diff options
Diffstat (limited to 'scripts/lib/ptxd_lib_dgen.awk')
-rw-r--r-- | scripts/lib/ptxd_lib_dgen.awk | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/scripts/lib/ptxd_lib_dgen.awk b/scripts/lib/ptxd_lib_dgen.awk index 2c6c80a69..024a3dc48 100644 --- a/scripts/lib/ptxd_lib_dgen.awk +++ b/scripts/lib/ptxd_lib_dgen.awk @@ -358,10 +358,16 @@ function write_deps_pkg_all(this_PKG, this_pkg) { function write_deps_pkg_active_cfghash(this_PKG, this_pkg) { print "ifneq ($(" this_PKG "),)" > DGEN_DEPS_POST; - print this_PKG "_PATCHES := $(call ptx/in-path,PTXDIST_PATH_PATCHES,$(" this_PKG "))" > DGEN_DEPS_POST; - print "ifneq ($(wildcard $(" this_PKG "_PATCHES)),)" > DGEN_DEPS_POST; + print "ifneq ($(" this_PKG "_PATCHES),)" > DGEN_DEPS_POST; + print this_PKG "_PATCH_DIR := $(call ptx/in-path,PTXDIST_PATH_PATCHES,$(" this_PKG "_PATCHES))" > DGEN_DEPS_POST; + print "else" > DGEN_DEPS_POST; + print this_PKG "_PATCH_DIR := $(call ptx/in-path,PTXDIST_PATH_PATCHES,$(" this_PKG "))" > DGEN_DEPS_POST; + print "endif" > DGEN_DEPS_POST; + print "ifeq ($(" this_PKG "_PATCH_DIR),)" > DGEN_DEPS_POST; + print "undefine " this_PKG "_PATCH_DIR" > DGEN_DEPS_POST; + print "else" > DGEN_DEPS_POST; print "ifeq ($(wildcard " PTXDIST_TEMPDIR "/pkghash-" this_PKG "_EXTRACT.done),)" > DGEN_DEPS_POST; - print "$(call ptx/force-sh, find '$(" this_PKG "_PATCHES)' -type f ! -name '.*' | sort | xargs cat | tee " \ + print "$(call ptx/force-sh, find '$(" this_PKG "_PATCH_DIR)' -type f ! -name '.*' | sort | xargs cat | tee " \ PTXDIST_TEMPDIR "/pkghash-" this_PKG "_EXTRACT >> " PTXDIST_TEMPDIR "/pkghash-" this_PKG \ " && touch " PTXDIST_TEMPDIR "/pkghash-" this_PKG "_EXTRACT.done )" > DGEN_DEPS_POST; print "endif" > DGEN_DEPS_POST; |