summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2012-06-25contrib: fix typo in PKGBUILD.vimAllan McRae
FS#30156 Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2012-06-25repo-add: add checkdepends informationAllan McRae
Similar to the case for makedepends, it is useful to be able to access this information without parsing a PKGBUILD. Signed-off-by: Allan McRae <allan@archlinux.org>
2012-06-25makepkg: install deps with --repackageAllan McRae
I have noticed that quite a number of packages fail with "makepkg -R" when their (make)dependencies are not installed. Adjust makepkg to check for dependencies when used with -R. This can still be avoided by using --nodeps/-d. Signed-off-by: Allan McRae <allan@archlinux.org>
2012-06-25Allow wildcards in PURGE_TARGETS to match any type of file except for ↵Jeremy Huntwork
directories. Signed-off-by: Jeremy Huntwork <jhuntwork@lightcubesolutions.com>
2012-06-25makepkg: allow url to be overridden in split packagesAllan McRae
This is already being used (despite not working...) in packages in the Arch Linux repos. Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2012-06-25Portability fixes for makepkgJeremy Huntwork
Allow makepkg to work correctly when used with find from busybox. Fix handling of cross directory symlinks. Signed-off-by: Jeremy Huntwork <jhuntwork@lightcubesolutions.com> Signed-off-by: Allan McRae <allan@archlinux.org>
2012-06-25query: avoid false ownership matches for files in rootDave Reisner
Check for an exact match when querying ownership of files in the root. Previously, our test was too simple and would match the the basename of package files against the query parameter, e.g. $ pacman -Qo config /config is owned by cower-git 20120614-1 Adds a new test to verify this behavior, query007.py. Fixes FS#30388. Signed-off-by: Dave Reisner <dreisner@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2012-06-25updpkgsums: avoid fancy quoting in error messageDave Reisner
m4 has a field day parsing escapes and actually vandalizes this string, causing the error to look like: ==> ERROR: \PKGBUILD\ not found or is not a file Avoid all quoting and just match up with how makepkg reports errors (no quoting at all). Signed-off-by: Dave Reisner <dreisner@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2012-06-25contrib: sed out @SCRIPTNAME@ in edit commandDave Reisner
Signed-off-by: Dave Reisner <dreisner@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2012-06-25add line length parameter to _alpm_strip_newlineDave Reisner
If known, callers can pass the line size to this function in order to avoid an strlen call. Otherwise, they simply pass 0 and _alpm_strip_newline will do the call instead. Signed-off-by: Dave Reisner <dreisner@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2012-06-25add real_line_size to alpm_read_bufferDave Reisner
We inevitably call strlen() or similar on the line returned from _alpm_archive_fgets(), so include the line size of the interesting line in the struct. Signed-off-by: Dave Reisner <dreisner@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2012-06-25pkgdelta: add missing --version longoptDave Reisner
This was missed in the switch to parseopts, and was caught by distcheck. Signed-off-by: Dave Reisner <dreisner@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2012-06-25check proper variable for NULLDave Reisner
Signed-off-by: Dave Reisner <dreisner@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2012-06-25Create repo-remove symlink in scripts dirAllan McRae
Fix the creation of the repo-remove symlink in the scripts/ dir on building. Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2012-06-25diskspace: canonicalize path to download dirDave Reisner
With lazy loading in place, it's now quite obvious that we aren't necessarily checking the right mountpoint for necessary download space. Signed-off-by: Dave Reisner <dreisner@archlinux.org>
2012-05-21libalpm/remove.c - add doxygenAndrew Gregory
Signed-off-by: Andrew Gregory <andrew.gregory.8@gmail.com> Signed-off-by: Dan McGee <dan@archlinux.org>
2012-05-20paccache: allow running as rootDave Reisner
The main motivation for this change is to allow this to be run as a cron job. Satisfies FS#29897 and some other undocumented requests for this. Signed-off-by: Dave Reisner <dreisner@archlinux.org>
2012-05-20makepkg: rework libdependsAllan McRae
Rewrite the handling of libdepends. The primary advantage are: - Moves functionality from write_pkginfo() to find_libdepends(). - The order of the depends array in the PKGBUILD is kept in the package. - An unneeded libdepends is only a warning and not an error. This allows putting a libdepend on a library that is dlopened. - It is now modular so can be extended to library types other than ELF *.so. - Finding the list of libraries a package depends only occurs when a libdepend is specified in the depends array. Signed-off-by: Allan McRae <allan@archlinux.org>
2012-05-20repo-add: add makedepends informationAllan McRae
This is useful for tools that automatically rebuild packages and thus require to generate a build order. These entries are skipped by pacman. Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2012-05-20makepkg: write makedepends into .PKGINFOAllan McRae
Currently there is no way to access the makedepends for a package apart from parsing its PKGBUILD. Put these into the .PKGINFO file with the idea of making them available in the repo dbs so that automated build tools can readily determine build order. Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2012-05-20Define _FORTIFY_SOURCE in CPPFLAGSAllan McRae
The -D_FORTIFY_SOURCE=2 define should be in CPPFLAGS and not CFLAGS Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2012-05-20makepkg: Add CPPFLAGS supportAllan McRae
Add CPPFLAGS support in addition to the current CFLAGS and CXXFLAGS. This keeps compiler flags split up in the same logical way done everywhere else. Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2012-05-20updpkgsums: add new contrib scriptDave Reisner
This updates checksums in a PKGBUILD in-place. If no sums are found, they are appended to the end.
2012-05-20fix -Wshadow warnings as reported by gcc 4.4.3Dave Reisner
Apparently gcc 4.7 has decided that -Wshadow warnings aren't worth reporting anymore even with the flag enabled. These were found on an Ubuntu 10.04 install. Signed-off-by: Dave Reisner <dreisner@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2012-05-20contrib/pacsysclean: use a standard vim modelineDave Reisner
Fix indenting to something more familiar with the rest of the codebase. Signed-off-by: Dave Reisner <dreisner@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2012-05-20Merge branch 'maint'Dan McGee
Conflicts: scripts/pacman-key.sh.in
2012-05-20pacman-key: use mapfile over readDave Reisner
Signed-off-by: Dave Reisner <dreisner@archlinux.org>
2012-05-20makepkg: use mapfile where plausibleDave Reisner
With bash4 as a requirement, we can use mapfile when reading command output into an array. mapfile has the advantage of using block buffered I/O rather than line buffered I/O, making it slightly faster for most jobs. Signed-off-by: Dave Reisner <dreisner@archlinux.org>
2012-05-20pacman: support group selection delimited by commasDave Reisner
We support multiple arguments being comma separated elsewhere, so this seems like a natural extension to support in our multiparse selection code. Signed-off-by: Dave Reisner <dreisner@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2012-05-20pkgdelta: adopt parseopts for option parsingDave Reisner
Signed-off-by: Dave Reisner <dreisner@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2012-05-20pacman-key: test for content in keyring filesDave Reisner
Test for file content (-s) rather than just existance (-f). This fixes a bug that manifests itself in the case of an empty -revoked file. A zero element 'keys' array would be passed to gpg, forcing it to list and, subsequently, revoke all known keys. Bug introduced in d1240f67eab6. Signed-off-by: Dave Reisner <dreisner@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2012-05-20contrib/pacsysclean: avoid setting bogus PACMAN_OPTSDave Reisner
PACMAN_OPTS would be erroneously set when it was undefined, causing pacsysclean to error out. Signed-off-by: Dave Reisner <dreisner@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2012-05-20Fix gettext usage in pkgdelta help instructionsDan McGee
Signed-off-by: Dan McGee <dan@archlinux.org>
2012-05-20Update pacman-scripts message catalogDan McGee
Signed-off-by: Dan McGee <dan@archlinux.org>
2012-05-18docs: remove 'in the wild' sectionDan McGee
We haven't updated this info in years and it is out of date. Signed-off-by: Dan McGee <dan@archlinux.org>
2012-05-04pacman-key: clarify messages, s/keychain/keyring/Dan McGee
Signed-off-by: Dan McGee <dan@archlinux.org>
2012-05-04doc: remove --recursive documentation for non-remove operationsDan McGee
This documentation was added in commit 857357f9 so was not caught in the removal of this option in commit 85712814. Signed-off-by: Dan McGee <dan@archlinux.org>
2012-05-04Ensure pre_upgrade scriptlet gets old package versionDan McGee
This was accidentally broken in the refactor done in commit 73139ccb. Fixes FS#29371. Signed-off-by: Dan McGee <dan@archlinux.org>
2012-04-30makepkg: fix package arch detectionAllan McRae
get_pkg_arch checked for the arch variable being overridden in the package_$1() function when used with a package as a parameter. However, when there was no override, it did not fall back to the global value. Signed-off-by: Allan McRae <allan@archlinux.org>
2012-04-30contrib: remove executable bit from input filesDave Reisner
There's no reason to make these executable, and this also mimics what we do in the scripts/ subdir. Signed-off-by: Dave Reisner <dreisner@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2012-04-30zsh completion for makepkgDaniel Wallace
This adds zsh completion for makepkg to the _pacman file in /usr/share/zsh/site-functions/. it completes makepkg and allows for stacking of flags like -si, -sci, et cetera. Signed-off-by: Daniel Wallace <daniel.wallace@gatech.edu>
2012-04-30add zsh completion to pacman-keyDaniel Wallace
This patch adds zsh completion to pacman-key. It completes files/directories for --config or --gpgdir and just completes the command for --keyserver then it can complete keyids or files for all the other flags. Signed-off-by: Daniel Wallace <daniel.wallace@gatech.edu>
2012-04-29Convert ALLOC_FAIL macro into a functionDan McGee
This path is rarely (read: never) taken in any normal run of the code, so injecting the fprintf() call everywhere with the macro is a bit overkill. Instead, add a lightweight _alpm_alloc_fail() function that gets called instead. This does have a reasonable effect on the size of the generated code; most places using the macros provided by util.c have their code size reduced. Signed-off-by: Dan McGee <dan@archlinux.org>
2012-04-29be_local: use the right length value for filename in all casesDan McGee
Increment the strlen() provided value by 1 for the NULL byte so we use the right value in all three places we later reference it. Signed-off-by: Dan McGee <dan@archlinux.org>
2012-04-29pkgdelta/repo-add: quoting fixesFlorian Pritz
Finish the job on master; most of these were applied to maint already. Signed-off-by: Florian Pritz <bluewind@xinu.at>
2012-04-29Output "Packages" instead of "Targets"Allan McRae
Prefix the list of packages being installed/removed with "Packages" instead of "Targets" as they are package names by this stage. Fixes FS#23123. Signed-off-by: Allan McRae <allan@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>
2012-04-29Merge remote-tracking branch 'dave/buildsys'Dan McGee
2012-04-29makepkg: remove subshelling from check_option and friendsDave Reisner
Instead of creating a subshell for each of these checks (of which there are many), pass in an expected value and make the check_* function do the comparison for us, returning 0 (match), 1, (mismatch), or 127 (not found). For a measureable benefit, I tested this on a fairly simple package, perl-term-readkey, and counted the number of clone(2) syscalls to try and isolate those generated by makepkg itself, rather than the user defined functions. Results as shown below: 336 before 180 after So, roughly a 50% reduction, which makes sense given that a single check_option() call could be up to 3 subprocesses in total. Signed-off-by: Dave Reisner <dreisner@archlinux.org>
2012-04-29makepkg: null terminate filenames to stripDave Reisner
Signed-off-by: Dave Reisner <dreisner@archlinux.org>
2012-04-29pacman/package.c: show checksums with -SiiDave Reisner
These were removed entirely by f34864cc9e, but some people (myself included) still find them useful. Revive these details, but "demote" them, so that they're only displayed when extra sync data is requested. Signed-off-by: Dave Reisner <dreisner@archlinux.org> Signed-off-by: Dan McGee <dan@archlinux.org>