Buildroot is great to make a full Linux system from sources. Nevertheless, the toolchain is a special part in building process:

  • Compilation is very long
  • Compilation is difficult to stop and restart
  • We rarely recompile toolchain
  • We want to provide toolchain as a standalone package without Buildroot

Some advice about toolchain making under Buildroot:

  1. Use crosstool-ng. Buildroot support internal toolchain building, but crosstool-ng is specialized in toolchain building. Toolchain depends less of their installation path and there are more options
  2. Use build out of tree (pass O= option to make). Since toolchains compilation is long, always test in a new fresh directory without break your current work.
  3. Change CONFIG_BR2_HOST_DIR. Toolchains depend often of their build path. It is not great to ask to end user to copy toolchain in /home/toto/mywork/buildroot/unstable_dontdeliver/host. /opt/arm-mycompagny-linux-eabi is a far better choice.
  4. $BR2_HOST_DIR will contain a full BSP. Just do "make uclibc" if you only want toolchain with headers from C library. Make an archive just after this step
  5. Write two configurations for your board: One compile toolchain and other one use external toolchain.
  6. Once your rootfs boot, add dropbear to your system and run gcc testsuite. It is really easy to run and guaranty again some bugs like badly configured floating units, bad exception catching, etc...