3 %bcond_with license_agreement # generates package
5 Summary: Bitstream Cyberfonts True Type font
6 Summary(pl): Font True Type Cyberfonts firmy Bitstream
7 %define base_name fonts-TTF-Bitstream-Cyberfonts
8 %if %{with license_agreement}
11 Name: %{base_name}-installer
14 Release: 1%{?with_license_agreement:wla}
15 License: Nondistributable but free (See Bitstream-Cyberfonts-licence.txt)
17 %if %{with license_agreement}
18 # also at http://dl.sourceforge.net/corefonts/
19 Source0: ftp://ftp.netscape.com/pub/communicator/extras/fonts/windows/Cyberbit.ZIP
20 # NoSource0-md5: 63a6f607ac5a78d34b67247b893faf5b
21 Source1: ftp://ftp.netscape.com/pub/communicator/extras/fonts/windows/Cyberbase.ZIP
22 # NoSource1-md5: 63a6f607ac5a78d34b67247b893faf5b
23 Source2: ftp://ftp.netscape.com/pub/communicator/extras/fonts/windows/CyberCJK.ZIP
24 # NoSource2-md5: 63a6f607ac5a78d34b67247b893faf5b
25 Source3: %{base_name}-licence.txt
27 Requires: %{_fontsdir}/TTF
28 Requires(post,postun): fontpostinst
31 Requires: rpm-build-tools
35 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
37 %define ttffontsdir %{_fontsdir}/TTF
40 Bitstream Cyberfonts True Type font.
41 %if ! %{with license_agreement}
42 License issues made us not to include inherent files into this package
43 by default. If you want to
44 create full working package please build it with one of the following
47 %{base_name}.install --with license_agreement %{_datadir}/%{base_name}/%{base_name}.spec
48 %{base_name}.install --with license_agreement ftp://ftp.pld-linux.org/dists/ac/PLD/<your_arch>/PLD/RPMS/%{base_name}-{version}-{release}.src.rpm
52 Font True Type Cyberfonts firmy Bitstream.
53 %if ! %{with license_agreement}
54 Kwestie licencji zmusi³y nas do niedo³±czania do tego pakietu istotnych
55 plików. Je¶li chcesz stworzyæ
56 w pe³ni funkcjonalny pakiet, zbuduj go za pomoc± polecenia:
58 %{base_name}.install --with license_agreement %{_datadir}/%{base_name}/%{base_name}.spec
59 %{base_name}.install --with license_agreement ftp://ftp.pld-linux.org/dists/ac/PLD/<your_arch>/PLD/RPMS/%{base_name}-{version}-{release}.src.rpm
63 %if %{with license_agreement}
65 /usr/bin/unzip -L %{SOURCE0}
66 /usr/bin/unzip -L %{SOURCE1}
67 /usr/bin/unzip -L %{SOURCE2}
72 rm -rf $RPM_BUILD_ROOT
73 %if ! %{with license_agreement}
74 install -d $RPM_BUILD_ROOT{%{_bindir},%{_datadir}/%{base_name}}
76 cat <<EOF >$RPM_BUILD_ROOT%{_bindir}/%{base_name}.install
78 if [ "\$1" = "--with" -a "\$2" = "license_agreement" ]
80 TMPDIR=\`rpm --eval "%%{tmpdir}"\`; export TMPDIR
81 SPECDIR=\`rpm --eval "%%{_specdir}"\`; export SPECDIR
82 SRPMDIR=\`rpm --eval "%%{_srcrpmdir}"\`; export SRPMDIR
83 SOURCEDIR=\`rpm --eval "%%{_sourcedir}"\`; export SOURCEDIR
84 BUILDDIR=\`rpm --eval "%%{_builddir}"\`; export BUILDDIR
85 RPMDIR=\`rpm --eval "%%{_rpmdir}"\`; export RPMDIR
87 mkdir -p \$TMPDIR \$SPECDIR \$SRPMDIR \$RPMDIR \$SRPMDIR \$SOURCEDIR \$BUILDDIR
88 if [ -f \$SPECDIR/%{base_name}.spec ]; then
90 mv -f \$SPECDIR/%{base_name}.spec \$SPECDIR/%{base_name}.spec.prev
92 if echo "\$3" | grep '\.src\.rpm$' >/dev/null; then
94 if echo "\$3" | grep '://' >/dev/null; then
95 wget --passive-ftp -t0 "\$3"
99 rpm2cpio \`basename "\$3"\` | ( cd \$TMPDIR; cpio -i %{base_name}.spec ) )
100 if ! cp -i \$TMPDIR/%{base_name}.spec \$SPECDIR/%{base_name}.spec; then
104 if ! cp -i "\$3" \$SPECDIR; then
109 %{_bindir}/builder -nc -ncs --with license_agreement --opts --target=%{_target_cpu} %{base_name}.spec
110 if [ "\$?" -ne 0 ]; then
113 RPMNAME=%{base_name}-%{version}-%{release}wla.noarch.rpm
114 rpm -U \$RPMDIR/\$RPMNAME || \
115 echo -e Install manually the file:\\\n \$RPMDIR/\$RPMNAME )
116 if [ "\$BACKUP_SPEC" -eq 1 ]; then
117 mv -f \$SPECDIR/%{base_name}.spec.prev \$SPECDIR/%{base_name}.spec
120 cat %{_datadir}/%{base_name}/Microsot-EULA.txt
122 License issues made us not to include inherent files into this package
123 by default. If you want to
124 create full working package please build it with the following command:
126 \$0 --with license_agreement %{_datadir}/%{base_name}/%{base_name}.spec
131 install %{_specdir}/%{base_name}.spec $RPM_BUILD_ROOT%{_datadir}/%{base_name}
133 install -d $RPM_BUILD_ROOT%{ttffontsdir}
134 install *.ttf $RPM_BUILD_ROOT%{ttffontsdir}
136 install -d $RPM_BUILD_ROOT%{_datadir}/%{base_name}
137 install %{SOURCE3} $RPM_BUILD_ROOT%{_datadir}/%{base_name}/Bitstream-Cyberfonts-licence.txt
140 rm -rf $RPM_BUILD_ROOT
142 %if %{with license_agreement}
152 If you accept the license enclosed in the file
153 %{_datadir}/%{base_name}/Bitstream-Cyberfonts-licence.txt
154 and want to install real fonts, then rebuild the package with the
157 %{base_name}.install --with license_agreement %{_datadir}/%{base_name}/%{base_name}.spec
162 %defattr(644,root,root,755)
163 %if %{with license_agreement}
166 %attr(755,root,root) %{_bindir}/%{base_name}.install
168 %{_datadir}/%{base_name}