Gentoo Archives: gentoo-alt

From: Michael Yang <yangofzeal@×××××.com>
To: gentoo-alt@l.g.o
Subject: Re: [gentoo-alt] numpy-1.3.0 problems with freebsd-7.2
Date: Tue, 28 Jul 2009 04:23:33
Message-Id: 2125c95f0907272123i149ddf4ej810575ceed6c1497@mail.gmail.com
In Reply to: Re: [gentoo-alt] numpy-1.3.0 problems with freebsd-7.2 by Fabian Groffen
1 > either your manual build uses the host compiler/linker, or it includes
2 > an -Ipath/to/var/tmp/portage/numpy/work/include
3
4 I checked the environment file and couldn't really figure out where
5 the various -I include flags were being defined. In any case, I
6 noticed that the ebuild compile command that fails is:
7
8 i686-pc-freebsd7.2-gcc -pthread -DNDEBUG -O2 -pipe -fPIC
9 -Ibuild/src.freebsd-7.2-RELEASE-i386-2.6/numpy/core/src
10 -Inumpy/core/include
11 -Ibuild/src.freebsd-7.2-RELEASE-i386-2.6/numpy/core/include/numpy
12 -Inumpy/core/src -Inumpy/core/include
13 -I/home/michael/gentoo/usr/include/python2.6 -c
14 build/src.freebsd-7.2-RELEASE-i386-2.6/numpy/core/src/umathmodule.c -o
15 build/temp.freebsd-7.2-RELEASE-i386-2.6/build/src.freebsd-7.2-RELEASE-i386-2.6/numpy/core/src/umathmodule.o
16
17 ...adding an additional -Inumpy/core/include/numpy/fenv (where fenv.h
18 with the numpy distribution) enables successful compilation, avoiding
19 pulling in /usr/include/fenv.h
20
21 Since I unfortunately lack the effort to dig around in the original
22 ebuild/numpy/python scripts, I made a single-line change to the
23 numpy-1.3.0.ebuild file:
24
25 --- numpy-1.3.0.ebuild.orig 2009-07-28 04:01:47 -0400
26 +++ numpy-1.3.0.ebuild 2009-07-28 04:07:27 -0400
27 @@ -48,6 +48,9 @@
28 epatch "${FILESDIR}/${P}-parisc.patch" # bug 277438
29 epatch "${FILESDIR}/${P}-alpha.patch" # bug 277438
30
31 + # copy numpy/core/include/numpy/fenv/fenv.h to numpy/core/include
32 + cp ${S}/numpy/core/include/numpy/fenv/fenv.h ${S}/numpy/core/include
33 +
34 # Gentoo patch for ATLAS library names
35 sed -i \
36 -e "s:'f77blas':'blas':g" \
37
38 which just copies the fenv.h to the numpy/core/include directory so
39 that -Inumpy/core/include will pick it up. This is a hack but
40 whatever, it works in my overlay. I'm open to better practices and
41 perhaps a solution that will throw the proper
42 -Inumpy/core/include/numpy/fenv into the build process.

Replies

Subject Author
Re: [gentoo-alt] numpy-1.3.0 problems with freebsd-7.2 Fabian Groffen <grobian@g.o>