build-cpu.sh 313 B

123456789101112
  1. #!/bin/bash
  2. name="$1"
  3. args="${@:2}"
  4. echo "Building $name with args: $args"
  5. rm -fr build-cpu-$1
  6. cmake -S . -B build-cpu-$1 -DGGML_BACKEND_DL=ON -DGGML_NATIVE=OFF $args
  7. cmake --build build-cpu-$1 --config Release -t ggml-cpu -j $(nproc)
  8. cp build-cpu-$1/bin/libggml-cpu.so ./libggml-cpu-$1.so
  9. rm -fr build-cpu-$1