New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[R][C++] Cmake error Unknown compiler: IntelLLVM 2023.2.0
#37750
Comments
I think we just need to add it to the various bits where we check the value of |
Or, as @jonkeane mentioned on Zulip, if this is something we don't want to or can't support, reintroduce the "arrow without arrow" approach that worked for solaris. |
Unknown compiler: IntelLLVM 2023.2.0
Unknown compiler: IntelLLVM 2023.2.0
Can we use the following (and similar changes)? diff --git a/cpp/cmake_modules/SetupCxxFlags.cmake b/cpp/cmake_modules/SetupCxxFlags.cmake
index a5f565972..a65daf03f 100644
--- a/cpp/cmake_modules/SetupCxxFlags.cmake
+++ b/cpp/cmake_modules/SetupCxxFlags.cmake
@@ -329,7 +329,7 @@ if("${BUILD_WARNING_LEVEL}" STREQUAL "CHECKIN")
set(CXX_COMMON_FLAGS "${CXX_COMMON_FLAGS} -Wno-sign-conversion")
set(CXX_COMMON_FLAGS "${CXX_COMMON_FLAGS} -Wunused-result")
set(CXX_COMMON_FLAGS "${CXX_COMMON_FLAGS} -Wdate-time")
- elseif(CMAKE_CXX_COMPILER_ID STREQUAL "Intel")
+ elseif(CMAKE_CXX_COMPILER_ID STREQUAL "Intel" OR CMAKE_CXX_COMPILER_ID STREQUAL "IntelLLVM")
if(WIN32)
set(CXX_COMMON_FLAGS "${CXX_COMMON_FLAGS} /Wall")
set(CXX_COMMON_FLAGS "${CXX_COMMON_FLAGS} /Wno-deprecated") Or can we use the following (and similar changes)? diff --git a/cpp/cmake_modules/SetupCxxFlags.cmake b/cpp/cmake_modules/SetupCxxFlags.cmake
index a5f565972..b595e6372 100644
--- a/cpp/cmake_modules/SetupCxxFlags.cmake
+++ b/cpp/cmake_modules/SetupCxxFlags.cmake
@@ -313,7 +313,7 @@ if("${BUILD_WARNING_LEVEL}" STREQUAL "CHECKIN")
set(CXX_COMMON_FLAGS "${CXX_COMMON_FLAGS} /wd4267")
set(CXX_COMMON_FLAGS "${CXX_COMMON_FLAGS} /wd4838")
elseif(CMAKE_CXX_COMPILER_ID STREQUAL "AppleClang" OR CMAKE_CXX_COMPILER_ID STREQUAL
- "Clang")
+ "Clang" OR CMAKE_CXX_COMPILER_ID STREQUAL "IntelLLVM")
set(CXX_COMMON_FLAGS "${CXX_COMMON_FLAGS} -Wall")
set(CXX_COMMON_FLAGS "${CXX_COMMON_FLAGS} -Wextra")
set(CXX_COMMON_FLAGS "${CXX_COMMON_FLAGS} -Wdocumentation") Or do we need one more new branch for the compiler? |
Thanks @kou! I guess it comes down to how common this compiler is and if we want to support it given the effort it'd take to do so. Unlike with the old Solaris build, where we used to build the R package without Arrow C++, this is a modern compiler, so it seems reasonable to try to support it. Perhaps we start off by trying what @kou has suggested above, and seeing if that works, and if so, that's great, and if not then we re-evaluate? @assignUser; given the extra output above, do you think we could replicate that environment and build failure now? |
I suspected that this is not the default identification, when replicating it with one of the official oneAPI docker containers it reported as Intel not IntelLLVM even thought it should have been the new llvm backed compiler... but checking cmake docs https://cmake.org/cmake/help/latest/variable/CMAKE_LANG_COMPILER_ID.html IntelLLVM is correct... maybe the cmake version in the container was to old and there is a fallback to 'Intel'? I will test this. If 'supporting' the compiler is as simple as adding the additonal condition I am fine with it. I don't think anything more substantial isn't really warranted at this point (there has not been any user requests for it). |
Thanks @assignUser! If you're happy to take a look at this, then once you've got a PR up and tested I'll cherry-pick it into the CRAN release branch and try to submit it again. |
Can confirm it worked because cmake 3.16 does not know about intelLLVM and falls back to intel. While it looks like we have to bump mimalloc version to make it IntelLLVM compatible... let's hope that's it. |
### Rationale for this change The IntelLLVM compiler has a different compiler ID that we currently can't handle and causes the build to fail. ### What changes are included in this PR? This adds the missing flags/IDs. Mimalloc in the current bundled version is not compatible with IntelLLVM this can be worked around by using a system version, a simple version bump is not sufficient and I don't think it's worth the effort to fix it properly for now. For the R package build I have disabled mimalloc with IntelLLVM to avoid issues on CRAN. * Closes: #37750 Authored-by: Jacob Wujciak-Jens <jacob@wujciak.de> Signed-off-by: Nic Crane <thisisnic@gmail.com>
### Rationale for this change The IntelLLVM compiler has a different compiler ID that we currently can't handle and causes the build to fail. ### What changes are included in this PR? This adds the missing flags/IDs. Mimalloc in the current bundled version is not compatible with IntelLLVM this can be worked around by using a system version, a simple version bump is not sufficient and I don't think it's worth the effort to fix it properly for now. For the R package build I have disabled mimalloc with IntelLLVM to avoid issues on CRAN. * Closes: apache#37750 Authored-by: Jacob Wujciak-Jens <jacob@wujciak.de> Signed-off-by: Nic Crane <thisisnic@gmail.com>
### Rationale for this change The IntelLLVM compiler has a different compiler ID that we currently can't handle and causes the build to fail. ### What changes are included in this PR? This adds the missing flags/IDs. Mimalloc in the current bundled version is not compatible with IntelLLVM this can be worked around by using a system version, a simple version bump is not sufficient and I don't think it's worth the effort to fix it properly for now. For the R package build I have disabled mimalloc with IntelLLVM to avoid issues on CRAN. * Closes: apache#37750 Authored-by: Jacob Wujciak-Jens <jacob@wujciak.de> Signed-off-by: Nic Crane <thisisnic@gmail.com>
### Rationale for this change The IntelLLVM compiler has a different compiler ID that we currently can't handle and causes the build to fail. ### What changes are included in this PR? This adds the missing flags/IDs. Mimalloc in the current bundled version is not compatible with IntelLLVM this can be worked around by using a system version, a simple version bump is not sufficient and I don't think it's worth the effort to fix it properly for now. For the R package build I have disabled mimalloc with IntelLLVM to avoid issues on CRAN. * Closes: apache#37750 Authored-by: Jacob Wujciak-Jens <jacob@wujciak.de> Signed-off-by: Nic Crane <thisisnic@gmail.com>
Describe the bug, including details regarding any error messages, version, and platform.
When trying to build the C++ library from source on one of the CRAN machines, we get the following error:
Component(s)
C++
The text was updated successfully, but these errors were encountered: