Package-Scoped USE Flags (use.local.desc / metadata.xml)

Flag Representative Description Distinct Packages Repo Instances
accelerate ggml: enable Accelerate framework 1 1
amd build for AMD GPU, ROCM-based 2 2
amd_mae enable experimental memory efficient attention on some AMD GPUs 2 2
android Package for Android via dev-python/python-for-android (recommended) 2 2
apache Create apache configuration. 1 1
blas ggml: use BLAS; for using specific vendor check https://wiki.gentoo.org/wiki/Blas-lapack-switch 1 1
blis ggml: use BLIS ( https://github.com/flame/blis ) 1 1
buildozer Cross-compile Kivy apps via dev-python/buildozer (recommended) 1 1
cann ggml: use CANN ; This provides NPU acceleration using the AI cores of your Ascend NPU. 1 1
comfyui build the built-in ComfyUI backend. If unselected, you will have to manually install backend later on. 1 1
cpu build for CPU-generation only 3 3
cpu-all-variants ggml: enable CPU backend; please use together with cpu flag; ggml: build all variants of the CPU backend (requires GGML_BACKEND_DL) 1 1
cpu-native ggml: enable CPU backend; please use together with cpu flag; it will add `-march=native` by itself. CPU_FLAGS_* consistency is expected to be user's problem 1 1
cpuonly If using systemd, adjust the systemd service parameters to ignore the GPU and use only CPU. 1 1
cuda ggml: use CUDA ; in order for it to compile also tag .... "cpu" has to be selected, don't ask why. Use CMAKE_EXTRA_CACHE_FILE env variable (check https://gitweb.gentoo.org/repo/gentoo.git/tree/eclass/cmake.eclass ) to specify next variables: CMAKE_CUDA_ARCHITECTURES ( use next command to find native architecture: `nvidia-smi --query-gpu=compute_cap --format=csv | tail -n 1 | sed -e 's/\.//g'` ) ; GGML_CUDA_PEER_MAX_BATCH_SIZE ggml: max. batch size for using peer access, default: 128 1 1
cuda-f16 ggml: use 16 bit floats for some calculations 1 1
cuda-fa-all-quants ggml: compile all quants for FlashAttention 1 1
cuda-force-cublas ggml: always use cuBLAS instead of mmq kernels 1 1
cuda-force-mmq ggml: use mmq kernels instead of cuBLAS 1 1
cuda-graphs ggml: use CUDA graphs (llama.cpp only) 1 1
cuda-no-peer-copy ggml: do not use peer to peer copies 1 1
cuda-no-vmm ggml: do not try to use CUDA VMM 1 1
cuda-unified-memory ggml: CUDA : unified memory: allow CUDA app use unified memory architecture (UMA) to share main memory between the CPU and integrated GPU 1 1
cython Enable Kivy C extensions via dev-python/cython (recommended) 1 1
debugger Install the CUDA debugger 1 1
desktop Create a "desktop" file (browser launcher) and add an icon. 3 3
disable-arm-neon Disable Arm Neon. Arm Neon is an advanced single instruction multiple data (SIMD) architecture extension for the Arm Cortex-A and Arm Cortex-R series of processors. Might help in case of CUDA related compilations errors: https://github.com/ggml-org/llama.cpp/issues/12826 1 1
dist-kernel Marking for an automatic module-rebuild for a distribution kernel. 1 1
dynamic-backends In most cases, it is possible to build and use multiple backends at the same time. For example, you can build llama.cpp with both CUDA and Vulkan support by using the -DGGML_CUDA=ON -DGGML_VULKAN=ON options with CMake. At runtime, you can specify which backend devices to use with the --device option. To see a list of available devices, use the --list-devices option. Backends can be built as dynamic libraries that can be loaded dynamically at runtime. This allows you to use the same llama.cpp binary on different machines with different GPUs. To enable this feature, use the GGML_BACKEND_DL option when building. GGML_NATIVE ("cpu-native" flag) is not compatible with GGML_BACKEND_DL, if you want to use also native flag, consider using otherwise GGML_CPU_ALL_VARIANTS 1 1
examples Build and install example Kivy apps 3 3
gles2 Enable GLES2 support 1 1
hbm ggml: use memkind for CPU HBM ( High Bandwidth Memory , check wikipedia.) ; a hardware-related feature 1 1
highlight Enable syntax highlighting support via dev-python/pygments 1 1
hip ggml: use HIP 1 1
hip-graphs ggml: use HIP graph, experimental, slow 1 1
hip-no-vmm ggml: do not try to use HIP VMM 1 1
hip-uma ggml: use HIP unified memory architecture : from docs/build.md : On Linux it is also possible to use unified memory architecture (UMA) to share main memory between the CPU and integrated GPU by setting -DGGML_HIP_UMA=ON. However, this hurts performance for non-integrated GPUs (but enables working with integrated GPUs). 1 1
imaging Enable image manipulation support via dev-python/pillow (recommended) 1 1
intel build for Intel GPU (XPU) Compatible Hardware ( https://docs.pytorch.org/docs/main/notes/get_start_xpu.html ): Intel® Arc A-Series Graphics (CodeName: Alchemist); Intel® Arc B-Series Graphics (CodeName: Battlemage); Intel® Core™ Ultra Processors with Intel® Arc™ Graphics (CodeName: Meteor Lake-H); Intel® Core™ Ultra Desktop Processors (Series 2) with Intel® Arc™ Graphics (CodeName: Lunar Lake); Intel® Core™ Ultra Mobile Processors (Series 2) with Intel® Arc™ Graphics (CodeName: Arrow Lake-H); Intel® Data Center GPU Max Series (CodeName: Ponte Vecchio) 2 2
ios Package for iOS via dev-python/kivy-ios (currently broken) 1 1
ipex build for Intel GPU (IPEX) Compatible Hardware: Intel® Arc™ A-Series Graphics (Intel® Arc™ A770 [Verified], Intel® Arc™ A750, Intel® Arc™ A580, Intel® Arc™ A770M, Intel® Arc™ A730M, Intel® Arc™ A550M); Intel® Arc™ B-Series Graphics (Intel® Arc™ B580 [Verified], Intel® Arc™ B570); Intel® Data Center GPU Max Series [Verified]; For GPUs newer than Intel® Core™ Ultra Processors with Intel® Arc™ Graphics (Meteor Lake) or Intel® Arc™ A-Series Graphics that aren't listed, please check the AOT documentation ( https://www.intel.com/content/www/us/en/docs/dpcpp-cpp-compiler/developer-guide-reference/2025-0/ahead-of-time-compilation.html ) to see if it is supported. If so, follow instructions in the source section above to compile from source. 2 2
kleidiai ggml: use kleidiai optimized kernels if applicable 1 1
kompute ggml: use Kompute 1 1
llamafile ggml: use LLAMAFILE 1 1
lm-sensors-conf Install a configuration file labelling the fans as fan1 and fan2, and additionally showing the thermal zone reading (which might duplicate acpitz) 1 1
metal ggml: use Metal; use CMAKE_EXTRA_CACHE_FILE env variable (check https://gitweb.gentoo.org/repo/gentoo.git/tree/eclass/cmake.eclass ) to specify next variables: ggml: metal minimum macOS version GGML_METAL_MACOSX_VERSION_MIN ; ggml: metal standard version (-std flag) GGML_METAL_STD 1 1
metal-embed-library ggml: embed Metal library 1 1
metal-ndebug ggml: disable Metal debugging 1 1
metal-shader-debug ggml: compile Metal with -fno-fast-math 1 1
metal-use-bf16 ggml: use bfloat if available 1 1
msvc Enable if you build with MSVC 1 1
musa ggml: use MUSA ; This provides GPU acceleration using a Moore Threads GPU. 1 1
nginx Create nginx configuration. 2 2
nginx_mainline Use www-servers/nginx:mainline as a web server for peertube. 1 1
nsight Install profiling and optimizing tools (nsight-compute, nsight-systems) 1 1
nvidia build for NVidia GPU, cuda-based 2 2
ollama Install also Ollama to be used with this server. 1 1
opencl ggml: use OpenCL; This provides GPU acceleration through OpenCL on recent Adreno GPU. 1 1
opencl-embed-kernels ggml: embed kernels 1 1
opencl-profiling ggml: use OpenCL profiling (increases overhead) 1 1
opencl-use-adreno-kernels ggml: use optimized kernels for Adreno 1 1
openmp ggml: use OpenMP 2 2
pango Enable support for x11-libs/pango 1 1
profiler Install the NVIDIA CUDA profiler (nvprof) and the related libraries 1 1
pygame Enable SDL2 support via dev-python/pygame 1 1
pytest Enable downstream "kivy.tests" Kivy app testing via dev-python/pytest 1 1
python_single_target_python3_10 Build for Python3.10 3 3
python_single_target_python3_11 Build for Python3.11 5 5
python_single_target_python3_12 Build for Python3.12 5 5
python_single_target_python3_13 Build for Python3.13 4 4
rdma Enable infiniband support via <pkg>sys-cluster/rdma-core</pkg> 1 1
rdna2 build for AMD GPU (together with amd flag), for 6700, 6600 and maybe other RDNA2 or older 2 2
rdna3 build for AMD GPU (together with amd flag), for AMD 7600 and maybe other RDNA3 cards 2 2
rpc ggml: use RPC 1 1
rst Enable reStructuredText (reST) support via dev-python/docutils 1 1
sanitizer Install compute-sanitizer tool 1 1
server ggml: build examples ; "llama: build server example" 1 1
static static build? 1 1
systemd Create a systemd service "comfyui.service" 7 7
test ggml: build tests; "llama: build tests" 2 2
utils Build also llama.cpp utils (scripts) for performing operations on models. 1 1
vis-profiler Install the NVIDIA CUDA visual profiler (nvvp) 1 1
vulkan ggml: use Vulkan ; use CMAKE_EXTRA_CACHE_FILE env variable (check https://gitweb.gentoo.org/repo/gentoo.git/tree/eclass/cmake.eclass ) to specify next variables: GGML_VULKAN_SHADERS_GEN_TOOLCHAIN "" "ggml: toolchain file for vulkan-shaders-gen" 1 1
vulkan-check-results ggml: run Vulkan op checks 1 1
vulkan-debug ggml: enable Vulkan debug output 1 1
vulkan-memory-debug ggml: enable Vulkan memory debug output 1 1
vulkan-perf ggml: enable Vulkan perf output 1 1
vulkan-run-tests ggml: run Vulkan tests 1 1
vulkan-shader-debug-info ggml: enable Vulkan shader debug info 1 1
vulkan-validate ggml: enable Vulkan validation 1 1
webgpu The WebGPU backend relies on Dawn: https://dawn.googlesource.com/dawn 1 1

Undocumented / Declared-Only Flags (IUSE / REQUIRED_USE)

Flag Distinct Packages Repo Instances
X 1 1
clang 1 1
cpu_flags_loong_lasx 1 1
cpu_flags_loong_lsx 1 1
cpu_flags_riscv_rvv 1 1
cpu_flags_x86_amx_bf16 1 1
cpu_flags_x86_amx_int8 1 1
cpu_flags_x86_amx_tile 1 1
cpu_flags_x86_avx 1 1
cpu_flags_x86_avx2 1 1
cpu_flags_x86_avx512 1 1
cpu_flags_x86_avx512_bf16 1 1
cpu_flags_x86_avx512_vbmi 1 1
cpu_flags_x86_avx512_vnni 1 1
cpu_flags_x86_avx_vnni 1 1
cpu_flags_x86_f16c 1 1
cpu_flags_x86_fma 1 1
cpu_flags_x86_sse 1 1
cpu_flags_x86_sse2 1 1
cpu_flags_x86_sse3 1 1
cpu_flags_x86_sse4 1 1
cpu_flags_x86_sse41 1 1
cpu_flags_x86_sse42 1 1
cpu_flags_x86_sse4a 1 1
cpu_flags_x86_ssse3 1 1
cuda12 1 1
cuda13 1 1
curl 1 1
debug 1 1
doc 2 2
gstreamer 1 1
lto 1 1
nls 1 1
opengl 1 1
python_single_target_python3_14 3 3
python_targets_python3_10 1 1
python_targets_python3_11 1 1
python_targets_python3_12 1 1
sdl 1 1
spell 1 1
startup-notification 1 1
system-glib 1 1
udev 1 1
vim-syntax 1 1
wayland 1 1