[fpc-devel]Exporting variables in libraries for Linux / FreeBSD

Maarten Bekers elevator at planet.nl
Sat Feb 15 10:24:25 CET 2003

hi Peter,

> >it will compile on Win32, but just refuse to compile on Linux. When you
> >search on the error the compiler generates, you'll find the docs that
> >explain that exporting of variables is only supported on Win32.
> Under linux it is not supported because linux works different with shared
> libraries. For procedures we could add an extra jmp with the new name. But
> for variables it's not possible as for the imported variables it is not
> know if they need an extra derefence (that is what WIn32 is using for dll
> variables) or that they need to be imported bij the dynamic linker.
I see. Is there any chance of getting this feature implemented, or would it
be better to try to write a library in C that in turn uses my library in FPC
to provide the functionality that it should?

groeten, Maarten.

More information about the fpc-devel mailing list