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 / PGM / Makefile < prev    next >
Makefile  |  1998-03-24  |  3KB  |  99 lines

  1. # Makefile for pgm tools.
  2. #
  3. # Copyright (C) 1989, 1991 by Jef Poskanzer.
  4. #
  5. # Permission to use, copy, modify, and distribute this software and its
  6. # documentation for any purpose and without fee is hereby granted, provided
  7. # that the above copyright notice appear in all copies and that both that
  8. # copyright notice and this permission notice appear in supporting
  9. # documentation.  This software is provided "as is" without express or
  10. # implied warranty.
  11.  
  12. # Default values, usually overridden by top-level Makefile.
  13. CC= gcc2
  14. CFLAGS= -ansi -O -m68000 -ucc -T/r0 -D_OSK -optasm
  15.  
  16. RGBDEF =        -DRGB_DB="""/dd/sys/rgb.txt"""
  17. TIFFDEF =       -DLIBTIFF
  18. ODIR = .
  19.  
  20. LDFLAGS= -L/dd/lib -nocol -m68000 -los9lib.l -ctrap
  21.  
  22. SHELL =    ksh
  23. INCLUDE =   -I.. -I../PBM
  24. ALLCFLAGS = $(CFLAGS) $(RGBDEF) $(TIFFDEF) $(INCLUDE)
  25. LIBPBM =    ../PBM/libpbm.l
  26. LIBPGM =    libpgm.l
  27. DEFPGM =    pgm.h ../pbmplus.h
  28.  
  29. BINARIES =  asciitopgm bioradtopgm fstopgm \
  30.          hipstopgm lispmtopgm pbmtopgm \
  31.          pgmbentley pgmenhance pgmhist pgmkernel \
  32.          pgmnoise pgmnorm pgmoil \
  33.          pgmramp pgmtofs pgmtolispm pgmtopbm \
  34.          psidtopgm rawtopgm spottopgm \
  35.          pgmcrater pgmedge pgmtexture
  36.  
  37.  
  38. OBJECTS =  asciitopgm.r bioradtopgm.r fstopgm.r \
  39.          hipstopgm.r lispmtopgm.r pbmtopgm.r \
  40.          pgmbentley.r pgmenhance.r pgmhist.r pgmkernel.r \
  41.          pgmnoise.r pgmnorm.r pgmoil.r \
  42.          pgmramp.r pgmtofs.r pgmtolispm.r pgmtopbm.r \
  43.          psidtopgm.r rawtopgm.r spottopgm.r \
  44.          pgmcrater.r pgmedge.r pgmtexture.r
  45.  
  46. .c.r:
  47.     $(CC) $(CFLAGS) -c -o $*.r $*.c
  48.  
  49. all.done:   $(BINARIES)
  50.    echo all done
  51.  
  52. merge:      pbmmerge
  53. pbmmerge:   pbmmerge.c $(OBJECTS) $(LIBPBM)
  54.     $(CC) $(ALLCFLAGS) $(LDFLAGS) -o ../cmds/$@ $@.c $(OBJECTS) $(LIBPBM)
  55.  
  56. # Rules for plain programs.
  57. $(BINARIES):    $(DEFPGM) $(LIBPGM)
  58.     $(CC) $(ALLCFLAGS) $(LDFLAGS) -o ../cmds/$@ $@.c -l$(LIBPGM) -l$(LIBPBM)
  59. $(OBJECTS): $(DEFPGM)
  60.     $(CC) $(ALLCFLAGS) "-Dmain=$*_main" -c $*.c
  61.  
  62. # And library.
  63. lib:        $(LIBPGM)
  64. $(LIBPGM):  libpgm1.r libpgm2.r
  65.     merge libpgm1.r libpgm2.r >-$(LIBPGM)
  66.  
  67. libpgm1.r:  $(DEFPGM) ../version.h libpgm.h libpgm1.c
  68.     $(CC) $(ALLCFLAGS) -c libpgm1.c
  69.  
  70. libpgm2.r:  $(DEFPGM) ../version.h libpgm.h libpgm2.c
  71.     $(CC) $(ALLCFLAGS) -c libpgm2.c
  72.  
  73.  
  74. bioradtopgm  bioradtopgm.r :  bioradtopgm.c
  75. asciitopgm  asciitopgm.r :  asciitopgm.c
  76. fstopgm  fstopgm.r :  fstopgm.c
  77. hipstopgm  hipstopgm.r :  hipstopgm.c
  78. lispmtopgm  lispmtopgm.r :  lispmtopgm.c
  79. pbmtopgm  pbmtopgm.r :  pbmtopgm.c
  80. pgmbentley  pgmbentley.r :  pgmbentley.c
  81. pgmenhance  pgmenhance.r :  pgmenhance.c
  82. pgmhist  pgmhist.r :  pgmhist.c
  83. pgmnoise  pgmnoise.r :  pgmnoise.c
  84. pgmnorm  pgmnorm.r :  pgmnorm.c
  85. pgmoil  pgmoil.r :  pgmoil.c
  86. pgmramp  pgmramp.r :  pgmramp.c
  87. pgmtofs  pgmtofs.r :  pgmtofs.c
  88. pgmtolispm  pgmtolispm.r :  pgmtolispm.c
  89. pgmtopbm  pgmtopbm.r :  pgmtopbm.c
  90. psidtopgm  psidtopgm.r :  psidtopgm.c
  91. spottopgm  spottopgm.r :  spottopgm.c
  92. pgmkernel  pgmkernel.r :  pgmkernel.c
  93. rawtopgm  rawtopgm.r :  rawtopgm.c
  94. pgmcrater  pgmcrater.r :  pgmcrater.c
  95. pgmedge  pgmedge.r :  pgmedge.c
  96. pgmtexture  pgmtexture.r :  pgmtexture.c
  97.  
  98.  
  99.