Apply smack label to system cache files
[platform/core/graphics/default-fonts-sdk.git] / packaging / default-fonts-sdk.spec
index 911b0e6..32eea2c 100644 (file)
@@ -6,7 +6,8 @@ Group:      TO_BE/FILLED_IN
 License:    Apache-2.0 and GPL-2.0-with-font-exception
 Source0:    %{name}-%{version}.tar.gz
 Source1001: packaging/default-fonts-sdk.manifest
-#Requires(post): fontconfig
+BuildRequires: pkgconfig(libtzplatform-config)
+Requires(post): fontconfig
 
 %description
 free fonts for Tizen SDK
@@ -28,7 +29,10 @@ mkdir -p %{buildroot}%{_datadir}/fallback_fonts && cp -a common/fallback_fonts %
 #cp -a $TARGET/fallback_fonts %{buildroot}%{_datadir}
 
 %post
-/usr/bin/fc-cache -f
+if [ -x /usr/bin/fc-cache ] ; then
+  /usr/bin/fc-cache -f
+  chsmack -a User::App::Shared %{TZ_SYS_VAR}/cache/fontconfig/*
+fi
 
 %files
 %manifest default-fonts-sdk.manifest