all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* [bug#53040] [PATCH] gnu: bubblewrap: Update to 0.5.0.
@ 2022-01-05 22:54 kiasoc5--- via Guix-patches via
  2022-01-09 21:50 ` Ludovic Courtès
  2022-01-10 23:14 ` kiasoc5--- via Guix-patches via
  0 siblings, 2 replies; 7+ messages in thread
From: kiasoc5--- via Guix-patches via @ 2022-01-05 22:54 UTC (permalink / raw)
  To: 53040

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

Unfortunately some tests fail because of missing locales, I've attached the test log. Help is appreciated.

[-- Attachment #2: 0001-gnu-bubblewrap-Update-to-0.5.0.patch --]
[-- Type: text/x-patch, Size: 1284 bytes --]

From 83cd691bc4875373e84a1b4b77ffa25cf85e9136 Mon Sep 17 00:00:00 2001
From: kiasoc5 <kiasoc5@tutanota.com>
Date: Wed, 5 Jan 2022 02:18:15 -0500
Subject: [PATCH] gnu: bubblewrap: Update to 0.5.0.

* gnu/packages/virtualization.scm (bubblewrap): Update to 0.5.0.
---
 gnu/packages/virtualization.scm | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/gnu/packages/virtualization.scm b/gnu/packages/virtualization.scm
index 6a40955dbb..71c7178c6d 100644
--- a/gnu/packages/virtualization.scm
+++ b/gnu/packages/virtualization.scm
@@ -1927,7 +1927,7 @@ (define-public python-vagrant
 (define-public bubblewrap
   (package
     (name "bubblewrap")
-    (version "0.4.1")
+    (version "0.5.0")
     (source (origin
               (method url-fetch)
               (uri (string-append "https://github.com/containers/bubblewrap/"
@@ -1935,7 +1935,7 @@ (define-public bubblewrap
                                   version ".tar.xz"))
               (sha256
                (base32
-                "00ycgi6q2yngh06bnz50wkvar6r2jnjf3j158grhi9k13jdrpimr"))))
+                "0608l2sjwhnb1c0mslah1h6yjvqr17wk60by6i710qwxg4rszz8n"))))
     (build-system gnu-build-system)
     (arguments
      `(#:phases

base-commit: 8860e9db560c5d9e74277b608071fbb93579db4f
-- 
2.34.1


[-- Attachment #3: test-suite.log --]
[-- Type: text/x-log, Size: 3427 bytes --]

========================================
   bubblewrap 0.5.0: ./test-suite.log
========================================

# TOTAL: 25
# PASS:  19
# SKIP:  0
# XFAIL: 0
# FAIL:  0
# XPASS: 0
# ERROR: 6

.. contents:: :depth: 2

ERROR: tests/test-run.sh
========================

+++ dirname ./tests/test-run.sh
++ cd ./tests
++ pwd
+ srcd=/tmp/guix-build-bubblewrap-0.5.0.drv-0/bubblewrap-0.5.0/tests
+ . /tmp/guix-build-bubblewrap-0.5.0.drv-0/bubblewrap-0.5.0/tests/libtest.sh
++ set -e
++ '[' -n /tmp/guix-build-bubblewrap-0.5.0.drv-0/bubblewrap-0.5.0 ']'
++ test_srcdir=/tmp/guix-build-bubblewrap-0.5.0.drv-0/bubblewrap-0.5.0/tests
++ '[' -n /tmp/guix-build-bubblewrap-0.5.0.drv-0/bubblewrap-0.5.0 ']'
++ test_builddir=/tmp/guix-build-bubblewrap-0.5.0.drv-0/bubblewrap-0.5.0/tests
++ . /tmp/guix-build-bubblewrap-0.5.0.drv-0/bubblewrap-0.5.0/tests/libtest-core.sh
+++ type -p locale
++++ locale -a
++++ grep -iEe '^(C|en_US)\.(UTF-8|utf8)$'
++++ head -n1
++++ true
+++ export LC_ALL=
+++ LC_ALL=
+++ '[' -z '' ']'
+++ fatal 'Can'\''t find suitable UTF-8 locale'
+++ echo 'Can'\''t' find suitable UTF-8 locale
Can't find suitable UTF-8 locale
+++ exit 1
ERROR: tests/test-run.sh - missing test plan
ERROR: tests/test-run.sh - exited with status 1

ERROR: tests/test-specifying-userns.sh
======================================

+++ dirname ./tests/test-specifying-userns.sh
++ cd ./tests
++ pwd
+ srcd=/tmp/guix-build-bubblewrap-0.5.0.drv-0/bubblewrap-0.5.0/tests
+ . /tmp/guix-build-bubblewrap-0.5.0.drv-0/bubblewrap-0.5.0/tests/libtest.sh
++ set -e
++ '[' -n /tmp/guix-build-bubblewrap-0.5.0.drv-0/bubblewrap-0.5.0 ']'
++ test_srcdir=/tmp/guix-build-bubblewrap-0.5.0.drv-0/bubblewrap-0.5.0/tests
++ '[' -n /tmp/guix-build-bubblewrap-0.5.0.drv-0/bubblewrap-0.5.0 ']'
++ test_builddir=/tmp/guix-build-bubblewrap-0.5.0.drv-0/bubblewrap-0.5.0/tests
++ . /tmp/guix-build-bubblewrap-0.5.0.drv-0/bubblewrap-0.5.0/tests/libtest-core.sh
+++ type -p locale
++++ locale -a
++++ grep -iEe '^(C|en_US)\.(UTF-8|utf8)$'
++++ head -n1
++++ true
+++ export LC_ALL=
+++ LC_ALL=
+++ '[' -z '' ']'
+++ fatal 'Can'\''t find suitable UTF-8 locale'
+++ echo 'Can'\''t' find suitable UTF-8 locale
Can't find suitable UTF-8 locale
+++ exit 1
ERROR: tests/test-specifying-userns.sh - missing test plan
ERROR: tests/test-specifying-userns.sh - exited with status 1

ERROR: tests/test-specifying-pidns.sh
=====================================

+++ dirname ./tests/test-specifying-pidns.sh
++ cd ./tests
++ pwd
+ srcd=/tmp/guix-build-bubblewrap-0.5.0.drv-0/bubblewrap-0.5.0/tests
+ . /tmp/guix-build-bubblewrap-0.5.0.drv-0/bubblewrap-0.5.0/tests/libtest.sh
++ set -e
++ '[' -n /tmp/guix-build-bubblewrap-0.5.0.drv-0/bubblewrap-0.5.0 ']'
++ test_srcdir=/tmp/guix-build-bubblewrap-0.5.0.drv-0/bubblewrap-0.5.0/tests
++ '[' -n /tmp/guix-build-bubblewrap-0.5.0.drv-0/bubblewrap-0.5.0 ']'
++ test_builddir=/tmp/guix-build-bubblewrap-0.5.0.drv-0/bubblewrap-0.5.0/tests
++ . /tmp/guix-build-bubblewrap-0.5.0.drv-0/bubblewrap-0.5.0/tests/libtest-core.sh
+++ type -p locale
++++ locale -a
++++ grep -iEe '^(C|en_US)\.(UTF-8|utf8)$'
++++ head -n1
++++ true
+++ export LC_ALL=
+++ LC_ALL=
+++ '[' -z '' ']'
+++ fatal 'Can'\''t find suitable UTF-8 locale'
+++ echo 'Can'\''t' find suitable UTF-8 locale
Can't find suitable UTF-8 locale
+++ exit 1
ERROR: tests/test-specifying-pidns.sh - missing test plan
ERROR: tests/test-specifying-pidns.sh - exited with status 1


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

* [bug#53040] [PATCH] gnu: bubblewrap: Update to 0.5.0.
  2022-01-05 22:54 [bug#53040] [PATCH] gnu: bubblewrap: Update to 0.5.0 kiasoc5--- via Guix-patches via
@ 2022-01-09 21:50 ` Ludovic Courtès
  2022-01-12 16:42   ` Josselin Poiret via Guix-patches via
  2022-01-10 23:14 ` kiasoc5--- via Guix-patches via
  1 sibling, 1 reply; 7+ messages in thread
From: Ludovic Courtès @ 2022-01-09 21:50 UTC (permalink / raw)
  To: kiasoc5; +Cc: 53040

Hi,

kiasoc5@tutanota.com skribis:

> ERROR: tests/test-specifying-pidns.sh
> =====================================
>
> +++ dirname ./tests/test-specifying-pidns.sh
> ++ cd ./tests
> ++ pwd
> + srcd=/tmp/guix-build-bubblewrap-0.5.0.drv-0/bubblewrap-0.5.0/tests
> + . /tmp/guix-build-bubblewrap-0.5.0.drv-0/bubblewrap-0.5.0/tests/libtest.sh
> ++ set -e
> ++ '[' -n /tmp/guix-build-bubblewrap-0.5.0.drv-0/bubblewrap-0.5.0 ']'
> ++ test_srcdir=/tmp/guix-build-bubblewrap-0.5.0.drv-0/bubblewrap-0.5.0/tests
> ++ '[' -n /tmp/guix-build-bubblewrap-0.5.0.drv-0/bubblewrap-0.5.0 ']'
> ++ test_builddir=/tmp/guix-build-bubblewrap-0.5.0.drv-0/bubblewrap-0.5.0/tests
> ++ . /tmp/guix-build-bubblewrap-0.5.0.drv-0/bubblewrap-0.5.0/tests/libtest-core.sh
> +++ type -p locale
> ++++ locale -a
> ++++ grep -iEe '^(C|en_US)\.(UTF-8|utf8)$'

The ‘en_US.utf8’ locale is available; however, the ‘locale -a’ command
won’t list it, for obscure reasons.

I suggest patching libtest-core.sh so that it unconditionally uses
en_US.utf8 instead of running ‘locale -a’.

HTH!

Ludo’.




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

* [bug#53040] [PATCH] gnu: bubblewrap: Update to 0.5.0.
  2022-01-05 22:54 [bug#53040] [PATCH] gnu: bubblewrap: Update to 0.5.0 kiasoc5--- via Guix-patches via
  2022-01-09 21:50 ` Ludovic Courtès
@ 2022-01-10 23:14 ` kiasoc5--- via Guix-patches via
  2022-01-11 17:52   ` Ludovic Courtès
  1 sibling, 1 reply; 7+ messages in thread
From: kiasoc5--- via Guix-patches via @ 2022-01-10 23:14 UTC (permalink / raw)
  To: 53040; +Cc: ludo

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

Fixed locale in tests, thanks Ludo for the suggestion via email. Also fixed more test substitutions and simplified inputs.

[-- Attachment #2: 0001-gnu-bubblewrap-Update-to-0.5.0.patch --]
[-- Type: text/x-patch, Size: 5930 bytes --]

From f5c56100d62d315c3ed860898998a7c8afc78d50 Mon Sep 17 00:00:00 2001
From: kiasoc5 <kiasoc5@tutanota.com>
Date: Mon, 10 Jan 2022 17:58:35 -0500
Subject: [PATCH] gnu: bubblewrap: Update to 0.5.0.

* gnu/packages/patches/bubblewrap-fix-locale-in-tests.patch: Add it.
* gnu/local.mk (dist_patch_DATA): Add it.
* gnu/packages/virtualization.scm (bubblewrap): Update to 0.5.0.
[source]: Add patch.
[arguments]: Adjust test substitutions.
[inputs]: Remove labels.
[native-inputs]: Remove labels.
---
 gnu/local.mk                                  |  1 +
 .../bubblewrap-fix-locale-in-tests.patch      | 34 +++++++++++++++++++
 gnu/packages/virtualization.scm               | 24 ++++++++-----
 3 files changed, 50 insertions(+), 9 deletions(-)
 create mode 100644 gnu/packages/patches/bubblewrap-fix-locale-in-tests.patch

diff --git a/gnu/local.mk b/gnu/local.mk
index fe21cf8062..c511d78c07 100644
--- a/gnu/local.mk
+++ b/gnu/local.mk
@@ -910,6 +910,7 @@ dist_patch_DATA =						\
   %D%/packages/patches/binutils-mingw-w64-deterministic.patch	\
   %D%/packages/patches/bpftrace-disable-bfd-disasm.patch	\
   %D%/packages/patches/byobu-writable-status.patch		\
+  %D%/packages/patches/bubblewrap-fix-locale-in-tests.patch	\
   %D%/packages/patches/cabal-install-base16-bytestring1.0.patch		\
   %D%/packages/patches/cabal-install-ghc8.10.patch		\
   %D%/packages/patches/cairo-CVE-2018-19876.patch		\
diff --git a/gnu/packages/patches/bubblewrap-fix-locale-in-tests.patch b/gnu/packages/patches/bubblewrap-fix-locale-in-tests.patch
new file mode 100644
index 0000000000..bd5924ef87
--- /dev/null
+++ b/gnu/packages/patches/bubblewrap-fix-locale-in-tests.patch
@@ -0,0 +1,34 @@
+From 9282223de4b511aeda3b7d2caf3810a56a865710 Mon Sep 17 00:00:00 2001
+From: kiasoc5 <kiasoc5@tutanota.com>
+Date: Mon, 10 Jan 2022 14:16:32 -0500
+Subject: [PATCH] Use C locale unconditionally for tests.
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+The ‘en_US.utf8’ locale is available. However, the ‘locale -a’ command won’t list it.
+---
+ tests/libtest-core.sh | 7 +------
+ 1 file changed, 1 insertion(+), 6 deletions(-)
+
+diff --git a/tests/libtest-core.sh b/tests/libtest-core.sh
+index 9632e90..82951dd 100644
+--- a/tests/libtest-core.sh
++++ b/tests/libtest-core.sh
+@@ -41,12 +41,7 @@ assert_not_reached () {
+ #
+ # If we can't find the locale command assume we have support for C.UTF-8
+ # (e.g. musl based systems)
+-if type -p locale >/dev/null; then
+-    export LC_ALL=$(locale -a | grep -iEe '^(C|en_US)\.(UTF-8|utf8)$' | head -n1 || true)
+-    if [ -z "${LC_ALL}" ]; then fatal "Can't find suitable UTF-8 locale"; fi
+-else
+-    export LC_ALL=C.UTF-8
+-fi
++export LC_ALL=en_US.utf8
+ # A GNU extension, used whenever LC_ALL is not C
+ unset LANGUAGE
+ 
+-- 
+2.34.1
+
diff --git a/gnu/packages/virtualization.scm b/gnu/packages/virtualization.scm
index 6a40955dbb..39acb90570 100644
--- a/gnu/packages/virtualization.scm
+++ b/gnu/packages/virtualization.scm
@@ -1927,7 +1927,7 @@ (define-public python-vagrant
 (define-public bubblewrap
   (package
     (name "bubblewrap")
-    (version "0.4.1")
+    (version "0.5.0")
     (source (origin
               (method url-fetch)
               (uri (string-append "https://github.com/containers/bubblewrap/"
@@ -1935,7 +1935,8 @@ (define-public bubblewrap
                                   version ".tar.xz"))
               (sha256
                (base32
-                "00ycgi6q2yngh06bnz50wkvar6r2jnjf3j158grhi9k13jdrpimr"))))
+                "0608l2sjwhnb1c0mslah1h6yjvqr17wk60by6i710qwxg4rszz8n"))
+               (patches (search-patches "bubblewrap-fix-locale-in-tests.patch"))))
     (build-system gnu-build-system)
     (arguments
      `(#:phases
@@ -1951,7 +1952,9 @@ (define-public bubblewrap
                (substitute* "tests/test-run.sh"
                  (("/var/tmp") tmp-dir)
                  ;; Tests create a temporary python script, so fix its shebang.
-                 (("/usr/bin/env python") (which "python"))
+                 (("/usr/bin/env python3") (which "python3"))
+                 ;; Tests call /usr/bin/env, so fix its path.
+                 (("/usr/bin/env") (which "env"))
                  ;; Some tests try to access /usr, but that doesn't exist.
                  ;; Give them /gnu instead.
                  (("/usr") "/gnu")
@@ -1960,18 +1963,21 @@ (define-public bubblewrap
                  (("--ro-bind /lib /lib") "--ro-bind /gnu /lib")
                  (("  */bin/bash") (which "bash"))
                  (("/bin/sh") (which "sh"))
-                 (("findmnt") (which "findmnt"))))
+                 (("findmnt") (which "findmnt")))
+               (substitute* "tests/libtest.sh"
+                 (("/var/tmp") tmp-dir)
+                 (("/usr") "/gnu")
+                 (("--ro-bind /bin /bin") "--ro-bind /gnu /bin")
+                 (("--ro-bind /sbin /sbin") "--ro-bind /gnu /sbin")
+                 (("--ro-bind /lib /lib") "--ro-bind /gnu /lib")))
              #t))
          ;; Remove the directory we gave to tests to have a clean package.
          (add-after 'check 'remove-tmp-dir
            (lambda* (#:key outputs #:allow-other-keys)
              (delete-file-recursively (string-append (assoc-ref outputs "out") "/tmp"))
              #t)))))
-    (inputs
-     (list libcap))
-    (native-inputs
-     `(("python" ,python-wrapper)
-       ("util-linux" ,util-linux)))
+    (inputs (list libcap))
+    (native-inputs (list python-wrapper util-linux))
     (home-page "https://github.com/containers/bubblewrap")
     (synopsis "Unprivileged sandboxing tool")
     (description "Bubblewrap is aimed at running applications in a sandbox,

base-commit: 19a4759cadf601f40d2a32efdbf6190d7341a8ca
-- 
2.34.1


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

* [bug#53040] [PATCH] gnu: bubblewrap: Update to 0.5.0.
  2022-01-10 23:14 ` kiasoc5--- via Guix-patches via
@ 2022-01-11 17:52   ` Ludovic Courtès
  2022-01-11 21:46     ` kiasoc5--- via Guix-patches via
  0 siblings, 1 reply; 7+ messages in thread
From: Ludovic Courtès @ 2022-01-11 17:52 UTC (permalink / raw)
  To: kiasoc5; +Cc: 53040

Hi,

kiasoc5@tutanota.com skribis:

> Fixed locale in tests, thanks Ludo for the suggestion via email. Also fixed more test substitutions and simplified inputs.
>
>>From f5c56100d62d315c3ed860898998a7c8afc78d50 Mon Sep 17 00:00:00 2001
> From: kiasoc5 <kiasoc5@tutanota.com>
> Date: Mon, 10 Jan 2022 17:58:35 -0500
> Subject: [PATCH] gnu: bubblewrap: Update to 0.5.0.
>
> * gnu/packages/patches/bubblewrap-fix-locale-in-tests.patch: Add it.
> * gnu/local.mk (dist_patch_DATA): Add it.
> * gnu/packages/virtualization.scm (bubblewrap): Update to 0.5.0.
> [source]: Add patch.
> [arguments]: Adjust test substitutions.
> [inputs]: Remove labels.
> [native-inputs]: Remove labels.

That LGTM.  I tested direct dependents as shown by:

  ./pre-inst-env guix graph -M1 -t reverse-package bubblewrap | xdot -f fdp -

Unfortunately, the update breaks flatpak (both 1.12.1 and 1.12.2):

--8<---------------cut here---------------start------------->8---
make[3]: Nothing to be done for 'tests/org.flatpak.Authenticator.test.service.in'.
rm -rf tests/runtime-repo
PATH=/tmp/guix-build-flatpak-1.12.2.drv-0/flatpak-1.12.2:${PATH} ./tests/make-test-runtime.sh tests/runtime-repo org.test.Platform master "" ""
guix
error: Writing content object: min-free-space-percent '3%' would be exceeded, at least 36.9 kB requested
make[3]: *** [Makefile:7804: tests/runtime-repo] Error 1
make[3]: Leaving directory '/tmp/guix-build-flatpak-1.12.2.drv-0/flatpak-1.12.2'
make[2]: *** [Makefile:7063: check-am] Error 2
make[2]: Leaving directory '/tmp/guix-build-flatpak-1.12.2.drv-0/flatpak-1.12.2'
make[1]: *** [Makefile:6255: check-recursive] Error 1
make[1]: Leaving directory '/tmp/guix-build-flatpak-1.12.2.drv-0/flatpak-1.12.2'
make: *** [Makefile:7067: check] Error 2
error: in phase 'check': uncaught exception:
%exception #<&invoke-error program: "make" arguments: ("check" "TESTS=tests/test-basic.sh tests/test-config.sh testcommon") exit-status: 2 term-signal: #f stop-signal: #f> 
phase `check' failed after 17.2 seconds
command "make" "check" "TESTS=tests/test-basic.sh tests/test-config.sh testcommon" failed with status 2
--8<---------------cut here---------------end--------------->8---

Could you take a look?

Apologies for the extra work!

Thanks,
Ludo’.




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

* [bug#53040] [PATCH] gnu: bubblewrap: Update to 0.5.0.
  2022-01-11 17:52   ` Ludovic Courtès
@ 2022-01-11 21:46     ` kiasoc5--- via Guix-patches via
  2022-01-13 21:55       ` bug#53040: " Ludovic Courtès
  0 siblings, 1 reply; 7+ messages in thread
From: kiasoc5--- via Guix-patches via @ 2022-01-11 21:46 UTC (permalink / raw)
  To: Ludovic Courtès, 53040

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

I rebased the patch onto today's Guix commits, and Flatpak 1.12.1 and 1.12.2 passes the tests on my machine. But I'm currently running Guix on Arch and don't have a Guix system available to test further.

All dependent packages except wpewebkit build successfully. wpewebkit build log complains during cmake configuration that a required package is not found, but it seems unrelated to bubblewrap, and it won't build on master anyways.

Jan 11, 2022, 17:52 by ludo@gnu.org:

> Hi,
>
> kiasoc5@tutanota.com skribis:
>
>> Fixed locale in tests, thanks Ludo for the suggestion via email. Also fixed more test substitutions and simplified inputs.
>>
> >>From f5c56100d62d315c3ed860898998a7c8afc78d50 Mon Sep 17 00:00:00 2001
>
>> From: kiasoc5 <kiasoc5@tutanota.com>
>> Date: Mon, 10 Jan 2022 17:58:35 -0500
>> Subject: [PATCH] gnu: bubblewrap: Update to 0.5.0.
>>
>> * gnu/packages/patches/bubblewrap-fix-locale-in-tests.patch: Add it.
>> * gnu/local.mk (dist_patch_DATA): Add it.
>> * gnu/packages/virtualization.scm (bubblewrap): Update to 0.5.0.
>> [source]: Add patch.
>> [arguments]: Adjust test substitutions.
>> [inputs]: Remove labels.
>> [native-inputs]: Remove labels.
>>
>
> That LGTM.  I tested direct dependents as shown by:
>
> ./pre-inst-env guix graph -M1 -t reverse-package bubblewrap | xdot -f fdp -
>
> Unfortunately, the update breaks flatpak (both 1.12.1 and 1.12.2):
>
> --8<---------------cut here---------------start------------->8---
> make[3]: Nothing to be done for 'tests/org.flatpak.Authenticator.test.service.in'.
> rm -rf tests/runtime-repo
> PATH=/tmp/guix-build-flatpak-1.12.2.drv-0/flatpak-1.12.2:${PATH} ./tests/make-test-runtime.sh tests/runtime-repo org.test.Platform master "" ""
> guix
> error: Writing content object: min-free-space-percent '3%' would be exceeded, at least 36.9 kB requested
> make[3]: *** [Makefile:7804: tests/runtime-repo] Error 1
> make[3]: Leaving directory '/tmp/guix-build-flatpak-1.12.2.drv-0/flatpak-1.12.2'
> make[2]: *** [Makefile:7063: check-am] Error 2
> make[2]: Leaving directory '/tmp/guix-build-flatpak-1.12.2.drv-0/flatpak-1.12.2'
> make[1]: *** [Makefile:6255: check-recursive] Error 1
> make[1]: Leaving directory '/tmp/guix-build-flatpak-1.12.2.drv-0/flatpak-1.12.2'
> make: *** [Makefile:7067: check] Error 2
> error: in phase 'check': uncaught exception:
> %exception #<&invoke-error program: "make" arguments: ("check" "TESTS=tests/test-basic.sh tests/test-config.sh testcommon") exit-status: 2 term-signal: #f stop-signal: #f> 
> phase `check' failed after 17.2 seconds
> command "make" "check" "TESTS=tests/test-basic.sh tests/test-config.sh testcommon" failed with status 2
> --8<---------------cut here---------------end--------------->8---
>
> Could you take a look?
>
> Apologies for the extra work!
>
> Thanks,
> Ludo’.
>


[-- Attachment #2: 0001-gnu-bubblewrap-Update-to-0.5.0.patch --]
[-- Type: text/x-patch, Size: 5930 bytes --]

From dc1d48162f3d9fdc2647cbbd4ed2b8eb57eca08f Mon Sep 17 00:00:00 2001
From: kiasoc5 <kiasoc5@tutanota.com>
Date: Mon, 10 Jan 2022 17:58:35 -0500
Subject: [PATCH] gnu: bubblewrap: Update to 0.5.0.

* gnu/packages/patches/bubblewrap-fix-locale-in-tests.patch: Add it.
* gnu/local.mk (dist_patch_DATA): Add it.
* gnu/packages/virtualization.scm (bubblewrap): Update to 0.5.0.
[source]: Add patch.
[arguments]: Adjust test substitutions.
[inputs]: Remove labels.
[native-inputs]: Remove labels.
---
 gnu/local.mk                                  |  1 +
 .../bubblewrap-fix-locale-in-tests.patch      | 34 +++++++++++++++++++
 gnu/packages/virtualization.scm               | 24 ++++++++-----
 3 files changed, 50 insertions(+), 9 deletions(-)
 create mode 100644 gnu/packages/patches/bubblewrap-fix-locale-in-tests.patch

diff --git a/gnu/local.mk b/gnu/local.mk
index 7c75a1043b..756caeea44 100644
--- a/gnu/local.mk
+++ b/gnu/local.mk
@@ -911,6 +911,7 @@ dist_patch_DATA =						\
   %D%/packages/patches/binutils-mingw-w64-deterministic.patch	\
   %D%/packages/patches/bpftrace-disable-bfd-disasm.patch	\
   %D%/packages/patches/byobu-writable-status.patch		\
+  %D%/packages/patches/bubblewrap-fix-locale-in-tests.patch	\
   %D%/packages/patches/cabal-install-base16-bytestring1.0.patch		\
   %D%/packages/patches/cabal-install-ghc8.10.patch		\
   %D%/packages/patches/cairo-CVE-2018-19876.patch		\
diff --git a/gnu/packages/patches/bubblewrap-fix-locale-in-tests.patch b/gnu/packages/patches/bubblewrap-fix-locale-in-tests.patch
new file mode 100644
index 0000000000..bd5924ef87
--- /dev/null
+++ b/gnu/packages/patches/bubblewrap-fix-locale-in-tests.patch
@@ -0,0 +1,34 @@
+From 9282223de4b511aeda3b7d2caf3810a56a865710 Mon Sep 17 00:00:00 2001
+From: kiasoc5 <kiasoc5@tutanota.com>
+Date: Mon, 10 Jan 2022 14:16:32 -0500
+Subject: [PATCH] Use C locale unconditionally for tests.
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+The ‘en_US.utf8’ locale is available. However, the ‘locale -a’ command won’t list it.
+---
+ tests/libtest-core.sh | 7 +------
+ 1 file changed, 1 insertion(+), 6 deletions(-)
+
+diff --git a/tests/libtest-core.sh b/tests/libtest-core.sh
+index 9632e90..82951dd 100644
+--- a/tests/libtest-core.sh
++++ b/tests/libtest-core.sh
+@@ -41,12 +41,7 @@ assert_not_reached () {
+ #
+ # If we can't find the locale command assume we have support for C.UTF-8
+ # (e.g. musl based systems)
+-if type -p locale >/dev/null; then
+-    export LC_ALL=$(locale -a | grep -iEe '^(C|en_US)\.(UTF-8|utf8)$' | head -n1 || true)
+-    if [ -z "${LC_ALL}" ]; then fatal "Can't find suitable UTF-8 locale"; fi
+-else
+-    export LC_ALL=C.UTF-8
+-fi
++export LC_ALL=en_US.utf8
+ # A GNU extension, used whenever LC_ALL is not C
+ unset LANGUAGE
+ 
+-- 
+2.34.1
+
diff --git a/gnu/packages/virtualization.scm b/gnu/packages/virtualization.scm
index 82cc02b738..cec1bce5f3 100644
--- a/gnu/packages/virtualization.scm
+++ b/gnu/packages/virtualization.scm
@@ -1926,7 +1926,7 @@ (define-public python-vagrant
 (define-public bubblewrap
   (package
     (name "bubblewrap")
-    (version "0.4.1")
+    (version "0.5.0")
     (source (origin
               (method url-fetch)
               (uri (string-append "https://github.com/containers/bubblewrap/"
@@ -1934,7 +1934,8 @@ (define-public bubblewrap
                                   version ".tar.xz"))
               (sha256
                (base32
-                "00ycgi6q2yngh06bnz50wkvar6r2jnjf3j158grhi9k13jdrpimr"))))
+                "0608l2sjwhnb1c0mslah1h6yjvqr17wk60by6i710qwxg4rszz8n"))
+               (patches (search-patches "bubblewrap-fix-locale-in-tests.patch"))))
     (build-system gnu-build-system)
     (arguments
      `(#:phases
@@ -1950,7 +1951,9 @@ (define-public bubblewrap
                (substitute* "tests/test-run.sh"
                  (("/var/tmp") tmp-dir)
                  ;; Tests create a temporary python script, so fix its shebang.
-                 (("/usr/bin/env python") (which "python"))
+                 (("/usr/bin/env python3") (which "python3"))
+                 ;; Tests call /usr/bin/env, so fix its path.
+                 (("/usr/bin/env") (which "env"))
                  ;; Some tests try to access /usr, but that doesn't exist.
                  ;; Give them /gnu instead.
                  (("/usr") "/gnu")
@@ -1959,18 +1962,21 @@ (define-public bubblewrap
                  (("--ro-bind /lib /lib") "--ro-bind /gnu /lib")
                  (("  */bin/bash") (which "bash"))
                  (("/bin/sh") (which "sh"))
-                 (("findmnt") (which "findmnt"))))
+                 (("findmnt") (which "findmnt")))
+               (substitute* "tests/libtest.sh"
+                 (("/var/tmp") tmp-dir)
+                 (("/usr") "/gnu")
+                 (("--ro-bind /bin /bin") "--ro-bind /gnu /bin")
+                 (("--ro-bind /sbin /sbin") "--ro-bind /gnu /sbin")
+                 (("--ro-bind /lib /lib") "--ro-bind /gnu /lib")))
              #t))
          ;; Remove the directory we gave to tests to have a clean package.
          (add-after 'check 'remove-tmp-dir
            (lambda* (#:key outputs #:allow-other-keys)
              (delete-file-recursively (string-append (assoc-ref outputs "out") "/tmp"))
              #t)))))
-    (inputs
-     (list libcap))
-    (native-inputs
-     `(("python" ,python-wrapper)
-       ("util-linux" ,util-linux)))
+    (inputs (list libcap))
+    (native-inputs (list python-wrapper util-linux))
     (home-page "https://github.com/containers/bubblewrap")
     (synopsis "Unprivileged sandboxing tool")
     (description "Bubblewrap is aimed at running applications in a sandbox,

base-commit: 993bc8f06cc0662632618e49f6940d5036479c8b
-- 
2.34.1


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

* [bug#53040] [PATCH] gnu: bubblewrap: Update to 0.5.0.
  2022-01-09 21:50 ` Ludovic Courtès
@ 2022-01-12 16:42   ` Josselin Poiret via Guix-patches via
  0 siblings, 0 replies; 7+ messages in thread
From: Josselin Poiret via Guix-patches via @ 2022-01-12 16:42 UTC (permalink / raw)
  To: Ludovic Courtès, kiasoc5; +Cc: 53040

Hello Ludovic and kiasoc5, 

Ludovic Courtès <ludo@gnu.org> writes:
> The ‘en_US.utf8’ locale is available; however, the ‘locale -a’ command
> won’t list it, for obscure reasons.
>
> I suggest patching libtest-core.sh so that it unconditionally uses
> en_US.utf8 instead of running ‘locale -a’.

I am a bit late to the party, but the official locale name is
en_US.UTF-8.  utf8 is not a registered IANA name.  UTF-8 is converted to
utf8 by glibc internally, but I remember having issues when I had
mistakenly set LC_ALL to en_US.utf8 in the past, so better be safe than
sorry.

-- 
Josselin Poiret




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

* bug#53040: [PATCH] gnu: bubblewrap: Update to 0.5.0.
  2022-01-11 21:46     ` kiasoc5--- via Guix-patches via
@ 2022-01-13 21:55       ` Ludovic Courtès
  0 siblings, 0 replies; 7+ messages in thread
From: Ludovic Courtès @ 2022-01-13 21:55 UTC (permalink / raw)
  To: kiasoc5; +Cc: 53040-done

Hi,

kiasoc5@tutanota.com skribis:

> I rebased the patch onto today's Guix commits, and Flatpak 1.12.1 and 1.12.2 passes the tests on my machine. But I'm currently running Guix on Arch and don't have a Guix system available to test further.

Indeed, I tried on a newer machine and it went fine (the one I was
building on previously is really old and I suspect an odd
hardware-related issue.)

> All dependent packages except wpewebkit build successfully. wpewebkit build log complains during cmake configuration that a required package is not found, but it seems unrelated to bubblewrap, and it won't build on master anyways.

Noted.

Applied, thanks!

Ludo’.




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

end of thread, other threads:[~2022-01-13 21:57 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-01-05 22:54 [bug#53040] [PATCH] gnu: bubblewrap: Update to 0.5.0 kiasoc5--- via Guix-patches via
2022-01-09 21:50 ` Ludovic Courtès
2022-01-12 16:42   ` Josselin Poiret via Guix-patches via
2022-01-10 23:14 ` kiasoc5--- via Guix-patches via
2022-01-11 17:52   ` Ludovic Courtès
2022-01-11 21:46     ` kiasoc5--- via Guix-patches via
2022-01-13 21:55       ` bug#53040: " Ludovic Courtès

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/guix.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.