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