home *** CD-ROM | disk | FTP | other *** search
/ rtsi.com / 2014.01.www.rtsi.com.tar / www.rtsi.com / OS9 / OSK / GRAPHICS / gnuplot32x.tar.Z / gnuplot32x.tar / os9gnuplot3 / MAkefile.OSK < prev    next >
Text File  |  1992-06-29  |  5KB  |  171 lines

  1. # Make file for use with gcc Version 1.40 on OS-9 Ver. 2.3-
  2. # by Dietmar Budelsky 22-5-1992
  3. # budelsky@haegar.ikp.uni-koeln.de
  4.  
  5. # From here, check for right paths and flags
  6. # Correct them, if You want
  7.  
  8. # where to place gnuplot.gih helpfile
  9. HELPFILE = /dd/sys/help/gnuplot.gih
  10.  
  11. # Installation of X11 support...
  12. # You need additional the original cc for compiling gnuplot_X11
  13. # Choose one of the following variants: X11 or no X11
  14. # Install X11 support
  15. PLOTXFLAG   = -DX11
  16. # Compile the X11 driver
  17. GNUPLOT_X11 = gnuplot_X11
  18. # Do not support X11
  19. # GNUPLOT_X11 =
  20. # PLOTXFLAG   =
  21.  
  22. # Use blarslib.l or equal (here os9lib020.l) for UNIX-compatibility */
  23. UNIXLIBDIR  = /dd/lib
  24. UNIXHEADDIR = /dd/defs/UNIX
  25.  
  26. # Compiler, must be ANSI compatible
  27. CC     = gcc
  28.  
  29. # Compiler flags
  30. # -ansi -O -m68020:  neccesary flags for compiling, insert 68881 here
  31. # -DOSK:             should be obsolete, but was not (don't know why)
  32. # -DNOVFORK -DMEMCPY -DMEMSET -DNOGAMMA: 
  33. #                    gnuplot sets for OS-9 (see README.Install)
  34. # -DREADLINE:        include nano emacs commands
  35. # -mlong-calls:      neccesary for not getting out of range errors
  36. # -fcombine-regs -pipe:
  37. #                    the usual, insert -T/r0, if wanted
  38. # -I$(UNIXHEADDIR):  where to find UNIX header files
  39. # -Dgetcwd=getwd:    compatibility defines
  40. #
  41. CFLAGS = -ansi -O -m68020 -DOSK -DNOVFORK -DMEMCPY -DMEMSET -DNOGAMMA\
  42.          -DREADLINE -mlong-calls -fcombine-regs -pipe\
  43.          -I$(UNIXHEADDIR) -Dgetcwd=getwd
  44.  
  45. # see other terminal defines in term.h
  46. TERMFLAGS = $(PLOTXFLAG)
  47.  
  48. # Where to write gnuplot and gnuplot_X11
  49. ODIR   = /dd/local/cmds
  50.  
  51. # Where to find libs
  52. LIBDIR = /dd/lib
  53.  
  54. # linker flags, nothing special for gcc
  55. LFLAGS = -e 1 -m68020 -cio -s 64 -n gnuplot -o $(ODIR)/gnuplot
  56.  
  57. # Give UNIX compatibility library 
  58. LIBS = -l$(UNIXLIBDIR)/os9lib020.l
  59.  
  60. # X11FLAGS and X11LIBS for linking with cc, obsolete for no
  61. # X11 support
  62. X11FLAGS = -I -K=2 -M=64K -n$(GNUPLOT_X11) -F=$(ODIR)/$(GNUPLOT_X11)
  63.  
  64. X11LIBS = -l=$(LIBDIR)/X11/xlib.l -l=$(LIBDIR)/X11/xaulib.l\
  65.           -l=$(LIBDIR)/X11/apsd4os9.l -l=$(LIBDIR)/netdb.l\
  66.           -l=$(LIBDIR)/gnulib.l -l=$(LIBDIR)/math.l\
  67.           -l=$(LIBDIR)/socklib.l -l=$(UNIXLIBDIR)/os9lib020.l
  68.  
  69. # From here, things should be all right
  70.  
  71. OBJS =     OS9comp.r bitmap.r command.r contour.r eval.r \
  72.         graphics.r graph3d.r \
  73.     help.r internal.r misc.r parse.r plot.r getline.r \
  74.     scanner.r setshow.r standard.r term.r util.r version.r
  75.  
  76. CSOURCE5 = term/aed.trm term/cgi.trm term/dumb.trm term/dxf.trm term/dxy.trm \
  77.     term/eepic.trm term/epson.trm term/fig.trm term/hp26.trm \
  78.     term/hp2648.trm term/hpgl.trm term/hpljii.trm 
  79. CSOURCE6 = term/impcodes.h term/imagen.trm term/object.h \
  80.     term/iris4d.trm term/kyo.trm term/latex.trm term/pc.trm 
  81. CSOURCE7 = term/post.trm term/qms.trm term/regis.trm term/sun.trm \
  82.     term/t410x.trm term/tek.trm term/unixpc.trm term/unixplot.trm \
  83.     term/v384.trm term/x11.trm
  84. CSOURCE8 = contour.c
  85.  
  86. # make complete project
  87. gnuplotproject: $(HELPFILE) $(GNUPLOT_X11) $(ODIR)/gnuplot plot.h.tmp
  88. #kill obsolete files
  89.         del *.r
  90. # restore old plot.h
  91.         copy -r plot.h.tmp plot.h
  92.         touch plot.h
  93.         del plot.h.tmp
  94. #ready with gnuplot
  95.         @echo "gnuplot ready to go!"
  96.  
  97.  
  98. # Add OS-9 definitions to plot.h
  99. plot.h.tmp: plot.h
  100.         copy -r plot.h plot.h.tmp
  101.         list plot.h.OSK plot.h.tmp >plot.h
  102.         touch plot.h.tmp
  103.  
  104. # convert gnuplot.doc to gnuplot.gih
  105. $(HELPFILE): $(ODIR)/doc2gih docs/gnuplot.doc
  106.     doc2gih <docs/gnuplot.doc >$(HELPFILE)
  107.         attr -pr $(HELPFILE)
  108.  
  109. $(ODIR)/doc2gih: docs/doc2gih.c
  110.     $(CC) $(CFLAGS) -o $(ODIR)/doc2gih -n doc2gih docs/doc2gih.c
  111.  
  112. # For X11 support generate gnuplot_X11
  113. $(GNUPLOT_X11): $(GNUPLOT_X11).r
  114.         cc $(X11FLAGS) $(X11LIBS) $(GNUPLOT_X11).r
  115.         attr -e -pe $(ODIR)/$(GNUPLOT_X11)
  116.  
  117. $(GNUPLOT_X11).r: $(GNUPLOT_X11).c
  118.         $(CC) $(CFLAGS) -c -Daccept=newaccept $(GNUPLOT_X11).c
  119.  
  120. # Object files in link command line are ordered to avoid far jumps.
  121.  
  122. $(ODIR)/gnuplot: $(OBJS) 
  123.         $(CC) $(LFLAGS) $(LIBS) $(OBJS)
  124.         attr -e -pe $(ODIR)/gnuplot
  125.  
  126. # Now, produce the object files
  127.  
  128. OS9comp.r: OS9comp.c OS9comp.h
  129.  
  130. bitmap.r: bitmap.c bitmap.h plot.h plot.h.tmp
  131.  
  132. command.r: command.c plot.h setshow.h help.h plot.h.tmp
  133.     $(CC) $(CFLAGS) \
  134.         -Dunix -DHELPFILE=\"$(HELPFILE)\" -c command.c
  135.  
  136. contour.r: contour.c plot.h plot.h.tmp
  137.  
  138. eval.r: eval.c plot.h plot.h.tmp
  139.  
  140. graphics.r: graphics.c plot.h setshow.h plot.h.tmp
  141.  
  142. graph3d.r: graphics.c plot.h setshow.h plot.h.tmp
  143.  
  144. help.r: help.c plot.h help.h plot.h.tmp
  145.  
  146. internal.r: internal.c plot.h plot.h.tmp
  147.  
  148. misc.r: misc.c plot.h setshow.h plot.h.tmp
  149.  
  150. parse.r: parse.c plot.h plot.h.tmp
  151.  
  152. plot.r: plot.c plot.h setshow.h plot.h.tmp
  153.     $(CC) $(CFLAGS) \
  154.          -Dunix -c plot.c
  155.  
  156. getline.r: getline.c OS9comp.h
  157.  
  158. scanner.r: scanner.c plot.h plot.h.tmp
  159.  
  160. setshow.r: setshow.c plot.h setshow.h plot.h.tmp
  161.  
  162. standard.r: standard.c plot.h plot.h.tmp
  163.  
  164. term.r: term.c term.h plot.h setshow.h bitmap.h plot.h.tmp \
  165.         $(CSOURCE5) $(CSOURCE6) $(CSOURCE7)
  166.     $(CC) $(CFLAGS) $(TERMFLAGS) -Iterm -c term.c
  167.  
  168. util.r: util.c plot.h plot.h.tmp
  169.  
  170. version.r: version.c
  171.