[fpc-devel] compile fpc for i386 from a 64 bit machine

Alvise Nicoletti alvise.nicoletti at siteland.it
Fri Nov 30 12:07:11 CET 2007


Daniël Mantione ha scritto:
> Op Thu, 29 Nov 2007, schreef Alvise Nicoletti:
>
>   
>> I added a /usr/lib32 link to the fpc.cfg, however I have no "crti.o" in the
>> /usr/lib32/ folder.
>> I got the same error trying to cross-compile to a i386 target.
>>
>> /usr/lib/crti.o is a "ELF 64-bit LSB relocatable, AMD x86-64, version 1
>> (SYSV), not stripped"
>>
>> Who should compile/provide that library at 32 bits?
>>     
>
> Your distro.
>   
There I see only the 64 bit libs, I will try to ask in some ubuntu forum 
if I can install also the 32 bit libs without destroying  the server (as 
I did yesterday cause I moved with "mv" a lib that was required by "mv" 
itself, restoring it this morning with a live cd).

Also now I have that error while linking at 64 bits (even if I 
reinstated the original configuration/situation):
/usr/lib/fpc/2.2.1/units/x86_64-linux/rtl/cthreads.o: In function 
`CTHREADS_LOADPTHREADS$$BOOLEAN':cthreads.pp:(.text+0x11): warning: 
Using 'dlopen' in statically linked applications requires at runtime the 
shared libraries from the glibc version used for linking
/usr/bin/../lib/libdl.a(dlopen.o): In function `dlopen': undefined 
reference to `__dlopen'
/usr/bin/../lib/libdl.a(dlclose.o): In function `dlclose': undefined 
reference to `__dlclose'
/usr/bin/../lib/libdl.a(dlsym.o): In function `dlsym': undefined 
reference to `__dlsym'
PoolPatrol.lpr(185,1) Error: Error while linking
PoolPatrol.lpr(185,1) Fatal: There were 1 errors compiling module, stopping

That's probably the end of that computer lazarus installation, I can't 
risk to mess up the libs again.

Thank you for the support, it's a pity that I was so close.

p.s. the wiki guide should be a little updated.

> Daniël
>
>   
>> p.s. so I will have to change the fpc.cfg every time I want to crosscompile?
>> or there is a IFDEF(initive) solution?
>>     
>
> You can add both directories, the linker will skip the unusable one. If 
> constructions are also possible by the way.
>
> Daniël
> ------------------------------------------------------------------------
>
> _______________________________________________
> fpc-devel maillist  -  fpc-devel at lists.freepascal.org
> http://lists.freepascal.org/mailman/listinfo/fpc-devel
>   
> ------------------------------------------------------------------------
>
> No virus found in this incoming message.
> Checked by AVG Free Edition. 
> Version: 7.5.503 / Virus Database: 269.16.9/1158 - Release Date: 28/11/2007 21.11
>   



More information about the fpc-devel mailing list