Amakefile 2.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141
  1. AMAKELIB = { . , /usr/local/lib/amake } ;
  2. %include ack-defs.amk ;
  3. %include common.amk ;
  4. %include cc_hh_tools.amk ;
  5. %include tok_tools.amk ;
  6. %include op_tools.amk ;
  7. %include char_tools.amk ;
  8. %include LLgen.amk ;
  9. %include cc-c.amk ;
  10. %include loader.amk ;
  11. %include lint.amk ;
  12. %default grind ;
  13. TOKENNAMES = tokenname.c [
  14. gen_tokens,
  15. cc-dest = symbol2str.c,
  16. LL-dest = tokenfile.g
  17. ];
  18. DBS_LLTARGETS = {
  19. dbx_string.c[type=C-src],
  20. DBSpars.c[type=C-src],
  21. DBSpars.h[type=C-incl]
  22. } ;
  23. DBS_LLSRC = {
  24. dbx_string.g
  25. } ;
  26. CMD_LLTARGETS = {
  27. tokenfile.c[type=C-src],
  28. commands.c[type=C-src],
  29. Lpars.c[type=C-src],
  30. Lpars.h[type=C-incl]
  31. } ;
  32. CMD_LLSRC = {
  33. tokenname.c,
  34. commands.g
  35. } ;
  36. GENNEXTSRC = {
  37. file.h[type=C-incl],
  38. next.c[type=C-src]
  39. } ;
  40. CSRC = {
  41. dbxread.c,
  42. main.c,
  43. list.c,
  44. tree.c,
  45. expr.c,
  46. position.c,
  47. idf.c,
  48. run.c,
  49. dump.c,
  50. symbol.c,
  51. print.c,
  52. value.c,
  53. type.c,
  54. rd.c,
  55. modula-2.c
  56. } ;
  57. HSRC = {
  58. tokenname.h,
  59. operator.h,
  60. class.h,
  61. position.h,
  62. idf.h,
  63. message.h,
  64. avl.h,
  65. scope.h,
  66. langdep.h,
  67. sizes.h,
  68. rd.h
  69. } ;
  70. HHSRC = {
  71. file.hh,
  72. type.hh,
  73. symbol.hh,
  74. tree.hh,
  75. avl.cc,
  76. scope.cc,
  77. itemlist.cc,
  78. langdep.cc
  79. } ;
  80. LIBRARIES = {
  81. $EMHOME/modules/lib/libassert.a,
  82. $EMHOME/modules/lib/liballoc.a,
  83. $EMHOME/modules/lib/malloc.o,
  84. $EMHOME/modules/lib/libstring.a,
  85. $EMHOME/modules/lib/libobject.a,
  86. $EMHOME/modules/lib/libsystem.a
  87. } ;
  88. DBFLAGS = { -g, -DDEBUG } ;
  89. PROFFLAGS = { } ;
  90. LDFLAGS = {
  91. -Bstatic,
  92. $PROFFLAGS,
  93. $DBFLAGS
  94. } ;
  95. INCLUDES = {
  96. -I$EMHOME/modules/h,
  97. -I$EMHOME/modules/pkg,
  98. -I$EMHOME/h
  99. } ;
  100. CFLAGS = {
  101. $INCLUDES,
  102. $PROFFLAGS,
  103. $DBFLAGS
  104. } ;
  105. LINTFLAGS = {
  106. $INCLUDES
  107. } ;
  108. %cluster {
  109. %targets $DBS_LLTARGETS ;
  110. %sources $DBS_LLSRC ;
  111. %use LLgen(prefix => DBS) ;
  112. } ;
  113. %cluster {
  114. %targets lint.out[type = lint-output];
  115. %sources $CMD_LLSRC + $CSRC + $DBS_LLTARGETS + $HHSRC + char.ct + operators.ot ;
  116. %use lint(realdest => lint.out) ;
  117. } ;
  118. %cluster {
  119. %targets grind[type = program];
  120. %sources $CMD_LLSRC + $CSRC + $DBS_LLTARGETS + $HHSRC + char.ct + operators.ot ;
  121. } ;