Group :: System/Libraries
RPM: libopencv
Main Changelog Spec Patches Sources Download Gear Bugs and FR Repocop
%define _unpackaged_files_terminate_build 1
%define _stripped_files_terminate_build 1
%set_verify_elf_method strict
# LTO causes errors, disable it
%global optflags_lto %nil
# TODO: remove later this fix for documentation
%define _cmake__builddir BUILD
%def_with openmp
%def_without unicap
%def_with swig
%def_with python3
%def_without xine
%def_without octave
%def_without gstreamer
%def_with ffmpeg
%def_with 1394libs
%def_with v4l
%def_with gtk
%def_without quicktime
%ifarch %{ix86} x86_64 armh
%def_with gdcm
%else
%def_without gdcm
%endif
%def_without openni
#----------------------------------------------------------------------
%define set_without() %{expand:%%force_without %{1}} %{expand:%%undefine _with_%{1}}
%{?_with_ffmpeg:%set_without gstreamer}
%{?_with_ffmpeg:%set_without quicktime}
%{?_with_xine:%set_without quicktime}
%{?_with_1394libs:%set_without quicktime}
%{?_with_v4l:%set_without quicktime}
%define bname opencv
%define Name OpenCV
%define sover 4.7
Name: lib%bname
Epoch: 1
Version: 4.7.0
Release: alt1.1
Summary: Open Source Computer Vision Library
License: Distributable
Group: System/Libraries
URL: https://opencv.org
# https://github.com/opencv/opencv.git
Source: %bname-%version.tar
# https://github.com/opencv/opencv_contrib.git
Source1: %bname-contrib-%version.tar
Patch1: %name-4.5.5-alt-python-paths.patch
Patch2: %name-4.5.5-alt-build.patch
Patch2000: %name-e2k-simd.patch
BuildRequires: gcc-c++ libjasper-devel libjpeg-devel libtiff-devel
BuildRequires: openexr-devel graphviz libpng-devel libpixman-devel
BuildRequires: cmake eigen3 zlib-devel
BuildRequires: python3 python3(bs4) doxygen
BuildRequires: libucil-devel libtbb-devel bzlib-devel
BuildRequires: pkgconfig(glproto) pkgconfig(dri2proto) pkgconfig(xext)
BuildRequires: pkgconfig(xdamage) pkgconfig(xxf86vm)
BuildRequires: libGLU-devel libXau-devel libXdmcp-devel
BuildRequires: python3-module-sphinx-devel python3-module-Pygments python3-module-sphinx-sphinx-build-symlink
BuildRequires: texlive-latex-base
BuildRequires: libprotobuf-devel protobuf-compiler libwebp-devel
BuildRequires: libgflags-devel
%ifarch %{ix86} x86_64 armh
BuildRequires: libglog-devel
%endif
%ifarch %{ix86} x86_64
BuildRequires: ceres-solver-devel
%endif
%{?_with_v4l:BuildRequires: libv4l-devel}
%{?_with_openmp:BuildRequires: libgomp-devel}
%{?_with_unicap:BuildRequires: libunicap-devel}
%{?_with_ffmpeg:BuildRequires: libavformat-devel libswscale-devel libavresample-devel}
%{?_with_gstreamer:BuildRequires: gstreamer1.0-devel gst-plugins1.0-devel}
%{?_with_gtk:BuildRequires: libgtk+3-devel}
%{?_with_xine:BuildRequires: libxine-devel}
%{?_with_python3:
BuildRequires(pre): rpm-build-python3
BuildRequires: python3-devel
BuildRequires: libnumpy-py3-devel
}
%{?_with_octave:BuildRequires: octave-devel}
%{?_with_swig:BuildRequires: swig}
%{?_with_1394libs:BuildRequires: libdc1394-devel}
%{?_with_gdcm:BuildRequires: gdcm-devel}
%{?_with_openni:
BuildRequires: openni-devel
BuildRequires: openni-primesense
}
BuildRequires: libade-devel
%add_findprov_skiplist %_datadir/OpenCV/samples/*
%description
%Name means Intel(R) Open Source Computer Vision Library. It is a
collection of C functions and a few C++ classes that implement many
popular Image Processing and Computer Vision algorithms.
%Name provides cross-platform middle-to-high level API that includes
about 300 C functions and a few C++ classes. Also there are constantly
improving Python bindings to %Name.
%package -n lib%bname%sover
Group: System/Libraries
Summary: Open Source Computer Vision Library
%description -n lib%bname%sover
%Name means Intel(R) Open Source Computer Vision Library. It is a
collection of C functions and a few C++ classes that implement many
popular Image Processing and Computer Vision algorithms.
%Name provides cross-platform middle-to-high level API that includes
about 300 C functions and a few C++ classes. Also there are constantly
improving Python bindings to %Name.
%package devel
Group: Development/C++
Summary: Development files for %name
Requires: lib%bname%sover = %EVR
# generated cmake targets mention tbb, require it here explicitly
Requires: tbb-devel
Provides: lib%{bname}2.2-devel = %EVR
Provides: lib%{bname}2-devel = %EVR
Conflicts: lib%{bname}2.2-devel < %EVR
Obsoletes: lib%{bname}2.2-devel < %EVR
Conflicts: lib%{bname}2-devel < %EVR
Obsoletes: lib%{bname}2-devel < %EVR
Provides: lib%bname-devel-static = %EVR
%description devel
%Name means Intel(R) Open Source Computer Vision Library. It is a
collection of C functions and a few C++ classes that implement many
popular Image Processing and Computer Vision algorithms.
%Name provides cross-platform middle-to-high level API that includes
about 300 C functions and a few C++ classes. Also there are constantly
improving Python bindings to %Name.
This package contains header files and documentation needed to develop
applications with %name.
%package doc
Summary: %name documentation
Group: Development/Documentation
BuildArch: noarch
%description doc
%Name means Intel(R) Open Source Computer Vision Library. It is a
collection of C functions and a few C++ classes that implement many
popular Image Processing and Computer Vision algorithms.
%Name provides cross-platform middle-to-high level API that includes
about 300 C functions and a few C++ classes. Also there are constantly
improving Python bindings to %Name.
This package contains API Reference for develop with %name.
%package tests
Group: Video
Summary: %Name tests
Requires: lib%bname%sover = %EVR
%description tests
%Name means Intel(R) Open Source Computer Vision Library. It is a
collection of C functions and a few C++ classes that implement many
popular Image Processing and Computer Vision algorithms.
%Name provides cross-platform middle-to-high level API that includes
about 300 C functions and a few C++ classes. Also there are constantly
improving Python bindings to %Name.
This package contains %Name tests applications.
%package utils
Group: Video
Summary: %Name utils
Provides: lib%{bname}2-utils = %EVR
Conflicts: lib%{bname}2-utils < %EVR
Obsoletes: lib%{bname}2-utils < %EVR
Provides: lib%{bname}3.4-utils = %EVR
Conflicts: lib%{bname}3.4-utils < %EVR
Obsoletes: lib%{bname}3.4-utils < %EVR
%description utils
%Name means Intel(R) Open Source Computer Vision Library. It is a
collection of C functions and a few C++ classes that implement many
popular Image Processing and Computer Vision algorithms.
%Name provides cross-platform middle-to-high level API that includes
about 300 C functions and a few C++ classes. Also there are constantly
improving Python bindings to %Name.
This package contains %Name demo applications.
%if_with python3
%package -n python3-module-%bname
Group: Development/Python3
Summary: Python3 modules for %Name
Provides: python3-module-%{bname}3.4 = %EVR
Conflicts: python3-module-%{bname}3.4 < %EVR
Obsoletes: python3-module-%{bname}3.4 < %EVR
%description -n python3-module-%bname
%Name means Intel(R) Open Source Computer Vision Library. It is a
collection of C functions and a few C++ classes that implement many
popular Image Processing and Computer Vision algorithms.
%Name provides cross-platform middle-to-high level API that includes
about 300 C functions and a few C++ classes. Also there are constantly
improving Python bindings to %Name.
This package contains an extension module for python that provides a
Python3 language mapping for the %Name.
%endif
%package examples
Group: Video
Summary: %Name samples
Conflicts: lib%bname-examples
Conflicts: lib%{bname}2-examples
Provides: lib%{bname}3.4-examples = %EVR
Conflicts: lib%{bname}3.4-examples < %EVR
Obsoletes: lib%{bname}3.4-examples < %EVR
AutoReq:no
%description examples
%Name means Intel(R) Open Source Computer Vision Library. It is a
collection of C functions and a few C++ classes that implement many
popular Image Processing and Computer Vision algorithms.
%Name provides cross-platform middle-to-high level API that includes
about 300 C functions and a few C++ classes. Also there are constantly
improving Python bindings to %Name.
This package contains %Name examples.
%prep
%setup -b 1
%patch1 -p1
pushd ../%bname-contrib-%version >/dev/null
popd >/dev/null
%patch2 -p1
%ifarch %e2k
%patch2000 -p1
%endif
rm -fR 3rdparty/{ffmpeg,libjasper,libjpeg,libpng,libtiff,openexr,tbb,zlib,protobuf,libwebp}
%build
%add_optflags -D_FILE_OFFSET_BITS=64
%cmake \
-DBUILD_PACKAGE:BOOL=ON \
-DBUILD_TESTS:BOOL=OFF \
-DBUILD_EXAMPLES:BOOL=ON \
-DINSTALL_C_EXAMPLES:BOOL=ON \
-DINSTALL_PYTHON_EXAMPLES:BOOL=ON \
-DENABLE_OPENMP:BOOL=%{?_with_openmp:ON}%{!?_with_openmp:OFF} \
-DWITH_TBB:BOOL=ON \
-DBUILD_PYTHON_SUPPORT:BOOL=ON \
-DCMAKE_VERBOSE:BOOL=ON \
-DCMAKE_VERBOSE_MAKEFILE:BOOL=ON \
-DCMAKE_BUILD_TYPE:STRING=RelWithDebInfo \
-DWITH_UNICAP:BOOL=%{?_with_unicap:ON}%{!?_with_unicap:OFF} \
-DWITH_QUICKTIME:BOOL=%{?_with_quicktime:ON}%{!?_with_quicktime:OFF} \
-DWITH_XINE:BOOL=%{?_with_xine:ON}%{!?_with_xine:OFF} \
-DWITH_FFMPEG:BOOL=%{?_with_ffmpeg:ON}%{!?_with_ffmpeg:OFF} \
-DWITH_GSTREAMER=%{?_with_gstreamer:ON}%{!?_with_gstreamer:OFF} \
-DWITH_OPENGL:BOOL=ON \
-DCMAKE_STRIP:FILEPATH="/bin/echo" \
-DBUILD_opencv_ts:BOOL=OFF \
-DBUILD_PROTOBUF:BOOL=OFF \
-DPROTOBUF_UPDATE_FILES:BOOL=ON \
-DOPENCV_ENABLE_NONFREE:BOOL=ON \
-DWITH_LIBV4L:BOOL=%{?_with_v4l:ON}%{!?_with_v4l:OFF} \
-DOPENCV_EXTRA_MODULES_PATH=%_builddir/%bname-contrib-%version/modules \
%{?_with_openni: -DWITH_OPENNI=ON } \
%{?_with_gdcm: -DWITH_GDCM=ON} \
-DBUILD_DOCS:BOOL=ON \
-DOPENCV_DOC_INSTALL_PATH=%_docdir/%name/ \
-DOPENCV_3P_LIB_INSTALL_PATH=%_libdir/%Name/3rdparty/%_lib \
-DOPENCV_LICENSES_INSTALL_PATH=%_datadir/%Name-%version/licenses \
-DOPENCV_OTHER_INSTALL_PATH=%_datadir/%Name \
-DOPENCV_GENERATE_PKGCONFIG:BOOL=ON \
-DOPENCV_SKIP_CMAKE_CXX_STANDARD:BOOL=ON \
-DPYTHON_EXECUTABLE=%__python3 \
-DPYTHON_DEFAULT_EXECUTABLE=%__python3 \
%nil
%cmake_build
%cmake_build -t opencv_docs
%install
%cmakeinstall_std install_docs
%files -n lib%bname%sover
%doc README.md
%_libdir/*.so.*
%dir %_datadir/%Name
%dir %_datadir/%Name-%version
%_datadir/%Name-%version/licenses
%files devel
%_libdir/*.so
%_libdir/cmake/*
%_includedir/*
%_pkgconfigdir/*
%_datadir/%Name/*.supp
%ifarch %{ix86} x86_64 armh
%dir %_libdir/%Name
%dir %_libdir/%Name/3rdparty
%dir %_libdir/%Name/3rdparty/%_lib
%_libdir/%Name/3rdparty/%_lib/*.a
%endif
%files doc
%_docdir/%name
%files utils
%_bindir/*
%if_with python3
%files -n python3-module-%bname
%python3_sitelibdir/*
%endif
%files examples
%_datadir/%Name/samples
%_datadir/%Name/haarcascades
%_datadir/%Name/lbpcascades
%_datadir/%Name/quality
%changelog
…
Full changelog you can see here
%define _stripped_files_terminate_build 1
%set_verify_elf_method strict
# LTO causes errors, disable it
%global optflags_lto %nil
# TODO: remove later this fix for documentation
%define _cmake__builddir BUILD
%def_with openmp
%def_without unicap
%def_with swig
%def_with python3
%def_without xine
%def_without octave
%def_without gstreamer
%def_with ffmpeg
%def_with 1394libs
%def_with v4l
%def_with gtk
%def_without quicktime
%ifarch %{ix86} x86_64 armh
%def_with gdcm
%else
%def_without gdcm
%endif
%def_without openni
#----------------------------------------------------------------------
%define set_without() %{expand:%%force_without %{1}} %{expand:%%undefine _with_%{1}}
%{?_with_ffmpeg:%set_without gstreamer}
%{?_with_ffmpeg:%set_without quicktime}
%{?_with_xine:%set_without quicktime}
%{?_with_1394libs:%set_without quicktime}
%{?_with_v4l:%set_without quicktime}
%define bname opencv
%define Name OpenCV
%define sover 4.7
Name: lib%bname
Epoch: 1
Version: 4.7.0
Release: alt1.1
Summary: Open Source Computer Vision Library
License: Distributable
Group: System/Libraries
URL: https://opencv.org
# https://github.com/opencv/opencv.git
Source: %bname-%version.tar
# https://github.com/opencv/opencv_contrib.git
Source1: %bname-contrib-%version.tar
Patch1: %name-4.5.5-alt-python-paths.patch
Patch2: %name-4.5.5-alt-build.patch
Patch2000: %name-e2k-simd.patch
BuildRequires: gcc-c++ libjasper-devel libjpeg-devel libtiff-devel
BuildRequires: openexr-devel graphviz libpng-devel libpixman-devel
BuildRequires: cmake eigen3 zlib-devel
BuildRequires: python3 python3(bs4) doxygen
BuildRequires: libucil-devel libtbb-devel bzlib-devel
BuildRequires: pkgconfig(glproto) pkgconfig(dri2proto) pkgconfig(xext)
BuildRequires: pkgconfig(xdamage) pkgconfig(xxf86vm)
BuildRequires: libGLU-devel libXau-devel libXdmcp-devel
BuildRequires: python3-module-sphinx-devel python3-module-Pygments python3-module-sphinx-sphinx-build-symlink
BuildRequires: texlive-latex-base
BuildRequires: libprotobuf-devel protobuf-compiler libwebp-devel
BuildRequires: libgflags-devel
%ifarch %{ix86} x86_64 armh
BuildRequires: libglog-devel
%endif
%ifarch %{ix86} x86_64
BuildRequires: ceres-solver-devel
%endif
%{?_with_v4l:BuildRequires: libv4l-devel}
%{?_with_openmp:BuildRequires: libgomp-devel}
%{?_with_unicap:BuildRequires: libunicap-devel}
%{?_with_ffmpeg:BuildRequires: libavformat-devel libswscale-devel libavresample-devel}
%{?_with_gstreamer:BuildRequires: gstreamer1.0-devel gst-plugins1.0-devel}
%{?_with_gtk:BuildRequires: libgtk+3-devel}
%{?_with_xine:BuildRequires: libxine-devel}
%{?_with_python3:
BuildRequires(pre): rpm-build-python3
BuildRequires: python3-devel
BuildRequires: libnumpy-py3-devel
}
%{?_with_octave:BuildRequires: octave-devel}
%{?_with_swig:BuildRequires: swig}
%{?_with_1394libs:BuildRequires: libdc1394-devel}
%{?_with_gdcm:BuildRequires: gdcm-devel}
%{?_with_openni:
BuildRequires: openni-devel
BuildRequires: openni-primesense
}
BuildRequires: libade-devel
%add_findprov_skiplist %_datadir/OpenCV/samples/*
%description
%Name means Intel(R) Open Source Computer Vision Library. It is a
collection of C functions and a few C++ classes that implement many
popular Image Processing and Computer Vision algorithms.
%Name provides cross-platform middle-to-high level API that includes
about 300 C functions and a few C++ classes. Also there are constantly
improving Python bindings to %Name.
%package -n lib%bname%sover
Group: System/Libraries
Summary: Open Source Computer Vision Library
%description -n lib%bname%sover
%Name means Intel(R) Open Source Computer Vision Library. It is a
collection of C functions and a few C++ classes that implement many
popular Image Processing and Computer Vision algorithms.
%Name provides cross-platform middle-to-high level API that includes
about 300 C functions and a few C++ classes. Also there are constantly
improving Python bindings to %Name.
%package devel
Group: Development/C++
Summary: Development files for %name
Requires: lib%bname%sover = %EVR
# generated cmake targets mention tbb, require it here explicitly
Requires: tbb-devel
Provides: lib%{bname}2.2-devel = %EVR
Provides: lib%{bname}2-devel = %EVR
Conflicts: lib%{bname}2.2-devel < %EVR
Obsoletes: lib%{bname}2.2-devel < %EVR
Conflicts: lib%{bname}2-devel < %EVR
Obsoletes: lib%{bname}2-devel < %EVR
Provides: lib%bname-devel-static = %EVR
%description devel
%Name means Intel(R) Open Source Computer Vision Library. It is a
collection of C functions and a few C++ classes that implement many
popular Image Processing and Computer Vision algorithms.
%Name provides cross-platform middle-to-high level API that includes
about 300 C functions and a few C++ classes. Also there are constantly
improving Python bindings to %Name.
This package contains header files and documentation needed to develop
applications with %name.
%package doc
Summary: %name documentation
Group: Development/Documentation
BuildArch: noarch
%description doc
%Name means Intel(R) Open Source Computer Vision Library. It is a
collection of C functions and a few C++ classes that implement many
popular Image Processing and Computer Vision algorithms.
%Name provides cross-platform middle-to-high level API that includes
about 300 C functions and a few C++ classes. Also there are constantly
improving Python bindings to %Name.
This package contains API Reference for develop with %name.
%package tests
Group: Video
Summary: %Name tests
Requires: lib%bname%sover = %EVR
%description tests
%Name means Intel(R) Open Source Computer Vision Library. It is a
collection of C functions and a few C++ classes that implement many
popular Image Processing and Computer Vision algorithms.
%Name provides cross-platform middle-to-high level API that includes
about 300 C functions and a few C++ classes. Also there are constantly
improving Python bindings to %Name.
This package contains %Name tests applications.
%package utils
Group: Video
Summary: %Name utils
Provides: lib%{bname}2-utils = %EVR
Conflicts: lib%{bname}2-utils < %EVR
Obsoletes: lib%{bname}2-utils < %EVR
Provides: lib%{bname}3.4-utils = %EVR
Conflicts: lib%{bname}3.4-utils < %EVR
Obsoletes: lib%{bname}3.4-utils < %EVR
%description utils
%Name means Intel(R) Open Source Computer Vision Library. It is a
collection of C functions and a few C++ classes that implement many
popular Image Processing and Computer Vision algorithms.
%Name provides cross-platform middle-to-high level API that includes
about 300 C functions and a few C++ classes. Also there are constantly
improving Python bindings to %Name.
This package contains %Name demo applications.
%if_with python3
%package -n python3-module-%bname
Group: Development/Python3
Summary: Python3 modules for %Name
Provides: python3-module-%{bname}3.4 = %EVR
Conflicts: python3-module-%{bname}3.4 < %EVR
Obsoletes: python3-module-%{bname}3.4 < %EVR
%description -n python3-module-%bname
%Name means Intel(R) Open Source Computer Vision Library. It is a
collection of C functions and a few C++ classes that implement many
popular Image Processing and Computer Vision algorithms.
%Name provides cross-platform middle-to-high level API that includes
about 300 C functions and a few C++ classes. Also there are constantly
improving Python bindings to %Name.
This package contains an extension module for python that provides a
Python3 language mapping for the %Name.
%endif
%package examples
Group: Video
Summary: %Name samples
Conflicts: lib%bname-examples
Conflicts: lib%{bname}2-examples
Provides: lib%{bname}3.4-examples = %EVR
Conflicts: lib%{bname}3.4-examples < %EVR
Obsoletes: lib%{bname}3.4-examples < %EVR
AutoReq:no
%description examples
%Name means Intel(R) Open Source Computer Vision Library. It is a
collection of C functions and a few C++ classes that implement many
popular Image Processing and Computer Vision algorithms.
%Name provides cross-platform middle-to-high level API that includes
about 300 C functions and a few C++ classes. Also there are constantly
improving Python bindings to %Name.
This package contains %Name examples.
%prep
%setup -b 1
%patch1 -p1
pushd ../%bname-contrib-%version >/dev/null
popd >/dev/null
%patch2 -p1
%ifarch %e2k
%patch2000 -p1
%endif
rm -fR 3rdparty/{ffmpeg,libjasper,libjpeg,libpng,libtiff,openexr,tbb,zlib,protobuf,libwebp}
%build
%add_optflags -D_FILE_OFFSET_BITS=64
%cmake \
-DBUILD_PACKAGE:BOOL=ON \
-DBUILD_TESTS:BOOL=OFF \
-DBUILD_EXAMPLES:BOOL=ON \
-DINSTALL_C_EXAMPLES:BOOL=ON \
-DINSTALL_PYTHON_EXAMPLES:BOOL=ON \
-DENABLE_OPENMP:BOOL=%{?_with_openmp:ON}%{!?_with_openmp:OFF} \
-DWITH_TBB:BOOL=ON \
-DBUILD_PYTHON_SUPPORT:BOOL=ON \
-DCMAKE_VERBOSE:BOOL=ON \
-DCMAKE_VERBOSE_MAKEFILE:BOOL=ON \
-DCMAKE_BUILD_TYPE:STRING=RelWithDebInfo \
-DWITH_UNICAP:BOOL=%{?_with_unicap:ON}%{!?_with_unicap:OFF} \
-DWITH_QUICKTIME:BOOL=%{?_with_quicktime:ON}%{!?_with_quicktime:OFF} \
-DWITH_XINE:BOOL=%{?_with_xine:ON}%{!?_with_xine:OFF} \
-DWITH_FFMPEG:BOOL=%{?_with_ffmpeg:ON}%{!?_with_ffmpeg:OFF} \
-DWITH_GSTREAMER=%{?_with_gstreamer:ON}%{!?_with_gstreamer:OFF} \
-DWITH_OPENGL:BOOL=ON \
-DCMAKE_STRIP:FILEPATH="/bin/echo" \
-DBUILD_opencv_ts:BOOL=OFF \
-DBUILD_PROTOBUF:BOOL=OFF \
-DPROTOBUF_UPDATE_FILES:BOOL=ON \
-DOPENCV_ENABLE_NONFREE:BOOL=ON \
-DWITH_LIBV4L:BOOL=%{?_with_v4l:ON}%{!?_with_v4l:OFF} \
-DOPENCV_EXTRA_MODULES_PATH=%_builddir/%bname-contrib-%version/modules \
%{?_with_openni: -DWITH_OPENNI=ON } \
%{?_with_gdcm: -DWITH_GDCM=ON} \
-DBUILD_DOCS:BOOL=ON \
-DOPENCV_DOC_INSTALL_PATH=%_docdir/%name/ \
-DOPENCV_3P_LIB_INSTALL_PATH=%_libdir/%Name/3rdparty/%_lib \
-DOPENCV_LICENSES_INSTALL_PATH=%_datadir/%Name-%version/licenses \
-DOPENCV_OTHER_INSTALL_PATH=%_datadir/%Name \
-DOPENCV_GENERATE_PKGCONFIG:BOOL=ON \
-DOPENCV_SKIP_CMAKE_CXX_STANDARD:BOOL=ON \
-DPYTHON_EXECUTABLE=%__python3 \
-DPYTHON_DEFAULT_EXECUTABLE=%__python3 \
%nil
%cmake_build
%cmake_build -t opencv_docs
%install
%cmakeinstall_std install_docs
%files -n lib%bname%sover
%doc README.md
%_libdir/*.so.*
%dir %_datadir/%Name
%dir %_datadir/%Name-%version
%_datadir/%Name-%version/licenses
%files devel
%_libdir/*.so
%_libdir/cmake/*
%_includedir/*
%_pkgconfigdir/*
%_datadir/%Name/*.supp
%ifarch %{ix86} x86_64 armh
%dir %_libdir/%Name
%dir %_libdir/%Name/3rdparty
%dir %_libdir/%Name/3rdparty/%_lib
%_libdir/%Name/3rdparty/%_lib/*.a
%endif
%files doc
%_docdir/%name
%files utils
%_bindir/*
%if_with python3
%files -n python3-module-%bname
%python3_sitelibdir/*
%endif
%files examples
%_datadir/%Name/samples
%_datadir/%Name/haarcascades
%_datadir/%Name/lbpcascades
%_datadir/%Name/quality
%changelog
…
Full changelog you can see here