Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use clang-14 for paritytech/base-ci-linux #488

Merged
merged 1 commit into from
Nov 24, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 7 additions & 7 deletions dockerfiles/base-ci-linux/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,8 @@ COPY utility/base-ci-linux-config /root/.cargo/config
ENV RUSTUP_HOME=/usr/local/rustup \
CARGO_HOME=/usr/local/cargo \
PATH=/usr/local/cargo/bin:$PATH \
CC=clang-13 \
CXX=clang-13
CC=clang-14 \
CXX=clang-14

# install tools and dependencies
RUN set -eux; \
Expand All @@ -41,13 +41,13 @@ RUN set -eux; \
libssl-dev make cmake graphviz \
git pkg-config curl time rhash ca-certificates \
python3 python3-pip lsof ruby ruby-bundler git-restore-mtime xz-utils unzip gnupg protobuf-compiler && \
# add clang 13 repo
# add clang 14 repo
curl -s https://apt.llvm.org/llvm-snapshot.gpg.key | apt-key add -; \
echo "deb http://apt.llvm.org/buster/ llvm-toolchain-buster-13 main" >> /etc/apt/sources.list.d/llvm-toochain-buster-13.list; \
echo "deb-src http://apt.llvm.org/buster/ llvm-toolchain-buster-13 main" >> /etc/apt/sources.list.d/llvm-toochain-buster-13.list; \
echo "deb http://apt.llvm.org/buster/ llvm-toolchain-buster-14 main" >> /etc/apt/sources.list.d/llvm-toochain-buster-14.list; \
echo "deb-src http://apt.llvm.org/buster/ llvm-toolchain-buster-14 main" >> /etc/apt/sources.list.d/llvm-toochain-buster-14.list; \
apt-get -y update; \
apt-get install -y --no-install-recommends \
clang-13 lldb-13 lld-13 libclang-13-dev && \
clang-14 lldb-14 lld-14 libclang-14-dev && \
# add non-root user
groupadd -g 1000 nonroot && \
useradd -u 1000 -g 1000 -s /bin/bash -m nonroot && \
Expand All @@ -61,7 +61,7 @@ RUN set -eux; \
curl -L "https://dl.min.io/client/mc/release/linux-amd64/mc" -o /usr/local/bin/mc && \
chmod 755 /usr/local/bin/mc && \
# set a link to clang
update-alternatives --install /usr/bin/cc cc /usr/bin/clang-13 100; \
update-alternatives --install /usr/bin/cc cc /usr/bin/clang-14 100; \
# install rustup, use minimum components
curl -L "https://static.rust-lang.org/rustup/dist/x86_64-unknown-linux-gnu/rustup-init" \
-o rustup-init; \
Expand Down
6 changes: 3 additions & 3 deletions dockerfiles/base-ci-linux/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,9 @@ Used to build and test Substrate-based projects.
**Dependencies and Tools:**

- `libssl-dev`
- `clang-13`
- `lld-13`
- `libclang-13-dev`
- `clang-14`
- `lld-14`
- `libclang-14-dev`
- `make`
- `cmake`
- `git`
Expand Down
4 changes: 2 additions & 2 deletions dockerfiles/utility/base-ci-linux-config
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
[target.wasm32-unknown-unknown]
runner = "node"
linker="clang-13"
linker="clang-14"

[target.x86_64-unknown-linux-gnu]
# Enables the aes-ni instructions for RustCrypto dependency.
rustflags = ["-Ctarget-feature=+aes,+sse2,+ssse3"]
# setup clang as Linker
linker="clang-13"
linker="clang-14"