diff options
Diffstat (limited to 'meta/recipes-rt/rt-tests')
-rw-r--r-- | meta/recipes-rt/rt-tests/files/0001-rt-tests-Allow-for-user-specified-PYLIB.patch | 35 | ||||
-rw-r--r-- | meta/recipes-rt/rt-tests/files/0002-rt-tests-Break-out-install_hwlatdetect.patch | 68 | ||||
-rw-r--r-- | meta/recipes-rt/rt-tests/files/Makefile-fix-gzip-command.patch | 30 | ||||
-rw-r--r-- | meta/recipes-rt/rt-tests/files/added-missing-dependencies.patch | 42 | ||||
-rw-r--r-- | meta/recipes-rt/rt-tests/files/fix-re-install-failure.patch | 48 | ||||
-rw-r--r-- | meta/recipes-rt/rt-tests/files/hackbench-fix-error-check.patch | 41 | ||||
-rwxr-xr-x | meta/recipes-rt/rt-tests/files/rt_bmark.py | 34 | ||||
-rw-r--r-- | meta/recipes-rt/rt-tests/files/run-ptest | 2 | ||||
-rw-r--r-- | meta/recipes-rt/rt-tests/hwlatdetect_1.1.bb (renamed from meta/recipes-rt/rt-tests/hwlatdetect_0.92.bb) | 7 | ||||
-rw-r--r-- | meta/recipes-rt/rt-tests/rt-tests-1.1/0001-gzip-with-n-for-build-reproducibilty.patch | 62 | ||||
-rw-r--r-- | meta/recipes-rt/rt-tests/rt-tests.inc | 20 | ||||
-rw-r--r-- | meta/recipes-rt/rt-tests/rt-tests_1.1.bb (renamed from meta/recipes-rt/rt-tests/rt-tests_0.92.bb) | 10 |
12 files changed, 99 insertions, 300 deletions
diff --git a/meta/recipes-rt/rt-tests/files/0001-rt-tests-Allow-for-user-specified-PYLIB.patch b/meta/recipes-rt/rt-tests/files/0001-rt-tests-Allow-for-user-specified-PYLIB.patch deleted file mode 100644 index 8b493eb1f1..0000000000 --- a/meta/recipes-rt/rt-tests/files/0001-rt-tests-Allow-for-user-specified-PYLIB.patch +++ /dev/null @@ -1,35 +0,0 @@ -From 66765522b634952346f1a3ab7d00c7222a1f9361 Mon Sep 17 00:00:00 2001 -Message-Id: <66765522b634952346f1a3ab7d00c7222a1f9361.1347419597.git.dvhart@linux.intel.com> -From: Darren Hart <dvhart@linux.intel.com> -Date: Tue, 11 Sep 2012 15:19:30 -0700 -Subject: [PATCH 1/2] rt-tests: Allow for user-specified PYLIB - -Upstream-Status: Submitted - -Allow users (build systems) to specify PYLIB. This allows for a -cross-build-system to specify the target PYLIB rather than the host -PYLIB. - -Signed-off-by: Darren Hart <dvhart@linux.intel.com> -CC: Clark Williams <williams@redhat.com> -CC: John Kacur <jkacur@redhat.com> ---- - Makefile | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/Makefile b/Makefile -index 3a82407..61e2f9f 100644 ---- a/Makefile -+++ b/Makefile -@@ -23,7 +23,7 @@ endif - CFLAGS ?= -D_GNU_SOURCE -Wall -Wno-nonnull -Isrc/include - LDFLAGS ?= - --PYLIB := $(shell python -c 'import distutils.sysconfig; print distutils.sysconfig.get_python_lib()') -+PYLIB ?= $(shell python -c 'import distutils.sysconfig; print distutils.sysconfig.get_python_lib()') - - ifndef DEBUG - CFLAGS += -O2 --- -1.7.11.4 - diff --git a/meta/recipes-rt/rt-tests/files/0002-rt-tests-Break-out-install_hwlatdetect.patch b/meta/recipes-rt/rt-tests/files/0002-rt-tests-Break-out-install_hwlatdetect.patch deleted file mode 100644 index bc6136f1de..0000000000 --- a/meta/recipes-rt/rt-tests/files/0002-rt-tests-Break-out-install_hwlatdetect.patch +++ /dev/null @@ -1,68 +0,0 @@ -From af93e580d005a2bba6ed36528003af4cf631adb8 Mon Sep 17 00:00:00 2001 -Message-Id: <af93e580d005a2bba6ed36528003af4cf631adb8.1347419597.git.dvhart@linux.intel.com> -In-Reply-To: <66765522b634952346f1a3ab7d00c7222a1f9361.1347419597.git.dvhart@linux.intel.com> -References: <66765522b634952346f1a3ab7d00c7222a1f9361.1347419597.git.dvhart@linux.intel.com> -From: Darren Hart <dvhart@linux.intel.com> -Date: Tue, 11 Sep 2012 14:51:10 -0700 -Subject: [PATCH 2/2] rt-tests: Break out install_hwlatdetect - -Upstream-Status: Submitted - -Allow hwlatdetect to be installed independently of the rest of the -tests. This is convenient for build systems that package it separately -due to the python dependency. - -Signed-off-by: Darren Hart <dvhart@linux.intel.com> -CC: Clark Williams <williams@redhat.com> -CC: John Kacur <jkacur@redhat.com> ---- - Makefile | 18 +++++++++++------- - 1 file changed, 11 insertions(+), 7 deletions(-) - -diff --git a/Makefile b/Makefile -index 61e2f9f..636e63b 100644 ---- a/Makefile -+++ b/Makefile -@@ -119,21 +119,15 @@ changelog: - git log >ChangeLog - - .PHONY: install --install: all -+install: all install_hwlatdetect - mkdir -p "$(DESTDIR)$(bindir)" "$(DESTDIR)$(mandir)/man4" - mkdir -p "$(DESTDIR)$(srcdir)" "$(DESTDIR)$(mandir)/man8" - cp $(TARGETS) "$(DESTDIR)$(bindir)" -- if test -n "$(PYLIB)" ; then \ -- install -D -m 755 src/hwlatdetect/hwlatdetect.py $(DESTDIR)$(PYLIB)/hwlatdetect.py ; \ -- rm -f "$(DESTDIR)$(bindir)/hwlatdetect" ; \ -- ln -s $(PYLIB)/hwlatdetect.py "$(DESTDIR)$(bindir)/hwlatdetect" ; \ -- fi - install -D -m 644 src/backfire/backfire.c "$(DESTDIR)$(srcdir)/backfire/backfire.c" - install -m 644 src/backfire/Makefile "$(DESTDIR)$(srcdir)/backfire/Makefile" - gzip src/backfire/backfire.4 -c >"$(DESTDIR)$(mandir)/man4/backfire.4.gz" - gzip src/cyclictest/cyclictest.8 -c >"$(DESTDIR)$(mandir)/man8/cyclictest.8.gz" - gzip src/pi_tests/pi_stress.8 -c >"$(DESTDIR)$(mandir)/man8/pi_stress.8.gz" -- gzip src/hwlatdetect/hwlatdetect.8 -c >"$(DESTDIR)$(mandir)/man8/hwlatdetect.8.gz" - gzip src/ptsematest/ptsematest.8 -c >"$(DESTDIR)$(mandir)/man8/ptsematest.8.gz" - gzip src/sigwaittest/sigwaittest.8 -c >"$(DESTDIR)$(mandir)/man8/sigwaittest.8.gz" - gzip src/svsematest/svsematest.8 -c >"$(DESTDIR)$(mandir)/man8/svsematest.8.gz" -@@ -141,6 +135,16 @@ install: all - gzip src/backfire/sendme.8 -c >"$(DESTDIR)$(mandir)/man8/sendme.8.gz" - gzip src/hackbench/hackbench.8 -c >"$(DESTDIR)$(mandir)/man8/hackbench.8.gz" - -+.PHONY: install_hwlatdetect -+install_hwlatdetect: hwlatdetect -+ if test -n "$(PYLIB)" ; then \ -+ mkdir -p "$(DESTDIR)$(bindir)" "$(DESTDIR)$(mandir)/man8" ; \ -+ install -D -m 755 src/hwlatdetect/hwlatdetect.py $(DESTDIR)$(PYLIB)/hwlatdetect.py ; \ -+ rm -f "$(DESTDIR)$(bindir)/hwlatdetect" ; \ -+ ln -s $(PYLIB)/hwlatdetect.py "$(DESTDIR)$(bindir)/hwlatdetect" ; \ -+ gzip src/hwlatdetect/hwlatdetect.8 -c >"$(DESTDIR)$(mandir)/man8/hwlatdetect.8.gz" ; \ -+ fi -+ - .PHONY: release - release: clean changelog - mkdir -p releases --- -1.7.11.4 - diff --git a/meta/recipes-rt/rt-tests/files/Makefile-fix-gzip-command.patch b/meta/recipes-rt/rt-tests/files/Makefile-fix-gzip-command.patch deleted file mode 100644 index 0a35ddc740..0000000000 --- a/meta/recipes-rt/rt-tests/files/Makefile-fix-gzip-command.patch +++ /dev/null @@ -1,30 +0,0 @@ -From 07b5ed42d7041ccc084889eaa96817aa097bf461 Mon Sep 17 00:00:00 2001 -From: Robert Yang <liezhi.yang@windriver.com> -Date: Tue, 3 Feb 2015 03:10:25 +0000 -Subject: [PATCH] Makefile: fix gzip command - -The "-c" doesn't work in command "gzip file -c", need use "gzip -c file" - -Upstream-Status: Pending - -Signed-off-by: Robert Yang <liezhi.yang@windriver.com> ---- - Makefile | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/Makefile b/Makefile -index 219a591..c7d147a 100644 ---- a/Makefile -+++ b/Makefile -@@ -144,7 +144,7 @@ install_hwlatdetect: hwlatdetect - install -D -m 755 src/hwlatdetect/hwlatdetect.py $(DESTDIR)$(PYLIB)/hwlatdetect.py ; \ - rm -f "$(DESTDIR)$(bindir)/hwlatdetect" ; \ - ln -s $(PYLIB)/hwlatdetect.py "$(DESTDIR)$(bindir)/hwlatdetect" ; \ -- gzip src/hwlatdetect/hwlatdetect.8 -c >"$(DESTDIR)$(mandir)/man8/hwlatdetect.8.gz" ; \ -+ gzip -c src/hwlatdetect/hwlatdetect.8 >"$(DESTDIR)$(mandir)/man8/hwlatdetect.8.gz" ; \ - fi - - .PHONY: release --- -2.0.1 - diff --git a/meta/recipes-rt/rt-tests/files/added-missing-dependencies.patch b/meta/recipes-rt/rt-tests/files/added-missing-dependencies.patch deleted file mode 100644 index 0bf768eb9d..0000000000 --- a/meta/recipes-rt/rt-tests/files/added-missing-dependencies.patch +++ /dev/null @@ -1,42 +0,0 @@ -From 3f948f22d9106a2b957d1d430b16a7c51ccfc067 Mon Sep 17 00:00:00 2001 -From: "Maxin B. John" <maxin.john@enea.com> -Date: Tue, 16 Jun 2015 22:53:23 +0200 -Subject: [PATCH] Added missing dependencies - -Upstream-Status: Submitted [linux-rt-users] - -The following targets missed dependency on librttest.a: -rt-migrate-test -hackbench - -Signed-off-by: Jackie Huang <jackie.huang@windriver.com> -Signed-off-by: Maxin B. John <maxin.john@enea.com> ---- - Makefile | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) - -diff --git a/Makefile b/Makefile -index a48e759..7a3f192 100644 ---- a/Makefile -+++ b/Makefile -@@ -85,7 +85,7 @@ hwlatdetect: src/hwlatdetect/hwlatdetect.py - chmod +x src/hwlatdetect/hwlatdetect.py - ln -s src/hwlatdetect/hwlatdetect.py hwlatdetect - --rt-migrate-test: rt-migrate-test.o -+rt-migrate-test: rt-migrate-test.o librttest.a - $(CC) $(CFLAGS) $(LDFLAGS) -o $@ $< $(LIBS) - - ptsematest: ptsematest.o librttest.a -@@ -106,7 +106,7 @@ sendme: sendme.o librttest.a - pip_stress: pip_stress.o librttest.a - $(CC) $(CFLAGS) $(LDFLAGS) -o $@ $< $(LIBS) $(RTTESTLIB) - --hackbench: hackbench.o -+hackbench: hackbench.o librttest.a - $(CC) $(CFLAGS) $(LDFLAGS) -o $@ $< $(LIBS) - - librttest.a: rt-utils.o error.o rt-get_cpu.o rt-sched.o --- -1.9.1 - diff --git a/meta/recipes-rt/rt-tests/files/fix-re-install-failure.patch b/meta/recipes-rt/rt-tests/files/fix-re-install-failure.patch deleted file mode 100644 index e38ec92c05..0000000000 --- a/meta/recipes-rt/rt-tests/files/fix-re-install-failure.patch +++ /dev/null @@ -1,48 +0,0 @@ -Currently gzip on host is used. If host gzip is provided by pigz, it fails to -redo install that pigz can't handle the option after file name. When run: - -gzip src/backfire/backfire.4 -c > OUTPUT_FILE - -File src/backfire/backfire.4 is zipped into backfire.4.gz but the OUTPUT_FILE -is empty. When rerun do_install, it shows warning: - -| gzip: src/backfire/backfire.4 does not exist -- skipping - -and empty manual gzip files are created: - -$ file image/usr/share/man/man4/backfire.4.gz -image/usr/share/man/man4/backfire.4.gz: empty - -Fix it by putting option '-c' before the file name. - -Upstream-Status: Pending - -Signed-off-by: Kai Kang <kai.kang@windriver.com> ---- ---- git/Makefile.orig 2014-11-14 15:47:26.406638419 +0800 -+++ git/Makefile 2014-11-14 15:46:53.890637533 +0800 -@@ -127,15 +127,15 @@ - cp $(TARGETS) "$(DESTDIR)$(bindir)" - install -D -m 644 src/backfire/backfire.c "$(DESTDIR)$(srcdir)/backfire/backfire.c" - install -m 644 src/backfire/Makefile "$(DESTDIR)$(srcdir)/backfire/Makefile" -- gzip src/backfire/backfire.4 -c >"$(DESTDIR)$(mandir)/man4/backfire.4.gz" -- gzip src/cyclictest/cyclictest.8 -c >"$(DESTDIR)$(mandir)/man8/cyclictest.8.gz" -- gzip src/pi_tests/pi_stress.8 -c >"$(DESTDIR)$(mandir)/man8/pi_stress.8.gz" -- gzip src/ptsematest/ptsematest.8 -c >"$(DESTDIR)$(mandir)/man8/ptsematest.8.gz" -- gzip src/sigwaittest/sigwaittest.8 -c >"$(DESTDIR)$(mandir)/man8/sigwaittest.8.gz" -- gzip src/svsematest/svsematest.8 -c >"$(DESTDIR)$(mandir)/man8/svsematest.8.gz" -- gzip src/pmqtest/pmqtest.8 -c >"$(DESTDIR)$(mandir)/man8/pmqtest.8.gz" -- gzip src/backfire/sendme.8 -c >"$(DESTDIR)$(mandir)/man8/sendme.8.gz" -- gzip src/hackbench/hackbench.8 -c >"$(DESTDIR)$(mandir)/man8/hackbench.8.gz" -+ gzip -c src/backfire/backfire.4 >"$(DESTDIR)$(mandir)/man4/backfire.4.gz" -+ gzip -c src/cyclictest/cyclictest.8 >"$(DESTDIR)$(mandir)/man8/cyclictest.8.gz" -+ gzip -c src/pi_tests/pi_stress.8 >"$(DESTDIR)$(mandir)/man8/pi_stress.8.gz" -+ gzip -c src/ptsematest/ptsematest.8 >"$(DESTDIR)$(mandir)/man8/ptsematest.8.gz" -+ gzip -c src/sigwaittest/sigwaittest.8 >"$(DESTDIR)$(mandir)/man8/sigwaittest.8.gz" -+ gzip -c src/svsematest/svsematest.8 >"$(DESTDIR)$(mandir)/man8/svsematest.8.gz" -+ gzip -c src/pmqtest/pmqtest.8 >"$(DESTDIR)$(mandir)/man8/pmqtest.8.gz" -+ gzip -c src/backfire/sendme.8 >"$(DESTDIR)$(mandir)/man8/sendme.8.gz" -+ gzip -c src/hackbench/hackbench.8 >"$(DESTDIR)$(mandir)/man8/hackbench.8.gz" - - .PHONY: install_hwlatdetect - install_hwlatdetect: hwlatdetect diff --git a/meta/recipes-rt/rt-tests/files/hackbench-fix-error-check.patch b/meta/recipes-rt/rt-tests/files/hackbench-fix-error-check.patch deleted file mode 100644 index d17fdff455..0000000000 --- a/meta/recipes-rt/rt-tests/files/hackbench-fix-error-check.patch +++ /dev/null @@ -1,41 +0,0 @@ -childinfo_t is a union that contains both signed (error) and unsigned -(threadid) members. Thus a large threadid could appear as a negative error -value, which will cause unexpected failures. - -childinfo_t should be changed to a struct, but it could potentially affect the -performance. So we keep it as a union but only check error against -1. There is -still a chance of false alarm but it's small. - -Upstream-Status: Pending - -Signed-off-by: Song.Li <Song.Li@windriver.com> -Signed-off-by: Jesse Zhang <sen.zhang@windriver.com> ---- - src/hackbench/hackbench.c | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) - -diff --git a/src/hackbench/hackbench.c b/src/hackbench/hackbench.c -index 8baeb23..dc0de8f 100644 ---- a/src/hackbench/hackbench.c -+++ b/src/hackbench/hackbench.c -@@ -317,7 +317,7 @@ static unsigned int group(childinfo_t *child, - ctx->wakefd = wakefd; - - child[tab_offset+i] = create_worker(ctx, (void *)(void *)receiver); -- if( child[tab_offset+i].error < 0 ) { -+ if( child[tab_offset+i].error == -1 ) { - return (i > 0 ? i-1 : 0); - } - snd_ctx->out_fds[i] = fds[1]; -@@ -332,7 +332,7 @@ static unsigned int group(childinfo_t *child, - snd_ctx->num_fds = num_fds; - - child[tab_offset+num_fds+i] = create_worker(snd_ctx, (void *)(void *)sender); -- if( child[tab_offset+num_fds+i].error < 0 ) { -+ if( child[tab_offset+num_fds+i].error == -1 ) { - return (num_fds+i)-1; - } - } --- -1.7.9.5 - diff --git a/meta/recipes-rt/rt-tests/files/rt_bmark.py b/meta/recipes-rt/rt-tests/files/rt_bmark.py index e2280e43e2..3b84447a0f 100755 --- a/meta/recipes-rt/rt-tests/files/rt_bmark.py +++ b/meta/recipes-rt/rt-tests/files/rt_bmark.py @@ -1,4 +1,4 @@ -#!/usr/bin/python +#!/usr/bin/env python3 # -*- coding: utf-8 -*- # SPDX-License-Identifier: BSD-3-Clause @@ -106,8 +106,8 @@ def tc_name(sub_name): def log(*msg): tmp = "".join(map(str, msg)) # 'map(str, ...' allows numbers - for line in tmp.split("\n"): - print "#", line + for line in tmp.splitlines(): + print("#", line) #------------------------------------------------------------------------------- # Like log(), but with a timestamp added @@ -130,7 +130,7 @@ def log_test_header(seq_no, nr_of_tests, name): #------------------------------------------------------------------------------- def start_stress(*args): - stress_cmd = [ "stress" ] + stress_cmd = [ "stress-ng" ] added_stress_types = [] req_stress_types = set(args) cpu_cnt = str(multiprocessing.cpu_count()) @@ -166,12 +166,12 @@ def start_stress(*args): log(" Command: '", stress_cmd_str, "'") log() - # preexec_fn=os.setsid causes stress to be executed in a separate + # start_new_session causes stress to be executed in a separate # session, => it gets a new process group (incl. children). It # can then be terminated using os.killpg in end_stress without # terminating this script. - p = subprocess.Popen(stress_cmd, preexec_fn=os.setsid) + p = subprocess.Popen(stress_cmd, start_new_session=True) return p @@ -265,7 +265,7 @@ cmd = ("cyclictest", "-d", str(interval_delta), "-l", str(loop_count) ) -rex = re.compile("C:\s*(\d+).*Min:\s*(\d+).*Avg:\s*(\d+).*Max:\s*(\d+)") +rex = re.compile(b"C:\s*(\d+).*Min:\s*(\d+).*Avg:\s*(\d+).*Max:\s*(\d+)") def run_cyclictest_once(): res = subprocess.check_output(cmd) @@ -283,7 +283,7 @@ def run_cyclictest_once(): avg_sum = 0 avg_cnt = 0 - for line in res.split("\n"): + for line in res.splitlines(): m = rex.search(line) if m is not None: minlist.append(int(m.group(2))) @@ -324,7 +324,7 @@ def run_cyclictest_suite(): t = time.time() max_list = [] - for i in xrange(0, suite_size): + for i in range(0, suite_size): tmp_min, tmp_avg, tmp_max = run_cyclictest_once() msg = "%2d/%2d:" % (i+1, suite_size) @@ -376,11 +376,11 @@ class cyclictest_runner: log() log("PASS") - print - print tc_name(name), "[Min/us,Avg/us,Max/us]:", - print "%d,%.1f,%d" % (bm_min,bm_avg, bm_max) - print "PASS:", tc_name(name) - print + print() + print(tc_name(name), "[Min/us,Avg/us,Max/us]:",) + print("%d,%.1f,%d" % (bm_min,bm_avg, bm_max)) + print("PASS:", tc_name(name)) + print() except Exception: log() @@ -391,9 +391,9 @@ class cyclictest_runner: log("WD: ", os.getcwd()) log() log("FAIL") - print - print "FAIL:", tc_name(name) - print + print() + print("FAIL:", tc_name(name)) + print() #------------------------------------------------------------------------------- diff --git a/meta/recipes-rt/rt-tests/files/run-ptest b/meta/recipes-rt/rt-tests/files/run-ptest index 8e6d3e3588..b7c5e29f2a 100644 --- a/meta/recipes-rt/rt-tests/files/run-ptest +++ b/meta/recipes-rt/rt-tests/files/run-ptest @@ -1,3 +1,3 @@ #!/bin/sh -python ./rt_bmark.py +python3 ./rt_bmark.py diff --git a/meta/recipes-rt/rt-tests/hwlatdetect_0.92.bb b/meta/recipes-rt/rt-tests/hwlatdetect_1.1.bb index 8319eb987a..5f61c4ecdd 100644 --- a/meta/recipes-rt/rt-tests/hwlatdetect_0.92.bb +++ b/meta/recipes-rt/rt-tests/hwlatdetect_1.1.bb @@ -1,11 +1,12 @@ SUMMARY = "Hardware latency detector" DESCRIPTION = "Python utility for controlling the kernel hardware latency detection module (hwlat_detector.ko)." -HOMEPAGE = "http://git.kernel.org/?p=linux/kernel/git/clrkwllms/rt-tests.git" +HOMEPAGE = "https://rt.wiki.kernel.org/index.php/Cyclictest" SECTION = "tests" LICENSE = "GPLv2" LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe" require rt-tests.inc +inherit python3-dir EXTRA_OEMAKE += "PYLIB=${libdir}/python${PYTHON_BASEVERSION}/dist-packages" @@ -16,8 +17,10 @@ do_compile() { do_install() { oe_runmake install_hwlatdetect DESTDIR=${D} SBINDIR=${sbindir} \ MANDIR=${mandir} INCLUDEDIR=${includedir} + + sed -i -e '1s,#!.*python.*,#!${bindir}/python3,' ${D}${libdir}/python${PYTHON_BASEVERSION}/dist-packages/hwlatdetect.py } FILES_${PN} += "${libdir}/python${PYTHON_BASEVERSION}/dist-packages/hwlatdetect.py" -RDEPENDS_${PN} = "python python-subprocess python-textutils" +RDEPENDS_${PN} = "python3-core " RRECOMMENDS_${PN} = "kernel-module-hwlat-detector" diff --git a/meta/recipes-rt/rt-tests/rt-tests-1.1/0001-gzip-with-n-for-build-reproducibilty.patch b/meta/recipes-rt/rt-tests/rt-tests-1.1/0001-gzip-with-n-for-build-reproducibilty.patch new file mode 100644 index 0000000000..3bafbbe08f --- /dev/null +++ b/meta/recipes-rt/rt-tests/rt-tests-1.1/0001-gzip-with-n-for-build-reproducibilty.patch @@ -0,0 +1,62 @@ +From aabf518e2e61a882b925f9d2ac53dafa7a041a0a Mon Sep 17 00:00:00 2001 +From: Jeremy Puhlman <jpuhlman@mvista.com> +Date: Tue, 25 Feb 2020 22:58:59 +0000 +Subject: [PATCH] gzip with -n for build reproducibilty + +The date can get encoded in the header of the gz file, which +causes the binary files between two different builds of the +same data to be different. Add -n for reproducibilty + +Signed-off-by: Jeremy Puhlman <jpuhlman@mvista.com> + +Upstream-Status: Submitted [mailinglist] + +--- + Makefile | 24 ++++++++++++------------ + 1 file changed, 12 insertions(+), 12 deletions(-) + +diff --git a/Makefile b/Makefile +index a54d82b..e9f0d5a 100644 +--- a/Makefile ++++ b/Makefile +@@ -168,17 +168,17 @@ install: all install_hwlatdetect + cp $(TARGETS) "$(DESTDIR)$(bindir)" + install -D -m 644 src/backfire/backfire.c "$(DESTDIR)$(srcdir)/backfire/backfire.c" + install -m 644 src/backfire/Makefile "$(DESTDIR)$(srcdir)/backfire/Makefile" +- gzip -c src/backfire/backfire.4 >"$(DESTDIR)$(mandir)/man4/backfire.4.gz" +- gzip -c src/cyclictest/cyclictest.8 >"$(DESTDIR)$(mandir)/man8/cyclictest.8.gz" +- gzip -c src/pi_tests/pi_stress.8 >"$(DESTDIR)$(mandir)/man8/pi_stress.8.gz" +- gzip -c src/ptsematest/ptsematest.8 >"$(DESTDIR)$(mandir)/man8/ptsematest.8.gz" +- gzip -c src/rt-migrate-test/rt-migrate-test.8 >"$(DESTDIR)$(mandir)/man8/rt-migrate-test.8.gz" +- gzip -c src/sigwaittest/sigwaittest.8 >"$(DESTDIR)$(mandir)/man8/sigwaittest.8.gz" +- gzip -c src/svsematest/svsematest.8 >"$(DESTDIR)$(mandir)/man8/svsematest.8.gz" +- gzip -c src/pmqtest/pmqtest.8 >"$(DESTDIR)$(mandir)/man8/pmqtest.8.gz" +- gzip -c src/backfire/sendme.8 >"$(DESTDIR)$(mandir)/man8/sendme.8.gz" +- gzip -c src/hackbench/hackbench.8 >"$(DESTDIR)$(mandir)/man8/hackbench.8.gz" +- gzip -c src/signaltest/signaltest.8 >"$(DESTDIR)$(mandir)/man8/signaltest.8.gz" ++ gzip -nc src/backfire/backfire.4 >"$(DESTDIR)$(mandir)/man4/backfire.4.gz" ++ gzip -nc src/cyclictest/cyclictest.8 >"$(DESTDIR)$(mandir)/man8/cyclictest.8.gz" ++ gzip -nc src/pi_tests/pi_stress.8 >"$(DESTDIR)$(mandir)/man8/pi_stress.8.gz" ++ gzip -nc src/ptsematest/ptsematest.8 >"$(DESTDIR)$(mandir)/man8/ptsematest.8.gz" ++ gzip -nc src/rt-migrate-test/rt-migrate-test.8 >"$(DESTDIR)$(mandir)/man8/rt-migrate-test.8.gz" ++ gzip -nc src/sigwaittest/sigwaittest.8 >"$(DESTDIR)$(mandir)/man8/sigwaittest.8.gz" ++ gzip -nc src/svsematest/svsematest.8 >"$(DESTDIR)$(mandir)/man8/svsematest.8.gz" ++ gzip -nc src/pmqtest/pmqtest.8 >"$(DESTDIR)$(mandir)/man8/pmqtest.8.gz" ++ gzip -nc src/backfire/sendme.8 >"$(DESTDIR)$(mandir)/man8/sendme.8.gz" ++ gzip -nc src/hackbench/hackbench.8 >"$(DESTDIR)$(mandir)/man8/hackbench.8.gz" ++ gzip -nc src/signaltest/signaltest.8 >"$(DESTDIR)$(mandir)/man8/signaltest.8.gz" + + .PHONY: install_hwlatdetect + install_hwlatdetect: hwlatdetect +@@ -187,7 +187,7 @@ install_hwlatdetect: hwlatdetect + install -D -m 755 src/hwlatdetect/hwlatdetect.py $(DESTDIR)$(PYLIB)/hwlatdetect.py ; \ + rm -f "$(DESTDIR)$(bindir)/hwlatdetect" ; \ + ln -s $(PYLIB)/hwlatdetect.py "$(DESTDIR)$(bindir)/hwlatdetect" ; \ +- gzip -c src/hwlatdetect/hwlatdetect.8 >"$(DESTDIR)$(mandir)/man8/hwlatdetect.8.gz" ; \ ++ gzip -nc src/hwlatdetect/hwlatdetect.8 >"$(DESTDIR)$(mandir)/man8/hwlatdetect.8.gz" ; \ + fi + + .PHONY: tarball +-- +2.23.0 + diff --git a/meta/recipes-rt/rt-tests/rt-tests.inc b/meta/recipes-rt/rt-tests/rt-tests.inc index 9a076ad88c..6e3afafce4 100644 --- a/meta/recipes-rt/rt-tests/rt-tests.inc +++ b/meta/recipes-rt/rt-tests/rt-tests.inc @@ -1,20 +1,12 @@ -# Version v0.92 -PV = "0.92" -SRCREV = "5f9f1e3fe327440a9d405f4af8feb16ff7a909eb" +# Version 1.1 +SRCREV = "dff174f994f547a5785d32454865f140daacb0f5" +PE = "1" -SRC_URI = "git://git.kernel.org/pub/scm/linux/kernel/git/clrkwllms/rt-tests.git \ - file://0001-rt-tests-Allow-for-user-specified-PYLIB.patch \ - file://0002-rt-tests-Break-out-install_hwlatdetect.patch \ - file://added-missing-dependencies.patch \ - file://hackbench-fix-error-check.patch \ - file://Makefile-fix-gzip-command.patch \ - file://fix-re-install-failure.patch \ -" +SRC_URI = "git://git.kernel.org/pub/scm/utils/rt-tests/rt-tests.git" +# 1.2 and up seem to be development versions +UPSTREAM_CHECK_GITTAGREGEX = "v(?P<pver>(?!1\.[2-8])(\d+(\.\d+)+))" S = "${WORKDIR}/git" -# need to append rt-tests' default CFLAGS to ours -CFLAGS += "-I${S}/src/include -D_GNU_SOURCE -Wall -Wno-nonnull" - # calling 'uname -m' is broken on crossbuilds EXTRA_OEMAKE = "NUMA=0" diff --git a/meta/recipes-rt/rt-tests/rt-tests_0.92.bb b/meta/recipes-rt/rt-tests/rt-tests_1.1.bb index fbe2f669e8..dad252b4ed 100644 --- a/meta/recipes-rt/rt-tests/rt-tests_0.92.bb +++ b/meta/recipes-rt/rt-tests/rt-tests_1.1.bb @@ -10,9 +10,15 @@ LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe \ require rt-tests.inc inherit ptest -SRC_URI += "file://run-ptest \ +SRC_URI += " \ + file://run-ptest \ file://rt_bmark.py \ + file://0001-gzip-with-n-for-build-reproducibilty.patch \ " + +# rt-tests needs PI mutex support in libc +COMPATIBLE_HOST_libc-musl = 'null' + # Do not install hwlatdetect EXTRA_OEMAKE += "PYLIB=''" @@ -25,6 +31,6 @@ do_install_ptest() { cp ${WORKDIR}/rt_bmark.py ${D}${PTEST_PATH} } -RDEPENDS_${PN}-ptest += " stress python python-subprocess python-multiprocessing python-datetime python-re python-lang" +RDEPENDS_${PN}-ptest += " stress-ng python3 python3-multiprocessing python3-datetime python3-misc" FILES_${PN} += "${prefix}/src/backfire" |