home *** CD-ROM | disk | FTP | other *** search
/ rtsi.com / 2014.01.www.rtsi.com.tar / www.rtsi.com / OS9 / OSK / EFFO / pd7.lzh / SRC / makefile < prev    next >
Makefile  |  1990-05-06  |  3KB  |  117 lines

  1. # Specify the name of the program.
  2. # All documentation and installation keys on this value.
  3. #
  4. name=sc
  5. NAME=SC
  6.  
  7. # This is where the install step puts it.
  8. EXDIR=/dd/cmds
  9.  
  10. # This is where the man page goes.
  11. MANDIR=/usr/man/man1
  12.  
  13. # Set SIMPLE for lex.c if you don't want arrow keys or lex.c blows up
  14. #SIMPLE=-DSIMPLE
  15. SIMPLE=
  16.  
  17. # Set INTERNATIONAL if you need 8 bit characters.  You should
  18. # not set this if you are running 5.3.0.  I think it is OK in 5.3.1.
  19. INTERNATIONAL=-DINTERNATIONAL
  20. #INTERNATIONAL=
  21.  
  22. # Set SIGVOID if signal routines are type void.  System 5.3, VMS and ANSI C
  23. # Compliant systems use this.  Most BSD systems do not.
  24. #SIGVOID=-DSIGVOID
  25. SIGVOID=
  26.  
  27. # This is the name of a pager like "more" If the line is commented out
  28. # then "more" will be used. "pg" may be appropriate for SYSV
  29. #PAGER=-DDFLT_PAGER="less"
  30. PAGER=
  31.  
  32. # Use this for system V.2
  33. # CFLAGS= -O -DSYSV2 $(SIGVOID)
  34. # LDFLAGS=
  35. # LIB=-lm -lcurses -lPW
  36.  
  37. # Use this for system V.3
  38. # CFLAGS= -O -DSYSV3 -DSIGVOID
  39. # LDFLAGS=
  40. # LIB=-lm -lcurses -lPW
  41.  
  42. # Use this for BSD 4.2
  43. #CFLAGS=  -O -DBSD42 $(SIGVOID)
  44. #LDFLAGS=
  45. #LIB=-lm -lcurses -ltermcap
  46.  
  47. # Use this for BSD 4.3
  48. #CFLAGS= -O -DBSD43 $(SIGVOID)
  49. #LDFLAGS=
  50. #LIB=-lm -lcurses -ltermcap
  51.  
  52. # Use this for system III (XENIX)
  53. #CFLAGS= -O -DSYSIII $(SIGVOID)
  54. #LDFLAGS= -i
  55. #LIB=-lm -lcurses -ltermcap
  56.  
  57. # Use this for VENIX
  58. #CFLAGS= -DVENIX -DBSD42 -DV7 $(SIGVOID)
  59. #LDFLAGS= -z -i
  60. #LIB=-lm -lcurses -ltermcap
  61.  
  62. # Use this for OSK
  63. CFLAGS= -t=/r0 -qix $(SIMPLE) $(INTERNATIONAL) $(PAGER)
  64. LDFLAGS= $(CFLAGS) -fd=sc -M=20K
  65. LIB= -l=/dd/lib/os9lib.l -l=/dd/lib/curses.l -l=/dd/lib/termlib.l
  66. RDIR=rels
  67. #YACC=bison
  68. YACC=yacc
  69. CC=cc
  70.  
  71. # All of the source files
  72. SRC=sc.h sc.c lex.c gram.y interp.c crypt.c xmalloc.c cmds.c range.c help.c \
  73.     eres.sed sres.sed Makefile psc.c
  74.  
  75. # The objects
  76. #OBJS=sc.r interp.r cmds.r crypt.r xmalloc.r range.r help.r lex.r gram.r
  77. OBJS=sc.r interp.r cmds.r xmalloc.r range.r help.r lex.r gram.r
  78.  
  79. # The documents in the Archive
  80. DOCS=README CHANGES sc.doc psc.doc tutorial.sc VMS_NOTES BSD_BUGS
  81.  
  82. .md : $(name) p$(name)
  83.    @touch .md
  84.  
  85. install: $(name) p$(name)
  86.     copy $(name) p$(name) -rw=$(EXDIR)
  87.  
  88. gram.c: gram.y
  89.     $(YACC) -d gram.y; grep -v \23line y.tab.c >-gram.c
  90.  
  91. $(name):    $(OBJS)
  92.     chd $(RDIR);$(CC) $(LDFLAGS) $(OBJS) $(LIB) -fd=../$(name)
  93.  
  94. p$(name):  getopt.r psc.r
  95.     chd $(RDIR);$(CC) $(CFLAGS) -fd=../p$(name) psc.r getopt.r
  96.  
  97. experres.h: gram.y eres.sed
  98.     sed<gram.y >experres.h -f eres.sed
  99.  
  100. statres.h: gram.y sres.sed
  101.     sed < gram.y > statres.h -f sres.sed
  102.  
  103. clean:
  104.     -del $(RDIR)/*.r *res.h y.tab.h $(name) p$(name) gram.c\
  105.     $(name).stb $(name).dbg p$(name).stb p$(name).dbg
  106.  
  107. gram.r: sc.h
  108. interp.r: interp.c sc.h
  109. cmds.r: cmds.c sc.h
  110. crypt.r: crypt.c sc.h
  111. range.r: range.c sc.h
  112. help.r: help.c sc.h
  113. y.tab.h: gram.y
  114. lex.r: sc.h y.tab.h experres.h statres.h
  115. sc.r: sc.h sc.c
  116.  
  117.