blob: 2dbe831df1bcd4fa7018003c80118bb1a7cf17c2 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
|
# Maintainer: Jesin <Jesin00@gmail.com>
# Contributor: Eduardo Sánchez Muñoz
pkgname=nlohmann-json-git
_name="${pkgname%-git}"
pkgver=2.1.1+603+gcc937dea
pkgrel=1
pkgdesc='Header-only JSON library for Modern C++'
url='https://github.com/nlohmann/json'
license=(MIT)
arch=(x86_64)
makedepends=(cmake git)
provides=("$_name")
conflicts=("$_name")
source=("git+$url")
sha256sums=(SKIP)
pkgver() {
cd json
local v="$(git describe --tags)"
v="${v#v}"
printf %s "${v//-/+}"
}
build() {
mkdir build
cd build
cmake ../json -DCMAKE_INSTALL_PREFIX=/usr -DCMAKE_BUILD_TYPE=Release
make
}
check() {
cd build
ctest --output-on-failure
}
package() {
cd build
make "DESTDIR=$pkgdir" install
install -Dm644 "-t$pkgdir/usr/share/licenses/$_name" ../json/LICENSE.MIT
}
|