fluffos/Dockerfile
Michael Programs 6f33a65c13
build: add pkg-config and libffi to dependency lists (#1235)
package_ffi requires pkg-config and libffi (find_package(PkgConfig
REQUIRED) + pkg_check_modules(FFI REQUIRED libffi) in
src/packages/ffi/CMakeLists.txt), but the docs, Dockerfile, and CI
package lists never listed them — CI only passed because the runners
preinstall pkg-config.
Add the platform-appropriate packages across every dependency list:
- apt: pkg-config libffi-dev
- brew: libffi (pkg-config already present)
- apk: pkgconf libffi-dev
- pacman: mingw-w64-x86_64-pkgconf mingw-w64-x86_64-libffi
Also note in the build docs that flex is only needed when editing the
LPC lexer; otherwise the pre-committed generated lexer is used.
2026-07-10 23:26:25 -04:00

36 lines
946 B
Docker

FROM alpine:3.18 AS builder
RUN apk add --no-progress --no-cache \
linux-headers gcc g++ clang-dev make cmake bash \
mariadb-dev mariadb-static postgresql-dev sqlite-dev sqlite-static\
openssl-dev openssl-libs-static zlib-dev zlib-static icu-dev icu-static \
pcre-dev bison git musl-dev libelf-static elfutils-dev zstd-static bzip2-static xz-static \
pkgconf libffi-dev
WORKDIR /build
RUN wget -O - https://github.com/jemalloc/jemalloc/releases/download/5.3.0/jemalloc-5.3.0.tar.bz2 | tar -xj
WORKDIR /build/jemalloc-5.3.0
RUN ./configure --prefix=/usr \
&& make \
&& make install
COPY . /build/fluffos
RUN mkdir /build/fluffos/build
WORKDIR /build/fluffos/build
RUN cmake .. -DMARCH_NATIVE=OFF -DSTATIC=ON \
&& make install
FROM alpine:3.18
RUN apk add --no-progress --no-cache \
icu-data-full
WORKDIR /fluffos
COPY --from=builder /build/fluffos/build/bin ./bin
ENTRYPOINT ["/fluffos/bin/driver"]