diff options
| author | Charles Cabergs <me@cacharle.xyz> | 2020-10-24 13:06:05 +0200 |
|---|---|---|
| committer | Charles Cabergs <me@cacharle.xyz> | 2020-10-24 13:06:05 +0200 |
| commit | 2baa67fd7ad31fe53ab21d257a104478e787fb62 (patch) | |
| tree | ac38bdf7aecd7056e1b7dfdd51f5403547966380 /philo_three | |
| parent | 47e1a7b4af69e1998182126310e42af83cf214ed (diff) | |
| download | philosophers-2baa67fd7ad31fe53ab21d257a104478e787fb62.tar.gz philosophers-2baa67fd7ad31fe53ab21d257a104478e787fb62.tar.bz2 philosophers-2baa67fd7ad31fe53ab21d257a104478e787fb62.zip | |
Replacing mutex stdout by semaphore in philo two, Compilation on Linux
Diffstat (limited to 'philo_three')
| -rw-r--r-- | philo_three/Makefile | 6 | ||||
| -rw-r--r-- | philo_three/src/philo_three.h | 3 |
2 files changed, 5 insertions, 4 deletions
diff --git a/philo_three/Makefile b/philo_three/Makefile index 3687670..32b3982 100644 --- a/philo_three/Makefile +++ b/philo_three/Makefile @@ -6,7 +6,7 @@ # By: cacharle <marvin@42.fr> +#+ +:+ +#+ # # +#+#+#+#+#+ +#+ # # Created: 2019/11/24 05:50:15 by cacharle #+# #+# # -# Updated: 2020/10/05 10:31:22 by cacharle ### ########.fr # +# Updated: 2020/10/24 13:02:46 by charles ### ########.fr # # # # **************************************************************************** # @@ -16,7 +16,7 @@ MAKE = make --no-print-directory COMMON_DIR = ../common CC = gcc -CCFLAGS = -I$(COMMON_DIR) -Wall -Wextra #-Werror +CCFLAGS = -I$(COMMON_DIR) -Wall -Wextra -Werror LDFLAGS = -lpthread -L$(COMMON_DIR) -lphilocommon NAME = philo_three @@ -33,7 +33,7 @@ prebuild: @mkdir -p $(OBJDIR) $(NAME): common_all $(OBJ) - $(CC) $(LDFLAGS) -o $@ $(OBJ) + $(CC) -o $@ $(OBJ) $(LDFLAGS) $(OBJDIR)/%.o: $(SRCDIR)/%.c $(CC) $(CCFLAGS) -c -o $@ $< diff --git a/philo_three/src/philo_three.h b/philo_three/src/philo_three.h index 1c1b8af..bb41343 100644 --- a/philo_three/src/philo_three.h +++ b/philo_three/src/philo_three.h @@ -6,7 +6,7 @@ /* By: cacharle <marvin@42.fr> +#+ +:+ +#+ */ /* +#+#+#+#+#+ +#+ */ /* Created: 2020/02/15 00:46:26 by cacharle #+# #+# */ -/* Updated: 2020/10/05 16:54:29 by cacharle ### ########.fr */ +/* Updated: 2020/10/24 13:02:33 by charles ### ########.fr */ /* */ /* ************************************************************************** */ @@ -14,6 +14,7 @@ # define PHILO_THREE_H # include <unistd.h> +# include <fcntl.h> # include <stdlib.h> # include <signal.h> # include <sys/time.h> |
