ci: add LLVM library path to LD_LIBRARY_PATH and GDB allowlist

This commit is contained in:
Kittywhiskers Van Gogh 2024-12-15 10:57:08 +00:00
parent 440fd3fe21
commit 64cdc42130
No known key found for this signature in database
GPG Key ID: 30CD0C065E5C4AAD

View File

@ -68,6 +68,8 @@ RUN set -ex; \
lldbUpdAltArgs="${lldbUpdAltArgs} --slave /usr/bin/${binName} ${binName} /usr/bin/${binName}-${LLVM_VERSION}"; \ lldbUpdAltArgs="${lldbUpdAltArgs} --slave /usr/bin/${binName} ${binName} /usr/bin/${binName}-${LLVM_VERSION}"; \
done; \ done; \
sh -c "${lldbUpdAltArgs}"; sh -c "${lldbUpdAltArgs}";
# LD_LIBRARY_PATH is empty by default, this is the first entry
ENV LD_LIBRARY_PATH="/usr/lib/llvm-${LLVM_VERSION}/lib"
# Python setup # Python setup
# PYTHON_VERSION should match the value in .python-version # PYTHON_VERSION should match the value in .python-version
@ -107,14 +109,15 @@ ARG DASH_HASH_VERSION=1.4.0
RUN git clone --depth 1 --no-tags --branch=${DASH_HASH_VERSION} https://github.com/dashpay/dash_hash RUN git clone --depth 1 --no-tags --branch=${DASH_HASH_VERSION} https://github.com/dashpay/dash_hash
RUN cd dash_hash && pip3 install -r requirements.txt . RUN cd dash_hash && pip3 install -r requirements.txt .
# Add user with specified (or default) user/group ids and setup configuration files
ARG USER_ID=1000 ARG USER_ID=1000
ARG GROUP_ID=1000 ARG GROUP_ID=1000
RUN set -ex; \
# add user with specified (or default) user/group ids groupadd -g ${GROUP_ID} dash; \
ENV USER_ID="${USER_ID}" useradd -u ${USER_ID} -g dash -s /bin/bash -m -d /home/dash dash; \
ENV GROUP_ID="${GROUP_ID}" mkdir -p /home/dash/.config/gdb; \
RUN groupadd -g ${GROUP_ID} dash echo "add-auto-load-safe-path /usr/lib/llvm-${LLVM_VERSION}/lib" | tee /home/dash/.config/gdb/gdbinit; \
RUN useradd -u ${USER_ID} -g dash -s /bin/bash -m -d /home/dash dash chown ${USER_ID}:${GROUP_ID} -R /home/dash
# Packages needed for all target builds # Packages needed for all target builds
RUN apt-get update && apt-get install $APT_ARGS \ RUN apt-get update && apt-get install $APT_ARGS \