diff options
| author | Charles <sircharlesaze@gmail.com> | 2020-01-31 10:44:30 +0100 |
|---|---|---|
| committer | Charles <sircharlesaze@gmail.com> | 2020-02-02 22:12:42 +0100 |
| commit | ac0559db82bfef3b7ca3d976b1d7700ed2c1c1fc (patch) | |
| tree | 214d344c714bdf5b53d651dbd11fec9e0db283cb /test/Makefile | |
| parent | 9db52bc5ef545a3fa9973002e9a28a2ece68d029 (diff) | |
| download | libft-ac0559db82bfef3b7ca3d976b1d7700ed2c1c1fc.tar.gz libft-ac0559db82bfef3b7ca3d976b1d7700ed2c1c1fc.tar.bz2 libft-ac0559db82bfef3b7ca3d976b1d7700ed2c1c1fc.zip | |
hash table unit testing, norming
Diffstat (limited to 'test/Makefile')
| -rw-r--r-- | test/Makefile | 27 |
1 files changed, 21 insertions, 6 deletions
diff --git a/test/Makefile b/test/Makefile index 4d84321..f429a29 100644 --- a/test/Makefile +++ b/test/Makefile @@ -8,11 +8,12 @@ SRC_DIR = src INCLUDE_DIR = include CC = gcc -CCFLAGS = -I$(INCLUDE_DIR) -I$(UNITY_DIR)/include -I$(LIBFT_DIR)/include -Wall -Wextra -Werror +CCFLAGS = -I$(INCLUDE_DIR) -I$(UNITY_DIR)/include -I$(LIBFT_DIR)/include -Wall -Wextra #-Werror LDFLAGS = -L$(UNITY_DIR) -lunity -L$(LIBFT_DIR) -lft NAME = libft_test +INCLUDE = $(shell find $(INCLUDE_DIR) -type f -name "*.h") SRC = $(shell find $(SRC_DIR) -type f -name "*.c") OBJ = $(SRC:.c=.o) @@ -23,26 +24,40 @@ run: all @echo "Test: Running" @./$(NAME) -$(NAME): $(OBJ) +run_v: all + @echo "Test: Running" + @./$(NAME) -v + +$(NAME): libft_all $(OBJ) @echo "Test: Linking: $@" - @$(CC) -o $@ $^ $(LDFLAGS) + @$(CC) -o $@ $(OBJ) $(LDFLAGS) -%.o: %.c +%.o: %.c $(INCLUDE) $(LIBFT_SRC) @echo "Test: Compiling: $@" @$(CC) $(CCFLAGS) -c -o $@ $< -clean: unity_fclean +clean: @echo "Test: Removing object" @$(RM) $(OBJ) -fclean: +clean_dep: unity_fclean libft_fclean + +fclean: clean @echo "Test: Removing executable" @$(RM) $(NAME) re: fclean all +re_dep: clean_dep fclean all + unity_all: @$(MAKE) $(MAKE_ARGS) -s -C $(UNITY_DIR) all unity_fclean: @$(MAKE) $(MAKE_ARGS) -s -C $(UNITY_DIR) fclean + +libft_all: + @$(MAKE) $(MAKE_ARGS) -s -C $(LIBFT_DIR) all + +libft_fclean: + @$(MAKE) $(MAKE_ARGS) -s -C $(LIBFT_DIR) fclean |
