Building From SRPMs

Matthew Saltzman mjs at ces.clemson.edu
Sun Apr 25 12:20:43 UTC 2004


On Sun, 25 Apr 2004, Michael A. Peters wrote:

> On Sun, 2004-04-25 at 00:26, Tom 'Needs A Hat' Mitchell wrote:
> > On Sat, Apr 24, 2004 at 06:38:11PM -0400, Jwp wrote:
> > ...
> > > > > Should this be done as Root or a Regular user?
> > ...
> > > > Better rpmbuild as an unprivileged user. See i.e.
> > > > http://freshrpms.net/docs/fight/
> > ...
> > >
> > > Thanks Alexander,
> > > But it begs the question, why is it that /usr/src/redhat/* are all owned by
> > > root?  When building from an SRPM as an unprivileged user I do not have the
> > > needed permissions to write to these locations.
> > >
> > > In the meantime I have made /usr/src/redhat/* world writeable and I am
> > > building as a normal user.
> >
> > In general source code should be managed by the system administrator.
>
> Better for source code to be managed by the builder, whether or not he
> is system administrator.
>
> Create a file called ~/.rpmmacros
>
> In that file have the following content:
>
> ----------------------------------------------
> %_topdir                %(/bin/echo $HOME)/rpm
> %_tmppath               %{_topdir}/tmp
> ----------------------------------------------
>
> Then - recreate the /usr/src/redhat directory structure inside ~/rpm
>

I'm surprised to se this thread go this long without anyone mentioning
Michael Fratoni's rpm_environment script.  It sets up a whole build tree
in your home directory, and includes some nice features like organizing
sources into subdirectories by package and keeping the specfiles with the
sources.

http://www.tuxfan.homeip.net:8080/hack.html

-- 
		Matthew Saltzman

Clemson University Math Sciences
mjs AT clemson DOT edu
http://www.math.clemson.edu/~mjs





More information about the fedora-list mailing list