Browse Source

Merge pull request #504 from Shulyaka/master

mailman: fixed compilation errors (Issue #498)
lilik-openwrt-22.03
sbyx 10 years ago
parent
commit
4cd6edf5b4
3 changed files with 51 additions and 2 deletions
  1. +4
    -2
      mail/mailman/Makefile
  2. +12
    -0
      mail/mailman/patches/300-targetpython.patch
  3. +35
    -0
      mail/mailman/patches/400-modules.patch

+ 4
- 2
mail/mailman/Makefile View File

@ -40,13 +40,15 @@ endef
CONFIGURE_ARGS += \ CONFIGURE_ARGS += \
--prefix="$(prefix)" \ --prefix="$(prefix)" \
--exec-prefix="$(prefix)" \ --exec-prefix="$(prefix)" \
--with-python="/usr/bin/python" \
--with-username="root" \ --with-username="root" \
--with-groupname="root" \ --with-groupname="root" \
--with-mail-gid="nogroup" \ --with-mail-gid="nogroup" \
--with-cgi-gid="root" \ --with-cgi-gid="root" \
--without-permcheck \ --without-permcheck \
define Build/Compile
endef
define Package/mailman/install define Package/mailman/install
$(INSTALL_DIR) $(1)$(prefix) $(INSTALL_DIR) $(1)$(prefix)
cd $(PKG_BUILD_DIR); $(MAKE) DESTDIR=$(1) install cd $(PKG_BUILD_DIR); $(MAKE) DESTDIR=$(1) install
@ -89,6 +91,7 @@ if [ -z "$${IPKG_INSTROOT}" ]; then
./bin/mmsitepass mailman ./bin/mmsitepass mailman
echo "NOTE: The default site password 'mailman' has been created." echo "NOTE: The default site password 'mailman' has been created."
fi fi
# /etc/init.d/mailman enable
if [ `ps | grep "mailman/bin/qrunner" | grep -cv grep` -gt 0 ] if [ `ps | grep "mailman/bin/qrunner" | grep -cv grep` -gt 0 ]
then then
$(prefix)/bin/mailmanctl -q restart $(prefix)/bin/mailmanctl -q restart
@ -105,7 +108,6 @@ if [ -z "$${IPKG_INSTROOT}" ]; then
echo "Don't forget to setup firewall for accessing this website!" echo "Don't forget to setup firewall for accessing this website!"
echo "To add a mailing list go to http://$$hostname/mailman/create." echo "To add a mailing list go to http://$$hostname/mailman/create."
fi fi
# /etc/init.d/mailman enable
fi fi
endef endef


+ 12
- 0
mail/mailman/patches/300-targetpython.patch View File

@ -0,0 +1,12 @@
diff -Naur mailman-2.1.18-1/configure mailman-2.1.18-1_patched/configure
--- mailman-2.1.18-1/configure 2014-05-06 20:43:56.000000000 +0400
+++ mailman-2.1.18-1_patched/configure 2014-11-04 15:02:32.892666331 +0300
@@ -3927,6 +3927,8 @@
$as_echo "$URLHOST" >&6; }
rm -f conftest.out conftest.py
+PYTHON=/usr/bin/python
+
# Checks for libraries.
for ac_func in strerror setregid syslog

+ 35
- 0
mail/mailman/patches/400-modules.patch View File

@ -0,0 +1,35 @@
diff -Naur mailman-2.1.18-1/Mailman/MailList.py mailman-2.1.18-1_patched/Mailman/MailList.py
--- mailman-2.1.18-1/Mailman/MailList.py 2014-05-06 20:43:56.000000000 +0400
+++ mailman-2.1.18-1_patched/Mailman/MailList.py 2014-11-04 15:57:06.832636147 +0300
@@ -30,7 +30,7 @@
import shutil
import socket
import urllib
-import cPickle
+import pickle as cPickle
from cStringIO import StringIO
from UserDict import UserDict
diff -Naur mailman-2.1.18-1/misc/paths.py.in mailman-2.1.18-1_patched/misc/paths.py.in
--- mailman-2.1.18-1/misc/paths.py.in 2014-05-06 20:43:56.000000000 +0400
+++ mailman-2.1.18-1_patched/misc/paths.py.in 2014-11-04 15:55:49.594941540 +0300
@@ -66,14 +66,14 @@
# In a normal interactive Python environment, the japanese.pth and korean.pth
# files would be imported automatically. But because we inhibit the importing
# of the site module, we need to be explicit about importing these codecs.
-if not jaok:
- import japanese
+#if not jaok:
+# import japanese
# As of KoreanCodecs 2.0.5, you had to do the second import to get the Korean
# codecs installed, however leave the first import in there in case an upgrade
# changes this.
-if not kook:
- import korean
- import korean.aliases
+#if not kook:
+# import korean
+# import korean.aliases
# Arabic and Hebrew (RFC-1556) encoding aliases. (temporary solution)
import encodings.aliases
encodings.aliases.aliases.update({

Loading…
Cancel
Save