Link with GCC object files

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Link with GCC object files

AndreasGMail
Hi, I have a question. Is it possible to link FPC for Linux (PC and ARM)
with GCC or other C++ object files?

Regards,
Andreas Berger


_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: Link with GCC object files

Free Pascal - General mailing list
Andreas <[hidden email]> schrieb am Mi., 22. Aug. 2018, 12:59:
Hi, I have a question. Is it possible to link FPC for Linux (PC and ARM)
with GCC or other C++ object files?

If you use C++ it's recommended to use "extern "C"" however even though FPC supports cppdecl (as it can't handle all cases currently). And classes won't work either. 

Regards, 
Sven 

_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: Link with GCC object files

Andreas Berger

Thank you Sven, this will be a big help

Regards,
Andreas


On 22/08/2018 12:12, Sven Barth via fpc-pascal wrote:
Andreas <[hidden email]> schrieb am Mi., 22. Aug. 2018, 12:59:
Hi, I have a question. Is it possible to link FPC for Linux (PC and ARM)
with GCC or other C++ object files?

If you use C++ it's recommended to use "extern "C"" however even though FPC supports cppdecl (as it can't handle all cases currently). And classes won't work either. 

Regards, 
Sven 


_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal


_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal