Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 7 Sep 2013 23:43:42 -0700
From:      Jason Helfman <jgh@FreeBSD.org>
To:        Christian Weisgerber <naddy@mips.inka.de>
Cc:        FreeBSD Ports List <freebsd-ports@freebsd.org>
Subject:   Re: bsd.port.pre.mk vs bsd.port.options.mk
Message-ID:  <CAMuy=%2BiqFsQst-tEYJmNmyih3eXfEGLa2XR3=u2ada=pKDMq4g@mail.gmail.com>
In-Reply-To: <l0g6jl$jf0$1@lorvorc.mips.inka.de>
References:  <l0g6jl$jf0$1@lorvorc.mips.inka.de>

next in thread | previous in thread | raw e-mail | index | archive | help
On Sat, Sep 7, 2013 at 2:42 PM, Christian Weisgerber <naddy@mips.inka.de>wrote:

> I have port that does something like
>
>     .include <bsd.port.pre.mk>
>
>     .if ${ARCH} == ...
>     ...
>     .endif
>
>     .include <bsd.port.post.mk>
>
> A while back somebody submitted a PR asking me to replace bsd.port.pre.mk
> with bsd.port.options.mk, because it also makes ARCH available and
> is far less expensive.
>
> Now, a priori it is not clear to me that including options.mk is
> actually cheaper than pre.mk.  And it seems odd to include options.mk
> but then not use any part of the options framework.  The Porter's
> Handbook explicitly mentions ARCH as one of the variables provided
> by pre.mk.
>
> What's the preferred way to handle this?
>
> --
> Christian "naddy" Weisgerber                          naddy@mips.inka.de
>
>
It is preferred to evaluate ARCH with bsd.port.options.mk.

-jgh



-- 
Jason Helfman          | FreeBSD Committer
jgh@FreeBSD.org     | http://people.freebsd.org/~jgh  | The Power to Serve



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CAMuy=%2BiqFsQst-tEYJmNmyih3eXfEGLa2XR3=u2ada=pKDMq4g>