mirror of https://github.com/google/oss-fuzz.git
Oak: Use the same version of rust the we use internally (#8217)
This commit is contained in:
parent
bbb34977ef
commit
b8905d6862
|
@ -24,9 +24,33 @@ RUN apt-get --yes update \
|
|||
&& apt-get clean \
|
||||
&& rm --recursive --force /var/lib/apt/lists/*
|
||||
|
||||
# Install rustup.
|
||||
ARG rustup_dir=/usr/local/cargo
|
||||
ENV RUSTUP_HOME ${rustup_dir}
|
||||
ENV CARGO_HOME ${rustup_dir}
|
||||
ENV PATH "${rustup_dir}/bin:${PATH}"
|
||||
RUN curl --location https://sh.rustup.rs > /tmp/rustup \
|
||||
&& sh /tmp/rustup -y --default-toolchain=none \
|
||||
&& chmod a+rwx ${rustup_dir} \
|
||||
&& rustup --version
|
||||
|
||||
# Install Rust toolchain.
|
||||
# We currently need the nightly version in order to be able to compile some of the examples.
|
||||
# See https://rust-lang.github.io/rustup-components-history/ for how to pick a version that supports
|
||||
# the appropriate set of components.
|
||||
ARG rust_version=nightly-2022-04-22
|
||||
RUN rustup toolchain install ${rust_version} \
|
||||
&& rustup default ${rust_version}
|
||||
|
||||
# Install WebAssembly target for Rust.
|
||||
RUN rustup target add wasm32-unknown-unknown
|
||||
|
||||
# Install musl target for Rust (for statically linked binaries).
|
||||
RUN rustup target add x86_64-unknown-linux-musl
|
||||
|
||||
# Install rust-src. Needed to recompile rust std library for MSAN
|
||||
RUN rustup component add rust-src
|
||||
|
||||
# Install Protobuf compiler.
|
||||
ARG protobuf_version=3.13.0
|
||||
ARG protobuf_sha256=4a3b26d1ebb9c1d23e933694a6669295f6a39ddc64c3db2adf671f0a6026f82e
|
||||
|
|
Loading…
Reference in New Issue