Skip to content

Commit

Permalink
chore: cleanup ggml files order
Browse files Browse the repository at this point in the history
  • Loading branch information
jhen0409 committed Nov 21, 2024
1 parent 9b6ea9f commit 0d590a4
Show file tree
Hide file tree
Showing 2 changed files with 28 additions and 30 deletions.
16 changes: 7 additions & 9 deletions android/src/main/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -9,29 +9,27 @@ include_directories(${RNLLAMA_LIB_DIR})

set(
SOURCE_FILES
${RNLLAMA_LIB_DIR}/llama-grammar.cpp
${RNLLAMA_LIB_DIR}/llama-sampling.cpp
${RNLLAMA_LIB_DIR}/llama-vocab.cpp
${RNLLAMA_LIB_DIR}/log.cpp

${RNLLAMA_LIB_DIR}/ggml.c
${RNLLAMA_LIB_DIR}/ggml-aarch64.c
${RNLLAMA_LIB_DIR}/ggml-alloc.c
${RNLLAMA_LIB_DIR}/ggml-backend.cpp
${RNLLAMA_LIB_DIR}/ggml-backend-reg.cpp
${RNLLAMA_LIB_DIR}/ggml.c
${RNLLAMA_LIB_DIR}/ggml-cpu.c
${RNLLAMA_LIB_DIR}/ggml-cpu.cpp
${RNLLAMA_LIB_DIR}/ggml-cpu-aarch64.c
${RNLLAMA_LIB_DIR}/ggml-cpu-quants.c
${RNLLAMA_LIB_DIR}/ggml-threading.cpp
${RNLLAMA_LIB_DIR}/ggml-quants.c
${RNLLAMA_LIB_DIR}/common.cpp
${RNLLAMA_LIB_DIR}/log.cpp
${RNLLAMA_LIB_DIR}/llama-grammar.cpp
${RNLLAMA_LIB_DIR}/llama-sampling.cpp
${RNLLAMA_LIB_DIR}/llama-vocab.cpp
${RNLLAMA_LIB_DIR}/llama.cpp
${RNLLAMA_LIB_DIR}/sampling.cpp
${RNLLAMA_LIB_DIR}/unicode-data.cpp
${RNLLAMA_LIB_DIR}/unicode.cpp
${RNLLAMA_LIB_DIR}/llama.cpp
${RNLLAMA_LIB_DIR}/sgemm.cpp
${RNLLAMA_LIB_DIR}/ggml-aarch64.c
${RNLLAMA_LIB_DIR}/common.cpp
${RNLLAMA_LIB_DIR}/rn-llama.hpp
${CMAKE_SOURCE_DIR}/jni-utils.h
${CMAKE_SOURCE_DIR}/jni.cpp
Expand Down
42 changes: 21 additions & 21 deletions scripts/bootstrap.sh
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,19 @@ cp ./llama.cpp/ggml/include/ggml-cpu.h ./cpp/ggml-cpu.h
cp ./llama.cpp/ggml/include/ggml-cpp.h ./cpp/ggml-cpp.h
cp ./llama.cpp/ggml/include/ggml-metal.h ./cpp/ggml-metal.h

cp ./llama.cpp/ggml/src/ggml-metal/ggml-metal.m ./cpp/ggml-metal.m

cp ./llama.cpp/ggml/src/ggml-cpu/ggml-cpu.c ./cpp/ggml-cpu.c
cp ./llama.cpp/ggml/src/ggml-cpu/ggml-cpu.cpp ./cpp/ggml-cpu.cpp
cp ./llama.cpp/ggml/src/ggml-cpu/ggml-cpu-impl.h ./cpp/ggml-cpu-impl.h
cp ./llama.cpp/ggml/src/ggml-cpu/ggml-cpu-aarch64.h ./cpp/ggml-cpu-aarch64.h
cp ./llama.cpp/ggml/src/ggml-cpu/ggml-cpu-aarch64.c ./cpp/ggml-cpu-aarch64.c
cp ./llama.cpp/ggml/src/ggml-cpu/ggml-cpu-quants.h ./cpp/ggml-cpu-quants.h
cp ./llama.cpp/ggml/src/ggml-cpu/ggml-cpu-quants.c ./cpp/ggml-cpu-quants.c

cp ./llama.cpp/ggml/src/ggml-cpu/llamafile/sgemm.h ./cpp/sgemm.h
cp ./llama.cpp/ggml/src/ggml-cpu/llamafile/sgemm.cpp ./cpp/sgemm.cpp

cp ./llama.cpp/ggml/src/ggml.c ./cpp/ggml.c
cp ./llama.cpp/ggml/src/ggml-impl.h ./cpp/ggml-impl.h
cp ./llama.cpp/ggml/src/ggml-alloc.c ./cpp/ggml-alloc.c
Expand All @@ -26,19 +39,6 @@ cp ./llama.cpp/ggml/src/ggml-aarch64.h ./cpp/ggml-aarch64.h
cp ./llama.cpp/ggml/src/ggml-threading.cpp ./cpp/ggml-threading.cpp
cp ./llama.cpp/ggml/src/ggml-threading.h ./cpp/ggml-threading.h

cp ./llama.cpp/ggml/src/ggml-cpu/ggml-cpu.c ./cpp/ggml-cpu.c
cp ./llama.cpp/ggml/src/ggml-cpu/ggml-cpu.cpp ./cpp/ggml-cpu.cpp
cp ./llama.cpp/ggml/src/ggml-cpu/ggml-cpu-impl.h ./cpp/ggml-cpu-impl.h
cp ./llama.cpp/ggml/src/ggml-cpu/ggml-cpu-aarch64.h ./cpp/ggml-cpu-aarch64.h
cp ./llama.cpp/ggml/src/ggml-cpu/ggml-cpu-aarch64.c ./cpp/ggml-cpu-aarch64.c
cp ./llama.cpp/ggml/src/ggml-cpu/ggml-cpu-quants.h ./cpp/ggml-cpu-quants.h
cp ./llama.cpp/ggml/src/ggml-cpu/ggml-cpu-quants.c ./cpp/ggml-cpu-quants.c

cp ./llama.cpp/ggml/src/ggml-metal/ggml-metal.m ./cpp/ggml-metal.m

cp ./llama.cpp/ggml/src/ggml-cpu/llamafile/sgemm.h ./cpp/sgemm.h
cp ./llama.cpp/ggml/src/ggml-cpu/llamafile/sgemm.cpp ./cpp/sgemm.cpp

cp ./llama.cpp/src/llama.cpp ./cpp/llama.cpp
cp ./llama.cpp/src/llama-impl.h ./cpp/llama-impl.h

Expand Down Expand Up @@ -72,17 +72,20 @@ files_add_lm_prefix=(
"./cpp/llama-sampling.cpp"
"./cpp/log.h"
"./cpp/log.cpp"
"./cpp/llama.h"
"./cpp/llama.cpp"
"./cpp/sampling.cpp"
"./cpp/sgemm.h"
"./cpp/sgemm.cpp"
"./cpp/common.h"
"./cpp/common.cpp"
"./cpp/ggml-common.h"
"./cpp/ggml.h"
"./cpp/ggml.c"
"./cpp/ggml-impl.h"
"./cpp/common.h"
"./cpp/common.cpp"
"./cpp/ggml-cpp.h"
"./cpp/ggml-metal.h"
"./cpp/ggml-metal.m"
"./cpp/llama.h"
"./cpp/llama.cpp"
"./cpp/sampling.cpp"
"./cpp/ggml-quants.h"
"./cpp/ggml-quants.c"
"./cpp/ggml-alloc.h"
Expand All @@ -101,9 +104,6 @@ files_add_lm_prefix=(
"./cpp/ggml-cpu-quants.c"
"./cpp/ggml-threading.h"
"./cpp/ggml-threading.cpp"
"./cpp/ggml-common.h"
"./cpp/sgemm.h"
"./cpp/sgemm.cpp"
"./cpp/ggml-aarch64.h"
"./cpp/ggml-aarch64.c"
)
Expand Down

0 comments on commit 0d590a4

Please sign in to comment.