diff mbox

virtio-input: enable on non-linux hosts

Message ID 1436772617-2490-1-git-send-email-kraxel@redhat.com
State New
Headers show

Commit Message

Gerd Hoffmann July 13, 2015, 7:30 a.m. UTC
As we include a copy of the linux input layer header file in the qemu
source tree (include/standard-headers/linux/input.h) the virtio-input
bits (except pass-through) should build and work just fine on non-linux
hosts too.  Tweak Makefile accordingly.

Cc: Paolo Bonzini <pbonzini@redhat.com>
Cc: qemu-trivial@nongnu.org
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
---
 hw/input/Makefile.objs | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Peter Maydell July 13, 2015, 8:56 a.m. UTC | #1
On 13 July 2015 at 08:30, Gerd Hoffmann <kraxel@redhat.com> wrote:
> As we include a copy of the linux input layer header file in the qemu
> source tree (include/standard-headers/linux/input.h) the virtio-input
> bits (except pass-through) should build and work just fine on non-linux
> hosts too.  Tweak Makefile accordingly.

Does "should" here mean "I haven't actually tested it" ? :-)

thanks
-- PMM
Gerd Hoffmann July 13, 2015, 11:48 a.m. UTC | #2
On Mo, 2015-07-13 at 09:56 +0100, Peter Maydell wrote:
> On 13 July 2015 at 08:30, Gerd Hoffmann <kraxel@redhat.com> wrote:
> > As we include a copy of the linux input layer header file in the qemu
> > source tree (include/standard-headers/linux/input.h) the virtio-input
> > bits (except pass-through) should build and work just fine on non-linux
> > hosts too.  Tweak Makefile accordingly.
> 
> Does "should" here mean "I haven't actually tested it" ? :-)

Did a build test on freebsd -- passed.

cheers,
  Gerd
Gerd Hoffmann July 13, 2015, 12:01 p.m. UTC | #3
On Mo, 2015-07-13 at 13:48 +0200, Gerd Hoffmann wrote:
> On Mo, 2015-07-13 at 09:56 +0100, Peter Maydell wrote:
> > On 13 July 2015 at 08:30, Gerd Hoffmann <kraxel@redhat.com> wrote:
> > > As we include a copy of the linux input layer header file in the qemu
> > > source tree (include/standard-headers/linux/input.h) the virtio-input
> > > bits (except pass-through) should build and work just fine on non-linux
> > > hosts too.  Tweak Makefile accordingly.
> > 
> > Does "should" here mean "I haven't actually tested it" ? :-)
> 
> Did a build test on freebsd -- passed.

Oops, the windows cross builds fails though (due to
include/standard-headers/linux/input.h including sys/ioctl.h).

Ok, scratch that one, back to the drawing board ...

sorry,
  Gerd
diff mbox

Patch

diff --git a/hw/input/Makefile.objs b/hw/input/Makefile.objs
index 624ba7e..7715d72 100644
--- a/hw/input/Makefile.objs
+++ b/hw/input/Makefile.objs
@@ -8,9 +8,9 @@  common-obj-$(CONFIG_STELLARIS_INPUT) += stellaris_input.o
 common-obj-$(CONFIG_TSC2005) += tsc2005.o
 common-obj-$(CONFIG_VMMOUSE) += vmmouse.o
 
-ifeq ($(CONFIG_LINUX),y)
 common-obj-$(CONFIG_VIRTIO) += virtio-input.o
 common-obj-$(CONFIG_VIRTIO) += virtio-input-hid.o
+ifeq ($(CONFIG_LINUX),y)
 common-obj-$(CONFIG_VIRTIO) += virtio-input-host.o
 endif