File python-pycopia-core.spec of Package python-pycopia-core

#
# spec file for package python-pycopia-core
#
# Copyright (c) 2013 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/
#


Name:           python-pycopia-core
Version:        1.0
Release:        0
Summary:        Core components of the Pycopia application framework
License:        LGPL-2.1+
Group:          Development/Languages/Python
Url:            http://www.pycopia.net/
Source:         http://pypi.python.org/packages/source/p/pycopia-core/pycopia-core-%{version}.tar.gz
BuildRequires:  fdupes
BuildRequires:  python-devel
BuildRequires:  python-setuptools
#BuildRequires:  python-pycopia-aid
#BuildRequires:  python-pycopia-utils
Requires:       python-pycopia-aid
Requires:       python-pycopia-utils
BuildRoot:      %{_tmppath}/%{name}-%{version}-build
%if 0%{?suse_version} && 0%{?suse_version} <= 1110
%{!?python_sitelib: %global python_sitelib %(python -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")}
%else
BuildArch:      noarch
%endif

%description
Core components of the Pycopia application framework.
Modules used by other PYcopia packages, that you can also use in your
applications. There is a asynchronous handler interface, CLI tools,
and misc modules.

%prep
%setup -q -n pycopia-core-%{version}
# Fix non-executable scripts rpmlint warning:
find . -type f -name "*.py" -exec sed -i -e "s|#!\/usr\/bin\/python.*||" {} \;

%build
python setup.py build

%install
python setup.py install --prefix=%{_prefix} --root=%{buildroot}
%fdupes %{buildroot}%{python_sitelib}

#%%check
#python test.py

%files
%defattr(-,root,root,-)
%doc README.txt
%{_bindir}/dos2mac
%{_bindir}/google
%{_bindir}/ipinfo
%{_bindir}/lookup
%{_bindir}/mac2dos
%{_bindir}/moddeps
%{_bindir}/pyedit
%{_bindir}/pyps
%{_bindir}/pypstree
%{_bindir}/pywhich
%{python_sitelib}/*
%dir %{_sysconfdir}/pycopia
%config %{_sysconfdir}/pycopia/*

%changelog
openSUSE Build Service is sponsored by