From: Jonathan Guyer <guyer@ni...> - 2013-05-03 14:16:03
I am attempting to
pip install git+git://pysparse.git.sourceforge.net/gitroot/pysparse/pysparse#egg=pysparse
into a homebrew environment under Mac OS X Mountain Lion. (`pip install pysparse` is no better).
I get three errors:
pysparse/direct/superlu/src/colamd.c:547:12: error: conflicting types for 'colamd_recommended'
PUBLIC int colamd_recommended /* returns recommended value of Alen. */
/Users/guyer/.homebrew/include/colamd.h:140:8: note: previous declaration is here
size_t colamd_recommended /* returns recommended value of Alen, */
pysparse/direct/superlu/src/colamd.c:708:12: error: conflicting types for 'colamd'
PUBLIC int colamd /* returns TRUE if successful */
/Users/guyer/.homebrew/include/colamd.h:166:5: note: previous declaration is here
int colamd /* returns (1) if successful, (0) otherwise*/
pysparse/direct/superlu/src/colamd.c:815:8: error: use of undeclared identifier 'COLAMD_JUMBLED_COLS'
A [COLAMD_JUMBLED_COLS] = init_result ;
I have SuiteSparse 4.2.0 [*], but got the same errors before I upgraded from SuiteSparse 3.6.1.
[*] requirements.txt says 'OSX users using homebrew can simply say "brew install suitesparse".', but this does not appear to (any longer) be true. Homebrew presently has no suitesparse formula. What does work is:
brew tap homebrew/science
brew install suite-sparse
From: Jonathan Guyer <guyer@ni...> - 2013-06-03 17:17:07
On May 3, 2013, at 10:15 AM, Jonathan Guyer <guyer@...> wrote:
> I am attempting to
> pip install git+git://pysparse.git.sourceforge.net/gitroot/pysparse/pysparse#egg=pysparse
> into a homebrew environment under Mac OS X Mountain Lion. (`pip install pysparse` is no better).
> I get three errors:
I can now successfully pip install from the git repository. I was actually able to get it working a few days after I posted by using:
CFLAGS="" pip install git+git://pysparse.git.sourceforge.net/gitroot/pysparse/pysparse#egg=pysparse
This issue (at the time) was that some of the headers from suite-sparse were being found instead of the ones included with pysparse.
After several reconstructions of my Homebrew installation (for other reasons) I find I no longer need to pass `CFLAGS=""`. I don't know why it used to be necessary and now is not.
What does *not* work is
pip install pysparse
pysparse/sparse/src/spmatrixmodule.c:4:10: fatal error: 'spmatrix.h' file not found
The tarball at https://pypi.python.org/pypi/pysparse is incomplete (missing pysparse/includes is the one that raises the errors, but there is a bunch of other stuff missing) and the tarball does not seem to correspond to any revision in the git repository, e.g., pysparse/direct/setup.py has a number of uses of
that do not appear (specifically the inclusion of `cwd` in the join) anywhere in the git history.