summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorEndlessEden2021-03-14 00:41:44 +1100
committerEndlessEden2021-03-14 00:41:44 +1100
commitb2eead011dff1ed9809b2318f313f6404be49e0a (patch)
tree6ec87995a385a4ce1fe903a4b537e6d8083449a5
downloadaur-jsoncpp-cmake-git.tar.gz
Init
-rw-r--r--.SRCINFO22
-rw-r--r--PKGBUILD51
2 files changed, 73 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 000000000000..282f88454f64
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,22 @@
+pkgbase = jsoncpp-cmake-git
+ pkgdesc = C++ library for interacting with JSON; cmake version: FS#60285
+ pkgver = 1.9.4.r21.g1ee39a6
+ pkgrel = 1
+ url = https://github.com/open-source-parsers/jsoncpp
+ arch = i686
+ arch = x86_64
+ license = MIT
+ license = custom
+ makedepends = git
+ makedepends = meson
+ makedepends = python
+ depends = gcc-libs
+ provides = jsoncpp
+ conflicts = jsoncpp
+ conflicts = jsoncpp-git
+ options = staticlibs
+ source = git+https://github.com/open-source-parsers/jsoncpp.git
+ sha256sums = SKIP
+
+pkgname = jsoncpp-cmake-git
+
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..8572584f1638
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,51 @@
+# Maintainer: Endlesseden <eden AT rose DOT place>
+# Upstream Maintainer: Chocobo1 <chocobo1 AT archlinux DOT net>
+
+pkgname=jsoncpp-cmake-git
+pkgver=1.9.4.r21.g1ee39a6
+pkgrel=1
+pkgdesc="C++ library for interacting with JSON; cmake version: FS#60285"
+arch=('i686' 'x86_64')
+url="https://github.com/open-source-parsers/jsoncpp"
+license=('MIT' 'custom')
+depends=('gcc-libs')
+makedepends=('git' 'meson' 'python')
+provides=('jsoncpp')
+conflicts=('jsoncpp' 'jsoncpp-git')
+options=('staticlibs')
+source=("git+https://github.com/open-source-parsers/jsoncpp.git")
+sha256sums=('SKIP')
+
+
+pkgver() {
+ cd "jsoncpp"
+
+ git describe --long --tags | sed 's/^v//;s/\([^-]*-g\)/r\1/;s/-/./g'
+}
+
+build() {
+ cd "jsoncpp"
+ if [ -d build ]; then
+ rm -r build
+ fi
+ mkdir build && cd build
+
+ cmake -DCMAKE_INSTALL_PREFIX="/usr" \
+ -DCMAKE_INSTALL_SBINDIR="bin" \
+ -DJSONCPP_WITH_CMAKE_PACKAGE=ON ..
+ make
+}
+
+check() {
+ cd "jsoncpp"
+
+ cd "build"
+ ctest
+}
+
+package() {
+ cd "jsoncpp"/"build"
+
+ DESTDIR="$pkgdir" make install
+ install -Dm644 "../LICENSE" -t "$pkgdir/usr/share/licenses/jsoncpp"
+}