Article View: gnu.gcc.help
Article #51121Re: gcc-2.4.5: undefined symbol: __lib_version on SunOS
From: Justin Mason
Date: Fri, 02 Jul 1993 17:07
Date: Fri, 02 Jul 1993 17:07
30 lines
1700 bytes
1700 bytes
west@lux.tsd.itg.ti.com (Roger West) writes: > gcc tRational.o -o tRational ../libg++.a -lm > ld: Undefined symbol > __lib_version > collect: ld returned 2 exit status Have you got the SparcCompiler 2.0.1 CD-ROM installed? If you do, and you have LD_LIBRARY_PATH set, and /usr/lang/SC2.0.1 is in LD_LIBRARY_PATH, this is why. LD_LIBRARY_PATH, unfortunately, is used by both the dynamic linker (ld.so) and the normal linker (ld); LD_LIBRARY_PATH is probably set on your system so you can use SC2.0.1's shared libraries. /usr/lang/SC2.0.1/libm.a is being picked up before /usr/lib/libm.a, and, of course, the SC libm has a U __lib_version in powf.o. Just put a -L/usr/lib on your command line, and hey presto! No more being the victim of SunOS 4.1.2's bad linker setup! :) -- justin. -- Justin Mason (Iona Technologies' unix caretaker, fixer-upper and disk-filler) <jm@maths.tcd.ie> -- play (I read news here) -><- phone: +353-1-6790677 <jmason@iona.ie> -- work (MIME spoken here) -><- fax: +353-1-6798039
Technical Details
Message-ID:
<1993Jul2.170740.4848@maths.tcd.ie>Path:
arc1-ca.pugleaf.net!gmd.de!newsserver.jvnc.net!howland.reston.ans.net!agate!doc.ic.ac.uk!uknet!mcsun!ieunet!tcdcs!maths.tcd.ie!jmReferences:
<WEST.93Jun30123532@lux.tsd.itg.ti.com>Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 11318c,e37eef784c9bc381 X-Google-Attributes: gid11318c,public X-Google-ArrivalTime: 1993-07-02 10:43:40 PST Newsgroups: gnu.gcc.help Path: arc1-ca.pugleaf.net!gmd.de!newsserver.jvnc.net!howland.reston.ans.net!agate!doc.ic.ac.uk!uknet!mcsun!ieunet!tcdcs!maths.tcd.ie!jm From: jm@maths.tcd.ie (Justin Mason) Subject: Re: gcc-2.4.5: undefined symbol: __lib_version on SunOS Organization: Universal Media Netweb (Ireland) Inc. Date: Fri, 2 Jul 1993 17:07:40 GMT Message-ID: <1993Jul2.170740.4848@maths.tcd.ie> References: <WEST.93Jun30123532@lux.tsd.itg.ti.com> Lines: 30