WinRT: use OS-native vsnprintf, which allows SDL_Log to format wide strings (via %ls)
authorDavid Ludwig <dludwig@pobox.com>
Sun, 03 Feb 2013 12:33:15 -0500
changeset 8402d9464231555b
parent 8401 29ecd2eca4af
child 8403 fbf6bb26c8ce
WinRT: use OS-native vsnprintf, which allows SDL_Log to format wide strings (via %ls)
VisualC-WinRT/SDL/SDL_VS2012-WinRT.vcxproj
include/SDL_config_windowsrt.h
     1.1 --- a/VisualC-WinRT/SDL/SDL_VS2012-WinRT.vcxproj	Sat Feb 02 21:05:32 2013 -0500
     1.2 +++ b/VisualC-WinRT/SDL/SDL_VS2012-WinRT.vcxproj	Sun Feb 03 12:33:15 2013 -0500
     1.3 @@ -410,7 +410,7 @@
     1.4        <PrecompiledHeader>NotUsing</PrecompiledHeader>
     1.5        <CompileAsWinRT>false</CompileAsWinRT>
     1.6        <AdditionalIncludeDirectories>..\..\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
     1.7 -      <PreprocessorDefinitions>_WINDLL;%(PreprocessorDefinitions)</PreprocessorDefinitions>
     1.8 +      <PreprocessorDefinitions>_WINDLL;_CRT_SECURE_NO_WARNINGS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
     1.9      </ClCompile>
    1.10      <Link>
    1.11        <SubSystem>Console</SubSystem>
    1.12 @@ -424,7 +424,7 @@
    1.13        <PrecompiledHeader>NotUsing</PrecompiledHeader>
    1.14        <CompileAsWinRT>false</CompileAsWinRT>
    1.15        <AdditionalIncludeDirectories>..\..\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
    1.16 -      <PreprocessorDefinitions>_WINDLL;%(PreprocessorDefinitions)</PreprocessorDefinitions>
    1.17 +      <PreprocessorDefinitions>_WINDLL;_CRT_SECURE_NO_WARNINGS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
    1.18      </ClCompile>
    1.19      <Link>
    1.20        <SubSystem>Console</SubSystem>
    1.21 @@ -438,7 +438,7 @@
    1.22        <PrecompiledHeader>NotUsing</PrecompiledHeader>
    1.23        <CompileAsWinRT>false</CompileAsWinRT>
    1.24        <AdditionalIncludeDirectories>..\..\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
    1.25 -      <PreprocessorDefinitions>_WINDLL;%(PreprocessorDefinitions)</PreprocessorDefinitions>
    1.26 +      <PreprocessorDefinitions>_WINDLL;_CRT_SECURE_NO_WARNINGS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
    1.27      </ClCompile>
    1.28      <Link>
    1.29        <SubSystem>Console</SubSystem>
    1.30 @@ -452,7 +452,7 @@
    1.31        <PrecompiledHeader>NotUsing</PrecompiledHeader>
    1.32        <CompileAsWinRT>false</CompileAsWinRT>
    1.33        <AdditionalIncludeDirectories>..\..\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
    1.34 -      <PreprocessorDefinitions>_WINDLL;%(PreprocessorDefinitions)</PreprocessorDefinitions>
    1.35 +      <PreprocessorDefinitions>_WINDLL;_CRT_SECURE_NO_WARNINGS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
    1.36      </ClCompile>
    1.37      <Link>
    1.38        <SubSystem>Console</SubSystem>
    1.39 @@ -466,7 +466,7 @@
    1.40        <PrecompiledHeader>NotUsing</PrecompiledHeader>
    1.41        <CompileAsWinRT>false</CompileAsWinRT>
    1.42        <AdditionalIncludeDirectories>..\..\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
    1.43 -      <PreprocessorDefinitions>_WINDLL;%(PreprocessorDefinitions)</PreprocessorDefinitions>
    1.44 +      <PreprocessorDefinitions>_WINDLL;_CRT_SECURE_NO_WARNINGS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
    1.45      </ClCompile>
    1.46      <Link>
    1.47        <SubSystem>Console</SubSystem>
    1.48 @@ -480,7 +480,7 @@
    1.49        <PrecompiledHeader>NotUsing</PrecompiledHeader>
    1.50        <CompileAsWinRT>false</CompileAsWinRT>
    1.51        <AdditionalIncludeDirectories>..\..\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
    1.52 -      <PreprocessorDefinitions>_WINDLL;%(PreprocessorDefinitions)</PreprocessorDefinitions>
    1.53 +      <PreprocessorDefinitions>_WINDLL;_CRT_SECURE_NO_WARNINGS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
    1.54      </ClCompile>
    1.55      <Link>
    1.56        <SubSystem>Console</SubSystem>
     2.1 --- a/include/SDL_config_windowsrt.h	Sat Feb 02 21:05:32 2013 -0500
     2.2 +++ b/include/SDL_config_windowsrt.h	Sun Feb 03 12:33:15 2013 -0500
     2.3 @@ -117,6 +117,7 @@
     2.4  #define HAVE_STRNCMP 1
     2.5  #define HAVE__STRICMP 1
     2.6  #define HAVE__STRNICMP 1
     2.7 +#define HAVE_VSNPRINTF 1
     2.8  //#define HAVE_SSCANF 1	// TODO, WinRT: consider using sscanf_s instead
     2.9  #define HAVE_M_PI 1
    2.10  #define HAVE_ATAN 1