Makefile.fpc 1.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091
  1. #
  2. # Makefile.fpc for FP IDE
  3. #
  4. [targets]
  5. programs=fp
  6. rst=fpstrings
  7. [dirs]
  8. fpcdir=../..
  9. [require]
  10. options=-Sg
  11. packages=api fv gdbint
  12. [libs]
  13. libgcc=1
  14. [postsettings]
  15. # when making a full version include the compiler
  16. ifeq ($(FULL),1)
  17. override UNITDIR+=../../compiler
  18. else
  19. override UNITDIR+=../fake/compiler
  20. endif
  21. # when including debugger include the gdbinterface
  22. ifndef GDBINT
  23. GDBINT=gdbint
  24. endif
  25. ifeq ($(GDB),1)
  26. GDBLIBDIR+=$(PACKAGESDIR)/$(GDBINT)/libgdb/$(OS_TARGET)
  27. GDBOBJDIR+=$(PACKAGESDIR)/$(GDBINT)/libgdb/$(OS_TARGET)
  28. ifeq ($(OS_TARGET),go32v2)
  29. ifneq ($(DJDIR),)
  30. GDBLIBDIR+=$(DJDIR)/lib
  31. endif
  32. endif
  33. ifeq ($(wildcard $(addsuffix /libgdb.a,$(GDBLIBDIR))),)
  34. override GDB=0
  35. endif
  36. endif
  37. ifeq ($(GDB),1)
  38. # The gdbint is already included due the gdbint package dependency
  39. override LIBDIR+=$(GDBLIBDIR)
  40. override OBJDIR+=$(GDBOBJDIR)
  41. else
  42. override UNITDIR+=../fake/gdb
  43. endif
  44. ifeq ($(FULL),1)
  45. override OPT+=-dBrowserCol -dGDB
  46. endif
  47. [rules]
  48. .PHONY: gdb full fullgdb clean_compiler clean
  49. clean: fpc_cleanall
  50. distclean: clean
  51. fp$(EXEEXT): $(wildcard *.pas) $(wildcard *.inc)
  52. gdb:
  53. $(MAKE) all GDB=1
  54. full:
  55. $(MAKE) all FULL=1
  56. fullgdb:
  57. $(MAKE) all FULL=1 GDB=1
  58. # This is necessary because we don't have all units separate in the
  59. # units targets
  60. clean: fpc_cleanall
  61. #
  62. # Installation
  63. #
  64. install: fpc_install
  65. $(INSTALL) $(wildcard *.pt) $(wildcard *.tdf) readme.txt $(BININSTALLDIR)
  66. #
  67. # Misc
  68. #
  69. clean_compiler:
  70. $(MAKE) -C ../../compiler clean