← Back to team overview

dolfin team mailing list archive

Re: Compilation problems (libxml2, MTL4)

 



Harish Narayanan wrote:
I'm running to a couple of errors compiling DOLFIN on Mac OS X. One
problem pertains to libxml2. I receive the following error:

dolfin/io/XMLFile.cpp: In member function ‘void
dolfin::XMLFile::validate(std::string)’:
dolfin/io/XMLFile.cpp:87: error: ‘xmlRelaxNGSetParserStructuredErrors’
was not declared in this scope
dolfin/io/XMLFile.cpp:92: error: ‘xmlRelaxNGSetValidStructuredErrors’
was not declared in this scope
mpic++ -o dolfin/io/XMLHandler.os -c -Wall -pipe -ansi -DNDEBUG -O3
-DHAS_MPI=1 -DMPICH_IGNORE_CXX_SEEK -DPACKAGE_VERSION=\"0.9.2\"
-DHAS_PETSC=1 -DHAS_SLEPC=1 -DHAS_SCOTCH=1 -DHAS_UMFPACK=1 -DHAS_GTS=1
-DHAS_TRILINOS=1 -DHAS_CHOLMOD=1 -DHAS_MTL4=1 -DHAS_PARMETIS=1
-DHAS_GMP=1 -fno-strict-aliasing -fPIC -I. -I/unstable/build/include
-I/sw/include -I/sw/include -I/sw/include -I/usr/include/libxml2
-I/unstable/build/darwin9.2.0-cxx-opt/include -I/unstable/build/include
-I/sw/include -I/sw/lib/openmpi -I/unstable/build
-I/unstable/build/include -I/unstable/build/darwin9.2.0-cxx-opt/include
-I/sw/include -I/sw/lib/openmpi -I/unstable/build/include
-I/sw/include/suitesparse -I/sw/include -I/sw/include/glib-2.0
-I/sw/lib/glib-2.0/include -I/unstable/build/include
-I/sw/include/suitesparse -I/unstable/mtl4 -I/sw/include
-I/unstable/build/include -I/unstable/build/include dolfin/io/XMLHandler.cpp
scons: *** [dolfin/io/XMLFile.os] Error 1
scons: building terminated because of errors.
dolfin/io/XMLFile.os failed: Error 1

What version of libxml2 (or whatever else) does one need to get this
RelaxNG stuff working?


Pull the latest changes and try again.

The second problem relates to MTL4. I've recently started to receive the
following error when attempting to build DOLFIN, even after checking out
a recent MTL4.

/unstable/mtl4/boost/numeric/mtl/matrix/compressed2D.hpp: In member
function ‘mtl::matrix::compressed2D_inserter<Elt, Parameters, Updater>&
mtl::matrix::compressed2D_inserter<Value, Parameters,
Updater>::sorted_block_insertion(const
mtl::matrix::element_matrix_t<EMatrix, Rows, Cols>&) [with Matrix =
mtl::matrix::dense2D<double,
mtl::matrix::parameters<mtl::tag::row_major, mtl::index::c_index,
mtl::non_fixed::dimensions, false> >, Rows =
mtl::vector::dense_vector<dolfin::uint,
mtl::vector::parameters<mtl::tag::col_major,
mtl::vector::non_fixed::dimension, false, false> >, Cols =
mtl::vector::dense_vector<dolfin::uint,
mtl::vector::parameters<mtl::tag::col_major,
mtl::vector::non_fixed::dimension, false, false> >, Elt = double,
Parameters = mtl::matrix::parameters<mtl::tag::row_major,
mtl::index::c_index, mtl::non_fixed::dimensions, false>, Updater =
mtl::operations::update_plus<double>]’:
/unstable/mtl4/boost/numeric/mtl/matrix/compressed2D.hpp:544:
instantiated from ‘mtl::matrix::compressed2D_inserter<Value, Parameters,
Updater>& mtl::matrix::compressed2D_inserter<Value, Parameters,
Updater>::operator<<(const mtl::matrix::element_matrix_t<EMatrix, Rows,
Cols>&) [with Matrix = mtl::matrix::dense2D<double,
mtl::matrix::parameters<mtl::tag::row_major, mtl::index::c_index,
mtl::non_fixed::dimensions, false> >, Rows =
mtl::vector::dense_vector<dolfin::uint,
mtl::vector::parameters<mtl::tag::col_major,
mtl::vector::non_fixed::dimension, false, false> >, Cols =
mtl::vector::dense_vector<dolfin::uint,
mtl::vector::parameters<mtl::tag::col_major,
mtl::vector::non_fixed::dimension, false, false> >, Elt = double,
Parameters = mtl::matrix::parameters<mtl::tag::row_major,
mtl::index::c_index, mtl::non_fixed::dimensions, false>, Updater =
mtl::operations::update_plus<double>]’
/unstable/mtl4/boost/numeric/mtl/matrix/compressed2D.hpp:557:
instantiated from ‘mtl::matrix::compressed2D_inserter<Value, Parameters,
Updater>& mtl::matrix::compressed2D_inserter<Value, Parameters,
Updater>::operator<<(const mtl::matrix::element_array_t<EMatrix, Rows,
Cols>&) [with Matrix = mtl::matrix::dense2D<double,
mtl::matrix::parameters<mtl::tag::row_major, mtl::index::c_index,
mtl::non_fixed::dimensions, false> >, Rows =
mtl::vector::dense_vector<dolfin::uint,
mtl::vector::parameters<mtl::tag::col_major,
mtl::vector::non_fixed::dimension, false, false> >, Cols =
mtl::vector::dense_vector<dolfin::uint,
mtl::vector::parameters<mtl::tag::col_major,
mtl::vector::non_fixed::dimension, false, false> >, Elt = double,
Parameters = mtl::matrix::parameters<mtl::tag::row_major,
mtl::index::c_index, mtl::non_fixed::dimensions, false>, Updater =
mtl::operations::update_plus<double>]’
dolfin/la/MTL4Matrix.cpp:113:   instantiated from here
/unstable/mtl4/boost/numeric/mtl/matrix/compressed2D.hpp:747: error: no
matching function for call to ‘num_cols(const
mtl::matrix::dense2D<double,
mtl::matrix::parameters<mtl::tag::row_major, mtl::index::c_index,
mtl::non_fixed::dimensions, false> >&)’
/unstable/mtl4/boost/numeric/mtl/matrix/compressed2D.hpp:544:
instantiated from ‘mtl::matrix::compressed2D_inserter<Value, Parameters,
Updater>& mtl::matrix::compressed2D_inserter<Value, Parameters,
Updater>::operator<<(const mtl::matrix::element_matrix_t<EMatrix, Rows,
Cols>&) [with Matrix = mtl::matrix::dense2D<double,
mtl::matrix::parameters<mtl::tag::row_major, mtl::index::c_index,
mtl::non_fixed::dimensions, false> >, Rows =
mtl::vector::dense_vector<dolfin::uint,
mtl::vector::parameters<mtl::tag::col_major,
mtl::vector::non_fixed::dimension, false, false> >, Cols =
mtl::vector::dense_vector<dolfin::uint,
mtl::vector::parameters<mtl::tag::col_major,
mtl::vector::non_fixed::dimension, false, false> >, Elt = double,
Parameters = mtl::matrix::parameters<mtl::tag::row_major,
mtl::index::c_index, mtl::non_fixed::dimensions, false>, Updater =
mtl::operations::update_plus<double>]’
/unstable/mtl4/boost/numeric/mtl/matrix/compressed2D.hpp:557:
instantiated from ‘mtl::matrix::compressed2D_inserter<Value, Parameters,
Updater>& mtl::matrix::compressed2D_inserter<Value, Parameters,
Updater>::operator<<(const mtl::matrix::element_array_t<EMatrix, Rows,
Cols>&) [with Matrix = mtl::matrix::dense2D<double,
mtl::matrix::parameters<mtl::tag::row_major, mtl::index::c_index,
mtl::non_fixed::dimensions, false> >, Rows =
mtl::vector::dense_vector<dolfin::uint,
mtl::vector::parameters<mtl::tag::col_major,
mtl::vector::non_fixed::dimension, false, false> >, Cols =
mtl::vector::dense_vector<dolfin::uint,
mtl::vector::parameters<mtl::tag::col_major,
mtl::vector::non_fixed::dimension, false, false> >, Elt = double,
Parameters = mtl::matrix::parameters<mtl::tag::row_major,
mtl::index::c_index, mtl::non_fixed::dimensions, false>, Updater =
mtl::operations::update_plus<double>]’
dolfin/la/MTL4Matrix.cpp:113:   instantiated from here
/unstable/mtl4/boost/numeric/mtl/matrix/compressed2D.hpp:747: error: no
matching function for call to ‘num_rows(const
mtl::matrix::dense2D<double,
mtl::matrix::parameters<mtl::tag::row_major, mtl::index::c_index,
mtl::non_fixed::dimensions, false> >&)’
scons: *** [dolfin/la/MTL4Matrix.os] Error 1
scons: building terminated because of errors.
dolfin/la/MTL4Matrix.os failed: Error 1


The joys of template error messages.


I've traced the problem to the following change. Do I need some other
version of MTL4 to get this to work?


Looks like a question for the MTL4 list. We can change the code back in DOLFIN. Reverting won't make all that much difference in terms of performance.

Garth

http://www.fenics.org/hg/dolfin?fd=9c94f3f12026;file=dolfin/la/MTL4Matrix.cpp

Thanks,
Harish

_______________________________________________
DOLFIN-dev mailing list
DOLFIN-dev@xxxxxxxxxx
http://www.fenics.org/mailman/listinfo/dolfin-dev




Follow ups

References