home *** CD-ROM | disk | FTP | other *** search
/ rtsi.com / 2014.01.www.rtsi.com.tar / www.rtsi.com / OS9 / OSK / NETWORK / netpbm_src.lzh / NETPBM / LIBTIFF / tiffcomp.h < prev    next >
Text File  |  1996-11-24  |  3KB  |  114 lines

  1. /* $Header: /usr/people/sam/tiff/libtiff/RCS/tiffcomp.h,v 1.34 93/08/25 09:45:30 sam Exp $ */
  2.  
  3. /*
  4.  * Copyright (c) 1990, 1991, 1992 Sam Leffler
  5.  * Copyright (c) 1991, 1992 Silicon Graphics, Inc.
  6.  *
  7.  * Permission to use, copy, modify, distribute, and sell this software and 
  8.  * its documentation for any purpose is hereby granted without fee, provided
  9.  * that (i) the above copyright notices and this permission notice appear in
  10.  * all copies of the software and related documentation, and (ii) the names of
  11.  * Sam Leffler and Silicon Graphics may not be used in any advertising or
  12.  * publicity relating to the software without the specific, prior written
  13.  * permission of Sam Leffler and Silicon Graphics.
  14.  * 
  15.  * THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 
  16.  * EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 
  17.  * WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.  
  18.  * 
  19.  * IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR
  20.  * ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND,
  21.  * OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
  22.  * WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 
  23.  * LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 
  24.  * OF THIS SOFTWARE.
  25.  */
  26.  
  27. #ifndef _COMPAT_
  28. #define    _COMPAT_
  29. /*
  30.  * This file contains a hodgepodge of definitions and
  31.  * declarations that are needed to provide compatibility
  32.  * between the native system and the base implementation
  33.  * that the library assumes.
  34.  *
  35.  * NB: This file is a mess.
  36.  */
  37.  
  38. /*
  39.  * Setup basic type definitions and function declaratations.
  40.  */
  41. #ifdef THINK_C
  42. #include <unix.h>
  43. #include <math.h>
  44. #endif
  45. #include <stdio.h>
  46. #ifdef applec
  47. #include <types.h>
  48. #else
  49. #ifndef THINK_C
  50. #ifndef _OSK
  51. #include <sys/types.h>
  52. #else
  53. #include <types.h>
  54. #endif
  55. #endif
  56. #endif
  57. #ifdef VMS
  58. #include <file.h>
  59. #include <unixio.h>
  60. #else
  61. #include <fcntl.h>
  62. #endif
  63. #if defined(THINK_C) || defined(applec)
  64. #include <stdlib.h>
  65. #define    BSDTYPES
  66. #endif
  67.  
  68. /*
  69.  * Workarounds for BSD lseek definitions.
  70.  */
  71. #if defined(SYSV) || defined(VMS)
  72. #if defined(SYSV)
  73. #include <unistd.h>
  74. #endif
  75. #define    L_SET    SEEK_SET
  76. #define    L_INCR    SEEK_CUR
  77. #define    L_XTND    SEEK_END
  78. #endif /* defined(SYSV) || defined(VMS) */
  79. #if !defined(L_SET) || defined(OSK)
  80. #define L_SET    0
  81. #define L_INCR    1
  82. #define L_XTND    2
  83. #endif
  84.  
  85. /*
  86.  * The library uses memset, memcpy, and memcmp.
  87.  * ANSI C and System V define these in string.h.
  88.  */
  89. #include <string.h>
  90.  
  91. /*
  92.  * The BSD typedefs are used throughout the library.
  93.  * If your system doesn't have them in <sys/types.h>,
  94.  * then define BSDTYPES in your Makefile.
  95.  */
  96. #ifdef BSDTYPES
  97. typedef    unsigned char u_char;
  98. typedef    unsigned short u_short;
  99. typedef    unsigned int u_int;
  100. typedef    unsigned long u_long;
  101. #endif
  102.  
  103. /*
  104.  * dblparam_t is the type that a double precision
  105.  * floating point value will have on the parameter
  106.  * stack (when coerced by the compiler).
  107.  */
  108. #ifdef applec
  109. typedef extended dblparam_t;
  110. #else
  111. typedef double dblparam_t;
  112. #endif
  113. #endif /* _COMPAT_ */
  114.