]> git.saurik.com Git - wxWidgets.git/blame_incremental - wxX11.spec
Apply combobox patch II.
[wxWidgets.git] / wxX11.spec
... / ...
CommitLineData
1%define pref /usr
2%define ver 2.5.4
3%define ver2 2.5
4%define rel 1
5
6# Configurable settings (use --with(out) unicode on rpmbuild cmd line):
7%define unicode 0
8%{?_with_unicode: %{expand: %%define unicode 1}}
9%{?_without_unicode: %{expand: %%define unicode 0}}
10
11%define portname x11
12%if %{unicode}
13%define name wx-%{portname}-unicode
14%define wxbasename wx-base-unicode
15%else
16%define name wx-%{portname}
17%define wxbasename wx-base
18%endif
19
20%if %{unicode}
21%define wxconfigname wx%{portname}univu-%{ver2}-config
22%else
23%define wxconfigname wx%{portname}univ-%{ver2}-config
24%endif
25
26Summary: The X11 port of the wxWindows library
27Name: %{name}
28Version: %{ver}
29Release: %{rel}
30License: wxWindows Licence
31Group: X11/Libraries
32Source: wxX11-%{ver}.tar.bz2
33URL: http://www.wxwindows.org
34Packager: Vadim Zeitlin <vadim@wxwindows.org>
35Prefix: %{pref}
36BuildRoot: /var/tmp/%{name}-root
37
38# all packages providing an implementation of wxWindows library (regardless of
39# the toolkit used) should provide the (virtual) wxwin package, this makes it
40# possible to require wxwin instead of requiring "wxgtk or wxmotif or wxuniv..."
41Provides: wxwin
42
43# in addition, we should provide libwx_gtk as automatic generator only notices
44# libwx_gtk-%{ver}-%{rel}
45Provides: libwx_x11.so
46Provides: libwx_x11-%{ver2}.so
47Provides: wxX11
48
49Requires: %{wxbasename} = %{ver}
50
51%description
52wxWindows is a free C++ library for cross-platform GUI development.
53With wxWindows, you can create applications for different GUIs (GTK+,
54Motif/LessTif, MS Windows, Mac) from the same source code.
55
56%package devel
57Summary: The X11 port of the wxWindows library
58Group: X11/Libraries
59Requires: %{name} = %{ver}
60Requires: %{wxbasename}-devel = %{ver}
61
62%description devel
63Header files for wxX11, the X11 port of the wxWindows library.
64
65%package gl
66Summary: The X11 port of the wxWindows library, OpenGL add-on.
67Group: X11/Libraries
68Requires: %{name} = %{ver}
69
70%description gl
71OpenGL add-on library for wxX11, the X11 port of the wxWindows library.
72
73%package static
74Summary: wxX11 static libraries
75Group: Development/Libraries
76
77%description static
78Static libraries for wxX11. You need them if you want to link statically against wxX11.
79
80%package contrib
81Summary: Contrib libraries for wxX11.
82Group: X11/Libraries
83Requires: %{name} = %{ver}
84
85%description contrib
86Contributed libraries for wxX11.
87
88%package contrib-devel
89Summary: Contrib libraries for wxX11.
90Group: X11/Libraries
91Requires: %{name}-contrib = %{ver}
92Requires: %{name}-devel = %{ver}
93
94%description contrib-devel
95Header files for contributed libraries for wxX11.
96
97%prep
98%setup -q -n wxX11-%{ver}
99
100%build
101if [ "$SMP" != "" ]; then
102 export MAKE="make -j$SMP"
103else
104 export MAKE="make"
105fi
106
107mkdir obj-shared
108cd obj-shared
109../configure --prefix=%{pref} --with-x11 \
110%if %{unicode}
111 --enable-unicode \
112%else
113 --with-odbc \
114%endif
115 --with-opengl
116$MAKE
117cd contrib/src
118$MAKE
119cd ../../..
120
121mkdir obj-static
122cd obj-static
123../configure --prefix=%{pref} --with-x11 --disable-shared \
124%if %{unicode}
125 --enable-unicode \
126%else
127 --with-odbc \
128%endif
129 --with-opengl
130$MAKE
131cd ..
132
133%install
134rm -rf $RPM_BUILD_ROOT
135(cd obj-static; make prefix=$RPM_BUILD_ROOT%{pref} install)
136(cd obj-shared; make prefix=$RPM_BUILD_ROOT%{pref} install)
137
138# Remove headers that are part of wx-base-devel:
139
140# --- wxBase headers list begins here ---
141cat <<EOF >wxbase-headers-list
142wx/afterstd.h
143wx/app.h
144wx/apptrait.h
145wx/archive.h
146wx/arrimpl.cpp
147wx/arrstr.h
148wx/beforestd.h
149wx/buffer.h
150wx/build.h
151wx/chkconf.h
152wx/clntdata.h
153wx/cmdline.h
154wx/confbase.h
155wx/config.h
156wx/containr.h
157wx/datetime.h
158wx/datetime.inl
159wx/datstrm.h
160wx/dde.h
161wx/debug.h
162wx/defs.h
163wx/dir.h
164wx/dlimpexp.h
165wx/dynarray.h
166wx/dynlib.h
167wx/dynload.h
168wx/encconv.h
169wx/event.h
170wx/except.h
171wx/features.h
172wx/ffile.h
173wx/file.h
174wx/fileconf.h
175wx/filefn.h
176wx/filename.h
177wx/filesys.h
178wx/fontenc.h
179wx/fontmap.h
180wx/fs_mem.h
181wx/fs_zip.h
182wx/hash.h
183wx/hashmap.h
184wx/hashset.h
185wx/iconloc.h
186wx/init.h
187wx/intl.h
188wx/iosfwrap.h
189wx/ioswrap.h
190wx/ipc.h
191wx/ipcbase.h
192wx/isql.h
193wx/isqlext.h
194wx/list.h
195wx/listimpl.cpp
196wx/log.h
197wx/longlong.h
198wx/math.h
199wx/memconf.h
200wx/memory.h
201wx/memtext.h
202wx/mimetype.h
203wx/module.h
204wx/msgout.h
205wx/msgout.h
206wx/mstream.h
207wx/object.h
208wx/platform.h
209wx/process.h
210wx/ptr_scpd.h
211wx/regex.h
212wx/scopeguard.h
213wx/snglinst.h
214wx/sstream.h
215wx/stack.h
216wx/stackwalk.h
217wx/stdpaths.h
218wx/stockitem.h
219wx/stopwatch.h
220wx/strconv.h
221wx/stream.h
222wx/string.h
223wx/sysopt.h
224wx/textbuf.h
225wx/textfile.h
226wx/thread.h
227wx/thrimpl.cpp
228wx/timer.h
229wx/tokenzr.h
230wx/txtstrm.h
231wx/types.h
232wx/uri.h
233wx/utils.h
234wx/variant.h
235wx/vector.h
236wx/version.h
237wx/volume.h
238wx/wfstream.h
239wx/wx.h
240wx/wxchar.h
241wx/wxprec.h
242wx/xti.h
243wx/xtistrm.h
244wx/zipstrm.h
245wx/zstream.h
246wx/msw/apptrait.h
247wx/msw/apptbase.h
248wx/msw/chkconf.h
249wx/msw/crashrpt.h
250wx/msw/dde.h
251wx/msw/debughlp.h
252wx/msw/gccpriv.h
253wx/msw/mimetype.h
254wx/msw/stackwalk.h
255wx/msw/winundef.h
256wx/msw/wrapcctl.h
257wx/msw/wrapwin.h
258wx/fs_inet.h
259wx/gsocket.h
260wx/protocol/file.h
261wx/protocol/ftp.h
262wx/protocol/http.h
263wx/protocol/protocol.h
264wx/sckaddr.h
265wx/sckipc.h
266wx/sckstrm.h
267wx/socket.h
268wx/url.h
269wx/msw/gsockmsw.h
270wx/xml/xml.h
271wx/xtixml.h
272wx/db.h
273wx/dbkeyg.h
274wx/dbtable.h
275EOF
276# --- wxBase headers list ends here ---
277for f in `cat wxbase-headers-list` ; do
278 rm -f $RPM_BUILD_ROOT%{_includedir}/wx-*/$f
279done
280
281# list of all core headers:
282find $RPM_BUILD_ROOT/usr/include/wx -type f | sed -e "s,$RPM_BUILD_ROOT,,g" >core-headers.files
283
284# contrib stuff:
285(cd obj-shared/contrib/src; make prefix=$RPM_BUILD_ROOT%{pref} install)
286(cd obj-shared/utils/wxrc; make prefix=$RPM_BUILD_ROOT%{pref} install)
287
288# remove wxBase files so that RPM doesn't complain about unpackaged files:
289rm -f $RPM_BUILD_ROOT%{_libdir}/libwx_base*
290rm -f $RPM_BUILD_ROOT%{_datadir}/aclocal/*
291rm -f $RPM_BUILD_ROOT%{_datadir}/locale/*/*/*
292
293%clean
294rm -rf $RPM_BUILD_ROOT
295
296%post
297/sbin/ldconfig
298
299%postun
300/sbin/ldconfig
301
302%post gl
303/sbin/ldconfig
304
305%postun gl
306/sbin/ldconfig
307
308
309%files
310%defattr(-,root,root)
311%doc COPYING.LIB *.txt
312%{_libdir}/libwx_%{portname}*_core*.so.*
313%{_libdir}/libwx_%{portname}*_html*.so.*
314%{_libdir}/libwx_%{portname}*_adv*.so.*
315%if !%{unicode}
316%{_libdir}/libwx_%{portname}*_dbgrid*.so.*
317%endif
318
319%files devel -f core-headers.files
320%defattr(-,root,root)
321%{_libdir}/libwx_%{portname}*_core*.so
322%{_libdir}/libwx_%{portname}*_html*.so
323%{_libdir}/libwx_%{portname}*_adv*.so
324%if !%{unicode}
325%{_libdir}/libwx_%{portname}*_dbgrid*.so
326%endif
327%{_libdir}/libwx_%{portname}*_gl*.so
328%dir %{_libdir}/wx
329%{_libdir}/wx/*
330%{_bindir}/%{wxconfigname}
331
332%files gl
333%defattr(-,root,root)
334%{_libdir}/libwx_%{portname}*_gl*.so.*
335
336%files static
337%defattr (-,root,root)
338%{_libdir}/libwx_%{portname}*.a
339
340%files contrib
341%defattr(-,root,root)
342%{_libdir}/libwx_%{portname}*_animate*.so.*
343%{_libdir}/libwx_%{portname}*_deprecated*.so.*
344%{_libdir}/libwx_%{portname}*_fl*.so.*
345%{_libdir}/libwx_%{portname}*_gizmos*.so.*
346%{_libdir}/libwx_%{portname}*_mmedia*.so.*
347%{_libdir}/libwx_%{portname}*_ogl*.so.*
348%{_libdir}/libwx_%{portname}*_plot*.so.*
349%{_libdir}/libwx_%{portname}*_stc*.so.*
350%{_libdir}/libwx_%{portname}*_svg*.so.*
351%{_libdir}/libwx_%{portname}*_xrc*.so.*
352
353%files contrib-devel
354%defattr(-,root,root)
355%{_bindir}/wxrc
356%dir %{_includedir}/wx-*/wx/animate
357%{_includedir}/wx-*/wx/animate/*
358%{_libdir}/libwx_%{portname}*_animate*.so
359
360%dir %{_includedir}/wx-*/wx/deprecated
361%{_includedir}/wx-*/wx/deprecated/*
362%{_libdir}/libwx_%{portname}*_deprecated*.so
363
364%dir %{_includedir}/wx-*/wx/fl
365%{_includedir}/wx-*/wx/fl/*
366%{_libdir}/libwx_%{portname}*_fl*.so
367
368%dir %{_includedir}/wx-*/wx/gizmos
369%{_includedir}/wx-*/wx/gizmos/*
370%{_libdir}/libwx_%{portname}*_gizmos*.so
371
372%dir %{_includedir}/wx-*/wx/mmedia
373%{_includedir}/wx-*/wx/mmedia/*
374%{_libdir}/libwx_%{portname}*_mmedia*.so
375
376%dir %{_includedir}/wx-*/wx/ogl
377%{_includedir}/wx-*/wx/ogl/*
378%{_libdir}/libwx_%{portname}*_ogl*.so
379
380%dir %{_includedir}/wx-*/wx/plot
381%{_includedir}/wx-*/wx/plot/*
382%{_libdir}/libwx_%{portname}*_plot*.so
383
384%dir %{_includedir}/wx-*/wx/stc
385%{_includedir}/wx-*/wx/stc/*
386%{_libdir}/libwx_%{portname}*_stc*.so
387
388%dir %{_includedir}/wx-*/wx/svg
389%{_includedir}/wx-*/wx/svg/*
390%{_libdir}/libwx_%{portname}*_svg*.so
391
392%dir %{_includedir}/wx-*/wx/xrc
393%{_includedir}/wx-*/wx/xrc/*
394%{_libdir}/libwx_%{portname}*_xrc*.so