]> git.pld-linux.org Git - packages/freetype1.git/blob - freetype1.spec
- ugly hack to make it build with recent autotools
[packages/freetype1.git] / freetype1.spec
1 # TODO:
2 # - fix build with libtool-2
3 #
4 # Conditional build:
5 %bcond_without  static_libs     # don't build static libraries
6 #
7 Summary:        Truetype font rasterizer
8 Summary(pl.UTF-8):      Rasteryzer fontów Truetype
9 Name:           freetype1
10 Version:        1.3.1
11 Release:        16
12 License:        BSD-like
13 Group:          Libraries
14 Source0:        ftp://ftp.freetype.org/freetype/freetype1/freetype-%{version}.tar.gz
15 # Source0-md5:  9a9e7ad00c1ef6dfbf8f8e19ceefb300
16 Patch0:         freetype-DESTDIR.patch
17 Patch1:         freetype-autoconf.patch
18 Patch2:         %{name}-po.patch
19 Patch3:         freetype-gcc33.patch
20 Patch4:         %{name}-parallel-make.patch
21 Patch5:         %{name}-link.patch
22 Patch6:         format-security.patch
23 URL:            http://freetype.sourceforge.net/freetype1/index.html
24 BuildRequires:  autoconf
25 BuildRequires:  automake
26 BuildRequires:  gettext-tools
27 BuildRequires:  libtool
28 BuildRequires:  xorg-lib-libX11-devel
29 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
30
31 %description
32 The FreeType engine is a free and portable TrueType font rendering
33 engine. It has been developed to provide TrueType support to a great
34 variety of platforms and environments.
35
36 Note that FreeType is a *library*. It is not a font server for your
37 favorite platform, even though it was designed to be used in many of
38 them. Note also that it is *not* a complete text-rendering library.
39 Its purpose is simply to open and manage font files, as well as load,
40 hint and render individual glyphs efficiently. You can also see it as
41 a "TrueType driver" for a higher-level library, though rendering text
42 with it is extremely easy, as demo-ed by the test programs.
43
44 %description -l pl.UTF-8
45 FreeType jest biblioteką służącą do rasteryzacji fontów TrueType. Jest
46 to jedynie biblioteka, a nie serwer fontów, chociaż została ona
47 zaprojektowana do używania także w takich serwerach. Nie jest to też
48 kompletna biblioteka do rasteryzacji tekstu. Jej celem jest tylko
49 odczytywanie i zarządzanie plikami z fontami oraz wczytywanie i
50 wykonywanie hintingu i rasteryzacji poszczególnych glifów. Może być
51 także uważana za "sterownik TrueType" dla bibliotek wyższego poziomu,
52 jednak użycie samej biblioteki FreeType do rasteryzacji jest bardzo
53 proste, co można zobaczyć w programach demonstracyjnych.
54
55 %package devel
56 Summary:        Header files and development documentation
57 Summary(pl.UTF-8):      Pliki nagłówkowe biblioteki freetype i dokumentacja
58 Group:          Development/Libraries
59 Requires:       %{name} = %{version}-%{release}
60 Provides:       freetype-devel = %{version}
61
62 %description devel
63 This package includes the header files documentations and libraries
64 necessary to develop applications that use freetype.
65
66 %description devel -l pl.UTF-8
67 Pakiet ten zawiera pliki nagłówkowe oraz biblioteki niezbędne przy
68 kompilowaniu programów wykorzystujących bibliotekę freetype.
69
70 %package static
71 Summary:        Freetype static libraries
72 Summary(pl.UTF-8):      Biblioteki statyczne freetype
73 Group:          Development/Libraries
74 Requires:       %{name}-devel = %{version}-%{release}
75 Provides:       freetype-static = %{version}
76
77 %description static
78 Static freetype libraries.
79
80 %description static -l pl.UTF-8
81 Biblioteki statyczne freetype.
82
83 %package progs
84 Summary:        Freetype library utilities
85 Summary(pl.UTF-8):      Programy użytkowe freetype
86 Group:          Applications
87 Requires:       %{name} = %{version}-%{release}
88 Provides:       freetype-progs = %{version}
89 Obsoletes:      freetype-utils
90 Obsoletes:      freetype-tools
91
92 %description progs
93 Freetype library utilites:
94 - ftimer - a simple performance timer for the engine,
95 - fzoom - very simple glyph viewer,
96 - ftlint - program will hint each glyph of a font file, at a given
97   point size,
98 - ftwiew - display all glyphs in a given font, applying hinting to
99   each one,
100 - fdump - a simple TrueType font or collection dumper,
101 - ftstring - a simple program to show off string text generation.
102 - ftstrpn - convert a rendered text string into the PGM or PBM format,
103 - fterror - small test program. Tests the gettext() functionality for
104   internationalized messages.
105
106 %description progs -l pl.UTF-8
107 Przykładowe aplikacje wykorzystujące freetype:
108 - ftimer - narzędzie mierzące szybkość silnika
109 - fzoom - prosta przeglądarka glifów
110 - ftlint - program robiący hinting każdego glifu z fontu przy podanym
111   rozmiarze
112 - ftview - program wyświetlający z hintingiem wszystkie glify z fontu
113 - fdump - narzędzie zrzucające dane z fontu lub zestawu fontów TT
114 - ftstring - prosty program obrazujący generowanie tekstu
115 - ftstrpn - konwerter zrenderowanego tekstu na format PGM/PBM
116 - fterror - prosty program testujący działanie gettext() w
117   zlokalizowanych komunikatach.
118
119 %prep
120 %setup -q -n freetype-%{version}
121 %patch0 -p1
122 %patch1 -p1
123 %patch2 -p1
124 %patch3 -p1
125 %patch4 -p1
126 %patch5 -p1
127 %patch6 -p1
128
129 %build
130 install /usr/share/automake/missing .
131 %{__gettextize}
132 # gettextize stupidity (doesn't see intl/Makefile in next lines after AC_OUTPUT)
133 sed -e 's@\(AC_OUTPUT.*\) intl/Makefile@\1@' configure.in > configure.in.tmp
134 mv -f configure.in.tmp configure.in
135 %{__libtoolize}
136 %{__aclocal}
137 %{__autoconf}
138 %configure \
139         %{?with_static_libs:--enable-static} \
140         --with-gnu-ld
141 %{__make}
142
143 cd contrib
144 # ttf2pfb ttf2pk don't build
145 for bdir in ttf2bdf ttfbanner; do
146         cd $bdir
147         %{__libtoolize}
148         %{__aclocal}
149         %{__autoconf}
150         %configure
151         %{__make} -j1
152         cd ..
153 done
154
155 %install
156 rm -rf $RPM_BUILD_ROOT
157
158 %{__make} install \
159         DESTDIR=$RPM_BUILD_ROOT
160
161 %find_lang freetype
162
163 # resolve conflict with freetype-demos-2.*
164 mv -f $RPM_BUILD_ROOT%{_bindir}/{ftdump,ft1dump}
165 mv -f $RPM_BUILD_ROOT%{_bindir}/{ftlint,ft1lint}
166 mv -f $RPM_BUILD_ROOT%{_bindir}/{ftview,ft1view}
167 mv -f $RPM_BUILD_ROOT%{_bindir}/{fttimer,ft1timer}
168
169 for bdir in ttf2bdf ttfbanner; do
170         %{__make} install -C contrib/$bdir \
171                 DESTDIR=$RPM_BUILD_ROOT
172 done
173
174 %clean
175 rm -rf $RPM_BUILD_ROOT
176
177 %post   -p /sbin/ldconfig
178 %postun -p /sbin/ldconfig
179
180 %files -f freetype.lang
181 %defattr(644,root,root,755)
182 %attr(755,root,root) %{_libdir}/libttf.so.*.*.*
183 %attr(755,root,root) %ghost %{_libdir}/libttf.so.2
184
185 %files devel
186 %defattr(644,root,root,755)
187 %doc howto/unix.txt README announce docs/{*.txt,FAQ,TODO,credits}
188 %attr(755,root,root) %{_libdir}/libttf.so
189 %{_libdir}/libttf.la
190 %{_includedir}/*
191
192 %if %{with static_libs}
193 %files static
194 %defattr(644,root,root,755)
195 %{_libdir}/lib*.a
196 %endif
197
198 %files progs
199 %defattr(644,root,root,755)
200 %attr(755,root,root) %{_bindir}/f*
201 %attr(755,root,root) %{_bindir}/ttf*
202 %{_mandir}/man1/ttf2bdf.1*
This page took 0.140893 seconds and 3 git commands to generate.