amd64/71674: static libraries cannot be linked when building shared
libraries
Pete French
pete at twisted.org.uk
Sun Sep 12 10:40:29 PDT 2004
>Number: 71674
>Category: amd64
>Synopsis: static libraries cannot be linked when building shared libraries
>Confidential: no
>Severity: non-critical
>Priority: medium
>Responsible: freebsd-amd64
>State: open
>Quarter:
>Keywords:
>Date-Required:
>Class: sw-bug
>Submitter-Id: current-users
>Arrival-Date: Sun Sep 12 17:40:28 GMT 2004
>Closed-Date:
>Last-Modified:
>Originator: Pete French
>Release: FreeBSD 5.3-BETA4 amd64
>Organization:
>Environment:
System: FreeBSD frenic.drayhouse 5.3-BETA4 FreeBSD 5.3-BETA4 #0: Sun Sep 12 18:04:01 BST 2004 pete at frenic.drayhouse:/usr/obj/usr/src/sys/FRENIC amd64
>Description:
The supplied /usr/lib/libobjc.a has been compiled in such a
way that trying to link when making a shared library gives
the following error:
/usr/bin/ld: /usr/lib/libobjc.a(Protocol.o): relocation R_X86_64_32 can not be used when making a shared object; recompile with -fPIC
/usr/lib/libobjc.a: could not read symbols: Bad value
This did not happen on pre BETA versions. I am unsure as to whether
the linker has changed or what. This may apply to all the static
libraries in /usr/lib though! I have tried with libz.a and libufs.a
with the same error.
>How-To-Repeat:
In this instance I was trying to build the GNUstep base libraries.
But trying to make a very simple shared library, linking against
static libraries in /usr/lib, will show it up.
>Fix:
Preseumably fix buildworld so that static libraries are compiled
with -fPIC ? This also applies to static libraries built from
ports.
>Release-Note:
>Audit-Trail:
>Unformatted:
More information about the freebsd-amd64
mailing list