humanoid-path-planner / hpp-doc

Documentation for project Humanoid Path Planner
https://humanoid-path-planner.github.io/hpp-doc
ISC License
27 stars 23 forks source link

Install on 18.04 not working. #59

Closed olivier-stasse closed 4 years ago

olivier-stasse commented 4 years ago

Right now following the install instructions I got an error on gepetto-viewer:

/integration_tests/HPP/src/gepetto-viewer/src/gui/osgwidget.cc:178:89: error: invalid use of incomplete type ‘class QTemporaryDir’
         tmpDirectory_ = new QTemporaryDir (QDir::temp().absoluteFilePath("gepetto-gui."));

pythonqt is on branch qt4 which I do not get because QTemporaryDir appears only on Qt5. See https://doc.qt.io/archives/qt-4.8/classes.html#t

olivier-stasse commented 4 years ago

The previous error appeared following development instructions.

florent-lamiraux commented 4 years ago

I have the same issue. Trying to compile with qt5, I have another error:

[ 79%] Building CXX object src/CMakeFiles/gepetto-viewer.dir/gui/point-intersector.cc.o
cd /home/florent/devel/hpp/src/gepetto-viewer/build/src && /usr/lib/ccache/g++  -DAVCONV=\"/usr/bin/avconv\" -DPYTHONQT_USE_RELEASE_PYTHON_FALLBACK -DQT_CONCURRENT_LIB -DQT_CORE_LIB -DQT_GUI_LIB -DQT_NETWORK_LIB -DQT_OPENGL_LIB -DQT_WIDGETS_LIB -DQT_XML_LIB -Dgepetto_viewer_EXPORTS -I/home/florent/devel/hpp/src/gepetto-viewer/build/src -I/home/florent/devel/hpp/src/gepetto-viewer/src -I/home/florent/devel/hpp/src/gepetto-viewer/build/src/gepetto-viewer_autogen/include -I/home/florent/devel/hpp/src/gepetto-viewer/build -I/home/florent/devel/hpp/src/gepetto-viewer/build/include -I/home/florent/devel/hpp/src/gepetto-viewer/include -isystem /usr/include/x86_64-linux-gnu/qt5 -isystem /usr/include/x86_64-linux-gnu/qt5/QtXml -isystem /usr/include/x86_64-linux-gnu/qt5/QtCore -isystem /usr/lib/x86_64-linux-gnu/qt5/mkspecs/linux-g++ -isystem /usr/include/x86_64-linux-gnu/qt5/QtWidgets -isystem /usr/include/x86_64-linux-gnu/qt5/QtGui -isystem /usr/include/x86_64-linux-gnu/qt5/QtOpenGL -isystem /usr/include/x86_64-linux-gnu/qt5/QtNetwork -isystem /usr/include/x86_64-linux-gnu/qt5/QtConcurrent -isystem /usr/include/python3.6m -isystem /home/florent/devel/hpp/install/include/PythonQt  -pedantic -Wno-long-long -Wall -Wextra -Wcast-align -Wcast-qual -Wformat -Wwrite-strings -Wconversion  -g -fPIC   -DQT_NO_DEBUG_OUTPUT -DQT_NO_INFO_OUTPUT -DQT_NO_WARNING_OUTPUT -fPIC -std=gnu++11 -o CMakeFiles/gepetto-viewer.dir/gui/point-intersector.cc.o -c /home/florent/devel/hpp/src/gepetto-viewer/src/gui/point-intersector.cc
/home/florent/devel/hpp/src/gepetto-viewer/src/gui/point-intersector.cc: In member function ‘virtual void gepetto::gui::PointIntersector::intersect(osgUtil::IntersectionVisitor&, osg::Drawable*)’:
/home/florent/devel/hpp/src/gepetto-viewer/src/gui/point-intersector.cc:74:37: error: ‘class osg::Drawable’ has no member named ‘getBoundingBox’; did you mean ‘_boundingBox’?
     osg::BoundingBox bb = drawable->getBoundingBox();
                                     ^~~~~~~~~~~~~~
                                     _boundingBox
src/CMakeFiles/gepetto-viewer.dir/build.make:1635: recipe for target 'src/CMakeFiles/gepetto-viewer.dir/gui/point-intersector.cc.o' failed
jmirabel commented 4 years ago

At the moment, the devel branch of gepetto-viewer is not compatible with Qt4. I have to fix it. However, it should work with Qt5.

jmirabel commented 4 years ago

@florent-lamiraux this is with osg 3.2 ?

jmirabel commented 4 years ago

https://github.com/Gepetto/gepetto-viewer/pull/139 should fix @olivier-stasse issue.

olivier-stasse commented 4 years ago

Dear @jmirabel, Thanks for the bug fix. Then it means that I should stay on qt 4 ? Because switching to Qt5 I got the following error:

[  5%] Building CXX object CMakeFiles/hpp-pinocchio.dir/src/urdf/util.cc.o
/usr/bin/c++  -DBOOST_MPL_LIMIT_LIST_SIZE=30 -DBOOST_MPL_LIMIT_VECTOR_SIZE=30 -DPINOCCHIO_WITH_HPP_FCL -DPINOCCHIO_WITH_URDFDOM -Dhpp_pinocchio_EXPORTS -I/integration_tests/HPP/src/hpp-pinocchio/build-rel -I/integration_tests/HPP/src/hpp-pinocchio/build-rel/include -I/integration_tests/HPP/src/hpp-pinocchio/include -isystem /integration_tests/HPP/install/include -isystem /usr/include/eigen3 -isystem /opt/openrobots/include  -pedantic -Wno-long-long -Wall -Wextra -Wcast-align -Wcast-qual -Wformat -Wwrite-strings -Wconversion  -O3 -DNDEBUG -fPIC   -DHPP_FCL_HAVE_OCTOMAP -DFCL_HAVE_OCTOMAP -DOCTOMAP_MAJOR_VERSION=1 -DOCTOMAP_MINOR_VERSION=9 -DOCTOMAP_PATCH_VERSION=0 -o CMakeFiles/hpp-pinocchio.dir/src/urdf/util.cc.o -c /integration_tests/HPP/src/hpp-pinocchio/src/urdf/util.cc
In file included from /integration_tests/HPP/install/include/pinocchio/parsers/urdf.hpp:11:0,
                 from /integration_tests/HPP/src/hpp-pinocchio/src/urdf/util.cc:24:
/integration_tests/HPP/install/include/pinocchio/parsers/urdf/types.hpp:31:3: error: conflicting declaration ‘typedef class boost::shared_ptr<urdf::Box> urdf::BoxSharedPtr’
   PINOCCHIO_URDF_TYPEDEF_CLASS_POINTER(Box);
florent-lamiraux commented 4 years ago

I recompiled pythonqt with option QT5 and the compilation error disappeared.

jmirabel commented 4 years ago

Qt5 is preferred when possible. However, hpp-pinocchio has no link with Qt so the version of Qt should have no influence of hpp-pinocchio.

The bug you show seems to come from an incompatibility between pinocchio and urdfdom. What version of each to you have ?

olivier-stasse commented 4 years ago

With the QT_VERSION of the Makefile set to 4, switching gepetto-viewer to your repo (i.e. https://github.com/jmirabel/gepetto-viewer.git ) at commit 4455589 which I believe is equivalent to the PR you pointed previously, restarting make all I got:

[ 27%] Building CXX object src/CMakeFiles/gepetto-viewer.dir/leaf-node-line.cpp.o
cd /integration_tests/HPP/src/gepetto-viewer/build-rel/src && /usr/bin/c++  -DAVCONV=\"/usr/bin/ffmpeg\" -DPYTHONQT_USE_RELEASE_PYTHON_FALLBACK -DQT_CORE_LIB -DQT_GUI_LIB -DQT_NETWORK_LIB -DQT_NO_DEBUG -DQT_OPENGL_LIB -DQT_XML_LIB -Dgepetto_viewer_EXPORTS -I/integration_tests/HPP/src/gepetto-viewer/build-rel/src -I/integration_tests/HPP/src/gepetto-viewer/src -I/integration_tests/HPP/src/gepetto-viewer/build-rel/src/gepetto-viewer_autogen/include -I/integration_tests/HPP/src/gepetto-viewer/build-rel -I/integration_tests/HPP/src/gepetto-viewer/build-rel/include -I/integration_tests/HPP/src/gepetto-viewer/include -isystem /usr/include/qt4 -isystem /usr/include/qt4/QtOpenGL -isystem /usr/include/qt4/QtGui -isystem /usr/include/qt4/QtXml -isystem /usr/include/qt4/QtNetwork -isystem /usr/include/qt4/QtCore -isystem /usr/include/python3.6m -isystem /integration_tests/HPP/install/include/PythonQt -isystem /usr/share/qt4/mkspecs/default  -pedantic -Wno-long-long -Wall -Wextra -Wcast-align -Wcast-qual -Wformat -Wwrite-strings -Wconversion  -O3 -DNDEBUG -fPIC   -DQT_NO_DEBUG_OUTPUT -DQT_NO_INFO_OUTPUT -DQT_NO_WARNING_OUTPUT -o CMakeFiles/gepetto-viewer.dir/leaf-node-line.cpp.o -c /integration_tests/HPP/src/gepetto-viewer/src/leaf-node-line.cpp
In file included from /integration_tests/HPP/src/gepetto-viewer/include/gepetto/viewer/macros.h:37:0,
                 from /integration_tests/HPP/src/gepetto-viewer/include/gepetto/viewer/fwd.h:12,
                 from /integration_tests/HPP/src/gepetto-viewer/include/gepetto/viewer/node.h:13,
                 from /integration_tests/HPP/src/gepetto-viewer/include/gepetto/viewer/node-drawable.h:12,
                 from /integration_tests/HPP/src/gepetto-viewer/include/gepetto/viewer/leaf-node-line.h:12,
                 from /integration_tests/HPP/src/gepetto-viewer/src/leaf-node-line.cpp:9:
/usr/include/osg/ref_ptr: In instantiation of ‘osg::ref_ptr<T>::ref_ptr(const osg::ref_ptr<Other>&) [with Other = osg::Geometry; T = osg::Node]’:
/integration_tests/HPP/src/gepetto-viewer/src/leaf-node-line.cpp:45:40:   required from here
/usr/include/osg/ref_ptr:33:79: error: cannot convert ‘osg::Geometry* const’ to ‘osg::Node*’ in initialization
         template<class Other> ref_ptr(const ref_ptr<Other>& rp) : _ptr(rp._ptr) { if (_ptr) _ptr->ref(); }
jmirabel commented 4 years ago

I saw this on the CI: https://gepgitlab.laas.fr/gepetto/gepetto-viewer/-/jobs/78344

I am surprised by this error. I tried to push a fix to see.

olivier-stasse commented 4 years ago

Qt5 is preferred when possible. However, hpp-pinocchio has no link with Qt so the version of Qt should have no influence of hpp-pinocchio.

The bug you show seems to come from an incompatibility between pinocchio and urdfdom. What version of each to you have ?

jmirabel commented 4 years ago

https://github.com/humanoid-path-planner/hpp-doc/pull/60 may help.

jmirabel commented 4 years ago

I merged both PR. Do you have a reason for trying to install the devel branch ?

olivier-stasse commented 4 years ago

From our exchanges I thought (maybe wrongly) that I needed the devel branch to have the sot-gepetto-viewer plugin working.

jmirabel commented 4 years ago

Ah, I see what you try to do.

olivier-stasse commented 4 years ago

Ok thanks for the update. I am trying now to have two directories one for HPP_devel and the other for HPP_stable. I'll close the issue.