$RPM_BUILD_ROOT vs. %buildroot (was: Re: potential candidates for contribution)

Michael Schwendt bugs.michael at gmx.net
Sun Mar 20 20:29:40 UTC 2005


On Sun, 20 Mar 2005 21:47:45 +0200, Ville Skyttä wrote:

> On Sun, 2005-03-20 at 20:13 +0100, Rudolf Kastl wrote:
> > Am Donnerstag, den 17.03.2005, 14:42 +0100 schrieb Michael Schwendt:
> >
> > > [As a side-note, using $RPM_BUILD_ROOT has been particularly dangerous in
> > > a few cases, where it appeared in scriptlets.]
> > 
> > this is a good argument so i might switch to a pure macro style.
> 
> You're missing an important point.  That value expanded doesn't really
> make things much better.  Put $RPM_BUILD_ROOT or %{buildroot} in a %post
> or friends scriptlet and it's a packaging bug anyway, and a potentially
> dangerous one.  Pick your poison.

Right. Basically, it is wasted time to discuss it, since it should occur
*very* rarely. The only difference is, operations below a path prefixed
with an expanded %buildroot, which likely doesn't exist on machines
other than the build system, are harmless, whereas an unassigned
environment variable just drops a prefix from a path and results in
paths into the main filesystem.





More information about the fedora-extras-list mailing list