Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Imported target "dart" includes non-existent path "/include" in its INTERFACE_INCLUDE_DIRECTORIES. #48

Open
juansuerorobotics opened this issue Feb 14, 2022 · 4 comments

Comments

@juansuerorobotics
Copy link

Im getting the following error running catkin_make on ROS1 noetic

CMake Error in gazebo_ros_demos/gazebo_tutorials/CMakeLists.txt:
Imported target "dart" includes non-existent path

"/include"

in its INTERFACE_INCLUDE_DIRECTORIES. Possible reasons include:

  • The path was deleted, renamed, or moved to another location.

  • An install or uninstall procedure did not complete successfully.

  • The installation package was faulty and references files it does not
    provide.

i did a text search for INTERFACE_INCLUDE_DIRECTORIES and for /include

and im seeing at line 60 of /usr/lib/x86_64-linux-gnu/cmake/assimp-5.0/assimpTargets.cmake
which i think is termed cmake "module" ....

set_target_properties(assimp::assimp PROPERTIES
COMPATIBLE_INTERFACE_STRING "assimp_MAJOR_VERSION"
INTERFACE_assimp_MAJOR_VERSION "1"
INTERFACE_INCLUDE_DIRECTORIES "${_IMPORT_PREFIX}/include;${_IMPORT_PREFIX}/include"
......
)

at src/gazebo_ros_demos/gazebo_tutorials/CMakeLists.txt

i see
find_package(gazebo REQUIRED)
target_link_libraries(${PROJECT_NAME} ${catkin_LIBRARIES} ${GAZEBO_LIBRARIES})

so how do i debug the cmake process? especially since its not even directly running cmake im using a tool that builds cmake called catkin_make?

I dont just want an answer to the issue. im sure the answer is not to use these packages as they are not rated to run against newer versions of ROS. I can see your latest branch is kinetic-devel. thats fine. I need to learn cmake and catkin_make and this is a great way to solve future problems so if you can give me some insight as to the nature of the problem as well as how to debug it for myself also.

@juansuerorobotics
Copy link
Author

in /usr/share/dart/cmake/dart_dartTargets.cmake
there is a line 44

Compute the installation prefix relative to this file.

get_filename_component(_IMPORT_PREFIX "${CMAKE_CURRENT_LIST_FILE}" PATH)
get_filename_component(_IMPORT_PREFIX "${_IMPORT_PREFIX}" PATH)
get_filename_component(_IMPORT_PREFIX "${_IMPORT_PREFIX}" PATH)
get_filename_component(_IMPORT_PREFIX "${_IMPORT_PREFIX}" PATH)
if(_IMPORT_PREFIX STREQUAL "/")
set(_IMPORT_PREFIX "")
endif()

Create imported target dart

add_library(dart SHARED IMPORTED)

set_target_properties(dart PROPERTIES
INTERFACE_COMPILE_FEATURES "cxx_std_14"
INTERFACE_INCLUDE_DIRECTORIES "${_IMPORT_PREFIX}/include"
INTERFACE_LINK_LIBRARIES "dl;dart-external-odelcpsolver;Eigen3::Eigen;ccd;fcl;assimp;Boost::boost;Boost::system;Boost::filesystem;octomap;Boost::regex"
)

that seems to be the responsible lines of code since it mentions both INTERFACE_INCLUDE_DIRECTORIES
and /include

@juansuerorobotics
Copy link
Author

i dont get it.

dart interface includes: /usr/include

Properties for TARGET dart:
dart.LOCATION = "/usr/lib/x86_64-linux-gnu/libdart.so.6.9.2"
dart.INTERFACE_INCLUDE_DIRECTORIES = "/usr/include

dart INTERFACE_LINK_LIBRARIES = dl;dart-external-odelcpsolver;Eigen3::Eigen;ccd;fcl;assimp;Boost::boost;Boost::system;Boost::filesystem;octomap;Boost::regex

No such TARGET "dl" !

Properties for TARGET dart-external-odelcpsolver:
dart-external-odelcpsolver.INTERFACE_INCLUDE_DIRECTORIES =
Properties for TARGET Eigen3::Eigen:
Eigen3::Eigen.INTERFACE_INCLUDE_DIRECTORIES = "/usr/include/eigen3"
Properties for TARGET ccd:
ccd.INTERFACE_INCLUDE_DIRECTORIES = "/usr/include"
Properties for TARGET fcl:
fcl.INTERFACE_INCLUDE_DIRECTORIES = "/opt/ros/noetic/include"
Properties for TARGET assimp:
assimp.INTERFACE_INCLUDE_DIRECTORIES = "/usr/include"
Properties for TARGET Boost::boost:
Boost::boost.INTERFACE_INCLUDE_DIRECTORIES =
Properties for TARGET Boost::system:
Boost::system.INTERFACE_INCLUDE_DIRECTORIES = "/include"
Properties for TARGET Boost::filesystem:
Boost::filesystem.INTERFACE_INCLUDE_DIRECTORIES = "/include"
Properties for TARGET octomap:
octomap.INTERFACE_INCLUDE_DIRECTORIES = "/opt/ros/noetic/include"
Properties for TARGET Boost::regex:
Boost::regex.INTERFACE_INCLUDE_DIRECTORIES = "/include"

dart INTERFACE_COMPILE_FEATURES = cxx_std_14
dart INTERFACE_INCLUDE_DIRECTORIES = /usr/include
dart INTERFACE_LINK_LIBRARIES = dl;dart-external-odelcpsolver;Eigen3::Eigen;ccd;fcl;assimp;Boost::boost;Boost::system;Boost::filesystem;octomap;Boost::regex
dart NAME = dart
dart POSITION_INDEPENDENT_CODE = True
dart SKIP_BUILD_RPATH = OFF
dart SOURCE_DIR = /home/meta/org/debugcmake/src/mypkg
dart TYPE = SHARED_LIBRARY

-- Configuring done
CMake Error in CMakeLists.txt:
Imported target "dart" includes non-existent path

"/include"

in its INTERFACE_INCLUDE_DIRECTORIES. Possible reasons include:

  • The path was deleted, renamed, or moved to another location.

  • An install or uninstall procedure did not complete successfully.

  • The installation package was faulty and references files it does not
    provide.

@ftn-gautam
Copy link

@juansuerorobotics were you able to resolve this? It would be really helpful if you could provide the resolution, i'm facing the same issue?

@juansuerorobotics
Copy link
Author

i think it works on ros melodic with ubuntu 1804. if you try to get fancy and run this on noetic and ubuntu 20.04 somethings off

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants