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.

115 lines
2.8KB

  1. #!/usr/bin/make -f
  2. # Makefile for carla-engine #
  3. # ------------------------- #
  4. # Created by falkTX
  5. #
  6. include ../Makefile.mk
  7. # --------------------------------------------------------------
  8. BUILD_CXX_FLAGS += -D__UNIX_JACK__
  9. BUILD_CXX_FLAGS += $(shell pkg-config --cflags liblo)
  10. ifeq ($(HAVE_QT4),true)
  11. BUILD_CXX_FLAGS += $(shell pkg-config --cflags QtCore QtXml)
  12. else
  13. BUILD_CXX_FLAGS += $(shell pkg-config --cflags Qt5Core Qt5Xml)
  14. endif
  15. # --------------------------------------------------------------
  16. ifeq ($(CARLA_RTAUDIO_SUPPORT),true)
  17. BUILD_CXX_FLAGS += -DHAVE_GETTIMEOFDAY
  18. BUILD_CXX_FLAGS += -Irtaudio-4.0.12 -Irtaudio-4.0.12/include -Irtmidi-2.0.1
  19. ifeq ($(DEBUG),true)
  20. BUILD_CXX_FLAGS += -D__RTAUDIO_DEBUG__ -D__RTMIDI_DEBUG__
  21. endif
  22. endif
  23. # --------------------------------------------------------------
  24. ifeq ($(HAVE_ALSA),true)
  25. BUILD_CXX_FLAGS += $(shell pkg-config --cflags alsa) -D__LINUX_ALSA__ -D__LINUX_ALSASEQ__
  26. endif
  27. ifeq ($(HAVE_PULSEAUDIO),true)
  28. BUILD_CXX_FLAGS += $(shell pkg-config --cflags libpulse-simple) -D__LINUX_PULSE__
  29. endif
  30. ifeq ($(MACOS),true)
  31. BUILD_CXX_FLAGS += -D__MACOSX_CORE__
  32. endif
  33. ifeq ($(WIN32),true)
  34. BUILD_CXX_FLAGS += -D__WINDOWS_ASIO__ -D__WINDOWS_DS__ -D__WINDOWS_MM__
  35. endif
  36. PLUGIN_CXX_FLAGS = $(BUILD_CXX_FLAGS)
  37. PLUGIN_CXX_FLAGS += -Idistrho -I../../libs/distrho
  38. PLUGIN_CXX_FLAGS += -DWANT_PLUGIN
  39. # --------------------------------------------------------------
  40. OBJSp = \
  41. CarlaEngine.cpp.o \
  42. CarlaEngineOsc.cpp.o \
  43. CarlaEngineThread.cpp.o \
  44. CarlaEngineNative.cpp.o
  45. OBJS = $(OBJSp) \
  46. CarlaEngineBridge.cpp.o \
  47. CarlaEngineJack.cpp.o \
  48. CarlaEngineRtAudio.cpp.o
  49. ifeq ($(CARLA_RTAUDIO_SUPPORT),true)
  50. OBJS += \
  51. rtaudio-4.0.12/RtAudio.cpp.o \
  52. rtmidi-2.0.1/RtMidi.cpp.o
  53. ifeq ($(WIN32),true)
  54. OBJS += \
  55. rtaudio-4.0.12/include/asio.cpp.o \
  56. rtaudio-4.0.12/include/asiodrivers.cpp.o \
  57. rtaudio-4.0.12/include/asiolist.cpp.o \
  58. rtaudio-4.0.12/include/iasiothiscallresolver.cpp.o
  59. endif
  60. endif
  61. TARGET = ../libcarla_engine.a
  62. TARGETp = ../libcarla_engine_plugin.a
  63. # --------------------------------------------------------------
  64. all: $(TARGET) $(TARGETp)
  65. clean:
  66. rm -f $(OBJS) $(OBJSp) $(TARGET) $(TARGETp)
  67. debug:
  68. $(MAKE) DEBUG=true
  69. # --------------------------------------------------------------
  70. HEADERS = \
  71. ../CarlaBackend.hpp ../CarlaEngine.hpp ../CarlaPlugin.hpp \
  72. CarlaEngineInternal.hpp CarlaEngineOsc.hpp CarlaEngineThread.hpp
  73. %.cpp.o: %.cpp $(HEADERS)
  74. $(CXX) $< $(BUILD_CXX_FLAGS) -c -o $@
  75. %.cpp.dssi.o: %.cpp $(HEADERS)
  76. $(CXX) $< $(PLUGIN_CXX_FLAGS) -DDISTRHO_PLUGIN_TARGET_DSSI -c -o $@
  77. %.cpp.lv2.o: %.cpp $(HEADERS)
  78. $(CXX) $< $(PLUGIN_CXX_FLAGS) -DDISTRHO_PLUGIN_TARGET_LV2 -c -o $@
  79. %.cpp.vst.o: %.cpp $(HEADERS)
  80. $(CXX) $< $(PLUGIN_CXX_FLAGS) -DDISTRHO_PLUGIN_TARGET_VST -c -o $@
  81. $(TARGET): $(OBJS)
  82. $(AR) rs $@ $^
  83. $(TARGETp): $(OBJSp)
  84. $(AR) rs $@ $^