From 62c253947563a7652a396ea3ddf84d2bee089135 Mon Sep 17 00:00:00 2001 From: Jack Date: Sun, 16 Oct 2016 02:49:19 -0400 Subject: [PATCH] include jsonschema.schemas files --- setup.py | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/setup.py b/setup.py index b35efc968..353200305 100644 --- a/setup.py +++ b/setup.py @@ -2,6 +2,7 @@ import sys import os +import site from lbrynet import __version__ LINUX = 1 @@ -134,6 +135,10 @@ elif platform == WINDOWS: # Allow virtualenv to find distutils of base python installation distutils_path = os.path.join(os.path.dirname(opcode.__file__), 'distutils') + schemas = os.path.join(site.getsitepackages()[1], "jsonschema", "schemas") + onlyfiles = [f for f in os.listdir(schemas) if os.path.isfile(os.path.join(schemas, f))] + zipincludes = [(os.path.join(schemas, f), os.path.join("jsonschema", "schemas", f)) for f in onlyfiles] + def find_data_file(filename): if getattr(sys, 'frozen', False): # The application is frozen @@ -292,7 +297,8 @@ elif platform == WINDOWS: (os.path.join(wordlist_path, 'portuguese.txt'), os.path.join('wordlist', 'portuguese.txt')), (os.path.join(wordlist_path, 'spanish.txt'), os.path.join('wordlist', 'spanish.txt')) ], - 'namespace_packages': ['zope', 'google']} + 'namespace_packages': ['zope', 'google'], + "zip_includes": zipincludes} tray_app = Executable( script=os.path.join(app_dir, 'LBRYWin32App.py'),