From patchwork Wed Nov 11 19:09:07 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Eduardo Habkost X-Patchwork-Id: 543034 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [IPv6:2001:4830:134:3::11]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 6C7271402D1 for ; Thu, 12 Nov 2015 06:11:10 +1100 (AEDT) Received: from localhost ([::1]:42504 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZwanU-0003C8-ID for incoming@patchwork.ozlabs.org; Wed, 11 Nov 2015 14:11:08 -0500 Received: from eggs.gnu.org ([2001:4830:134:3::10]:33748) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Zwamt-0002FG-S0 for qemu-devel@nongnu.org; Wed, 11 Nov 2015 14:10:32 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Zwamt-0006Zm-0N for qemu-devel@nongnu.org; Wed, 11 Nov 2015 14:10:31 -0500 Received: from mx1.redhat.com ([209.132.183.28]:35070) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Zwams-0006Zi-Qq for qemu-devel@nongnu.org; Wed, 11 Nov 2015 14:10:30 -0500 Received: from int-mx09.intmail.prod.int.phx2.redhat.com (int-mx09.intmail.prod.int.phx2.redhat.com [10.5.11.22]) by mx1.redhat.com (Postfix) with ESMTPS id 693361B282E for ; Wed, 11 Nov 2015 19:10:30 +0000 (UTC) Received: from localhost (ovpn-113-50.phx2.redhat.com [10.3.113.50]) by int-mx09.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id tABJAR7G014962; Wed, 11 Nov 2015 14:10:29 -0500 From: Eduardo Habkost To: qemu-devel@nongnu.org Date: Wed, 11 Nov 2015 17:09:07 -0200 Message-Id: <1447268956-27500-4-git-send-email-ehabkost@redhat.com> In-Reply-To: <1447268956-27500-1-git-send-email-ehabkost@redhat.com> References: <1447268956-27500-1-git-send-email-ehabkost@redhat.com> X-Scanned-By: MIMEDefang 2.68 on 10.5.11.22 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 209.132.183.28 Cc: Paolo Bonzini Subject: [Qemu-devel] [PATCH 03/12] stubs: curses_display_init() stub X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Sender: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org One less #ifdef in vl.c. Signed-off-by: Eduardo Habkost --- stubs/Makefile.objs | 1 + stubs/curses.c | 10 ++++++++++ vl.c | 2 -- 3 files changed, 11 insertions(+), 2 deletions(-) create mode 100644 stubs/curses.c diff --git a/stubs/Makefile.objs b/stubs/Makefile.objs index f69ab8d..df86bc6 100644 --- a/stubs/Makefile.objs +++ b/stubs/Makefile.objs @@ -38,3 +38,4 @@ stub-obj-y += qmp_pc_dimm_device_list.o stub-obj-y += target-monitor-defs.o stub-obj-y += vhost.o stub-obj-y += vnc.o +stub-obj-y += curses.o diff --git a/stubs/curses.c b/stubs/curses.c new file mode 100644 index 0000000..2115c77 --- /dev/null +++ b/stubs/curses.c @@ -0,0 +1,10 @@ +#include "qemu-common.h" +#include "ui/console.h" +#include "qemu/error-report.h" + +void curses_display_init(DisplayState *ds, int full_screen) +{ + /* This must never be called if CONFIG_CURSES is disabled */ + error_report("curses support is disabled"); + abort(); +} diff --git a/vl.c b/vl.c index 0558e87..3ca1c11 100644 --- a/vl.c +++ b/vl.c @@ -4568,11 +4568,9 @@ int main(int argc, char **argv, char **envp) case DT_NOGRAPHIC: (void)ds; /* avoid warning if no display is configured */ break; -#if defined(CONFIG_CURSES) case DT_CURSES: curses_display_init(ds, full_screen); break; -#endif #if defined(CONFIG_SDL) case DT_SDL: sdl_display_init(ds, full_screen, no_frame);