From b62568cc7067f3558c79b985c2a2ec30631a56a2 Mon Sep 17 00:00:00 2001 From: Jerry James Date: Tue, 30 Nov 2021 10:05:00 -0700 Subject: [PATCH] Version 0.15.0. Add patch for OCaml 4.13 compatibility. --- README.md | 9 ++++++++- ocaml-base-ocaml413.patch | 26 ++++++++++++++++++++++++++ ocaml-base.spec | 17 ++++++++++++----- sources | 2 +- 4 files changed, 47 insertions(+), 7 deletions(-) create mode 100644 ocaml-base-ocaml413.patch diff --git a/README.md b/README.md index 4507a51..97799a5 100644 --- a/README.md +++ b/README.md @@ -1,3 +1,10 @@ # ocaml-base -The ocaml-base package \ No newline at end of file +[Base](https://opensource.janestreet.com/base/) is a complete and portable +alternative to the OCaml standard library. It provides all standard +functionalities one would expect from a language standard library. It uses +consistent conventions across all of its modules. + +Base aims to be usable in any context. As a result system dependent features +such as I/O are not offered by Base. They are instead provided by companion +libraries such as [stdio](https://github.com/janestreet/stdio). diff --git a/ocaml-base-ocaml413.patch b/ocaml-base-ocaml413.patch new file mode 100644 index 0000000..bf1a8bf --- /dev/null +++ b/ocaml-base-ocaml413.patch @@ -0,0 +1,26 @@ +--- a/shadow-stdlib/gen/mapper.mll 2021-11-19 11:05:01.000000000 -0700 ++++ b/shadow-stdlib/gen/mapper.mll 2021-11-23 15:17:54.018455142 -0700 +@@ -110,10 +110,13 @@ let val_replacement = function + | "abs" -> No_equivalent + | "abs_float" -> No_equivalent + | "acos" -> Repl "Float.acos" ++ | "acosh" -> Repl "Float.acosh" + | "asin" -> Repl "Float.asin" ++ | "asinh" -> Repl "Float.asinh" + | "at_exit" -> No_equivalent + | "atan" -> Repl "Float.atan" + | "atan2" -> Repl "Float.atan2" ++ | "atanh" -> Repl "Float.atanh" + | "bool_of_string" -> Repl "Bool.of_string" + | "bool_of_string_opt" -> No_equivalent + | "ceil" -> Repl "Float.round_up" +--- a/src/dune 2021-11-19 11:05:01.000000000 -0700 ++++ b/src/dune 2021-11-23 15:29:54.579266675 -0700 +@@ -9,6 +9,7 @@ + + (library (name base) (public_name base) + (libraries base_internalhash_types caml sexplib0 shadow_stdlib) ++ (flags :standard -w -55) + (c_flags :standard -D_LARGEFILE64_SOURCE (:include mpopcnt.sexp)) + (c_names exn_stubs int_math_stubs hash_stubs am_testing) + (preprocess no_preprocessing) diff --git a/ocaml-base.spec b/ocaml-base.spec index 16052a0..bb66e92 100644 --- a/ocaml-base.spec +++ b/ocaml-base.spec @@ -6,17 +6,20 @@ %global srcname base Name: ocaml-%{srcname} -Version: 0.14.1 -Release: 4%{?dist} +Version: 0.15.0 +Release: 1%{?dist} Summary: Jane Street standard library for OCaml License: MIT URL: https://opensource.janestreet.com/base/ Source0: https://github.com/janestreet/%{srcname}/archive/v%{version}/%{srcname}-%{version}.tar.gz +# Adapt to changes in the OCaml 4.13 standard library +# See https://github.com/janestreet/base/issues/125 +Patch0: %{name}-ocaml413.patch -BuildRequires: ocaml >= 4.07.0 +BuildRequires: ocaml >= 4.08.0 BuildRequires: ocaml-dune-devel >= 2.0.0 -BuildRequires: ocaml-sexplib0-devel >= 0.14 +BuildRequires: ocaml-sexplib0-devel >= 0.15 %description Base is a standard library for OCaml. It provides a standard set of @@ -41,7 +44,7 @@ developing applications that use %{name}. %autosetup -n %{srcname}-%{version} -p1 %build -dune build %{?_smp_mflags} +dune build %{?_smp_mflags} --verbose --profile release # TODO: Once odoc is available, BR it and run this to generate documentation: # dune build %{?_smp_mflags} @doc @@ -109,6 +112,10 @@ rm -fr %{buildroot}%{_prefix}/doc %{_libdir}/ocaml/%{srcname}/*/*.mli %changelog +* Tue Nov 30 2021 Jerry James - 0.15.0-1 +- Version 0.15.0 +- Add patch for OCaml 4.13 compatibility + * Mon Oct 04 2021 Richard W.M. Jones - 0.14.1-4 - OCaml 4.13.1 build diff --git a/sources b/sources index b08290c..cc13d69 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (base-0.14.1.tar.gz) = 5675a8b6b1ee5b7bd992ac9fbb036239f11b8a8c7cac9059ca38581d91f42e35d7bfa5839a90ed227344dd4c7b1bbacf0e7871d958c81f6ccf7e072b64ceff2e +SHA512 (base-0.15.0.tar.gz) = 7c3f864fb47f3dd84f11c9110d3f4dbb245cd42c33d3f653d55c39a64c182e5d12a40073fe1e90b276ccf2130522b58a22ab8a61dbfaa7756041c4a95e133bab