Edgewall Software

Version 9 (modified by anonymous, 18 years ago) ( diff )

Taken from TracOnRedhat with a few modifications.

Required Software

Python-2.3.5.tgz   
pysqlite-1.0.1.tar.gz 
clearsilver-0.10.1.tar.gz                 
sqlite-2.8.16.tar.gz 
db-4.4.16.tar.gz           
SilverCity-0.9.5.tar.gz     
subversion-1.2.3.tar.gz 
httpd-2.0.55.tar.gz         
apr-1.2.2.tar.gz           
swig-1.3.27.tar.gz 
apr-util-1.2.2.tar.gz       
neon-0.25.4.tar.gz         
trac-0.9.tar.gz 


Make sure you have the latest libtool15 and autoconf259 (Install from ports) 

tar -xvzf apr-1.2.2.tar.gz 
cd apr-1.2.2 
./configure --prefix=/usr/local/apr 
make 
su root -c 'make install' 

Install sleepycat database 
tar -xvzf db-4.4.16.tar.gz 
cd db-4.4.16/build_unix 
../dist/configure 
make 
su root -c 'make install' 

tar -xvzf apr-util-1.2.2.tar.gz 
cd apr-util-1.2.2 
export CPPFLAGS="-I/usr/local/BerkeleyDB.4.4/include" 
export LD_LIBRARY_PATH="/usr/local/BerkeleyDB.4.4/lib" 
./configure --with-apr=/usr/local/apr --with-berkeley-db=/usr/local/BerkeleyDB.4.4 
make 
su root -c 'make install' 

cd /usr/ports/textproc/libxml 
make install 

Install python 2.3.5 
pkg_add ftp://ftp.openbsd.org/pub/OpenBSD/3.8/packages/i386/python-2.3.5p2.tgz 

Install gmake-3.8 
pkg_add ftp://ftp.openbsd.org/pub/OpenBSD/3.8/packages/i386/gmake-3.80p1.tgz 

tar -xvzf neon-0.25.4.tar.gz 
mv neon-0.25.4 neon 
cd neon 
./configure --prefix=/usr/local/neon --with-ssl 
make 
su root -c 'make install' 

tar -xvzf httpd-2.0.55.tar.gz 
cd httpd-2.0.55 
./configure --prefix=/usr/local/apache2 --enable-dav --enable-dav-fs 
make 
su root -c 'make install' 

tar -xvzf swig-1.3.27.tar.gz 
cd swig-1.3.27 
./configure --prefix=/usr/local/swig --with-python=/usr/local/bin/python 
make 
su root -c 'make install' 

(note: Had problems with subversion not detecting neon in /usr/local/neon, had 
to take out the option --with-neon=/usr/local/neon in the configure, it then 
detected neon 0.24.7, presumably the neon folder inside the subversion 
folder once untarred.) 

tar -xvzf subversion-1.2.3.tar.gz 
cd subversion-1.2.3 
$ ./configure --disable-mod-activation --with-zlib 
--enable-swig-bindings=python --with-apr=/usr/local/apr/bin/apr-1-config 
--with-apr-util=/usr/local/apr/bin/apu-1-config --with-apxs=/usr/local/apache2/bin/apxs 
--with-berkeley-db --with-swig=/usr/local/swig --with-httpd=../httpd-2.0.55 
gmake 
su root -c 'gmake install' 

vi /usr/local/apr/include/apr-1/apr.h 

Modify this (somewhere in line 384) 
#if defined(PATH_MAX) 
#define APR_PATH_MAX PATH_MAX 
#elif defined(_POSIX_PATH_MAX) 
#define APR_PATH_MAX _POSIX_PATH_MAX 
#elif !defined(PATH_MAX) <<<<<< This will be added 
#define PATH_MAX 1024 <<<<<< This will be added 
#else 
#error no decision has been made on APR_PATH_MAX for your platform 
#endif 

gmake swig-py' 
su root -c 'gmake install-swig-py' 

tar -xvzf sqlite-2.8.16.tar.gz 
./configure 
gmake 
su root -c 'gmake install' 

tar -xvzf SilverCity-0.9.5.tar.gz 
cd SilverCity-0.9.5 
python setup.py build 
su root -c 'python setup.py install' 

tar -xvzf clearsilver-0.10.1.tar.gz 
cd clearsilver-0.9.6 
./configure --with-python=/usr/local/bin/python --with-apache=/usr/local/apache2 
gmake 
vi scripts/document.py, change 1st line #!/bin/env python to #!/usr/local/bin/python 

su root -c 'gmake install' 
cd python 
su root -c 'python setup.py install' 

tar -xvzf pysqlite-1.0.1.tar.gz 
cd pysqlite 
python setup.py build 
su root -c 'python setup.py install' 

tar -xvzf trac-0.9.tar.gz 
cd trac-0.9 
python setup.py build 
su root -c 'python setup.py install' 

Create symbolic link for libsvn library to the python2.3 library: 
cd /usr/local/lib/python2.3/site-packages 
ln -s /usr/local/lib/svn-python svn-python 
ln -s /usr/local/lib/svn-python/svn svn 
ln -s /usr/local/lib/svn-python/libsvn libsvn 

Create the svn project environment: 
svnadmin create --fs-type=fsfs /var/svn 

Create the trac project environment: 
trac-admin /var/svn/repo initenv 

Creating a new Trac environment at /var/svn/repo 

Trac will first ask a few questions about your environment 
in order to initalize and prepare the project database. 

 Please enter the name of your project. 
 This name will be used in page titles and descriptions. 

Project Name [My Project]> 

 Please specify the absolute path to the project Subversion repository. 
 Repository must be local, and trac-admin requires read+write 
 permission to initialize the Trac database. 

Path to repository [/var/svn/test]> /var/svn 

 Please enter location of Trac page templates. 
 Default is the location of the site-wide templates installed with Trac. 

Templates directory [/usr/local/share/trac/templates]> 
Creating and Initializing Project 
 Inserting default data 
 Configuring Project 
  trac.repository_dir 
  trac.templates_dir 
  project.name 
 Installing wiki pages 
 /usr/local/share/trac/wiki-default/CamelCase => CamelCase 
 /usr/local/share/trac/wiki-default/RecentChanges => RecentChanges 
 /usr/local/share/trac/wiki-default/SandBox => SandBox 
 /usr/local/share/trac/wiki-default/TitleIndex => TitleIndex 
 /usr/local/share/trac/wiki-default/TracAccessibility => TracAccessibility 
 /usr/local/share/trac/wiki-default/TracAdmin => TracAdmin 
 /usr/local/share/trac/wiki-default/TracBackup => TracBackup 
 /usr/local/share/trac/wiki-default/TracBrowser => TracBrowser 
 /usr/local/share/trac/wiki-default/TracChangeset => TracChangeset 
 /usr/local/share/trac/wiki-default/TracEnvironment => TracEnvironment 
 /usr/local/share/trac/wiki-default/TracGuide => TracGuide 
 /usr/local/share/trac/wiki-default/TracImport => TracImport 
 /usr/local/share/trac/wiki-default/TracIni => TracIni 
 /usr/local/share/trac/wiki-default/TracInstall => TracInstall 
 /usr/local/share/trac/wiki-default/TracInstallPlatforms => TracInstallPlatforms 
 /usr/local/share/trac/wiki-default/TracLinks => TracLinks 
 /usr/local/share/trac/wiki-default/TracLogging => TracLogging 
 /usr/local/share/trac/wiki-default/TracModPython => TracModPython 
 /usr/local/share/trac/wiki-default/TracMultipleProjects => TracMultipleProjects 
 /usr/local/share/trac/wiki-default/TracNotification => TracNotification 
 /usr/local/share/trac/wiki-default/TracPermissions => TracPermissions 
 /usr/local/share/trac/wiki-default/TracQuery => TracQuery 
 /usr/local/share/trac/wiki-default/TracReports => TracReports 
 /usr/local/share/trac/wiki-default/TracRoadmap => TracRoadmap 
 /usr/local/share/trac/wiki-default/TracRss => TracRss 
 /usr/local/share/trac/wiki-default/TracSearch => TracSearch 
 /usr/local/share/trac/wiki-default/TracStandalone => TracStandalone 
 /usr/local/share/trac/wiki-default/TracSupport => TracSupport 
 /usr/local/share/trac/wiki-default/TracSyntaxColoring => TracSyntaxColoring 
 /usr/local/share/trac/wiki-default/TracTickets => TracTickets 
 /usr/local/share/trac/wiki-default/TracTicketsCustomFields => TracTicketsCustomFields 
 /usr/local/share/trac/wiki-default/TracTimeline => TracTimeline 
 /usr/local/share/trac/wiki-default/TracUnicode => TracUnicode 
 /usr/local/share/trac/wiki-default/TracUpgrade => TracUpgrade 
 /usr/local/share/trac/wiki-default/TracWiki => TracWiki 
 /usr/local/share/trac/wiki-default/WikiFormatting => WikiFormatting 
 /usr/local/share/trac/wiki-default/WikiHtml => WikiHtml 
 /usr/local/share/trac/wiki-default/WikiMacros => WikiMacros 
 /usr/local/share/trac/wiki-default/WikiNewPage => WikiNewPage 
 /usr/local/share/trac/wiki-default/WikiPageNames => WikiPageNames 
 /usr/local/share/trac/wiki-default/WikiProcessors => WikiProcessors 
 /usr/local/share/trac/wiki-default/WikiRestructuredText => WikiRestructuredText 
 /usr/local/share/trac/wiki-default/WikiRestructuredTextLinks => WikiRestructuredTextLinks 
 /usr/local/share/trac/wiki-default/WikiStart => WikiStart 
 Indexing repository 
--------------------------------------------------------------------- 

Project database for 'My Project' created. 

Don't forget, you also need to copy (or symlink) "trac/cgi-bin/trac.cgi" 
to you web server's /cgi-bin/ directory, and then configure the server. 
cp /usr/local/share/trac/cgi-bin/trac.cgi /usr/local/apache2/cgi-bin 

If you're using Apache, this config example snippet might be helpful: 

    Alias /trac "/usr/local/share/trac/htdocs/" 
    <Location "/cgi-bin/trac.cgi"> 
        SetEnv TRAC_ENV "/var/svn/repo" 
    </Location> 
    
chmod -R a+rw /var/svn/repo
Note: See TracWiki for help on using the wiki.