Return-Path: Delivered-To: apmail-incubator-stdcxx-dev-archive@www.apache.org Received: (qmail 80173 invoked from network); 5 Jun 2006 19:04:56 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 5 Jun 2006 19:04:56 -0000 Received: (qmail 17352 invoked by uid 500); 5 Jun 2006 19:04:56 -0000 Delivered-To: apmail-incubator-stdcxx-dev-archive@incubator.apache.org Received: (qmail 17328 invoked by uid 500); 5 Jun 2006 19:04:55 -0000 Mailing-List: contact stdcxx-dev-help@incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: stdcxx-dev@incubator.apache.org Delivered-To: mailing list stdcxx-dev@incubator.apache.org Received: (qmail 17316 invoked by uid 99); 5 Jun 2006 19:04:55 -0000 Received: from asf.osuosl.org (HELO asf.osuosl.org) (140.211.166.49) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 05 Jun 2006 12:04:55 -0700 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Received-SPF: neutral (asf.osuosl.org: local policy) Received: from [208.30.140.160] (HELO moroha.quovadx.com) (208.30.140.160) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 05 Jun 2006 12:04:51 -0700 Received: from qxvcexch01.ad.quovadx.com ([192.168.170.59]) by moroha.quovadx.com (8.13.4/8.13.4) with ESMTP id k55J4GVf025057 for ; Mon, 5 Jun 2006 19:04:16 GMT Content-class: urn:content-classes:message MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable X-MimeOLE: Produced By Microsoft Exchange V6.5 Subject: FW: Mac OS X Link Errors Date: Mon, 5 Jun 2006 13:04:29 -0600 Message-ID: X-MS-Has-Attach: X-MS-TNEF-Correlator: Thread-Topic: Mac OS X Link Errors Thread-Index: AcaIxoFJXLa5R9/mToWLziczys5FZgADAfTw From: "Eric Lemings" To: X-Virus-Checked: Checked by ClamAV on apache.org X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N -----Original Message----- From: Martin Sebor=20 Sent: Monday, June 05, 2006 10:44 AM To: Eric Lemings Subject: Re: Mac OS X Link Errors Interesting. Could you forward this to the list for the record? Thanks Martin Eric Lemings wrote: > =20 > http://gcc.gnu.org/onlinedocs/gcc-4.0.3/gcc/Vague-Linkage.html#Vague-Lin kage >=20 > "When used with GNU ld version 2.8 or later on an ELF system such as=20 > GNU/Linux or Solaris 2, or on Microsoft Windows, duplicate copies of=20 > these constructs will be discarded at link time. This is known as=20 > COMDAT support. >=20 > On targets that don't support COMDAT, but do support weak symbols, GCC > will use them. This way one copy will override all the others, but the > unused copies will still take up space in the executable. >=20 > For targets which do not support either COMDAT or weak symbols, most=20 > entities with vague linkage will be emitted as local symbols to avoid=20 > duplicate definition errors from the linker. This will not happen for=20 > local statics in inlines, however, as having multiple copies will=20 > almost certainly break things." >=20 > It appears that the linker on Mac OS X is the BSD version, not the GNU > version which is why the first option happens on other GCC 4.0=20 > platforms with STDCXX. I'll have to take a closer look at the other two options. >=20 > Brad. > =20 >=20 > ------------------------------------------------------------------------ > *From:* Eric Lemings > *Sent:* Friday, June 02, 2006 11:43 AM > *To:* Martin Sebor > *Subject:* Mac OS X Link Errors >=20 > =20 > What do you make of this? > =20 > gcc -c -I/Users/elemings/Work/stdcxx/include/ansi -D_RWSTDDEBUG =20 > -D_RWSTD_USE_CONFIG -I/Users/elemings/Work/stdcxx/include > -I/Users/elemings/Build/stdcxx/include -pedantic -nostdinc++ -g -W > -Wall -Wcast-qual -Winline -Wshadow -Wwrite-strings -Wno-long-long > -Wcast-align -fPIC /Users/elemings/Work/stdcxx/src/wctype.cpp > gcc assert.o atomic-cxx.o bitset.o catalog.o codecvt.o > collate.o ctype.o ctype_bits.o exception.o export.o facet.o file.o > instance.o ios.o ios_bits.o iostore.o iostream.o iso2022.o limits.o > limits_bits.o locale_bits.o locale_body.o locale_classic.o > locale_combine.o locale_core.o locale_eq.o locale_global.o > locale_name.o memattr.o memory.o messages.o num_get.o num_put.o > punct.o random.o setlocale.o string.o strstream.o strtol.o > ti_collate.o ti_filebuf.o ti_insert_dbl.o ti_insert_int.o > ti_insert_ptr.o ti_ios.o ti_istream.o ti_messages.o ti_money_get.o > ti_money_put.o ti_moneypunct.o ti_num_get.o ti_num_put.o > ti_numpunct.o ti_ostream.o ti_streambuf.o ti_string.o ti_stringbuf.o > ti_time_get.o ti_time_put.o ti_wcollate.o ti_wfilebuf.o > ti_winsert_dbl.o ti_winsert_int.o ti_winsert_ptr.o ti_wios.o > ti_wistream.o ti_wmessages.o ti_wmoney_get.o ti_wmoney_put.o > ti_wmoneypunct.o ti_wnum_get.o ti_wnum_put.o ti_wnumpunct.o > ti_wostream.o ti_wstreambuf.o ti_wstring.o ti_wstringbuf.o > ti_wtime_get.o ti_wtime_put.o time_get.o time_put.o tmpbuf.o > typeinfo.o valarray.o vecbool.o version.o wcodecvt.o wctype.o > -lsupc++ -lgcc_eh -o /Users/elemings/Build/stdcxx/lib/libstd.so.4.2.0 > /usr/bin/ld: multiple definitions of symbol vtable for > std::bad_exception > exception.o definition of vtable for std::bad_exceptionin section > (__DATA,__const) > /usr/lib/gcc/i686-apple-darwin8/4.0.1/../../../libsupc++.a(eh_exception. o) > private external definition of vtable for std::bad_exceptionin > section (__DATA,__const) > /usr/bin/ld: multiple definitions of symbol vtable for std::bad_alloc > memory.o definition of vtable for std::bad_allocin section > (__DATA,__const) > /usr/lib/gcc/i686-apple-darwin8/4.0.1/../../../libsupc++.a(new_handler.o ) > private external definition of vtable for std::bad_allocin section > (__DATA,__const) > collect2: ld returned 1 exit status > make[2]: *** [/Users/elemings/Build/stdcxx/lib/libstd.so] Error 1 > make[1]: *** [lib] Error 2 > make: *** [libstd] Error 2 > I've tried without -lsupc++, without -lgcc_eh, without both of > them... Nothing works. > =20 > Brad. > =20 > =20