Its trying to call the real read() instead of the __wrap_read() even
though --wrap=read was passed to the linker. Seems like the linker is
ignoring --wrap=read if LTO is enabled.

The attached debdiff is a quick fix for Noble. No need to add to lto-
disabled-list, as only the test is building linking with --wrap=read.
But I have not forwarded the bug upstream as I am not sure if this
should be a gcc bug or a bug in mtd-utils. If gcc ignores --wrap=read
with LTO enabled then imho, it should be a gcc bug.

A build with this change can be seen at
https://launchpad.net/~sudipmuk/+archive/ubuntu/mtd-
utils/+build/28026320


** Patch added: "mtd-utils.debdiff"
   
https://bugs.launchpad.net/ubuntu/+source/mtd-utils/+bug/2060214/+attachment/5761652/+files/mtd-utils.debdiff

** Changed in: mtd-utils (Ubuntu)
       Status: New => Confirmed

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/2060214

Title:
  mtd-utils 1:2.1.6-1build1 FTBFS

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/mtd-utils/+bug/2060214/+subscriptions


-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to