Subject: Re: autoconf AC_PATH_PROGS question
To: None <tech-pkg@netbsd.org>
From: Joerg Sonnenberger <joerg@britannica.bec.de>
List: tech-pkg
Date: 11/16/2006 00:12:52
On Wed, Nov 15, 2006 at 11:58:58PM +0100, Manuel Bouyer wrote:
> On Wed, Nov 15, 2006 at 08:10:46PM +0100, Joerg Sonnenberger wrote:
> > On Wed, Nov 15, 2006 at 07:43:24PM +0100, Manuel Bouyer wrote:
> > > I have a configure.in which does:
> > > AC_PATH_PROGS(SHUTDOWN, shutdown shutdown.bsd, no)
> > 
> > Can't you just overwrite SHUTDOWN by hand? Either via CONFIGURE_ARGS or
> > CONFIGURE_ENV.
> 
> I could, but then it may not't find shutdown on non-netbsd systems ...

Which system does *not* provide /sbin/shutdown? Let's ignore obscure
"Just for the sake of it" Linux distros -- isn't that the standard
location in both BSD and SysV?

Otherwise:
.if exists(/sbin/shutdown)
CONFIGURE_ENV+=	SHUTDOWN=/sbin/shutdown
.endif

should do the trick.

Joerg