diff options
author | Julien Lepiller <julien@lepiller.eu> | 2021-11-20 03:05:18 +0100 |
---|---|---|
committer | Julien Lepiller <julien@lepiller.eu> | 2021-11-20 03:48:28 +0100 |
commit | 42eeea188d03e5c9943d653ec0afa6ff0ae2a9ad (patch) | |
tree | 8ce990c9adcda6e2b852523dc52b5aef7ca937a4 /gnu | |
parent | 32cecfa057b11969c60c2d41e79b17ce74e80d12 (diff) | |
download | guix-42eeea188d03e5c9943d653ec0afa6ff0ae2a9ad.tar guix-42eeea188d03e5c9943d653ec0afa6ff0ae2a9ad.tar.gz |
gnu: ocaml-frontc: Update to 4.1.0.
* gnu/packages/ocaml.scm (ocaml-frontc): Update to 4.1.0.
(ocaml4.07-frontc): New variable.
Diffstat (limited to 'gnu')
-rw-r--r-- | gnu/packages/ocaml.scm | 80 |
1 files changed, 54 insertions, 26 deletions
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm index 23b022984d..a15842a8b6 100644 --- a/gnu/packages/ocaml.scm +++ b/gnu/packages/ocaml.scm @@ -1478,41 +1478,29 @@ for speed and space economy.") (define-public ocaml-frontc (package (name "ocaml-frontc") - (version "3.4.2") + (version "4.1.0") (source (origin (method git-fetch) (uri (git-reference (url "https://github.com/BinaryAnalysisPlatform/FrontC") - (commit (string-append - "V_" (string-join (string-split version #\.) "_"))))) + (commit (string-append "v" version)))) (file-name (git-file-name name version)) (sha256 (base32 - "0k7jk9hkglnkk27s62xl493jyqc017gyvwqb1lyc0ywbb001s102")))) - (build-system ocaml-build-system) + "1mi1vh4qgscnb470qwidccaqd068j1bqlz6pf6wddk21paliwnqb")))) + (build-system dune-build-system) (arguments - `(#:phases + `(#:test-target "test.t" + #:phases (modify-phases %standard-phases - (delete 'configure) - (add-after 'install 'install-meta - (lambda* (#:key outputs #:allow-other-keys) - (let ((out (assoc-ref outputs "out"))) - (with-output-to-file - (string-append out "/lib/ocaml/frontc/META") - (lambda _ - (display - (string-append - "description = \"Parser for the C language\" -version = \"" ,version "\" -requires = \"unix\" -archive(byte) = \"frontc.cma\" -archive(native) = \"frontc.cmxa\"")))) - (symlink (string-append out "/lib/ocaml/frontc") - (string-append out "/lib/ocaml/FrontC")))))) - #:make-flags (list (string-append "PREFIX=" - (assoc-ref %outputs "out")) - "OCAML_SITE=$(LIB_DIR)/ocaml/"))) - (properties `((upstream-name . "FrontC"))) + (add-after 'unpack 'make-writable + (lambda _ + (for-each make-file-writable (find-files "." "."))))))) + (native-inputs + `(("ocaml-menhir" ,ocaml-menhir) + ("ocaml-odoc" ,ocaml-odoc))) + (properties `((upstream-name . "FrontC") + (ocaml4.07-variant . ,(delay ocaml4.07-frontc)))) (home-page "https://www.irit.fr/FrontC") (synopsis "C parser and lexer library") (description "FrontC is an OCAML library providing a C parser and lexer. @@ -1521,6 +1509,46 @@ It provides support for ANSI C syntax, old-C K&R style syntax and the standard GNU CC attributes. It provides also a C pretty printer as an example of use.") (license license:lgpl2.1))) +(define-public ocaml4.07-frontc + (package-with-ocaml4.07 + (package + (inherit ocaml-frontc) + (version "3.4.2") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/mirage/ocaml-base64") + (commit (string-append + "V_" (string-join (string-split version #\.) "_"))))) + (file-name (git-file-name "ocaml-frontc" version)) + (sha256 + (base32 + "0k7jk9hkglnkk27s62xl493jyqc017gyvwqb1lyc0ywbb001s102")))) + (build-system ocaml-build-system) + (arguments + `(#:phases + (modify-phases %standard-phases + (delete 'configure) + (add-after 'install 'install-meta + (lambda* (#:key outputs #:allow-other-keys) + (let ((out (assoc-ref outputs "out"))) + (with-output-to-file + (string-append out "/lib/ocaml/frontc/META") + (lambda _ + (display + (string-append + "description = \"Parser for the C language\" +version = \"" ,version "\" +requires = \"unix\" +archive(byte) = \"frontc.cma\" +archive(native) = \"frontc.cmxa\"")))) + (symlink (string-append out "/lib/ocaml/frontc") + (string-append out "/lib/ocaml/FrontC")))))) + #:make-flags (list (string-append "PREFIX=" + (assoc-ref %outputs "out")) + "OCAML_SITE=$(LIB_DIR)/ocaml/"))) + (properties '())))) + (define-public ocaml-qcheck (package (name "ocaml-qcheck") |