mirror of https://github.com/google/oss-fuzz.git
cras: Build Rust code from ${SRC}/adhd (#10079)
We have a unified Cargo workspace now, so we don't have to build inside the rust specific directory
This commit is contained in:
parent
4e029f1de4
commit
ad4f54ec77
|
@ -41,7 +41,6 @@ RUN apt-get -y update && \
|
||||||
libtool \
|
libtool \
|
||||||
libudev-dev \
|
libudev-dev \
|
||||||
wget \
|
wget \
|
||||||
vim \
|
|
||||||
zip
|
zip
|
||||||
RUN apt-get clean
|
RUN apt-get clean
|
||||||
|
|
||||||
|
@ -64,7 +63,6 @@ RUN mkdir -p /tmp/alsa-build && cd /tmp/alsa-build && \
|
||||||
make -j$(nproc) all && \
|
make -j$(nproc) all && \
|
||||||
make install
|
make install
|
||||||
|
|
||||||
|
|
||||||
RUN cd $SRC && git clone https://chromium.googlesource.com/chromiumos/third_party/adhd
|
RUN cd $SRC && git clone https://chromium.googlesource.com/chromiumos/third_party/adhd
|
||||||
WORKDIR adhd
|
WORKDIR adhd
|
||||||
COPY build.sh $SRC/
|
COPY build.sh $SRC/
|
||||||
|
|
|
@ -21,12 +21,20 @@
|
||||||
# Builds fuzzers from within a container into /out/ directory.
|
# Builds fuzzers from within a container into /out/ directory.
|
||||||
# Expects /src/cras to contain a cras checkout.
|
# Expects /src/cras to contain a cras checkout.
|
||||||
|
|
||||||
cd ${SRC}/adhd/cras/src/server/rust
|
|
||||||
export CARGO_BUILD_TARGET="x86_64-unknown-linux-gnu"
|
|
||||||
cargo build --release --target-dir=${WORK}/cargo_out
|
|
||||||
cp ${WORK}/cargo_out/${CARGO_BUILD_TARGET}/release/libcras_rust.a /usr/local/lib
|
|
||||||
|
|
||||||
cd ${SRC}/adhd
|
cd ${SRC}/adhd
|
||||||
|
|
||||||
|
#
|
||||||
|
# Build Rust code.
|
||||||
|
#
|
||||||
|
export CARGO_BUILD_TARGET="x86_64-unknown-linux-gnu"
|
||||||
|
cargo build --package=cras_rust --release --target-dir=${WORK}/cargo_out
|
||||||
|
cp ${WORK}/cargo_out/${CARGO_BUILD_TARGET}/release/libcras_rust.a /usr/local/lib
|
||||||
|
|
||||||
|
#
|
||||||
|
# Build C code.
|
||||||
|
#
|
||||||
|
|
||||||
# Set bazel options.
|
# Set bazel options.
|
||||||
# See also:
|
# See also:
|
||||||
# https://github.com/google/oss-fuzz/blob/master/infra/base-images/base-builder/bazel_build_fuzz_tests
|
# https://github.com/google/oss-fuzz/blob/master/infra/base-images/base-builder/bazel_build_fuzz_tests
|
||||||
|
|
Loading…
Reference in New Issue