Re: [Trac] How to setup trac 0.12 - subversion 1.6\1.7, python 2.6+ ? Is it possoble at all?

164 views
Skip to first unread message

Thomas Moschny

unread,
Feb 26, 2013, 11:00:12 AM2/26/13
to trac-...@googlegroups.com
Hi,

attached is a patch against rpmforge's subversion.spec for building it with Python 2.6. This is on Centos5, works fine for us.

HTH
Thomas


2013/2/26 st0ne_c0ld <nativep...@gmail.com>
Hello everybody,

We have somehow customized trac 0.12rc1
I have to install it to some new server. And I have problem with subversion dependencies. When I try to check if python could use svn("from svn import fs") I have an error that svn module either not found or just "Segmentation fault" or "Symbols not found" and so on.

I tried to build subversoin bindings to python and all the time process fails when I try to build them(make swig-py).


Does anyone have Trac on the RHEL\OEL\CentOS, with python 2.6 and subversion 1.6/1.7.8 ?
Or maybe I should use Debian-based OS?
Or maybe someone have prebuilt binaries and could give them to me? :-)

I wasted a week trying to make it work. But when I use Python 2.4 - our plugins doesn't work. When I use python 2.6 - Subversion connectivity doesn't work because I could not compile required svn bindings. I just stuck with this.

PS:
I also asked this question on stackoverflow but nobody had a correct answer to the issue yet.

--
Dmitry

--
You received this message because you are subscribed to the Google Groups "Trac Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to trac-users+...@googlegroups.com.
To post to this group, send email to trac-...@googlegroups.com.
Visit this group at http://groups.google.com/group/trac-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.
 
 



--
Thomas Moschny <thomas....@gmail.com>
svn-py26.patch

st0ne_c0ld

unread,
Feb 26, 2013, 1:06:52 PM2/26/13
to trac-...@googlegroups.com
Hi Thomas,

Sorry for asking, but could you tell which version of the spec I should patch?
I found something on the github: https://github.com/repoforge/rpms/tree/master/specs/subversion
But I do not quietly understand what file I should patch(there is no subversion.spec)?

And am I right that after patching correct spec file I should run "rpm build" with some options and it will download all required source files by itself according to spec file? (I'm not very familiar with rpm building)

Thanks,
Dmitry

Thomas Moschny

unread,
Feb 26, 2013, 2:18:31 PM2/26/13
to trac-...@googlegroups.com

This is a pseudo-script of what to do - not really tested, but you should get the idea:

# install requirements (be sure you have set multilib_policy=best in /etc/yum.conf)
yum install 'apr-devel' 'apr-util-devel' 'autoconf' 'db4-devel' 'docbook-style-xsl' 'expat-devel' 'gettext' 'libtool' 'neon-devel' 'openssl-devel' 'python26' 'python26-devel' 'texinfo' 'which' 'httpd-devel' 'perl' 'perl(ExtUtils::MakeMaker)' 'java-devel' 'ruby-devel' 'ruby'

mkdir subversion ; cd subversion
rpm2cpio subversion-1.6.15-0.1.rf.src.rpm  | cpio -ivd
# copy the patch from my earlier mail here
patch -p1 < svn-py26.patch
rpmbuild -bb --define="_sourcedir $PWD" --define="_specdir $PWD" --define="_rpmdir $PWD" --define="_rpmfilename %%{NAME}-%%{VERSION}-%%{RELEASE}.%%{ARCH}.rpm" subversion.spec

- Thomas


2013/2/26 st0ne_c0ld <nativep...@gmail.com>

Dmitry V.

unread,
Mar 6, 2013, 2:00:58 PM3/6/13
to trac-...@googlegroups.com
Hello Thomas!

I just want to say THANK YOU VERY MUCH! Your solution helped! Svn bindings were compiled and now Trac could use Python 2.6 and subversion.

--
Dmitry


--
You received this message because you are subscribed to the Google Groups "Trac Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to trac-users+...@googlegroups.com.
To post to this group, send email to trac-...@googlegroups.com.
Visit this group at http://groups.google.com/group/trac-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.
 
 



--

--
Дмитрий

Patricio Dorantes

unread,
May 17, 2015, 12:32:15 PM5/17/15
to trac-...@googlegroups.com
Hi, 

I wanted to thank you guys you helped me a lot in making trough too. Below I attach my whole recipe for installing Trac 1.0.5 on CentOS 5 




sudo yum update -y
sudo yum
-y install epel-release
sudo yum install
-y gcc gcc-c++ python26 rpm-build redhat-rpm-config yum-utils mod_wsgi.x86_64 python26-devel autoconf libtool texinfo swig apr-devel apr-util-devel neon-devel httpd-devel java-devel-gcj ruby-devel ruby

wget
http://pypi.python.org/packages/2.6/s/setuptools/setuptools-0.6c9-py2.6.egg
sudo sh setuptools
-0.6c9-py2.6.egg


for package in pygments docutils textile pygments ConfigObj 'Trac==1.0.5'; do
 sudo easy_install
-2.6 $package
done;


sudo sed
-i /etc/yum.repos.d/CentOS-Sources.repo -e 's/enabled=0/enabled=1/'
yumdownloader
--source subversion
sudo sed
-i /etc/yum.repos.d/CentOS-Sources.repo -e 's/enabled=1/enabled=0/'
mkdir
-p ~/rpmbuild/{BUILD,RPMS,SOURCES,SPECS,SRPMS}
echo
'%_topdir %(echo $HOME)/rpmbuild' > ~/.rpmmacros
rpm -i subversion-1.6.11-12.el5_10.src.rpm
patch rpmbuild/
SPECS/subversion.spec < subversion-1.6.1-12.spec.patch
patching file rpmbuild
/SPECS/subversion.spec
cd rpmbuild
/SPECS/
rpmbuild
-ba subversion.spec
cd
sudo yum install
-y --nogpgcheck rpmbuild/RPMS/x86_64/subversion-1.6.11-12.1.x86_64.rpm rpmbuild/RPMS/x86_64/mod_dav_svn-1.6.11-12.1.x86_64.rpm
# Test

sudo mkdir
-p /var/svn-test/svn
sudo svnadmin create
/var/svn-test/svn/test1
sudo trac
-admin /var/svn-test/trac-test initenv
sudo echo
"[components]
tracopt.versioncontrol.svn.* = enabled"
>> /var/svn-test/trac-test/conf/trac.ini
sudo trac
-admin /var/svn-test/trac-test repository add test1 /var/svn-test/svn/test1 svn


subversion-1.6.1-12.spec.patch
Reply all
Reply to author
Forward
0 new messages