From 36b1044363549aaeb3e9dbf2818a83adb6eaf8fa Mon Sep 17 00:00:00 2001 From: renjipanicker Date: Mon, 24 Feb 2020 08:59:23 +0530 Subject: [PATCH] Fixed C compiler detection error in CMakeList.txt (#176) * Fixed C compiler detection error in CMakeList.txt * Update CMakeLists.txt Co-authored-by: wenyongh --- product-mini/platforms/linux/CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/product-mini/platforms/linux/CMakeLists.txt b/product-mini/platforms/linux/CMakeLists.txt index 5f1aeb69..320534b5 100644 --- a/product-mini/platforms/linux/CMakeLists.txt +++ b/product-mini/platforms/linux/CMakeLists.txt @@ -63,7 +63,7 @@ set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wall -Wextra -Wformat -Wformat-security") # set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wconversion -Wsign-conversion") if (WAMR_BUILD_TARGET MATCHES "X86_.*" OR WAMR_BUILD_TARGET STREQUAL "AMD_64") - if (NOT (${CMAKE_C_COMPILER} MATCHES ".*clang.*")) + if (NOT (CMAKE_C_COMPILER MATCHES ".*clang.*" OR CMAKE_C_COMPILER_ID MATCHES ".*Clang")) set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -mindirect-branch-register") endif () endif ()