From 3a41f37bdfe0959f305ab9a50e7aebdfcf1642db Mon Sep 17 00:00:00 2001 From: Chris Ratliff Date: Thu, 7 Mar 2019 11:55:16 -0500 Subject: [PATCH] allow OGRE_PLUGIN_PATH to be defined at cmake config time (#1274) --- CMakeLists.txt | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index f0730361d4..761e04ad78 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -56,11 +56,13 @@ if(NOT OGRE_OV_FOUND) endif(NOT OGRE_OV_FOUND) ## Find OGRE Plugin path (not necessarily platform-independent, I guess) -execute_process(COMMAND - ${PKG_CONFIG_EXECUTABLE} --variable=plugindir OGRE - OUTPUT_VARIABLE OGRE_PLUGIN_PATH - OUTPUT_STRIP_TRAILING_WHITESPACE - ) +if(NOT DEFINED OGRE_PLUGIN_PATH) + execute_process(COMMAND + ${PKG_CONFIG_EXECUTABLE} --variable=plugindir OGRE + OUTPUT_VARIABLE OGRE_PLUGIN_PATH + OUTPUT_STRIP_TRAILING_WHITESPACE + ) +endif(NOT DEFINED OGRE_PLUGIN_PATH) message(STATUS OGRE_PLUGIN_PATH=${OGRE_PLUGIN_PATH}) # find absolute path of ogre libraries.