From e8a3a2323d117ab0a72e4a4f489ee87ed7c5597b Mon Sep 17 00:00:00 2001 From: Bruno Haible Date: Sun, 20 Jun 2021 22:33:32 +0200 Subject: [PATCH] libgettextpo: Tidy up exported symbols. * gettext-tools/libgettextpo/Makefile.am (libgettextpo_la_LDFLAGS): Add an -export-symbols-regex option. --- gettext-tools/libgettextpo/Makefile.am | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/gettext-tools/libgettextpo/Makefile.am b/gettext-tools/libgettextpo/Makefile.am index e5688b82f..f88f8d1d6 100644 --- a/gettext-tools/libgettextpo/Makefile.am +++ b/gettext-tools/libgettextpo/Makefile.am @@ -108,11 +108,14 @@ LTV_AGE=5 # How to build libgettextpo.la. # Don't make it depend on libgettextsrc.la or libgettextlib.la, since they # define an uncontrolled amount of symbols. +# Limit the exported symbols: Don't export libgettextpo_*, except do export +# libgettextpo_version. libgettextpo_la_LIBADD = libgnu.la $(WOE32_LIBADD) $(LTLIBUNISTRING) libgettextpo_la_LDFLAGS = \ -version-info $(LTV_CURRENT):$(LTV_REVISION):$(LTV_AGE) \ -rpath $(libdir) \ - @LTLIBINTL@ @LTLIBICONV@ -lc -no-undefined + @LTLIBINTL@ @LTLIBICONV@ -lc -no-undefined \ + -export-symbols-regex '^([^l]|l[^i]|li[^b]|lib[^g]|libg[^e]|libge[^t]|libget[^t]|libgett[^e]|libgette[^x]|libgettex[^t]|libgettext[^p]|libgettextp[^o]|libgettextpo[^_]|libgettextpo_version).*' # Tell the mingw or Cygwin linker which symbols to export. if WOE32DLL -- 2.47.3