MantisBT - CMake
View Issue Details
0014473CMakeCMakepublic2013-10-10 06:202016-06-10 14:31
Paul "TBBle" Hampson 
Kitware Robot 
normalfeatureN/A
closedmoved 
x86_64Windows7
CMake 2.8.11.2 
 
0014473: Add CMAKE_CXX_LIBRARY_ARCHITECTURE support for Windows-MSVC Platform
As it came up in issue 0014029, I discovered that currently no attempt is made to populate CMAKE_CXX_LIBRARY_ARCHTECTURE for the Windows-MSVC Platform.

The attached patch should do so, for both MSVC and Clang-CL (pretending to be MSVC), based on the path to the MSVC-bundled runtime libraries.

The main outstanding issue is that CMAKE_CXX_LIBRARY_ARCHITECTURE's not as useful on this platform as it could be, as there's no solid consensus on what this value should be (Microsoft appear to have changed their opinion about it as they've gone through Visual Studio and Platform SDK releases.

I don't have Visual Studio 2013 here or extra platforms installed for the Visual Studio installations I do have, so it's possible the regex is missing some options. It'd be nice if the "/lib/" in the path match was part of the regex variable instead of being always present, as then "/VC/lib/(.*)" would be a safer match.

http://cmake.org/Bug/view.php?id=14029 [^]
msvc, visual studio
patch 0001-MSVC-Populate-CMAKE_CXX_LIBRARY_ARCHITECTURE.patch (5,537) 2013-10-10 06:20
https://public.kitware.com/Bug/file/4899/0001-MSVC-Populate-CMAKE_CXX_LIBRARY_ARCHITECTURE.patch
Issue History
2013-10-10 06:20Paul "TBBle" HampsonNew Issue
2013-10-10 06:20Paul "TBBle" HampsonFile Added: 0001-MSVC-Populate-CMAKE_CXX_LIBRARY_ARCHITECTURE.patch
2013-10-10 06:24Paul "TBBle" HampsonTag Attached: msvc
2013-10-10 06:24Paul "TBBle" HampsonTag Attached: visual studio
2013-10-10 08:55Brad KingNote Added: 0034095
2016-06-10 14:29Kitware RobotNote Added: 0042389
2016-06-10 14:29Kitware RobotStatusnew => resolved
2016-06-10 14:29Kitware RobotResolutionopen => moved
2016-06-10 14:29Kitware RobotAssigned To => Kitware Robot
2016-06-10 14:31Kitware RobotStatusresolved => closed

Notes
(0034095)
Brad King   
2013-10-10 08:55   
The _LIBRARY_ARCHITECTURE variables are for Linux multiarch systems where the name is well-defined for the system.

As you point out the variable has no "standard" value for MS platforms.
(0042389)
Kitware Robot   
2016-06-10 14:29   
Resolving issue as `moved`.

This issue tracker is no longer used. Further discussion of this issue may take place in the current CMake Issues page linked in the banner at the top of this page.