From: Mike Frysinger Date: Fri, 16 Dec 2016 00:10:28 +0000 (-0500) Subject: change default CFLAGS settings into the default X-Git-Tag: v1.1~6^2 X-Git-Url: https://www.infradead.org/git/?a=commitdiff_plain;h=9c4f79fe0c9aa4d05f82c0f34cd4956bf76549e8;p=users%2Fsagi%2Fnvme-cli.git change default CFLAGS settings into the default The way compiler settings are appended to CFLAGS breaks custom flags that people are using to build. So if someone does: $ export CFLAGS='-O0 -ggdb' $ make The build will force -O2 instead. Shift these defaults into a default setting rather than always appending. Signed-off-by: Mike Frysinger --- diff --git a/Makefile b/Makefile index 33c71902..77945efa 100644 --- a/Makefile +++ b/Makefile @@ -1,4 +1,5 @@ -CFLAGS += -std=gnu99 -O2 -g -Wall -Werror +CFLAGS ?= -O2 -g -Wall -Werror +CFLAGS += -std=gnu99 CPPFLAGS += -D_GNU_SOURCE -D__CHECK_ENDIAN__ NVME = nvme INSTALL ?= install