delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2004/10/22/11:10:19

Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/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
To: cygwin AT cygwin DOT com
From: "Judd" <jbogus1 AT yahoo DOT com>
Subject: Build/Linker question again (g++)
Date: Fri, 22 Oct 2004 09:09:56 -0600
Lines: 50
Message-ID: <clb7sb$bar$1@sea.gmane.org>
X-Complaints-To: usenet AT sea DOT gmane DOT org
X-Gmane-NNTP-Posting-Host: 66.54.224.97
X-Newsreader: Microsoft Outlook Express 6.00.2800.1437
X-IsSubscribed: yes

The error I'm getting now is:
----------------------------
/usr/lib/gcc-lib/i686-pc-cygwin/3.3.3/libgcc.a(_chkstk.o)(.text+0x0):
multiple definition of `__alloca'

/usr/lib/libcygwin.a(d000085.o)(.text+0x0): first defined here

/usr/lib/gcc-lib/i686-pc-cygwin/3.3.3/libgcc.a(_eprintf.o)(.text+0x0):
multiple definition of `___eprintf'

/usr/lib/libcygwin.a(d000027.o)(.text+0x0): first defined here

---------------------------------

From the build command:

-------------------------

g++ -shared -nodefaultlibs -o
libInventor.dll -Wl,--out-implib=libInventor.dll.a \

-Wl,--export-all-symbols -Wl,--enable-auto-import -Wl,--whole-archive
libInventor.a \

-WL,--no-whole-archive -L/usr/lib -L/usr/lib/gcc-lib/i686-pc-cygwin/3.3.3 -L
/usr/X11R6/lib -L/usr/lib/w32api -L../libimage -L../libFL/src \

-ljpeg.dll -limage -lFL -lX11.dll -lfltk_gl.dll -lGLU.dll -lGL.dll -liconv.d
ll \

-lfreetype.dll -lcygwin -lstdc++ -lasprintf -lz -lkernel32 -lgcc

-----------------------------

I'm using nodefaultlibs because I had a problem linking before where I was
getting lots of multiple definition errors from essentially the same
library.  Using nodefaultlibs and linking all the libs I need by hand has
fixed all those, but I have those last 2 multiple definition errors.  Is
there any way to link libcygwin and libgcc without getting multiple
definitions of ___eprintf and __alloca?  It seems bizarre that those 2 would
conflict.  Maybe there's a command line option that I need to be using in my
build command.



Thank You

Judd




--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.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