bug-gnu-utils
[Top][All Lists]
Advanced

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

Re: multiple definition of `gl_locale_name_thread'


From: Bruno Haible
Subject: Re: multiple definition of `gl_locale_name_thread'
Date: Fri, 21 May 2010 01:21:22 +0200
User-agent: KMail/1.9.9

Hi,

> I'm on Windows Vista 64, trying to build gettext-0.18 in the msys shell 
> using the mingw64 (x64) port of gcc-4.4.4.
> 
> It's actually a cross-compiler, which makes for a rather lengthy configure 
> command - though I may be specifying some arguments that don't need to be 
> specified. Anyway, I start with:
> 
> ./configure --disable-shared --enable-static --build=x86_64-w64-mingw32 
> --host=x86_64-w64-mingw32 
> CC=x86_64-w64-mingw32-gcc CXX=x86_64-w64-mingw32-g++ 
> AR=x86_64-w64-mingw32-ar LD=x86_64-w64-mingw32-ld NM=x86_64-w64-mingw32-nm 
> RANLIB=x86_64-w64-mingw32-ranlib 
> LDFLAGS="-L/usr/local/lib -L/usr/local/ssl/lib" 
> CPPFLAGS="-I/usr/local/include -I/usr/local/ssl/include" && make
> 
> After a while, the make process terminates with:
> 
> libtool: link: 
> x86_64-w64-mingw32-gcc -std=gnu99 -g -O2 -Wl,--disable-auto-import -o 
> msginit.exe msginit-msginit.o msginit-lang-table.o msginit-plural-count.o 
> msginit-localealias.o msginit-lock.o 
> gettext.res  -L/usr/local/lib -L/usr/local/ssl/lib ./.libs/libgettextsrc.a 
> /c/_64/comp/gettext-0.18/gettext-tools/gnulib-lib/.libs/libgettextlib.a 
> /c/_64/comp/gettext-0.18/gettext-tools/intl/.libs/libintl.a 
> /usr/local/lib/libiconv.a
> c:/_64/comp/gettext-0.18/gettext-tools/intl/.libs/libintl.a(localename.o): 
> In function `gl_locale_name_thread':
> c:\_64\comp\gettext-0.18\gettext-tools\intl/../../gettext-runtime/intl/localename.c:2759:
>  
> multiple definition of `gl_locale_name_thread'
> c:/_64/comp/gettext-0.18/gettext-tools/gnulib-lib/.libs/libgettextlib.a(localename.o):c:\_64\comp\gettext-0.18\gettext-tools\gnulib-lib/localename.c:2759:
>  
> first defined here
> collect2: ld returned 1 exit status

Thanks for the report. I can reproduce this error with a similar configuration
on mingw. I'll be applying the fix below.

> There were a few tests that failed during 'make check' - but that can wait
> for another day: 
> 
> =======================
> 13 of 299 tests failed
> (28 tests were not run)
> =======================

Here it makes sense to see which of them also fail on mingw, and if you can
analyze one or the other.

Bruno


--- gettext-runtime/intl/gettextP.h.orig        Fri May 21 01:14:45 2010
+++ gettext-runtime/intl/gettextP.h     Fri May 21 01:14:40 2010
@@ -1,5 +1,5 @@
 /* Header describing internals of libintl library.
-   Copyright (C) 1995-1999, 2000-2007, 2009 Free Software Foundation, Inc.
+   Copyright (C) 1995-1999, 2000-2007, 2009-2010 Free Software Foundation, Inc.
    Written by Ulrich Drepper <address@hidden>, 1995.
 
    This program is free software; you can redistribute it and/or modify it
@@ -238,6 +238,9 @@
 # define gl_locale_name_thread_unsafe _nl_locale_name_thread_unsafe
 extern const char *_nl_locale_name_thread_unsafe (int category,
                                                  const char *categoryname);
+# define gl_locale_name_thread _nl_locale_name_thread
+/* extern const char *_nl_locale_name_thread (int category,
+                                             const char *categoryname); */
 # define gl_locale_name_posix _nl_locale_name_posix
 extern const char *_nl_locale_name_posix (int category,
                                          const char *categoryname);



reply via email to

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