summaryrefslogtreecommitdiffstats
path: root/lib/libalpm/deps.c
AgeCommit message (Collapse)AuthorFilesLines
2007-03-05This commit looks much more monumental than it is. Almost all just #includeDan McGee1-3/+6
reordering and adding ones that were forgotten (noticed when trying to compile after reordering). * Updated the HACKING file to include information on #include usage. * print -> vprint in "making dir" function in pactest.
2007-03-03* A little more hacking with wchar_t output, but nothing really changed inDan McGee1-60/+72
it. Eventually we'll make progress. * Rewrote the _alpm_splitdep function to behave more like all our other function calls. Use heap instead of stack allocation for the depend struct, so now it needs to be freed by the caller.
2007-03-03Big commit this time:Aaron Griffin1-64/+60
* Moved entirely to alpm_pkg_get_* accessors, to read data on demand * Mostly removed the INFRQ_ parameters from outside the be_files backend (making the backend more extensible in the long run) * packages created from _alpm_db_scan now have the db and origin set (making accessors actually work for these packages) * removed _alpm_db_ensure_pkgcache * totally revamped the _alpm_checkconflicts function, making it cleaner and easier to read (and thus fix in the long run) - maintainable code ftw NOTE: feel free to rename the functions... I couldn't think of anything better * removed an extra loop in sync.c:find_replacements - no sense in looping over an entire DB while strcmp'ing the name, when we have get_pkgfromcache Other: * package struct "license" -> "licenses" * Created _alpm_sync_find (duplicate code in some places, find_pkginsync * Minor const correctness changes along the way * fixed a couple extra '/' pathing issues (non-issues really) * removed a duplicate pkg_cmp function
2007-03-01* Comment clarificationAaron Griffin1-1/+2
2007-03-01* Switched some functions to alpm_pkg_get_* usage as I came across themAaron Griffin1-18/+53
* Added some provision switching hackery. This could probably use some refactoring,.. it solves the following case: pkg1 and pkg2 provide 'foo' and are both installed pkg3 depends on 'foo' and so lists 'pkg1' in the REQUIREDBY db section pkg1 is upgraded and no longer provides 'foo' ** This code ensures that the REQUIREDBY of pkg3 is updated to require pkg2 now instead of pkg1
2007-02-28* Added another test as suggested by Nagy on the ML- a package both providesDan McGee1-30/+19
for and is a dependency of another package. (upgrade057) * Removed man2html stuff from doc/Makefile.am. * Patch: improved depends checking in _alpm_checkdeps Nagy Gabor <ngaba@petra.hos.u-szeged.hu> * Slight revisions to pmrule.py to allow for a PKG_PROVIDES test. * Very quick updates to the pactest README. * Added rules to some of the newer upgrade tests. Note: upgrade055 now fails due to requiredby entries not being written packages that are dependencies in a provides role.
2007-02-26* Enforce const char* params when using stringsAaron Griffin1-8/+8
* Unified some functions names "package" -> "pkg" for consistency * Removed the goofy 'faketarget' stuff used for dep testing * Renamed alpm_pkg_isin -> alpm_pkg_find * Renamed alpm_db_readpkg -> alpm_db_get_pkg
2007-02-21* Fixed inconsistency of args- _alpm_db_read, _alpm_db_write.Dan McGee1-6/+6
2007-02-20* Some cascade removal changes. Mainly code cleanup, but this is an attempt toAaron Griffin1-46/+50
track down the great "Codemac Segfault" * Fixed sortdeps - use the alpm_pkg_get functions to ensure data
2007-02-18* Fix version comparisons when one pkgrel doesn't exist (this ony fails on an ==Aaron Griffin1-3/+3
operation, technically, as 1.1.2-1 >= 1.1.2 is true.
2007-02-16* Removed unnecessary #defineDan McGee1-0/+1
* Added comment for something I noticed while looking through code
2007-01-31Switched an int to an enumAaron Griffin1-1/+1
2007-01-31Debug logging changes:Aaron Griffin1-2/+2
* The --debug params were goofy. New setup allows --debug without params, --debug=<level> where level 1=debug output, 2=debug and download output, 3=debug, download, and function tracing output. This seems more sane to me. * Removed PM_LOG_FLOW1 and PM_LOG_FLOW2. They were just confusing. When adding new functions, it is near impossible to determin if your output should be "flow1" or "flow2" without tracking all the way up the call chain. Rarely would one ever say "ok, lets just show "flow2" output. These have both been replaced with PM_LOG_DEBUG * Removed the need for the root parameter on alpm_initialize. it is now defaulted to PM_ROOT just like dbpath and cachedir. This allows alpm to be initialized BEFORE option parsing in the front end, saving us some duplicate variables in the frontend. * Cleaned up front end variables due to early alpm_initialize call.
2007-01-30K. Piche <kevin.piche@cgi.com>Aaron Griffin1-0/+22
* ALPM_LOG_FUNCTION macro and all the great work to add this macro everywhere
2007-01-30K. Piche <kpiche@rogers.com>Aaron Griffin1-5/+5
* gcc visiblity changes Also modified _alpm_versioncmp -> alpm_versioncmp (public function) as per K. Piche's suggestions
2007-01-30* Remove -fno-strict-aliasing as it is now unnecessary to compile.Dan McGee1-7/+6
* Fix up add.c a bit better than it was in regards to FS #3492. * Optimized the sqrt call in dependency cycle checking to a single call. * Removal of an outdated comment.
2007-01-30Discussed on IRC for a bit, this makes the following changes for clarity:Dan McGee1-3/+3
* alpm_list_is_in --> alpm_list_find * alpm_list_is_strin --> alpm_list_find_str * Flip parameters of both functions to be inline with rest of alpm_list. First commit, woohoo.
2007-01-26Dan McGee <dpmcgee@gmail.com>Aaron Griffin1-2/+2
* Lots of code cleanup, and type fixes * Make 'makeworld' a bit more in-line with the other stuff * Make -Si and -Qi operations appear the same
2007-01-24This mainly deals with code clarity- removing currently unneededAaron Griffin1-15/+24
optimizations in order to make the code much more readable and type-checkable. Every enum in the library now has it's own type that should be used instead of the generic 'unsigned char'. In addition, several #define statements dealing with constants were converted to enums. Signed-off-by: Dan McGee <dpmcgee@gmail.com>
2007-01-19Preliminary checkin for alpm_list conversionAaron Griffin1-43/+43
* renamed pmlist_t -> alpm_list_t * made alpm_list_t a public type (alpm_list.h header) * removed additional storage for registered DBs in pacman source * some code cleanup * removed duplicate (pm)list_display functions from pacman source * misc code cleanup
2007-01-18Dan McGee <dpmcgee@gmail.com>Aaron Griffin1-0/+4
* Removed some unnecessary headers and library links * Made things static if possible * Cleaned up makefiles a bit * Fixed some old comments in the code * Fixed some errors the static code checker splint pointed out * Backwards arguments in a memset call in _alpm_db_read (could have been worse) * Other various small fixes Other: * Default to 80 columns when getcols cannot determine display width * Removal of ._install as a valid install file in packages
2006-12-05Corrected -Rsc operation - dependancy info was not being read from the DBAaron Griffin1-0/+3
2006-12-01* Fixed the bug where -R pkgA pkgB failed when pkgA depended on pkgBAaron Griffin1-9/+20
2006-12-01* Cosmetic changes and typo fixesAaron Griffin1-2/+3
* IgnorePkg and --ignore work again * Partial changes to support removal of conflicts for -U and -A (INCOMPLETE)
2006-11-24* Fixed some error output for "-Sd" and "-Rsc" dealing with missing/ignoredAaron Griffin1-1/+2
depends * Added valgrind suppression file
2006-11-22* Completed getinfo api changes (pmmissing_t, pmtrans_t, etc)Aaron Griffin1-90/+51
* Modified some dependancy checking * Changed "performing local database upgrade" message to be more clear * Change 'usize' to 'isize' in database files * Scriptlet output is now sent to pacman's log file * Limited some debugging output to be more clear
2006-10-31Numerous changes:Aaron Griffin1-2/+23
* Furthered the "lazy caching" to force the pkgcache to read nothing (INFRQ_NONE) by default. Anything requiring package data should now check the infolevel of each package and attempt to update it. This could be ironed out a bit more later (by using the front-end get_info function * Switched to libfetch. Drastic changes to the download code and the callback progress bar functions. Also fixed the return value of _alpm_downloadfiles_forreal. Downloading now supports http, ftp, https, and files urls, along with 'mtime's and numerous other fancy features from libfetch.
2006-10-21Fixes from frugalware: few 'typos' included while patchingAaron Griffin1-12/+28
Also re-added Judd's dependancy fix in libalpm/deps.c
2006-10-20A handful of minor changes:Aaron Griffin1-23/+23
* Removed the PMList typedef, in favor of the same naming scheme other structs use 'pmlist_t' * Added a time stamp on debug output, to make it more informational * Moved alpm_db_register to _alpm_db_register, making the public function not take a callback parameter
2006-10-15Merged frugalware changes (too many to list). Also added some config fileAaron Griffin1-37/+55
handling changes (support [sections] to carry over to included files - this helps with backwards compatibility with existing pacman config files)
2006-07-04bugfix: when looking at provides, defer to the new, to-be-installed ↵Judd Vinet1-12/+27
package's provisios instead of the the existing package's
2006-05-15first stage of i18n stuff from VMiklosJudd Vinet1-18/+19
2006-03-07removed an unexpected logAurelien Foret1-1/+0
2006-03-02reworked the db object to prepare future integration with different backendsAurelien Foret1-8/+6
2006-03-01added ERROR logs in case of malloc failures (patch from VMiklos ↵Aurelien Foret1-1/+4
<vmiklos@frugalware.org>)
2006-02-17prepend library function names with _alpm (helped with the patch from ↵Aurelien Foret1-57/+57
VMiklos <vmiklos@frugalware.org>) added log and event callbacks to sync_commit internal transactions
2006-02-07code cleanupAurelien Foret1-8/+0
2006-01-21resolvedeps: return the depmiss info to the frontend in case of failureAurelien Foret1-4/+23
2006-01-18more code cleanup yetAurelien Foret1-89/+53
2006-01-17fixed detection for duplicate entries in list of deps/conflictsAurelien Foret1-3/+18
2006-01-15pulled out conflict checkings from checkdeps() in its own function: ↵Aurelien Foret1-232/+102
checkconflicts()
2006-01-14checkdeps:Aurelien Foret1-9/+50
- merged missing chunks of code from pacman 2.9.7 - more debug logs
2006-01-09- merged pkg_new and pkg_dummy functionsAurelien Foret1-2/+2
- renamed _alpm_log_action to _alpm_logaction
2006-01-08cleanupJudd Vinet1-3/+0
2006-01-08removed old/disable provides-conflict checking codeJudd Vinet1-29/+1
2006-01-08In the database-against-targets conflict checks, scan db packages' providesJudd Vinet1-3/+52
fields and look for packages that want to exclusively provide a provisio that the target package also provides.
2006-01-07added more debug logs in the sync conflict/replace codeAurelien Foret1-4/+10
2006-01-05- started to rename list_XXX calls to _alpm_list_XXXAurelien Foret1-1/+0
- fixed 2 compilation warnings
2006-01-02fixed a segfault in removdepsAurelien Foret1-5/+31
updated removedeps to keep in sync with pacman 2.9.x
2006-01-02patch from VMiklos - use PACKAGE_VERSION instead of PACMAN_VERSIONJudd Vinet1-1/+1