summaryrefslogtreecommitdiff
path: root/configure
diff options
context:
space:
mode:
authorPeter Maydell <peter.maydell@linaro.org>2018-03-05 15:16:30 +0000
committerPeter Maydell <peter.maydell@linaro.org>2018-03-05 15:16:30 +0000
commit4ee02f53be79f21602ace1ff4057c45bbf86ca64 (patch)
tree82bd6c34d73ce7ed8ae0ec582aa9940abc42ce8a /configure
parent41dfc0dc55f0b338ab3c1d29a1721441b76ebd03 (diff)
parent96400a148b3e1337e2c451e95bc3c3c69a05b67c (diff)
downloadqemu-4ee02f53be79f21602ace1ff4057c45bbf86ca64.tar.gz
Merge remote-tracking branch 'remotes/kraxel/tags/ui-20180305-pull-request' into staging
ui: build curses, gtk and sdl as modules. # gpg: Signature made Mon 05 Mar 2018 08:48:24 GMT # gpg: using RSA key 4CB6D8EED3E87138 # gpg: Good signature from "Gerd Hoffmann (work) <kraxel@redhat.com>" # gpg: aka "Gerd Hoffmann <gerd@kraxel.org>" # gpg: aka "Gerd Hoffmann (private) <kraxel@gmail.com>" # Primary key fingerprint: A032 8CFF B93A 17A7 9901 FE7D 4CB6 D8EE D3E8 7138 * remotes/kraxel/tags/ui-20180305-pull-request: ui/sdl: build as module audio: rename CONFIG_* to CONFIG_AUDIO_* ui/curses: build as module ui/gtk: build as module configure: opengl doesn't depend on x11 configure: add X11 vars to config-host.mak console: add ui module loading support console: add and use qemu_display_find_default egl-headless: switch over to new display registry curses: switch over to new display registry cocoa: switch over to new display registry sdl: switch over to new display registry console: add qemu display registry, add gtk Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'configure')
-rwxr-xr-xconfigure31
1 files changed, 18 insertions, 13 deletions
diff --git a/configure b/configure
index 2c1cb58520..27d3f66bd5 100755
--- a/configure
+++ b/configure
@@ -2520,9 +2520,8 @@ fi
##########################################
# X11 probe
-x11_cflags=
-x11_libs=-lX11
if $pkg_config --exists "x11"; then
+ have_x11=yes
x11_cflags=$($pkg_config --cflags x11)
x11_libs=$($pkg_config --libs x11)
fi
@@ -2555,10 +2554,10 @@ if test "$gtk" != "no"; then
gtk_libs=$($pkg_config --libs $gtkpackage)
gtk_version=$($pkg_config --modversion $gtkpackage)
if $pkg_config --exists "$gtkx11package >= $gtkversion"; then
+ need_x11=yes
gtk_cflags="$gtk_cflags $x11_cflags"
gtk_libs="$gtk_libs $x11_libs"
fi
- libs_softmmu="$gtk_libs $libs_softmmu"
gtk="yes"
elif test "$gtk" = "yes"; then
feature_not_found "gtk" "Install gtk3-devel"
@@ -2808,7 +2807,6 @@ if test "$vte" != "no"; then
vte_cflags=$($pkg_config --cflags $vtepackage)
vte_libs=$($pkg_config --libs $vtepackage)
vteversion=$($pkg_config --modversion $vtepackage)
- libs_softmmu="$vte_libs $libs_softmmu"
vte="yes"
elif test "$vte" = "yes"; then
if test "$gtkabi" = "3.0"; then
@@ -2923,6 +2921,7 @@ if test "$sdl" = "yes" ; then
int main(void) { return 0; }
EOF
if compile_prog "$sdl_cflags $x11_cflags" "$sdl_libs $x11_libs" ; then
+ need_x11=yes
sdl_cflags="$sdl_cflags $x11_cflags"
sdl_libs="$sdl_libs $x11_libs"
fi
@@ -3281,8 +3280,6 @@ EOF
unset IFS
if compile_prog "$curses_inc" "$curses_lib" ; then
curses_found=yes
- QEMU_CFLAGS="$curses_inc $QEMU_CFLAGS"
- libs_softmmu="$curses_lib $libs_softmmu"
break
fi
done
@@ -3778,9 +3775,9 @@ libs_softmmu="$libs_softmmu $fdt_libs"
if test "$opengl" != "no" ; then
opengl_pkgs="epoxy libdrm gbm"
- if $pkg_config $opengl_pkgs x11; then
- opengl_cflags="$($pkg_config --cflags $opengl_pkgs) $x11_cflags"
- opengl_libs="$($pkg_config --libs $opengl_pkgs) $x11_libs"
+ if $pkg_config $opengl_pkgs; then
+ opengl_cflags="$($pkg_config --cflags $opengl_pkgs)"
+ opengl_libs="$($pkg_config --libs $opengl_pkgs)"
opengl=yes
if test "$gtk" = "yes" && $pkg_config --exists "$gtkpackage >= 3.16"; then
gtk_gl="yes"
@@ -5984,7 +5981,7 @@ if test "$cap_ng" = "yes" ; then
fi
echo "CONFIG_AUDIO_DRIVERS=$audio_drv_list" >> $config_host_mak
for drv in $audio_drv_list; do
- def=CONFIG_$(echo $drv | LC_ALL=C tr '[a-z]' '[A-Z]')
+ def=CONFIG_AUDIO_$(echo $drv | LC_ALL=C tr '[a-z]' '[A-Z]')
echo "$def=y" >> $config_host_mak
done
echo "ALSA_LIBS=$alsa_libs" >> $config_host_mak
@@ -6036,8 +6033,13 @@ if test "$modules" = "yes"; then
echo "CONFIG_STAMP=_$( (echo $qemu_version; echo $pkgversion; cat $0) | $shacmd - | cut -f1 -d\ )" >> $config_host_mak
echo "CONFIG_MODULES=y" >> $config_host_mak
fi
+if test "$have_x11" = "yes" -a "$need_x11" = "yes"; then
+ echo "CONFIG_X11=y" >> $config_host_mak
+ echo "X11_CFLAGS=$x11_cflags" >> $config_host_mak
+ echo "X11_LIBS=$x11_libs" >> $config_host_mak
+fi
if test "$sdl" = "yes" ; then
- echo "CONFIG_SDL=y" >> $config_host_mak
+ echo "CONFIG_SDL=m" >> $config_host_mak
echo "CONFIG_SDLABI=$sdlabi" >> $config_host_mak
echo "SDL_CFLAGS=$sdl_cflags" >> $config_host_mak
echo "SDL_LIBS=$sdl_libs" >> $config_host_mak
@@ -6046,7 +6048,9 @@ if test "$cocoa" = "yes" ; then
echo "CONFIG_COCOA=y" >> $config_host_mak
fi
if test "$curses" = "yes" ; then
- echo "CONFIG_CURSES=y" >> $config_host_mak
+ echo "CONFIG_CURSES=m" >> $config_host_mak
+ echo "CURSES_CFLAGS=$curses_inc" >> $config_host_mak
+ echo "CURSES_LIBS=$curses_lib" >> $config_host_mak
fi
if test "$pipe2" = "yes" ; then
echo "CONFIG_PIPE2=y" >> $config_host_mak
@@ -6143,7 +6147,7 @@ if test "$glib_subprocess" = "yes" ; then
echo "CONFIG_HAS_GLIB_SUBPROCESS_TESTS=y" >> $config_host_mak
fi
if test "$gtk" = "yes" ; then
- echo "CONFIG_GTK=y" >> $config_host_mak
+ echo "CONFIG_GTK=m" >> $config_host_mak
echo "CONFIG_GTKABI=$gtkabi" >> $config_host_mak
echo "GTK_CFLAGS=$gtk_cflags" >> $config_host_mak
echo "GTK_LIBS=$gtk_libs" >> $config_host_mak
@@ -6194,6 +6198,7 @@ fi
if test "$vte" = "yes" ; then
echo "CONFIG_VTE=y" >> $config_host_mak
echo "VTE_CFLAGS=$vte_cflags" >> $config_host_mak
+ echo "VTE_LIBS=$vte_libs" >> $config_host_mak
fi
if test "$virglrenderer" = "yes" ; then
echo "CONFIG_VIRGL=y" >> $config_host_mak