[ https://issues.apache.org/jira/browse/STDCXX-337?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12472153 ]
Mark Brown commented on STDCXX-337: ----------------------------------- Here's a simple patch that fixed the iconv and catgets linker errors for me: $ diff -u /home/mbrown/stdcxx-4.1.3/etc/config/gcc.config /home/mbrown/stdcxx-4.1.3/etc/config/gcc.config.save --- /home/mbrown/stdcxx-4.1.3/etc/config/gcc.config 2007-02-11 16:02:18.352101500 -0700 +++ /home/mbrown/stdcxx-4.1.3/etc/config/gcc.config.save 2007-02-11 16:02:15.544101500 -0700 @@ -166,9 +166,6 @@ MULTI_CPPFLAGS_POSIX = -mthreads MULTI_LDFLAGS_POSIX = -mthreads - # link with libcatgets and libiconv - LDLIBS += -catgets -liconv - # set the assembler file suffix to .s AS_EXT = .s endif > [Cygwin] unsats on _libiconv, _catgets > -------------------------------------- > > Key: STDCXX-337 > URL: https://issues.apache.org/jira/browse/STDCXX-337 > Project: C++ Standard Library > Issue Type: Bug > Components: Build > Affects Versions: 4.1.3 > Environment: Cygwin > Reporter: Mark Brown > > I tried to build the library on Cygwin but I'm getting linker errors for the > localedef utility. I have the iconv library installed (in /usr/lib) but make > isn't linking with it. I also get linker errors for _catopen, _catgets, and > _catclose. I searched under /usr/lib to see what library defines these > symbols and it's libcatgets.a. Should the makefile be linking with it? > gcc localedef.o aliases.o charmap.o codecvt.o collate.o ctype.o def.o > diagnostic.o messages.o monetary.o numeric.o path.o time.o scanner.o -o > localedef -L/home/mbrown/stdcxx-4.1.3-gcc-3.4.4-11s/lib -lstd11s -lsupc++ > -lm > /usr/lib/gcc/i686-pc-cygwin/3.4.4/libsupc++.a(eh_exception.o):(.text+0x80): > multiple definition of `std::exception::what() const' > /home/mbrown/stdcxx-4.1.3-gcc-3.4.4-11s/lib/libstd11s.a(exception.o):/home/mbrown/stdcxx-4.1.3/src/exception.cpp:334: > first defined here > charmap.o: In function `_ZNSt4pairIKwSsEC1ERKS1_': > /home/mbrown/stdcxx-4.1.3/include/rw/_specialized.h:(.text+0x4c0): undefined > reference to `_libiconv_open' > charmap.o: In function `_ZNK7Charmap15convert_to_utf8EPKcjPcj': > /home/mbrown/stdcxx-4.1.3/util/charmap.cpp:346: undefined reference to > `_libiconv' > /home/mbrown/stdcxx-4.1.3-gcc-3.4.4-11s/lib/libstd11s.a(messages.o): In > function `_ZN4__rw13__rw_cat_openERKSsRKSt6locale': > /home/mbrown/stdcxx-4.1.3/src/messages.cpp:205: undefined reference to > `_catopen' > /home/mbrown/stdcxx-4.1.3-gcc-3.4.4-11s/lib/libstd11s.a(messages.o): In > function `_ZN4__rw16__rw_get_messageEiii': > /home/mbrown/stdcxx-4.1.3/src/messages.cpp:235: undefined reference to > `_catgets' > /home/mbrown/stdcxx-4.1.3-gcc-3.4.4-11s/lib/libstd11s.a(messages.o): In > function `_ZN4__rw14__rw_cat_closeEi': > /home/mbrown/stdcxx-4.1.3/src/messages.cpp:277: undefined reference to > `_catclose' > collect2: ld returned 1 exit status > make[2]: *** [localedef] Error 1 > make[2]: Leaving directory `/home/mbrown/stdcxx-4.1.3-gcc-3.4.4-11s/bin' > make[1]: *** [util] Error 2 > make[1]: Leaving directory `/home/mbrown/stdcxx-4.1.3-gcc-3.4.4-11s' > make: *** [libstd] Error 2 -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.