forked from pool/python-pysvn
Fix building python 3 package on openSUSE 11.4 (forwarded request 116037 from TheBlackCat) OBS-URL: https://build.opensuse.org/request/show/116041 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-pysvn?expand=0&rev=18
91 lines
3.0 KiB
RPMSpec
91 lines
3.0 KiB
RPMSpec
#
|
|
# spec file for package python3-pysvn
|
|
#
|
|
# Copyright (c) 2012 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: python3-pysvn
|
|
Version: 1.7.6
|
|
Release: 0
|
|
Summary: Highlevel Subversion Python 3 Bindings
|
|
License: Apache-2.0
|
|
Group: Development/Libraries/Python
|
|
Url: http://pysvn.tigris.org
|
|
Source0: http://pysvn.barrys-emacs.org/source_kits/pysvn-%{version}.tar.gz
|
|
Patch0: bnc445431_pysvn_svnenv.cpp.diff
|
|
BuildRequires: gcc-c++
|
|
BuildRequires: libcom_err-devel
|
|
BuildRequires: libexpat-devel
|
|
BuildRequires: neon-devel
|
|
BuildRequires: python3
|
|
BuildRequires: python3-2to3
|
|
BuildRequires: python3-devel
|
|
BuildRequires: python3-distribute
|
|
BuildRequires: python3-xml
|
|
BuildRequires: subversion-devel
|
|
BuildRequires: pkgconfig(apr-1)
|
|
Requires: neon
|
|
Requires: subversion
|
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
|
%if 0%{?suse_version} <= 1140
|
|
%{!?python3_sitearch: %global python3_sitearch %(python3 -c "from distutils.sysconfig import get_python_lib; print(get_python_lib(1))")}
|
|
%{!?py3_ver: %global py3_ver %(python3 -c "import sys; version=str(sys.version_info[0]) + '.' + str(sys.version_info[1]); print(version)" 2>/dev/null || echo PYTHON-NOT-FOUND)}
|
|
%endif
|
|
Requires: python3 >= %{py3_ver}
|
|
|
|
%description
|
|
pysvn is a highlevel and easy to use Python bindings to Subversion. The pysvn
|
|
project's goal is to enable Tools to be written in Python that use Subversion.
|
|
Windows, Mac OS X, Linux and other unix platforms are supported.
|
|
|
|
Features:
|
|
* Supports all svn client features
|
|
* Supports svn transaction features required to write svn pre-commit
|
|
hooks
|
|
* Easy to learn and use
|
|
* Python like interface
|
|
* Good Documentation and examples
|
|
* No need to understand the Subversion C API
|
|
|
|
%prep
|
|
%setup -q -n pysvn-%{version}
|
|
%patch0 -p0
|
|
# patch in rpm compiler flags
|
|
sed -i 's/CCFLAGS=-Wall/CCFLAGS=$(RPM_OPT_FLAGS) -Wall -Wno-deprecated/g' Source/setup_configure.py
|
|
|
|
%build
|
|
cd Source
|
|
python3 setup.py backport
|
|
python3 setup.py configure
|
|
# --norpath
|
|
make %{?_smp_mflags}
|
|
|
|
%install
|
|
mkdir -p %{buildroot}/%{python3_sitearch}/pysvn
|
|
cp Source/pysvn/{__init__.py,_pysvn*.so} %{buildroot}/%{python3_sitearch}/pysvn
|
|
python3 setup.py install --prefix=%{_prefix} --root=%{buildroot}
|
|
rm -f Docs/generate_cpp_docs_from_html_docs.py
|
|
|
|
#%%check
|
|
#cd Tests
|
|
#make %{?_smp_mflags}
|
|
|
|
%files
|
|
%defattr(-,root,root)
|
|
%doc LICENSE.txt Docs Examples
|
|
%{python3_sitearch}/*
|
|
|
|
%changelog
|