summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAge
* Report missing directory if we can not initialise alpm libraryAllan McRae2013-07-30
| | | | | | | | | | | | | When pacman failed to initialise the alpm library due to the database directory being missing (either via the root not existing or the database directory itself not existing), it just printed the non-informative message "could not find or read directory". Add the directory information the the error output. E.g.: error: failed to initialize alpm library (could not find or read directory: /this/does/not/exist/var/lib/pacman/) Signed-off-by: Allan McRae <allan@archlinux.org>
* Remove setlocale usage from the backendAllan McRae2013-07-30
| | | | | | | | Using setlocale in the backend is bound to lead to frontend issues and we have have been using epoch in our databases since April 2007 (commit 47622eef). Remove support for old style times. Signed-off-by: Allan McRae <allan@archlinux.org>
* Warn when directory ownership differs between filesystem and packageAllan McRae2013-07-30
| | | | | | | | | | | | | We currently only warn if a directory's permissions differ, but using -Qkk on my system shows that directory permissions tend to change in packages reasonably frequently without notice. Provide a warning in such cases so that it can be altered. Example output: (1/1) reinstalling nginx warning: directory ownership differs on /var/lib/nginx/proxy/ filesystem: 33:0 package: 0:0 Signed-off-by: Allan McRae <allan@archlinux.org>
* Only note backup file changes with -QkkAllan McRae2013-07-30
| | | | | | | | Backup files are expected to be changed and should not be flagged by -Qkk. Note changed back-up files in -Qkk but do not count them as altered. Do not report backup files in -Qqkk. Signed-off-by: Allan McRae <allan@archlinux.org>
* Fix whitespace in makepkg.sh.in and makepkg-template.pl.inJason St. John2013-07-30
| | | | | | | | Replace spaces with tabs in one instance. Remove extra spaces. Signed-off-by: Jason St. John <jstjohn@purdue.edu> Signed-off-by: Allan McRae <allan@archlinux.org>
* Fix whitespace in pacsort.c and pactree.cJason St. John2013-07-30
| | | | | | | | Replace spaces with tabs. Remove extra spaces. Signed-off-by: Jason St. John <jstjohn@purdue.edu> Signed-off-by: Allan McRae <allan@archlinux.org>
* pacdiff: provide an --output option to show any .pac* filesJonathan Frazier2013-07-30
| | | | | | | | | This is an option to just echo's the pacnews/pacsaves instead of merging or removing them. This can be used to check the config status such as in a cron job without modifying the system. Signed-off-by: Jonathan Frazier <eyeswide@gmail.com> Signed-off-by: Allan McRae <allan@archlinux.org>
* pacdiff: make pacmandb search the default type.Jonathan Frazier2013-07-30
| | | | | Signed-off-by: Jonathan Frazier <eyeswide@gmail.com> Signed-off-by: Allan McRae <allan@archlinux.org>
* pacdiff: improve speed, accuracy finding active configs using pacmandbJonathan Frazier2013-07-30
| | | | | | | | | | | | | | | | | | | | | | | | | | | This is a new search type, using -p or --pacmandb options. It reads config file locations directly from the local pacman db. It will find active configs anywhere they are defined in installed packages. It is not dependant on outside configs such as updatedb.conf or scanning a large set of directories for find. This will find more pacnews than find when searching with the current default of /etc, and it is faster than both find and updatedb when searching the entire fs. When run directly after an update, the local db is more likely to be cached than all files in /etc or / as other methods read. This will increase performance further post upgrade. After a package is removed and a pacsave is created, this method will not find these pacsaves until the base config is added to the local db again. These files have no influence in a working system and only take up a few blocks of disk space. Active configs need to be dealt with immediately to keep a system working. pacsaves related to removed configs can remain for weeks or months without problems. I would recommend occasionally running other methods such as --locate to remove them. Signed-off-by: Jonathan Frazier <eyeswide@gmail.com> Signed-off-by: Allan McRae <allan@archlinux.org>
* pacdiff: rework search type handling, add --find optionJonathan Frazier2013-07-30
| | | | | | | | | | Change cmd tests to if (( USE_FIND ))... as it is cleaner. All search cmds have an option and a variable initialized to zero. The active option should be set to 1. Add a switch to exclude multiple search options. set the default when all are equal to zero. Signed-off-by: Jonathan Frazier <eyeswide@gmail.com> Signed-off-by: Allan McRae <allan@archlinux.org>
* pacdiff: add --nocolor option for the terminally challenged.Jonathan Frazier2013-07-30
| | | | | | | Allow colors to be disabled for use on broken/serial terminals. Signed-off-by: Jonathan Frazier <eyeswide@gmail.com> Signed-off-by: Allan McRae <allan@archlinux.org>
* pacdiff: allow multiple separated optionsJonathan Frazier2013-07-30
| | | | | | | loop over arguments, this will allow adding options such as --nocolor Signed-off-by: Jonathan Frazier <eyeswide@gmail.com> Signed-off-by: Allan McRae <allan@archlinux.org>
* pacdiff: clean up and reword --helpJonathan Frazier2013-07-30
| | | | | | | | Clean up and reword --help get rid of all the echos to make it easier to read in source. Signed-off-by: Jonathan Frazier <eyeswide@gmail.com> Signed-off-by: Allan McRae <allan@archlinux.org>
* pacdiff: Search and give warnings for older pacsave.[0-9]* filesJonathan Frazier2013-07-30
| | | | | Signed-off-by: Jonathan Frazier <eyeswide@gmail.com> Signed-off-by: Allan McRae <allan@archlinux.org>
* Corrected return codes for Sg flagAshley Whetter2013-07-22
| | | | | | | | Non-zero is now returned if a group is searched for that doesn't exist. Fixes FS#36097. Signed-off-by: Ashley Whetter <awhetter.2011@my.bristol.ac.uk> Signed-off-by: Allan McRae <allan@archlinux.org>
* Fix typoAllan McRae2013-07-22
| | | | Signed-off-by: Allan McRae <allan@archlinux.org>
* clarified descriptions for pactree -r (--help)Zulker Nayeen Nahiyan2013-07-22
| | | | | Signed-off-by: Zulker Nayeen Nahiyan <nahiyan02@gmail.com> Signed-off-by: Allan McRae <allan@archlinux.org>
* Clarify inter-conflicts messageAllan McRae2013-07-22
| | | | | | | Use a clear message rather than using a made up word to describe what we are doing. Signed-off-by: Allan McRae <allan@archlinux.org>
* Install makedepends and checkdepends togetherAshley Whetter2013-07-22
| | | | | | | Fixes FS#31557 Signed-off-by: Ashley Whetter <awhetter.2011@my.bristol.ac.uk> Signed-off-by: Allan McRae <allan@archlinux.org>
* pacdiff: Add quit to found pacnew optionsJonathan Frazier2013-07-22
| | | | | Signed-off-by: Jonathan Frazier <eyeswide@gmail.com> Signed-off-by: Allan McRae <allan@archlinux.org>
* Carry a copy of gpgme.m4Allan McRae2013-07-22
| | | | | | | On systems without gpgme installed, autoreconf will fail with an unrelated error message unless the gpgme.m4 file is present. Signed-off-by: Allan McRae <allan@archlinux.org>
* Remove autoclean.shAllan McRae2013-07-22
| | | | | | Use 'git clean' instead. Signed-off-by: Allan McRae <allan@archlinux.org>
* Patch ltmain on autoreconfAllan McRae2013-07-22
| | | | | | | | We used to carry a patched version of ltmain in our repos to fix libtools issues with -Wl,-as-needed. Now that ltmain is "generated" by autoreconf, we manually patch it afterwards. Signed-off-by: Allan McRae <allan@archlinux.org>
* Use autoreconf in autogen.shAllan McRae2013-07-22
| | | | Signed-off-by: Allan McRae <allan@archlinux.org>
* Update gitignore files for use with autoreconfAllan McRae2013-07-22
| | | | Signed-off-by: Allan McRae <allan@archlinux.org>
* Remove autotools filesAllan McRae2013-07-22
| | | | Signed-off-by: Allan McRae <allan@archlinux.org>
* be_sync: avoid crashing on files in the root of a DBDave Reisner2013-07-22
| | | | | | | | | | | | | | If a sync DB is malformed and contains entries in the root of the archive, load_pkg_for_entry will leave the 'filename' variable empty, leading to a crash in the ensuing strcmp() calls which determine the DB fragment being examined. While this isn't a read error, this should be reported to the user so that it can be addressed by the creator of the DB. As seen: https://bbs.archlinux.org/viewtopic.php?pid=1297766 Signed-off-by: Dave Reisner <dreisner@archlinux.org>
* Hide unused parameter warnings when building without libcurlAllan McRae2013-07-22
| | | | Signed-off-by: Allan McRae <allan@archlinux.org>
* Add missing headerAllan McRae2013-07-22
| | | | | | Exposed when building with --without-libcurl Signed-off-by: Allan McRae <allan@archlinux.org>
* use full path when checking for mountpointsAndrew Gregory2013-07-05
| | | | | Signed-off-by: Andrew Gregory <andrew.gregory.8@gmail.com> Signed-off-by: Allan McRae <allan@archlinux.org>
* do not check error from close(2)Dave Reisner2013-07-05
| | | | | | | | | | | | | | | On operating systems we support, the behavior is always such that the kernel will do the right thing as far as invalidating the file descriptor, regardless of the eventual return value. Therefore, potentially looping and calling close multiple times is wrong. At best, we call close again on an invalid FD and throw a spurious EBADF error. At worst, we might close an FD which doesn't belong to us when a multi-threaded application opens its own file descriptor between iterations of the loop. Signed-off-by: Dave Reisner <dreisner@archlinux.org> Signed-off-by: Allan McRae <allan@archlinux.org>
* Consolidate and improve table implementationsSimon Gomizelj2013-07-05
| | | | | | | | | | | | | | | | Implement both the VerbosePkgList and the summary message with the same table. Improve VerbosePkgList by caching attributes and cell's lengths instead of recaculating them. Right align every cell that containing a file size in both the VerbosePkgList and the summary. Simplify the printf statements and the alignment application. Signed-off-by: Simon Gomizelj <simongmzlj@gmail.com> Signed-off-by: Allan McRae <allan@archlinux.org>
* update to automake 1.14Allan McRae2013-06-26
| | | | Signed-off-by: Allan McRae <allan@archlinux.org>
* query_fileowner: resolve trailing . or .. in pathsAndrew Gregory2013-06-26
| | | | | | | | | The full path needs to resolved any time it ends with "." or "..", not just when those are the entire path. This allows strange-but-valid paths such as: "/home/." to be queried. Signed-off-by: Andrew Gregory <andrew.gregory.8@gmail.com> Signed-off-by: Allan McRae <allan@archlinux.org>
* query_fileowner: remove useless path variableAndrew Gregory2013-06-26
| | | | | | | | We no longer need it for resolving package files and using it to resolve root is unnecessary as alpm does that for us. Signed-off-by: Andrew Gregory <andrew.gregory.8@gmail.com> Signed-off-by: Allan McRae <allan@archlinux.org>
* query_group: allow package filtersAndrew Gregory2013-06-26
| | | | | | | | | Relocated query_group() to allow calling filter(). Fixes FS#19716 Signed-off-by: Andrew Gregory <andrew.gregory.8@gmail.com> Signed-off-by: Allan McRae <allan@archlinux.org>
* skip unknown repo names for pacman -SlAndrew Gregory2013-06-26
| | | | | | | Brings pacman -Sl behavior in line with other listing operations. Signed-off-by: Andrew Gregory <andrew.gregory.8@gmail.com> Signed-off-by: Allan McRae <allan@archlinux.org>
* Enable inverted patterns in NoExtract and NoUpgrade.Patrick Steinhardt2013-06-26
| | | | | | | | It is now possible to invert patterns in NoExtract and NoUpgrade. This feature allows users to whitelist certain files that were previously blacklisted by another entry. Signed-off-by: Allan McRae <allan@archlinux.org>
* deps.c: check for indirect deps when orderingAndrew Gregory2013-06-26
| | | | | | | | | | | | | | | | | | | | On upgrades, indirect dependencies were not being detected if there was a dependency in between them that was not part of the transaction. For example, with the dependency chain: pkg1 -> pkg2 -> pkg3, if pkg1 and pkg3 are being upgraded but not pkg2 pacman would not order pkg1 and pkg3 properly. This was particularly problematic when replacements were involved because the replaced package(s) would be removed at the start of the transaction. If an install script required the replacer and lacked a direct dependency, it could fail. Fixes FS#32764. Partially fixes FS#23011. Signed-off-by: Andrew Gregory <andrew.gregory.8@gmail.com> Signed-off-by: Allan McRae <allan@archlinux.org>
* Make --unrequired filter packages that are optdep as wellOlivier Brunel2013-06-26
| | | | | | | Specify it twice to only filter direct dependencies. Signed-off-by: Olivier Brunel <i.am.jack.mail@gmail.com> Signed-off-by: Allan McRae <allan@archlinux.org>
* Install unchanged backup files to get correct timestamps.Patrick Steinhardt2013-06-26
| | | | | | Fixes FS#35515. Signed-off-by: Allan McRae <allan@archlinux.org>
* Merge branch 'maint'Allan McRae2013-06-26
|\
| * Respect paths with spaces on --installAndrea Scarpino2013-06-23
| | | | | | | | | | | | | | makepkg --install doesn't quote the absolute path, so if the path contains spaces pacman -U fails. Signed-off-by: Allan McRae <allan@archlinux.org>
* | Merge branch 'maint'Allan McRae2013-06-18
|\|
| * 4.1.2 release preparationAllan McRae2013-06-18
| | | | | | | | Signed-off-by: Allan McRae <allan@archlinux.org>
| * contrib: update .gitignoreAllan McRae2013-06-18
| | | | | | | | Signed-off-by: Allan McRae <allan@archlinux.org>
| * Pull translation updatesAllan McRae2013-06-18
| | | | | | | | Signed-off-by: Allan McRae <allan@archlinux.org>
| * pacscripts: Update for pacman changesKarol Blazewicz2013-06-18
| | | | | | | | | | | | | | | | Changes to pacman mean that -Sp can be called without root permissions and '-d' needs passed twice to completely ignore dependencies. Signed-off-by: Karol Błażewicz <karol.blazewicz at gmail.com> Signed-off-by: Allan McRae <allan@archlinux.org>
| * pacscripts: don't read the whole package from cacheKarol Blazewicz2013-06-18
| | | | | | | | | | | | | | | | | | | | '-q' means "Exit as soon as each specified pattern or filename has been matched." There is no reason to keep reading the whole package from the cache when the install script has already been printed to stdout. Signed-off-by: Karol Błażewicz <karol.blazewicz at gmail.com> Signed-off-by: Allan McRae <allan@archlinux.org>
| * checkupdates: Consistency in environmental variable nameAllan McRae2013-06-18
| | | | | | | | | | | | | | Use CHECKUPDATES_DB rather than CHECKUPDATE_DB for consistency with the script name. Signed-off-by: Allan McRae <allan@archlinux.org>