]> git.pld-linux.org Git - packages/libwmf.git/blob - libwmf.spec
- fix internal deps
[packages/libwmf.git] / libwmf.spec
1 #
2 # Conditional build:
3 %bcond_without  gtk             # without gtk-loader package (which requires gtk+2-devel)
4 %bcond_without  static_libs     # don't build static version of library
5 #
6 Summary:        libwmf - library to convert wmf files
7 Summary(pl):    libwmf - biblioteka z funkcjami do konwersji plików wmf
8 Name:           libwmf
9 Version:        0.2.8.4
10 Release:        1.2
11 Epoch:          2
12 License:        GPL
13 Group:          Applications/Text
14 Source0:        http://dl.sourceforge.net/wvware/%{name}-%{version}.tar.gz
15 # Source0-md5:  d1177739bf1ceb07f57421f0cee191e0
16 Patch0:         %{name}-fontmap-pld.patch
17 Patch1:         %{name}-includes.patch
18 Patch2:         %{name}-segv.patch
19 URL:            http://wvware.sourceforge.net/
20 BuildRequires:  XFree86-devel
21 BuildRequires:  autoconf
22 BuildRequires:  automake
23 BuildRequires:  expat-devel
24 BuildRequires:  freetype-devel >= 2.0
25 %{?with_gtk:BuildRequires:      gtk+2-devel >= 1:2.1.2}
26 BuildRequires:  libjpeg-devel
27 BuildRequires:  libpng-devel
28 BuildRequires:  libtool >= 1:1.4.2-9
29 PreReq:         ghostscript-fonts-std
30 Requires(post): /sbin/ldconfig
31 Requires(post): sed
32 Requires:       sed
33 Requires:       %{name}-libs = %{epoch}:%{version}-%{release}
34 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
35
36 %define         specflags_ia32  -fomit-frame-pointer
37
38 %description
39 libwmf is a library for unix like machines that can convert wmf files
40 into other formats, currently it supports fig, eps, a gd binding to
41 convert to png, and an X one to draw direct to an X window or pixmap.
42
43 %description -l pl
44 libwmf jest bibliotek± dla systemów uniksowych, która konwertuje pliki
45 wmf na inne formaty. Aktualnie obs³uguje formaty fig i eps, format png
46 poprzez bibliotekê gd oraz - poprzez biblioteki X Window - rysowanie w
47 okienku oraz format xpm.
48
49 %package devel
50 Summary:        libwmf - header files
51 Summary(pl):    libwmf - pliki nag³ówkowe
52 Group:          Development/Libraries
53 Requires:       %{name}-libs = %{epoch}:%{version}-%{release}
54 # libwmflite(.la) has no additional deps
55 # libwmf(.la) needs freetype-devel, XFree86-devel, expat-devel, libjpeg-devel, libpng-devel
56
57 %description devel
58 This package contains libwmf header files.
59
60 %description devel -l pl
61 Pakiet zawiera pliki nag³ówkowe do biblioteki libwmf.
62
63 %package libs
64 Summary:        libwmf - libraries
65 Group:          Libraries
66
67 %description libs
68 This package contains libwmf libraries.
69
70 %package static
71 Summary:        libwmf - static libraries
72 Summary(pl):    libwmf - biblioteki statyczne
73 Group:          Development/Libraries
74 Requires:       %{name}-devel = %{epoch}:%{version}-%{release}
75
76 %description static
77 This package contains libwmf static libraries.
78
79 %description static -l pl
80 Pakiet zawiera statyczn± wersjê biblioteki libwmf.
81
82 %package gtk-loader
83 Summary:        WMF loader for gdk_pixbuf 2.x library
84 Summary(pl):    Modu³ wczytuj±cy WMF dla biblioteki gdk_pixbuf 2.x
85 Group:          X11/Libraries
86 Requires:       %{name} = %{epoch}:%{version}-%{release}
87
88 %description gtk-loader
89 WMF loader for gdk_pixbuf 2.x library.
90
91 %description gtk-loader -l pl
92 Modu³ wczytuj±cy WMF dla biblioteki gdk_pixbuf 2.x
93
94 %prep
95 %setup -q
96 %patch0 -p1
97 %patch1 -p1
98 %patch2 -p1
99
100 %build
101 %{__libtoolize}
102 %{__aclocal}
103 %{__autoheader}
104 %{__autoconf}
105 %{__automake}
106 %configure \
107         %{!?with_static_libs:--disable-static} \
108         --with-sysfontmap=%{_fontsdir}/ghostscript-fonts-std.font \
109         --with-gsfontmap=%{_fontsdir}/Type1/Fontmap \
110         --with-gsfontdir=%{_fontsdir}/Type1
111
112 %{__make}
113
114 %install
115 rm -rf $RPM_BUILD_ROOT
116
117 %{__make} install \
118         DESTDIR=$RPM_BUILD_ROOT
119
120 rm -rf html-doc
121 mv -f $RPM_BUILD_ROOT%{_datadir}/doc ./html-doc
122
123 # no static modules and *.la for GTK+ loaders - shut up check-files
124 rm -f $RPM_BUILD_ROOT%{_libdir}/gtk-2*/*/loaders/*.{a,la}
125
126 %clean
127 rm -rf $RPM_BUILD_ROOT
128
129 %post
130 %{_bindir}/libwmf-fontmap > /dev/null
131
132 %post   libs -p /sbin/ldconfig
133 %postun libs -p /sbin/ldconfig
134
135 %files
136 %defattr(644,root,root,755)
137 %doc CREDITS ChangeLog README TODO
138 %attr(755,root,root) %{_bindir}/libwmf-fontmap
139 %attr(755,root,root) %{_bindir}/wmf2eps
140 %attr(755,root,root) %{_bindir}/wmf2fig
141 %attr(755,root,root) %{_bindir}/wmf2gd
142 %attr(755,root,root) %{_bindir}/wmf2svg
143 %attr(755,root,root) %{_bindir}/wmf2x
144 %dir %{_datadir}/libwmf
145 %dir %{_datadir}/libwmf/fonts
146 %ghost %{_datadir}/libwmf/fonts/fontmap
147
148 %files devel
149 %defattr(644,root,root,755)
150 %doc html-doc examples
151 %attr(755,root,root) %{_bindir}/libwmf-config
152 %attr(755,root,root) %{_libdir}/*.so
153 %{_libdir}/*.la
154 %{_includedir}/*
155
156 %files libs
157 %defattr(644,root,root,755)
158 %attr(755,root,root) %{_libdir}/*.so.*.*
159
160 %if %{with static_libs}
161 %files static
162 %defattr(644,root,root,755)
163 %{_libdir}/*.a
164 %endif
165
166 %if %{with gtk}
167 %files gtk-loader
168 %defattr(644,root,root,755)
169 %attr(755,root,root) %{_libdir}/gtk-2*/*/loaders/*.so
170 %endif
This page took 0.041012 seconds and 4 git commands to generate.