diff options
author | Mark Wagie | 2020-02-24 15:22:38 -0700 |
---|---|---|
committer | Mark Wagie | 2020-02-24 15:22:38 -0700 |
commit | cb998189893edcddf7c30db14d47ee296b02c868 (patch) | |
tree | 03d29ebd097c1d0d4d72840f8db073476e5da94f | |
parent | 1eea24c3d75c1e24212344ec44fd40b28b3fde8b (diff) | |
download | aur-cb998189893edcddf7c30db14d47ee296b02c868.tar.gz |
various improvements
-rw-r--r-- | .SRCINFO | 6 | ||||
-rw-r--r-- | .gitignore | 2 | ||||
-rw-r--r-- | PKGBUILD | 36 | ||||
-rw-r--r-- | mullvad-vpn.desktop | 9 | ||||
-rw-r--r-- | mullvad-vpn.sh | 2 |
5 files changed, 25 insertions, 30 deletions
@@ -1,7 +1,7 @@ pkgbase = mullvad-vpn pkgdesc = The Mullvad VPN client app for desktop pkgver = 2020.3 - pkgrel = 1 + pkgrel = 2 url = https://www.mullvad.net install = mullvad-vpn.install arch = x86_64 @@ -16,13 +16,13 @@ pkgbase = mullvad-vpn depends = nss source = git+https://github.com/mullvad/mullvadvpn-app.git#tag=2020.3?signed source = git+https://github.com/mullvad/mullvadvpn-app-binaries.git#commit=90b0c06b59a0b9d6cda69924377335f39854b216?signed - source = mullvad-vpn.desktop + source = mullvad-vpn.sh source = update-relays.sh validpgpkeys = EA0A77BF9E115615FC3BD8BC7653B940E494FE87 validpgpkeys = 8339C7D2942EB854E3F27CE5AEE9DECFD582E984 sha256sums = SKIP sha256sums = SKIP - sha256sums = 121d90e6683e64d9c0d2dbb7b346fa918bdb37cf21fdaf9f66232304ed23abc2 + sha256sums = a59c29f07b4eab9af56f0e8be42bae0d83726f5185e88de0c5a48f4098c3c0a4 sha256sums = 89267795175c5be95d13e8f700b69654faf2f38f35be5033eb8e94da404d2353 pkgname = mullvad-vpn diff --git a/.gitignore b/.gitignore index 3102c7b66867..a754c58f5754 100644 --- a/.gitignore +++ b/.gitignore @@ -5,6 +5,6 @@ !.gitignore !PKGBUILD !.SRCINFO -!mullvad-vpn.desktop !mullvad-vpn.install +!mullvad-vpn.sh !update-relays.sh @@ -8,7 +8,7 @@ # Contributor: Andrej Mihajlov <and at mullvad dot net> pkgname=mullvad-vpn pkgver=2020.3 -pkgrel=1 +pkgrel=2 pkgdesc="The Mullvad VPN client app for desktop" url="https://www.mullvad.net" arch=('x86_64') @@ -19,11 +19,11 @@ install="$pkgname.install" _commit='90b0c06b59a0b9d6cda69924377335f39854b216' source=("git+https://github.com/mullvad/mullvadvpn-app.git#tag=$pkgver?signed" "git+https://github.com/mullvad/mullvadvpn-app-binaries.git#commit=$_commit?signed" - "$pkgname.desktop" + "$pkgname.sh" 'update-relays.sh') sha256sums=('SKIP' 'SKIP' - '121d90e6683e64d9c0d2dbb7b346fa918bdb37cf21fdaf9f66232304ed23abc2' + 'a59c29f07b4eab9af56f0e8be42bae0d83726f5185e88de0c5a48f4098c3c0a4' '89267795175c5be95d13e8f700b69654faf2f38f35be5033eb8e94da404d2353') validpgpkeys=('EA0A77BF9E115615FC3BD8BC7653B940E494FE87' # Linus Färnstrand (code signing key) <linus at mullvad dot net> @@ -42,6 +42,8 @@ prepare() { } build() { + echo "Building Mullvad VPN $pkgver..." + # Build wireguard-go cd "$srcdir/mullvadvpn-app/wireguard/wireguard-go" mkdir -p "../../build/lib/$arch-unknown-linux-gnu" @@ -54,12 +56,15 @@ build() { cd "$srcdir/mullvadvpn-app" # Remove old Rust build artifacts + echo "Removing old Rust build artifacts" cargo clean --release --locked # Build binaries + echo "Building Rust code..." cargo build --release --locked --all-features # Copy binaries for packaging + echo "Copying binaries" binaries=( mullvad-daemon mullvad @@ -75,7 +80,9 @@ build() { # Build Electron GUI app cd gui + echo "Installing JavaScript dependencies..." npm install --cache "$srcdir/npm-cache" + echo "Packing final release artifact..." npm run pack:linux } @@ -106,24 +113,19 @@ package() { "$pkgdir/usr/bin/mullvad-problem-report" # Link to the GUI binary - ln -s "/opt/Mullvad VPN/mullvad-gui" "$pkgdir/usr/bin/$pkgname" + install -m755 "$srcdir/$pkgname.sh" "$pkgdir/usr/bin/$pkgname" - # Install desktop file from .deb - install -Dm644 "$srcdir/$pkgname.desktop" -t \ - "$pkgdir/usr/share/applications" + cd dist - # Install icons - for icon_size in 16 48; do - icons_dir=/usr/share/icons/hicolor/${icon_size}x${icon_size}/apps - install -d $pkgdir/$icons_dir - install -m644 dist/.icon-set/icon_${icon_size}x${icon_size}.png \ - $pkgdir$icons_dir/$pkgname.png - done + # Install desktop file & icons from .deb + ar x "MullvadVPN-${pkgver}.0_amd64.deb" + tar -xf data.tar.xz + install -Dm644 "usr/share/applications/$pkgname.desktop" -t \ + "$pkgdir/usr/share/applications" - for icon_size in 32 64 128 256 512 1024; do + for icon_size in 16 32 48 64 128 256 512 1024; do icons_dir=/usr/share/icons/hicolor/${icon_size}x${icon_size}/apps install -d $pkgdir/$icons_dir - install -m644 dist/.icon-set/icon_${icon_size}.png \ - $pkgdir$icons_dir/$pkgname.png + install -m644 $icons_dir/$pkgname.png -t $pkgdir$icons_dir done } diff --git a/mullvad-vpn.desktop b/mullvad-vpn.desktop deleted file mode 100644 index 0a407c85db4c..000000000000 --- a/mullvad-vpn.desktop +++ /dev/null @@ -1,9 +0,0 @@ -[Desktop Entry] -Name=Mullvad VPN -Exec="/opt/Mullvad VPN/mullvad-vpn" %U -Terminal=false -Type=Application -Icon=mullvad-vpn -StartupWMClass=Mullvad VPN -Comment=Mullvad VPN client -Categories=Network; diff --git a/mullvad-vpn.sh b/mullvad-vpn.sh new file mode 100644 index 000000000000..387d9923a01f --- /dev/null +++ b/mullvad-vpn.sh @@ -0,0 +1,2 @@ +#!/bin/bash +"/opt/Mullvad VPN/mullvad-vpn" %U |