diff options
Diffstat (limited to 'Makefile')
| -rw-r--r-- | Makefile | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..e269455 --- /dev/null +++ b/Makefile @@ -0,0 +1,22 @@ +CC = cc +CFLAGS = -Wall -Werror -Wextra -g +SRCS = ft_printf.c ft_putnbr.c ft_putstr.c ft_putchar.c ft_putunsigned.c ft_puthexlower.c ft_puthexupper.c ft_checkpadd.c +OBJS = $(SRCS:.c=.o) +NAME = libftprintf.a +DEPS = ft_printf.h + +%.o : %.c $(DEPS) + $(CC) -c -o $@ $< $(CFLAGS) + +$(NAME) : $(OBJS) + ar rcs $(NAME) $(OBJS) + +all: $(NAME) + +.PHONY: clean fclean re + +clean: + rm -f *.o +fclean: clean + rm -f $(NAME) +re: fclean all |
