ftp.delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin-apps/2000/05/19/17:29:45

Mailing-List: contact cygwin-apps-help AT sourceware DOT cygnus DOT com; run by ezmlm
list-help: <mailto:cygwin-apps-help AT sourceware DOT cygnus DOT com>
list-post: <mailto:cygwin-apps AT sourceware DOT cygnus DOT com>
Sender: cygwin-apps-owner AT sourceware DOT cygnus DOT com
Delivered-To: mailing list cygwin-apps AT sourceware DOT cygnus DOT com
Message-ID: <3925B438.53F17C7B@ece.gatech.edu>
Date: Fri, 19 May 2000 17:38:00 -0400
From: Charles Wilson <cwilson AT ece DOT gatech DOT edu>
X-Mailer: Mozilla 4.7 [en] (Win98; U)
X-Accept-Language: en
MIME-Version: 1.0
To: earnie_boyd AT yahoo DOT com
CC: cygwin-apps AT sourceware DOT cygnus DOT com
Subject: Re: NCurses-5.0
References: <20000519202317 DOT 29524 DOT qmail AT web123 DOT yahoomail DOT com>

Earnie Boyd wrote:
> --- "Charles S. Wilson" <cwilson AT ece DOT gatech DOT edu> wrote:
> -8<-
> >
> -8<-
> Paul Sokolovsky has this nice a2dll script to create a dll from a static lib.
> I've been playing with it today with readline-4.1 and have found it to be
> useful.  I modified his naming scheme so that the static library becomes
> libfoo_s.a, libfoo.a is a symbolic link to foo.dll and libfoo.dll.a is the
> import library.  I don't know that this is the best idea yet.  With the
> symbolic link the linker builds the executable but the executable just exits
> without doing anything.  With using the dll directly, ie specifying
> readline.dll on the command line as an input file, the linker builds the
> executable but some of the examples stackdump, some of the examples complain of
> missing routines and some work.  They all work with the static library of
> course.

use cygcheck to analyze the executable. I messed with symlinks a little
bit, and found that ld used the name of the symlink as the embedded
dll-name in the executable. e.g:

/usr/bin/libz.dll (identical copies of the same file)
/usr/lib/z.dll -> /usr/bin/libz.dll

gcc -o minigzip.exe minigzip.o -L/usr/lib -lz
(This will link using the /usr/lib/z.dll symlink)

cygcheck minigzip.exe
[ lots of cygwin & windows dll's ]
/usr/bin/z.dll !!!!

So, I suspect that if you use 'libfoo.a --> foo.dll' then the executable
will have 'libfoo.a' embedded as the dll-name to hunt for; and windows
will not find it.

> > > If this can be resolved soon, then we should wait.  Should we put it up
> > > for a vote?  Or is cygwin-apps too new for this to be useful?
> > >
> >
> As long as it works, makes life easier to have a choice of static versus
> dynamic, and is close to what people are used to in unix I don't think anyone
> is going to complain.
> How about using this naming scheme?  It looks right and comes close to being
> "real".
> libfoo.a == static library
> libfoo.so == sybolic link to foo.dll
> libfoo.dll.a == import library

see above.

> Chuck, I'm willing to test your binutils changes.  Just let me know where I can
> find a distro.

I'll upload ld.exe/collect2.exe/specs tonight & let you know where to
find it.


- Raw text -

  webmaster     delorie software   privacy  
  Copyright 2019   by DJ Delorie     Updated Jul 2019