Invoking Command-Line Tools

To compile, assemble, link, or perform some other programming task with the CodeWarrior command-line tools, you type a command at a command line's prompt. This command specifies the tool you want to run, what options to use while the tool runs, and what files the tool should operate on. For example,
  tool options files  

Where tool is the name of the CodeWarrior command-line tool to invoke, options is a list of zero or more options that specify to the tool what operation it should perform and how it should be performed, and files is a list of files zero or more files that the tool should operate on.

Which options and files you should specify depend on what operation you want the tool to perform.

The tool then performs the operation on the files you specify. If the tool is successful it simply finishes its operation and a new prompt appears at the command line. If the tool encounters problems it reports these problems as text messages on the command-line before a new prompt appears.

Scripts that automate the process to build a piece of software contain commands to invoke command-line tools. For example, the make tool, a common software development tool, uses scripts to manage dependencies among source code files and invoke command-line compilers, assemblers and linkers as needed.

Same can be done using response file.

  tool [@response_file] OR tool [@@response_file]  

Where response_file is used to insert command-line arguments from a file.

The response file is parsed such that arguments are separated by whitespace except where surrounded by quote marks. Anything followed by a pound character '#' is used to indicate the rest of the line is a comment. Use '\#' in a response file if an argument actually starts with '#'.

The @ option will make sure the response file content is used "as is", whereas a @@ specification will ensure that environment variables in the response file contents are expanded. Note that only one level of environment variable expansion is performed. Environment variable that expands to another variable-like syntax reamin unchanged. For example, in FOO='$BAR', $FOO expands to $BAR, where as $BAR is not expanded.

Any of the following syntax can be used to recognize environment variables:

Points to remember::