summaryrefslogtreecommitdiffstats
path: root/Modules/Compiler/GNU-C-FeatureTests.cmake
Commit message (Collapse)AuthorAgeFilesLines
* Features: Fix C90 feature detection.Stephen Kelly2015-02-041-1/+1
| | | | | | | | | | | | | | | This bug caused c_function_prototypes to not be recorded at configure time when compiling with -std=gnu99 or similar. In the case of feature recording, that was not a problem, because the logic in CMakeDetermineCompileFeatures.cmake currently assumes that a feature present for an earlier standard is present for a later standard. However, the detection strings are also used in WriteCompilerDetectionHeader, so the feature macro has been defined to '0' when using a later language dialect. Fix that by not checking the existence of the __STDC_VERSION__ macro at all when detecting C90 features.
* Features: Record for GNU 4.4.Stephen Kelly2015-01-181-2/+2
|
* Features: Record for GNU 4.6.Stephen Kelly2015-01-151-2/+2
| | | | | Adjust the CompileFeatures genex_test for the expectation of the OVERRIDE_CONTROL feature group.
* Features: Test an old value of __STDC_VERSION__ for GNU < 4.7 compatibility.Stephen Kelly2015-01-151-1/+6
|
* WCDH: Make the header -Wundef safe for the C language.Stephen Kelly2014-11-251-2/+2
| | | | | | | | | The __STDC_VERSION__ macro may be defined or not depending on the implementation dialect of C. Test that it is defined before testing its value. The CXX tests do not need such a change because they define __cplusplus in all dialects.
* Features: Extend concept to C language.Stephen Kelly2014-05-141-0/+12
Add properties and variables corresponding to CXX equivalents. Add features for c_function_prototypes (C90), c_restrict (C99), c_variadic_macros (C99) and c_static_assert (C11). This feature set can be extended later. Add a <PREFIX>_RESTRICT symbol define to WriteCompilerDetectionHeader to conditionally represent the c_restrict feature.