PaulHowarth/Blog/2006-06-22

Thursday 22nd June 2006

Fedora Extras

The version of mock in Extras was updated to the new version, 0.6. This version does away with using comps style groups for populating the buildroot (at least by default), and introduces the use of a buildsys-build package, which is basically empty but has dependencies on all of the packages required for the buildroot. The default list of dependencies is much smaller than with the previous mock release, basically lining up with the BuildRequires Exceptions List from the Packaging/Guidelines, which is good.

In addition to using mock to test-build packages for Extras, I also use it to build packages for old distributions. There are some problems to be overcome to do this though.

  • For all Fedora Core distributions before Fedora Core 5, and Red Hat Linux 9, an additional package, elfutils, is needed in the default buildroot. It's needed because redhat-rpm-config turns on the creation of debuginfo packages, and eu-strip from the elfutils package is needed for this. In Fedora Core 5, elfutils is a dependency of rpm-build, so it gets pulled in automatically, but this doesn't happen for earlier distributions. There is disagreement about where the dependency should really be (see Bug #111363, Bug #132633, and Bug #155129) so in the meantime (and certainly for end-of-lifed distributions), it needs to be a dependency of buildsys-build.

  • For all Fedora Core and Red Hat Linux distributions before Fedora Core 3, runuser isn't available and so the mock configuration file needs:

  • config_opts['runuser'] = '/bin/su'
  • I can't get mock to build for a Fedora Core 2 target on an x86_32 host, though I'm told it works on an x86_64 host, and it might work with SELinux disabled (not just permissive mode). The symptom is that it hangs up at the useradd mockbuild stage. I'd be interested to hear from anyone that has this working.

  • To build for a target of Fedora Core 1, you need to set in the host's /etc/sysctl.conf:

  • kernel.vdso = 0
  • This is due to a glibc bug (Bug #121351).

  • Building for any Red Hat Linux target requires rebuilding of many of the original packages, which have broken dependencies due to the use of Epoch: tags and the omission of the epoch in exact version dependencies, such as between foo and foo-devel. Whilst these comparisons worked back in 2003, they don't now.

  • Building for any Red Hat Linux target older than Red Hat Linux 9 requires file, fileutils, and findutils in the buildroot rather than coreutils (these are needed for the post-build scripts).

  • Red Hat Linux 7 does not include the redhat-rpm-config package, so it must not be included in the buildroot.

I have built buildsys-build and buildsys-macros packages for Red Hat Linux 7 to 9, Fedora Core 1 to 5, and they are available in my local repository.


Recent