[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Location of declarations in Linux vs FreeBSD, etc.
From: |
Philip Kovacs |
Subject: |
Re: Location of declarations in Linux vs FreeBSD, etc. |
Date: |
Mon, 5 Mar 2007 16:47:45 -0500 |
User-agent: |
Mutt/1.5.13 (2006-08-11) |
* Ralf Wildenhues <address@hidden> [2007-03-05 20:27:31 +0100]:
> The next more complicated case is with conflicting header files.
> In that case I guess you should write a special test. You can
> use AC_COMPILE_IFELSE for general compile tests, and AC_CHECK_DECL
> to find out if a symbol is declared. You'll have to work around
> the caching though if it really depends only on the set of included
> headers (e.g., by unsetting the cache variable before the test).
>
Yes, I tried a few tests using this approach and I can, with some effort,
create definitions such as DAEMON_IN_STDLIB or DAEMON_IN_UNISTD, etc.
I'm convinced now this method is overly complex and rather brittle....
I think the thing to do is a) include both headers and be done with it or
b) code a small daemon function myself given that some unices may not have it.
Thanks for your response.
Phil
pgpSgpoRfo2rR.pgp
Description: PGP signature