OSDN Git Service

* CreateFile: drd64_libbrownie_searchlib.[ch] (for Search .so Library Exist Path...
[drdeamon64/drdeamon64.git] / include / libbrownie.h
1 /*DrDeAmOn64DrDeAmOn64DrDeAmOn64DrDeAmOn64DrDeAmOn64DrDeAmOn64DrDeAmOn64
2
3                          D r . D e a m o n  6 4
4                         for INTEL64(R), AMD64(R)
5         
6    Copyright(C) 2007-2009 Koine Yuusuke(koinec). All rights reserved.
7
8 Redistribution and use in source and binary forms, with or without
9 modification, are permitted provided that the following conditions are met:
10
11  1. Redistributions of source code must retain the above copyright notice,
12     this list of conditions and the following disclaimer.
13  2. Redistributions in binary form must reproduce the above copyright
14     notice, this list of conditions and the following disclaimer in the
15     documentation and/or other materials provided with the distribution.
16
17 THIS SOFTWARE IS PROVIDED BY Koine Yuusuke(koinec) ``AS IS'' AND ANY
18 EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
19 WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
20 DISCLAIMED. IN NO EVENT SHALL Koine Yuusuke(koinec) OR CONTRIBUTORS BE
21 LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
22 CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
23 SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
24 INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
25 CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
26 ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED
27 OF THE POSSIBILITY OF SUCH DAMAGE.
28
29 DrDeAmOn64DrDeAmOn64DrDeAmOn64DrDeAmOn64DrDeAmOn64DrDeAmOn64DrDeAmOn64*/
30
31 /* File Info -----------------------------------------------------------
32 File: drd64_.h
33 Function: Header 
34 Comment: 
35 ----------------------------------------------------------------------*/
36
37 #ifndef DRD64_HEADER_LIBBROWNIE
38 #define DRD64_HEADER_LIBBROWNIE
39
40 #include<netinet/in.h>
41
42 #include"./drd64_types.h"
43 #include"./drd64_defines.h"
44 #include"./drd64_error.h"
45
46 #ifdef DRD64_HEADER_LIBBROWNIE_MAIN
47         #define LIBBROWNIE_FUNC
48 #else
49         #define LIBBROWNIE_FUNC extern
50 #endif
51
52
53 #define LIBBROWNIE_LDHINTS_MAX          2   
54 #define LIBBROWNIE_LDHINTS_ELF64        0x00
55 #define LIBBROWNIE_LDHINTS_ELF32        0x01
56
57
58 /* drd64_libbrownie_main.c Functions =========================*/
59 LIBBROWNIE_FUNC
60         int LibBrownie_Init( void );
61 LIBBROWNIE_FUNC
62         void LibBrownie_Term( void );
63
64 /* drd64_libbrownie_error.c Functions ========================*/
65 LIBBROWNIE_FUNC
66         int LibBrownie_Error_GetReferenceCount( void );
67 LIBBROWNIE_FUNC
68         int LibBrownie_Error_DebugErrorInfoPrint( int i_id );
69 LIBBROWNIE_FUNC
70         int LibBrownie_Error_DebugAllInfoPrint( void );
71 LIBBROWNIE_FUNC
72         int LibBrownie_Error_SetErrorInfo(
73                         DWord dw_errcode, DWord dw_errlocation, int i_syserrno,
74                         QWord qw_value1, QWord qw_value2, int i_srcline );
75 LIBBROWNIE_FUNC
76         Drd64_ErrorInfo *LibBrownie_Error_GetErrorInfo( int i_history_id );
77
78
79 /* drd64_libbrownie_inetaddr.c Functions =====================*/
80 LIBBROWNIE_FUNC
81 int
82         Drd64_LibBrownie_INetAddr_CmpInAddr(
83                 struct  in_addr *p_dest,
84                 struct  in_addr *p_src );
85
86 LIBBROWNIE_FUNC
87         int
88                 Drd64_LibBrownie_INetAddr_CopyInAddr(
89                         struct  in_addr *p_dest,
90                         struct  in_addr *p_src );
91
92 LIBBROWNIE_FUNC
93         int
94                 Drd64_LibBrownie_INetAddr_SetInAddr_fromFQDN(
95                         struct  in_addr *p_addr,
96                         char    *pstr_hostname );
97
98 LIBBROWNIE_FUNC
99         int
100                 Drd64_LibBrownie_INetAddr_SetInAddr_LocalHost(
101                         struct  in_addr *p_addr );
102
103 /* drd64_libbrownie_ldsohints.c Functions ====================*/
104 #ifdef DRD64_SRC_LIBBROWNIE_LDSOHINTS
105         #define LIBBROWNIE_LDSOHINTS_API
106 #else
107         #define LIBBROWNIE_LDSOHINTS_API        extern
108 #endif
109 LIBBROWNIE_LDSOHINTS_API
110         char *LibBrownie_GetLoadLibraryPath( Byte b_ldbits );
111 LIBBROWNIE_LDSOHINTS_API
112         int LibBrownie_FreeLoadLibraryPath( Byte b_ldbits );
113
114
115 /* drd64_libbrownie_searchlib.c Functions ====================*/
116 #ifdef DRD64_SRC_LIBBROWNIE_SEARCHLIB
117         #define LIBBROWNIE_SEARCHLIB_API
118 #else
119         #define LIBBROWNIE_SEARCHLIB_API        extern
120 #endif
121 LIBBROWNIE_SEARCHLIB_API
122         int LibBrownie_GetLibraryPath(
123                         char *pstr_solibpath, char *pstr_solibname, char *pstr_rpath, char *pstr_ldsohints );
124
125
126 #endif  /* DRD64_HEADER_XXX */
127
128 /* EOF of drd64_.h ----------------------------------- */