Hi, Jim
Thsnk you for your reply.
src/network_conf.c defines #include <arpa/inet.h>.
The error message says the link does not exist.
So I think it should add inet_pton.c to Makefile
Is my understanding incorrect?
By the way,
I added sys/stat.h to domain_conf.c.
It solves the missing definition of S_IRUSR, S_IWUSR.
Thanks
Atsushi SAKAI
Jim Meyering <jim(a)meyering.net> wrote:
Atsushi SAKAI <sakaia(a)jp.fujitsu.com> wrote:
> I have a question about inet_pton().
> I try to compile libvirt on MinGW after some modification.
> The error message says follows.
> C:/msys/1.0/home/sakaia/work/libvirt/src/network_conf.c:290: undefined reference to
`inet_pton'
> C:/msys/1.0/home/sakaia/work/libvirt/src/network_conf.c:296: undefined reference to
`inet_pton'
Thanks for the report.
When the system does not declare inet_pton,
gnulib arranges for it to be in gnulib/lib/arpa/inet.h.
Since network_conf.c does include <arpa/inet.h>, and -I
directives point to the containing directory, it should
use that file.
Please run "make distclean" (or start from a fresh checkout), then run
the usual ./autogen.sh command, to ensure that you don't have any stale,
generated files. If the problem persists, please post the contents of
the generated gnulib/lib/arpa/inet.h.