meson: Add PIO access support for FreeBSD and NetBSD on Alpha.

Signed-off-by: Eric Anholt <eric@anholt.net>
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
This commit is contained in:
Eric Anholt 2018-08-07 16:23:11 -07:00 committed by Adam Jackson
parent 513d52d589
commit 843e44adf1
2 changed files with 10 additions and 4 deletions

View File

@ -11,6 +11,9 @@ hdrs_xorg_os_support = [
'xf86_OSproc.h'
]
os_dep = []
os_c_args = []
if get_option('pciaccess')
srcs_xorg_os_support += 'bus/Pci.c'
if host_machine.system() != 'linux' and host_machine.system() != 'solaris'
@ -108,6 +111,11 @@ elif host_machine.system().endswith('bsd')
srcs_xorg_os_support += 'shared/ioperm_noop.c'
elif host_machine.cpu_family() == 'alpha'
srcs_xorg_os_support += 'bsd/alpha_video.c'
if host_machine.system() == 'freebsd'
os_dep += cc.find_library('io')
elif host_machine.system() == 'netbsd'
os_c_args += '-DUSE_ALPHA_PIO'
endif
endif
if host_machine.system() == 'freebsd'
@ -145,8 +153,9 @@ xorg_os_support = static_library('xorg_os_support',
common_dep,
dbus_dep,
libdrm_dep,
os_dep,
],
c_args: xorg_c_args,
c_args: xorg_c_args + os_c_args,
)
install_data(hdrs_xorg_os_support, install_dir: xorgsdkdir)

View File

@ -52,7 +52,6 @@ conf_data.set('_GNU_SOURCE', '1')
# ifdef for openbsd?
conf_data.set('HAS_APERTURE_DRV', host_machine.system() == 'openbsd')
# XXX: USE_ALPHA_PIO and other bsd bits
# XXX: FALLBACK_INPUT_DRIVER
# XXX: BUNDLE_ID_PREFIX
# XXX: HAVE_LIBDISPATCH
@ -344,9 +343,7 @@ if host_machine.system() == 'freebsd' or host_machine.system() == 'dragonflybsd'
if host_machine.cpu_family() == 'x86' or host_machine.cpu_family() == 'x86_64'
xorg_data.set('USE_DEV_IO', true)
endif
# XXX: Add link to libio on alpha
elif host_machine.system() == 'netbsd'
# XXX: USE_ALPHA_PIO
# XXX: Add link to libi386
if host_machine.cpu_family() == 'x86' or host_machine.cpu_family() == 'x86_64'
xorg_data.set('USE_I386_IOPL', true)