From 9274a22e0d27e8cd2f5e07e71053d176d3293465 Mon Sep 17 00:00:00 2001 From: Mikko Ylinen Date: Fri, 12 Sep 2014 15:21:48 +0300 Subject: [PATCH] Fix Systemd unitdir path on x86_64 This workaround is needed to fix systemd pkg-config issue on x86_64. Looks like this: pkg-config --silence-errors --variable=systemdsystemunitdir systemd returns static /usr/lib/systemd/system. However, on x86_64 /usr/lib64 is used. Make with_systemdsystemunitdir configurable and pass %{_unitdir} variable to it. Change-Id: I19077085065e2b15873904f460117d87f3759d4c Signed-off-by: Mikko Ylinen --- configure.ac | 2 +- packaging/node-state-manager.changes | 3 +++ packaging/node-state-manager.spec | 4 ++-- 3 files changed, 6 insertions(+), 3 deletions(-) diff --git a/configure.ac b/configure.ac index fcc9abc..4f9abff 100644 --- a/configure.ac +++ b/configure.ac @@ -50,7 +50,7 @@ PKG_CHECK_MODULES([PCL], [persistence_client_library >= 0.6.0 ]) # Derive path for storing systemd service files (e. g. /lib/systemd/system) AC_ARG_WITH([systemdsystemunitdir], AS_HELP_STRING([--with-systemdsystemunitdir=DIR], [Directory for systemd service files]), - [], + [with_systemdsystemunitdir="$withval"], [with_systemdsystemunitdir=$(pkg-config --silence-errors --variable=systemdsystemunitdir systemd)]) if test "x${with_systemdsystemunitdir}" = "x"; then diff --git a/packaging/node-state-manager.changes b/packaging/node-state-manager.changes index fa0a884..67b6bac 100644 --- a/packaging/node-state-manager.changes +++ b/packaging/node-state-manager.changes @@ -1,3 +1,6 @@ +* Fri Sep 12 2014 Ossama Othman submit/tizen_ivi/20140912.678321-1-g6599c84 +- Fix Systemd unitdir path on x86_64 + * Fri Sep 05 2014 Ossama Othman b4ff31e - Initial packaging. diff --git a/packaging/node-state-manager.spec b/packaging/node-state-manager.spec index 711cca2..086556f 100644 --- a/packaging/node-state-manager.spec +++ b/packaging/node-state-manager.spec @@ -49,7 +49,7 @@ This package provides test related files for package %{name}. cp %{SOURCE1001} . %build -%autogen --disable-static +%autogen --disable-static --with-systemdsystemunitdir=%{_unitdir} make %{?_smp_mflags} @@ -65,7 +65,7 @@ make %{?_smp_mflags} %license COPYING %{_bindir}/NodeStateManager %config %{_sysconfdir}/dbus-1/system.d/org.genivi.NodeStateManager.conf -%{_libdir}/systemd/system/nodestatemanager-daemon.service +%{_unitdir}/nodestatemanager-daemon.service %{_datadir}/dbus-1/system-services/org.genivi.NodeStateManager.LifeCycleControl.service %{_datadir}/dbus-1/interfaces/org.genivi.NodeStateManager.*.xml # These `.so' files are not in the 'devel' subpackage since they are -- 2.7.4