]> git.pld-linux.org Git - packages/crossmingw32-cairo.git/blob - crossmingw32-cairo.spec
- proper shared + static build
[packages/crossmingw32-cairo.git] / crossmingw32-cairo.spec
1 #
2 # Conditional build:
3 %bcond_with     glitz           # build with glitz backend
4 #
5 Summary:        Cairo - multi-platform 2D graphics library - cross Mingw32 version
6 Summary(pl):    Cairo - wieloplatformowa biblioteka graficzna 2D - skro¶na wersja Mingw32
7 %define         _realname   cairo
8 Name:           crossmingw32-%{_realname}
9 Version:        1.2.6
10 Release:        1
11 License:        LGPL v2.1 or MPL v1.1
12 Group:          Libraries
13 Source0:        http://cairographics.org/releases/%{_realname}-%{version}.tar.gz
14 # Source0-md5:  487b3d7515752fe57f780d0fd707b01a
15 Patch0:         %{name}-dll.patch
16 Patch1:         %{name}-dllmain.patch
17 URL:            http://cairographics.org/
18 BuildRequires:  autoconf >= 2.54
19 BuildRequires:  automake >= 1:1.7
20 BuildRequires:  crossmingw32-fontconfig
21 BuildRequires:  crossmingw32-freetype >= 2.1.10
22 %{?with_glitz:BuildRequires:    crossmingw32-glitz >= 0.5.1}
23 BuildRequires:  crossmingw32-libpng
24 BuildRequires:  crossmingw32-pkgconfig
25 BuildRequires:  crossmingw32-zlib
26 BuildRequires:  libtool
27 Requires:       crossmingw32-freetype >= 2.1.10
28 %{?with_glitz:Requires: glitz >= 0.5.1}
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}
36 %define         gccarch                 %{_prefix}/lib/gcc-lib/%{target}
37 %define         gcclib                  %{_prefix}/lib/gcc-lib/%{target}/%{version}
38
39 %define         _sysprefix              /usr
40 %define         _prefix                 %{_sysprefix}/%{target}
41 %define         _pkgconfigdir           %{_prefix}/lib/pkgconfig
42 %define         __cc                    %{target}-gcc
43 %define         __cxx                   %{target}-g++
44
45 %description
46 Cairo provides anti-aliased vector-based rendering for X. Paths
47 consist of line segments and cubic splines and can be rendered at any
48 width with various join and cap styles. All colors may be specified
49 with optional translucence (opacity/alpha) and combined using the
50 extended Porter/Duff compositing algebra as found in the X Render
51 Extension.
52
53 Cairo exports a stateful rendering API similar in spirit to the path
54 construction, text, and painting operators of PostScript, (with the
55 significant addition of translucence in the imaging model). When
56 complete, the API is intended to support the complete imaging model of
57 PDF 1.4.
58
59 Cairo relies on the Xc library for backend rendering. Xc provides an
60 abstract interface for rendering to multiple target types. As of this
61 writing, Xc allows Cairo to target X drawables as well as generic
62 image buffers. Future backends such as PostScript, PDF, and perhaps
63 OpenGL are currently being planned.
64
65 %description -l pl
66 Cairo obs³uguje oparty na wektorach rendering z antyaliasingiem dla X.
67 ¦cie¿ki sk³adaj± siê z odcinków i splajnów kubicznych, a renderowane
68 mog± byæ z dowoln± grubo¶ci± i ró¿nymi stylami po³±czeñ i zakoñczeñ.
69 Wszystkie kolory mog± byæ podane z opcjonaln± pó³przezroczysto¶ci±
70 (podan± przez wspó³czynnik nieprzezroczysto¶ci lub alpha) i ³±czone
71 przy u¿yciu rozszerzonego algorytmu mieszania Portera-Duffa, który
72 mo¿na znale¼æ w rozszerzeniu X Render.
73
74 Cairo eksportuje stanowe API renderuj±ce w duchu podobne do operatorów
75 konstruowania ¶cie¿ek, tekstu i rysowania z PostScriptu (ze znacznym
76 dodatkiem pó³przezroczysto¶ci w modelu obrazu). Kiedy API zostanie
77 ukoñczone, ma obs³ugiwaæ pe³ny model obrazu z PDF w wersji 1.4.
78
79 Cairo do backendowego renderowania wykorzystuje bibliotekê Xc. Xc
80 dostarcza abstrakcyjny interfejs do renderowania na wiele rodzajów
81 wyj¶æ. Aktualnie Xc pozwala Cairo tworzyæ obiekty X, a tak¿e ogólne
82 bufory obrazu. W przysz³o¶ci planowane s± takie backendy jak
83 PostScript, PDF i byæ mo¿e OpenGL.
84
85 %prep
86 %setup -q -n %{_realname}-%{version}
87 #%patch0 -p1
88 #%patch1 -p1
89
90 %build
91 export PKG_CONFIG_PATH=%{_prefix}/lib/pkgconfig
92 %{__libtoolize}
93 %{__aclocal}
94 %{__autoheader}
95 %{__autoconf}
96 %{__automake}
97 %configure \
98         --target=%{target} \
99         --host=%{target} \
100         %{?with_glitz:--enable-glitz} \
101         --disable-gtk-doc \
102         --disable-xlib \
103         --disable-xlib-render \
104         --enable-freetype \
105         --enable-pdf \
106         --enable-png \
107         --enable-ps \
108         --disable-svg \
109         --enable-windows \
110
111 %{__sed} -i -e 's/^deplibs_check_method=.*/deplibs_check_method="pass_all"/' libtool
112
113 %{__make}
114
115 %install
116 rm -rf $RPM_BUILD_ROOT
117
118 %{__make} install \
119         DESTDIR=$RPM_BUILD_ROOT
120
121 %clean
122 rm -rf $RPM_BUILD_ROOT
123
124 %files
125 %defattr(644,root,root,755)
126 # COPYING contains only notes, not LGPL/MPL texts
127 %doc AUTHORS COPYING ChangeLog NEWS README TODO
128 %{_libdir}/lib*.la
129 %{_libdir}/lib*.a
130 %{_bindir}/*.dll
131 %{_includedir}/*
132 %{_pkgconfigdir}/*.pc
This page took 0.099443 seconds and 3 git commands to generate.