Gentoo Archives: gentoo-commits

From: Sam James <sam@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-lang/ocaml/files/, dev-lang/ocaml/
Date: Fri, 04 Mar 2022 00:59:57
Message-Id: 1646355391.1eabb8b88db7647b7a04300ead166f4e4e852951.sam@gentoo
1 commit: 1eabb8b88db7647b7a04300ead166f4e4e852951
2 Author: Sam James <sam <AT> gentoo <DOT> org>
3 AuthorDate: Fri Mar 4 00:55:27 2022 +0000
4 Commit: Sam James <sam <AT> gentoo <DOT> org>
5 CommitDate: Fri Mar 4 00:56:31 2022 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=1eabb8b8
7
8 dev-lang/ocaml: drop 4.09.0-r2
9
10 Bug: https://bugs.gentoo.org/804498
11 Signed-off-by: Sam James <sam <AT> gentoo.org>
12
13 dev-lang/ocaml/files/ocaml-4.09.0-cflags.patch | 65 ----------------
14 dev-lang/ocaml/files/ocaml-4.09.0-gcc-10.patch | 21 -----
15 dev-lang/ocaml/ocaml-4.09.0-r2.ebuild | 104 -------------------------
16 3 files changed, 190 deletions(-)
17
18 diff --git a/dev-lang/ocaml/files/ocaml-4.09.0-cflags.patch b/dev-lang/ocaml/files/ocaml-4.09.0-cflags.patch
19 deleted file mode 100644
20 index d0a947da0ea6..000000000000
21 --- a/dev-lang/ocaml/files/ocaml-4.09.0-cflags.patch
22 +++ /dev/null
23 @@ -1,65 +0,0 @@
24 ---- a/runtime/Makefile
25 -+++ b/runtime/Makefile
26 -@@ -335,7 +335,7 @@
27 - # (without the extension, which is added by the macro)
28 - define COMPILE_C_FILE
29 - $(1).$(O): %.c
30 -- $$(CC) -c $$(OC_CFLAGS) $$(OC_CPPFLAGS) $$(OUTPUTOBJ)$$@ $$<
31 -+ $$(CC) -c $$(OC_CFLAGS) $(CFLAGS) $$(OC_CPPFLAGS) $$(OUTPUTOBJ)$$@ $$<
32 - endef
33 -
34 - object_types := % %_b %_bd %_bi %_bpic %_n %_nd %_ni %_np %_npic
35 ---- a/yacc/Makefile
36 -+++ b/yacc/Makefile
37 -@@ -63,4 +63,4 @@
38 - # also works for .obj files.
39 -
40 - %.$(O): %.c
41 -- $(CC) -c $(OC_CFLAGS) $(OC_CPPFLAGS) $(OUTPUTOBJ)$@ $<
42 -+ $(CC) -c $(OC_CFLAGS) $(CFLAGS) $(OC_CPPFLAGS) $(OUTPUTOBJ)$@ $<
43 ---- a/otherlibs/Makefile.otherlibs.common
44 -+++ b/otherlibs/Makefile.otherlibs.common
45 -@@ -138,4 +138,4 @@
46 - $(CAMLOPT) -c $(COMPFLAGS) $(OPTCOMPFLAGS) $<
47 -
48 - .c.$(O):
49 -- $(CC) -c $(OC_CFLAGS) $(OC_CPPFLAGS) $(OUTPUTOBJ)$@ $<
50 -+ $(CC) -c $(OC_CFLAGS) $(CFLAGS) $(OC_CPPFLAGS) $(OUTPUTOBJ)$@ $<
51 ---- a/ocamltest/Makefile
52 -+++ b/ocamltest/Makefile
53 -@@ -221,7 +221,7 @@
54 - $(ocamllex) -q $<
55 -
56 - %.$(O): %.c
57 -- $(CC) $(OC_CFLAGS) $(OC_CPPFLAGS) -c $<
58 -+ $(CC) $(OC_CFLAGS) $(CFLAGS) $(OC_CPPFLAGS) -c $<
59 -
60 - ocamltest_config.ml: ocamltest_config.ml.in Makefile ../Makefile.config
61 - sed \
62 ---- a/otherlibs/systhreads/Makefile
63 -+++ b/otherlibs/systhreads/Makefile
64 -@@ -93,11 +93,11 @@
65 - # twice, each time with different options).
66 -
67 - st_stubs_b.$(O): st_stubs.c $(HEADER)
68 -- $(CC) -c $(OC_CFLAGS) $(OC_CPPFLAGS) -I$(ROOTDIR)/runtime \
69 -+ $(CC) -c $(OC_CFLAGS) $(CFLAGS) $(OC_CPPFLAGS) -I$(ROOTDIR)/runtime \
70 - $(SHAREDLIB_CFLAGS) $(OUTPUTOBJ)$@ $<
71 -
72 - st_stubs_n.$(O): st_stubs.c $(HEADER)
73 -- $(CC) $(OC_CFLAGS) $(OC_CPPFLAGS) \
74 -+ $(CC) $(OC_CFLAGS) $(CFLAGS) $(OC_CPPFLAGS) \
75 - -I$(ROOTDIR)/runtime $(SHAREDLIB_CFLAGS) -DNATIVE_CODE \
76 - -DTARGET_$(ARCH) -DMODEL_$(MODEL) -DSYS_$(SYSTEM) \
77 - $(OUTPUTOBJ)$@ -c $<
78 ---- a/tools/Makefile
79 -+++ b/tools/Makefile
80 -@@ -322,7 +322,7 @@
81 - endif
82 -
83 - objinfo_helper$(EXE): objinfo_helper.c $(ROOTDIR)/runtime/caml/s.h
84 -- $(CC) $(OC_CFLAGS) $(OC_CPPFLAGS) -I$(ROOTDIR)/runtime $(OUTPUTEXE)$@ \
85 -+ $(CC) $(OC_CFLAGS) $(CFLAGS) $(OC_CPPFLAGS) -I$(ROOTDIR)/runtime $(OUTPUTEXE)$@ \
86 - $(DEF_SYMBOL_PREFIX) $(LIBBFD_INCLUDE) $< $(LIBBFD_LINK)
87 -
88 - OBJINFO=$(ROOTDIR)/compilerlibs/ocamlcommon.cma \
89
90 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
91 deleted file mode 100644
92 index e25d55a5f668..000000000000
93 --- a/dev-lang/ocaml/files/ocaml-4.09.0-gcc-10.patch
94 +++ /dev/null
95 @@ -1,21 +0,0 @@
96 ---- a/runtime/backtrace.c
97 -+++ b/runtime/backtrace.c
98 -@@ -28,7 +28,7 @@
99 - #include "caml/fail.h"
100 -
101 - /* The table of debug information fragments */
102 --struct ext_table caml_debug_info;
103 -+extern struct ext_table caml_debug_info;
104 -
105 - CAMLexport int32_t caml_backtrace_active = 0;
106 - CAMLexport int32_t caml_backtrace_pos = 0;
107 ---- a/runtime/startup_nat.c
108 -+++ b/runtime/startup_nat.c
109 -@@ -44,7 +44,6 @@
110 - #endif
111 -
112 - extern int caml_parser_trace;
113 --CAMLexport header_t caml_atom_table[256];
114 - char * caml_code_area_start, * caml_code_area_end;
115 - struct ext_table caml_code_fragments_table;
116 -
117
118 diff --git a/dev-lang/ocaml/ocaml-4.09.0-r2.ebuild b/dev-lang/ocaml/ocaml-4.09.0-r2.ebuild
119 deleted file mode 100644
120 index f889bc03a12a..000000000000
121 --- a/dev-lang/ocaml/ocaml-4.09.0-r2.ebuild
122 +++ /dev/null
123 @@ -1,104 +0,0 @@
124 -# Copyright 1999-2022 Gentoo Authors
125 -# Distributed under the terms of the GNU General Public License v2
126 -
127 -EAPI=7
128 -
129 -inherit flag-o-matic
130 -
131 -HOMEPAGE="https://ocaml.org/"
132 -SRC_URI="https://github.com/ocaml/ocaml/archive/${PV}.tar.gz -> ${P}.tar.gz"
133 -DESCRIPTION="Programming language supporting functional, imperative & object-oriented styles"
134 -
135 -LICENSE="LGPL-2.1"
136 -SLOT="0/$(ver_cut 1-2)"
137 -KEYWORDS="~alpha amd64 arm arm64 ~hppa ~ia64 ~mips ~ppc ppc64 x86 ~amd64-linux ~x86-linux ~ppc-macos ~sparc-solaris ~x86-solaris"
138 -IUSE="emacs flambda latex +ocamlopt spacetime xemacs"
139 -
140 -RDEPEND="sys-libs/binutils-libs:=
141 - spacetime? ( sys-libs/libunwind:= )"
142 -BDEPEND="${RDEPEND}
143 - virtual/pkgconfig"
144 -PDEPEND="emacs? ( app-emacs/ocaml-mode )
145 - xemacs? ( app-xemacs/ocaml )"
146 -
147 -QA_FLAGS_IGNORED='/usr/lib.*/ocaml/bigarray.cmxs'
148 -
149 -PATCHES=(
150 - "${FILESDIR}"/${PN}-4.09.0-gcc-10.patch
151 - "${FILESDIR}"/${P}-cflags.patch
152 -)
153 -
154 -src_prepare() {
155 - default
156 -
157 - cp "${FILESDIR}"/ocaml.conf "${T}" || die
158 -
159 - # Broken until 4.12
160 - # bug #818445
161 - filter-flags '-flto*'
162 - append-flags -fno-strict-aliasing
163 -
164 - # OCaml generates textrels on 32-bit arches
165 - # We can't do anything about it, but disabling it means that tests
166 - # for OCaml-based packages won't fail on unexpected output
167 - # bug #773226
168 - if use arm || use ppc || use x86 ; then
169 - append-ldflags "-Wl,-z,notext"
170 - fi
171 -
172 - # Upstream build ignores LDFLAGS in several places.
173 - sed -i -e 's/\(^MKDLL=.*\)/\1 $(LDFLAGS)/' \
174 - -e 's/\(^OC_CFLAGS=.*\)/\1 $(LDFLAGS)/' \
175 - -e 's/\(^OC_LDFLAGS=.*\)/\1 $(LDFLAGS)/' \
176 - Makefile.config.in || die "LDFLAGS fix failed"
177 - # ${P} overrides upstream build's own P due to a wrong assignment operator.
178 - sed -i -e 's/^P ?=/P =/' stdlib/StdlibModules || die "P fix failed"
179 -}
180 -
181 -src_configure() {
182 - local opt=(
183 - --bindir="${EPREFIX}/usr/bin"
184 - --libdir="${EPREFIX}/usr/$(get_libdir)/ocaml"
185 - --mandir="${EPREFIX}/usr/share/man"
186 - --prefix="${EPREFIX}/usr"
187 - $(use_enable flambda)
188 - $(use_enable spacetime)
189 - )
190 - econf ${opt[@]}
191 -}
192 -
193 -src_compile() {
194 - if use ocamlopt ; then
195 - emake world.opt
196 - else
197 - emake world
198 - fi
199 -}
200 -
201 -src_test() {
202 - if use ocamlopt ; then
203 - # OCaml tests only work when run sequentially
204 - emake -j1 -C testsuite all
205 - else
206 - ewarn "${PN} was built without 'ocamlopt' USE flag; skipping tests."
207 - fi
208 -}
209 -
210 -src_install() {
211 - default
212 - dodir /usr/include
213 - # Create symlink for header files
214 - dosym "../$(get_libdir)/ocaml/caml" /usr/include/caml
215 - dodoc Changes README.adoc
216 - # Create envd entry for latex input files
217 - if use latex ; then
218 - echo "TEXINPUTS=\"${EPREFIX}/usr/$(get_libdir)/ocaml/ocamldoc:\"" > "${T}"/99ocamldoc || die
219 - doenvd "${T}"/99ocamldoc
220 - fi
221 -
222 - sed -i -e "s:lib:$(get_libdir):" "${T}"/ocaml.conf || die
223 -
224 - # Install ocaml-rebuild portage set
225 - insinto /usr/share/portage/config/sets
226 - doins "${T}"/ocaml.conf
227 -}