Go to:
Gentoo Home
Documentation
Forums
Lists
Bugs
Planet
Store
Wiki
Get Gentoo!
Gentoo's Bugzilla – Attachment 126329 Details for
Bug 186913
dev-python/numpy-1.0.3 wrongly depends on fortran
Home
|
New
–
[Ex]
|
Browse
|
Search
|
Privacy Policy
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
Further cleanups
numpy-1.0.3.ebuild.clean (text/plain), 4.30 KB, created by
Vincent Legoll
on 2007-07-29 10:37:00 UTC
(
hide
)
Description:
Further cleanups
Filename:
MIME Type:
Creator:
Vincent Legoll
Created:
2007-07-29 10:37:00 UTC
Size:
4.30 KB
patch
obsolete
># 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.3.ebuild,v 1.12 2007/07/22 15:39:58 opfer 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 fortran" >SLOT="0" >KEYWORDS="~alpha amd64 hppa ia64 ppc ppc64 sparc x86" >LICENSE="BSD" > >S="${WORKDIR}/${MY_P}" > >lapack_configure() { > local mycblas > 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 > > export BLAS=None > export LAPACK=None > export ATLAS=None > export PTATLAS=None > export MKL=None > > # Remove default values > echo "# gentoo config" > site.cfg > 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 >} > >fortran_configure() { > [[ -z "${F77FLAGS}" ]] && F77FLAGS="${CFLAGS}" > [[ -z "${FFLAGS}" ]] && FFLAGS="${F77FLAGS}" > > # That was called at "inherit fortran" time, but this is now > # not done any more, look at pkg_setup() below > need_fortran "gfortran g77" > > # 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 >} > >linker_configure() { > if [[ -n "${LDFLAGS}" ]]; then > ewarn "Ignoring LDFLAGS=${LDFLAGS}, look at:" > ewarn "http://projects.scipy.org/scipy/numpy/ticket/182" > fi > unset LDFLAGS >} > >numpy_configure() { > use lapack && lapack_configure > use fortran && fortran_configure > linker_configure >} > >src_unpack() { > unpack ${A} > cd ${S} > > # Apply fortran compiler patches > use fortran && patch_fortran > > # 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" >} > >if use fortran; then > NUMPY_FORTRAN_CONFIG="config_fc --fcompiler=${NUMPY_FC} --opt=\"${FFLAGS}\"" >fi > >src_compile() { > # See comment before the distutils_src_install > numpy_configure > distutils_src_compile ${NUMPY_FORTRAN_CONFIG} >} > >src_test() { > # See comment before the distutils_src_install > numpy_configure > ${python} setup.py install \ > --home="${S}"/test \ > --no-compile \ > ${NUMPY_FORTRAN_CONFIG} || 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 >} > ># Horrible kludge to avoid fortran.eclass::fortran_pkg_setup() ># to be called by the global "inherit fortran" ># Suggested in: https://bugs.gentoo.org/show_bug.cgi?id=186913 >pkg_setup() { > true >} > >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 ${NUMPY_FORTRAN_CONFIG} > > docinto numpy > dodoc numpy/doc/*txt > docinto f2py > dodoc numpy/f2py/docs/*txt > doman numpy/f2py/f2py.1 >}
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Actions:
View
Attachments on
bug 186913
:
126326
|
126329
|
126331
|
126345