This commit is contained in:
Armin 2026-07-23 23:40:48 +02:00
commit d21bc831e1
178 changed files with 24136 additions and 0 deletions

70
Makefile Normal file
View file

@ -0,0 +1,70 @@
PLUGIN_NAME := Just a Sample
BUILD_DIR := out/build/macos
CMAKE_FLAGS := -G "Unix Makefiles" -DCMAKE_BUILD_TYPE=Release \
-DCMAKE_OSX_ARCHITECTURES="arm64" \
-DCMAKE_OSX_DEPLOYMENT_TARGET="10.13" \
-DJAS_ENABLE_AVX2=OFF
NPROC := $(shell sysctl -n hw.ncpu 2>/dev/null || echo 4)
VST3_SRC := $(BUILD_DIR)/JustASample_artefacts/Release/VST3/$(PLUGIN_NAME).vst3
AU_SRC := $(BUILD_DIR)/JustASample_artefacts/Release/AU/$(PLUGIN_NAME).component
VST3_DST := $(HOME)/Library/Audio/Plug-Ins/VST3/$(PLUGIN_NAME).vst3
AU_DST := $(HOME)/Library/Audio/Plug-Ins/Components/$(PLUGIN_NAME).component
# ---------- phony targets ----------
.PHONY: all install uninstall clean help configure build build-au build-all
all: install
configure: $(BUILD_DIR)/Makefile
$(BUILD_DIR)/Makefile:
cmake -B $(BUILD_DIR) $(CMAKE_FLAGS)
build: configure
cmake --build $(BUILD_DIR) --target JustASample_VST3 -j$(NPROC)
build-au: configure
cmake --build $(BUILD_DIR) --target JustASample_AU -j$(NPROC)
build-all: configure
cmake --build $(BUILD_DIR) --target JustASample_All -j$(NPROC)
install: install-vst3 install-au
install-vst3: build
@mkdir -p "$(VST3_DST)"
rm -rf "$(VST3_DST)"
cp -R "$(VST3_SRC)" "$(VST3_DST)"
@echo "Installed VST3 to $(VST3_DST)"
install-au: build-au
@mkdir -p "$(AU_DST)"
rm -rf "$(AU_DST)"
cp -R "$(AU_SRC)" "$(AU_DST)"
@echo "Installed AU to $(AU_DST)"
install-all: build-all install-vst3 install-au
uninstall:
rm -rf "$(VST3_DST)" "$(AU_DST)"
@echo "Removed plugin from ~/Library/Audio/Plug-Ins/"
clean:
rm -rf $(BUILD_DIR)
help:
@echo "Targets:"
@echo " make - build and install VST3 + AU (default)"
@echo " make build - build VST3 only"
@echo " make build-au - build AU only"
@echo " make build-all - build all plugin formats"
@echo " make install - install VST3 + AU"
@echo " make install-vst3 - install VST3 only"
@echo " make install-au - install AU only"
@echo " make install-all - install all formats"
@echo " make uninstall - remove all installed copies"
@echo " make clean - remove build directory"
@echo " make help - show this message"