]> git.saurik.com Git - wxWidgets.git/blame_incremental - wxX11.spec
check the radio buttons when they get focus (closes 777500)
[wxWidgets.git] / wxX11.spec
... / ...
CommitLineData
1%define pref /usr
2%define ver 2.5.1
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/arrimpl.cpp
146wx/arrstr.h
147wx/beforestd.h
148wx/buffer.h
149wx/build.h
150wx/chkconf.h
151wx/clntdata.h
152wx/cmdline.h
153wx/confbase.h
154wx/config.h
155wx/containr.h
156wx/datetime.h
157wx/datetime.inl
158wx/datstrm.h
159wx/dde.h
160wx/debug.h
161wx/defs.h
162wx/dir.h
163wx/dynarray.h
164wx/dynlib.h
165wx/dynload.h
166wx/encconv.h
167wx/event.h
168wx/except.h
169wx/features.h
170wx/ffile.h
171wx/file.h
172wx/fileconf.h
173wx/filefn.h
174wx/filename.h
175wx/filesys.h
176wx/fontenc.h
177wx/fontmap.h
178wx/fs_mem.h
179wx/fs_zip.h
180wx/hash.h
181wx/hashmap.h
182wx/hashset.h
183wx/iconloc.h
184wx/init.h
185wx/intl.h
186wx/iosfwrap.h
187wx/ioswrap.h
188wx/ipc.h
189wx/ipcbase.h
190wx/isql.h
191wx/isqlext.h
192wx/list.h
193wx/listimpl.cpp
194wx/log.h
195wx/longlong.h
196wx/math.h
197wx/memconf.h
198wx/memory.h
199wx/memtext.h
200wx/mimetype.h
201wx/module.h
202wx/msgout.h
203wx/msgout.h
204wx/mstream.h
205wx/object.h
206wx/platform.h
207wx/process.h
208wx/ptr_scpd.h
209wx/regex.h
210wx/scopeguard.h
211wx/snglinst.h
212wx/stopwatch.h
213wx/strconv.h
214wx/stream.h
215wx/string.h
216wx/sysopt.h
217wx/textbuf.h
218wx/textfile.h
219wx/thread.h
220wx/thrimpl.cpp
221wx/timer.h
222wx/tokenzr.h
223wx/txtstrm.h
224wx/types.h
225wx/utils.h
226wx/variant.h
227wx/vector.h
228wx/version.h
229wx/volume.h
230wx/wfstream.h
231wx/wx.h
232wx/wxchar.h
233wx/wxprec.h
234wx/xti.h
235wx/xtistrm.h
236wx/zipstrm.h
237wx/zstream.h
238wx/msw/apptrait.h
239wx/msw/apptbase.h
240wx/msw/chkconf.h
241wx/msw/crashrpt.h
242wx/msw/dde.h
243wx/msw/gccpriv.h
244wx/msw/mimetype.h
245wx/msw/winundef.h
246wx/msw/wrapcctl.h
247wx/msw/wrapwin.h
248wx/fs_inet.h
249wx/gsocket.h
250wx/protocol/file.h
251wx/protocol/ftp.h
252wx/protocol/http.h
253wx/protocol/protocol.h
254wx/sckaddr.h
255wx/sckipc.h
256wx/sckstrm.h
257wx/socket.h
258wx/url.h
259wx/msw/gsockmsw.h
260wx/xml/xml.h
261wx/xtixml.h
262wx/db.h
263wx/dbkeyg.h
264wx/dbtable.h
265EOF
266# --- wxBase headers list ends here ---
267for f in `cat wxbase-headers-list` ; do
268 rm -f $RPM_BUILD_ROOT%{_includedir}/$f
269done
270
271# list of all core headers:
272find $RPM_BUILD_ROOT/usr/include/wx -type f | sed -e "s,$RPM_BUILD_ROOT,,g" >core-headers.files
273
274# contrib stuff:
275(cd obj-shared/contrib/src; make prefix=$RPM_BUILD_ROOT%{pref} install)
276(cd obj-shared/contrib/utils/wxrc; make prefix=$RPM_BUILD_ROOT%{pref} install)
277
278%clean
279rm -rf $RPM_BUILD_ROOT
280
281%post
282/sbin/ldconfig
283
284%postun
285/sbin/ldconfig
286
287%post gl
288/sbin/ldconfig
289
290%postun gl
291/sbin/ldconfig
292
293%post devel
294# Install wx-config if there isn't any
295if test ! -f %{_bindir}/wx-config ; then
296 ln -sf %{wxconfigname} %{_bindir}/wx-config
297fi
298
299%preun devel
300# Remove wx-config if it points to this package
301if test -f %{_bindir}/wx-config -a -f /usr/bin/md5sum ; then
302 SUM1=`md5sum %{_bindir}/%{wxconfigname} | cut -c 0-32`
303 SUM2=`md5sum %{_bindir}/wx-config | cut -c 0-32`
304 if test "x$SUM1" = "x$SUM2" ; then
305 rm -f %{_bindir}/wx-config
306 fi
307fi
308
309
310%files
311%defattr(-,root,root)
312%doc COPYING.LIB *.txt
313%dir %{_datadir}/wx
314%{_datadir}/wx/*
315%{_libdir}/libwx_%{portname}*_core*.so.*
316%{_libdir}/libwx_%{portname}*_html*.so.*
317%{_libdir}/libwx_%{portname}*_adv*.so.*
318%if !%{unicode}
319%{_libdir}/libwx_%{portname}*_dbgrid*.so.*
320%endif
321
322%files devel -f core-headers.files
323%defattr(-,root,root)
324%{_libdir}/libwx_%{portname}*_core*.so
325%{_libdir}/libwx_%{portname}*_html*.so
326%{_libdir}/libwx_%{portname}*_adv*.so
327%if !%{unicode}
328%{_libdir}/libwx_%{portname}*_dbgrid*.so
329%endif
330%{_libdir}/libwx_%{portname}*_gl*.so
331%dir %{_libdir}/wx
332%{_libdir}/wx/*
333%{_bindir}/%{wxconfigname}
334
335%files gl
336%defattr(-,root,root)
337%{_libdir}/libwx_%{portname}*_gl*.so.*
338
339%files static
340%defattr (-,root,root)
341%{_libdir}/libwx_%{portname}*.a
342
343%files contrib
344%defattr(-,root,root)
345%{_libdir}/libwx_%{portname}*_animate*.so.*
346%{_libdir}/libwx_%{portname}*_deprecated*.so.*
347%{_libdir}/libwx_%{portname}*_fl*.so.*
348%{_libdir}/libwx_%{portname}*_gizmos*.so.*
349%{_libdir}/libwx_%{portname}*_mmedia*.so.*
350%{_libdir}/libwx_%{portname}*_ogl*.so.*
351%{_libdir}/libwx_%{portname}*_plot*.so.*
352%{_libdir}/libwx_%{portname}*_stc*.so.*
353%{_libdir}/libwx_%{portname}*_svg*.so.*
354%{_libdir}/libwx_%{portname}*_xrc*.so.*
355
356%files contrib-devel
357%defattr(-,root,root)
358%{_bindir}/wxrc
359%dir %{_includedir}/wx/animate
360%{_includedir}/wx/animate/*
361%{_libdir}/libwx_%{portname}*_animate*.so
362
363%dir %{_includedir}/wx/deprecated
364%{_includedir}/wx/deprecated/*
365%{_libdir}/libwx_%{portname}*_deprecated*.so
366
367%dir %{_includedir}/wx/fl
368%{_includedir}/wx/fl/*
369%{_libdir}/libwx_%{portname}*_fl*.so
370
371%dir %{_includedir}/wx/gizmos
372%{_includedir}/wx/gizmos/*
373%{_libdir}/libwx_%{portname}*_gizmos*.so
374
375%dir %{_includedir}/wx/mmedia
376%{_includedir}/wx/mmedia/*
377%{_libdir}/libwx_%{portname}*_mmedia*.so
378
379%dir %{_includedir}/wx/ogl
380%{_includedir}/wx/ogl/*
381%{_libdir}/libwx_%{portname}*_ogl*.so
382
383%dir %{_includedir}/wx/plot
384%{_includedir}/wx/plot/*
385%{_libdir}/libwx_%{portname}*_plot*.so
386
387%dir %{_includedir}/wx/stc
388%{_includedir}/wx/stc/*
389%{_libdir}/libwx_%{portname}*_stc*.so
390
391%dir %{_includedir}/wx/svg
392%{_includedir}/wx/svg/*
393%{_libdir}/libwx_%{portname}*_svg*.so
394
395%dir %{_includedir}/wx/xrc
396%{_includedir}/wx/xrc/*
397%{_libdir}/libwx_%{portname}*_xrc*.so