Makefile 3.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143
  1. #
  2. # $Id$
  3. # Copyright (c) 1999 by the Free Pascal Development Team
  4. #
  5. # Makefile for <template> for Free Pascal
  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. DEFAULTFPCDIR=..
  18. #####################################################################
  19. # Real targets
  20. #####################################################################
  21. all: alldirs
  22. clean: cleanalldirs
  23. install: installalldirs
  24. #####################################################################
  25. # Include default makefile
  26. #####################################################################
  27. # test if FPCMAKE is still valid
  28. ifdef FPCMAKE
  29. ifeq ($(strip $(wildcard $(FPCMAKE))),)
  30. FPCDIR=
  31. FPCMAKE=
  32. endif
  33. endif
  34. ifndef FPCDIR
  35. ifdef DEFAULTFPCDIR
  36. FPCDIR=$(DEFAULTFPCDIR)
  37. endif
  38. endif
  39. ifndef FPCMAKE
  40. ifdef FPCDIR
  41. FPCMAKE=$(FPCDIR)/makefile.fpc
  42. else
  43. FPCMAKE=makefile.fpc
  44. endif
  45. endif
  46. override FPCMAKE:=$(strip $(wildcard $(FPCMAKE)))
  47. ifeq ($(FPCMAKE),)
  48. testfpcmake:
  49. @echo makefile.fpc not found!
  50. @echo Check the FPCMAKE and FPCDIR environment variables.
  51. @exit
  52. else
  53. include $(FPCMAKE)
  54. testfpcmake:
  55. endif
  56. #####################################################################
  57. # Targets
  58. #####################################################################
  59. # Construct real targets
  60. .PHONY: all clean install info alldirs\
  61. staticlib sharedlib libsclean \
  62. staticinstall sharedinstall libinstall
  63. clean: testfpcmake fpc_clean
  64. install: testfpcmake fpc_install
  65. info: testfpcmake fpc_info
  66. staticlib: testfpcmake fpc_staticlib
  67. sharedlib: testfpcmake fpc_sharedlib
  68. libsclean: testfpcmake fpc_libsclean
  69. staticinstall: testfpcmake fpc_staticinstall
  70. sharedinstall: testfpcmake fpc_sharedinstall
  71. libinstall: testfpcmake fpc_libinstall
  72. alldirs:
  73. $(MAKE) -C ibase
  74. $(MAKE) -C mysql
  75. $(MAKE) -C uncgi
  76. ifdef inlinux
  77. $(MAKE) -C utmp
  78. $(MAKE) -C inet
  79. $(MAKE) -C postgres
  80. $(MAKE) -C ncurses
  81. $(MAKE) -C forms
  82. $(MAKE) -C svgalib
  83. endif
  84. cleanalldirs:
  85. $(MAKE) -C ibase clean
  86. $(MAKE) -C mysql clean
  87. $(MAKE) -C uncgi clean
  88. ifdef inlinux
  89. $(MAKE) -C utmp clean
  90. $(MAKE) -C inet clean
  91. $(MAKE) -C postgres clean
  92. $(MAKE) -C ncurses clean
  93. $(MAKE) -C forms clean
  94. $(MAKE) -C svgalib clean
  95. endif
  96. installalldirs:
  97. $(MAKE) -C ibase DEFAULTUNITS=1 install
  98. $(MAKE) -C mysql DEFAULTUNITS=1 install
  99. $(MAKE) -C uncgi DEFAULTUNITS=1 install
  100. ifdef inlinux
  101. $(MAKE) -C utmp DEFAULTUNITS=1 install
  102. $(MAKE) -C inet DEFAULTUNITS=1 install
  103. $(MAKE) -C postgres DEFAULTUNITS=1 install
  104. $(MAKE) -C ncurses DEFAULTUNITS=1 install
  105. $(MAKE) -C forms DEFAULTUNITS=1 install
  106. $(MAKE) -C svgalib DEFAULTUNITS=1 install
  107. endif
  108. #
  109. # $Log$
  110. # Revision 1.2 1999-06-08 18:28:22 peter
  111. # * fixes for 0.99.12 release
  112. #
  113. #