[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: configure can not determin 'HAVE_LIMITS'
From: |
Steven Woody |
Subject: |
Re: configure can not determin 'HAVE_LIMITS' |
Date: |
Thu, 27 Oct 2005 08:29:19 +0800 |
User-agent: |
Gnus/5.110004 (No Gnus v0.4) Emacs/21.4 (gnu/linux) |
Ralf Corsepius <address@hidden> writes:
> On Wed, 2005-10-26 at 21:52 +0800, Steven Woody wrote:
>> Stepan Kasal <address@hidden> writes:
>>
>> > Hello,
>> >
>> > On Tue, Oct 25, 2005 at 10:23:55PM +0800, Steven Woody wrote:
>> >> #ifdef HAVE_LIMITS
>> >
>> > add line
>> >
>> > AC_CHECK_HEADERS([limits])
>> >
>> > to configure.ac (or configure.in).
>> >
>> > HTH,
>> > Stepan Kasal
>>
>> thanks. but still got problem. if i say, AC_CHECK_HEADERS([limits]) as you
>> pointed, the the configure script will complain and the HAVE_LIMITS veriable
>> would't be set because my system (Linux) only get limits.h instead of
>> 'limits'.
>>
>> so to make 'configure' happy, i changed to AC_CHECK_HEADERS([limits.h]), this
>> time, 'configure' feels happy and HAVE_LIMITS_H is set properly. but the
>> third-party headers used in my project requires a HAVE_LIMITS that is still
>> not
>> set.
>>
>> my current solution is add the below line into 'config.h.in':
>>
>> #define HAVE_LIMITS 1
>>
>> but i think this is not a decent way. any thinking?
>
> You seem to be confused and are outsmarting yourself ;)
>
> limits.h is a POSIX header. On linux it is supplied by GCC.
>
> So if you want to check for "limits", you should use
> AC_CHECK_HEADERS([limits])
>
but could you explain why AC_CHECK_HEADERS([limits]) failed but
AC_CHECK_HEADERS([limits.h]) success?
> If this fails, something else is broken and you will have to
> investigate. It could be a bug inside of "limits", it could be problem
> elsewhere inside of your configure script, or could be a problem with
> your include paths.
>