I use ./configure command to generate a makefile. My compiler is arm-fsl-linux-gnueabi toochain. When I ran ./configure, I got the following problem:
tl@tl-virtual-machine:~/Desktop/mvux_camera/demo/sampli_save_demo$ ./configure --host=/home/tl/Desktop/opt/Embedsky/gcc-4.6.2-glibc-2.13-linaro-multilib-2011.12/tq-linaro-toolchain/bin/arm-fsl-linux-gnueabi-g++ configure: WARNING: if you wanted to set the --build type, don't use --host. If a cross compiler is detected then cross compile mode will be used checking for a BSD-compatible install... /usr/bin/install -c checking whether build environment is sane... yes checking for /home/tl/Desktop/opt/Embedsky/gcc-4.6.2-glibc-2.13-linaro-multilib-2011.12/tq-linaro-toolchain/bin/arm-fsl-linux-gnueabi-g++-strip... no checking for strip... strip checking for a thread-safe mkdir -p... /bin/mkdir -p checking for gawk... no checking for mawk... mawk checking whether make sets $(MAKE)... yes checking for /home/tl/Desktop/opt/Embedsky/gcc-4.6.2-glibc-2.13-linaro-multilib-2011.12/tq-linaro-toolchain/bin/arm-fsl-linux-gnueabi-g++-g++... no checking for /home/tl/Desktop/opt/Embedsky/gcc-4.6.2-glibc-2.13-linaro-multilib-2011.12/tq-linaro-toolchain/bin/arm-fsl-linux-gnueabi-g++-c++... no checking for /home/tl/Desktop/opt/Embedsky/gcc-4.6.2-glibc-2.13-linaro-multilib-2011.12/tq-linaro-toolchain/bin/arm-fsl-linux-gnueabi-g++-gpp... no checking for /home/tl/Desktop/opt/Embedsky/gcc-4.6.2-glibc-2.13-linaro-multilib-2011.12/tq-linaro-toolchain/bin/arm-fsl-linux-gnueabi-g++-aCC... no checking for /home/tl/Desktop/opt/Embedsky/gcc-4.6.2-glibc-2.13-linaro-multilib-2011.12/tq-linaro-toolchain/bin/arm-fsl-linux-gnueabi-g++-CC... no checking for /home/tl/Desktop/opt/Embedsky/gcc-4.6.2-glibc-2.13-linaro-multilib-2011.12/tq-linaro-toolchain/bin/arm-fsl-linux-gnueabi-g++-cxx... no checking for /home/tl/Desktop/opt/Embedsky/gcc-4.6.2-glibc-2.13-linaro-multilib-2011.12/tq-linaro-toolchain/bin/arm-fsl-linux-gnueabi-g++-cc++... no checking for /home/tl/Desktop/opt/Embedsky/gcc-4.6.2-glibc-2.13-linaro-multilib-2011.12/tq-linaro-toolchain/bin/arm-fsl-linux-gnueabi-g++-cl.exe... no checking for /home/tl/Desktop/opt/Embedsky/gcc-4.6.2-glibc-2.13-linaro-multilib-2011.12/tq-linaro-toolchain/bin/arm-fsl-linux-gnueabi-g++-FCC... no checking for /home/tl/Desktop/opt/Embedsky/gcc-4.6.2-glibc-2.13-linaro-multilib-2011.12/tq-linaro-toolchain/bin/arm-fsl-linux-gnueabi-g++-KCC... no checking for /home/tl/Desktop/opt/Embedsky/gcc-4.6.2-glibc-2.13-linaro-multilib-2011.12/tq-linaro-toolchain/bin/arm-fsl-linux-gnueabi-g++-RCC... no checking for /home/tl/Desktop/opt/Embedsky/gcc-4.6.2-glibc-2.13-linaro-multilib-2011.12/tq-linaro-toolchain/bin/arm-fsl-linux-gnueabi-g++-xlC_r... no checking for /home/tl/Desktop/opt/Embedsky/gcc-4.6.2-glibc-2.13-linaro-multilib-2011.12/tq-linaro-toolchain/bin/arm-fsl-linux-gnueabi-g++-xlC... no checking for g++... no checking for c++... no checking for gpp... no checking for aCC... no checking for CC... no checking for cxx... no checking for cc++... no checking for cl.exe... no checking for FCC... no checking for KCC... no checking for RCC... no checking for xlC_r... no checking for xlC... no checking whether the C++ compiler works... no configure: error: in '/home/tl/Desktop/mvux_camera/demo/sampli_save_demo': configure: error: C++ compiler cannot create executables See 'config.log' for more details
My toolchain was sourced, when typing arm-fsl-linux-gnueabi-gcc -v
, the command line shows it works.
tl@tl-virtual-machine:~/Desktop/mvux_camera/demo/sampli_save_demo$ arm-fsl-linux-gnueabi-gcc -v Using built-in specs. COLLECT_GCC=arm-fsl-linux-gnueabi-gcc COLLECT_LTO_WRAPPER=/home/tl/Desktop/opt/Embedsky/gcc-4.6.2-glibc-2.13-linaro-multilib-2011.12/tq-linaro-toolchain/bin/../libexec/gcc/arm-fsl-linux-gnueabi/4.6.2/lto-wrapper Target: arm-fsl-linux-gnueabi Configured with: /work/build/.build/src/gcc-linaro-4.6-2011.06-0/configure --build=i686-build_pc-linux-gnu --host=i686-build_pc-linux-gnu --target=arm-fsl-linux-gnueabi --prefix=/work/fsl-linaro-toolchain-2.13 --with-sysroot=/work/fsl-linaro-toolchain-2.13/arm-fsl-linux-gnueabi/multi-libs --enable-languages=c,c++ --with-pkgversion='Freescale MAD -- Linaro 2011.07 -- Built at 2011/08/10 09:20' --enable-__cxa_atexit --disable-libmudflap --disable-libgomp --disable-libssp --with-gmp=/work/build/.build/arm-fsl-linux-gnueabi/build/static --with-mpfr=/work/build/.build/arm-fsl-linux-gnueabi/build/static --with-mpc=/work/build/.build/arm-fsl-linux-gnueabi/build/static --with-ppl=/work/build/.build/arm-fsl-linux-gnueabi/build/static --with-cloog=/work/build/.build/arm-fsl-linux-gnueabi/build/static --with-libelf=/work/build/.build/arm-fsl-linux-gnueabi/build/static --with-host-libstdcxx='-static-libgcc -Wl,-Bstatic,-lstdc++,-Bdynamic -lm -L/work/build/.build/arm-fsl-linux-gnueabi/build/static/lib -lpwl' --enable-threads=posix --enable-target-optspace --enable-plugin --enable-multilib --with-local-prefix=/work/fsl-linaro-toolchain-2.13/arm-fsl-linux-gnueabi/multi-libs --disable-nls --enable-c99 --enable-long-long --with-system-zlib Thread model: posix gcc version 4.6.2 20110630 (prerelease) (Freescale MAD -- Linaro 2011.07 -- Built at 2011/08/10 09:20)