summaryrefslogtreecommitdiff
path: root/pcr/ocaml-yojson/PKGBUILD
blob: 5ae179919e21b9b0b49ed01f1a365f7b1f78aff2 (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
# Contributor (Arch)     : Leonard de Ruijter <leonard@aur.archlinux.org>
# Contributor (Arch)     : Serge Zirukin <ftrvxmtrx@gmail.com>
# Contributor (Arch)     : Sergei Lebedev <superbobry@gmail.com>
# Contributor (Arch)     : Justin Davis <jrcd 83 at gmail>
# Maintainer  (Parabola) : Aurélien DESBRIÈRES <aurelien@hackers.camp>

pkgname=ocaml-yojson
_oname=yojson
pkgver=1.1.8
pkgrel=2
pkgdesc='An optimized parsing and printing library for JSON'
arch=('i686' 'x86_64')
options=('!strip' 'staticlibs')
license=('BSD3')
depends=('ocaml-easy-format')
makedepends=('ocaml-biniou' 'ocaml-findlib' 'cppo')
url='http://mjambon.com/yojson.html'
source=("http://mjambon.com/releases/${_oname}/${_oname}-${pkgver}.tar.gz")
md5sums=('e3c53004f74410c3835d851b02c1bf21')
options=(!makeflags)

build() {
  cd $srcdir/$_oname-$pkgver
  make && make doc
}

package() {
  cd $srcdir/$_oname-$pkgver
  mkdir -p $pkgdir/usr/bin $pkgdir$(ocamlfind printconf destdir)
  make OCAMLFIND_DESTDIR=${pkgdir}$(ocamlfind printconf destdir) install BINDIR="${pkgdir}/usr/bin"
  install -dm755 "${pkgdir}/usr/share/doc/$pkgname"
  install -t "${pkgdir}/usr/share/doc/$pkgname" doc/*
}