Package: capnproto
Version: 0.7.0-5
Severity: serious
Tags: patch upstream ftbfs
Justification: fails to build from source (but built successfully in the past)

Dear Maintainer,

capnproto 0.7.0-5 failed to build in Ubuntu Focal on s390x:

https://bugs.launchpad.net/ubuntu/+source/capnproto/+bug/1870055

In an upstream issue:

https://github.com/capnproto/capnproto/issues/962

They pointed at a fix:

https://github.com/capnproto/capnproto/pull/761

The attached patch is that fix.



-- System Information:
Debian Release: bullseye/sid
  APT prefers focal-security
  APT policy: (500, 'focal-security'), (500, 'focal')
Architecture: amd64 (x86_64)
Foreign Architectures: i386

Kernel: Linux 5.4.0-21-generic (SMP w/4 CPU cores)
Kernel taint flags: TAINT_PROPRIETARY_MODULE, TAINT_OOT_MODULE
Locale: LANG=pl_PL.UTF-8, LC_CTYPE=pl_PL.UTF-8 (charmap=UTF-8), 
LANGUAGE=pl_PL.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /usr/bin/dash
Init: systemd (via /run/systemd/system)
LSM: AppArmor: enabled

Versions of packages capnproto depends on:
ii  libc6           2.31-0ubuntu6
pn  libcapnp-0.7.0  <none>
ii  libgcc-s1       10-20200324-1ubuntu1
ii  libstdc++6      10-20200324-1ubuntu1

capnproto recommends no packages.

capnproto suggests no packages.
commit ce4dd5a1031ee741c676daaea89ae3d1b19f2bb2
Author: David Renshaw <dwrens...@gmail.com>
Date:   Fri Nov 16 21:23:58 2018 -0500

    initialize anonymous enums in isPlausiblyText() and isPlausiblyJson()

diff --git a/src/capnp/compiler/capnp.c++ b/c++/src/capnp/compiler/capnp.c++
index e39db556..8e8c459b 100644
--- a/src/capnp/compiler/capnp.c++
+++ b/src/capnp/compiler/capnp.c++
@@ -1377,7 +1377,7 @@ private:
   }
 
   Plausibility isPlausiblyText(kj::ArrayPtr<const byte> prefix) {
-    enum { PREAMBLE, COMMENT, BODY } state;
+    enum { PREAMBLE, COMMENT, BODY } state = PREAMBLE;
 
     for (char c: prefix.asChars()) {
       switch (state) {
@@ -1427,7 +1427,7 @@ private:
   }
 
   Plausibility isPlausiblyJson(kj::ArrayPtr<const byte> prefix) {
-    enum { PREAMBLE, COMMENT, BODY } state;
+    enum { PREAMBLE, COMMENT, BODY } state = PREAMBLE;
 
     for (char c: prefix.asChars()) {
       switch (state) {

Reply via email to