Windows Environment

From OpenLP
Jump to: navigation, search

Installing Python

The recommended version of Python is version 3.4 for OpenLP 2.4. Python 3.5 is not supported by the current PyQt5 release!

At the time of this writting (~2.4 release) OpenLP is only distribute in a 32-bit build, but it is possible to run OpenLP on a 64-bit setup. The only package unavailable for 64-bit is pyenchant (see this issue for any progress) which is used for spellchecking and is optional. If you chose to do a 64-bit install always get the 64-bit (amd64 or x64) build of the various downloads.

Download and install the Python Windows Installer from Python download page.

Installing PyQt5

The recommended version of PyQt5 is version 5.5.11.

Download the binary package from PyQt5 download page. This includes Qt5.

For Python 3.4 the exe file name looks like PyQt5-5.5.1-gpl-Py3.4-Qt5.5.1-x32.exe.

Installing additional packages

To install a Python package just type command like:

c:\Python34\scripts\pip.exe install PACKAGE_NAME

For OpenLP 2.4+/Python 3.4 run:

pip install sqlalchemy alembic chardet beautifulsoup4 Mako nose mock pyodbc

Optionally install mysql-connector for MySQL support and/or psycopg2 for PostgreSQL support:

pip install
pip install psycopg2

The mysql-connector url was taken from Go to the newest version subpage and copy the link is a different/newer version is needed.

For automating PowerPoint or packaging OpenLP into .exe file, the Python Extensions for Windows (Pywin32) will be required:

 pip install pypiwin32

The following packages are not available for Python 3.4 via pip but are provided by Christoph Gohlke. You need to download and install them one by one. Be sure to get the one that matches your python version and windows version. For example on windows 64-bit and python 3.4 for PyICU you will need to get PyICU‑1.9.2‑cp34‑none‑win_amd64.whl.

Install the downloaded whl files like this:

 pip install FILE_NAME.whl

Trouble Shooting

You may come across the following error:

 error: Unable to find vcvarsall.bat

If you encounter this error, you need to install Visual Studio 2015 from The "Visual Studio Community" software is free to download. (you can just do a 'minimal' install of just the VC++ componets)

Verify Installation

Once you have completed this, check the install is successful by launching python script in a command prompt:

C:\python34\python OPENLP_SRC\scripts\

The output should be similar to the following:

Checking Python version...
  Python >= 3.0 ...          
Checking for modules...
  PyQt5 ...                            OK
  PyQt5.QtCore ...                     OK
  PyQt5.QtGui ...                      OK
  PyQt5.QtWidgets ...                  OK
  PyQt5.QtNetwork ...                  OK
  PyQt5.QtOpenGL ...                   OK
  PyQt5.QtSvg ...                      OK
  PyQt5.QtTest ...                     OK
  PyQt5.QtWebKit ...                   OK
  PyQt5.QtMultimedia ...               OK
  sqlalchemy ...                       OK
  alembic ...                          OK
  sqlite3 ...                          OK
  lxml ...                             OK
  chardet ...                          OK
  enchant ...                          OK
  bs4 ...                              OK
  mako ...                             OK
  uno ...                              FAIL
Checking for optional modules...
  mysql.connector (MySQL support)...   OK
  psycopg2 (PostgreSQL support)...     OK
  nose (testing framework)...          OK
  jenkins (access jenkins api - package name: jenkins-webapi)...  FAIL
Checking for Windows specific modules...
  win32com ...                         OK
  win32ui ...                          OK
  pywintypes ...                       OK
  pyodbc ...                           OK
  icu ...                              OK
Verifying version of modules...
  PyQt5 >= 5.0 ...                     5.5.1
  Qt5 >= 5.0 ...                       5.5.1
  sqlalchemy >= 0.5 ...                1.0.11
  enchant >= 1.6 ...                   1.6.6
Qt5 image formats...
  read: bmp, pbm, pgm, png, ppm, xbm, xpm
  write: bmp, pbm, pgm, png, ppm, xbm, xpm
Enchant (spell checker)...
  available backends: ispell, myspell
  available languages: de_DE, en_AU, en_GB, en_US, fr_FR