Makefile 2.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273
  1. #
  2. # Makefile for supertux-editor.exe
  3. # Copyright (C) 2008 Christoph Sommer <christoph.sommer@2008.expires.deltadevelopment.de>
  4. #
  5. # This program is free software; you can redistribute it and/or modify
  6. # it under the terms of the GNU General Public License as published by
  7. # the Free Software Foundation; either version 2 of the License, or
  8. # (at your option) any later version.
  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. See the
  13. # GNU General Public License for more details.
  14. #
  15. # You should have received a copy of the GNU General Public License
  16. # along with this program; if not, write to the Free Software
  17. # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
  18. #
  19. GMCS?=gmcs
  20. GMCSFLAGS?=-debug -warn:4 -nowarn:1591 -unsafe
  21. ifeq ($(VERBOSE),1)
  22. Q=
  23. else
  24. Q=@
  25. endif
  26. .phony: all clean
  27. all: supertux-editor.exe
  28. clean:
  29. rm -f *.dll *.pkg.dummy supertux-editor.exe
  30. gtkgl-sharp.dll: \
  31. $(wildcard gtkgl-sharp/*.cs) \
  32. gtk-sharp-2.0.pkg.dummy \
  33. Lisp.dll: \
  34. $(wildcard Lisp/*.cs) \
  35. Resources.dll: \
  36. $(wildcard Resources/*.cs) \
  37. libeditor.dll: \
  38. $(wildcard libeditor/DataStructures/*.cs) $(wildcard libeditor/Libs/*.cs) $(wildcard libeditor/SceneGraph/*.cs) $(wildcard libeditor/Drawing/*.cs) $(wildcard libeditor/*.cs) \
  39. $(wildcard libeditor/resources/*.png) $(wildcard libeditor/resources/*.glade) \
  40. Resources.dll gtkgl-sharp.dll \
  41. gtk-sharp-2.0.pkg.dummy glade-sharp-2.0.pkg.dummy
  42. LispReader.dll: \
  43. $(wildcard LispReader/*.cs) \
  44. Lisp.dll libeditor.dll \
  45. supertux-editor.exe: \
  46. $(wildcard src/*.cs) $(wildcard src/Sprites/*.cs) $(wildcard src/Tiles/*.cs) $(wildcard src/PropertyEditors/*.cs) $(wildcard src/LevelObjects/*.cs) $(wildcard src/Undo/*.cs) $(wildcard src/Editors/*.cs) \
  47. $(wildcard src/resources/*.png) $(wildcard src/resources/*.glade) \
  48. Lisp.dll Resources.dll LispReader.dll libeditor.dll gtkgl-sharp.dll \
  49. gtk-sharp-2.0.pkg.dummy glade-sharp-2.0.pkg.dummy \
  50. %.pkg.dummy:
  51. $(Q)touch $@
  52. %.exe:
  53. @echo MonoCSharp $@
  54. $(Q)$(GMCS) $(GMCSFLAGS) $(patsubst %.pkg.dummy,-pkg:%,$(filter %.pkg.dummy, $^)) -out:$@ -doc:$(patsubst %.dll,%.dll.xml,$@) -target:exe $(patsubst %,-r:%,$(filter %.dll, $^)) $(patsubst %,-resource:%,$(filter %.png %.glade, $^)) $(filter %.cs, $^)
  55. %.dll:
  56. @echo MonoCSharp $@
  57. $(Q)$(GMCS) $(GMCSFLAGS) $(patsubst %.pkg.dummy,-pkg:%,$(filter %.pkg.dummy, $^)) -out:$@ -doc:$(patsubst %.dll,%.dll.xml,$@) -target:library $(patsubst %,-r:%,$(filter %.dll, $^)) $(patsubst %,-resource:%,$(filter %.png %.glade, $^)) $(filter %.cs, $^)