assignUser commented on code in PR #45326:
URL: https://github.com/apache/arrow/pull/45326#discussion_r1924523970


##########
cpp/cmake_modules/SetupCxxFlags.cmake:
##########
@@ -23,6 +23,23 @@ include(CheckCXXSourceCompiles)
 
 message(STATUS "System processor: ${CMAKE_SYSTEM_PROCESSOR}")
 
+if(CMAKE_C_COMPILER_ID STREQUAL "AppleClang" OR CMAKE_C_COMPILER_ID STREQUAL 
"Clang")
+  set(UsingClang TRUE)
+else()
+  set(UsingClang FALSE)
+endif()
+
+# Check for Clang C++ compiler
+if(CMAKE_CXX_COMPILER_ID STREQUAL "AppleClang" OR CMAKE_CXX_COMPILER_ID 
STREQUAL "Clang")
+  set(UsingClangPlusPlus TRUE)
+else()
+  set(UsingClangPlusPlus FALSE)
+endif()
+
+if(${UsingClangPlusPlus} AND NOT ${UsingClang})
+  message(FATAL_ERROR "When using clang++ you must also use clang")
+endif()

Review Comment:
   gcc != g++
   clang != clang++



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to