File wxGTK.spec of Package libwxgtk2.8

# norootforbuild

%define wx_version	2.8

Name:			wxGTK
Version:		2.8.12
Release:		1
Group:			System/Libraries
Summary:		C++ framework for cross-platform development
License:		wxWidgets
URL:			http://wxwidgets.org/
Source0:		wxWidgets-%{version}.tar.gz
BuildRoot:		%{_tmppath}/%{name}-%{version}-build
BuildRequires:	expat
BuildRequires:	gcc-c++
BuildRequires:	gtk2-devel
Requires:		libpng-devel
BuildRequires:	libjpeg-devel
BuildRequires:	libtiff-devel
#BuildRequires:	lynx

%description
C++ framework for cross-platform development.

%package devel
Summary:	Include files and libraries for wxWidgets development
Group:		Development/Libraries/C and C++
Requires:	gtk2-devel
Requires:	libpng-devel
Requires:	libjpeg-devel
Requires:	libtiff-devel

%description devel
Development package for wxWidgets.

%prep
%setup -q -n wxWidgets-%{version}

%build

%__install -dm 755 build-unicode
pushd build-unicode
	../configure \
		--prefix=%{_prefix} \
		--datadir=%{_datadir} \
		--libdir='${prefix}/%{_lib}' \
		--enable-rpath='${prefix}/%{_lib}' \
		--disable-backtrace \
		--disable-catch_segvs \
		--disable-debug \
		--disable-dialupman \
		--disable-gpe \
		--disable-profile \
		--enable-optimise \
		--enable-shared \
		--enable-tabdialog \
		--enable-threads \
		--enable-unicode \
		--enable-gui \
                --enable-compat24

	%__make clean
	%__make %{?jobs:-j%{jobs}}

%install
pushd build-unicode
	%makeinstall
popd
pushd %{buildroot}%{_bindir}
%__rm -r wx-config
ln -s %{_libdir}/wx/config/gtk2-unicode-release-2.8 wx-config
popd


%post -p /sbin/ldconfig
%postun -p /sbin/ldconfig

%clean
[ -d "%{buildroot}" -a "%{buildroot}" != "" ] && %__rm -rf "%{buildroot}"

%files
%defattr(-,root,root)
%doc docs/*.txt
%{_libdir}/*

%files devel
%defattr(-,root,root)
%{_bindir}/*
%{_includedir}/wx-%{wx_version}/*
%{_libdir}/*
%{_datadir}/*