%define _fontdir %{_datadir}/fonts/TrueType-ipafont Name: TrueType-ipafont Version: 3.03 Release: 4%{?_dist_release} Summary: IPA TrueType Fonts Summary(ja): IPA の日本語 TrueType フォント Group: User Interface/X Vendor: Project Vine Distribution: Vine Linux License: IPA Font License Agreement v1.0 URL: https://ipafont.ipa.go.jp/ Source: https://ipafont.ipa.go.jp/IPAfont/IPAfont00303.zip Source10: ipafont-mincho.ttfconf Source11: ipafont-gothic.ttfconf Source20: cidfmap.ja.ipafont-mincho Source21: cidfmap.ja.ipafont-gothic Source30: 59-ipa-mincho.conf Source31: 60-ipa-gothic.conf BuildArch: noarch BuildRoot: %{_tmppath}/%{name}-%{version}-root Obsoletes: TrueType-ipafont Requires: TrueType-ipafont-mincho = %{version} Requires: TrueType-ipafont-gothic = %{version} Requires: TrueType-ipafont-doc = %{version} %description This package is meta package to install both IPAMincho and IPAGothic fonts. %description -l ja このパッケージは独立行政法人情報処理推進機構のIPAフォントの明朝、ゴシック 両書体をインストールするためのメタパッケージです。このパッケージで 以下の4書体がインストールされます。 (IPA明朝、IPAP明朝、IPAゴシック、IPAPゴシック) %package mincho Summary: IPAMincho TrueType Fonts Summary(ja): IPA明朝 True Type フォント Group: User Interface/X Requires: TrueType-ipafont-doc Requires: alternatives Requires(preun): alternatives %description mincho This package includes IPA Mincho TrueType fonts. %description -l ja mincho このパッケージには独立行政法人情報処理推進機構のIPA明朝フォントが含まれています。 (IPA明朝、IPAP明朝) %package gothic Summary: IPA Gothic TrueType Fonts Summary(ja): IPA Gothic 日本語 True Type フォント Group: User Interface/X Requires: TrueType-ipafont-doc Requires: alternatives Requires(preun): alternatives %description gothic This package includes IPA Gothic TrueType fonts. This font is distributable without modification. (see /usr/share/doc/TrueType-ipafont/enduser_license.txt for details) %description -l ja gothic このパッケージには独立行政法人情報処理推進機構のIPAゴシックフォントが含まれて います。(IPAゴシック、IPAPゴシック) %package doc Summary: IPA Font Documents Summary(ja): IPA フォントドキュメント Group: User Interface/X %description doc This package includes important documents for IPA fonts includes enduser license. %description -l ja doc このパッケージには独立行政法人情報処理推進機構のIPAフォントのライセンス を含むドキュメント類が含まれています。 %prep %setup -q -n IPAfont00303 %build %install mkdir -p $RPM_BUILD_ROOT%{_fontdir} cp -a *.ttf $RPM_BUILD_ROOT%{_fontdir} cp -f %{SOURCE10} %{SOURCE11} $RPM_BUILD_ROOT%{_fontdir} mkdir -p $RPM_BUILD_ROOT/%{_sysconfdir}/fonts/conf.{avail,d} install -m664 %{SOURCE30} %{SOURCE31} $RPM_BUILD_ROOT/%{_sysconfdir}/fonts/conf.avail/ for i in $RPM_BUILD_ROOT/%{_sysconfdir}/fonts/conf.avail/*.conf do ln -sf ../conf.avail/$(basename $i) $RPM_BUILD_ROOT/%{_sysconfdir}/fonts/conf.d/ done # install ghostscript8 cidfmap #mkdir -p $RPM_BUILD_ROOT%{_datadir}/ghostscript/conf.d #install -m644 %{SOURCE20} %{SOURCE21} $RPM_BUILD_ROOT%{_datadir}/ghostscript/conf.d # add fontpath.d symlinks mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/X11/fontpath.d ln -sf /usr/share/fonts/%{name} $RPM_BUILD_ROOT%{_sysconfdir}/X11/fontpath.d/ %clean if test -n "${RPM_BUILD_ROOT}" && test "/" != "${RPM_BUILD_ROOT}"; then rm -rf ${RPM_BUILD_ROOT} fi %post mincho %__font_install_post %{_fontdir} %post gothic %__font_install_post %{_fontdir} %posttrans mincho update-alternatives --install \ /usr/share/fonts/alias/TrueType/fonts-japanese-mincho.ttf \ fonts-japanese-mincho.ttf \ %{_fontdir}/ipam.ttf \ 100 if [ ! -f /usr/share/fonts/alias/TrueType/fonts-japanese-mincho.ttf ] ; then /sbin/update-alternatives --auto fonts-japanese-mincho.ttf fi %posttrans gothic update-alternatives --install \ /usr/share/fonts/alias/TrueType/fonts-japanese-gothic.ttf \ fonts-japanese-gothic.ttf \ %{_fontdir}/ipag.ttf \ 100 if [ ! -f /usr/share/fonts/alias/TrueType/fonts-japanese-gothic.ttf ] ; then /sbin/update-alternatives --auto fonts-japanese-gothic.ttf fi %preun mincho if [ $1 -eq 0 ]; then update-alternatives --remove \ fonts-japanese-mincho.ttf \ %{_fontdir}/ipam.ttf /sbin/update-alternatives --auto fonts-japanese-mincho.ttf ||: fi %preun gothic if [ $1 -eq 0 ]; then update-alternatives --remove \ fonts-japanese-gothic.ttf \ %{_fontdir}/ipag.ttf /sbin/update-alternatives --auto fonts-japanese-gothic.ttf ||: fi %postun mincho %__font_install_postun %{_fontdir} %postun gothic %__font_install_postun %{_fontdir} %files %files doc %doc *.txt %files mincho %license IPA_Font_License_Agreement_v1.0.txt %{_fontdir}/ipam*.ttf %{_fontdir}/ipafont-mincho.ttfconf #%config %{_datadir}/ghostscript/conf.d/cidfmap.ja.ipafont-mincho %{_sysconfdir}/fonts/conf.avail/*-ipa-mincho.conf %{_sysconfdir}/X11/fontpath.d/%{name} %config(missingok,noreplace) %{_sysconfdir}/fonts/conf.d/*-ipa-mincho.conf %files gothic %license IPA_Font_License_Agreement_v1.0.txt %{_fontdir}/ipag*.ttf %{_fontdir}/ipafont-gothic.ttfconf #%config %{_datadir}/ghostscript/conf.d/cidfmap.ja.ipafont-gothic %{_sysconfdir}/fonts/conf.avail/*-ipa-gothic.conf %config(missingok,noreplace) %{_sysconfdir}/fonts/conf.d/*-ipa-gothic.conf %changelog * Sun May 03 2020 Tomohiro "Tomo-p" KATO 3.03-4 - made to use alternatives for new ghostscript structure. * Wed Jul 13 2016 IWAI, Masaharu 3.03-3 - fix fontconfig files (Source30, 31) for fontconfig 2.10 - sync Vine Linux Git repository * Mon Jan 13 2014 TANAKA hiroaki - built with gcc-4.8 * Sun Nov 20 2011 Daisuke SUZUKI 3.03-1 - update to IPAfont 00303 * Fri Sep 24 2010 Daisuke SUZUKI 3.02-1 - update to IPAfont 00302 - update ttfconf/cidfmap * Mon Aug 24 2009 Daisuke SUZUKI 3.01-3 - add fontpath.d symlink * Wed Jun 03 2009 Daisuke SUZUKI 3.01-2 - use fixed width font for ghostscript. * Wed Apr 22 2009 Daisuke SUZUKI 3.01-1 - update to IPAfont 00301 - drop IPAUIGothic - update License tag - OSI approved license 'IPA Font License Agreement v1.0' - add fontconfig file * Thu Jan 08 2009 Daisuke SUZUKI 2.01-2 - fix typo in cidfmap.ja.ipafont - update vine.map and exec updmap-sys on %%post/%%postun * Wed Oct 29 2008 Daisuke SUZUKI 2.01-1 - add gs8 cidfmap - move font files to new location - new versioning policy, spec in utf-8 * Fri Jan 11 2008 Daisuke SUZUKI 2.01-0vl2 - remove Provides: TrueTypeFonts_jp - ipa*font is not free and should not be default font. * Mon Oct 01 2007 Daisuke SUZUKI 2.01-0vl1 - initial build with new ipafont license - sprit mincho and gothic as an independent package - sprit readme and license to doc package - drop M+IPA font which is not allowed by new enduser license.