[Numpy-discussion] Numpy compilation error

Pradeep Jha jhapk at utias.utoronto.ca
Fri Apr 30 10:01:36 EDT 2010


Thanks. That works.

2010/4/29 David Cournapeau <cournape at gmail.com>

> On Fri, Apr 30, 2010 at 5:23 AM, Pradeep Jha <jhapk at utias.utoronto.ca>
> wrote:
> > Hi,
> >
> > I have a few questions:
> >
> > 1)
> > I downloaded numpy1.3.0 and installed it in a directory using the command
> > python setup.py install --prefix=$HOME/src/numpy
> > and I see that numpy files have been generated in that directory.
> >
> > Now when I tried to install matplotlib, it complained that my numpy
> version
> > is 1.0.3
>
> That's because by default, python does not look into
> $HOME/src/numpy/.... You have several ways of controlling that, but
> the easy one is PYTHONPATH. This environment variable should contain
> your site-package, which is the $prefix/lib/python2.4/site-packages
> here where $prefix is what you gave to --prefix.
>
> PYTHONPATH is only on of the way to modify sys.path, which is what is
> used by python in the end:
>
> # python will only look for packages which are sys.path
> python -c "import sys; print sys.path"
>
> You can check the path of the package after import:
> python -c "import numpy; print numpy.__file__"
>
> David
> _______________________________________________
> NumPy-Discussion mailing list
> NumPy-Discussion at scipy.org
> http://mail.scipy.org/mailman/listinfo/numpy-discussion
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/numpy-discussion/attachments/20100430/731b5a51/attachment.html>


More information about the NumPy-Discussion mailing list