emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: MinGW "pwd -W" configure.ac correction


From: Glenn Morris
Subject: Re: MinGW "pwd -W" configure.ac correction
Date: Thu, 24 Oct 2013 21:55:56 -0400
User-agent: Gnus (www.gnus.org), GNU Emacs (www.gnu.org/software/emacs/)

Eli Zaretskii wrote:

>> Does this `pwd -W' correction only matter for epaths.h?
>> If so, could it be moved to the epaths-force-w32 rule in Makefile.in?
>
> This could maybe work today, but it's a time bomb: the underlying
> problem, explained in configure.ac, will bite us if we ever invoke any
> MinGW program (including, but not limited to, Emacs) during the build.

(We should use relative paths wherever possible, to avoid this and other
issues.)

This sounds like rather a general problem. Is it something to report to
autoconf they can improve support for it in some future version?

> We cannot allow something like /usr/foo/bar in $abs_srcdir, anywhere.
> It must be in the /x/foo/bar format, i.e. it must include the Windows
> drive letter (in the "/x/" form) explicitly.  It's just that epaths.h
> were the first place where this problem hit us.

I didn't appreciate at first that for autoconf, $srcdir is "special",
and not like eg "$abs_srcdir." You can easily change the former, but not
the latter (AFAICS).

If Emacs really needs a special value for "absolute path to sources on
MinGW" that is different to what autoconf provides, then the only method
I can think of is:

In configure.ac, on MinGW, define mingw_abs_srcdir = whatever

Use that variable directly in configure wherever needed.

In Makefiles, use

abs_srcdir = @abs_srcdir@
mingw_abs_srcdir = @mingw_abs_srcdir@
real_abs_srcdir = @real_abs_srcdir@

where configure sets
real_abs_srcdir = \${mingw_abs_srcdir} on MinGW, and \${abs_srcdir}
everywhere else.

Then in rules, remember to use $(real_abs_srcdir).

Bit messy. Maybe someone else has a better idea.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]