This question was inspired by that one.
I've understood how to execute utils from C or C++ code. But how can we handle, that the command can't be executed because of some packages that are not installed and what exactly they are?
For example: if I call some command (that is not installed) from terminal, I'll see a message about it and suggestions about packages, where I can find it. How to get it in code to show user, or to call installation, or to do something else?