From 3dbd1bef7e64f7dbbdf3ac069afe2913a14653ac Mon Sep 17 00:00:00 2001 From: Paul Date: Wed, 15 Apr 2020 11:01:57 -0400 Subject: [PATCH] A Few build-linux tweaks (#1726) The re-package for VST2 isn't how VST2 quite works; and broke the build-linux install scripts. Also the make_deb was wrong since cmake. Closes #1724 Addresses #1206 --- CMakeLists.txt | 5 ++--- build-linux.sh | 2 +- installer_linux/make_deb.sh | 4 ++-- scripts/linux/package-vst2.sh | 18 ------------------ 4 files changed, 5 insertions(+), 24 deletions(-) delete mode 100644 scripts/linux/package-vst2.sh diff --git a/CMakeLists.txt b/CMakeLists.txt index f5c4ab1a040..aa7587a18aa 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -624,9 +624,8 @@ if( BUILD_VST2 ) TARGET Surge.vst2 POST_BUILD WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR} - COMMAND echo "Packaging up VST2 component" - COMMAND pwd - COMMAND ./scripts/linux/package-vst2.sh + COMMAND ${CMAKE_COMMAND} -E make_directory ${CMAKE_CURRENT_SOURCE_DIR}/products + COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_BINARY_DIR}/libsurge-vst2.so ${CMAKE_CURRENT_SOURCE_DIR}/products/Surge.so ) endif() if( WIN32 ) diff --git a/build-linux.sh b/build-linux.sh index 8c759915c95..ee38759a473 100755 --- a/build-linux.sh +++ b/build-linux.sh @@ -231,7 +231,7 @@ fi if [ -z "$option_debug" ]; then config="config=release_x64" - vst2_src_path="products/Surge.vst2" + vst2_src_path="products/Surge.so" vst3_src_path="products/Surge.vst3" lv2_bundle_name="Surge.lv2" lv2_src_path="products/$lv2_bundle_name" diff --git a/installer_linux/make_deb.sh b/installer_linux/make_deb.sh index 099ec29d5ef..b8321cabce5 100755 --- a/installer_linux/make_deb.sh +++ b/installer_linux/make_deb.sh @@ -83,13 +83,13 @@ gzip -9 -n ${PACKAGE_NAME}/usr/share/${SURGE_NAME}/doc/changelog.Debian cp ../LICENSE ${PACKAGE_NAME}/usr/share/${SURGE_NAME}/doc/copyright cp -r ../resources/data/* ${PACKAGE_NAME}/usr/share/${SURGE_NAME}/ -cp ../target/vst2/Release/Surge.so ${PACKAGE_NAME}/usr/lib/vst/${SURGE_NAME}.so +cp ../products/Surge.so ${PACKAGE_NAME}/usr/lib/vst/${SURGE_NAME}.so # Once VST3 works, this will be ../products/vst3 cp -r ../products/Surge.vst3 ${PACKAGE_NAME}/usr/lib/vst3/ # copy the lv2 bundle -cp -r ../target/lv2/Release/Surge.lv2 ${PACKAGE_NAME}/usr/lib/lv2/ +cp -r ../products/Surge.lv2 ${PACKAGE_NAME}/usr/lib/lv2/ # set permissions on shared libraries chmod -R 0644 ${PACKAGE_NAME}/usr/lib/vst/${SURGE_NAME}.so diff --git a/scripts/linux/package-vst2.sh b/scripts/linux/package-vst2.sh deleted file mode 100644 index bc12951af86..00000000000 --- a/scripts/linux/package-vst2.sh +++ /dev/null @@ -1,18 +0,0 @@ -#!/bin/sh - -OUTPUT_DIR=products - -BUNDLE_NAME="Surge.vst2" -BUNDLE_DIR="$OUTPUT_DIR/$BUNDLE_NAME" - -echo "Creating Linux VST2 Bundle..." - -# create basic bundle structure - -if test -d "$BUNDLE_DIR"; then - rm -rf "$BUNDLE_DIR" -fi - -VST_SO_DIR="$BUNDLE_DIR" -mkdir -p "$VST_SO_DIR" -cp build/libsurge-vst2.so "$VST_SO_DIR"/Surge.so