Gentoo Archives: gentoo-commits

From: Alexey Shvetsov <alexxy@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: sci-chemistry/gromacs/
Date: Tue, 27 Oct 2020 11:09:57
Message-Id: 1603796963.fd9375c7dbe1fba727556d33a9cf4d30163bc028.alexxy@gentoo
1 commit: fd9375c7dbe1fba727556d33a9cf4d30163bc028
2 Author: Alexey Shvetsov <alexxy <AT> gentoo <DOT> org>
3 AuthorDate: Tue Oct 27 11:09:08 2020 +0000
4 Commit: Alexey Shvetsov <alexxy <AT> gentoo <DOT> org>
5 CommitDate: Tue Oct 27 11:09:23 2020 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=fd9375c7
7
8 sci-chemistry/gromacs: Version bump
9
10 Package-Manager: Portage-3.0.8, Repoman-3.0.2
11 Signed-off-by: Alexey Shvetsov <alexxy <AT> gentoo.org>
12
13 sci-chemistry/gromacs/Manifest | 2 +
14 ...romacs-9999.ebuild => gromacs-2021.9999.ebuild} | 49 +++++++++++++---------
15 ...omacs-9999.ebuild => gromacs-2021_beta1.ebuild} | 49 +++++++++++++---------
16 sci-chemistry/gromacs/gromacs-9999.ebuild | 49 +++++++++++++---------
17 4 files changed, 89 insertions(+), 60 deletions(-)
18
19 diff --git a/sci-chemistry/gromacs/Manifest b/sci-chemistry/gromacs/Manifest
20 index 9ff5ce63cab..b5a7ae11084 100644
21 --- a/sci-chemistry/gromacs/Manifest
22 +++ b/sci-chemistry/gromacs/Manifest
23 @@ -5,6 +5,7 @@ DIST gromacs-2020.1.tar.gz 29153989 BLAKE2B b1c0313da945c57c74040c2bcd50495b238b
24 DIST gromacs-2020.2.tar.gz 29144614 BLAKE2B cd20b031dcec32d9a797d66f2679779077910c184702f12f12093d92e8417d42e07bfb17a8fe63e9d29a889d5f57461b5f86e11adfc26635f8d2b5a5df19473a SHA512 348c80fad93b34e6703906fec97c6c2294c0803c326d6145776b732e1c33cd58e0967ddb2ec4799e3583542c09e7a6a015e4d084d60cf97b81b3a92253cca76c
25 DIST gromacs-2020.3.tar.gz 29143950 BLAKE2B ea88fcacc3958f1123c1fe4852f7160a04e4daff15dd2eb87c23197bff2e6379f396df0747b078dc86e7bb909ecbb4b6d98530a34234c989a636dbdb2327562d SHA512 8dbd13f8c6dd9ac337e0bea683aeff38010ee9b4ef438de230beb76e5a54884a5c1eda72f20294b7920758978e247900ac3db32b95c7452350fc1f5ef0a4bcc8
26 DIST gromacs-2020.4.tar.gz 29149899 BLAKE2B a07c8efd96137d58c1edf4ac9b5aafeb16d9e65234b9459b71471827032654acacb58ed6ae87ec6e0e593a0acd799683cc4461b06cc883b089d740708619345e SHA512 0c56f058741af70660baf0177724ec940dd984c05ea141ede91ee51ce3744f76d00e31bdb5db907e46fa1639de5dca637b3ace26e89f908c2e74c69f0c21ed3a
27 +DIST gromacs-2021-beta1.tar.gz 29665063 BLAKE2B 2c03adc1b14ec7096f0b3899e8b11b4846b6a7cf5ad1e279d3deee721fc9e78b620854d2279dccbb6b5195e891f53cca3dce273f928f00b0223d6509d5355f27 SHA512 adc5062a2d1d204d2bc366d806ca78a181df3c7c8a2f4e4814d6a64dbd890f40d3e70f522e69fa3b4a71bfae8a8843bad49c6b811363e5426c6405ec1e5d7385
28 DIST manual-2018.8.pdf 10025023 BLAKE2B afb0a6e6a72d78df743fcb57e7c1716848589e571dd35167b957a9b407ca27978ccfb6cb9e0df9c9439b888f352501a00ba32281ed1e0b4193bd606f1d77152e SHA512 b1972f7ce965bfc9377542993c5943ea4868a8ed23a969d4203264746d6bea3a7a65c6379196ece37fd6d68ec7ec80f827bde87d1049284af7082759a124f1d5
29 DIST manual-2019.5.pdf 12702361 BLAKE2B cb80429a59019b190115bf2af689c0df23b0fec6e41a9ebc9eba20977d1b06eed79044c906c41228883767f673140e15d3a5ef947a0c1ec4fe84012089f4fa91 SHA512 baf27961b87e6120c49abc9dc58e25d12a15588b4ac787e1a086748d488692d4a1262229ac66e550d3cca3a6042545fb6ec472a2c98d6a8698b7a18b4397f605
30 DIST manual-2019.6.pdf 12702376 BLAKE2B c350127bc06a9eb3dee73da39037c84daeb89500e23cb131bd19a150bf60602d4dde7611e0c6f0f344af4093e96a899303dac71b4df56fd0c44c3a48a56606b7 SHA512 dfdff67c2c1c9ce1f1c236b7686c5331b0fe86951da6c98eddd6a3e748815e0be0a9653ae4318469fcdd913c4e7c355d64a997cc80b9d9fbe6282ef6d98e61eb
31 @@ -15,3 +16,4 @@ DIST regressiontests-2020.1.tar.gz 48541809 BLAKE2B 0fec2f0fb7fad0ad48bb790d7df6
32 DIST regressiontests-2020.2.tar.gz 48539492 BLAKE2B 08222ec18e70f551194fc0a060facda394c0d9999e162dace06029aa5f36e7237aeb2468a80d1198257a45fb076f8f633a7279a85976484900bf4154176aa070 SHA512 3066d92a59dafade78807612681d82a7b8a0bd9b74fa7e8784063a908418c55b4427482dc7feb261ff6981fabb2d64a800d3e90ed647ab45e201f4847347bac7
33 DIST regressiontests-2020.3.tar.gz 48541439 BLAKE2B c8b3840b76b7974e5efd518d02da2be3c8e685a420462962cf4ffb7b234bd5ffec0fb83adc962e4ce4716098667e1431f7bc46911bf5400f369881c697c1d0cb SHA512 84848210b2c4c0387c3f347237d58a114bd28c2d248f359e40a4a5b3557fca7763c431d1e03f167dcf22296a48dd47413a644238d72edc1414e3f830dd732416
34 DIST regressiontests-2020.4.tar.gz 48542144 BLAKE2B 1dcde67525d40ababa74d9e8ba2dd3fdef1de7d1018491e102edd71d3a622925f213b5a0812e5448882b4cb5fb578317e8e5029bdc4bd53008aa8441a3d9dea1 SHA512 7c71f36a1cef22562f14dcd233e90ad2fe370ae1a7d3b5268727259b374e12d4754253735ac8745d3738bdbc1cc2067780fda5e393be2ff264f632fe4e0c1978
35 +DIST regressiontests-2021-beta1.tar.gz 48526911 BLAKE2B 6bd20fd368f09af415881420828df1b0c1eb36848afb1e9bb47cd35dbb62847f4c529357df9a120fac314d6eca56eec10f460354bd7b8449b7f99e869c64142e SHA512 df7f95eb1a4946ec879432de1d8382f25e3dda71c80b569da59414b106ed85d7ecebc2c6e1f394ec6446dac75fe4efc8acc0aadc2bd402272c0f81edef8503ca
36
37 diff --git a/sci-chemistry/gromacs/gromacs-9999.ebuild b/sci-chemistry/gromacs/gromacs-2021.9999.ebuild
38 similarity index 87%
39 copy from sci-chemistry/gromacs/gromacs-9999.ebuild
40 copy to sci-chemistry/gromacs/gromacs-2021.9999.ebuild
41 index 808f5df33db..f3636cfc50f 100644
42 --- a/sci-chemistry/gromacs/gromacs-9999.ebuild
43 +++ b/sci-chemistry/gromacs/gromacs-2021.9999.ebuild
44 @@ -9,7 +9,7 @@ PYTHON_COMPAT=( python3_{6,7,8,9} )
45
46 DISTUTILS_SINGLE_IMPL=1
47
48 -inherit bash-completion-r1 cmake cuda distutils-r1 eutils multilib readme.gentoo-r1 toolchain-funcs xdg-utils
49 +inherit bash-completion-r1 cmake cuda distutils-r1 eutils flag-o-matic multilib readme.gentoo-r1 toolchain-funcs xdg-utils
50
51 if [[ $PV = *9999* ]]; then
52 EGIT_REPO_URI="git://git.gromacs.org/gromacs.git
53 @@ -19,12 +19,13 @@ if [[ $PV = *9999* ]]; then
54 [[ $PV = 9999 ]] && EGIT_BRANCH="master" || EGIT_BRANCH="release-${PV:0:4}"
55 inherit git-r3
56 else
57 - SRC_URI="ftp://ftp.gromacs.org/pub/${PN}/${PN}-${PV/_/-}.tar.gz
58 - test? ( http://gerrit.gromacs.org/download/regressiontests-${PV/_/-}.tar.gz )"
59 + SRC_URI="
60 + http://ftp.gromacs.org/pub/${PN}/${PN}-${PV/_/-}.tar.gz
61 + test? ( http://ftp.gromacs.org/pub/regressiontests/regressiontests-${PV/_/-}.tar.gz )"
62 KEYWORDS="~amd64 ~arm ~x86 ~amd64-linux ~x86-linux ~x64-macos ~x86-macos"
63 fi
64
65 -ACCE_IUSE="cpu_flags_x86_sse2 cpu_flags_x86_sse4_1 cpu_flags_x86_fma4 cpu_flags_x86_avx cpu_flags_x86_avx2"
66 +ACCE_IUSE="cpu_flags_x86_sse2 cpu_flags_x86_sse4_1 cpu_flags_x86_fma4 cpu_flags_x86_avx cpu_flags_x86_avx2 cpu_flags_x86_avx512f cpu_flags_arm_neon"
67
68 DESCRIPTION="The ultimate molecular dynamics simulation package"
69 HOMEPAGE="http://www.gromacs.org/"
70 @@ -34,7 +35,7 @@ HOMEPAGE="http://www.gromacs.org/"
71 # base, vmd plugins, fftpack from numpy, blas/lapck from netlib, memtestG80 library, mpi_thread lib
72 LICENSE="LGPL-2.1 UoI-NCSA !mkl? ( !fftw? ( BSD ) !blas? ( BSD ) !lapack? ( BSD ) ) cuda? ( LGPL-3 ) threads? ( BSD )"
73 SLOT="0/${PV}"
74 -IUSE="X blas cuda +doc -double-precision +fftw +gmxapi +gmxapi-legacy +hwloc lapack +lmfit mkl mpi +offensive opencl openmp +python +single-precision test +threads +tng ${ACCE_IUSE}"
75 +IUSE="X blas cuda +custom-cflags +doc -double-precision +fftw +gmxapi +gmxapi-legacy +hwloc lapack +lmfit mkl mpi +offensive opencl openmp +python +single-precision test +threads +tng ${ACCE_IUSE}"
76
77 CDEPEND="
78 X? (
79 @@ -159,13 +160,24 @@ src_prepare() {
80 src_configure() {
81 local mycmakeargs_pre=( ) extra fft_opts=( )
82
83 - #go from slowest to fastest acceleration
84 - local acce="None"
85 - use cpu_flags_x86_sse2 && acce="SSE2"
86 - use cpu_flags_x86_sse4_1 && acce="SSE4.1"
87 - use cpu_flags_x86_fma4 && acce="AVX_128_FMA"
88 - use cpu_flags_x86_avx && acce="AVX_256"
89 - use cpu_flags_x86_avx2 && acce="AVX2_256"
90 + if use custom-cflags; then
91 + #go from slowest to fastest acceleration
92 + local acce="None"
93 + if (use amd64 || use x86); then
94 + use cpu_flags_x86_sse2 && acce="SSE2"
95 + use cpu_flags_x86_sse4_1 && acce="SSE4.1"
96 + use cpu_flags_x86_fma4 && acce="AVX_128_FMA"
97 + use cpu_flags_x86_avx && acce="AVX_256"
98 + use cpu_flags_x86_avx2 && acce="AVX2_256"
99 + use cpu_flags_x86_avx512f && acce="AVX_512"
100 + elif (use arm); then
101 + use cpu_flags_arm_neon && acce="ARM_NEON"
102 + elif (use arm64); then
103 + use cpu_flags_arm_neon && acce="ARM_NEON_ASIMD"
104 + fi
105 + else
106 + strip-flags
107 + fi
108
109 #to create man pages, build tree binaries are executed (bug #398437)
110 [[ ${CHOST} = *-darwin* ]] && \
111 @@ -222,24 +234,21 @@ src_configure() {
112 [[ ${x} = "double" ]] && suffix="_d"
113 local p
114 [[ ${x} = "double" ]] && p="-DGMX_DOUBLE=ON" || p="-DGMX_DOUBLE=OFF"
115 - local cuda=( "-DGMX_GPU=OFF" )
116 - [[ ${x} = "float" ]] && use cuda && \
117 - cuda=( "-DGMX_GPU=ON" )
118 - local opencl=( "-DGMX_USE_OPENCL=OFF" )
119 - use opencl && opencl=( "-DGMX_USE_OPENCL=ON" ) cuda=( "-DGMX_GPU=ON" )
120 + local gpu=( "-DGMX_GPU=OFF" )
121 + [[ ${x} = "float" ]] && use cuda && gpu=( "-DGMX_GPU=CUDA" )
122 + use opencl && gpu=( "-DGMX_GPU=OPENCL" )
123 mycmakeargs=(
124 ${mycmakeargs_pre[@]} ${p}
125 -DGMX_MPI=OFF
126 -DGMX_THREAD_MPI=$(usex threads)
127 -DGMXAPI=$(usex gmxapi)
128 -DGMX_INSTALL_LEGACY_API=$(usex gmxapi-legacy)
129 - "${opencl[@]}"
130 - "${cuda[@]}"
131 + "${gpu[@]}"
132 "$(use test && echo -DREGRESSIONTEST_PATH="${WORKDIR}/${P}_${x}/tests")"
133 -DGMX_BINARY_SUFFIX="${suffix}"
134 -DGMX_LIBS_SUFFIX="${suffix}"
135 -DGMX_PYTHON_PACKAGE=$(usex python)
136 - )
137 + )
138 BUILD_DIR="${WORKDIR}/${P}_${x}" cmake_src_configure
139 [[ ${CHOST} != *-darwin* ]] || \
140 sed -i '/SET(CMAKE_INSTALL_NAME_DIR/s/^/#/' "${WORKDIR}/${P}_${x}/gentoo_rules.cmake" || die
141
142 diff --git a/sci-chemistry/gromacs/gromacs-9999.ebuild b/sci-chemistry/gromacs/gromacs-2021_beta1.ebuild
143 similarity index 87%
144 copy from sci-chemistry/gromacs/gromacs-9999.ebuild
145 copy to sci-chemistry/gromacs/gromacs-2021_beta1.ebuild
146 index 808f5df33db..f3636cfc50f 100644
147 --- a/sci-chemistry/gromacs/gromacs-9999.ebuild
148 +++ b/sci-chemistry/gromacs/gromacs-2021_beta1.ebuild
149 @@ -9,7 +9,7 @@ PYTHON_COMPAT=( python3_{6,7,8,9} )
150
151 DISTUTILS_SINGLE_IMPL=1
152
153 -inherit bash-completion-r1 cmake cuda distutils-r1 eutils multilib readme.gentoo-r1 toolchain-funcs xdg-utils
154 +inherit bash-completion-r1 cmake cuda distutils-r1 eutils flag-o-matic multilib readme.gentoo-r1 toolchain-funcs xdg-utils
155
156 if [[ $PV = *9999* ]]; then
157 EGIT_REPO_URI="git://git.gromacs.org/gromacs.git
158 @@ -19,12 +19,13 @@ if [[ $PV = *9999* ]]; then
159 [[ $PV = 9999 ]] && EGIT_BRANCH="master" || EGIT_BRANCH="release-${PV:0:4}"
160 inherit git-r3
161 else
162 - SRC_URI="ftp://ftp.gromacs.org/pub/${PN}/${PN}-${PV/_/-}.tar.gz
163 - test? ( http://gerrit.gromacs.org/download/regressiontests-${PV/_/-}.tar.gz )"
164 + SRC_URI="
165 + http://ftp.gromacs.org/pub/${PN}/${PN}-${PV/_/-}.tar.gz
166 + test? ( http://ftp.gromacs.org/pub/regressiontests/regressiontests-${PV/_/-}.tar.gz )"
167 KEYWORDS="~amd64 ~arm ~x86 ~amd64-linux ~x86-linux ~x64-macos ~x86-macos"
168 fi
169
170 -ACCE_IUSE="cpu_flags_x86_sse2 cpu_flags_x86_sse4_1 cpu_flags_x86_fma4 cpu_flags_x86_avx cpu_flags_x86_avx2"
171 +ACCE_IUSE="cpu_flags_x86_sse2 cpu_flags_x86_sse4_1 cpu_flags_x86_fma4 cpu_flags_x86_avx cpu_flags_x86_avx2 cpu_flags_x86_avx512f cpu_flags_arm_neon"
172
173 DESCRIPTION="The ultimate molecular dynamics simulation package"
174 HOMEPAGE="http://www.gromacs.org/"
175 @@ -34,7 +35,7 @@ HOMEPAGE="http://www.gromacs.org/"
176 # base, vmd plugins, fftpack from numpy, blas/lapck from netlib, memtestG80 library, mpi_thread lib
177 LICENSE="LGPL-2.1 UoI-NCSA !mkl? ( !fftw? ( BSD ) !blas? ( BSD ) !lapack? ( BSD ) ) cuda? ( LGPL-3 ) threads? ( BSD )"
178 SLOT="0/${PV}"
179 -IUSE="X blas cuda +doc -double-precision +fftw +gmxapi +gmxapi-legacy +hwloc lapack +lmfit mkl mpi +offensive opencl openmp +python +single-precision test +threads +tng ${ACCE_IUSE}"
180 +IUSE="X blas cuda +custom-cflags +doc -double-precision +fftw +gmxapi +gmxapi-legacy +hwloc lapack +lmfit mkl mpi +offensive opencl openmp +python +single-precision test +threads +tng ${ACCE_IUSE}"
181
182 CDEPEND="
183 X? (
184 @@ -159,13 +160,24 @@ src_prepare() {
185 src_configure() {
186 local mycmakeargs_pre=( ) extra fft_opts=( )
187
188 - #go from slowest to fastest acceleration
189 - local acce="None"
190 - use cpu_flags_x86_sse2 && acce="SSE2"
191 - use cpu_flags_x86_sse4_1 && acce="SSE4.1"
192 - use cpu_flags_x86_fma4 && acce="AVX_128_FMA"
193 - use cpu_flags_x86_avx && acce="AVX_256"
194 - use cpu_flags_x86_avx2 && acce="AVX2_256"
195 + if use custom-cflags; then
196 + #go from slowest to fastest acceleration
197 + local acce="None"
198 + if (use amd64 || use x86); then
199 + use cpu_flags_x86_sse2 && acce="SSE2"
200 + use cpu_flags_x86_sse4_1 && acce="SSE4.1"
201 + use cpu_flags_x86_fma4 && acce="AVX_128_FMA"
202 + use cpu_flags_x86_avx && acce="AVX_256"
203 + use cpu_flags_x86_avx2 && acce="AVX2_256"
204 + use cpu_flags_x86_avx512f && acce="AVX_512"
205 + elif (use arm); then
206 + use cpu_flags_arm_neon && acce="ARM_NEON"
207 + elif (use arm64); then
208 + use cpu_flags_arm_neon && acce="ARM_NEON_ASIMD"
209 + fi
210 + else
211 + strip-flags
212 + fi
213
214 #to create man pages, build tree binaries are executed (bug #398437)
215 [[ ${CHOST} = *-darwin* ]] && \
216 @@ -222,24 +234,21 @@ src_configure() {
217 [[ ${x} = "double" ]] && suffix="_d"
218 local p
219 [[ ${x} = "double" ]] && p="-DGMX_DOUBLE=ON" || p="-DGMX_DOUBLE=OFF"
220 - local cuda=( "-DGMX_GPU=OFF" )
221 - [[ ${x} = "float" ]] && use cuda && \
222 - cuda=( "-DGMX_GPU=ON" )
223 - local opencl=( "-DGMX_USE_OPENCL=OFF" )
224 - use opencl && opencl=( "-DGMX_USE_OPENCL=ON" ) cuda=( "-DGMX_GPU=ON" )
225 + local gpu=( "-DGMX_GPU=OFF" )
226 + [[ ${x} = "float" ]] && use cuda && gpu=( "-DGMX_GPU=CUDA" )
227 + use opencl && gpu=( "-DGMX_GPU=OPENCL" )
228 mycmakeargs=(
229 ${mycmakeargs_pre[@]} ${p}
230 -DGMX_MPI=OFF
231 -DGMX_THREAD_MPI=$(usex threads)
232 -DGMXAPI=$(usex gmxapi)
233 -DGMX_INSTALL_LEGACY_API=$(usex gmxapi-legacy)
234 - "${opencl[@]}"
235 - "${cuda[@]}"
236 + "${gpu[@]}"
237 "$(use test && echo -DREGRESSIONTEST_PATH="${WORKDIR}/${P}_${x}/tests")"
238 -DGMX_BINARY_SUFFIX="${suffix}"
239 -DGMX_LIBS_SUFFIX="${suffix}"
240 -DGMX_PYTHON_PACKAGE=$(usex python)
241 - )
242 + )
243 BUILD_DIR="${WORKDIR}/${P}_${x}" cmake_src_configure
244 [[ ${CHOST} != *-darwin* ]] || \
245 sed -i '/SET(CMAKE_INSTALL_NAME_DIR/s/^/#/' "${WORKDIR}/${P}_${x}/gentoo_rules.cmake" || die
246
247 diff --git a/sci-chemistry/gromacs/gromacs-9999.ebuild b/sci-chemistry/gromacs/gromacs-9999.ebuild
248 index 808f5df33db..f3636cfc50f 100644
249 --- a/sci-chemistry/gromacs/gromacs-9999.ebuild
250 +++ b/sci-chemistry/gromacs/gromacs-9999.ebuild
251 @@ -9,7 +9,7 @@ PYTHON_COMPAT=( python3_{6,7,8,9} )
252
253 DISTUTILS_SINGLE_IMPL=1
254
255 -inherit bash-completion-r1 cmake cuda distutils-r1 eutils multilib readme.gentoo-r1 toolchain-funcs xdg-utils
256 +inherit bash-completion-r1 cmake cuda distutils-r1 eutils flag-o-matic multilib readme.gentoo-r1 toolchain-funcs xdg-utils
257
258 if [[ $PV = *9999* ]]; then
259 EGIT_REPO_URI="git://git.gromacs.org/gromacs.git
260 @@ -19,12 +19,13 @@ if [[ $PV = *9999* ]]; then
261 [[ $PV = 9999 ]] && EGIT_BRANCH="master" || EGIT_BRANCH="release-${PV:0:4}"
262 inherit git-r3
263 else
264 - SRC_URI="ftp://ftp.gromacs.org/pub/${PN}/${PN}-${PV/_/-}.tar.gz
265 - test? ( http://gerrit.gromacs.org/download/regressiontests-${PV/_/-}.tar.gz )"
266 + SRC_URI="
267 + http://ftp.gromacs.org/pub/${PN}/${PN}-${PV/_/-}.tar.gz
268 + test? ( http://ftp.gromacs.org/pub/regressiontests/regressiontests-${PV/_/-}.tar.gz )"
269 KEYWORDS="~amd64 ~arm ~x86 ~amd64-linux ~x86-linux ~x64-macos ~x86-macos"
270 fi
271
272 -ACCE_IUSE="cpu_flags_x86_sse2 cpu_flags_x86_sse4_1 cpu_flags_x86_fma4 cpu_flags_x86_avx cpu_flags_x86_avx2"
273 +ACCE_IUSE="cpu_flags_x86_sse2 cpu_flags_x86_sse4_1 cpu_flags_x86_fma4 cpu_flags_x86_avx cpu_flags_x86_avx2 cpu_flags_x86_avx512f cpu_flags_arm_neon"
274
275 DESCRIPTION="The ultimate molecular dynamics simulation package"
276 HOMEPAGE="http://www.gromacs.org/"
277 @@ -34,7 +35,7 @@ HOMEPAGE="http://www.gromacs.org/"
278 # base, vmd plugins, fftpack from numpy, blas/lapck from netlib, memtestG80 library, mpi_thread lib
279 LICENSE="LGPL-2.1 UoI-NCSA !mkl? ( !fftw? ( BSD ) !blas? ( BSD ) !lapack? ( BSD ) ) cuda? ( LGPL-3 ) threads? ( BSD )"
280 SLOT="0/${PV}"
281 -IUSE="X blas cuda +doc -double-precision +fftw +gmxapi +gmxapi-legacy +hwloc lapack +lmfit mkl mpi +offensive opencl openmp +python +single-precision test +threads +tng ${ACCE_IUSE}"
282 +IUSE="X blas cuda +custom-cflags +doc -double-precision +fftw +gmxapi +gmxapi-legacy +hwloc lapack +lmfit mkl mpi +offensive opencl openmp +python +single-precision test +threads +tng ${ACCE_IUSE}"
283
284 CDEPEND="
285 X? (
286 @@ -159,13 +160,24 @@ src_prepare() {
287 src_configure() {
288 local mycmakeargs_pre=( ) extra fft_opts=( )
289
290 - #go from slowest to fastest acceleration
291 - local acce="None"
292 - use cpu_flags_x86_sse2 && acce="SSE2"
293 - use cpu_flags_x86_sse4_1 && acce="SSE4.1"
294 - use cpu_flags_x86_fma4 && acce="AVX_128_FMA"
295 - use cpu_flags_x86_avx && acce="AVX_256"
296 - use cpu_flags_x86_avx2 && acce="AVX2_256"
297 + if use custom-cflags; then
298 + #go from slowest to fastest acceleration
299 + local acce="None"
300 + if (use amd64 || use x86); then
301 + use cpu_flags_x86_sse2 && acce="SSE2"
302 + use cpu_flags_x86_sse4_1 && acce="SSE4.1"
303 + use cpu_flags_x86_fma4 && acce="AVX_128_FMA"
304 + use cpu_flags_x86_avx && acce="AVX_256"
305 + use cpu_flags_x86_avx2 && acce="AVX2_256"
306 + use cpu_flags_x86_avx512f && acce="AVX_512"
307 + elif (use arm); then
308 + use cpu_flags_arm_neon && acce="ARM_NEON"
309 + elif (use arm64); then
310 + use cpu_flags_arm_neon && acce="ARM_NEON_ASIMD"
311 + fi
312 + else
313 + strip-flags
314 + fi
315
316 #to create man pages, build tree binaries are executed (bug #398437)
317 [[ ${CHOST} = *-darwin* ]] && \
318 @@ -222,24 +234,21 @@ src_configure() {
319 [[ ${x} = "double" ]] && suffix="_d"
320 local p
321 [[ ${x} = "double" ]] && p="-DGMX_DOUBLE=ON" || p="-DGMX_DOUBLE=OFF"
322 - local cuda=( "-DGMX_GPU=OFF" )
323 - [[ ${x} = "float" ]] && use cuda && \
324 - cuda=( "-DGMX_GPU=ON" )
325 - local opencl=( "-DGMX_USE_OPENCL=OFF" )
326 - use opencl && opencl=( "-DGMX_USE_OPENCL=ON" ) cuda=( "-DGMX_GPU=ON" )
327 + local gpu=( "-DGMX_GPU=OFF" )
328 + [[ ${x} = "float" ]] && use cuda && gpu=( "-DGMX_GPU=CUDA" )
329 + use opencl && gpu=( "-DGMX_GPU=OPENCL" )
330 mycmakeargs=(
331 ${mycmakeargs_pre[@]} ${p}
332 -DGMX_MPI=OFF
333 -DGMX_THREAD_MPI=$(usex threads)
334 -DGMXAPI=$(usex gmxapi)
335 -DGMX_INSTALL_LEGACY_API=$(usex gmxapi-legacy)
336 - "${opencl[@]}"
337 - "${cuda[@]}"
338 + "${gpu[@]}"
339 "$(use test && echo -DREGRESSIONTEST_PATH="${WORKDIR}/${P}_${x}/tests")"
340 -DGMX_BINARY_SUFFIX="${suffix}"
341 -DGMX_LIBS_SUFFIX="${suffix}"
342 -DGMX_PYTHON_PACKAGE=$(usex python)
343 - )
344 + )
345 BUILD_DIR="${WORKDIR}/${P}_${x}" cmake_src_configure
346 [[ ${CHOST} != *-darwin* ]] || \
347 sed -i '/SET(CMAKE_INSTALL_NAME_DIR/s/^/#/' "${WORKDIR}/${P}_${x}/gentoo_rules.cmake" || die