On Thu, 14 Jun 2007 10:13:19 +0400 "Andrew Pantyukhin" <[EMAIL PROTECTED]>
wrote:
> > # Configure script is written in perl
> > USE_PERL5_BUILD=yes
> > @@ -46,5 +48,9 @@
> > @${STRIP_CMD} ${PREFIX}/lib/inspircd/modules/*.so
> > @${STRIP_CMD} ${PREFIX}/lib/inspircd/*.so
> > @${STRIP_CMD} ${PREFIX}/bin/inspircd
> > +.for FILE in censor conf filter helpop motd quotes rules
> > + @${TEST} -f ${PREFIX}/etc/inspircd/inspircd.${FILE} || \
> > + ${CP} ${PREFIX}/etc/inspircd/inspircd.${FILE}.example
> > ${PREFIX}/etc/inspircd/inspircd.${FILE}
> > +.endfor
>
> We don't use this type of conditional in ports. It fails
> with non-zero status. Instead you should use if;then;fi,
> which always exits 0.
FWIW (ignoring the content), this syntax is better than 'if'.
As you say, 'if' always succeeds, however 'x || y' will
succeed if x, otherwise will run y, returning the result
to make.
Above, copy failures fail as expected. If 'if' were used
they would not (unless you use 'set -e; if ...').
--
Brian Somers <[EMAIL PROTECTED]>
Don't _EVER_ lose your sense of humour ! <[EMAIL PROTECTED]>
_______________________________________________
[email protected] mailing list
http://lists.freebsd.org/mailman/listinfo/cvs-all
To unsubscribe, send any mail to "[EMAIL PROTECTED]"