2011-03-28 23:36:26 +00:00
|
|
|
set(LAUNCHER
|
2011-06-24 15:37:12 +00:00
|
|
|
datafilespage.cpp
|
|
|
|
graphicspage.cpp
|
|
|
|
main.cpp
|
|
|
|
maindialog.cpp
|
|
|
|
playpage.cpp
|
2012-10-10 19:31:40 +00:00
|
|
|
|
2013-01-25 04:19:06 +00:00
|
|
|
settings/gamesettings.cpp
|
|
|
|
settings/graphicssettings.cpp
|
2013-02-11 14:01:00 +00:00
|
|
|
settings/launchersettings.cpp
|
2013-01-25 04:19:06 +00:00
|
|
|
|
2013-02-19 15:41:33 +00:00
|
|
|
utils/checkablemessagebox.cpp
|
2012-10-22 23:47:07 +00:00
|
|
|
utils/textinputdialog.cpp
|
2012-10-12 00:25:14 +00:00
|
|
|
|
2013-03-12 03:05:14 +00:00
|
|
|
${CMAKE_SOURCE_DIR}/files/launcher/launcher.rc
|
2011-03-28 23:36:26 +00:00
|
|
|
)
|
|
|
|
|
2011-06-24 15:37:12 +00:00
|
|
|
set(LAUNCHER_HEADER
|
|
|
|
datafilespage.hpp
|
|
|
|
graphicspage.hpp
|
|
|
|
maindialog.hpp
|
|
|
|
playpage.hpp
|
2012-10-10 19:31:40 +00:00
|
|
|
|
2013-01-25 04:19:06 +00:00
|
|
|
settings/gamesettings.hpp
|
|
|
|
settings/graphicssettings.hpp
|
2013-02-11 14:01:00 +00:00
|
|
|
settings/launchersettings.hpp
|
2013-01-25 04:19:06 +00:00
|
|
|
settings/settingsbase.hpp
|
|
|
|
|
2013-02-19 15:41:33 +00:00
|
|
|
utils/checkablemessagebox.hpp
|
2012-10-22 23:47:07 +00:00
|
|
|
utils/textinputdialog.hpp
|
2013-03-02 23:48:09 +00:00
|
|
|
|
2011-06-24 15:37:12 +00:00
|
|
|
)
|
2011-06-06 23:42:53 +00:00
|
|
|
|
2011-06-24 15:37:12 +00:00
|
|
|
# Headers that must be pre-processed
|
|
|
|
set(LAUNCHER_HEADER_MOC
|
|
|
|
datafilespage.hpp
|
|
|
|
graphicspage.hpp
|
|
|
|
maindialog.hpp
|
|
|
|
playpage.hpp
|
2012-10-10 19:31:40 +00:00
|
|
|
|
2013-02-19 15:41:33 +00:00
|
|
|
utils/checkablemessagebox.hpp
|
2012-10-22 23:47:07 +00:00
|
|
|
utils/textinputdialog.hpp
|
2011-03-28 23:36:26 +00:00
|
|
|
)
|
|
|
|
|
2013-03-02 22:49:31 +00:00
|
|
|
set(LAUNCHER_UI
|
2013-03-12 03:05:14 +00:00
|
|
|
${CMAKE_SOURCE_DIR}/files/ui/datafilespage.ui
|
|
|
|
${CMAKE_SOURCE_DIR}/files/ui/graphicspage.ui
|
|
|
|
${CMAKE_SOURCE_DIR}/files/ui/mainwindow.ui
|
|
|
|
${CMAKE_SOURCE_DIR}/files/ui/playpage.ui
|
2013-03-02 22:49:31 +00:00
|
|
|
)
|
|
|
|
|
|
|
|
source_group(launcher FILES ${LAUNCHER} ${LAUNCHER_HEADER})
|
2011-06-24 15:37:12 +00:00
|
|
|
|
2011-03-28 23:36:26 +00:00
|
|
|
find_package(Qt4 REQUIRED)
|
|
|
|
set(QT_USE_QTGUI 1)
|
|
|
|
|
2012-03-12 01:31:37 +00:00
|
|
|
# Set some platform specific settings
|
|
|
|
if(WIN32)
|
|
|
|
set(GUI_TYPE WIN32)
|
|
|
|
set(QT_USE_QTMAIN TRUE)
|
|
|
|
endif(WIN32)
|
2011-06-26 13:37:06 +00:00
|
|
|
|
2013-03-07 02:00:59 +00:00
|
|
|
QT4_ADD_RESOURCES(RCC_SRCS ${CMAKE_SOURCE_DIR}/files/launcher/launcher.qrc)
|
2011-06-24 15:37:12 +00:00
|
|
|
QT4_WRAP_CPP(MOC_SRCS ${LAUNCHER_HEADER_MOC})
|
2013-03-02 23:48:09 +00:00
|
|
|
QT4_WRAP_UI(UI_HDRS ${LAUNCHER_UI})
|
2011-03-28 23:36:26 +00:00
|
|
|
|
|
|
|
include(${QT_USE_FILE})
|
2013-03-02 23:48:09 +00:00
|
|
|
include_directories(${CMAKE_CURRENT_BINARY_DIR})
|
2011-03-28 23:36:26 +00:00
|
|
|
|
|
|
|
# Main executable
|
2012-03-15 14:51:39 +00:00
|
|
|
IF(OGRE_STATIC)
|
|
|
|
IF(WIN32)
|
|
|
|
ADD_DEFINITIONS(-DENABLE_PLUGIN_Direct3D9 -DENABLE_PLUGIN_GL)
|
|
|
|
set(OGRE_STATIC_PLUGINS ${OGRE_RenderSystem_Direct3D9_LIBRARIES} ${OGRE_RenderSystem_GL_LIBRARIES})
|
|
|
|
ELSE(WIN32)
|
|
|
|
ADD_DEFINITIONS(-DENABLE_PLUGIN_GL)
|
|
|
|
set(OGRE_STATIC_PLUGINS ${OGRE_RenderSystem_GL_LIBRARIES})
|
|
|
|
ENDIF(WIN32)
|
|
|
|
ENDIF(OGRE_STATIC)
|
2011-06-24 19:42:18 +00:00
|
|
|
add_executable(omwlauncher
|
2012-03-12 01:31:37 +00:00
|
|
|
${GUI_TYPE}
|
2011-06-24 15:37:12 +00:00
|
|
|
${LAUNCHER}
|
2013-02-11 14:01:00 +00:00
|
|
|
${LAUNCHER_HEADER}
|
2011-06-24 15:37:12 +00:00
|
|
|
${RCC_SRCS}
|
|
|
|
${MOC_SRCS}
|
2013-03-02 22:49:31 +00:00
|
|
|
${UI_HDRS}
|
2011-03-28 23:36:26 +00:00
|
|
|
)
|
|
|
|
|
2011-06-24 19:42:18 +00:00
|
|
|
target_link_libraries(omwlauncher
|
2011-06-24 15:37:12 +00:00
|
|
|
${Boost_LIBRARIES}
|
|
|
|
${OGRE_LIBRARIES}
|
2012-10-12 00:25:14 +00:00
|
|
|
${OGRE_STATIC_PLUGINS}
|
2011-06-24 15:37:12 +00:00
|
|
|
${QT_LIBRARIES}
|
2011-11-06 08:30:15 +00:00
|
|
|
components
|
2011-03-28 23:36:26 +00:00
|
|
|
)
|
|
|
|
|
2011-09-30 07:36:06 +00:00
|
|
|
if(DPKG_PROGRAM)
|
|
|
|
INSTALL(TARGETS omwlauncher RUNTIME DESTINATION games COMPONENT omwlauncher)
|
|
|
|
endif()
|
|
|
|
|
2012-08-19 19:23:46 +00:00
|
|
|
if (BUILD_WITH_CODE_COVERAGE)
|
|
|
|
add_definitions (--coverage)
|
|
|
|
target_link_libraries(omwlauncher gcov)
|
|
|
|
endif()
|