diff --git a/v4.5.2.tar.gz b/opencv-4.5.2.tar.gz similarity index 100% rename from v4.5.2.tar.gz rename to opencv-4.5.2.tar.gz diff --git a/opencv.spec b/opencv.spec index 55a1e4259b7aae2272f5decca74f76af8041ad3d..0c3e6d8134d3a7e9ec62527d16318f20cb218133 100644 --- a/opencv.spec +++ b/opencv.spec @@ -4,7 +4,13 @@ Release: 1 Summary: OpenCV means IntelĀ® Open Source Computer Vision Library. License: Apache-2.0 URL: https://github.com/opencv/opencv -Source0: https://github.com/opencv/opencv/archive/v%{version}.tar.gz +Source0: %{name}-%{version}.tar.gz +Source1: %{name}_extra-%{version}.tar.gz +Source2: opencv_extra-4.5.2.tar.gz.aa +Source3: opencv_extra-4.5.2.tar.gz.ab +Source4: opencv_extra-4.5.2.tar.gz.ac +Source5: opencv_extra-4.5.2.tar.gz.ad +Source6: opencv_extra-4.5.2.tar.gz.ae BuildRequires: gcc-c++ gcc autoconf pkgconfig protobuf-compiler protobuf BuildRequires: cmake BuildRequires: libjpeg-devel @@ -15,11 +21,13 @@ BuildRequires: libpng-devel OpenCV means IntelĀ® Open Source Computer Vision Library. It is a collection of C functions and a few C++ classes that implement some popular Image Processing and Computer Vision algorithms. -ON + %global debug_package %{nil} %prep +cat %{SOURCE2} %{SOURCE3} %{SOURCE4} %{SOURCE5} %{SOURCE6} > %{SOURCE1} %autosetup -p1 -n %{name}-%{version} +tar -xvf %{SOURCE1} -C . %build mkdir -p cmake/build @@ -32,7 +40,11 @@ cmake ../../ -DCMAKE_BUILD_TYPE=Release -DWITH_PROTOBUF=OFF -DWITH_WEBP=OFF\ -DBUILD_PNG=OFF\ -DBUILD_OPENEXR=ON\ -DBUILD_TESTS=ON\ - -DBUILD_PERF_TESTS=OFF\ + -DBUILD_PERF_TESTS=ON\ + -DBUILD_EXAMPLES=ON\ + -DOPENCV_TEST_DATA_PATH=opencv_extra-%{version}/testdata\ + -DINSTALL_TESTS=ON\ + -DCMAKE_INSTALL_PREFIX=/usr/local\ -DBUILD_opencv_apps=OFF\ -DCMAKE_SKIP_RPATH=TRUE\ -DBUILD_opencv_python3=OFF\ @@ -51,16 +63,16 @@ make -j24 V=1 %install cd cmake/build -# mkdir %{buildroot}/usr/ make install DESTDIR=%{buildroot} %files %defattr(-,root,root) %exclude /usr/local/bin/setup_vars_opencv4.sh +%{_bindir}/opencv_run_all_tests.sh %{_libdir}/* %{_includedir}/* %exclude /usr/local/share/* %changelog -* Wed Sep 29 2021 shenwei - 4.5.2-1 +* Wed Sep 30 2021 shenwei - 4.5.2-1 - package init diff --git a/opencv_extra-4.5.2.tar.gz b/opencv_extra-4.5.2.tar.gz new file mode 100644 index 0000000000000000000000000000000000000000..5bd66f1a6f4c4c5bd7209bc5d1e8b4f42cf8cb52 Binary files /dev/null and b/opencv_extra-4.5.2.tar.gz differ diff --git a/opencv_extra-4.5.2.tar.gz.aa b/opencv_extra-4.5.2.tar.gz.aa new file mode 100644 index 0000000000000000000000000000000000000000..a412056c6efd7dc306323b89fd61a621dd989979 Binary files /dev/null and b/opencv_extra-4.5.2.tar.gz.aa differ diff --git a/opencv_extra-4.5.2.tar.gz.ab b/opencv_extra-4.5.2.tar.gz.ab new file mode 100644 index 0000000000000000000000000000000000000000..abe5197a4aeb09cca981a232579509ef8c9967c0 Binary files /dev/null and b/opencv_extra-4.5.2.tar.gz.ab differ diff --git a/opencv_extra-4.5.2.tar.gz.ac b/opencv_extra-4.5.2.tar.gz.ac new file mode 100644 index 0000000000000000000000000000000000000000..6d79a33e5a0c32decee390d35f910f921fad45bb Binary files /dev/null and b/opencv_extra-4.5.2.tar.gz.ac differ diff --git a/opencv_extra-4.5.2.tar.gz.ad b/opencv_extra-4.5.2.tar.gz.ad new file mode 100644 index 0000000000000000000000000000000000000000..ee942f848d5667df9dab937a3bdb256d93c6f74e Binary files /dev/null and b/opencv_extra-4.5.2.tar.gz.ad differ diff --git a/opencv_extra-4.5.2.tar.gz.ae b/opencv_extra-4.5.2.tar.gz.ae new file mode 100644 index 0000000000000000000000000000000000000000..6a117010b5f56a3b402b0ba4a43bfee1edd198ff Binary files /dev/null and b/opencv_extra-4.5.2.tar.gz.ae differ