about summary refs log tree commit diff
path: root/utils/afl_frida/GNUmakefile
blob: 8b56415be6b845e0e2dbf76c9f47e2463b5fe422 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
ifdef DEBUG
  OPT=-O0 -D_DEBUG=\"1\"
else
  OPT=-O3 -funroll-loops
endif

all:	afl-frida libtestinstr.so

libfrida-gum.a:
	@echo Download and extract frida-gum-devkit-VERSION-PLATFORM.tar.xz for your platform from https://github.com/frida/frida/releases/latest
	@exit 1
	
afl-frida:	afl-frida.c libfrida-gum.a
	$(CC) -g $(OPT) -o afl-frida -Wno-format -Wno-pointer-sign -I. -fpermissive -fPIC afl-frida.c ../../afl-compiler-rt.o libfrida-gum.a -ldl -lresolv -pthread

libtestinstr.so:        libtestinstr.c
	$(CC) -g -O0 -fPIC -o libtestinstr.so -shared libtestinstr.c

clean:
	rm -f afl-frida *~ core *.o libtestinstr.so

deepclean: clean
	rm -f libfrida-gum.a frida-gum*