svn commit: r208180 - user/dougb/portmaster
Doug Barton
dougb at FreeBSD.org
Mon May 17 02:11:04 UTC 2010
Author: dougb
Date: Mon May 17 02:11:03 2010
New Revision: 208180
URL: http://svn.freebsd.org/changeset/base/208180
Log:
Limit the scope of some of the variables related to fetching distfiles
If a distfile has a / in the file name creation of the flag file for
background fetching will fail, so swap that for a _ instead.
Modified:
user/dougb/portmaster/portmaster
Modified: user/dougb/portmaster/portmaster
==============================================================================
--- user/dougb/portmaster/portmaster Mon May 17 02:01:22 2010 (r208179)
+++ user/dougb/portmaster/portmaster Mon May 17 02:11:03 2010 (r208180)
@@ -2811,6 +2811,8 @@ check_state || {
# Do these things first time through, with or without 'make config'
if [ -z "$PM_BUILDING" -a -z "$SHOW_WORK" -a -z "$NO_ACTION" ]; then
dofetch () {
+ local fetchlog allfiles
+
echo "===>>> Launching 'make checksum' for $portdir in background"
fetchlog=`pm_mktemp fetchlog-${portdir#*/}`
(pm_make -DBATCH checksum >> $fetchlog 2>&1 && {
@@ -2836,8 +2838,8 @@ dofetch () {
# Make sure that different ports using the same distfiles
# do not clobber each other's fetchs
for file in $distfiles; do
- if ! ls ${TMPDIR}/f-${PM_PARENT_PID}-${file}-* >/dev/null 2>&1
- then
+ case "$file" in */*) file=`echo $file | sed s#/#_#g` ;; esac
+ if ! ls ${TMPDIR}/f-${PM_PARENT_PID}-${file}-* >/dev/null 2>&1; then
pm_mktemp ${file}-${portdir#*/} >/dev/null
else
DONT_FETCH=dont_fetch
@@ -2847,7 +2849,7 @@ dofetch () {
[ -z "$DONT_FETCH" -a -n "$distfiles" ] && dofetch
fi
- unset master_sites
+ unset master_sites distfiles file DONT_FETCH
if [ -z "$FETCH_ONLY" -a ! "$PM_PACKAGES" = only ]; then
TESTINT=`grep -l ^IS_INTERACTIVE Makefile`
@@ -2862,6 +2864,7 @@ dofetch () {
echo -n "===>>> Press the [Enter] or [Return] key to continue "
read DISCARD
echo ''
+ unset TESTINT DISCARD
fi
fi
fi # [ -z "$PM_INDEX_ONLY" ]
More information about the svn-src-user
mailing list