View Issue Details Jump to Notes ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0015861CMakeCMakepublic2015-11-25 01:042016-05-02 08:30
ReporterRuslan Baratov 
Assigned ToBrad King 
PrioritynormalSeverityminorReproducibilityalways
StatusclosedResolutionfixed 
PlatformOSOS VersionOS X 10.11
Product VersionCMake 3.4 
Target VersionCMake 3.4.1Fixed in VersionCMake 3.4.1 
Summary0015861: Configuration with -flto flag failed: CMAKE_CXX_STANDARD_COMPUTED_DEFAULT should be set for AppleClang [3.4 regression]
DescriptionNot able to configure project with CMAKE_CXX_FLAGS=-flto and CMAKE_CXX_COMPILER=clang++. Works fine for CMake 3.3.
Steps To ReproduceExample:

> cat CMakeLists.txt
cmake_minimum_required(VERSION 3.0)
project(Foo)

> cmake --version
cmake version 3.4.0

> /usr/bin/clang++ --version
Apple LLVM version 6.1.0 (clang-602.0.53) (based on LLVM 3.6.0svn)
Target: x86_64-apple-darwin15.0.0
Thread model: posix

> cmake -H. -B_builds -DCMAKE_CXX_COMPILER=/usr/bin/clang++ -DCMAKE_CXX_FLAGS=-flto
...
CMake Error at .../share/cmake-3.4/Modules/Compiler/AppleClang-CXX.cmake:28 (message):
  CMAKE_CXX_STANDARD_COMPUTED_DEFAULT should be set for AppleClang
  (/usr/bin/clang++) version 6.1.0.6020053
TagsNo tags attached.
Attached Files

 Relationships

  Notes
(0039917)
Brad King (manager)
2015-11-30 09:30

This was fixed recently here:

 Make C and C++ default dialect detection robust to advanced optimizations
 https://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=c3dc8935 [^]

and has been merged to 'release' for inclusion in 3.4.1.
(0039924)
Brad King (manager)
2015-11-30 13:15

Corresponding mailing list thread:

 http://thread.gmane.org/gmane.comp.programming.tools.cmake.devel/14984 [^]
(0039925)
Ruslan Baratov (reporter)
2015-12-01 03:37

Version from branch 'next' with c3dc8935 commit works fine, thanks.
(0040973)
Robert Maynard (manager)
2016-05-02 08:30

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

 Issue History
Date Modified Username Field Change
2015-11-25 01:04 Ruslan Baratov New Issue
2015-11-30 09:30 Brad King Note Added: 0039917
2015-11-30 09:30 Brad King Assigned To => Brad King
2015-11-30 09:30 Brad King Status new => resolved
2015-11-30 09:30 Brad King Resolution open => fixed
2015-11-30 09:30 Brad King Fixed in Version => CMake 3.4.1
2015-11-30 09:30 Brad King Target Version => CMake 3.4.1
2015-11-30 13:15 Brad King Note Added: 0039924
2015-12-01 03:37 Ruslan Baratov Note Added: 0039925
2016-05-02 08:30 Robert Maynard Note Added: 0040973
2016-05-02 08:30 Robert Maynard Status resolved => closed


Copyright © 2000 - 2018 MantisBT Team