Writing an Operating System - Environment Setup
It took me a few times because I didn’t read the instructions properly. It is important to unpack the sources for binutils and gcc and have separate build directories,
gcc-build for example. Then, for building gcc, make sure the newly built binutils are on your path.
And finally, when building gcc, make sure you run
make install-gcc, and
make install-target-libgcc instead of just
make all like I did.
Also, running make with
-j 4 or any value larger than 1 greatly sped up the build on my machine. Multicore for the win!
Once you’ve built both binutils and gcc you’re ready to start building your kernel!