[fpc-devel] Safecall on Linux (and other unices?)

Michael Van Canneyt michael at freepascal.org
Wed Jul 21 12:57:50 CEST 2010



On Wed, 21 Jul 2010, Joost van der Sluis wrote:

> On Wed, 2010-07-21 at 18:41 +0800, Paul Ishenin wrote:
>> 21.07.2010 17:41, Michael Van Canneyt wrote:
>>>> How Kylix handles the safecall convention on linux? I think we need
>>>> to follow it.
>>> Is it an idea to change the 'safecall' convention on Linux/i386 to be
>>>
>>> Well,
>>>
>>> Safecall = cdecl for Kylix.
>>>
>>> Borland decided to do this instead of giving a compiler error.
>>> But since Kylix is long dead, I don't see the need to follow it in
>>> this detail. Or do you know a lot of kylix programs/code/libraries out
>>> there ?
>> When (if) codegear release the new linux compiler I think they reuse
>> their kylix work. So if we follow the kylix way now we will protect the
>> compiler from the unneeded changes in the future.
>>
>> Is there a big difference for fpc to call the new calling convention
>> different and map it to safecall on windows?
>
> I don't think we have to look at Kylix in this regard. When Kylix was
> released there was no such thing as 'com/activex' on Linux, so the whole
> safecall thing was useless. Only now there is xpcom it gets a meaning.

Exactly.

Michael.



More information about the fpc-devel mailing list