aboutsummaryrefslogtreecommitdiff
path: root/philo_three
diff options
context:
space:
mode:
authorCharles Cabergs <me@cacharle.xyz>2021-01-08 14:35:53 +0100
committerCharles Cabergs <me@cacharle.xyz>2021-01-08 14:35:53 +0100
commitad7ed73c124c8fcda6629350307f0f4f41b87fe3 (patch)
tree5faf9809401b64fecffe709f20cc9bb980aa7406 /philo_three
parent907debbb7d1e7ccc4914805cfe4acbed92b82bcc (diff)
downloadphilosophers-ad7ed73c124c8fcda6629350307f0f4f41b87fe3.tar.gz
philosophers-ad7ed73c124c8fcda6629350307f0f4f41b87fe3.tar.bz2
philosophers-ad7ed73c124c8fcda6629350307f0f4f41b87fe3.zip
Updated Makefile, restructuring common files
Diffstat (limited to 'philo_three')
-rw-r--r--philo_three/Makefile7
1 files changed, 4 insertions, 3 deletions
diff --git a/philo_three/Makefile b/philo_three/Makefile
index 17c5b46..da20c9d 100644
--- a/philo_three/Makefile
+++ b/philo_three/Makefile
@@ -6,17 +6,18 @@
# By: cacharle <marvin@42.fr> +#+ +:+ +#+ #
# +#+#+#+#+#+ +#+ #
# Created: 2019/11/24 05:50:15 by cacharle #+# #+# #
-# Updated: 2021/01/01 16:28:33 by charles ### ########.fr #
+# Updated: 2021/01/08 14:32:09 by charles ### ########.fr #
# #
# **************************************************************************** #
RM = rm -f
+MKDIR = mkdir -p
MAKE = make --no-print-directory
COMMON_DIR = ../common
CC = gcc
-CCFLAGS = -I$(COMMON_DIR) -O2 -std=c99 -Wall -Wextra #-Werror
+CCFLAGS = -std=c99 -Wall -Wextra -Werror -O2 -I$(COMMON_DIR)/inc
LDFLAGS = -lpthread -L$(COMMON_DIR) -lphilocommon
NAME = philo_three
@@ -30,7 +31,7 @@ OBJ = $(SRC:$(SRCDIR)/%.c=$(OBJDIR)/%.o)
all: prebuild $(NAME)
prebuild:
- @mkdir -p $(OBJDIR)
+ $(MKDIR) $(OBJDIR)
$(NAME): common_all $(OBJ)
$(CC) -o $@ $(OBJ) $(LDFLAGS)