// file      : bpkg/pkg-configure.cli
// license   : MIT; see accompanying LICENSE file

include <bpkg/configuration.cli>;

"\section=1"
"\name=bpkg-pkg-configure"
"\summary=configure package"

namespace bpkg
{
  {
    "<options> <cfg-var> <pkg> <ver>",

    "\h|SYNOPSIS|

     \c{\b{bpkg pkg-configure} [<options>] [<cfg-var>...] <pkg>}

     \h|DESCRIPTION|

     The \cb{pkg-configure} command configures either the previously unpacked
     (\l{bpkg-pkg-unpack(1)}, \l{bpkg-pkg-checkout(1)}) source code package or
     a package that is present in the system.

     A source code package inherits the common \cb{build2} configuration
     values that were specified when creating the configuration
     (\l{bpkg-cfg-create(1)}). Additional package-specific configuration
     variables can be passed to \cb{pkg-configure} (<cfg-var>).

     A system package is specified using the \c{\b{sys:}<pkg>[/<ver>]}
     syntax. If the package version (<ver>) is not specified, then it is
     considered to be unknown but satisfying any dependency constraint. Such a
     version is displayed as \cb{*}."
  }

  class pkg_configure_options: configuration_options
  {
    "\h|PKG-CONFIGURE OPTIONS|"
  };

  "
   \h|DEFAULT OPTIONS FILES|

   See \l{bpkg-default-options-files(1)} for an overview of the default
   options files. For the \cb{pkg-configure} command the search start
   directory is the configuration directory. The following options files are
   searched for in each directory and, if found, loaded in the order listed:

   \
   bpkg.options
   bpkg-pkg-configure.options
   \

   The following \cb{pkg-configure} command options cannot be specified in the
   default options files:

   \
   --directory|-d
   \
  "
}
