summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authortaesub kim <taesub.kim@samsung.com>2017-10-10 15:19:17 +0900
committertaesub kim <taesub.kim@samsung.com>2017-10-10 16:29:00 +0900
commitccac24c41631a6edf79233362a7e60970b3a90cd (patch)
treecbf23e47cdf6f50ab855226dfc8c431a7509071d
parent796441c4296905691f55c893e73e7b8704b49f73 (diff)
downloadconnman-ccac24c41631a6edf79233362a7e60970b3a90cd.tar.gz
connman-ccac24c41631a6edf79233362a7e60970b3a90cd.tar.bz2
connman-ccac24c41631a6edf79233362a7e60970b3a90cd.zip
Added RW upgrade script
Change-Id: I2208cf0923a66c78551ac2eb13933735afe33604 Signed-off-by: Taesub Kim <taesub.kim@samsung.com>
-rwxr-xr-xpackaging/connman.spec8
-rw-r--r--scripts/500.connman_upgrade.sh9
2 files changed, 17 insertions, 0 deletions
diff --git a/packaging/connman.spec b/packaging/connman.spec
index 0888d9d5..4238f160 100755
--- a/packaging/connman.spec
+++ b/packaging/connman.spec
@@ -41,6 +41,9 @@ Provides: %{name}-profile_common = %{version}-%{release}
Provides: %{name}-profile_mobile = %{version}-%{release}
Provides: %{name}-profile_wearable = %{version}-%{release}
+%define upgrade_script_filename 500.connman_upgrade.sh
+%define upgrade_script_path /usr/share/upgrade/scripts
+
%description
Connection Manager provides a daemon for managing Internet connections
within embedded devices running the Linux operating system.
@@ -218,6 +221,10 @@ cp src/connman.conf %{buildroot}%{_sysconfdir}/dbus-1/system.d/
cp vpn/vpn-dbus.conf %{buildroot}%{_sysconfdir}/dbus-1/system.d/connman-vpn-dbus.conf
%endif
+#OS Upgrade
+mkdir -p %{buildroot}%{upgrade_script_path}
+cp -f scripts/%{upgrade_script_filename} %{buildroot}%{upgrade_script_path}
+
%post
#chsmack -a 'System' /%{_localstatedir}/lib/connman
#chsmack -a 'System' /%{_localstatedir}/lib/connman/settings
@@ -251,6 +258,7 @@ systemctl daemon-reload
%attr(644,root,root) %{_libdir}/systemd/system/sockets.target.wants/connman.socket
%endif
%license COPYING
+%{upgrade_script_path}/%{upgrade_script_filename}
%files test
%manifest connman.manifest
diff --git a/scripts/500.connman_upgrade.sh b/scripts/500.connman_upgrade.sh
new file mode 100644
index 00000000..a21336e2
--- /dev/null
+++ b/scripts/500.connman_upgrade.sh
@@ -0,0 +1,9 @@
+#!/bin/sh
+PATH=/bin:/usr/bin:/sbin:/usr/sbin
+
+#------------------------------------------------------------#
+# connman patch script for upgrade (3.0 -> the latest tizen) #
+#------------------------------------------------------------#
+
+chmod 755 /var/lib/connman
+chown -R network_fw:network_fw /var/lib/connman