ffi-libc
Description
Useful Ruby FFI bindings for libc
.
Features
- Provides common Structs used in
libc
: - Binds to common functions and global variables in
libc
:errno.h
:sys_errlist
sys_nerr
errno
unistd.h
:brk
sbrk
getpid
getppid
getuid
geteuid
getgid
getegid
stdlib.h
:calloc
malloc
free
realloc
getenv
putenv
unsetenv
clearenv
time.h
:time
sys/time.h
:gettimeofday
settimeofday
sys/mman.h
:mmap
munmap
string.h
:bzero
memset
memcpy
memcmp
memchr
memrchr
strcpy
strncpy
strlen
index
rindex
strchr
strrchr
strstr
strerror
stdio.h
:stdin
stdout
stderr
fopen
fdopen
freopen
fseek
ftell
rewind
fread
fwrite
fgetc
fgets
fputc
fputs
fflush
fclose
clearerr
feof
ferror
fileno
perror
Requirements
- ffi >= 0.6.0, <= 1.1.0
Install
$ sudo gem install ffi-libc
License
Copyright (c) 2010-2011 Hal Brodigan
See LICENSE for license information.