Add a variable to handle extra CFLAGS values
Some packages don't install its headers in the default directory (e.g.: In Arch Linux libiberty and libn13 includes are installed) in their own subdirectory under /usr/include) and the build fails trying to find the headers. This patch will allow passing extra CFLAGS values without discarding the assignments made in the Makefile. The CFLAGS values in the Makefile are ignored, if defined directly in the make command line. Signed-off-by: Roger Zanoni <roger.zanoni@openbossa.org>
This commit is contained in:
parent
54f2cae2e6
commit
b42f539ed2
2 changed files with 2 additions and 0 deletions
|
@ -6,6 +6,7 @@ ifndef CFLAGS
|
||||||
CFLAGS = -MMD -O2 -Wall -g
|
CFLAGS = -MMD -O2 -Wall -g
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
CFLAGS += $(EXTRA_CFLAGS)
|
||||||
CFLAGS += -I$(abspath ../src)
|
CFLAGS += -I$(abspath ../src)
|
||||||
CFLAGS += -I$(abspath ../src/utils)
|
CFLAGS += -I$(abspath ../src/utils)
|
||||||
|
|
||||||
|
|
|
@ -10,6 +10,7 @@ export LIBDIR ?= /usr/local/lib/
|
||||||
export BINDIR ?= /usr/local/sbin/
|
export BINDIR ?= /usr/local/sbin/
|
||||||
PKG_CONFIG ?= pkg-config
|
PKG_CONFIG ?= pkg-config
|
||||||
|
|
||||||
|
CFLAGS += $(EXTRA_CFLAGS)
|
||||||
CFLAGS += -I$(abspath ../src)
|
CFLAGS += -I$(abspath ../src)
|
||||||
CFLAGS += -I$(abspath ../src/utils)
|
CFLAGS += -I$(abspath ../src/utils)
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue