# # spec file for package python-odfpy # # Copyright (c) 2010 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 %define real_name odfpy # # Name: python-%{real_name} Group: Development/Libraries/Python Version: 0.9.2 Release: 1 License: dual license(GPLv2+|ASLv2.0) Summary: Tools and Python API for manipulating OASIS ODF documents Autoreqprov: on Source: %{real_name}-%{version}.tar.bz2 BuildRoot: %{_tmppath}/%{name}-%{version}-build BuildRequires: perl python python-setuptools %if 0%{?suse_version} >= 1120 BuildArch: noarch %endif Url: http://opendocumentfellowship.com/projects/odfpy # Packager: Ciaran Farrell %{py_requires} %description odfpy aims to be a complete API for OpenDocument in Python. Unlike other more convenient APIs, this one is essentially an abstraction layer just above the XML format. The main focus has been to prevent the programmer from creating invalid documents. It has checks that raise an exception if the programmer adds an invalid element, adds an attribute unknown to the grammar, forgets to add a required attribute or adds text to an element that doesn't allow it. %prep %setup -n %{real_name}-%{version} %build export CFLAGS="$RPM_OPT_FLAGS" python setup.py build %install python setup.py install --prefix=%{_prefix} --root=$RPM_BUILD_ROOT --record-rpm=INSTALLED_FILES perl -p -i -e 's|(.*/man/.*)|${1}*|g' INSTALLED_FILES %clean rm -rf $RPM_BUILD_ROOT %files -f INSTALLED_FILES %defattr(-,root,root) %changelog * Wed Feb 17 2010 - cfarrell1980@gmail.com - Update to 0.9.2 * Tue Nov 03 2009 - cfarrell1980@gmail.com - Update to 0.9.1 * Tue Aug 12 2008 - cfarrell - Initial import and build. - darix suggested to use perl to gather the man files.