Skip to content

Commit 9731682

Browse files
authored
Update Makefile (ggml-org#345)
fix requirements for idiotic source file concatenation (lol)
1 parent d8d2449 commit 9731682

File tree

1 file changed

+7
-4
lines changed

1 file changed

+7
-4
lines changed

Makefile

+7-4
Original file line numberDiff line numberDiff line change
@@ -335,13 +335,16 @@ grammar-parser.o: examples/grammar-parser.cpp examples/grammar-parser.h
335335
$(CXX) $(CXXFLAGS) -c $< -o $@
336336
expose.o: expose.cpp expose.h
337337
$(CXX) $(CXXFLAGS) -c $< -o $@
338-
gpttype_adapter_failsafe.o: gpttype_adapter.cpp
338+
339+
# idiotic "for easier compilation"
340+
GPTTYPE_ADAPTER = gpttype_adapter.cpp otherarch/llama_v2.cpp llama.cpp otherarch/utils.cpp otherarch/gptj_v1.cpp otherarch/gptj_v2.cpp otherarch/gptj_v3.cpp otherarch/gpt2_v1.cpp otherarch/gpt2_v2.cpp otherarch/gpt2_v3.cpp otherarch/rwkv_v2.cpp otherarch/rwkv_v3.cpp otherarch/neox_v2.cpp otherarch/neox_v3.cpp otherarch/mpt_v3.cpp ggml.h ggml-cuda.h llama.h llama-util.h
341+
gpttype_adapter_failsafe.o: $(GPTTYPE_ADAPTER)
339342
$(CXX) $(CXXFLAGS) $(FAILSAFE_FLAGS) -c $< -o $@
340-
gpttype_adapter.o: gpttype_adapter.cpp
343+
gpttype_adapter.o: $(GPTTYPE_ADAPTER)
341344
$(CXX) $(CXXFLAGS) -c $< -o $@
342-
gpttype_adapter_clblast.o: gpttype_adapter.cpp
345+
gpttype_adapter_clblast.o: $(GPTTYPE_ADAPTER)
343346
$(CXX) $(CXXFLAGS) $(CLBLAST_FLAGS) -c $< -o $@
344-
gpttype_adapter_cublas.o: gpttype_adapter.cpp
347+
gpttype_adapter_cublas.o: $(GPTTYPE_ADAPTER)
345348
$(CXX) $(CXXFLAGS) $(CUBLAS_FLAGS) -c $< -o $@
346349

347350
clean:

0 commit comments

Comments
 (0)