Project

General

Profile

Actions

Bug #18332

closed

unrecognized command line option '-fdiagnostics-color=always'

Added by Dave Chen over 7 years ago. Updated almost 7 years ago.

Status:
Closed
Priority:
Normal
Assignee:
-
Category:
-
Target version:
-
% Done:

0%

Source:
Tags:
Backport:
Regression:
No
Severity:
3 - minor
Reviewed:
Affected Versions:
ceph-qa-suite:
Pull request ID:
Crash signature (v1):
Crash signature (v2):

Description

Although the following rule has been defined in the CMakeLists.txt, the 'diagnostics-color' option is added during source compiling while the gcc version is not actually support the option, typically, the gcc version lower than 4.9.

  1. Handle diagnostics color if compiler supports them.
    CHECK_C_COMPILER_FLAG("-fdiagnostics-color=always"
    COMPILER_SUPPORTS_DIAGNOSTICS_COLOR)

The message from the CMakeError.log

/usr/bin/cc -Wall -Wtype-limits -Wignored-qualifiers -Winit-self -Wpointer-arith -Werror=format-security -fno-strict-aliasing -fsigned-char -rdynamic -Wno-unknown-pragmas -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=2 -std=gnu99 -DCOMPILER_SUPPORTS_DIAGNOSTICS_COLOR -fPIE -fdiagnostics-color=always -o CMakeFiles/cmTryCompileExec2260236235.dir/src.c.o -c /home/dave/gerrit/ceph/build/CMakeFiles/CMakeTmp/src.c
cc: error: unrecognized command line option '-fdiagnostics-color=always'
make1: Leaving directory `/home/dave/gerrit/ceph/build/CMakeFiles/CMakeTmp'
make1: * [CMakeFiles/cmTryCompileExec2260236235.dir/src.c.o] Error 1make: * [cmTryCompileExec2260236235/fast] Error 2

Actions #1

Updated by Dave Chen over 7 years ago

This properly not a bug, these message from CMakeError.log should be caused by cmake test command, there must be other reason result in the failure of building.

Actions #2

Updated by Dave Chen over 7 years ago

Looks like I don't have the permission to change the status, anyone who can change the status pls kindly mark it as invalid.

Actions #3

Updated by Greg Farnum almost 7 years ago

  • Status changed from New to Closed
Actions

Also available in: Atom PDF