----- Original Message ----- > From: "Andrew Dorozhkin" <glukensoft@xxxxxxxxx> > To: "CentOS mailing list" <centos@xxxxxxxxxx> > Sent: Monday, September 12, 2011 11:39:44 AM > Subject: Re: trouble building an rpm > > 12.09.2011 20:00, Jon Detert wrote: > > i'm a newbie at building rpms. I made a few rpms years ago, but > > can't now make one on Centos 5. > > > > In /usr/local/rpmbuild, there are 5 subdirs: BUILD RPMS SOURCES > > SPECS SRPMS tmp > > > > When I type: rpmbuild -ba > > /usr/local/rpmbuild/SPECS/centos-release-cr-ihc.spec > > > > I get 'file not found' errors, for paths in > > /usr/local/rpmbuild/tmp: > > error: File not found: -- snip -- > > my spec file is > > /usr/local/rpmbuild/SPECS/centos-release-cr-ihc.spec > > the contents of which are: > > Summary: Package to set up IHC use of the centos-cr repository -- snip -- > > %build > > %install > > install -m 0755 -d /etc/yum.repos.d > > install -m 0755 etc/yum.repos.d/CentOS-cr.repo -- snip -- > Directory > /etc/yum.repos.d > and file > /etc/yum.repos.d/CentOS-cr.repo > need to be installed into $RPM_BUILD_ROOT and not into actual / > during > the %install phase. > > Try something like this: > > %install > install -m 0755 -d $RPM_BUILD_ROOT/etc/yum.repos.d > install -m 0755 etc/yum.repos.d/CentOS-cr.repo > $RPM_BUILD_ROOT/etc/yum.repos.d Thanks! That was the problem, and your solution worked. Regards, Jon _______________________________________________ CentOS mailing list CentOS@xxxxxxxxxx http://lists.centos.org/mailman/listinfo/centos