Skip to content

Commit

Permalink
vpnc: change upstream to fork
Browse files Browse the repository at this point in the history
fixes void-linux#26798.

* Changes upstream to https://github.com/streambinder/vpnc/. That's a fork
  that's a fork which is at least used in alpine.
* Depends on vpnc-scripts. New upstream doesn't ship those files anymore
* Add wrapper script to stay backwards compatible
* Switch to build_style=gnu-makefile instead of manually calling make.
  • Loading branch information
Gottox committed Jan 31, 2021
1 parent df52627 commit f907270
Show file tree
Hide file tree
Showing 4 changed files with 23 additions and 127 deletions.
3 changes: 3 additions & 0 deletions srcpkgs/vpnc/files/vpnc-script
@@ -0,0 +1,3 @@
#!/bin/sh

exec /usr/libexec/vpnc-scripts/vpnc-script "$@"
81 changes: 0 additions & 81 deletions srcpkgs/vpnc/patches/00-fix-fritzbox.diff

This file was deleted.

33 changes: 0 additions & 33 deletions srcpkgs/vpnc/patches/2-fix-musl.patch

This file was deleted.

33 changes: 20 additions & 13 deletions srcpkgs/vpnc/template
@@ -1,17 +1,22 @@
# Template file for 'vpnc'
pkgname=vpnc
version=0.5.3
revision=7
revision=8
_githash=43780cecd7a61668002f73b6f8b9f9ba61af74ad
wrksrc="vpnc-$_githash"
build_style=gnu-makefile
make_use_env=yes
make_build_args="SBINDIR=/usr/bin"
make_check_target=test
hostmakedepends="perl"
makedepends="libgcrypt-devel"
depends="net-tools"
makedepends="libgcrypt-devel libressl-devel"
depends="net-tools vpnc-scripts"
short_desc="Client for cisco vpn concentrator"
maintainer="Enno Boland <gottox@voidlinux.org>"
license="GPL-2.0-or-later"
homepage="https://www.unix-ag.uni-kl.de/~massar/vpnc/"
distfiles="https://www.unix-ag.uni-kl.de/~massar/vpnc/vpnc-${version}.tar.gz"
checksum=46cea3bd02f207c62c7c6f2f22133382602baeda1dc320747809e94881414884

distfiles="https://github.com/streambinder/vpnc/archive/$_githash.tar.gz"
checksum=473449da6be522eea43c2b16e6b2214d6ace49a2eac0a625405981193fc43170
conf_files="
/etc/vpnc/default.conf
/etc/vpnc/vpnc-script"
Expand All @@ -20,14 +25,16 @@ if [ "$CROSS_BUILD" ]; then
hostmakedepends+=" vpnc"
fi

do_configure() {
post_patch() {
vsed -e 's/^#OPENSSL/OPENSSL/' -i Makefile
vsed -e 's/^install:.*/install: install-common/' -i Makefile
vsed -e 's#^SBINDIR=.*#SBINDIR=/$(PREFIX)/bin#' -i Makefile
if [ "$CROSS_BUILD" ]; then
sed -i 's%^my \$vpnc = .*;%my \$vpnc = "/usr/bin/vpnc";%' makeman.pl
vsed -e 's%^my \$vpnc = .*;%my \$vpnc = "/usr/bin/vpnc";%' -i src/makeman.pl
fi
}
do_build() {
make CC=$CC ${makejobs}
}
do_install() {
make PREFIX=/usr SBINDIR=/usr/bin DESTDIR=${DESTDIR} install

post_install() {
rm -r $DESTDIR/usr/lib/systemd/system
vinstall $FILESDIR/vpnc-script 755 etc/vpnc
}

0 comments on commit f907270

Please sign in to comment.