1 /* test to build and run so that we know if we have getprotobyname_r
2 * and getprotobynumber_r */
12 * For me the code below compiles, but it segfaults when actually run:
14 * #0 0x00007f7fc20050a9 in _rtld_symlook_obj () from /usr/libexec/ld.elf_so
15 * #1 0x00007f7fc20059e0 in _rtld_symlook_default () from /usr/libexec/ld.elf_so
16 * #2 0x00007f7fc20060d3 in _rtld_find_plt_symdef () from /usr/libexec/ld.elf_so
17 * #3 0x00007f7fc2000bc5 in _rtld_bind () from /usr/libexec/ld.elf_so
18 * #4 0x00007f7fc20007fd in _rtld_bind_start () from /usr/libexec/ld.elf_so
19 * #5 0x0000000000000000 in ?? ()
21 * I guess that somebody decided it would be clever to pretend that the calls exist,
22 * but then /usr/libexec/ld.elf_so can't figure out what to do.
24 * This is EXTREMELY disconcerting, as it occurs during 'make-config.sh'
25 * and so you're not sure (without a nontrivial amount of debugging)
26 * whether configuration completed without error.
28 return 1; // just say "no"
30 struct protoent result_buf
;
31 struct protoent
*result
;
33 getprotobyname_r("", &result_buf
, buf
, BUFSIZE
, &result
);
34 getprotobynumber_r(0, &result_buf
, buf
, BUFSIZE
, &result
);