summarylogtreecommitdiffstats
path: root/PKGBUILD
diff options
context:
space:
mode:
authorOnur Kader2021-12-13 18:37:42 +0300
committerOnur Kader2021-12-13 18:37:42 +0300
commit70c55e8f8a0102e9982a3c9498f58f2a7581d0b3 (patch)
treea0647650e50eaee54a7ea05517db011d785cd3f5 /PKGBUILD
downloadaur-70c55e8f8a0102e9982a3c9498f58f2a7581d0b3.tar.gz
scnlib-git: Add a simple PKGBUILD, might be wrong
Diffstat (limited to 'PKGBUILD')
-rw-r--r--PKGBUILD37
1 files changed, 37 insertions, 0 deletions
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..bbc91c3a4725
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,37 @@
+# Maintainer: Onur Kader <onurorkunkader1999@gmail.com>
+pkgname=scnlib-git
+pkgver=r361.815782b
+pkgrel=1
+pkgdesc="A formatted input library, think {fmt} but in the other direction. 'scanf' for modern C++"
+arch=("x86_64")
+url="https://github.com/eliaskosunen/scnlib"
+license=("Apache")
+makedepends=("git" "cmake")
+provides=("${pkgname%-git}")
+source=("${pkgname}::git+https://github.com/eliaskosunen/scnlib.git")
+md5sums=("SKIP")
+options=(!strip)
+
+pkgver() {
+ cd "$srcdir/$pkgname"
+ printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
+}
+
+build() {
+ cd "$srcdir/$pkgname"
+ mkdir build
+ cd build
+ cmake -DCMAKE_INTERPROCEDURAL_OPTIMIZATION=ON ..
+ cmake --build .
+}
+
+check() {
+ cd "$srcdir/$pkgname/build"
+ cmake --build . --target test
+}
+
+package() {
+ cd "$srcdir/$pkgname/build"
+ DESTDIR="$pkgdir/" cmake --build . --target install
+}
+