VS10: Do not set the TargetMachine when detecting the compiler
The Microsoft linker is intelligent enough to detect the target machine type depending on the input files. This allows us to get the target architecture from the compiler instead of maintaining the mapping to the platform name.
This commit is contained in:
parent
dfbfe6f166
commit
60e568cf79
|
@ -126,15 +126,8 @@ Id flags: ${testflags}
|
||||||
set(v 6)
|
set(v 6)
|
||||||
set(ext dsp)
|
set(ext dsp)
|
||||||
endif()
|
endif()
|
||||||
if("${id_arch}" STREQUAL "x64")
|
if("${id_arch}" STREQUAL "Itanium")
|
||||||
set(id_machine_10 MachineX64)
|
|
||||||
elseif("${id_arch}" STREQUAL "Itanium")
|
|
||||||
set(id_machine_10 MachineIA64)
|
|
||||||
set(id_arch ia64)
|
set(id_arch ia64)
|
||||||
elseif("${id_arch}" STREQUAL "ARM")
|
|
||||||
set(id_machine_10 MachineARM)
|
|
||||||
else()
|
|
||||||
set(id_machine_10 MachineX86)
|
|
||||||
endif()
|
endif()
|
||||||
if(CMAKE_VS_PLATFORM_TOOLSET)
|
if(CMAKE_VS_PLATFORM_TOOLSET)
|
||||||
set(id_toolset "<PlatformToolset>${CMAKE_VS_PLATFORM_TOOLSET}</PlatformToolset>")
|
set(id_toolset "<PlatformToolset>${CMAKE_VS_PLATFORM_TOOLSET}</PlatformToolset>")
|
||||||
|
|
|
@ -40,7 +40,6 @@
|
||||||
<Link>
|
<Link>
|
||||||
<GenerateDebugInformation>false</GenerateDebugInformation>
|
<GenerateDebugInformation>false</GenerateDebugInformation>
|
||||||
<SubSystem>Console</SubSystem>
|
<SubSystem>Console</SubSystem>
|
||||||
<TargetMachine>@id_machine_10@</TargetMachine>
|
|
||||||
</Link>
|
</Link>
|
||||||
<PostBuildEvent>
|
<PostBuildEvent>
|
||||||
<Command>for %%i in (@id_cl@) do %40echo CMAKE_@id_lang@_COMPILER=%%~$PATH:i</Command>
|
<Command>for %%i in (@id_cl@) do %40echo CMAKE_@id_lang@_COMPILER=%%~$PATH:i</Command>
|
||||||
|
|
Loading…
Reference in New Issue