FTBFS: [nettle-sys 2.2.0] thread 'main' panicked

Bug #2030886 reported by Andreas Hasenack
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
rust-bindgen (Debian)
Fix Released
Unknown
rust-bindgen (Ubuntu)
Fix Released
Undecided
Andreas Hasenack

Bug Description

https://launchpadlibrarian.net/680819239/buildlog_ubuntu-mantic-amd64.rust-sequoia-ipc_0.28.0-5_BUILDING.txt.gz

Compiling structopt-derive v0.4.18
     Running `CARGO=/usr/bin/cargo CARGO_CRATE_NAME=structopt_derive CARGO_MANIFEST_DIR=/<<PKGBUILDDIR>>/debian/cargo_registry/structopt-derive-0.4.18 CARGO_PKG_AUTHORS='Guillaume Pinot <email address hidden>' CARGO_PKG_DESCRIPTION='Parse command line argument by defining a struct, derive crate.' CARGO_PKG_HOMEPAGE='' CARGO_PKG_LICENSE=Apache-2.0/MIT CARGO_PKG_LICENSE_FILE='' CARGO_PKG_NAME=structopt-derive CARGO_PKG_README='' CARGO_PKG_REPOSITORY='https://github.com/TeXitoi/structopt' CARGO_PKG_RUST_VERSION='' CARGO_PKG_VERSION=0.4.18 CARGO_PKG_VERSION_MAJOR=0 CARGO_PKG_VERSION_MINOR=4 CARGO_PKG_VERSION_PATCH=18 CARGO_PKG_VERSION_PRE='' LD_LIBRARY_PATH='/<<PKGBUILDDIR>>/target/debug/deps:/usr/lib' rustc --crate-name structopt_derive --edition=2018 /<<PKGBUILDDIR>>/debian/cargo_registry/structopt-derive-0.4.18/src/lib.rs --error-format=json --json=diagnostic-rendered-ansi,artifacts,future-incompat --crate-type proc-macro --emit=dep-info,link -C prefer-dynamic -C embed-bitcode=no -C debuginfo=2 -C metadata=a59557f1d82fe6b9 -C extra-filename=-a59557f1d82fe6b9 --out-dir /<<PKGBUILDDIR>>/target/debug/deps -L dependency=/<<PKGBUILDDIR>>/target/debug/deps --extern heck=/<<PKGBUILDDIR>>/target/debug/deps/libheck-6fbcb03ccef27113.rlib --extern proc_macro_error=/<<PKGBUILDDIR>>/target/debug/deps/libproc_macro_error-310fc4fdadfe4057.rlib --extern proc_macro2=/<<PKGBUILDDIR>>/target/debug/deps/libproc_macro2-9c4aedeeff913cdd.rlib --extern quote=/<<PKGBUILDDIR>>/target/debug/deps/libquote-3beb99caf35deab7.rlib --extern syn=/<<PKGBUILDDIR>>/target/debug/deps/libsyn-82cc9f044862844a.rlib --extern proc_macro --cap-lints warn`
warning: unnecessary parentheses around match arm expression
   --> /<<PKGBUILDDIR>>/debian/cargo_registry/structopt-derive-0.4.18/src/parse.rs:177:28
    |
177 | "about" => (Ok(About(name, None))),
    | ^ ^
    |
    = note: `#[warn(unused_parens)]` on by default
help: remove these parentheses
    |
177 - "about" => (Ok(About(name, None))),
177 + "about" => Ok(About(name, None)),
    |

warning: unnecessary parentheses around match arm expression
   --> /<<PKGBUILDDIR>>/debian/cargo_registry/structopt-derive-0.4.18/src/parse.rs:178:29
    |
178 | "author" => (Ok(Author(name, None))),
    | ^ ^
    |
help: remove these parentheses
    |
178 - "author" => (Ok(Author(name, None))),
178 + "author" => Ok(Author(name, None)),
    |

[nettle-sys 2.2.0] thread 'main' panicked at '"aes_ctx_union_(unnamed_at_/usr/include/nettle/aes_h_150_3)" is not a valid Ident', /<<PKGBUILDDIR>>/debian/cargo_registry/proc-macro2-1.0.65/src/fallback.rs:791:9

Revision history for this message
Andreas Hasenack (ahasenack) wrote :

It's actually src:rust-nettle-sys that is failing to build.

affects: rust-sequoia-ipc (Ubuntu) → rust-nettle-sys (Ubuntu)
Revision history for this message
Andreas Hasenack (ahasenack) wrote :
Download full text (6.2 KiB)

Upstream nettle-sys builds fine, but the package from debian doesn't. If I don't apply the debian patches, the build also works fine.

This is the diff between a build with and without the debian patches:

without patches:
    Updating crates.io index
   Compiling libc v0.2.147
   Compiling glob v0.3.1
   Compiling proc-macro2 v1.0.66
   Compiling memchr v2.5.0
   Compiling cfg-if v1.0.0
   Compiling unicode-ident v1.0.11
   Compiling minimal-lexical v0.2.1
   Compiling rustix v0.38.7
   Compiling regex-syntax v0.7.4
   Compiling syn v1.0.109
   Compiling linux-raw-sys v0.4.5
   Compiling bindgen v0.63.0
   Compiling bitflags v2.3.3
   Compiling peeking_take_while v0.1.2
   Compiling shlex v1.1.0
   Compiling fastrand v2.0.0
   Compiling libloading v0.7.4
   Compiling lazy_static v1.4.0
   Compiling rustc-hash v1.1.0
   Compiling bitflags v1.3.2
   Compiling lazycell v1.3.0
   Compiling pkg-config v0.3.27
   Compiling clang-sys v1.6.1
   Compiling nom v7.1.3
   Compiling quote v1.0.32
   Compiling cc v1.0.82
   Compiling tempfile v3.7.1
   Compiling cexpr v0.6.0
   Compiling regex-automata v0.3.6
   Compiling regex v1.9.3
   Compiling nettle-sys v2.2.0 (/home/ubuntu/git/packages/rust-nettle-sys/rust-nettle-sys)
    Finished release [optimized] target(s) in 11.00s

With patches:
    Updating crates.io index
   Compiling libc v0.2.147
   Compiling glob v0.3.1
   Compiling memchr v2.5.0
   Compiling proc-macro2 v1.0.66
   Compiling cfg-if v1.0.0
   Compiling regex-syntax v0.7.4
   Compiling unicode-ident v1.0.11
   Compiling rustix v0.38.7
   Compiling minimal-lexical v0.2.1
   Compiling bitflags v2.3.3
   Compiling linux-raw-sys v0.4.5 ...

Read more...

Revision history for this message
Andreas Hasenack (ahasenack) wrote :

I identified an upstream fix for rust-bindgen which fixes the rust-nettle-sys build:

https://github.com/rust-lang/rust-bindgen/pull/2316

affects: rust-nettle-sys (Ubuntu) → rust-bindgen (Ubuntu)
Revision history for this message
Andreas Hasenack (ahasenack) wrote :

Should be fixed in https://launchpad.net/ubuntu/+source/rust-bindgen/0.60.1-2ubuntu1 which I just uploaded. I also subscribed to the package in debian, so I'll be notified whenever they update it, or apply the patch.

Changed in rust-bindgen (Ubuntu):
assignee: nobody → Andreas Hasenack (ahasenack)
status: New → Fix Committed
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package rust-bindgen - 0.60.1-3ubuntu1

---------------
rust-bindgen (0.60.1-3ubuntu1) mantic; urgency=medium

  * Merge with Debian. Remaining change:
    - Add d/p/fix_handling_of_anonymous_names_in_clang_16.patch: correctly
      detect anonymous items in Clang16 (LP: #2030886)

rust-bindgen (0.60.1-3) unstable; urgency=medium

  * Team upload.
  * Package bindgen 0.60.1 from crates.io using debcargo 2.6.0
  * Add patch for env-logger 0.10

 -- Jeremy Bícha <email address hidden> Fri, 18 Aug 2023 22:16:01 -0400

Changed in rust-bindgen (Ubuntu):
status: Fix Committed → Fix Released
Changed in rust-bindgen (Debian):
status: Unknown → New
Changed in rust-bindgen (Debian):
status: New → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.