[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Bootstrap failure on MS-Windows
From: |
Dani Moncayo |
Subject: |
Re: Bootstrap failure on MS-Windows |
Date: |
Tue, 5 Nov 2013 22:08:51 +0100 |
>> I've tried again with that correction, but I see the same failure.
>>
>> I may provide any necessary info to investigate this further (though I
>> think that this problem should be trivial to reproduce by anyone who
>> builds Emacs on MS-Windows).
>
> The relevant piece of information is src/epaths.h. But really, Dani,
> you are the only person who is motivated enough to dig into this, so
> please do. The issue cannot be too complicated: what happens here is
> that Emacs does not find its lisp subdirectory, and therefore looks
> for the one in the installation tree, which doesn't yet exist.
It seems that Glenn's patch (with Eli's fix) was almost correct.
After a bit of observation to the output of "msysconfig", I found a
problem in this line:
@(w32srcdir=`cd "$srcdir"; pwd -W | sed -e 's,^\([A-Za-z]\):,/\1,' |
${msys_to_w32}` ; \
^^^^^^^
It seems that the shell was expanding "$s" to the empty string, so
that the command finally executed was "cd rcdir; pwd -W | ..."
I've fixed this by replacing "$srcdir" with "${srcdir}".
So this is the final patch that has worked for me:
diff --git a/Makefile.in b/Makefile.in
index 461f0cb..39bdc5d 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -342,8 +342,16 @@ msys_sed_sh_escape=sed -e 's/[];$$*.^[]/\\\\&/g'
# nt/epaths.nt as the template.
# Use the value of ${locallisppath} supplied by `configure',
# to support the --enable-locallisppath argument.
+#
+# When building with MinGW inside the MSYS tree, 'pwd' produces directories
+# relative to the root of the MSYS tree, e.g. '/home/user/foo' instead of
+# '/d/MSYS/home/user/foo'. If such a value of srcdir is written to
+# src/epaths.h, that causes temacs to fail, because, being a MinGW
+# program that knows nothing of MSYS root substitution, it cannot find
+# the data directory. "pwd -W" produces Windows-style 'd:/foo/bar'
+# absolute directory names, so we use it here to countermand that lossage.
epaths-force-w32: FRC
- @(w32srcdir=`echo "${abs_srcdir}" | ${msys_to_w32}` ; \
+ @(w32srcdir=`cd "${srcdir}"; pwd -W | sed -e 's,^\([A-Za-z]\):,/\1,'
| ${msys_to_w32}` ; \
prefixpattern=`echo '${prefix}' | ${msys_to_w32} | ${msys_sed_sh_escape}` ; \
locallisppath=`echo '${locallisppath}' | ${msys_lisppath_to_w32} |
${msys_prefix_subst}` ; \
sed < ${srcdir}/nt/epaths.nt > epaths.h.$$$$ \
diff --git a/configure.ac b/configure.ac
index cb97564..a8fb34b 100644
--- a/configure.ac
+++ b/configure.ac
@@ -419,17 +419,6 @@ AC_ARG_ENABLE(gtk-deprecation-warnings,
[Show Gtk+/Gdk deprecation warnings for Gtk+ >= 3.0])],
[ac_enable_gtk_deprecation_warnings="${enableval}"],[])
-#### When building with MinGW inside the MSYS tree, 'pwd' produces
-#### directories relative to the root of the MSYS tree,
-#### e.g. '/home/user/foo' instead of '/d/MSYS/home/user/foo'. When
-#### such a value of srcdir is written to the top-level Makefile, it
-#### gets propagated to src/epaths.h, and that causes temacs to fail,
-#### because, being a MinGW program that knows nothing of MSYS root
-#### substitution, it cannot find the data directory. "pwd -W"
-#### produces Windows-style 'd:/foo/bar' absolute directory names, so
-#### we use it here to countermand that lossage.
-test "$MSYSTEM" = "MINGW32" && abs_srcdir=`(cd "$abs_srcdir"; pwd -W
| sed -e 's,^\([[A-Za-z]]\):,/\1,')`
-
### Canonicalize the configuration name.
AC_CANONICAL_HOST
--
Dani Moncayo
- Bootstrap failure on MS-Windows, Dani Moncayo, 2013/11/02
- Re: Bootstrap failure on MS-Windows, Glenn Morris, 2013/11/02
- Re: Bootstrap failure on MS-Windows, Glenn Morris, 2013/11/05
- Re: Bootstrap failure on MS-Windows, Dani Moncayo, 2013/11/05
- Re: Bootstrap failure on MS-Windows, Eli Zaretskii, 2013/11/05
- Re: Bootstrap failure on MS-Windows, Dani Moncayo, 2013/11/05
- Re: Bootstrap failure on MS-Windows, Eli Zaretskii, 2013/11/05
- Re: Bootstrap failure on MS-Windows,
Dani Moncayo <=
- Re: Bootstrap failure on MS-Windows, Glenn Morris, 2013/11/05
- Re: Bootstrap failure on MS-Windows, Dani Moncayo, 2013/11/06
- Re: Bootstrap failure on MS-Windows, Glenn Morris, 2013/11/06
- Re: Bootstrap failure on MS-Windows, Eli Zaretskii, 2013/11/06
- Re: Bootstrap failure on MS-Windows, Glenn Morris, 2013/11/06
- Re: Bootstrap failure on MS-Windows, Glenn Morris, 2013/11/11
- Re: Bootstrap failure on MS-Windows, Óscar Fuentes, 2013/11/05
- Re: Bootstrap failure on MS-Windows, Glenn Morris, 2013/11/05
- Re: Bootstrap failure on MS-Windows, Glenn Morris, 2013/11/05
- Re: Bootstrap failure on MS-Windows, Andy Moreton, 2013/11/06