[linuxptp] include test suite
Miroslav Lichvar
mlichvar at fedoraproject.org
Fri Feb 21 13:32:41 UTC 2014
commit 930708955aac5def750d94bd7a7cedc314860266
Author: Miroslav Lichvar <mlichvar at redhat.com>
Date: Fri Feb 21 14:20:50 2014 +0100
include test suite
.gitignore | 2 ++
linuxptp.spec | 12 +++++++++++-
sources | 2 ++
3 files changed, 15 insertions(+), 1 deletions(-)
---
diff --git a/.gitignore b/.gitignore
index 2a9aca0..6317cd7 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1 +1,3 @@
/linuxptp-1.4.tgz
+/clknetsim-19a8df.tar.gz
+/testsuite-a1040d.tar.gz
diff --git a/linuxptp.spec b/linuxptp.spec
index ebb45d3..01c8b9a 100644
--- a/linuxptp.spec
+++ b/linuxptp.spec
@@ -12,6 +12,10 @@ URL: http://linuxptp.sourceforge.net/
Source0: http://downloads.sourceforge.net/%{name}/%{name}-%{version}.tgz
Source1: phc2sys.service
Source2: ptp4l.service
+# test suite from https://github.com/mlichvar/linuxptp-testsuite.git
+Source3: testsuite-a1040d.tar.gz
+# simulator for test suite from https://github.com/mlichvar/clknetsim.git
+Source4: clknetsim-19a8df.tar.gz
BuildRequires: systemd-units
@@ -27,7 +31,8 @@ Application Programming Interfaces (API) offered by the Linux kernel.
Supporting legacy APIs and other platforms is not a goal.
%prep
-%setup -q
+%setup -q -a 3 -a 4
+mv clknetsim testsuite
%build
make %{?_smp_mflags} \
@@ -47,6 +52,11 @@ echo 'OPTIONS="-w -s eth0"' > $RPM_BUILD_ROOT%{_sysconfdir}/sysconfig/phc2sys
echo '.so man8/ptp4l.8' > $RPM_BUILD_ROOT%{_mandir}/man5/ptp4l.conf.5
+%check
+cd testsuite
+make %{?_smp_mflags} -C clknetsim
+PATH=..:$PATH ./run
+
%post
%systemd_post ptp4l.service phc2sys.service
diff --git a/sources b/sources
index d3b84c7..a72bd88 100644
--- a/sources
+++ b/sources
@@ -1 +1,3 @@
a37ad2b2ef7d1ebc4d64a66d3fe55cdf linuxptp-1.4.tgz
+8719dab29f5dfbcb123576d5ceb3a4c3 clknetsim-19a8df.tar.gz
+0e45824432e9289e07550ea47ccaac87 testsuite-a1040d.tar.gz
More information about the scm-commits
mailing list