71 lines
2.4 KiB
Bash
71 lines
2.4 KiB
Bash
# Maintainer: Jesus E. <heckyel@riseup.net>
|
|
|
|
pkgname=tinc
|
|
pkgver=1.0.36
|
|
_debver=$pkgver
|
|
_debrel=2
|
|
pkgrel=1
|
|
pkgdesc="VPN (Virtual Private Network) daemon"
|
|
url="https://www.tinc-vpn.org/"
|
|
arch=('i686' 'x86_64')
|
|
license=('custom:GPL-2+OpenSSL-Linking-Exception+LZO-Linking-Exception')
|
|
depends=('lzo' 'libressl' 'zlib')
|
|
makedepends=('quilt')
|
|
source=(https://www.tinc-vpn.org/packages/tinc-$pkgver.tar.gz{,.sig}
|
|
https://deb.debian.org/debian/pool/main/t/tinc/tinc_$_debver-$_debrel.debian.tar.xz
|
|
tincd.confd
|
|
tincd.initd
|
|
tincd.run)
|
|
sha512sums=('23af9162f7ae700bad01e1f59f23f32d1b183b185ec35f4a69a987c52c53cfebfa9e852203b399f035988078e9131e5d59b018554a52a30044f34df6e64b5289'
|
|
'SKIP'
|
|
'c58b0b4c3983ced1d03ae0490a56b45c7ba1929a1185ced955a294e69d806d961b3d076b8b0b508c0046d73834d4e9967a88e6c76daa0c8bb71bbda122509523'
|
|
'f8d9354af5ebc07420ced98059262751bffef434b61c6333964338f327e2ac01ae676e375954efa794a1bccf8b939c78387b9fb7261f675f1237b0d946b529c9'
|
|
'cd4e56cd49cc48409b753e4366c8a2f57babe9da80bdf048f3bd562debd82405c641af7f3c4c73460a720c3e458194cb5af6bf4ed84f04758b47b991fb01c385'
|
|
'51f259d4584945c9eb99d3a0bb837e90126a331fc63c4477ce751b902a3fffdeb5247d1465d19de00004b0e5f46f87d3c568d9847c732bf7a5dd86375f6aa883')
|
|
validpgpkeys=('D62BDD168EFBE48BC60E8E234A6084B9C0D71F4A')
|
|
|
|
prepare() {
|
|
cd $pkgname-$pkgver
|
|
|
|
if [[ ${pkgver%.*} = ${_debver%.*} ]]; then
|
|
# Debian patches
|
|
export QUILT_PATCHES=debian/patches
|
|
export QUILT_REFRESH_ARGS='-p ab --no-timestamps --no-index'
|
|
export QUILT_DIFF_ARGS='--no-timestamps'
|
|
|
|
mv "$srcdir"/debian .
|
|
|
|
quilt push -av
|
|
fi
|
|
}
|
|
|
|
build() {
|
|
cd $pkgname-$pkgver
|
|
|
|
./configure \
|
|
--prefix=/usr \
|
|
--sysconfdir=/etc \
|
|
--localstatedir=/var
|
|
make
|
|
}
|
|
|
|
package() {
|
|
cd $pkgname-$pkgver
|
|
|
|
make DESTDIR="$pkgdir/" install
|
|
install -dm755 "$pkgdir"/usr/share/tinc/examples
|
|
cp -a doc/sample-config/. "$pkgdir"/usr/share/tinc/examples/
|
|
find "$pkgdir"/usr/share/tinc/examples -type f -exec chmod 644 {} +
|
|
find "$pkgdir"/usr/share/tinc/examples -type d -exec chmod 755 {} +
|
|
|
|
# services
|
|
install -Dm644 $srcdir/tincd.confd "$pkgdir"/etc/conf.d/tincd
|
|
install -Dm755 $srcdir/tincd.initd "$pkgdir"/etc/init.d/tincd
|
|
install -Dm755 $srcdir/tincd.run "$pkgdir"/etc/sv/tincd/run
|
|
|
|
# licenses
|
|
for i in COPYING{,.README}; do
|
|
install -Dm644 $i "$pkgdir"/usr/share/licenses/$pkgname/$i
|
|
done
|
|
}
|