]> git.ipfire.org Git - thirdparty/gettext.git/commitdiff
libtextstyle: Don't export symbols from static MSVC .obj files.
authorBruno Haible <bruno@clisp.org>
Wed, 6 Sep 2023 18:59:36 +0000 (20:59 +0200)
committerBruno Haible <bruno@clisp.org>
Wed, 6 Sep 2023 23:41:00 +0000 (01:41 +0200)
* libtextstyle/lib/Makefile.am (config.h): Don't alias isatty to
libtextstyle_isatty here, before the Windows header files have been included.
* libtextstyle/gnulib-local/lib/isatty.c.diff: New file.
* libtextstyle/Makefile.am (EXTRA_DIST): Add it.

libtextstyle/Makefile.am
libtextstyle/gnulib-local/lib/isatty.c.diff [new file with mode: 0644]
libtextstyle/lib/Makefile.am

index ca2d03bbb3278079414818149726d4eb6f40a56a..7544f52805fbf89f6a3e4d04208f0a8718f65ebe 100644 (file)
@@ -1,5 +1,5 @@
 ## Makefile for the toplevel directory of GNU libtextstyle
-## Copyright (C) 1995-2022 Free Software Foundation, Inc.
+## Copyright (C) 1995-2023 Free Software Foundation, Inc.
 ##
 ## This program is free software: you can redistribute it and/or modify
 ## it under the terms of the GNU General Public License as published by
@@ -55,6 +55,7 @@ EXTRA_DIST = \
   gnulib-local/lib/html-styled-ostream.oo.h \
   gnulib-local/lib/iconv-ostream.oo.c \
   gnulib-local/lib/iconv-ostream.oo.h \
+  gnulib-local/lib/isatty.c.diff \
   gnulib-local/lib/libcroco/cr-additional-sel.c \
   gnulib-local/lib/libcroco/cr-additional-sel.h \
   gnulib-local/lib/libcroco/cr-attr-sel.c \
diff --git a/libtextstyle/gnulib-local/lib/isatty.c.diff b/libtextstyle/gnulib-local/lib/isatty.c.diff
new file mode 100644 (file)
index 0000000..e113322
--- /dev/null
@@ -0,0 +1,15 @@
+*** isatty.c.orig      2023-09-06 17:28:49.893388907 +0200
+--- isatty.c   2023-09-06 17:30:02.718035282 +0200
+***************
+*** 162,167 ****
+--- 162,171 ----
+  # define _isatty_nothrow _isatty
+  #endif
+  
++ #ifdef IN_LIBTEXTSTYLE
++ # define isatty libtextstyle_isatty
++ #endif
++ 
+  /* Determine whether FD refers to a console device.  Return 1 if yes.
+     Return 0 and set errno if no. (ptsname_r relies on the errno value.)  */
+  int
index 324d189dbd6cbb0393d15bc83d981e24529eeba3..b0fd3851a6e3dc723805b924da5ca8ee104aaa86 100644 (file)
@@ -216,9 +216,6 @@ config.h: $(BUILT_SOURCES) libtextstyle.sym
          echo '#include "../config.h"'; \
          echo; \
          echo '#endif /* LIBTEXTSTYLE_CONFIG_H */'; \
-         case "@host_os@" in \
-           mingw* | windows*) echo '#define isatty libtextstyle_isatty' ;; \
-         esac; \
        } > config.h && \
        if test -n "$(NAMESPACING)" && test -n "$(HAVE_GLOBAL_SYMBOL_PIPE)"; then \
          { \