]> git.djapps.eu Git - pkg/ggml/sources/whisper.cpp/commitdiff
common : fix build min/max (#2845)
authorGeorgi Gerganov <redacted>
Thu, 27 Feb 2025 08:39:13 +0000 (10:39 +0200)
committerGitHub <redacted>
Thu, 27 Feb 2025 08:39:13 +0000 (10:39 +0200)
* common : try to fix build

* cont : try another fix

examples/common.cpp

index ec1fa191e718ec4469a6dd381f8c0a8fcda85391..f114e84d9d86f6ccf508853c2bf9173b687e936c 100644 (file)
@@ -7,6 +7,12 @@
 #define STB_VORBIS_HEADER_ONLY
 #include "stb_vorbis.c"    /* Enables Vorbis decoding. */
 
+#ifdef _WIN32
+#ifndef NOMINMAX
+    #define NOMINMAX
+#endif
+#endif
+
 #define MA_NO_DEVICE_IO
 #define MA_NO_THREADING
 #define MA_NO_ENCODING
 #include "miniaudio.h"
 
 #include <cmath>
+#include <codecvt>
 #include <cstring>
 #include <fstream>
-#include <regex>
 #include <locale>
-#include <codecvt>
+#include <regex>
 #include <sstream>
 
 #if defined(_MSC_VER)