64 bit porting problem

Linux specific forum
User avatar
mariosk8s
Enthusiast
Enthusiast
Posts: 103
Joined: Wed Apr 06, 2011 11:37 am
Location: Hüfingen, Germany
Contact:

64 bit porting problem

Post by mariosk8s »

I have code that builds a shared library. It compiles and works fine under 32 bit pb 5.10+ linux mac and windows
When i try to build it on 64bit linux pb 5.10 or 5.11 i get the following.

Code: Select all

pbcompiler -u -t -so libfoo.so libfoo.pb

******************************************
PureBasic 5.11 (Linux - x64)
******************************************

Loading external modules...
Starting compilation...
Including source: ....
[snip...]
16814 lines processed.
Creating the executable.
Error: Linker
/usr/bin/ld.bfd.real: /usr/local/purebasic/compilers/unicodefunctions.a(swprintf.o): relocation R_X86_64_32 against `.text' can not be used when making a shared object; recompile with -fPIC
/usr/local/purebasic/compilers/unicodefunctions.a: could not read symbols: Bad value
collect2: ld returned 1 exit status
Is there any way i can debug this, other than to start commenting out thousands of lines of code until it goes away?
User avatar
ts-soft
Always Here
Always Here
Posts: 5756
Joined: Thu Jun 24, 2004 2:44 pm
Location: Berlin - Germany

Re: 64 bit porting problem

Post by ts-soft »

PureBasic 5.73 | SpiderBasic 2.30 | Windows 10 Pro (x64) | Linux Mint 20.1 (x64)
Old bugs good, new bugs bad! Updates are evil: might fix old bugs and introduce no new ones.
Image
Post Reply