ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question
0

ROS-Qt project issue

asked 2020-03-31 03:06:11 -0500

Shapy gravatar image

Hello All!
I am currently working on building a qt app for ROS Melodic. The app's purpose is to send commands to a mobile robot for movement. I am following this blogpost for reference. After creating the "qtros" project in my catkin workspace, when I try to open the project in my qtcreator, the parsing of the CMakeLists.txt file fails, giving this message

Could NOT find qt_build (missing: qt_build_DIR) Could not find the required component 'qt_build'. The following CMake error indicates that you either need to install the package with the same name or change your environment so that it can be found. CMake Error at /opt/ros/melodic/share/catkin/cmake/catkinConfig.cmake:83 (find_package):   Could not find a package configuration file provided by "qt_build" with any   of the following names:

    qt_buildConfig.cmake
    qt_build-config.cmake

  Add the installation prefix of "qt_build" to CMAKE_PREFIX_PATH or set "qt_build_DIR" to a directory containing one of the above files.  If "qt_build" provides a separate development package or SDK, be sure it has   been installed. Call Stack (most recent call first):   CMakeLists.txt:13 (find_package)


Configuring incomplete, errors occurred! See also "/tmp/QtCreator-XzAWGc/qtc-cmake-yqSteIho/CMakeFiles/CMakeOutput.log". See also "/tmp/QtCreator-XzAWGc/qtc-cmake-yqSteIho/CMakeFiles/CMakeError.log". CMake Project parsing failed.

I tried opening a simple project file with a roscpp dependency too, it gives me this message

Could NOT find roscpp (missing: roscpp_DIR)
Could not find the required component 'roscpp'. The following CMake error indicates that you either need to install the package with the same name or change your environment so that it can be found.
CMake Error at /opt/ros/melodic/share/catkin/cmake/catkinConfig.cmake:83 (find_package):
  Could not find a package configuration file provided by "roscpp" with any
  of the following names:

    roscppConfig.cmake
    roscpp-config.cmake

  Add the installation prefix of "roscpp" to CMAKE_PREFIX_PATH or set
  "roscpp_DIR" to a directory containing one of the above files.  If "roscpp"
  provides a separate development package or SDK, be sure it has been
  installed.
Call Stack (most recent call first):
  CMakeLists.txt:10 (find_package)


Configuring incomplete, errors occurred!
See also "/home/aditya/Codeworks/ROS/catkin_ws/src/beginner_tutorials/CMakeFiles/CMakeOutput.log".
See also "/home/aditya/Codeworks/ROS/catkin_ws/src/beginner_tutorials/CMakeFiles/CMakeError.log".
CMake Project parsing failed.

Please can anyone help me solve this issue? And if u have any other verified resources that does the same thing, it will be much appreciated! Thanks!

edit retag flag offensive close merge delete

Comments

Hi @Shapy,

For the first compilation issue you missed a strong dependency: sudo apt-get install ros-melodic-qt-build. For the second: Maybe a naive question but, Do you have ROS installed in your system? Because the fact that the CMake is unable to find roscpp is a clear indication that you do not have ROS installed or at least you have it misconfigured. Maybe your ROS_PACKAGE_PATH environment variable is not set accordingly. Take a look at this wiki post, maybe you find it useful.

Weasfas gravatar image Weasfas  ( 2020-04-04 11:02:16 -0500 )edit

1 Answer

Sort by ยป oldest newest most voted
0

answered 2020-11-08 21:42:38 -0500

arwang gravatar image

Hi there I 'd like suggest you to change your qtcrator worksapce into your catkin space For my situation it sovled

edit flag offensive delete link more

Question Tools

1 follower

Stats

Asked: 2020-03-31 03:06:11 -0500

Seen: 1,304 times

Last updated: Mar 31 '20