]>
Commit | Line | Data |
---|---|---|
6145ff55 | 1 | # |
2 | # Conditional build | |
3 | %bcond_with bytecode # use bytecode hinting instead of autohinting by default | |
2279380a | 4 | # |
6145ff55 | 5 | %define _realname fontconfig |
6 | Summary: Font configuration and customization tools - cross Mingw32 versoin | |
2279380a | 7 | Summary(pl.UTF-8): Narzędzia do konfigurowania fontów - wersja skrośna dla Mingw32 |
6145ff55 | 8 | Name: crossmingw32-%{_realname} |
9 | Version: 2.4.2 | |
10 | Release: 1 | |
11 | License: MIT | |
2279380a | 12 | Group: Development/Libraries |
6145ff55 | 13 | Source0: http://fontconfig.org/release/%{_realname}-%{version}.tar.gz |
14 | # Source0-md5: f035852f521b54677f2b5c9e2f6d54a4 | |
15 | Patch0: %{name}-dll.patch | |
16 | Patch1: %{_realname}-blacklist.patch | |
17 | Patch2: %{_realname}-autohint.patch | |
18 | Patch3: %{_realname}-bitstream-cyberbit.patch | |
19 | URL: http://fontconfig.org/ | |
20 | BuildRequires: autoconf | |
21 | BuildRequires: automake | |
22 | BuildRequires: crossmingw32-expat | |
23 | BuildRequires: crossmingw32-freetype >= 2.1.5 | |
2279380a JB |
24 | BuildRequires: crossmingw32-gcc |
25 | BuildRequires: libtool | |
26 | BuildRequires: pkgconfig | |
27 | Requires: crossmingw32-expat | |
6145ff55 | 28 | Requires: crossmingw32-freetype >= 2.1.5 |
29 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
30 | ||
31 | %define no_install_post_strip 1 | |
32 | ||
33 | %define target i386-mingw32 | |
34 | %define target_platform i386-pc-mingw32 | |
35 | %define arch %{_prefix}/%{target} | |
6145ff55 | 36 | |
37 | %define _sysprefix /usr | |
38 | %define _prefix %{_sysprefix}/%{target} | |
6145ff55 | 39 | %define _pkgconfigdir %{_libdir}/pkgconfig |
2279380a | 40 | %define _dlldir /usr/share/wine/windows/system |
6145ff55 | 41 | %define __cc %{target}-gcc |
42 | %define __cxx %{target}-g++ | |
43 | ||
44 | %description | |
45 | Fontconfig is designed to locate fonts within the system and select | |
46 | them according to requirements specified by applications. | |
47 | ||
2279380a | 48 | This package contains the cross version for Win32. |
6145ff55 | 49 | |
50 | %description -l pl.UTF-8 | |
51 | Fontconfig jest biblioteką przeznaczoną do lokalizowania fontów w | |
52 | systemie i wybierania ich w zależności od potrzeb aplikacji. | |
53 | ||
2279380a JB |
54 | Paket ten zawiera wersję skrośną dla Win32. |
55 | ||
56 | %package static | |
57 | Summary: Static freetype library (cross mingw32 version) | |
58 | Summary(pl.UTF-8): Statyczna biblioteka freetype (wersja skrośna mingw32) | |
59 | Group: Development/Libraries | |
60 | Requires: %{name} = %{version}-%{release} | |
61 | ||
62 | %description static | |
63 | Static freetype library (cross mingw32 version). | |
64 | ||
65 | %description static -l pl.UTF-8 | |
66 | Statyczna biblioteka freetype (wersja skrośna mingw32). | |
6145ff55 | 67 | |
2279380a JB |
68 | %package dll |
69 | Summary: DLL freetype library for Windows | |
70 | Summary(pl.UTF-8): Biblioteka DLL freetype dla Windows | |
71 | Group: Applications/Emulators | |
72 | Requires: crossmingw32-expat-dll | |
73 | Requires: crossmingw32-freetype-dll >= 2.1.5 | |
74 | Requires: wine | |
6145ff55 | 75 | |
2279380a JB |
76 | %description dll |
77 | DLL freetype library for Windows. | |
78 | ||
79 | %description dll -l pl.UTF-8 | |
80 | Biblioteka DLL freetype dla Windows. | |
6145ff55 | 81 | |
82 | %prep | |
83 | %setup -q -n %{_realname}-%{version} | |
9702f257 | 84 | #%patch0 -p1 |
6145ff55 | 85 | %patch1 -p1 |
86 | %if %{with bytecode} | |
87 | %patch2 -p1 | |
88 | %endif | |
89 | %patch3 -p1 | |
90 | ||
91 | %build | |
92 | export PKG_CONFIG_PATH=%{_prefix}/lib/pkgconfig | |
93 | %{__libtoolize} | |
94 | %{__aclocal} | |
95 | %{__autoconf} | |
96 | %{__autoheader} | |
97 | %{__automake} | |
98 | %configure \ | |
6145ff55 | 99 | --target=%{target} \ |
9702f257 | 100 | --host=%{target} \ |
101 | --with-arch=%{target} \ | |
6145ff55 | 102 | --disable-docs |
103 | ||
104 | %{__make} | |
105 | ||
106 | %install | |
107 | rm -rf $RPM_BUILD_ROOT | |
6145ff55 | 108 | |
109 | %{__make} install \ | |
110 | DESTDIR=$RPM_BUILD_ROOT | |
111 | ||
2279380a JB |
112 | install -d $RPM_BUILD_ROOT%{_dlldir} |
113 | mv -f $RPM_BUILD_ROOT%{_prefix}/bin/*.dll $RPM_BUILD_ROOT%{_dlldir} | |
114 | ||
115 | %if 0%{!?debug:1} | |
116 | %{target}-strip --strip-unneeded -R.comment -R.note $RPM_BUILD_ROOT%{_dlldir}/*.dll | |
117 | %{target}-strip -g -R.comment -R.note $RPM_BUILD_ROOT%{_libdir}/*.a | |
118 | %endif | |
119 | ||
120 | rm -rf $RPM_BUILD_ROOT%{_datadir}/man | |
121 | # runtime | |
122 | rm -rf $RPM_BUILD_ROOT/etc/fonts | |
6145ff55 | 123 | |
124 | %clean | |
125 | rm -rf $RPM_BUILD_ROOT | |
126 | ||
6145ff55 | 127 | %files |
128 | %defattr(644,root,root,755) | |
2279380a JB |
129 | %doc AUTHORS COPYING ChangeLog README |
130 | %{_libdir}/libfontconfig.dll.a | |
131 | %{_libdir}/libfontconfig.la | |
132 | %{_libdir}/fontconfig.def | |
9702f257 | 133 | %dir %{_includedir}/fontconfig |
134 | %{_includedir}/fontconfig/*.h | |
6145ff55 | 135 | %{_pkgconfigdir}/fontconfig.pc |
2279380a JB |
136 | |
137 | %files static | |
138 | %defattr(644,root,root,755) | |
139 | %{_libdir}/libfontconfig.a | |
140 | ||
141 | %files dll | |
142 | %defattr(644,root,root,755) | |
143 | %{_dlldir}/libfontconfig-*.dll |