About the only thing I'd add to roel_v's excellent sugegstions (to which I cannot reply) is the use of ccache, distcc, and if you can use it, the gold linker. For larger projects, they make compile times bearable. In fact, I usually complain about time spent in linking, rather than compiling.