From 39e050d9e2ad906eba49614bae6e5ff0ebb16ee0 Mon Sep 17 00:00:00 2001 From: "LocalAI [bot]" <139863280+localai-bot@users.noreply.github.com> Date: Sun, 31 May 2026 23:56:07 +0200 Subject: [PATCH] fix(parakeet-cpp): cublas/hipblas/vulkan builds were silently CPU-only (#10120) fix(parakeet-cpp): forward PARAKEET_GGML_* so cublas/hipblas/vulkan builds aren't silently CPU-only parakeet.cpp gates its GGML backends behind PARAKEET_GGML_CUDA/HIP/VULKAN and does set(GGML_CUDA ${PARAKEET_GGML_CUDA} CACHE BOOL "" FORCE), which overwrites a bare -DGGML_CUDA=ON back to OFF. So the backend's BUILD_TYPE=cublas (and hipblas, vulkan) produced a CPU-only libparakeet.so. Forward the PARAKEET_GGML_* options instead. Verified on a GB10 (CUDA 13): the lib now links libcudart/libcublas and registers the CUDA backend, vs a CPU-only lib before. Assisted-by: Claude:claude-opus-4-8 [Claude Code] Signed-off-by: Ettore Di Giacinto Co-authored-by: Ettore Di Giacinto --- backend/go/parakeet-cpp/Makefile | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/backend/go/parakeet-cpp/Makefile b/backend/go/parakeet-cpp/Makefile index 80ba1696d..a31b75f06 100644 --- a/backend/go/parakeet-cpp/Makefile +++ b/backend/go/parakeet-cpp/Makefile @@ -34,14 +34,18 @@ ifeq ($(NATIVE),false) CMAKE_ARGS+=-DGGML_NATIVE=OFF endif +# parakeet.cpp gates its GGML backends behind PARAKEET_GGML_* options and does +# set(GGML_CUDA ${PARAKEET_GGML_CUDA} CACHE BOOL "" FORCE), so a bare -DGGML_CUDA=ON +# is overwritten back to OFF and the build silently falls back to CPU. Forward the +# PARAKEET_GGML_* options instead. (openblas is not gated, so -DGGML_BLAS passes through.) ifeq ($(BUILD_TYPE),cublas) - CMAKE_ARGS+=-DGGML_CUDA=ON + CMAKE_ARGS+=-DPARAKEET_GGML_CUDA=ON else ifeq ($(BUILD_TYPE),openblas) CMAKE_ARGS+=-DGGML_BLAS=ON -DGGML_BLAS_VENDOR=OpenBLAS else ifeq ($(BUILD_TYPE),hipblas) - CMAKE_ARGS+=-DGGML_HIP=ON + CMAKE_ARGS+=-DPARAKEET_GGML_HIP=ON else ifeq ($(BUILD_TYPE),vulkan) - CMAKE_ARGS+=-DGGML_VULKAN=ON + CMAKE_ARGS+=-DPARAKEET_GGML_VULKAN=ON endif .PHONY: parakeet-cpp-grpc package build clean purge test all