fontconfig-vl.spec 9.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316
  1. %define build_compat32 %{?_with_compat32:1}%{!?_with_compat32:0}
  2. %define _unpackaged_files_terminate_build 1
  3. %define freetype_version 2.10.1
  4. Summary: Font configuration and customization library
  5. Summary(ja): フォント設定/カスタマイズライブラリ
  6. Name: fontconfig
  7. Version: 2.14.2
  8. Release: 1%{?_dist_release}
  9. Group: system
  10. Vendor: Project Vine
  11. Distribution: Vine Linux
  12. License: MIT
  13. URL: https://fontconfig.org/
  14. Source: https://fontconfig.org/release/fontconfig-%{version}.tar.xz
  15. Source10: 70-prefer-ja-font.conf
  16. Source11: 59-morisawa-font-alias.conf
  17. Source100: ChangeLog.fedora
  18. # from fedora
  19. # https://bugzilla.redhat.com/show_bug.cgi?id=140335
  20. Patch0: %{name}-sleep-less.patch
  21. Patch4: %{name}-drop-lang-from-pkgkit-format.patch
  22. Patch5: %{name}-disable-network-required-test.patch
  23. # vine
  24. Patch10000: fontconfig-2.3.2-subst-ja-font.patch
  25. Patch10001: fontconfig-2.13.1-vine.patch
  26. BuildRoot: %{_tmppath}/%{name}-%{version}-root
  27. BuildRequires: gawk
  28. BuildRequires: expat-devel
  29. BuildRequires: freetype2-devel >= %{freetype_version}
  30. BuildRequires: perl
  31. #BuildRequires: itstool
  32. BuildRequires: libuuid-devel
  33. BuildRequires: gperf
  34. Requires(pre): freetype2 >= %{freetype_version}, coreutils
  35. Conflicts: XOrg-libs <= 6.9.0
  36. Obsoletes: XOrg-libs <= 6.9.0
  37. Conflicts: XOrg-font-utils <= 6.9.0
  38. Obsoletes: XOrg-font-utils <= 6.9.0
  39. %description
  40. Fontconfig is designed to locate fonts within the
  41. system and select them according to requirements specified by
  42. applications.
  43. %description -l ja
  44. Fontconfig は、システム内のフォントを把握し、アプリケーション
  45. が指定した要求に応じてそれらを選択するためのライブラリです。
  46. %package devel
  47. Summary: Development files for %{name}
  48. Summary(ja): Fontconfig の開発ファイル
  49. Group: programming
  50. Requires: fontconfig = %{version}-%{release}
  51. Requires: freetype2-devel >= %{freetype_version}
  52. Requires: expat-devel
  53. Requires: pkgconfig
  54. Conflicts: XOrg-devel <= 6.9.0
  55. Obsoletes: XOrg-devel <= 6.9.0
  56. %description devel
  57. The fontconfig-devel package includes the header files,
  58. and developer docs for the fontconfig package.
  59. %description -l ja devel
  60. fontconfig-devel パッケージには fontconfig を使ったソフトウエア
  61. を開発するために必要なヘッダファイルやライブラリ、開発用ドキュメ
  62. ントが含まれています。
  63. # compat32
  64. %package -n compat32-%{name}
  65. Summary: Font configuration and customization library
  66. Summary(ja): フォント設定/カスタマイズライブラリ
  67. Group: system,legacy
  68. %description -n compat32-%{name}
  69. Fontconfig is designed to locate fonts within the
  70. system and select them according to requirements specified by
  71. applications.
  72. %description -l ja -n compat32-%{name}
  73. Fontconfig は、システム内のフォントを把握し、アプリケーション
  74. が指定した要求に応じてそれらを選択するためのライブラリです。
  75. %package -n compat32-%{name}-devel
  76. Summary: Font configuration and customization library
  77. Group: programming,legacy
  78. Requires: compat32-%{name} = %{version}-%{release}
  79. Requires: %{name}-devel = %{version}-%{release}
  80. Requires: compat32-freetype2-devel >= %{freetype_version}
  81. Requires: compat32-expat-devel
  82. %description -n compat32-%{name}-devel
  83. The fontconfig-devel package includes the header files,
  84. and developer docs for the fontconfig package.
  85. %description -l ja -n compat32-%{name}-devel
  86. fontconfig-devel パッケージには fontconfig を使ったソフトウエア
  87. を開発するために必要なヘッダファイルやライブラリ、開発用ドキュメ
  88. ントが含まれています。
  89. %debug_package
  90. %prep
  91. %setup -q
  92. %autopatch -p1 -M 9999
  93. #patch10000 -p1 -b .subst-ja-font
  94. %patch10001 -p1 -b .vine
  95. %build
  96. # We don't want to rebuild the docs, but we want to install the included ones.
  97. export HASDOCBOOK=no
  98. %configure \
  99. --with-add-fonts=/usr/share/fonts,/usr/share/X11/fonts/Type1,/usr/share/X11/fonts/TTF,/usr/local/share/fonts
  100. %__make %{?_smp_mflags}
  101. %install
  102. rm -rf $RPM_BUILD_ROOT
  103. %__make install DESTDIR=$RPM_BUILD_ROOT
  104. ln -s %{_datadir}/fontconfig/conf.avail/25-unhint-nonlatin.conf $RPM_BUILD_ROOT%{_sysconfdir}/fonts/conf.d
  105. install -m664 %{SOURCE10} %{SOURCE11} $RPM_BUILD_ROOT/%{_datadir}/fontconfig/conf.avail/
  106. for i in 70-prefer-ja-font.conf 59-morisawa-font-alias.conf
  107. do
  108. ln -sf %{_datadir}/fontconfig/conf.avail/$i $RPM_BUILD_ROOT/%{_sysconfdir}/fonts/conf.d/
  109. done
  110. # move installed doc files back to build directory to package themm
  111. # in the right place
  112. mv $RPM_BUILD_ROOT%{_docdir}/fontconfig/* .
  113. rmdir $RPM_BUILD_ROOT%{_docdir}/fontconfig/
  114. # All font packages depend on this package, so we create
  115. # and own /usr/share/fonts
  116. mkdir -p $RPM_BUILD_ROOT%{_datadir}/fonts
  117. # Remove unpackaged files
  118. find $RPM_BUILD_ROOT -name '*.la' -exec rm -f {} \;
  119. find $RPM_BUILD_ROOT -name '*.a' -exec rm -f {} \;
  120. # remove locales (zh only)
  121. rm -rf %{buildroot}%{_datadir}/locale
  122. %clean
  123. rm -rf $RPM_BUILD_ROOT
  124. %transfiletriggerin -- /usr/share/fonts /usr/share/X11/fonts/Type1 /usr/share/X11/fonts/TTF /usr/local/share/fonts
  125. HOME=/root /usr/bin/fc-cache -s
  126. %transfiletriggerpostun -- /usr/share/fonts /usr/share/X11/fonts/Type1 /usr/share/X11/fonts/TTF /usr/local/share/fonts
  127. HOME=/root /usr/bin/fc-cache -s
  128. %posttrans
  129. umask 0022
  130. # Remove stale caches
  131. rm -f %{_localstatedir}/cache/fontconfig/????????????????????????????????-*.cache-2
  132. HOME=/root /usr/bin/fc-cache -f -s >& /dev/null
  133. %files
  134. %defattr(-, root, root)
  135. %license COPYING
  136. %doc README AUTHORS
  137. %doc fontconfig-user.txt fontconfig-user.html
  138. %doc %{_sysconfdir}/fonts/conf.d/README
  139. %{_libdir}/libfontconfig.so.*
  140. %{_bindir}/fc-cache
  141. %{_bindir}/fc-conflist
  142. %{_bindir}/fc-list
  143. %{_bindir}/fc-match
  144. %{_bindir}/fc-cat
  145. %{_bindir}/fc-query
  146. %{_bindir}/fc-scan
  147. %{_bindir}/fc-pattern
  148. %{_bindir}/fc-validate
  149. %dir %{_datadir}/fonts
  150. %{_datadir}/%{name}
  151. %{_datadir}/xml/%{name}/fonts.dtd
  152. %config %{_sysconfdir}/fonts/fonts.conf
  153. %config(noreplace) %{_sysconfdir}/fonts/conf.d/*.conf
  154. %dir %{_localstatedir}/cache/fontconfig
  155. %{_mandir}/man1/*
  156. %{_mandir}/man5/*
  157. %files devel
  158. %defattr(-, root, root)
  159. %doc fontconfig-devel.txt fontconfig-devel
  160. %{_libdir}/libfontconfig.so
  161. %dir %{_datadir}/gettext
  162. %dir %{_datadir}/gettext/its
  163. %{_datadir}/gettext/its/*
  164. %{_libdir}/pkgconfig/*
  165. %{_includedir}/fontconfig
  166. %{_mandir}/man3/*
  167. # compat32
  168. %if %{build_compat32}
  169. %files -n compat32-%{name}
  170. %defattr(-, root, root)
  171. %{_libdir}/libfontconfig.so.*
  172. %files -n compat32-%{name}-devel
  173. %defattr(-, root, root)
  174. %{_libdir}/libfontconfig.so
  175. %endif
  176. %changelog
  177. * Tue Oct 03 2023 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 2.14.2-1
  178. - new upstream release.
  179. * Tue Nov 01 2022 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 2.14.1-1
  180. - new upstream release.
  181. * Fri Apr 10 2020 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 2.13.1-1
  182. - new upstream release.
  183. - disabled Patch4.
  184. - updated Patch10.
  185. - truncated %%changelog: old logs are ChangeLog.fedora.
  186. * Fri Jan 05 2018 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 2.12.6-1
  187. - new upstream release.
  188. - added BR:gperf.
  189. * Fri Mar 28 2014 Yoji TOYODA <bsyamato@sea.plala.or.jp> 2.11.1-1
  190. - new upstream release
  191. * Mon Dec 30 2013 Yoji TOYODA <bsyamato@sea.plala.or.jp> 2.11.0-1
  192. - new upstream release
  193. - remove Patch1,2
  194. * Tue May 07 2013 Daisuke SUZUKI <daisuke@linux.or.jp> 2.10.92-2
  195. - install/enable 70-prefer-ja-font.conf and 59-morisawa-font-alias.conf (again)
  196. - enable 25-unhint-nonlatin.conf (again)
  197. - add patch0-2 from fedora package
  198. - patch0: less sleep in fc-cache
  199. - patch1: fix font matching issue
  200. - patch2: fix web font issue in firefox
  201. * Wed Apr 17 2013 Yoji TOYODA <bsyamato@sea.plala.or.jp> 2.10.92-1
  202. - new upstream release
  203. - remove Patch1 (fontconfig-2.2.1-AppleRoman-DynaFont.patch)
  204. * Fri Dec 24 2010 Yoji TOYODA <bsyamato@sea.plala.or.jp> 2.8.0-3
  205. - rebuild with freetype2-2.4.8
  206. - add Requires: expat-devel (-devel package)
  207. * Tue Sep 21 2010 IWAI, Masaharu <iwai@alib.jp> 2.8.0-2
  208. - build with rpm-4.8.1-1 for pkg-config file
  209. * Fri Jan 08 2010 Daisuke SUZUKI <daisuke@linux.or.jp> 2.8.0-1
  210. - new upstream release
  211. - remove static libs
  212. * Sun Aug 16 2009 Daisuke SUZUKI <daisuke@linux.or.jp> 2.7.1-3
  213. - update %%post
  214. * Thu Aug 06 2009 Daisuke SUZUKI <daisuke@linux.or.jp> 2.7.1-2
  215. - add translated summary and description
  216. * Wed Aug 05 2009 Daisuke SUZUKI <daisuke@linux.or.jp> 2.7.1-1
  217. - new upstream release
  218. * Mon Jul 20 2009 Daisuke SUZUKI <daisuke@linux.or.jp> 2.7.0-2
  219. - add fc-query and fc-scan to %%files
  220. * Mon Jul 20 2009 Daisuke SUZUKI <daisuke@linux.or.jp> 2.7.0-1
  221. - new upstream release
  222. - update 59-morisawa-font-alias.conf
  223. * Sun May 03 2009 NAKAMURA Kenta <kenta@vinelinux.org> 2.6.0-3
  224. - added compat32 package for x86_64 arch support
  225. * Tue Jan 06 2009 Daisuke SUZUKI <daisuke@linux.or.jp> 2.6.0-2
  226. - update 59-morisawa-font-alias.conf
  227. - add FutoMin, FutoGo, Jun alias
  228. * Thu Jun 12 2008 Daisuke SUZUKI <daisuke@linux.or.jp> 2.6.0-1
  229. - new upstream release
  230. - rename 10-prefer-ja-font.conf to 70-prefer-ja-font.conf
  231. * Thu May 29 2008 Daisuke SUZUKI <daisuke@linux.or.jp> 2.5.0-3
  232. - add 10-prefer-ja-font.conf to prefer Japanese fonts.
  233. - add 59-morisawa-font-alias.conf
  234. - bind Ryumin to serif and GothicBBB to sans-serif
  235. * Mon May 12 2008 Daisuke SUZUKI <daisuke@linux.or.jp> 2.5.0-2
  236. - add legacy font path for compatibility
  237. * Thu Apr 17 2008 Daisuke SUZUKI <daisuke@linux.or.jp> 2.5.0-1
  238. - add Conflits/Obsoletes: XOrg-font-utils <= 6.9.0
  239. * Mon Dec 10 2007 Daisuke SUZUKI <daisuke@linux.or.jp> 2.5.0-0vl1
  240. - initial build for Vine Linux
  241. - splitted from XOrg package.