Can't compile win32-library lazarus / 8-Other ---------------------------------------------------------------------- Knoppers · 2005-11-17 13:27 Hi there, can anyone help me compiling this simple dll-code with lazarus? Code: [Select]library project1; {$mode objfpc}{$H+} uses   SysUtils; function Test: PChar; begin   Result := StrNew( 'Test' ); end; exports   Test; begin end. Compiling this I get the message: ..\lazarus\pp\i386-win32\rtl\wdllprt0.o(.test+0x1b):fake: undefined reference to 'U_SYSTEM_HINSTANCE' project.lpr(17,1) Error: Error while linking please help me, Jan[/code] ---------------------------------------------------------------------- felipemdc · 2005-11-18 08:46 What is the version of your Lazarus?? And your operating system? Very strange error ..... works here. Did you install Lazarus correctly? With that I mean in a directory witch contains no spaces in it´s name. ---------------------------------------------------------------------- Anonymous · 2005-11-18 09:09 The Lazarus version is 0.9.10 beta, date 02.10.2005. Operating System: winXP SP2 I think I installed Lazarus correctly. I used the standard directory. In the (script) file wdllprt0.o there is an identifier named U_SYSTEM_HINSTANCE. I think its definition was not found. ---------------------------------------------------------------------- matthijs · 2005-11-18 09:41 When I use Lazarus 0.9.11 from 04-11-2005 the library compiles without any error messages. Maybe you did not start with the proper application type. Select Project -> New Project -> Custom Program. ---------------------------------------------------------------------- Anonymous · 2005-11-18 10:15 I tried Select Project->New Project->Custom Program. It still doesn't work. so I try to update Lazarus and give you the result, thx so far ---------------------------------------------------------------------- Anonymous · 2005-11-18 11:35 the version update from 0.9.10b to 0.9.11 solved the problem. now I can compile the dll. but the output file is an exe-file. now i have to proof if it is an dll anyway :-) ---------------------------------------------------------------------- Marc · 2005-11-21 13:37 on win32 there isn't much difference between an .exe or a .dll except for the extentionname. Both can execute code and both can export functions. ---------------------------------------------------------------------- Lawrence · 2005-12-21 12:19 Quote from: "Anonymous"the version update from 0.9.10b to 0.9.11 solved the problem. now I can compile the dll. but the output file is an exe-file. now i have to proof if it is an dll anyway :-) why can i see the 0.9.11 anywhere ? i've just downloaded the win32 binaries wich come with the 0.9.10b version. Can you help me find the 0.9.11 ? I have the same behaviour when compiling un library. thanks ---------------------------------------------------------------------- JanH · 2005-12-21 12:46 take a look at http://www.de.freepascal.org//lazarus/ but read the BEWARE on this site. ---------------------------------------------------------------------- Anonymous · 2005-12-21 17:23 Quote from: "JanH"take a look at http://www.de.freepascal.org//lazarus/ but read the BEWARE on this site. Thanks a lot. I'll search more next time. And sorry again. ---------------------------------------------------------------------- SergKam · 2005-12-21 21:05 ..\lazarus\pp\i386-win32\rtl\wdllprt0.o(.test+0x1b) I have same problems. it is FPC bug not lazarus fpc 1.9.8 OK fpc 2 ERR fpc 2.1 ERR fpc 2.1.1 OK(i think) all in same LAZARUS 0.9.11 ---------------------------------------------------------------------- Anonymous · 2006-01-05 22:39 Hi! I have the same problem, and i found this: http://www.freepascal.org/bugs/showrec.php3?ID=4395 This bug is fixed So i have to update my system too. Bye!