Age | Commit message (Collapse) | Author | Files | Lines |
|
This prevents multiple spaces between values from being
parsed as empty values.
Signed-off-by: Andrew Gregory <andrew.gregory.8@gmail.com>
Signed-off-by: Allan McRae <allan@archlinux.org>
|
|
Signed-off-by: Andrew Gregory <andrew.gregory.8@gmail.com>
Signed-off-by: Allan McRae <allan@archlinux.org>
|
|
Signed-off-by: Allan McRae <allan@archlinux.org>
|
|
Rearrange the functions section of the PKGBUILD man package. Clarify
that the package() function is a requirement and the rest are all
optional. Note that $pkgdir should only be used in the package()
function.
Signed-off-by: Allan McRae <allan@archlinux.org>
|
|
The idea of having separate build() and package() functions is that
build() is run as a normal uses and package() as (fake)root. Any
files placed in $pkgdir during build() can have the wrong permissions.
Restrict access to $pkgdir during build() - unless there is no package()
function.
Also, set $pkgdir to something "useful" during build(). For split
packages, this uses "<path>/pkg/$pkgbase" because it is not obvious
which $pkgdir is being referred to.
Signed-off-by: Allan McRae <allan@archlinux.org>
|
|
Signed-off-by: Andrew Gregory <andrew.gregory.8@gmail.com>
Signed-off-by: Allan McRae <allan@archlinux.org>
|
|
Signed-off-by: Andrew Gregory <andrew.gregory.8@gmail.com>
Signed-off-by: Allan McRae <allan@archlinux.org>
|
|
No other contrib script is executable.
Signed-off-by: Andrew Gregory <andrew.gregory.8@gmail.com>
Signed-off-by: Allan McRae <allan@archlinux.org>
|
|
Suggested-by: Dan McGee <dan@archlinux.org>
Signed-off-by: Dave Reisner <dreisner@archlinux.org>
Signed-off-by: Allan McRae <allan@archlinux.org>
|
|
Signed-off-by: Allan McRae <allan@archlinux.org>
|
|
Add LocalFileSigLevel and RemoteFileSigLevel to control the signature
checking for "pacman -U <file>" and "pacman -U <url>" operations
respectively. The starting value for both these options is SigLevel,
if it is specified in the [options] section, or the built-in system
default. The specified values override and/or supplement this initial
value. Note there is no distinction between setting "Required" and
"PackageRequired" as there are no database options for Upgrade
operations.
Signed-off-by: Allan McRae <allan@archlinux.org>
|
|
We still call some of these 'deprecated' methods elsewhere, so this
shouldn't present a problem. When we decide 2.x support is to be dropped,
we should update all of the code to not call deprecated methods.
Allan: Adjusted with respect to previous patches adding libarchive
compatibilty layer.
Signed-off-by: Allan McRae <allan@archlinux.org>
|
|
Signed-off-by: Dave Reisner <dreisner@archlinux.org>
Signed-off-by: Allan McRae <allan@archlinux.org>
|
|
This allows us to support both libarchive 2.8.x as well as 3.x without
deprecation warnings on compile.
Signed-off-by: Dave Reisner <dreisner@archlinux.org>
Signed-off-by: Allan McRae <allan@archlinux.org>
|
|
Rearrange tidy_install so we first remove docs, unwanted files,
libtool files, and empty directories. Then check for missing backup
files and references to $srcdir and $pkgdir. Finally compress manpages,
strip debug symbols, and compress executables with upx.
Fixes FS33318
Signed-off-by: Chirantan Ekbote <chirantan.ekbote@gmail.com>
Signed-off-by: Allan McRae <allan@archlinux.org>
|
|
I suspect that eventually we're going to end up returning a pointer to
an allocated struct to describe the download result, but that's for
another patch when the need arises...
Fixes FS#33508.
Signed-off-by: Dave Reisner <dreisner@archlinux.org>
Signed-off-by: Allan McRae <allan@archlinux.org>
|
|
Users have hit issues behind corporate firewalls that initially throttle
downloads to ~1B/sec.
Signed-off-by: Olivier Langlois < olivier.pis.langlois@transport.alstom.com>
Signed-off-by: Allan McRae <allan@archlinux.org>
|
|
Also fix a small bug where pacman won't check if the sync dbs are first
downloaded when invoked with --native (it should).
Signed-off-by: Simon Gomizelj <simongmzlj@gmail.com>
Signed-off-by: Allan McRae <allan@archlinux.org>
|
|
Signed-off-by: Maxime Gauduin <alucryd@gmail.com>
Signed-off-by: Allan McRae <allan@archlinux.org>
|
|
Signed-off-by: Andrew Gregory <andrew.gregory.8@gmail.com>
Signed-off-by: Allan McRae <allan@archlinux.org>
|
|
prefix defaults to "UNKOWN" if null or an empty string is provided.
Signed-off-by: Andrew Gregory <andrew.gregory.8@gmail.com>
Signed-off-by: Allan McRae <allan@archlinux.org>
|
|
The latest automake release causes complaints about an out of date
'missing' file during configure. Sync with upstream.
Signed-off-by: Allan McRae <allan@archlinux.org>
|
|
Originally printed a leading \ before all path names as the `' would be
removed during the make. Using '' should be just as good as using `'.
paccache.sh.in:
die "cachedir \`%s' does not exist or is not a directory" "$cachedir"
paccache
die "cachedir \%s does not exist or is not a directory" "$cachedir"
Signed-off-by: William Giokas <1007380@gmail.com>
Signed-off-by: Allan McRae <allan@archlinux.org>
|
|
Signed-off-by: Andrew Gregory <andrew.gregory.8@gmail.com>
Signed-off-by: Allan McRae <allan@archlinux.org>
|
|
Resolves FS#33455.
Signed-off-by: Dave Reisner <dreisner@archlinux.org>
Signed-off-by: Allan McRae <allan@archlinux.org>
|
|
Teach pacsort to understand package filenames and optionally strip away
some of the context. alpm_pkg_vercmp() intentionally only understands
pure versions, so strings such as '18.0-2-x86_64' and '18.0.1-1-x86_64'
will be compared wrongly.
Partially addresses FS#33455.
Signed-off-by: Dave Reisner <dreisner@archlinux.org>
Signed-off-by: Allan McRae <allan@archlinux.org>
|
|
The FHS (2.3) says having ldconfig in /sbin is optional and it is usually
located in /usr/sbin. So /sbin/ldconfig should not be hard coded in
pacman. Instead, provide a configure option --with-ldconfig that defaults
to the current path.
Signed-off-by: Allan McRae <allan@archlinux.org>
|
|
The leading / makes the pactest suite look for the file in the users
filesystem. This meant the ldconfig tests always passed (even when
broken in pacman...).
Signed-off-by: Allan McRae <allan@archlinux.org>
|
|
pacman can be configured to use a different shell than /bin/sh for
scriplets. Pass the cnfigured value to the pactest suite and make the
necessary "copy" of the shell in the test root.
Also update all copyright years in the pactest suite.
Signed-off-by: Allan McRae <allan@archlinux.org>
|
|
This reverts commit 4a8c2852a887d2b1aaa43be3071ab586eb24b9e3.
This reverts commit 993700bc6b12cd291544d2a22845f480e8a7925e.
This reverts commit bb4d2b72c1d35ab9d65d632be0dcaf00cfa7d600.
This reverts commit 60b192e3836a150eb6950ce52241efebbee00f11.
Signed-off-by: Allan McRae <allan@archlinux.org>
|
|
The difference between the echo and the printf's in write_pkginfo seemed
to be somewhat sporadic. Also, the INFAKEROOT check was doing the same
exact thing as the SPLITPKG check, but formatted much differently and
consuming two extra lines. I think this makes it more readable than it
was previously, if nothing else.
Signed-off-by: William Giokas <1007380@gmail.com>
Signed-off-by: Allan McRae <allan@archlinux.org>
|
|
RFC 2616 doesn't forbid a 301 or 302 repsonse from having a body, and
servers exist in the wild that show this behavior. In order to prevent
pacman from showing a progress bar when we aren't actually downloading a
package (and merely following one of these pain in the butt redirects),
capture the server response code in the response header, rather than
waiting to peel it off the handle after the download has finished.
Signed-off-by: Dave Reisner <dreisner@archlinux.org>
Reported-by: Alexandre Filgueira <alexfilgueira@cinnarch.com>
Signed-off-by: Allan McRae <allan@archlinux.org>
|
|
Signed-off-by: Allan McRae <allan@archlinux.org>
|
|
In order to support a variety of values for the --with-scriptlet-shell
configure flag, pmtest has to be aware of what kind of path was passed,
be it an absolute path or a fragment for a path lookup. For absolute
paths, leave the path alone. For fragments, search the PATH environment
var for the resolved path to the binary. In both cases, join the
resultant path to the root directory defined for the test, not a
pre-determined bin directory.
Fixes FS#31552.
With-contribution-by: Dave Reisner <dreisner@archlinux.org>
Signed-off-by: Allan McRae <allan@archlinux.org>
|
|
This increases robustness to the shell location changing paths.
Signed-off-by: Allan McRae <allan@archlinux.org>
|
|
The ldconfig binary is not guaranteed to be in /sbin. Change to calling
just "ldconfig" rather than using the full path.
This removed the check that the ldconfig binary exists. However, it is
a reasonable assumption that it will exist if its configuration file
does.
Signed-off-by: Allan McRae <allan@archlinux.org>
|
|
This makes us more robust to utilities changing paths. There is no
functional change when a full path is specified.
Signed-off-by: Allan McRae <allan@archlinux.org>
|
|
The restriction of not checking the ownership of a directory is
unnecessary given that all the package filelists contain this
information. Remove this restriction, with the expectation that you
might get multiple packages returned for a given directory.
Additionally attempt to minimise the number of files getting through
to the slow realpath call.
Original-work-by: Dan McGee <dan@archlinux.org>
Original-work-by: Allan McRae <allan@archlinux.org>
Signed-off-by: Andrew Gregory <andrew.gregory.8@gmail.com>
Signed-off-by: Allan McRae <allan@archlinux.org>
|
|
Signed-off-by: Andrew Gregory <andrew.gregory.8@gmail.com>
Signed-off-by: Allan McRae <allan@archlinux.org>
|
|
Do not bother the user with gpg's verbose output.
Signed-off-by: Pierre Schmitz <pierre@archlinux.de>
Signed-off-by: Allan McRae <allan@archlinux.org>
|
|
gpg --lsign-key does not like being given multiple keys to sign.
Signed-off-by: Allan McRae <allan@archlinux.org>
|
|
Signed-off-by: Gerardo Exequiel Pozzi <vmlinuz386@yahoo.com.ar>
Signed-off-by: Allan McRae <allan@archlinux.org>
|
|
Signed-off-by: Gerardo Exequiel Pozzi <vmlinuz386@yahoo.com.ar>
Signed-off-by: Allan McRae <allan@archlinux.org>
|
|
Signed-off-by: Gerardo Exequiel Pozzi <vmlinuz386@yahoo.com.ar>
Signed-off-by: Allan McRae <allan@archlinux.org>
|
|
Signed-off-by: Gerardo Exequiel Pozzi <vmlinuz386@yahoo.com.ar>
Signed-off-by: Allan McRae <allan@archlinux.org>
|
|
Signed-off-by: Allan McRae <allan@archlinux.org>
|
|
Teach pacman to save backup files with extension .pacsave.n, where n is a
positive integer. The current backup file shall be saved as <name>.pacsave,
while existing .pacsave.n files will be renamed to <name>.pacsave.n+1
Example:
1. You have subversion installed in your local repo. /etc/conf.d/svnserve
is a file to be backed up. It contains local modifications
2. You remove subversion from your repo. /etc/conf.d/svnserve is backed up as
/etc/conf.d/svnserve.pacsave
2. You install subversion again
3. You edit /etc/conf.d/svnserve
4. You remove subversion. The existing /etc/conf.d/svnserve.pacsave is renamed
to /etc/conf.d/svnserve.pacsave.1 and /etc/conf.d/svnserve is backed up as
/etc/conf.d/svnserve.pacsave
Signed-off-by: Pang Yan Han <pangyanhan@gmail.com>
Rebased from original email and adjusted for util-common usage.
Signed-off-by: Florian Pritz <bluewind@xinu.at>
Signed-off-by: Allan McRae <allan@archlinux.org>
|
|
There is duplicated code in the util.c files in the libalpm and pacman
source code. Split this into a separate file so that it can be shared
via a symlink. This prevents code divergence between the two code bases.
Also, move mbasename and mdirname from pacman/util.c into util-common.c
in preparation for the following patch that uses them to add an extension
to pacsave files.
Signed-off-by: Allan McRae <allan@archlinux.org>
|
|
Packages are already in the pkg db were given a warning, and then
readded anyway. With -n specified, the warning is printed, but skips
readding it.
Signed-off-by: Danny George <dangets@gmail.com>
Signed-off-by: Allan McRae <allan@archlinux.org>
|
|
When building sources with a pkgver function, makepkg will print out the
original version before pkgver() is run, claiming that that is the
package that will be built. This patch simply re-prints the output
later, after pkgver() has been run so people can see which package they
are actually building.
Signed-off-by: William Giokas <1007380@gmail.com>
Signed-off-by: Allan McRae <allan@archlinux.org>
|