Add a script to upgrade from 2.4 to 3.0 51/87951/2 accepted/tizen/common/20160912.181716 accepted/tizen/ivi/20160920.052144 accepted/tizen/mobile/20160920.052055 accepted/tizen/tv/20160920.052108 accepted/tizen/wearable/20160920.052128 submit/tizen/20160912.091121 submit/tizen/20160920.023107
authorShinwoo Kim <cinoo.kim@samsung.com>
Mon, 12 Sep 2016 08:47:18 +0000 (17:47 +0900)
committerShinwoo Kim <cinoo.kim@samsung.com>
Mon, 12 Sep 2016 08:53:28 +0000 (17:53 +0900)
Change-Id: I62e943ff1d54336f3b249da97b7593889e7a78ed

packaging/fontconfig.spec
scripts/fontconfig_upgrade.sh [new file with mode: 0755]

index b8f8e23..7f0ef71 100644 (file)
@@ -22,6 +22,8 @@ Requires(pre):  %{TZ_SYS_BIN}/fc-cache, %{TZ_SYS_BIN}/mkdir %{TZ_SYS_BIN}/rm, %{
 Requires(post): /sbin/ldconfig
 Requires(postun): /sbin/ldconfig
 
+%define upgrade_script_path /usr/share/upgrade/scripts
+
 %description
 Fontconfig is designed to locate fonts within the
 system and select them according to requirements specified by
@@ -68,6 +70,8 @@ make %{?jobs:-j%jobs}
 #make check
 %install
 rm -rf %{buildroot}
+mkdir -p %{buildroot}%{upgrade_script_path}
+cp -f scripts/fontconfig_upgrade.sh %{buildroot}%{upgrade_script_path}
 
 %make_install
 
@@ -135,6 +139,7 @@ fi
 %config(noreplace) %{TZ_SYS_RO_ETC}/fonts/conf.d/*.conf
 %{TZ_SYS_RO_SHARE}/license/%{name}
 %{_tmpfilesdir}/fontconfig.conf
+%{upgrade_script_path}/fontconfig_upgrade.sh
 
 %files devel
 %manifest fontconfig.manifest
diff --git a/scripts/fontconfig_upgrade.sh b/scripts/fontconfig_upgrade.sh
new file mode 100755 (executable)
index 0000000..2b9a6d9
--- /dev/null
@@ -0,0 +1,15 @@
+#!/bin/sh
+
+#------------------------------------------#
+# efl-misc upgrade (2.4 -> 3.0)            #
+#------------------------------------------#
+
+# Macro
+PATH=/bin:/usr/bin:/sbin:/usr/sbin
+
+# Set under the /opt
+mkdir -p /opt/var/cache/fontconfig
+chmod -R 775 /opt/var/cache/fontconfig
+chown -R :users /opt/var/cache/fontconfig
+chsmack -a 'User::App::Shared' /opt/var/cache/fontconfig
+chsmack -t /opt/var/cache/fontconfig