packaging: uses systemd macros to supports x64 64/17064/1
authorPhilippe Coval <philippe.coval@open.eurogiciel.org>
Mon, 3 Mar 2014 11:00:53 +0000 (12:00 +0100)
committerPhilippe Coval <philippe.coval@open.eurogiciel.org>
Mon, 3 Mar 2014 11:00:53 +0000 (12:00 +0100)
Change-Id: I043612296a822be8c65d37c39f270687b03b716b
Bug-Tizen: PTREL-643/part
Signed-off-by: Philippe Coval <philippe.coval@open.eurogiciel.org>
packaging/system-server.spec

index 118404d..95d6ab8 100755 (executable)
@@ -37,6 +37,7 @@ BuildRequires:  gettext
 BuildRequires:  pkgconfig(sensor)
 BuildRequires:  pkgconfig(libsystemd-daemon)
 BuildRequires:  pkgconfig(capi-base-common)
+BuildRequires:  systemd
 %{?systemd_requires}
 Requires(preun): /usr/bin/systemctl
 Requires(post): /usr/bin/systemctl
@@ -185,15 +186,14 @@ cp %{SOURCE6} .
 rm -rf %{buildroot}
 %make_install
 
-mkdir -p %{buildroot}%{_libdir}/systemd/system/multi-user.target.wants
-mkdir -p %{buildroot}%{_libdir}/systemd/system/sockets.target.wants
-ln -s ../system-server.service %{buildroot}%{_libdir}/systemd/system/multi-user.target.wants/system-server.service
-ln -s ../system-server.service %{buildroot}%{_libdir}/systemd/system/sockets.target.wants/system-server.socket
-install -m 0644 %{SOURCE8} %{buildroot}%{_libdir}/systemd/system/regpmon.service
-ln -s ../regpmon.service %{buildroot}%{_libdir}/systemd/system/multi-user.target.wants/regpmon.service
-mkdir -p %{buildroot}%{_libdir}/systemd/system/graphical.target.wants
-install -m 0644 %{SOURCE9} %{buildroot}%{_libdir}/systemd/system/zbooting-done.service
-ln -s ../zbooting-done.service %{buildroot}%{_libdir}/systemd/system/graphical.target.wants/zbooting-done.service
+%install_service multi-user.target.wants system-server.service
+%install_service sockets.target.wants system-server.service
+
+%install_service graphical.target.wants regpmon.service
+install -m 0644 %{SOURCE8} %{buildroot}%{_unitdir}/regpmon.service
+
+%install_service graphical.target.wants zbooting-done.service
+install -m 0644 %{SOURCE9} %{buildroot}%{_unitdir}/zbooting-done.service
 
 %post
 #memory type vconf key init
@@ -298,14 +298,14 @@ systemctl daemon-reload
 %{_bindir}/mmc-smack-label
 %{_bindir}/device-daemon
 %{_bindir}/fsck_msdosfs
-%{_libdir}/systemd/system/multi-user.target.wants/system-server.service
-%{_libdir}/systemd/system/sockets.target.wants/system-server.socket
-%{_libdir}/systemd/system/system-server.service
-%{_libdir}/systemd/system/system-server.socket
-%{_libdir}/systemd/system/multi-user.target.wants/regpmon.service
-%{_libdir}/systemd/system/regpmon.service
-%{_libdir}/systemd/system/graphical.target.wants/zbooting-done.service
-%{_libdir}/systemd/system/zbooting-done.service
+%{_unitdir}/multi-user.target.wants/system-server.service
+%{_unitdir}/graphical.target.wants/regpmon.service
+%{_unitdir}/sockets.target.wants/system-server.service
+%{_unitdir}/system-server.service
+%{_unitdir}/system-server.socket
+%{_unitdir}/regpmon.service
+%{_unitdir}/graphical.target.wants/zbooting-done.service
+%{_unitdir}/zbooting-done.service
 %{_datadir}/system-server/sys_pci_noti/res/locale/*/LC_MESSAGES/*.mo
 %config %{_sysconfdir}/dbus-1/system.d/system-server.conf
 %{_datadir}/license/fsck_msdosfs