Skip to content

Commit b8a834c

Browse files
committed
[DOCKER]: botan-config.cmake patch for libbotan-3-dev
Patch the botan config file for libbotan-3-dev. It is expecting the header files in a wrong location Same goes for the library files, it is not considering multi architecture.
1 parent 26fdfe6 commit b8a834c

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

Dockerfile

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,12 @@ ARG disable_threads=0
4545
ARG build_type=Rel
4646
ARG install_dir=/usr/local/bin
4747

48+
# Patch the Botan config file for header paths: (THIS IS FIXED IN BOTAN 3.8 - REMOVE WHEN apt-get HAS UPDATED)
49+
RUN sh -c 'arch=$(dpkg-architecture -qDEB_HOST_MULTIARCH) && \
50+
BOTAN_CFG=$(find / -type f -iname "botan-config.cmake" 2>/dev/null | grep "/usr/lib/$arch" | head -n1) && \
51+
[ -n "$BOTAN_CFG" ] && \
52+
sed -i -e "s|\${_Botan_PREFIX}/include|/usr/include|g" -e "s|\${_Botan_PREFIX}/lib|/usr/lib/$arch|g" "$BOTAN_CFG"'
53+
4854
# Generate Makefile & compile
4955
RUN --mount=type=cache,target=build \
5056
cmake -S . -B build \

0 commit comments

Comments
 (0)