Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe@cygwin.com>
List-Archive: <http://sources.redhat.com/ml/cygwin/>
List-Post: <mailto:cygwin@cygwin.com>
List-Help: <mailto:cygwin-help@cygwin.com>, <http://sources.redhat.com/ml/#faqs>
Sender: cygwin-owner@cygwin.com
Mail-Followup-To: cygwin@cygwin.com
Delivered-To: mailing list cygwin@cygwin.com
Message-ID: <3FBF7056.70057DD@dessent.net>
Date: Sat, 22 Nov 2003 06:19:02 -0800
From: Brian Dessent <brian@dessent.net>
Organization: My own little world...
X-Accept-Language: en,en-US
MIME-Version: 1.0
To: Cygwin Mailing List <cygwin@cygwin.com>
Subject: Re: linking 3rd party DLLs to my code.
References: <NGBBLLIAMFLGJEOAJCCEKEHNDGAA.garbage_collector@telia.com>
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
X-AntiAbuse: This header was added to track abuse, please include it with any abuse report
X-AntiAbuse: Primary Hostname - host.linuxsv3.net
X-AntiAbuse: Original Domain - cygwin.com
X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12]
X-AntiAbuse: Sender Address Domain - dessent.net
Note-from-DJ: This may be spam

Hannu E K Nevalainen wrote:

> > > However I am able to link it. putting cg.dll in /usr/local/lib (say) and
> > > compiling with
> > >
> > > gcc -mno-cygwin <files> -L/usr/local/lib -lcg
>         ===========
> 
> > >
> > > compiles with no complaints.
> > >
> > > However, cygcheck complains, saying that it cannot find the dll.
> > >

> > Unless I'm really missing something, isn't this just a path issue?
> > AFAIK, every DLL that your program links against must be either in the
> > path or in the same directory as the .exe (unless the program
> > specifically looks for it with dlopen() or whatever.)

>  He is compiling with -mno-cygwin, I'd guess that this has some impact here.
> i.e. cygwin1.dll isn't used -> POSIX paths not available.

Okay, so you'd need to add c:\cygwin\usr\local\lib to the path instead. 
It still doesn't change the fact that DLLs have to be either in the path
or in the same directory as the EXE.  And that would definitely explain
why the symlink wasn't working as expected.

Brian

--
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/

