1 |
markusle 08/07/23 14:43:52 |
2 |
|
3 |
Modified: ChangeLog |
4 |
Added: blas-atlas-3.9.1.ebuild |
5 |
Removed: blas-atlas-3.9.0.ebuild |
6 |
Log: |
7 |
Version bump. |
8 |
(Portage version: 2.2_rc1/cvs/Linux 2.6.25-SENTINEL-5 i686) |
9 |
|
10 |
Revision Changes Path |
11 |
1.82 sci-libs/blas-atlas/ChangeLog |
12 |
|
13 |
file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/sci-libs/blas-atlas/ChangeLog?rev=1.82&view=markup |
14 |
plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/sci-libs/blas-atlas/ChangeLog?rev=1.82&content-type=text/plain |
15 |
diff : http://sources.gentoo.org/viewcvs.py/gentoo-x86/sci-libs/blas-atlas/ChangeLog?r1=1.81&r2=1.82 |
16 |
|
17 |
Index: ChangeLog |
18 |
=================================================================== |
19 |
RCS file: /var/cvsroot/gentoo-x86/sci-libs/blas-atlas/ChangeLog,v |
20 |
retrieving revision 1.81 |
21 |
retrieving revision 1.82 |
22 |
diff -u -r1.81 -r1.82 |
23 |
--- ChangeLog 21 Jul 2008 13:42:28 -0000 1.81 |
24 |
+++ ChangeLog 23 Jul 2008 14:43:51 -0000 1.82 |
25 |
@@ -1,6 +1,13 @@ |
26 |
# ChangeLog for sci-libs/blas-atlas |
27 |
# Copyright 2002-2008 Gentoo Foundation; Distributed under the GPL v2 |
28 |
-# $Header: /var/cvsroot/gentoo-x86/sci-libs/blas-atlas/ChangeLog,v 1.81 2008/07/21 13:42:28 markusle Exp $ |
29 |
+# $Header: /var/cvsroot/gentoo-x86/sci-libs/blas-atlas/ChangeLog,v 1.82 2008/07/23 14:43:51 markusle Exp $ |
30 |
+ |
31 |
+*blas-atlas-3.9.1 (22 Jul 2008) |
32 |
+ |
33 |
+ 22 Jul 2008; Markus Dittrich <markusle@g.o> |
34 |
+ -files/atlas-3.9.0-upstream-fixes.patch, -blas-atlas-3.9.0.ebuild, |
35 |
+ +blas-atlas-3.9.1.ebuild: |
36 |
+ Version bump. |
37 |
|
38 |
*blas-atlas-3.9.0 (20 Jul 2008) |
39 |
|
40 |
|
41 |
|
42 |
|
43 |
1.1 sci-libs/blas-atlas/blas-atlas-3.9.1.ebuild |
44 |
|
45 |
file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/sci-libs/blas-atlas/blas-atlas-3.9.1.ebuild?rev=1.1&view=markup |
46 |
plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/sci-libs/blas-atlas/blas-atlas-3.9.1.ebuild?rev=1.1&content-type=text/plain |
47 |
|
48 |
Index: blas-atlas-3.9.1.ebuild |
49 |
=================================================================== |
50 |
# Copyright 1999-2008 Gentoo Foundation |
51 |
# Distributed under the terms of the GNU General Public License v2 |
52 |
# $Header: /var/cvsroot/gentoo-x86/sci-libs/blas-atlas/blas-atlas-3.9.1.ebuild,v 1.1 2008/07/23 14:43:51 markusle Exp $ |
53 |
|
54 |
inherit eutils toolchain-funcs fortran multilib |
55 |
|
56 |
PATCH_V="3.9.0" |
57 |
|
58 |
DESCRIPTION="Automatically Tuned Linear Algebra Software BLAS implementation" |
59 |
HOMEPAGE="http://math-atlas.sourceforge.net/" |
60 |
MY_PN=${PN/blas-/} |
61 |
SRC_URI="mirror://sourceforge/math-atlas/${MY_PN}${PV}.tar.bz2 |
62 |
mirror://gentoo/${MY_PN}-${PATCH_V}-shared-libs.patch.bz2" |
63 |
|
64 |
LICENSE="BSD" |
65 |
SLOT="0" |
66 |
KEYWORDS="~alpha ~amd64 ~ppc ~ppc64 ~sparc ~x86" |
67 |
IUSE="doc" |
68 |
|
69 |
RDEPEND="app-admin/eselect-blas |
70 |
app-admin/eselect-cblas |
71 |
doc? ( app-doc/blas-docs )" |
72 |
DEPEND="app-admin/eselect-blas |
73 |
app-admin/eselect-cblas |
74 |
>=sys-devel/libtool-1.5" |
75 |
|
76 |
S="${WORKDIR}/ATLAS" |
77 |
|
78 |
pkg_setup() { |
79 |
# icc won't compile (as of icc-10.0.026) |
80 |
# and will blow out $PORTAGE_TMPDIR |
81 |
if [[ $(tc-getCC) = icc* ]]; then |
82 |
eerror "icc compiler is not supported with sci-libs/blas-atlas" |
83 |
die "blas-atlas won't compile with icc" |
84 |
fi |
85 |
|
86 |
FORTRAN="g77 gfortran ifc" |
87 |
fortran_pkg_setup |
88 |
echo |
89 |
ewarn "Please make sure to disable CPU throttling completely" |
90 |
ewarn "during the compile of blas-atlas. Otherwise, all atlas" |
91 |
ewarn "generated timings will be completely random and the" |
92 |
ewarn "performance of the resulting libraries will be degraded" |
93 |
ewarn "considerably." |
94 |
echo |
95 |
ewarn "For users of <=gcc-4.1 only:" |
96 |
ewarn "If you experience failing SANITY tests during" |
97 |
ewarn "atlas' compile please try passing -mfpmath=387; this" |
98 |
ewarn "option might also result in much better performance" |
99 |
ewarn "than using then sse instruction set depending on your" |
100 |
ewarn "CPU." |
101 |
echo |
102 |
epause 10 |
103 |
} |
104 |
|
105 |
src_unpack() { |
106 |
unpack ${A} |
107 |
|
108 |
cd "${S}" |
109 |
epatch "${DISTDIR}"/${MY_PN}-${PATCH_V}-shared-libs.patch.bz2 |
110 |
epatch "${FILESDIR}"/${MY_PN}-asm-gentoo.patch |
111 |
epatch "${FILESDIR}"/${MY_PN}-${PATCH_V}-decl-fix.patch |
112 |
|
113 |
BLD_DIR="${S}"/gentoo-build |
114 |
mkdir "${BLD_DIR}" || die "failed to generate build directory" |
115 |
cd "${BLD_DIR}" |
116 |
cp "${FILESDIR}"/war . && chmod a+x war || die "failed to install war" |
117 |
|
118 |
local archselect= |
119 |
if use amd64 || use ppc64; then |
120 |
archselect="-b 64" |
121 |
elif use alpha; then |
122 |
archselect="" |
123 |
else |
124 |
archselect="-b 32" |
125 |
fi |
126 |
|
127 |
# unfortunately, atlas-3.9.0 chokes when passed |
128 |
# x86_64-pc-linux-gnu-gcc and friends instead of |
129 |
# plain gcc. Hence, we'll have to workaround this |
130 |
# until it is fixed by upstream |
131 |
local c_compiler=$(tc-getCC) |
132 |
if [[ "${c_compiler}" == *gcc* ]]; then |
133 |
c_compiler="gcc" |
134 |
fi |
135 |
|
136 |
../configure \ |
137 |
--cc="${c_compiler}" \ |
138 |
--cflags="${CFLAGS}" \ |
139 |
--prefix="${D}/${DESTTREE}" \ |
140 |
--libdir="${D}/${DESTTREE}"/$(get_libdir)/atlas \ |
141 |
--incdir="${D}/${DESTTREE}"/include \ |
142 |
-C ac "${c_compiler}" -F ac "${CFLAGS}" \ |
143 |
-C if ${FORTRANC} -F if "${FFLAGS:-'-O2'}" \ |
144 |
-Ss pmake "\$(MAKE) ${MAKEOPTS}" \ |
145 |
-Si cputhrchk 0 ${archselect} \ |
146 |
|| die "configure failed" |
147 |
} |
148 |
|
149 |
src_compile() { |
150 |
cd "${BLD_DIR}" |
151 |
|
152 |
# atlas does its own parallel builds |
153 |
emake -j1 || die "emake failed" |
154 |
|
155 |
RPATH="${DESTTREE}"/$(get_libdir)/blas |
156 |
make \ |
157 |
LIBDIR=$(get_libdir) \ |
158 |
RPATH="${RPATH}"/atlas \ |
159 |
shared || die "failed to build shared libraries" |
160 |
|
161 |
# build shared libraries of threaded libraries if applicable |
162 |
if [[ -d gentoo/libptcblas.a ]]; then |
163 |
make \ |
164 |
LIBDIR=$(get_libdir) \ |
165 |
RPATH="${RPATH}"/threaded-atlas \ |
166 |
ptshared || die "failed to build threaded shared libraries" |
167 |
fi |
168 |
} |
169 |
|
170 |
src_test() { |
171 |
# make check does not work because |
172 |
# we don't build lapack libs |
173 |
for i in F77 C; do |
174 |
einfo "Testing ${i} interface" |
175 |
cd "${BLD_DIR}"/interfaces/blas/${i}/testing |
176 |
make sanity_test || die "emake tests for ${i} failed" |
177 |
if [[ -d "${BLD_DIR}"/gentoo/libptf77blas.a ]]; then |
178 |
make ptsanity_test || die "emake tests threaded for ${i}failed" |
179 |
fi |
180 |
done |
181 |
echo "Timing ATLAS" |
182 |
cd "${BLD_DIR}" |
183 |
emake time || die "emake time failed" |
184 |
} |
185 |
|
186 |
src_install () { |
187 |
dodir "${RPATH}"/atlas |
188 |
cd "${BLD_DIR}"/gentoo/libs |
189 |
cp -P libatlas* "${D}/${DESTTREE}"/$(get_libdir) \ |
190 |
|| die "Failed to install libatlas" |
191 |
|
192 |
# pkgconfig files |
193 |
local extlibs="-lm" |
194 |
local threadlibs |
195 |
[[ ${FORTRANC} == gfortran ]] && extlibs="${extlibs} -lgfortran" |
196 |
[[ ${FORTRANC} == g77 ]] && extlibs="${extlibs} -lg2c" |
197 |
cp "${FILESDIR}"/blas.pc.in blas.pc |
198 |
cp "${FILESDIR}"/cblas.pc.in cblas.pc |
199 |
sed -i \ |
200 |
-e "s:@LIBDIR@:$(get_libdir):" \ |
201 |
-e "s:@PV@:${PV}:" \ |
202 |
-e "s:@EXTLIBS@:${extlibs}:g" \ |
203 |
-e "s:@THREADLIBS@:${threadlibs}:g" \ |
204 |
*blas.pc || die "sed *blas.pc failed" |
205 |
|
206 |
cp -P *blas* "${D}/${RPATH}"/atlas \ |
207 |
|| die "Failed to install blas/cblas" |
208 |
|
209 |
ESELECT_PROF=atlas |
210 |
eselect blas add $(get_libdir) "${FILESDIR}"/eselect.blas.atlas ${ESELECT_PROF} |
211 |
eselect cblas add $(get_libdir) "${FILESDIR}"/eselect.cblas.atlas ${ESELECT_PROF} |
212 |
|
213 |
if [[ -d "${BLD_DIR}"/gentoo/threaded-libs ]]; then |
214 |
dodir "${RPATH}"/threaded-atlas |
215 |
cd "${BLD_DIR}"/gentoo/threaded-libs |
216 |
|
217 |
# pkgconfig files |
218 |
cp "${FILESDIR}"/blas.pc.in blas.pc |
219 |
cp "${FILESDIR}"/cblas.pc.in cblas.pc |
220 |
threadlibs="-lpthread" |
221 |
sed -i \ |
222 |
-e "s:@LIBDIR@:$(get_libdir):" \ |
223 |
-e "s:@PV@:${PV}:" \ |
224 |
-e "s:@EXTLIBS@:${extlibs}:g" \ |
225 |
-e "s:@THREADLIBS@:${threadlibs}:g" \ |
226 |
*blas.pc || die "sed *blas.pc failed" |
227 |
|
228 |
cp -P * "${D}/${RPATH}"/threaded-atlas \ |
229 |
|| die "Failed to install threaded atlas" |
230 |
ESELECT_PROF=atlas-threads |
231 |
|
232 |
eselect blas add $(get_libdir) "${FILESDIR}"/eselect.blas.threaded-atlas ${ESELECT_PROF} |
233 |
eselect cblas add $(get_libdir) "${FILESDIR}"/eselect.cblas.threaded-atlas ${ESELECT_PROF} |
234 |
fi |
235 |
|
236 |
insinto "${DESTTREE}"/include/atlas |
237 |
doins \ |
238 |
"${S}"/include/cblas.h \ |
239 |
"${S}"/include/atlas_misc.h \ |
240 |
"${S}"/include/atlas_enum.h \ |
241 |
|| die "failed to install headers" |
242 |
|
243 |
# These headers contain the architecture-specific |
244 |
# optimizations determined by ATLAS. The atlas-lapack build |
245 |
# is much shorter if they are available, so save them: |
246 |
doins "${BLD_DIR}"/include/*.h \ |
247 |
|| die "failed to install timing headers" |
248 |
|
249 |
# some docs |
250 |
cd "${S}"/doc |
251 |
dodoc INDEX.txt AtlasCredits.txt ChangeLog || die "dodoc failed" |
252 |
# atlas specific doc (blas generic docs installed by blas-docs) |
253 |
if use doc; then |
254 |
insinto /usr/share/doc/${PF} |
255 |
doins atlas*pdf cblasqref.pdf || die "doins docs failed" |
256 |
fi |
257 |
} |
258 |
|
259 |
pkg_postinst() { |
260 |
for p in blas cblas; do |
261 |
local current_p=$(eselect ${p} show | cut -d' ' -f2) |
262 |
# this snippet works around the eselect bug #189942 and makes |
263 |
# sure that users upgrading from a previous blas-atlas |
264 |
# version pick up the new pkg-config files |
265 |
if [[ ${current_p} == ${ESELECT_PROF} \ |
266 |
|| ${current_p} == "threaded-atlas" \ |
267 |
|| -z ${current_p} ]]; then |
268 |
local configfile="${ROOT}"/etc/env.d/${p}/$(get_libdir)/config |
269 |
[[ -e ${configfile} ]] && rm -f ${configfile} |
270 |
eselect ${p} set ${ESELECT_PROF} |
271 |
elog "${p} has been eselected to ${ESELECT_PROF}" |
272 |
else |
273 |
elog "Current eselected ${p} is ${current_p}" |
274 |
elog "To use the ${p} ${ESELECT_PROF} implementation, you have to issue (as root):" |
275 |
elog "\t eselect ${p} set ${ESELECT_PROF}" |
276 |
fi |
277 |
done |
278 |
} |