Activate build dir overrides in libvirtd, virtlockd, virsh & tests

Add calls to virFileActivateDirOverride so that the build dir
overrides are activated.

Signed-off-by: Daniel P. Berrange <berrange@redhat.com>
This commit is contained in:
Daniel P. Berrange 2014-04-24 15:57:36 +01:00
parent 63a92e7220
commit 391ac4d990
4 changed files with 8 additions and 0 deletions

View File

@ -1156,6 +1156,8 @@ int main(int argc, char **argv) {
virUpdateSelfLastChanged(argv[0]);
virFileActivateDirOverride(argv[0]);
if (strstr(argv[0], "lt-libvirtd") ||
strstr(argv[0], "/daemon/.libs/libvirtd")) {
char *tmp = strrchr(argv[0], '/');

View File

@ -1271,6 +1271,8 @@ int main(int argc, char **argv) {
}
}
virFileActivateDirOverride(argv[0]);
if (!(config = virLockDaemonConfigNew(privileged))) {
VIR_ERROR(_("Can't create initial configuration"));
exit(EXIT_FAILURE);

View File

@ -678,6 +678,8 @@ int virtTestMain(int argc,
char *oomstr;
#endif
virFileActivateDirOverride(argv[0]);
if (!virFileExists(abs_srcdir))
return EXIT_AM_HARDFAIL;

View File

@ -3594,6 +3594,8 @@ main(int argc, char **argv)
return EXIT_FAILURE;
}
virFileActivateDirOverride(argv[0]);
if (!(progname = strrchr(argv[0], '/')))
progname = argv[0];
else