ik-llama.cpp-cuda

This commit is contained in:
Orion 2025-07-31 09:40:53 +08:00
commit cb41acb605
2 changed files with 100 additions and 0 deletions

31
.SRCINFO Normal file
View file

@ -0,0 +1,31 @@
pkgbase = ik-llama.cpp-cuda
pkgdesc = llama.cpp fork with additional SOTA quants and improved performance (CUDA Backend)
pkgver = 1.0
pkgrel = 1
url = https://github.com/ikawrakow/ik_llama.cpp
arch = x86_64
arch = armv7h
arch = aarch64
license = MIT
makedepends = cmake
makedepends = git
depends = cuda
depends = nvidia-utils
depends = curl
depends = gcc-libs
depends = glibc
depends = python
provides = llama.cpp
conflicts = libggml
conflicts = ggml
conflicts = llama.cpp
conflicts = llama.cpp-vulkan
conflicts = llama.cpp-cuda
conflicts = llama.cpp-hip
conflicts = ik-llama.cpp
options = lto
options = !debug
source = git+https://github.com/ikawrakow/ik_llama.cpp
sha256sums = SKIP
pkgname = ik-llama.cpp-cuda

69
PKGBUILD Normal file
View file

@ -0,0 +1,69 @@
# Maintainer: Orion-zhen <https://github.com/Orion-zhen>
pkgname=ik-llama.cpp-cuda
_pkgname=ik_llama.cpp
pkgver=1.0
pkgrel=1
pkgdesc="llama.cpp fork with additional SOTA quants and improved performance (CUDA Backend)"
arch=(x86_64 armv7h aarch64)
url="https://github.com/ikawrakow/ik_llama.cpp"
license=("MIT")
depends=(
cuda
nvidia-utils
curl
gcc-libs
glibc
python
)
makedepends=(
cmake
git
)
conflicts=(
libggml
ggml
llama.cpp
llama.cpp-vulkan
llama.cpp-cuda
llama.cpp-hip
ik-llama.cpp
)
provides=(llama.cpp)
options=(lto !debug)
source=("git+${url}")
sha256sums=("SKIP")
pkgver() {
cd "$_pkgname"
printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
}
build() {
local _cmake_options=(
-B build
-S "${_pkgname}"
-DCMAKE_INSTALL_PREFIX='/usr'
-DBUILD_SHARED_LIBS=ON
-DLLAMA_CURL=ON
-DLLAMA_BUILD_TESTS=OFF
-DLLAMA_USE_SYSTEM_GGML=OFF
-DGGML_ALL_WARNINGS=OFF
-DGGML_ALL_WARNINGS_3RD_PARTY=OFF
-DGGML_BUILD_EXAMPLES=OFF
-DGGML_BUILD_TESTS=OFF
-DGGML_CUDA=ON
-DGGML_LTO=ON
-DGGML_RPC=ON
-DGGML_NATIVE=ON
-Wno-dev
)
cmake "${_cmake_options[@]}"
cmake --build build --config Release
}
package() {
DESTDIR="${pkgdir}" cmake --install build
}