ACK: [Oneiric] [PATCH 0/1] LP#824377 -- fix relative include files in linux-libc-dev
Tim Gardner
tim.gardner at canonical.com
Fri Sep 16 12:58:29 UTC 2011
On 09/16/2011 06:20 AM, Andy Whitcroft wrote:
> We are seeing a number of FTBSs in Oneiric in userspace packages.
> The common theme is that they use the -I- option with gcc. This changes
> implicit search order for header files, specifically it removes "the same
> directory as the current header" from the search path. This directly
> affects any system header files which include local variants using this
> mechanism. For example unistd.h on x86 includes a 32 or 64 bit variant
> as below:
>
> # ifdef __i386__
> # include "unistd_32.h"
> # else
> # include "unistd_64.h"
> # endif
>
> As the use of -I- is not an unreasonable thing for userspace to do those headers should be corrected to use the appropriate #include<> form as below:
>
> # ifdef __i386__
> # include<asm/unistd_32.h>
> # else
> # include<asm/unistd_64.h>
> # endif
>
> As this is un unbounded problem, any number of headers might use this idom
> at any time I have modified the header file generation phase to substitute
> in the appropriate path.
>
> Proposing for Oneiric.
>
> -apw
>
> Andy Whitcroft (1):
> UBUNTU: SAUCE: headers_install: fix #include "..." usage for
> userspace
>
> scripts/Makefile.headersinst | 4 ++--
> scripts/headers_install.pl | 8 +++++++-
> 2 files changed, 9 insertions(+), 3 deletions(-)
>
Good catch. Have you noticed other instances of this form of relative
include path that are creeping into the kernel headers? Seems like a
worthy upstream patch.
Acked-by: Tim Gardner <tim.gardner at canonical.com>
--
Tim Gardner tim.gardner at canonical.com
More information about the kernel-team
mailing list