From 90b089d7fd6454771b23fdcebb78d3b1a469c3f5 Mon Sep 17 00:00:00 2001 From: John Mark Bell Date: Mon, 7 Apr 2008 02:11:49 +0000 Subject: Rework buildsystem so that it no longer calls make recursively and rebuilds the testcases when the library changes. svn path=/trunk/hubbub/; revision=4077 --- Makefile | 53 ++++++++++++++++++++++++++++++----------------------- 1 file changed, 30 insertions(+), 23 deletions(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index db5a35b..cdac442 100644 --- a/Makefile +++ b/Makefile @@ -1,34 +1,41 @@ # Toolchain definitions for building on the destination platform -export CC = gcc -export AR = ar -export LD = gcc +CC := gcc +AR := ar +LD := gcc -export CP = cp -export RM = rm -export MKDIR = mkdir -export MV = mv -export ECHO = echo -export MAKE = make -export PERL = perl -export PKGCONFIG = pkg-config +CP := cp +RM := rm +MKDIR := mkdir +MV := mv +ECHO := echo +MAKE := make +PERL := perl +PKGCONFIG := pkg-config +INSTALL := install +SED := sed # Toolchain flags -WARNFLAGS = -Wall -Wextra -Wundef -Wpointer-arith -Wcast-align \ +WARNFLAGS := -Wall -Wextra -Wundef -Wpointer-arith -Wcast-align \ -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes \ -Wmissing-declarations -Wnested-externs -Werror -pedantic -export CFLAGS = -std=c99 -D_BSD_SOURCE -I$(TOP)/include/ $(WARNFLAGS) -export ARFLAGS = -cru -export LDFLAGS = -L$(TOP)/ +CFLAGS += -std=c99 -D_BSD_SOURCE -I$(TOP)/include/ $(WARNFLAGS) +RELEASECFLAGS = $(CFLAGS) -DNDEBUG -O2 +DEBUGCFLAGS = $(CFLAGS) -O0 -g +ARFLAGS := -cru +LDFLAGS = -L$(TOP)/ -export CPFLAGS = -export RMFLAGS = -export MKDIRFLAGS = -p -export MVFLAGS = -export ECHOFLAGS = -export MAKEFLAGS = -export PKGCONFIGFLAGS = +CPFLAGS := +RMFLAGS := -f +MKDIRFLAGS := -p +MVFLAGS := +ECHOFLAGS := +MAKEFLAGS := +PKGCONFIGFLAGS := -export EXEEXT = +EXEEXT := + +# Default installation prefix +PREFIX ?= /usr/local include build/Makefile.common -- cgit v1.2.3