You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

140 lines
3.6KB

  1. #
  2. # "$Id: Makefile 8427 2011-02-15 15:29:03Z mike $"
  3. #
  4. # Top-level makefile for the Fast Light Tool Kit (FLTK).
  5. #
  6. # Copyright 1998-2010 by Bill Spitzak and others.
  7. #
  8. # This library is free software; you can redistribute it and/or
  9. # modify it under the terms of the GNU Library General Public
  10. # License as published by the Free Software Foundation; either
  11. # version 2 of the License, or (at your option) any later version.
  12. #
  13. # This library is distributed in the hope that it will be useful,
  14. # but WITHOUT ANY WARRANTY; without even the implied warranty of
  15. # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  16. # Library General Public License for more details.
  17. #
  18. # You should have received a copy of the GNU Library General Public
  19. # License along with this library; if not, write to the Free Software
  20. # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
  21. # USA.
  22. #
  23. # Please report all bugs and problems on the following page:
  24. #
  25. # http://www.ntk.org/str.php
  26. #
  27. include makeinclude
  28. DIRS = $(IMAGEDIRS) src fluid documentation
  29. all: makeinclude ntk-config
  30. for dir in $(DIRS); do\
  31. echo "=== making $$dir ===";\
  32. (cd $$dir; $(MAKE) $(MFLAGS)) || exit 1;\
  33. done
  34. install: makeinclude
  35. -mkdir -p $(DESTDIR)$(bindir)
  36. $(RM) $(DESTDIR)$(bindir)/ntk-config
  37. $(INSTALL_SCRIPT) ntk-config $(DESTDIR)$(bindir)
  38. for dir in FL $(DIRS); do\
  39. echo "=== installing $$dir ===";\
  40. (cd $$dir; $(MAKE) $(MFLAGS) install) || exit 1;\
  41. done
  42. install-desktop: makeinclude
  43. cd documentation; $(MAKE) $(MFLAGS) $(INSTALL_DESKTOP)
  44. cd fluid; $(MAKE) $(MFLAGS) $(INSTALL_DESKTOP)
  45. cd test; $(MAKE) $(MFLAGS) $(INSTALL_DESKTOP)
  46. uninstall: makeinclude
  47. $(RM) $(DESTDIR)$(bindir)/ntk-config
  48. for dir in FL $(DIRS); do\
  49. echo "=== uninstalling $$dir ===";\
  50. (cd $$dir; $(MAKE) $(MFLAGS) uninstall) || exit 1;\
  51. done
  52. uninstall-desktop: makeinclude
  53. cd documentation; $(MAKE) $(MFLAGS) $(UNINSTALL_DESKTOP)
  54. cd fluid; $(MAKE) $(MFLAGS) $(UNINSTALL_DESKTOP)
  55. cd test; $(MAKE) $(MFLAGS) $(UNINSTALL_DESKTOP)
  56. depend: makeinclude
  57. for dir in $(DIRS); do\
  58. echo "=== making dependencies in $$dir ===";\
  59. (cd $$dir; $(MAKE) $(MFLAGS) depend) || exit 1;\
  60. done
  61. clean:
  62. -$(RM) core *.o
  63. for dir in $(DIRS); do\
  64. echo "=== cleaning $$dir ===";\
  65. (cd $$dir; $(MAKE) $(MFLAGS) clean) || exit 1;\
  66. done
  67. distclean: clean
  68. $(RM) config.*
  69. $(RM) ntk-config ntk.list makeinclude
  70. $(RM) ntk.spec
  71. $(RM) FL/Makefile
  72. $(RM) documentation/*.$(CAT1EXT)
  73. $(RM) documentation/*.$(CAT3EXT)
  74. $(RM) documentation/*.$(CAT6EXT)
  75. $(RM) documentation/ntk.ps
  76. $(RM) -r documentation/ntk.d
  77. for file in test/*.fl; do\
  78. $(RM) test/`basename $$file .fl`.cxx; \
  79. $(RM) test/`basename $$file .fl`.h; \
  80. done
  81. ntk-config: configure configh.in ntk-config.in
  82. if test -f config.status; then \
  83. ./config.status --recheck; \
  84. ./config.status; \
  85. else \
  86. ./configure; \
  87. fi
  88. touch config.h
  89. chmod +x ntk-config
  90. makeinclude: configure configh.in makeinclude.in
  91. if test -f config.status; then \
  92. ./config.status --recheck; \
  93. ./config.status; \
  94. else \
  95. ./configure; \
  96. fi
  97. touch config.h
  98. chmod +x ntk-config
  99. configure: configure.in
  100. autoconf
  101. portable-dist:
  102. epm -v -s ntk.xpm ntk
  103. native-dist:
  104. epm -v -f native ntk
  105. etags:
  106. etags FL/*.H FL/*.h src/*.cxx src/*.c src/*.h src/xutf8/*.h src/xutf8/*.c cairo/*.cxx fluid/*.h fluid/*.cxx test/*.h test/*.cxx
  107. #
  108. # Run the clang.llvm.org static code analysis tool on the C sources.
  109. # (at least checker-231 is required for scan-build to work this way)
  110. #
  111. .PHONY: clang clang-changes
  112. clang:
  113. $(RM) -r clang
  114. scan-build -V -k -o `pwd`/clang $(MAKE) $(MFLAGS) clean all
  115. clang-changes:
  116. scan-build -V -k -o `pwd`/clang $(MAKE) $(MFLAGS) all
  117. #
  118. # End of "$Id: Makefile 8427 2011-02-15 15:29:03Z mike $".
  119. #