[fpc-pascal] Shared libries

noreply at z505.com noreply at z505.com
Mon Dec 12 00:48:07 CET 2011


> Ok, thanks for clearifying that. I guess it's going to be a lot of
> include files instead... :)
>
> -Torsten.


Why do you need include files in your case?
You can put the units in the uses clause of your library.

library something;

uses
  someunit;

exports
  someunit.yourproc;

end.

The someunit. prefix is optional.

In newer versions of FPC it allows you to put an exports clause in the
unit itself, but older versions didn't allow it.

http://62.166.198.202/bug_view_page.php?bug_id=4398&history=1

In delphi 1.0 the export directive meant something different which causes
confusion. Borland made export directive obsolete but kept the export
keyword there probably for compiling old code. fpc has slightly different
reasons for the export directive than delphi and lots of confusion arises.




More information about the fpc-pascal mailing list