#21 figure out how to do mock builds with ccache
Closed 2 years ago by dcavalca. Opened 3 years ago by dcavalca.

ccache isn't in CentOS. It's available in EPEL, but one doesn't necessarily want to enable EPEL for builds. One option could be to build ccache in CentOS via the SIG, but maybe there's a better solution I'm not seeing here.


Why wouldn't one enable epel for builds? You can use includepkgs to include just one packages to be available

TIL. I hadn't realized you could just pick individual packages. Thanks! I'll give this a try and update the docs.

I'd rather not have EPEL enabled in general unless one is building against EPEL to prevent accidentally pulling in unwanted dependencies.

Yeah this totally works, I'm using this config:

include('templates/centos-stream-8.tpl')

config_opts['root'] = 'centos-stream-8-x86_64'
config_opts['target_arch'] = 'x86_64'
config_opts['legal_host_arches'] = ('x86_64',)

config_opts['dnf.conf'] += """

[epel]
name=Extra Packages for Enterprise Linux $releasever - $basearch
mirrorlist=http://mirrors.fedoraproject.org/mirrorlist?repo=epel-8&arch=$basearch
failovermethod=priority
gpgkey=file:///usr/share/distribution-gpg-keys/epel/RPM-GPG-KEY-EPEL-8
gpgcheck=1
skip_if_unavailable=False
includepkgs=ccache*
"""

Now that mock-centos-sig-configs includes the EPEL repos for Hyperscale this just works out of the box.

Metadata Update from @dcavalca:
- Issue status updated to: Closed (was: Open)

2 years ago

Login to comment on this ticket.

Metadata