View Issue Details Jump to Notes ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0014458CMakeCMakepublic2013-10-04 04:572014-06-02 08:37
Reporterhansw 
Assigned ToBrad King 
PrioritynormalSeverityminorReproducibilityN/A
StatusclosedResolutionfixed 
PlatformOSOS Version
Product Version 
Target VersionCMake 3.0Fixed in VersionCMake 3.0 
Summary0014458: Support clang-cl, clang's cl-compatible driver
DescriptionClang has recently developed a cl-compatible driver, clang-cl.

Configuring a project on Windows with cmake -DCMAKE_CXX_COMPILER=clang-cl still generates files that try to use the regular gcc-compatible clang options.

Would it be possible to teach cmake about this new driver mode?
Additional Informationclang-cl was announced at http://blog.llvm.org/2013/09/a-path-forward-for-llvm-toolchain-on.html, [^] and builds are available from http://llvm.org/builds/ [^]
TagsNo tags attached.
Attached Files

 Relationships
related to 0013035closedBrad King Support for MinGW Clang on Windows 
has duplicate 0014586closed LLVM platform toolset for Visual Studio 

  Notes
(0033974)
Brad King (manager)
2013-10-04 13:57

Okay, I've installed both Clang for MinGW (see issue 0013035) and Clang CL and got things working. First I had to introduce the notion of one compiler simulating another, used to detect the difference between the GNU-like and MS-like Clang:

 CMakeDetermineCompilerId: Add notion of "simulated" id/version
 http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=51ab85c3 [^]

Then I added the platform files to use this information to load either GNU or MSVC flags:

 Clang: Support Windows variants for GNU and MSVC
 http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=3d8356d4 [^]
(0033976)
Brad King (manager)
2013-10-04 13:58

Please try out CMake from Git commit 3d8356d4.
(0033977)
Brad King (manager)
2013-10-04 14:01

FYI, you can even use the VS generator with the LLVM toolset like this:

 cmake ../src -G "Visual Studio 10" -T LLVM-vs2010

or

 cmake ../src -G "Visual Studio 11" -T LLVM-vs2012
(0033978)
hansw (reporter)
2013-10-04 14:04

Thanks! I'll try it out as soon as I can.
(0034073)
hansw (reporter)
2013-10-07 17:29

I tried this out with CMake from http://www.cmake.org/files/dev/cmake-2.8.11.20131006-gd5ad0-win32-x86.zip [^] and it seems to work great. Thanks!
(0034074)
Brad King (manager)
2013-10-08 11:20

Thanks for testing. The change is now in master.
(0036017)
Robert Maynard (manager)
2014-06-02 08:37

Closing resolved issues that have not been updated in more than 4 months.

 Issue History
Date Modified Username Field Change
2013-10-04 04:57 hansw New Issue
2013-10-04 09:21 Brad King Relationship added related to 0013035
2013-10-04 13:56 Brad King Assigned To => Brad King
2013-10-04 13:56 Brad King Status new => assigned
2013-10-04 13:56 Brad King Target Version => CMake 3.0
2013-10-04 13:57 Brad King Note Added: 0033974
2013-10-04 13:58 Brad King Note Added: 0033976
2013-10-04 14:01 Brad King Note Added: 0033977
2013-10-04 14:04 hansw Note Added: 0033978
2013-10-07 17:29 hansw Note Added: 0034073
2013-10-08 11:20 Brad King Note Added: 0034074
2013-10-08 11:20 Brad King Status assigned => resolved
2013-10-08 11:20 Brad King Resolution open => fixed
2013-10-08 11:20 Brad King Fixed in Version => CMake 3.0
2013-11-20 08:35 Brad King Relationship added has duplicate 0014586
2014-06-02 08:37 Robert Maynard Note Added: 0036017
2014-06-02 08:37 Robert Maynard Status resolved => closed


Copyright © 2000 - 2018 MantisBT Team