Working under Linux on a big project taking some time to build, I would like to add a sound at the end of the build. How can I do that with CMake?
My first idea is to add a command like
add_custom_target(DONG ALL COMMAND aplay ${PathDong} &)
but I don't know how to create the dependency on all the targets (to be sure to play it after all). Is there a global target depending on all the targets defined?
Note: I need it at the end of the build, not at the end of installation (that is easy).
Use a script.
The script executes CMake, and after that it plays a sound. There are several solutions for this described in this post.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With