Skip to content

Commit

Permalink
Several changes:
Browse files Browse the repository at this point in the history
 - Make all Windows includes lowercase for MinGW cross-compiling from Linux
 - AbstractUserDatabase: just include WDllDefs instead of own C++11 check
 - JWt fixes (for new GCC versions)
  • Loading branch information
RockinRoel committed Aug 21, 2018
1 parent 91542c6 commit 2449394
Show file tree
Hide file tree
Showing 9 changed files with 15 additions and 28 deletions.
15 changes: 1 addition & 14 deletions src/Wt/Auth/AbstractUserDatabase
Original file line number Diff line number Diff line change
Expand Up @@ -13,22 +13,9 @@
#include <Wt/Auth/IssuedToken>
#include <Wt/Auth/OAuthClient>
#include <Wt/Auth/WAuthGlobal>
#include <Wt/WDllDefs.h>
#include <Wt/Json/Value>

#ifndef WT_CX11

#if defined(__GXX_EXPERIMENTAL_CXX0X__) || __cplusplus >= 201103L
#define WT_CXX11
#endif

#ifdef WT_CXX11
#define WT_CXX11ONLY(x) x
#else
#define WT_CXX11ONLY(x)
#endif

#endif

namespace Wt {
namespace Auth {

Expand Down
2 changes: 1 addition & 1 deletion src/Wt/Dbo/WDboDllDefs.h
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@

#ifndef WT_CXX11

#if defined(__GXX_EXPERIMENTAL_CXX0X__) || __cplusplus >= 201103L || _MSC_VER >= 1900
#if (defined(__GXX_EXPERIMENTAL_CXX0X__) || __cplusplus >= 201103L || _MSC_VER >= 1900) && !defined(WT_TARGET_JAVA)
#define WT_CXX11
#endif

Expand Down
2 changes: 1 addition & 1 deletion src/Wt/Dbo/backend/MSSQLServer.C
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
#include "Wt/Dbo/Exception"

#ifdef WT_WIN32
#include <Windows.h>
#include <windows.h>
#endif // WT_WIN32
#include <sql.h>
#include <sqlext.h>
Expand Down
2 changes: 1 addition & 1 deletion src/Wt/WDllDefs.h
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ typedef unsigned __int32 uint32_t; /* 32 bit unsigned */

#ifndef WT_CXX11

#if defined(__GXX_EXPERIMENTAL_CXX0X__) || __cplusplus >= 201103L || _MSC_VER >= 1900
#if (defined(__GXX_EXPERIMENTAL_CXX0X__) || __cplusplus >= 201103L || _MSC_VER >= 1900) && !defined(WT_TARGET_JAVA)
#define WT_CXX11
#endif

Expand Down
4 changes: 2 additions & 2 deletions src/Wt/WRasterImage-d2d1.C
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,9 @@
// WIC
#include <wincodec.h>
// DirectWrite
#include <Dwrite.h>
#include <dwrite.h>

#include <Shlwapi.h> // for SHCreateMemStream
#include <shlwapi.h> // for SHCreateMemStream

#ifndef M_PI
#define M_PI 3.14159265358979323846
Expand Down
2 changes: 1 addition & 1 deletion src/Wt/WServerGLWidget.C
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@

#ifdef WIN32_GL
#include <GL/wglew.h>
#include <Windows.h>
#include <windows.h>
#endif

#include "Wt/WApplication"
Expand Down
12 changes: 6 additions & 6 deletions src/Wt/WTransform.C
Original file line number Diff line number Diff line change
Expand Up @@ -593,12 +593,12 @@ bool WTransform::closeTo(const WTransform &other) const

static const double EPS = 1E-12;

return std::abs(m_[0] - other.m_[0]) <= EPS &&
std::abs(m_[1] - other.m_[1]) <= EPS &&
std::abs(m_[2] - other.m_[2]) <= EPS &&
std::abs(m_[3] - other.m_[3]) <= EPS &&
std::abs(m_[4] - other.m_[4]) <= EPS &&
std::abs(m_[5] - other.m_[5]) <= EPS;
return std::fabs(m_[0] - other.m_[0]) <= EPS &&
std::fabs(m_[1] - other.m_[1]) <= EPS &&
std::fabs(m_[2] - other.m_[2]) <= EPS &&
std::fabs(m_[3] - other.m_[3]) <= EPS &&
std::fabs(m_[4] - other.m_[4]) <= EPS &&
std::fabs(m_[5] - other.m_[5]) <= EPS;
}

}
2 changes: 1 addition & 1 deletion src/isapi/Isapi.C
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
#include "IsapiRequest.h"

#include <windows.h>
#include <WtsApi32.h>
#include <wtsapi32.h>
#include <httpext.h>

#include <fstream>
Expand Down
2 changes: 1 addition & 1 deletion src/isapi/WServer.C
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@

#include <boost/algorithm/string.hpp>

#include <Windows.h>
#include <windows.h>
#include <fstream>

namespace Wt {
Expand Down

0 comments on commit 2449394

Please sign in to comment.