diff --git a/googletest-rpmlintrc b/googletest-rpmlintrc index 8d93323..a4ad7f2 100644 --- a/googletest-rpmlintrc +++ b/googletest-rpmlintrc @@ -1,6 +1,4 @@ # Since the main package is a devel package: -addFilter("devel-file-in-non-devel-package") -# Symlinks are intentionally not generated for the SO: -addFilter("shlib-policy-missing-suffix") +addFilter("non-devel-file-in-devel-package") # The package doesn't provide any libraries anymore: addFilter("obsolete-not-provided libgoogletest0") \ No newline at end of file diff --git a/googletest.changes b/googletest.changes index 898bb40..1fa79f5 100644 --- a/googletest.changes +++ b/googletest.changes @@ -1,3 +1,10 @@ +------------------------------------------------------------------- +Wed Feb 2 15:56:01 UTC 2022 - Stefan Brüns + +- Add missing ldconfig calls in %post/%postun +- Enable unit tests on Tumbleweed (fails on 15.x) +- Update rpmlintrc for rpmlint 2.0 + ------------------------------------------------------------------- Wed Jan 5 09:15:53 UTC 2022 - Dirk Müller diff --git a/googletest.spec b/googletest.spec index 8657cea..bcd0357 100644 --- a/googletest.spec +++ b/googletest.spec @@ -16,6 +16,12 @@ # +%if 0%{?suse_version} >= 1550 +%bcond_without tests +%else +%bcond_with tests +%endif + %define _name googlemock Name: googletest Version: 1.11.0 @@ -77,8 +83,11 @@ with googlemock. %setup -q -n %{name}-release-%{version} %build -%cmake -%make_jobs +%cmake \ + %{?with_tests:-Dgtest_build_tests=ON} \ + %{?with_tests:-Dgmock_build_tests=ON} \ + %{nil} +%cmake_build %install %cmake_install @@ -86,6 +95,16 @@ with googlemock. mkdir -p %{buildroot}%{_includedir}/gmock/src && install -m 0644 googlemock/src/* %{buildroot}%{_includedir}/gmock/src mkdir -p %{buildroot}%{_includedir}/gtest/src && install -m 0644 googletest/src/* %{buildroot}%{_includedir}/gtest/src +%check +%if %{with tests} +%ctest +%endif + +%post -n gtest -p /sbin/ldconfig +%postun -n gtest -p /sbin/ldconfig +%post -n gmock -p /sbin/ldconfig +%postun -n gmock -p /sbin/ldconfig + %files -n gtest %license LICENSE %doc README.md