home *** CD-ROM | disk | FTP | other *** search
/ Encyclopedia of Graphics File Formats Companion / GFF_CD.ISO / software / unix / libtiff / lbtif3_3.tar / tools / Makefile.sgi < prev    next >
Makefile  |  1993-08-26  |  4KB  |  142 lines

  1. #    $Header: /usr/people/sam/tiff/tools/RCS/Makefile.sgi,v 1.26 92/10/21 16:30:27 sam Exp $
  2. #
  3. # TIFF Library Tools
  4. #
  5. # Copyright (c) 1988, 1989, 1990, 1991, 1992 Sam Leffler
  6. # Copyright (c) 1991, 1992 Silicon Graphics, Inc.
  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 Stanford and Silicon Graphics.
  14. # THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 
  15. # EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 
  16. # WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.  
  17. # IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR
  18. # ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND,
  19. # OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
  20. # WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 
  21. # LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 
  22. # OF THIS SOFTWARE.
  23. #
  24. NULL=
  25. IPATH=    -I../libtiff
  26. #
  27. # If you don't want the public domain getopt code, then
  28. # simply null this out and you'll get whatever is in your
  29. # libc (or similar).
  30. #
  31. GETOPT=    getopt.o
  32. #
  33. # Library-wide configuration defines:
  34. # Note that if you change the library-wide configuration, you'll
  35. # need to manual force a full rebuild. 
  36. #
  37. CONF_LIBRARY=\
  38.     ${NULL}
  39. COPTS=    
  40. CFLAGS=    -O -ansi ${COPTS} ${IPATH}
  41. #
  42. LIBTIFF=../libtiff/libtiff.a
  43. LIBS=    ${LIBTIFF}
  44. MACHALL=ras2tiff tiffgt tiffsv sgi2tiff        # these exist on the SGI
  45. OBJS=    \
  46.     fax2tiff.o \
  47.     gif2tiff.o \
  48.     pal2rgb.o \
  49.     ppm2tiff.o \
  50.     rgb2ycbcr.o \
  51.     tiff2bw.o \
  52.     tiff2ps.o \
  53.     tiffcmp.o \
  54.     tiffcp.o \
  55.     tiffdither.o \
  56.     tiffdump.o \
  57.     tiffinfo.o \
  58.     tiffmedian.o \
  59.     tiffsplit.o \
  60.     ras2tiff.o \
  61.     sgigt.o \
  62.     sgisv.o \
  63.     sgi2tiff.o \
  64.     ${GETOPT} \
  65.     ${NULL}
  66. ALL=\
  67.     fax2tiff \
  68.     gif2tiff \
  69.     pal2rgb \
  70.     ppm2tiff \
  71.     rgb2ycbcr \
  72.     tiff2bw \
  73.     tiff2ps \
  74.     tiffcmp \
  75.     tiffcp \
  76.     tiffdither \
  77.     tiffdump \
  78.     tiffinfo \
  79.     tiffmedian \
  80.     tiffsplit \
  81.     ${MACHALL} \
  82.     ${NULL}
  83.  
  84. all:     ${ALL}
  85.  
  86. tiffinfo: tiffinfo.c ${GETOPT} ${LIBTIFF}
  87.     ${CC} -o tiffinfo ${CFLAGS} tiffinfo.c ${GETOPT} ${LIBS}
  88. tiffcmp:tiffcmp.c ${GETOPT} ${LIBTIFF}
  89.     ${CC} -o tiffcmp ${CFLAGS} tiffcmp.c ${GETOPT} ${LIBS}
  90. tiffcp:    tiffcp.c ${LIBTIFF}
  91.     ${CC} -o tiffcp ${CFLAGS} tiffcp.c ${LIBS}
  92. tiffdump: tiffdump.c
  93.     ${CC} -o tiffdump ${CFLAGS} tiffdump.c
  94. tiffmedian: tiffmedian.c ${LIBTIFF}
  95.     ${CC} -o tiffmedian ${CFLAGS} tiffmedian.c ${LIBS}
  96. tiffsplit: tiffsplit.c ${LIBTIFF}
  97.     ${CC} -o tiffsplit ${CFLAGS} tiffsplit.c ${LIBS}
  98. tiff2ps: tiff2ps.c ${LIBTIFF}
  99.     ${CC} -o tiff2ps ${CFLAGS} tiff2ps.c ${LIBS} -lm
  100. # junky stuff...
  101. # convert RGB image to B&W
  102. tiff2bw: tiff2bw.c ${GETOPT} ${LIBTIFF}
  103.     ${CC} -o tiff2bw ${CFLAGS} tiff2bw.c ${GETOPT} ${LIBS}
  104. # convert B&W image to bilevel w/ FS dithering
  105. tiffdither: tiffdither.c ${GETOPT} ${LIBTIFF}
  106.     ${CC} -o tiffdither ${CFLAGS} tiffdither.c ${GETOPT} ${LIBS}
  107. # Sun rasterfile converter
  108. ras2tiff: ras2tiff.c ${LIBTIFF}
  109.     ${CC} -o ras2tiff ${CFLAGS} ras2tiff.c ${LIBS}
  110. # GIF converter
  111. gif2tiff: gif2tiff.c ${LIBTIFF}
  112.     ${CC} -o gif2tiff ${CFLAGS} gif2tiff.c ${LIBS} -lm
  113. # PBM converter
  114. ppm2tiff: ppm2tiff.c ${LIBTIFF}
  115.     ${CC} -o ppm2tiff ${CFLAGS} ppm2tiff.c ${LIBS}
  116. # SGI image file converter
  117. sgi2tiff: sgi2tiff.c ${LIBTIFF}
  118.     ${CC} -o sgi2tiff ${CFLAGS} sgi2tiff.c -limage ${LIBS}
  119. # Group 3 FAX file converter
  120. fax2tiff: fax2tiff.c ${GETOPT} ${LIBTIFF}
  121.     ${CC} -o fax2tiff ${CFLAGS} ${CONF_LIBRARY} fax2tiff.c ${GETOPT} ${LIBS}
  122. # convert Palette image to RGB
  123. pal2rgb: pal2rgb.c ${LIBTIFF}
  124.     ${CC} -o pal2rgb ${CFLAGS} pal2rgb.c ${LIBS}
  125. # convert RGB image to YCbCr
  126. rgb2ycbcr: rgb2ycbcr.c ${GETOPT} ${LIBTIFF}
  127.     ${CC} -o rgb2ycbcr ${CFLAGS} rgb2ycbcr.c ${GETOPT} ${LIBS} -lm
  128. # SGI versions of tiffgt & tiffsv
  129. tiffgt:    sgigt.c ${GETOPT} ${LIBTIFF}
  130.     ${CC} -o tiffgt ${CFLAGS} sgigt.c ${GETOPT} ${LIBS} -lgutil -lgl_s -lm
  131. tiffsv:    sgisv.c ${LIBTIFF}
  132.     ${CC} -o tiffsv ${CFLAGS} sgisv.c ${LIBS} -lgutil -lgl_s -lm
  133.  
  134. install: all
  135.     /etc/install -f /usr/local/bin -m 755 -O ${ALL}
  136.  
  137. clean:
  138.     rm -f ${ALL} ${OBJS} core a.out ycbcr
  139.