summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAge
* Merge branch 'maint'Dan McGee2011-01-29
|\
| * libalpm: Fix a missing "nicht" (not) in German translation.Thomas Bächler2011-01-28
| | | | | | | | Signed-off-by: Dan McGee <dan@archlinux.org>
| * Enable failure on server error for curl download commandDan McGee2011-01-28
| | | | | | | | | | | | | | | | This will make a 404 a silent failure that returns an error code rather than 0 as was previously done, screwing up the logic used by pacman/libalpm to allow moving onto the next server on a failed download. Fixes FS#22630. Signed-off-by: Dan McGee <dan@archlinux.org>
* | pactest: pass entire test to rule.check()Dan McGee2011-01-29
| | | | | | | | | | | | | | | | We were piecemeal passing fields from the test object in and it was getting out of hand, and future work would have added yet another argument. Instead, just pass the entire test object and entrust the rule to get what it needs. Signed-off-by: Dan McGee <dan@archlinux.org>
* | Remove need to explicitly register the local DBDan McGee2011-01-29
| | | | | | | | | | | | | | | | | | Perform the cheap struct and string setup of the local DB at handle initialization time to match the teardown we do when releasing the handle. If the local DB is not needed, all real initialization is done lazily after DB paths and other things have been configured anyway. Signed-off-by: Dan McGee <dan@archlinux.org>
* | Ignore known but unused package descfile fieldsDan McGee2011-01-28
| | | | | | | | | | | | | | | | We explicitly place 'pkgbase' (and used to place 'force') fields inside PKGINFO files, so ignore them silently instead of printing an error for them. Also make the error message for unknown keys actually contain the key. Signed-off-by: Dan McGee <dan@archlinux.org>
* | Fix libtool performance regression with many argumentsDan McGee2011-01-28
| | | | | | | | | | | | | | | | | | | | Reported and fixed upstream, patching our version for now until a future release fixes it: * http://lists.gnu.org/archive/html/bug-libtool/2011-01/msg00007.html * http://git.savannah.gnu.org/cgit/libtool.git/commit/?id=286e87b1030c353d9cfc89dbb72d59e0391cb693 Signed-off-by: Dan McGee <dan@archlinux.org>
* | Fix memory leak and error code in DB readingDan McGee2011-01-24
| | | | | | | | | | | | | | We were returning a package error code rather than a DB one, and we would leak the archive memory if the database file didn't exist. Signed-off-by: Dan McGee <dan@archlinux.org>
* | pkgsearch: handle non-matching lines gracefullyDan McGee2011-01-24
| | | | | | | | | | | | | | | | | | Before any non-matching line would trigger some perl warnings about undefined variables. If a line doesn't match, just show it to the user unprocessed; this is seen with warning and error messages pacman not so helpfully emits on stdout rather than stderr. Signed-off-by: Dan McGee <dan@archlinux.org>
* | Update contrib/ MakefileDan McGee2011-01-24
| | | | | | | | | | | | | | | | We didn't have the proper dependencies specified for our scripts after the move to *.in extensions, so a change to a file didn't trigger a rebuild. Also remove old stuff from .gitignore. Signed-off-by: Dan McGee <dan@archlinux.org>
* | Query fileowner performance improvementsDan McGee2011-01-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Clean up some of the code by doing less string copying and printing. This is accomplished by either doing it after we know we need it, or taking advantage of the fact that some strings never change such as the root directory prefix. Also, fix an issue where a file at the root level (e.g. /foobar) could not be queried. End result is a much faster user experience when combined with the mbasename() changes. These timings are for looking up 113 files in /etc/, some of which are owned and some which are not. $ find /etc -maxdepth 1 -type f | xargs time pacman -Qo >/dev/null 6.10user 0.05system 0:06.17elapsed 99%CPU (0avgtext+0avgdata 131040maxresident)k 0inputs+0outputs (0major+9436minor)pagefaults 0swaps $ find /etc -maxdepth 1 -type f | xargs time ./src/pacman/.libs/lt-pacman -Qo >/dev/null 0.86user 0.04system 0:00.92elapsed 99%CPU (0avgtext+0avgdata 131120maxresident)k 0inputs+0outputs (0major+9436minor)pagefaults 0swaps I'll take a 600% increase in speed. Signed-off-by: Dan McGee <dan@archlinux.org>
* | Improve mbasename performanceDan McGee2011-01-22
| | | | | | | | | | | | | | Rather than roll our own, use strrchr() instead, which glibc may have a better implementation than the simple iteration method we were using. Signed-off-by: Dan McGee <dan@archlinux.org>
* | Merge branch 'backup-status'Dan McGee2011-01-22
|\ \
| * | Be smarter about failure to read backup file contentsDan McGee2011-01-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | Instead of always printing MISSING, we can switch on the errno value set by access() and print a more useful string. In this case, handle files we can't read by printing UNREADABLE, print MISSING on ENOENT, and print UNKNOWN for anything else. Fixes FS#22546. Signed-off-by: Dan McGee <dan@archlinux.org>
| * | Mark backup status strings as untranslatedDan McGee2011-01-22
| | | | | | | | | | | | | | | | | | | | | | | | And also change "Not Modified" -> "UNMODIFIED" for consistency. This makes it a lot easier to machine-parse this and not worry about locale differences. Signed-off-by: Dan McGee <dan@archlinux.org>
| * | Refactor backup file status check into separate functionDan McGee2011-01-22
| | | | | | | | | | | | | | | | | | This will make it a lot easier to use this stuff elsewhere. Signed-off-by: Dan McGee <dan@archlinux.org>
* | | Add a few new provides testsDan McGee2011-01-22
| | | | | | | | | | | | | | | | | | | | | | | | These deal with already-installed packages and how they should be the preferred provider in cases where provider selection now occurs. A few involve multiple sync repos. Signed-off-by: Dan McGee <dan@archlinux.org>
* | | pactest: sort repos by alpha order in config fileDan McGee2011-01-22
| | | | | | | | | | | | | | | | | | | | | | | | The order was non-deterministic before, and just happened to work for sync023.py as it was written. Ensure there is some sort of predictable ordering. Signed-off-by: Dan McGee <dan@archlinux.org>
* | | pactest: use new-style python classesDan McGee2011-01-22
|/ / | | | | | | Signed-off-by: Dan McGee <dan@archlinux.org>
* | pactest: revamp modified logicDan McGee2011-01-22
| | | | | | | | | | | | | | | | | | | | Remove all logic dealing with PKG_MODIFIED as this rule no longer exists. This removes a bunch of unnecessary stat and checksum logic that most of the time we were never even using. Also update the file modified checks to mark every file created using mkfile() with an older time so any modified checks will just work without hacks. Signed-off-by: Dan McGee <dan@archlinux.org>
* | Modify all pactests to not use PKG_MODIFIEDDan McGee2011-01-22
| | | | | | | | | | | | | | | | All conditions that this particular rule tested are better served by using a more specific rule, whether that be checking a package version or whether files inside the package have changed or still exist. Signed-off-by: Dan McGee <dan@archlinux.org>
* | pactest: pylint changes for pmdbDan McGee2011-01-22
| | | | | | | | Signed-off-by: Dan McGee <dan@archlinux.org>
* | pactest: pylint changes for utilDan McGee2011-01-22
| | | | | | | | Signed-off-by: Dan McGee <dan@archlinux.org>
* | pactest: pylint changes for pmtestDan McGee2011-01-22
| | | | | | | | Signed-off-by: Dan McGee <dan@archlinux.org>
* | pactest: pylint changes for pmpkgDan McGee2011-01-22
| | | | | | | | Signed-off-by: Dan McGee <dan@archlinux.org>
* | pactest: pylint changes for pmruleDan McGee2011-01-22
| | | | | | | | Signed-off-by: Dan McGee <dan@archlinux.org>
* | pactest: pylint changes for pmenvDan McGee2011-01-22
| | | | | | | | Signed-off-by: Dan McGee <dan@archlinux.org>
* | pactest: pylint changes for pactestDan McGee2011-01-22
| | | | | | | | Signed-off-by: Dan McGee <dan@archlinux.org>
* | pactest: pylint changes for pmfileDan McGee2011-01-22
| | | | | | | | Signed-off-by: Dan McGee <dan@archlinux.org>
* | Compute download size for sync packages onlyDan McGee2011-01-22
| | | | | | | | | | | | | | Neither packages from files nor packages from the local database will ever have a download size. Signed-off-by: Dan McGee <dan@archlinux.org>
* | Merge branch 'maint'Dan McGee2011-01-22
|\|
| * Update 3.4.3 release dateDan McGee2011-01-22
| | | | | | | | Signed-off-by: Dan McGee <dan@archlinux.org>
| * Copy new backend translation over from frontend translationDan McGee2011-01-21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Since it is the same string. Done with some bash looping and sed magic. for src in po/*.po; do echo $src newtrans=$(grep -A1 "msgid.*$1" $src | tail -n1) newtrans=${newtrans//\\/\\\\} echo "$newtrans" fname=${src##*/} dest=lib/libalpm/po/$fname sed -i -e "/msgid.*$1/{N; s/msgstr.*$/$newtrans/}" $dest done Signed-off-by: Dan McGee <dan@archlinux.org>
| * 3.4.3 release preparationDan McGee2011-01-21
| | | | | | | | Signed-off-by: Dan McGee <dan@archlinux.org>
* | Merge branch 'epoch-work'Dan McGee2011-01-22
|\ \
| * | doc: update current list of authorsDan McGee2011-01-22
| | | | | | | | | | | | | | | | | | | | | | | | Allan, I had no idea you were not listed here. I think you count as an active developer at the moment. Also, move Aaron to the past contributors section. Signed-off-by: Dan McGee <dan@archlinux.org>
| * | doc: add a vercmp manpageDan McGee2011-01-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This includes info on version comparison that is very similar to the stuff in the pacman manpage, but also a few vercmp examples, the return values, and other fun stuff. Also update the version comparison stuff in the pacman manpage. Signed-off-by: Dan McGee <dan@archlinux.org>
| * | makepkg: encode epoch in version specifier if > 0Dan McGee2011-01-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This makes things consistent with everywhere else we are incorporating the new optional epoch field. Add a helper function that forms the version string for you and use it in makepkg where I found 'pkgver.*-.*pkgrel'. This exposes a few shortcomings in a previous "Override pkgver" patch (2020e629) in the install package and check if built functions. Signed-off-by: Dan McGee <dan@archlinux.org>
| * | Remove epoch as an independent fieldDan McGee2011-01-21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Instead, go the same route we have always taken with version-release in libalpm and treat it all as one piece of information. Makepkg is the only script that knows about epoch as a distinct value; from there on out we will parse out the components as necessary. This makes the code a lot simpler as far as epoch handling goes. The downside here is that we are tossing some compatibility to the wind; packages using force will have to be rebuilt with an incremented epoch to keep their special status. Signed-off-by: Dan McGee <dan@archlinux.org>
| * | Allow version comparison to contain epoch specifierDan McGee2011-01-21
| | | | | | | | | | | | | | | | | | | | | | | | | | | Adapting from RPM, follow the [epoch:]version[-release] syntax. We can also borrow some of their parsing code for our purposes (thanks!). Add some new tests to our vercmp shell script tester for epoch comparisons, and then make the code work with these newfangled epoch specifiers. Signed-off-by: Dan McGee <dan@archlinux.org>
| * | pactest: add more testing for epochDan McGee2011-01-21
| | | | | | | | | | | | Signed-off-by: Dan McGee <dan@archlinux.org>
| * | pactest: Rename epoch pactestsDan McGee2011-01-21
| | | | | | | | | | | | Signed-off-by: Dan McGee <dan@archlinux.org>
* | | Makefile: Use git describe --dirty for GIT VERSIONXavier Chantry2011-01-22
| | | | | | | | | | | | | | | | | | | | | | | | dirty indicates if the repo has uncommited changes or not when building, so dont hardcode this info. Signed-off-by: Xavier Chantry <chantry.xavier@gmail.com> Signed-off-by: Dan McGee <dan@archlinux.org>
* | | repo-add: only attempt to create deltas when askedAllan McRae2011-01-22
|/ / | | | | | | | | | | | | | | | | | | repo-add should only attempt to create the delta file when using the -d option. Also adjust a couple of tests to use the "double bracket" syntax. Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
* | Add a likely_pkg hint argument to sync_db_readDan McGee2011-01-21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In most (all?) cases, we will process all files for a given sync database entry sequentially. The code currently does an _alpm_pkg_find() for every file in the database, but we had the "current" package readily available. Shift some local variables around a bit to expose this to sync_db_read() and use it if the package is the correct one. On my system, this cuts calls to _alpm_pkg_find() from 20,769 to 10,349 calls during a -Qu operation, and results in a ~30% speedup of the same operation (0.35 sec -> 0.27 sec). This benefit should be apparent anywhere we read in the full contents of the sync databases. Signed-off-by: Dan McGee <dan@archlinux.org>
* | Improve splitname memory allocationDan McGee2011-01-21
| | | | | | | | | | | | | | | | We don't need to create a temporary copy of the string if we are smart with our pointer manipulation and string copying. This saves a bunch of string duplication during database parsing, both local and sync. Signed-off-by: Dan McGee <dan@archlinux.org>
* | Improve depends string parsingDan McGee2011-01-21
| | | | | | | | | | | | | | | | | | Remove the need for an unconditional string duplication by using pointer arithmetic instead, and strndup() instead of an unspecified-length strdup(). This should reduce memory churn a fair amount as this is called pretty frequently during database loads. Signed-off-by: Dan McGee <dan@archlinux.org>
* | Add strndup fallback function to libalpm utilDan McGee2011-01-21
| | | | | | | | | | | | The same fallback we are currently using in the pacman frontend. Signed-off-by: Dan McGee <dan@archlinux.org>
* | Update valgrind suppressions fileDan McGee2011-01-21
| | | | | | | | | | | | | | We haven't tweaked this in a while, but some of the old stuff seems to no longer be necessary and there are a few new things we should add. Signed-off-by: Dan McGee <dan@archlinux.org>
* | Add a pactest for the situation in FS#7524Dan McGee2011-01-21
| | | | | | | | | | | | | | Confirming the current behavior. And yes, the error message is still no better than it was when this was reported 3.5 years ago. Signed-off-by: Dan McGee <dan@archlinux.org>