[fpc-devel] What is CreateFileMapping?

Gilles MARCOU g.marcou at chimie.u-strasbg.fr
Thu Dec 11 19:39:51 CET 2008


Hi,

I am converting a small project from Delphi to Free Pascal. I am working
on a Linux (Debian) box. In several places, the software seems to call
to external applications an uses this kind of command:

var
  smfMemHnd : HWND; 
...
smfMemHnd := CreateFileMapping(HWND($FFFFFFFF), nil, PAGE_READWRITE, 0,
memFileSize , memFileName);

Free Pascal seems unable to find the function CreateFileMapping. While
browsing the RTL, this function seems to be part of some Windows related
library.

I have two questions:

1/ Which unit shall I add to my .pas file for FPC to find this function?
2/ If this is Windows specific, how do I manage this on other
architectures?

thanks in advance for your help,
Gilles Marcou






More information about the fpc-devel mailing list