Lapo Luchini wrote: >>Yeah, and we can kiss that pesky "UNIX emulation" claim of cygwin's >>goodbye, too. Somehow, I don't think that you'll find many library >>files in /usr/lib/cygwin on, say, HP/UX, Linux, Tru64, etc. >> >>This method solves a "problem" for -mno-cygwin at the expense of >>impacting many other packages. >> >>I agree that the print-search-dirs should work correctly and even suggested >>this in the libtools forum. I agree that --dll-search-prefix=cyg should >>not be activated when the user specifies -mno-cygwin. >> >> > OK, maybe part of Jon's idea was bad or "not correct", but what about > replacing just that > --dll-search-prefix=cyg > with a > %{!mno-cygwin:--dll-search-prefix=cyg} > in the distro? > > If I understood it right this whould be a problem solver with no side > effects, right?
Except that it doesn't really solve any problems that currently exist -- only potential ones. I'll explain below. I agree that you SHOULD have %(!mno-cygwin:--dll-search-prefix=cyg). If the mingw folks would condescend to actually USE the search prefix feature I laboriously added to binutils -- at thier request -- and name their DLLs with a prefix other than 'lib' it would truly be nice. And then you'd also put %(mno-cygwin:--dll-search-prefix=mgw) or something. And Paul Sokolovsky could use --dll-search-prefix=pw. But I digress. dll-search-prefix only has effect when you are trying to link directly to a DLL. Ordinarily, you don't do that -- you link with import libs. Which are named 'libfoo.dll.a'. Really, to link to a DLL, in practice you have to: -L/usr/bin -lfoo Since there aren't any import libs in /usr/bin, when ld fails to find libfoo.dll.a THEN it will search for cygfoo.dll. (Actually, I'm glossing over some other items in the search procedure -- use the source, luke) Do you currently add -L/usr/bin when linking? No, I didn't think so -- therefore --dll-search-prefix can't really be causing any problems. Unless you've got DLLs scattered around elsewhere... --Chuck -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Bug reporting: http://cygwin.com/bugs.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/