Chapter 13. Libraries

Table of Contents
Interfaces for libc
Data Definitions for libc
Interfaces Definitions for libc
Interfaces for libm
Data Definitions for libm
Interfaces for libpthread
Data Definitions for libpthread
Interfaces Definitions for libpthread
Interfaces for libgcc_s
Data Definitions for libgcc_s
Interfaces Definitions for libgcc_s
Interfaces for libdl
Data Definitions for libdl
Interfaces Definitions for libdl
Interfaces for libcrypt
Data Definitions for libcrypt
Interfaces for libpam
Data Definitions for libpam
Interfaces Definitions for libpam

An LSB-conforming implementation shall support some base libraries which provide interfaces for accessing the operating system, processor and other hardware in the system.

Interfaces for libc

Table 13-1. libc Definition

Library:libc
SONAME:See archLSB.

The behavior of the interfaces in this library is specified by the following standards.

ISO/IEC 9899: 1999, Programming Languages --C[1]
Large File Support[2]
Linux Standard Base[3]
IEEE Std POSIX.1-1996 [ISO/IEC 9945-1:1996][4]
CAE Specification, February 1997, Networking Services (XNS), Issue 5(ISBN: 1-85912-165-9, C523)[5]
CAE Specification, January 1997, System Interfaces and Headers (XSH),Issue 5 (ISBN: 1-85912-181-0, C606)[6]
The Single UNIX® Specification(SUS) Version 3[7]
System V Interface Definition, Issue 3 (ISBN 0201566524)[8]
System V Interface Definition,Fourth Edition[9]

RPC

Table 13-2. libc - RPC Function Interfaces

authnone_create[9]svc_getreqset[8]xdr_bytes[8]xdr_opaque_auth[8]xdr_union[8]
clnt_create[9]svcerr_auth[8]xdr_callhdr[8]xdr_pointer[8]xdr_vector[8]
clnt_pcreateerror[9]svcerr_decode[8]xdr_callmsg[8]xdr_reference[8]xdr_void[8]
clnt_perrno[9]svcerr_noproc[8]xdr_char[8]xdr_rejected_reply[8]xdr_wrapstring[8]
clnt_perror[9]svcerr_noprog[8]xdr_double[8]xdr_replymsg[8]xdrmem_create[8]
clnt_spcreateerror[9]svcerr_progvers[8]xdr_enum[8]xdr_short[8]xdrrec_create[8]
clnt_sperrno[9]svcerr_systemerr[8]xdr_float[8]xdr_string[8]xdrrec_eof[8]
clnt_sperror[9]svcerr_weakauth[8]xdr_free[8]xdr_u_char[8] 
getdomainname[3]xdr_accepted_reply[8]xdr_int[8]xdr_u_int[3] 
key_decryptsession[8]xdr_array[8]xdr_long[8]xdr_u_long[8] 
setdomainname[3]xdr_bool[8]xdr_opaque[8]xdr_u_short[8] 

System Calls

Table 13-3. libc - System Calls Function Interfaces

__fxstat[3]fchown[6]initgroups[3]read[6]setrlimit64[2]
__getpgid[3]fcntl[3]ioctl[3]readdir[6]setsid[6]
__lxstat[3]fdatasync[6]kill[3]readdir_r[6]setuid[6]
__xmknod[3]flock[3]killpg[6]readlink[6]sleep[6]
__xstat[3]fork[6]lchown[6]readv[6]statfs[3]
access[6]fstatfs[3]link[6]rename[6]statvfs[6]
acct[3]fstatvfs[6]lockf[6]rmdir[6]stime[3]
alarm[6]fsync[6]lseek[6]sbrk[6]symlink[6]
brk[6]ftime[6]mkdir[6]sched_get_priority_max[6]sync[6]
chdir[6]ftruncate[6]mkfifo[6]sched_get_priority_min[6]sysconf[6]
chmod[6]getcontext[6]mlock[6]sched_getparam[6]time[6]
chown[6]getegid[6]mlockall[6]sched_getscheduler[6]times[6]
chroot[6]geteuid[6]mmap[6]sched_rr_get_interval[6]truncate[6]
clock[6]getgid[6]mprotect[6]sched_setparam[6]ulimit[6]
close[6]getgroups[6]msync[6]sched_setscheduler[6]umask[6]
closedir[6]getitimer[6]munlock[6]sched_yield[6]uname[6]
creat[6]getloadavg[3]munlockall[6]select[5]unlink[3]
dup[6]getpagesize[6]munmap[6]setcontext[6]utime[6]
dup2[6]getpgid[6]nanosleep[6]setegid[3]utimes[6]
execl[6]getpgrp[6]nice[3]seteuid[3]vfork[6]
execle[6]getpid[6]open[6]setgid[6]wait[6]
execlp[6]getppid[6]opendir[6]setitimer[6]wait3[3]
execv[6]getpriority[6]pathconf[6]setpgid[6]wait4[3]
execve[6]getrlimit[6]pause[6]setpgrp[6]waitid[3]
execvp[6]getrusage[6]pipe[6]setpriority[6]waitpid[3]
exit[6]getsid[6]poll[6]setregid[6]write[6]
fchdir[6]getuid[6]pread[6]setreuid[6]writev[6]
fchmod[6]getwd[6]pwrite[6]setrlimit[6] 

Table 13-4. libc - System Calls Deprecated Function Interfaces

fstatfs[3]statfs[3]waitid[3]  

Standard I/O

Table 13-5. libc - Standard I/O Function Interfaces

_IO_feof[3]fgetc[6]fseeko[6]putc[6]snprintf[6]
_IO_getc[3]fgetpos[6]fsetpos[6]putc_unlocked[6]sprintf[6]
_IO_putc[3]fgets[6]ftell[6]putchar[6]sscanf[6]
_IO_puts[3]fgetwc_unlocked[6]ftello[6]putchar_unlocked[6]telldir[6]
alphasort[3]fileno[6]fwrite[6]puts[6]tempnam[6]
asprintf[3]flockfile[6]getc[6]putw[6]ungetc[6]
clearerr[6]fopen[6]getc_unlocked[6]remove[6]vasprintf[3]
ctermid[6]fprintf[6]getchar[6]rewind[6]vdprintf[3]
fclose[6]fputc[6]getchar_unlocked[6]rewinddir[6]vfprintf[6]
fdopen[6]fputs[6]gets[3]scanf[6]vprintf[6]
feof[6]fread[6]getw[6]seekdir[6]vsnprintf[6]
ferror[6]freopen[6]pclose[6]setbuf[6]vsprintf[6]
fflush[6]fscanf[6]popen[6]setbuffer[3] 
fflush_unlocked[6]fseek[6]printf[6]setvbuf[6] 

Table 13-6. libc - Standard I/O Deprecated Function Interfaces

alphasort[3]    

Table 13-7. libc - Standard I/O Data Interfaces

stderr[6]stdin[6]stdout[6]  

Signal Handling

Table 13-8. libc - Signal Handling Function Interfaces

__libc_current_sigrtmax[3]sigaddset[6]sighold[6]sigpause[6]sigsuspend[6]
__libc_current_sigrtmin[3]sigaltstack[6]sigignore[6]sigpending[6]sigtimedwait[6]
__sigsetjmp[3]sigandset[3]siginterrupt[6]sigprocmask[6]sigwait[6]
__sysv_signal[3]sigblock[3]sigisemptyset[3]sigqueue[6]sigwaitinfo[6]
bsd_signal[6]sigdelset[6]sigismember[6]sigrelse[6] 
psignal[3]sigemptyset[6]siglongjmp[6]sigreturn[3] 
raise[6]sigfillset[6]signal[6]sigset[6] 
sigaction[6]siggetmask[3]sigorset[3]sigstack[6] 

Table 13-9. libc - Signal Handling Data Interfaces

_sys_siglist[3]    

Localization Functions

Table 13-10. libc - Localization Functions Function Interfaces

__dcgettext[3]catgets[6]dgettext[3]iconv_close[6]nl_langinfo[6]
bind_textdomain_codeset[3]catopen[6]dngettext[3]iconv_open[6]setlocale[6]
bindtextdomain[3]dcgettext[3]gettext[3]localeconv[6]textdomain[3]
catclose[6]dcngettext[3]iconv[6]ngettext[3] 

Table 13-11. libc - Localization Functions Deprecated Function Interfaces

__dcgettext[3]    

Table 13-12. libc - Localization Functions Data Interfaces

_nl_msg_cat_cntr[3]    

Socket Interface

Table 13-13. libc - Socket Interface Function Interfaces

__h_errno_location[3]gethostbyname_r[3]getsockopt[5]send[5]socket[5]
accept[5]gethostid[6]listen[5]sendmsg[5]socketpair[5]
bind[5]gethostname[5]recv[5]sendto[5] 
bindresvport[3]getpeername[5]recvfrom[5]setsockopt[5] 
connect[5]getsockname[5]recvmsg[5]shutdown[5] 

Wide Characters

Table 13-14. libc - Wide Characters Function Interfaces

__wcstod_internal[3]mbsinit[6]vwscanf[1]wcsnlen[3]wcstoumax[1]
__wcstof_internal[3]mbsnrtowcs[3]wcpcpy[3]wcsnrtombs[3]wcstouq[3]
__wcstol_internal[3]mbsrtowcs[6]wcpncpy[3]wcspbrk[1]wcswcs[6]
__wcstold_internal[3]mbstowcs[6]wcrtomb[6]wcsrchr[6]wcswidth[6]
__wcstoul_internal[3]mbtowc[6]wcscasecmp[3]wcsrtombs[6]wcsxfrm[6]
btowc[6]putwc[1]wcscat[6]wcsspn[6]wctob[6]
fgetwc[6]putwchar[1]wcschr[6]wcsstr[6]wctomb[6]
fgetws[1]swprintf[6]wcscmp[6]wcstod[6]wctrans[6]
fputwc[1]swscanf[1]wcscoll[6]wcstof[1]wctype[6]
fputws[1]towctrans[6]wcscpy[6]wcstoimax[1]wcwidth[6]
fwide[1]towlower[1]wcscspn[6]wcstok[6]wmemchr[6]
fwprintf[6]towupper[6]wcsdup[3]wcstol[6]wmemcmp[6]
fwscanf[1]ungetwc[1]wcsftime[1]wcstold[1]wmemcpy[6]
getwc[1]vfwprintf[1]wcslen[6]wcstoll[1]wmemmove[6]
getwchar[6]vfwscanf[1]wcsncasecmp[3]wcstombs[6]wmemset[6]
mblen[6]vswprintf[1]wcsncat[6]wcstoq[3]wprintf[1]
mbrlen[6]vswscanf[1]wcsncmp[6]wcstoul[6]wscanf[1]
mbrtowc[6]vwprintf[1]wcsncpy[6]wcstoull[1] 

String Functions

Table 13-15. libc - String Functions Function Interfaces

__mempcpy[3]bzero[6]strcasestr[3]strncasecmp[6]strtoimax[1]
__rawmemchr[3]ffs[6]strcat[6]strncat[6]strtok[6]
__stpcpy[3]index[6]strchr[6]strncmp[6]strtok_r[3]
__strdup[3]memccpy[6]strcmp[6]strncpy[6]strtold[1]
__strtod_internal[3]memchr[6]strcoll[6]strndup[3]strtoll[1]
__strtof_internal[3]memcmp[6]strcpy[6]strnlen[3]strtoq[3]
__strtok_r[3]memcpy[6]strcspn[6]strpbrk[6]strtoull[1]
__strtol_internal[3]memmove[6]strdup[6]strptime[3]strtoumax[1]
__strtold_internal[3]memrchr[3]strerror[6]strrchr[6]strtouq[3]
__strtoll_internal[3]memset[6]strerror_r[3]strsep[3]strverscmp[3]
__strtoul_internal[3]rindex[6]strfmon[6]strsignal[3]strxfrm[6]
__strtoull_internal[3]stpcpy[3]strfry[3]strspn[6]swab[6]
bcmp[6]stpncpy[3]strftime[6]strstr[6] 
bcopy[6]strcasecmp[6]strlen[6]strtof[1] 

IPC Functions

Table 13-16. libc - IPC Functions Function Interfaces

ftok[6]msgrcv[6]semget[6]shmctl[6] 
msgctl[6]msgsnd[6]semop[6]shmdt[6] 
msgget[6]semctl[6]shmat[6]shmget[6] 

Regular Expressions

Table 13-17. libc - Regular Expressions Function Interfaces

advance[6]re_exec[6]regerror[6]regfree[6] 
re_comp[6]regcomp[6]regexec[6]step[6] 

Table 13-18. libc - Regular Expressions Data Interfaces

loc1[6]loc2[6]locs[6]  

Character Type Functions

Table 13-19. libc - Character Type Functions Function Interfaces

__ctype_get_mb_cur_max[3]isdigit[6]iswalnum[6]iswlower[6]toascii[6]
_tolower[6]isgraph[6]iswalpha[6]iswprint[6]tolower[6]
_toupper[6]islower[6]iswblank[7]iswpunct[6]toupper[6]
isalnum[6]isprint[6]iswcntrl[6]iswspace[6] 
isalpha[6]ispunct[6]iswctype[3]iswupper[6] 
isascii[6]isspace[6]iswdigit[6]iswxdigit[6] 
iscntrl[6]isupper[6]iswgraph[6]isxdigit[6] 

Table 13-20. libc - Character Type Functions Data Interfaces

__ctype_b[3]__ctype_tolower[3]__ctype_toupper[3]  

Time Manipulation

Table 13-21. libc - Time Manipulation Function Interfaces

adjtime[3]asctime_r[6]difftime[6]localtime[6]tzset[6]
adjtimex[3]ctime[6]gmtime[6]localtime_r[6]ualarm[6]
asctime[6]ctime_r[6]gmtime_r[6]mktime[6] 

Table 13-22. libc - Time Manipulation Data Interfaces

__daylight[3]__tzname[3]timezone[6]  
__timezone[3]daylight[6]tzname[6]  

Terminal Interface Functions

Table 13-23. libc - Terminal Interface Functions Function Interfaces

cfgetispeed[6]cfsetispeed[6]tcdrain[6]tcgetattr[6]tcsendbreak[6]
cfgetospeed[6]cfsetospeed[6]tcflow[6]tcgetpgrp[6]tcsetattr[6]
cfmakeraw[3]cfsetspeed[3]tcflush[6]tcgetsid[6]tcsetpgrp[6]

System Database Interface

Table 13-24. libc - System Database Interface Function Interfaces

endgrent[6]getgrgid[6]getprotoent[6]getutent[3]setmntent[3]
endhostent[5]getgrgid_r[6]getpwent[6]getutent_r[3]setnetent[5]
endnetent[5]getgrnam[6]getpwnam[6]getutxent[6]setprotoent[5]
endprotoent[5]getgrnam_r[6]getpwnam_r[3]getutxid[6]setpwent[6]
endpwent[6]gethostbyaddr[5]getpwuid[6]getutxline[6]setservent[5]
endservent[5]gethostbyname[3]getpwuid_r[6]pututxline[6]setutent[3]
endutent[6]getnetbyaddr[5]getservbyname[3]setgrent[6]setutxent[6]
endutxent[6]getprotobyname[6]getservbyport[5]setgroups[3] 
getgrent[6]getprotobynumber[5]getservent[3]sethostent[5] 

Table 13-25. libc - System Database Interface Deprecated Function Interfaces

endhostent[5]sethostent[5]setmntent[3]  

Language Support

Table 13-26. libc - Language Support Function Interfaces

__libc_start_main[3]_obstack_begin[3]_obstack_newchunk[3]obstack_free[3] 

Large File Support

Table 13-27. libc - Large File Support Function Interfaces

__fxstat64[3]fopen64[2]ftello64[2]mkstemp64[2]readdir64[2]
__lxstat64[3]freopen64[2]ftruncate64[2]mmap64[2]statfs64[3]
__xstat64[3]fseeko64[2]ftw64[2]nftw64[2]statvfs64[2]
alphasort64[3]fsetpos64[2]getrlimit64[2]open64[2]tmpfile64[2]
creat64[2]fstatfs64[3]lockf64[2]pread64[2]truncate64[2]
fgetpos64[2]fstatvfs64[2]lseek64[2]pwrite64[2] 

Table 13-28. libc - Large File Support Deprecated Function Interfaces

alphasort64[3]fstatfs64[3]statfs64[3]  

Standard Library

Table 13-29. libc - Standard Library Function Interfaces

_Exit[1]div[6]globfree64[3]longjmp[6]srand[6]
__assert_fail[3]drand48[6]grantpt[6]lrand48[6]srand48[6]
__cxa_atexit[3]ecvt[6]hcreate[6]lsearch[6]srandom[6]
__errno_location[3]erand48[6]hdestroy[6]makecontext[6]strtod[6]
__fpending[3]err[3]hsearch[6]malloc[6]strtol[6]
__getpagesize[3]error[3]htonl[5]memmem[3]strtoul[6]
__isinf[3]errx[3]htons[5]mkstemp[6]swapcontext[6]
__isinff[3]fcvt[6]imaxabs[1]mktemp[6]syslog[6]
__isinfl[3]fmtmsg[6]imaxdiv[1]mrand48[6]system[3]
__isnan[3]fnmatch[6]inet_addr[5]nftw[6]tdelete[6]
__isnanf[3]fpathconf[6]inet_aton[5]nrand48[6]tfind[6]
__isnanl[3]free[6]inet_ntoa[5]ntohl[5]tmpfile[6]
__sysconf[3]freeaddrinfo[7]inet_ntop[7]ntohs[5]tmpnam[6]
_exit[6]ftrylockfile[6]inet_pton[7]openlog[6]tsearch[6]
_longjmp[6]ftw[6]initstate[6]perror[6]ttyname[6]
_setjmp[6]funlockfile[6]insque[6]posix_memalign[4]ttyname_r[6]
a64l[6]gai_strerror[7]isatty[6]ptsname[6]twalk[6]
abort[6]gcvt[6]isblank[7]putenv[6]unlockpt[6]
abs[6]getaddrinfo[7]isinf[1]qsort[6]unsetenv[3]
atexit[6]getcwd[6]isinffrand[6]usleep[6]
atof[6]getdate[6]isinfl[1]rand_r[6]verrx[3]
atoi[6]getenv[6]isnan[1]random[6]vfscanf[1]
atol[6]getlogin[6]isnanf[1]random_r[3]vscanf[1]
atoll[1]getnameinfo[7]isnanl[1]realloc[6]vsscanf[1]
basename[6]getopt[3]jrand48[6]realpath[6]vsyslog[3]
bsearch[6]getopt_long[3]l64a[6]remque[6]warn[3]
calloc[6]getopt_long_only[3]labs[6]seed48[6]warnx[3]
closelog[6]getsubopt[6]lcong48[6]setenv[3]wordexp[6]
confstr[6]gettimeofday[6]ldiv[6]sethostid[3]wordfree[6]
cuserid[6]glob[6]lfind[6]sethostname[3] 
daemon[3]glob64[3]llabs[1]setlogmask[6] 
dirname[6]globfree[6]lldiv[1]setstate[6] 

Table 13-30. libc - Standard Library Data Interfaces

__environ[3]_sys_errlist[3]getdate_err[6]opterr[3]optopt[3]
_environ[3]environ[6]optarg[6]optind[3] 

Notes

[1]

ISO/IEC 9899: 1999, Programming Languages --C

[2]

Large File Support

[3]

Linux Standard Base

[4]

IEEE Std POSIX.1-1996 [ISO/IEC 9945-1:1996]

[5]

CAE Specification, February 1997, Networking Services (XNS), Issue 5(ISBN: 1-85912-165-9, C523)

[6]

CAE Specification, January 1997, System Interfaces and Headers (XSH),Issue 5 (ISBN: 1-85912-181-0, C606)

[7]

The Single UNIX® Specification(SUS) Version 3

[8]

System V Interface Definition, Issue 3 (ISBN 0201566524)

[9]

System V Interface Definition,Fourth Edition