compiling with static libs for darwin breaks during compile with the following message. MLIBS=`/home/hanwen/vc/gub/target/darwin-x86/build/gcc-4.1.0/./gcc/xgcc -B/home/hanwen/vc/gub/target/darwin-x86/build/gcc-4.1.0/./gcc/ -B/home/hanwen/vc/gub/target/darwin-x86/system/usr/cross//i686-apple-darwin8/bin/ -B/home/hanwen/vc/gub/target/darwin-x86/system/usr/cross//i686-apple-darwin8/lib/ -isystem /home/hanwen/vc/gub/target/darwin-x86/system/usr/cross//i686-apple-darwin8/include -isystem /home/hanwen/vc/gub/target/darwin-x86/system/usr/cross//i686-apple-darwin8/sys-include --print-multi-lib \ | sed -e 's/;.*$//' -e '/^\.$/d' -e 's/^/_/'` ; \ for mlib in '' $MLIBS ; do \ i686-apple-darwin8-strip -o libgcc_s.10.4.dylib_T${mlib} \ -s /home/hanwen/vc/gub/target/darwin-x86/src/gcc-4.1.0/gcc/config/i386/darwin-libgcc.10.4.ver -c -u \ libgcc_s${mlib}.1.dylib || exit 1 ; \ done i686-apple-darwin8-strip: can't open file: libgcc_s.1.dylib (No such file or directory) make[3]: *** [libgcc_s.10.4.dylib] Fout 1 make[3]: Leaving directory `/home/hanwen/vc/gub/target/darwin-x86/build/gcc-4.1.0/gcc' make[2]: *** [all-gcc] Fout 2
Related to PR 19176. But static is almost never supported on Darwin anyways.
I should mention that i686-darwin is not supported in any way shape or form for GCC's before 4.2.0.
I guess that means that 4.2 snapshots don't count, and that I should stick to Apple's sources, right?
*** Bug 29564 has been marked as a duplicate of this bug. ***
Caused by: 2005-09-28 Geoffrey Keating <geoffk@apple.com> * config/rs6000/t-darwin8: Uncomment contents, allow -m64 multilib to be built. * Makefile.in: Export LIPO_FOR_TARGET, STRIP_FOR_TARGET. (stage1-start): Delete old libgcc and libunwind before moving anything into the stage directory. (stage2-start): Likewise. (stage3-start): Likewise. (stage4-start): Likewise.
I tried to disable the multilib with - ../gcc/configure --disable-shared --disable-multilib --prefix=/usr/local/gfortran --enable-languages=c,fortran but I still about the save errors - MLIBS=`/Users/dir/gfortran/ibin2/./gcc/xgcc -B/Users/dir/gfortran/ibin2/./gcc/ -B/usr/local/gfortran/powerpc-apple-darwin8.8.0/bin/ -B/usr/local/gfortran/powerpc-apple-darwin8.8.0/lib/ -isystem /usr/local/gfortran/powerpc-apple-darwin8.8.0/include -isystem /usr/local/gfortran/powerpc-apple-darwin8.8.0/sys-include --print-multi-lib \ | sed -e 's/;.*$//' -e '/^\.$/d'` ; \ for mlib in '' $MLIBS ; do \ strip -o libgcc_s.10.5.dylib_T${mlib} \ -s ../../gcc/gcc/config/rs6000/darwin-libgcc.10.5.ver -c -u \ ./${mlib}/libgcc_s.1.dylib.tmp || exit 1 ; \ done strip: can't open file: /Users/dir/gfortran/ibin2/gcc/libgcc_s.1.dylib.tmp (No such file or directory) make[3]: *** [libgcc_s.10.4.dylib] Error 1 make[3]: *** Waiting for unfinished jobs.... strip: can't open file: /Users/dir/gfortran/ibin2/gcc/libgcc_s.1.dylib.tmp (No such file or directory) make[3]: *** [libgcc_s.10.5.dylib] Error 1 rm fsf-funding.pod gcov.pod gfdl.pod cpp.pod gpl.pod gcc.pod make[2]: *** [all-stage1-gcc] Error 2 make[1]: *** [stage1-bubble] Error 2 make: *** [all] Error 2 [dranta:~/gfortran/ibin2] dir%
I think I'll just declare that GCC requires a shared libgcc on Darwin.
Fixing the errors that are shown above is trivial - so I assume that they are just the first of a cascade of errors in trying to fix the problem. Having a shared libgcc is Ok - the real problem is distributing version of programs compilied with gfortran to people that do not have gfortran installed. --disable-shared appears to be the only way to do it - I tried just loading the static libraries, but a few dependencies on the shared parts remained.
*** Bug 19176 has been marked as a duplicate of this bug. ***
This is no problem with g95. You can move files to other Macintosh computers without g95 istalled and use them. This really is quite important, the usefulness of gfortran is greatly limited without this ablity. Programs built with gfortran cannot be distributed to a general group of users.
(In reply to comment #10) > This is no problem with g95. That is because g95's library is not fully integrated at all in GCC's build infrastructure at all. You can use just disable's gfortran shared library anyways, See the installation documentation which describes how to do that.
Hi Andrew, I thought that was the problem - there appears to be no way to disable the shared libraries on the Macintosh. In comment #6, I tried to disable the shared libraries and the multilib with "--disable-shared --disable-multilib". Where do I find the installation documentation ? Does the installation documentation tell another way to do it ?