[PATCH] Remove ocaml-4.02

  • Done
  • quality assurance status badge
Details
One participant
  • Julien Lepiller
Owner
unassigned
Submitted by
Julien Lepiller
Severity
normal
J
J
Julien Lepiller wrote on 14 Apr 2019 22:25
(address . guix-patches@gnu.org)
20190414222536.704eea02@sybil.lepiller.eu
Hi!

This patch series removes ocaml-4.02 and dependent packages. I updated
bap to 1.6.0 (so it can build with the latest ocaml) and downgraded
ocamlify for the same reason. I removed the obsolete jbuilder and
adapted two dependents.

Thanks!
J
J
Julien Lepiller wrote on 14 Apr 2019 22:32
[PATCH 1/5] gnu: Add ocaml-bigarray-compat.
(address . 35280@debbugs.gnu.org)
20190414203205.8104-1-julien@lepiller.eu
* gnu/packages/ocaml.scm (ocaml-bigarray-compat): New variable.
---
gnu/packages/ocaml.scm | 22 ++++++++++++++++++++++
1 file changed, 22 insertions(+)

Toggle diff (35 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index 0190c3937a..92489ba52d 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -859,6 +859,28 @@ Knuth’s LR(1) parser construction technique.")
(inputs `(("ocaml" ,ocaml-4.02)))
(native-inputs '())))
+(define-public ocaml-bigarray-compat
+ (package
+ (name "ocaml-bigarray-compat")
+ (version "1.0.0")
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/mirage/bigarray-compat")
+ (commit (string-append "v" version))))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "06j1dwlpisxshdd0nab4n4x266gg1s1n8na16lpgw3fvcznwnimz"))))
+ (build-system dune-build-system)
+ (arguments
+ `(#:tests? #f)); no tests
+ (home-page "https://github.com/mirage/bigarray-compat")
+ (synopsis "OCaml compatibility library")
+ (description "This package contains a compatibility library for
+@code{Stdlib.Bigarray} in OCaml.")
+ (license license:isc)))
+
(define-public lablgtk
(package
(name "lablgtk")
--
2.21.0
J
J
Julien Lepiller wrote on 14 Apr 2019 22:32
[PATCH 2/5] gnu: bap: Update to 1.6.0.
(address . 35280@debbugs.gnu.org)
20190414203205.8104-2-julien@lepiller.eu
* gnu/packages/ocaml.scm (bap): Update to 1.6.0.
(ocaml-frontc): Update to 3.4.1.
(ocaml-fileutils, ocaml-cstruct, ocaml-hex, ocaml-ezjsonm, ocaml-uri):
New variables.
(ocaml4.02-fileutils, ocaml4.02-cstruct, ocaml4.02-hex,
ocaml4.02-ezjsonm, ocaml4.02-uri): Remove variables.
---
gnu/packages/ocaml.scm | 215 ++++++++++++++++++-----------------------
1 file changed, 95 insertions(+), 120 deletions(-)

Toggle diff (335 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index 92489ba52d..18c2531658 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -1247,19 +1247,20 @@ for speed and space economy.")
(define-public ocaml-frontc
(package
(name "ocaml-frontc")
- (version "3.4")
+ (version "3.4.1")
(source (origin
- (method url-fetch)
- (uri (string-append "https://www.irit.fr/recherches/ARCHI/MARCH/"
- "frontc/Frontc-" version ".tgz"))
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/BinaryAnalysisPlatform/FrontC")
+ (commit (string-append
+ "V_" (string-join (string-split version #\.) "_")))))
+ (file-name (git-file-name name version))
(sha256
(base32
- "16dz153s92dgbw1rrfwbhscy73did87kfmjwyh3qpvs748h1sc4g"))))
+ "1dq5nks0c9gsbr1m8k39m1bniawr5hqcy1r8x5px7naa95ch06ak"))))
(build-system ocaml-build-system)
(arguments
- `(#:ocaml ,ocaml-4.02
- #:findlib ,ocaml4.02-findlib
- #:phases
+ `(#:phases
(modify-phases %standard-phases
(delete 'configure)
(add-after 'install 'install-meta
@@ -2712,9 +2713,9 @@ language.")
can match the question using a regular expression or a timeout.")
(license license:lgpl2.1+))) ; with the OCaml static compilation exception
-(define-public ocaml4.02-fileutils
+(define-public ocaml-fileutils
(package
- (name "ocaml4.02-fileutils")
+ (name "ocaml-fileutils")
(version "0.5.3")
(source (origin
(method url-fetch)
@@ -2723,11 +2724,9 @@ can match the question using a regular expression or a timeout.")
(base32
"1rc4cqlvdhbs55i85zfbfhz938fsy4fj6kwlkfm3ra7bpwn8bmpd"))))
(build-system ocaml-build-system)
- (arguments
- `(#:ocaml ,ocaml-4.02
- #:findlib ,ocaml4.02-findlib))
(native-inputs
- `(("ounit" ,ocaml4.02-ounit)))
+ `(("ocamlbuild" ,ocamlbuild)
+ ("ounit" ,ocaml-ounit)))
(home-page "http://ocaml-fileutils.forge.ocamlcore.org")
(synopsis "Pure OCaml functions to manipulate real file and filename")
(description "Library to provide pure OCaml functions to manipulate real
@@ -3896,43 +3895,24 @@ big- and little-endian, with their unsafe counter-parts.")
(define-public ocaml4.02-ocplib-endian
(package-with-ocaml4.02 ocaml-ocplib-endian))
-(define-public ocaml4.02-cstruct
+(define-public ocaml-cstruct
(package
- (name "ocaml4.02-cstruct")
- (version "2.3.1")
+ (name "ocaml-cstruct")
+ (version "4.0.0")
(source (origin
- (method url-fetch)
- (uri (string-append "https://github.com/mirage/ocaml-cstruct/"
- "archive/v" version ".tar.gz"))
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/mirage/ocaml-cstruct")
+ (commit (string-append "v" version))))
(sha256
(base32
- "15qpdc8421shq4pprdas9jznpva45229wkfqbwcxw9khaiiz7949"))
- (file-name (string-append name "-" version ".tar.gz"))))
- (build-system ocaml-build-system)
+ "0m4bz0digcsc8l2msfikwcbi1y371kccx6xnkwrz212mf5mp98bv"))))
+ (build-system dune-build-system)
(arguments
- `(#:ocaml ,ocaml-4.02
- #:findlib ,ocaml4.02-findlib
- #:configure-flags
- (list "--enable-lwt" "--enable-async")
- #:phases
- (modify-phases %standard-phases
- (add-after 'install 'link-stubs
- (lambda* (#:key outputs #:allow-other-keys)
- (let* ((out (assoc-ref outputs "out"))
- (stubs (string-append out "/lib/ocaml/site-lib/stubslibs"))
- (lib (string-append out "/lib/ocaml/site-lib/cstruct")))
- (mkdir-p stubs)
- (symlink (string-append lib "/dllcstruct_stubs.so")
- (string-append stubs "/dllcstruct_stubs.so"))))))))
+ `(#:package "cstruct"
+ #:test-target "."))
(native-inputs
- `(("ounit" ,ocaml4.02-ounit)
- ("ppx-tools" ,ocaml4.02-ppx-tools)
- ("camlp4" ,camlp4-4.02)))
- (propagated-inputs
- `(("ocplib-endian" ,ocaml4.02-ocplib-endian)
- ("lwt" ,ocaml4.02-lwt)
- ("async" ,ocaml4.02-async)
- ("sexplib" ,ocaml4.02-sexplib)))
+ `(("ocaml-alcotest" ,ocaml-alcotest)))
(home-page "https://github.com/mirage/ocaml-cstruct")
(synopsis "Access C structures via a camlp4 extension")
(description "Cstruct is a library and syntax extension to make it easier
@@ -3940,33 +3920,34 @@ to access C-like structures directly from OCaml. It supports both reading and
writing to these structures, and they are accessed via the Bigarray module.")
(license license:isc)))
-(define-public ocaml4.02-hex
+(define-public ocaml-hex
(package
- (name "ocaml4.02-hex")
- (version "1.0.0")
+ (name "ocaml-hex")
+ (version "1.4.0")
(source (origin
- (method url-fetch)
- (uri (string-append "https://github.com/mirage/ocaml-hex/"
- "archive/" version ".tar.gz"))
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/mirage/ocaml-hex")
+ (commit (string-append "v" version))))
+ (file-name (git-file-name name version))
(sha256
(base32
- "0s63g0b8gfv2xm6fv6xg7bva8h76b5pcjb0zw3f8cygs0lq9072v"))
- (file-name (string-append name "-" version ".tar.gz"))))
- (build-system ocaml-build-system)
+ "0c8nhibcwy0ykzca4jn3gqb8ylq21ff88y82gl60wyzijr64rn0q"))))
+ (build-system dune-build-system)
(arguments
- `(#:ocaml ,ocaml-4.02
- #:findlib ,ocaml4.02-findlib))
+ `(#:test-target "."))
(propagated-inputs
- `(("cstruct" ,ocaml4.02-cstruct)))
+ `(("ocaml-bigarray-compat" ,ocaml-bigarray-compat)
+ ("cstruct" ,ocaml-cstruct)))
(home-page "https://github.com/mirage/ocaml-hex/")
(synopsis "Minimal library providing hexadecimal converters")
(description "Hex is a minimal library providing hexadecimal converters.")
(license license:isc)))
-(define-public ocaml4.02-ezjsonm
+(define-public ocaml-ezjsonm
(package
- (name "ocaml4.02-ezjsonm")
- (version "0.4.3")
+ (name "ocaml-ezjsonm")
+ (version "1.0.0")
(source
(origin
(method git-fetch)
@@ -3975,19 +3956,17 @@ writing to these structures, and they are accessed via the Bigarray module.")
(commit (string-append "v" version))))
(file-name (git-file-name name version))
(sha256
- (base32 "1y6p3ga6vj1wx5dyns7hjgd0qgrrn2hnn323a7y5didgci5pybls"))))
- (build-system ocaml-build-system)
+ (base32 "1dzjqrj7nl15ij921r7439fp0m7jrl3vskkdqb4syihjvsbvq1sj"))))
+ (build-system dune-build-system)
+ (arguments
+ `(#:package "ezjsonm"
+ #:test-target "."))
(native-inputs
- `(("alcotest" ,ocaml4.02-alcotest)))
+ `(("ocaml-alcotest" ,ocaml-alcotest)))
(propagated-inputs
- `(("hex" ,ocaml4.02-hex)
- ("jsonm" ,ocaml4.02-jsonm)
- ("lwt" ,ocaml4.02-lwt)
- ("sexplib" ,ocaml4.02-sexplib)))
- (arguments
- `(#:configure-flags (list "--enable-lwt")
- #:ocaml ,ocaml-4.02
- #:findlib ,ocaml4.02-findlib))
+ `(("ocaml-hex" ,ocaml-hex)
+ ("ocaml-jsonm" ,ocaml-jsonm)
+ ("ocaml-sexplib" ,ocaml-sexplib)))
(home-page "https://github.com/mirage/ezjsonm/")
(synopsis "Read and write JSON data")
(description "Ezjsonm provides more convenient (but far less flexible) input
@@ -3996,10 +3975,10 @@ the need to write signal code, which is useful for quick scripts that manipulate
JSON.")
(license license:isc)))
-(define-public ocaml4.02-uri
+(define-public ocaml-uri
(package
- (name "ocaml4.02-uri")
- (version "1.9.2")
+ (name "ocaml-uri")
+ (version "2.2.0")
(source
(origin
(method git-fetch)
@@ -4008,19 +3987,17 @@ JSON.")
(commit (string-append "v" version))))
(file-name (git-file-name name version))
(sha256
- (base32 "137pg8j654x7r0d1664iy2zp3l82nki1kkh921lwdrwc5qqdl6jx"))))
- (build-system ocaml-build-system)
+ (base32 "1ppbav41mszpjcl0zi3fyg958cxyfs57i7kvha4ds9ydn89bjmrh"))))
+ (build-system dune-build-system)
(arguments
- `(#:ocaml ,ocaml-4.02
- #:findlib ,ocaml4.02-findlib))
+ `(#:test-target "."))
(native-inputs
- `(("ounit" ,ocaml4.02-ounit)))
+ `(("ocaml-ounit" ,ocaml-ounit)
+ ("ocaml-ppx-sexp-conv" ,ocaml-ppx-sexp-conv)))
(propagated-inputs
- `(("ppx-sexp-conv" ,ocaml4.02-ppx-sexp-conv)
- ("re" ,ocaml4.02-re)
- ("ppx-deriving" ,ocaml4.02-ppx-deriving)
- ("sexplib" ,ocaml4.02-sexplib)
- ("stringext" ,ocaml4.02-stringext)))
+ `(("ocaml-re" ,ocaml-re)
+ ("ocaml-sexplib0" ,ocaml-sexplib0)
+ ("ocaml-stringext" ,ocaml-stringext)))
(home-page "https://github.com/mirage/ocaml-uri")
(synopsis "RFC3986 URI/URL parsing library")
(description "OCaml-uri is a library for parsing URI/URL in the RFC3986 format.")
@@ -4258,50 +4235,52 @@ XML and Protocol Buffers formats.")
(define-public bap
(package
(name "bap")
- (version "1.3.0")
+ (version "1.6.0")
(home-page "https://github.com/BinaryAnalysisPlatform/bap")
(source (origin
- (method url-fetch)
- (uri (string-append home-page "/archive/v" version ".tar.gz"))
+ (method git-fetch)
+ (uri (git-reference
+ (url home-page)
+ (commit (string-append "v" version))))
+ (file-name (git-file-name name version))
(sha256
(base32
- "0v95v9mp7mg8fj25ry0w7566zd9xp6cs8nnqj4l38q54fb1hfav9"))
- (file-name (string-append name "-" version ".tar.gz"))))
+ "0ryf2xb37pj2f9mc3p5prqgqrylph9qgq7q9jnbx8b03nzzpa6h6"))))
(build-system ocaml-build-system)
(native-inputs
- `(("oasis" ,ocaml4.02-oasis)
+ `(("ocaml-oasis" ,ocaml-oasis)
("clang" ,clang-3.8)
- ("ounit" ,ocaml4.02-ounit)))
+ ("ocaml-ounit" ,ocaml-ounit)))
(propagated-inputs
- `(("core-kernel" ,ocaml4.02-core-kernel)
- ("ppx-driver" ,ocaml4.02-ppx-driver)
- ("bin-prot" ,ocaml4.02-bin-prot)
- ("uri" ,ocaml4.02-uri)
- ("llvm" ,llvm-3.8)
- ("gmp" ,gmp)
- ("clang-runtime" ,clang-runtime)
- ("fileutils" ,ocaml4.02-fileutils)
- ("cmdliner" ,ocaml4.02-cmdliner)
- ("zarith" ,ocaml4.02-zarith)
- ("uuidm" ,ocaml4.02-uuidm)
- ("camlzip" ,ocaml4.02-camlzip)
- ("frontc" ,ocaml-frontc)
- ("ezjsonm" ,ocaml4.02-ezjsonm)
- ("ocurl" ,ocaml4.02-ocurl)
- ("piqi" ,ocaml4.02-piqi)
- ("ocamlgraph" ,ocaml4.02-graph)
- ("bitstring" ,ocaml4.02-bitstring)
- ("ppx-jane" ,ocaml4.02-ppx-jane)
- ("re" ,ocaml4.02-re)))
- (inputs `(("llvm" ,llvm-3.8)))
+ `(("camlzip" ,camlzip)
+ ("ocaml-bitstring" ,ocaml-bitstring)
+ ("ocaml-cmdliner" ,ocaml-cmdliner)
+ ("ocaml-core-kernel" ,ocaml-core-kernel)
+ ("ocaml-ezjsonm" ,ocaml-ezjsonm)
+ ("ocaml-fileutils" ,ocaml-fileutils)
+ ("ocaml-frontc" ,ocaml-frontc)
+ ("ocaml-graph" ,ocaml-graph)
+ ("ocaml-ocurl" ,ocaml-ocurl)
+ ("ocaml-piqi" ,ocaml-piqi)
+ ("ocaml-ppx-jane" ,ocaml-ppx-jane)
+ ("ocaml-uuidm" ,ocaml-uuidm)
+ ("ocaml-uri" ,ocaml-uri)
+ ("ocaml-zarith" ,ocaml-zarith)))
+ (inputs
+ `(("llvm" ,llvm-3.8)
+ ("gmp" ,gmp)))
(arguments
- `(#:ocaml ,ocaml-4.02
- #:findlib ,ocaml4.02-findlib
- #:use-make? #t
+ `(#:use-make? #t
#:phases
(modify-phases %standard-phases
(replace 'configure
(lambda* (#:key outputs inputs #:allow-other-keys)
+ ;; add write for user, to prevent a failure in the install phase
+ (for-each
+ (lambda (file)
+ (let ((stat (stat file)))
+ (chmod file (+ #o200 (stat:mode stat)))))
+ (find-files "." "."))
(invoke "./configure" "--prefix"
(assoc-ref outputs "out")
"--libdir"
@@ -4310,11 +4289,7 @@ XML and Protocol Buffers formats.")
"/lib/ocaml/site-lib")
"--with-llvm-version=3.8"
"--with-llvm-config=llvm-config"
- "--enable-everything")
- (substitute* "plugins/objdump/objdump_main.ml"
- (("Re_perl") "Re.Perl"))
- (substitute* "oasis/objdump"
- (("re.pcre") "re.pcre, re.perl")))))))
+ "--enable-everything"))))))
(synopsis "Binary Analysis Platform")
(description "Binary Analysis Platform is a framework for writing program
analysis tools, that target binary files. The framework consists of a plethora
--
2.21.0
J
J
Julien Lepiller wrote on 14 Apr 2019 22:32
[PATCH 3/5] gnu: Remove ocaml-jbuilder.
(address . 35280@debbugs.gnu.org)
20190414203205.8104-3-julien@lepiller.eu
Jbuilder is deprecated and replaced by dune.

* gnu/packages/ocaml.scm (ocaml-jbuilder): Remove variable.
(ocaml-zed, ocaml-utop): Use dune-build-system.
---
gnu/packages/ocaml.scm | 75 +++++-------------------------------------
1 file changed, 8 insertions(+), 67 deletions(-)

Toggle diff (106 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index 18c2531658..252d9b8496 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -4326,42 +4326,6 @@ library is currently designed for Unicode Standard 3.2.")
(define-public ocaml4.02-camomile
(package-with-ocaml4.02 ocaml-camomile))
-(define-public ocaml-jbuilder
- (package
- (name "ocaml-jbuilder")
- (version "1.0+beta16")
- (source
- (origin
- (method git-fetch)
- (uri (git-reference
- (url "https://github.com/janestreet/jbuilder.git")
- (commit version)))
- (file-name (git-file-name name version))
- (sha256
- (base32 "1y3fgf570w3vrnhianrg26jy5j749zczq3f78s2dy5ylbp1hrx71"))))
- (build-system ocaml-build-system)
- (arguments
- `(#:ocaml ,ocaml-4.02
- #:findlib ,ocaml4.02-findlib
- #:phases
- (modify-phases %standard-phases
- (replace 'configure
- (lambda* (#:key outputs #:allow-other-keys)
- (let ((out (assoc-ref outputs "out")))
- (setenv "PREFIX" out))
- #t)))))
- (native-inputs
- `(("menhir" ,ocaml4.02-menhir)))
- (propagated-inputs
- `(("opam" ,opam)))
- (home-page "https://github.com/janestreet/jbuilder")
- (synopsis "Composable build system for OCaml")
- (description "Jbuilder is a build system designed for OCaml/Reason projects
-only. It focuses on providing the user with a consistent experience and takes
-care of most of the low-level details of OCaml compilation. All you have to do
-is provide a description of your project and Jbuilder will do the rest.")
- (license license:asl2.0)))
-
(define-public ocaml-zed
(package
(name "ocaml-zed")
@@ -4375,20 +4339,10 @@ is provide a description of your project and Jbuilder will do the rest.")
(file-name (git-file-name name version))
(sha256
(base32 "00hhxcjf3bj3w2qm8nzs9x6vrqkadf4i0277s5whzy2rmiknj63v"))))
- (build-system ocaml-build-system)
+ (build-system dune-build-system)
(arguments
- `(#:phases
- (modify-phases %standard-phases
- (delete 'configure)
- (replace 'build
- (lambda _ (invoke "jbuilder" "build")))
- (delete 'check)
- (replace 'install
- (lambda* (#:key outputs #:allow-other-keys)
- (let ((out (assoc-ref outputs "out")))
- (invoke "jbuilder" "install" "--prefix" out)))))))
- (native-inputs
- `(("jbuilder" ,ocaml-jbuilder)))
+ `(#:jbuild? #t
+ #:test-target "."))
(propagated-inputs
`(("camomile" ,ocaml-camomile)
("react" ,ocaml-react)))
@@ -4449,27 +4403,14 @@ instead of bindings to a C library.")
(file-name (git-file-name name version))
(sha256
(base32 "02hjkc0rdzfq3bqy9mqm5wmw312r3187v9cl66ynb6hxkj6s3glb"))))
- (build-system gnu-build-system)
+ (build-system dune-build-system)
(arguments
- `(#:test-target "test"
- #:phases
- (modify-phases %standard-phases
- (delete 'configure)
- (replace 'install
- (lambda* (#:key outputs #:allow-other-keys)
- (let* ((out (assoc-ref outputs "out"))
- (libdir (string-append out "/lib/ocaml/site-lib")))
- (mkdir-p libdir)
- (invoke "jbuilder" "install"
- "--prefix" out
- "--libdir" libdir)))))))
+ `(#:jbuild? #t
+ #:test-target "."))
(native-inputs
- `(("ocaml" ,ocaml)
- ("cppo" ,ocaml-cppo)
- ("jbuilder" ,ocaml-jbuilder)))
+ `(("cppo" ,ocaml-cppo)))
(propagated-inputs
- `(("ocaml-findlib" ,ocaml-findlib)
- ("lambda-term" ,ocaml-lambda-term)
+ `(("lambda-term" ,ocaml-lambda-term)
("lwt" ,ocaml-lwt)
("react" ,ocaml-react)
("camomile" ,ocaml-camomile)
--
2.21.0
J
J
Julien Lepiller wrote on 14 Apr 2019 22:32
[PATCH 4/5] gnu: ocamlify: Downgrade to 0.0.1.
(address . 35280@debbugs.gnu.org)
20190414203205.8104-4-julien@lepiller.eu
Version 0.0.2 cannot be built with the latest OCaml, whereas this
version does. This is also the version used by opam.

* gnu/packages/ocaml.scm (ocamlify): Downgrade to 0.0.1.
[arguments]: Do not use ocaml-4.02.
---
gnu/packages/ocaml.scm | 18 +++++++++++-------
1 file changed, 11 insertions(+), 7 deletions(-)

Toggle diff (39 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index 252d9b8496..b750dbe9f4 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -2500,21 +2500,25 @@ radix-64 representation. It is specified in RFC 4648.")
(define-public ocamlify
(package
(name "ocamlify")
- (version "0.0.2")
+ (version "0.0.1")
(source (origin
(method url-fetch)
- (uri (ocaml-forge-uri name version 1209))
+ (uri "https://download.ocamlcore.org/ocamlify/ocamlify/0.0.1/ocamlify-0.0.1.tar.gz")
(sha256
(base32
- "1f0fghvlbfryf5h3j4as7vcqrgfjb4c8abl5y0y5h069vs4kp5ii"))))
+ "1j9nb3vjqbdsx3d6jazixgrh776051zkrc06nsc5q5ilp1jhrwkm"))))
(build-system ocaml-build-system)
; tests are done during build
(arguments
- `(#:ocaml ,ocaml-4.02
- #:findlib ,ocaml4.02-findlib
- #:phases
+ `(#:phases
(modify-phases %standard-phases
- (delete 'check))))
+ (delete 'check)
+ (replace 'configure
+ (lambda* (#:key outputs #:allow-other-keys)
+ (invoke "ocaml" "setup.ml" "-configure" "--prefix"
+ (assoc-ref outputs "out")))))))
+ (native-inputs
+ `(("ocamlbuild" ,ocamlbuild)))
(home-page "https://forge.ocamlcore.org/projects/ocamlify")
(synopsis "Include files in OCaml code")
(description "OCamlify allows to create OCaml source code by including
--
2.21.0
J
J
Julien Lepiller wrote on 14 Apr 2019 22:32
[PATCH 5/5] gnu: ocaml@4.02: Remove the package, affected by a CVE, and its dependent packages.
(address . 35280@debbugs.gnu.org)
20190414203205.8104-5-julien@lepiller.eu

* gnu/packages/ocaml.scm (ocaml-4.02, camlp4-4.02, ocaml4.02-menhir)
(ocaml4.02-lablgtk, ocaml4.02-findlib, ocaml4.02-ounit)
(ocaml4.02-camlzip, ocaml4.02-ocamlmod, ocaml4.02-zarith)
(ocaml4.02-qcheck, ocaml4.02-qtest, ocaml4.02-stringext)
(ocaml4.02-bisect, ocaml4.02-bitstring, ocaml4.02-result)
(ocaml4.02-topkg, ocaml4.02-rresult, ocaml4.02-sqlite3, ocaml4.02-csv)
(ocaml4.02-mtime, ocaml4.02-cmdliner, ocaml4.02-fmt, ocaml4.02-astring)
(ocaml4.02-alcotest, ocaml4.02-ppx-tools, ocaml4.02-react, ocaml4.02-ssl)
(ocaml4.02-lwt, ocaml4.02-lwt-log, ocaml4.02-logs, ocaml4.02-fpath)
(ocaml4.02-bos, ocaml4.02-xmlm, ocaml4.02-ulex, ocaml4.02-uchar)
(ocaml4.02-uutf, ocaml4.02-jsonm, ocaml4.02-ocurl, ocaml4.02-base64)
(ocaml4.02-omake, ocaml4.02-batteries, ocaml4.02-pcre, ocaml4.02-oasis)
(ocaml4.02-js-build-tools, ocaml4.02-bin-prot, ocaml4.02-fieldslib)
(ocaml4.02-ppx-core, ocaml4.02-ppx-optcomp, ocaml4.02-ppx-driver)
(ocaml4.02-cppo, ocaml4.02-ppx-deriving, ocaml4.02-ppx-type-conv)
(ocaml4.02-ppx-inline-test, ocaml4.02-ppx-bench, ocaml4.02-ppx-compare)
(ocaml4.02-sexplib, ocaml4.02-typerep, ocaml4.02-variantslib)
(ocaml4.02-ppx-sexp-conv, ocaml4.02-ppx-variants-conv)
(ocaml4.02-ppx-here, ocaml4.02-ppx-assert, ocaml4.02-ppx-enumerate)
(ocaml4.02-ppx-let, ocaml4.02-ppx-typerep-conv, ocaml4.02-ppx-sexp-value)
(ocaml4.02-ppx-pipebang, ocaml4.02-ppx-bin-prot, ocaml4.02-ppx-fail)
(ocaml4.02-ppx-custom-printf, ocaml4.02-ppx-sexp-message)
(ocaml4.02-ppx-fields-conv, ocaml4.02-seq, ocaml4.02-re)
(ocaml4.02-ppx-expect, ocaml4.02-ppx-jane, ocaml4.02-core-kernel)
(ocaml4.02-async-kernel, ocaml4.02-async-rpc-kernel, ocaml4.02-core)
(ocaml4.02-async-unix, ocaml4.02-async-extra, ocaml4.02-async)
(ocaml4.02-ocplib-endian, ocaml4.02-easy-format, optcomp)
(ocaml4.02-piqilib, ocaml4.02-uuidm, ocaml4.02-graph, ocaml4.02-piqi)
(ocaml4.02-camomile, ocaml4.02-zed, ocaml4.02-lambda-term): Remove variables.
* guix/build-system/ocaml.scm (default-ocaml4.02)
(default-ocaml4.02-findlib, package-with-ocaml4.02)
(strip-ocaml4.02-variant): Remove variables.
---
gnu/packages/ocaml.scm | 1410 +----------------------------------
guix/build-system/ocaml.scm | 22 -
2 files changed, 20 insertions(+), 1412 deletions(-)

Toggle diff (490 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index b750dbe9f4..51435b2155 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -129,10 +129,10 @@
"/lib/ocaml/site-lib"))
#:phases (modify-phases %standard-phases (delete 'configure))))
-(define-public ocaml-4.02
+(define-public ocaml-4.07
(package
(name "ocaml")
- (version "4.02.3")
+ (version "4.07.1")
(source (origin
(method url-fetch)
(uri (string-append
@@ -141,12 +141,7 @@
"/ocaml-" version ".tar.xz"))
(sha256
(base32
- "1qwwvy8nzd87hk8rd9sm667nppakiapnx4ypdwcrlnav2dz6kil3"))
- (patches
- (search-patches
- "ocaml-CVE-2015-8869.patch"
- "ocaml-Add-a-.file-directive.patch"
- "ocaml-enable-ocamldoc-reproducibility.patch"))))
+ "1f07hgj5k45cylj1q3k5mk8yi02cwzx849b1fwnwia8xlcfqpr6z"))))
(build-system gnu-build-system)
(native-search-paths
(list (search-path-specification
@@ -204,25 +199,7 @@ patch-/bin/sh-references: ~a: changing `\"/bin/sh\"' to `~a'~%"
(add-after 'install 'check
(lambda _
(with-directory-excursion "testsuite"
- (invoke "make" "all"))))
- (add-before 'check 'prepare-socket-test
- (lambda _
- (format (current-error-port)
- "Spawning local test web server on port 8080~%")
- (when (zero? (primitive-fork))
- (run-server (lambda (request request-body)
- (values '((content-type . (text/plain)))
- "Hello!"))
- 'http '(#:port 8080)))
- (let ((file "testsuite/tests/lib-threads/testsocket.ml"))
- (format (current-error-port)
- "Patching ~a to use localhost port 8080~%"
- file)
- (substitute* file
- (("caml.inria.fr") "localhost")
- (("80") "8080")
- (("HTTP1.0") "HTTP/1.0"))
- #t))))))
+ (invoke "make" "all")))))))
(home-page "https://ocaml.org/")
(synopsis "The OCaml programming language")
(description
@@ -235,30 +212,6 @@ functional, imperative and object-oriented styles of programming.")
;; distributed under lgpl2.0.
(license (list license:qpl license:lgpl2.0))))
-(define-public ocaml-4.07
- (package
- (inherit ocaml-4.02)
- (version "4.07.1")
- (source (origin
- (method url-fetch)
- (uri (string-append
- "http://caml.inria.fr/pub/distrib/ocaml-"
- (version-major+minor version)
- "/ocaml-" version ".tar.xz"))
- (sha256
- (base32
- "1f07hgj5k45cylj1q3k5mk8yi02cwzx849b1fwnwia8xlcfqpr6z"))))
- (arguments
- (substitute-keyword-arguments (package-arguments ocaml-4.02)
- ((#:phases phases)
- `(modify-phases ,phases
- (delete 'prepare-socket-test)
- (replace 'check
- (lambda _
- (with-directory-excursion "testsuite"
- (invoke "make" "all"))
- #t))))))))
-
(define-public ocaml ocaml-4.07)
(define-public ocamlbuild
@@ -560,23 +513,25 @@ Git-friendly development workflow.")
;; The 'LICENSE' file waives some requirements compared to LGPLv3.
(license license:lgpl3)))
-(define-public camlp4-4.02
+(define-public camlp4-4.07
(package
(name "camlp4")
- (version "4.02+6")
- (source
- (origin
- (method git-fetch)
- (uri (git-reference
- (url "https://github.com/ocaml/camlp4.git")
- (commit version)))
- (file-name (git-file-name name version))
- (sha256
- (base32 "06yl4q0qazl7g25b0axd1gdkfd4qpqzs1gr5fkvmkrcbz113h1hj"))))
+ (version "4.07+1")
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/ocaml/camlp4.git")
+ (commit version)))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "0cxl4hkqcvspvkx4f2k83217rh6051fll9i2yz7cw6m3bq57mdvl"))))
(build-system gnu-build-system)
- (native-inputs `(("ocaml" ,ocaml-4.02)
- ("which" ,which)))
- (inputs `(("ocaml" ,ocaml-4.02)))
+ (native-inputs
+ `(("ocaml" ,ocaml-4.07)
+ ("ocamlbuild" ,ocamlbuild)
+ ("which" ,which)))
+ (inputs `(("ocaml" ,ocaml-4.07)))
(arguments
'(#:tests? #f ;no documented test target
;; a race-condition will lead byte and native targets to mkdir _build
@@ -617,28 +572,6 @@ syntax of OCaml.")
;; against the library to be released under any terms.
(license license:lgpl2.0)))
-(define-public camlp4-4.07
- (package
- (inherit camlp4-4.02)
- (name "camlp4")
- (version "4.07+1")
- (source (origin
- (method url-fetch)
- (uri (string-append "https://github.com/ocaml/camlp4/archive/"
- version ".tar.gz"))
- (sha256
- (base32
- "143hhxv1i6aq413z0i1pynrjcfl2g5gnh5r3863v6h9z0riqknzc"))
- (file-name (string-append name "-" version ".tar.gz"))))
- (properties
- `((ocaml4.02-variant . ,(delay camlp4-4.02))))
- (native-inputs
- `(("ocaml" ,ocaml-4.07)
- ("ocamlbuild" ,ocamlbuild)
- ("which" ,which)))
- (inputs
- `(("ocaml" ,ocaml-4.07)))))
-
(define-public camlp4 camlp4-4.07)
(define-public camlp5
@@ -839,8 +772,6 @@ Emacs.")
(let ((out (assoc-ref outputs "out")))
(setenv "PREFIX" out))
#t)))))
- (properties
- `((ocaml4.02-variant . ,(delay ocaml4.02-menhir))))
(home-page "http://gallium.inria.fr/~fpottier/menhir")
(synopsis "Parser generator")
(description "Menhir is a parser generator. It turns high-level grammar
@@ -852,13 +783,6 @@ Knuth’s LR(1) parser construction technique.")
;; are QPL licensed.
(license (list license:gpl2+ license:qpl))))
-(define-public ocaml4.02-menhir
- (package
- (inherit ocaml-menhir)
- (name "ocaml4.02-menhir")
- (inputs `(("ocaml" ,ocaml-4.02)))
- (native-inputs '())))
-
(define-public ocaml-bigarray-compat
(package
(name "ocaml-bigarray-compat")
@@ -892,8 +816,6 @@ Knuth’s LR(1) parser construction technique.")
(base32
"1y38fdvswy6hmppm65qvgdk4pb3ghhnvz7n4ialf46340r1s5p2d"))))
(build-system gnu-build-system)
- (properties
- `((ocaml4.02-variant . ,(delay ocaml4.02-lablgtk))))
(native-inputs
`(("camlp4" ,camlp4)
("ocaml" ,ocaml)
@@ -944,23 +866,6 @@ libglade (and it an generate OCaml code from .glade files),
libpanel, librsvg and quartz.")
(license license:lgpl2.1)))
-(define-public ocaml4.02-lablgtk
- (package
- (inherit lablgtk)
- (name "ocaml4.02-lablgtk")
- (version "2.18.5")
- (source (origin
- (method url-fetch)
- (uri (ocaml-forge-uri name version 1627))
- (sha256
- (base32
- "0cyj6sfdvzx8hw7553lhgwc0krlgvlza0ph3dk9gsxy047dm3wib"))))
- (native-inputs
- `(("camlp4" ,camlp4-4.02)
- ("ocaml" ,ocaml-4.02)
- ("findlib" ,ocaml4.02-findlib)
- ("pkg-config" ,pkg-config)))))
-
(define-public unison
(package
(name "unison")
@@ -1103,15 +1008,6 @@ compilation and linkage, there are new frontends of the various OCaml
compilers that can directly deal with packages.")
(license license:x11)))
-(define-public ocaml4.02-findlib
- (package
- (inherit ocaml-findlib)
- (name "ocaml4.02-findlib")
- (native-inputs
- `(("camlp4" ,camlp4-4.02)
- ("m4" ,m4)
- ("ocaml" ,ocaml-4.02)))))
-
;; note that some tests may hang for no obvious reason.
(define-public ocaml-ounit
(package
@@ -1137,9 +1033,6 @@ compilers that can directly deal with packages.")
other XUnit testing frameworks.")
(license license:expat)))
-(define-public ocaml4.02-ounit
- (package-with-ocaml4.02 ocaml-ounit))
-
(define-public camlzip
(package
(name "camlzip")
@@ -1182,9 +1075,6 @@ JAR format. It provides functions for reading from and writing to compressed
files in these formats.")
(license license:lgpl2.1+)))
-(define-public ocaml4.02-camlzip
- (package-with-ocaml4.02 camlzip))
-
(define-public ocamlmod
(package
(name "ocamlmod")
@@ -1209,9 +1099,6 @@ files in these formats.")
(description "Generate modules from OCaml source files.")
(license license:lgpl2.1+))) ; with an exception
-(define-public ocaml4.02-ocamlmod
- (package-with-ocaml4.02 ocamlmod))
-
(define-public ocaml-zarith
(package
(name "ocaml-zarith")
@@ -1241,9 +1128,6 @@ over big integers. Small integers are represented as Caml unboxed integers,
for speed and space economy.")
(license license:lgpl2.1+))) ; with an exception
-(define-public ocaml4.02-zarith
- (package-with-ocaml4.02 ocaml-zarith))
-
(define-public ocaml-frontc
(package
(name "ocaml-frontc")
@@ -1314,9 +1198,6 @@ generated instances of the type. It provides combinators for generating
instances and printing them.")
(license license:lgpl3+)))
-(define-public ocaml4.02-qcheck
- (package-with-ocaml4.02 ocaml-qcheck))
-
(define-public ocaml-qtest
(package
(name "ocaml-qtest")
@@ -1350,9 +1231,6 @@ qcheck library. The possibilities range from trivial tests -- extremely simple
to use -- to sophisticated random generation of test cases.")
(license license:lgpl3+)))
-(define-public ocaml4.02-qtest
- (package-with-ocaml4.02 ocaml-qtest))
-
(define-public ocaml-stringext
(package
(name "ocaml-stringext")
@@ -1378,9 +1256,6 @@ full_split, cut, rcut, etc..")
;; where it says `mit'.
(license license:expat)))
-(define-public ocaml4.02-stringext
- (package-with-ocaml4.02 ocaml-stringext))
-
(define-public ocaml-bisect
(package
(name "ocaml-bisect")
@@ -1426,21 +1301,8 @@ a camlp4-based tool that allows to instrument your application before running
tests. After application execution, it is possible to generate a report in HTML
format that is the replica of the application source code annotated with code
coverage information.")
- (properties
- `((ocaml4.02-variant . ,(delay ocaml4.02-bisect))))
(license license:gpl3+)))
-(define-public ocaml4.02-bisect
- (let ((base (package-with-ocaml4.02 (strip-ocaml4.02-variant ocaml-bisect))))
- (package
- (inherit base)
- (native-inputs
- `(("camlp4" ,camlp4-4.02)
- ("libxml2" ,libxml2)
- ("which" ,which)))
- (propagated-inputs
- `(("camlp4" ,camlp4-4.02))))))
-
(define-public dune
(package
(name "dune")
@@ -1547,8 +1409,6 @@ ocaml-migrate-parsetree")
(arguments
`(#:tests? #f; Tests fail to build
#:jbuild? #t))
- (properties
- `((ocaml4.02-variant . ,(delay ocaml4.02-bitstring))))
(home-page "https://github.com/xguerin/bitstring")
(synopsis "Bitstrings and bitstring matching for OCaml")
(description "Adds Erlang-style bitstrings and matching over bitstrings as
@@ -1558,68 +1418,6 @@ as primitives to the language, making it exceptionally simple to use and very
powerful.")
(license license:isc)))
-(define-public ocaml4.02-bitstring
- (let ((base (package-with-ocaml4.02 (strip-ocaml4.02-variant ocaml-bitstring))))
- (package
- (inherit base)
- (version "2.1.1")
- (source (origin
- (method url-fetch)
- (uri (string-append "https://github.com/xguerin/bitstring"
- "/archive/v" version ".tar.gz"))
- (file-name (string-append "ocaml-bitstring-" version ".tar.gz"))
- (sha256
- (base32
- "0vy8ibrxccii1jbsk5q6yh1kxjigqvi7lhhcmizvd5gfhf7mfyc8"))
- (patches (search-patches "ocaml-bitstring-fix-configure.patch"))))
- (build-system ocaml-build-system)
- (arguments
- `(#:ocaml ,ocaml-4.02
- #:findlib ,ocaml4.02-findlib
- #:configure-flags
- (list "CAMLP4OF=camlp4of" "--enable-coverage")
- #:make-flags
- (list (string-append "BISECTLIB="
- (assoc-ref %build-inputs "bisect")
- "/lib/ocaml/site-lib")
- (string-append "OCAMLCFLAGS=-g -I "
- (assoc-ref %build-inputs "camlp4")
- "/lib/ocaml/site-lib/camlp4 -I "
- "$(BISECTLIB)/bisect")
- (string-append "OCAMLOPTFLAGS=-g -I "
- (assoc-ref %build-inputs "camlp4")
- "/lib/ocaml/site-lib/camlp4 -I "
- "$(BISECTLIB)/bisect"))
- #:phases
- (modify-phases %standard-phases
- (add-after 'install 'link-lib
- (lambda* (#:key outputs #:allow-other-keys)
- (let* ((out (assoc-ref outputs "out"))
- (stubs (string-append out
- "/lib/ocaml/site-lib/stubslibs"))
- (lib (string-append out
- "/lib/ocaml/site-lib/bitstring")))
- (mkdir-p stubs)
- (symlink (string-append lib "/dllbitstring.so")
- (string-append stubs "/dllbitstring.so")))
- #t))
- (add-before 'configure 'fix-configure
- (lambda* (#:key inputs #:allow-other-keys)
- (substitute* "Makefile.in"
- (("@abs_top_builddir@")
- (string-append "@abs_top_builddir@:" (getenv "LIBRARY_PATH"))))
- (substitute* "configure"
- (("-/bin/sh") (string-append "-" (assoc-ref inputs "bash")
- "/bin/sh"))))))))
- (native-inputs
- `(("camlp4" ,camlp4-4.02)
- ("time" ,time)
- ("autoconf" ,autoconf)
- ("automake" ,automake)
- ("bisect" ,ocaml4.02-bisect)))
- (propagated-inputs
- `(("camlp4" ,camlp4-4.02))))))
-
(define-public ocaml-result
(package
(name "ocaml-result")
@@ -1645,9 +1443,6 @@ staying compatible with older version of OCaml should use the Result module
defined in this library.")
(license license:bsd-3)))
-(define-public ocaml4.02-result
- (package-with-ocaml4.02 ocaml-result))
-
(define-public ocaml-topkg
(package
(name "ocaml-topkg")
@@ -1679,9 +1474,6 @@ configuration and to specify information about the package's distribution,
creation and publication procedures.")
(license license:isc)))
-(define-public ocaml4.02-topkg
- (package-with-ocaml4.02 ocaml-topkg))
-
(define-public ocaml-rresult
(package
(name "ocaml-rresult")
@@ -1713,9 +1505,6 @@ to operate on the result type available from OCaml 4.03 in the standard
library.")
(license license:isc)))
-(define-public ocaml4.02-rresult
- (package-with-ocaml4.02 ocaml-rresult))
-
(define-public ocaml-sqlite3
(package
(name "ocaml-sqlite3")
@@ -1746,9 +1535,6 @@ coexistence with the old (version 2) SQLite and its OCaml wrapper
@code{ocaml-sqlite}.")
(license license:expat)))
-(define-public ocaml4.02-sqlite3
- (package-with-ocaml4.02 ocaml-sqlite3))
-
(define-public ocaml-csv
(package
(name "ocaml-csv")
@@ -1775,9 +1561,6 @@ read and write files in this format as well as some convenience functions to
manipulate such data.")
(license (package-license camlp4))))
-(define-public ocaml4.02-csv
- (package-with-ocaml4.02 ocaml-csv))
-
(define-public ocaml-mtime
(package
(name "ocaml-mtime")
@@ -1808,9 +1591,6 @@ manipulate such data.")
spans without being subject to operating system calendar time adjustments.")
(license license:isc)))
-(define-public ocaml4.02-mtime
- (package-with-ocaml4.02 ocaml-mtime))
-
(define-public ocaml-cmdliner
(package
(name "ocaml-cmdliner")
@@ -1834,8 +1614,6 @@ spans without being subject to operating system calendar time adjustments.")
#:phases
(modify-phases %standard-phases
(delete 'configure))))
- (properties
- `((ocaml4.02-variant . ,(delay ocaml4.02-cmdliner))))
(home-page "http://erratique.ch/software/cmdliner")
(synopsis "Declarative definition of command line interfaces for OCaml")
(description "Cmdliner is a module for the declarative definition of command
@@ -1846,19 +1624,6 @@ generation. It supports programs with single or multiple commands and respects
most of the POSIX and GNU conventions.")
(license license:bsd-3)))
-(define-public ocaml4.02-cmdliner
- (let ((base (package-with-ocaml4.02 (strip-ocaml4.02-variant ocaml-cmdliner))))
- (package
- (inherit base)
- (version "1.0.2")
- (source (origin
- (method url-fetch)
- (uri (string-append "http://erratique.ch/software/cmdliner/releases/"
- "cmdliner-" version ".tbz"))
- (sha256
- (base32
- "18jqphjiifljlh9jg8zpl6310p3iwyaqphdkmf89acyaix0s4kj1")))))))
-
(define-public ocaml-fmt
(package
(name "ocaml-fmt")
@@ -1891,9 +1656,6 @@ most of the POSIX and GNU conventions."
This message was truncated. Download the full message here.
J
J
Julien Lepiller wrote on 25 Apr 2019 19:04
Re: [bug#35280] [PATCH] Remove ocaml-4.02
(address . 35280-done@debbugs.gnu.org)
20190425190411.5f7d1c34@sybil.lepiller.eu
Le Sun, 14 Apr 2019 22:25:36 +0200,
Julien Lepiller <julien@lepiller.eu> a écrit :

Toggle quote (10 lines)
> Hi!
>
> This patch series removes ocaml-4.02 and dependent packages. I updated
> bap to 1.6.0 (so it can build with the latest ocaml) and downgraded
> ocamlify for the same reason. I removed the obsolete jbuilder and
> adapted two dependents.
>
> Thanks!
>

Pushed as ce9a30e6f4a34df45a4a165fea315f61745bb1d3 -
c3634df2a48a5b981a97c85f425784cee9f94bc7 since there was no answer.
Closed
?