|
Boost Users : |
Subject: Re: [Boost-users] boost/numeric/ublas/matrix_sparse.hpp does not play well with RICE
From: John O. Woods (john.woods_at_[hidden])
Date: 2010-05-21 15:49:41
I have partially resolved the issue. I deleted all boost libraries and
headers from my machine and clean re-compiled and installed 1.43.
I can now compile with unordered_map successfully. I suspect the compiler
was using one version of the libraries and a different version of the
headers.
Unfortunately, I still cannot #include
<boost/numeric/ublas/matrix_sparse.hpp> while also including rice/Data_Type
and rice/Constructor. The #undefs Steven recommended don't appear to make a
difference.
I've included the current code below. It compiles perfectly if I comment the
first line. If I replace the Data_Type.hpp header with a different rice
header, it still doesn't work -- I've tried Class.hpp, String.hpp,
Object.hpp, and Constructor.hpp.
FYI, here's the address for rice: http://rice.rubyforge.org/main.html
Thanks again,
John
#include <rice/Data_Type.hpp>
#include <boost/numeric/ublas/matrix_sparse.hpp>
int main() { return 0; }
$ make
g++ -I. -I. -I/usr/lib/ruby/1.8/i486-linux -I. -D_FILE_OFFSET_BITS=64
-I/usr/lib/ruby/gems/1.8/gems/rice-1.3.2/ruby/lib/include -fPIC
-fno-strict-aliasing -g -g -O2 -fPIC -Wall -g -c main.cpp
In file included from
/usr/local/include/boost/numeric/ublas/storage_sparse.hpp:23,
from
/usr/local/include/boost/numeric/ublas/vector_sparse.hpp:16,
from
/usr/local/include/boost/numeric/ublas/matrix_sparse.hpp:16,
from main.cpp:2:
/usr/local/include/boost/numeric/ublas/storage.hpp:60: error: expected
primary-expression before ) token
/usr/local/include/boost/numeric/ublas/storage.hpp:65: error: expected
primary-expression before ) token
/usr/local/include/boost/numeric/ublas/storage.hpp:79: error: expected
primary-expression before ) token
/usr/local/include/boost/numeric/ublas/storage.hpp: In member function
typename ALLOC::size_type boost::numeric::ublas::unbounded_array<T,
ALLOC>::max_size() const:
/usr/local/include/boost/numeric/ublas/storage.hpp:174: error: expected
primary-expression before ) token
/usr/local/include/boost/numeric/ublas/storage.hpp:174: error: expected ;
before ruby_xmalloc
/usr/local/include/boost/numeric/ublas/storage.hpp:174: error: expected
primary-expression before ) token
/usr/local/include/boost/numeric/ublas/storage.hpp: In member function
typename ALLOC::size_type boost::numeric::ublas::bounded_array<T, N,
ALLOC>::max_size() const:
/usr/local/include/boost/numeric/ublas/storage.hpp:357: error: expected
primary-expression before ) token
/usr/local/include/boost/numeric/ublas/storage.hpp:357: error: expected ;
before ruby_xmalloc
/usr/local/include/boost/numeric/ublas/storage.hpp:357: error: expected
primary-expression before ) token
In file included from
/usr/local/include/boost/numeric/ublas/vector_sparse.hpp:16,
from
/usr/local/include/boost/numeric/ublas/matrix_sparse.hpp:16,
from main.cpp:2:
/usr/local/include/boost/numeric/ublas/storage_sparse.hpp: At global scope:
/usr/local/include/boost/numeric/ublas/storage_sparse.hpp:240: error:
expected primary-expression before ) token
make: *** [main.o] Error 1
Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net