Makefile.fpc 2.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140
  1. #
  2. # Makefile.fpc for Amiga RTL
  3. #
  4. [package]
  5. main=rtl
  6. [target]
  7. loaders=prt0
  8. units=system exec strings \
  9. dos crt objects printer \
  10. objpas \
  11. heaptrc lineinfo getopts graph \
  12. sysutils math typinfo
  13. rsts=math
  14. [require]
  15. nortl=y
  16. [install]
  17. fpcpackage=y
  18. [default]
  19. fpcdir=../..
  20. target=amiga
  21. cpu=m68k
  22. [compiler]
  23. includedir=$(INC) $(PROCINC)
  24. sourcedir=$(INC) $(PROCINC)
  25. targetdir=.
  26. [prerules]
  27. RTL=..
  28. INC=../inc
  29. PROCINC=../$(CPU_TARGET)
  30. PPUEXT=ppa
  31. ASMEXT=.asm
  32. UNITPREFIX=rtl
  33. # Use new feature from 1.0.5 version
  34. # that generates release PPU files
  35. # which will not be recompiled
  36. ifdef RELEASE
  37. ifeq ($(findstring 1.0.2,$(FPC_VERSION)),)
  38. ifeq ($(findstring 1.0.4,$(FPC_VERSION)),)
  39. override FPCOPT+=-Ur
  40. endif
  41. endif
  42. endif
  43. # Paths
  44. OBJPASDIR=$(RTL)/objpas
  45. GRAPHDIR=$(INC)/graph
  46. [rules]
  47. # Get the system independent include file names.
  48. # This will set the following variables :
  49. # SYSINCNAMES
  50. include $(INC)/makefile.inc
  51. SYSINCDEPS=$(addprefix $(INC)/,$(SYSINCNAMES))
  52. # Get the processor dependent include file names.
  53. # This will set the following variables :
  54. # CPUINCNAMES
  55. include $(PROCINC)/makefile.cpu
  56. SYSCPUDEPS=$(addprefix $(PROCINC)/,$(CPUINCNAMES))
  57. # Put system unit dependencies together.
  58. SYSDEPS=$(SYSINCDEPS) $(SYSCPUDEPS)
  59. #
  60. # Loaders
  61. #
  62. prt0$(OEXT) : prt0$(LOADEREXT)
  63. -$(AS) prt0$(LOADEREXT) -o prt0$(OEXT)
  64. #gprt0$(OEXT) : $(GLOADERAS)
  65. # -$(AS) $(GLOADERAS) -o gprt0$(OEXT)
  66. #
  67. # Base Units (System, strings, os-dependent-base-unit)
  68. #
  69. system$(PPUEXT) : sysamiga.pas $(SYSLINUXDEPS) $(SYSDEPS)
  70. $(COMPILER) -ui386 -dm68k -Us -Sg sysamiga.pas $(REDIR)
  71. strings$(PPUEXT) : ../template/strings.pp system$(PPUEXT)
  72. $(COMPILER) ../template/strings.pp $(REDIR)
  73. exec$(PPUEXT) : exec.pp exec.inc system$(PPUEXT)
  74. $(COMPILER) exec $(REDIR)
  75. #
  76. # Delphi Object Model
  77. #
  78. objpas$(PPUEXT) : $(OBJPASDIR)/objpas.pp system$(PPUEXT)
  79. $(COPY) $(OBJPASDIR)/objpas.pp .
  80. $(COMPILER) objpas $(REDIR)
  81. $(DEL) objpas.pp
  82. sysutils$(PPUEXT) : $(OBJPASDIR)/sysutils.pp objpas$(PPUEXT) system$(PPUEXT)
  83. $(COPY) $(OBJPASDIR)/sysutils.pp .
  84. $(COMPILER) sysutils $(REDIR)
  85. #$(DEL) sysutils.pp
  86. #
  87. # System Dependent Units
  88. #
  89. #
  90. # TP7 Compatible RTL Units
  91. #
  92. dos$(PPUEXT) : $(DOSDEPS) system$(PPUEXT)
  93. $(COMPILER) dos $(REDIR)
  94. crt$(PPUEXT) : crt.pp $(INC)/textrec.inc system$(PPUEXT)
  95. $(COMPILER) crt $(REDIR)
  96. printer$(PPUEXT) : printer.pp system$(PPUEXT)
  97. $(COMPILER) printer $(REDIR)
  98. objects$(PPUEXT) : $(INC)/objects.pp objinc.inc system$(PPUEXT)
  99. $(COMPILER) $(INC)/objects.pp $(REDIR)
  100. #
  101. # Other RTL Units
  102. #
  103. getopts$(PPUEXT) : $(INC)/getopts.pp strings$(PPUEXT) system$(PPUEXT)
  104. $(COMPILER) $(INC)/getopts.pp $(REDIR)
  105. heaptrc$(PPUEXT) : $(INC)/heaptrc.pp system$(PPUEXT)
  106. $(COMPILER) $(INC)/heaptrc.pp $(REDIR)