You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I wanted to build binaries for Windows and I'm getting an error
/workspace/srcdir/llama.cpp/ggml.c:193:35: error: implicit declaration of function ‘_aligned_malloc’; did you mean
It seems to be linked to an old MinGW bug.
The workaround seems to be just moving inclusion of stdlib.h to the top, so it's called before intrin.h in the file ggml.c.
In practice, it would have to be before "ggml-impl.h", because that calls intrih.h.
| [12:08:21] /workspace/srcdir/llama.cpp/ggml.c: In function ‘ggml_init’:
| [12:08:21] /workspace/srcdir/llama.cpp/ggml.c:193:35: error: implicit declaration of function ‘_aligned_malloc’; did you mean ‘_aligned_realloc’? [-Werror=implicit-function-declaration]
Uh oh!
There was an error while loading. Please reload this page.
First of all, thank you for llama.cpp!
I wanted to build binaries for Windows and I'm getting an error
It seems to be linked to an old MinGW bug.
The workaround seems to be just moving inclusion of
stdlib.h
to the top, so it's called beforeintrin.h
in the file ggml.c.In practice, it would have to be before "ggml-impl.h", because that calls
intrih.h
.This workaround seems to be covered in many places, eg, https://stackoverflow.com/a/10862288.
Steps to reproduce:
Error:
Version: Latest master (b1730)
System: build system for x86_64 (x86_64-w64-mingw32-gcc (GCC) 10.2.0, clang version 16.0.6)
Build log: https://buildkite.com/julialang/yggdrasil/builds/7432#018cba9c-3aff-49f1-a5e3-71ae130b1364
EDIT: The linked build log is for version 1703, but the error persists even for the latest 1730 (tested locally).
The text was updated successfully, but these errors were encountered: