summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--net-mail/vmailmgr/ChangeLog9
-rw-r--r--net-mail/vmailmgr/files/vmailmgr-0.97-python.patch52
-rw-r--r--net-mail/vmailmgr/vmailmgr-0.97-r1.ebuild25
3 files changed, 78 insertions, 8 deletions
diff --git a/net-mail/vmailmgr/ChangeLog b/net-mail/vmailmgr/ChangeLog
index 901caa54fe53..ae7ef98fc75f 100644
--- a/net-mail/vmailmgr/ChangeLog
+++ b/net-mail/vmailmgr/ChangeLog
@@ -1,6 +1,11 @@
# ChangeLog for net-mail/vmailmgr
-# Copyright 1999-2010 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/net-mail/vmailmgr/ChangeLog,v 1.32 2010/10/25 08:41:29 ssuominen Exp $
+# Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2
+# $Header: /var/cvsroot/gentoo-x86/net-mail/vmailmgr/ChangeLog,v 1.33 2011/04/09 16:23:33 arfrever Exp $
+
+ 09 Apr 2011; Arfrever Frehtes Taifersar Arahesis <arfrever@gentoo.org>
+ vmailmgr-0.97-r1.ebuild, +files/vmailmgr-0.97-python.patch:
+ Use Python 2, fix detection of Python library path, don't install .pyc and
+ .pyo files in Python site-packages directory (bug #362723).
25 Oct 2010; Samuli Suominen <ssuominen@gentoo.org>
vmailmgr-0.97-r1.ebuild:
diff --git a/net-mail/vmailmgr/files/vmailmgr-0.97-python.patch b/net-mail/vmailmgr/files/vmailmgr-0.97-python.patch
new file mode 100644
index 000000000000..772f6d59cd8a
--- /dev/null
+++ b/net-mail/vmailmgr/files/vmailmgr-0.97-python.patch
@@ -0,0 +1,52 @@
+--- configure.in
++++ configure.in
+@@ -54,7 +54,7 @@
+ AC_PATH_PROG(PYTHON, python)
+ AC_CACHE_CHECK(Python library path, local_cv_python_lib_dir,
+ [[if test -x "$PYTHON"; then
+- local_cv_python_lib_dir=`$PYTHON -c "import sys;print sys.path[1]"`
++ local_cv_python_lib_dir=`$PYTHON -c "import distutils.sysconfig; print(distutils.sysconfig.get_python_lib())"`
+ else
+ local_cv_python_lib_dir=NONE
+ fi]])
+--- python/Makefile.am
++++ python/Makefile.am
+@@ -1,31 +1,13 @@
+ pythonlib_DATA = \
+- __init__.py __init__.pyc __init__.pyo \
+- commands.py commands.pyc commands.pyo \
+- config.py config.pyc config.pyo \
+- constants.py constants.pyc constants.pyo \
+- daemon.py daemon.pyc daemon.pyo \
+- local.py local.pyc local.pyo \
+- types.py types.pyc types.pyo
++ __init__.py \
++ commands.py \
++ config.py \
++ constants.py \
++ daemon.py \
++ local.py \
++ types.py
+ EXTRA_DIST = __init__.py commands.py config.py constants.py daemon.py types.py
+ CLEANFILES = local.py *.pyc *.pyo
+
+ local.py: Makefile
+ echo "sysconfdir = '${sysconfdir}'" >$@
+-
+-__init__.pyc: __init__.py local.py
+-__init__.pyo: __init__.py local.py
+-commands.pyc: commands.py local.py
+-commands.pyo: commands.py local.py
+-config.pyc: config.py local.py
+-config.pyo: config.py local.py
+-constants.pyc: constants.py local.py
+-constants.pyo: constants.py local.py
+-daemon.pyc: daemon.py local.py
+-daemon.pyo: daemon.py local.py
+-types.pyc: types.py local.py
+-types.pyo: types.py local.py
+-
+-.py.pyc:
+- python -c 'import $*' && touch $@
+-.py.pyo:
+- python -O -c 'import $*' && touch $@
diff --git a/net-mail/vmailmgr/vmailmgr-0.97-r1.ebuild b/net-mail/vmailmgr/vmailmgr-0.97-r1.ebuild
index 9e7a874a7a74..e07453ae576c 100644
--- a/net-mail/vmailmgr/vmailmgr-0.97-r1.ebuild
+++ b/net-mail/vmailmgr/vmailmgr-0.97-r1.ebuild
@@ -1,17 +1,18 @@
-# Copyright 1999-2010 Gentoo Foundation
+# Copyright 1999-2011 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/net-mail/vmailmgr/vmailmgr-0.97-r1.ebuild,v 1.2 2010/10/25 08:41:29 ssuominen Exp $
+# $Header: /var/cvsroot/gentoo-x86/net-mail/vmailmgr/vmailmgr-0.97-r1.ebuild,v 1.3 2011/04/09 16:23:33 arfrever Exp $
-EAPI="2"
+EAPI="3"
+PYTHON_DEPEND="2"
-inherit toolchain-funcs eutils autotools
+inherit autotools eutils python toolchain-funcs
DESCRIPTION="virtual domains for qmail"
HOMEPAGE="http://www.vmailmgr.org/"
SRC_URI="http://www.vmailmgr.org/archive/${P}.tar.gz"
-SLOT="0"
LICENSE="GPL-2"
+SLOT="0"
KEYWORDS="amd64 ~ppc sparc x86"
IUSE=""
@@ -20,13 +21,19 @@ RDEPEND=">=sys-apps/ucspi-unix-0.34
virtual/qmail
>=net-mail/qmail-autoresponder-0.95"
+pkg_setup() {
+ python_set_active_version 2
+ python_pkg_setup
+}
+
src_prepare() {
sed -i \
-e 's:vadduser.pod vadduser.pod:vadduser.pod:' \
commands/Makefile.am || die #327431
epatch "${FILESDIR}"/${P}-gentoo.patch \
- "${FILESDIR}"/${P}-strcasestr.patch
+ "${FILESDIR}"/${P}-strcasestr.patch \
+ "${FILESDIR}"/${P}-python.patch
eautoreconf
}
@@ -55,6 +62,8 @@ src_install() {
}
pkg_postinst() {
+ python_mod_optimize vmailmgr
+
ewarn "CAUTION: courier-authlib does not support vmailmgr!"
ewarn "If you want to use vmailmgr in conjuction with courier-imap,"
ewarn "you should use imapfront-auth found in net-mail/mailfront package."
@@ -66,3 +75,7 @@ pkg_postinst() {
elog "To start vmailmgrd you need to link"
elog "/var/lib/supervise/vmailmgrd to /service"
}
+
+pkg_postrm() {
+ python_mod_cleanup vmailmgr
+}