/[gentoo-x86]/www-apps/rt/rt-3.2.1.ebuild
Gentoo

Contents of /www-apps/rt/rt-3.2.1.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.13 - (show annotations) (download)
Sat May 12 04:44:46 2007 UTC (12 years, 11 months ago) by chtekk
Branch: MAIN
CVS Tags: HEAD
Changes since 1.12: +1 -1 lines
FILE REMOVED
Apache 1.X masking (fix ebuilds to not require apache-1*).
(Portage version: 2.1.2.7)

1 # Copyright 1999-2007 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: /var/cvsroot/gentoo-x86/www-apps/rt/rt-3.2.1.ebuild,v 1.12 2007/01/20 14:42:43 mcummings Exp $
4
5 inherit webapp eutils
6
7 IUSE="mysql postgres fastcgi"
8 #IUSE="mysql postgres fastcgi apache2"
9
10 DESCRIPTION="RT is an industrial-grade ticketing system"
11 HOMEPAGE="http://www.bestpractical.com/rt/"
12 SRC_URI="http://www.fsck.com/pub/${PN}/release/${P}.tar.gz
13 ftp://ftp.eu.uu.net/pub/unix/ticketing/${PN}/release/${P}.tar.gz
14 ftp://rhinst.ece.cmu.edu/${PN}/release/${P}.tar.gz"
15
16 KEYWORDS="~x86 ~ppc"
17
18 DEPEND="
19 >=dev-lang/perl-5.8.3
20 >=dev-perl/Params-Validate-0.02
21 dev-perl/Cache-Cache
22 >=dev-perl/Exception-Class-1.14
23 >=dev-perl/HTML-Mason-1.23
24 dev-perl/MLDBM
25 dev-perl/FreezeThaw
26 >=dev-perl/Apache-Session-1.53
27 dev-perl/XML-RSS
28 dev-perl/HTML-Tree
29 dev-perl/HTML-Format
30 dev-perl/libwww-perl
31 >=dev-perl/Apache-DBI-0.92
32 >=dev-perl/DBI-1.37
33 dev-perl/Test-Inline
34 >=dev-perl/class-returnvalue-0.40
35 >=dev-perl/dbix-searchbuilder-1.01
36 dev-perl/text-template
37 dev-perl/HTML-Parser
38 >=dev-perl/HTML-Scrubber-0.08
39 >=dev-perl/log-dispatch-2.0
40 >=dev-perl/locale-maketext-lexicon-0.32
41 dev-perl/locale-maketext-fuzzy
42 >=dev-perl/MIME-tools-5.411a-r2
43 >=dev-perl/MailTools-1.60
44 dev-perl/text-wrapper
45 dev-perl/Time-modules
46 dev-perl/TermReadKey
47 dev-perl/text-autoformat
48 >=dev-perl/Text-Quoted-1.3
49 >=dev-perl/Tree-Simple-1.04
50 dev-perl/Module-Versions-Report
51 dev-perl/regexp-common
52 dev-perl/WWW-Mechanize
53
54 dev-perl/Font-AFM
55 dev-perl/text-autoformat
56 dev-perl/text-reform
57 "
58
59 RDEPEND="
60 ${DEPEND}
61 virtual/mta
62 mysql? ( >=dev-perl/DBD-mysql-2.0416 )
63 postgres? ( dev-perl/DBD-Pg )
64 fastcgi? ( dev-perl/FCGI )
65 !fastcgi? ( =www-misc/libapreq-1* )
66 =net-www/apache-1*
67 "
68 # apache2? ( >=net-www/apache-2 dev-perl/FCGI net-www/mod_fastcgi )
69 # !apache2? ( =net-www/apache-1* =www-misc/libapreq-1* )
70
71 LICENSE="GPL-2"
72
73 pkg_setup() {
74 webapp_pkg_setup
75
76 # if use apache2; then
77 # ewarn "mod_perl2 isn't ready for prime time, fastcgi will be used instead"
78 # ewarn "If you really want mod_perl2, you can edit the ebuild and uncomment a few lines"
79 # ewarn "but if your RT breaks, you get to keep the pieces."
80 # ewarn
81 # fi
82 ewarn "RT needs MySQL with innodb support"
83 ewarn
84 ewarn "If you are upgrading from an existing _RT2_ installation,"
85 ewarn "stop this ebuild (Ctrl-C now), download the upgrade tool,"
86 ewarn "http://bestpractical.com/pub/rt/devel/rt2-to-rt3.tar.gz"
87 ewarn "and follow the included instructions."
88 ewarn
89 enewgroup rt >/dev/null
90 }
91
92 src_unpack() {
93 unpack ${A}
94 cd ${S}
95 sed -e "s|/opt/rt3/bin/rt-mailgate|/usr/bin/rt-mailgate|g" -i README
96 }
97
98 src_compile() {
99 # capture the list of files from configure to patch later on
100 files=$(./configure --prefix=${D}/usr \
101 --with-web-user=apache \
102 --with-web-group=apache | grep creating | cut -d':' -f2 | cut -d' ' -f3)
103 # ./configure doesn't accept locations, so patch these files directly
104 sed -i "s|/usr/etc|${MY_HOSTROOTDIR}/rt-config|
105 s|/usr/man|/usr/share/man|
106 s|/usr/var|/var|
107 s|/var/mason_data|/var/rt/mason_data|
108 s|/var/session_data|/var/rt/session_data|
109 s|/var/log|/var/log/rt|
110 s|/usr/local/html|${MY_HTDOCSDIR}|
111 s|/usr/share/html|${MY_HTDOCSDIR}|
112 s|/usr/local|${MY_HOSTROOTDIR}/rt|
113 " ${files}
114
115 # check for missing deps and ask to report if something is broken
116 /usr/bin/perl ./sbin/rt-test-dependencies --verbose \
117 $(use_with mysql) \
118 $(use_with postgres pg) > ${T}/t
119 if grep -q "MISSING" ${T}/t; then
120 ewarn "Missing Perl dependency!"
121 ewarn
122 cat ${T}/t
123 ewarn
124 ewarn "Please file a bug in the Gentoo Bugzilla with the information above"
125 ewarn "and assign it to rl03@gentoo.org"
126 die "Missing dependencies."
127 fi
128 }
129
130 src_install() {
131 webapp_src_preinst
132
133 dodoc README Changelog
134 rm -f COPYING README Changelog
135
136 make install
137
138 # copy upgrade schemas
139 cd etc
140 cp -R upgrade ${D}/${MY_HOSTROOTDIR}/rt-config
141
142 # delete RT_SiteConfig.pm so we don't accidentally overwrite existing
143 # configuration
144 rm -f ${D}/${MY_HOSTROOTDIR}/rt-config/RT_SiteConfig.pm
145
146 cd ${D}
147 grep -Rl "${D}" * | xargs dosed
148 chmod +r ${D}/${MY_HOSTROOTDIR}/rt-config/RT*
149
150 webapp_postinst_txt en ${FILESDIR}/${PV}/postinstall-en.txt
151 webapp_hook_script ${FILESDIR}/${PV}/reconfig
152 webapp_src_install
153 }

  ViewVC Help
Powered by ViewVC 1.1.20