summaryrefslogtreecommitdiffstats
path: root/lib
AgeCommit message (Collapse)AuthorFilesLines
2007-02-06Cleaning up mistakes. :PDan McGee1-1/+1
2007-02-06Attempt #2 at -S/-Su unification: verify that the 'force' option has been ↵Aaron Griffin2-1/+6
read before comparing versions
2007-02-06Copy-pasta errors. 8)Aaron Griffin1-8/+8
2007-02-06Attempt to unify the -S and -Su version comparissons for when a package is newerAaron Griffin2-31/+35
See FS#5388
2007-02-04Implemented a crappy version of -Qu (query upgrades). This simply outputs theAaron Griffin5-14/+170
packages to be upgraded in a -Su operation. Much of the code is duplicated from sync.c. TODO: move the implementation to upgrades.c, and reimplement the sync_sysupgrade function in terms of this: trans->packages = alpm_get_upgrades();
2007-02-04* Added archive verification when loading package metadata for -u and -AAaron Griffin1-16/+27
operations (now aborts on a corrupt archive) * Fixed the pm_fprintf newline error that was plaguing us. It seems a line resetting 'neednl' was removed a while back (by me). This causes all the output errors we've been seeing
2007-02-01* Minor output fix (move colon so it's not part of the URL)Aaron Griffin2-1/+8
* Added ldconfig on --sync operations too
2007-02-01Loading package data from a file was ALWAYS generating the filelist, instead ofAaron Griffin1-17/+22
using the in-package one. This is now fixed, and an autogenerated one is used as a last resort. This fixes the bug where /.CHANGELOG showed up in -Ql.
2007-02-01Cleaned up some of the metadata controlAaron Griffin1-17/+9
2007-02-01* !strcmp reads funny (as "not string compare" - switch those to == 0, which hasAaron Griffin1-3/+6
a positive connotation. * Added a nice TODO
2007-01-31* Forgot the int->enum header checkinAaron Griffin1-1/+1
* Removed the dep-sorting TODO item - switch the sorting to a topological sort later (I'll let Dan do the CS stuff, heh)
2007-01-31Switched an int to an enumAaron Griffin1-1/+1
2007-01-31Fix corrupt DB entry handling when loading package entries.Aaron Griffin2-55/+61
* scan loops no longer abort on corrupt entries * reloading a cache package (and discovering it corrupt) no longer prints 2 messages and uses the pre-build "remove from package cache" function NOTE: The TODOs in there are important for later w.r.t. cleaning up corrupt DB entries but there are some logical complexities with doing so, so I'm holding off for now.
2007-01-31Debug logging changes:Aaron Griffin10-85/+75
* 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-31slight line spacing/indent updatesDan McGee3-3/+3
2007-01-30K. Piche <kevin.piche@cgi.com>Aaron Griffin21-0/+302
* ALPM_LOG_FUNCTION macro and all the great work to add this macro everywhere
2007-01-30K. Piche <kpiche@rogers.com>Aaron Griffin16-98/+104
* 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 McGee4-19/+34
* 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 McGee13-31/+34
* 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-29* Fix building outside $(srcdir).Jürgen Hötzel1-1/+1
* Removed ./gen-mirrorlist.sh invocation from configure script: Mirror-files are generated by make, not configure.
2007-01-26Dan McGee <dpmcgee@gmail.com>Aaron Griffin3-5/+5
* 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-26* Fix FS #3107- Use ISO date styleAaron Griffin1-4/+5
* Fix FS #5409- document that pacman.conf repo ordering is important Signed-off-by: Dan McGee <dpmcgee@gmail.com>
2007-01-24* Shuffled some of the alpm_list free funtions - still not perfect, but betterAaron Griffin5-35/+68
* Added alpm_list_remove_node for single list node removal * Proper error checking/output for failed db_read/db_write (missing files) * Invalid packages (missing files) are now removed from the package cache * -Qs and -Ss output now look the same * config.rpath causes errors on one machine I had, so I added it to CVS * Fixed a "clobbered memory" issue when installing groups - only the outer list should be free'd, not the contained data
2007-01-24This mainly deals with code clarity- removing currently unneededAaron Griffin25-150/+207
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-23James Rosten <seinfeld90@gmail.com>Aaron Griffin1-3/+4
* attempt to unlink file AFTER moving to .pacsave always fails
2007-01-23* Added some calloc calls to replace the malloc-then-set-to-zero functionalityAaron Griffin3-11/+7
* Fixed -Ss output so as not to call alpm_list_getdata with a NULl list * Added a NULL check in alpm_list_getdata * Fixed alpm_list_add_sorted to properly handle a new / beginning insertions
2007-01-22* Added a check for .FILELIST for package validity in addition to .PKGINFOAaron Griffin1-0/+3
2007-01-22Introduced an infinite loop during the pmlist -> alpm_list transition, whoopsAaron Griffin1-0/+1
2007-01-20Moved some decls to make the "pkg_invalid" patch compile again.Aaron Griffin1-6/+9
2007-01-19Whoops. There's a 0 where there should be a 1.Aaron Griffin1-1/+1
2007-01-19Johannes Weiner <hannes@saeurebad.de>Aaron Griffin1-15/+8
* package cleanup (pkg_invalid) refactoring
2007-01-19Johannes Weiner <hannes@saeurebad.de>Aaron Griffin1-55/+6
* use calloc to zero-out new packages (far more ideal) * use memcpy to copy primatives when copying package structures
2007-01-19Preliminary checkin for alpm_list conversionAaron Griffin39-917/+916
* 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-18Some confusion with variable names in unlink_file caused unlink to try and ↵Aaron Griffin1-8/+8
find the _relative_ file instead of absolute. The absolute path name has also been used in some of the output there too.
2007-01-18Dan McGee <dpmcgee@gmail.com>Aaron Griffin15-24/+31
* 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
2007-01-18Dan McGee <dpmcgee@gmail.com>Aaron Griffin1-3/+3
* fix "warning: dereferencing type-punned pointer will break strict-aliasing rules"
2007-01-18Added strerror() output on unlink failureAaron Griffin1-68/+70
2007-01-17* Misc logging changesAaron Griffin2-10/+6
Addition of a forced fflush in an attempt to diagnose mutli-logging Removal of varargs from the internal logaction function, they are handled in alpm_logaction just fine
2007-01-17James Rosten <seinfeld90@gmail.com>Aaron Griffin1-80/+77
* _alpm_remove_commit refactoring * clean up/fixes by Dan McGee <dpmcgee@gmail.com>
2007-01-17Jürgen Hötzel <juergen@hoetzel.info>Aaron Griffin3-57/+20
* avoid repeated regex compilations (regex for search string do not change while scanning the package database) * remove needless string duplication (regex function do not change target string nor free them) * code cleanup This patch improves search performance: bash-3.2$ time ./src/pacman/pacman.static.old -Ss "(database|web).*server" >/dev/null real 0m1.026s user 0m0.544s sys 0m0.208s bash-3.2$ time ./src/pacman/pacman.static -Ss "(database|web).*server" >/dev/null real 0m0.777s user 0m0.456s sys 0m0.128s bash-3.2$
2007-01-17cvsignore cleanup and additionsAaron Griffin1-0/+6
2007-01-11* Jürgen Hötzel <juergen@hoetzel.info>Aaron Griffin3-3/+87
_alpm_db_load_pkgcache: use mergesort to improve performance
2007-01-11* Dan McGee <dpmcgee@gmail.com>Aaron Griffin1-28/+8
Documentation cleanup
2007-01-03* bug fix FS#6100 - fix --print-uris outputAaron Griffin3-2/+10
2007-01-03* Bug fix FS#6058Aaron Griffin2-0/+7
properly remove entries from "Required By" instead of wiping it out entirely
2007-01-02* Missing error label in sync.cAaron Griffin2-1/+5
* Additional debug output for db_write
2006-12-29* Removed latest fix from TODO.autoconfAaron Griffin1-67/+81
* Attempted fix for FS#6100 - "-Spd foo" failure * Beginning of refactoring from Dan McGee <dpmcgee@gmail.com>
2006-12-22Cleanup from Dan McGee <dpmcgee@gmail.com> and Jürgen Hötzel ↵Aaron Griffin4-7/+11
<juergen@hoetzel.info> * configure swig check * misc libalpm cleanup
2006-12-22* Properly fix the NoUpgrade issues.Aaron Griffin1-13/+12
2006-12-22* Unused variable 'path'Aaron Griffin1-2/+1