Skip to content

Commit

Permalink
Special case for ogre2.2 on Windows
Browse files Browse the repository at this point in the history
Signed-off-by: Michael Carroll <[email protected]>
  • Loading branch information
mjcarroll committed Aug 12, 2021
1 parent 6aabfea commit 4c7f8ba
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions cmake/FindIgnOGRE2.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -293,7 +293,17 @@ else() #WIN32
set(OGRE_${ogre_component}_FOUND FALSE)
endforeach()
# currently designed to work with osrf vcpkg ogre2 portfile
set(OGRE2_PATHS "")
if(${IgnOGRE2_FIND_VERSION_MINOR} EQUAL 2)
# Specific case for osrf ogre 2.2 vcpkg
foreach(_rootPath ${VCPKG_CMAKE_FIND_ROOT_PATH})
list(APPEND OGRE2_PATHS "${_rootPath}/share/ogre22")
else()
set(OGRE2_PATHS ${VCPKG_CMAKE_FIND_ROOT_PATH})
endif()

find_package(OGRE2
PATHS ${OGRE2_PATHS}
COMPONENTS ${IgnOGRE2_FIND_COMPONENTS})
set(OGRE2_INCLUDE_DIRS ${OGRE_INCLUDE_DIRS})
# Imported from OGRE1: link component libs outside of static build
Expand Down

0 comments on commit 4c7f8ba

Please sign in to comment.