CPack RPM : special situation for boost.mpi library

This may not precisely a cpack question, but I thought to start asking here.
I generate a binary .rpm file.

That rpm requires (by checking rpm -q --requries)

libboost_mpi.so.1.78.0()(64bit)

however, the Fedora installed packages provide

rpm -q --whatprovides “libboost_mpi.so.1.78.0()(64bit)”
no package provides libboost_mpi.so.1.78.0()(64bit)
rpm -q --whatprovides “libboost_mpi.so.1.78.0()(64bit)(openmpi-x86_64)”
boost-openmpi-1.78.0-11.fc38.x86_64

The difference is in that 2nd bracket section.
The context is that MPI is a specification for message passing parallel compute framework.
openmpi is a implementation. openmpi is installed.
boost.mpi is a C++ Boost library that can hook up to openmpi or other mpi impls.

I’m not sure how to instruct cpack?

Fedora handles this with some RPM macro magic somewhere. I think you’ll have to use and/or emulate that as needed. I wasn’t seeing it by the wiki page below, but asking of the discussion forum may find someone more familiar with the mechanisms.

yes not clear.
I’ve asked here Openmpi rpm : how is it spec'ed - #3 by finjulhich - Fedora Discussion

I’m at a loss her.
They’re saying there are rpm macros that collect the various mpi impl to generate the provides.
But I have no idea which ones.

rpmbuild --showrc on my host shows this section that matches openmpi.
13: _openmpi_load
. /etc/profile.d/modules.sh;
module load mpi/openmpi-%{_arch};
export OMPI_MCA_rmaps_base_oversubscribe=1
-13: _openmpi_unload
. /etc/profile.d/modules.sh;
module unload mpi/openmpi-%{_arch};

I’ve asked the guys who produced the packages directly

It may require building the RPM on a Fedora box or Fedora chroot/container. There may be some Fedora additional macro configuration present when built in a Fedora environment.