/[gentoo-x86]/www-apps/otrs/otrs-2.2.3.ebuild
Gentoo

Contents of /www-apps/otrs/otrs-2.2.3.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.2 - (show annotations) (download)
Fri Oct 31 06:40:42 2008 UTC (10 years ago) by wrobel
Branch: MAIN
CVS Tags: HEAD
Changes since 1.1: +1 -1 lines
FILE REMOVED
Added www-apps/otrs-2.3.3, removed otrs-2.2.2, -2.2.3. (#228607)
(Portage version: 2.1.4.5)

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/otrs/otrs-2.2.3.ebuild,v 1.1 2007/09/18 12:29:04 wrobel Exp $
4
5 inherit webapp eutils depend.apache
6
7 IUSE="mysql postgres fastcgi ldap gd pdf"
8
9 DESCRIPTION="OTRS is an Open source Ticket Request System"
10 HOMEPAGE="http://otrs.org/"
11 SRC_URI="ftp://ftp.otrs.org/pub/${PN}/${P}.tar.bz2"
12
13 KEYWORDS="~amd64 ~ppc ~ppc64 ~x86"
14
15 RDEPEND="
16 ${DEPEND}
17 =dev-lang/perl-5*
18 dev-perl/Date-Pcalc
19 dev-perl/TimeDate
20 dev-perl/Crypt-PasswdMD5
21 dev-perl/DBI
22 virtual/perl-CGI
23 virtual/perl-Digest-MD5
24 dev-perl/libwww-perl
25 dev-perl/IO-stringy
26 virtual/perl-MIME-Base64
27 dev-perl/MIME-tools
28 dev-perl/MailTools
29 dev-perl/Net-DNS
30 virtual/perl-libnet
31 dev-perl/Authen-SASL
32 dev-perl/XML-Parser
33 virtual/mta
34 pdf? ( dev-perl/PDF-API2 )
35 ldap? ( dev-perl/perl-ldap net-nds/openldap )
36 mysql? ( dev-perl/DBD-mysql )
37 postgres? ( dev-perl/DBD-Pg )
38 fastcgi? ( dev-perl/FCGI )
39 apache2? ( =www-apache/libapreq2-2* )
40 gd? ( dev-perl/GD dev-perl/GDTextUtil dev-perl/GDGraph )
41 "
42
43 want_apache
44
45 LICENSE="GPL-2"
46
47 pkg_setup() {
48 webapp_pkg_setup
49 if use apache2; then
50 enewuser otrs -1 -1 /dev/null apache
51 fi
52 }
53
54 src_unpack() {
55 unpack ${A}
56 cp ${S}/Kernel/Config.pm.dist ${S}/Kernel/Config.pm
57
58 # http://bugs.otrs.org/show_bug.cgi?id=1231
59 cd ${S}
60 epatch ${FILESDIR}/dbi_finish.patch
61
62 cd ${S}/Kernel/Config/
63 for foo in *.dist; do cp ${foo} $(basename ${foo} .dist); done
64
65 cd ${S}/scripts
66 rm -rf auto_* redhat* suse*
67
68 if use fastcgi; then
69 epatch ${FILESDIR}/apache2.patch
70 sed -e "s|cgi-bin|fcgi-bin|" -i ${S}/scripts/apache2-httpd.include.conf
71 sed -e "s|index.pl|index.fpl|" -i ${S}/var/httpd/htdocs/index.html
72 fi
73 }
74
75 src_install() {
76 webapp_src_preinst
77 dodir ${MY_HOSTROOTDIR}/${PF}
78
79 # install documentation
80 dodoc CHANGES CREDITS INSTALL README* TODO UPGRADING \
81 doc/otrs-database.dia doc/test-* doc/X-OTRS-Headers.txt \
82 .fetchmailrc.dist .mailfilter.dist .procmailrc.dist
83 dohtml doc/manual/{en,de}/html/*
84
85 # copy main files
86 cp -R .fetchmailrc.dist .mailfilter.dist .procmailrc.dist RELEASE Kernel bin scripts var ${D}/${MY_HOSTROOTDIR}/${PF}
87 mv ${D}/${MY_HOSTROOTDIR}/${PF}/var/httpd/htdocs/* ${D}/${MY_HTDOCSDIR}
88
89 # remove stuff from ${D} that shouldn't be there
90 rm -rf ${D}/${MY_HOSTROOTDIR}/${PF}/var/httpd
91
92 # keep some empty dirs
93 local a
94 local d="article log pics/images pics/stats pics sessions spool tmp"
95 for a in ${d}; do
96 keepdir ${MY_HOSTROOTDIR}/${PF}/var/${a}
97 done
98
99 # helpers
100 webapp_configfile ${MY_HOSTROOTDIR}/${PF}/Kernel/Config.pm
101 webapp_postinst_txt en ${FILESDIR}/postinstall-en-2.txt
102 webapp_hook_script ${FILESDIR}/reconfig-2
103 webapp_src_install
104 }
105
106 pkg_postinst() {
107 ewarn "webapp-config will not be run automatically"
108 ewarn "That messes up Apache configs"
109 ewarn "Don't run webapp-config with -d otrs. Instead, try"
110 ewarn "webapp-config -I -h <host> -d ot ${PN} ${PVR}"
111 ewarn
112 if ! use apache2; then
113 ewarn "You did not activate the USE-flag apache2 which means you"
114 ewarn "will need to create the otrs user yourself. Make this user"
115 ewarn "a member of your webserver group."
116 fi
117 # webapp_pkg_postinst
118 }

  ViewVC Help
Powered by ViewVC 1.1.20