mirror of
https://codeberg.org/armin/wavetable.git
synced 2026-09-01 05:50:46 +02:00
Create installer
This commit is contained in:
parent
26f572a019
commit
386a89cc9a
11 changed files with 591 additions and 36 deletions
97
Installer/linux/build_deb.sh
Executable file
97
Installer/linux/build_deb.sh
Executable file
|
|
@ -0,0 +1,97 @@
|
|||
#!/bin/bash
|
||||
# Build Linux .deb package for Wavetable
|
||||
|
||||
set -e
|
||||
|
||||
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
|
||||
ROOT_DIR="$(cd "$SCRIPT_DIR/../.." && pwd)"
|
||||
VERSION="${VERSION:-1.0.0}"
|
||||
PLUGIN_NAME="Wavetable"
|
||||
PACKAGE_NAME="wavetable"
|
||||
ARCH="amd64"
|
||||
|
||||
# Paths
|
||||
BIN_DIR="$ROOT_DIR/ci/bin"
|
||||
DEB_ROOT="$SCRIPT_DIR/deb_root"
|
||||
OUTPUT_DIR="$SCRIPT_DIR/output"
|
||||
|
||||
echo "Building Wavetable $VERSION .deb package..."
|
||||
|
||||
# Clean and create directories
|
||||
rm -rf "$DEB_ROOT" "$OUTPUT_DIR"
|
||||
mkdir -p "$DEB_ROOT"
|
||||
mkdir -p "$OUTPUT_DIR"
|
||||
|
||||
# Create package structure
|
||||
mkdir -p "$DEB_ROOT/DEBIAN"
|
||||
mkdir -p "$DEB_ROOT/usr/lib/vst"
|
||||
mkdir -p "$DEB_ROOT/usr/lib/vst3"
|
||||
mkdir -p "$DEB_ROOT/usr/lib/lv2"
|
||||
mkdir -p "$DEB_ROOT/usr/share/SocaLabs/Wavetable/Wavetables"
|
||||
mkdir -p "$DEB_ROOT/usr/share/SocaLabs/Wavetable/Presets"
|
||||
|
||||
# Copy plugins
|
||||
if [ -f "$BIN_DIR/vst/$PLUGIN_NAME.so" ]; then
|
||||
cp "$BIN_DIR/vst/$PLUGIN_NAME.so" "$DEB_ROOT/usr/lib/vst/"
|
||||
fi
|
||||
|
||||
if [ -d "$BIN_DIR/vst3/$PLUGIN_NAME.vst3" ]; then
|
||||
cp -R "$BIN_DIR/vst3/$PLUGIN_NAME.vst3" "$DEB_ROOT/usr/lib/vst3/"
|
||||
fi
|
||||
|
||||
if [ -d "$BIN_DIR/lv2/$PLUGIN_NAME.lv2" ]; then
|
||||
cp -R "$BIN_DIR/lv2/$PLUGIN_NAME.lv2" "$DEB_ROOT/usr/lib/lv2/"
|
||||
fi
|
||||
|
||||
# Copy wavetables and presets
|
||||
cp -R "$ROOT_DIR/plugin/Resources/WavetablesFLAC/"* "$DEB_ROOT/usr/share/SocaLabs/Wavetable/Wavetables/"
|
||||
cp -R "$ROOT_DIR/plugin/Resources/Presets/"* "$DEB_ROOT/usr/share/SocaLabs/Wavetable/Presets/"
|
||||
|
||||
# Calculate installed size (in KB)
|
||||
INSTALLED_SIZE=$(du -sk "$DEB_ROOT" | cut -f1)
|
||||
|
||||
# Create control file
|
||||
cat > "$DEB_ROOT/DEBIAN/control" << EOF
|
||||
Package: $PACKAGE_NAME
|
||||
Version: $VERSION
|
||||
Section: sound
|
||||
Priority: optional
|
||||
Architecture: $ARCH
|
||||
Installed-Size: $INSTALLED_SIZE
|
||||
Maintainer: SocaLabs <support@socalabs.com>
|
||||
Homepage: https://socalabs.com
|
||||
Description: Wavetable Synthesizer Plugin
|
||||
Wavetable is a powerful wavetable synthesizer available as
|
||||
VST2, VST3, and LV2 plugins for Linux.
|
||||
.
|
||||
Features:
|
||||
- Dual wavetable oscillators
|
||||
- Multiple filter types
|
||||
- Extensive modulation matrix
|
||||
- Built-in effects
|
||||
EOF
|
||||
|
||||
# Create postinst script
|
||||
cat > "$DEB_ROOT/DEBIAN/postinst" << 'EOF'
|
||||
#!/bin/bash
|
||||
# Update plugin caches if available
|
||||
if command -v update-mime-database &> /dev/null; then
|
||||
update-mime-database /usr/share/mime || true
|
||||
fi
|
||||
exit 0
|
||||
EOF
|
||||
chmod 755 "$DEB_ROOT/DEBIAN/postinst"
|
||||
|
||||
# Set permissions
|
||||
find "$DEB_ROOT" -type d -exec chmod 755 {} \;
|
||||
find "$DEB_ROOT/usr" -type f -exec chmod 644 {} \;
|
||||
find "$DEB_ROOT/usr/lib" -name "*.so" -exec chmod 755 {} \;
|
||||
|
||||
# Build the package
|
||||
DEB_FILE="$OUTPUT_DIR/${PACKAGE_NAME}_${VERSION}_${ARCH}.deb"
|
||||
dpkg-deb --build "$DEB_ROOT" "$DEB_FILE"
|
||||
|
||||
# Cleanup
|
||||
rm -rf "$DEB_ROOT"
|
||||
|
||||
echo "Done! Package created: $DEB_FILE"
|
||||
124
Installer/macOS/build_pkg.sh
Executable file
124
Installer/macOS/build_pkg.sh
Executable file
|
|
@ -0,0 +1,124 @@
|
|||
#!/bin/bash
|
||||
# Build macOS installer package for Wavetable
|
||||
|
||||
set -e
|
||||
|
||||
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
|
||||
ROOT_DIR="$(cd "$SCRIPT_DIR/../.." && pwd)"
|
||||
VERSION="${VERSION:-1.0.0}"
|
||||
PLUGIN_NAME="Wavetable"
|
||||
|
||||
# Paths
|
||||
BIN_DIR="$ROOT_DIR/ci/bin"
|
||||
PKG_ROOT="$SCRIPT_DIR/pkg_root"
|
||||
OUTPUT_DIR="$SCRIPT_DIR/output"
|
||||
|
||||
# Signing identities (set via environment or leave empty for unsigned)
|
||||
DEV_APP_ID="${DEV_APP_ID:-}"
|
||||
DEV_INST_ID="${DEV_INST_ID:-}"
|
||||
|
||||
echo "Building Wavetable $VERSION installer..."
|
||||
|
||||
# Clean and create directories
|
||||
rm -rf "$PKG_ROOT" "$OUTPUT_DIR"
|
||||
mkdir -p "$PKG_ROOT"
|
||||
mkdir -p "$OUTPUT_DIR"
|
||||
|
||||
# Create package root structure
|
||||
mkdir -p "$PKG_ROOT/Library/Audio/Plug-Ins/VST"
|
||||
mkdir -p "$PKG_ROOT/Library/Audio/Plug-Ins/VST3"
|
||||
mkdir -p "$PKG_ROOT/Library/Audio/Plug-Ins/Components"
|
||||
mkdir -p "$PKG_ROOT/Library/Application Support/SocaLabs/Wavetable/Wavetables"
|
||||
mkdir -p "$PKG_ROOT/Library/Application Support/SocaLabs/Wavetable/Presets"
|
||||
|
||||
# Copy plugins
|
||||
if [ -d "$BIN_DIR/vst/$PLUGIN_NAME.vst" ]; then
|
||||
cp -R "$BIN_DIR/vst/$PLUGIN_NAME.vst" "$PKG_ROOT/Library/Audio/Plug-Ins/VST/"
|
||||
fi
|
||||
|
||||
if [ -d "$BIN_DIR/vst3/$PLUGIN_NAME.vst3" ]; then
|
||||
cp -R "$BIN_DIR/vst3/$PLUGIN_NAME.vst3" "$PKG_ROOT/Library/Audio/Plug-Ins/VST3/"
|
||||
fi
|
||||
|
||||
if [ -d "$BIN_DIR/au/$PLUGIN_NAME.component" ]; then
|
||||
cp -R "$BIN_DIR/au/$PLUGIN_NAME.component" "$PKG_ROOT/Library/Audio/Plug-Ins/Components/"
|
||||
fi
|
||||
|
||||
# Copy wavetables and presets
|
||||
cp -R "$ROOT_DIR/plugin/Resources/WavetablesFLAC/"* "$PKG_ROOT/Library/Application Support/SocaLabs/Wavetable/Wavetables/"
|
||||
cp -R "$ROOT_DIR/plugin/Resources/Presets/"* "$PKG_ROOT/Library/Application Support/SocaLabs/Wavetable/Presets/"
|
||||
|
||||
# Set permissions
|
||||
chmod -R 755 "$PKG_ROOT/Library/Audio"
|
||||
chmod -R 755 "$PKG_ROOT/Library/Application Support"
|
||||
|
||||
# Build component package
|
||||
pkgbuild --root "$PKG_ROOT" \
|
||||
--identifier "com.socalabs.wavetable.pkg" \
|
||||
--version "$VERSION" \
|
||||
--install-location "/" \
|
||||
"$OUTPUT_DIR/Wavetable-component.pkg"
|
||||
|
||||
# Create distribution.xml
|
||||
cat > "$OUTPUT_DIR/distribution.xml" << EOF
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<installer-gui-script minSpecVersion="1">
|
||||
<title>Wavetable $VERSION</title>
|
||||
<organization>com.socalabs</organization>
|
||||
<domains enable_localSystem="true"/>
|
||||
<options customize="never" require-scripts="true" rootVolumeOnly="true" />
|
||||
<welcome file="welcome.txt" mime-type="text/plain" />
|
||||
<choices-outline>
|
||||
<line choice="default">
|
||||
<line choice="com.socalabs.wavetable.pkg"/>
|
||||
</line>
|
||||
</choices-outline>
|
||||
<choice id="default"/>
|
||||
<choice id="com.socalabs.wavetable.pkg" visible="false">
|
||||
<pkg-ref id="com.socalabs.wavetable.pkg"/>
|
||||
</choice>
|
||||
<pkg-ref id="com.socalabs.wavetable.pkg" version="$VERSION" onConclusion="none">Wavetable-component.pkg</pkg-ref>
|
||||
</installer-gui-script>
|
||||
EOF
|
||||
|
||||
# Create welcome text
|
||||
cat > "$OUTPUT_DIR/welcome.txt" << EOF
|
||||
Welcome to the Wavetable $VERSION installer.
|
||||
|
||||
This will install:
|
||||
- Wavetable VST2 plugin
|
||||
- Wavetable VST3 plugin
|
||||
- Wavetable AU plugin
|
||||
- Factory wavetables
|
||||
- Factory presets
|
||||
|
||||
Click Continue to proceed with the installation.
|
||||
EOF
|
||||
|
||||
# Build product archive
|
||||
UNSIGNED_PKG="$OUTPUT_DIR/${PLUGIN_NAME}_${VERSION}_Mac_unsigned.pkg"
|
||||
SIGNED_PKG="$OUTPUT_DIR/${PLUGIN_NAME}_${VERSION}_Mac.pkg"
|
||||
|
||||
productbuild --distribution "$OUTPUT_DIR/distribution.xml" \
|
||||
--package-path "$OUTPUT_DIR" \
|
||||
--resources "$OUTPUT_DIR" \
|
||||
"$UNSIGNED_PKG"
|
||||
|
||||
# Sign if identity is available
|
||||
if [ -n "$DEV_INST_ID" ]; then
|
||||
echo "Signing installer..."
|
||||
productsign --sign "$DEV_INST_ID" "$UNSIGNED_PKG" "$SIGNED_PKG"
|
||||
rm "$UNSIGNED_PKG"
|
||||
echo "Signed installer: $SIGNED_PKG"
|
||||
else
|
||||
mv "$UNSIGNED_PKG" "$SIGNED_PKG"
|
||||
echo "Unsigned installer: $SIGNED_PKG"
|
||||
fi
|
||||
|
||||
# Cleanup
|
||||
rm -rf "$PKG_ROOT"
|
||||
rm -f "$OUTPUT_DIR/Wavetable-component.pkg"
|
||||
rm -f "$OUTPUT_DIR/distribution.xml"
|
||||
rm -f "$OUTPUT_DIR/welcome.txt"
|
||||
|
||||
echo "Done! Installer created: $SIGNED_PKG"
|
||||
74
Installer/win/Wavetable.iss
Normal file
74
Installer/win/Wavetable.iss
Normal file
|
|
@ -0,0 +1,74 @@
|
|||
; Wavetable Installer Script for Inno Setup
|
||||
|
||||
#define MyAppName "Wavetable"
|
||||
#define MyAppCompany "SocaLabs"
|
||||
#define MyAppPublisher "SocaLabs"
|
||||
#define MyAppURL "https://socalabs.com"
|
||||
#define MyAppVersion GetEnv('VERSION')
|
||||
#if MyAppVersion == ""
|
||||
#define MyAppVersion "1.0.0"
|
||||
#endif
|
||||
|
||||
[Setup]
|
||||
AppID={{B8F4E3A2-9C7D-4B5E-8A1F-6D2E3C4B5A6F}
|
||||
AppName={#MyAppCompany} {#MyAppName}
|
||||
AppVerName={#MyAppCompany} {#MyAppName} {#MyAppVersion}
|
||||
AppVersion={#MyAppVersion}
|
||||
AppPublisher={#MyAppPublisher}
|
||||
AppPublisherURL={#MyAppURL}
|
||||
AppSupportURL={#MyAppURL}
|
||||
AppUpdatesURL={#MyAppURL}
|
||||
DefaultDirName={commonpf64}\VstPlugins
|
||||
DisableProgramGroupPage=yes
|
||||
OutputDir=.\output
|
||||
OutputBaseFilename=Wavetable_{#MyAppVersion}_Win
|
||||
Compression=lzma/ultra
|
||||
SolidCompression=true
|
||||
ShowLanguageDialog=auto
|
||||
InternalCompressLevel=ultra
|
||||
MinVersion=6.1.7600
|
||||
FlatComponentsList=false
|
||||
AppendDefaultDirName=false
|
||||
AlwaysShowDirOnReadyPage=yes
|
||||
DirExistsWarning=no
|
||||
DisableDirPage=no
|
||||
DisableWelcomePage=False
|
||||
DisableReadyPage=no
|
||||
ArchitecturesAllowed=x64compatible
|
||||
ArchitecturesInstallIn64BitMode=x64compatible
|
||||
VersionInfoVersion={#MyAppVersion}
|
||||
VersionInfoCompany={#MyAppPublisher}
|
||||
VersionInfoProductName={#MyAppCompany} {#MyAppName}
|
||||
VersionInfoProductVersion={#MyAppVersion}
|
||||
UsePreviousGroup=False
|
||||
Uninstallable=yes
|
||||
UninstallDisplayName={#MyAppCompany} {#MyAppName}
|
||||
|
||||
[Languages]
|
||||
Name: english; MessagesFile: compiler:Default.isl
|
||||
|
||||
[Types]
|
||||
Name: "full"; Description: "Full installation"
|
||||
Name: "custom"; Description: "Custom installation"; Flags: iscustom
|
||||
|
||||
[Components]
|
||||
Name: "vst2"; Description: "VST2 Plugin"; Types: full
|
||||
Name: "vst3"; Description: "VST3 Plugin"; Types: full
|
||||
Name: "data"; Description: "Wavetables and Presets"; Types: full; Flags: fixed
|
||||
|
||||
[Files]
|
||||
; VST2 Plugin
|
||||
Source: "bin\vst\Wavetable.dll"; DestDir: "{app}"; Components: vst2; Flags: ignoreversion
|
||||
|
||||
; VST3 Plugin
|
||||
Source: "bin\vst3\Wavetable.vst3\*"; DestDir: "{commoncf64}\VST3\Wavetable.vst3"; Components: vst3; Flags: ignoreversion recursesubdirs
|
||||
|
||||
; Wavetables
|
||||
Source: "bin\Wavetables\*"; DestDir: "{commonappdata}\SocaLabs\Wavetable\Wavetables"; Components: data; Flags: ignoreversion recursesubdirs
|
||||
|
||||
; Presets
|
||||
Source: "bin\Presets\*"; DestDir: "{commonappdata}\SocaLabs\Wavetable\Presets"; Components: data; Flags: ignoreversion recursesubdirs
|
||||
|
||||
[InstallDelete]
|
||||
; Clean up old VST3 installation
|
||||
Type: filesandordirs; Name: "{commoncf64}\VST3\Wavetable.vst3"
|
||||
Loading…
Add table
Add a link
Reference in a new issue