bug-gnu-utils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[PATCH] OS/2 support


From: KO Myung-Hun
Subject: [PATCH] OS/2 support
Date: Tue, 24 Feb 2009 23:54:13 +0900
User-agent: Mozilla/5.0 (OS/2; U; Warp 4.5; en-US; rv:1.8.1.19) Gecko/20081217 SeaMonkey/1.1.14 Mnenhy/0.7.6.0

Hi/2.

This patch provides some more stuffs for OS/2.

-- 
KO Myung-Hun

Using Mozilla SeaMonkey 1.1.14
Under OS/2 Warp 4 for Korean with FixPak #15
On AMD ThunderBird 1 GHz with 512 MB RAM

Korean OS/2 User Community : http://www.ecomstation.co.kr


diff -buNr build-aux/install-reloc.org build-aux/install-reloc
--- build-aux/install-reloc.org 2007-10-07 13:28:30.000000000 +0900
+++ build-aux/install-reloc     2009-02-21 03:09:20.000000000 +0900
@@ -131,6 +131,7 @@
              "$srcdir"/relocwrapper.c \
              "$srcdir"/progname.c \
              "$srcdir"/progreloc.c \
+             "$srcdir"/xmalloc.c \
              "$srcdir"/xreadlink.c \
              "$srcdir"/areadlink.c \
              "$srcdir"/readlink.c \
@@ -147,8 +148,10 @@
 rm -f relocwrapper.o \
       progname.o \
       progreloc.o \
+      xmalloc.o \
       xreadlink.o \
       areadlink.o \
+      readlink.o \
       canonicalize-lgpl.o \
       malloca.o \
       relocatable.o \
diff -buNr gettext-runtime/gnulib-lib/progreloc.c.org 
gettext-runtime/gnulib-lib/progreloc.c
--- gettext-runtime/gnulib-lib/progreloc.c.org  2007-10-07 13:28:32.000000000 
+0900
+++ gettext-runtime/gnulib-lib/progreloc.c      2009-02-20 20:58:06.000000000 
+0900
@@ -43,6 +43,11 @@
 # include <windows.h>
 #endif
 
+#ifdef __EMX__
+# define INCL_DOS
+# include <os2.h>
+#endif
+
 #include "xreadlink.h"
 #include "canonicalize.h"
 #include "relocatable.h"
@@ -162,7 +167,19 @@
     return xstrdup (location);
 #endif
   }
-#else /* Unix && !Cygwin */
+#elif defined __EMX__
+  PPIB ppib;
+  char location[CCHMAXPATH];
+
+  DosGetInfoBlocks (NULL, &ppib);
+
+  if (DosQueryModuleName (ppib->pib_hmte, sizeof (location), location))
+    return NULL;
+
+  _fnslashify (location);
+
+  return xstrdup (location);
+#else /* Unix && !Cygwin && !EMX */
 #ifdef __linux__
   /* The executable is accessible as /proc/<pid>/exe.  In newer Linux
      versions, also as /proc/self/exe.  Linux >= 2.1 provides a symlink
diff -buNr gettext-runtime/gnulib-lib/relocatable.c.org 
gettext-runtime/gnulib-lib/relocatable.c
--- gettext-runtime/gnulib-lib/relocatable.c.org        2007-10-31 
21:35:40.000000000 +0900
+++ gettext-runtime/gnulib-lib/relocatable.c    2009-02-22 18:48:48.000000000 
+0900
@@ -48,6 +48,14 @@
 # include <windows.h>
 #endif
 
+#ifdef __EMX__
+# define INCL_DOS
+# include <os2.h>
+
+#define strcmp  stricmp
+#define strncmp strnicmp
+#endif
+
 #if DEPENDS_ON_LIBCHARSET
 # include <libcharset.h>
 #endif
@@ -327,7 +335,44 @@
   return TRUE;
 }
 
-#else /* Unix except Cygwin */
+#elif defined __EMX__
+
+extern int  _CRT_init (void);
+extern void _CRT_term (void);
+extern void __ctordtorInit (void);
+extern void __ctordtorTerm (void);
+
+unsigned long _System
+_DLL_InitTerm (unsigned long hModule, unsigned long ulFlag)
+{
+  static char location[CCHMAXPATH];
+
+  switch (ulFlag)
+    {
+      case 0:
+        if (_CRT_init () == -1)
+          return 0;
+
+        __ctordtorInit();
+
+        if (DosQueryModuleName (hModule, sizeof (location), location))
+          return 0;
+
+        _fnslashify (location);
+        shared_library_fullname = strdup (location);
+        break;
+
+      case 1:
+        __ctordtorTerm();
+
+        _CRT_term ();
+        break;
+    }
+
+  return 1;
+}
+
+#else /* Unix except Cygwin and EMX */
 
 static void
 find_shared_library_fullname ()
@@ -378,15 +423,15 @@
 #endif
 }
 
-#endif /* (WIN32 or Cygwin) / (Unix except Cygwin) */
+#endif /* (WIN32 or Cygwin) / (Unix except Cygwin and EMX) */
 
 /* Return the full pathname of the current shared library.
    Return NULL if unknown.
-   Guaranteed to work only on Linux, Cygwin and Woe32.  */
+   Guaranteed to work only on Linux, Cygwin, Woe32 and EMX.  */
 static char *
 get_shared_library_fullname ()
 {
-#if !(defined _WIN32 || defined __WIN32__ || defined __CYGWIN__)
+#if !(defined _WIN32 || defined __WIN32__ || defined __CYGWIN__ || defined 
__EMX__)
   static bool tried_find_shared_library_fullname;
   if (!tried_find_shared_library_fullname)
     {
@@ -461,8 +506,30 @@
            }
        }
     }
+
+#ifdef __EMX__
+  if (pathname && ISSLASH (pathname[0]))
+    {
+      const char *unixroot = getenv ("UNIXROOT");
+
+      if (unixroot && HAS_DEVICE (unixroot) && !unixroot[2])
+        {
+          char *result = (char *) xmalloc (2 + strlen (pathname) + 1);
+#ifdef NO_XMALLOC
+          if (result != NULL)
+#endif
+            {
+              strcpy (result, unixroot);
+              strcpy (result + 2, pathname);
+              return result;
+            }
+        }
+    }
+#endif
+
   /* Nothing to relocate.  */
   return pathname;
 }
 
 #endif
+
diff -buNr gettext-runtime/intl/bindtextdom.c.org 
gettext-runtime/intl/bindtextdom.c
--- gettext-runtime/intl/bindtextdom.c.org      2006-11-06 05:49:02.000000000 
+0900
+++ gettext-runtime/intl/bindtextdom.c  2009-02-22 13:47:44.000000000 +0900
@@ -320,6 +320,27 @@
 char *
 BINDTEXTDOMAIN (const char *domainname, const char *dirname)
 {
+#ifdef __EMX__
+  char dirname_with_drive[_MAX_PATH];
+
+  if (dirname && (dirname[0] == '/' || dirname[0] == '\\' ))
+    {
+      const char *unixroot = getenv ("UNIXROOT");
+      size_t len = strlen (dirname) + 1;
+
+      if (unixroot
+          && unixroot[0] != '\0'
+          && unixroot[1] == ':'
+          && unixroot[2] == '\0'
+          && 2 + len <= _MAX_PATH)
+        {
+          memcpy (dirname_with_drive, unixroot, 2);
+          memcpy (dirname_with_drive + 2, dirname, len);
+
+          dirname = dirname_with_drive;
+        }
+    }
+#endif
   set_binding_values (domainname, &dirname, NULL);
   return (char *) dirname;
 }
diff -buNr gettext-runtime/intl/gettextP.h.org gettext-runtime/intl/gettextP.h
--- gettext-runtime/intl/gettextP.h.org 2007-10-13 09:18:22.000000000 +0900
+++ gettext-runtime/intl/gettextP.h     2009-02-22 12:47:08.000000000 +0900
@@ -220,6 +220,9 @@
 /* A counter which is incremented each time some previous translations
    become invalid.
    This variable is part of the external ABI of the GNU libintl.  */
+#ifndef _LIBC
+# define _nl_msg_cat_cntr libintl_nl_msg_cat_cntr
+#endif
 #ifdef IN_LIBGLOCALE
 # include <glocale/config.h>
 extern LIBGLOCALE_DLL_EXPORTED int _nl_msg_cat_cntr;
diff -buNr gettext-runtime/intl/os2compat.c.org gettext-runtime/intl/os2compat.c
--- gettext-runtime/intl/os2compat.c.org        2005-05-20 14:05:52.000000000 
+0900
+++ gettext-runtime/intl/os2compat.c    2009-02-22 13:39:54.000000000 +0900
@@ -25,8 +25,8 @@
 #include <string.h>
 #include <sys/param.h>
 
-/* A version of getenv() that works from DLLs */
-extern unsigned long DosScanEnv (const unsigned char *pszName, unsigned char 
**ppszValue);
+#define INCL_DOS
+#include <os2.h>
 
 char *
 _nl_getenv (const char *name)
diff -buNr gettext-runtime/intl/os2compat.h.org gettext-runtime/intl/os2compat.h
--- gettext-runtime/intl/os2compat.h.org        2005-05-20 14:05:52.000000000 
+0900
+++ gettext-runtime/intl/os2compat.h    2009-02-22 23:38:04.000000000 +0900
@@ -17,7 +17,7 @@
    Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
    USA.  */
 
-/* When included from os2compat.h we need all the original definitions */
+/* When included from os2compat.c we need all the original definitions */
 #ifndef OS2_AWARE
 
 #undef LIBDIR
@@ -39,8 +39,11 @@
 #define strcasecmp stricmp
 #define strncasecmp strnicmp
 
+/* We don't have to use our own getenv() out of libintl */
+#ifdef IN_LIBINTL
 /* We have our own getenv() which works even if library is compiled as DLL */
-#define getenv _nl_getenv
+# define getenv _nl_getenv
+#endif
 
 /* Older versions of gettext used -1 as the value of LC_MESSAGES */
 #define LC_MESSAGES_COMPAT (-1)
diff -buNr gettext-runtime/intl/relocatable.c.org 
gettext-runtime/intl/relocatable.c
--- gettext-runtime/intl/relocatable.c.org      2006-10-09 05:00:24.000000000 
+0900
+++ gettext-runtime/intl/relocatable.c  2009-02-22 18:48:50.000000000 +0900
@@ -48,6 +48,14 @@
 # include <windows.h>
 #endif
 
+#ifdef __EMX__
+# define INCL_DOS
+# include <os2.h>
+
+#define strcmp  stricmp
+#define strncmp strnicmp
+#endif
+
 #if DEPENDS_ON_LIBCHARSET
 # include <libcharset.h>
 #endif
@@ -327,7 +335,44 @@
   return TRUE;
 }
 
-#else /* Unix except Cygwin */
+#elif defined __EMX__
+
+extern int  _CRT_init (void);
+extern void _CRT_term (void);
+extern void __ctordtorInit (void);
+extern void __ctordtorTerm (void);
+
+unsigned long _System
+_DLL_InitTerm (unsigned long hModule, unsigned long ulFlag)
+{
+  static char location[CCHMAXPATH];
+
+  switch (ulFlag)
+  {
+    case 0:
+      if (_CRT_init () == -1)
+        return 0;
+
+      __ctordtorInit();
+
+      if (DosQueryModuleName (hModule, sizeof (location), location))
+        return 0;
+
+      _fnslashify (location);
+      shared_library_fullname = strdup (location);
+      break;
+
+    case 1:
+      __ctordtorTerm();
+
+      _CRT_term ();
+      break;
+  }
+
+  return 1;
+}
+
+#else /* Unix except Cygwin and EMX */
 
 static void
 find_shared_library_fullname ()
@@ -378,15 +423,15 @@
 #endif
 }
 
-#endif /* (WIN32 or Cygwin) / (Unix except Cygwin) */
+#endif /* (WIN32 or Cygwin) / (Unix except Cygwin and EMX) */
 
 /* Return the full pathname of the current shared library.
    Return NULL if unknown.
-   Guaranteed to work only on Linux, Cygwin and Woe32.  */
+   Guaranteed to work only on Linux, Cygwin, Woe32 and EMX.  */
 static char *
 get_shared_library_fullname ()
 {
-#if !(defined _WIN32 || defined __WIN32__ || defined __CYGWIN__)
+#if !(defined _WIN32 || defined __WIN32__ || defined __CYGWIN__ || defined 
__EMX__)
   static bool tried_find_shared_library_fullname;
   if (!tried_find_shared_library_fullname)
     {
@@ -461,6 +506,27 @@
            }
        }
     }
+
+#ifdef __EMX__
+  if (pathname && ISSLASH (pathname[0]))
+    {
+      const char *unixroot = getenv ("UNIXROOT");
+
+      if (unixroot && HAS_DEVICE (unixroot) && !unixroot[2])
+        {
+          char *result = (char *) xmalloc (2 + strlen (pathname) + 1);
+#ifdef NO_XMALLOC
+          if (result != NULL)
+#endif
+            {
+              strcpy (result, unixroot);
+              strcpy (result + 2, pathname);
+              return result;
+            }
+        }
+    }
+#endif
+
   /* Nothing to relocate.  */
   return pathname;
 }
diff -buNr gettext-tools/Makefile.am.org gettext-tools/Makefile.am
--- gettext-tools/Makefile.am.org       2007-10-28 08:22:22.000000000 +0900
+++ gettext-tools/Makefile.am   2009-02-22 21:36:44.000000000 +0900
@@ -46,6 +46,11 @@
 $(srcdir)/ABOUT-NLS: $(srcdir)/../gettext-runtime/ABOUT-NLS
        cp $(srcdir)/../gettext-runtime/ABOUT-NLS $(srcdir)/ABOUT-NLS
 
+# config.h need intl/os2compat.h
+config.h: $(srcdir)/intl/os2compat.h
+$(srcdir)/intl/os2compat.h: $(srcdir)/../gettext-runtime/intl/os2compat.h
+       cp $(srcdir)/../gettext-runtime/intl/os2compat.h 
$(srcdir)/intl/os2compat.h
+
 
 # Allow users to use "gnulib-tool --update".
 EXTRA_DIST += gnulib-m4/gnulib-cache.m4
diff -buNr gettext-tools/gnulib-lib/binary-io.h.org 
gettext-tools/gnulib-lib/binary-io.h
--- gettext-tools/gnulib-lib/binary-io.h.org    2007-10-07 13:29:38.000000000 
+0900
+++ gettext-tools/gnulib-lib/binary-io.h        2009-02-21 13:37:04.000000000 
+0900
@@ -41,10 +41,10 @@
 #  undef fileno
 #  define fileno _fileno
 # endif
-# if defined __DJGPP__ || defined __CYGWIN__
+# if defined __DJGPP__ || defined __CYGWIN__ || defined __EMX__
 #  include <io.h> /* declares setmode() */
 # endif
-# ifdef __DJGPP__
+# if defined __DJGPP__ || defined __EMX__
 #  include <unistd.h> /* declares isatty() */
 #  /* Avoid putting stdin/stdout in binary mode if it is connected to the
 #     console, because that would make it impossible for the user to
diff -buNr gettext-tools/gnulib-lib/progreloc.c.org 
gettext-tools/gnulib-lib/progreloc.c
--- gettext-tools/gnulib-lib/progreloc.c.org    2007-10-07 13:29:04.000000000 
+0900
+++ gettext-tools/gnulib-lib/progreloc.c        2009-02-21 00:05:06.000000000 
+0900
@@ -43,6 +43,11 @@
 # include <windows.h>
 #endif
 
+#ifdef __EMX__
+# define INCL_DOS
+# include <os2.h>
+#endif
+
 #include "xreadlink.h"
 #include "canonicalize.h"
 #include "relocatable.h"
@@ -162,7 +167,19 @@
     return xstrdup (location);
 #endif
   }
-#else /* Unix && !Cygwin */
+#elif defined __EMX__
+  PPIB ppib;
+  char location[CCHMAXPATH];
+
+  DosGetInfoBlocks (NULL, &ppib);
+
+  if (DosQueryModuleName (ppib->pib_hmte, sizeof (location), location))
+    return NULL;
+
+  _fnslashify (location);
+
+  return xstrdup (location);
+#else /* Unix && !Cygwin && !EMX */
 #ifdef __linux__
   /* The executable is accessible as /proc/<pid>/exe.  In newer Linux
      versions, also as /proc/self/exe.  Linux >= 2.1 provides a symlink
diff -buNr gettext-tools/gnulib-lib/relocatable.c.org 
gettext-tools/gnulib-lib/relocatable.c
--- gettext-tools/gnulib-lib/relocatable.c.org  2007-10-31 21:35:40.000000000 
+0900
+++ gettext-tools/gnulib-lib/relocatable.c      2009-02-22 18:48:50.000000000 
+0900
@@ -48,6 +48,14 @@
 # include <windows.h>
 #endif
 
+#ifdef __EMX__
+# define INCL_DOS
+# include <os2.h>
+
+#define strcmp  stricmp
+#define strncmp strnicmp
+#endif
+
 #if DEPENDS_ON_LIBCHARSET
 # include <libcharset.h>
 #endif
@@ -327,7 +335,44 @@
   return TRUE;
 }
 
-#else /* Unix except Cygwin */
+#elif defined __EMX__
+
+extern int  _CRT_init (void);
+extern void _CRT_term (void);
+extern void __ctordtorInit (void);
+extern void __ctordtorTerm (void);
+
+unsigned long _System
+_DLL_InitTerm (unsigned long hModule, unsigned long ulFlag)
+{
+  static char location[CCHMAXPATH];
+
+  switch (ulFlag)
+  {
+    case 0:
+      if (_CRT_init () == -1)
+        return 0;
+
+      __ctordtorInit();
+
+      if (DosQueryModuleName (hModule, sizeof (location), location))
+        return 0;
+
+      _fnslashify (location);
+      shared_library_fullname = strdup (location);
+      break;
+
+    case 1:
+      __ctordtorTerm();
+
+      _CRT_term ();
+      break;
+  }
+
+  return 1;
+}
+
+#else /* Unix except Cygwin and EMX */
 
 static void
 find_shared_library_fullname ()
@@ -378,15 +423,15 @@
 #endif
 }
 
-#endif /* (WIN32 or Cygwin) / (Unix except Cygwin) */
+#endif /* (WIN32 or Cygwin) / (Unix except Cygwin and EMX) */
 
 /* Return the full pathname of the current shared library.
    Return NULL if unknown.
-   Guaranteed to work only on Linux, Cygwin and Woe32.  */
+   Guaranteed to work only on Linux, Cygwin, Woe32 and EMX.  */
 static char *
 get_shared_library_fullname ()
 {
-#if !(defined _WIN32 || defined __WIN32__ || defined __CYGWIN__)
+#if !(defined _WIN32 || defined __WIN32__ || defined __CYGWIN__ || defined 
__EMX__)
   static bool tried_find_shared_library_fullname;
   if (!tried_find_shared_library_fullname)
     {
@@ -461,6 +506,27 @@
            }
        }
     }
+
+#ifdef __EMX__
+  if (pathname && ISSLASH (pathname[0]))
+    {
+      const char *unixroot = getenv ("UNIXROOT");
+
+      if (unixroot && HAS_DEVICE (unixroot) && !unixroot[2])
+        {
+          char *result = (char *) xmalloc (2 + strlen (pathname) + 1);
+#ifdef NO_XMALLOC
+          if (result != NULL)
+#endif
+            {
+              strcpy (result, unixroot);
+              strcpy (result + 2, pathname);
+              return result;
+            }
+        }
+    }
+#endif
+
   /* Nothing to relocate.  */
   return pathname;
 }
diff -buNr gettext-tools/libgettextpo/relocatable.c.org 
gettext-tools/libgettextpo/relocatable.c
--- gettext-tools/libgettextpo/relocatable.c.org        2007-10-31 
21:35:40.000000000 +0900
+++ gettext-tools/libgettextpo/relocatable.c    2009-02-22 18:48:48.000000000 
+0900
@@ -48,6 +48,14 @@
 # include <windows.h>
 #endif
 
+#ifdef __EMX__
+# define INCL_DOS
+# include <os2.h>
+
+#define strcmp  stricmp
+#define strncmp strnicmp
+#endif
+
 #if DEPENDS_ON_LIBCHARSET
 # include <libcharset.h>
 #endif
@@ -327,7 +335,44 @@
   return TRUE;
 }
 
-#else /* Unix except Cygwin */
+#elif defined __EMX__
+
+extern int  _CRT_init (void);
+extern void _CRT_term (void);
+extern void __ctordtorInit (void);
+extern void __ctordtorTerm (void);
+
+unsigned long _System
+_DLL_InitTerm (unsigned long hModule, unsigned long ulFlag)
+{
+  static char location[CCHMAXPATH];
+
+  switch (ulFlag)
+  {
+    case 0:
+      if (_CRT_init () == -1)
+        return 0;
+
+      __ctordtorInit();
+
+      if (DosQueryModuleName (hModule, sizeof (location), location))
+        return 0;
+
+      _fnslashify (location);
+      shared_library_fullname = strdup (location);
+      break;
+
+    case 1:
+      __ctordtorTerm();
+
+      _CRT_term ();
+      break;
+  }
+
+  return 1;
+}
+
+#else /* Unix except Cygwin and EMX */
 
 static void
 find_shared_library_fullname ()
@@ -378,15 +423,15 @@
 #endif
 }
 
-#endif /* (WIN32 or Cygwin) / (Unix except Cygwin) */
+#endif /* (WIN32 or Cygwin) / (Unix except Cygwin and EMX) */
 
 /* Return the full pathname of the current shared library.
    Return NULL if unknown.
-   Guaranteed to work only on Linux, Cygwin and Woe32.  */
+   Guaranteed to work only on Linux, Cygwin, Woe32 and EMX.  */
 static char *
 get_shared_library_fullname ()
 {
-#if !(defined _WIN32 || defined __WIN32__ || defined __CYGWIN__)
+#if !(defined _WIN32 || defined __WIN32__ || defined __CYGWIN__ || defined 
__EMX__)
   static bool tried_find_shared_library_fullname;
   if (!tried_find_shared_library_fullname)
     {
@@ -461,6 +506,27 @@
            }
        }
     }
+
+#ifdef __EMX__
+  if (pathname && ISSLASH (pathname[0]))
+    {
+      const char *unixroot = getenv ("UNIXROOT");
+
+      if (unixroot && HAS_DEVICE (unixroot) && !unixroot[2])
+        {
+          char *result = (char *) xmalloc (2 + strlen (pathname) + 1);
+#ifdef NO_XMALLOC
+          if (result != NULL)
+#endif
+            {
+              strcpy (result, unixroot);
+              strcpy (result + 2, pathname);
+              return result;
+            }
+        }
+    }
+#endif
+
   /* Nothing to relocate.  */
   return pathname;
 }
diff -buNr gettext-tools/src/Makefile.am.org gettext-tools/src/Makefile.am
--- gettext-tools/src/Makefile.am.org   2007-10-07 12:37:12.000000000 +0900
+++ gettext-tools/src/Makefile.am       2009-02-22 16:20:46.000000000 +0900
@@ -235,22 +235,22 @@
 # INTL_MACOSX_LIBS is needed because the programs depend on libintl.la
 # but libtool doesn't put -Wl,-framework options into .la files.
 # For msginit, it is also needed because of localename.c.
-msgcmp_LDADD = libgettextsrc.la @INTL_MACOSX_LIBS@ $(WOE32_LDADD)
-msgfmt_LDADD = libgettextsrc.la @INTL_MACOSX_LIBS@ $(WOE32_LDADD)
-msgmerge_LDADD = libgettextsrc.la @INTL_MACOSX_LIBS@ @MSGMERGE_LIBM@ 
$(WOE32_LDADD) $(OPENMP_CFLAGS)
-msgunfmt_LDADD = libgettextsrc.la @INTL_MACOSX_LIBS@ $(WOE32_LDADD)
-xgettext_LDADD = libgettextsrc.la @INTL_MACOSX_LIBS@ @LTLIBEXPAT@ 
$(WOE32_LDADD)
-msgattrib_LDADD = libgettextsrc.la @INTL_MACOSX_LIBS@ $(WOE32_LDADD)
-msgcat_LDADD = libgettextsrc.la @INTL_MACOSX_LIBS@ $(WOE32_LDADD)
-msgcomm_LDADD = libgettextsrc.la @INTL_MACOSX_LIBS@ $(WOE32_LDADD)
-msgconv_LDADD = libgettextsrc.la @INTL_MACOSX_LIBS@ $(WOE32_LDADD)
-msgen_LDADD = libgettextsrc.la @INTL_MACOSX_LIBS@ $(WOE32_LDADD)
-msgexec_LDADD = libgettextsrc.la @INTL_MACOSX_LIBS@ $(WOE32_LDADD)
-msgfilter_LDADD = libgettextsrc.la @INTL_MACOSX_LIBS@ $(WOE32_LDADD)
-msggrep_LDADD = $(LIBGREP) libgettextsrc.la @INTL_MACOSX_LIBS@ $(WOE32_LDADD)
-msginit_LDADD = libgettextsrc.la @INTL_MACOSX_LIBS@ $(WOE32_LDADD)
-msguniq_LDADD = libgettextsrc.la @INTL_MACOSX_LIBS@ $(WOE32_LDADD)
-recode_sr_latin_LDADD = ../gnulib-lib/libgettextlib.la @INTL_MACOSX_LIBS@ 
$(WOE32_LDADD)
+msgcmp_LDADD = libgettextsrc.la @INTL_MACOSX_LIBS@ $(LDADD)
+msgfmt_LDADD = libgettextsrc.la @INTL_MACOSX_LIBS@ $(LDADD)
+msgmerge_LDADD = libgettextsrc.la @INTL_MACOSX_LIBS@ @MSGMERGE_LIBM@ $(LDADD) 
$(OPENMP_CFLAGS)
+msgunfmt_LDADD = libgettextsrc.la @INTL_MACOSX_LIBS@ $(LDADD)
+xgettext_LDADD = libgettextsrc.la @INTL_MACOSX_LIBS@ @LTLIBEXPAT@ $(LDADD)
+msgattrib_LDADD = libgettextsrc.la @INTL_MACOSX_LIBS@ $(LDADD)
+msgcat_LDADD = libgettextsrc.la @INTL_MACOSX_LIBS@ $(LDADD)
+msgcomm_LDADD = libgettextsrc.la @INTL_MACOSX_LIBS@ $(LDADD)
+msgconv_LDADD = libgettextsrc.la @INTL_MACOSX_LIBS@ $(LDADD)
+msgen_LDADD = libgettextsrc.la @INTL_MACOSX_LIBS@ $(LDADD)
+msgexec_LDADD = libgettextsrc.la @INTL_MACOSX_LIBS@ $(LDADD)
+msgfilter_LDADD = libgettextsrc.la @INTL_MACOSX_LIBS@ $(LDADD)
+msggrep_LDADD = $(LIBGREP) libgettextsrc.la @INTL_MACOSX_LIBS@ $(LDADD)
+msginit_LDADD = libgettextsrc.la @INTL_MACOSX_LIBS@ $(LDADD)
+msguniq_LDADD = libgettextsrc.la @INTL_MACOSX_LIBS@ $(LDADD)
+recode_sr_latin_LDADD = ../gnulib-lib/libgettextlib.la @INTL_MACOSX_LIBS@ 
$(LDADD)
 
 # Specify installation directory, for --enable-relocatable.
 msgcmp_CPPFLAGS = $(AM_CPPFLAGS) -DINSTALLDIR=\"$(bindir)\"
diff -buNr gettext-tools/src/msginit.c.org gettext-tools/src/msginit.c
--- gettext-tools/src/msginit.c.org     2007-10-07 12:37:12.000000000 +0900
+++ gettext-tools/src/msginit.c 2009-02-22 19:52:20.000000000 +0900
@@ -819,7 +819,7 @@
 
   gettextlibdir = getenv ("GETTEXTLIBDIR");
   if (gettextlibdir == NULL || gettextlibdir[0] == '\0')
-    gettextlibdir = relocate (LIBDIR "/gettext");
+    gettextlibdir = relocate (concatenated_filename (LIBDIR, "/gettext", 
NULL));
 
   prog = concatenated_filename (gettextlibdir, "project-id", NULL);
 
@@ -893,7 +893,7 @@
 
   gettextlibdir = getenv ("GETTEXTLIBDIR");
   if (gettextlibdir == NULL || gettextlibdir[0] == '\0')
-    gettextlibdir = relocate (LIBDIR "/gettext");
+    gettextlibdir = relocate (concatenated_filename (LIBDIR, "/gettext", 
NULL));
 
   prog = concatenated_filename (gettextlibdir, "project-id", NULL);
 
@@ -1044,7 +1044,7 @@
 static const char *
 get_user_email ()
 {
-  const char *prog = relocate (LIBDIR "/gettext/user-email");
+  const char *prog = relocate (concatenated_filename (LIBDIR, 
"/gettext/user-email", NULL));
   char *argv[4];
   pid_t child;
   int fd[1];
@@ -1157,7 +1157,7 @@
   argv[0] = "/bin/sh";
   argv[1] = (char *) prog;
   argv[2] = (char *) relocate (PROJECTSDIR);
-  argv[3] = (char *) relocate (LIBDIR "/gettext");
+  argv[3] = (char *) relocate (concatenated_filename (LIBDIR, "/gettext", 
NULL));
   argv[4] = (char *) catalogname;
   argv[5] = (char *) language;
   argv[6] = NULL;
diff -buNr gettext-tools/src/read-csharp.c.org gettext-tools/src/read-csharp.c
--- gettext-tools/src/read-csharp.c.org 2007-10-07 12:37:12.000000000 +0900
+++ gettext-tools/src/read-csharp.c     2009-02-22 19:52:20.000000000 +0900
@@ -141,7 +141,7 @@
      necessary for running the testsuite before "make install".  */
   gettextexedir = getenv ("GETTEXTCSHARPEXEDIR");
   if (gettextexedir == NULL || gettextexedir[0] == '\0')
-    gettextexedir = relocate (LIBDIR "/gettext");
+    gettextexedir = relocate (concatenated_filename (LIBDIR, "/gettext", 
NULL));
 
   /* Make it possible to override the .dll location.  This is
      necessary for running the testsuite before "make install".  */
diff -buNr gettext-tools/src/read-resources.c.org 
gettext-tools/src/read-resources.c
--- gettext-tools/src/read-resources.c.org      2007-10-07 12:37:12.000000000 
+0900
+++ gettext-tools/src/read-resources.c  2009-02-22 19:51:00.000000000 +0900
@@ -105,7 +105,7 @@
      necessary for running the testsuite before "make install".  */
   gettextexedir = getenv ("GETTEXTCSHARPEXEDIR");
   if (gettextexedir == NULL || gettextexedir[0] == '\0')
-    gettextexedir = relocate (LIBDIR "/gettext");
+    gettextexedir = relocate (concatenated_filename (LIBDIR, "/gettext", 
NULL));
 
   /* Make it possible to override the .dll location.  This is
      necessary for running the testsuite before "make install".  */
diff -buNr gettext-tools/src/write-resources.c.org 
gettext-tools/src/write-resources.c
--- gettext-tools/src/write-resources.c.org     2007-10-07 12:37:14.000000000 
+0900
+++ gettext-tools/src/write-resources.c 2009-02-22 19:51:00.000000000 +0900
@@ -171,7 +171,7 @@
           necessary for running the testsuite before "make install".  */
        gettextexedir = getenv ("GETTEXTCSHARPEXEDIR");
        if (gettextexedir == NULL || gettextexedir[0] == '\0')
-         gettextexedir = relocate (LIBDIR "/gettext");
+         gettextexedir = relocate (concatenated_filename (LIBDIR, "/gettext", 
NULL));
 
        assembly_path =
          concatenated_filename (gettextexedir, "msgfmt.net", ".exe");

reply via email to

[Prev in Thread] Current Thread [Next in Thread]