4lex4 / scantailor-libs-build

Building scantailor and its dependencies
55 stars 18 forks source link

Building `scantailor-advanced` on Fedora 39 #16

Closed rramphal closed 10 months ago

rramphal commented 10 months ago

Hey everyone, I just thought I'd post this as a reference for anyone trying to build scantailor-advanced on Fedora. It differs from the docs in the README, so it might save you some time.

# install dependencies
sudo dnf install -y \
    zlib gcc gcc-c++ cmake libjpeg-turbo-devel libpng-devel \
    libtiff libtiff-devel boost-test boost-devel \
    qt5-qtbase-devel qt5-qtsvg-devel qt5-qttools qt5-qttools-devel \
    libglvnd-devel libxcb-devel

# installable version
mkdir build; cd build
cmake -G "Unix Makefiles" ..
cmake --build .
make -j $(($(nproc)-1))
sudo make install # to install
sudo make uninstall # to uninstall

# variant: portable version
mkdir build; cd build
cmake -D PORTABLE_VERSION=ON -G "Unix Makefiles" ..
cmake --build .
make -j $(($(nproc)-1))
./scantailor # to run

NOTE: The README says you should run make -j $(nproc), but @sixtyfive mentioned that on most machines, it is better to keep one thread for I/O by running make -j $(($(nproc)-1)) instead.