Set up a Linux (vcpkg) development environment for Met.3D
This page describes the steps required to set up a development environment for Met.3D under Linux using vcpkg. Contrary to conda, this allows you to use development symbols for dependencies, helping with debugging.
First, install all requirements and clone Met.3D as described in Compile Met.3D from source code: Linux (vcpkg).
Then, install and set up an IDE.
CLion
Download and install CLion from the JetBrains website.
To use CLion with Met.3D, simply open the Met.3D source folder as a project in CLion.
Navigate to Settings → Build, Execution, Deployment. Here we have to setup the CMake profiles. Go to the CMake section.
There will be a default configuration called Debug.
Remove it with the - symbol.
There should be four grayed-out configurations left.
Duplicate the two linux configuration presets and enable the duplicates.
Next, add the VCPKG_ROOT environment variable created earlier to the environment variables of the presets.
This only works on the duplicates, as the presets are un-editable.
Apply the changes and close the dialog.
Now you can configure CMake.
Once that completes, you can select your build and run configuration in the menu bar.
Important
You will not be able to start Met.3D just yet with CLion, as it will not find the Qt plugins.
For that edit your run configuration, and add a new environment variable, QT_PLUGIN_PATH.
Set its value to PATH_TO_BUILD_DEBUG/vcpkg_installed/x64-linux-dynamic/debug/Qt6/plugins;PATH_TO_BUILD_RELEASE/vcpkg_installed/x64-linux-dynamic/Qt6/plugins