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: <199904092044.PAA15648@modi.xraylith.wisc.edu> X-Authentication-Warning: modi.xraylith.wisc.edu: localhost.xraylith.wisc.edu [127.0.0.1] didn't use HELO protocol To: "Richard Ashwell" cc: cygwin AT sourceware DOT cygnus DOT com Subject: Re: EGCS 1.1.2 - Mingw32 - wxWindows 2.0 In-reply-to: Your message of "Fri, 09 Apr 1999 13:10:07 PDT." <19990409201010 DOT 2065 DOT qmail AT hotmail DOT com> Date: Fri, 09 Apr 1999 15:44:34 -0500 From: Mumit Khan "Richard Ashwell" writes: > gcc -Wl,--subsystem,windows -mwindows -Lc:/wx/lib -o test.exe test.o > test_resou > rces.o c:/wx/lib/libwx.a -lstdc++ -lgcc -lwinspool -lwinmm -lshell32 - > lcomctl32 > -lctl3d32 -lodbc32 -ladvapi32 > c:\egcs-1.1.2\lib\libstdc++.a(floatconv.o)(.text+0x12e7): undefined > reference to > `__imp__HUGE_dll' > C:\EGCS-1~1.2\BIN\MAKE.EXE: *** [test.exe] Error 1 Interesting .... The symbol __imp__HUGE_dll is a reference to the symbol HUGE_dll exported by CRTDLL runtime and is in libcrtdll.a. Whenever you link using GCC, it automatically links in -lcrtdll, and so it should always find this symbol. Please check the following: 1. none of the variables are defined in the environment (ie., as DOS variables) -- GCC_EXEC_PREFIX, COMPILER_PATH, LIBRARY_PATH, C_INCLUDE_PATH, CPLUS_INCLUDE_PATH. If these are set, UNSET these first. I don't like hidden surprises. 2. Make sure you're linking with the correct libcrtdll.a: $ gcc -print-file-name=libcrtdll.a should print `c:\egcs-1.1.2\i386-mingw32\lib\libcrtdll.a' 3. Add the `-v' option to gcc when linking to see what's going on. 4. If all of provide no clue, time for some detective work. First check for HUGE_dll in the C++ runtime library: C:\> cd c:/egcs-1.1.2/lib C:\> nm --print-file-name libstdc++.a | nm HUGE libstdc++.a:floatconv.o: U ___imp__HUGE_dll now, check libcrtdll.a: C:\> cd c:/egcs-1.1.2/i386-mingw32/lib C:\> nm --print-file-name libcrtdll.a | nm HUGE libcrtdll.a:ds16.o:00000000 T __HUGE_dll libcrtdll.a:ds16.o:00000000 ? ___imp__HUGE_dll libcrtdll.a:ds16.o:00000000 ? __imp___HUGE_dll If you get something else, there's a problem somewhere. We can talk then. > Despite, the Install instructions for wxWindows which apear old (IE > they had patchs for Mingw32 that when I went to implement where > already there in my version) I didn't setup the environment the way > the install instructions suggested. It appears they wanted me to run > a Batch File like: > > REM > REM replace k:\mingw32 with whatever your installation root may be. > REM > path c:\egcs-1.1.2\bin;%PATH%; > > SET GCC_EXEC_PREFIX=c:\egcs-1.1.2\lib\gcc-lib\ > set BISON_SIMPLE=c:\egcs-1.1.2\share\bison.simple > set BISON_HAIRY=c:\egcs-1.1.2\share\bison.hairy > set C_INCLUDE_PATH=c:\egcs-1.1.2\include > set CPLUS_INCLUDE_PATH=c:\egcs-1.1.2\include\g++;c:\egcs-1.1.2\include > set LIBRARY_PATH=c:\egcs-1.1.2\lib > set GCC_EXEC_PREFIX=c:\egcs-1.1.2\lib\gcc-lib\ Please get rid of all bug BISON_SIMPLE and BISON_HAIRY, but only if you have bison installed. It doesn't come with Mingw compiler distribution. Try not to be frustrated by these problems; these are just part of the learning process, albeit somewhat cruel at times. I have much more trouble when I have to use Visual Studio once in a while to check for something using VC 6; it took me a while one time to figure out why it insisted on linking libpcmtd.lib or some such library no matter what I did until I changed some linker option somewhere ... Regards, Mumit -- Want to unsubscribe from this list? Send a message to cygwin-unsubscribe AT sourceware DOT cygnus DOT com