diff options
-rw-r--r-- | dev-lang/ocaml/ocaml-4.05.0-r3.ebuild | 8 | ||||
-rw-r--r-- | dev-lang/ocaml/ocaml-4.09.0.ebuild | 11 | ||||
-rw-r--r-- | dev-lang/ocaml/ocaml-4.10.0.ebuild | 11 | ||||
-rw-r--r-- | dev-lang/ocaml/ocaml-4.10.2.ebuild | 11 | ||||
-rw-r--r-- | dev-lang/ocaml/ocaml-4.11.1.ebuild | 11 | ||||
-rw-r--r-- | dev-lang/ocaml/ocaml-4.11.2.ebuild | 11 |
6 files changed, 63 insertions, 0 deletions
diff --git a/dev-lang/ocaml/ocaml-4.05.0-r3.ebuild b/dev-lang/ocaml/ocaml-4.05.0-r3.ebuild index c05a2cadaf49..69094b6cb10a 100644 --- a/dev-lang/ocaml/ocaml-4.05.0-r3.ebuild +++ b/dev-lang/ocaml/ocaml-4.05.0-r3.ebuild @@ -66,6 +66,14 @@ src_configure() { # -ggdb3 & co makes it behave weirdly, breaks sexplib replace-flags -ggdb* -ggdb + # OCaml generates textrels on 32-bit arches + # We can't do anything about it, but disabling it means that tests + # for OCaml-based packages won't fail on unexpected output + # bug #773226 + if use arm || use ppc || use x86 ; then + append-ldflags "-Wl,-z,notext" + fi + # It doesn't compile on alpha without this LDFLAGS use alpha && append-ldflags "-Wl,--no-relax" diff --git a/dev-lang/ocaml/ocaml-4.09.0.ebuild b/dev-lang/ocaml/ocaml-4.09.0.ebuild index 181f30b8fef2..f74988668b87 100644 --- a/dev-lang/ocaml/ocaml-4.09.0.ebuild +++ b/dev-lang/ocaml/ocaml-4.09.0.ebuild @@ -3,6 +3,8 @@ EAPI=7 +inherit flag-o-matic + HOMEPAGE="https://ocaml.org/" SRC_URI="https://github.com/ocaml/ocaml/archive/${PV}.tar.gz -> ${P}.tar.gz" DESCRIPTION="Programming language supporting functional, imperative & object-oriented styles" @@ -23,6 +25,15 @@ PATCHES=("${FILESDIR}"/${PN}-4.09.0-gcc-10.patch) src_prepare() { default + + # OCaml generates textrels on 32-bit arches + # We can't do anything about it, but disabling it means that tests + # for OCaml-based packages won't fail on unexpected output + # bug #773226 + if use arm || use ppc || use x86 ; then + append-ldflags "-Wl,-z,notext" + fi + # Upstream build ignores LDFLAGS in several places. sed -i -e 's/\(^MKDLL=.*\)/\1 $(LDFLAGS)/' \ -e 's/\(^OC_CFLAGS=.*\)/\1 $(LDFLAGS)/' \ diff --git a/dev-lang/ocaml/ocaml-4.10.0.ebuild b/dev-lang/ocaml/ocaml-4.10.0.ebuild index 903534e88c81..a91786e03014 100644 --- a/dev-lang/ocaml/ocaml-4.10.0.ebuild +++ b/dev-lang/ocaml/ocaml-4.10.0.ebuild @@ -3,6 +3,8 @@ EAPI=7 +inherit flag-o-matic + HOMEPAGE="https://ocaml.org/" SRC_URI="https://github.com/ocaml/ocaml/archive/${PV}.tar.gz -> ${P}.tar.gz" DESCRIPTION="Programming language supporting functional, imperative & object-oriented styles" @@ -23,6 +25,15 @@ PDEPEND="emacs? ( app-emacs/ocaml-mode ) src_prepare() { default + + # OCaml generates textrels on 32-bit arches + # We can't do anything about it, but disabling it means that tests + # for OCaml-based packages won't fail on unexpected output + # bug #773226 + if use arm || use ppc || use x86 ; then + append-ldflags "-Wl,-z,notext" + fi + # Upstream build ignores LDFLAGS in several places. sed -i -e 's/\(^MKDLL=.*\)/\1 $(LDFLAGS)/' \ -e 's/\(^OC_CFLAGS=.*\)/\1 $(LDFLAGS)/' \ diff --git a/dev-lang/ocaml/ocaml-4.10.2.ebuild b/dev-lang/ocaml/ocaml-4.10.2.ebuild index f29e4ae72201..208d8612d6a9 100644 --- a/dev-lang/ocaml/ocaml-4.10.2.ebuild +++ b/dev-lang/ocaml/ocaml-4.10.2.ebuild @@ -3,6 +3,8 @@ EAPI=7 +inherit flag-o-matic + HOMEPAGE="https://ocaml.org/" SRC_URI="https://github.com/ocaml/ocaml/archive/${PV}.tar.gz -> ${P}.tar.gz" DESCRIPTION="Programming language supporting functional, imperative & object-oriented styles" @@ -21,6 +23,15 @@ PDEPEND="emacs? ( app-emacs/ocaml-mode ) src_prepare() { default + + # OCaml generates textrels on 32-bit arches + # We can't do anything about it, but disabling it means that tests + # for OCaml-based packages won't fail on unexpected output + # bug #773226 + if use arm || use ppc || use x86 ; then + append-ldflags "-Wl,-z,notext" + fi + # Upstream build ignores LDFLAGS in several places. sed -i -e 's/\(^MKDLL=.*\)/\1 $(LDFLAGS)/' \ -e 's/\(^OC_CFLAGS=.*\)/\1 $(LDFLAGS)/' \ diff --git a/dev-lang/ocaml/ocaml-4.11.1.ebuild b/dev-lang/ocaml/ocaml-4.11.1.ebuild index 280d813184b1..b9fe45e6172d 100644 --- a/dev-lang/ocaml/ocaml-4.11.1.ebuild +++ b/dev-lang/ocaml/ocaml-4.11.1.ebuild @@ -3,6 +3,8 @@ EAPI=7 +inherit flag-o-matic + HOMEPAGE="https://ocaml.org/" SRC_URI="https://github.com/ocaml/ocaml/archive/${PV}.tar.gz -> ${P}.tar.gz" DESCRIPTION="Programming language supporting functional, imperative & object-oriented styles" @@ -21,6 +23,15 @@ PDEPEND="emacs? ( app-emacs/ocaml-mode ) src_prepare() { default + + # OCaml generates textrels on 32-bit arches + # We can't do anything about it, but disabling it means that tests + # for OCaml-based packages won't fail on unexpected output + # bug #773226 + if use arm || use ppc || use x86 ; then + append-ldflags "-Wl,-z,notext" + fi + # Upstream build ignores LDFLAGS in several places. sed -i -e 's/\(^MKDLL=.*\)/\1 $(LDFLAGS)/' \ -e 's/\(^OC_CFLAGS=.*\)/\1 $(LDFLAGS)/' \ diff --git a/dev-lang/ocaml/ocaml-4.11.2.ebuild b/dev-lang/ocaml/ocaml-4.11.2.ebuild index 280d813184b1..e3298bdfc899 100644 --- a/dev-lang/ocaml/ocaml-4.11.2.ebuild +++ b/dev-lang/ocaml/ocaml-4.11.2.ebuild @@ -3,6 +3,8 @@ EAPI=7 +inherit flag-o-matic + HOMEPAGE="https://ocaml.org/" SRC_URI="https://github.com/ocaml/ocaml/archive/${PV}.tar.gz -> ${P}.tar.gz" DESCRIPTION="Programming language supporting functional, imperative & object-oriented styles" @@ -21,6 +23,15 @@ PDEPEND="emacs? ( app-emacs/ocaml-mode ) src_prepare() { default + + # OCaml generates textrels on 32-bit arches + # We can't do anything about it, but disabling it means that tests + # for OCaml-based packages won't fail on unexpected output + # bug #773226 + #if use arm || use ppc || use x86 ; then + append-ldflags "-Wl,-z,notext" + #fi + # Upstream build ignores LDFLAGS in several places. sed -i -e 's/\(^MKDLL=.*\)/\1 $(LDFLAGS)/' \ -e 's/\(^OC_CFLAGS=.*\)/\1 $(LDFLAGS)/' \ |