[Xcb] problem in xcb_conn.c, xcb_out.c, xcb_in.c

Vincent Torri Vincent.Torri at iecn.u-nancy.fr
Sat Mar 4 00:02:31 PST 2006


hey,

i've just tried to compile xcb. Here is the error:

xcb_conn.c:76: erreur: 'caddr_t' undeclared (first use in this function)

i've tried to look a bit at that type. In bits/types.h, there is that
typedef :

typedef char *__caddr_t;

and in sys/types (which includes bits/types.h), this one :

#ifdef	__USE_BSD
# ifndef __daddr_t_defined
typedef __daddr_t daddr_t;
typedef __caddr_t caddr_t;
#  define __daddr_t_defined
# endif
#endif

so, it's only defined on BSD, right ?

Btw, why using a posix type instead of a standard char *, as pad is
defined by a char ?

Same problem in xcb_out.c

In xcb_in.c : xcb_in.c:218: erreur: 'fd_set' undeclared (first use in this
function)

adding #include <sys/select.h> solves the problem. Using sys/types.h is
not good, as sys/select.h is only added when __USE_BSD is defined.

Finally, I add all the warnings that i've found (sorry, there are some
french words) :

xcb_conn.c: In function 'write_setup':
xcb_conn.c:66: attention : comparaison entre lment sign et lment non sign
xcb_conn.c:90: attention : comparaison entre lment sign et lment non sign
xcb_out.c: In function 'XCBSendRequest':
xcb_out.c:103: attention : comparaison entre lment sign et lment non sign
xcb_in.c: In function 'read_packet':
xcb_in.c:93: attention : comparaison entre lment sign et lment non sign
xcb_in.c:96: attention : comparaison entre lment sign et lment non sign
xcb_in.c: In function 'read_block':
xcb_in.c:212: attention : comparaison entre lment sign et lment non sign
xcb_util.c: In function 'XCBOpenUnix':
xcb_util.c:136: attention : initialisation manquante
xcb_util.c:136: attention : (near initialization for 'addr.sun_path')
xcb_util.c: In function 'XCBConnectToDisplayWithAuthInfo':
xcb_auth.c: In function 'authname_match':
xcb_auth.c:136: attention : comparaison entre lment sign et lment non sign
xcb_auth.c: Hors de toute fonction :
xcb_auth.c:203: attention : unused parameter 'sockname'
xcb_des.c:1: attention : ISO C interdit un fichier source vide
extensions/bigreq.c:10: attention : initialisation manquante
extensions/bigreq.c:10: attention : (near initialization for
'XCBBigRequestsId.global_id')
extensions/composite.c:10: attention : initialisation manquante
extensions/composite.c:10: attention : (near initialization for
'XCBCompositeId.global_id')
extensions/damage.c:10: attention : initialisation manquante
extensions/damage.c:10: attention : (near initialization for
'XCBDamageId.global_id')
extensions/glx.c:10: attention : initialisation manquante
extensions/glx.c:10: attention : (near initialization for
'XCBGlxId.global_id')
extensions/shm.c:10: attention : initialisation manquante
extensions/shm.c:10: attention : (near initialization for
'XCBShmId.global_id')
extensions/shape.c:10: attention : initialisation manquante
extensions/shape.c:10: attention : (near initialization for
'XCBShapeId.global_id')
extensions/randr.c:10: attention : initialisation manquante
extensions/randr.c:10: attention : (near initialization for
'XCBRandRId.global_id')
extensions/record.c:10: attention : initialisation manquante
extensions/record.c:10: attention : (near initialization for
'XCBRecordId.global_id')
extensions/render.c:10: attention : initialisation manquante
extensions/render.c:10: attention : (near initialization for
'XCBRenderId.global_id')
extensions/res.c:10: attention : initialisation manquante
extensions/res.c:10: attention : (near initialization for
'XCBResId.global_id')
extensions/dpms.c:10: attention : initialisation manquante
extensions/dpms.c:10: attention : (near initialization for
'XCBDPMSId.global_id')
extensions/sync.c:10: attention : initialisation manquante
extensions/sync.c:10: attention : (near initialization for
'XCBSyncId.global_id')
extensions/xc_misc.c:10: attention : initialisation manquante
extensions/xc_misc.c:10: attention : (near initialization for
'XCBXCMiscId.global_id')
extensions/xevie.c:10: attention : initialisation manquante
extensions/xevie.c:10: attention : (near initialization for
'XCBXevieId.global_id')
extensions/xf86dri.c:10: attention : initialisation manquante
extensions/xf86dri.c:10: attention : (near initialization for
'XCBXF86DriId.global_id')
extensions/xfixes.c:10: attention : initialisation manquante
extensions/xfixes.c:10: attention : (near initialization for
'XCBXFixesId.global_id')
extensions/xprint.c:10: attention : initialisation manquante
extensions/xprint.c:10: attention : (near initialization for
'XCBXPId.global_id')
extensions/xv.c:10: attention : initialisation manquante
extensions/xv.c:10: attention : (near initialization for
'XCBXvId.global_id')
extensions/xvmc.c:10: attention : initialisation manquante
extensions/xvmc.c:10: attention : (near initialization for
'XCBXvMCId.global_id')


Vincent


More information about the Xcb mailing list