Revert "configure: Abort if Xlib isn't present when building for XCB."

the change is wrong for multiple reasons:
- it is possible to build qt (the offscreen plugin) with xlib but
  without xcb, which was impossible after the change
- the check was built in a way that if xcb is auto-detected but xlib is
  missing, configure would abort (instead of disabling xcb), which is
  unreasonable (cf. linked task)
- it should be possible to build the xcb plugin without xlib - it's
  testing for xcb-xlib and should have the correct #ifdefs. if these are
  broken, they should be fixed. if this is unrealistic, the build system
  should be adjusted to this fact ... differently.

This reverts commit 683451e7c7.

Task-number: QTBUG-34382
Change-Id: I1c5811e2fb1f09b084b6aeb7350e5f376e1b9b82
Reviewed-by: Nicolás Alvarez <nicolas.alvarez@gmail.com>
Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
This commit is contained in:
Oswald Buddenhagen 2013-11-13 19:14:45 +01:00 committed by The Qt Project
parent 789b556ef1
commit edd51e4486

16
configure vendored
View File

@ -5080,6 +5080,11 @@ if [ "$CFG_TSLIB" != "no" ]; then
fi
fi
# Check we actually have X11 :-)
if compileTest x11/xlib "XLib"; then
QT_CONFIG="$QT_CONFIG xlib"
fi
if [ "$CFG_XCB" != "no" ]; then
if [ -n "$PKG_CONFIG" ] && $PKG_CONFIG --exists "xcb >= 1.5" 2>/dev/null; then
QMAKE_CFLAGS_XCB="`$PKG_CONFIG --cflags xcb 2>/dev/null`"
@ -5125,17 +5130,6 @@ if [ "$CFG_XCB" != "no" ]; then
fi
fi
# Check for X11. Eventually we should port everything to XCB,
# but for now the port is incomplete and Xlib is a requirement.
if compileTest x11/xlib "XLib"; then
QT_CONFIG="$QT_CONFIG xlib"
else
echo "The test for linking against Xlib failed!"
echo " You might need to install dependency packages."
echo " See src/plugins/platforms/xcb/README."
exit 1
fi
if compileTest qpa/xcb-xlib "xcb-xlib" $QMAKE_CFLAGS_XCB $QMAKE_LIBS_XCB; then
QT_CONFIG="$QT_CONFIG xcb-xlib"
fi