1 |
commit: e8d185b273bb394cdcde5d156d8b8a6106d3b5cd |
2 |
Author: Sam James <sam <AT> gentoo <DOT> org> |
3 |
AuthorDate: Wed Oct 13 05:11:41 2021 +0000 |
4 |
Commit: Sam James <sam <AT> gentoo <DOT> org> |
5 |
CommitDate: Wed Oct 13 05:12:05 2021 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=e8d185b2 |
7 |
|
8 |
sys-cluster/mpich: add 3.4.2 |
9 |
|
10 |
No expert on MPI but at least this builds! |
11 |
|
12 |
Closes: https://bugs.gentoo.org/808219 |
13 |
Signed-off-by: Sam James <sam <AT> gentoo.org> |
14 |
|
15 |
sys-cluster/mpich/Manifest | 1 + |
16 |
sys-cluster/mpich/mpich-3.4.2.ebuild | 164 +++++++++++++++++++++++++++++++++++ |
17 |
2 files changed, 165 insertions(+) |
18 |
|
19 |
diff --git a/sys-cluster/mpich/Manifest b/sys-cluster/mpich/Manifest |
20 |
index ee2a89453a2..8cba7427970 100644 |
21 |
--- a/sys-cluster/mpich/Manifest |
22 |
+++ b/sys-cluster/mpich/Manifest |
23 |
@@ -1,2 +1,3 @@ |
24 |
DIST mpich-3.0.4.tar.gz 10921075 BLAKE2B 341aaac23277aed05a4448ea03d9caf1ee14cfe327a770c95d620fc1ee1ea7bfa6df36860aa44aad162eb6d630d35fdfb30ae9a866d67680ab71c7b4326c109c SHA512 f9d8b2cf561fe5f85c12512ef4dd7b0cf5ec8b53ddb07bfa0d1db2e3c8ae0382c77e0661f46b82ec96b05d18ea2d25328bb84e9528ac06e5925f30ec8ef030d0 |
25 |
DIST mpich-3.3.tar.gz 27209008 BLAKE2B 3010f847456ed71a27e728b91887e04303a83b4abea883bf73d9794ff697052efe3bccd238933dc6e5fbc75e0be36004f1ae9fc7695a4e8887984552ae005917 SHA512 1ed6d8d30db4923fd1bd39b6e9622f0db939a45edf8d9f8bdbccfa619fde7fb920c5a0d3f2442f0dd63cf8fda823dbd2983ac5f7c16308bc79e04f61d8e119be |
26 |
+DIST mpich-3.4.2.tar.gz 32850822 BLAKE2B cbbb7d8b3c6db31c9ee8f59e6a386c000480a738819c8b4398e1299c0fdfce28649a3ebc868aa48517476d0b49d4d58e66407f2116708c3d9e61ce43f6e1c32b SHA512 5f5389071c7d275a864df16aedd19f2b925c9b9ad3b304f9c9f99b5808f6b82def775b4191c03cdd3288c5e4478a40a2aae22c3cf2aabe82be1dd612efd7f2a6 |
27 |
|
28 |
diff --git a/sys-cluster/mpich/mpich-3.4.2.ebuild b/sys-cluster/mpich/mpich-3.4.2.ebuild |
29 |
new file mode 100644 |
30 |
index 00000000000..d6e74a25650 |
31 |
--- /dev/null |
32 |
+++ b/sys-cluster/mpich/mpich-3.4.2.ebuild |
33 |
@@ -0,0 +1,164 @@ |
34 |
+# Copyright 1999-2021 Gentoo Authors |
35 |
+# Distributed under the terms of the GNU General Public License v2 |
36 |
+ |
37 |
+EAPI=6 |
38 |
+ |
39 |
+FORTRAN_NEEDED=fortran |
40 |
+FORTRAN_STANDARD="77 90" |
41 |
+ |
42 |
+inherit fortran-2 multilib-minimal multilib flag-o-matic autotools |
43 |
+ |
44 |
+MY_PV=${PV/_/} |
45 |
+DESCRIPTION="A high performance and portable MPI implementation" |
46 |
+HOMEPAGE="http://www.mpich.org/" |
47 |
+SRC_URI="http://www.mpich.org/static/downloads/${PV}/${P}.tar.gz" |
48 |
+ |
49 |
+SLOT="0" |
50 |
+LICENSE="mpich2" |
51 |
+KEYWORDS="~amd64 ~arm64 ~hppa ~ppc ~ppc64 ~x86 ~amd64-linux ~x86-linux" |
52 |
+IUSE="+cxx doc fortran mpi-threads +romio threads" |
53 |
+REQUIRED_USE="mpi-threads? ( threads )" |
54 |
+ |
55 |
+COMMON_DEPEND=" |
56 |
+ >=dev-libs/libaio-0.3.109-r5[${MULTILIB_USEDEP}] |
57 |
+ >=sys-apps/hwloc-2.0.2[${MULTILIB_USEDEP}] |
58 |
+ sys-libs/libunwind[${MULTILIB_USEDEP}] |
59 |
+ romio? ( net-fs/nfs-utils ) |
60 |
+" |
61 |
+ |
62 |
+DEPEND="${COMMON_DEPEND} |
63 |
+ dev-lang/perl |
64 |
+ sys-devel/libtool |
65 |
+" |
66 |
+ |
67 |
+RDEPEND="${COMMON_DEPEND} |
68 |
+ !sys-cluster/mpich2 |
69 |
+ !sys-cluster/openmpi |
70 |
+ !sys-cluster/nullmpi" |
71 |
+ |
72 |
+S="${WORKDIR}"/${PN}-${MY_PV} |
73 |
+ |
74 |
+MULTILIB_WRAPPED_HEADERS=( |
75 |
+ /usr/include/mpicxx.h |
76 |
+ /usr/include/mpi.h |
77 |
+ /usr/include/opa_config.h |
78 |
+) |
79 |
+ |
80 |
+#PATCHES=( |
81 |
+# "${FILESDIR}"/${PN}-3.3-add-external-libdir-parameter.patch |
82 |
+#) |
83 |
+ |
84 |
+src_prepare() { |
85 |
+ default |
86 |
+ |
87 |
+ # Using MPICHLIB_LDFLAGS doesn't seem to fully work. |
88 |
+ sed -i 's| *@WRAPPER_LDFLAGS@ *||' \ |
89 |
+ src/packaging/pkgconfig/mpich.pc.in \ |
90 |
+ src/env/*.in \ |
91 |
+ || die |
92 |
+ |
93 |
+ # Fix m4 files to satisfy lib dir with multilib. |
94 |
+ #touch -r src/pm/hydra/confdb/aclocal_libs.m4 \ |
95 |
+ # confdb/aclocal_libs.m4 \ |
96 |
+ # || die |
97 |
+ #cp -fp confdb/aclocal_libs.m4 \ |
98 |
+ # src/pm/hydra/confdb/aclocal_libs.m4 \ |
99 |
+ # || die |
100 |
+ #cp -fp confdb/aclocal_libs.m4 \ |
101 |
+ # src/pm/hydra/mpl/confdb/aclocal_libs.m4 \ |
102 |
+ # || die |
103 |
+ #cd src/pm/hydra/mpl; eautoreconf; cd - |
104 |
+ #cd src/pm/hydra; eautoreconf; cd - |
105 |
+ #eautoreconf |
106 |
+} |
107 |
+ |
108 |
+multilib_src_configure() { |
109 |
+ # The configure statements can be somewhat confusing, as they |
110 |
+ # don't all show up in the top level configure, however, they |
111 |
+ # are picked up in the children directories. Hence the separate |
112 |
+ # local vars. |
113 |
+ |
114 |
+ local c= |
115 |
+ if use mpi-threads; then |
116 |
+ # MPI-THREAD requries threading. |
117 |
+ c="${c} --with-thread-package=pthreads" |
118 |
+ c="${c} --enable-threads=runtime" |
119 |
+ else |
120 |
+ if use threads ; then |
121 |
+ c="${c} --with-thread-package=pthreads" |
122 |
+ else |
123 |
+ c="${c} --with-thread-package=none" |
124 |
+ fi |
125 |
+ c="${c} --enable-threads=single" |
126 |
+ fi |
127 |
+ |
128 |
+ c="${c} --sysconfdir=${EPREFIX}/etc/${PN}" |
129 |
+ |
130 |
+ # GCC 10 compatibility workaround |
131 |
+ # bug #725842 |
132 |
+ append-fflags $(test-flags-FC -fallow-argument-mismatch) |
133 |
+ |
134 |
+ export MPICHLIB_CFLAGS="${CFLAGS}" |
135 |
+ export MPICHLIB_CPPFLAGS="${CPPFLAGS}" |
136 |
+ export MPICHLIB_CXXFLAGS="${CXXFLAGS}" |
137 |
+ export MPICHLIB_FFLAGS="${FFLAGS}" |
138 |
+ export MPICHLIB_FCFLAGS="${FCFLAGS}" |
139 |
+ export MPICHLIB_LDFLAGS="${LDFLAGS}" |
140 |
+ |
141 |
+ # dropped w/ bug #725842 fix |
142 |
+ #unset CFLAGS CPPFLAGS CXXFLAGS FFLAGS FCFLAGS LDFLAGS |
143 |
+ |
144 |
+ # Forcing Bash as there's quite a few bashisms in the build system |
145 |
+ CONFIG_SHELL="${BROOT}/bin/bash" ECONF_SOURCE=${S} econf \ |
146 |
+ --enable-shared \ |
147 |
+ --with-hwloc-prefix="${EPREFIX}/usr" \ |
148 |
+ --with-hwloc-libdir="$(get_libdir)" \ |
149 |
+ --with-common-libdir="$(get_libdir)" \ |
150 |
+ --with-prefix-libdir="$(get_libdir)" \ |
151 |
+ --with-izem-libdir="$(get_libdir)" \ |
152 |
+ --with-fiprovider-libdir="$(get_libdir)" \ |
153 |
+ ${c} \ |
154 |
+ --with-pm=hydra \ |
155 |
+ --with-device=ch3 \ |
156 |
+ --disable-fast \ |
157 |
+ --enable-versioning \ |
158 |
+ $(use_enable romio) \ |
159 |
+ $(use_enable cxx) \ |
160 |
+ $(use_enable fortran fortran all) |
161 |
+} |
162 |
+ |
163 |
+multilib_src_test() { |
164 |
+ emake -j1 check |
165 |
+} |
166 |
+ |
167 |
+multilib_src_install() { |
168 |
+ default |
169 |
+ |
170 |
+ # fortran header cannot be wrapped (bug #540508), workaround part 1 |
171 |
+ if use fortran; then |
172 |
+ if multilib_is_native_abi; then |
173 |
+ mkdir "${T}"/fortran || die |
174 |
+ mv "${ED}"usr/include/mpif* "${T}"/fortran || die |
175 |
+ mv "${ED}"usr/include/*.mod "${T}"/fortran || die |
176 |
+ else |
177 |
+ rm "${ED}"usr/include/mpif* "${ED}"usr/include/*.mod || die |
178 |
+ fi |
179 |
+ fi |
180 |
+} |
181 |
+ |
182 |
+multilib_src_install_all() { |
183 |
+ # fortran header cannot be wrapped (bug #540508), workaround part 2 |
184 |
+ if use fortran; then |
185 |
+ mv "${T}"/fortran/* "${ED}"usr/include || die |
186 |
+ fi |
187 |
+ |
188 |
+ einstalldocs |
189 |
+ newdoc src/pm/hydra/README README.hydra |
190 |
+ if use romio; then |
191 |
+ newdoc src/mpi/romio/README README.romio |
192 |
+ fi |
193 |
+ |
194 |
+ if ! use doc; then |
195 |
+ rm -rf "${ED}"usr/share/doc/${PF}/www* || die |
196 |
+ fi |
197 |
+} |