-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
67 lines (53 loc) · 1.67 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
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
# **************************************************************************** #
# #
# ::: :::::::: #
# Makefile :+: :+: :+: #
# +:+ +:+ +:+ #
# By: fvieira <[email protected]> +#+ +:+ +#+ #
# +#+#+#+#+#+ +#+ #
# Created: 2023/01/23 17:21:26 by fvieira #+# #+# #
# Updated: 2023/03/30 22:33:16 by fvieira ### ########.fr #
# #
# **************************************************************************** #
NAME = minishell
CC = cc
CFLAGS = -Werror -Wall -Wextra -fsanitize=address
LIBFT = ./libft/libft.a
SRC = main.c \
set_new_env.c \
parser.c \
append.c \
executables.c \
delimit.c \
echo.c \
path_related.c \
sanitize.c \
ft_export.c \
pelicaseaspas.c \
split.c \
input_errors.c \
pipe.c \
dollarsign.c \
unset_export_surplus.c \
dollarexport.c \
env.c \
environment_utils.c
OBJ = $(SRC:.c=.o)
all: $(NAME)
$(NAME): $(OBJ)
$(MAKE) --no-print-directory -C ./libft
echo "./minishell created"
$(CC) $(CFLAGS) $(OBJ) -lreadline $(LIBFT) -o $(NAME)
clean:
$(MAKE) clean -C ./libft
rm -f $(OBJ)
echo "OBJ deleted"
fclean: clean
$(MAKE) fclean -C ./libft
rm -f $(NAME)
echo "$(NAME) deleted"
re: fclean all
run: re
./minishell
.SILENT:
.PHONY: all, clean, fclean, re