Compiling IMP 2.5.0 on CentOS 7
Hi there,
Having a heck of a time trying to compile IMP 2.5.0 and its dependencies. Hopefully someone can help. Note that below, the ones that do not say (CentOS 7.2) are in non-standard locations under /opt because we have to keep multiple versions of a lot of this stuff due to other software depending on it.
I’m using:
* GCC 4.8.5 (CentOS 7.2) * CMake 2.8.11 * Boost 1.60.00 * HDF5 1.8.16 (--with-parallel) * Python 2.7.11 * SWIG 2.0.10 (CentOS 7.2) * Modeller 9.16 * GSL 1.15 (CentOS 7.2) * OpenCV 2.3.1 * FFTW 3.3.3 (CentOS 7.2) * MVAPICH 2.1 * NumPy: 1.10.4, SciPy: 0.16.1, matplotlib: 1.5.1, biopython 1.66
First I had a very difficult time getting it to even detect OpenCV. My final solution was to set $PKG_CONFIG_PATH to include the pkgconfig directory for OpenCV 2.3.1 and to symlink opencv.pc (which was created by the build) to opencv22.pc (which is what IMP looks for for some reason). Note that the documentation mentions that 2.1-2.3 works, but it isn’t clear whether that’s actually true when a build failure claims 2.2 is not detected and that is the reason it won’t build em2d. OpenCV 2.2 doesn’t build properly on this environment, for a reason that I’m not quite sure of. As an aside, OpenCV 2.3.1 seems to require a very old version of CUDA that most people would not have, so one has to turn off CUDA support or get that very old version (which doesn’t support our hardware anyway).
I then had difficulty with HDF5 not finding mpi.h. Apparently this is a common problem if you’ve built HDF5 parallel. My solution was setting the compilers to be mpicc/mpic++. At this point, I have to say I’m lost. Here is my cmake command line:
cmake ../imp-2.5.0 -DCMAKE_BUILD_TYPE=Release -DPYTHON_LIBRARY=/opt/sw/packages/gcc-4.8.3/python/2.7.11/lib -DPYTHON_INCLUDE_DIR=/opt/sw/packages/gcc-4.8.3/python/2.7.11/include -DCMAKE_C_COMPILER=mpicc -DCMAKE_CXX_COMPILER=mpic++ -DCMAKE_INSTALL_PREFIX=/opt/sw/packages/gcc-4.8.3/mvapich2-2.1/boost-1.60.0/imp/2.5.0
Doing a make with a high parallel number (eg. 24, 32) got me to a place where there were a number of errors on RMF/SWIG relating to not being able to find Python.h. It’s not clear whether that blocks the build, but it’s probably not good. The CMake command at the beginning reports that it found the expected version of Python (which didn’t work right unless I manually supplied it on the command line). It eventually fails for what I suspect is some other reason.
Doing just a make fails on what looks like a problem with Boost. Perhaps Boost 1.60.0 isn’t supported? I don’t know what version to use instead, other than to assume 1.40.0 works since 1.40.0 or newer is required. Output as follows; your help is appreciated!
Scanning dependencies of target IMP.statistics-lib [ 18%] Building CXX object modules/statistics/src/CMakeFiles/IMP.statistics-lib.dir/__/__/__/src/statistics_all.cpp.o In file included from /opt/sw/packages/gcc-4.8.3/mvapich2-2.1/boost/1.60.0/include/boost/functional/hash/extensions.hpp:24:0, from /opt/sw/packages/gcc-4.8.3/mvapich2-2.1/boost/1.60.0/include/boost/functional/hash/hash.hpp:558, from /opt/sw/packages/gcc-4.8.3/mvapich2-2.1/boost/1.60.0/include/boost/functional/hash.hpp:6, from /usr/src/imp-2.5.0-build/include/IMP/hash.h:17, from /usr/src/imp-2.5.0-build/include/IMP/statistics/statistics_config.h:162, from /usr/src/imp-2.5.0-build/include/IMP/statistics/ChiSquareMetric.h:11, from /usr/src/imp-2.5.0/modules/statistics/src/ChiSquareMetric.cpp:8, from /usr/src/imp-2.5.0-build/src/statistics_all.cpp:4: /opt/sw/packages/gcc-4.8.3/mvapich2-2.1/boost/1.60.0/include/boost/graph/adjacency_matrix.hpp:446:25: error: ^Xice_not^Y is not a member of ^Xboost::type_traits^Y BOOST_STATIC_ASSERT(type_traits::ice_not<(is_same<Directed, bidirectionalS>::value)>::value); ^ /opt/sw/packages/gcc-4.8.3/mvapich2-2.1/boost/1.60.0/include/boost/static_assert.hpp:70:55: note: in definition of macro ^XBOOST_STATIC_ASSERT^Y # define BOOST_STATIC_ASSERT( ... ) static_assert(__VA_ARGS__, #__VA_ARGS__) ^ /opt/sw/packages/gcc-4.8.3/mvapich2-2.1/boost/1.60.0/include/boost/graph/adjacency_matrix.hpp:446:89: error: ^X::value^Y has not been declared BOOST_STATIC_ASSERT(type_traits::ice_not<(is_same<Directed, bidirectionalS>::value)>::value); ^ /opt/sw/packages/gcc-4.8.3/mvapich2-2.1/boost/1.60.0/include/boost/static_assert.hpp:70:55: note: in definition of macro ^XBOOST_STATIC_ASSERT^Y # define BOOST_STATIC_ASSERT( ... ) static_assert(__VA_ARGS__, #__VA_ARGS__) ^ /opt/sw/packages/gcc-4.8.3/mvapich2-2.1/boost/1.60.0/include/boost/graph/adjacency_matrix.hpp:446:89: note: suggested alternatives: BOOST_STATIC_ASSERT(type_traits::ice_not<(is_same<Directed, bidirectionalS>::value)>::value); ^ /opt/sw/packages/gcc-4.8.3/mvapich2-2.1/boost/1.60.0/include/boost/static_assert.hpp:70:55: note: in definition of macro ^XBOOST_STATIC_ASSERT^Y # define BOOST_STATIC_ASSERT( ... ) static_assert(__VA_ARGS__, #__VA_ARGS__) ^ In file included from /opt/sw/packages/gcc-4.8.3/mvapich2-2.1/boost/1.60.0/include/boost/program_options/value_semantic.hpp:432:0, from /opt/sw/packages/gcc-4.8.3/mvapich2-2.1/boost/1.60.0/include/boost/program_options/options_description.hpp:13, from /opt/sw/packages/gcc-4.8.3/mvapich2-2.1/boost/1.60.0/include/boost/program_options.hpp:15, from /usr/src/imp-2.5.0-build/include/IMP/internal/Flag.h:13, from /usr/src/imp-2.5.0-build/include/IMP/Flag.h:13, from /usr/src/imp-2.5.0-build/include/IMP/internal/base_static.h:13, from /usr/src/imp-2.5.0-build/include/IMP/exception.h:16, from /usr/src/imp-2.5.0-build/include/IMP/Object.h:14, from /usr/src/imp-2.5.0-build/include/IMP/statistics/Metric.h:13, from /usr/src/imp-2.5.0-build/include/IMP/statistics/ChiSquareMetric.h:12, from /usr/src/imp-2.5.0/modules/statistics/src/ChiSquareMetric.cpp:8, from /usr/src/imp-2.5.0-build/src/statistics_all.cpp:4: /opt/sw/packages/gcc-4.8.3/mvapich2-2.1/boost/1.60.0/include/boost/program_options/detail/value_semantic.hpp:180:5: note: ^Xboost::program_options::value^Y value(T* v) ^ In file included from /opt/sw/packages/gcc-4.8.3/mvapich2-2.1/boost/1.60.0/include/boost/xpressive/detail/core/access.hpp:18:0, from /opt/sw/packages/gcc-4.8.3/mvapich2-2.1/boost/1.60.0/include/boost/xpressive/detail/core/state.hpp:18, from /opt/sw/packages/gcc-4.8.3/mvapich2-2.1/boost/1.60.0/include/boost/xpressive/detail/core/matcher/alternate_end_matcher.hpp:20, from /opt/sw/packages/gcc-4.8.3/mvapich2-2.1/boost/1.60.0/include/boost/xpressive/detail/core/matchers.hpp:17, from /opt/sw/packages/gcc-4.8.3/mvapich2-2.1/boost/1.60.0/include/boost/xpressive/regex_primitives.hpp:22, from /opt/sw/packages/gcc-4.8.3/mvapich2-2.1/boost/1.60.0/include/boost/xpressive/xpressive_static.hpp:24, from /opt/sw/packages/gcc-4.8.3/mvapich2-2.1/boost/1.60.0/include/boost/graph/graphviz.hpp:34, from /usr/src/imp-2.5.0-build/include/IMP/internal/base_graph_utility.h:16, from /usr/src/imp-2.5.0-build/include/IMP/graph_macros.h:14, from /usr/src/imp-2.5.0-build/include/IMP/base_macros.h:24, from /usr/src/imp-2.5.0-build/include/IMP/base_utility.h:15, from /usr/src/imp-2.5.0-build/include/IMP/utility.h:13, from /usr/src/imp-2.5.0-build/include/IMP/algebra/VectorBaseD.h:16, from /usr/src/imp-2.5.0-build/include/IMP/algebra/VectorD.h:12, from /usr/src/imp-2.5.0-build/include/IMP/algebra/BoundingBoxD.h:12, from /usr/src/imp-2.5.0-build/include/IMP/algebra.h:10, from /usr/src/imp-2.5.0/modules/statistics/src/ChiSquareMetric.cpp:9, from /usr/src/imp-2.5.0-build/src/statistics_all.cpp:4: /opt/sw/packages/gcc-4.8.3/mvapich2-2.1/boost/1.60.0/include/boost/proto/traits.hpp:1161:5: note: ^Xboost::proto::value^Y value(Expr const &e) ^ In file included from /opt/sw/packages/gcc-4.8.3/mvapich2-2.1/boost/1.60.0/include/boost/xpressive/detail/core/access.hpp:18:0, from /opt/sw/packages/gcc-4.8.3/mvapich2-2.1/boost/1.60.0/include/boost/xpressive/detail/core/state.hpp:18, from /opt/sw/packages/gcc-4.8.3/mvapich2-2.1/boost/1.60.0/include/boost/xpressive/detail/core/matcher/alternate_end_matcher.hpp:20, from /opt/sw/packages/gcc-4.8.3/mvapich2-2.1/boost/1.60.0/include/boost/xpressive/detail/core/matchers.hpp:17, from /opt/sw/packages/gcc-4.8.3/mvapich2-2.1/boost/1.60.0/include/boost/xpressive/regex_primitives.hpp:22, from /opt/sw/packages/gcc-4.8.3/mvapich2-2.1/boost/1.60.0/include/boost/xpressive/xpressive_static.hpp:24, from /opt/sw/packages/gcc-4.8.3/mvapich2-2.1/boost/1.60.0/include/boost/graph/graphviz.hpp:34, from /usr/src/imp-2.5.0-build/include/IMP/internal/base_graph_utility.h:16, from /usr/src/imp-2.5.0-build/include/IMP/graph_macros.h:14, from /usr/src/imp-2.5.0-build/include/IMP/base_macros.h:24, from /usr/src/imp-2.5.0-build/include/IMP/base_utility.h:15, from /usr/src/imp-2.5.0-build/include/IMP/utility.h:13, from /usr/src/imp-2.5.0-build/include/IMP/algebra/VectorBaseD.h:16, from /usr/src/imp-2.5.0-build/include/IMP/algebra/VectorD.h:12, from /usr/src/imp-2.5.0-build/include/IMP/algebra/BoundingBoxD.h:12, from /usr/src/imp-2.5.0-build/include/IMP/algebra.h:10, from /usr/src/imp-2.5.0/modules/statistics/src/ChiSquareMetric.cpp:9, from /usr/src/imp-2.5.0-build/src/statistics_all.cpp:4: /opt/sw/packages/gcc-4.8.3/mvapich2-2.1/boost/1.60.0/include/boost/proto/traits.hpp:294:16: note: ^Xboost::proto::result_of::value^Y struct value ^ In file included from /opt/sw/packages/gcc-4.8.3/mvapich2-2.1/boost/1.60.0/include/boost/xpressive/detail/core/access.hpp:18:0, from /opt/sw/packages/gcc-4.8.3/mvapich2-2.1/boost/1.60.0/include/boost/xpressive/detail/core/state.hpp:18, from /opt/sw/packages/gcc-4.8.3/mvapich2-2.1/boost/1.60.0/include/boost/xpressive/detail/core/matcher/alternate_end_matcher.hpp:20, from /opt/sw/packages/gcc-4.8.3/mvapich2-2.1/boost/1.60.0/include/boost/xpressive/detail/core/matchers.hpp:17, from /opt/sw/packages/gcc-4.8.3/mvapich2-2.1/boost/1.60.0/include/boost/xpressive/regex_primitives.hpp:22, from /opt/sw/packages/gcc-4.8.3/mvapich2-2.1/boost/1.60.0/include/boost/xpressive/xpressive_static.hpp:24, from /opt/sw/packages/gcc-4.8.3/mvapich2-2.1/boost/1.60.0/include/boost/graph/graphviz.hpp:34, from /usr/src/imp-2.5.0-build/include/IMP/internal/base_graph_utility.h:16, from /usr/src/imp-2.5.0-build/include/IMP/graph_macros.h:14, from /usr/src/imp-2.5.0-build/include/IMP/base_macros.h:24, from /usr/src/imp-2.5.0-build/include/IMP/base_utility.h:15, from /usr/src/imp-2.5.0-build/include/IMP/utility.h:13, from /usr/src/imp-2.5.0-build/include/IMP/algebra/VectorBaseD.h:16, from /usr/src/imp-2.5.0-build/include/IMP/algebra/VectorD.h:12, from /usr/src/imp-2.5.0-build/include/IMP/algebra/BoundingBoxD.h:12, from /usr/src/imp-2.5.0-build/include/IMP/algebra.h:10, from /usr/src/imp-2.5.0/modules/statistics/src/ChiSquareMetric.cpp:9, from /usr/src/imp-2.5.0-build/src/statistics_all.cpp:4: /opt/sw/packages/gcc-4.8.3/mvapich2-2.1/boost/1.60.0/include/boost/proto/traits.hpp:824:16: note: ^Xboost::proto::functional::value^Y struct value ^ In file included from /opt/sw/packages/gcc-4.8.3/mvapich2-2.1/boost/1.60.0/include/boost/xpressive/detail/detail_fwd.hpp:24:0, from /opt/sw/packages/gcc-4.8.3/mvapich2-2.1/boost/1.60.0/include/boost/xpressive/regex_primitives.hpp:21, from /opt/sw/packages/gcc-4.8.3/mvapich2-2.1/boost/1.60.0/include/boost/xpressive/xpressive_static.hpp:24, from /opt/sw/packages/gcc-4.8.3/mvapich2-2.1/boost/1.60.0/include/boost/graph/graphviz.hpp:34, from /usr/src/imp-2.5.0-build/include/IMP/internal/base_graph_utility.h:16, from /usr/src/imp-2.5.0-build/include/IMP/graph_macros.h:14, from /usr/src/imp-2.5.0-build/include/IMP/base_macros.h:24, from /usr/src/imp-2.5.0-build/include/IMP/base_utility.h:15, from /usr/src/imp-2.5.0-build/include/IMP/utility.h:13, from /usr/src/imp-2.5.0-build/include/IMP/algebra/VectorBaseD.h:16, from /usr/src/imp-2.5.0-build/include/IMP/algebra/VectorD.h:12, from /usr/src/imp-2.5.0-build/include/IMP/algebra/BoundingBoxD.h:12, from /usr/src/imp-2.5.0-build/include/IMP/algebra.h:10, from /usr/src/imp-2.5.0/modules/statistics/src/ChiSquareMetric.cpp:9, from /usr/src/imp-2.5.0-build/src/statistics_all.cpp:4: /opt/sw/packages/gcc-4.8.3/mvapich2-2.1/boost/1.60.0/include/boost/xpressive/xpressive_fwd.hpp:134:12: note: ^Xboost::xpressive::value^Y struct value; ^ In file included from /opt/sw/packages/gcc-4.8.3/mvapich2-2.1/boost/1.60.0/include/boost/bind.hpp:22:0, from /usr/src/imp-2.5.0-build/include/IMP/internal/container_helpers.h:19, from /usr/src/imp-2.5.0-build/include/IMP/internal/TupleRestraint.h:14, from /usr/src/imp-2.5.0-build/include/IMP/singleton_macros.h:15, from /usr/src/imp-2.5.0-build/include/IMP/macros.h:13, from /usr/src/imp-2.5.0-build/include/IMP/statistics/PartitionalClustering.h:13, from /usr/src/imp-2.5.0/modules/statistics/src/PartitionalClustering.cpp:7, from /usr/src/imp-2.5.0-build/src/statistics_all.cpp:8: /opt/sw/packages/gcc-4.8.3/mvapich2-2.1/boost/1.60.0/include/boost/bind/bind.hpp:118:25: note: ^Xboost::_bi::value^Y template<class T> class value ^ In file included from /usr/src/imp-2.5.0-build/include/IMP/statistics/internal/TrivialPartitionalClustering.h:14:0, from /usr/src/imp-2.5.0/modules/statistics/src/RecursivePartitionalClusteringEmbedding.cpp:9, from /usr/src/imp-2.5.0-build/src/statistics_all.cpp:10: /opt/sw/packages/gcc-4.8.3/mvapich2-2.1/boost/1.60.0/include/boost/graph/adjacency_matrix.hpp: In instantiation of ^Xstatic boost::adj_mat_pm_helper<D, VP, EP, GP, A, Tag, boost::edge_property_tag>::type boost::adj_mat_pm_helper<D, VP, EP, GP, A, Tag, boost::edge_property_tag>::get_nonconst(boost::adjacency_matrix<D , VP, EP, GP, A>&, Tag) [with D = boost::undirectedS; VP = boost::no_property; EP = boost::property<boost::edge_weight_t, double, boost::property<boost::edge_ centrality_t, double> >; GP = boost::no_property; A = std::allocator<bool>; Tag = boost::edge_centrality_t; boost::adj_mat_pm_helper<D, VP, EP, GP, A, Tag, bo ost::edge_property_tag>::type = boost::function_property_map<boost::adj_mat_pm_helper<boost::undirectedS, boost::no_property, boost::property<boost::edge_weig ht_t, double, boost::property<boost::edge_centrality_t, double> >, boost::no_property, std::allocator<bool>, boost::edge_centrality_t, boost::edge_property_ta g>::lookup_property_from_edge<mpl_::bool_<false> >, boost::detail::matrix_edge_desc_impl<boost::undirected_tag, long unsigned int>, double&>; typename boost:: result_of<const boost::adj_mat_pm_helper<D, VP, EP, GP, A, Tag, boost::edge_property_tag>::lookup_property_from_edge<mpl_::bool_<false> >(const typename boost ::graph_traits<boost::adjacency_matrix<D, VP, EP, GP, A> >::edge_descriptor&)>::type = double&; typename boost::graph_traits<boost::adjacency_matrix<D, VP, EP , GP, A> >::edge_descriptor = boost::detail::matrix_edge_desc_impl<boost::undirected_tag, long unsigned int>]^Y: /opt/sw/packages/gcc-4.8.3/mvapich2-2.1/boost/1.60.0/include/boost/graph/adjacency_matrix.hpp:1119:86: required from ^Xtypename boost::property_map<boost::ad jacency_matrix<D, VP, EP, GP, A>, Tag>::type boost::get(Tag, boost::adjacency_matrix<D, VP, EP, GP, A>&) [with D = boost::undirectedS; VP = boost::no_property ; EP = boost::property<boost::edge_weight_t, double, boost::property<boost::edge_centrality_t, double> >; GP = boost::no_property; A = std::allocator<bool>; T ag = boost::edge_centrality_t; typename boost::property_map<boost::adjacency_matrix<D, VP, EP, GP, A>, Tag>::type = boost::function_property_map<boost::adj_ma t_pm_helper<boost::undirectedS, boost::no_property, boost::property<boost::edge_weight_t, double, boost::property<boost::edge_centrality_t, double> >, boost:: no_property, std::allocator<bool>, boost::edge_centrality_t, boost::edge_property_tag>::lookup_property_from_edge<mpl_::bool_<false> >, boost::detail::matrix_ edge_desc_impl<boost::undirected_tag, long unsigned int>, double&>]^Y /usr/src/imp-2.5.0/modules/statistics/src/internal/centrality_clustering.cpp:74:43: required from here /opt/sw/packages/gcc-4.8.3/mvapich2-2.1/boost/1.60.0/include/boost/graph/adjacency_matrix.hpp:1092:17: warning: unused parameter ^Xg^Y [-Wunused-parameter] static type get_nonconst(adjacency_matrix<D, VP, EP, GP, A>& g, Tag tag) { ^ /opt/sw/packages/gcc-4.8.3/mvapich2-2.1/boost/1.60.0/include/boost/graph/adjacency_matrix.hpp: In instantiation of ^Xstatic boost::adj_mat_pm_helper<D, VP, EP, GP, A, Tag, boost::edge_property_tag>::type boost::adj_mat_pm_helper<D, VP, EP, GP, A, Tag, boost::edge_property_tag>::get_nonconst(boost::adjacency_matrix<D , VP, EP, GP, A>&, Tag) [with D = boost::undirectedS; VP = boost::no_property; EP = boost::property<boost::edge_weight_t, double, boost::property<boost::edge_ centrality_t, double> >; GP = boost::no_property; A = std::allocator<bool>; Tag = boost::edge_weight_t; boost::adj_mat_pm_helper<D, VP, EP, GP, A, Tag, boost: :edge_property_tag>::type = boost::function_property_map<boost::adj_mat_pm_helper<boost::undirectedS, boost::no_property, boost::property<boost::edge_weight_t , double, boost::property<boost::edge_centrality_t, double> >, boost::no_property, std::allocator<bool>, boost::edge_weight_t, boost::edge_property_tag>::look up_property_from_edge<mpl_::bool_<false> >, boost::detail::matrix_edge_desc_impl<boost::undirected_tag, long unsigned int>, double&>; typename boost::result_o f<const boost::adj_mat_pm_helper<D, VP, EP, GP, A, Tag, boost::edge_property_tag>::lookup_property_from_edge<mpl_::bool_<false> >(const typename boost::graph_ traits<boost::adjacency_matrix<D, VP, EP, GP, A> >::edge_descriptor&)>::type = double&; typename boost::graph_traits<boost::adjacency_matrix<D, VP, EP, GP, A> > ::edge_descriptor = boost::detail::matrix_edge_desc_impl<boost::undirected_tag, long unsigned int>]^Y: /opt/sw/packages/gcc-4.8.3/mvapich2-2.1/boost/1.60.0/include/boost/graph/adjacency_matrix.hpp:1119:86: required from ^Xtypename boost::property_map<boost::ad jacency_matrix<D, VP, EP, GP, A>, Tag>::type boost::get(Tag, boost::adjacency_matrix<D, VP, EP, GP, A>&) [with D = boost::undirectedS; VP = boost::no_property ; EP = boost::property<boost::edge_weight_t, double, boost::property<boost::edge_centrality_t, double> >; GP = boost::no_property; A = std::allocator<bool>; T ag = boost::edge_weight_t; typename boost::property_map<boost::adjacency_matrix<D, VP, EP, GP, A>, Tag>::type = boost::function_property_map<boost::adj_mat_pm _helper<boost::undirectedS, boost::no_property, boost::property<boost::edge_weight_t, double, boost::property<boost::edge_centrality_t, double> >, boost::no_p roperty, std::allocator<bool>, boost::edge_weight_t, boost::edge_property_tag>::lookup_property_from_edge<mpl_::bool_<false> >, boost::detail::matrix_edge_des c_impl<boost::undirected_tag, long unsigned int>, double&>]^Y /usr/src/imp-2.5.0/modules/statistics/src/metric_clustering.cpp:25:39: required from here /opt/sw/packages/gcc-4.8.3/mvapich2-2.1/boost/1.60.0/include/boost/graph/adjacency_matrix.hpp:1092:17: warning: unused parameter ^Xg^Y [-Wunused-parameter] make[2]: *** [modules/statistics/src/CMakeFiles/IMP.statistics-lib.dir/__/__/__/src/statistics_all.cpp.o] Error 1 ake[1]: *** [modules/statistics/src/CMakeFiles/IMP.statistics-lib.dir/all] Error 2 make: *** [all] Error 2
-- ____ *Note: UMDNJ is now Rutgers-Biomedical and Health Sciences* || \UTGERS |---------------------*O*--------------------- ||_// Biomedical | Ryan Novosielski - Senior Technologist || \ and Health | novosirj@rutgers.edu - 973/972.0922 (2x0922) || \ Sciences | OIRT/High Perf & Res Comp - MSB C630, Newark `'
On 2/1/16 2:29 PM, Novosielski, Ryan wrote: > Having a heck of a time trying to compile IMP 2.5.0 and its > dependencies. Hopefully someone can help. Note that below, the ones > that do not say (CentOS 7.2) are in non-standard locations under /opt > because we have to keep multiple versions of a lot of this stuff due > to other software depending on it.
Just out of curiosity, why you didn't want to use the RHEL 7 RPM package?
> First I had a very difficult time getting it to even detect OpenCV. > My final solution was to set $PKG_CONFIG_PATH to include the > pkgconfig directory for OpenCV 2.3.1 and to symlink opencv.pc (which > was created by the build) to opencv22.pc
I guess that would work. Or you could add the paths to CMAKE_INCLUDE_PATH and CMAKE_LIBRARY_PATH.
> Note that the documentation mentions that 2.1-2.3 works, but it > isn’t clear whether that’s actually true when a build failure claims > 2.2 is not detected and that is the reason it won’t build em2d.
I'm not sure what you mean here... but we've built IMP with various versions of OpenCV, the oldest being 2.1 and the newest being 2.3. RHEL and CentOS don't yet package OpenCV in any form (not even in EPEL), so on CentOS 7 the only version we've built with is that at http://integrativemodeling.org/build-extras/, 2.1 in this case.
> Doing just a make fails on what looks like a problem with Boost. > Perhaps Boost 1.60.0 isn’t supported?
Boost 1.60 is broken - nothing we can do about that, sorry. Complain to the Boost folks. The relevant bug is here: https://svn.boost.org/trac/boost/ticket/11880
The Homebrew folks already ship Boost 1.60, so I've contributed a fix to them for that: https://github.com/Homebrew/homebrew/commit/7efd777
RHEL 7 ships Boost 1.53 though so isn't affected. If you really want to use your own copy of Boost, you'll need to patch it yourself.
Ben
> On Feb 1, 2016, at 18:49, Ben Webb ben@salilab.org wrote: > >> On 2/1/16 2:29 PM, Novosielski, Ryan wrote: >> Having a heck of a time trying to compile IMP 2.5.0 and its >> dependencies. Hopefully someone can help. Note that below, the ones >> that do not say (CentOS 7.2) are in non-standard locations under /opt >> because we have to keep multiple versions of a lot of this stuff due >> to other software depending on it. > > Just out of curiosity, why you didn't want to use the RHEL 7 RPM package?
I think at least using the binary RPM, I wouldn't have gotten the control I needed about where the software was installed. This is a multiuser system, and we keep installs of each version of software so that something doesn't break when there upgrades done. This is also on a network filesystem. I thought about looking into using the source RPM, but decided it probably didn't buy me much.
>> First I had a very difficult time getting it to even detect OpenCV. >> My final solution was to set $PKG_CONFIG_PATH to include the >> pkgconfig directory for OpenCV 2.3.1 and to symlink opencv.pc (which >> was created by the build) to opencv22.pc > > I guess that would work. Or you could add the paths to > CMAKE_INCLUDE_PATH and CMAKE_LIBRARY_PATH.
OK, thanks. It wasn't clear why it was failing, so I wasn't sure whether that would do it or not. Didn't get around to trying it before I thought of this. I'm not too familiar with the way CMake works. >> Note that the documentation mentions that 2.1-2.3 works, but it >> isn’t clear whether that’s actually true when a build failure claims >> 2.2 is not detected and that is the reason it won’t build em2d. > > I'm not sure what you mean here... but we've built IMP with various > versions of OpenCV, the oldest being 2.1 and the newest being 2.3.
During the build process, it reports that it doesn't find OpenCV version 2.1 or 2.2. It wasn't clear to me for a while whether it was finding 2.3 and discounting it because it was the wrong version number, or whether I had a problem finding OpenCV at all. I did see that the documentation says that 2.3 will work.
> RHEL and CentOS don't yet package OpenCV in any form (not even in EPEL), so > on CentOS 7 the only version we've built with is that at > http://integrativemodeling.org/build-extras/, 2.1 in this case
I actually looked today, BTW -- that's not true anymore, apparently. CentOS packages OpenCV 2.4.5. I had seen that, but it was not one of the versions that was listed as working, so I didn't want to make things any more complicated for myself. >> Doing just a make fails on what looks like a problem with Boost. >> Perhaps Boost 1.60.0 isn’t supported? > > Boost 1.60 is broken - nothing we can do about that, sorry. Complain to > the Boost folks. The relevant bug is here: > https://svn.boost.org/trac/boost/ticket/11880
That's OK. A note on the website would be good though (eg. 1.40.00 or newer but NOT 1.60.00). I guessed that 1.60.0 was not working, but didn't want to guess at which ones do because that compile is not particularly pleasant either -- I'd like to do the minimum number of Boost builds.
> The Homebrew folks already ship Boost 1.60, so I've contributed a fix to > them for that: > https://github.com/Homebrew/homebrew/commit/7efd777 > > RHEL 7 ships Boost 1.53 though so isn't affected. If you really want to > use your own copy of Boost, you'll need to patch it yourself.
That only applies if I am using 1.60.0, right? I have no particular desire to use that version, so if 1.59.0 or 1.58.0 or something works, I'm happy with that. I don't want to use the OS copy, because it is too old for other software packages we use, and I would prefer not having it changed by surprise during upgrades.
Thanks again.
On 02/01/2016 07:07 PM, Novosielski, Ryan wrote: >> On Feb 1, 2016, at 18:49, Ben Webb ben@salilab.org wrote: >> I'm not sure what you mean here... but we've built IMP with various >> versions of OpenCV, the oldest being 2.1 and the newest being 2.3. > During the build process, it reports that it doesn't find OpenCV > version 2.1 or 2.2. It wasn't clear to me for a while whether it was > finding 2.3 and discounting it because it was the wrong version number, > or whether I had a problem finding OpenCV at all.
Ah, I see what you mean. Yes, the cmake output can be a bit sparse - you have to look in an obscure location (I think CMakeFiles/CMakeError.log) to see more useful information - but ours is a bit sparse too. Should be addressed in b0f5340d.
>> RHEL and CentOS don't yet package OpenCV in any form (not even in EPEL) > I actually looked today, BTW -- that's not true anymore, apparently. > CentOS packages OpenCV 2.4.5.
Oh, you're right, and I misremembered the OpenCV situation here. RHEL *does* package OpenCV, but it's a really old version in EPEL5 and RHEL6. I hadn't noticed that they finally updated it in RHEL7. Our RPM should pull in the system copy of OpenCV on RHEL7 now, as of becfba59.
>> Boost 1.60 is broken - nothing we can do about that, sorry. Complain to >> the Boost folks. The relevant bug is here: >> https://svn.boost.org/trac/boost/ticket/11880 > That's OK. A note on the website would be good though
Sure, done in f0f06deb.
>> RHEL 7 ships Boost 1.53 though so isn't affected. If you really want to >> use your own copy of Boost, you'll need to patch it yourself. > That only applies if I am using 1.60.0, right?
Right - 1.60.0 is the only version I've noticed as being broken. And we've definitely built with 1.59.0.
Ben
> On Feb 1, 2016, at 18:49, Ben Webb ben@salilab.org wrote: > >> On 2/1/16 2:29 PM, Novosielski, Ryan wrote: >> Doing just a make fails on what looks like a problem with Boost. >> Perhaps Boost 1.60.0 isn’t supported? > > Boost 1.60 is broken - nothing we can do about that, sorry. Complain to > the Boost folks. The relevant bug is here: > https://svn.boost.org/trac/boost/ticket/11880
So I'm using 1.59.0 and the issue has gone away. The Python trouble remains. I have all of -DCMAKE_INCLUDE_PATH, -DPYTHON_INCLUDE_DIR, and -DPYTHON_LIBRARY defined -- no help. I'd have expected the latter two to suffice anyway.
Linking CXX shared module ../../../../../lib/rmfplugin.so [ 53%] Built target RMF-vmd [ 54%] Swig source /usr/src/imp-2.5.0/modules/rmf/dependency/RMF/include/RMF/BufferConstHandle.h:48: Warning 467: Overloaded method RMF::BufferConstHandle::BufferConstHandle(std::vector< char,std::allocator< char > > const &) not supported (no type checking rule for 'std::vector< char,std::allocator< char > > const &'). Scanning dependencies of target _RMF [ 54%] Building CXX object src/dependency/RMF/swig/CMakeFiles/_RMF.dir/RMFPYTHON_wrap.cxx.o /usr/src/imp-2.5.0-build/src/dependency/RMF/swig/RMFPYTHON_wrap.cxx:151:20: fatal error: Python.h: No such file or directory #include <Python.h> ^ compilation terminated. make[2]: *** [src/dependency/RMF/swig/CMakeFiles/_RMF.dir/RMFPYTHON_wrap.cxx.o] Error 1 make[1]: *** [src/dependency/RMF/swig/CMakeFiles/_RMF.dir/all] Error 2 make: *** [all] Error 2
On 02/01/2016 08:01 PM, Novosielski, Ryan wrote: > So I'm using 1.59.0 and the issue has gone away. The Python trouble > remains. I have all of -DCMAKE_INCLUDE_PATH, -DPYTHON_INCLUDE_DIR, and > -DPYTHON_LIBRARY defined -- no help. I'd have expected the latter two to > suffice anyway.
Either your PYTHON_INCLUDE_DIR cmake variable is pointing to the wrong directory (doesn't include Python.h) or for some reason the compiler isn't being given the right arguments. You can get more information (the compiler command line is most useful) by running "make VERBOSE=1".
Ben
> On Feb 2, 2016, at 4:17 PM, Ben Webb ben@salilab.org wrote: > > On 02/01/2016 08:01 PM, Novosielski, Ryan wrote: >> So I'm using 1.59.0 and the issue has gone away. The Python trouble >> remains. I have all of -DCMAKE_INCLUDE_PATH, -DPYTHON_INCLUDE_DIR, and >> -DPYTHON_LIBRARY defined -- no help. I'd have expected the latter two to >> suffice anyway. > > Either your PYTHON_INCLUDE_DIR cmake variable is pointing to the wrong > directory (doesn't include Python.h) or for some reason the compiler > isn't being given the right arguments. You can get more information (the > compiler command line is most useful) by running "make VERBOSE=1”.
Thanks much, Ben. This was interesting, actually: apparently Python.h is NOT in “include” but rather “include/python2.7” (I should have looked sooner). Apparently, though, setting PYTHON_INCLUDE_DIR to /anything/ (whether or not it contains Python.h) stops this error:
CMake Error at modules/rmf/dependency/RMF/cmake_modules/py-FindPackageHandleStandardArgs.cmake:97 (message): Could NOT find PythonLibs: Found unsuitable version "2.7.5", but required is exact version "2.7.11" (found /opt/sw/packages/gcc-4.8.3/python/2.7.11/lib). The version of the Python libraries and/or headers does not match that of your 'python' binary (/opt/sw/packages/gcc-4.8.3/python/2.7.11/bin/python). Either set your PATH so that 'python' uses a different Python (e.g. to use /usr/local/bin/python26, do something like mkdir ~/bin; ln -sf /usr/local/bin/python26 ~/bin/python; PATH=~/bin:$PATH), or set PYTHON_LIBRARY to the full path to the correct version of the Python library and PYTHON_INCLUDE_DIR to the directory containing the corresponding Python.h.
…which is what you see if you have a system Python that is one version and then try to use a different Python in your environment. I figured when the error went away when I set PYTHON_INCLUDE_DIR that I had indeed gotten that correct. Setting it to /opt/sw/packages/gcc-4.8.3/python/2.7.11/include/python2.7 did allow the CMake to succeed as well as the build.
Is this the expected behavior? Maybe so.
-- ____ *Note: UMDNJ is now Rutgers-Biomedical and Health Sciences* || \UTGERS |---------------------*O*--------------------- ||_// Biomedical | Ryan Novosielski - Senior Technologist || \ and Health | novosirj@rutgers.edu - 973/972.0922 (2x0922) || \ Sciences | OIRT/High Perf & Res Comp - MSB C630, Newark `'
On 02/02/2016 02:24 PM, Novosielski, Ryan wrote: > Apparently, though, setting PYTHON_INCLUDE_DIR to /anything/ > (whether or not it contains Python.h) stops this error:
Right - this is a "feature" of cmake. If you set PYTHON_INCLUDE_DIR you are explicitly saying to cmake "believe me, I know where Python.h is - don't bother looking for it" and it will trust you blindly. Since it's such a sledgehammer solution to the problem, perhaps we shouldn't suggest that people set it, but rather set the corresponding search hint (PYTHON_INCLUDE_PATH, IIRC). I'll poke at it and see.
Ben
> On Feb 2, 2016, at 5:35 PM, Ben Webb ben@salilab.org wrote: > > On 02/02/2016 02:24 PM, Novosielski, Ryan wrote: >> Apparently, though, setting PYTHON_INCLUDE_DIR to /anything/ >> (whether or not it contains Python.h) stops this error: > > Right - this is a "feature" of cmake. If you set PYTHON_INCLUDE_DIR you > are explicitly saying to cmake "believe me, I know where Python.h is - > don't bother looking for it" and it will trust you blindly. Since it's > such a sledgehammer solution to the problem, perhaps we shouldn't > suggest that people set it, but rather set the corresponding search hint > (PYTHON_INCLUDE_PATH, IIRC). I'll poke at it and see.
To save you the time, I just gave PYTHON_INCLUDE_PATH a shot — appears to exist (no warning that it wasn’t used at the end) and has the same result (setting it to a fictitious directory works fine).
-- ____ *Note: UMDNJ is now Rutgers-Biomedical and Health Sciences* || \UTGERS |---------------------*O*--------------------- ||_// Biomedical | Ryan Novosielski - Senior Technologist || \ and Health | novosirj@rutgers.edu - 973/972.0922 (2x0922) || \ Sciences | OIRT/High Perf & Res Comp - MSB C630, Newark `'
participants (2)
-
Ben Webb
-
Novosielski, Ryan