On 7/29/2026 8:04 AM, Rohitashv Kumar wrote:
> From: Rohitashv Kumar <[email protected]>
> 
> With modular builds, the system/block module loop adds the common
> boilerplate (modulecommon) to every registered module and emits a
> shared_module unconditionally.  A module whose device sources are all
> disabled by the configuration then still produces a shared object
> containing nothing but the boilerplate: an empty stub that provides no
> devices and only complicates packaging.
> 
> This happens when a module is registered under a broader condition than
> the one gating its sources, e.g. hw-display-virtio-gpu-pci (registered on
> CONFIG_VIRTIO_PCI, sources need CONFIG_VIRTIO_GPU) in a build without
> virtio-gpu, or hw-s390x-virtio-gpu-ccw (registered unconditionally,
> source needs CONFIG_VIRTIO_CCW) in a build without an s390x target.
> 
> The target_modules loop already skips modules whose applied source set is
> empty; make the system/block loop consistent and do the same.
> 
> Signed-off-by: Rohitashv Kumar <[email protected]>
> ---
>  meson.build | 3 +++
>  1 file changed, 3 insertions(+)
> 

Reviewed-by: Pierrick Bouvier <[email protected]>

Reply via email to