%else
%define USE_VULKAN 1
+%define USE_GBM 0
%define VULKAN_DRIVER broadcom
%if %{USE_VULKAN} == 1
%enable_driver vulkan
%endif
+%if %{USE_GBM} == 1
+%enable_driver gbm
+%endif
+
%enable_gallium_driver kmsro
%enable_gallium_driver swrast
%enable_gallium_driver vc4
%define dri_drivers "auto"
%endif
-%enable_driver gbm
%{echo: enabled gallium drivers : %{expand:%{gallium_drivers}}}
cp -a %{buildroot}%{_hal_libdir}/libEGL* %{buildroot}%{_hal_libdir}/driver/
cp -a %{buildroot}%{_hal_libdir}/libGLES* %{buildroot}%{_hal_libdir}/driver/
+%if %{expand:%{?enable_gbm:1}%{?!enable_gbm:0}}
cp -a %{buildroot}%{_hal_libdir}/libgbm* %{buildroot}%{_hal_libdir}/driver/
+%endif
mkdir -p %{buildroot}%{_hal_libdir}/udev/rules.d
cp 99-GPU-Acceleration.rules %{buildroot}%{_hal_libdir}/udev/rules.d
%{_hal_libdir}/dri/i915_dri.so
%endif
-%if %{enable_gbm}
+%if %{expand:%{?enable_gbm:1}%{?!enable_gbm:0}}
%{_hal_libdir}/driver/libgbm*
%endif