mirror of
https://github.com/TES3MP/openmw-tes3mp.git
synced 2025-01-19 21:53:51 +00:00
Allow MinGW64 compilation in Windows/msys
This commit is contained in:
parent
e348c6baa9
commit
c3f350e3fb
6 changed files with 9 additions and 4 deletions
1
.gitignore
vendored
1
.gitignore
vendored
|
@ -13,6 +13,7 @@ Doxygen
|
||||||
|
|
||||||
## ides/editors
|
## ides/editors
|
||||||
*~
|
*~
|
||||||
|
*.bak
|
||||||
*.kdev4
|
*.kdev4
|
||||||
*.swp
|
*.swp
|
||||||
*.swo
|
*.swo
|
||||||
|
|
|
@ -385,7 +385,7 @@ class MovieAudioDecoder : public MWSound::Sound_Decoder
|
||||||
}
|
}
|
||||||
|
|
||||||
void open(const std::string&)
|
void open(const std::string&)
|
||||||
#ifdef _WIN32
|
#ifdef _MSC_VER
|
||||||
{ fail(std::string("Invalid call to ")+__FUNCSIG__); }
|
{ fail(std::string("Invalid call to ")+__FUNCSIG__); }
|
||||||
#else
|
#else
|
||||||
{ fail(std::string("Invalid call to ")+__PRETTY_FUNCTION__); }
|
{ fail(std::string("Invalid call to ")+__PRETTY_FUNCTION__); }
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
#include "worldimp.hpp"
|
#include "worldimp.hpp"
|
||||||
#ifdef _WIN32
|
#if defined(_WIN32) && !defined(__MINGW32__)
|
||||||
#include <boost/tr1/tr1/unordered_map>
|
#include <boost/tr1/tr1/unordered_map>
|
||||||
#elif defined HAVE_UNORDERED_MAP
|
#elif defined HAVE_UNORDERED_MAP
|
||||||
#include <unordered_map>
|
#include <unordered_map>
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
#ifndef COMPONENTS_FILES_CONFIGURATIONMANAGER_HPP
|
#ifndef COMPONENTS_FILES_CONFIGURATIONMANAGER_HPP
|
||||||
#define COMPONENTS_FILES_CONFIGURATIONMANAGER_HPP
|
#define COMPONENTS_FILES_CONFIGURATIONMANAGER_HPP
|
||||||
|
|
||||||
#ifdef _WIN32
|
#if defined(_WIN32) && !defined(__MINGW32__)
|
||||||
#include <boost/tr1/tr1/unordered_map>
|
#include <boost/tr1/tr1/unordered_map>
|
||||||
#elif defined HAVE_UNORDERED_MAP
|
#elif defined HAVE_UNORDERED_MAP
|
||||||
#include <unordered_map>
|
#include <unordered_map>
|
||||||
|
|
4
extern/sdl4ogre/sdlwindowhelper.cpp
vendored
4
extern/sdl4ogre/sdlwindowhelper.cpp
vendored
|
@ -31,7 +31,11 @@ SDLWindowHelper::SDLWindowHelper (SDL_Window* window, int w, int h,
|
||||||
#ifdef WIN32
|
#ifdef WIN32
|
||||||
case SDL_SYSWM_WINDOWS:
|
case SDL_SYSWM_WINDOWS:
|
||||||
// Windows code
|
// Windows code
|
||||||
|
#ifdef __MINGW64__
|
||||||
|
winHandle = Ogre::StringConverter::toString((DWORD_PTR)wmInfo.info.win.window);
|
||||||
|
#else
|
||||||
winHandle = Ogre::StringConverter::toString((unsigned long)wmInfo.info.win.window);
|
winHandle = Ogre::StringConverter::toString((unsigned long)wmInfo.info.win.window);
|
||||||
|
#endif /* __MINGW64__ */
|
||||||
break;
|
break;
|
||||||
#elif __MACOSX__
|
#elif __MACOSX__
|
||||||
case SDL_SYSWM_COCOA:
|
case SDL_SYSWM_COCOA:
|
||||||
|
|
|
@ -9,7 +9,7 @@
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
#if (defined(__APPLE__) && __MAC_OS_X_VERSION_MIN_REQUIRED < 1070) || defined(__MINGW32__)
|
#if (defined(__APPLE__) && __MAC_OS_X_VERSION_MIN_REQUIRED < 1070) || defined(__MINGW32__)
|
||||||
// need our own implementation of strnlen
|
// need our own implementation of strnlen
|
||||||
#ifdef __MINGW32__
|
#ifdef __MINGW32__ && !__MINGW64__
|
||||||
static size_t strnlen(const char *s, size_t n)
|
static size_t strnlen(const char *s, size_t n)
|
||||||
{
|
{
|
||||||
const char *p = (const char *)memchr(s, 0, n);
|
const char *p = (const char *)memchr(s, 0, n);
|
||||||
|
|
Loading…
Reference in a new issue