Sophie

Sophie

distrib > Mandriva > 10.2 > x86_64 > by-pkgid > a1ccc9098c7089ab3d9b835e34970fab > files > 2

wxBase-2.4.2-2mdk.src.rpm

%define name wxBase
%define version 2.4.2
%define release 2mdk

%define major 2.4
%define minor 0
%define libname %mklibname wx_base %{major} %{minor}

Summary: The wxBase library - non-GUI support classes of wxWidgets toolkit
Name: %{name}
Version: %{version}
Release: %{release}
Epoch: 1
License: wxWindows Licence
Group: System/Libraries
Source: http://prdownloads.sourceforge.net/wxwindows/%{name}-%{version}.tar.bz2
URL: http://www.wxwindows.org/
BuildRoot: %_tmppath/%name-buildroot
BuildRequires: zlib-devel

%description
wxBase is a collection of C++ classes providing basic data structures (strings,
lists, arrays), powerful wxDateTime class for date manipulations, portable
wrappers around many OS-specific functions allowing to build the same program
under all supported folders, wxThread class for writing multithreaded programs
using either Win32 or POSIX threads and much more. wxBase currently supports
the following platforms: Win32, generic Unix (Linux, FreeBSD, Solaris, HP-UX,
...) and BeOS.

%package -n %{libname}
Group: System/Libraries
Summary: The wxBase library
Provides: libwxBase libwx_base%{major} libwx_base libwxBase%{minor}
Obsoletes: %{epoch}:libwxBase%{minor}

%description -n %{libname}
wxBase is a collection of C++ classes providing basic data structures (strings,
lists, arrays), powerful wxDateTime class for date manipulations, portable
wrappers around many OS-specific functions allowing to build the same program
under all supported folders, wxThread class for writing multithreaded programs
using either Win32 or POSIX threads and much more. wxBase currently supports
the following platforms: Win32, generic Unix (Linux, FreeBSD, Solaris, HP-UX,
...) and BeOS.

This package contains the libraries.

%package -n %{libname}-devel
Summary: The wxBase headers needed for developing with wxBase
Group: Development/Other
Requires: %{libname} = %{epoch}:%{version}-%{release}
Provides: libwxBase-devel libwx_base%{major}-devel libwx_base-devel libwxBase%{minor}-devel
Obsoletes: %{epoch}:libwxBase%{minor}-devel

%description -n %{libname}-devel
Header files and dynamic library for wxBase. You need them to develop programs 
using wxBase.

%package -n %{libname}-static-devel
Summary: The wxBase static library for wxBase
Group: Development/Other
Requires: %{libname}-devel = %{epoch}:%{version}-%{release}
Provides: libwxBase-static-devel libwx_base2.4-static-devel libwx_base-static-devel 

%description -n %{libname}-static-devel
Static library for wxBase. You need them to develop programs using wxBase which
don't require the wxBase runtime library.

%prep

%setup -q

export OPTIONS="--disable-gui --disable-std_iostreams \
	--enable-optimise --with-zlib=sys"
export CONFIGURE_TOP="../"

mkdir obj-shared
pushd obj-shared
%configure --enable-soname $OPTIONS --includedir=%_includedir/wxbase
popd

mkdir obj-static
pushd obj-static
%configure --disable-shared $OPTIONS --includedir=%_includedir/wxbase
popd

%build

pushd obj-shared
%make
popd
pushd obj-static
%make
popd

%install
rm -rf $RPM_BUILD_ROOT

pushd obj-static
%makeinstall includedir=%buildroot%_includedir/wxbase
popd
mv %{buildroot}/%{_bindir}/wxbase-%major-config %{buildroot}/%{_bindir}/wxbase-%major-static-config

pushd obj-shared
%makeinstall includedir=%buildroot%_includedir/wxbase
popd
mv %{buildroot}/%{_bindir}/wxbase-%major-config %{buildroot}/%{_bindir}/wxbase-%major-shared-config
rm -f %buildroot%_bindir/wx-config

%find_lang wxstd

%clean
rm -rf $RPM_BUILD_ROOT

%post -n %{libname} -p /sbin/ldconfig

%postun -n %{libname} -p /sbin/ldconfig

%post -n %{libname}-devel
update-alternatives --install %{_bindir}/wxbase-%major-config wx-config %{_bindir}/wxbase-%major-shared-config 10

%postun -n %{libname}-devel
update-alternatives --remove wxbase-%major-config %{_bindir}/wxbase-%major-shared-config

%post -n %{libname}-static-devel
update-alternatives --install %{_bindir}/wxbase-%major-config wx-config %{_bindir}/wxbase-%major-static-config 20

%postun -n %{libname}-static-devel
update-alternatives --remove wxbase-%major-config %{_bindir}/wxbase-%major-static-config


%files -n %{libname} -f wxstd.lang
%defattr (-, root, root)
%doc COPYING.LIB LICENCE.txt README.txt
%{_libdir}/*.so.*

%files -n %{libname}-devel
%defattr (-,root,root)
%dir %{_libdir}/wx
%dir %{_libdir}/wx/include
%dir %{_libdir}/wx/include/*
%{_libdir}/wx/include/base*/wx/setup.h
%{_datadir}/aclocal/*
%_includedir/wxbase

#%files -n %{libname}-devel
%{_libdir}/*.so
%{_bindir}/wxbase-%major-shared-config

%files -n %{libname}-static-devel
%defattr (-,root,root)
%{_libdir}/*.a
%{_bindir}/wxbase-%major-static-config

%changelog
* Wed Sep 29 2004 Götz Waschk <waschk@linux-mandrake.com> 2.4.2-2mdk
- epoch changes to solve -devel installation problem (Guillaume Bedot)

* Mon Sep 27 2004 Götz Waschk <waschk@linux-mandrake.com> 2.4.2-1mdk
- back to the 2.4 version, wxBase 2.5 is included in wxGTK

* Mon Aug 30 2004 Lenny Cartier <lenny@mandrakesoft.com> 2.5.2-1mdk
- 2.5.2

* Fri Jun 18 2004 Lenny Cartier <lenny@mandrakesoft.com> 2.4.1-3mdk
- rebuild

* Wed Feb 25 2004 Götz Waschk <waschk@linux-mandrake.com> 2.4.1-2mdk
- rename config symlink to wxbase-2.4-config
- move headers to %_includedir/wxbase
- fix conflict with wxGTK

* Tue Jul 15 2003 Buchan Milne <bgmilne@linux-mandrake.com> 2.4.1-1mdk
- 2.4.1
- Solve wx-config clobbering with alternatives

* Wed Jun 04 2003 Buchan Milne <bgmilne@linux-mandrake.com> 2.4.0-2mdk
- Provide/Obsolete libwxBase0*

* Tue Jun 03 2003 Buchan Milne <bgmilne@linux-mandrake.com> 2.4.0-1mdk
- 2.4.0 (fixes a bug in 2.2.9 that has caused me lots of headaches)
- Provide .so link in -devel so we can actually use this
- Use mklibname and make rpmlint happier
- Conflict with wxgtk-devel packages
- Buildrequires
- Add -static-devel, name lib packages like lib files and cleanup configure

* Wed Jan 29 2003 Lenny Cartier <lenny@mandrakesoft.com> 2.2.7-3mdk
- rebuild

* Wed Feb 13 2002 Lenny Cartier <lenny@mandrakesoft.com> 2.2.7-2mdk
- use shared libs

* Mon Jun 18 2001 Yves Bailly <ybailly@mandrakesoft.com> 2.2.7-1mdk
- upgraded to 2.2.7

* Thu Feb 15 2001 Lenny Cartier <lenny@mandrakesoft.com> 2.2.5-1mdk
- new in contribs