diff options
author | André Fabian Silva Delgado <emulatorman@parabola.nu> | 2014-02-25 21:31:19 -0200 |
---|---|---|
committer | André Fabian Silva Delgado <emulatorman@parabola.nu> | 2014-02-25 21:31:48 -0200 |
commit | 9a9a2e94f674d97421d82792a300c26d86c18e68 (patch) | |
tree | 0ded364fb64523de1c88cd0b1fbabfe353e00678 /pcr/tunnels-git/PKGBUILD | |
parent | c937a305a82069a4f4745608acbf08a281b549d5 (diff) |
tunnels-git: adding on abslibre because it's included from pacman database only (https://labs.parabola.nu/issues/491)
Diffstat (limited to 'pcr/tunnels-git/PKGBUILD')
-rw-r--r-- | pcr/tunnels-git/PKGBUILD | 58 |
1 files changed, 58 insertions, 0 deletions
diff --git a/pcr/tunnels-git/PKGBUILD b/pcr/tunnels-git/PKGBUILD new file mode 100644 index 000000000..bf1f0e8bc --- /dev/null +++ b/pcr/tunnels-git/PKGBUILD @@ -0,0 +1,58 @@ +# Maintainer: Etienne Perot <etienne at perot dot me> +pkgname=tunnels-git +pkgver=20130503 +pkgrel=1 +pkgdesc='Transparent, system-wide, domain-name-specific proxying rules' +arch=('any') +url='https://github.com/EtiennePerot/tunnels' +license=('LGPL') +depends=('bash' 'python2' 'python2-paramiko' 'python2-yaml') +makedepends=('git' 'svn') +source=( + 'https://socksipy-branch.googlecode.com/svn-history/r19/trunk/socks.py' + 'https://pypi.python.org/packages/source/p/python-daemon/python-daemon-1.6.tar.gz' + 'https://pypi.python.org/packages/source/l/lockfile/lockfile-0.9.1.tar.gz' +) +sha512sums=( + '58e7393b365ad5bde308cb2290224c15dfce82c0dc8e3209b8c4fea9876d1afa5bebfd184ea5e9d577d1494037f78bf5013a64d7ad21b5ed4b7405fb4a3a86dd' + 'ff9480844d8f57a09f27067aaa78669c167f66b2cc05f9b3baa660bc0aa21228d4894eeaeb3440611c1e0f0d5633b1c60eac60893da4a86d1db4b94d99961299' + '46288cb4d15bcb546d6cece7e032b7b020c71fba695d16a3c7718eeb0bc15c97c29f09f3c1649b6061d117e6bbd708e243fdcee89b2fa5f13a262a0e74f62c3d' +) + +_gitroot='git://perot.me/tunnels' +_gitname='tunnels' + +build() { + cd "$srcdir" + msg "Connecting to GIT server...." + + if [[ -d "$_gitname" ]]; then + cd "$_gitname" && git pull origin + msg "The local files are updated." + else + git clone "$_gitroot" "$_gitname" + fi + + msg "Starting build..." + + rm -rf "$srcdir/$_gitname-build" + git clone "$srcdir/$_gitname" "$srcdir/$_gitname-build" + cd "$srcdir/$_gitname-build" + cp -ra "$srcdir/socks.py" "$srcdir"/python-daemon-*/daemon "$srcdir"/lockfile-*/lockfile src/ + python util/mkportslist.py > conf.d.sample/autogenerated-ports.yml +} + +package() { + cd "$srcdir/$_gitname-build" + install -D -m644 LICENSE "$pkgdir/usr/share/licenses/$pkgname/LICENSE" + install -D -m644 pkg/resources/tunnels.service "$pkgdir/usr/lib/systemd/system/tunnels.service" + mkdir -p "$pkgdir/usr/lib/tunnels" + for target in conf.d.sample src tunnels tunnelsd; do + cp -ra "$target" "$pkgdir/usr/lib/tunnels/" + done + mkdir -p "$pkgdir/etc/tunnels.d" + cp -a conf.d.sample/* "$pkgdir/etc/tunnels.d/" + mkdir -p "${pkgdir}/usr/bin" + ln -sf /usr/lib/tunnels/tunnels "$pkgdir/usr/bin/tunnels" + ln -sf /usr/lib/tunnels/tunnelsd "$pkgdir/usr/bin/tunnelsd" +} |