Hide Forgot
Description of problem: The mock init fails when using "fedpkg --dist f26 mockbuild" (which is necessary when you're working on a local branch rather than on 'master') Error: libcrypt-nss conflicts with libcrypt-2.24.90-19.fc26.x86_64 You could try using --skip-broken to work around the problem You could try running: rpm -Va --nofiles --nodigest Error: libcrypt conflicts with libcrypt-nss-2.24.90-19.fc26.x86_64 Version-Release number of selected component (if applicable): fedpkg-1.25-1.fc24.noarch koji-1.10.1-13.fc24.noarch mock-1.2.21-1.fc24.noarch How reproducible: Always Steps to Reproduce: 1. fedpkg clone pstreams-devel 2. cd pstreams-devel 3. fedpkg --dist f26 mockbuild Actual results: Error: libcrypt-nss conflicts with libcrypt-2.24.90-19.fc26.x86_64 You could try using --skip-broken to work around the problem You could try running: rpm -Va --nofiles --nodigest Error: libcrypt conflicts with libcrypt-nss-2.24.90-19.fc26.x86_64 Expected results: The mock init completes successfully. Additional info: The problem is that the mock cfg generated by fedpkg (using koji) uses the /etc/mock/site-defaults.cfg value for config_opts['package_manager'], which is still 'yum' Rawhide needs to use 'dnf' now, so the mock config that fedpkg/koji generates in /tmp/fedora-26-x86_64.XXXXXXmockconfig/fedora-26-x86_64.cfg should use 'dnf' too. This problem doesn't happen for "--dist f26" because mock supplies /etc/mock/fedora-25-*.cfg configs with the right package_manager setting. It could be solved by adding /etc/mock/fedora-26-*.cfg but the nthe problem would happen again after F26 branches when there are no configs for F27. Another option would be to change mock's site-defaults.cfg to use 'dnf' as the package_manager and then fix all the configs for EPEL and older Fedora releases to set 'yum' explicitly. This would require some users of mock to also change their custom configs, but would solve the problem for future Fedora versions. The full output is: $ fedpkg --dist f26 mockbuild Wrote: /home/jwakely/src/fedora-scm/pstreams-devel/pstreams-devel-0.8.1-4.fc26.src.rpm INFO: mock.py version 1.2.21 starting (python version = 3.5.2)... Start: init plugins INFO: selinux enabled Finish: init plugins Start: run INFO: Start(/home/jwakely/src/fedora-scm/pstreams-devel/pstreams-devel-0.8.1-4.fc26.src.rpm) Config(f26-candidate-x86_64) Start: clean chroot Finish: clean chroot Start: chroot init INFO: calling preinit hooks Mock Version: 1.2.21 INFO: Mock Version: 1.2.21 Start: yum install Yum command has been deprecated, use dnf instead. See 'man dnf' and 'man yum2dnf' for more information. There is no installed groups file. Maybe run: yum groups mark convert (see man yum) Error: libcrypt-nss conflicts with libcrypt-2.24.90-19.fc26.x86_64 You could try using --skip-broken to work around the problem You could try running: rpm -Va --nofiles --nodigest Error: libcrypt conflicts with libcrypt-nss-2.24.90-19.fc26.x86_64 ERROR: Exception(/home/jwakely/src/fedora-scm/pstreams-devel/pstreams-devel-0.8.1-4.fc26.src.rpm) Config(f26-candidate-x86_64) 0 minutes 18 seconds INFO: Results and/or logs in: /home/jwakely/src/fedora-scm/pstreams-devel/results_pstreams-devel/0.8.1/4.fc26 INFO: Cleaning up build root ('cleanup_on_failure=True') Start: clean chroot Finish: clean chroot ERROR: Command failed. See logs for output. # /usr/bin/yum-deprecated --installroot /var/lib/mock/f26-candidate-x86_64/root/ groupinstall build --setopt=tsflags=nocontexts Could not run mockbuild: Command '['mock', '--configdir', '/tmp/fedora-26-x86_64.73ges_mockconfig', '-r', 'fedora-26-x86_64', '--resultdir', u'/home/jwakely/src/fedora-scm/pstreams-devel/results_pstreams-devel/0.8.1/4.fc26', '--rebuild', u'/home/jwakely/src/fedora-scm/pstreams-devel/pstreams-devel-0.8.1-4.fc26.src.rpm']' returned non-zero exit status 30
In fact a similar problem can be shown for f25 by using "fedpkg --dist f25 mock-config", which doesn't set the correct package_manager either. Usually that wouldn't be used, because mock provides an f25 config, but if you invoke it explicitly you get a config that doesn't work. I suppose another way to fix it would be to add another option to the fedpkg mockbuild command to allow the user to specify the package_manager, which could get passed down from pyrpkg to koji.genMockBuild in the **opts arg. That wouldn't be as good as just having it Do The Right Thing but would let users work around the problem without needing to edit (root-owned) mock configs to change the site-defaults.
Hmm, or maybe I should just be using "--dist master" instead? Is that the right answer?
The --dist=X option makes fedpkg work as if it was running in git branch X. If you want to build for Rawhide, you should indeed use --dist master. I think this problem is caused by f26 not being explicitly configured yet. If you run fedpkg with -v -d, you should see in the debug output that mock config was not found and fedpkg asked koji to generate one. Since the dist tag is unknown, it probably gets it wrong.
(In reply to Lubomír Sedlář from comment #3) > The --dist=X option makes fedpkg work as if it was running in git branch X. > If you want to build for Rawhide, you should indeed use --dist master. OK, sorry for the noise then. I'd always been using "--dist fNN" for rawhide, because until recently it worked fine and I thought it was correct. Let's close this then. > I think this problem is caused by f26 not being explicitly configured yet. Right. As I tried to say (but failed due to a typo) using "--dist f25" works, because it finds /etc/mock/fedora-25-$arch.cfg which has the right package manager set. > If you run fedpkg with -v -d, you should see in the debug output that mock > config was not found and fedpkg asked koji to generate one. Since the dist > tag is unknown, it probably gets it wrong. Note that it still gets it wrong for "fedpkg --dist f25 mock-config" though, and f25 *is* a known config, it's just that the mock-config command always generates a config from scratch, and doesn't use the known configs. That's usually not a problem, because mockbuild doesn't use mock-config for known configs.