aboutsummaryrefslogtreecommitdiff
path: root/c09/ex01/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'c09/ex01/Makefile')
-rw-r--r--c09/ex01/Makefile28
1 files changed, 28 insertions, 0 deletions
diff --git a/c09/ex01/Makefile b/c09/ex01/Makefile
new file mode 100644
index 0000000..0fec395
--- /dev/null
+++ b/c09/ex01/Makefile
@@ -0,0 +1,28 @@
+SRCDIR = srcs
+SRC = ft_putchar.c ft_swap.c ft_putstr.c ft_strlen.c ft_strcmp.c
+OBJ = $(SRC:.c = .o)
+INCLUDEDIR = includes
+INCLUDES = ft.h
+CC = gcc
+CCFLAGS = -Wall -Wextra -Werror
+OUT = libft.a
+
+all: OUT
+.PHONY: all
+
+$(OUT): $(OBJ)
+ ar -crs $(OBJ)
+
+$(OBJ): %.o: %.c
+ $(CC) $(CCFLAGS) -c $< -o $@
+
+.PHONY: clean
+clean:
+ rm -f srcs/*.o
+
+.PHONY: fclean
+fclean: clean
+ rm $(OUT)
+
+.PHONY: re
+re: fclean all