Change 960:c41b2528b3b1 by tmodes

This construct is not valid
...
SET(CXX11_FLAG_CANDIDATES
  "--std=gnu++11"
  "--std=c++11"
  "--std=gnu++0x"
)

...
        FOREACH(FLAG ${CXX11_FLAG_CANDIDATES})
        SET(SAFE_CMAKE_REQUIRED_FLAGS "${CMAKE_REQUIRED_FLAGS}")
        SET(CMAKE_REQUIRED_FLAGS "${FLAG}")
        CHECK_CXX_SOURCE_COMPILES("${CXX11_TEST_SOURCE}" CXX11_FLAG_DETECTED)
        SET(CMAKE_REQUIRED_FLAGS "${SAFE_CMAKE_REQUIRED_FLAGS}")
        IF(CXX11_FLAG_DETECTED)
        SET(CXX11_FLAG "${FLAG}")
        BREAK()
        ENDIF(CXX11_FLAG_DETECTED)
        ENDFOREACH()
...

The first run in the loop sets CXX11_FLAG_DETECTED and _caches_ it.
The following runs see the value and no processing is done.

So, if --std=gnu++11 is invalid, there is no checking for --std=c++11 or 
--std=gnu++0x.

(It took me some time to find out)

        Kornel

Attachment: signature.asc
Description: This is a digitally signed message part.

Reply via email to