another fix

actorid
Nikolay Kasyanov 13 years ago
parent 582d7ab213
commit 0c739825f2

@ -256,14 +256,6 @@ if (${CMAKE_SYSTEM_NAME} MATCHES "Linux")
endif()
if (APPLE)
# prepare plugins
if (${CMAKE_BUILD_TYPE} MATCHES "Release")
set(OPENMW_RELEASE_BUILD TRUE)
endif()
if (${CMAKE_BUILD_TYPE} MATCHES "RelWithDebugInfo")
set(OPENMW_RELEASE_BUILD TRUE)
endif()
if (${OGRE_PLUGIN_DIR_REL}})
set(OGRE_PLUGINS_REL_FOUND TRUE)
endif ()
@ -272,18 +264,12 @@ if (APPLE)
set(OGRE_PLUGINS_DBG_FOUND TRUE)
endif ()
if (${OPENMW_RELEASE_BUILD} AND ${OGRE_PLUGINS_REL_FOUND})
if (${OGRE_PLUGINS_REL_FOUND})
set(OGRE_PLUGIN_DIR ${OGRE_PLUGIN_DIR_REL})
else ()
set(OGRE_PLUGIN_DIR ${OGRE_PLUGIN_DIR_DBG})
endif ()
if (NOT ${OPENMW_RELEASE_BUILD} AND ${OGRE_PLUGINS_DBG_FOUND})
set(OGRE_PLUGIN_DIR ${OGRE_PLUGIN_DIR_DBG})
else()
set(OGRE_PLUGIN_DIR ${OGRE_PLUGIN_DIR_REL})
endif()
set(OGRE_PLUGIN_DIR "${OGRE_PLUGIN_DIR}/")
configure_file(${OpenMW_SOURCE_DIR}/files/plugins.cfg.mac
@ -587,7 +573,7 @@ if (APPLE)
if (item MATCHES \"Frameworks\") # if it is a framework
# get last segment of path
get_filename_component(fname \"\${item}\" NAME_WE)
find_library(ri NAMES \${fname} PATHS \${exepath} \${dirs} /Library/Frameworks)
find_library(ri NAMES \${fname} PATHS \${exepath} \${dirs} \${CMAKE_SYSTEM_FRAMEWORK_PATH})
if (ri)
string(REGEX REPLACE \"^.*/Frameworks/.*\\\\.framework\" \"\" item_part \${item})
set(ri \"\${ri}\${item_part}\")

Loading…
Cancel
Save