]> git.saurik.com Git - wxWidgets.git/blame_incremental - wxMotif.spec
open more keys in read only mode if we need to only read from them (fixes problems...
[wxWidgets.git] / wxMotif.spec
... / ...
CommitLineData
1# RPM .spec file for wxMotif. Based on the .spec file for wxGTK
2# (c) by Robert Roebling. Modifications (c) 2000/03 by Robert Fendt.
3
4# Note that this is NOT a relocatable package
5%define pref /usr
6%define ver 2.5.2
7%define ver2 2.5
8%define rel 1
9
10%define portname motif
11%define name wx-%{portname}
12%define wxbasename wx-base
13%define wxconfigname wx%{portname}-%{ver2}-config
14
15Summary: The Motif/Lesstif port of the wxWindows library
16Name: %{name}
17Version: %{ver}
18Release: %{rel}
19License: wxWindows Licence
20Group: X11/Libraries
21Source: wxMOTIF-%{ver}.tar.bz2
22URL: http://www.wxwindows.org
23Packager: Robert Fendt <rfendt@myokay.net>
24BuildRoot: /tmp/wxmotif_root
25
26# all packages providing an implementation of wxWindows library (regardless of
27# the toolkit used) should provide the (virtual) wxwin package, this makes it
28# possible to require wxwin instead of requiring "wxgtk or wxmotif or wxuniv..."
29Provides: wxwin
30
31Provides: wxMotif
32
33Requires: %{wxbasename} = %{ver}
34
35%description
36wxWindows is a free C++ library for cross-platform GUI development.
37With wxWindows, you can create applications for different GUIs (GTK+,
38Motif/LessTif, MS Windows, Mac) from the same source code.
39
40%package devel
41Summary: The Motif/Lesstif port of the wxWindows library
42Group: X11/Libraries
43Requires: %{name} = %{ver}
44Requires: %{wxbasename}-devel = %{ver}
45
46%description devel
47Header files for wxMotif, the Motif/Lesstif port of the wxWindows library.
48
49%package gl
50Summary: The Motif/Lesstif port of the wxWindows library, OpenGL add-on.
51Group: X11/Libraries
52Requires: %{name} = %{ver}
53
54%description gl
55OpenGL add-on library for wxMotif, the Motif/Lesstif port of the wxWindows library.
56
57%package static
58Summary: wxMotif static libraries
59Group: Development/Libraries
60
61%description static
62Static libraries for wxMotif. You need them if you want to link statically against wxMotif.
63
64%prep
65%setup -q -n wxMOTIF-%{ver}
66
67%build
68if [ "$SMP" != "" ]; then
69 export MAKE="make -j$SMP"
70else
71 export MAKE="make"
72fi
73
74mkdir obj-shared
75cd obj-shared
76../configure --prefix=%{pref} --with-odbc --with-opengl --with-motif
77$MAKE
78cd ..
79
80mkdir obj-static
81cd obj-static
82../configure --prefix=%{pref} --disable-shared --with-odbc --with-opengl --with-motif
83$MAKE
84cd ..
85
86%install
87rm -rf $RPM_BUILD_ROOT
88(cd obj-static; make prefix=$RPM_BUILD_ROOT%{pref} install)
89(cd obj-shared; make prefix=$RPM_BUILD_ROOT%{pref} install)
90
91# Remove headers that are part of wx-base-devel:
92
93# --- wxBase headers list begins here ---
94cat <<EOF >wxbase-headers-list
95wx/afterstd.h
96wx/app.h
97wx/apptrait.h
98wx/arrimpl.cpp
99wx/arrstr.h
100wx/beforestd.h
101wx/buffer.h
102wx/build.h
103wx/chkconf.h
104wx/cmdline.h
105wx/confbase.h
106wx/config.h
107wx/containr.h
108wx/datetime.h
109wx/datetime.inl
110wx/datstrm.h
111wx/dde.h
112wx/debug.h
113wx/defs.h
114wx/dir.h
115wx/dlimpexp.h
116wx/dynarray.h
117wx/dynlib.h
118wx/dynload.h
119wx/encconv.h
120wx/event.h
121wx/except.h
122wx/features.h
123wx/ffile.h
124wx/file.h
125wx/fileconf.h
126wx/filefn.h
127wx/filename.h
128wx/filesys.h
129wx/fontenc.h
130wx/fontmap.h
131wx/fs_mem.h
132wx/fs_zip.h
133wx/hash.h
134wx/hashmap.h
135wx/hashset.h
136wx/iconloc.h
137wx/init.h
138wx/intl.h
139wx/iosfwrap.h
140wx/ioswrap.h
141wx/ipc.h
142wx/ipcbase.h
143wx/isql.h
144wx/isqlext.h
145wx/list.h
146wx/listimpl.cpp
147wx/log.h
148wx/longlong.h
149wx/math.h
150wx/memconf.h
151wx/memory.h
152wx/memtext.h
153wx/mimetype.h
154wx/module.h
155wx/msgout.h
156wx/msgout.h
157wx/mstream.h
158wx/object.h
159wx/platform.h
160wx/process.h
161wx/ptr_scpd.h
162wx/regex.h
163wx/scopeguard.h
164wx/snglinst.h
165wx/stack.h
166wx/stopwatch.h
167wx/strconv.h
168wx/stream.h
169wx/string.h
170wx/sysopt.h
171wx/textbuf.h
172wx/textfile.h
173wx/thread.h
174wx/thrimpl.cpp
175wx/timer.h
176wx/tokenzr.h
177wx/txtstrm.h
178wx/types.h
179wx/utils.h
180wx/variant.h
181wx/vector.h
182wx/version.h
183wx/volume.h
184wx/wfstream.h
185wx/wx.h
186wx/wxchar.h
187wx/wxprec.h
188wx/xti.h
189wx/xtistrm.h
190wx/zipstrm.h
191wx/zstream.h
192wx/msw/apptrait.h
193wx/msw/apptbase.h
194wx/msw/chkconf.h
195wx/msw/crashrpt.h
196wx/msw/dde.h
197wx/msw/gccpriv.h
198wx/msw/mimetype.h
199wx/msw/winundef.h
200wx/msw/wrapcctl.h
201wx/msw/wrapwin.h
202wx/fs_inet.h
203wx/gsocket.h
204wx/protocol/file.h
205wx/protocol/ftp.h
206wx/protocol/http.h
207wx/protocol/protocol.h
208wx/sckaddr.h
209wx/sckipc.h
210wx/sckstrm.h
211wx/socket.h
212wx/url.h
213wx/msw/gsockmsw.h
214wx/xml/xml.h
215wx/xtixml.h
216wx/db.h
217wx/dbkeyg.h
218wx/dbtable.h
219EOF
220# --- wxBase headers list ends here ---
221for f in `cat wxbase-headers-list` ; do
222 rm -f $RPM_BUILD_ROOT%{_includedir}/$f
223done
224
225# list of all core headers:
226find $RPM_BUILD_ROOT/usr/include/wx -type f | sed -e "s,$RPM_BUILD_ROOT,,g" >core-headers.files
227
228# remove wxBase files so that RPM doesn't complain about unpackaged files:
229rm -f $RPM_BUILD_ROOT%{_libdir}/libwx_base*
230rm -f $RPM_BUILD_ROOT%{_datadir}/aclocal/*
231rm -f $RPM_BUILD_ROOT%{_datadir}/locale/*/*/*
232
233
234%clean
235rm -rf $RPM_BUILD_ROOT
236
237%post
238/sbin/ldconfig
239
240%postun
241/sbin/ldconfig
242
243%post gl
244/sbin/ldconfig
245
246%postun gl
247/sbin/ldconfig
248
249%post devel
250# Install wx-config if there isn't any
251if test ! -f %{_bindir}/wx-config ; then
252 ln -sf %{wxconfigname} %{_bindir}/wx-config
253fi
254
255%preun devel
256# Remove wx-config if it points to this package
257if test -f %{_bindir}/wx-config -a -f /usr/bin/md5sum ; then
258 SUM1=`md5sum %{_bindir}/%{wxconfigname} | cut -c 0-32`
259 SUM2=`md5sum %{_bindir}/wx-config | cut -c 0-32`
260 if test "x$SUM1" = "x$SUM2" ; then
261 rm -f %{_bindir}/wx-config
262 fi
263fi
264
265
266%files
267%defattr(-,root,root)
268%doc COPYING.LIB *.txt
269%dir %{_datadir}/wx
270%{_datadir}/wx/*
271%{_libdir}/libwx_%{portname}*_core*.so.*
272%{_libdir}/libwx_%{portname}*_html*.so.*
273%{_libdir}/libwx_%{portname}*_adv*.so.*
274%{_libdir}/libwx_%{portname}*_dbgrid*.so.*
275
276%files devel -f core-headers.files
277%defattr(-,root,root)
278%{_libdir}/libwx_%{portname}*_core*.so
279%{_libdir}/libwx_%{portname}*_html*.so
280%{_libdir}/libwx_%{portname}*_adv*.so
281%{_libdir}/libwx_%{portname}*_dbgrid*.so
282%{_libdir}/libwx_%{portname}*_gl*.so
283%dir %{_libdir}/wx
284%{_libdir}/wx/*
285%{_bindir}/%{wxconfigname}
286
287%files gl
288%defattr(-,root,root)
289%{_libdir}/libwx_%{portname}*_gl*.so.*
290
291%files static
292%defattr (-,root,root)
293%{_libdir}/libwx_%{portname}*.a