[m-rev.] diff: make configure work if the path of source directory contains spaces
Julien Fischer
juliensf at csse.unimelb.edu.au
Fri Dec 17 17:17:17 AEDT 2010
Note: mmake doesn't currently appear to work if the source directory
contains spaces - I am looking into this. The rationale for the change
below is that we currently get a rather horrible abort from configure that
doesn't give much of an indication of what's gone wrong. If the problem
with mmake is not fixable I will add a check to configure that prints
out a nicer error message and then aborts.
Branches: main
Fix problems with the configure script if the absolute path of the source
directory contains spaces.
configure.in:
As above.
Julien.
Index: configure.in
===================================================================
RCS file: /home/mercury/mercury1/repository/mercury/configure.in,v
retrieving revision 1.572
diff -u -r1.572 configure.in
--- configure.in 13 Dec 2010 05:59:41 -0000 1.572
+++ configure.in 17 Dec 2010 06:13:21 -0000
@@ -4554,12 +4554,12 @@
# The following allows us to share some subroutines between the
# `ml' and `mgnuc' scripts.
-top=`pwd`
-INIT_GRADE_OPTIONS=$top/scripts/init_grade_options.sh-subr
-PARSE_GRADE_OPTIONS=$top/scripts/parse_grade_options.sh-subr
-FINAL_GRADE_OPTIONS=$top/scripts/final_grade_options.sh-subr
-PARSE_ML_OPTIONS=$top/scripts/parse_ml_options.sh-subr
-CANONICAL_GRADE=$top/scripts/canonical_grade.sh-subr
+top="`pwd`"
+INIT_GRADE_OPTIONS="$top"/scripts/init_grade_options.sh-subr
+PARSE_GRADE_OPTIONS="$top"/scripts/parse_grade_options.sh-subr
+FINAL_GRADE_OPTIONS="$top"/scripts/final_grade_options.sh-subr
+PARSE_ML_OPTIONS="$top"/scripts/parse_ml_options.sh-subr
+CANONICAL_GRADE="$top"/scripts/canonical_grade.sh-subr
# The following allows us to duplicate a subroutine in mgnuc.
@@ -5183,11 +5183,11 @@
*)
m4 -P -DDEFAULT_MERCURY_DEBUGGER_INIT_DIR=TESTS_MDB_INIT_DIR \
-DDEFAULT_MERCURY_DEBUGGER_DOC=TESTS_MDB_DOC \
- `pwd`/scripts/mdbrc.in > $test_mdbrc.in
+ "`pwd`"/scripts/mdbrc.in > $test_mdbrc.in
;;
esac
-TESTS_MDB_INIT_DIR=`pwd`/scripts
-TESTS_MDB_DOC=`pwd`/doc/mdb_doc
+TESTS_MDB_INIT_DIR="`pwd`"/scripts
+TESTS_MDB_DOC="`pwd`"/doc/mdb_doc
AC_SUBST(TESTS_MDB_INIT_DIR)
AC_SUBST(TESTS_MDB_DOC)
@@ -5319,7 +5319,7 @@
case "$remake_dependencies.$reconfiguring" in
"true.no")
MERCURY_MSG("regenerating dependencies to enable GCC backend.")
- MMAKE_DIR=`pwd`/scripts scripts/mmake depend || exit 1
+ MMAKE_DIR="`pwd`"/scripts scripts/mmake depend || exit 1
;;
esac
--------------------------------------------------------------------------
mercury-reviews mailing list
Post messages to: mercury-reviews at csse.unimelb.edu.au
Administrative Queries: owner-mercury-reviews at csse.unimelb.edu.au
Subscriptions: mercury-reviews-request at csse.unimelb.edu.au
--------------------------------------------------------------------------
More information about the reviews
mailing list