diff options
| author | Charles <sircharlesaze@gmail.com> | 2020-02-10 00:34:47 +0100 |
|---|---|---|
| committer | Charles <sircharlesaze@gmail.com> | 2020-02-10 01:30:53 +0100 |
| commit | 1a7c6c5a0ed9a5aae1fe45c3af335c120c2dc642 (patch) | |
| tree | 965aa21be5411d2a9e1156013efc1980bca29f90 /common/Makefile | |
| parent | dfbafce6506fe5c47b0e60289a9d4629e502c9ac (diff) | |
| download | philosophers-1a7c6c5a0ed9a5aae1fe45c3af335c120c2dc642.tar.gz philosophers-1a7c6c5a0ed9a5aae1fe45c3af335c120c2dc642.tar.bz2 philosophers-1a7c6c5a0ed9a5aae1fe45c3af335c120c2dc642.zip | |
WIP: philo one
Diffstat (limited to 'common/Makefile')
| -rw-r--r-- | common/Makefile | 38 |
1 files changed, 38 insertions, 0 deletions
diff --git a/common/Makefile b/common/Makefile new file mode 100644 index 0000000..cf3089c --- /dev/null +++ b/common/Makefile @@ -0,0 +1,38 @@ +# **************************************************************************** # +# # +# ::: :::::::: # +# Makefile :+: :+: :+: # +# +:+ +:+ +:+ # +# By: cacharle <marvin@42.fr> +#+ +:+ +#+ # +# +#+#+#+#+#+ +#+ # +# Created: 2020/02/09 22:39:08 by cacharle #+# #+# # +# Updated: 2020/02/09 23:57:34 by cacharle ### ########.fr # +# # +# **************************************************************************** # + +LIB = ar rcs +RM = rm -rf + +CC = gcc +CCFLAGS = -Wall -Wextra -Werror + +NAME = libphilocommon.a + +SRC = $(shell find . -type f -name "*.c") +OBJ = $(SRC:.c=.o) + +all: $(NAME) + +$(NAME): $(OBJ) + $(LIB) $(NAME) $(OBJ) + +%.o: %.c + $(CC) $(CCFLAGS) -c -o $@ $< + +clean: + $(RM) $(OBJ) + +fclean: clean + $(RM) $(NAME) + +re: fclean all |
