mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2024-12-22 21:55:25 +00:00
build: fix cgroups on non-Linux
Running ./autobuild.sh detected a mingw failure: CCLD libvirt.la Cannot export virCgroupGetPercpuStats: symbol not defined Cannot export virCgroupSetOwner: symbol not defined * src/util/vircgroup.c (virCgroupGetPercpuStats) (virCgroupSetOwner): Implement stubs. Signed-off-by: Eric Blake <eblake@redhat.com>
This commit is contained in:
parent
4d975deddd
commit
fa2e4dbfd6
@ -1,7 +1,7 @@
|
||||
/*
|
||||
* vircgroup.c: methods for managing control cgroups
|
||||
*
|
||||
* Copyright (C) 2010-2013 Red Hat, Inc.
|
||||
* Copyright (C) 2010-2014 Red Hat, Inc.
|
||||
* Copyright IBM Corp. 2008
|
||||
*
|
||||
* This library is free software; you can redistribute it and/or
|
||||
@ -4379,4 +4379,29 @@ virCgroupSupportsCpuBW(virCgroupPtr cgroup ATTRIBUTE_UNUSED)
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
int
|
||||
virCgroupGetPercpuStats(virCgroupPtr group ATTRIBUTE_UNUSED,
|
||||
virTypedParameterPtr params ATTRIBUTE_UNUSED,
|
||||
unsigned int nparams ATTRIBUTE_UNUSED,
|
||||
int start_cpu ATTRIBUTE_UNUSED,
|
||||
unsigned int ncpus ATTRIBUTE_UNUSED)
|
||||
{
|
||||
virReportSystemError(ENOSYS, "%s",
|
||||
_("Control groups not supported on this platform"));
|
||||
return -1;
|
||||
}
|
||||
|
||||
|
||||
int
|
||||
virCgroupSetOwner(virCgroupPtr cgroup ATTRIBUTE_UNUSED,
|
||||
uid_t uid ATTRIBUTE_UNUSED,
|
||||
gid_t gid ATTRIBUTE_UNUSED,
|
||||
int controllers ATTRIBUTE_UNUSED)
|
||||
{
|
||||
virReportSystemError(ENOSYS, "%s",
|
||||
_("Control groups not supported on this platform"));
|
||||
return -1;
|
||||
}
|
||||
|
||||
#endif /* !VIR_CGROUP_SUPPORTED */
|
||||
|
Loading…
Reference in New Issue
Block a user