mailing list of musl libc
 help / color / mirror / code / Atom feed
* [musl] About the glibc libresolv vs musl network resolver routines signature
@ 2020-10-23  9:25 =?gb18030?B?xMnAvMja0ak=?=
  2020-10-23 17:08 ` Rich Felker
  0 siblings, 1 reply; 2+ messages in thread
From: =?gb18030?B?xMnAvMja0ak=?= @ 2020-10-23  9:25 UTC (permalink / raw)
  To: =?gb18030?B?bXVzbA==?=

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain; charset="gb18030", Size: 593 bytes --]

I work with any third party code written with glic, and I need compile and run it in a musl runtime.The code use `res_ninit`, but I cloud not find it in musl's resolv.h file.I noticed that glibc use `res_ninit`, `res_nclose`, `res_nquery`, etc, and marked `res_init`, `res_query`, etc as deprecated, but musl still using the old signature.I'm wondering:- How do I compile the code that use the `res_ninit` routine signature?- Is there a standard for the sinature for `resolv.h` (/usr/include/resolv.h)?- Will musl will use the new `res_ninit` glibc current using or the `res_init` style still?

[-- Attachment #2: Type: text/html, Size: 1306 bytes --]

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [musl] About the glibc libresolv vs musl network resolver routines signature
  2020-10-23  9:25 [musl] About the glibc libresolv vs musl network resolver routines signature =?gb18030?B?xMnAvMja0ak=?=
@ 2020-10-23 17:08 ` Rich Felker
  0 siblings, 0 replies; 2+ messages in thread
From: Rich Felker @ 2020-10-23 17:08 UTC (permalink / raw)
  To: 纳兰融雪; +Cc: musl

On Fri, Oct 23, 2020 at 05:25:44PM +0800, 纳兰融雪 wrote:
> I work with any third party code written with glic, and I need
> compile and run it in a musl runtime.The code use `res_ninit`, but I
> cloud not find it in musl's resolv.h file.I noticed that glibc use
> `res_ninit`, `res_nclose`, `res_nquery`, etc, and marked `res_init`,
> `res_query`, etc as deprecated, but musl still using the old
> signature.I'm wondering:- How do I compile the code that use the
> `res_ninit` routine signature?- Is there a standard for the sinature
> for `resolv.h` (/usr/include/resolv.h)?- Will musl will use the new
> `res_ninit` glibc current using or the `res_init` style still?

resolv.h defines the __RES version macro to indicate the API level
provided, and its meaning is consistent across different libcs. __RES
>= 19991006 indicates support for the res_n* functions. musl's
resolver is stateless and does not have them, and defines __RES
appropriately to indicate that it doesn't.

Rich

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2020-10-23 17:08 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-10-23  9:25 [musl] About the glibc libresolv vs musl network resolver routines signature =?gb18030?B?xMnAvMja0ak=?=
2020-10-23 17:08 ` Rich Felker

Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/musl/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).