Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2011-06-27repo-add: add new command, repo-elephantDave Reisner
_ _ / \__/ \_____ / / \ \ `\ ) \''/ ( |\ `\__)/__/'_\ / ` //_|_|~|_|_| ^""'"' ""'"' Signed-off-by: Dave Reisner <d@falconindy.com>
2011-06-27repo-add: enforce file extensionsDave Reisner
Allow one of 4 archive extensions: .tar{,.gz,.xz,.bz2} for each of the 2 valid repo extensions: .db and .files. Check for this via 'verify_repo_extension' directly after option parsing to assert that this extension is present, and again after files have been added to get the proper archive option for bsdtar. Signed-off-by: Dave Reisner <d@falconindy.com>
2011-06-27repo-add: move command invocation out of arg parsing loopDave Reisner
Signed-off-by: Dave Reisner <d@falconindy.com>
2011-06-27repo-add: refactor repacking of repo fileDave Reisner
Dump the whole conditional and filter the contents of the directory to create an empty or non-empty archive. Signed-off-by: Dave Reisner <d@falconindy.com>
2011-06-24repo-add.8.txt: document valid DB file extensionsDave Reisner
Signed-off-by: Dave Reisner <d@falconindy.com>
2011-06-24repo-add: use format_entry for all desc/depends fieldsDave Reisner
This ranks high on the code readability scale. The same function formats all of our data and writes to the metadata file at once. Signed-off-by: Dave Reisner <d@falconindy.com>
2011-06-24repo-add: store multi-value fields as arraysDave Reisner
Fields like groups and depends should be stored as arrays. This requires rewriting our write_list_entry function to accomodate our new data type. This new function will not write to a file, but rather only format it. Signed-off-by: Dave Reisner <d@falconindy.com>
2011-06-24repo-add: bashify reading of .PKGINFO fileDave Reisner
grep and sed aren't needed here, and this removes the truly ugly manipulation of IFS. The process substituion could just as well be a herestring, but it breaks vim's syntax highlighting. Style over substance, mang. Signed-off-by: Dave Reisner <d@falconindy.com>
2011-06-24Merge branch 'master' of git://projects.archlinux.org/pacmanDave Reisner
* 'master' of git://projects.archlinux.org/pacman: pactree: carry a list of databases for dep resolution makepkg: Remove a lone quotation mark makepkg: remove the cleancache option Don't require a transaction for sync DB updates Move locking functions to handle Add a 'valid' flag to the database object Move database 'version' check to registration time Do database signature checking at load time
2011-06-24pactree: carry a list of databases for dep resolutionDave Reisner
Declare an alpm_list which, for now, only holds our local database. walk_deps and walk_reverse_deps are refactored to account for this, and a helper function is added to wrap alpm_db_get_pkg for traversing a list. This is groundwork for letting pactree walk the sync DBs. Signed-off-by: Dave Reisner <d@falconindy.com> Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-24makepkg: Remove a lone quotation markWieland Hoffmann
Allan broke it in 4bdb868. Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-24makepkg: remove the cleancache optionAllan McRae
This is a fairly useless feature given all it does is an "rm" on a directory. It is also unlikely that you would want to remove the entire SRCDEST anyway, but rather just the old files. Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-24makepkg: fix incorrect parenthesis in gettext callDave Reisner
allan broke it in 4bdb868a. Signed-off-by: Dave Reisner <d@falconindy.com>
2011-06-24Don't require a transaction for sync DB updatesDan McGee
Instead, just do the required locking directly in the backend in calls to alpm_db_update(). Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-24Move locking functions to handleDan McGee
These operate on the handle, and the state is stored on the handle, so move them where they belong. Up until now only the transaction stuff calls them, but this will soon change and alpm_db_update() will handle locking all on its own. Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-24Add a 'valid' flag to the database objectDan McGee
Start by converting all of our flags to a 'status' bitmask (pkgcache status, grpcache status). Add a new 'valid' flag as well. This will let us keep track if the database itself has been marked valid in whatever fashion. For local databases at the moment we ensure there are no depends files; for sync databases we ensure the PGP signature is valid if required/requested. The loading of the pkgcache is prohibited if the database is invalid. Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-24Move database 'version' check to registration timeDan McGee
This is another step toward doing both local database validation (ensuring we don't have depends files) and sync database validation (via signatures if present) when the database is registered. Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-24Do database signature checking at load timeDan McGee
This is the ideal place to do it as all clients should be checking the return value and ensuring there are no errors. This is similar to pkg_load(). We also add an additional step of validation after we download a new database; a subsequent '-y' operation can potentially invalidate the original check at registration time. Note that this implementation is still a bit naive; if a signature is invalid it is currently impossible to refresh and re-download the file without manually deleting it first. Similarly, if one downloads a database and the check fails, the database object is still there and can be used. These shortcomings will be addressed in a future commit. Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-24Document group and providers selectionAllan McRae
The format required for selection of packages within the group selection dialog is not entirely obvious, so provide some documentation. Fixes FS#24134. Signed-off-by: Allan McRae <allan@archlinux.org>
2011-06-24makepkg: clean-up of output messagesAllan McRae
There was a lot of inconsistency in how strings that should not be translated (program names, option flags, PKGBUILD directives, etc) were handled. This patch moves them all outside the gettext invocation for consistency and to prevent accidental translation. Note that some of these may need reverted if they cause difficulties in translation due to gettext usage in bash not taking positional parameters for arguments. A quick survey of current translations indicates that this issue will be rare. Also, we should be able to catch these before a full string freeze given we are going to probably need a "developer preview" release before the next release series. Signed-off-by: Allan McRae <allan@archlinux.org>
2011-06-24pactest: generate sync DB's in memoryDan McGee
Sync database are no longer exploded on the filesystem. Rework the logic used to generate our test databases so we can create them completely in memory without having to write the individual files to disk at all. The local database is unaffected. Note that several shortcomings in libalpm parsing were discovered by this change, which have since been temporarily patched around in this test suite: * archive_fgets() did not properly handle a file that ended in a non-newline, and would silently drop the data in this line. * sync database with only the file entries and not the directories would fail to parse properly, and even cause segfaults in some cases. Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-24pactest: refactor install file creationDan McGee
Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-24pactest: move filelist/backup generation into package objectDan McGee
These are definite methods that operate on a package, so move them there which cleans up util a bit more. Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-24pactest: make pmfile a bit more pythonicDan McGee
Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-24pactest: small cleanups and chmod -x most filesDan McGee
Remove empty docstrings, small and easy pylint fixes, etc. Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-24pactest: clean up database section writingDan McGee
Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-24pactest: add isize attribute, fix url attributeDan McGee
Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-24Remove three unnecessary usages of alpm_list_count()Dan McGee
For the files count when loading from a package, we can keep a counter. The two in the frontend were completely useless due to the fact that if sync_dbs is non-NULL, alpm_list_count() will always be greater than 0. Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-24Prevent segfault when parsing unexpected sync database fileDan McGee
This doesn't fix the real (bigger) problem of failing to parse sync databases without directory entries, but it does prevent the parser from segfaulting when the first desc file encountered did not have a directory entry, among other conditions. Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-24parse-options: simplify unused-arg & parameter printingDave Reisner
Signed-off-by: Dave Reisner <d@falconindy.com>
2011-06-23Merge branch 'po-split'Dan McGee
2011-06-23repo-add: fix path designation regressionDave Reisner
b899099 made path checking a bit more strict than I had intended, and would actually forbid creation of a repo in $PWD if only the filename was specified. readlink would be the fun and easy solution here, but it's avoided due to portability issues, making the validation process a bit more verbose. Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-23scripts/po/: add pacman-keyDan McGee
This has gettext strings, but wasn't added to the list of files in POTFILES.in just yet. Add it and update the catalogs. Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-23src/pacman/po/: prune message catalog and translationsDan McGee
Now that we have performed the split, prune the catalogs of all scripts-only messages. All old messages were pruned from the files using the following command: sed -i -e '/^#\~/,$d' *.po Note: the diff on this commit looks much less insane if the --patience option is used. Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-23scripts/po/: prune message catalog and translationsDan McGee
Now that we have performed the split, prune the catalogs of all pacman-only messages. All old messages were pruned from the files using the following command: sed -i -e '/^#\~/,' *.po Note: the diff on this commit looks much less insane if the --patience option is used. Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-23po/: split into scripts/po/ and src/pacman/po/Dan McGee
This is the first step at separating the pacman message catalog and the scripts message catalog. Makefiles, configure.ac, and other such files are adjusted accordingly, as well as renaming files. The TEXTDOMAIN of scripts is also adjusted. Note that no actual pot or po files get changed here; these will get pruned in a future commit so each catalog contains only the necessary messages. Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-23Update all translation filesDan McGee
This is for the eventual 4.0.0 release, but more importantly to logically separate new translations and strings from the PO split about to happen between pacman and scripts. Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-23Let configure gettext setup know we use ngettext()Dan McGee
Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-23makepkg: Added checks in check_software for distcc, ccache, strip and gzipEric Bélanger
Dan: slightly shorten some of the messages. Signed-off-by: Eric Bélanger <snowmaniscool@gmail.com> Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-23makepkg: remove distcc/makeflags option interactionDan McGee
Way back in c94bfbaba when refactoring makepkg options handling, I added these lines to unset MAKEFLAGS if '!distcc' was set in a PKGBUILD (not taking into account makepkg.conf settings). This was an attempt to say "if it is broken in distcc, it is probably broken even more". However, this is silly as one should be using '!makeflags' as well. Remove the linkage. Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-22Convert backup list to new pmbackup_t typeDan McGee
This allows us to separate the name and hash elements in one place and not scatter different parsing code all over the place, including both the frontend and backend. Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-22makepkg: fix 'check_sofware' typoDan McGee
Allan broke it! Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-22repo-add: style cleanupDave Reisner
Unify function braces to be top right opening, bottom left closing. Signed-off-by: Dave Reisner <d@falconindy.com> Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-22Fixed outdated documentation in test/pacman/READMEKerrick Staley
test/pacman/README mentioned the -A flag, which no longer exists. Signed-off-by: Kerrick Staley <mail@kerrickstaley.com> Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-22makepkg: add software check functionAllan McRae
Add a function that checks for the software needed by makepkg to process a PKGBUILD with the requested options. This allows makepkg to bail early in the packaging process. Many other checks can be added to this function... Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-22Remove old TODO listsAllan McRae
These had not been touched since 2007 and had lost most of their relevance. The bug tracker is a better place for the filing of ideas. Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-22makepkg: move comment into correct placeAllan McRae
Oops... Introduced by commit d21f6ca4. Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-22makepkg: adjust libprovides/depends messagesAllan McRae
Contractions are less clear for non-native speakers so should be avoided (and cause syntax highlighting issues). Also, the 'provides' and 'depends' strings are not to be translated. Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-22makepkg: allow specifying alternative build directoryAllan McRae
Add a BUILDDIR variable (which can be overridden in the environment) to specify an alternative location for building the package. This is useful for people who want to build on a different filesystem for improved performance (e.g. tmpfs). Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2011-06-22makepkg: Add UPX compression supportAllan McRae
This patch enables the automatic compression of executable binaries using UPX when the 'upx' options is specified in makepkg.conf or the PKGBUILD. Additional arguments can be passed to UPX by specifying the UPXFLAGS variable. Original-patch-by: Bryce Gibson <bryce@gibson-consulting.com.au> Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>