xfree86: os-support: fix FTBS when no recent enough libdrm found

On Linux, the only supported platform bus backend (*1) is via DRM/DRI.
Trying to build it w/o (recent enough) libdrm fails as it tries to
compile the drm-based implementation, w/o having drm.h available. (*2)

In order to fix this, we need to compile noop-implementation instead.

*1) platform specific code for detecting video devices
*2) https://gitlab.freedesktop.org/xorg/xserver/-/issues/1771

Issue: https://gitlab.freedesktop.org/xorg/xserver/-/issues/1771
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/1848>
This commit is contained in:
Enrico Weigelt, metux IT consult 2025-02-28 15:15:14 +01:00 committed by Marge Bot
parent e2ac461629
commit cab3856903

View File

@ -36,8 +36,12 @@ if host_machine.system() == 'linux'
'linux/lnx_video.c', 'linux/lnx_video.c',
'misc/SlowBcopy.c', 'misc/SlowBcopy.c',
'shared/VTsw_usl.c', 'shared/VTsw_usl.c',
'shared/drm_platform.c',
] ]
if libdrm_dep.found()
srcs_xorg_os_support += 'shared/drm_platform.c'
else
srcs_xorg_os_support += 'shared/platform_noop.c'
endif
if build_agp if build_agp
srcs_xorg_os_support += 'linux/lnx_agp.c' srcs_xorg_os_support += 'linux/lnx_agp.c'
else else