From dcf7890076d2a4bd16517ac017e0d46d29135bf9 Mon Sep 17 00:00:00 2001 From: "Enrico Weigelt, metux IT consult" Date: Wed, 16 Jul 2025 23:01:06 +0200 Subject: [PATCH] Xace: always build xace Xace callbacks are needed in many places, and the their overhead (when not actually used) is really minimal. So it doesn't make much sense having extra complexity for disabling it at build time. Signed-off-by: Enrico Weigelt, metux IT consult --- Xext/meson.build | 5 +---- Xext/xace.h | 25 ------------------------- include/meson.build | 2 +- meson.build | 13 ------------- meson_options.txt | 2 -- 5 files changed, 2 insertions(+), 45 deletions(-) diff --git a/Xext/meson.build b/Xext/meson.build index 2294902e6b..fe2e1d60b0 100644 --- a/Xext/meson.build +++ b/Xext/meson.build @@ -4,6 +4,7 @@ srcs_xext = [ 'shape.c', 'sleepuntil.c', 'sync.c', + 'xace.c', 'xcmisc.c', 'xtest.c', ] @@ -33,10 +34,6 @@ if build_screensaver srcs_xext += 'saver.c' endif -if build_xace - srcs_xext += 'xace.c' -endif - if build_xf86bigfont srcs_xext += 'xf86bigfont.c' endif diff --git a/Xext/xace.h b/Xext/xace.h index 5ad11fbfb9..8d8b2700eb 100644 --- a/Xext/xace.h +++ b/Xext/xace.h @@ -20,8 +20,6 @@ CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. #ifndef _XACE_H #define _XACE_H -#ifdef XACE - #define XACE_MAJOR_VERSION 2 #define XACE_MINOR_VERSION 0 @@ -107,27 +105,4 @@ void XaceCensorImage(ClientPtr client, int x, int y, int w, int h, unsigned int format, char *pBuf); -#else /* XACE */ - -/* Default window background */ -#define XaceBackgroundNoneState(w) None - -/* Define calls away when XACE is not being built. */ - -#ifdef __GNUC__ -#define XaceHookIsSet(args...) 0 -#define XaceHookDispatch(args...) Success -#define XaceHookPropertyAccess(args...) Success -#define XaceHookSelectionAccess(args...) Success -#define XaceCensorImage(args...) { ; } -#else -#define XaceHookIsSet(...) 0 -#define XaceHookDispatch(...) Success -#define XaceHookPropertyAccess(...) Success -#define XaceHookSelectionAccess(...) Success -#define XaceCensorImage(...) { ; } -#endif - -#endif /* XACE */ - #endif /* _XACE_H */ diff --git a/include/meson.build b/include/meson.build index 1e9ed19501..b942aff813 100644 --- a/include/meson.build +++ b/include/meson.build @@ -228,7 +228,7 @@ conf_data.set('RES', build_res ? '1' : false) conf_data.set('RENDER', '1') conf_data.set('SCREENSAVER', build_screensaver ? '1' : false) conf_data.set('SHAPE', '1') -conf_data.set('XACE', build_xace ? '1' : false) +conf_data.set('XACE', '1') conf_data.set('XCMISC', '1') conf_data.set('XCSECURITY', build_xsecurity ? '1' : false) conf_data.set('CONFIG_NAMESPACE', build_namespace ? '1' : false) diff --git a/meson.build b/meson.build index ae3cd8daa2..53a70d9728 100644 --- a/meson.build +++ b/meson.build @@ -502,22 +502,9 @@ if build_res build_hashtable = true endif -build_xace = get_option('xace') build_xinerama = get_option('xinerama') - build_xsecurity = get_option('xcsecurity') -if build_xsecurity - if not build_xace - error('cannot build Security extension without X-ACE') - endif -endif - build_namespace = get_option('namespace') -if build_namespace - if not build_xace - error('cannot build Container extension without X-ACE') - endif -endif build_xv = get_option('xv') build_xvmc = get_option('xvmc') diff --git a/meson_options.txt b/meson_options.txt index 4b30777ffe..f0aef3535b 100644 --- a/meson_options.txt +++ b/meson_options.txt @@ -82,8 +82,6 @@ option('screensaver', type: 'boolean', value: true, description: 'ScreenSaver extension') option('xres', type: 'boolean', value: true, description: 'XRes extension') -option('xace', type: 'boolean', value: true, - description: 'X-ACE extension') option('xselinux', type: 'combo', choices: ['true', 'false', 'auto'], value: 'auto', description: 'XSELINUX extension') option('namespace', type: 'boolean', value: true,