Gentoo Archives: gentoo-commits

From: "Sebastien Fabbro (bicatali)" <bicatali@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in dev-python/numpy: ChangeLog numpy-1.0.3.1.ebuild
Date: Mon, 15 Oct 2007 14:44:58
Message-Id: E1IhQm3-0005zT-0i@stork.gentoo.org
1 bicatali 07/10/15 14:18:27
2
3 Modified: ChangeLog numpy-1.0.3.1.ebuild
4 Log:
5 Use the new virtual/cblas.
6 (Portage version: 2.1.3.12)
7
8 Revision Changes Path
9 1.37 dev-python/numpy/ChangeLog
10
11 file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-python/numpy/ChangeLog?rev=1.37&view=markup
12 plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-python/numpy/ChangeLog?rev=1.37&content-type=text/plain
13 diff : http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-python/numpy/ChangeLog?r1=1.36&r2=1.37
14
15 Index: ChangeLog
16 ===================================================================
17 RCS file: /var/cvsroot/gentoo-x86/dev-python/numpy/ChangeLog,v
18 retrieving revision 1.36
19 retrieving revision 1.37
20 diff -u -r1.36 -r1.37
21 --- ChangeLog 26 Aug 2007 21:27:50 -0000 1.36
22 +++ ChangeLog 15 Oct 2007 14:18:26 -0000 1.37
23 @@ -1,6 +1,9 @@
24 # ChangeLog for dev-python/numpy
25 # Copyright 1999-2007 Gentoo Foundation; Distributed under the GPL v2
26 -# $Header: /var/cvsroot/gentoo-x86/dev-python/numpy/ChangeLog,v 1.36 2007/08/26 21:27:50 bicatali Exp $
27 +# $Header: /var/cvsroot/gentoo-x86/dev-python/numpy/ChangeLog,v 1.37 2007/10/15 14:18:26 bicatali Exp $
28 +
29 + 15 Oct 2007; Sébastien Fabbro <bicatali@g.o> numpy-1.0.3.1.ebuild:
30 + Use the new virtual/cblas.
31
32 26 Aug 2007; Sébastien Fabbro <bicatali@g.o> -numpy-0.9.8.ebuild:
33 Removed old version
34
35
36
37 1.3 dev-python/numpy/numpy-1.0.3.1.ebuild
38
39 file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-python/numpy/numpy-1.0.3.1.ebuild?rev=1.3&view=markup
40 plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-python/numpy/numpy-1.0.3.1.ebuild?rev=1.3&content-type=text/plain
41 diff : http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-python/numpy/numpy-1.0.3.1.ebuild?r1=1.2&r2=1.3
42
43 Index: numpy-1.0.3.1.ebuild
44 ===================================================================
45 RCS file: /var/cvsroot/gentoo-x86/dev-python/numpy/numpy-1.0.3.1.ebuild,v
46 retrieving revision 1.2
47 retrieving revision 1.3
48 diff -u -r1.2 -r1.3
49 --- numpy-1.0.3.1.ebuild 24 Aug 2007 19:22:47 -0000 1.2
50 +++ numpy-1.0.3.1.ebuild 15 Oct 2007 14:18:26 -0000 1.3
51 @@ -1,6 +1,6 @@
52 # Copyright 1999-2007 Gentoo Foundation
53 # Distributed under the terms of the GNU General Public License v2
54 -# $Header: /var/cvsroot/gentoo-x86/dev-python/numpy/numpy-1.0.3.1.ebuild,v 1.2 2007/08/24 19:22:47 mr_bones_ Exp $
55 +# $Header: /var/cvsroot/gentoo-x86/dev-python/numpy/numpy-1.0.3.1.ebuild,v 1.3 2007/10/15 14:18:26 bicatali Exp $
56
57 NEED_PYTHON=2.3
58
59 @@ -14,11 +14,9 @@
60 HOMEPAGE="http://numeric.scipy.org/"
61
62 RDEPEND="!dev-python/f2py
63 - lapack? ( || ( >=sci-libs/blas-atlas-3.7.11-r1
64 - >=sci-libs/cblas-reference-20030223-r3 )
65 - virtual/lapack )"
66 + lapack? ( virtual/cblas virtual/lapack )"
67 DEPEND="${RDEPEND}
68 - lapack? ( app-admin/eselect-cblas )"
69 + lapack? ( dev-util/pkgconfig )"
70
71 IUSE="lapack"
72 SLOT="0"
73 @@ -35,37 +33,13 @@
74 [[ -n "${LDFLAGS_sav}" ]] && einfo "Ignoring LDFLAGS=${LDFLAGS_sav}"
75 }
76
77 -numpy_lapack_setup() {
78 - local mycblas
79 - for d in $(eselect cblas show); do mycblas=${d}; done
80 - if [[ -z "${mycblas/reference/}" ]] && [[ -z "${mycblas/atlas/}" ]]; then
81 - ewarn "You need to set cblas to atlas or reference. Do:"
82 - ewarn " eselect cblas set <impl>"
83 - ewarn "where <impl> is atlas, threaded-atlas or reference"
84 - die "numpy_lapack_setup failed"
85 - fi
86 -
87 - # Remove default values
88 - echo "[blas_opt]" > site.cfg
89 - case "${mycblas}" in
90 - reference)
91 - echo "include_dirs = /usr/include/cblas" >> site.cfg
92 - echo "libraries = blas, cblas" >> site.cfg
93 - unset BLAS
94 - ;;
95 - atlas|threaded-atlas)
96 - echo "include_dirs = /usr/include/atlas" >> site.cfg
97 - echo "libraries = blas, cblas, atlas" >> site.cfg
98 - unset ATLAS
99 - ;;
100 - *)
101 - eerror "Invalid cblas implementation: ${cblas}"
102 - die "numpy_lapack_setup failed"
103 - ;;
104 - esac
105 - echo "[lapack_opt]" >> site.cfg
106 - echo "libraries = lapack" >> site.cfg
107 - unset LAPACK
108 +# ex usage: pkgconf_cfg --libs-only-l cblas: ['cblas','atlas']
109 +pkgconf_cfg() {
110 + local cfg="["
111 + for i in $(pkg-config "$1" "$2"); do
112 + cfg="${cfg}'${i:2}'"
113 + done
114 + echo "${cfg//\'\'/','}]"
115 }
116
117 src_unpack() {
118 @@ -87,7 +61,19 @@
119 export ATLAS=None
120 export PTATLAS=None
121 export MKL=None
122 - use lapack && numpy_lapack_setup
123 +
124 + if use lapack; then
125 + unset BLAS LAPACK
126 + cat > setup.cfg << EOF
127 +[blas_opt]
128 +libraries = $(pkgconf_cfg --libs-only-l cblas)
129 +library_dirs = $(pkgconf_cfg --libs-only-L cblas)
130 +
131 +[lapack_opt]
132 +libraries = $(pkgconf_cfg --libs-only-l lapack)
133 +library_dirs = $(pkgconf_cfg --libs-only-L lapack)
134 +EOF
135 + fi
136 }
137
138 src_test() {
139 @@ -102,7 +88,7 @@
140 grep -q '^OK$' test.log || die "test failed"
141 popd
142
143 -_ rm -rf test
144 + rm -rf test
145 }
146
147 src_install() {
148
149
150
151 --
152 gentoo-commits@g.o mailing list