From fa58f27bb421b449134e79c03a4fb8762ab18679 Mon Sep 17 00:00:00 2001 From: Michael Stahl Date: Wed, 31 Jul 2019 12:30:26 +0200 Subject: solenv installer: don't let RPM generate config(...) Requires Fedora 30's rpm 4.14.2.1 will generate this Requires: config(lodevbasis6.1-core) = 6.1.7.0.0-1 ... but no corresponding Provides because that's disabled, so the package cannot be installed. The reason is that there is one %config file in the -core rpm: %attr(0644,root,root) %config(noreplace) "/opt/libreofficedev6.1/./share/psprint/psprint.conf" Old RPM from CentOS6 does not generate these config requires. Unfortunately there doesn't appear to be a way to disable this config(...) without disabling AutoReq, so do that, and invoke the shell script find-requires-x11.sh manually from epmfile.pm. Change-Id: I7fee0d9cd1b9e79f81bd4c611500e84736564881 Reviewed-on: https://gerrit.libreoffice.org/76736 Tested-by: Jenkins Reviewed-by: Michael Stahl (cherry picked from commit b1d555ed42a035e0489accc19903c1ed8897bcee) --- solenv/bin/modules/installer/epmfile.pm | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'solenv') diff --git a/solenv/bin/modules/installer/epmfile.pm b/solenv/bin/modules/installer/epmfile.pm index bc6a76ccf44d..3e3df2a03295 100644 --- a/solenv/bin/modules/installer/epmfile.pm +++ b/solenv/bin/modules/installer/epmfile.pm @@ -1182,15 +1182,15 @@ sub set_autoprovreq_in_specfile { my ($changefile, $findrequires, $bindir) = @_; - my $autoreqprovline; + my $autoreqprovline = "AutoReqProv\: no\n"; if ( $findrequires ) { - $autoreqprovline = "AutoProv\: no\n%define _use_internal_dependency_generator 0\n%define __find_requires $bindir/$findrequires\n"; - } - else - { - $autoreqprovline = "AutoReqProv\: no\n"; + # don't let rpm invoke it, we never want to use AutoReq because + # rpm will generate Requires: config(packagename) + open (FINDREQUIRES, "echo | $bindir/$findrequires |"); + while () { $autoreqprovline .= "Requires: $_\n"; } + close (FINDREQUIRES); } $autoreqprovline .= "%define _binary_filedigest_algorithm 1\n%define _binary_payload w9.gzdio\n"; -- cgit