From: Nathan F. <nf...@au...> - 2010-01-25 16:26:59
|
Brad Peters wrote: > Nathan Fontenot wrote: >> Brad Peters wrote: >>> These spec file changes allow you to run rpmbuild to build the rpm from >>> source. All >>> you need to do now is provide the tarball with a >>> powerpc-utils-[version].tar.gz name, >>> copy it into /usr/src/packages/SOURCES (or whereever $_topdir is >>> pointing), copy the >>> spec in /usr/src/packages/SPECS, and run: >>> >>>> rpmbuild --ba --target=ppc /usr/src/packages/SPECS/powerpc-utils.spec >>> I guess either way will work, but it seems like a good idea to have >>> rpmbuild do as >>> much of the work as possible. >>> >> Took this for a spin, and this is much nicer than all of the prep work >> I was having to do previously to get a rpm built. >> >> I have one comment on the patch... >> >> (please post patches inline instead of attaching them, this way people >> don't have to cut and paste the patch into their reply to comment on it) >> >> --- powerpc-utils-1.2.2/powerpc-utils.spec.in 2010-01-19 >> 10:18:05.000000000 -0800 >> +++ powerpc-utils.spec.in 2010-01-20 10:43:21.000000000 -0800 >> @@ -7,13 +7,24 @@ Version: %{version} >> Release: %{release} >> License: IBM Common Public License (CPL) >> Group: System Environment >> -Source0: N/A >> -BuildRoot: /tmp/%{name}-buildroot/ >> +Source: powerpc-utils-%{version}.tar.gz >> +BuildRoot: %{name}-buildroot/ >> >> I think this still needs to be /tmp/%{name}-buildroot. In my testing the >> rpm build failed when trying to create /powerpc-utils-buildroot. > > Hi Nathan, > > Huh, normally, rpmbuild will create the specified > directory in /tmp by default, then do an install to $_topdir, or > /usr/src/packages/BUILD/powerpc-utils-1.2.2, in this case. This looks like > a permissions problem, so I'm curious if you built as root, or as a > normal user? I did the build as myself and it attempted to create /powerpc-utils-buildroot. Which failed as it should. -Nathan > > >> + /bin/mkdir /powerpc-utils-buildroot >> /bin/mkdir: cannot create directory `/powerpc-utils-buildroot': >> Permission denied >> error: Bad exit status from /var/tmp/rpm-tmp.38059 (%build) >> >> -Nathan > > |