home *** CD-ROM | disk | FTP | other *** search
/ Club Amiga de Montreal - CAM / CAM_CD_1.iso / files / 505a.lha / GrapicsGems / Makefile < prev    next >
Makefile  |  1991-05-01  |  3KB  |  123 lines

  1. #
  2. # Makefile for Graphics Gems source
  3. #
  4. # Craig Kolb, 8/90
  5. #
  6. # This make file will build "gemslib.a" and a number of executables.
  7. # Gemslib is built solely for debugging purposes -- it is not intended
  8. # to be used as a library.
  9. #
  10. # Note that some of the gems need additional macros, functions, tables
  11. # driving routines, etc. before they will compile or run properly.
  12. # These include:
  13. #
  14. # AALines
  15. #    Needs variables set in the Makefile.
  16. # Dissolve
  17. #    Needs a table filled.
  18. # FitCurves
  19. #    Needs a functioning DrawBezierCurve().
  20. # MatrixOrtho
  21. #    Needs a number of matrix routines.
  22. # PolyScan
  23. #    Needs driving routines and other additional code.
  24. # RayPolygon
  25. #    Needs surrounding function structure, declaration of
  26. #    variable types, etc.
  27.  
  28. #
  29. # C compiler flags
  30. #
  31. CFLAGS = -g
  32. #
  33. # Location of Graphics Gems library
  34. #
  35. LIBFILE = gemslib.a
  36.  
  37. #
  38. # Graphics Gems Vector Library
  39. #
  40. VECLIB = GGVecLib.o
  41.  
  42. MFLAGS = "LIBFILE = ../$(LIBFILE)" "GENCFLAGS = $(CFLAGS)"
  43.  
  44. FTPDIR = /usr/spool/uucppublic/ftp/pub/GraphicsGems/src
  45. ZOOFILE = Gems.zoo
  46.  
  47. SHELL = /bin/sh
  48.  
  49. OFILES =    PntOnLine.o ViewTrans.o AAPolyScan.o Albers.o \
  50.         Interleave.o BoundSphere.o BoxSphere.o CircleRect.o \
  51.         ConcaveScan.o Roots3And4.o Dissolve.o DigitalLine.o \
  52.         FastJitter.o FixedTrig.o HSLtoRGB.o HypotApprox.o LineEdge.o \
  53.         MatrixInvert.o MatrixPost.o Median.o PixelInteger.o \
  54.         TriPoints.o Quaternions.o RGBTo4Bits.o RayBox.o \
  55.         SeedFill.o SquareRoot.o DoubleLine.o TransBox.o
  56.  
  57. DIRS = 2DClip PolyScan Sturm
  58.  
  59. ALL =    Hash3D FitCurves Forms NearestPoint Label \
  60.     OrderDither BinRec $(LIBFILE)
  61.  
  62. all: $(ALL)
  63.     @for d in $(DIRS) ; do \
  64.         (cd $$d ; $(MAKE) $(MFLAGS)) ;\
  65.     done
  66.  
  67. $(LIBFILE): $(OFILES) $(VECLIB)
  68.     ar rcs $(LIBFILE) $(OFILES) $(VECLIB)
  69.  
  70. Hash3D: Hash3D.o
  71.     $(CC) $(CFLAGS) -o $@ Hash3D.o
  72.  
  73. FitCurves: FitCurves.o $(VECLIB)
  74.     $(CC) $(CFLAGS) -o $@ FitCurves.o $(VECLIB) -lm
  75.  
  76. Forms: Forms.o
  77.     $(CC) $(CFLAGS) -o $@ Forms.o
  78.  
  79. NearestPoint: NearestPoint.o $(VECLIB)
  80.     $(CC) $(CFLAGS) -o $@ NearestPoint.o $(VECLIB) -lm
  81.  
  82. Label: Label.o
  83.     $(CC) $(CFLAGS) -o $@ Label.o -lm
  84.  
  85. OrderDither: OrderDither.o
  86.     $(CC) $(CFLAGS) -o $@ OrderDither.o
  87.  
  88. BinRec: BinRec.o
  89.     $(CC) $(CFLAGS) -o $@ BinRec.o
  90.  
  91. ftpreadme:
  92.     /bin/rm -f $(FTPDIR)/README
  93.     sed -e "s/__DATE__/`date`/g" < README.ftp > $(FTPDIR)/README
  94.  
  95. readme:
  96.     /bin/rm -rf README
  97.     sed -e "s/__DATE__/`date`/g" < README.dist > README
  98.     
  99.  
  100. clean:
  101.     @for d in $(DIRS) ; do \
  102.         (cd $$d ; $(MAKE) $(MFLAGS) clean) ;\
  103.     done
  104.     /bin/rm -f $(OFILES) $(VECLIB)
  105.     /bin/rm -f Hash3D.o FitCurves.o \
  106.         Forms.o NearestPoint.o Label.o OrderDither.o BinRec.o \
  107.         Hash3D FitCurves Forms NearestPoint Label OrderDither BinRec \
  108.         bugs a.out core Part??.Z Part?? $(ZOOFILE)
  109.  
  110. kit: readme
  111.     /bin/rm -f Part??.Z Part??
  112.     (makekit -iPACKING_LIST -oMANIFEST)
  113.  
  114. zoo: readme
  115.     /bin/rm -f Gems.zoo
  116.     cut -d" " -f2 PACKING_LIST | zoo aI $(ZOOFILE)
  117.  
  118. ftp: kit zoo ftpreadme
  119.     compress Part??
  120.     /bin/cp Part??.Z $(ZOOFILE) $(FTPDIR)
  121.  
  122. $(ALL): GraphicsGems.h
  123.