Here is my makefile:
NAME = libftprintf.a
SRCS = ft_printf.c \
ft_hexadecimal_fd.c \
ft_putchar_fd.c \
ft_putnbr_fd.c \
ft_putstr_fd.c
OBJS = $(SRCS:.c=.o)
CC = gcc
FLAGS = -Wall -Werror -Wextra
all: $(NAME)
$(NAME): $(OBJS)
ar rcs $(NAME) $(OBJS)
%.o: %.c
$(CC) $(FLAGS) -c $<
clean:
rm -f $(OBJS)
fclean: clean
rm -f $(NAME)
re: fclean $(NAME)
.PHONY: all clean fclean re
I was expecting to be able to execute ./libftprintf.a to run my program but instead i get the following: zsh: permission denied: ./libftprintf.a