Adding a file to a project [message #177827] |
Fri, 09 January 2004 14:33  |
Eclipse User |
|
|
|
Originally posted by: erik.rogind.com
I must be missing something.
I would simply like to add a C++ file from a "common" directory into a C++
project, and not force the inclusion of all C++ files from that "common"
directory to be included in my project.
How do I do this? If I click Project Properties | Compiler | Extra Source
Paths, and add the "common" directory, then ALL C++ files in the common
directory are included. Not the intended result.
There should be a simple "Add File to Project" (where that file is not in
the project directory)
Can anyone help?
Thanks.
|
|
|
|
Re: Adding a file to a project [message #177841 is a reply to message #177835] |
Fri, 09 January 2004 14:53   |
Eclipse User |
|
|
|
Originally posted by: erik.rogind.com
Thanks Pabo,
Your idea works. However, this copies the file into the project from the
common directory, creating multiple copies of a single class file, one for
each project that uses it. This is NOT the intended effect. I would simply
like to include the source file from the common directory path where it
lives.... leave it there. (A link would be acceptable). Such that there
exists only a single copy of this class file.
Any other ideas?
Thanks.
"Pablo Escobar" <pablo@intiwawa.net> wrote in message
news:pan.2004.01.09.19.43.52.764231@intiwawa.net...
> Hello,
>
> > I must be missing something.
> > I would simply like to add a C++ file from a "common" directory into a
C++
> > project, and not force the inclusion of all C++ files from that "common"
> > directory to be included in my project.
> > How do I do this? If I click Project Properties | Compiler | Extra
Source
> > Paths, and add the "common" directory, then ALL C++ files in the common
> > directory are included. Not the intended result.
> > There should be a simple "Add File to Project" (where that file is not
in
> > the project directory)
> > Can anyone help?
> > Thanks.
>
> try in the Explorer view:
> right-click on project -> import -> File System -> Next -> (make your
> election)
>
> Hope could help you.
>
> Greetings,
>
> Pablo
>
>
|
|
|
|
Re: Adding a file to a project [message #177862 is a reply to message #177848] |
Fri, 09 January 2004 15:18   |
Eclipse User |
|
|
|
Originally posted by: erik.rogind.com
Thanks again, Pablo.
I have no such "advanced | link" option under new | file. Perhaps I have an
older version of eclipse? I am using QNX Momentics version 2.0, which seems
to be built ontop of Eclipse 2.0.2.
Any other ideas? I notice that "Software Upgrades" links to
www/qnx.com/updates, which hangs.
How painful will a Eclipse/Momentics update be... If it is possible?
"Pablo Escobar" <pablo@intiwawa.net> wrote in message
news:pan.2004.01.09.20.00.19.676946@intiwawa.net...
> Yes,
>
> > Thanks Pabo,
> > Your idea works. However, this copies the file into the project from the
> > common directory, creating multiple copies of a single class file, one
for
> > each project that uses it. This is NOT the intended effect. I would
simply
> > like to include the source file from the common directory path where it
> > lives.... leave it there. (A link would be acceptable). Such that there
> > exists only a single copy of this class file.
> > Any other ideas?
> > Thanks.
> >
>
> try this:
> in the navigator view, at the place you want your link, right-click -> new
> -> file -> advanced -> choose link your file ... and so on.
>
> >>
> >> Hope could help you.
> >>
> >> Greetings,
> >>
> >> Pablo
> >>
> >>
>
|
|
|
|
Re: Adding a file to a project [message #178685 is a reply to message #177862] |
Mon, 12 January 2004 13:09  |
Eclipse User |
|
|
|
Originally posted by: Michael_Valenta.oti.com
Erik,
Linked resources were introduced in Eclipse 2.1 so you would need to get
an updated software product from QNX to use links. It would be best to
contact QNX (or ask on one of their mailing lists/newsgroups if they
have them) to see how to go about this.
However, resources can only be linked as direct childen of the project
so this would only help you out if you wanted the file to be a direct
child of your project. You could still link a parent directory of the
file but all children would be included. I believe the intention is that
tools in Eclipse would provide their own mechanism for excluding files.
Java provides such a mechanism but I don't know if CDT does. You could
post a questions on the CDT newsgroup to find out.
Michael
Erik Rogind wrote:
> Thanks again, Pablo.
> I have no such "advanced | link" option under new | file. Perhaps I have an
> older version of eclipse? I am using QNX Momentics version 2.0, which seems
> to be built ontop of Eclipse 2.0.2.
> Any other ideas? I notice that "Software Upgrades" links to
> www/qnx.com/updates, which hangs.
> How painful will a Eclipse/Momentics update be... If it is possible?
>
>
> "Pablo Escobar" <pablo@intiwawa.net> wrote in message
> news:pan.2004.01.09.20.00.19.676946@intiwawa.net...
>
>>Yes,
>>
>>
>>>Thanks Pabo,
>>>Your idea works. However, this copies the file into the project from the
>>>common directory, creating multiple copies of a single class file, one
>>>
> for
>
>>>each project that uses it. This is NOT the intended effect. I would
>>>
> simply
>
>>>like to include the source file from the common directory path where it
>>>lives.... leave it there. (A link would be acceptable). Such that there
>>>exists only a single copy of this class file.
>>>Any other ideas?
>>>Thanks.
>>>
>>>
>>try this:
>>in the navigator view, at the place you want your link, right-click -> new
>>-> file -> advanced -> choose link your file ... and so on.
>>
>>
>>>>Hope could help you.
>>>>
>>>>Greetings,
>>>>
>>>>Pablo
>>>>
>>>>
>>>>
>
>
|
|
|
Powered by
FUDForum. Page generated in 0.04475 seconds