Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[new package] rosenpass 0.2.1 #20653

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
62 changes: 62 additions & 0 deletions mingw-w64-rosenpass/PKGBUILD
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
# Maintainer: Maksim Bondarenkov <maksapple2306@gmail.com>

_realname=rosenpass
pkgbase=mingw-w64-${_realname}
pkgname="${MINGW_PACKAGE_PREFIX}-${_realname}"
pkgver=0.2.1
pkgrel=1
pkgdesc="Rosenpass is a post-quantum-secure VPN that uses WireGuard to transport the actual data (mingw-w64)"
arch=('any')
mingw_arch=('ucrt64' 'clang64')
url='https://rosenpass.eu'
msys2_repository_url='https://github.com/rosenpass/rosenpass'
license=('Apache-2.0 OR MIT')
depends=("${MINGW_PACKAGE_PREFIX}-liboqs"
"${MINGW_PACKAGE_PREFIX}-libsodium"
#"${MINGW_PACKAGE_PREFIX}-wireguard-tools"
'gawk'
'findutils')
makedepends=("${MINGW_PACKAGE_PREFIX}-rust"
"${MINGW_PACKAGE_PREFIX}-pkgconf")
source=("https://github.com/rosenpass/rosenpass/archive/v${pkgver}/${_realname}-${pkgver}.tar.gz")
sha256sums=('09dffa62c9bbf3bfa4b34c7667f4052f3c262195a45da9c21c8123f197e7742a')

_env() {
export LIBOQS_NO_VENDOR=1
export PKG_CONFIG_ALL_DYNAMIC=1
}

prepare() {
cd "${srcdir}/${_realname}-${pkgver}"

cargo fetch --locked --target "$(rustc -vV | sed -n 's/host: //p')"
}

build() {
cd "${srcdir}/${_realname}-${pkgver}"

_env
cargo build --release --frozen -p rosenpass
}

check() {
cd "${srcdir}/${_realname}-${pkgver}"

_env
cargo test --release --frozen -p rosenpass
}

package() {
cd "${srcdir}/${_realname}-${pkgver}"

_env
cargo install \
--offline \
--no-track \
--frozen \
--path rosenpass \
--root "${pkgdir}${MINGW_PREFIX}"
install -Dm755 rp "${pkgdir}${MINGW_PREFIX}/bin/rp"

install -Dm644 LICENSE-{APACHE,MIT} -t "${pkgdir}${MINGW_PREFIX}/share/licenses/${_realname}/"
}