#include "ruby.h"
#include "dln.h"
#include <stdlib.h>
#include <alloca.h>
#include <string.h>
#include <stdio.h>
#include <sys/types.h>
#include <sys/stat.h>
#include <sys/param.h>
#include <unistd.h>
#include <dlfcn.h>
Go to the source code of this file.
Defines | |
| #define | S_ISDIR(m) ((m & S_IFMT) == S_IFDIR) |
| #define | MAXPATHLEN 1024 |
| #define | USE_DLN_DLOPEN |
| #define | FUNCNAME_PATTERN "Init_%s" |
| #define | init_funcname(buf, file) |
| #define | DLN_ERROR() (error = dln_strerror(), strcpy(ALLOCA_N(char, strlen(error) + 1), error)) |
| #define | DLN_DEFINED |
| #define | RTLD_LAZY 1 |
| #define | RTLD_GLOBAL 0 |
Functions | |
| char * | getenv () |
| int | eaccess () |
| int | init_funcname_len (char **buf, const char *file) |
| const char * | dln_strerror () |
| void * | dln_load (char *file) const |
| char * | dln_find_1 () |
| char * | dln_find_exe (char *fname, const char *path) const |
| char * | dln_find_file (char *fname, const char *path) const |
| char * | dln_find_1 (char *fname, char *path, int exe_flag) |
Variables | |
| char | fbuf [MAXPATHLEN] |
|
|
|
|
|
Referenced by dln_load(). |
|
|
Definition at line 105 of file dln.c. Referenced by init_funcname_len(). |
|
|
Value: do {\ int len = init_funcname_len(buf, file);\ char *tmp = ALLOCA_N(char, len+1);\ if (!tmp) {\ free(*buf);\ rb_memerror();\ }\ strcpy(tmp, *buf);\ free(*buf);\ *buf = tmp;\ } while (0) Definition at line 137 of file dln.c. Referenced by dln_load(). |
|
|
Definition at line 65 of file dln.c. Referenced by dln_load(), and rb_file_expand_path(). |
|
|
Referenced by dln_load(). |
|
|
Referenced by dln_load(). |
|
|
|
|
|
|
|
||||||||||||||||
|
Definition at line 1717 of file dln.c. References eaccess(), fbuf, getenv(), NULL, PATH_SEP, S_ISDIR, and strchr(). |
|
|
Referenced by dln_find_exe(), and dln_find_file(). |
|
||||||||||||
|
Definition at line 1653 of file dln.c. References dln_find_1(), getenv(), and PATH_ENV. |
|
||||||||||||
|
Definition at line 1672 of file dln.c. References dln_find_1(). |
|
|
Definition at line 1283 of file dln.c. References DLN_ERROR, dln_load(), dln_strerror(), init_funcname, load(), MAXPATHLEN, NULL, rb_eLoadError, rb_loaderror(), rb_notimplement(), rb_raise(), RTLD_GLOBAL, RTLD_LAZY, strerror(), and strrchr(). Referenced by dln_load(). |
|
|
Definition at line 1169 of file dln.c. References NULL, and strerror(). Referenced by dln_load(). |
|
|
Referenced by dln_find_1(), test_r(), test_w(), and test_x(). |
|
|
||||||||||||
|
Definition at line 110 of file dln.c. References FUNCNAME_PATTERN, snprintf(), and xmalloc. |
|
|
Definition at line 1714 of file dln.c. Referenced by dln_find_1(). |
1.3.5