all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* emacs, jumping to relative file locations in compiler output.
@ 2014-03-27 12:14 glen stark
  2014-03-27 12:26 ` glen stark
  0 siblings, 1 reply; 3+ messages in thread
From: glen stark @ 2014-03-27 12:14 UTC (permalink / raw)
  To: help-gnu-emacs

In the company I'm working for, the build system is set up to cd in 
various directories, and the call make.    When a compiler error is 
returned, it is of the form:

In file included from ../../../../include/whatever.h:33:0

emacs is then unable to determine where to look for the file in question.

Changing out build system is big project, but I'd like to be able to jump 
around to compiler errors in emacs.  In practice I know what path I 
should substitute for "../../../../"

Is there someway I can tell emacs to regex substitute a fixed path for a 
string of the form "../../"?

Is there an alternative solution to my problem (that doesn't mean 
modifying the build system :) ).

Many thanks,

Glen 


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: emacs, jumping to relative file locations in compiler output.
  2014-03-27 12:14 emacs, jumping to relative file locations in compiler output glen stark
@ 2014-03-27 12:26 ` glen stark
  2014-03-27 16:13   ` Pascal J. Bourguignon
  0 siblings, 1 reply; 3+ messages in thread
From: glen stark @ 2014-03-27 12:26 UTC (permalink / raw)
  To: help-gnu-emacs

On Thu, 27 Mar 2014 12:14:57 +0000, glen stark wrote:

> In the company I'm working for, the build system is set up to cd in
> various directories, and the call make.    When a compiler error is
> returned, it is of the form:
> 
> In file included from ../../../../include/whatever.h:33:0
> 
> emacs is then unable to determine where to look for the file in
> question.
> 
> Changing out build system is big project, but I'd like to be able to
> jump around to compiler errors in emacs.  In practice I know what path I
> should substitute for "../../../../"
> 
> Is there someway I can tell emacs to regex substitute a fixed path for a
> string of the form "../../"?
> 
> Is there an alternative solution to my problem (that doesn't mean
> modifying the build system :) ).
> 
> Many thanks,
> 
> Glen

Sorry, I have a follow up:

After reading more on the subject, I think the path is not the issue.  We 
are outputing "Entering X" and "Leaving x" messages, so I guess emacs 
should be able to handle this.

  The problem might be that the string with the error looks like this:  
EE=../../../../include/Check.h: In function 'Bool check::isNull(UShort)':

If I look at plain old g++ output, I don't see the EE.  So perhaps this 
is the problem?


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: emacs, jumping to relative file locations in compiler output.
  2014-03-27 12:26 ` glen stark
@ 2014-03-27 16:13   ` Pascal J. Bourguignon
  0 siblings, 0 replies; 3+ messages in thread
From: Pascal J. Bourguignon @ 2014-03-27 16:13 UTC (permalink / raw)
  To: help-gnu-emacs

glen stark <g.a.stark@gmail.com> writes:

> On Thu, 27 Mar 2014 12:14:57 +0000, glen stark wrote:
>
>> In the company I'm working for, the build system is set up to cd in
>> various directories, and the call make.    When a compiler error is
>> returned, it is of the form:
>> 
>> In file included from ../../../../include/whatever.h:33:0
>> 
>> emacs is then unable to determine where to look for the file in
>> question.
>> 
>> Changing out build system is big project, but I'd like to be able to
>> jump around to compiler errors in emacs.  In practice I know what path I
>> should substitute for "../../../../"
>> 
>> Is there someway I can tell emacs to regex substitute a fixed path for a
>> string of the form "../../"?
>> 
>> Is there an alternative solution to my problem (that doesn't mean
>> modifying the build system :) ).
>> 
>> Many thanks,
>> 
>> Glen
>
> Sorry, I have a follow up:
>
> After reading more on the subject, I think the path is not the issue.  We 
> are outputing "Entering X" and "Leaving x" messages, so I guess emacs 
> should be able to handle this.
>
>   The problem might be that the string with the error looks like this:  
> EE=../../../../include/Check.h: In function 'Bool check::isNull(UShort)':
>
> If I look at plain old g++ output, I don't see the EE.  So perhaps this 
> is the problem?

You can configure regexps to scan the compiler output.

cf. compilation-error-regexp-alist
and compilation-error-regexp-alist-alist
see also compilation-search-path

-- 
__Pascal Bourguignon__
http://www.informatimago.com/
"Le mercure monte ?  C'est le moment d'acheter !"




^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2014-03-27 16:13 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-03-27 12:14 emacs, jumping to relative file locations in compiler output glen stark
2014-03-27 12:26 ` glen stark
2014-03-27 16:13   ` Pascal J. Bourguignon

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.