-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
99 lines (89 loc) · 1.66 KB
/
Makefile
File metadata and controls
99 lines (89 loc) · 1.66 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
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
NAME = pathfinder
INC = pathfinder.h
INCI = inc/pathfinder.h
SRC = main.c\
mx_file_to_str.c\
mx_split.c\
mx_parser.c\
mx_atoi.c\
mx_printerr.c\
mx_rec_struct.c\
mx_isdigit.c\
mx_get_index.c\
mx_m_distance.c\
mx_m_floyd.c\
mx_floyd.c\
mx_printmatrix.c\
mx_line1_is_invalid.c\
mx_usage.c\
mx_file_does_not_exist.c\
mx_file_is_empty.c\
mx_back_path.c\
mx_int_print.c\
mx_ret_trip_output.c\
mx_find_all_paths.c\
mx_isalpha.c
SRCS = $(addprefix src/, main.c\
mx_file_to_str.c\
mx_split.c\
mx_parser.c\
mx_atoi.c\
mx_printerr.c\
mx_rec_struct.c\
mx_isdigit.c\
mx_get_index.c\
mx_m_distance.c\
mx_m_floyd.c\
mx_floyd.c\
mx_printmatrix.c\
mx_line1_is_invalid.c\
mx_usage.c\
mx_file_does_not_exist.c\
mx_file_is_empty.c\
mx_back_path.c\
mx_int_print.c\
mx_ret_trip_output.c\
mx_find_all_paths.c\
mx_isalpha.c)
OBJ = main.o\
mx_file_to_str.o\
mx_split.o\
mx_parser.o\
mx_atoi.o\
mx_printerr.o\
mx_rec_struct.o\
mx_isdigit.o\
mx_get_index.o\
mx_m_distance.o\
mx_m_floyd.o\
mx_floyd.o\
mx_printmatrix.o\
mx_line1_is_invalid.o\
mx_usage.o\
mx_file_does_not_exist.o\
mx_file_is_empty.o\
mx_back_path.o\
mx_int_print.o\
mx_ret_trip_output.o\
mx_find_all_paths.o\
mx_isalpha.o
CFLAGS = -std=c11 -Wall -Wextra -Werror -Wpedantic
all: install clean
install:
@make -C libmx
@cp $(SRCS) .
@cp $(INCI) .
@clang $(CFLAGS) -c $(SRC) -I $(INC)
@mkdir -p obj
@clang $(CFLAGS) libmx/libmx.a $(OBJ) -o $(NAME)
@mv $(OBJ) ./obj
uninstall:
@make uninstall -C libmx
@rm -rf $(NAME)
clean:
@make clean -C libmx
@rm -rf $(INC)
@rm -rf $(SRC)
@rm -rf $(OBJ)
@rm -rf ./obj
reinstall: uninstall all