summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlexander Kanavin <alex.kanavin@gmail.com>2020-12-03 14:37:18 +0100
committerRichard Purdie <richard.purdie@linuxfoundation.org>2020-12-09 12:20:33 +0000
commit5a6aaf745f52feac5697149c7dfdaf82bb07274b (patch)
tree622a335120253491d06fe9ba4c36a8865ec1749a
parent826b12792bba1af0f78ed494fbd1e905a1a3ea9b (diff)
downloadpoky-5a6aaf745f52feac5697149c7dfdaf82bb07274b.tar.gz
kea: fix reproducibility
(From OE-Core rev: 5f486c39a766f921fb4374165b6e342dd87244ec) Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r--meta/recipes-connectivity/kea/files/0001-src-lib-log-logger_unittest_support.cc-do-not-write-.patch27
-rw-r--r--meta/recipes-connectivity/kea/kea_1.7.10.bb29
2 files changed, 44 insertions, 12 deletions
diff --git a/meta/recipes-connectivity/kea/files/0001-src-lib-log-logger_unittest_support.cc-do-not-write-.patch b/meta/recipes-connectivity/kea/files/0001-src-lib-log-logger_unittest_support.cc-do-not-write-.patch
new file mode 100644
index 0000000000..226bc5b311
--- /dev/null
+++ b/meta/recipes-connectivity/kea/files/0001-src-lib-log-logger_unittest_support.cc-do-not-write-.patch
@@ -0,0 +1,27 @@
1From 9985a03f13da4d7bb0a433f7305d2ffae3d82a27 Mon Sep 17 00:00:00 2001
2From: Alexander Kanavin <alex.kanavin@gmail.com>
3Date: Tue, 10 Nov 2020 15:57:03 +0000
4Subject: [PATCH] src/lib/log/logger_unittest_support.cc: do not write build
5 path into binary
6
7This breaks reproducibility and is needed only in unit testing.
8
9Upstream-Status: Inappropriate [oe-core specific]
10Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
11---
12 src/lib/log/logger_unittest_support.cc | 2 +-
13 1 file changed, 1 insertion(+), 1 deletion(-)
14
15diff --git a/src/lib/log/logger_unittest_support.cc b/src/lib/log/logger_unittest_support.cc
16index 58dbef8..9a2929c 100644
17--- a/src/lib/log/logger_unittest_support.cc
18+++ b/src/lib/log/logger_unittest_support.cc
19@@ -84,7 +84,7 @@ void initLogger(isc::log::Severity severity, int dbglevel) {
20 const char* localfile = getenv("KEA_LOGGER_LOCALMSG");
21
22 // Set a directory for creating lockfiles when running tests
23- setenv("KEA_LOCKFILE_DIR", TOP_BUILDDIR, 0);
24+ //setenv("KEA_LOCKFILE_DIR", TOP_BUILDDIR, 0);
25
26 // Initialize logging
27 initLogger(root, isc::log::DEBUG, isc::log::MAX_DEBUG_LEVEL, localfile);
diff --git a/meta/recipes-connectivity/kea/kea_1.7.10.bb b/meta/recipes-connectivity/kea/kea_1.7.10.bb
index 1d011ace78..c9a11908e5 100644
--- a/meta/recipes-connectivity/kea/kea_1.7.10.bb
+++ b/meta/recipes-connectivity/kea/kea_1.7.10.bb
@@ -7,18 +7,18 @@ LIC_FILES_CHKSUM = "file://COPYING;md5=68d95543d2096459290a4e6b9ceccffa"
7 7
8DEPENDS = "boost log4cplus openssl" 8DEPENDS = "boost log4cplus openssl"
9 9
10SRC_URI = "\ 10SRC_URI = "http://ftp.isc.org/isc/kea/${PV}/${BP}.tar.gz \
11 http://ftp.isc.org/isc/kea/${PV}/${BP}.tar.gz \ 11 file://0001-keactrl.in-create-var-lib-kea-and-var-run-kea-folder.patch \
12 file://0001-keactrl.in-create-var-lib-kea-and-var-run-kea-folder.patch \ 12 file://kea-dhcp4.service \
13 file://kea-dhcp4.service \ 13 file://kea-dhcp6.service \
14 file://kea-dhcp6.service \ 14 file://kea-dhcp-ddns.service \
15 file://kea-dhcp-ddns.service \ 15 file://kea-dhcp4-server \
16 file://kea-dhcp4-server \ 16 file://kea-dhcp6-server \
17 file://kea-dhcp6-server \ 17 file://kea-dhcp-ddns-server \
18 file://kea-dhcp-ddns-server \ 18 file://fix-multilib-conflict.patch \
19 file://fix-multilib-conflict.patch \ 19 file://fix_pid_keactrl.patch \
20 file://fix_pid_keactrl.patch \ 20 file://0001-src-lib-log-logger_unittest_support.cc-do-not-write-.patch \
21" 21 "
22SRC_URI[sha256sum] = "4e121f0e58b175a827581c69cb1d60778647049fa47f142940dddc9ce58f3c82" 22SRC_URI[sha256sum] = "4e121f0e58b175a827581c69cb1d60778647049fa47f142940dddc9ce58f3c82"
23 23
24inherit autotools systemd update-rc.d upstream-version-is-even 24inherit autotools systemd update-rc.d upstream-version-is-even
@@ -50,6 +50,11 @@ do_configure_prepend() {
50 sed -i "s:@abs_top_srcdir@:@abs_top_srcdir_placeholder@:g" ${S}/src/bin/admin/kea-admin.in 50 sed -i "s:@abs_top_srcdir@:@abs_top_srcdir_placeholder@:g" ${S}/src/bin/admin/kea-admin.in
51} 51}
52 52
53# patch out build host paths for reproducibility
54do_compile_prepend_class-target() {
55 sed -i -e "s,${WORKDIR},,g" ${B}/config.report
56}
57
53do_install_append() { 58do_install_append() {
54 install -d ${D}${sysconfdir}/init.d 59 install -d ${D}${sysconfdir}/init.d
55 install -d ${D}${systemd_system_unitdir} 60 install -d ${D}${systemd_system_unitdir}