STATUS: FAILED BUILD: master:eaa5df34af42b6a37f6506847d0f3ef6ba0d298a ENVIRONMENT: qemux86-64 STEPS TO REPRODUCE: 1. Download sudoku-savant project from http://downloads.sourceforge.net/project/sudoku-savant/sudoku-savant/sudoku-savant-1.3/sudoku-savant-1.3.tar.bz2 2. Copy sudoku-savant tarball into sdk image 3. Extract the tarball and do "configure", "make" EXPECTED OUTCOME: sudoku-savant could be compiled successfully . ACTUAL OUTCOME: " root@qemux86-64:~/sudoku-savant-1.3# make make all-recursive make[1]: Entering directory `/home/root/sudoku-savant-1.3' Making all in src make[2]: Entering directory `/home/root/sudoku-savant-1.3/src' g++ -DHAVE_CONFIG_H -I. -I.. -DPACKAGE_DATA_DIR=\""/usr/local/share"\" -DPACKAGE_LOCALE_DIR=\""/usr/local/share/locale"\" -pthread -I/usr/include/gtk-2.0 -I/usr/lib/gtk-2.0/include -I/usr/include/pango-1.0 -I/usr/include/atk-1.0 -I/usr/include/cairo -I/usr/include/pixman-1 -I/usr/include/libpng16 -I/usr/include/gdk-pixbuf-2.0 -I/usr/include/libpng16 -I/usr/include/pango-1.0 -I/usr/include/harfbuzz -I/usr/include/pango-1.0 -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/freetype2 -frepo -fno-implement-inlines -ansi -pedantic -pipe -Wall -Winline -Wshadow -Wsign-compare -Woverloaded-virtual -Wextra --param max-inline-insns-single=400 -g -O2 -MT main.o -MD -MP -MF .deps/main.Tpo -c -o main.o main.cpp main.cpp:10:19: fatal error: cstdlib: No such file or directory #include <cstdlib> ^ compilation terminated. " NOTE: Reproduced for BSP targets and QEMU targets on sato-sdk and lsb-sdk images.
Same thing happened when I tried to do a simple compiler test on MPC8315e BUILD: master:eaa5df34af42b6a37f6506847d0f3ef6ba0d298a Target: mpc8315e root@mpc8315e-rdb:/opt/tests/compilers# gcc -c cpp_test.cpp cpp_test.cpp:3:20: fatal error: iostream: No such file or directory #include <iostream> ^ compilation terminated. root@mpc8315e-rdb:/opt/tests/compilers# find /usr/include -name iostream /usr/include/c++/iostream root@mpc8315e-rdb:/opt/tests/compilers# gcc -v Using built-in specs. COLLECT_GCC=gcc COLLECT_LTO_WRAPPER=/usr/lib/gcc/gcc/powerpc-poky-linux/4.8.1/lto-wrapper Target: powerpc-poky-linux Configured with: /srv/home/pokybuild/yocto-autobuilder-new/yocto-slave/nightly-ppc/build/build/tmp/work-shared/gcc-4.8.1-r0/gcc-4.8.1/configure --build=x86_64-linux --host=powerpc-poky-linux --target=powerpc-poky-linux --prefix=/usr --exec_prefix=/usr --bindir=/usr/bin --sbindir=/usr/sbin --libexecdir=/usr/lib/gcc --datadir=/usr/share --sysconfdir=/etc --sharedstatedir=/com --localstatedir=/var --libdir=/usr/lib --includedir=/usr/include --oldincludedir=/usr/include --infodir=/usr/share/info --mandir=/usr/share/man --disable-silent-rules --disable-dependency-tracking --with-libtool-sysroot=/srv/home/pokybuild/yocto-autobuilder-new/yocto-slave/nightly-ppc/build/build/tmp/sysroots/mpc8315e-rdb --with-gnu-ld --enable-shared --enable-languages=c,c++ --enable-threads=posix --enable-multilib --enable-c99 --enable-long-long --enable-symvers=gnu --enable-libstdcxx-pch --program-prefix=powerpc-poky-linux- --without-local-prefix --enable-lto --enable-libssp --disable-bootstrap --disable-libmudflap --with-system-zlib --with-linker-hash-style=gnu --enable-linker-build-id --with-ppl=no --with-cloog=no --enable-checking=release --enable-cheaders=c_global --with-float=soft --with-sysroot=/ --with-build-sysroot=/srv/home/pokybuild/yocto-autobuilder-new/yocto-slave/nightly-ppc/build/build/tmp/sysroots/mpc8315e-rdb --with-native-system-header-dir=/srv/home/pokybuild/yocto-autobuilder-new/yocto-slave/nightly-ppc/build/build/tmp/sysroots/mpc8315e-rdb/usr/include --with-gxx-include-dir=/usr/include/c++/ --enable-dependency-tracking --enable-targets=powerpc64 --enable-nls --enable-__cxa_atexit --with-long-double-128 Thread model: posix gcc version 4.8.1 (GCC) But using gcc (version 4.7.2) doesn't has this problem. It looks like that gcc didn't look for header files from /usr/include/c++, which means "--with-gxx-include-dir=/usr/include/c++/" doesn't work. This should be the same problem that Stoicescu Cornel encountered.
Plus, if I specify header dir with -I /usr/include/c++, compiling is OK.
This looks like a configuration issue with the target gcc missing some setup.
*** Bug 4829 has been marked as a duplicate of this bug. ***
sometimes applications use precompiled headers and can end up in such issues. Can you try to compile a simple c++ program like helloworld and see it it can find the headers ? something like #include <iostream> #include <cstdlib> int main() { std::cout << "Hello, World!" << std::endl; } if that compiles then we do not have issue with gcc.
It indeed fails with the same error.
Patch is posted here http://lists.openembedded.org/pipermail/openembedded-core/2013-July/081311.html Please test it out in your environment.
http://git.yoctoproject.org/cgit/cgit.cgi/poky/commit/?id=fb58029ed04c105a80a7ca0ed4a18d5ac924742a
This issue is not present in latest 1.5 M5 RC5 build. Setting to VERIFIED for: poky master:4d8ab87d25ea6e59dc88375813ef88ee0ac813d0