app-emulation/libvirt: Do not create qemu user if USE=-qemu, bug #601678
authorMatthias Maier <tamiko@gentoo.org>
Sun, 22 Jan 2017 15:55:05 +0000 (09:55 -0600)
committerMatthias Maier <tamiko@gentoo.org>
Sun, 22 Jan 2017 16:28:25 +0000 (10:28 -0600)
Package-Manager: Portage-2.3.0, Repoman-2.3.1

app-emulation/libvirt/libvirt-1.3.5-r2.ebuild
app-emulation/libvirt/libvirt-2.1.0-r2.ebuild
app-emulation/libvirt/libvirt-2.3.0.ebuild
app-emulation/libvirt/libvirt-2.5.0-r2.ebuild
app-emulation/libvirt/libvirt-9999.ebuild

index 780322798a66c798a3f791d73256e90eb1acee29..5f11f0c6bd345c680c9de394635051f1f3470a2f 100644 (file)
@@ -1,4 +1,4 @@
-# Copyright 1999-2016 Gentoo Foundation
+# Copyright 1999-2017 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
 # $Id$
 
@@ -125,15 +125,9 @@ DEPEND="${RDEPEND}
        virtual/pkgconfig"
 
 pkg_setup() {
-       enewgroup qemu 77
-       enewuser qemu 77 -1 -1 "qemu,kvm"
-
-       # Some people used the masked ebuild which was not adding the qemu
-       # user to the kvm group originally. This results in VMs failing to
-       # start for some users. bug #430808
-       egetent group kvm | grep -q qemu
-       if [[ $? -ne 0 ]]; then
-               gpasswd -a qemu kvm
+       if use qemu; then
+               enewgroup qemu 77
+               enewuser qemu 77 -1 -1 "qemu,kvm"
        fi
 
        # Check kernel configuration:
index 24c8f32628607a5a1edf3b1963f0285f570217ab..f9d91d7eba5045eb3d80b2e1dbdd87f2ce346ac4 100644 (file)
@@ -1,4 +1,4 @@
-# Copyright 1999-2016 Gentoo Foundation
+# Copyright 1999-2017 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
 # $Id$
 
@@ -124,15 +124,9 @@ DEPEND="${RDEPEND}
        virtual/pkgconfig"
 
 pkg_setup() {
-       enewgroup qemu 77
-       enewuser qemu 77 -1 -1 "qemu,kvm"
-
-       # Some people used the masked ebuild which was not adding the qemu
-       # user to the kvm group originally. This results in VMs failing to
-       # start for some users. bug #430808
-       egetent group kvm | grep -q qemu
-       if [[ $? -ne 0 ]]; then
-               gpasswd -a qemu kvm
+       if use qemu; then
+               enewgroup qemu 77
+               enewuser qemu 77 -1 -1 "qemu,kvm"
        fi
 
        # Check kernel configuration:
index 7d3cd016afdd5c031d0be983e5511c7ddcd90cb0..96b318e307d56ec70fddcc704c18e8a03da5bbac 100644 (file)
@@ -1,4 +1,4 @@
-# Copyright 1999-2016 Gentoo Foundation
+# Copyright 1999-2017 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
 # $Id$
 
@@ -124,15 +124,9 @@ DEPEND="${RDEPEND}
        virtual/pkgconfig"
 
 pkg_setup() {
-       enewgroup qemu 77
-       enewuser qemu 77 -1 -1 "qemu,kvm"
-
-       # Some people used the masked ebuild which was not adding the qemu
-       # user to the kvm group originally. This results in VMs failing to
-       # start for some users. bug #430808
-       egetent group kvm | grep -q qemu
-       if [[ $? -ne 0 ]]; then
-               gpasswd -a qemu kvm
+       if use qemu; then
+               enewgroup qemu 77
+               enewuser qemu 77 -1 -1 "qemu,kvm"
        fi
 
        # Check kernel configuration:
index edc6c59f2b1b6b0dae7e5bf052c0dc23965d812f..9f9134680d1951bd85517d6d391bab87836dbeb8 100644 (file)
@@ -130,15 +130,9 @@ PATCHES=(
 )
 
 pkg_setup() {
-       enewgroup qemu 77
-       enewuser qemu 77 -1 -1 "qemu,kvm"
-
-       # Some people used the masked ebuild which was not adding the qemu
-       # user to the kvm group originally. This results in VMs failing to
-       # start for some users. bug #430808
-       egetent group kvm | grep -q qemu
-       if [[ $? -ne 0 ]]; then
-               gpasswd -a qemu kvm
+       if use qemu; then
+               enewgroup qemu 77
+               enewuser qemu 77 -1 -1 "qemu,kvm"
        fi
 
        # Check kernel configuration:
index 609bf97449e2ba33fce6e5dc98cb4e0988f22957..81795e4a7f6bf4bb7e70685b3bd425130e10587c 100644 (file)
@@ -130,15 +130,9 @@ PATCHES=(
 )
 
 pkg_setup() {
-       enewgroup qemu 77
-       enewuser qemu 77 -1 -1 "qemu,kvm"
-
-       # Some people used the masked ebuild which was not adding the qemu
-       # user to the kvm group originally. This results in VMs failing to
-       # start for some users. bug #430808
-       egetent group kvm | grep -q qemu
-       if [[ $? -ne 0 ]]; then
-               gpasswd -a qemu kvm
+       if use qemu; then
+               enewgroup qemu 77
+               enewuser qemu 77 -1 -1 "qemu,kvm"
        fi
 
        # Check kernel configuration: