Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / fpc-pascal / 2018-08

Link with GCC object files

3 messages · 3 people ·

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Andreas

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

Reply by email

Sven Barth
to Andreas

Andreas 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?

You can use the $L directive for this (
https://freepascal.org/docs-html/current/prog/progsu43.html#x50-490001.2.43 ).
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

Reply by email

Andreas Berger
to Sven Barth

Thank you Sven, this will be a big help

Regards,
Andreas

Sven Barth wrote 23 lines
Andreas < > 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? You can use the $L directive for this ( https://freepascal.org/docs-html/current/prog/progsu43.html#x50-490001.2.43 ). 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 - http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

Reply by email