# old automake does not provide abs_{src,build}dir variables
abs_builddir = $(shell pwd)
-abs_topbuilddir = $(shell cd .. && pwd)
+abs_top_builddir = $(shell cd .. && pwd)
abs_srcdir = $(shell cd $(srcdir) && pwd)
-abs_topsrcdir = $(shell cd $(top_srcdir) && pwd)
+abs_top_srcdir = $(shell cd $(top_srcdir) && pwd)
# No libraries with the exception of LIBXML should be listed
# here. List them against the individual XXX_la_CFLAGS targets
-I$(srcdir)/util \
-I./util \
-DIN_LIBVIRT \
- -Dabs_topbuilddir="\"$(abs_topbuilddir)\"" \
- -Dabs_topsrcdir="\"$(abs_topsrcdir)\"" \
+ -Dabs_top_builddir="\"$(abs_top_builddir)\"" \
+ -Dabs_top_srcdir="\"$(abs_top_srcdir)\"" \
$(NULL)
WARN_CFLAGS += $(STRICT_FRAME_LIMIT_CFLAGS)
VIR_AUTOFREE(char *) schema = NULL;
schema = virFileFindResource("domain.rng",
- abs_topsrcdir "/docs/schemas",
+ abs_top_srcdir "/docs/schemas",
PKGDATADIR "/schemas");
if (!schema)
return NULL;
char *mapfile;
if (!(mapfile = virFileFindResource(filename,
- abs_topsrcdir "/src/cpu_map",
+ abs_top_srcdir "/src/cpu_map",
PKGDATADIR "/cpu_map")))
return -1;
char *mapfile;
if (!(mapfile = virFileFindResource("index.xml",
- abs_topsrcdir "/src/cpu_map",
+ abs_top_srcdir "/src/cpu_map",
PKGDATADIR "/cpu_map")))
return -1;
if (!(modfile = virFileFindResourceFull(name,
"libvirt_driver_",
".so",
- abs_topbuilddir "/src/.libs",
+ abs_top_builddir "/src/.libs",
DEFAULT_DRIVER_DIR,
"LIBVIRT_DRIVER_DIR")))
return -1;
if (!privileged &&
!(daemonPath = virFileFindResourceFull("virtlockd",
NULL, NULL,
- abs_topbuilddir "/src",
+ abs_top_builddir "/src",
SBINDIR,
"VIRTLOCKD_PATH")))
goto error;
if (!(modfile = virFileFindResourceFull(name,
NULL,
".so",
- abs_topbuilddir "/src/.libs",
+ abs_top_builddir "/src/.libs",
LIBDIR "/libvirt/lock-driver",
"LIBVIRT_LOCK_MANAGER_PLUGIN_DIR")))
goto cleanup;
if (!privileged &&
!(daemonPath = virFileFindResourceFull("virtlogd",
NULL, NULL,
- abs_topbuilddir "/src",
+ abs_top_builddir "/src",
SBINDIR,
"VIRTLOGD_PATH")))
goto error;
}
if (!(lxc_path = virFileFindResource("libvirt_lxc",
- abs_topbuilddir "/src",
+ abs_top_builddir "/src",
LIBEXECDIR)))
goto error;
/* This helper is used to create custom leases file for libvirt */
if (!(leaseshelper_path = virFileFindResource("libvirt_leaseshelper",
- abs_topbuilddir "/src",
+ abs_top_builddir "/src",
LIBEXECDIR)))
goto cleanup;
if ((flags & VIR_DRV_OPEN_REMOTE_AUTOSTART) &&
!(daemonPath = virFileFindResourceFull("libvirtd",
NULL, NULL,
- abs_topbuilddir "/src",
+ abs_top_builddir "/src",
SBINDIR,
"LIBVIRTD_PATH")))
goto failed;
if (!(modfile = virFileFindResourceFull(name,
"libvirt_storage_backend_",
".so",
- abs_topbuilddir "/src/.libs",
+ abs_top_builddir "/src/.libs",
STORAGE_BACKEND_MODULE_DIR,
"LIBVIRT_STORAGE_BACKEND_DIR")))
return -1;
VIR_AUTOPTR(virCommand) cmd = NULL;
if (!(parthelper_path = virFileFindResource("libvirt_parthelper",
- abs_topbuilddir "/src",
+ abs_top_builddir "/src",
LIBEXECDIR)))
return -1;
VIR_AUTOPTR(virCommand) cmd = NULL;
if (!(parthelper_path = virFileFindResource("libvirt_parthelper",
- abs_topbuilddir "/src",
+ abs_top_builddir "/src",
LIBEXECDIR)))
return -1;
}
if (!(iohelper_path = virFileFindResource("libvirt_iohelper",
- abs_topbuilddir "/src",
+ abs_top_builddir "/src",
LIBEXECDIR)))
goto error;
* @prefix: optional string to prepend to filename
* @suffix: optional string to append to filename
* @builddir: location of the filename in the build tree including
- * abs_topsrcdir or abs_topbuilddir prefix
+ * abs_top_srcdir or abs_top_builddir prefix
* @installdir: location of the installed binary
* @envname: environment variable used to override all dirs
*
if (!(modfile = virFileFindResourceFull(name,
"libvirt_storage_file_",
".so",
- abs_topbuilddir "/src/.libs",
+ abs_top_builddir "/src/.libs",
STORAGE_FILE_MODULE_DIR,
"LIBVIRT_STORAGE_FILE_DIR")))
return -1;
# old automake does not provide abs_{src,build}dir variables
abs_builddir = $(shell pwd)
-abs_topbuilddir = $(shell cd .. && pwd)
+abs_top_builddir = $(shell cd .. && pwd)
abs_srcdir = $(shell cd $(srcdir) && pwd)
-abs_topsrcdir = $(shell cd $(top_srcdir) && pwd)
+abs_top_srcdir = $(shell cd $(top_srcdir) && pwd)
SHELL = $(PREFERABLY_POSIX_SHELL)
AM_CFLAGS = \
-Dabs_builddir="\"$(abs_builddir)\"" \
- -Dabs_topbuilddir="\"$(abs_topbuilddir)\"" \
+ -Dabs_top_builddir="\"$(abs_top_builddir)\"" \
-Dabs_srcdir="\"$(abs_srcdir)\"" \
- -Dabs_topsrcdir="\"$(abs_topsrcdir)\"" \
+ -Dabs_top_srcdir="\"$(abs_top_srcdir)\"" \
$(LIBXML_CFLAGS) \
$(LIBNL_CFLAGS) \
$(GNUTLS_CFLAGS) \
int ret = -1;
if (virAsprintf(&schema_path, "%s/docs/schemas/%s",
- abs_topsrcdir, data->schema) < 0)
+ abs_top_srcdir, data->schema) < 0)
return -1;
if (!(data->validator = virXMLValidatorInit(schema_path)))
return result;
}
-# define VIRSH_DEFAULT abs_topbuilddir "/tools/virsh", \
+# define VIRSH_DEFAULT abs_top_builddir "/tools/virsh", \
"--connect", \
"test:///default"
static char *custom_uri;
-# define VIRSH_CUSTOM abs_topbuilddir "/tools/virsh", \
+# define VIRSH_CUSTOM abs_top_builddir "/tools/virsh", \
"--connect", \
custom_uri
}
- if (!STRPREFIX(path, abs_topsrcdir) &&
- !STRPREFIX(path, abs_topbuilddir)) {
+ if (!STRPREFIX(path, abs_top_srcdir) &&
+ !STRPREFIX(path, abs_top_builddir)) {
printFile(path, func);
}