'Generic Commit'
All checks were successful
dropshell-build / build (push) Successful in 1m1s

This commit is contained in:
Your Name
2025-06-03 00:45:34 +12:00
parent 1da19b9191
commit a882153e56
6 changed files with 12 additions and 8 deletions

View File

@ -2,7 +2,7 @@ FROM --platform=$BUILDPLATFORM alpine:latest AS builder
ARG PROJECT
# Install build dependencies
# Install ccache along with other dependencies
RUN apk add --no-cache \
build-base \
cmake \
@ -15,7 +15,8 @@ RUN apk add --no-cache \
ninja \
linux-headers \
mold \
zlib-static
zlib-static \
ccache
# Set working directory
WORKDIR /build
@ -23,10 +24,12 @@ WORKDIR /build
# Copy source files
COPY . .
# Configure and build
# Configure and build with ccache
RUN mkdir -p build_static && \
cmake -G Ninja -B build_static -DCMAKE_BUILD_TYPE=Release \
-DCMAKE_EXE_LINKER_FLAGS="-static" \
-DCMAKE_CXX_COMPILER_LAUNCHER=ccache \
-DCMAKE_C_COMPILER_LAUNCHER=ccache \
-DCMAKE_EXE_LINKER_FLAGS="-fuse-ld=mold -static" \
-DCMAKE_FIND_LIBRARY_SUFFIXES=".a" \
-DZLIB_BUILD_SHARED=OFF \
-DZLIB_BUILD_STATIC=ON \