Github messages for voidlinux
 help / color / mirror / Atom feed
* [PR PATCH] fix sort-dependencies to use checkdepends
@ 2023-12-23 22:56 tornaria
  2023-12-25  8:30 ` sgn
                   ` (12 more replies)
  0 siblings, 13 replies; 14+ messages in thread
From: tornaria @ 2023-12-23 22:56 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 1931 bytes --]

There is a new pull request by tornaria against master on the void-packages repository

https://github.com/tornaria/void-packages sort-deps
https://github.com/void-linux/void-packages/pull/47888

fix sort-dependencies to use checkdepends
As it is now, if `pkgA` checkdepends on `pkgB`, sort-dependencies will still print `pkgA` before `pkgB`. This causes CI to build `pkgB` twice: first build `pkgA` which forces implicit build of `pkgB`; then build of `pkgB` (explicit, so it will ignore the package is already built).

A concrete example:

```
$ ./xbps-src sort-dependencies python3-process-tests python3-pytest-cov
python3-pytest-cov
python3-process-tests
```
After this commit, the order above is the other way around.

The example above causes `python-process-tests` to be built twice, as shown in:
https://github.com/void-linux/void-packages/actions/runs/7107346278/job/19348602412?pr=47610

<!-- Uncomment relevant sections and delete options which are not applicable -->

#### Testing the changes
- I tested the changes in this PR: **YES**

<!--
#### New package
- This new package conforms to the [package requirements](https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#package-requirements): **YES**|**NO**
-->

<!-- Note: If the build is likely to take more than 2 hours, please add ci skip tag as described in
https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#continuous-integration
and test at least one native build and, if supported, at least one cross build.
Ignore this section if this PR is not skipping CI.
-->
<!--
#### Local build testing
- I built this PR locally for my native architecture, (ARCH-LIBC)
- I built this PR locally for these architectures (if supported. mark crossbuilds):
  - aarch64-musl
  - armv7l
  - armv6l-musl
-->


A patch file from https://github.com/void-linux/void-packages/pull/47888.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-sort-deps-47888.patch --]
[-- Type: text/x-diff, Size: 2817 bytes --]

From 416aa296a43c51cf224de81a632ea8d30a0efcc2 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Gonzalo=20Tornar=C3=ADa?= <tornaria@cmat.edu.uy>
Date: Sat, 23 Dec 2023 19:40:53 -0300
Subject: [PATCH] fix sort-dependencies to use checkdepends

As it is now, if pkgA checkdepends on pkgB, sort-dependencies will still
print pkgA before pkgB. This causes CI to build pkgB twice: first build
pkgA which forces implicit build of pkgB; then build of pkgB (explicit,
so it will ignore the package is already built).

A concrete example:

$ ./xbps-src sort-dependencies python3-process-tests python3-pytest-cov
python3-pytest-cov
python3-process-tests

After this commit, the order above is the other way around.
---
 common/xbps-src/shutils/bulk.sh | 3 ++-
 common/xbps-src/shutils/show.sh | 4 ++++
 xbps-src                        | 7 +++++++
 3 files changed, 13 insertions(+), 1 deletion(-)

diff --git a/common/xbps-src/shutils/bulk.sh b/common/xbps-src/shutils/bulk.sh
index 69e36f4a43f4e..15a7dc6c94d12 100644
--- a/common/xbps-src/shutils/bulk.sh
+++ b/common/xbps-src/shutils/bulk.sh
@@ -35,7 +35,8 @@ bulk_sortdeps() {
     # Perform a topological sort of all pkgs but only with build dependencies
     # that are found in previous step.
     for pkg in ${pkgs}; do
-        _pkgs="$($XBPS_DISTDIR/xbps-src show-build-deps $pkg 2>/dev/null)"
+        _pkgs="$($XBPS_DISTDIR/xbps-src show-build-deps $pkg 2>/dev/null)
+               $($XBPS_DISTDIR/xbps-src show-check-deps $pkg 2>/dev/null)"
         found=0
         for x in ${_pkgs}; do
             _pkg=$(bulk_getlink $x)
diff --git a/common/xbps-src/shutils/show.sh b/common/xbps-src/shutils/show.sh
index 606396d2b4b1a..8af32295d25d5 100644
--- a/common/xbps-src/shutils/show.sh
+++ b/common/xbps-src/shutils/show.sh
@@ -120,6 +120,10 @@ show_pkg_build_deps() {
     show_pkg_build_depends "${makedepends} $(setup_pkg_depends '' 1 1)" "${hostmakedepends}"
 }
 
+show_pkg_check_deps() {
+    show_pkg_build_depends "${checkdepends}" ""
+}
+
 show_pkg_hostmakedepends() {
     show_pkg_build_depends "" "${hostmakedepends}"
 }
diff --git a/xbps-src b/xbps-src
index cdb5f8c6d643e..cf0d31ff903d4 100755
--- a/xbps-src
+++ b/xbps-src
@@ -91,6 +91,9 @@ show-avail <pkgname>
 show-build-deps <pkgname>
     Show required build dependencies for <pkgname>.
 
+show-check-deps <pkgname>
+    Show required check dependencies for <pkgname>.
+
 show-deps <pkgname>
     Show required run-time dependencies for <pkgname>. Package must be
     installed into destdir.
@@ -861,6 +864,10 @@ case "$XBPS_TARGET" in
         read_pkg ignore-problems
         show_pkg_build_deps
         ;;
+    show-check-deps)
+        read_pkg ignore-problems
+        show_pkg_check_deps
+        ;;
     show-hostmakedepends)
         read_pkg ignore-problems
         show_pkg_hostmakedepends

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: fix sort-dependencies to use checkdepends
  2023-12-23 22:56 [PR PATCH] fix sort-dependencies to use checkdepends tornaria
@ 2023-12-25  8:30 ` sgn
  2023-12-25 14:41 ` tornaria
                   ` (11 subsequent siblings)
  12 siblings, 0 replies; 14+ messages in thread
From: sgn @ 2023-12-25  8:30 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 195 bytes --]

New comment by sgn on void-packages repository

https://github.com/void-linux/void-packages/pull/47888#issuecomment-1868853319

Comment:
We need to ignore `checkdepends` during non-testing-build

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: fix sort-dependencies to use checkdepends
  2023-12-23 22:56 [PR PATCH] fix sort-dependencies to use checkdepends tornaria
  2023-12-25  8:30 ` sgn
@ 2023-12-25 14:41 ` tornaria
  2023-12-25 14:52 ` tornaria
                   ` (10 subsequent siblings)
  12 siblings, 0 replies; 14+ messages in thread
From: tornaria @ 2023-12-25 14:41 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 1491 bytes --]

New comment by tornaria on void-packages repository

https://github.com/void-linux/void-packages/pull/47888#issuecomment-1869011818

Comment:
> We need to ignore `checkdepends` during non-testing-build

This only affects order, in the sense that `sort-dependencies` will not add anything, just sort.

For example:
```
$ ./xbps-src sort-dependencies python3-pytest-cov
python3-pytest-cov
```
even if `python3-pytest-cov` checkdepends on `python3-process-tests`.

OTOH,in
```
$ ./xbps-src sort-dependencies python3-process-tests python3-pytest-cov
python3-pytest-cov
python3-process-tests
```
it is irrelevant for non-testing-build in which order these two packages are built, so it should not be a problem.

The only case where this would make a difference is if there is a build-check cycle. Then this will print a warning, and IMO it should be considered a bug.

Example:
```
$ XBPS_CHECK_PKGS=full ./xbps-src sort-dependencies python3-jupyter_server python3-jupyter_server_terminals
tsort: /tmp/tmp.owWM5auH2j: input contains a loop:
tsort: python3-jupyter_server
tsort: python3-jupyter_server_terminals
python3-jupyter_server_terminals
python3-jupyter_server
```
Note this is only a cycle because of `XBPS_CHECK_PKGS=full` which is one way build-check cycles can be broken. Indeed:
```
$ XBPS_CHECK_PKGS=yes ./xbps-src sort-dependencies python3-jupyter_server python3-jupyter_server_terminals
python3-jupyter_server_terminals
python3-jupyter_server
```

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: fix sort-dependencies to use checkdepends
  2023-12-23 22:56 [PR PATCH] fix sort-dependencies to use checkdepends tornaria
  2023-12-25  8:30 ` sgn
  2023-12-25 14:41 ` tornaria
@ 2023-12-25 14:52 ` tornaria
  2023-12-25 15:18 ` [PR PATCH] [Updated] " tornaria
                   ` (9 subsequent siblings)
  12 siblings, 0 replies; 14+ messages in thread
From: tornaria @ 2023-12-25 14:52 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 264 bytes --]

New comment by tornaria on void-packages repository

https://github.com/void-linux/void-packages/pull/47888#issuecomment-1869015736

Comment:
Also, note that there are several situations of non-testing-build where checkdepends will still be required (see #46207).

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PR PATCH] [Updated] fix sort-dependencies to use checkdepends
  2023-12-23 22:56 [PR PATCH] fix sort-dependencies to use checkdepends tornaria
                   ` (2 preceding siblings ...)
  2023-12-25 14:52 ` tornaria
@ 2023-12-25 15:18 ` tornaria
  2023-12-25 15:34 ` tornaria
                   ` (8 subsequent siblings)
  12 siblings, 0 replies; 14+ messages in thread
From: tornaria @ 2023-12-25 15:18 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 1936 bytes --]

There is an updated pull request by tornaria against master on the void-packages repository

https://github.com/tornaria/void-packages sort-deps
https://github.com/void-linux/void-packages/pull/47888

fix sort-dependencies to use checkdepends
As it is now, if `pkgA` checkdepends on `pkgB`, sort-dependencies will still print `pkgA` before `pkgB`. This causes CI to build `pkgB` twice: first build `pkgA` which forces implicit build of `pkgB`; then build of `pkgB` (explicit, so it will ignore the package is already built).

A concrete example:

```
$ ./xbps-src sort-dependencies python3-process-tests python3-pytest-cov
python3-pytest-cov
python3-process-tests
```
After this commit, the order above is the other way around.

The example above causes `python-process-tests` to be built twice, as shown in:
https://github.com/void-linux/void-packages/actions/runs/7107346278/job/19348602412?pr=47610

<!-- Uncomment relevant sections and delete options which are not applicable -->

#### Testing the changes
- I tested the changes in this PR: **YES**

<!--
#### New package
- This new package conforms to the [package requirements](https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#package-requirements): **YES**|**NO**
-->

<!-- Note: If the build is likely to take more than 2 hours, please add ci skip tag as described in
https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#continuous-integration
and test at least one native build and, if supported, at least one cross build.
Ignore this section if this PR is not skipping CI.
-->
<!--
#### Local build testing
- I built this PR locally for my native architecture, (ARCH-LIBC)
- I built this PR locally for these architectures (if supported. mark crossbuilds):
  - aarch64-musl
  - armv7l
  - armv6l-musl
-->


A patch file from https://github.com/void-linux/void-packages/pull/47888.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-sort-deps-47888.patch --]
[-- Type: text/x-diff, Size: 2356 bytes --]

From 4bbf81d2b865ad7b1c1cf4959128b0af8f443c89 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Gonzalo=20Tornar=C3=ADa?= <tornaria@cmat.edu.uy>
Date: Sat, 23 Dec 2023 19:40:53 -0300
Subject: [PATCH] have show-build-deps include checkdepends when using -Q or -K

This makes sort-dependencies take checkdepends into account when using -Q or -K.

As it is now, if pkgA checkdepends on pkgB, sort-dependencies will still
print pkgA before pkgB. This causes CI to build pkgB twice: first build
pkgA which forces implicit build of pkgB; then build of pkgB (explicit,
so it will ignore the package is already built).

A concrete example:

$ ./xbps-src sort-dependencies python3-process-tests python3-pytest-cov
python3-pytest-cov
python3-process-tests

After this commit:

$ ./xbps-src -Q sort-dependencies python3-process-tests python3-pytest-cov
python3-process-tests
python3-pytest-cov

Note that nothing is changed unless -Q or -K flag is passed.
---
 common/xbps-src/shutils/show.sh | 4 ++++
 xbps-src                        | 8 ++++++++
 2 files changed, 12 insertions(+)

diff --git a/common/xbps-src/shutils/show.sh b/common/xbps-src/shutils/show.sh
index 606396d2b4b1a..8af32295d25d5 100644
--- a/common/xbps-src/shutils/show.sh
+++ b/common/xbps-src/shutils/show.sh
@@ -120,6 +120,10 @@ show_pkg_build_deps() {
     show_pkg_build_depends "${makedepends} $(setup_pkg_depends '' 1 1)" "${hostmakedepends}"
 }
 
+show_pkg_check_deps() {
+    show_pkg_build_depends "${checkdepends}" ""
+}
+
 show_pkg_hostmakedepends() {
     show_pkg_build_depends "" "${hostmakedepends}"
 }
diff --git a/xbps-src b/xbps-src
index cdb5f8c6d643e..f4afdd13f5f70 100755
--- a/xbps-src
+++ b/xbps-src
@@ -91,6 +91,9 @@ show-avail <pkgname>
 show-build-deps <pkgname>
     Show required build dependencies for <pkgname>.
 
+show-check-deps <pkgname>
+    Show required check dependencies for <pkgname>.
+
 show-deps <pkgname>
     Show required run-time dependencies for <pkgname>. Package must be
     installed into destdir.
@@ -860,6 +863,11 @@ case "$XBPS_TARGET" in
     show-build-deps)
         read_pkg ignore-problems
         show_pkg_build_deps
+        [ -n "$XBPS_CHECK_PKGS" ] && show_pkg_check_deps
+        ;;
+    show-check-deps)
+        read_pkg ignore-problems
+        show_pkg_check_deps
         ;;
     show-hostmakedepends)
         read_pkg ignore-problems

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: fix sort-dependencies to use checkdepends
  2023-12-23 22:56 [PR PATCH] fix sort-dependencies to use checkdepends tornaria
                   ` (3 preceding siblings ...)
  2023-12-25 15:18 ` [PR PATCH] [Updated] " tornaria
@ 2023-12-25 15:34 ` tornaria
  2023-12-26  3:19 ` [PR PATCH] [Updated] " tornaria
                   ` (7 subsequent siblings)
  12 siblings, 0 replies; 14+ messages in thread
From: tornaria @ 2023-12-25 15:34 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 1399 bytes --]

New comment by tornaria on void-packages repository

https://github.com/void-linux/void-packages/pull/47888#issuecomment-1869029316

Comment:
Pushed a new version. Now `show-build-deps` will include checkdepends when using -Q or -K.

This means `sort-dependencies` will do the same when using -Q or -K.

As is this won't fix CI, since `common/travis/changed_templates.sh` doesn't pass `-Q` to sort-dependencies.

It's also not 100% correct since there are a number of situations where `XBPS_CHECK_PKGS` can be set but check will not run. See here: https://github.com/void-linux/void-packages/pull/46207/files#diff-2553330b694a471fd9a77f9645b03f16c9c92e8e656a5b44634d816cbdaa2a5dR140-R144 for a set of conditions which imply no testing for a particular package. Maybe this can be refactored somewhere and used for this PR and also to fix #46207.

The idea is: read the pkg, determine if checks would be run for this pkg (based on `make_check`, value of `XBPS_CHECK_PKGS`, ci-skip, etc) and only include checkdepends together with build depends if the checks will be run.

This also means it's easy to use `common/scripts/xbps-cycles.py` to catch build-check cycles by doing something like `XBPS_CHECK_PKGS=yes common/scripts/xbps-cycles.py`.

Proposal (again): consider build-check cycles with `XBPS_CHECK_PKGS=yes` to be a bug; only allow build-check cycles when `XBPS_CHECK_PKGS=full`.

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PR PATCH] [Updated] fix sort-dependencies to use checkdepends
  2023-12-23 22:56 [PR PATCH] fix sort-dependencies to use checkdepends tornaria
                   ` (4 preceding siblings ...)
  2023-12-25 15:34 ` tornaria
@ 2023-12-26  3:19 ` tornaria
  2023-12-26  3:37 ` tornaria
                   ` (6 subsequent siblings)
  12 siblings, 0 replies; 14+ messages in thread
From: tornaria @ 2023-12-26  3:19 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 1936 bytes --]

There is an updated pull request by tornaria against master on the void-packages repository

https://github.com/tornaria/void-packages sort-deps
https://github.com/void-linux/void-packages/pull/47888

fix sort-dependencies to use checkdepends
As it is now, if `pkgA` checkdepends on `pkgB`, sort-dependencies will still print `pkgA` before `pkgB`. This causes CI to build `pkgB` twice: first build `pkgA` which forces implicit build of `pkgB`; then build of `pkgB` (explicit, so it will ignore the package is already built).

A concrete example:

```
$ ./xbps-src sort-dependencies python3-process-tests python3-pytest-cov
python3-pytest-cov
python3-process-tests
```
After this commit, the order above is the other way around.

The example above causes `python-process-tests` to be built twice, as shown in:
https://github.com/void-linux/void-packages/actions/runs/7107346278/job/19348602412?pr=47610

<!-- Uncomment relevant sections and delete options which are not applicable -->

#### Testing the changes
- I tested the changes in this PR: **YES**

<!--
#### New package
- This new package conforms to the [package requirements](https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#package-requirements): **YES**|**NO**
-->

<!-- Note: If the build is likely to take more than 2 hours, please add ci skip tag as described in
https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#continuous-integration
and test at least one native build and, if supported, at least one cross build.
Ignore this section if this PR is not skipping CI.
-->
<!--
#### Local build testing
- I built this PR locally for my native architecture, (ARCH-LIBC)
- I built this PR locally for these architectures (if supported. mark crossbuilds):
  - aarch64-musl
  - armv7l
  - armv6l-musl
-->


A patch file from https://github.com/void-linux/void-packages/pull/47888.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-sort-deps-47888.patch --]
[-- Type: text/x-diff, Size: 7957 bytes --]

From 59506730e1ee1a495b6abcc70bf72418d8c48421 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Gonzalo=20Tornar=C3=ADa?= <tornaria@cmat.edu.uy>
Date: Sat, 23 Dec 2023 19:40:53 -0300
Subject: [PATCH 1/6] have show-build-deps include checkdepends when using -Q
 or -K

This makes sort-dependencies take checkdepends into account when using -Q or -K.

As it is now, if pkgA checkdepends on pkgB, sort-dependencies will still
print pkgA before pkgB. This causes CI to build pkgB twice: first build
pkgA which forces implicit build of pkgB; then build of pkgB (explicit,
so it will ignore the package is already built).

A concrete example:

$ ./xbps-src sort-dependencies python3-process-tests python3-pytest-cov
python3-pytest-cov
python3-process-tests

After this commit:

$ ./xbps-src -Q sort-dependencies python3-process-tests python3-pytest-cov
python3-process-tests
python3-pytest-cov

Note that nothing is changed unless -Q or -K flag is passed.
---
 common/xbps-src/shutils/show.sh | 4 ++++
 xbps-src                        | 8 ++++++++
 2 files changed, 12 insertions(+)

diff --git a/common/xbps-src/shutils/show.sh b/common/xbps-src/shutils/show.sh
index 606396d2b4b1a..8af32295d25d5 100644
--- a/common/xbps-src/shutils/show.sh
+++ b/common/xbps-src/shutils/show.sh
@@ -120,6 +120,10 @@ show_pkg_build_deps() {
     show_pkg_build_depends "${makedepends} $(setup_pkg_depends '' 1 1)" "${hostmakedepends}"
 }
 
+show_pkg_check_deps() {
+    show_pkg_build_depends "${checkdepends}" ""
+}
+
 show_pkg_hostmakedepends() {
     show_pkg_build_depends "" "${hostmakedepends}"
 }
diff --git a/xbps-src b/xbps-src
index cdb5f8c6d643e..c7a4246c7f41f 100755
--- a/xbps-src
+++ b/xbps-src
@@ -91,6 +91,9 @@ show-avail <pkgname>
 show-build-deps <pkgname>
     Show required build dependencies for <pkgname>.
 
+show-check-deps <pkgname>
+    Show required check dependencies for <pkgname>.
+
 show-deps <pkgname>
     Show required run-time dependencies for <pkgname>. Package must be
     installed into destdir.
@@ -860,6 +863,11 @@ case "$XBPS_TARGET" in
     show-build-deps)
         read_pkg ignore-problems
         show_pkg_build_deps
+        [ -z "$XBPS_CHECK_PKGS" ] || show_pkg_check_deps
+        ;;
+    show-check-deps)
+        read_pkg ignore-problems
+        show_pkg_check_deps
         ;;
     show-hostmakedepends)
         read_pkg ignore-problems

From fbdc4313b6f05a22e5b5367949a34f795917404f Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Gonzalo=20Tornar=C3=ADa?= <tornaria@cmat.edu.uy>
Date: Mon, 25 Dec 2023 23:55:08 -0300
Subject: [PATCH 2/6] Fix show-build-deps for *-32bit deps

---
 common/xbps-src/shutils/show.sh | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/common/xbps-src/shutils/show.sh b/common/xbps-src/shutils/show.sh
index 8af32295d25d5..6d71033c34d2c 100644
--- a/common/xbps-src/shutils/show.sh
+++ b/common/xbps-src/shutils/show.sh
@@ -75,7 +75,7 @@ show_avail() {
 
 show_eval_dep() {
     local f x _pkgname _srcpkg found
-    local _dep="$1"
+    local _dep="${1%-32bit}"
     local _host="$2"
     if [ -z "$CROSS_BUILD" ] || [ -z "$_host" ]; then
         # ignore dependency on itself
@@ -92,8 +92,7 @@ show_eval_dep() {
         [[ $_dep == $x ]] && found=1 && break
     done
     [[ $found ]] && return
-    _pkgname=${_dep/-32bit}
-    _srcpkg=$(readlink -f ${XBPS_SRCPKGDIR}/${_pkgname})
+    _srcpkg=$(readlink -f ${XBPS_SRCPKGDIR}/${_dep})
     _srcpkg=${_srcpkg##*/}
     echo $_srcpkg
 }

From 3fb6c003646dd7742b1c83034129bbdb2222f468 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Gonzalo=20Tornar=C3=ADa?= <tornaria@cmat.edu.uy>
Date: Mon, 25 Dec 2023 19:09:51 -0300
Subject: [PATCH 3/6] python3-QtPy: fix one check dependency

---
 srcpkgs/python3-QtPy/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/python3-QtPy/template b/srcpkgs/python3-QtPy/template
index 5a77ca425b5d3..79e4016fb0236 100644
--- a/srcpkgs/python3-QtPy/template
+++ b/srcpkgs/python3-QtPy/template
@@ -16,7 +16,7 @@ _qt5check="${_qtcommon} :location :opengl :quick :x11extras :xmlpatterns
 _qt6check="${_qtcommon} :dbus :declarative :devel-tools :gui :network
  :opengl-widgets :printsupport :quick3d :remoteobjects :test :widgets :xml
  qt6-plugin-sqlite"
-checkdepends="python3-pytest-cov python3-pytest-qt font-liberation-ttf
+checkdepends="python3-pytest-cov python3-pytest-qt liberation-fonts-ttf
  ${_qt5check//:/python3-PyQt5-} ${_qt6check//:/python3-pyqt6-}"
 short_desc="Abstraction layer on top of various Python Qt bindings"
 maintainer="Gonzalo Tornaría <tornaria@cmat.edu.uy>"

From 4c9ce56910280ccbba2980a894ea98dabbc289d4 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Gonzalo=20Tornar=C3=ADa?= <tornaria@cmat.edu.uy>
Date: Mon, 25 Dec 2023 22:43:07 -0300
Subject: [PATCH 4/6] bcachefs-tools: fix one make dependency

---
 srcpkgs/bcachefs-tools/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/bcachefs-tools/template b/srcpkgs/bcachefs-tools/template
index 35fa36d13a37e..5c67e9aa9f9fe 100644
--- a/srcpkgs/bcachefs-tools/template
+++ b/srcpkgs/bcachefs-tools/template
@@ -8,7 +8,7 @@ make_install_args="ROOT_SBINDIR=/usr/bin"
 make_use_env=yes
 hostmakedepends="pkg-config cargo clang liburcu-devel"
 makedepends="rust attr-devel keyutils-devel libaio-devel libblkid-devel
- liblz4-devel libscrypt-devel libsodium-devel libudev-devel liburcu-devel
+ liblz4-devel libscrypt-devel libsodium-devel eudev-libudev-devel liburcu-devel
  libuuid-devel libzstd-devel zlib-devel"
 short_desc="Userspace tools for bcachefs"
 maintainer="Leah Neukirchen <leah@vuxu.org>"

From 6cd04f21869916e9b387fff0c8f916fe5354d377 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Gonzalo=20Tornar=C3=ADa?= <tornaria@cmat.edu.uy>
Date: Mon, 25 Dec 2023 22:44:02 -0300
Subject: [PATCH 5/6] qgis: don't makedepend on opencl-clhpp (removed pkg)

---
 srcpkgs/qgis/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/qgis/template b/srcpkgs/qgis/template
index 3c7edb573363e..f066720f06ea4 100644
--- a/srcpkgs/qgis/template
+++ b/srcpkgs/qgis/template
@@ -9,7 +9,7 @@ hostmakedepends="bison flex pkg-config protobuf python3 python3-sip-PyQt5 sip"
 makedepends="exiv2-devel draco-devel expat-devel freexl-devel geos-devel
  gsl-devel grass-devel hdf5-devel libgdal-devel libpdal-devel librttopo-devel
  libspatialindex-devel libspatialite-devel libxml2-devel libzip-devel
- minizip-devel netcdf-devel ocl-icd-devel opencl-clhpp postgresql-libs-devel
+ minizip-devel netcdf-devel ocl-icd-devel postgresql-libs-devel
  proj-devel protobuf-devel python3-devel python3-PyQt-builder
  python3-PyQt5-devel python3-PyQt5-devel-tools python3-PyQt5-multimedia
  python3-pyqt5-qsci-devel python3-PyQt5-webkit python3-sip-PyQt5 qca-qt5-devel

From 9c3fdec187a44c94057e7d7fca7950c70b81714e Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Gonzalo=20Tornar=C3=ADa?= <tornaria@cmat.edu.uy>
Date: Mon, 25 Dec 2023 22:44:42 -0300
Subject: [PATCH 6/6] python3-google-api-python-client: don't checkdepend on
 python3-Django (removed pkg)

---
 srcpkgs/python3-google-api-python-client/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/python3-google-api-python-client/template b/srcpkgs/python3-google-api-python-client/template
index b2f3f446d4489..dfca76ef2fc27 100644
--- a/srcpkgs/python3-google-api-python-client/template
+++ b/srcpkgs/python3-google-api-python-client/template
@@ -8,7 +8,7 @@ make_check_args="--deselect=tests/test__helpers.py::PositionalTests::test_usage
 hostmakedepends="python3-setuptools"
 depends="python3-httplib2 python3-google-auth python3-google-auth-httplib2
  python3-google-api-core python3-uritemplate"
-checkdepends="${depends} python3-Django python3-parameterized python3-openssl
+checkdepends="${depends} python3-parameterized python3-openssl
  python3-oauth2client python3-pytest-xdist"
 short_desc="Google API client library for Python3"
 maintainer="Orphaned <orphan@voidlinux.org>"

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: fix sort-dependencies to use checkdepends
  2023-12-23 22:56 [PR PATCH] fix sort-dependencies to use checkdepends tornaria
                   ` (5 preceding siblings ...)
  2023-12-26  3:19 ` [PR PATCH] [Updated] " tornaria
@ 2023-12-26  3:37 ` tornaria
  2023-12-26 15:48 ` [PR PATCH] [Updated] " tornaria
                   ` (5 subsequent siblings)
  12 siblings, 0 replies; 14+ messages in thread
From: tornaria @ 2023-12-26  3:37 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 783 bytes --]

New comment by tornaria on void-packages repository

https://github.com/void-linux/void-packages/pull/47888#issuecomment-1869228392

Comment:
New version:
 - make sure `./xbps-src show-build-deps PKG` will not exit 1: changed `[ -n "$XBPS_CHECK_PKGS" ] && show_pkgs_check_deps` to `[ -z "$XBPS_CHECK_PKGS" ] || show_pkg_check_deps`
 - Fix `show-build-deps` for dependencies `*-32bit` (try `./xbps-src show-build-deps gcc-multilib`)
 - Fix dependencies in four packages so `show-build-deps` won`t fail.

Now running `common/scripts/xbps-cycles.py` finishes without any error (and no cycles), and it's also possible to run `XBPS_CHECK_PKGS=yes common/scripts/xbps-cycles.py` (no errors, 6 cycles) and `XBPS_CHECK_PKGS=full common/scripts/xbps-cycles.py` (no errors, 8 cycles)



^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PR PATCH] [Updated] fix sort-dependencies to use checkdepends
  2023-12-23 22:56 [PR PATCH] fix sort-dependencies to use checkdepends tornaria
                   ` (6 preceding siblings ...)
  2023-12-26  3:37 ` tornaria
@ 2023-12-26 15:48 ` tornaria
  2023-12-26 16:10 ` Include checkdepends in show-build-deps / fix sort-dependencies for CI tornaria
                   ` (4 subsequent siblings)
  12 siblings, 0 replies; 14+ messages in thread
From: tornaria @ 2023-12-26 15:48 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 1936 bytes --]

There is an updated pull request by tornaria against master on the void-packages repository

https://github.com/tornaria/void-packages sort-deps
https://github.com/void-linux/void-packages/pull/47888

fix sort-dependencies to use checkdepends
As it is now, if `pkgA` checkdepends on `pkgB`, sort-dependencies will still print `pkgA` before `pkgB`. This causes CI to build `pkgB` twice: first build `pkgA` which forces implicit build of `pkgB`; then build of `pkgB` (explicit, so it will ignore the package is already built).

A concrete example:

```
$ ./xbps-src sort-dependencies python3-process-tests python3-pytest-cov
python3-pytest-cov
python3-process-tests
```
After this commit, the order above is the other way around.

The example above causes `python-process-tests` to be built twice, as shown in:
https://github.com/void-linux/void-packages/actions/runs/7107346278/job/19348602412?pr=47610

<!-- Uncomment relevant sections and delete options which are not applicable -->

#### Testing the changes
- I tested the changes in this PR: **YES**

<!--
#### New package
- This new package conforms to the [package requirements](https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#package-requirements): **YES**|**NO**
-->

<!-- Note: If the build is likely to take more than 2 hours, please add ci skip tag as described in
https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#continuous-integration
and test at least one native build and, if supported, at least one cross build.
Ignore this section if this PR is not skipping CI.
-->
<!--
#### Local build testing
- I built this PR locally for my native architecture, (ARCH-LIBC)
- I built this PR locally for these architectures (if supported. mark crossbuilds):
  - aarch64-musl
  - armv7l
  - armv6l-musl
-->


A patch file from https://github.com/void-linux/void-packages/pull/47888.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-sort-deps-47888.patch --]
[-- Type: text/x-diff, Size: 7356 bytes --]

From f15228ae3174e5f1a5ab6db00583cc6ac6f4b7e3 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Gonzalo=20Tornar=C3=ADa?= <tornaria@cmat.edu.uy>
Date: Tue, 26 Dec 2023 12:28:39 -0300
Subject: [PATCH 1/4] common/xbps-src/shutils/build_dependencies.sh: implement
 skip_check_step()

This function contains the logic that determines whether the check step
will be skipped for the current pkg, taking into account `make_check`.

Use this new function in `install_pkg_deps()` so that it uses a more
accurate condition to skip installing check dependencies.

For instance, check dependencies for a pkg with `make_check=extended`
will no longer be installed when using `-Q`. Similar for `make_check=ci-skip`.

Replaces: #46207
---
 common/xbps-src/shutils/build_dependencies.sh | 15 +++++++++++++--
 1 file changed, 13 insertions(+), 2 deletions(-)

diff --git a/common/xbps-src/shutils/build_dependencies.sh b/common/xbps-src/shutils/build_dependencies.sh
index 20f61528d14c2..9eadb674b384d 100644
--- a/common/xbps-src/shutils/build_dependencies.sh
+++ b/common/xbps-src/shutils/build_dependencies.sh
@@ -124,6 +124,17 @@ check_installed_pkg() {
     return 1
 }
 
+#
+# Return 0 if we will skip the check step
+#
+skip_check_step() {
+    [ -z "$XBPS_CHECK_PKGS" ] ||
+        [ "$XBPS_CROSS_BUILD" ] ||
+        [ "$make_check" = ci-skip  -a "$XBPS_BUILD_ENVIRONMENT" = void-packages-ci ] ||
+        [ "$make_check" = extended -a "$XBPS_CHECK_PKGS" != full ] ||
+        [ "$make_check" = no ]
+}
+
 #
 # Build all dependencies required to build and run.
 #
@@ -137,7 +148,7 @@ install_pkg_deps() {
     local -a host_missing_deps missing_deps missing_rdeps
 
     [ -z "$pkgname" ] && return 2
-    [ -z "$XBPS_CHECK_PKGS" ] && unset checkdepends
+    skip_check_step && unset checkdepends
 
     if [[ $build_style ]] || [[ $build_helper ]]; then
         style=" with"
@@ -208,7 +219,7 @@ install_pkg_deps() {
     #
     # Host check dependencies.
     #
-    if [[ ${checkdepends} ]] && [[ $XBPS_CHECK_PKGS ]] && [ -z "$XBPS_CROSS_BUILD" ]; then
+    if [[ ${checkdepends} ]]; then
         templates=""
         # check validity
         for f in ${checkdepends}; do

From 7be0492ad0109836b0f5ccdb76db3b622ea41001 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Gonzalo=20Tornar=C3=ADa?= <tornaria@cmat.edu.uy>
Date: Sat, 23 Dec 2023 19:40:53 -0300
Subject: [PATCH 2/4] ./xbps-src show-build-deps: include checkdepends when
 using -Q or -K

Due to this change, `./xbps-src sort-dependencies` will take
checkdepends into account when using -Q or -K.

Before this commit, if `pkgA` checkdepends on `pkgB`, sort-dependencies
could still print `pkgA` before `pkgB`. This causes CI to build `pkgB`
twice: first when building `pkgA`, which forces implicit build of pkgB;
second when building `pkgB` (explicit, so it will ignore the package is
already built).

The implementation uses `skip_check_step()` from previous commit, for
consistency, so checkdepends are only taken into account if the check
step would be enabled.

In particular, nothing is changed unless -Q or -K flag is passed.

EXAMPLE:

Before:
```
$ ./xbps-src -Q sort-dependencies python3-process-tests python3-pytest-cov
python3-pytest-cov
python3-process-tests
```

After:
```
$ ./xbps-src -Q sort-dependencies python3-process-tests python3-pytest-cov
python3-process-tests
python3-pytest-cov
```
---
 common/xbps-src/shutils/show.sh | 8 +++++++-
 xbps-src                        | 7 +++++++
 2 files changed, 14 insertions(+), 1 deletion(-)

diff --git a/common/xbps-src/shutils/show.sh b/common/xbps-src/shutils/show.sh
index 606396d2b4b1a..18817f5c619a3 100644
--- a/common/xbps-src/shutils/show.sh
+++ b/common/xbps-src/shutils/show.sh
@@ -117,7 +117,9 @@ show_pkg_build_depends() {
 }
 
 show_pkg_build_deps() {
-    show_pkg_build_depends "${makedepends} $(setup_pkg_depends '' 1 1)" "${hostmakedepends}"
+    local build_depends="${makedepends} $(setup_pkg_depends '' 1 1)"
+    skip_check_step || build_depends+=" ${checkdepends}"
+    show_pkg_build_depends "${build_depends}" "${hostmakedepends}"
 }
 
 show_pkg_hostmakedepends() {
@@ -128,6 +130,10 @@ show_pkg_makedepends() {
     show_pkg_build_depends "${makedepends}" ""
 }
 
+show_pkg_checkdepends() {
+    show_pkg_build_depends "${checkdepends}" ""
+}
+
 show_pkg_build_options() {
     local f
 
diff --git a/xbps-src b/xbps-src
index cdb5f8c6d643e..b8ce3b21b13a4 100755
--- a/xbps-src
+++ b/xbps-src
@@ -91,6 +91,9 @@ show-avail <pkgname>
 show-build-deps <pkgname>
     Show required build dependencies for <pkgname>.
 
+show-check-deps <pkgname>
+    Show required check dependencies for <pkgname>.
+
 show-deps <pkgname>
     Show required run-time dependencies for <pkgname>. Package must be
     installed into destdir.
@@ -869,6 +872,10 @@ case "$XBPS_TARGET" in
         read_pkg ignore-problems
         show_pkg_makedepends
         ;;
+    show-checkdepends)
+        read_pkg ignore-problems
+        show_pkg_checkdepends
+        ;;
     show-pkg-var-dump)
         read_pkg ignore-problems
         for sub_name in $subpackages; do

From 177b6710406b502da2d6c6e49b5335234a61b243 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Gonzalo=20Tornar=C3=ADa?= <tornaria@cmat.edu.uy>
Date: Tue, 26 Dec 2023 12:46:37 -0300
Subject: [PATCH 3/4] common/travis/build.sh: use $test for sort-dependencies

This ensures that checkdepends will be taken into account in the build
order whenever test is enabled.
---
 common/travis/build.sh | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/common/travis/build.sh b/common/travis/build.sh
index 007a61f994d78..b319057344304 100755
--- a/common/travis/build.sh
+++ b/common/travis/build.sh
@@ -10,7 +10,7 @@ if [ "$3" = 1 ]; then
 	test="-Q"
 fi
 
-PKGS=$(/hostrepo/xbps-src sort-dependencies $(cat /tmp/templates))
+PKGS=$(/hostrepo/xbps-src $test sort-dependencies $(cat /tmp/templates))
 
 for pkg in ${PKGS}; do
 	/hostrepo/xbps-src -j$(nproc) -s -H "$HOME"/hostdir $arch $test pkg "$pkg"

From c46793f2daf3a6ab0306702b1c9a402c03ce2e54 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Gonzalo=20Tornar=C3=ADa?= <tornaria@cmat.edu.uy>
Date: Tue, 26 Dec 2023 10:38:49 -0300
Subject: [PATCH 4/4] common/scripts/xbps-cycles.py: add -Q and -K options for
 dependencies

---
 common/scripts/xbps-cycles.py | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/common/scripts/xbps-cycles.py b/common/scripts/xbps-cycles.py
index 7710381eb2925..1f51fe71fd809 100755
--- a/common/scripts/xbps-cycles.py
+++ b/common/scripts/xbps-cycles.py
@@ -101,6 +101,10 @@ def find_cycles(depmap, xbpsdir):
 			help='Directory used to cache build dependencies (must exist)')
 	parser.add_argument('-d', '--directory',
 			default=None, help='Path to void-packages repo')
+	parser.add_argument('-Q', dest='check_pkgs', action='store_const',
+			const='yes', help='Use build dependencies for check -Q')
+	parser.add_argument('-K', dest='check_pkgs', action='store_const',
+			const='full', help='Use build dependencies for check -K')
 
 	args = parser.parse_args()
 
@@ -108,6 +112,9 @@ def find_cycles(depmap, xbpsdir):
 		try: args.directory = os.environ['XBPS_DISTDIR']
 		except KeyError: args.directory = '.'
 
+	if args.check_pkgs:
+		os.environ['XBPS_CHECK_PKGS'] = args.check_pkgs
+
 	pool = multiprocessing.Pool(processes = args.jobs)
 
 	pattern = os.path.join(args.directory, 'srcpkgs', '*')

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: Include checkdepends in show-build-deps / fix sort-dependencies for CI
  2023-12-23 22:56 [PR PATCH] fix sort-dependencies to use checkdepends tornaria
                   ` (7 preceding siblings ...)
  2023-12-26 15:48 ` [PR PATCH] [Updated] " tornaria
@ 2023-12-26 16:10 ` tornaria
  2024-02-15 15:15 ` Accept -Q / -K in show-build-deps, sort-dependencies, xbps-cycles.py tornaria
                   ` (3 subsequent siblings)
  12 siblings, 0 replies; 14+ messages in thread
From: tornaria @ 2023-12-26 16:10 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 1021 bytes --]

New comment by tornaria on void-packages repository

https://github.com/void-linux/void-packages/pull/47888#issuecomment-1869639495

Comment:
Please review. In this version I moved fixing other pkgs to #47910 to make this PR simpler.

Summary of changes:
1. implement function `skip_check_step()` with the logic that determines whether the check step will be skipped for the current pkg, taking into account `make_check`. As a side effect `install_pkg_deps()` now uses a more accurate condition to skip installing checkdepends.
2. Fix  implementation of `./xbps-src show-build-deps` so it includes checkdepends when using -Q or -K (using `skip_check_step()` to match `install_pkg_deps()` so it will be consistent). As a side effect, `./xbps-src sort-dependencies` will take checkdepends into account.
3. Change `common/travis/build.sh` so that -Q is passed to sort-dependencies when we are doing a test build.
4. Add `-Q` and `-K` flags to `common/scripts/xbps-cycles.py`.

@sgn does this address your concerns? 

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: Accept -Q / -K in show-build-deps, sort-dependencies, xbps-cycles.py
  2023-12-23 22:56 [PR PATCH] fix sort-dependencies to use checkdepends tornaria
                   ` (8 preceding siblings ...)
  2023-12-26 16:10 ` Include checkdepends in show-build-deps / fix sort-dependencies for CI tornaria
@ 2024-02-15 15:15 ` tornaria
  2024-03-18  2:58 ` tornaria
                   ` (2 subsequent siblings)
  12 siblings, 0 replies; 14+ messages in thread
From: tornaria @ 2024-02-15 15:15 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 147 bytes --]

New comment by tornaria on void-packages repository

https://github.com/void-linux/void-packages/pull/47888#issuecomment-1946299411

Comment:
ping

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: Accept -Q / -K in show-build-deps, sort-dependencies, xbps-cycles.py
  2023-12-23 22:56 [PR PATCH] fix sort-dependencies to use checkdepends tornaria
                   ` (9 preceding siblings ...)
  2024-02-15 15:15 ` Accept -Q / -K in show-build-deps, sort-dependencies, xbps-cycles.py tornaria
@ 2024-03-18  2:58 ` tornaria
  2024-04-07 21:06 ` tornaria
  2024-04-08  1:57 ` [PR PATCH] [Merged]: " sgn
  12 siblings, 0 replies; 14+ messages in thread
From: tornaria @ 2024-03-18  2:58 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 1142 bytes --]

New comment by tornaria on void-packages repository

https://github.com/void-linux/void-packages/pull/47888#issuecomment-2002785810

Comment:
This also fixes `xbulk`. A quick example, currently on master:


The following is ok, since neither package depends or builddepends on the other:
```
$ xbulk -n python3-coverage python3-flaky
pkg=pkg-python3-coverage; ./xbps-src  pkg ${pkg#pkg-}
pkg=pkg-python3-flaky; ./xbps-src  pkg ${pkg#pkg-}
```

The following is NOT ok, since coverage checkdepends on flaky
```
$ xbulk -n -K python3-coverage python3-flaky
pkg=pkg-python3-coverage; ./xbps-src  -K pkg ${pkg#pkg-}
pkg=pkg-python3-flaky; ./xbps-src  -K pkg ${pkg#pkg-}
```
This is NOT ok, since 


With this branch, the no-check version does the same as before, and the check version does the proper thing.
```
$ xbulk -n python3-coverage python3-flaky
pkg=pkg-python3-coverage; ./xbps-src  pkg ${pkg#pkg-}
pkg=pkg-python3-flaky; ./xbps-src  pkg ${pkg#pkg-}
$ xbulk -n -K python3-coverage python3-flaky
pkg=pkg-python3-flaky; ./xbps-src  -K pkg ${pkg#pkg-}
pkg=pkg-python3-coverage; ./xbps-src  -K pkg ${pkg#pkg-}
```

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: Accept -Q / -K in show-build-deps, sort-dependencies, xbps-cycles.py
  2023-12-23 22:56 [PR PATCH] fix sort-dependencies to use checkdepends tornaria
                   ` (10 preceding siblings ...)
  2024-03-18  2:58 ` tornaria
@ 2024-04-07 21:06 ` tornaria
  2024-04-08  1:57 ` [PR PATCH] [Merged]: " sgn
  12 siblings, 0 replies; 14+ messages in thread
From: tornaria @ 2024-04-07 21:06 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 454 bytes --]

New comment by tornaria on void-packages repository

https://github.com/void-linux/void-packages/pull/47888#issuecomment-2041609260

Comment:
@sgn: this scratches an itch and I think it's in good shape. I use it sometimes by merging into my current branch (useful on jupyter branch which often has several updates with a number of check dependencies).

By fixing sort-dependencies when used with `-Q` or `-K`, this fixes CI build and xbulk with check.

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PR PATCH] [Merged]: Accept -Q / -K in show-build-deps, sort-dependencies, xbps-cycles.py
  2023-12-23 22:56 [PR PATCH] fix sort-dependencies to use checkdepends tornaria
                   ` (11 preceding siblings ...)
  2024-04-07 21:06 ` tornaria
@ 2024-04-08  1:57 ` sgn
  12 siblings, 0 replies; 14+ messages in thread
From: sgn @ 2024-04-08  1:57 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 2137 bytes --]

There's a merged pull request on the void-packages repository

Accept -Q / -K in show-build-deps, sort-dependencies, xbps-cycles.py
https://github.com/void-linux/void-packages/pull/47888

Description:
As it is now, if `pkgA` checkdepends on `pkgB`, sort-dependencies will still print `pkgA` before `pkgB`. This causes CI to build `pkgB` twice: first build `pkgA` which forces implicit build of `pkgB`; then build of `pkgB` (explicit, so it will ignore the package is already built).

A concrete example:

```
$ ./xbps-src sort-dependencies python3-process-tests python3-pytest-cov
python3-pytest-cov
python3-process-tests
```

The example above causes `python-process-tests` to be built twice, as shown in:
https://github.com/void-linux/void-packages/actions/runs/7107346278/job/19348602412?pr=47610


After this commit one can do
```
$ ./xbps-src -Q sort-dependencies python3-process-tests python3-pytest-cov
python3-process-tests
python3-pytest-cov
```

The CI issue is fixed by pasing -Q to sort-dependencies when we are doing a test build.

Jump to https://github.com/void-linux/void-packages/pull/47888#issuecomment-1869639495 to skip comments about earlier versions of the PR.

<!-- Uncomment relevant sections and delete options which are not applicable -->

#### Testing the changes
- I tested the changes in this PR: **YES**

<!--
#### New package
- This new package conforms to the [package requirements](https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#package-requirements): **YES**|**NO**
-->

<!-- Note: If the build is likely to take more than 2 hours, please add ci skip tag as described in
https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#continuous-integration
and test at least one native build and, if supported, at least one cross build.
Ignore this section if this PR is not skipping CI.
-->
<!--
#### Local build testing
- I built this PR locally for my native architecture, (ARCH-LIBC)
- I built this PR locally for these architectures (if supported. mark crossbuilds):
  - aarch64-musl
  - armv7l
  - armv6l-musl
-->


^ permalink raw reply	[flat|nested] 14+ messages in thread

end of thread, other threads:[~2024-04-08  1:57 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-12-23 22:56 [PR PATCH] fix sort-dependencies to use checkdepends tornaria
2023-12-25  8:30 ` sgn
2023-12-25 14:41 ` tornaria
2023-12-25 14:52 ` tornaria
2023-12-25 15:18 ` [PR PATCH] [Updated] " tornaria
2023-12-25 15:34 ` tornaria
2023-12-26  3:19 ` [PR PATCH] [Updated] " tornaria
2023-12-26  3:37 ` tornaria
2023-12-26 15:48 ` [PR PATCH] [Updated] " tornaria
2023-12-26 16:10 ` Include checkdepends in show-build-deps / fix sort-dependencies for CI tornaria
2024-02-15 15:15 ` Accept -Q / -K in show-build-deps, sort-dependencies, xbps-cycles.py tornaria
2024-03-18  2:58 ` tornaria
2024-04-07 21:06 ` tornaria
2024-04-08  1:57 ` [PR PATCH] [Merged]: " sgn

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).