CMake Build Failure for llama_cpp_dart: Missing add_subdirectory Source Directory
Steps to Reproduce
- Make flutter app.
- install library flutter pub add llama_cpp_dart
- Download llama.cpp and make a shared library for me this is .libllama.dylib and add to root.
- Observe the build failure with the above error.
Environment
- Operating System: macOS
- CMake Version: 3.30
- NDK Version: 23.1.7779620
- API Level: 23
- Architecture: arm64-v8a
Additional Information
- The CMakeLists.txt file does not contain a
project()command, which seems to be a requirement. - The path specified for
add_subdirectorydoes not exist, leading to the failure. - Any suggestions on how to resolve these issues would be greatly appreciated!
Expected Behavior
The build should complete successfully without any configuration errors.
Have you found a solution to this yet? We are also facing this problem.
can you edit cmake, this line add_subdirectory(./llama.cpp) to point exactly to where you have cloned llama.cpp make sure to clone exact version
What I did was, cloned the llama.cpp into this ~/.pub-cache/hosted/pub.dev/llama_cpp_dart-0.0.7/src.
And then app runned without any warnings or errors, but when i tried to load model, app crashed. you can on more at here: https://github.com/netdur/llama_cpp_dart/issues/41
What I did was, cloned the llama.cpp into this ~/.pub-cache/hosted/pub.dev/llama_cpp_dart-0.0.7/src.
And then app runned without any warnings or errors, but when i tried to load model, app crashed. you can on more at here: #41
I have the same problem. How can it be fixed?
What I did was, cloned the llama.cpp into this ~/.pub-cache/hosted/pub.dev/llama_cpp_dart-0.0.7/src.
And then app runned without any warnings or errors, but when i tried to load model, app crashed. you can on more at here: #41
this solution worked for me as well but app is being crashed on loading the model
same