Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Compiling in Fedora 38 #1

Open
cap-nestor opened this issue Jun 16, 2023 · 1 comment
Open

Compiling in Fedora 38 #1

cap-nestor opened this issue Jun 16, 2023 · 1 comment

Comments

@cap-nestor
Copy link

Just in case someone else have this issue while compiling in Fedora 38 (after installing cmake: sudo dnf install cmake)

[nalonso@satellite build]$ cmake --build . --parallel
[ 14%] Built target ggml
[ 42%] Built target llama
[ 57%] Linking CXX executable ../bin/chat
/usr/bin/ld: cannot find -lstdc++: No such file or directory
/usr/bin/ld: cannot find -lm: No such file or directory
/usr/bin/ld: cannot find -lc: No such file or directory
collect2: error: ld returned 1 exit status
gmake[2]: *** [src/CMakeFiles/chat.dir/build.make:130: bin/chat] Error 1
gmake[1]: *** [CMakeFiles/Makefile2:171: src/CMakeFiles/chat.dir/all] Error 2
gmake: *** [Makefile:91: all] Error 2

Run:

sudo dnf install libstdc++-static glibc-static

And it compiles fine:

[nalonso@satellite build]$ cmake --build . --parallel
[ 57%] Building C object llama.cpp/CMakeFiles/ggml.dir/ggml.c.o
[ 57%] Built target ggml
[ 57%] Building CXX object llama.cpp/CMakeFiles/llama.dir/llama.cpp.o
[ 57%] Linking CXX static library libllama.a
[ 57%] Built target llama
[ 57%] Building CXX object src/CMakeFiles/chat.dir//llm/llamamodel.cpp.o
[ 57%] Building CXX object src/CMakeFiles/chat.dir/chat.cpp.o
[ 57%] Building CXX object src/CMakeFiles/chat.dir/
/llama.cpp/examples/common.cpp.o
[ 57%] Linking CXX executable ../bin/chat
[ 57%] Built target chat

@kuvaus
Copy link
Owner

kuvaus commented Jun 16, 2023

I just want to say that I appreciate these kind of "this is how you fix it" -post a lot. :)
Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants