app-backup/snapper: Fix systemd systemunitdir
authorLuigi 'Comio' Mantellini <luigi.mantellini@gmail.com>
Mon, 5 Mar 2018 11:03:21 +0000 (12:03 +0100)
committerAndreas Sturmlechner <asturm@gentoo.org>
Tue, 13 Mar 2018 22:36:00 +0000 (23:36 +0100)
Closes: https://bugs.gentoo.org/649630
Closes: https://github.com/gentoo/gentoo/pull/7363

app-backup/snapper/snapper-0.5.4.ebuild

index dfc07db31057163b6f775ce3b43ce01f60cd4aec..08667a65c08b98d1ae5891f64abbb86010f6316b 100644 (file)
@@ -1,8 +1,10 @@
-# Copyright 1999-2018 Gentoo Foundation
+# Copyright 1999-2017 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
 
 EAPI=6
 
+inherit systemd
+
 DESCRIPTION="Command-line program for btrfs and ext4 snapshot management"
 HOMEPAGE="http://snapper.io/"
 SRC_URI="ftp://ftp.suse.com/pub/projects/snapper/${P}.tar.bz2"
@@ -36,6 +38,14 @@ PATCHES=(
        "${FILESDIR}"/cron-confd.patch
 )
 
+src_prepare() {
+       default
+
+       sed -e "s,/usr/lib/systemd/system,$(systemd_get_systemunitdir),g" \
+               -i data/Makefile.* \
+               || die "Failed to fix systemd services and timers installation path"
+}
+
 src_configure() {
        local myeconfargs=(
                --with-conf="/etc/conf.d"