summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJozanLeClerc <bousset.rudy@gmail.com>2020-08-01 21:14:17 +0200
committerJozanLeClerc <bousset.rudy@gmail.com>2020-08-01 21:14:17 +0200
commitb776f92ee534e42e22175e4f2bcccec83d9cfcc2 (patch)
treeffae7f13009958680bd63a2ed3cc0bfa90f3f424
parentexport first part is working fine (diff)
download42-minishell-b776f92ee534e42e22175e4f2bcccec83d9cfcc2.tar.gz
42-minishell-b776f92ee534e42e22175e4f2bcccec83d9cfcc2.tar.bz2
42-minishell-b776f92ee534e42e22175e4f2bcccec83d9cfcc2.tar.xz
42-minishell-b776f92ee534e42e22175e4f2bcccec83d9cfcc2.tar.zst
42-minishell-b776f92ee534e42e22175e4f2bcccec83d9cfcc2.zip
Makefile update
-rw-r--r--Makefile9
1 files changed, 9 insertions, 0 deletions
diff --git a/Makefile b/Makefile
index cd96f76..23115fa 100644
--- a/Makefile
+++ b/Makefile
@@ -3,6 +3,7 @@ default: all
#--------------------------------- SHELL --------------------------------------#
#==============================================================================#
SHELL := /bin/sh
+OS = $(shell uname)
#==============================================================================#
#------------------------------ DIRECTORIES -----------------------------------#
#==============================================================================#
@@ -71,7 +72,15 @@ LFT_SRCS = $(shell find ${LFT_SRCS_DIR} -name "*.c")
#==============================================================================#
#-------------------------------- COMPILER ------------------------------------#
#==============================================================================#
+ifeq (${OS}, FreeBSD)
+CC = /usr/bin/cc
+endif
+ifeq (${OS}, Linux)
+CC = /usr/bin/clang-9
+endif
+ifeq (${OS}, Darwin)
CC = clang
+endif
CFLAGS = -std=c89
CFLAGS += -Wall
CFLAGS += -Wextra