(no subject)
Yuri Pankov
yuri.pankov at gmail.com
Tue Dec 29 11:50:38 UTC 2009
On Tue, Dec 29, 2009 at 02:17:17PM +0300, Eygene Ryabinkin wrote:
> Tue, Dec 29, 2009 at 10:40:02AM +0300, Yuri Pankov wrote:
> > On Tue, Dec 29, 2009 at 01:28:46AM -0600, Scot Hetzel wrote:
> > > dv8t01# make do-check
> > > File /usr/local/etc/rc.d/motd exists
> > > File /usr/local/etc/rc.d/hald doesnt exist
> > >
> > > This Makefile fails due to LOCALBASE is not defined at the time that
> > > the exists check is run.
> >
> > How come that ${DATADIR} (and ${LOCALBASE}) are correctly expanded in
> > ${ECHO_MSG} then?
>
> .if and .for are unrolled and evaluated while parsing the makefile
> and make transforms it to bare "@${ECHO_MSG} ..." lines with the
> content that depends on the if-else-endif evaluation. LOCALBASE
> isn't defined at that time
>
> And targets are executed after the whole Makefile was read, so
> LOCALBASE is here. Actually, the found "/usr/local/etc/rc.d/motd"
> is really an "/etc/rc.d/motd".
> --
> Eygene
> _ ___ _.--. #
> \`.|\..----...-'` `-._.-'_.-'` # Remember that it is hard
> / ' ` , __.--' # to read the on-line manual
> )/' _/ \ `-_, / # while single-stepping the kernel.
> `-'" `"\_ ,_.-;_.-\_ ', fsc/as #
> _.-'_./ {_.' ; / # -- FreeBSD Developers handbook
> {_.-``-' {_/ #
Thanks for explanation. I just wonder how PREFIX is different from
LOCALBASE (i.e., devel/gettext uses .if exists(${PREFIX}/.....) without
including bsd.port.pre.mk).
Yuri
More information about the freebsd-ports
mailing list