File python-django-page-cms.spec of Package python-django-page-cms

#
# spec file for package python-django-page-cms
#
# 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/
#

%define mod_name django-page-cms

Name:           python-%{mod_name}
Version:        1.5.2
Release:        0
Url:            http://packages.python.org/django-page-cms/
Summary:        A tree based Django CMS application
License:        BSD
Group:          Development/Languages/Python
Source:         https://pypi.python.org/packages/source/d/django-page-cms/%{mod_name}-%{version}.tar.gz
BuildRoot:      %{_tmppath}/%{name}-%{version}-build
BuildRequires:  dos2unix
BuildRequires:  python-devel
BuildRequires:  python-setuptools
BuildRequires:  fdupes
Requires:       python-beautifulsoup
Requires:       python-django
Requires:       python-django-mptt
Requires:       python-django-tagging
Requires:       python-html5lib
%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
This Django CMS enable you to create and administrate hierarchical pages in a simple and powerful way.

Django page CMS is based around a placeholders concept. A placeholder is special template tag that
you use in your page templates. Every time you add a placeholder in your template  a field
dynamically appears in the page admin.

This CMS is know to work on Django 1.1.3, 1.2.5 and 1.3-beta-1


%prep
%setup -q -n %{mod_name}-%{version}
# Fix script-without-shebang.
find -name '*.css' -o -name '*.html' -o -name '*.js' -o -name '*.php' -o -name '*.txt' -o -name '*.pack' | xargs chmod -x
# Fix wrong-script-end-of-line-encoding.
find -name '*.css' -o -name '*.html' -o -name '*.js' -o -name '*.php' -o -name '*.txt' -exec dos2unix {} \;

%build
python setup.py build

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

%files
%defattr(-,root,root,-)
%doc AUTHORS README.rst THANKS TODO doc/*.rst
%{python_sitelib}/*

%changelog
openSUSE Build Service is sponsored by