# $Id: PKGBUILD 70458 2012-05-08 13:27:24Z seblu $ # Maintainer: Sébastien Luttringer # Contributor: Le_suisse # Contributor: Jason Rodriguez pkgname=sslh pkgver=1.12 pkgrel=1 pkgdesc='SSL/SSH/OpenVPN/XMPP/tinc port multiplexer' arch=('i686' 'x86_64') url='http://www.rutschle.net/tech/sslh.shtml' license=('GPL2') depends=('libconfig') backup=('etc/conf.d/sslh' 'etc/sslh.conf') source=("http://www.rutschle.net/tech/$pkgname-$pkgver.tar.gz" 'sslh.rc' 'sslh.conf' 'sslh.service') md5sums=('265014ecdae4512eacca91aaff0b9a81' 'e1c44f8160b7fef397f81db63eec8421' 'c51c63d2b28080bae4c1c7a0c469bab7' 'ee8a4fcfc1f6839f7c93deb6f59f7fd6') build() { cd $pkgname-$pkgver # fix archlinux path in manpage sed -i 's/init.d/rc.d/' sslh.pod sed -i 's+/etc/default+/etc/conf.d+' sslh.pod # remove default pidfile in example sed -i '/pidfile:/d' example.cfg # daemon mode by default (as not overridable in command line) sed -i 's/foreground: true;/foreground: false;/' example.cfg make } package() { # install initscripts install -Dm 755 sslh.rc "$pkgdir/etc/rc.d/sslh" install -Dm 644 sslh.conf "$pkgdir/etc/conf.d/sslh" # install systemd service install -Dm 644 sslh.service "$pkgdir/usr/lib/systemd/system/sslh.service" # manually install to have both ssl-fork and ssl-select cd $pkgname-$pkgver install -Dm 0755 sslh-fork "$pkgdir/usr/bin/sslh-fork" install -Dm 0755 sslh-select "$pkgdir/usr/bin/sslh-select" ln -s sslh-fork "$pkgdir/usr/bin/sslh" install -Dm 0644 sslh.8.gz "$pkgdir/usr/share/man/man8/sslh.8.gz" install -Dm 0644 example.cfg "$pkgdir/etc/sslh.conf" } # vim:set ts=2 sw=2 ft=sh et: