uclibc is part of the toolchain, and as such does not have a dependency on it. As a consequence, it does not have a dependency on host-ccache, when this is needed. Usually, host-ccache is built before uclibc, as part of the dependency of gcc-initial, host-binutils, and a few other host packages that are built before uclibc. However, during top-level parallel builds, this ordering is only ever guaranteed at the beginning of the configure step, and not before. But for kconfig-packages, the moment we apply the configuration to prepare the .config file is a pseudo step that happens somewhere in limbo between the patch step and the configure step. As such, the build ordering that is otherwise guaranteed by the _DEPENDENCIES is not applicable yet. And so, with top-level parallel builds with ccache enabled, there is nothing that guarantees host-ccache to be built and installed by the time we are trying to generate uclibc's .config file, which can be quite early in the build process, and thus the build fails: /home/raphael/github/ftcommunity-TXT/buildroot-rootfs/output/per-package/uclibc/host/bin/ccache /usr/bin/gcc /home/raphael/github/ftcommunity-TXT/buildroot-rootfs/output/build/uclibc-1.0.34/extra/config/conf.c -c -o ../../extra/config/conf.o -Os -I/usr/include/ncursesw -DCURSES_LOC="<curses.h>" -DNCURSES_WIDECHAR=1 -DLOCALE -DKBUILD_NO_NLS -DCONFIG_='""' -I/usr/include/ncursesw -DCURSES_LOC="<curses.h>" -DNCURSES_WIDECHAR=1 -DLOCALE -DKBUILD_NO_NLS -DCONFIG_='""' /bin/sh: 1: /home/raphael/github/ftcommunity-TXT/buildroot-rootfs/output/per-package/uclibc/host/bin/ccache: not found make[2]: *** [Makefile:64: ../../extra/config/conf.o] Error 127 make[1]: *** [Makefile.in:475: extra/config/conf] Error 2 make[1]: Leaving directory '/home/raphael/github/ftcommunity-TXT/buildroot-rootfs/output/build/uclibc-1.0.34' make: *** [package/uclibc/uclibc.mk:458: /home/raphael/github/ftcommunity-TXT/buildroot-rootfs/output/build/uclibc-1.0.34/.stamp_dotconfig] Error 2 make: *** Waiting for unfinished jobs.... The root cause is that uclibc sets; UCLIBC_KCONFIG_OPTS = $(UCLIBC_MAKE_FLAGS) [...] with: UCLIBC_MAKE_FLAGS = [...] HOSTCC="$(HOSTCC)" And then the kconfig-package infra calls to the configurators, menuconfig, xconfig et al, but also olddefconfig et al.. with: [...] $($(1)_MAKE) [...] $(PKG_KCONFIG_COMMON_OPTS) $($(1)_KCONFIG_OPTS) [...] with (note a latent bug in there, will be fixed in another patch): PKG_KCONFIG_COMMON_OPTS = HOSTCC=$(HOSTCC_NOCCACHE) So, a HOSTCC as set by a package will always win onver the one set by the infra, which is exactly what we want. But in this case, uclibc sets HOSTCC so that it can build its host tools needed during the build, and in doing so uses the ccache-enabled host c compiler. Which might not yet be available for the kconfig-package infra to generate the .config file. We had a similar (non-)issue for the linux package, which was fixed in commit |
||
---|---|---|
arch | ||
board | ||
boot | ||
configs | ||
docs | ||
fs | ||
linux | ||
package | ||
support | ||
system | ||
toolchain | ||
utils | ||
.defconfig | ||
.flake8 | ||
.gitignore | ||
.gitlab-ci.yml | ||
.gitlab-ci.yml.in | ||
CHANGES | ||
Config.in | ||
Config.in.legacy | ||
COPYING | ||
DEVELOPERS | ||
Makefile | ||
Makefile.legacy | ||
README |
Buildroot is a simple, efficient and easy-to-use tool to generate embedded Linux systems through cross-compilation. The documentation can be found in docs/manual. You can generate a text document with 'make manual-text' and read output/docs/manual/manual.text. Online documentation can be found at http://buildroot.org/docs.html To build and use the buildroot stuff, do the following: 1) run 'make menuconfig' 2) select the target architecture and the packages you wish to compile 3) run 'make' 4) wait while it compiles 5) find the kernel, bootloader, root filesystem, etc. in output/images You do not need to be root to build or run buildroot. Have fun! Buildroot comes with a basic configuration for a number of boards. Run 'make list-defconfigs' to view the list of provided configurations. Please feed suggestions, bug reports, insults, and bribes back to the buildroot mailing list: buildroot@buildroot.org You can also find us on #buildroot on Freenode IRC. If you would like to contribute patches, please read https://buildroot.org/manual.html#submitting-patches