mailing list of musl libc
 help / color / mirror / code / Atom feed
From: Isaac Dunham <idunham@lavabit.com>
To: musl@lists.openwall.com
Subject: Re: lshw FTBFS: res_querydomain declared but not implemented
Date: Mon, 31 Dec 2012 12:03:34 -0800	[thread overview]
Message-ID: <20121231120334.05263f66.idunham@lavabit.com> (raw)
In-Reply-To: <20121231180653.GO20323@brightrain.aerifal.cx>

On Mon, 31 Dec 2012 13:06:53 -0500
Rich Felker <dalias@aerifal.cx> wrote:

> On Sun, Dec 30, 2012 at 09:59:31PM -0800, Isaac Dunham wrote:
> > I've been trying to build lshw [1] with musl, and I ran into a few problems:
> 
> Have you sent any reports/patches upstream yet?

I figured I'd get it to compile and see how it runs first.

<snip>

> > 3: It wants MAX_PATH from some header that doesn't have it: I added <limits.h>
> 
> PATH_MAX is in limits.h. MAXPATHLEN is in sys/param.h (bogus header
> full of random miscellaneous junk). I don't think I've ever heard of
> MAX_PATH...
Sorry, I meant PATH_MAX.

> > 4: It wants res_querydomain.
> > This does not show up until link time, since <resolv.h> declares it.
> > However, musl does not acually implement this function.
> 
> And it seems to be completely undocumented how it's supposed to
> work...
Call res_query with name as "name.domain". It's described in the linux-dev manpages. 
> > Currently, I've got a very hackish implementation that isn't fit to ship:
> > -it doesn't check for name == "machine."
> 
> What is special about "machine."?

That was a bad example; I meant "Doesn't check for a terminal '.'"

> > -it does no error checking, on the assumption that res_query can handle that.
> 
> Seems fine.
> 
> BTW a full name can never be longer than 256 bytes (including null
> termination), so you can do the concatenation on the stack in a
> fixed-size array. You'll need to generate your own error if the
> combined length would exceed the max.

Ah, thanks.

-- 
Isaac Dunham <idunham@lavabit.com>



      reply	other threads:[~2012-12-31 20:03 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-12-31  5:59 Isaac Dunham
2012-12-31 12:44 ` Szabolcs Nagy
2012-12-31 20:49   ` [PATCH] Re: strverscmp (Was: Re: lshw FTBFS: res_querydomain...) Isaac Dunham
2012-12-31 18:06 ` lshw FTBFS: res_querydomain declared but not implemented Rich Felker
2012-12-31 20:03   ` Isaac Dunham [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20121231120334.05263f66.idunham@lavabit.com \
    --to=idunham@lavabit.com \
    --cc=musl@lists.openwall.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).