-
Notifications
You must be signed in to change notification settings - Fork 8
/
Copy pathDockerfile.extensions-all.x86_64
31 lines (24 loc) · 1.59 KB
/
Dockerfile.extensions-all.x86_64
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
FROM ghcr.io/tobilg/duckdb-nodejs-layer:main as builder
ARG DUCKDB_VERSION=1.1.3
ARG ARCHITECTURE=x86_64
# Get DuckDB sources for specific commit
RUN mkdir -p /tmp/from-git && \
cd /tmp/from-git && \
git clone --branch main https://github.com/duckdb/duckdb.git && \
cd duckdb && \
git fetch --all --tags && \
git checkout v${DUCKDB_VERSION}
# Copy custom cmake extension config
COPY src/duckdb_extension_config.cmake /tmp/from-git/duckdb/extension/extension_config_local.cmake
# Configure
RUN cd /tmp/from-git/duckdb && \
export PATH="/usr/lib/ccache:/usr/local/opt/ccache/libexec:/tmp/from-git/vcpkg:$PATH" && \
make extension_configuration && \
yum install bison patch -y
RUN cd /tmp/from-git/duckdb && \
export PATH="/usr/lib/ccache:/usr/local/opt/ccache/libexec:/tmp/from-git/vcpkg:$PATH" && \
CMAKE_GENERATOR=Ninja OPENSSL_ROOT_DIR=/tmp/from-git/vcpkg/packages/openssl_x64-linux USE_MERGED_VCPKG_MANIFEST=1 CMAKE_TOOLCHAIN_FILE="/tmp/from-git/vcpkg/scripts/buildsystems/vcpkg.cmake" EXTENSION_CONFIGS="/tmp/from-git/duckdb/extension/extension_config_local.cmake" EXTENSION_STATIC_BUILD=1 BUILD_HTTPFS=1 STATIC_LIBCPP=1 CMAKE_BUILD_PROGRAM="/usr/bin/make" CMAKE_VARS="-DOPENSSL_ROOT_DIR=/tmp/from-git/vcpkg/packages/openssl_x64-linux -DCMAKE_TOOLCHAIN_FILE=/tmp/from-git/vcpkg/scripts/buildsystems/vcpkg.cmake -DVCPKG_TARGET_TRIPLET=x64-linux -DVCPKG_BUILD=1 -GNinja" CMAKE_BUILD_PARALLEL_LEVEL=$(nproc) make
RUN mkdir -p /tmp/release && \
cp /tmp/from-git/duckdb/build/release/extension/*/*.duckdb_extension /tmp/release
# Strip binary
#RUN strip --strip-unneeded /tmp/release/*.duckdb_extension