2021-10-07 13:00:47 +03:00
|
|
|
#!/usr/bin/make -f
|
|
|
|
# Makefile for DISTRHO Plugins #
|
|
|
|
# ---------------------------- #
|
|
|
|
# Created by falkTX
|
|
|
|
#
|
|
|
|
|
|
|
|
include dpf/Makefile.base.mk
|
|
|
|
|
2021-10-21 14:03:01 +03:00
|
|
|
all: cardinal deps dgl plugins gen resources
|
|
|
|
|
|
|
|
# --------------------------------------------------------------
|
|
|
|
# Build config
|
|
|
|
|
|
|
|
PREFIX ?= /usr/local
|
|
|
|
DESTDIR ?=
|
|
|
|
SYSDEPS ?= false
|
|
|
|
|
|
|
|
# --------------------------------------------------------------
|
|
|
|
# Check for system-wide dependencies
|
|
|
|
|
2021-10-21 19:35:41 +03:00
|
|
|
ifeq ($(SYSDEPS),true)
|
|
|
|
|
|
|
|
ifneq ($(shell pkg-config --exists jansson && echo true),true)
|
|
|
|
$(error jansson dpendency not installed/available)
|
|
|
|
endif
|
|
|
|
ifneq ($(shell pkg-config --exists libarchive && echo true),true)
|
|
|
|
$(error libarchive dpendency not installed/available)
|
|
|
|
endif
|
|
|
|
ifneq ($(shell pkg-config --exists samplerate && echo true),true)
|
|
|
|
$(error samplerate dpendency not installed/available)
|
|
|
|
endif
|
|
|
|
ifneq ($(shell pkg-config --exists speexdsp && echo true),true)
|
|
|
|
$(error speexdsp dpendency not installed/available)
|
|
|
|
endif
|
|
|
|
|
|
|
|
endif
|
2021-10-07 13:00:47 +03:00
|
|
|
|
|
|
|
# --------------------------------------------------------------
|
|
|
|
|
2021-10-17 01:48:44 +03:00
|
|
|
cardinal: deps dgl plugins
|
|
|
|
$(MAKE) all -C src
|
|
|
|
|
|
|
|
deps:
|
2021-10-21 19:35:41 +03:00
|
|
|
ifneq ($(SYSDEPS),true)
|
2021-10-17 01:48:44 +03:00
|
|
|
$(MAKE) all -C deps
|
2021-10-21 19:35:41 +03:00
|
|
|
endif
|
2021-10-17 01:48:44 +03:00
|
|
|
|
2021-10-07 13:00:47 +03:00
|
|
|
dgl:
|
2021-10-21 22:23:00 +03:00
|
|
|
$(MAKE) USE_NANOVG_FBO=true -C dpf/dgl opengl
|
|
|
|
# $(MAKE) opengl -C dpf/dgl USE_NANOVG_FBO=true
|
2021-10-07 13:00:47 +03:00
|
|
|
|
2021-10-17 01:48:44 +03:00
|
|
|
plugins: deps
|
|
|
|
$(MAKE) all -C plugins
|
2021-10-07 13:00:47 +03:00
|
|
|
|
2021-10-21 20:16:22 +03:00
|
|
|
resources: cardinal
|
2021-10-21 14:03:01 +03:00
|
|
|
$(MAKE) resources -C plugins
|
|
|
|
|
2021-10-07 13:00:47 +03:00
|
|
|
ifneq ($(CROSS_COMPILING),true)
|
2021-10-21 20:16:22 +03:00
|
|
|
gen: cardinal resources dpf/utils/lv2_ttl_generator
|
2021-10-07 13:00:47 +03:00
|
|
|
@$(CURDIR)/dpf/utils/generate-ttl.sh
|
|
|
|
|
|
|
|
dpf/utils/lv2_ttl_generator:
|
|
|
|
$(MAKE) -C dpf/utils/lv2-ttl-generator
|
|
|
|
else
|
|
|
|
gen:
|
|
|
|
endif
|
|
|
|
|
|
|
|
# --------------------------------------------------------------
|
|
|
|
|
|
|
|
clean:
|
2021-10-17 01:48:44 +03:00
|
|
|
$(MAKE) clean -C deps
|
2021-10-07 13:00:47 +03:00
|
|
|
$(MAKE) clean -C dpf/dgl
|
|
|
|
$(MAKE) clean -C dpf/utils/lv2-ttl-generator
|
2021-10-17 01:48:44 +03:00
|
|
|
$(MAKE) clean -C plugins
|
|
|
|
$(MAKE) clean -C src
|
2021-10-07 13:00:47 +03:00
|
|
|
rm -rf bin build
|
|
|
|
|
|
|
|
# --------------------------------------------------------------
|
|
|
|
|
2021-10-21 19:10:54 +03:00
|
|
|
install:
|
|
|
|
install -d $(DESTDIR)$(PREFIX)/bin
|
|
|
|
install -d $(DESTDIR)$(PREFIX)/lib/lv2
|
|
|
|
install -d $(DESTDIR)$(PREFIX)/lib/vst
|
|
|
|
install -d $(DESTDIR)$(PREFIX)/lib/vst3
|
|
|
|
install -d $(DESTDIR)$(PREFIX)/share/Cardinal
|
|
|
|
|
|
|
|
cp -rL bin/Cardinal.lv2 $(DESTDIR)$(PREFIX)/lib/lv2/
|
|
|
|
cp -rL bin/Cardinal.vst $(DESTDIR)$(PREFIX)/lib/vst/
|
|
|
|
cp -rL bin/Cardinal.vst3 $(DESTDIR)$(PREFIX)/lib/vst3/
|
|
|
|
|
|
|
|
install -m 755 bin/Cardinal$(APP_EXT) $(DESTDIR)$(PREFIX)/bin/
|
|
|
|
cp -rL bin/Cardinal.lv2/resources/* $(DESTDIR)$(PREFIX)/share/Cardinal/
|
|
|
|
|
|
|
|
# --------------------------------------------------------------
|
|
|
|
|
2021-10-17 01:48:44 +03:00
|
|
|
.PHONY: deps plugins
|