adding packages to mock chroot
Jeff Sheltren
sheltren at cs.ucsb.edu
Mon Feb 27 23:38:38 UTC 2006
On Feb 27, 2006, at 6:14 PM, David Smith wrote:
> When you create a mock chroot, all the packages you want to install in
> it need to be available from a yum repostory. I've got the situation
> where I'm trying to bootstrap a bit, so, I'd like to be able to:
>
> - build a chroot
> - build a small set of packages
> - add those packages to the chroot to be used by future builds
>
> Off the top of my head, possibilities include:
>
> (1) creating a base chroot, building the rpms, add the new packages
> to a
> yum repo, creating a second chroot that contains the new packages
>
> (2) creating the base chroot, building the rpms, editing the
> buildroots.xml file and adding in the new packages, updating the yum
> repo, then run "mock init" again (hoping that the new packages
> would get
> added to the chroot)
>
> Are there better ways of doing this?
>
> Thanks.
>
>
David, I may be missing something, but I think the easiest way would
be to create a local directory on your build machine which contains
the packages you want included. Run 'createrepo' there, and then
reference that directory (now a yum repo) using file:///path/to/rpms
in your /etc/mock/whatever.conf file(s). This way you have a local
yum repo you can add your "special" packages to. There's no need to
edit the buildroots.xml file unless you want these to *always* be
installed - otherwise they'll just get pulled in as needed for
dependencies.
-Jeff
More information about the Fedora-buildsys-list
mailing list