diff options
author | Eduardo Sánchez Muñoz | 2017-10-15 18:59:22 +0200 |
---|---|---|
committer | Eduardo Sánchez Muñoz | 2017-10-15 18:59:22 +0200 |
commit | 393ad250d1f7a32c66fa1312ac12024275b260fd (patch) | |
tree | adf42405ab82a9bceaf852ae9067aaa71f699196 | |
parent | 8e2ddacd5cd7e868514d7bba8771d9ecb7dff4b9 (diff) | |
download | aur-393ad250d1f7a32c66fa1312ac12024275b260fd.tar.gz |
Fix package
-rw-r--r-- | .SRCINFO | 14 | ||||
-rw-r--r-- | .gitignore | 4 | ||||
-rw-r--r-- | PKGBUILD | 46 |
3 files changed, 31 insertions, 33 deletions
@@ -1,14 +1,16 @@ +# Generated by mksrcinfo v8 +# Sun Oct 15 16:57:01 UTC 2017 pkgbase = nlohmann-json - pkgdesc = JSON for Modern C++, whole code consistes of a single header file - pkgver = 2.1.1.r487.gb05ea3de + pkgdesc = Header-only JSON library for Modern C++ + pkgver = 2.1.1 pkgrel = 1 url = https://github.com/nlohmann/json - arch = any + arch = i686 + arch = x86_64 license = MIT - makedepends = git makedepends = cmake - source = nlohmann-json::git+https://github.com/nlohmann/json.git - md5sums = SKIP + source = https://github.com/nlohmann/json/archive/v2.1.1.tar.gz + sha256sums = SKIP pkgname = nlohmann-json diff --git a/.gitignore b/.gitignore new file mode 100644 index 000000000000..48d23192e391 --- /dev/null +++ b/.gitignore @@ -0,0 +1,4 @@ +/*.tar.xz +/*.tar.gz +/pkg +/src @@ -1,39 +1,31 @@ -# Maintainer: bartus <aur@bartus.33mail.com> pkgname=nlohmann-json -#for fragment you can use one of: #commit=, #tag=, #branch= -#fragment= -pkgver=2.1.1.r487.gb05ea3de +pkgver=2.1.1 pkgrel=1 -pkgdesc="JSON for Modern C++, whole code consistes of a single header file" -arch=(any) +pkgdesc="Header-only JSON library for Modern C++" url="https://github.com/nlohmann/json" -license=(MIT) -makedepends=(git cmake) -source=(${pkgname}::git+https://github.com/nlohmann/json.git${fragment}) -md5sums=(SKIP) #generate with 'makepkg -g' - -pkgver() { - cd "$pkgname" - git describe --long --tags | sed 's/^v//;s/\([^-]*-g\)/r\1/;s/-/./g' -} +license=('MIT') +arch=('i686' 'x86_64') +makedepends=('cmake') +source=("https://github.com/nlohmann/json/archive/v$pkgver.tar.gz") +sha256sums=('SKIP') build() { - cd ${pkgname} - mkdir -p build - cd build - cmake -DCMAKE_INSTALL_PREFIX=/usr .. - make + mkdir -p "$srcdir/nlohmann-json-build" + cd "$srcdir/nlohmann-json-build" + + cmake "$srcdir/json-$pkgver" \ + -DCMAKE_INSTALL_PREFIX=/usr + make } check() { - cd ${pkgname}/build - make test + cd "$srcdir/nlohmann-json-build" + # Tests in this version are broken + #CTEST_OUTPUT_ON_FAILURE=1 ctest } package() { - cd ${pkgname}/build - make DESTDIR="$pkgdir/" install - install -D -m644 "../LICENSE.MIT" "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE" + cd "$srcdir/nlohmann-json-build" + make DESTDIR="$pkgdir" install + install -Dm644 "$srcdir/json-$pkgver/LICENSE.MIT" "$pkgdir/usr/share/licenses/$pkgname/LICENSE.MIT" } - -# vim:set ts=2 sw=2 et: |