From: Jeffrey C. O. <je...@ol...> - 2000-08-15 03:57:35
|
On Tue, Aug 15, 2000 at 11:58:00AM +1000, David Leonard wrote: > > I just commited Build/template.spec which could help someone doing the > rpm packaging. > > I not sure how to build the package without having to first properly > install things. You see, I don't have root access to a linux box so I > can't actually install anything. I thought maybe with RPM I could do this: > > Prefix: /tmp/myroot/usr > %install > mkdir -p /tmp/myroot/usr > make install DESTDIR=/tmp/myroot/usr > > but then, that would be a confusing default. > > The BSD packaging system allows you to build packages without modifying the > ultimate target directories. RPM has a similar mechanism: Prefix: /usr BuildRoot: %{_tmp}/%{name}-%{version}-root %install rm -rf %{buildroot} mkdir -p %{buildroot} make install DESTDIR=%{buildroot} Note: the %{buildroot} macro only works in more recent versions of RPM. $RPM_BUILD_ROOT is the equivalent (but deprecated) variable to use in older versions of RPM. Jeff |