build: fix build without numactl

Under ./configure --without-numactl but with numactl-devel installed,
the build fails with:

../../src/util/virnuma.c: In function 'virNumaNodeIsAvailable':
../../src/util/virnuma.c:407:5: error: implicit declaration of function 'numa_bitmask_isbitset' [-Werror=implicit-function-declaration]
     return numa_bitmask_isbitset(numa_nodes_ptr, node);
     ^

and other failures, all because the configure results for particular
functions were used without regard to whether libnuma was even being
linked in.

* src/util/virnuma.c (virNumaGetPages): Fix message typo.
(virNumaNodeIsAvailable): Correct build when not using numactl.

Signed-off-by: Eric Blake <eblake@redhat.com>
This commit is contained in:
Eric Blake 2014-07-21 11:24:21 -06:00
parent 53939d58cb
commit 72823b4443

View File

@ -390,7 +390,7 @@ virNumaGetMaxCPUs(void)
}
#ifdef HAVE_NUMA_BITMASK_ISBITSET
#if WITH_NUMACTL && HAVE_NUMA_BITMASK_ISBITSET
/**
* virNumaNodeIsAvailable:
* @node: node to check
@ -485,7 +485,7 @@ virNumaGetDistances(int node ATTRIBUTE_UNUSED,
{
*distances = NULL;
*ndistances = 0;
VIR_DEBUG("NUMA distance information isn't availble on this host");
VIR_DEBUG("NUMA distance information isn't available on this host");
return 0;
}
#endif