summaryrefslogtreecommitdiffstats
path: root/scripts/lib/ptxd_lib_dgen.awk
diff options
context:
space:
mode:
authorMichael Olbrich <m.olbrich@pengutronix.de>2009-10-20 20:13:32 +0200
committerMichael Olbrich <m.olbrich@pengutronix.de>2009-10-26 12:46:19 +0100
commitadaff8ac204285eeaffd14b63e296ebdf8cf1c62 (patch)
tree398e57a7536f1c59b491e3e83b3bfeee9d07364d /scripts/lib/ptxd_lib_dgen.awk
parent46496f2236ce9cb4eb5f826a824d9a73bad97a49 (diff)
downloadptxdist-adaff8ac204285eeaffd14b63e296ebdf8cf1c62.tar.gz
ptxdist-adaff8ac204285eeaffd14b63e296ebdf8cf1c62.tar.xz
[autogen] create automatic dependencies for packages that need to run autogen.sh
Signed-off-by: Michael Olbrich <m.olbrich@pengutronix.de> Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
Diffstat (limited to 'scripts/lib/ptxd_lib_dgen.awk')
-rw-r--r--scripts/lib/ptxd_lib_dgen.awk17
1 files changed, 17 insertions, 0 deletions
diff --git a/scripts/lib/ptxd_lib_dgen.awk b/scripts/lib/ptxd_lib_dgen.awk
index 37c179839..5be1ddf16 100644
--- a/scripts/lib/ptxd_lib_dgen.awk
+++ b/scripts/lib/ptxd_lib_dgen.awk
@@ -243,6 +243,23 @@ END {
}
#
+ # conditional dependency on autogen script
+ #
+ if (!(this_pkg ~ /^host-|^cross-/)) {
+ print "ifneq ($(" this_PKG "),)" > DGEN_DEPS_POST;
+ print "ifneq ($(call autogen_dep,$(" this_PKG ")),)" > DGEN_DEPS_POST;
+ } else {
+ target_PKG = gensub(/^HOST_/, "", "", this_PKG);
+ target_PKG = gensub(/^CROSS_/, "", "", target_PKG);
+ # host/cross packages inherit the package name xor have their own
+ print "ifneq ($(" this_PKG ")$(" target_PKG "),)" > DGEN_DEPS_POST;
+ print "ifneq ($(call autogen_dep,$(" this_PKG ")$(" target_PKG ")),)" > DGEN_DEPS_POST;
+ }
+ print "$(STATEDIR)/" this_pkg ".extract: $(STATEDIR)/autogen-tools" > DGEN_DEPS_POST;
+ print "endif" > DGEN_DEPS_POST;
+ print "endif" > DGEN_DEPS_POST;
+
+ #
# add dep to pkgs we depend on
#
this_PKG_DEPS = PKG_to_DEP[this_PKG];