summaryrefslogtreecommitdiff
path: root/lib/libalpm/be_files.c
Commit message (Collapse)AuthorAge
* Remove FREEPKG macro and correctly type _alpm_pkg_freeDan McGee2007-04-28
| | | | Signed-off-by: Dan McGee <dan@archlinux.org>
* Clean up gettext on the libalpm sideDan McGee2007-04-26
| | | | | | | Remove inclusion of libintl.h from all files, because we can do it once in util.c where the _() macro is defined. Signed-off-by: Dan McGee <dan@archlinux.org>
* Clarify some English messages as suggested by Nagy Gabor. I even did the hardDan McGee2007-03-22
| | | | | | work of fixing these in the translation files, and I removed a few fuzzys while doing so. If any more patches for translations come, try to do it against these files.
* * Noted a misspelling for later (after we are not in string freeze).Dan McGee2007-03-12
|
* * Fix wrong filesize being recorded to local DB. Reported by Andreas Radke.Dan McGee2007-03-12
|
* * Removed ${CFLAGS} from Makefile.am(s) as it was causing all CFLAGS to beDan McGee2007-03-12
| | | | | | | | duplicated. * Updated the util Makefile.am to link with the proper libalpm.la. * Fixed bitmasking issues in be_files.c and db.h. * Rankmirrors updates from James Rosten (with some cleaning up of my own). KeyboardInterrupts are now handled gracefully.
* This commit looks much more monumental than it is. Almost all just #includeDan McGee2007-03-05
| | | | | | | | 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.
* * Fixed a whole mess of extra '/' pathing issues when a different root isAaron Griffin2007-03-04
| | | | | | | | | | | | | | specified * Use db->path when appropriate * Commented out the FAKEROOT checks in libalpm. This should never ever be done. TODO test this quite a bit, as this will never cause the transactions to fail if RW operations are requested... right now it is totally up to the front end to decide when to fail * Use realpath() to canonicalize the root path when specified, so _alpm_makepath() doesn't freak out * Fixed some output/indent of MDFile and SHAFile algorithms * More efficient sprintf() usage in MDFile/SHAFile * Added real error output to _alpm_makepath
* * handle changes: callbacks should check handle first, as there's a fewAaron Griffin2007-03-04
| | | | | | | | | occasions where some alpm stuff could be used without initializing the library (vercmp is one). TODO make these functions (handle accessors) better by returning "library not initialized" instead of failing. * Removed NoUpgrade lines from pacman.conf - we need to test this! * Re-corrected the lib targets for src/util/* * make dist seems to have updated the po files
* Big commit this time:Aaron Griffin2007-03-03
| | | | | | | | | | | | | | | | | | | | | | | * 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
* * Unifying placement of REPLACES in desc file, as pacman2 does. We'll worryDan McGee2007-02-28
| | | | | | | | about bigger DB changes later, but lets not screw anything up for release. * Removed some weird uses of "not ... ==" usage in pactest- correct me if I'm wrong, but isn't "!=" a lot more clean and concise? * Print description of failed tests in the pactest summary. This could get dirty with a lot of failed tests though, so watch out.
* * Enforce const char* params when using stringsAaron Griffin2007-02-26
| | | | | | | * 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
* * Cleaned up some debug outputAaron Griffin2007-02-22
| | | | | | | | | * Fixed a segfault in the conflict checking code * Added an automatic failure in the case of -A/-U for a replacement of an existing package. This requires a large amount of work and is postponed for now. Example: If ncmpc is installed, pacman -U /path/to/ncmpc-svn.pkg.tar.gz will fail with and appropriate error message
* * Fixed inconsistency of args- _alpm_db_read, _alpm_db_write.Dan McGee2007-02-21
|
* * Re-added a compare function for syncpkg's - it was removed without thinkingAaron Griffin2007-02-21
| | | | | | | | | | | | | | | properly * Error when re-reading the DB for replacements, wrong info level * Removed an duplicate debug message "checking for package replacements" * Check ignorepkg for REAL upgrades... * Properly check the NOSAVE flag * some unlink_file (remove.c) cleanup * fix indent level on handle.c * Force libalpm paths to end with a '/' char * Fixed 'target' looping in conflict.c (pmsyncpkg_t, not pmpkg_t) * Added some debug output to cache and db scanning ** All pactest tests succeed again, yay **
* Removed desc_localized for the time being. We don't have localizedAaron Griffin2007-02-13
| | | | | | descriptions, nor do we actually build them with the newest makepkg. The actual implementation in here seems like it could be done better, and it soaks a large amount of CPU time according to profilers.
* Spruced up the TODOs a bit, got rid of some of them since a lot of it wasDan McGee2007-02-07
| | | | | duplicate anyway. Also removed the last of the ORE tags and replaced them with TODOs.
* Fix corrupt DB entry handling when loading package entries.Aaron Griffin2007-01-31
| | | | | | | | | | * 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.
* Debug logging changes:Aaron Griffin2007-01-31
| | | | | | | | | | | | | | | | * 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.
* K. Piche <kevin.piche@cgi.com>Aaron Griffin2007-01-30
| | | | * ALPM_LOG_FUNCTION macro and all the great work to add this macro everywhere
* * Shuffled some of the alpm_list free funtions - still not perfect, but betterAaron Griffin2007-01-24
| | | | | | | | | | * 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
* This mainly deals with code clarity- removing currently unneededAaron Griffin2007-01-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>
* Preliminary checkin for alpm_list conversionAaron Griffin2007-01-19
| | | | | | | | | * 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
* Dan McGee <dpmcgee@gmail.com>Aaron Griffin2007-01-18
| | | | | | | | | | | | | | * 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
* * Missing error label in sync.cAaron Griffin2007-01-02
| | | | * Additional debug output for db_write
* * Cosmetic changes and typo fixesAaron Griffin2006-12-01
| | | | | * IgnorePkg and --ignore work again * Partial changes to support removal of conflicts for -U and -A (INCOMPLETE)
* * Completed getinfo api changes (pmmissing_t, pmtrans_t, etc)Aaron Griffin2006-11-22
| | | | | | | | * 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
* * repo-add script - to add entries to a db file directly from package data ↵Aaron Griffin2006-11-20
| | | | | | | | | | (no PKGBUILD) * libalpm api changes - move from a _getinfo(p, WHAT_WE_WANT) scheme to a typesafe _get_what_we_want(p) scheme [not 100% complete yet] * some const correctness changes * removal of PM_* types in alpm.h in favor of the pm*_t types used throughout libalpm
* * Numerous mini valgrind fixes.Aaron Griffin2006-11-14
| | | | | | | | | | * Addition of hacky architecture check in the _splitname function * Removal of libfetch from the archlinux proper - it has been renamed to libdownload and can be found at http://phraktured.net/libdownload * Merge of _some_ of the Frugalware makepkg change - this may still be incomplete * Removal of libftp from cvs proper * PKGBUILD manpage now says 'PKGBUILD' instead of FrugalBuild (he he)
* * Improved mcheck outputAaron Griffin2006-11-08
| | | | | * Added minor libalpm const correctness * Mini-memory fixes
* * Fixed an error message that should be a debug messageAaron Griffin2006-11-08
| | | | | * Fixed "the big segfault" - dbs_sync list was being modified while iterating * over the list, big No-No. Now using a while loop over alpm_list_count.
* Fixed pacman -U:Aaron Griffin2006-11-01
| | | | | | * Accidental database read of a file-based package (whoops) * Proper fetching of url-based -U or -A Removed some newlines from _alpm_log calls, to make debug output more concise
* Numerous changes:Aaron Griffin2006-10-31
| | | | | | | | | | | | * 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.
* Moved downloaded db unpacking to the backend files, to easier allow conversionAaron Griffin2006-10-25
| | | | from db to whatever format we need.
* Minor changes:Aaron Griffin2006-10-21
| | | | | * Moved the pmhandle_t extern decl around * Fixed a doxygen complaint
* A handful of minor changes:Aaron Griffin2006-10-20
| | | | | | | | * 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
* Merged frugalware changes (too many to list). Also added some config fileAaron Griffin2006-10-15
| | | | | handling changes (support [sections] to carry over to included files - this helps with backwards compatibility with existing pacman config files)
* first stage of i18n stuff from VMiklosJudd Vinet2006-05-15
|
* fixed a regression (patch from VMiklos <vmiklos@frugalware.org>)Aurelien Foret2006-03-21
|
* put back treename in db->pathAurelien Foret2006-03-14
|
* db_write: fixed md5sum fieldAurelien Foret2006-03-07
|
* reworked the db object to prepare future integration with different backendsAurelien Foret2006-03-02