pmfile 1.8 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071
  1. -- $Source$
  2. -- $State$
  3. local d = ROOTDIR.."mach/proto/as/"
  4. local parser = yacc {
  5. simple {
  6. outputs = {"%U%-%I%.y"},
  7. -- command = {
  8. -- "cd %out[1]:dirname% && "..
  9. -- "%BINDIR%%PLATDEP%/cpp.ansi -P -I%ROOTDIR%mach/%ARCH%/as -I"..d.." %CINCLUDES:cincludes% %in[1]% > %out[1]%"
  10. -- },
  11. command = {
  12. "cd %out[1]:dirname% && "..
  13. "cpp -P -I%ROOTDIR%mach/%ARCH%/as -I"..d.." %CINCLUDES:cincludes% %in[1]% > %out[1]%"
  14. },
  15. file (d.."comm2.y"),
  16. }
  17. }
  18. local cfile_with_tables = cfile {
  19. class = "cfile_with_tables",
  20. CINCLUDES = {PARENT, "%ROOTDIR%mach/%ARCH%/as"},
  21. dynamicheaders = {
  22. parser,
  23. }
  24. }
  25. proto_as = cprogram {
  26. class = "proto_as",
  27. cfile_with_tables (d.."comm3.c"),
  28. cfile_with_tables (d.."comm4.c"),
  29. cfile_with_tables (d.."comm5.c"),
  30. cfile_with_tables (d.."comm6.c"),
  31. cfile_with_tables (d.."comm7.c"),
  32. cfile_with_tables (d.."comm8.c"),
  33. cfile {
  34. parser,
  35. },
  36. lib_object,
  37. outputs = {"%U%/%PLATFORM%-as"},
  38. install = pm.install(BINDIR.."%PLATDEP%/%PLATFORM%/as")
  39. }
  40. -- Revision history
  41. -- $Log$
  42. -- Revision 1.5 2007-04-21 22:55:59 dtrg
  43. -- yacc source files are now run through the ANSI C preprocessor, not the K&R one.
  44. --
  45. -- Revision 1.4 2007/02/20 00:45:19 dtrg
  46. -- Done a major overhaul of the way target include files are installed and
  47. -- how platform libraries are built. The ARCH pm variable has now been
  48. -- renamed PLATFORM (which is more accurate) and a different ARCH
  49. -- variable added, which represents the CPU family rather than the
  50. -- hardware platform.
  51. --
  52. -- Revision 1.3 2006/10/15 00:28:12 dtrg
  53. -- Updated to the version 0.1 of Prime Mover (which involves some syntax changes).
  54. --
  55. -- Revision 1.2 2006/07/30 23:41:16 dtrg
  56. -- Broke dependency on tool_cpp in order to speed up the build.
  57. --
  58. -- Revision 1.1 2006/07/20 23:18:19 dtrg
  59. -- First version in CVS.
  60. --