Bug 1769304 - glibc: Backport more precise tokenizer for installed headers test
Summary: glibc: Backport more precise tokenizer for installed headers test
Alias: None
Product: Red Hat Enterprise Linux 8
Classification: Red Hat
Component: glibc
Version: 8.2
Hardware: All
OS: Linux
Target Milestone: rc
: 8.0
Assignee: Florian Weimer
QA Contact: qe-baseos-tools-bugs
Depends On:
TreeView+ depends on / blocked
Reported: 2019-11-06 11:01 UTC by Florian Weimer
Modified: 2020-04-28 16:50 UTC (History)
7 users (show)

Fixed In Version: glibc-2.28-89.el8
Doc Type: No Doc Update
Doc Text:
Clone Of:
Last Closed: 2020-04-28 16:50:25 UTC
Type: Bug
Target Upstream Version:

Attachments (Terms of Use)

System ID Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2020:1828 None None None 2020-04-28 16:50:36 UTC

Description Florian Weimer 2019-11-06 11:01:26 UTC
Upstream commit 81c9d43f94870be66146739c6e61df40dc17bb64 was backported into the Red Hat Enterprise Linux 8 kernel tree, adding:

+       KERN_PANIC_PRINT=78, /* ulong: bitmask to print system info on panic */

This results in a misc/check-installed-headers-c test failure:

*** Obsolete types detected:
/usr/include/linux/sysctl.h:    KERN_PANIC_PRINT=78, /* ulong: bitmask to print system info on panic */

In glibc upstream, this was fixed by this commit:

commit 711a322a235d4c8177713f11aa59156603b94aeb
Author: Zack Weinberg <zackw@panix.com>
Date:   Mon Mar 11 10:59:27 2019 -0400

    Use a proper C tokenizer to implement the obsolete typedefs test.
    The test for obsolete typedefs in installed headers was implemented
    using grep, and could therefore get false positives on e.g. “ulong”
    in a comment.  It was also scanning all of the headers included by
    our headers, and therefore testing headers we don’t control, e.g.
    Linux kernel headers.
    This patch splits the obsolete-typedef test from
    scripts/check-installed-headers.sh to a separate program,
    scripts/check-obsolete-constructs.py.  Being implemented in Python,
    it is feasible to make it tokenize C accurately enough to avoid false
    positives on the contents of comments and strings.  It also only
    examines $(headers) in each subdirectory--all the headers we install,
    but not any external dependencies of those headers.  Headers whose
    installed name starts with finclude/ are ignored, on the assumption
    that they contain Fortran. […]

Comment 3 Sergey Kolosov 2020-03-09 18:20:41 UTC
Verified with posix/check-obsolete-construct

Comment 5 errata-xmlrpc 2020-04-28 16:50:25 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.


Note You need to log in before you can comment on or make changes to this bug.