
"Andrew Wilkinson"
in addition that although the CCFLAGS variable is given to the C compiler when building C files, it is not given to the C compiler when linking those object files together.
Can you post the complete output of scons when trying to build? CCFLAGS are passed for me...
Attached below Regards, Malcolm ---- $ CCFLAGS=-m64 scons scons: Reading SConscript files ... Building version 0.7.0-20070213121534-custom. Checking for architecture... ppc Checking for operating system... darwin Adding '-m64' to CCFLAGS. Checking for architecture... ppc Checking for operating system... darwin Checking for Subversion binary... "svn" Checking for Subversion version... Found version 1.3.1. Checking for GHC binary... "ghc" Checking for GHC version 6.4.1 or later... Found version 6.6. Checking for C header file gmp.h... yes Checking for mpz_t integ; mpz_init (integ) in C library gmp... no Checking for mpz_t integ; mpz_init (integ) in C library GMP... no Error. libgmp must be installed made accessible before you can compile Yhc. Checking for libgmp version... failed Bootstrapping... Done. scons: done reading SConscript files. scons: Building targets ... gcc -DPOWERPC_DARWIN -m64 -Wall -DVERSION=\"0.7.0-20070213121534-custom\" -DPOWERPC_DARWIN -Idepends/ctypes/libffi/include -Idepends/ctypes/libffi/src -Idepends/ctypes/libffi/src/powerpc -Idepends/ctypes/libffi -I. -I/usr/local/include -I/opt/local/include -I/Library/Frameworks/GMP.Framework/Headers -Idepends/ctypes/libffi/include -Idepends/ctypes/libffi/src/powerpc -c -o depends/ctypes/libffi/src/cfield.o depends/ctypes/libffi/src/cfield.c gcc -DPOWERPC_DARWIN -m64 -Wall -DVERSION=\"0.7.0-20070213121534-custom\" -DPOWERPC_DARWIN -Idepends/ctypes/libffi/include -Idepends/ctypes/libffi/src -Idepends/ctypes/libffi/src/powerpc -Idepends/ctypes/libffi -I. -I/usr/local/include -I/opt/local/include -I/Library/Frameworks/GMP.Framework/Headers -Idepends/ctypes/libffi/include -Idepends/ctypes/libffi/src/powerpc -c -o depends/ctypes/libffi/src/powerpc/ffi_darwin.o depends/ctypes/libffi/src/powerpc/ffi_darwin.c gcc -DPOWERPC_DARWIN -m64 -Wall -DVERSION=\"0.7.0-20070213121534-custom\" -DPOWERPC_DARWIN -Idepends/ctypes/libffi/include -Idepends/ctypes/libffi/src -Idepends/ctypes/libffi/src/powerpc -Idepends/ctypes/libffi -I. -I/usr/local/include -I/opt/local/include -I/Library/Frameworks/GMP.Framework/Headers -Idepends/ctypes/libffi/include -Idepends/ctypes/libffi/src/powerpc -c -o depends/ctypes/libffi/src/prep_cif.o depends/ctypes/libffi/src/prep_cif.c gcc -DPOWERPC_DARWIN -m64 -Wall -DVERSION=\"0.7.0-20070213121534-custom\" -DPOWERPC_DARWIN -I. -I/usr/local/include -I/opt/local/include -I/Library/Frameworks/GMP.Framework/Headers -Idepends/ctypes/libffi/include -Idepends/ctypes/libffi/src/powerpc -c -o src/runtime/BCKernel/basepath.o src/runtime/BCKernel/basepath.c gcc -DPOWERPC_DARWIN -m64 -Wall -DVERSION=\"0.7.0-20070213121534-custom\" -DPOWERPC_DARWIN -I. -I/usr/local/include -I/opt/local/include -I/Library/Frameworks/GMP.Framework/Headers -Idepends/ctypes/libffi/include -Idepends/ctypes/libffi/src/powerpc -c -o src/runtime/BCKernel/external.o src/runtime/BCKernel/external.c gcc -DPOWERPC_DARWIN -m64 -Wall -DVERSION=\"0.7.0-20070213121534-custom\" -DPOWERPC_DARWIN -I. -I/usr/local/include -I/opt/local/include -I/Library/Frameworks/GMP.Framework/Headers -Idepends/ctypes/libffi/include -Idepends/ctypes/libffi/src/powerpc -c -o src/runtime/BCKernel/foreign.o src/runtime/BCKernel/foreign.c gcc -DPOWERPC_DARWIN -m64 -Wall -DVERSION=\"0.7.0-20070213121534-custom\" -DPOWERPC_DARWIN -I. -I/usr/local/include -I/opt/local/include -I/Library/Frameworks/GMP.Framework/Headers -Idepends/ctypes/libffi/include -Idepends/ctypes/libffi/src/powerpc -c -o src/runtime/BCKernel/hashtable.o src/runtime/BCKernel/hashtable.c gcc -DPOWERPC_DARWIN -m64 -Wall -DVERSION=\"0.7.0-20070213121534-custom\" -DPOWERPC_DARWIN -I. -I/usr/local/include -I/opt/local/include -I/Library/Frameworks/GMP.Framework/Headers -Idepends/ctypes/libffi/include -Idepends/ctypes/libffi/src/powerpc -c -o src/runtime/BCKernel/heap.o src/runtime/BCKernel/heap.c gcc -DPOWERPC_DARWIN -m64 -Wall -DVERSION=\"0.7.0-20070213121534-custom\" -DPOWERPC_DARWIN -I. -I/usr/local/include -I/opt/local/include -I/Library/Frameworks/GMP.Framework/Headers -Idepends/ctypes/libffi/include -Idepends/ctypes/libffi/src/powerpc -c -o src/runtime/BCKernel/hsffi.o src/runtime/BCKernel/hsffi.c gcc -DPOWERPC_DARWIN -m64 -Wall -DVERSION=\"0.7.0-20070213121534-custom\" -DPOWERPC_DARWIN -I. -I/usr/local/include -I/opt/local/include -I/Library/Frameworks/GMP.Framework/Headers -Idepends/ctypes/libffi/include -Idepends/ctypes/libffi/src/powerpc -c -o src/runtime/BCKernel/info.o src/runtime/BCKernel/info.c gcc -DPOWERPC_DARWIN -m64 -Wall -DVERSION=\"0.7.0-20070213121534-custom\" -DPOWERPC_DARWIN -I. -I/usr/local/include -I/opt/local/include -I/Library/Frameworks/GMP.Framework/Headers -Idepends/ctypes/libffi/include -Idepends/ctypes/libffi/src/powerpc -c -o src/runtime/BCKernel/integer.o src/runtime/BCKernel/integer.c gcc -DPOWERPC_DARWIN -m64 -Wall -DVERSION=\"0.7.0-20070213121534-custom\" -DPOWERPC_DARWIN -I. -I/usr/local/include -I/opt/local/include -I/Library/Frameworks/GMP.Framework/Headers -Idepends/ctypes/libffi/include -Idepends/ctypes/libffi/src/powerpc -c -o src/runtime/BCKernel/iofuncs.o src/runtime/BCKernel/iofuncs.c gcc -DPOWERPC_DARWIN -m64 -Wall -DVERSION=\"0.7.0-20070213121534-custom\" -DPOWERPC_DARWIN -I. -I/usr/local/include -I/opt/local/include -I/Library/Frameworks/GMP.Framework/Headers -Idepends/ctypes/libffi/include -Idepends/ctypes/libffi/src/powerpc -c -o src/runtime/BCKernel/jonkers.o src/runtime/BCKernel/jonkers.c gcc -DPOWERPC_DARWIN -m64 -Wall -DVERSION=\"0.7.0-20070213121534-custom\" -DPOWERPC_DARWIN -I. -I/usr/local/include -I/opt/local/include -I/Library/Frameworks/GMP.Framework/Headers -Idepends/ctypes/libffi/include -Idepends/ctypes/libffi/src/powerpc -c -o src/runtime/BCKernel/main.o src/runtime/BCKernel/main.c gcc -DPOWERPC_DARWIN -m64 -Wall -DVERSION=\"0.7.0-20070213121534-custom\" -DPOWERPC_DARWIN -I. -I/usr/local/include -I/opt/local/include -I/Library/Frameworks/GMP.Framework/Headers -Idepends/ctypes/libffi/include -Idepends/ctypes/libffi/src/powerpc -c -o src/runtime/BCKernel/make.o src/runtime/BCKernel/make.c gcc -DPOWERPC_DARWIN -m64 -Wall -DVERSION=\"0.7.0-20070213121534-custom\" -DPOWERPC_DARWIN -I. -I/usr/local/include -I/opt/local/include -I/Library/Frameworks/GMP.Framework/Headers -Idepends/ctypes/libffi/include -Idepends/ctypes/libffi/src/powerpc -c -o src/runtime/BCKernel/mark.o src/runtime/BCKernel/mark.c src/runtime/BCKernel/mark.c: In function 'mark_rec': src/runtime/BCKernel/mark.c:238: warning: unused variable 'indent' gcc -DPOWERPC_DARWIN -m64 -Wall -DVERSION=\"0.7.0-20070213121534-custom\" -DPOWERPC_DARWIN -I. -I/usr/local/include -I/opt/local/include -I/Library/Frameworks/GMP.Framework/Headers -Idepends/ctypes/libffi/include -Idepends/ctypes/libffi/src/powerpc -c -o src/runtime/BCKernel/module.o src/runtime/BCKernel/module.c gcc -DPOWERPC_DARWIN -m64 -Wall -DVERSION=\"0.7.0-20070213121534-custom\" -DPOWERPC_DARWIN -I. -I/usr/local/include -I/opt/local/include -I/Library/Frameworks/GMP.Framework/Headers -Idepends/ctypes/libffi/include -Idepends/ctypes/libffi/src/powerpc -c -o src/runtime/BCKernel/mutator.o src/runtime/BCKernel/mutator.c gcc -DPOWERPC_DARWIN -m64 -Wall -DVERSION=\"0.7.0-20070213121534-custom\" -DPOWERPC_DARWIN -I. -I/usr/local/include -I/opt/local/include -I/Library/Frameworks/GMP.Framework/Headers -Idepends/ctypes/libffi/include -Idepends/ctypes/libffi/src/powerpc -c -o src/runtime/BCKernel/pretty.o src/runtime/BCKernel/pretty.c gcc -DPOWERPC_DARWIN -m64 -Wall -DVERSION=\"0.7.0-20070213121534-custom\" -DPOWERPC_DARWIN -I. -I/usr/local/include -I/opt/local/include -I/Library/Frameworks/GMP.Framework/Headers -Idepends/ctypes/libffi/include -Idepends/ctypes/libffi/src/powerpc -c -o src/runtime/BCKernel/primitive.o src/runtime/BCKernel/primitive.c gcc -DPOWERPC_DARWIN -m64 -Wall -DVERSION=\"0.7.0-20070213121534-custom\" -DPOWERPC_DARWIN -I. -I/usr/local/include -I/opt/local/include -I/Library/Frameworks/GMP.Framework/Headers -Idepends/ctypes/libffi/include -Idepends/ctypes/libffi/src/powerpc -c -o src/runtime/BCKernel/process.o src/runtime/BCKernel/process.c gcc -DPOWERPC_DARWIN -m64 -Wall -DVERSION=\"0.7.0-20070213121534-custom\" -DPOWERPC_DARWIN -I. -I/usr/local/include -I/opt/local/include -I/Library/Frameworks/GMP.Framework/Headers -Idepends/ctypes/libffi/include -Idepends/ctypes/libffi/src/powerpc -c -o src/runtime/BCKernel/profile.o src/runtime/BCKernel/profile.c gcc -DPOWERPC_DARWIN -m64 -Wall -DVERSION=\"0.7.0-20070213121534-custom\" -DPOWERPC_DARWIN -I. -I/usr/local/include -I/opt/local/include -I/Library/Frameworks/GMP.Framework/Headers -Idepends/ctypes/libffi/include -Idepends/ctypes/libffi/src/powerpc -c -o src/runtime/BCKernel/sanity.o src/runtime/BCKernel/sanity.c src/runtime/BCKernel/sanity.c: In function 'sanity_init': src/runtime/BCKernel/sanity.c:59: warning: format '%d' expects type 'int', but argument 3 has type 'long unsigned int' src/runtime/BCKernel/sanity.c:59: warning: format '%d' expects type 'int', but argument 4 has type 'long unsigned int' gcc -DPOWERPC_DARWIN -m64 -Wall -DVERSION=\"0.7.0-20070213121534-custom\" -DPOWERPC_DARWIN -I. -I/usr/local/include -I/opt/local/include -I/Library/Frameworks/GMP.Framework/Headers -Idepends/ctypes/libffi/include -Idepends/ctypes/libffi/src/powerpc -c -o src/runtime/BCKernel/stable.o src/runtime/BCKernel/stable.c gcc -DPOWERPC_DARWIN -m64 -Wall -DVERSION=\"0.7.0-20070213121534-custom\" -DPOWERPC_DARWIN -I. -I/usr/local/include -I/opt/local/include -I/Library/Frameworks/GMP.Framework/Headers -Idepends/ctypes/libffi/include -Idepends/ctypes/libffi/src/powerpc -c -o src/runtime/BCKernel/stopcopy.o src/runtime/BCKernel/stopcopy.c gcc -DPOWERPC_DARWIN -m64 -Wall -DVERSION=\"0.7.0-20070213121534-custom\" -DPOWERPC_DARWIN -I. -I/usr/local/include -I/opt/local/include -I/Library/Frameworks/GMP.Framework/Headers -Idepends/ctypes/libffi/include -Idepends/ctypes/libffi/src/powerpc -c -o src/runtime/BCKernel/thread.o src/runtime/BCKernel/thread.c src/runtime/BCKernel/thread.c: In function 'yhi_semaphore_create': src/runtime/BCKernel/thread.c:134: warning: comparison between pointer and integer gcc -DPOWERPC_DARWIN -m64 -Wall -DVERSION=\"0.7.0-20070213121534-custom\" -DPOWERPC_DARWIN -I. -I/usr/local/include -I/opt/local/include -I/Library/Frameworks/GMP.Framework/Headers -Idepends/ctypes/libffi/include -Idepends/ctypes/libffi/src/powerpc -c -o src/runtime/BCKernel/builtin/Array.o src/runtime/BCKernel/builtin/Array.c gcc -DPOWERPC_DARWIN -m64 -Wall -DVERSION=\"0.7.0-20070213121534-custom\" -DPOWERPC_DARWIN -I. -I/usr/local/include -I/opt/local/include -I/Library/Frameworks/GMP.Framework/Headers -Idepends/ctypes/libffi/include -Idepends/ctypes/libffi/src/powerpc -c -o src/runtime/BCKernel/builtin/Concurrent.o src/runtime/BCKernel/builtin/Concurrent.c gcc -DPOWERPC_DARWIN -m64 -Wall -DVERSION=\"0.7.0-20070213121534-custom\" -DPOWERPC_DARWIN -I. -I/usr/local/include -I/opt/local/include -I/Library/Frameworks/GMP.Framework/Headers -Idepends/ctypes/libffi/include -Idepends/ctypes/libffi/src/powerpc -c -o src/runtime/BCKernel/builtin/FFI.o src/runtime/BCKernel/builtin/FFI.c gcc -DPOWERPC_DARWIN -m64 -Wall -DVERSION=\"0.7.0-20070213121534-custom\" -DPOWERPC_DARWIN -I. -I/usr/local/include -I/opt/local/include -I/Library/Frameworks/GMP.Framework/Headers -Idepends/ctypes/libffi/include -Idepends/ctypes/libffi/src/powerpc -c -o src/runtime/BCKernel/builtin/IO.o src/runtime/BCKernel/builtin/IO.c gcc -DPOWERPC_DARWIN -m64 -Wall -DVERSION=\"0.7.0-20070213121534-custom\" -DPOWERPC_DARWIN -I. -I/usr/local/include -I/opt/local/include -I/Library/Frameworks/GMP.Framework/Headers -Idepends/ctypes/libffi/include -Idepends/ctypes/libffi/src/powerpc -c -o src/runtime/BCKernel/builtin/IORef.o src/runtime/BCKernel/builtin/IORef.c gcc -DPOWERPC_DARWIN -m64 -Wall -DVERSION=\"0.7.0-20070213121534-custom\" -DPOWERPC_DARWIN -I. -I/usr/local/include -I/opt/local/include -I/Library/Frameworks/GMP.Framework/Headers -Idepends/ctypes/libffi/include -Idepends/ctypes/libffi/src/powerpc -c -o src/runtime/BCKernel/builtin/PackedString.o src/runtime/BCKernel/builtin/PackedString.c gcc -DPOWERPC_DARWIN -m64 -Wall -DVERSION=\"0.7.0-20070213121534-custom\" -DPOWERPC_DARWIN -I. -I/usr/local/include -I/opt/local/include -I/Library/Frameworks/GMP.Framework/Headers -Idepends/ctypes/libffi/include -Idepends/ctypes/libffi/src/powerpc -c -o src/runtime/BCKernel/builtin/Prelude.o src/runtime/BCKernel/builtin/Prelude.c gcc -DPOWERPC_DARWIN -m64 -Wall -DVERSION=\"0.7.0-20070213121534-custom\" -DPOWERPC_DARWIN -I. -I/usr/local/include -I/opt/local/include -I/Library/Frameworks/GMP.Framework/Headers -Idepends/ctypes/libffi/include -Idepends/ctypes/libffi/src/powerpc -c -o src/runtime/BCKernel/builtin/RuntimeAPI.o src/runtime/BCKernel/builtin/RuntimeAPI.c gcc -DPOWERPC_DARWIN -m64 -Wall -DVERSION=\"0.7.0-20070213121534-custom\" -DPOWERPC_DARWIN -I. -I/usr/local/include -I/opt/local/include -I/Library/Frameworks/GMP.Framework/Headers -Idepends/ctypes/libffi/include -Idepends/ctypes/libffi/src/powerpc -c -o src/runtime/BCKernel/builtin/System.o src/runtime/BCKernel/builtin/System.c gcc -Xlinker -lgmp -o inst/bin/yhi src/runtime/BCKernel/basepath.o src/runtime/BCKernel/external.o src/runtime/BCKernel/foreign.o src/runtime/BCKernel/hashtable.o src/runtime/BCKernel/heap.o src/runtime/BCKernel/hsffi.o src/runtime/BCKernel/info.o src/runtime/BCKernel/integer.o src/runtime/BCKernel/iofuncs.o src/runtime/BCKernel/jonkers.o src/runtime/BCKernel/main.o src/runtime/BCKernel/make.o src/runtime/BCKernel/mark.o src/runtime/BCKernel/module.o src/runtime/BCKernel/mutator.o src/runtime/BCKernel/pretty.o src/runtime/BCKernel/primitive.o src/runtime/BCKernel/process.o src/runtime/BCKernel/profile.o src/runtime/BCKernel/sanity.o src/runtime/BCKernel/stable.o src/runtime/BCKernel/stopcopy.o src/runtime/BCKernel/thread.o src/runtime/BCKernel/builtin/Array.o src/runtime/BCKernel/builtin/Concurrent.o src/runtime/BCKernel/builtin/FFI.o src/runtime/BCKernel/builtin/IO.o src/runtime/BCKernel/builtin/IORef.o src/runtime/BCKernel/builtin/PackedString.o src/runtime/BCKernel/builtin/Prelude.o src/runtime/BCKernel/builtin/RuntimeAPI.o src/runtime/BCKernel/builtin/System.o depends/ctypes/libffi/src/prep_cif.o depends/ctypes/libffi/src/cfield.o depends/ctypes/libffi/src/powerpc/ffi_darwin.o depends/ctypes/libffi/src/powerpc/darwin.o depends/ctypes/libffi/src/powerpc/darwin_closure.o -L/usr/local/lib -L/opt/local/lib -L/Library/Frameworks/GMP.Framework -ldl /usr/bin/ld: truncated or malformed archive: /sw/lib/libgmp.a (ranlib structures in table of contents extends past the end of the table of contents, can't load from it) /usr/bin/ld: src/runtime/BCKernel/basepath.o bad magic number (not a Mach-O file) /usr/bin/ld: src/runtime/BCKernel/external.o bad magic number (not a Mach-O file) /usr/bin/ld: src/runtime/BCKernel/foreign.o bad magic number (not a Mach-O file) /usr/bin/ld: src/runtime/BCKernel/hashtable.o bad magic number (not a Mach-O file) /usr/bin/ld: src/runtime/BCKernel/heap.o bad magic number (not a Mach-O file) /usr/bin/ld: src/runtime/BCKernel/hsffi.o bad magic number (not a Mach-O file) /usr/bin/ld: src/runtime/BCKernel/info.o bad magic number (not a Mach-O file) /usr/bin/ld: src/runtime/BCKernel/integer.o bad magic number (not a Mach-O file) /usr/bin/ld: src/runtime/BCKernel/iofuncs.o bad magic number (not a Mach-O file) /usr/bin/ld: src/runtime/BCKernel/jonkers.o bad magic number (not a Mach-O file) /usr/bin/ld: src/runtime/BCKernel/main.o bad magic number (not a Mach-O file) /usr/bin/ld: src/runtime/BCKernel/make.o bad magic number (not a Mach-O file) /usr/bin/ld: src/runtime/BCKernel/mark.o bad magic number (not a Mach-O file) /usr/bin/ld: src/runtime/BCKernel/module.o bad magic number (not a Mach-O file) /usr/bin/ld: src/runtime/BCKernel/mutator.o bad magic number (not a Mach-O file) /usr/bin/ld: src/runtime/BCKernel/pretty.o bad magic number (not a Mach-O file) /usr/bin/ld: src/runtime/BCKernel/primitive.o bad magic number (not a Mach-O file) /usr/bin/ld: src/runtime/BCKernel/process.o bad magic number (not a Mach-O file) /usr/bin/ld: src/runtime/BCKernel/profile.o bad magic number (not a Mach-O file) /usr/bin/ld: src/runtime/BCKernel/sanity.o bad magic number (not a Mach-O file) /usr/bin/ld: src/runtime/BCKernel/stable.o bad magic number (not a Mach-O file) /usr/bin/ld: src/runtime/BCKernel/stopcopy.o bad magic number (not a Mach-O file) /usr/bin/ld: src/runtime/BCKernel/thread.o bad magic number (not a Mach-O file) /usr/bin/ld: src/runtime/BCKernel/builtin/Array.o bad magic number (not a Mach-O file) /usr/bin/ld: src/runtime/BCKernel/builtin/Concurrent.o bad magic number (not a Mach-O file) /usr/bin/ld: src/runtime/BCKernel/builtin/FFI.o bad magic number (not a Mach-O file) /usr/bin/ld: src/runtime/BCKernel/builtin/IO.o bad magic number (not a Mach-O file) /usr/bin/ld: src/runtime/BCKernel/builtin/IORef.o bad magic number (not a Mach-O file) /usr/bin/ld: src/runtime/BCKernel/builtin/PackedString.o bad magic number (not a Mach-O file) /usr/bin/ld: src/runtime/BCKernel/builtin/Prelude.o bad magic number (not a Mach-O file) /usr/bin/ld: src/runtime/BCKernel/builtin/RuntimeAPI.o bad magic number (not a Mach-O file) /usr/bin/ld: src/runtime/BCKernel/builtin/System.o bad magic number (not a Mach-O file) /usr/bin/ld: depends/ctypes/libffi/src/prep_cif.o bad magic number (not a Mach-O file) /usr/bin/ld: depends/ctypes/libffi/src/cfield.o bad magic number (not a Mach-O file) /usr/bin/ld: depends/ctypes/libffi/src/powerpc/ffi_darwin.o bad magic number (not a Mach-O file) collect2: ld returned 1 exit status scons: *** [inst/bin/yhi] Error 1 scons: building terminated because of errors.