----- "Justin Clift" <jclift@xxxxxxxxxx> wrote: > From: "Justin Clift" <jclift@xxxxxxxxxx> > To: "Libvirt Developers Mailing List" <libvir-list@xxxxxxxxxx> > Sent: Wednesday, September 15, 2010 7:42:48 AM GMT +08:00 Beijing / Chongqing / Hong Kong / Urumqi > Subject: OSX 10.6 build failures > > Hi us, > > Going through the process of getting libvirt to compile on OSX, making > > notes of the failures on the way through (from a clean system) to be > fixed. > > a) libtool -> glibtool > libtoolize -> glibtoolize > > It turns out that autogen.sh is hard coded to use "libtool", and > wants the GNU version. > > OSX supplies has it's own version, without a --version option, so > autogen.sh fails. > > Installing GNU libtool through MacPorts, makes it available as > glibtool, with libtoolize being glibtoolize. > > Adjusting autogen.sh to detect that, then set LIBTOOL and > LIBTOOLIZE > appropriately was fairly trivial. > > Will submit a patch to fix that in a bit. > > > b) pkg-config > > The next thing to barf was autoconf, complaining about > AC_MSG_ERROR > not being a defined macro. > > Googling with some persistence showed this is caused by > pkg-config > not being installed. Fixed that. > > Will submit a patch for that too. Probably "pkg-config > --version" > based, copying the approach used for the other autogen.sh checks. > > > c) This is a compilation failure, one I don't readily know how to > fix: > > ... > Making all in src > make all-am > CC libvirt_util_la-network.lo > util/network.c: In function 'getIPv6Addr': > util/network.c:50: error: 'struct in6_addr' has no member named > 's6_addr16' > util/network.c:50: error: 'struct in6_addr' has no member named > 's6_addr16' > util/network.c:50: error: 'struct in6_addr' has no member named > 's6_addr16' > util/network.c:50: error: 'struct in6_addr' has no member named > 's6_addr16' > make[3]: *** [libvirt_util_la-network.lo] Error 1 > make[2]: *** [all] Error 2 > make[1]: *** [all-recursive] Error 1 > make: *** [all] Error 2 > $ > > They're the only problems so far, though most things have been > disabled > on the ./configure line so it's only the client libraries being > built. > > Anyone know how to address that third one? > % man ipv6 Address Format struct sockaddr_in6 { sa_family_t sin6_family; /* AF_INET6 */ in_port_t sin6_port; /* port number */ uint32_t sin6_flowinfo; /* IPv6 flow information */ struct in6_addr sin6_addr; /* IPv6 address */ uint32_t sin6_scope_id; /* Scope ID (new in 2.4) */ }; struct in6_addr { unsigned char s6_addr[16]; /* IPv6 address */ }; % vim libvirt/src/util/network.c 43 static int getIPv6Addr(virSocketAddrPtr addr, virIPv6AddrPtr tab) { 44 int i; 45 46 if ((addr == NULL) || (tab == NULL) || (addr->stor.ss_family != AF_INET6 )) 47 return(-1); 48 49 for (i = 0;i < 8;i++) { 50 (*tab)[i] = ntohs(addr->inet6.sin6_addr.s6_addr16[i]); 51 } 52 53 return(0); 54 } I guess it's a typo, should be "addr->inet6.sin6_addr.s6_addr[i]", but not "addr->inet6.sin6_addr.s6_addr16[i]".. :-) - Osier > Regards and best wishes, > > Justin Clift > > -- > libvir-list mailing list > libvir-list@xxxxxxxxxx > https://www.redhat.com/mailman/listinfo/libvir-list -- libvir-list mailing list libvir-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/libvir-list