From 3285a49dd871d54c1ec13076173ad617443baae1 Mon Sep 17 00:00:00 2001 From: Mike Frysinger Date: Sat, 25 Jun 2011 13:20:37 -0400 Subject: rewrite build system to avoid recursion The ubi-utils/src/ subdir is tossed as it just complicates things for no real gain. The dictionary.h header is relocated to the ubi-utils/include/ since other headers in there need it. The top level clean is replaced with a `find -delete` on objects, so it might prune more than necessary, but many projects now do this sort of thing and no one complained there. A "mkdep" helper generates the actual rule, and the variables are used with "foreach" to expand these automatically. The tests subdir is updated only to reflect the ubi-utils source move. Otherwise, it is left untouched as making that non-recursive isn't really worth the effort. While we're gutting things, also through in kbuild style output while building to make things more legible. Signed-off-by: Mike Frysinger Signed-off-by: Artem Bityutskiy --- tests/fs-tests/integrity/Makefile | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'tests/fs-tests') diff --git a/tests/fs-tests/integrity/Makefile b/tests/fs-tests/integrity/Makefile index 509a94e..4d6fc7d 100644 --- a/tests/fs-tests/integrity/Makefile +++ b/tests/fs-tests/integrity/Makefile @@ -4,9 +4,8 @@ CC = gcc endif COMMON_HEADERS_DIR := ../../../include -LIBUBI_PATH=../../../ubi-utils/ -LIBUBI_SRC_PATH=../../../ubi-utils/src/ -LIBUBI_HEADER_PATH=../../../ubi-utils/include +LIBUBI_PATH = ../../../ubi-utils/ +LIBUBI_HEADER_PATH = $(LIBUBI_PATH)/include CFLAGS := $(CFLAGS) -Wall -g -O2 -I$(COMMON_HEADERS_DIR) -I$(LIBUBI_HEADER_PATH) @@ -18,7 +17,7 @@ all: $(TARGETS) # Compile ubilib libubi.a: - $(CC) $(CFLAGS) -I $(LIBUBI_SRC_PATH) -c $(LIBUBI_SRC_PATH)/libubi.c -o libubi.o + $(CC) $(CFLAGS) -c $(LIBUBI_PATH)/libubi.c -o libubi.o ar cr libubi.a libubi.o $(TARGETS): libubi.a -- cgit v1.2.3