This was just setting the current date when the pkg
is being added to the repository index.
It does not make any sense, so get rid of it completely.
This "build-date" string obj needs to be added via
xbps-create(1) not xbps-rindex(1)!
Another step towards reproducability (#55)
When there's a new xbps update, xbps-install(1) will now return
EBUSY (16) and a message (if dry-run disabled) explaining
how to proceed.
If there's an update and transaction does not contain xbps, it will
error out unless the 'xbps' pkg is the only target pkg, i.e:
# xbps-install -Su
# echo $?
16
To update xbps, the only way to proceed is to explicitly declare
it as an update, i.e:
# xbps-install -u xbps
The dry-run mode will still show there's an xbps update.
Modified the existing test cases to satisfy the new behaviour.
Closes#166Closes#142
The '%n' pkgname fmt option still needs to be the sourcepkg
for xbps-src to work with no additional changes.
This restores previous behaviour, and uses binpkg's pkgname
while checking for pkgdb/repo.
Up until now `xbps-checkvers` would only check for the
real sourcepkg, this broke detection of binary packages
that are subpkgs.
Added a new test case.
Close#192
This fixes issues where if xbps-create creates a new archive on a full
disk, it will write an incomplete archive and then later fails to be
read by xbps-rindex.
xbps-{alternatives,pkgdb,reconfigure}: xbps_pkgdb_update()
has been fixed to flush when told so, and we don't need
to update the in-memory copy because we are exiting.
Added `-D, --download-only` flag to allow downloading
packages to the cache without attempting to install them.
Contributed by Toyam Cox via #9
Adapted to master by yours truly.
Close#9
If set it will continue with the transaction and will
just print what are the conflicting files without returning
EEXIST.
This is a temporary solution for void where there are still
some packages with conflicting files (qt5-host-tools vs qt5-tools-devel).
With input by @duncaen
Before this change xbps-install could return EEXIST
when the package is already installed, or already up-to-date.
Return 0 if such condition happens, and only return EEXIST
if there's a file conflict.
Close#51
Add 'digest' and 'fetch' actions again for compatibility,
but don't mention them in usage().
This way previous versions of xbps-src (that don't require xbps-0.54)
still work without changes.
assert() must not change program behaviour.
It's unlikely that xbps_dictionary_set_cstring() fails, but even
so proplib will report it, so no need to run it via assert().
Any compression format from that list is supported without
additional changes: gzip, bzip2, lz4, xz, zstd.
This is for repository data and binary packages.
Close#122
The character has to be checked for EOF (-1), otherwise with
architectures that use unsigned char by default this breaks at
compile and runtime.
https://github.com/void-linux/xbps/issues/123
xbps_get_pkg_fulldeptree() now returns NULL and sets errno to ENODEV
when there are missing dependencies, rather than assert()ing.
Added another test case to check returned error codes.
Signed-off-by: Juan RP <xtraeme@gmail.com>
This replaces -s,--show-missing. This now prints all processed packages
and outputs in the following format:
pkgname repover srcver
if `repover` or `srcver` can't be known, '?' is print.
Will be used in xbps-src soon. Thanks to @duncaen for ideas.
Signed-off-by: Juan RP <xtraeme@gmail.com>
-i,--ignore-conf-repos has been added.
The previous -i,--installed flag has been renamed to -I.
This breaks compat but we'll need to change buildbot anyway.
Signed-off-by: Juan RP <xtraeme@gmail.com>
See the manual page:
XBPS-DIGEST(1) General Commands Manual XBPS-DIGEST(1)
NAME
xbps-digest - XBPS utility to generate message digests
SYNOPSIS
xbps-digest [OPTIONS] [FILE] [FILE+N]
DESCRIPTION
The xbps-digest utility generates message digests for specified FILE or
stdin if unset.
OPTIONS
-m, --mode mode
Sets the message digest mode. Supported: sha256. If unset, defaults
to sha256.
-h, --help
Show the help message.
-V, --version
Show the version information.
SEE ALSO
xbps.d(5), xbps-checkvers(1), xbps-create(1), xbps-dgraph(1),
xbps-fbulk(1), xbps-install(1), xbps-pkgdb(1), xbps-query(1),
xbps-reconfigure(1), xbps-remove(1), xbps-rindex(1), xbps-uchroot(1),
xbps-uunshare(1)
AUTHORS
Juan Romero Pardines <xtraeme@gmail.com>
BUGS
Probably, but I try to make this not happen. Use it under your own
responsibility and enjoy your life.
Report bugs at https://github.com/void-linux/xbps/issues
June 12, 2019
Signed-off-by: Juan RP <xtraeme@gmail.com>
This now works as expected again, see https://i.imgur.com/pr2XO70.png
for the full dependency graph of the sway pkg installed on my system.
Closes: #80 [via git-merge-pr]
The previous idea was to use virtual packages in the users configuration
to satisfy dependencies by mapping them to existing installed packages.
Using virtual packages for it doesn't work as expected and trying to make
it work would break other functionalities of virtual packages, like the
version satisfaction checks for `provides` and the ability to replace
virtual packages with real packages. The virtual package functionality
should be used exclusively for virtual packages.
This allows users to specify packages packages that should be ignored.
Ignored packages in dependencies are always satisfied without installing
the package, while updating or installing a package that depends on an
ignored package.
This does NOT ignore the shlib checks, ignoring a package that provides
required shared libraries will abort the transaction as if there was no
package that provides the required shared library.
A segfault in xbps-create(1) was found in:
https://github.com/void-linux/void-packages/pull/7524
xbps-create adds a file type string to the xentry for every file it
finds in `destdir`, files other than symlinks, regular files and
directories weren't handled and resulted in a segfault later when
when processing the xentry structures.
This commit adds checks for sockets and fifos and exits with an
appropriate error message or with a generic error message for every
other unhandled file.
Closes#66
EBUSY occurs if xbps tries to remove a directory with unlink(2) that is
a mount point, this happens with `/boot` as example.
https: //github.com/voidlinux/void-packages/issues/7229#issuecomment-319392560
https: //github.com/voidlinux/void-packages/issues/8753
Closes: #259 [via git-merge-pr]
Original message:
```
fetch_cb.c:80:29: error: ‘h’ directive output may be truncated writing 1 byte into a region of size between 0 and 14 [-Werror=format-truncation=]
snprintf(str, sizeof str, "%02ldh%02ldm",
^~~~~~~~~~~~~~
fetch_cb.c:80:29: note: directive argument in the range [0, 59]
fetch_cb.c:80:3: note: ‘snprintf’ output between 7 and 21 bytes into a destination of size 16
snprintf(str, sizeof str, "%02ldh%02ldm",
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
eta / 3600, (eta % 3600) / 60);
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
fetch_cb.c:83:30: error: ‘%02ld’ directive output may be truncated writing between 2 and 19 bytes into a region of size 16 [-Werror=format-truncation=]
snprintf(str, sizeof str, "%02ldm%02lds",
^~~~~
fetch_cb.c:83:29: note: directive argument in the range [-153722867280912930, 60]
snprintf(str, sizeof str, "%02ldm%02lds",
^~~~~~~~~~~~~~
fetch_cb.c:83:29: note: directive argument in the range [-59, 59]
fetch_cb.c:83:3: note: ‘snprintf’ output between 7 and 25 bytes into a destination of size 16
snprintf(str, sizeof str, "%02ldm%02lds",
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
eta / 60, eta % 60);
~~~~~~~~~~~~~~~~~~~
fetch_cb.c:80:29: error: ‘h’ directive output may be truncated writing 1 byte into a region of size between 0 and 14 [-Werror=format-truncation=]
snprintf(str, sizeof str, "%02ldh%02ldm",
^~~~~~~~~~~~~~
fetch_cb.c:80:29: note: directive argument in the range [0, 59]
fetch_cb.c:80:3: note: ‘snprintf’ output between 7 and 21 bytes into a destination of size 16
snprintf(str, sizeof str, "%02ldh%02ldm",
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
eta / 3600, (eta % 3600) / 60);
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
fetch_cb.c:83:30: error: ‘%02ld’ directive output may be truncated writing between 2 and 19 bytes into a region of size 16 [-Werror=format-truncation=]
snprintf(str, sizeof str, "%02ldm%02lds",
^~~~~
fetch_cb.c:83:29: note: directive argument in the range [-153722867280912930, 60]
snprintf(str, sizeof str, "%02ldm%02lds",
^~~~~~~~~~~~~~
fetch_cb.c:83:29: note: directive argument in the range [-59, 59]
fetch_cb.c:83:3: note: ‘snprintf’ output between 7 and 25 bytes into a destination of size 16
snprintf(str, sizeof str, "%02ldm%02lds",
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
eta / 60, eta % 60);
~~~~~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors
```