rpms/monafont/F-8 monafont.spec, NONE, 1.1 .cvsignore, 1.1, 1.2 sources, 1.1, 1.2

Mamoru Tasaka (mtasaka) fedora-extras-commits at redhat.com
Mon Aug 4 20:06:33 UTC 2008


Author: mtasaka

Update of /cvs/extras/rpms/monafont/F-8
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv11102/F-8

Modified Files:
	.cvsignore sources 
Added Files:
	monafont.spec 
Log Message:
initial commit


--- NEW FILE monafont.spec ---
%define		fontname		mona-fonts
%define		archivename		monafont

%define		name_bitmap		%{fontname}-bitmap
%define		name_ttf_s		%{fontname}-sazanami
%define		name_ttf_v		%{fontname}-VLGothic

%define		fontbasedir		%{_datadir}/fonts
%define 	fontdir_bitmap		%{fontbasedir}/%{name_bitmap}
%define		fontdir_ttf_s		%{fontbasedir}/%{name_ttf_s}
%define		fontdir_ttf_v		%{fontbasedir}/%{name_ttf_v}

%if 0%{?fedora} >= 10
%define		sazanami_ver		20040629
%define		vlgothic_ver		20080624
%endif
%if 0%{?fedora} == 9
%define		sazanami_ver		20040629
%define		vlgothic_ver		20071215
%endif
%if 0%{?fedora} <= 8
%define		sazanami_ver		20040629
%define		vlgothic_ver		20071215
%endif

%define		catalog_dir		%{_sysconfdir}/X11/fontpath.d

# misc
%define		show_progress		0
%if 0%{?fedora} <= 8
%define		use_f_option		1
%else
%undefine	use_f_option
%endif

Name:		%{archivename}
Version:	2.90
Release:	4%{?dist}
Summary:	Japanese font for text arts

# monafont itself is under public domain
Group:		User Interface/X
License:	Public Domain
URL:		http://monafont.sourceforge.net/
Source0:	http://downloads.sourceforge.net/monafont/%{archivename}-%{version}.tar.bz2
BuildRoot:	%{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)

BuildArch:	noarch
# Write BuildRequires seperately

%description
Mona Font is a Japanese proportional font which allows you to view
Japanese text arts correctly.


%package -n	%{name_bitmap}
Summary:	Bitmap Japanese font for text arts
Group:		User Interface/X
License:	Public Domain

# Write BuildRequires a bit verbosely
BuildRequires:	perl
BuildRequires:	xorg-x11-font-utils

%description -n	%{name_bitmap}
Mona Font is a Japanese proportional font which allows you to view
Japanese text arts correctly.


%package -n	%{name_ttf_s}
Summary:	True Type Japanese font for text arts based on Sazanami
Group:		User Interface/X
# monafont itself is Public Domain and this package borrows
# Sazanami
License:	BSD

BuildRequires:	sazanami-fonts-gothic = 0.%{sazanami_ver}

%description -n	%{name_ttf_s}
Mona Font is a Japanese proportional font which allows you to view
Japanese text arts correctly.

This package contains True Type fonts generated generated from
%{name} source package which are based on Sazanami fonts.

%package -n	%{name_ttf_v}
Summary:	True Type Japanese font for text arts based on VLGothic
Group:		User Interface/X
# monafont itself is Public Domain and this package borrows
# VLGothic (mplus and BSD)
# And the outline otf uses Kochi-substitute (later renamed to sazanami),
# which is under BSD
License:	mplus and BSD

BuildRequires:	VLGothic-fonts = %{vlgothic_ver}

%description -n	%{name_ttf_v}
Mona Font is a Japanese proportional font which allows you to view
Japanese text arts correctly.

This package contains True Type fonts generated generated from
%{name} source package which are based on VLGothic fonts.

%prep
%setup -q
iconv -f EUC-JP -t UTF-8 README.euc > README
touch -r README.euc README
iconv -f SHIFT-JIS -t UTF-8 ttfsrc/README-ttf.txt > ttfsrc/README-ttf.txt.tmp
touch -r ttfsrc/README-ttf.txt ttfsrc/README-ttf.txt.tmp
mv -f ttfsrc/README-ttf.txt.tmp ttfsrc/README-ttf.txt

%if ! %{show_progress}
# In the build on koji, showing progress bar is rather dirty
grep -rl '\\rprogress' . | xargs sed -i.bar -e '/\\rprogress/s|print|# print|'
%endif


%build
## Not using parallel make

# 1. bitmap fonts
make bdf

# 2. ttf
cd ttfsrc
cp -p name.src name.src.orig

## 2.1 ttf based on sazanami
sed -e 's|^Mona$|Mona-sazanami|' name.src.orig > name.src
make clean
make \
	BASE_OUTLINE_TTF=%{fontbasedir}/sazanami-fonts-gothic/sazanami-gothic.ttf \
	BASE_OUTLINE_VERSION=sazanami-%{sazanami_ver}
mv mona.ttf mona-sazanami.ttf

## 2.2 ttf based on VLGothic
sed -e 's|^Mona$|Mona-VLGothic|' name.src.orig > name.src
make clean
make \
	BASE_OUTLINE_TTF=%{fontbasedir}/VLGothic/VL-Gothic-Regular.ttf \
	BASE_OUTLINE_VERSION=VLGothic-%{vlgothic_ver}
mv mona.ttf mona-VLGothic.ttf

cd ..

%install
rm -rf $RPM_BUILD_ROOT

# 1. bitmap fonts
mkdir -p -m 0755 $RPM_BUILD_ROOT%{fontdir_bitmap}
make install \
	X11BINDIR=%{_bindir} \
	MKDIRHIER="mkdir -p" \
	X11FONTDIR=$RPM_BUILD_ROOT%{fontdir_bitmap} \
	GZIP_CMD="gzip -9" \
	install
install -cpm 644 fonts.alias.mona \
	$RPM_BUILD_ROOT%{fontdir_bitmap}/fonts.alias

## catalog symlink
mkdir -p $RPM_BUILD_ROOT%{catalog_dir}
pushd $RPM_BUILD_ROOT%{catalog_dir}

UPWARDDIR="../../.."
ln -sf ${UPWARDDIR}%{fontdir_bitmap} %{name_bitmap}
if [ ! -f $UPWARDDIR%{fontdir_bitmap}/fonts.dir ] ; then
	echo "Perhaps symlink target is wrong"
	exit 1
fi
popd


# 2. ttf
cd ttfsrc
mkdir -p -m 0755 \
	$RPM_BUILD_ROOT%{fontdir_ttf_s} \
	$RPM_BUILD_ROOT%{fontdir_ttf_v}
install -cpm 644 mona-sazanami.ttf $RPM_BUILD_ROOT%{fontdir_ttf_s}/
install -cpm 644 mona-VLGothic.ttf $RPM_BUILD_ROOT%{fontdir_ttf_v}/
cd ..

%clean
rm -rf $RPM_BUILD_ROOT


%post -n	%{name_bitmap}
if [ -x %{_bindir}/fc-cache ] ; then
	%{_bindir}/fc-cache %{?use_f_option:-f %{fontdir_bitmap}} || :
fi

%post -n	%{name_ttf_s}
if [ -x %{_bindir}/fc-cache ] ; then
	%{_bindir}/fc-cache %{?use_f_option:-f %{fontdir_ttf_s}} || :
fi

%post -n	%{name_ttf_v}
if [ -x %{_bindir}/fc-cache ] ; then
	%{_bindir}/fc-cache %{?use_f_option:-f %{fontdir_ttf_v}} || :
fi

%postun -n	%{name_bitmap}
if [ $1 -eq 0 -a -x %{_bindir}/fc-cache ] ; then
	%{_bindir}/fc-cache %{?use_f_option:-f %{fontdir_bitmap}} || :
fi

%postun -n	%{name_ttf_s}
if [ $1 -eq 0 -a -x %{_bindir}/fc-cache ] ; then
	%{_bindir}/fc-cache %{?use_f_option:-f %{fontdir_ttf_s}} || :
fi

%postun -n	%{name_ttf_v}
if [ $1 -eq 0 -a -x %{_bindir}/fc-cache ] ; then
	%{_bindir}/fc-cache %{?use_f_option:-f %{fontdir_ttf_v}} || :
fi


%files -n	%{name_bitmap}
%defattr(0644,root,root,0755)
%doc	README
%doc	README.ascii

%{catalog_dir}/%{name_bitmap}
%dir				%{fontdir_bitmap}
%verify(not md5 size mtime)	%{fontdir_bitmap}/fonts.alias
%verify(not md5 size mtime)	%{fontdir_bitmap}/fonts.dir
%{fontdir_bitmap}/*.pcf.gz


%files -n	%{name_ttf_s}
%defattr(0644,root,root,0755)
%doc	ttfsrc/README-ttf.txt
%dir	%{fontdir_ttf_s}
%{fontdir_ttf_s}/mona-sazanami.ttf


%files -n	%{name_ttf_v}
%defattr(0644,root,root,0755)
%doc	ttfsrc/README-ttf.txt
%dir	%{fontdir_ttf_v}
%{fontdir_ttf_v}/mona-VLGothic.ttf


%changelog
* Tue Aug  5 2008 Mamoru Tasaka <mtasaka at ioa.s.u-tokyo.ac.jp> - 2.90-4
- Bump

* Mon Jul 28 2008 Mamoru Tasaka <mtasaka at ioa.s.u-tokyo.ac.jp> - 2.90-3
- Rewrite

* Sun Jul  6 2008 Mamoru Tasaka <mtasaka at ioa.s.u-tokyo.ac.jp> - 2.90-2
- Gerenal packaing fix according to Fedora fonts packaing
  conventions

* Sat Jul  5 2008 Mamoru Tasaka <mtasaka at ioa.s.u-tokyo.ac.jp> - 2.90-1
- Initial packaging


Index: .cvsignore
===================================================================
RCS file: /cvs/extras/rpms/monafont/F-8/.cvsignore,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- .cvsignore	4 Aug 2008 18:51:41 -0000	1.1
+++ .cvsignore	4 Aug 2008 20:06:03 -0000	1.2
@@ -0,0 +1 @@
+monafont-2.90.tar.bz2


Index: sources
===================================================================
RCS file: /cvs/extras/rpms/monafont/F-8/sources,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- sources	4 Aug 2008 18:51:41 -0000	1.1
+++ sources	4 Aug 2008 20:06:03 -0000	1.2
@@ -0,0 +1 @@
+2b914878b19b1550757cea5d8a771612  monafont-2.90.tar.bz2




More information about the fedora-extras-commits mailing list