diff options
author | Mattias Andrée <maandree@operamail.com> | 2014-05-28 02:31:10 +0200 |
---|---|---|
committer | Mattias Andrée <maandree@operamail.com> | 2014-05-28 02:31:10 +0200 |
commit | 48de208b5e29d9d43d68cf8a1392a673616d0c6a (patch) | |
tree | 533ecc8576ffb8684ca359cb89e1f9c5976fc7cc | |
parent | on configuring (diff) | |
download | libgamma-48de208b5e29d9d43d68cf8a1392a673616d0c6a.tar.gz libgamma-48de208b5e29d9d43d68cf8a1392a673616d0c6a.tar.bz2 libgamma-48de208b5e29d9d43d68cf8a1392a673616d0c6a.tar.xz |
fix order things in the makefile
Signed-off-by: Mattias Andrée <maandree@operamail.com>
Diffstat (limited to '')
-rw-r--r-- | Makefile | 43 |
1 files changed, 21 insertions, 22 deletions
@@ -25,13 +25,6 @@ LICENSEDIR ?= $(DATADIR)/licenses PKGNAME ?= libgamma -# Optimisation level (and debug flags.) -ifeq ($(DEBUG),y) -OPTIMISE = -Og -g -else -OPTIMISE = -Ofast -endif - # Enabled warnings. WARN = -Wall -Wextra -pedantic -Wdouble-promotion -Wformat=2 -Winit-self \ -Wmissing-include-dirs -Wtrampolines -Wfloat-equal -Wshadow \ @@ -48,20 +41,6 @@ WARN = -Wall -Wextra -pedantic -Wdouble-promotion -Wformat=2 -Winit-self \ # The C standard used in the code. STD = c99 -# C compiler debug flags. -DEBUG_FLAGS = -ifeq ($(DEBUG),y) -DEBUG_FLAGS += -D'DEBUG' -endif - -# Options for the C compiler for the test. -TEST_FLAGS = $(OPTIMISE) $(WARN) -std=$(STD) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) \ - -ftree-vrp -fstrict-aliasing -fipa-pure-const -fstack-usage \ - -fstrict-overflow -funsafe-loop-optimizations -fno-builtin - -# Options for the C compiler for the library. -LIB_FLAGS = $(TEST_FLAGS) $(DEBUG_FLAGS) $(DEFINITIONS) -DLIBGAMMA_CONFIG_H - # Library linking flags for the linker. LIBS_LD = # Library linking flags for the C compiler. @@ -78,10 +57,30 @@ LIB_MAJOR = 1 LIB_MINOR = 0 LIB_VERSION = $(LIB_MAJOR).$(LIB_MINOR) - # Include configurations from `./configure`. include .config.mk +# Optimisation level (and debug flags.) +ifeq ($(DEBUG),y) +OPTIMISE = -Og -g +else +OPTIMISE = -Ofast +endif + +# C compiler debug flags. +DEBUG_FLAGS = +ifeq ($(DEBUG),y) +DEBUG_FLAGS += -D'DEBUG' +endif + +# Options for the C compiler for the test. +TEST_FLAGS = $(OPTIMISE) $(WARN) -std=$(STD) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) \ + -ftree-vrp -fstrict-aliasing -fipa-pure-const -fstack-usage \ + -fstrict-overflow -funsafe-loop-optimizations -fno-builtin + +# Options for the C compiler for the library. +LIB_FLAGS = $(TEST_FLAGS) $(DEBUG_FLAGS) $(DEFINITIONS) -DLIBGAMMA_CONFIG_H + # Build rules. |