qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: "Philippe Mathieu-Daudé" <philmd@linaro.org>
To: "Marc-André Lureau" <marcandre.lureau@redhat.com>,
	"Bernhard Beschow" <shentey@gmail.com>
Cc: qemu-devel@nongnu.org, richard.henderson@linaro.org,
	"Gerd Hoffmann" <kraxel@redhat.com>,
	"Paolo Bonzini" <pbonzini@redhat.com>,
	"Daniel P. Berrangé" <berrange@redhat.com>,
	"Thomas Huth" <thuth@redhat.com>
Subject: Re: [PULL 17/33] ui/dbus: win32 support
Date: Sat, 1 Jul 2023 01:51:39 +0200	[thread overview]
Message-ID: <ded8a8b6-d09a-810f-e4f9-e9a4fb7e35b3@linaro.org> (raw)
In-Reply-To: <CAMxuvayCrjNH5QnbWNWtiP1HrMNnnGYOdY142KzpTGj6hf9F8A@mail.gmail.com>

On 30/6/23 23:41, Marc-André Lureau wrote:
> Hi
> 
> On Thu, Jun 29, 2023 at 7:55 PM Bernhard Beschow <shentey@gmail.com 
> <mailto:shentey@gmail.com>> wrote:
> 
> 
> 
>     Am 27. Juni 2023 13:02:14 UTC schrieb marcandre.lureau@redhat.com
>     <mailto:marcandre.lureau@redhat.com>:
>      >From: Marc-André Lureau <marcandre.lureau@redhat.com
>     <mailto:marcandre.lureau@redhat.com>>
>      >
>      >D-Bus doesn't support fd-passing on Windows (AF_UNIX doesn't have
>      >SCM_RIGHTS yet, but there are other means to share objects. I have
>      >proposed various solutions upstream, but none seem fitting enough
>     atm).
>      >
>      >To make the "-display dbus" work on Windows, implement an alternative
>      >D-Bus interface where all the 'h' (FDs) arguments are replaced with
>      >'ay' (WSASocketW data), and sockets are passed to the other end via
>      >WSADuplicateSocket().
>      >
>      >Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com
>     <mailto:marcandre.lureau@redhat.com>>
>      >Message-Id: <20230606115658.677673-6-marcandre.lureau@redhat.com
>     <mailto:20230606115658.677673-6-marcandre.lureau@redhat.com>>
>      >---
>      > meson.build          |  4 +--
>      > ui/dbus.h            |  6 +++++
>      > audio/dbusaudio.c    | 44 +++++++++++++++++++++++++++------
>      > ui/dbus-chardev.c    | 22 +++++++++++++----
>      > ui/dbus-console.c    | 59
>     ++++++++++++++++++++++++++++++++++++++------
>      > ui/dbus-display1.xml | 28 +++++++++++++++++++++
>      > ui/meson.build       |  9 ++++++-
>      > 7 files changed, 149 insertions(+), 23 deletions(-)
>      >
>      >diff --git a/meson.build b/meson.build
>      >index b409788832..9a1ce43471 100644
>      >--- a/meson.build
>      >+++ b/meson.build
>      >@@ -838,6 +838,8 @@ if gdbus_codegen.found() and get_option('cfi')
>      >   gdbus_codegen_error = '@0@ uses gdbus-codegen, which does not
>     support control flow integrity'
>      > endif
>      >
>      >+xml_pp = find_program('scripts/xml-preprocess.py')
>      >+
>      > lttng = not_found
>      > if 'ust' in get_option('trace_backends')
>      >   lttng = dependency('lttng-ust', required: true, version: '>= 2.1',
>      >@@ -1985,8 +1987,6 @@ dbus_display = get_option('dbus_display') \
>      >            error_message: '-display dbus requires glib>=2.64') \
>      >   .require(gdbus_codegen.found(),
>      >            error_message: gdbus_codegen_error.format('-display
>     dbus')) \
>      >-  .require(targetos != 'windows',
>      >-           error_message: '-display dbus is not available on
>     Windows') \
>      >   .allowed()
>      >
>      > have_virtfs = get_option('virtfs') \
>      >diff --git a/ui/dbus.h b/ui/dbus.h
>      >index 9c149e7b41..1e8c24a48e 100644
>      >--- a/ui/dbus.h
>      >+++ b/ui/dbus.h
>      >@@ -62,6 +62,12 @@ struct DBusDisplay {
>      >     Notifier notifier;
>      > };
>      >
>      >+#ifdef WIN32
>      >+bool
>      >+dbus_win32_import_socket(GDBusMethodInvocation *invocation,
>      >+                         GVariant *arg_listener, int *socket);
>      >+#endif
>      >+
>      > #define TYPE_DBUS_DISPLAY "dbus-display"
>      > OBJECT_DECLARE_SIMPLE_TYPE(DBusDisplay, DBUS_DISPLAY)
>      >
>      >diff --git a/audio/dbusaudio.c b/audio/dbusaudio.c
>      >index de59467d9e..7a11fbfb42 100644
>      >--- a/audio/dbusaudio.c
>      >+++ b/audio/dbusaudio.c
>      >@@ -33,6 +33,7 @@
>      > #include <gio/gunixfdlist.h>
>      > #endif
>      >
>      >+#include "ui/dbus.h"
> 
>     This patch causes below compile error since pixman.h isn't found. It
>     seems as if the pixman include path is missing. Since pixman.h is
>     found elsewhere in the same build I suspect that the DBUS audio
>     module now needs a pixman dependency -- which sounds a little bit
>     weired.
> 
>     FAILED: libaudio-dbus.a.p/audio_dbusaudio.c.o
>     cc -m64 -mcx16 -Ilibaudio-dbus.a.p -I. -I../src -Iqapi -Itrace -Iui
>     -Iui/shader -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include
>     -I/usr/include/sysprof-4 -I/usr/include/libmount
>     -I/usr/include/blkid -I/usr/include/gio-unix-2.0
>     -fdiagnostics-color=auto -Wall -Winvalid-pch -Werror -std=gnu11 -O0
>     -g -fstack-protector-strong -Wundef -Wwrite-strings
>     -Wmissing-prototypes -Wstrict-prototypes -Wredundant-decls
>     -Wold-style-declaration -Wold-style-definition -Wtype-limits
>     -Wformat-security -Wformat-y2k -Winit-self -Wignored-qualifiers
>     -Wempty-body -Wnested-externs -Wendif-labels -Wexpansion-to-defined
>     -Wimplicit-fallthrough=2 -Wmissing-format-attribute
>     -Wno-missing-include-dirs -Wno-shift-negative-value -Wno-psabi
>     -isystem qemu/src/linux-headers -isystem linux-headers -iquote .
>     -iquote qemu/src -iquote qemu/src/include -iquote
>     qemu/src/host/include/x86_64 -iquote qemu/src/host/include/generic
>     -iquote qemu/src/tcg/i386 -Wno-unused-function -pthread
>     -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE
>     -fno-strict-aliasing -fno-common -fwrapv -march=x86-64
>     -mtune=generic -O2 -pipe -fno-plt -fexceptions
>     -Wp,-D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security
>     -fstack-clash-protection -fcf-protection -fPIC -DBUILD_DSO -MD -MQ
>     libaudio-dbus.a.p/audio_dbusaudio.c.o -MF
>     libaudio-dbus.a.p/audio_dbusaudio.c.o.d -o
>     libaudio-dbus.a.p/audio_dbusaudio.c.o -c ../src/audio/dbusaudio.c
>     In file included from qemu/src/include/ui/console.h:4,
>                       from qemu/src/ui/dbus.h:31,
>                       from ../src/audio/dbusaudio.c:36:
>     qemu/src/include/ui/qemu-pixman.h:12:10: fatal error: pixman.h: No
>     such file or directory
>         12 | #include <pixman.h>
>            |          ^~~~~~~~~~
> 
> 
> This is reported here:
> https://gitlab.com/qemu-project/qemu/-/issues/1739 
> <https://gitlab.com/qemu-project/qemu/-/issues/1739>
> 
> I am going to send the patch.

I just send a patch fixing this error, see:
https://lore.kernel.org/qemu-devel/20230630234839.14716-1-philmd@linaro.org/


  reply	other threads:[~2023-06-30 23:52 UTC|newest]

Thread overview: 46+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-06-27 13:01 [PULL 00/33] UI patches marcandre.lureau
2023-06-27 13:01 ` [PULL 01/33] ui: return NULL when getting cursor without a console marcandre.lureau
2023-06-27 13:01 ` [PULL 02/33] egl: no need to lookup EGL functions manually marcandre.lureau
2023-06-27 13:02 ` [PULL 03/33] ui/sdl2: OpenGL window context marcandre.lureau
2023-06-27 13:02 ` [PULL 04/33] virtio-gpu: Optimize 2D resource data transfer marcandre.lureau
2023-06-27 15:04   ` Richard Henderson
2023-06-27 15:10     ` Marc-André Lureau
2023-06-28  9:22       ` Richard Henderson
2023-06-27 13:02 ` [PULL 05/33] chardev/char-win-stdio: Support VT sequences on Windows 11 host marcandre.lureau
2023-06-27 13:02 ` [PULL 06/33] ui/touch: Move event handling to a common helper marcandre.lureau
2023-06-27 13:02 ` [PULL 07/33] ui/dbus: Expose a touch device interface marcandre.lureau
2023-06-27 13:02 ` [PULL 08/33] virtio-gpu: Make non-gl display updates work again when blob=true marcandre.lureau
2023-06-27 13:02 ` [PULL 09/33] virtio-gpu-udmabuf: create udmabuf for blob even when iov_cnt == 1 marcandre.lureau
2023-06-27 13:02 ` [PULL 10/33] ui/gtk: set the area of the scanout texture correctly marcandre.lureau
2023-06-27 17:46   ` Michael Tokarev
2023-06-27 13:02 ` [PULL 11/33] virtio-gpu: OUT_OF_MEMORY if failing to create udmabuf marcandre.lureau
2023-06-27 13:02 ` [PULL 12/33] ui/gtk: making dmabuf NULL when it's released marcandre.lureau
2023-06-27 13:02 ` [PULL 13/33] ui/egl: export qemu_egl_get_error_string() marcandre.lureau
2023-06-27 13:02 ` [PULL 14/33] ui/egl: fix make_context_current() callback return value marcandre.lureau
2023-06-27 13:02 ` [PULL 15/33] ui/dbus: compile without gio/gunixfdlist.h marcandre.lureau
2023-06-27 13:02 ` [PULL 16/33] scripts: add a XML preprocessor script marcandre.lureau
2023-06-27 13:02 ` [PULL 17/33] ui/dbus: win32 support marcandre.lureau
2023-06-29 17:55   ` Bernhard Beschow
2023-06-30 21:41     ` Marc-André Lureau
2023-06-30 23:51       ` Philippe Mathieu-Daudé [this message]
2023-06-27 13:02 ` [PULL 18/33] qtest: add qtest_pid() marcandre.lureau
2023-06-27 13:02 ` [PULL 19/33] tests: make dbus-display-test work on win32 marcandre.lureau
2023-06-27 13:02 ` [PULL 20/33] ui/dbus: introduce "Interfaces" properties marcandre.lureau
2023-06-27 13:02 ` [PULL 21/33] console/win32: allocate shareable display surface marcandre.lureau
2023-06-27 13:02 ` [PULL 22/33] virtio-gpu/win32: allocate shareable 2d resources/images marcandre.lureau
2023-07-03 11:45   ` Alexander Bulekov
2023-07-03 14:11   ` Peter Maydell
2023-06-27 13:02 ` [PULL 23/33] ui/dbus: use shared memory when possible on win32 marcandre.lureau
2023-06-27 13:02 ` [PULL 24/33] ui: add egl-headless support " marcandre.lureau
2023-06-27 13:02 ` [PULL 25/33] ui/egl: default to GLES on windows marcandre.lureau
2023-06-27 13:02 ` [PULL 26/33] ui: add egl_fb_read_rect() marcandre.lureau
2023-06-27 13:02 ` [PULL 27/33] ui/dbus: add GL support on win32 marcandre.lureau
2023-06-27 13:02 ` [PULL 28/33] ui/dbus: add some GL traces marcandre.lureau
2023-06-27 13:02 ` [PULL 29/33] virtio-gpu-virgl: teach it to get the QEMU EGL display marcandre.lureau
2023-06-27 13:02 ` [PULL 30/33] ui/egl: query ANGLE d3d device marcandre.lureau
2023-06-27 13:02 ` [PULL 31/33] ui: add optional d3d texture pointer to scanout texture marcandre.lureau
2023-06-27 13:02 ` [PULL 32/33] virtio-gpu-virgl: use D3D11_SHARE_TEXTURE when available marcandre.lureau
2023-06-27 13:02 ` [PULL 33/33] ui/dbus: use shared D3D11 Texture2D when possible marcandre.lureau
2023-06-29  7:40   ` Richard Henderson
2023-06-29  7:45     ` Richard Henderson
2023-06-29  8:35     ` Mark Cave-Ayland

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=ded8a8b6-d09a-810f-e4f9-e9a4fb7e35b3@linaro.org \
    --to=philmd@linaro.org \
    --cc=berrange@redhat.com \
    --cc=kraxel@redhat.com \
    --cc=marcandre.lureau@redhat.com \
    --cc=pbonzini@redhat.com \
    --cc=qemu-devel@nongnu.org \
    --cc=richard.henderson@linaro.org \
    --cc=shentey@gmail.com \
    --cc=thuth@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).