From a128f57e88e52c64d758030cff8d42fff7e673c3 Mon Sep 17 00:00:00 2001 From: Aaron Cook Date: Mon, 8 May 2023 10:00:58 -0500 Subject: [PATCH] Optimize build by default with debug option --- Makefile | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/Makefile b/Makefile index 3a7376d..7302347 100644 --- a/Makefile +++ b/Makefile @@ -1,5 +1,5 @@ CC=clang -CFLAGS=-g -Wall -MMD -pthread -D_XOPEN_SOURCE=700 -D_POSIX_C_SOURCE +CFLAGS=-Wall -MMD -pthread -D_XOPEN_SOURCE=700 -D_POSIX_C_SOURCE LDFLAGS=-lpthread -lncurses DIR_SRC=src @@ -11,7 +11,9 @@ TARGET=$(DIR_BIN)/bytenuts DEBUG ?= 0 ifeq ($(DEBUG), 1) - CFLAGS += -DDEBUG + CFLAGS += -g +else + CFLAGS += -O2 endif SRCS=$(wildcard $(DIR_SRC)/*.c)