Compare commits
1 Commits
2026.1-dev
...
93912b1e2a
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
93912b1e2a |
8
.gitmodules
vendored
8
.gitmodules
vendored
@@ -1,8 +0,0 @@
|
|||||||
[submodule "mullvad-vpn-daemon/mullvadvpn-app"]
|
|
||||||
path = mullvad-vpn-daemon/mullvadvpn-app
|
|
||||||
url = git@github.com:mullvad/mullvadvpn-app-priv.git
|
|
||||||
branch = poc-slint
|
|
||||||
[submodule "mullvad-vpn-slint/mullvadvpn-app"]
|
|
||||||
path = mullvad-vpn-slint/mullvadvpn-app
|
|
||||||
url = git@github.com:mullvad/mullvadvpn-app-priv.git
|
|
||||||
branch = poc-slint
|
|
||||||
56
Dockerfile
56
Dockerfile
@@ -1,21 +1,57 @@
|
|||||||
FROM alpine:edge
|
FROM alpine:3.21
|
||||||
|
|
||||||
# Install build dependencies
|
# Install build dependencies
|
||||||
# TODO: trim dependencies?
|
# TODO: trim dependencies?
|
||||||
RUN apk update && apk add \
|
RUN apk update && apk add \
|
||||||
|
build-base abuild \
|
||||||
|
rustup \
|
||||||
build-base \
|
build-base \
|
||||||
abuild \
|
musl-dev \
|
||||||
git \
|
gcc \
|
||||||
rust \
|
cmake \
|
||||||
cargo-auditable \
|
make \
|
||||||
pkgconfig \
|
pkgconfig \
|
||||||
|
perl \
|
||||||
|
python3 \
|
||||||
|
curl \
|
||||||
|
git \
|
||||||
|
llvm \
|
||||||
|
clang \
|
||||||
|
clang-libclang \
|
||||||
protobuf-dev \
|
protobuf-dev \
|
||||||
protobuf-dev \
|
libc-dev \
|
||||||
libmnl libmnl-dev \
|
linux-headers \
|
||||||
libnftnl libnftnl-dev \
|
freetype-dev \
|
||||||
dbus dbus-dev \
|
freetype-static \
|
||||||
fontconfig-dev \
|
fontconfig-dev \
|
||||||
wayland-dev
|
fontconfig-static \
|
||||||
|
bzip2-dev \
|
||||||
|
bzip2-static \
|
||||||
|
brotli-dev \
|
||||||
|
brotli-static \
|
||||||
|
expat-dev \
|
||||||
|
expat-static \
|
||||||
|
libx11-dev \
|
||||||
|
libxcursor-dev \
|
||||||
|
libxkbcommon-dev \
|
||||||
|
libxkbcommon-static \
|
||||||
|
wayland-dev \
|
||||||
|
wayland-libs-client \
|
||||||
|
wayland-libs-server \
|
||||||
|
wayland-static \
|
||||||
|
openssl-dev \
|
||||||
|
openssl-libs-static \
|
||||||
|
zlib-dev \
|
||||||
|
zlib-static \
|
||||||
|
libpng-dev \
|
||||||
|
libpng-static \
|
||||||
|
libwebp-dev \
|
||||||
|
libwebp-static \
|
||||||
|
tiff-dev \
|
||||||
|
libjpeg-turbo-dev \
|
||||||
|
libjpeg-turbo-static
|
||||||
|
|
||||||
|
RUN rustup-init -y --default-toolchain stable
|
||||||
|
|
||||||
# Set pkg-config to use static libraries
|
# Set pkg-config to use static libraries
|
||||||
ENV PKG_CONFIG_ALLOW_STATIC=1
|
ENV PKG_CONFIG_ALLOW_STATIC=1
|
||||||
|
|||||||
@@ -4,7 +4,7 @@
|
|||||||
|
|
||||||
1. Install `abuild`
|
1. Install `abuild`
|
||||||
2. Create keys: `abuild-keygen`
|
2. Create keys: `abuild-keygen`
|
||||||
The keys will end up in ~/.abuild/, and will be mounted into the build container.
|
The keys will end up in ~/.abuild/, and will be mounted into the build container by podma, and will be mounted into the build container.
|
||||||
3. Remember to keep keys around.
|
3. Remember to keep keys around.
|
||||||
|
|
||||||
## Building
|
## Building
|
||||||
|
|||||||
@@ -1,26 +0,0 @@
|
|||||||
#!/bin/sh
|
|
||||||
|
|
||||||
set -ex
|
|
||||||
cd "$(dirname "$0")"
|
|
||||||
|
|
||||||
package="$1"
|
|
||||||
builder_image="mullvad-slint-musl-builder"
|
|
||||||
cargo_home="${CARGO_HOME:-$HOME/.cargo}"
|
|
||||||
. "$HOME/.abuild/abuild.conf"
|
|
||||||
|
|
||||||
docker build . -f Dockerfile -t "$builder_image"
|
|
||||||
docker run --rm \
|
|
||||||
-v "./$package":/build \
|
|
||||||
-v ./abuild.conf:/root/.abuild/abuild.conf:ro \
|
|
||||||
-v "$PACKAGER_PRIVKEY":/key.rsa:ro \
|
|
||||||
-v "$PACKAGER_PRIVKEY.pub":/key.rsa.pub:ro \
|
|
||||||
-v "$PACKAGER_PRIVKEY.pub":/etc/apk/keys/key.rsa.pub:ro \
|
|
||||||
-v ./packages:/root/packages \
|
|
||||||
-v "$cargo_home":/cargo-home \
|
|
||||||
-e "CARGO_HOME=/cargo-home" \
|
|
||||||
-v ./target:/cargo-target \
|
|
||||||
-e "CARGO_TARGET_DIR=/cargo-target" \
|
|
||||||
-it \
|
|
||||||
"$builder_image" \
|
|
||||||
abuild -F
|
|
||||||
|
|
||||||
@@ -1,85 +0,0 @@
|
|||||||
# Contributor:
|
|
||||||
# Maintainer: Joakim Hulthe <joakim@hulthe.net>
|
|
||||||
pkgname=mullvad-vpn-daemon
|
|
||||||
pkgver=2026.1_git
|
|
||||||
pkgrel=4
|
|
||||||
pkgdesc="Mullvad VPN system service"
|
|
||||||
url="https://mullvad.net/"
|
|
||||||
arch="all"
|
|
||||||
license="GPL-3-or-later"
|
|
||||||
depends="
|
|
||||||
dbus
|
|
||||||
libmnl
|
|
||||||
libnftnl
|
|
||||||
"
|
|
||||||
makedepends="
|
|
||||||
build-base
|
|
||||||
cargo-auditable
|
|
||||||
rust
|
|
||||||
pkgconfig
|
|
||||||
git
|
|
||||||
protobuf-dev
|
|
||||||
dbus-dev
|
|
||||||
libmnl-dev
|
|
||||||
libnftnl-dev
|
|
||||||
"
|
|
||||||
checkdepends=""
|
|
||||||
install="$pkgname.post-install $pkgname.pre-upgrade $pkgname.post-upgrade $pkgname.pre-deinstall $pkgname.post-deinstall"
|
|
||||||
subpackages="$pkgname-systemd"
|
|
||||||
source=""
|
|
||||||
builddir="$srcdir/"
|
|
||||||
options="net suid"
|
|
||||||
|
|
||||||
_cargo_target_dir="${CARGO_TARGET_DIR:-$startdir/mullvadvpn-app/target}"
|
|
||||||
|
|
||||||
prepare() {
|
|
||||||
default_prepare
|
|
||||||
|
|
||||||
cd "$startdir/mullvadvpn-app"
|
|
||||||
cargo fetch --target "$CHOST" --locked
|
|
||||||
}
|
|
||||||
|
|
||||||
build() {
|
|
||||||
cd "$startdir/mullvadvpn-app"
|
|
||||||
|
|
||||||
# Specify `--target` so that the build artifacts ends up in target/<target>/release to
|
|
||||||
# avoid clashes with host system when running in a container with a mounted target folder.
|
|
||||||
cargo auditable build --release --locked \
|
|
||||||
--target "$CHOST" \
|
|
||||||
-p mullvad-cli \
|
|
||||||
-p mullvad-daemon \
|
|
||||||
-p mullvad-exclude \
|
|
||||||
-p mullvad-problem-report \
|
|
||||||
-p mullvad-setup
|
|
||||||
}
|
|
||||||
|
|
||||||
check() {
|
|
||||||
cd "$startdir/mullvadvpn-app"
|
|
||||||
cargo test --target "$CHOST" --frozen
|
|
||||||
}
|
|
||||||
|
|
||||||
package() {
|
|
||||||
install -m755 -D "$_cargo_target_dir/$CHOST/release/mullvad" \
|
|
||||||
"$pkgdir"/usr/bin/mullvad
|
|
||||||
|
|
||||||
install -m755 -D "$_cargo_target_dir/$CHOST/release/mullvad-daemon" \
|
|
||||||
"$pkgdir"/usr/bin/mullvad-daemon
|
|
||||||
|
|
||||||
# mullvad-exclude requires setuid
|
|
||||||
install -m4755 -D "$_cargo_target_dir/$CHOST/release/mullvad-exclude" \
|
|
||||||
"$pkgdir"/usr/bin/mullvad-exclude
|
|
||||||
|
|
||||||
install -m755 -D "$_cargo_target_dir/$CHOST/release/mullvad-problem-report" \
|
|
||||||
"$pkgdir"/usr/bin/mullvad-problem-report
|
|
||||||
|
|
||||||
install -m755 -D "$_cargo_target_dir/$CHOST/release/mullvad-setup" \
|
|
||||||
"$pkgdir"/usr/bin/mullvad-setup
|
|
||||||
}
|
|
||||||
|
|
||||||
systemd() {
|
|
||||||
install -m755 -D "$startdir/mullvadvpn-app/dist-assets/linux/mullvad-daemon.service" \
|
|
||||||
"$subpkgdir"/usr/lib/systemd/system/mullvad-daemon.service
|
|
||||||
|
|
||||||
install -m755 -D "$startdir/mullvadvpn-app/dist-assets/linux/mullvad-early-boot-blocking.service" \
|
|
||||||
"$subpkgdir"/usr/lib/systemd/system/mullvad-early-boot-blocking.service
|
|
||||||
}
|
|
||||||
@@ -1,9 +0,0 @@
|
|||||||
#!/usr/bin/env bash
|
|
||||||
set -eu
|
|
||||||
|
|
||||||
rm -r --interactive=never /var/log/mullvad-vpn/ || \
|
|
||||||
echo "Failed to remove mullvad-vpn logs"
|
|
||||||
rm -r --interactive=never /var/cache/mullvad-vpn/ || \
|
|
||||||
echo "Failed to remove mullvad-vpn cache"
|
|
||||||
rm -r --interactive=never /etc/mullvad-vpn || \
|
|
||||||
echo "Failed to remove mullvad-vpn config"
|
|
||||||
@@ -1,10 +0,0 @@
|
|||||||
#!/usr/bin/env bash
|
|
||||||
set -eu
|
|
||||||
|
|
||||||
if which systemctl &> /dev/null && systemctl is-system-running | grep -vq offline &> /dev/null; then
|
|
||||||
if systemctl status mullvad-daemon &> /dev/null; then
|
|
||||||
systemctl enable "/usr/lib/systemd/system/mullvad-daemon.service"
|
|
||||||
systemctl start mullvad-daemon.service || echo "Failed to start mullvad-daemon.service"
|
|
||||||
systemctl enable "/usr/lib/systemd/system/mullvad-early-boot-blocking.service"
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
@@ -1,10 +0,0 @@
|
|||||||
#!/usr/bin/env bash
|
|
||||||
set -eu
|
|
||||||
|
|
||||||
if which systemctl &> /dev/null && systemctl is-system-running | grep -vq offline &> /dev/null; then
|
|
||||||
if systemctl status mullvad-daemon &> /dev/null; then
|
|
||||||
systemctl enable "/usr/lib/systemd/system/mullvad-daemon.service"
|
|
||||||
systemctl start mullvad-daemon.service || echo "Failed to start mullvad-daemon.service"
|
|
||||||
systemctl enable "/usr/lib/systemd/system/mullvad-early-boot-blocking.service"
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
@@ -1,23 +0,0 @@
|
|||||||
#!/usr/bin/env bash
|
|
||||||
set -eu
|
|
||||||
|
|
||||||
echo "Running prerm."
|
|
||||||
is_number_re='^[0-9]+$'
|
|
||||||
# Check if we're running during an upgrade step on Fedora
|
|
||||||
# https://fedoraproject.org/wiki/Packaging:Scriptlets#Syntax
|
|
||||||
if [[ "$1" =~ $is_number_re ]] && [ "$1" -gt 0 ]; then
|
|
||||||
exit 0;
|
|
||||||
fi
|
|
||||||
|
|
||||||
if [[ "$1" == "upgrade" ]]; then
|
|
||||||
exit 0;
|
|
||||||
fi
|
|
||||||
|
|
||||||
# the user might've disabled or stopped the service themselves already
|
|
||||||
systemctl stop mullvad-daemon.service || true
|
|
||||||
systemctl disable mullvad-daemon.service || true
|
|
||||||
systemctl stop mullvad-early-boot-blocking.service || true
|
|
||||||
systemctl disable mullvad-early-boot-blocking.service || true
|
|
||||||
|
|
||||||
mullvad-setup reset-firewall || echo "Failed to reset firewall"
|
|
||||||
mullvad-setup remove-device || echo "Failed to remove device from account"
|
|
||||||
@@ -1,16 +0,0 @@
|
|||||||
#!/usr/bin/env bash
|
|
||||||
set -eu
|
|
||||||
|
|
||||||
if which systemctl &> /dev/null && systemctl is-system-running | grep -vq offline &> /dev/null; then
|
|
||||||
if systemctl status mullvad-daemon &> /dev/null; then
|
|
||||||
mullvad-setup prepare-restart || true
|
|
||||||
systemctl stop mullvad-daemon.service
|
|
||||||
systemctl disable mullvad-daemon.service
|
|
||||||
systemctl disable mullvad-early-boot-blocking.service || true
|
|
||||||
cp /var/log/mullvad-vpn/daemon.log /var/log/mullvad-vpn/old-install-daemon.log \
|
|
||||||
|| echo "Failed to copy old daemon log"
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
|
|
||||||
rm -f /var/cache/mullvad-vpn/relays.json
|
|
||||||
rm -f /var/cache/mullvad-vpn/api-ip-address.txt
|
|
||||||
Submodule mullvad-vpn-daemon/mullvadvpn-app deleted from 236bbc4c0e
@@ -1,85 +0,0 @@
|
|||||||
# Contributor:
|
|
||||||
# Maintainer: Joakim Hulthe <joakim@hulthe.net>
|
|
||||||
pkgname=mullvad-vpn-slint
|
|
||||||
pkgver=2026.1_git
|
|
||||||
pkgrel=4
|
|
||||||
pkgdesc="Mullvad VPN GUI"
|
|
||||||
url="https://mullvad.net/"
|
|
||||||
arch="all"
|
|
||||||
license="GPL-3-or-later"
|
|
||||||
# TODO: maybe depend on mullvad-vpn-daemon?
|
|
||||||
depends="
|
|
||||||
"
|
|
||||||
makedepends="
|
|
||||||
build-base
|
|
||||||
cargo-auditable
|
|
||||||
rust
|
|
||||||
pkgconfig
|
|
||||||
protobuf-dev
|
|
||||||
fontconfig-dev
|
|
||||||
dbus-dev
|
|
||||||
wayland-dev
|
|
||||||
"
|
|
||||||
checkdepends=""
|
|
||||||
install=""
|
|
||||||
subpackages=""
|
|
||||||
source=""
|
|
||||||
builddir="$srcdir/"
|
|
||||||
options="net !check"
|
|
||||||
|
|
||||||
_cargo_target_dir="${CARGO_TARGET_DIR:-$startdir/mullvadvpn-app/target}"
|
|
||||||
|
|
||||||
prepare() {
|
|
||||||
default_prepare
|
|
||||||
|
|
||||||
cd "$startdir/mullvadvpn-app"
|
|
||||||
cargo fetch --target "$CHOST" --locked
|
|
||||||
}
|
|
||||||
|
|
||||||
build() {
|
|
||||||
cd "$startdir/mullvadvpn-app"
|
|
||||||
|
|
||||||
# Specify `--target` so that the final binary ends up in target/<target>/release.
|
|
||||||
cargo build --release --locked \
|
|
||||||
--target "$CHOST" \
|
|
||||||
-p mullvad-slint
|
|
||||||
}
|
|
||||||
|
|
||||||
package() {
|
|
||||||
# Executable
|
|
||||||
install -m755 -D "$_cargo_target_dir/$CHOST/release/mullvad-slint" \
|
|
||||||
"$pkgdir"/usr/bin/mullvad-slint
|
|
||||||
|
|
||||||
# .desktop file
|
|
||||||
install -m644 -D "$startdir/mullvadvpn-app/dist-assets/linux/slint/mullvad-vpn-slint.desktop" \
|
|
||||||
"$pkgdir"/usr/share/applications/mullvad-vpn-slint.desktop
|
|
||||||
|
|
||||||
# Icons
|
|
||||||
install -m644 -D "$startdir/mullvadvpn-app/dist-assets/linux/slint/16x16/apps/mullvad.png" \
|
|
||||||
"$pkgdir"/usr/share/icons/hicolor/16x16/apps/mullvad.png
|
|
||||||
install -m644 -D "$startdir/mullvadvpn-app/dist-assets/linux/slint/20x20/apps/mullvad.png" \
|
|
||||||
"$pkgdir"/usr/share/icons/hicolor/20x20/apps/mullvad.png
|
|
||||||
install -m644 -D "$startdir/mullvadvpn-app/dist-assets/linux/slint/24x24/apps/mullvad.png" \
|
|
||||||
"$pkgdir"/usr/share/icons/hicolor/24x24/apps/mullvad.png
|
|
||||||
install -m644 -D "$startdir/mullvadvpn-app/dist-assets/linux/slint/30x30/apps/mullvad.png" \
|
|
||||||
"$pkgdir"/usr/share/icons/hicolor/30x30/apps/mullvad.png
|
|
||||||
install -m644 -D "$startdir/mullvadvpn-app/dist-assets/linux/slint/32x32/apps/mullvad.png" \
|
|
||||||
"$pkgdir"/usr/share/icons/hicolor/32x32/apps/mullvad.png
|
|
||||||
install -m644 -D "$startdir/mullvadvpn-app/dist-assets/linux/slint/36x36/apps/mullvad.png" \
|
|
||||||
"$pkgdir"/usr/share/icons/hicolor/36x36/apps/mullvad.png
|
|
||||||
install -m644 -D "$startdir/mullvadvpn-app/dist-assets/linux/slint/40x40/apps/mullvad.png" \
|
|
||||||
"$pkgdir"/usr/share/icons/hicolor/40x40/apps/mullvad.png
|
|
||||||
install -m644 -D "$startdir/mullvadvpn-app/dist-assets/linux/slint/48x48/apps/mullvad.png" \
|
|
||||||
"$pkgdir"/usr/share/icons/hicolor/48x48/apps/mullvad.png
|
|
||||||
install -m644 -D "$startdir/mullvadvpn-app/dist-assets/linux/slint/64x64/apps/mullvad.png" \
|
|
||||||
"$pkgdir"/usr/share/icons/hicolor/64x64/apps/mullvad.png
|
|
||||||
install -m644 -D "$startdir/mullvadvpn-app/dist-assets/linux/slint/72x72/apps/mullvad.png" \
|
|
||||||
"$pkgdir"/usr/share/icons/hicolor/72x72/apps/mullvad.png
|
|
||||||
install -m644 -D "$startdir/mullvadvpn-app/dist-assets/linux/slint/96x96/apps/mullvad.png" \
|
|
||||||
"$pkgdir"/usr/share/icons/hicolor/96x96/apps/mullvad.png
|
|
||||||
install -m644 -D "$startdir/mullvadvpn-app/dist-assets/linux/slint/256x256/apps/mullvad.png" \
|
|
||||||
"$pkgdir"/usr/share/icons/hicolor/256x256/apps/mullvad.png
|
|
||||||
install -m644 -D "$startdir/mullvadvpn-app/dist-assets/linux/slint/512x512/apps/mullvad.png" \
|
|
||||||
"$pkgdir"/usr/share/icons/hicolor/512x512/apps/mullvad.png
|
|
||||||
}
|
|
||||||
|
|
||||||
Submodule mullvad-vpn-slint/mullvadvpn-app deleted from 236bbc4c0e
5
podman-build.sh
Executable file → Normal file
5
podman-build.sh
Executable file → Normal file
@@ -5,7 +5,6 @@ cd "$(dirname "$0")"
|
|||||||
|
|
||||||
package="$1"
|
package="$1"
|
||||||
builder_image="mullvad-slint-musl-builder"
|
builder_image="mullvad-slint-musl-builder"
|
||||||
cargo_home="${CARGO_HOME:-$HOME/.cargo}"
|
|
||||||
. "$HOME/.abuild/abuild.conf"
|
. "$HOME/.abuild/abuild.conf"
|
||||||
|
|
||||||
podman build . -f Dockerfile -t "$builder_image"
|
podman build . -f Dockerfile -t "$builder_image"
|
||||||
@@ -15,10 +14,8 @@ podman run --rm \
|
|||||||
-v "$PACKAGER_PRIVKEY":/key.rsa:ro \
|
-v "$PACKAGER_PRIVKEY":/key.rsa:ro \
|
||||||
-v "$PACKAGER_PRIVKEY.pub":/key.rsa.pub:ro \
|
-v "$PACKAGER_PRIVKEY.pub":/key.rsa.pub:ro \
|
||||||
-v "$PACKAGER_PRIVKEY.pub":/etc/apk/keys/key.rsa.pub:ro \
|
-v "$PACKAGER_PRIVKEY.pub":/etc/apk/keys/key.rsa.pub:ro \
|
||||||
-v ./packages:/root/packages \
|
|
||||||
-v "$cargo_home":/cargo-home \
|
|
||||||
-e "CARGO_HOME=/cargo-home" \
|
|
||||||
-v ./target:/cargo-target \
|
-v ./target:/cargo-target \
|
||||||
|
-v ./packages:/root/packages \
|
||||||
-e "CARGO_TARGET_DIR=/cargo-target" \
|
-e "CARGO_TARGET_DIR=/cargo-target" \
|
||||||
-it \
|
-it \
|
||||||
"$builder_image" \
|
"$builder_image" \
|
||||||
|
|||||||
Reference in New Issue
Block a user