meson: Tidy NorthStar driver selection code (NFC)

This commit is contained in:
Jakob Bornecrantz 2020-05-11 14:34:53 +01:00
parent 26539e79b6
commit d645b58186

View file

@ -130,9 +130,6 @@ drivers = get_option('drivers')
if 'ohmd' in drivers if 'ohmd' in drivers
openhmd_required = true openhmd_required = true
endif endif
if 'ns' in drivers
ns_required = true
endif
if 'psvr' in drivers if 'psvr' in drivers
hidapi_required = true hidapi_required = true
endif endif
@ -141,19 +138,13 @@ if 'v4l2' in drivers
endif endif
if 'auto' in drivers if 'auto' in drivers
drivers += ['dummy', 'hdk', 'hydra', 'psmv'] drivers += ['dummy', 'hdk', 'hydra', 'ns', 'psmv']
endif endif
openhmd = dependency('openhmd', required: openhmd_required) openhmd = dependency('openhmd', required: openhmd_required)
hidapi = dependency('hidapi-libusb', required: hidapi_required) hidapi = dependency('hidapi-libusb', required: hidapi_required)
v4l2 = dependency('libv4l2', required: v4l2_required) v4l2 = dependency('libv4l2', required: v4l2_required)
if 'auto' in drivers or 'ns' in drivers
if 'ns' not in drivers
drivers += ['ns']
endif
endif
if openhmd.found() and ('auto' in drivers or 'ohmd' in drivers) if openhmd.found() and ('auto' in drivers or 'ohmd' in drivers)
if 'ohmd' not in drivers if 'ohmd' not in drivers
drivers += ['ohmd'] drivers += ['ohmd']