View on GitHub

Mock » Release Notes 1.4.11

A 'simple' chroot build environment manager for building RPMs.

Released on 2018-06-12.

Features:

$ mock -r fedora-28-ppc64le shell
ERROR: Cannot build target ppc64le on arch x86_64, because it is not listed in legal_host_arches ('ppc64le',)

Now, you can build for any architecture using new option –force-arch ARCH. GH#120 You have to have installed package qemu-user-static, which is a new soft dependence. Try this:

$ sudo dnf install qemu-user-static
$ mock -r fedora-28-ppc64le --forcearch ppc64le shell

and you get the prompt in PPC64LE Fedora. You can do this for any architecture supported by QEMU. Note: Do not confuse --forcearch and --arch which are very different options.

# You can configure which tar is used (for root cache and SCM plugin)
# valid options are: "gnutar" or "bsdtar"
# config_opts['tar'] = "gnutar"

Be aware that if you created a cache using gnutar then you cannot extract it using bsdtar. Therefore when changing this option, you have to scrub all caches.

# name of user that is used when executing commands inside the chroot
# config_opts['chrootuser'] = 'mockbuild'

This can be changed to different value. E.g., ‘root’. However, be aware that any other value than ‘mockbuild’ is not tested by upstream.

# config_opts['microdnf_command'] = '/usr/bin/microdnf'
## "dnf-install" is special keyword which tells mock to use install but with DNF
# config_opts['microdnf_install_command'] = 'dnf-install microdnf dnf dnf-plugins-core distribution-gpg-keys'
# config_opts['microdnf_builddep_command'] = '/usr/bin/dnf'
# config_opts['microdnf_builddep_opts'] = []
# config_opts['microdnf_common_opts'] = []
# config_opts['microdnf_command'] = '/usr/bin/microdnf'
config_opts['package_manager'] = 'microdnf'

Right now, Mock does not ship any config which use this package manager.

# dnf download --source foo
# rpm2cpio foo.src.rpm | cpio -dimv
(Add/modify compilation flags in .spec file)
# mock --spec foo.spec foo.src.rpm --postinstall
(or)
# mock --spec foo.spec --sources ./

Bugfixes:

Following contributors contributed to this release:

Thank you.