home *** CD-ROM | disk | FTP | other *** search
/ Geek Gadgets 1 / ADE-1.bin / ade-dist / octave-1.1.1p1-base.tgz / octave-1.1.1p1-base.tar / fsf / octave / kpathsea / c-pathch.h < prev    next >
C/C++ Source or Header  |  1993-05-25  |  2KB  |  77 lines

  1. /* c-pathch.h: define the characters which separate components of
  2.    filenames and environment variable paths.
  3.  
  4. Copyright (C) 1992, 93 Free Software Foundation, Inc.
  5.  
  6. This program is free software; you can redistribute it and/or modify
  7. it under the terms of the GNU General Public License as published by
  8. the Free Software Foundation; either version 2, or (at your option)
  9. any later version.
  10.  
  11. This program is distributed in the hope that it will be useful,
  12. but WITHOUT ANY WARRANTY; without even the implied warranty of
  13. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  14. GNU General Public License for more details.
  15.  
  16. You should have received a copy of the GNU General Public License
  17. along with this program; if not, write to the Free Software
  18. Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.  */
  19.  
  20. #ifndef C_PATHCH_H
  21. #define C_PATHCH_H
  22.  
  23. /* What separates filename components?  */
  24. #ifndef DIR_SEP
  25. #ifdef VMS
  26. #define DIR_SEP ':'
  27. #define DIR_SEP_STRING ":"
  28. #else
  29. #ifdef DOS
  30. #define DIR_SEP '\\'
  31. #define DIR_SEP_STRING "\\"
  32. /* On DOS, it's good to allow both \ and / between directories.  */
  33. #define IS_DIR_SEP(ch) ((ch) == DIR_SEP || (ch) == '/')
  34. #else
  35. #ifdef VMCMS
  36. #define DIR_SEP ' '
  37. #define DIR_SEP_STRING " "
  38. #else
  39. #define DIR_SEP '/'
  40. #define DIR_SEP_STRING "/"
  41. #endif /* not VM/CMS */
  42. #endif /* not DOS */
  43. #endif /* not VMS */
  44. #endif /* not PATH_SEP */
  45.  
  46. #ifndef IS_DIR_SEP
  47. #define IS_DIR_SEP(ch) ((ch) == DIR_SEP)
  48. #endif
  49.  
  50.  
  51. /* What separates elements in environment variable path lists?  */
  52. #ifndef ENV_SEP
  53. #ifdef VMS
  54. #define ENV_SEP ','
  55. #define ENV_SEP_STRING ","
  56. #else
  57. #ifdef DOS
  58. #define ENV_SEP ';'
  59. #define ENV_SEP_STRING ";"
  60. #else
  61. #ifdef VMCMS
  62. #define ENV_SEP ' '
  63. #define ENV_SEP_STRING " "
  64. #else
  65. #define ENV_SEP ':'
  66. #define ENV_SEP_STRING ":"
  67. #endif /* not VM/CMS */
  68. #endif /* not DOS */
  69. #endif /* not VMS */
  70. #endif /* not ENV_SEP */
  71.  
  72. #ifndef IS_ENV_SEP
  73. #define IS_ENV_SEP(ch) ((ch) == ENV_SEP)
  74. #endif
  75.  
  76. #endif /* not C_PATHCH_H */
  77.