From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 26267 invoked by alias); 3 May 2006 13:49:36 -0000 Received: (qmail 26253 invoked by uid 48); 3 May 2006 13:49:32 -0000 Date: Wed, 03 May 2006 13:49:00 -0000 Subject: [Bug c++/27408] New: g++ -force_flat_namespace fails due to crt3.o multiply defined symbols X-Bugzilla-Reason: CC Message-ID: Reply-To: gcc-bugzilla@gcc.gnu.org To: gcc-bugs@gcc.gnu.org From: "peter at pogma dot com" Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org X-SW-Source: 2006-05/txt/msg00273.txt.bz2 List-Id: 03-May-2006 12:37 PM Peter O'Gorman: g++ -force_flat_namespace dies with multiple definition of symbols in libSystem and crt3.o on Mac OS X 10.4. peter$ /opt/gcc_mainline/bin/g++ -force_flat_namespace -o foo foo.cpp /opt/odcctools/bin/ld: multiple definitions of symbol _atexit /opt/gcc_mainline/lib/gcc/powerpc-apple-darwin8.6.0/4.2.0/crt3.o private external definition of _atexit in section (__TEXT,__text) /usr/lib/libSystem.dylib(atexit.So) definition of _atexit /opt/odcctools/bin/ld: multiple definitions of symbol ___cxa_atexit /opt/gcc_mainline/lib/gcc/powerpc-apple-darwin8.6.0/4.2.0/crt3.o private external definition of ___cxa_atexit in section (__TEXT,__text) /usr/lib/libSystem.dylib(atexit.So) definition of ___cxa_atexit collect2: ld returned 1 exit status I expected the link to succeed. This bug is also an Apple radar - rdar://problem/4535166 Peter -- Summary: g++ -force_flat_namespace fails due to crt3.o multiply defined symbols Product: gcc Version: 4.2.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++ AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: peter at pogma dot com GCC host triplet: *-*-darwin8* http://gcc.gnu.org/bugzilla/show_bug.cgi?id=27408