From 9829c5eb955c118db3923a8626addd7a19319f8a Mon Sep 17 00:00:00 2001 From: van Hauser Date: Mon, 30 Dec 2019 15:14:00 +0100 Subject: really ensure that all .test files are removed after they are not needed anymore --- llvm_mode/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'llvm_mode') diff --git a/llvm_mode/Makefile b/llvm_mode/Makefile index 5a836a0e..0e3da147 100644 --- a/llvm_mode/Makefile +++ b/llvm_mode/Makefile @@ -115,7 +115,7 @@ endif CLANGVER = $(shell $(CC) --version | sed -E -ne '/^.*version\ ([0-9]\.[0-9]\.[0-9]).*/s//\1/p') -ifeq "$(shell echo '\#include @\#include @int main() { int _id = shmget(IPC_PRIVATE, 65536, IPC_CREAT | IPC_EXCL | 0600); shmctl(_id, IPC_RMID, 0); return 0;}' | tr @ '\n' | $(CC) -x c - -o .test2 2>/dev/null && echo 1 || echo 0 )" "1" +ifeq "$(shell echo '\#include @\#include @int main() { int _id = shmget(IPC_PRIVATE, 65536, IPC_CREAT | IPC_EXCL | 0600); shmctl(_id, IPC_RMID, 0); return 0;}' | tr @ '\n' | $(CC) -x c - -o .test2 2>/dev/null && echo 1 || echo 0 ; rm -f .test2 )" "1" SHMAT_OK=1 else SHMAT_OK=0 -- cgit 1.4.1 From 842cd9dec3c4c83d660d96dcdb3f5cf0c6e6f4fb Mon Sep 17 00:00:00 2001 From: van Hauser Date: Tue, 31 Dec 2019 12:52:10 +0100 Subject: final touches before 2.60 --- Makefile | 1 - docs/ChangeLog | 2 +- llvm_mode/afl-clang-fast.c | 18 ++++++++++++++++-- 3 files changed, 17 insertions(+), 4 deletions(-) (limited to 'llvm_mode') diff --git a/Makefile b/Makefile index 36f6d4c5..f287a3a0 100644 --- a/Makefile +++ b/Makefile @@ -326,7 +326,6 @@ clean: $(MAKE) -C qemu_mode/unsigaction clean $(MAKE) -C qemu_mode/libcompcov clean $(MAKE) -C src/third_party/libradamsa/ clean - -test -e unicorn_mode/unicorn/Makefile && $(MAKE) -C unicorn_mode/unicorn clean -rm -rf unicorn_mode/unicorn distrib: all radamsa diff --git a/docs/ChangeLog b/docs/ChangeLog index 8492d7fd..a5e3efcd 100644 --- a/docs/ChangeLog +++ b/docs/ChangeLog @@ -23,7 +23,7 @@ Version ++2.59d (develop): - added preeny's desock_dup ld_preload library as ./experimental/socket_fuzzing for network fuzzing - added AFL_AS_FORCE_INSTRUMENT environment variable for afl-as - this is - for retrorewrite project + for the retrorewrite project - we now set QEMU_SET_ENV from AFL_PRELOAD when qemu_mode is used diff --git a/llvm_mode/afl-clang-fast.c b/llvm_mode/afl-clang-fast.c index fe91a01b..a1da83b2 100644 --- a/llvm_mode/afl-clang-fast.c +++ b/llvm_mode/afl-clang-fast.c @@ -49,7 +49,11 @@ static void find_obj(u8* argv0) { if (afl_path) { +#ifdef __ANDROID__ + tmp = alloc_printf("%s/afl-llvm-rt.so", afl_path); +#else tmp = alloc_printf("%s/afl-llvm-rt.o", afl_path); +#endif if (!access(tmp, R_OK)) { @@ -73,7 +77,11 @@ static void find_obj(u8* argv0) { dir = ck_strdup(argv0); *slash = '/'; +#ifdef __ANDROID__ + tmp = alloc_printf("%s/afl-llvm-rt.so", afl_path); +#else tmp = alloc_printf("%s/afl-llvm-rt.o", dir); +#endif if (!access(tmp, R_OK)) { @@ -88,8 +96,14 @@ static void find_obj(u8* argv0) { } +#ifdef __ANDROID__ + if (!access(AFL_PATH "/afl-llvm-rt.so", R_OK)) { + +#else if (!access(AFL_PATH "/afl-llvm-rt.o", R_OK)) { +#endif + obj_path = AFL_PATH; return; @@ -358,7 +372,7 @@ static void edit_params(u32 argc, char** argv) { } - //#ifndef __ANDROID__ // not sure, we might need these ifdefs for Android +#ifndef __ANDROID__ switch (bit_mode) { case 0: @@ -383,7 +397,7 @@ static void edit_params(u32 argc, char** argv) { } - //#endif +#endif } -- cgit 1.4.1 From 3827b912c7090314bb011fe6c1ccfaf0d33fc678 Mon Sep 17 00:00:00 2001 From: van Hauser Date: Thu, 2 Jan 2020 08:39:29 +0100 Subject: compile fixes --- docs/ChangeLog | 5 +++-- libdislocator/Makefile | 4 ++-- libtokencap/Makefile | 4 ++-- llvm_mode/Makefile | 2 +- 4 files changed, 8 insertions(+), 7 deletions(-) (limited to 'llvm_mode') diff --git a/docs/ChangeLog b/docs/ChangeLog index 745f2587..d3b27e35 100644 --- a/docs/ChangeLog +++ b/docs/ChangeLog @@ -17,8 +17,9 @@ sending a mail to . Version ++2.60d (develop): -------------------------- - - exciting new stuff is coming up :-) - - all the best for the new year! + - afl-fuzz: + - now prints the real python version support compiled in + - added fix from Debian project to compile libdislocator and libtokencap -------------------------- diff --git a/libdislocator/Makefile b/libdislocator/Makefile index dae187e5..279667a1 100644 --- a/libdislocator/Makefile +++ b/libdislocator/Makefile @@ -18,8 +18,8 @@ HELPER_PATH = $(PREFIX)/lib/afl VERSION = $(shell grep '^\#define VERSION ' ../config.h | cut -d '"' -f2) -CFLAGS ?= -O3 -funroll-loops -I ../include/ -CFLAGS += -Wall -D_FORTIFY_SOURCE=2 -g -Wno-pointer-sign +CFLAGS ?= -O3 -funroll-loops +CFLAGS += -I ../include/ -Wall -D_FORTIFY_SOURCE=2 -g -Wno-pointer-sign ifdef USEHUGEPAGE CFLAGS += -DUSEHUGEPAGE diff --git a/libtokencap/Makefile b/libtokencap/Makefile index 3ecbf471..804f03c2 100644 --- a/libtokencap/Makefile +++ b/libtokencap/Makefile @@ -18,8 +18,8 @@ HELPER_PATH = $(PREFIX)/lib/afl VERSION = $(shell grep '^\#define VERSION ' ../config.h | cut -d '"' -f2) -CFLAGS ?= -O3 -funroll-loops -I ../include/ -CFLAGS += -Wall -D_FORTIFY_SOURCE=2 -g -Wno-pointer-sign +CFLAGS ?= -O3 -funroll-loops +CFLAGS += -I ../include/ -Wall -D_FORTIFY_SOURCE=2 -g -Wno-pointer-sign ifeq "$(shell uname)" "Linux" TARGETS = libtokencap.so diff --git a/llvm_mode/Makefile b/llvm_mode/Makefile index 0e3da147..5bb1aef2 100644 --- a/llvm_mode/Makefile +++ b/llvm_mode/Makefile @@ -261,5 +261,5 @@ vpath % .. ln -sf afl-clang-fast.8 ../afl-clang-fast++.8 clean: - rm -f *.o *.so *~ a.out core core.[1-9][0-9]* .test2 test-instr .test-instr0 .test-instr1 + rm -f *.o *.so *~ a.out core core.[1-9][0-9]* .test2 test-instr .test-instr0 .test-instr1 afl-llvm-pass.dwo rm -f $(PROGS) ../afl-clang-fast++ ../afl-clang-fast*.8 -- cgit 1.4.1