]>
Commit | Line | Data |
---|---|---|
b0f59df1 JB |
1 | Summary: Pixel manipulation library - cross Mingw32 |
2 | Summary(pl.UTF-8): Biblioteka operacji na pikselach - wersja skrośna Mingw32 | |
3 | Name: crossmingw32-pixman | |
7921815b | 4 | Version: 0.16.6 |
b0f59df1 JB |
5 | Release: 1 |
6 | License: MIT | |
7 | Group: Development/Libraries | |
8 | Source0: http://xorg.freedesktop.org/archive/individual/lib/pixman-%{version}.tar.bz2 | |
7921815b JB |
9 | # Source0-md5: fbd6ee9cb09d0b26281557bc7afcb3ab |
10 | Patch0: pixman-no_pkgconfig.patch | |
b0f59df1 JB |
11 | URL: http://xorg.freedesktop.org/ |
12 | BuildRequires: autoconf >= 2.57 | |
13 | BuildRequires: automake | |
14 | BuildRequires: crossmingw32-gcc | |
b0f59df1 JB |
15 | BuildRequires: libtool |
16 | BuildRequires: sed >= 4.0 | |
17 | Requires: crossmingw32-runtime | |
18 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
19 | ||
20 | %define no_install_post_strip 1 | |
21 | ||
22 | %define target i386-mingw32 | |
23 | %define target_platform i386-pc-mingw32 | |
24 | ||
25 | %define _sysprefix /usr | |
26 | %define _prefix %{_sysprefix}/%{target} | |
27 | %define _libdir %{_prefix}/lib | |
28 | %define _pkgconfigdir %{_prefix}/lib/pkgconfig | |
29 | %define _dlldir /usr/share/wine/windows/system | |
30 | %define __cc %{target}-gcc | |
31 | %define __cxx %{target}-g++ | |
32 | ||
6f3319a2 JB |
33 | %ifnarch %{ix86} |
34 | # arch-specific flags (like alpha's -mieee) are not valid for i386 gcc | |
35 | %define optflags -O2 | |
36 | %endif | |
37 | # -z options are invalid for mingw linker | |
38 | %define filterout_ld -Wl,-z,.* | |
39 | ||
b0f59df1 JB |
40 | %description |
41 | pixman is a pixel manipulation library. | |
42 | ||
43 | This package contains the cross version for Win32. | |
44 | ||
45 | %description -l pl.UTF-8 | |
46 | pixman to biblioteka do operacji na pikselach. | |
47 | ||
48 | Ten pakiet zawiera wersję skrośną dla Win32. | |
49 | ||
50 | %package static | |
51 | Summary: Static pixman library (cross mingw32 version) | |
52 | Summary(pl.UTF-8): Statyczna biblioteka pixman (wersja skrośna mingw32) | |
53 | Group: Development/Libraries | |
54 | Requires: %{name} = %{version}-%{release} | |
55 | ||
56 | %description static | |
57 | Static pixman library (cross mingw32 version). | |
58 | ||
59 | %description static -l pl.UTF-8 | |
60 | Statyczna biblioteka pixman (wersja skrośna mingw32). | |
61 | ||
62 | %package dll | |
63 | Summary: DLL pixman library for Windows | |
64 | Summary(pl.UTF-8): Biblioteka DLL pixman dla Windows | |
65 | Group: Applications/Emulators | |
66 | Requires: wine | |
67 | ||
68 | %description dll | |
69 | DLL pixman library for Windows. | |
70 | ||
71 | %description dll -l pl.UTF-8 | |
72 | Biblioteka DLL pixman dla Windows. | |
73 | ||
74 | %prep | |
75 | %setup -q -n pixman-%{version} | |
7921815b | 76 | %patch0 -p1 |
b0f59df1 JB |
77 | |
78 | # disable gtk-based test | |
79 | :> test/Makefile.am | |
80 | # needed to build dll | |
81 | sed -i -e 's/^libpixman_1_la_LDFLAGS =/& -no-undefined/' pixman/Makefile.am | |
82 | ||
83 | %build | |
84 | %{__libtoolize} | |
85 | %{__aclocal} | |
86 | %{__autoconf} | |
87 | %{__autoheader} | |
88 | %{__automake} | |
89 | %configure \ | |
90 | --target=%{target} \ | |
91 | --host=%{target} | |
92 | ||
93 | %{__make} | |
94 | ||
95 | %install | |
96 | rm -rf $RPM_BUILD_ROOT | |
97 | ||
98 | %{__make} install \ | |
99 | DESTDIR=$RPM_BUILD_ROOT | |
100 | ||
7921815b JB |
101 | sed -i -e 's#<pixman-version.h>#<pixman-1/pixman-version.h>#g' $RPM_BUILD_ROOT%{_includedir}/pixman-1/pixman.h |
102 | ||
b0f59df1 JB |
103 | install -d $RPM_BUILD_ROOT%{_dlldir} |
104 | mv -f $RPM_BUILD_ROOT%{_prefix}/bin/*.dll $RPM_BUILD_ROOT%{_dlldir} | |
105 | ||
106 | %if 0%{!?debug:1} | |
107 | %{target}-strip --strip-unneeded -R.comment -R.note $RPM_BUILD_ROOT%{_dlldir}/*.dll | |
108 | %{target}-strip -g -R.comment -R.note $RPM_BUILD_ROOT%{_libdir}/*.a | |
109 | %endif | |
110 | ||
111 | %clean | |
112 | rm -rf $RPM_BUILD_ROOT | |
113 | ||
114 | %files | |
115 | %defattr(644,root,root,755) | |
116 | %doc README TODO | |
117 | %{_libdir}/libpixman-1.dll.a | |
118 | %{_libdir}/libpixman-1.la | |
119 | %{_includedir}/pixman-1 | |
120 | %{_pkgconfigdir}/pixman-1.pc | |
121 | ||
122 | %files static | |
123 | %defattr(644,root,root,755) | |
124 | %{_libdir}/libpixman-1.a | |
125 | ||
126 | %files dll | |
127 | %defattr(644,root,root,755) | |
128 | %{_dlldir}/libpixman-1-*.dll |