From a732bd776717f14a7b47c0e0ba096b8921dff16d Mon Sep 17 00:00:00 2001 From: Alessio Igor Bogani Date: Fri, 25 Oct 2019 16:01:57 +0200 Subject: systemtap: support usrmerge Signed-off-by: Alessio Igor Bogani Signed-off-by: Ross Burton --- meta/recipes-kernel/systemtap/systemtap_git.bb | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) (limited to 'meta/recipes-kernel') diff --git a/meta/recipes-kernel/systemtap/systemtap_git.bb b/meta/recipes-kernel/systemtap/systemtap_git.bb index 6ee3e1c0f7..1c9f2aed16 100644 --- a/meta/recipes-kernel/systemtap/systemtap_git.bb +++ b/meta/recipes-kernel/systemtap/systemtap_git.bb @@ -51,10 +51,13 @@ do_install_append () { rm ${D}${libexecdir}/${PN}/stap-env fi - # Fix makefile hardcoded path assumptions for systemd (assumes $prefix) - install -d `dirname ${D}${systemd_unitdir}` - mv ${D}${prefix}/lib/systemd `dirname ${D}${systemd_unitdir}` - rmdir ${D}${prefix}/lib --ignore-fail-on-non-empty + if [ ${D}${prefix}/lib != `dirname ${D}${systemd_unitdir}` ]; then + # Fix makefile hardcoded path assumptions for systemd (assumes $prefix) + # without usrmerge distro feature enabled + install -d `dirname ${D}${systemd_unitdir}` + mv ${D}${prefix}/lib/systemd `dirname ${D}${systemd_unitdir}` + rmdir ${D}${prefix}/lib --ignore-fail-on-non-empty + fi # Ensure correct ownership for files copied in chown root:root ${D}${sysconfdir}/stap-exporter/* -R -- cgit 1.2.3-korg