Makefile 3.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159
  1. #
  2. # $Id$
  3. # Copyright (c) 1999 by the Free Pascal Development Team
  4. #
  5. # Makefile for Free Pascal Utils
  6. #
  7. # See the file COPYING.FPC, included in this distribution,
  8. # for details about the copyright.
  9. #
  10. # This program is distributed in the hope that it will be useful,
  11. # but WITHOUT ANY WARRANTY; without even the implied warranty of
  12. # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
  13. #
  14. #####################################################################
  15. # Defaults
  16. #####################################################################
  17. # Default place of the makefile.fpc
  18. DEFAULTFPCDIR=..
  19. #####################################################################
  20. # Real targets
  21. #####################################################################
  22. EXEOBJECTS=ppudump ppumove ppdep ptop
  23. UNITOBJECTS=
  24. #####################################################################
  25. # Common targets
  26. #####################################################################
  27. .PHONY: all clean install info \
  28. staticlib sharedlib libsclean \
  29. staticinstall sharedinstall libinstall \
  30. extra_clean \
  31. h2pas_all h2pas_clean h2pas_install \
  32. all: testfpcmake fpc_all h2pas_all
  33. clean: testfpcmake fpc_clean extra_clean h2pas_clean
  34. install: testfpcmake fpc_install h2pas_install
  35. info: testfpcmake fpc_info
  36. staticlib: testfpcmake fpc_staticlib
  37. sharedlib: testfpcmake fpc_sharedlib
  38. libsclean: testfpcmake fpc_libsclean
  39. staticinstall: testfpcmake fpc_staticinstall
  40. sharedinstall: testfpcmake fpc_sharedinstall
  41. libinstall: testfpcmake fpc_libinstall
  42. #####################################################################
  43. # Include default makefile
  44. #####################################################################
  45. # test if FPCMAKE is still valid
  46. ifdef FPCMAKE
  47. ifeq ($(strip $(wildcard $(FPCMAKE))),)
  48. FPCDIR=
  49. FPCMAKE=
  50. endif
  51. endif
  52. ifndef FPCDIR
  53. ifdef DEFAULTFPCDIR
  54. FPCDIR=$(DEFAULTFPCDIR)
  55. endif
  56. endif
  57. ifndef FPCMAKE
  58. ifdef FPCDIR
  59. FPCMAKE=$(FPCDIR)/makefile.fpc
  60. else
  61. FPCMAKE=makefile.fpc
  62. endif
  63. endif
  64. override FPCMAKE:=$(strip $(wildcard $(FPCMAKE)))
  65. ifeq ($(FPCMAKE),)
  66. testfpcmake:
  67. @echo makefile.fpc not found!
  68. @echo Check the FPCMAKE and FPCDIR environment variables.
  69. @exit
  70. else
  71. include $(FPCMAKE)
  72. testfpcmake:
  73. endif
  74. #####################################################################
  75. # Dependencies
  76. #####################################################################
  77. #
  78. # PPU Tools
  79. #
  80. ppu$(PPUEXT): ppu.pas
  81. ppudump$(EXEEXT): ppudump.pp ppu$(PPUEXT)
  82. ppumove$(EXEEXT): ppumove.pp ppu$(PPUEXT)
  83. #
  84. # Pascal beautifier
  85. #
  86. ptop$(EXEEXT): ptop.pp ptopu$(PPUEXT)
  87. ptopu$(PPUEXT): ptopu.pp
  88. #
  89. # Clean also the .ppu's
  90. #
  91. extra_clean:
  92. $(DEL) ppu$(PPUEXT) ptopu$(PPUEXT)
  93. #
  94. # H2Pas
  95. #
  96. h2pas_all:
  97. $(MAKE) -C h2pas all
  98. h2pas_clean:
  99. $(MAKE) -C h2pas clean
  100. h2pas_install:
  101. $(MAKE) -C h2pas install
  102. #
  103. # $Log$
  104. # Revision 1.1 1999-05-12 16:11:39 peter
  105. # * moved
  106. #
  107. # Revision 1.14 1999/05/03 18:03:13 peter
  108. # * renamed mkdep -> ppdep
  109. # * removed obsolete units
  110. # * add .cod files
  111. #
  112. # Revision 1.13 1999/04/02 00:01:49 peter
  113. # + ptop to exeobjects
  114. #
  115. # Revision 1.12 1999/04/01 22:52:00 peter
  116. # * update for makefile.fpc
  117. #
  118. # Revision 1.1 1999/03/16 00:50:29 peter
  119. # + init
  120. #
  121. #