1 |
markusle 08/07/23 14:47:07 |
2 |
|
3 |
Modified: ChangeLog |
4 |
Added: lapack-atlas-3.9.1.ebuild |
5 |
Removed: lapack-atlas-3.9.0.ebuild |
6 |
Log: |
7 |
Version bump and further fixes to ilaenv patch. The latter now simply disables atlas' oldier version and uses the one in lapack-3.1.1 instead. |
8 |
(Portage version: 2.2_rc1/cvs/Linux 2.6.25-SENTINEL-5 i686) |
9 |
|
10 |
Revision Changes Path |
11 |
1.66 sci-libs/lapack-atlas/ChangeLog |
12 |
|
13 |
file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/sci-libs/lapack-atlas/ChangeLog?rev=1.66&view=markup |
14 |
plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/sci-libs/lapack-atlas/ChangeLog?rev=1.66&content-type=text/plain |
15 |
diff : http://sources.gentoo.org/viewcvs.py/gentoo-x86/sci-libs/lapack-atlas/ChangeLog?r1=1.65&r2=1.66 |
16 |
|
17 |
Index: ChangeLog |
18 |
=================================================================== |
19 |
RCS file: /var/cvsroot/gentoo-x86/sci-libs/lapack-atlas/ChangeLog,v |
20 |
retrieving revision 1.65 |
21 |
retrieving revision 1.66 |
22 |
diff -u -r1.65 -r1.66 |
23 |
--- ChangeLog 21 Jul 2008 13:44:27 -0000 1.65 |
24 |
+++ ChangeLog 23 Jul 2008 14:47:07 -0000 1.66 |
25 |
@@ -1,6 +1,16 @@ |
26 |
# ChangeLog for sci-libs/lapack-atlas |
27 |
# Copyright 2004-2008 Gentoo Foundation; Distributed under the GPL v2 |
28 |
-# $Header: /var/cvsroot/gentoo-x86/sci-libs/lapack-atlas/ChangeLog,v 1.65 2008/07/21 13:44:27 markusle Exp $ |
29 |
+# $Header: /var/cvsroot/gentoo-x86/sci-libs/lapack-atlas/ChangeLog,v 1.66 2008/07/23 14:47:07 markusle Exp $ |
30 |
+ |
31 |
+*lapack-atlas-3.9.1 (22 Jul 2008) |
32 |
+ |
33 |
+ 22 Jul 2008; Markus Dittrich <markusle@g.o> |
34 |
+ files/atlas-3.9.0-disable-ilaenv.patch, |
35 |
+ -files/atlas-3.9.0-upstream-fixes.patch, -lapack-atlas-3.9.0.ebuild, |
36 |
+ +lapack-atlas-3.9.1.ebuild: |
37 |
+ Version bump and further fixes to ilaenv patch. The latter now simply |
38 |
+ disables atlas' oldier version and uses the one in lapack-3.1.1 |
39 |
+ instead. |
40 |
|
41 |
*lapack-atlas-3.9.0 (20 Jul 2008) |
42 |
|
43 |
|
44 |
|
45 |
|
46 |
1.1 sci-libs/lapack-atlas/lapack-atlas-3.9.1.ebuild |
47 |
|
48 |
file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/sci-libs/lapack-atlas/lapack-atlas-3.9.1.ebuild?rev=1.1&view=markup |
49 |
plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/sci-libs/lapack-atlas/lapack-atlas-3.9.1.ebuild?rev=1.1&content-type=text/plain |
50 |
|
51 |
Index: lapack-atlas-3.9.1.ebuild |
52 |
=================================================================== |
53 |
# Copyright 1999-2008 Gentoo Foundation |
54 |
# Distributed under the terms of the GNU General Public License v2 |
55 |
# $Header: /var/cvsroot/gentoo-x86/sci-libs/lapack-atlas/lapack-atlas-3.9.1.ebuild,v 1.1 2008/07/23 14:47:07 markusle Exp $ |
56 |
|
57 |
inherit eutils flag-o-matic toolchain-funcs fortran autotools versionator |
58 |
|
59 |
MY_PN="${PN/lapack-/}" |
60 |
PATCH_V="3.9.0" |
61 |
L_PN="lapack" |
62 |
L_PV="3.1.1" |
63 |
BlasRelease=$(get_version_component_range 1-3) |
64 |
|
65 |
DESCRIPTION="F77 and C LAPACK implementations using available ATLAS routines" |
66 |
LICENSE="BSD" |
67 |
HOMEPAGE="http://math-atlas.sourceforge.net/" |
68 |
SRC_URI1="mirror://sourceforge/math-atlas/${MY_PN}${PV}.tar.bz2" |
69 |
SRC_URI2="http://www.netlib.org/${L_PN}/${L_PN}-lite-${L_PV}.tgz" |
70 |
SRC_URI="${SRC_URI1} ${SRC_URI2} |
71 |
mirror://gentoo/${MY_PN}-${PATCH_V}-shared-libs.patch.bz2" |
72 |
|
73 |
SLOT="0" |
74 |
IUSE="doc" |
75 |
KEYWORDS="~alpha ~amd64 ~ppc ~ppc64 ~sparc ~x86" |
76 |
|
77 |
CDEPEND="virtual/blas |
78 |
virtual/cblas |
79 |
app-admin/eselect-lapack |
80 |
~sci-libs/blas-atlas-${BlasRelease}" |
81 |
DEPEND="${CDEPEND} |
82 |
dev-util/pkgconfig |
83 |
>=sys-devel/libtool-1.5" |
84 |
RDEPEND="${CDEPEND} |
85 |
doc? ( app-doc/lapack-docs )" |
86 |
|
87 |
FORTRAN="g77 gfortran ifc" |
88 |
|
89 |
S="${WORKDIR}/ATLAS" |
90 |
S_LAPACK="${WORKDIR}/${L_PN}-lite-${L_PV}" |
91 |
BLD_DIR="${S}/gentoo-build" |
92 |
RPATH="${DESTTREE}/$(get_libdir)/${L_PN}/${MY_PN}" |
93 |
|
94 |
src_unpack() { |
95 |
unpack ${A} |
96 |
|
97 |
cd "${S}" |
98 |
epatch "${DISTDIR}"/${MY_PN}-${PATCH_V}-shared-libs.patch.bz2 |
99 |
epatch "${FILESDIR}"/${MY_PN}-asm-gentoo.patch |
100 |
epatch "${FILESDIR}"/${MY_PN}-${PATCH_V}-disable-ilaenv.patch |
101 |
|
102 |
# make sure the compile picks up the proper includes |
103 |
sed -i \ |
104 |
-e "s|INCLUDES.*=|INCLUDES = -I/usr/include/atlas/|" \ |
105 |
"${S}"/CONFIG/src/SpewMakeInc.c \ |
106 |
|| die "failed to append proper includes" |
107 |
|
108 |
BLD_DIR="${S}"/gentoo-build |
109 |
mkdir "${BLD_DIR}" || die "failed to generate build directory" |
110 |
cd "${BLD_DIR}" |
111 |
cp "${FILESDIR}"/war . && chmod a+x war || die "failed to install war" |
112 |
|
113 |
# force proper 32/64bit libs |
114 |
local archselect |
115 |
if use amd64 || use ppc64; then |
116 |
archselect="-b 64" |
117 |
elif use alpha; then |
118 |
archselect="" |
119 |
else |
120 |
archselect="-b 32" |
121 |
fi |
122 |
|
123 |
# unfortunately, atlas-3.9.0 chokes when passed |
124 |
# x86_64-pc-linux-gnu-gcc and friends instead of |
125 |
# plain gcc. Hence, we'll have to workaround this |
126 |
# until it is fixed by upstream |
127 |
local c_compiler=$(tc-getCC) |
128 |
if [[ "${c_compiler}" == *gcc* ]]; then |
129 |
c_compiler="gcc" |
130 |
fi |
131 |
|
132 |
../configure \ |
133 |
--cc="${c_compiler}" \ |
134 |
--cflags="${CFLAGS}" \ |
135 |
--prefix="${D}/${DESTTREE}" \ |
136 |
--libdir="${D}/${DESTTREE}"/$(get_libdir)/atlas \ |
137 |
--incdir="${D}/${DESTTREE}"/include \ |
138 |
-C ac "${c_compiler}" -F ac "${CFLAGS}" \ |
139 |
-C if ${FORTRANC} -F if "${FFLAGS:-'-O2'}" \ |
140 |
-Ss pmake "\$(MAKE) ${MAKEOPTS}" \ |
141 |
-Si cputhrchk 0 ${archselect} \ |
142 |
|| die "configure failed" |
143 |
|
144 |
cd "${S_LAPACK}" |
145 |
epatch "${FILESDIR}"/${L_PN}-reference-${L_PV}-autotools.patch |
146 |
epatch "${FILESDIR}"/${L_PN}-reference-${L_PV}-test-fix.patch |
147 |
eautoreconf |
148 |
|
149 |
# set up the testing routines |
150 |
sed -e "s:g77:${FORTRANC}:" \ |
151 |
-e "s:-funroll-all-loops -O3:${FFLAGS} $(pkg-config --cflags blas cblas):" \ |
152 |
-e "s:LOADOPTS =:LOADOPTS = ${LDFLAGS} $(pkg-config --cflags blas cblas):" \ |
153 |
-e "s:../../blas\$(PLAT).a:$(pkg-config --libs blas cblas):" \ |
154 |
-e "s:lapack\$(PLAT).a:SRC/.libs/liblapack.so -Wl,-rpath,${S_LAPACK}/SRC/.libs:" \ |
155 |
-e "s:EXT_ETIME$:INT_CPU_TIME:" \ |
156 |
make.inc.example > make.inc \ |
157 |
|| die "Failed to set up make.inc" |
158 |
} |
159 |
|
160 |
src_compile() { |
161 |
# build atlas' part of lapack |
162 |
cd "${BLD_DIR}" |
163 |
for d in src/lapack interfaces/lapack/C/src interfaces/lapack/F77/src interfaces/lapack/C2F/src; do |
164 |
cd "${BLD_DIR}"/${d} |
165 |
make lib || die "Failed to make lib in ${d}" |
166 |
done |
167 |
|
168 |
# build rest of lapack |
169 |
S_LAPACK="${WORKDIR}"/${L_PN}-lite-${L_PV} |
170 |
cd "${S_LAPACK}" |
171 |
econf || die "Failed to configure reference lapack lib" |
172 |
emake || die "Failed to make reference lapack lib" |
173 |
|
174 |
cd "${S_LAPACK}"/SRC |
175 |
einfo "Copying liblapack.a/*.o to ${S_LAPACK}/SRC" |
176 |
cp -sf "${BLD_DIR}"/gentoo/liblapack.a/*.o . |
177 |
einfo "Copying liblapack.a/*.lo to ${S_LAPACK}/SRC" |
178 |
cp -sf "${BLD_DIR}"/gentoo/liblapack.a/*.lo . |
179 |
einfo "Copying liblapack.a/.libs/*.o to ${S_LAPACK}/SRC" |
180 |
cp -sf "${BLD_DIR}"/gentoo/liblapack.a/.libs/*.o .libs/ |
181 |
|
182 |
RPATH="${DESTTREE}"/$(get_libdir)/${L_PN}/${MY_PN} |
183 |
local flibs |
184 |
[[ ${FORTRANC} == gfortran ]] && flibs=-lgfortran |
185 |
[[ ${FORTRANC} == g77 ]] && flibs=-lg2c |
186 |
../libtool --mode=link --tag=F77 ${FORTRANC} \ |
187 |
$(pkg-config --libs blas cblas) -latlas ${flibs} \ |
188 |
-o liblapack.la *.lo -rpath "${RPATH}" \ |
189 |
|| die "Failed to create liblapack.la" |
190 |
|
191 |
# making pkg-config file |
192 |
sed -e "s:@LIBDIR@:$(get_libdir):" \ |
193 |
-e "s:@PV@:${PV}:" \ |
194 |
-e "s:@EXTLIBS@:-lm ${flibs}:g" \ |
195 |
"${FILESDIR}"/lapack.pc.in > "${S}"/lapack.pc \ |
196 |
|| die "sed lapack.pc failed" |
197 |
} |
198 |
|
199 |
src_install () { |
200 |
dodir "${RPATH}" |
201 |
|
202 |
cd "${S_LAPACK}"/SRC |
203 |
../libtool --mode=install cp liblapack.la "${D}/${RPATH}" \ |
204 |
|| die "Failed to install lapack-atlas library" |
205 |
|
206 |
ESELECT_PROF=atlas |
207 |
eselect lapack add $(get_libdir) "${FILESDIR}"/eselect.lapack.atlas ${ESELECT_PROF} |
208 |
|
209 |
insinto /usr/include/atlas |
210 |
doins "${S}"/include/clapack.h || die "Failed to install clapack.h" |
211 |
dosym atlas/clapack.h /usr/include/clapack.h |
212 |
|
213 |
cd "${S}" |
214 |
dodoc README doc/AtlasCredits.txt doc/ChangeLog \ |
215 |
|| die "Failed to install docs" |
216 |
|
217 |
insinto /usr/$(get_libdir)/lapack/atlas |
218 |
doins "${S}"/lapack.pc || die "Failed to install lapack.pc" |
219 |
} |
220 |
|
221 |
src_test() { |
222 |
cd "${S_LAPACK}"/TESTING/MATGEN |
223 |
emake || die "Failed to create tmglib.a" |
224 |
cd .. |
225 |
emake || die "lapack-reference tests failed" |
226 |
} |
227 |
|
228 |
pkg_postinst() { |
229 |
local current_lib=$(eselect lapack show | cut -d' ' -f2) |
230 |
# this snippet works around the eselect bug #189942 and makes |
231 |
# sure that users upgrading from a previous lapack-atlas |
232 |
# version pick up the new pkg-config files |
233 |
if [[ ${current_lib} == ${ESELECT_PROF} || -z ${current_lib} ]]; then |
234 |
local configfile="${ROOT}"/etc/env.d/lapack/$(get_libdir)/config |
235 |
[[ -e ${configfile} ]] && rm -f ${configfile} |
236 |
eselect lapack set ${ESELECT_PROF} |
237 |
elog "lapack has been eselected to ${ESELECT_PROF}" |
238 |
else |
239 |
elog "Current eselected lapack is ${current_lib}" |
240 |
elog "To use blas ${ESELECT_PROF} implementation, you have to issue (as root):" |
241 |
elog "\t eselect lapack set ${ESELECT_PROF}" |
242 |
fi |
243 |
} |