help-gplusplus
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Port to Cygwin Causes Multiple Definition link errors on std::min


From: douglas . nospam
Subject: Port to Cygwin Causes Multiple Definition link errors on std::min
Date: 22 Aug 2006 19:26:37 -0700
User-agent: G2/0.2

I've googled this problem and can't seem to find an answer to my
problem.

I get the error below when linking an executable which I am trying to
port from Linux to Cygwin/XP.  I'm not sure how to attack this...any
thoughts?   Do I possibly need to use some different g++ options when
linking/compiling on cygwin

-------------------- link error ---------------------
g++ -lpthread -g  stilverify.o libstil.so   -o stilverify
libstil.so: In function `_ZSt3minIjERKT_S2_S2_':
/usr/lib/gcc/i686-pc-cygwin/3.4.4/include/c++/bits/stl_algobase.h:151:
multiple definition of `unsigned int const& std::min<unsigned
int>(unsigned int const&, unsigned int const&)'
stilverify.o:/usr/lib/gcc/i686-pc-cygwin/3.4.4/include/c++/bits/locale_facets.tcc:2497:
first defined here
collect2: ld returned 1 exit status
make: *** [stilverify] Error 1

------------------------------- g++ version -----------------------

$ g++ -v
Reading specs from /usr/lib/gcc/i686-pc-cygwin/3.4.4/specs
Configured with: /gcc/gcc-3.4.4/gcc-3.4.4-1/configure --verbose
--prefix=/usr --exec-prefix=/usr --sysconfdir=/etc --libdir=/usr/lib
--libexecdir=/usr/lib --mandir=/usr/share/man --infodir=/usr/share/info
--enable-languages=c,ada,c++,d,f77,java,objc --enable-nls
--without-included-gettext --enable-version-specific-runtime-libs
--without-x --enable-libgcj --disable-java-awt --with-system-zlib
--enable-interpreter --disable-libgcj-debug --enable-threads=posix
--enable-java-gc=boehm --disable-win32-registry
--enable-sjlj-exceptions --enable-hash-synchronization
--enable-libstdcxx-debug : (reconfigured)
Thread model: posix
gcc version 3.4.4 (cygming special) (gdc 0.12, using dmd 0.125)



reply via email to

[Prev in Thread] Current Thread [Next in Thread]