From 5b988818b7ad2d6fd7b07438c6d6180d738a7890 Mon Sep 17 00:00:00 2001 From: "Mike A. Trethewey" Date: Wed, 4 Mar 2020 01:00:33 -0800 Subject: [PATCH] Add to analysis --- DungeonRandomizer.spec | 11 +++++++---- Gui.spec | 11 ++++++----- 2 files changed, 13 insertions(+), 9 deletions(-) diff --git a/DungeonRandomizer.spec b/DungeonRandomizer.spec index dff96ef5..4afcc6e8 100644 --- a/DungeonRandomizer.spec +++ b/DungeonRandomizer.spec @@ -1,5 +1,7 @@ # -*- mode: python -*- +import sys + block_cipher = None console = True @@ -21,10 +23,14 @@ def recurse_for_py_files(names_so_far): return returnvalue hiddenimports = [] +binaries = [] + +if sys.platform.find("windows"): + binaries.append("ucrtbase.dll") a = Analysis(['DungeonRandomizer.py'], pathex=[], - binaries=[], + binaries=binaries, datas=[], hiddenimports=hiddenimports, hookspath=[], @@ -35,9 +41,6 @@ a = Analysis(['DungeonRandomizer.py'], cipher=block_cipher, noarchive=False) -if sys.platform.find("windows"): - a.binaries.append("ucrtbase.dll") - # https://stackoverflow.com/questions/17034434/how-to-remove-exclude-modules-and-files-from-pyinstaller excluded_binaries = [ 'VCRUNTIME140.dll', diff --git a/Gui.spec b/Gui.spec index 56404336..b8bba397 100644 --- a/Gui.spec +++ b/Gui.spec @@ -26,10 +26,14 @@ def recurse_for_py_files(names_so_far): return returnvalue hiddenimports = [] +binaries = [] -a = Analysis(['Gui.py'], +if sys.platform.find("windows"): + binaries.append("ucrtbase.dll") + +a = Analysis(['DungeonRandomizer.py'], pathex=[], - binaries=[], + binaries=binaries, datas=[], hiddenimports=hiddenimports, hookspath=[], @@ -40,9 +44,6 @@ a = Analysis(['Gui.py'], cipher=block_cipher, noarchive=False) -if sys.platform.find("windows"): - a.binaries.append("ucrtbase.dll") - # https://stackoverflow.com/questions/17034434/how-to-remove-exclude-modules-and-files-from-pyinstaller excluded_binaries = [ 'VCRUNTIME140.dll',