When I am building a (very small cpio initramfs) buildroot configuration, strace fails if only busybox & strace are build. Probably strace configure see my system bluetooth/bluetooth.h which is not present in sysroot.
Could you please indicate the Buildroot version you're using, and attach a minimal Buildroot .config that exhibits the problem? I'm routinely building system with just Busybox and strace, and it just works fine for me, so there is probably something special in the configuration you're using.
Created attachment 5986 [details] my configuration failing with busybox & strace
using buildroot from git merged today, commit id 53903a1520420ae92fc1a9b4ffa6df8efff266f4
You're using a custom external toolchain: BR2_TOOLCHAIN_EXTERNAL_PATH="/opt/cross/quark/toolchain" So it's most likely this toolchain that is broken. Is this toolchain available somewhere?
Created attachment 5991 [details] ct-ng toolchain configuration I am using my own ct-ng build toolchain. See other comment.
We are working with an Intel Galileo gen2 board. Intel states you should use Yocto. The reason we are all still here (probably) is because we do NOT like Yocto, or at least I do not like it. I think it is way to bloated. Because I could not find a suitable toolchain, I built one myself. My guess would be that it is not the toolchain which is broken, it has no header files whatsoever regarding any bluetooth headers. I am using the same toolchain for a "full-blown" rootfs (the one from this bug is only for initramfs); it works quite well there. But in that case I also enabled bluez5....
So, I've tried to reproduce this here. Here's my defconfig: BR2_x86_64=y BR2_TOOLCHAIN_EXTERNAL=y BR2_PACKAGE_STRACE=y Also, I do have bluetooth devel files installed on my host system: $ ls -l /usr/include/bluetooth/bluetooth.h -rw-r--r-- 1 root root 7588 Jan 28 22:19 /usr/include/bluetooth/bluetooth.h But it is not present in the sysroot: $ find staging/ -name bluetooth.h [nothing] And strace's log is like: checking bluetooth/bluetooth.h usability... no checking bluetooth/bluetooth.h presence... no checking for bluetooth/bluetooth.h... no Can you try to reproduce from a clean environment?
Okay, I checked the build output: <snip> checking bluetooth/bluetooth.h usability... yes checking bluetooth/bluetooth.h presence... no configure: WARNING: bluetooth/bluetooth.h: accepted by the compiler, rejected by the preprocessor! configure: WARNING: bluetooth/bluetooth.h: proceeding with the compiler's result checking for bluetooth/bluetooth.h... yes </snip> Any clue if I should look into the toolchain? I might also try the buildroot toolchain generator once more later today. I could also build that once, store it in /opt/cross/ .. and just use that from buildroot, just like my current toolchain.
Can you look at config.log in the strace build dir and see what commands are run when checking for bluetooth.h ?
My strace/config.log <snip> configure:7337: checking bluetooth/bluetooth.h usability configure:7337: /data/work/zupr/ZUPR-Embedded-Buildroot_initramfs/output/host/usr/bin/ccache /data/work/zupr/ZUPR-Embedded-Buildroot_initramfs/output/host/usr/bin/i586-unknown-linux-gnu-gcc -c -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -pipe -Os -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 conftest.c >&5 conftest.c:89:33: fatal error: bluetooth/bluetooth.h: No such file or directory #include <bluetooth/bluetooth.h> ^ compilation terminated. configure:7337: $? = 1 </snip> Seems rather normal. But, wait, I just did change two things: - change default rootpw to "" - did a make distclean Now it seems to work as expected. Could it have something to do with the above? Most likely number 2, I do not think changing a root pwd wil effect something like this. Or maybe it is ccache ?
It seems you did not start from a clean directory (e.g. you only removed target/ or some such). Buildroot does not try to track changes in the configuration, so sometimes it is needed to clean the build directory and restart from scratch. Please have a look at the manual: http://buildroot.net/downloads/manual/manual.html#full-rebuild and see if you where in a case explained there. See also: http://buildroot.net/downloads/manual/manual.html#faq-no-binary-packages which has a good explanation about (not) removing packages and (not) tracking configuration changes.
I think it was my badness after all. I cloned the buildroot git archive and put several branches in it from which I develop my various images. Sometimes I git checkout <other_branch> and forget to do a make clean. I changed my method of working to cloning the archive in multiple directories en never do git checkout <other_branch> in those directories. It seems to work as expected now. Closing the issue.