cmake HAVE_FUNC_ATTRIBUTE_NORETURN examples

netdata/netdata CMakeLists.txt :678

check_c_source_compiles("
#include <stdlib.h>
void my_exit_function() __attribute__((noreturn));
int main() {
        my_exit_function(); // Call the noreturn function
        return 0;
}
void my_exit_function() {
        exit(1);
}
" HAVE_FUNC_ATTRIBUTE_NORETURN)