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.

Makefile 20KB

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