From: Jorrit DOT Tyberghein AT uz DOT kuleuven DOT ac DOT be (Jorrit Tyberghein) Subject: Creation of dynamic object 6 Nov 1998 18:26:54 -0800 Message-ID: <3641B49C.EF2B1045.cygnus.gnu-win32@uz.kuleuven.ac.be> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit To: gnu-win32 AT cygnus DOT com Hi, I'm using the new CygWin B20 and try to create a dynamic object (not a DLL) which I can access from another executable with dlopen and dlsym. On Unix I would create this (linking stage) with: g++ -Wl -shared -o dynobj.so obj_file1.o obj_file2.o obj_file3.o ... -l... But with CygWin B20 I get the following errors: g++: unrecognized option `-shared' C:\cygnus\CYGWIN~1\H-I586~1\bin\..\lib\gcc-lib\i586-cygwin32\egcs-2.91.57\..\..\ ...\..\i586-cygwin32\lib/libcygwin.a(libcmain.o)(.text+0x58):libcmain.cc: undefined reference to `WinMain AT 16' So first gcc doesn't seem to recognize the -Wl option so that the '-shared' option goes to the linker. And of course in that case I have the problem that it seems to need WinMain which is obviously not included in the objects. How can I fix this? Note that I DON'T want to make a DLL. Greetings and thanks in advance, -- ============================================================================== Jorrit DOT Tyberghein AT uz DOT kuleuven DOT ac DOT be, University Hospitals KU Leuven BELGIUM No-one would have believed, in the final years of the Century of the Fruitbat, that Discworld affairs were being watched keenly and impatiently by intelligences greater than Man's, or at least much nastier; that their affairs were being scrutinised and studied as a man with a three-day appetite might study the All-You-Can-Gobble-For-A-Dollar menu outside Harga's House of Ribs... -- (Terry Pratchett, Moving Pictures) ============================================================================== - For help on using this list (especially unsubscribing), send a message to "gnu-win32-request AT cygnus DOT com" with one line of text: "help".