diff options
author | Chocobo1 | 2017-03-18 13:43:07 +0800 |
---|---|---|
committer | Chocobo1 | 2017-03-18 13:59:22 +0800 |
commit | 4e51d4a721de8b544d4461cb72c05ca8bebfb98c (patch) | |
tree | 6d391664e07f27906e11cc48563943f86ed0d502 | |
download | aur-4e51d4a721de8b544d4461cb72c05ca8bebfb98c.tar.gz |
newpkg: gflags-git 2.2.0.r5.g30dbc81-1
-rw-r--r-- | .SRCINFO | 18 | ||||
-rw-r--r-- | PKGBUILD | 52 |
2 files changed, 70 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 000000000000..0f49f3752b30 --- /dev/null +++ b/.SRCINFO @@ -0,0 +1,18 @@ +pkgbase = gflags-git + pkgdesc = C++ Library for commandline flag processing + pkgver = 2.2.0.r5.g30dbc81 + pkgrel = 1 + url = https://github.com/gflags/gflags + arch = i686 + arch = x86_64 + license = BSD + makedepends = git + makedepends = cmake + provides = gflags + conflicts = gflags + options = staticlibs + source = git+https://github.com/gflags/gflags.git + sha256sums = SKIP + +pkgname = gflags-git + diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 000000000000..e7e103158c3a --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,52 @@ +# Maintainer: Chocobo1 <chocobo1 AT archlinux DOT net> + +pkgname=gflags-git +pkgver=2.2.0.r5.g30dbc81 +pkgrel=1 +pkgdesc="C++ Library for commandline flag processing" +arch=('i686' 'x86_64') +url="https://github.com/gflags/gflags" +license=('BSD') +makedepends=('git' 'cmake') +provides=('gflags') +conflicts=('gflags') +options=('staticlibs') +source=("git+https://github.com/gflags/gflags.git") +sha256sums=('SKIP') + + +pkgver() { + cd "gflags" + + git describe --long --tags | sed 's/^[A-Za-z]*//;s/\([^-]*-g\)/r\1/;s/-/./g' +} + +prepare() { + cd "gflags" + + mkdir -p "build" +} + +build() { + cd "gflags/build" + + cmake -DCMAKE_INSTALL_PREFIX="/usr" \ + -DREGISTER_INSTALL_PREFIX=OFF \ + -DBUILD_SHARED_LIBS=ON \ + -DBUILD_STATIC_LIBS=ON \ + -DBUILD_TESTING=ON ../ + make +} + +check() { + cd "gflags/build" + + make test +} + +package() { + cd "gflags/build" + + make DESTDIR="$pkgdir" install + install -D -m644 "../COPYING.txt" "$pkgdir/usr/share/licenses/gflags/COPYING.txt" +} |