tags 984224 +patch
thanks
I started off by removing -Werror, IMO -Werror combined with -Wall
is only appropriate for use during development as it is likely to cause
failures wen new compilers are released.
I then ran into a bunch of errors like.
In file included from /usr/include/glib-2.0/glib/glib-typeof.h:39,
from /usr/include/glib-2.0/glib/gatomic.h:28,
from /usr/include/glib-2.0/glib/gthread.h:32,
from /usr/include/glib-2.0/glib/gasyncqueue.h:32,
from /usr/include/glib-2.0/glib.h:32,
from
/lomiri-app-launch-0.0.90/liblomiri-app-launch/lomiri-app-launch.h:20,
from
/lomiri-app-launch-0.0.90/liblomiri-app-launch/application.cpp:21:
/usr/include/c++/10/type_traits:2930:3: error: template with C linkage
2930 | template<typename _Fn, typename... _Args>
| ^~~~~~~~
/lomiri-app-launch-0.0.90/liblomiri-app-launch/application.cpp:20:1: note: âextern
"C"â linkage started here
20 | extern "C" {
|
Which i fixed by changing the header includes to ensure glib.h was included outside of
any extern "C" block.
At this point I realised I was in-fact testing with gcc 10, so I moved from
testing in a raspbian
bookworm-staging environment to a Debian bookworm arm64 environment.
The build then failed with a symbols file error.
- (arch=!alpha !amd64 !hppa !i386 !m68k !mips64el !mipsel !powerpc !ppc64
!ppc64el !riscv64 !s390x !sh4 !x32)_ZN6lomiri10app_launch5AppIDC1ERKS1_@Base
0.0.90
+#MISSING: 0.0.90-8+rpi1# (arch=!alpha !amd64 !hppa !i386 !m68k !mips64el
!mipsel !powerpc !ppc64 !ppc64el !riscv64 !s390x !sh4
!x32)_ZN6lomiri10app_launch5AppIDC1ERKS1_@Base 0.0.90
- (arch=!alpha !amd64 !hppa !i386 !m68k !mips64el !mipsel !powerpc !ppc64
!ppc64el !riscv64 !s390x !sh4 !x32)_ZN6lomiri10app_launch5AppIDC2ERKS1_@Base
0.0.90
+#MISSING: 0.0.90-8+rpi1# (arch=!alpha !amd64 !hppa !i386 !m68k !mips64el
!mipsel !powerpc !ppc64 !ppc64el !riscv64 !s390x !sh4
!x32)_ZN6lomiri10app_launch5AppIDC2ERKS1_@Base 0.0.90
I fed these symbols (with the @Base removed) through a demangler and curiously
they both demangled to the same thing.
lomiri::app_launch::AppID::AppID(lomiri::app_launch::AppID const&)
I can't find any reference to this constructor in the definition of AppID.
Therefore
I think this is an auto-generated copy constructor that may be inlined and
hence not
show up in the symbols depending on compiler optimization. The fact it has
negated
architecture specifiers for a whole load of architectures reinforces this idea.
As
such I marked the symbols as "optional=inline".
A debdiff has been attatched and an upload has been made to raspbian, no intent
to NMU
in Debian.
diff -Nru lomiri-app-launch-0.0.90/debian/changelog
lomiri-app-launch-0.0.90/debian/changelog
--- lomiri-app-launch-0.0.90/debian/changelog 2021-05-23 22:41:04.000000000
+0000
+++ lomiri-app-launch-0.0.90/debian/changelog 2021-11-08 00:26:53.000000000
+0000
@@ -1,3 +1,13 @@
+lomiri-app-launch (0.0.90-8+rpi1) bookworm-staging; urgency=medium
+
+ * Remove -Werror, it breaks the build with gcc-11 (Closes: 984224).
+ * Adjust includes to avoid including glib.h inside extern "C" as
+ this causes build failures.
+ * Mark a couple of symbols that disappeard with gcc-11 as
+ optional=inline
+
+ -- Peter Michael Green <[email protected]> Mon, 08 Nov 2021 00:26:53
+0000
+
lomiri-app-launch (0.0.90-8) unstable; urgency=medium
* debian/control:
diff -Nru lomiri-app-launch-0.0.90/debian/liblomiri-app-launch0.symbols
lomiri-app-launch-0.0.90/debian/liblomiri-app-launch0.symbols
--- lomiri-app-launch-0.0.90/debian/liblomiri-app-launch0.symbols
2021-05-23 22:38:47.000000000 +0000
+++ lomiri-app-launch-0.0.90/debian/liblomiri-app-launch0.symbols
2021-11-08 00:26:53.000000000 +0000
@@ -17,10 +17,10 @@
_ZN6lomiri10app_launch5AppID8discoverERKSt10shared_ptrINS0_8RegistryEERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESE_NS1_15VersionWildcardE@Base
0.0.90
_ZN6lomiri10app_launch5AppID8discoverERKSt10shared_ptrINS0_8RegistryEERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESE_SE_@Base
0.0.90
_ZN6lomiri10app_launch5AppIDC1ENS0_10TypeTaggerINS1_10PackageTagENSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEENS2_INS1_10AppNameTagES9_EENS2_INS1_10VersionTagES9_EE@Base
0.0.90
- (arch=!alpha !amd64 !hppa !i386 !m68k !mips64el !mipsel !powerpc !ppc64
!ppc64el !riscv64 !s390x !sh4 !x32)_ZN6lomiri10app_launch5AppIDC1ERKS1_@Base
0.0.90
+ (optional=inline|arch=!alpha !amd64 !hppa !i386 !m68k !mips64el !mipsel
!powerpc !ppc64 !ppc64el !riscv64 !s390x !sh4
!x32)_ZN6lomiri10app_launch5AppIDC1ERKS1_@Base 0.0.90
_ZN6lomiri10app_launch5AppIDC1Ev@Base 0.0.90
_ZN6lomiri10app_launch5AppIDC2ENS0_10TypeTaggerINS1_10PackageTagENSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEENS2_INS1_10AppNameTagES9_EENS2_INS1_10VersionTagES9_EE@Base
0.0.90
- (arch=!alpha !amd64 !hppa !i386 !m68k !mips64el !mipsel !powerpc !ppc64
!ppc64el !riscv64 !s390x !sh4 !x32)_ZN6lomiri10app_launch5AppIDC2ERKS1_@Base
0.0.90
+ (optional=inline|arch=!alpha !amd64 !hppa !i386 !m68k !mips64el !mipsel
!powerpc !ppc64 !ppc64el !riscv64 !s390x !sh4
!x32)_ZN6lomiri10app_launch5AppIDC2ERKS1_@Base 0.0.90
_ZN6lomiri10app_launch5AppIDC2Ev@Base 0.0.90
_ZN6lomiri10app_launch5AppIDD1Ev@Base 0.0.90
_ZN6lomiri10app_launch5AppIDD2Ev@Base 0.0.90
diff -Nru
lomiri-app-launch-0.0.90/debian/patches/1004-move-system-headers-outside-extern-c.patch
lomiri-app-launch-0.0.90/debian/patches/1004-move-system-headers-outside-extern-c.patch
---
lomiri-app-launch-0.0.90/debian/patches/1004-move-system-headers-outside-extern-c.patch
1970-01-01 00:00:00.000000000 +0000
+++
lomiri-app-launch-0.0.90/debian/patches/1004-move-system-headers-outside-extern-c.patch
2021-11-08 00:26:53.000000000 +0000
@@ -0,0 +1,36 @@
+Description: Move system headers outside extern C.
+ Including some system headers (notablly glib.h) inside extern "C" causes
+ build failure. Since lomiri-app-launch includes glib.h it must be
+ included from outside extern "C" (it already has internal extern "C"
+ for it's own functions).
+Author: Peter Michael Green <[email protected]>
+
+--- lomiri-app-launch-0.0.90.orig/liblomiri-app-launch/application.cpp
++++ lomiri-app-launch-0.0.90/liblomiri-app-launch/application.cpp
+@@ -17,9 +17,7 @@
+ * Ted Gould <[email protected]>
+ */
+
+-extern "C" {
+ #include "lomiri-app-launch.h"
+-}
+
+ #include "application.h"
+ #include "info-watcher.h"
+--- lomiri-app-launch-0.0.90.orig/liblomiri-app-launch/lomiri-app-launch.cpp
++++ lomiri-app-launch-0.0.90/liblomiri-app-launch/lomiri-app-launch.cpp
+@@ -17,13 +17,13 @@
+ * Ted Gould <[email protected]>
+ */
+
+-extern "C" {
+ #include "lomiri-app-launch.h"
+ #include <gio/gio.h>
+ #include <gio/gunixfdlist.h>
+ #include <string.h>
+ #include <fcntl.h>
+ #include <errno.h>
++extern "C" {
+ #pragma GCC diagnostic push
+ #pragma GCC diagnostic ignored "-Wdeprecated-declarations"
+ #include <zeitgeist.h>
diff -Nru lomiri-app-launch-0.0.90/debian/patches/2003-remove-werror.patch
lomiri-app-launch-0.0.90/debian/patches/2003-remove-werror.patch
--- lomiri-app-launch-0.0.90/debian/patches/2003-remove-werror.patch
1970-01-01 00:00:00.000000000 +0000
+++ lomiri-app-launch-0.0.90/debian/patches/2003-remove-werror.patch
2021-11-08 00:26:53.000000000 +0000
@@ -0,0 +1,15 @@
+Description: Remove -Werror, it breaks the build with gcc-11
+Author: Peter Michael Green <[email protected]>
+Bug-Debian: https://bugs.debian.org/984224
+
+--- lomiri-app-launch-0.0.90.orig/CMakeLists.txt
++++ lomiri-app-launch-0.0.90/CMakeLists.txt
+@@ -51,7 +51,7 @@ set(lomiri_app_launch_arch "${LOMIRI_APP
+
+ add_compile_options(
+ # Because we believe in quality
+- -Wall -Werror
++ -Wall
+ -g
+ -pthread
+ )
diff -Nru lomiri-app-launch-0.0.90/debian/patches/series
lomiri-app-launch-0.0.90/debian/patches/series
--- lomiri-app-launch-0.0.90/debian/patches/series 2020-11-17
11:02:46.000000000 +0000
+++ lomiri-app-launch-0.0.90/debian/patches/series 2021-11-08
00:26:53.000000000 +0000
@@ -3,3 +3,5 @@
1001_fix-gir-api-version.patch
1002_typo-fixes.patch
1003_add-missing-keywords-key.patch
+2003-remove-werror.patch
+1004-move-system-headers-outside-extern-c.patch