Imlib/gdm specs (was Re: /opt/gnome?)



Hi,

On Fri, 12 Feb 1999, Allan Third wrote:
[snip]
> > > With the way GNOME is built currently, automatically relocatible RPMs are
> > > essentially impossible to make.  They should be very easily manually
> > > relocatable.  First, configure your system to accept an /opt/gnome
> > > installation (eg. /opt/gnome/bin in the path, /opt/gnome/lib in
> > > ld.so.conf).  Then, for each package, in compile order, do the following
> > >   * Go to /usr/src/redhat/SPECS, and edit the spec file (glib.spec) so
> > >     that the %prefix line points to "/opt/gnome" instead of "/usr"
> > >   * Build the RPM from the new spec file
> 
> > > The %prefix variable should get passed to all the right places, so the
> > > binary RPM, while still not relocatable as far as rpm is concerned, is 
> > > now properly located in the different directory.
> > 
> > That's what I was hoping to be able to do, and it all seemed to be OK, but 
> > I wasn't sure how adding %prefix would affect the %build section - would I
> > have to alter the arguments given to configure, or would rpm do this
> > automatically? My guess is that it wouldn't, but I wasn't sure, and given
> > that I don't fully understand all of the arguments that are there, I 
> > thought I'd better hold off a while, and seek expert advice! :-) I'd give 
> > examples of the things I don't understand, but I'm not using my own machine
> > right now. I'll look them up when I get home, though.
> 
> My fault, I was speaking off the top of my head rather than looking at a
> spec.  I meant changing the line that says "%define prefix /usr" to 
> "%define prefix /opt/gnome".  Don't add a "%prefix /opt/gnome" line, that
> WILL confuse rpm (it will think the package is relocatable, but the
> binaries won't be able to handle relocation).

Thanks. My problem actually was that the SRPM I'd picked as a "sample" to let 
me see if I could do this was the one for freetype, which doesn't use the 
"%define prefix /usr" style, but just specifies each file location literally.
My fault. When I tried your suggestion with all the other SRPMS, they almost 
all worked fine, although I had problems with imlib and gdm.

Firstly,
imlib-1.9.2-3.src.rpm, from ftp.fr.gnome.org/pub/gnome/redhat/latest/SRPMS/:
I altered the spec file as suggested above, and then ran

rpm -ba --clean --rmsource imlib.spec

It all seemed to go well, until rpm tried to find the Provides and Requires 
stuff for imlib-cfgeditor. Here are the last lines of output:

Processing files: imlib-cfgeditor
Finding provides...
Finding requires...
Requires: imlib ld-linux.so.2 libX11.so.6 libXext.so.6 libc.so.6 libdl.so.2
libgdk-1.1.so.14 libgdk_imlib.so.1 libglib-1.1.so.13 libgmodule-1.1.so.13
libgtk-1.1.so.14 libm.so.6

after which it just drops to the shell, without writing either source or binary
RPMS. I then tried using the spec file from the source tarball 
imlib-1.9.2.tar.gz, with the same alteration to %prefix, and it worked 
perfectly. It wasn't really a big problem, but it was a bit weird - I
couldn't  really see why it originally went wrong.

I had a similar problem with gdm-0.7.9-3.src.rpm, which again compiled 
perfectly, but then suddenly stopped with the line:

Prereq: /usr/sbin/useradd /bin/sh

Again, I got this to work by compiling from the source tarball.

Anyone got any ideas why they went wrong? I suppose it doesn't really
matter,as they can both be made to work by other methods, but it'd be nice
if everything worked the way it was supposed to.

Thanks

Allan

------------------------------------------------------------------------
Allan Third (allan@mindless.com)

"It's raining popcorn. Hallelujah!"



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]