manpagez: man pages & more
info automake
Home | html | info | man
[ < ] [ > ]   [ << ] [ Up ] [ >> ]         [Top] [Contents] [Index] [ ? ]

12.1 Basics of Installation

A file named in a primary is installed by copying the built file into the appropriate directory. The base name of the file is used when installing.

 
bin_PROGRAMS = hello subdir/goodbye

In this example, both ‘hello’ and ‘goodbye’ will be installed in ‘$(bindir)’.

Sometimes it is useful to avoid the basename step at install time. For instance, you might have a number of header files in subdirectories of the source tree that are laid out precisely how you want to install them. In this situation you can use the nobase_ prefix to suppress the base name step. For example:

 
nobase_include_HEADERS = stdio.h sys/types.h

will install ‘stdio.h’ in ‘$(includedir)’ and ‘types.h’ in ‘$(includedir)/sys’.

For most file types, Automake will install multiple files at once, while avoiding command line length issues (see section Staying below the command line length limit). Since some install programs will not install the same file twice in one invocation, you may need to ensure that file lists are unique within one variable such as ‘nobase_include_HEADERS’ above.

You should not rely on the order in which files listed in one variable are installed. Likewise, to cater for parallel make, you should not rely on any particular file installation order even among different file types (library dependencies are an exception here).


© manpagez.com 2000-2024
Individual documents may contain additional copyright information.