summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorDuckSoft2020-04-29 20:04:07 +0800
committerDuckSoft2020-04-29 20:04:07 +0800
commit5cae818823f722c69ce76ec98603f660bb03dd1d (patch)
tree045e2e4cf881fb1038e8fba0ec75c0811f204b19
downloadaur-5cae818823f722c69ce76ec98603f660bb03dd1d.tar.gz
initial commit
-rw-r--r--.SRCINFO27
-rw-r--r--PKGBUILD42
2 files changed, 69 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 000000000000..0726be18f2df
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,27 @@
+pkgbase = qv2ray-plugin-trojan-git
+ pkgdesc = Qv2ray Plugin: Trojan
+ pkgver = 20200429.r26.3305c41
+ pkgrel = 1
+ url = https://github.com/Qv2ray/QvPlugin-Trojan
+ arch = x86_64
+ license = GPL3
+ makedepends = git
+ makedepends = make
+ makedepends = qt5-tools
+ makedepends = which
+ makedepends = gcc
+ makedepends = cmake
+ makedepends = ninja
+ makedepends = libffi
+ makedepends = boost
+ depends = qt5-base>5.11.0
+ depends = openssl
+ depends = boost-libs
+ depends = qv2ray
+ provides = qv2ray-plugin-trojan
+ conflicts = qv2ray-plugin-trojan
+ source = qv2ray-plugin-trojan::git+https://github.com/Qv2ray/QvPlugin-Trojan
+ sha512sums = SKIP
+
+pkgname = qv2ray-plugin-trojan-git
+
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..c7a3b5d178dd
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,42 @@
+# Maintainer: DuckSoft <realducksoft at gmail dot com>
+pkgname=qv2ray-plugin-trojan-git
+_pkgname=qv2ray-plugin-trojan
+pkgver=20200429.r26.3305c41
+pkgrel=1
+pkgdesc="Qv2ray Plugin: Trojan"
+arch=('x86_64')
+url='https://github.com/Qv2ray/QvPlugin-Trojan'
+license=('GPL3')
+# _virtualdepends=('qv2ray-plugin-host=1')
+depends=('qt5-base>5.11.0' 'openssl' 'boost-libs' 'qv2ray')
+makedepends=('git' 'make' 'qt5-tools' 'which' 'gcc' 'cmake' 'ninja' 'libffi' 'boost')
+provides=('qv2ray-plugin-trojan')
+conflicts=('qv2ray-plugin-trojan')
+source=("$_pkgname::git+${url}")
+sha512sums=('SKIP')
+pkgver() {
+ cd "$srcdir"/"$_pkgname"
+ local date=$(git log -1 --format="%cd" --date=short | sed s/-//g)
+ local count=$(git rev-list --count HEAD)
+ local commit=$(git rev-parse --short HEAD)
+ echo "$date.r${count}.$commit"
+}
+prepare() {
+ cd "$srcdir"/"$_pkgname"
+ git submodule update --init --recursive
+}
+build() {
+ cd "$srcdir"/"$_pkgname"
+ mkdir -p build && cd build
+ cmake .. \
+ -DCMAKE_BUILD_TYPE=Release \
+ -DFORCE_TCP_FASTOPEN=ON \
+ -GNinja
+ ninja
+}
+package() {
+ cd "$srcdir"/"$_pkgname"/build
+ install -Dm644 libQvTrojanPlugin.so "$pkgdir"/usr/share/qv2ray/plugins/libQvTrojanPlugin.so
+ # NOTE: This virtual dependency will be introduced after Qv2ray stablize its interface.
+ # depends+=(${_virtualdepends[@]})
+}