Skip to content

Commit

Permalink
macos plugin details, bump version
Browse files Browse the repository at this point in the history
Signed-off-by: falkTX <[email protected]>
  • Loading branch information
falkTX committed Mar 16, 2024
1 parent fa9854b commit d3f6250
Show file tree
Hide file tree
Showing 5 changed files with 111 additions and 12 deletions.
4 changes: 2 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -283,7 +283,7 @@ TARGETS += src/DPF/utils/lv2_ttl_generator$(APP_EXT)
# ---------------------------------------------------------------------------------------------------------------------

all: $(TARGETS)
./utils/run.sh $(PAWPAW_TARGET) $(MAKE) -C src/plugin
./utils/run.sh $(PAWPAW_TARGET) $(MAKE) NOOPT=true -C src/plugin
./utils/run.sh $(PAWPAW_TARGET) $(CURDIR)/src/DPF/utils/generate-ttl.sh build-plugin

clean:
Expand All @@ -300,7 +300,7 @@ clean:
rm -rf build-ui

src/DPF/utils/lv2_ttl_generator$(APP_EXT):
./utils/run.sh $(PAWPAW_TARGET) $(MAKE) -C src/DPF/utils/lv2-ttl-generator
./utils/run.sh $(PAWPAW_TARGET) $(MAKE) NOOPT=true -C src/DPF/utils/lv2-ttl-generator

plugins: $(foreach PLUGIN,$(PLUGINS),$(call PLUGIN_STAMP,$(PLUGIN)))

Expand Down
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
0.0.12
0.0.13
2 changes: 1 addition & 1 deletion src/plugin/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ BUILD_CXX_FLAGS += $(shell $(PKG_CONFIG) --cflags Qt5Core)
LINK_FLAGS += -ldl -lrt
endif

TARGETS = clap lv2_sep vst2 vst3
TARGETS = au clap lv2_sep vst2 vst3

# ---------------------------------------------------------------------------------------------------------------------

Expand Down
93 changes: 86 additions & 7 deletions utils/macos/macos-pkg.sh
Original file line number Diff line number Diff line change
Expand Up @@ -20,11 +20,19 @@ rm -rf mod-ui/modtools/__pycache__
./utils/pack-html.sh

# create pkg dir for placing patched app bundle inside
mkdir build/pkg
gcp -rL "build/mod-desktop.app" "build/pkg/MOD Desktop.app"
mkdir build/pkg build/pkg/app
gcp -rL "build/mod-desktop.app" "build/pkg/app/MOD Desktop.app"

# create pkg dir for plugins
mkdir build/pkg/au build/pkg/clap build/pkg/lv2 build/pkg/vst2 build/pkg/vst3
gcp -rL build-plugin/*.component build/pkg/au/
gcp -rL build-plugin/*.clap build/pkg/clap/
gcp -rL build-plugin/*.lv2 build/pkg/lv2/
gcp -rL build-plugin/*.vst build/pkg/vst2/
gcp -rL build-plugin/*.vst3 build/pkg/vst3/

# patch rpath for Qt libs and jack tools
pushd "build/pkg/MOD Desktop.app/Contents"
pushd "build/pkg/app/MOD Desktop.app/Contents"

rm -rf Frameworks/*/*.prl
rm -rf Frameworks/*/Headers
Expand Down Expand Up @@ -68,15 +76,15 @@ if [ -n "${CODESIGN_APP_IDENTITY}" ]; then
security set-key-partition-list -S apple-tool:,apple: -k dummypassword build.keychain
security list-keychains -d user -s build.keychain login.keychain

pushd "build/pkg/MOD Desktop.app/Contents/LV2"
pushd "build/pkg/app/MOD Desktop.app/Contents/LV2"

for f in $(find . -name "*.dylib"); do
codesign -s "${CODESIGN_APP_IDENTITY}" \
--force \
--verbose \
--timestamp \
--option runtime \
--entitlements "../../../../../utils/macos/entitlements.plist" \
--entitlements "../../../../../../utils/macos/entitlements.plist" \
"${f}"
done

Expand All @@ -89,7 +97,42 @@ if [ -n "${CODESIGN_APP_IDENTITY}" ]; then
--timestamp \
--option runtime \
--entitlements "utils/macos/entitlements.plist" \
"build/pkg/MOD Desktop.app"
"build/pkg/app/MOD Desktop.app"

codesign -s "${CODESIGN_APP_IDENTITY}" \
--deep \
--force \
--verbose \
--timestamp \
--option runtime \
--entitlements "utils/macos/entitlements.plist" \
build/pkg/clap/*.clap

codesign -s "${CODESIGN_APP_IDENTITY}" \
--force \
--verbose \
--timestamp \
--option runtime \
--entitlements "utils/macos/entitlements.plist" \
build/pkg/lv2/*.lv2/*.dylib

codesign -s "${CODESIGN_APP_IDENTITY}" \
--deep \
--force \
--verbose \
--timestamp \
--option runtime \
--entitlements "utils/macos/entitlements.plist" \
build/pkg/vst2/*.vst

codesign -s "${CODESIGN_APP_IDENTITY}" \
--deep \
--force \
--verbose \
--timestamp \
--option runtime \
--entitlements "utils/macos/entitlements.plist" \
build/pkg/vst3/*.vst3

PKG_SIGN_ARGS=(--sign "${CODESIGN_PKG_IDENTITY}")
fi
Expand All @@ -99,10 +142,46 @@ pkgbuild \
--identifier "audio.mod.desktop-app" \
--component-plist "utils/macos/build.plist" \
--install-location "/Applications/" \
--root "${PWD}/build/pkg/" \
--root "${PWD}/build/pkg/app/" \
"${PKG_SIGN_ARGS[@]}" \
build/mod-desktop.pkg

# create plugins pkgs
pkgbuild \
--identifier "audio.mod.desktop-components" \
--install-location "/Library/Audio/Plug-Ins/Components/" \
--root "${PWD}/build/pkg/au/" \
"${PKG_SIGN_ARGS[@]}" \
build/mod-desktop-components.pkg

pkgbuild \
--identifier "audio.mod.desktop-clapbundles" \
--install-location "/Library/Audio/Plug-Ins/CLAP/" \
--root "${PWD}/build/pkg/clap/" \
"${PKG_SIGN_ARGS[@]}" \
build/mod-desktop-clapbundles.pkg

pkgbuild \
--identifier "audio.mod.desktop-lv2bundles" \
--install-location "/Library/Audio/Plug-Ins/LV2/" \
--root "${PWD}/build/pkg/lv2/" \
"${PKG_SIGN_ARGS[@]}" \
build/mod-desktop-lv2bundles.pkg

pkgbuild \
--identifier "audio.mod.desktop-vst2bundles" \
--install-location "/Library/Audio/Plug-Ins/VST/" \
--root "${PWD}/build/pkg/vst2/" \
"${PKG_SIGN_ARGS[@]}" \
build/mod-desktop-vst2bundles.pkg

pkgbuild \
--identifier "audio.mod.desktop-vst3bundles" \
--install-location "/Library/Audio/Plug-Ins/VST3/" \
--root "${PWD}/build/pkg/vst3/" \
"${PKG_SIGN_ARGS[@]}" \
build/mod-desktop-vst3bundles.pkg

# create final pkg
sed -e "s|@builddir@|${PWD}/build|" \
utils/macos/package.xml.in > build/package.xml
Expand Down
22 changes: 21 additions & 1 deletion utils/macos/package.xml.in
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,30 @@
<options customize="always" hostArchitectures="arm64,x86_64" require-scripts="false" rootVolumeOnly="true" />
<pkg-ref id="audio.mod.desktop" />
<welcome file="@builddir@/../utils/macos/welcome.txt" mime-type="text/plain" />
<choice id="audio.mod.desktop-pkg" title="MOD Desktop" description='MOD Desktop macOS bundle' visible="true" enabled="false" selected="true">
<choice id="audio.mod.desktop-pkg" title="MOD Desktop" description='MOD Desktop application' visible="true" enabled="false" selected="true">
<pkg-ref id="audio.mod.desktop-pkg" version="0">mod-desktop.pkg</pkg-ref>
</choice>
<choice id="audio.mod.desktop-au" title="AU plugin" description="Install AU plugin" selected="true" visible="true">
<pkg-ref id="audio.mod.desktop-components" version="0">mod-desktop-components.pkg</pkg-ref>
</choice>
<choice id="audio.mod.desktop-clap" title="CLAP plugin" description="Install CLAP plugin" selected="true" visible="true">
<pkg-ref id="audio.mod.desktop-clapbundles" version="0">mod-desktop-clapbundles.pkg</pkg-ref>
</choice>
<choice id="audio.mod.desktop-lv2" title="LV2 plugin" description="Install LV2 plugin" selected="true" visible="true">
<pkg-ref id="audio.mod.desktop-lv2bundles" version="0">mod-desktop-lv2bundles.pkg</pkg-ref>
</choice>
<choice id="audio.mod.desktop-vst2" title="VST2 plugin" description="Install VST2 plugin" selected="true" visible="true">
<pkg-ref id="audio.mod.desktop-vst2bundles" version="0">mod-desktop-vst2bundles.pkg</pkg-ref>
</choice>
<choice id="audio.mod.desktop-vst3" title="VST3 plugin" description="Install VST3 plugin" selected="true" visible="true">
<pkg-ref id="audio.mod.desktop-vst3bundles" version="0">mod-desktop-vst3bundles.pkg</pkg-ref>
</choice>
<choices-outline>
<line choice="audio.mod.desktop-pkg"/>
<line choice="audio.mod.desktop-au"/>
<line choice="audio.mod.desktop-clap"/>
<line choice="audio.mod.desktop-lv2"/>
<line choice="audio.mod.desktop-vst2"/>
<line choice="audio.mod.desktop-vst3"/>
</choices-outline>
</installer-gui-script>

0 comments on commit d3f6250

Please sign in to comment.