summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAge
* Ensure stdout/stderr are flushed when asking questionsDan McGee2011-04-01
| | | | | | | | | Addresses FS#23492, where the question was shown without knowing what one was answering to. Ensure we flush our output streams before printing the question, and flush the stream on which we ask the question before waiting for an answer. Signed-off-by: Dan McGee <dan@archlinux.org>
* Add default changelog functions to pkg_operationsDan McGee2011-04-01
| | | | | | | | So we don't segfault when calling this on be_sync loaded packages. They return logical values as much as possible for indicating there is no changelog available. Signed-off-by: Dan McGee <dan@archlinux.org>
* Ensure dbpath is not null when populating sync databaseDan McGee2011-04-01
| | | | | | | | | | | | | | | | | | | | | | We didn't do this sanity check before trying to open an archive. If the alpm dbpath wasn't set, the sync database dbpath would be NULL, causing us to hang indefinitely in archive_read_open_filename() rather than erroring out. We already have a corresponding check in local_db_populate(). The following program will test this case, and hangs before this patch without the call to set_dbpath: int main(int argc, char *argv[]) { alpm_initialize(); // alpm_option_set_dbpath("/var/lib/pacman/"); pmdb_t *core = alpm_db_register_sync("core"); pmpkg_t *pkg = alpm_db_get_pkg(core, "pacman"); return 0; } Signed-off-by: Dan McGee <dan@archlinux.org>
* Ignore upcoming new values in sync backendDan McGee2011-04-01
| | | | | | | PGPSIG and SHA256SUM are new and we can safely ignore them for now if we come across them. Signed-off-by: Dan McGee <dan@archlinux.org>
* makepkg: remove unnecessary tr usageAllan McRae2011-03-30
| | | | | | | | The use of "tr" only leads to trouble. Remove unnecessary usage of it from within makepkg. Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
* makepkg: avoid usage of tr to sidestep locale issuesDave Reisner2011-03-30
| | | | | | | | | to quote dan: "turkish will FUCK YOU UP. this is not the first or the last time" Signed-off-by: Dave Reisner <d@falconindy.com> Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
* alpm/handle.c: ensure handle is not NULL before proceedingRémy Oudompheng2011-03-29
| | | | | | | | | Many alpm_option_get/set_*() functions already check this and set pm_errno to the right value, but not all, so this improves consistency. Signed-off-by: Rémy Oudompheng <remy@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
* call alpm_option_get_localdb once in syncfirst()Andrea Scarpino2011-03-29
| | | | | Signed-off-by: Andrea Scarpino <andrea@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
* Fix an outdated commentDan McGee2011-03-29
| | | | Signed-off-by: Dan McGee <dan@archlinux.org>
* Add initial 3.5.2 notesDan McGee2011-03-28
| | | | Signed-off-by: Dan McGee <dan@archlinux.org>
* Update .mailmap fileDan McGee2011-03-28
| | | | Signed-off-by: Dan McGee <dan@archlinux.org>
* Update pacman.pot with changed stringsDan McGee2011-03-27
| | | | Signed-off-by: Dan McGee <dan@archlinux.org>
* Clarify error message in pacman-db-upgradeDan McGee2011-03-27
| | | | | | Addresses FS#23451. Signed-off-by: Dan McGee <dan@archlinux.org>
* Ensure reported missing dependencies show correct version comparisonDan McGee2011-03-25
| | | | | | | | | | | | This addresses FS#23424. The -dd backend code was introduced in commit b6ec9019d77, and unfortunately the munged depend used for comparison did not carry through to the eventual display of this version. To fix this, we undo some of the depcmp_tolerant() business introduced, and instead make a new pmdepend_t object if necessary when the no dependency version flag is set. This results in the correct depend being copied to the missing depend passed onto the frontend. Signed-off-by: Dan McGee <dan@archlinux.org>
* Mark various functions in deps.c staticDan McGee2011-03-25
| | | | Signed-off-by: Dan McGee <dan@archlinux.org>
* Move alpm_find_dbs_satisfier() function down in deps.cDan McGee2011-03-25
| | | | | | | This will make sense for a later commit when static/non-static properties of other functions are changed. Signed-off-by: Dan McGee <dan@archlinux.org>
* Rework find_requiredby() to not use _alpm_dep_edge()Dan McGee2011-03-25
| | | | | | | And move the sort after the final loop; we don't need to sort once for each database we look at. Signed-off-by: Dan McGee <dan@archlinux.org>
* Don't include version in dep string if mod == ANYDan McGee2011-03-25
| | | | Signed-off-by: Dan McGee <dan@archlinux.org>
* Update usage instruction stringsDan McGee2011-03-25
| | | | | | | | | * Address FS#23433 by documenting -d vs. -dd * Drop the useless "as well", "also", "too", and "that won't break packages" strings from -R usage * Fix alignment of multiline strings in source (no string change) Signed-off-by: Dan McGee <dan@archlinux.org>
* Add -T, --deptest to usage messageRay Kohler2011-03-24
| | | | | | | Fixes FS #23369 Signed-off-by: Ray Kohler <ataraxia937@gmail.com> Signed-off-by: Dan McGee <dan@archlinux.org>
* Make log redirection sanerJan Steffens2011-03-24
| | | | | | | | | My main motivation was to remove the "sync", which can stall for minutes on a busy machine (FS#23378). I also cleaned up the redirection. Signed-off-by: Jan Steffens <jan.steffens@gmail.com> Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
* alpm/db: do not close local DB in alpm_db_unregister_allDave Reisner2011-03-24
| | | | | | | | | pacman 3.5.0 removed alpm_db_register_local, so calling alpm_db_unregister_all leaves the front end in a position where there's no local db, and no way to re-register it. Signed-off-by: Dave Reisner <d@falconindy.com> Signed-off-by: Dan McGee <dan@archlinux.org>
* Update doc/index.txt with 3.5.1 release dateDan McGee2011-03-23
| | | | Signed-off-by: Dan McGee <dan@archlinux.org>
* Bump version to 3.5.1Dan McGee2011-03-23
| | | | Signed-off-by: Dan McGee <dan@archlinux.org>
* Updated 3.5.1 translations from TransifexDan McGee2011-03-23
| | | | Signed-off-by: Dan McGee <dan@archlinux.org>
* Add new Serbian translation from TransifexSlobodan Terzić2011-03-23
| | | | | | Thanks! Signed-off-by: Dan McGee <dan@archlinux.org>
* 3.5.1 NEWS updatesDan McGee2011-03-23
| | | | Signed-off-by: Dan McGee <dan@archlinux.org>
* Documentation consistency fixesDan McGee2011-03-23
| | | | | | | Fix the way we were referring to paths (use ``), .pac* extensions (use ''), and other general things across our main manpages. Signed-off-by: Dan McGee <dan@archlinux.org>
* Fix documentation typo in makepkg.8Dan McGee2011-03-23
| | | | Signed-off-by: Dan McGee <dan@archlinux.org>
* Minor code cleanupsDan McGee2011-03-21
| | | | | | | Wrap lines of long length, noticed while creating and messing around with some of the other maint branch patches. Signed-off-by: Dan McGee <dan@archlinux.org>
* Ensure package removal list does not contain duplicatesDan McGee2011-03-21
| | | | | | | | | Noticed with the openoffice/libreoffice replacement scheme where many packages are listed as replacements to one package, thus electing it for removal multiple times. Ensure a given package is not already present before placing it in the removal list. Signed-off-by: Dan McGee <dan@archlinux.org>
* Fix line_offset not being reset in _alpm_archive_fgets()Dan McGee2011-03-21
| | | | | | | | | | This is a rather serious data corruption issue that luckily manifested itself today in a noticable way. A package in testing had replaces entries read in as ["%RE pkgname", "%RE"] which was clearly wrong. This happens when we hit the end of an archive block, do not have a newline, and have to continue reading from the next block to complete the line. Signed-off-by: Dan McGee <dan@archlinux.org>
* Do not query group selection when using -SpAllan McRae2011-03-21
| | | | | | | Remove unnecessary output when using -Sp. Fixes FS#23340. Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
* Some more zsh completion tidy upAllan McRae2011-03-21
| | | | | | | Changes for consistency across functions Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
* Fix zsh completionAllan McRae2011-03-21
| | | | | | | | Fixes completion for "pacman -S <tab>" and "pacman -S repo/<tab>" Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de> Signed-off-by: Dan McGee <dan@archlinux.org>
* Restore --debug/--verbose output without a primary operationDan McGee2011-03-21
| | | | | | | | | This is by no means a guarantee of this behavior remaining the same in the future, but it is easy enough to do what we used to in this case by delaying any sort of error condition until after we are completely done parsing options. Addresses FS#23370. Signed-off-by: Dan McGee <dan@archlinux.org>
* Add a few more notes about translating using TransifexDan McGee2011-03-20
| | | | Signed-off-by: Dan McGee <dan@archlinux.org>
* Update source translation files in prep for 3.5.1Dan McGee2011-03-20
| | | | Signed-off-by: Dan McGee <dan@archlinux.org>
* Remove unnecessary NULL checkDan McGee2011-03-20
| | | | | | fp can never be NULL at this point in the code, proven by Coccinelle. Signed-off-by: Dan McGee <dan@archlinux.org>
* Fix comparison to 0 rather than NULLDan McGee2011-03-20
| | | | | | Another fix found by Coccinelle example semantic patches. Signed-off-by: Dan McGee <dan@archlinux.org>
* Fix assignment before NULL checkDan McGee2011-03-20
| | | | | | Easy fix, found using null_ref.cocci example Coccinelle script. Signed-off-by: Dan McGee <dan@archlinux.org>
* Add missing include for size_tDan McGee2011-03-20
| | | | | | Needed for things like our strndup() substitute function. Signed-off-by: Dan McGee <dan@archlinux.org>
* Fix libtool and LDFLAGS reordering issuesLukas Fleischer2011-03-20
| | | | | | | | This is a Debian patch (from #347650) that makes libtool play nicely with "-Wl,--as-needed". Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de> Signed-off-by: Dan McGee <dan@archlinux.org>
* Fix handling of ignored packagesPang Yan Han2011-03-20
| | | | | | | | | | | | | | | | | | | Noted in FS#23342. When the user attempts to install an ignored package and answers no when asked whether to install it, pacman bails out with: "error: target not found: packagename" This is because satisfiers are not found for the package and execution continues to process_group(), where the package is treated as a group (which does not exist). In addition, test ignore006.py is updated with PACMAN_RETCODE=0 since saying no to installing an ignored package should not be considered an error. Signed-off-by: Pang Yan Han <pangyanhan@gmail.com> Signed-off-by: Xavier Chantry <chantry.xavier@gmail.com> Signed-off-by: Dan McGee <dan@archlinux.org>
* Use sane umask for repo db downloadsAllan McRae2011-03-20
| | | | | | | Fixes FS#23343. Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
* makepkg: Improve optdepends extractionAllan McRae2011-03-20
| | | | | | | | | | Prevents issues where optdepends descriptions contain a bracket. Also, strip all comments from arrays before joining them. Fixes FS#23307. Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
* Correctly parse %DELTAS% entries in sync DBtuxce2011-03-17
| | | | | | | We erroniously dropped the call to _alpm_delta_parse() when macro-izing, causing segfaults for repos that provide deltas. Addresses FS#23314. Signed-off-by: Dan McGee <dan@archlinux.org>
* Ensure we have a root partition when checking spaceDan McGee2011-03-17
| | | | | | | | | Partially addresses the "why doesn't CheckSpace work in a chroot" issue. We can't make it work, but we can at least detect when it won't work by checking for a partition for our given installation root. If we can't determine the mountpoint for this, bail out with an error. Signed-off-by: Dan McGee <dan@archlinux.org>
* pacman.8: (re)document behavior of reading from stdinDave Reisner2011-03-16
| | | | | | | | Change the term 'packages' to 'targets' in the synopsis as well, since command line parameters could just as well be groups, repos, or URLs. Signed-off-by: Dave Reisner <d@falconindy.com> Signed-off-by: Dan McGee <dan@archlinux.org>
* Warn but don't error for unknown pacman.conf directivesDan McGee2011-03-16
| | | | | | | | | | | | | | | | | This makes all the pacman developers' jobs harder as we have to switch files whenever running multiple pacman versions and are using newly introduced options. Instead of erroring out, print warnings and continue on. This patch also fixes a const-correctness issue. We immediately cast a 'const char *' to a 'char *' in setrepeatingoption(), which is just plain wrong as we manipulate the underlying string. Fix the types and remove the now unnecessary variable. Finally, a few messages change here for consistency and clarity and because we continue parsing rather than bailing out on a problem. Signed-off-by: Dan McGee <dan@archlinux.org>