Re: FC4, FC6, F7 what works, and don't

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Aaron Konstam wrote:
> On Wed, 2007-07-18 at 22:54 -0400, Todd Zullinger wrote:
>> It's dangerous to build packages as root.  It's a practice that should
>> not be encouraged.  Build as a regular user (not even as your normal
>> user account, ideally).  To setup the config and dir structure needed
>> to build as a regular user, install the rpmdevtools package and then
>> run (as the user you want to build as):
>>
>> $ rpmdev-setuptree
>>
>> This will create ~/rpmbuild with the needed subdirectories.
> I don't understand this. The last time I ran rpmbuild as root I got
> warnings like: no bbder found using root instead.
> Presumably it will use your user name instead of root if we do the
> rpmbuild you way. When you install the rpm is it the fact that rpm runs
> as root that allows you install anything.
> 
When you build an RPM as a user, there is no danger of an error in
the .spec file messing up your running system. As part of the
packaging process, you can set the owner and permissions of the
files to what ever they need to be, regardless of the user that is
building the package. Also, if you have to be root to build a
package, then there is something wrong with the package.

Remember, you do not want to be replacing files on the normal file
system when you build an RPM. But if the install section does not
work properly with build-root, this can happen. This can lead to
strange problems with the installed files not matching the RPM
database. It can also result in config files being overwritten with
the default file for the new package.

Mikkel
-- 

  Do not meddle in the affairs of dragons,
for thou art crunchy and taste good with Ketchup!

Attachment: signature.asc
Description: OpenPGP digital signature


[Index of Archives]     [Current Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]     [Fedora Docs]

  Powered by Linux