%define archivename umefont
%define _fontdir %{_datadir}/fonts/TrueType-umefont
%define package_ver 424

Name: TrueType-umefont
Summary: Ume Fonts are Japanese fonts that the license restriction is a little
Summary(ja): 梅フォント - ライセンス制約の少ない日本語フォント

Version: %{package_ver}
Release: 1%{?_dist_release}
License: mplus Font License
Group: User Interface/X

BuildArch: noarch
BuildRoot: %{_tmppath}/%{name}-%{version}-root
URL: http://sourceforge.jp/projects/%{archivename}/wiki/FrontPage

%if %{?_dist_release} == "vl5"
Source: %{archivename}_%{package_ver}.tar.bz2
%endif

%if %{?_dist_release} == "vl6"
Source: %{archivename}_%{package_ver}.tar.xz
BuildRequires: xz
%endif

Requires: TrueType-%{archivename}-mincho = %{version}
Requires: TrueType-%{archivename}-gothic = %{version}
Requires: TrueType-%{archivename}-doc = %{version}

%description
Ume Fonts are Japanese fonts that to be able to be using
that the license restriction is a little regularly it.

%description -l ja
梅フォントはライセンス制約の少ない常用可能な日本語フォントです。
このパッケージは明朝、ゴシック両書体をインストールするためのメタパッケージです。

#-- 明朝
%package mincho
Summary: Ume Mincho TrueType Fonts
Summary(ja): 梅フォント（明朝体）
Group: User Interface/X
Requires: TrueType-umefont-doc

%description mincho
This package includes Ume Mincho TrueType fonts.

%description -l ja mincho
このパッケージには梅フォントの明朝体フォントが含まれています。

プロポーショナル：梅P明朝
等幅：梅明朝

#-- ゴシック
%package gothic
Summary: Ume Gothic TrueType Fonts
Summary(ja): 梅フォント（ゴシック体）
Group: User Interface/X
Requires: TrueType-umefont-doc

%description gothic
This package includes Ume Gothic TrueType fonts.

%description -l ja gothic
このパッケージには梅フォントのゴシック体フォントが含まれています。

プロポーショナル：梅PゴシックC4、梅PゴシックC5、梅Pゴシック、梅PゴシックO5
等幅：梅ゴシックC4、梅ゴシックC5、梅ゴシック、梅ゴシックO5
UI：梅UIゴシック、梅UIゴシックO5

#-- ドキュメント
%package doc
Summary: ume Font Documents
Summary(ja): 梅フォントドキュメント
Group: User Interface/X

%description doc
This package includes license for ume fonts enduser.

%description -l ja doc
このパッケージには梅フォントのライセンスが含まれています。

%prep
%setup -q -n %{archivename}_%{package_ver}

%build

%install
/bin/rm -rf $RPM_BUILD_ROOT

mkdir -p $RPM_BUILD_ROOT%{_fontdir}
cp -a *.ttf $RPM_BUILD_ROOT%{_fontdir}

%clean
rm -rf $RPM_BUILD_ROOT

%post mincho
%__font_install_post %{_fontdir}

%post gothic
%__font_install_post %{_fontdir}

%postun mincho
%__font_install_postun %{_fontdir}

%postun gothic
%__font_install_postun %{_fontdir}

%files

%files mincho
%{_fontdir}/ume-*m*3.ttf

%files gothic
%{_fontdir}/ume-pg*.ttf
%{_fontdir}/ume-ugo*.ttf
%{_fontdir}/ume-tg*.ttf

%files doc
%doc *.html

%changelog
* Tue Feb 8 2011 Toshiharu Kudoh <toshi.kd2@gmail.com> 424-1
- new upstream release

* Tue Jan 4 2011 Toshiharu Kudoh <toshi.kd2@gmail.com> 423-1
- new upstream release

* Tue Dec 7 2010 Toshiharu Kudoh <toshi.kd2@gmail.com> 422-1
- new upstream release

* Tue Nov 2 2010 Toshiharu Kudoh <toshi.kd2@gmail.com> 421-1
- new upstream release
- added BuildRequires: xz (VineSeed)

* Sun Oct 3 2010 Toshiharu Kudoh <toshi.kd2@gmail.com> 420-1
- new upstream release

* Mon Sep 6 2010 Toshiharu Kudoh <toshi.kd2@gmail.com> 419-1
- new upstream release

* Tue Aug 3 2010 Toshiharu Kudoh <toshi.kd2@gmail.com> 418-1
- new upstream release

* Mon Jul 5 2010 Toshiharu Kudoh <toshi.kd2@gmail.com> 417-1
- new upstream release

* Tue Jun 8 2010 Toshiharu Kudoh <toshi.kd2@gmail.com> 416-2
- reverted and changed source archive type on Vine 5.x
  - Seed's source archive type is keeping (using tar.xz)

* Mon Jun 7 2010 Toshiharu Kudoh <toshi.kd2@gmail.com> 416-1
- new upstream release
- changed source archive type

* Tue May 4 2010 Toshiharu Kudoh <toshi.kd2@gmail.com> 415-1
- new upstream release

* Wed Mar 3 2010 Toshiharu Kudoh <toshi.kd2@gmail.com> 413-1
- new upstream release

* Mon Feb 1 2010 Toshiharu Kudoh <toshi.kd2@gmail.com> 412-1
- new upstream release

* Tue Jan 5 2010 Toshiharu Kudoh <toshi.kd2@gmail.com> 411-1
- new upstream release

* Mon Dec 14 2009 Toshiharu Kudoh <toshi.kd2@gmail.com> 410-1
- new upstream release

* Tue Nov 10 2009 Toshiharu Kudoh <toshi.kd2@gmail.com> 409-1
- new upstream release

* Wed Oct 7 2009 Toshiharu Kudoh <toshi.kd2@gmail.com> 408-1
- new upstream release

* Thu Sep 10 2009 Toshiharu Kudoh <toshi.kd2@gmail.com> 407-1
- new upstream release

* Tue Aug 4 2009 Toshiharu Kudoh <toshi.kd2@gmail.com> 406-1vl5
- new upstream release

* Tue Jul 7 2009 Toshiharu Kudoh <toshi.kd2@gmail.com> 405-1vl5
- new upstream release

* Fri Jun 19 2009 Toshiharu Kudoh <toshi.kd2@gmail.com> 404-2vl5
- fixed License (Umefont License to mplus Font License)
- changed summary, summary(ja)

* Mon Jun 1 2009 Toshiharu Kudoh <toshi.kd2@gmail.com> 404-1vl5
- new upstream release

* Thu May 7 2009 Toshiharu Kudoh <toshi.kd2@gmail.com> 403-1vl5
- new upstream release
- changed License, summary, description
- spec in UTF-8

* Sat Apr 25 2009 Toshiharu Kudoh <toshi.kd2@gmail.com> 402-1vl5
- initial build for VineSeed
