diff --git a/CMakeLists.txt b/CMakeLists.txt index b52c71e5..d2cae5ee 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -69,9 +69,8 @@ ign_find_package(ignition-math6 REQUIRED) set(IGN_MATH_VER ${ignition-math6_VERSION_MAJOR}) #-------------------------------------- -# Find ignition-tools -ign_find_package(ignition-tools - QUIET) +# Find if ign command is available +find_program(HAVE_IGN_TOOLS ign) #-------------------------------------- # Find Tinyxml2 diff --git a/tools/CMakeLists.txt b/tools/CMakeLists.txt index 3343f257..65cd2d4c 100644 --- a/tools/CMakeLists.txt +++ b/tools/CMakeLists.txt @@ -12,6 +12,7 @@ if (MSVC) list(REMOVE_ITEM test_sources ign_TEST.cc) endif() -if (IGNITION-TOOLS_BINARY_DIRS) + +if (HAVE_IGN_TOOLS) ign_build_tests(TYPE UNIT SOURCES ${test_sources}) endif ()