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 11KB

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
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399
  1. #!/usr/bin/make -f
  2. # Makefile for Carla #
  3. # ------------------ #
  4. # Created by falkTX
  5. #
  6. include source/Makefile.mk
  7. # --------------------------------------------------------------
  8. PREFIX = /usr/local
  9. DESTDIR =
  10. SED_PREFIX = $(shell echo $(PREFIX) | sed "s/\//\\\\\\\\\//g")
  11. LINK = ln -sf
  12. PYUIC ?= pyuic5
  13. PYRCC ?= pyrcc5
  14. # --------------------------------------------------------------
  15. all: WARN
  16. # CXX RES UI WIDGETS
  17. WARN:
  18. @echo "This is the development branch of carla, DO NOT USE IT."
  19. @echo "Please switch to the stable branch by using:"
  20. @echo "git checkout 1.0.x"
  21. # --------------------------------------------------------------
  22. # C++ code
  23. CXX: backend bridges discovery
  24. backend:
  25. $(MAKE) -C source/backend
  26. bridges:
  27. $(MAKE) -C source/bridges
  28. discovery:
  29. $(MAKE) -C source/discovery
  30. plugin:
  31. $(MAKE) -C source/plugin
  32. posix32:
  33. $(MAKE) -C source/bridges posix32
  34. $(MAKE) -C source/discovery posix32
  35. posix64:
  36. $(MAKE) -C source/bridges posix64
  37. $(MAKE) -C source/discovery posix64
  38. win32:
  39. $(MAKE) -C source/bridges win32
  40. $(MAKE) -C source/discovery win32
  41. win64:
  42. $(MAKE) -C source/bridges win64
  43. $(MAKE) -C source/discovery win64
  44. wine32:
  45. $(MAKE) -C source/libs jackbridge-wine32
  46. $(LINK) ../libs/jackbridge-win32.dll.so source/bridges/jackbridge-win32.dll
  47. wine64:
  48. $(MAKE) -C source/libs jackbridge-wine64
  49. $(LINK) ../libs/jackbridge-win64.dll.so source/bridges/jackbridge-win64.dll
  50. # --------------------------------------------------------------
  51. # Resources
  52. RES = source/resources_rc.py
  53. RES: $(RES)
  54. source/%_rc.py: resources/%.qrc resources/*/*.png resources/*/*.svg
  55. $(PYRCC) $< -o $@
  56. # --------------------------------------------------------------
  57. # UI code
  58. UIs = \
  59. source/ui_carla.py \
  60. source/ui_carla_control.py \
  61. source/ui_carla_about.py \
  62. source/ui_carla_database.py \
  63. source/ui_carla_edit.py \
  64. source/ui_carla_parameter.py \
  65. source/ui_carla_plugin.py \
  66. source/ui_carla_refresh.py \
  67. source/ui_carla_settings.py \
  68. source/ui_carla_settings_driver.py \
  69. source/ui_inputdialog_value.py
  70. UI: $(UIs)
  71. source/ui_%.py: resources/ui/%.ui
  72. $(PYUIC) $< -o $@
  73. # --------------------------------------------------------------
  74. # Widgets
  75. WIDGETS = \
  76. source/canvaspreviewframe.py \
  77. source/digitalpeakmeter.py \
  78. source/ledbutton.py \
  79. source/paramspinbox.py \
  80. source/pixmapbutton.py \
  81. source/pixmapdial.py \
  82. source/pixmapkeyboard.py
  83. WIDGETS: $(WIDGETS)
  84. source/%.py: source/widgets/%.py
  85. $(LINK) widgets/$*.py $@
  86. # --------------------------------------------------------------
  87. clean:
  88. $(MAKE) clean -C source/backend
  89. $(MAKE) clean -C source/bridges
  90. $(MAKE) clean -C source/discovery
  91. $(MAKE) clean -C source/modules
  92. $(MAKE) clean -C source/plugin
  93. rm -f $(RES)
  94. rm -f $(UIs)
  95. rm -f $(WIDGETS)
  96. rm -f *~ source/*~ source/*.pyc source/*_rc.py source/ui_*.py
  97. # --------------------------------------------------------------
  98. debug:
  99. $(MAKE) DEBUG=true
  100. # --------------------------------------------------------------
  101. doxygen:
  102. $(MAKE) doxygen -C source/backend
  103. # --------------------------------------------------------------
  104. install:
  105. # Create directories
  106. install -d $(DESTDIR)$(PREFIX)/bin/
  107. install -d $(DESTDIR)$(PREFIX)/lib/carla/
  108. install -d $(DESTDIR)$(PREFIX)/lib/carla/resources/
  109. install -d $(DESTDIR)$(PREFIX)/lib/carla/resources/nekofilter/
  110. install -d $(DESTDIR)$(PREFIX)/lib/carla/resources/zynaddsubfx/
  111. install -d $(DESTDIR)$(PREFIX)/share/applications/
  112. install -d $(DESTDIR)$(PREFIX)/share/carla/
  113. install -d $(DESTDIR)$(PREFIX)/share/icons/hicolor/16x16/apps/
  114. install -d $(DESTDIR)$(PREFIX)/share/icons/hicolor/48x48/apps/
  115. install -d $(DESTDIR)$(PREFIX)/share/icons/hicolor/128x128/apps/
  116. install -d $(DESTDIR)$(PREFIX)/share/icons/hicolor/256x256/apps/
  117. install -d $(DESTDIR)$(PREFIX)/share/icons/hicolor/scalable/apps/
  118. install -d $(DESTDIR)$(PREFIX)/share/mime/packages/
  119. # Install script files
  120. install -m 755 \
  121. data/carla \
  122. data/carla-control \
  123. data/carla-single \
  124. $(DESTDIR)$(PREFIX)/bin/
  125. # Install desktop files
  126. install -m 644 data/*.desktop $(DESTDIR)$(PREFIX)/share/applications/
  127. # Install icons, 16x16
  128. install -m 644 resources/16x16/carla.png $(DESTDIR)$(PREFIX)/share/icons/hicolor/16x16/apps/
  129. install -m 644 resources/16x16/carla-control.png $(DESTDIR)$(PREFIX)/share/icons/hicolor/16x16/apps/
  130. # Install icons, 48x48
  131. install -m 644 resources/48x48/carla.png $(DESTDIR)$(PREFIX)/share/icons/hicolor/48x48/apps/
  132. install -m 644 resources/48x48/carla-control.png $(DESTDIR)$(PREFIX)/share/icons/hicolor/48x48/apps/
  133. # Install icons, 128x128
  134. install -m 644 resources/128x128/carla.png $(DESTDIR)$(PREFIX)/share/icons/hicolor/128x128/apps/
  135. install -m 644 resources/128x128/carla-control.png $(DESTDIR)$(PREFIX)/share/icons/hicolor/128x128/apps/
  136. # Install icons, 256x256
  137. install -m 644 resources/256x256/carla.png $(DESTDIR)$(PREFIX)/share/icons/hicolor/256x256/apps/
  138. install -m 644 resources/256x256/carla-control.png $(DESTDIR)$(PREFIX)/share/icons/hicolor/256x256/apps/
  139. # Install icons, scalable
  140. install -m 644 resources/scalable/carla.svg $(DESTDIR)$(PREFIX)/share/icons/hicolor/scalable/apps/
  141. install -m 644 resources/scalable/carla-control.svg $(DESTDIR)$(PREFIX)/share/icons/hicolor/scalable/apps/
  142. # Install mime package
  143. install -m 644 data/carla.xml $(DESTDIR)$(PREFIX)/share/mime/packages/
  144. # Install binaries
  145. install -m 755 \
  146. source/backend/*.so \
  147. source/bridges/carla-bridge-* \
  148. source/discovery/carla-discovery-* \
  149. $(DESTDIR)$(PREFIX)/lib/carla/
  150. # Install python code
  151. install -m 755 source/*.py $(DESTDIR)$(PREFIX)/share/carla/
  152. # Install resources
  153. install -m 644 source/backend/resources/nekofilter-ui $(DESTDIR)$(PREFIX)/lib/carla/resources/
  154. install -m 644 source/backend/resources/nekofilter/*.png $(DESTDIR)$(PREFIX)/lib/carla/resources/nekofilter/
  155. install -m 644 source/backend/resources/zynaddsubfx/*.png $(DESTDIR)$(PREFIX)/lib/carla/resources/zynaddsubfx/
  156. # Adjust PREFIX value in script files
  157. sed -i "s/X-PREFIX-X/$(SED_PREFIX)/" \
  158. $(DESTDIR)$(PREFIX)/bin/carla \
  159. $(DESTDIR)$(PREFIX)/bin/carla-control \
  160. $(DESTDIR)$(PREFIX)/bin/carla-single
  161. # --------------------------------------------------------------
  162. uninstall:
  163. rm -f $(DESTDIR)$(PREFIX)/bin/carla*
  164. rm -f $(DESTDIR)$(PREFIX)/share/applications/carla.desktop
  165. rm -f $(DESTDIR)$(PREFIX)/share/applications/carla-control.desktop
  166. rm -f $(DESTDIR)$(PREFIX)/share/icons/hicolor/*/apps/carla.png
  167. rm -f $(DESTDIR)$(PREFIX)/share/icons/hicolor/*/apps/carla-control.png
  168. rm -f $(DESTDIR)$(PREFIX)/share/icons/hicolor/scalable/apps/carla.svg
  169. rm -f $(DESTDIR)$(PREFIX)/share/icons/hicolor/scalable/apps/carla-control.svg
  170. rm -f $(DESTDIR)$(PREFIX)/share/mime/packages/carla.xml
  171. rm -f $(DESTDIR)$(PREFIX)/lib/dssi/carla-dssi.so
  172. rm -f $(DESTDIR)$(PREFIX)/lib/vst/carla-vst.so
  173. rm -rf $(DESTDIR)$(PREFIX)/lib/carla/
  174. rm -rf $(DESTDIR)$(PREFIX)/lib/lv2/carla.lv2/
  175. rm -rf $(DESTDIR)$(PREFIX)/share/carla/
  176. # --------------------------------------------------------------
  177. ANS_NO=\033[31m NO \033[0m
  178. ANS_YES=\033[32m YES \033[0m
  179. mS=\033[33m[
  180. mE=]\033[0m
  181. features:
  182. ifeq ($(MACOS),true)
  183. # --- MacOS ---
  184. @echo "\033[36m---> Engine drivers: (MacOS)\033[0m"
  185. @echo "JACK: $(ANS_YES)"
  186. ifeq ($(CARLA_RTAUDIO_SUPPORT),true)
  187. @echo "CoreAudio:$(ANS_YES)"
  188. else
  189. @echo "CoreAudio:$(ANS_NO) $(mS)RtAudio disabled$(mE)"
  190. endif
  191. # --- MacOS ---
  192. else
  193. # --- Win32 ---
  194. ifeq ($(WIN32),true)
  195. @echo "\033[36m---> Engine drivers: (Windows)\033[0m"
  196. @echo "JACK: $(ANS_YES)"
  197. ifeq ($(CARLA_RTAUDIO_SUPPORT),true)
  198. @echo "ASIO: $(ANS_YES)"
  199. @echo "DirectSound:$(ANS_YES)"
  200. else
  201. @echo "ASIO: $(ANS_NO) $(mS)RtAudio disabled$(mE)"
  202. @echo "DirectSound:$(ANS_NO) $(mS)RtAudio disabled$(mE)"
  203. endif
  204. # --- Win32 ---
  205. else
  206. # --- Others ---
  207. @echo "\033[36m---> Engine drivers: \033[0m"
  208. @echo "JACK: $(ANS_YES)"
  209. ifeq ($(CARLA_RTAUDIO_SUPPORT),true)
  210. ifeq ($(HAVE_ALSA),true)
  211. @echo "ALSA: $(ANS_YES)"
  212. else
  213. @echo "ALSA: $(ANS_NO) $(mS)Missing ALSA$(mE)"
  214. endif
  215. ifeq ($(HAVE_PULSEAUDIO),true)
  216. @echo "PulseAudio:$(ANS_YES)"
  217. else
  218. @echo "PulseAudio:$(ANS_NO) $(mS)Missing PulseAudio$(mE)"
  219. endif
  220. else
  221. @echo "ALSA: $(ANS_NO) $(mS)RtAudio disabled$(mE)"
  222. @echo "PulseAudio:$(ANS_NO) $(mS)RtAudio disabled$(mE)"
  223. endif
  224. # --- Others ---
  225. endif
  226. endif
  227. @echo ""
  228. @echo "\033[36m---> Plugin formats: \033[0m"
  229. @echo "Internal:$(ANS_YES)"
  230. ifeq ($(CARLA_PLUGIN_SUPPORT),true)
  231. @echo "LADSPA: $(ANS_YES)"
  232. @echo "DSSI: $(ANS_YES)"
  233. @echo "LV2: $(ANS_YES)"
  234. @echo "VST: $(ANS_YES)"
  235. else
  236. @echo "LADSPA: $(ANS_NO) $(mS)Plugins disabled$(mE)"
  237. @echo "DSSI: $(ANS_NO) $(mS)Plugins disabled$(mE)"
  238. @echo "LV2: $(ANS_NO) $(mS)Plugins disabled$(mE)"
  239. @echo "VST: $(ANS_NO) $(mS)Plugins disabled$(mE)"
  240. endif
  241. @echo ""
  242. ifeq ($(CARLA_PLUGIN_SUPPORT),true)
  243. @echo "\033[36m---> LV2 UI toolkit support: \033[0m"
  244. @echo "ExternalUI:$(ANS_YES) (direct+bridge)"
  245. ifeq ($(MACOS),true)
  246. # --- MacOS ---
  247. @echo "CocoaUI: $(ANS_YES) (direct+bridge)"
  248. # --- MacOS ---
  249. else
  250. # --- Win32 ---
  251. ifeq ($(WIN32),true)
  252. # --- Win32 ---
  253. @echo "WindowsUI: $(ANS_YES) (direct+bridge)"
  254. else
  255. # --- Others ---
  256. ifeq ($(HAVE_GTK2),true)
  257. @echo "GtkUI: $(ANS_YES) (bridge)"
  258. else
  259. @echo "GtkUI: $(ANS_NO) $(mS)Gtk2 missing$(mE)"
  260. endif
  261. ifeq ($(HAVE_GTK3),true)
  262. @echo "Gtk3UI: $(ANS_YES) (bridge)"
  263. else
  264. @echo "Gtk3UI: $(ANS_NO) $(mS)Gtk3 missing$(mE)"
  265. endif
  266. ifeq ($(HAVE_QT4),true)
  267. @echo "Qt4UI: $(ANS_YES) (bridge)"
  268. else
  269. @echo "Qt4UI: $(ANS_NO) $(mS)Qt4 missing$(mE)"
  270. endif
  271. ifeq ($(HAVE_QT5),true)
  272. @echo "Qt5UI: $(ANS_YES) (bridge)"
  273. else
  274. @echo "Qt5UI: $(ANS_NO) $(mS)Qt5 missing$(mE)"
  275. endif
  276. @echo "X11UI: $(ANS_YES) (direct+bridge)"
  277. endif
  278. # --- Others ---
  279. endif
  280. @echo ""
  281. endif
  282. @echo "\033[36m---> Sample formats: \033[0m"
  283. ifeq ($(CARLA_SAMPLERS_SUPPORT),true)
  284. ifeq ($(HAVE_LINUXSAMPLER),true)
  285. @echo "GIG:$(ANS_YES)"
  286. else
  287. @echo "GIG:$(ANS_NO) $(mS)LinuxSampler missing$(mE)"
  288. endif
  289. ifeq ($(HAVE_FLUIDSYNTH),true)
  290. @echo "SF2:$(ANS_YES)"
  291. else
  292. @echo "SF2:$(ANS_NO) $(mS)FluidSynth missing$(mE)"
  293. endif
  294. ifeq ($(HAVE_LINUXSAMPLER),true)
  295. @echo "SFZ:$(ANS_YES)"
  296. else
  297. @echo "SFZ:$(ANS_NO) $(mS)LinuxSampler missing$(mE)"
  298. endif
  299. else
  300. @echo "GIG:$(ANS_NO) $(mS)Samplers disabled$(mE)"
  301. @echo "SF2:$(ANS_NO) $(mS)Samplers disabled$(mE)"
  302. @echo "SFZ:$(ANS_NO) $(mS)Samplers disabled$(mE)"
  303. endif
  304. @echo ""
  305. @echo "\033[36m---> Internal plugins: \033[0m"
  306. ifeq ($(HAVE_AF_DEPS),true)
  307. ifeq ($(HAVE_FFMPEG),true)
  308. @echo "AudioFile: $(ANS_YES) (with ffmpeg)"
  309. else
  310. @echo "AudioFile: $(ANS_YES) (without ffmpeg) $(mS)ffmpeg/libav missing or too new$(mE)"
  311. endif
  312. else
  313. @echo "AudioFile: $(ANS_NO) $(mS)libsndfile missing$(mE)"
  314. endif
  315. ifeq ($(HAVE_MF_DEPS),true)
  316. @echo "MidiFile: $(ANS_YES)"
  317. else
  318. @echo "MidiFile: $(ANS_NO) $(mS)libsmf missing$(mE)"
  319. endif
  320. ifeq ($(HAVE_OPENGL),true)
  321. @echo "DISTRHO: $(ANS_YES)"
  322. else
  323. @echo "DISTRHO: $(ANS_NO) $(mS)OpenGL missing$(mE)"
  324. endif
  325. ifeq ($(HAVE_ZYN_DEPS),true)
  326. ifeq ($(HAVE_ZYN_UI_DEPS),true)
  327. @echo "ZynAddSubFX:$(ANS_YES) (with UI)"
  328. else
  329. @echo "ZynAddSubFX:$(ANS_YES) (without UI) $(mS)NTK missing$(mE)"
  330. endif
  331. else
  332. @echo "ZynAddSubFX:$(ANS_NO) $(mS)fftw-3, mxml or zlib missing$(mE)"
  333. endif
  334. # --------------------------------------------------------------