Gtk+ frontend fails to build

Bug #1177774 reported by Brad Smith
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
QEMU
Fix Released
Undecided
Unassigned

Bug Description

The QEMU Gtk+ frontend fails to build..

cc -I/home/ports/pobj/qemu-1.5.0-rc0/qemu-1.5.0-rc0/tcg -I/home/ports/pobj/qemu-1.5.0-rc0/qemu-1.5.0-rc0/tcg/i386 -I. -I/home/ports/pobj/qemu-1.5.0-rc0/qemu-1.5.0-rc0 -I/home/ports/pobj/qemu-1.5.0-rc0/qemu-1.5.0-rc0/include -Iui -Iui -fPIE -DPIE -m64 -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -Wstrict-prototypes -Wredundant-decls -Wall -Wundef -Wwrite-strings -Wmissing-prototypes -fno-strict-aliasing -I/usr/local/include -I/usr/X11R6/include -Wno-redundant-decls -DTIME_MAX=INT_MAX -Wendif-labels -Wmissing-include-dirs -Wnested-externs -Wformat-security -Wformat-y2k -Winit-self -Wold-style-definition -fstack-protector-all -I/usr/local/include -I/usr/local/include/p11-kit-1 -I/usr/include -I/usr/local/include/libpng -I/usr/local/include -I/usr/include -I/usr/X11R6/include/pixman-1 -I/home/ports/pobj/qemu-1.5.0-rc0/qemu-1.5.0-rc0/dtc/libfdt -pthread -I/usr/local/include/glib-2.0 -I/usr/local/lib/glib-2.0/include -I/usr/local/include -I/home/ports/pobj/qemu-1.5.0-rc0/qemu-1.5.0-rc0/tests -I/usr/local/include/gtk-2.0 -I/usr/local/lib/gtk-2.0/include -I/usr/local/include/pango-1.0 -I/usr/local/include/gio-unix-2.0/ -I/usr/X11R6/include -I/usr/local/include/cairo -I/usr/local/include/atk-1.0 -I/usr/X11R6/include/pixman-1 -I/usr/local/include/libpng -I/usr/local/include/gdk-pixbuf-2.0 -I/usr/local/include/harfbuzz -pthread -I/usr/local/include/glib-2.0 -I/usr/local/lib/glib-2.0/include -I/usr/local/include -I/usr/X11R6/include/freetype2 -I/usr/local/include/vte-0.0 -I/usr/local/include/gtk-2.0 -I/usr/local/lib/gtk-2.0/include -I/usr/local/include/pango-1.0 -I/usr/X11R6/include -I/usr/local/include/atk-1.0 -I/usr/local/include/gdk-pixbuf-2.0 -I/usr/local/include/harfbuzz -I/usr/local/include/gio-unix-2.0/ -pthread -I/usr/local/include/cairo -I/usr/local/include/glib-2.0 -I/usr/local/lib/glib-2.0/include -I/usr/local/include -I/usr/X11R6/include/pixman-1 -I/usr/X11R6/include/freetype2 -I/usr/local/include/libpng -MMD -MP -MT ui/gtk.o -MF ui/gtk.d -O2 -pipe -c -o ui/gtk.o ui/gtk.c
In file included from /usr/local/include/gtk-2.0/gtk/gtk.h:234,
                 from ui/gtk.c:44:
/usr/local/include/gtk-2.0/gtk/gtkitemfactory.h:47: warning: function declaration isn't a prototype
ui/gtk.c:58:17: warning: pty.h: No such file or directory
ui/gtk.c: In function 'gd_vc_init':
ui/gtk.c:1142: error: storage size of 'tty' isn't known
ui/gtk.c:1162: warning: implicit declaration of function 'openpty'
ui/gtk.c:1162: warning: nested extern declaration of 'openpty'
ui/gtk.c:1166: warning: implicit declaration of function 'tcgetattr'
ui/gtk.c:1166: warning: nested extern declaration of 'tcgetattr'
ui/gtk.c:1167: warning: implicit declaration of function 'cfmakeraw'
ui/gtk.c:1167: warning: nested extern declaration of 'cfmakeraw'
ui/gtk.c:1168: warning: implicit declaration of function 'tcsetattr'
ui/gtk.c:1168: warning: nested extern declaration of 'tcsetattr'
ui/gtk.c:1168: error: 'TCSAFLUSH' undeclared (first use in this function)
ui/gtk.c:1168: error: (Each undeclared identifier is reported only once
ui/gtk.c:1168: error: for each function it appears in.)
ui/gtk.c:1142: warning: unused variable 'tty'

Revision history for this message
Brad Smith (t-brad-3) wrote :

With the 1.5 release so near does no one really care that the Gtk+ frontend does not build? I would think this would be a pretty important bug to fix before the release.

Revision history for this message
Paolo Bonzini (bonzini) wrote :

Sending a patch soon, please reply with Tested-by if it works.

Revision history for this message
Brad Smith (t-brad-3) wrote :

For *BSD OS's you have to include termios.h..

In file included from /usr/local/include/gtk-2.0/gtk/gtk.h:234,
                 from ui/gtk.c:44:
/usr/local/include/gtk-2.0/gtk/gtkitemfactory.h:47: warning: function declaration isn't a prototype
ui/gtk.c: In function 'gd_vc_init':
ui/gtk.c:1141: error: storage size of 'tty' isn't known
ui/gtk.c:1165: warning: implicit declaration of function 'tcgetattr'
ui/gtk.c:1165: warning: nested extern declaration of 'tcgetattr'
ui/gtk.c:1166: warning: implicit declaration of function 'cfmakeraw'
ui/gtk.c:1166: warning: nested extern declaration of 'cfmakeraw'
ui/gtk.c:1167: warning: implicit declaration of function 'tcsetattr'
ui/gtk.c:1167: warning: nested extern declaration of 'tcsetattr'
ui/gtk.c:1167: error: 'TCSAFLUSH' undeclared (first use in this function)
ui/gtk.c:1167: error: (Each undeclared identifier is reported only once
ui/gtk.c:1167: error: for each function it appears in.)
ui/gtk.c:1141: warning: unused variable 'tty'

e.g.

#if defined(__GLIBC__)
# include <pty.h>
#elif defined CONFIG_BSD
# include <termios.h>
# if defined(__FreeBSD__) || defined(__FreeBSD_kernel__) || defined(__DragonFly__)
# include <libutil.h>
# else
# include <util.h>
# endif
#elif defined CONFIG_SOLARIS
# include <stropts.h>
#endif

Revision history for this message
Brad Smith (t-brad-3) wrote :

This should allow OS X to at least build. It looks like Solaris does not have openpty() and cfmakeraw()

Revision history for this message
Brad Smith (t-brad-3) wrote :

So the *BSD build has been fixed, but someone needs to look into fixing the Gtk+ backend on Solaris.

Revision history for this message
Thomas Huth (th-huth) wrote :

Looks like this issue has been fixed by this commit here:
http://git.qemu.org/?p=qemu.git;a=commitdiff;h=4efeabbbe8441cc327052304
... so I think it should be OK to close this now.

Changed in qemu:
status: New → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.