Skip to main content



      Home
Home » Language IDEs » C / C++ IDE (CDT) » Absolute paths and project sharing
Absolute paths and project sharing [message #180147] Thu, 23 November 2006 04:07 Go to next message
Eclipse UserFriend
Hi,

I have created a managed make CDT project successfully in my computer.
I'm using Windows.
But when I copied the project to another computer the following problems
have arisen:

- org.eclipse.cdt.managedbuilder.core.prefs has hardcoded the absolute
paths to MinGW. The other computer has MinGW installed in other path.
Both computers have different drive letter assignments, so they must be
installed on different paths. I have entered this settings also in global
preferences. Why is this setting stored in the project instead of on the
workspace?

- *.launch files used to debug my executable has hardcoded the path to
GDB. It would be interesting to have this setting in global preferences
(even though it could be overriden in the launch file).

What do you think?

Regards
David
Re: Absolute paths and project sharing [message #180155 is a reply to message #180147] Thu, 23 November 2006 06:30 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: dmsubs.NOSPAM.consertum.com

Projects are not designed to be copied across machines. You need to Export it to
the file system, copy the exported directory (or archive) to the new machine and
then Import it to your new workspace.

I suggest using an Eclipse variable instead of hardcoding a path. Suggest you
use something like ${env_var:ENV_VAR_NAME}.

Note: Eclipse variables aren't well documented, but you can find a list from
Run->Debug, Environment (tab)-> New (button)-> Edit (dialog) -> Variables (dialog)

HTH
--
Derek


David Pérez wrote:
> Hi,
>
> I have created a managed make CDT project successfully in my computer.
> I'm using Windows.
> But when I copied the project to another computer the following problems
> have arisen:
>
> - org.eclipse.cdt.managedbuilder.core.prefs has hardcoded the absolute
> paths to MinGW. The other computer has MinGW installed in other path.
> Both computers have different drive letter assignments, so they must be
> installed on different paths. I have entered this settings also in
> global preferences. Why is this setting stored in the project instead
> of on the workspace?
>
> - *.launch files used to debug my executable has hardcoded the path to
> GDB. It would be interesting to have this setting in global preferences
> (even though it could be overriden in the launch file).
>
> What do you think?
>
> Regards
> David
>
Re: Absolute paths and project sharing [message #180168 is a reply to message #180155] Thu, 23 November 2006 09:39 Go to previous messageGo to next message
Eclipse UserFriend
Thanks Derek for your quick response.
The env var trick is good.
With JDT you specify once the JVM locations, and this info isn't coded in
the project file. I have the project file under a source control system.
This idea could also be used for CDT.


Derek Morris wrote:

> Projects are not designed to be copied across machines. You need to Export
it to
> the file system, copy the exported directory (or archive) to the new machine
and
> then Import it to your new workspace.

> I suggest using an Eclipse variable instead of hardcoding a path. Suggest
you
> use something like ${env_var:ENV_VAR_NAME}.

> Note: Eclipse variables aren't well documented, but you can find a list from
> Run->Debug, Environment (tab)-> New (button)-> Edit (dialog) -> Variables
(dialog)

> HTH
Re: Absolute paths and project sharing [message #180322 is a reply to message #180168] Fri, 24 November 2006 05:47 Go to previous message
Eclipse UserFriend
David,

you could also specify workspace variables, they are evaluated in the
Managed Build System. But this is not fundamentally different from
Environment variables. Just a different place to put the variable, but
certainly outside of the project.


Cheers,


Norbert
Previous Topic:How to Generate .map and .19 files with Managed Make
Next Topic:How to Replacing the Command Line Generator
Goto Forum:
  


Current Time: Thu May 08 09:51:50 EDT 2025

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

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

Back to the top