Using %license macro to install license file instead of using manual command.
[platform/upstream/fontconfig.git] / packaging / fontconfig.spec
index 334b445..13fba0a 100644 (file)
@@ -71,7 +71,7 @@ make %{?jobs:-j%jobs}
 %install
 rm -rf %{buildroot}
 mkdir -p %{buildroot}%{upgrade_script_path}
-cp -f scripts/fontconfig_upgrade.sh %{buildroot}%{upgrade_script_path}
+cp -f scripts/500.fontconfig.sh %{buildroot}%{upgrade_script_path}
 
 %make_install
 
@@ -82,8 +82,6 @@ install -m 0644 %SOURCE100 %{buildroot}%{_tmpfilesdir}/fontconfig.conf
 # and own /usr/share/fonts
 mydir=$RPM_BUILD_ROOT%{TZ_SYS_RO_SHARE}/fonts
 mkdir -p $RPM_BUILD_ROOT%{TZ_SYS_RO_SHARE}/fonts
-mkdir -p %{buildroot}%{TZ_SYS_RO_SHARE}/license
-cat COPYING > %{buildroot}%{TZ_SYS_RO_SHARE}/license/%{name}
 
 # Remove unpackaged files. no need when configure --disable-static
 #rm $RPM_BUILD_ROOT%{_libdir}/*.la
@@ -124,9 +122,9 @@ chsmack -a User::App::Shared %{TZ_SYS_VAR}/cache/fontconfig
 # The check for existance is needed on dual-arch installs (the second
 #  copy of fontconfig might install the binary instead of the first)
 # The HOME setting is to avoid problems if HOME hasn't been reset
-if [ -x %{TZ_SYS_BIN}/fc-cache ] && %{TZ_SYS_BIN}/fc-cache --version 2>&1 | grep -q %{version} ; then
-fc-cache -rf --system-only
-fi
+#if [ -x %{TZ_SYS_BIN}/fc-cache ] && %{TZ_SYS_BIN}/fc-cache --version 2>&1 | grep -q %{version} ; then
+#fc-cache -rf --system-only
+#fi
 
 %postun -p /sbin/ldconfig
 
@@ -143,9 +141,9 @@ fi
 %doc %{TZ_SYS_RO_ETC}/fonts/conf.d/README
 %config %{TZ_SYS_RO_ETC}/fonts/conf.avail/*.conf
 %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
+%{upgrade_script_path}/500.fontconfig.sh
+%license COPYING
 
 %files devel
 %manifest fontconfig.manifest