Skip to content

Commit

Permalink
Merge pull request #825 from ros/relax_depends_check
Browse files Browse the repository at this point in the history
relax depends check
  • Loading branch information
dirk-thomas authored Sep 19, 2016
2 parents 5a7f61d + bbc9875 commit 7d9e4e6
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions cmake/catkin_package.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -159,9 +159,9 @@ function(_catkin_package)
#message(WARNING "catkin_package() DEPENDS on catkin package '${depend_name}' which is deprecated. Use CATKIN_DEPENDS for catkin packages instead.")
list(APPEND _PROJECT_CATKIN_DEPENDS ${depend_name})
else()
if(NOT ${depend_name}_FOUND)
message(FATAL_ERROR "catkin_package() DEPENDS on '${depend_name}' which must be find_package()-ed before. If it is a catkin package it can be declared as CATKIN_DEPENDS instead without find_package()-ing it.")
endif()
# the dependency might not come from a CMake config / module file
# but from e.g. PkgConfig / pkg_search_module
# therefore this can't expect ${depend_name}_FOUND to be defined
if(NOT DEFINED ${depend_name}_INCLUDE_DIRS AND NOT DEFINED ${depend_name}_LIBRARIES)
message(WARNING "catkin_package() DEPENDS on '${depend_name}' but neither '${depend_name}_INCLUDE_DIRS' nor '${depend_name}_LIBRARIES' is defined.")
endif()
Expand Down

0 comments on commit 7d9e4e6

Please sign in to comment.