While this isn’t specifically a Rocky issue, I figure any answer would be helpful for those rebuilding packages on Rocky.
I want to rebuild the roundcubemail package from Rawhide for my CentOS 7 system, as the package has been removed from EPEL The ancient version had lots of vulnerabilities and updating to one without them would require a newer version of PHP. The latest roundcubemail in Rawhide, 1.6.1, requires PHP 7.3. There’s an rh-php73 in Software Collections. How do I get rpmbuild to accept that to satisfy the dependency? I tried “scl enable rh-php73 – rpmbuild -ba roundcubemail.spec” but that’s not going to see the SCL package to satisfy the dependency. (I also had to add a conditional to the spec file to suppress the Suggests tags that are unrecognized in the older rpmbuild command.)
(Once built, I’d run the package from rh73-php-fpm using a proxy directive in the Apache or nginx config file.)
I managed to get a test build to run to completion. I commented out the PHP >= 7.3 requirements and discovered an unspecified requirement for php-cli because it needs to parse one of the sources and the older PHP doesn’t like its syntax. So I installed rh-php73-php-cli and the package was built.
So I think I need to know how to change the BuildRequires and Requires tags to consider SCL packages.