-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
executable file
·34 lines (25 loc) · 1.05 KB
/
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
NASMFLAGS = -f elf64
CFLAGS = -O2
CDEBUGFLAGS = -g -fsanitize=address -fsanitize=alignment -fsanitize=bool -fsanitize=bounds -fsanitize=enum -fsanitize=float-cast-overflow -fsanitize=float-divide-by-zero -fsanitize=integer-divide-by-zero -fsanitize=leak -fsanitize=nonnull-attribute -fsanitize=null -fsanitize=object-size -fsanitize=return -fsanitize=returns-nonnull-attribute -fsanitize=shift -fsanitize=signed-integer-overflow -fsanitize=undefined -fsanitize=unreachable -fsanitize=vla-bound -fsanitize=vptr
CWARNING = -Wall
all:
vector:
gcc -c -o bin/vector.o src/vector.c
node:
gcc -c -o bin/node.o src/node.c
tree:
gcc -c -o bin/tree.o src/tree.c
lexic:
gcc -c -o bin/lexical_analyzer.o src/lexical_analyzer.c
syntax:
gcc -c -o bin/syntax_analyzer.o src/syntax_analyzer.c
lib:
nasm $(NASMFLAGS) stdoors/stdoors.asm -o stdoors/stdoors.o
ld stdoors/stdoors.o -o stdoors/stdoors
rm stdoors/stdoors.o
compiler: lib
g++ -o udc main.cpp
mv udc bin
debug:
g++ $(CDEBUGFLAGS) -o udc_debug main.cpp
mv udc_debug bin