Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 575970

Summary: x11-drivers/xf86-video-intel with sys-libs/glibc-2.23 - .../work/d1672806a5222f00dcc2eb24ccddd03f727f71bc/tools/backlight_helper.c:54:2: error: implicit declaration of function ‘major’ [-Werror=implicit-function-declaration]
Product: Gentoo Linux Reporter: Franz Trischberger <franz.trischberger>
Component: [OLD] LibraryAssignee: Gentoo X packagers <x11>
Status: RESOLVED FIXED    
Severity: normal CC: floppym, ganellon, karl.j.linden, kripton, mark+gentoobugs, phantom4, toralf
Priority: Normal Keywords: PATCH
Version: unspecified   
Hardware: All   
OS: Linux   
URL: https://lists.freedesktop.org/archives/intel-gfx/2016-December/113685.html
Whiteboard:
Package list:
Runtime testing required: ---
Bug Depends on:    
Bug Blocks: 575232    
Attachments: build.log.gz
Include config.h in tools/backlight_helper.c

Description Franz Trischberger 2016-02-29 08:40:27 UTC
Created attachment 426962 [details]
build.log.gz

But IMHO this is not directly due to the removal of sysmacros.h from types.h. They check what to include in the buildsystem, set defines and act according to that. In this case they simply forgot to #include <config.h> in tools/backlight_helper.h
Comment 1 Rémi Cardona (RETIRED) gentoo-dev 2016-02-29 21:01:16 UTC
I'm confused: major(3) on glibc 2.22 says major() comes from sys/types.h. Has that changed with glibc 2.23 ?
Comment 2 Chí-Thanh Christopher Nguyễn gentoo-dev 2016-02-29 23:21:32 UTC
This due to a Gentoo-specific change in glibc-2.23.
Other packages are affected too. See the blocked bug and
https://forums.gentoo.org/viewtopic-t-1039602.html
https://forums.gentoo.org/viewtopic-t-1039604.html
Comment 3 Mike Gilbert gentoo-dev 2016-04-14 01:50:48 UTC
This was (mostly) fixed already upstream.

https://cgit.freedesktop.org/xorg/driver/xf86-video-intel/commit/?id=aa40f990142eb165ee7f60f08e9616bc5bebdebe
Comment 4 Mike Gilbert gentoo-dev 2016-04-14 01:52:15 UTC
Created attachment 430350 [details, diff]
Include config.h in tools/backlight_helper.c

Here's a patch to complete the upstream code fix.
Comment 5 Mike Gilbert gentoo-dev 2016-04-14 18:08:58 UTC
*** Bug 579926 has been marked as a duplicate of this bug. ***
Comment 6 Mike Gilbert gentoo-dev 2016-04-15 22:34:08 UTC
*** Bug 580150 has been marked as a duplicate of this bug. ***
Comment 7 Lars Wendler (Polynomial-C) (RETIRED) gentoo-dev 2016-04-18 08:21:56 UTC
*** Bug 580394 has been marked as a duplicate of this bug. ***
Comment 8 SpanKY gentoo-dev 2016-12-07 05:20:54 UTC
sent your patch upstream and added to Gentoo:
https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=7bfe70d0e1ac379f44661c7b783d482052dfe183