1 |
commit: 0684bbcc349805c36386ba78ac688882a4b6d7c3 |
2 |
Author: Justin Lecher <jlec <AT> gentoo <DOT> org> |
3 |
AuthorDate: Tue Dec 29 09:12:54 2015 +0000 |
4 |
Commit: Justin Lecher <jlec <AT> gentoo <DOT> org> |
5 |
CommitDate: Tue Dec 29 10:01:53 2015 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=0684bbcc |
7 |
|
8 |
sci-libs/mkl: Bump to EAPI=5 |
9 |
|
10 |
Package-Manager: portage-2.2.26 |
11 |
Signed-off-by: Justin Lecher <jlec <AT> gentoo.org> |
12 |
|
13 |
sci-libs/mkl/mkl-10.0.5.025.ebuild | 61 ++++++++++++++++++++------------------ |
14 |
1 file changed, 32 insertions(+), 29 deletions(-) |
15 |
|
16 |
diff --git a/sci-libs/mkl/mkl-10.0.5.025.ebuild b/sci-libs/mkl/mkl-10.0.5.025.ebuild |
17 |
index 794d067..4978b61 100644 |
18 |
--- a/sci-libs/mkl/mkl-10.0.5.025.ebuild |
19 |
+++ b/sci-libs/mkl/mkl-10.0.5.025.ebuild |
20 |
@@ -2,7 +2,9 @@ |
21 |
# Distributed under the terms of the GNU General Public License v2 |
22 |
# $Id$ |
23 |
|
24 |
-inherit eutils fortran-2 multilib toolchain-funcs check-reqs |
25 |
+EAPI=5 |
26 |
+ |
27 |
+inherit check-reqs eutils fortran-2 multilib toolchain-funcs |
28 |
|
29 |
PID=1232 |
30 |
PB=${PN} |
31 |
@@ -11,10 +13,11 @@ DESCRIPTION="Intel(R) Math Kernel Library: linear algebra, fft, math functions" |
32 |
HOMEPAGE="http://developer.intel.com/software/products/mkl/" |
33 |
SRC_URI="http://registrationcenter-download.intel.com/irc_nas/${PID}/l_${PN}_p_${PV}.tgz" |
34 |
|
35 |
-KEYWORDS="-* amd64 ~ia64 x86" |
36 |
SLOT="0" |
37 |
LICENSE="Intel-SDP" |
38 |
+KEYWORDS="-* amd64 ~ia64 x86" |
39 |
IUSE="doc fftw fortran95 int64 mpi" |
40 |
+ |
41 |
RESTRICT="strip mirror" |
42 |
|
43 |
DEPEND=" |
44 |
@@ -28,8 +31,7 @@ RDEPEND="${DEPEND} |
45 |
MKL_DIR=/opt/intel/${PN}/${PV} |
46 |
INTEL_LIC_DIR=/opt/intel/licenses |
47 |
|
48 |
-QA_EXECSTACK="opt/intel/${PN}/${PV}/*" |
49 |
-QA_TEXTRELS="opt/intel/${PN}/${PV}/*" |
50 |
+QA_PREBUILT="opt/intel/${PN}/${PV}/*" |
51 |
|
52 |
get_fcomp() { |
53 |
case $(tc-getFC) in |
54 |
@@ -86,12 +88,10 @@ pkg_setup() { |
55 |
get_fcomp |
56 |
} |
57 |
|
58 |
-src_unpack() { |
59 |
- |
60 |
- unpack ${A} |
61 |
- cd l_${PN}_*_${PV}/install |
62 |
+src_prepare() { |
63 |
+ cd l_${PN}_*_${PV}/install || die |
64 |
|
65 |
- cp ${MKL_LICENSE} "${WORKDIR}"/ |
66 |
+ cp ${MKL_LICENSE} "${WORKDIR}"/ || die |
67 |
MKL_LIC="$(basename ${MKL_LICENSE})" |
68 |
|
69 |
# binary blob extractor installs rpm leftovers in /opt/intel |
70 |
@@ -123,12 +123,12 @@ src_unpack() { |
71 |
die "extracting failed" |
72 |
fi |
73 |
# remove left over |
74 |
- rm -f /opt/intel/.*mkl*.log /opt/intel/intel_sdp_products.db |
75 |
+ rm -f /opt/intel/.*mkl*.log /opt/intel/intel_sdp_products.db || die |
76 |
|
77 |
# remove unused stuff and set up intel names |
78 |
- rm -rf "${WORKDIR}"/l_* |
79 |
+ rm -rf "${WORKDIR}"/l_* || die |
80 |
|
81 |
- cd "${S}" |
82 |
+ cd "${S}" || die |
83 |
# allow openmpi to work |
84 |
epatch "${FILESDIR}"/${PN}-10.0.2.018-openmpi.patch |
85 |
# make scalapack tests work for gfortran |
86 |
@@ -136,17 +136,17 @@ src_unpack() { |
87 |
case ${ARCH} in |
88 |
x86) MKL_ARCH=32 |
89 |
MKL_KERN=ia32 |
90 |
- rm -rf lib*/{em64t,64} |
91 |
+ rm -rf lib*/{em64t,64} || die |
92 |
;; |
93 |
|
94 |
amd64) MKL_ARCH=em64t |
95 |
MKL_KERN=em64t |
96 |
- rm -rf lib*/{32,64} |
97 |
+ rm -rf lib*/{32,64} || die |
98 |
;; |
99 |
|
100 |
ia64) MKL_ARCH=64 |
101 |
MKL_KERN=ipf |
102 |
- rm -rf lib*/{32,em64t} |
103 |
+ rm -rf lib*/{32,em64t} || die |
104 |
;; |
105 |
esac |
106 |
MKL_LIBDIR=${MKL_DIR}/lib/${MKL_ARCH} |
107 |
@@ -157,7 +157,7 @@ src_unpack() { |
108 |
} |
109 |
|
110 |
src_compile() { |
111 |
- cd "${S}"/interfaces |
112 |
+ cd "${S}"/interfaces || die |
113 |
if use fortran95; then |
114 |
einfo "Compiling fortan95 static lib wrappers" |
115 |
local myconf="lib${MKL_ARCH}" |
116 |
@@ -168,10 +168,11 @@ src_compile() { |
117 |
[[ $(tc-getFC) =~ gfortran ]] && \ |
118 |
myconf="${myconf} FOPTS=-fdefault-integer-8" |
119 |
fi |
120 |
+ local x |
121 |
for x in blas95 lapack95; do |
122 |
- pushd ${x} |
123 |
- emake ${myconf} || die "emake ${x} failed" |
124 |
- popd |
125 |
+ pushd ${x} > /dev/null || die |
126 |
+ emake ${myconf} |
127 |
+ popd > /dev/null || die |
128 |
done |
129 |
fi |
130 |
|
131 |
@@ -183,10 +184,11 @@ src_compile() { |
132 |
myconf="${myconf} mpi=${MKL_MPI}" |
133 |
fi |
134 |
einfo "Compiling fftw static lib wrappers" |
135 |
+ local x |
136 |
for x in ${fftwdirs}; do |
137 |
- pushd ${x} |
138 |
- emake ${myconf} || die "emake ${x} failed" |
139 |
- popd |
140 |
+ pushd ${x} > /dev/null || die |
141 |
+ emake ${myconf} |
142 |
+ popd > /dev/null || die |
143 |
done |
144 |
fi |
145 |
} |
146 |
@@ -214,7 +216,7 @@ src_test() { |
147 |
} |
148 |
|
149 |
mkl_make_generic_profile() { |
150 |
- cd "${S}" |
151 |
+ cd "${S}" || die |
152 |
# produce eselect files |
153 |
# don't make them in FILESDIR, it changes every major version |
154 |
cat > eselect.blas <<-EOF |
155 |
@@ -237,8 +239,9 @@ mkl_make_generic_profile() { |
156 |
|
157 |
# usage: mkl_add_profile <profile> <interface_lib> <thread_lib> <rtl_lib> |
158 |
mkl_add_profile() { |
159 |
- cd "${S}" |
160 |
+ cd "${S}" || die |
161 |
local prof=${1} |
162 |
+ local x |
163 |
for x in blas cblas lapack; do |
164 |
cat > ${x}-${prof}.pc <<-EOF |
165 |
prefix=${MKL_DIR} |
166 |
@@ -265,7 +268,7 @@ mkl_add_profile() { |
167 |
insinto ${MKL_LIBDIR} |
168 |
for x in blas cblas lapack; do |
169 |
doins ${x}-${prof}.pc |
170 |
- cp eselect.${x} eselect.${x}.${prof} |
171 |
+ cp eselect.${x} eselect.${x}.${prof} || die |
172 |
echo "${MKL_LIBDIR}/${x}-${prof}.pc /usr/@LIBDIR@/pkgconfig/${x}.pc" \ |
173 |
>> eselect.${x}.${prof} |
174 |
eselect ${x} add $(get_libdir) eselect.${x}.${prof} ${prof} |
175 |
@@ -273,12 +276,12 @@ mkl_add_profile() { |
176 |
} |
177 |
|
178 |
mkl_make_profiles() { |
179 |
- local clib |
180 |
- has_version 'dev-lang/ifc' && clib="intel" |
181 |
- built_with_use sys-devel/gcc fortran && clib="${clib} gf" |
182 |
+ local clib="gf" |
183 |
+ has_version 'dev-lang/ifc' && clib+=" intel" |
184 |
local slib="-lmkl_sequential" |
185 |
local rlib="-liomp5" |
186 |
local pbase=${PN} |
187 |
+ local c |
188 |
for c in ${clib}; do |
189 |
local ilib="-lmkl_${c}_lp64" |
190 |
use x86 && ilib="-lmkl_${c}" |
191 |
@@ -324,7 +327,7 @@ src_install() { |
192 |
LDPATH=${MKL_LIBDIR} |
193 |
MANPATH=${MKL_DIR}/man |
194 |
EOF |
195 |
- doenvd 35mkl || die "doenvd failed" |
196 |
+ doenvd 35mkl |
197 |
} |
198 |
|
199 |
pkg_postinst() { |