|
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410 |
- #!/usr/bin/make -f
- # Makefile for Carla #
- # ------------------ #
- # Created by falkTX
- #
-
- include source/Makefile.mk
-
- # --------------------------------------------------------------
-
- PREFIX = /usr/local
- DESTDIR =
-
- SED_PREFIX = $(shell echo $(PREFIX) | sed "s/\//\\\\\\\\\//g")
-
- LINK = ln -sf
- PYUIC ?= pyuic4
- PYRCC ?= pyrcc4 -py3
-
- # --------------------------------------------------------------
-
- all: CXX RES UI WIDGETS
-
- # --------------------------------------------------------------
- # C++ code
-
- CXX: backend bridges discovery
-
- backend:
- $(MAKE) -C source/backend
-
- bridges:
- $(MAKE) -C source/bridges
-
- discovery:
- $(MAKE) -C source/discovery
-
- plugin:
- $(MAKE) -C source/plugin
-
- tests:
- $(MAKE) -C source/tests
-
- theme:
- $(MAKE) -C source/theme
-
- widgets:
- $(MAKE) -C source/widgets
-
- posix32:
- $(MAKE) -C source/bridges posix32
- $(MAKE) -C source/discovery posix32
-
- posix64:
- $(MAKE) -C source/bridges posix64
- $(MAKE) -C source/discovery posix64
-
- win32:
- # $(MAKE) -C source/bridges win32
- $(MAKE) -C source/discovery win32
-
- win64:
- $(MAKE) -C source/bridges win64
- $(MAKE) -C source/discovery win64
-
- wine32:
- $(MAKE) -C source/libs jackbridge-win32.dll.so
- $(LINK) ../libs/jackbridge-win32.dll.so source/bridges/jackbridge-win32.dll
-
- wine64:
- $(MAKE) -C source/libs jackbridge-win64.dll.so
- $(LINK) ../libs/jackbridge-win64.dll.so source/bridges/jackbridge-win64.dll
-
- # --------------------------------------------------------------
- # Resources
-
- RES = source/resources_rc.py
-
- RES: $(RES)
-
- source/%_rc.py: resources/%.qrc
- $(PYRCC) $< -o $@
-
- # --------------------------------------------------------------
- # UI code
-
- UIs = \
- source/ui_carla.py \
- source/ui_carla_control.py \
- source/ui_carla_about.py \
- source/ui_carla_database.py \
- source/ui_carla_edit.py \
- source/ui_carla_parameter.py \
- source/ui_carla_plugin.py \
- source/ui_carla_refresh.py \
- source/ui_carla_settings.py \
- source/ui_carla_settings_driver.py \
- source/ui_inputdialog_value.py
-
- UI: $(UIs)
-
- source/ui_%.py: resources/ui/%.ui
- $(PYUIC) $< -o $@
-
- # --------------------------------------------------------------
- # Widgets
-
- WIDGETS = \
- source/canvaspreviewframe.py \
- source/digitalpeakmeter.py \
- source/ledbutton.py \
- source/paramspinbox.py \
- source/pixmapbutton.py \
- source/pixmapdial.py \
- source/pixmapkeyboard.py
-
- WIDGETS: $(WIDGETS)
-
- source/%.py: source/widgets/%.py
- $(LINK) widgets/$*.py $@
-
- # --------------------------------------------------------------
-
- clean:
- $(MAKE) clean -C source/backend
- $(MAKE) clean -C source/bridges
- $(MAKE) clean -C source/discovery
- $(MAKE) clean -C source/libs
- $(MAKE) clean -C source/plugin
- $(MAKE) clean -C source/tests
- $(MAKE) clean -C source/theme
- $(MAKE) clean -C source/widgets
- rm -f $(RES)
- rm -f $(UIs)
- rm -f $(WIDGETS)
- rm -f *~ source/*~ source/*.pyc source/*_rc.py source/ui_*.py
-
- # --------------------------------------------------------------
-
- debug:
- $(MAKE) DEBUG=true
-
- # --------------------------------------------------------------
-
- install:
- # Create directories
- install -d $(DESTDIR)$(PREFIX)/bin/
- install -d $(DESTDIR)$(PREFIX)/lib/carla/
- install -d $(DESTDIR)$(PREFIX)/lib/carla/resources/
- install -d $(DESTDIR)$(PREFIX)/lib/carla/resources/nekofilter/
- install -d $(DESTDIR)$(PREFIX)/lib/carla/resources/zynaddsubfx/
- ifeq ($(CARLA_PLUGIN_SUPPORT),true)
- install -d $(DESTDIR)$(PREFIX)/lib/dssi/
- install -d $(DESTDIR)$(PREFIX)/lib/lv2/
- install -d $(DESTDIR)$(PREFIX)/lib/lv2/carla.lv2/
- install -d $(DESTDIR)$(PREFIX)/lib/vst/
- endif
- install -d $(DESTDIR)$(PREFIX)/share/applications/
- install -d $(DESTDIR)$(PREFIX)/share/icons/hicolor/16x16/apps/
- install -d $(DESTDIR)$(PREFIX)/share/icons/hicolor/48x48/apps/
- install -d $(DESTDIR)$(PREFIX)/share/icons/hicolor/128x128/apps/
- install -d $(DESTDIR)$(PREFIX)/share/icons/hicolor/256x256/apps/
- install -d $(DESTDIR)$(PREFIX)/share/icons/hicolor/scalable/apps/
- install -d $(DESTDIR)$(PREFIX)/share/carla/
-
- # Install script files
- install -m 755 \
- data/carla \
- data/carla-control \
- data/carla-single \
- $(DESTDIR)$(PREFIX)/bin/
-
- # Install desktop files
- install -m 644 data/*.desktop $(DESTDIR)$(PREFIX)/share/applications/
-
- # Install icons, 16x16
- install -m 644 resources/16x16/carla.png $(DESTDIR)$(PREFIX)/share/icons/hicolor/16x16/apps/
- install -m 644 resources/16x16/carla-control.png $(DESTDIR)$(PREFIX)/share/icons/hicolor/16x16/apps/
-
- # Install icons, 48x48
- install -m 644 resources/48x48/carla.png $(DESTDIR)$(PREFIX)/share/icons/hicolor/48x48/apps/
- install -m 644 resources/48x48/carla-control.png $(DESTDIR)$(PREFIX)/share/icons/hicolor/48x48/apps/
-
- # Install icons, 128x128
- install -m 644 resources/128x128/carla.png $(DESTDIR)$(PREFIX)/share/icons/hicolor/128x128/apps/
- install -m 644 resources/128x128/carla-control.png $(DESTDIR)$(PREFIX)/share/icons/hicolor/128x128/apps/
-
- # Install icons, 256x256
- install -m 644 resources/256x256/carla.png $(DESTDIR)$(PREFIX)/share/icons/hicolor/256x256/apps/
- install -m 644 resources/256x256/carla-control.png $(DESTDIR)$(PREFIX)/share/icons/hicolor/256x256/apps/
-
- # Install icons, scalable
- install -m 644 resources/scalable/carla.svg $(DESTDIR)$(PREFIX)/share/icons/hicolor/scalable/apps/
- install -m 644 resources/scalable/carla-control.svg $(DESTDIR)$(PREFIX)/share/icons/hicolor/scalable/apps/
-
- # Install binaries
- install -m 755 \
- source/backend/*.so \
- source/bridges/carla-bridge-* \
- source/discovery/carla-discovery-* \
- $(DESTDIR)$(PREFIX)/lib/carla/
-
- # Install python code
- install -m 755 source/*.py $(DESTDIR)$(PREFIX)/share/carla/
-
- # Install resources
- install -m 644 source/backend/resources/nekofilter-ui $(DESTDIR)$(PREFIX)/lib/carla/resources/
- install -m 644 source/backend/resources/nekofilter/*.png $(DESTDIR)$(PREFIX)/lib/carla/resources/nekofilter/
- install -m 644 source/backend/resources/zynaddsubfx/*.png $(DESTDIR)$(PREFIX)/lib/carla/resources/zynaddsubfx/
-
- # ifeq ($(CARLA_PLUGIN_SUPPORT),true)
- # # Install plugin
- # install -m 644 source/plugin/carla-dssi.so $(DESTDIR)$(PREFIX)/lib/dssi/
- # install -m 644 source/plugin/carla-vst.so $(DESTDIR)$(PREFIX)/lib/vst/
- # install -m 644 source/plugin/carla.lv2/* $(DESTDIR)$(PREFIX)/lib/lv2/carla.lv2/
- # endif
-
- # Adjust PREFIX value in script files
- sed -i "s/X-PREFIX-X/$(SED_PREFIX)/" \
- $(DESTDIR)$(PREFIX)/bin/carla \
- $(DESTDIR)$(PREFIX)/bin/carla-control \
- $(DESTDIR)$(PREFIX)/bin/carla-single
-
- # --------------------------------------------------------------
-
- uninstall:
- rm -f $(DESTDIR)$(PREFIX)/bin/carla*
- rm -f $(DESTDIR)$(PREFIX)/share/applications/carla.desktop
- rm -f $(DESTDIR)$(PREFIX)/share/applications/carla-control.desktop
- rm -f $(DESTDIR)$(PREFIX)/share/icons/hicolor/*/apps/carla.png
- rm -f $(DESTDIR)$(PREFIX)/share/icons/hicolor/*/apps/carla-control.png
- rm -f $(DESTDIR)$(PREFIX)/share/icons/hicolor/scalable/apps/carla.svg
- rm -f $(DESTDIR)$(PREFIX)/share/icons/hicolor/scalable/apps/carla-control.svg
- rm -f $(DESTDIR)$(PREFIX)/lib/dssi/carla-dssi.so
- rm -f $(DESTDIR)$(PREFIX)/lib/vst/carla-vst.so
- rm -rf $(DESTDIR)$(PREFIX)/lib/carla/
- rm -rf $(DESTDIR)$(PREFIX)/lib/lv2/carla.lv2/
- rm -rf $(DESTDIR)$(PREFIX)/share/carla/
-
- # --------------------------------------------------------------
-
- ANS_NO=\033[31m NO \033[0m
- ANS_YES=\033[32m YES \033[0m
- mS=\033[33m[
- mE=]\033[0m
-
- features:
- ifeq ($(MACOS),true)
- # --- MacOS ---
- @echo "\033[36m---> Engine drivers: (MacOS)\033[0m"
- @echo "JACK: $(ANS_YES)"
- ifeq ($(CARLA_RTAUDIO_SUPPORT),true)
- @echo "CoreAudio:$(ANS_YES)"
- else
- @echo "CoreAudio:$(ANS_NO) $(mS)RtAudio disabled$(mE)"
- endif
- # --- MacOS ---
- else
- # --- Win32 ---
- ifeq ($(WIN32),true)
- @echo "\033[36m---> Engine drivers: (Windows)\033[0m"
- @echo "JACK: $(ANS_YES)"
- ifeq ($(CARLA_RTAUDIO_SUPPORT),true)
- @echo "ASIO: $(ANS_YES)"
- @echo "DirectSound:$(ANS_YES)"
- else
- @echo "ASIO: $(ANS_NO) $(mS)RtAudio disabled$(mE)"
- @echo "DirectSound:$(ANS_NO) $(mS)RtAudio disabled$(mE)"
- endif
- # --- Win32 ---
- else
- # --- Others ---
- @echo "\033[36m---> Engine drivers: \033[0m"
- @echo "JACK: $(ANS_YES)"
- ifeq ($(CARLA_RTAUDIO_SUPPORT),true)
- ifeq ($(HAVE_ALSA),true)
- @echo "ALSA: $(ANS_YES)"
- else
- @echo "ALSA: $(ANS_NO) $(mS)Missing ALSA$(mE)"
- endif
- ifeq ($(HAVE_PULSEAUDIO),true)
- @echo "PulseAudio:$(ANS_YES)"
- else
- @echo "PulseAudio:$(ANS_NO) $(mS)Missing PulseAudio$(mE)"
- endif
- else
- @echo "ALSA: $(ANS_NO) $(mS)RtAudio disabled$(mE)"
- @echo "PulseAudio:$(ANS_NO) $(mS)RtAudio disabled$(mE)"
- endif
- # --- Others ---
- endif
- endif
- @echo ""
-
- @echo "\033[36m---> Plugin formats: \033[0m"
- @echo "Internal:$(ANS_YES)"
- ifeq ($(CARLA_PLUGIN_SUPPORT),true)
- @echo "LADSPA: $(ANS_YES)"
- @echo "DSSI: $(ANS_YES)"
- @echo "LV2: $(ANS_YES)"
- @echo "VST: $(ANS_YES)"
- else
- @echo "LADSPA: $(ANS_NO) $(mS)Plugins disabled$(mE)"
- @echo "DSSI: $(ANS_NO) $(mS)Plugins disabled$(mE)"
- @echo "LV2: $(ANS_NO) $(mS)Plugins disabled$(mE)"
- @echo "VST: $(ANS_NO) $(mS)Plugins disabled$(mE)"
- endif
- @echo ""
-
- ifeq ($(CARLA_PLUGIN_SUPPORT),true)
- @echo "\033[36m---> LV2 UI toolkit support: \033[0m"
- @echo "ExternalUI:$(ANS_YES) (direct)"
- ifeq ($(MACOS),true)
- # --- MacOS ---
- @echo "CocoaUI: $(ANS_YES) (direct+bridge)"
- # --- MacOS ---
- else
- # --- Win32 ---
- ifeq ($(WIN32),true)
- # --- Win32 ---
- @echo "WindowsUI: $(ANS_YES) (direct+bridge)"
- else
- # --- Others ---
- ifeq ($(HAVE_GTK2),true)
- @echo "GtkUI: $(ANS_YES) (bridge)"
- else
- @echo "GtkUI: $(ANS_NO) $(mS)Gtk2 missing$(mE)"
- endif
- ifeq ($(HAVE_GTK3),true)
- @echo "Gtk3UI: $(ANS_YES) (bridge)"
- else
- @echo "Gtk3UI: $(ANS_NO) $(mS)Gtk3 missing$(mE)"
- endif
- ifeq ($(HAVE_QT4),true)
- @echo "Qt4UI: $(ANS_YES) (direct+bridge)"
- else
- @echo "Qt4UI: $(ANS_NO) $(mS)Qt4 missing$(mE)"
- endif
- ifeq ($(HAVE_QT5),true)
- ifeq ($(HAVE_QT4),true)
- @echo "Qt5UI: $(ANS_YES) (bridge)"
- else
- @echo "Qt5UI: $(ANS_YES) (direct+bridge)"
- endif
- else
- @echo "Qt5UI: $(ANS_NO) $(mS)Qt5 missing$(mE)"
- endif
- @echo "X11UI: $(ANS_YES) (direct+bridge)"
- endif
- # --- Others ---
- endif
- @echo ""
- endif
-
- @echo "\033[36m---> Sample formats: \033[0m"
- ifeq ($(CARLA_SAMPLERS_SUPPORT),true)
- ifeq ($(HAVE_LINUXSAMPLER),true)
- @echo "GIG:$(ANS_YES)"
- else
- @echo "GIG:$(ANS_NO) $(mS)LinuxSampler missing$(mE)"
- endif
- ifeq ($(HAVE_FLUIDSYNTH),true)
- @echo "SF2:$(ANS_YES)"
- else
- @echo "SF2:$(ANS_NO) $(mS)FluidSynth missing$(mE)"
- endif
- ifeq ($(HAVE_LINUXSAMPLER),true)
- @echo "SFZ:$(ANS_YES)"
- else
- @echo "SFZ:$(ANS_NO) $(mS)LinuxSampler missing$(mE)"
- endif
- else
- @echo "GIG:$(ANS_NO) $(mS)Samplers disabled$(mE)"
- @echo "SF2:$(ANS_NO) $(mS)Samplers disabled$(mE)"
- @echo "SFZ:$(ANS_NO) $(mS)Samplers disabled$(mE)"
- endif
- @echo ""
-
- @echo "\033[36m---> Internal plugins: \033[0m"
- ifeq ($(HAVE_AF_DEPS),true)
- ifeq ($(HAVE_FFMPEG),true)
- @echo "AudioFile: $(ANS_YES) (with ffmpeg)"
- else
- @echo "AudioFile: $(ANS_YES) (without ffmpeg) $(mS)ffmpeg/libav missing$(mE)"
- endif
- else
- @echo "AudioFile: $(ANS_NO) $(mS)libsndfile missing$(mE)"
- endif
-
- ifeq ($(HAVE_MF_DEPS),true)
- @echo "MidiFile: $(ANS_YES)"
- else
- @echo "MidiFile: $(ANS_NO) $(mS)libsmf missing$(mE)"
- endif
-
- ifeq ($(HAVE_OPENGL),true)
- @echo "DISTRHO: $(ANS_YES)"
- else
- @echo "DISTRHO: $(ANS_NO) $(mS)OpenGL missing$(mE)"
- endif
-
- ifeq ($(HAVE_ZYN_DEPS),true)
- ifeq ($(HAVE_ZYN_UI_DEPS),true)
- @echo "ZynAddSubFX:$(ANS_YES) (with UI)"
- else
- @echo "ZynAddSubFX:$(ANS_YES) (without UI) $(mS)NTK missing$(mE)"
- endif
- else
- @echo "ZynAddSubFX:$(ANS_NO) $(mS)fftw-3, mxml or zlib missing$(mE)"
- endif
|