TABLE OF CONTENTS


Installing

[ Top ] [ Chapter 10 ] [ Concepts ]

NOTE

In the context of cygport, "installing" always means into the DESTDIR $D. However, the syntax of the convenience functions is as if one were installing to the system.


dodir

[ Top ] [ Installing ] [ Install Functions ]

SYNOPSIS

  dodir DIRECTORY [DIRECTORY] ...

DESCRIPTION

Creates the given directories under $D.


keepdir

[ Top ] [ Installing ] [ Install Functions ]

SYNOPSIS

  keepdir DIRECTORY [DIRECTORY] ...

DESCRIPTION

Preserves the given empty directories under $D from being removed during automatic postinstall steps.

SEE ALSO

KEEPDIRS


dobin

[ Top ] [ Installing ] [ Install Functions ]

SYNOPSIS

  dobin FILE [FILE] ...

DESCRIPTION

Installs the given file(s) to the standard bindir and makes them executable.


newbin

[ Top ] [ Installing ] [ Install Functions ]

SYNOPSIS

  newbin FILE NEW_NAME

DESCRIPTION

Installs the given file to the standard bindir with the given new name, and makes it executable.


docinto

[ Top ] [ Installing ] [ Install Functions ]

SYNOPSIS

  docinto [/]SUBDIRECTORY

DESCRIPTION

Sets the subdirectory into which dodoc and newdoc should install. If the subdirectory is prefixed by a slash, then dodoc and newdoc will use /usr/share/doc/SUBDIRECTORY/; if not, they will use /usr/share/doc/PN/SUBDIRECTORY/.


dodoc

[ Top ] [ Installing ] [ Install Functions ]

SYNOPSIS

  dodoc FILE [FILE] ...

DESCRIPTION

Installs the given files or directories into $D/usr/share/doc/PN/, or a subdirectory thereof specified by the previous call to docinto.


newdoc

[ Top ] [ Installing ] [ Install Functions ]

SYNOPSIS

  newdoc FILE NEW_NAME

DESCRIPTION

Installs the given file into $D/usr/share/doc/PN/, or a subdirectory thereof specified by the previous call to docinto, with the given new name.


exeinto

[ Top ] [ Installing ] [ Install Functions ]

SYNOPSIS

  exeinto DIRECTORY

DESCRIPTION

Specifies the directory under $D into which doexe and newexe will install.


doexe

[ Top ] [ Installing ] [ Install Functions ]

SYNOPSIS

  doexe FILE [FILE] ...

DESCRIPTION

Installs the given file(s) into the directory under $D specified by the preceding call to exeinto and makes them executable.


newexe

[ Top ] [ Installing ] [ Install Functions ]

SYNOPSIS

  newexe FILE NEW_NAME

DESCRIPTION

Installs the given file into the directory under $D specified by the preceding call to exeinto, renaming it as indicated, and makes it executable.


insinto

[ Top ] [ Installing ] [ Install Functions ]

SYNOPSIS

  insinto DIRECTORY

DESCRIPTION

Specifies the directory under $D into which doins and newins will install.


doins

[ Top ] [ Installing ] [ Install Functions ]

SYNOPSIS

  doins FILE [FILE] ...

DESCRIPTION

Installs the given file(s) into the directory under $D specified by the preceding call to insinto. Files are made not executable.


newins

[ Top ] [ Installing ] [ Install Functions ]

SYNOPSIS

  newins FILE NEW_NAME

DESCRIPTION

Installs the given file into the directory under $D specified by the preceding call to insinto, renaming it as indicated. Files are made not executable.


doicon

[ Top ] [ Installing ] [ Install Functions ]

SYNOPSIS

  doicon FILE [FILE] ...

DESCRIPTION

Installs the given image file(s) into the legacy icon directory.

NOTES


newicon

[ Top ] [ Installing ] [ Install Functions ]

SYNOPSIS

  newicon FILE NEW_NAME

DESCRIPTION

Installs the given image file into the legacy icon directory, renaming it as indicated.

NOTE

Supported icon formats are PNG, XPM, and SVG.


includeinto

[ Top ] [ Installing ] [ Install Functions ]

SYNOPSIS

  includeinto SUBDIRECTORY

DESCRIPTION

Sets the subdirectory of the standard includedir into which doinclude should install.


doinclude

[ Top ] [ Installing ] [ Install Functions ]

SYNOPSIS

  doinclude HEADER [HEADER] ...

DESCRIPTION

Installs the given headers into the standard includedir, or the subdirectory thereof specified by a previous call to includeinto.


dolib

[ Top ] [ Installing ] [ Install Functions ]

SYNOPSIS

  dolib LIBRARY [LIBRARY] ...

DESCRIPTION

Installs the given libtool, static, or import libraries into the standard libdir.

NOTES


newlib

[ Top ] [ Installing ] [ Install Functions ]

SYNOPSIS

  newlib LIBRARY NEW_NAME

DESCRIPTION

Installs the given static or import library into the standard libdir, renaming it as indicated.

NOTES


doinfo

[ Top ] [ Installing ] [ Install Functions ]

SYNOPSIS

  doinfo FILE [FILE] ...

DESCRIPTION

Installs the given Info documentation file(s) into the standard infodir.


doman

[ Top ] [ Installing ] [ Install Functions ]

SYNOPSIS

  doman [[-l |--lang=]LANGUAGE] MANPAGE [MANPAGE] ...

DESCRIPTION

Installs the given manpage(s) into the appropriate subdirectory of the standard mandir. Localized manpages can be installed by specifing the --lang (-l) argument, otherwise manpages are assumed to be in English.


newman

[ Top ] [ Installing ] [ Install Functions ]

SYNOPSIS

  newman [[-l |--lang=]LANGUAGE] MANPAGE NEW_NAME

DESCRIPTION

Installs the given manpage into the appropriate subdirectory of the standard mandir with the given new name. Localized manpages can be installed by specifing the --lang (-l) argument, otherwise manpages are assumed to be in English.


domenu

[ Top ] [ Installing ] [ Install Functions ]

SYNOPSIS

  domenu DESKTOP_MENU [DESKTOP_MENU] ...

DESCRIPTION

Installs the given desktop menu entries (.desktop).


newmenu

[ Top ] [ Installing ] [ Install Functions ]

SYNOPSIS

  newmenu DESKTOP_MENU NEW_NAME

DESCRIPTION

Installs the given desktop menu entry (.desktop) with the given new name.


dopkgconfig

[ Top ] [ Installing ] [ Install Functions ]

SYNOPSIS

  dopkgconfig PC_FILE [PC_FILE] ...

DESCRIPTION

Installs the given pkg-config metadata files.


dosbin

[ Top ] [ Installing ] [ Install Functions ]

SYNOPSIS

  dosbin FILE [FILE] ...

DESCRIPTION

Installs the given file(s) to the standard sbindir and makes them executable.


newsbin

[ Top ] [ Installing ] [ Install Functions ]

SYNOPSIS

  newsbin FILE NEW_NAME

DESCRIPTION

Installs the given file to the standard sbindir with the given new name, and makes it executable.


dosym

[ Top ] [ Installing ] [ Install Functions ]

SYNOPSIS

  dosym TARGET [TARGET] ... DESTINATION

DESCRIPTION

Creates symlinks from the given target(s) to the given destination. The destination must be a directory if more than one target is given. Both relative and absolute targets are supported; relative targets must be given in relation to the destination.

NOTE

The destination directory must exist under $D before dosym is called, therefore a preceding call to dodir may be necessary.


dotool

[ Top ] [ Installing ] [ Install Functions ]

SYNOPSIS

  dotool FILE [FILE] ...

DESCRIPTION

Installs the given compiler tool(s) into the target-specific bindir and a target-prefixed version into the native bindir.


doenv

[ Top ] [ Installing ] [ Install Functions ]

SYNOPSIS

  doenv VARIABLE VALUE

DESCRIPTION

Creates profile.d scripts which set the given environment variable.

NOTE

If VALUE includes a reference to a variable which is meant to be expanded at runtime, then be sure to escape the leading dollar-sign and, for portability, do not use braces; for example:

    doenv PATH \$PATH:/foo/bar


make_autostart_entry

[ Top ] [ Installing ] [ Install Functions ]

SYNOPSIS

  make_autostart_entry COMMAND NAME [ADDITIONAL_FIELDS]

DESCRIPTION

Creates an autostart entry for desktop applications as follows:


make_desktop_entry

[ Top ] [ Installing ] [ Install Functions ]

SYNOPSIS

  make_desktop_entry COMMAND NAME [ICON] [CATEGORIES] [COMMENT] [ADDITIONAL_FIELDS]

DESCRIPTION

Creates a desktop menu entry for GUI applications as follows:

NOTES


make_etc_defaults

[ Top ] [ Installing ] [ Install Functions ]

SYNOPSIS

  make_etc_defaults FILE_PATH [FILE_PATH] ...

DESCRIPTION

Indicates that the given file(s) or directory/ies under $D contain templates for system-configurable files. make_etc_defaults moves these files/directories to a special location, creates a postinstall script to install each file to the correct location if it doesn't already exist, and a preremove script which removes the file if still unchanged.


update_etc_shells

[ Top ] [ Installing ] [ Install Functions ]

SYNOPSIS

  update_etc_shells PATH_TO_SHELL [PATH_TO_SHELL] ...

DESCRIPTION

Indicates that the given fully-qualified path(s) are shells which should be listed in /etc/shells. update_etc_shells creates a postinstall script to add this listing if it doesn't already exist, and a preremove script which removes it when uninstalling.

NOTES


cyginstall

[ Top ] [ Installing ] [ Install Functions ]

SYNOPSIS

  cyginstall [OPTIONS]

DESCRIPTION

Runs 'make install' (or 'make install/fast' in CMake packages) with the necessary arguments to install into $D, based on the value of USE_DESTDIR.


USE_DESTDIR

[ Top ] [ cyginstall ] [ Variables ]

DESCRIPTION

Set to 1 (the default) if 'make install' supports the DESTDIR variable, or 0 if not, in which case the value of prefix and the standard *dir variables will be overriden with $D-prefixed values.


src_install

[ Top ] [ Installing ] [ Install Functions ]

DESCRIPTION

This function must be defined in the .cygport file, or in inherit()ed cygclasses, containing all steps necessary to install the package into $D and prepare it for packaging.

The default src_install function is shown below. Several cygclasses provide their own src_install overrides.

DEFINITION

src_install() {
        cd ${B}
        cyginstall
}