dnsmasq: fix parallel make failure

The dnsmasq target depends on .configured and $(objs). .configured does an rm
-f *.o. Yet the only thing telling make to build the .configured target before
the $(objs) target was the order of the dependencies of the dnsmasq target. We
can't rely on that order when doing a paralllel make build, so add an explicit
rule to enforce that order.

Signed-off-by: Christopher Larson <kergoth@gmail.com>
Signed-off-by: Shrikant Bobade <Shrikant_Bobade@mentor.com>
Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
This commit is contained in:
Shrikant Bobade
2014-08-04 14:42:57 +05:30
committed by Martin Jansa
parent 6576cddf6b
commit 3740ef2638
2 changed files with 19 additions and 0 deletions
@@ -11,6 +11,7 @@ SRC_URI = "http://www.thekelleys.org.uk/dnsmasq/${@['archive/', ''][float(d.getV
file://init \
file://dnsmasq.conf \
file://dnsmasq.service \
file://parallel-make.patch \
"
inherit update-rc.d systemd
@@ -0,0 +1,18 @@
The dnsmasq target depends on .configured and $(objs). .configured does an rm
-f *.o. Yet the only thing telling make to build the .configured target before
the $(objs) target was the order of the dependencies of the dnsmasq target. We
can't rely on that order when doing a paralllel make build, so add an explicit
rule to enforce that order.
Signed-off-by: Christopher Larson <chris_larson@mentor.com>
--- dnsmasq-2.68.orig/Makefile
+++ dnsmasq-2.68/Makefile
@@ -139,6 +139,8 @@ bloatcheck : $(BUILDDIR)/dnsmasq_baselin
@rm -f *.o
@touch $@
+$(objs): .configured
+
$(objs:.o=.c) $(hdrs):
ln -s $(top)/$(SRC)/$@ .