DISTRHO Plugin Framework
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.

86 lines
1.8KB

  1. #!/usr/bin/make -f
  2. # Makefile for dgl #
  3. # ---------------- #
  4. # Created by falkTX
  5. #
  6. include Makefile.mk
  7. # --------------------------------------------------------------
  8. BUILD_C_FLAGS += $(DGL_FLAGS) -I.
  9. BUILD_CXX_FLAGS += $(DGL_FLAGS) -I.
  10. LINK_FLAGS += $(DGL_LIBS)
  11. # --------------------------------------------------------------
  12. OBJS = \
  13. src/App.cpp.o \
  14. src/Geometry.cpp.o \
  15. src/Image.cpp.o \
  16. src/ImageAboutWindow.cpp.o \
  17. src/ImageButton.cpp.o \
  18. src/ImageKnob.cpp.o \
  19. src/ImageSlider.cpp.o \
  20. src/Widget.cpp.o \
  21. src/Window.cpp.o
  22. # freetype-gl
  23. # OBJS += \
  24. # src/freetype-gl/font-manager.c.o \
  25. # src/freetype-gl/mat4.c.o \
  26. # src/freetype-gl/shader.c.o \
  27. # src/freetype-gl/text-buffer.c.o \
  28. # src/freetype-gl/texture-atlas.c.o \
  29. # src/freetype-gl/texture-font.c.o \
  30. # src/freetype-gl/vector.c.o \
  31. # src/freetype-gl/vertex-attribute.c.o \
  32. # src/freetype-gl/vertex-buffer.c.o
  33. ifeq ($(MACOS),true)
  34. OBJS += src/pugl/pugl_osx_extended.m.o
  35. endif
  36. TARGET = ../libdgl.a
  37. # --------------------------------------------------------------
  38. all: $(TARGET)
  39. # --------------------------------------------------------------
  40. ../libdgl.a: $(OBJS)
  41. $(RM) $@
  42. $(AR) crs $@ $^
  43. ../libdgl.dll: $(OBJS)
  44. # -Wl,--output-def,$@.def,--out-implib,$@.a
  45. $(CXX) $^ -shared $(LINK_FLAGS) -o $@
  46. ../libdgl.dylib: $(OBJS)
  47. $(CXX) $^ -dynamiclib $(LINK_FLAGS) -o $@
  48. ../libdgl.so: $(OBJS)
  49. $(CXX) $^ -shared $(LINK_FLAGS) -o $@
  50. # --------------------------------------------------------------
  51. %.c.o: %.c
  52. $(CC) $< $(BUILD_C_FLAGS) -c -o $@
  53. %.cpp.o: %.cpp
  54. $(CXX) $< $(BUILD_CXX_FLAGS) -c -o $@
  55. %.m.o: %.m
  56. $(CC) $< $(BUILD_C_FLAGS) -ObjC -c -o $@
  57. # --------------------------------------------------------------
  58. clean:
  59. $(RM) src/*.o src/pugl/*.o src/freetype-gl/*.o ../libdgl.*
  60. debug:
  61. $(MAKE) DEBUG=true
  62. # --------------------------------------------------------------