summaryrefslogtreecommitdiff
path: root/mk/buildlink3/logic
diff options
context:
space:
mode:
authorjlam <jlam>2003-10-03 19:39:19 +0000
committerjlam <jlam>2003-10-03 19:39:19 +0000
commit687eb1a698518352774991d77db65965ff9b0160 (patch)
tree41bbdd7c68171c46a86410bccc508d727ef552be /mk/buildlink3/logic
parent2dbbeae6751d26a24b75f1186eae7d818f228a88 (diff)
downloadpkgsrc-687eb1a698518352774991d77db65965ff9b0160.tar.gz
Factor out some more commonly used bits of the wrapper system into
their own files: buildcmd and quotearg, which are used to build up the command line and to quote arguments. Also add the ability to skip processing the next few arguments and add them directly to the command line. Now, either the marshall script or the cache scripts can request skipping the N arguments by setting skipargs=N.
Diffstat (limited to 'mk/buildlink3/logic')
-rw-r--r--mk/buildlink3/logic19
1 files changed, 2 insertions, 17 deletions
diff --git a/mk/buildlink3/logic b/mk/buildlink3/logic
index c62c25ceaf6..75b9b2909ff 100644
--- a/mk/buildlink3/logic
+++ b/mk/buildlink3/logic
@@ -1,26 +1,11 @@
-# $NetBSD: logic,v 1.3 2003/09/19 22:47:34 jlam Exp $
+# $NetBSD: logic,v 1.4 2003/10/03 19:39:19 jlam Exp $
quotedarg=no
addtocache=no
addtoprivatecache=no
cachesettings='arg="$cachearg"; cachehit=yes'
-# $qarg contains a correctly-quoted $arg
-case $arg in
-*[\`\"\$\\]*)
- qarg=`$echo "X$arg" | $Xsed -e "$sed_quote_subst"`
- quotedarg=yes
- ;;
-*)
- qarg="$arg"
- ;;
-esac
-case $qarg in
- *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"")
- qarg="\"$qarg\""
- quotedarg=yes
- ;;
-esac
+. $quotearg
searcharg="$qarg"
case $arg in