Commit Graph

23 Commits

Author SHA1 Message Date
Ingo Weinhold 6ef57ae2a9 pkgman: Add full-sync command
* BSolver/LibsolvSolver: Add FullSync() method. It uses libsolv's
SOLVER_DISTUPGRADE mode.
* BPackageManager: Add FullSync() using the new solver mode.
* pkgman: Add full-sync command.

The new command is similar to the update command without arguments, just
more aggressive, allowing downgrading or even removal of packages, to
match the state of the repositories. Just like "update" it doesn't work
properly yet.
2014-01-25 10:47:35 +01:00
Ingo Weinhold ecd7a82e0d BSolverPackage: Add Version() 2013-11-27 15:38:41 +01:00
Ingo Weinhold 9b2fd34196 Add BSolverPackageSpecifierList::AppendSpecifiers() 2013-09-10 19:14:19 +02:00
Ingo Weinhold 89cb001511 BSolver::VerifyInstallation(): Add flags parameter
Only flag ATM is B_VERIFY_ALLOW_UNINSTALL. It tells to solver to suggest
uninstalling packages when necessary instead of considering such a case
a problem.
2013-08-28 12:55:47 +02:00
Ingo Weinhold 75d15eb4c2 BSolver: Extend FindPackages() functionality
* Add flag B_FIND_INSTALLED_ONLY to only return installed packages.
* Add FindPackages() version that finds packages like Install() or
  Uninstall() do.
2013-08-28 12:47:58 +02:00
Ingo Weinhold 220b5e1f29 BSolverRepository: Add {Remove,Delete}Package() 2013-08-28 12:44:14 +02:00
Ingo Weinhold 682bf414da BSolverRepository: make polymorphic 2013-08-28 12:43:42 +02:00
Ingo Weinhold 383cd08d72 BSolverRepository: add SetTo(const BRepositoryCache&) 2013-07-04 19:06:42 +02:00
Ingo Weinhold 212c636f41 BSolver/LibsolvSolver: Add Update() 2013-04-21 13:55:38 +02:00
Ingo Weinhold de62d76176 BSolver/LibsolvSolver: Add Uninstall()
Also fix incorrect check in LibsolvSolver::GetResult().
2013-04-21 12:48:39 +02:00
Ingo Weinhold 8e6c3631a3 BSolver/LibsolvSolver: Add problem solution selection support
... and re-solving.
2013-04-21 02:48:52 +02:00
Ingo Weinhold 0d8ed3f2a8 BSolver::Install(): Add optional unmatched specifier return param 2013-04-12 14:21:54 +02:00
Ingo Weinhold 334a5a566c BSolverRepository: Change priority from uint8 to int32
This allows us to specifies priorities below and above the user
definable range.
2013-04-12 13:42:27 +02:00
Ingo Weinhold 01758ed332 Rework SolverPackageSpecifier
* It no longer consists of a BPackageResolvableExpression and a
  repository. Instead it can now either refer to a package directly or
  consist of a search string.
* SolverPackageSpecifierList: Add AppendSpecifier() convenience
  versions.
* Adjust LibsolvSolver and pkgman accordingly.
2013-04-12 00:21:49 +02:00
Ingo Weinhold 663e351cb4 BSolver/pkgman: Support for searching in provides
* BSolver/LibsolvSolver:
  * Add B_FIND_IN_NAME and make searching in the names explicit.
  * Add B_FIND_IN_PROVIDES to search the packages' provides list.
* pkgman: Also search in provides.
2013-04-11 23:36:12 +02:00
Ingo Weinhold fc57db481f BSolver/LibsolvSolver: Add FindPackages()
Given a search string it finds all matching packages.
2013-04-11 17:30:08 +02:00
Ingo Weinhold 50888ebdc0 BSolverRepository: Add a change count
... so we can easily check whether the repository has changed since the
last time we used it.
2013-04-10 12:58:12 +02:00
Ingo Weinhold 5e01af3199 package kit: Add data structures for problem solutions
... and add the problem solutions in LibsolvSolver.
2013-04-09 17:24:27 +02:00
Ingo Weinhold a8b832bf46 BSolverRepository::AddPackage(): Add optional return parameter
... returning the added BSolverPackage object.
2013-04-03 19:06:47 +02:00
Ingo Weinhold 65502bbe88 BSolver: Add VerifyInstallation()
... and implement it in LibsolvSolver.
2013-04-03 18:42:20 +02:00
Ingo Weinhold 07a4d4e370 BSolverRepository: Add SetPriority() 2013-04-03 15:57:16 +00:00
Ingo Weinhold 1a4d020daf Flesh out the package kit solver API quite a bit more
* Reorganize things a bit:
  - BSolver is now an abstract base class.
  - A libsolv based implementation, LibsolvSolver, lives in a new
    add-on, which is loaded lazily.
  - Get rid of libpackage_solver. Save for LibsolvSolver everything
    is moved to libpackage.
  - This is a nicer solution for the cyclic dependency caused by
    libsolv (libsolvext to be precise) using the package kit for
    reading repositories and package files.
* Add a solver result data structure and and an accessor the solver.
* Add problem reporting support to the solver. There aren't data
  structures for the problem solutions yet and support for selecting
  solutions and re-solving is missing as well.
2013-04-03 02:15:57 +00:00
Ingo Weinhold 479ca8169c Beginnings of the PackageKit dependency solver
Not functional (or tested) yet. The libsolv setup for a somewhat
simplified installation case should be more or less complete, though.
The solution conversion to to-be-created Haiku data structures and the
handling of problems is still missing, though.
2013-04-01 00:25:37 +00:00