Skip to content

Linux Build and Install Guide

Benjamin O edited this page Jan 15, 2022 · 4 revisions

Introduction

This is a guide for how to build qView from source and install it on your Linux computer.

Dependencies

Download qView by clicking the "Source tarball" button on the website or the tar.gz download from the latest release on Github (Not the "source code"). After downloading it, extract it.

To build qView, you will need the following things:

  • basic build tools such as make, gcc, and g++
  • openssl
  • Qt5 5.9 or later
  • Qt SVG addon (optional)
  • Qt Image Formats addon (optional)
  • qmake build tool
  • lrelease build tool for translations

Under Debian-based distros such as Ubuntu, that typically equates to the following packages:

  • build-essential
  • openssl
  • qt5-default
  • qttools5-dev-tools
  • libqt5svg5-dev
  • qt5-image-formats-plugins

sudo apt install build-essential openssl qt5-default libqt5svg5-dev qt5-image-formats-plugins qttools5-dev-tools

Build

Navigate to the folder containing the .pro file and run

qmake && make && sudo make install

If you ever want to uninstall qView, navigate to the same folder and run

qmake && make && sudo make uninstall

Troubleshooting

When uninstalling, I see errors about failing to remove non-empty directories

This is actually perfectly normal, and is caused by the way qmake generates the Makefile. This should be ignored.

I see some errors while building along the lines of "nullptr was not declared", "only available with c++11", and "no member named 'setTabletTracking'".

Your Qt version is older than 5.9, the minimum version for qView.

qmake: command not found

qmake is not in your "PATH" variable. That's okay, we can work around that.

First, try using qmake-qt5, and if that doesn't work, you'll have to find it

Run sudo find / -name 'qmake' to find your qmake binary.

If you can't find anything, then you don't have qmake installed. If you found qmake, it's now the simple matter of using it directly.

/your/qmake/location/qmake && make && sudo make install

Just replace the /your/qmake/location/qmake with the location of your qmake.