diff options
author | Gluzskiy Alexandr <sss123next@list.ru> | 2010-03-26 15:00:27 +0200 |
---|---|---|
committer | Gluzskiy Alexandr <sss123next@list.ru> | 2010-03-26 15:00:27 +0200 |
commit | d379fedd1e998a5b92213adf89ec5f2376ab7198 (patch) | |
tree | b8a179ea3041681b19359035f160edf252391029 /www-apps | |
parent | 8234ae2bfefc148dddbcb5180aab8fec632a6d2d (diff) |
deleted: www-apps/trac/files
new file: www-apps/trac/files/9138-mysql-key-size-r9405.patch
new file: www-apps/trac/files/postinst-en.txt
new file: www-apps/trac/files/postupgrade-en.txt
new file: www-apps/trac/files/tracd.confd
new file: www-apps/trac/files/tracd.initd
new file: www-apps/trac/files/tracd.initd.2
modified: www-apps/trac/trac-9999.ebuild
Diffstat (limited to 'www-apps')
l--------- | www-apps/trac/files | 1 | ||||
-rw-r--r-- | www-apps/trac/files/9138-mysql-key-size-r9405.patch | 107 | ||||
-rw-r--r-- | www-apps/trac/files/postinst-en.txt | 41 | ||||
-rw-r--r-- | www-apps/trac/files/postupgrade-en.txt | 19 | ||||
-rw-r--r-- | www-apps/trac/files/tracd.confd | 13 | ||||
-rwxr-xr-x | www-apps/trac/files/tracd.initd | 26 | ||||
-rwxr-xr-x | www-apps/trac/files/tracd.initd.2 | 27 | ||||
-rw-r--r-- | www-apps/trac/trac-9999.ebuild | 16 |
8 files changed, 244 insertions, 6 deletions
diff --git a/www-apps/trac/files b/www-apps/trac/files deleted file mode 120000 index 133d044..0000000 --- a/www-apps/trac/files +++ /dev/null @@ -1 +0,0 @@ -/usr/portage/www-apps/trac/files
\ No newline at end of file diff --git a/www-apps/trac/files/9138-mysql-key-size-r9405.patch b/www-apps/trac/files/9138-mysql-key-size-r9405.patch new file mode 100644 index 0000000..ab5d468 --- /dev/null +++ b/www-apps/trac/files/9138-mysql-key-size-r9405.patch @@ -0,0 +1,107 @@ +diff --git a/trac/db/mysql_backend.py b/trac/db/mysql_backend.py +--- a/trac/db/mysql_backend.py ++++ b/trac/db/mysql_backend.py +@@ -121,7 +121,9 @@ + name = '`%s`' % c + table_col = filter((lambda x: x.name == c), table.columns) + if len(table_col) == 1 and table_col[0].type.lower() == 'text': +- if name == '`rev`': ++ if table_col[0].key_size is not None: ++ name += '(%d)' % table_col[0].key_size ++ elif name == '`rev`': + name += '(20)' + elif name == '`path`': + name += '(255)' +diff --git a/trac/db/schema.py b/trac/db/schema.py +--- a/trac/db/schema.py ++++ b/trac/db/schema.py +@@ -35,11 +35,12 @@ + class Column(object): + """Declare a table column in a database schema.""" + +- def __init__(self, name, type='text', size=None, unique=False, ++ def __init__(self, name, type='text', size=None, key_size=None, + auto_increment=False): + self.name = name + self.type = type + self.size = size ++ self.key_size = key_size + self.auto_increment = auto_increment + + +diff --git a/trac/db_default.py b/trac/db_default.py +--- a/trac/db_default.py ++++ b/trac/db_default.py +@@ -91,17 +91,17 @@ + Column('value')], + Table('revision', key=('repos', 'rev'))[ + Column('repos', type='int'), +- Column('rev'), ++ Column('rev', key_size=20), + Column('time', type='int64'), + Column('author'), + Column('message'), + Index(['repos', 'time'])], + Table('node_change', key=('repos', 'rev', 'path', 'change_type'))[ + Column('repos', type='int'), +- Column('rev'), +- Column('path'), ++ Column('rev', key_size=20), ++ Column('path', key_size=255), + Column('node_type', size=1), +- Column('change_type', size=1), ++ Column('change_type', size=1, key_size=2), + Column('base_path'), + Column('base_rev'), + Index(['repos', 'rev'])], +diff --git a/trac/upgrades/db23.py b/trac/upgrades/db23.py +--- a/trac/upgrades/db23.py ++++ b/trac/upgrades/db23.py +@@ -15,17 +15,17 @@ + Column('value')], + Table('revision', key=('repos', 'rev'))[ + Column('repos'), +- Column('rev'), ++ Column('rev', key_size=20), + Column('time', type='int'), + Column('author'), + Column('message'), + Index(['repos', 'time'])], + Table('node_change', key=('repos', 'rev', 'path', 'change_type'))[ +- Column('repos'), +- Column('rev'), +- Column('path'), ++ Column('repos', key_size=56), ++ Column('rev', key_size=20), ++ Column('path', key_size=255), + Column('node_type', size=1), +- Column('change_type', size=1), ++ Column('change_type', size=1, key_size=2), + Column('base_path'), + Column('base_rev'), + Index(['repos', 'rev'])]] +diff --git a/trac/upgrades/db24.py b/trac/upgrades/db24.py +--- a/trac/upgrades/db24.py ++++ b/trac/upgrades/db24.py +@@ -24,17 +24,17 @@ + Column('value')], + Table('revision', key=('repos', 'rev'))[ + Column('repos', type='int'), +- Column('rev'), ++ Column('rev', key_size=20), + Column('time', type='int'), + Column('author'), + Column('message'), + Index(['repos', 'time'])], + Table('node_change', key=('repos', 'rev', 'path', 'change_type'))[ + Column('repos', type='int'), +- Column('rev'), +- Column('path'), ++ Column('rev', key_size=20), ++ Column('path', key_size=255), + Column('node_type', size=1), +- Column('change_type', size=1), ++ Column('change_type', size=1, key_size=2), + Column('base_path'), + Column('base_rev'), + Index(['repos', 'rev'])]] diff --git a/www-apps/trac/files/postinst-en.txt b/www-apps/trac/files/postinst-en.txt new file mode 100644 index 0000000..1aa1d51 --- /dev/null +++ b/www-apps/trac/files/postinst-en.txt @@ -0,0 +1,41 @@ +Install Instructions +==================== + +This is brief and generic information about Trac. + +See the releases notes at http://trac.edgewall.org/wiki/TracDev/ReleaseNotes +for the Trac version you have installed to learn about software changes and +possible caveats. + +Web Server +---------- + +Trac installation depends on the web server you are using. + +FastCGI users: see http://trac.edgewall.org/wiki/TracFastCgi + +CGI users: see http://trac.edgewall.org/wiki/TracCgi + +Apache 2 and mod_python users: you have to manually emerge +www-apache/mod_python. See http://trac.edgewall.org/wiki/TracModPython + +You can also use Trac without having to install a web server. See +http://projects.edgewall.com/trac/wiki/TracStandalone to know more. + +Trac relies on the web server for users authentication. Please refer to the +Trac wiki and to your web server documentation to set up authentication. + +Trac environments +----------------- + +To complete the install, create your first Trac environment by running this +command: + + trac-admin /var/lib/trac/<project-name> initenv + +Don't forget to review the configuration file! It is located at +/var/lib/trac/<project-name>/conf/trac.ini. Consult its reference at +http://projects.edgewall.com/trac/wiki/TracIni + +See http://trac.edgewall.org/wiki/TracEnvironment to know more about Trac +environments and how to configure them. diff --git a/www-apps/trac/files/postupgrade-en.txt b/www-apps/trac/files/postupgrade-en.txt new file mode 100644 index 0000000..2fbdc18 --- /dev/null +++ b/www-apps/trac/files/postupgrade-en.txt @@ -0,0 +1,19 @@ +Upgrade Instructions +==================== + +This is brief and generic information about Trac. + +See the releases notes at http://trac.edgewall.org/wiki/TracDev/ReleaseNotes +for the Trac version you have installed to learn about software changes and +possible caveats. + +If you are upgrading from a previous Trac version, please follow the +instructions here: + + http://projects.edgewall.com/trac/wiki/TracUpgrade + +You will need to run trac-admin commands (upgrade, wiki upgrade...) for each +Trac environment you have. + +You might also want to check for new configuration options by comparing trac.ini +file with trac.ini.sample file in the conf/ directory in each Trac environment. diff --git a/www-apps/trac/files/tracd.confd b/www-apps/trac/files/tracd.confd new file mode 100644 index 0000000..2cb9d29 --- /dev/null +++ b/www-apps/trac/files/tracd.confd @@ -0,0 +1,13 @@ +# The commented variables in this file are the defaults that are used +# in the init-script. You don't need to uncomment them except to +# customize them to different values. + +# Port for tracd +#TRACD_PORT="8000" + +# Options for tracd +#TRACD_OPTS="--env-parent-dir /var/lib/trac/" + +# User and group as which to run tracd +#TRACD_USER="tracd" +#TRACD_GROUP="tracd" diff --git a/www-apps/trac/files/tracd.initd b/www-apps/trac/files/tracd.initd new file mode 100755 index 0000000..c63b794 --- /dev/null +++ b/www-apps/trac/files/tracd.initd @@ -0,0 +1,26 @@ +#!/sbin/runscript +# Copyright 1999-2006 Gentoo Foundation +# Distributed under the terms of the GNU General Public License, v2 or later +# $Header: /var/cvsroot/gentoo-x86/www-apps/trac/files/tracd.initd,v 1.3 2008/07/16 21:20:07 pva Exp $ + +depend() { + need net +} + +start() { + ebegin "Starting tracd" + # tracd fails to create pidfile if started as non-root user, thus we are asking + # s-s-d to do that. To have correct pid we avoid -d option of tracd and use + # --background option of s-s-d. + start-stop-daemon --start --chuid ${TRACD_USER:-tracd}:${TRACD_GROUP:-tracd} \ + --pidfile /var/run/tracd.pid --make-pidfile --background \ + --exec /usr/bin/python -- /usr/bin/tracd \ + -p ${TRACD_PORT:-8000} ${TRACD_OPTS:---env-parent-dir /var/lib/trac/} + eend $? +} + +stop() { + ebegin "Stopping tracd" + start-stop-daemon --stop --quiet --pidfile /var/run/tracd.pid + eend $? +} diff --git a/www-apps/trac/files/tracd.initd.2 b/www-apps/trac/files/tracd.initd.2 new file mode 100755 index 0000000..75de909 --- /dev/null +++ b/www-apps/trac/files/tracd.initd.2 @@ -0,0 +1,27 @@ +#!/sbin/runscript +# Copyright 1999-2006 Gentoo Foundation +# Distributed under the terms of the GNU General Public License, v2 or later +# $Header: /var/cvsroot/gentoo-x86/www-apps/trac/files/tracd.initd.2,v 1.1 2008/09/10 07:50:30 wrobel Exp $ + +depend() { + need net +} + +start() { + ebegin "Starting tracd" + # tracd fails to create pidfile if started as non-root user, thus we are asking + # s-s-d to do that. To have correct pid we avoid -d option of tracd and use + # --background option of s-s-d. + start-stop-daemon --start --chuid ${TRACD_USER:-tracd}:${TRACD_GROUP:-tracd} \ + --pidfile /var/run/tracd.pid --make-pidfile --background \ + --env PYTHON_EGG_CACHE="/var/lib/trac/egg-cache" \ + --exec /usr/bin/python -- /usr/bin/tracd \ + -p ${TRACD_PORT:-8000} ${TRACD_OPTS:---env-parent-dir /var/lib/trac/} + eend $? +} + +stop() { + ebegin "Stopping tracd" + start-stop-daemon --stop --quiet --pidfile /var/run/tracd.pid + eend $? +} diff --git a/www-apps/trac/trac-9999.ebuild b/www-apps/trac/trac-9999.ebuild index 6200747..b838aa6 100644 --- a/www-apps/trac/trac-9999.ebuild +++ b/www-apps/trac/trac-9999.ebuild @@ -2,11 +2,12 @@ # Distributed under the terms of the GNU General Public License v2 # $Header: /var/cvsroot/gentoo-x86/www-apps/trac/trac-0.11.2.ebuild,v 1.3 2008/11/16 17:47:23 maekke Exp $ -inherit distutils webapp subversion +EAPI=2 +inherit webapp subversion distutils -MY_PV=${PV/_beta/b} -MY_P=Trac-${MY_PV} -S=${WORKDIR}/${MY_P} +#MY_PV=${PV/_beta/b} +#MY_P=Trac-${MY_PV} +#S=${WORKDIR}/${MY_P} DESCRIPTION="Trac is a minimalistic web-based project management, wiki and bug/issue tracking system." HOMEPAGE="http://trac.edgewall.com/" @@ -25,7 +26,7 @@ fi ESVN_STORE_DIR="${DISTDIR}/svn-src" #ESVN_BOOTSTRAP="./reconf" -S="${WORKDIR}/${P/_/}" +#S="${WORKDIR}/${P/_/}" @@ -103,6 +104,10 @@ built_with_use_die() { die "${package} missing ${func} support" } +src_prepare(){ + epatch ${FILESDIR}/*.patch +} + pkg_setup() { webapp_pkg_setup @@ -138,6 +143,7 @@ src_upack(){ cd ${S} } + src_install() { webapp_src_preinst distutils_src_install |