diff --git a/0001-Don-t-ignore-.-configure-it-s-a-real-git-file.patch b/0001-Don-t-ignore-.-configure-it-s-a-real-git-file.patch index 5457965..6561c03 100644 --- a/0001-Don-t-ignore-.-configure-it-s-a-real-git-file.patch +++ b/0001-Don-t-ignore-.-configure-it-s-a-real-git-file.patch @@ -1,7 +1,7 @@ From ccc1bf226619608230dc94b26377756719cf7b20 Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Tue, 24 Jun 2014 22:29:38 +0100 -Subject: [PATCH 01/11] Don't ignore ./configure, it's a real git file. +Subject: [PATCH 01/12] Don't ignore ./configure, it's a real git file. --- .gitignore | 1 - diff --git a/0002-Ensure-empty-compilerlibs-directory-is-created-by-gi.patch b/0002-Ensure-empty-compilerlibs-directory-is-created-by-gi.patch index 310f51c..6560bd3 100644 --- a/0002-Ensure-empty-compilerlibs-directory-is-created-by-gi.patch +++ b/0002-Ensure-empty-compilerlibs-directory-is-created-by-gi.patch @@ -1,7 +1,7 @@ From 0e3b6450f6ab803442a809b6da41d5d5c5da650f Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Thu, 7 Jun 2012 15:36:16 +0100 -Subject: [PATCH 02/11] Ensure empty compilerlibs/ directory is created by git. +Subject: [PATCH 02/12] Ensure empty compilerlibs/ directory is created by git. This directory exists in the OCaml tarball, but is empty. As a result, git ignores it unless we put a dummy file in it. diff --git a/0003-Don-t-add-rpaths-to-libraries.patch b/0003-Don-t-add-rpaths-to-libraries.patch index 09ad172..1d36ccc 100644 --- a/0003-Don-t-add-rpaths-to-libraries.patch +++ b/0003-Don-t-add-rpaths-to-libraries.patch @@ -1,7 +1,7 @@ From 79f0f91e3e4abbfbd3564c11ea72e53310236afc Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Tue, 24 Jun 2014 10:00:15 +0100 -Subject: [PATCH 03/11] Don't add rpaths to libraries. +Subject: [PATCH 03/12] Don't add rpaths to libraries. --- tools/Makefile.shared | 6 +++--- diff --git a/0004-ocamlbyteinfo-ocamlplugininfo-Useful-utilities-from-.patch b/0004-ocamlbyteinfo-ocamlplugininfo-Useful-utilities-from-.patch index f970b0c..5e117b7 100644 --- a/0004-ocamlbyteinfo-ocamlplugininfo-Useful-utilities-from-.patch +++ b/0004-ocamlbyteinfo-ocamlplugininfo-Useful-utilities-from-.patch @@ -1,7 +1,7 @@ From 11b377aee2811891635982a5590fef62f12645b6 Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Tue, 29 May 2012 20:40:36 +0100 -Subject: [PATCH 04/11] ocamlbyteinfo, ocamlplugininfo: Useful utilities from +Subject: [PATCH 04/12] ocamlbyteinfo, ocamlplugininfo: Useful utilities from Debian, sent upstream. See: diff --git a/0005-configure-Allow-user-defined-C-compiler-flags.patch b/0005-configure-Allow-user-defined-C-compiler-flags.patch index 5220db3..c66d1fb 100644 --- a/0005-configure-Allow-user-defined-C-compiler-flags.patch +++ b/0005-configure-Allow-user-defined-C-compiler-flags.patch @@ -1,7 +1,7 @@ From 5308c47681201ef3beef3e543ab877f81aa08784 Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Tue, 29 May 2012 20:44:18 +0100 -Subject: [PATCH 05/11] configure: Allow user defined C compiler flags. +Subject: [PATCH 05/12] configure: Allow user defined C compiler flags. --- configure | 4 ++++ diff --git a/0006-Add-support-for-ppc64.patch b/0006-Add-support-for-ppc64.patch index 900c625..ddaf2d3 100644 --- a/0006-Add-support-for-ppc64.patch +++ b/0006-Add-support-for-ppc64.patch @@ -1,7 +1,7 @@ From b97622b54339f810bdca378ba7e58e5ad3152330 Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Tue, 29 May 2012 20:47:07 +0100 -Subject: [PATCH 06/11] Add support for ppc64. +Subject: [PATCH 06/12] Add support for ppc64. Note (1): This patch was rejected upstream because they don't have appropriate hardware for testing. diff --git a/0007-Add-support-for-ppc64le.patch b/0007-Add-support-for-ppc64le.patch index d0f2029..b319026 100644 --- a/0007-Add-support-for-ppc64le.patch +++ b/0007-Add-support-for-ppc64le.patch @@ -1,7 +1,7 @@ From 6e3ca14f2d4dba2612eff59126140cde0d04394f Mon Sep 17 00:00:00 2001 From: Michel Normand Date: Tue, 18 Mar 2014 09:15:47 -0400 -Subject: [PATCH 07/11] Add support for ppc64le. +Subject: [PATCH 07/12] Add support for ppc64le. Signed-off-by: Michel Normand --- diff --git a/0008-arm-arm64-Mark-stack-as-non-executable.patch b/0008-arm-arm64-Mark-stack-as-non-executable.patch index 75403ae..8a44cdb 100644 --- a/0008-arm-arm64-Mark-stack-as-non-executable.patch +++ b/0008-arm-arm64-Mark-stack-as-non-executable.patch @@ -1,7 +1,7 @@ From a2a1e564bbe995f44de2023893f6dea51668b51e Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Sat, 10 May 2014 03:20:35 -0400 -Subject: [PATCH 08/11] arm, arm64: Mark stack as non-executable. +Subject: [PATCH 08/12] arm, arm64: Mark stack as non-executable. The same fix as this one, which was only fully applied to i686 & x86-64: diff --git a/0009-arg-Add-no_arg-and-get_arg-helper-functions.patch b/0009-arg-Add-no_arg-and-get_arg-helper-functions.patch index 8d300c1..3dbebc9 100644 --- a/0009-arg-Add-no_arg-and-get_arg-helper-functions.patch +++ b/0009-arg-Add-no_arg-and-get_arg-helper-functions.patch @@ -1,7 +1,7 @@ From 0641f11626be99c8bde349520ac28a8d93106856 Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Tue, 1 Apr 2014 11:17:07 +0100 -Subject: [PATCH 09/11] arg: Add no_arg and get_arg helper functions. +Subject: [PATCH 09/12] arg: Add no_arg and get_arg helper functions. The no_arg function in this patch is a no-op. It will do something useful in the followups. diff --git a/0010-arg-Allow-flags-such-as-flag-arg-as-well-as-flag-arg.patch b/0010-arg-Allow-flags-such-as-flag-arg-as-well-as-flag-arg.patch index d33a771..d9f7fc9 100644 --- a/0010-arg-Allow-flags-such-as-flag-arg-as-well-as-flag-arg.patch +++ b/0010-arg-Allow-flags-such-as-flag-arg-as-well-as-flag-arg.patch @@ -1,7 +1,7 @@ From 4d1defe6f017b86b0766fd02005a468bedd9aa88 Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Tue, 1 Apr 2014 11:21:40 +0100 -Subject: [PATCH 10/11] arg: Allow flags such as --flag=arg as well as --flag +Subject: [PATCH 10/12] arg: Allow flags such as --flag=arg as well as --flag arg. Allow flags to be followed directly by their argument, separated by an '=' diff --git a/0011-PR-6517-use-ISO-C99-types-u-int-32-64-_t-in-preferen.patch b/0011-PR-6517-use-ISO-C99-types-u-int-32-64-_t-in-preferen.patch index b19149c..cf8f07a 100644 --- a/0011-PR-6517-use-ISO-C99-types-u-int-32-64-_t-in-preferen.patch +++ b/0011-PR-6517-use-ISO-C99-types-u-int-32-64-_t-in-preferen.patch @@ -1,7 +1,7 @@ From 6156d208e6cc6e28a964be5dd34585bd54f6eadf Mon Sep 17 00:00:00 2001 From: Xavier Leroy Date: Wed, 27 Aug 2014 09:58:33 +0000 -Subject: [PATCH 11/11] PR#6517: use ISO C99 types {,u}int{32,64}_t in +Subject: [PATCH 11/12] PR#6517: use ISO C99 types {,u}int{32,64}_t in preference to our homegrown types {,u}int{32,64}. git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@15131 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02 diff --git a/0012-ppc-ppc64-ppc64le-Mark-stack-as-non-executable.patch b/0012-ppc-ppc64-ppc64le-Mark-stack-as-non-executable.patch new file mode 100644 index 0000000..f6220dd --- /dev/null +++ b/0012-ppc-ppc64-ppc64le-Mark-stack-as-non-executable.patch @@ -0,0 +1,38 @@ +From 4e06fda2060d8696649260937f8a551815de24cf Mon Sep 17 00:00:00 2001 +From: "Richard W.M. Jones" +Date: Thu, 11 Sep 2014 14:49:54 +0100 +Subject: [PATCH 12/12] ppc, ppc64, ppc64le: Mark stack as non-executable. + +The same fix as this one, which was only fully applied to +i686 & x86-64: + +http://caml.inria.fr/mantis/view.php?id=4564 +--- + asmrun/power-elf.S | 3 +++ + asmrun/power64-elf.S | 2 ++ + 2 files changed, 5 insertions(+) + +diff --git a/asmrun/power-elf.S b/asmrun/power-elf.S +index facbfbf..14d28a0 100644 +--- a/asmrun/power-elf.S ++++ b/asmrun/power-elf.S +@@ -478,3 +478,6 @@ caml_system__frametable: + .long .L105 + 4 /* return address into callback */ + .short -1 /* negative size count => use callback link */ + .short 0 /* no roots here */ ++ ++/* Mark stack as non-executable, PR#4564 */ ++ .section .note.GNU-stack,"",%progbits +diff --git a/asmrun/power64-elf.S b/asmrun/power64-elf.S +index 98c42e2..b7bfce4 100644 +--- a/asmrun/power64-elf.S ++++ b/asmrun/power64-elf.S +@@ -577,3 +577,5 @@ caml_system__frametable: + .short 0 /* no roots here */ + .align 3 + ++/* Mark stack as non-executable, PR#4564 */ ++ .section .note.GNU-stack,"",%progbits +-- +2.0.4 + diff --git a/ocaml.spec b/ocaml.spec index c9dea4e..10a154b 100644 --- a/ocaml.spec +++ b/ocaml.spec @@ -17,7 +17,7 @@ Name: ocaml Version: 4.02.0 -Release: 2%{?dist} +Release: 3%{?dist} Summary: OCaml compiler and programming environment @@ -56,6 +56,7 @@ Patch0008: 0008-arm-arm64-Mark-stack-as-non-executable.patch Patch0009: 0009-arg-Add-no_arg-and-get_arg-helper-functions.patch Patch0010: 0010-arg-Allow-flags-such-as-flag-arg-as-well-as-flag-arg.patch Patch0011: 0011-PR-6517-use-ISO-C99-types-u-int-32-64-_t-in-preferen.patch +Patch0012: 0012-ppc-ppc64-ppc64le-Mark-stack-as-non-executable.patch # Add BFD support so that ocamlobjinfo supports *.cmxs format (RHBZ#1113735). BuildRequires: binutils-devel @@ -216,7 +217,7 @@ ulimit -Hs 65536 ulimit -Ss 65536 %endif -CFLAGS="$RPM_OPT_FLAGS" \ +CFLAGS="$RPM_OPT_FLAGS -fno-strict-aliasing" \ ./configure \ -bindir %{_bindir} \ -libdir %{_libdir}/ocaml \ @@ -418,6 +419,10 @@ fi %changelog +* Thu Sep 11 2014 Richard W.M. Jones - 4.02.0-3 +- Use -fno-strict-aliasing when building the compiler (RHBZ#990540). +- ppc, ppc64, ppc64le: Mark stack as non-executable. + * Tue Sep 9 2014 Richard W.M. Jones - 4.02.0-2 - Fix bug in argument parsing (RHBZ#1139790).