| 1 |
arfrever |
1.3 |
# Copyright 1999-2010 Gentoo Foundation
|
| 2 |
griffon26 |
1.1 |
# Distributed under the terms of the GNU General Public License v2
|
| 3 |
arfrever |
1.3 |
# $Header: /var/cvsroot/gentoo-x86/net-im/pyicq-t/pyicq-t-0.8.1.5.ebuild,v 1.2 2009/10/03 17:30:43 maekke Exp $
|
| 4 |
griffon26 |
1.1 |
|
| 5 |
|
|
NEED_PYTHON=2.3
|
| 6 |
|
|
|
| 7 |
arfrever |
1.3 |
inherit eutils python
|
| 8 |
griffon26 |
1.1 |
|
| 9 |
|
|
MY_P="${P/pyicq-t/pyicqt}"
|
| 10 |
|
|
|
| 11 |
|
|
DESCRIPTION="Python based jabber transport for ICQ"
|
| 12 |
|
|
HOMEPAGE="http://code.google.com/p/pyicqt/"
|
| 13 |
|
|
SRC_URI="http://pyicqt.googlecode.com/files/${MY_P}.tar.gz"
|
| 14 |
|
|
S="${WORKDIR}/${MY_P}"
|
| 15 |
|
|
|
| 16 |
|
|
LICENSE="GPL-2"
|
| 17 |
|
|
SLOT="0"
|
| 18 |
maekke |
1.2 |
KEYWORDS="amd64 x86"
|
| 19 |
griffon26 |
1.1 |
IUSE="webinterface"
|
| 20 |
|
|
|
| 21 |
|
|
DEPEND="net-im/jabber-base"
|
| 22 |
|
|
RDEPEND="${DEPEND}
|
| 23 |
|
|
>=dev-python/twisted-2.2.0
|
| 24 |
|
|
>=dev-python/twisted-words-0.1.0
|
| 25 |
|
|
>=dev-python/twisted-web-0.5.0
|
| 26 |
|
|
webinterface? ( >=dev-python/nevow-0.4.1 )
|
| 27 |
|
|
>=dev-python/imaging-1.1"
|
| 28 |
|
|
|
| 29 |
|
|
src_install() {
|
| 30 |
|
|
local inspath
|
| 31 |
|
|
|
| 32 |
arfrever |
1.3 |
inspath=$(python_get_sitedir)/${PN}
|
| 33 |
griffon26 |
1.1 |
insinto ${inspath}
|
| 34 |
|
|
doins -r data src tools
|
| 35 |
|
|
newins PyICQt.py ${PN}.py
|
| 36 |
|
|
|
| 37 |
|
|
insinto /etc/jabber
|
| 38 |
|
|
newins config_example.xml ${PN}.xml
|
| 39 |
|
|
fperms 600 /etc/jabber/${PN}.xml
|
| 40 |
|
|
fowners jabber:jabber /etc/jabber/${PN}.xml
|
| 41 |
|
|
dosed \
|
| 42 |
|
|
"s:<spooldir>[^\<]*</spooldir>:<spooldir>/var/spool/jabber</spooldir>:" \
|
| 43 |
|
|
/etc/jabber/${PN}.xml
|
| 44 |
|
|
dosed \
|
| 45 |
|
|
"s:<pid>[^\<]*</pid>:<pid>/var/run/jabber/${PN}.pid</pid>:" \
|
| 46 |
|
|
/etc/jabber/${PN}.xml
|
| 47 |
|
|
|
| 48 |
|
|
newinitd "${FILESDIR}/${PN}-0.8-initd" ${PN}
|
| 49 |
|
|
dosed "s:INSPATH:${inspath}:" /etc/init.d/${PN}
|
| 50 |
|
|
}
|
| 51 |
|
|
|
| 52 |
|
|
pkg_postinst() {
|
| 53 |
arfrever |
1.3 |
python_mod_optimize $(python_get_sitedir)/${PN}
|
| 54 |
griffon26 |
1.1 |
|
| 55 |
|
|
elog "A sample configuration file has been installed in /etc/jabber/${PN}.xml."
|
| 56 |
|
|
elog "Please edit it and the configuration of your Jabber server to match."
|
| 57 |
|
|
|
| 58 |
|
|
ewarn "If you are storing user accounts in MySQL and are upgrading from a "
|
| 59 |
|
|
ewarn "version older than 0.8.1, then you will need to run the following "
|
| 60 |
|
|
ewarn "command to create some new tables:"
|
| 61 |
arfrever |
1.3 |
ewarn " mysql -u user_name -p pyicqt < $(python_get_sitedir)/${PN}/tools/db-setup.mysql"
|
| 62 |
griffon26 |
1.1 |
|
| 63 |
|
|
elog "These instructions along with a list of new config variables are "
|
| 64 |
|
|
elog "available at: http://code.google.com/p/pyicqt/wiki/Upgrade"
|
| 65 |
|
|
}
|
| 66 |
|
|
|
| 67 |
|
|
pkg_postrm() {
|
| 68 |
arfrever |
1.3 |
python_mod_cleanup $(python_get_sitedir)/${PN}
|
| 69 |
griffon26 |
1.1 |
}
|