qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-devel] [PATCH v2 2/4] hw/display/milkymist-tmu2: Explicit the depe


From: Philippe Mathieu-Daudé
Subject: [Qemu-devel] [PATCH v2 2/4] hw/display/milkymist-tmu2: Explicit the dependency to both X11 / OpenGL
Date: Thu, 24 Jan 2019 02:15:52 +0100

The TMU device requires both X11 and OpenGL.

Signed-off-by: Philippe Mathieu-Daudé <address@hidden>
---
 default-configs/lm32-softmmu.mak | 2 +-
 hw/display/Makefile.objs         | 4 ++--
 hw/lm32/milkymist-hw.h           | 4 ++--
 3 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/default-configs/lm32-softmmu.mak b/default-configs/lm32-softmmu.mak
index 4889348a10..4049b23562 100644
--- a/default-configs/lm32-softmmu.mak
+++ b/default-configs/lm32-softmmu.mak
@@ -2,7 +2,7 @@
 
 CONFIG_LM32=y
 CONFIG_MILKYMIST=y
-CONFIG_MILKYMIST_TMU2=$(CONFIG_OPENGL)
+CONFIG_MILKYMIST_TMU2=$(call land,$(CONFIG_X11),$(CONFIG_OPENGL))
 CONFIG_FRAMEBUFFER=y
 CONFIG_PTIMER=y
 CONFIG_PFLASH_CFI01=y
diff --git a/hw/display/Makefile.objs b/hw/display/Makefile.objs
index 97acd5b6cb..079e702f25 100644
--- a/hw/display/Makefile.objs
+++ b/hw/display/Makefile.objs
@@ -29,8 +29,8 @@ common-obj-$(CONFIG_MILKYMIST) += milkymist-vgafb.o
 common-obj-$(CONFIG_ZAURUS) += tc6393xb.o
 
 common-obj-$(CONFIG_MILKYMIST_TMU2) += milkymist-tmu2.o
-milkymist-tmu2.o-cflags := $(X11_CFLAGS)
-milkymist-tmu2.o-libs := $(X11_LIBS)
+milkymist-tmu2.o-cflags := $(X11_CFLAGS) $(OPENGL_CFLAGS)
+milkymist-tmu2.o-libs := $(X11_LIBS) $(OPENGL_LIBS)
 
 obj-$(CONFIG_OMAP) += omap_dss.o
 obj-$(CONFIG_OMAP) += omap_lcdc.o
diff --git a/hw/lm32/milkymist-hw.h b/hw/lm32/milkymist-hw.h
index d3be0cfb3a..32c344ef9f 100644
--- a/hw/lm32/milkymist-hw.h
+++ b/hw/lm32/milkymist-hw.h
@@ -88,7 +88,7 @@ static inline DeviceState *milkymist_pfpu_create(hwaddr base,
     return dev;
 }
 
-#ifdef CONFIG_OPENGL
+#if defined(CONFIG_X11) && defined(CONFIG_OPENGL)
 #include <X11/Xlib.h>
 #include <epoxy/gl.h>
 #include <epoxy/glx.h>
@@ -103,7 +103,7 @@ static const int glx_fbconfig_attr[] = {
 static inline DeviceState *milkymist_tmu2_create(hwaddr base,
         qemu_irq irq)
 {
-#ifdef CONFIG_OPENGL
+#if defined(CONFIG_X11) && defined(CONFIG_OPENGL)
     DeviceState *dev;
     Display *d;
     GLXFBConfig *configs;
-- 
2.20.1




reply via email to

[Prev in Thread] Current Thread [Next in Thread]