unofficial mirror of guile-devel@gnu.org 
 help / color / mirror / Atom feed
* Debian package build problems with 2.0.9 (from git)
@ 2013-06-15 18:06 Rob Browning
  2013-06-15 20:47 ` Ludovic Courtès
  2013-06-16  0:22 ` Daniel Hartwig
  0 siblings, 2 replies; 7+ messages in thread
From: Rob Browning @ 2013-06-15 18:06 UTC (permalink / raw)
  To: guile-devel


It looks like the newer libgc is headed for unstable, and I'm working on
the Debian packages for 2.0.9, where I've run into a couple of problems.

The first might be a problem caused by my packaging, but in case not,
the build from git fails because doc/ref/effective-version.texi doesn't
exist when it tries to build guile.info.  Here's how I fixed that for
now in doc/ref/Makefile.am:

  -guile.texi: libguile-autoconf.texi
  +guile.texi: effective-version.texi libguile-autoconf.texi

The second problem is that the net-db.test is failing:

  Running net-db.test
  unexpected error code: -11 "System error"
  FAIL: net-db.test: getaddrinfo: no name

But it looks like at least on my current (Debian unstable) system,
that may be the normal behavior.  This program:

  #include <errno.h>
  #include <netdb.h>
  #include <stdio.h>
  #include <string.h>

  int
  main(int argc, char **argv)
  {
    struct addrinfo c_hints, *c_result;

    memset(&c_hints, 0, sizeof (c_hints));
    const int err = getaddrinfo ("does-not-exist",
                                 NULL,
                                 &c_hints,
                                 &c_result);
    if (err == 0)
      freeaddrinfo (c_result);

    printf("err: %d\n", err);
    printf("errno: %d\n", errno);

    return 0;
  }

Produces this output:

  $ ./foo
  err: -11
  errno: 2

So I'm wondering if there's a problem with my test code, my system, or
if the test might need another exception here:

            (and (or (= errcode EAI_NONAME)
                     (and (defined? 'EAI_NODATA)  ; GNU extension
                          (= errcode EAI_NODATA))
                     (= errcode EAI_AGAIN)

Thanks
-- 
Rob Browning
rlb @defaultvalue.org and @debian.org
GPG as of 2011-07-10 E6A9 DA3C C9FD 1FF8 C676 D2C4 C0F0 39E9 ED1B 597A
GPG as of 2002-11-03 14DD 432F AE39 534D B592 F9A0 25C8 D377 8C7E 73A4



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

* Re: Debian package build problems with 2.0.9 (from git)
  2013-06-15 18:06 Debian package build problems with 2.0.9 (from git) Rob Browning
@ 2013-06-15 20:47 ` Ludovic Courtès
  2013-06-15 21:28   ` Rob Browning
  2013-06-16  0:22 ` Daniel Hartwig
  1 sibling, 1 reply; 7+ messages in thread
From: Ludovic Courtès @ 2013-06-15 20:47 UTC (permalink / raw)
  To: Rob Browning; +Cc: guile-devel

Rob Browning <rlb@defaultvalue.org> skribis:

> The first might be a problem caused by my packaging, but in case not,
> the build from git fails because doc/ref/effective-version.texi doesn't
> exist when it tries to build guile.info.

guile.info normally doesn’t need to be built when using the tarball.
However, this wasn’t the case until a9ea4f909b9970c755b0a7c4cd9da907e66496fc.

> The second problem is that the net-db.test is failing:
>
>   Running net-db.test
>   unexpected error code: -11 "System error"
>   FAIL: net-db.test: getaddrinfo: no name
>
> But it looks like at least on my current (Debian unstable) system,
> that may be the normal behavior.  This program:
>
>   #include <errno.h>
>   #include <netdb.h>
>   #include <stdio.h>
>   #include <string.h>
>
>   int
>   main(int argc, char **argv)
>   {
>     struct addrinfo c_hints, *c_result;
>
>     memset(&c_hints, 0, sizeof (c_hints));
>     const int err = getaddrinfo ("does-not-exist",
>                                  NULL,
>                                  &c_hints,
>                                  &c_result);
>     if (err == 0)
>       freeaddrinfo (c_result);
>
>     printf("err: %d\n", err);
>     printf("errno: %d\n", errno);
>
>     return 0;
>   }
>
> Produces this output:
>
>   $ ./foo
>   err: -11
>   errno: 2

(Where 2 is ENOENT.)

Quoting http://debbugs.gnu.org/cgi/bugreport.cgi?bug=13958#8 :

  [T]here are only two occurrences of EAI_SYSTEM in inet/getaddrinfo.c
  in glibc: one is for NETDB_INTERNAL, and the other is for
  IDNA_DLOPEN_ERROR.

Most likely, that means that one of the NSS modules specified in
/etc/nsswitch.conf could not be loaded.

Could you strace the C program above and check what happens?

TIA,
Ludo’.



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

* Re: Debian package build problems with 2.0.9 (from git)
  2013-06-15 20:47 ` Ludovic Courtès
@ 2013-06-15 21:28   ` Rob Browning
  2013-06-15 22:21     ` Ludovic Courtès
  0 siblings, 1 reply; 7+ messages in thread
From: Rob Browning @ 2013-06-15 21:28 UTC (permalink / raw)
  To: Ludovic Courtès; +Cc: guile-devel

ludo@gnu.org (Ludovic Courtès) writes:

> guile.info normally doesn’t need to be built when using the tarball.
> However, this wasn’t the case until a9ea4f909b9970c755b0a7c4cd9da907e66496fc.

Right.  I was asking about the case of building from git -- there I'm
using ./autogen.sh.  Is that not sufficient?

In any case, for now, the patch I posted handles the problem.

> (Where 2 is ENOENT.)
>
> Quoting http://debbugs.gnu.org/cgi/bugreport.cgi?bug=13958#8 :
>
>   [T]here are only two occurrences of EAI_SYSTEM in inet/getaddrinfo.c
>   in glibc: one is for NETDB_INTERNAL, and the other is for
>   IDNA_DLOPEN_ERROR.
>
> Most likely, that means that one of the NSS modules specified in
> /etc/nsswitch.conf could not be loaded.

Here's the nsswitch.conf:

  passwd:         compat
  group:          compat
  shadow:         compat

  hosts:          files mdns4_minimal [NOTFOUND=return] dns mdns4
  networks:       files

  protocols:      db files
  services:       db files
  ethers:         db files
  rpc:            db files

  netgroup:       nis

> Could you strace the C program above and check what happens?

  $ strace -f -p ./foo
  ...
  27725 open("/lib/libnss_mdns4.so.2", O_RDONLY|O_CLOEXEC) = 3
  27725 read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\340\v\0\0\0\0\0\0"..., 832) = 832
  27725 fstat(3, {st_mode=S_IFREG|0644, st_size=10880, ...}) = 0
  27725 mmap(NULL, 2106096, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7f3717b7f000
  27725 mprotect(0x7f3717b81000, 2097152, PROT_NONE) = 0
  27725 mmap(0x7f3717d81000, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x2000) = 0x7f3717d81000
  27725 close(3)                          = 0
  27725 munmap(0x7f3718b48000, 203786)    = 0
  27725 open("/etc/mdns.allow", O_RDONLY) = -1 ENOENT (No such file or directory)
  27725 fstat(1, {st_mode=S_IFCHR|0620, st_rdev=makedev(136, 1), ...}) = 0
  27725 mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7f3718b79000
  27725 write(1, "  err: -11\n", 11)      = 11
  27725 write(1, "errno: 2\n", 9)         = 9
  27725 exit_group(0)                     = ?

Hope this helps, and thanks.
-- 
Rob Browning
rlb @defaultvalue.org and @debian.org
GPG as of 2011-07-10 E6A9 DA3C C9FD 1FF8 C676 D2C4 C0F0 39E9 ED1B 597A
GPG as of 2002-11-03 14DD 432F AE39 534D B592 F9A0 25C8 D377 8C7E 73A4



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

* Re: Debian package build problems with 2.0.9 (from git)
  2013-06-15 21:28   ` Rob Browning
@ 2013-06-15 22:21     ` Ludovic Courtès
  2013-06-16 15:18       ` Ludovic Courtès
  0 siblings, 1 reply; 7+ messages in thread
From: Ludovic Courtès @ 2013-06-15 22:21 UTC (permalink / raw)
  To: Rob Browning; +Cc: guile-devel

Rob Browning <rlb@defaultvalue.org> skribis:

>   $ strace -f -p ./foo
>   ...
>   27725 open("/lib/libnss_mdns4.so.2", O_RDONLY|O_CLOEXEC) = 3
>   27725 read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\340\v\0\0\0\0\0\0"..., 832) = 832
>   27725 fstat(3, {st_mode=S_IFREG|0644, st_size=10880, ...}) = 0
>   27725 mmap(NULL, 2106096, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7f3717b7f000
>   27725 mprotect(0x7f3717b81000, 2097152, PROT_NONE) = 0
>   27725 mmap(0x7f3717d81000, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x2000) = 0x7f3717d81000
>   27725 close(3)                          = 0
>   27725 munmap(0x7f3718b48000, 203786)    = 0
>   27725 open("/etc/mdns.allow", O_RDONLY) = -1 ENOENT (No such file or directory)
>   27725 fstat(1, {st_mode=S_IFCHR|0620, st_rdev=makedev(136, 1), ...}) = 0
>   27725 mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7f3718b79000
>   27725 write(1, "  err: -11\n", 11)      = 11
>   27725 write(1, "errno: 2\n", 9)         = 9
>   27725 exit_group(0)                     = ?

Here requests take place in the program, rather than going through nscd.

I just tried (with glibc 2.17) and indeed, I get EAI_SYSTEM when nscd is
*not* running, and EAI_NONAME when nscd is running.

I believe the former is a bug, and I reported it at
<http://sourceware.org/bugzilla/show_bug.cgi?id=15635>.  Let’s see...

Thanks!

Ludo’.



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

* Re: Debian package build problems with 2.0.9 (from git)
  2013-06-15 18:06 Debian package build problems with 2.0.9 (from git) Rob Browning
  2013-06-15 20:47 ` Ludovic Courtès
@ 2013-06-16  0:22 ` Daniel Hartwig
  2013-06-16  4:52   ` Rob Browning
  1 sibling, 1 reply; 7+ messages in thread
From: Daniel Hartwig @ 2013-06-16  0:22 UTC (permalink / raw)
  To: Rob Browning; +Cc: guile-devel

On 16 June 2013 02:06, Rob Browning <rlb@defaultvalue.org> wrote:
>
> It looks like the newer libgc is headed for unstable, and I'm working on
> the Debian packages for 2.0.9, where I've run into a couple of problems.
>
> The first might be a problem caused by my packaging, but in case not,
> the build from git fails because doc/ref/effective-version.texi doesn't
> exist when it tries to build guile.info.  Here's how I fixed that for
> now in doc/ref/Makefile.am:

Hi Rob

Not really related to your build failure, but now that the docs do not
need to be separated I really think you should use the upstream
tarball for packaging.



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

* Re: Debian package build problems with 2.0.9 (from git)
  2013-06-16  0:22 ` Daniel Hartwig
@ 2013-06-16  4:52   ` Rob Browning
  0 siblings, 0 replies; 7+ messages in thread
From: Rob Browning @ 2013-06-16  4:52 UTC (permalink / raw)
  To: Daniel Hartwig; +Cc: guile-devel

Daniel Hartwig <mandyke@gmail.com> writes:

> Not really related to your build failure, but now that the docs do not
> need to be separated I really think you should use the upstream
> tarball for packaging.

I may eventually, but if I do, I can't nearly as easily cherry-pick
patches, or update to a new release.

It's quite handy to be able to use normal git commands with respect to
upstream development.

(And for anyone remotely interested -- I use git-dpm -- many thanks to
 Bernhard.)

Thanks
-- 
Rob Browning
rlb @defaultvalue.org and @debian.org
GPG as of 2011-07-10 E6A9 DA3C C9FD 1FF8 C676 D2C4 C0F0 39E9 ED1B 597A
GPG as of 2002-11-03 14DD 432F AE39 534D B592 F9A0 25C8 D377 8C7E 73A4



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

* Re: Debian package build problems with 2.0.9 (from git)
  2013-06-15 22:21     ` Ludovic Courtès
@ 2013-06-16 15:18       ` Ludovic Courtès
  0 siblings, 0 replies; 7+ messages in thread
From: Ludovic Courtès @ 2013-06-16 15:18 UTC (permalink / raw)
  To: guile-devel

ludo@gnu.org (Ludovic Courtès) skribis:

> I just tried (with glibc 2.17) and indeed, I get EAI_SYSTEM when nscd is
> *not* running, and EAI_NONAME when nscd is running.
>
> I believe the former is a bug, and I reported it at
> <http://sourceware.org/bugzilla/show_bug.cgi?id=15635>.  Let’s see...

Was already fixed:
<http://sourceware.org/bugzilla/show_bug.cgi?id=15339#c1>.

Ludo’.




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

end of thread, other threads:[~2013-06-16 15:18 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-06-15 18:06 Debian package build problems with 2.0.9 (from git) Rob Browning
2013-06-15 20:47 ` Ludovic Courtès
2013-06-15 21:28   ` Rob Browning
2013-06-15 22:21     ` Ludovic Courtès
2013-06-16 15:18       ` Ludovic Courtès
2013-06-16  0:22 ` Daniel Hartwig
2013-06-16  4:52   ` Rob Browning

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 read-only IMAP folder(s) and NNTP newsgroup(s).