]> git.ipfire.org Git - thirdparty/gettext.git/commitdiff
build: Remove the need for an autoconf test.
authorBruno Haible <bruno@clisp.org>
Sat, 21 Nov 2020 21:37:30 +0000 (22:37 +0100)
committerBruno Haible <bruno@clisp.org>
Sun, 9 Oct 2022 07:30:42 +0000 (09:30 +0200)
* gettext-runtime/intl/intl-exports.c (IMP): Use predefined preprocessor symbol
tests, not USER_LABEL_PREFIX_UNDERSCORE.
* gettext-runtime/configure.ac (INTL_EXPORTS_FLAGS): Remove variable.
* gnulib-local/modules/gettext-runtime-misc (Makefile.am): Don't use
INTL_EXPORTS_FLAGS.
* gettext-tools/woe32dll/export.h (IMP): Use predefined preprocessor symbol
tests, not USER_LABEL_PREFIX_UNDERSCORE.
* gettext-tools/configure.ac (GETTEXTLIB_EXPORTS_FLAGS): Don't define USER_LABEL_PREFIX_UNDERSCORE.

gettext-runtime/configure.ac
gettext-runtime/intl/intl-exports.c
gettext-tools/configure.ac
gettext-tools/woe32dll/export.h
gnulib-local/modules/gettext-runtime-misc

index d524fc9c9c8e9df6e56a8693b2f1f1abcab0f3ae..40187d145236e02fae77a5d66d71b86de21cbc1c 100644 (file)
@@ -130,14 +130,6 @@ if test $is_woe32dll = yes; then
     [Define when --enable-shared is used on mingw or Cygwin.])
 fi
 
-INTL_EXPORTS_FLAGS=
-dnl 64-bit mingw does not prepend an underscore to C symbols.
-dnl USER_LABEL_PREFIX is set by gl_ASM_SYMBOL_PREFIX, inside gl_INIT.
-if test "$USER_LABEL_PREFIX" = _; then
-  INTL_EXPORTS_FLAGS="-DUSER_LABEL_PREFIX_UNDERSCORE $INTL_EXPORTS_FLAGS"
-fi
-AC_SUBST([INTL_EXPORTS_FLAGS])
-
 dnl Put some default definitions into config.h.
 AH_BOTTOM([
 /* On Windows, variables that may be in a DLL must be marked specially.
index 0ddfb89af0887878c7f230169b1644f9b204bf5c..56542644662e163184c48af558232a63352adebb 100644 (file)
@@ -1,5 +1,5 @@
 /* List of exported symbols of libintl on Cygwin.
-   Copyright (C) 2006, 2012-2013 Free Software Foundation, Inc.
+   Copyright (C) 2006, 2012-2020 Free Software Foundation, Inc.
    Written by Bruno Haible <bruno@clisp.org>, 2006.
 
    This program is free software: you can redistribute it and/or modify
    along with this program.  If not, see <https://www.gnu.org/licenses/>.  */
 
  /* IMP(x) is a symbol that contains the address of x.  */
-#if USER_LABEL_PREFIX_UNDERSCORE
-# define IMP(x) _imp__##x
-#else
+#if defined _WIN64 || defined _LP64
 # define IMP(x) __imp_##x
+#else
+# define IMP(x) _imp__##x
 #endif
 
  /* Ensure that the variable x is exported from the library, and that a
index f439f5e9ad2f4dfdf1e54ae48919655a18b17e19..387d148ec24f036241bdcef7007dffa01e4737b4 100644 (file)
@@ -302,12 +302,6 @@ dnl gl_ERROR, inside gl_INIT.
 if test "$ac_cv_lib_error_at_line" = no; then
   GETTEXTLIB_EXPORTS_FLAGS="-DGNULIB_DEFINED_ERROR $GETTEXTLIB_EXPORTS_FLAGS"
 fi
-
-dnl 64-bit mingw does not prepend an underscore to C symbols.
-dnl USER_LABEL_PREFIX is set by gl_ASM_SYMBOL_PREFIX, inside gl_INIT.
-if test "$USER_LABEL_PREFIX" = _; then
-  GETTEXTLIB_EXPORTS_FLAGS="-DUSER_LABEL_PREFIX_UNDERSCORE $GETTEXTLIB_EXPORTS_FLAGS"
-fi
 AC_SUBST([GETTEXTLIB_EXPORTS_FLAGS])
 
 dnl Tell the source files that the error facility is replaced by
index ff3515e392dac9edf97605f6bfe26e31a8c30d1c..1c4054d28f770ca707c41f76bf0c57c1abaa7292 100644 (file)
@@ -1,5 +1,5 @@
 /* Exporting symbols from Cygwin shared libraries.
-   Copyright (C) 2006, 2011-2018 Free Software Foundation, Inc.
+   Copyright (C) 2006, 2011-2020 Free Software Foundation, Inc.
    Written by Bruno Haible <bruno@clisp.org>, 2006.
 
    This program is free software: you can redistribute it and/or modify
 #if defined __GNUC__ /* GCC compiler, GNU toolchain */
 
  /* IMP(x) is a symbol that contains the address of x.  */
-#if USER_LABEL_PREFIX_UNDERSCORE
-# define IMP(x) _imp__##x
-#else
+#if defined _WIN64 || defined _LP64
 # define IMP(x) __imp_##x
+#else
+# define IMP(x) _imp__##x
 #endif
 
  /* Ensure that the variable x is exported from the library, and that a
index de358b6ff8cec166b285a57a5ff6f07b286cb695..4cad86d658484c49b8d94ed8ea3282f381db3269 100644 (file)
@@ -15,11 +15,6 @@ AM_CPPFLAGS += -I$(top_builddir)/intl -I$(top_srcdir)/intl
 # Parametrization of the 'relocatable' module.
 AM_CPPFLAGS += -DDEPENDS_ON_LIBICONV=1 -DDEPENDS_ON_LIBINTL=1
 
-# Tell the mingw or Cygwin linker which symbols to export.
-if WOE32DLL
-AM_CPPFLAGS += @INTL_EXPORTS_FLAGS@
-endif
-
 Include:
 
 License: