home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 9 Archive / 09-Archive.zip / zip21.zip / win32 / osdep.h < prev    next >
C/C++ Source or Header  |  1996-04-17  |  2KB  |  82 lines

  1. /*
  2.  
  3.  Copyright (C) 1990-1996 Mark Adler, Richard B. Wales, Jean-loup Gailly,
  4.  Kai Uwe Rommel, Onno van der Linden and Igor Mandrichenko.
  5.  Permission is granted to any individual or institution to use, copy, or
  6.  redistribute this software so long as all of the original files are included,
  7.  that it is not sold for profit, and that this copyright notice is retained.
  8.  
  9. */
  10.  
  11. /* Automatic setting of the common Microsoft C idenfifier MSC.
  12.  * NOTE: Watcom also defines M_I*86 !
  13.  */
  14. #if defined(_MSC_VER) || (defined(M_I86) && !defined(__WATCOMC__))
  15. #  ifndef MSC
  16. #    define MSC                 /* This should work for older MSC, too!  */
  17. #  endif
  18. #endif
  19.  
  20. #if defined(__WATCOMC__) && defined(__386__)
  21. #  define WATCOMC_386
  22. #endif
  23.  
  24. #ifndef MSDOS
  25. /*
  26.  * Windows 95 (and Windows NT) file systems are (to some extend)
  27.  * extensions of MSDOS. Common features include for example:
  28.  *      FAT or (FAT like) file systems,
  29.  *      '\\' as directory separator in paths,
  30.  *      "\r\n" as record (line) terminator in text files, ...
  31.  */
  32. #  define MSDOS
  33. /* inherit MS-DOS file system etc. stuff */
  34. #endif
  35.  
  36. /* Define MSVMS if MSDOS or VMS defined */
  37. #define MSVMS
  38.  
  39. /* File operations--use "b" for binary if allowed or fixed length 512 on VMS */
  40. #define FOPR "rb"
  41. #define FOPM "r+b"
  42. #define FOPW "wb"
  43.  
  44. #ifdef WIZZIPDLL
  45. #define NO_ASM
  46. #define NO_SECURE_TESTS
  47. #define MSWIN
  48. #define REENTRANT
  49. #endif
  50.  
  51. /* Enable use of optimized x86 assembler version of longest_match() for
  52.    MSDOS, WIN32 and OS2 per default.  */
  53. #if !defined(NO_ASM) && !defined(ASMV)
  54. #  define ASMV
  55. #endif
  56.  
  57. #define NO_UNISTD_H
  58.  
  59. /* Get types and stat */
  60. #include <sys/types.h>
  61. #include <sys/stat.h>
  62. #include <io.h>
  63. #include <malloc.h>
  64.  
  65. #ifdef __WATCOMC__
  66. #  define NO_MKTEMP
  67.  
  68. /* Get asm routines to link properly without using "__cdecl": */
  69. #  ifdef __386__
  70. #    ifdef ASMV
  71. #      pragma aux match_init    "_*" parm caller [] modify []
  72. #      pragma aux longest_match "_*" parm caller [] value [eax] \
  73.                                       modify [eax ecx edx]
  74. #    endif
  75. #    if defined(ASM_CRC) && !defined(USE_ZLIB)
  76. #      pragma aux crc32         "_*" parm caller [] value [eax] modify [eax]
  77. #      pragma aux get_crc_table "_*" parm caller [] value [eax] \
  78.                                       modify [eax ecx edx]
  79. #    endif /* ASM_CRC && !USE_ZLIB */
  80. #  endif /* __386__ */
  81. #endif /* __WATCOMC__ */
  82.