From 491d37df15c048cd4757cd57d3091cec7c255fc5 Mon Sep 17 00:00:00 2001 From: "Matias N. Goldberg" Date: Wed, 1 Nov 2023 20:37:26 -0300 Subject: [PATCH] FindOgre missing functionality OGRE-Next pkg-config (#346) Fixes #346 --- CMake/Packages/FindOGRE.cmake | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/CMake/Packages/FindOGRE.cmake b/CMake/Packages/FindOGRE.cmake index 62f62aba65f..9e512371cbb 100644 --- a/CMake/Packages/FindOGRE.cmake +++ b/CMake/Packages/FindOGRE.cmake @@ -173,8 +173,9 @@ set(OGRE_PREFIX_WATCH ${OGRE_PREFIX_PATH} ${OGRE_PREFIX_SOURCE} ${OGRE_PREFIX_BU clear_if_changed(OGRE_PREFIX_WATCH ${OGRE_RESET_VARS}) if(NOT OGRE_STATIC) - # try to locate Ogre via pkg-config - use_pkgconfig(OGRE_PKGC "OGRE${OGRE_LIB_SUFFIX}") + # try to locate Ogre via pkg-config + use_pkgconfig(OGRE_PKGC "OGRE-Next${OGRE_LIB_SUFFIX}") + use_pkgconfig(OGRE_PKGC "OGRE${OGRE_LIB_SUFFIX}") # Set the framework search path for OS X set(OGRE_FRAMEWORK_SEARCH_PATH @@ -396,7 +397,7 @@ set(OGRE_COMPONENT_SEARCH_PATH_DBG macro(ogre_find_component COMPONENT HEADER PATH_HINTS) set(OGRE_${COMPONENT}_FIND_QUIETLY ${OGRE_FIND_QUIETLY}) findpkg_begin(OGRE_${COMPONENT}) - find_path(OGRE_${COMPONENT}_INCLUDE_DIR NAMES ${HEADER} HINTS ${OGRE_INCLUDE_DIRS} ${OGRE_PREFIX_SOURCE} PATH_SUFFIXES ${PATH_HINTS} ${COMPONENT} OGRE/${COMPONENT} ) + find_path(OGRE_${COMPONENT}_INCLUDE_DIR NAMES ${HEADER} HINTS ${OGRE_INCLUDE_DIRS} ${OGRE_PREFIX_SOURCE} PATH_SUFFIXES ${PATH_HINTS} ${COMPONENT} OGRE-Next/${COMPONENT} OGRE/${COMPONENT} ) set(OGRE_${COMPONENT}_LIBRARY_NAMES "OgreNext${COMPONENT}${OGRE_LIB_SUFFIX}" "Ogre${COMPONENT}${OGRE_LIB_SUFFIX}") get_debug_names(OGRE_${COMPONENT}_LIBRARY_NAMES) find_library(OGRE_${COMPONENT}_LIBRARY_REL NAMES ${OGRE_${COMPONENT}_LIBRARY_NAMES} HINTS ${OGRE_LIBRARY_DIR_REL} ${OGRE_FRAMEWORK_PATH} PATH_SUFFIXES "" "Release" "RelWithDebInfo" "MinSizeRel")