[ooc-compiler] Interface mod.: undef. ref. to win32 API proc.
Brought to you by:
mva
|
From: Frank H. <fh...@ph...> - 2004-05-25 18:34:42
|
Doing my first steps with oo2c under MinGW, I wrote an interface module
which begins like this:
MODULE IFserial [INTERFACE "C"; LINK LIB "kernel32" END];
and which contains:
PROCEDURE CreateFile*
(name:ARRAY OF LONGCHAR;
accessMode,shareMode:SET;
secAttr:lpSecAttr; create,attr:DWORD; template:HANDLE
): HANDLE;
This module is imported by another one, "Serial.Mod". Both compile, but
the linker produces an error message:
obj/Serial.o(.text+0x8d):Serial.c: undefined reference to `CreateFile'
I am somewhat overwhelmed by the amount of information contained in
OOCRef, Win32-SDK-Help, MinGW and other documentation. So if someone
could give me a hint.
-----------------------------------------------------------
Frank Hrebabetzky Tel.: +55/48/239-2258
Photonita Ltda Fax: +55/48/239-2200
Parque Tec. Alfa - Ed. CELTA
Florianopolis, SC
88030-000
Brasil
|