3 %bcond_with qt4 # Qt 4 instead of Qt 5
4 %bcond_without static_libs # static library
6 Summary: Auto-generating hints for TrueType fonts
7 Summary(pl.UTF-8): Automatyczne generowanie hintingu dla fontów TrueType
11 License: FreeType License or GPL v2+
12 Group: Applications/Graphics
13 Source0: http://download.savannah.gnu.org/releases/freetype/%{name}-%{version}.tar.gz
14 # Source0-md5: 5e5b320217909ddfc9ba527cbf7ec823
15 URL: http://freetype.org/
16 BuildRequires: freetype-devel >= 1:2.4.5
17 BuildRequires: harfbuzz-devel >= 2.4.0
18 BuildRequires: pkgconfig >= 1:0.24
20 BuildRequires: QtCore-devel >= 4.8
21 BuildRequires: QtGui-devel >= 4.8
22 BuildRequires: qt4-build >= 4.8
24 BuildRequires: Qt5Core-devel >= 5.0
25 BuildRequires: Qt5Gui-devel >= 5.0
26 BuildRequires: Qt5Widgets-devel >= 5.0
27 BuildRequires: qt5-build >= 5.0
29 Requires: freetype >= 1:2.4.5
30 Requires: harfbuzz >= 2.4.0
31 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
33 %define qtmajor %{?with_qt4:4}%{!?with_qt4:5}
36 This project provides a utility which takes a TrueType font as the
37 input, remove its hinting bytecode instructions (if any), and return a
38 new font where all glyphs are bytecode hinted using the information
39 given by FreeType's autohinting module. The idea is to provide the
40 same quality of the autohinter on platforms which don't use FreeType.
42 %description -l pl.UTF-8
43 Ten projekt zapewnia narzędzie przyjmujące na wejściu fonty TrueType,
44 usuwające z nich instrukcje bajtkodowe hintingu (jeśli są) i tworzące
45 nowy font, w którym wszystkie glify wykorzystują hinting utworzony
46 przy użyciu modułu autohintingu z FreeType. Celem jest zapewnienie tej
47 samej jakości, którą daje autohinter, na platformach nie
48 wykorzystujących FreeType.
51 Summary: Header files for ttfautohint library
52 Summary(pl.UTF-8): Pliki nagłówkowe biblioteki ttfautohint
53 Group: Development/Libraries
54 Requires: %{name} = %{version}-%{release}
55 Requires: freetype-devel >= 1:2.4.5
56 Requires: harfbuzz-devel >= 2.4.0
59 Header files for ttfautohint automatic font hinting library.
61 %description devel -l pl.UTF-8
62 Pliki nagłówkowe biblioteki ttfautohint, służącej do automatycznego
66 Summary: Static ttfautohint library
67 Summary(pl.UTF-8): Statyczna biblioteka ttfautohint
68 Group: Development/Libraries
69 Requires: %{name}-devel = %{version}-%{release}
72 Static ttfautohint library.
74 %description static -l pl.UTF-8
75 Statyczna biblioteka ttfautohint.
78 Summary: GUI application to replace hints in a TrueType font
79 Summary(pl.UTF-8): Graficzna aplikacja do podmiany reguł hintingu w fontach TrueType
80 Group: X11/Applications/Graphics
82 Requires: QtGui >= 4.8
84 Requires: freetype >= 1:2.4.5
87 GUI application to replace hints in a TrueType font. The new hints are
88 based on FreeType's auto-hinter.
90 %description gui -l pl.UTF-8
91 Graficzna aplikacja do podmiany reguł hintingu w fontach TrueType.
92 Nowe reguły są oparte na auto-hinterze z FreeType.
99 MOC=/usr/bin/moc-qt%{qtmajor} \
100 QMAKE=/usr/bin/qmake-qt%{qtmajor} \
101 QTDIR=%{_libdir}/qt%{qtmajor} \
102 --disable-silent-rules \
103 %{!?with_static_libs:--disable-static}
108 rm -rf $RPM_BUILD_ROOT
111 DESTDIR=$RPM_BUILD_ROOT
113 # obsoleted by pkg-config
114 %{__rm} $RPM_BUILD_ROOT%{_libdir}/libttfautohint.la
116 # install (dist) man pages manually - requirements to automatically install them
117 # are insane ($DISPLAY + ImageMagick + inkscape + pandoc + xelatex + NotoSans fonts)
118 install -d $RPM_BUILD_ROOT%{_mandir}/man1
119 cp -p frontend/ttf*.1 $RPM_BUILD_ROOT%{_mandir}/man1
122 rm -rf $RPM_BUILD_ROOT
124 %post -p /sbin/ldconfig
125 %postun -p /sbin/ldconfig
128 %defattr(644,root,root,755)
129 %doc AUTHORS COPYING ChangeLog FTL.TXT NEWS README THANKS TODO
130 %attr(755,root,root) %{_bindir}/ttfautohint
131 %attr(755,root,root) %{_libdir}/libttfautohint.so.*.*.*
132 %attr(755,root,root) %ghost %{_libdir}/libttfautohint.so.1
133 %{_mandir}/man1/ttfautohint.1*
136 %defattr(644,root,root,755)
137 %attr(755,root,root) %{_libdir}/libttfautohint.so
138 %{_includedir}/ttfautohint*.h
139 %{_pkgconfigdir}/ttfautohint.pc
141 %if %{with static_libs}
143 %defattr(644,root,root,755)
144 %{_libdir}/libttfautohint.a
148 %defattr(644,root,root,755)
149 %attr(755,root,root) %{_bindir}/ttfautohintGUI
150 %{_mandir}/man1/ttfautohintGUI.1*