Replace the ARM PIC patch with one from upstream
authorXimin Luo <infinity0@debian.org>
Tue, 3 Oct 2017 21:35:14 +0000 (23:35 +0200)
committerXimin Luo <infinity0@debian.org>
Tue, 3 Oct 2017 21:35:14 +0000 (23:35 +0200)
debian/changelog
debian/patches/0010-XL-001-tests.asmcomp.patch [new file with mode: 0644]
debian/patches/0010-arm-default-PIC.patch [deleted file]
debian/patches/series

index fe20e39a00461e46b8db76c510bfe828eedc73da..5de5ca2394008f958c7d77136ce421f345db5d6b 100644 (file)
@@ -1,6 +1,7 @@
 ocaml (4.05.0-10) UNRELEASED; urgency=medium
 
   * Drop support for ocamlopt on armel as suggested by upstream.
+  * Replace the ARM PIC patch with one from upstream.
 
  -- Ximin Luo <infinity0@debian.org>  Tue, 03 Oct 2017 23:36:43 +0200
 
diff --git a/debian/patches/0010-XL-001-tests.asmcomp.patch b/debian/patches/0010-XL-001-tests.asmcomp.patch
new file mode 100644 (file)
index 0000000..57cd6ca
--- /dev/null
@@ -0,0 +1,18 @@
+Description: Drop a test-suite experiment committed by mistake
+ This was failing on armhf because Debian GCC now enables PIE by default.
+Author: Xavier Leroy <xavier.leroy@inria.fr>
+Bug: https://caml.inria.fr/mantis/view.php?id=7642
+Bug-Debian: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=837359#80
+---
+diff --git a/testsuite/tests/asmcomp/main.ml b/testsuite/tests/asmcomp/main.ml
+index 284f7fb..6457ad2 100644
+--- a/testsuite/tests/asmcomp/main.ml
++++ b/testsuite/tests/asmcomp/main.ml
+@@ -6,7 +6,6 @@ let compile_file filename =
+     let out_name = Filename.chop_extension filename ^ ".s" in
+     Emitaux.output_channel := open_out out_name
+   end; (* otherwise, stdout *)
+-  Clflags.dlcode := false;
+   Compilenv.reset ~source_provenance:(Timings.File filename) "test";
+   Emit.begin_assembly();
+   let ic = open_in filename in
diff --git a/debian/patches/0010-arm-default-PIC.patch b/debian/patches/0010-arm-default-PIC.patch
deleted file mode 100644 (file)
index 98a60a0..0000000
+++ /dev/null
@@ -1,32 +0,0 @@
-Description: Default to PIC on arm
- Otherwise the armhf build fails now that PIE is enabled by default.
- TODO: there might be a better way to do this.
-Author: Ximin Luo <infinity0@debian.org>
-Forwarded: TODO
----
-This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
---- a/utils/clflags.ml
-+++ b/utils/clflags.ml
-@@ -147,6 +147,7 @@
- let pic_code = ref (match Config.architecture with (* -fPIC *)
-                      | "amd64" -> true
-+                     | "arm" -> true
-                      | _       -> false)
- let runtime_variant = ref "";;      (* -runtime-variant *)
---- a/man/ocamlopt.m
-+++ b/man/ocamlopt.m
-@@ -739,10 +739,10 @@
- Select the floating-point hardware
- .TP
- .B \-fPIC
--Generate position-independent machine code.
-+Generate position-independent machine code.  This is the default.
- .TP
- .B \-fno\-PIC
--Generate position-dependent machine code.  This is the default.
-+Generate position-dependent machine code.
- .TP
- .B \-fthumb
- Enable Thumb/Thumb-2 code generation
index 32174dcd2a1c68bf4e781930b27bacbe3df3f7a6..1196040080034b1ed34fa5a3f2199309eab30f49 100644 (file)
@@ -5,7 +5,7 @@
 0005-Avoid-multiple-declarations-in-generated-.c-files-in.patch
 0006-Embed-bytecode-in-C-object-when-using-custom.patch
 0008-Native-backtraces-don-t-work-on-powerpc-and-sparc.patch
-0010-arm-default-PIC.patch
+0010-XL-001-tests.asmcomp.patch
 0011-arm64-hide-symbols-for-stricter-binutils.patch
 0013-Use-CCLINKFLAGS-for-linking-all-executables-and-shar.patch
 0014-Compute-a-stable-name-for-preprocessed-files.patch