From: Georgi Gerganov Date: Wed, 23 Nov 2022 20:27:49 +0000 (+0200) Subject: ggml : fix cross-compile Linux -> Window with mingw (#168) X-Git-Tag: upstream/1.7.4~1799 X-Git-Url: https://git.djapps.eu/?a=commitdiff_plain;h=35cd29ce1fc79b2b97075456dcfd84e8129e3e66;p=pkg%2Fggml%2Fsources%2Fwhisper.cpp ggml : fix cross-compile Linux -> Window with mingw (#168) --- diff --git a/README.md b/README.md index 2619a6a8..5a20073f 100644 --- a/README.md +++ b/README.md @@ -20,7 +20,7 @@ Supported platforms: - [x] [iOS](examples/whisper.objc) - [x] Linux - [x] [WebAssembly](examples/whisper.wasm) -- [x] Windows ([MSVC](https://github.com/ggerganov/whisper.cpp/blob/master/.github/workflows/build.yml#L117-L144) and [MinGW](https://github.com/ggerganov/whisper.cpp/issues/5)] +- [x] Windows ([MSVC](https://github.com/ggerganov/whisper.cpp/blob/master/.github/workflows/build.yml#L117-L144) and [MinGW](https://github.com/ggerganov/whisper.cpp/issues/168)] - [x] [Raspberry Pi](https://github.com/ggerganov/whisper.cpp/discussions/166) - [x] [Android](https://github.com/ggerganov/whisper.cpp/issues/30) diff --git a/ggml.c b/ggml.c index 17f324e0..6f06023a 100644 --- a/ggml.c +++ b/ggml.c @@ -15,7 +15,14 @@ #include #if defined _MSC_VER || defined(__MINGW32__) + +#ifndef(__MINGW32__) #include +#else +// ref: https://github.com/ggerganov/whisper.cpp/issues/168 +#include +#include +#endif typedef volatile LONG atomic_int; typedef atomic_int atomic_bool;