Add Docker support for Linux build testing

- Introduced a `Dockerfile` for setting up a minimal Ubuntu-based build environment with required dependencies.
- Added `docker-build.sh` script to simplify Linux build and test execution using Docker or Podman.
- Updated `DEVELOPER_GUIDE.md` with instructions for using Docker/Podman for Linux builds, including CI/CD integration examples.
This commit is contained in:
2026-02-17 16:35:52 -08:00
parent 9485d2aa24
commit 422b27b1ba
5 changed files with 176 additions and 3 deletions

20
Dockerfile Normal file
View File

@@ -0,0 +1,20 @@
# Minimal Dockerfile for building and testing kte on Linux
# This container provides a build environment with all dependencies.
# Mount the source tree at /kte when running the container.
FROM ubuntu:22.04
# Avoid interactive prompts during package installation
ENV DEBIAN_FRONTEND=noninteractive
# Install build dependencies
RUN apt-get update && apt-get install -y \
build-essential \
cmake \
libncursesw5-dev \
&& rm -rf /var/lib/apt/lists/*
# Set working directory where source will be mounted
WORKDIR /kte
# Default command: build and run tests
CMD ["sh", "-c", "cmake -B build -DBUILD_GUI=OFF -DBUILD_TESTS=ON && cmake --build build --target kte && cmake --build build --target kte_tests && ./build/kte_tests"]