diff --git a/BUILD_TARGET.md b/BUILD_TARGET.md index e8e6e78..af95373 100644 --- a/BUILD_TARGET.md +++ b/BUILD_TARGET.md @@ -22,12 +22,12 @@ cd workdir wget http://ftpmirror.gnu.org/binutils/binutils-2.34.tar.xz # or curl -O http://ftpmirror.gnu.org/binutils/binutils-2.34.tar.xz tar xf binutils-2.34.tar.xz -mkdir build # Create a build dir ``` ## 3) Build bitcode file using gclang ```bash cd binutils-2.34 +sudo apt install texinfo CC=gclang CXX=gclang++ CFLAGS="-fPIC" ./configure --with-pic make -j$(nprocs) # Build in parallel cd binutils/ diff --git a/build/install_tools.sh b/build/install_tools.sh index 293fe32..b4e89db 100755 --- a/build/install_tools.sh +++ b/build/install_tools.sh @@ -3,8 +3,8 @@ set -euxo pipefail #wllvm and gllvm -pip3 install --upgrade pip==9.0.3 -pip3 install wllvm +pip3 install --upgrade pip==9.0.3 --user +pip3 install wllvm --user mkdir ${HOME}/go go get github.com/SRI-CSL/gllvm/cmd/... diff --git a/tests/test.sh b/tests/test.sh index 22b195c..7ddd933 100755 --- a/tests/test.sh +++ b/tests/test.sh @@ -24,7 +24,7 @@ fi envs="BUILD_TYPE=${BUILD_TYPE} LOG_TYPE=${LOG_TYPE}" -fuzzer="../angora_fuzzer" +fuzzer="../bin/fuzzer" input="./input" output="./output" diff --git a/tools/compile_bc.py b/tools/compile_bc.py index d9fccdb..8c65f77 100644 --- a/tools/compile_bc.py +++ b/tools/compile_bc.py @@ -1,4 +1,4 @@ -#!/usr/bin/env python +#!/usr/bin/env python3 import sys import os from pathlib import Path @@ -43,7 +43,7 @@ def build_pipeline(bc_file, target_flags="@@", profiling_input_dir="in", is_cpp= run_cmd(f"opt -load {ID_ASSIGNER_PATH} -idassign -idassign-emit-cfg \ -idassign-cfg-file cfg.dat {name}.fast.ll") #8) Prune targets - run_cmd(f"python {PRUNE_SCRIPT_PATH} {targets_file} {name}.diff cmp.map {profiling_input_dir} ./{name}.track {target_flags} > targets.pruned.json") + run_cmd(f"python3.8 {PRUNE_SCRIPT_PATH} {targets_file} {name}.diff cmp.map {profiling_input_dir} ./{name}.track {target_flags} > targets.pruned.json") # Print fuzzing command print("You can now run your target application (with SanOpt enabled) using:")