gettext: update to 0.21
This commit is contained in:
@@ -1,876 +0,0 @@
|
||||
From: Erwin Waterlander <waterlan@xs4all.nl>
|
||||
Subject: [PATCH] 00-relocatex-libintl-0.18.3.1.patch
|
||||
|
||||
The relocatex-libintl patch adds builtin relocation for executables to the
|
||||
libintl dll. With this patch the programs are automatically relocatable. There
|
||||
is no need anymore to add relocation code to your program when you use this
|
||||
libintl DLL.
|
||||
|
||||
The patch was ported from the GnuWin32 port of libintl, which has also builtin
|
||||
relacation support.
|
||||
|
||||
At the moment the relocation support is only active if you compile with MinGW
|
||||
for Windows. If you compile for Unix/Linux/Cygwin the functionality is
|
||||
unchanged.
|
||||
|
||||
See also:
|
||||
http://waterlan.home.xs4all.nl/libintl.html
|
||||
http://sourceforge.net/tracker/?func=detail&atid=302435&aid=3003879&group_id=2435
|
||||
GnuWin32: http://gnuwin32.sourceforge.net/
|
||||
|
||||
Great thanks to GnuWin32 maintainer Kees Zeelenberg.
|
||||
|
||||
[jes: fixed for 64-bit]
|
||||
|
||||
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
|
||||
---
|
||||
MINGW-PATCHES/README-relocatex-libintl.txt | 23 ++
|
||||
gettext-runtime/intl/Makefile.in | 9 +
|
||||
gettext-runtime/intl/bindtextdom.c | 22 ++
|
||||
gettext-runtime/intl/canonicalize.c | 343 +++++++++++++++++++++++++++++
|
||||
gettext-runtime/intl/canonicalize.h | 18 ++
|
||||
gettext-runtime/intl/relocatex.c | 284 ++++++++++++++++++++++++
|
||||
gettext-runtime/intl/relocatex.h | 41 ++++
|
||||
7 files changed, 740 insertions(+)
|
||||
create mode 100644 MINGW-PATCHES/README-relocatex-libintl.txt
|
||||
create mode 100644 gettext-runtime/intl/canonicalize.c
|
||||
create mode 100644 gettext-runtime/intl/canonicalize.h
|
||||
create mode 100644 gettext-runtime/intl/relocatex.c
|
||||
create mode 100644 gettext-runtime/intl/relocatex.h
|
||||
|
||||
diff --git a/MINGW-PATCHES/README-relocatex-libintl.txt b/MINGW-PATCHES/README-relocatex-libintl.txt
|
||||
new file mode 100644
|
||||
index 0000000..06f6a02
|
||||
--- /dev/null
|
||||
+++ b/MINGW-PATCHES/README-relocatex-libintl.txt
|
||||
@@ -0,0 +1,23 @@
|
||||
+The relocatex-libintl patch adds builtin relocation for executables to the
|
||||
+libintl dll. With this patch the programs are automatically relocatable. There
|
||||
+is no need anymore to add relocation code to your program when you use this
|
||||
+libintl DLL.
|
||||
+
|
||||
+The patch was ported from the GnuWin32 port of libintl, which has also builtin
|
||||
+relacation support.
|
||||
+
|
||||
+At the moment the relocation support is only active if you compile with MinGW
|
||||
+for Windows. If you compile for Unix/Linux/Cygwin the functionality is
|
||||
+unchanged.
|
||||
+
|
||||
+See also:
|
||||
+http://waterlan.home.xs4all.nl/libintl.html
|
||||
+http://sourceforge.net/tracker/?func=detail&atid=302435&aid=3003879&group_id=2435
|
||||
+GnuWin32: http://gnuwin32.sourceforge.net/
|
||||
+
|
||||
+Great thanks to GnuWin32 maintainer Kees Zeelenberg.
|
||||
+
|
||||
+Erwin Waterlander
|
||||
+waterlan@xs4all.nl
|
||||
+http://waterlan.home.xs4all.nl/
|
||||
+
|
||||
diff --git a/gettext-runtime/intl/Makefile.in b/gettext-runtime/intl/Makefile.in
|
||||
index 2acfb2e..d6c270b 100644
|
||||
--- a/gettext-runtime/intl/Makefile.in
|
||||
+++ b/gettext-runtime/intl/Makefile.in
|
||||
@@ -126,6 +126,7 @@ HEADERS = \
|
||||
localcharset.h \
|
||||
lock.h \
|
||||
relocatable.h \
|
||||
+ relocatex.h \
|
||||
tsearch.h tsearch.c \
|
||||
verify.h \
|
||||
xsize.h \
|
||||
@@ -156,6 +157,8 @@ SOURCES = \
|
||||
threadlib.c \
|
||||
lock.c \
|
||||
relocatable.c \
|
||||
+ relocatex.c \
|
||||
+ canonicalize.c \
|
||||
langprefs.c \
|
||||
localename.c \
|
||||
log.c \
|
||||
@@ -189,6 +192,8 @@ OBJECTS = \
|
||||
threadlib.$lo \
|
||||
lock.$lo \
|
||||
relocatable.$lo \
|
||||
+ relocatex.$lo \
|
||||
+ canonicalize.$lo \
|
||||
langprefs.$lo \
|
||||
localename.$lo \
|
||||
log.$lo \
|
||||
@@ -298,6 +303,10 @@ threadlib.lo: $(srcdir)/threadlib.c
|
||||
$(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC --mode=compile $(COMPILE) $(srcdir)/threadlib.c
|
||||
lock.lo: $(srcdir)/lock.c
|
||||
$(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC --mode=compile $(COMPILE) $(srcdir)/lock.c
|
||||
+relocatex.lo: $(srcdir)/relocatex.c
|
||||
+ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC --mode=compile $(COMPILE) $(srcdir)/relocatex.c
|
||||
+canonicalize.lo: $(srcdir)/canonicalize.c
|
||||
+ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC --mode=compile $(COMPILE) $(srcdir)/canonicalize.c
|
||||
relocatable.lo: $(srcdir)/relocatable.c
|
||||
$(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC --mode=compile $(COMPILE) $(srcdir)/relocatable.c
|
||||
langprefs.lo: $(srcdir)/langprefs.c
|
||||
diff --git a/gettext-runtime/intl/bindtextdom.c b/gettext-runtime/intl/bindtextdom.c
|
||||
index 2e7ada4..bd0cddd 100644
|
||||
--- a/gettext-runtime/intl/bindtextdom.c
|
||||
+++ b/gettext-runtime/intl/bindtextdom.c
|
||||
@@ -22,6 +22,7 @@
|
||||
#include <stddef.h>
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
+#include <unistd.h>
|
||||
|
||||
#include "gettextP.h"
|
||||
#ifdef _LIBC
|
||||
@@ -66,6 +67,12 @@ gl_rwlock_define (extern, _nl_state_lock attribute_hidden)
|
||||
# define BIND_TEXTDOMAIN_CODESET libintl_bind_textdomain_codeset
|
||||
#endif
|
||||
|
||||
+#if ENABLE_RELOCATABLE
|
||||
+# include "relocatex.h"
|
||||
+#else
|
||||
+# define relocate(pathname) (pathname)
|
||||
+#endif
|
||||
+
|
||||
/* Specifies the directory name *DIRNAMEP and the output codeset *CODESETP
|
||||
to be used for the DOMAINNAME message catalog.
|
||||
If *DIRNAMEP or *CODESETP is NULL, the corresponding attribute is not
|
||||
@@ -318,11 +325,22 @@ set_binding_values (const char *domainname,
|
||||
}
|
||||
}
|
||||
#endif
|
||||
- set_binding_values (domainname, &dirname, NULL);
|
||||
-#ifdef __EMX__
|
||||
- dirname = saved_dirname;
|
||||
-#endif
|
||||
- return (char *) dirname;
|
||||
+ if (!dirname || !access (dirname, R_OK)) {
|
||||
+ set_binding_values (domainname, &dirname, NULL);
|
||||
+#ifdef __EMX__
|
||||
+ dirname = saved_dirname;
|
||||
+#endif
|
||||
+ return (char *) dirname;
|
||||
+ } else {
|
||||
+ char *locale_dirname, *installdir = strdup (dirname), *s;
|
||||
+ if ((s = strrchr (installdir, '/'))) *s = '\0';
|
||||
+ if ((s = strrchr (installdir, '/'))) *s = '\0';
|
||||
+ locale_dirname = relocatex (installdir, dirname);
|
||||
+ set_binding_values (domainname, (const char **) &locale_dirname, NULL);
|
||||
+ if (installdir)
|
||||
+ free (installdir);
|
||||
+ return (char *) locale_dirname;
|
||||
+ }
|
||||
}
|
||||
|
||||
/* Specify the character encoding in which the messages from the
|
||||
diff --git a/gettext-runtime/intl/canonicalize.c b/gettext-runtime/intl/canonicalize.c
|
||||
new file mode 100644
|
||||
index 0000000..ae2aa93
|
||||
--- /dev/null
|
||||
+++ b/gettext-runtime/intl/canonicalize.c
|
||||
@@ -0,0 +1,343 @@
|
||||
+/* Return the canonical absolute name of a given file.
|
||||
+ Copyright (C) 1996, 1997, 1998, 1999, 2000 Free Software Foundation, Inc.
|
||||
+ This file is part of the GNU C Library.
|
||||
+
|
||||
+ The GNU C Library is free software; you can redistribute it and/or
|
||||
+ modify it under the terms of the GNU Lesser General Public
|
||||
+ License as published by the Free Software Foundation; either
|
||||
+ version 2.1 of the License, or (at your option) any later version.
|
||||
+
|
||||
+ The GNU C Library is distributed in the hope that it will be useful,
|
||||
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
+ Lesser General Public License for more details.
|
||||
+
|
||||
+ You should have received a copy of the GNU Lesser General Public
|
||||
+ License along with the GNU C Library; if not, write to the Free
|
||||
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
|
||||
+ 02111-1307 USA. */
|
||||
+
|
||||
+#include <stdlib.h>
|
||||
+#include <string.h>
|
||||
+#include <unistd.h>
|
||||
+#include <limits.h>
|
||||
+#include <sys/param.h>
|
||||
+#include <sys/stat.h>
|
||||
+#include <errno.h>
|
||||
+#include <stddef.h>
|
||||
+#include <malloc.h>
|
||||
+#ifdef __WIN32__
|
||||
+# include <stdio.h>
|
||||
+# include <windows.h>
|
||||
+//# include <gw32.h>
|
||||
+#endif /* __WIN32__ */
|
||||
+#include "canonicalize.h"
|
||||
+
|
||||
+#ifndef MAXSYMLINKS
|
||||
+# define MAXSYMLINKS 20
|
||||
+#endif
|
||||
+
|
||||
+#ifndef __set_errno
|
||||
+# define __set_errno(Val) errno = (Val)
|
||||
+#endif
|
||||
+
|
||||
+# ifdef VMS
|
||||
+ /* We want the directory in Unix syntax, not in VMS syntax. */
|
||||
+# define __getcwd(buf, max) getcwd (buf, max, 0)
|
||||
+# else
|
||||
+# define __getcwd getcwd
|
||||
+# endif
|
||||
+
|
||||
+#define weak_alias(local, symbol)
|
||||
+
|
||||
+#if defined _WIN32 || defined __WIN32__ || defined __CYGWIN__ || defined __EMX__ || defined __DJGPP__
|
||||
+ /* Win32, Cygwin, OS/2, DOS */
|
||||
+# define ISDIRSEP(C) ((C) == '/' || (C) == '\\')
|
||||
+#else
|
||||
+ /* Unix */
|
||||
+# define ISDIRSEP(C) ((C) == '/')
|
||||
+#endif
|
||||
+
|
||||
+#ifdef __WIN32__
|
||||
+char *win2unixpath (char *FileName)
|
||||
+{
|
||||
+ char *s = FileName;
|
||||
+ while (*s) {
|
||||
+ if (*s == '\\')
|
||||
+ *s = '/';
|
||||
+ *s++;
|
||||
+ }
|
||||
+ return FileName;
|
||||
+}
|
||||
+#endif
|
||||
+
|
||||
+/* Return the canonical absolute name of file NAME. A canonical name
|
||||
+ does not contain any `.', `..' components nor any repeated path
|
||||
+ separators ('/') or symlinks. All path components must exist. If
|
||||
+ RESOLVED is null, the result is malloc'd; otherwise, if the
|
||||
+ canonical name is PATH_MAX chars or more, returns null with `errno'
|
||||
+ set to ENAMETOOLONG; if the name fits in fewer than PATH_MAX chars,
|
||||
+ returns the name in RESOLVED. If the name cannot be resolved and
|
||||
+ RESOLVED is non-NULL, it contains the path of the first component
|
||||
+ that cannot be resolved. If the path can be resolved, RESOLVED
|
||||
+ holds the same value as the value returned.
|
||||
+ RESOLVED must be at least PATH_MAX long */
|
||||
+
|
||||
+static char *
|
||||
+canonicalize (const char *name, char *resolved)
|
||||
+{
|
||||
+ char *rpath, *dest, *extra_buf = NULL;
|
||||
+ const char *start, *end, *rpath_limit;
|
||||
+ long int path_max;
|
||||
+ int num_links = 0, old_errno;
|
||||
+
|
||||
+ if (name == NULL)
|
||||
+ {
|
||||
+ /* As per Single Unix Specification V2 we must return an error if
|
||||
+ either parameter is a null pointer. We extend this to allow
|
||||
+ the RESOLVED parameter to be NULL in case the we are expected to
|
||||
+ allocate the room for the return value. */
|
||||
+ __set_errno (EINVAL);
|
||||
+ return NULL;
|
||||
+ }
|
||||
+
|
||||
+ if (name[0] == '\0')
|
||||
+ {
|
||||
+ /* As per Single Unix Specification V2 we must return an error if
|
||||
+ the name argument points to an empty string. */
|
||||
+ __set_errno (ENOENT);
|
||||
+ return NULL;
|
||||
+ }
|
||||
+#ifdef __WIN32__
|
||||
+ {
|
||||
+ char *lpFilePart;
|
||||
+ int len;
|
||||
+// fprintf(stderr, "name: %s\n", name);
|
||||
+ rpath = resolved ? __builtin_alloca (MAX_PATH) : malloc (MAX_PATH);
|
||||
+// unix2winpath (name);
|
||||
+// fprintf(stderr, "name: %s\n", name);
|
||||
+ len = GetFullPathName(name, MAX_PATH, rpath, &lpFilePart);
|
||||
+ /* GetFullPathName returns bogus paths for *nix-style paths, like
|
||||
+ * /foo/bar - it just prepends current drive to them. Keep them
|
||||
+ * intact (they need to be for relocation to work!).
|
||||
+ */
|
||||
+ if (name[0] == '/') {
|
||||
+ strncpy (rpath, name, MAX_PATH - 1);
|
||||
+ rpath[MAX_PATH - 1] = '\0';
|
||||
+ len = strlen (rpath);
|
||||
+ }
|
||||
+// fprintf(stderr, "rpath: %s\n", rpath);
|
||||
+ if (len == 0) {
|
||||
+ //set_werrno;
|
||||
+ return NULL;
|
||||
+ }
|
||||
+ if (len > MAX_PATH) {
|
||||
+ if (resolved)
|
||||
+ __set_errno(ENAMETOOLONG);
|
||||
+ else {
|
||||
+ rpath = realloc(rpath, len + 2);
|
||||
+ GetFullPathName(name, len, rpath, &lpFilePart);
|
||||
+// fprintf(stderr, "rpath: %s\n", rpath);
|
||||
+ }
|
||||
+ }
|
||||
+// if ( ISDIRSEP(name[strlen(name)]) && !ISDIRSEP(rpath[len]) ) {
|
||||
+// rpath[len] = '\\';
|
||||
+// rpath[len + 1] = 0;
|
||||
+// }
|
||||
+ old_errno = errno;
|
||||
+ //if (!access (rpath, D_OK) && !ISDIRSEP(rpath[len - 1]) ){
|
||||
+ if (!access (rpath, R_OK) && !ISDIRSEP(rpath[len - 1]) ){
|
||||
+ rpath[len] = '\\';
|
||||
+ rpath[len + 1] = 0;
|
||||
+ }
|
||||
+ errno = old_errno;
|
||||
+ win2unixpath (rpath);
|
||||
+// fprintf(stderr, "rpath: %s\n", rpath);
|
||||
+ return resolved ? strcpy(resolved, rpath) : rpath ;
|
||||
+ }
|
||||
+#else /* __WIN32__ */
|
||||
+
|
||||
+#ifdef PATH_MAX
|
||||
+ path_max = PATH_MAX;
|
||||
+#else
|
||||
+ path_max = pathconf (name, _PC_PATH_MAX);
|
||||
+ if (path_max <= 0)
|
||||
+ path_max = 1024;
|
||||
+#endif
|
||||
+
|
||||
+ rpath = resolved ? __builtin_alloca (path_max) : malloc (path_max);
|
||||
+ rpath_limit = rpath + path_max;
|
||||
+
|
||||
+ if (name[0] != '/')
|
||||
+ {
|
||||
+ if (!__getcwd (rpath, path_max))
|
||||
+ {
|
||||
+ rpath[0] = '\0';
|
||||
+ goto error;
|
||||
+ }
|
||||
+ dest = strchr (rpath, '\0');
|
||||
+ }
|
||||
+ else
|
||||
+ {
|
||||
+ rpath[0] = '/';
|
||||
+ dest = rpath + 1;
|
||||
+ }
|
||||
+
|
||||
+ for (start = end = name; *start; start = end)
|
||||
+ {
|
||||
+#ifdef _LIBC
|
||||
+ struct stat64 st;
|
||||
+#else
|
||||
+ struct stat st;
|
||||
+#endif
|
||||
+ int n;
|
||||
+
|
||||
+ /* Skip sequence of multiple path-separators. */
|
||||
+ while (*start == '/')
|
||||
+ ++start;
|
||||
+
|
||||
+ /* Find end of path component. */
|
||||
+ for (end = start; *end && *end != '/'; ++end)
|
||||
+ /* Nothing. */;
|
||||
+
|
||||
+ if (end - start == 0)
|
||||
+ break;
|
||||
+ else if (end - start == 1 && start[0] == '.')
|
||||
+ /* nothing */;
|
||||
+ else if (end - start == 2 && start[0] == '.' && start[1] == '.')
|
||||
+ {
|
||||
+ /* Back up to previous component, ignore if at root already. */
|
||||
+ if (dest > rpath + 1)
|
||||
+ while ((--dest)[-1] != '/');
|
||||
+ }
|
||||
+ else
|
||||
+ {
|
||||
+ size_t new_size;
|
||||
+
|
||||
+ if (dest[-1] != '/')
|
||||
+ *dest++ = '/';
|
||||
+
|
||||
+ if (dest + (end - start) >= rpath_limit)
|
||||
+ {
|
||||
+ ptrdiff_t dest_offset = dest - rpath;
|
||||
+
|
||||
+ if (resolved)
|
||||
+ {
|
||||
+ __set_errno (ENAMETOOLONG);
|
||||
+ if (dest > rpath + 1)
|
||||
+ dest--;
|
||||
+ *dest = '\0';
|
||||
+ goto error;
|
||||
+ }
|
||||
+ new_size = rpath_limit - rpath;
|
||||
+ if (end - start + 1 > path_max)
|
||||
+ new_size += end - start + 1;
|
||||
+ else
|
||||
+ new_size += path_max;
|
||||
+ rpath = realloc (rpath, new_size);
|
||||
+ rpath_limit = rpath + new_size;
|
||||
+ if (rpath == NULL)
|
||||
+ return NULL;
|
||||
+
|
||||
+ dest = rpath + dest_offset;
|
||||
+ }
|
||||
+
|
||||
+#ifdef _LIBC
|
||||
+ dest = __mempcpy (dest, start, end - start);
|
||||
+#else
|
||||
+ memcpy (dest, start, end - start);
|
||||
+ dest += end - start;
|
||||
+#endif
|
||||
+ *dest = '\0';
|
||||
+
|
||||
+#ifdef _LIBC
|
||||
+ if (__lxstat64 (_STAT_VER, rpath, &st) < 0)
|
||||
+#else
|
||||
+ if (lstat (rpath, &st) < 0)
|
||||
+#endif
|
||||
+ goto error;
|
||||
+
|
||||
+#if HAVE_READLINK
|
||||
+ if (S_ISLNK (st.st_mode))
|
||||
+ {
|
||||
+ char *buf = __builtin_alloca (path_max);
|
||||
+ size_t len;
|
||||
+
|
||||
+ if (++num_links > MAXSYMLINKS)
|
||||
+ {
|
||||
+ __set_errno (ELOOP);
|
||||
+ goto error;
|
||||
+ }
|
||||
+
|
||||
+ n = __readlink (rpath, buf, path_max);
|
||||
+ if (n < 0)
|
||||
+ goto error;
|
||||
+ buf[n] = '\0';
|
||||
+
|
||||
+ if (!extra_buf)
|
||||
+ extra_buf = __builtin_alloca (path_max);
|
||||
+
|
||||
+ len = strlen (end);
|
||||
+ if ((long int) (n + len) >= path_max)
|
||||
+ {
|
||||
+ __set_errno (ENAMETOOLONG);
|
||||
+ goto error;
|
||||
+ }
|
||||
+
|
||||
+ /* Careful here, end may be a pointer into extra_buf... */
|
||||
+ memmove (&extra_buf[n], end, len + 1);
|
||||
+ name = end = memcpy (extra_buf, buf, n);
|
||||
+
|
||||
+ if (buf[0] == '/')
|
||||
+ dest = rpath + 1; /* It's an absolute symlink */
|
||||
+ else
|
||||
+ /* Back up to previous component, ignore if at root already: */
|
||||
+ if (dest > rpath + 1)
|
||||
+ while ((--dest)[-1] != '/');
|
||||
+ }
|
||||
+#endif
|
||||
+ }
|
||||
+ }
|
||||
+ if (dest > rpath + 1 && dest[-1] == '/')
|
||||
+ --dest;
|
||||
+ *dest = '\0';
|
||||
+
|
||||
+ return resolved ? memcpy (resolved, rpath, dest - rpath + 1) : rpath;
|
||||
+
|
||||
+error:
|
||||
+ if (resolved)
|
||||
+ strcpy (resolved, rpath);
|
||||
+ else
|
||||
+ free (rpath);
|
||||
+ return NULL;
|
||||
+
|
||||
+#endif /* __WIN32__ */
|
||||
+}
|
||||
+
|
||||
+
|
||||
+char *
|
||||
+__realpath (const char *name, char *resolved)
|
||||
+{
|
||||
+ if (resolved == NULL)
|
||||
+ {
|
||||
+ __set_errno (EINVAL);
|
||||
+ return NULL;
|
||||
+ }
|
||||
+
|
||||
+ return canonicalize (name, resolved);
|
||||
+}
|
||||
+weak_alias (__realpath, realpath)
|
||||
+
|
||||
+
|
||||
+char *
|
||||
+__canonicalize_file_name (const char *name)
|
||||
+{
|
||||
+ return canonicalize (name, NULL);
|
||||
+}
|
||||
+weak_alias (__canonicalize_file_name, canonicalize_file_name)
|
||||
+
|
||||
+char *
|
||||
+canonicalize_file_name (const char *name)
|
||||
+{
|
||||
+ return canonicalize (name, NULL);
|
||||
+}
|
||||
diff --git a/gettext-runtime/intl/canonicalize.h b/gettext-runtime/intl/canonicalize.h
|
||||
new file mode 100644
|
||||
index 0000000..ea707bf
|
||||
--- /dev/null
|
||||
+++ b/gettext-runtime/intl/canonicalize.h
|
||||
@@ -0,0 +1,18 @@
|
||||
+#ifndef __CANONICALIZE_H__
|
||||
+#define __CANONICALIZE_H__ 1
|
||||
+
|
||||
+#ifdef __cplusplus
|
||||
+extern "C" {
|
||||
+#endif
|
||||
+
|
||||
+char *canonicalize_file_name (const char *name);
|
||||
+
|
||||
+#ifdef __WIN32__
|
||||
+char *win2unixpath (char *path);
|
||||
+#endif
|
||||
+
|
||||
+#ifdef __cplusplus
|
||||
+}
|
||||
+#endif
|
||||
+
|
||||
+#endif /* __CANONICALIZE_H__ */
|
||||
diff --git a/gettext-runtime/intl/relocatex.c b/gettext-runtime/intl/relocatex.c
|
||||
new file mode 100644
|
||||
index 0000000..a2b7438
|
||||
--- /dev/null
|
||||
+++ b/gettext-runtime/intl/relocatex.c
|
||||
@@ -0,0 +1,284 @@
|
||||
+/* Provide relocatable packages.
|
||||
+ Copyright (C) 2003 Free Software Foundation, Inc.
|
||||
+ Written by Bruno Haible <bruno@clisp.org>, 2003.
|
||||
+
|
||||
+ This program is free software; you can redistribute it and/or modify it
|
||||
+ under the terms of the GNU Library General Public License as published
|
||||
+ by the Free Software Foundation; either version 2, or (at your option)
|
||||
+ any later version.
|
||||
+
|
||||
+ This program is distributed in the hope that it will be useful,
|
||||
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
+ Library General Public License for more details.
|
||||
+
|
||||
+ You should have received a copy of the GNU Library General Public
|
||||
+ License along with this program; if not, write to the Free Software
|
||||
+ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
|
||||
+ USA. */
|
||||
+
|
||||
+
|
||||
+/* Specification. */
|
||||
+#include <errno.h>
|
||||
+#define _GNU_SOURCE
|
||||
+#include <stdlib.h>
|
||||
+#include <string.h>
|
||||
+#include <stdio.h>
|
||||
+#include <unistd.h>
|
||||
+/* #include <path.h> */
|
||||
+#include "relocatex.h"
|
||||
+#include "canonicalize.h"
|
||||
+/* #include <gw32.h> */
|
||||
+
|
||||
+
|
||||
+#if defined _WIN32 || defined __WIN32__
|
||||
+# define WIN32_LEAN_AND_MEAN
|
||||
+# include <windows.h>
|
||||
+//# define __GW32__
|
||||
+//# include <winx/errnox.h>
|
||||
+#endif
|
||||
+#define set_werrno
|
||||
+
|
||||
+#if defined _WIN32 || defined __WIN32__ || defined __CYGWIN__ || defined __EMX__ || defined __DJGPP__
|
||||
+ /* Win32, Cygwin, OS/2, DOS */
|
||||
+# define ISDIRSEP(C) ((C) == '/' || (C) == '\\')
|
||||
+#else
|
||||
+ /* Unix */
|
||||
+# define ISDIRSEP(C) ((C) == '/')
|
||||
+#endif
|
||||
+
|
||||
+/* Original installation prefix. */
|
||||
+static char *orig_prefix = NULL;
|
||||
+static size_t orig_prefix_len = 0;
|
||||
+/* Current installation prefix. */
|
||||
+static char *curr_prefix = NULL;
|
||||
+static size_t curr_prefix_len = 0;
|
||||
+/* These prefixes do not end in a slash. Anything that will be concatenated
|
||||
+ to them must start with a slash. */
|
||||
+
|
||||
+
|
||||
+int win2posixpath (const char *winpath, char *posixpath)
|
||||
+{
|
||||
+ strcpy (posixpath, winpath);
|
||||
+ win2unixpath (posixpath);
|
||||
+ return 0;
|
||||
+}
|
||||
+
|
||||
+
|
||||
+/* Sets the original and the current installation prefix of this module.
|
||||
+ Relocation simply replaces a pathname starting with the original prefix
|
||||
+ by the corresponding pathname with the current prefix instead. Both
|
||||
+ prefixes should be directory names without trailing slash (i.e. use ""
|
||||
+ instead of "/"). */
|
||||
+static char *
|
||||
+set_orig_prefix (const char *orig_prefix_arg)
|
||||
+{
|
||||
+ char *memory;
|
||||
+// printf ("orig_prefix_arg: %s\n", orig_prefix_arg);
|
||||
+ if (!orig_prefix_arg) {
|
||||
+ orig_prefix = NULL;
|
||||
+ orig_prefix_len = 0;
|
||||
+ return NULL;
|
||||
+ }
|
||||
+ if (orig_prefix)
|
||||
+ free (orig_prefix);
|
||||
+
|
||||
+ memory = canonicalize_file_name (orig_prefix_arg);
|
||||
+// printf ("memory: %s\n", memory);
|
||||
+// memory = (char *) malloc (orig_prefix_len + 1);
|
||||
+ if (!memory) {
|
||||
+ set_werrno;
|
||||
+ orig_prefix = NULL;
|
||||
+ orig_prefix_len = 0;
|
||||
+ return NULL;
|
||||
+ }
|
||||
+ win2unixpath (memory);
|
||||
+// win2posixpath (orig_prefix_arg, memory);
|
||||
+ orig_prefix = memory;
|
||||
+ orig_prefix_len = strlen (orig_prefix);
|
||||
+// printf ("orig_prefix: %s\n", orig_prefix);
|
||||
+ if (ISDIRSEP (orig_prefix[orig_prefix_len-1])) {
|
||||
+ orig_prefix[orig_prefix_len-1] = '\0';
|
||||
+ orig_prefix_len--;
|
||||
+ }
|
||||
+// printf ("orig_prefix: %s\n", orig_prefix);
|
||||
+// printf ("orig_prefix_len: %d\n", orig_prefix_len);
|
||||
+ return orig_prefix;
|
||||
+}
|
||||
+
|
||||
+#if defined __WIN32__
|
||||
+static char *
|
||||
+set_current_prefix (const char *ModuleName)
|
||||
+{
|
||||
+ LPTSTR curr_prefix_arg, q, lpFilePart;
|
||||
+ DWORD len;
|
||||
+ int nDIRSEP = 0;
|
||||
+
|
||||
+ if (curr_prefix)
|
||||
+ free (curr_prefix);
|
||||
+ curr_prefix_arg = malloc (MAX_PATH * sizeof (TCHAR));
|
||||
+ if (!curr_prefix_arg) {
|
||||
+ set_werrno;
|
||||
+ curr_prefix = NULL;
|
||||
+ curr_prefix_len = 0;
|
||||
+ return NULL;
|
||||
+ }
|
||||
+ if (ModuleName) {
|
||||
+// printf ("ModuleName: %s\n", ModuleName);
|
||||
+ len = SearchPath (NULL, ModuleName, ".DLL", MAX_PATH, curr_prefix_arg, &lpFilePart);
|
||||
+ if (len) {
|
||||
+// printf ("ModulePath: %s\n", curr_prefix_arg);
|
||||
+// printf ("FilePart: %s\n", lpFilePart);
|
||||
+ }
|
||||
+ }
|
||||
+ if (!ModuleName || !len) {
|
||||
+ len = GetModuleFileName (NULL, curr_prefix_arg, MAX_PATH);
|
||||
+ if (!len) {
|
||||
+ set_werrno;
|
||||
+ curr_prefix = NULL;
|
||||
+ curr_prefix_len = 0;
|
||||
+ return NULL;
|
||||
+ }
|
||||
+ }
|
||||
+// strncpy (curr_prefix_arg, ModuleName, MAX_PATH);
|
||||
+// printf ("curr_prefix_arg: %s\n", curr_prefix_arg);
|
||||
+ win2posixpath (curr_prefix_arg, curr_prefix_arg);
|
||||
+ curr_prefix = curr_prefix_arg;
|
||||
+ q = curr_prefix_arg + len - 1;
|
||||
+ /* strip name of executable and its directory */
|
||||
+ while (!ISDIRSEP (*q) && (q > curr_prefix_arg) && nDIRSEP < 2) {
|
||||
+ q--;
|
||||
+ if (ISDIRSEP (*q)) {
|
||||
+ *q = '\0';
|
||||
+ nDIRSEP++;
|
||||
+ }
|
||||
+ }
|
||||
+ curr_prefix_len = q - curr_prefix_arg;
|
||||
+// printf ("curr_prefix: %s\n", curr_prefix);
|
||||
+// printf ("curr_prefix_len: %d\n", curr_prefix_len);
|
||||
+ return curr_prefix;
|
||||
+}
|
||||
+
|
||||
+char *getshortpath (const char *longpath)
|
||||
+{
|
||||
+ char *shortpath = NULL;
|
||||
+ DWORD len, res;
|
||||
+
|
||||
+// printf ("longpath: %s\n", longpath);
|
||||
+ len = GetShortPathName(longpath, shortpath, 0);
|
||||
+// printf ("len: %ld\n", len);
|
||||
+ if (!len) {
|
||||
+// WinErr ("getshortpath: len = 0");
|
||||
+ set_werrno;
|
||||
+ return (char *) longpath;
|
||||
+ }
|
||||
+ shortpath = (char *) malloc (len + 1);
|
||||
+ if (!shortpath) {
|
||||
+// WinErr ("getshortpath: malloc");
|
||||
+ set_werrno;
|
||||
+ return (char *) longpath;
|
||||
+ }
|
||||
+ res = GetShortPathName(longpath, shortpath, len);
|
||||
+// printf ("res: %ld\n", res);
|
||||
+ if (!res) {
|
||||
+// WinErr ("getshortpath: res = 0");
|
||||
+ free (shortpath);
|
||||
+ set_werrno;
|
||||
+ return (char *) longpath;
|
||||
+ }
|
||||
+// printf ("shortpath: %s\n", shortpath);
|
||||
+ return shortpath;
|
||||
+}
|
||||
+
|
||||
+char *relocaten (const char *ModuleName, const char *path)
|
||||
+{
|
||||
+ char *relative_path, *relocated_path, *relocated_short_path;
|
||||
+ int relative_path_len;
|
||||
+
|
||||
+ if (!curr_prefix)
|
||||
+ set_current_prefix (ModuleName);
|
||||
+// printf ("path: %s\n", path);
|
||||
+// printf ("orig_prefix: %s\n", orig_prefix);
|
||||
+// printf ("curr_prefix: %s\n", curr_prefix);
|
||||
+// if (strncmp (orig_prefix, path, orig_prefix_len))
|
||||
+// if (strcmp (orig_prefix, path))
|
||||
+// return (char *) path;
|
||||
+ relative_path = (char *) path + orig_prefix_len;
|
||||
+// printf ("relative_path: %s\n", relative_path);
|
||||
+ relative_path_len = strlen (relative_path);
|
||||
+ relocated_path = malloc (curr_prefix_len + relative_path_len + 1);
|
||||
+ strcpy (relocated_path, curr_prefix);
|
||||
+ strcat (relocated_path, relative_path);
|
||||
+// printf ("relocated_path: %s\n", relocated_path);
|
||||
+ relocated_short_path = getshortpath (relocated_path);
|
||||
+// printf ("relocated_short_path: %s\n", relocated_short_path);
|
||||
+ if (relocated_short_path) {
|
||||
+ if (relocated_short_path != relocated_path)
|
||||
+ free (relocated_path);
|
||||
+ return relocated_short_path;
|
||||
+ } else
|
||||
+ return relocated_path;
|
||||
+}
|
||||
+
|
||||
+#else // __WIN32__
|
||||
+char *relocaten (const char *ModuleName, const char *path)
|
||||
+{
|
||||
+ // dummy function for Unix/Linux
|
||||
+ return (char *)path;
|
||||
+}
|
||||
+#endif
|
||||
+
|
||||
+char *relocaten2 (const char *ModuleName, const char *installdir, const char *path)
|
||||
+{
|
||||
+ set_orig_prefix (installdir);
|
||||
+ return relocaten (ModuleName, path);
|
||||
+}
|
||||
+
|
||||
+char *relocatenx (const char *ModuleName, const char *installdir, const char *path)
|
||||
+{
|
||||
+ char *p;
|
||||
+
|
||||
+ set_orig_prefix (installdir);
|
||||
+ if (access (path, R_OK))
|
||||
+ p = relocaten (ModuleName, path);
|
||||
+ else
|
||||
+ p = (char *) path;
|
||||
+// printf ("relocatenx: %s\n", p);
|
||||
+ return p;
|
||||
+}
|
||||
+
|
||||
+char *relocate2 (const char *installdir, const char *path)
|
||||
+{
|
||||
+ return relocaten2 (NULL, installdir, path);
|
||||
+}
|
||||
+
|
||||
+char *relocatex (const char *installdir, const char *path)
|
||||
+{
|
||||
+ return relocatenx (NULL, installdir, path);
|
||||
+}
|
||||
+
|
||||
+char *relocatepx (const char *cprefix, const char *installdir, const char *path)
|
||||
+{
|
||||
+ if (curr_prefix)
|
||||
+ free (curr_prefix);
|
||||
+ curr_prefix = strdup (cprefix);
|
||||
+ return relocatex (installdir, path);
|
||||
+}
|
||||
+
|
||||
+static char *get_orig_prefix (void)
|
||||
+{
|
||||
+ return orig_prefix;
|
||||
+}
|
||||
+
|
||||
+static char *get_curr_prefix (void)
|
||||
+{
|
||||
+ return curr_prefix;
|
||||
+}
|
||||
+
|
||||
+static char *set_curr_prefix (const char *ModuleName)
|
||||
+{
|
||||
+ if (curr_prefix)
|
||||
+ free (curr_prefix);
|
||||
+ set_current_prefix (ModuleName);
|
||||
+ return curr_prefix;
|
||||
+}
|
||||
diff --git a/gettext-runtime/intl/relocatex.h b/gettext-runtime/intl/relocatex.h
|
||||
new file mode 100644
|
||||
index 0000000..5cc7c51
|
||||
--- /dev/null
|
||||
+++ b/gettext-runtime/intl/relocatex.h
|
||||
@@ -0,0 +1,41 @@
|
||||
+/*
|
||||
+ Copyright (C) 2006 Free Software Foundation, Inc.
|
||||
+ This file is part of the GnuWin C Library.
|
||||
+
|
||||
+ The GnuWin C Library is free software; you can redistribute it and/or
|
||||
+ modify it under the terms of the GNU Lesser General Public
|
||||
+ License as published by the Free Software Foundation; either
|
||||
+ version 2.1 of the License, or (at your option) any later version.
|
||||
+
|
||||
+ The GnuWin C Library is distributed in the hope that it will be useful,
|
||||
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
+ Lesser General Public License for more details.
|
||||
+
|
||||
+ You should have received a copy of the GNU Lesser General Public
|
||||
+ License along with the GnuWin32 C Library; if not, write to the Free
|
||||
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
|
||||
+ 02111-1307 USA. */
|
||||
+
|
||||
+#ifndef __RELOCATE_H__
|
||||
+#define __RELOCATE_H__ 1
|
||||
+
|
||||
+/* #include <libc-dll.h> */
|
||||
+
|
||||
+#ifdef __cplusplus
|
||||
+extern "C" {
|
||||
+#endif
|
||||
+
|
||||
+char *relocaten (const char *ModuleName, const char *path);
|
||||
+char *relocaten2 (const char *ModuleName, const char *installdir, const char *path);
|
||||
+char *relocatenx (const char *ModuleName, const char *installdir, const char *path);
|
||||
+char *relocate2 (const char *installdir, const char *path);
|
||||
+char *relocatex (const char *installdir, const char *path);
|
||||
+
|
||||
+#ifdef __cplusplus
|
||||
+}
|
||||
+#endif
|
||||
+
|
||||
+//#endif /* __GW32__ */
|
||||
+
|
||||
+#endif /* __RELOCATE_H__ */
|
||||
--
|
||||
2.7.0.windows.2.1.gab3a2bd
|
||||
|
||||
@@ -0,0 +1,70 @@
|
||||
From: Michele Locati <michele@locati.it>
|
||||
Date: Fri, 10 May 2019 10:25:28 +0200
|
||||
Subject: [PATCH] libtool: hide "using cross tools not prefixed with host
|
||||
triplet"
|
||||
|
||||
--- a/configure
|
||||
+++ b/configure
|
||||
@@ -32,6 +32,7 @@ else
|
||||
esac
|
||||
fi
|
||||
|
||||
+ac_tool_warned=yes
|
||||
|
||||
as_nl='
|
||||
'
|
||||
|
||||
--- a/gettext-runtime/configure
|
||||
+++ b/gettext-runtime/configure
|
||||
@@ -32,6 +32,7 @@ else
|
||||
esac
|
||||
fi
|
||||
|
||||
+ac_tool_warned=yes
|
||||
|
||||
as_nl='
|
||||
'
|
||||
|
||||
--- a/gettext-runtime/libasprintf/configure
|
||||
+++ b/gettext-runtime/libasprintf/configure
|
||||
@@ -30,6 +30,7 @@ else
|
||||
esac
|
||||
fi
|
||||
|
||||
+ac_tool_warned=yes
|
||||
|
||||
as_nl='
|
||||
'
|
||||
|
||||
--- a/gettext-tools/configure
|
||||
+++ b/gettext-tools/configure
|
||||
@@ -32,6 +32,7 @@ else
|
||||
esac
|
||||
fi
|
||||
|
||||
+ac_tool_warned=yes
|
||||
|
||||
as_nl='
|
||||
'
|
||||
|
||||
--- a/gettext-tools/examples/configure
|
||||
+++ b/gettext-tools/examples/configure
|
||||
@@ -32,6 +32,7 @@ else
|
||||
esac
|
||||
fi
|
||||
|
||||
+ac_tool_warned=yes
|
||||
|
||||
as_nl='
|
||||
'
|
||||
|
||||
--- a/libtextstyle/configure
|
||||
+++ b/libtextstyle/configure
|
||||
@@ -30,6 +30,7 @@ else
|
||||
esac
|
||||
fi
|
||||
|
||||
+ac_tool_warned=yes
|
||||
|
||||
as_nl='
|
||||
'
|
||||
39
mingw-w64-gettext/0002-libtool-hide-library-was-moved.patch
Normal file
39
mingw-w64-gettext/0002-libtool-hide-library-was-moved.patch
Normal file
@@ -0,0 +1,39 @@
|
||||
From: Michele Locati <michele@locati.it>
|
||||
Date: Fri, 10 May 2019 10:35:49 +0200
|
||||
Subject: [PATCH] libtool: hide "library was moved"
|
||||
|
||||
--- a/build-aux/ltmain.sh
|
||||
+++ b/build-aux/ltmain.sh
|
||||
@@ -7956,7 +7956,7 @@ func_mode_link ()
|
||||
# Find the relevant object directory and library name.
|
||||
if test yes = "$installed"; then
|
||||
if test ! -f "$lt_sysroot$libdir/$linklib" && test -f "$abs_ladir/$linklib"; then
|
||||
- func_warning "library '$lib' was moved."
|
||||
+ #func_warning "library '$lib' was moved."
|
||||
dir=$ladir
|
||||
absdir=$abs_ladir
|
||||
libdir=$abs_ladir
|
||||
|
||||
--- a/gettext-tools/examples/hello-c++-kde/admin/ltmain.sh
|
||||
+++ b/gettext-tools/examples/hello-c++-kde/admin/ltmain.sh
|
||||
@@ -1958,7 +1958,7 @@ EOF
|
||||
# Find the relevant object directory and library name.
|
||||
if test "X$installed" = Xyes; then
|
||||
if test ! -f "$libdir/$linklib" && test -f "$abs_ladir/$linklib"; then
|
||||
- $echo "$modename: warning: library \`$lib' was moved." 1>&2
|
||||
+ #$echo "$modename: warning: library \`$lib' was moved." 1>&2
|
||||
dir="$ladir"
|
||||
absdir="$abs_ladir"
|
||||
libdir="$abs_ladir"
|
||||
|
||||
--- a/libtextstyle/build-aux/ltmain.sh
|
||||
+++ b/libtextstyle/build-aux/ltmain.sh
|
||||
@@ -7956,7 +7956,7 @@ func_mode_link ()
|
||||
# Find the relevant object directory and library name.
|
||||
if test yes = "$installed"; then
|
||||
if test ! -f "$lt_sysroot$libdir/$linklib" && test -f "$abs_ladir/$linklib"; then
|
||||
- func_warning "library '$lib' was moved."
|
||||
+ #func_warning "library '$lib' was moved."
|
||||
dir=$ladir
|
||||
absdir=$abs_ladir
|
||||
libdir=$abs_ladir
|
||||
@@ -0,0 +1,35 @@
|
||||
From: Michele Locati <michele@locati.it>
|
||||
Date: Fri, 10 May 2019 10:35:49 +0200
|
||||
Subject: [PATCH] libtool: hide "Could not determine host file name"
|
||||
|
||||
--- a/build-aux/ltmain.sh
|
||||
+++ b/build-aux/ltmain.sh
|
||||
@@ -2891,9 +2891,9 @@ func_convert_path_check ()
|
||||
$debug_cmd
|
||||
|
||||
if test -z "$4" && test -n "$3"; then
|
||||
- func_error "Could not determine the host path corresponding to"
|
||||
- func_error " '$3'"
|
||||
- func_error "Continuing, but uninstalled executables may not work."
|
||||
+ #func_error "Could not determine the host path corresponding to"
|
||||
+ #func_error " '$3'"
|
||||
+ #func_error "Continuing, but uninstalled executables may not work."
|
||||
# Fallback. This is a deliberately simplistic "conversion" and
|
||||
# should not be "improved". See libtool.info.
|
||||
if test "x$1" != "x$2"; then
|
||||
|
||||
--- a/libtextstyle/build-aux/ltmain.sh
|
||||
+++ b/libtextstyle/build-aux/ltmain.sh
|
||||
@@ -2891,9 +2891,9 @@ func_convert_path_check ()
|
||||
$debug_cmd
|
||||
|
||||
if test -z "$4" && test -n "$3"; then
|
||||
- func_error "Could not determine the host path corresponding to"
|
||||
- func_error " '$3'"
|
||||
- func_error "Continuing, but uninstalled executables may not work."
|
||||
+ #func_error "Could not determine the host path corresponding to"
|
||||
+ #func_error " '$3'"
|
||||
+ #func_error "Continuing, but uninstalled executables may not work."
|
||||
# Fallback. This is a deliberately simplistic "conversion" and
|
||||
# should not be "improved". See libtool.info.
|
||||
if test "x$1" != "x$2"; then
|
||||
27
mingw-w64-gettext/0004-libtool-hide-seems-to-be-moved.patch
Normal file
27
mingw-w64-gettext/0004-libtool-hide-seems-to-be-moved.patch
Normal file
@@ -0,0 +1,27 @@
|
||||
From: Michele Locati <michele@locati.it>
|
||||
Date: Fri, 10 May 2019 11:04:38 +0200
|
||||
Subject: [PATCH] libtool: hide "seems to be moved"
|
||||
|
||||
--- a/build-aux/ltmain.sh
|
||||
+++ b/build-aux/ltmain.sh
|
||||
@@ -8523,7 +8523,7 @@ func_mode_link ()
|
||||
eval libdir=`$SED -n -e 's/^libdir=\(.*\)$/\1/p' $deplib`
|
||||
test -z "$libdir" && \
|
||||
func_fatal_error "'$deplib' is not a valid libtool archive"
|
||||
- test "$absdir" != "$libdir" && \
|
||||
+ false && test "$absdir" != "$libdir" && \
|
||||
func_warning "'$deplib' seems to be moved"
|
||||
|
||||
path=-L$absdir
|
||||
|
||||
--- a/libtextstyle/build-aux/ltmain.sh
|
||||
+++ b/libtextstyle/build-aux/ltmain.sh
|
||||
@@ -8523,7 +8523,7 @@ func_mode_link ()
|
||||
eval libdir=`$SED -n -e 's/^libdir=\(.*\)$/\1/p' $deplib`
|
||||
test -z "$libdir" && \
|
||||
func_fatal_error "'$deplib' is not a valid libtool archive"
|
||||
- test "$absdir" != "$libdir" && \
|
||||
+ false && test "$absdir" != "$libdir" && \
|
||||
func_warning "'$deplib' seems to be moved"
|
||||
|
||||
path=-L$absdir
|
||||
@@ -0,0 +1,17 @@
|
||||
From: Michele Locati <michele@locati.it>
|
||||
Date: Fri, 10 May 2019 11:11:02 +0200
|
||||
Subject: [PATCH] Fix compilation of pthread_sigmask.c
|
||||
|
||||
--- a/gettext-tools/gnulib-tests/pthread_sigmask.c
|
||||
+++ b/gettext-tools/gnulib-tests/pthread_sigmask.c
|
||||
@@ -30,9 +30,9 @@
|
||||
# include <unistd.h>
|
||||
#endif
|
||||
|
||||
+#undef pthread_sigmask
|
||||
int
|
||||
pthread_sigmask (int how, const sigset_t *new_mask, sigset_t *old_mask)
|
||||
-#undef pthread_sigmask
|
||||
{
|
||||
#if HAVE_PTHREAD_SIGMASK
|
||||
int ret;
|
||||
27
mingw-w64-gettext/0006-libtool-hide-remember-to-run.patch
Normal file
27
mingw-w64-gettext/0006-libtool-hide-remember-to-run.patch
Normal file
@@ -0,0 +1,27 @@
|
||||
From: Michele Locati <michele@locati.it>
|
||||
Date: Fri, 10 May 2019 11:16:55 +0200
|
||||
Subject: [PATCH] libtool: hide "remember to run"
|
||||
|
||||
--- a/build-aux/ltmain.sh
|
||||
+++ b/build-aux/ltmain.sh
|
||||
@@ -4543,7 +4543,7 @@ func_mode_install ()
|
||||
func_execute_cmds "$old_postinstall_cmds" 'exit $?'
|
||||
done
|
||||
|
||||
- test -n "$future_libdirs" && \
|
||||
+ false && test -n "$future_libdirs" && \
|
||||
func_warning "remember to run '$progname --finish$future_libdirs'"
|
||||
|
||||
if test -n "$current_libdirs"; then
|
||||
|
||||
--- a/libtextstyle/build-aux/ltmain.sh
|
||||
+++ b/libtextstyle/build-aux/ltmain.sh
|
||||
@@ -4543,7 +4543,7 @@ func_mode_install ()
|
||||
func_execute_cmds "$old_postinstall_cmds" 'exit $?'
|
||||
done
|
||||
|
||||
- test -n "$future_libdirs" && \
|
||||
+ false && test -n "$future_libdirs" && \
|
||||
func_warning "remember to run '$progname --finish$future_libdirs'"
|
||||
|
||||
if test -n "$current_libdirs"; then
|
||||
@@ -0,0 +1,39 @@
|
||||
From: Michele Locati <michele@locati.it>
|
||||
Date: Fri, 10 May 2019 11:24:34 +0200
|
||||
Subject: [PATCH] libtool: hide "has not been installed in"
|
||||
|
||||
--- a/build-aux/ltmain.sh
|
||||
+++ b/build-aux/ltmain.sh
|
||||
@@ -4458,7 +4458,7 @@ func_mode_install ()
|
||||
fi
|
||||
libfile=$libdir/`$ECHO "$lib" | $SED 's%^.*/%%g'`
|
||||
if test -n "$libdir" && test ! -f "$libfile"; then
|
||||
- func_warning "'$lib' has not been installed in '$libdir'"
|
||||
+ #func_warning "'$lib' has not been installed in '$libdir'"
|
||||
finalize=false
|
||||
fi
|
||||
done
|
||||
|
||||
--- a/gettext-tools/examples/hello-c++-kde/admin/ltmain.sh
|
||||
+++ b/gettext-tools/examples/hello-c++-kde/admin/ltmain.sh
|
||||
@@ -4853,7 +4853,7 @@ relink_command=\"$relink_command\""
|
||||
fi
|
||||
libfile="$libdir/"`$echo "X$lib" | $Xsed -e 's%^.*/%%g'` ### testsuite: skip nested quoting test
|
||||
if test -n "$libdir" && test ! -f "$libfile"; then
|
||||
- $echo "$modename: warning: \`$lib' has not been installed in \`$libdir'" 1>&2
|
||||
+ #$echo "$modename: warning: \`$lib' has not been installed in \`$libdir'" 1>&2
|
||||
finalize=no
|
||||
fi
|
||||
done
|
||||
|
||||
--- a/libtextstyle/build-aux/ltmain.sh
|
||||
+++ b/libtextstyle/build-aux/ltmain.sh
|
||||
@@ -4458,7 +4458,7 @@ func_mode_install ()
|
||||
fi
|
||||
libfile=$libdir/`$ECHO "$lib" | $SED 's%^.*/%%g'`
|
||||
if test -n "$libdir" && test ! -f "$libfile"; then
|
||||
- func_warning "'$lib' has not been installed in '$libdir'"
|
||||
+ #func_warning "'$lib' has not been installed in '$libdir'"
|
||||
finalize=false
|
||||
fi
|
||||
done
|
||||
@@ -0,0 +1,72 @@
|
||||
From: =?UTF-8?q?Va=CC=81clav=20Slavi=CC=81k?= <vaclav@slavik.io>
|
||||
Date: Tue, 19 Jan 2016 16:48:53 +0100
|
||||
Subject: [PATCH] Force redirected output's encoding
|
||||
|
||||
This patch adds support for GETTEXTIOENCODING environment variable that can be
|
||||
set to override console codepage autodetection. This is particularly useful
|
||||
when redirecting the output to a pipe (console CP detection fails) and using
|
||||
localized messages. Inspired by Python's PYTHONIOENCODING.
|
||||
|
||||
--- a/gettext-runtime/gnulib-lib/localcharset.c
|
||||
+++ b/gettext-runtime/gnulib-lib/localcharset.c
|
||||
@@ -832,6 +832,12 @@ locale_charset (void)
|
||||
{
|
||||
const char *codeset;
|
||||
|
||||
+ /* Force output encoding, particularly useful for redirected output on win32
|
||||
+ where charset detection fails when no actual console is attached. */
|
||||
+ const char *forced_encoding = getenv("GETTEXTIOENCODING");
|
||||
+ if (forced_encoding)
|
||||
+ return forced_encoding;
|
||||
+
|
||||
/* This function must be multithread-safe. To achieve this without using
|
||||
thread-local storage, we use a simple strcpy or memcpy to fill this static
|
||||
buffer. Filling it through, for example, strcpy + strcat would not be
|
||||
|
||||
--- a/gettext-runtime/intl/localcharset.c
|
||||
+++ b/gettext-runtime/intl/localcharset.c
|
||||
@@ -832,6 +832,12 @@ locale_charset (void)
|
||||
{
|
||||
const char *codeset;
|
||||
|
||||
+ /* Force output encoding, particularly useful for redirected output on win32
|
||||
+ where charset detection fails when no actual console is attached. */
|
||||
+ const char *forced_encoding = getenv("GETTEXTIOENCODING");
|
||||
+ if (forced_encoding)
|
||||
+ return forced_encoding;
|
||||
+
|
||||
/* This function must be multithread-safe. To achieve this without using
|
||||
thread-local storage, we use a simple strcpy or memcpy to fill this static
|
||||
buffer. Filling it through, for example, strcpy + strcat would not be
|
||||
|
||||
--- a/gettext-tools/gnulib-lib/localcharset.c
|
||||
+++ b/gettext-tools/gnulib-lib/localcharset.c
|
||||
@@ -832,6 +832,12 @@ locale_charset (void)
|
||||
{
|
||||
const char *codeset;
|
||||
|
||||
+ /* Force output encoding, particularly useful for redirected output on win32
|
||||
+ where charset detection fails when no actual console is attached. */
|
||||
+ const char *forced_encoding = getenv("GETTEXTIOENCODING");
|
||||
+ if (forced_encoding)
|
||||
+ return forced_encoding;
|
||||
+
|
||||
/* This function must be multithread-safe. To achieve this without using
|
||||
thread-local storage, we use a simple strcpy or memcpy to fill this static
|
||||
buffer. Filling it through, for example, strcpy + strcat would not be
|
||||
|
||||
--- a/gettext-tools/libgettextpo/localcharset.c
|
||||
+++ b/gettext-tools/libgettextpo/localcharset.c
|
||||
@@ -832,6 +832,12 @@ locale_charset (void)
|
||||
{
|
||||
const char *codeset;
|
||||
|
||||
+ /* Force output encoding, particularly useful for redirected output on win32
|
||||
+ where charset detection fails when no actual console is attached. */
|
||||
+ const char *forced_encoding = getenv("GETTEXTIOENCODING");
|
||||
+ if (forced_encoding)
|
||||
+ return forced_encoding;
|
||||
+
|
||||
/* This function must be multithread-safe. To achieve this without using
|
||||
thread-local storage, we use a simple strcpy or memcpy to fill this static
|
||||
buffer. Filling it through, for example, strcpy + strcat would not be
|
||||
@@ -0,0 +1,27 @@
|
||||
From: Michele Locati <michele@locati.it>
|
||||
Date: Wed, 15 May 2019 09:34:55 +0200
|
||||
Subject: [PATCH] Typo: func__fatal_error should be func_fatal_error
|
||||
|
||||
--- a/build-aux/ltmain.sh
|
||||
+++ b/build-aux/ltmain.sh
|
||||
@@ -2124,7 +2124,7 @@ fi
|
||||
# a configuration failure hint, and exit.
|
||||
func_fatal_configuration ()
|
||||
{
|
||||
- func__fatal_error ${1+"$@"} \
|
||||
+ func_fatal_error ${1+"$@"} \
|
||||
"See the $PACKAGE documentation for more information." \
|
||||
"Fatal configuration error."
|
||||
}
|
||||
|
||||
--- a/libtextstyle/build-aux/ltmain.sh
|
||||
+++ b/libtextstyle/build-aux/ltmain.sh
|
||||
@@ -2124,7 +2124,7 @@ fi
|
||||
# a configuration failure hint, and exit.
|
||||
func_fatal_configuration ()
|
||||
{
|
||||
- func__fatal_error ${1+"$@"} \
|
||||
+ func_fatal_error ${1+"$@"} \
|
||||
"See the $PACKAGE documentation for more information." \
|
||||
"Fatal configuration error."
|
||||
}
|
||||
@@ -0,0 +1,17 @@
|
||||
From: Michele Locati <michele@locati.it>
|
||||
Date: Thu, 30 Jul 2020 18:58:02 +0200
|
||||
Subject: [PATCH] build: Fix build failure on mingw (formatstring_ruby)
|
||||
|
||||
This fixes the following issue when compiling for Windows:
|
||||
undefined reference to `_imp__formatstring_ruby'
|
||||
|
||||
--- a/gettext-tools/woe32dll/gettextsrc-exports.c
|
||||
+++ b/gettext-tools/woe32dll/gettextsrc-exports.c
|
||||
@@ -50,6 +50,7 @@ VARIABLE(formatstring_python)
|
||||
VARIABLE(formatstring_python_brace)
|
||||
VARIABLE(formatstring_qt)
|
||||
VARIABLE(formatstring_qt_plural)
|
||||
+VARIABLE(formatstring_ruby)
|
||||
VARIABLE(formatstring_scheme)
|
||||
VARIABLE(formatstring_sh)
|
||||
VARIABLE(formatstring_smalltalk)
|
||||
@@ -0,0 +1,133 @@
|
||||
--- a/gettext-runtime/intl/libgnuintl.in.h
|
||||
+++ b/gettext-runtime/intl/libgnuintl.in.h
|
||||
@@ -359,11 +359,17 @@
|
||||
#undef fprintf
|
||||
#define fprintf libintl_fprintf
|
||||
extern int fprintf (FILE *, const char *, ...);
|
||||
+# if defined __cplusplus && !defined _INTL_CXX_NO_CLOBBER_STD_NAMESPACE
|
||||
+namespace std { using ::libintl_fprintf; }
|
||||
+# endif
|
||||
#endif
|
||||
#if !(defined vfprintf && defined _GL_STDIO_H) /* don't override gnulib */
|
||||
#undef vfprintf
|
||||
#define vfprintf libintl_vfprintf
|
||||
extern int vfprintf (FILE *, const char *, va_list);
|
||||
+# if defined __cplusplus && !defined _INTL_CXX_NO_CLOBBER_STD_NAMESPACE
|
||||
+namespace std { using ::libintl_vfprintf; }
|
||||
+# endif
|
||||
#endif
|
||||
|
||||
#if !(defined printf && defined _GL_STDIO_H) /* don't override gnulib */
|
||||
@@ -382,22 +388,34 @@
|
||||
#endif
|
||||
#define printf libintl_printf
|
||||
extern int printf (const char *, ...);
|
||||
+# if defined __cplusplus && !defined _INTL_CXX_NO_CLOBBER_STD_NAMESPACE
|
||||
+namespace std { using ::libintl_printf; }
|
||||
+# endif
|
||||
#endif
|
||||
#if !(defined vprintf && defined _GL_STDIO_H) /* don't override gnulib */
|
||||
#undef vprintf
|
||||
#define vprintf libintl_vprintf
|
||||
extern int vprintf (const char *, va_list);
|
||||
+# if defined __cplusplus && !defined _INTL_CXX_NO_CLOBBER_STD_NAMESPACE
|
||||
+namespace std { using ::libintl_vprintf; }
|
||||
+# endif
|
||||
#endif
|
||||
|
||||
#if !(defined sprintf && defined _GL_STDIO_H) /* don't override gnulib */
|
||||
#undef sprintf
|
||||
#define sprintf libintl_sprintf
|
||||
extern int sprintf (char *, const char *, ...);
|
||||
+# if defined __cplusplus && !defined _INTL_CXX_NO_CLOBBER_STD_NAMESPACE
|
||||
+namespace std { using ::libintl_sprintf; }
|
||||
+# endif
|
||||
#endif
|
||||
#if !(defined vsprintf && defined _GL_STDIO_H) /* don't override gnulib */
|
||||
#undef vsprintf
|
||||
#define vsprintf libintl_vsprintf
|
||||
extern int vsprintf (char *, const char *, va_list);
|
||||
+# if defined __cplusplus && !defined _INTL_CXX_NO_CLOBBER_STD_NAMESPACE
|
||||
+namespace std { using ::libintl_vsprintf; }
|
||||
+# endif
|
||||
#endif
|
||||
|
||||
#if @HAVE_SNPRINTF@
|
||||
@@ -406,11 +424,17 @@
|
||||
#undef snprintf
|
||||
#define snprintf libintl_snprintf
|
||||
extern int snprintf (char *, size_t, const char *, ...);
|
||||
+# if defined __cplusplus && !defined _INTL_CXX_NO_CLOBBER_STD_NAMESPACE
|
||||
+namespace std { using ::libintl_snprintf; }
|
||||
+# endif
|
||||
#endif
|
||||
#if !(defined vsnprintf && defined _GL_STDIO_H) /* don't override gnulib */
|
||||
#undef vsnprintf
|
||||
#define vsnprintf libintl_vsnprintf
|
||||
extern int vsnprintf (char *, size_t, const char *, va_list);
|
||||
+# if defined __cplusplus && !defined _INTL_CXX_NO_CLOBBER_STD_NAMESPACE
|
||||
+namespace std { using ::libintl_vsnprintf; }
|
||||
+# endif
|
||||
#endif
|
||||
|
||||
#endif
|
||||
@@ -421,11 +445,17 @@
|
||||
#undef asprintf
|
||||
#define asprintf libintl_asprintf
|
||||
extern int asprintf (char **, const char *, ...);
|
||||
+# if defined __cplusplus && !defined _INTL_CXX_NO_CLOBBER_STD_NAMESPACE
|
||||
+namespace std { using ::libintl_asprintf; }
|
||||
+# endif
|
||||
#endif
|
||||
#if !(defined vasprintf && defined _GL_STDIO_H) /* don't override gnulib */
|
||||
#undef vasprintf
|
||||
#define vasprintf libintl_vasprintf
|
||||
extern int vasprintf (char **, const char *, va_list);
|
||||
+# if defined __cplusplus && !defined _INTL_CXX_NO_CLOBBER_STD_NAMESPACE
|
||||
+namespace std { using ::libintl_vasprintf; }
|
||||
+# endif
|
||||
#endif
|
||||
|
||||
#endif
|
||||
@@ -435,23 +465,41 @@
|
||||
#undef fwprintf
|
||||
#define fwprintf libintl_fwprintf
|
||||
extern int fwprintf (FILE *, const wchar_t *, ...);
|
||||
+# if defined __cplusplus && !defined _INTL_CXX_NO_CLOBBER_STD_NAMESPACE
|
||||
+namespace std { using ::libintl_fwprintf; }
|
||||
+# endif
|
||||
#undef vfwprintf
|
||||
#define vfwprintf libintl_vfwprintf
|
||||
extern int vfwprintf (FILE *, const wchar_t *, va_list);
|
||||
+# if defined __cplusplus && !defined _INTL_CXX_NO_CLOBBER_STD_NAMESPACE
|
||||
+namespace std { using ::libintl_vfwprintf; }
|
||||
+# endif
|
||||
|
||||
#undef wprintf
|
||||
#define wprintf libintl_wprintf
|
||||
extern int wprintf (const wchar_t *, ...);
|
||||
+# if defined __cplusplus && !defined _INTL_CXX_NO_CLOBBER_STD_NAMESPACE
|
||||
+namespace std { using ::libintl_wprintf; }
|
||||
+# endif
|
||||
#undef vwprintf
|
||||
#define vwprintf libintl_vwprintf
|
||||
extern int vwprintf (const wchar_t *, va_list);
|
||||
+# if defined __cplusplus && !defined _INTL_CXX_NO_CLOBBER_STD_NAMESPACE
|
||||
+namespace std { using ::libintl_vwprintf; }
|
||||
+# endif
|
||||
|
||||
#undef swprintf
|
||||
#define swprintf libintl_swprintf
|
||||
extern int swprintf (wchar_t *, size_t, const wchar_t *, ...);
|
||||
+# if defined __cplusplus && !defined _INTL_CXX_NO_CLOBBER_STD_NAMESPACE
|
||||
+namespace std { using ::libintl_swprintf; }
|
||||
+# endif
|
||||
#undef vswprintf
|
||||
#define vswprintf libintl_vswprintf
|
||||
extern int vswprintf (wchar_t *, size_t, const wchar_t *, va_list);
|
||||
+# if defined __cplusplus && !defined _INTL_CXX_NO_CLOBBER_STD_NAMESPACE
|
||||
+namespace std { using ::libintl_vswprintf; }
|
||||
+# endif
|
||||
|
||||
#endif
|
||||
|
||||
@@ -1,159 +0,0 @@
|
||||
--- gettext-tools/misc/autopoint.in 2011-09-06 23:40:21 -0400
|
||||
+++ gettext-tools/misc/autopoint.in 2011-09-09 11:45:07 -0400
|
||||
@@ -100,7 +100,7 @@ func_find_curr_installdir ()
|
||||
*) curr_executable=`pwd`/"$curr_executable" ;;
|
||||
esac
|
||||
# Resolve symlinks.
|
||||
- sed_dirname='s,/[^/]*$,,'
|
||||
+ sed_dirname='s,[\\/][^\\/]*$,,'
|
||||
sed_linkdest='s,^.* -> \(.*\),\1,p'
|
||||
while : ; do
|
||||
lsline=`LC_ALL=C ls -l "$curr_executable"`
|
||||
@@ -114,7 +114,7 @@ func_find_curr_installdir ()
|
||||
*) break ;;
|
||||
esac
|
||||
done
|
||||
- curr_installdir=`echo "$curr_executable" | sed -e 's,/[^/]*$,,'`
|
||||
+ curr_installdir=`echo "$curr_executable" | sed -e 's,[\\/][^\\/]*$,,'`
|
||||
# Canonicalize.
|
||||
curr_installdir=`cd "$curr_installdir" && pwd`
|
||||
}
|
||||
@@ -125,16 +125,16 @@ func_find_prefixes ()
|
||||
orig_installprefix="$orig_installdir"
|
||||
curr_installprefix="$curr_installdir"
|
||||
while true; do
|
||||
- orig_last=`echo "$orig_installprefix" | sed -n -e 's,^.*/\([^/]*\)$,\1,p'`
|
||||
- curr_last=`echo "$curr_installprefix" | sed -n -e 's,^.*/\([^/]*\)$,\1,p'`
|
||||
+ orig_last=`echo "$orig_installprefix" | sed -n -e 's,^.*[\\/]\([^\\/]*\)$,\1,p'`
|
||||
+ curr_last=`echo "$curr_installprefix" | sed -n -e 's,^.*[\\/]\([^\\/]*\)$,\1,p'`
|
||||
if test -z "$orig_last" || test -z "$curr_last"; then
|
||||
break
|
||||
fi
|
||||
if test "$orig_last" != "$curr_last"; then
|
||||
break
|
||||
fi
|
||||
- orig_installprefix=`echo "$orig_installprefix" | sed -e 's,/[^/]*$,,'`
|
||||
- curr_installprefix=`echo "$curr_installprefix" | sed -e 's,/[^/]*$,,'`
|
||||
+ orig_installprefix=`echo "$orig_installprefix" | sed -e 's,[\\/][^\\/]*$,,'`
|
||||
+ curr_installprefix=`echo "$curr_installprefix" | sed -e 's,[\\/][^\\/]*$,,'`
|
||||
done
|
||||
}
|
||||
if test "@RELOCATABLE@" = yes; then
|
||||
@@ -144,7 +144,7 @@ if test "@RELOCATABLE@" = yes; then
|
||||
func_find_curr_installdir # determine curr_installdir
|
||||
func_find_prefixes
|
||||
# Relocate the directory variables that we use.
|
||||
- gettext_datadir=`echo "$gettext_datadir/" | sed -e "s%^${orig_installprefix}/%${curr_installprefix}/%" | sed -e 's,/$,,'`
|
||||
+ gettext_datadir=`echo "$gettext_datadir/" | sed -e "s%^${orig_installprefix}/%${curr_installprefix}/%" | sed -e 's,[\\/]$,,'`
|
||||
fi
|
||||
|
||||
# func_trace macro configure.ac
|
||||
@@ -543,7 +543,7 @@ func_destfile ()
|
||||
# po/* ->
|
||||
sharedowner=
|
||||
allpodirs=
|
||||
- case `echo "$1" | sed -e 's,[^/]*$,,'` in
|
||||
+ case `echo "$1" | sed -e 's,[^\\/]*$,,'` in
|
||||
"" )
|
||||
case "$1" in
|
||||
config.rpath ) destfile="$auxdir$1" ;;
|
||||
@@ -551,7 +551,7 @@ func_destfile ()
|
||||
* ) destfile="$1" ;;
|
||||
esac
|
||||
;;
|
||||
- m4/ ) destfile=`echo "$1" | sed -e "s,^m4/,$m4dir/,"` ;;
|
||||
+ m4/ ) destfile=`echo "$1" | sed -e "s,^m4\([\\/]\),$m4dir\1,"` ;;
|
||||
intl/ ) if test -n "$omitintl"; then destfile=""; else destfile="$1"; fi ;;
|
||||
po/ ) destfile=`echo "$1" | sed -e "s,^po/,,"` allpodirs=yes ;;
|
||||
* ) destfile="$1" ;;
|
||||
@@ -600,7 +600,7 @@ if test -z "$force"; then
|
||||
mismatch=
|
||||
func_tmpdir
|
||||
mismatchfile="$tmp"/autopoint.diff
|
||||
- for file in `find "$work_dir/archive" -type f -print | sed -e "s,^$work_dir/archive/,," | LC_ALL=C sort`; do
|
||||
+ for file in `find "$work_dir/archive" -type f -print | sed -e "s,^$work_dir[\\/]archive[\\/],," | LC_ALL=C sort`; do
|
||||
func_destfile "$file"
|
||||
if test -n "$destfile"; then
|
||||
func_compare_to_destfile ()
|
||||
@@ -613,7 +613,7 @@ if test -z "$force"; then
|
||||
else
|
||||
echo "autopoint: File $finaldestfile has been locally modified." 1>&2
|
||||
mismatch=yes
|
||||
- diff -c "$work_dir/archive/$file" "$finaldestfile" | sed -e "1s,$work_dir/archive/,," >> "$mismatchfile"
|
||||
+ diff -c "$work_dir/archive/$file" "$finaldestfile" | sed -e "1s,$work_dir[\\/]archive[\\/],," >> "$mismatchfile"
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
@@ -639,11 +639,11 @@ fi
|
||||
# 'to' is a relative pathname, relative to the current directory.
|
||||
func_mkdir_for ()
|
||||
{
|
||||
- base=`echo "$1" | sed -e 's,/[^/]*$,,'`
|
||||
+ base=`echo "$1" | sed -e 's,[\\/][^\\/]*$,,'`
|
||||
if test "X$base" != "X$1" && test -n "$base"; then
|
||||
func_mkdir_for "$base"
|
||||
# Recompute base. It was clobbered by the recursive call.
|
||||
- base=`echo "$1" | sed -e 's,/[^/]*$,,'`
|
||||
+ base=`echo "$1" | sed -e 's,[\\/][^\\/]*$,,'`
|
||||
test -d "$base" || { echo "Creating directory $base"; mkdir "$base"; }
|
||||
fi
|
||||
}
|
||||
@@ -678,7 +678,7 @@ func_backup ()
|
||||
}
|
||||
|
||||
# Now copy the files.
|
||||
-for file in `find "$work_dir/archive" -type f -print | sed -e "s,^$work_dir/archive/,," | LC_ALL=C sort`; do
|
||||
+for file in `find "$work_dir/archive" -type f -print | sed -e "s,^$work_dir[\\/]archive[\\/],," | LC_ALL=C sort`; do
|
||||
func_destfile "$file"
|
||||
if test -n "$destfile"; then
|
||||
func_copy_to_destfile ()
|
||||
--- gettext-tools/misc/gettextize.in 2010-06-06 08:49:57 -0400
|
||||
+++ gettext-tools/misc/gettextize.in 2011-09-09 11:37:21 -0400
|
||||
@@ -100,7 +100,7 @@ func_find_curr_installdir ()
|
||||
*) curr_executable=`pwd`/"$curr_executable" ;;
|
||||
esac
|
||||
# Resolve symlinks.
|
||||
- sed_dirname='s,/[^/]*$,,'
|
||||
+ sed_dirname='s,[\\/][^\\/]*$,,'
|
||||
sed_linkdest='s,^.* -> \(.*\),\1,p'
|
||||
while : ; do
|
||||
lsline=`LC_ALL=C ls -l "$curr_executable"`
|
||||
@@ -114,7 +114,7 @@ func_find_curr_installdir ()
|
||||
*) break ;;
|
||||
esac
|
||||
done
|
||||
- curr_installdir=`echo "$curr_executable" | sed -e 's,/[^/]*$,,'`
|
||||
+ curr_installdir=`echo "$curr_executable" | sed -e 's,[\\/][^\\/]*$,,'`
|
||||
# Canonicalize.
|
||||
curr_installdir=`cd "$curr_installdir" && pwd`
|
||||
}
|
||||
@@ -125,16 +125,16 @@ func_find_prefixes ()
|
||||
orig_installprefix="$orig_installdir"
|
||||
curr_installprefix="$curr_installdir"
|
||||
while true; do
|
||||
- orig_last=`echo "$orig_installprefix" | sed -n -e 's,^.*/\([^/]*\)$,\1,p'`
|
||||
- curr_last=`echo "$curr_installprefix" | sed -n -e 's,^.*/\([^/]*\)$,\1,p'`
|
||||
+ orig_last=`echo "$orig_installprefix" | sed -n -e 's,^.*[\\/]\([^\\/]*\)$,\1,p'`
|
||||
+ curr_last=`echo "$curr_installprefix" | sed -n -e 's,^.*]\\/]\([^\\/]*\)$,\1,p'`
|
||||
if test -z "$orig_last" || test -z "$curr_last"; then
|
||||
break
|
||||
fi
|
||||
if test "$orig_last" != "$curr_last"; then
|
||||
break
|
||||
fi
|
||||
- orig_installprefix=`echo "$orig_installprefix" | sed -e 's,/[^/]*$,,'`
|
||||
- curr_installprefix=`echo "$curr_installprefix" | sed -e 's,/[^/]*$,,'`
|
||||
+ orig_installprefix=`echo "$orig_installprefix" | sed -e 's,[\\/][^\\/]*$,,'`
|
||||
+ curr_installprefix=`echo "$curr_installprefix" | sed -e 's,[\\/][^\\/]*$,,'`
|
||||
done
|
||||
}
|
||||
if test "@RELOCATABLE@" = yes; then
|
||||
@@ -144,7 +144,7 @@ if test "@RELOCATABLE@" = yes; then
|
||||
func_find_curr_installdir # determine curr_installdir
|
||||
func_find_prefixes
|
||||
# Relocate the directory variables that we use.
|
||||
- gettext_datadir=`echo "$gettext_datadir/" | sed -e "s%^${orig_installprefix}/%${curr_installprefix}/%" | sed -e 's,/$,,'`
|
||||
+ gettext_datadir=`echo "$gettext_datadir/" | sed -e "s%^${orig_installprefix}\([\\/]\)%${curr_installprefix}\1%" | sed -e 's,[\\/]$,,'`
|
||||
fi
|
||||
|
||||
# func_trace macro configure.ac
|
||||
@@ -1,11 +0,0 @@
|
||||
--- gettext-runtime/intl/printf.c.orig 2012-09-22 16:23:24 +0400
|
||||
+++ gettext-runtime/intl/printf.c 2012-09-22 23:45:29 +0400
|
||||
@@ -209,7 +209,7 @@
|
||||
int
|
||||
libintl_vsnprintf (char *resultbuf, size_t length, const char *format, va_list args)
|
||||
{
|
||||
- if (strchr (format, '$') == NULL)
|
||||
+ if (0 && (strchr (format, '$') == NULL))
|
||||
return system_vsnprintf (resultbuf, length, format, args);
|
||||
else
|
||||
{
|
||||
@@ -1,44 +0,0 @@
|
||||
--- gettext-tools/gnulib-lib/libxml/parser.c.orig 2013-01-18 10:24:37 +0400
|
||||
+++ gettext-tools/gnulib-lib/libxml/parser.c 2013-01-18 10:36:35 +0400
|
||||
@@ -42,6 +42,9 @@
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
#include <stdarg.h>
|
||||
+#ifdef HAVE_CTYPE_H
|
||||
+#include <ctype.h>
|
||||
+#endif
|
||||
#include <libxml/xmlmemory.h>
|
||||
#include <libxml/threads.h>
|
||||
#include <libxml/globals.h>
|
||||
@@ -61,9 +64,6 @@
|
||||
#include <libxml/xmlschemastypes.h>
|
||||
#include <libxml/relaxng.h>
|
||||
#endif
|
||||
-#ifdef HAVE_CTYPE_H
|
||||
-#include <ctype.h>
|
||||
-#endif
|
||||
#ifdef HAVE_STDLIB_H
|
||||
#include <stdlib.h>
|
||||
#endif
|
||||
--- gettext-tools/gnulib-lib/libxml/threads.c.orig 2013-01-18 10:38:24 +0400
|
||||
+++ gettext-tools/gnulib-lib/libxml/threads.c 2013-01-18 10:41:11 +0400
|
||||
@@ -12,15 +12,16 @@
|
||||
|
||||
#include <string.h>
|
||||
|
||||
+#ifdef HAVE_UNISTD_H
|
||||
+#include <unistd.h>
|
||||
+#endif
|
||||
+
|
||||
#include <libxml/threads.h>
|
||||
#include <libxml/globals.h>
|
||||
|
||||
#ifdef HAVE_SYS_TYPES_H
|
||||
#include <sys/types.h>
|
||||
#endif
|
||||
-#ifdef HAVE_UNISTD_H
|
||||
-#include <unistd.h>
|
||||
-#endif
|
||||
#ifdef HAVE_STDLIB_H
|
||||
#include <stdlib.h>
|
||||
#endif
|
||||
@@ -1,63 +0,0 @@
|
||||
--- gettext-runtime/libasprintf/vasnprintf.h.orig 2013-01-17 09:09:12 +0400
|
||||
+++ gettext-runtime/libasprintf/vasnprintf.h 2013-05-01 17:33:31 +0400
|
||||
@@ -40,6 +40,8 @@
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
+#if !defined(__USE_MINGW_ANSI_STDIO) && defined(__MINGW64_VERSION_MAJOR)
|
||||
+
|
||||
/* Write formatted output to a string dynamically allocated with malloc().
|
||||
You can pass a preallocated buffer for the result in RESULTBUF and its
|
||||
size in *LENGTHP; otherwise you pass RESULTBUF = NULL.
|
||||
@@ -64,11 +66,14 @@
|
||||
free (output);
|
||||
}
|
||||
*/
|
||||
+
|
||||
extern char * asnprintf (char *resultbuf, size_t *lengthp, const char *format, ...)
|
||||
__attribute__ ((__format__ (__printf__, 3, 4)));
|
||||
extern char * vasnprintf (char *resultbuf, size_t *lengthp, const char *format, va_list args)
|
||||
__attribute__ ((__format__ (__printf__, 3, 0)));
|
||||
|
||||
+#endif /* !defined(__USE_MINGW_ANSI_STDIO) && defined(__MINGW64_VERSION_MAJOR) */
|
||||
+
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
--- gettext-runtime/libasprintf/vasprintf.h.orig 2013-04-30 09:03:19 +0400
|
||||
+++ gettext-runtime/libasprintf/vasprintf.h 2013-05-01 17:32:04 +0400
|
||||
@@ -37,6 +37,8 @@
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
+#if !defined(__USE_MINGW_ANSI_STDIO) && defined(__MINGW64_VERSION_MAJOR)
|
||||
+
|
||||
/* Write formatted output to a string dynamically allocated with malloc().
|
||||
If the memory allocation succeeds, store the address of the string in
|
||||
*RESULT and return the number of resulting bytes, excluding the trailing
|
||||
@@ -46,6 +48,8 @@
|
||||
extern int vasprintf (char **result, const char *format, va_list args)
|
||||
__attribute__ ((__format__ (__printf__, 2, 0)));
|
||||
|
||||
+#endif /* !defined(__USE_MINGW_ANSI_STDIO) && defined(__MINGW64_VERSION_MAJOR) */
|
||||
+
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
--- gettext-runtime/libasprintf/vasnprintf.c.orig 2013-05-01 18:07:02 +0400
|
||||
+++ gettext-runtime/libasprintf/vasnprintf.c 2013-05-01 18:42:46 +0400
|
||||
@@ -67,7 +67,14 @@
|
||||
#endif
|
||||
|
||||
#include <locale.h> /* localeconv() */
|
||||
+#if defined(__MINGW64_VERSION_MAJOR) && defined(__USE_MINGW_ANSI_STDIO)
|
||||
+# define REMOVED__USE_MINGW_ANSI_STDIO
|
||||
+# undef __USE_MINGW_ANSI_STDIO
|
||||
+#endif
|
||||
#include <stdio.h> /* snprintf(), sprintf() */
|
||||
+#if defined(__MINGW64_VERSION_MAJOR) && defined(REMOVED__USE_MINGW_ANSI_STDIO)
|
||||
+# define __USE_MINGW_ANSI_STDIO
|
||||
+#endif
|
||||
#include <stdlib.h> /* abort(), malloc(), realloc(), free() */
|
||||
#include <string.h> /* memcpy(), strlen() */
|
||||
#include <errno.h> /* errno */
|
||||
@@ -1,11 +0,0 @@
|
||||
--- gettext-runtime/intl/libgnuintl.in.h.old 2015-06-15 10:40:11.594942600 +0200
|
||||
+++ gettext-runtime/intl/libgnuintl.in.h 2015-06-15 10:40:50.579345400 +0200
|
||||
@@ -336,7 +336,7 @@ extern int vfprintf (FILE *, const char
|
||||
|
||||
#if !(defined printf && defined _GL_STDIO_H) /* don't override gnulib */
|
||||
#undef printf
|
||||
-#if defined __NetBSD__ || defined __BEOS__ || defined __CYGWIN__ || defined __MINGW32__
|
||||
+#if defined __NetBSD__ || defined __BEOS__ || defined __CYGWIN__ || defined __MINGW32__ || defined _MSC_VER
|
||||
/* Don't break __attribute__((format(printf,M,N))).
|
||||
This redefinition is only possible because the libc in NetBSD, Cygwin,
|
||||
mingw does not have a function __printf__.
|
||||
@@ -1,44 +0,0 @@
|
||||
--- gettext-0.19.8.1/gettext-runtime/gnulib-m4/asm-underscore.m4.orig 2017-01-17 11:42:29.417883700 +0300
|
||||
+++ gettext-0.19.8.1/gettext-runtime/gnulib-m4/asm-underscore.m4 2017-01-17 11:42:37.039697600 +0300
|
||||
@@ -29,7 +29,7 @@
|
||||
EOF
|
||||
# Look for the assembly language name in the .s file.
|
||||
AC_TRY_COMMAND(${CC-cc} $CFLAGS $CPPFLAGS $gl_c_asm_opt conftest.c) >/dev/null 2>&1
|
||||
- if LC_ALL=C grep -E '(^|[^a-zA-Z0-9_])_foo([^a-zA-Z0-9_]|$)' conftest.$gl_asmext >/dev/null; then
|
||||
+ if LC_ALL=C grep -E '(^|[[^a-zA-Z0-9_]])_foo([[^a-zA-Z0-9_]]|$)' conftest.$gl_asmext >/dev/null; then
|
||||
gl_cv_prog_as_underscore=yes
|
||||
else
|
||||
gl_cv_prog_as_underscore=no
|
||||
--- gettext-0.19.8.1/gettext-tools/gnulib-m4/asm-underscore.m4.orig 2017-01-17 11:41:49.073406600 +0300
|
||||
+++ gettext-0.19.8.1/gettext-tools/gnulib-m4/asm-underscore.m4 2017-01-17 11:42:07.503241900 +0300
|
||||
@@ -29,7 +29,7 @@
|
||||
EOF
|
||||
# Look for the assembly language name in the .s file.
|
||||
AC_TRY_COMMAND(${CC-cc} $CFLAGS $CPPFLAGS $gl_c_asm_opt conftest.c) >/dev/null 2>&1
|
||||
- if LC_ALL=C grep -E '(^|[^a-zA-Z0-9_])_foo([^a-zA-Z0-9_]|$)' conftest.$gl_asmext >/dev/null; then
|
||||
+ if LC_ALL=C grep -E '(^|[[^a-zA-Z0-9_]])_foo([[^a-zA-Z0-9_]]|$)' conftest.$gl_asmext >/dev/null; then
|
||||
gl_cv_prog_as_underscore=yes
|
||||
else
|
||||
gl_cv_prog_as_underscore=no
|
||||
--- gettext-0.19.8.1/gettext-runtime/configure.orig 2017-01-17 11:42:29.417883700 +0300
|
||||
+++ gettext-0.19.8.1/gettext-runtime/configure 2017-01-17 11:42:37.039697600 +0300
|
||||
@@ -24606,7 +24606,7 @@
|
||||
ac_status=$?
|
||||
$as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
|
||||
test $ac_status = 0; }; } >/dev/null 2>&1
|
||||
- if LC_ALL=C grep -E '(^|^a-zA-Z0-9_)_foo(^a-zA-Z0-9_|$)' conftest.$gl_asmext >/dev/null; then
|
||||
+ if LC_ALL=C grep -E '(^|[^a-zA-Z0-9_])_foo(^[a-zA-Z0-9_]|$)' conftest.$gl_asmext >/dev/null; then
|
||||
gl_cv_prog_as_underscore=yes
|
||||
else
|
||||
gl_cv_prog_as_underscore=no
|
||||
--- gettext-0.19.8.1/gettext-tools/configure.orig 2017-01-17 11:42:29.417883700 +0300
|
||||
+++ gettext-0.19.8.1/gettext-tools/configure 2017-01-17 11:42:37.039697600 +0300
|
||||
@@ -32286,7 +32286,7 @@
|
||||
ac_status=$?
|
||||
$as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
|
||||
test $ac_status = 0; }; } >/dev/null 2>&1
|
||||
- if LC_ALL=C grep -E '(^|^a-zA-Z0-9_)_foo(^a-zA-Z0-9_|$)' conftest.$gl_asmext >/dev/null; then
|
||||
+ if LC_ALL=C grep -E '(^|[^a-zA-Z0-9_])_foo(^[a-zA-Z0-9_]|$)' conftest.$gl_asmext >/dev/null; then
|
||||
gl_cv_prog_as_underscore=yes
|
||||
else
|
||||
gl_cv_prog_as_underscore=no
|
||||
@@ -1,348 +0,0 @@
|
||||
From d4ecf6f15ad7a428786df2efdc88b03be0a4fdbb Mon Sep 17 00:00:00 2001
|
||||
From: Daiki Ueno <ueno@gnu.org>
|
||||
Date: Thu, 17 Jan 2013 18:33:40 +0900
|
||||
Subject: [PATCH] Fix Woe32 link errors when compiling with -O0.
|
||||
|
||||
---
|
||||
gettext-tools/src/Makefile.am | 24 ++++++++++++++++++++++--
|
||||
gettext-tools/src/color.c | 1 +
|
||||
gettext-tools/woe32dll/c++color.cc | 1 +
|
||||
gettext-tools/woe32dll/c++file-ostream.cc | 2 ++
|
||||
gettext-tools/woe32dll/c++html-ostream.cc | 1 +
|
||||
gettext-tools/woe32dll/c++styled-ostream.cc | 1 +
|
||||
gettext-tools/woe32dll/c++term-ostream.cc | 1 +
|
||||
gettext-tools/woe32dll/c++write-catalog.cc | 1 +
|
||||
gettext-tools/woe32dll/c++write-po.cc | 1 +
|
||||
gettext-tools/woe32dll/c++write-properties.cc | 1 +
|
||||
gettext-tools/woe32dll/c++write-stringtable.cc | 1 +
|
||||
gnulib-local/modules/file-ostream | 4 ++++
|
||||
gnulib-local/modules/html-ostream | 4 ++++
|
||||
gnulib-local/modules/ostream | 4 ++++
|
||||
gnulib-local/modules/styled-ostream | 4 ++++
|
||||
gnulib-local/modules/term-ostream | 4 ++++
|
||||
16 files changed, 53 insertions(+), 2 deletions(-)
|
||||
create mode 100644 gettext-tools/woe32dll/c++color.cc
|
||||
create mode 100644 gettext-tools/woe32dll/c++file-ostream.cc
|
||||
create mode 100644 gettext-tools/woe32dll/c++html-ostream.cc
|
||||
create mode 100644 gettext-tools/woe32dll/c++styled-ostream.cc
|
||||
create mode 100644 gettext-tools/woe32dll/c++term-ostream.cc
|
||||
create mode 100644 gettext-tools/woe32dll/c++write-catalog.cc
|
||||
create mode 100644 gettext-tools/woe32dll/c++write-po.cc
|
||||
create mode 100644 gettext-tools/woe32dll/c++write-properties.cc
|
||||
create mode 100644 gettext-tools/woe32dll/c++write-stringtable.cc
|
||||
|
||||
Additional fix (COLOR_SOURCE) by Ray Donnelly <mingw.android@gmail.com>
|
||||
|
||||
diff -urN a/gettext-tools/src/Makefile.am b/gettext-tools/src/Makefile.am
|
||||
--- a/gettext-tools/src/Makefile.am 2013-08-15 17:15:56.000000000 +0100
|
||||
+++ b/gettext-tools/src/Makefile.am 2013-12-12 23:49:22.198570891 +0000
|
||||
@@ -141,10 +141,30 @@
|
||||
format-lua.c \
|
||||
format-javascript.c
|
||||
|
||||
+if !WOE32DLL
|
||||
+COLOR_SOURCE = color.c
|
||||
+else
|
||||
+COLOR_SOURCE = ../woe32dll/c++color.cc
|
||||
+endif
|
||||
+
|
||||
+if !WOE32DLL
|
||||
+OUTPUT_SOURCE = \
|
||||
+ write-catalog.c \
|
||||
+ write-po.c \
|
||||
+ write-properties.c \
|
||||
+ write-stringtable.c
|
||||
+else
|
||||
+OUTPUT_SOURCE = \
|
||||
+ ../woe32dll/c++write-catalog.cc \
|
||||
+ ../woe32dll/c++write-po.cc \
|
||||
+ ../woe32dll/c++write-properties.cc \
|
||||
+ ../woe32dll/c++write-stringtable.cc
|
||||
+endif
|
||||
+
|
||||
# libgettextsrc contains all code that is needed by at least two programs.
|
||||
libgettextsrc_la_SOURCES = \
|
||||
$(COMMON_SOURCE) read-catalog.c \
|
||||
-color.c write-catalog.c write-properties.c write-stringtable.c write-po.c \
|
||||
+$(COLOR_SOURCE) $(OUTPUT_SOURCE) \
|
||||
msgl-ascii.c msgl-iconv.c msgl-equal.c msgl-cat.c msgl-header.c msgl-english.c \
|
||||
msgl-check.c file-list.c msgl-charset.c po-time.c plural-exp.c plural-eval.c \
|
||||
plural-table.c \
|
||||
diff -urN a/gettext-tools/src/Makefile.in b/gettext-tools/src/Makefile.in
|
||||
--- a/gettext-tools/src/Makefile.in 2013-08-15 17:31:16.000000000 +0100
|
||||
+++ b/gettext-tools/src/Makefile.in 2013-12-12 23:53:30.512410954 +0000
|
||||
@@ -402,8 +402,13 @@
|
||||
am__libgettextsrc_la_SOURCES_DIST = message.c po-error.c po-xerror.c \
|
||||
read-catalog-abstract.c po-lex.c po-gram-gen.y po-charset.c \
|
||||
read-po.c read-properties.c read-stringtable.c open-catalog.c \
|
||||
- dir-list.c str-list.c read-catalog.c color.c write-catalog.c \
|
||||
- write-properties.c write-stringtable.c write-po.c msgl-ascii.c \
|
||||
+ dir-list.c str-list.c read-catalog.c color.c \
|
||||
+ ../woe32dll/c++color.cc write-catalog.c \
|
||||
+ write-properties.c write-stringtable.c write-po.c
|
||||
+ ../woe32dll/c++write-catalog.cc \
|
||||
+ ../woe32dll/c++write-po.cc \
|
||||
+ ../woe32dll/c++write-properties.cc \
|
||||
+ ../woe32dll/c++write-stringtable.cc msgl-ascii.c \
|
||||
msgl-iconv.c msgl-equal.c msgl-cat.c msgl-header.c \
|
||||
msgl-english.c msgl-check.c file-list.c msgl-charset.c \
|
||||
po-time.c plural-exp.c plural-eval.c plural-table.c quote.h \
|
||||
@@ -400,7 +404,17 @@
|
||||
libgettextsrc_la-open-catalog.lo libgettextsrc_la-dir-list.lo \
|
||||
libgettextsrc_la-str-list.lo
|
||||
am__dirstamp = $(am__leading_dot)dirstamp
|
||||
-@WOE32DLL_FALSE@am__objects_2 = libgettextsrc_la-format.lo \
|
||||
+@WOE32DLL_FALSE@am__objects_2 = libgettextsrc_la-color.lo
|
||||
+@WOE32DLL_TRUE@am__objects_2 = libgettextsrc_la-c++color.lo
|
||||
+@WOE32DLL_FALSE@am__objects_3 = libgettextsrc_la-write-catalog.lo \
|
||||
+@WOE32DLL_FALSE@ libgettextsrc_la-write-po.lo \
|
||||
+@WOE32DLL_FALSE@ libgettextsrc_la-write-properties.lo \
|
||||
+@WOE32DLL_FALSE@ libgettextsrc_la-write-stringtable.lo
|
||||
+@WOE32DLL_TRUE@am__objects_3 = libgettextsrc_la-c++write-catalog.lo \
|
||||
+@WOE32DLL_TRUE@ libgettextsrc_la-c++write-po.lo \
|
||||
+@WOE32DLL_TRUE@ libgettextsrc_la-c++write-properties.lo \
|
||||
+@WOE32DLL_TRUE@ libgettextsrc_la-c++write-stringtable.lo
|
||||
+@WOE32DLL_FALSE@am__objects_4 = libgettextsrc_la-format.lo \
|
||||
@WOE32DLL_FALSE@ libgettextsrc_la-format-c.lo \
|
||||
@WOE32DLL_FALSE@ libgettextsrc_la-format-sh.lo \
|
||||
@WOE32DLL_FALSE@ libgettextsrc_la-format-python.lo \
|
||||
@@ -426,7 +440,7 @@
|
||||
@WOE32DLL_FALSE@ libgettextsrc_la-format-boost.lo \
|
||||
@WOE32DLL_FALSE@ libgettextsrc_la-format-lua.lo \
|
||||
@WOE32DLL_FALSE@ libgettextsrc_la-format-javascript.lo
|
||||
-@WOE32DLL_TRUE@am__objects_2 = \
|
||||
+@WOE32DLL_TRUE@am__objects_4 = \
|
||||
@WOE32DLL_TRUE@ ../woe32dll/libgettextsrc_la-c++format.lo \
|
||||
@WOE32DLL_TRUE@ libgettextsrc_la-format-c.lo \
|
||||
@WOE32DLL_TRUE@ libgettextsrc_la-format-sh.lo \
|
||||
@@ -452,23 +466,20 @@
|
||||
@WOE32DLL_TRUE@ libgettextsrc_la-format-boost.lo \
|
||||
@WOE32DLL_TRUE@ libgettextsrc_la-format-lua.lo \
|
||||
@WOE32DLL_TRUE@ libgettextsrc_la-format-javascript.lo
|
||||
-@WOE32DLL_TRUE@am__objects_3 = ../woe32dll/libgettextsrc_la-gettextsrc-exports.lo
|
||||
+@WOE32DLL_TRUE@am__objects_5 = ../woe32dll/libgettextsrc_la-gettextsrc-exports.lo
|
||||
am_libgettextsrc_la_OBJECTS = $(am__objects_1) \
|
||||
- libgettextsrc_la-read-catalog.lo libgettextsrc_la-color.lo \
|
||||
- libgettextsrc_la-write-catalog.lo \
|
||||
- libgettextsrc_la-write-properties.lo \
|
||||
- libgettextsrc_la-write-stringtable.lo \
|
||||
- libgettextsrc_la-write-po.lo libgettextsrc_la-msgl-ascii.lo \
|
||||
+ libgettextsrc_la-read-catalog.lo $(am__objects_2) \
|
||||
+ $(am__objects_3) libgettextsrc_la-msgl-ascii.lo \
|
||||
libgettextsrc_la-msgl-iconv.lo libgettextsrc_la-msgl-equal.lo \
|
||||
libgettextsrc_la-msgl-cat.lo libgettextsrc_la-msgl-header.lo \
|
||||
libgettextsrc_la-msgl-english.lo \
|
||||
libgettextsrc_la-msgl-check.lo libgettextsrc_la-file-list.lo \
|
||||
libgettextsrc_la-msgl-charset.lo libgettextsrc_la-po-time.lo \
|
||||
libgettextsrc_la-plural-exp.lo libgettextsrc_la-plural-eval.lo \
|
||||
libgettextsrc_la-plural-table.lo libgettextsrc_la-sentence.lo \
|
||||
- $(am__objects_2) libgettextsrc_la-read-desktop.lo \
|
||||
+ $(am__objects_4) libgettextsrc_la-read-desktop.lo \
|
||||
libgettextsrc_la-locating-rule.lo libgettextsrc_la-its.lo \
|
||||
- libgettextsrc_la-search-path.lo $(am__objects_3)
|
||||
+ libgettextsrc_la-search-path.lo $(am__objects_5)
|
||||
libgettextsrc_la_OBJECTS = $(am_libgettextsrc_la_OBJECTS)
|
||||
PROGRAMS = $(bin_PROGRAMS) $(noinst_PROGRAMS)
|
||||
am_cldr_plurals_OBJECTS = cldr_plurals-cldr-plural.$(OBJEXT) \
|
||||
@@ -2260,11 +2260,25 @@
|
||||
@WOE32DLL_TRUE@ format-qt.c format-qt-plural.c format-kde.c \
|
||||
@WOE32DLL_TRUE@ format-kde-kuit.c format-boost.c format-lua.c \
|
||||
@WOE32DLL_TRUE@ format-javascript.c
|
||||
+@WOE32DLL_FALSE@COLOR_SOURCE = color.c
|
||||
+@WOE32DLL_TRUE@COLOR_SOURCE = ../woe32dll/c++color.cc
|
||||
+@WOE32DLL_FALSE@OUTPUT_SOURCE = \
|
||||
+@WOE32DLL_FALSE@ write-catalog.c \
|
||||
+@WOE32DLL_FALSE@ write-po.c \
|
||||
+@WOE32DLL_FALSE@ write-properties.c \
|
||||
+@WOE32DLL_FALSE@ write-stringtable.c
|
||||
+
|
||||
+@WOE32DLL_TRUE@OUTPUT_SOURCE = \
|
||||
+@WOE32DLL_TRUE@ ../woe32dll/c++write-catalog.cc \
|
||||
+@WOE32DLL_TRUE@ ../woe32dll/c++write-po.cc \
|
||||
+@WOE32DLL_TRUE@ ../woe32dll/c++write-properties.cc \
|
||||
+@WOE32DLL_TRUE@ ../woe32dll/c++write-stringtable.cc
|
||||
+
|
||||
|
||||
# libgettextsrc contains all code that is needed by at least two programs.
|
||||
-libgettextsrc_la_SOURCES = $(COMMON_SOURCE) read-catalog.c color.c \
|
||||
- write-catalog.c write-properties.c write-stringtable.c \
|
||||
- write-po.c msgl-ascii.c msgl-iconv.c msgl-equal.c msgl-cat.c \
|
||||
+libgettextsrc_la_SOURCES = $(COMMON_SOURCE) read-catalog.c \
|
||||
+ $(COLOR_SOURCE) $(OUTPUT_SOURCE) \
|
||||
+ msgl-ascii.c msgl-iconv.c msgl-equal.c msgl-cat.c \
|
||||
msgl-header.c msgl-english.c msgl-check.c file-list.c \
|
||||
msgl-charset.c po-time.c plural-exp.c plural-eval.c \
|
||||
plural-table.c quote.h sentence.h sentence.c $(FORMAT_SOURCE) \
|
||||
@@ -2476,15 +2500,15 @@
|
||||
libgettextsrc_la-write-catalog.lo: write-catalog.c
|
||||
$(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libgettextsrc_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o libgettextsrc_la-write-catalog.lo `test -f 'write-catalog.c' || echo '$(srcdir)/'`write-catalog.c
|
||||
|
||||
+libgettextsrc_la-write-po.lo: write-po.c
|
||||
+ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libgettextsrc_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o libgettextsrc_la-write-po.lo `test -f 'write-po.c' || echo '$(srcdir)/'`write-po.c
|
||||
+
|
||||
libgettextsrc_la-write-properties.lo: write-properties.c
|
||||
$(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libgettextsrc_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o libgettextsrc_la-write-properties.lo `test -f 'write-properties.c' || echo '$(srcdir)/'`write-properties.c
|
||||
|
||||
libgettextsrc_la-write-stringtable.lo: write-stringtable.c
|
||||
$(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libgettextsrc_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o libgettextsrc_la-write-stringtable.lo `test -f 'write-stringtable.c' || echo '$(srcdir)/'`write-stringtable.c
|
||||
|
||||
-libgettextsrc_la-write-po.lo: write-po.c
|
||||
- $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libgettextsrc_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o libgettextsrc_la-write-po.lo `test -f 'write-po.c' || echo '$(srcdir)/'`write-po.c
|
||||
-
|
||||
libgettextsrc_la-msgl-ascii.lo: msgl-ascii.c
|
||||
$(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libgettextsrc_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o libgettextsrc_la-msgl-ascii.lo `test -f 'msgl-ascii.c' || echo '$(srcdir)/'`msgl-ascii.c
|
||||
|
||||
@@ -2980,6 +3004,21 @@
|
||||
.cc.lo:
|
||||
$(AM_V_CXX)$(LTCXXCOMPILE) -c -o $@ $<
|
||||
|
||||
+libgettextsrc_la-c++color.lo: ../woe32dll/c++color.cc
|
||||
+ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libgettextsrc_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libgettextsrc_la-c++color.lo `test -f '../woe32dll/c++color.cc' || echo '$(srcdir)/'`../woe32dll/c++color.cc
|
||||
+
|
||||
+libgettextsrc_la-c++write-catalog.lo: ../woe32dll/c++write-catalog.cc
|
||||
+ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libgettextsrc_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libgettextsrc_la-c++write-catalog.lo `test -f '../woe32dll/c++write-catalog.cc' || echo '$(srcdir)/'`../woe32dll/c++write-catalog.cc
|
||||
+
|
||||
+libgettextsrc_la-c++write-po.lo: ../woe32dll/c++write-po.cc
|
||||
+ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libgettextsrc_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libgettextsrc_la-c++write-po.lo `test -f '../woe32dll/c++write-po.cc' || echo '$(srcdir)/'`../woe32dll/c++write-po.cc
|
||||
+
|
||||
+libgettextsrc_la-c++write-properties.lo: ../woe32dll/c++write-properties.cc
|
||||
+ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libgettextsrc_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libgettextsrc_la-c++write-properties.lo `test -f '../woe32dll/c++write-properties.cc' || echo '$(srcdir)/'`../woe32dll/c++write-properties.cc
|
||||
+
|
||||
+libgettextsrc_la-c++write-stringtable.lo: ../woe32dll/c++write-stringtable.cc
|
||||
+ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libgettextsrc_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libgettextsrc_la-c++write-stringtable.lo `test -f '../woe32dll/c++write-stringtable.cc' || echo '$(srcdir)/'`../woe32dll/c++write-stringtable.cc
|
||||
+
|
||||
../woe32dll/libgettextsrc_la-c++format.lo: ../woe32dll/c++format.cc
|
||||
$(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libgettextsrc_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o ../woe32dll/libgettextsrc_la-c++format.lo `test -f '../woe32dll/c++format.cc' || echo '$(srcdir)/'`../woe32dll/c++format.cc
|
||||
|
||||
diff -urN a/gettext-tools/src/color.c b/gettext-tools/src/color.c
|
||||
--- a/gettext-tools/src/color.c 2012-12-10 01:59:06.000000000 +0000
|
||||
+++ b/gettext-tools/src/color.c 2013-12-12 23:49:00.401567136 +0000
|
||||
@@ -28,6 +28,7 @@
|
||||
#include <sys/types.h>
|
||||
#include <sys/stat.h>
|
||||
|
||||
+#include "ostream.h"
|
||||
#include "term-ostream.h"
|
||||
#include "xalloc.h"
|
||||
#include "relocatable.h"
|
||||
diff -urN a/gettext-tools/woe32dll/c++color.cc b/gettext-tools/woe32dll/c++color.cc
|
||||
--- a/gettext-tools/woe32dll/c++color.cc 1970-01-01 01:00:00.000000000 +0100
|
||||
+++ b/gettext-tools/woe32dll/c++color.cc 2013-12-12 23:49:00.401567136 +0000
|
||||
@@ -0,0 +1 @@
|
||||
+#include "../src/color.c"
|
||||
diff -urN a/gettext-tools/woe32dll/c++file-ostream.cc b/gettext-tools/woe32dll/c++file-ostream.cc
|
||||
--- a/gettext-tools/woe32dll/c++file-ostream.cc 1970-01-01 01:00:00.000000000 +0100
|
||||
+++ b/gettext-tools/woe32dll/c++file-ostream.cc 2013-12-12 23:49:00.401567136 +0000
|
||||
@@ -0,0 +1,2 @@
|
||||
+#include "../gnulib-lib/file-ostream.c"
|
||||
+
|
||||
diff -urN a/gettext-tools/woe32dll/c++html-ostream.cc b/gettext-tools/woe32dll/c++html-ostream.cc
|
||||
--- a/gettext-tools/woe32dll/c++html-ostream.cc 1970-01-01 01:00:00.000000000 +0100
|
||||
+++ b/gettext-tools/woe32dll/c++html-ostream.cc 2013-12-12 23:49:00.401567136 +0000
|
||||
@@ -0,0 +1 @@
|
||||
+#include "../gnulib-lib/html-ostream.c"
|
||||
diff -urN a/gettext-tools/woe32dll/c++styled-ostream.cc b/gettext-tools/woe32dll/c++styled-ostream.cc
|
||||
--- a/gettext-tools/woe32dll/c++styled-ostream.cc 1970-01-01 01:00:00.000000000 +0100
|
||||
+++ b/gettext-tools/woe32dll/c++styled-ostream.cc 2013-12-12 23:49:00.401567136 +0000
|
||||
@@ -0,0 +1 @@
|
||||
+#include "../gnulib-lib/styled-ostream.c"
|
||||
diff -urN a/gettext-tools/woe32dll/c++term-ostream.cc b/gettext-tools/woe32dll/c++term-ostream.cc
|
||||
--- a/gettext-tools/woe32dll/c++term-ostream.cc 1970-01-01 01:00:00.000000000 +0100
|
||||
+++ b/gettext-tools/woe32dll/c++term-ostream.cc 2013-12-12 23:49:00.401567136 +0000
|
||||
@@ -0,0 +1 @@
|
||||
+#include "../gnulib-lib/term-ostream.c"
|
||||
diff -urN a/gettext-tools/woe32dll/c++write-catalog.cc b/gettext-tools/woe32dll/c++write-catalog.cc
|
||||
--- a/gettext-tools/woe32dll/c++write-catalog.cc 1970-01-01 01:00:00.000000000 +0100
|
||||
+++ b/gettext-tools/woe32dll/c++write-catalog.cc 2013-12-12 23:49:00.401567136 +0000
|
||||
@@ -0,0 +1 @@
|
||||
+#include "../src/write-catalog.c"
|
||||
diff -urN a/gettext-tools/woe32dll/c++write-po.cc b/gettext-tools/woe32dll/c++write-po.cc
|
||||
--- a/gettext-tools/woe32dll/c++write-po.cc 1970-01-01 01:00:00.000000000 +0100
|
||||
+++ b/gettext-tools/woe32dll/c++write-po.cc 2013-12-12 23:49:00.401567136 +0000
|
||||
@@ -0,0 +1 @@
|
||||
+#include "../src/write-po.c"
|
||||
diff -urN a/gettext-tools/woe32dll/c++write-properties.cc b/gettext-tools/woe32dll/c++write-properties.cc
|
||||
--- a/gettext-tools/woe32dll/c++write-properties.cc 1970-01-01 01:00:00.000000000 +0100
|
||||
+++ b/gettext-tools/woe32dll/c++write-properties.cc 2013-12-12 23:49:00.401567136 +0000
|
||||
@@ -0,0 +1 @@
|
||||
+#include "../src/write-properties.c"
|
||||
diff -urN a/gettext-tools/woe32dll/c++write-stringtable.cc b/gettext-tools/woe32dll/c++write-stringtable.cc
|
||||
--- a/gettext-tools/woe32dll/c++write-stringtable.cc 1970-01-01 01:00:00.000000000 +0100
|
||||
+++ b/gettext-tools/woe32dll/c++write-stringtable.cc 2013-12-12 23:49:00.401567136 +0000
|
||||
@@ -0,0 +1 @@
|
||||
+#include "../src/write-stringtable.c"
|
||||
diff -urN a/gnulib-local/modules/file-ostream b/gnulib-local/modules/file-ostream
|
||||
--- a/gnulib-local/modules/file-ostream 2012-12-10 01:59:06.000000000 +0000
|
||||
+++ b/gnulib-local/modules/file-ostream 2013-12-12 23:49:00.401567136 +0000
|
||||
@@ -12,7 +12,11 @@
|
||||
configure.ac:
|
||||
|
||||
Makefile.am:
|
||||
+if !WOE32DLL
|
||||
lib_SOURCES += file-ostream.c
|
||||
+else
|
||||
+lib_SOURCES += ../woe32dll/c++file-ostream.cc
|
||||
+endif
|
||||
# This is a Makefile rule that generates multiple files at once; see the
|
||||
# automake documentation, node "Multiple Outputs", for details.
|
||||
file-ostream.h : $(top_srcdir)/build-aux/moopp file-ostream.oo.h file-ostream.oo.c ostream.oo.h
|
||||
diff -urN a/gnulib-local/modules/html-ostream b/gnulib-local/modules/html-ostream
|
||||
--- a/gnulib-local/modules/html-ostream 2012-12-10 01:59:06.000000000 +0000
|
||||
+++ b/gnulib-local/modules/html-ostream 2013-12-12 23:49:00.401567136 +0000
|
||||
@@ -15,7 +15,11 @@
|
||||
configure.ac:
|
||||
|
||||
Makefile.am:
|
||||
+if !WOE32DLL
|
||||
lib_SOURCES += html-ostream.c
|
||||
+else
|
||||
+lib_SOURCES += ../woe32dll/c++html-ostream.cc
|
||||
+endif
|
||||
# This is a Makefile rule that generates multiple files at once; see the
|
||||
# automake documentation, node "Multiple Outputs", for details.
|
||||
html-ostream.h : $(top_srcdir)/build-aux/moopp html-ostream.oo.h html-ostream.oo.c ostream.oo.h
|
||||
diff -urN a/gnulib-local/modules/ostream b/gnulib-local/modules/ostream
|
||||
--- a/gnulib-local/modules/ostream 2012-12-10 01:59:06.000000000 +0000
|
||||
+++ b/gnulib-local/modules/ostream 2013-12-12 23:49:00.401567136 +0000
|
||||
@@ -11,7 +11,11 @@
|
||||
configure.ac:
|
||||
|
||||
Makefile.am:
|
||||
+if !WOE32DLL
|
||||
lib_SOURCES += ostream.c
|
||||
+else
|
||||
+lib_SOURCES += ../woe32dll/c++ostream.cc
|
||||
+endif
|
||||
# This is a Makefile rule that generates multiple files at once; see the
|
||||
# automake documentation, node "Multiple Outputs", for details.
|
||||
ostream.h : $(top_srcdir)/build-aux/moopp ostream.oo.h ostream.oo.c
|
||||
diff -urN a/gnulib-local/modules/styled-ostream b/gnulib-local/modules/styled-ostream
|
||||
--- a/gnulib-local/modules/styled-ostream 2012-12-10 01:59:06.000000000 +0000
|
||||
+++ b/gnulib-local/modules/styled-ostream 2013-12-12 23:49:00.401567136 +0000
|
||||
@@ -11,7 +11,11 @@
|
||||
configure.ac:
|
||||
|
||||
Makefile.am:
|
||||
+if !WOE32DLL
|
||||
lib_SOURCES += styled-ostream.c
|
||||
+else
|
||||
+lib_SOURCES += ../woe32dll/c++styled-ostream.cc
|
||||
+endif
|
||||
# This is a Makefile rule that generates multiple files at once; see the
|
||||
# automake documentation, node "Multiple Outputs", for details.
|
||||
styled-ostream.h : $(top_srcdir)/build-aux/moopp styled-ostream.oo.h styled-ostream.oo.c ostream.oo.h
|
||||
diff -urN a/gnulib-local/modules/term-ostream b/gnulib-local/modules/term-ostream
|
||||
--- a/gnulib-local/modules/term-ostream 2012-12-10 01:59:06.000000000 +0000
|
||||
+++ b/gnulib-local/modules/term-ostream 2013-12-12 23:49:00.401567136 +0000
|
||||
@@ -22,7 +22,11 @@
|
||||
gl_TERM_OSTREAM
|
||||
|
||||
Makefile.am:
|
||||
+if !WOE32DLL
|
||||
lib_SOURCES += term-ostream.c
|
||||
+else
|
||||
+lib_SOURCES += ../woe32dll/c++term-ostream.cc
|
||||
+endif
|
||||
# This is a Makefile rule that generates multiple files at once; see the
|
||||
# automake documentation, node "Multiple Outputs", for details.
|
||||
term-ostream.h : $(top_srcdir)/build-aux/moopp term-ostream.oo.h term-ostream.oo.c ostream.oo.h
|
||||
@@ -1,37 +0,0 @@
|
||||
From c9b8cf86ba8a24f1e0a45de53a295166672cf219 Mon Sep 17 00:00:00 2001
|
||||
From: Johannes Schindelin <johannes.schindelin@gmx.de>
|
||||
Date: Thu, 10 Sep 2015 13:09:15 +0200
|
||||
Subject: [PATCH] Prevent absolute DOS path from being hard-coded
|
||||
|
||||
When passing absolute POSIX-style paths to the MinGW compiler, they are
|
||||
mangled into Windows-style paths, including the DOS drive, making the
|
||||
paths highly specific to the developer who happened to build the package.
|
||||
|
||||
This is obviously not what we want, so prefix the absolute POSIX path with
|
||||
a space to convince the MSys2 runtime *not* to mangle the aliaspath.
|
||||
|
||||
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
|
||||
---
|
||||
gettext-runtime/intl/Makefile.in | 6 +++---
|
||||
1 file changed, 3 insertions(+), 3 deletions(-)
|
||||
|
||||
diff --git a/gettext-runtime/intl/Makefile.in b/gettext-runtime/intl/Makefile.in
|
||||
index 49751a2..b801220 100644
|
||||
--- a/gettext-runtime/intl/Makefile.in
|
||||
+++ b/gettext-runtime/intl/Makefile.in
|
||||
@@ -98,9 +98,9 @@ am__v_lt_0 = --silent
|
||||
|
||||
# -DBUILDING_LIBINTL: Change expansion of LIBINTL_DLL_EXPORTED macro.
|
||||
# -DBUILDING_DLL: Change expansion of RELOCATABLE_DLL_EXPORTED macro.
|
||||
-DEFS = -DLOCALEDIR=\"$(localedir)\" -DLOCALE_ALIAS_PATH=\"$(aliaspath)\" \
|
||||
--DLIBDIR=\"$(libdir)\" -DBUILDING_LIBINTL -DBUILDING_DLL -DIN_LIBINTL \
|
||||
--DENABLE_RELOCATABLE=1 -DIN_LIBRARY -DINSTALLDIR=\"$(libdir)\" -DNO_XMALLOC \
|
||||
+DEFS = -DLOCALEDIR=\ \"$(localedir)\" -DLOCALE_ALIAS_PATH=\ \"$(aliaspath)\" \
|
||||
+-DLIBDIR=\ \"$(libdir)\" -DBUILDING_LIBINTL -DBUILDING_DLL -DIN_LIBINTL \
|
||||
+-DENABLE_RELOCATABLE=1 -DIN_LIBRARY -DINSTALLDIR=\ \"$(libdir)\" -DNO_XMALLOC \
|
||||
-Dset_relocation_prefix=libintl_set_relocation_prefix \
|
||||
-Drelocate=libintl_relocate \
|
||||
-DDEPENDS_ON_LIBICONV=1 @DEFS@
|
||||
--
|
||||
2.5.1+unc.5.gc15a74e.dirty
|
||||
|
||||
@@ -1,54 +0,0 @@
|
||||
From 89170435bde2d889dee8b20c74d7771e6af8f19e Mon Sep 17 00:00:00 2001
|
||||
From: Tim S <stahta01@users.sourceforge.net>
|
||||
Date: Sun, 16 Sep 2018 10:35:04 -0400
|
||||
Subject: [PATCH] Use LF as newline in envsubst
|
||||
|
||||
Now using underline prefix in functions as stated at:
|
||||
https://docs.microsoft.com/en-us/cpp/c-runtime-library/reference/setmode
|
||||
And, change mode back to prior mode
|
||||
|
||||
---
|
||||
gettext-runtime/src/envsubst.c | 18 ++++++++++++++++++
|
||||
1 file changed, 18 insertions(+)
|
||||
|
||||
diff --git a/gettext-runtime/src/envsubst.c b/gettext-runtime/src/envsubst.c
|
||||
index 941452b03..2afceb9ac 100644
|
||||
--- a/gettext-runtime/src/envsubst.c
|
||||
+++ b/gettext-runtime/src/envsubst.c
|
||||
@@ -27,6 +27,11 @@
|
||||
#include <string.h>
|
||||
#include <locale.h>
|
||||
|
||||
+#ifdef _WIN32
|
||||
+# include <io.h> /* for _setmode() */
|
||||
+# include <fcntl.h>
|
||||
+#endif
|
||||
+
|
||||
#include "closeout.h"
|
||||
#include "error.h"
|
||||
#include "progname.h"
|
||||
@@ -281,8 +286,21 @@ find_variables (const char *string,
|
||||
static void
|
||||
print_variable (const char *var_ptr, size_t var_len)
|
||||
{
|
||||
+ int oldmode;
|
||||
+
|
||||
fwrite (var_ptr, var_len, 1, stdout);
|
||||
+#if defined(_WIN32)
|
||||
+ /* Change to binary mode */
|
||||
+ oldmode = _setmode( _fileno( stdout ), _O_BINARY );
|
||||
+#endif
|
||||
putchar ('\n');
|
||||
+#if defined(_WIN32)
|
||||
+ fflush(stdout); /* Must flush before changing mode back */
|
||||
+ if ( oldmode != -1 )
|
||||
+ { /* Return to prior mode */
|
||||
+ _setmode( _fileno( stdout ), oldmode );
|
||||
+ }
|
||||
+#endif
|
||||
}
|
||||
|
||||
/* Print the variables contained in STRING to stdout, each one followed by a
|
||||
--
|
||||
2.19.0.windows.1
|
||||
|
||||
@@ -1,12 +0,0 @@
|
||||
for relocate()
|
||||
--- gettext-0.19.8.1/gettext-tools/gnulib-lib/Makefile.am.orig 2019-05-11 22:20:53.069987300 +0200
|
||||
+++ gettext-0.19.8.1/gettext-tools/gnulib-lib/Makefile.am 2019-05-11 22:21:54.510209600 +0200
|
||||
@@ -48,6 +48,8 @@
|
||||
# Parametrization of the 'relocatable' module.
|
||||
AM_CPPFLAGS += -DDEPENDS_ON_LIBICONV=1 -DDEPENDS_ON_LIBINTL=1
|
||||
|
||||
+AM_CPPFLAGS += -DINSTALLDIR=\"$(bindir)\"
|
||||
+
|
||||
# Parametrization of the 'libxml' module:
|
||||
# When building a shared library, don't export the variables
|
||||
# xmlMalloc, xmlMallocAtomic, xmlRealloc, xmlFree, xmlMemStrdup.
|
||||
@@ -4,88 +4,83 @@
|
||||
_realname=gettext
|
||||
pkgbase=mingw-w64-${_realname}
|
||||
pkgname="${MINGW_PACKAGE_PREFIX}-${_realname}"
|
||||
pkgver=0.19.8.1
|
||||
pkgrel=10
|
||||
pkgver=0.21
|
||||
pkgrel=1
|
||||
arch=('any')
|
||||
mingw_arch=('mingw32' 'mingw64' 'ucrt64' 'clang64' 'clang32' 'clangarm64')
|
||||
url="https://www.gnu.org/software/gettext/"
|
||||
pkgdesc="GNU internationalization library (mingw-w64)"
|
||||
# GPL3 for the package as a whole and LGPL for some parts, see the license files
|
||||
license=(GPL3 partial:'LGPL2.1')
|
||||
depends=("${MINGW_PACKAGE_PREFIX}-expat"
|
||||
"${MINGW_PACKAGE_PREFIX}-gcc-libs"
|
||||
"${MINGW_PACKAGE_PREFIX}-libiconv"
|
||||
#"${MINGW_PACKAGE_PREFIX}-termcap"
|
||||
)
|
||||
makedepends=("${MINGW_PACKAGE_PREFIX}-gcc" "${MINGW_PACKAGE_PREFIX}-ncurses" "git" "${MINGW_PACKAGE_PREFIX}-autotools")
|
||||
makedepends=("${MINGW_PACKAGE_PREFIX}-ncurses"
|
||||
"${MINGW_PACKAGE_PREFIX}-autotools")
|
||||
options=('strip' 'staticlibs')
|
||||
|
||||
# GPL3 for the package as a whole and LGPL for some parts, see the license files
|
||||
license=(GPL3 partial:'LGPL2.1')
|
||||
|
||||
url="https://www.gnu.org/software/gettext/"
|
||||
source=("https://ftp.gnu.org/pub/gnu/${_realname}/${_realname}-${pkgver}.tar.gz"
|
||||
00-relocatex-libintl-0.18.3.1.patch
|
||||
120-Fix-Woe32-link-errors-when-compiling-with-O0.patch
|
||||
04-mingw-script-slash-fix.mingw.patch
|
||||
05-always-use-libintl-vsnprintf.mingw.patch
|
||||
06-dont-include-ctype-after-gnulibs-wctype.mingw.patch
|
||||
07-fix-asprintf-conflict.mingw.patch
|
||||
08-vs-compatible.patch
|
||||
09-asm-underscore-mingw.patch
|
||||
121-keep-posix-path.patch
|
||||
122-Use-LF-as-newline-in-envsubst.patch
|
||||
200-tools-gnulib-define-installdir.patch)
|
||||
sha256sums=('ff942af0e438ced4a8b0ea4b0b6e0d6d657157c5e2364de57baa279c1c125c43'
|
||||
'030987c317279c27eea503ef257c7c3cf4ff947de8ea71d84fdf5eea802ee587'
|
||||
'8f51c320c104c94e1ab3c8630905185214ca0c7ecf5423f20001c8694ead454c'
|
||||
'bebc791443a739f91ace5bca1dba3d45d50dff92706fae7629d150e197d2f411'
|
||||
'51604823755d1ae669544bb9730c5a09b78b0f1b1978577c8604fbd6cafc073e'
|
||||
'25aee9534c45772370ef5ca495da0d6a9f4d73e7a53d6ba91314883c6f3bb695'
|
||||
'3b85e4d0b771b47a168c629a65463f5b87a5d5627b5f05000a45c3d2df96b66d'
|
||||
'522715ac22936943a85b4b78274302a6058f4f5371439cf491193ed53d8fc729'
|
||||
'2ffc73f1b8d66d88ff5ce640be211e5a927daba13788cb2319b97fc885444eac'
|
||||
'051bf975687a92da8a5acc09a367632396570c2609c5ecc1eba06c60c7135ad6'
|
||||
'2abfa598e1586abe14e982b867c8981790d8114e1ee575cb08b7ed49d4a46c74'
|
||||
'71eb3554cbf37a8c866722e39c6102c3ae3a215b82e153000f61f2e80d3bfd1b')
|
||||
0001-libtool-hide-using-cross-tools-not-prefixed-with-hos.patch
|
||||
0002-libtool-hide-library-was-moved.patch
|
||||
0003-libtool-hide-Could-not-determine-host-file-name.patch
|
||||
0004-libtool-hide-seems-to-be-moved.patch
|
||||
0005-Fix-compilation-of-pthread_sigmask.c.patch
|
||||
0006-libtool-hide-remember-to-run.patch
|
||||
0007-libtool-hide-has-not-been-installed-in.patch
|
||||
0008-Force-redirected-output-s-encoding.patch
|
||||
0009-Typo-func__fatal_error-should-be-func_fatal_error.patch
|
||||
0010-build-Fix-build-failure-on-mingw-formatstring_ruby.patch
|
||||
0011-fix-interference-between-libintl-boost-header-files.patch)
|
||||
sha256sums=('c77d0da3102aec9c07f43671e60611ebff89a996ef159497ce8e59d075786b12'
|
||||
'cf88da22e06683433aec46fb799f526a2a760ba088d7180c74bed2f5dc5c03b7'
|
||||
'33cc3ec86a0c8eef7769e816f42364e9ee43e4e31d59bdfe05889df2d0ef5852'
|
||||
'f752abb114446ff0c9ad5990433614ac6e936597a4660d4cfc3371c5d8fe3032'
|
||||
'db1f29cd8917ac0c0af41be3092488fee7d58cb693775b7cba8d18b416b0f6f1'
|
||||
'cbc2f533012d646521afa20f8b256917fce040741ff42cf53fb6dd7123a6670a'
|
||||
'4931cfccb2d458d1de9e26eadfc98f129f3c3a148a852123215de9cef9d439a5'
|
||||
'da1b9e85c368ba01af3412a5a9a9c7e8a66f60b01643b7789e938b1e5c74e636'
|
||||
'e75be4d84ce54cd9dc0d2ff738d7e9c77856a593f777fece9dcdd29ab8812b6b'
|
||||
'dcafa97dff683e075a9779f1a0a0d684a4a755343f711b11f7096de7f635ba19'
|
||||
'c4a85dc6d781d29bdcdc557d8867408f2181d871338f6a1c4b9e6fcd78dc3e7f'
|
||||
'41201d74f5f352c4fe219316340521fc3f9a0f3a7c572a3ddd3b8df33d4dab9a')
|
||||
validpgpkeys=('462225C3B46F34879FC8496CD605848ED7E69871') #Daiki Ueno
|
||||
|
||||
# Helper macros to help make tasks easier #
|
||||
apply_patch_with_msg() {
|
||||
for _patch in "$@"
|
||||
do
|
||||
msg2 "Applying ${_patch}"
|
||||
patch -Nbp1 -i "${srcdir}/${_patch}"
|
||||
done
|
||||
}
|
||||
|
||||
prepare() {
|
||||
cd "${srcdir}/${_realname}-${pkgver}"
|
||||
rm -rf gettext-runtime/intl/canonicalize.c \
|
||||
gettext-runtime/intl/canonicalize.h \
|
||||
gettext-runtime/intl/relocatex.c \
|
||||
gettext-runtime/intl/relocatex.h \
|
||||
gettext-tools/woe32dll/c++color.cc \
|
||||
gettext-tools/woe32dll/c++file-ostream.cc \
|
||||
gettext-tools/woe32dll/c++html-ostream.cc \
|
||||
gettext-tools/woe32dll/c++styled-ostream.cc \
|
||||
gettext-tools/woe32dll/c++term-ostream.cc \
|
||||
gettext-tools/woe32dll/c++write-catalog.cc \
|
||||
gettext-tools/woe32dll/c++write-po.cc \
|
||||
gettext-tools/woe32dll/c++write-properties.cc \
|
||||
gettext-tools/woe32dll/c++write-stringtable.cc \
|
||||
MINGW-PATCHES/README-relocatex-libintl.txt || true
|
||||
|
||||
patch -p1 -i ${srcdir}/00-relocatex-libintl-0.18.3.1.patch
|
||||
patch -p0 -i ${srcdir}/04-mingw-script-slash-fix.mingw.patch
|
||||
patch -p0 -i ${srcdir}/05-always-use-libintl-vsnprintf.mingw.patch
|
||||
patch -p0 -i ${srcdir}/06-dont-include-ctype-after-gnulibs-wctype.mingw.patch
|
||||
patch -p0 -i ${srcdir}/07-fix-asprintf-conflict.mingw.patch
|
||||
patch -p0 -i ${srcdir}/08-vs-compatible.patch
|
||||
patch -p1 -i ${srcdir}/09-asm-underscore-mingw.patch
|
||||
patch -p1 -i ${srcdir}/120-Fix-Woe32-link-errors-when-compiling-with-O0.patch
|
||||
#patch -p1 -i ${srcdir}/121-keep-posix-path.patch
|
||||
patch -p1 -i ${srcdir}/122-Use-LF-as-newline-in-envsubst.patch
|
||||
patch -p1 -i ${srcdir}/200-tools-gnulib-define-installdir.patch
|
||||
apply_patch_with_msg \
|
||||
0001-libtool-hide-using-cross-tools-not-prefixed-with-hos.patch \
|
||||
0002-libtool-hide-library-was-moved.patch \
|
||||
0003-libtool-hide-Could-not-determine-host-file-name.patch \
|
||||
0004-libtool-hide-seems-to-be-moved.patch \
|
||||
0005-Fix-compilation-of-pthread_sigmask.c.patch \
|
||||
0006-libtool-hide-remember-to-run.patch \
|
||||
0007-libtool-hide-has-not-been-installed-in.patch \
|
||||
0008-Force-redirected-output-s-encoding.patch \
|
||||
0009-Typo-func__fatal_error-should-be-func_fatal_error.patch \
|
||||
0010-build-Fix-build-failure-on-mingw-formatstring_ruby.patch \
|
||||
0011-fix-interference-between-libintl-boost-header-files.patch
|
||||
|
||||
libtoolize --automake --copy --force
|
||||
WANT_AUTOMAKE=latest ./autogen.sh --skip-gnulib
|
||||
}
|
||||
|
||||
build() {
|
||||
export lt_cv_deplibs_check_method='pass_all'
|
||||
[[ -d ${srcdir}/build-${MSYSTEM} ]] && rm -rf ${srcdir}/build-${MSYSTEM}
|
||||
mkdir -p ${srcdir}/build-${MSYSTEM} && cd ${srcdir}/build-${MSYSTEM}
|
||||
|
||||
export lt_cv_deplibs_check_method='pass_all'
|
||||
export MSYS2_ARG_CONV_EXCL="-DLOCALEDIR=;-DLIBDIR=;-DLOCALE_ALIAS_PATH="
|
||||
[[ -d ${srcdir}/build-${MINGW_CHOST} ]] && rm -rf ${srcdir}/build-${MINGW_CHOST}
|
||||
mkdir -p ${srcdir}/build-${MINGW_CHOST} && cd ${srcdir}/build-${MINGW_CHOST}
|
||||
|
||||
../${_realname}-${pkgver}/configure \
|
||||
--prefix=${MINGW_PREFIX} \
|
||||
@@ -112,11 +107,11 @@ build() {
|
||||
# to make relocate() in gnulib-lib work
|
||||
sed -s "s|${MINGW_PREFIX}|$(cygpath -m ${MINGW_PREFIX})|g" -i gettext-tools/config.h
|
||||
|
||||
make V=1
|
||||
make
|
||||
}
|
||||
|
||||
package() {
|
||||
cd ${srcdir}/build-${MINGW_CHOST}
|
||||
cd ${srcdir}/build-${MSYSTEM}
|
||||
make DESTDIR="${pkgdir}" install
|
||||
|
||||
# Licenses
|
||||
@@ -128,5 +123,4 @@ package() {
|
||||
install -Dm644 "${srcdir}/${_realname}-${pkgver}/gettext-tools/COPYING" "${pkgdir}${MINGW_PREFIX}/share/licenses/${_realname}/gettext-tools/COPYING"
|
||||
install -Dm644 "${srcdir}/${_realname}-${pkgver}/gettext-tools/gnulib-lib/libxml/COPYING" "${pkgdir}${MINGW_PREFIX}/share/licenses/${_realname}/gettext-tools/gnulib-lib/libxml/COPYING"
|
||||
install -Dm644 "${srcdir}/${_realname}-${pkgver}/gnulib-local/lib/libxml/COPYING" "${pkgdir}${MINGW_PREFIX}/share/licenses/${_realname}/gnulib-local/lib/libxml/COPYING"
|
||||
rm "${pkgdir}${MINGW_PREFIX}/share/${_realname}/intl/COPYING.LIB"
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user