bug-prolog
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Linking errors from gplc with ld 2.28


From: Jasper Taylor
Subject: Linking errors from gplc with ld 2.28
Date: Fri, 21 Jul 2017 11:25:59 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.8.0

I just upgraded my Debian box from Jessie to Stretch and I find I can no longer use gplc to convert Prolog code into executables. I get a lot of error messages starting as follows...

/usr/bin/ld: /tmp/gplcMP1nIg.o: relocation R_X86_64_32S against `.text' can not be used when making a shared object; recompile with -fPIC /usr/bin/ld: /usr/local/gprolog-1.4.4/lib/all_pl_bips.o: relocation R_X86_64_32S against `.text' can not be used when making a shared object; recompile with -fPIC /usr/bin/ld: /usr/local/gprolog-1.4.4/lib/all_fd_bips.o: relocation R_X86_64_32S against `.text' can not be used when making a shared object; recompile with -fPIC
.

.

/usr/bin/ld: final link failed: Nonrepresentable section on output
collect2: error: ld returned 1 exit status
compilation failed

The first line refers to the object file generated from the Prolog code, subsequent lines to objects included in the gprolog installation. Debian Stretch includes ld version 2.28, while systems on which gplc works properly include ld version 2.25.

Adding -C '-fPIC' makes no difference, presumably because the c compiler is not used when converting Prolog code to executable. Adding -A -'fPIC' produces an error message from the assembler, presumably because position-independence is determined in the assembly language code and cannot be added by the assembler.

I get similar errors attempting to recompile gprolog on the new system. Does anyone know what is going on?

    --Jasper





reply via email to

[Prev in Thread] Current Thread [Next in Thread]