summarylogtreecommitdiffstats
path: root/PKGBUILD
diff options
context:
space:
mode:
authorHaruue Icymoon2018-07-31 11:18:06 +0800
committerHaruue Icymoon2018-07-31 11:18:06 +0800
commit977d640a11a87a287e72af94ea4076de3c4595a5 (patch)
treeb3dc6962995cdb1d60971eda8e74f3fb7a8787be /PKGBUILD
downloadaur-977d640a11a87a287e72af94ea4076de3c4595a5.tar.gz
version: 1.0-1
Diffstat (limited to 'PKGBUILD')
-rw-r--r--PKGBUILD32
1 files changed, 32 insertions, 0 deletions
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..d4f969a6bae8
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,32 @@
+# Maintainer: Haruue Icymoon <haruue@caoyue.com.cn>
+
+pkgname=port-protection
+_pkgbase=PortProtection
+pkgver=1.0
+pkgrel=1
+pkgdesc='A program to protect port with iptables by authorizing client on another port'
+arch=('i686' 'x86_64')
+url='https://github.com/PinkD/PortProtection'
+license=('GPL2')
+depends=('openssl')
+makedepends=('cmake')
+options=('!strip')
+source=("$pkgname.tar.gz"::"https://github.com/PinkD/PortProtection/archive/$pkgver.tar.gz")
+md5sums=('a18e0c4bfb61be127e23105737f63619')
+
+build() {
+ cd "$srcdir/$_pkgbase-$pkgver"
+ mkdir -p build
+ cd build
+ unset CFLAGS
+ unset CXXFLAGS
+ cmake ..
+ make
+}
+
+package() {
+ cd "$srcdir/$_pkgbase-$pkgver"
+ install -Dm 755 "build/PortProtection" "$pkgdir/usr/bin/PortProtection"
+ install -Dm 644 "config/sample.conf" "$pkgdir/etc/portpro/sample.conf"
+ install -Dm 644 "tools/systemd/port-protection@.service" "$pkgdir/usr/lib/systemd/system/port-protection@.service"
+}