]> git.djapps.eu Git - pkg/ggml/sources/whisper.cpp/commitdiff
cmake : allow external ggml
authorBorislav Stanimirov <redacted>
Mon, 8 Jul 2024 14:08:55 +0000 (17:08 +0300)
committerGeorgi Gerganov <redacted>
Tue, 9 Jul 2024 08:38:15 +0000 (11:38 +0300)
CMakeLists.txt

index 7bcb0347a5d29c9ee75075da8e938a090c1bf4e0..cb17def7d40c1d084a9844d3ac872dcdf9d9ef5f 100644 (file)
@@ -120,7 +120,10 @@ whisper_option_depr(WARNING     WHISPER_SYCL_F16            GGML_SYCL_F16)
 # build the library
 #
 
-add_subdirectory(ggml)
+if (NOT TARGET ggml)
+    add_subdirectory(ggml)
+    # ... otherwise assume ggml is added by a parent CMakeLists.txt
+endif()
 add_subdirectory(src)
 
 #