-
Notifications
You must be signed in to change notification settings - Fork 7
/
Makefile
37 lines (27 loc) · 977 Bytes
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
CC_x64 := gcc
STRIP := strip
OPTIONS := -O3 -I include -ldl
OBJECTS := procmem.o utils.o
all: apollon-all-x64 apollon-selective-x64
apollon-all-x64: $(OBJECTS) apollon-all-x64.o
$(CC_x64) $^ -o dist/$@ $(OPTIONS)
$(STRIP) --strip-unneeded dist/$@
apollon-selective-x64: $(OBJECTS) apollon-selective-x64.o
$(CC_x64) $^ -o dist/$@ $(OPTIONS)
$(STRIP) --strip-unneeded dist/$@
apollon-selective-x64.o: src/apollon.c shellcode-selective.bin
$(CC_x64) -c $< -o $@ $(OPTIONS)
apollon-all-x64.o: src/apollon.c shellcode-all.bin
$(CC_x64) -D FILTER_ALL -c $< -o $@ $(OPTIONS)
shellcode-selective.bin: src/filter-selective.asm
nasm $< -o $@ -f bin
python3 generate-header.py $@
shellcode-all.bin: src/filter-all.asm
nasm $< -o $@ -f bin
python3 generate-header.py $@
procmem.o: src/procmem.c include/procmem.h
$(CC_x64) -c $< -o $@ $(OPTIONS)
utils.o: src/utils.c include/utils.h
$(CC_x64) -c $< -o $@ $(OPTIONS)
clean:
rm -f dist/* *.o *.bin include/shellcode.h