Skip to content

Commit

Permalink
Fix check for missing components in OGRE2. Be more verbose with compo…
Browse files Browse the repository at this point in the history
…nents (#220)

Signed-off-by: Jose Luis Rivero <[email protected]>
  • Loading branch information
j-rivero authored Apr 4, 2022
1 parent e7e2c53 commit 3617a83
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions cmake/FindIgnOGRE2.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ if (${IgnOGRE2_FIND_VERSION_MAJOR})
endif()
endif()

message(STATUS "-- Finding OGRE 2.${IgnOGRE2_FIND_VERSION_MINOR}")
message(STATUS " Version: 2.${IgnOGRE2_FIND_VERSION_MINOR}")
set(OGRE2_INSTALL_PATH "OGRE-2.${IgnOGRE2_FIND_VERSION_MINOR}")

macro(append_library VAR LIB)
Expand Down Expand Up @@ -226,8 +226,8 @@ if (NOT WIN32)
"Ogre${component}.${OGRE2_VERSION}"
"Ogre${component}"
HINTS ${OGRE2_LIBRARY_DIRS})
if (NOT "OGRE2-${component}" STREQUAL "OGRE2-${component}-NOTFOUND")

if (NOT "${OGRE2-${component}}" STREQUAL "OGRE2-${component}-NOTFOUND")
message(STATUS " component ${component}: found")
# create a new target for each component
set(component_TARGET_NAME "IgnOGRE2-${component}::IgnOGRE2-${component}")
set(component_INCLUDE_DIRS ${OGRE2_INCLUDE_DIRS})
Expand Down Expand Up @@ -256,6 +256,7 @@ if (NOT WIN32)
list(APPEND OGRE2_LIBRARIES ${component_TARGET_NAME})

elseif(IgnOGRE2_FIND_REQUIRED_${component})
message(STATUS " component ${component}: not found!")
set(OGRE2_FOUND false)
endif()
endforeach()
Expand Down

0 comments on commit 3617a83

Please sign in to comment.