View Single Post

   
  #4 (permalink)  
Old 02-19-2008, 09:19 PM
Pawel Kot
 
Posts: n/a
Default Re: being a normal user to build package

Joost Kremers wrote:

>> This approach contradicts the philosophy of never being root when you do
>> not really need to.

>
> no, it doesn't, because you really *do* need to be root in order to make a
> package that has to be installed system-wide. why? because tar retains
> ownership and permissions of files. if you were to create a package as
> user and then install it as root system-wide, the files *and* the
> directories in the package would obtain ownership and permissions of the
> user that created the package.
>
> now, note that if a tar ball (and therefore also in a slackware package)
> contains a file /usr/bin/someprog, it will also list the directories /usr
> and /usr/bin. so if you were to install a package that was created by a
> user system-wide, the directories /usr and /usr/bin would get ownership of
> the user. as a result, those directories would be *writable* for that
> user. which is not what you want.


That's why (among other reasons) the post-install script idea was invented.

pkot
--
p k o t a t b e z s e n s u d o t p l
http://www.gnokii.org/
Reply With Quote