diff options
author | Chris Leishman <chris@leishman.org> | 2016-07-29 15:24:59 +0200 |
---|---|---|
committer | Natanael Copa <ncopa@alpinelinux.org> | 2016-09-22 10:26:16 +0000 |
commit | 69c2a856eb1d4f1dcf4ffbb6bbcb7bc2e1542149 (patch) | |
tree | 6e23ac5e95632ff95e40f0692670af3775388961 | |
parent | 0798c6c89299d8378673c24553c9bea84d4fa07e (diff) | |
download | aports-69c2a856eb1d4f1dcf4ffbb6bbcb7bc2e1542149.tar.bz2 aports-69c2a856eb1d4f1dcf4ffbb6bbcb7bc2e1542149.tar.xz |
testing/libcypher-parser: new aport
https://github.com/cleishm/libcypher-parser
Parsing library for the Cypher query language
-rw-r--r-- | testing/libcypher-parser/APKBUILD | 69 |
1 files changed, 69 insertions, 0 deletions
diff --git a/testing/libcypher-parser/APKBUILD b/testing/libcypher-parser/APKBUILD new file mode 100644 index 0000000000..1e223ed4b5 --- /dev/null +++ b/testing/libcypher-parser/APKBUILD @@ -0,0 +1,69 @@ +# Contributor: Chris Leishman <chris@leishman.org> +# Maintainer: Chris Leishman <chris@leishman.org> +pkgname=libcypher-parser +pkgver=0.5.1 +pkgrel=0 +pkgdesc="Parsing library for the Cypher query language" +url="https://github.com/cleishm/libcypher-parser" +arch="all" +license="ASL 2.0" +depends="" +depends_dev="" +makedepends="$depends_dev automake autoconf libtool check-dev doxygen pkgconfig" +install="" +subpackages="$pkgname-dev $pkgname-doc cypher-lint cypher-lint-doc" +source="https://github.com/cleishm/libcypher-parser/releases/download/v$pkgver/$pkgname-$pkgver.tar.gz" + +_builddir="$srcdir"/"$pkgname-$pkgver" +build() { + cd "$_builddir" + ./configure \ + --prefix=/usr \ + || return 1 + make || return 1 + make check || return 1 + make doc || return 1 +} + +package() { + cd "$_builddir" + make DESTDIR="$pkgdir" install || return 1 + mkdir -p "$pkgdir"/usr/share/doc/libcypher-parser + mv doc/html/* "$pkgdir"/usr/share/doc/libcypher-parser/ +} + +doc() { + depends="$depends_doc" + pkgdesc="$pkgdesc (documentation)" + arch=${arch_doc:-"noarch"} + install_if="docs $pkgname=$pkgver-r$pkgrel" + + if [ "X$subpkgname" = "Xlibcypher-parser-doc" ]; then + mkdir -p "$subpkgdir"/usr/share + mv "$pkgdir"/usr/share/doc "$subpkgdir"/usr/share/ + elif [ "X$subpkgname" = "Xcypher-lint-doc" ]; then + mkdir -p "$subpkgdir"/usr/share + mv "$pkgdir"/usr/share/man "$subpkgdir"/usr/share/ + find "$subpkgdir"/usr/share/man/ -type f | xargs gzip -9 + else + die "Unknown doc package $pkgname" + fi + + # remove if empty, ignore error (not empty) + rmdir "$pkgdir"/usr/share "$pkgdir"/usr 2>/dev/null + return 0 +} + +lint() { + pkgdesc="Lint tool for the Cypher query language" + + mkdir -p "$subpkgdir"/usr + mv "$pkgdir"/usr/bin "$subpkgdir"/usr/ + + # remove if empty, ignore error (not empty) + rmdir "$pkgdir"/usr/bin "$pkgdir"/usr 2>/dev/null + return 0 +} +md5sums="c4c9a3bd9a97f4d97c1ffeb1ff19ebbe libcypher-parser-0.5.1.tar.gz" +sha256sums="bc9e3234e97b2e7c5829bfe17ed9e2f6a619a2e66144b6db7a6082e697441ead libcypher-parser-0.5.1.tar.gz" +sha512sums="632d65741332cc81cb42bbf61f53074677d81db27b6a8f2ce9f44fa04f82f16fd13b78c1ed34518124f7e10b77dc87fa3d4f791d19e076c6dc668b89faa82a56 libcypher-parser-0.5.1.tar.gz" |