libalpm: never attempt to remove a mountpoint

Arch Linux typically runs into this with /sys when upgrading the
filesystem package in build chroots, but LXC users might also run into
this, since their /sys is shared from the host and must, for security
reasons, be mounted RO.

I've neglected to add any tests for this because they would require root
in order to run. Current tests all pass with this patch and I've
confirmed the desired behavior in a VM. Incidentally, the first hunk of
this patch (skipping can_remove_file checks for directories) resolves the
case of API mountpoints being removed since they eventually fall into
unlink_file and fail with "contains files". However, this patch should
still be the Right Thing To Do™, as we can't possibly remove a directory
that is also a mountpoint.

Signed-off-by: Dave Reisner <dreisner@archlinux.org>

[Allan] Do not skip checking if directories can be removed. Instead test
if directories are mountpoints in can_remove_file.

Signed-off-by: Allan McRae <allan@archlinux.org>
makepkg.conf.5: fix bulletted list item formatting

Signed-off-by: Dave Reisner <dreisner@archlinux.org>
Signed-off-by: Allan McRae <allan@archlinux.org>
makepkg: add support for .pkg.tar.lzo

Supported by libarchive as of version 3.1.0 when compiled against lzo2
or in the presence of the lzop binary.

Signed-off-by: Dave Reisner <dreisner@archlinux.org>
Signed-off-by: Allan McRae <allan@archlinux.org>
find_fileconflicts: reduce path resolution calls

Signed-off-by: Andrew Gregory <andrew.gregory.8@gmail.com>
add alpm_logaction to API updates

Signed-off-by: Andrew Gregory <andrew.gregory.8@gmail.com>
Signed-off-by: Allan McRae <allan@archlinux.org>
fix alpm_validation_t comment

Signed-off-by: Andrew Gregory <andrew.gregory.8@gmail.com>
Signed-off-by: Allan McRae <allan@archlinux.org>
fix style violations

Signed-off-by: Andrew Gregory <andrew.gregory.8@gmail.com>
Signed-off-by: Allan McRae <allan@archlinux.org>
fix off-by-one error in _alpm_filelist_resolve

'/' should not be appended to the resolved root when root is "/".

Signed-off-by: Andrew Gregory <andrew.gregory.8@gmail.com>
Signed-off-by: Allan McRae <allan@archlinux.org>
pmtest: install filesystem entries before packages

Installing filesystem entries first allows the filesystem to provide
a symlink to a directory.  Packages will then be able to use the symlink
as if it were a directory instead of causing an error.

For example:

self.filesystem = ["dir/", "link -> dir/"]
pkg = pmpkg("pkg1")
pkg.files = ["link/file"]
self.addpkg2db("local", pkg)

Signed-off-by: Andrew Gregory <andrew.gregory.8@gmail.com>
Signed-off-by: Allan McRae <allan@archlinux.org>
Perform limited conflict checking with --force

Pacman currently bails when trying to extract a file over a directory
when using --force.  Instead of ignoring all conflict, perform the
check and skip any file-file conflicts. Conflicts between directories
and files are still flagged and cause the transation to abort.

As a bonus, we now know about files changing packages when using
--force, so we can skip removing them fixing upgrade046.

Signed-off-by: Allan McRae <allan@archlinux.org>
Remove "ts=2 sw=2" from Vim modelines for pacman-contrib

There is no reason to force a certain tab width on users. These settings
should be configured by the user in their own ~/.vimrc.

Signed-off-by: Jason St. John <jstjohn@purdue.edu>
Remove tab width config from Vim modelines in doc/

There is no reason to force a certain tab width on users. These settings
should be configured by the user in their own ~/.vimrc.

Signed-off-by: Jason St. John <jstjohn@purdue.edu>
update zshcompletion
save update