summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSebastien Fabbro <bicatali@gentoo.org>2007-11-12 16:55:03 +0000
committerSebastien Fabbro <bicatali@gentoo.org>2007-11-12 16:55:03 +0000
commit5ab86b2d714265ff872087b06bc3a093a5fada28 (patch)
treec85c21dd68a6f2b7a950256a2b68493b933db3a6 /dev-python
parentamd64 stable (diff)
downloadgentoo-2-5ab86b2d714265ff872087b06bc3a093a5fada28.tar.gz
gentoo-2-5ab86b2d714265ff872087b06bc3a093a5fada28.tar.bz2
gentoo-2-5ab86b2d714265ff872087b06bc3a093a5fada28.zip
Version bump.
(Portage version: 2.1.3.16)
Diffstat (limited to 'dev-python')
-rw-r--r--dev-python/numpy/ChangeLog8
-rw-r--r--dev-python/numpy/files/digest-numpy-1.0.23
-rw-r--r--dev-python/numpy/files/digest-numpy-1.0.43
-rw-r--r--dev-python/numpy/numpy-1.0.2.ebuild164
-rw-r--r--dev-python/numpy/numpy-1.0.4.ebuild111
5 files changed, 121 insertions, 168 deletions
diff --git a/dev-python/numpy/ChangeLog b/dev-python/numpy/ChangeLog
index 7d035dc7594d..8c05d55ee884 100644
--- a/dev-python/numpy/ChangeLog
+++ b/dev-python/numpy/ChangeLog
@@ -1,6 +1,12 @@
# ChangeLog for dev-python/numpy
# Copyright 1999-2007 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/dev-python/numpy/ChangeLog,v 1.38 2007/10/29 15:29:47 armin76 Exp $
+# $Header: /var/cvsroot/gentoo-x86/dev-python/numpy/ChangeLog,v 1.39 2007/11/12 16:55:02 bicatali Exp $
+
+*numpy-1.0.4 (12 Nov 2007)
+
+ 12 Nov 2007; Sébastien Fabbro <bicatali@gentoo.org> -numpy-1.0.2.ebuild,
+ +numpy-1.0.4.ebuild:
+ Version bump
29 Oct 2007; Raúl Porcel <armin76@gentoo.org> numpy-1.0.3.ebuild:
alpha stable wrt #180713
diff --git a/dev-python/numpy/files/digest-numpy-1.0.2 b/dev-python/numpy/files/digest-numpy-1.0.2
deleted file mode 100644
index 192a3b615bf2..000000000000
--- a/dev-python/numpy/files/digest-numpy-1.0.2
+++ /dev/null
@@ -1,3 +0,0 @@
-MD5 8be83678056ae31bfe641d35bbc181f4 numpy-1.0.2.tar.gz 1400121
-RMD160 e41ade8e070357cef5ea65f56ac883e0d3a5cef3 numpy-1.0.2.tar.gz 1400121
-SHA256 1f253c7482895f7ec95cb57f5f412eafcf3be23eaebdb7d1b7bbcc2c8a65c226 numpy-1.0.2.tar.gz 1400121
diff --git a/dev-python/numpy/files/digest-numpy-1.0.4 b/dev-python/numpy/files/digest-numpy-1.0.4
new file mode 100644
index 000000000000..2abfed99cb45
--- /dev/null
+++ b/dev-python/numpy/files/digest-numpy-1.0.4
@@ -0,0 +1,3 @@
+MD5 8f011e9d7697da570efaac61c51725e0 numpy-1.0.4.tar.gz 1547541
+RMD160 8ac192ad3f36a94a45c26e0c4028fdbb744881f5 numpy-1.0.4.tar.gz 1547541
+SHA256 b993ecc060aa2bdca9a45a552f4ea77d96959ce0f429d5f9019e05738d68c9bd numpy-1.0.4.tar.gz 1547541
diff --git a/dev-python/numpy/numpy-1.0.2.ebuild b/dev-python/numpy/numpy-1.0.2.ebuild
deleted file mode 100644
index 08ee50e6c825..000000000000
--- a/dev-python/numpy/numpy-1.0.2.ebuild
+++ /dev/null
@@ -1,164 +0,0 @@
-# Copyright 1999-2007 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/dev-python/numpy/numpy-1.0.2.ebuild,v 1.1 2007/04/05 10:32:11 bicatali Exp $
-
-NEED_PYTHON=2.3
-
-inherit distutils eutils fortran
-
-MY_P=${P/_beta/b}
-MY_P=${MY_P/_}
-DESCRIPTION="Python array processing for numbers, strings, records, and objects"
-SRC_URI="mirror://sourceforge/numpy/${MY_P}.tar.gz"
-HOMEPAGE="http://numeric.scipy.org/"
-
-RDEPEND="!dev-python/f2py
- lapack? ( || ( >=sci-libs/blas-atlas-3.7.11-r1
- >=sci-libs/cblas-reference-20030223-r3 )
- virtual/lapack )"
-DEPEND="${RDEPEND}
- lapack? ( app-admin/eselect-cblas )"
-
-IUSE="lapack"
-SLOT="0"
-KEYWORDS="~amd64 ~ppc ~ppc64 ~x86"
-LICENSE="BSD"
-
-S="${WORKDIR}/${MY_P}"
-
-FORTRAN="g77 gfortran"
-
-numpy_configure() {
- local mycblas
- if use lapack; then
- for d in $(eselect cblas show); do mycblas=${d}; done
- if [[ -z "${mycblas/reference/}" ]] && [[ -z "${mycblas/atlas/}" ]]; then
- ewarn "You need to set cblas to atlas or reference. Do:"
- ewarn " eselect cblas set <impl>"
- ewarn "where <impl> is atlas, threaded-atlas or reference"
- die "setup failed"
- fi
- fi
- [[ -z "${F77FLAGS}" ]] && F77FLAGS="${CFLAGS}"
- [[ -z "${FFLAGS}" ]] && FFLAGS="${F77FLAGS}"
-
- # remove default values
- echo "# gentoo config" > site.cfg
-
- export BLAS=None
- export LAPACK=None
- export ATLAS=None
- export PTATLAS=None
- export MKL=None
-
- if use lapack; then
- echo "[blas_opt]" >> site.cfg
- case "${mycblas}" in
- reference)
- echo "include_dirs = /usr/include/cblas" >> site.cfg
- echo "libraries = blas, cblas" >> site.cfg
- unset BLAS
- ;;
- atlas|threaded-atlas)
- echo "include_dirs = /usr/include/atlas" >> site.cfg
- echo "libraries = blas, cblas, atlas" >> site.cfg
- unset ATLAS
- ;;
- *)
- local msg="Invalid cblas implementation: ${cblas}"
- eerror "${msg}"
- die "${msg}"
- ;;
- esac
- echo "[lapack_opt]" >> site.cfg
- echo "libraries = lapack" >> site.cfg
- unset LAPACK
- fi
- # Map compilers to what numpy calls them (same as scipy)
- case "${FORTRANC}" in
- gfortran)
- NUMPY_FC="gnu95"
- ;;
- g77)
- NUMPY_FC="gnu"
- ;;
- g95)
- NUMPY_FC="g95"
- ;;
- ifc|ifort)
- if use ia64; then
- NUMPY_FC="intele"
- elif use amd64; then
- NUMPY_FC="intelem"
- else
- NUMPY_FC="intel"
- fi
- ;;
- *)
- local msg="Invalid Fortran compiler \'${FORTRANC}\'"
- eerror "${msg}"
- die "${msg}"
- ;;
- esac
- export NUMPY_FC
- # http://projects.scipy.org/scipy/numpy/ticket/182
- # Can't set LDFLAGS
- unset LDFLAGS
-}
-
-src_unpack() {
- fortran_src_unpack
- cd "${S}"
- # fix some paths and docs in f2py
- epatch "${FILESDIR}"/${PN}-1.0.1-f2py.patch
-
- # gentoo patch for ATLAS library names
- sed -i \
- -e "s:'f77blas':'blas':g" \
- -e "s:'ptblas':'blas':g" \
- -e "s:'ptcblas':'cblas':g" \
- -e "s:'lapack_atlas':'lapack':g" \
- numpy/distutils/system_info.py
-}
-
-src_compile() {
- numpy_configure
- distutils_src_compile \
- config_fc \
- --fcompiler=${NUMPY_FC} \
- --opt="${FFLAGS}"
-}
-
-src_test() {
- # see comment before the distutils_src_install
- numpy_configure
- ${python} setup.py install \
- --home="${S}"/test \
- --no-compile \
- config_fc \
- --fcompiler=${NUMPY_FC} \
- --opt="${FFLAGS}" || die "install test failed"
- pushd "${S}"/test/lib*/python
- PYTHONPATH=. "${python}" -c \
- "import numpy as n;import sys;sys.exit(n.test(10,3))" \
- > test.log 2>&1
- grep -q OK test.log || die "test failed"
- popd
- rm -rf test
-}
-
-src_install() {
- # we need to do the configuring again, for some reason, the
- # variables are not kept within setup.py functions
- numpy_configure
- distutils_src_install \
- config_fc \
- --fcompiler=${NUMPY_FC} \
- --opt="${FFLAGS}"
-
- docinto numpy
- dodoc numpy/doc/*txt
- docinto f2py
- dodoc numpy/f2py/docs/*txt
- doman numpy/f2py/f2py.1
-}
diff --git a/dev-python/numpy/numpy-1.0.4.ebuild b/dev-python/numpy/numpy-1.0.4.ebuild
new file mode 100644
index 000000000000..03f84fa7b49c
--- /dev/null
+++ b/dev-python/numpy/numpy-1.0.4.ebuild
@@ -0,0 +1,111 @@
+# Copyright 1999-2007 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/dev-python/numpy/numpy-1.0.4.ebuild,v 1.1 2007/11/12 16:55:02 bicatali Exp $
+
+NEED_PYTHON=2.3
+
+inherit distutils eutils
+
+MY_P=${P/_beta/b}
+MY_P=${MY_P/_}
+
+DESCRIPTION="Python array processing for numbers, strings, records, and objects"
+SRC_URI="mirror://sourceforge/numpy/${MY_P}.tar.gz"
+HOMEPAGE="http://numeric.scipy.org/"
+
+RDEPEND="!dev-python/f2py
+ lapack? ( virtual/cblas virtual/lapack )"
+DEPEND="${RDEPEND}
+ lapack? ( dev-util/pkgconfig )"
+
+IUSE="lapack"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~hppa ~ia64 ~ppc ~ppc64 ~sparc ~x86"
+LICENSE="BSD"
+
+S="${WORKDIR}/${MY_P}"
+
+# whatever LDFLAGS set will break linking
+# as reported in many tickets in http://projects.scipy.org/scipy/numpy
+LDFLAGS_sav="${LDFLAGS}"
+unset LDFLAGS
+pkg_setup() {
+ [[ -n "${LDFLAGS_sav}" ]] && einfo "Ignoring LDFLAGS=${LDFLAGS_sav}"
+}
+
+# ex usage: pkgconf_cfg --libs-only-l cblas: ['cblas','atlas']
+pkgconf_cfg() {
+ local cfg="["
+ for i in $(pkg-config "$1" "$2"); do
+ cfg="${cfg}'${i:2}'"
+ done
+ echo "${cfg//\'\'/','}]"
+}
+
+src_unpack() {
+ unpack ${A}
+ cd "${S}"
+ # Fix some paths and docs in f2py
+ epatch "${FILESDIR}"/${PN}-1.0.1-f2py.patch
+ # Gentoo patch for ATLAS library names
+ sed -i \
+ -e "s:'f77blas':'blas':g" \
+ -e "s:'ptblas':'blas':g" \
+ -e "s:'ptcblas':'cblas':g" \
+ -e "s:'lapack_atlas':'lapack':g" \
+ numpy/distutils/system_info.py \
+ || die "sed system_info.py failed"
+
+ export BLAS=None
+ export LAPACK=None
+ export ATLAS=None
+ export PTATLAS=None
+ export MKL=None
+
+ if use lapack; then
+ unset BLAS LAPACK
+ cat > setup.cfg << EOF
+[blas_opt]
+libraries = $(pkgconf_cfg --libs-only-l cblas)
+library_dirs = $(pkgconf_cfg --libs-only-L cblas)
+
+[lapack_opt]
+libraries = $(pkgconf_cfg --libs-only-l lapack)
+library_dirs = $(pkgconf_cfg --libs-only-L lapack)
+EOF
+ fi
+}
+
+src_test() {
+ "${python}" setup.py install \
+ --home="${S}"/test \
+ --no-compile \
+ || die "install test failed"
+
+ pushd "${S}"/test/lib*/python
+ PYTHONPATH=. "${python}" -c "import numpy; numpy.test(10,3)" 2>&1 \
+ | tee test.log
+ grep -q '^OK$' test.log || die "test failed"
+ popd
+
+ rm -rf test
+}
+
+src_install() {
+ distutils_src_install
+
+ docinto numpy
+ dodoc numpy/doc/*txt || die "dodoc failed"
+
+ docinto f2py
+ dodoc numpy/f2py/docs/*txt || die "dodoc f2py failed"
+ doman numpy/f2py/f2py.1 || die "doman failed"
+}
+
+pkg_postinst() {
+ if ! built_with_use sys-devel/gcc fortran && ! has_version dev-lang/ifc; then
+ ewarn "To use numpy's f2py you need a fortran compiler."
+ ewarn "You can either set USE=fortran flag and re-emerge gcc,"
+ ewarn "or emerge dev-lang/ifc"
+ fi
+}