rpmbuild --root should do what is expected, namely do a chroot into the prefix
before running scripts.
Yes chroot(2) requires root, thank you POSIX. To preserve the mantra "Never
invoke rpmbuild as root" behavior, rpmbuild should drop root privileges, and
switch back to root only when needed.
(aside)
Dropping root privileges until needed is equally wise for rpm installations,
but that is not this RFE.
The root prefix might also need to be prepended to file paths for packages
produced by rpmbuild similar to what is done opening an rpmdb.
--
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/rpm-software-management/rpm/issues/510
_______________________________________________
Rpm-maint mailing list
Rpm-maint@lists.rpm.org
http://lists.rpm.org/mailman/listinfo/rpm-maint