delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2002/11/09/05:59:21

Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sources.redhat.com/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sources.redhat.com/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com
Message-ID: <20021109105904.24937.qmail@web21405.mail.yahoo.com>
Date: Sat, 9 Nov 2002 21:59:04 +1100 (EST)
From: =?iso-8859-1?q?Danny=20Smith?= <danny_r_smith_2001 AT yahoo DOT co DOT nz>
Subject: re: binutils 20021107-2
To: cygwin AT cygwin DOT com
MIME-Version: 1.0

Hello Robert

By default symbols in libstdc++.a are excluded when doing --export-all, to
protect against this type of error.

However, ld/pe-dll.c knows nothing about libstdc++-2.a.  So those symbols do
get exported ... and cause the usual problems with multiple definitions.

Quick solution: Try --exclude-libs=libstdc++-2.a


Danny


Robert Collins wrote:
Hmm, a new ?bug? in binutils:

Linking a g++-2 compiled program, with a g++-2 compiled dll


(line breaks and blank lines added for clarity)

RobertC AT LIFELESSAMD ~/src/barch/build
 make
/bin/bash ./libtool --mode=link g++-2  -g -O2   -o get-archive-name.exe
src/get-archive-name.o src/Archive.la
/usr/local/lib/libgetopt++.la -lm -lboost_regex

g++-2 -g -O2 -o get-archive-name.exe src/get-archive-name.o
src/.libs/Archive.a  -L/usr/lib -L/usr/lib/w32api
 -L/usr/lib/gcc-lib/i686-pc-cygwin/2.95.3-10 -lgcc
-lgcc -lgcc -lgcc -lgcc -lgcc -lgcc -lgcc -lgcc -lgcc -lgcc -lgcc
/usr/local/lib /libgetopt++.dll.a -lstdc++-2 -lgcc -lcygwin 
-luser32 -lkernel32 -ladvapi32 -lshell32 -lgcc -lboost_regex 
-L/usr/local/lib -L/usr/local/lib

/usr/lib/gcc-lib/i686-pc-cygwin/2.95.3-10/libstdc++-2.a(filebuf.o)(.text
+0x2a8):
filebuf.cc: multiple definition of `filebuf::~filebuf(void)'
/usr/local/lib/libgetopt++.dll.a(d000031.o)(.text+0x0): first defined
here
/usr/lib/gcc-lib/i686-pc-cygwin/2.95.3-10/libstdc++-2.a(streambuf.o)
(.text+0x35c):streambuf.cc: multiple definition of `streambuf::sungetc(void)'
/usr/local/lib/libgetopt++.dll.a(d000485.o)(.text+0x0): first defined
here
collect2: ld returned 1 exit status
make: *** [get-archive-name.exe] Error 1


http://careers.yahoo.com.au - Yahoo! Careers
- 1,000's of jobs waiting online for you!

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

- Raw text -


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