Quick Start¶
RUNNING AND BUILDING¶
Running locally:
If you have
pipenv
, runpipenv install
and thenpython main.py
.If not, you may use
pip
withrequirements.txt
andrequirements-dev.txt
. They are generated from the Pipfile and may not be up-to-date though, so check the commit history to make sure.
Building an Executable with Pyinstaller:¶
Always run
pyinstaller rkviewer.spec
whenrkviewer.spec
is present.If somehow
rkviewer.spec
went missing or you want to regenerate the build specs, runpyinstaller -F --windowed --add-data ext/Iodine.dll;. main.py
on Windows orpyinstaller -F -- windowed --add-data ext/Iodine.dll:. main.py
on Linux/Mac to generate a file namedmain.spec
. Note that if amain.spec
file is already present it will be overwritten.
USING ON DIFFERENT PLATFORMS¶
The python version used is 3.7.7.
Mac Notes:
pyinstaller and wxPython require a python built with
enable-framework
on. Therefore, one should doenv PYTHON_CONFIGURE_OPTS="--enable-framework" pyenv install 3.7.7
and use that Python installation for building.If the text is blurry in the app bundled by
pyinstaller
, one needs to add an entry in the pyinstaller settings as described in https://stackoverflow.com/a/40676321 .
Linux Notes:
To install wxPython on linux, see https://wxpython.org/blog/2017-08-17-builds-for-linux-with-pip/index.html.
requirements-dev.txt
andrequirements.txt
assume the user is on Ubuntu 18.04 for readthedocs. If you have a different distro and have trouble usingrequirements.txt
, just install wxPython manually using the previous link.Related to the last note, if readthedocs start having trouble building wxPython, understand that it might be because readthedocs updated its distro from Ubuntu 18.04. Go to
requirements-dev.txt
and change the line abovewxPython
to look in the appropriate link.