Skip to content

Commit 8cd9dcb

Browse files
committed
Fix compilation on Pop!_OS 22.04 LTS CUDA
Downgrade the C++ version from 17 to 14, and also update the code to remove compilation warnings.
1 parent 558a764 commit 8cd9dcb

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

ggml/CMakeLists.txt

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -219,7 +219,11 @@ option(GGML_BUILD_EXAMPLES "ggml: build examples" ${GGML_STANDALONE})
219219
set(CMAKE_C_STANDARD 11)
220220
set(CMAKE_C_STANDARD_REQUIRED true)
221221

222-
set(CMAKE_CXX_STANDARD 17)
222+
if (GGML_SYCL)
223+
set(CMAKE_CXX_STANDARD 17)
224+
else()
225+
set(CMAKE_CXX_STANDARD 14)
226+
endif()
223227
set(CMAKE_CXX_STANDARD_REQUIRED true)
224228

225229
set(THREADS_PREFER_PTHREAD_FLAG ON)

0 commit comments

Comments
 (0)