diff --git a/.gitignore b/.gitignore index b8383fd51..774478e2b 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,4 @@ build *~ Doxygen +prebuilt \ No newline at end of file diff --git a/CMakeLists.txt b/CMakeLists.txt index ca21824b6..beed45084 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -8,6 +8,35 @@ option(USE_MPG123 "use mpg123 + libsndfile for sound" ON) # We probably support older versions than this. cmake_minimum_required(VERSION 2.6) + +# +# Pre-built binaries being used? +# +IF(EXISTS "${CMAKE_SOURCE_DIR}/prebuilt/vc100-mt-gd/ogre_1_7_1") + set(PREBUILT_DIR "${CMAKE_SOURCE_DIR}/prebuilt/vc100-mt-gd") + message (STATUS "OpenMW pre-built binaries found at ${PREBUILT_DIR}.") + + SET(ENV{OGRE_HOME} "${PREBUILT_DIR}/ogre_1_7_1") + + SET(ENV{BOOST_ROOT} "${PREBUILT_DIR}/boost_1_42_0") + set(Boost_USE_STATIC_LIBS ON) + set(Boost_USE_MULTITHREADED ON) + set(ENV{BOOST_INCLUDEDIR} "${BOOST_ROOT}/include") + set(ENV{BOOST_LIBRARYDIR} "${BOOST_ROOT}/lib") + + set(ENV{FREETYPE_DIR} "${PREBUILT_DIR}/freetype-2.3.5-1") + + set(USE_MPG123 OFF) + set(USE_AUDIERE ON) + set(AUDIERE_INCLUDE_DIR "${PREBUILT_DIR}/audiere-1.9.4/include") + set(AUDIERE_LIBRARY "${PREBUILT_DIR}/audiere-1.9.4/lib/audiere.lib") + + set(ENV{OPENALDIR} "${PREBUILT_DIR}/OpenAL 1.1 SDK") + +ELSE() + message (STATUS "OpenMW pre-built binaries not found. Using standard locations.") +ENDIF() + # Add path for CMake scripts set(CMAKE_MODULE_PATH ${CMAKE_SOURCE_DIR}/cmake/) @@ -166,6 +195,9 @@ if (WIN32) else (WIN32) set(PLATFORM_INCLUDE_DIR "") endif (WIN32) +if (MSVC10) +set(PLATFORM_INCLUDE_DIR "") +endif() # Dependencies @@ -180,10 +212,10 @@ include_directories("." ${CMAKE_HOME_DIRECTORY}/extern/caelum/include ${CMAKE_HOME_DIRECTORY}/extern/mygui_3.0.1/MyGUIEngine/include ${CMAKE_HOME_DIRECTORY}/extern/mygui_3.0.1/OgrePlatform/include + ${OPENAL_INCLUDE_DIR} ${LIBDIR} ) - link_directories(${Boost_LIBRARY_DIRS} ${OGRE_LIB_DIR}) add_subdirectory( extern/caelum ) diff --git a/apps/openmw/CMakeLists.txt b/apps/openmw/CMakeLists.txt index 6863b2e13..e0986ae32 100644 --- a/apps/openmw/CMakeLists.txt +++ b/apps/openmw/CMakeLists.txt @@ -205,7 +205,7 @@ target_link_libraries(openmw ${SOUND_INPUT_LIBRARY} caelum MyGUIEngine - MyGUI.OgrePlatform + MyGUIOgrePlatform ) if (APPLE) diff --git a/apps/openmw/mwgui/window_manager.cpp b/apps/openmw/mwgui/window_manager.cpp index 1752743f7..995b39e88 100644 --- a/apps/openmw/mwgui/window_manager.cpp +++ b/apps/openmw/mwgui/window_manager.cpp @@ -15,8 +15,8 @@ WindowManager::WindowManager(MyGUI::Gui *_gui, MWWorld::Environment& environment { // Get size info from the Gui object assert(gui); - int w = gui->getViewWidth(); - int h = gui->getViewHeight(); + int w = gui->getViewSize().width; + int h = gui->getViewSize().height; hud = new HUD(w,h); menu = new MainMenu(w,h); diff --git a/apps/openmw/mwworld/actionteleport.cpp b/apps/openmw/mwworld/actionteleport.cpp index 4edc02c30..f757b70be 100644 --- a/apps/openmw/mwworld/actionteleport.cpp +++ b/apps/openmw/mwworld/actionteleport.cpp @@ -11,7 +11,7 @@ namespace MWWorld : mCellName (cellName), mPosition (position) {} - void ActionTeleportPlayer::ActionTeleportPlayer::execute (Environment& environment) + void ActionTeleportPlayer::execute (Environment& environment) { environment.mWorld->changeCell (mCellName, mPosition); } diff --git a/extern/mygui_3.0.1/OgrePlatform/CMakeLists.txt b/extern/mygui_3.0.1/OgrePlatform/CMakeLists.txt index 38c5c714a..2fa38a242 100644 --- a/extern/mygui_3.0.1/OgrePlatform/CMakeLists.txt +++ b/extern/mygui_3.0.1/OgrePlatform/CMakeLists.txt @@ -4,6 +4,6 @@ include_directories( ${OGRE_INCLUDE_DIR} ) include(MyGUI.OgrePlatform.list) -add_library(MyGUI.OgrePlatform ${HEADER_FILES} ${SOURCE_FILES}) -target_link_libraries(MyGUI.OgrePlatform ${OGRE_LIBRARIES}) +add_library(MyGUIOgrePlatform ${HEADER_FILES} ${SOURCE_FILES}) +target_link_libraries(MyGUIOgrePlatform ${OGRE_LIBRARIES}) link_directories(${OGRE_LIB_DIR}) diff --git a/libs/platform/stdint.h b/libs/platform/stdint.h index 499590da7..00af741b1 100644 --- a/libs/platform/stdint.h +++ b/libs/platform/stdint.h @@ -2,6 +2,12 @@ #ifndef _STDINT_WRAPPER_H #define _STDINT_WRAPPER_H +#if (_MSC_VER >= 1600) + +#include + +#else + #include // Pull the boost names into the global namespace for convenience @@ -11,3 +17,5 @@ using boost::int64_t; using boost::uint64_t; #endif + +#endif