i'm trying to use pyinstaller on Kali Linux to compile a python program but when i run it i have some problem:
root@kali:/usr/bin# ./pyinstaller ~/Desktop/neighbourhood.py
14 INFO: wrote /usr/share/pyinstaller/neighbourhood/neighbourhood.spec
44 INFO: UPX is available.
520 INFO: checking Analysis
520 INFO: building Analysis because out00-Analysis.toc non existent
522 INFO: running Analysis out00-Analysis.toc
575 INFO: Analyzing /usr/share/pyinstaller/support/_pyi_bootstrap.py
1022 INFO: Analyzing /usr/share/pyinstaller/PyInstaller/loader/archive.py
1058 INFO: Analyzing /usr/share/pyinstaller/PyInstaller/loader/carchive.py
1107 INFO: Analyzing /usr/share/pyinstaller/PyInstaller/loader/iu.py
1121 INFO: Analyzing /root/Desktop/neighbourhood.py
2964 INFO: checking Tree
2964 INFO: building because out00-Tree.toc missing or bad
2964 INFO: building Tree out00-Tree.toc
2996 INFO: checking Tree
2996 INFO: building because out01-Tree.toc missing or bad
2996 INFO: building Tree out01-Tree.toc
Traceback (most recent call last):
File "./pyinstaller.py", line 91, in <module>
main()
File "./pyinstaller.py", line 86, in main
run_build(opts, spec_file)
File "./pyinstaller.py", line 50, in run_build
PyInstaller.build.main(spec_file, **opts.__dict__)
File "/usr/share/pyinstaller/PyInstaller/build.py", line 1625, in main
build(specfile, buildpath)
File "/usr/share/pyinstaller/PyInstaller/build.py", line 1582, in build
execfile(spec)
File "/usr/share/pyinstaller/neighbourhood/neighbourhood.spec", line 5, in <module>
hookspath=None)
File "/usr/share/pyinstaller/PyInstaller/build.py", line 389, in __init__
self.__postinit__()
File "/usr/share/pyinstaller/PyInstaller/build.py", line 315, in __postinit__
self.assemble()
File "/usr/share/pyinstaller/PyInstaller/build.py", line 475, in assemble
importTracker.analyze_script(script)
File "/usr/share/pyinstaller/PyInstaller/depend/imptracker.py", line 205, in analyze_script
return self.analyze_r('__main__')
File "/usr/share/pyinstaller/PyInstaller/depend/imptracker.py", line 98, in analyze_r
newnms = self.analyze_one(name, nm, imptyp, level)
File "/usr/share/pyinstaller/PyInstaller/depend/imptracker.py", line 159, in analyze_one
mod = self.doimport(nm, ctx, fqname)
File "/usr/share/pyinstaller/PyInstaller/depend/imptracker.py", line 256, in doimport
hooks = __import__('PyInstaller.hooks', globals(), locals(), [hookmodnm])
TypeError: Item in ``from list'' not a string
I don't know if this is problem but i have pyinstaller in a lot of folders.
root@kali:~# whereis pyinstaller
pyinstaller: /usr/bin/pyinstaller /usr/local/bin/pyinstaller /usr/share/pyinstaller
I follow a tutorial on youtube and it runs this command:
./pyinstaller setup.py
but i can't find setup.py in pyinstaller's folder . If if run pyinstaller with out dot slash i got this:
root@kali:~# pyinstaller No handlers could be found for logger "PyInstaller.utils.misc"
Anyone know how to fix it? Thanks You!