DISTRHO ProM
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.

70 lines
1.9KB

  1. #!/usr/bin/make -f
  2. # Makefile for DISTRHO Plugins #
  3. # ---------------------------- #
  4. # Created by falkTX
  5. #
  6. # NAME, OBJS_DSP and OBJS_UI have been defined before
  7. include ../../Makefile.mk
  8. # --------------------------------------------------------------
  9. # Basic setup
  10. TARGET_DIR = ../../bin
  11. BUILD_C_FLAGS += -I.
  12. BUILD_CXX_FLAGS += -I. -I../../dpf/distrho -I../../dpf/dgl
  13. # --------------------------------------------------------------
  14. # Enable all possible plugin types
  15. all: lv2 vst
  16. # --------------------------------------------------------------
  17. # Set plugin binary file targets
  18. lv2 = $(TARGET_DIR)/$(NAME).lv2/$(NAME).$(EXT)
  19. vst = $(TARGET_DIR)/$(NAME)-vst.$(EXT)
  20. # TODO: MacOS VST bundle
  21. # --------------------------------------------------------------
  22. # Set distrho code files
  23. DISTRHO_PLUGIN_FILES = ../../dpf/distrho/DistrhoPluginMain.cpp
  24. DISTRHO_UI_FILES = ../../dpf/distrho/DistrhoUIMain.cpp ../../dpf/libdgl.a
  25. # --------------------------------------------------------------
  26. # Common
  27. %.c.o: %.c
  28. $(CC) $< $(BUILD_C_FLAGS) -c -o $@
  29. %.cpp.o: %.cpp
  30. $(CXX) $< $(BUILD_CXX_FLAGS) -c -o $@
  31. clean:
  32. rm -f *.o
  33. rm -rf $(TARGET_DIR)/$(NAME)-* $(TARGET_DIR)/$(NAME).lv2/
  34. # --------------------------------------------------------------
  35. # LV2
  36. lv2: $(lv2)
  37. $(lv2): $(OBJS_DSP) $(OBJS_UI) $(DISTRHO_PLUGIN_FILES) $(DISTRHO_UI_FILES)
  38. mkdir -p $(shell dirname $@)
  39. $(CXX) $^ $(BUILD_CXX_FLAGS) $(LINK_FLAGS) $(DGL_LIBS) $(shell pkg-config --libs libprojectM) -lpthread $(SHARED) -DDISTRHO_PLUGIN_TARGET_LV2 -o $@
  40. # --------------------------------------------------------------
  41. # VST
  42. vst: $(vst)
  43. $(vst): $(OBJS_DSP) $(OBJS_UI) $(DISTRHO_PLUGIN_FILES) $(DISTRHO_UI_FILES)
  44. mkdir -p $(shell dirname $@)
  45. $(CXX) $^ $(BUILD_CXX_FLAGS) $(LINK_FLAGS) $(DGL_LIBS) $(shell pkg-config --libs libprojectM) -lpthread $(SHARED) -DDISTRHO_PLUGIN_TARGET_VST -o $@
  46. # --------------------------------------------------------------