summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFrank Haverkamp <haver@vnet.ibm.com>2008-02-21 16:00:13 +0200
committerArtem Bityutskiy <Artem.Bityutskiy@nokia.com>2008-02-21 16:00:13 +0200
commitfb552c18cb72e2eb778e74f4bac2d61e059b4278 (patch)
tree8d74ae1bedb243f417140d720ae4b1b9072a2167
parent56868f374f5ba88e766690236a41af36a1e51949 (diff)
ubi-utils: Fixup Makefile for new version of the tools
Because of defining targets which get never build calling make multiple times caused regeneration of the code. The fix creates proper .a files which prevent the rebuild since they exist after build. Signed-off-by: Frank Haverkamp <haver@vnet.ibm.com>
-rw-r--r--ubi-utils/new-utils/Makefile22
1 files changed, 11 insertions, 11 deletions
diff --git a/ubi-utils/new-utils/Makefile b/ubi-utils/new-utils/Makefile
index 2d073a9..175187e 100644
--- a/ubi-utils/new-utils/Makefile
+++ b/ubi-utils/new-utils/Makefile
@@ -29,26 +29,26 @@ all: $(UTILS)
$(CC) $(CFLAGS) $< -c -o $@
# And the below is the rule to get final executable from its .o and common.o
-%: libubi %.o common.o
+%: libubi.a %.o common.o
$(CC) $(CFLAGS) $(filter %.o, $^) -L. -lubi -o $@
ubicrc32: ubicrc32.o crc32.o
$(CC) $(CFLAGS) -o $@ $^
-ubinize: ubinize.o common.o crc32.o libiniparser libubigen
+ubinize: ubinize.o common.o crc32.o libiniparser.a libubigen.a
$(CC) $(CFLAGS) $(filter %.o, $^) -L. -liniparser -lubigen -o $@
-libubi: libubi.o
- $(AR) crv $@.a $^
- ranlib $@.a
+libubi.a: libubi.o
+ $(AR) crv $@ $^
+ ranlib $@
-libubigen: libubigen.o
- $(AR) crv $@.a $^
- ranlib $@.a
+libubigen.a: libubigen.o
+ $(AR) crv $@ $^
+ ranlib $@
-libiniparser: libiniparser.o dictionary.o
- $(AR) crv $@.a $^
- ranlib $@.a
+libiniparser.a: libiniparser.o dictionary.o
+ $(AR) crv $@ $^
+ ranlib $@
clean:
rm -rf *.o $(addsuffix .a, $(LIBS)) $(UTILS) .*.c.dep