summaryrefslogtreecommitdiff
path: root/community/ocaml-findlib/PKGBUILD
blob: 8cca5d56526bd9838e9f0c6743c99b88b29978a3 (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
34
35
36
# Maintainer: Thomas S Hatch <thatch45 at gmail dot com>
# Contributor: Sebastian Wiesner <lunaryorn googlemail com>
# Contributor: Benjamin Andresen <benny(at)klapmuetz(dot)org>
#              scj <scj archlinux us>
pkgname=ocaml-findlib
pkgver=1.2.6
pkgrel=4
license=('MIT')
arch=('i686' 'x86_64')
pkgdesc="Objective Caml (OCaml) package manager"
url="http://projects.camlcity.org/projects/findlib.html"
depends=('ocaml')
source=("http://download.camlcity.org/download/findlib-${pkgver}.tar.gz")
md5sums=('4924c8c3ef1208eb0fa9096c8b8bb72f')
options=('!strip' 'zipman') # otherwise the bytecode gets broken

build() {
  cd ${srcdir}/findlib-${pkgver}
  ./configure\
      -config /etc/findlib.conf \
      -sitelib /usr/lib/ocaml \
      -mandir /usr/share/man
  make all opt
}

package () {
  cd ${srcdir}/findlib-${pkgver}
  make prefix=${pkgdir} install 

  # Add the old site-lib to the path to maintain compatability with old style
  # packages.
  sed -i 's/path=\"\/usr\/lib\/ocaml\"/path="\/usr\/lib\/ocaml:\/usr\/lib\/ocaml\/site-lib"/' ${pkgdir}/etc/findlib.conf

  install -m755 src/findlib/ocamlfind_opt "${pkgdir}/usr/bin/"
  install -Dm644 LICENSE "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
}