From 47e2aecb710615b6752adc9a487ba425a2edc11f Mon Sep 17 00:00:00 2001 From: Matthias Braun Date: Tue, 23 Jan 2007 12:26:05 +0000 Subject: [PATCH] From the README.txt file: WARNING This msvc build is totally unsupported and experimental! This is for people who know what they are doing. Please don't annoy us with questions if you don't know: - how c++ works and how to fix smaller errors yourself - what an include directory is - how to make a windows application find .dll files - what a .lib file does In general fix the stuff yourself, you probably know msvc++ better than me anyway. Apart from that patches which keep these project files running are always welcome ;-) SVN-Revision: 4658 --- mk/msvc/README.txt | 11 + mk/msvc/config.h | 158 ++++ mk/msvc/stdint.h | 7 + mk/msvc/supertux.sln | 20 + mk/msvc/supertux.vcproj | 2019 ++++++++++++++++++++++++++++++++++++++++++++++ mk/msvc/supertux.vsprops | 15 + mk/msvc/unistd.h | 1 + 7 files changed, 2231 insertions(+) create mode 100644 mk/msvc/README.txt create mode 100644 mk/msvc/config.h create mode 100644 mk/msvc/stdint.h create mode 100644 mk/msvc/supertux.sln create mode 100644 mk/msvc/supertux.vcproj create mode 100644 mk/msvc/supertux.vsprops create mode 100644 mk/msvc/unistd.h diff --git a/mk/msvc/README.txt b/mk/msvc/README.txt new file mode 100644 index 000000000..dbfa1bdd1 --- /dev/null +++ b/mk/msvc/README.txt @@ -0,0 +1,11 @@ +WARNING This msvc build is totally unsupported and experimental! This is for +people who know what they are doing. Please don't annoy us with questions if +you don't know: +- how c++ works and how to fix smaller errors yourself +- what an include directory is +- how to make a windows application find .dll files +- what a .lib file does + +In general fix the stuff yourself, you probably know msvc++ better than me +anyway. Apart from that patches which keep these project files running are +always welcome ;-) diff --git a/mk/msvc/config.h b/mk/msvc/config.h new file mode 100644 index 000000000..0f88d4f9c --- /dev/null +++ b/mk/msvc/config.h @@ -0,0 +1,158 @@ +/* config.h.in. Generated from configure.ac by autoheader. */ + +/* Include pthread support for binary relocation? */ +//#undef BR_PTHREAD + +/* define to compile in debug checks */ +#define DEBUG + +/* Use binary relocation? */ +//#undef ENABLE_BINRELOC + +/* define if sqdbg should be enabled */ +//#undef ENABLE_SQDBG + +/* Use the Apple OpenGL framework. */ +//#undef HAVE_APPLE_OPENGL_FRAMEWORK + +/* Define to 1 if you have the header file, and it defines `DIR'. + */ +//#undef HAVE_DIRENT_H + +/* Define if you have the iconv() function. */ +//#undef HAVE_ICONV + +/* Define to 1 if you have the header file. */ +//#undef HAVE_INTTYPES_H + +/* Define to 1 if you have the `pthread' library (-lpthread). */ +//#undef HAVE_LIBPTHREAD + +/* Define to 1 if you have the header file. */ +#define HAVE_MEMORY_H 1 + +/* Define to 1 if you have the `mkdir' function. */ +//#define HAVE_MKDIR + +/* Define to 1 if you have the header file, and it defines `DIR'. */ +//#undef HAVE_NDIR_H + +/* Define if you have POSIX threads libraries and header files. */ +//#undef HAVE_PTHREAD + +/* Define to 1 if you have the header file. */ +//#undef HAVE_STDINT_H + +/* Define to 1 if you have the header file. */ +#define HAVE_STDLIB_H 1 + +/* Define to 1 if you have the `strdup' function. */ +#define HAVE_STRDUP 1 + +/* Define to 1 if you have the header file. */ +//#define HAVE_STRINGS_H + +/* Define to 1 if you have the header file. */ +#define HAVE_STRING_H 1 + +/* Define to 1 if you have the `strstr' function. */ +#define HAVE_STRSTR 1 + +/* Define to 1 if you have the header file, and it defines `DIR'. + */ +//#undef HAVE_SYS_DIR_H + +/* Define to 1 if you have the header file, and it defines `DIR'. + */ +//#undef HAVE_SYS_NDIR_H + +/* Define to 1 if you have the header file. */ +//#undef HAVE_SYS_STAT_H + +/* Define to 1 if you have the header file. */ +//#undef HAVE_SYS_TYPES_H + +/* Define to 1 if you have the header file. */ +//#undef HAVE_UNISTD_H + +/* Define to 1 if you have the header file. */ +#define HAVE_WINDOWS_H 1 + +/* Define as const if the declaration of iconv() needs const. */ +#define ICONV_CONST const + +/* Define to the address where bug reports for this package should be sent. */ +#define PACKAGE_BUGREPORT "" + +/* Define to the full name of this package. */ +#define PACKAGE_NAME "supertux" + +/* Define to the full name and version of this package. */ +#define PACKAGE_STRING "supertux 0.3.0-SVN" + +/* Define to the one symbol short name of this package. */ +#define PACKAGE_TARNAME "supertux" + +/* Define to the version of this package. */ +#define PACKAGE_VERSION "0.3.0-SVN" + +/* Define to necessary symbol if this constant uses a non-standard name on + your system. */ +//#undef PTHREAD_CREATE_JOINABLE + +/* The size of a `void *', as computed by sizeof. */ +#define SIZEOF_VOID_P 4 + +/* Define to 1 if you have the ANSI C header files. */ +#define STDC_HEADERS 1 + +/* Define to 1 if your processor stores words with the most significant byte + first (like Motorola and SPARC, unlike Intel and VAX). */ +// #undef WORDS_BIGENDIAN + +/* Define to 1 if `lex' declares `yytext' as a `char *' by default, not a + `char[]'. */ +// #undef YYTEXT_POINTER + +/* Define to empty if `const' does not conform to ANSI C. */ +// #undef const + + +#if SIZEOF_VOID_P == 8 +#define _SQ64 +#endif + +/* Disable some very annoying warnings */ +#pragma warning(disable: 4244) +#pragma warning(disable: 4267) +#pragma warning(disable: 4800) +#pragma warning(disable: 4103) + +/* some stuff is not in standard lib in msvc */ +#define _CRT_SECURE_NO_DEPRECATE +#define snprintf _snprintf +#define strcasecmp _strcmpi +#define strncasecmp _strncmpi +#define strdup _strdup + +#ifndef M_PI +#define M_PI 3.14159265358979323846 +#endif +#ifndef M_PI_2 +#define M_PI_2 (3.14159265358979323846/2.0) +#endif + +static inline int roundf(float val) +{ + if(val > 0) { + return (int) (val + 0.5f); + } else { + return (int) (val - 0.5f); + } +} + +// msvc has no sscanf it seems, this breaks demo recording, but who cares... +static inline int sscanf(...) +{ + return -1; +} \ No newline at end of file diff --git a/mk/msvc/stdint.h b/mk/msvc/stdint.h new file mode 100644 index 000000000..03906643a --- /dev/null +++ b/mk/msvc/stdint.h @@ -0,0 +1,7 @@ +#ifndef _STDINT_H +#define _STDINT_H + +// SDL config declares most stdint.h stuff... +#include + +#endif \ No newline at end of file diff --git a/mk/msvc/supertux.sln b/mk/msvc/supertux.sln new file mode 100644 index 000000000..aef43c5c5 --- /dev/null +++ b/mk/msvc/supertux.sln @@ -0,0 +1,20 @@ + +Microsoft Visual Studio Solution File, Format Version 9.00 +# Visual C++ Express 2005 +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "supertux", "supertux.vcproj", "{00ABCA25-5FAD-4603-8687-0F25240D7579}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|Win32 = Debug|Win32 + Release|Win32 = Release|Win32 + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {00ABCA25-5FAD-4603-8687-0F25240D7579}.Debug|Win32.ActiveCfg = Debug|Win32 + {00ABCA25-5FAD-4603-8687-0F25240D7579}.Debug|Win32.Build.0 = Debug|Win32 + {00ABCA25-5FAD-4603-8687-0F25240D7579}.Release|Win32.ActiveCfg = Release|Win32 + {00ABCA25-5FAD-4603-8687-0F25240D7579}.Release|Win32.Build.0 = Release|Win32 + EndGlobalSection + GlobalSection(SolutionProperties) = preSolution + HideSolutionNode = FALSE + EndGlobalSection +EndGlobal diff --git a/mk/msvc/supertux.vcproj b/mk/msvc/supertux.vcproj new file mode 100644 index 000000000..dd2020c51 --- /dev/null +++ b/mk/msvc/supertux.vcproj @@ -0,0 +1,2019 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/mk/msvc/supertux.vsprops b/mk/msvc/supertux.vsprops new file mode 100644 index 000000000..96ab7ebf9 --- /dev/null +++ b/mk/msvc/supertux.vsprops @@ -0,0 +1,15 @@ + + + + + diff --git a/mk/msvc/unistd.h b/mk/msvc/unistd.h new file mode 100644 index 000000000..b262fa10a --- /dev/null +++ b/mk/msvc/unistd.h @@ -0,0 +1 @@ +// dummy file -- 2.11.0