[Reproducible-commits] [dpkg] 14/32: build: Quote paths in run-scripts

Jérémy Bobbio lunar at moszumanska.debian.org
Fri Nov 6 14:02:18 UTC 2015


This is an automated email from the git hooks/post-receive script.

lunar pushed a commit to branch pu/reproducible_builds
in repository dpkg.

commit b0f1071aaff431f68825c1b749f6c6ab58475a9d
Author: Guillem Jover <guillem at debian.org>
Date:   Sat Oct 17 16:57:01 2015 +0200

    build: Quote paths in run-scripts
    
    This makes the script more robust, although the source tree is not
    really prepared to be built on paths with spaces.
---
 run-script | 14 +++++++-------
 1 file changed, 7 insertions(+), 7 deletions(-)

diff --git a/run-script b/run-script
index 0832f90..00e2230 100755
--- a/run-script
+++ b/run-script
@@ -1,19 +1,19 @@
 #!/bin/sh
 
-top_srcdir=`dirname $0`
+top_srcdir="`dirname $0`"
 
 # To avoid using «readlink -f» or «realpath» we just change into the
 # desired directory and work from there.
 cd "$top_srcdir"
-cwd=`pwd`
+cwd="`pwd`"
 cd "$OLDPWD"
 
 # Set up the environment, to use local perl modules and data files.
-export PERL5LIB=$cwd/scripts:$cwd/dselect/methods
-export DPKG_DATADIR=$cwd
+export PERL5LIB="$cwd/scripts:$cwd/dselect/methods"
+export DPKG_DATADIR="$cwd"
 
-interp=$1
-script=$2
+interp="$1"
+script="$2"
 shift 2
 
-exec $interp "$cwd/$script" "$@"
+exec "$interp" "$cwd/$script" "$@"

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/reproducible/dpkg.git



More information about the Reproducible-commits mailing list