1 |
commit: 919dddde3c29c8de62bfebab71761efe3f30b5d3 |
2 |
Author: David Seifert <soap <AT> gentoo <DOT> org> |
3 |
AuthorDate: Fri May 26 18:02:22 2017 +0000 |
4 |
Commit: David Seifert <soap <AT> gentoo <DOT> org> |
5 |
CommitDate: Fri May 26 18:02:42 2017 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=919dddde |
7 |
|
8 |
sci-libs/fftw: Version bump to 3.3.6-pl2 |
9 |
|
10 |
Package-Manager: Portage-2.3.6, Repoman-2.3.2 |
11 |
|
12 |
sci-libs/fftw/Manifest | 1 + |
13 |
sci-libs/fftw/fftw-3.3.6_p2.ebuild | 180 +++++++++++++++++++++++++++++++++++++ |
14 |
2 files changed, 181 insertions(+) |
15 |
|
16 |
diff --git a/sci-libs/fftw/Manifest b/sci-libs/fftw/Manifest |
17 |
index c13f4f4aa7f..b337988db26 100644 |
18 |
--- a/sci-libs/fftw/Manifest |
19 |
+++ b/sci-libs/fftw/Manifest |
20 |
@@ -2,3 +2,4 @@ DIST fftw-2.1.5.tar.gz 1256888 SHA256 f8057fae1c7df8b99116783ef3e94a6a44518d49c7 |
21 |
DIST fftw-3.3.4.tar.gz 3940427 SHA256 8f0cde90929bc05587c3368d2f15cd0530a60b8a9912a8e2979a72dbe5af0982 SHA512 1ee2c7bec3657f6846e63c6dfa71410563830d2b951966bf0123bd8f4f2f5d6b50f13b76d9a7b0eae70e44856f829ca6ceb3d080bb01649d1572c9f3f68e8eb1 WHIRLPOOL 2a5733f5537ff55a1830994431f1750dd790a4df3e8b3d1e9018c1afba2c5172f4e456eaee1c3427a2b170d23b6928da462e067a6f4e94792cfc7ff1cbc38938 |
22 |
DIST fftw-3.3.5.tar.gz 4148447 SHA256 8ecfe1b04732ec3f5b7d279fdb8efcad536d555f9d1e8fabd027037d45ea8bcf SHA512 a81f02d884cfe4171fab479b0e5ec76eceb9c5da6d4eda1f89281b7e1efa2d8176c9ba87051595c402889eb32172d216ce40eb2bef41289c646f01002fb4ba8e WHIRLPOOL dc044c73dbb1b9fa595a0f1e71b5958d3e023c38cd6b1bb8a486adcad506fc6e411a3d8d0657a32346ff6636cf25396bd9bcdbcd720e8c799f6e40f1e04bfd65 |
23 |
DIST fftw-3.3.6-pl1.tar.gz 4179807 SHA256 1ef4aa8427d9785839bc767f3eb6a84fcb5e9a37c31ed77a04e7e047519a183d SHA512 e2ed33fcb068a36a841bbd898d12ceec74f4e9a0a349e7c55959878b50224a69a0f87656347dad7d7e1448ebc50d28d8f34f6da7992c43072d26942fd97c0134 WHIRLPOOL 8ccd7a3dfc49be2053e8c3f334ea348a3455bcb6f84a636cd531f15822abd3452cfa50cd0bca4295b1dc922897e38613cf5cb865e60b83e9e357af396f2d9c99 |
24 |
+DIST fftw-3.3.6-pl2.tar.gz 4185261 SHA256 a5de35c5c824a78a058ca54278c706cdf3d4abba1c56b63531c2cb05f5d57da2 SHA512 e130309856752a1555b6d151c4d0ce9eb4b2c208fff7e3e89282ca8ef6104718f865cbb5e9c4af4367b3615b69b0d50fd001a26d74fd5324ff2faabe14fe3472 WHIRLPOOL 92b55473e1aaca71e07869c12b5f0e9b94e21317c1d8e37c2f0ae5e4ff1bb803a7f8c8104ad52ede56211964a6374e4cb054809ca2df9b22306bb1ca89e2bfa7 |
25 |
|
26 |
diff --git a/sci-libs/fftw/fftw-3.3.6_p2.ebuild b/sci-libs/fftw/fftw-3.3.6_p2.ebuild |
27 |
new file mode 100644 |
28 |
index 00000000000..d8341392a97 |
29 |
--- /dev/null |
30 |
+++ b/sci-libs/fftw/fftw-3.3.6_p2.ebuild |
31 |
@@ -0,0 +1,180 @@ |
32 |
+# Copyright 1999-2017 Gentoo Foundation |
33 |
+# Distributed under the terms of the GNU General Public License v2 |
34 |
+ |
35 |
+EAPI=6 |
36 |
+ |
37 |
+FORTRAN_NEEDED=fortran |
38 |
+ |
39 |
+inherit flag-o-matic fortran-2 toolchain-funcs versionator multibuild multilib-minimal |
40 |
+ |
41 |
+DESCRIPTION="Fast C library for the Discrete Fourier Transform" |
42 |
+HOMEPAGE="http://www.fftw.org/" |
43 |
+ |
44 |
+MY_P=${PN}-${PV/_p/-pl} |
45 |
+ |
46 |
+if [[ ${PV} = *9999 ]]; then |
47 |
+ inherit autotools git-r3 |
48 |
+ EGIT_REPO_URI="https://github.com/FFTW/fftw3.git" |
49 |
+else |
50 |
+ SRC_URI="http://www.fftw.org/${PN}-${PV/_p/-pl}.tar.gz" |
51 |
+ KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sparc ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos" |
52 |
+fi |
53 |
+ |
54 |
+LICENSE="GPL-2+" |
55 |
+SLOT="3.0/3" |
56 |
+IUSE="altivec cpu_flags_x86_avx cpu_flags_x86_avx2 cpu_flags_x86_fma3 cpu_flags_x86_fma4 cpu_flags_x86_sse cpu_flags_x86_sse2 doc fortran mpi neon openmp quad static-libs test threads zbus" |
57 |
+ |
58 |
+RDEPEND=" |
59 |
+ mpi? ( >=virtual/mpi-2.0-r4[${MULTILIB_USEDEP}] )" |
60 |
+DEPEND="${RDEPEND} |
61 |
+ test? ( dev-lang/perl )" |
62 |
+ |
63 |
+S=${WORKDIR}/${MY_P} |
64 |
+HTML_DOCS=( doc/html/. ) |
65 |
+ |
66 |
+pkg_pretend() { |
67 |
+ [[ ${MERGE_TYPE} != binary ]] && use openmp && tc-check-openmp |
68 |
+} |
69 |
+ |
70 |
+pkg_setup() { |
71 |
+ if [[ ${MERGE_TYPE} != binary ]] && use openmp; then |
72 |
+ tc-check-openmp |
73 |
+ FORTRAN_NEED_OPENMP=1 |
74 |
+ fi |
75 |
+ |
76 |
+ fortran-2_pkg_setup |
77 |
+ |
78 |
+ MULTIBUILD_VARIANTS=( single double longdouble ) |
79 |
+ if use quad; then |
80 |
+ if ! tc-is-gcc; then |
81 |
+ ewarn "quad precision only available for gcc >= 4.6" |
82 |
+ die "need quad precision capable gcc" |
83 |
+ fi |
84 |
+ MULTIBUILD_VARIANTS+=( quad ) |
85 |
+ fi |
86 |
+} |
87 |
+ |
88 |
+src_prepare() { |
89 |
+ default |
90 |
+ |
91 |
+ # fix info file for category directory |
92 |
+ if [[ ${PV} = *9999 ]]; then |
93 |
+ sed -i -e |
94 |
+ 's/Texinfo documentation system/Libraries/' \ |
95 |
+ doc/fftw3."info" || die "failed to fix info file" |
96 |
+ |
97 |
+ eautoreconf |
98 |
+ fi |
99 |
+} |
100 |
+ |
101 |
+multilib_src_configure() { |
102 |
+ # jlec reported USE=quad on abi_x86_32 has too few registers |
103 |
+ # stub Makefiles |
104 |
+ if [[ ${MULTILIB_ABI_FLAG} == abi_x86_32 && ${MULTIBUILD_ID} == quad-* ]]; then |
105 |
+ mkdir -p "${BUILD_DIR}/tests" || die |
106 |
+ echo "all: ;" > "${BUILD_DIR}/Makefile" || die |
107 |
+ echo "install: ;" >> "${BUILD_DIR}/Makefile" || die |
108 |
+ echo "smallcheck: ;" > "${BUILD_DIR}/tests/Makefile" || die |
109 |
+ return 0 |
110 |
+ fi |
111 |
+ |
112 |
+ local myconf=( |
113 |
+ --enable-shared |
114 |
+ $(use_enable static-libs static) |
115 |
+ $(use_enable "cpu_flags_x86_fma$(usex cpu_flags_x86_fma3 3 4)" fma) |
116 |
+ $(use_enable fortran) |
117 |
+ $(use_enable zbus mips-zbus-timer) |
118 |
+ $(use_enable threads) |
119 |
+ $(use_enable openmp) |
120 |
+ ) |
121 |
+ case "${MULTIBUILD_ID}" in |
122 |
+ single-*) |
123 |
+ # altivec, sse, single-paired only work for single |
124 |
+ myconf+=( |
125 |
+ --enable-single |
126 |
+ $(use_enable altivec) |
127 |
+ $(use_enable cpu_flags_x86_avx avx) |
128 |
+ $(use_enable cpu_flags_x86_avx2 avx2) |
129 |
+ $(use_enable cpu_flags_x86_sse sse) |
130 |
+ $(use_enable cpu_flags_x86_sse2 sse2) |
131 |
+ $(use_enable neon) |
132 |
+ $(use_enable mpi) |
133 |
+ ) |
134 |
+ ;; |
135 |
+ |
136 |
+ double-*) |
137 |
+ myconf+=( |
138 |
+ $(use_enable cpu_flags_x86_avx avx) |
139 |
+ $(use_enable cpu_flags_x86_avx2 avx2) |
140 |
+ $(use_enable cpu_flags_x86_sse2 sse2) |
141 |
+ $(use_enable mpi) |
142 |
+ ) |
143 |
+ ;; |
144 |
+ |
145 |
+ longdouble-*) |
146 |
+ myconf+=( |
147 |
+ --enable-long-double |
148 |
+ $(use_enable mpi) |
149 |
+ ) |
150 |
+ ;; |
151 |
+ |
152 |
+ quad-*) |
153 |
+ # quad does not support mpi |
154 |
+ myconf+=( |
155 |
+ --enable-quad-precision |
156 |
+ ) |
157 |
+ ;; |
158 |
+ |
159 |
+ *) |
160 |
+ die "${MULTIBUILD_ID%-*} precision not implemented in this ebuild" |
161 |
+ ;; |
162 |
+ esac |
163 |
+ |
164 |
+ ECONF_SOURCE="${S}" econf "${myconf[@]}" MPICC="$(tc-getCC -lmpi)" |
165 |
+} |
166 |
+ |
167 |
+src_configure() { |
168 |
+ multibuild_foreach_variant multilib-minimal_src_configure |
169 |
+} |
170 |
+ |
171 |
+src_compile() { |
172 |
+ multibuild_foreach_variant multilib-minimal_src_compile |
173 |
+} |
174 |
+ |
175 |
+multilib_src_test() { |
176 |
+ emake -C tests smallcheck |
177 |
+} |
178 |
+ |
179 |
+src_test() { |
180 |
+ # We want this to be a reasonably quick test, but that is still hard... |
181 |
+ ewarn "This test series will take 30 minutes on a modern 2.5Ghz machine" |
182 |
+ # Do not increase the number of threads, it will not help your performance |
183 |
+ # local testbase="perl check.pl --nthreads=1 --estimate" |
184 |
+ # ${testbase} -${p}d || die "Failure: $n" |
185 |
+ |
186 |
+ multibuild_foreach_variant multilib-minimal_src_test |
187 |
+} |
188 |
+ |
189 |
+src_install() { |
190 |
+ multibuild_foreach_variant multilib-minimal_src_install |
191 |
+ dodoc CONVENTIONS |
192 |
+ |
193 |
+ if use doc; then |
194 |
+ dodoc doc/*.pdf |
195 |
+ docinto faq |
196 |
+ dodoc -r doc/FAQ/fftw-faq.html/. |
197 |
+ else |
198 |
+ rm -r "${ED%/}"/usr/share/doc/${PF}/html || die |
199 |
+ fi |
200 |
+ |
201 |
+ local x |
202 |
+ for x in "${ED%/}"/usr/lib*/pkgconfig/*.pc; do |
203 |
+ local u |
204 |
+ for u in $(usev mpi) $(usev threads) $(usex openmp omp ""); do |
205 |
+ sed -e "s|-lfftw3[flq]\?|&_${u} &|" "$x" > "${x%.pc}_${u}.pc" || die |
206 |
+ done |
207 |
+ done |
208 |
+ |
209 |
+ # fftw uses pkg-config to record its private dependencies |
210 |
+ find "${D}" -name '*.la' -delete || die |
211 |
+} |