Installing Photohoard on your computer¶
Binary installation¶
Most users on Windows and Debian-derived Linux systems (including Ubuntu, Mint, etc.), should be able to install Photohoard using the binary files of the most recent release.
Installation from source¶
Those who wish to use the software on other systems, or simply prefer to compile from source, may follow these instructions.
Prerequisites¶
To get started, you will need these prerequisites:
The Qt libraries (5.15 or later)
A C++ compiler (e.g., GCC or Microsoft Visual Studio)
The CMake build system
The git version control system
The lcms2, exiv2, and opencv libraries
If you are reading this on a Linux system, chances are you can get all of these through your distribution’s package manager. For instance, on Ubuntu:
sudo apt install g++ cmake git libqt5core5a libqt5svg5-dev qttools5-dev
libexiv2-dev liblcms2-dev \
libopencv-imgproc-dev libxcb-randr0-dev libx11-xcb-dev
On Windows you may have to install the software from the websites linked above.
Downloading the sources¶
Download the source for Photohoard from github. Open a terminal of your choice in a location on your computer of your choice and type:
git clone https://github.com/wagenadl/photohoard.git
Of course, if you prefer, there are various graphical frontends for git that you may use instead of the command line.
Compiling the sources¶
After downloading, enter into the downloaded folder:
cd photohoard
Then, let CMake figure out whether it has all prerequisites:
cmake -S . -B build
(but first see the Critical note for Windows users, below, if you are using Windows).
Do not ignore any errors at this stage. However, a warning like
Sphinx not found - not building documentation
may safely ignored, unless you want to have a copy of this documentation on your own computer.
Next, compile the software:
cmake --build build --config Release
(The “–config Release” is only needed on Windows, but is harmless on Linux.)
Critical note for Windows users¶
On Windows, it is particularly important that CMake uses the right versions of Qt and the C++ compiler. I have seen builds fail because different versions were used during different steps of the process. To be safe, it is best to define a few system variables before the first cmake command, by typing:
export CMAKE_PREFIX_PATH=/c/Qt/5.15.2/msvc2019_64/lib/cmake/Qt5
export PATH=/c/Qt/5.15.2/msvc2019_64/bin:$PATH
export VCINSTALLDIR="/c/"
Of course, you may have to adjust those to point to the appropriate location on your own system.
Creating an installation package¶
After building, you could simply type:
cd build
make install
to install the programs in /usr/local/bin (or your operating
system’s equivalent), but it may be more attractive to create an
installation package:
cd build
cpack
On Ubuntu, that creates a .deb; on Windows, a
.exe. The .deb may be installed like:
sudo dpkg -i photohoard_0.5.0-1_amd64.deb
And the .exe may be installed by double-clicking it.
Closing words¶
If you have any trouble installing Photohard, please drop me a line. I’d be sad to lose potential users due to resolvable stumbling blocks.