Audio plugin host https://kx.studio/carla
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.

137 lines
3.1KB

  1. #!/usr/bin/make -f
  2. # Makefile for dgl #
  3. # ---------------- #
  4. # Created by falkTX
  5. #
  6. include ../../../Makefile.mk
  7. # --------------------------------------------------------------
  8. BUILD_C_FLAGS += -fvisibility=hidden -fPIC
  9. BUILD_CXX_FLAGS += -fvisibility=hidden -fPIC -I.
  10. OBJS = \
  11. src/App.cpp.o \
  12. src/Image.cpp.o \
  13. src/ImageAboutWindow.cpp.o \
  14. src/ImageButton.cpp.o \
  15. src/ImageKnob.cpp.o \
  16. src/ImageSlider.cpp.o \
  17. src/Geometry.cpp.o \
  18. src/Widget.cpp.o \
  19. src/Window.cpp.o
  20. OBJS_posix32 = \
  21. src/App.cpp.posix32.o \
  22. src/Image.cpp.posix32.o \
  23. src/ImageAboutWindow.cpp.posix32.o \
  24. src/ImageButton.cpp.posix32.o \
  25. src/ImageKnob.cpp.posix32.o \
  26. src/ImageSlider.cpp.posix32.o \
  27. src/Geometry.cpp.posix32.o \
  28. src/Widget.cpp.posix32.o \
  29. src/Window.cpp.posix32.o
  30. OBJS_posix64 = \
  31. src/App.cpp.posix64.o \
  32. src/Image.cpp.posix64.o \
  33. src/ImageAboutWindow.cpp.posix64.o \
  34. src/ImageButton.cpp.posix64.o \
  35. src/ImageKnob.cpp.posix64.o \
  36. src/ImageSlider.cpp.posix64.o \
  37. src/Geometry.cpp.posix64.o \
  38. src/Widget.cpp.posix64.o \
  39. src/Window.cpp.posix64.o
  40. OBJS_win32 = \
  41. src/App.cpp.win32.o \
  42. src/Image.cpp.win32.o \
  43. src/ImageAboutWindow.cpp.win32.o \
  44. src/ImageButton.cpp.win32.o \
  45. src/ImageKnob.cpp.win32.o \
  46. src/ImageSlider.cpp.win32.o \
  47. src/Geometry.cpp.win32.o \
  48. src/Widget.cpp.win32.o \
  49. src/Window.cpp.win32.o
  50. OBJS_win64 = \
  51. src/App.cpp.win64.o \
  52. src/Image.cpp.win64.o \
  53. src/ImageAboutWindow.cpp.win64.o \
  54. src/ImageButton.cpp.win64.o \
  55. src/ImageKnob.cpp.win64.o \
  56. src/ImageSlider.cpp.win64.o \
  57. src/Geometry.cpp.win64.o \
  58. src/Widget.cpp.win64.o \
  59. src/Window.cpp.win64.o
  60. ifeq ($(MACOS),true)
  61. OBJS += src/pugl/pugl_osx_extended.m.o
  62. OBJS_posix32 += src/pugl/pugl_osx_extended.m.posix32.o
  63. OBJS_posix64 += src/pugl/pugl_osx_extended.m.posix64.o
  64. endif
  65. # --------------------------------------------------------------
  66. all: ../../dgl.a
  67. posix32: ../../dgl.posix32.a
  68. posix64: ../../dgl.posix64.a
  69. win32: ../../dgl.win32.a
  70. win64: ../../dgl.win64.a
  71. # --------------------------------------------------------------
  72. ../../dgl.a: $(OBJS)
  73. $(AR) rs $@ $^
  74. ../../dgl.posix32.a: $(OBJS_posix32)
  75. $(AR) rs $@ $^
  76. ../../dgl.posix64.a: $(OBJS_posix64)
  77. $(AR) rs $@ $^
  78. ../../dgl.win32.a: $(OBJS_win32)
  79. $(AR) rs $@ $^
  80. ../../dgl.win64.a: $(OBJS_win64)
  81. $(AR) rs $@ $^
  82. ../../dgl.dll: $(OBJS)
  83. $(CXX) $^ -shared $(LINK_FLAGS) -lopengl32 -lgdi32 -o $@
  84. ../../dgl.dylib: $(OBJS)
  85. $(CXX) $^ -shared $(LINK_FLAGS) -framework OpenGL -framework Cocoa -o $@
  86. ../../dgl.so: $(OBJS)
  87. $(CXX) $^ -shared $(LINK_FLAGS) -lGL -lX11 -o $@
  88. # --------------------------------------------------------------
  89. %.cpp.o: %.cpp
  90. $(CXX) $< $(BUILD_CXX_FLAGS) -c -o $@
  91. %.cpp.posix32.o: %.cpp
  92. $(CXX) $< $(BUILD_CXX_FLAGS) $(32BIT_FLAGS) -c -o $@
  93. %.cpp.posix64.o: %.cpp
  94. $(CXX) $< $(BUILD_CXX_FLAGS) $(64BIT_FLAGS) -c -o $@
  95. %.cpp.win32.o: %.cpp
  96. $(CXX) $< $(BUILD_CXX_FLAGS) $(32BIT_FLAGS) -c -o $@
  97. %.cpp.win64.o: %.cpp
  98. $(CXX) $< $(BUILD_CXX_FLAGS) $(64BIT_FLAGS) -c -o $@
  99. %.m.o: %.m
  100. $(CC) $< $(BUILD_C_FLAGS) -objc -c -o $@
  101. # --------------------------------------------------------------
  102. clean:
  103. rm -f *.o src/*.o src/pugl/*.o ../../dgl.*
  104. debug:
  105. $(MAKE) DEBUG=true