Handle "unknown" ocaml system as Linux
authorStephane Glondu <steph@glondu.net>
Thu, 17 Aug 2023 12:27:20 +0000 (14:27 +0200)
committerStephane Glondu <steph@glondu.net>
Thu, 17 Aug 2023 12:30:21 +0000 (14:30 +0200)
In Debian, on mipsel and mips64el, ocaml reports system as "unknown".

debian/changelog
debian/patches/0001-Handle-unknown-ocaml-system-as-Linux.patch [new file with mode: 0644]
debian/patches/series [new file with mode: 0644]

index c02449fc3740a1abca68c9c55db5affc4787cc21..d782c4dccab4d631e6f442c302ac2a2a9a905d35 100644 (file)
@@ -1,3 +1,9 @@
+ocaml-eqaf (0.9-4) unstable; urgency=medium
+
+  * Fix FTBFS on mipsel and mips64el
+
+ -- Stéphane Glondu <glondu@debian.org>  Thu, 17 Aug 2023 14:30:17 +0200
+
 ocaml-eqaf (0.9-3) unstable; urgency=medium
 
   * Use ocaml_dune DH buildsystem
diff --git a/debian/patches/0001-Handle-unknown-ocaml-system-as-Linux.patch b/debian/patches/0001-Handle-unknown-ocaml-system-as-Linux.patch
new file mode 100644 (file)
index 0000000..c311fc1
--- /dev/null
@@ -0,0 +1,22 @@
+From: Stephane Glondu <steph@glondu.net>
+Date: Thu, 17 Aug 2023 14:27:20 +0200
+Subject: Handle "unknown" ocaml system as Linux
+
+In Debian, on mipsel and mips64el, ocaml reports system as "unknown".
+---
+ clock/select/select.ml | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/clock/select/select.ml b/clock/select/select.ml
+index 78b45cf..6572136 100644
+--- a/clock/select/select.ml
++++ b/clock/select/select.ml
+@@ -22,7 +22,7 @@ let () =
+       | [|_; "--system"; system; "-o"; output|] ->
+           let system =
+             match system with
+-            | "linux" | "elf" -> `Linux
++            | "linux" | "elf" | "unknown" -> `Linux
+             | "windows" | "mingw64" | "mingw" | "cygwin" -> `Windows
+             | "freebsd" -> `FreeBSD
+             | "macosx" -> `MacOSX
diff --git a/debian/patches/series b/debian/patches/series
new file mode 100644 (file)
index 0000000..626a2f4
--- /dev/null
@@ -0,0 +1 @@
+0001-Handle-unknown-ocaml-system-as-Linux.patch