]> git.pld-linux.org Git - packages/crossmingw32-harfbuzz.git/blob - crossmingw32-harfbuzz.spec
b02e331a98c0739abaef6ecb58bd13de10ee4975
[packages/crossmingw32-harfbuzz.git] / crossmingw32-harfbuzz.spec
1 Summary:        HarfBuzz - internationalized text shaping library - MinGW32 cross version
2 Summary(pl.UTF-8):      Rasteryzer fontów TrueType - wersja skrośna dla MinGW32
3 Name:           crossmingw32-harfbuzz
4 Version:        2.7.0
5 Release:        1
6 License:        MIT
7 Group:          Development/Libraries
8 Source0:        https://github.com/harfbuzz/harfbuzz/archive/%{version}/harfbuzz-%{version}.tar.gz
9 # Source0-md5:  fee932e4063cef1f39cc575ecc0d1213
10 Patch0:         harfbuzz-win32.patch
11 URL:            https://harfbuzz.github.io/
12 BuildRequires:  autoconf >= 2.64
13 BuildRequires:  automake >= 1:1.13.0
14 BuildRequires:  crossmingw32-w32api >= 5.0.2-8
15 # cairo is used only for utilities, which are not packaged
16 #BuildRequires: crossmingw32-cairo >= 1.8.0
17 BuildRequires:  crossmingw32-freetype >= 2.9
18 BuildRequires:  crossmingw32-glib2 >= 2.38
19 BuildRequires:  crossmingw32-gcc-c++ >= 1:4.7
20 BuildRequires:  crossmingw32-pthreads-w32
21 BuildRequires:  gtk-doc >= 1.15
22 BuildRequires:  libtool >= 2:2.2
23 BuildRequires:  pkgconfig >= 1:0.20
24 Requires:       crossmingw32-freetype >= 2.9
25 Requires:       crossmingw32-glib2 >= 2.38
26 Requires:       crossmingw32-gcc-c++ >= 1:4.7
27 Requires:       crossmingw32-pthreads-w32
28 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
29
30 # see <harfbuzz/internal/ftserv.h>, the real horror
31 %define         specflags       -fno-strict-aliasing
32
33 %define         no_install_post_strip   1
34
35 %define         target                  i386-mingw32
36 %define         target_platform         i386-pc-mingw32
37
38 %define         _sysprefix              /usr
39 %define         _prefix                 %{_sysprefix}/%{target}
40 %define         _libdir                 %{_prefix}/lib
41 %define         _pkgconfigdir           %{_prefix}/lib/pkgconfig
42 %define         _dlldir                 /usr/share/wine/windows/system
43 %define         __cc                    %{target}-gcc
44 %define         __cxx                   %{target}-g++
45 %define         __pkgconfig_provides    %{nil}
46 %define         __pkgconfig_requires    %{nil}
47
48 %ifnarch %{ix86}
49 # arch-specific flags (like alpha's -mieee) are not valid for i386 gcc
50 %define         optflags        -O2 -march=i486
51 %endif
52 # -z options are invalid for mingw linker, most of -f options are Linux-specific
53 %define         filterout_ld    -Wl,-z,.*
54 %define         filterout_c     -f[-a-z0-9=]*
55 %define         filterout_cxx   -f[-a-z0-9=]*
56
57 %description
58 Internationalized OpenType text layout and rendering library.
59
60 This package contains the cross version for Win32.
61
62 %description -l pl.UTF-8
63 Biblioteka rozmieszczająca i rysująca tekst z fontów OpenType,
64 obsługująca wiele języków.
65
66 Ten pakiet zawiera wersję skrośną dla Win32.
67
68 %package static
69 Summary:        Static harfbuzz library (cross MinGW32 version)
70 Summary(pl.UTF-8):      Statyczna biblioteka harfbuzz (wersja skrośna MinGW32)
71 Group:          Development/Libraries
72 Requires:       %{name} = %{version}-%{release}
73
74 %description static
75 Static harfbuzz library (cross MinGW32 version).
76
77 %description static -l pl.UTF-8
78 Statyczna biblioteka harfbuzz (wersja skrośna MinGW32).
79
80 %package dll
81 Summary:        DLL harfbuzz library for Windows
82 Summary(pl.UTF-8):      Biblioteka DLL harfbuzz dla Windows
83 Group:          Applications/Emulators
84 Requires:       crossmingw32-freetype-dll >= 2.9
85 Requires:       crossmingw32-glib2-dll >= 2.38
86 Requires:       wine
87
88 %description dll
89 DLL harfbuzz library for Windows.
90
91 %description dll -l pl.UTF-8
92 Biblioteka DLL harfbuzz dla Windows.
93
94 %package subset
95 Summary:        HarfBuzz text shaping library - font subsetter - MinGW32 cross version
96 Summary(pl.UTF-8):      Biblioteka HarfBuzz do rysowania tekstu - font subsetter - wersja skrośna dla MinGW32
97 Group:          Development/Libraries
98 Requires:       %{name} = %{version}-%{release}
99
100 %description subset
101 HarfBuzz text shaping library - font subsetter.
102
103 This package contains the cross version for Win32.
104
105 %description subset -l pl.UTF-8
106 Biblioteka HarfBuzz do rysowania tekstu - font subsetter.
107
108 Ten pakiet zawiera wersję skrośną dla Win32.
109
110 %package subset-static
111 Summary:        Static HarfBuzz subset library (cross MinGW32 version)
112 Summary(pl.UTF-8):      Biblioteka statyczna HarfBuzz subset (wersja skrośna MinGW32)
113 Group:          Development/Libraries
114 Requires:       %{name}-subset = %{version}-%{release}
115
116 %description subset-static
117 Static HarfBuzz subset library (cross MinGW32 version).
118
119 %description subset-static -l pl.UTF-8
120 Biblioteka statyczna HarfBuzz subset (wersja skrośna MinGW32).
121
122 %package subset-dll
123 Summary:        DLL HarfBuzz subset library for Windows
124 Summary(pl.UTF-8):      Biblioteka DLL HarfBuzz subset dla Windows
125 Group:          Applications/Emulators
126 Requires:       %{name}-dll = %{version}-%{release}
127
128 %description subset-dll
129 DLL HarfBuzz subset library for Windows.
130
131 %description subset-dll -l pl.UTF-8
132 Biblioteka DLL HarfBuzz subset dla Windows.
133
134 %prep
135 %setup -q -n harfbuzz-%{version}
136 %patch0 -p1
137
138 %build
139 %{__libtoolize}
140 %{__gtkdocize}
141 %{__aclocal} -I m4
142 %{__autoconf}
143 %{__autoheader}
144 %{__automake}
145 export PKG_CONFIG_LIBDIR=%{_pkgconfigdir}
146 # MingW32 headers require GNU extensions (-std=c++11 doesn't work)
147 %configure \
148         CPPFLAGS="%{rpmcppflags} -D_GNU_SOURCE" \
149         CXXFLAGS="%{rpmcxxflags} -std=gnu++11" \
150         PTHREAD_LIBS="-lpthread" \
151         --target=%{target} \
152         --build=i686-pc-linux-gnu \
153         --host=%{target} \
154         --disable-gtk-doc \
155         --disable-silent-rules \
156         --enable-static \
157         --without-cairo \
158         --with-freetype \
159         --with-glib \
160         --without-graphite2 \
161         --with-html-dir=%{_gtkdocdir} \
162         --without-icu \
163         --with-uniscribe
164
165 %{__make}
166
167 %install
168 rm -rf $RPM_BUILD_ROOT
169
170 %{__make} install \
171         DESTDIR=$RPM_BUILD_ROOT
172
173 install -d $RPM_BUILD_ROOT%{_dlldir}
174 %{__mv} $RPM_BUILD_ROOT%{_prefix}/bin/*.dll $RPM_BUILD_ROOT%{_dlldir}
175
176 %{__rm} $RPM_BUILD_ROOT%{_libdir}/lib*.la
177
178 %if 0%{!?debug:1}
179 %{target}-strip --strip-unneeded -R.comment -R.note $RPM_BUILD_ROOT%{_dlldir}/*.dll
180 %{target}-strip -g -R.comment -R.note $RPM_BUILD_ROOT%{_libdir}/*.a
181 %endif
182
183 %{__rm} -r $RPM_BUILD_ROOT%{_libdir}/cmake/harfbuzz
184 %{__rm} $RPM_BUILD_ROOT%{_bindir}/hb*.exe
185 %{__rm} -rf $RPM_BUILD_ROOT%{_gtkdocdir}
186
187 %clean
188 rm -rf $RPM_BUILD_ROOT
189
190 %files
191 %defattr(644,root,root,755)
192 %doc COPYING README TODO
193 %{_libdir}/libharfbuzz.dll.a
194 %dir %{_includedir}/harfbuzz
195 %{_includedir}/harfbuzz/hb.h
196 %{_includedir}/harfbuzz/hb-aat.h
197 %{_includedir}/harfbuzz/hb-aat-layout.h
198 %{_includedir}/harfbuzz/hb-blob.h
199 %{_includedir}/harfbuzz/hb-buffer.h
200 %{_includedir}/harfbuzz/hb-common.h
201 %{_includedir}/harfbuzz/hb-deprecated.h
202 %{_includedir}/harfbuzz/hb-draw.h
203 %{_includedir}/harfbuzz/hb-face.h
204 %{_includedir}/harfbuzz/hb-font.h
205 %{_includedir}/harfbuzz/hb-ft.h
206 %{_includedir}/harfbuzz/hb-glib.h
207 %{_includedir}/harfbuzz/hb-map.h
208 %{_includedir}/harfbuzz/hb-ot-color.h
209 %{_includedir}/harfbuzz/hb-ot-deprecated.h
210 %{_includedir}/harfbuzz/hb-ot-font.h
211 %{_includedir}/harfbuzz/hb-ot-layout.h
212 %{_includedir}/harfbuzz/hb-ot-math.h
213 %{_includedir}/harfbuzz/hb-ot-meta.h
214 %{_includedir}/harfbuzz/hb-ot-metrics.h
215 %{_includedir}/harfbuzz/hb-ot-name.h
216 %{_includedir}/harfbuzz/hb-ot-shape.h
217 %{_includedir}/harfbuzz/hb-ot-var.h
218 %{_includedir}/harfbuzz/hb-ot.h
219 %{_includedir}/harfbuzz/hb-set.h
220 %{_includedir}/harfbuzz/hb-shape-plan.h
221 %{_includedir}/harfbuzz/hb-shape.h
222 %{_includedir}/harfbuzz/hb-style.h
223 %{_includedir}/harfbuzz/hb-unicode.h
224 %{_includedir}/harfbuzz/hb-uniscribe.h
225 %{_includedir}/harfbuzz/hb-version.h
226 %{_pkgconfigdir}/harfbuzz.pc
227
228 %files static
229 %defattr(644,root,root,755)
230 %{_libdir}/libharfbuzz.a
231
232 %files dll
233 %defattr(644,root,root,755)
234 %{_dlldir}/libharfbuzz-0.dll
235
236 %files subset
237 %defattr(644,root,root,755)
238 %{_libdir}/libharfbuzz-subset.dll.a
239 %{_includedir}/harfbuzz/hb-subset.h
240 %{_pkgconfigdir}/harfbuzz-subset.pc
241
242 %files subset-static
243 %defattr(644,root,root,755)
244 %{_libdir}/libharfbuzz-subset.a
245
246 %files subset-dll
247 %defattr(644,root,root,755)
248 %{_dlldir}/libharfbuzz-subset-0.dll
This page took 0.096432 seconds and 2 git commands to generate.