Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Language IDEs » C / C++ IDE (CDT) » changing "Problems" path
changing "Problems" path [message #235280] Mon, 29 June 2009 13:58 Go to next message
Eclipse UserFriend
Originally posted by: marco.binz.annax.ch

Hi,

I'm using Eclipse / CDT on Windows, my source files however are on a
linux server. We access the files with a network drive connecting to the
server using samba. Compilation is done on the server, using plink (a
"command line PuTTY".

Paths to files with errors or warnings are of corse returned by the
compiler in linux style, e.g. /home/Projects/Projectx/main.cpp
Since these paths are not known to Windows, I can't doubelick on a error
/ warning in the "Problems" view to jump to the problem.
Is there a way to tell Eclipse (or the error parser, or make, or...) to
change the path from /home/Projects/... to Q:\Projects\...?

Thanks
Marco
Re: changing "Problems" path [message #235294 is a reply to message #235280] Mon, 29 June 2009 18:27 Go to previous messageGo to next message
Andrew Gvozdev is currently offline Andrew GvozdevFriend
Messages: 257
Registered: July 2009
Senior Member
Marco Binz wrote:
> I'm using Eclipse / CDT on Windows, my source files however are on a
> linux server. We access the files with a network drive connecting to the
> server using samba. Compilation is done on the server, using plink (a
> "command line PuTTY".
> Paths to files with errors or warnings are of corse returned by the
> compiler in linux style, e.g. /home/Projects/Projectx/main.cpp
> Since these paths are not known to Windows, I can't doubelick on a error
> / warning in the "Problems" view to jump to the problem.
> Is there a way to tell Eclipse (or the error parser, or make, or...) to
> change the path from /home/Projects/... to Q:Projects...?

Doubleclick will work only for paths which are in eclipse workspace. In
CDT 6.0 eclipse can find absolute path in any workspace folder as long as
it ends with it (gotta be full path). I.e. you can create a project
"LinuxFiles" and link your Q:Projects/ folder to LinuxFiles/home/Projects/
(using New-Folder/Advanced/Link-to-folder-in-the-file-system) so you get
/home/Projects/Projectx/main.cpp in LinuxFiles project. If this is C++
project you'll get F3 code navigation to there as well. But beware that
network folder like that can slow things down as eclipse is eager to
refresh the whole workspace on builds.

Andrew
Re: changing "Problems" path [message #235299 is a reply to message #235294] Tue, 30 June 2009 08:56 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: marco.binz.annax.ch

Unfortunately, we're still working with Eclipse 3.4.1 / CDT 5.0.1 here,
so I tried to do it in the Project itself, not in a special "LinuxFiles"
project. But eclipse doesn't allow this, it says "Cannot create a link
to 'Q:\Projects' because it overlaps the location of the project that
contains the linked resource."

So guess I'm out of luck until we update to the new eclipse / cdt,
unless anyone has another idea?

Btw, F3 code navigation works, guess that relies on the data collected
by the indexer and not the compiler.

Marco

Andrew Gvozdev wrote:
> Doubleclick will work only for paths which are in eclipse workspace. In
> CDT 6.0 eclipse can find absolute path in any workspace folder as long
> as it ends with it (gotta be full path). I.e. you can create a project
> "LinuxFiles" and link your Q:Projects/ folder to
> LinuxFiles/home/Projects/ (using
> New-Folder/Advanced/Link-to-folder-in-the-file-system) so you get
> /home/Projects/Projectx/main.cpp in LinuxFiles project. If this is C++
> project you'll get F3 code navigation to there as well. But beware that
> network folder like that can slow things down as eclipse is eager to
> refresh the whole workspace on builds.
>
> Andrew
>
Re: changing "Problems" path [message #235313 is a reply to message #235299] Tue, 30 June 2009 13:03 Go to previous message
Andrew Gvozdev is currently offline Andrew GvozdevFriend
Messages: 257
Registered: July 2009
Senior Member
Marco Binz wrote:

> Unfortunately, we're still working with Eclipse 3.4.1 / CDT 5.0.1 here,
> so I tried to do it in the Project itself, not in a special "LinuxFiles"
> project. But eclipse doesn't allow this, it says "Cannot create a link
> to 'Q:Projects' because it overlaps the location of the project that
> contains the linked resource."
So you already got the files in your workspace. But it is not going to
work in CDT 5.0.X with absolute paths in output. It may find relative ones
with some luck.

> So guess I'm out of luck until we update to the new eclipse / cdt,
> unless anyone has another idea?
You can try to imitate directory structure on Windows filesystem starting
from root, i.e. place your files like Q:\home\Projects\Projectx\main.cpp.
This may allow to use "Open external location" from Problems View
(right-click on error/warning) - if you can see the full file name in the
description of the error. I think it has to be current drive, i.e. start
eclipse in a folder on Q: drive. But don't expect double-click to work.

I'd really advise to update to CDT 6.0. It's well worth it.

Andrew
Previous Topic:Starting debug session from command line
Next Topic:CDT Plug-in "dropins" folder problem
Goto Forum:
  


Current Time: Fri Apr 26 03:39:54 GMT 2024

Powered by FUDForum. Page generated in 0.03352 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top