[libvirt] [PATCH] maint: update to latest gnulib
by Eric Blake
Incorporates fixes for cross-compiling to mingw on rawhide, where
gcc 5.1 changes detection of how to properly determine PRIdMAX.
* .gnulib: Update to latest, for mingw.
Signed-off-by: Eric Blake <eblake(a)redhat.com>
---
I've missed the freeze for rc1, but confirmed that this update
is rather minimal and should only affect mingw (in particular, it
will fix cross-compilation failure under rawhide with gcc 5.1).
As such, I won't push without review, but I also argue that the
changeset is small enough that it should be safe if we agree to
take it before rc2.
* .gnulib 875ec93...c26527c (5):
> stdio: limit __gnu_printf__ witness to gcc 4.4+
> error: use correct printf attributes on mingw
> update from texinfo
> inttypes: force correct mingw PRIdMAX even without <stdio.h>
> stdio: fix probe on mingw under gcc 5.1
.gnulib | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/.gnulib b/.gnulib
index 875ec93..c26527c 160000
--- a/.gnulib
+++ b/.gnulib
@@ -1 +1 @@
-Subproject commit 875ec93e1501d2d2a8bab1b64fa66b8ceb51dc67
+Subproject commit c26527cebbbf42ed1dbc50df0074861e0ebe33dc
--
2.1.0
9 years, 7 months
[libvirt] [PATCH] spec: fixes for recently introduced libxl conf files
by Jim Fehlig
Commit 198cc1d3 introduced libxl-lockd and libxl-sanlock config
files but forgot to add them to the spec file. Follow-up commit
62b18d98 added the files to daemon-driver-libxl, but missed adding
them to the daemon package when configuring libvirt
--without-driver-modules. In addition, commit 62b18d98 added
libxl-sanlock to daemon-driver-libxl, but it should be included
in lock-sanlock when libvirt is configured --with-sanlock.
Signed-off-by: Jim Fehlig <jfehlig(a)suse.com>
---
Given the problems I've caused with the original commit 198cc1d3,
I'm reluctant to push this as a build-breaker without another
set of eyes reviewing it.
libvirt.spec.in | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/libvirt.spec.in b/libvirt.spec.in
index f95e31f..0c343d6 100644
--- a/libvirt.spec.in
+++ b/libvirt.spec.in
@@ -2007,6 +2007,7 @@ exit 0
%endif
%if %{with_libxl}
%config(noreplace) %{_sysconfdir}/libvirt/libxl.conf
+%config(noreplace) %{_sysconfdir}/libvirt/libxl-lockd.conf
%dir %attr(0700, root, root) %{_localstatedir}/log/libvirt/libxl/
%ghost %dir %{_localstatedir}/run/libvirt/libxl/
%dir %attr(0700, root, root) %{_localstatedir}/lib/libvirt/libxl/
@@ -2130,7 +2131,6 @@ exit 0
%defattr(-, root, root)
%config(noreplace) %{_sysconfdir}/libvirt/libxl.conf
%config(noreplace) %{_sysconfdir}/libvirt/libxl-lockd.conf
-%config(noreplace) %{_sysconfdir}/libvirt/libxl-sanlock.conf
%{_datadir}/augeas/lenses/libvirtd_libxl.aug
%{_datadir}/augeas/lenses/tests/test_libvirtd_libxl.aug
%dir %attr(0700, root, root) %{_localstatedir}/log/libvirt/libxl/
@@ -2183,6 +2183,9 @@ exit 0
%if %{with_qemu}
%config(noreplace) %{_sysconfdir}/libvirt/qemu-sanlock.conf
%endif
+ %if %{with_libxl}
+%config(noreplace) %{_sysconfdir}/libvirt/libxl-sanlock.conf
+ %endif
%attr(0755, root, root) %{_libdir}/libvirt/lock-driver/sanlock.so
%{_datadir}/augeas/lenses/libvirt_sanlock.aug
%{_datadir}/augeas/lenses/tests/test_libvirt_sanlock.aug
--
1.8.4.5
9 years, 7 months
[libvirt] [PATCH v2] libxl: load on FreeBSD
by Roman Bogorodskiy
The libxl tries to check if it's running in dom0 by parsing
/proc/xen/capabilities and if that fails it doesn't load.
There's no procfs interface in Xen on FreeBSD, so this check always
fails.
In addition to checking procfs, check if /dev/xen/xenstored, that's enough to
check if we're running in dom0 in FreeBSD case.
---
src/libxl/libxl_driver.c | 42 ++++++++++++++++++++++--------------------
1 file changed, 22 insertions(+), 20 deletions(-)
diff --git a/src/libxl/libxl_driver.c b/src/libxl/libxl_driver.c
index 12be816..fddafa1 100644
--- a/src/libxl/libxl_driver.c
+++ b/src/libxl/libxl_driver.c
@@ -74,6 +74,7 @@ VIR_LOG_INIT("libxl.libxl_driver");
#define LIBXL_CONFIG_FORMAT_SEXPR "xen-sxpr"
#define HYPERVISOR_CAPABILITIES "/proc/xen/capabilities"
+#define HYPERVISOR_XENSTORED "/dev/xen/xenstored"
/* Number of Xen scheduler parameters */
#define XEN_SCHED_CREDIT_NPARAM 2
@@ -427,8 +428,6 @@ static bool
libxlDriverShouldLoad(bool privileged)
{
bool ret = false;
- int status;
- char *output = NULL;
/* Don't load if non-root */
if (!privileged) {
@@ -436,24 +435,27 @@ libxlDriverShouldLoad(bool privileged)
return ret;
}
- if (!virFileExists(HYPERVISOR_CAPABILITIES)) {
- VIR_INFO("Disabling driver as " HYPERVISOR_CAPABILITIES
- " does not exist");
- return ret;
- }
- /*
- * Don't load if not running on a Xen control domain (dom0). It is not
- * sufficient to check for the file to exist as any guest can mount
- * xenfs to /proc/xen.
- */
- status = virFileReadAll(HYPERVISOR_CAPABILITIES, 10, &output);
- if (status >= 0)
- status = strncmp(output, "control_d", 9);
- VIR_FREE(output);
- if (status) {
- VIR_INFO("No Xen capabilities detected, probably not running "
- "in a Xen Dom0. Disabling libxenlight driver");
-
+ if (virFileExists(HYPERVISOR_CAPABILITIES)) {
+ int status;
+ char *output = NULL;
+ /*
+ * Don't load if not running on a Xen control domain (dom0). It is not
+ * sufficient to check for the file to exist as any guest can mount
+ * xenfs to /proc/xen.
+ */
+ status = virFileReadAll(HYPERVISOR_CAPABILITIES, 10, &output);
+ if (status >= 0)
+ status = strncmp(output, "control_d", 9);
+ VIR_FREE(output);
+ if (status) {
+ VIR_INFO("No Xen capabilities detected, probably not running "
+ "in a Xen Dom0. Disabling libxenlight driver");
+
+ return ret;
+ }
+ } else if (!virFileExists(HYPERVISOR_XENSTORED)) {
+ VIR_INFO("Disabling driver as neither " HYPERVISOR_CAPABILITIES
+ " nor " HYPERVISOR_CAPABILITIES " exist");
return ret;
}
--
2.3.7
9 years, 7 months
[libvirt] [PATCH v3 0/3] qemu: Deal with panic device on pSeries
by Andrea Bolognani
Currently, having the <panic> element in a domain XML prevents it from
starting on pSeries. The error message in this case is not very accurate,
and the first commit improves it.
Since the guest firmware provides the same features as the pvpanic
device for pSeries guests, the element should be allowed. The second
commit implements this change.
It being part of the firmware, the <panic> element should actually
always be present in the domain XML: the third commit makes sure
this is the case.
Andrea Bolognani (3):
qemu: Improve error message for missing QEMU_CAPS_DEVICE_PANIC.
qemu: Allow panic device for pSeries guests
qemu: Automatically add <panic> element for pSeries guests.
docs/formatdomain.html.in | 8 ++++-
src/qemu/qemu_command.c | 34 ++++++++++++++++------
src/qemu/qemu_domain.c | 14 +++++++++
.../qemuxml2argvdata/qemuxml2argv-pseries-disk.xml | 1 +
.../qemuxml2argv-pseries-nvram.xml | 1 +
.../qemuxml2argv-pseries-panic-address.xml | 32 ++++++++++++++++++++
.../qemuxml2argv-pseries-panic-missing.args | 7 +++++
.../qemuxml2argv-pseries-panic-missing.xml | 29 ++++++++++++++++++
.../qemuxml2argv-pseries-panic-no-address.args | 7 +++++
.../qemuxml2argv-pseries-panic-no-address.xml | 30 +++++++++++++++++++
tests/qemuxml2argvtest.c | 6 ++++
.../qemuxml2xmlout-pseries-panic-missing.xml | 30 +++++++++++++++++++
tests/qemuxml2xmltest.c | 2 ++
13 files changed, 191 insertions(+), 10 deletions(-)
create mode 100644 tests/qemuxml2argvdata/qemuxml2argv-pseries-panic-address.xml
create mode 100644 tests/qemuxml2argvdata/qemuxml2argv-pseries-panic-missing.args
create mode 100644 tests/qemuxml2argvdata/qemuxml2argv-pseries-panic-missing.xml
create mode 100644 tests/qemuxml2argvdata/qemuxml2argv-pseries-panic-no-address.args
create mode 100644 tests/qemuxml2argvdata/qemuxml2argv-pseries-panic-no-address.xml
create mode 100644 tests/qemuxml2xmloutdata/qemuxml2xmlout-pseries-panic-missing.xml
--
2.1.0
9 years, 7 months
[libvirt] [PATCH] parallels: better support of volume based disks in containers
by Maxim Nestratov
It is possible to attach volumes to containers but since they are
added they are reported erroneously as filesystems. It is fixed
in this patch. And as soon as bus type has no meaning for containers
we always report SATA for such disks.
In case a container is created with the only disk based on physical
volume we are expected to specify mount point to be able to boot
from it, that is done in the patch.
Sygned-off-by: Maxim Nestratov <mnestratov(a)parallels.com>
---
.gnulib | 2 +-
src/parallels/parallels_sdk.c | 40 +++++++++++++++++++++++++++++++---------
2 files changed, 32 insertions(+), 10 deletions(-)
diff --git a/.gnulib b/.gnulib
index 875ec93..106a386 160000
--- a/.gnulib
+++ b/.gnulib
@@ -1 +1 @@
-Subproject commit 875ec93e1501d2d2a8bab1b64fa66b8ceb51dc67
+Subproject commit 106a3866d01f9dd57ab4f10dbeb0d5a8db73a9f7
diff --git a/src/parallels/parallels_sdk.c b/src/parallels/parallels_sdk.c
index 39c200a..9228bfb 100644
--- a/src/parallels/parallels_sdk.c
+++ b/src/parallels/parallels_sdk.c
@@ -452,7 +452,8 @@ prlsdkAddDomainVideoInfo(PRL_HANDLE sdkdom, virDomainDefPtr def)
static int
prlsdkGetDiskInfo(PRL_HANDLE prldisk,
virDomainDiskDefPtr disk,
- bool isCdrom)
+ bool isCdrom,
+ bool isCt)
{
char *buf = NULL;
PRL_UINT32 buflen = 0;
@@ -495,8 +496,13 @@ prlsdkGetDiskInfo(PRL_HANDLE prldisk,
if (virDomainDiskSetSource(disk, buf) < 0)
goto cleanup;
- pret = PrlVmDev_GetIfaceType(prldisk, &ifType);
- prlsdkCheckRetGoto(pret, cleanup);
+ /* Let physical devices added to CT look like SATA disks */
+ if (isCt)
+ ifType = PMS_SATA_DEVICE;
+ else {
+ pret = PrlVmDev_GetIfaceType(prldisk, &ifType);
+ prlsdkCheckRetGoto(pret, cleanup);
+ }
pret = PrlVmDev_GetStackIndex(prldisk, &pos);
prlsdkCheckRetGoto(pret, cleanup);
@@ -606,10 +612,16 @@ prlsdkAddDomainHardDisksInfo(PRL_HANDLE sdkdom, virDomainDefPtr def)
prlsdkCheckRetGoto(pret, error);
for (i = 0; i < hddCount; ++i) {
+
+ PRL_UINT32 emulatedType;
+
pret = PrlVmCfg_GetHardDisk(sdkdom, i, &hdd);
prlsdkCheckRetGoto(pret, error);
- if (IS_CT(def)) {
+ pret = PrlVmDev_GetEmulatedType(hdd, &emulatedType);
+ prlsdkCheckRetGoto(pret, error);
+
+ if (PDT_USE_REAL_DEVICE != emulatedType && IS_CT(def)) {
if (VIR_ALLOC(fs) < 0)
goto error;
@@ -627,7 +639,7 @@ prlsdkAddDomainHardDisksInfo(PRL_HANDLE sdkdom, virDomainDefPtr def)
if (!(disk = virDomainDiskDefNew(NULL)))
goto error;
- if (prlsdkGetDiskInfo(hdd, disk, false) < 0)
+ if (prlsdkGetDiskInfo(hdd, disk, false, IS_CT(def)) < 0)
goto error;
if (VIR_APPEND_ELEMENT(def->disks, def->ndisks, disk) < 0)
@@ -667,7 +679,7 @@ prlsdkAddDomainOpticalDisksInfo(PRL_HANDLE sdkdom, virDomainDefPtr def)
if (!(disk = virDomainDiskDefNew(NULL)))
goto error;
- if (prlsdkGetDiskInfo(cdrom, disk, true) < 0)
+ if (prlsdkGetDiskInfo(cdrom, disk, true, IS_CT(def)) < 0)
goto error;
PrlHandle_Free(cdrom);
@@ -2878,7 +2890,10 @@ static int prlsdkDelDisk(PRL_HANDLE sdkdom, int idx)
return ret;
}
-static int prlsdkAddDisk(PRL_HANDLE sdkdom, virDomainDiskDefPtr disk, bool bootDisk)
+static int prlsdkAddDisk(PRL_HANDLE sdkdom,
+ virDomainDiskDefPtr disk,
+ bool bootDisk,
+ bool isCt)
{
PRL_RESULT pret;
PRL_HANDLE sdkdisk = PRL_INVALID_HANDLE;
@@ -3039,6 +3054,13 @@ static int prlsdkAddDisk(PRL_HANDLE sdkdom, virDomainDiskDefPtr disk, bool bootD
if (prlsdkAddDeviceToBootList(sdkdom, devIndex, devType, 0) < 0)
goto cleanup;
+
+ /* If we add physical device as a boot disk to container
+ * we have to specify mount point for it */
+ if (isCt) {
+ pret = PrlVmDevHd_SetMountPoint(sdkdisk, "/");
+ prlsdkCheckRetGoto(pret, cleanup);
+ }
}
return 0;
@@ -3059,7 +3081,7 @@ prlsdkAttachVolume(virDomainObjPtr dom, virDomainDiskDefPtr disk)
if (PRL_FAILED(waitJob(job)))
goto cleanup;
- ret = prlsdkAddDisk(privdom->sdkdom, disk, false);
+ ret = prlsdkAddDisk(privdom->sdkdom, disk, false, IS_CT(dom->def));
if (ret == 0) {
job = PrlVm_CommitEx(privdom->sdkdom, PVCF_DETACH_HDD_BUNDLE);
if (PRL_FAILED(waitJob(job))) {
@@ -3282,7 +3304,7 @@ prlsdkDoApplyConfig(virConnectPtr conn,
needBoot = false;
bootDisk = true;
}
- if (prlsdkAddDisk(sdkdom, def->disks[i], bootDisk) < 0)
+ if (prlsdkAddDisk(sdkdom, def->disks[i], bootDisk, IS_CT(def)) < 0)
goto error;
}
--
2.1.0
9 years, 7 months
[libvirt] [PATCHv2] qemu: fix unsuitable error report when get memory stats
by Wang Yufei
From: Zhang Bo <oscar.zhangbo(a)huawei.com>
when we run the command 'virsh dommemstat xxx',
althrough memballoon's model is set 'none' in vm's XML,
it still reports an error in libvirtd.log.
error : qemuMonitorFindBalloonObjectPath:1042 : internal error: Cannot determine balloon device path
Apparently, if we don't set memballoon, we don't need to
set balloon device path.
Signed-off-by: Wang Yufei <james.wangyufei(a)huawei.com>
Signed-off-by: Zhang Bo <oscar.zhangbo(a)huawei.com>
---
src/qemu/qemu_monitor.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/src/qemu/qemu_monitor.c b/src/qemu/qemu_monitor.c
index f959b74..c72702d 100644
--- a/src/qemu/qemu_monitor.c
+++ b/src/qemu/qemu_monitor.c
@@ -1711,7 +1711,9 @@ qemuMonitorGetMemoryStats(qemuMonitorPtr mon,
QEMU_CHECK_MONITOR(mon);
if (mon->json) {
- ignore_value(qemuMonitorFindBalloonObjectPath(mon, "/"));
+ if (mon->vm->def->memballoon &&
+ mon->vm->def->memballoon->model != VIR_DOMAIN_MEMBALLOON_MODEL_NONE)
+ ignore_value(qemuMonitorFindBalloonObjectPath(mon, "/"));
mon->ballooninit = true;
return qemuMonitorJSONGetMemoryStats(mon, mon->balloonpath,
stats, nr_stats);
--
1.7.12.4
9 years, 7 months
[libvirt] [libvirt-glib] storage-pool: API to get/set autostart flag
by Zeeshan Ali (Khattak)
Add binding for virStoragePoolGetAutostart & virStoragePoolSetAutostart.
---
libvirt-gobject/libvirt-gobject-storage-pool.c | 52 ++++++++++++++++++++++++++
libvirt-gobject/libvirt-gobject-storage-pool.h | 5 +++
libvirt-gobject/libvirt-gobject.sym | 6 +++
3 files changed, 63 insertions(+)
diff --git a/libvirt-gobject/libvirt-gobject-storage-pool.c b/libvirt-gobject/libvirt-gobject-storage-pool.c
index f3eac0d..e520c6a 100644
--- a/libvirt-gobject/libvirt-gobject-storage-pool.c
+++ b/libvirt-gobject/libvirt-gobject-storage-pool.c
@@ -1048,6 +1048,58 @@ gboolean gvir_storage_pool_delete (GVirStoragePool *pool,
return TRUE;
}
+/**
+ * gvir_storage_pool_get_autostart:
+ * @pool: the storage pool
+ * @err: return location for any #GError
+ *
+ * Return value: #True if autostart is enabled, #False otherwise.
+ */
+gboolean gvir_storage_pool_get_autostart(GVirStoragePool *pool,
+ GError **err)
+{
+ gboolean ret = FALSE;
+
+ g_return_val_if_fail(GVIR_IS_STORAGE_POOL(pool), ret);
+ g_return_val_if_fail(err == NULL || *err == NULL, ret);
+
+ if (virStoragePoolGetAutostart(pool->priv->handle, &ret)) {
+ gvir_set_error_literal(err, GVIR_STORAGE_POOL_ERROR,
+ 0,
+ "Failed to get autostart flag from storage pool");
+ return FALSE;
+ }
+
+ return ret;
+}
+
+/**
+ * gvir_storage_pool_set_autostart:
+ * @pool: the storage pool
+ * @autostart: New value for autostart flag
+ * @err: return location for any #GError
+ *
+ * Sets whether or not storage pool @pool is started automatically on boot.
+ *
+ * Return value: #TRUE on success, #FALSE otherwise.
+ */
+gboolean gvir_storage_pool_set_autostart(GVirStoragePool *pool,
+ gboolean autostart,
+ GError **err)
+{
+ g_return_val_if_fail(GVIR_IS_STORAGE_POOL(pool), FALSE);
+ g_return_val_if_fail(err == NULL || *err == NULL, FALSE);
+
+ if (virStoragePoolSetAutostart(pool->priv->handle, autostart)) {
+ gvir_set_error_literal(err, GVIR_STORAGE_POOL_ERROR,
+ 0,
+ "Failed to set autostart flag on storage pool");
+ return FALSE;
+ }
+
+ return TRUE;
+}
+
static void
gvir_storage_pool_delete_helper(GSimpleAsyncResult *res,
GObject *object,
diff --git a/libvirt-gobject/libvirt-gobject-storage-pool.h b/libvirt-gobject/libvirt-gobject-storage-pool.h
index f8529f0..f7f879c 100644
--- a/libvirt-gobject/libvirt-gobject-storage-pool.h
+++ b/libvirt-gobject/libvirt-gobject-storage-pool.h
@@ -166,6 +166,11 @@ void gvir_storage_pool_delete_async (GVirStoragePool *pool,
gboolean gvir_storage_pool_delete_finish(GVirStoragePool *pool,
GAsyncResult *result,
GError **err);
+gboolean gvir_storage_pool_get_autostart(GVirStoragePool *pool,
+ GError **err);
+gboolean gvir_storage_pool_set_autostart(GVirStoragePool *pool,
+ gboolean autostart,
+ GError **err);
G_END_DECLS
diff --git a/libvirt-gobject/libvirt-gobject.sym b/libvirt-gobject/libvirt-gobject.sym
index 927cad9..dcda675 100644
--- a/libvirt-gobject/libvirt-gobject.sym
+++ b/libvirt-gobject/libvirt-gobject.sym
@@ -265,4 +265,10 @@ LIBVIRT_GOBJECT_0.2.0 {
gvir_domain_open_graphics_fd;
} LIBVIRT_GOBJECT_0.1.9;
+LIBVIRT_GOBJECT_0.2.1 {
+ global:
+ gvir_storage_pool_get_autostart;
+ gvir_storage_pool_set_autostart;
+} LIBVIRT_GOBJECT_0.2.0;
+
# .... define new API here using predicted next version number ....
--
2.1.0
9 years, 7 months
[libvirt] [PATCH] check if console PTY is null before attempting to open
by Shivaprasad G Bhat
Console devices have their pty devices assigned when the qemu is actually
started. The libvirt spends considerable amount of time to start the qemu if
the guest has multiple passthrough devices. If time is spent during the
hostdev preparation, someone attempts to open the console, the libvirt
crashes in virChrdevLockFilePath().The patch attempts to fix the crash by
adding a check before attempting to open.
Signed-off-by: Shivaprasad G Bhat <sbhat(a)linux.vnet.ibm.com>
---
src/qemu/qemu_driver.c | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/src/qemu/qemu_driver.c b/src/qemu/qemu_driver.c
index 1233d8f..fec928f 100644
--- a/src/qemu/qemu_driver.c
+++ b/src/qemu/qemu_driver.c
@@ -16278,6 +16278,12 @@ qemuDomainOpenConsole(virDomainPtr dom,
goto cleanup;
}
+ if (!(chr->source.data.file.path)) {
+ virReportError(VIR_ERR_OPERATION_FAILED, "%s",
+ _("PTY device is not yet assigned"));
+ goto cleanup;
+ }
+
/* handle mutually exclusive access to console devices */
ret = virChrdevOpen(priv->devs,
&chr->source,
9 years, 7 months
[libvirt] [PATCH 0/3] Better error reporting of bad IP address ranges
by Laine Stump
This resolves: https://bugzilla.redhat.com/show_bug.cgi?id=985653
Laine Stump (3):
network: validate DHCP ranges are completely within defined network
network: cleanup range loop in networkDnsmasqConfContents
util: report all address range errors in virSocketAddrGetRange()
src/conf/network_conf.c | 18 +--
src/network/bridge_driver.c | 24 +--
src/util/virsocketaddr.c | 180 ++++++++++++++++++---
src/util/virsocketaddr.h | 6 +-
tests/networkxml2xmlupdatein/dhcp-range-10.xml | 1 +
tests/networkxml2xmlupdatein/dhcp-range.xml | 2 +-
.../dhcp6host-routed-network-another-range.xml | 2 +-
.../dhcp6host-routed-network-range.xml | 2 +-
tests/networkxml2xmlupdatetest.c | 5 +
tests/sockettest.c | 55 ++++---
10 files changed, 228 insertions(+), 67 deletions(-)
create mode 100644 tests/networkxml2xmlupdatein/dhcp-range-10.xml
--
2.1.0
9 years, 7 months
[libvirt] [PATCH V2 libvirt-python] Fix duplicate entries in AUTHORS
by Jim Fehlig
The generated AUTHORS file contains many duplicates. If an author
has N commits, there will be N entries for the author in AUTHORS.
Check if an author already exists in the list before appending.
While at it, add a .mailmap (derived from libivrt's .mailmap) to
futher tidy the generated AUTHORS list.
Signed-off-by: Jim Fehlig <jfehlig(a)suse.com>
---
V2:
Add .mailmap. I started with libvirt's .mailmap and removed
entries where there was no corresponding author in the
libvirt-python repo.
.mailmap | 16 ++++++++++++++++
setup.py | 4 +++-
2 files changed, 19 insertions(+), 1 deletion(-)
diff --git a/.mailmap b/.mailmap
new file mode 100644
index 0000000..d8ac934
--- /dev/null
+++ b/.mailmap
@@ -0,0 +1,16 @@
+# 'git shortlog --help' and look for mailmap for the format of each line
+
+# Email consolidation:
+# <Preferred address in AUTHORS> <other alias used by same author>
+
+<jdenemar(a)redhat.com> <Jiri.Denemark(a)gmail.com>
+<jfehlig(a)suse.com> <jfehlig(a)novell.com>
+<stefanb(a)us.ibm.com> <stefanb(a)linux.vnet.ibm.com>
+
+# Name consolidation:
+# Preferred author spelling <preferred email>
+Alex Jia <ajia(a)redhat.com>
+Ján Tomko <jtomko(a)redhat.com>
+MATSUDA Daiki <matsudadik(a)intellilink.co.jp>
+Serge E. Hallyn <serge.hallyn(a)canonical.com>
+Philipp Hahn <hahn(a)univention.de>
diff --git a/setup.py b/setup.py
index 2571742..7a1964b 100755
--- a/setup.py
+++ b/setup.py
@@ -176,7 +176,9 @@ class my_sdist(sdist):
f = os.popen("git log --pretty=format:'%aN <%aE>'")
authors = []
for line in f:
- authors.append(" " + line.strip())
+ line = " " + line.strip()
+ if line not in authors:
+ authors.append(line)
authors.sort(key=str.lower)
--
2.3.7
9 years, 7 months