]>
Commit | Line | Data |
---|---|---|
2224580a | 1 | %define pref /usr |
32037c4e | 2 | %define ver 2.3.2 |
8c8fb2f6 | 3 | %define ver2 2.3 |
014e19de | 4 | %define rel 1 |
2224580a VZ |
5 | |
6 | Summary: wxBase library - non-GUI support classes of wxWindows toolkit | |
7 | Name: wxBase | |
8 | Version: %{ver} | |
9 | Release: %{rel} | |
10 | Copyright: wxWindows Licence | |
11 | Group: Development/Libraries | |
b5fa0a3e VZ |
12 | Source: wxBase-%{ver}.tar.bz2 |
13 | URL: http://www.wxwindows.org | |
2224580a | 14 | Packager: Vadim Zeitlin <vadim@wxwindows.org> |
31fe72b6 VZ |
15 | Prefix: %{pref} |
16 | BuildRoot: /var/tmp/%{name}-root | |
2224580a VZ |
17 | |
18 | %description | |
19 | wxBase is a collection of C++ classes providing basic data structures (strings, | |
20 | lists, arrays), powerful wxDateTime class for date manipulations, portable | |
21 | wrappers around many OS-specific functions allowing to build the same program | |
22 | under all supported folders, wxThread class for writing multithreaded programs | |
23 | using either Win32 or POSIX threads and much more. wxBase currently supports | |
24 | the following platforms: Win32, generic Unix (Linux, FreeBSD, Solaris, HP-UX, | |
25 | ...) and BeOS. | |
26 | ||
27 | %package devel | |
28 | Summary: wxBase headers needed for developping with wxBase | |
29 | Group: Development/Libraries | |
5dcf9614 | 30 | Requires: wxBase = %{ver} |
2224580a VZ |
31 | |
32 | %description devel | |
33 | Header files for wxBase. You need them to develop programs using wxBase. | |
34 | ||
5dcf9614 VS |
35 | %package static |
36 | Summary: wxBase static libraries | |
37 | Group: Development/Libraries | |
38 | ||
39 | %description static | |
40 | Static libraries for wxBase. You need them if you want to link statically against wxBase. | |
41 | ||
2224580a | 42 | %prep |
31fe72b6 | 43 | %setup -n wxBase-%{ver} |
2224580a VZ |
44 | |
45 | %build | |
46 | if [ "$SMP" != "" ]; then | |
47 | export MAKE="make -j$SMP" | |
48 | else | |
49 | export MAKE="make" | |
50 | fi | |
5dcf9614 | 51 | |
5dcf9614 VS |
52 | mkdir obj-shared |
53 | cd obj-shared | |
54 | ../configure --prefix=%{pref} --enable-soname --disable-gui --disable-std_iostreams | |
55 | $MAKE | |
56 | cd .. | |
57 | ||
58 | mkdir obj-static | |
59 | cd obj-static | |
60 | ../configure --prefix=%{pref} --disable-shared --disable-gui --disable-std_iostreams | |
61 | $MAKE | |
62 | cd .. | |
63 | ||
2224580a VZ |
64 | %install |
65 | rm -rf $RPM_BUILD_ROOT | |
5dcf9614 VS |
66 | (cd obj-static ; make prefix=$RPM_BUILD_ROOT%{pref} install) |
67 | (cd obj-shared ; make prefix=$RPM_BUILD_ROOT%{pref} install) | |
2224580a | 68 | |
acea2a0b VS |
69 | %find_lang wxstd |
70 | ||
2224580a VZ |
71 | %clean |
72 | rm -rf $RPM_BUILD_ROOT | |
73 | ||
74 | %post | |
75 | /sbin/ldconfig | |
76 | ||
77 | %postun | |
78 | /sbin/ldconfig | |
79 | ||
32037c4e VS |
80 | %post devel |
81 | # Install wx-config if there isn't any | |
82 | if test ! -f %{_bindir}/wx-config ; then | |
83 | ln -sf wxbase-%{ver2}-config %{_bindir}/wx-config | |
84 | fi | |
85 | ||
86 | %preun devel | |
87 | # Remove wx-config if it points to this package | |
88 | if test -f %{_bindir}/wx-config -a -f /usr/bin/md5sum ; then | |
89 | SUM1=`md5sum %{_bindir}/wxbase-%{ver2}-config | cut -c 0-32` | |
90 | SUM2=`md5sum %{_bindir}/wx-config | cut -c 0-32` | |
91 | if test "x$SUM1" = "x$SUM2" ; then | |
92 | rm -f %{_bindir}/wx-config | |
93 | fi | |
94 | fi | |
95 | ||
acea2a0b | 96 | %files -f wxstd.lang |
32037c4e VS |
97 | %defattr (-,root,root) |
98 | %doc COPYING.LIB *.txt | |
99 | %{_libdir}/libwx_base*so.* | |
156da3a9 | 100 | |
32037c4e VS |
101 | %files devel |
102 | %defattr (-,root,root) | |
103 | %dir %{_includedir}/wx | |
104 | %{_includedir}/wx/* | |
105 | %{_libdir}/libwx_base*.so | |
106 | %dir %{_libdir}/wx | |
107 | %{_libdir}/wx/* | |
108 | %{_bindir}/wxbase-%{ver2}-config | |
debc175a | 109 | %{_datadir}/aclocal/*.m4 |
2224580a | 110 | |
5dcf9614 VS |
111 | %files static |
112 | %defattr (-,root,root) | |
113 | %{_libdir}/lib*.a |