Mailing-List: contact cygwin-help AT sourceware DOT cygnus DOT com; run by ezmlm Sender: cygwin-owner AT sourceware DOT cygnus DOT com Delivered-To: mailing list cygwin AT sourceware DOT cygnus DOT com Message-ID: <3793000B.A88D3A3D@cyberbotics.com> Date: Mon, 19 Jul 1999 10:38:20 +0000 From: Emanuele Ornella Reply-To: emanuele DOT ornella AT cyberbotics DOT com Organization: Cyberbotics Ltd. X-Mailer: Mozilla 4.5 (Macintosh; I; PPC) X-Accept-Language: en MIME-Version: 1.0 To: cygwin AT sourceware DOT cygnus DOT com Subject: Function allowed only in Win32 mode !!! Content-Type: text/plain; charset=us-ascii; x-mac-type="54455854"; x-mac-creator="4D4F5353" Content-Transfer-Encoding: 7bit Hi, I'm porting an application from Linux to Windows. I use MSVC++ 6.0 for this. This application is a robot simulator, and the robots are different application that the user can develop in C/C++. The problem is that no everybody (fortunatly) use MSVC, and I want provide with the simulator a free user compiler, like CygWin. So I converted the .dll (using the tool you exlpain in your pages) and so on. What's the problem on this? From the controller program of a robot an user can use some GUI windows and widgets, the same used in the simulator and sotred in some dlls. When a controller is launched, it registers some windows classes, and use these buid-up windows for create the guis. If I compile with CygWin I had an error returned when use the RegisterClass or RegisterClassEx: "This function can be used only on Win32 mode" (something like this; it's a translation) and then crashs. If I compile with MSVC++ this dosen't happen! I try with console application, and with Win32 application, using and not using "-mwindows". I also try to use different class name for the same type of window class. What I thought is that maybe I have to set some flags in the makefile. I also try some examples in which the RegisterClassEx is used (it's really a normal win32 application). So I don't understand why in my application I cannot use it. Maybe it's a problem with DLL (I used impdef.exe utility to create the .def and so on). If you can help me, thank you very much. Here is the makefile NAME = gui LIBRARY = -L../../lib -lController -lKhepera -mwindows CC_OPTS = -c -I../../include -DSIMULATION -Wall $(NAME): $(NAME).o $(CC) -o $(NAME) $(NAME).o $(LIBRARY) $(NAME).o: $(NAME).c $(CC) $(CC_OPTS) $(NAME).c clean: -rm -f *.o *~ $(NAME) -- Emanuele DOT Ornella AT cyberbotics DOT com _________________________________________________________________ C Y B E R B O T I C S Ltd. http://www.cyberbotics.com _________________________________________________________________ Chemin de Valrose 1 CH-1305 PENTHALAZ - Switzerland Tel/Fax: ++41 21 801 31 32 _________________________________________________________________ -- Want to unsubscribe from this list? Send a message to cygwin-unsubscribe AT sourceware DOT cygnus DOT com