(offtopic) RPM build trick (was Re: [Mimedefang] HUGE problem with mimedefang)

Dave O'Neill dmo at roaringpenguin.com
Fri Apr 22 11:31:05 EDT 2005


On Fri, Apr 22, 2005 at 07:59:09AM -0700, Kenneth Porter wrote:
> Or set the ownership on the /usr/src/redhat tree to the mortal that
> normally builds packages, and run "rpmbuild -ta
> mimedefang-2.51.tar.gz". An RPM will appear in a subdirectory of
> /usr/src/redhat/RPMS.

You can avoid the need to do this by using the barely-documented
%_topdir macro.  Create yourself a ~/.rpmmacros file with the following
line:

%_topdir /some/writeable/path

where /some/writeable/path is any location your desired user can create
files (/home/$USER/rpmbuilddir is usually my choice).  Then populate
that path with the bare minimum needed for RPM building:

# mkdir -p /some/writeable/path/{BUILD,RPMS,SOURCES,SPECS,SRPMS}

You should now be able to run 'rpmbuild' as yourself, and your binary
RPMs will appear under /some/writeable/path/RPMS

Cheers,
Dave
-- 
Dave O'Neill <dmo at roaringpenguin.com>    Roaring Penguin Software Inc.
+1 (613) 231-6599 ext. 104               http://www.roaringpenguin.com/
For CanIt technical support, please mail: support at roaringpenguin.com



More information about the MIMEDefang mailing list