qconfig.mk macros

Here's a summary of the macros available from qconfig.mk:

CP_HOST
Copy files from one spot to another.
LN_HOST
Create a symbolic link from one file to another.
RM_HOST
Remove files from the filesystem.
TOUCH_HOST
Update a file's access and modification times.
PWD_HOST
Print the full path of the current working directory.
CL_ which
Compile and link.
CC_ which
Compile C/C++ source to an object file.
AS_ which
Assemble something to an object file.
AR_ which
Generate an object file library (archive).
LR_ which
Link a list of objects/libraries to a relocatable object file.
LD_ which
Link a list of objects/libraries to a executable/shared object.
UM_ which
Add a usage message to an executable.

The which parameter can be either the string HOST for compiling something for the host system or a triplet of the form os _ cpu _ compiler to specify a combination of target OS and CPU, as well as the compiler to be used.

The os is usually the string nto to indicate Neutrino. The cpu is one of x86, mips, ppc, arm or sh. Finally, the compiler is usually gcc.

For example, you could use the macro CC_nto_x86_gcc to specify:

The following macro contains the command-line sequence required to invoke the GCC compiler:

CC_nto_x86_gcc = qcc -Vgcc_ntox86 -c

The various makefiles use the CP_HOST, LN_HOST, RM_HOST, TOUCH_HOST, and PWD_HOST macros to decouple the OS commands from the commands used to perform the given actions. For example, under most POSIX systems, the CP_HOST macro expands to the cp utility. Under other operating systems, it may expand to something else (e.g. copy).

In addition to the macros mentioned above, you can use the following macros to specify options to be placed at the end of the corresponding command lines:

The parameter "which" is the same as defined above: either the string "HOST" or the ordered triplet defining the OS, CPU, and compiler.

For example, specifying the following:

CCPOST_nto_x86_gcc = -ansi

causes the command line specified by CC_nto_x86_gcc to have the additional string "-ansi" appended to it.