How to build GPlates 2.5.0 in Fedora 40 KDE

With some help over on reddit I managed to build the latest GPlates in Fedora.
Here is how I did it and what the problems were.

Download source file
Go to Download GPlates 2.5 – EarthByte
and download the
gplates_2.5.0_src.tar.bz2
file.

My system
I am running latest Fedora 40 with KDE Plasma 6.1 (Wayland).

Dependencies
My main struggle was finding the correct packages in the fedora repositories. I managed to find them using dnf search, dnf provides and searching at https://packages.fedoraproject.org. Additionally, some redditors were very helpful.

Here is the list of programs and libraries from the DEPS.Linux file.
Read it as follows:
• The package or library name listed in DEPS.Linux
→ What to install using sudo dnf install <name>


• cmake (3.10 or newer)
→ cmake
• g++ (4.8.1 or newer, required to support C++11)
→ gcc-c++
• GL library (the OpenGL shared library)
→ mesa-libGLU
→ mesa-libGLU-devel
• GLEW library (the OpenGL Extension Wrangler Library)
→ glew
→ glew-devel
• Python library (version 2.7 or 3, preferably 3)
→ python3
→ python3-devel
• Boost library headers (version 1.35 or newer)
→ boost
• Qt library (version 5.6 or newer)
→ qt5-qtxmlpatterns-devel
• Geospatial Data Abstraction Library (GDAL) (1.3.2 or newer; GDAL 2 is highly recommended.)
→ gdal
→ gdal-devel
• Computational Geometry Algorithms Library (CGAL) (4.7 or newer; preferably 4.12 or newer for improved CMake support)
→ CGAL-qt5-devel
• PROJ (4.6.0 or newer; preferably 6 or newer)
→ proj
→ proj-devel
• Qwt (6.0.1 or newer; preferably 6.1 or newer)
→ qwt-qt5
→ qwt-qt5-devel
(Yes, it says 6.0.1 or newer, but for some reason it only worked with qt5.)
• zlib
→ zlib


Some packages were already installed.
Most of the packages come with a bunch of other packages.

Build GPlates
Now for the fun part.
Unpack the gplates_2.5.0_src.tar.bz2 file.
Open the file path in the terminal.

For some reason, cmake does not find QWT, eventhough we installed it. So the first thing to enter is:

export QWT_INCLUDE_DIR=/usr/include/qt5

Now run

cmake .

In theory, no error should pop up, because we installed all dependencies.
So you can run

make

now. Note: This takes quite some time. I have quite a beefy machine and it took nearly an hour.

Once it is done, you can run

sudo make install 

just as said in the BUILD.Linux file.

Problems
The only problem I have is, that I bought an NVIDIA GPU and because I wanted to update to KDE Plasma 6.1 as soon as it came out, I am only running on the nouveau driver. Just like in blender, Gplates has an transparent viewport for me. If you are using X11 with proprietary NVIDIA drivers or are so lucky to run a GPU not made by NVIDIA, everything should be fine now!

Let me know, if / how it worked for you!

FYI, here is the thread over on reddit:
https://www.reddit.com/r/Fedora/comments/1dl1t7l/can_anyone_help_me_build_gplates_in_fedora/
(As I am quite new here, I was only allowed to put two links into the main post.)

On the Problem:
As it turns out, the transparent viewport had little to do with the NVIDIA drivers, instead the problem is wayland.

Solution:
Start GPlates with QT_QPA_PLATFORM=xcb gplates.
kluckie13 on reddit shows how this could look like in the launch menu:
https://www.reddit.com/user/kluckie13/comments/1dut0cb/gplates_launcher/