autoconf
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Which header a symbol is declared in (AC_CHECK_DECLS) ?


From: Russ Allbery
Subject: Re: Which header a symbol is declared in (AC_CHECK_DECLS) ?
Date: Mon, 27 Apr 2009 11:16:12 -0700
User-agent: Gnus/5.11 (Gnus v5.11) Emacs/22.3 (gnu/linux)

Konstantin Andreev <address@hidden> writes:

> I have heard that 'string.h' and 'strings.h' are incompatible on some
> systems, and including both may causes problems. So, if I include only
> one of them, I increase portability.

You're well beyond the 10 year portability time horizon here and heading
fast for 20-year-obsolete OSes when worrying about anything related to
strings.h.

Even with that vintage of system, SunOS would handle co-inclusion of
both headers just fine, and it was the primary system that required
strings.h.  Including both has also been recommended in the Autoconf
manual for a long, long time.

I think any system that has problems with including both is going to be
pretty amazingly obscure.

Practically speaking, I suspect that you'll improve portability to
systems that people actually care about by not worrying about strings.h
at all and not even trying to include it.  I think we've now reached the
point where it's more likely that an OS will provide a broken strings.h
out of a misguided sense of backwards compatibility than that someone
will really want to build new software on SunOS.

-- 
Russ Allbery (address@hidden)             <http://www.eyrie.org/~eagle/>




reply via email to

[Prev in Thread] Current Thread [Next in Thread]