summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorMark Wagie2020-05-12 14:17:38 -0600
committerMark Wagie2020-05-12 14:17:38 -0600
commite6c2b711ac015350976dc5fdb0f24d1b2c81fee4 (patch)
tree792e0809488f7f4fa1655eadf568500799483dcc
parent8fbf90be798df58e3b9d15745a6dd8f2028fd0b3 (diff)
downloadaur-e6c2b711ac015350976dc5fdb0f24d1b2c81fee4.tar.gz
updated to 2020.4
-rw-r--r--.SRCINFO12
-rw-r--r--.gitignore1
-rw-r--r--PKGBUILD57
-rwxr-xr-xupdate-relays.sh22
4 files changed, 41 insertions, 51 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 4dfa3cbca42e..61c3cf0690ae 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,7 +1,7 @@
pkgbase = mullvad-vpn
pkgdesc = The Mullvad VPN client app for desktop
- pkgver = 2020.3
- pkgrel = 3
+ pkgver = 2020.4
+ pkgrel = 1
url = https://www.mullvad.net
install = mullvad-vpn.install
arch = x86_64
@@ -14,16 +14,14 @@ pkgbase = mullvad-vpn
depends = libappindicator-gtk3
depends = libxss
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
+ optdepends = bash-completion
+ source = git+https://github.com/mullvad/mullvadvpn-app.git#tag=2020.4?signed
+ source = git+https://github.com/mullvad/mullvadvpn-app-binaries.git#commit=ca17805ec31da8201982ef3e9082ca3376395b52?signed
source = mullvad-vpn.sh
- source = update-relays.sh
validpgpkeys = EA0A77BF9E115615FC3BD8BC7653B940E494FE87
- validpgpkeys = 8339C7D2942EB854E3F27CE5AEE9DECFD582E984
sha256sums = SKIP
sha256sums = SKIP
sha256sums = a59c29f07b4eab9af56f0e8be42bae0d83726f5185e88de0c5a48f4098c3c0a4
- sha256sums = 89267795175c5be95d13e8f700b69654faf2f38f35be5033eb8e94da404d2353
pkgname = mullvad-vpn
diff --git a/.gitignore b/.gitignore
index a754c58f5754..951b4436e9df 100644
--- a/.gitignore
+++ b/.gitignore
@@ -7,4 +7,3 @@
!.SRCINFO
!mullvad-vpn.install
!mullvad-vpn.sh
-!update-relays.sh
diff --git a/PKGBUILD b/PKGBUILD
index 5bd7ddd00a08..032f8c2f333f 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -7,28 +7,28 @@
# Contributor: Emīls Piņķis <emil at mullvad dot net>
# Contributor: Andrej Mihajlov <and at mullvad dot net>
pkgname=mullvad-vpn
-pkgver=2020.3
-pkgrel=3
+pkgver=2020.4
+pkgrel=1
pkgdesc="The Mullvad VPN client app for desktop"
url="https://www.mullvad.net"
arch=('x86_64')
license=('GPL3')
depends=('libnotify' 'libappindicator-gtk3' 'libxss' 'nss')
makedepends=('git' 'go-pie' 'rust' 'npm')
+optdepends=('bash-completion')
install="$pkgname.install"
-_commit='90b0c06b59a0b9d6cda69924377335f39854b216'
+_commit='ca17805ec31da8201982ef3e9082ca3376395b52'
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.sh"
- 'update-relays.sh')
+ "$pkgname.sh")
sha256sums=('SKIP'
'SKIP'
- 'a59c29f07b4eab9af56f0e8be42bae0d83726f5185e88de0c5a48f4098c3c0a4'
- '89267795175c5be95d13e8f700b69654faf2f38f35be5033eb8e94da404d2353')
+ 'a59c29f07b4eab9af56f0e8be42bae0d83726f5185e88de0c5a48f4098c3c0a4')
validpgpkeys=('EA0A77BF9E115615FC3BD8BC7653B940E494FE87'
# Linus Färnstrand (code signing key) <linus at mullvad dot net>
- '8339C7D2942EB854E3F27CE5AEE9DECFD582E984')
+ #'8339C7D2942EB854E3F27CE5AEE9DECFD582E984'
# David Lönnhager (code signing) <david dot l at mullvad dot net>
+ )
prepare() {
# Point the submodule to our local copy
@@ -39,13 +39,20 @@ prepare() {
# Disable building of rpm
sed -i "s/'deb', 'rpm'/'deb'/g" gui/tasks/distribution.js
+
+ mkdir -p dist-assets/shell-completions
}
build() {
- echo "Building Mullvad VPN $pkgver..."
+ cd "$srcdir/mullvadvpn-app"
+ local RUSTC_VERSION=$(rustc --version)
+ local PRODUCT_VERSION=$(node -p "require('./gui/package.json').version" | \
+ sed -Ee 's/\.0//g')
+
+ echo "Building Mullvad VPN $PRODUCT_VERSION..."
- # Build wireguard-go
- cd "$srcdir/mullvadvpn-app/wireguard/wireguard-go"
+ # Compile wireguard-go
+ cd "$srcdir/mullvadvpn-app/wireguard/libwg"
mkdir -p "../../build/lib/$arch-unknown-linux-gnu"
go build \
-trimpath \
@@ -54,34 +61,43 @@ build() {
-buildmode c-archive
cd "$srcdir/mullvadvpn-app"
+ echo "Updating version in metadata files..."
+ ./version-metadata.sh inject $PRODUCT_VERSION
- # Remove old Rust build artifacts
echo "Removing old Rust build artifacts"
- cargo clean --release --locked
+ cargo clean --locked
+
+ echo "Building Rust code in release mode using $RUSTC_VERSION..."
+
+ cd mullvad-cli
+ for sh in bash zsh; do
+ echo "Generating shell completion script for $sh..."
+ cargo run --release --locked --features shell-completions -- \
+ shell-completions "$sh" ../dist-assets/shell-completions/
+ done
- # Build binaries
- echo "Building Rust code..."
- cargo build --release --locked --all-features
+ cd "$srcdir/mullvadvpn-app"
+ MULLVAD_ADD_MANIFEST="1" cargo build --release --locked --all-features
- # Copy binaries for packaging
echo "Copying binaries"
binaries=(
mullvad-daemon
mullvad
mullvad-problem-report
libtalpid_openvpn_plugin.so
+ mullvad-setup
)
for binary in ${binaries[*]}; do
cp "target/release/$binary" "dist-assets/$binary"
done
# Update relay list & generate relays.json
- ../update-relays.sh
+ ./update-relays.sh
# Build Electron GUI app
cd gui
echo "Installing JavaScript dependencies..."
- npm install --cache "$srcdir/npm-cache"
+ npm ci --no-optional --cache "$srcdir/npm-cache"
echo "Packing final release artifact..."
npm run pack:linux
}
@@ -115,9 +131,8 @@ package() {
# Link to the GUI binary
install -m755 "$srcdir/$pkgname.sh" "$pkgdir/usr/bin/$pkgname"
- cd dist
-
# Install desktop file & icons from .deb
+ cd dist
ar x "MullvadVPN-${pkgver}.0_amd64.deb"
tar -xf data.tar.xz
install -Dm644 "usr/share/applications/$pkgname.desktop" -t \
diff --git a/update-relays.sh b/update-relays.sh
deleted file mode 100755
index 88f43c3ca60b..000000000000
--- a/update-relays.sh
+++ /dev/null
@@ -1,22 +0,0 @@
-#!/bin/bash
-echo "Updating relay list..."
-set +e
-read -d '' JSONRPC_CODE <<-JSONRPC_CODE
-var buff = "";
-process.stdin.on('data', function (chunk) {
- buff += chunk;
-})
-process.stdin.on('end', function () {
- var obj = JSON.parse(buff);
- var output = JSON.stringify(obj.result, null, ' ');
- process.stdout.write(output);
-})
-JSONRPC_CODE
-set -e
-
-JSONRPC_RESPONSE="$(curl -X POST \
- --fail \
- -H "Content-Type: application/json" \
- -d '{"jsonrpc": "2.0", "id": "0", "method": "relay_list_v3"}' \
- https://api.mullvad.net/rpc/)"
-echo $JSONRPC_RESPONSE | node -e "$JSONRPC_CODE" > dist-assets/relays.json