]> git.pld-linux.org Git - packages/highway.git/commitdiff
add tests bcond
authorJan Palus <atler@pld-linux.org>
Sat, 9 Jul 2022 17:35:57 +0000 (19:35 +0200)
committerJan Palus <atler@pld-linux.org>
Sat, 9 Jul 2022 17:35:57 +0000 (19:35 +0200)
highway.spec

index ead09d00d1864be7f664e3229f8786e346a443ed..0865b0f963358a679c997455f758a3ddf7cfd658 100644 (file)
@@ -1,6 +1,7 @@
 #
 # Conditional build:
 %bcond_without apidocs         # API documentation
+%bcond_without tests           # don't build tests
 #
 Summary:       Efficient and performance-portable SIMD
 Summary(pl.UTF-8):     Wydajne i przenoĊ›ne operacje SIMD
@@ -16,10 +17,10 @@ Source0:    https://github.com/google/highway/archive/%{version}/%{name}-%{version}
 Patch0:                %{name}-rdtscp.patch
 URL:           https://github.com/google/highway
 BuildRequires: cmake >= 3.10
-BuildRequires: gtest-devel
+%{?with_tests:BuildRequires:   gtest-devel}
 BuildRequires: libstdc++-devel >= 6:4.7
 BuildRequires: rpm-build >= 4.6
-BuildRequires: rpmbuild(macros) >= 1.605
+BuildRequires: rpmbuild(macros) >= 1.742
 BuildRoot:     %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
 %description
@@ -90,6 +91,7 @@ Dokumentacja API biblioteki Highway.
 install -d build
 cd build
 %cmake .. \
+       %{cmake_on_off tests BUILD_TESTING} \
        -DCMAKE_INSTALL_INCLUDEDIR=include \
        -DCMAKE_INSTALL_LIBDIR=%{_lib} \
        -DHWY_SYSTEM_GTEST=ON
This page took 0.170725 seconds and 4 git commands to generate.