From 489b7c5abf251894a25c0d8e4f3341b5a6bfc662 Mon Sep 17 00:00:00 2001 From: Goran Jelic-Cizmek Date: Sat, 26 Oct 2024 17:10:54 +0200 Subject: [PATCH] Add `-fpermissive` if using GCC --- CMakeLists.txt | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/CMakeLists.txt b/CMakeLists.txt index b7a0c99..6ddaa51 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -32,6 +32,10 @@ if (GGML_BITNET_X86_TL2) add_compile_definitions(GGML_BITNET_X86_TL2) endif() +if (CMAKE_C_COMPILER_ID STREQUAL "GNU" OR CMAKE_CXX_COMPILER_ID STREQUAL "GNU") + add_compile_options(-fpermissive) +endif() + find_package(Threads REQUIRED) add_subdirectory(src)