Skip to content

Commit 5cb2ed3

Browse files
committed
Restore custom image for Cross
1 parent f7c6b7d commit 5cb2ed3

File tree

2 files changed

+27
-2
lines changed

2 files changed

+27
-2
lines changed

Cross.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
[target.x86_64-unknown-linux-gnu]
2-
pre-build = ["apt-get install -y cmake clang-3.9"]
2+
dockerfile = './scripts/cross/Dockerfile'
33

44
[target.aarch64-unknown-linux-gnu]
5-
pre-build = ["apt-get install -y cmake clang-3.9"]
5+
dockerfile = './scripts/cross/Dockerfile'

scripts/cross/Dockerfile

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
ARG CROSS_BASE_IMAGE
2+
FROM $CROSS_BASE_IMAGE
3+
4+
RUN apt-get update -y && apt-get upgrade -y
5+
6+
RUN apt-get install -y unzip && \
7+
PB_REL="https://github.com/protocolbuffers/protobuf/releases" && \
8+
curl -L $PB_REL/download/v3.15.8/protoc-3.15.8-linux-x86_64.zip -o protoc.zip && \
9+
unzip protoc.zip -d /usr && \
10+
chmod +x /usr/bin/protoc
11+
12+
RUN apt-get install -y \
13+
apt-transport-https \
14+
ca-certificates \
15+
gnupg-agent \
16+
software-properties-common
17+
18+
RUN curl -L https://apt.llvm.org/llvm-snapshot.gpg.key | apt-key add - && \
19+
apt-add-repository "deb http://apt.llvm.org/xenial/ llvm-toolchain-xenial-5.0 main" && \
20+
apt-get update && \
21+
apt-get install -y clang-5.0
22+
23+
RUN apt-get install -y cmake
24+
25+
ENV PROTOC=/usr/bin/protoc

0 commit comments

Comments
 (0)