Datasheet
C and C++ Compilers
2-4 Copyright © 1999-2001 ARM Limited. All rights reserved. ARM DUI 0067D
2.2 File usage
This section describes naming conventions and included files.
2.2.1 Naming conventions
The ARM compilers use suffix naming (filename-extension) conventions to identify the
classes of file involved in compilation and in the linking process. The names used on
the command line, and as arguments to preprocessor
#include
directives, map directly
to host file names under UNIX and Windows/MS-DOS.
The ARM compilers use or generate files with the following file suffixes:
filename.c
ARM C compilers recognize the
.c
suffix as source files.
ARM C++ compilers recognize
.c
,
.cpp
,
.cp
,
.c++
, and
.cc
suffixes as source files.
filename.h
Header file (a convention only, this suffix has no special
significance for the compiler).
filename.o
ARM object file in ELF format.
filename.s
ARM or Thumb assembly language file. (This can be placed in the
input file list or, with the
-S
option, produced as an output file from
the C and C++ compilers.)
filename.lst
Error and warning list file (the default output extension for
-list
option).
Portability
The ARM compilers support multiple file-naming conventions on all supported hosts.
To ensure portability between hosts, use the following guidelines:
• Ensure that filenames do not contain spaces. If you have to use pathnames or
filenames containing spaces, enclose the path and filename in quotes.
• Make embedded pathnames relative rather than absolute.
In each host environment, the compilers support:
• native filenames
• pseudo UNIX filenames in the format:
host-volume-name:/rest-of-unix-file-name
• UNIX filenames using
/
as apath separator.