From: dbv Date: Mon, 23 Apr 2012 07:57:19 +0000 (+0400) Subject: Correction of files of qt samples for generation VS projects X-Git-Tag: V6_5_3~1 X-Git-Url: http://git.dev.opencascade.org/gitweb/?p=occt.git;a=commitdiff_plain;h=5ce17593b9170a1bf2d656feee43e1b56f5942d7 Correction of files of qt samples for generation VS projects --- diff --git a/samples/qt/IESample/generation-vc-projects.bat b/samples/qt/IESample/generation-vc-projects.bat index 2d5385c168..9e332ee0d4 100644 --- a/samples/qt/IESample/generation-vc-projects.bat +++ b/samples/qt/IESample/generation-vc-projects.bat @@ -5,6 +5,28 @@ REM Use first argument to specify version of Visual Studio (vc8, vc9, or vc10), REM second argument specifies architecture) (win32 or win64) REM third argument specifies Debug or Release mode -call ..\..\..\env.bat %1 %2 %3 +call .\..\..\..\env.bat %1 %2 %3 + +if not "%1" == "" ( + if /I "%1" == "vc8" ( + set VCVER=vc8 + set "VCVARS=%VS80COMNTOOLS%..\..\VC\vcvarsall.bat" + ) else if /I "%1" == "vc9" ( + set VCVER=vc9 + set "VCVARS=%VS90COMNTOOLS%..\..\VC\vcvarsall.bat" + ) else if /I "%1" == "vc10" ( + set VCVER=vc10 + set "VCVARS=%VS100COMNTOOLS%..\..\VC\vcvarsall.bat" + ) else ( + echo Error: first argument ^(%1^) should specify supported version of Visual C++, + echo one of: vc8 ^(VS 2005 SP1^), vc9 ^(VS 2008 SP1^), or vc10 ^(VS 2010^) + exit + ) +) + +if ["%ARCH%"] == ["32"] set VCARCH=x86 +if ["%ARCH%"] == ["64"] set VCARCH=amd64 + +call "%VCVARS%" %VCARCH% qmake -tp vc -r IESample.pro diff --git a/samples/qt/Tutorial/env.bat b/samples/qt/Tutorial/env.bat index d42ee2c7ef..4985b2cb71 100755 --- a/samples/qt/Tutorial/env.bat +++ b/samples/qt/Tutorial/env.bat @@ -1,3 +1,4 @@ SET RES_DIR=%~dp0res SET CSF_ResourcesDefaults=%RES_DIR% -SET CSF_IEResourcesDefaults=%RES_DIR% +SET CSF_TuturialResourcesDefaults=%RES_DIR% + diff --git a/samples/qt/Tutorial/generation-vc-projects.bat b/samples/qt/Tutorial/generation-vc-projects.bat index b306354459..a131dbbbdc 100644 --- a/samples/qt/Tutorial/generation-vc-projects.bat +++ b/samples/qt/Tutorial/generation-vc-projects.bat @@ -5,6 +5,28 @@ REM Use first argument to specify version of Visual Studio (vc8, vc9, or vc10), REM second argument specifies architecture) (win32 or win64) REM third argument specifies Debug or Release mode -call ..\..\..\env.bat %1 %2 %3 +call .\..\..\..\env.bat %1 %2 %3 + +if not "%1" == "" ( + if /I "%1" == "vc8" ( + set VCVER=vc8 + set "VCVARS=%VS80COMNTOOLS%..\..\VC\vcvarsall.bat" + ) else if /I "%1" == "vc9" ( + set VCVER=vc9 + set "VCVARS=%VS90COMNTOOLS%..\..\VC\vcvarsall.bat" + ) else if /I "%1" == "vc10" ( + set VCVER=vc10 + set "VCVARS=%VS100COMNTOOLS%..\..\VC\vcvarsall.bat" + ) else ( + echo Error: first argument ^(%1^) should specify supported version of Visual C++, + echo one of: vc8 ^(VS 2005 SP1^), vc9 ^(VS 2008 SP1^), or vc10 ^(VS 2010^) + exit + ) +) + +if ["%ARCH%"] == ["32"] set VCARCH=x86 +if ["%ARCH%"] == ["64"] set VCARCH=amd64 + +call "%VCVARS%" %VCARCH% qmake -tp vc -r Tutorial.pro