msgpack / msgpack-c

MessagePack implementation for C and C++ / msgpack.org[C/C++]
Other
3.03k stars 883 forks source link

Issue Configuring and building for Linux running on Cold Fire Board / Atomic Opertions not supported ? #19

Open UsmanQureshi opened 11 years ago

UsmanQureshi commented 11 years ago

dev@dev-desktop:~/Downloads/msgpack-0.5.4$ ./configure --host=m68k-linux CC=m68k-linux-gnu-gcc CXX=m68k-linux-gnu-g++ CFLAGS=-march=m68k 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 m68k-linux-strip... no checking for strip... strip checking for a thread-safe mkdir -p... /bin/mkdir -p checking for gawk... gawk checking whether make sets $(MAKE)... yes checking for m68k-linux-gcc... m68k-linux-gnu-gcc checking whether the C compiler works... no configure: error: in /home/dev/Downloads/msgpack-0.5.4': configure: error: C compiler cannot create executables Seeconfig.log' for more details. dev@dev-desktop:~/Downloads/msgpack-0.5.4$ ./configure --host=m68k-linux CC=m68k-linux-gnu-gcc CXX=m68k-linux-gnu-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 m68k-linux-strip... no checking for strip... strip checking for a thread-safe mkdir -p... /bin/mkdir -p checking for gawk... gawk checking whether make sets $(MAKE)... yes checking for m68k-linux-gcc... m68k-linux-gnu-gcc checking whether the C compiler works... yes checking for C compiler default output file name... a.out checking for suffix of executables... checking whether we are cross compiling... yes checking for suffix of object files... o checking whether we are using the GNU C compiler... yes checking whether m68k-linux-gnu-gcc accepts -g... yes checking for m68k-linux-gnu-gcc option to accept ISO C89... none needed checking for style of include used by make... GNU checking dependency style of m68k-linux-gnu-gcc... gcc3 checking if C++ API is enabled... checking whether we are using the GNU C++ compiler... yes checking whether m68k-linux-gnu-g++ accepts -g... yes checking dependency style of m68k-linux-gnu-g++... gcc3 checking whether m68k-linux-gnu-gcc and cc understand -c and -o together... yes checking build system type... i686-pc-linux-gnu checking host system type... m68k-unknown-linux-gnu checking for a sed that does not truncate output... /bin/sed checking for grep that handles long lines and -e... /bin/grep checking for egrep... /bin/grep -E checking for fgrep... /bin/grep -F checking for ld used by m68k-linux-gnu-gcc... /opt/freescale/usr/local/gcc-4.4.217-eglibc-2.11.217/m68k-linux/m68k-linux-gnu/bin/ld checking if the linker (/opt/freescale/usr/local/gcc-4.4.217-eglibc-2.11.217/m68k-linux/m68k-linux-gnu/bin/ld) is GNU ld... yes checking for BSD- or MS-compatible name lister (nm)... no checking for m68k-linux-dumpbin... no checking for m68k-linux-link... no checking for dumpbin... no checking for link... link -dump -symbols configure: WARNING: using cross tools not prefixed with host triplet checking the name lister (link -dump -symbols) interface... BSD nm checking whether ln -s works... yes checking the maximum length of command line arguments... 1572864 checking whether the shell understands some XSI constructs... yes checking whether the shell understands "+="... yes checking for /opt/freescale/usr/local/gcc-4.4.217-eglibc-2.11.217/m68k-linux/m68k-linux-gnu/bin/ld option to reload object files... -r checking for m68k-linux-objdump... no checking for objdump... objdump checking how to recognize dependent libraries... pass_all checking for m68k-linux-ar... no checking for ar... ar checking for m68k-linux-strip... strip checking for m68k-linux-ranlib... no checking for ranlib... ranlib checking command to parse link -dump -symbols output from m68k-linux-gnu-gcc object... failed checking how to run the C preprocessor... m68k-linux-gnu-gcc -E checking for ANSI C header files... yes checking for sys/types.h... yes checking for sys/stat.h... yes checking for stdlib.h... yes checking for string.h... yes checking for memory.h... yes checking for strings.h... yes checking for inttypes.h... yes checking for stdint.h... yes checking for unistd.h... yes checking for dlfcn.h... yes checking whether we are using the GNU C++ compiler... (cached) yes checking whether m68k-linux-gnu-g++ accepts -g... (cached) yes checking dependency style of m68k-linux-gnu-g++... (cached) gcc3 checking how to run the C++ preprocessor... m68k-linux-gnu-g++ -E checking for objdir... .libs checking if m68k-linux-gnu-gcc supports -fno-rtti -fno-exceptions... no checking for m68k-linux-gnu-gcc option to produce PIC... -fPIC -DPIC checking if m68k-linux-gnu-gcc PIC flag -fPIC -DPIC works... yes checking if m68k-linux-gnu-gcc static flag -static works... yes checking if m68k-linux-gnu-gcc supports -c -o file.o... yes checking if m68k-linux-gnu-gcc supports -c -o file.o... (cached) yes checking whether the m68k-linux-gnu-gcc linker (/opt/freescale/usr/local/gcc-4.4.217-eglibc-2.11.217/m68k-linux/m68k-linux-gnu/bin/ld) supports shared libraries... yes checking whether -lc should be explicitly linked in... no checking dynamic linker characteristics... GNU/Linux ld.so checking how to hardcode library paths into programs... immediate checking whether stripping libraries is possible... yes checking if libtool supports shared libraries... yes checking whether to build shared libraries... yes checking whether to build static libraries... yes checking for ld used by m68k-linux-gnu-g++... /opt/freescale/usr/local/gcc-4.4.217-eglibc-2.11.217/m68k-linux/m68k-linux-gnu/bin/ld checking if the linker (/opt/freescale/usr/local/gcc-4.4.217-eglibc-2.11.217/m68k-linux/m68k-linux-gnu/bin/ld) is GNU ld... yes checking whether the m68k-linux-gnu-g++ linker (/opt/freescale/usr/local/gcc-4.4.217-eglibc-2.11.217/m68k-linux/m68k-linux-gnu/bin/ld) supports shared libraries... yes checking for m68k-linux-gnu-g++ option to produce PIC... -fPIC -DPIC checking if m68k-linux-gnu-g++ PIC flag -fPIC -DPIC works... yes checking if m68k-linux-gnu-g++ static flag -static works... yes checking if m68k-linux-gnu-g++ supports -c -o file.o... yes checking if m68k-linux-gnu-g++ supports -c -o file.o... (cached) yes checking whether the m68k-linux-gnu-g++ linker (/opt/freescale/usr/local/gcc-4.4.217-eglibc-2.11.217/m68k-linux/m68k-linux-gnu/bin/ld) supports shared libraries... yes checking dynamic linker characteristics... GNU/Linux ld.so checking how to hardcode library paths into programs... immediate checking dependency style of m68k-linux-gnu-gcc... gcc3 checking if debug option is enabled... checking for _sync* atomic operations... configure: error: _sync* atomic operations are not supported.

Note that gcc < 4.1 is not supported.

If you are using gcc >= 4.1 and the default target CPU architecture is "i386", try to add CFLAGS="--march=i686" and CXXFLAGS="-march=i686" options to ./configure as follows:

$ ./configure CFLAGS="-march=i686" CXXFLAGS="-march=i686"

dev@dev-desktop:~/Downloads/msgpack-0.5.4$ m68k-linux-gnu-gcc -v Using built-in specs. Target: m68k-linux-gnu Configured with: /scratch/maxim/cf-2010q1-lite/src-linux/gcc-4.4-2010q1/configure --build=i686-pc-linux-gnu --host=i686-pc-linux-gnu --target=m68k-linux-gnu --enable-threads --disable-libmudflap --disable-libssp --disable-libstdcxx-pch --with-arch=cf --with-gnu-as --with-gnu-ld --with-specs='%{O2:%{!fno-remove-local-statics: -fremove-local-statics}} %{O*:%{O|O0|O1|O2|Os:;:%{!fno-remove-local-statics: -fremove-local-statics}}}' --enable-languages=c,c++ --enable-shared --disable-lto --enable-symvers=gnu --enable-__cxa_atexit --with-pkgversion='Sourcery G++ Lite 4.4-217' --with-bugurl=https://support.codesourcery.com/GNUToolchain/ --disable-nls --prefix=/opt/freescale/usr/local/gcc-4.4.217-eglibc-2.11.217/m68k-linux --with-sysroot=/opt/freescale/usr/local/gcc-4.4.217-eglibc-2.11.217/m68k-linux/m68k-linux-gnu/libc --with-build-sysroot=/scratch/maxim/cf-2010q1-lite/install-linux/m68k-linux-gnu/libc --with-gmp=/scratch/maxim/cf-2010q1-lite/obj-linux/host-libs-4.4-217-m68k-linux-gnu-i686-pc-linux-gnu/usr --with-mpfr=/scratch/maxim/cf-2010q1-lite/obj-linux/host-libs-4.4-217-m68k-linux-gnu-i686-pc-linux-gnu/usr --with-ppl=/scratch/maxim/cf-2010q1-lite/obj-linux/host-libs-4.4-217-m68k-linux-gnu-i686-pc-linux-gnu/usr --with-host-libstdcxx='-static-libgcc -Wl,-Bstatic,-lstdc++,-Bdynamic -lm' --with-cloog=/scratch/maxim/cf-2010q1-lite/obj-linux/host-libs-4.4-217-m68k-linux-gnu-i686-pc-linux-gnu/usr --enable-libgomp --enable-poison-system-directories --with-build-time-tools=/scratch/maxim/cf-2010q1-lite/install-linux/m68k-linux-gnu/bin --with-build-time-tools=/scratch/maxim/cf-2010q1-lite/install-linux/m68k-linux-gnu/bin Thread model: posix gcc version 4.4.1 (Sourcery G++ Lite 4.4-217) dev@dev-desktop:~/Downloads/msgpack-0.5.4$ The above tool chain uses the https://sourcery.mentor.com/GNUToolchain/subscription3129?lite=ColdFire

redboltz commented 7 years ago

Now msgpack-c is using cmake. autotools has already been unsupported. Please test with cmake.