summarylogtreecommitdiffstats
path: root/PKGBUILD
diff options
context:
space:
mode:
authorIshan Arora2022-12-26 18:28:17 +1300
committerIshan Arora2022-12-26 18:28:17 +1300
commit1f060d5e7220baf90afad40006357a20d00dc8c7 (patch)
tree343cef57c239c73508d068e8c477e9cbd93b50dc /PKGBUILD
downloadaur-1f060d5e7220baf90afad40006357a20d00dc8c7.tar.gz
Autorestic v1.7.4
Diffstat (limited to 'PKGBUILD')
-rw-r--r--PKGBUILD31
1 files changed, 31 insertions, 0 deletions
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..15c044d75a5a
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,31 @@
+pkgname=autorestic
+pkgver=1.7.4
+pkgrel=1
+pkgdesc='Config driven, easy backup cli for restic'
+arch=('i686' 'x86_64' 'armv7h' 'aarch64')
+url="https://github.com/cupcakearmy/$pkgname"
+license=('Apache License 2.0')
+depends=('restic')
+makedepends=('go')
+source=("${pkgname}-${pkgver}.tar.gz::$url/archive/refs/tags/v$pkgver.tar.gz")
+sha256sums=('253a16dbad709e1e1065222ab0950ded6dc302ebcebba2585eed7759c7b99714')
+
+prepare(){
+ cd "$pkgname-$pkgver"
+ mkdir -p build/
+}
+
+build() {
+ cd "$pkgname-$pkgver"
+ export CGO_CPPFLAGS="${CPPFLAGS}"
+ export CGO_CFLAGS="${CFLAGS}"
+ export CGO_CXXFLAGS="${CXXFLAGS}"
+ export CGO_LDFLAGS="${LDFLAGS}"
+ export GOFLAGS="-buildmode=pie -trimpath -ldflags=-linkmode=external -mod=readonly -modcacherw"
+ go build
+}
+
+package() {
+ cd "$pkgname-$pkgver"
+ install -Dm755 $pkgname "$pkgdir"/usr/bin/$pkgname
+}