Question

I am using PCL library and internally it needs boost libraries.

Unfortunately I am getting an error like this. Explicitly I dont refer to any of the boost library but PCL library does.

/usr/include/boost/graph/graph_concepts.hpp: In destructor ‘boost::concepts::AdjacencyMatrix<G>::~AdjacencyMatrix()’:
/usr/include/boost/graph/graph_concepts.hpp:368:17: error: missing template arguments before ‘(’ token
/usr/include/boost/graph/graph_concepts.hpp: In member function ‘void boost::concepts::AdjacencyMatrix<G>::const_constraints(const G&)’:
/usr/include/boost/graph/graph_concepts.hpp:372:17: error: missing template arguments before ‘(’ token
Was it helpful?

Solution 2

This is very strange.

The problem is solved when I moved the header file

#include<pcl/registration/icp.h>

to the beginning of all the header files. No error any more and the program executed giving the expected results!

OTHER TIPS

Can't reproduce it.

Here's what I did:

Compilation took some time

cd /tmp
tar xf ~/Downloads/pcl-pcl-1.7.1.tar.gz 
cd pcl-pcl-1.7.1/
cmake .
time make -sj

Output ends with

...
Linking CXX executable ../bin/pcl_train_linemod_template
[100%] Built target pcl_train_linemod_template

real    13m55.327s
user    82m49.499s
sys 2m24.611s

Pretty impressive. But clearly no compilation errors (http://paste.ubuntu.com/7359651/). I hope you can work out what is different for you.

Most likely, one of your program header files has some #define ZZZ statement and that macro ZZZ collides with some identifier in Boost. This is why the problem is gone when you move icp.h to the first line.

To find out which macro is causing the problem, look carefully at the line you specified: /usr/include/boost/graph/graph_concepts.hpp:368. The macro probably replaces or removes one of identifiers on this line or in its vicinity. Good luck.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top