]> git.ipfire.org Git - thirdparty/gettext.git/commitdiff
Update after gnulib changed: Fix link errors on native Windows.
authorBruno Haible <bruno@clisp.org>
Mon, 28 Dec 2020 13:05:05 +0000 (14:05 +0100)
committerBruno Haible <bruno@clisp.org>
Mon, 28 Dec 2020 13:05:05 +0000 (14:05 +0100)
* autogen.sh (GNULIB_MODULES_TOOLS_FOR_SRC, GNULIB_MODULES_LIBGETTEXTPO): Add
strdup-posix.
Avoid the *-list-tests, since they reference a variable, leading to a problem
with --enable-shared.
* gettext-tools/libgettextpo/Makefile.am (config.h): Undefine GNULIB_GETCWD and
REPLACE_FCHDIR that are defined in the parent config.h.

.gitignore
autogen.sh
gettext-tools/libgettextpo/Makefile.am

index 254a7ceff50145dbd3606046f3d5ac11a490a5e3..4110c15b1509fe0dbaa38423c599de139f0720b7 100644 (file)
 /gettext-tools/libgettextpo/str-two-way.h
 /gettext-tools/libgettextpo/strchrnul.c
 /gettext-tools/libgettextpo/strchrnul.valgrind
+/gettext-tools/libgettextpo/strdup.c
 /gettext-tools/libgettextpo/streq.h
 /gettext-tools/libgettextpo/strerror-override.c
 /gettext-tools/libgettextpo/strerror-override.h
index 02b4a3fb9c0d12a065655b62fac0a9dc7966d77c..d766977b3f1e7a2a4418d63d8be55338bf24323f 100755 (executable)
@@ -197,6 +197,7 @@ if ! $skip_gnulib; then
     stpncpy
     strchrnul
     strcspn
+    strdup-posix
     strerror
     strpbrk
     strtol
@@ -281,8 +282,11 @@ if ! $skip_gnulib; then
     uniwidth/width-tests
   '
   $GNULIB_TOOL --dir=gettext-tools --lib=libgettextlib --source-base=gnulib-lib --m4-base=gnulib-m4 --tests-base=gnulib-tests --makefile-name=Makefile.gnulib --libtool --with-tests --local-dir=gnulib-local --local-symlink \
-    --import --avoid=fdutimensat-tests --avoid=futimens-tests --avoid=utime-tests --avoid=utimens-tests --avoid=utimensat-tests \
-    `for m in $GNULIB_MODULES_TOOLS_LIBUNISTRING_TESTS; do echo --avoid=$m; done` $GNULIB_MODULES_TOOLS_FOR_SRC $GNULIB_MODULES_TOOLS_FOR_SRC_COMMON_DEPENDENCIES $GNULIB_MODULES_TOOLS_OTHER || exit $?
+    --import \
+    --avoid=fdutimensat-tests --avoid=futimens-tests --avoid=utime-tests --avoid=utimens-tests --avoid=utimensat-tests \
+    --avoid=array-list-tests --avoid=linked-list-tests --avoid=linkedhash-list-tests \
+    `for m in $GNULIB_MODULES_TOOLS_LIBUNISTRING_TESTS; do echo --avoid=$m; done` \
+    $GNULIB_MODULES_TOOLS_FOR_SRC $GNULIB_MODULES_TOOLS_FOR_SRC_COMMON_DEPENDENCIES $GNULIB_MODULES_TOOLS_OTHER || exit $?
   $GNULIB_TOOL --copy-file m4/libtextstyle.m4 gettext-tools/gnulib-m4/libtextstyle.m4 || exit $?
   # In gettext-tools/libgrep:
   GNULIB_MODULES_TOOLS_FOR_LIBGREP='
@@ -290,7 +294,9 @@ if ! $skip_gnulib; then
     regex
   '
   $GNULIB_TOOL --dir=gettext-tools --macro-prefix=grgl --lib=libgrep --source-base=libgrep --m4-base=libgrep/gnulib-m4 --witness-c-macro=IN_GETTEXT_TOOLS_LIBGREP --makefile-name=Makefile.gnulib --local-dir=gnulib-local --local-symlink \
-    --import `for m in $GNULIB_MODULES_TOOLS_FOR_SRC_COMMON_DEPENDENCIES; do if test \`$GNULIB_TOOL --extract-applicability $m\` != all; then echo --avoid=$m; fi; done` $GNULIB_MODULES_TOOLS_FOR_LIBGREP || exit $?
+    --import \
+    `for m in $GNULIB_MODULES_TOOLS_FOR_SRC_COMMON_DEPENDENCIES; do if test \`$GNULIB_TOOL --extract-applicability $m\` != all; then echo --avoid=$m; fi; done` \
+    $GNULIB_MODULES_TOOLS_FOR_LIBGREP || exit $?
   # In gettext-tools/libgettextpo:
   # This is a subset of the GNULIB_MODULES_TOOLS_FOR_SRC.
   GNULIB_MODULES_LIBGETTEXTPO='
@@ -325,6 +331,7 @@ if ! $skip_gnulib; then
     stpcpy
     stpncpy
     strchrnul
+    strdup-posix
     strerror
     unictype/ctype-space
     unilbrk/ulc-width-linebreaks
index 59b016ee458060cce56c53ca95e7026e8a89f656..a5ba8398fdeb324311c89074a422eb0799a8f831 100644 (file)
@@ -154,6 +154,10 @@ config.h: $(BUILT_SOURCES)
          echo '#define GTPO_CONFIG_H'; \
          echo; \
          echo '#include "../config.h"'; \
+         : "We use gnulib module 'getcwd-lgpl' here, not module 'getcwd'."; \
+         echo '#undef GNULIB_GETCWD'; \
+         : "We don't use gnulib module 'fchdir' here."; \
+         echo '#undef REPLACE_FCHDIR'; \
          : "Turn all gettext() calls into dgettext() calls."; \
          echo '#define DEFAULT_TEXT_DOMAIN "gettext-tools"'; \
          : "All code is collected in a single library,"; \