/usr/lib/aarch64-linux-gnu/libprotobuf.a’ generated with LTO version 9.2 instead of the expected 11.0

Bug #1939413 reported by Heinrich Schuchardt
10
This bug affects 1 person
Affects Status Importance Assigned to Milestone
elfutils (Ubuntu)
Undecided
Unassigned
mozc (Ubuntu)
Undecided
Unassigned
protobuf (Ubuntu)
Undecided
Unassigned

Bug Description

When trying to build package mozc for arm64 the following error popped up:

lto1: fatal error: bytecode stream in file ‘/usr/lib/aarch64-linux-gnu/libprotobuf.a’ generated with LTO version 9.2 instead of the expected 11.0

Why does the library contain LTO information at all?

Best regards

Heinrich

tags: added: ftbfs impish
Revision history for this message
Gunnar Hjalmarsson (gunnarhj) wrote :
Revision history for this message
Gunnar Hjalmarsson (gunnarhj) wrote :

Thanks for reporting this, Heinrich! It looks like protobuf needs to be built with gcc-11.

Changed in protobuf (Ubuntu):
assignee: nobody → Gunnar Hjalmarsson (gunnarhj)
status: New → Fix Committed
Changed in mozc (Ubuntu):
status: New → Invalid
Revision history for this message
Matthias Klose (doko) wrote :

rebuilding just hides the issue. need to find out why the lto sections are in the archive.

Matthias Klose (doko)
Changed in protobuf (Ubuntu):
status: Fix Committed → New
assignee: Gunnar Hjalmarsson (gunnarhj) → Matthias Klose (doko)
Revision history for this message
Matthias Klose (doko) wrote :

the real problem here is that the package is not stripped at all on arm64.

Revision history for this message
Matthias Klose (doko) wrote :

correctly stripped on other architectures, also not stripped in hirsute, so not a regression in impish.

tags: removed: ftbfs
tags: added: rls-ii-incoming
Changed in protobuf (Ubuntu):
assignee: Matthias Klose (doko) → nobody
Revision history for this message
Matthias Klose (doko) wrote :

3.12.4-1ubuntu1 using binutils 2.36 OK 3.12.4-1ubuntu2 BAD

Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package protobuf - 3.12.4-1ubuntu3

---------------
protobuf (3.12.4-1ubuntu3) impish; urgency=medium

  * No-change rebuild to build with gcc-11 (LP: #1939413)

 -- Gunnar Hjalmarsson <email address hidden> Thu, 12 Aug 2021 12:38:56 +0200

Changed in protobuf (Ubuntu):
status: New → Fix Released
Revision history for this message
Gunnar Hjalmarsson (gunnarhj) wrote :

While the rebuild allowed for mozc to build on arm64, as Matthias pointed out there is a root cause that remains to be dealt with, so re-opening.

Changed in protobuf (Ubuntu):
status: Fix Released → Triaged
Revision history for this message
dann frazier (dannf) wrote :

The rebuild of protobuf no longer has lto information according to objdump, but the reported version certainly does. The "bad" version was built during hirsute devel, so I took a current hirsute system and systematically downgraded build-deps to the versions in the log of the "bad" build. Turns out, the relevant difference is a couple libs from elfutils: libdw1 and libelf1. If I build protobuf w/ the 0.183-6 versions, I can reproduce the problem. 0.183-8 does not (0.183-7 FTBFS, so could not be tested).

Strangely the delta between elfutils 0.183-6 and 0.183-8 appears innocuous - it all looks like packaging cleanup, no changes to upstream source.

tags: removed: rls-ii-incoming
Revision history for this message
dann frazier (dannf) wrote :

It would be interesting to know if the issue is due to the differences in the toolchain used to build elfutils 0.183-6 and 0.183-8. The build logs show they were 10.2.1-23ubuntu2
 and 11.2.0-1ubuntu2, respectively. If we built 2 copies of 0.183-8 in the same environment, but just varied the different gcc versions, would the problem follow the compiler?

Revision history for this message
Alexandre Erwin Ittner (aittner) wrote :

I was running a few test builds with different combinations of gcc, elfutils and protobuf and trying to make the build fail... but it continues working despite the older elfutils compiled with the newer gcc.

Last check was with protobuf-3.12.4-1ubuntu3 (from jammy, 4 days ago) in an impish 0.185-1build1 and then downgraded to a 0.183-8 built with 11.2.0-7ubuntu2 (from impish), but it still does not trigger the issue despite the mismatches.

I still could not find the reason.

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers