diff options
author | DuckSoft | 2021-03-06 08:21:35 +0800 |
---|---|---|
committer | DuckSoft | 2021-03-06 08:21:35 +0800 |
commit | 70dcc828bc54a37fb0271c379e23ff62348d6108 (patch) | |
tree | 1c96554aaf93da3ea00aa41bf7986d41edb1b64d | |
download | aur-70dcc828bc54a37fb0271c379e23ff62348d6108.tar.gz |
init commit
-rw-r--r-- | .SRCINFO | 18 | ||||
-rw-r--r-- | PKGBUILD | 36 |
2 files changed, 54 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 000000000000..05b170e46445 --- /dev/null +++ b/.SRCINFO @@ -0,0 +1,18 @@ +pkgbase = leaf-git + pkgdesc = A lightweight and fast proxy utility tries to include any useful features. + pkgver = 0.2.11.r13.g5b1582f + pkgrel = 1 + url = https://github.com/eycorsican/leaf + arch = x86_64 + arch = aarch64 + license = GPL + makedepends = git + makedepends = cargo + depends = gcc-libs + provides = leaf + conflicts = leaf + source = leaf::git+https://github.com/eycorsican/leaf + b2sums = SKIP + +pkgname = leaf-git + diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 000000000000..14525ac9d0bd --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,36 @@ +# Maintainer: DuckSoft <realducksoft at gmail dot com> +pkgname=leaf-git +pkgver=0.2.11.r13.g5b1582f +pkgrel=1 +pkgdesc="A lightweight and fast proxy utility tries to include any useful features." +arch=(x86_64 aarch64) +url="https://github.com/eycorsican/leaf" +license=('GPL') +depends=(gcc-libs) +makedepends=(git cargo) +provides=(leaf) +conflicts=(leaf) +source=("${pkgname%-git}::git+$url") +b2sums=(SKIP) + +pkgver() { + cd "$srcdir"/"${pkgname%-git}" + git describe --long --tags | sed 's/^v//;s/\([^-]*-g\)/r\1/;s/-/./g' +} + +prepare() { + cd "$srcdir"/"${pkgname%-git}" + git submodule update --init --recursive +} + +build() { + cd "$srcdir"/"${pkgname%-git}" + cargo +nightly build --release -p leaf-bin +} + +package() { + cd "$srcdir"/"${pkgname%-git}" + install -Dm644 LICENSE -t "$pkgdir"/usr/share/licenses/${pkgname%-git}/ + install -Dm644 README{,.zh}.md -t "$pkgdir"/usr/share/doc/${pkgname%-git}/ + install -Dm755 target/release/${pkgname%-git} -t "$pkgdir"/usr/bin/ +} |