forked from github/server
get the code to compile under vs2015 (disable warnings)
This commit is contained in:
parent
c47c9dbf64
commit
e8880db447
|
@ -1531,7 +1531,7 @@ report_computer(const char *filename, report_context * ctx, const char *charset)
|
||||||
fprintf(F, "\"%s\";charset\n", charset);
|
fprintf(F, "\"%s\";charset\n", charset);
|
||||||
fprintf(F, "\"%s\";locale\n", locale_name(f->locale));
|
fprintf(F, "\"%s\";locale\n", locale_name(f->locale));
|
||||||
fprintf(F, "%d;noskillpoints\n", 1);
|
fprintf(F, "%d;noskillpoints\n", 1);
|
||||||
fprintf(F, "%ld;date\n", ctx->report_time);
|
fprintf(F, "%lld;date\n", (long long)ctx->report_time);
|
||||||
fprintf(F, "\"%s\";Spiel\n", game_name());
|
fprintf(F, "\"%s\";Spiel\n", game_name());
|
||||||
fprintf(F, "\"%s\";Konfiguration\n", "Standard");
|
fprintf(F, "\"%s\";Konfiguration\n", "Standard");
|
||||||
fprintf(F, "\"%s\";Koordinaten\n", "Hex");
|
fprintf(F, "\"%s\";Koordinaten\n", "Hex");
|
||||||
|
|
|
@ -870,9 +870,9 @@ int eff_spelllevel(unit * u, const spell * sp, int cast_level, int range)
|
||||||
/* Ein Spruch mit Fixkosten wird immer mit der Stufe des Spruchs und
|
/* Ein Spruch mit Fixkosten wird immer mit der Stufe des Spruchs und
|
||||||
* nicht auf der Stufe des Magiers gezaubert */
|
* nicht auf der Stufe des Magiers gezaubert */
|
||||||
if (costtyp == SPC_FIX) {
|
if (costtyp == SPC_FIX) {
|
||||||
spellbook * spells = unit_get_spellbook(u);
|
spellbook * sb = unit_get_spellbook(u);
|
||||||
if (spells) {
|
if (sb) {
|
||||||
spellbook_entry * sbe = spellbook_get(spells, sp);
|
spellbook_entry * sbe = spellbook_get(sb, sp);
|
||||||
if (sbe) {
|
if (sbe) {
|
||||||
return _min(cast_level, sbe->level);
|
return _min(cast_level, sbe->level);
|
||||||
}
|
}
|
||||||
|
|
|
@ -34,6 +34,14 @@ OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||||
# undef MOUSE_MOVED
|
# undef MOUSE_MOVED
|
||||||
# define STDIO_CP 1252 /* log.c, convert to console character set */
|
# define STDIO_CP 1252 /* log.c, convert to console character set */
|
||||||
# pragma warning (disable: 4201 4214 4514 4115 4711)
|
# pragma warning (disable: 4201 4214 4514 4115 4711)
|
||||||
|
# pragma warning(disable: 4710)
|
||||||
|
/* warning C4710: function not inlined */
|
||||||
|
# pragma warning(disable: 4456)
|
||||||
|
/* warning C4456 : declaration of <name> hides previous local declaration */
|
||||||
|
# pragma warning(disable: 4457)
|
||||||
|
/* warning C4457: declaration of <name> hides function parameter */
|
||||||
|
# pragma warning(disable: 4459)
|
||||||
|
/* warning C4459: declaration of <name> hides global declaration */
|
||||||
# pragma warning(disable: 4056)
|
# pragma warning(disable: 4056)
|
||||||
/* warning C4056: overflow in floating point constant arithmetic */
|
/* warning C4056: overflow in floating point constant arithmetic */
|
||||||
# pragma warning(disable: 4201)
|
# pragma warning(disable: 4201)
|
||||||
|
|
|
@ -96,6 +96,10 @@ OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||||
#include <limits.h>
|
#include <limits.h>
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
|
|
||||||
|
#ifdef _MSC_VER
|
||||||
|
# pragma warning(disable: 4774) // TODO: remove this
|
||||||
|
#endif
|
||||||
|
|
||||||
extern int *storms;
|
extern int *storms;
|
||||||
extern int weeks_per_month;
|
extern int weeks_per_month;
|
||||||
extern int months_per_year;
|
extern int months_per_year;
|
||||||
|
|
|
@ -73,6 +73,10 @@ OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||||
|
|
||||||
#include "move.h"
|
#include "move.h"
|
||||||
|
|
||||||
|
#ifdef _MSC_VER
|
||||||
|
# pragma warning(disable: 4774) // TODO: remove this
|
||||||
|
#endif
|
||||||
|
|
||||||
#define SCALEWEIGHT 100 /* Faktor, um den die Anzeige von Gewichten skaliert wird */
|
#define SCALEWEIGHT 100 /* Faktor, um den die Anzeige von Gewichten skaliert wird */
|
||||||
|
|
||||||
bool nocr = false;
|
bool nocr = false;
|
||||||
|
|
|
@ -101,6 +101,10 @@
|
||||||
#include <attributes/hate.h>
|
#include <attributes/hate.h>
|
||||||
/* ----------------------------------------------------------------------- */
|
/* ----------------------------------------------------------------------- */
|
||||||
|
|
||||||
|
#ifdef _MSC_VER
|
||||||
|
# pragma warning(disable: 4774) // TODO: remove this
|
||||||
|
#endif
|
||||||
|
|
||||||
static double zero_effect = 0.0;
|
static double zero_effect = 0.0;
|
||||||
|
|
||||||
attrib_type at_wdwpyramid = {
|
attrib_type at_wdwpyramid = {
|
||||||
|
|
|
@ -0,0 +1,11 @@
|
||||||
|
@ECHO OFF
|
||||||
|
SET VSVERSION=14
|
||||||
|
SET SRCDIR=%CD%
|
||||||
|
CD ..
|
||||||
|
SET ERESSEA=%CD%
|
||||||
|
|
||||||
|
CD %SRCDIR%
|
||||||
|
mkdir build-vs%VSVERSION%
|
||||||
|
cd build-vs%VSVERSION%
|
||||||
|
"%ProgramFiles(x86)%\CMake\bin\cmake.exe" -G "Visual Studio %VSVERSION%" -DCMAKE_PREFIX_PATH="%ProgramFiles(x86)%/Lua/5.1;%ERESSEA%/dependencies-win32" -DCMAKE_MODULE_PATH="%SRCDIR%/cmake/Modules" -DCMAKE_SUPPRESS_REGENERATION=TRUE ..
|
||||||
|
PAUSE
|
Loading…
Reference in New Issue