Specifications

Red Hat Enterprise Linux to Oracle Solaris Porting Guide
23
TABLE 3-1. EQUIVALENT SYSTEM CALLS, ALTERNATIVE SYSTEM CALLS, AND WORKAROUNDS
API SYNOPSIS ON LINUX FOR ORACLE SOLARIS 11
AT_* constants */ #include <unistd.h>
int fchmodat(int dirfd, const char
*pathname, mode_t mode, gid_t group,
int flags);
#include <fcntl.h>.
Requires #include <sys/types.h>.
fcntl #include <unistd.h>
#include <fcntl.h>
int fcntl(int fd, int cmd, ... /* arg
*/ );
Signature on Oracle Solaris is the same.
Requires #include <sys/types.h>.
fork #include <unistd.h>
pid_t fork(void);
Signature on Oracle Solaris is the same.
Requires #include <sys/types.h>.
fstat #include <sys/types.h>
#include <sys/stat.h>
#include <unistd.h>
int fstat(int fd, struct stat *buf);
Signature on Oracle Solaris is the same.
Requires #include <fcntl.h>.
Does not require #include <unistd.h>.
futimesat #define _ATFILE_SOURCE
#include <fcntl.h> /* Definition of
AT_* constants */
int futimesat(int dirfd, const chat
*pathname, const struct timeval
times[2]);
Signature on Oracle Solaris is the same.
Does not require #define _ATFILE_SOURCE and
#include <fcntl.h>.
Requires #include <sys/time.h>.
getdents int getdents(unsigned int fd, struct
linux_dirent *dirp,unsigned int count);
int getdents(int fildes, struct dirent
*buf, size_t nbyte);
Requires
#include <dirent.h>
.
getgroups #include <sys/types.h>
#include <unistd.h>
#include <grp.h>
int getgroups(int size, gid_t list[]);
int getgroups(int gidsetsize, gid_t
*grouplist);
Does not require #include <sys/types.h>.
getpid #include <sys/types.h>
#include <unistd.h> pid_t getpid(void);
Signature on Oracle Solaris is the same.
Does not require #include <sys/types.h>.
getppid #include <sys/types.h>
#include <unistd.h>
pid_t getppid(void);
Signature on Oracle Solaris is the same.
Does not require #include <sys/types.h>.
getrlimit #include <sys/time.h>
#include <sys/resource.h>
int getrlimit(int resource, struct
rlimit *rlim);
Signature on Oracle Solaris is the same.
Does not require #include <sys/time.h>.
ioctl #include <sys/ioctl.h> Signature on Oracle Solaris is the same.