[SciPy-user] problem building svn scipy

Damian Eads eads at soe.ucsc.edu
Fri Apr 25 20:19:04 EDT 2008


Hi there,

The hierarchy_wrap.c file is code I wrote and Chris Burns checked in. I 
did not try to compile it with an earlier version of gcc. Sorry about that.

$ gcc --version
gcc (GCC) 4.1.2 20070925 (Red Hat 4.1.2-33)
$

I will log-in to a machine with gcc-3.4.1 and try recompiling. I hope to 
have a fix soon.

Robert: interesting catch. I could try renaming CS, _X, and _dm. Let me 
try reproducing this compiler error on a machine with the gcc version 
John is using.

Damian


On Fri, Apr 25, 2008 at 9:28 AM, John Hunter <jdh2358 at gmail.com> wrote:
 > With numpy r5083 and scipy r4176 I am getting the following build error
 >
 >  building 'scipy.cluster._hierarchy_wrap' extension
 >  compiling C sources
 >  C compiler: /opt/app/g++lib6/gcc-3.4/bin/gcc -fno-strict-aliasing
 >  -DNDEBUG -g -O3 -Wall -Wstrict-prototypes -fPIC
 >
 >  compile options:
 >  '-I/home/titan/johnh/dev/lib/python2.4/site-packages/numpy/core/include
 >  -I/home/titan/johnh/dev/lib/python2.4/site-packages/numpy/core/include
 >  -I/opt/app/g++lib6/python-2.4/include/python2.4 -c'
 >  gcc: scipy/cluster/src/hierarchy_wrap.c
 >  scipy/cluster/src/hierarchy_wrap.c: In function 
`calculate_cluster_sizes_wrap':
 >  scipy/cluster/src/hierarchy_wrap.c:117: error: parse error before
 >  numeric constant
 >  scipy/cluster/src/hierarchy_wrap.c:120: error: invalid lvalue in 
unary `&'
 >  scipy/cluster/src/hierarchy_wrap.c:124: error: invalid type argument 
of `->'

It looks like something is #defining CS to be a number. Search through
the headers for this.

 >  scipy/cluster/src/hierarchy_wrap.c: In function
 >  `cluster_maxclust_monocrit_wrap':
 >  scipy/cluster/src/hierarchy_wrap.c:251: warning: unused variable 
`cutoff'
 >  scipy/cluster/src/hierarchy_wrap.c: In function `pdist_euclidean_wrap':
 >  scipy/cluster/src/hierarchy_wrap.c:387: error: parse error before
 >  numeric constant

Possibly the same thing with _X or _dm. Are there any more errors
following this?

-- 
Robert Kern

"I have come to believe that the whole world is an enigma, a harmless
enigma that is made terrible by our own mad attempt to interpret it as
though it had an underlying truth."
  -- Umberto Eco




More information about the SciPy-User mailing list