pkgsrc-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[pkgsrc/trunk]: pkgsrc/mk/configure Added the CHECK_PORTABILITY_SKIP variable...
details: https://anonhg.NetBSD.org/pkgsrc/rev/5a83102ace58
branches: trunk
changeset: 520586:5a83102ace58
user: rillig <rillig%pkgsrc.org@localhost>
date: Mon Oct 23 16:07:12 2006 +0000
description:
Added the CHECK_PORTABILITY_SKIP variable that may be defined by packages
to exclude some files from the portability checks.
diffstat:
mk/configure/check-portability.mk | 12 ++++++++++--
mk/configure/check-portability.sh | 13 ++++++++-----
2 files changed, 18 insertions(+), 7 deletions(-)
diffs (73 lines):
diff -r ab6486dbde43 -r 5a83102ace58 mk/configure/check-portability.mk
--- a/mk/configure/check-portability.mk Mon Oct 23 15:37:52 2006 +0000
+++ b/mk/configure/check-portability.mk Mon Oct 23 16:07:12 2006 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: check-portability.mk,v 1.6 2006/10/21 19:07:18 rillig Exp $
+# $NetBSD: check-portability.mk,v 1.7 2006/10/23 16:07:12 rillig Exp $
#
# This file contains some checks that are applied to the configure
# scripts to check for certain constructs that are known to cause
@@ -20,12 +20,19 @@
#
# Default value: no
#
+# CHECK_PORTABILITY_SKIP: List of Pathmask
+# The list of files that should be skipped in the portability
+# check.
+#
+# Default value: empty.
+#
.if defined(PKG_DEVELOPER) && !empty(PKG_DEVELOPER:M[Yy][Ee][Ss])
CHECK_PORTABILITY?= yes
.endif
CHECK_PORTABILITY?= no
SKIP_PORTABILITY_CHECK?= no
+CHECK_PORTABILITY_SKIP?= # none
.if ${CHECK_PORTABILITY:M[Yy][Ee][Ss]} != "" && \
${SKIP_PORTABILITY_CHECK:M[Yy][Ee][Ss]} == ""
@@ -37,4 +44,5 @@
${_PKG_SILENT}${_PKG_DEBUG} \
[ -d ${WRKSRC}/. ] || exit 0; \
cd ${WRKSRC} \
- && sh ${PKGSRCDIR}/mk/configure/check-portability.sh
+ && env SKIP_FILTER=${CHECK_PORTABILITY_SKIP:@p@${p}) continue;;@:Q} \
+ sh ${PKGSRCDIR}/mk/configure/check-portability.sh
diff -r ab6486dbde43 -r 5a83102ace58 mk/configure/check-portability.sh
--- a/mk/configure/check-portability.sh Mon Oct 23 15:37:52 2006 +0000
+++ b/mk/configure/check-portability.sh Mon Oct 23 16:07:12 2006 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: check-portability.sh,v 1.3 2006/10/21 10:37:48 rillig Exp $
+# $NetBSD: check-portability.sh,v 1.4 2006/10/23 16:07:12 rillig Exp $
#
# This program checks the extracted files for portability issues that
# are likely to result in false assumptions by the package.
@@ -10,9 +10,15 @@
# the PATH, it calls the utilities by their base names. It also assumes
# to be interpreted by a POSIX-conforming shell.
#
+# ENVIRONMENT VARIABLES
+#
+# SKIP_FILTER: A shell command that excludes some patterns.
+#
set -eu
+: ${SKIP:=""}
+
exitcode=0
last_heading=""
@@ -93,10 +99,7 @@
| {
while read fname; do
- case "$fname" in
- *.orig)
- continue;;
- esac
+ eval "case \"\$fname\" in $SKIP_FILTER *.orig) continue;; esac"
read firstline < "$fname" || continue
case "$firstline" in
Home |
Main Index |
Thread Index |
Old Index