Makefile 4.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126
  1. #
  2. # "$Id: Makefile 8864 2011-07-19 04:49:30Z greg.ercolano $"
  3. #
  4. # FLUID 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. Distribution and use rights are outlined in
  9. # the file "COPYING" which should have been included with this file. If this
  10. # file is missing or damaged, see the license at:
  11. #
  12. # http://www.fltk.org/COPYING.php
  13. #
  14. # Please report all bugs and problems on the following page:
  15. #
  16. # http://www.fltk.org/str.php
  17. #
  18. CPPFILES = \
  19. CodeEditor.cxx \
  20. Fl_Function_Type.cxx \
  21. Fl_Group_Type.cxx \
  22. Fl_Menu_Type.cxx \
  23. Fl_Type.cxx \
  24. Fl_Widget_Type.cxx \
  25. Fl_Window_Type.cxx \
  26. Fluid_Image.cxx \
  27. about_panel.cxx \
  28. align_widget.cxx \
  29. alignment_panel.cxx \
  30. code.cxx \
  31. factory.cxx \
  32. file.cxx \
  33. fluid.cxx \
  34. function_panel.cxx \
  35. template_panel.cxx \
  36. undo.cxx \
  37. widget_panel.cxx
  38. ################################################################
  39. OBJECTS = $(CPPFILES:.cxx=.o)
  40. include ../makeinclude
  41. all: $(FLUID) fluid$(EXEEXT)
  42. fluid$(EXEEXT): $(OBJECTS) $(LIBNAME) $(FLLIBNAME) \
  43. $(IMGLIBNAME)
  44. echo Linking $@...
  45. $(CXX) $(ARCHFLAGS) $(LDFLAGS) -o $@ $(OBJECTS) $(LINKFLTKFORMS) $(LINKFLTKIMG) $(LDLIBS)
  46. $(OSX_ONLY) $(INSTALL_BIN) fluid fluid.app/Contents/MacOS
  47. fluid-shared$(EXEEXT): $(OBJECTS) ../src/$(DSONAME) ../src/$(FLDSONAME) \
  48. ../src/$(IMGDSONAME)
  49. echo Linking $@...
  50. $(CXX) $(ARCHFLAGS) $(LDFLAGS) -o $@ $(OBJECTS) $(LINKSHARED) $(LDLIBS)
  51. clean:
  52. -$(RM) *.o core.* *~ *.bck *.bck
  53. -$(RM) core fluid$(EXEEXT) fluid-shared$(EXEEXT)
  54. -$(RM) fluid.app/Contents/MacOS/fluid$(EXEEXT)
  55. depend: $(CPPFILES)
  56. makedepend -Y -I.. -f makedepend $(CPPFILES)
  57. # Automatically generated dependencies...
  58. include makedepend
  59. install: all
  60. echo "Installing FLUID in $(DESTDIR)$(bindir)..."
  61. -$(INSTALL_DIR) $(DESTDIR)$(bindir)
  62. $(INSTALL_BIN) $(FLUID) $(DESTDIR)$(bindir)/fluid$(EXEEXT)
  63. install-linux:
  64. -$(INSTALL_DIR) $(DESTDIR)/usr/share/applications
  65. $(INSTALL_DATA) fluid.desktop $(DESTDIR)/usr/share/applications
  66. for size in 16 32 48 64 128; do \
  67. if test ! -d $(DESTDIR)/usr/share/icons/hicolor/$${size}x$${size}/apps; then \
  68. $(INSTALL_DIR) $(DESTDIR)/usr/share/icons/hicolor/$${size}x$${size}/apps; \
  69. fi; \
  70. $(INSTALL_DATA) icons/fluid-$$size.png $(DESTDIR)/usr/share/icons/hicolor/$${size}x$${size}/apps/fluid.png; \
  71. done
  72. -$(INSTALL_DIR) $(DESTDIR)/usr/share/mimelnk/application
  73. $(INSTALL_DATA) x-fluid.desktop $(DESTDIR)/usr/share/mimelnk/application
  74. install-osx:
  75. echo Installing Fluid in $(DESTDIR)/Applications...
  76. -$(INSTALL_DIR) $(DESTDIR)/Applications/fluid.app
  77. -$(INSTALL_DIR) $(DESTDIR)/Applications/fluid.app/Contents
  78. $(INSTALL_DATA) fluid.app/Contents/Info.plist $(DESTDIR)/Applications/fluid.app/Contents/Info.plist
  79. $(INSTALL_DATA) fluid.app/Contents/PkgInfo $(DESTDIR)/Applications/fluid.app/Contents/PkgInfo
  80. -$(INSTALL_DIR) $(DESTDIR)/Applications/fluid.app/Contents/MacOS
  81. $(RM) $(DESTDIR)/Applications/fluid.app/Contents/MacOS/fluid
  82. $(LN) $(bindir)/fluid $(DESTDIR)/Applications/fluid.app/Contents/MacOS/fluid
  83. -$(INSTALL_DIR) $(DESTDIR)/Applications/fluid.app/Contents/Resources
  84. $(INSTALL_DATA) fluid.app/Contents/Resources/fluid.icns $(DESTDIR)/Applications/fluid.app/Contents/Resources
  85. uninstall:
  86. $(RM) $(DESTDIR)$(bindir)/fluid$(EXEEXT)
  87. uninstall-linux:
  88. $(RM) $(DESTDIR)/usr/share/applications/fluid.desktop
  89. $(RM) $(DESTDIR)/usr/share/icons/hicolor/*/fluid.png
  90. $(RM) $(DESTDIR)/usr/share/mimelnk/application/x-fluid.desktop
  91. uninstall-osx:
  92. $(RM) -r $(DESTDIR)/Applications/fluid.app
  93. #
  94. # Note: The rebuild target can only be used if you have the original .fl
  95. # files. This is normally only used by the FLTK maintainers...
  96. #
  97. rebuild:
  98. ./fluid -c about_panel.fl
  99. ./fluid -c alignment_panel.fl
  100. ./fluid -c function_panel.fl
  101. ./fluid -c print_panel.fl
  102. ./fluid -c template_panel.fl
  103. ./fluid -c widget_panel.fl
  104. #
  105. # End of "$Id: Makefile 8864 2011-07-19 04:49:30Z greg.ercolano $".
  106. #