Important: You need to set up your environment as described in Setting up your build environment before building the examples.
Plug-in examples are located in $DEVKIT_LOCATION/devkit/plug-ins/ and standalone application examples are located in $DEVKIT_LOCATION/devkit/applications/. Each individual example is in its own dedicated directory. Change to the example's directory to build it.
For example, the circleNode plug-in example, is located in the circleNode directory. To build it, change directory to circleNode:
> cd $DEVKIT_LOCATION/devkit/plug-ins/circleNode
To build an example, run cmake once to generate a makefile:
> cmake -H. -Bbuild -G "Unix Makefiles"
The cmake command should exit with no errors and create a build directory.
Run cmake again to build the example:
> cmake --build build
The executable or plug-in will be located under the build directory.
Plug-ins have the suffix so. For example, the circleNode plug-in will be called circleNode/build/circleNode.so.
Unlike applications that can be run from the command line, plug-ins must be loaded into Maya.
Important: Do not rebuild a plug-in that is already loaded into Maya. Unload the plug-in before you rebuild it.