sync code with last improvements from OpenBSD

This commit is contained in:
purplerain 2023-11-11 18:37:37 +00:00
parent 68fa196282
commit 9c49429a7e
Signed by: purplerain
GPG key ID: F42C07F07E2E35B7
4431 changed files with 2761157 additions and 1135565 deletions

View file

@ -1,5 +1,5 @@
/*
* Copyright (c) 1991, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1991, Oracle and/or its affiliates.
*
* Permission is hereby granted, free of charge, to any person obtaining a
* copy of this software and associated documentation files (the "Software"),

View file

@ -163,19 +163,6 @@ in this Software without prior written authorization from The Open Group.
# define _X_ATTRIBUTE_PRINTF(x,y)
#endif
/* requires xproto >= 7.0.22 - since this uses either gcc or C99 variable
argument macros, must be only used inside #ifdef _X_NONNULL guards, as
many legacy X clients are compiled in C89 mode still. */
#if __has_attribute(nonnull) \
&& defined(__STDC_VERSION__) && (__STDC_VERSION__ - 0 >= 199901L) /* C99 */
#define _X_NONNULL(...) __attribute__((nonnull(__VA_ARGS__)))
#elif __has_attribute(nonnull) \
|| defined(__GNUC__) && ((__GNUC__ * 100 + __GNUC_MINOR__) >= 303)
#define _X_NONNULL(args...) __attribute__((nonnull(args)))
#elif defined(__STDC_VERSION__) && (__STDC_VERSION__ - 0 >= 199901L) /* C99 */
#define _X_NONNULL(...) /* */
#endif
/* requires xproto >= 7.0.22 */
#if __has_attribute(__unused__) \
|| defined(__GNUC__) && ((__GNUC__ * 100 + __GNUC_MINOR__) >= 205)

View file

@ -60,7 +60,7 @@ in this Software without prior written authorization from The Open Group.
*/
# include <string.h>
# if defined(__SCO__) || defined(__UNIXWARE__) || defined(__sun) || defined(__CYGWIN__) || defined(_AIX) || defined(__APPLE__)
# if defined(__SCO__) || defined(__UNIXWARE__) || defined(__sun) || defined(__CYGWIN__) || defined(_AIX) || defined(__APPLE__) || defined(__FreeBSD__)
# include <strings.h>
# else
# ifndef index

View file

@ -27,7 +27,7 @@
**
** (c) Copyright 1996 Hewlett-Packard Company
** (c) Copyright 1996 International Business Machines Corp.
** (c) Copyright 1996, Oracle and/or its affiliates. All rights reserved.
** (c) Copyright 1996, Oracle and/or its affiliates.
** (c) Copyright 1996 Novell, Inc.
** (c) Copyright 1996 Digital Equipment Corp.
** (c) Copyright 1996 Fujitsu Limited

View file

@ -13,7 +13,7 @@
**
** (c) Copyright 1996 Hewlett-Packard Company
** (c) Copyright 1996 International Business Machines Corp.
** (c) Copyright 1996, Oracle and/or its affiliates. All rights reserved.
** (c) Copyright 1996, Oracle and/or its affiliates.
** (c) Copyright 1996 Novell, Inc.
** (c) Copyright 1996 Digital Equipment Corp.
** (c) Copyright 1996 Fujitsu Limited

View file

@ -27,14 +27,14 @@ typedef struct {
CARD32 mc_type;
CARD32 flags;
} xvmcSurfaceInfo;
#define sz_xvmcSurfaceInfo 24;
#define sz_xvmcSurfaceInfo 24
typedef struct {
CARD8 reqType;
CARD8 xvmcReqType;
CARD16 length;
} xvmcQueryVersionReq;
#define sz_xvmcQueryVersionReq 4;
#define sz_xvmcQueryVersionReq 4
typedef struct {
BYTE type; /* X_Reply */
@ -56,7 +56,7 @@ typedef struct {
CARD16 length;
CARD32 port;
} xvmcListSurfaceTypesReq;
#define sz_xvmcListSurfaceTypesReq 8;
#define sz_xvmcListSurfaceTypesReq 8
typedef struct {
BYTE type; /* X_Reply */
@ -83,7 +83,7 @@ typedef struct {
CARD16 height;
CARD32 flags;
} xvmcCreateContextReq;
#define sz_xvmcCreateContextReq 24;
#define sz_xvmcCreateContextReq 24
typedef struct {
BYTE type; /* X_Reply */
@ -106,7 +106,7 @@ typedef struct {
CARD16 length;
CARD32 context_id;
} xvmcDestroyContextReq;
#define sz_xvmcDestroyContextReq 8;
#define sz_xvmcDestroyContextReq 8
typedef struct {
CARD8 reqType;
@ -115,7 +115,7 @@ typedef struct {
CARD32 surface_id;
CARD32 context_id;
} xvmcCreateSurfaceReq;
#define sz_xvmcCreateSurfaceReq 12;
#define sz_xvmcCreateSurfaceReq 12
typedef struct {
BYTE type; /* X_Reply */
@ -137,7 +137,7 @@ typedef struct {
CARD16 length;
CARD32 surface_id;
} xvmcDestroySurfaceReq;
#define sz_xvmcDestroySurfaceReq 8;
#define sz_xvmcDestroySurfaceReq 8
typedef struct {
@ -150,7 +150,7 @@ typedef struct {
CARD16 width;
CARD16 height;
} xvmcCreateSubpictureReq;
#define sz_xvmcCreateSubpictureReq 20;
#define sz_xvmcCreateSubpictureReq 20
typedef struct {
BYTE type; /* X_Reply */
@ -174,7 +174,7 @@ typedef struct {
CARD16 length;
CARD32 subpicture_id;
} xvmcDestroySubpictureReq;
#define sz_xvmcDestroySubpictureReq 8;
#define sz_xvmcDestroySubpictureReq 8
typedef struct {
CARD8 reqType;
@ -183,7 +183,7 @@ typedef struct {
CARD32 port;
CARD32 surface_type_id;
} xvmcListSubpictureTypesReq;
#define sz_xvmcListSubpictureTypesReq 12;
#define sz_xvmcListSubpictureTypesReq 12
typedef struct {
BYTE type; /* X_Reply */
@ -207,7 +207,7 @@ typedef struct {
CARD32 shmKey;
CARD32 magic;
} xvmcGetDRInfoReq;
#define sz_xvmcGetDRInfoReq 16;
#define sz_xvmcGetDRInfoReq 16
typedef struct {
BYTE type; /* X_Reply */

View file

@ -1,5 +1,5 @@
/*
* Copyright (c) 2006, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2006, Oracle and/or its affiliates.
*
* Permission is hereby granted, free of charge, to any person obtaining a
* copy of this software and associated documentation files (the "Software"),

View file

@ -1,5 +1,5 @@
/*
* Copyright (c) 2006, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2006, Oracle and/or its affiliates.
*
* Permission is hereby granted, free of charge, to any person obtaining a
* copy of this software and associated documentation files (the "Software"),

View file

@ -1,6 +1,6 @@
/************************************************************
Copyright (c) 2003, Oracle and/or its affiliates. All rights reserved.
Copyright (c) 2003, Oracle and/or its affiliates.
Permission is hereby granted, free of charge, to any person obtaining a
copy of this software and associated documentation files (the "Software"),

View file

@ -25,7 +25,7 @@
#define PRESENT_NAME "Present"
#define PRESENT_MAJOR 1
#define PRESENT_MINOR 2
#define PRESENT_MINOR 3
#define PresentNumberErrors 0
#define PresentNumberEvents 0
@ -45,11 +45,15 @@
#define PresentOptionCopy (1 << 1)
#define PresentOptionUST (1 << 2)
#define PresentOptionSuboptimal (1 << 3)
#define PresentOptionAsyncMayTear (1 << 4)
#define PresentAllOptions (PresentOptionAsync | \
PresentOptionCopy | \
PresentOptionUST | \
PresentOptionSuboptimal)
PresentOptionSuboptimal | \
PresentOptionAsyncMayTear)
#define PresentAllAsyncOptions (PresentOptionAsync | PresentOptionAsyncMayTear)
/* Present capabilities */
@ -57,10 +61,14 @@
#define PresentCapabilityAsync 1
#define PresentCapabilityFence 2
#define PresentCapabilityUST 4
#define PresentCapabilityAsyncMayTear 8
#define PresentAllCapabilities (PresentCapabilityAsync | \
PresentCapabilityFence | \
PresentCapabilityUST)
PresentCapabilityUST | \
PresentCapabilityAsyncMayTear)
#define PresentAllAsyncCapabilities (PresentCapabilityAsync | PresentCapabilityAsyncMayTear)
/* Events */
#define PresentConfigureNotify 0

View file

@ -1,5 +1,5 @@
/*
* Copyright (c) 2006, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2006, Oracle and/or its affiliates.
* Copyright 2010 Red Hat, Inc.
*
* Permission is hereby granted, free of charge, to any person obtaining a

View file

@ -1,5 +1,5 @@
/*
* Copyright (c) 2006, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2006, Oracle and/or its affiliates.
* Copyright 2010 Red Hat, Inc.
*
* Permission is hereby granted, free of charge, to any person obtaining a
@ -146,4 +146,9 @@
/* The server may disconnect this client to shut down */
#define XFixesClientDisconnectFlagTerminate (1L << 0)
/*************** Version 6.1 ******************/
/* The server must terminate if this client exits */
#define XFixesClientDisconnectFlagForceTerminate (1L << 1)
#endif /* _XFIXESWIRE_H_ */

View file

@ -414,12 +414,6 @@ SOFTWARE.
#define XK_dead_belowcomma 0xfe6e
#define XK_dead_currency 0xfe6f
/* extra dead elements for German T3 layout */
#define XK_dead_lowline 0xfe90
#define XK_dead_aboveverticalline 0xfe91
#define XK_dead_belowverticalline 0xfe92
#define XK_dead_longsolidusoverlay 0xfe93
/* dead vowels for universal syllable entry */
#define XK_dead_a 0xfe80
#define XK_dead_A 0xfe81
@ -431,8 +425,10 @@ SOFTWARE.
#define XK_dead_O 0xfe87
#define XK_dead_u 0xfe88
#define XK_dead_U 0xfe89
#define XK_dead_small_schwa 0xfe8a
#define XK_dead_capital_schwa 0xfe8b
#define XK_dead_schwa 0xfe8a
#define XK_dead_SCHWA 0xfe8b
#define XK_dead_small_schwa 0xfe8a /* deprecated, remove in 2025 */
#define XK_dead_capital_schwa 0xfe8b /* deprecated, remove in 2025 */
#define XK_dead_greek 0xfe8c
@ -650,7 +646,8 @@ SOFTWARE.
#define XK_diaeresis 0x00a8 /* U+00A8 DIAERESIS */
#define XK_copyright 0x00a9 /* U+00A9 COPYRIGHT SIGN */
#define XK_ordfeminine 0x00aa /* U+00AA FEMININE ORDINAL INDICATOR */
#define XK_guillemotleft 0x00ab /* U+00AB LEFT-POINTING DOUBLE ANGLE QUOTATION MARK */
#define XK_guillemetleft 0x00ab /* U+00AB LEFT-POINTING DOUBLE ANGLE QUOTATION MARK */
#define XK_guillemotleft 0x00ab /* deprecated misspelling */
#define XK_notsign 0x00ac /* U+00AC NOT SIGN */
#define XK_hyphen 0x00ad /* U+00AD SOFT HYPHEN */
#define XK_registered 0x00ae /* U+00AE REGISTERED SIGN */
@ -665,8 +662,10 @@ SOFTWARE.
#define XK_periodcentered 0x00b7 /* U+00B7 MIDDLE DOT */
#define XK_cedilla 0x00b8 /* U+00B8 CEDILLA */
#define XK_onesuperior 0x00b9 /* U+00B9 SUPERSCRIPT ONE */
#define XK_masculine 0x00ba /* U+00BA MASCULINE ORDINAL INDICATOR */
#define XK_guillemotright 0x00bb /* U+00BB RIGHT-POINTING DOUBLE ANGLE QUOTATION MARK */
#define XK_ordmasculine 0x00ba /* U+00BA MASCULINE ORDINAL INDICATOR */
#define XK_masculine 0x00ba /* deprecated inconsistent name */
#define XK_guillemetright 0x00bb /* U+00BB RIGHT-POINTING DOUBLE ANGLE QUOTATION MARK */
#define XK_guillemotright 0x00bb /* deprecated misspelling */
#define XK_onequarter 0x00bc /* U+00BC VULGAR FRACTION ONE QUARTER */
#define XK_onehalf 0x00bd /* U+00BD VULGAR FRACTION ONE HALF */
#define XK_threequarters 0x00be /* U+00BE VULGAR FRACTION THREE QUARTERS */