1 |
commit: 43f4976dbc20cb4c18668db393c05c71a66d9544 |
2 |
Author: Michael Orlitzky <mjo <AT> gentoo <DOT> org> |
3 |
AuthorDate: Thu May 7 13:43:52 2020 +0000 |
4 |
Commit: Michael Orlitzky <mjo <AT> gentoo <DOT> org> |
5 |
CommitDate: Fri May 8 12:20:34 2020 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=43f4976d |
7 |
|
8 |
sci-libs/coinor-clp: new EAPI=7 version 1.17.6. |
9 |
|
10 |
Another "standard" version bump that is getting less standard. I've |
11 |
added the usual coinor-* hacks and comments explaining them, but this |
12 |
package is worse than some of the others. The mumps and libscotch |
13 |
dependencies are being neglected in Gentoo, so a lot of that stuff is |
14 |
broken. To work around it, we now require sci-libs/mumps (and |
15 |
therefore sci-libs/scotch) to be built without USE=mpi. |
16 |
|
17 |
I don't feel great about this ebuild, but it's a necessary step towards |
18 |
a modern set of coinor-* packages that we can begin fixing in earnest. |
19 |
|
20 |
Package-Manager: Portage-2.3.89, Repoman-2.3.20 |
21 |
Signed-off-by: Michael Orlitzky <mjo <AT> gentoo.org> |
22 |
|
23 |
sci-libs/coinor-clp/Manifest | 2 +- |
24 |
sci-libs/coinor-clp/coinor-clp-1.15.6-r1.ebuild | 116 ------------------ |
25 |
sci-libs/coinor-clp/coinor-clp-1.17.6.ebuild | 131 +++++++++++++++++++++ |
26 |
.../files/coinor-clp-1.15.6-mpi-header.patch | 12 -- |
27 |
.../files/coinor-clp-1.15.6-overflow.patch | 11 -- |
28 |
5 files changed, 132 insertions(+), 140 deletions(-) |
29 |
|
30 |
diff --git a/sci-libs/coinor-clp/Manifest b/sci-libs/coinor-clp/Manifest |
31 |
index 159faf292db..f68d30116b4 100644 |
32 |
--- a/sci-libs/coinor-clp/Manifest |
33 |
+++ b/sci-libs/coinor-clp/Manifest |
34 |
@@ -1 +1 @@ |
35 |
-DIST Clp-1.15.6.tgz 5644504 BLAKE2B 5d11d83f96d77a9a5ec7a65276699527757d7eb77f7e54d5199c26b27007ff49aca6bfc34c777aff62a4a82b876d318d9f49f14d8860fcc784b2733ab74465f9 SHA512 a0da0cc5dcdd409c67cb67dd0f126a3d96bf59851543e7e08adbdbf01012a25905b58ded66aac50b06462ee3a147bed912740c00681417f8c228992a917748db |
36 |
+DIST coinor-clp-1.17.6.tar.gz 2158530 BLAKE2B b1bf6ecfdf3669ff4393e31c23d24f9160124dcd69df611c96feaa73acf796bc3a13a54542a5d0495e9a68789e762f5392bd7f23c0fee20c0699df2d0b084891 SHA512 8a799d87ba988a27e3ba526ded65425979b4364e374db4e943f41a523f3743efb88a9964eb575c058151e47f58be6ba0ac1b368177f0322850be3704be6f24d1 |
37 |
|
38 |
diff --git a/sci-libs/coinor-clp/coinor-clp-1.15.6-r1.ebuild b/sci-libs/coinor-clp/coinor-clp-1.15.6-r1.ebuild |
39 |
deleted file mode 100644 |
40 |
index 77b81b3997d..00000000000 |
41 |
--- a/sci-libs/coinor-clp/coinor-clp-1.15.6-r1.ebuild |
42 |
+++ /dev/null |
43 |
@@ -1,116 +0,0 @@ |
44 |
-# Copyright 1999-2019 Gentoo Authors |
45 |
-# Distributed under the terms of the GNU General Public License v2 |
46 |
- |
47 |
-EAPI=5 |
48 |
- |
49 |
-inherit autotools-utils eutils multilib toolchain-funcs |
50 |
- |
51 |
-MYPN=Clp |
52 |
- |
53 |
-DESCRIPTION="COIN-OR Linear Programming solver" |
54 |
-HOMEPAGE="https://projects.coin-or.org/Clp/" |
55 |
-SRC_URI="http://www.coin-or.org/download/source/${MYPN}/${MYPN}-${PV}.tgz" |
56 |
- |
57 |
-LICENSE="EPL-1.0" |
58 |
-SLOT="0/1" |
59 |
-KEYWORDS="~amd64 ~x86 ~amd64-linux ~x86-linux" |
60 |
-IUSE="doc examples glpk metis mumps sparse static-libs test" |
61 |
-RESTRICT="!test? ( test )" |
62 |
- |
63 |
-RDEPEND=" |
64 |
- sci-libs/coinor-osi:= |
65 |
- sci-libs/coinor-utils:= |
66 |
- glpk? ( sci-mathematics/glpk:= sci-libs/amd ) |
67 |
- metis? ( || ( sci-libs/metis sci-libs/parmetis ) ) |
68 |
- mumps? ( sci-libs/mumps ) |
69 |
- sparse? ( sci-libs/cholmod )" |
70 |
-DEPEND="${RDEPEND} |
71 |
- virtual/pkgconfig |
72 |
- doc? ( app-doc/doxygen[dot] ) |
73 |
- test? ( sci-libs/coinor-sample )" |
74 |
- |
75 |
-S="${WORKDIR}/${MYPN}-${PV}/${MYPN}" |
76 |
- |
77 |
-PATCHES=( |
78 |
- "${FILESDIR}"/${PN}-1.15.6-mpi-header.patch |
79 |
- "${FILESDIR}"/${PN}-1.15.6-overflow.patch |
80 |
-) |
81 |
- |
82 |
-src_prepare() { |
83 |
- # needed for the --with-coin-instdir |
84 |
- dodir /usr |
85 |
- if has_version sci-libs/mumps[-mpi]; then |
86 |
- ln -s "${EPREFIX}"/usr/include/mpiseq/mpi.h src/mpi.h |
87 |
- elif has_version sci-libs/mumps[mpi]; then |
88 |
- export CXX=mpicxx |
89 |
- fi |
90 |
- sed -i \ |
91 |
- -e "s:lib/pkgconfig:$(get_libdir)/pkgconfig:g" \ |
92 |
- configure || die |
93 |
- autotools-utils_src_prepare |
94 |
-} |
95 |
- |
96 |
-src_configure() { |
97 |
- local myeconfargs=( |
98 |
- --enable-aboca |
99 |
- --enable-dependency-linking |
100 |
- --with-coin-instdir="${ED}"/usr |
101 |
- $(use_with doc dot) |
102 |
- ) |
103 |
- if use glpk; then |
104 |
- myeconfargs+=( |
105 |
- --with-amd-incdir="${EPREFIX}"/usr/include |
106 |
- --with-amd-lib=-lamd |
107 |
- --with-glpk-incdir="${EPREFIX}"/usr/include |
108 |
- --with-glpk-lib=-lglpk ) |
109 |
- else |
110 |
- myeconfargs+=( --without-glpk ) |
111 |
- fi |
112 |
- if use sparse; then |
113 |
- myeconfargs+=( |
114 |
- --with-amd-incdir="${EPREFIX}"/usr/include |
115 |
- --with-amd-lib=-lamd |
116 |
- --with-cholmod-incdir="${EPREFIX}"/usr/include |
117 |
- --with-cholmod-lib=-lcholmod ) |
118 |
- else |
119 |
- myeconfargs+=( --without-amd --without-cholmod ) |
120 |
- fi |
121 |
- if use metis; then |
122 |
- myeconfargs+=( |
123 |
- --with-metis-incdir="$($(tc-getPKG_CONFIG) --cflags metis | sed s/-I//)" |
124 |
- --with-metis-lib="$($(tc-getPKG_CONFIG) --libs metis)" ) |
125 |
- else |
126 |
- myeconfargs+=( --without-metis ) |
127 |
- fi |
128 |
- if use mumps; then |
129 |
- myeconfargs+=( |
130 |
- --with-mumps-incdir="${EPREFIX}"/usr/include |
131 |
- --with-mumps-lib="-lmumps_common -ldmumps -lzmumps -lsmumps -lcmumps" ) |
132 |
- else |
133 |
- myeconfargs+=( --without-mumps ) |
134 |
- fi |
135 |
- autotools-utils_src_configure |
136 |
-} |
137 |
- |
138 |
-src_compile() { |
139 |
- # hack for parallel build, to overcome not patching Makefile.am above |
140 |
- #autotools-utils_src_compile -C src libClp.la |
141 |
- autotools-utils_src_compile all $(usex doc doxydoc "") |
142 |
-} |
143 |
- |
144 |
-src_test() { |
145 |
- autotools-utils_src_test test |
146 |
-} |
147 |
- |
148 |
-src_install() { |
149 |
- use doc && HTML_DOC=("${BUILD_DIR}/doxydocs/html/") |
150 |
- # hack for parallel install, to overcome not patching Makefile.am above |
151 |
- #autotools-utils_src_install -C src install-am |
152 |
- autotools-utils_src_install |
153 |
- # already installed |
154 |
- rm "${ED}"/usr/share/coin/doc/${MYPN}/{README,AUTHORS,LICENSE} || die |
155 |
- if use examples; then |
156 |
- insinto /usr/share/doc/${PF} |
157 |
- doins -r examples |
158 |
- fi |
159 |
-} |
160 |
|
161 |
diff --git a/sci-libs/coinor-clp/coinor-clp-1.17.6.ebuild b/sci-libs/coinor-clp/coinor-clp-1.17.6.ebuild |
162 |
new file mode 100644 |
163 |
index 00000000000..7449be2ae9f |
164 |
--- /dev/null |
165 |
+++ b/sci-libs/coinor-clp/coinor-clp-1.17.6.ebuild |
166 |
@@ -0,0 +1,131 @@ |
167 |
+# Copyright 1999-2020 Gentoo Authors |
168 |
+# Distributed under the terms of the GNU General Public License v2 |
169 |
+ |
170 |
+EAPI=7 |
171 |
+ |
172 |
+inherit toolchain-funcs |
173 |
+ |
174 |
+MY_PN=Clp |
175 |
+ |
176 |
+DESCRIPTION="COIN-OR linear programming solver" |
177 |
+HOMEPAGE="https://github.com/coin-or/Clp/" |
178 |
+SRC_URI="https://github.com/coin-or/${MY_PN}/archive/releases/${PV}.tar.gz |
179 |
+ -> ${P}.tar.gz" |
180 |
+LICENSE="EPL-1.0" |
181 |
+ |
182 |
+# major soname component |
183 |
+SLOT="0/1" |
184 |
+ |
185 |
+KEYWORDS="~amd64 ~x86 ~amd64-linux ~x86-linux" |
186 |
+IUSE="doc examples glpk metis mumps sparse static-libs test" |
187 |
+RESTRICT="!test? ( test )" |
188 |
+ |
189 |
+# Fortran is NOT needed, but the ./configure scripts for all of the CoinOR |
190 |
+# packages contain a check for it. Gentoo bug 601648 and upstream issue, |
191 |
+# |
192 |
+# https://github.com/coin-or/CoinUtils/issues/132 |
193 |
+# |
194 |
+BDEPEND="virtual/fortran |
195 |
+ virtual/pkgconfig |
196 |
+ doc? ( app-doc/doxygen[dot] ) |
197 |
+ test? ( sci-libs/coinor-sample )" |
198 |
+ |
199 |
+# USE=mpi is disabled on sci-libs/mumps because mumps/scotch are in |
200 |
+# total disarray, but in particular for bugs 670759 and 695962. There |
201 |
+# used to be some conditional USE=mpi stuff in src_prepare() that will |
202 |
+# need to be put back if you restore the ability to build against |
203 |
+# mumps[mpi]. |
204 |
+DEPEND="sci-libs/coinor-osi:= |
205 |
+ sci-libs/coinor-utils:= |
206 |
+ glpk? ( sci-mathematics/glpk:= sci-libs/amd ) |
207 |
+ metis? ( || ( sci-libs/metis sci-libs/parmetis ) ) |
208 |
+ mumps? ( sci-libs/mumps[-mpi] ) |
209 |
+ sparse? ( sci-libs/cholmod )" |
210 |
+RDEPEND="${DEPEND}" |
211 |
+ |
212 |
+S="${WORKDIR}/${MY_PN}-releases-${PV}/${MY_PN}" |
213 |
+ |
214 |
+src_prepare() { |
215 |
+ # Needed to make the --with-coin-instdir in src_configure happy. |
216 |
+ dodir /usr |
217 |
+ |
218 |
+ # The file ClpCholeskyMumps.cpp does #include "mpi.h", and we |
219 |
+ # need to point it to the right file. Our sci-libs/mumps ebuild |
220 |
+ # is so ridiculous that I can't even tell if this is our fault |
221 |
+ # or if it's something that should be reported upstream. |
222 |
+ ln -s "${EPREFIX}"/usr/include/mpiseq/mpi.h src/mpi.h || die |
223 |
+ |
224 |
+ # They don't need to guess at this, but they do, and get it wrong... |
225 |
+ sed -e "s:lib/pkgconfig:$(get_libdir)/pkgconfig:g" \ |
226 |
+ -i configure \ |
227 |
+ || die "failed to fix the pkgconfig path in ${S}/configure" |
228 |
+ |
229 |
+ default |
230 |
+} |
231 |
+ |
232 |
+src_configure() { |
233 |
+ # The --enable-aboca flag is temporarily disabled, because the build |
234 |
+ # is broken with it (see https://github.com/coin-or/Clp/issues/139). |
235 |
+ # There's a fix, but I'm not going to bother with a patch for an |
236 |
+ # an experimental feature. |
237 |
+ local myeconfargs=( |
238 |
+ --enable-dependency-linking |
239 |
+ --with-coin-instdir="${ED}"/usr |
240 |
+ $(use_with doc dot) |
241 |
+ ) |
242 |
+ if use glpk; then |
243 |
+ myeconfargs+=( |
244 |
+ --with-amd-incdir="${EPREFIX}"/usr/include |
245 |
+ --with-amd-lib=-lamd |
246 |
+ --with-glpk-incdir="${EPREFIX}"/usr/include |
247 |
+ --with-glpk-lib=-lglpk ) |
248 |
+ else |
249 |
+ myeconfargs+=( --without-glpk ) |
250 |
+ fi |
251 |
+ if use sparse; then |
252 |
+ myeconfargs+=( |
253 |
+ --with-amd-incdir="${EPREFIX}"/usr/include |
254 |
+ --with-amd-lib=-lamd |
255 |
+ --with-cholmod-incdir="${EPREFIX}"/usr/include |
256 |
+ --with-cholmod-lib=-lcholmod ) |
257 |
+ else |
258 |
+ myeconfargs+=( --without-amd --without-cholmod ) |
259 |
+ fi |
260 |
+ if use metis; then |
261 |
+ myeconfargs+=( |
262 |
+ --with-metis-incdir="$($(tc-getPKG_CONFIG) --cflags metis | sed s/-I//)" |
263 |
+ --with-metis-lib="$($(tc-getPKG_CONFIG) --libs metis)" ) |
264 |
+ else |
265 |
+ myeconfargs+=( --without-metis ) |
266 |
+ fi |
267 |
+ if use mumps; then |
268 |
+ myeconfargs+=( |
269 |
+ --with-mumps-incdir="${EPREFIX}"/usr/include |
270 |
+ --with-mumps-lib="-lmumps_common -ldmumps -lzmumps -lsmumps -lcmumps -lmpiseq" ) |
271 |
+ else |
272 |
+ myeconfargs+=( --without-mumps ) |
273 |
+ fi |
274 |
+ |
275 |
+ econf "${myeconfargs[@]}" |
276 |
+} |
277 |
+ |
278 |
+src_compile() { |
279 |
+ emake all $(usex doc doxydoc "") |
280 |
+} |
281 |
+ |
282 |
+src_test() { |
283 |
+ # NOT redundant! The build system has a "make check" target that does |
284 |
+ # nothing, so if you don't specify "test" here, you'll get a no-op. |
285 |
+ emake test |
286 |
+} |
287 |
+ |
288 |
+src_install() { |
289 |
+ use doc && HTML_DOC=("${BUILD_DIR}/doxydocs/html/") |
290 |
+ |
291 |
+ emake DESTDIR="${D}" install |
292 |
+ |
293 |
+ # Duplicate junk, and in the wrong location. |
294 |
+ rm -r "${ED}/usr/share/coin/doc/${MY_PN}" || die |
295 |
+ |
296 |
+ use examples && dodoc -r examples |
297 |
+} |
298 |
|
299 |
diff --git a/sci-libs/coinor-clp/files/coinor-clp-1.15.6-mpi-header.patch b/sci-libs/coinor-clp/files/coinor-clp-1.15.6-mpi-header.patch |
300 |
deleted file mode 100644 |
301 |
index 7ad03e8c76c..00000000000 |
302 |
--- a/sci-libs/coinor-clp/files/coinor-clp-1.15.6-mpi-header.patch |
303 |
+++ /dev/null |
304 |
@@ -1,12 +0,0 @@ |
305 |
---- src/ClpCholeskyMumps.cpp.orig 2013-06-19 09:58:02.834485943 -0700 |
306 |
-+++ src/ClpCholeskyMumps.cpp 2013-06-19 09:57:39.013355095 -0700 |
307 |
-@@ -14,8 +14,8 @@ |
308 |
- #define USE_COMM_WORLD -987654 |
309 |
- extern "C" { |
310 |
- #include "dmumps_c.h" |
311 |
--#include "mpi.h" |
312 |
- } |
313 |
-+#include "mpi.h" |
314 |
- |
315 |
- #include "ClpCholeskyMumps.hpp" |
316 |
- #include "ClpMessage.hpp" |
317 |
|
318 |
diff --git a/sci-libs/coinor-clp/files/coinor-clp-1.15.6-overflow.patch b/sci-libs/coinor-clp/files/coinor-clp-1.15.6-overflow.patch |
319 |
deleted file mode 100644 |
320 |
index cded22bf384..00000000000 |
321 |
--- a/sci-libs/coinor-clp/files/coinor-clp-1.15.6-overflow.patch |
322 |
+++ /dev/null |
323 |
@@ -1,11 +0,0 @@ |
324 |
---- src/ClpPdco.cpp.orig 2014-01-14 11:44:22.717643715 -0800 |
325 |
-+++ src/ClpPdco.cpp 2014-01-14 11:43:12.543202133 -0800 |
326 |
-@@ -316,7 +316,7 @@ |
327 |
- //bool useChol = (LSmethod == 1); |
328 |
- //bool useQR = (LSmethod == 2); |
329 |
- bool direct = (LSmethod <= 2 && ifexplicit); |
330 |
-- char solver[6]; |
331 |
-+ char solver[7]; |
332 |
- strcpy(solver, " LSQR"); |
333 |
- |
334 |
- |