Specify UPX directory from the spec file

36 views
Skip to first unread message

Michel Lavoie

unread,
Aug 8, 2020, 5:45:46 AM8/8/20
to PyInstaller
Hi,

Is there a way to specify the UPX directory from the spec file? I run PyInstaller from a Python script with:

PyInstaller.__main__.run(["main.spec", ])

...so I don't think I can use the --upx-dir option (can't see that clearly in the doc). I tried adding the UPX directory to `pathex` thusly:

a = Analysis(['main.py'],
             pathex=[
                 'C:\\Users\\myself\\gits\\myproject\\src',
                 "D:\\upx-3.96-win64",
                 ],
...

...but that didn't work (UPX wasn't found).

Can it be done?

Thanks,

Michel
Reply all
Reply to author
Forward
0 new messages