Commit 0999ba8eaae33b633e80954701bda3e267cbc74d

Thomas de Grivel 2023-11-14T09:26:53

fix configure

diff --git a/libc3/window/configure b/libc3/window/configure
index 35ef542..e8c7b2d 100755
--- a/libc3/window/configure
+++ b/libc3/window/configure
@@ -22,18 +22,21 @@ echo "HAVE_ASAN = $HAVE_ASAN" >> ${CONFIG_MK}
 
 if pkg-config cairo; then
     HAVE_CAIRO=true
-    if pkg-config xcb; then
-        HAVE_XCB=true
-        ( cd cairo/xcb && ./configure; )
-        ( cd cairo/xcb/demo && ./configure; )
-    else
-        HAVE_XCB=false
-    fi
 else
     HAVE_CAIRO=false
 fi
-
 echo "HAVE_CAIRO = $HAVE_CAIRO" >> ${CONFIG_MK}
+
+if pkg-config xcb; then
+    HAVE_XCB=true
+else
+    HAVE_XCB=false
+fi
 echo "HAVE_XCB = $HAVE_XCB" >> ${CONFIG_MK}
 
 update_config_mk
+
+if ${HAVE_CAIRO} && ${HAVE_XCB}; then
+    ( cd cairo/xcb && ./configure; )
+    ( cd cairo/xcb/demo && ./configure; )
+fi