-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
46 lines (36 loc) · 1.53 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
# **************************************************************************** #
# #
# ::: :::::::: #
# Makefile :+: :+: :+: #
# +:+ +:+ +:+ #
# By: ecortes- <[email protected]> +#+ +:+ +#+ #
# +#+#+#+#+#+ +#+ #
# Created: 2024/07/03 14:57:59 by ecortes- #+# #+# #
# Updated: 2024/07/03 15:00:10 by ecortes- ### ########.fr #
# #
# **************************************************************************** #
SRC_DIR = ./src
SRC = check_args.c main.c push.c reverse_rotate.c rotate.c swap.c utils.c utils2.c utils3.c order.c order2.c utils4.c
OBJS = $(addprefix $(SRC_DIR)/, $(SRC:.c=.o))
CC = gcc
CFLAGS = -Wall -Werror -Wextra -fsanitize=address -g3
AR = ar
ARFLAGS = rcs
RM = rm -rf
LIBFT_DIR = ./libft/
LIBFT_A = libft.a
LIBFT = -L$(LIBFT_DIR) $(LIBFT_DIR)$(LIBFT_A)
NAME = push_swap
all: $(NAME)
.SILENT: $(OBJS)
$(NAME): $(OBJS)
@make bonus -C $(LIBFT_DIR)
@gcc $(CFLAGS) $(OBJS) $(LIBFT) -o $(NAME)
clean:
$(RM) $(OBJS) $(LIBFT_A)
fclean: clean
@$(RM) $(NAME) $(B_NAME) $(OBJS)
@make -C $(LIBFT_DIR) fclean
re: fclean
@make all
.PHONY: all clean fclean re