From 7cdfc99aae8f0c5a45545ede84de8cedbb410ce7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9rgio=20M=2E=20Basto?= Date: Sun, 21 Jan 2024 16:48:42 +0000 Subject: [PATCH] Disable openexr on epel 9 --- opencv.spec | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/opencv.spec b/opencv.spec index 29ba800..88e703c 100644 --- a/opencv.spec +++ b/opencv.spec @@ -51,6 +51,12 @@ %bcond_with java %endif +%if 0%{?fedora} +%bcond_without openexr +%else +%bcond_with openexr +%endif + %bcond_without va %bcond_without vulkan @@ -125,10 +131,14 @@ BuildRequires: libpng-devel BuildRequires: libtiff-devel BuildRequires: libGL-devel BuildRequires: libv4l-devel +%{?with_openexr: BuildRequires: OpenEXR-devel +} %{?with_openni: BuildRequires: openni-devel +%if 0%{?fedora} BuildRequires: openni-primesense +%endif } %{?with_tbb: BuildRequires: tbb-devel @@ -434,7 +444,8 @@ install -pm 0644 %{S:4} .cache/ade/ %endif -DOpenGL_GL_PREFERENCE=GLVND \ -DWITH_GDAL=ON \ - -DWITH_OPENEXR=ON \ +%{?with_openexr: -DWITH_OPENEXR=ON} \ +%{!?with_openexr: -DWITH_OPENEXR=OFF} \ -DCMAKE_SKIP_RPATH=ON \ -DWITH_CAROTENE=OFF \ %ifarch x86_64 %{ix86}