File wxGTK-doc.spec of Package wxGTK-doc

#
# spec file for package wxGTK-doc (Version 2.8.10.1)
#
# Copyright (c) 2009 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.

# Please submit bugfixes or comments via http://bugs.opensuse.org/
#

# norootforbuild


Name:           wxGTK-doc
Group:          System/Libraries
Url:            http://www.wxwidgets.org/
Summary:        wxGTK Documentation
License:        GPL v2 or later
Version:        2.8.10.1
Release:        1
%define     wxGTKver    %(sh -c 'echo %version | sed s/\\\\.[0-9]\\$//')
# Source from http://www.wxpython.org/
Source:         http://downloads.sourceforge.net/wxpython/wxPython-docs-%{version}.tar.bz2
# %( exec >&2 ; cd %{_sourcedir} ; if ! test -f wxWidgets-%{wxGTKver}-HTML.tar.bz2 ; then wget -N http://downloads.sourceforge.net/wxwindows/wxWidgets-%{wxGTKver}-HTML.zip ; mkdir wxWidgets-HTML ; cd wxWidgets-HTML ; unzip ../wxWidgets-%{wxGTKver}-HTML.zip ; tar -jcf ../wxWidgets-%{wxGTKver}-HTML.tar.bz2 * ; cd .. ; rm -r wxWidgets-HTML ; fi )
Source1:        wxWidgets-%{wxGTKver}-HTML.tar.bz2
# %( exec >&2 ; cd %{_sourcedir} ; if ! test -f wxWidgets-%{wxGTKver}-PDF.tar.bz2 ; then wget -N http://downloads.sourceforge.net/wxwindows/wxWidgets-%{wxGTKver}-PDF.zip ; mkdir wxWidgets-PDF ; cd wxWidgets-PDF ; unzip ../wxWidgets-%{wxGTKver}-PDF.zip ; tar -jcf ../wxWidgets-%{wxGTKver}-PDF.tar.bz2 * ; cd .. ; rm -r wxWidgets-PDF ; fi )
Source2:        wxWidgets-%{wxGTKver}-PDF.tar.bz2
# Sources from http://www.wxpython.org/
Source3:        http://downloads.sourceforge.net/wxpython/wxPython-demo-%{version}.tar.bz2
Source4:        wxGTK-doc-rpmlintrc
# Uncomment to save space:
#NoSource:       0
#NoSource:       1
#NoSource:       2
#NoSource:       3
Requires:       wxGTK = %{version}
BuildRequires:  fdupes
BuildRoot:      %{_tmppath}/%{name}-%{version}-build
# One of examples contain binary, the package cannot be noarch and rpm
# does not have a feature to make other patzs noarch.
#BuildArch:      noarch

%description
This package contains wxGTK documentation in HTML and PDF formats.



Authors:
--------
    Robert Roebling <robert@roebling.de>

%package -n python-wxGTK-doc
License:        GPL v2 or later
Group:          Development/Libraries/Python
Summary:        wxPython Documentation
Url:            http://www.wxpython.org/
Requires:       python-wxGTK = %{version}

%description -n python-wxGTK-doc
This package contains wxPython (package python-wxGTK) documentation.



Authors:
--------
    Robin Dunn <robin@alldunn.com>

%package -n python-wxGTK-examples
License:        GPL v2 or later
Group:          Development/Libraries/Python
Summary:        wxPython Demos and Examples
Url:            http://www.wxpython.org/
Requires:       python-wxGTK = %{version} python-numeric python-opengl

%description -n python-wxGTK-examples
This package contains wxPython (package python-wxGTK) demos and
examples.



Authors:
--------
    Robin Dunn <robin@alldunn.com>

%prep
%setup -q -n wxPython-%{version} -a 1 -a 2 -b 3
chmod -x demo/bmp_source/customcontrol.png samples/wxPIA_book/Chapter-17/sample-text.txt

%build

%install
rm -rf $RPM_BUILD_ROOT
find . -name '*.orig' -exec rm {} \;
install -m 755 -d $RPM_BUILD_ROOT/$RPM_DOC_DIR/wxGTK/examples
cp -r docs/{mshtml,pdf} $RPM_BUILD_ROOT/$RPM_DOC_DIR/wxGTK
install -m 755 -d $RPM_BUILD_ROOT/$RPM_DOC_DIR/python-wxGTK
cp -r {samples,demo} $RPM_BUILD_ROOT/$RPM_DOC_DIR/python-wxGTK
cp -r docs $RPM_BUILD_ROOT/$RPM_DOC_DIR/python-wxGTK
%fdupes $RPM_BUILD_ROOT%{_datadir}

%clean
rm -rf $RPM_BUILD_ROOT

%files
%defattr(-, root, root)
%dir %{_docdir}/wxGTK
%doc %{_docdir}/wxGTK/mshtml
%doc %{_docdir}/wxGTK/pdf

%files -n python-wxGTK-doc
%defattr(-, root, root)
%dir %{_docdir}/python-wxGTK
%doc %{_docdir}/python-wxGTK/docs

%files -n python-wxGTK-examples
%defattr(-, root, root)
%dir %{_docdir}/python-wxGTK
%doc %{_docdir}/python-wxGTK/samples
%doc %{_docdir}/python-wxGTK/demo

%changelog
openSUSE Build Service is sponsored by