Commits:
-
c0654e90
by Alan Coopersmith at 2019-02-17T11:51:42-08:00
Update configure.ac bug URL for gitlab migration
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
-
77b0521b
by Alan Coopersmith at 2019-02-17T12:02:23-08:00
Update README for gitlab migration
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
-
dbfc1c65
by Alan Coopersmith at 2019-02-17T12:03:48-08:00
Add README.md to EXTRA_DIST
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
-
e7fcd702
by Alan Coopersmith at 2022-07-20T15:34:19-07:00
Build xz tarballs instead of bzip2
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
-
34b54a86
by Alan Coopersmith at 2022-07-20T15:34:24-07:00
Update m4 to xorg/util/xcb-util-m4@c617eee22ae5c285e79e81
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
-
b9b1e5a2
by Alan Coopersmith at 2022-07-20T15:35:56-07:00
gitlab CI: add a basic build test
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
-
c52eaa7f
by Peter Hutterer at 2022-07-24T14:22:02-07:00
autogen.sh: use exec instead of waiting for configure to finish
Syncs the invocation of configure with the one from the server.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
-
9f8dbe86
by Emil Velikov at 2022-07-24T14:22:02-07:00
autogen.sh: use quoted string variables
Place quotes around the $srcdir, $ORIGDIR and $0 variables to prevent
fall-outs, when they contain space.
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
-
82e8eac6
by Mihail Konev at 2022-07-24T14:22:07-07:00
autogen: add default patch prefix
Signed-off-by: Mihail Konev <k.mvc@ya.ru>
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
-
1f2e5330
by Alan Coopersmith at 2022-12-04T13:39:22-08:00
atoms: add format attribute to makenames() function
Quiets clang warning:
atoms.c:53:22: warning: format string is not a string literal [-Wformat-nonliteral]
n = vasprintf(&ret, fmt, ap);
^~~
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
-
50c93174
by Alan Coopersmith at 2022-12-04T13:43:02-08:00
atoms: Fix type mismatch in xcb_atom_name_unique()
Clears clang warnings of:
atoms.c:84:36: warning: format specifies type 'unsigned long' but
the argument has type 'uint32_t' (aka 'unsigned int') [-Wformat]
return makename("%s_U%lu", base, id);
~~~ ^~
%u
atoms.c:86:27: warning: format specifies type 'unsigned long' but
the argument has type 'uint32_t' (aka 'unsigned int') [-Wformat]
return makename("U%lu", id);
~~~ ^~
%u
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
-
5b966c72
by Alan Coopersmith at 2022-12-04T13:49:27-08:00
xcb_aux: handle -Wimplicit-int-conversion warnings from clang
xcb_aux.c:61:10: warning: implicit conversion loses integer precision:
'int' to 'uint8_t' (aka 'unsigned char') [-Wimplicit-int-conversion]
return depth;
~~~~~~ ^~~~~
xcb_aux.c:343:14: warning: implicit conversion loses integer precision:
'int' to 'uint16_t' (aka 'unsigned short') [-Wimplicit-int-conversion]
*red = r << n;
~ ~~^~~~
xcb_aux.c:344:16: warning: implicit conversion loses integer precision:
'int' to 'uint16_t' (aka 'unsigned short') [-Wimplicit-int-conversion]
*green = g << n;
~ ~~^~~~
xcb_aux.c:345:15: warning: implicit conversion loses integer precision:
'int' to 'uint16_t' (aka 'unsigned short') [-Wimplicit-int-conversion]
*blue = b << n;
~ ~~^~~~
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
-
3a157762
by Alan Coopersmith at 2022-12-19T18:09:12-08:00
xcb-util 0.4.1
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
-
240741ea
by Enrico Weigelt, metux IT consult at 2024-08-27T15:11:03+02:00
xcb_aux.h: fix missing includes
The header needs several times defined in other headers, which
haven't been included yet.
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
-
bffd8df1
by Enrico Weigelt, metux IT consult at 2024-09-06T13:53:42+02:00
.gitmodules: fix xcb-util-m4 url and CI failure
anongit.freedesktop.org doesn't seem to work anymore - using the canonical
gitlab https URL instead, so making the CIs work again.
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
Part-of: <https://gitlab.freedesktop.org/xorg/lib/libxcb-util/-/merge_requests/7>
11 changed files:
Changes:
.gitlab-ci.yml
|
1
|
+# vim: set expandtab shiftwidth=2 tabstop=8 textwidth=0 filetype=yaml:
|
|
2
|
+#
|
|
3
|
+# This CI uses the freedesktop.org ci-templates.
|
|
4
|
+# Please see the ci-templates documentation for details:
|
|
5
|
+# https://freedesktop.pages.freedesktop.org/ci-templates/
|
|
6
|
+
|
|
7
|
+.templates_sha: &template_sha 34f4ade99434043f88e164933f570301fd18b125 # see https://docs.gitlab.com/ee/ci/yaml/#includefile
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+include:
|
|
11
|
+ # Arch container builder template
|
|
12
|
+ - project: 'freedesktop/ci-templates'
|
|
13
|
+ ref: *template_sha
|
|
14
|
+ file: '/templates/arch.yml'
|
|
15
|
+ - project: 'freedesktop/ci-templates'
|
|
16
|
+ ref: *template_sha
|
|
17
|
+ file: '/templates/ci-fairy.yml'
|
|
18
|
+ - template: Security/SAST.gitlab-ci.yml
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+stages:
|
|
22
|
+ - prep # prep work like rebuilding the container images if there is a change
|
|
23
|
+ - build # for actually building and testing things in a container
|
|
24
|
+ - test
|
|
25
|
+ - deploy
|
|
26
|
+
|
|
27
|
+
|
|
28
|
+variables:
|
|
29
|
+ FDO_UPSTREAM_REPO: 'xorg/lib/libxcb-util'
|
|
30
|
+ # The tag should be updated each time the list of packages is updated.
|
|
31
|
+ # Changing a tag forces the associated image to be rebuilt.
|
|
32
|
+ # Note: the tag has no meaning, we use a date format purely for readability
|
|
33
|
+ FDO_DISTRIBUTION_TAG: '2022-07-20.0'
|
|
34
|
+ FDO_DISTRIBUTION_PACKAGES: 'git gcc pkgconf autoconf automake libtool make xorg-util-macros doxygen graphviz xorgproto libxcb'
|
|
35
|
+ GIT_SUBMODULE_STRATEGY: normal
|
|
36
|
+
|
|
37
|
+#
|
|
38
|
+# Verify that commit messages are as expected
|
|
39
|
+#
|
|
40
|
+check-commits:
|
|
41
|
+ extends:
|
|
42
|
+ - .fdo.ci-fairy
|
|
43
|
+ stage: prep
|
|
44
|
+ script:
|
|
45
|
+ - ci-fairy check-commits --junit-xml=results.xml
|
|
46
|
+ except:
|
|
47
|
+ - master@xorg/lib/libxcb-util
|
|
48
|
+ variables:
|
|
49
|
+ GIT_DEPTH: 100
|
|
50
|
+ artifacts:
|
|
51
|
+ reports:
|
|
52
|
+ junit: results.xml
|
|
53
|
+
|
|
54
|
+#
|
|
55
|
+# Verify that the merge request has the allow-collaboration checkbox ticked
|
|
56
|
+#
|
|
57
|
+check-merge-request:
|
|
58
|
+ extends:
|
|
59
|
+ - .fdo.ci-fairy
|
|
60
|
+ stage: deploy
|
|
61
|
+ script:
|
|
62
|
+ - ci-fairy check-merge-request --require-allow-collaboration --junit-xml=results.xml
|
|
63
|
+ artifacts:
|
|
64
|
+ when: on_failure
|
|
65
|
+ reports:
|
|
66
|
+ junit: results.xml
|
|
67
|
+ allow_failure: true
|
|
68
|
+
|
|
69
|
+
|
|
70
|
+#
|
|
71
|
+# Build a container with the given tag and the packages pre-installed.
|
|
72
|
+# This only happens if/when the tag changes, otherwise the existing image is
|
|
73
|
+# re-used.
|
|
74
|
+#
|
|
75
|
+container-prep:
|
|
76
|
+ extends:
|
|
77
|
+ - .fdo.container-build@arch
|
|
78
|
+ stage: prep
|
|
79
|
+ variables:
|
|
80
|
+ GIT_STRATEGY: none
|
|
81
|
+
|
|
82
|
+
|
|
83
|
+#
|
|
84
|
+# The default build, runs on the image built above.
|
|
85
|
+#
|
|
86
|
+build:
|
|
87
|
+ stage: build
|
|
88
|
+ extends:
|
|
89
|
+ - .fdo.distribution-image@arch
|
|
90
|
+ script:
|
|
91
|
+ - autoreconf -ivf
|
|
92
|
+ - mkdir _builddir
|
|
93
|
+ - pushd _builddir > /dev/null
|
|
94
|
+ - ../configure --disable-silent-rules
|
|
95
|
+ - make
|
|
96
|
+ - make check
|
|
97
|
+ - make distcheck
|
|
98
|
+ - popd > /dev/null |
.gitmodules
1
|
1
|
[submodule "m4"]
|
2
|
2
|
path = m4
|
3
|
|
- url = "" class="idiff left deletion" style="background-color: #fac5cd;">git://anongit.freedesktop.org/xcb/util-common-m4.git |
|
3
|
+ url = "" class="idiff left addition" style="background-color: #c7f0d2;">https://gitlab.freedesktop.org/xorg/util/xcb-util-m4.git |
Makefile.am
... |
... |
@@ -20,4 +20,4 @@ ChangeLog: |
20
|
20
|
|
21
|
21
|
dist-hook: ChangeLog INSTALL
|
22
|
22
|
|
23
|
|
-EXTRA_DIST = autogen.sh |
|
23
|
+EXTRA_DIST = autogen.sh README.md |
NEWS
|
1
|
+Release 0.4.1 (2022-12-19)
|
|
2
|
+==========================
|
|
3
|
+
|
|
4
|
+- Add standard X.Org package changes to autogen.sh
|
|
5
|
+- Build xz tarballs instead of bzip2
|
|
6
|
+- Clean up some compiler warnings from clang
|
|
7
|
+- Do updates for migration to gitlab
|
|
8
|
+
|
1
|
9
|
Release 0.4.0 (2014-10-15)
|
2
|
10
|
==========================
|
3
|
11
|
|
README
→
README.md
... |
... |
@@ -13,27 +13,29 @@ you're using and why you aren't in a mental hospital yet. We'd welcome |
13
|
13
|
patches/suggestions for enhancement and new libraries; Please report any
|
14
|
14
|
issues you find to the freedesktop.org bug tracker, at:
|
15
|
15
|
|
16
|
|
- <https://bugs.freedesktop.org/enter_bug.cgi?product=XCB>
|
|
16
|
+ https://gitlab.freedesktop.org/xorg/lib/libxcb-util/-/issues
|
17
|
17
|
|
18
|
18
|
Discussion about XCB occurs on the XCB mailing list:
|
19
|
19
|
|
20
|
|
- <mailto:xcb at lists.freedesktop.org>
|
21
|
|
- <http://lists.freedesktop.org/mailman/listinfo/xcb>
|
|
20
|
+ https://lists.freedesktop.org/mailman/listinfo/xcb
|
22
|
21
|
|
23
|
22
|
About XCB util module
|
24
|
23
|
=====================
|
25
|
24
|
|
26
|
|
-XCB util module provides the following library:
|
|
25
|
+XCB util module provides the following libraries:
|
27
|
26
|
|
28
|
27
|
- aux: Convenient access to connection setup and some core requests.
|
29
|
28
|
- atom: Standard core X atom constants and atom caching.
|
30
|
29
|
- event: Some utilities that have little to do with events any more.
|
31
|
30
|
|
32
|
|
-You can obtain the latest development versions of XCB util using
|
33
|
|
-GIT. For anonymous checkouts, use:
|
|
31
|
+You can obtain the latest development versions of XCB util using GIT from:
|
34
|
32
|
|
35
|
|
- git clone --recursive git://anongit.freedesktop.org/git/xcb/util
|
|
33
|
+ https://gitlab.freedesktop.org/xorg/lib/libxcb-util
|
36
|
34
|
|
37
|
|
-For developers, use:
|
|
35
|
+ For anonymous checkouts, use:
|
38
|
36
|
|
39
|
|
- git clone --recursive git+ssh://git.freedesktop.org/git/xcb/util |
|
37
|
+ git clone --recursive https://gitlab.freedesktop.org/xorg/lib/libxcb-util.git
|
|
38
|
+
|
|
39
|
+ For developers, use:
|
|
40
|
+
|
|
41
|
+ git clone --recursive git@gitlab.freedesktop.org:xorg/lib/libxcb-util.git |
autogen.sh
1
|
1
|
#! /bin/sh
|
2
|
2
|
|
3
|
|
-srcdir=`dirname $0`
|
|
3
|
+srcdir=`dirname "$0"`
|
4
|
4
|
test -z "$srcdir" && srcdir=.
|
5
|
5
|
|
6
|
6
|
ORIGDIR=`pwd`
|
7
|
|
-cd $srcdir
|
|
7
|
+cd "$srcdir"
|
8
|
8
|
|
9
|
9
|
# If this is a git checkout, verify that the submodules are initialized,
|
10
|
10
|
# otherwise autotools will just fail with an unhelpful error message.
|
... |
... |
@@ -22,8 +22,11 @@ then |
22
|
22
|
fi
|
23
|
23
|
|
24
|
24
|
autoreconf -v --install || exit 1
|
25
|
|
-cd $ORIGDIR || exit $?
|
|
25
|
+cd "$ORIGDIR" || exit $?
|
|
26
|
+
|
|
27
|
+git config --local --get format.subjectPrefix >/dev/null 2>&1 ||
|
|
28
|
+ git config --local format.subjectPrefix "PATCH libxcb-util"
|
26
|
29
|
|
27
|
30
|
if test -z "$NOCONFIGURE"; then
|
28
|
|
- $srcdir/configure "$@"
|
|
31
|
+ exec "$srcdir"/configure "$@"
|
29
|
32
|
fi |
configure.ac
1
|
1
|
AC_PREREQ(2.59c)
|
2
|
|
-AC_INIT([xcb-util],[0.4.0],
|
3
|
|
- [https://bugs.freedesktop.org/enter_bug.cgi?product=xcb&component=Utils],
|
|
2
|
+AC_INIT([xcb-util],[0.4.1],
|
|
3
|
+ [https://gitlab.freedesktop.org/xorg/lib/libxcb-util/-/issues],
|
4
|
4
|
[xcb-util])
|
5
|
5
|
AC_CONFIG_SRCDIR([Makefile.am])
|
6
|
6
|
AC_CONFIG_HEADERS([config.h])
|
7
|
7
|
AC_CONFIG_MACRO_DIR([m4])
|
8
|
|
-AM_INIT_AUTOMAKE([foreign dist-bzip2])
|
|
8
|
+AM_INIT_AUTOMAKE([foreign dist-xz])
|
9
|
9
|
|
10
|
10
|
XCB_UTIL_COMMON([1.4], [1.6])
|
11
|
11
|
|
m4
1
|
|
-Subproject commit f662e3a93ebdec3d1c9374382dcc070093a42fed |
|
1
|
+Subproject commit c617eee22ae5c285e79e81ec39ce96862fd3262f |
src/atoms.c
... |
... |
@@ -13,6 +13,14 @@ |
13
|
13
|
#include <stdarg.h>
|
14
|
14
|
#include "xcb_atom.h"
|
15
|
15
|
|
|
16
|
+#ifndef __has_attribute
|
|
17
|
+# define __has_attribute(x) 0 /* Compatibility with older compilers. */
|
|
18
|
+#endif
|
|
19
|
+
|
|
20
|
+#if __has_attribute(__format__) \
|
|
21
|
+ || defined(__GNUC__) && ((__GNUC__ * 100 + __GNUC_MINOR__) >= 203)
|
|
22
|
+__attribute__((__format__(__printf__,1,2)))
|
|
23
|
+#endif
|
16
|
24
|
static char *makename(const char *fmt, ...)
|
17
|
25
|
{
|
18
|
26
|
char *ret;
|
... |
... |
@@ -73,7 +81,7 @@ char *xcb_atom_name_by_resource(const char *base, uint32_t resource) |
73
|
81
|
char *xcb_atom_name_unique(const char *base, uint32_t id)
|
74
|
82
|
{
|
75
|
83
|
if(base)
|
76
|
|
- return makename("%s_U%lu", base, id);
|
|
84
|
+ return makename("%s_U%u", base, id);
|
77
|
85
|
else
|
78
|
|
- return makename("U%lu", id);
|
|
86
|
+ return makename("U%u", id);
|
79
|
87
|
} |
src/xcb_aux.c
... |
... |
@@ -48,7 +48,7 @@ xcb_aux_get_depth (xcb_connection_t *c, |
48
|
48
|
{
|
49
|
49
|
xcb_drawable_t drawable;
|
50
|
50
|
xcb_get_geometry_reply_t *geom;
|
51
|
|
- int depth = 0;
|
|
51
|
+ uint8_t depth = 0;
|
52
|
52
|
|
53
|
53
|
drawable = screen->root;
|
54
|
54
|
geom = xcb_get_geometry_reply (c, xcb_get_geometry(c, drawable), 0);
|
... |
... |
@@ -340,9 +340,9 @@ xcb_aux_parse_color(const char *color_name, |
340
|
340
|
} while (*color_name != '\0');
|
341
|
341
|
n <<= 2;
|
342
|
342
|
n = 16 - n;
|
343
|
|
- *red = r << n;
|
344
|
|
- *green = g << n;
|
345
|
|
- *blue = b << n;
|
|
343
|
+ *red = (uint16_t) (r << n);
|
|
344
|
+ *green = (uint16_t) (g << n);
|
|
345
|
+ *blue = (uint16_t) (b << n);
|
346
|
346
|
return 1;
|
347
|
347
|
}
|
348
|
348
|
|
src/xcb_aux.h
1
|
1
|
#ifndef __XCB_AUX_H__
|
2
|
2
|
#define __XCB_AUX_H__
|
3
|
3
|
|
|
4
|
+#include <stdint.h>
|
|
5
|
+#include <xcb/xcb.h>
|
|
6
|
+#include <xcb/xproto.h>
|
4
|
7
|
|
5
|
8
|
#ifdef __cplusplus
|
6
|
9
|
extern "C" {
|
|