summaryrefslogtreecommitdiffstats
path: root/Modules/Compiler/XLClang-C.cmake
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2020-12-04 13:27:36 (GMT)
committerKitware Robot <kwrobot@kitware.com>2020-12-04 13:27:55 (GMT)
commit76685b985d9ec91f7ffa036cc2a43bca6477f6e9 (patch)
treebb1ee84f0c5c16b3fb1a670fa4800c4afdfc1f0a /Modules/Compiler/XLClang-C.cmake
parent16c0057a13282001a5de56a8eb434b299aea3282 (diff)
parent48aac247e922409b4dfe7189521661df4b0583d1 (diff)
downloadCMake-76685b985d9ec91f7ffa036cc2a43bca6477f6e9.zip
CMake-76685b985d9ec91f7ffa036cc2a43bca6477f6e9.tar.gz
CMake-76685b985d9ec91f7ffa036cc2a43bca6477f6e9.tar.bz2
Merge topic 'explicit-LANGUAGE-flag'
48aac247e9 Compile with explicit language flag when source LANGUAGE property is set 2e67a75acd Embarcadero: Simplify addition of -P flag for C++ Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !5522
Diffstat (limited to 'Modules/Compiler/XLClang-C.cmake')
-rw-r--r--Modules/Compiler/XLClang-C.cmake2
1 files changed, 2 insertions, 0 deletions
diff --git a/Modules/Compiler/XLClang-C.cmake b/Modules/Compiler/XLClang-C.cmake
index 54c18a6..1668a4d 100644
--- a/Modules/Compiler/XLClang-C.cmake
+++ b/Modules/Compiler/XLClang-C.cmake
@@ -1,6 +1,8 @@
include(Compiler/XLClang)
__compiler_xlclang(C)
+set(CMAKE_C_COMPILE_OPTIONS_EXPLICIT_LANGUAGE -x c)
+
if (CMAKE_C_COMPILER_VERSION VERSION_GREATER_EQUAL 13.1.1)
set(CMAKE_C90_STANDARD_COMPILE_OPTION "-std=c89")
set(CMAKE_C90_EXTENSION_COMPILE_OPTION "-std=gnu89")