Tim Rice tim at
Wed Dec 19 08:14:56 EST 2012

On Tue, 18 Dec 2012, Darren Tucker wrote:

> On Mon, Dec 17, 2012 at 03:22:22PM -0500, hays wrote:
> > Got this building portable openssh on os x 10.8.2, reporting as requested.
> > 
> > checking for sandbox_init... yes
> > checking sandbox.h usability... no
> > checking sandbox.h presence... yes
> > configure: WARNING: sandbox.h: present but cannot be compiled
> could you please take a look in config.log and see what the actual error
> message is?  it'll be a compile error before the error above, but in
> between that there'll be lots of #defines and configure settings.
> thanks.

I had a look at this on my Lion box.
In file included from conftest.c:101:
/usr/include/sandbox.h:98:29: error: sandbox/private.h: No such file or directory

Indeed sandbox/private.h does not exist.

The offending code looks like this
#include <sandbox/private.h>

Now we're not defining __APPLE_API_PRIVATE anywhere.

"gcc -E -dM - < /dev/null" doesn't show __APPLE_API_PRIVATE

Digging deeper, I find it is defined in sys/appleapiopts.h
that sys/types.h pulls in.

and __APPLE_API_OBSOLETE) are guarded with a
so if we want to quiet down that warning we could define
__APPLE_API_STRICT_CONFORMANCE before testing for sandbox.h

Tim Rice				Multitalents
tim at

More information about the openssh-unix-dev mailing list