The following program demonstrates the use of the sigaction system call to (almost) emulate the signal system call. (libc's wrapper for signal will also arrange to restart interrupted system calls.) The program is an infinite loop that catches the SIGINT signal.
The complete source code and Makefile is available as a zip file.