Extracted conditionals from SUSE rpm spec file to forward port.
Original work done by Thorsten Behrens <tbehrens@suse.com>
Signed-off-by: Owen Synge <osynge@suse.com>
%bcond_with ocf
%bcond_without cephfs_java
+%bcond_with tests
%if (0%{?el5} || (0%{?rhel_version} >= 500 && 0%{?rhel_version} <= 600))
%{!?python_sitelib: %global python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print(get_python_lib())")}
make -j$(getconf _NPROCESSORS_ONLN)
+
+%if 0%{with tests}
+%check
+# run in-tree unittests
+make -j$(getconf _NPROCESSORS_ONLN) check-local
+
+%endif
+
+
+
%install
make DESTDIR=$RPM_BUILD_ROOT install
find $RPM_BUILD_ROOT -type f -name "*.la" -exec rm -f {} ';'