[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Google
  Web www.spinics.net

Re: Changing the %Setup Macro



On Wed, Feb 4, 2009 at 12:24 AM, Eric Aiken <eric.aiken@xxxxxx> wrote:

I realize it is intentional that the %setup macro extracts files and then chown/chmod's the extracted files.  Is there a way around this?

I need to create an rpm of files (no compile, make install,etc).  There are a large number of files with very disparate owner/group/perms.

Creating a bunch of %file statements to create external file lists with sed's  is not my preference.  If I could only:

tar --atime-preserve --preserve-permissions --same-owner   file.tar

that would quick and easy.

Could I create a macro for chown/chmod to point to echo or some other harmless command within the spec  file and trick rpmbuild?

When i package proprietary appl i execute this script (http://devzero2000.pastebin.com/f16cf0404) for filling the manifest on every target package directory - but it is simple to change it for use with a file list - and in the %file section use

%file -f manifest.list.

This is imho preferable because your solution and the trick that you want work only if you build the package as the root user - a normal user can't in %install set file/dir ownership to other user and this in general is required by the package. And using the root user for build is no good. But IMHO.

hth




_______________________________________________
Rpm-list mailing list
Rpm-list@xxxxxxxxxxxxx
http://lists.rpm.org/mailman/listinfo/rpm-list


_______________________________________________
Rpm-list mailing list
Rpm-list@xxxxxxxxxxxxx
http://lists.rpm.org/mailman/listinfo/rpm-list

[Linux Kernel]     [Red Hat Install]     [PAM]     [Red Hat Watch List]     [Red Hat Development]     [Red Hat]     [Gimp]     [Yosemite News]     [IETF Discussion]