Das SetEnv.cmd
Skript, das von der Verknüpfung "SDK-Eingabeaufforderung" ausgeführt wird, wird cl.exe
an verschiedenen Stellen überprüft, bevor Einträge zum Hinzufügen eingerichtet werden PATH
. Es kann also nichts hinzugefügt werden, wenn kein nativer C-Compiler installiert ist.
Wenden Sie den folgenden Patch an, um dies zu beheben <SDK install dir>\Bin\SetEnv.cmd
. Dadurch werden auch fehlende Pfade zu anderen Tools in <SDK install dir>\Bin
und Unterordnern behoben. Natürlich können Sie stattdessen den C-Compiler installieren, um diesen Fehler zu umgehen.
--- SetEnv.Cmd_ 2010-04-27 19:52:00.000000000 +0400
+++ SetEnv.Cmd 2013-12-02 15:05:30.834400000 +0400
@@ -228,10 +228,10 @@
IF "%CURRENT_CPU%" =="x64" (
IF "%TARGET_CPU%" == "x64" (
+ SET "FxTools=%FrameworkDir64%\%FrameworkVersion%;%FrameworkDir32%%FrameworkVersion%;%windir%\Microsoft.NET\Framework64\v3.5;%windir%\Microsoft.NET\Framework\v3.5;"
+ SET "SdkTools=%WindowsSdkDir%Bin\NETFX 4.0 Tools\x64;%WindowsSdkDir%Bin\x64;%WindowsSdkDir%Bin;"
IF EXIST "%VCTools%\amd64\cl.exe" (
SET "VCTools=%VCTools%\amd64;%VCTools%\VCPackages;"
- SET "SdkTools=%WindowsSdkDir%Bin\NETFX 4.0 Tools\x64;%WindowsSdkDir%Bin\x64;%WindowsSdkDir%Bin;"
- SET "FxTools=%FrameworkDir64%\%FrameworkVersion%;%FrameworkDir32%%FrameworkVersion%;%windir%\Microsoft.NET\Framework64\v3.5;%windir%\Microsoft.NET\Framework\v3.5;"
) ELSE (
SET VCTools=
ECHO The x64 compilers are not currently installed.
@@ -239,10 +239,10 @@
ECHO .
)
) ELSE IF "%TARGET_CPU%" == "IA64" (
+ SET "FxTools=%FrameworkDir64%\%FrameworkVersion%;%FrameworkDir32%%FrameworkVersion%;%windir%\Microsoft.NET\Framework64\v3.5;%windir%\Microsoft.NET\Framework\v3.5;"
+ SET "SdkTools=%WindowsSdkDir%Bin\NETFX 4.0 Tools\x64;%WindowsSdkDir%Bin\x64;%WindowsSdkDir%Bin;"
IF EXIST "%VCTools%\x86_ia64\cl.exe" (
SET "VCTools=%VCTools%\x86_ia64;%VCTools%\VCPackages;"
- SET "SdkTools=%WindowsSdkDir%Bin\NETFX 4.0 Tools\x64;%WindowsSdkDir%Bin\x64;%WindowsSdkDir%Bin;"
- SET "FxTools=%FrameworkDir64%\%FrameworkVersion%;%FrameworkDir32%%FrameworkVersion%;%windir%\Microsoft.NET\Framework64\v3.5;%windir%\Microsoft.NET\Framework\v3.5;"
) ELSE (
SET VCTools=
ECHO The IA64 compilers are not currently installed.
@@ -250,10 +250,10 @@
ECHO .
)
) ELSE IF "%TARGET_CPU%" == "x86" (
+ SET "FxTools=%FrameworkDir32%%FrameworkVersion%;%windir%\Microsoft.NET\Framework\v3.5;"
+ SET "SdkTools=%WindowsSdkDir%Bin\NETFX 4.0 Tools;%WindowsSdkDir%Bin;"
IF EXIST "%VCTools%\cl.exe" (
SET "VCTools=%VCTools%;%VCTools%\VCPackages;"
- SET "SdkTools=%WindowsSdkDir%Bin\NETFX 4.0 Tools;%WindowsSdkDir%Bin;"
- SET "FxTools=%FrameworkDir32%%FrameworkVersion%;%windir%\Microsoft.NET\Framework\v3.5;"
) ELSE (
SET VCTools=
ECHO The x86 compilers are not currently installed.
@@ -263,10 +263,10 @@
)
) ELSE IF "%CURRENT_CPU%" =="IA64" (
IF "%TARGET_CPU%" == "IA64" (
+ SET "FxTools=%FrameworkDir64%\%FrameworkVersion%;%FrameworkDir32%%FrameworkVersion%;%windir%\Microsoft.NET\Framework64\v3.5;%windir%\Microsoft.NET\Framework\v3.5;"
+ SET "SdkTools=%WindowsSdkDir%Bin\NETFX 4.0 Tools\IA64;%WindowsSdkDir%Bin\IA64;%WindowsSdkDir%Bin;"
IF EXIST "%VCTools%\IA64\cl.exe" (
SET "VCTools=%VCTools%\IA64;%VCTools%;%VCTools%\VCPackages;"
- SET "SdkTools=%WindowsSdkDir%Bin\NETFX 4.0 Tools\IA64;%WindowsSdkDir%Bin\IA64;%WindowsSdkDir%Bin;"
- SET "FxTools=%FrameworkDir64%\%FrameworkVersion%;%FrameworkDir32%%FrameworkVersion%;%windir%\Microsoft.NET\Framework64\v3.5;%windir%\Microsoft.NET\Framework\v3.5;"
) ELSE (
SET VCTools=
ECHO The IA64 compilers are not currently installed.
@@ -274,10 +274,10 @@
ECHO .
)
) ELSE IF "%TARGET_CPU%" == "x64" (
+ SET "FxTools=%FrameworkDir64%\%FrameworkVersion%;%FrameworkDir32%%FrameworkVersion%;%windir%\Microsoft.NET\Framework64\v3.5;%windir%\Microsoft.NET\Framework\v3.5;"
+ SET "SdkTools=%WindowsSdkDir%Bin\NETFX 4.0 Tools\IA64;%WindowsSdkDir%Bin\IA64;%WindowsSdkDir%Bin;"
IF EXIST "%VCTools%\x86_amd64\cl.exe" (
SET "VCTools=%VCTools%\x86_amd64;%VCTools%\VCPackages;"
- SET "SdkTools=%WindowsSdkDir%Bin\NETFX 4.0 Tools\IA64;%WindowsSdkDir%Bin\IA64;%WindowsSdkDir%Bin;"
- SET "FxTools=%FrameworkDir64%\%FrameworkVersion%;%FrameworkDir32%%FrameworkVersion%;%windir%\Microsoft.NET\Framework64\v3.5;%windir%\Microsoft.NET\Framework\v3.5;"
) ELSE (
SET VCTools=
ECHO The VC compilers are not currently installed.
@@ -285,10 +285,10 @@
ECHO .
)
) ELSE IF "%TARGET_CPU%" == "x86" (
+ SET "FxTools=%FrameworkDir32%%FrameworkVersion%;%windir%\Microsoft.NET\Framework\v3.5;"
+ SET "SdkTools=%WindowsSdkDir%Bin\NETFX 4.0 Tools;%WindowsSdkDir%Bin;"
IF EXIST "%VCTools%\cl.exe" (
SET "VCTools=%VCTools%;%VCTools%\VCPackages;"
- SET "SdkTools=%WindowsSdkDir%Bin\NETFX 4.0 Tools;%WindowsSdkDir%Bin;"
- SET "FxTools=%FrameworkDir32%%FrameworkVersion%;%windir%\Microsoft.NET\Framework\v3.5;"
) ELSE (
SET VCTools=
ECHO The x86 compilers are not currently installed.
@@ -298,10 +298,10 @@
)
) ELSE IF "%CURRENT_CPU%"=="x86" (
IF "%TARGET_CPU%" == "x64" (
+ SET "FxTools=%FrameworkDir32%%FrameworkVersion%;%windir%\Microsoft.NET\Framework\v3.5;"
+ SET "SdkTools=%WindowsSdkDir%Bin\NETFX 4.0 Tools;%WindowsSdkDir%Bin;"
IF EXIST "%VCTools%\x86_amd64\cl.exe" (
SET "VCTools=%VCTools%\x86_amd64;%VCTools%\VCPackages;"
- SET "SdkTools=%WindowsSdkDir%Bin\NETFX 4.0 Tools;%WindowsSdkDir%Bin;"
- SET "FxTools=%FrameworkDir32%%FrameworkVersion%;%windir%\Microsoft.NET\Framework\v3.5;"
) ELSE (
SET VCTools=
ECHO The x64 cross compilers are not currently installed.
@@ -309,10 +309,10 @@
ECHO .
)
) ELSE IF "%TARGET_CPU%" == "IA64" (
+ SET "FxTools=%FrameworkDir32%%FrameworkVersion%;%windir%\Microsoft.NET\Framework\v3.5;"
+ SET "SdkTools=%WindowsSdkDir%Bin\NETFX 4.0 Tools;%WindowsSdkDir%Bin;"
IF EXIST "%VCTools%\x86_IA64\cl.exe" (
SET "VCTools=%VCTools%\x86_IA64;%VCTools%;%VCTools%\VCPackages;"
- SET "SdkTools=%WindowsSdkDir%Bin\NETFX 4.0 Tools;%WindowsSdkDir%Bin;"
- SET "FxTools=%FrameworkDir32%%FrameworkVersion%;%windir%\Microsoft.NET\Framework\v3.5;"
) ELSE (
SET VCTools=
ECHO The IA64 compilers are not currently installed.
@@ -320,10 +320,10 @@
ECHO .
)
) ELSE IF "%TARGET_CPU%" == "x86" (
+ SET "FxTools=%FrameworkDir32%%FrameworkVersion%;%windir%\Microsoft.NET\Framework\v3.5;"
+ SET "SdkTools=%WindowsSdkDir%Bin\NETFX 4.0 Tools;%WindowsSdkDir%Bin;"
IF EXIST "%VCTools%\cl.exe" (
SET "VCTools=%VCTools%;%VCTools%\VCPackages;"
- SET "SdkTools=%WindowsSdkDir%Bin\NETFX 4.0 Tools;%WindowsSdkDir%Bin;"
- SET "FxTools=%FrameworkDir32%%FrameworkVersion%;%windir%\Microsoft.NET\Framework\v3.5;"
) ELSE (
SET VCTools=
ECHO The x86 compilers are not currently installed. x86-x86
@@ -331,15 +331,17 @@
ECHO .
)
)
-) ELSE IF EXIST "%VCTools%\cl.exe" (
- SET "VCTools=%VCTools%;%VCTools%\VCPackages;"
- SET "SdkTools=%WindowsSdkDir%Bin\NETFX 4.0 Tools;%WindowsSdkDir%Bin;"
- SET "FxTools=%FrameworkDir32%%FrameworkVersion%;%windir%\Microsoft.NET\Framework\v3.5;"
) ELSE (
- SET VCTools=
- ECHO The x86 compilers are not currently installed. default
- ECHO Please go to Add/Remove Programs to update your installation.
- ECHO .
+ SET "FxTools=%FrameworkDir32%%FrameworkVersion%;%windir%\Microsoft.NET\Framework\v3.5;"
+ SET "SdkTools=%WindowsSdkDir%Bin\NETFX 4.0 Tools;%WindowsSdkDir%Bin;"
+ IF EXIST "%VCTools%\cl.exe" (
+ SET "VCTools=%VCTools%;%VCTools%\VCPackages;"
+ ) ELSE (
+ SET VCTools=
+ ECHO The x86 compilers are not currently installed. default
+ ECHO Please go to Add/Remove Programs to update your installation.
+ ECHO .
+ )
)
:: --------------------------------------------------------------------------------------------