]> git.ipfire.org Git - thirdparty/dbus.git/commitdiff
Emit an error when --with-x was given but no X11 libs were found
authorLars Wendler <polynomial-c@gentoo.org>
Tue, 1 Mar 2022 15:05:52 +0000 (16:05 +0100)
committerLars Wendler <polynomial-c@gentoo.org>
Tue, 1 Mar 2022 18:01:17 +0000 (19:01 +0100)
configure.ac

index a51e726533a746e220cce92d5dfd6d2422aee367..4420c6d377ab446efde3098c73a045545e92fe99 100644 (file)
@@ -1121,12 +1121,13 @@ else if test "x$with_x" != xno; then
             have_x11=yes
             DBUS_X_LIBS="$X_LIBS"
             DBUS_X_CFLAGS="$X_CFLAGS"
-            ],
-            [ have_x11=no ])
-
-    if test "x$have_x11" = xno; then
-        AC_MSG_WARN([Couldn't found X11, tried with pkg-config.])
-    fi
+            ], [
+             AS_IF([test "x$with_x" = xyes],
+                [AC_MSG_ERROR([Couldn't find X11, tried with pkg-config.])],
+                [AC_MSG_WARN([Couldn't find X11, tried with pkg-config.])]
+             )
+             have_x11=no
+            ])
 else
     AS_IF([test "x$enable_x11_autolaunch" = "xyes"], [
       AC_MSG_ERROR([--enable-x11-autolaunch and --without-x are not compatible])