Pack a file on Linux with Pyinstaller-2.0, and run the source code Pyinstaller.py to install:
./pyinstaller-2.0/pyinstaller.py -F main.py
AttributeError: 'NoneType' object has no attribute 'rfind'
I checked it online, someone mentioned the BUG of the previous version of Pyinstaller, so I tried to update the latest version Pyinstaller:
pip install https://github.com/pyinstaller/pyinstaller/tarball/develop
Then run Pyinstaller, problem solved, and you can package it again.