delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2000/09/08/10:21:57

Mailing-List: contact cygwin-help AT sourceware DOT cygnus DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT sources DOT redhat DOT com>
List-Archive: <http://sources.redhat.com/ml/cygwin/>
List-Post: <mailto:cygwin AT sources DOT redhat DOT com>
List-Help: <mailto:cygwin-help AT sources DOT redhat DOT com>, <http://sources.redhat.com/ml/#faqs>
Sender: cygwin-owner AT sources DOT redhat DOT com
Delivered-To: mailing list cygwin AT sources DOT redhat DOT com
Message-ID: <17B78BDF120BD411B70100500422FC6309E0DD@IIS000>
From: Bernard Dautrevaux <Dautrevaux AT microprocess DOT com>
To: "'Larry Hall (RFK Partners, Inc)'" <lhall AT rfk DOT com>,
"Fleischer, Karsten (K.)" <kfleisc1 AT ford DOT com>,
"'kris DOT thielemans AT ic DOT ac DOT uk'" <kris DOT thielemans AT ic DOT ac DOT uk>
Cc: "Cygwin (E-mail)" <cygwin AT sourceware DOT cygnus DOT com>
Subject: RE: problem with dynamic_cast
Date: Fri, 8 Sep 2000 16:11:54 +0200
MIME-Version: 1.0
X-Mailer: Internet Mail Service (5.5.2650.21)

> -----Original Message-----
> From: Larry Hall (RFK Partners, Inc) [mailto:lhall AT rfk DOT com]
> Sent: Friday, September 08, 2000 3:53 PM
> To: Fleischer, Karsten (K.); 'kris DOT thielemans AT ic DOT ac DOT uk'
> Cc: Cygwin (E-mail)
> Subject: RE: problem with dynamic_cast
> 
> 
> Quite true.  -lm and -lc are not necessary with Cygwin.  The 
> support for 
> them are in the Cygwin DLL/lib which is linked in 
> automatically.  Linking
> with it twice (or more) guarantees a crash.  The simple 
> answer is, don't
> us -lm or -lc with Cygwin.
> 

Obviously if I create a program to work on cygwin, I'll be careful not to
add "-lm" to my link commands; however I quite often just port UNIX programs
to cygwin and then I may forget to remove "-lm" from the makefiles (or
oversee them). 

Just saying "dont use -lm" is a bit harsh on the developper; at the least we
should avoid delivering libm.a, so we will get a clear message "libm.a" not
found, that could be looked up in the FAQ quite simply. Now we just link
correctly but then crash misteriously ;-(

I think I remember someone already suggest a simple solution to the fact the
"-lm" crash under cygwin but it seems it was never implemented :-( :

Instead of having libm.a (and libc.a BTW) be a symbolic link to libcygwin.a,
just create one (two) empty libraries named "libm.a" and "libc.a"; linking
several times to these libraries would then essentially do nothing, which is
what we expect, instead of creating a "crashing" executable :-)

Maybe I'm just tood tosee the obvious problem this causes that will prevent
cygwin to be useful :-)

I know I should provide a patch, but I just don't know where to look :-)

Just my 2 cents,

	Bernard

--------------------------------------------
Bernard Dautrevaux
Microprocess Ingenierie
97 bis, rue de Colombes
92400 COURBEVOIE
FRANCE
Tel:	+33 (0) 1 47 68 80 80
Fax:	+33 (0) 1 47 88 97 85
e-mail:	dautrevaux AT microprocess DOT com
		b DOT dautrevaux AT usa DOT net
-------------------------------------------- 

--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe AT sourceware DOT cygnus DOT com

- Raw text -


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