-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
38 lines (28 loc) · 1.25 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
# **************************************************************************** #
# #
# ::: :::::::: #
# Makefile :+: :+: :+: #
# +:+ +:+ +:+ #
# By: ler-rech <[email protected]> +#+ +:+ +#+ #
# +#+#+#+#+#+ +#+ #
# Created: 2019/10/21 15:43:25 by ler-rech #+# #+# #
# Updated: 2021/01/13 15:56:31 by ler-rech ### ########.fr #
# #
# **************************************************************************** #
GCC = gcc -Wall -Wextra -Werror
NASM = nasm -f macho64
NAME = libasm.a
FILES_S = _ft_write.s _ft_strlen.s _ft_strcpy.s _ft_strcmp.s _ft_read.s _ft_strdup.s
FILES_O = $(FILES_S:.s=.o)
%.o: %.s
$(NASM) $<
all: $(NAME)
$(NAME): $(FILES_O)
ar rcs $(NAME) $(FILES_O)
test:
$(GCC) main.c $(NAME)
clean:
rm -f $(FILES_O)
fclean: clean
rm -f $(NAME)
re: fclean all