summaryrefslogtreecommitdiff
path: root/packaging
diff options
context:
space:
mode:
authorKévin THIERRY <kevin.thierry@open.eurogiciel.org>2014-02-13 14:24:16 +0100
committerKévin THIERRY <kevin.thierry@open.eurogiciel.org>2014-05-16 11:14:43 +0200
commit16dd30cb7b9c86bc5744ff170f45683d5c76ac0c (patch)
treee6fb1088b0287ae88e3a44c0ff7fc22478b87611 /packaging
parentbe41cb5bbf3b00430c1fff05f36c69fe3a56e127 (diff)
downloadoma-ds-agent-tizen.tar.gz
oma-ds-agent-tizen.tar.bz2
oma-ds-agent-tizen.zip
Bug-Tizen: PTREL-271 Change-Id: I65b0d09ba91e9d072358d50950f31bd31c22c143 Signed-off-by: Kévin THIERRY <kevin.thierry@open.eurogiciel.org>
Diffstat (limited to 'packaging')
-rwxr-xr-xpackaging/oma-ds-agent.spec68
1 files changed, 33 insertions, 35 deletions
diff --git a/packaging/oma-ds-agent.spec b/packaging/oma-ds-agent.spec
index 9cf9177..7531831 100755
--- a/packaging/oma-ds-agent.spec
+++ b/packaging/oma-ds-agent.spec
@@ -1,25 +1,26 @@
Name: oma-ds-agent
Summary: OMA-DS Agent Daemon for Data Synchronization
Version: 0.1.66
-Release: 1
+Release: 0
Group: Base/Device Management
License: Apache-2.0
Source0: %{name}-%{version}.tar.gz
-Requires(post): /sbin/ldconfig
+Requires(post): /sbin/ldconfig
Requires(postun): /sbin/ldconfig
-BuildRequires: pkgconfig(glib-2.0)
-BuildRequires: pkgconfig(libsoup-2.4)
-BuildRequires: pkgconfig(sqlite3)
-BuildRequires: pkgconfig(sync-agent)
-BuildRequires: pkgconfig(vconf)
-BuildRequires: pkgconfig(dbus-glib-1)
-BuildRequires: pkgconfig(check)
-BuildRequires: pkgconfig(memo)
-BuildRequires: pkgconfig(contacts-service2)
-BuildRequires: pkgconfig(dlog)
-BuildRequires: pkgconfig(aul)
-BuildRequires: expat-devel
-BuildRequires: cmake
+BuildRequires: pkgconfig(glib-2.0)
+BuildRequires: pkgconfig(libsoup-2.4)
+BuildRequires: pkgconfig(sqlite3)
+BuildRequires: pkgconfig(sync-agent)
+BuildRequires: pkgconfig(vconf)
+BuildRequires: pkgconfig(dbus-glib-1)
+BuildRequires: pkgconfig(check)
+BuildRequires: pkgconfig(memo)
+BuildRequires: pkgconfig(contacts-service2)
+BuildRequires: pkgconfig(dlog)
+BuildRequires: pkgconfig(aul)
+BuildRequires: pkgconfig(libtzplatform-config)
+BuildRequires: expat-devel
+BuildRequires: cmake
%description
@@ -38,19 +39,19 @@ ds public plugins for sync-agent
%build
-cmake . -DCMAKE_INSTALL_PREFIX=%{_prefix}
+%cmake . -DCMAKE_INSTALL_PREFIX=%{_prefix} -DTZ_SYS_DB=%TZ_SYS_DB
make %{?jobs:-j%jobs}
%install
rm -rf %{buildroot}
-if [ ! -d %{buildroot}/opt/dbspace ]
+if [ ! -d %{buildroot}%{TZ_SYS_DB} ]
then
- mkdir -p %{buildroot}/opt/dbspace
+ mkdir -p %{buildroot}%{TZ_SYS_DB}
fi
-sqlite3 %{buildroot}/opt/dbspace/.omasyncagent.db "PRAGMA journal_mode = PERSIST; create table a(a); drop table a;" > /dev/null
+sqlite3 %{buildroot}%{TZ_SYS_DB}/.omasyncagent.db "PRAGMA journal_mode = PERSIST; create table a(a); drop table a;" > /dev/null
%make_install
@@ -59,44 +60,41 @@ rm -rf %{buildroot}
%post
-if [ ! -d /opt/dbspace ]
+if [ ! -d %{TZ_SYS_DB} ]
then
- mkdir /opt/dbspace
+ mkdir %{TZ_SYS_DB}
fi
-if [ ! -d /etc/rc.d/rc3.d ]
+if [ ! -d %{_sysconfdir}/rc.d/rc3.d ]
then
- mkdir /etc/rc.d/rc3.d
+ mkdir %{_sysconfdir}/rc.d/rc3.d
fi
-if [ ! -d /etc/rc.d/rc5.d ]
+if [ ! -d %{_sysconfdir}/rc.d/rc5.d ]
then
- mkdir /etc/rc.d/rc5.d
+ mkdir %{_sysconfdir}/rc.d/rc5.d
fi
-%preun
-
-
%postun
rm -f /tmp/agent_fw_event_omads*
rm -f /tmp/agent_fw_noti_reply_omads*
-rm -f /etc/rc.d/rc3.d/S91oma-ds-agent
-rm -f /etc/rc.d/rc5.d/S91oma-ds-agent
+rm -f %{_sysconfdir}/rc.d/rc3.d/S91oma-ds-agent
+rm -f %{_sysconfdir}/rc.d/rc5.d/S91oma-ds-agent
-rm -f /opt/dbspace/.omasyncagent.db /opt/dbspace/.omasyncagent.db-journal
+rm -f %{TZ_SYS_DB}/.omasyncagent.db %{TZ_SYS_DB}/.omasyncagent.db-journal
rm -rf /usr/share/oma-ds-cfg
%files
-%attr(600,root,root) /opt/dbspace/.omasyncagent.db
-%attr(600,root,root) /opt/dbspace/.omasyncagent.db-journal
+%attr(600,root,root) %{TZ_SYS_DB}/.omasyncagent.db
+%attr(600,root,root) %{TZ_SYS_DB}/.omasyncagent.db-journal
%manifest oma-ds-agent.manifest
%defattr(-,root,root,-)
/usr/share/dbus-1/system-services/com.samsung.omadsagent.service
-/usr/bin/oma-ds-agent
+%{_bindir}/oma-ds-agent
/usr/share/oma-ds-cfg/*
@@ -104,7 +102,7 @@ rm -rf /usr/share/oma-ds-cfg
%defattr(644,root,root)
/usr/lib/systemd/system/oma-ds-agent.service
/usr/lib/systemd/system/graphical.target.wants/oma-ds-agent.service
-/etc/dbus-1/system.d/com.samsung.omadsagent.conf
+%{_sysconfdir}/dbus-1/system.d/com.samsung.omadsagent.conf
%files -n ds-public-plugins
%manifest ds-public-plugins.manifest