1
0
Fork 1
mirror of https://github.com/TES3MP/openmw-tes3mp.git synced 2025-01-16 04:19:55 +00:00
openmw-tes3mp/apps/openmw/CMakeLists.txt

202 lines
6.3 KiB
Text
Raw Normal View History

# local files
2014-08-26 15:31:34 +00:00
set(GAME
main.cpp
engine.cpp
2014-09-04 21:17:31 +00:00
${CMAKE_SOURCE_DIR}/files/windows/openmw.rc
2014-08-26 15:31:34 +00:00
)
if (ANDROID)
2015-03-15 17:15:58 +00:00
set(GAME ${GAME} android_commandLine.cpp)
2014-08-26 15:31:34 +00:00
set(GAME ${GAME} android_main.c)
2014-09-05 22:02:39 +00:00
endif()
2014-08-26 15:31:34 +00:00
2014-09-05 22:02:39 +00:00
if(NOT WIN32 AND NOT ANDROID)
set(GAME ${GAME} crashcatcher.cpp)
endif()
set(GAME_HEADER
engine.hpp
2012-01-28 00:36:17 +00:00
)
source_group(game FILES ${GAME} ${GAME_HEADER})
2011-10-22 11:55:06 +00:00
add_openmw_dir (mwrender
2015-04-18 23:57:52 +00:00
actors objects renderingmanager animation sky npcanimation vismask
2015-04-21 21:40:10 +00:00
creatureanimation effectmanager util renderinginterface
2015-04-19 01:05:47 +00:00
# debugging camera activatoranimation
2015-04-21 21:40:10 +00:00
# localmap occlusionquery water shadows
# characterpreview globalmap ripplesimulation refraction
2015-04-19 15:55:56 +00:00
# terrainstorage renderconst weaponanimation
)
#add_openmw_dir (mwinput
# inputmanagerimp
# )
add_openmw_dir (mwgui
2013-04-10 17:05:15 +00:00
textinput widgets race class birth review windowmanagerimp console dialogue
2013-05-06 13:30:23 +00:00
windowbase statswindow messagebox journalwindow charactercreation
mapwindow windowpinnablebase tooltips scrollwindow bookwindow
formatting inventorywindow container hud countdialog tradewindow settingswindow
confirmationdialog alchemywindow referenceinterface spellwindow mainmenu quickkeysmenu
2012-09-22 22:36:20 +00:00
itemselection spellbuyingwindow loadingscreen levelupdialog waitdialog spellcreationdialog
enchantingdialog trainingwindow travelwindow exposedwindow cursor spellicons
merchantrepair repair soulgemdialog companionwindow bookpage journalviewmodel journalbooks
itemmodel containeritemmodel inventoryitemmodel sortfilteritemmodel itemview
tradeitemmodel companionitemmodel pickpocketitemmodel controllers savegamedialog
recharge mode videowidget backgroundimage itemwidget screenfader debugwindow spellmodel spellview
2015-04-24 19:55:30 +00:00
draganddrop timeadvancer jailscreen myguiplatform myguirendermanager myguidatamanager
)
add_openmw_dir (mwdialogue
dialoguemanagerimp journalimp journalentry quest topic filter selectwrapper hypertextparser keywordsearch scripttest
)
add_openmw_dir (mwscript
locals scriptmanagerimp compilercontext interpretercontext cellextensions miscextensions
guiextensions soundextensions skyextensions statsextensions containerextensions
aiextensions controlextensions extensions globalscripts ref dialogueextensions
2014-03-16 20:39:46 +00:00
animationextensions transformationextensions consoleextensions userextensions
)
add_openmw_dir (mwsound
2015-04-19 18:07:18 +00:00
soundmanagerimp openal_output ffmpeg_decoder sound sound_decoder sound_output loudness libavwrapper movieaudiofactory
)
add_openmw_dir (mwworld
refdata worldimp scene globals class action nullaction actionteleport
2012-11-17 17:17:08 +00:00
containerstore actiontalk actiontake manualref player cellfunctors failedaction
cells localscripts customdata inventorystore ptr actionopen actionread
actionequip timestamp actionalchemy cellstore actionapply actioneat
2013-04-28 12:59:15 +00:00
esmstore store recordcmp fallback actionrepair actionsoulgem livecellref actiondoor
contentloader esmloader actiontrap cellreflist cellref physicssystem weather
# projectilemanager
)
add_openmw_dir (mwclass
classes activator creature npc weapon armor potion apparatus book clothing container door
ingredient creaturelevlist itemlevlist light lockpick misc probe repair static
)
add_openmw_dir (mwmechanics
mechanicsmanagerimp stat creaturestats magiceffects movement
drawstate spells activespells npcstats aipackage aisequence aipursue alchemy aiwander aitravel aifollow aiavoiddoor
aiescort aiactivate aicombat repair enchanting pathfinding pathgrid security spellsuccess spellcasting
disease pickpocket levelledlist combat steering obstacle autocalcspell difficultyscaling aicombataction actor summoning
2015-04-24 23:20:07 +00:00
character actors objects
)
2013-11-16 09:31:46 +00:00
add_openmw_dir (mwstate
statemanagerimp charactermanager character
)
add_openmw_dir (mwbase
environment world scriptmanager dialoguemanager journal soundmanager mechanicsmanager
inputmanager windowmanager statemanager
)
# Main executable
if (ANDROID)
2014-09-05 22:02:39 +00:00
set(BOOST_COMPONENTS system filesystem program_options thread wave atomic)
2014-08-05 20:46:21 +00:00
else ()
2014-09-05 22:02:39 +00:00
set(BOOST_COMPONENTS system filesystem program_options thread wave)
endif ()
2014-09-05 22:02:39 +00:00
2014-05-22 11:42:47 +00:00
if(WIN32)
set(BOOST_COMPONENTS ${BOOST_COMPONENTS} locale)
endif(WIN32)
2013-12-29 21:25:49 +00:00
find_package(Boost REQUIRED COMPONENTS ${BOOST_COMPONENTS})
2013-02-03 12:47:55 +00:00
2015-04-24 19:55:30 +00:00
# for MyGUI platform
find_package(OpenGL REQUIRED)
if (NOT ANDROID)
2014-08-06 03:59:39 +00:00
add_executable(openmw
${OPENMW_FILES}
${GAME} ${GAME_HEADER}
${APPLE_BUNDLE_RESOURCES}
)
2014-08-05 20:46:21 +00:00
else ()
2014-09-14 09:28:28 +00:00
add_library(openmw
2014-08-06 03:59:39 +00:00
SHARED
${OPENMW_FILES}
${GAME} ${GAME_HEADER}
)
2014-08-05 20:46:21 +00:00
endif ()
2011-11-06 08:30:15 +00:00
2010-08-13 20:30:22 +00:00
# Sound stuff - here so CMake doesn't stupidly recompile EVERYTHING
# when we change the backend.
include_directories(${SOUND_INPUT_INCLUDES})
2010-08-13 20:30:22 +00:00
target_link_libraries(openmw
${OENGINE_LIBRARY}
2012-01-28 00:36:17 +00:00
${OGRE_LIBRARIES}
${OGRE_STATIC_PLUGINS}
${OPENSCENEGRAPH_LIBRARIES}
2012-01-28 00:36:17 +00:00
${Boost_LIBRARIES}
${OPENAL_LIBRARY}
${SOUND_INPUT_LIBRARY}
${BULLET_LIBRARIES}
${MYGUI_LIBRARIES}
${SDL2_LIBRARY}
${MYGUI_PLATFORM_LIBRARIES}
2015-04-24 19:55:30 +00:00
${OPENGL_gl_LIBRARY}
2015-04-19 18:14:06 +00:00
"osg-ffmpeg-videoplayer"
2012-08-12 18:45:02 +00:00
"oics"
components
)
if (ANDROID)
2014-08-06 03:59:39 +00:00
target_link_libraries(openmw
2014-09-14 09:28:28 +00:00
${OGRE_STATIC_PLUGINS}
2014-08-06 03:59:39 +00:00
EGL
android
log
2014-09-14 09:28:28 +00:00
dl
2014-08-06 03:59:39 +00:00
MyGUI.OgrePlatform
MyGUIEngineStatic
Plugin_StrangeButtonStatic
cpufeatures
BulletCollision
BulletDynamics
2014-09-14 09:28:28 +00:00
LinearMath
2014-08-06 03:59:39 +00:00
)
endif (ANDROID)
2013-09-14 11:33:49 +00:00
if (USE_SYSTEM_TINYXML)
target_link_libraries(openmw ${TINYXML_LIBRARIES})
endif()
2013-06-27 19:45:32 +00:00
if (NOT UNIX)
target_link_libraries(openmw ${SDL2MAIN_LIBRARY})
endif()
# Fix for not visible pthreads functions for linker with glibc 2.15
if (UNIX AND NOT APPLE)
target_link_libraries(openmw ${CMAKE_THREAD_LIBS_INIT})
endif()
2012-01-28 00:36:17 +00:00
if(APPLE)
2012-08-20 17:05:02 +00:00
find_library(COCOA_FRAMEWORK Cocoa)
find_library(IOKIT_FRAMEWORK IOKit)
2013-06-15 10:47:33 +00:00
target_link_libraries(openmw ${COCOA_FRAMEWORK} ${IOKIT_FRAMEWORK})
if (FFMPEG_FOUND)
find_library(COREVIDEO_FRAMEWORK CoreVideo)
find_library(VDA_FRAMEWORK VideoDecodeAcceleration)
target_link_libraries(openmw ${COREVIDEO_FRAMEWORK} ${VDA_FRAMEWORK})
endif()
2012-01-28 00:36:17 +00:00
endif(APPLE)
if (BUILD_WITH_CODE_COVERAGE)
add_definitions (--coverage)
target_link_libraries(openmw gcov)
endif()
if (MSVC)
# Debug version needs increased number of sections beyond 2^16
if (CMAKE_CL_64)
set (CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} /bigobj")
endif (CMAKE_CL_64)
endif (MSVC)