fixed xcb detection (but disabled for now)

This commit is contained in:
stefan schippers 2022-12-08 14:19:02 +01:00
parent 888ff17305
commit 7629e8e406
3 changed files with 8 additions and 18 deletions

View File

@ -232,7 +232,6 @@ int hook_detect_target()
} }
*/ */
} }
/* append("cc/cflags", " -Wformat -Werror=format-security"); */
} }
if (require("libs/io/popen/*", 0, 0) != 0) { if (require("libs/io/popen/*", 0, 0) != 0) {
@ -243,13 +242,11 @@ int hook_detect_target()
require("libs/io/dup2/*", 0, 0); /* Stefan: query dup2() availability */ require("libs/io/dup2/*", 0, 0); /* Stefan: query dup2() availability */
require("parsgen/flex/presents", 0, 1); require("parsgen/flex/presents", 0, 1);
require("parsgen/bison/presents", 0, 1); require("parsgen/bison/presents", 0, 1);
require("libs/script/tk/*", 0, 1); /* this will also bring libs/script/tcl */ require("libs/script/tk/*", 0, 1); /* this will also bring libs/script/tcl/* */
require("fstools/awk", 0, 1); require("fstools/awk", 0, 1);
require("libs/gui/xpm/*", 0, 1); require("libs/gui/xpm/*", 0, 1);
require("libs/gui/cairo/*", 0, 0); require("libs/gui/cairo/*", 0, 0);
if (require("libs/gui/cairo-xcb/*", 0, 0) != 0) { if (require("libs/gui/cairo-xcb/*", 0, 0) != 0) {
put("libs/gui/xcb/presents", sfalse); put("libs/gui/xcb/presents", sfalse);
} }
@ -269,9 +266,6 @@ int hook_detect_target()
} }
} }
return 0; return 0;
} }

View File

@ -28,11 +28,9 @@
/* ------------------------------------------------ */ /* ------------------------------------------------ */
Display *display; Display *display;
#if 0
#ifdef HAS_XCB #ifdef HAS_XCB
xcb_connection_t *xcb_conn; xcb_connection_t *xcb_conn;
#endif #endif
#endif
Colormap colormap; Colormap colormap;
unsigned char **pixdata; unsigned char **pixdata;

View File

@ -86,12 +86,6 @@
#include <X11/Xatom.h> #include <X11/Xatom.h>
#include <X11/xpm.h> #include <X11/xpm.h>
#if 0
#ifdef HAS_XCB
#include <X11/Xlib-xcb.h>
#endif
#endif
#define xunlink unlink #define xunlink unlink
#define xfseek fseek #define xfseek fseek
#define xftell ftell #define xftell ftell
@ -108,6 +102,12 @@ extern char win_temp_dir[PATH_MAX];
#define xftell _ftelli64 #define xftell _ftelli64
#endif #endif
#undef HAS_XCB
#ifdef HAS_XCB
#include <xcb/render.h>
#include <X11/Xlib-xcb.h>
#endif
#if HAS_CAIRO==1 #if HAS_CAIRO==1
#define DRAW_ALL_CAIRO 0 /* use cairo for all graphics. Work in progress! */ #define DRAW_ALL_CAIRO 0 /* use cairo for all graphics. Work in progress! */
#include <cairo.h> #include <cairo.h>
@ -1004,10 +1004,8 @@ extern unsigned char **pixdata;
extern unsigned char pixdata_init[22][32]; extern unsigned char pixdata_init[22][32];
extern Display *display; extern Display *display;
#undef HAS_XCB
#ifdef HAS_XCB #ifdef HAS_XCB
xcb_connection_t *xcb_conn; extern xcb_connection_t *xcb_conn;
#endif #endif
extern int screen_number; extern int screen_number;
extern int screendepth; extern int screendepth;