+
+%if "%{run_tests}" == "1"
+ %define __spec_check_pre %___build_pre
+ %define check %%check
+%endif
+
+
Name: libxml2
-Version: 2.8.0
+Version: 2.9.7
Release: 0
Summary: A Library to Manipulate XML Files
License: MIT
# Source ftp://xmlsoft.org/libxml2/libxml2-git-snapshot.tar.gz changes every day
Source: ftp://xmlsoft.org/libxml2/%{name}-%{version}.tar.gz
Source2: baselibs.conf
+Source1001: libxml2.manifest
BuildRequires: pkg-config
BuildRequires: readline-devel
BuildRequires: xz-devel
%prep
%setup -q
+cp %{SOURCE1001} .
%build
%configure --disable-static \
make %{?_smp_mflags} BASE_DIR="%_docdir" DOC_MODULE="%name"
%check
-# qemu-arm can't keep up atm, disabling check for arm
-%ifnarch %arm
-make check
-%endif
+rm -f /tmp/%{name}_test
+%__make runtests | tee -i /tmp/%{name}_log
+cat /tmp/%{name}_log | grep "^TEST: " > /tmp/%{name}_test
+chmod +x ./run_test.sh
+./run_test.sh %{name} %{version}
+rm -f /tmp/%{name}_log
+
%install
make install DESTDIR="%buildroot" BASE_DIR="%_docdir" DOC_MODULE="%name"
%postun -p /sbin/ldconfig
-%files
+%files
+%manifest %{name}.manifest
%defattr(-, root, root)
-%license COPYING*
+%license Copyright
%{_libdir}/lib*.so.*
%files tools
+%manifest %{name}.manifest
%defattr(-, root, root)
+%license Copyright
%{_bindir}/xmllint
%{_bindir}/xmlcatalog
%files devel
+%manifest %{name}.manifest
%defattr(-, root, root)
+%license Copyright
%{_bindir}/xml2-config
%dir %{_datadir}/aclocal
%{_datadir}/aclocal/libxml.m4
%{_libdir}/libxml2.la
%{_libdir}/*.sh
%{_libdir}/pkgconfig/*.pc
+%{_libdir}/cmake/libxml2/libxml2-config.cmake
%changelog