BESM6: Revised windows build to add SDL support to provide the besm6_panel interface.

This commit is contained in:
Mark Pizzolato 2015-01-09 13:50:29 -08:00
parent 9e945b705b
commit ec1f57d120
2 changed files with 44 additions and 21 deletions

View file

@ -26,8 +26,8 @@
> >
<Tool <Tool
Name="VCPreBuildEventTool" Name="VCPreBuildEventTool"
Description="Check for required build dependencies &amp; git commit id" Description="Check for required build dependencies, git commit id and required Font File"
CommandLine="Pre-Build-Event.cmd LIBPCRE" CommandLine="Pre-Build-Event.cmd LIBPCRE LIBSDL FINDFONT tahoma.ttf besm6_panel_font.h"
/> />
<Tool <Tool
Name="VCCustomBuildTool" Name="VCCustomBuildTool"
@ -44,8 +44,8 @@
<Tool <Tool
Name="VCCLCompilerTool" Name="VCCLCompilerTool"
Optimization="0" Optimization="0"
AdditionalIncludeDirectories="./;../;../BESM6/;&quot;../../windows-build/PCRE/include/&quot;" AdditionalIncludeDirectories="./;../;../BESM6/;&quot;../../windows-build/PCRE/include/&quot;;&quot;../../windows-build/libSDL/SDL2-2.0.3/include&quot;;&quot;../../windows-build/libSDL/SDL2_ttf-2.0.12&quot;"
PreprocessorDefinitions="USE_INT64;_CRT_NONSTDC_NO_WARNINGS;_CRT_SECURE_NO_WARNINGS;_WINSOCK_DEPRECATED_NO_WARNINGS;SIM_NEED_GIT_COMMIT_ID;HAVE_PCREPOSIX_H;PCRE_STATIC" PreprocessorDefinitions="USE_INT64;_CRT_NONSTDC_NO_WARNINGS;_CRT_SECURE_NO_WARNINGS;_WINSOCK_DEPRECATED_NO_WARNINGS;SIM_NEED_GIT_COMMIT_ID;HAVE_PCREPOSIX_H;PCRE_STATIC;HAVE_LIBSDL"
KeepComments="false" KeepComments="false"
MinimalRebuild="true" MinimalRebuild="true"
BasicRuntimeChecks="0" BasicRuntimeChecks="0"
@ -67,9 +67,9 @@
/> />
<Tool <Tool
Name="VCLinkerTool" Name="VCLinkerTool"
AdditionalDependencies="wsock32.lib winmm.lib pcrestaticd.lib pcreposixstaticd.lib" AdditionalDependencies="wsock32.lib winmm.lib pcrestaticd.lib pcreposixstaticd.lib SDL2-StaticD.lib dxguid.lib Imm32.lib Version.lib SDL2_ttf-StaticD.lib freetype2412MT_D.lib"
LinkIncremental="2" LinkIncremental="2"
AdditionalLibraryDirectories="../../windows-build/PCRE/lib/" AdditionalLibraryDirectories="&quot;../../windows-build/PCRE/lib/&quot;;&quot;../../windows-build/libSDL/SDL2-2.0.3/lib/&quot;;&quot;../../windows-build/libSDL/Microsoft DirectX SDK (June 2010)\Lib\x86&quot;;&quot;../../windows-build/libSDL/SDL2_ttf-2.0.12/VisualC/Debug&quot;;&quot;../../windows-build/libSDL/SDL2_ttf-2.0.12/external/freetype-2.4.12/objs/win32/vc2008&quot;"
GenerateDebugInformation="true" GenerateDebugInformation="true"
SubSystem="1" SubSystem="1"
StackReserveSize="10485760" StackReserveSize="10485760"
@ -110,8 +110,8 @@
> >
<Tool <Tool
Name="VCPreBuildEventTool" Name="VCPreBuildEventTool"
Description="Check for required build dependencies &amp; git commit id" Description="Check for required build dependencies, git commit id and required Font File"
CommandLine="Pre-Build-Event.cmd LIBPCRE" CommandLine="Pre-Build-Event.cmd LIBPCRE LIBSDL FINDFONT tahoma.ttf besm6_panel_font.h"
/> />
<Tool <Tool
Name="VCCustomBuildTool" Name="VCCustomBuildTool"
@ -130,8 +130,8 @@
Optimization="2" Optimization="2"
InlineFunctionExpansion="1" InlineFunctionExpansion="1"
OmitFramePointers="true" OmitFramePointers="true"
AdditionalIncludeDirectories="./;../;../BESM6/;&quot;../../windows-build/PCRE/include/&quot;" AdditionalIncludeDirectories="./;../;../BESM6/;&quot;../../windows-build/PCRE/include/&quot;;&quot;../../windows-build/libSDL/SDL2-2.0.3/include&quot;;&quot;../../windows-build/libSDL/SDL2_ttf-2.0.12&quot;"
PreprocessorDefinitions="USE_INT64;_CRT_NONSTDC_NO_WARNINGS;_CRT_SECURE_NO_WARNINGS;_WINSOCK_DEPRECATED_NO_WARNINGS;SIM_NEED_GIT_COMMIT_ID;HAVE_PCREPOSIX_H;PCRE_STATIC" PreprocessorDefinitions="USE_INT64;_CRT_NONSTDC_NO_WARNINGS;_CRT_SECURE_NO_WARNINGS;_WINSOCK_DEPRECATED_NO_WARNINGS;SIM_NEED_GIT_COMMIT_ID;HAVE_PCREPOSIX_H;PCRE_STATIC;HAVE_LIBSDL"
StringPooling="true" StringPooling="true"
RuntimeLibrary="0" RuntimeLibrary="0"
EnableFunctionLevelLinking="true" EnableFunctionLevelLinking="true"
@ -151,9 +151,9 @@
/> />
<Tool <Tool
Name="VCLinkerTool" Name="VCLinkerTool"
AdditionalDependencies="wsock32.lib winmm.lib pcrestatic.lib pcreposixstatic.lib" AdditionalDependencies="wsock32.lib winmm.lib pcrestatic.lib pcreposixstatic.lib SDL2-Static.lib dxguid.lib Imm32.lib Version.lib SDL2_ttf-Static.lib freetype2412MT.lib"
LinkIncremental="1" LinkIncremental="1"
AdditionalLibraryDirectories="../../windows-build/PCRE/lib/" AdditionalLibraryDirectories="&quot;../../windows-build/PCRE/lib/&quot;;&quot;../../windows-build/libSDL/SDL2-2.0.3/lib/&quot;;&quot;../../windows-build/libSDL/Microsoft DirectX SDK (June 2010)\Lib\x86&quot;;&quot;../../windows-build/libSDL/SDL2_ttf-2.0.12/VisualC/Release&quot;;&quot;../../windows-build/libSDL/SDL2_ttf-2.0.12/external/freetype-2.4.12/objs/win32/vc2008&quot;"
GenerateDebugInformation="false" GenerateDebugInformation="false"
SubSystem="1" SubSystem="1"
StackReserveSize="10485760" StackReserveSize="10485760"

View file

@ -39,13 +39,19 @@ if /I "%1" == "ROM" set _arg=ROM
if /I "%1" == "BUILD" set _arg=BUILD if /I "%1" == "BUILD" set _arg=BUILD
if /I "%1" == "LIBSDL" set _arg=LIBSDL if /I "%1" == "LIBSDL" set _arg=LIBSDL
if /I "%1" == "LIBPCRE" set _arg=LIBPCRE if /I "%1" == "LIBPCRE" set _arg=LIBPCRE
if "%_arg%" == "" echo *** warning *** unknown parameter %0 if /I "%1" == "FINDFONT" set _arg=FINDFONT
if "%_arg%" == "" echo *** warning *** unknown parameter %1
if /I "%1" == "FINDFONT" set _X_FontName=%2
if /I "%1" == "FINDFONT" set _X_FontIncludeName=%3
if /I "%_arg%" == "FINDFONT" shift
if /I "%_arg%" == "FINDFONT" shift
if not "%_arg%" == "" set _X_%_arg%=%_arg% if not "%_arg%" == "" set _X_%_arg%=%_arg%
shift shift
goto _next_arg goto _next_arg
:_done_args :_done_args
rem some arguments implicitly require BUILD to also be set to have rem some arguments implicitly require BUILD to also be set to have
rem any meaning. These are LIBSDL and LIBPCRE rem any meaning. These are LIBSDL, LIBPCRE and FINDFONT
if not "%_X_FINDFONT%" == "" set _X_BUILD=BUILD
if not "%_X_LIBSDL%" == "" set _X_BUILD=BUILD if not "%_X_LIBSDL%" == "" set _X_BUILD=BUILD
if not "%_X_LIBPCRE%" == "" set _X_BUILD=BUILD if not "%_X_LIBPCRE%" == "" set _X_BUILD=BUILD
@ -89,6 +95,23 @@ if not exist "../../windows-build/libSDL/Microsoft DirectX SDK (June 2010)/Lib/x
if "%_X_LIBPCRE%" == "" goto _done_libpcre if "%_X_LIBPCRE%" == "" goto _done_libpcre
if not exist ../../windows-build/PCRE/include/pcreposix.h goto _notice2 if not exist ../../windows-build/PCRE/include/pcreposix.h goto _notice2
:_done_libpcre :_done_libpcre
if "%_X_FINDFONT%" == "" goto _done_findfont
if not exist ../../windows-build/libSDL/SDL2_ttf-2.0.12/SDL_ttf.h goto _notice2
if "%_X_FontName%" == "" goto _done_findfont
echo. >%_X_FontIncludeName%.temp
set FONTFILE=%windir%\Fonts\%_X_FontName%
if not exist "%FONTFILE%" echo Can't find font %_X_FontName%
if not exist "%FONTFILE%" goto _done_findfont
set FONTFILE=%FONTFILE:\=/%
echo #define FONTFILE %FONTFILE% >>%_X_FontIncludeName%.temp
if not exist %_X_FontIncludeName% goto _found_font
fc %_X_FontIncludeName%.temp %_X_FontIncludeName% >NUL
if NOT ERRORLEVEL 1 goto _done_findfont
:_found_font
echo Found: %FONTFILE%
move /Y %_X_FontIncludeName%.temp %_X_FontIncludeName% >NUL
:_done_findfont
if exist %_X_FontIncludeName%.temp del %_X_FontIncludeName%.temp
goto _done_build goto _done_build
:_notice1 :_notice1
echo ***************************************************** echo *****************************************************