You can learn a lot about the system functions that are available and how to use them by looking at the system header files.These reside in /usr/include and /usr/include/sys. If you are getting compile errors from using a system call, for instance, take a look in the corresponding header file to verify that the function’s signature is the same as what’s listed in the man page.
On Linux systems, a lot of the nitty-gritty details of how the system calls work are reflected in header files in the directories /usr/include/bits, /usr/include/asm, and /usr/include/linux. For instance, the numerical values of signals are defined in /usr/include/bits/signum.h.
These header files make good reading for inquiring minds. Don’t include them directly in your programs, though; always use the header files in /usr/include or as mentioned in the man page for the function you’re using.
On Linux systems, a lot of the nitty-gritty details of how the system calls work are reflected in header files in the directories /usr/include/bits, /usr/include/asm, and /usr/include/linux. For instance, the numerical values of signals are defined in /usr/include/bits/signum.h.
These header files make good reading for inquiring minds. Don’t include them directly in your programs, though; always use the header files in /usr/include or as mentioned in the man page for the function you’re using.
No comments:
Post a Comment