gwenhywfar
5.7.4
gwenhywfar5
gwenhywfar
binreloc.h
Go to the documentation of this file.
1
/*
2
* BinReloc - a library for creating relocatable executables
3
* Written by: Hongli Lai <h.lai@chello.nl>
4
* http://autopackage.org/
5
*
6
* This source code is public domain. You can relicense this code
7
* under whatever license you want.
8
*
9
* See http://autopackage.org/docs/binreloc/ for
10
* more information and how to use this.
11
*/
12
13
#ifndef __BINRELOC_H__
14
#define __BINRELOC_H__
15
16
#ifdef __cplusplus
17
extern
"C"
{
18
#endif
/* __cplusplus */
19
20
22
typedef
enum
{
24
BR_INIT_ERROR_NOMEM
,
26
BR_INIT_ERROR_OPEN_MAPS
,
28
BR_INIT_ERROR_READ_MAPS
,
30
BR_INIT_ERROR_INVALID_MAPS
,
32
BR_INIT_ERROR_DISABLED
33
}
34
BrInitError
;
35
36
37
#ifndef BINRELOC_RUNNING_DOXYGEN
38
/* Mangle symbol names to avoid symbol collisions with other ELF objects. */
39
#define br_init pkND64590836275372_br_init
40
#define br_init_lib pkND64590836275372_br_init_lib
41
#define br_find_exe pkND64590836275372_br_find_exe
42
#define br_find_exe_dir pkND64590836275372_br_find_exe_dir
43
#define br_find_prefix pkND64590836275372_br_find_prefix
44
#define br_find_bin_dir pkND64590836275372_br_find_bin_dir
45
#define br_find_sbin_dir pkND64590836275372_br_find_sbin_dir
46
#define br_find_data_dir pkND64590836275372_br_find_data_dir
47
#define br_find_locale_dir pkND64590836275372_br_find_locale_dir
48
#define br_find_lib_dir pkND64590836275372_br_find_lib_dir
49
#define br_find_libexec_dir pkND64590836275372_br_find_libexec_dir
50
#define br_find_etc_dir pkND64590836275372_br_find_etc_dir
51
#define br_strcat pkND64590836275372_br_strcat
52
#define br_build_path pkND64590836275372_br_build_path
53
#define br_dirname pkND64590836275372_br_dirname
54
55
56
#endif
57
int
br_init
(
BrInitError
*error);
58
int
br_init_lib
(
BrInitError
*error);
59
60
char
*
br_find_exe
(
const
char
*default_exe);
61
char
*
br_find_exe_dir
(
const
char
*default_dir);
62
char
*
br_find_prefix
(
const
char
*default_prefix);
63
char
*
br_find_bin_dir
(
const
char
*default_bin_dir);
64
char
*
br_find_sbin_dir
(
const
char
*default_sbin_dir);
65
char
*
br_find_data_dir
(
const
char
*default_data_dir);
66
char
*
br_find_locale_dir
(
const
char
*default_locale_dir);
67
char
*
br_find_lib_dir
(
const
char
*default_lib_dir);
68
char
*
br_find_libexec_dir
(
const
char
*default_libexec_dir);
69
char
*
br_find_etc_dir
(
const
char
*default_etc_dir);
70
71
/* Utility functions */
72
char
*
br_strcat
(
const
char
*str1,
const
char
*str2);
73
char
*
br_build_path
(
const
char
*dir,
const
char
*file);
74
char
*
br_dirname
(
const
char
*path);
75
76
77
#ifdef __cplusplus
78
}
79
#endif
/* __cplusplus */
80
81
#endif
/* __BINRELOC_H__ */
br_find_data_dir
#define br_find_data_dir
Definition:
binreloc.h:46
BrInitError
BrInitError
Definition:
binreloc.h:22
br_find_etc_dir
#define br_find_etc_dir
Definition:
binreloc.h:50
br_init
#define br_init
Definition:
binreloc.h:39
br_strcat
#define br_strcat
Definition:
binreloc.h:51
br_find_sbin_dir
#define br_find_sbin_dir
Definition:
binreloc.h:45
br_init_lib
#define br_init_lib
Definition:
binreloc.h:40
br_dirname
#define br_dirname
Definition:
binreloc.h:53
BR_INIT_ERROR_READ_MAPS
@ BR_INIT_ERROR_READ_MAPS
Definition:
binreloc.h:28
br_build_path
#define br_build_path
Definition:
binreloc.h:52
br_find_bin_dir
#define br_find_bin_dir
Definition:
binreloc.h:44
BR_INIT_ERROR_OPEN_MAPS
@ BR_INIT_ERROR_OPEN_MAPS
Definition:
binreloc.h:26
br_find_exe
#define br_find_exe
Definition:
binreloc.h:41
BR_INIT_ERROR_INVALID_MAPS
@ BR_INIT_ERROR_INVALID_MAPS
Definition:
binreloc.h:30
br_find_lib_dir
#define br_find_lib_dir
Definition:
binreloc.h:48
br_find_prefix
#define br_find_prefix
Definition:
binreloc.h:43
BR_INIT_ERROR_DISABLED
@ BR_INIT_ERROR_DISABLED
Definition:
binreloc.h:32
BR_INIT_ERROR_NOMEM
@ BR_INIT_ERROR_NOMEM
Definition:
binreloc.h:24
br_find_exe_dir
#define br_find_exe_dir
Definition:
binreloc.h:42
br_find_libexec_dir
#define br_find_libexec_dir
Definition:
binreloc.h:49
br_find_locale_dir
#define br_find_locale_dir
Definition:
binreloc.h:47
Generated by
1.8.17