File tree Expand file tree Collapse file tree 2 files changed +10
-0
lines changed Expand file tree Collapse file tree 2 files changed +10
-0
lines changed Original file line number Diff line number Diff line change @@ -117,6 +117,7 @@ fn main() {
117
117
// Just pass all these through, no need for a "struct" prefix
118
118
"FILE" |
119
119
"fd_set" |
120
+ "Dl_info" |
120
121
"DIR" => ty. to_string ( ) ,
121
122
122
123
// Fixup a few types on windows that don't actually exist.
@@ -229,6 +230,7 @@ fn main() {
229
230
"gettimeofday" if linux || android || freebsd => true ,
230
231
231
232
"dlerror" if android => true , // const-ness is added
233
+ "dladdr" if musl => true , // const-ness only added recently
232
234
233
235
_ => false ,
234
236
}
Original file line number Diff line number Diff line change 76
76
#[ cfg( not( target_os = "android" ) ) ]
77
77
pub ipv6mr_interface: :: c_uint,
78
78
}
79
+
80
+ pub struct Dl_info {
81
+ pub dli_fname: * const :: c_char,
82
+ pub dli_fbase: * mut :: c_void,
83
+ pub dli_sname: * const :: c_char,
84
+ pub dli_saddr: * mut :: c_void,
85
+ }
79
86
}
80
87
81
88
pub const WNOHANG : :: c_int = 1 ;
@@ -432,6 +439,7 @@ extern {
432
439
pub fn dlsym ( handle : * mut :: c_void ,
433
440
symbol : * const :: c_char ) -> * mut :: c_void ;
434
441
pub fn dlclose ( handle : * mut :: c_void ) -> :: c_int ;
442
+ pub fn dladdr ( addr : * const :: c_void , info : * mut Dl_info ) -> :: c_int ;
435
443
}
436
444
437
445
// TODO: get rid of this #[cfg(not(...))]
You can’t perform that action at this time.
0 commit comments