Your message dated Sat, 21 Mar 2026 21:23:00 -0400
with message-id 
<caaajcmzqysvevfjdrsxczp4sn1_5rizr0p2xko61ykd3jwi...@mail.gmail.com>
and subject line Re: repowerd: FTBFS with LTO enabled
has caused the Debian Bug report #1031428,
regarding repowerd: FTBFS with LTO enabled
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact [email protected]
immediately.)


-- 
1031428: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1031428
Debian Bug Tracking System
Contact [email protected] with problems
--- Begin Message ---
Package: repowerd
Version: 2022.01-3
Severity: normal
Tags: patch
User: [email protected]
Usertags: origin-ubuntu lunar ubuntu-patch

Hi Mike,

The repowerd package fails to build from source when LTO is enabled, as seen
in Ubuntu on those archs that use LTO:

[...]
/usr/bin/c++ -g -O2 -ffile-prefix-map=/<<PKGBUILDDIR>>=. -flto=auto 
-ffat-lto-objects -fstack-protector-strong -Wformat -Werror=format-security 
-fdebug-prefix-map=/<<PKGBUILDDIR>>=/usr/src/repowerd-2022.01-3 -Wdate-time 
-D_FORTIFY_SOURCE=2 -g -pthread -std=c++14 -Werror -Wall -Wnon-virtual-dtor 
-Wextra -pedantic -Wl,-Bsymbolic-functions -flto=auto -ffat-lto-objects 
-Wl,-z,relro -Wl,-z,now -rdynamic CMakeFiles/repowerd.dir/main.cpp.o -o 
../bin/repowerd  core/librepowerd-core.a adapters/librepowerd-adapters.a 
librepowerd-default-daemon-config.a core/librepowerd-core.a 
adapters/librepowerd-adapters.a adapters/libsuspend/libsuspend.a 
-L/usr/lib/x86_64-linux-gnu -lgio-2.0 -lgobject-2.0 -lglib-2.0 -lgio-2.0 
-lgobject-2.0 -lglib-2.0 -lgio-2.0 -lgobject-2.0 -lglib-2.0 -lgio-2.0 
-lgobject-2.0 -lglib-2.0 
[...]
In member function ‘__ct ’,
    inlined from ‘__ct ’ at 
/usr/src/repowerd-2022.01-3/src/core/handler_registration.cpp:32:7,
    inlined from ‘__ct ’ at 
/usr/src/repowerd-2022.01-3/src/default_daemon_config.cpp:65:57,
    inlined from ‘register_proximity_handler’ at 
/usr/src/repowerd-2022.01-3/src/default_daemon_config.cpp:116:16:
/usr/include/c++/12/bits/std_function.h:391:17: error: ‘<anonymous>’ may be 
used uninitialized [-Werror=maybe-uninitialized]
  391 |             __x._M_manager(_M_functor, __x._M_functor, __clone_functor);
      |                 ^
[...]

  (https://launchpad.net/ubuntu/+source/repowerd/2022.01-3/+build/24577522)

I have uploaded the attached patch in Ubuntu to fix the build failure there. 
Debian does not yet use LTO by default but it is being discussed, so I'm
upstreaming this patch for your consideration.

Cheers,
-- 
Steve Langasek                   Give me a lever long enough and a Free OS
Debian Developer                   to set it on, and I can move the world.
Ubuntu Developer                                   https://www.debian.org/
[email protected]                                     [email protected]
diff -Nru repowerd-2022.01/debian/rules repowerd-2022.01/debian/rules
--- repowerd-2022.01/debian/rules       2022-07-19 15:23:13.000000000 -0700
+++ repowerd-2022.01/debian/rules       2023-02-16 21:08:12.000000000 -0800
@@ -6,7 +6,7 @@
 
 include /usr/share/dpkg/buildflags.mk
 # see FEATURE AREAS in dpkg-buildflags(1)
-export DEB_BUILD_MAINT_OPTIONS = hardening=+all
+export DEB_BUILD_MAINT_OPTIONS = hardening=+all optimize=-lto
 
 %:
        dh $@

--- End Message ---
--- Begin Message ---
Version: 2023.07-4

--- End Message ---

Reply via email to