Building
DataMorph depends on CMake, so every plugin developer will need it.
Configuration
Configuration is done in the terminal with the following command :
cmake build --preset <config>Note that multiple pre-configurations can be used. Here are the available ones :
- x64-release (le plus conseillé)
- x64-debug
- x86-release
- x86-debug
With that done, CMake-generated files should appear in a new folder called “build”, present in the current working directory of the code.
Compiling
Compiling is done with the following command :
cmake --build build --preset <config>Where <config> is the chosen pre-configuration.
Installing the plugin
Now that the plugin is installed, you can choose to either move necessary files manually or install the plugin in the DataMorph executable’s directory with CMake.
Installing with CMake (recommended)
If DataMorph is already installed, you can specify its location in the CMake command add_datamorph_plugin by specifying the DATAMORPH_DIR argument. If the folder doesn’t exist, or if the executable isn’t found in the folder, then CMake will emit a warning and won’t generate the “install” target.
Make sure to regenerate CMake build files before installing the plugin. You can now use this command :
cmake --build build --target installIf the plugin has been compiled successfully, it will be installed directly into the <DataMorph>/plugins directory and should work as expected.
Manual installation
This step is not recommended and should only be used if there are issues with CMake’s install command. To do this, you will need to copy the following files located in <source>/build/<config>, where <config> is the pre-configuration selected earlier:
- plugin.yml: the file that provides the software with key information such as the name, description, etc.
- <plugin>.dmplug: the file required for the plugin itself to function.
- All resources used, including images, configuration files, or any other assets.
Next, navigate to the location of the DataMorph executable, then open the plugins directory. Once there, create a folder with any name (using the plugin name specified in plugin.yml is recommended), and paste all the previously copied files into it.