Fedora Linux Support Community & Resources Center
  #1  
Old 23rd September 2012, 04:24 PM
mackendw Offline
Registered User
 
Join Date: Sep 2012
Location: Cornwall, PEI
Posts: 2
linuxfirefox
rpmbuild packaging question

Hi:

Have an rpm I'm building for an application. The application's makefile has an install target. Inside
it issues a set permissions block that changes some of the executables within the package as root.root
for owner and group and sets a couple of them as setuid.

Given the cardinal rule of not building the package rpm's as root, this block will fail during the %install in the spec.

I've worked around this by passing an option from the make issued in the %install section to the Makefile which gets pushed down to this script and determine if the make install is being done by root or the package creator. If the package creator, don't attempt to set owner/group to root.root.

Is this the usual method?

thx.
W. MacKenzie
Reply With Quote
  #2  
Old 25th September 2012, 04:12 AM
ocratato Offline
Registered User
 
Join Date: Oct 2010
Location: Canberra
Posts: 551
linuxfirefox
Re: rpmbuild packaging question

I've never built a package, but I will need to at the end of my current project, so I had a bit of a look.

Would the %attr macro solve the problem ?
link to doc
Reply With Quote
  #3  
Old 25th September 2012, 10:43 AM
mackendw Offline
Registered User
 
Join Date: Sep 2012
Location: Cornwall, PEI
Posts: 2
windows_7firefox
Re: rpmbuild packaging question

I have the %attr directives for the packaged files.

The source rpm (if/when installed) has an install tag inside which does permissions settings if they chose to install the rpm later and do a make install.

What I'm doing in the package build is not doing the chown / chgrp commands to root as I'm not root during the package build.

The package installs fine and the ownership is being done as correctly.
Reply With Quote
  #4  
Old 25th September 2012, 11:39 AM
Yellowman
Guest
 
Posts: n/a
linuxfirefox
Re: rpmbuild packaging question

Quote:
Originally Posted by mackendw View Post
I have the %attr directives for the packaged files.

The source rpm (if/when installed) has an install tag inside which does permissions settings if they chose to install the rpm later and do a make install.

What I'm doing in the package build is not doing the chown / chgrp commands to root as I'm not root during the package build.

The package installs fine and the ownership is being done as correctly.
%attr is obsolete

https://fedoraproject.org/wiki/Packa...le_Permissions
Reply With Quote
Reply

Tags
packaging, question, rpmbuild

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Question on RPMBUILD chajohari Programming & Packaging 3 23rd November 2010 01:52 PM
RPMBUILD perl packaging problem aks Programming & Packaging 0 13th August 2010 10:55 AM
rpmbuild as user: optimisation flag question a550ee Using Fedora 1 24th August 2006 01:31 PM
rpmbuild question salmankhilji Using Fedora 5 6th January 2005 07:35 AM


Current GMT-time: 03:48 (Friday, 24-05-2013)

TopSubscribe to XML RSS for all Threads in all ForumsFedoraForumDotOrg Archive
logo

All trademarks, and forum posts in this site are property of their respective owner(s).
FedoraForum.org is privately owned and is not directly sponsored by the Fedora Project or Red Hat, Inc.

Privacy Policy | Term of Use | Posting Guidelines | Archive | Contact Us | Founding Members

Powered by vBulletin® Copyright ©2000 - 2012, vBulletin Solutions, Inc.

FedoraForum is Powered by RedHat