[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: lib/fcntl.in.h fails on AIX 6.1
From: |
Bruno Haible |
Subject: |
Re: lib/fcntl.in.h fails on AIX 6.1 |
Date: |
Fri, 5 Sep 2008 00:50:05 +0200 |
User-agent: |
KMail/1.5.4 |
Albert Chin wrote:
> The patch below would work around this and disable #include_next on this
> platform.
>
> --
> albert chin (address@hidden)
>
> -- snip snip
> diff --git a/m4/include_next.m4 b/m4/include_next.m4
> index 08c63db..f0f947b 100644
> --- a/m4/include_next.m4
> +++ b/m4/include_next.m4
> @@ -30,6 +30,7 @@ AC_DEFUN([gl_INCLUDE_NEXT],
> mkdir conftestd1 conftestd2
> cat <<EOF > conftestd1/conftest.h
> #define DEFINED_IN_CONFTESTD1
> +#include <stdio.h>
> #include_next <conftest.h>
> #ifdef DEFINED_IN_CONFTESTD2
> int foo;
Many thanks! Much appreciated. Applied with some comments, like this:
2008-09-04 Albert Chin <address@hidden>
Bruno Haible <address@hidden>
* m4/include_next.m4 (gl_INCLUDE_NEXT): Add check whether #include_next
also works after #include directives.
*** m4/include_next.m4.orig 2008-09-05 00:46:53.000000000 +0200
--- m4/include_next.m4 2008-09-05 00:44:57.000000000 +0200
***************
*** 1,4 ****
! # include_next.m4 serial 7
dnl Copyright (C) 2006-2008 Free Software Foundation, Inc.
dnl This file is free software; the Free Software Foundation
dnl gives unlimited permission to copy and/or distribute it,
--- 1,4 ----
! # include_next.m4 serial 8
dnl Copyright (C) 2006-2008 Free Software Foundation, Inc.
dnl This file is free software; the Free Software Foundation
dnl gives unlimited permission to copy and/or distribute it,
***************
*** 28,35 ****
--- 28,39 ----
[gl_cv_have_include_next],
[rm -rf conftestd1 conftestd2
mkdir conftestd1 conftestd2
+ dnl The include of <stdio.h> is because IBM C 9.0 on AIX 6.1 supports
+ dnl include_next when used as first preprocessor directive in a file,
+ dnl but not when preceded by another include directive.
cat <<EOF > conftestd1/conftest.h
#define DEFINED_IN_CONFTESTD1
+ #include <stdio.h>
#include_next <conftest.h>
#ifdef DEFINED_IN_CONFTESTD2
int foo;