* export PROFILE

* install aflplusplusw

* no dot

* a
This commit is contained in:
Dongjia "toka" Zhang 2023-09-25 20:51:40 +02:00 committed by GitHub
parent c1eef33b5d
commit c1006c4d38
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 37 additions and 12 deletions

View File

@ -1,11 +1,24 @@
#!/bin/sh
#!/bin/bash
# cargo build --release
# PWD=$(pwd)
# export CC="$PWD/target/release/libafl_cc"
# export CXX="$PWD/target/release/libafl_cxx"
export CC=afl-clang-fast
export CXX=afl-clang-fast++
# Check if afl-clang-fast exists in PATH
if ! command -v afl-clang-fast &> /dev/null
then
echo "afl-clang-fast not found. Cloning and compiling AFLplusplus..."
git clone https://github.com/AFLplusplus/AFLplusplus.git
pushd AFLplusplus
make
popd
else
echo "afl-clang-fast already exists in PATH."
fi
export CC="$(pwd)/AFLplusplus/afl-clang-fast"
export CXX="$(pwd)/AFLplusplus/afl-clang-fast++"
curl -C - https://gitlab.gnome.org/GNOME/libxml2/-/archive/v2.9.14/libxml2-v2.9.14.tar.gz --output libxml2-v2.9.14.tar.gz
tar -xf ./libxml2-v2.9.14.tar.gz --transform s/libxml2-v2.9.14/libxml2/ || exit
cd ./libxml2/ || exit

View File

@ -1,11 +1,23 @@
#!/bin/sh
#!/bin/bash
# cargo build --release
# PWD=$(pwd)
# export CC="$PWD/target/release/libafl_cc"
# export CXX="$PWD/target/release/libafl_cxx"
export CC=afl-clang-fast
export CXX=afl-clang-fast++
# Check if afl-clang-fast exists in PATH
if ! command -v afl-clang-fast &> /dev/null
then
echo "afl-clang-fast not found. Cloning and compiling AFLplusplus..."
git clone https://github.com/AFLplusplus/AFLplusplus.git
pushd AFLplusplus
make
popd
else
echo "afl-clang-fast already exists in PATH."
fi
export CC="$(pwd)/AFLplusplus/afl-clang-fast"
export CXX="$(pwd)/AFLplusplus/afl-clang-fast++"
curl -C - https://gitlab.gnome.org/GNOME/libxml2/-/archive/v2.9.14/libxml2-v2.9.14.tar.gz --output libxml2-v2.9.14.tar.gz
tar -xf ./libxml2-v2.9.14.tar.gz --transform s/libxml2-v2.9.14/libxml2/ || exit
cd ./libxml2/ || exit

View File

@ -5,13 +5,13 @@ cd "$SCRIPT_DIR/.." || exit 1
# TODO: This should be rewritten in rust, a Makefile, or some platform-independent language
if [[ -z "${RUN_ON_CI}" ]]; then
fuzzers=$(find ./fuzzers -mindepth 1 -maxdepth 1 -type d)
backtrace_fuzzers=$(find ./fuzzers/backtrace_baby_fuzzers -mindepth 1 -maxdepth 1 -type d)
export PROFILE=dev
fuzzers=$(find ./fuzzers -mindepth 1 -maxdepth 1 -type d)
backtrace_fuzzers=$(find ./fuzzers/backtrace_baby_fuzzers -mindepth 1 -maxdepth 1 -type d)
else
cargo build -p build_and_test_fuzzers
fuzzers=$(cargo run -p build_and_test_fuzzers -- "remotes/origin/main" "HEAD^")
backtrace_fuzzers=""
cargo build -p build_and_test_fuzzers
fuzzers=$(cargo run -p build_and_test_fuzzers -- "remotes/origin/main" "HEAD^")
backtrace_fuzzers=""
export PROFILE=dev
fi
libafl=$(pwd)