]> git.eshelyaron.com Git - emacs.git/commitdiff
Move definitions of directory and device separators to configure
authorGlenn Morris <rgm@gnu.org>
Wed, 1 Aug 2012 01:43:08 +0000 (21:43 -0400)
committerGlenn Morris <rgm@gnu.org>
Wed, 1 Aug 2012 01:43:08 +0000 (21:43 -0400)
* configure.ac (DEVICE_SEP, IS_DEVICE_SEP, IS_DIRECTORY_SEP, IS_ANY_SEP):
Move here from src/lisp.h.

* src/lisp.h (IS_DIRECTORY_SEP, IS_DEVICE_SEP, IS_ANY_SEP):
Move to configure.ac.

ChangeLog
configure.ac
src/ChangeLog
src/lisp.h

index 6c74a79f5cdaf616b88030f5394e4cba6d197360..fea0e72a9df66d9003e51d5d4b015f3820538f3c 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2012-08-01  Glenn Morris  <rgm@gnu.org>
+
+       * configure.ac (DEVICE_SEP, IS_DEVICE_SEP, IS_DIRECTORY_SEP)
+       (IS_ANY_SEP): Move here from src/lisp.h.
+
 2012-08-01  Juanma Barranquero  <lekktu@gmail.com>
 
        * lib/makefile.w32-in (CONFIG_H): Update dependencies.
index cf4e0540d2fdf8354dfd25ca93e95f5ea0e8a4eb..27aba36e744344642a16f9e2b9863165315deab1 100644 (file)
@@ -3158,6 +3158,20 @@ AC_DEFINE(subprocesses, 1, [Define to enable asynchronous subprocesses.])
 AC_DEFINE(USER_FULL_NAME, [pw->pw_gecos], [How to get a user's full name.])
 
 
+dnl Only used on MS platforms.
+AH_TEMPLATE(DEVICE_SEP, [Character that separates a device in a file name.])
+
+AC_DEFINE(IS_DEVICE_SEP(_c_), 0,
+  [Returns true if character is a device separator.])
+
+AC_DEFINE(IS_DIRECTORY_SEP(_c_), [((_c_) == DIRECTORY_SEP)],
+  [Returns true if character is a directory separator.])
+
+dnl On MS, this also accepts IS_DEVICE_SEP.
+AC_DEFINE(IS_ANY_SEP(_c_), [(IS_DIRECTORY_SEP (_c_))],
+  [Returns true if character is any form of separator.])
+
+
 AH_TEMPLATE(NO_EDITRES, [Define if XEditRes should not be used.])
 
 case $opsys in
index bf172320eed00c7322064e86bdd325974be73911..c810675c4a46969663159d03ae542259e347bbce 100644 (file)
@@ -1,3 +1,8 @@
+2012-08-01  Glenn Morris  <rgm@gnu.org>
+
+       * lisp.h (IS_DIRECTORY_SEP, IS_DEVICE_SEP, IS_ANY_SEP):
+       Move to configure.ac.
+
 2012-08-01  Juanma Barranquero  <lekktu@gmail.com>
 
        * makefile.w32-in (CONFIG_H): Update dependencies.
index 147a4781937f0cccbb78d1b7e81447dbceb56f91..55f8677f9a55008f274fb5d4a0f5c05dfc3bae9b 100644 (file)
@@ -3305,24 +3305,7 @@ extern char *egetenv (const char *);
 /* Set up the name of the machine we're running on.  */
 extern void init_system_name (void);
 
-/* Some systems (e.g., NT) use a different path separator than Unix,
-   in addition to a device separator.  Set the path separator
-   to '/', and don't test for a device separator in IS_ANY_SEP.  */
-
 static char const DIRECTORY_SEP = '/';
-#ifndef IS_DIRECTORY_SEP
-#define IS_DIRECTORY_SEP(_c_) ((_c_) == DIRECTORY_SEP)
-#endif
-#ifndef IS_DEVICE_SEP
-#ifndef DEVICE_SEP
-#define IS_DEVICE_SEP(_c_) 0
-#else
-#define IS_DEVICE_SEP(_c_) ((_c_) == DEVICE_SEP)
-#endif
-#endif
-#ifndef IS_ANY_SEP
-#define IS_ANY_SEP(_c_) (IS_DIRECTORY_SEP (_c_))
-#endif
 
 /* Use this to suppress gcc's warnings.  */
 #ifdef lint