GNU bug report logs - #63526
hubbub build failure when doing guix package -u

Previous Next

Package: guix;

Reported by: Andy Tai <atai <at> atai.org>

Date: Mon, 15 May 2023 19:26:01 UTC

Severity: normal

Done: Andreas Enge <andreas <at> enge.fr>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 63526 in the body.
You can then email your comments to 63526 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-guix <at> gnu.org:
bug#63526; Package guix. (Mon, 15 May 2023 19:26:01 GMT) Full text and rfc822 format available.

Acknowledgement sent to Andy Tai <atai <at> atai.org>:
New bug report received and forwarded. Copy sent to bug-guix <at> gnu.org. (Mon, 15 May 2023 19:26:01 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Andy Tai <atai <at> atai.org>
To: bug-guix <at> gnu.org
Subject: hubbub build failure when doing guix package -u
Date: Mon, 15 May 2023 12:24:24 -0700
key lines:

COMPILE: test/tokeniser2.c
 COMPILE: test/tokeniser3.c
 COMPILE: test/tree.c
 COMPILE: test/tree2.c
 COMPILE: test/tree-buf.c
test/tokeniser2.c: In function ‘token_handler’:
test/tokeniser2.c:444:46: error: ‘t.data.character.ptr’ may be used
uninitialized [-Werror=maybe-uninitialized]
  444 |                         t.data.character.ptr += len;
      |                                              ^~
test/tokeniser2.c:441:38: note: ‘t’ declared here
  441 |                         hubbub_token t;
      |                                      ^
test/tokeniser2.c:445:46: error: ‘t.data.character.len’ may be used
uninitialized [-Werror=maybe-uninitialized]
  445 |                         t.data.character.len -= len;
      |                                              ^~
test/tokeniser2.c:441:38: note: ‘t’ declared here
  441 |                         hubbub_token t;
      |                                      ^
test/tokeniser3.c: In function ‘token_handler’:
test/tokeniser3.c:453:46: error: ‘t.data.character.ptr’ may be used
uninitialized [-Werror=maybe-uninitialized]
  453 |                         t.data.character.ptr += len;
      |                                              ^~
test/tokeniser3.c:450:38: note: ‘t’ declared here
  450 |                         hubbub_token t;
      |                                      ^
test/tokeniser3.c:454:46: error: ‘t.data.character.len’ may be used
uninitialized [-Werror=maybe-uninitialized]
  454 |                         t.data.character.len -= len;
      |                                              ^~
test/tokeniser3.c:450:38: note: ‘t’ declared here
  450 |                         hubbub_token t;
      |                                      ^
    LINK: build-x86_64-unknown-linux-gnu-x86_64-unknown-linux-gnu-release-lib-shared/test_entities
    LINK: build-x86_64-unknown-linux-gnu-x86_64-unknown-linux-gnu-release-lib-shared/test_csdetect
    LINK: build-x86_64-unknown-linux-gnu-x86_64-unknown-linux-gnu-release-lib-shared/test_tokeniser
    LINK: build-x86_64-unknown-linux-gnu-x86_64-unknown-linux-gnu-release-lib-shared/test_parser
cc1: all warnings being treated as errors
make: *** [/gnu/store/3jqaqf59ra550lk7hvpgpg8l5krxizra-netsurf-buildsystem-1.9/share/netsurf-buildsystem/makefiles/Makefile.top:631:
build-x86_64-unknown-linux-gnu-x86_64-unknown-linux-gnu-release-lib-shared/test_tokeniser2.o]
Error 1
make: *** Waiting for unfinished jobs....
cc1: all warnings being treated as errors
make: *** [/gnu/store/3jqaqf59ra550lk7hvpgpg8l5krxizra-netsurf-buildsystem-1.9/share/netsurf-buildsystem/makefiles/Makefile.top:631:
build-x86_64-unknown-linux-gnu-x86_64-unknown-linux-gnu-release-lib-shared/test_tokeniser3.o]
Error 1

Test suite failed, dumping logs.
error: in phase 'check': uncaught exception:
%exception #<&invoke-error program: "make" arguments: ("test" "-j"
"31" "COMPONENT_TYPE=lib-shared" "CC=gcc" "BUILD_CC=gcc"
"PREFIX=/gnu/store/7fn6jxg1vpadm8rpa8rzbwqgipxlwync-hubbub-0.3.7"
"NSSHARED=/gnu/store/3jqaqf59ra550lk7hvpgpg8l5krxizra-netsurf-buildsystem-1.9/share/netsurf-buildsystem")
exit-status: 2 term-signal: #f stop-signal: #f>
phase `check' failed after 0.2 seconds
command "make" "test" "-j" "31" "COMPONENT_TYPE=lib-shared" "CC=gcc"
"BUILD_CC=gcc" "PREFIX=/gnu/store/7fn6jxg1vpadm8rpa8rzbwqgipxlwync-hubbub-0.3.7"
"NSSHARED=/gnu/store/3jqaqf59ra550lk7hvpgpg8l5krxizra-netsurf-buildsystem-1.9/share/netsurf-buildsystem"
failed with status 2




Information forwarded to bug-guix <at> gnu.org:
bug#63526; Package guix. (Mon, 22 May 2023 06:46:02 GMT) Full text and rfc822 format available.

Message #8 received at 63526 <at> debbugs.gnu.org (full text, mbox):

From: Andy Tai <atai <at> atai.org>
To: 63526 <at> debbugs.gnu.org
Cc: Andy Tai <atai <at> atai.org>
Subject: [PATCH] gnu: hubbub: Disable building tests
Date: Sun, 21 May 2023 23:44:59 -0700
Fix for https://debbugs.gnu.org/cgi/bugreport.cgi?bug=63526

* gnu/packages/web.scm (hubbub): [arguments] (tests): Set to #f to disable test build
---
 gnu/packages/web.scm | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/gnu/packages/web.scm b/gnu/packages/web.scm
index fe52f673e2..203e3283cf 100644
--- a/gnu/packages/web.scm
+++ b/gnu/packages/web.scm
@@ -5252,7 +5252,9 @@ (define-public hubbub
            perl))
     (propagated-inputs
      (list libparserutils)) ;for libhubbub.pc
-    (arguments netsurf-buildsystem-arguments)
+    (arguments
+     `(#:tests? #f  ;build error in building tests with gcc 11; skip for now
+       ,@netsurf-buildsystem-arguments))
     (home-page "https://www.netsurf-browser.org/projects/hubbub/")
     (synopsis "HTML5 compliant parsing library")
     (description

base-commit: 3abcf1663b86bc075e29563140698d8bfae44992
-- 
2.40.1





Information forwarded to bug-guix <at> gnu.org:
bug#63526; Package guix. (Thu, 25 May 2023 13:04:02 GMT) Full text and rfc822 format available.

Message #11 received at 63526 <at> debbugs.gnu.org (full text, mbox):

From: Greg Hogan <code <at> greghogan.com>
To: Andy Tai <atai <at> atai.org>
Cc: 63526 <at> debbugs.gnu.org
Subject: Re: bug#63526: [PATCH] gnu: hubbub: Disable building tests
Date: Thu, 25 May 2023 09:02:44 -0400
On Mon, May 22, 2023 at 2:46 AM Andy Tai <atai <at> atai.org> wrote:
>
> Fix for https://debbugs.gnu.org/cgi/bugreport.cgi?bug=63526
>
> * gnu/packages/web.scm (hubbub): [arguments] (tests): Set to #f to disable test build
> ---
>  gnu/packages/web.scm | 4 +++-
>  1 file changed, 3 insertions(+), 1 deletion(-)
>
> diff --git a/gnu/packages/web.scm b/gnu/packages/web.scm
> index fe52f673e2..203e3283cf 100644
> --- a/gnu/packages/web.scm
> +++ b/gnu/packages/web.scm
> @@ -5252,7 +5252,9 @@ (define-public hubbub
>             perl))
>      (propagated-inputs
>       (list libparserutils)) ;for libhubbub.pc
> -    (arguments netsurf-buildsystem-arguments)
> +    (arguments
> +     `(#:tests? #f  ;build error in building tests with gcc 11; skip for now
> +       ,@netsurf-buildsystem-arguments))
>      (home-page "https://www.netsurf-browser.org/projects/hubbub/")
>      (synopsis "HTML5 compliant parsing library")
>      (description
>
> base-commit: 3abcf1663b86bc075e29563140698d8bfae44992
> --
> 2.40.1

Hi Andy,

Disabling tests should be a last resort, especially without a process
to evaluate re-enabling tests in the future.

Based on the error, can we instead add
"-Wno-error=maybe-uninitialized" to the configure-flags?

Greg




Information forwarded to bug-guix <at> gnu.org:
bug#63526; Package guix. (Thu, 25 May 2023 13:36:02 GMT) Full text and rfc822 format available.

Message #14 received at 63526 <at> debbugs.gnu.org (full text, mbox):

From: Bruno Victal <mirai <at> makinata.eu>
To: Greg Hogan <code <at> greghogan.com>, Andy Tai <atai <at> atai.org>
Cc: 63526 <at> debbugs.gnu.org
Subject: Re: bug#63526: [PATCH] gnu: hubbub: Disable building tests
Date: Thu, 25 May 2023 14:35:17 +0100
On 2023-05-25 14:02, Greg Hogan wrote:
> Hi Andy,
> 
> Disabling tests should be a last resort, especially without a process
> to evaluate re-enabling tests in the future.

I concur.

A test failure, unless it is caused by things such as “requiring
network access” or is expected due to guix specifics should be
considered a problem with the package. (if tests are disabled simply
because they happen to fail without doing any investigation, why have
tests at all?)

> Based on the error, can we instead add
> "-Wno-error=maybe-uninitialized" to the configure-flags?

I'd report this upstream first, it can be the case that the error
(which is being flagged by the compiler) is unmasking a real bug
upstream.


-- 
Furthermore, I consider that nonfree software must be eradicated.

Cheers,
Bruno.





Information forwarded to bug-guix <at> gnu.org:
bug#63526; Package guix. (Thu, 25 May 2023 17:56:02 GMT) Full text and rfc822 format available.

Message #17 received at 63526 <at> debbugs.gnu.org (full text, mbox):

From: Andy Tai <atai <at> atai.org>
To: Bruno Victal <mirai <at> makinata.eu>
Cc: 63526 <at> debbugs.gnu.org, Greg Hogan <code <at> greghogan.com>
Subject: Re: bug#63526: [PATCH] gnu: hubbub: Disable building tests
Date: Thu, 25 May 2023 10:54:37 -0700
Will do. Thanks

On Thu, May 25, 2023 at 6:35 AM Bruno Victal <mirai <at> makinata.eu> wrote:
>
> On 2023-05-25 14:02, Greg Hogan wrote:

>
> > Based on the error, can we instead add
> > "-Wno-error=maybe-uninitialized" to the configure-flags?
>
> I'd report this upstream first, it can be the case that the error
> (which is being flagged by the compiler) is unmasking a real bug
> upstream.
>




Information forwarded to bug-guix <at> gnu.org:
bug#63526; Package guix. (Sat, 27 May 2023 07:30:02 GMT) Full text and rfc822 format available.

Message #20 received at 63526 <at> debbugs.gnu.org (full text, mbox):

From: Andy Tai <atai <at> atai.org>
To: 63526 <at> debbugs.gnu.org,
	code <at> greghogan.com,
	mirai <at> makinata.eu
Cc: Andy Tai <atai <at> atai.org>
Subject: [PATCH v2] gnu (hubbub): Fix build
Date: Sat, 27 May 2023 00:29:04 -0700
Fix for https://debbugs.gnu.org/cgi/bugreport.cgi?bug=63526

* gnu/packages/web.scm (hubbub): [source](patches): Add patch to fix build.
* gnu/packages/patches/hubbub-prevent-Werror-maybe-uninitialized-build-failure-wit.patch: New file
* gnu/local.mk  (dist_patch_DATA): Add it.
---
 gnu/local.mk                                  |  2 +
 ...aybe-uninitialized-build-failure-wit.patch | 40 +++++++++++++++++++
 gnu/packages/web.scm                          |  4 +-
 3 files changed, 45 insertions(+), 1 deletion(-)
 create mode 100644 gnu/packages/patches/hubbub-prevent-Werror-maybe-uninitialized-build-failure-wit.patch

diff --git a/gnu/local.mk b/gnu/local.mk
index 18e8235140..e2b42ca676 100644
--- a/gnu/local.mk
+++ b/gnu/local.mk
@@ -58,6 +58,7 @@
 # Copyright © 2022 jgart <jgart <at> dismail.de>
 # Copyright © 2023 Zheng Junjie <873216071 <at> qq.com>
 # Copyright © 2023 Ivana Drazovic <iv.dra <at> hotmail.com>
+# Copyright © 2023 Andy Tai <atai <at> atai.org>
 #
 # This file is part of GNU Guix.
 #
@@ -1349,6 +1350,7 @@ dist_patch_DATA =						\
   %D%/packages/patches/http-parser-CVE-2020-8287.patch		\
   %D%/packages/patches/htslib-for-stringtie.patch		\
   %D%/packages/patches/hubbub-sort-entities.patch		\
+  %D%/packages/patches/hubbub-prevent-Werror-maybe-uninitialized-build-failure-wit.patch \
   %D%/packages/patches/hueplusplus-mbedtls.patch		\
   %D%/packages/patches/hurd-add-without-rump-configure-option.patch \
   %D%/packages/patches/hurd-fix-types-of-read-write-and-readables-methods-2.patch \
diff --git a/gnu/packages/patches/hubbub-prevent-Werror-maybe-uninitialized-build-failure-wit.patch b/gnu/packages/patches/hubbub-prevent-Werror-maybe-uninitialized-build-failure-wit.patch
new file mode 100644
index 0000000000..6f289a770e
--- /dev/null
+++ b/gnu/packages/patches/hubbub-prevent-Werror-maybe-uninitialized-build-failure-wit.patch
@@ -0,0 +1,40 @@
+From 69d81a8a4d4c223aad67cde0fdf64d64351b9802 Mon Sep 17 00:00:00 2001
+From: Andy Tai <atai <at> atai.org>
+Date: Sat, 27 May 2023 00:01:34 -0700
+Subject: [PATCH] prevent -Werror=maybe-uninitialized build failure with gcc 11
+ when building tests tokeniser2 and tokeniser3
+
+---
+ test/tokeniser2.c | 2 +-
+ test/tokeniser3.c | 2 +-
+ 2 files changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/test/tokeniser2.c b/test/tokeniser2.c
+index c8ab9c0..4caae38 100644
+--- a/test/tokeniser2.c
++++ b/test/tokeniser2.c
+@@ -438,7 +438,7 @@ hubbub_error token_handler(const hubbub_token *token, void *pw)
+ 			/* Expected token only contained part of the data
+ 			 * Calculate how much is left, then try again with
+ 			 * the next expected token */
+-			hubbub_token t;
++			hubbub_token t = { 0 };
+ 
+ 			t.type = HUBBUB_TOKEN_CHARACTER;
+ 			t.data.character.ptr += len;
+diff --git a/test/tokeniser3.c b/test/tokeniser3.c
+index e33d018..b3be901 100644
+--- a/test/tokeniser3.c
++++ b/test/tokeniser3.c
+@@ -447,7 +447,7 @@ hubbub_error token_handler(const hubbub_token *token, void *pw)
+ 			/* Expected token only contained part of the data
+ 			 * Calculate how much is left, then try again with
+ 			 * the next expected token */
+-			hubbub_token t;
++			hubbub_token t = { 0 };
+ 
+ 			t.type = HUBBUB_TOKEN_CHARACTER;
+ 			t.data.character.ptr += len;
+-- 
+2.40.1
+
diff --git a/gnu/packages/web.scm b/gnu/packages/web.scm
index 3af4aa0b8d..387ceac058 100644
--- a/gnu/packages/web.scm
+++ b/gnu/packages/web.scm
@@ -5242,7 +5242,9 @@ (define-public hubbub
        (sha256
         (base32
          "1dimfyblmym98qa1b80c5jslv2zk8r44xbdrgrsrw1n9wr9y4yly"))
-       (patches (search-patches "hubbub-sort-entities.patch"))))
+       (patches (search-patches
+         "hubbub-sort-entities.patch"
+         "hubbub-prevent-Werror-maybe-uninitialized-build-failure-wit.patch"))))
     (build-system gnu-build-system)
     (native-inputs
      (list netsurf-buildsystem

base-commit: b96b82bcd4bc24529941ff74a91432481f1a71b5
-- 
2.40.1





Added blocking bug(s) 63592 Request was from Andy Tai <atai <at> atai.org> to control <at> debbugs.gnu.org. (Thu, 08 Jun 2023 02:54:02 GMT) Full text and rfc822 format available.

Removed blocking bug(s) 63592 Request was from Andy Tai <atai <at> atai.org> to control <at> debbugs.gnu.org. (Thu, 08 Jun 2023 03:36:01 GMT) Full text and rfc822 format available.

Added blocking bug(s) 63952 Request was from Andy Tai <atai <at> atai.org> to control <at> debbugs.gnu.org. (Thu, 08 Jun 2023 03:36:01 GMT) Full text and rfc822 format available.

Reply sent to Andreas Enge <andreas <at> enge.fr>:
You have taken responsibility. (Fri, 09 Jun 2023 11:08:01 GMT) Full text and rfc822 format available.

Notification sent to Andy Tai <atai <at> atai.org>:
bug acknowledged by developer. (Fri, 09 Jun 2023 11:08:02 GMT) Full text and rfc822 format available.

Message #31 received at 63526-done <at> debbugs.gnu.org (full text, mbox):

From: Andreas Enge <andreas <at> enge.fr>
To: Andy Tai <atai <at> atai.org>
Cc: guix-devel <at> gnu.org, 63526-done <at> debbugs.gnu.org, 63952-done <at> debbugs.gnu.org
Subject: Re: ping on a build fix for a build failure (main branch)
Date: Fri, 9 Jun 2023 13:07:30 +0200
Hello Andy,

Am Tue, May 30, 2023 at 10:54:20AM -0700 schrieb Andy Tai:
> Hi, following previous comments (thanks) I have submitted a patch to
> correctly fix a build failure due to compiler warnings, instead of
> avoiding not building tests, on this Guix bug issue:
> https://debbugs.gnu.org/cgi/bugreport.cgi?bug=63526
> Please review the patch (which shall be a simple and low risk fix).  Thanks!

I have reworked a bit the punctuation of the commit message, shortened
the patch file name and pushed. By this I am closing the two corresponding
bug reports (it would have been enough to send a second version of the
patch to the first bug).

Did you contact upstream? Looking at the test, it looked wrong before and
after your patch...
if (len < token->data.character.len) {
   hubbub_token t = { 0 };
   t.type = HUBBUB_TOKEN_CHARACTER;
   t.data.character.ptr += len;
   t.data.character.len -= len;
...
Adding to a previously undefined, now 0 pointer .ptr raised a warning
for a reason, I think; and it looks like the t.data maybe should be
token->data. But it is quite possible that this branch is not even
reached by the test.

Andreas





Information forwarded to bug-guix <at> gnu.org:
bug#63526; Package guix. (Fri, 09 Jun 2023 17:30:02 GMT) Full text and rfc822 format available.

Message #34 received at 63526-done <at> debbugs.gnu.org (full text, mbox):

From: Andy Tai <atai <at> atai.org>
To: Andreas Enge <andreas <at> enge.fr>
Cc: guix-devel <at> gnu.org, 63526-done <at> debbugs.gnu.org, 63952-done <at> debbugs.gnu.org
Subject: Re: ping on a build fix for a build failure (main branch)
Date: Fri, 9 Jun 2023 10:28:25 -0700
I did contact upstream, no response

On Fri, Jun 9, 2023 at 4:07 AM Andreas Enge <andreas <at> enge.fr> wrote:
>
> Hello Andy,
>
> Am Tue, May 30, 2023 at 10:54:20AM -0700 schrieb Andy Tai:
> > Hi, following previous comments (thanks) I have submitted a patch to
> > correctly fix a build failure due to compiler warnings, instead of
> > avoiding not building tests, on this Guix bug issue:
> > https://debbugs.gnu.org/cgi/bugreport.cgi?bug=63526
> > Please review the patch (which shall be a simple and low risk fix).  Thanks!
>
> I have reworked a bit the punctuation of the commit message, shortened
> the patch file name and pushed. By this I am closing the two corresponding
> bug reports (it would have been enough to send a second version of the
> patch to the first bug).
>
> Did you contact upstream? Looking at the test, it looked wrong before and
> after your patch...
> if (len < token->data.character.len) {
>    hubbub_token t = { 0 };
>    t.type = HUBBUB_TOKEN_CHARACTER;
>    t.data.character.ptr += len;
>    t.data.character.len -= len;
> ...
> Adding to a previously undefined, now 0 pointer .ptr raised a warning
> for a reason, I think; and it looks like the t.data maybe should be
> token->data. But it is quite possible that this branch is not even
> reached by the test.
>
> Andreas
>


-- 
Andy Tai, atai <at> atai.org, Skype: licheng.tai, Line: andy_tai, WeChat: andytai1010
Year 2023 民國112年
自動的精神力是信仰與覺悟
自動的行為力是勞動與技能




bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Sat, 08 Jul 2023 11:24:04 GMT) Full text and rfc822 format available.

This bug report was last modified 285 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.