ghini.desktop is a cross-platform program and it will run on unix machines like GNU/Linux and MacOSX, as well as on Windows.

one-liner for hurried Linux users.

Download and run the installation script. You may read the documentation later.

Ghini is maintained by very few people, who focus on enhancing its functional parts, more than on writing fancy installers. Instead of several native installers we offer a single cross-platform installation procedure. This has a few big advantages which you will learn to appreciate as we go.

The installation is based on running a script.

  • The GNU/Linux script takes care of everything, from dependecies to installation for users in the ghini group.
  • The Windows script needs you to first install a couple things.
  • On MacOSX we use the same script as on GNU/Linux. Since OSX has no default package manager, we install one and we use it before we start the script.

Following our installation procedure, you will end with Ghini running within a Python virtual environment, all Python dependencies installed locally, non conflicting with any other Python program you may have on your system.

Dependencies that don’t fit in a Python virtual environment are: Python, virtualenv, GTK+, and PyGTK. Their installation varies per platform.

If you later choose to remove Ghini, you simply remove the virtual environment, which is a directory, with all of its content.

Installing on GNU/Linux

Open a shell terminal window, and follow the following instructions.

  1. Download the script:

  2. Invoke the script from a terminal window, starting at the directory where you downloaded it, like this:

    bash ./

    The script will produce quite some output, which you can safely ignore.

    global installation

    When almost ready, the installation script will ask you for your password. This lets it create a ghini user group, initialise it to just yourself, make the just created ghini script available to the whole ghini user group.

    If feeling paranoid, you can safely not give your password and interrupt the script there.

    Possibly the main advantage of a global installation is being able to find Ghini in the application menus of your graphic environment.

  3. You can now start ghini by invoking the ghini script:

    1. You use the same ghini script to update ghini to the latest released production patch:

      ~/bin/ghini -u

      This is what you would do when ghini shows you something like this:

    2. Again the same ghini script lets you install the optional database connectors: option -p is for PostgreSQL, option -m is for MySQL/MariaDB, but you can also install both at the same time:

      ~/bin/ghini -pm

      Please beware: you might need solve dependencies. How to do so, depends on which GNU/Linux flavour you are using. Check with your distribution documentation.

    3. You can also use the ghini script to switch to a different production line. At the moment 1.0 is the stable one, but you can select 1.1 if you want to help us with its development:

      ~/bin/ghini -s 1.1

beginner’s note

To run a script, first make sure you note down the name of the directory to which you have downloaded the script, then you open a terminal window and in that window you type bash followed by a space and the complete name of the script including directory name, and hit on the enter key.

technical note

You can study the script to see what steps if runs for you.

In short it will install dependencies which can’t be satisfied in a virtual environment, then it will create a virtual environment named ghide, use git to download the sources to a directory named ~/Local/github/Ghini/ghini.desktop, and connect this git checkout to the ghini-1.0 branch (this you can consider a production line), it then builds ghini, downloading all remaining dependencies in the virtual environment, and finally it creates the ghini startup script.

If you have sudo permissions, it will be placed in /usr/local/bin, otherwise in your ~/bin folder.


Connecting to a database.

Installing on MacOSX

Being MacOSX a unix environment, most things will work the same as on GNU/Linux (sort of).

Last time we tested, some of the dependencies could not be installed on MacOSX 10.5 and we assume similar problems would also show on older OSX versions. Ghini has been successfully tested with 10.7, 10.9 and 10.12.

First of all, you need things which are an integral part of a unix environment, but which are missing in a off-the-shelf mac:

  1. developers tools: xcode. check the wikipedia page for the version supported on your mac.
  2. package manager: homebrew (tigerbrew for older OSX versions).

with the above installed, open a terminal window and run:

brew doctor

make sure you understand the problems it reports, and correct them. pygtk will need xquartz and brew will not solve the dependency automatically. either install xquartz using brew or the way you prefer:

brew install Caskroom/cask/xquartz

then install the remaining dependencies:

brew install git
brew install pygtk  # takes time and installs all dependencies

follow all instructions on how to activate what you have installed.

Mac running OSX 10.12 —Sierra—

On OSX 10.12, brew reports that gettext is already installed, but then it won’t let us find it. A solution is to run the following line:

brew link gettext --force

Before we can run as on GNU/Linux, we still need installing a couple of python packages, globally. Do this:

sudo pip install virtualenv lxml

The rest is just as on a normal unix machine. Read the above GNU/Linux instructions, follow them, enjoy.


Connecting to a database.

Installing on Windows

The current maintainer of ghini.desktop has no interest in learning how to produce Windows installers, so the Windows installation is here reduced to the same installation procedure as on Unix (GNU/Linux and MacOSX).

Please report any trouble. Help with packaging will be very welcome, in particular by other Windows users.

The steps described here instruct you on how to install Git, Gtk, Python, and the python database connectors. With this environment correctly set up, the Ghini installation procedure runs as on GNU/Linux. The concluding steps are again Windows specific.


Ghini has been tested with and is known to work on W-XP, W-7 and W-8. Although it should work fine on other versions Windows it has not been thoroughly tested.


Direct download links are given for all needed components. They have been tested in September 2015, but things change with time. If any of the direct download links stops working, please ring the bell, so we can update the information here.

The installation steps on Windows:

  1. download and install git (comes with a unix-like sh and includes vi) from:

    Direct link to download git

    all default options are fine, except we need git to be executable from the command prompt:

  2. download and install Python 2.x (32bit) from:

    Direct link to download Python

    Ghini has been developed and tested using Python 2.x. It will definitely not run on Python 3.x. If you are interested in helping port to Python 3.x, please contact the Ghini maintainers.

    when installing Python, do put Python in the PATH:

  3. download pygtk from the following source. (this requires 32bit python). be sure you download the “all in one” version:

    Direct link to download PyGTK

    make a complete install, selecting everything:

  4. (Possibly necessary, maybe superfluous) install lxml, you can grab this from:

    Remember you need the 32 bit version, for Python 2.7.

    Direct link to download lxml

    On some systems, lxml was necessary to avoid the following error:

    Building without Cython.
    ERROR: 'xslt-config' is not recognized as an internal or external command,
    operable program or batch file.

    If you skip this step and can confirm you get the error, please inform us.

  5. (optional) download and install a database connector other than sqlite3.

    On Windows, it is NOT easy to install psycopg2 from sources, using pip, so “avoid the gory details” and use a pre-compiled pagkage from:

    Direct link to download psycopg2


    hey, this is Windows, you need to reboot for changes to take effect!

  7. download and run (from \system32\cmd.exe) the batch file:

    right before you hit the enter key to run the script, your screen might look like something like this:


    this will pull the ghini.desktop repository on github to your home directory, under Local\github\Ghini, checkout the ghini-1.0 production line, create a virtual environment and install ghini into it.

    you can also run devinstall.bat passing it as argument the numerical part of the production line you want to follow.

    this is the last installation step that depends, heavily, on a working internet connection.

    the operation can take several minutes to complete, depending on the speed of your internet connection.

  8. the last installation step creates the Ghini group and shortcuts in the Windows Start Menu, for all users. To do so, you need run a script with administrative rights. The script is called devinstall-finalize.bat, it is right in your HOME folder, and has been created at the previous step.

    right-click on it, select run as administrator, confirm you want it to make changes to your computer. These changes are in the Start Menu only: create the Ghini group, place the Ghini shortcut.

  9. download the batch file you will use to stay up-to-date with the production line you chose to follow:

    if you are on a recent Ghini installation, each time you start the program, Ghini will check on the development site and alert you of any newer ghini release within your chosen production line.

    any time you want to update your installation, just start the command prompt and run ghini-update.bat

If you would like to generate and print PDF reports using Ghini’s default report generator then you will need to download and install Apache FOP. After extracting the FOP archive you will need to include the directory you extracted to in your PATH.


Connecting to a database.


  1. any error related to lxml.

    In order to be able to compile lxml, you have to install a C compiler (on GNU/Linux this would be the gcc package) and Cython (a Python specialization, that gets compiled into C code. Note: Cython is not CPython).

    However, It should not be necessary to compile anything, and pip should be able to locate the binary modules in the online libraries.

    For some reason, this is not the case on Windows 8.1.

    Please report any other trouble related to the installation of lxml.

  2. Couldn’t install gdata.

    For some reason the Google’s gdata package lists itself in the Python Package Index but doesn’t work properly with the easy_install command. You can download the latest gdata package from:

    Unzip it and run python installw in the folder you unzip it to.


Connecting to a database.