gnu: camlp4: Install camlp4 META file.

* gnu/packages/ocaml.scm (camlp4)[arguments]: Install in OCAMLPATH and
  META file.
  (ocaml-findlib)[arguments]: Delete camlp4 META file.

Signed-off-by: David Craven <david@craven.ch>
This commit is contained in:
Julien Lepiller 2016-12-22 20:13:49 +01:00 committed by David Craven
parent 56f73eadc0
commit ad3d730e3a
No known key found for this signature in database
GPG key ID: C5E051C79C0BECDB

View file

@ -256,9 +256,19 @@ (define-public camlp4
;; This is a home-made 'configure' script. ;; This is a home-made 'configure' script.
(let ((out (assoc-ref outputs "out"))) (let ((out (assoc-ref outputs "out")))
(zero? (system* "./configure" (zero? (system* "./configure"
(string-append "--libdir=" out "/lib") (string-append "--libdir=" out
"/lib/ocaml/site-lib")
(string-append "--bindir=" out "/bin") (string-append "--bindir=" out "/bin")
(string-append "--pkgdir=" out))))))))) (string-append "--pkgdir=" out
"/lib/ocaml/site-lib"))))))
(add-after 'install 'install-meta
(lambda* (#:key outputs #:allow-other-keys)
(let ((out (assoc-ref outputs "out")))
(substitute* "camlp4/META.in"
(("directory = .*")
(string-append "directory = \"" out
"/lib/ocaml/site-lib/camlp4\"\n")))
(zero? (system* "make" "install-META"))))))))
(home-page "https://github.com/ocaml/camlp4") (home-page "https://github.com/ocaml/camlp4")
(synopsis "Write parsers in OCaml") (synopsis "Write parsers in OCaml")
(description (description
@ -726,7 +736,12 @@ (define-public ocaml-findlib
"-config" (string-append out "/etc/ocamfind.conf") "-config" (string-append out "/etc/ocamfind.conf")
"-mandir" (string-append out "/share/man") "-mandir" (string-append out "/share/man")
"-sitelib" (string-append out "/lib/ocaml/site-lib") "-sitelib" (string-append out "/lib/ocaml/site-lib")
"-with-toolbox"))))))) "-with-toolbox"))))
(add-after 'install 'remove-camlp4
(lambda* (#:key outputs #:allow-other-keys)
(let ((out (assoc-ref outputs "out")))
(delete-file-recursively
(string-append out "/lib/ocaml/site-lib/camlp4"))))))))
(home-page "http://projects.camlcity.org/projects/findlib.html") (home-page "http://projects.camlcity.org/projects/findlib.html")
(synopsis "Management tool for OCaml libraries") (synopsis "Management tool for OCaml libraries")
(description (description