Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com Date: Sun, 1 Feb 2004 17:34:27 -0700 From: Sean LeBlanc To: Cygwin List Subject: Re: Linking problems Message-ID: <20040202003427.GA26776@smtp.americanisp.net> References: <20040201174043 DOT GA20082 AT smtp DOT americanisp DOT net> <6 DOT 0 DOT 1 DOT 1 DOT 0 DOT 20040201181337 DOT 038aab60 AT 127 DOT 0 DOT 0 DOT 1> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <6.0.1.1.0.20040201181337.038aab60@127.0.0.1> User-Agent: Mutt/1.4.1i X-IsSubscribed: yes On 02-01 18:16, Larry Hall wrote: > At 12:40 PM 2/1/2004, Sean LeBlanc you wrote: > >Hi all. I'm currently having troubles linking against a lib. The signature > >it complains about certainly shows up when I search the lib. I have been > >able to build against other libs in the same set (MS' Host Integration > >Server API), but not against anything in this lib. > > > >Are there a set of things to look for when link failures like this happen? > >Do some windows libs get exported in different ways that require something > >beyond this: > > > >I'm compiling with both -L and -l. > > > >-v doesn't seem to give me any helpful information. > > > Please read and follow: > > >Problem reports: http://cygwin.com/problems.html > > when contacting the list with an issue you believe to be Cygwin-related. > This allows interested parties on the list to evaluate your problem in > the light of some specifics and ask informed follow-up questions. > > Thanks, Well, I guess this is a way of telling me that I didn't include enough info. :) I'm not intimating that this is a problem with Cygwin or the gcc (ld) port per se, I'm just trying to find out if maybe there is a different way that some libs export their methods. Or maybe there is a quirk I'm unaware of. Let me reiterate that I have been able to link against other libs in this same api using this same version of gcc on this same version of Cygwin...so it's clear that it's possible. Anyway, here is a listing of what happens during make when the error occurs. Maybe this will be provide more insight: gcc -v -mno-cygwin -L./lib -Wl,--add-stdcall-alias -shared -o cpic.dll cpic.o -lwcpic32 -lwappc32 -wincsv32 Reading specs from /usr/lib/gcc-lib/i686-pc-mingw32/3.2/specs gcc: unrecognized option `-wincsv32' Configured with: /netrel/src/gcc-3.2-3/configure --enable-languages=c,c++,f77,java --enable-libgcj --enable-threads=posix --with-system-zlib --enable- nls --without-included-gettext --enable-interpreter --disable-sjlj-exceptions --disable-version-specific-runtime-libs --enable-shared --build=i686-pc- linux --host=i686-pc-cygwin --target=i686-pc-cygwin --enable-haifa --prefix=/usr --exec-prefix=/usr --sysconfdir=/etc --libdir=/usr/lib --includedir=/ nonexistent/include --libexecdir=/usr/sbin Thread model: posix gcc version 3.2 20020927 (prerelease) /usr/lib/gcc-lib/i686-pc-mingw32/3.2/../../../../i686-pc-mingw32/bin/ld.exe --shared -Bdynamic -e _DllMainCRTStartup AT 12 -o cpic.dll /usr/lib/gcc-lib/ i686-pc-mingw32/3.2/../../../../i686-pc-mingw32/lib/dllcrt2.o /usr/lib/gcc-lib/i686-pc-mingw32/3.2/crtbegin.o -L./lib -L/usr/lib/gcc-lib/i686-pc-mingw 32/3.2 -L/usr/lib/gcc-lib/i686-pc-mingw32/3.2/../../../../i686-pc-mingw32/lib -L/usr/lib/gcc-lib/i686-pc-mingw32/3.2/../../.. --add-stdcall-alias cpic .o -lwcpic32 -lwappc32 -lmingw32 -lgcc -lmoldname -lmingwex -lmsvcrt -lmingw32 -luser32 -lkernel32 -ladvapi32 -lshell32 -lmingw32 -lgcc -lmoldname -lm ingwex -lmsvcrt /usr/lib/gcc-lib/i686-pc-mingw32/3.2/crtend.o cpic.o(.text+0x6a):cpic.c: undefined reference to `cminit AT 12' Note that this is a DLL I'm trying to build, but I'm also unable to link when just building an executable that uses this same lib. BTW, searching for cminit AT 12 on wcpic32.lib does come back with results. I hope this provides enough info. TIA, -- Sean LeBlanc:seanleblanc AT americanisp DOT net http://users.americanisp.net/~seanleblanc/ Get MLAC at: http://sourceforge.net/projects/mlac/ If you don't make things happen then things will happen to you. -Lanes Company -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/