Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / fpc-pascal / 2009-10

FPC 2.3.1: undefined reference to `fpc_geteipasebx'

3 messages · 2 people ·

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Matthias Klumpp

Hello!
I use FPC 2.3.1 to let FPC compile shared libraries with PIC code. (PIC support is broken in FPC 2.2.4)
My shared lib compiles successful, but if I compile a project which uses this library, I get this:

Linking build/project1
/usr/bin/ld: warning: bin/link.res contains output sections; did you forget -T?
./libipkinject.so: undefined reference to `fpc_geteipasebx' project1.lpr(42,1) Error: Error while linking

Do you have any idea why this happens? The project compiles successfully on the AMD64 architecture, but not on i386.

(Tested under Linux, Ubuntu 9.10, Fedora 12)

Reply by email

Jonas Maebe
to Matthias Klumpp
Matthias Klumpp wrote 8 lines
Linking build/project1 /usr/bin/ld: warning: bin/link.res contains output sections; did you forget -T? ./libipkinject.so: undefined reference to `fpc_geteipasebx' project1.lpr(42,1) Error: Error while linking Do you have any idea why this happens?

This currently happens if you compile the library with smart linking on Linux/i386 with PIC. Disable smart linking and it will work fine. This will be fixed in a future release (but not in 2.4.0).

The project compiles successfully on the AMD64 architecture, but not on i386.

x86_64 uses a completely different mechanism for PIC than i386.

Jonas

Reply by email

Matthias Klumpp
to Jonas Maebe
Jonas Maebe wrote 22 lines
On 20 Oct 2009, at 16:43, Matthias Klumpp wrote: > Linking build/project1 > /usr/bin/ld: warning: bin/link.res contains output sections; did you > forget > -T? > ./libipkinject.so: undefined reference to `fpc_geteipasebx' > project1.lpr(42,1) Error: Error while linking > > Do you have any idea why this happens? This currently happens if you compile the library with smart linking on Linux/i386 with PIC. Disable smart linking and it will work fine. This will be fixed in a future release (but not in 2.4.0). > The project compiles successfully on > the AMD64 architecture, but not on i386. x86_64 uses a completely different mechanism for PIC than i386. Jonas

Thank you!

Reply by email