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

Re: building rpms on debian system?



The Fungi wrote:
I'm not sure I've seen what seems to me to be the obvious solution
come through in a reply yet, but why not just create a custom chroot
for your target distribution (be it RHEL 4 or SUSE 9 or whatever)
and build in there?

Apparently this works pretty well for most people.  If so, great.  I'm
aware that any autobuilt package in Debian is handled with a chroot of
some kind, so obviously I've either been doing something wrong, or I'm
tripping over edge cases that don't get along with virtual Linux
installs of any kind.

Do it a la pbuilder and just keep a tarfile of
the clean system archived so you can have several without taking up
much space, and upgrade them periodically as needed. Your only
limitation is that you're stuck in the chroot using whatever kernel
you've booted for Debian, but if that becomes an issue, UML to the
rescue (in some ways easier to manage than chroots, in my opinion).

For reasonably current OSes, this is probably a useful option.  But my
own experience has been that while it may work OK for semi-recent OS
releases, it's of limited value for older OS releases.

I've never used this for building packages, but I tried for some time to
build an updated version of a Quake2 mod.  Unfortunately, a critical
library used by this mod is only available as a statically-linkable
binary - the library's author(s) did not release their source for
whatever reason.

In order to get the mod to build in such a way that it actually runs
without segfaulting, it must be compiled with a GCC version that matches
the version used to build the library (~2.7something).  At the very
*least*.  (g)libc version, kernel version, possibly the CPU, and who
knows what else may also be factors;  the code will compile and link
apparently without error pretty much anywhere I've tried.  But it will
either fail to load in Quake2 at all, or it will segfault on attempting
to exercise any of its capabilities.  (Once compiled correctly, it seems
to *run* just fine pretty much anywhere.  Nrgh.)

However, **EVERY** attempt I've made to do this in a logically separate
OS running under the current "real" OS (chroot, UML, and most recently a
VMWare virtual machine) has failed to produce a working binary.  The
ONLY place I've been able to successfully build this mod was in a
distribution that shipped with a suitable GCC, installed on a real P133.
 (RedHat 5.2 or Debian slink [2.1] contain a suitable gcc.)

Other things I've tried in chroots, UML images, and VMWare virtual
machines have shown a minor assortment of other oddities as well.
(Quite aside from the minor headaches of actually getting RedHat and its
descendants and variants installed in a chroot or UML image;  this is
one place Debian has a big advantage.)

-kgd
--
Get your mouse off of there!  You don't know where that email has been!




Reply to: