home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: InfoMgt / InfoMgt.zip / MAILMIND.ZOO / ENVIRON.MSC < prev    next >
Text File  |  1990-12-31  |  2KB  |  76 lines

  1. #ifndef ENVIRON_H
  2. #define ENVIRON_H
  3.  
  4. /* environ.h - Microsoft C specific version
  5.  * Division of Cancer Prevention & Control, NCI
  6.  */
  7.  
  8. /* Revision history:
  9.  * 1.03  tam  12/31/90  add FINDFIRST macros
  10.  * 1.02  tam  09/21/90  transfer io.h, stat.h, types.h to environ.h
  11.  * 1.01  tam  08/31/90  add defines
  12.  * 1.0   tam  08/24/90  split from local.h
  13.  */
  14.  
  15. /* specific compiler define - avoid use if possible */
  16. #define MSC
  17.  
  18. /* Microsoft C specific headers */
  19. #include <io.h>
  20. #include <dos.h>
  21. #include <direct.h>
  22. #include <fcntl.h>
  23.  
  24. /* System V compatible headers */
  25. #include <malloc.h>
  26. #include <errno.h>
  27. #include <process.h>
  28. #include <sys\types.h>
  29.  
  30. /* other headers */
  31. #include <pckeys.h>
  32.  
  33. /* macro to duplicate TurboC */
  34. #define MK_FP(seg, ofs) ((((unsigned long) seg) << 16) + (unsigned) ofs)
  35.  
  36. /* findfirst & findnext macros for TurboC compatibility */
  37. struct ffblk
  38.   {
  39.   char     ff_reserved[21];
  40.   char     ff_attrib;
  41.   unsigned ff_ftime;
  42.   unsigned ff_fdate;
  43.   long     ff_fsize;
  44.   char     ff_name[13];
  45.   };
  46.  
  47. #define findfirst(path, buffer, attr) (_dos_findfirst(path, attr, buffer))
  48. #define findnext(buffer) (_dos_findnext(buffer))
  49.  
  50. #define FA_NORMAL 0x00    /* Normal files */
  51. #define FA_RDONLY 0x01    /* Read only attribute */
  52. #define FA_HIDDEN 0x02    /* Hidden file */
  53. #define FA_SYSTEM 0x04    /* System file */
  54. #define FA_LABEL  0x08    /* Volume label */
  55. #define FA_DIREC  0x10    /* Directory */
  56. #define FA_ARCH   0x20    /* Archive */
  57.  
  58. /* defines */
  59. #define S_IREAD        0000400          /* read permission, owner */
  60. #define S_IWRITE       0000200          /* write permission, owner */
  61. #define FILE_NAME_LEN  13               /* length of a DOS file name */
  62.  
  63. #endif /* environ.h */
  64.  
  65.  
  66.  
  67.  
  68.  
  69.  
  70.  
  71.  
  72.  
  73.  
  74.  
  75.  
  76.