|
Introduction
The
probe(1)
command generates, installs and displays tool-specific probe information
for programming languages supported by the local system.
Probe information is generated as needed
(i.e., when it doesn't exist, when compiler-specific environment variables
change) and is shared among all users.
nmake(1)
references two types of probe information:
the make probe information and the preprocessor probe information,
described in the next sections.
make probe information
The make probe information is a makefile that is included by the default
nmake(1)
makerules.
The make probe information for the
cc
C compiler is listed by
probe -l C make cc
The
nmake
C
language probe information is in the form of variable definitions.
These variables are used to parameterize the default
makerules.
In the descriptions below
cc
means the path or name of the C compiler, and
positional
options are command options that may appear multiple times on the command line;
they enable/disable properties of operands to the right and usually appear
in pairs, one part to enable a property, and the other part to disable.
The
nmake
probe variables are:
- CC.CC
-
The absolute path of
cc.
- CC.NATIVE
-
The relative or absolute path of the native
cc.
The native
cc
generates execuatbles that may be run on the
execution host.
CC.NATIVE!=CC.CC
means
cc
is a cross compiler.
- CC.EXECTYPE
-
The
package(1)
hosttype of the native execution environment.
CC.EXECTYPE!=CC.HOSTTYPE
means
cc
is a cross compiler.
CC.HOSTTYPE
The
package(1)
hosttype of the target host execution environment.
- CC.ALTPP.FLAGS
-
The command line options that coax
cc
to use a different preprocessor.
If both
CC.ALTPP.FLAGS
and
CC.ALTPP.ENV
are null then
ppcc(1)
is used to force alternate preprocessors.
- CC.ALTPP.ENV
-
Environment variable definitions that coax
cc
to use a different preprocessor.
- CC.AR
-
The
ar(1)
command path.
- CC.ARFLAGS
-
Default options for the
ar(1)
command.
- CC.DEBUG
-
The
cc
options for generating objects and executables with debugging information.
Typically but not always
-g.
- CC.DIALECT
-
A list of
cc
dialect properties.
- ANSI
-
ANSI C function prototypes accepted.
- C++
-
cc
compiles C++.
- CROSS
-
cc
is a cross compiler: generated objects and executables not compatible
with the native architecture.
- DOTI
-
cc
treats input files with
.i
suffix as preprocessed source.
- DYNAMIC
-
cc
handles static and dynamic libraries.
- GNU
-
cc
is
gcc(1).
- IMPLICITC
-
cc
is C++ and infers implicit template definitions from
foo.c
given only
#include <foo.h>.
- LIBPP
-
The default preprocessor is the
ast
cpp(1)
based on
libpp(3).
- PTRIMPLICIT
-
cc
is C++ and generates a
ptr
subdirectory for implicit template definitions.
- TOUCHO
-
The link phase
(cc -o ...)
may touch the time stamps of object files
generated by a separate compile phase
(cc -c ...).
- VERSION
-
cc
and/or the runtime environment
handle version numbers in dynamic library suffixes.
- -dD
-
The
cc
-dD
option generates
-E
style output that includes
#define
and
#undef
statements.
- -I-
-
cc
handles the
-I-
that separates "..." and <...> include file search directories.
- -L
-
-Ldirectory
specifies directories to seacrh for static and dynamic libraries.
- CC.DLL
-
The
cc
options for generating objects that will be linked to make dlls
(shared libraries.)
- CC.DLLBIG
-
Similar to
CC.DLL,
but required on some systems for
large
dlls.
The definition of
large
is compiler/system specific.
- CC.DLL.DEF
-
Always set to
-D_BLD_DLL
and always included in
CC.DLL
and
CC.DLLBIG.
- CC.DLL.DIR
-
The runtime dlls (shared library) installation directory.
- CC.DLL.LIBRARIES
-
Additional libraries that must be included for all dynamic executable links.
- CC.DLL.VARIANTS
-
A space separated list of
hosttype:postfix:option
tuples that describes the architecture variants that must be generated
for preload libraries.
sgi
really screwed this one up.
- CC.DYNAMIC
-
The
cc
options to link dynamic executables.
- CC.EXPORT.DYNAMIC
-
cc
options that make main program symbols visible to shared libraries
and dlls loaded by
dlopen(3).
- CC.LD
-
The path to the
ld
associated with
cc.
CC.LD
The
ld(1)
command path.
- CC.LD.DYNAMIC
-
dll link time positional
cc
options to place subsequent object file arguments
in the dynamic portion of the generated dll.
- CC.LD.LAZY
-
Link time positional
cc
options to enable runtime lazy loading of dlls.
dlls marked lazyload will not be loaded at initial process start-up,
but instead will be delayed until the first binding to the object is made.
- CC.LD.NOLAZY
-
Link time positional
cc
options that disable
CC.LD.LAZY.
- CC.LD.ORIGIN
-
Link time
cc
options that enable runtime dll searching in the
../lib
directory relative to the directory of the main executable.
- CC.LD.RECORD
-
Link time positional
cc
options that enable recording of dlls dependencies not explicitly referenced
at link time.
- CC.LD.NORECORD
-
Link time positional
cc
options that disable
CC.LD.RECORD.
- CC.LD.RUNPATH
-
Link time
cc
options to set the
:
separated runtime dll lookup directory list.
The
nmake
action usage is $(CC.LD.RUNPATH)directory-list.
- CC.LD.STATIC
-
dll link time positional
cc
options to place subsequent object file arguments
in the static portion of the generated dll.
The static portion may be a static archive appended to the link time
path of the dll.
- CC.LD.STRIP
-
Link time
cc
options to generate stripped executables.
- CC.LIB.DLL
-
The dll link time method name.
The
nmake
:LIBRARY:
assertion always generates a static library from the member object files
and removes the object files from the current directory.
If a corresponding dll is also to be generated,
it is generated using the static library.
The dll method encodes how to build a dll from a static library.
Note that
static library
does not imply static linking: the
:LIBRARY:
assertion ensures that the static library for a dll contains object
file members suitable for either static or dynamic linking.
- export
-
The exported library symbols must be listed in a separate
exports
file that must appear before the static library in the
cc
dll link command line.
The exported symbols are determined by running
$(CC.NM) $(CC.NMFLAGS) static-library-path |
$(SED) $(CC.NMEDIT) -e '/^$(CC.PREFIX.SYMBOL)_STUB_/d' \
-e '/$(CC.PREFIX.SYMBOL)_already_defined$/d'
- option
-
The
CC.LIB.ALL
and
CC.LIB.UNDEF
options may be used to generate a dll from a static library.
- symbol
-
The exported library symbols must be listed in a separate object file
that must appear before the static library in the
cc
dll link command line.
The exported symbols are determined by running
$(CC.NM) $(CC.NMFLAGS) static-library-path |
$(SED) $(CC.NMEDIT) -e '/^$(CC.PREFIX.SYMBOL)_STUB_/d' \
-e '/$(CC.PREFIX.SYMBOL)_already_defined$/d'
- CC.LIB.ALL
-
Link time
cc
options that causes all members in subsequent static library arguments to
be linked.
- CC.LIB.UNDEF
-
Link time
cc
options that disables
CC.LIB.ALL
and enables default static library link semantics.
The default only links library members that supply definitions for
required symbols.
- CC.MAKE.OPTIONS
-
The default
makrules
MAKE_OPTIONS.
Usually null, but provided for debugging.
See
makerules(6)
for details.
- CC.NM
-
The
nm(1)
command path.
- CC.NMEDIT
-
sed(1)
command that extracts symbol names from
CC.NM
output.
- CC.NMFLAGS
-
Default
CC.NM
flags.
- CC.OPTIMIZE
-
Enable (trustworthy)
cc
optimization; usually
-O.
- CC.PIC
-
cc
options to compile position independent code.
PIC
is often enabled by default.
- CC.PICBIG
-
Similar to
CC.PIC,
but required on some systems for
large
dlls.
The definition of
large
is compiler/system specific.
- CC.READONLY
-
cc
options to enable readonly data generation.
The ANSI C
const
keyword makes
CC.READONLY
obsolete.
- CC.REPOSITORY
-
The C++ parameterized type repository directory name.
- CC.SHARED
-
The link time
cc
flags to generate shared libraries or dlls.
- CC.SHARED.LD
-
The
cc(1)
or
ld(1)
command path that generates shared libraries or dlls.
- CC.SHARED.REGISTRY
-
The link time
cc
flags that specify the shared library or dll symbol offset registry.
- CC.SHARED.REGISTRY.PATH
-
The path name of the shared library or dll symbol offset registry file.
- CC.SHELLMAGIC
-
Generated shell scripts must have this value as the first line.
- CC.SIZE
-
The
size(1)
command path.
- CC.STATIC
-
The
cc
options to link static executables.
- CC.STDINCLUDE
-
The default
cc
include directory search list.
- CC.STDLIB
-
The default
cc
library directory search list.
- CC.STRICT
-
The
cc
options that enable strict compliance messages.
- CC.STRIP
-
The
strip(1)
command path.
- CC.STRIP.FLAGS
-
Default
CC.STRIP
options .
- CC.PREFIX.ARCHIVE
-
The prefix for static archive libraries.
lib
for all systems.
- CC.PREFIX.DYNAMIC
-
The prefix for dynamic link time archive libraries.
These libraries contain thunks and a file name reference to a runtime dll.
lib
for
cygwin
and null otherwise.
- CC.PREFIX.SHARED
-
The prefix for runtime shared libraries or dlls.
cyg
for
cygwin,
null for
uwin,
and
lib
otherwise.
- CC.PREFIX.SYMBOL
-
The object file symbol prefix.
Typically
_
or null.
- CC.SUFFIX.ARCHIVE
-
The suffix for static archive libraries.
.a
for all systems.
- CC.SUFFIX.COMMAND
-
The command/executable suffix.
.exe
on win32 systems, null otherwise.
- CC.SUFFIX.DYNAMIC
-
The suffix for runtime shared libraries or dlls.
These libraries contain thunks and a file name reference to a runtime dll.
.dll
for
win32
and
mvs,
otherwise not used (and assumed to be the same as
CC.SUFFIX.SHARED.)
- CC.SUFFIX.LD
-
The suffix for link script and symbol import/export list files.
- CC.SUFFIX.OBJECT
-
The object file suffix.
- CC.SUFFIX.SHARED
-
The suffix for dynamic link time libraries.
These libraries contain thunks and a file name reference to a runtime dll.
.dll.a
for
cygwin
(note that the double suffix can break some code that attempts to extract
file base names),
.lib
for dll systems,
.x
for
mvs,
otherwise
.so
or
.sl
or other inventive permutations, catenations, truncations and abbreviations of
{ dynamic library link load object shared }
for systems where the link time and runtime shared libraries are the same.
- CC.SUFFIX.SOURCE
-
The
cc
source file suffix list.
The preferred suffix is leftmost in the list.
- CC.SUFFIX.STATIC
-
The suffix of the static counterpart of shared libraries.
- CC.WARN
-
The
cc
option to enable verbose warnings.
- CC.PREROOT
-
The
cc
preroot directory.
Preroots are a vestige of amdahl C compilers.
- CC.UNIVERSE
-
The default universe; typically
ast
or
bsd.
preprocessor probe information
The preprocessor probe information is a header that is included by the
ast
libpp(3)
C preprocessor.
The preprocessor probe information for the
cc
C compiler is listed by
probe -l C pp cc
|
|
Glenn Fowler |
|
|
Information and Software Systems Research |
|
|
AT&T Labs Research |
|
|
Florham Park NJ |
|
|
March 08, 2004 |
|