From 540affb926afd91a1f4cacbe1ad4e27225d88a72 Mon Sep 17 00:00:00 2001 From: Florian Pritz Date: Wed, 14 Mar 2012 00:42:25 +0100 Subject: Makefile: preserve some flags even if $CFLAGS is set Signed-off-by: Florian Pritz --- Makefile | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index 5884b00..71fcfa0 100644 --- a/Makefile +++ b/Makefile @@ -4,7 +4,8 @@ BINDIR=/usr/bin LIBDIR=/usr/lib MY_LIBDIR=$(LIBDIR)/fb-client CC=cc -CFLAGS?=-O2 -std=c99 -Wall -Wextra -pedantic +CFLAGS?=-O2 +MY_CFLAGS=-std=c99 -Wall -Wextra -pedantic LIBCURL:=$(shell pkg-config --silence-errors --libs --cflags libcurl) ifdef LIBCURL @@ -19,7 +20,7 @@ fb: fb.in chmod 755 $@ fb-helper: fb-helper.c - $(CC) $(CFLAGS) $(LIBCURL) -DVERSION=\"$(VERSION)\" -o $@ $< + $(CC) $(MY_CFLAGS) $(CFLAGS) $(LIBCURL) -DVERSION=\"$(VERSION)\" -o $@ $< clean: rm -f fb fb-helper -- cgit v1.2.3-24-g4f1b