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

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
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
11 years ago
9 years ago
9 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
10 years ago
10 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
6 years ago
11 years ago
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856
  1. #!/usr/bin/make -f
  2. # Makefile for Carla #
  3. # ------------------ #
  4. # Created by falkTX
  5. #
  6. CWD=source
  7. include source/Makefile.mk
  8. # ---------------------------------------------------------------------------------------------------------------------
  9. PREFIX := /usr/local
  10. BINDIR := $(PREFIX)/bin
  11. LIBDIR := $(PREFIX)/lib
  12. DATADIR := $(PREFIX)/share
  13. INCLUDEDIR := $(PREFIX)/include
  14. DESTDIR :=
  15. ifeq ($(DEBUG),true)
  16. MODULEDIR := $(CURDIR)/build/modules/Debug
  17. else
  18. MODULEDIR := $(CURDIR)/build/modules/Release
  19. endif
  20. # ---------------------------------------------------------------------------------------------------------------------
  21. all: backend discovery bridges-plugin bridges-ui frontend interposer libjack plugin theme
  22. # ---------------------------------------------------------------------------------------------------------------------
  23. # Binaries (native)
  24. ALL_LIBS += $(MODULEDIR)/carla_engine.a
  25. ALL_LIBS += $(MODULEDIR)/carla_engine_plugin.a
  26. ALL_LIBS += $(MODULEDIR)/carla_plugin.a
  27. ALL_LIBS += $(MODULEDIR)/jackbridge.a
  28. ALL_LIBS += $(MODULEDIR)/native-plugins.a
  29. ALL_LIBS += $(MODULEDIR)/audio_decoder.a
  30. ALL_LIBS += $(MODULEDIR)/lilv.a
  31. ALL_LIBS += $(MODULEDIR)/rtmempool.a
  32. ALL_LIBS += $(MODULEDIR)/sfzero.a
  33. ALL_LIBS += $(MODULEDIR)/water.a
  34. ifeq ($(HAVE_DGL),true)
  35. ALL_LIBS += $(MODULEDIR)/dgl.a
  36. endif
  37. ifeq ($(HAVE_HYLIA),true)
  38. ALL_LIBS += $(MODULEDIR)/hylia.a
  39. endif
  40. ALL_LIBS += $(MODULEDIR)/rtaudio.a
  41. ALL_LIBS += $(MODULEDIR)/rtmidi.a
  42. ifeq ($(HAVE_QT4),true)
  43. ALL_LIBS += $(MODULEDIR)/theme.qt4.a
  44. endif
  45. ifeq ($(HAVE_QT5),true)
  46. ALL_LIBS += $(MODULEDIR)/theme.qt5.a
  47. endif
  48. ifeq ($(USING_JUCE),true)
  49. ALL_LIBS += $(MODULEDIR)/juce_audio_basics.a
  50. ALL_LIBS += $(MODULEDIR)/juce_audio_devices.a
  51. ALL_LIBS += $(MODULEDIR)/juce_core.a
  52. ALL_LIBS += $(MODULEDIR)/juce_data_structures.a
  53. ALL_LIBS += $(MODULEDIR)/juce_events.a
  54. ifeq ($(MACOS_OR_WIN32),true)
  55. ALL_LIBS += $(MODULEDIR)/juce_audio_processors.a
  56. ALL_LIBS += $(MODULEDIR)/juce_graphics.a
  57. ALL_LIBS += $(MODULEDIR)/juce_gui_basics.a
  58. # ALL_LIBS += $(MODULEDIR)/juce_gui_extra.a
  59. endif
  60. endif
  61. libs: $(ALL_LIBS)
  62. $(MODULEDIR)/carla_engine.a: .FORCE
  63. @$(MAKE) -C source/backend/engine
  64. $(MODULEDIR)/carla_engine_plugin.a: $(MODULEDIR)/carla_engine.a
  65. @$(MAKE) -C source/backend/engine
  66. $(MODULEDIR)/carla_plugin.a: .FORCE
  67. @$(MAKE) -C source/backend/plugin
  68. $(MODULEDIR)/jackbridge.a: .FORCE
  69. @$(MAKE) -C source/jackbridge
  70. $(MODULEDIR)/jackbridge.%.a: .FORCE
  71. @$(MAKE) -C source/jackbridge $*
  72. $(MODULEDIR)/native-plugins.a: .FORCE
  73. @$(MAKE) -C source/native-plugins
  74. $(MODULEDIR)/theme.qt4.a: .FORCE
  75. @$(MAKE) -C source/theme qt4
  76. $(MODULEDIR)/theme.qt5.a: .FORCE
  77. @$(MAKE) -C source/theme qt5
  78. $(MODULEDIR)/%.posix32.a: .FORCE
  79. ifneq ($(WIN32),true)
  80. @$(MAKE) -C source/modules/$* posix32
  81. else
  82. $(error Trying to build POSIX binaries with a Windows toolchain, this cannot work)
  83. endif
  84. $(MODULEDIR)/%.posix64.a: .FORCE
  85. ifneq ($(WIN32),true)
  86. @$(MAKE) -C source/modules/$* posix64
  87. else
  88. $(error Trying to build POSIX binaries with a Windows toolchain, this cannot work)
  89. endif
  90. $(MODULEDIR)/%.win32.a: .FORCE
  91. ifeq ($(WIN32),true)
  92. @$(MAKE) -C source/modules/$* win32
  93. else
  94. $(error Trying to build Windows binaries with a regular toolchain, this cannot work)
  95. endif
  96. $(MODULEDIR)/%.win64.a: .FORCE
  97. ifeq ($(WIN32),true)
  98. @$(MAKE) -C source/modules/$* win64
  99. else
  100. $(error Trying to build Windows binaries with a regular toolchain, this cannot work)
  101. endif
  102. $(MODULEDIR)/dgl.wine.a: .FORCE
  103. @$(MAKE) -C source/modules/dgl wine
  104. $(MODULEDIR)/%.a: .FORCE
  105. @$(MAKE) -C source/modules/$*
  106. # ---------------------------------------------------------------------------------------------------------------------
  107. backend: libs
  108. @$(MAKE) -C source/backend
  109. bridges-plugin: libs
  110. @$(MAKE) -C source/bridges-plugin
  111. bridges-ui: libs
  112. @$(MAKE) -C source/bridges-ui
  113. discovery: libs
  114. @$(MAKE) -C source/discovery
  115. frontend:
  116. ifeq ($(HAVE_PYQT),true)
  117. @$(MAKE) -C source/frontend
  118. endif
  119. interposer:
  120. ifeq ($(LINUX),true)
  121. @$(MAKE) -C source/interposer
  122. endif
  123. libjack: libs
  124. @$(MAKE) -C source/libjack
  125. plugin: backend bridges-plugin bridges-ui discovery
  126. @$(MAKE) -C source/plugin
  127. ifeq ($(WIN32),true)
  128. plugin-wine:
  129. @$(MAKE) -C source/plugin wine
  130. else
  131. plugin-wine: $(MODULEDIR)/dgl.wine.a
  132. @$(MAKE) -C source/plugin wine
  133. endif
  134. rest: libs
  135. @$(MAKE) -C source/rest
  136. theme: libs
  137. @$(MAKE) -C source/theme
  138. # ---------------------------------------------------------------------------------------------------------------------
  139. # nuitka
  140. nuitka: bin/carla bin/carla-rack bin/carla-plugin
  141. bin/carla:
  142. python3 -m nuitka \
  143. -j 8 \
  144. --recurse-all \
  145. --python-flag -O --warn-unusual-code --warn-implicit-exceptions \
  146. --recurse-not-to=PyQt5 \
  147. --file-reference-choice=runtime \
  148. -o ./$@ \
  149. ./source/frontend/carla
  150. bin/carla-rack:
  151. python3 -m nuitka \
  152. -j 8 \
  153. --recurse-all \
  154. --python-flag -O --warn-unusual-code --warn-implicit-exceptions \
  155. --recurse-not-to=PyQt5 \
  156. --file-reference-choice=runtime \
  157. -o ./$@ \
  158. ./source/frontend/carla
  159. bin/carla-plugin:
  160. python3 -m nuitka \
  161. -j 8 \
  162. --recurse-all \
  163. --python-flag -O --warn-unusual-code --warn-implicit-exceptions \
  164. --recurse-not-to=PyQt5 \
  165. --file-reference-choice=runtime \
  166. -o ./$@ \
  167. ./source/native-plugins/resources/carla-plugin
  168. # ---------------------------------------------------------------------------------------------------------------------
  169. # Binaries (posix32)
  170. LIBS_POSIX32 = $(MODULEDIR)/jackbridge.posix32.a
  171. LIBS_POSIX32 += $(MODULEDIR)/lilv.posix32.a
  172. LIBS_POSIX32 += $(MODULEDIR)/rtmempool.posix32.a
  173. LIBS_POSIX32 += $(MODULEDIR)/water.posix32.a
  174. posix32: $(LIBS_POSIX32)
  175. $(MAKE) -C source/bridges-plugin posix32
  176. $(MAKE) -C source/discovery posix32
  177. # ---------------------------------------------------------------------------------------------------------------------
  178. # Binaries (posix64)
  179. LIBS_POSIX64 = $(MODULEDIR)/jackbridge.posix64.a
  180. LIBS_POSIX64 += $(MODULEDIR)/lilv.posix64.a
  181. LIBS_POSIX64 += $(MODULEDIR)/rtmempool.posix64.a
  182. LIBS_POSIX64 += $(MODULEDIR)/water.posix64.a
  183. posix64: $(LIBS_POSIX64)
  184. $(MAKE) -C source/bridges-plugin posix64
  185. $(MAKE) -C source/discovery posix64
  186. # ---------------------------------------------------------------------------------------------------------------------
  187. # Binaries (win32)
  188. ifeq ($(BUILDING_FOR_WINDOWS),true)
  189. LIBS_WIN32 = $(MODULEDIR)/jackbridge.win32.a
  190. else
  191. LIBS_WIN32 = $(MODULEDIR)/jackbridge.win32e.a
  192. endif
  193. LIBS_WIN32 += $(MODULEDIR)/lilv.win32.a
  194. LIBS_WIN32 += $(MODULEDIR)/rtmempool.win32.a
  195. LIBS_WIN32 += $(MODULEDIR)/water.win32.a
  196. win32: $(LIBS_WIN32)
  197. $(MAKE) -C source/bridges-plugin win32
  198. $(MAKE) -C source/discovery win32
  199. # ---------------------------------------------------------------------------------------------------------------------
  200. # Binaries (win64)
  201. ifeq ($(BUILDING_FOR_WINDOWS),true)
  202. LIBS_WIN64 = $(MODULEDIR)/jackbridge.win64.a
  203. else
  204. LIBS_WIN64 = $(MODULEDIR)/jackbridge.win64e.a
  205. endif
  206. LIBS_WIN64 += $(MODULEDIR)/lilv.win64.a
  207. LIBS_WIN64 += $(MODULEDIR)/rtmempool.win64.a
  208. LIBS_WIN64 += $(MODULEDIR)/water.win64.a
  209. win64: $(LIBS_WIN64)
  210. $(MAKE) -C source/bridges-plugin win64
  211. $(MAKE) -C source/discovery win64
  212. # ---------------------------------------------------------------------------------------------------------------------
  213. # Binaries (wine)
  214. wine32:
  215. $(MAKE) -C source/jackbridge wine32
  216. cp -f $(MODULEDIR)/jackbridge-wine32.dll.so $(CURDIR)/bin/jackbridge-wine32.dll
  217. wine64:
  218. $(MAKE) -C source/jackbridge wine64
  219. cp -f $(MODULEDIR)/jackbridge-wine64.dll.so $(CURDIR)/bin/jackbridge-wine64.dll
  220. # ---------------------------------------------------------------------------------------------------------------------
  221. clean:
  222. $(MAKE) clean -C source/backend
  223. $(MAKE) clean -C source/bridges-plugin
  224. $(MAKE) clean -C source/bridges-ui
  225. $(MAKE) clean -C source/discovery
  226. $(MAKE) clean -C source/frontend
  227. $(MAKE) clean -C source/interposer
  228. $(MAKE) clean -C source/libjack
  229. $(MAKE) clean -C source/modules
  230. $(MAKE) clean -C source/native-plugins
  231. $(MAKE) clean -C source/plugin
  232. $(MAKE) clean -C source/theme
  233. rm -f *~ source/*~
  234. distclean: clean
  235. rm -f bin/*.exe bin/*.dll bin/*.dylib bin/*.so
  236. rm -rf build build-lv2
  237. debug:
  238. $(MAKE) DEBUG=true
  239. doxygen:
  240. $(MAKE) doxygen -C source/backend
  241. stoat:
  242. stoat --recursive ./build/ --suppression ./data/stoat-supression.txt --whitelist ./data/stoat-whitelist.txt --graph-view ./data/stoat-callgraph.png
  243. # stoat --recursive ./build/ \
  244. # --suppression ./data/stoat-supression.txt \
  245. # --whitelist ./data/stoat-whitelist.txt \
  246. # --graph-view ./data/stoat-callgraph.png
  247. # ---------------------------------------------------------------------------------------------------------------------
  248. install_main:
  249. # Create directories
  250. install -d $(DESTDIR)$(BINDIR)
  251. ifeq ($(LINUX),true)
  252. install -d $(DESTDIR)$(LIBDIR)/carla/jack
  253. else
  254. install -d $(DESTDIR)$(LIBDIR)/carla
  255. endif
  256. install -d $(DESTDIR)$(LIBDIR)/pkgconfig
  257. install -d $(DESTDIR)$(INCLUDEDIR)/carla/includes
  258. ifeq ($(HAVE_PYQT),true)
  259. # Create directories (gui)
  260. install -d $(DESTDIR)$(LIBDIR)/carla/styles
  261. install -d $(DESTDIR)$(DATADIR)/applications
  262. install -d $(DESTDIR)$(DATADIR)/icons/hicolor/16x16/apps
  263. install -d $(DESTDIR)$(DATADIR)/icons/hicolor/48x48/apps
  264. install -d $(DESTDIR)$(DATADIR)/icons/hicolor/128x128/apps
  265. install -d $(DESTDIR)$(DATADIR)/icons/hicolor/256x256/apps
  266. install -d $(DESTDIR)$(DATADIR)/icons/hicolor/scalable/apps
  267. install -d $(DESTDIR)$(DATADIR)/mime/packages
  268. install -d $(DESTDIR)$(DATADIR)/carla/resources
  269. install -d $(DESTDIR)$(DATADIR)/carla/patchcanvas
  270. install -d $(DESTDIR)$(DATADIR)/carla/widgets
  271. endif
  272. # -------------------------------------------------------------------------------------------------------------
  273. # Install script files (non-gui)
  274. install -m 755 \
  275. data/carla-single \
  276. $(DESTDIR)$(BINDIR)
  277. # Adjust PREFIX value in script files (non-gui)
  278. sed $(SED_ARGS) 's?X-PREFIX-X?$(PREFIX)?' \
  279. $(DESTDIR)$(BINDIR)/carla-single
  280. # Install backend libs
  281. install -m 644 \
  282. bin/libcarla_*.* \
  283. $(DESTDIR)$(LIBDIR)/carla
  284. # Install other binaries
  285. install -m 755 \
  286. bin/*bridge-* \
  287. bin/carla-discovery-* \
  288. $(DESTDIR)$(LIBDIR)/carla
  289. ifeq ($(LINUX),true)
  290. # Install libjack
  291. install -m 755 \
  292. bin/jack/libjack.so.0 \
  293. $(DESTDIR)$(LIBDIR)/carla/jack
  294. endif
  295. # Install pkg-config files
  296. install -m 644 \
  297. data/*.pc \
  298. $(DESTDIR)$(LIBDIR)/pkgconfig
  299. # Adjust PREFIX, LIBDIR and INCLUDEDIR in pkg-config files
  300. sed $(SED_ARGS) 's?X-PREFIX-X?$(PREFIX)?' \
  301. $(DESTDIR)$(LIBDIR)/pkgconfig/carla-native-plugin.pc \
  302. $(DESTDIR)$(LIBDIR)/pkgconfig/carla-standalone.pc \
  303. $(DESTDIR)$(LIBDIR)/pkgconfig/carla-utils.pc
  304. sed $(SED_ARGS) 's?X-LIBDIR-X?$(LIBDIR)?' \
  305. $(DESTDIR)$(LIBDIR)/pkgconfig/carla-native-plugin.pc \
  306. $(DESTDIR)$(LIBDIR)/pkgconfig/carla-standalone.pc \
  307. $(DESTDIR)$(LIBDIR)/pkgconfig/carla-utils.pc
  308. sed $(SED_ARGS) 's?X-INCLUDEDIR-X?$(INCLUDEDIR)?' \
  309. $(DESTDIR)$(LIBDIR)/pkgconfig/carla-native-plugin.pc \
  310. $(DESTDIR)$(LIBDIR)/pkgconfig/carla-standalone.pc \
  311. $(DESTDIR)$(LIBDIR)/pkgconfig/carla-utils.pc
  312. # Install headers
  313. install -m 644 \
  314. source/backend/CarlaBackend.h \
  315. source/backend/CarlaHost.h \
  316. source/backend/CarlaUtils.h \
  317. source/backend/CarlaEngine.hpp \
  318. source/backend/CarlaPlugin.hpp \
  319. source/includes/CarlaNative.h \
  320. $(DESTDIR)$(INCLUDEDIR)/carla
  321. install -m 644 \
  322. source/includes/CarlaDefines.h \
  323. source/includes/CarlaMIDI.h \
  324. source/includes/CarlaNative.h \
  325. source/includes/CarlaNativePlugin.h \
  326. $(DESTDIR)$(INCLUDEDIR)/carla/includes
  327. # -------------------------------------------------------------------------------------------------------------
  328. ifeq ($(HAVE_PYQT),true)
  329. # Install script files (gui)
  330. install -m 755 \
  331. data/carla \
  332. data/carla-database \
  333. data/carla-jack-multi \
  334. data/carla-jack-single \
  335. data/carla-patchbay \
  336. data/carla-rack \
  337. data/carla-settings \
  338. $(DESTDIR)$(BINDIR)
  339. # Adjust PREFIX value in script files (gui)
  340. sed $(SED_ARGS) 's?X-PREFIX-X?$(PREFIX)?' \
  341. $(DESTDIR)$(BINDIR)/carla \
  342. $(DESTDIR)$(BINDIR)/carla-database \
  343. $(DESTDIR)$(BINDIR)/carla-jack-multi \
  344. $(DESTDIR)$(BINDIR)/carla-jack-single \
  345. $(DESTDIR)$(BINDIR)/carla-patchbay \
  346. $(DESTDIR)$(BINDIR)/carla-rack \
  347. $(DESTDIR)$(BINDIR)/carla-settings
  348. ifeq ($(HAVE_LIBLO),true)
  349. install -m 755 \
  350. data/carla-control \
  351. $(DESTDIR)$(BINDIR)
  352. sed $(SED_ARGS) 's?X-PREFIX-X?$(PREFIX)?' \
  353. $(DESTDIR)$(BINDIR)/carla-control
  354. endif
  355. # Install frontend
  356. install -m 644 \
  357. source/frontend/carla \
  358. source/frontend/carla-control \
  359. source/frontend/carla-jack-multi \
  360. source/frontend/carla-jack-single \
  361. source/frontend/carla-patchbay \
  362. source/frontend/carla-rack \
  363. source/frontend/*.py \
  364. $(DESTDIR)$(DATADIR)/carla/
  365. install -m 644 \
  366. source/frontend/patchcanvas/*.py \
  367. $(DESTDIR)$(DATADIR)/carla/patchcanvas/
  368. install -m 644 \
  369. source/frontend/widgets/*.py \
  370. $(DESTDIR)$(DATADIR)/carla/widgets/
  371. # Adjust LIBDIR and DATADIR value in python code
  372. sed $(SED_ARGS) 's?X_LIBDIR_X = None?X_LIBDIR_X = "$(LIBDIR)"?' \
  373. $(DESTDIR)$(DATADIR)/carla/carla_shared.py
  374. sed $(SED_ARGS) 's?X_DATADIR_X = None?X_DATADIR_X = "$(DATADIR)"?' \
  375. $(DESTDIR)$(DATADIR)/carla/carla_shared.py
  376. # Install resources (gui)
  377. install -m 755 \
  378. bin/resources/carla-plugin \
  379. bin/resources/carla-plugin-patchbay \
  380. bin/resources/*-ui \
  381. $(DESTDIR)$(DATADIR)/carla/resources
  382. ifeq ($(HAVE_THEME),true)
  383. # Install theme
  384. install -m 644 \
  385. bin/styles/* \
  386. $(DESTDIR)$(LIBDIR)/carla/styles
  387. endif
  388. # Install desktop files
  389. install -m 644 data/carla.desktop $(DESTDIR)$(DATADIR)/applications
  390. ifeq ($(HAVE_LIBLO),true)
  391. install -m 644 data/carla-control.desktop $(DESTDIR)$(DATADIR)/applications
  392. endif
  393. # Install mime package
  394. install -m 644 data/carla.xml $(DESTDIR)$(DATADIR)/mime/packages
  395. # Install icons, 16x16
  396. install -m 644 resources/16x16/carla.png $(DESTDIR)$(DATADIR)/icons/hicolor/16x16/apps
  397. install -m 644 resources/16x16/carla-control.png $(DESTDIR)$(DATADIR)/icons/hicolor/16x16/apps
  398. # Install icons, 48x48
  399. install -m 644 resources/48x48/carla.png $(DESTDIR)$(DATADIR)/icons/hicolor/48x48/apps
  400. install -m 644 resources/48x48/carla-control.png $(DESTDIR)$(DATADIR)/icons/hicolor/48x48/apps
  401. # Install icons, 128x128
  402. install -m 644 resources/128x128/carla.png $(DESTDIR)$(DATADIR)/icons/hicolor/128x128/apps
  403. install -m 644 resources/128x128/carla-control.png $(DESTDIR)$(DATADIR)/icons/hicolor/128x128/apps
  404. # Install icons, 256x256
  405. install -m 644 resources/256x256/carla.png $(DESTDIR)$(DATADIR)/icons/hicolor/256x256/apps
  406. install -m 644 resources/256x256/carla-control.png $(DESTDIR)$(DATADIR)/icons/hicolor/256x256/apps
  407. # Install icons, scalable
  408. install -m 644 resources/scalable/carla.svg $(DESTDIR)$(DATADIR)/icons/hicolor/scalable/apps
  409. install -m 644 resources/scalable/carla-control.svg $(DESTDIR)$(DATADIR)/icons/hicolor/scalable/apps
  410. # Install resources (re-use python files)
  411. $(LINK) ../patchcanvas $(DESTDIR)$(DATADIR)/carla/resources
  412. $(LINK) ../widgets $(DESTDIR)$(DATADIR)/carla/resources
  413. $(LINK) ../carla_app.py $(DESTDIR)$(DATADIR)/carla/resources
  414. $(LINK) ../carla_backend.py $(DESTDIR)$(DATADIR)/carla/resources
  415. $(LINK) ../carla_backend_qt.py $(DESTDIR)$(DATADIR)/carla/resources
  416. $(LINK) ../carla_control.py $(DESTDIR)$(DATADIR)/carla/resources
  417. $(LINK) ../carla_database.py $(DESTDIR)$(DATADIR)/carla/resources
  418. $(LINK) ../carla_host.py $(DESTDIR)$(DATADIR)/carla/resources
  419. $(LINK) ../carla_settings.py $(DESTDIR)$(DATADIR)/carla/resources
  420. $(LINK) ../carla_skin.py $(DESTDIR)$(DATADIR)/carla/resources
  421. $(LINK) ../carla_shared.py $(DESTDIR)$(DATADIR)/carla/resources
  422. $(LINK) ../carla_utils.py $(DESTDIR)$(DATADIR)/carla/resources
  423. $(LINK) ../carla_widgets.py $(DESTDIR)$(DATADIR)/carla/resources
  424. $(LINK) ../externalui.py $(DESTDIR)$(DATADIR)/carla/resources
  425. $(LINK) ../resources_rc.py $(DESTDIR)$(DATADIR)/carla/resources
  426. $(LINK) ../ui_carla_about.py $(DESTDIR)$(DATADIR)/carla/resources
  427. $(LINK) ../ui_carla_add_jack.py $(DESTDIR)$(DATADIR)/carla/resources
  428. $(LINK) ../ui_carla_database.py $(DESTDIR)$(DATADIR)/carla/resources
  429. $(LINK) ../ui_carla_edit.py $(DESTDIR)$(DATADIR)/carla/resources
  430. $(LINK) ../ui_carla_host.py $(DESTDIR)$(DATADIR)/carla/resources
  431. $(LINK) ../ui_carla_parameter.py $(DESTDIR)$(DATADIR)/carla/resources
  432. $(LINK) ../ui_carla_plugin_calf.py $(DESTDIR)$(DATADIR)/carla/resources
  433. $(LINK) ../ui_carla_plugin_classic.py $(DESTDIR)$(DATADIR)/carla/resources
  434. $(LINK) ../ui_carla_plugin_compact.py $(DESTDIR)$(DATADIR)/carla/resources
  435. $(LINK) ../ui_carla_plugin_default.py $(DESTDIR)$(DATADIR)/carla/resources
  436. $(LINK) ../ui_carla_plugin_presets.py $(DESTDIR)$(DATADIR)/carla/resources
  437. $(LINK) ../ui_carla_refresh.py $(DESTDIR)$(DATADIR)/carla/resources
  438. $(LINK) ../ui_carla_settings.py $(DESTDIR)$(DATADIR)/carla/resources
  439. $(LINK) ../ui_carla_settings_driver.py $(DESTDIR)$(DATADIR)/carla/resources
  440. $(LINK) ../ui_inputdialog_value.py $(DESTDIR)$(DATADIR)/carla/resources
  441. $(LINK) ../ui_midipattern.py $(DESTDIR)$(DATADIR)/carla/resources
  442. endif # HAVE_PYQT
  443. # -------------------------------------------------------------------------------------------------------------
  444. # Install lv2 plugin
  445. install -d $(DESTDIR)$(LIBDIR)/lv2/carla.lv2
  446. install -m 644 \
  447. bin/carla.lv2/carla.* \
  448. bin/carla.lv2/*.ttl \
  449. $(DESTDIR)$(LIBDIR)/lv2/carla.lv2
  450. # Link binaries for lv2 plugin
  451. @for i in `find $(DESTDIR)$(LIBDIR)/carla/ -maxdepth 1 -type f -exec basename {} ';'`; do \
  452. $(LINK) ../../carla/$$i $(DESTDIR)$(LIBDIR)/lv2/carla.lv2/$$i; \
  453. done
  454. rm -f $(DESTDIR)$(LIBDIR)/lv2/carla.lv2/libcarla_standalone2.*
  455. ifeq ($(LINUX),true)
  456. # Link jack app bridge
  457. rm -rf $(DESTDIR)$(LIBDIR)/lv2/carla.lv2/jack
  458. $(LINK) ../../carla/jack $(DESTDIR)$(LIBDIR)/lv2/carla.lv2/jack
  459. endif
  460. # Link resources for lv2 plugin
  461. rm -rf $(DESTDIR)$(LIBDIR)/lv2/carla.lv2/resources
  462. $(LINK) ../../../share/carla/resources $(DESTDIR)$(LIBDIR)/lv2/carla.lv2/resources
  463. ifeq ($(HAVE_PYQT),true)
  464. # Link styles for lv2 plugin
  465. rm -rf $(DESTDIR)$(LIBDIR)/lv2/carla.lv2/styles
  466. $(LINK) ../../carla/styles $(DESTDIR)$(LIBDIR)/lv2/carla.lv2/styles
  467. endif
  468. # -------------------------------------------------------------------------------------------------------------
  469. ifneq ($(HAIKU),true)
  470. ifeq ($(HAVE_PYQT),true)
  471. # Install vst plugin
  472. install -d $(DESTDIR)$(LIBDIR)/vst/carla.vst
  473. install -m 644 \
  474. bin/CarlaRack*.* \
  475. bin/CarlaPatchbay*.* \
  476. $(DESTDIR)$(LIBDIR)/vst/carla.vst
  477. # Link binaries for vst plugin
  478. @for i in `find $(DESTDIR)$(LIBDIR)/carla/ -maxdepth 1 -type f -exec basename {} ';'`; do \
  479. $(LINK) ../../carla/$$i $(DESTDIR)$(LIBDIR)/vst/carla.vst/$$i; \
  480. done
  481. rm -f $(DESTDIR)$(LIBDIR)/vst/carla.vst/libcarla_standalone2.*
  482. # Link jack app bridge
  483. rm -rf $(DESTDIR)$(LIBDIR)/vst/carla.vst/jack
  484. $(LINK) ../../carla/jack $(DESTDIR)$(LIBDIR)/vst/carla.vst/jack
  485. # Link resources for vst plugin
  486. rm -rf $(DESTDIR)$(LIBDIR)/vst/carla.vst/resources
  487. $(LINK) ../../../share/carla/resources $(DESTDIR)$(LIBDIR)/vst/carla.vst/resources
  488. # Link styles for vst plugin
  489. rm -rf $(DESTDIR)$(LIBDIR)/vst/carla.vst/styles
  490. $(LINK) ../../carla/styles $(DESTDIR)$(LIBDIR)/vst/carla.vst/styles
  491. endif
  492. endif
  493. ifneq ($(EXTERNAL_PLUGINS),true)
  494. install_external_plugins:
  495. endif
  496. install: install_main install_external_plugins
  497. # ---------------------------------------------------------------------------------------------------------------------
  498. uninstall:
  499. rm -f $(DESTDIR)$(BINDIR)/carla*
  500. rm -f $(DESTDIR)$(LIBDIR)/pkgconfig/carla-native-plugin.pc
  501. rm -f $(DESTDIR)$(LIBDIR)/pkgconfig/carla-standalone.pc
  502. rm -f $(DESTDIR)$(LIBDIR)/pkgconfig/carla-utils.pc
  503. rm -f $(DESTDIR)$(DATADIR)/applications/carla.desktop
  504. rm -f $(DESTDIR)$(DATADIR)/applications/carla-control.desktop
  505. rm -f $(DESTDIR)$(DATADIR)/icons/hicolor/*/apps/carla.png
  506. rm -f $(DESTDIR)$(DATADIR)/icons/hicolor/*/apps/carla-control.png
  507. rm -f $(DESTDIR)$(DATADIR)/icons/hicolor/scalable/apps/carla.svg
  508. rm -f $(DESTDIR)$(DATADIR)/icons/hicolor/scalable/apps/carla-control.svg
  509. rm -f $(DESTDIR)$(DATADIR)/mime/packages/carla.xml
  510. rm -rf $(DESTDIR)$(LIBDIR)/carla
  511. rm -rf $(DESTDIR)$(LIBDIR)/lv2/carla.lv2
  512. rm -rf $(DESTDIR)$(LIBDIR)/lv2/carla-native.lv2
  513. rm -rf $(DESTDIR)$(LIBDIR)/vst/carla.vst
  514. rm -rf $(DESTDIR)$(DATADIR)/carla
  515. rm -rf $(DESTDIR)$(INCLUDEDIR)/carla
  516. # ----------------------------------------------------------------------------------------------------------------------------
  517. ifneq ($(MAKE_TERMOUT),)
  518. ANS_NO=\033[31mNO\033[0m
  519. ANS_YES=\033[32mYES\033[0m
  520. mS=\033[33m[
  521. mZ=\033[30;1m[
  522. mE=]\033[0m
  523. tS=\033[36m
  524. tE=\033[0m
  525. else
  526. ANS_NO=NO
  527. ANS_YES=YES
  528. mS=[
  529. mZ=[
  530. mE=]
  531. endif
  532. features_print_main:
  533. @printf -- "$(tS)---> Main features $(tE)\n"
  534. ifeq ($(HAVE_PYQT),true)
  535. @printf -- "Front-End: $(ANS_YES)\n"
  536. ifneq ($(WIN32),true)
  537. @printf -- "LV2 plugin: $(ANS_YES)\n"
  538. else
  539. @printf -- "LV2 plugin: $(ANS_NO) $(mZ)Not available for Windows$(mE)\n"
  540. endif
  541. ifeq ($(LINUX),true)
  542. ifeq ($(HAVE_X11),true)
  543. @printf -- "VST plugin: $(ANS_YES)\n"
  544. else # HAVE_X11
  545. @printf -- "VST plugin: $(ANS_NO) $(mS)X11 missing$(mE)\n"
  546. endif
  547. else # LINUX
  548. @printf -- "VST plugin: $(ANS_NO) $(mZ)Linux only$(mE)\n"
  549. endif
  550. else
  551. @printf -- "Front-End: $(ANS_NO) $(mS)Missing PyQt$(mE)\n"
  552. @printf -- "LV2 plugin: $(ANS_NO) $(mS)No front-end$(mE)\n"
  553. @printf -- "VST plugin: $(ANS_NO) $(mS)No front-end$(mE)\n"
  554. endif
  555. ifeq ($(HAVE_HYLIA),true)
  556. @printf -- "Link support: $(ANS_YES)\n"
  557. else
  558. ifeq ($(MACOS_OLD),true)
  559. @printf -- "Link support: $(ANS_NO) $(mZ)MacOS >= 10.10 only$(mE)\n"
  560. else
  561. @printf -- "Link support: $(ANS_NO) $(mZ)Linux, MacOS and Windows only$(mE)\n"
  562. endif
  563. endif
  564. ifeq ($(HAVE_LIBLO),true)
  565. @printf -- "OSC support: $(ANS_YES)\n"
  566. else
  567. @printf -- "OSC support: $(ANS_NO) $(mS)Missing liblo$(mE)\n"
  568. endif
  569. ifeq ($(WIN32),true)
  570. @printf -- "Binary detect: $(ANS_YES)\n"
  571. else
  572. ifeq ($(HAVE_LIBMAGIC),true)
  573. @printf -- "Binary detect: $(ANS_YES)\n"
  574. else
  575. @printf -- "Binary detect: $(ANS_NO) $(mS)Missing libmagic/file$(mE)\n"
  576. endif
  577. endif
  578. @printf -- "\n"
  579. @printf -- "$(tS)---> Engine drivers $(tE)\n"
  580. @printf -- "JACK: $(ANS_YES)\n"
  581. ifeq ($(LINUX),true)
  582. ifeq ($(HAVE_ALSA),true)
  583. @printf -- "ALSA: $(ANS_YES)\n"
  584. else
  585. @printf -- "ALSA: $(ANS_NO) $(mS)Missing ALSA$(mE)\n"
  586. endif
  587. else
  588. @printf -- "ALSA: $(ANS_NO) $(mZ)Linux only$(mE)\n"
  589. endif
  590. ifeq ($(UNIX),true)
  591. ifneq ($(MACOS),true)
  592. ifeq ($(HAVE_PULSEAUDIO),true)
  593. @printf -- "PulseAudio: $(ANS_YES)\n"
  594. else
  595. @printf -- "PulseAudio: $(ANS_NO) $(mS)Missing PulseAudio$(mE)\n"
  596. endif
  597. else
  598. @printf -- "PulseAudio: $(ANS_NO) $(mZ)Not available for MacOS$(mE)\n"
  599. endif
  600. else
  601. @printf -- "PulseAudio: $(ANS_NO) $(mZ)Only available for Unix systems$(mE)\n"
  602. endif
  603. ifeq ($(MACOS),true)
  604. @printf -- "CoreAudio: $(ANS_YES)\n"
  605. else
  606. @printf -- "CoreAudio: $(ANS_NO) $(mZ)MacOS only$(mE)\n"
  607. endif
  608. ifeq ($(WIN32),true)
  609. @printf -- "ASIO: $(ANS_YES)\n"
  610. @printf -- "DirectSound: $(ANS_YES)\n"
  611. @printf -- "WASAPI: $(ANS_YES)\n"
  612. else
  613. @printf -- "ASIO: $(ANS_NO) $(mZ)Windows only$(mE)\n"
  614. @printf -- "DirectSound: $(ANS_NO) $(mZ)Windows only$(mE)\n"
  615. @printf -- "WASAPI: $(ANS_NO) $(mZ)Windows only$(mE)\n"
  616. endif
  617. @printf -- "\n"
  618. @printf -- "$(tS)---> Plugin formats: $(tE)\n"
  619. @printf -- "Internal: $(ANS_YES)\n"
  620. @printf -- "LADSPA: $(ANS_YES)\n"
  621. @printf -- "DSSI: $(ANS_YES)\n"
  622. @printf -- "LV2: $(ANS_YES)\n"
  623. ifeq ($(MACOS_OR_WIN32),true)
  624. @printf -- "VST: $(ANS_YES) (with UI)\n"
  625. else
  626. ifeq ($(HAIKU),true)
  627. @printf -- "VST: $(ANS_YES) (without UI)\n"
  628. else
  629. ifeq ($(HAVE_X11),true)
  630. @printf -- "VST: $(ANS_YES) (with UI)\n"
  631. else
  632. @printf -- "VST: $(ANS_YES) (without UI) $(mS)Missing X11$(mE)\n"
  633. endif
  634. endif
  635. endif
  636. @printf -- "\n"
  637. @printf -- "$(tS)---> LV2 UI toolkit support: $(tE)\n"
  638. @printf -- "External: $(ANS_YES) (direct)\n"
  639. ifneq ($(MACOS_OR_WIN32),true)
  640. ifeq ($(HAVE_GTK2),true)
  641. @printf -- "Gtk2: $(ANS_YES) (bridge)\n"
  642. else
  643. @printf -- "Gtk2: $(ANS_NO) $(mS)Gtk2 missing$(mE)\n"
  644. endif
  645. ifeq ($(HAVE_GTK3),true)
  646. @printf -- "Gtk3: $(ANS_YES) (bridge)\n"
  647. else
  648. @printf -- "Gtk3: $(ANS_NO) $(mS)Gtk3 missing$(mE)\n"
  649. endif
  650. ifeq ($(HAVE_QT4),true)
  651. @printf -- "Qt4: $(ANS_YES) (bridge)\n"
  652. else
  653. @printf -- "Qt4: $(ANS_NO) $(mS)Qt4 missing$(mE)\n"
  654. endif
  655. ifeq ($(HAVE_QT5),true)
  656. @printf -- "Qt5: $(ANS_YES) (bridge)\n"
  657. else
  658. @printf -- "Qt5: $(ANS_NO) $(mS)Qt5 missing$(mE)\n"
  659. endif
  660. ifeq ($(HAVE_X11),true)
  661. @printf -- "X11: $(ANS_YES) (direct+bridge)\n"
  662. else
  663. @printf -- "X11: $(ANS_NO) $(mS)X11 missing$(mE)\n"
  664. endif
  665. else # LINUX
  666. @printf -- "Gtk2: $(ANS_NO) $(mZ)Not available for Windows or MacOS$(mE)\n"
  667. @printf -- "Gtk3: $(ANS_NO) $(mZ)Not available for Windows or MacOS$(mE)\n"
  668. @printf -- "Qt4: $(ANS_NO) $(mZ)Not available for Windows or MacOS$(mE)\n"
  669. @printf -- "Qt5: $(ANS_NO) $(mZ)Not available for Windows or MacOS$(mE)\n"
  670. @printf -- "X11: $(ANS_NO) $(mZ)Not available for Windows or MacOS$(mE)\n"
  671. endif # LINUX
  672. ifeq ($(MACOS),true)
  673. @printf -- "Cocoa: $(ANS_YES) (direct+bridge)\n"
  674. else
  675. @printf -- "Cocoa: $(ANS_NO) $(mZ)MacOS only$(mE)\n"
  676. endif
  677. ifeq ($(WIN32),true)
  678. @printf -- "Windows: $(ANS_YES) (direct+bridge)\n"
  679. else
  680. @printf -- "Windows: $(ANS_NO) $(mZ)Windows only$(mE)\n"
  681. endif
  682. @printf -- "\n"
  683. @printf -- "$(tS)---> File formats: $(tE)\n"
  684. ifeq ($(HAVE_SNDFILE),true)
  685. @printf -- "Basic: $(ANS_YES)\n"
  686. else
  687. @printf -- "Basic: $(ANS_NO) $(mS)libsndfile missing$(mE)\n"
  688. endif
  689. ifeq ($(HAVE_FFMPEG),true)
  690. @printf -- "Extra: $(ANS_YES)\n"
  691. else
  692. @printf -- "Extra: $(ANS_NO) $(mS)FFmpeg missing or too new$(mE)\n"
  693. endif
  694. ifeq ($(HAVE_FLUIDSYNTH),true)
  695. @printf -- "SF2/3: $(ANS_YES)\n"
  696. else
  697. @printf -- "SF2/3: $(ANS_NO) $(mS)FluidSynth missing or too old$(mE)\n"
  698. endif
  699. @printf -- "SFZ: $(ANS_YES)\n"
  700. @printf -- "\n"
  701. @printf -- "$(tS)---> Internal plugins: $(tE)\n"
  702. @printf -- "Basic Plugins: $(ANS_YES)\n"
  703. ifneq ($(WIN32),true)
  704. @printf -- "Carla-Patchbay: $(ANS_YES)\n"
  705. @printf -- "Carla-Rack: $(ANS_YES)\n"
  706. else
  707. @printf -- "Carla-Patchbay: $(ANS_NO) $(mS)Not available for Windows$(mE)\n"
  708. @printf -- "Carla-Rack: $(ANS_NO) $(mS)Not available for Windows$(mE)\n"
  709. endif
  710. ifeq ($(EXTERNAL_PLUGINS),true)
  711. @printf -- "External Plugins: $(ANS_YES)\n"
  712. else
  713. @printf -- "External Plugins: $(ANS_NO)\n"
  714. endif
  715. ifneq ($(EXTERNAL_PLUGINS),true)
  716. features_print_external_plugins:
  717. endif
  718. features: features_print_main features_print_external_plugins
  719. # ---------------------------------------------------------------------------------------------------------------------
  720. .FORCE:
  721. .PHONY: .FORCE
  722. # ---------------------------------------------------------------------------------------------------------------------