"Steven G. Kargl" wrote: > This commit by Peter breaks 3rd party software: > > Revision 1.48 / (download) - annotate - [select for diffs], \ > Fri Oct 11 22:38:17 2002 UTC (18 hours, 14 minutes ago) by peter > Branch: MAIN > Changes since 1.47: +0 -8 lines > Diff to previous 1.47 (colored) > > Zap the early-adopter transition aid before we get into serious > 5.0-R territory, as threatened. This only affects antique 5.0 > systems that have not had a 'make world' done for well over a year. > > In particular, NAG's Fortran 95 compiler on longer works.
The problem is that you're trying to mix 4.x binaries with 5.x components. This really needs to be linked against the 4.x libraries. More below.. > kargl[203] make > f95 -O -C=all -o testchkder chkdrv.f90 -L. -lminpack > /usr/local/lib/NAGWare/libf96.so: undefined reference to `__sF' > collect2: ld returned 1 exit status > *** Error code 1 > > I've tried passing numerous combinations of flags directly to > gcc with the -Wc (compiler options) and -Wl (linker options) > to f95 (including -L/usr/lib/compat, -nostdlib, and -v). See > below for two examples. The reason why this is not working is because ld looks at .a and .so files only. It will not link with libc.so.4, only libc.so. We only provide /usr/lib/compat/libc.so.4 for runtime compatability, not compile time compatability. Here's something to try: mkdir /somewhere/lib cd /somewhere/lib ln -s /usr/lib/compat/libc.so.4 ./libc.so ... repeat ... And in your flags, try -nostdlib, -L/somewhere/lib. Hopefully you can cause the search order to find /somewhere/lib/libc.so and hence link against /usr/lib/compat/libc.so.4. It will record a dependency against libc.so.4 in the resulting binary so you only need these gymnastics for compile time. At runtime, ld.so knows to find libc.so.4 in /usr/lib/compat. Note at the very end of these messages the references to "/usr/lib/libc.so".. That is the problem. The crt*.o files should probably be taken care of too, but in this case it should be ok. We probably need a package or something to build a proper 4.x compile environment. Includes, library links etc, everything. > No amount of gymnastics has worked around this problem. > Finally, the NAG compiler was released for 4.x, and > it may be difficult to convince 3rd party software vendors > to support both 4.x and 5.0. > > -- > Steve > http://troutmask.apl.washington.edu/~kargl/ > > cript started on Sat Oct 12 10:25:53 2002 > f95 -O -C=all -o testchkder -Wc,-v -Wl,-v -Wc,-nostdlib -Wl,-nostdlib chkdrv. f90 -L. -L/usr/lib/c > ompat -lminpack -lm -lc > Using built-in specs. > Configured with: FreeBSD/i386 system compiler > Thread model: posix > gcc version 3.2.1 [FreeBSD] 20021009 (prerelease) > /usr/libexec/cc1 -lang-c -v -I/usr/local/lib/NAGWare -D__GNUC__=3 -D__GNUC_M INOR__=2 -D__GNUC_PA > TCHLEVEL__=1 -D__GXX_ABI_VERSION=102 -D__FreeBSD__=5 -D__FreeBSD_cc_version=5 00004 -Dunix -D__KPR > INTF_ATTRIBUTE__ -D__FreeBSD__=5 -D__FreeBSD_cc_version=500004 -D__unix__ -D_ _KPRINTF_ATTRIBUTE__ > -D__unix -Asystem=unix -Asystem=bsd -Asystem=FreeBSD -D__OPTIMIZE__ -D__STDC _HOSTED__=1 -Acpu=i3 > 86 -Amachine=i386 -Di386 -D__i386 -D__i386__ -D__tune_i386__ -D__ELF__ -D_LON GLONG -DBSD -DANSI_C > -DINT64=long long -DPOW_IS_INACCURATE /var/tmp/chkdrv.026087.c -quiet -dumpb ase chkdrv.026087.c > -O -version -fsigned-char -funroll-loops -o /var/tmp/cc9AAdTR.s > GNU CPP version 3.2.1 [FreeBSD] 20021009 (prerelease) (cpplib) (i386 FreeBSD/ ELF) > GNU C version 3.2.1 [FreeBSD] 20021009 (prerelease) (i386-undermydesk-freebsd ) > compiled by GNU C version 3.2.1 [FreeBSD] 20021009 (prerelease). > ignoring duplicate directory "/usr/include" > #include "..." search starts here: > #include <...> search starts here: > /usr/local/lib/NAGWare > /usr/include > End of search list. > /usr/libexec/elf/as -v -o chkdrv.o /var/tmp/cc9AAdTR.s > GNU assembler version 2.12.1 [FreeBSD] 2002-07-20 (i386-obrien-freebsd5.0) us ing BFD version 2.12 > .1 [FreeBSD] 2002-07-20 > Using built-in specs. > Configured with: FreeBSD/i386 system compiler > Thread model: posix > gcc version 3.2.1 [FreeBSD] 20021009 (prerelease) > /usr/libexec/collect2 -V -dynamic-linker /usr/libexec/ld-elf.so.1 -o testchk der -L. -L/usr/lib/c > ompat -L/usr/lib /usr/local/lib/NAGWare/quickfit.o chkdrv.o -lminpack -lm -lc -rpath /usr/local/l > ib/NAGWare /usr/local/lib/NAGWare/libf96.so /usr/local/lib/NAGWare/libf96.a - lm > /usr/libexec/elf/ld: warning: cannot find entry symbol _start; defaulting to 08048d1c > /usr/lib/libc.so: undefined reference to `environ' > /usr/lib/libc.so: undefined reference to `__progname' > /usr/local/lib/NAGWare/libf96.so: undefined reference to `__sF' > GNU ld version 2.12.1 [FreeBSD] 2002-07-20 > Supported emulations: > elf_i386 > collect2: ld returned 1 exit status > Cheers, -Peter -- Peter Wemm - [EMAIL PROTECTED]; [EMAIL PROTECTED]; [EMAIL PROTECTED] "All of this is for nothing if we don't go to the stars" - JMS/B5 To Unsubscribe: send mail to [EMAIL PROTECTED] with "unsubscribe freebsd-current" in the body of the message