Cache::Apt::Package(3)

Name

Cache::Apt::Package - Package handler for apt-cross and related tools

Description

Turns the awkward libapt-pkg-perl API into an Object-oriented set of
structs that can be passed around between scripts. Uses an extensively modified portion of NorthernCross to provide the data contained in the structs. Together with Cache and Config, Package will form a new Debian package: libcache-apt-perl

The structures are designed to be discrete and do not contain selfreferencing variables as are found in apt-pkg-perl. All instances can
be safely used with Data::Dumper to inspect the contents - most
functions support a $verbose setting that can dump the contents of the current package to the console using Data::Dumper.

Copyright and Licence

Copyright (C) 2007 Neil Williams <codehelp@debian.org>

This package is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 3 of the License, or
(at your option) any later version.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.

Bugs

Please report bugs via the Debian Bug Tracking System.

Support

All enquiries to the "<debian-embedded@lists.debian.org"> mailing list.

AptCrossPackage

The struct that is used to describe a package.

Note that Depends is an array - it needs to be an array of
AptCrossDependency structs.
struct (AptCrossPackage => {
"Package" => '$',
"Version" => '$',
"Source" => '$',
"Distribution" => '$',
"Architecture" => '$',
"Maintainer" => '$',
"Size" => '$',
"Installed" => '$',
"Section" => '$',
"Priority" => '$',
"Build_Depends" => '$',
"Build_Depends_Indep" => '$',
"Depends" => '@',
"Description" => '$',
"Summary" => '$',
"Recommends" => '$',
"Suggests" => '$',
"Filename" => '$',
"Provides" => '$',
"FileMD5Hash" => '$',
});

AptCrossDependency

AptCrossPackage->Depends is an array of AptCrossDependency instances
describing the dependency.

VersionLimit is the version indicator for this dependency and the
version string itself - but not the parentheses.
e.g.
>= 1.2.3-1
<< 0.56-2
>> 1.3~r345-1
struct (AptCrossDependency => {
"Package" => '$',
"VersionLimit" => '$',
"Installed" => '$',
"Type" => '$',
});
lookup_pkg
Populate an AptCrossPackage with data from the cache.
Use this function to remove some of the pain of working directly with
the apt-pkg-perl constructs or even AptCross::Cache functions.
Note that this lookup operates on the binary package name.
output_pkg
Creates output on STDOUT to imitate dpkg-query -s or apt-cache show
Certain values are not available via the current perl bindings.
Copyright © 2010-2025 Platon Technologies, s.r.o.           Home | Man pages | tLDP | Documents | Utilities | About
Design by styleshout