]> git.ipfire.org Git - thirdparty/gettext.git/commitdiff
gettext-tools: Use a short name for DLLs on OS/2
authorKO Myung-Hun <komh78@gmail.com>
Tue, 12 Jan 2016 02:35:50 +0000 (11:35 +0900)
committerDaiki Ueno <ueno@gnu.org>
Wed, 20 Jan 2016 02:38:26 +0000 (11:38 +0900)
OS/2 does not support a DLL name longer than 8 characters.

* gettext-tools/configure.ac (OS2): Define on OS/2.
* gettext-tools/gnulib-lib/Makefile.am (libgettextlib_la_LDFLAGS):
Set a DLL name to gtlib on OS/2.
* gettext-tools/libgettextpo/Makefile.am (libgettextpo_la_LDFLAGS):
Set a DLL name to gtpo on OS/2.
* gettext-tools/src/Makefile.am (libgettextsrc_la_LDFLAGS): Set a DLL
name to gtsrc on OS/2.

gettext-tools/configure.ac
gettext-tools/gnulib-lib/Makefile.am
gettext-tools/libgettextpo/Makefile.am
gettext-tools/src/Makefile.am

index 037803f7ea9beac02ca12422b7f3c015a0e3d816..02b69abd65e21b5f7b6cfa61e85527d487730369 100644 (file)
@@ -100,10 +100,12 @@ LT_LANG([Windows Resource])
 dnl On mingw and Cygwin, we can activate special Makefile rules which add
 dnl version information to the shared libraries and executables.
 case "$host_os" in
-  mingw* | cygwin*) is_woe32=yes ;;
-  *) is_woe32=no ;;
+  mingw* | cygwin*) special_makefile_rules=woe32 ;;
+  os2*) special_makefile_rules=os2 ;;
+  *) special_makefile_rules=none ;;
 esac
-AM_CONDITIONAL([WOE32], [test $is_woe32 = yes])
+AM_CONDITIONAL([WOE32], [test $special_makefile_rules = woe32])
+AM_CONDITIONAL([OS2], [test $special_makefile_rules = os2])
 
 dnl On Cygwin 1.7.10-1 or later, error_* variables are defined in the
 dnl Cygwin DLL.  To avoid any conflict with gettext DLLs, always link
index 1da342f94a66527fdca0f6976ccc2da8b626d9f4..25c9cc1c7c13d3aab27fb03b4cc8ff7ccab7fb62 100644 (file)
@@ -61,6 +61,11 @@ include Makefile.gnulib
 # Which classes to export from the shared library.
 MOOPPFLAGS += --dllexport=styled_ostream
 
+# OS/2 does not support a DLL name longer than 8 characters.
+if OS2
+libgettextlib_la_LDFLAGS += -os2dllname gtlib
+endif
+
 # Linking with C++ libraries is needed _only_ on mingw and Cygwin.
 if !WOE32DLL
 libgettextlib_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC \
index 8aa0f3b0b97cf1e09f0e1c9343fc48fe1c11d18c..39211454ad8fbe2a17f363804ce0bcf262c28d64 100644 (file)
@@ -117,6 +117,11 @@ libgettextpo_la_SOURCES += ../woe32dll/gettextpo-exports.c
 libgettextpo_la_LDFLAGS += -Wl,--export-all-symbols
 endif
 
+# OS/2 does not support a DLL name longer than 8 characters.
+if OS2
+libgettextpo_la_LDFLAGS += -os2dllname gtpo
+endif
+
 # Version information according to Woe32 conventions.
 EXTRA_DIST += libgettextpo.rc
 if WOE32
index 63efe6e767c928dd5a5e58444bc81be390985c3c..e84702141a45eee14d0091c9e70fc1e1b7338e84 100644 (file)
@@ -255,6 +255,11 @@ libgettextsrc_la_LDFLAGS = \
   -release @VERSION@ \
   ../gnulib-lib/libgettextlib.la $(LTLIBUNISTRING) @LTLIBINTL@ @LTLIBICONV@ -lc -no-undefined
 
+# OS/2 does not support a DLL name longer than 8 characters.
+if OS2
+libgettextsrc_la_LDFLAGS += -os2dllname gtsrc
+endif
+
 libgettextsrc_la_CPPFLAGS = $(AM_CPPFLAGS) $(INCXML)
 
 # Tell the mingw or Cygwin linker which symbols to export.