File tree 2 files changed +24
-8
lines changed
2 files changed +24
-8
lines changed Original file line number Diff line number Diff line change @@ -15,6 +15,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
15
15
16
16
- ` Ruzzy.c_trace_branch ` to ` Ruzzy.trace ` to simplify interface
17
17
- Support for ` clang ` back to ` 14.0.6 ` , and system ` clang ` , e.g. from ` apt ` ([ #12 ] ( https://github.com/trailofbits/ruzzy/pull/12 ) )
18
+ - Support ` RUBY_VERSION ` and ` LLVM_VERSION ` build args when building Docker development image
18
19
19
20
### Fixed
20
21
Original file line number Diff line number Diff line change 1
- FROM debian:12-slim
1
+ # https://hub.docker.com/_/ruby
2
+ ARG RUBY_VERSION=3.3
3
+
4
+ FROM ruby:$RUBY_VERSION-slim-bookworm
5
+
6
+ RUN apt update && apt install -y \
7
+ ca-certificates \
8
+ wget \
9
+ && rm -rf /var/lib/apt/lists/*
10
+
11
+ # LLVM builds version 15-18 for Debian 12 (Bookworm)
12
+ # https://apt.llvm.org/bookworm/dists/
13
+ ARG LLVM_VERSION=18
14
+
15
+ RUN echo "deb http://apt.llvm.org/bookworm/ llvm-toolchain-bookworm-$LLVM_VERSION main" > /etc/apt/sources.list.d/llvm.list
16
+ RUN echo "deb-src http://apt.llvm.org/bookworm/ llvm-toolchain-bookworm-$LLVM_VERSION main" >> /etc/apt/sources.list.d/llvm.list
17
+ RUN wget -qO- https://apt.llvm.org/llvm-snapshot.gpg.key > /etc/apt/trusted.gpg.d/apt.llvm.org.asc
2
18
3
19
RUN apt update && apt install -y \
4
20
build-essential \
5
- clang \
6
- ruby \
7
- ruby-dev \
21
+ clang-$LLVM_VERSION \
8
22
&& rm -rf /var/lib/apt/lists/*
9
23
10
24
ENV APP_DIR="/app"
11
25
RUN mkdir $APP_DIR
12
26
WORKDIR $APP_DIR
13
27
14
- ENV CC="clang"
15
- ENV CXX="clang++"
16
- ENV LDSHARED="clang -shared"
17
- ENV LDSHAREDXX="clang++ -shared"
28
+ ENV CC="clang-$LLVM_VERSION"
29
+ ENV CXX="clang++-$LLVM_VERSION"
30
+ ENV LDSHARED="clang-$LLVM_VERSION -shared"
31
+ ENV LDSHAREDXX="clang++-$LLVM_VERSION -shared"
32
+ ENV ASAN_SYMBOLIZER_PATH="/usr/bin/llvm-symbolizer-$LLVM_VERSION"
18
33
19
34
# The MAKE variable allows overwriting the make command at runtime. This forces the
20
35
# Ruby C extension to respect ENV variables when compiling, like CC, CFLAGS, etc.
You can’t perform that action at this time.
0 commit comments