packaging: enable tests
authorPhilippe Coval <philippe.coval@open.eurogiciel.org>
Mon, 3 Mar 2014 15:40:02 +0000 (16:40 +0100)
committerPhilippe Coval <philippe.coval@open.eurogiciel.org>
Mon, 3 Mar 2014 15:40:19 +0000 (16:40 +0100)
Change-Id: I03d485bee9a667510f5d7d39dbbae341be13531f
Signed-off-by: Philippe Coval <philippe.coval@open.eurogiciel.org>
packaging/libinput.spec

index 90fd0f32a4db610c7827e05156af9f2877af1268..bdfbf6b6952708410b2c4ff27170b5e7135c273d 100755 (executable)
@@ -9,6 +9,7 @@ Source:         %{name}-%{version}.tar.gz
 #X-Vcs-Url:      git://anongit.freedesktop.org/wayland/libinput
 
 BuildRequires:  make
+BuildRequires:  pkgconfig(check) >= 0.9.9
 BuildRequires:  pkgconfig(libevdev)
 BuildRequires:  pkgconfig(libevent)
 BuildRequires:  pkgconfig(libudev)
@@ -44,13 +45,24 @@ functionality that users expect.
 %prep
 %setup -q
 
-%autogen
+%autogen \
+    --enable-tests \
+    #eol
 
 %build
 make %{?jobs:-j%jobs} V=1
 
+%check
+make %{?jobs:-j%jobs} tests check V=1
+
 %install
 %make_install
+install -d %{_libdir}/%{name}/test
+install -m 0755 test/test-log %{_libdir}/%{name}/test
+install -m 0755 test/test-path %{_libdir}/%{name}/test
+install -m 0755 test/test-pointer %{_libdir}/%{name}/test
+install -m 0755 test/test-touch %{_libdir}/%{name}/test
+install -m 0755 test/test-udev %{_libdir}/%{name}/test
 
 %post -p /sbin/ldconfig
 
@@ -67,3 +79,7 @@ make %{?jobs:-j%jobs} V=1
 %{_includedir}/*
 %{_libdir}/*.so
 %{_libdir}/pkgconfig/*
+
+%file test
+%{_libdir}/%{name}/test/*
+