|
|
|
@ -96,7 +96,7 @@ endif()
|
|
|
|
|
# Set up common paths
|
|
|
|
|
if (APPLE)
|
|
|
|
|
set(MORROWIND_DATA_FILES "./data" CACHE PATH "location of Morrowind data files")
|
|
|
|
|
set(OPENMW_RESOURCE_FILES "./resources" CACHE PATH "location of OpenMW resources files")
|
|
|
|
|
set(OPENMW_RESOURCE_FILES "../Resources/resources" CACHE PATH "location of OpenMW resources files")
|
|
|
|
|
elseif(UNIX)
|
|
|
|
|
# Paths
|
|
|
|
|
SET(BINDIR "${CMAKE_INSTALL_PREFIX}/bin" CACHE PATH "Where to install binaries")
|
|
|
|
@ -286,6 +286,11 @@ endif (APPLE)
|
|
|
|
|
# Set up DEBUG define
|
|
|
|
|
set_directory_properties(PROPERTIES COMPILE_DEFINITIONS_DEBUG DEBUG=1)
|
|
|
|
|
|
|
|
|
|
if (NOT APPLE)
|
|
|
|
|
set(OPENMW_MYGUI_FILES_ROOT ${OpenMW_BINARY_DIR})
|
|
|
|
|
set(OPENMW_SHADERS_ROOT ${OpenMW_BINARY_DIR})
|
|
|
|
|
endif ()
|
|
|
|
|
|
|
|
|
|
add_subdirectory(files/)
|
|
|
|
|
|
|
|
|
|
# Specify build paths
|
|
|
|
@ -307,11 +312,15 @@ endif (APPLE)
|
|
|
|
|
configure_file(${OpenMW_SOURCE_DIR}/files/settings-default.cfg
|
|
|
|
|
"${OpenMW_BINARY_DIR}/settings-default.cfg")
|
|
|
|
|
|
|
|
|
|
configure_file(${OpenMW_SOURCE_DIR}/files/openmw.cfg.local
|
|
|
|
|
"${OpenMW_BINARY_DIR}/openmw.cfg")
|
|
|
|
|
|
|
|
|
|
configure_file(${OpenMW_SOURCE_DIR}/files/openmw.cfg
|
|
|
|
|
"${OpenMW_BINARY_DIR}/openmw.cfg.install")
|
|
|
|
|
if (NOT APPLE)
|
|
|
|
|
configure_file(${OpenMW_SOURCE_DIR}/files/openmw.cfg.local
|
|
|
|
|
"${OpenMW_BINARY_DIR}/openmw.cfg")
|
|
|
|
|
configure_file(${OpenMW_SOURCE_DIR}/files/openmw.cfg
|
|
|
|
|
"${OpenMW_BINARY_DIR}/openmw.cfg.install")
|
|
|
|
|
else ()
|
|
|
|
|
configure_file(${OpenMW_SOURCE_DIR}/files/openmw.cfg
|
|
|
|
|
"${OpenMW_BINARY_DIR}/openmw.cfg")
|
|
|
|
|
endif ()
|
|
|
|
|
|
|
|
|
|
configure_file(${OpenMW_SOURCE_DIR}/files/openmw-cs.cfg
|
|
|
|
|
"${OpenMW_BINARY_DIR}/openmw-cs.cfg")
|
|
|
|
@ -725,14 +734,7 @@ if (APPLE)
|
|
|
|
|
configure_file("${QT_COCOA_PLUGIN_PATH}" "${OPENCS_BUNDLE_NAME}/Contents/MacOS/${QT_COCOA_PLUGIN_GROUP}/${QT_COCOA_PLUGIN_NAME}" COPYONLY)
|
|
|
|
|
endif ()
|
|
|
|
|
|
|
|
|
|
set(INSTALL_SUBDIR OpenMW)
|
|
|
|
|
|
|
|
|
|
install(DIRECTORY "${APP_BUNDLE_DIR}" USE_SOURCE_PERMISSIONS DESTINATION "${INSTALL_SUBDIR}" COMPONENT Runtime)
|
|
|
|
|
install(DIRECTORY "${OpenMW_BINARY_DIR}/resources" DESTINATION "${INSTALL_SUBDIR}" COMPONENT Runtime)
|
|
|
|
|
install(FILES "${OpenMW_BINARY_DIR}/openmw.cfg.install" RENAME "openmw.cfg" DESTINATION "${INSTALL_SUBDIR}" COMPONENT Runtime)
|
|
|
|
|
install(FILES "${OpenMW_BINARY_DIR}/settings-default.cfg" DESTINATION "${INSTALL_SUBDIR}" COMPONENT Runtime)
|
|
|
|
|
install(FILES "${OpenMW_BINARY_DIR}/gamecontrollerdb.txt" DESTINATION "${INSTALL_SUBDIR}" COMPONENT Runtime)
|
|
|
|
|
install(FILES "${OpenMW_BINARY_DIR}/openmw-cs.cfg" DESTINATION "${INSTALL_SUBDIR}" COMPONENT Runtime)
|
|
|
|
|
install(DIRECTORY "${APP_BUNDLE_DIR}" USE_SOURCE_PERMISSIONS DESTINATION "." COMPONENT Runtime)
|
|
|
|
|
|
|
|
|
|
set(CPACK_GENERATOR "DragNDrop")
|
|
|
|
|
set(CPACK_PACKAGE_VERSION ${OPENMW_VERSION})
|
|
|
|
@ -740,8 +742,8 @@ if (APPLE)
|
|
|
|
|
set(CPACK_PACKAGE_VERSION_MINOR ${OPENMW_VERSION_MINOR})
|
|
|
|
|
set(CPACK_PACKAGE_VERSION_PATCH ${OPENMW_VERSION_RELEASE})
|
|
|
|
|
|
|
|
|
|
set(INSTALLED_OPENMW_APP "\${CMAKE_INSTALL_PREFIX}/${INSTALL_SUBDIR}/${APP_BUNDLE_NAME}")
|
|
|
|
|
set(INSTALLED_OPENCS_APP "\${CMAKE_INSTALL_PREFIX}/${INSTALL_SUBDIR}/${OPENCS_BUNDLE_NAME}")
|
|
|
|
|
set(INSTALLED_OPENMW_APP "\${CMAKE_INSTALL_PREFIX}/${APP_BUNDLE_NAME}")
|
|
|
|
|
set(INSTALLED_OPENCS_APP "\${CMAKE_INSTALL_PREFIX}/${OPENCS_BUNDLE_NAME}")
|
|
|
|
|
|
|
|
|
|
install(CODE "
|
|
|
|
|
set(BU_CHMOD_BUNDLE_ITEMS ON)
|
|
|
|
@ -785,8 +787,8 @@ if (APPLE)
|
|
|
|
|
set(${plugins_var} ${PLUGINS} PARENT_SCOPE)
|
|
|
|
|
endfunction (install_plugins_for_bundle)
|
|
|
|
|
|
|
|
|
|
install_plugins_for_bundle("${INSTALL_SUBDIR}/${APP_BUNDLE_NAME}" PLUGINS)
|
|
|
|
|
install_plugins_for_bundle("${INSTALL_SUBDIR}/${OPENCS_BUNDLE_NAME}" OPENCS_PLUGINS)
|
|
|
|
|
install_plugins_for_bundle("${APP_BUNDLE_NAME}" PLUGINS)
|
|
|
|
|
install_plugins_for_bundle("${OPENCS_BUNDLE_NAME}" OPENCS_PLUGINS)
|
|
|
|
|
|
|
|
|
|
set(PLUGINS ${PLUGINS} "${INSTALLED_OPENMW_APP}/Contents/MacOS/${QT_COCOA_PLUGIN_GROUP}/${QT_COCOA_PLUGIN_NAME}")
|
|
|
|
|
set(OPENCS_PLUGINS ${OPENCS_PLUGINS} "${INSTALLED_OPENCS_APP}/Contents/MacOS/${QT_COCOA_PLUGIN_GROUP}/${QT_COCOA_PLUGIN_NAME}")
|
|
|
|
|