This is the mail archive of the cygwin mailing list for the Cygwin project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]


On Nov 25 10:21, John Emmas wrote:
> When I compile & build for my Linux installation, library files and shared
> objects go to /usr/lib/
> If I then run an executable (from /usr/bin/) it will automatically find the
> shared objects because it expects them to be in /usr/lib/.  This isn't
> happening for Cygwin and I'm finding that I need to copy the shared
> objects into /usr/bin/
> After googling, I found out that I might be able to set an envinronment
> variable called LD_LIBRARY_PATH.  So I set it up and tried again - but
> unfortunately, without success...  :-(

Since the process is loaded into memory by the Windows loader, the
underlying mechanism to load shared libs at process startup time is the
Windows mechanism:

$PATH is what you want and if you examine /bin resp. /usr/bin, you see
that Cygwin puts all shared libs there for the above reason.  /lib resp.
/usr/lib only contain the static libs and the shared link stubs
necessary for the linker at build time.

LD_LIBRARY_PATH only has a meaning in Cygwin's dlopen() implementation,
when loading shared libs at runtime.


Corinna Vinschen                  Please, send mails regarding Cygwin to
Cygwin Project Co-Leader          cygwin AT cygwin DOT com
Red Hat

Unsubscribe info:
Problem reports:

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]