wpkg --create-admindir
Options | Comments |
---|---|
--admindir | Define the administration directory, where the database of the installed packages resides. |
--build | [Only with --install] Using this command along the --install command is the same as doing --build-and-install. |
--debug | Define a set of flags of things to print out for debug purposes. |
--dry-run | Run all validations then exit. |
--force-all | Ignore all problems that can be bypassed. |
--force-architecture | Ignore architecture mismatch errors. |
--force-breaks | Allow the installation of packages that break others. |
--force-configure-any | Automatically configure packages that were only unpackaged earlier. |
--force-conflicts | Accept packages even if they are in conflict with others. |
--force-depends | Accept installing packages with missing dependencies. |
--force-depends-version | Accept installing packages with dependencies having incompatible versions. |
--force-downgrade | Allow a package to be dowgraded. |
--force-hold | Force an upgrade to occur even if one of the explicit packages is currently on hold. |
--force-overwrite | Allow a package to overwrite another's file(s). |
--force-overwrite-dir | Allow the system to overwrite directories with files and vice versa. |
--instdir | Define the installation directory, where the data files are installed on the target. |
--interactive | Allow wpkg to interactively request a username and password when necessary to access a remote drive. |
--no-act | Run all validations then exit. |
--no-force-all | Prevent any --force-... command line option from being used. |
--no-force-architecture | Prevent package with an incompatible architectures from being installed. |
--no-force-breaks | Prevent the installation of package if marked as breaking each others. |
--no-force-configure-any | Do no automatically configure packaages. If a dependency is an unpacked package, then the verification fails. |
--no-force-conflicts | Prevent incompatible packages from being installed along each others. |
--no-force-depends | Prevent packages with missing dependencies from being installed. |
|
Prevent installing packages if dependency versions are not compatible. |
--no-force-downgrade | Prevent a package from being downgraded (a smaller version cannot be installed.) |
--no-force-hold | Prevent upgrading a package if it is currently on hold. |
--no-force-overwrite | Forbid any package from overwriting any file while being installed. |
--no-force-overwrite-dir | Prevent the overwrite feature on directory. |
--quiet | Request for minimal output. For the --verify function this is the default behavior. |
--recursive | Recursively scan the --repository directories or remove all dependencies automatically. |
--refuse-all | Prevent all problems from ever being bypassed. |
--refuse-architecture | Prevent package with an incompatible architecture from being installed. |
--refuse-breaks | Prevent the installation of package if marked as breaking each others. |
--refuse-configure-any | Do no automatically configure packaages. If a dependency is an unpacked package, then the verification fails. |
--refuse-conflicts | Prevent incompatible packages from being installed along each others. |
--refuse-depends | Prevent packages with missing dependencies from being installed. |
--refuse-depends-version | Prevent installing packages if dependency versions are not compatible. |
--refuse-downgrade | Prevent a package from being downgraded (a smaller version cannot be installed.) |
--refuse-hold | Prevent an upgrade of a package that is on hold. |
--refuse-overwrite | Forbid any package from overwriting any file while being installed. |
--refuse-overwrite-dir | Prevent the overwrite feature on directory. |
--repository | List of directories used as repositories for package dependencies. |
--root | Define the installation root path. |
--simulate | Run all validations then exit. |
--skip-same-version | Do not reinstall a package if that same version is already installed. |
--tracking-journal | Specify the filename for the tracking journal that can be used to rollback changes made by installation commands. |
--verify-fields | Ensure fields validity before processing. |
--verbose | Display log information of level INFO. |
The --create-admindir command is used to create a target directory. This is necessary before you can install a package on a target system1.
The command requires you to define at least the architecture of the target and the name and email address of the maintainer. Note that wpkg does not check the architecture of the target machine so you can really define any architecture on any computer. This is done on purpose so that way you can install a Windows 32 target on a Windows 64 computer or even a Linux server.
The command accepts one parameter which is a control file. You also want to use the --root or --admindir options to specify the destination of the database on your target. It is preferable to use --root so your database and installation remain together.
The following is an example of a control file one can use to create the administration folder2:
Architecture: mswindows-i386 Maintainer: John Smith <js@example.com>
The main architectures are mswindows-i386, mswindows-amd64, linux-i386, and linux-amd64. See the Architectures in wpkg page for additional information about architectures.
The fields that are supported in the core control file are:
- Architecture (mandatory)
- Description
- Distribution
- Maintainer (mandatory)
- Package (which must be named "core" if specified)
wpkg automatically adds the Version field with the version of the libdebpackages database. This version is used to control how to handle the database in case a different version of wpkg is used than the one that was used to create the database. At this point this has not been necessary.
To get information about an existing target, use the --field command with the package named core:
wpkg -f core
The output includes a few additional fields such as X-Status and the list may grow as the target is being managed.
- 1. Note that this may feel strange to a user who is used to install a Linux distribution. The fact is that this step is hidden from you as the distribution does it under the hood. With wpkg, you have to do this manually.
- 2. There is a sample in the dev directory of the source project called sample.admindir which you can copy and edit for your own purposes.