Projects - Command Line Build/Create
From Texas Instruments Embedded Processors Wiki
Contents |
Overview
Code Composer has several DOS commands you can use to create, build, and import information into its projects:
- Create a Project
- Build a Project
- Import a CCSv4/Eclipse Project
- Import a Legacy Project
Prior to using any of these commands, you must first change your working directory to the Code Composer Eclipse folder. For a default Code Composer installation, this command would be something similar to:
cd C:\Program Files\Texas Instruments\CCSv4\eclipse
Create a Project
Usage:
jre\bin\java -jar startup.jar -data <workspace_path> -application com.ti.ccstudio.apps.projectCreate -ccs.name -ccs.device [-options]
Options:
(Options listed are up to date as of CCS v4.1) -ccs.name <name> The name of the new project. -ccs.location <dir> The filesystem location of the project, if it is to be created outside of workspace (optional). -ccs.kind <id> The project kind ID (optional). Defaults to 'executable'. A list of all available project kind IDs will be printed if this argument is not recognized. -ccs.device <id> The device-variant ID. A list of all available device-variant IDs will be printed if this argument is missing or not recognized. -ccs.endianness <name> The device endianness (optional). Defaults to device-specific setting, if defined. A list of all applicable endianness types will be printed if this argument is not recognized. -ccs.cgtVersion <version> Code-generation tools version (optional). Defaults to highest applicable version. -ccs.outputFormat (coff | elf) The output-format (optional). Defaults to device-specific setting, if defined, or 'coff'. -ccs.cmd <file> Linker command file to be physically copied into the project (optional). Defaults to device-specific setting, if defined. -ccs.rts <file> Runtime support library (optional). Defaults to device-specific setting, if defined. -ccs.asmOnly Create an 'assembly-only' project (optional). -ccs.configurations <name1>[ <name2>]* Space-separated list of build-configurations to create (optional). Defaults to 'Debug Release'. -ccs.references <name1>[ <name2>]* Space-separated list of project-references to add to created project (optional). -ccs.artifactName <name> Name of the build-artifact (optional). Defaults to the name of the project. -ccs.artifactExtension <ext> Extension of the build-artifact (optional). Defaults to 'out'. -ccs.listBuildOptions Prints a list of all applicable build-options (optional). Does not actually create the project. -ccs.setCompilerOptions "<options>" [@configurations <name1>[ <name2>]*] Space-separated list of build-options to set on the created project's compiler tool (optional). (use backslash '\' to escape all double-quotes in <options>). Optionally, specify a list of build-configurations in which these options are to be set. -ccs.setLinkerOptions "<options>" [@configurations <name1>[ <name2>]*] Similar to -ccs.setCompilerOptions -ccs.setAssemblerOptions "<options>" [@configurations <name1>[ <name2>]*] Similar to -ccs.setCompilerOptions Applicable only when -ccs.cgtVersion is 'GNU'. -ccs.setPreBuildStep "<command>" [@configurations <name1>[ <name2>]*] Command to be used as a pre-build step (optional). Optionally, specify a list of build-configurations in which this build-step is to be set. -ccs.setPostBuildStep "<command>" [@configurations <name1>[ <name2>]*] Command to be used as a post-build step (optional). Optionally, specify a list of build-configurations in which this build-step is to be set. -ccs.copyFile <file> [@dir <dir>] [@configurations [<name> ]*] Copies the given file/directory into the project upon creation (optional). Optionally, specify a project-relative directory as the file's destination. Optionally, specify a list of build-configurations in which this file is to be used. -ccs.linkFile <file> [@dir <dir>] [@configurations [<name> ]*] Links the given file/directory into the project upon creation (optional). Optionally, specify a project-relative directory as the file's destination. Optionally, specify a list of build-configurations in which this file is to be used. -ccs.definePathVariable <name> <value> Defines the given path-variable for resolving portable linked file paths (optional). -ccs.overwrite (full | keep) Forces overwrite of existing file-system resources (optional). A 'full' overwrite would delete and recreate the entire existing project folder. A 'keep' overwrite would keep all existing filesystem project contents (applies only when workspace project does not exist). -ccs.listBuildOptionIDs Prints a list of all applicable build-option IDs (optional). Does not actually create the project. [Deprecated] - use -ccs.listBuildOptions -ccs.setBuildOption <id> "<value>" [@configurations <name1>[ <name2>]*] Sets the given build-option on the created project (optional). (use the wildcard '*' to match multiple characters in <id> and enum <value>'s). Optionally, specify a list of build-configurations in which this option is to be set. [Deprecated] - use -ccs.setCompilerOptions, -ccs.setLinkerOptions -ccs.args <file> File containing any extra arguments (optional). -ccs.help Print this help message. -rtsc.enableDspBios Enable DSP/BIOS support. -rtsc.biosVersion <version> DSP/BIOS tools version (optional). When '-rtsc.enableDspBios' argument is set, defaults to highest available version. -rtsc.enableRtsc Enable RTSC support. -rtsc.xdcVersion <version> XDCtools version (optional). When '-rtsc.enableRtsc' argument is set, defaults to highest available version.Examples
- Create a C64xx project 'newProject' at default location 'C:\myWorkspace\newProject\', leaving all other arguments at their defaults:
jre\bin\java -jar startup.jar -data "C:\myWorkspace" -application com.ti.ccstudio.apps.projectCreate -ccs.name newProject -ccs.device com.ti.ccstudio.deviceModel.C6000.GenericC64xxDevice
- Create a project as above, and also set some extra build-options (note the optional use of wildcard '*' in option-IDs):
jre\bin\java -jar startup.jar -data "C:\myWorkspace" -application com.ti.ccstudio.apps.projectCreate -ccs.name newProject -ccs.device com.ti.ccstudio.deviceModel.C6000.GenericC64xxDevice -ccs.setBuildOption com.ti.ccstudio.buildDefinitions.C6000_6.1.compilerID.QUIET_LEVEL com.ti.ccstudio.buildDefinitions.C6000_6.1.compilerID.QUIET_LEVEL.VERBOSE -ccs.setBuildOption com.ti.ccstudio.buildDefinitions.C6000_*.compilerID.DEFINE "DEBUG" -ccs.setBuildOption com.ti.ccstudio.buildDefinitions.*.compilerID.KEEP_ASM true
Create Standard Make Project
Usage:
jre\bin\java -jar startup.jar -data "C:\MyWorkspace" -application com.ti.ccstudio.apps.projectCreate_stdMake -ccs.name ProjectName [-options]
Options:
-ccs.name <name> | The name of the new project.<br> -ccs.location <dir> | The filesystem location of the project, if it is to be created outside of workspace (optional).<br> -ccs.buildLocation <path> | A project-relative folder to be used as the build-directory (optional).Defaults to project root-directory.<br> -ccs.buildCommand <path> | Absolute path to an alternative build utility (optional). Defaults to the gmake utility that is shipped with CCS.<br> -ccs.buildFlags <flags> | List of flags to override the default build-command flags (optional).<br> -ccs.makefileName <name> | Name of the makefile, if other than the gmake default 'makefile' (optional). Only used when the build-flags are not overridden.<br> -ccs.buildTarget <name> | Name of the target to run during an incremental build (optional). Defaults to 'all'.<br>-ccs.cleanTarget <name> | Name of the target to run during a clean build (optional). Defaults to 'clean'.<br> -ccs.references <name1>[ <name2>]* | Space-separated list of project-references to add to created project (optional).<br> -ccs.copyFile <file> [dir] | Copies the given file into the project upon creation (optional). Optionally, specify a project-relative directory as the file's destination.<br> -ccs.linkFile <file> [dir] | Links the given file into the project upon creation (optional). Optionally, specify a project-relative directory as the file's destination.<br> -ccs.definePathVariable <name> <value> | Defines the given path-variable for resolving portable linked file paths (optional).<br> -ccs.overwrite (full | keep) | Forces overwrite of existing file-system resources (optional). A 'full' overwrite would delete and recreate the entire existing project folder. A 'keep' overwrite would keep all existing filesystem project contents (applies only when workspace project does not exist). -ccs.args <file> | File containing any extra arguments (optional).<br> -ccs.help | Print this help message.<br>
Example
jre\bin\java -jar startup.jar -data ":\MyWorkspace" -application com.ti.ccstudio.apps.projectCreate_stdMake -ccs.name MyProject -ccs.location C:\MySourceFiles\Location -ccs.buildCommand "${project_loc}/pathToMyMakeUtility/gnumake.exe" -ccs.makefileName "makefile.mak" -ccs.buildTarget ALL -ccs.cleanTarget CLEAN -ccs.overwrite keep
Build a Project
Usage:
jre\bin\java -jar startup.jar -data <workspace_path> -application com.ti.ccstudio.apps.projectBuild (-ccs.projects | -ccs.workspace) [-options]
Options:
-ccs.configuration <name> | Build configuration name to build. Defaults to the active build configuration selected in the Code Composer interface. -ccs.projects <name1>[<name2>]* | Project names to build (a list separated by blanks). -ccs.workspace <name> | Build entire workspace (all projects in the CCS eclipse workspace) -ccs.clean | Perform a clean build. Defaults to full-build. -ccs.autoImport | Automatically import projects found in file system. -ccs.autoOpen | Automatically open any closed projects. -ccs.args <file> | Use an argument file containing any build project arguments listed in this topic. -ccs.help | Display command options help explanation on the command line
Examples
- Clean the active build-configuration of project 'newProject' without building it:
jre\bin\java -jar startup.jar -data "C:\myWorkspace" -application com.ti.ccstudio.apps.projectBuild -ccs.projects newProject -ccs.clean
- Rebuild the 'Debug' build-configuration of project 'newProject':
jre\bin\java -jar startup.jar -data "C:\myWorkspace" -application com.ti.ccstudio.apps.projectBuild -ccs.projects newProject -ccs.configuration Debug
- Rebuild the active build-configuration of all projects in the workspace:
jre\bin\java -jar startup.jar -data "C:\myWorkspace" -application com.ti.ccstudio.apps.projectBuild -ccs.workspace
Import a CCSv4 Project
Usage:
jre\bin\java -jar startup.jar -data <workspace_path> -application com.ti.ccstudio.apps.projectImport -ccs.location [-options] (See Notation Used)
Options:
(Options are up to date as of CCS v4.1) -ccs.configuration <name> The build-configuration name to build (optional). Defaults to active build-configuration. -ccs.projects <name1>[ <name2>]* Space-separated list of projects to build. -ccs.workspace Build entire workspace. -ccs.clean Perform a clean build (optional). Defaults to full-build. -ccs.autoImport Automatically import projects found in file-system (optional). -ccs.autoOpen Automatically open any closed projects (optional). -ccs.args <file> File containing any extra arguments (optional). -ccs.help Print this help message.
Examples
- Import an existing project:
jre\bin\java -jar startup.jar -data "C:\myWorkspace" -application com.ti.ccstudio.apps.projectImport -ccs.location "C:\Work\myProject"
- Import an existing project, and copy it into the workspace directory:
jre\bin\java -jar startup.jar -data "C:\myWorkspace" -application com.ti.ccstudio.apps.projectImport -ccs.location "C:\Work\myProject" -ccs.copyIntoWorkspace
Import a CCSv3 Project
Usage:
jre\bin\java -jar startup.jar -data <workspace_path> -application com.ti.ccstudio.apps.legacyProjectImport -ccs.location [-options] (See Notation Used)
Options:
(Options are up to date as of CCS v4.1) -ccs.location <path> Absolute path to the location containing the project. -ccs.definePathVariable <name> <value> Defines a general path-variable for resolving linked files in a portable way (optional). -ccs.copyIntoWorkspace Copy project folder and contents into the workspace directory (optional). Defaults to 'false'. -ccs.overwrite Forces overwrite of existing file-system resources (optional). -ccs.args <file> File containing any extra arguments (optional). -ccs.help Print this help message.Leave a Comment

