# Upstream has all enabled by default.
config_query_option LIBVA_INTEL_API_OPTS "Enable DRM API?" y \
  --enable-drm --disable-drm     &&
config_query_option LIBVA_INTEL_API_OPTS "Enable X11 API?" y \
  --enable-x11 --disable-x11     &&
config_query_option LIBVA_INTEL_API_OPTS "Enable wayland API?" y \
  --enable-wayland --disable-wayland &&
config_query_option LIBVA_INTEL_API_OPTS "Enable hybrid codec?" y \
  --enable-hybrid-codec --disable-hybrid-codec &&

# Need to store the selection for sub dependency to libva.
persistent_add LIBVA_INTEL_API
if list_find "$LIBVA_INTEL_API_OPTS" --enable-drm; then
  LIBVA_INTEL_API+=" DRM"
fi &&
if list_find "$LIBVA_INTEL_API_OPTS" --enable-x11; then
  LIBVA_INTEL_API+=" X11"
fi &&
if list_find "$LIBVA_INTEL_API_OPTS" --enable-wayland; then
  LIBVA_INTEL_API+=" WAYLAND"
fi
