diff options
author | Brad King <brad.king@kitware.com> | 2012-08-16 20:23:16 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2012-08-22 20:35:54 (GMT) |
commit | 66cb3356f508da309d599f6148763f7afe3802e1 (patch) | |
tree | be204ca3f17d391ae965f5393622497a04cc236a /Modules/CompilerId/VS-10.vcxproj.in | |
parent | 89595d6bceb25ecfa221342f03d1c3dce70c8484 (diff) | |
download | CMake-66cb3356f508da309d599f6148763f7afe3802e1.zip CMake-66cb3356f508da309d599f6148763f7afe3802e1.tar.gz CMake-66cb3356f508da309d599f6148763f7afe3802e1.tar.bz2 |
VS: Detect the compiler id and tool location
Configure a hand-generated Visual Studio project to build the compiler id
source file since we cannot run the compiler command-line tool directly.
Add a post-build command to print out the full path to the compiler tool.
Parse the full path to the compiler tool from the build output.
Diffstat (limited to 'Modules/CompilerId/VS-10.vcxproj.in')
-rw-r--r-- | Modules/CompilerId/VS-10.vcxproj.in | 53 |
1 files changed, 53 insertions, 0 deletions
diff --git a/Modules/CompilerId/VS-10.vcxproj.in b/Modules/CompilerId/VS-10.vcxproj.in new file mode 100644 index 0000000..ab4705f --- /dev/null +++ b/Modules/CompilerId/VS-10.vcxproj.in @@ -0,0 +1,53 @@ +<?xml version="1.0" encoding="utf-8"?> +<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> + <ItemGroup Label="ProjectConfigurations"> + <ProjectConfiguration Include="Debug|@id_arch@"> + <Configuration>Debug</Configuration> + <Platform>@id_arch@</Platform> + </ProjectConfiguration> + </ItemGroup> + <PropertyGroup Label="Globals"> + <ProjectGuid>{CAE07175-D007-4FC3-BFE8-47B392814159}</ProjectGuid> + <RootNamespace>CompilerId@id_lang@</RootNamespace> + <Keyword>Win32Proj</Keyword> + </PropertyGroup> + <Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" /> + <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|@id_arch@'" Label="Configuration"> + <ConfigurationType>Application</ConfigurationType> + @id_toolset@ + <CharacterSet>MultiByte</CharacterSet> + </PropertyGroup> + <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" /> + <PropertyGroup> + <_ProjectFileVersion>10.0.30319.1</_ProjectFileVersion> + <OutDir Condition="'$(Configuration)|$(Platform)'=='Debug|@id_arch@'">.\</OutDir> + <IntDir Condition="'$(Configuration)|$(Platform)'=='Debug|@id_arch@'">$(Configuration)\</IntDir> + <LinkIncremental Condition="'$(Configuration)|$(Platform)'=='Debug|@id_arch@'">false</LinkIncremental> + </PropertyGroup> + <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|@id_arch@'"> + <ClCompile> + <Optimization>Disabled</Optimization> + <PreprocessorDefinitions>%(PreprocessorDefinitions)</PreprocessorDefinitions> + <MinimalRebuild>false</MinimalRebuild> + <BasicRuntimeChecks>EnableFastChecks</BasicRuntimeChecks> + <RuntimeLibrary>MultiThreadedDebugDLL</RuntimeLibrary> + <PrecompiledHeader> + </PrecompiledHeader> + <WarningLevel>TurnOffAllWarnings</WarningLevel> + <DebugInformationFormat> + </DebugInformationFormat> + </ClCompile> + <Link> + <GenerateDebugInformation>false</GenerateDebugInformation> + <SubSystem>Console</SubSystem> + <TargetMachine>@id_machine_10@</TargetMachine> + </Link> + <PostBuildEvent> + <Command>for %%i in (@id_cl@) do %40echo CMAKE_@id_lang@_COMPILER=%%~$PATH:i</Command> + </PostBuildEvent> + </ItemDefinitionGroup> + <ItemGroup> + <ClCompile Include="@id_src@" /> + </ItemGroup> + <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" /> +</Project> |