libuv_sys_lite/
functions.rs

1use crate::generate;
2use crate::types::*;
3
4generate! {
5  extern "C" {
6    fn uv_version() -> ::std::os::raw::c_uint;
7    fn uv_version_string() -> *const ::std::os::raw::c_char;
8    fn uv_library_shutdown();
9    fn uv_replace_allocator(
10      malloc_func: uv_malloc_func,
11      realloc_func: uv_realloc_func,
12      calloc_func: uv_calloc_func,
13      free_func: uv_free_func,
14    ) -> ::std::os::raw::c_int;
15    fn uv_default_loop() -> *mut uv_loop_t;
16    fn uv_loop_init(loop_: *mut uv_loop_t) -> ::std::os::raw::c_int;
17    fn uv_loop_close(loop_: *mut uv_loop_t) -> ::std::os::raw::c_int;
18    fn uv_loop_new() -> *mut uv_loop_t;
19    fn uv_loop_delete(arg1: *mut uv_loop_t);
20    fn uv_loop_size() -> usize;
21    fn uv_loop_alive(loop_: *const uv_loop_t) -> ::std::os::raw::c_int;
22    fn uv_loop_fork(loop_: *mut uv_loop_t) -> ::std::os::raw::c_int;
23    fn uv_run(arg1: *mut uv_loop_t, mode: uv_run_mode) -> ::std::os::raw::c_int;
24    fn uv_stop(arg1: *mut uv_loop_t);
25    fn uv_ref(arg1: *mut uv_handle_t);
26    fn uv_unref(arg1: *mut uv_handle_t);
27    fn uv_has_ref(arg1: *const uv_handle_t) -> ::std::os::raw::c_int;
28    fn uv_update_time(arg1: *mut uv_loop_t);
29    fn uv_now(arg1: *const uv_loop_t) -> u64;
30    fn uv_backend_fd(arg1: *const uv_loop_t) -> ::std::os::raw::c_int;
31    fn uv_backend_timeout(arg1: *const uv_loop_t) -> ::std::os::raw::c_int;
32    fn uv_translate_sys_error(sys_errno: ::std::os::raw::c_int) -> ::std::os::raw::c_int;
33    fn uv_strerror(err: ::std::os::raw::c_int) -> *const ::std::os::raw::c_char;
34    fn uv_strerror_r(
35      err: ::std::os::raw::c_int,
36      buf: *mut ::std::os::raw::c_char,
37      buflen: usize,
38    ) -> *mut ::std::os::raw::c_char;
39    fn uv_err_name(err: ::std::os::raw::c_int) -> *const ::std::os::raw::c_char;
40    fn uv_err_name_r(
41      err: ::std::os::raw::c_int,
42      buf: *mut ::std::os::raw::c_char,
43      buflen: usize,
44    ) -> *mut ::std::os::raw::c_char;
45    fn uv_shutdown(
46      req: *mut uv_shutdown_t,
47      handle: *mut uv_stream_t,
48      cb: uv_shutdown_cb,
49    ) -> ::std::os::raw::c_int;
50    fn uv_handle_size(type_: uv_handle_type) -> usize;
51    fn uv_handle_get_type(handle: *const uv_handle_t) -> uv_handle_type;
52    fn uv_handle_type_name(type_: uv_handle_type) -> *const ::std::os::raw::c_char;
53    fn uv_handle_get_data(handle: *const uv_handle_t) -> *mut ::std::os::raw::c_void;
54    fn uv_handle_get_loop(handle: *const uv_handle_t) -> *mut uv_loop_t;
55    fn uv_handle_set_data(handle: *mut uv_handle_t, data: *mut ::std::os::raw::c_void);
56    fn uv_req_size(type_: uv_req_type) -> usize;
57    fn uv_req_get_data(req: *const uv_req_t) -> *mut ::std::os::raw::c_void;
58    fn uv_req_set_data(req: *mut uv_req_t, data: *mut ::std::os::raw::c_void);
59    fn uv_req_get_type(req: *const uv_req_t) -> uv_req_type;
60    fn uv_req_type_name(type_: uv_req_type) -> *const ::std::os::raw::c_char;
61    fn uv_is_active(handle: *const uv_handle_t) -> ::std::os::raw::c_int;
62    fn uv_walk(loop_: *mut uv_loop_t, walk_cb: uv_walk_cb, arg: *mut ::std::os::raw::c_void);
63    fn uv_print_all_handles(loop_: *mut uv_loop_t, stream: *mut FILE);
64    fn uv_print_active_handles(loop_: *mut uv_loop_t, stream: *mut FILE);
65    fn uv_close(handle: *mut uv_handle_t, close_cb: uv_close_cb);
66    fn uv_send_buffer_size(
67      handle: *mut uv_handle_t,
68      value: *mut ::std::os::raw::c_int,
69    ) -> ::std::os::raw::c_int;
70    fn uv_recv_buffer_size(
71      handle: *mut uv_handle_t,
72      value: *mut ::std::os::raw::c_int,
73    ) -> ::std::os::raw::c_int;
74    fn uv_fileno(handle: *const uv_handle_t, fd: *mut uv_os_fd_t) -> ::std::os::raw::c_int;
75    fn uv_buf_init(base: *mut ::std::os::raw::c_char, len: ::std::os::raw::c_uint) -> uv_buf_t;
76    fn uv_pipe(
77      fds: *mut uv_file,
78      read_flags: ::std::os::raw::c_int,
79      write_flags: ::std::os::raw::c_int,
80    ) -> ::std::os::raw::c_int;
81    fn uv_socketpair(
82      type_: ::std::os::raw::c_int,
83      protocol: ::std::os::raw::c_int,
84      socket_vector: *mut uv_os_sock_t,
85      flags0: ::std::os::raw::c_int,
86      flags1: ::std::os::raw::c_int,
87    ) -> ::std::os::raw::c_int;
88    fn uv_stream_get_write_queue_size(stream: *const uv_stream_t) -> usize;
89    fn uv_listen(
90      stream: *mut uv_stream_t,
91      backlog: ::std::os::raw::c_int,
92      cb: uv_connection_cb,
93    ) -> ::std::os::raw::c_int;
94    fn uv_accept(server: *mut uv_stream_t, client: *mut uv_stream_t) -> ::std::os::raw::c_int;
95    fn uv_read_start(
96      arg1: *mut uv_stream_t,
97      alloc_cb: uv_alloc_cb,
98      read_cb: uv_read_cb,
99    ) -> ::std::os::raw::c_int;
100    fn uv_read_stop(arg1: *mut uv_stream_t) -> ::std::os::raw::c_int;
101    fn uv_write(
102      req: *mut uv_write_t,
103      handle: *mut uv_stream_t,
104      bufs: *const uv_buf_t,
105      nbufs: ::std::os::raw::c_uint,
106      cb: uv_write_cb,
107    ) -> ::std::os::raw::c_int;
108    fn uv_write2(
109      req: *mut uv_write_t,
110      handle: *mut uv_stream_t,
111      bufs: *const uv_buf_t,
112      nbufs: ::std::os::raw::c_uint,
113      send_handle: *mut uv_stream_t,
114      cb: uv_write_cb,
115    ) -> ::std::os::raw::c_int;
116    fn uv_try_write(
117      handle: *mut uv_stream_t,
118      bufs: *const uv_buf_t,
119      nbufs: ::std::os::raw::c_uint,
120    ) -> ::std::os::raw::c_int;
121    fn uv_try_write2(
122      handle: *mut uv_stream_t,
123      bufs: *const uv_buf_t,
124      nbufs: ::std::os::raw::c_uint,
125      send_handle: *mut uv_stream_t,
126    ) -> ::std::os::raw::c_int;
127    fn uv_is_readable(handle: *const uv_stream_t) -> ::std::os::raw::c_int;
128    fn uv_is_writable(handle: *const uv_stream_t) -> ::std::os::raw::c_int;
129    fn uv_stream_set_blocking(
130      handle: *mut uv_stream_t,
131      blocking: ::std::os::raw::c_int,
132    ) -> ::std::os::raw::c_int;
133    fn uv_is_closing(handle: *const uv_handle_t) -> ::std::os::raw::c_int;
134    fn uv_tcp_init(arg1: *mut uv_loop_t, handle: *mut uv_tcp_t) -> ::std::os::raw::c_int;
135    fn uv_tcp_init_ex(
136      arg1: *mut uv_loop_t,
137      handle: *mut uv_tcp_t,
138      flags: ::std::os::raw::c_uint,
139    ) -> ::std::os::raw::c_int;
140    fn uv_tcp_open(handle: *mut uv_tcp_t, sock: uv_os_sock_t) -> ::std::os::raw::c_int;
141    fn uv_tcp_nodelay(
142      handle: *mut uv_tcp_t,
143      enable: ::std::os::raw::c_int,
144    ) -> ::std::os::raw::c_int;
145    fn uv_tcp_keepalive(
146      handle: *mut uv_tcp_t,
147      enable: ::std::os::raw::c_int,
148      delay: ::std::os::raw::c_uint,
149    ) -> ::std::os::raw::c_int;
150    fn uv_tcp_simultaneous_accepts(
151      handle: *mut uv_tcp_t,
152      enable: ::std::os::raw::c_int,
153    ) -> ::std::os::raw::c_int;
154    fn uv_tcp_bind(
155      handle: *mut uv_tcp_t,
156      addr: *const sockaddr,
157      flags: ::std::os::raw::c_uint,
158    ) -> ::std::os::raw::c_int;
159    fn uv_tcp_getsockname(
160      handle: *const uv_tcp_t,
161      name: *mut sockaddr,
162      namelen: *mut ::std::os::raw::c_int,
163    ) -> ::std::os::raw::c_int;
164    fn uv_tcp_getpeername(
165      handle: *const uv_tcp_t,
166      name: *mut sockaddr,
167      namelen: *mut ::std::os::raw::c_int,
168    ) -> ::std::os::raw::c_int;
169    fn uv_tcp_close_reset(handle: *mut uv_tcp_t, close_cb: uv_close_cb) -> ::std::os::raw::c_int;
170    fn uv_tcp_connect(
171      req: *mut uv_connect_t,
172      handle: *mut uv_tcp_t,
173      addr: *const sockaddr,
174      cb: uv_connect_cb,
175    ) -> ::std::os::raw::c_int;
176    fn uv_udp_init(arg1: *mut uv_loop_t, handle: *mut uv_udp_t) -> ::std::os::raw::c_int;
177    fn uv_udp_init_ex(
178      arg1: *mut uv_loop_t,
179      handle: *mut uv_udp_t,
180      flags: ::std::os::raw::c_uint,
181    ) -> ::std::os::raw::c_int;
182    fn uv_udp_open(handle: *mut uv_udp_t, sock: uv_os_sock_t) -> ::std::os::raw::c_int;
183    fn uv_udp_bind(
184      handle: *mut uv_udp_t,
185      addr: *const sockaddr,
186      flags: ::std::os::raw::c_uint,
187    ) -> ::std::os::raw::c_int;
188    fn uv_udp_connect(handle: *mut uv_udp_t, addr: *const sockaddr) -> ::std::os::raw::c_int;
189    fn uv_udp_getpeername(
190      handle: *const uv_udp_t,
191      name: *mut sockaddr,
192      namelen: *mut ::std::os::raw::c_int,
193    ) -> ::std::os::raw::c_int;
194    fn uv_udp_getsockname(
195      handle: *const uv_udp_t,
196      name: *mut sockaddr,
197      namelen: *mut ::std::os::raw::c_int,
198    ) -> ::std::os::raw::c_int;
199    fn uv_udp_set_membership(
200      handle: *mut uv_udp_t,
201      multicast_addr: *const ::std::os::raw::c_char,
202      interface_addr: *const ::std::os::raw::c_char,
203      membership: uv_membership,
204    ) -> ::std::os::raw::c_int;
205    fn uv_udp_set_source_membership(
206      handle: *mut uv_udp_t,
207      multicast_addr: *const ::std::os::raw::c_char,
208      interface_addr: *const ::std::os::raw::c_char,
209      source_addr: *const ::std::os::raw::c_char,
210      membership: uv_membership,
211    ) -> ::std::os::raw::c_int;
212    fn uv_udp_set_multicast_loop(
213      handle: *mut uv_udp_t,
214      on: ::std::os::raw::c_int,
215    ) -> ::std::os::raw::c_int;
216    fn uv_udp_set_multicast_ttl(
217      handle: *mut uv_udp_t,
218      ttl: ::std::os::raw::c_int,
219    ) -> ::std::os::raw::c_int;
220    fn uv_udp_set_multicast_interface(
221      handle: *mut uv_udp_t,
222      interface_addr: *const ::std::os::raw::c_char,
223    ) -> ::std::os::raw::c_int;
224    fn uv_udp_set_broadcast(
225      handle: *mut uv_udp_t,
226      on: ::std::os::raw::c_int,
227    ) -> ::std::os::raw::c_int;
228    fn uv_udp_set_ttl(handle: *mut uv_udp_t, ttl: ::std::os::raw::c_int)
229      -> ::std::os::raw::c_int;
230    fn uv_udp_send(
231      req: *mut uv_udp_send_t,
232      handle: *mut uv_udp_t,
233      bufs: *const uv_buf_t,
234      nbufs: ::std::os::raw::c_uint,
235      addr: *const sockaddr,
236      send_cb: uv_udp_send_cb,
237    ) -> ::std::os::raw::c_int;
238    fn uv_udp_try_send(
239      handle: *mut uv_udp_t,
240      bufs: *const uv_buf_t,
241      nbufs: ::std::os::raw::c_uint,
242      addr: *const sockaddr,
243    ) -> ::std::os::raw::c_int;
244    fn uv_udp_recv_start(
245      handle: *mut uv_udp_t,
246      alloc_cb: uv_alloc_cb,
247      recv_cb: uv_udp_recv_cb,
248    ) -> ::std::os::raw::c_int;
249    fn uv_udp_using_recvmmsg(handle: *const uv_udp_t) -> ::std::os::raw::c_int;
250    fn uv_udp_recv_stop(handle: *mut uv_udp_t) -> ::std::os::raw::c_int;
251    fn uv_udp_get_send_queue_size(handle: *const uv_udp_t) -> usize;
252    fn uv_udp_get_send_queue_count(handle: *const uv_udp_t) -> usize;
253    fn uv_tty_init(
254      arg1: *mut uv_loop_t,
255      arg2: *mut uv_tty_t,
256      fd: uv_file,
257      readable: ::std::os::raw::c_int,
258    ) -> ::std::os::raw::c_int;
259    fn uv_tty_set_mode(arg1: *mut uv_tty_t, mode: uv_tty_mode_t) -> ::std::os::raw::c_int;
260    fn uv_tty_reset_mode() -> ::std::os::raw::c_int;
261    fn uv_tty_get_winsize(
262      arg1: *mut uv_tty_t,
263      width: *mut ::std::os::raw::c_int,
264      height: *mut ::std::os::raw::c_int,
265    ) -> ::std::os::raw::c_int;
266    fn uv_tty_set_vterm_state(state: uv_tty_vtermstate_t);
267    fn uv_tty_get_vterm_state(state: *mut uv_tty_vtermstate_t) -> ::std::os::raw::c_int;
268    fn uv_guess_handle(file: uv_file) -> uv_handle_type;
269    fn uv_pipe_init(
270      arg1: *mut uv_loop_t,
271      handle: *mut uv_pipe_t,
272      ipc: ::std::os::raw::c_int,
273    ) -> ::std::os::raw::c_int;
274    fn uv_pipe_open(arg1: *mut uv_pipe_t, file: uv_file) -> ::std::os::raw::c_int;
275    fn uv_pipe_bind(
276      handle: *mut uv_pipe_t,
277      name: *const ::std::os::raw::c_char,
278    ) -> ::std::os::raw::c_int;
279    fn uv_pipe_bind2(
280      handle: *mut uv_pipe_t,
281      name: *const ::std::os::raw::c_char,
282      namelen: usize,
283      flags: ::std::os::raw::c_uint,
284    ) -> ::std::os::raw::c_int;
285    fn uv_pipe_connect(
286      req: *mut uv_connect_t,
287      handle: *mut uv_pipe_t,
288      name: *const ::std::os::raw::c_char,
289      cb: uv_connect_cb,
290    );
291    fn uv_pipe_connect2(
292      req: *mut uv_connect_t,
293      handle: *mut uv_pipe_t,
294      name: *const ::std::os::raw::c_char,
295      namelen: usize,
296      flags: ::std::os::raw::c_uint,
297      cb: uv_connect_cb,
298    ) -> ::std::os::raw::c_int;
299    fn uv_pipe_getsockname(
300      handle: *const uv_pipe_t,
301      buffer: *mut ::std::os::raw::c_char,
302      size: *mut usize,
303    ) -> ::std::os::raw::c_int;
304    fn uv_pipe_getpeername(
305      handle: *const uv_pipe_t,
306      buffer: *mut ::std::os::raw::c_char,
307      size: *mut usize,
308    ) -> ::std::os::raw::c_int;
309    fn uv_pipe_pending_instances(handle: *mut uv_pipe_t, count: ::std::os::raw::c_int);
310    fn uv_pipe_pending_count(handle: *mut uv_pipe_t) -> ::std::os::raw::c_int;
311    fn uv_pipe_pending_type(handle: *mut uv_pipe_t) -> uv_handle_type;
312    fn uv_pipe_chmod(
313      handle: *mut uv_pipe_t,
314      flags: ::std::os::raw::c_int,
315    ) -> ::std::os::raw::c_int;
316    fn uv_poll_init(
317      loop_: *mut uv_loop_t,
318      handle: *mut uv_poll_t,
319      fd: ::std::os::raw::c_int,
320    ) -> ::std::os::raw::c_int;
321    fn uv_poll_init_socket(
322      loop_: *mut uv_loop_t,
323      handle: *mut uv_poll_t,
324      socket: uv_os_sock_t,
325    ) -> ::std::os::raw::c_int;
326    fn uv_poll_start(
327      handle: *mut uv_poll_t,
328      events: ::std::os::raw::c_int,
329      cb: uv_poll_cb,
330    ) -> ::std::os::raw::c_int;
331    fn uv_poll_stop(handle: *mut uv_poll_t) -> ::std::os::raw::c_int;
332    fn uv_prepare_init(arg1: *mut uv_loop_t, prepare: *mut uv_prepare_t)
333      -> ::std::os::raw::c_int;
334    fn uv_prepare_start(prepare: *mut uv_prepare_t, cb: uv_prepare_cb) -> ::std::os::raw::c_int;
335    fn uv_prepare_stop(prepare: *mut uv_prepare_t) -> ::std::os::raw::c_int;
336    fn uv_check_init(arg1: *mut uv_loop_t, check: *mut uv_check_t) -> ::std::os::raw::c_int;
337    fn uv_check_start(check: *mut uv_check_t, cb: uv_check_cb) -> ::std::os::raw::c_int;
338    fn uv_check_stop(check: *mut uv_check_t) -> ::std::os::raw::c_int;
339    fn uv_idle_init(arg1: *mut uv_loop_t, idle: *mut uv_idle_t) -> ::std::os::raw::c_int;
340    fn uv_idle_start(idle: *mut uv_idle_t, cb: uv_idle_cb) -> ::std::os::raw::c_int;
341    fn uv_idle_stop(idle: *mut uv_idle_t) -> ::std::os::raw::c_int;
342    fn uv_async_init(
343      arg1: *mut uv_loop_t,
344      async_: *mut uv_async_t,
345      async_cb: uv_async_cb,
346    ) -> ::std::os::raw::c_int;
347    fn uv_async_send(async_: *mut uv_async_t) -> ::std::os::raw::c_int;
348    fn uv_timer_init(arg1: *mut uv_loop_t, handle: *mut uv_timer_t) -> ::std::os::raw::c_int;
349    fn uv_timer_start(
350      handle: *mut uv_timer_t,
351      cb: uv_timer_cb,
352      timeout: u64,
353      repeat: u64,
354    ) -> ::std::os::raw::c_int;
355    fn uv_timer_stop(handle: *mut uv_timer_t) -> ::std::os::raw::c_int;
356    fn uv_timer_again(handle: *mut uv_timer_t) -> ::std::os::raw::c_int;
357    fn uv_timer_set_repeat(handle: *mut uv_timer_t, repeat: u64);
358    fn uv_timer_get_repeat(handle: *const uv_timer_t) -> u64;
359    fn uv_timer_get_due_in(handle: *const uv_timer_t) -> u64;
360    fn uv_getaddrinfo(
361      loop_: *mut uv_loop_t,
362      req: *mut uv_getaddrinfo_t,
363      getaddrinfo_cb: uv_getaddrinfo_cb,
364      node: *const ::std::os::raw::c_char,
365      service: *const ::std::os::raw::c_char,
366      hints: *const addrinfo,
367    ) -> ::std::os::raw::c_int;
368    fn uv_freeaddrinfo(ai: *mut addrinfo);
369    fn uv_getnameinfo(
370      loop_: *mut uv_loop_t,
371      req: *mut uv_getnameinfo_t,
372      getnameinfo_cb: uv_getnameinfo_cb,
373      addr: *const sockaddr,
374      flags: ::std::os::raw::c_int,
375    ) -> ::std::os::raw::c_int;
376    fn uv_spawn(
377      loop_: *mut uv_loop_t,
378      handle: *mut uv_process_t,
379      options: *const uv_process_options_t,
380    ) -> ::std::os::raw::c_int;
381    fn uv_process_kill(
382      arg1: *mut uv_process_t,
383      signum: ::std::os::raw::c_int,
384    ) -> ::std::os::raw::c_int;
385    fn uv_kill(
386      pid: ::std::os::raw::c_int,
387      signum: ::std::os::raw::c_int,
388    ) -> ::std::os::raw::c_int;
389    fn uv_process_get_pid(arg1: *const uv_process_t) -> uv_pid_t;
390    fn uv_queue_work(
391      loop_: *mut uv_loop_t,
392      req: *mut uv_work_t,
393      work_cb: uv_work_cb,
394      after_work_cb: uv_after_work_cb,
395    ) -> ::std::os::raw::c_int;
396    fn uv_cancel(req: *mut uv_req_t) -> ::std::os::raw::c_int;
397    fn uv_setup_args(
398      argc: ::std::os::raw::c_int,
399      argv: *mut *mut ::std::os::raw::c_char,
400    ) -> *mut *mut ::std::os::raw::c_char;
401    fn uv_get_process_title(
402      buffer: *mut ::std::os::raw::c_char,
403      size: usize,
404    ) -> ::std::os::raw::c_int;
405    fn uv_set_process_title(title: *const ::std::os::raw::c_char) -> ::std::os::raw::c_int;
406    fn uv_resident_set_memory(rss: *mut usize) -> ::std::os::raw::c_int;
407    fn uv_uptime(uptime: *mut f64) -> ::std::os::raw::c_int;
408    fn uv_get_osfhandle(fd: ::std::os::raw::c_int) -> uv_os_fd_t;
409    fn uv_open_osfhandle(os_fd: uv_os_fd_t) -> ::std::os::raw::c_int;
410    fn uv_getrusage(rusage: *mut uv_rusage_t) -> ::std::os::raw::c_int;
411    fn uv_os_homedir(
412      buffer: *mut ::std::os::raw::c_char,
413      size: *mut usize,
414    ) -> ::std::os::raw::c_int;
415    fn uv_os_tmpdir(
416      buffer: *mut ::std::os::raw::c_char,
417      size: *mut usize,
418    ) -> ::std::os::raw::c_int;
419    fn uv_os_get_passwd(pwd: *mut uv_passwd_t) -> ::std::os::raw::c_int;
420    fn uv_os_free_passwd(pwd: *mut uv_passwd_t);
421    fn uv_os_get_passwd2(pwd: *mut uv_passwd_t, uid: uv_uid_t) -> ::std::os::raw::c_int;
422    fn uv_os_get_group(grp: *mut uv_group_t, gid: uv_uid_t) -> ::std::os::raw::c_int;
423    fn uv_os_free_group(grp: *mut uv_group_t);
424    fn uv_os_getpid() -> uv_pid_t;
425    fn uv_os_getppid() -> uv_pid_t;
426    fn uv_os_getpriority(
427      pid: uv_pid_t,
428      priority: *mut ::std::os::raw::c_int,
429    ) -> ::std::os::raw::c_int;
430    fn uv_os_setpriority(pid: uv_pid_t, priority: ::std::os::raw::c_int)
431      -> ::std::os::raw::c_int;
432    fn uv_thread_getpriority(
433      tid: uv_thread_t,
434      priority: *mut ::std::os::raw::c_int,
435    ) -> ::std::os::raw::c_int;
436    fn uv_thread_setpriority(
437      tid: uv_thread_t,
438      priority: ::std::os::raw::c_int,
439    ) -> ::std::os::raw::c_int;
440    fn uv_available_parallelism() -> ::std::os::raw::c_uint;
441    fn uv_cpu_info(
442      cpu_infos: *mut *mut uv_cpu_info_t,
443      count: *mut ::std::os::raw::c_int,
444    ) -> ::std::os::raw::c_int;
445    fn uv_free_cpu_info(cpu_infos: *mut uv_cpu_info_t, count: ::std::os::raw::c_int);
446    fn uv_cpumask_size() -> ::std::os::raw::c_int;
447    fn uv_interface_addresses(
448      addresses: *mut *mut uv_interface_address_t,
449      count: *mut ::std::os::raw::c_int,
450    ) -> ::std::os::raw::c_int;
451    fn uv_free_interface_addresses(
452      addresses: *mut uv_interface_address_t,
453      count: ::std::os::raw::c_int,
454    );
455    fn uv_os_environ(
456      envitems: *mut *mut uv_env_item_t,
457      count: *mut ::std::os::raw::c_int,
458    ) -> ::std::os::raw::c_int;
459    fn uv_os_free_environ(envitems: *mut uv_env_item_t, count: ::std::os::raw::c_int);
460    fn uv_os_getenv(
461      name: *const ::std::os::raw::c_char,
462      buffer: *mut ::std::os::raw::c_char,
463      size: *mut usize,
464    ) -> ::std::os::raw::c_int;
465    fn uv_os_setenv(
466      name: *const ::std::os::raw::c_char,
467      value: *const ::std::os::raw::c_char,
468    ) -> ::std::os::raw::c_int;
469    fn uv_os_unsetenv(name: *const ::std::os::raw::c_char) -> ::std::os::raw::c_int;
470    fn uv_os_gethostname(
471      buffer: *mut ::std::os::raw::c_char,
472      size: *mut usize,
473    ) -> ::std::os::raw::c_int;
474    fn uv_os_uname(buffer: *mut uv_utsname_t) -> ::std::os::raw::c_int;
475    fn uv_metrics_info(
476      loop_: *mut uv_loop_t,
477      metrics: *mut uv_metrics_t,
478    ) -> ::std::os::raw::c_int;
479    fn uv_metrics_idle_time(loop_: *mut uv_loop_t) -> u64;
480    fn uv_fs_get_type(arg1: *const uv_fs_t) -> uv_fs_type;
481    fn uv_fs_get_result(arg1: *const uv_fs_t) -> isize;
482    fn uv_fs_get_system_error(arg1: *const uv_fs_t) -> ::std::os::raw::c_int;
483    fn uv_fs_get_ptr(arg1: *const uv_fs_t) -> *mut ::std::os::raw::c_void;
484    fn uv_fs_get_path(arg1: *const uv_fs_t) -> *const ::std::os::raw::c_char;
485    fn uv_fs_get_statbuf(arg1: *mut uv_fs_t) -> *mut uv_stat_t;
486    fn uv_fs_req_cleanup(req: *mut uv_fs_t);
487    fn uv_fs_close(
488      loop_: *mut uv_loop_t,
489      req: *mut uv_fs_t,
490      file: uv_file,
491      cb: uv_fs_cb,
492    ) -> ::std::os::raw::c_int;
493    fn uv_fs_open(
494      loop_: *mut uv_loop_t,
495      req: *mut uv_fs_t,
496      path: *const ::std::os::raw::c_char,
497      flags: ::std::os::raw::c_int,
498      mode: ::std::os::raw::c_int,
499      cb: uv_fs_cb,
500    ) -> ::std::os::raw::c_int;
501    fn uv_fs_read(
502      loop_: *mut uv_loop_t,
503      req: *mut uv_fs_t,
504      file: uv_file,
505      bufs: *const uv_buf_t,
506      nbufs: ::std::os::raw::c_uint,
507      offset: i64,
508      cb: uv_fs_cb,
509    ) -> ::std::os::raw::c_int;
510    fn uv_fs_unlink(
511      loop_: *mut uv_loop_t,
512      req: *mut uv_fs_t,
513      path: *const ::std::os::raw::c_char,
514      cb: uv_fs_cb,
515    ) -> ::std::os::raw::c_int;
516    fn uv_fs_write(
517      loop_: *mut uv_loop_t,
518      req: *mut uv_fs_t,
519      file: uv_file,
520      bufs: *const uv_buf_t,
521      nbufs: ::std::os::raw::c_uint,
522      offset: i64,
523      cb: uv_fs_cb,
524    ) -> ::std::os::raw::c_int;
525    fn uv_fs_copyfile(
526      loop_: *mut uv_loop_t,
527      req: *mut uv_fs_t,
528      path: *const ::std::os::raw::c_char,
529      new_path: *const ::std::os::raw::c_char,
530      flags: ::std::os::raw::c_int,
531      cb: uv_fs_cb,
532    ) -> ::std::os::raw::c_int;
533    fn uv_fs_mkdir(
534      loop_: *mut uv_loop_t,
535      req: *mut uv_fs_t,
536      path: *const ::std::os::raw::c_char,
537      mode: ::std::os::raw::c_int,
538      cb: uv_fs_cb,
539    ) -> ::std::os::raw::c_int;
540    fn uv_fs_mkdtemp(
541      loop_: *mut uv_loop_t,
542      req: *mut uv_fs_t,
543      tpl: *const ::std::os::raw::c_char,
544      cb: uv_fs_cb,
545    ) -> ::std::os::raw::c_int;
546    fn uv_fs_mkstemp(
547      loop_: *mut uv_loop_t,
548      req: *mut uv_fs_t,
549      tpl: *const ::std::os::raw::c_char,
550      cb: uv_fs_cb,
551    ) -> ::std::os::raw::c_int;
552    fn uv_fs_rmdir(
553      loop_: *mut uv_loop_t,
554      req: *mut uv_fs_t,
555      path: *const ::std::os::raw::c_char,
556      cb: uv_fs_cb,
557    ) -> ::std::os::raw::c_int;
558    fn uv_fs_scandir(
559      loop_: *mut uv_loop_t,
560      req: *mut uv_fs_t,
561      path: *const ::std::os::raw::c_char,
562      flags: ::std::os::raw::c_int,
563      cb: uv_fs_cb,
564    ) -> ::std::os::raw::c_int;
565    fn uv_fs_scandir_next(req: *mut uv_fs_t, ent: *mut uv_dirent_t) -> ::std::os::raw::c_int;
566    fn uv_fs_opendir(
567      loop_: *mut uv_loop_t,
568      req: *mut uv_fs_t,
569      path: *const ::std::os::raw::c_char,
570      cb: uv_fs_cb,
571    ) -> ::std::os::raw::c_int;
572    fn uv_fs_readdir(
573      loop_: *mut uv_loop_t,
574      req: *mut uv_fs_t,
575      dir: *mut uv_dir_t,
576      cb: uv_fs_cb,
577    ) -> ::std::os::raw::c_int;
578    fn uv_fs_closedir(
579      loop_: *mut uv_loop_t,
580      req: *mut uv_fs_t,
581      dir: *mut uv_dir_t,
582      cb: uv_fs_cb,
583    ) -> ::std::os::raw::c_int;
584    fn uv_fs_stat(
585      loop_: *mut uv_loop_t,
586      req: *mut uv_fs_t,
587      path: *const ::std::os::raw::c_char,
588      cb: uv_fs_cb,
589    ) -> ::std::os::raw::c_int;
590    fn uv_fs_fstat(
591      loop_: *mut uv_loop_t,
592      req: *mut uv_fs_t,
593      file: uv_file,
594      cb: uv_fs_cb,
595    ) -> ::std::os::raw::c_int;
596    fn uv_fs_rename(
597      loop_: *mut uv_loop_t,
598      req: *mut uv_fs_t,
599      path: *const ::std::os::raw::c_char,
600      new_path: *const ::std::os::raw::c_char,
601      cb: uv_fs_cb,
602    ) -> ::std::os::raw::c_int;
603    fn uv_fs_fsync(
604      loop_: *mut uv_loop_t,
605      req: *mut uv_fs_t,
606      file: uv_file,
607      cb: uv_fs_cb,
608    ) -> ::std::os::raw::c_int;
609    fn uv_fs_fdatasync(
610      loop_: *mut uv_loop_t,
611      req: *mut uv_fs_t,
612      file: uv_file,
613      cb: uv_fs_cb,
614    ) -> ::std::os::raw::c_int;
615    fn uv_fs_ftruncate(
616      loop_: *mut uv_loop_t,
617      req: *mut uv_fs_t,
618      file: uv_file,
619      offset: i64,
620      cb: uv_fs_cb,
621    ) -> ::std::os::raw::c_int;
622    fn uv_fs_sendfile(
623      loop_: *mut uv_loop_t,
624      req: *mut uv_fs_t,
625      out_fd: uv_file,
626      in_fd: uv_file,
627      in_offset: i64,
628      length: usize,
629      cb: uv_fs_cb,
630    ) -> ::std::os::raw::c_int;
631    fn uv_fs_access(
632      loop_: *mut uv_loop_t,
633      req: *mut uv_fs_t,
634      path: *const ::std::os::raw::c_char,
635      mode: ::std::os::raw::c_int,
636      cb: uv_fs_cb,
637    ) -> ::std::os::raw::c_int;
638    fn uv_fs_chmod(
639      loop_: *mut uv_loop_t,
640      req: *mut uv_fs_t,
641      path: *const ::std::os::raw::c_char,
642      mode: ::std::os::raw::c_int,
643      cb: uv_fs_cb,
644    ) -> ::std::os::raw::c_int;
645    fn uv_fs_utime(
646      loop_: *mut uv_loop_t,
647      req: *mut uv_fs_t,
648      path: *const ::std::os::raw::c_char,
649      atime: f64,
650      mtime: f64,
651      cb: uv_fs_cb,
652    ) -> ::std::os::raw::c_int;
653    fn uv_fs_futime(
654      loop_: *mut uv_loop_t,
655      req: *mut uv_fs_t,
656      file: uv_file,
657      atime: f64,
658      mtime: f64,
659      cb: uv_fs_cb,
660    ) -> ::std::os::raw::c_int;
661    fn uv_fs_lutime(
662      loop_: *mut uv_loop_t,
663      req: *mut uv_fs_t,
664      path: *const ::std::os::raw::c_char,
665      atime: f64,
666      mtime: f64,
667      cb: uv_fs_cb,
668    ) -> ::std::os::raw::c_int;
669    fn uv_fs_lstat(
670      loop_: *mut uv_loop_t,
671      req: *mut uv_fs_t,
672      path: *const ::std::os::raw::c_char,
673      cb: uv_fs_cb,
674    ) -> ::std::os::raw::c_int;
675    fn uv_fs_link(
676      loop_: *mut uv_loop_t,
677      req: *mut uv_fs_t,
678      path: *const ::std::os::raw::c_char,
679      new_path: *const ::std::os::raw::c_char,
680      cb: uv_fs_cb,
681    ) -> ::std::os::raw::c_int;
682    fn uv_fs_symlink(
683      loop_: *mut uv_loop_t,
684      req: *mut uv_fs_t,
685      path: *const ::std::os::raw::c_char,
686      new_path: *const ::std::os::raw::c_char,
687      flags: ::std::os::raw::c_int,
688      cb: uv_fs_cb,
689    ) -> ::std::os::raw::c_int;
690    fn uv_fs_readlink(
691      loop_: *mut uv_loop_t,
692      req: *mut uv_fs_t,
693      path: *const ::std::os::raw::c_char,
694      cb: uv_fs_cb,
695    ) -> ::std::os::raw::c_int;
696    fn uv_fs_realpath(
697      loop_: *mut uv_loop_t,
698      req: *mut uv_fs_t,
699      path: *const ::std::os::raw::c_char,
700      cb: uv_fs_cb,
701    ) -> ::std::os::raw::c_int;
702    fn uv_fs_fchmod(
703      loop_: *mut uv_loop_t,
704      req: *mut uv_fs_t,
705      file: uv_file,
706      mode: ::std::os::raw::c_int,
707      cb: uv_fs_cb,
708    ) -> ::std::os::raw::c_int;
709    fn uv_fs_chown(
710      loop_: *mut uv_loop_t,
711      req: *mut uv_fs_t,
712      path: *const ::std::os::raw::c_char,
713      uid: uv_uid_t,
714      gid: uv_gid_t,
715      cb: uv_fs_cb,
716    ) -> ::std::os::raw::c_int;
717    fn uv_fs_fchown(
718      loop_: *mut uv_loop_t,
719      req: *mut uv_fs_t,
720      file: uv_file,
721      uid: uv_uid_t,
722      gid: uv_gid_t,
723      cb: uv_fs_cb,
724    ) -> ::std::os::raw::c_int;
725    fn uv_fs_lchown(
726      loop_: *mut uv_loop_t,
727      req: *mut uv_fs_t,
728      path: *const ::std::os::raw::c_char,
729      uid: uv_uid_t,
730      gid: uv_gid_t,
731      cb: uv_fs_cb,
732    ) -> ::std::os::raw::c_int;
733    fn uv_fs_statfs(
734      loop_: *mut uv_loop_t,
735      req: *mut uv_fs_t,
736      path: *const ::std::os::raw::c_char,
737      cb: uv_fs_cb,
738    ) -> ::std::os::raw::c_int;
739    fn uv_fs_poll_init(loop_: *mut uv_loop_t, handle: *mut uv_fs_poll_t)
740      -> ::std::os::raw::c_int;
741    fn uv_fs_poll_start(
742      handle: *mut uv_fs_poll_t,
743      poll_cb: uv_fs_poll_cb,
744      path: *const ::std::os::raw::c_char,
745      interval: ::std::os::raw::c_uint,
746    ) -> ::std::os::raw::c_int;
747    fn uv_fs_poll_stop(handle: *mut uv_fs_poll_t) -> ::std::os::raw::c_int;
748    fn uv_fs_poll_getpath(
749      handle: *mut uv_fs_poll_t,
750      buffer: *mut ::std::os::raw::c_char,
751      size: *mut usize,
752    ) -> ::std::os::raw::c_int;
753    fn uv_signal_init(loop_: *mut uv_loop_t, handle: *mut uv_signal_t) -> ::std::os::raw::c_int;
754    fn uv_signal_start(
755      handle: *mut uv_signal_t,
756      signal_cb: uv_signal_cb,
757      signum: ::std::os::raw::c_int,
758    ) -> ::std::os::raw::c_int;
759    fn uv_signal_start_oneshot(
760      handle: *mut uv_signal_t,
761      signal_cb: uv_signal_cb,
762      signum: ::std::os::raw::c_int,
763    ) -> ::std::os::raw::c_int;
764    fn uv_signal_stop(handle: *mut uv_signal_t) -> ::std::os::raw::c_int;
765    fn uv_loadavg(avg: *mut f64);
766    fn uv_fs_event_init(
767      loop_: *mut uv_loop_t,
768      handle: *mut uv_fs_event_t,
769    ) -> ::std::os::raw::c_int;
770    fn uv_fs_event_start(
771      handle: *mut uv_fs_event_t,
772      cb: uv_fs_event_cb,
773      path: *const ::std::os::raw::c_char,
774      flags: ::std::os::raw::c_uint,
775    ) -> ::std::os::raw::c_int;
776    fn uv_fs_event_stop(handle: *mut uv_fs_event_t) -> ::std::os::raw::c_int;
777    fn uv_fs_event_getpath(
778      handle: *mut uv_fs_event_t,
779      buffer: *mut ::std::os::raw::c_char,
780      size: *mut usize,
781    ) -> ::std::os::raw::c_int;
782    fn uv_ip4_addr(
783      ip: *const ::std::os::raw::c_char,
784      port: ::std::os::raw::c_int,
785      addr: *mut sockaddr_in,
786    ) -> ::std::os::raw::c_int;
787    fn uv_ip6_addr(
788      ip: *const ::std::os::raw::c_char,
789      port: ::std::os::raw::c_int,
790      addr: *mut sockaddr_in6,
791    ) -> ::std::os::raw::c_int;
792    fn uv_ip4_name(
793      src: *const sockaddr_in,
794      dst: *mut ::std::os::raw::c_char,
795      size: usize,
796    ) -> ::std::os::raw::c_int;
797    fn uv_ip6_name(
798      src: *const sockaddr_in6,
799      dst: *mut ::std::os::raw::c_char,
800      size: usize,
801    ) -> ::std::os::raw::c_int;
802    fn uv_ip_name(
803      src: *const sockaddr,
804      dst: *mut ::std::os::raw::c_char,
805      size: usize,
806    ) -> ::std::os::raw::c_int;
807    fn uv_inet_ntop(
808      af: ::std::os::raw::c_int,
809      src: *const ::std::os::raw::c_void,
810      dst: *mut ::std::os::raw::c_char,
811      size: usize,
812    ) -> ::std::os::raw::c_int;
813    fn uv_inet_pton(
814      af: ::std::os::raw::c_int,
815      src: *const ::std::os::raw::c_char,
816      dst: *mut ::std::os::raw::c_void,
817    ) -> ::std::os::raw::c_int;
818    fn uv_random(
819      loop_: *mut uv_loop_t,
820      req: *mut uv_random_t,
821      buf: *mut ::std::os::raw::c_void,
822      buflen: usize,
823      flags: ::std::os::raw::c_uint,
824      cb: uv_random_cb,
825    ) -> ::std::os::raw::c_int;
826    fn uv_if_indextoname(
827      ifindex: ::std::os::raw::c_uint,
828      buffer: *mut ::std::os::raw::c_char,
829      size: *mut usize,
830    ) -> ::std::os::raw::c_int;
831    fn uv_if_indextoiid(
832      ifindex: ::std::os::raw::c_uint,
833      buffer: *mut ::std::os::raw::c_char,
834      size: *mut usize,
835    ) -> ::std::os::raw::c_int;
836    fn uv_exepath(buffer: *mut ::std::os::raw::c_char, size: *mut usize)
837      -> ::std::os::raw::c_int;
838    fn uv_cwd(buffer: *mut ::std::os::raw::c_char, size: *mut usize) -> ::std::os::raw::c_int;
839    fn uv_chdir(dir: *const ::std::os::raw::c_char) -> ::std::os::raw::c_int;
840    fn uv_get_free_memory() -> u64;
841    fn uv_get_total_memory() -> u64;
842    fn uv_get_constrained_memory() -> u64;
843    fn uv_get_available_memory() -> u64;
844    fn uv_clock_gettime(clock_id: uv_clock_id, ts: *mut uv_timespec64_t)
845      -> ::std::os::raw::c_int;
846    fn uv_hrtime() -> u64;
847    fn uv_sleep(msec: ::std::os::raw::c_uint);
848    fn uv_disable_stdio_inheritance();
849    fn uv_dlopen(
850      filename: *const ::std::os::raw::c_char,
851      lib: *mut uv_lib_t,
852    ) -> ::std::os::raw::c_int;
853    fn uv_dlclose(lib: *mut uv_lib_t);
854    fn uv_dlsym(
855      lib: *mut uv_lib_t,
856      name: *const ::std::os::raw::c_char,
857      ptr: *mut *mut ::std::os::raw::c_void,
858    ) -> ::std::os::raw::c_int;
859    fn uv_dlerror(lib: *const uv_lib_t) -> *const ::std::os::raw::c_char;
860    fn uv_mutex_init(handle: *mut uv_mutex_t) -> ::std::os::raw::c_int;
861    fn uv_mutex_init_recursive(handle: *mut uv_mutex_t) -> ::std::os::raw::c_int;
862    fn uv_mutex_destroy(handle: *mut uv_mutex_t);
863    fn uv_mutex_lock(handle: *mut uv_mutex_t);
864    fn uv_mutex_trylock(handle: *mut uv_mutex_t) -> ::std::os::raw::c_int;
865    fn uv_mutex_unlock(handle: *mut uv_mutex_t);
866    fn uv_rwlock_init(rwlock: *mut uv_rwlock_t) -> ::std::os::raw::c_int;
867    fn uv_rwlock_destroy(rwlock: *mut uv_rwlock_t);
868    fn uv_rwlock_rdlock(rwlock: *mut uv_rwlock_t);
869    fn uv_rwlock_tryrdlock(rwlock: *mut uv_rwlock_t) -> ::std::os::raw::c_int;
870    fn uv_rwlock_rdunlock(rwlock: *mut uv_rwlock_t);
871    fn uv_rwlock_wrlock(rwlock: *mut uv_rwlock_t);
872    fn uv_rwlock_trywrlock(rwlock: *mut uv_rwlock_t) -> ::std::os::raw::c_int;
873    fn uv_rwlock_wrunlock(rwlock: *mut uv_rwlock_t);
874    fn uv_sem_init(sem: *mut uv_sem_t, value: ::std::os::raw::c_uint) -> ::std::os::raw::c_int;
875    fn uv_sem_destroy(sem: *mut uv_sem_t);
876    fn uv_sem_post(sem: *mut uv_sem_t);
877    fn uv_sem_wait(sem: *mut uv_sem_t);
878    fn uv_sem_trywait(sem: *mut uv_sem_t) -> ::std::os::raw::c_int;
879    fn uv_cond_init(cond: *mut uv_cond_t) -> ::std::os::raw::c_int;
880    fn uv_cond_destroy(cond: *mut uv_cond_t);
881    fn uv_cond_signal(cond: *mut uv_cond_t);
882    fn uv_cond_broadcast(cond: *mut uv_cond_t);
883    fn uv_barrier_init(
884      barrier: *mut uv_barrier_t,
885      count: ::std::os::raw::c_uint,
886    ) -> ::std::os::raw::c_int;
887    fn uv_barrier_destroy(barrier: *mut uv_barrier_t);
888    fn uv_barrier_wait(barrier: *mut uv_barrier_t) -> ::std::os::raw::c_int;
889    fn uv_cond_wait(cond: *mut uv_cond_t, mutex: *mut uv_mutex_t);
890    fn uv_cond_timedwait(
891      cond: *mut uv_cond_t,
892      mutex: *mut uv_mutex_t,
893      timeout: u64,
894    ) -> ::std::os::raw::c_int;
895    fn uv_once(guard: *mut uv_once_t, callback: ::std::option::Option<unsafe extern "C" fn()>);
896    fn uv_key_create(key: *mut uv_key_t) -> ::std::os::raw::c_int;
897    fn uv_key_delete(key: *mut uv_key_t);
898    fn uv_key_get(key: *mut uv_key_t) -> *mut ::std::os::raw::c_void;
899    fn uv_key_set(key: *mut uv_key_t, value: *mut ::std::os::raw::c_void);
900    fn uv_gettimeofday(tv: *mut uv_timeval64_t) -> ::std::os::raw::c_int;
901    fn uv_thread_create(
902      tid: *mut uv_thread_t,
903      entry: uv_thread_cb,
904      arg: *mut ::std::os::raw::c_void,
905    ) -> ::std::os::raw::c_int;
906    fn uv_thread_create_ex(
907      tid: *mut uv_thread_t,
908      params: *const uv_thread_options_t,
909      entry: uv_thread_cb,
910      arg: *mut ::std::os::raw::c_void,
911    ) -> ::std::os::raw::c_int;
912    fn uv_thread_setaffinity(
913      tid: *mut uv_thread_t,
914      cpumask: *mut ::std::os::raw::c_char,
915      oldmask: *mut ::std::os::raw::c_char,
916      mask_size: usize,
917    ) -> ::std::os::raw::c_int;
918    fn uv_thread_getaffinity(
919      tid: *mut uv_thread_t,
920      cpumask: *mut ::std::os::raw::c_char,
921      mask_size: usize,
922    ) -> ::std::os::raw::c_int;
923    fn uv_thread_getcpu() -> ::std::os::raw::c_int;
924    fn uv_thread_self() -> uv_thread_t;
925    fn uv_thread_join(tid: *mut uv_thread_t) -> ::std::os::raw::c_int;
926    fn uv_thread_equal(t1: *const uv_thread_t, t2: *const uv_thread_t) -> ::std::os::raw::c_int;
927    fn uv_loop_get_data(arg1: *const uv_loop_t) -> *mut ::std::os::raw::c_void;
928    fn uv_loop_set_data(arg1: *mut uv_loop_t, data: *mut ::std::os::raw::c_void);
929    fn uv_utf16_length_as_wtf8(utf16: *const u16, utf16_len: isize) -> usize;
930    fn uv_utf16_to_wtf8(
931      utf16: *const u16,
932      utf16_len: isize,
933      wtf8_ptr: *mut *mut ::std::os::raw::c_char,
934      wtf8_len_ptr: *mut usize,
935    ) -> ::std::os::raw::c_int;
936    fn uv_wtf8_length_as_utf16(wtf8: *const ::std::os::raw::c_char) -> isize;
937    fn uv_wtf8_to_utf16(wtf8: *const ::std::os::raw::c_char, utf16: *mut u16, utf16_len: usize);
938  }
939
940}
941extern "C" {
942  pub fn uv_loop_configure(loop_: *mut uv_loop_t, option: uv_loop_option, ...);
943}
944
945#[cfg(feature = "dyn-symbols")]
946pub(super) unsafe fn load_all() -> Result<libloading::Library, libloading::Error> {
947  #[cfg(windows)]
948  let host = libloading::os::windows::Library::this()?.into();
949
950  #[cfg(unix)]
951  let host = libloading::os::unix::Library::this().into();
952
953  load(&host)?;
954
955  Ok(host)
956}