From 3e396d2b57d76c1025491c8313859e59778f65e8 Mon Sep 17 00:00:00 2001 From: Sergei Trofimovich Date: Wed, 5 Feb 2020 09:38:23 +0000 Subject: dev-lang/ocaml: tweak for gcc-10 Package-Manager: Portage-2.3.87, Repoman-2.3.20 Signed-off-by: Sergei Trofimovich --- dev-lang/ocaml/files/ocaml-4.09.0-gcc-10.patch | 21 +++++++++++++++++++++ dev-lang/ocaml/ocaml-4.09.0.ebuild | 4 +++- 2 files changed, 24 insertions(+), 1 deletion(-) create mode 100644 dev-lang/ocaml/files/ocaml-4.09.0-gcc-10.patch (limited to 'dev-lang') diff --git a/dev-lang/ocaml/files/ocaml-4.09.0-gcc-10.patch b/dev-lang/ocaml/files/ocaml-4.09.0-gcc-10.patch new file mode 100644 index 000000000000..e25d55a5f668 --- /dev/null +++ b/dev-lang/ocaml/files/ocaml-4.09.0-gcc-10.patch @@ -0,0 +1,21 @@ +--- a/runtime/backtrace.c ++++ b/runtime/backtrace.c +@@ -28,7 +28,7 @@ + #include "caml/fail.h" + + /* The table of debug information fragments */ +-struct ext_table caml_debug_info; ++extern struct ext_table caml_debug_info; + + CAMLexport int32_t caml_backtrace_active = 0; + CAMLexport int32_t caml_backtrace_pos = 0; +--- a/runtime/startup_nat.c ++++ b/runtime/startup_nat.c +@@ -44,7 +44,6 @@ + #endif + + extern int caml_parser_trace; +-CAMLexport header_t caml_atom_table[256]; + char * caml_code_area_start, * caml_code_area_end; + struct ext_table caml_code_fragments_table; + diff --git a/dev-lang/ocaml/ocaml-4.09.0.ebuild b/dev-lang/ocaml/ocaml-4.09.0.ebuild index c39cc2aee83d..5fb59fc6617a 100644 --- a/dev-lang/ocaml/ocaml-4.09.0.ebuild +++ b/dev-lang/ocaml/ocaml-4.09.0.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2019 Gentoo Authors +# Copyright 1999-2020 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 EAPI=7 @@ -19,6 +19,8 @@ BDEPEND="${RDEPEND} PDEPEND="emacs? ( app-emacs/ocaml-mode ) xemacs? ( app-xemacs/ocaml )" +PATCHES=("${FILESDIR}"/${PN}-4.09.0-gcc-10.patch) + src_prepare() { default # Upstream build ignores LDFLAGS in several places. -- cgit v1.2.3-65-gdbad