mirror of
https://github.com/AFLplusplus/AFLplusplus.git
synced 2025-06-20 05:23:43 +00:00
fix qemu sigunaction tests
This commit is contained in:
@ -12,19 +12,19 @@
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
.POSIX:
|
||||
|
||||
_UNIQ=_QINU_
|
||||
|
||||
TARGETCANDIDATES=unsigaction.so
|
||||
_TARGETS=$(_UNIQ)$(AFL_NO_X86)$(_UNIQ)
|
||||
__TARGETS=$(_TARGETS:$(_UNIQ)1$(_UNIQ)=)
|
||||
TARGETS=$(__TARGETS:$(_UNIQ)$(_UNIQ)=$(TARGETCANDIDATES))
|
||||
TARGETS=unsigaction.so unsigaction32.so unsigaction64.so
|
||||
|
||||
all: $(TARGETS)
|
||||
|
||||
unsigaction.so: unsigaction.c
|
||||
@if $(CC) -fPIC -shared unsigaction.c -o unsigaction.so 2>/dev/null ; then echo "unsigaction build success"; else echo "unsigaction build failure (that's fine)"; fi
|
||||
|
||||
unsigaction32.so: unsigaction.c
|
||||
@if $(CC) -fPIC -m32 -shared unsigaction.c -o unsigaction32.so 2>/dev/null ; then echo "unsigaction32 build success"; else echo "unsigaction32 build failure (that's fine)"; fi
|
||||
|
||||
unsigaction64.so: unsigaction.c
|
||||
@if $(CC) -fPIC -m64 -shared unsigaction.c -o unsigaction64.so 2>/dev/null ; then echo "unsigaction64 build success"; else echo "unsigaction64 build failure (that's fine)"; fi
|
||||
|
||||
clean:
|
||||
rm -f unsigaction.so
|
||||
|
@ -165,11 +165,8 @@ test -e ../afl-qemu-trace && {
|
||||
CODE=1
|
||||
}
|
||||
} || {
|
||||
echo CUT------------------------------------------------------------------CUT
|
||||
cat errors
|
||||
echo CUT------------------------------------------------------------------CUT
|
||||
$ECHO "$RED[!] cannot compile test program (32 bit) for unsigaction library"
|
||||
CODE=1
|
||||
$ECHO "$YELLOW[-] cannot compile test program (32 bit) for unsigaction library"
|
||||
INCOMPLETE=1
|
||||
}
|
||||
} || {
|
||||
$ECHO "$YELLOW[-] we cannot test qemu_mode unsigaction library (32 bit) because it is not present"
|
||||
@ -194,11 +191,8 @@ test -e ../afl-qemu-trace && {
|
||||
}
|
||||
unset LD_PRELOAD
|
||||
} || {
|
||||
echo CUT------------------------------------------------------------------CUT
|
||||
cat errors
|
||||
echo CUT------------------------------------------------------------------CUT
|
||||
$ECHO "$RED[!] cannot compile test program (64 bit) for unsigaction library"
|
||||
CODE=1
|
||||
$ECHO "$YELLOW[-] cannot compile test program (64 bit) for unsigaction library"
|
||||
INCOMPLETE=1
|
||||
}
|
||||
} || {
|
||||
$ECHO "$YELLOW[-] we cannot test qemu_mode unsigaction library (64 bit) because it is not present"
|
||||
|
@ -217,7 +217,9 @@ cd ../samples/python_simple || echo "Cannot cd"
|
||||
|
||||
# Run afl-showmap on the sample application. If anything comes out then it must have worked!
|
||||
unset AFL_INST_RATIO
|
||||
echo 0 | ../../../afl-showmap -U -m none -t 2000 -q -o ./.test-instr0 -- $PYTHONBIN ./simple_test_harness.py ./sample_inputs/sample1.bin || echo "Showmap"
|
||||
pwd
|
||||
echo "echo 0 | ../../../afl-showmap -U -m none -t 2000 -o ./.test-instr0 -- $PYTHONBIN ./simple_test_harness.py ./sample_inputs/sample1.bin"
|
||||
echo 0 | ../../../afl-showmap -U -m none -t 2000 -o ./.test-instr0 -- $PYTHONBIN ./simple_test_harness.py ./sample_inputs/sample1.bin || echo "Showmap"
|
||||
|
||||
if [ -s ./.test-instr0 ]
|
||||
then
|
||||
|
Reference in New Issue
Block a user