diff --git a/jsoncpp.changes b/jsoncpp.changes index 2cadfb3..066e802 100644 --- a/jsoncpp.changes +++ b/jsoncpp.changes @@ -3,6 +3,7 @@ Mon Jan 2 15:42:49 UTC 2017 - mpluskal@suse.com - Update to version 1.8.0: * Build related changes, minimal required cmake is 3.1 +- Execute tests in check section ------------------------------------------------------------------- Fri Oct 14 06:59:15 UTC 2016 - olaf@aepfle.de diff --git a/jsoncpp.spec b/jsoncpp.spec index 2cb9c19..e523714 100644 --- a/jsoncpp.spec +++ b/jsoncpp.spec @@ -25,7 +25,7 @@ License: MIT Group: Development/Libraries/C and C++ Url: https://github.com/open-source-parsers/jsoncpp Source0: https://github.com/open-source-parsers/%{name}/archive/%{version}.tar.gz#/%{name}-%{version}.tar.gz -BuildRequires: cmake >= 3.1.0 +BuildRequires: cmake >= 3.1 BuildRequires: gcc-c++ BuildRequires: pkgconfig BuildRoot: %{_tmppath}/%{name}-%{version}-build @@ -71,14 +71,18 @@ format to store user input files. %build %cmake \ - -DJSONCPP_WITH_CMAKE_PACKAGE=ON -# path needs to be exported otherwise unit tests will fail -export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:%{_builddir}/%{name}-%{version}/build/src/lib_json + -DBUILD_STATIC_LIBS=OFF \ + -DJSONCPP_WITH_CMAKE_PACKAGE=ON \ + -DJSONCPP_WITH_POST_BUILD_UNITTEST=OFF %make_jobs %install %cmake_install -rm -rf %{buildroot}%{_libdir}/lib%{name}.a + +%check +# path needs to be exported otherwise unit tests will fail +export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:%{_builddir}/%{name}-%{version}/build/src/lib_json +./build/src/test_lib_json/jsoncpp_test %post -n lib%{name}%{sover} -p /sbin/ldconfig %postun -n lib%{name}%{sover} -p /sbin/ldconfig