summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--rules/project-name.in10
-rw-r--r--scripts/lib/ptxd_lib_dgen.awk9
2 files changed, 19 insertions, 0 deletions
diff --git a/rules/project-name.in b/rules/project-name.in
index 2adf4e8bf..a9fdc4792 100644
--- a/rules/project-name.in
+++ b/rules/project-name.in
@@ -201,5 +201,15 @@ config PROJECT_DEVMIRROR
Enter a URL where *-dev.tar.gz packages can be downloaded
Use: ptxdist getdev
+comment "------------------------------------"
+comment "license information handling"
+comment "------------------------------------"
+config PROJECT_CHECK_LICENSES
+ bool
+ prompt "check licenses during normal build"
+ help
+ If this is enabled <pkg>.report is build during the normal build
+ process. As a result all specified md5 sums for license files are
+ verified.
endmenu
diff --git a/scripts/lib/ptxd_lib_dgen.awk b/scripts/lib/ptxd_lib_dgen.awk
index 5c8280ba2..4b9c065fa 100644
--- a/scripts/lib/ptxd_lib_dgen.awk
+++ b/scripts/lib/ptxd_lib_dgen.awk
@@ -21,6 +21,7 @@ BEGIN {
DGEN_RULESFILES_MAKE = ENVIRON["PTX_DGEN_RULESFILES_MAKE"];
PTXDIST_TEMPDIR = ENVIRON["PTXDIST_TEMPDIR"];
PARALLEL = ENVIRON["PTXDIST_PARALLELMFLAGS_EXTERN"]
+ CHECK_LICENSES = 0
}
#
@@ -193,6 +194,8 @@ $1 ~ /^PTXCONF_/ {
}
} while (sub(/_+[^_]+$/, "", this_PKG));
+ if (this_PKG = "PROJECT_CHECK_LICENSES")
+ CHECK_LICENSES = 1;
next;
}
@@ -278,6 +281,12 @@ function write_deps_pkg_active(this_PKG, this_pkg, prefix) {
}
print "$(STATEDIR)/" this_pkg ".report: " "$(STATEDIR)/" this_pkg ".extract" > DGEN_DEPS_POST;
print "$(STATEDIR)/" this_pkg ".release: " "$(STATEDIR)/" this_pkg ".extract" > DGEN_DEPS_POST;
+ if (CHECK_LICENSES) {
+ if (prefix == "")
+ print "$(STATEDIR)/" this_pkg ".targetinstall.post: $(STATEDIR)/" this_pkg ".report" > DGEN_DEPS_POST;
+ else
+ print "$(STATEDIR)/" this_pkg ".install.post: $(STATEDIR)/" this_pkg ".report" > DGEN_DEPS_POST;
+ }
#
# conditional dependencies