Kebab Build and Environment
When to Use This Skill
- •User asks to build project from scratch
- •User sees CUDA detection failures (
CUDA_PATH/CUDA_ARCH/nvidia-smi) - •User asks for debug/release build instructions
- •User asks to clean and rebuild reliably
Prerequisites
- •Linux with NVIDIA driver and visible GPU (
nvidia-smiworks) - •CUDA toolkit and
nvcc - •CMake (3.18+) and GNU Make
- •
yaml-cppdevelopment headers
Step-by-Step Workflows
Workflow A: Standard Build (preferred)
- •Check environment:
- •
make gpu-info
- •
- •Prepare dependencies:
- •
make setup
- •
- •Build:
- •
make build
- •
Workflow B: Explicit CMake Build
- •Configure:
- •
cmake -S kebab -B build -DCUDA_ARCH=sm_90a
- •
- •Compile:
- •
cmake --build build -j$(nproc)
- •
Workflow C: Clean Rebuild
- •
make clean - •
make build
Environment Guidance
- •If auto detection fails, set:
- •
export CUDA_PATH=/usr/local/cuda - •
export CUDA_ARCH=sm_90a
- •
- •Hopper WGMMA workloads should use
sm_90awhen possible.
Troubleshooting
| Issue | Mitigation |
|---|---|
GPU detection failed from Makefile | Run nvidia-smi; then set CUDA_ARCH manually |
CUDA toolkit not found | Set CUDA_PATH and ensure ${CUDA_PATH}/bin/nvcc exists |
| CMake configure fails | Remove build/ and rerun configure+build |
References
- •
Makefile(setup,gpu-info,cmake-configure,cmake-build,clean) - •
kebab/CMakeLists.txt