]> git.pld-linux.org Git - packages/crossmingw32-freetype.git/blob - crossmingw32-freetype.spec
do not provide pkgconfig deps in system namespace
[packages/crossmingw32-freetype.git] / crossmingw32-freetype.spec
1 #
2 # Conditional build:
3 %bcond_without  lcd             # without LCD subpixel color filtering (Microsoft patents in USA)
4 #
5 %define         realname   freetype
6 Summary:        TrueType font rasterizer - MinGW32 cross version
7 Summary(pl.UTF-8):      Rasteryzer fontów TrueType - wersja skrośna dla MinGW32
8 Name:           crossmingw32-%{realname}
9 Version:        2.4.11
10 Release:        2
11 License:        GPL v2 or FTL
12 Group:          Development/Libraries
13 Source0:        http://downloads.sourceforge.net/freetype/%{realname}-%{version}.tar.bz2
14 # Source0-md5:  b93435488942486c8d0ca22e8f768034
15 URL:            http://www.freetype.org/
16 BuildRequires:  crossmingw32-bzip2
17 BuildRequires:  crossmingw32-gcc
18 BuildRequires:  crossmingw32-zlib >= 1.2.3-2
19 BuildRequires:  python
20 Requires:       crossmingw32-bzip2
21 Requires:       crossmingw32-zlib >= 1.2.3-2
22 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
23
24 %define         specflags_ia32  -fomit-frame-pointer
25 # see <freetype/internal/ftserv.h>, the real horror
26 %define         specflags       -fno-strict-aliasing
27
28 %define         no_install_post_strip   1
29
30 %define         target                  i386-mingw32
31 %define         target_platform         i386-pc-mingw32
32
33 %define         _sysprefix              /usr
34 %define         _prefix                 %{_sysprefix}/%{target}
35 %define         _libdir                 %{_prefix}/lib
36 %define         _pkgconfigdir           %{_prefix}/lib/pkgconfig
37 %define         _dlldir                 /usr/share/wine/windows/system
38 %define         __cc                    %{target}-gcc
39 %define         __cxx                   %{target}-g++
40 %define         __pkgconfig_provides    %{nil}
41
42 %ifnarch %{ix86}
43 # arch-specific flags (like alpha's -mieee) are not valid for i386 gcc
44 %define         optflags        -O2
45 %endif
46 # -z options are invalid for mingw linker
47 %define         filterout_ld    -Wl,-z,.*
48
49 %description
50 The FreeType engine is a free and portable TrueType font rendering
51 engine. It has been developed to provide TrueType support to a great
52 variety of platforms and environments.
53
54 Note that FreeType is a *library*. It is not a font server for your
55 favorite platform, even though it was designed to be used in many of
56 them. Note also that it is *not* a complete text-rendering library.
57 Its purpose is simply to open and manage font files, as well as load,
58 hint and render individual glyphs efficiently. You can also see it as
59 a "TrueType driver" for a higher-level library, though rendering text
60 with it is extremely easy, as demo-ed by the test programs.
61
62 This package contains the cross version for Win32.
63
64 %description -l pl.UTF-8
65 FreeType jest biblioteką służącą do rasteryzacji fontów
66 TrueType. Jest to jedynie biblioteka, a nie serwer fontów, chociaż
67 została ona zaprojektowana do używania także w takich serwerach.
68 Nie jest to też kompletna biblioteka do rasteryzacji tekstu. Jej
69 celem jest tylko odczytywanie i zarządzanie plikami z fontami oraz
70 wczytywanie i wykonywanie hintingu i rasteryzacji poszczególnych
71 glifów. Może być także uważana za "sterownik TrueType" dla
72 bibliotek wyższego poziomu, jednak użycie samej biblioteki FreeType
73 do rasteryzacji jest bardzo proste, co można zobaczyć w programach
74 demonstracyjnych.
75
76 Ten pakiet zawiera wersję skrośną dla Win32.
77
78 %package static
79 Summary:        Static freetype library (cross MinGW32 version)
80 Summary(pl.UTF-8):      Statyczna biblioteka freetype (wersja skrośna MinGW32)
81 Group:          Development/Libraries
82 Requires:       %{name} = %{version}-%{release}
83
84 %description static
85 Static freetype library (cross MinGW32 version).
86
87 %description static -l pl.UTF-8
88 Statyczna biblioteka freetype (wersja skrośna MinGW32).
89
90 %package dll
91 Summary:        DLL freetype library for Windows
92 Summary(pl.UTF-8):      Biblioteka DLL freetype dla Windows
93 Group:          Applications/Emulators
94 Requires:       crossmingw32-zlib-dll
95 Requires:       wine
96
97 %description dll
98 DLL freetype library for Windows.
99
100 %description dll -l pl.UTF-8
101 Biblioteka DLL freetype dla Windows.
102
103 %prep
104 %setup -q -n %{realname}-%{version}
105
106 %build
107 CFLAGS="%{rpmcflags} \
108 %{?with_lcd:-DFT_CONFIG_OPTION_SUBPIXEL_RENDERING} \
109 -DTT_CONFIG_OPTION_SUBPIXEL_HINTING \
110 " \
111 %configure \
112         --target=%{target} \
113         --build=i686-pc-linux-gnu \
114         --host=%{target} \
115         --enable-shared
116
117 %{__make}
118
119 %install
120 rm -rf $RPM_BUILD_ROOT
121
122 %{__make} install \
123         DESTDIR=$RPM_BUILD_ROOT
124
125 install -d $RPM_BUILD_ROOT%{_dlldir}
126 mv -f $RPM_BUILD_ROOT%{_prefix}/bin/*.dll $RPM_BUILD_ROOT%{_dlldir}
127
128 %if 0%{!?debug:1}
129 %{target}-strip --strip-unneeded -R.comment -R.note $RPM_BUILD_ROOT%{_dlldir}/*.dll
130 %{target}-strip -g -R.comment -R.note $RPM_BUILD_ROOT%{_libdir}/*.a
131 %endif
132
133 rm -rf $RPM_BUILD_ROOT%{_datadir}/aclocal
134
135 %clean
136 rm -rf $RPM_BUILD_ROOT
137
138 %files
139 %defattr(644,root,root,755)
140 %doc docs/{CHANGES,FTL.TXT,LICENSE.TXT,TODO,formats.txt,raster.txt}
141 %{_libdir}/libfreetype.dll.a
142 %{_libdir}/libfreetype.la
143 %{_includedir}/freetype2
144 %{_includedir}/ft2build.h
145 %{_pkgconfigdir}/freetype2.pc
146
147 %files static
148 %defattr(644,root,root,755)
149 %{_libdir}/libfreetype.a
150
151 %files dll
152 %defattr(644,root,root,755)
153 %{_dlldir}/libfreetype-*.dll
This page took 0.065103 seconds and 3 git commands to generate.