64 bit porting problem
Posted: Wed Apr 03, 2013 1:03 pm
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.
Is there any way i can debug this, other than to start commenting out thousands of lines of code until it goes away?
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