Last active
April 11, 2024 12:49
-
-
Save SpotlightKid/828a2c44906f4a1e3ea5ac8b24daed66 to your computer and use it in GitHub Desktop.
Generic FAUST to LV2 plugin makefile
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
DESTDIR ?= | |
PREFIX ?= /usr | |
LV2_DIR ?= $(PREFIX)/lib/lv2 | |
FAUSTFLAGS ?= -nvoices 4 | |
NAME ?= mydsp | |
FAUST_DSP = $(NAME).dsp | |
LV2_BUNDLE = $(NAME).lv2 | |
ROOT_DIR:=$(shell dirname "$(realpath $(firstword $(MAKEFILE_LIST)))") | |
all: $(LV2_BUNDLE) | |
$(LV2_BUNDLE): $(FAUST_DSP) | |
faust2lv2 $(FAUSTFLAGS) $< | |
install: uninstall $(LV2_BUNDLE) | |
@install -v -Dm 755 $(LV2_BUNDLE)/*.so -t $(DESTDIR)$(LV2_DIR)/$(LV2_BUNDLE) | |
@install -v -Dm 644 $(LV2_BUNDLE)/*.ttl -t $(DESTDIR)$(LV2_DIR)/$(LV2_BUNDLE) | |
install-link: uninstall | |
ln -s $(ROOT_DIR)/$(LV2_BUNDLE) $(DESTDIR)$(LV2_DIR)/$(LV2_BUNDLE) | |
uninstall: | |
rm -rf $(LV2_DIR)/$(LV2_BUNDLE) | |
clean: | |
rm -rf $(LV2_BUNDLE) | |
.PHONY: all clean install install-link uninstall |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment