summaryrefslogtreecommitdiff
path: root/package/fetchmail
diff options
context:
space:
mode:
authorSamuel Martin <s.martin49@gmail.com>2016-06-08 23:06:38 +0200
committerThomas Petazzoni <thomas.petazzoni@free-electrons.com>2016-06-08 23:22:21 +0200
commita890032596aa5e6afbfdbcccc01fcb07c9a4ef8c (patch)
tree8f329faef626cc16b617bf587ae5ef64748a9e25 /package/fetchmail
parent246f6d8380e087937cd660441279798d196738a5 (diff)
package/fetchmail: fix *.pyc compilation with python-3
This change removes the fetchmailconf.py python module when the python interpreter is python-3, because this module is not yet python-3 compliant. Fixes: http://autobuild.buildroot.org/results/700/7009445dd116a1c02db82a351d38db44db8dad16/ ... Signed-off-by: Samuel Martin <s.martin49@gmail.com> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Diffstat (limited to 'package/fetchmail')
-rw-r--r--package/fetchmail/fetchmail.mk10
1 files changed, 10 insertions, 0 deletions
diff --git a/package/fetchmail/fetchmail.mk b/package/fetchmail/fetchmail.mk
index a198dc52e..5cae0e2c4 100644
--- a/package/fetchmail/fetchmail.mk
+++ b/package/fetchmail/fetchmail.mk
@@ -23,4 +23,14 @@ FETCHMAIL_DEPENDENCIES = \
openssl \
$(if $(BR2_NEEDS_GETTEXT_IF_LOCALE),gettext)
+# fetchmailconf.py script is not (yet) python3-compliant.
+# Prevent the pyc-compilation with python-3 from failing by removing this
+# non-critical script.
+ifeq ($(BR2_PACKAGE_PYTHON3),y)
+define FETCHMAIL_REMOVE_FETCHMAILCONF_PY
+ $(RM) -f $(TARGET_DIR)/usr/lib/python$(PYTHON3_VERSION_MAJOR)/site-packages/fetchmailconf.py
+endef
+FETCHMAIL_POST_TARGET_INSTALL_HOOKS += FETCHMAIL_REMOVE_FETCHMAILCONF_PY
+endif
+
$(eval $(autotools-package))