Your message dated Mon, 11 May 2020 17:48:33 +0000
with message-id <[email protected]>
and subject line Bug#952415: fixed in android-platform-external-libselinux 
8.1.0+r23-4
has caused the Debian Bug report #952415,
regarding android-platform-external-libselinux: FTBFS against glibc 2.30+
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.)


-- 
952415: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=952415
Debian Bug Tracking System
Contact [email protected] with problems
--- Begin Message ---
Package: android-platform-external-libselinux
Version: 8.1.0+r23-2
Severity: normal
Tags: patch
User: [email protected]
Usertags: origin-ubuntu focal ubuntu-patch

Hi,

This package currently FTBFS against glibc 2.30+ (2.30 is currently in
experimental) because it defines its own gettid(), which conflicts with
the one provided in the newer versions of glibc.

In Ubuntu, the attached patch was applied to achieve the following:

  * Import patch from upstream Git to fix FTBFS against glibc 2.30.

Thanks for considering the patch.

Logan

-- System Information:
Debian Release: bullseye/sid
  APT prefers focal
  APT policy: (500, 'focal')
Architecture: amd64 (x86_64)
Foreign Architectures: i386

Kernel: Linux 5.4.0-14-generic (SMP w/8 CPU cores)
Kernel taint flags: TAINT_PROPRIETARY_MODULE, TAINT_OOT_MODULE
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8), 
LANGUAGE=en_US.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /usr/bin/dash
Init: systemd (via /run/systemd/system)
LSM: AppArmor: enabled
diff -Nru 
android-platform-external-libselinux-8.1.0+r23/debian/patches/0001-libselinux-Do-not-define-gettid-if-glibc-2.30-is-use.patch
 
android-platform-external-libselinux-8.1.0+r23/debian/patches/0001-libselinux-Do-not-define-gettid-if-glibc-2.30-is-use.patch
--- 
android-platform-external-libselinux-8.1.0+r23/debian/patches/0001-libselinux-Do-not-define-gettid-if-glibc-2.30-is-use.patch
       1969-12-31 19:00:00.000000000 -0500
+++ 
android-platform-external-libselinux-8.1.0+r23/debian/patches/0001-libselinux-Do-not-define-gettid-if-glibc-2.30-is-use.patch
       2020-02-23 22:08:04.000000000 -0500
@@ -0,0 +1,56 @@
+From 707e4b8610733b5c9eaac0f00239778f3edb23c2 Mon Sep 17 00:00:00 2001
+From: Petr Lautrbach <[email protected]>
+Date: Mon, 11 Mar 2019 16:00:41 +0100
+Subject: [PATCH] libselinux: Do not define gettid() if glibc >= 2.30 is used
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+Since version 2.30 glibc implements gettid() system call wrapper, see
+https://sourceware.org/bugzilla/show_bug.cgi?id=6399
+
+Fixes:
+cc -O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 
-Wp,-D_GLIBCXX_ASSERTIONS -fexceptions -fstack-protector-strong 
-grecord-gcc-switches -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 
-specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -m64 -mtune=generic 
-fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection 
-I../include -D_GNU_SOURCE  -DNO_ANDROID_BACKEND   -c -o procattr.o procattr.c
+procattr.c:28:14: error: static declaration of ‘gettid’ follows non-static 
declaration
+   28 | static pid_t gettid(void)
+      |              ^~~~~~
+In file included from /usr/include/unistd.h:1170,
+                 from procattr.c:2:
+/usr/include/bits/unistd_ext.h:34:16: note: previous declaration of ‘gettid’ 
was here
+   34 | extern __pid_t gettid (void) __THROW;
+      |                ^~~~~~
+
+Signed-off-by: Petr Lautrbach <[email protected]>
+---
+ libselinux/src/procattr.c | 15 +++++++++++++--
+ 1 file changed, 13 insertions(+), 2 deletions(-)
+
+diff --git a/libselinux/src/procattr.c b/libselinux/src/procattr.c
+index 48dd8aff..c6799ef2 100644
+--- a/libselinux/src/procattr.c
++++ b/libselinux/src/procattr.c
+@@ -22,8 +22,19 @@ static pthread_key_t destructor_key;
+ static int destructor_key_initialized = 0;
+ static __thread char destructor_initialized;
+ 
+-#ifndef __BIONIC__
+-/* Bionic declares this in unistd.h and has a definition for it */
++/* Bionic and glibc >= 2.30 declare gettid() system call wrapper in unistd.h 
and
++ * has a definition for it */
++#ifdef __BIONIC__
++  #define OVERRIDE_GETTID 0
++#elif !defined(__GLIBC_PREREQ)
++  #define OVERRIDE_GETTID 1
++#elif !__GLIBC_PREREQ(2,30)
++  #define OVERRIDE_GETTID 1
++#else
++  #define OVERRIDE_GETTID 0
++#endif
++
++#if OVERRIDE_GETTID
+ static pid_t gettid(void)
+ {
+       return syscall(__NR_gettid);
+-- 
+2.25.0
+
diff -Nru android-platform-external-libselinux-8.1.0+r23/debian/patches/series 
android-platform-external-libselinux-8.1.0+r23/debian/patches/series
--- android-platform-external-libselinux-8.1.0+r23/debian/patches/series        
2018-06-18 08:57:44.000000000 -0400
+++ android-platform-external-libselinux-8.1.0+r23/debian/patches/series        
2020-02-23 22:08:04.000000000 -0500
@@ -1 +1,2 @@
 Fix-header-path
+0001-libselinux-Do-not-define-gettid-if-glibc-2.30-is-use.patch

--- End Message ---
--- Begin Message ---
Source: android-platform-external-libselinux
Source-Version: 8.1.0+r23-4
Done: Roger Shimizu <[email protected]>

We believe that the bug you reported is fixed in the latest version of
android-platform-external-libselinux, which is due to be installed in the 
Debian FTP archive.

A summary of the changes between this version and the previous one is
attached.

Thank you for reporting the bug, which will now be closed.  If you
have further comments please address them to [email protected],
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
Roger Shimizu <[email protected]> (supplier of updated 
android-platform-external-libselinux package)

(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing [email protected])


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA512

Format: 1.8
Date: Tue, 12 May 2020 01:55:05 +0900
Source: android-platform-external-libselinux
Architecture: source
Version: 8.1.0+r23-4
Distribution: unstable
Urgency: medium
Maintainer: Android Tools Maintainers 
<[email protected]>
Changed-By: Roger Shimizu <[email protected]>
Closes: 952415
Changes:
 android-platform-external-libselinux (8.1.0+r23-4) unstable; urgency=medium
 .
   * Team upload.
   * debian/patches: Replace my patch with the one from BTS to fix FTBFS.
     (Closes: #952415)
   * debian/.gitlab-ci.yml: Update to perform CI only on master branch.
Checksums-Sha1:
 c8333713e64d5f95e135c3ae322838e71adac3fe 2701 
android-platform-external-libselinux_8.1.0+r23-4.dsc
 5f3451c233955113d690c1307f6af70e96735d33 6828 
android-platform-external-libselinux_8.1.0+r23-4.debian.tar.xz
 aacee17f69d597641f345bca03f2e61979f18619 5574 
android-platform-external-libselinux_8.1.0+r23-4_source.buildinfo
Checksums-Sha256:
 9fa4602806d7defc8fd2b28f8b877875568b5cce2e8b49fc87b1df9a22c8adc9 2701 
android-platform-external-libselinux_8.1.0+r23-4.dsc
 5c6e9e6d75964daa3c7c6037bf0fa12fcdf9927b4e3bc0441817b8b0f38d9491 6828 
android-platform-external-libselinux_8.1.0+r23-4.debian.tar.xz
 90dd933f8dfae1ad2b48c5482377ff19c96827a01f9d51a8e8e75c69dc63a797 5574 
android-platform-external-libselinux_8.1.0+r23-4_source.buildinfo
Files:
 00aba65496d2f816dd8681b38ba69bdd 2701 libs optional 
android-platform-external-libselinux_8.1.0+r23-4.dsc
 f2dcefcddc62cdb6ee72de5a056e0aa6 6828 libs optional 
android-platform-external-libselinux_8.1.0+r23-4.debian.tar.xz
 cbd6ed6e97d541823d9c73655925d228 5574 libs optional 
android-platform-external-libselinux_8.1.0+r23-4_source.buildinfo

-----BEGIN PGP SIGNATURE-----

iQJEBAEBCgAuFiEECjKtvoA5m+cWOFnspHhrDacDNKgFAl65h3kQHHJvc2hAZGVi
aWFuLm9yZwAKCRCkeGsNpwM0qCkZD/9ShSutYGyFB2gIlQ1oqGjKn++Y/OGmJYjf
pbisktUpAyRC3vCO6AwHvr9lrxojhnLqQTDe5HtVdZplHX7cm0hnj6bZ7l1PFogl
2zFDS+Ai/bF2vjpBsAcMMnbvaUcpGAwhi/Wgn/ihxDqsigmcOXhuhcKVJkoW3KEe
VJgzk6VXEkMjfIDsb2ZiFROoHbVdtb4yOndItC5+pRzMH9p3vfGZ7+J9/2DKvori
jnoeoDFeRSYzuiq9CX+i3fmLbkJ8hQAb75K4y7G7DD1ZwhJriCuztIkX1vqoXJuM
ZfyKxf9K/8AENtyUHK3d3GFXhC9n/cgb2aV06LsTzbTT97FdtsupcH9Xg7w1jOOq
PbQNXgn6c5hLzD17kXJeoBocee/e1tdEbZHPazyTKPLe/I4WcqYDoy/ikYtgtgkK
NwwyNfg5ut8nxy3ymGqFZrCYnXDIaGh72d30EQnMGxP2kC8J11EkPgbdOS2TSJHi
Jfex60vOonOkZG749MHvVT28EklG2T9s7lTa/A10nzIfCeq619d7AM3uBYz65iuj
cMTQs4ItO+2tZrNBS9Zkk2T8It0O3NCi/fADO6OLrfarw4e7RgbBAFJhvy1Doeid
5I/RCpDZzk40tFURQ9fHA0HLnAxpUR1ji4S/frO7xdTBarU5YNS6tPU8U+JuUNir
778Z79MlbQ==
=W8vK
-----END PGP SIGNATURE-----

--- End Message ---

Reply via email to