pkgsrc-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[pkgsrc/trunk]: pkgsrc/mk/check Removed the need to define the PKGSRCDIR envi...
details: https://anonhg.NetBSD.org/pkgsrc/rev/76fdb5e0311f
branches: trunk
changeset: 523144:76fdb5e0311f
user: rillig <rillig%pkgsrc.org@localhost>
date: Tue Jan 02 17:58:11 2007 +0000
description:
Removed the need to define the PKGSRCDIR environment variable.
diffstat:
mk/check/check-headers.mk | 5 ++---
mk/check/check-headers.sh | 5 +++--
mk/check/check-portability.mk | 5 ++---
mk/check/check-portability.sh | 18 ++++++++++++------
mk/check/check-subr.sh | 5 +----
5 files changed, 20 insertions(+), 18 deletions(-)
diffs (112 lines):
diff -r 5112cb66c1ba -r 76fdb5e0311f mk/check/check-headers.mk
--- a/mk/check/check-headers.mk Tue Jan 02 17:56:52 2007 +0000
+++ b/mk/check/check-headers.mk Tue Jan 02 17:58:11 2007 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: check-headers.mk,v 1.2 2006/11/09 14:41:18 rillig Exp $
+# $NetBSD: check-headers.mk,v 1.3 2007/01/02 17:58:11 rillig Exp $
#
# This file checks the C and C++ header files for possible problems.
#
@@ -32,6 +32,5 @@
${RUN} \
[ -d ${WRKSRC}/. ] || exit 0; \
cd ${WRKSRC}; \
- env PKGSRCDIR=${PKGSRCDIR:Q} \
- SKIP_FILTER=${CHECK_HEADERS_SKIP:@p@${p}) skip=yes;;@:Q} \
+ env SKIP_FILTER=${CHECK_HEADERS_SKIP:@p@${p}) skip=yes;;@:Q} \
sh ${PKGSRCDIR}/mk/check/check-headers.sh
diff -r 5112cb66c1ba -r 76fdb5e0311f mk/check/check-headers.sh
--- a/mk/check/check-headers.sh Tue Jan 02 17:56:52 2007 +0000
+++ b/mk/check/check-headers.sh Tue Jan 02 17:58:11 2007 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: check-headers.sh,v 1.8 2006/11/10 07:59:01 rillig Exp $
+# $NetBSD: check-headers.sh,v 1.9 2007/01/02 17:58:11 rillig Exp $
#
# This program checks the header files for possible problems.
#
@@ -9,7 +9,8 @@
set -eu
-. "${PKGSRCDIR}/mk/check/check-subr.sh"
+checkdir=`dirname "$0"`
+. "$checkdir/check-subr.sh"
cs_setprogname "$0"
found_unresolved_variable=no
diff -r 5112cb66c1ba -r 76fdb5e0311f mk/check/check-portability.mk
--- a/mk/check/check-portability.mk Tue Jan 02 17:56:52 2007 +0000
+++ b/mk/check/check-portability.mk Tue Jan 02 17:58:11 2007 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: check-portability.mk,v 1.2 2006/11/09 14:36:18 rillig Exp $
+# $NetBSD: check-portability.mk,v 1.3 2007/01/02 17:58:11 rillig Exp $
#
# This file contains some checks that are applied to the configure
# scripts to check for certain constructs that are known to cause
@@ -45,6 +45,5 @@
${RUN} \
[ -d ${WRKSRC}/. ] || exit 0; \
cd ${WRKSRC}; \
- env PKGSRCDIR=${PKGSRCDIR:Q} \
- SKIP_FILTER=${CHECK_PORTABILITY_SKIP:@p@${p}) skip=yes;;@:Q} \
+ env SKIP_FILTER=${CHECK_PORTABILITY_SKIP:@p@${p}) skip=yes;;@:Q} \
sh ${PKGSRCDIR}/mk/check/check-portability.sh
diff -r 5112cb66c1ba -r 76fdb5e0311f mk/check/check-portability.sh
--- a/mk/check/check-portability.sh Tue Jan 02 17:56:52 2007 +0000
+++ b/mk/check/check-portability.sh Tue Jan 02 17:58:11 2007 +0000
@@ -1,17 +1,23 @@
-# $NetBSD: check-portability.sh,v 1.5 2006/12/31 13:35:10 rillig Exp $
+# $NetBSD: check-portability.sh,v 1.6 2007/01/02 17:58:11 rillig Exp $
#
-# This program checks the extracted files for portability issues that
-# are likely to result in false assumptions by the package.
+# This program checks all files in the current directory and any
+# subdirectories for portability issues that are likely to result in
+# false assumptions by the package.
#
# The most prominent example is the "==" operator of test(1), which is
# only implemented by bash and some versions of the ksh.
#
+# usage: check-portability.sh
+#
set -eu
-. "${PKGSRCDIR}/mk/check/check-subr.sh"
+checkdir=`dirname "$0"`
+. "$checkdir/check-subr.sh"
cs_setprogname "$0"
+: ${SKIP_FILTER:=""}
+
found_random=no
found_test_eqeq=no
@@ -20,8 +26,8 @@
env \
CK_FNAME="$1" \
CK_PROGNAME="check-portability.awk" \
- awk -f "$PKGSRCDIR/mk/check/check-subr.awk" \
- -f "$PKGSRCDIR/mk/check/check-portability.awk" \
+ awk -f "$checkdir/check-subr.awk" \
+ -f "$checkdir/check-portability.awk" \
< "$1" 1>&2 \
|| cs_exitcode=1
}
diff -r 5112cb66c1ba -r 76fdb5e0311f mk/check/check-subr.sh
--- a/mk/check/check-subr.sh Tue Jan 02 17:56:52 2007 +0000
+++ b/mk/check/check-subr.sh Tue Jan 02 17:58:11 2007 +0000
@@ -1,12 +1,9 @@
-# $NetBSD: check-subr.sh,v 1.4 2006/11/11 23:08:00 rillig Exp $
+# $NetBSD: check-subr.sh,v 1.5 2007/01/02 17:58:11 rillig Exp $
#
# This file contains shell functions that are used by the various shell
# programs that check things in pkgsrc. All these programs must be
# called with the following environment variables set:
#
-# PKGSRCDIR
-# The root directory of the pkgsrc tree.
-#
# SKIP_FILTER
# A shell expression of the form
#
Home |
Main Index |
Thread Index |
Old Index