Due to the kernel packages being named differently in RHEL/CentOS 8, the macros in the rpm spec for the scst-dkms-rpm build target fail to build, claiming a missing dependency on the kernel-core-devel package, which is not a real package.
The package is still called kernel-devel, even though the kernel itself is now kernel-core.
Build log:
# make scst-dkms-rpm
name=scst-dkms && \
rpmtopdir=/usr/src/packages && \
make scst-dist-gzip && \
for d in BUILD RPMS SOURCES SPECS SRPMS; do \
mkdir -p ${rpmtopdir}/$d; \
done && \
cp scst-3.5.0.8782.tar.bz2 ${rpmtopdir}/SOURCES && \
sed "s/@rpm_version@/3.5.0.8782/g" \
<${name}.spec.in >${name}.spec && \
MAKE="make" rpmbuild --define="%_topdir ${rpmtopdir}" \
\
\
-ba ${name}.spec && \
rm -f ${name}-3.5.0.8782.tar.bz2
make[1]: Entering directory '/root/scst-trunk'
[ -n "j" ] && [ -n "bz2" ] && [ -n "3.5.0.8782" ] && [ -n "grep -E '^doc/|^fcst/|^iscsi-scst/|^Makefile|^qla2x00t(|_git)/|^scripts/|^scst.spec|^scst/|^scst_local/|^srpt/|^usr/|^scstadmin/'" ] && name=scst && mkdir "${name}-3.5.0.8782" && { { scripts/list-source-files && if [ -e debian/changelog ]; then echo debian/changelog; fi; } | grep -E '^doc/|^fcst/|^iscsi-scst/|^Makefile|^qla2x00t(|_git)/|^scripts/|^scst.spec|^scst/|^scst_local/|^srpt/|^usr/|^scstadmin/' | tar -T- -cf- | tar -C "${name}-3.5.0.8782" -xf-; } && rm -f "${name}-3.5.0.8782.tar.bz2" && tar -cj -f "${name}-3.5.0.8782.tar.bz2" "${name}-3.5.0.8782" && rm -rf "${name}-3.5.0.8782"
make[1]: Leaving directory '/root/scst-trunk'
kversion=4.18.0-147.5.1.el8_1.centos.plus.x86_64
warning: Macro expanded in comment on line 22: %{kversion}.
krpmver=4.18.0-147.5.1.el8_1.centos.plus
error: Failed build dependencies:
kernel-plus-core-devel = 4.18.0-147.5.1.el8_1.centos.plus is needed by scst-dkms-3.5.0.8782-1.el8.x86_64
make: *** [Makefile:418: scst-dkms-rpm] Error 1
The offending line in scst-dkms.spec.in is line 34, where the name of the kernel-devel package is assumed to start with the name of the kernel package itself, which is no longer the case in CentOS 8.
This happens on non-plus kernels and mainline kernels, as well, for the record, since the naming convention is the same.
Oh, and I should also point out this is true of all the rpm build targets - not just the dkms rpm.
A candidate fix has been checked in on the trunk as r8833 + r8834. Please verify whether these changes fixes this issue.
This fixed the rpm builds on a plus kernel. I have not yet tested it on a mainline or non-plus kernel.
Confirmed this fixes the builds on mailine and vanilla kernels of CentOS 8.
I'd say this is safe to close.
Last edit: Brandon Thetford 2020-03-11
Thanks for the feedback!