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.

634 lines
20KB

  1. #!/usr/bin/make -f
  2. # Makefile for carla-bridges #
  3. # -------------------------- #
  4. # Created by falkTX
  5. #
  6. include ../Makefile.mk
  7. # --------------------------------------------------------------
  8. # TODO: remove in favour of juce gui stuff
  9. QT5_UI_FLAGS = $(shell pkg-config --cflags Qt5Core Qt5Gui Qt5Widgets)
  10. QT5_UI_LIBS = $(shell pkg-config --libs Qt5Core Qt5Gui Qt5Widgets)
  11. # --------------------------------------------------------------
  12. BUILD_CXX_FLAGS += -DBUILD_BRIDGE
  13. BUILD_CXX_FLAGS += -I. -I../backend -I../includes -I../modules -I../modules/theme -I../utils
  14. BUILD_CXX_FLAGS += $(shell pkg-config --cflags liblo)
  15. LINK_FLAGS += $(shell pkg-config --libs liblo)
  16. # --------------------------------------------------------------
  17. # Plugin bridges
  18. BUILD_PLUGIN_FLAGS = $(BUILD_CXX_FLAGS) -DBUILD_BRIDGE_PLUGIN
  19. BUILD_PLUGIN_FLAGS += -I../backend/engine -I../backend/plugin
  20. LINK_PLUGIN_FLAGS = $(LINK_FLAGS) -lpthread
  21. ifeq ($(CARLA_PLUGIN_SUPPORT),true)
  22. BUILD_PLUGIN_FLAGS += -DWANT_LADSPA -DWANT_DSSI -DWANT_LV2 -DWANT_VST
  23. ifeq ($(CARLA_VESTIGE_HEADER),true)
  24. BUILD_PLUGIN_FLAGS += -DVESTIGE_HEADER
  25. endif
  26. endif
  27. LINK_PLUGIN_FLAGS += $(JUCE_AUDIO_BASICS_LIBS)
  28. LINK_PLUGIN_FLAGS += $(JUCE_CORE_LIBS)
  29. LINK_PLUGIN_FLAGS += $(JUCE_DATA_STRUCTURES_LIBS)
  30. LINK_PLUGIN_FLAGS += $(JUCE_EVENTS_LIBS)
  31. LINK_PLUGIN_FLAGS += $(JUCE_GRAPHICS_LIBS)
  32. LINK_PLUGIN_FLAGS += $(JUCE_GUI_BASICS_LIBS)
  33. # --------------------------------------------------------------
  34. # Plugin bridges (POSIX)
  35. POSIX_BUILD_FLAGS = $(BUILD_PLUGIN_FLAGS)
  36. POSIX_32BIT_FLAGS = $(32BIT_FLAGS) -L/usr/lib32 -L/usr/lib/i386-linux-gnu
  37. POSIX_64BIT_FLAGS = $(64BIT_FLAGS) -L/usr/lib64 -L/usr/lib/x86_64-linux-gnu
  38. POSIX_LINK_FLAGS = $(LINK_PLUGIN_FLAGS) -ldl
  39. ifneq ($(MACOS),true)
  40. POSIX_LINK_FLAGS += -lrt
  41. endif
  42. # --------------------------------------------------------------
  43. # Plugin bridges (Windows)
  44. WIN_BUILD_FLAGS = $(BUILD_PLUGIN_FLAGS) -DJACKBRIDGE_EXPORT
  45. WIN_32BIT_FLAGS = $(32BIT_FLAGS)
  46. WIN_64BIT_FLAGS = $(64BIT_FLAGS)
  47. WIN_LINK_FLAGS = $(LINK_PLUGIN_FLAGS) -L../modules
  48. # --------------------------------------------------------------
  49. # Plugin bridges (Native)
  50. NATIVE_BUILD_FLAGS = $(POSIX_BUILD_FLAGS) -DWANT_NATIVE
  51. NATIVE_LINK_FLAGS = $(POSIX_LINK_FLAGS)
  52. ifeq ($(HAVE_FLUIDSYNTH),true)
  53. NATIVE_BUILD_FLAGS += -DWANT_FLUIDSYNTH
  54. NATIVE_BUILD_FLAGS += $(shell pkg-config --cflags fluidsynth)
  55. NATIVE_LINK_FLAGS += $(shell pkg-config --libs fluidsynth)
  56. endif
  57. ifeq ($(HAVE_LINUXSAMPLER),true)
  58. NATIVE_BUILD_FLAGS += -DWANT_LINUXSAMPLER
  59. NATIVE_BUILD_FLAGS += $(shell pkg-config --cflags linuxsampler)
  60. NATIVE_LINK_FLAGS += $(shell pkg-config --libs linuxsampler)
  61. endif
  62. ifeq ($(HAVE_AF_DEPS),true)
  63. NATIVE_BUILD_FLAGS += -DWANT_AUDIOFILE
  64. NATIVE_LINK_FLAGS += $(shell pkg-config --libs sndfile)
  65. ifeq ($(HAVE_FFMPEG),true)
  66. NATIVE_BUILD_FLAGS += -DHAVE_FFMPEG
  67. NATIVE_LINK_FLAGS += $(shell pkg-config --libs libavcodec libavformat libavutil)
  68. endif
  69. endif
  70. ifeq ($(HAVE_MF_DEPS),true)
  71. NATIVE_BUILD_FLAGS += -DWANT_MIDIFILE
  72. NATIVE_LINK_FLAGS += $(shell pkg-config --libs smf)
  73. endif
  74. ifeq ($(HAVE_OPENGL),true)
  75. NATIVE_BUILD_FLAGS += -DWANT_OPENGL
  76. NATIVE_LINK_FLAGS += $(DGL_LIBS)
  77. endif
  78. ifeq ($(HAVE_ZYN_DEPS),true)
  79. NATIVE_BUILD_FLAGS += -DWANT_ZYNADDSUBFX
  80. NATIVE_LINK_FLAGS += $(shell pkg-config --libs fftw3 mxml zlib)
  81. ifeq ($(HAVE_ZYN_UI_DEPS),true)
  82. NATIVE_LINK_FLAGS += $(shell pkg-config --libs ntk_images ntk)
  83. endif
  84. endif
  85. # --------------------------------------------------------------
  86. # UI bridges
  87. BUILD_UI_FLAGS = $(BUILD_CXX_FLAGS) -DBUILD_BRIDGE_UI
  88. LINK_UI_FLAGS = $(LINK_FLAGS) -ldl
  89. LINK_UI_FLAGS += $(JUCE_CORE_LIBS)
  90. BUILD_UI_LV2_FLAGS = $(BUILD_UI_FLAGS) -DBRIDGE_LV2
  91. BUILD_UI_VST_FLAGS = $(BUILD_UI_FLAGS) -DBRIDGE_VST
  92. ifeq ($(CARLA_VESTIGE_HEADER),true)
  93. BUILD_UI_VST_FLAGS += -DVESTIGE_HEADER
  94. endif
  95. BUILD_UI_LV2_GTK2_FLAGS = $(BUILD_UI_LV2_FLAGS) -DBRIDGE_GTK2 -DBRIDGE_LV2_GTK2 $(shell pkg-config --cflags gtk+-2.0 Qt5Core)
  96. LINK_UI_LV2_GTK2_FLAGS = $(LINK_UI_FLAGS) $(shell pkg-config --libs gtk+-2.0 Qt5Core)
  97. BUILD_UI_LV2_GTK3_FLAGS = $(BUILD_UI_LV2_FLAGS) -DBRIDGE_GTK3 -DBRIDGE_LV2_GTK3 $(shell pkg-config --cflags gtk+-3.0 Qt5Core)
  98. LINK_UI_LV2_GTK3_FLAGS = $(LINK_UI_FLAGS) $(shell pkg-config --libs gtk+-3.0 Qt5Core)
  99. BUILD_UI_LV2_QT4_FLAGS = $(BUILD_UI_LV2_FLAGS) -DBRIDGE_QT4 -DBRIDGE_LV2_QT4 $(shell pkg-config --cflags QtCore QtGui)
  100. LINK_UI_LV2_QT4_FLAGS = $(LINK_UI_FLAGS) $(shell pkg-config --libs QtCore QtGui)
  101. BUILD_UI_LV2_QT5_FLAGS = $(BUILD_UI_LV2_FLAGS) -DBRIDGE_QT5 -DBRIDGE_LV2_QT5 $(shell pkg-config --cflags Qt5Core Qt5Gui Qt5Widgets)
  102. LINK_UI_LV2_QT5_FLAGS = $(LINK_UI_FLAGS) $(shell pkg-config --libs Qt5Core Qt5Gui Qt5Widgets)
  103. BUILD_UI_LV2_COCOA_FLAGS = $(BUILD_UI_LV2_FLAGS) -DBRIDGE_COCOA -DBRIDGE_LV2_COCOA $(QT5_UI_FLAGS)
  104. LINK_UI_LV2_COCOA_FLAGS = $(LINK_UI_FLAGS) $(QT5_UI_LIBS)
  105. BUILD_UI_LV2_WIN32_FLAGS = $(BUILD_UI_LV2_FLAGS) -DBRIDGE_HWND -DBRIDGE_LV2_WIN32 $(QT5_UI_FLAGS)
  106. LINK_UI_LV2_WIN32_FLAGS = $(LINK_FLAGS) $(QT5_UI_LIBS) $(EXTRA_LIBS) -mwindows -lwinspool -lole32 -luuid -limm32 -lshell32 -lws2_32 -static
  107. BUILD_UI_LV2_X11_FLAGS = $(BUILD_UI_LV2_FLAGS) -DBRIDGE_X11 -DBRIDGE_LV2_X11 $(QT5_UI_FLAGS)
  108. LINK_UI_LV2_X11_FLAGS = $(LINK_UI_FLAGS) $(QT5_UI_LIBS)
  109. BUILD_UI_VST_MAC_FLAGS = $(BUILD_UI_VST_FLAGS) -DBRIDGE_MAC -DBRIDGE_VST_MAC $(QT5_UI_FLAGS)
  110. LINK_UI_VST_MAC_FLAGS = $(LINK_UI_FLAGS) $(QT5_UI_LIBS)
  111. BUILD_UI_VST_HWND_FLAGS = $(BUILD_UI_VST_FLAGS) -DBRIDGE_HWND -DBRIDGE_VST_HWND $(QT5_UI_FLAGS)
  112. LINK_UI_VST_HWND_FLAGS = $(LINK_FLAGS) $(QT5_UI_LIBS) $(EXTRA_LIBS) -mwindows -lwinspool -lole32 -luuid -limm32 -lshell32 -lws2_32 -static
  113. BUILD_UI_VST_X11_FLAGS = $(BUILD_UI_VST_FLAGS) -DBRIDGE_X11 -DBRIDGE_VST_X11 $(QT5_UI_FLAGS)
  114. LINK_UI_VST_X11_FLAGS = $(LINK_UI_FLAGS) $(QT5_UI_LIBS)
  115. # --------------------------------------------------------------
  116. TARGETS = native
  117. ifeq ($(CARLA_PLUGIN_SUPPORT),true)
  118. ifeq ($(HAVE_GTK2),true)
  119. TARGETS += ui_lv2-gtk2
  120. endif
  121. ifeq ($(HAVE_GTK3),true)
  122. TARGETS += ui_lv2-gtk3
  123. endif
  124. ifeq ($(HAVE_QT4),true)
  125. TARGETS += ui_lv2-qt4
  126. else
  127. ifeq ($(HAVE_QT5),true)
  128. TARGETS += ui_lv2-qt5
  129. endif
  130. endif
  131. TARGETS += ui_lv2-x11
  132. TARGETS += ui_vst-x11
  133. endif
  134. ifeq ($(WIN32),true)
  135. TARGETS = carla-bridge-win32.exe
  136. TARGETS += carla-bridge-win64.exe
  137. TARGETS += carla-bridge-lv2-windows.exe
  138. TARGETS += carla-bridge-vst-hwnd.exe
  139. endif
  140. # --------------------------------------------------------------
  141. all: $(TARGETS)
  142. ui_lv2-gtk2: carla-bridge-lv2-gtk2
  143. ui_lv2-gtk3: carla-bridge-lv2-gtk3
  144. ui_lv2-qt4: carla-bridge-lv2-qt4
  145. ui_lv2-qt5: carla-bridge-lv2-qt5
  146. ui_lv2-cocoa: carla-bridge-lv2-cocoa
  147. ui_lv2-win32: carla-bridge-lv2-windows.exe
  148. ui_lv2-x11: carla-bridge-lv2-x11
  149. ui_vst-mac: carla-bridge-vst-mac
  150. ui_vst-hwnd: carla-bridge-vst-hwnd.exe
  151. ui_vst-x11: carla-bridge-vst-x11
  152. # --------------------------------------------------------------
  153. native: carla-bridge-native
  154. posix32: carla-bridge-posix32
  155. posix64: carla-bridge-posix64
  156. win32: carla-bridge-win32.exe
  157. win64: carla-bridge-win64.exe
  158. # --------------------------------------------------------------
  159. # UI common
  160. OBJS_UI_LV2_LIBS = \
  161. ../modules/lilv.a \
  162. ../modules/juce_core.a
  163. OBJS_UI_VST_LIBS = \
  164. ../modules/juce_core.a
  165. %__lv2.o: %.cpp
  166. $(CXX) $< $(BUILD_UI_LV2_FLAGS) -c -o $@
  167. %__vst.o: %.cpp
  168. $(CXX) $< $(BUILD_UI_VST_FLAGS) -c -o $@
  169. resources.cpp: ../../resources/resources-theme.qrc
  170. $(RCC) $< -o $@
  171. resources.qt4.cpp: ../../resources/resources-theme.qrc
  172. $(RCC_QT4) $< -o $@
  173. CarlaBridgeToolkitQt.moc: CarlaBridgeToolkitQt.cpp
  174. $(MOC) $< -DMOC_PARSING -o $@
  175. CarlaBridgeToolkitQt4.moc: CarlaBridgeToolkitQt.cpp
  176. $(MOC_QT4) $< -DMOC_PARSING -o $@
  177. # --------------------------------------------------------------
  178. # ui_lv2-gtk2
  179. OBJS_UI_LV2_GTK2 = CarlaBridgeUI-LV2__lv2-gtk2.o \
  180. CarlaBridgeClient__lv2.o CarlaBridgeOsc__lv2.o \
  181. CarlaBridgeToolkit__lv2.o CarlaBridgeToolkitGtk__lv2-gtk2.o
  182. carla-bridge-lv2-gtk2: $(OBJS_UI_LV2_GTK2) $(OBJS_UI_LV2_LIBS)
  183. $(CXX) $^ $(LINK_UI_LV2_GTK2_FLAGS) -o $@
  184. %__lv2-gtk2.o: %.cpp
  185. $(CXX) $< $(BUILD_UI_LV2_GTK2_FLAGS) -c -o $@
  186. # --------------------------------------------------------------
  187. # ui_lv2-gtk3
  188. OBJS_UI_LV2_GTK3 = CarlaBridgeUI-LV2__lv2-gtk3.o \
  189. CarlaBridgeClient__lv2.o CarlaBridgeOsc__lv2.o \
  190. CarlaBridgeToolkit__lv2.o CarlaBridgeToolkitGtk__lv2-gtk3.o
  191. carla-bridge-lv2-gtk3: $(OBJS_UI_LV2_GTK3) $(OBJS_UI_LV2_LIBS)
  192. $(CXX) $^ $(LINK_UI_LV2_GTK3_FLAGS) -o $@
  193. %__lv2-gtk3.o: %.cpp
  194. $(CXX) $< $(BUILD_UI_LV2_GTK3_FLAGS) -c -o $@
  195. # --------------------------------------------------------------
  196. # ui_lv2-qt4
  197. OBJS_UI_LV2_QT4 = CarlaBridgeUI-LV2__lv2-qt4.o \
  198. CarlaBridgeClient__lv2.o CarlaBridgeOsc__lv2.o \
  199. CarlaBridgeToolkit__lv2.o CarlaBridgeToolkitQt__lv2-qt4.o
  200. carla-bridge-lv2-qt4: $(OBJS_UI_LV2_QT4) $(OBJS_UI_LV2_LIBS) ../modules/theme.qt4.a
  201. $(CXX) $^ $(LINK_UI_LV2_QT4_FLAGS) -o $@
  202. %__lv2-qt4.o: %.cpp CarlaBridgeToolkitQt4.moc resources.qt4.cpp
  203. $(CXX) $< $(BUILD_UI_LV2_QT4_FLAGS) -c -o $@
  204. # --------------------------------------------------------------
  205. # ui_lv2-qt5
  206. OBJS_UI_LV2_QT5 = CarlaBridgeUI-LV2__lv2-qt5.o \
  207. CarlaBridgeClient__lv2.o CarlaBridgeOsc__lv2.o \
  208. CarlaBridgeToolkit__lv2.o CarlaBridgeToolkitQt__lv2-qt5.o
  209. carla-bridge-lv2-qt5: $(OBJS_UI_LV2_QT5) $(OBJS_UI_LV2_LIBS) ../modules/theme.a
  210. $(CXX) $^ $(LINK_UI_LV2_QT5_FLAGS) -o $@
  211. %__lv2-qt5.o: %.cpp CarlaBridgeToolkitQt.moc resources.cpp
  212. $(CXX) $< $(BUILD_UI_LV2_QT5_FLAGS) -c -o $@
  213. # --------------------------------------------------------------
  214. # ui_lv2-cocoa
  215. OBJS_UI_LV2_COCOA = CarlaBridgeUI-LV2__lv2-cocoa.o \
  216. CarlaBridgeClient__lv2.o CarlaBridgeOsc__lv2.o \
  217. CarlaBridgeToolkit__lv2.o CarlaBridgeToolkitQt__lv2-cocoa.o
  218. carla-bridge-lv2-cocoa: $(OBJS_UI_LV2_COCOA) $(OBJS_UI_LV2_LIBS) ../modules/theme.a
  219. $(CXX) $^ $(LINK_UI_LV2_COCOA_FLAGS) -o $@
  220. %__lv2-cocoa.o: %.cpp CarlaBridgeToolkitQt.moc resources.cpp
  221. $(CXX) $< $(BUILD_UI_LV2_COCOA_FLAGS) -c -o $@
  222. # --------------------------------------------------------------
  223. # ui_lv2-windows
  224. OBJS_UI_LV2_WIN32 = CarlaBridgeUI-LV2__lv2-windows.o \
  225. CarlaBridgeClient__lv2.o CarlaBridgeOsc__lv2.o \
  226. CarlaBridgeToolkit__lv2.o CarlaBridgeToolkitQt__lv2-windows.o
  227. carla-bridge-lv2-windows.exe: $(OBJS_UI_LV2_WIN32) $(OBJS_UI_LV2_LIBS) ../modules/theme.a
  228. $(CXX) $^ $(LINK_UI_LV2_WIN32_FLAGS) -o $@
  229. %__lv2-windows.o: %.cpp CarlaBridgeToolkitQt.moc resources.cpp
  230. $(CXX) $< $(BUILD_UI_LV2_WIN32_FLAGS) -c -o $@
  231. # --------------------------------------------------------------
  232. # ui_lv2-x11
  233. OBJS_UI_LV2_X11 = CarlaBridgeUI-LV2__lv2-x11.o \
  234. CarlaBridgeClient__lv2.o CarlaBridgeOsc__lv2.o \
  235. CarlaBridgeToolkit__lv2.o CarlaBridgeToolkitQt__lv2-x11.o
  236. carla-bridge-lv2-x11: $(OBJS_UI_LV2_X11) $(OBJS_UI_LV2_LIBS) ../modules/theme.a
  237. $(CXX) $^ $(LINK_UI_LV2_X11_FLAGS) -o $@
  238. %__lv2-x11.o: %.cpp CarlaBridgeToolkitQt.moc resources.cpp
  239. $(CXX) $< $(BUILD_UI_LV2_X11_FLAGS) -c -o $@
  240. # --------------------------------------------------------------
  241. # ui_vst-mac
  242. OBJS_UI_VST_MAC = CarlaBridgeUI-VST__vst-mac.o \
  243. CarlaBridgeClient__vst.o CarlaBridgeOsc__vst.o \
  244. CarlaBridgeToolkit__vst.o CarlaBridgeToolkitQt__vst-mac.o
  245. carla-bridge-vst-mac: $(OBJS_UI_VST_MAC) $(OBJS_UI_VST_LIBS) ../modules/theme.a
  246. $(CXX) $^ $(LINK_UI_VST_MAC_FLAGS) -o $@
  247. %__vst-mac.o: %.cpp CarlaBridgeToolkitQt.moc resources.cpp
  248. $(CXX) $< $(BUILD_UI_VST_MAC_FLAGS) -c -o $@
  249. # --------------------------------------------------------------
  250. # ui_vst-hwnd
  251. OBJS_UI_VST_HWND = CarlaBridgeUI-VST__vst-hwnd.o \
  252. CarlaBridgeClient__vst.o CarlaBridgeOsc__vst.o \
  253. CarlaBridgeToolkit__vst.o CarlaBridgeToolkitQt__vst-hwnd.o
  254. carla-bridge-vst-hwnd.exe: $(OBJS_UI_VST_HWND) $(OBJS_UI_VST_LIBS) ../modules/theme.a
  255. $(CXX) $^ $(LINK_UI_VST_HWND_FLAGS) -o $@
  256. %__vst-hwnd.o: %.cpp CarlaBridgeToolkitQt.moc resources.cpp
  257. $(CXX) $< $(BUILD_UI_VST_HWND_FLAGS) -c -o $@
  258. # --------------------------------------------------------------
  259. # ui_vst-x11
  260. OBJS_UI_VST_X11 = CarlaBridgeUI-VST__vst-x11.o \
  261. CarlaBridgeClient__vst.o CarlaBridgeOsc__vst.o \
  262. CarlaBridgeToolkit__vst.o CarlaBridgeToolkitQt__vst-x11.o
  263. carla-bridge-vst-x11: $(OBJS_UI_VST_X11) $(OBJS_UI_VST_LIBS) ../modules/theme.a
  264. $(CXX) $^ $(LINK_UI_VST_X11_FLAGS) -o $@
  265. %__vst-x11.o: %.cpp CarlaBridgeToolkitQt.moc resources.cpp
  266. $(CXX) $< $(BUILD_UI_VST_X11_FLAGS) -c -o $@
  267. # --------------------------------------------------------------
  268. # native
  269. OBJS_NATIVE = CarlaBridgePlugin__native.o \
  270. CarlaBridgeClient__native.o CarlaBridgeOsc__native.o
  271. # carla-engine
  272. OBJS_NATIVE += \
  273. ../backend/engine/CarlaEngine__native.o \
  274. ../backend/engine/CarlaEngineOsc__native.o \
  275. ../backend/engine/CarlaEngineThread__native.o \
  276. ../backend/engine/CarlaEngineJack__native.o \
  277. ../backend/engine/CarlaEngineBridge__native.o
  278. # carla-plugin
  279. OBJS_NATIVE += \
  280. ../backend/plugin/CarlaPlugin__native.o \
  281. ../backend/plugin/CarlaPluginThread__native.o \
  282. ../backend/plugin/NativePlugin__native.o \
  283. ../backend/plugin/LadspaPlugin__native.o \
  284. ../backend/plugin/DssiPlugin__native.o \
  285. ../backend/plugin/Lv2Plugin__native.o \
  286. ../backend/plugin/VstPlugin__native.o \
  287. ../backend/plugin/Vst3Plugin__native.o \
  288. ../backend/plugin/FluidSynthPlugin__native.o \
  289. ../backend/plugin/LinuxSamplerPlugin__native.o
  290. # carla-standalone
  291. OBJS_NATIVE += \
  292. ../backend/standalone/CarlaStandalone__native.o
  293. # libs
  294. OBJS_NATIVE += \
  295. ../modules/carla_native.a \
  296. ../modules/juce_audio_basics.a \
  297. ../modules/juce_core.a \
  298. ../modules/juce_data_structures.a \
  299. ../modules/juce_events.a \
  300. ../modules/juce_graphics.a \
  301. ../modules/juce_gui_basics.a \
  302. ../modules/rtmempool.a
  303. ifeq ($(HAVE_OPENGL),true)
  304. OBJS_NATIVE += \
  305. ../modules/dgl.a
  306. endif
  307. ifeq ($(CARLA_PLUGIN_SUPPORT),true)
  308. OBJS_NATIVE += \
  309. ../modules/lilv.a
  310. endif
  311. carla-bridge-native: $(FILES) $(OBJS_NATIVE)
  312. $(CXX) $(OBJS_NATIVE) $(NATIVE_LINK_FLAGS) -o $@
  313. %__native.o: %.cpp
  314. $(CXX) $< $(NATIVE_BUILD_FLAGS) -c -o $@
  315. # --------------------------------------------------------------
  316. # posix32
  317. OBJS_POSIX32 = CarlaBridgePlugin__posix32.o \
  318. CarlaBridgeClient__posix32.o CarlaBridgeOsc__posix32.o
  319. # carla-engine
  320. OBJS_POSIX32 += \
  321. ../backend/engine/CarlaEngine__posix32.o \
  322. ../backend/engine/CarlaEngineOsc__posix32.o \
  323. ../backend/engine/CarlaEngineThread__posix32.o \
  324. ../backend/engine/CarlaEngineJack__posix32.o \
  325. ../backend/engine/CarlaEngineBridge__posix32.o
  326. # carla-plugin
  327. OBJS_POSIX32 += \
  328. ../backend/plugin/CarlaPlugin__posix32.o \
  329. ../backend/plugin/CarlaPluginThread__posix32.o \
  330. ../backend/plugin/NativePlugin__posix32.o \
  331. ../backend/plugin/LadspaPlugin__posix32.o \
  332. ../backend/plugin/DssiPlugin__posix32.o \
  333. ../backend/plugin/Lv2Plugin__posix32.o \
  334. ../backend/plugin/VstPlugin__posix32.o \
  335. ../backend/plugin/Vst3Plugin__posix32.o \
  336. ../backend/plugin/FluidSynthPlugin__posix32.o \
  337. ../backend/plugin/LinuxSamplerPlugin__posix32.o
  338. # carla-standalone
  339. OBJS_POSIX32 += \
  340. ../backend/standalone/CarlaStandalone__posix32.o
  341. # libs
  342. OBJS_POSIX32 += \
  343. ../modules/lilv.posix32.a \
  344. ../modules/rtmempool.posix32.a
  345. carla-bridge-posix32: $(FILES) $(OBJS_POSIX32)
  346. $(CXX) $(OBJS_POSIX32) $(POSIX_LINK_FLAGS) $(POSIX_32BIT_FLAGS) -o $@
  347. %__posix32.o: %.cpp
  348. $(CXX) $< $(POSIX_BUILD_FLAGS) $(POSIX_32BIT_FLAGS) -c -o $@
  349. # --------------------------------------------------------------
  350. # posix64
  351. OBJS_POSIX64 = CarlaBridgePlugin__posix64.o \
  352. CarlaBridgeClient__posix64.o CarlaBridgeOsc__posix64.o
  353. # carla-engine
  354. OBJS_POSIX64 += \
  355. ../backend/engine/CarlaEngine__posix64.o \
  356. ../backend/engine/CarlaEngineOsc__posix64.o \
  357. ../backend/engine/CarlaEngineThread__posix64.o \
  358. ../backend/engine/CarlaEngineJack__posix64.o \
  359. ../backend/engine/CarlaEngineBridge__posix64.o
  360. # carla-plugin
  361. OBJS_POSIX64 += \
  362. ../backend/plugin/CarlaPlugin__posix64.o \
  363. ../backend/plugin/CarlaPluginThread__posix64.o \
  364. ../backend/plugin/NativePlugin__posix64.o \
  365. ../backend/plugin/LadspaPlugin__posix64.o \
  366. ../backend/plugin/DssiPlugin__posix64.o \
  367. ../backend/plugin/Lv2Plugin__posix64.o \
  368. ../backend/plugin/VstPlugin__posix64.o \
  369. ../backend/plugin/Vst3Plugin__posix64.o \
  370. ../backend/plugin/FluidSynthPlugin__posix64.o \
  371. ../backend/plugin/LinuxSamplerPlugin__posix64.o
  372. # carla-standalone
  373. OBJS_POSIX64 += \
  374. ../backend/standalone/CarlaStandalone__posix64.o
  375. # libs
  376. OBJS_POSIX64 += \
  377. ../modules/lilv.posix64.a \
  378. ../modules/rtmempool.posix64.a
  379. carla-bridge-posix64: $(FILES) $(OBJS_POSIX64)
  380. $(CXX) $(OBJS_POSIX64) $(POSIX_LINK_FLAGS) $(POSIX_64BIT_FLAGS) -o $@
  381. %__posix64.o: %.cpp
  382. $(CXX) $< $(POSIX_BUILD_FLAGS) $(POSIX_64BIT_FLAGS) -c -o $@
  383. # --------------------------------------------------------------
  384. # win32
  385. OBJS_WIN32 = CarlaBridgePlugin__win32.o \
  386. CarlaBridgeClient__win32.o CarlaBridgeOsc__win32.o
  387. # carla-engine
  388. OBJS_WIN32 += \
  389. ../backend/engine/CarlaEngine__win32.o \
  390. ../backend/engine/CarlaEngineOsc__win32.o \
  391. ../backend/engine/CarlaEngineThread__win32.o \
  392. ../backend/engine/CarlaEngineBridge__win32.o \
  393. ../backend/engine/CarlaEngineJack__win32.o
  394. # carla-plugin
  395. OBJS_WIN32 += \
  396. ../backend/plugin/CarlaPlugin__win32.o \
  397. ../backend/plugin/CarlaPluginThread__win32.o \
  398. ../backend/plugin/NativePlugin__win32.o \
  399. ../backend/plugin/LadspaPlugin__win32.o \
  400. ../backend/plugin/DssiPlugin__win32.o \
  401. ../backend/plugin/Lv2Plugin__win32.o \
  402. ../backend/plugin/VstPlugin__win32.o \
  403. ../backend/plugin/Vst3Plugin__win32.o \
  404. ../backend/plugin/FluidSynthPlugin__win32.o \
  405. ../backend/plugin/LinuxSamplerPlugin__win32.o
  406. # carla-standalone
  407. OBJS_WIN32 += \
  408. ../backend/standalone/CarlaStandalone__win32.o
  409. # libs
  410. OBJS_WIN32 += \
  411. ../modules/juce_core.win32.a \
  412. ../modules/lilv.win32.a \
  413. ../modules/rtmempool.win32.a
  414. carla-bridge-win32.exe: $(FILES) $(OBJS_WIN32) ../modules/jackbridge-win32.dll
  415. $(CXX) $(OBJS_WIN32) $(WIN_32BIT_FLAGS) $(WIN_LINK_FLAGS) -ljackbridge-win32 -o $@
  416. %__win32.o: %.cpp
  417. $(CXX) $< $(WIN_BUILD_FLAGS) $(WIN_32BIT_FLAGS) -c -o $@
  418. # --------------------------------------------------------------
  419. # win64
  420. OBJS_WIN64 = CarlaBridgePlugin__win64.o \
  421. CarlaBridgeClient__win64.o CarlaBridgeOsc__win64.o
  422. # carla-engine
  423. OBJS_WIN64 += \
  424. ../backend/engine/CarlaEngine__win64.o \
  425. ../backend/engine/CarlaEngineOsc__win64.o \
  426. ../backend/engine/CarlaEngineThread__win64.o \
  427. ../backend/engine/CarlaEngineBridge__win64.o \
  428. ../backend/engine/CarlaEngineJack__win64.o
  429. # carla-plugin
  430. OBJS_WIN64 += \
  431. ../backend/plugin/CarlaPlugin__win64.o \
  432. ../backend/plugin/CarlaPluginThread__win64.o \
  433. ../backend/plugin/NativePlugin__win64.o \
  434. ../backend/plugin/LadspaPlugin__win64.o \
  435. ../backend/plugin/DssiPlugin__win64.o \
  436. ../backend/plugin/Lv2Plugin__win64.o \
  437. ../backend/plugin/VstPlugin__win64.o \
  438. ../backend/plugin/Vst3Plugin__win64.o \
  439. ../backend/plugin/FluidSynthPlugin__win64.o \
  440. ../backend/plugin/LinuxSamplerPlugin__win64.o
  441. # carla-standalone
  442. OBJS_WIN64 += \
  443. ../backend/standalone/CarlaStandalone__win64.o
  444. # libs
  445. OBJS_WIN64 += \
  446. ../modules/lilv.win64.a \
  447. ../modules/rtmempool.win64.a
  448. carla-bridge-win64.exe: $(FILES) $(OBJS_WIN64) ../modules/jackbridge-win64.dll
  449. $(CXX) $(OBJS_WIN64) $(WIN_64BIT_FLAGS) $(WIN_LINK_FLAGS) -ljackbridge-win64 -o $@
  450. %__win64.o: %.cpp
  451. $(CXX) $< $(WIN_BUILD_FLAGS) $(WIN_64BIT_FLAGS) -c -o $@
  452. # --------------------------------------------------------------
  453. .FORCE:
  454. .PHONY: .FORCE
  455. ../modules/juce_core.%.a: .FORCE
  456. $(MAKE) -C ../modules juce_core_$*
  457. ../modules/lilv.%.a: .FORCE
  458. $(MAKE) -C ../modules lilv_$*
  459. ../modules/rtmempool.%.a: .FORCE
  460. $(MAKE) -C ../modules rtmempool_$*
  461. ../modules/%.a: .FORCE
  462. $(MAKE) -C ../modules $*
  463. ../modules/%.dll:
  464. $(MAKE) -C ../modules $*
  465. # --------------------------------------------------------------
  466. doxygen: carla_bridge.doxygen
  467. doxygen $<
  468. # --------------------------------------------------------------
  469. clean:
  470. rm -f *.moc *.o *.dll *.dylib *.so *.exe
  471. rm -f resources.cpp resources.qt4.cpp
  472. rm -f $(OBJS_NATIVE)
  473. rm -f $(OBJS_POSIX32)
  474. rm -f $(OBJS_POSIX64)
  475. rm -f $(OBJS_WIN32)
  476. rm -f $(OBJS_WIN64)
  477. rm -f carla-bridge-lv2-gtk2 carla-bridge-lv2-gtk3 carla-bridge-lv2-qt4 carla-bridge-lv2-qt5 carla-bridge-lv2-cocoa carla-bridge-lv2-x11
  478. rm -f carla-bridge-vst-mac carla-bridge-vst-x11
  479. rm -f carla-bridge-native carla-bridge-posix32 carla-bridge-posix64
  480. # --------------------------------------------------------------
  481. debug:
  482. $(MAKE) DEBUG=true