summarylogtreecommitdiffstats
path: root/PKGBUILD
diff options
context:
space:
mode:
authorAndy Weidenbaum2016-04-26 09:42:46 -0700
committerAndy Weidenbaum2016-04-26 09:42:46 -0700
commitd5fa1f71db4ce16941a6d3af3d181f8552360bac (patch)
treeccea2636cc04d8c8e619a04cfdbd5bc5bcd969bd /PKGBUILD
downloadaur-d5fa1f71db4ce16941a6d3af3d181f8552360bac.tar.gz
Initial import
Diffstat (limited to 'PKGBUILD')
-rw-r--r--PKGBUILD44
1 files changed, 44 insertions, 0 deletions
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..a8e8cc75870c
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,44 @@
+# Maintainer: Andy Weidenbaum <archbaum@gmail.com>
+
+pkgname=flatcc-git
+pkgver=20160420
+pkgrel=1
+pkgdesc="FlatBuffers Compiler and Library in C for C"
+arch=('i686' 'x86_64')
+makedepends=('cmake' 'git' 'ninja')
+url="https://github.com/dvidelabs/flatcc"
+license=('Apache')
+options=('staticlibs')
+source=(git+https://github.com/dvidelabs/flatcc)
+sha256sums=('SKIP')
+provides=('flatcc')
+conflicts=('flatcc')
+
+pkgver() {
+ cd ${pkgname%-git}
+ git log -1 --format="%cd" --date=short | sed "s|-||g"
+}
+
+build() {
+ cd ${pkgname%-git}
+
+ msg2 'Building...'
+ ./scripts/build.sh
+}
+
+package() {
+ cd ${pkgname%-git}
+
+ msg2 'Installing license...'
+ install -Dm 644 LICENSE NOTICE -t "$pkgdir/usr/share/licenses/${pkgname%-git}"
+
+ msg2 'Installing documentation...'
+ install -Dm 644 *.md doc/* -t "$pkgdir/usr/share/doc/${pkgname%-git}"
+
+ msg2 'Installing...'
+ find bin -mindepth 1 -maxdepth 1 -type f -exec \
+ install -Dm 755 -t "$pkgdir/usr/bin" '{}' +
+ find lib -mindepth 1 -maxdepth 1 -type f -exec \
+ install -Dm 644 -t "$pkgdir/usr/lib" '{}' +
+ cp -dpr --no-preserve=ownership include "$pkgdir/usr"
+}