bug-gnu-emacs
[Top][All Lists]
Advanced

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

Re: next-error fails to find file on Cygwin with recursive make


From: Eli Zaretskii
Subject: Re: next-error fails to find file on Cygwin with recursive make
Date: Fri, 25 Apr 2008 17:39:30 +0300

> Date: Fri, 25 Apr 2008 13:52:10 +0100
> From: Gareth Rees <address@hidden>
> Cc: Gareth Rees <address@hidden>
> 
>     Find this error in (default src/test.c): c:/cygdrive/c/tmp/test
> 
> The reason it can't find the file is that 
> `compilation-directory-matcher' has matched the recursive make's 
> "Entering directory" line, which contains an absolute path name in 
> Cygwin syntax; and then `compilation-find-file' has called 
> `expand-file-name', which has converted `/cygdrive/c/tmp/test' into the 
> incorrect `c:/cygdrive/c/tmp/test' instead of the correct `c:/tmp/test'.
> 
> I am aware that I can work around this problem by advising 
> `expand-file-name' to recognize Cygwin path names and convert them to 
> path names that Emacs recognizes, for example like this:
> 
> (defadvice expand-file-name (before cygpath-convert-to-emacs-path activate)
>   (let ((name (ad-get-arg 0)))
>     (when (string-match "^/cygdrive/\\([a-z]\\)\\(/.*\\)" name)
>       (ad-set-arg 0 (concat (match-string 1 name) ":" (match-string 2 
> name))))))
> 
> However, it would be nice if recursive make in Cygwin worked in Emacs 
> out of the box.

It does, if you use the Cygwin build of Emacs.




reply via email to

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