From 6971e08b0d64fcdff8557ca164322a1314833c52 Mon Sep 17 00:00:00 2001 From: Calum Lind Date: Thu, 19 May 2016 17:18:34 +0100 Subject: [PATCH] [#2828] [Packaging] Fix ImportError with setuptools version > 18.8 --- packaging/win32/deluge-bbfreeze.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/packaging/win32/deluge-bbfreeze.py b/packaging/win32/deluge-bbfreeze.py index d3ecaa917..4807e5269 100644 --- a/packaging/win32/deluge-bbfreeze.py +++ b/packaging/win32/deluge-bbfreeze.py @@ -81,6 +81,10 @@ def recipe_gtk_override(mf): return True bbfreeze.recipes.recipe_gtk_and_friends = recipe_gtk_override +# Workaround for "ImportError: The 'packaging' package is required" with setuptools > 18.8. +# (https://github.com/pypa/setuptools/issues/517) +bbfreeze.recipes.recipe_pkg_resources = bbfreeze.recipes.include_whole_package("pkg_resources") + fzr = bbfreeze.Freezer(build_dir, includes=includes, excludes=excludes) fzr.include_py = False fzr.setIcon(os.path.join(os.path.dirname(deluge.common.__file__), "ui", "data", "pixmaps", "deluge.ico"))