GNU bug report logs -
#28718
[PATCH] gnu: qemu: Add sysconfdir to configure-flags.
Previous Next
Reported by: Oleg Pykhalov <go.wigust <at> gmail.com>
Date: Fri, 6 Oct 2017 03:31:03 UTC
Severity: normal
Tags: patch
Done: ludo <at> gnu.org (Ludovic Courtès)
Bug is archived. No further changes may be made.
To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 28718 in the body.
You can then email your comments to 28718 AT debbugs.gnu.org in the normal way.
Toggle the display of automated, internal messages from the tracker.
Report forwarded
to
guix-patches <at> gnu.org
:
bug#28718
; Package
guix-patches
.
(Fri, 06 Oct 2017 03:31:03 GMT)
Full text and
rfc822 format available.
Acknowledgement sent
to
Oleg Pykhalov <go.wigust <at> gmail.com>
:
New bug report received and forwarded. Copy sent to
guix-patches <at> gnu.org
.
(Fri, 06 Oct 2017 03:31:03 GMT)
Full text and
rfc822 format available.
Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
[0001-gnu-qemu-Add-sysconfdir-to-configure-flags.patch (text/x-patch, inline)]
From 371ba5aee9ef1412753fdb43230f107087f9651b Mon Sep 17 00:00:00 2001
From: Oleg Pykhalov <go.wigust <at> gmail.com>
Date: Fri, 6 Oct 2017 06:24:58 +0300
Subject: [PATCH] gnu: qemu: Add sysconfdir to configure-flags.
* gnu/packages/virtualization.scm (qemu): Add sysconfdir to configure-flags.
---
gnu/packages/virtualization.scm | 1 +
1 file changed, 1 insertion(+)
diff --git a/gnu/packages/virtualization.scm b/gnu/packages/virtualization.scm
index a8e54d684..21fc7b784 100644
--- a/gnu/packages/virtualization.scm
+++ b/gnu/packages/virtualization.scm
@@ -111,6 +111,7 @@
"--disable-debug-info" ; save build space
"--enable-virtfs" ; just to be sure
,(string-append "--prefix=" out)
+ ,(string-append "--sysconfdir=/tmp/etc")
,@configure-flags))))))
(add-after 'install 'install-info
(lambda* (#:key inputs outputs #:allow-other-keys)
--
2.14.2
Information forwarded
to
guix-patches <at> gnu.org
:
bug#28718
; Package
guix-patches
.
(Fri, 06 Oct 2017 04:39:01 GMT)
Full text and
rfc822 format available.
Message #8 received at 28718 <at> debbugs.gnu.org (full text, mbox):
I've used this patch to run a QEMU VM with bridge interface.
$ mkdir -p /tmp/etc/qemu
$ echo 'allow bridge0' | tee -a /tmp/etc/qemu/bridge.conf
# ip link add bridge0 type bridge
# ip link set dev enp6s0 master bridge0
# ip link up bridge0
# dhclient bridge0
# qemu-system-x86_64 -net nic -net bridge,br=bridge0 # …
Information forwarded
to
guix-patches <at> gnu.org
:
bug#28718
; Package
guix-patches
.
(Sat, 07 Oct 2017 17:59:02 GMT)
Full text and
rfc822 format available.
Message #11 received at 28718 <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
On Fri, Oct 06, 2017 at 06:30:34AM +0300, Oleg Pykhalov wrote:
> From 371ba5aee9ef1412753fdb43230f107087f9651b Mon Sep 17 00:00:00 2001
> From: Oleg Pykhalov <go.wigust <at> gmail.com>
> Date: Fri, 6 Oct 2017 06:24:58 +0300
> Subject: [PATCH] gnu: qemu: Add sysconfdir to configure-flags.
>
> * gnu/packages/virtualization.scm (qemu): Add sysconfdir to configure-flags.
Hi Oleg, thanks for the patch.
> ---
> gnu/packages/virtualization.scm | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/gnu/packages/virtualization.scm b/gnu/packages/virtualization.scm
> index a8e54d684..21fc7b784 100644
> --- a/gnu/packages/virtualization.scm
> +++ b/gnu/packages/virtualization.scm
> @@ -111,6 +111,7 @@
> "--disable-debug-info" ; save build space
> "--enable-virtfs" ; just to be sure
> ,(string-append "--prefix=" out)
> + ,(string-append "--sysconfdir=/tmp/etc")
> ,@configure-flags))))))
> (add-after 'install 'install-info
> (lambda* (#:key inputs outputs #:allow-other-keys)
Can you describe the problem this patch aims to address? And, where does
QEMU look for its configuration when this flag is not set?
[signature.asc (application/pgp-signature, inline)]
Information forwarded
to
guix-patches <at> gnu.org
:
bug#28718
; Package
guix-patches
.
(Sat, 07 Oct 2017 20:35:02 GMT)
Full text and
rfc822 format available.
Message #14 received at 28718 <at> debbugs.gnu.org (full text, mbox):
Hi Oleg,
Oleg Pykhalov <go.wigust <at> gmail.com> skribis:
> From 371ba5aee9ef1412753fdb43230f107087f9651b Mon Sep 17 00:00:00 2001
> From: Oleg Pykhalov <go.wigust <at> gmail.com>
> Date: Fri, 6 Oct 2017 06:24:58 +0300
> Subject: [PATCH] gnu: qemu: Add sysconfdir to configure-flags.
>
> * gnu/packages/virtualization.scm (qemu): Add sysconfdir to configure-flags.
> ---
> gnu/packages/virtualization.scm | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/gnu/packages/virtualization.scm b/gnu/packages/virtualization.scm
> index a8e54d684..21fc7b784 100644
> --- a/gnu/packages/virtualization.scm
> +++ b/gnu/packages/virtualization.scm
> @@ -111,6 +111,7 @@
> "--disable-debug-info" ; save build space
> "--enable-virtfs" ; just to be sure
> ,(string-append "--prefix=" out)
> + ,(string-append "--sysconfdir=/tmp/etc")
[...]
> I've used this patch to run a QEMU VM with bridge interface.
>
> $ mkdir -p /tmp/etc/qemu
> $ echo 'allow bridge0' | tee -a /tmp/etc/qemu/bridge.conf
> # ip link add bridge0 type bridge
> # ip link set dev enp6s0 master bridge0
> # ip link up bridge0
> # dhclient bridge0
> # qemu-system-x86_64 -net nic -net bridge,br=bridge0 # …
It feels wrong to me to default to /tmp/etc instead of /etc.
Setting up a bridge requires root privileges anyway, so why not stick to
/etc instead of /tmp/etc?
Thanks,
Ludo’.
Information forwarded
to
guix-patches <at> gnu.org
:
bug#28718
; Package
guix-patches
.
(Sun, 08 Oct 2017 07:16:02 GMT)
Full text and
rfc822 format available.
Message #17 received at 28718 <at> debbugs.gnu.org (full text, mbox):
Hello Ludovic,
ludo <at> gnu.org (Ludovic Courtès) writes:
[...]
>> I've used this patch to run a QEMU VM with bridge interface.
>>
>> $ mkdir -p /tmp/etc/qemu
>> $ echo 'allow bridge0' | tee -a /tmp/etc/qemu/bridge.conf
>> # ip link add bridge0 type bridge
>> # ip link set dev enp6s0 master bridge0
>> # ip link up bridge0
>> # dhclient bridge0
>> # qemu-system-x86_64 -net nic -net bridge,br=bridge0 # …
>
> It feels wrong to me to default to /tmp/etc instead of /etc.
>
> Setting up a bridge requires root privileges anyway, so why not stick to
> /etc instead of /tmp/etc?
It's inspired by libvirt package recipe :-)
Information forwarded
to
guix-patches <at> gnu.org
:
bug#28718
; Package
guix-patches
.
(Sun, 08 Oct 2017 15:23:02 GMT)
Full text and
rfc822 format available.
Message #20 received at 28718 <at> debbugs.gnu.org (full text, mbox):
Oleg Pykhalov <go.wigust <at> gmail.com> skribis:
> Hello Ludovic,
>
> ludo <at> gnu.org (Ludovic Courtès) writes:
>
> [...]
>
>>> I've used this patch to run a QEMU VM with bridge interface.
>>>
>>> $ mkdir -p /tmp/etc/qemu
>>> $ echo 'allow bridge0' | tee -a /tmp/etc/qemu/bridge.conf
>>> # ip link add bridge0 type bridge
>>> # ip link set dev enp6s0 master bridge0
>>> # ip link up bridge0
>>> # dhclient bridge0
>>> # qemu-system-x86_64 -net nic -net bridge,br=bridge0 # …
>>
>> It feels wrong to me to default to /tmp/etc instead of /etc.
>>
>> Setting up a bridge requires root privileges anyway, so why not stick to
>> /etc instead of /tmp/etc?
>
> It's inspired by libvirt package recipe :-)
Looking at commit a4b9392151 for libvirt, I think it’s a trick here: we
do pass --sysconfdir=/etc, and sysconfdir=/tmp/etc is passed only during
the install phase, which I think is a trick to avoid errors while
creating $(sysconfdir). But /etc is the actual sysconfdir AIUI.
So, WDYT? :-)
Ludo’.
Information forwarded
to
guix-patches <at> gnu.org
:
bug#28718
; Package
guix-patches
.
(Mon, 09 Oct 2017 11:25:02 GMT)
Full text and
rfc822 format available.
Message #23 received at 28718 <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
Hello Ludovic,
ludo <at> gnu.org (Ludovic Courtès) writes:
[...]
>>>> I've used this patch to run a QEMU VM with bridge interface.
>>>>
>>>> $ mkdir -p /tmp/etc/qemu
>>>> $ echo 'allow bridge0' | tee -a /tmp/etc/qemu/bridge.conf
>>>> # ip link add bridge0 type bridge
>>>> # ip link set dev enp6s0 master bridge0
>>>> # ip link up bridge0
>>>> # dhclient bridge0
>>>> # qemu-system-x86_64 -net nic -net bridge,br=bridge0 # …
>>>
>>> It feels wrong to me to default to /tmp/etc instead of /etc.
>>>
>>> Setting up a bridge requires root privileges anyway, so why not stick to
>>> /etc instead of /tmp/etc?
>>
>> It's inspired by libvirt package recipe :-)
>
> Looking at commit a4b9392151 for libvirt, I think it’s a trick here: we
> do pass --sysconfdir=/etc, and sysconfdir=/tmp/etc is passed only during
> the install phase, which I think is a trick to avoid errors while
> creating $(sysconfdir). But /etc is the actual sysconfdir AIUI.
>
> So, WDYT? :-)
Thank you for investigation. I saw no reason not to use file-system
convention at the beginning of discussion. Here is an another patch.
Build finished successfully for me.
[0001-gnu-qemu-Add-sysconfdir-to-configure-flags.patch (text/x-patch, attachment)]
Reply sent
to
ludo <at> gnu.org (Ludovic Courtès)
:
You have taken responsibility.
(Mon, 09 Oct 2017 19:38:02 GMT)
Full text and
rfc822 format available.
Notification sent
to
Oleg Pykhalov <go.wigust <at> gmail.com>
:
bug acknowledged by developer.
(Mon, 09 Oct 2017 19:38:02 GMT)
Full text and
rfc822 format available.
Message #28 received at 28718-done <at> debbugs.gnu.org (full text, mbox):
Oleg Pykhalov <go.wigust <at> gmail.com> skribis:
> From fcff3b4b2c53af7974786f7f4dd1633c9b634130 Mon Sep 17 00:00:00 2001
> From: Oleg Pykhalov <go.wigust <at> gmail.com>
> Date: Fri, 6 Oct 2017 06:24:58 +0300
> Subject: [PATCH] gnu: qemu: Add sysconfdir to configure-flags.
>
> * gnu/packages/virtualization.scm (qemu): Add sysconfdir to configure-flags.
Applied, thanks!
Ludo'.
bug archived.
Request was from
Debbugs Internal Request <help-debbugs <at> gnu.org>
to
internal_control <at> debbugs.gnu.org
.
(Tue, 07 Nov 2017 12:24:03 GMT)
Full text and
rfc822 format available.
This bug report was last modified 7 years and 304 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.