fix: snap build
This commit is contained in:
@@ -17,7 +17,7 @@ contact: https://reya.su
|
|||||||
parts:
|
parts:
|
||||||
signed:
|
signed:
|
||||||
plugin: dump
|
plugin: dump
|
||||||
source: target/release/signed-linux-$ARCH_SUFFIX.tar.gz
|
source: target/release/signed-linux-$TARBALL_ARCH_SUFFIX.tar.gz
|
||||||
|
|
||||||
organize:
|
organize:
|
||||||
# These renames seem to not be necessary, but it's tidier.
|
# These renames seem to not be necessary, but it's tidier.
|
||||||
|
|||||||
+6
-3
@@ -11,9 +11,12 @@ ARCH=$(uname -m)
|
|||||||
# Snap uses its own architecture names, which must match the file name and
|
# Snap uses its own architecture names, which must match the file name and
|
||||||
# the architecture asserted inside the .snap. `x86_64`/`aarch64` here would
|
# the architecture asserted inside the .snap. `x86_64`/`aarch64` here would
|
||||||
# produce a file like signed_1.0.0_x86_64.snap that snapd cannot match.
|
# produce a file like signed_1.0.0_x86_64.snap that snapd cannot match.
|
||||||
|
#
|
||||||
|
# The source tarball is named by `script/bundle-linux` after `uname -m`, so it
|
||||||
|
# keeps the x86_64/aarch64 spelling rather than the snap-native one.
|
||||||
case "$ARCH" in
|
case "$ARCH" in
|
||||||
x86_64|amd64) ARCH_SUFFIX="amd64" ;;
|
x86_64|amd64) ARCH_SUFFIX="amd64"; TARBALL_ARCH_SUFFIX="x86_64" ;;
|
||||||
aarch64|arm64) ARCH_SUFFIX="arm64" ;;
|
aarch64|arm64) ARCH_SUFFIX="arm64"; TARBALL_ARCH_SUFFIX="aarch64" ;;
|
||||||
*) echo "Unsupported architecture: $ARCH"; exit 1 ;;
|
*) echo "Unsupported architecture: $ARCH"; exit 1 ;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
@@ -27,7 +30,7 @@ envsubst < "desktop/resources/signed.desktop.in" > "snap/gui/signed.desktop"
|
|||||||
cp "desktop/resources/icon.png" "snap/gui/signed.png"
|
cp "desktop/resources/icon.png" "snap/gui/signed.png"
|
||||||
|
|
||||||
# Generate snapcraft.yaml with version and architecture
|
# Generate snapcraft.yaml with version and architecture
|
||||||
RELEASE_VERSION="$1" ARCH_SUFFIX="$ARCH_SUFFIX" envsubst < desktop/resources/snap/snapcraft.yaml.in > snap/snapcraft.yaml
|
RELEASE_VERSION="$1" TARBALL_ARCH_SUFFIX="$TARBALL_ARCH_SUFFIX" envsubst < desktop/resources/snap/snapcraft.yaml.in > snap/snapcraft.yaml
|
||||||
|
|
||||||
# Clean previous builds
|
# Clean previous builds
|
||||||
snapcraft clean
|
snapcraft clean
|
||||||
|
|||||||
Reference in New Issue
Block a user