]> git.ipfire.org Git - thirdparty/gettext.git/commitdiff
Improved Cygwin support.
authorBruno Haible <bruno@clisp.org>
Wed, 28 Apr 2004 11:13:59 +0000 (11:13 +0000)
committerBruno Haible <bruno@clisp.org>
Tue, 23 Jun 2009 10:11:51 +0000 (12:11 +0200)
gettext-tools/lib/ChangeLog
gettext-tools/lib/basename.c
gettext-tools/lib/findprog.c
gettext-tools/lib/localcharset.c
gettext-tools/lib/pathname.h
gettext-tools/lib/progreloc.c
gettext-tools/lib/relocatable.c

index dc70e484783f790f5660eb2955e636ee13ce8791..48604df7477e5bd804663f88e65bbcb29f00a5d1 100644 (file)
@@ -1,3 +1,20 @@
+2004-04-28  Bruno Haible  <bruno@clisp.org>
+
+       * basename.c (FILESYSTEM_PREFIX_LEN, ISSLASH): Treat Cygwin like
+       Windows, since it now accepts Windows pathnames.
+       * findprog.c (find_in_path): Treat Cygwin like Windows, since it also
+       implicitly appends .exe to executables.
+       * localcharset.c (ISSLASH): Treat Cygwin like Windows, since it now
+       accepts Windows pathnames.
+       * pathname.h (ISSLASH, IS_PATH_WITH_DIR, FILESYSTEM_PREFIX_LEN): Treat
+       Cygwin like Windows, since it now accepts Windows pathnames.
+       * relocatable.c (ISSLASH, IS_PATH_WITH_DIR, FILESYSTEM_PREFIX_LEN):
+       Treat Cygwin like Windows, since it now accepts Windows pathnames.
+       (compute_curr_prefix): Likewise.
+       * progreloc.c (ISSLASH, IS_PATH_WITH_DIR, FILESYSTEM_PREFIX_LEN): Treat
+       Cygwin like Windows, since it now accepts Windows pathnames.
+       Reported by Derek Robert Price <derek@ximbiot.com>.
+
 2004-04-23  Bruno Haible  <bruno@clisp.org>
 
        * localcharset.c (get_charset_aliases): Allow the CHARSETALIASDIR
index 5c589412281945c9fd476562628b862372479828..d993347383ab0c81eb823b746fd027b2a80fabff 100644 (file)
@@ -1,5 +1,5 @@
 /* Return the name-within-directory of a file name.
-   Copyright (C) 1996-1999, 2000-2002 Free Software Foundation, Inc.
+   Copyright (C) 1996-1999, 2000-2002, 2004 Free Software Foundation, Inc.
 
    NOTE: The canonical source of this file is maintained with the GNU C Library.
    Bugs can be reported to bug-glibc@gnu.org.
@@ -31,8 +31,8 @@
 #include <stdio.h>
 #include <assert.h>
 
-#if defined _WIN32 || defined __WIN32__ || defined __EMX__ || defined __DJGPP__
-  /* Win32, OS/2, DOS */
+#if defined _WIN32 || defined __WIN32__ || defined __CYGWIN__ || defined __EMX__ || defined __DJGPP__
+  /* Win32, Cygwin, OS/2, DOS */
 # define HAS_DEVICE(P) \
     ((((P)[0] >= 'A' && (P)[0] <= 'Z') || ((P)[0] >= 'a' && (P)[0] <= 'z')) \
      && (P)[1] == ':')
index 48c3edf6c5c9227d50e71b72964bff16880b291b..469acfd2e4d182fa0708b89af0cfb4ca1010f48e 100644 (file)
@@ -1,5 +1,5 @@
 /* Locating a program in PATH.
-   Copyright (C) 2001-2003 Free Software Foundation, Inc.
+   Copyright (C) 2001-2004 Free Software Foundation, Inc.
    Written by Bruno Haible <haible@clisp.cons.org>, 2001.
 
    This program is free software; you can redistribute it and/or modify
@@ -39,8 +39,8 @@
 const char *
 find_in_path (const char *progname)
 {
-#if defined _WIN32 || defined __WIN32__ || defined __EMX__ || defined __DJGPP__
-  /* Win32, OS/2, DOS */
+#if defined _WIN32 || defined __WIN32__ || defined __CYGWIN__ || defined __EMX__ || defined __DJGPP__
+  /* Win32, Cygwin, OS/2, DOS */
   /* The searching rules with .COM, .EXE, .BAT, .CMD etc. suffixes are
      too complicated.  Leave it to the OS.  */
   return progname;
index 990420ba454ad2beebba708e271430f25c232a93..a3e52ef37b89c142bb8d1636f37f28cf2b935070 100644 (file)
@@ -73,8 +73,8 @@
 # define relocate(pathname) (pathname)
 #endif
 
-#if defined _WIN32 || defined __WIN32__ || defined __EMX__ || defined __DJGPP__
-  /* Win32, OS/2, DOS */
+#if defined _WIN32 || defined __WIN32__ || defined __CYGWIN__ || defined __EMX__ || defined __DJGPP__
+  /* Win32, Cygwin, OS/2, DOS */
 # define ISSLASH(C) ((C) == '/' || (C) == '\\')
 #endif
 
index bac881798a9b520ece206f14deccffe67b9ea6a3..1bce49bf7a3faa7af438eaf6b17191170b187dd8 100644 (file)
@@ -1,5 +1,5 @@
 /* Pathname support.
-   Copyright (C) 2001-2003 Free Software Foundation, Inc.
+   Copyright (C) 2001-2004 Free Software Foundation, Inc.
 
    This program is free software; you can redistribute it and/or modify
    it under the terms of the GNU General Public License as published by
@@ -29,8 +29,8 @@ extern "C" {
                         it may be concatenated to a directory pathname.
    IS_PATH_WITH_DIR(P)  tests whether P contains a directory specification.
  */
-#if defined _WIN32 || defined __WIN32__ || defined __EMX__ || defined __DJGPP__
-  /* Win32, OS/2, DOS */
+#if defined _WIN32 || defined __WIN32__ || defined __CYGWIN__ || defined __EMX__ || defined __DJGPP__
+  /* Win32, Cygwin, OS/2, DOS */
 # define ISSLASH(C) ((C) == '/' || (C) == '\\')
 # define HAS_DEVICE(P) \
     ((((P)[0] >= 'A' && (P)[0] <= 'Z') || ((P)[0] >= 'a' && (P)[0] <= 'z')) \
index 35547498003ce5c681de6a575f648016de7e39c3..21a2c810c13120605d86cec7480a445d276b2e33 100644 (file)
@@ -60,8 +60,8 @@
    ISSLASH(C)           tests whether C is a directory separator character.
    IS_PATH_WITH_DIR(P)  tests whether P contains a directory specification.
  */
-#if defined _WIN32 || defined __WIN32__ || defined __EMX__ || defined __DJGPP__
-  /* Win32, OS/2, DOS */
+#if defined _WIN32 || defined __WIN32__ || defined __CYGWIN__ || defined __EMX__ || defined __DJGPP__
+  /* Win32, Cygwin, OS/2, DOS */
 # define ISSLASH(C) ((C) == '/' || (C) == '\\')
 # define HAS_DEVICE(P) \
     ((((P)[0] >= 'A' && (P)[0] <= 'Z') || ((P)[0] >= 'a' && (P)[0] <= 'z')) \
index bf7c7085485d1b086d9b81810bb34880b07a75b5..c14b53f97d5bd97816fce921f72ccec8a79f50e0 100644 (file)
@@ -1,5 +1,5 @@
 /* Provide relocatable packages.
-   Copyright (C) 2003 Free Software Foundation, Inc.
+   Copyright (C) 2003-2004 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
@@ -72,8 +72,8 @@
    ISSLASH(C)           tests whether C is a directory separator character.
    IS_PATH_WITH_DIR(P)  tests whether P contains a directory specification.
  */
-#if defined _WIN32 || defined __WIN32__ || defined __EMX__ || defined __DJGPP__
-  /* Win32, OS/2, DOS */
+#if defined _WIN32 || defined __WIN32__ || defined __CYGWIN__ || defined __EMX__ || defined __DJGPP__
+  /* Win32, Cygwin, OS/2, DOS */
 # define ISSLASH(C) ((C) == '/' || (C) == '\\')
 # define HAS_DEVICE(P) \
     ((((P)[0] >= 'A' && (P)[0] <= 'Z') || ((P)[0] >= 'a' && (P)[0] <= 'z')) \
@@ -234,8 +234,8 @@ compute_curr_prefix (const char *orig_installprefix,
                  same = true;
                break;
              }
-#if defined _WIN32 || defined __WIN32__ || defined __EMX__ || defined __DJGPP__
-           /* Win32, OS/2, DOS - case insignificant filesystem */
+#if defined _WIN32 || defined __WIN32__ || defined __CYGWIN__ || defined __EMX__ || defined __DJGPP__
+           /* Win32, Cygwin, OS/2, DOS - case insignificant filesystem */
            if ((*rpi >= 'a' && *rpi <= 'z' ? *rpi - 'a' + 'A' : *rpi)
                != (*cpi >= 'a' && *cpi <= 'z' ? *cpi - 'a' + 'A' : *cpi))
              break;