Index of Section 1 Manual Pages

Interix / SUApkg_update.1Interix / SUA

PKG_UPDATE(1)           System General Commands Manual           PKG_UPDATE(1)

NAME
     pkg_update - updates installed software package distributions

SYNOPSIS
     pkg_update [-aACdDGhHiLnpPrsSvWx] [-f file] [-l location] [-M type]
                [-R release] [-X tag] pkg-name [...]

DESCRIPTION
     The pkg_update command is used to update packages that have been previ-
     ously installed with the pkg_add(1) command, pkg_update command or to
     install groups of packages by reading configurations.  Selected packages
     containing pre-compiled applications from the /src tree can be found on
     the Interop Systems FTP site or on the official Interop Systems "Tool-
     works" CD.  These packages are provided as a convenience for quickly
     installing software that would otherwise need to be built manually.

     Package names may be specified to pkg_update as just the "basename" (no
     version numbers or file extentions needs).  For example, the following is
     a valid example to obtain the latest update for the "ftp" package:

     pkg_update -iL ftp

     Warning: Since the pkg_update command may execute scripts or programs
     contained within a package file, your system may be susceptible to
     ``trojan horses'' or other subtle attacks from miscreants who create dan-
     gerous packages.  Be sure the specified package(s) are from trusted
     sources.  pkg_update will always ask you to verify the location the pack-
     ages are being obtained from.

     The options are as follows:

     -a      Check that all installed packages are current and update those
             packages that have changed.

     -A      Install as a group all of the packages that have been labeled as
             user packages from the install location.

     -C      Indicates that the named packages will be stored in a cache
             instead of being installed. By default the cache is
             /var/db/pkg/CACHE but if the environment variable PKG_DBDIR is
             set then the location will be ${PKG_DBDIR}/CACHE.  The cache
             location can be specifically set with the environment variable
             PKG_CACHE. The cache location should be provided to the '-l'
             option when the installation is to actually happen.

     -d      Display the name of each package as its installation is com-
             pleted.

     -D      Install as a group all of the packages that have been labeled as
             developer packages from the install location.

     -G      Install as a group all of the packages that have been labeled as
             administrator packages from the install location.

     -f file
             Give the name of a file that has a list of packages to be updated
             (or installed).  This option may be specified more than once. A
             file consists of one package name per line in a standard text
             file. Like the command line listing, only the "basename" of the
             package should be listed (i.e. "ftp").  If the '#' is found on
             the line then everything after the last '#' on the line is taken
             as a comment.

     -h      Display a short help list as a memory aid for options.

     -H      Access the default location (see -L) using HTTP instead of FTP.
             Ignored when not used with the '-L' option.

     -i      Check with the user before any actions are taken to install a
             package. With this inquiry mode you may accept (y) or reject (n)
             a package being installed.  You may also respond to quit (q) the
             entire process.

     -l location
             Specify a default location where updated packages might be found
             if the package name does not provide enough information, or the
             environment variable PKG_LOCATION is not set, or if the built-in
             default location (/Tools ftp site) is not to be used.

     -L      Use the default location (see -l) to obtain packages. Information
             will normally be drawn out of the pathname or URLname to derive
             where the package should be found.

     -M type
             Use the specified type as the basis for package selection instead
             of the default based on what is reported by uname(2).  The option
             -R is a companion to this option.

     -n      New package check. A timestamp is maintained each time this
             option is used.  This will check for any new or updated packages
             that are available for installation from the install location
             since the last time this option was used by anyone.

     -p      Suppress printing the install-message for a package if it exists.

     -P basepath
             Base all utilities to be run from the directory basepath instead
             of /bin/ (the default). All utilities to be run are specified
             with full paths to well known locations instead of relying on the
             PATH environment variable to avoid potential spoofs.

     -Q      Quiet mode.

     -r      Re-install the package when the currently installed version
             matches the version available for installation. This can be use-
             ful if you believe that part of the installed package has been
             corrupted or erroneously modified. It can also be useful if you
             have installed a 32-bit based package on a 64-bit system and now
             want to change to the 64-bit based package.

     -R release
             Use the specified release as the basis for package selection
             instead of the default based on what is reported by uname(2).
             This is useful when a beta release of Interix has a uname prob-
             lem. The option -M is a companion to this option.

     -s      Work in silent mode: no warning messages will be given.

     -S      Work in very silent mode: no warning and no error messages will
             be given.

     -v      Turn on verbose output.

     -V      Display the version number of the release of this utility.

     -W      Do not take the install lock. Users should avoid this option.

     -x      Do not use any Internet connection or path, either explicit,
             implicit or cached to get a package, a package dependency or
             update list.

     -X tag  Similar to the options -A, -D and -G but you specify the tag to
             match. Tags are placed trailing on the line of each package iter-
             ated in the list file. A tag consists of the `#' character fol-
             lowed by a word of your choice.  This allows local administrators
             to have a unified list file while still being able to have spe-
             cific install groups.

   Technical details

     pkg_update is the easy command line interface to the package system for
     installing.  pkg_update extracts each package's ``packing list'' into a
     special staging directory in /tmp (or PKG_TMPDIR if set) and then starts
     the installation. Full details for the sequence can be found on the man-
     ual page for pkg_add(1).

     pkg_update does several automatic discovery options to determine the
     right location of an available package so that you do not have to worry
     about it. This means that with different versions of Interix or even the
     same version on different hardware platforms, the same command can be
     issued uniformly. A typical installation may look like this to install
     the package lc:

     % pkg_update -L lc

     The -L option is used to indicate that a search for the package at the
     default ftp site is to happen. You can use the -l option to indicate a
     local cache or use the environment variable PKG_LOCATION. Typically users
     will obtain the packages automatically from the default ftp site.

     When you ask for a package to be installed it will also install any pack-
     ages that it depends on to run properly. Dependent packages are often
     used by other packages meaning that each additional package installed
     will typically required fewer dependent packages to be installed since
     they are already installed. To see which package you have installed use
     the pkg_info(1) command.

     When you have local cache you should maintain a special file named `list'
     in that directory. The list file can be used to advertise which packages
     are available from that cache, when each became available and to which
     install group it belongs (refer to the option -X -).  The content is a
     set of lines, one for each package. Each line consists of a date, package
     name and optional tag(s) that are tab separated. For example:

     20060517 xargs-1.1-bin.tgz #user #dev #admin

     This tells us that the package was made available 17, May, 2007 and has
     three tags associated with it (`user', `dev' and `admin'). The package
     name is as stored in the directory.

     When storing packages in a local cache it is best to maintain a directory
     hierarchy that keeps the packages for different Interix releases and
     hardware platforms separate. This is for clarity, sanity and functional-
     ity.

     When the option -x is used to indicate that no Internet access is to be
     used to obtain packages then you should use the -l option or one of the
     environment variables PKG_LOCATION or PKG_CACHE (in that order) If none
     of these is specified then a location default location will be used.  The
     local default location will be $(PKG_DBDIR)/CACHE/{RELEASE}-{HARDWARE}.

ENVIRONMENT
     PKG_LOCATION
                 If a location for a package has not be specified explicitly
                 in the package name or with the -l option then the location
                 given in PKG_LOCATION is used to find the package. The loca-
                 tion may be either a local pathname which includes the /net
                 filesystem, or an FTP URL. The default when no setting is
                 specified is the FTP URL of:
                 ftp://ftp.interopsystems.com/pkgs/{RELEASE}-{HARDWARE}
                 Where {RELEASE} is the release version of Interix and {HARD-
                 WARE} is type of CPU hardware for the machine (both as
                 reported by 'uname').

     PKG_CACHE   Location for cacheing packages with the '-C' option. If not
                 specified then the default cache will be
                 $(PKG_DBDIR)/CACHE/{RELEASE}-{HARDWARE}.

     PKG_DBDIR   Where to register packages. The default is /var/db/pkg.

     PKG_TMPDIR  Temporary area where packages will be extracted, instead of
                 /var/tmp.

SEE ALSO
     pkg_add(1), pkg_create(1), pkg_delete(1), pkg_info(1), uname(1)

AUTHORS
     Rodney Ruddock
             Initial work and ongoing development.

CAVEATS
     The options that are functional are stable as released.

     All of the caveats that apply to pkg_add and pkg_delete are applicable
     since one or both may be invoked during the updating.

BUGS
     Some are sure to appear. We'll fix them as soon as we know about them.
     So please send bug reports to rodney@interopsystems.com.

Interix                           May 5, 2009                          Interix

Interix / SUAHosted at SUA Community for Interix, SUA and SFUInterix / SUA