Portable Projects: Difference between revisions

From DSignT Support Database
Jump to navigationJump to search

(Pushed from DSignT Issue Database.)
 
(Pushed from DSignT Issue Database.)
 
(2 intermediate revisions by the same user not shown)
Line 1: Line 1:
=== Problem ===
== Problem ==
CCS4 projects store absolute paths. Moving a project to a different directory or another computer is not possible.
CCS4 projects store absolute paths. Moving a project to a different directory or another computer is not possible.


=== Solution ===
 
{{pagetop}}
== Solution ==
This example assumes the following directory structure:
This example assumes the following directory structure:
  CCS_projects
  CCS_projects
Line 17: Line 19:




* create a file macros.ini in the project directory (current_project in the above example). This file must contain an entry SWROOT = ../../  <br /> SWROOT now points to the project base directory (CCS_projects in the above example). You can of course select a different name.
* create a file macros.ini in the project directory (current_project in the above example). This file must contain an entry EXT_ROOT__current_project = ../../  <br /> EXT_ROOT__current_project now points to the project base directory (CCS_projects in the above example). To give highest compatibility even for later CCS releases, this macro should always start with a leading ''EXT_ROOT__'' and end with the trailing project name.
    
    
* make sure all source files include header files with a relative path, or add the include path in the project settings:
* make sure all source files include header files with a relative path, or add the include path in the project settings:
Line 24: Line 26:
   #include <dmodule/dm2c6747.h>
   #include <dmodule/dm2c6747.h>


* edit the .project file in the project directory (current_project in the above example) and replace the absolute paths with the SWROOT macro. Replace the <location> tag
* edit the .project file in the project directory (current_project in the above example) and replace the absolute paths with the EXT_ROOT__current_project macro. Replace the <location> tag
   <linkedResources>
   <linkedResources>
     <link>
     <link>
Line 33: Line 35:
   </linkedResources>
   </linkedResources>
with
with
       <location>SWROOT/dmodule/dm2c6747.cmd</location>
       <location>EXT_ROOT__current_project/dmodule/dm2c6747.cmd</location>
 
* Use ${EXT_ROOT__current_project} in the Build Properties to add include paths and/or call programs for post-build steps:
  Build Properties - Tool Settings - C6000 Compiler - Include Options = ${EXT_ROOT__current_project}
  ${EXT_ROOT__current_project}/utils/makehex ${BuildArtifactFileBaseName}
 
 
== Additional Tags ==
http://www.dsignt.de/support/doc/portable_ccs_projects/html/index.html
 
[[Migrating C2000 Projects from CCSv3.3 to CCSv4|Migrating old projects]]


* Use ${SWROOT} in the Build Properties to add include paths and/or call programs for post-build steps:
[[CCS4 open old CCS3 DSP/BIOS project]]
  Build Properties - Tool Settings - C6000 Compiler - Include Options = ${SWROOT}
  ${SWROOT}/utils/makehex ${BuildArtifactFileBaseName}


[[Import old CCS project]]


[[category:CCS4 Usage]]
[[category:CCS4 Usage]]

Latest revision as of 15:12, 22 June 2012

Problem

CCS4 projects store absolute paths. Moving a project to a different directory or another computer is not possible.


Arr u.png    back to top

Solution

This example assumes the following directory structure:

CCS_projects
    |
    +--- dmodule (D.Module specific headers and linker command files)
    |
    +--- common (libs, headers, etc)
    |
    +--- utils 
    |
    +--- myprojects
    |        |
    |        +--- current_project (source files)


  • create a file macros.ini in the project directory (current_project in the above example). This file must contain an entry EXT_ROOT__current_project = ../../
    EXT_ROOT__current_project now points to the project base directory (CCS_projects in the above example). To give highest compatibility even for later CCS releases, this macro should always start with a leading EXT_ROOT__ and end with the trailing project name.
  • make sure all source files include header files with a relative path, or add the include path in the project settings:
 #include "../../dmodule/dm2c6747.h"

or, if the base directory CCS_projects is added to the project include options:

 #include <dmodule/dm2c6747.h>
  • edit the .project file in the project directory (current_project in the above example) and replace the absolute paths with the EXT_ROOT__current_project macro. Replace the <location> tag
 <linkedResources>
   <link>
     <name>dm2c6747.cmd</name>
     <type>1</type>
     <location>d:/work/ccs_projects/dmodule/dm2c6747.cmd</location>
   </link>
 </linkedResources>

with

     <location>EXT_ROOT__current_project/dmodule/dm2c6747.cmd</location>
  • Use ${EXT_ROOT__current_project} in the Build Properties to add include paths and/or call programs for post-build steps:
 Build Properties - Tool Settings - C6000 Compiler - Include Options = ${EXT_ROOT__current_project}
 ${EXT_ROOT__current_project}/utils/makehex ${BuildArtifactFileBaseName}


Additional Tags

http://www.dsignt.de/support/doc/portable_ccs_projects/html/index.html

Migrating old projects

CCS4 open old CCS3 DSP/BIOS project

Import old CCS project



Contact Post.png Support Tool.png