Răsfoiți Sursa

make : add libllama.so target for llama-cpp-python (#797)

I was able to get llama-cpp-python working but only when I build libllama.so with make.
bhubbb 2 ani în urmă
părinte
comite
698f7b5d63
1 a modificat fișierele cu 2 adăugiri și 0 ștergeri
  1. 2 0
      Makefile

+ 2 - 0
Makefile

@@ -166,6 +166,8 @@ perplexity: examples/perplexity/perplexity.cpp ggml.o llama.o common.o
 embedding: examples/embedding/embedding.cpp ggml.o llama.o common.o
 embedding: examples/embedding/embedding.cpp ggml.o llama.o common.o
 	$(CXX) $(CXXFLAGS) examples/embedding/embedding.cpp ggml.o llama.o common.o -o embedding $(LDFLAGS)
 	$(CXX) $(CXXFLAGS) examples/embedding/embedding.cpp ggml.o llama.o common.o -o embedding $(LDFLAGS)
 
 
+libllama.so: llama.o ggml.o
+	$(CXX) $(CXXFLAGS) -shared -fPIC -o libllama.so llama.o ggml.o $(LDFLAGS)
 #
 #
 # Tests
 # Tests
 #
 #