Does setting "destroot.post_args" not include default "destroot.destdir" in the assembled command?

Clemens Lang cal at macports.org
Mon Aug 20 12:52:21 PDT 2012


On Mon, Aug 20, 2012 at 12:41:52PM -0700, Davor Cubranic wrote:
> Based on the MacPorts guide, I assumed that just setting
> "destroot.post_args PREFIX=${prefix}" would still use the default
> value of "destroot.destdir" (i.e., "DESTDIR=${destroot}"), but I found
> the assembled command to be just "make -w install PREFIX=/opt/local",
> with no DESTROOT passed through. In the end, I had to use in the
> Portfile "destroot.post_args DESTDIR=${destroot} PREFIX=${prefix}".
> 
> This seemed redundant, or at least inelegant. Did I miss a better way
> to do this, or was I simply reading too much into the guide?

Apparently the guide is wrong in this case; the default value of
  destroot.post_args
is
  DESTROOT=${desroot}.
I'll fix this shortly.

However, in your case, why don't you just use
  destroot.args PREFIX=${prefix}?
The split into pre_args, args and post_args is there to allow adding
parameters to the destroot arguments _without_ overwriting the defaults,
i.e., exactly the use case you have.

-- 
Clemens Lang



More information about the macports-users mailing list