<!--  vim: set sw=2 sts=2 et ft=docbk:

  Part of the A-A-P recipe executive: Common Variables

  Copyright (C) 2002-2003 Stichting NLnet Labs
  Permission to copy and use this file is specified in the file COPYING.
  If this file is missing you can find it here: http://www.a-a-p.org/COPYING

-->

<para>
This is a complete list of the variables that are currently used inside &Aap;,
except the variables specifically used for porting, see
<xref linkend="user-porting"/> for that.
</para>
<para>
This list will be extended when more features are being added.
To avoid the problem that your own variables interfere with the use of common
&Aap; variables, do not use variable names with only upper case letters.
Suggested scheme:

<table frame="none">
  <title>Naming scheme for variables</title>
  <tgroup cols="2">
    <colspec colwidth="200"/>
    <tbody>
      <row>
        <entry>$STANDARD_VARIABLE</entry>
        <entry>global variable defined by &Aap;</entry>
      </row>
      <row>
        <entry>$YourVariable</entry>
        <entry>global variable used in your recipe(s)</entry>
      </row>
      <row>
        <entry>$local_variable</entry>
        <entry>local variable used in build commands</entry>
      </row>
    </tbody>
  </tgroup>
</table>
</para>

<para>
The following table lists the predefined variables.  These types are used:
<informaltable frame="none">
  <tgroup cols="2">
    <colspec colwidth="100"/>
    <tbody>
      <row>
        <entry>&Aap;</entry>
        <entry>set by &Aap; and mostly not changed by the user</entry>
      </row>
      <row>
        <entry>conf</entry>
        <entry>set depending on the configuration of the system, may be
        modified by the user</entry>
      </row>
      <row>
        <entry>user</entry>
        <entry>set by the user</entry>
      </row>
      <row>
        <entry>auto</entry>
        <entry>value updated when using commands (e.g.,
        <computeroutput>:program</computeroutput>), may also
        be appended to by the user</entry>
      </row>
    </tbody>
  </tgroup>
</informaltable>
</para>

<table frame="none">
  <title>Standard Variables</title>
  <tgroup cols="2">
    <colspec colwidth="170"/>
    <thead>
      <row>
        <entry>name</entry>
        <entry>type&nbsp;&nbsp;</entry>
        <entry>description</entry>
      </row>
    </thead>
    <tbody>

<row>
<entry valign="top"><anchor id="var-hash"/> $# </entry>
<entry valign="top"> &Aap; </entry>
<entry valign="top"> A single #.  OBSOLETE, use $(#) </entry>
</row>
<row>
<entry valign="top"><anchor id="var-dollar"/> $$ </entry>
<entry valign="top"> &Aap; </entry>
<entry valign="top"> A single $.  OBSOLETE, use $($) </entry>
</row>
<row>
<entry valign="top"><anchor id="var-aap"/> $AAP </entry>
<entry valign="top"> &Aap; </entry>
<entry valign="top"> Command that was used to start &Aap;, including the Python
interpreter used.  Example:
<programlisting>
    :asroot $AAP install
</programlisting>
Note that this can be a command and an argument, e.g.:
"/usr/local/bin/python1.5 /usr/local/share/aap/Main.py".
</entry>
</row>
<row>
<entry valign="top"><anchor id="var-aapsysdir"/> $AAPSYSDIR </entry>
<entry valign="top"> conf </entry>
<entry valign="top"> List of system directories to search for startup recipes,
  modules and tools.  Default value is
  <filename>/usr/local/share/aap</filename>, although this may be different on
  some systems.  When the directory doesn't exist the default is empty.
</entry>
</row>
<row>
<entry valign="top"><anchor id="var-aapversion"/> $AAPVERSION </entry>
<entry valign="top"> &Aap; </entry>
<entry valign="top"> Version number of &Aap;.  E.g., 31 (version 0.031) or 1003 (version
1.003).  Also see <link linkend="var-versionstr">$VERSIONSTR</link>.
</entry>
</row>
<row>
<entry valign="top"><anchor id="var-ar"/> $AR </entry>
<entry valign="top"> conf </entry>
<entry valign="top"> Name of archiver program: combines object files into a static libray.
</entry>
</row>
<row>
<entry valign="top"><anchor id="var-arflags"/> $ARFLAGS </entry>
<entry valign="top"> user </entry>
<entry valign="top"> Arguments for $AR (default: "r" or "/nologo"). </entry>
</row>
<row>
<entry valign="top"><anchor id="var-bdir"/> $BDIR </entry>
<entry valign="top"> conf </entry>
<entry valign="top"> Directory to write build files in.  Modified by the
<link linkend="cmd-variant">:variant</link> command. </entry>
</row>
<row>
<entry valign="top"><anchor id="var-br"/> $BR </entry>
<entry valign="top"> &Aap; </entry>
<entry valign="top"> A line break. </entry>
</row>
<row>
<entry valign="top"><anchor id="var-browser"/> $BROWSER </entry>
<entry valign="top"> conf </entry>
<entry valign="top"> HTML browser to be used for the "view" action for HTML, XML and PHP
  files.  The default value
  comes from the "BROWSER" environment variable or a list of known browser
  commands (netscape mozilla konquerer grail iexplore mosaic lynx w3m).
</entry>
</row>
<row>
<entry valign="top"><anchor id="var-build-action"/> $BUILD_ACTION </entry>
<entry valign="top"> conf </entry>
<entry valign="top"> When not empty, specifies the action name to be executed for building.
  Usually for building a program from object files with a specific tool.
  A "buildaction" attribute on one of the object files is used before
  $BUILD_ACTION.
  See <xref linkend="user-tools"/>.</entry>
</row>
<row>
<entry valign="top"><anchor id="var-builddll-action"/> $BUILDDLL_ACTION </entry>
<entry valign="top"> conf </entry>
<entry valign="top"> When not empty, specifies the action name to be executed
  for building a dynamic (shared) library.
  A "buildaction" attribute on one of the object files should be respected by
  the action specified with $BUILDDLL_ACTION.
  See <xref linkend="user-tools"/>.</entry>
</row>
<row>
<entry valign="top"><anchor id="var-buildlib-action"/> $BUILDLIB_ACTION </entry>
<entry valign="top"> conf </entry>
<entry valign="top"> When not empty, specifies the action name to be executed
  for building a static library.
  A "buildaction" attribute on one of the object files should be respected by
  the action specified with $BUILDLIB_ACTION.
  See <xref linkend="user-tools"/>.</entry>
</row>
<row>
<entry valign="top"><anchor id="var-bunzip2"/> $BUNZIP2 </entry>
<entry valign="top"> conf </entry>
<entry valign="top"> Program to use for ".bz2" compressed files.  Default value
  is "bunzip2". </entry>
</row>
<row>
<entry valign="top"><anchor id="var-c-compile-action"/> $C_COMPILE_ACTION </entry>
<entry valign="top"> conf </entry>
<entry valign="top"> When not empty, specifies the action name to be executed for compiling
  a C file into an object, dllobject, libobject or ltobject file.  See
  <xref linkend="user-tools"/>.</entry>
</row>
<row>
<entry valign="top"><anchor id="var-cxx-compile-action"/> $CXX_COMPILE_ACTION </entry>
<entry valign="top"> conf </entry>
<entry valign="top"> When not empty, specifies the action name to be executed for compiling
  a C++ file into an object, dllobject, libobject or ltobject file.  See
  <xref linkend="user-tools"/>.</entry>
</row>
<row>
<entry valign="top"><anchor id="var-cachepath"/> $CACHEPATH </entry>
<entry valign="top"> conf </entry>
<entry valign="top"> List of directories to search for cached downloaded
    files.
Default for Unix:
<literallayout>    /var/aap/cache
    ~/.aap/cache
    aap/cache
</literallayout>
For MS-Windows, OS/2:
<literallayout>    $HOME/aap/cache
    aap/cache
</literallayout>
Directories that don't exist are skipped.
When using a relative name, it is relative to the
current recipe.  Thus the recipe specified with
<computeroutput>:child dir/main.aap</computeroutput> uses a different cache
directory.

When this variable is set, currently cached files are
flushed.  Otherwise this only happens when exiting.
Thus this command can be used to flush the cache:
<programlisting>
    CACHEPATH = $CACHEPATH
</programlisting>
</entry>
</row>
<row>
<entry valign="top"><anchor id="var-cacheupdate"/> $CACHEUPDATE </entry>
<entry valign="top"> user </entry>
<entry valign="top"> Timeout after which cached files may be downloaded again.  For the
possible values see the <link linkend="cache-update">explanation in the user
manual</link>. </entry>
</row>
<row>
<entry valign="top"><anchor id="var-cc"/> $CC </entry>
<entry valign="top"> conf </entry>
<entry valign="top"> Command to execute the C compiler (default: "cc"). </entry>
</row>
<row>
<entry valign="top"><anchor id="var-cflags"/> $CFLAGS </entry>
<entry valign="top"> user </entry>
<entry valign="top"> Arguments always used for $CC. NOTE: it's not $CCFLAGS!  This is
inconsistent, used for historic reasons.</entry>
</row>
<row>
<entry valign="top"><anchor id="var-childdir"/> $CHILDDIR </entry>
<entry valign="top"> &Aap; </entry>
<entry valign="top"> In a child recipe: The directory of the child recipe relative to the
parent recipe.  When using: :child subdir/main.aap $CHILDDIR will be "subdir"
in the child recipe. </entry>
</row>
<row>
<entry valign="top"><anchor id="var-cleandirs"/> $CLEANDIRS </entry>
<entry valign="top"> auto </entry>
<entry valign="top"> Names of directories that the "clean" target should remove. </entry>
</row>
<row>
<entry valign="top"><anchor id="var-cleanfiles"/> $CLEANFILES </entry>
<entry valign="top"> auto </entry>
<entry valign="top"> Names of files that the "clean" target should remove.
The <computeroutput>:program</computeroutput> command adds files to this. </entry>
</row>
<row>
<entry valign="top"><anchor id="var-cleanmoredirs"/> $CLEANMOREDIRS </entry>
<entry valign="top"> user </entry>
<entry valign="top"> Names of directories that the "cleanmore" target should remove.
</entry>
</row>
<row>
<entry valign="top"><anchor id="var-cleanmorefiles"/> $CLEANMOREFILES </entry>
<entry valign="top"> user </entry>
<entry valign="top"> Names of files that the "cleanmore" target should remove. </entry>
</row>
<row>
<entry valign="top"><anchor id="var-compile-action"/> $COMPILE_ACTION </entry>
<entry valign="top"> conf </entry>
<entry valign="top"> Obsolete.  See <link
    linkend="var-c-compile-action">$C_COMPILE_ACTION</link> and  <link
    linkend="var-cxx-compile-action">$CXX_COMPILE_ACTION</link>.
  </entry>
</row>
<row>
<entry valign="top"><anchor id="var-confdir"/> $CONFDIR </entry>
<entry valign="top"> &Aap; </entry>
<entry valign="top"> Sub-directory to install configuration files into. Default value:
"etc/".</entry>
</row>
<row>
<entry valign="top"><anchor id="var-confmode"/> $CONFMODE </entry>
<entry valign="top"> &Aap; </entry>
<entry valign="top"> Mode to use for installed configuration files. Default value: "0644"
(read/write for the user, readable for the group and others).</entry>
</row>
<row>
<entry valign="top"><anchor id="var-cppflags"/> $CPPFLAGS </entry>
<entry valign="top"> user </entry>
<entry valign="top"> Arguments for $CC when compiling sources (not when linking objects).
These are raw arguments, not always portable.  Use $INCLUDE and $DEFINE when
possible. </entry>
</row>
<row>
<entry valign="top"><anchor id="var-cvs"/> $CVS </entry>
<entry valign="top"> conf </entry>
<entry valign="top"> Cvs program to use.  No arguments are allowed.  May
  include spaces. When not set "cvs" is used. </entry>
</row>
<row>
<entry valign="top"><anchor id="var-cvscmd"/> $CVSCMD </entry>
<entry valign="top"> user </entry>
<entry valign="top"> Cvs command to use.  This overrules $CVS and may include
  arguments.  E.g. "cvs -z 9".  Spaces in the program name must be escaped as
  expected for the shell.  When not set $CVS is used. </entry>
</row>
<row>
<entry valign="top"><anchor id="var-cxx"/> $CXX </entry>
<entry valign="top"> conf </entry>
<entry valign="top"> Command for compiling C++ files </entry>
</row>
<row>
<entry valign="top"><anchor id="var-cxxflags"/> $CXXFLAGS </entry>
<entry valign="top"> user </entry>
<entry valign="top"> Arguments always used for $CXX. </entry>
</row>
<row>
<entry valign="top"><anchor id="var-shlink"/> $CXXSHLINK </entry>
<entry valign="top"> conf </entry>
<entry valign="top"> Name of linker used to combine object files from C++
  sources into a shared (dynamic)
library. Default value: "$CXX" for Unix, not used for MS-Windows. </entry>
</row>
<row>
<entry valign="top"><anchor id="var-shlinkflags"/> $CXXSHLINKFLAGS </entry>
<entry valign="top"> user </entry>
<entry valign="top"> Arguments for $CXXSHLINK.  Default value: "-shared" for
  Unix, not used for MS-Windows. </entry>
</row>
<row>
<entry valign="top"><anchor id="var-datadir"/> $DATADIR </entry>
<entry valign="top"> &Aap; </entry>
<entry valign="top"> Sub-directory to install data files into. Default value:
"share/".</entry>
</row>
<row>
<entry valign="top"><anchor id="var-datamode"/> $DATAMODE </entry>
<entry valign="top"> &Aap; </entry>
<entry valign="top"> Mode to use for installed data files.
Default value: "0644"
(read/write for the user, readable for the group and others).</entry>
</row>
<row>
<entry valign="top"><anchor id="var-datestr"/> $DATESTR </entry>
<entry valign="top"> &Aap; </entry>
<entry valign="top">Date as a string in the form "2002 Month 11".  This does not change
while &Aap; is running.
Also see <link linkend="var-timestr">$TIMESTR</link> and
<link linkend="var-gmtime">$GMTIME</link>.
</entry>
</row>
<row>
<entry valign="top"><anchor id="var-debug"/> $DEBUG </entry>
<entry valign="top"> user </entry>
<entry valign="top"> The kind of debugging to be done.  "yes" means debugging is enabled.
The variable is not set by default.
For an example see
<link linkend="build-variant">the tutorial</link>.</entry>
</row>
<row>
<entry valign="top"><anchor id="var-defaultcheck"/> $DEFAULTCHECK </entry>
<entry valign="top"> &Aap; </entry>
<entry valign="top"> Check to use when none is speficied.  Defaults to "md5", can be set to
"time" or "newer".  "time" means that a file is outdated when its timestamp is
different from when it was last used.  "newer" means a target is outdated when
one of the source files has a more recent timestamp.
Also see the <link linkend="check-attribute">check</link> attribute.
</entry>
</row>
<row>
<entry valign="top"><anchor id="var-defer-action-name"/> $DEFER_ACTION_NAME </entry>
<entry valign="top"> &Aap; </entry>
<entry valign="top"> Only available in the commands of an action: the name the
  action to which the work should be deferred.
</entry>
</row>
<row>
<entry valign="top"><anchor id="var-define"/> $DEFINE </entry>
<entry valign="top"> user </entry>
<entry valign="top"> Preprocessor symbols.  Used in the same place as
<link linkend="var-cppflags">$CPPFLAGS</link>. 
Form: "-DNAME" or "-DNAME=value".  The tools will convert this to the argument
the compiler actually uses. </entry>
</row>
<row>
<entry valign="top"><anchor id="var-destdir"/> $DESTDIR </entry>
<entry valign="top"> user </entry>
<entry valign="top"> Directory used to install in a different root directory.
  Useful for a "fake" install.
  Also see <link linkend="var-prefix">$PREFIX</link>.
</entry>
</row>
<row>
<entry valign="top"><anchor id="var-distdirs"/> $DISTDIRS </entry>
<entry valign="top"> &Aap; </entry>
<entry valign="top"> Names of directories that should be distributed as a whole.  If there
is one file in this directory that should not be distributed use $DISTFILES.
</entry>
</row>
<row>
<entry valign="top"><anchor id="var-distfiles"/> $DISTFILES </entry>
<entry valign="top"> auto </entry>
<entry valign="top"> Names of files that are used as a source in the recipe and should be
distributed.  The <computeroutput>:program</computeroutput> command adds files to this.
</entry>
</row>
<row>
<entry valign="top"><anchor id="var-dllcflags"/> $DLLCFLAGS </entry>
<entry valign="top"> user </entry>
<entry valign="top"> Extra arguments to compile a C program into a dynamic (shared) object
file.
The default is currently "-fPIC", but since that only works with gcc it
will soon be changed. </entry>
</row>
<row>
<entry valign="top"><anchor id="var-dllcxxflags"/> $DLLCXXFLAGS </entry>
<entry valign="top"> user </entry>
<entry valign="top"> Extra arguments to compile a C++ program into a dynamic (shared)
object file.
The default is currently "-fPIC", but since that only works with gcc it
will soon be changed. </entry>
</row>
<row>
<entry valign="top"><anchor id="var-dlldir"/> $DLLDIR </entry>
<entry valign="top"> &Aap; </entry>
<entry valign="top"> Sub-directory to install shared (dynamic) library files into.
Default value: "lib/".  </entry>
</row>
<row>
<entry valign="top"><anchor id="var-dllmode"/> $DLLMODE </entry>
<entry valign="top"> &Aap; </entry>
<entry valign="top"> Mode to use for installed shared (dynamic) library files.
Default value: "0755"
(readable and executable for everybody, writable for the user).</entry>
</row>
<row>
<entry valign="top"><anchor id="var-dllobjsuf"/> $DLLOBJSUF </entry>
<entry valign="top"> &Aap; </entry>
<entry valign="top"> Suffix for an object file to be included in a dynamic (shared)
library.  Default: ".o" for Unix, ".obj" for MS-Windows. </entry>
</row>
<row>
<entry valign="top"><anchor id="var-dllpre"/> $DLLPRE </entry>
<entry valign="top"> conf </entry>
<entry valign="top"> Prefix for a dynamic (shared) library.  Default: "lib" for Unix, empty
for others.</entry>
</row>
<row>
<entry valign="top"><anchor id="var-dllsuf"/> $DLLSUF </entry>
<entry valign="top"> conf </entry>
<entry valign="top"> Suffix for a dynamic (shared) library.  Default: ".dll" for
MS-Windows, ".so" for Unix. </entry>
</row>
<row>
<entry valign="top"><anchor id="var-editor"/> $EDITOR </entry>
<entry valign="top"> conf </entry>
<entry valign="top"> Editor to be used for the "edit" action.  The default value comes from
  the "VISUAL" or "EDITOR" environment variable.  When these are not defined
  it falls back to "vi" On Unix and "notepad" otherwise.
</entry>
</row>
<row>
<entry valign="top"><anchor id="var-execdir"/> $EXECDIR </entry>
<entry valign="top"> &Aap; </entry>
<entry valign="top"> Sub-directory to install programs files into.
Default value is "bin/".</entry>
</row>
<row>
<entry valign="top"><anchor id="var-execmode"/> $EXECMODE </entry>
<entry valign="top"> &Aap; </entry>
<entry valign="top"> Mode to use for installed programs. 
Default value: "0755"
(readable and executable for everybody, writable for the user).</entry>
</row>
<row>
<entry valign="top"><anchor id="var-exesuf"/> $EXESUF </entry>
<entry valign="top"> conf </entry>
<entry valign="top"> Suffix for an executable file.  Default value: ".exe" for MS-Windows,
empty for others.</entry>
</row>
<row>
<entry valign="top"><anchor id="var-gmtime"/> $GMTIME </entry>
<entry valign="top"> &Aap; </entry>
<entry valign="top"> Time in seconds since 1970 Jan 1. 
This always uses GMT, it ignores time zones and daylight saving.  But it
depends on the system time to be set correctly!  The value does not change
while &Aap; is running, it is the time when &Aap; was started.
Also see <link linkend="var-timestr">$TIMESTR</link> and
<link linkend="var-datestr">$DATESTR</link>.
</entry>
</row>
<row>
<entry valign="top"><anchor id="var-groupcount"/> $GROUPCOUNT </entry>
<entry valign="top"> &Aap; </entry>
<entry valign="top"> Number of files handled at a time for uploading,
  downloading and version control commands.  The default value is 20.  Set it
  to a smaller number when using big files.  Set it to a large number when you
  need to enter a password every time.
</entry>
</row>
<row>
<entry valign="top"><anchor id="var-hasgcc"/> $HASGCC </entry>
<entry valign="top"> conf </entry>
<entry valign="top"> Indicates whether gcc can be used to scan C sources for
  dependencies.  It is initialized empty.  When dependency scanning is to be
  done a configure check is run to see if $CC can be used for dependency
  checking.  $HASGCC is then set to "yes" or "no".  You can set $HASGCC to
  empty to force running the check again, set it to "no" to avoid using $CC
  for dependency checking or set it to "yes" to skip the configure check and
  use $CC for dependency checking.
</entry>
</row>
<row>
<entry valign="top"><anchor id="var-hasgccxx"/> $HASGCCXX </entry>
<entry valign="top"> conf </entry>
<entry valign="top"> Indicates whether gcc can be used to scan C++ sources for
  dependencies.  Just like
<link linkend="var-hasgcc">$HASGCC</link> does this for C.
</entry>
</row>

<row>
<entry valign="top"><anchor id="var-include"/> $INCLUDE </entry>
<entry valign="top"> user </entry>
<entry valign="top"> Directories to find include files.  Used in the same place as
<link linkend="var-cppflags">$CPPFLAGS</link>.
Form: "-Ipath".  The tools will convert this to the argument the
compiler actually uses. </entry>
</row>
<row>
<entry valign="top"><anchor id="var-includedir"/> $INCLUDEDIR </entry>
<entry valign="top"> &Aap; </entry>
<entry valign="top"> Sub-directory to install include files into. Default value:
"include/".</entry>
</row>
<row>
<entry valign="top"><anchor id="var-includemode"/> $INCLUDEMODE </entry>
<entry valign="top"> &Aap; </entry>
<entry valign="top"> Mode to use for installed include files.
Default value: "0644"
(read/write for the user, readable for the group and others).</entry>
</row>
<row>
<entry valign="top"><anchor id="var-infodir"/> $INFODIR </entry>
<entry valign="top"> &Aap; </entry>
<entry valign="top"> Sub-directory to install info files into. Default value: "info/".</entry>
</row>
<row>
<entry valign="top"><anchor id="var-infomode"/> $INFOMODE </entry>
<entry valign="top"> &Aap; </entry>
<entry valign="top"> Mode to use for installed info files.
Default value: "0644"
(read/write for the user, readable for the group and others).</entry>
</row>
<row>
<entry valign="top"><anchor id="var-ld"/> $LD </entry>
<entry valign="top"> conf </entry>
<entry valign="top"> Command to execute the linker.  The default is empty, in which case
$CC is used.  But for C++ object files (cxx_build action) the default is $CXX.
</entry>
</row>
<row>
<entry valign="top"><anchor id="var-ldflags"/> $LDFLAGS </entry>
<entry valign="top"> user </entry>
<entry valign="top"> Arguments for linking, before the object files. The default is
empty.</entry>
</row>
<row>
<entry valign="top"><anchor id="var-lex"/> $LEX </entry>
<entry valign="top"> &Aap; </entry>
<entry valign="top"> Program to turn a lex file into C.
The default is empty.
When the "lex" action is invoked &Aap; will search for "flex" and "lex" and
set $LEX to the found program.
</entry>
</row>
<row>
<entry valign="top"><anchor id="var-lexflags"/> $LEXFLAGS </entry>
<entry valign="top"> user </entry>
<entry valign="top"> Flags for $LEX. There is no default value.</entry>
</row>
<row>
<entry valign="top"><anchor id="var-lexpp"/> $LEXPP </entry>
<entry valign="top"> &Aap; </entry>
<entry valign="top"> Program to turn a lex++ file into C++.
The default is empty.
When the "lexpp" action is invoked &Aap; will search for "flex++", "lex++",
"flex" and "lex" and set $LEX to the found program.
</entry>
</row>
<row>
<entry valign="top"><anchor id="var-lexppflags"/> $LEXPPFLAGS </entry>
<entry valign="top"> user </entry>
<entry valign="top"> Flags for $LEXPP.  There is no default value.</entry>
</row>
<row>
<entry valign="top"><anchor id="var-libdir"/> $LIBDIR </entry>
<entry valign="top"> &Aap; </entry>
<entry valign="top"> Sub-directory to install static library files into. Default value:
"lib/".</entry>
</row>
<row>
<entry valign="top"><anchor id="var-libmode"/> $LIBMODE </entry>
<entry valign="top"> &Aap; </entry>
<entry valign="top"> Mode to use for installed static library files.
Default value: "0644"
(read/write for the user, readable for the group and others).</entry>
</row>
<row>
<entry valign="top"><anchor id="var-libobjsuf"/> $LIBOBJSUF </entry>
<entry valign="top"> conf </entry>
<entry valign="top"> Suffix for an object file to be included in a static library.  Default
value: ".o" for Unix, ".obj" for MS-Windows. </entry>
</row>
<row>
<entry valign="top"><anchor id="var-libpre"/> $LIBPRE </entry>
<entry valign="top"> conf </entry>
<entry valign="top"> Prefix for static library.  The default is empty on MS-Windows, "lib"
on Unix. </entry>
</row>
<row>
<entry valign="top"><anchor id="var-libs"/> $LIBS </entry>
<entry valign="top"> user </entry>
<entry valign="top"> Arguments for linking, after the object files.  Convention: Always use
"-lname", the tools will translate it into the flags that the linker actually
uses.  Also see <link linkend="var-ltlibs">$LTLIBS</link></entry>
</row>
<row>
<entry valign="top"><anchor id="var-libsuf"/> $LIBSUF </entry>
<entry valign="top"> conf </entry>
<entry valign="top"> Suffix for a static library.  Default value: ".lib" for MS-Windows,
".a" for Unix.
</entry>
</row>
<row>
<entry valign="top"><anchor id="var-libtool"/> $LIBTOOL </entry>
<entry valign="top"> conf </entry>
<entry valign="top"> Actual name of the "libtool" program, used to build libtool libraries
  and for building programs that use libtool libraries.  Default value:
  "libtool --silent".
</entry>
</row>
<row>
<entry valign="top"><anchor id="var-lnksuf"/> $LNKSUF </entry>
<entry valign="top"> conf </entry>
<entry valign="top"> Suffix for a (symbolic) link.  Default is empty. </entry>
</row>
<row>
<entry valign="top"><anchor id="var-logentry"/> $LOGENTRY </entry>
<entry valign="top"> user </entry>
<entry valign="top"> Default message for the version control change log.  Used when a file
is committed (also when it was deleted and the delete is committed).</entry>
</row>
<row>
<entry valign="top"><anchor id="var-ltobjsuf"/> $LTOBJSUF </entry>
<entry valign="top"> conf </entry>
<entry valign="top"> Suffix for an object file to be included in a libtool library.
  Default value: ".lo". </entry>
</row>
<row>
<entry valign="top"><anchor id="var-ltlibpre"/> $LTLIBPRE </entry>
<entry valign="top"> conf </entry>
<entry valign="top"> Prefix for libtool library.  The default is "lib". </entry>
</row>
<row>
<entry valign="top"><anchor id="var-ltlibs"/> $LTLIBS </entry>
<entry valign="top"> user </entry>
<entry valign="top"> Arguments for linking, after the object files but before
<link linkend="var-ltlibs">$LIBS</link>.
When <link linkend="var-ltlibs">$LTLIBS</link> is set "libtool" will be used
for building, see <link linkend="var-libtool">$LIBTOOL</link> (when the
platform supports it).
Convention: Always use "-lname", the tools will translate it into the flags
that the linker actually uses.</entry>
</row>
<row>
<entry valign="top"><anchor id="var-ltlibsuf"/> $LTLIBSUF </entry>
<entry valign="top"> conf </entry>
<entry valign="top"> Suffix for a libtool library.  Default value: ".la". </entry>
</row>
<row>
<entry valign="top"><anchor id="var-mandir"/> $MANDIR </entry>
<entry valign="top"> &Aap; </entry>
<entry valign="top"> Sub-directory to install man pages into. Default value: "man/".
Note that &Aap; will append "man1", "man2", etc. when installing manual pages.
</entry>
</row>
<row>
<entry valign="top"><anchor id="var-manmode"/> $MANMODE </entry>
<entry valign="top"> &Aap; </entry>
<entry valign="top"> Mode to use for installed man pages.
Default value: "0644"
(read/write for the user, readable for the group and others).</entry>
</row>
<row>
<entry valign="top"><anchor id="var-message"/> $MESSAGE </entry>
<entry valign="top"> user </entry>
<entry valign="top">
  <para>
Comma separated list of message types which are printed.  Possible
values:
<literallayout>    note             note message
    warning       warning message
    error            error message
    system         executed system command
    result           result of :sys command
    info              informational message
    extra            extra informational message
    changedir    changing directories
    depend        message about dependencies
    all                all messages
</literallayout>
Default value: "error,warning,system,info".
When the <link linkend="option-silent">-s</link> or <link
linkend="option-silent">--silent</link> option is used: "error".
When the <link linkend="option-verbose">-v</link> or <link
linkend="option-verbose">--verbose</link> option is used: all possible
values.
</para>
<para>
  Instead of removing "print" from $MESSAGE it is possible to use the
  <link linkend="cmd-log">:log</link> command to write text to the log file.
</para>
</entry>
</row>
<row>
<entry valign="top"><anchor id="var-objsuf"/> $OBJSUF </entry>
<entry valign="top"> &Aap; </entry>
<entry valign="top"> Suffix for an object file.  Default value: ".o" for Unix, ".obj" for
MS-Windows.
</entry>
</row>
<row>
<entry valign="top"><anchor id="var-optimize"/> $OPTIMIZE </entry>
<entry valign="top"> user </entry>
<entry valign="top"> A number from zero to nine.  Zero means no optimization, nine means
maximum optimization.  The default is two.
For an example see
<link linkend="build-variant">the tutorial</link>.</entry>
</row>
<row>
<entry valign="top"><anchor id="var-osname"/> $OSNAME </entry>
<entry valign="top"> &Aap; </entry>
<entry valign="top">
The name of the operating system and its version (on systems that support it).
For instance, FreeBSD 4.9 gives $OSNAME the value 
<literal>FreeBSD4_9_STABLE</literal>.
Systems that do not support name and version yield
what Python's <literal>os.name</literal> yields -
usually the same as $OSTYPE except for MS-Windows and MS-DOS.
This name is usually incorporated in <link linkend="var-bdir">$BDIR</link>
as well, as <literal>build-<replaceable>OSNAME</replaceable></literal>.
</entry>
</row>
<row>
<entry valign="top"><anchor id="var-ostype"/> $OSTYPE </entry>
<entry valign="top"> &Aap; </entry>
<entry valign="top">
Type of operating system used:
<literallayout>    posix             Unix-like (Linux, BSD)
    mswin           MS-Windows (98, XP)
    msdos           MS-DOS (not MS-Windows)
    os2                OS/2
    mac               Macintosh (OS X gives "posix")
    java               Java OS
    riscos            Risc OS
    ce                  MS-Windows CE
</literallayout>
</entry>
</row>
<row>
<entry valign="top"><anchor id="var-painter"/> $PAINTER </entry>
<entry valign="top"> conf </entry>
<entry valign="top"> Graphical editor to be used for the "edit" action.  The default value
  comes from the "PAINTER" environment variable.
</entry>
</row>
<row>
<entry valign="top"><anchor id="var-prefix"/> $PREFIX </entry>
<entry valign="top"> user </entry>
<entry valign="top"> Directory normally used for the top directory to install
  to.  When empty it defaults to "/usr/local".  Use a single slash to install
  in the root directory.
  Also see <link linkend="var-destdir">$DESTDIR</link>.
</entry>
</row>
<row>
<entry valign="top"><anchor id="var-ranlib"/> $RANLIB </entry>
<entry valign="top"> conf </entry>
<entry valign="top"> Program to run on created static library. Default is not set.  When
the "ranlib" action is invoked it will search for the "ranlib" program and set
the $RANLIB variable.</entry>
</row>
<row>
<entry valign="top"><anchor id="var-ranlibflags"/> $RANLIBFLAGS </entry>
<entry valign="top"> user </entry>
<entry valign="top"> Arguments for $RANLIB.  The default is not set. </entry>
</row>
<row>
<entry valign="top"><anchor id="var-rcp"/> $RCP </entry>
<entry valign="top"> conf </entry>
<entry valign="top"> Remote copy program to use for rcp://.  The default is not set, which
means "rcp -p" is used.  May also include arguments. </entry>
</row>
<row>
<entry valign="top"><anchor id="var-recipeversion"/> $RECIPEVERSION </entry>
<entry valign="top"> user </entry>
<entry valign="top"> Version of A-A-P the recipe was written for, set by the user.  Uses
the format "1.0", "1.3".  Currently not used, but in a later version of &Aap;
it can be use for backward compatible behavior.</entry>
</row>
<row>
<entry valign="top"><anchor id="var-rsync"/> $RSYNC </entry>
<entry valign="top"> user </entry>
<entry valign="top"> Remote sync program to use for rsync://.  The default is not set,
which means "rsync -p --rsh=ssh --copy-links" is
used (preserve file attributes, use secure shell connection, copy what
symbolic link points to). </entry>
</row>
<row>
<entry valign="top"><anchor id="var-sbindir"/> $SBINDIR </entry>
<entry valign="top"> &Aap; </entry>
<entry valign="top"> Sub-directory to install "sbin" files into. Default value:
"sbin/".</entry>
</row>
<row>
<entry valign="top"><anchor id="var-scp"/> $SCP </entry>
<entry valign="top"> user </entry>
<entry valign="top"> Secure copy program to use for scp://.  The default is not set, which
means "scp -C -p" is used.  May also include arguments, e.g.: "scp -i
c:/private/keyfile". </entry>
</row>
<row>
<entry valign="top"><anchor id="var-shlink"/> $SHLINK </entry>
<entry valign="top"> conf </entry>
<entry valign="top"> Name of linker used to combine object files into a shared (dynamic)
library. Default value: "ld" for Unix, "link" for MS-Windows. </entry>
</row>
<row>
<entry valign="top"><anchor id="var-shlinkflags"/> $SHLINKFLAGS </entry>
<entry valign="top"> user </entry>
<entry valign="top"> Arguments for $SHLINK.  Default value: "-shared" for Unix, "/nologo
/dll" for MS-Windows. </entry>
</row>
<row>
<entry valign="top"><anchor id="var-source"/> $SOURCE </entry>
<entry valign="top"> user </entry>
<entry valign="top"> List of source files.  OBSOLETE </entry>
</row>
<row>
<entry valign="top"><anchor id="var-strip"/> $STRIP </entry>
<entry valign="top"> conf </entry>
<entry valign="top"> Program to run on installed program. Default is empty.  When the
"strip" action is involved &Aap; will search for the "strip" command and set
$STRIP to the found program.</entry>
</row>
<row>
<entry valign="top"><anchor id="var-stripflags"/> $STRIPFLAGS </entry>
<entry valign="top"> user </entry>
<entry valign="top"> Arguments for $STRIP.  The default is not set. </entry>
</row>
<row>
<entry valign="top"><anchor id="var-tar"/> $TAR </entry>
<entry valign="top"> conf </entry>
<entry valign="top"> Tar program to use.  Default value is "tar". </entry>
</row>
<row>
<entry valign="top"><anchor id="var-target"/> $TARGET </entry>
<entry valign="top"> user </entry>
<entry valign="top"> List of target files, usually the name of the resulting program.
OBSOLETE </entry>
</row>
<row>
<entry valign="top"><anchor id="var-targetarg"/> $TARGETARG </entry>
<entry valign="top"> &Aap; </entry>
<entry valign="top"> Target(s) specified on the command line. </entry>
</row>
<row>
<entry valign="top"><anchor id="var-timestr"/> $TIMESTR </entry>
<entry valign="top"> &Aap; </entry>
<entry valign="top"> Time as a string in the form "23:11:09".  This always uses GMT, it
ignores time zones and daylight saving.  But it depends on the system time to
be set correctly!  The value does not change while &Aap; is running, it is the
time when &Aap; was started.
Also see <link linkend="var-gmtime">$GMTIME</link> and
<link linkend="var-datestr">$DATESTR</link>.
</entry>
</row>
<row>
<entry valign="top"><anchor id="var-topdir"/> $TOPDIR </entry>
<entry valign="top"> &Aap; </entry>
<entry valign="top"> In a child recipe: The directory of the child recipe relative to the
toplevel recipe.  When using: ":child subdir/main.aap" in the toplevel recipe,
$TOPDIR will be "subdir" in the child recipe. In the toplevel recipe $TOPDIR
is empty.</entry>
</row>
<row>
<entry valign="top"><anchor id="var-unzip"/> $UNZIP </entry>
<entry valign="top"> conf </entry>
<entry valign="top"> Unzip program to use for ".zip" archives.  Default value
  is "unzip". </entry>
</row>
<row>
<entry valign="top"><anchor id="var-versionstr"/> $VERSIONSTR </entry>
<entry valign="top"> &Aap; </entry>
<entry valign="top"> Version of A-A-P being used as a string, e.g., "0.100".
Also see <link linkend="var-aapversion">$AAPVERSION</link>.
</entry>
</row>
<row>
<entry valign="top"><anchor id="var-yacc"/> $YACC </entry>
<entry valign="top"> conf </entry>
<entry valign="top"> Program to turn a yacc file into C.
The default value is empty.  When
the "yacc" action is invoked &Aap; will search for "yacc" and "bison" and set
$YACC to the found program.
</entry>
</row>
<row>
<entry valign="top"><anchor id="var-yaccflags"/> $YACCFLAGS </entry>
<entry valign="top"> user </entry>
<entry valign="top"> Flags for $YACC. The default value is not set.</entry>
</row>
<row>
<entry valign="top"><anchor id="var-yaccpp"/> $YACCPP </entry>
<entry valign="top"> &Aap; </entry>
<entry valign="top"> Program to turn a yacc++ file into C++.
The default value is empty.  When
the "yaccpp" action is invoked &Aap; will search for "bison" and "yacc" and
set $YACC to the found program.
</entry>
</row>
<row>
<entry valign="top"><anchor id="var-yaccppflags"/> $YACCPPFLAGS </entry>
<entry valign="top"> user </entry>
<entry valign="top"> Flags for $YACCPP. The default value is not set.</entry>
</row>
<row>
<entry valign="top"><anchor id="var-bar-old"/> $bar </entry>
<entry valign="top"> &Aap; </entry>
<entry valign="top"> A single |.  OBSOLETE, use $(|). </entry>
</row>
<row>
<entry valign="top"><anchor id="var-br-old"/> $br </entry>
<entry valign="top"> &Aap; </entry>
<entry valign="top"> A line break.  OBSOLETE, use $BR </entry>
</row>
<row>
<entry valign="top"><anchor id="var-empty-old"/> $empty </entry>
<entry valign="top"> &Aap; </entry>
<entry valign="top"> Empty.  Can be used to get leading white space with
<computeroutput>:print</computeroutput>.
OBSOLETE, use $( ) </entry>
</row>
<row>
<entry valign="top"><anchor id="var-gt-old"/> $gt </entry>
<entry valign="top"> &Aap; </entry>
<entry valign="top"> A single &gt;.  OBSOLETE, use $(&gt;). </entry>
</row>
<row>
<entry valign="top"><anchor id="var-lt-old"/> $lt </entry>
<entry valign="top"> &Aap; </entry>
<entry valign="top"> A single &lt;.  OBSOLETE, use $(&lt;). </entry>
</row>
<row>
<entry valign="top"><anchor id="var-pipe-old"/> $pipe </entry>
<entry valign="top"> &Aap; </entry>
<entry valign="top"> A single |.  OBSOLETE, use $(|). </entry>
</row>

    </tbody>
  </tgroup>
</table>

