This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Project Structure Theory: Source Code Locations and Portable Projects

I am looking for some thoughts on the best way to locate my source code files to achieve project portability.  I have read all of the wiki's and workshop materials for both CCSv4 and CCSv5, so I am not looking for a repeat of that information.  I do plan on using version control (CVSNT for the server), in case that influences your answer, but please don't focus your answer on CVSNT - I am mostly curious about project structure whether or not I even use CVSNT.  I plan on developing my projects on three different computers (home, office, lab), and want to keep the projects in-sync.  The absolute location of the project directory will be different on at least two of the computers.  Eventually, the development effort may be shared with other team members.

I have a set of source code files that I plan on using across many projects, as well as using the TI Stellarisware source code.  My plan is to use a linked resource variable to point to these locations and then link to any specific source files I need.  I think I understand this pretty well, though I still have a little confusion about whether the linked variable should be a workspace setting or a project setting?

Also, I have source code files that I plan on using mainly in this project, though some of them may eventually get pushed into one of the common directories.  So it seems that I could either put the source code in a directory separate from my project files/settings, and then create a linked variable; or I could put them all in my project directory.  Putting them in my project directory seems to be the most straightforward, but it is not clear to me that the files can be referenced "relative" to the project or whether they are "absolute"ly located.  How do I reference these files so that a project located at a different location (e.g. on a different computer) isn't broken by the absolute location difference?

Finally, I also have some files, such as the custom .cmd file for the project.  Should I treat these the same or different than the source files in regards to location/linking?  How about the target configuration file?

Thank you in advance for sharig your thoughts, opinions, experiences.

  • Hi Ivek,

    Ivek Engineer said:
    I think I understand this pretty well, though I still have a little confusion about whether the linked variable should be a workspace setting or a project setting?

    This is up to you. The benefit of setting the linked resource path variable at the workspace level is that you do not need to modify the project files. This can be useful if you have the project files in source control and do not wish to modify it just to set the linked resource path variable if it is specified in the project. Also you can also just set the variable once at the workspace level and have all the projects use it.

    Ivek Engineer said:
    Putting them in my project directory seems to be the most straightforward, but it is not clear to me that the files can be referenced "relative" to the project or whether they are "absolute"ly located.  How do I reference these files so that a project located at a different location (e.g. on a different computer) isn't broken by the absolute location difference?

    Source files in the project folder will be referenced via relative path to the project folder.

    Ivek Engineer said:
    Finally, I also have some files, such as the custom .cmd file for the project.  Should I treat these the same or different than the source files in regards to location/linking?  How about the target configuration file?

    I would treat these all the same as the source files. They are all files that are part of the project.

    Hope this helps

    ki