Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

what happened to syscalls.h?

Tags:

c

I am testing some code examples of the K&R C book and it uses #include "syscalls.h" in one of its programs but the compiler complains about unable to find the file. What should I replace syscalls.h with? Is it deprecated?

like image 958
Mark Avatar asked Sep 11 '11 19:09

Mark


People also ask

Where to find syscalls h?

Symbolic constants for system call numbers can be found in the header file <sys/syscall.

What is Syscalls H?

syscall() is a small library function that invokes the system call whose assembly language interface has the specified number with the specified arguments. Employing syscall() is useful, for example, when invoking a system call that has no wrapper function in the C library.

Which Linux manual section is dedicated to system calls?

Section 2 of the manual describes the Linux system calls. A system call is an entry point into the Linux kernel.


1 Answers

You should probably use unistd.h instead. Check the man page for the call you're trying to make, as it is system dependent and can vary.

like image 125
littleadv Avatar answered Sep 28 '22 11:09

littleadv