2022-10-16 00:08:40 +00:00
|
|
|
#ifndef GSR_LIBRARY_LOADER_H
|
|
|
|
#define GSR_LIBRARY_LOADER_H
|
2022-09-27 23:03:06 +00:00
|
|
|
|
2022-11-30 23:47:30 +00:00
|
|
|
#include <stdbool.h>
|
2022-09-27 23:03:06 +00:00
|
|
|
|
|
|
|
typedef struct {
|
|
|
|
void **func;
|
|
|
|
const char *name;
|
|
|
|
} dlsym_assign;
|
|
|
|
|
2023-04-07 03:31:46 +00:00
|
|
|
void* dlsym_print_fail(void *handle, const char *name, bool required);
|
2022-09-27 23:03:06 +00:00
|
|
|
/* |dlsyms| should be null terminated */
|
2023-04-07 03:31:46 +00:00
|
|
|
bool dlsym_load_list(void *handle, const dlsym_assign *dlsyms);
|
2022-09-27 23:03:06 +00:00
|
|
|
/* |dlsyms| should be null terminated */
|
2023-04-07 03:31:46 +00:00
|
|
|
void dlsym_load_list_optional(void *handle, const dlsym_assign *dlsyms);
|
2022-10-16 00:08:40 +00:00
|
|
|
|
2022-11-30 23:47:30 +00:00
|
|
|
#endif /* GSR_LIBRARY_LOADER_H */
|