[Fedora-packaging] Package for pysvn

Timothy Selivanow timothy.selivanow at virtualxistenz.com
Sat Jan 5 00:35:44 UTC 2008

I'm trying to make a package for pysvn [http://pysvn.tigris.org] and I
have a few questions.  Right now it's not compiling, rpmbuild is
complaining about "error: line 27: Package does not exist: %description
debuginfo", this must have changed either in F7 or F8 because this spec
worked a long time ago (F6/F7, not sure which).

Also, I discovered that the installer makes a differently named .so
depending on the version of python that it is compiling against, and I'd
like to know the best way to do an if style statement that will solve
that (I'd like to be able to use the same spec on CentOS too).

So, any help and comments would be much appreciated.  Thanks!

Below is the spec file.


%{!?python_sitearch: %define python_sitearch %(%{__python} -c "from
distutils.sysconfig import get_python_lib; print get_python_lib(1)")}
%{!?python_version: %define python_version %(%{__python} -c 'from sys
import version_info; print str(version_info[0]) + "." +

Name:           pysvn
Version:        1.5.2
Release:        1%{dist}
Summary:        Pythonic style bindings for Subversion

Group:          Development/Languages
License:        http://www.apache.org/LICENSE.txt
URL:            http://pysvn.tigris.org/
Source0:        pysvn-%{version}.tar.gz
%{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
Requires:       python > 2.3

BuildRequires:  python-devel
BuildRequires:	PyXML
BuildRequires:	subversion-devel
BuildRequires:	libgssapi-devel
BuildRequires:	neon-devel
BuildRequires:	chrpath

Pythonic style bindings for Subversion

%description debuginfo
debug info

%setup -q

cd Source
CFLAGS="$RPM_OPT_FLAGS" %{__python} setup.py configure
cd ../Tests

mkdir -p $RPM_BUILD_ROOT%{python_sitearch}/pysvn
cp Source/pysvn/__init__.py $RPM_BUILD_ROOT%{python_sitearch}/pysvn
cp Source/pysvn/__init__.pyc $RPM_BUILD_ROOT%{python_sitearch}/pysvn

#%if %(test [ "%{python_version}" == "2.5" ])
cp Source/pysvn/_pysvn_2_5.so $RPM_BUILD_ROOT%{python_sitearch}/pysvn
chrpath --delete $RPM_BUILD_ROOT%{python_sitearch}/pysvn/_pysvn_2_5.so
cd $RPM_BUILD_ROOT%{python_sitearch}/pysvn
ln -s _pysvn_2_5.so _pysvn.so
#cp Source/pysvn/_pysvn.so $RPM_BUILD_ROOT%{python_sitearch}/pysvn
#chrpath --delete $RPM_BUILD_ROOT%{python_sitearch}/pysvn/_pysvn.so


%doc Docs/pysvn.html Docs/pysvn_prog_guide.html Docs/pysvn_prog_ref.html


* Fri Jan 04 2008 Timothy Selivanow
<timothy.selivanow at virtualxistenz.com> - 1.5.2-2
- Attempting to make the spec work with different versions of Python

* Mon Sep 03 2007 Timothy Selivanow
<timothy.selivanow at virtualxistenz.com> - 1.5.2-1
- Update to 1.5.2
- Some spec clean up

* Fri Jan 12 2007 Timothy Selivanow
<timothy.selivanow at virtualxistenz.com> - 1.5.0-1
- Initial spec creation

---END SPEC---

/ If you will practice being fictional for a while, you will understand that \
| fictional characters are sometimes more real than people with bodies and   |
\ heartbeats.                                                                /
   \   \
        \ /\
        ( )
      .( o ).

More information about the Fedora-packaging mailing list