diff options
Diffstat (limited to 'lib/libXdmcp')
56 files changed, 8588 insertions, 3828 deletions
diff --git a/lib/libXdmcp/A8Eq.c b/lib/libXdmcp/A8Eq.c deleted file mode 100644 index d274f788d..000000000 --- a/lib/libXdmcp/A8Eq.c +++ /dev/null @@ -1,49 +0,0 @@ -/* - * $Xorg: A8Eq.c,v 1.4 2001/02/09 02:03:48 xorgcvs Exp $ - * - * -Copyright 1989, 1998 The Open Group - -Permission to use, copy, modify, distribute, and sell this software and its -documentation for any purpose is hereby granted without fee, provided that -the above copyright notice appear in all copies and that both that -copyright notice and this permission notice appear in supporting -documentation. - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN -AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN -CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - -Except as contained in this notice, the name of The Open Group shall not be -used in advertising or otherwise to promote the sale, use or other dealings -in this Software without prior written authorization from The Open Group. - * * - * Author: Keith Packard, MIT X Consortium - */ - -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif -#include <X11/Xos.h> -#include <X11/X.h> -#include <X11/Xmd.h> -#include <X11/Xdmcp.h> - -int -XdmcpARRAY8Equal (ARRAY8Ptr array1, ARRAY8Ptr array2) -{ - int i; - - if (array1->length != array2->length) - return FALSE; - for (i = 0; i < (int)array1->length; i++) - if (array1->data[i] != array2->data[i]) - return FALSE; - return TRUE; -} diff --git a/lib/libXdmcp/AA16.c b/lib/libXdmcp/AA16.c deleted file mode 100644 index 5de5cafee..000000000 --- a/lib/libXdmcp/AA16.c +++ /dev/null @@ -1,51 +0,0 @@ -/* - * $Xorg: AA16.c,v 1.4 2001/02/09 02:03:48 xorgcvs Exp $ - * - * -Copyright 1989, 1998 The Open Group - -Permission to use, copy, modify, distribute, and sell this software and its -documentation for any purpose is hereby granted without fee, provided that -the above copyright notice appear in all copies and that both that -copyright notice and this permission notice appear in supporting -documentation. - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN -AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN -CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - -Except as contained in this notice, the name of The Open Group shall not be -used in advertising or otherwise to promote the sale, use or other dealings -in this Software without prior written authorization from The Open Group. - * * - * Author: Keith Packard, MIT X Consortium - */ - -/* $XFree86: xc/lib/Xdmcp/AA16.c,v 1.3 2001/01/17 19:42:43 dawes Exp $ */ - -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif -#include <X11/Xos.h> -#include <X11/X.h> -#include <X11/Xmd.h> -#include <X11/Xdmcp.h> - -int -XdmcpAllocARRAY16 (ARRAY16Ptr array, int length) -{ - CARD16Ptr newData; - - newData = (CARD16Ptr) Xalloc (length * sizeof (CARD16)); - if (!newData) - return FALSE; - array->length = length; - array->data = newData; - return TRUE; -} diff --git a/lib/libXdmcp/AA32.c b/lib/libXdmcp/AA32.c deleted file mode 100644 index fbeded1f9..000000000 --- a/lib/libXdmcp/AA32.c +++ /dev/null @@ -1,51 +0,0 @@ -/* - * $Xorg: AA32.c,v 1.4 2001/02/09 02:03:48 xorgcvs Exp $ - * - * -Copyright 1989, 1998 The Open Group - -Permission to use, copy, modify, distribute, and sell this software and its -documentation for any purpose is hereby granted without fee, provided that -the above copyright notice appear in all copies and that both that -copyright notice and this permission notice appear in supporting -documentation. - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN -AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN -CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - -Except as contained in this notice, the name of The Open Group shall not be -used in advertising or otherwise to promote the sale, use or other dealings -in this Software without prior written authorization from The Open Group. - * * - * Author: Keith Packard, MIT X Consortium - */ - -/* $XFree86: xc/lib/Xdmcp/AA32.c,v 1.3 2001/01/17 19:42:43 dawes Exp $ */ - -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif -#include <X11/Xos.h> -#include <X11/X.h> -#include <X11/Xmd.h> -#include <X11/Xdmcp.h> - -int -XdmcpAllocARRAY32 (ARRAY32Ptr array, int length) -{ - CARD32Ptr newData; - - newData = (CARD32Ptr) Xalloc (length * sizeof (CARD32)); - if (!newData) - return FALSE; - array->length = length; - array->data = newData; - return TRUE; -} diff --git a/lib/libXdmcp/AA8.c b/lib/libXdmcp/AA8.c deleted file mode 100644 index 391e78874..000000000 --- a/lib/libXdmcp/AA8.c +++ /dev/null @@ -1,51 +0,0 @@ -/* - * $Xorg: AA8.c,v 1.4 2001/02/09 02:03:48 xorgcvs Exp $ - * - * -Copyright 1989, 1998 The Open Group - -Permission to use, copy, modify, distribute, and sell this software and its -documentation for any purpose is hereby granted without fee, provided that -the above copyright notice appear in all copies and that both that -copyright notice and this permission notice appear in supporting -documentation. - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN -AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN -CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - -Except as contained in this notice, the name of The Open Group shall not be -used in advertising or otherwise to promote the sale, use or other dealings -in this Software without prior written authorization from The Open Group. - * * - * Author: Keith Packard, MIT X Consortium - */ - -/* $XFree86: xc/lib/Xdmcp/AA8.c,v 1.3 2001/01/17 19:42:43 dawes Exp $ */ - -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif -#include <X11/Xos.h> -#include <X11/X.h> -#include <X11/Xmd.h> -#include <X11/Xdmcp.h> - -int -XdmcpAllocARRAY8 (ARRAY8Ptr array, int length) -{ - CARD8Ptr newData; - - newData = (CARD8Ptr) Xalloc (length * sizeof (CARD8)); - if (!newData) - return FALSE; - array->length = length; - array->data = newData; - return TRUE; -} diff --git a/lib/libXdmcp/Alloc.c b/lib/libXdmcp/Alloc.c deleted file mode 100644 index 1c32270b0..000000000 --- a/lib/libXdmcp/Alloc.c +++ /dev/null @@ -1,79 +0,0 @@ -/* - * $Xorg: Alloc.c,v 1.4 2001/02/09 02:03:48 xorgcvs Exp $ - * - * -Copyright 1989, 1998 The Open Group - -Permission to use, copy, modify, distribute, and sell this software and its -documentation for any purpose is hereby granted without fee, provided that -the above copyright notice appear in all copies and that both that -copyright notice and this permission notice appear in supporting -documentation. - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN -AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN -CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - -Except as contained in this notice, the name of The Open Group shall not be -used in advertising or otherwise to promote the sale, use or other dealings -in this Software without prior written authorization from The Open Group. - * * - * Author: Keith Packard, MIT X Consortium - */ - -/* $XFree86: xc/lib/Xdmcp/Alloc.c,v 3.4 2001/07/25 15:04:50 dawes Exp $ */ - -/* stubs for use when Xalloc, Xrealloc and Xfree are not defined */ - -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif -#include <X11/Xos.h> -#include <X11/X.h> -#include <X11/Xmd.h> -#include <X11/Xdmcp.h> -#include <stdlib.h> - -/* this probably works for Mach-O too, but probably not for PE */ -#if defined(__ELF__) && defined(__GNUC__) && (__GNUC__ >= 3) -#define weak __attribute__((weak)) -#else -#define weak -#endif - -#ifdef __SUNPRO_C -#pragma weak Xalloc -#pragma weak Xrealloc -#pragma weak Xfree -#endif - -weak void * -Xalloc (unsigned long amount) -{ - if (amount == 0) - amount = 1; - return malloc (amount); -} - -weak void * -Xrealloc (void *old, unsigned long amount) -{ - if (amount == 0) - amount = 1; - if (!old) - return malloc (amount); - return realloc ((char *) old, amount); -} - -weak void -Xfree (void *old) -{ - if (old) - free ((char *) old); -} diff --git a/lib/libXdmcp/AofA8.c b/lib/libXdmcp/AofA8.c deleted file mode 100644 index fe773300d..000000000 --- a/lib/libXdmcp/AofA8.c +++ /dev/null @@ -1,51 +0,0 @@ -/* - * $Xorg: AofA8.c,v 1.4 2001/02/09 02:03:48 xorgcvs Exp $ - * - * -Copyright 1989, 1998 The Open Group - -Permission to use, copy, modify, distribute, and sell this software and its -documentation for any purpose is hereby granted without fee, provided that -the above copyright notice appear in all copies and that both that -copyright notice and this permission notice appear in supporting -documentation. - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN -AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN -CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - -Except as contained in this notice, the name of The Open Group shall not be -used in advertising or otherwise to promote the sale, use or other dealings -in this Software without prior written authorization from The Open Group. - * * - * Author: Keith Packard, MIT X Consortium - */ - -/* $XFree86: xc/lib/Xdmcp/AofA8.c,v 1.3 2001/01/17 19:42:43 dawes Exp $ */ - -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif -#include <X11/Xos.h> -#include <X11/X.h> -#include <X11/Xmd.h> -#include <X11/Xdmcp.h> - -int -XdmcpAllocARRAYofARRAY8 (ARRAYofARRAY8Ptr array, int length) -{ - ARRAY8Ptr newData; - - newData = (ARRAY8Ptr) Xalloc (length * sizeof (ARRAY8)); - if (!newData) - return FALSE; - array->length = length; - array->data = newData; - return TRUE; -} diff --git a/lib/libXdmcp/Array.c b/lib/libXdmcp/Array.c new file mode 100644 index 000000000..8862773b9 --- /dev/null +++ b/lib/libXdmcp/Array.c @@ -0,0 +1,247 @@ +/* +Copyright 1989, 1998 The Open Group + +Permission to use, copy, modify, distribute, and sell this software and its +documentation for any purpose is hereby granted without fee, provided that +the above copyright notice appear in all copies and that both that +copyright notice and this permission notice appear in supporting +documentation. + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN +AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +Except as contained in this notice, the name of The Open Group shall not be +used in advertising or otherwise to promote the sale, use or other dealings +in this Software without prior written authorization from The Open Group. + * + * Author: Keith Packard, MIT X Consortium + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif +#include <X11/Xos.h> +#include <X11/X.h> +#include <X11/Xmd.h> +#include <X11/Xdmcp.h> +#include <stdint.h> +#include <stdlib.h> + +/* + * This variant of malloc does not return NULL if zero size is passed into. + */ +static void * +xmalloc(size_t size) +{ + return malloc(size ? size : 1); +} + +/* + * This variant of realloc does not return NULL if zero size is passed into + */ +static void * +xrealloc(void *ptr, size_t size) +{ + return realloc(ptr, size ? size : 1); +} + +int +XdmcpAllocARRAY8 (ARRAY8Ptr array, int length) +{ + CARD8Ptr newData; + + /* length defined in ARRAY8 struct is a CARD16 (not CARD8 like the rest) */ + if (length > UINT16_MAX) + return FALSE; + + newData = (CARD8Ptr) xmalloc(length * sizeof (CARD8)); + if (!newData) + return FALSE; + array->length = (CARD16) length; + array->data = newData; + return TRUE; +} + +int +XdmcpAllocARRAY16 (ARRAY16Ptr array, int length) +{ + CARD16Ptr newData; + + /* length defined in ARRAY16 struct is a CARD8 */ + if (length > UINT8_MAX) + return FALSE; + + newData = (CARD16Ptr) xmalloc(length * sizeof (CARD16)); + if (!newData) + return FALSE; + array->length = (CARD8) length; + array->data = newData; + return TRUE; +} + +int +XdmcpAllocARRAY32 (ARRAY32Ptr array, int length) +{ + CARD32Ptr newData; + + /* length defined in ARRAY32 struct is a CARD8 */ + if (length > UINT8_MAX) + return FALSE; + + newData = (CARD32Ptr) xmalloc(length * sizeof (CARD32)); + if (!newData) + return FALSE; + array->length = (CARD8) length; + array->data = newData; + return TRUE; +} + +int +XdmcpAllocARRAYofARRAY8 (ARRAYofARRAY8Ptr array, int length) +{ + ARRAY8Ptr newData; + + /* length defined in ARRAYofARRAY8 struct is a CARD8 */ + if (length > UINT8_MAX) + return FALSE; + + newData = (ARRAY8Ptr) xmalloc(length * sizeof (ARRAY8)); + if (!newData) + return FALSE; + array->length = (CARD8) length; + array->data = newData; + return TRUE; +} + +int +XdmcpARRAY8Equal (const ARRAY8Ptr array1, const ARRAY8Ptr array2) +{ + if (array1->length != array2->length) + return FALSE; + if (memcmp(array1->data, array2->data, array1->length) != 0) + return FALSE; + return TRUE; +} + +int +XdmcpCopyARRAY8 (const ARRAY8Ptr src, ARRAY8Ptr dst) +{ + dst->length = src->length; + dst->data = (CARD8 *) xmalloc(dst->length * sizeof (CARD8)); + if (!dst->data) + return FALSE; + memmove (dst->data, src->data, src->length * sizeof (CARD8)); + return TRUE; +} + +int +XdmcpReallocARRAY8 (ARRAY8Ptr array, int length) +{ + CARD8Ptr newData; + + /* length defined in ARRAY8 struct is a CARD16 (not CARD8 like the rest) */ + if (length > UINT16_MAX) + return FALSE; + + newData = (CARD8Ptr) xrealloc(array->data, length * sizeof (CARD8)); + if (!newData) + return FALSE; + array->length = (CARD16) length; + array->data = newData; + return TRUE; +} + +int +XdmcpReallocARRAYofARRAY8 (ARRAYofARRAY8Ptr array, int length) +{ + ARRAY8Ptr newData; + + /* length defined in ARRAYofARRAY8 struct is a CARD8 */ + if (length > UINT8_MAX) + return FALSE; + + newData = (ARRAY8Ptr) xrealloc(array->data, length * sizeof (ARRAY8)); + if (!newData) + return FALSE; + array->length = (CARD8) length; + array->data = newData; + return TRUE; +} + +int +XdmcpReallocARRAY16 (ARRAY16Ptr array, int length) +{ + CARD16Ptr newData; + + /* length defined in ARRAY16 struct is a CARD8 */ + if (length > UINT8_MAX) + return FALSE; + newData = (CARD16Ptr) xrealloc(array->data, length * sizeof (CARD16)); + if (!newData) + return FALSE; + array->length = (CARD8) length; + array->data = newData; + return TRUE; +} + +int +XdmcpReallocARRAY32 (ARRAY32Ptr array, int length) +{ + CARD32Ptr newData; + + /* length defined in ARRAY32 struct is a CARD8 */ + if (length > UINT8_MAX) + return FALSE; + + newData = (CARD32Ptr) xrealloc(array->data, length * sizeof (CARD32)); + if (!newData) + return FALSE; + array->length = (CARD8) length; + array->data = newData; + return TRUE; +} + +void +XdmcpDisposeARRAY8 (ARRAY8Ptr array) +{ + free(array->data); + array->length = 0; + array->data = NULL; +} + +void +XdmcpDisposeARRAY16 (ARRAY16Ptr array) +{ + free(array->data); + array->length = 0; + array->data = NULL; +} + +void +XdmcpDisposeARRAY32 (ARRAY32Ptr array) +{ + free(array->data); + array->length = 0; + array->data = NULL; +} + +void +XdmcpDisposeARRAYofARRAY8 (ARRAYofARRAY8Ptr array) +{ + int i; + + if (array->data != NULL) { + for (i = 0; i < (int)array->length; i++) + XdmcpDisposeARRAY8 (&array->data[i]); + free(array->data); + } + array->length = 0; + array->data = NULL; +} diff --git a/lib/libXdmcp/CA8.c b/lib/libXdmcp/CA8.c deleted file mode 100644 index dc68c40f4..000000000 --- a/lib/libXdmcp/CA8.c +++ /dev/null @@ -1,48 +0,0 @@ -/* - * $Xorg: CA8.c,v 1.4 2001/02/09 02:03:48 xorgcvs Exp $ - * - * -Copyright 1989, 1998 The Open Group - -Permission to use, copy, modify, distribute, and sell this software and its -documentation for any purpose is hereby granted without fee, provided that -the above copyright notice appear in all copies and that both that -copyright notice and this permission notice appear in supporting -documentation. - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN -AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN -CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - -Except as contained in this notice, the name of The Open Group shall not be -used in advertising or otherwise to promote the sale, use or other dealings -in this Software without prior written authorization from The Open Group. - * * - * Author: Keith Packard, MIT X Consortium - */ - -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif -#include <X11/Xos.h> -#include <X11/X.h> -#include <X11/Xmd.h> -#include <X11/Xdmcp.h> -#include <X11/Xfuncs.h> - -int -XdmcpCopyARRAY8 (ARRAY8Ptr src, ARRAY8Ptr dst) -{ - dst->length = src->length; - dst->data = (CARD8 *) Xalloc (dst->length * sizeof (CARD8)); - if (!dst->data) - return FALSE; - memmove (dst->data, src->data, src->length * sizeof (CARD8)); - return TRUE; -} diff --git a/lib/libXdmcp/ChangeLog b/lib/libXdmcp/ChangeLog index 85804a2f6..1ebdd0441 100644 --- a/lib/libXdmcp/ChangeLog +++ b/lib/libXdmcp/ChangeLog @@ -1,3 +1,278 @@ +commit 7db29ff43eb3cdcbfe77c35ecc78c7ca3ddba595 +Author: Alan Coopersmith <alan.coopersmith@oracle.com> +Date: Fri Oct 29 15:13:16 2010 -0700 + + libXdmcp 1.1.0 + + Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com> + +commit fef4451fa3c55dcf81e7eee7ca001c57e301a150 +Author: Alan Coopersmith <alan.coopersmith@oracle.com> +Date: Wed Oct 27 23:01:49 2010 -0700 + + Remove AC_PROG_CC & AC_PROG_INSTALL that XORG_DEFAULT_OPTIONS already call + + Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com> + +commit 21c9f93bb5200dda0bfdd05b928c19829f23d646 +Author: Gaetan Nadon <memsize@videotron.ca> +Date: Tue Aug 3 15:28:51 2010 -0400 + + config: require xorg-macros minimum of 1.10 for XORG_CHECK_SGML_DOCTOOLS + + Signed-off-by: Gaetan Nadon <memsize@videotron.ca> + +commit adaf75c9aac6ca77b26379cc5e451728d9f1a78b +Author: Matt Dew <matt@osource.org> +Date: Sun Aug 1 14:23:18 2010 -0400 + + specs: replace troff source with docbook-xml source + + Signed-off-by: Gaetan Nadon <memsize@videotron.ca> + +commit 39993ef6f48cb3f9ee0cb0cd4dcef0d643cda698 +Author: Alan Coopersmith <alan.coopersmith@oracle.com> +Date: Fri May 7 19:21:42 2010 -0700 + + Replace comments pointing to non-public X Consortium defect reports + + Restored the original comments suggested by Paul Shearer of Sequent in the + patches he submitted with these fixes in the original X Consortium defect + reports from 1995, since modern readers can't refer to the referenced + bug reports in that old/closed bug db. + + 7328 Xdmcp: memory leak in XdmcpReadARRAYofARRAY8 when read fails + 7329 Xdmcp: XdmcpReadARRAY and XdmcpDisposeARRAY routines may free twice + + Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com> + +commit ea0e0d0e3d45eb5e71542af835194514a6f8801c +Author: Alan Coopersmith <alan.coopersmith@oracle.com> +Date: Fri May 7 19:03:54 2010 -0700 + + Fix order of CPPFLAGS passed to lint/compile steps + + Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com> + +commit 996d92d2710f9dc740351f4d9cbe14af64569689 +Author: Mikhail Gusarov <dottedmag@dottedmag.net> +Date: Fri May 7 20:22:20 2010 +0000 + + Get rid of Xalloc/Xrealloc/Xfree from X server or Xlib + + alloc/realloc/free calls are encapsulated in libXdmcp, so + there is no need to wrap allocation functions even under Windows + + Signed-off-by: Mikhail Gusarov <dottedmag@dottedmag.net> + Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com> + +commit 2a51e57425e1b4062a459a19b1860c9c9721d9ea +Author: Mikhail Gusarov <dottedmag@dottedmag.net> +Date: Fri May 7 20:06:52 2010 +0000 + + Nuke RCS tags + + Signed-off-by: Mikhail Gusarov <dottedmag@dottedmag.net> + Reviewed-by: Alan Coopersmith <alan.coopersmith@oracle.com> + Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com> + +commit 710d4a4298772cf06c22cce336622b33487b8b44 +Author: Mikhail Gusarov <dottedmag@dottedmag.net> +Date: Fri May 7 20:03:46 2010 +0000 + + Reshuffle functions to decrease amount of boilerplate + + It it a PitA to do anything with lot of nearly idenical code scattered + around in 30 files each containing 5-line function + + Signed-off-by: Mikhail Gusarov <dottedmag@dottedmag.net> + Reviewed-by: Alan Coopersmith <alan.coopersmith@oracle.com> + Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com> + +commit 1b22d07fc1268e7c5343cccd562ab69a101baf91 +Author: Alan Coopersmith <alan.coopersmith@oracle.com> +Date: Thu May 6 15:38:01 2010 -0700 + + Use stdint.h instead of limits.h for UINT*_MAX definitions + + While Solaris allows either one, C99 only requires them in stdint.h + and some platforms don't include them via limits.h + + Corrects tinderbox reported errors on Fedora 11 build machine: + + http://tinderbox.x.org/builds/2010-05-06-0019/logs/libXdmcp/#build + + AA32.c: In function 'XdmcpAllocARRAY32': + AA32.c:47: error: 'UINT8_MAX' undeclared (first use in this function) + + AA8.c: In function 'XdmcpAllocARRAY8': + AA8.c:47: error: 'UINT16_MAX' undeclared (first use in this function) + + Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com> + + Compiles clean on GNU/Linux AMD64 + Tested-by: Gaetan Nadon <memsize@videotron.ca> + +commit 30e388a8284ed100893983178acb6b4e3ff2b815 +Author: Alan Coopersmith <alan.coopersmith@oracle.com> +Date: Thu Apr 29 20:19:38 2010 -0700 + + Deal with lint warnings about implicit narrowing conversions + + Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com> + Reviewed-by: Matt Turner <mattst88@gmail.com> + +commit 110078a137915f486a13e0445ee9ba5e1558c081 +Author: Alan Coopersmith <alan.coopersmith@oracle.com> +Date: Thu Apr 29 19:57:46 2010 -0700 + + unifdef Lynx + + Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com> + Reviewed-by: Matt Turner <mattst88@gmail.com> + +commit 5ea80e308026357aeee8b56230e85cb4d2e87631 +Author: Alan Coopersmith <alan.coopersmith@oracle.com> +Date: Thu Apr 29 19:56:37 2010 -0700 + + XdmcpARRAY8Equal: Use memcmp instead of rolling our own + + Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com> + Reviewed-by: Matt Turner <mattst88@gmail.com> + +commit 27b1aa82a3f0db7d20a303ba093d1ec52de39bff +Author: Alan Coopersmith <alan.coopersmith@oracle.com> +Date: Thu Apr 29 19:51:25 2010 -0700 + + Constify function prototypes + + Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com> + Reviewed-by: Matt Turner <mattst88@gmail.com> + +commit 482b19329fac5e311fe0423e58f3e8c573b66114 +Author: Gaetan Nadon <memsize@videotron.ca> +Date: Mon Mar 29 16:50:34 2010 -0400 + + config: update AC_PREREQ statement to 2.60 + + Unrelated to the previous patches, the new value simply reflects + the reality that the minimum level for autoconf to configure + all x.org modules is 2.60 dated June 2006. + + ftp://ftp.gnu.org/gnu/autoconf/autoconf-2.60.tar.gz + + Signed-off-by: Gaetan Nadon <memsize@videotron.ca> + +commit 1c220fc14083ed8e1214329138d6ca548dad6dcc +Author: Gaetan Nadon <memsize@videotron.ca> +Date: Mon Mar 29 14:53:48 2010 -0400 + + config: remove the pkgconfig pc.in file from EXTRA_DIST + + Automake always includes it in the tarball. + + Signed-off-by: Gaetan Nadon <memsize@videotron.ca> + +commit 7367f2efae9561d87cabaa6e1740355b0aeda86f +Author: Gaetan Nadon <memsize@videotron.ca> +Date: Sat Mar 20 11:22:59 2010 -0400 + + make: remove unrequired -I${top_builddir}/include + + The -I${top_srcdir}/include in AM_CFLAGS is the correct one. + + Signed-off-by: Gaetan Nadon <memsize@videotron.ca> + +commit 2110b60cf122a624011ade8883af07b88bb2c2bb +Author: Gaetan Nadon <memsize@videotron.ca> +Date: Tue Feb 16 10:37:21 2010 -0500 + + config: move CWARNFLAGS from configure.ac to Makefile.am + + Compiler warning flags should be explicitly set in the makefile + rather than being merged with other packages compiler flags. + + Signed-off-by: Gaetan Nadon <memsize@videotron.ca> + +commit 7c1d4d862240a0b01eefbccf6b85e7a365e60ada +Author: Gaetan Nadon <memsize@videotron.ca> +Date: Fri Nov 27 20:56:04 2009 -0500 + + Makefile.am: add ChangeLog and INSTALL on MAINTAINERCLEANFILES + + Now that the INSTALL file is generated. + Allows running make maintainer-clean. + +commit 3c0e64988dad80afe5633c62c29ab3d1c54d2d23 +Author: Gaetan Nadon <memsize@videotron.ca> +Date: Wed Oct 28 14:09:10 2009 -0400 + + INSTALL, NEWS, README or AUTHORS files are missing/incorrect #24206 + + Add missing INSTALL file. Use standard GNU file on building tarball + README may have been updated + Remove AUTHORS file as it is empty and no content available yet. + Remove NEWS file as it is empty and no content available yet. + +commit a4a69387d7d0783326fbbd2b7b202498325d5f96 +Author: Gaetan Nadon <memsize@videotron.ca> +Date: Tue Oct 27 15:07:25 2009 -0400 + + Deploy the new XORG_DEFAULT_OPTIONS #24242 + + This macro aggregate a number of existing macros that sets commmon + X.Org components configuration options. It shields the configuration file from + future changes. + +commit 748ea77263a40080e665adc742a7a9791b4293c0 +Author: Gaetan Nadon <memsize@videotron.ca> +Date: Mon Oct 26 22:08:43 2009 -0400 + + Makefile.am: ChangeLog not required: EXTRA_DIST or *CLEANFILES #24432 + + ChangeLog filename is known to Automake and requires no further + coding in the makefile. + +commit 1ac333abaae4940467d2101d1080be9e46d90c78 +Author: Gaetan Nadon <memsize@videotron.ca> +Date: Thu Oct 22 12:34:19 2009 -0400 + + .gitignore: use common defaults with custom section # 24239 + + Using common defaults will reduce errors and maintenance. + Only the very small or inexistent custom section need periodic maintenance + when the structure of the component changes. Do not edit defaults. + +commit c362c31e583215855458bc5cbb9ed1020157b1ad +Author: Gaetan Nadon <memsize@videotron.ca> +Date: Sun Sep 27 16:28:37 2009 -0400 + + Makefile.am: do not include autogen.sh in distribution #24183 + + This is a private build script that should not be distributed + +commit d0f3336872147e925666aaf73b6c0c11aedc63c3 +Author: Jeremy Huddleston <jeremyhu@freedesktop.org> +Date: Wed Oct 21 12:47:24 2009 -0700 + + This is not a GNU project, so declare it foreign. + + On Wed, 2009-10-21 at 13:36 +1000, Peter Hutterer wrote: + > On Tue, Oct 20, 2009 at 08:23:55PM -0700, Jeremy Huddleston wrote: + > > I noticed an INSTALL file in xlsclients and libXvMC today, and it + > > was quite annoying to work around since 'autoreconf -fvi' replaces + > > it and git wants to commit it. Should these files even be in git? + > > Can I nuke them for the betterment of humanity and since they get + > > created by autoreconf anyways? + > + > See https://bugs.freedesktop.org/show_bug.cgi?id=24206 + + As an interim measure, replace AM_INIT_AUTOMAKE([dist-bzip2]) with + AM_INIT_AUTOMAKE([foreign dist-bzip2]). This will prevent the generation + of the INSTALL file. It is also part of the 24206 solution. + + Signed-off-by: Jeremy Huddleston <jeremyhu@freedesktop.org> + commit 3a7e0bb1cec5975e9fcbddc6569e7ac1aea550e5 Author: Peter Hutterer <peter.hutterer@who-t.net> Date: Fri Aug 28 15:32:31 2009 +1000 diff --git a/lib/libXdmcp/CmpKey.c b/lib/libXdmcp/CmpKey.c deleted file mode 100644 index 112bc2006..000000000 --- a/lib/libXdmcp/CmpKey.c +++ /dev/null @@ -1,49 +0,0 @@ -/* - * $Xorg: CmpKey.c,v 1.4 2001/02/09 02:03:48 xorgcvs Exp $ - * - * -Copyright 1989, 1998 The Open Group - -Permission to use, copy, modify, distribute, and sell this software and its -documentation for any purpose is hereby granted without fee, provided that -the above copyright notice appear in all copies and that both that -copyright notice and this permission notice appear in supporting -documentation. - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN -AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN -CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - -Except as contained in this notice, the name of The Open Group shall not be -used in advertising or otherwise to promote the sale, use or other dealings -in this Software without prior written authorization from The Open Group. - * * - * Author: Keith Packard, MIT X Consortium - */ - -/* $XFree86: xc/lib/Xdmcp/CmpKey.c,v 1.3 2001/01/17 19:42:43 dawes Exp $ */ - -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif -#include <X11/Xos.h> -#include <X11/X.h> -#include <X11/Xmd.h> -#include <X11/Xdmcp.h> - -int -XdmcpCompareKeys (XdmAuthKeyPtr a, XdmAuthKeyPtr b) -{ - int i; - - for (i = 0; i < 8; i++) - if (a->data[i] != b->data[i]) - return FALSE; - return TRUE; -} diff --git a/lib/libXdmcp/DA16.c b/lib/libXdmcp/DA16.c deleted file mode 100644 index 021accee5..000000000 --- a/lib/libXdmcp/DA16.c +++ /dev/null @@ -1,46 +0,0 @@ -/* - * $Xorg: DA16.c,v 1.4 2001/02/09 02:03:48 xorgcvs Exp $ - * - * -Copyright 1989, 1998 The Open Group - -Permission to use, copy, modify, distribute, and sell this software and its -documentation for any purpose is hereby granted without fee, provided that -the above copyright notice appear in all copies and that both that -copyright notice and this permission notice appear in supporting -documentation. - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN -AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN -CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - -Except as contained in this notice, the name of The Open Group shall not be -used in advertising or otherwise to promote the sale, use or other dealings -in this Software without prior written authorization from The Open Group. - * * - * Author: Keith Packard, MIT X Consortium - */ - -/* $XFree86: xc/lib/Xdmcp/DA16.c,v 1.5 2001/01/17 19:42:43 dawes Exp $ */ - -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif -#include <X11/Xos.h> -#include <X11/X.h> -#include <X11/Xmd.h> -#include <X11/Xdmcp.h> - -void -XdmcpDisposeARRAY16 (ARRAY16Ptr array) -{ - if (array->data != NULL) Xfree (array->data); - array->length = 0; - array->data = NULL; -} diff --git a/lib/libXdmcp/DA32.c b/lib/libXdmcp/DA32.c deleted file mode 100644 index 37cc99ad5..000000000 --- a/lib/libXdmcp/DA32.c +++ /dev/null @@ -1,44 +0,0 @@ -/* - * $Xorg: DA32.c,v 1.4 2001/02/09 02:03:48 xorgcvs Exp $ - * - * -Copyright 1989, 1998 The Open Group - -Permission to use, copy, modify, distribute, and sell this software and its -documentation for any purpose is hereby granted without fee, provided that -the above copyright notice appear in all copies and that both that -copyright notice and this permission notice appear in supporting -documentation. - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN -AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN -CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - -Except as contained in this notice, the name of The Open Group shall not be -used in advertising or otherwise to promote the sale, use or other dealings -in this Software without prior written authorization from The Open Group. - * * - * Author: Keith Packard, MIT X Consortium - */ - -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif -#include <X11/Xos.h> -#include <X11/X.h> -#include <X11/Xmd.h> -#include <X11/Xdmcp.h> - -void -XdmcpDisposeARRAY32 (ARRAY32Ptr array) -{ - if (array->data != NULL) Xfree (array->data); - array->length = 0; - array->data = NULL; -} diff --git a/lib/libXdmcp/DA8.c b/lib/libXdmcp/DA8.c deleted file mode 100644 index dbcd63542..000000000 --- a/lib/libXdmcp/DA8.c +++ /dev/null @@ -1,44 +0,0 @@ -/* - * $Xorg: DA8.c,v 1.4 2001/02/09 02:03:48 xorgcvs Exp $ - * - * -Copyright 1989, 1998 The Open Group - -Permission to use, copy, modify, distribute, and sell this software and its -documentation for any purpose is hereby granted without fee, provided that -the above copyright notice appear in all copies and that both that -copyright notice and this permission notice appear in supporting -documentation. - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN -AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN -CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - -Except as contained in this notice, the name of The Open Group shall not be -used in advertising or otherwise to promote the sale, use or other dealings -in this Software without prior written authorization from The Open Group. - * * - * Author: Keith Packard, MIT X Consortium - */ - -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif -#include <X11/Xos.h> -#include <X11/X.h> -#include <X11/Xmd.h> -#include <X11/Xdmcp.h> - -void -XdmcpDisposeARRAY8 (ARRAY8Ptr array) -{ - if (array->data != NULL) Xfree (array->data); - array->length = 0; - array->data = NULL; -} diff --git a/lib/libXdmcp/DAofA8.c b/lib/libXdmcp/DAofA8.c deleted file mode 100644 index 26f0a92dd..000000000 --- a/lib/libXdmcp/DAofA8.c +++ /dev/null @@ -1,50 +0,0 @@ -/* $Xdotorg: $ - * $Xorg: DAofA8.c,v 1.4 2001/02/09 02:03:48 xorgcvs Exp $ - * - * -Copyright 1989, 1998 The Open Group - -Permission to use, copy, modify, distribute, and sell this software and its -documentation for any purpose is hereby granted without fee, provided that -the above copyright notice appear in all copies and that both that -copyright notice and this permission notice appear in supporting -documentation. - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN -AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN -CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - -Except as contained in this notice, the name of The Open Group shall not be -used in advertising or otherwise to promote the sale, use or other dealings -in this Software without prior written authorization from The Open Group. - * * - * Author: Keith Packard, MIT X Consortium - */ - -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif -#include <X11/Xos.h> -#include <X11/X.h> -#include <X11/Xmd.h> -#include <X11/Xdmcp.h> - -void -XdmcpDisposeARRAYofARRAY8 (ARRAYofARRAY8Ptr array) -{ - int i; - - if (array->data != NULL) { - for (i = 0; i < (int)array->length; i++) - XdmcpDisposeARRAY8 (&array->data[i]); - Xfree (array->data); - } - array->length = 0; - array->data = NULL; -} diff --git a/lib/libXdmcp/DecKey.c b/lib/libXdmcp/DecKey.c deleted file mode 100644 index fe08cc33f..000000000 --- a/lib/libXdmcp/DecKey.c +++ /dev/null @@ -1,49 +0,0 @@ -/* - * $Xorg: DecKey.c,v 1.4 2001/02/09 02:03:48 xorgcvs Exp $ - * - * -Copyright 1989, 1998 The Open Group - -Permission to use, copy, modify, distribute, and sell this software and its -documentation for any purpose is hereby granted without fee, provided that -the above copyright notice appear in all copies and that both that -copyright notice and this permission notice appear in supporting -documentation. - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN -AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN -CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - -Except as contained in this notice, the name of The Open Group shall not be -used in advertising or otherwise to promote the sale, use or other dealings -in this Software without prior written authorization from The Open Group. - * * - * Author: Keith Packard, MIT X Consortium - */ - -/* $XFree86: xc/lib/Xdmcp/DecKey.c,v 1.3 2001/01/17 19:42:43 dawes Exp $ */ - -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif -#include <X11/Xos.h> -#include <X11/X.h> -#include <X11/Xmd.h> -#include <X11/Xdmcp.h> - -void -XdmcpDecrementKey (XdmAuthKeyPtr key) -{ - int i; - - i = 7; - while (key->data[i]-- == 0) - if (--i < 0) - break; -} diff --git a/lib/libXdmcp/Fill.c b/lib/libXdmcp/Fill.c index dd26d8b2d..98c324f45 100644 --- a/lib/libXdmcp/Fill.c +++ b/lib/libXdmcp/Fill.c @@ -1,7 +1,4 @@ /* - * $Xorg: Fill.c,v 1.4 2001/02/09 02:03:48 xorgcvs Exp $ - * - * Copyright 1989, 1998 The Open Group Permission to use, copy, modify, distribute, and sell this software and its @@ -27,8 +24,6 @@ in this Software without prior written authorization from The Open Group. * Author: Keith Packard, MIT X Consortium */ -/* $XFree86: xc/lib/Xdmcp/Fill.c,v 3.8 2001/07/23 13:15:42 dawes Exp $ */ - #ifdef WIN32 #define _WILLWINSOCK_ #endif @@ -39,6 +34,7 @@ in this Software without prior written authorization from The Open Group. #include <X11/X.h> #include <X11/Xmd.h> #include <X11/Xdmcp.h> +#include <stdlib.h> #ifdef STREAMSCONN #include <tiuser.h> @@ -46,11 +42,7 @@ in this Software without prior written authorization from The Open Group. #ifdef WIN32 #include <X11/Xwinsock.h> #else -#ifndef Lynx #include <sys/socket.h> -#else -#include <socket.h> -#endif /* !Lynx */ #endif #endif @@ -65,10 +57,10 @@ XdmcpFill (int fd, XdmcpBufferPtr buffer, XdmcpNetaddr from, int *fromlen) if (buffer->size < XDM_MAX_MSGLEN) { - newBuf = (BYTE *) Xalloc (XDM_MAX_MSGLEN); + newBuf = (BYTE *) malloc(XDM_MAX_MSGLEN); if (newBuf) { - Xfree (buffer->data); + free(buffer->data); buffer->data = newBuf; buffer->size = XDM_MAX_MSGLEN; } diff --git a/lib/libXdmcp/Flush.c b/lib/libXdmcp/Flush.c index 6a32e7c7a..cdcd1f096 100644 --- a/lib/libXdmcp/Flush.c +++ b/lib/libXdmcp/Flush.c @@ -1,7 +1,4 @@ /* - * $Xorg: Flush.c,v 1.4 2001/02/09 02:03:48 xorgcvs Exp $ - * - * Copyright 1989, 1998 The Open Group Permission to use, copy, modify, distribute, and sell this software and its @@ -27,8 +24,6 @@ in this Software without prior written authorization from The Open Group. * Author: Keith Packard, MIT X Consortium */ -/* $XFree86: xc/lib/Xdmcp/Flush.c,v 3.7 2001/07/23 13:15:42 dawes Exp $ */ - #ifdef WIN32 #define _WILLWINSOCK_ #endif @@ -46,11 +41,7 @@ in this Software without prior written authorization from The Open Group. #ifdef WIN32 #include <X11/Xwinsock.h> #else -#ifndef Lynx #include <sys/socket.h> -#else -#include <socket.h> -#endif /* !Lynx */ #endif #endif diff --git a/lib/libXdmcp/INSTALL b/lib/libXdmcp/INSTALL index 23e5f25d0..8b82ade08 100644 --- a/lib/libXdmcp/INSTALL +++ b/lib/libXdmcp/INSTALL @@ -1,16 +1,19 @@ Installation Instructions ************************* -Copyright (C) 1994, 1995, 1996, 1999, 2000, 2001, 2002, 2004, 2005 Free -Software Foundation, Inc. +Copyright (C) 1994, 1995, 1996, 1999, 2000, 2001, 2002, 2004, 2005, +2006, 2007, 2008 Free Software Foundation, Inc. -This file is free documentation; the Free Software Foundation gives + This file is free documentation; the Free Software Foundation gives unlimited permission to copy, distribute and modify it. Basic Installation ================== -These are generic installation instructions. + Briefly, the shell commands `./configure; make; make install' should +configure, build, and install this package. The following +more-detailed instructions are generic; see the `README' file for +instructions specific to this package. The `configure' shell script attempts to guess correct values for various system-dependent variables used during compilation. It uses @@ -23,9 +26,9 @@ debugging `configure'). It can also use an optional file (typically called `config.cache' and enabled with `--cache-file=config.cache' or simply `-C') that saves -the results of its tests to speed up reconfiguring. (Caching is +the results of its tests to speed up reconfiguring. Caching is disabled by default to prevent problems with accidental use of stale -cache files.) +cache files. If you need to do unusual things to compile the package, please try to figure out how `configure' could check whether to do them, and mail @@ -35,20 +38,17 @@ some point `config.cache' contains results you don't want to keep, you may remove or edit it. The file `configure.ac' (or `configure.in') is used to create -`configure' by a program called `autoconf'. You only need -`configure.ac' if you want to change it or regenerate `configure' using -a newer version of `autoconf'. +`configure' by a program called `autoconf'. You need `configure.ac' if +you want to change it or regenerate `configure' using a newer version +of `autoconf'. The simplest way to compile this package is: 1. `cd' to the directory containing the package's source code and type - `./configure' to configure the package for your system. If you're - using `csh' on an old version of System V, you might need to type - `sh ./configure' instead to prevent `csh' from trying to execute - `configure' itself. + `./configure' to configure the package for your system. - Running `configure' takes awhile. While running, it prints some - messages telling which features it is checking for. + Running `configure' might take a while. While running, it prints + some messages telling which features it is checking for. 2. Type `make' to compile the package. @@ -67,42 +67,57 @@ The simplest way to compile this package is: all sorts of other programs in order to regenerate files that came with the distribution. + 6. Often, you can also type `make uninstall' to remove the installed + files again. + Compilers and Options ===================== -Some systems require unusual options for compilation or linking that the -`configure' script does not know about. Run `./configure --help' for -details on some of the pertinent environment variables. + Some systems require unusual options for compilation or linking that +the `configure' script does not know about. Run `./configure --help' +for details on some of the pertinent environment variables. You can give `configure' initial values for configuration parameters by setting variables in the command line or in the environment. Here is an example: - ./configure CC=c89 CFLAGS=-O2 LIBS=-lposix + ./configure CC=c99 CFLAGS=-g LIBS=-lposix *Note Defining Variables::, for more details. Compiling For Multiple Architectures ==================================== -You can compile the package for more than one kind of computer at the + You can compile the package for more than one kind of computer at the same time, by placing the object files for each architecture in their -own directory. To do this, you must use a version of `make' that -supports the `VPATH' variable, such as GNU `make'. `cd' to the +own directory. To do this, you can use GNU `make'. `cd' to the directory where you want the object files and executables to go and run the `configure' script. `configure' automatically checks for the source code in the directory that `configure' is in and in `..'. - If you have to use a `make' that does not support the `VPATH' -variable, you have to compile the package for one architecture at a -time in the source code directory. After you have installed the -package for one architecture, use `make distclean' before reconfiguring -for another architecture. + With a non-GNU `make', it is safer to compile the package for one +architecture at a time in the source code directory. After you have +installed the package for one architecture, use `make distclean' before +reconfiguring for another architecture. + + On MacOS X 10.5 and later systems, you can create libraries and +executables that work on multiple system types--known as "fat" or +"universal" binaries--by specifying multiple `-arch' options to the +compiler but only a single `-arch' option to the preprocessor. Like +this: + + ./configure CC="gcc -arch i386 -arch x86_64 -arch ppc -arch ppc64" \ + CXX="g++ -arch i386 -arch x86_64 -arch ppc -arch ppc64" \ + CPP="gcc -E" CXXCPP="g++ -E" + + This is not guaranteed to produce working output in all cases, you +may have to build one architecture at a time and combine the results +using the `lipo' tool if you have problems. Installation Names ================== -By default, `make install' installs the package's commands under + By default, `make install' installs the package's commands under `/usr/local/bin', include files under `/usr/local/include', etc. You can specify an installation prefix other than `/usr/local' by giving `configure' the option `--prefix=PREFIX'. @@ -125,7 +140,7 @@ option `--program-prefix=PREFIX' or `--program-suffix=SUFFIX'. Optional Features ================= -Some packages pay attention to `--enable-FEATURE' options to + Some packages pay attention to `--enable-FEATURE' options to `configure', where FEATURE indicates an optional part of the package. They may also pay attention to `--with-PACKAGE' options, where PACKAGE is something like `gnu-as' or `x' (for the X Window System). The @@ -137,14 +152,36 @@ find the X include and library files automatically, but if it doesn't, you can use the `configure' options `--x-includes=DIR' and `--x-libraries=DIR' to specify their locations. +Particular systems +================== + + On HP-UX, the default C compiler is not ANSI C compatible. If GNU +CC is not installed, it is recommended to use the following options in +order to use an ANSI C compiler: + + ./configure CC="cc -Ae" + +and if that doesn't work, install pre-built binaries of GCC for HP-UX. + + On OSF/1 a.k.a. Tru64, some versions of the default C compiler cannot +parse its `<wchar.h>' header file. The option `-nodtk' can be used as +a workaround. If GNU CC is not installed, it is therefore recommended +to try + + ./configure CC="cc" + +and if that doesn't work, try + + ./configure CC="cc -nodtk" + Specifying the System Type ========================== -There may be some features `configure' cannot figure out automatically, -but needs to determine by the type of machine the package will run on. -Usually, assuming the package is built to be run on the _same_ -architectures, `configure' can figure that out, but if it prints a -message saying it cannot guess the machine type, give it the + There may be some features `configure' cannot figure out +automatically, but needs to determine by the type of machine the package +will run on. Usually, assuming the package is built to be run on the +_same_ architectures, `configure' can figure that out, but if it prints +a message saying it cannot guess the machine type, give it the `--build=TYPE' option. TYPE can either be a short name for the system type, such as `sun4', or a canonical name which has the form: @@ -170,9 +207,9 @@ eventually be run) with `--host=TYPE'. Sharing Defaults ================ -If you want to set default values for `configure' scripts to share, you -can create a site shell script called `config.site' that gives default -values for variables like `CC', `cache_file', and `prefix'. + If you want to set default values for `configure' scripts to share, +you can create a site shell script called `config.site' that gives +default values for variables like `CC', `cache_file', and `prefix'. `configure' looks for `PREFIX/share/config.site' if it exists, then `PREFIX/etc/config.site' if it exists. Or, you can set the `CONFIG_SITE' environment variable to the location of the site script. @@ -181,7 +218,7 @@ A warning: not all `configure' scripts look for a site script. Defining Variables ================== -Variables not defined in a site shell script can be set in the + Variables not defined in a site shell script can be set in the environment passed to `configure'. However, some packages may run configure again during the build, and the customized values of these variables may be lost. In order to avoid this problem, you should set @@ -190,21 +227,29 @@ them in the `configure' command line, using `VAR=value'. For example: ./configure CC=/usr/local2/bin/gcc causes the specified `gcc' to be used as the C compiler (unless it is -overridden in the site shell script). Here is a another example: +overridden in the site shell script). - /bin/bash ./configure CONFIG_SHELL=/bin/bash +Unfortunately, this technique does not work for `CONFIG_SHELL' due to +an Autoconf bug. Until the bug is fixed you can use this workaround: -Here the `CONFIG_SHELL=/bin/bash' operand causes subsequent -configuration-related scripts to be executed by `/bin/bash'. + CONFIG_SHELL=/bin/bash /bin/bash ./configure CONFIG_SHELL=/bin/bash `configure' Invocation ====================== -`configure' recognizes the following options to control how it operates. + `configure' recognizes the following options to control how it +operates. `--help' `-h' - Print a summary of the options to `configure', and exit. + Print a summary of all of the options to `configure', and exit. + +`--help=short' +`--help=recursive' + Print a summary of the options unique to this package's + `configure', and exit. The `short' variant lists options used + only in the top level, while the `recursive' variant lists options + also present in any nested packages. `--version' `-V' @@ -231,6 +276,16 @@ configuration-related scripts to be executed by `/bin/bash'. Look for the package's source code in directory DIR. Usually `configure' can determine that directory automatically. +`--prefix=DIR' + Use DIR as the installation prefix. *Note Installation Names:: + for more details, including other options available for fine-tuning + the installation locations. + +`--no-create' +`-n' + Run the configure checks, but stop before creating any output + files. + `configure' also accepts some other, not widely useful, options. Run `configure --help' for more details. diff --git a/lib/libXdmcp/IncKey.c b/lib/libXdmcp/IncKey.c deleted file mode 100644 index 292413a49..000000000 --- a/lib/libXdmcp/IncKey.c +++ /dev/null @@ -1,49 +0,0 @@ -/* - * $Xorg: IncKey.c,v 1.4 2001/02/09 02:03:48 xorgcvs Exp $ - * - * -Copyright 1989, 1998 The Open Group - -Permission to use, copy, modify, distribute, and sell this software and its -documentation for any purpose is hereby granted without fee, provided that -the above copyright notice appear in all copies and that both that -copyright notice and this permission notice appear in supporting -documentation. - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN -AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN -CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - -Except as contained in this notice, the name of The Open Group shall not be -used in advertising or otherwise to promote the sale, use or other dealings -in this Software without prior written authorization from The Open Group. - * * - * Author: Keith Packard, MIT X Consortium - */ - -/* $XFree86: xc/lib/Xdmcp/IncKey.c,v 1.3 2001/01/17 19:42:43 dawes Exp $ */ - -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif -#include <X11/Xos.h> -#include <X11/X.h> -#include <X11/Xmd.h> -#include <X11/Xdmcp.h> - -void -XdmcpIncrementKey (XdmAuthKeyPtr key) -{ - int i; - - i = 7; - while (++key->data[i] == 0) - if (--i < 0) - break; -} diff --git a/lib/libXdmcp/GenKey.c b/lib/libXdmcp/Key.c index 1469082ba..aa4add653 100644 --- a/lib/libXdmcp/GenKey.c +++ b/lib/libXdmcp/Key.c @@ -1,7 +1,4 @@ /* - * $Xorg: GenKey.c,v 1.4 2001/02/09 02:03:48 xorgcvs Exp $ - * - * Copyright 1989, 1998 The Open Group Permission to use, copy, modify, distribute, and sell this software and its @@ -23,12 +20,10 @@ CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. Except as contained in this notice, the name of The Open Group shall not be used in advertising or otherwise to promote the sale, use or other dealings in this Software without prior written authorization from The Open Group. - * * + * * Author: Keith Packard, MIT X Consortium */ -/* $XFree86: xc/lib/Xdmcp/GenKey.c,v 3.7 2001/07/25 15:04:50 dawes Exp $ */ - #ifdef HAVE_CONFIG_H #include <config.h> #endif @@ -72,3 +67,36 @@ XdmcpGenerateKey (XdmAuthKeyPtr key) getbits (lowbits, key->data); getbits (highbits, key->data + 4); } + +int +XdmcpCompareKeys (const XdmAuthKeyPtr a, const XdmAuthKeyPtr b) +{ + int i; + + for (i = 0; i < 8; i++) + if (a->data[i] != b->data[i]) + return FALSE; + return TRUE; +} + +void +XdmcpIncrementKey (XdmAuthKeyPtr key) +{ + int i; + + i = 7; + while (++key->data[i] == 0) + if (--i < 0) + break; +} + +void +XdmcpDecrementKey (XdmAuthKeyPtr key) +{ + int i; + + i = 7; + while (key->data[i]-- == 0) + if (--i < 0) + break; +} diff --git a/lib/libXdmcp/Makefile.am b/lib/libXdmcp/Makefile.am index e419649db..c3b85aad6 100644 --- a/lib/libXdmcp/Makefile.am +++ b/lib/libXdmcp/Makefile.am @@ -1,50 +1,24 @@ +SUBDIRS=doc + lib_LTLIBRARIES = libXdmcp.la -AM_CFLAGS=-I${top_srcdir}/include $(XDMCP_CFLAGS) +AM_CPPFLAGS = -I${top_srcdir}/include +AM_CFLAGS = \ + $(XDMCP_CFLAGS) \ + $(CWARNFLAGS) + libXdmcp_la_LDFLAGS = -version-number 6:0:0 -no-undefined libXdmcp_la_LIBADD = $(XDMCP_LIBS) libXdmcp_la_SOURCES = \ - A8Eq.c \ - AA16.c \ - AA32.c \ - AA8.c \ - Alloc.c \ - AofA8.c \ - CA8.c \ - CmpKey.c \ - DA16.c \ - DA32.c \ - DA8.c \ - DAofA8.c \ - DecKey.c \ + Array.c \ Fill.c \ Flush.c \ - GenKey.c \ - IncKey.c \ - RA16.c \ - RA32.c \ - RA8.c \ - RAofA8.c \ - RC16.c \ - RC32.c \ - RC8.c \ - RHead.c \ - RR.c \ - RaA16.c \ - RaA32.c \ - RaA8.c \ - RaAoA8.c \ + Key.c \ + Read.c \ Unwrap.c \ - WA16.c \ - WA32.c \ - WA8.c \ - WAofA8.c \ - WC16.c \ - WC32.c \ - WC8.c \ - Whead.c \ Wrap.c \ - Wrap.h + Wrap.h \ + Write.c if HASXDMAUTH nodist_libXdmcp_la_SOURCES = Wraphelp.c @@ -52,16 +26,14 @@ endif HASXDMAUTH xdmcpincludedir=$(includedir)/X11 -INCLUDES = \ - -I${top_builddir}/include - xdmcpinclude_HEADERS = \ include/X11/Xdmcp.h pkgconfigdir = $(libdir)/pkgconfig pkgconfig_DATA = xdmcp.pc -EXTRA_DIST = xdmcp.pc.in autogen.sh Wraphelp.c Wraphelp.README.crypto +MAINTAINERCLEANFILES = ChangeLog INSTALL +EXTRA_DIST = autogen.sh Wraphelp.c Wraphelp.README.crypto if LINT ALL_LINT_FLAGS=$(LINT_FLAGS) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \ @@ -80,13 +52,15 @@ $(LINTLIB): $(libXdmcp_la_SOURCES) $(nodist_libXdmcp_la_SOURCES) $(LINT) -y -oXdmcp -x $(ALL_LINT_FLAGS) $(libXdmcp_la_SOURCES) $(nodist_libXdmcp_la_SOURCES) endif MAKE_LINT_LIB -MAINTAINERCLEANFILES=ChangeLog -.PHONY: ChangeLog +.PHONY: ChangeLog INSTALL + +INSTALL: + $(INSTALL_CMD) ChangeLog: $(CHANGELOG_CMD) -dist-hook: ChangeLog +dist-hook: ChangeLog INSTALL CLEANFILES=$(lintlib_DATA) diff --git a/lib/libXdmcp/Makefile.in b/lib/libXdmcp/Makefile.in index 7618efbcf..a8a9bed3a 100644 --- a/lib/libXdmcp/Makefile.in +++ b/lib/libXdmcp/Makefile.in @@ -65,12 +65,8 @@ libLTLIBRARIES_INSTALL = $(INSTALL) LTLIBRARIES = $(lib_LTLIBRARIES) am__DEPENDENCIES_1 = libXdmcp_la_DEPENDENCIES = $(am__DEPENDENCIES_1) -am_libXdmcp_la_OBJECTS = A8Eq.lo AA16.lo AA32.lo AA8.lo Alloc.lo \ - AofA8.lo CA8.lo CmpKey.lo DA16.lo DA32.lo DA8.lo DAofA8.lo \ - DecKey.lo Fill.lo Flush.lo GenKey.lo IncKey.lo RA16.lo RA32.lo \ - RA8.lo RAofA8.lo RC16.lo RC32.lo RC8.lo RHead.lo RR.lo \ - RaA16.lo RaA32.lo RaA8.lo RaAoA8.lo Unwrap.lo WA16.lo WA32.lo \ - WA8.lo WAofA8.lo WC16.lo WC32.lo WC8.lo Whead.lo Wrap.lo +am_libXdmcp_la_OBJECTS = Array.lo Fill.lo Flush.lo Key.lo Read.lo \ + Unwrap.lo Wrap.lo Write.lo @HASXDMAUTH_TRUE@nodist_libXdmcp_la_OBJECTS = Wraphelp.lo libXdmcp_la_OBJECTS = $(am_libXdmcp_la_OBJECTS) \ $(nodist_libXdmcp_la_OBJECTS) @@ -87,6 +83,12 @@ LINK = $(LIBTOOL) --tag=CC --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ $(AM_LDFLAGS) $(LDFLAGS) -o $@ SOURCES = $(libXdmcp_la_SOURCES) $(nodist_libXdmcp_la_SOURCES) DIST_SOURCES = $(libXdmcp_la_SOURCES) +RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \ + html-recursive info-recursive install-data-recursive \ + install-exec-recursive install-info-recursive \ + install-recursive installcheck-recursive installdirs-recursive \ + pdf-recursive ps-recursive uninstall-info-recursive \ + uninstall-recursive lintlibDATA_INSTALL = $(INSTALL_DATA) pkgconfigDATA_INSTALL = $(INSTALL_DATA) DATA = $(lintlib_DATA) $(pkgconfig_DATA) @@ -94,6 +96,7 @@ xdmcpincludeHEADERS_INSTALL = $(INSTALL_HEADER) HEADERS = $(xdmcpinclude_HEADERS) ETAGS = etags CTAGS = ctags +DIST_SUBDIRS = $(SUBDIRS) DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) distdir = $(PACKAGE)-$(VERSION) top_distdir = $(distdir) @@ -104,12 +107,14 @@ am__remove_distdir = \ DIST_ARCHIVES = $(distdir).tar.gz $(distdir).tar.bz2 GZIP_ENV = --best distuninstallcheck_listfiles = find . -type f -print +distcleancheck_listfiles = find . -type f -print ACLOCAL = @ACLOCAL@ ADMIN_MAN_DIR = @ADMIN_MAN_DIR@ ADMIN_MAN_SUFFIX = @ADMIN_MAN_SUFFIX@ AMDEP_FALSE = @AMDEP_FALSE@ AMDEP_TRUE = @AMDEP_TRUE@ AMTAR = @AMTAR@ +AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ APP_MAN_DIR = @APP_MAN_DIR@ APP_MAN_SUFFIX = @APP_MAN_SUFFIX@ AR = @AR@ @@ -141,14 +146,26 @@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ +ENABLE_DOCS_FALSE = @ENABLE_DOCS_FALSE@ +ENABLE_DOCS_TRUE = @ENABLE_DOCS_TRUE@ EXEEXT = @EXEEXT@ F77 = @F77@ FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ +FOP = @FOP@ GREP = @GREP@ HASXDMAUTH_FALSE = @HASXDMAUTH_FALSE@ HASXDMAUTH_TRUE = @HASXDMAUTH_TRUE@ +HAVE_FOP_FALSE = @HAVE_FOP_FALSE@ +HAVE_FOP_TRUE = @HAVE_FOP_TRUE@ +HAVE_STYLESHEETS_FALSE = @HAVE_STYLESHEETS_FALSE@ +HAVE_STYLESHEETS_TRUE = @HAVE_STYLESHEETS_TRUE@ +HAVE_XMLTO_FALSE = @HAVE_XMLTO_FALSE@ +HAVE_XMLTO_TEXT_FALSE = @HAVE_XMLTO_TEXT_FALSE@ +HAVE_XMLTO_TEXT_TRUE = @HAVE_XMLTO_TEXT_TRUE@ +HAVE_XMLTO_TRUE = @HAVE_XMLTO_TRUE@ +INSTALL_CMD = @INSTALL_CMD@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ @@ -172,6 +189,7 @@ MAINTAINER_MODE_TRUE = @MAINTAINER_MODE_TRUE@ MAKEINFO = @MAKEINFO@ MAKE_LINT_LIB_FALSE = @MAKE_LINT_LIB_FALSE@ MAKE_LINT_LIB_TRUE = @MAKE_LINT_LIB_TRUE@ +MAN_SUBSTS = @MAN_SUBSTS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ NMEDIT = @NMEDIT@ @@ -190,9 +208,14 @@ SED = @SED@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ STRIP = @STRIP@ +STYLESHEET_SRCDIR = @STYLESHEET_SRCDIR@ VERSION = @VERSION@ XDMCP_CFLAGS = @XDMCP_CFLAGS@ XDMCP_LIBS = @XDMCP_LIBS@ +XMLTO = @XMLTO@ +XORG_MAN_PAGE = @XORG_MAN_PAGE@ +XORG_SGML_PATH = @XORG_SGML_PATH@ +XSL_STYLESHEET = @XSL_STYLESHEET@ ac_ct_CC = @ac_ct_CC@ ac_ct_CXX = @ac_ct_CXX@ ac_ct_F77 = @ac_ct_F77@ @@ -213,7 +236,6 @@ build_os = @build_os@ build_vendor = @build_vendor@ datadir = @datadir@ datarootdir = @datarootdir@ -distcleancheck_listfiles = @distcleancheck_listfiles@ docdir = @docdir@ dvidir = @dvidir@ exec_prefix = @exec_prefix@ @@ -241,73 +263,43 @@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ sysconfdir = @sysconfdir@ target_alias = @target_alias@ +SUBDIRS = doc lib_LTLIBRARIES = libXdmcp.la -AM_CFLAGS = -I${top_srcdir}/include $(XDMCP_CFLAGS) +AM_CPPFLAGS = -I${top_srcdir}/include +AM_CFLAGS = \ + $(XDMCP_CFLAGS) \ + $(CWARNFLAGS) + libXdmcp_la_LDFLAGS = -version-number 6:0:0 -no-undefined libXdmcp_la_LIBADD = $(XDMCP_LIBS) libXdmcp_la_SOURCES = \ - A8Eq.c \ - AA16.c \ - AA32.c \ - AA8.c \ - Alloc.c \ - AofA8.c \ - CA8.c \ - CmpKey.c \ - DA16.c \ - DA32.c \ - DA8.c \ - DAofA8.c \ - DecKey.c \ + Array.c \ Fill.c \ Flush.c \ - GenKey.c \ - IncKey.c \ - RA16.c \ - RA32.c \ - RA8.c \ - RAofA8.c \ - RC16.c \ - RC32.c \ - RC8.c \ - RHead.c \ - RR.c \ - RaA16.c \ - RaA32.c \ - RaA8.c \ - RaAoA8.c \ + Key.c \ + Read.c \ Unwrap.c \ - WA16.c \ - WA32.c \ - WA8.c \ - WAofA8.c \ - WC16.c \ - WC32.c \ - WC8.c \ - Whead.c \ Wrap.c \ - Wrap.h + Wrap.h \ + Write.c @HASXDMAUTH_TRUE@nodist_libXdmcp_la_SOURCES = Wraphelp.c xdmcpincludedir = $(includedir)/X11 -INCLUDES = \ - -I${top_builddir}/include - xdmcpinclude_HEADERS = \ include/X11/Xdmcp.h pkgconfigdir = $(libdir)/pkgconfig pkgconfig_DATA = xdmcp.pc -EXTRA_DIST = xdmcp.pc.in autogen.sh Wraphelp.c Wraphelp.README.crypto +MAINTAINERCLEANFILES = ChangeLog INSTALL +EXTRA_DIST = autogen.sh Wraphelp.c Wraphelp.README.crypto @LINT_TRUE@ALL_LINT_FLAGS = $(LINT_FLAGS) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \ @LINT_TRUE@ $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) @MAKE_LINT_LIB_TRUE@lintlibdir = $(libdir) @MAKE_LINT_LIB_TRUE@lintlib_DATA = $(LINTLIB) -MAINTAINERCLEANFILES = ChangeLog CLEANFILES = $(lintlib_DATA) all: config.h - $(MAKE) $(AM_MAKEFLAGS) all-am + $(MAKE) $(AM_MAKEFLAGS) all-recursive .SUFFIXES: .SUFFIXES: .c .lo .o .obj @@ -317,15 +309,15 @@ $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__confi @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ - echo ' cd $(srcdir) && $(AUTOMAKE) --gnu '; \ - cd $(srcdir) && $(AUTOMAKE) --gnu \ + echo ' cd $(srcdir) && $(AUTOMAKE) --foreign '; \ + cd $(srcdir) && $(AUTOMAKE) --foreign \ && exit 0; \ exit 1;; \ esac; \ done; \ - echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu Makefile'; \ + echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign Makefile'; \ cd $(top_srcdir) && \ - $(AUTOMAKE) --gnu Makefile + $(AUTOMAKE) --foreign Makefile .PRECIOUS: Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @case '$?' in \ @@ -399,47 +391,15 @@ mostlyclean-compile: distclean-compile: -rm -f *.tab.c -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/A8Eq.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/AA16.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/AA32.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/AA8.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/Alloc.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/AofA8.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/CA8.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/CmpKey.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/DA16.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/DA32.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/DA8.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/DAofA8.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/DecKey.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/Array.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/Fill.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/Flush.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/GenKey.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/IncKey.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/RA16.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/RA32.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/RA8.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/RAofA8.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/RC16.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/RC32.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/RC8.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/RHead.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/RR.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/RaA16.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/RaA32.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/RaA8.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/RaAoA8.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/Key.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/Read.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/Unwrap.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/WA16.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/WA32.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/WA8.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/WAofA8.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/WC16.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/WC32.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/WC8.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/Whead.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/Wrap.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/Wraphelp.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/Write.Plo@am__quote@ .c.o: @am__fastdepCC_TRUE@ if $(COMPILE) -MT $@ -MD -MP -MF "$(DEPDIR)/$*.Tpo" -c -o $@ $<; \ @@ -523,6 +483,77 @@ uninstall-xdmcpincludeHEADERS: rm -f "$(DESTDIR)$(xdmcpincludedir)/$$f"; \ done +# This directory's subdirectories are mostly independent; you can cd +# into them and run `make' without going through this Makefile. +# To change the values of `make' variables: instead of editing Makefiles, +# (1) if the variable is set in `config.status', edit `config.status' +# (which will cause the Makefiles to be regenerated when you run `make'); +# (2) otherwise, pass the desired values on the `make' command line. +$(RECURSIVE_TARGETS): + @failcom='exit 1'; \ + for f in x $$MAKEFLAGS; do \ + case $$f in \ + *=* | --[!k]*);; \ + *k*) failcom='fail=yes';; \ + esac; \ + done; \ + dot_seen=no; \ + target=`echo $@ | sed s/-recursive//`; \ + list='$(SUBDIRS)'; for subdir in $$list; do \ + echo "Making $$target in $$subdir"; \ + if test "$$subdir" = "."; then \ + dot_seen=yes; \ + local_target="$$target-am"; \ + else \ + local_target="$$target"; \ + fi; \ + (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \ + || eval $$failcom; \ + done; \ + if test "$$dot_seen" = "no"; then \ + $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \ + fi; test -z "$$fail" + +mostlyclean-recursive clean-recursive distclean-recursive \ +maintainer-clean-recursive: + @failcom='exit 1'; \ + for f in x $$MAKEFLAGS; do \ + case $$f in \ + *=* | --[!k]*);; \ + *k*) failcom='fail=yes';; \ + esac; \ + done; \ + dot_seen=no; \ + case "$@" in \ + distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \ + *) list='$(SUBDIRS)' ;; \ + esac; \ + rev=''; for subdir in $$list; do \ + if test "$$subdir" = "."; then :; else \ + rev="$$subdir $$rev"; \ + fi; \ + done; \ + rev="$$rev ."; \ + target=`echo $@ | sed s/-recursive//`; \ + for subdir in $$rev; do \ + echo "Making $$target in $$subdir"; \ + if test "$$subdir" = "."; then \ + local_target="$$target-am"; \ + else \ + local_target="$$target"; \ + fi; \ + (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \ + || eval $$failcom; \ + done && test -z "$$fail" +tags-recursive: + list='$(SUBDIRS)'; for subdir in $$list; do \ + test "$$subdir" = . || (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) tags); \ + done +ctags-recursive: + list='$(SUBDIRS)'; for subdir in $$list; do \ + test "$$subdir" = . || (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) ctags); \ + done + ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES) list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ unique=`for i in $$list; do \ @@ -533,10 +564,23 @@ ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES) mkid -fID $$unique tags: TAGS -TAGS: $(HEADERS) $(SOURCES) config.h.in $(TAGS_DEPENDENCIES) \ +TAGS: tags-recursive $(HEADERS) $(SOURCES) config.h.in $(TAGS_DEPENDENCIES) \ $(TAGS_FILES) $(LISP) tags=; \ here=`pwd`; \ + if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \ + include_option=--etags-include; \ + empty_fix=.; \ + else \ + include_option=--include; \ + empty_fix=; \ + fi; \ + list='$(SUBDIRS)'; for subdir in $$list; do \ + if test "$$subdir" = .; then :; else \ + test ! -f $$subdir/TAGS || \ + tags="$$tags $$include_option=$$here/$$subdir/TAGS"; \ + fi; \ + done; \ list='$(SOURCES) $(HEADERS) config.h.in $(LISP) $(TAGS_FILES)'; \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ @@ -549,7 +593,7 @@ TAGS: $(HEADERS) $(SOURCES) config.h.in $(TAGS_DEPENDENCIES) \ $$tags $$unique; \ fi ctags: CTAGS -CTAGS: $(HEADERS) $(SOURCES) config.h.in $(TAGS_DEPENDENCIES) \ +CTAGS: ctags-recursive $(HEADERS) $(SOURCES) config.h.in $(TAGS_DEPENDENCIES) \ $(TAGS_FILES) $(LISP) tags=; \ here=`pwd`; \ @@ -601,6 +645,21 @@ distdir: $(DISTFILES) || exit 1; \ fi; \ done + list='$(DIST_SUBDIRS)'; for subdir in $$list; do \ + if test "$$subdir" = .; then :; else \ + test -d "$(distdir)/$$subdir" \ + || $(mkdir_p) "$(distdir)/$$subdir" \ + || exit 1; \ + distdir=`$(am__cd) $(distdir) && pwd`; \ + top_distdir=`$(am__cd) $(top_distdir) && pwd`; \ + (cd $$subdir && \ + $(MAKE) $(AM_MAKEFLAGS) \ + top_distdir="$$top_distdir" \ + distdir="$$distdir/$$subdir" \ + distdir) \ + || exit 1; \ + fi; \ + done $(MAKE) $(AM_MAKEFLAGS) \ top_distdir="$(top_distdir)" distdir="$(distdir)" \ dist-hook @@ -702,21 +761,22 @@ distcleancheck: distclean $(distcleancheck_listfiles) ; \ exit 1; } >&2 check-am: all-am -check: check-am +check: check-recursive all-am: Makefile $(LTLIBRARIES) $(DATA) $(HEADERS) config.h -installdirs: +installdirs: installdirs-recursive +installdirs-am: for dir in "$(DESTDIR)$(libdir)" "$(DESTDIR)$(lintlibdir)" "$(DESTDIR)$(pkgconfigdir)" "$(DESTDIR)$(xdmcpincludedir)"; do \ test -z "$$dir" || $(mkdir_p) "$$dir"; \ done -install: install-am -install-exec: install-exec-am -install-data: install-data-am -uninstall: uninstall-am +install: install-recursive +install-exec: install-exec-recursive +install-data: install-data-recursive +uninstall: uninstall-recursive install-am: all-am @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am -installcheck: installcheck-am +installcheck: installcheck-recursive install-strip: $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ @@ -734,25 +794,25 @@ maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." -test -z "$(MAINTAINERCLEANFILES)" || rm -f $(MAINTAINERCLEANFILES) -clean: clean-am +clean: clean-recursive clean-am: clean-generic clean-libLTLIBRARIES clean-libtool \ mostlyclean-am -distclean: distclean-am +distclean: distclean-recursive -rm -f $(am__CONFIG_DISTCLEAN_FILES) -rm -rf ./$(DEPDIR) -rm -f Makefile distclean-am: clean-am distclean-compile distclean-generic \ distclean-hdr distclean-libtool distclean-tags -dvi: dvi-am +dvi: dvi-recursive dvi-am: -html: html-am +html: html-recursive -info: info-am +info: info-recursive info-am: @@ -761,29 +821,29 @@ install-data-am: install-lintlibDATA install-pkgconfigDATA \ install-exec-am: install-libLTLIBRARIES -install-info: install-info-am +install-info: install-info-recursive install-man: installcheck-am: -maintainer-clean: maintainer-clean-am +maintainer-clean: maintainer-clean-recursive -rm -f $(am__CONFIG_DISTCLEAN_FILES) -rm -rf $(top_srcdir)/autom4te.cache -rm -rf ./$(DEPDIR) -rm -f Makefile maintainer-clean-am: distclean-am maintainer-clean-generic -mostlyclean: mostlyclean-am +mostlyclean: mostlyclean-recursive mostlyclean-am: mostlyclean-compile mostlyclean-generic \ mostlyclean-libtool -pdf: pdf-am +pdf: pdf-recursive pdf-am: -ps: ps-am +ps: ps-recursive ps-am: @@ -791,21 +851,26 @@ uninstall-am: uninstall-info-am uninstall-libLTLIBRARIES \ uninstall-lintlibDATA uninstall-pkgconfigDATA \ uninstall-xdmcpincludeHEADERS -.PHONY: CTAGS GTAGS all all-am am--refresh check check-am clean \ - clean-generic clean-libLTLIBRARIES clean-libtool ctags dist \ +uninstall-info: uninstall-info-recursive + +.PHONY: $(RECURSIVE_TARGETS) CTAGS GTAGS all all-am am--refresh check \ + check-am clean clean-generic clean-libLTLIBRARIES \ + clean-libtool clean-recursive ctags ctags-recursive dist \ dist-all dist-bzip2 dist-gzip dist-hook dist-shar dist-tarZ \ dist-zip distcheck distclean distclean-compile \ distclean-generic distclean-hdr distclean-libtool \ - distclean-tags distcleancheck distdir distuninstallcheck dvi \ - dvi-am html html-am info info-am install install-am \ - install-data install-data-am install-exec install-exec-am \ - install-info install-info-am install-libLTLIBRARIES \ - install-lintlibDATA install-man install-pkgconfigDATA \ - install-strip install-xdmcpincludeHEADERS installcheck \ - installcheck-am installdirs maintainer-clean \ - maintainer-clean-generic mostlyclean mostlyclean-compile \ - mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ - tags uninstall uninstall-am uninstall-info-am \ + distclean-recursive distclean-tags distcleancheck distdir \ + distuninstallcheck dvi dvi-am html html-am info info-am \ + install install-am install-data install-data-am install-exec \ + install-exec-am install-info install-info-am \ + install-libLTLIBRARIES install-lintlibDATA install-man \ + install-pkgconfigDATA install-strip \ + install-xdmcpincludeHEADERS installcheck installcheck-am \ + installdirs installdirs-am maintainer-clean \ + maintainer-clean-generic maintainer-clean-recursive \ + mostlyclean mostlyclean-compile mostlyclean-generic \ + mostlyclean-libtool mostlyclean-recursive pdf pdf-am ps ps-am \ + tags tags-recursive uninstall uninstall-am uninstall-info-am \ uninstall-libLTLIBRARIES uninstall-lintlibDATA \ uninstall-pkgconfigDATA uninstall-xdmcpincludeHEADERS @@ -816,12 +881,15 @@ uninstall-am: uninstall-info-am uninstall-libLTLIBRARIES \ @MAKE_LINT_LIB_TRUE@$(LINTLIB): $(libXdmcp_la_SOURCES) $(nodist_libXdmcp_la_SOURCES) @MAKE_LINT_LIB_TRUE@ $(LINT) -y -oXdmcp -x $(ALL_LINT_FLAGS) $(libXdmcp_la_SOURCES) $(nodist_libXdmcp_la_SOURCES) -.PHONY: ChangeLog +.PHONY: ChangeLog INSTALL + +INSTALL: + $(INSTALL_CMD) ChangeLog: $(CHANGELOG_CMD) -dist-hook: ChangeLog +dist-hook: ChangeLog INSTALL # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. .NOEXPORT: diff --git a/lib/libXdmcp/RA16.c b/lib/libXdmcp/RA16.c deleted file mode 100644 index c8ccd1a11..000000000 --- a/lib/libXdmcp/RA16.c +++ /dev/null @@ -1,70 +0,0 @@ -/* - * $Xorg: RA16.c,v 1.5 2001/02/09 02:03:48 xorgcvs Exp $ - * - * -Copyright 1989, 1998 The Open Group - -Permission to use, copy, modify, distribute, and sell this software and its -documentation for any purpose is hereby granted without fee, provided that -the above copyright notice appear in all copies and that both that -copyright notice and this permission notice appear in supporting -documentation. - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN -AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN -CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - -Except as contained in this notice, the name of The Open Group shall not be -used in advertising or otherwise to promote the sale, use or other dealings -in this Software without prior written authorization from The Open Group. - * * - * Author: Keith Packard, MIT X Consortium - */ - -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif -#include <X11/Xos.h> -#include <X11/X.h> -#include <X11/Xmd.h> -#include <X11/Xdmcp.h> - -int -XdmcpReadARRAY16 (XdmcpBufferPtr buffer, ARRAY16Ptr array) -{ - int i; - - if (!XdmcpReadCARD8 (buffer, &array->length)) { - - /* Must set array->data to NULL to guarantee safe call of - * XdmcpDisposeARRAY*(array) (which calls Xfree(array->data)); - * see defect 7329 */ - array->data = NULL; - return FALSE; - } - if (!array->length) - { - array->data = NULL; - return TRUE; - } - array->data = (CARD16 *) Xalloc (array->length * sizeof (CARD16)); - if (!array->data) - return FALSE; - for (i = 0; i < (int)array->length; i++) - { - if (!XdmcpReadCARD16 (buffer, &array->data[i])) - { - Xfree (array->data); - array->data = NULL; - array->length = 0; - return FALSE; - } - } - return TRUE; -} diff --git a/lib/libXdmcp/RA32.c b/lib/libXdmcp/RA32.c deleted file mode 100644 index 8f6bfd3dc..000000000 --- a/lib/libXdmcp/RA32.c +++ /dev/null @@ -1,70 +0,0 @@ -/* - * $Xorg: RA32.c,v 1.5 2001/02/09 02:03:48 xorgcvs Exp $ - * - * -Copyright 1989, 1998 The Open Group - -Permission to use, copy, modify, distribute, and sell this software and its -documentation for any purpose is hereby granted without fee, provided that -the above copyright notice appear in all copies and that both that -copyright notice and this permission notice appear in supporting -documentation. - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN -AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN -CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - -Except as contained in this notice, the name of The Open Group shall not be -used in advertising or otherwise to promote the sale, use or other dealings -in this Software without prior written authorization from The Open Group. - * * - * Author: Keith Packard, MIT X Consortium - */ - -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif -#include <X11/Xos.h> -#include <X11/X.h> -#include <X11/Xmd.h> -#include <X11/Xdmcp.h> - -int -XdmcpReadARRAY32 (XdmcpBufferPtr buffer, ARRAY32Ptr array) -{ - int i; - - if (!XdmcpReadCARD8 (buffer, &array->length)) { - - /* Must set array->data to NULL to guarantee safe call of - * XdmcpDisposeARRAY*(array) (which calls Xfree(array->data)); - * see defect 7329 */ - array->data = NULL; - return FALSE; - } - if (!array->length) - { - array->data = NULL; - return TRUE; - } - array->data = (CARD32 *) Xalloc (array->length * sizeof (CARD32)); - if (!array->data) - return FALSE; - for (i = 0; i < (int)array->length; i++) - { - if (!XdmcpReadCARD32 (buffer, &array->data[i])) - { - Xfree (array->data); - array->data = NULL; - array->length = 0; - return FALSE; - } - } - return TRUE; -} diff --git a/lib/libXdmcp/RA8.c b/lib/libXdmcp/RA8.c deleted file mode 100644 index b4478960a..000000000 --- a/lib/libXdmcp/RA8.c +++ /dev/null @@ -1,70 +0,0 @@ -/* - * $Xorg: RA8.c,v 1.5 2001/02/09 02:03:48 xorgcvs Exp $ - * - * -Copyright 1989, 1998 The Open Group - -Permission to use, copy, modify, distribute, and sell this software and its -documentation for any purpose is hereby granted without fee, provided that -the above copyright notice appear in all copies and that both that -copyright notice and this permission notice appear in supporting -documentation. - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN -AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN -CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - -Except as contained in this notice, the name of The Open Group shall not be -used in advertising or otherwise to promote the sale, use or other dealings -in this Software without prior written authorization from The Open Group. - * * - * Author: Keith Packard, MIT X Consortium - */ - -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif -#include <X11/Xos.h> -#include <X11/X.h> -#include <X11/Xmd.h> -#include <X11/Xdmcp.h> - -int -XdmcpReadARRAY8 (XdmcpBufferPtr buffer, ARRAY8Ptr array) -{ - int i; - - if (!XdmcpReadCARD16 (buffer, &array->length)) { - - /* Must set array->data to NULL to guarantee safe call of - * XdmcpDisposeARRAY*(array) (which calls Xfree(array->data)); - * see defect 7329 */ - array->data = NULL; - return FALSE; - } - if (!array->length) - { - array->data = NULL; - return TRUE; - } - array->data = (CARD8 *) Xalloc (array->length * sizeof (CARD8)); - if (!array->data) - return FALSE; - for (i = 0; i < (int)array->length; i++) - { - if (!XdmcpReadCARD8 (buffer, &array->data[i])) - { - Xfree (array->data); - array->data = NULL; - array->length = 0; - return FALSE; - } - } - return TRUE; -} diff --git a/lib/libXdmcp/RAofA8.c b/lib/libXdmcp/RAofA8.c deleted file mode 100644 index 7c8563f9e..000000000 --- a/lib/libXdmcp/RAofA8.c +++ /dev/null @@ -1,73 +0,0 @@ -/* - * $Xorg: RAofA8.c,v 1.6 2001/02/09 02:03:48 xorgcvs Exp $ - * - * -Copyright 1989, 1998 The Open Group - -Permission to use, copy, modify, distribute, and sell this software and its -documentation for any purpose is hereby granted without fee, provided that -the above copyright notice appear in all copies and that both that -copyright notice and this permission notice appear in supporting -documentation. - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN -AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN -CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - -Except as contained in this notice, the name of The Open Group shall not be -used in advertising or otherwise to promote the sale, use or other dealings -in this Software without prior written authorization from The Open Group. - * * - * Author: Keith Packard, MIT X Consortium - */ - -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif -#include <X11/Xos.h> -#include <X11/X.h> -#include <X11/Xmd.h> -#include <X11/Xdmcp.h> - -int -XdmcpReadARRAYofARRAY8 (XdmcpBufferPtr buffer, ARRAYofARRAY8Ptr array) -{ - int i; - - if (!XdmcpReadCARD8 (buffer, &array->length)) { - - /* Must set array->data to NULL to guarantee safe call of - * XdmcpDisposeARRAY*(array) (which calls Xfree(array->data)); - * see defect 7329 */ - array->data = NULL; - return FALSE; - } - if (!array->length) - { - array->data = NULL; - return TRUE; - } - array->data = (ARRAY8 *) Xalloc (array->length * sizeof (ARRAY8)); - if (!array->data) - return FALSE; - for (i = 0; i < (int)array->length; i++) - { - if (!XdmcpReadARRAY8 (buffer, &array->data[i])) - { - - /* All arrays allocated thus far in the loop must be freed - * if there is an error in the read. - * See Defect 7328 */ - array->length = i; - XdmcpDisposeARRAYofARRAY8(array); - return FALSE; - } - } - return TRUE; -} diff --git a/lib/libXdmcp/RC16.c b/lib/libXdmcp/RC16.c deleted file mode 100644 index cd5ec4d88..000000000 --- a/lib/libXdmcp/RC16.c +++ /dev/null @@ -1,50 +0,0 @@ -/* - * $Xorg: RC16.c,v 1.4 2001/02/09 02:03:48 xorgcvs Exp $ - * - * -Copyright 1989, 1998 The Open Group - -Permission to use, copy, modify, distribute, and sell this software and its -documentation for any purpose is hereby granted without fee, provided that -the above copyright notice appear in all copies and that both that -copyright notice and this permission notice appear in supporting -documentation. - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN -AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN -CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - -Except as contained in this notice, the name of The Open Group shall not be -used in advertising or otherwise to promote the sale, use or other dealings -in this Software without prior written authorization from The Open Group. - * * - * Author: Keith Packard, MIT X Consortium - */ - -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif -#include <X11/Xos.h> -#include <X11/X.h> -#include <X11/Xmd.h> -#include <X11/Xdmcp.h> - -int -XdmcpReadCARD16 (XdmcpBufferPtr buffer, CARD16Ptr valuep) -{ - CARD8 high, low; - - if (XdmcpReadCARD8 (buffer, &high) && - XdmcpReadCARD8 (buffer, &low)) - { - *valuep = (((CARD16) high) << 8) | ((CARD16) low); - return TRUE; - } - return FALSE; -} diff --git a/lib/libXdmcp/RC32.c b/lib/libXdmcp/RC32.c deleted file mode 100644 index 99a6d3584..000000000 --- a/lib/libXdmcp/RC32.c +++ /dev/null @@ -1,54 +0,0 @@ -/* - * $Xorg: RC32.c,v 1.4 2001/02/09 02:03:48 xorgcvs Exp $ - * - * -Copyright 1989, 1998 The Open Group - -Permission to use, copy, modify, distribute, and sell this software and its -documentation for any purpose is hereby granted without fee, provided that -the above copyright notice appear in all copies and that both that -copyright notice and this permission notice appear in supporting -documentation. - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN -AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN -CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - -Except as contained in this notice, the name of The Open Group shall not be -used in advertising or otherwise to promote the sale, use or other dealings -in this Software without prior written authorization from The Open Group. - * * - * Author: Keith Packard, MIT X Consortium - */ - -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif -#include <X11/Xos.h> -#include <X11/X.h> -#include <X11/Xmd.h> -#include <X11/Xdmcp.h> - -int -XdmcpReadCARD32 (XdmcpBufferPtr buffer, CARD32Ptr valuep) -{ - CARD8 byte0, byte1, byte2, byte3; - if (XdmcpReadCARD8 (buffer, &byte0) && - XdmcpReadCARD8 (buffer, &byte1) && - XdmcpReadCARD8 (buffer, &byte2) && - XdmcpReadCARD8 (buffer, &byte3)) - { - *valuep = (((CARD32) byte0) << 24) | - (((CARD32) byte1) << 16) | - (((CARD32) byte2) << 8) | - (((CARD32) byte3)); - return TRUE; - } - return FALSE; -} diff --git a/lib/libXdmcp/RC8.c b/lib/libXdmcp/RC8.c deleted file mode 100644 index 4376265ee..000000000 --- a/lib/libXdmcp/RC8.c +++ /dev/null @@ -1,45 +0,0 @@ -/* - * $Xorg: RC8.c,v 1.4 2001/02/09 02:03:48 xorgcvs Exp $ - * - * -Copyright 1989, 1998 The Open Group - -Permission to use, copy, modify, distribute, and sell this software and its -documentation for any purpose is hereby granted without fee, provided that -the above copyright notice appear in all copies and that both that -copyright notice and this permission notice appear in supporting -documentation. - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN -AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN -CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - -Except as contained in this notice, the name of The Open Group shall not be -used in advertising or otherwise to promote the sale, use or other dealings -in this Software without prior written authorization from The Open Group. - * * - * Author: Keith Packard, MIT X Consortium - */ - -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif -#include <X11/Xos.h> -#include <X11/X.h> -#include <X11/Xmd.h> -#include <X11/Xdmcp.h> - -int -XdmcpReadCARD8 (XdmcpBufferPtr buffer, CARD8Ptr valuep) -{ - if (buffer->pointer >= buffer->count) - return FALSE; - *valuep = (CARD8) buffer->data[buffer->pointer++]; - return TRUE; -} diff --git a/lib/libXdmcp/RHead.c b/lib/libXdmcp/RHead.c deleted file mode 100644 index a5640a5ca..000000000 --- a/lib/libXdmcp/RHead.c +++ /dev/null @@ -1,46 +0,0 @@ -/* - * $Xorg: RHead.c,v 1.4 2001/02/09 02:03:48 xorgcvs Exp $ - * - * -Copyright 1989, 1998 The Open Group - -Permission to use, copy, modify, distribute, and sell this software and its -documentation for any purpose is hereby granted without fee, provided that -the above copyright notice appear in all copies and that both that -copyright notice and this permission notice appear in supporting -documentation. - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN -AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN -CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - -Except as contained in this notice, the name of The Open Group shall not be -used in advertising or otherwise to promote the sale, use or other dealings -in this Software without prior written authorization from The Open Group. - * * - * Author: Keith Packard, MIT X Consortium - */ - -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif -#include <X11/Xos.h> -#include <X11/X.h> -#include <X11/Xmd.h> -#include <X11/Xdmcp.h> - -int -XdmcpReadHeader (XdmcpBufferPtr buffer, XdmcpHeaderPtr header) -{ - if (XdmcpReadCARD16 (buffer, &header->version) && - XdmcpReadCARD16 (buffer, &header->opcode) && - XdmcpReadCARD16 (buffer, &header->length)) - return TRUE; - return FALSE; -} diff --git a/lib/libXdmcp/RR.c b/lib/libXdmcp/RR.c deleted file mode 100644 index 3f0c26ad7..000000000 --- a/lib/libXdmcp/RR.c +++ /dev/null @@ -1,42 +0,0 @@ -/* - * $Xorg: RR.c,v 1.4 2001/02/09 02:03:48 xorgcvs Exp $ - * - * -Copyright 1989, 1998 The Open Group - -Permission to use, copy, modify, distribute, and sell this software and its -documentation for any purpose is hereby granted without fee, provided that -the above copyright notice appear in all copies and that both that -copyright notice and this permission notice appear in supporting -documentation. - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN -AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN -CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - -Except as contained in this notice, the name of The Open Group shall not be -used in advertising or otherwise to promote the sale, use or other dealings -in this Software without prior written authorization from The Open Group. - * * - * Author: Keith Packard, MIT X Consortium - */ - -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif -#include <X11/Xos.h> -#include <X11/X.h> -#include <X11/Xmd.h> -#include <X11/Xdmcp.h> - -int -XdmcpReadRemaining (XdmcpBufferPtr buffer) -{ - return buffer->count - buffer->pointer; -} diff --git a/lib/libXdmcp/RaA16.c b/lib/libXdmcp/RaA16.c deleted file mode 100644 index b02fa2f05..000000000 --- a/lib/libXdmcp/RaA16.c +++ /dev/null @@ -1,51 +0,0 @@ -/* - * $Xorg: RaA16.c,v 1.4 2001/02/09 02:03:48 xorgcvs Exp $ - * - * -Copyright 1989, 1998 The Open Group - -Permission to use, copy, modify, distribute, and sell this software and its -documentation for any purpose is hereby granted without fee, provided that -the above copyright notice appear in all copies and that both that -copyright notice and this permission notice appear in supporting -documentation. - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN -AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN -CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - -Except as contained in this notice, the name of The Open Group shall not be -used in advertising or otherwise to promote the sale, use or other dealings -in this Software without prior written authorization from The Open Group. - * * - * Author: Keith Packard, MIT X Consortium - */ - -/* $XFree86: xc/lib/Xdmcp/RaA16.c,v 1.3 2001/01/17 19:42:44 dawes Exp $ */ - -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif -#include <X11/Xos.h> -#include <X11/X.h> -#include <X11/Xmd.h> -#include <X11/Xdmcp.h> - -int -XdmcpReallocARRAY16 (ARRAY16Ptr array, int length) -{ - CARD16Ptr newData; - - newData = (CARD16Ptr) Xrealloc (array->data, length * sizeof (CARD16)); - if (!newData) - return FALSE; - array->length = length; - array->data = newData; - return TRUE; -} diff --git a/lib/libXdmcp/RaA32.c b/lib/libXdmcp/RaA32.c deleted file mode 100644 index 52167d1e4..000000000 --- a/lib/libXdmcp/RaA32.c +++ /dev/null @@ -1,51 +0,0 @@ -/* - * $Xorg: RaA32.c,v 1.4 2001/02/09 02:03:48 xorgcvs Exp $ - * - * -Copyright 1989, 1998 The Open Group - -Permission to use, copy, modify, distribute, and sell this software and its -documentation for any purpose is hereby granted without fee, provided that -the above copyright notice appear in all copies and that both that -copyright notice and this permission notice appear in supporting -documentation. - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN -AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN -CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - -Except as contained in this notice, the name of The Open Group shall not be -used in advertising or otherwise to promote the sale, use or other dealings -in this Software without prior written authorization from The Open Group. - * * - * Author: Keith Packard, MIT X Consortium - */ - -/* $XFree86: xc/lib/Xdmcp/RaA32.c,v 1.3 2001/01/17 19:42:44 dawes Exp $ */ - -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif -#include <X11/Xos.h> -#include <X11/X.h> -#include <X11/Xmd.h> -#include <X11/Xdmcp.h> - -int -XdmcpReallocARRAY32 (ARRAY32Ptr array, int length) -{ - CARD32Ptr newData; - - newData = (CARD32Ptr) Xrealloc (array->data, length * sizeof (CARD32)); - if (!newData) - return FALSE; - array->length = length; - array->data = newData; - return TRUE; -} diff --git a/lib/libXdmcp/RaA8.c b/lib/libXdmcp/RaA8.c deleted file mode 100644 index 3e7bc08e4..000000000 --- a/lib/libXdmcp/RaA8.c +++ /dev/null @@ -1,51 +0,0 @@ -/* - * $Xorg: RaA8.c,v 1.4 2001/02/09 02:03:48 xorgcvs Exp $ - * - * -Copyright 1989, 1998 The Open Group - -Permission to use, copy, modify, distribute, and sell this software and its -documentation for any purpose is hereby granted without fee, provided that -the above copyright notice appear in all copies and that both that -copyright notice and this permission notice appear in supporting -documentation. - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN -AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN -CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - -Except as contained in this notice, the name of The Open Group shall not be -used in advertising or otherwise to promote the sale, use or other dealings -in this Software without prior written authorization from The Open Group. - * * - * Author: Keith Packard, MIT X Consortium - */ - -/* $XFree86: xc/lib/Xdmcp/RaA8.c,v 1.3 2001/01/17 19:42:44 dawes Exp $ */ - -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif -#include <X11/Xos.h> -#include <X11/X.h> -#include <X11/Xmd.h> -#include <X11/Xdmcp.h> - -int -XdmcpReallocARRAY8 (ARRAY8Ptr array, int length) -{ - CARD8Ptr newData; - - newData = (CARD8Ptr) Xrealloc (array->data, length * sizeof (CARD8)); - if (!newData) - return FALSE; - array->length = length; - array->data = newData; - return TRUE; -} diff --git a/lib/libXdmcp/RaAoA8.c b/lib/libXdmcp/RaAoA8.c deleted file mode 100644 index 8b4806c5b..000000000 --- a/lib/libXdmcp/RaAoA8.c +++ /dev/null @@ -1,51 +0,0 @@ -/* - * $Xorg: RaAoA8.c,v 1.4 2001/02/09 02:03:48 xorgcvs Exp $ - * - * -Copyright 1989, 1998 The Open Group - -Permission to use, copy, modify, distribute, and sell this software and its -documentation for any purpose is hereby granted without fee, provided that -the above copyright notice appear in all copies and that both that -copyright notice and this permission notice appear in supporting -documentation. - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN -AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN -CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - -Except as contained in this notice, the name of The Open Group shall not be -used in advertising or otherwise to promote the sale, use or other dealings -in this Software without prior written authorization from The Open Group. - * * - * Author: Keith Packard, MIT X Consortium - */ - -/* $XFree86: xc/lib/Xdmcp/RaAoA8.c,v 1.3 2001/01/17 19:42:44 dawes Exp $ */ - -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif -#include <X11/Xos.h> -#include <X11/X.h> -#include <X11/Xmd.h> -#include <X11/Xdmcp.h> - -int -XdmcpReallocARRAYofARRAY8 (ARRAYofARRAY8Ptr array, int length) -{ - ARRAY8Ptr newData; - - newData = (ARRAY8Ptr) Xrealloc (array->data, length * sizeof (ARRAY8)); - if (!newData) - return FALSE; - array->length = length; - array->data = newData; - return TRUE; -} diff --git a/lib/libXdmcp/Read.c b/lib/libXdmcp/Read.c new file mode 100644 index 000000000..7da6163e4 --- /dev/null +++ b/lib/libXdmcp/Read.c @@ -0,0 +1,244 @@ +/* +Copyright 1989, 1998 The Open Group + +Permission to use, copy, modify, distribute, and sell this software and its +documentation for any purpose is hereby granted without fee, provided that +the above copyright notice appear in all copies and that both that +copyright notice and this permission notice appear in supporting +documentation. + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN +AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +Except as contained in this notice, the name of The Open Group shall not be +used in advertising or otherwise to promote the sale, use or other dealings +in this Software without prior written authorization from The Open Group. + * + * Author: Keith Packard, MIT X Consortium + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif +#include <X11/Xos.h> +#include <X11/X.h> +#include <X11/Xmd.h> +#include <X11/Xdmcp.h> +#include <stdlib.h> + +int +XdmcpReadHeader (XdmcpBufferPtr buffer, XdmcpHeaderPtr header) +{ + if (XdmcpReadCARD16 (buffer, &header->version) && + XdmcpReadCARD16 (buffer, &header->opcode) && + XdmcpReadCARD16 (buffer, &header->length)) + return TRUE; + return FALSE; +} + +int +XdmcpReadRemaining (const XdmcpBufferPtr buffer) +{ + return buffer->count - buffer->pointer; +} + +int +XdmcpReadARRAY8 (XdmcpBufferPtr buffer, ARRAY8Ptr array) +{ + int i; + + /* + * When returning FALSE, guarantee that array->data = 0. + * This allows the user to safely call XdmcpDisposeARRAY8(array) + * regardless of the return value below. + * Note that XdmcpDisposeARRAY*(array) will call free(array->data), + * so we must guarantee that array->data is NULL or a malloced pointer. + */ + if (!XdmcpReadCARD16 (buffer, &array->length)) { + array->data = NULL; + return FALSE; + } + if (!array->length) + { + array->data = NULL; + return TRUE; + } + array->data = (CARD8 *) malloc(array->length * sizeof (CARD8)); + if (!array->data) + return FALSE; + for (i = 0; i < (int)array->length; i++) + { + if (!XdmcpReadCARD8 (buffer, &array->data[i])) + { + free(array->data); + array->data = NULL; + array->length = 0; + return FALSE; + } + } + return TRUE; +} + +int +XdmcpReadARRAY16 (XdmcpBufferPtr buffer, ARRAY16Ptr array) +{ + int i; + + /* + * When returning FALSE, guarantee that array->data = 0. + * This allows the user to safely call XdmcpDisposeARRAY16(array) + * regardless of the return value below. + * Note that XdmcpDisposeARRAY*(array) will call free(array->data), + * so we must guarantee that array->data is NULL or a malloced pointer. + */ + if (!XdmcpReadCARD8 (buffer, &array->length)) { + array->data = NULL; + return FALSE; + } + if (!array->length) + { + array->data = NULL; + return TRUE; + } + array->data = (CARD16 *) malloc(array->length * sizeof (CARD16)); + if (!array->data) + return FALSE; + for (i = 0; i < (int)array->length; i++) + { + if (!XdmcpReadCARD16 (buffer, &array->data[i])) + { + free(array->data); + array->data = NULL; + array->length = 0; + return FALSE; + } + } + return TRUE; +} + +int +XdmcpReadARRAY32 (XdmcpBufferPtr buffer, ARRAY32Ptr array) +{ + int i; + + /* + * When returning FALSE, guarantee that array->data = 0. + * This allows the user to safely call XdmcpDisposeARRAY32(array) + * regardless of the return value below. + * Note that XdmcpDisposeARRAY*(array) will call free(array->data), + * so we must guarantee that array->data is NULL or a malloced pointer. + */ + if (!XdmcpReadCARD8 (buffer, &array->length)) { + array->data = NULL; + return FALSE; + } + if (!array->length) + { + array->data = NULL; + return TRUE; + } + array->data = (CARD32 *) malloc(array->length * sizeof (CARD32)); + if (!array->data) + return FALSE; + for (i = 0; i < (int)array->length; i++) + { + if (!XdmcpReadCARD32 (buffer, &array->data[i])) + { + free(array->data); + array->data = NULL; + array->length = 0; + return FALSE; + } + } + return TRUE; +} + +int +XdmcpReadARRAYofARRAY8 (XdmcpBufferPtr buffer, ARRAYofARRAY8Ptr array) +{ + CARD8 i; + + /* + * When returning FALSE, guarantee that array->data = 0. + * This allows the user to safely call XdmcpDisposeARRAYofARRAY8(array) + * regardless of the return value below. + * Note that XdmcpDisposeARRAY*(array) will call free(array->data), + * so we must guarantee that array->data is NULL or a malloced pointer. + */ + if (!XdmcpReadCARD8 (buffer, &array->length)) { + array->data = NULL; + return FALSE; + } + if (!array->length) + { + array->data = NULL; + return TRUE; + } + array->data = (ARRAY8 *) malloc(array->length * sizeof (ARRAY8)); + if (!array->data) + return FALSE; + for (i = 0; i < array->length; i++) + { + if (!XdmcpReadARRAY8 (buffer, &array->data[i])) + { + /* + * We must free all of the arrays allocated thus far in the loop + * and free array->data and finally set array->data = 0; + * The easiest way to do this is to reset the length and call + * XdmcpDisposeARRAYofARRAY8(array). + */ + array->length = i; + XdmcpDisposeARRAYofARRAY8(array); + return FALSE; + } + } + return TRUE; +} + +int +XdmcpReadCARD8 (XdmcpBufferPtr buffer, CARD8Ptr valuep) +{ + if (buffer->pointer >= buffer->count) + return FALSE; + *valuep = (CARD8) buffer->data[buffer->pointer++]; + return TRUE; +} + +int +XdmcpReadCARD16 (XdmcpBufferPtr buffer, CARD16Ptr valuep) +{ + CARD8 high, low; + + if (XdmcpReadCARD8 (buffer, &high) && + XdmcpReadCARD8 (buffer, &low)) + { + *valuep = (((CARD16) high) << 8) | ((CARD16) low); + return TRUE; + } + return FALSE; +} + +int +XdmcpReadCARD32 (XdmcpBufferPtr buffer, CARD32Ptr valuep) +{ + CARD8 byte0, byte1, byte2, byte3; + if (XdmcpReadCARD8 (buffer, &byte0) && + XdmcpReadCARD8 (buffer, &byte1) && + XdmcpReadCARD8 (buffer, &byte2) && + XdmcpReadCARD8 (buffer, &byte3)) + { + *valuep = (((CARD32) byte0) << 24) | + (((CARD32) byte1) << 16) | + (((CARD32) byte2) << 8) | + (((CARD32) byte3)); + return TRUE; + } + return FALSE; +} diff --git a/lib/libXdmcp/Unwrap.c b/lib/libXdmcp/Unwrap.c index 0d60c2bed..82a10ee03 100644 --- a/lib/libXdmcp/Unwrap.c +++ b/lib/libXdmcp/Unwrap.c @@ -1,7 +1,4 @@ /* - * $Xorg: Unwrap.c,v 1.4 2001/02/09 02:03:48 xorgcvs Exp $ - * - * Copyright 1989, 1998 The Open Group Permission to use, copy, modify, distribute, and sell this software and its @@ -27,8 +24,6 @@ in this Software without prior written authorization from The Open Group. * Author: Keith Packard, MIT X Consortium */ -/* $XFree86: xc/lib/Xdmcp/Unwrap.c,v 1.3 2001/01/17 19:42:44 dawes Exp $ */ - #ifdef HAVE_CONFIG_H #include <config.h> #endif diff --git a/lib/libXdmcp/WA16.c b/lib/libXdmcp/WA16.c deleted file mode 100644 index 8ad307bb4..000000000 --- a/lib/libXdmcp/WA16.c +++ /dev/null @@ -1,49 +0,0 @@ -/* - * $Xorg: WA16.c,v 1.4 2001/02/09 02:03:48 xorgcvs Exp $ - * - * -Copyright 1989, 1998 The Open Group - -Permission to use, copy, modify, distribute, and sell this software and its -documentation for any purpose is hereby granted without fee, provided that -the above copyright notice appear in all copies and that both that -copyright notice and this permission notice appear in supporting -documentation. - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN -AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN -CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - -Except as contained in this notice, the name of The Open Group shall not be -used in advertising or otherwise to promote the sale, use or other dealings -in this Software without prior written authorization from The Open Group. - * * - * Author: Keith Packard, MIT X Consortium - */ - -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif -#include <X11/Xos.h> -#include <X11/X.h> -#include <X11/Xmd.h> -#include <X11/Xdmcp.h> - -int -XdmcpWriteARRAY16 (XdmcpBufferPtr buffer, ARRAY16Ptr array) -{ - int i; - - if (!XdmcpWriteCARD8 (buffer, array->length)) - return FALSE; - for (i = 0; i < (int)array->length; i++) - if (!XdmcpWriteCARD16 (buffer, array->data[i])) - return FALSE; - return TRUE; -} diff --git a/lib/libXdmcp/WA32.c b/lib/libXdmcp/WA32.c deleted file mode 100644 index b58ad25ef..000000000 --- a/lib/libXdmcp/WA32.c +++ /dev/null @@ -1,49 +0,0 @@ -/* - * $Xorg: WA32.c,v 1.4 2001/02/09 02:03:48 xorgcvs Exp $ - * - * -Copyright 1989, 1998 The Open Group - -Permission to use, copy, modify, distribute, and sell this software and its -documentation for any purpose is hereby granted without fee, provided that -the above copyright notice appear in all copies and that both that -copyright notice and this permission notice appear in supporting -documentation. - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN -AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN -CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - -Except as contained in this notice, the name of The Open Group shall not be -used in advertising or otherwise to promote the sale, use or other dealings -in this Software without prior written authorization from The Open Group. - * * - * Author: Keith Packard, MIT X Consortium - */ - -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif -#include <X11/Xos.h> -#include <X11/X.h> -#include <X11/Xmd.h> -#include <X11/Xdmcp.h> - -int -XdmcpWriteARRAY32 (XdmcpBufferPtr buffer, ARRAY32Ptr array) -{ - int i; - - if (!XdmcpWriteCARD8 (buffer, array->length)) - return FALSE; - for (i = 0; i < (int)array->length; i++) - if (!XdmcpWriteCARD32 (buffer, array->data[i])) - return FALSE; - return TRUE; -} diff --git a/lib/libXdmcp/WA8.c b/lib/libXdmcp/WA8.c deleted file mode 100644 index 336d74708..000000000 --- a/lib/libXdmcp/WA8.c +++ /dev/null @@ -1,49 +0,0 @@ -/* - * $Xorg: WA8.c,v 1.4 2001/02/09 02:03:48 xorgcvs Exp $ - * - * -Copyright 1989, 1998 The Open Group - -Permission to use, copy, modify, distribute, and sell this software and its -documentation for any purpose is hereby granted without fee, provided that -the above copyright notice appear in all copies and that both that -copyright notice and this permission notice appear in supporting -documentation. - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN -AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN -CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - -Except as contained in this notice, the name of The Open Group shall not be -used in advertising or otherwise to promote the sale, use or other dealings -in this Software without prior written authorization from The Open Group. - * * - * Author: Keith Packard, MIT X Consortium - */ - -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif -#include <X11/Xos.h> -#include <X11/X.h> -#include <X11/Xmd.h> -#include <X11/Xdmcp.h> - -int -XdmcpWriteARRAY8 (XdmcpBufferPtr buffer, ARRAY8Ptr array) -{ - int i; - - if (!XdmcpWriteCARD16 (buffer, array->length)) - return FALSE; - for (i = 0; i < (int)array->length; i++) - if (!XdmcpWriteCARD8 (buffer, array->data[i])) - return FALSE; - return TRUE; -} diff --git a/lib/libXdmcp/WAofA8.c b/lib/libXdmcp/WAofA8.c deleted file mode 100644 index d50f3a637..000000000 --- a/lib/libXdmcp/WAofA8.c +++ /dev/null @@ -1,49 +0,0 @@ -/* - * $Xorg: WAofA8.c,v 1.4 2001/02/09 02:03:48 xorgcvs Exp $ - * - * -Copyright 1989, 1998 The Open Group - -Permission to use, copy, modify, distribute, and sell this software and its -documentation for any purpose is hereby granted without fee, provided that -the above copyright notice appear in all copies and that both that -copyright notice and this permission notice appear in supporting -documentation. - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN -AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN -CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - -Except as contained in this notice, the name of The Open Group shall not be -used in advertising or otherwise to promote the sale, use or other dealings -in this Software without prior written authorization from The Open Group. - * * - * Author: Keith Packard, MIT X Consortium - */ - -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif -#include <X11/Xos.h> -#include <X11/X.h> -#include <X11/Xmd.h> -#include <X11/Xdmcp.h> - -int -XdmcpWriteARRAYofARRAY8 (XdmcpBufferPtr buffer, ARRAYofARRAY8Ptr array) -{ - int i; - - if (!XdmcpWriteCARD8 (buffer, array->length)) - return FALSE; - for (i = 0; i < (int)array->length; i++) - if (!XdmcpWriteARRAY8 (buffer, &array->data[i])) - return FALSE; - return TRUE; -} diff --git a/lib/libXdmcp/WC16.c b/lib/libXdmcp/WC16.c deleted file mode 100644 index 945171d8c..000000000 --- a/lib/libXdmcp/WC16.c +++ /dev/null @@ -1,50 +0,0 @@ -/* - * $Xorg: WC16.c,v 1.4 2001/02/09 02:03:48 xorgcvs Exp $ - * - * -Copyright 1989, 1998 The Open Group - -Permission to use, copy, modify, distribute, and sell this software and its -documentation for any purpose is hereby granted without fee, provided that -the above copyright notice appear in all copies and that both that -copyright notice and this permission notice appear in supporting -documentation. - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN -AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN -CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - -Except as contained in this notice, the name of The Open Group shall not be -used in advertising or otherwise to promote the sale, use or other dealings -in this Software without prior written authorization from The Open Group. - * * - * Author: Keith Packard, MIT X Consortium - */ - -/* $XFree86: xc/lib/Xdmcp/WC16.c,v 1.4 2001/01/17 19:42:44 dawes Exp $ */ - -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif -#include <X11/Xos.h> -#include <X11/X.h> -#include <X11/Xmd.h> -#include <X11/Xdmcp.h> - -int -XdmcpWriteCARD16 ( - XdmcpBufferPtr buffer, - unsigned value) -{ - if (!XdmcpWriteCARD8 (buffer, value >> 8)) - return FALSE; - if (!XdmcpWriteCARD8 (buffer, value & 0xff)) - return FALSE; - return TRUE; -} diff --git a/lib/libXdmcp/WC32.c b/lib/libXdmcp/WC32.c deleted file mode 100644 index 2d5df8340..000000000 --- a/lib/libXdmcp/WC32.c +++ /dev/null @@ -1,53 +0,0 @@ -/* - * $Xorg: WC32.c,v 1.4 2001/02/09 02:03:49 xorgcvs Exp $ - * - * -Copyright 1989, 1998 The Open Group - -Permission to use, copy, modify, distribute, and sell this software and its -documentation for any purpose is hereby granted without fee, provided that -the above copyright notice appear in all copies and that both that -copyright notice and this permission notice appear in supporting -documentation. - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN -AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN -CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - -Except as contained in this notice, the name of The Open Group shall not be -used in advertising or otherwise to promote the sale, use or other dealings -in this Software without prior written authorization from The Open Group. - * * - * Author: Keith Packard, MIT X Consortium - */ -/* $XFree86: xc/lib/Xdmcp/WC32.c,v 1.4 2001/01/17 19:42:44 dawes Exp $ */ - -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif -#include <X11/Xos.h> -#include <X11/X.h> -#include <X11/Xmd.h> -#include <X11/Xdmcp.h> - -int -XdmcpWriteCARD32 ( - XdmcpBufferPtr buffer, - unsigned value) -{ - if (!XdmcpWriteCARD8 (buffer, value >> 24)) - return FALSE; - if (!XdmcpWriteCARD8 (buffer, (value >> 16) & 0xff)) - return FALSE; - if (!XdmcpWriteCARD8 (buffer, (value >> 8) & 0xff)) - return FALSE; - if (!XdmcpWriteCARD8 (buffer, value & 0xff)) - return FALSE; - return TRUE; -} diff --git a/lib/libXdmcp/WC8.c b/lib/libXdmcp/WC8.c deleted file mode 100644 index 2cbd6f1bf..000000000 --- a/lib/libXdmcp/WC8.c +++ /dev/null @@ -1,49 +0,0 @@ -/* - * $Xorg: WC8.c,v 1.4 2001/02/09 02:03:49 xorgcvs Exp $ - * - * -Copyright 1989, 1998 The Open Group - -Permission to use, copy, modify, distribute, and sell this software and its -documentation for any purpose is hereby granted without fee, provided that -the above copyright notice appear in all copies and that both that -copyright notice and this permission notice appear in supporting -documentation. - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN -AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN -CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - -Except as contained in this notice, the name of The Open Group shall not be -used in advertising or otherwise to promote the sale, use or other dealings -in this Software without prior written authorization from The Open Group. - * * - * Author: Keith Packard, MIT X Consortium - */ - -/* $XFree86: xc/lib/Xdmcp/WC8.c,v 1.4 2001/01/17 19:42:44 dawes Exp $ */ - -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif -#include <X11/Xos.h> -#include <X11/X.h> -#include <X11/Xmd.h> -#include <X11/Xdmcp.h> - -int -XdmcpWriteCARD8 ( - XdmcpBufferPtr buffer, - unsigned value) -{ - if (buffer->pointer >= buffer->size) - return FALSE; - buffer->data[buffer->pointer++] = (BYTE) value; - return TRUE; -} diff --git a/lib/libXdmcp/Whead.c b/lib/libXdmcp/Whead.c deleted file mode 100644 index 82c55c9d2..000000000 --- a/lib/libXdmcp/Whead.c +++ /dev/null @@ -1,64 +0,0 @@ -/* - * $Xorg: Whead.c,v 1.4 2001/02/09 02:03:49 xorgcvs Exp $ - * - * -Copyright 1989, 1998 The Open Group - -Permission to use, copy, modify, distribute, and sell this software and its -documentation for any purpose is hereby granted without fee, provided that -the above copyright notice appear in all copies and that both that -copyright notice and this permission notice appear in supporting -documentation. - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN -AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN -CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - -Except as contained in this notice, the name of The Open Group shall not be -used in advertising or otherwise to promote the sale, use or other dealings -in this Software without prior written authorization from The Open Group. - * * - * Author: Keith Packard, MIT X Consortium - */ - -/* $XFree86: xc/lib/Xdmcp/Whead.c,v 1.3 2001/01/17 19:42:44 dawes Exp $ */ - -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif -#include <X11/Xos.h> -#include <X11/X.h> -#include <X11/Xmd.h> -#include <X11/Xdmcp.h> - -int -XdmcpWriteHeader ( - XdmcpBufferPtr buffer, - XdmcpHeaderPtr header) -{ - BYTE *newData; - - if ((int)buffer->size < 6 + (int)header->length) - { - newData = (BYTE *) Xalloc (XDM_MAX_MSGLEN * sizeof (BYTE)); - if (!newData) - return FALSE; - Xfree ((unsigned long *)(buffer->data)); - buffer->data = newData; - buffer->size = XDM_MAX_MSGLEN; - } - buffer->pointer = 0; - if (!XdmcpWriteCARD16 (buffer, header->version)) - return FALSE; - if (!XdmcpWriteCARD16 (buffer, header->opcode)) - return FALSE; - if (!XdmcpWriteCARD16 (buffer, header->length)) - return FALSE; - return TRUE; -} diff --git a/lib/libXdmcp/Wrap.c b/lib/libXdmcp/Wrap.c index d8a032abc..f025caff0 100644 --- a/lib/libXdmcp/Wrap.c +++ b/lib/libXdmcp/Wrap.c @@ -1,7 +1,4 @@ /* - * $Xorg: Wrap.c,v 1.4 2001/02/09 02:03:49 xorgcvs Exp $ - * - * Copyright 1989, 1998 The Open Group Permission to use, copy, modify, distribute, and sell this software and its @@ -27,8 +24,6 @@ in this Software without prior written authorization from The Open Group. * Author: Keith Packard, MIT X Consortium */ -/* $XFree86: xc/lib/Xdmcp/Wrap.c,v 1.3 2001/01/17 19:42:44 dawes Exp $ */ - #ifdef HAVE_CONFIG_H #include <config.h> #endif diff --git a/lib/libXdmcp/Wrap.h b/lib/libXdmcp/Wrap.h index 9c57e1df7..479da5f32 100644 --- a/lib/libXdmcp/Wrap.h +++ b/lib/libXdmcp/Wrap.h @@ -1,11 +1,7 @@ -/* $XdotOrg: xc/lib/Xdmcp/Wrap.h,v 1.5 2004/08/22 01:02:25 jg Exp $ */ -/* $Xorg: Wrap.h,v 1.3 2000/08/17 19:45:50 cpqbld Exp $ */ /* * header file for compatibility with something useful */ -/* $XFree86: xc/lib/Xdmcp/Wrap.h,v 1.3 2001/01/17 19:42:44 dawes Exp $ */ - typedef unsigned char auth_cblock[8]; /* block size */ typedef struct auth_ks_struct { auth_cblock _; } auth_wrapper_schedule[16]; diff --git a/lib/libXdmcp/Wraphelp.c b/lib/libXdmcp/Wraphelp.c index 07ccf3ea7..1b962e384 100644 --- a/lib/libXdmcp/Wraphelp.c +++ b/lib/libXdmcp/Wraphelp.c @@ -1,8 +1,3 @@ -/* - * $Xorg: A8Eq.c,v 1.4 2001/02/09 02:03:48 xorgcvs Exp $ - * - */ - #ifdef HAVE_CONFIG_H #include <config.h> #endif diff --git a/lib/libXdmcp/Write.c b/lib/libXdmcp/Write.c new file mode 100644 index 000000000..8eb9c5043 --- /dev/null +++ b/lib/libXdmcp/Write.c @@ -0,0 +1,151 @@ +/* +Copyright 1989, 1998 The Open Group + +Permission to use, copy, modify, distribute, and sell this software and its +documentation for any purpose is hereby granted without fee, provided that +the above copyright notice appear in all copies and that both that +copyright notice and this permission notice appear in supporting +documentation. + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN +AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +Except as contained in this notice, the name of The Open Group shall not be +used in advertising or otherwise to promote the sale, use or other dealings +in this Software without prior written authorization from The Open Group. + * + * Author: Keith Packard, MIT X Consortium + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif +#include <X11/Xos.h> +#include <X11/X.h> +#include <X11/Xmd.h> +#include <X11/Xdmcp.h> +#include <stdlib.h> + +int +XdmcpWriteHeader ( + XdmcpBufferPtr buffer, + const XdmcpHeaderPtr header) +{ + BYTE *newData; + + if ((int)buffer->size < 6 + (int)header->length) + { + newData = (BYTE *) malloc(XDM_MAX_MSGLEN * sizeof (BYTE)); + if (!newData) + return FALSE; + free((unsigned long *)(buffer->data)); + buffer->data = newData; + buffer->size = XDM_MAX_MSGLEN; + } + buffer->pointer = 0; + if (!XdmcpWriteCARD16 (buffer, header->version)) + return FALSE; + if (!XdmcpWriteCARD16 (buffer, header->opcode)) + return FALSE; + if (!XdmcpWriteCARD16 (buffer, header->length)) + return FALSE; + return TRUE; +} + +int +XdmcpWriteARRAY8 (XdmcpBufferPtr buffer, const ARRAY8Ptr array) +{ + int i; + + if (!XdmcpWriteCARD16 (buffer, array->length)) + return FALSE; + for (i = 0; i < (int)array->length; i++) + if (!XdmcpWriteCARD8 (buffer, array->data[i])) + return FALSE; + return TRUE; +} + +int +XdmcpWriteARRAY16 (XdmcpBufferPtr buffer, const ARRAY16Ptr array) +{ + int i; + + if (!XdmcpWriteCARD8 (buffer, array->length)) + return FALSE; + for (i = 0; i < (int)array->length; i++) + if (!XdmcpWriteCARD16 (buffer, array->data[i])) + return FALSE; + return TRUE; +} + +int +XdmcpWriteARRAY32 (XdmcpBufferPtr buffer, const ARRAY32Ptr array) +{ + int i; + + if (!XdmcpWriteCARD8 (buffer, array->length)) + return FALSE; + for (i = 0; i < (int)array->length; i++) + if (!XdmcpWriteCARD32 (buffer, array->data[i])) + return FALSE; + return TRUE; +} + +int +XdmcpWriteARRAYofARRAY8 (XdmcpBufferPtr buffer, ARRAYofARRAY8Ptr array) +{ + int i; + + if (!XdmcpWriteCARD8 (buffer, array->length)) + return FALSE; + for (i = 0; i < (int)array->length; i++) + if (!XdmcpWriteARRAY8 (buffer, &array->data[i])) + return FALSE; + return TRUE; +} + +int +XdmcpWriteCARD8 ( + XdmcpBufferPtr buffer, + unsigned value) +{ + if (buffer->pointer >= buffer->size) + return FALSE; + buffer->data[buffer->pointer++] = (BYTE) value; + return TRUE; +} + +int +XdmcpWriteCARD16 ( + XdmcpBufferPtr buffer, + unsigned value) +{ + if (!XdmcpWriteCARD8 (buffer, value >> 8)) + return FALSE; + if (!XdmcpWriteCARD8 (buffer, value & 0xff)) + return FALSE; + return TRUE; +} + +int +XdmcpWriteCARD32 ( + XdmcpBufferPtr buffer, + unsigned value) +{ + if (!XdmcpWriteCARD8 (buffer, value >> 24)) + return FALSE; + if (!XdmcpWriteCARD8 (buffer, (value >> 16) & 0xff)) + return FALSE; + if (!XdmcpWriteCARD8 (buffer, (value >> 8) & 0xff)) + return FALSE; + if (!XdmcpWriteCARD8 (buffer, value & 0xff)) + return FALSE; + return TRUE; +} diff --git a/lib/libXdmcp/aclocal.m4 b/lib/libXdmcp/aclocal.m4 index 5d53347b9..b2777e06d 100644 --- a/lib/libXdmcp/aclocal.m4 +++ b/lib/libXdmcp/aclocal.m4 @@ -7633,32 +7633,26 @@ AC_SUBST([am__untar]) dnl xorg-macros.m4. Generated from xorg-macros.m4.in xorgversion.m4 by configure. dnl -dnl Copyright 2005-2006 Sun Microsystems, Inc. All rights reserved. +dnl Copyright (c) 2005, 2006, Oracle and/or its affiliates. All rights reserved. dnl dnl Permission is hereby granted, free of charge, to any person obtaining a -dnl copy of this software and associated documentation files (the -dnl "Software"), to deal in the Software without restriction, including -dnl without limitation the rights to use, copy, modify, merge, publish, -dnl distribute, and/or sell copies of the Software, and to permit persons -dnl to whom the Software is furnished to do so, provided that the above -dnl copyright notice(s) and this permission notice appear in all copies of -dnl the Software and that both the above copyright notice(s) and this -dnl permission notice appear in supporting documentation. +dnl copy of this software and associated documentation files (the "Software"), +dnl to deal in the Software without restriction, including without limitation +dnl the rights to use, copy, modify, merge, publish, distribute, sublicense, +dnl and/or sell copies of the Software, and to permit persons to whom the +dnl Software is furnished to do so, subject to the following conditions: dnl -dnl THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -dnl OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -dnl MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT -dnl OF THIRD PARTY RIGHTS. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR -dnl HOLDERS INCLUDED IN THIS NOTICE BE LIABLE FOR ANY CLAIM, OR ANY SPECIAL -dnl INDIRECT OR CONSEQUENTIAL DAMAGES, OR ANY DAMAGES WHATSOEVER RESULTING -dnl FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, -dnl NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION -dnl WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +dnl The above copyright notice and this permission notice (including the next +dnl paragraph) shall be included in all copies or substantial portions of the +dnl Software. dnl -dnl Except as contained in this notice, the name of a copyright holder -dnl shall not be used in advertising or otherwise to promote the sale, use -dnl or other dealings in this Software without prior written authorization -dnl of the copyright holder. +dnl THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +dnl IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +dnl FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL +dnl THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +dnl LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING +dnl FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER +dnl DEALINGS IN THE SOFTWARE. # XORG_MACROS_VERSION(required-version) # ------------------------------------- @@ -7676,7 +7670,7 @@ dnl of the copyright holder. # See the "minimum version" comment for each macro you use to see what # version you require. m4_defun([XORG_MACROS_VERSION],[ -m4_define([vers_have], [1.3.0]) +m4_define([vers_have], [1.11.0]) m4_define([maj_have], m4_substr(vers_have, 0, m4_index(vers_have, [.]))) m4_define([maj_needed], m4_substr([$1], 0, m4_index([$1], [.]))) m4_if(m4_cmp(maj_have, maj_needed), 0,, @@ -7744,9 +7738,12 @@ AC_SUBST(RAWCPPFLAGS) # on this OS - replaces *ManSuffix settings in old Imake *.cf per-os files. # Not sure if there's any better way than just hardcoding by OS name. # Override default settings by setting environment variables +# Added MAN_SUBSTS in version 1.8 +# Added AC_PROG_SED in version 1.8 AC_DEFUN([XORG_MANPAGE_SECTIONS],[ AC_REQUIRE([AC_CANONICAL_HOST]) +AC_REQUIRE([AC_PROG_SED]) if test x$APP_MAN_SUFFIX = x ; then APP_MAN_SUFFIX=1 @@ -7815,8 +7812,60 @@ AC_SUBST([FILE_MAN_DIR]) AC_SUBST([MISC_MAN_DIR]) AC_SUBST([DRIVER_MAN_DIR]) AC_SUBST([ADMIN_MAN_DIR]) + +XORG_MAN_PAGE="X Version 11" +AC_SUBST([XORG_MAN_PAGE]) +MAN_SUBSTS="\ + -e 's|__vendorversion__|\"\$(PACKAGE_STRING)\" \"\$(XORG_MAN_PAGE)\"|' \ + -e 's|__xorgversion__|\"\$(PACKAGE_STRING)\" \"\$(XORG_MAN_PAGE)\"|' \ + -e 's|__xservername__|Xorg|g' \ + -e 's|__xconfigfile__|xorg.conf|g' \ + -e 's|__projectroot__|\$(prefix)|g' \ + -e 's|__apploaddir__|\$(appdefaultdir)|g' \ + -e 's|__appmansuffix__|\$(APP_MAN_SUFFIX)|g' \ + -e 's|__drivermansuffix__|\$(DRIVER_MAN_SUFFIX)|g' \ + -e 's|__adminmansuffix__|\$(ADMIN_MAN_SUFFIX)|g' \ + -e 's|__libmansuffix__|\$(LIB_MAN_SUFFIX)|g' \ + -e 's|__miscmansuffix__|\$(MISC_MAN_SUFFIX)|g' \ + -e 's|__filemansuffix__|\$(FILE_MAN_SUFFIX)|g'" +AC_SUBST([MAN_SUBSTS]) + ]) # XORG_MANPAGE_SECTIONS +# XORG_CHECK_SGML_DOCTOOLS([MIN-VERSION]) +# ------------------------ +# Minimum version: 1.7.0 +# +# Defines the variable XORG_SGML_PATH containing the location of X11/defs.ent +# provided by xorg-sgml-doctools, if installed. +AC_DEFUN([XORG_CHECK_SGML_DOCTOOLS],[ +AC_MSG_CHECKING([for X.Org SGML entities m4_ifval([$1],[>= $1])]) +XORG_SGML_PATH= +PKG_CHECK_EXISTS([xorg-sgml-doctools m4_ifval([$1],[>= $1])], + [XORG_SGML_PATH=`$PKG_CONFIG --variable=sgmlrootdir xorg-sgml-doctools`], + [m4_ifval([$1],[:], + [if test x"$cross_compiling" != x"yes" ; then + AC_CHECK_FILE([$prefix/share/sgml/X11/defs.ent], + [XORG_SGML_PATH=$prefix/share/sgml]) + fi]) + ]) + +# Define variables STYLESHEET_SRCDIR and XSL_STYLESHEET containing +# the path and the name of the doc stylesheet +if test "x$XORG_SGML_PATH" != "x" ; then + AC_MSG_RESULT([$XORG_SGML_PATH]) + STYLESHEET_SRCDIR=$XORG_SGML_PATH/X11 + XSL_STYLESHEET=$STYLESHEET_SRCDIR/xorg.xsl +else + AC_MSG_RESULT([no]) +fi + +AC_SUBST(XORG_SGML_PATH) +AC_SUBST(STYLESHEET_SRCDIR) +AC_SUBST(XSL_STYLESHEET) +AM_CONDITIONAL([HAVE_STYLESHEETS], [test "x$XSL_STYLESHEET" != "x"]) +]) # XORG_CHECK_SGML_DOCTOOLS + # XORG_CHECK_LINUXDOC # ------------------- # Minimum version: 1.0.0 @@ -7826,23 +7875,14 @@ AC_SUBST([ADMIN_MAN_DIR]) # Whether or not the necessary tools and files are found can be checked # with the AM_CONDITIONAL "BUILD_LINUXDOC" AC_DEFUN([XORG_CHECK_LINUXDOC],[ -if test x$XORG_SGML_PATH = x ; then - XORG_SGML_PATH=$prefix/share/sgml -fi -HAVE_DEFS_ENT= - -if test x"$cross_compiling" = x"yes" ; then - HAVE_DEFS_ENT=no -else - AC_CHECK_FILE([$XORG_SGML_PATH/X11/defs.ent], [HAVE_DEFS_ENT=yes]) -fi +AC_REQUIRE([XORG_CHECK_SGML_DOCTOOLS]) +AC_REQUIRE([XORG_WITH_PS2PDF]) AC_PATH_PROG(LINUXDOC, linuxdoc) -AC_PATH_PROG(PS2PDF, ps2pdf) -AC_MSG_CHECKING([Whether to build documentation]) +AC_MSG_CHECKING([whether to build documentation]) -if test x$HAVE_DEFS_ENT != x && test x$LINUXDOC != x ; then +if test x$XORG_SGML_PATH != x && test x$LINUXDOC != x ; then BUILDDOC=yes else BUILDDOC=no @@ -7852,9 +7892,9 @@ AM_CONDITIONAL(BUILD_LINUXDOC, [test x$BUILDDOC = xyes]) AC_MSG_RESULT([$BUILDDOC]) -AC_MSG_CHECKING([Whether to build pdf documentation]) +AC_MSG_CHECKING([whether to build pdf documentation]) -if test x$PS2PDF != x && test x$BUILD_PDFDOC != xno; then +if test x$have_ps2pdf != xno && test x$BUILD_PDFDOC != xno; then BUILDPDFDOC=yes else BUILDPDFDOC=no @@ -7864,7 +7904,7 @@ AM_CONDITIONAL(BUILD_PDFDOC, [test x$BUILDPDFDOC = xyes]) AC_MSG_RESULT([$BUILDPDFDOC]) -MAKE_TEXT="SGML_SEARCH_PATH=$XORG_SGML_PATH GROFF_NO_SGR=y $LINUXDOC -B txt" +MAKE_TEXT="SGML_SEARCH_PATH=$XORG_SGML_PATH GROFF_NO_SGR=y $LINUXDOC -B txt -f" MAKE_PS="SGML_SEARCH_PATH=$XORG_SGML_PATH $LINUXDOC -B latex --papersize=letter --output=ps" MAKE_PDF="$PS2PDF" MAKE_HTML="SGML_SEARCH_PATH=$XORG_SGML_PATH $LINUXDOC -B html --split=0" @@ -7884,48 +7924,44 @@ AC_SUBST(MAKE_HTML) # indicates whether the necessary tools and files are found and, if set, # $(MAKE_XXX) blah.sgml will produce blah.xxx. AC_DEFUN([XORG_CHECK_DOCBOOK],[ -if test x$XORG_SGML_PATH = x ; then - XORG_SGML_PATH=$prefix/share/sgml -fi -HAVE_DEFS_ENT= +AC_REQUIRE([XORG_CHECK_SGML_DOCTOOLS]) + BUILDTXTDOC=no BUILDPDFDOC=no BUILDPSDOC=no BUILDHTMLDOC=no -AC_CHECK_FILE([$XORG_SGML_PATH/X11/defs.ent], [HAVE_DEFS_ENT=yes]) - AC_PATH_PROG(DOCBOOKPS, docbook2ps) AC_PATH_PROG(DOCBOOKPDF, docbook2pdf) AC_PATH_PROG(DOCBOOKHTML, docbook2html) AC_PATH_PROG(DOCBOOKTXT, docbook2txt) -AC_MSG_CHECKING([Whether to build text documentation]) -if test x$HAVE_DEFS_ENT != x && test x$DOCBOOKTXT != x && +AC_MSG_CHECKING([whether to build text documentation]) +if test x$XORG_SGML_PATH != x && test x$DOCBOOKTXT != x && test x$BUILD_TXTDOC != xno; then BUILDTXTDOC=yes fi AM_CONDITIONAL(BUILD_TXTDOC, [test x$BUILDTXTDOC = xyes]) AC_MSG_RESULT([$BUILDTXTDOC]) -AC_MSG_CHECKING([Whether to build PDF documentation]) -if test x$HAVE_DEFS_ENT != x && test x$DOCBOOKPDF != x && +AC_MSG_CHECKING([whether to build PDF documentation]) +if test x$XORG_SGML_PATH != x && test x$DOCBOOKPDF != x && test x$BUILD_PDFDOC != xno; then BUILDPDFDOC=yes fi AM_CONDITIONAL(BUILD_PDFDOC, [test x$BUILDPDFDOC = xyes]) AC_MSG_RESULT([$BUILDPDFDOC]) -AC_MSG_CHECKING([Whether to build PostScript documentation]) -if test x$HAVE_DEFS_ENT != x && test x$DOCBOOKPS != x && +AC_MSG_CHECKING([whether to build PostScript documentation]) +if test x$XORG_SGML_PATH != x && test x$DOCBOOKPS != x && test x$BUILD_PSDOC != xno; then BUILDPSDOC=yes fi AM_CONDITIONAL(BUILD_PSDOC, [test x$BUILDPSDOC = xyes]) AC_MSG_RESULT([$BUILDPSDOC]) -AC_MSG_CHECKING([Whether to build HTML documentation]) -if test x$HAVE_DEFS_ENT != x && test x$DOCBOOKHTML != x && +AC_MSG_CHECKING([whether to build HTML documentation]) +if test x$XORG_SGML_PATH != x && test x$DOCBOOKHTML != x && test x$BUILD_HTMLDOC != xno; then BUILDHTMLDOC=yes fi @@ -7943,6 +7979,548 @@ AC_SUBST(MAKE_PDF) AC_SUBST(MAKE_HTML) ]) # XORG_CHECK_DOCBOOK +# XORG_WITH_XMLTO([MIN-VERSION], [DEFAULT]) +# ---------------- +# Minimum version: 1.5.0 +# Minimum version for optional DEFAULT argument: 1.11.0 +# +# Documentation tools are not always available on all platforms and sometimes +# not at the appropriate level. This macro enables a module to test for the +# presence of the tool and obtain it's path in separate variables. Coupled with +# the --with-xmlto option, it allows maximum flexibilty in making decisions +# as whether or not to use the xmlto package. When DEFAULT is not specified, +# --with-xmlto assumes 'auto'. +# +# Interface to module: +# HAVE_XMLTO: used in makefiles to conditionally generate documentation +# XMLTO: returns the path of the xmlto program found +# returns the path set by the user in the environment +# --with-xmlto: 'yes' user instructs the module to use xmlto +# 'no' user instructs the module not to use xmlto +# +# Added in version 1.10.0 +# HAVE_XMLTO_TEXT: used in makefiles to conditionally generate text documentation +# xmlto for text output requires either lynx, links, or w3m browsers +# +# If the user sets the value of XMLTO, AC_PATH_PROG skips testing the path. +# +AC_DEFUN([XORG_WITH_XMLTO],[ +AC_ARG_VAR([XMLTO], [Path to xmlto command]) +m4_define([_defopt], m4_default([$2], [auto])) +AC_ARG_WITH(xmlto, + AS_HELP_STRING([--with-xmlto], + [Use xmlto to regenerate documentation (default: ]_defopt[)]), + [use_xmlto=$withval], [use_xmlto=]_defopt) +m4_undefine([_defopt]) + +if test "x$use_xmlto" = x"auto"; then + AC_PATH_PROG([XMLTO], [xmlto]) + if test "x$XMLTO" = "x"; then + AC_MSG_WARN([xmlto not found - documentation targets will be skipped]) + have_xmlto=no + else + have_xmlto=yes + fi +elif test "x$use_xmlto" = x"yes" ; then + AC_PATH_PROG([XMLTO], [xmlto]) + if test "x$XMLTO" = "x"; then + AC_MSG_ERROR([--with-xmlto=yes specified but xmlto not found in PATH]) + fi + have_xmlto=yes +elif test "x$use_xmlto" = x"no" ; then + if test "x$XMLTO" != "x"; then + AC_MSG_WARN([ignoring XMLTO environment variable since --with-xmlto=no was specified]) + fi + have_xmlto=no +else + AC_MSG_ERROR([--with-xmlto expects 'yes' or 'no']) +fi + +# Test for a minimum version of xmlto, if provided. +m4_ifval([$1], +[if test "$have_xmlto" = yes; then + # scrape the xmlto version + AC_MSG_CHECKING([the xmlto version]) + xmlto_version=`$XMLTO --version 2>/dev/null | cut -d' ' -f3` + AC_MSG_RESULT([$xmlto_version]) + AS_VERSION_COMPARE([$xmlto_version], [$1], + [if test "x$use_xmlto" = xauto; then + AC_MSG_WARN([xmlto version $xmlto_version found, but $1 needed]) + have_xmlto=no + else + AC_MSG_ERROR([xmlto version $xmlto_version found, but $1 needed]) + fi]) +fi]) + +# Test for the ability of xmlto to generate a text target +have_xmlto_text=no +cat > conftest.xml << "EOF" +EOF +AS_IF([test "$have_xmlto" = yes], + [AS_IF([$XMLTO --skip-validation txt conftest.xml >/dev/null 2>&1], + [have_xmlto_text=yes], + [AC_MSG_WARN([xmlto cannot generate text format, this format skipped])])]) +rm -f conftest.xml +AM_CONDITIONAL([HAVE_XMLTO_TEXT], [test $have_xmlto_text = yes]) +AM_CONDITIONAL([HAVE_XMLTO], [test "$have_xmlto" = yes]) +]) # XORG_WITH_XMLTO + +# XORG_WITH_ASCIIDOC([MIN-VERSION], [DEFAULT]) +# ---------------- +# Minimum version: 1.5.0 +# Minimum version for optional DEFAULT argument: 1.11.0 +# +# Documentation tools are not always available on all platforms and sometimes +# not at the appropriate level. This macro enables a module to test for the +# presence of the tool and obtain it's path in separate variables. Coupled with +# the --with-asciidoc option, it allows maximum flexibilty in making decisions +# as whether or not to use the asciidoc package. When DEFAULT is not specified, +# --with-asciidoc assumes 'auto'. +# +# Interface to module: +# HAVE_ASCIIDOC: used in makefiles to conditionally generate documentation +# ASCIIDOC: returns the path of the asciidoc program found +# returns the path set by the user in the environment +# --with-asciidoc: 'yes' user instructs the module to use asciidoc +# 'no' user instructs the module not to use asciidoc +# +# If the user sets the value of ASCIIDOC, AC_PATH_PROG skips testing the path. +# +AC_DEFUN([XORG_WITH_ASCIIDOC],[ +AC_ARG_VAR([ASCIIDOC], [Path to asciidoc command]) +m4_define([_defopt], m4_default([$2], [auto])) +AC_ARG_WITH(asciidoc, + AS_HELP_STRING([--with-asciidoc], + [Use asciidoc to regenerate documentation (default: ]_defopt[)]), + [use_asciidoc=$withval], [use_asciidoc=]_defopt) +m4_undefine([_defopt]) + +if test "x$use_asciidoc" = x"auto"; then + AC_PATH_PROG([ASCIIDOC], [asciidoc]) + if test "x$ASCIIDOC" = "x"; then + AC_MSG_WARN([asciidoc not found - documentation targets will be skipped]) + have_asciidoc=no + else + have_asciidoc=yes + fi +elif test "x$use_asciidoc" = x"yes" ; then + AC_PATH_PROG([ASCIIDOC], [asciidoc]) + if test "x$ASCIIDOC" = "x"; then + AC_MSG_ERROR([--with-asciidoc=yes specified but asciidoc not found in PATH]) + fi + have_asciidoc=yes +elif test "x$use_asciidoc" = x"no" ; then + if test "x$ASCIIDOC" != "x"; then + AC_MSG_WARN([ignoring ASCIIDOC environment variable since --with-asciidoc=no was specified]) + fi + have_asciidoc=no +else + AC_MSG_ERROR([--with-asciidoc expects 'yes' or 'no']) +fi +m4_ifval([$1], +[if test "$have_asciidoc" = yes; then + # scrape the asciidoc version + AC_MSG_CHECKING([the asciidoc version]) + asciidoc_version=`$ASCIIDOC --version 2>/dev/null | cut -d' ' -f2` + AC_MSG_RESULT([$asciidoc_version]) + AS_VERSION_COMPARE([$asciidoc_version], [$1], + [if test "x$use_asciidoc" = xauto; then + AC_MSG_WARN([asciidoc version $asciidoc_version found, but $1 needed]) + have_asciidoc=no + else + AC_MSG_ERROR([asciidoc version $asciidoc_version found, but $1 needed]) + fi]) +fi]) +AM_CONDITIONAL([HAVE_ASCIIDOC], [test "$have_asciidoc" = yes]) +]) # XORG_WITH_ASCIIDOC + +# XORG_WITH_DOXYGEN([MIN-VERSION], [DEFAULT]) +# -------------------------------- +# Minimum version: 1.5.0 +# Minimum version for optional DEFAULT argument: 1.11.0 +# +# Documentation tools are not always available on all platforms and sometimes +# not at the appropriate level. This macro enables a module to test for the +# presence of the tool and obtain it's path in separate variables. Coupled with +# the --with-doxygen option, it allows maximum flexibilty in making decisions +# as whether or not to use the doxygen package. When DEFAULT is not specified, +# --with-doxygen assumes 'auto'. +# +# Interface to module: +# HAVE_DOXYGEN: used in makefiles to conditionally generate documentation +# DOXYGEN: returns the path of the doxygen program found +# returns the path set by the user in the environment +# --with-doxygen: 'yes' user instructs the module to use doxygen +# 'no' user instructs the module not to use doxygen +# +# If the user sets the value of DOXYGEN, AC_PATH_PROG skips testing the path. +# +AC_DEFUN([XORG_WITH_DOXYGEN],[ +AC_ARG_VAR([DOXYGEN], [Path to doxygen command]) +m4_define([_defopt], m4_default([$2], [auto])) +AC_ARG_WITH(doxygen, + AS_HELP_STRING([--with-doxygen], + [Use doxygen to regenerate documentation (default: ]_defopt[)]), + [use_doxygen=$withval], [use_doxygen=]_defopt) +m4_undefine([_defopt]) + +if test "x$use_doxygen" = x"auto"; then + AC_PATH_PROG([DOXYGEN], [doxygen]) + if test "x$DOXYGEN" = "x"; then + AC_MSG_WARN([doxygen not found - documentation targets will be skipped]) + have_doxygen=no + else + have_doxygen=yes + fi +elif test "x$use_doxygen" = x"yes" ; then + AC_PATH_PROG([DOXYGEN], [doxygen]) + if test "x$DOXYGEN" = "x"; then + AC_MSG_ERROR([--with-doxygen=yes specified but doxygen not found in PATH]) + fi + have_doxygen=yes +elif test "x$use_doxygen" = x"no" ; then + if test "x$DOXYGEN" != "x"; then + AC_MSG_WARN([ignoring DOXYGEN environment variable since --with-doxygen=no was specified]) + fi + have_doxygen=no +else + AC_MSG_ERROR([--with-doxygen expects 'yes' or 'no']) +fi +m4_ifval([$1], +[if test "$have_doxygen" = yes; then + # scrape the doxygen version + AC_MSG_CHECKING([the doxygen version]) + doxygen_version=`$DOXYGEN --version 2>/dev/null` + AC_MSG_RESULT([$doxygen_version]) + AS_VERSION_COMPARE([$doxygen_version], [$1], + [if test "x$use_doxygen" = xauto; then + AC_MSG_WARN([doxygen version $doxygen_version found, but $1 needed]) + have_doxygen=no + else + AC_MSG_ERROR([doxygen version $doxygen_version found, but $1 needed]) + fi]) +fi]) +AM_CONDITIONAL([HAVE_DOXYGEN], [test "$have_doxygen" = yes]) +]) # XORG_WITH_DOXYGEN + +# XORG_WITH_GROFF([DEFAULT]) +# ---------------- +# Minimum version: 1.6.0 +# Minimum version for optional DEFAULT argument: 1.11.0 +# +# Documentation tools are not always available on all platforms and sometimes +# not at the appropriate level. This macro enables a module to test for the +# presence of the tool and obtain it's path in separate variables. Coupled with +# the --with-groff option, it allows maximum flexibilty in making decisions +# as whether or not to use the groff package. When DEFAULT is not specified, +# --with-groff assumes 'auto'. +# +# Interface to module: +# HAVE_GROFF: used in makefiles to conditionally generate documentation +# HAVE_GROFF_MM: the memorandum macros (-mm) package +# HAVE_GROFF_MS: the -ms macros package +# GROFF: returns the path of the groff program found +# returns the path set by the user in the environment +# --with-groff: 'yes' user instructs the module to use groff +# 'no' user instructs the module not to use groff +# +# Added in version 1.9.0: +# HAVE_GROFF_HTML: groff has dependencies to output HTML format: +# pnmcut pnmcrop pnmtopng pnmtops from the netpbm package. +# psselect from the psutils package. +# the ghostcript package. Refer to the grohtml man pages +# +# If the user sets the value of GROFF, AC_PATH_PROG skips testing the path. +# +# OS and distros often splits groff in a basic and full package, the former +# having the groff program and the later having devices, fonts and macros +# Checking for the groff executable is not enough. +# +# If macros are missing, we cannot assume that groff is useless, so we don't +# unset HAVE_GROFF or GROFF env variables. +# HAVE_GROFF_?? can never be true while HAVE_GROFF is false. +# +AC_DEFUN([XORG_WITH_GROFF],[ +AC_ARG_VAR([GROFF], [Path to groff command]) +m4_define([_defopt], m4_default([$1], [auto])) +AC_ARG_WITH(groff, + AS_HELP_STRING([--with-groff], + [Use groff to regenerate documentation (default: ]_defopt[)]), + [use_groff=$withval], [use_groff=]_defopt) +m4_undefine([_defopt]) + +if test "x$use_groff" = x"auto"; then + AC_PATH_PROG([GROFF], [groff]) + if test "x$GROFF" = "x"; then + AC_MSG_WARN([groff not found - documentation targets will be skipped]) + have_groff=no + else + have_groff=yes + fi +elif test "x$use_groff" = x"yes" ; then + AC_PATH_PROG([GROFF], [groff]) + if test "x$GROFF" = "x"; then + AC_MSG_ERROR([--with-groff=yes specified but groff not found in PATH]) + fi + have_groff=yes +elif test "x$use_groff" = x"no" ; then + if test "x$GROFF" != "x"; then + AC_MSG_WARN([ignoring GROFF environment variable since --with-groff=no was specified]) + fi + have_groff=no +else + AC_MSG_ERROR([--with-groff expects 'yes' or 'no']) +fi + +# We have groff, test for the presence of the macro packages +if test "x$have_groff" = x"yes"; then + AC_MSG_CHECKING([for ${GROFF} -ms macros]) + if ${GROFF} -ms -I. /dev/null >/dev/null 2>&1 ; then + groff_ms_works=yes + else + groff_ms_works=no + fi + AC_MSG_RESULT([$groff_ms_works]) + AC_MSG_CHECKING([for ${GROFF} -mm macros]) + if ${GROFF} -mm -I. /dev/null >/dev/null 2>&1 ; then + groff_mm_works=yes + else + groff_mm_works=no + fi + AC_MSG_RESULT([$groff_mm_works]) +fi + +# We have groff, test for HTML dependencies, one command per package +if test "x$have_groff" = x"yes"; then + AC_PATH_PROGS(GS_PATH, [gs gswin32c]) + AC_PATH_PROG(PNMTOPNG_PATH, [pnmtopng]) + AC_PATH_PROG(PSSELECT_PATH, [psselect]) + if test "x$GS_PATH" != "x" -a "x$PNMTOPNG_PATH" != "x" -a "x$PSSELECT_PATH" != "x"; then + have_groff_html=yes + else + have_groff_html=no + AC_MSG_WARN([grohtml dependencies not found - HTML Documentation skipped. Refer to grohtml man pages]) + fi +fi + +# Set Automake conditionals for Makefiles +AM_CONDITIONAL([HAVE_GROFF], [test "$have_groff" = yes]) +AM_CONDITIONAL([HAVE_GROFF_MS], [test "$groff_ms_works" = yes]) +AM_CONDITIONAL([HAVE_GROFF_MM], [test "$groff_mm_works" = yes]) +AM_CONDITIONAL([HAVE_GROFF_HTML], [test "$have_groff_html" = yes]) +]) # XORG_WITH_GROFF + +# XORG_WITH_FOP([DEFAULT]) +# ---------------- +# Minimum version: 1.6.0 +# Minimum version for optional DEFAULT argument: 1.11.0 +# +# Documentation tools are not always available on all platforms and sometimes +# not at the appropriate level. This macro enables a module to test for the +# presence of the tool and obtain it's path in separate variables. Coupled with +# the --with-fop option, it allows maximum flexibilty in making decisions +# as whether or not to use the fop package. When DEFAULT is not specified, +# --with-fop assumes 'auto'. +# +# Interface to module: +# HAVE_FOP: used in makefiles to conditionally generate documentation +# FOP: returns the path of the fop program found +# returns the path set by the user in the environment +# --with-fop: 'yes' user instructs the module to use fop +# 'no' user instructs the module not to use fop +# +# If the user sets the value of FOP, AC_PATH_PROG skips testing the path. +# +AC_DEFUN([XORG_WITH_FOP],[ +AC_ARG_VAR([FOP], [Path to fop command]) +m4_define([_defopt], m4_default([$1], [auto])) +AC_ARG_WITH(fop, + AS_HELP_STRING([--with-fop], + [Use fop to regenerate documentation (default: ]_defopt[)]), + [use_fop=$withval], [use_fop=]_defopt) +m4_undefine([_defopt]) + +if test "x$use_fop" = x"auto"; then + AC_PATH_PROG([FOP], [fop]) + if test "x$FOP" = "x"; then + AC_MSG_WARN([fop not found - documentation targets will be skipped]) + have_fop=no + else + have_fop=yes + fi +elif test "x$use_fop" = x"yes" ; then + AC_PATH_PROG([FOP], [fop]) + if test "x$FOP" = "x"; then + AC_MSG_ERROR([--with-fop=yes specified but fop not found in PATH]) + fi + have_fop=yes +elif test "x$use_fop" = x"no" ; then + if test "x$FOP" != "x"; then + AC_MSG_WARN([ignoring FOP environment variable since --with-fop=no was specified]) + fi + have_fop=no +else + AC_MSG_ERROR([--with-fop expects 'yes' or 'no']) +fi +AM_CONDITIONAL([HAVE_FOP], [test "$have_fop" = yes]) +]) # XORG_WITH_FOP + +# XORG_WITH_PS2PDF([DEFAULT]) +# ---------------- +# Minimum version: 1.6.0 +# Minimum version for optional DEFAULT argument: 1.11.0 +# +# Documentation tools are not always available on all platforms and sometimes +# not at the appropriate level. This macro enables a module to test for the +# presence of the tool and obtain it's path in separate variables. Coupled with +# the --with-ps2pdf option, it allows maximum flexibilty in making decisions +# as whether or not to use the ps2pdf package. When DEFAULT is not specified, +# --with-ps2pdf assumes 'auto'. +# +# Interface to module: +# HAVE_PS2PDF: used in makefiles to conditionally generate documentation +# PS2PDF: returns the path of the ps2pdf program found +# returns the path set by the user in the environment +# --with-ps2pdf: 'yes' user instructs the module to use ps2pdf +# 'no' user instructs the module not to use ps2pdf +# +# If the user sets the value of PS2PDF, AC_PATH_PROG skips testing the path. +# +AC_DEFUN([XORG_WITH_PS2PDF],[ +AC_ARG_VAR([PS2PDF], [Path to ps2pdf command]) +m4_define([_defopt], m4_default([$1], [auto])) +AC_ARG_WITH(ps2pdf, + AS_HELP_STRING([--with-ps2pdf], + [Use ps2pdf to regenerate documentation (default: ]_defopt[)]), + [use_ps2pdf=$withval], [use_ps2pdf=]_defopt) +m4_undefine([_defopt]) + +if test "x$use_ps2pdf" = x"auto"; then + AC_PATH_PROG([PS2PDF], [ps2pdf]) + if test "x$PS2PDF" = "x"; then + AC_MSG_WARN([ps2pdf not found - documentation targets will be skipped]) + have_ps2pdf=no + else + have_ps2pdf=yes + fi +elif test "x$use_ps2pdf" = x"yes" ; then + AC_PATH_PROG([PS2PDF], [ps2pdf]) + if test "x$PS2PDF" = "x"; then + AC_MSG_ERROR([--with-ps2pdf=yes specified but ps2pdf not found in PATH]) + fi + have_ps2pdf=yes +elif test "x$use_ps2pdf" = x"no" ; then + if test "x$PS2PDF" != "x"; then + AC_MSG_WARN([ignoring PS2PDF environment variable since --with-ps2pdf=no was specified]) + fi + have_ps2pdf=no +else + AC_MSG_ERROR([--with-ps2pdf expects 'yes' or 'no']) +fi +AM_CONDITIONAL([HAVE_PS2PDF], [test "$have_ps2pdf" = yes]) +]) # XORG_WITH_PS2PDF + +# XORG_ENABLE_DOCS (enable_docs=yes) +# ---------------- +# Minimum version: 1.6.0 +# +# Documentation tools are not always available on all platforms and sometimes +# not at the appropriate level. This macro enables a builder to skip all +# documentation targets except traditional man pages. +# Combined with the specific tool checking macros XORG_WITH_*, it provides +# maximum flexibilty in controlling documentation building. +# Refer to: +# XORG_WITH_XMLTO --with-xmlto +# XORG_WITH_ASCIIDOC --with-asciidoc +# XORG_WITH_DOXYGEN --with-doxygen +# XORG_WITH_FOP --with-fop +# XORG_WITH_GROFF --with-groff +# XORG_WITH_PS2PDF --with-ps2pdf +# +# Interface to module: +# ENABLE_DOCS: used in makefiles to conditionally generate documentation +# --enable-docs: 'yes' user instructs the module to generate docs +# 'no' user instructs the module not to generate docs +# parm1: specify the default value, yes or no. +# +AC_DEFUN([XORG_ENABLE_DOCS],[ +m4_define([default], m4_default([$1], [yes])) +AC_ARG_ENABLE(docs, + AS_HELP_STRING([--enable-docs], + [Enable building the documentation (default: ]default[)]), + [build_docs=$enableval], [build_docs=]default) +m4_undefine([default]) +AM_CONDITIONAL(ENABLE_DOCS, [test x$build_docs = xyes]) +AC_MSG_CHECKING([whether to build documentation]) +AC_MSG_RESULT([$build_docs]) +]) # XORG_ENABLE_DOCS + +# XORG_ENABLE_DEVEL_DOCS (enable_devel_docs=yes) +# ---------------- +# Minimum version: 1.6.0 +# +# This macro enables a builder to skip all developer documentation. +# Combined with the specific tool checking macros XORG_WITH_*, it provides +# maximum flexibilty in controlling documentation building. +# Refer to: +# XORG_WITH_XMLTO --with-xmlto +# XORG_WITH_ASCIIDOC --with-asciidoc +# XORG_WITH_DOXYGEN --with-doxygen +# XORG_WITH_FOP --with-fop +# XORG_WITH_GROFF --with-groff +# XORG_WITH_PS2PDF --with-ps2pdf +# +# Interface to module: +# ENABLE_DEVEL_DOCS: used in makefiles to conditionally generate developer docs +# --enable-devel-docs: 'yes' user instructs the module to generate developer docs +# 'no' user instructs the module not to generate developer docs +# parm1: specify the default value, yes or no. +# +AC_DEFUN([XORG_ENABLE_DEVEL_DOCS],[ +m4_define([devel_default], m4_default([$1], [yes])) +AC_ARG_ENABLE(devel-docs, + AS_HELP_STRING([--enable-devel-docs], + [Enable building the developer documentation (default: ]devel_default[)]), + [build_devel_docs=$enableval], [build_devel_docs=]devel_default) +m4_undefine([devel_default]) +AM_CONDITIONAL(ENABLE_DEVEL_DOCS, [test x$build_devel_docs = xyes]) +AC_MSG_CHECKING([whether to build developer documentation]) +AC_MSG_RESULT([$build_devel_docs]) +]) # XORG_ENABLE_DEVEL_DOCS + +# XORG_ENABLE_SPECS (enable_specs=yes) +# ---------------- +# Minimum version: 1.6.0 +# +# This macro enables a builder to skip all functional specification targets. +# Combined with the specific tool checking macros XORG_WITH_*, it provides +# maximum flexibilty in controlling documentation building. +# Refer to: +# XORG_WITH_XMLTO --with-xmlto +# XORG_WITH_ASCIIDOC --with-asciidoc +# XORG_WITH_DOXYGEN --with-doxygen +# XORG_WITH_FOP --with-fop +# XORG_WITH_GROFF --with-groff +# XORG_WITH_PS2PDF --with-ps2pdf +# +# Interface to module: +# ENABLE_SPECS: used in makefiles to conditionally generate specs +# --enable-specs: 'yes' user instructs the module to generate specs +# 'no' user instructs the module not to generate specs +# parm1: specify the default value, yes or no. +# +AC_DEFUN([XORG_ENABLE_SPECS],[ +m4_define([spec_default], m4_default([$1], [yes])) +AC_ARG_ENABLE(specs, + AS_HELP_STRING([--enable-specs], + [Enable building the specs (default: ]spec_default[)]), + [build_specs=$enableval], [build_specs=]spec_default) +m4_undefine([spec_default]) +AM_CONDITIONAL(ENABLE_SPECS, [test x$build_specs = xyes]) +AC_MSG_CHECKING([whether to build functional specifications]) +AC_MSG_RESULT([$build_specs]) +]) # XORG_ENABLE_SPECS + # XORG_CHECK_MALLOC_ZERO # ---------------------- # Minimum version: 1.0.0 @@ -7972,7 +8550,8 @@ main() { exit(m0 == 0 || r0 == 0 || c0 == 0 ? 0 : 1); }], [MALLOC_ZERO_RETURNS_NULL=yes], - [MALLOC_ZERO_RETURNS_NULL=no]) + [MALLOC_ZERO_RETURNS_NULL=no], + [MALLOC_ZERO_RETURNS_NULL=yes]) fi AC_MSG_RESULT([$MALLOC_ZERO_RETURNS_NULL]) @@ -7995,38 +8574,69 @@ AC_SUBST([XTMALLOC_ZERO_CFLAGS]) # ---------------- # Minimum version: 1.1.0 # -# Sets up flags for source checkers such as lint and sparse if --with-lint -# is specified. (Use --with-lint=sparse for sparse.) -# Sets $LINT to name of source checker passed with --with-lint (default: lint) -# Sets $LINT_FLAGS to flags to pass to source checker -# Sets LINT automake conditional if enabled (default: disabled) +# This macro enables the use of a tool that flags some suspicious and +# non-portable constructs (likely to be bugs) in C language source code. +# It will attempt to locate the tool and use appropriate options. +# There are various lint type tools on different platforms. +# +# Interface to module: +# LINT: returns the path to the tool found on the platform +# or the value set to LINT on the configure cmd line +# also an Automake conditional +# LINT_FLAGS: an Automake variable with appropriate flags +# +# --with-lint: 'yes' user instructs the module to use lint +# 'no' user instructs the module not to use lint (default) +# +# If the user sets the value of LINT, AC_PATH_PROG skips testing the path. +# If the user sets the value of LINT_FLAGS, they are used verbatim. # AC_DEFUN([XORG_WITH_LINT],[ -# Allow checking code with lint, sparse, etc. +AC_ARG_VAR([LINT], [Path to a lint-style command]) +AC_ARG_VAR([LINT_FLAGS], [Flags for the lint-style command]) AC_ARG_WITH(lint, [AS_HELP_STRING([--with-lint], [Use a lint-style source code checker (default: disabled)])], [use_lint=$withval], [use_lint=no]) -if test "x$use_lint" = "xyes" ; then - LINT="lint" + +# Obtain platform specific info like program name and options +# The lint program on FreeBSD and NetBSD is different from the one on Solaris +case $host_os in + *linux* | *openbsd* | kfreebsd*-gnu | darwin* | cygwin*) + lint_name=splint + lint_options="-badflag" + ;; + *freebsd* | *netbsd*) + lint_name=lint + lint_options="-u -b" + ;; + *solaris*) + lint_name=lint + lint_options="-u -b -h -erroff=E_INDISTING_FROM_TRUNC2" + ;; +esac + +# Test for the presence of the program (either guessed by the code or spelled out by the user) +if test "x$use_lint" = x"yes" ; then + AC_PATH_PROG([LINT], [$lint_name]) + if test "x$LINT" = "x"; then + AC_MSG_ERROR([--with-lint=yes specified but lint-style tool not found in PATH]) + fi +elif test "x$use_lint" = x"no" ; then + if test "x$LINT" != "x"; then + AC_MSG_WARN([ignoring LINT environment variable since --with-lint=no was specified]) + fi else - LINT="$use_lint" + AC_MSG_ERROR([--with-lint expects 'yes' or 'no'. Use LINT variable to specify path.]) fi -if test "x$LINT_FLAGS" = "x" -a "x$LINT" != "xno" ; then - case $LINT in - lint|*/lint) - case $host_os in - solaris*) - LINT_FLAGS="-u -b -h -erroff=E_INDISTING_FROM_TRUNC2" - ;; - esac - ;; - esac + +# User supplied flags override default flags +if test "x$LINT_FLAGS" != "x"; then + lint_options=$LINT_FLAGS fi -AC_SUBST(LINT) -AC_SUBST(LINT_FLAGS) -AM_CONDITIONAL(LINT, [test x$LINT != xno]) +AC_SUBST([LINT_FLAGS],[$lint_options]) +AM_CONDITIONAL(LINT, [test "x$LINT" != x]) ]) # XORG_WITH_LINT @@ -8036,28 +8646,29 @@ AM_CONDITIONAL(LINT, [test x$LINT != xno]) # # Sets up flags for building lint libraries for checking programs that call # functions in the library. -# Disabled by default, enable with --enable-lint-library -# Sets: -# @LINTLIB@ - name of lint library file to make -# MAKE_LINT_LIB - automake conditional # +# Interface to module: +# LINTLIB - Automake variable with the name of lint library file to make +# MAKE_LINT_LIB - Automake conditional +# +# --enable-lint-library: - 'yes' user instructs the module to created a lint library +# - 'no' user instructs the module not to create a lint library (default) AC_DEFUN([XORG_LINT_LIBRARY],[ AC_REQUIRE([XORG_WITH_LINT]) -# Build lint "library" for more indepth checks of programs calling this library AC_ARG_ENABLE(lint-library, [AS_HELP_STRING([--enable-lint-library], [Create lint library (default: disabled)])], [make_lint_lib=$enableval], [make_lint_lib=no]) -if test "x$make_lint_lib" != "xno" ; then - if test "x$LINT" = "xno" ; then - AC_MSG_ERROR([Cannot make lint library without --with-lint]) - fi - if test "x$make_lint_lib" = "xyes" ; then - LINTLIB=llib-l$1.ln - else - LINTLIB=$make_lint_lib - fi + +if test "x$make_lint_lib" = x"yes" ; then + LINTLIB=llib-l$1.ln + if test "x$LINT" = "x"; then + AC_MSG_ERROR([Cannot make lint library without --with-lint]) + fi +elif test "x$make_lint_lib" != x"no" ; then + AC_MSG_ERROR([--enable-lint-library expects 'yes' or 'no'.]) fi + AC_SUBST(LINTLIB) AM_CONDITIONAL(MAKE_LINT_LIB, [test x$make_lint_lib != xno]) @@ -8070,11 +8681,11 @@ AM_CONDITIONAL(MAKE_LINT_LIB, [test x$make_lint_lib != xno]) # Defines CWARNFLAGS to enable C compiler warnings. # AC_DEFUN([XORG_CWARNFLAGS], [ -AC_REQUIRE([AC_PROG_CC]) +AC_REQUIRE([AC_PROG_CC_C99]) if test "x$GCC" = xyes ; then CWARNFLAGS="-Wall -Wpointer-arith -Wstrict-prototypes -Wmissing-prototypes \ -Wmissing-declarations -Wnested-externs -fno-strict-aliasing \ --Wbad-function-cast" +-Wbad-function-cast -Wformat=2" case `$CC -dumpversion` in 3.4.* | 4.*) CWARNFLAGS="$CWARNFLAGS -Wold-style-definition -Wdeclaration-after-statement" @@ -8087,7 +8698,6 @@ else fi fi AC_SUBST(CWARNFLAGS) -m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])]) ]) # XORG_CWARNFLAGS # XORG_STRICT_OPTION @@ -8096,7 +8706,7 @@ m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])]) # # Add configure option to enable strict compilation AC_DEFUN([XORG_STRICT_OPTION], [ -AC_REQUIRE([AC_PROG_CC]) +# If the module's configure.ac calls AC_PROG_CC later on, CC gets set to C89 AC_REQUIRE([AC_PROG_CC_C99]) AC_REQUIRE([XORG_CWARNFLAGS]) @@ -8126,12 +8736,33 @@ AC_SUBST([CWARNFLAGS]) # Defines default options for X.Org modules. # AC_DEFUN([XORG_DEFAULT_OPTIONS], [ +AC_REQUIRE([AC_PROG_INSTALL]) XORG_CWARNFLAGS XORG_STRICT_OPTION XORG_RELEASE_VERSION XORG_CHANGELOG +XORG_INSTALL XORG_MANPAGE_SECTIONS +m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])], + [AC_SUBST([AM_DEFAULT_VERBOSITY], [1])]) ]) # XORG_DEFAULT_OPTIONS + +# XORG_INSTALL() +# ---------------- +# Minimum version: 1.4.0 +# +# Defines the variable INSTALL_CMD as the command to copy +# INSTALL from $prefix/share/util-macros. +# +AC_DEFUN([XORG_INSTALL], [ +AC_REQUIRE([PKG_PROG_PKG_CONFIG]) +macros_datadir=`$PKG_CONFIG --print-errors --variable=pkgdatadir xorg-macros` +INSTALL_CMD="(cp -f "$macros_datadir/INSTALL" \$(top_srcdir)/.INSTALL.tmp && \ +mv \$(top_srcdir)/.INSTALL.tmp \$(top_srcdir)/INSTALL) \ +|| (rm -f \$(top_srcdir)/.INSTALL.tmp; touch \$(top_srcdir)/INSTALL; \ +echo 'util-macros \"pkgdatadir\" from xorg-macros.pc not found: installing possibly empty INSTALL.' >&2)" +AC_SUBST([INSTALL_CMD]) +]) # XORG_INSTALL dnl Copyright 2005 Red Hat, Inc dnl dnl Permission to use, copy, modify, distribute, and sell this software and its @@ -8159,22 +8790,9 @@ dnl # XORG_RELEASE_VERSION # -------------------- -# Adds --with/without-release-string and changes the PACKAGE and -# PACKAGE_TARNAME to use "$PACKAGE{_TARNAME}-$RELEASE_VERSION". If -# no option is given, PACKAGE and PACKAGE_TARNAME are unchanged. Also -# defines PACKAGE_VERSION_{MAJOR,MINOR,PATCHLEVEL} for modules to use. +# Defines PACKAGE_VERSION_{MAJOR,MINOR,PATCHLEVEL} for modules to use. AC_DEFUN([XORG_RELEASE_VERSION],[ - AC_ARG_WITH(release-version, - AS_HELP_STRING([--with-release-version=STRING], - [Use release version string in package name]), - [RELEASE_VERSION="$withval"], - [RELEASE_VERSION=""]) - if test "x$RELEASE_VERSION" != "x"; then - PACKAGE="$PACKAGE-$RELEASE_VERSION" - PACKAGE_TARNAME="$PACKAGE_TARNAME-$RELEASE_VERSION" - AC_MSG_NOTICE([Building with package name set to $PACKAGE]) - fi AC_DEFINE_UNQUOTED([PACKAGE_VERSION_MAJOR], [`echo $PACKAGE_VERSION | cut -d . -f 1`], [Major version of this package]) @@ -8201,13 +8819,12 @@ AC_DEFUN([XORG_RELEASE_VERSION],[ # Defines the variable CHANGELOG_CMD as the command to generate # ChangeLog from git. # -# Arrange that distcleancheck ignores ChangeLog left over by distclean. # AC_DEFUN([XORG_CHANGELOG], [ -CHANGELOG_CMD="(GIT_DIR=\$(top_srcdir)/.git git log > .changelog.tmp && \ -mv .changelog.tmp ChangeLog) || (rm -f .changelog.tmp; touch ChangeLog; \ +CHANGELOG_CMD="(GIT_DIR=\$(top_srcdir)/.git git log > \$(top_srcdir)/.changelog.tmp && \ +mv \$(top_srcdir)/.changelog.tmp \$(top_srcdir)/ChangeLog) \ +|| (rm -f \$(top_srcdir)/.changelog.tmp; touch \$(top_srcdir)/ChangeLog; \ echo 'git directory not found: installing possibly empty changelog.' >&2)" AC_SUBST([CHANGELOG_CMD]) -AC_SUBST([distcleancheck_listfiles], ['find . -type f ! -name ChangeLog -print']) ]) # XORG_CHANGELOG diff --git a/lib/libXdmcp/configure b/lib/libXdmcp/configure index 64b02c650..90194e774 100644 --- a/lib/libXdmcp/configure +++ b/lib/libXdmcp/configure @@ -1,6 +1,6 @@ #! /bin/sh # Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.62 for libXdmcp 1.0.3. +# Generated by GNU Autoconf 2.62 for libXdmcp 1.1.0. # # Report bugs to <https://bugs.freedesktop.org/enter_bug.cgi?product=xorg>. # @@ -572,6 +572,66 @@ as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" +as_awk_strverscmp=' + # Use only awk features that work with 7th edition Unix awk (1978). + # My, what an old awk you have, Mr. Solaris! + END { + while (length(v1) && length(v2)) { + # Set d1 to be the next thing to compare from v1, and likewise for d2. + # Normally this is a single character, but if v1 and v2 contain digits, + # compare them as integers and fractions as strverscmp does. + if (v1 ~ /^[0-9]/ && v2 ~ /^[0-9]/) { + # Split v1 and v2 into their leading digit string components d1 and d2, + # and advance v1 and v2 past the leading digit strings. + for (len1 = 1; substr(v1, len1 + 1) ~ /^[0-9]/; len1++) continue + for (len2 = 1; substr(v2, len2 + 1) ~ /^[0-9]/; len2++) continue + d1 = substr(v1, 1, len1); v1 = substr(v1, len1 + 1) + d2 = substr(v2, 1, len2); v2 = substr(v2, len2 + 1) + if (d1 ~ /^0/) { + if (d2 ~ /^0/) { + # Compare two fractions. + while (d1 ~ /^0/ && d2 ~ /^0/) { + d1 = substr(d1, 2); len1-- + d2 = substr(d2, 2); len2-- + } + if (len1 != len2 && ! (len1 && len2 && substr(d1, 1, 1) == substr(d2, 1, 1))) { + # The two components differ in length, and the common prefix + # contains only leading zeros. Consider the longer to be less. + d1 = -len1 + d2 = -len2 + } else { + # Otherwise, compare as strings. + d1 = "x" d1 + d2 = "x" d2 + } + } else { + # A fraction is less than an integer. + exit 1 + } + } else { + if (d2 ~ /^0/) { + # An integer is greater than a fraction. + exit 2 + } else { + # Compare two integers. + d1 += 0 + d2 += 0 + } + } + } else { + # The normal case, without worrying about digits. + d1 = substr(v1, 1, 1); v1 = substr(v1, 2) + d2 = substr(v2, 1, 1); v2 = substr(v2, 2) + } + if (d1 < d2) exit 1 + if (d1 > d2) exit 2 + } + # Beware Solaris /usr/xgp4/bin/awk (at least through Solaris 10), + # which mishandles some comparisons of empty strings to integers. + if (length(v2)) exit 1 + if (length(v1)) exit 2 + } +' # Check that we are running under the correct shell. @@ -750,8 +810,8 @@ SHELL=${CONFIG_SHELL-/bin/sh} # Identity of this package. PACKAGE_NAME='libXdmcp' PACKAGE_TARNAME='libXdmcp' -PACKAGE_VERSION='1.0.3' -PACKAGE_STRING='libXdmcp 1.0.3' +PACKAGE_VERSION='1.1.0' +PACKAGE_STRING='libXdmcp 1.1.0' PACKAGE_BUGREPORT='https://bugs.freedesktop.org/enter_bug.cgi?product=xorg' # Factoring default headers for most tests. @@ -867,7 +927,13 @@ AMDEPBACKSLASH CCDEPMODE am__fastdepCC_TRUE am__fastdepCC_FALSE -LN_S +CPP +GREP +EGREP +CWARNFLAGS +CHANGELOG_CMD +PKG_CONFIG +INSTALL_CMD build build_cpu build_vendor @@ -877,8 +943,37 @@ host_cpu host_vendor host_os SED -GREP -EGREP +APP_MAN_SUFFIX +LIB_MAN_SUFFIX +FILE_MAN_SUFFIX +MISC_MAN_SUFFIX +DRIVER_MAN_SUFFIX +ADMIN_MAN_SUFFIX +APP_MAN_DIR +LIB_MAN_DIR +FILE_MAN_DIR +MISC_MAN_DIR +DRIVER_MAN_DIR +ADMIN_MAN_DIR +XORG_MAN_PAGE +MAN_SUBSTS +AM_DEFAULT_VERBOSITY +ENABLE_DOCS_TRUE +ENABLE_DOCS_FALSE +XMLTO +HAVE_XMLTO_TEXT_TRUE +HAVE_XMLTO_TEXT_FALSE +HAVE_XMLTO_TRUE +HAVE_XMLTO_FALSE +FOP +HAVE_FOP_TRUE +HAVE_FOP_FALSE +XORG_SGML_PATH +STYLESHEET_SRCDIR +XSL_STYLESHEET +HAVE_STYLESHEETS_TRUE +HAVE_STYLESHEETS_FALSE +LN_S ECHO AR RANLIB @@ -887,7 +982,6 @@ NMEDIT DLLTOOL AS OBJDUMP -CPP CXX CXXFLAGS ac_ct_CXX @@ -899,24 +993,8 @@ F77 FFLAGS ac_ct_F77 LIBTOOL -PKG_CONFIG XDMCP_CFLAGS XDMCP_LIBS -CWARNFLAGS -CHANGELOG_CMD -distcleancheck_listfiles -APP_MAN_SUFFIX -LIB_MAN_SUFFIX -FILE_MAN_SUFFIX -MISC_MAN_SUFFIX -DRIVER_MAN_SUFFIX -ADMIN_MAN_SUFFIX -APP_MAN_DIR -LIB_MAN_DIR -FILE_MAN_DIR -MISC_MAN_DIR -DRIVER_MAN_DIR -ADMIN_MAN_DIR HASXDMAUTH_TRUE HASXDMAUTH_FALSE LINT @@ -933,6 +1011,10 @@ ac_user_opts=' enable_option_checking enable_maintainer_mode enable_dependency_tracking +enable_strict_compilation +enable_docs +with_xmlto +with_fop enable_shared enable_static enable_fast_install @@ -940,8 +1022,6 @@ with_gnu_ld enable_libtool_lock with_pic with_tags -enable_strict_compilation -with_release_version with_lint enable_lint_library ' @@ -954,15 +1034,19 @@ LDFLAGS LIBS CPPFLAGS CPP +PKG_CONFIG +XMLTO +FOP CXX CXXFLAGS CCC CXXCPP F77 FFLAGS -PKG_CONFIG XDMCP_CFLAGS -XDMCP_LIBS' +XDMCP_LIBS +LINT +LINT_FLAGS' # Initialize some variables set by options. @@ -1515,7 +1599,7 @@ if test "$ac_init_help" = "long"; then # Omit some internal or obsolete options to make the list less imposing. # This message is too long to be a string in the A/UX 3.1 sh. cat <<_ACEOF -\`configure' configures libXdmcp 1.0.3 to adapt to many kinds of systems. +\`configure' configures libXdmcp 1.1.0 to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... @@ -1585,7 +1669,7 @@ fi if test -n "$ac_init_help"; then case $ac_init_help in - short | recursive ) echo "Configuration of libXdmcp 1.0.3:";; + short | recursive ) echo "Configuration of libXdmcp 1.1.0:";; esac cat <<\_ACEOF @@ -1597,25 +1681,27 @@ Optional Features: (and sometimes confusing) to the casual installer --disable-dependency-tracking speeds up one-time build --enable-dependency-tracking do not reject slow dependency extractors + --enable-strict-compilation + Enable all warnings from compiler and make them + errors (default: disabled) + --enable-docs Enable building the documentation (yes: yes) --enable-shared[=PKGS] build shared libraries [default=yes] --enable-static[=PKGS] build static libraries [default=yes] --enable-fast-install[=PKGS] optimize for fast installation [default=yes] --disable-libtool-lock avoid locking (might break parallel builds) - --enable-strict-compilation - Enable all warnings from compiler and make them - errors (default: disabled) --enable-lint-library Create lint library (default: disabled) Optional Packages: --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) + --with-xmlto Use xmlto to regenerate documentation (default: + auto) + --with-fop Use fop to regenerate documentation (default: auto) --with-gnu-ld assume the C compiler uses GNU ld [default=no] --with-pic try to use only PIC/non-PIC objects [default=use both] --with-tags[=TAGS] include additional configurations [automatic] - --with-release-version=STRING - Use release version string in package name --with-lint Use a lint-style source code checker (default: disabled) @@ -1628,15 +1714,19 @@ Some influential environment variables: CPPFLAGS C/C++/Objective C preprocessor flags, e.g. -I<include dir> if you have headers in a nonstandard directory <include dir> CPP C preprocessor + PKG_CONFIG path to pkg-config utility + XMLTO Path to xmlto command + FOP Path to fop command CXX C++ compiler command CXXFLAGS C++ compiler flags CXXCPP C++ preprocessor F77 Fortran 77 compiler command FFLAGS Fortran 77 compiler flags - PKG_CONFIG path to pkg-config utility XDMCP_CFLAGS C compiler flags for XDMCP, overriding pkg-config XDMCP_LIBS linker flags for XDMCP, overriding pkg-config + LINT Path to a lint-style command + LINT_FLAGS Flags for the lint-style command Use these variables to override the choices made by `configure' or to help it to find libraries and programs with nonstandard names/locations. @@ -1704,7 +1794,7 @@ fi test -n "$ac_init_help" && exit $ac_status if $ac_init_version; then cat <<\_ACEOF -libXdmcp configure 1.0.3 +libXdmcp configure 1.1.0 generated by GNU Autoconf 2.62 Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, @@ -1718,7 +1808,7 @@ cat >config.log <<_ACEOF This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. -It was created by libXdmcp $as_me 1.0.3, which was +It was created by libXdmcp $as_me 1.1.0, which was generated by GNU Autoconf 2.62. Invocation command line was $ $0 $@ @@ -2367,7 +2457,7 @@ fi # Define the identity of the package. PACKAGE='libXdmcp' - VERSION='1.0.3' + VERSION='1.1.0' cat >>confdefs.h <<_ACEOF @@ -2541,7 +2631,11 @@ fi ac_config_headers="$ac_config_headers config.h" -# Require xorg-macros: XORG_WITH_LINT, XORG_CWARNFLAGS, XORG_CHANGELOG +# Require xorg-macros minimum of 1.10 for HAVE_STYLESHEETS in XORG_CHECK_SGML_DOCTOOLS + + + + @@ -2549,8 +2643,68 @@ ac_config_headers="$ac_config_headers config.h" +DEPDIR="${am__leading_dot}deps" + +ac_config_commands="$ac_config_commands depfiles" + + +am_make=${MAKE-make} +cat > confinc << 'END' +am__doit: + @echo done +.PHONY: am__doit +END +# If we don't find an include directive, just comment out the code. +{ $as_echo "$as_me:$LINENO: checking for style of include used by $am_make" >&5 +$as_echo_n "checking for style of include used by $am_make... " >&6; } +am__include="#" +am__quote= +_am_result=none +# First try GNU make style include. +echo "include confinc" > confmf +# We grep out `Entering directory' and `Leaving directory' +# messages which can occur if `w' ends up in MAKEFLAGS. +# In particular we don't look at `^make:' because GNU make might +# be invoked under some other name (usually "gmake"), in which +# case it prints its new name instead of `make'. +if test "`$am_make -s -f confmf 2> /dev/null | grep -v 'ing directory'`" = "done"; then + am__include=include + am__quote= + _am_result=GNU +fi +# Now try BSD make style include. +if test "$am__include" = "#"; then + echo '.include "confinc"' > confmf + if test "`$am_make -s -f confmf 2> /dev/null`" = "done"; then + am__include=.include + am__quote="\"" + _am_result=BSD + fi +fi + + +{ $as_echo "$as_me:$LINENO: result: $_am_result" >&5 +$as_echo "$_am_result" >&6; } +rm -f confinc confmf + +# Check whether --enable-dependency-tracking was given. +if test "${enable_dependency_tracking+set}" = set; then + enableval=$enable_dependency_tracking; +fi + +if test "x$enable_dependency_tracking" != xno; then + am_depcomp="$ac_aux_dir/depcomp" + AMDEPBACKSLASH='\' +fi +if test "x$enable_dependency_tracking" != xno; then + AMDEP_TRUE= + AMDEP_FALSE='#' +else + AMDEP_TRUE='#' + AMDEP_FALSE= +fi @@ -3484,71 +3638,6 @@ ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu -DEPDIR="${am__leading_dot}deps" - -ac_config_commands="$ac_config_commands depfiles" - - -am_make=${MAKE-make} -cat > confinc << 'END' -am__doit: - @echo done -.PHONY: am__doit -END -# If we don't find an include directive, just comment out the code. -{ $as_echo "$as_me:$LINENO: checking for style of include used by $am_make" >&5 -$as_echo_n "checking for style of include used by $am_make... " >&6; } -am__include="#" -am__quote= -_am_result=none -# First try GNU make style include. -echo "include confinc" > confmf -# We grep out `Entering directory' and `Leaving directory' -# messages which can occur if `w' ends up in MAKEFLAGS. -# In particular we don't look at `^make:' because GNU make might -# be invoked under some other name (usually "gmake"), in which -# case it prints its new name instead of `make'. -if test "`$am_make -s -f confmf 2> /dev/null | grep -v 'ing directory'`" = "done"; then - am__include=include - am__quote= - _am_result=GNU -fi -# Now try BSD make style include. -if test "$am__include" = "#"; then - echo '.include "confinc"' > confmf - if test "`$am_make -s -f confmf 2> /dev/null`" = "done"; then - am__include=.include - am__quote="\"" - _am_result=BSD - fi -fi - - -{ $as_echo "$as_me:$LINENO: result: $_am_result" >&5 -$as_echo "$_am_result" >&6; } -rm -f confinc confmf - -# Check whether --enable-dependency-tracking was given. -if test "${enable_dependency_tracking+set}" = set; then - enableval=$enable_dependency_tracking; -fi - -if test "x$enable_dependency_tracking" != xno; then - am_depcomp="$ac_aux_dir/depcomp" - AMDEPBACKSLASH='\' -fi - - -if test "x$enable_dependency_tracking" != xno; then - AMDEP_TRUE= - AMDEP_FALSE='#' -else - AMDEP_TRUE='#' - AMDEP_FALSE= -fi - - - depcc="$CC" am_compiler_list= @@ -3659,184 +3748,948 @@ else fi -# Find a good install program. We prefer a C program (faster), -# so one script is as good as another. But avoid the broken or -# incompatible versions: -# SysV /etc/install, /usr/sbin/install -# SunOS /usr/etc/install -# IRIX /sbin/install -# AIX /bin/install -# AmigaOS /C/install, which installs bootblocks on floppy discs -# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag -# AFS /usr/afsws/bin/install, which mishandles nonexistent args -# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" -# OS/2's system install, which has a completely different semantic -# ./install, which can be erroneously created by make from ./install.sh. -# Reject install programs that cannot install multiple files. -{ $as_echo "$as_me:$LINENO: checking for a BSD-compatible install" >&5 -$as_echo_n "checking for a BSD-compatible install... " >&6; } -if test -z "$INSTALL"; then -if test "${ac_cv_path_install+set}" = set; then + { $as_echo "$as_me:$LINENO: checking for $CC option to accept ISO C99" >&5 +$as_echo_n "checking for $CC option to accept ISO C99... " >&6; } +if test "${ac_cv_prog_cc_c99+set}" = set; then + $as_echo_n "(cached) " >&6 +else + ac_cv_prog_cc_c99=no +ac_save_CC=$CC +cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ +#include <stdarg.h> +#include <stdbool.h> +#include <stdlib.h> +#include <wchar.h> +#include <stdio.h> + +// Check varargs macros. These examples are taken from C99 6.10.3.5. +#define debug(...) fprintf (stderr, __VA_ARGS__) +#define showlist(...) puts (#__VA_ARGS__) +#define report(test,...) ((test) ? puts (#test) : printf (__VA_ARGS__)) +static void +test_varargs_macros (void) +{ + int x = 1234; + int y = 5678; + debug ("Flag"); + debug ("X = %d\n", x); + showlist (The first, second, and third items.); + report (x>y, "x is %d but y is %d", x, y); +} + +// Check long long types. +#define BIG64 18446744073709551615ull +#define BIG32 4294967295ul +#define BIG_OK (BIG64 / BIG32 == 4294967297ull && BIG64 % BIG32 == 0) +#if !BIG_OK + your preprocessor is broken; +#endif +#if BIG_OK +#else + your preprocessor is broken; +#endif +static long long int bignum = -9223372036854775807LL; +static unsigned long long int ubignum = BIG64; + +struct incomplete_array +{ + int datasize; + double data[]; +}; + +struct named_init { + int number; + const wchar_t *name; + double average; +}; + +typedef const char *ccp; + +static inline int +test_restrict (ccp restrict text) +{ + // See if C++-style comments work. + // Iterate through items via the restricted pointer. + // Also check for declarations in for loops. + for (unsigned int i = 0; *(text+i) != '\0'; ++i) + continue; + return 0; +} + +// Check varargs and va_copy. +static void +test_varargs (const char *format, ...) +{ + va_list args; + va_start (args, format); + va_list args_copy; + va_copy (args_copy, args); + + const char *str; + int number; + float fnumber; + + while (*format) + { + switch (*format++) + { + case 's': // string + str = va_arg (args_copy, const char *); + break; + case 'd': // int + number = va_arg (args_copy, int); + break; + case 'f': // float + fnumber = va_arg (args_copy, double); + break; + default: + break; + } + } + va_end (args_copy); + va_end (args); +} + +int +main () +{ + + // Check bool. + _Bool success = false; + + // Check restrict. + if (test_restrict ("String literal") == 0) + success = true; + char *restrict newvar = "Another string"; + + // Check varargs. + test_varargs ("s, d' f .", "string", 65, 34.234); + test_varargs_macros (); + + // Check flexible array members. + struct incomplete_array *ia = + malloc (sizeof (struct incomplete_array) + (sizeof (double) * 10)); + ia->datasize = 10; + for (int i = 0; i < ia->datasize; ++i) + ia->data[i] = i * 1.234; + + // Check named initializers. + struct named_init ni = { + .number = 34, + .name = L"Test wide string", + .average = 543.34343, + }; + + ni.number = 58; + + int dynamic_array[ni.number]; + dynamic_array[ni.number - 1] = 543; + + // work around unused variable warnings + return (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == 'x' + || dynamic_array[ni.number - 1] != 543); + + ; + return 0; +} +_ACEOF +for ac_arg in '' -std=gnu99 -std=c99 -c99 -AC99 -xc99=all -qlanglvl=extc99 +do + CC="$ac_save_CC $ac_arg" + rm -f conftest.$ac_objext +if { (ac_try="$ac_compile" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" +$as_echo "$ac_try_echo") >&5 + (eval "$ac_compile") 2>conftest.er1 + ac_status=$? + grep -v '^ *+' conftest.er1 >conftest.err + rm -f conftest.er1 + cat conftest.err >&5 + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && { + test -z "$ac_c_werror_flag" || + test ! -s conftest.err + } && test -s conftest.$ac_objext; then + ac_cv_prog_cc_c99=$ac_arg +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + +fi + +rm -f core conftest.err conftest.$ac_objext + test "x$ac_cv_prog_cc_c99" != "xno" && break +done +rm -f conftest.$ac_ext +CC=$ac_save_CC + +fi +# AC_CACHE_VAL +case "x$ac_cv_prog_cc_c99" in + x) + { $as_echo "$as_me:$LINENO: result: none needed" >&5 +$as_echo "none needed" >&6; } ;; + xno) + { $as_echo "$as_me:$LINENO: result: unsupported" >&5 +$as_echo "unsupported" >&6; } ;; + *) + CC="$CC $ac_cv_prog_cc_c99" + { $as_echo "$as_me:$LINENO: result: $ac_cv_prog_cc_c99" >&5 +$as_echo "$ac_cv_prog_cc_c99" >&6; } ;; +esac + + + + +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu +{ $as_echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5 +$as_echo_n "checking how to run the C preprocessor... " >&6; } +# On Suns, sometimes $CPP names a directory. +if test -n "$CPP" && test -d "$CPP"; then + CPP= +fi +if test -z "$CPP"; then + if test "${ac_cv_prog_CPP+set}" = set; then $as_echo_n "(cached) " >&6 else + # Double quotes because CPP needs to be expanded + for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" + do + ac_preproc_ok=false +for ac_c_preproc_warn_flag in '' yes +do + # Use a header file that comes with gcc, so configuring glibc + # with a fresh cross-compiler works. + # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since + # <limits.h> exists even on freestanding compilers. + # On the NeXT, cc -E runs the code through the compiler's parser, + # not just through cpp. "Syntax error" is here to catch this case. + cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ +#ifdef __STDC__ +# include <limits.h> +#else +# include <assert.h> +#endif + Syntax error +_ACEOF +if { (ac_try="$ac_cpp conftest.$ac_ext" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" +$as_echo "$ac_try_echo") >&5 + (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 + ac_status=$? + grep -v '^ *+' conftest.er1 >conftest.err + rm -f conftest.er1 + cat conftest.err >&5 + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } >/dev/null && { + test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || + test ! -s conftest.err + }; then + : +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + # Broken: fails on valid input. +continue +fi + +rm -f conftest.err conftest.$ac_ext + + # OK, works on sane cases. Now check whether nonexistent headers + # can be detected and how. + cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ +#include <ac_nonexistent.h> +_ACEOF +if { (ac_try="$ac_cpp conftest.$ac_ext" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" +$as_echo "$ac_try_echo") >&5 + (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 + ac_status=$? + grep -v '^ *+' conftest.er1 >conftest.err + rm -f conftest.er1 + cat conftest.err >&5 + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } >/dev/null && { + test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || + test ! -s conftest.err + }; then + # Broken: success on invalid input. +continue +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + # Passes both tests. +ac_preproc_ok=: +break +fi + +rm -f conftest.err conftest.$ac_ext + +done +# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. +rm -f conftest.err conftest.$ac_ext +if $ac_preproc_ok; then + break +fi + + done + ac_cv_prog_CPP=$CPP + +fi + CPP=$ac_cv_prog_CPP +else + ac_cv_prog_CPP=$CPP +fi +{ $as_echo "$as_me:$LINENO: result: $CPP" >&5 +$as_echo "$CPP" >&6; } +ac_preproc_ok=false +for ac_c_preproc_warn_flag in '' yes +do + # Use a header file that comes with gcc, so configuring glibc + # with a fresh cross-compiler works. + # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since + # <limits.h> exists even on freestanding compilers. + # On the NeXT, cc -E runs the code through the compiler's parser, + # not just through cpp. "Syntax error" is here to catch this case. + cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ +#ifdef __STDC__ +# include <limits.h> +#else +# include <assert.h> +#endif + Syntax error +_ACEOF +if { (ac_try="$ac_cpp conftest.$ac_ext" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" +$as_echo "$ac_try_echo") >&5 + (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 + ac_status=$? + grep -v '^ *+' conftest.er1 >conftest.err + rm -f conftest.er1 + cat conftest.err >&5 + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } >/dev/null && { + test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || + test ! -s conftest.err + }; then + : +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + # Broken: fails on valid input. +continue +fi + +rm -f conftest.err conftest.$ac_ext + + # OK, works on sane cases. Now check whether nonexistent headers + # can be detected and how. + cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ +#include <ac_nonexistent.h> +_ACEOF +if { (ac_try="$ac_cpp conftest.$ac_ext" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" +$as_echo "$ac_try_echo") >&5 + (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 + ac_status=$? + grep -v '^ *+' conftest.er1 >conftest.err + rm -f conftest.er1 + cat conftest.err >&5 + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } >/dev/null && { + test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || + test ! -s conftest.err + }; then + # Broken: success on invalid input. +continue +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + # Passes both tests. +ac_preproc_ok=: +break +fi + +rm -f conftest.err conftest.$ac_ext + +done +# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. +rm -f conftest.err conftest.$ac_ext +if $ac_preproc_ok; then + : +else + { { $as_echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check +See \`config.log' for more details." >&5 +$as_echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check +See \`config.log' for more details." >&2;} + { (exit 1); exit 1; }; } +fi + +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + + +{ $as_echo "$as_me:$LINENO: checking for grep that handles long lines and -e" >&5 +$as_echo_n "checking for grep that handles long lines and -e... " >&6; } +if test "${ac_cv_path_GREP+set}" = set; then + $as_echo_n "(cached) " >&6 +else + if test -z "$GREP"; then + ac_path_GREP_found=false + # Loop through the user's path and test for each of PROGNAME-LIST as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH +for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. - # Account for people who put trailing slashes in PATH elements. -case $as_dir/ in - ./ | .// | /cC/* | \ - /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \ - ?:\\/os2\\/install\\/* | ?:\\/OS2\\/INSTALL\\/* | \ - /usr/ucb/* ) ;; - *) - # OSF1 and SCO ODT 3.0 have their own names for install. - # Don't use installbsd from OSF since it installs stuff as root - # by default. - for ac_prog in ginstall scoinst install; do - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then - if test $ac_prog = install && - grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then - # AIX install. It has an incompatible calling convention. - : - elif test $ac_prog = install && - grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then - # program-specific install script used by HP pwplus--don't use. - : - else - rm -rf conftest.one conftest.two conftest.dir - echo one > conftest.one - echo two > conftest.two - mkdir conftest.dir - if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" && - test -s conftest.one && test -s conftest.two && - test -s conftest.dir/conftest.one && - test -s conftest.dir/conftest.two - then - ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c" - break 3 - fi - fi - fi - done + for ac_prog in grep ggrep; do + for ac_exec_ext in '' $ac_executable_extensions; do + ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" + { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue +# Check for GNU ac_path_GREP and select it if it is found. + # Check for GNU $ac_path_GREP +case `"$ac_path_GREP" --version 2>&1` in +*GNU*) + ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; +*) + ac_count=0 + $as_echo_n 0123456789 >"conftest.in" + while : + do + cat "conftest.in" "conftest.in" >"conftest.tmp" + mv "conftest.tmp" "conftest.in" + cp "conftest.in" "conftest.nl" + $as_echo 'GREP' >> "conftest.nl" + "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break + diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break + ac_count=`expr $ac_count + 1` + if test $ac_count -gt ${ac_path_GREP_max-0}; then + # Best one so far, save it but keep looking for a better one + ac_cv_path_GREP="$ac_path_GREP" + ac_path_GREP_max=$ac_count + fi + # 10*(2^10) chars as input seems more than enough + test $ac_count -gt 10 && break + done + rm -f conftest.in conftest.tmp conftest.nl conftest.out;; +esac + + $ac_path_GREP_found && break 3 done - ;; + done +done +IFS=$as_save_IFS + if test -z "$ac_cv_path_GREP"; then + { { $as_echo "$as_me:$LINENO: error: no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5 +$as_echo "$as_me: error: no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;} + { (exit 1); exit 1; }; } + fi +else + ac_cv_path_GREP=$GREP +fi + +fi +{ $as_echo "$as_me:$LINENO: result: $ac_cv_path_GREP" >&5 +$as_echo "$ac_cv_path_GREP" >&6; } + GREP="$ac_cv_path_GREP" + + +{ $as_echo "$as_me:$LINENO: checking for egrep" >&5 +$as_echo_n "checking for egrep... " >&6; } +if test "${ac_cv_path_EGREP+set}" = set; then + $as_echo_n "(cached) " >&6 +else + if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 + then ac_cv_path_EGREP="$GREP -E" + else + if test -z "$EGREP"; then + ac_path_EGREP_found=false + # Loop through the user's path and test for each of PROGNAME-LIST + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_prog in egrep; do + for ac_exec_ext in '' $ac_executable_extensions; do + ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" + { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue +# Check for GNU ac_path_EGREP and select it if it is found. + # Check for GNU $ac_path_EGREP +case `"$ac_path_EGREP" --version 2>&1` in +*GNU*) + ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; +*) + ac_count=0 + $as_echo_n 0123456789 >"conftest.in" + while : + do + cat "conftest.in" "conftest.in" >"conftest.tmp" + mv "conftest.tmp" "conftest.in" + cp "conftest.in" "conftest.nl" + $as_echo 'EGREP' >> "conftest.nl" + "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break + diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break + ac_count=`expr $ac_count + 1` + if test $ac_count -gt ${ac_path_EGREP_max-0}; then + # Best one so far, save it but keep looking for a better one + ac_cv_path_EGREP="$ac_path_EGREP" + ac_path_EGREP_max=$ac_count + fi + # 10*(2^10) chars as input seems more than enough + test $ac_count -gt 10 && break + done + rm -f conftest.in conftest.tmp conftest.nl conftest.out;; esac + $ac_path_EGREP_found && break 3 + done + done done IFS=$as_save_IFS + if test -z "$ac_cv_path_EGREP"; then + { { $as_echo "$as_me:$LINENO: error: no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5 +$as_echo "$as_me: error: no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;} + { (exit 1); exit 1; }; } + fi +else + ac_cv_path_EGREP=$EGREP +fi -rm -rf conftest.one conftest.two conftest.dir + fi +fi +{ $as_echo "$as_me:$LINENO: result: $ac_cv_path_EGREP" >&5 +$as_echo "$ac_cv_path_EGREP" >&6; } + EGREP="$ac_cv_path_EGREP" + +{ $as_echo "$as_me:$LINENO: checking for ANSI C header files" >&5 +$as_echo_n "checking for ANSI C header files... " >&6; } +if test "${ac_cv_header_stdc+set}" = set; then + $as_echo_n "(cached) " >&6 +else + cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ +#include <stdlib.h> +#include <stdarg.h> +#include <string.h> +#include <float.h> + +int +main () +{ + + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext +if { (ac_try="$ac_compile" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" +$as_echo "$ac_try_echo") >&5 + (eval "$ac_compile") 2>conftest.er1 + ac_status=$? + grep -v '^ *+' conftest.er1 >conftest.err + rm -f conftest.er1 + cat conftest.err >&5 + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && { + test -z "$ac_c_werror_flag" || + test ! -s conftest.err + } && test -s conftest.$ac_objext; then + ac_cv_header_stdc=yes +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_cv_header_stdc=no fi - if test "${ac_cv_path_install+set}" = set; then - INSTALL=$ac_cv_path_install - else - # As a last resort, use the slow shell script. Don't cache a - # value for INSTALL within a source directory, because that will - # break other packages using the cache if that directory is - # removed, or if the value is a relative name. - INSTALL=$ac_install_sh - fi + +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + +if test $ac_cv_header_stdc = yes; then + # SunOS 4.x string.h does not declare mem*, contrary to ANSI. + cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ +#include <string.h> + +_ACEOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "memchr" >/dev/null 2>&1; then + : +else + ac_cv_header_stdc=no fi -{ $as_echo "$as_me:$LINENO: result: $INSTALL" >&5 -$as_echo "$INSTALL" >&6; } +rm -f conftest* -# Use test -z because SunOS4 sh mishandles braces in ${var-val}. -# It thinks the first close brace ends the variable substitution. -test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' +fi -test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}' +if test $ac_cv_header_stdc = yes; then + # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. + cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ +#include <stdlib.h> -test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' +_ACEOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "free" >/dev/null 2>&1; then + : +else + ac_cv_header_stdc=no +fi +rm -f conftest* -{ $as_echo "$as_me:$LINENO: checking whether ln -s works" >&5 -$as_echo_n "checking whether ln -s works... " >&6; } -LN_S=$as_ln_s -if test "$LN_S" = "ln -s"; then - { $as_echo "$as_me:$LINENO: result: yes" >&5 -$as_echo "yes" >&6; } +fi + +if test $ac_cv_header_stdc = yes; then + # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. + if test "$cross_compiling" = yes; then + : else - { $as_echo "$as_me:$LINENO: result: no, using $LN_S" >&5 -$as_echo "no, using $LN_S" >&6; } + cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ +#include <ctype.h> +#include <stdlib.h> +#if ((' ' & 0x0FF) == 0x020) +# define ISLOWER(c) ('a' <= (c) && (c) <= 'z') +# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) +#else +# define ISLOWER(c) \ + (('a' <= (c) && (c) <= 'i') \ + || ('j' <= (c) && (c) <= 'r') \ + || ('s' <= (c) && (c) <= 'z')) +# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) +#endif + +#define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) +int +main () +{ + int i; + for (i = 0; i < 256; i++) + if (XOR (islower (i), ISLOWER (i)) + || toupper (i) != TOUPPER (i)) + return 2; + return 0; +} +_ACEOF +rm -f conftest$ac_exeext +if { (ac_try="$ac_link" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" +$as_echo "$ac_try_echo") >&5 + (eval "$ac_link") 2>&5 + ac_status=$? + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && { ac_try='./conftest$ac_exeext' + { (case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" +$as_echo "$ac_try_echo") >&5 + (eval "$ac_try") 2>&5 + ac_status=$? + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then + : +else + $as_echo "$as_me: program exited with status $ac_status" >&5 +$as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + +( exit $ac_status ) +ac_cv_header_stdc=no +fi +rm -rf conftest.dSYM +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext fi +fi +fi +{ $as_echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5 +$as_echo "$ac_cv_header_stdc" >&6; } +if test $ac_cv_header_stdc = yes; then -# Check whether --enable-shared was given. -if test "${enable_shared+set}" = set; then - enableval=$enable_shared; p=${PACKAGE-default} - case $enableval in - yes) enable_shared=yes ;; - no) enable_shared=no ;; - *) - enable_shared=no - # Look at the argument we got. We use all the common list separators. - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," - for pkg in $enableval; do - IFS="$lt_save_ifs" - if test "X$pkg" = "X$p"; then - enable_shared=yes - fi - done - IFS="$lt_save_ifs" - ;; - esac +cat >>confdefs.h <<\_ACEOF +#define STDC_HEADERS 1 +_ACEOF + +fi + +# On IRIX 5.3, sys/types and inttypes.h are conflicting. + + + + + + + + + +for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \ + inttypes.h stdint.h unistd.h +do +as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +{ $as_echo "$as_me:$LINENO: checking for $ac_header" >&5 +$as_echo_n "checking for $ac_header... " >&6; } +if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then + $as_echo_n "(cached) " >&6 else - enable_shared=yes + cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ +$ac_includes_default + +#include <$ac_header> +_ACEOF +rm -f conftest.$ac_objext +if { (ac_try="$ac_compile" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" +$as_echo "$ac_try_echo") >&5 + (eval "$ac_compile") 2>conftest.er1 + ac_status=$? + grep -v '^ *+' conftest.er1 >conftest.err + rm -f conftest.er1 + cat conftest.err >&5 + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && { + test -z "$ac_c_werror_flag" || + test ! -s conftest.err + } && test -s conftest.$ac_objext; then + eval "$as_ac_Header=yes" +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + eval "$as_ac_Header=no" fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +ac_res=`eval 'as_val=${'$as_ac_Header'} + $as_echo "$as_val"'` + { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 +$as_echo "$ac_res" >&6; } +if test `eval 'as_val=${'$as_ac_Header'} + $as_echo "$as_val"'` = yes; then + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF -# Check whether --enable-static was given. -if test "${enable_static+set}" = set; then - enableval=$enable_static; p=${PACKAGE-default} - case $enableval in - yes) enable_static=yes ;; - no) enable_static=no ;; - *) - enable_static=no - # Look at the argument we got. We use all the common list separators. - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," - for pkg in $enableval; do - IFS="$lt_save_ifs" - if test "X$pkg" = "X$p"; then - enable_static=yes - fi - done - IFS="$lt_save_ifs" - ;; - esac +fi + +done + + + + +if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args. +set dummy ${ac_tool_prefix}pkg-config; ac_word=$2 +{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if test "${ac_cv_path_PKG_CONFIG+set}" = set; then + $as_echo_n "(cached) " >&6 else - enable_static=yes + case $PKG_CONFIG in + [\\/]* | ?:[\\/]*) + ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done +done +IFS=$as_save_IFS + + ;; +esac +fi +PKG_CONFIG=$ac_cv_path_PKG_CONFIG +if test -n "$PKG_CONFIG"; then + { $as_echo "$as_me:$LINENO: result: $PKG_CONFIG" >&5 +$as_echo "$PKG_CONFIG" >&6; } +else + { $as_echo "$as_me:$LINENO: result: no" >&5 +$as_echo "no" >&6; } fi -# Check whether --enable-fast-install was given. -if test "${enable_fast_install+set}" = set; then - enableval=$enable_fast_install; p=${PACKAGE-default} - case $enableval in - yes) enable_fast_install=yes ;; - no) enable_fast_install=no ;; - *) - enable_fast_install=no - # Look at the argument we got. We use all the common list separators. - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," - for pkg in $enableval; do - IFS="$lt_save_ifs" - if test "X$pkg" = "X$p"; then - enable_fast_install=yes - fi - done - IFS="$lt_save_ifs" - ;; - esac +fi +if test -z "$ac_cv_path_PKG_CONFIG"; then + ac_pt_PKG_CONFIG=$PKG_CONFIG + # Extract the first word of "pkg-config", so it can be a program name with args. +set dummy pkg-config; ac_word=$2 +{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if test "${ac_cv_path_ac_pt_PKG_CONFIG+set}" = set; then + $as_echo_n "(cached) " >&6 else - enable_fast_install=yes + case $ac_pt_PKG_CONFIG in + [\\/]* | ?:[\\/]*) + ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done +done +IFS=$as_save_IFS + + ;; +esac +fi +ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG +if test -n "$ac_pt_PKG_CONFIG"; then + { $as_echo "$as_me:$LINENO: result: $ac_pt_PKG_CONFIG" >&5 +$as_echo "$ac_pt_PKG_CONFIG" >&6; } +else + { $as_echo "$as_me:$LINENO: result: no" >&5 +$as_echo "no" >&6; } fi + if test "x$ac_pt_PKG_CONFIG" = x; then + PKG_CONFIG="" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools +whose name does not start with the host triplet. If you think this +configuration is useful to you, please write to autoconf@gnu.org." >&5 +$as_echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools +whose name does not start with the host triplet. If you think this +configuration is useful to you, please write to autoconf@gnu.org." >&2;} +ac_tool_warned=yes ;; +esac + PKG_CONFIG=$ac_pt_PKG_CONFIG + fi +else + PKG_CONFIG="$ac_cv_path_PKG_CONFIG" +fi + +fi +if test -n "$PKG_CONFIG"; then + _pkg_min_version=0.9.0 + { $as_echo "$as_me:$LINENO: checking pkg-config is at least version $_pkg_min_version" >&5 +$as_echo_n "checking pkg-config is at least version $_pkg_min_version... " >&6; } + if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then + { $as_echo "$as_me:$LINENO: result: yes" >&5 +$as_echo "yes" >&6; } + else + { $as_echo "$as_me:$LINENO: result: no" >&5 +$as_echo "no" >&6; } + PKG_CONFIG="" + fi +fi # Make sure we can run config.sub. $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 || { { $as_echo "$as_me:$LINENO: error: cannot run $SHELL $ac_aux_dir/config.sub" >&5 @@ -3922,85 +4775,32 @@ case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac { $as_echo "$as_me:$LINENO: checking for a sed that does not truncate output" >&5 $as_echo_n "checking for a sed that does not truncate output... " >&6; } -if test "${lt_cv_path_SED+set}" = set; then - $as_echo_n "(cached) " >&6 -else - # Loop through the user's path and test for sed and gsed. -# Then use that list of sed's as ones to test for truncation. -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for lt_ac_prog in sed gsed; do - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$lt_ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$lt_ac_prog$ac_exec_ext"; }; then - lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext" - fi - done - done -done -IFS=$as_save_IFS -lt_ac_max=0 -lt_ac_count=0 -# Add /usr/xpg4/bin/sed as it is typically found on Solaris -# along with /bin/sed that truncates output. -for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do - test ! -f $lt_ac_sed && continue - cat /dev/null > conftest.in - lt_ac_count=0 - echo $ECHO_N "0123456789$ECHO_C" >conftest.in - # Check for GNU sed and select it if it is found. - if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then - lt_cv_path_SED=$lt_ac_sed - break - fi - while true; do - cat conftest.in conftest.in >conftest.tmp - mv conftest.tmp conftest.in - cp conftest.in conftest.nl - echo >>conftest.nl - $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break - cmp -s conftest.out conftest.nl || break - # 10000 chars as input seems more than enough - test $lt_ac_count -gt 10 && break - lt_ac_count=`expr $lt_ac_count + 1` - if test $lt_ac_count -gt $lt_ac_max; then - lt_ac_max=$lt_ac_count - lt_cv_path_SED=$lt_ac_sed - fi - done -done - -fi - -SED=$lt_cv_path_SED - -{ $as_echo "$as_me:$LINENO: result: $SED" >&5 -$as_echo "$SED" >&6; } - -{ $as_echo "$as_me:$LINENO: checking for grep that handles long lines and -e" >&5 -$as_echo_n "checking for grep that handles long lines and -e... " >&6; } -if test "${ac_cv_path_GREP+set}" = set; then +if test "${ac_cv_path_SED+set}" = set; then $as_echo_n "(cached) " >&6 else - if test -z "$GREP"; then - ac_path_GREP_found=false + ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/ + for ac_i in 1 2 3 4 5 6 7; do + ac_script="$ac_script$as_nl$ac_script" + done + echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed + $as_unset ac_script || ac_script= + if test -z "$SED"; then + ac_path_SED_found=false # Loop through the user's path and test for each of PROGNAME-LIST as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin +for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. - for ac_prog in grep ggrep; do + for ac_prog in sed gsed; do for ac_exec_ext in '' $ac_executable_extensions; do - ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" - { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue -# Check for GNU ac_path_GREP and select it if it is found. - # Check for GNU $ac_path_GREP -case `"$ac_path_GREP" --version 2>&1` in + ac_path_SED="$as_dir/$ac_prog$ac_exec_ext" + { test -f "$ac_path_SED" && $as_test_x "$ac_path_SED"; } || continue +# Check for GNU ac_path_SED and select it if it is found. + # Check for GNU $ac_path_SED +case `"$ac_path_SED" --version 2>&1` in *GNU*) - ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; + ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;; *) ac_count=0 $as_echo_n 0123456789 >"conftest.in" @@ -4009,14 +4809,14 @@ case `"$ac_path_GREP" --version 2>&1` in cat "conftest.in" "conftest.in" >"conftest.tmp" mv "conftest.tmp" "conftest.in" cp "conftest.in" "conftest.nl" - $as_echo 'GREP' >> "conftest.nl" - "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break + $as_echo '' >> "conftest.nl" + "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break ac_count=`expr $ac_count + 1` - if test $ac_count -gt ${ac_path_GREP_max-0}; then + if test $ac_count -gt ${ac_path_SED_max-0}; then # Best one so far, save it but keep looking for a better one - ac_cv_path_GREP="$ac_path_GREP" - ac_path_GREP_max=$ac_count + ac_cv_path_SED="$ac_path_SED" + ac_path_SED_max=$ac_count fi # 10*(2^10) chars as input seems more than enough test $ac_count -gt 10 && break @@ -4024,94 +4824,904 @@ case `"$ac_path_GREP" --version 2>&1` in rm -f conftest.in conftest.tmp conftest.nl conftest.out;; esac - $ac_path_GREP_found && break 3 + $ac_path_SED_found && break 3 done done done IFS=$as_save_IFS - if test -z "$ac_cv_path_GREP"; then - { { $as_echo "$as_me:$LINENO: error: no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5 -$as_echo "$as_me: error: no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;} + if test -z "$ac_cv_path_SED"; then + { { $as_echo "$as_me:$LINENO: error: no acceptable sed could be found in \$PATH" >&5 +$as_echo "$as_me: error: no acceptable sed could be found in \$PATH" >&2;} { (exit 1); exit 1; }; } fi else - ac_cv_path_GREP=$GREP + ac_cv_path_SED=$SED fi fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_path_GREP" >&5 -$as_echo "$ac_cv_path_GREP" >&6; } - GREP="$ac_cv_path_GREP" +{ $as_echo "$as_me:$LINENO: result: $ac_cv_path_SED" >&5 +$as_echo "$ac_cv_path_SED" >&6; } + SED="$ac_cv_path_SED" + rm -f conftest.sed -{ $as_echo "$as_me:$LINENO: checking for egrep" >&5 -$as_echo_n "checking for egrep... " >&6; } -if test "${ac_cv_path_EGREP+set}" = set; then + + + +if test "x$GCC" = xyes ; then + CWARNFLAGS="-Wall -Wpointer-arith -Wstrict-prototypes -Wmissing-prototypes \ +-Wmissing-declarations -Wnested-externs -fno-strict-aliasing \ +-Wbad-function-cast -Wformat=2" + case `$CC -dumpversion` in + 3.4.* | 4.*) + CWARNFLAGS="$CWARNFLAGS -Wold-style-definition -Wdeclaration-after-statement" + ;; + esac +else + { $as_echo "$as_me:$LINENO: checking whether __SUNPRO_C is declared" >&5 +$as_echo_n "checking whether __SUNPRO_C is declared... " >&6; } +if test "${ac_cv_have_decl___SUNPRO_C+set}" = set; then $as_echo_n "(cached) " >&6 else - if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 - then ac_cv_path_EGREP="$GREP -E" - else - if test -z "$EGREP"; then - ac_path_EGREP_found=false - # Loop through the user's path and test for each of PROGNAME-LIST + cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ +$ac_includes_default +int +main () +{ +#ifndef __SUNPRO_C + (void) __SUNPRO_C; +#endif + + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext +if { (ac_try="$ac_compile" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" +$as_echo "$ac_try_echo") >&5 + (eval "$ac_compile") 2>conftest.er1 + ac_status=$? + grep -v '^ *+' conftest.er1 >conftest.err + rm -f conftest.er1 + cat conftest.err >&5 + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && { + test -z "$ac_c_werror_flag" || + test ! -s conftest.err + } && test -s conftest.$ac_objext; then + ac_cv_have_decl___SUNPRO_C=yes +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_cv_have_decl___SUNPRO_C=no +fi + +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +{ $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl___SUNPRO_C" >&5 +$as_echo "$ac_cv_have_decl___SUNPRO_C" >&6; } +if test $ac_cv_have_decl___SUNPRO_C = yes; then + SUNCC="yes" +else + SUNCC="no" +fi + + if test "x$SUNCC" = "xyes"; then + CWARNFLAGS="-v" + fi +fi + + + +# If the module's configure.ac calls AC_PROG_CC later on, CC gets set to C89 + + + +# Check whether --enable-strict-compilation was given. +if test "${enable_strict_compilation+set}" = set; then + enableval=$enable_strict_compilation; STRICT_COMPILE=$enableval +else + STRICT_COMPILE=no +fi + +if test "x$STRICT_COMPILE" = "xyes"; then + { $as_echo "$as_me:$LINENO: checking whether __SUNPRO_C is declared" >&5 +$as_echo_n "checking whether __SUNPRO_C is declared... " >&6; } +if test "${ac_cv_have_decl___SUNPRO_C+set}" = set; then + $as_echo_n "(cached) " >&6 +else + cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ +$ac_includes_default +int +main () +{ +#ifndef __SUNPRO_C + (void) __SUNPRO_C; +#endif + + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext +if { (ac_try="$ac_compile" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" +$as_echo "$ac_try_echo") >&5 + (eval "$ac_compile") 2>conftest.er1 + ac_status=$? + grep -v '^ *+' conftest.er1 >conftest.err + rm -f conftest.er1 + cat conftest.err >&5 + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && { + test -z "$ac_c_werror_flag" || + test ! -s conftest.err + } && test -s conftest.$ac_objext; then + ac_cv_have_decl___SUNPRO_C=yes +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_cv_have_decl___SUNPRO_C=no +fi + +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +{ $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl___SUNPRO_C" >&5 +$as_echo "$ac_cv_have_decl___SUNPRO_C" >&6; } +if test $ac_cv_have_decl___SUNPRO_C = yes; then + SUNCC="yes" +else + SUNCC="no" +fi + + { $as_echo "$as_me:$LINENO: checking whether __INTEL_COMPILER is declared" >&5 +$as_echo_n "checking whether __INTEL_COMPILER is declared... " >&6; } +if test "${ac_cv_have_decl___INTEL_COMPILER+set}" = set; then + $as_echo_n "(cached) " >&6 +else + cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ +$ac_includes_default +int +main () +{ +#ifndef __INTEL_COMPILER + (void) __INTEL_COMPILER; +#endif + + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext +if { (ac_try="$ac_compile" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" +$as_echo "$ac_try_echo") >&5 + (eval "$ac_compile") 2>conftest.er1 + ac_status=$? + grep -v '^ *+' conftest.er1 >conftest.err + rm -f conftest.er1 + cat conftest.err >&5 + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && { + test -z "$ac_c_werror_flag" || + test ! -s conftest.err + } && test -s conftest.$ac_objext; then + ac_cv_have_decl___INTEL_COMPILER=yes +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_cv_have_decl___INTEL_COMPILER=no +fi + +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +{ $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl___INTEL_COMPILER" >&5 +$as_echo "$ac_cv_have_decl___INTEL_COMPILER" >&6; } +if test $ac_cv_have_decl___INTEL_COMPILER = yes; then + INTELCC="yes" +else + INTELCC="no" +fi + + if test "x$GCC" = xyes ; then + STRICT_CFLAGS="-pedantic -Werror" + elif test "x$SUNCC" = "xyes"; then + STRICT_CFLAGS="-errwarn" + elif test "x$INTELCC" = "xyes"; then + STRICT_CFLAGS="-Werror" + fi +fi +CWARNFLAGS="$CWARNFLAGS $STRICT_CFLAGS" + + + + +cat >>confdefs.h <<_ACEOF +#define PACKAGE_VERSION_MAJOR `echo $PACKAGE_VERSION | cut -d . -f 1` +_ACEOF + + PVM=`echo $PACKAGE_VERSION | cut -d . -f 2 | cut -d - -f 1` + if test "x$PVM" = "x"; then + PVM="0" + fi + +cat >>confdefs.h <<_ACEOF +#define PACKAGE_VERSION_MINOR $PVM +_ACEOF + + PVP=`echo $PACKAGE_VERSION | cut -d . -f 3 | cut -d - -f 1` + if test "x$PVP" = "x"; then + PVP="0" + fi + +cat >>confdefs.h <<_ACEOF +#define PACKAGE_VERSION_PATCHLEVEL $PVP +_ACEOF + + + +CHANGELOG_CMD="(GIT_DIR=\$(top_srcdir)/.git git log > \$(top_srcdir)/.changelog.tmp && \ +mv \$(top_srcdir)/.changelog.tmp \$(top_srcdir)/ChangeLog) \ +|| (rm -f \$(top_srcdir)/.changelog.tmp; touch \$(top_srcdir)/ChangeLog; \ +echo 'git directory not found: installing possibly empty changelog.' >&2)" + + + + +macros_datadir=`$PKG_CONFIG --print-errors --variable=pkgdatadir xorg-macros` +INSTALL_CMD="(cp -f "$macros_datadir/INSTALL" \$(top_srcdir)/.INSTALL.tmp && \ +mv \$(top_srcdir)/.INSTALL.tmp \$(top_srcdir)/INSTALL) \ +|| (rm -f \$(top_srcdir)/.INSTALL.tmp; touch \$(top_srcdir)/INSTALL; \ +echo 'util-macros \"pkgdatadir\" from xorg-macros.pc not found: installing possibly empty INSTALL.' >&2)" + + + + + + +if test x$APP_MAN_SUFFIX = x ; then + APP_MAN_SUFFIX=1 +fi +if test x$APP_MAN_DIR = x ; then + APP_MAN_DIR='$(mandir)/man$(APP_MAN_SUFFIX)' +fi + +if test x$LIB_MAN_SUFFIX = x ; then + LIB_MAN_SUFFIX=3 +fi +if test x$LIB_MAN_DIR = x ; then + LIB_MAN_DIR='$(mandir)/man$(LIB_MAN_SUFFIX)' +fi + +if test x$FILE_MAN_SUFFIX = x ; then + case $host_os in + solaris*) FILE_MAN_SUFFIX=4 ;; + *) FILE_MAN_SUFFIX=5 ;; + esac +fi +if test x$FILE_MAN_DIR = x ; then + FILE_MAN_DIR='$(mandir)/man$(FILE_MAN_SUFFIX)' +fi + +if test x$MISC_MAN_SUFFIX = x ; then + case $host_os in + solaris*) MISC_MAN_SUFFIX=5 ;; + *) MISC_MAN_SUFFIX=7 ;; + esac +fi +if test x$MISC_MAN_DIR = x ; then + MISC_MAN_DIR='$(mandir)/man$(MISC_MAN_SUFFIX)' +fi + +if test x$DRIVER_MAN_SUFFIX = x ; then + case $host_os in + solaris*) DRIVER_MAN_SUFFIX=7 ;; + *) DRIVER_MAN_SUFFIX=4 ;; + esac +fi +if test x$DRIVER_MAN_DIR = x ; then + DRIVER_MAN_DIR='$(mandir)/man$(DRIVER_MAN_SUFFIX)' +fi + +if test x$ADMIN_MAN_SUFFIX = x ; then + case $host_os in + solaris*) ADMIN_MAN_SUFFIX=1m ;; + *) ADMIN_MAN_SUFFIX=8 ;; + esac +fi +if test x$ADMIN_MAN_DIR = x ; then + ADMIN_MAN_DIR='$(mandir)/man$(ADMIN_MAN_SUFFIX)' +fi + + + + + + + + + + + + + + + +XORG_MAN_PAGE="X Version 11" + +MAN_SUBSTS="\ + -e 's|__vendorversion__|\"\$(PACKAGE_STRING)\" \"\$(XORG_MAN_PAGE)\"|' \ + -e 's|__xorgversion__|\"\$(PACKAGE_STRING)\" \"\$(XORG_MAN_PAGE)\"|' \ + -e 's|__xservername__|Xorg|g' \ + -e 's|__xconfigfile__|xorg.conf|g' \ + -e 's|__projectroot__|\$(prefix)|g' \ + -e 's|__apploaddir__|\$(appdefaultdir)|g' \ + -e 's|__appmansuffix__|\$(APP_MAN_SUFFIX)|g' \ + -e 's|__drivermansuffix__|\$(DRIVER_MAN_SUFFIX)|g' \ + -e 's|__adminmansuffix__|\$(ADMIN_MAN_SUFFIX)|g' \ + -e 's|__libmansuffix__|\$(LIB_MAN_SUFFIX)|g' \ + -e 's|__miscmansuffix__|\$(MISC_MAN_SUFFIX)|g' \ + -e 's|__filemansuffix__|\$(FILE_MAN_SUFFIX)|g'" + + + +AM_DEFAULT_VERBOSITY=1 + + + + +# Check whether --enable-docs was given. +if test "${enable_docs+set}" = set; then + enableval=$enable_docs; build_docs=$enableval +else + build_docs=yes +fi + + + + +if test x$build_docs = xyes; then + ENABLE_DOCS_TRUE= + ENABLE_DOCS_FALSE='#' +else + ENABLE_DOCS_TRUE='#' + ENABLE_DOCS_FALSE= +fi + +{ $as_echo "$as_me:$LINENO: checking whether to build documentation" >&5 +$as_echo_n "checking whether to build documentation... " >&6; } +{ $as_echo "$as_me:$LINENO: result: $build_docs" >&5 +$as_echo "$build_docs" >&6; } + + + + + +# Check whether --with-xmlto was given. +if test "${with_xmlto+set}" = set; then + withval=$with_xmlto; use_xmlto=$withval +else + use_xmlto=auto +fi + + + +if test "x$use_xmlto" = x"auto"; then + # Extract the first word of "xmlto", so it can be a program name with args. +set dummy xmlto; ac_word=$2 +{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if test "${ac_cv_path_XMLTO+set}" = set; then + $as_echo_n "(cached) " >&6 +else + case $XMLTO in + [\\/]* | ?:[\\/]*) + ac_cv_path_XMLTO="$XMLTO" # Let the user override the test with a path. + ;; + *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin +for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. - for ac_prog in egrep; do - for ac_exec_ext in '' $ac_executable_extensions; do - ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" - { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue -# Check for GNU ac_path_EGREP and select it if it is found. - # Check for GNU $ac_path_EGREP -case `"$ac_path_EGREP" --version 2>&1` in -*GNU*) - ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; -*) - ac_count=0 - $as_echo_n 0123456789 >"conftest.in" - while : - do - cat "conftest.in" "conftest.in" >"conftest.tmp" - mv "conftest.tmp" "conftest.in" - cp "conftest.in" "conftest.nl" - $as_echo 'EGREP' >> "conftest.nl" - "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break - diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break - ac_count=`expr $ac_count + 1` - if test $ac_count -gt ${ac_path_EGREP_max-0}; then - # Best one so far, save it but keep looking for a better one - ac_cv_path_EGREP="$ac_path_EGREP" - ac_path_EGREP_max=$ac_count - fi - # 10*(2^10) chars as input seems more than enough - test $ac_count -gt 10 && break - done - rm -f conftest.in conftest.tmp conftest.nl conftest.out;; + for ac_exec_ext in '' $ac_executable_extensions; do + if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + ac_cv_path_XMLTO="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done +done +IFS=$as_save_IFS + + ;; esac +fi +XMLTO=$ac_cv_path_XMLTO +if test -n "$XMLTO"; then + { $as_echo "$as_me:$LINENO: result: $XMLTO" >&5 +$as_echo "$XMLTO" >&6; } +else + { $as_echo "$as_me:$LINENO: result: no" >&5 +$as_echo "no" >&6; } +fi - $ac_path_EGREP_found && break 3 - done - done + + if test "x$XMLTO" = "x"; then + { $as_echo "$as_me:$LINENO: WARNING: xmlto not found - documentation targets will be skipped" >&5 +$as_echo "$as_me: WARNING: xmlto not found - documentation targets will be skipped" >&2;} + have_xmlto=no + else + have_xmlto=yes + fi +elif test "x$use_xmlto" = x"yes" ; then + # Extract the first word of "xmlto", so it can be a program name with args. +set dummy xmlto; ac_word=$2 +{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if test "${ac_cv_path_XMLTO+set}" = set; then + $as_echo_n "(cached) " >&6 +else + case $XMLTO in + [\\/]* | ?:[\\/]*) + ac_cv_path_XMLTO="$XMLTO" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + ac_cv_path_XMLTO="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done done IFS=$as_save_IFS - if test -z "$ac_cv_path_EGREP"; then - { { $as_echo "$as_me:$LINENO: error: no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5 -$as_echo "$as_me: error: no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;} + + ;; +esac +fi +XMLTO=$ac_cv_path_XMLTO +if test -n "$XMLTO"; then + { $as_echo "$as_me:$LINENO: result: $XMLTO" >&5 +$as_echo "$XMLTO" >&6; } +else + { $as_echo "$as_me:$LINENO: result: no" >&5 +$as_echo "no" >&6; } +fi + + + if test "x$XMLTO" = "x"; then + { { $as_echo "$as_me:$LINENO: error: --with-xmlto=yes specified but xmlto not found in PATH" >&5 +$as_echo "$as_me: error: --with-xmlto=yes specified but xmlto not found in PATH" >&2;} + { (exit 1); exit 1; }; } + fi + have_xmlto=yes +elif test "x$use_xmlto" = x"no" ; then + if test "x$XMLTO" != "x"; then + { $as_echo "$as_me:$LINENO: WARNING: ignoring XMLTO environment variable since --with-xmlto=no was specified" >&5 +$as_echo "$as_me: WARNING: ignoring XMLTO environment variable since --with-xmlto=no was specified" >&2;} + fi + have_xmlto=no +else + { { $as_echo "$as_me:$LINENO: error: --with-xmlto expects 'yes' or 'no'" >&5 +$as_echo "$as_me: error: --with-xmlto expects 'yes' or 'no'" >&2;} + { (exit 1); exit 1; }; } +fi + +# Test for a minimum version of xmlto, if provided. +if test "$have_xmlto" = yes; then + # scrape the xmlto version + { $as_echo "$as_me:$LINENO: checking the xmlto version" >&5 +$as_echo_n "checking the xmlto version... " >&6; } + xmlto_version=`$XMLTO --version 2>/dev/null | cut -d' ' -f3` + { $as_echo "$as_me:$LINENO: result: $xmlto_version" >&5 +$as_echo "$xmlto_version" >&6; } + as_arg_v1=$xmlto_version +as_arg_v2=0.0.20 +awk "$as_awk_strverscmp" v1="$as_arg_v1" v2="$as_arg_v2" /dev/null +case $? in +1) if test "x$use_xmlto" = xauto; then + { $as_echo "$as_me:$LINENO: WARNING: xmlto version $xmlto_version found, but 0.0.20 needed" >&5 +$as_echo "$as_me: WARNING: xmlto version $xmlto_version found, but 0.0.20 needed" >&2;} + have_xmlto=no + else + { { $as_echo "$as_me:$LINENO: error: xmlto version $xmlto_version found, but 0.0.20 needed" >&5 +$as_echo "$as_me: error: xmlto version $xmlto_version found, but 0.0.20 needed" >&2;} { (exit 1); exit 1; }; } + fi;; +0) ;; +2) ;; +esac +fi + +# Test for the ability of xmlto to generate a text target +have_xmlto_text=no +cat > conftest.xml << "EOF" +EOF +if test "$have_xmlto" = yes; then + if $XMLTO --skip-validation txt conftest.xml >/dev/null 2>&1; then + have_xmlto_text=yes +else + { $as_echo "$as_me:$LINENO: WARNING: xmlto cannot generate text format, this format skipped" >&5 +$as_echo "$as_me: WARNING: xmlto cannot generate text format, this format skipped" >&2;} +fi + +fi + +rm -f conftest.xml + + +if test $have_xmlto_text = yes; then + HAVE_XMLTO_TEXT_TRUE= + HAVE_XMLTO_TEXT_FALSE='#' +else + HAVE_XMLTO_TEXT_TRUE='#' + HAVE_XMLTO_TEXT_FALSE= +fi + + + +if test "$have_xmlto" = yes; then + HAVE_XMLTO_TRUE= + HAVE_XMLTO_FALSE='#' +else + HAVE_XMLTO_TRUE='#' + HAVE_XMLTO_FALSE= +fi + + + + + + +# Check whether --with-fop was given. +if test "${with_fop+set}" = set; then + withval=$with_fop; use_fop=$withval +else + use_fop=auto +fi + + + +if test "x$use_fop" = x"auto"; then + # Extract the first word of "fop", so it can be a program name with args. +set dummy fop; ac_word=$2 +{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if test "${ac_cv_path_FOP+set}" = set; then + $as_echo_n "(cached) " >&6 +else + case $FOP in + [\\/]* | ?:[\\/]*) + ac_cv_path_FOP="$FOP" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + ac_cv_path_FOP="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 fi +done +done +IFS=$as_save_IFS + + ;; +esac +fi +FOP=$ac_cv_path_FOP +if test -n "$FOP"; then + { $as_echo "$as_me:$LINENO: result: $FOP" >&5 +$as_echo "$FOP" >&6; } else - ac_cv_path_EGREP=$EGREP + { $as_echo "$as_me:$LINENO: result: no" >&5 +$as_echo "no" >&6; } fi + + if test "x$FOP" = "x"; then + { $as_echo "$as_me:$LINENO: WARNING: fop not found - documentation targets will be skipped" >&5 +$as_echo "$as_me: WARNING: fop not found - documentation targets will be skipped" >&2;} + have_fop=no + else + have_fop=yes fi +elif test "x$use_fop" = x"yes" ; then + # Extract the first word of "fop", so it can be a program name with args. +set dummy fop; ac_word=$2 +{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if test "${ac_cv_path_FOP+set}" = set; then + $as_echo_n "(cached) " >&6 +else + case $FOP in + [\\/]* | ?:[\\/]*) + ac_cv_path_FOP="$FOP" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + ac_cv_path_FOP="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done +done +IFS=$as_save_IFS + + ;; +esac fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_path_EGREP" >&5 -$as_echo "$ac_cv_path_EGREP" >&6; } - EGREP="$ac_cv_path_EGREP" +FOP=$ac_cv_path_FOP +if test -n "$FOP"; then + { $as_echo "$as_me:$LINENO: result: $FOP" >&5 +$as_echo "$FOP" >&6; } +else + { $as_echo "$as_me:$LINENO: result: no" >&5 +$as_echo "no" >&6; } +fi + + + if test "x$FOP" = "x"; then + { { $as_echo "$as_me:$LINENO: error: --with-fop=yes specified but fop not found in PATH" >&5 +$as_echo "$as_me: error: --with-fop=yes specified but fop not found in PATH" >&2;} + { (exit 1); exit 1; }; } + fi + have_fop=yes +elif test "x$use_fop" = x"no" ; then + if test "x$FOP" != "x"; then + { $as_echo "$as_me:$LINENO: WARNING: ignoring FOP environment variable since --with-fop=no was specified" >&5 +$as_echo "$as_me: WARNING: ignoring FOP environment variable since --with-fop=no was specified" >&2;} + fi + have_fop=no +else + { { $as_echo "$as_me:$LINENO: error: --with-fop expects 'yes' or 'no'" >&5 +$as_echo "$as_me: error: --with-fop expects 'yes' or 'no'" >&2;} + { (exit 1); exit 1; }; } +fi + + +if test "$have_fop" = yes; then + HAVE_FOP_TRUE= + HAVE_FOP_FALSE='#' +else + HAVE_FOP_TRUE='#' + HAVE_FOP_FALSE= +fi + + + +{ $as_echo "$as_me:$LINENO: checking for X.Org SGML entities >= 1.5" >&5 +$as_echo_n "checking for X.Org SGML entities >= 1.5... " >&6; } +XORG_SGML_PATH= +if test -n "$PKG_CONFIG" && \ + { ($as_echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \"xorg-sgml-doctools >= 1.5\"") >&5 + ($PKG_CONFIG --exists --print-errors "xorg-sgml-doctools >= 1.5") 2>&5 + ac_status=$? + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; then + XORG_SGML_PATH=`$PKG_CONFIG --variable=sgmlrootdir xorg-sgml-doctools` +else + : + +fi + +# Define variables STYLESHEET_SRCDIR and XSL_STYLESHEET containing +# the path and the name of the doc stylesheet +if test "x$XORG_SGML_PATH" != "x" ; then + { $as_echo "$as_me:$LINENO: result: $XORG_SGML_PATH" >&5 +$as_echo "$XORG_SGML_PATH" >&6; } + STYLESHEET_SRCDIR=$XORG_SGML_PATH/X11 + XSL_STYLESHEET=$STYLESHEET_SRCDIR/xorg.xsl +else + { $as_echo "$as_me:$LINENO: result: no" >&5 +$as_echo "no" >&6; } +fi + + + + + +if test "x$XSL_STYLESHEET" != "x"; then + HAVE_STYLESHEETS_TRUE= + HAVE_STYLESHEETS_FALSE='#' +else + HAVE_STYLESHEETS_TRUE='#' + HAVE_STYLESHEETS_FALSE= +fi + + + +{ $as_echo "$as_me:$LINENO: checking whether ln -s works" >&5 +$as_echo_n "checking whether ln -s works... " >&6; } +LN_S=$as_ln_s +if test "$LN_S" = "ln -s"; then + { $as_echo "$as_me:$LINENO: result: yes" >&5 +$as_echo "yes" >&6; } +else + { $as_echo "$as_me:$LINENO: result: no, using $LN_S" >&5 +$as_echo "no, using $LN_S" >&6; } +fi + + + +# Check whether --enable-shared was given. +if test "${enable_shared+set}" = set; then + enableval=$enable_shared; p=${PACKAGE-default} + case $enableval in + yes) enable_shared=yes ;; + no) enable_shared=no ;; + *) + enable_shared=no + # Look at the argument we got. We use all the common list separators. + lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," + for pkg in $enableval; do + IFS="$lt_save_ifs" + if test "X$pkg" = "X$p"; then + enable_shared=yes + fi + done + IFS="$lt_save_ifs" + ;; + esac +else + enable_shared=yes +fi + + +# Check whether --enable-static was given. +if test "${enable_static+set}" = set; then + enableval=$enable_static; p=${PACKAGE-default} + case $enableval in + yes) enable_static=yes ;; + no) enable_static=no ;; + *) + enable_static=no + # Look at the argument we got. We use all the common list separators. + lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," + for pkg in $enableval; do + IFS="$lt_save_ifs" + if test "X$pkg" = "X$p"; then + enable_static=yes + fi + done + IFS="$lt_save_ifs" + ;; + esac +else + enable_static=yes +fi + + +# Check whether --enable-fast-install was given. +if test "${enable_fast_install+set}" = set; then + enableval=$enable_fast_install; p=${PACKAGE-default} + case $enableval in + yes) enable_fast_install=yes ;; + no) enable_fast_install=no ;; + *) + enable_fast_install=no + # Look at the argument we got. We use all the common list separators. + lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," + for pkg in $enableval; do + IFS="$lt_save_ifs" + if test "X$pkg" = "X$p"; then + enable_fast_install=yes + fi + done + IFS="$lt_save_ifs" + ;; + esac +else + enable_fast_install=yes +fi + + +{ $as_echo "$as_me:$LINENO: checking for a sed that does not truncate output" >&5 +$as_echo_n "checking for a sed that does not truncate output... " >&6; } +if test "${lt_cv_path_SED+set}" = set; then + $as_echo_n "(cached) " >&6 +else + # Loop through the user's path and test for sed and gsed. +# Then use that list of sed's as ones to test for truncation. +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for lt_ac_prog in sed gsed; do + for ac_exec_ext in '' $ac_executable_extensions; do + if { test -f "$as_dir/$lt_ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$lt_ac_prog$ac_exec_ext"; }; then + lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext" + fi + done + done +done +IFS=$as_save_IFS +lt_ac_max=0 +lt_ac_count=0 +# Add /usr/xpg4/bin/sed as it is typically found on Solaris +# along with /bin/sed that truncates output. +for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do + test ! -f $lt_ac_sed && continue + cat /dev/null > conftest.in + lt_ac_count=0 + echo $ECHO_N "0123456789$ECHO_C" >conftest.in + # Check for GNU sed and select it if it is found. + if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then + lt_cv_path_SED=$lt_ac_sed + break + fi + while true; do + cat conftest.in conftest.in >conftest.tmp + mv conftest.tmp conftest.in + cp conftest.in conftest.nl + echo >>conftest.nl + $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break + cmp -s conftest.out conftest.nl || break + # 10000 chars as input seems more than enough + test $lt_ac_count -gt 10 && break + lt_ac_count=`expr $lt_ac_count + 1` + if test $lt_ac_count -gt $lt_ac_max; then + lt_ac_max=$lt_ac_count + lt_cv_path_SED=$lt_ac_sed + fi + done +done + +fi + +SED=$lt_cv_path_SED + +{ $as_echo "$as_me:$LINENO: result: $SED" >&5 +$as_echo "$SED" >&6; } # Check whether --with-gnu-ld was given. @@ -4502,7 +6112,6 @@ LTCFLAGS=${LTCFLAGS-"$CFLAGS"} # Allow CC to be a program name with arguments. compiler=$CC - # Check whether --enable-libtool-lock was given. if test "${enable_libtool_lock+set}" = set; then enableval=$enable_libtool_lock; @@ -4534,7 +6143,7 @@ ia64-*-hpux*) ;; *-*-irix6*) # Find out which ABI we are using. - echo '#line 4537 "configure"' > conftest.$ac_ext + echo '#line 6146 "configure"' > conftest.$ac_ext if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? @@ -5018,491 +6627,6 @@ esac need_locks="$enable_libtool_lock" -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu -{ $as_echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5 -$as_echo_n "checking how to run the C preprocessor... " >&6; } -# On Suns, sometimes $CPP names a directory. -if test -n "$CPP" && test -d "$CPP"; then - CPP= -fi -if test -z "$CPP"; then - if test "${ac_cv_prog_CPP+set}" = set; then - $as_echo_n "(cached) " >&6 -else - # Double quotes because CPP needs to be expanded - for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" - do - ac_preproc_ok=false -for ac_c_preproc_warn_flag in '' yes -do - # Use a header file that comes with gcc, so configuring glibc - # with a fresh cross-compiler works. - # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since - # <limits.h> exists even on freestanding compilers. - # On the NeXT, cc -E runs the code through the compiler's parser, - # not just through cpp. "Syntax error" is here to catch this case. - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#ifdef __STDC__ -# include <limits.h> -#else -# include <assert.h> -#endif - Syntax error -_ACEOF -if { (ac_try="$ac_cpp conftest.$ac_ext" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } >/dev/null && { - test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || - test ! -s conftest.err - }; then - : -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - # Broken: fails on valid input. -continue -fi - -rm -f conftest.err conftest.$ac_ext - - # OK, works on sane cases. Now check whether nonexistent headers - # can be detected and how. - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include <ac_nonexistent.h> -_ACEOF -if { (ac_try="$ac_cpp conftest.$ac_ext" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } >/dev/null && { - test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || - test ! -s conftest.err - }; then - # Broken: success on invalid input. -continue -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - # Passes both tests. -ac_preproc_ok=: -break -fi - -rm -f conftest.err conftest.$ac_ext - -done -# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. -rm -f conftest.err conftest.$ac_ext -if $ac_preproc_ok; then - break -fi - - done - ac_cv_prog_CPP=$CPP - -fi - CPP=$ac_cv_prog_CPP -else - ac_cv_prog_CPP=$CPP -fi -{ $as_echo "$as_me:$LINENO: result: $CPP" >&5 -$as_echo "$CPP" >&6; } -ac_preproc_ok=false -for ac_c_preproc_warn_flag in '' yes -do - # Use a header file that comes with gcc, so configuring glibc - # with a fresh cross-compiler works. - # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since - # <limits.h> exists even on freestanding compilers. - # On the NeXT, cc -E runs the code through the compiler's parser, - # not just through cpp. "Syntax error" is here to catch this case. - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#ifdef __STDC__ -# include <limits.h> -#else -# include <assert.h> -#endif - Syntax error -_ACEOF -if { (ac_try="$ac_cpp conftest.$ac_ext" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } >/dev/null && { - test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || - test ! -s conftest.err - }; then - : -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - # Broken: fails on valid input. -continue -fi - -rm -f conftest.err conftest.$ac_ext - - # OK, works on sane cases. Now check whether nonexistent headers - # can be detected and how. - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include <ac_nonexistent.h> -_ACEOF -if { (ac_try="$ac_cpp conftest.$ac_ext" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } >/dev/null && { - test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || - test ! -s conftest.err - }; then - # Broken: success on invalid input. -continue -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - # Passes both tests. -ac_preproc_ok=: -break -fi - -rm -f conftest.err conftest.$ac_ext - -done -# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. -rm -f conftest.err conftest.$ac_ext -if $ac_preproc_ok; then - : -else - { { $as_echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check -See \`config.log' for more details." >&5 -$as_echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check -See \`config.log' for more details." >&2;} - { (exit 1); exit 1; }; } -fi - -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu - - -{ $as_echo "$as_me:$LINENO: checking for ANSI C header files" >&5 -$as_echo_n "checking for ANSI C header files... " >&6; } -if test "${ac_cv_header_stdc+set}" = set; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include <stdlib.h> -#include <stdarg.h> -#include <string.h> -#include <float.h> - -int -main () -{ - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_header_stdc=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_header_stdc=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - -if test $ac_cv_header_stdc = yes; then - # SunOS 4.x string.h does not declare mem*, contrary to ANSI. - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include <string.h> - -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "memchr" >/dev/null 2>&1; then - : -else - ac_cv_header_stdc=no -fi -rm -f conftest* - -fi - -if test $ac_cv_header_stdc = yes; then - # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include <stdlib.h> - -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "free" >/dev/null 2>&1; then - : -else - ac_cv_header_stdc=no -fi -rm -f conftest* - -fi - -if test $ac_cv_header_stdc = yes; then - # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. - if test "$cross_compiling" = yes; then - : -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include <ctype.h> -#include <stdlib.h> -#if ((' ' & 0x0FF) == 0x020) -# define ISLOWER(c) ('a' <= (c) && (c) <= 'z') -# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) -#else -# define ISLOWER(c) \ - (('a' <= (c) && (c) <= 'i') \ - || ('j' <= (c) && (c) <= 'r') \ - || ('s' <= (c) && (c) <= 'z')) -# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) -#endif - -#define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) -int -main () -{ - int i; - for (i = 0; i < 256; i++) - if (XOR (islower (i), ISLOWER (i)) - || toupper (i) != TOUPPER (i)) - return 2; - return 0; -} -_ACEOF -rm -f conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { ac_try='./conftest$ac_exeext' - { (case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - : -else - $as_echo "$as_me: program exited with status $ac_status" >&5 -$as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -ac_cv_header_stdc=no -fi -rm -rf conftest.dSYM -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext -fi - - -fi -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5 -$as_echo "$ac_cv_header_stdc" >&6; } -if test $ac_cv_header_stdc = yes; then - -cat >>confdefs.h <<\_ACEOF -#define STDC_HEADERS 1 -_ACEOF - -fi - -# On IRIX 5.3, sys/types and inttypes.h are conflicting. - - - - - - - - - -for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \ - inttypes.h stdint.h unistd.h -do -as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_header" >&5 -$as_echo_n "checking for $ac_header... " >&6; } -if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - -#include <$ac_header> -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - eval "$as_ac_Header=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_Header=no" -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_Header'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -if test `eval 'as_val=${'$as_ac_Header'} - $as_echo "$as_val"'` = yes; then - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 -_ACEOF - -fi - -done - - for ac_header in dlfcn.h do @@ -7932,11 +9056,11 @@ else -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:7935: $lt_compile\"" >&5) + (eval echo "\"\$as_me:9059: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 - echo "$as_me:7939: \$? = $ac_status" >&5 + echo "$as_me:9063: \$? = $ac_status" >&5 if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. @@ -8222,11 +9346,11 @@ else -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:8225: $lt_compile\"" >&5) + (eval echo "\"\$as_me:9349: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 - echo "$as_me:8229: \$? = $ac_status" >&5 + echo "$as_me:9353: \$? = $ac_status" >&5 if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. @@ -8326,11 +9450,11 @@ else -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:8329: $lt_compile\"" >&5) + (eval echo "\"\$as_me:9453: $lt_compile\"" >&5) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&5 - echo "$as_me:8333: \$? = $ac_status" >&5 + echo "$as_me:9457: \$? = $ac_status" >&5 if (exit $ac_status) && test -s out/conftest2.$ac_objext then # The compiler can only warn and ignore the option if not recognized @@ -10726,7 +11850,7 @@ else lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 lt_status=$lt_dlunknown cat > conftest.$ac_ext <<EOF -#line 10729 "configure" +#line 11853 "configure" #include "confdefs.h" #if HAVE_DLFCN_H @@ -10826,7 +11950,7 @@ else lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 lt_status=$lt_dlunknown cat > conftest.$ac_ext <<EOF -#line 10829 "configure" +#line 11953 "configure" #include "confdefs.h" #if HAVE_DLFCN_H @@ -13235,11 +14359,11 @@ else -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:13238: $lt_compile\"" >&5) + (eval echo "\"\$as_me:14362: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 - echo "$as_me:13242: \$? = $ac_status" >&5 + echo "$as_me:14366: \$? = $ac_status" >&5 if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. @@ -13339,11 +14463,11 @@ else -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:13342: $lt_compile\"" >&5) + (eval echo "\"\$as_me:14466: $lt_compile\"" >&5) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&5 - echo "$as_me:13346: \$? = $ac_status" >&5 + echo "$as_me:14470: \$? = $ac_status" >&5 if (exit $ac_status) && test -s out/conftest2.$ac_objext then # The compiler can only warn and ignore the option if not recognized @@ -14922,11 +16046,11 @@ else -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:14925: $lt_compile\"" >&5) + (eval echo "\"\$as_me:16049: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 - echo "$as_me:14929: \$? = $ac_status" >&5 + echo "$as_me:16053: \$? = $ac_status" >&5 if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. @@ -15026,11 +16150,11 @@ else -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:15029: $lt_compile\"" >&5) + (eval echo "\"\$as_me:16153: $lt_compile\"" >&5) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&5 - echo "$as_me:15033: \$? = $ac_status" >&5 + echo "$as_me:16157: \$? = $ac_status" >&5 if (exit $ac_status) && test -s out/conftest2.$ac_objext then # The compiler can only warn and ignore the option if not recognized @@ -17241,11 +18365,11 @@ else -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:17244: $lt_compile\"" >&5) + (eval echo "\"\$as_me:18368: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 - echo "$as_me:17248: \$? = $ac_status" >&5 + echo "$as_me:18372: \$? = $ac_status" >&5 if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. @@ -17531,11 +18655,11 @@ else -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:17534: $lt_compile\"" >&5) + (eval echo "\"\$as_me:18658: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 - echo "$as_me:17538: \$? = $ac_status" >&5 + echo "$as_me:18662: \$? = $ac_status" >&5 if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. @@ -17635,11 +18759,11 @@ else -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:17638: $lt_compile\"" >&5) + (eval echo "\"\$as_me:18762: $lt_compile\"" >&5) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&5 - echo "$as_me:17642: \$? = $ac_status" >&5 + echo "$as_me:18766: \$? = $ac_status" >&5 if (exit $ac_status) && test -s out/conftest2.$ac_objext then # The compiler can only warn and ignore the option if not recognized @@ -20543,126 +21667,6 @@ fi - -if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then - if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args. -set dummy ${ac_tool_prefix}pkg-config; ac_word=$2 -{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_path_PKG_CONFIG+set}" = set; then - $as_echo_n "(cached) " >&6 -else - case $PKG_CONFIG in - [\\/]* | ?:[\\/]*) - ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path. - ;; - *) - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" - $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done -done -IFS=$as_save_IFS - - ;; -esac -fi -PKG_CONFIG=$ac_cv_path_PKG_CONFIG -if test -n "$PKG_CONFIG"; then - { $as_echo "$as_me:$LINENO: result: $PKG_CONFIG" >&5 -$as_echo "$PKG_CONFIG" >&6; } -else - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$ac_cv_path_PKG_CONFIG"; then - ac_pt_PKG_CONFIG=$PKG_CONFIG - # Extract the first word of "pkg-config", so it can be a program name with args. -set dummy pkg-config; ac_word=$2 -{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_path_ac_pt_PKG_CONFIG+set}" = set; then - $as_echo_n "(cached) " >&6 -else - case $ac_pt_PKG_CONFIG in - [\\/]* | ?:[\\/]*) - ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path. - ;; - *) - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" - $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done -done -IFS=$as_save_IFS - - ;; -esac -fi -ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG -if test -n "$ac_pt_PKG_CONFIG"; then - { $as_echo "$as_me:$LINENO: result: $ac_pt_PKG_CONFIG" >&5 -$as_echo "$ac_pt_PKG_CONFIG" >&6; } -else - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } -fi - - if test "x$ac_pt_PKG_CONFIG" = x; then - PKG_CONFIG="" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools -whose name does not start with the host triplet. If you think this -configuration is useful to you, please write to autoconf@gnu.org." >&5 -$as_echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools -whose name does not start with the host triplet. If you think this -configuration is useful to you, please write to autoconf@gnu.org." >&2;} -ac_tool_warned=yes ;; -esac - PKG_CONFIG=$ac_pt_PKG_CONFIG - fi -else - PKG_CONFIG="$ac_cv_path_PKG_CONFIG" -fi - -fi -if test -n "$PKG_CONFIG"; then - _pkg_min_version=0.9.0 - { $as_echo "$as_me:$LINENO: checking pkg-config is at least version $_pkg_min_version" >&5 -$as_echo_n "checking pkg-config is at least version $_pkg_min_version... " >&6; } - if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then - { $as_echo "$as_me:$LINENO: result: yes" >&5 -$as_echo "yes" >&6; } - else - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } - PKG_CONFIG="" - fi - -fi - pkg_failed=no { $as_echo "$as_me:$LINENO: checking for XDMCP" >&5 $as_echo_n "checking for XDMCP... " >&6; } @@ -20773,551 +21777,6 @@ else $as_echo "yes" >&6; } : fi - { $as_echo "$as_me:$LINENO: checking for $CC option to accept ISO C99" >&5 -$as_echo_n "checking for $CC option to accept ISO C99... " >&6; } -if test "${ac_cv_prog_cc_c99+set}" = set; then - $as_echo_n "(cached) " >&6 -else - ac_cv_prog_cc_c99=no -ac_save_CC=$CC -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include <stdarg.h> -#include <stdbool.h> -#include <stdlib.h> -#include <wchar.h> -#include <stdio.h> - -// Check varargs macros. These examples are taken from C99 6.10.3.5. -#define debug(...) fprintf (stderr, __VA_ARGS__) -#define showlist(...) puts (#__VA_ARGS__) -#define report(test,...) ((test) ? puts (#test) : printf (__VA_ARGS__)) -static void -test_varargs_macros (void) -{ - int x = 1234; - int y = 5678; - debug ("Flag"); - debug ("X = %d\n", x); - showlist (The first, second, and third items.); - report (x>y, "x is %d but y is %d", x, y); -} - -// Check long long types. -#define BIG64 18446744073709551615ull -#define BIG32 4294967295ul -#define BIG_OK (BIG64 / BIG32 == 4294967297ull && BIG64 % BIG32 == 0) -#if !BIG_OK - your preprocessor is broken; -#endif -#if BIG_OK -#else - your preprocessor is broken; -#endif -static long long int bignum = -9223372036854775807LL; -static unsigned long long int ubignum = BIG64; - -struct incomplete_array -{ - int datasize; - double data[]; -}; - -struct named_init { - int number; - const wchar_t *name; - double average; -}; - -typedef const char *ccp; - -static inline int -test_restrict (ccp restrict text) -{ - // See if C++-style comments work. - // Iterate through items via the restricted pointer. - // Also check for declarations in for loops. - for (unsigned int i = 0; *(text+i) != '\0'; ++i) - continue; - return 0; -} - -// Check varargs and va_copy. -static void -test_varargs (const char *format, ...) -{ - va_list args; - va_start (args, format); - va_list args_copy; - va_copy (args_copy, args); - - const char *str; - int number; - float fnumber; - - while (*format) - { - switch (*format++) - { - case 's': // string - str = va_arg (args_copy, const char *); - break; - case 'd': // int - number = va_arg (args_copy, int); - break; - case 'f': // float - fnumber = va_arg (args_copy, double); - break; - default: - break; - } - } - va_end (args_copy); - va_end (args); -} - -int -main () -{ - - // Check bool. - _Bool success = false; - - // Check restrict. - if (test_restrict ("String literal") == 0) - success = true; - char *restrict newvar = "Another string"; - - // Check varargs. - test_varargs ("s, d' f .", "string", 65, 34.234); - test_varargs_macros (); - - // Check flexible array members. - struct incomplete_array *ia = - malloc (sizeof (struct incomplete_array) + (sizeof (double) * 10)); - ia->datasize = 10; - for (int i = 0; i < ia->datasize; ++i) - ia->data[i] = i * 1.234; - - // Check named initializers. - struct named_init ni = { - .number = 34, - .name = L"Test wide string", - .average = 543.34343, - }; - - ni.number = 58; - - int dynamic_array[ni.number]; - dynamic_array[ni.number - 1] = 543; - - // work around unused variable warnings - return (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == 'x' - || dynamic_array[ni.number - 1] != 543); - - ; - return 0; -} -_ACEOF -for ac_arg in '' -std=gnu99 -std=c99 -c99 -AC99 -xc99=all -qlanglvl=extc99 -do - CC="$ac_save_CC $ac_arg" - rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_prog_cc_c99=$ac_arg -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - -fi - -rm -f core conftest.err conftest.$ac_objext - test "x$ac_cv_prog_cc_c99" != "xno" && break -done -rm -f conftest.$ac_ext -CC=$ac_save_CC - -fi -# AC_CACHE_VAL -case "x$ac_cv_prog_cc_c99" in - x) - { $as_echo "$as_me:$LINENO: result: none needed" >&5 -$as_echo "none needed" >&6; } ;; - xno) - { $as_echo "$as_me:$LINENO: result: unsupported" >&5 -$as_echo "unsupported" >&6; } ;; - *) - CC="$CC $ac_cv_prog_cc_c99" - { $as_echo "$as_me:$LINENO: result: $ac_cv_prog_cc_c99" >&5 -$as_echo "$ac_cv_prog_cc_c99" >&6; } ;; -esac - - - - - - -if test "x$GCC" = xyes ; then - CWARNFLAGS="-Wall -Wpointer-arith -Wstrict-prototypes -Wmissing-prototypes \ --Wmissing-declarations -Wnested-externs -fno-strict-aliasing \ --Wbad-function-cast" - case `$CC -dumpversion` in - 3.4.* | 4.*) - CWARNFLAGS="$CWARNFLAGS -Wold-style-definition -Wdeclaration-after-statement" - ;; - esac -else - { $as_echo "$as_me:$LINENO: checking whether __SUNPRO_C is declared" >&5 -$as_echo_n "checking whether __SUNPRO_C is declared... " >&6; } -if test "${ac_cv_have_decl___SUNPRO_C+set}" = set; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -#ifndef __SUNPRO_C - (void) __SUNPRO_C; -#endif - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_have_decl___SUNPRO_C=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_have_decl___SUNPRO_C=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl___SUNPRO_C" >&5 -$as_echo "$ac_cv_have_decl___SUNPRO_C" >&6; } -if test $ac_cv_have_decl___SUNPRO_C = yes; then - SUNCC="yes" -else - SUNCC="no" -fi - - if test "x$SUNCC" = "xyes"; then - CWARNFLAGS="-v" - fi -fi - - - - - - - - -# Check whether --enable-strict-compilation was given. -if test "${enable_strict_compilation+set}" = set; then - enableval=$enable_strict_compilation; STRICT_COMPILE=$enableval -else - STRICT_COMPILE=no -fi - -if test "x$STRICT_COMPILE" = "xyes"; then - { $as_echo "$as_me:$LINENO: checking whether __SUNPRO_C is declared" >&5 -$as_echo_n "checking whether __SUNPRO_C is declared... " >&6; } -if test "${ac_cv_have_decl___SUNPRO_C+set}" = set; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -#ifndef __SUNPRO_C - (void) __SUNPRO_C; -#endif - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_have_decl___SUNPRO_C=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_have_decl___SUNPRO_C=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl___SUNPRO_C" >&5 -$as_echo "$ac_cv_have_decl___SUNPRO_C" >&6; } -if test $ac_cv_have_decl___SUNPRO_C = yes; then - SUNCC="yes" -else - SUNCC="no" -fi - - { $as_echo "$as_me:$LINENO: checking whether __INTEL_COMPILER is declared" >&5 -$as_echo_n "checking whether __INTEL_COMPILER is declared... " >&6; } -if test "${ac_cv_have_decl___INTEL_COMPILER+set}" = set; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -#ifndef __INTEL_COMPILER - (void) __INTEL_COMPILER; -#endif - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_have_decl___INTEL_COMPILER=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_have_decl___INTEL_COMPILER=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl___INTEL_COMPILER" >&5 -$as_echo "$ac_cv_have_decl___INTEL_COMPILER" >&6; } -if test $ac_cv_have_decl___INTEL_COMPILER = yes; then - INTELCC="yes" -else - INTELCC="no" -fi - - if test "x$GCC" = xyes ; then - STRICT_CFLAGS="-pedantic -Werror" - elif test "x$SUNCC" = "xyes"; then - STRICT_CFLAGS="-errwarn" - elif test "x$INTELCC" = "xyes"; then - STRICT_CFLAGS="-Werror" - fi -fi -CWARNFLAGS="$CWARNFLAGS $STRICT_CFLAGS" - - - - -# Check whether --with-release-version was given. -if test "${with_release_version+set}" = set; then - withval=$with_release_version; RELEASE_VERSION="$withval" -else - RELEASE_VERSION="" -fi - - if test "x$RELEASE_VERSION" != "x"; then - PACKAGE="$PACKAGE-$RELEASE_VERSION" - PACKAGE_TARNAME="$PACKAGE_TARNAME-$RELEASE_VERSION" - { $as_echo "$as_me:$LINENO: Building with package name set to $PACKAGE" >&5 -$as_echo "$as_me: Building with package name set to $PACKAGE" >&6;} - fi - -cat >>confdefs.h <<_ACEOF -#define PACKAGE_VERSION_MAJOR `echo $PACKAGE_VERSION | cut -d . -f 1` -_ACEOF - - PVM=`echo $PACKAGE_VERSION | cut -d . -f 2 | cut -d - -f 1` - if test "x$PVM" = "x"; then - PVM="0" - fi - -cat >>confdefs.h <<_ACEOF -#define PACKAGE_VERSION_MINOR $PVM -_ACEOF - - PVP=`echo $PACKAGE_VERSION | cut -d . -f 3 | cut -d - -f 1` - if test "x$PVP" = "x"; then - PVP="0" - fi - -cat >>confdefs.h <<_ACEOF -#define PACKAGE_VERSION_PATCHLEVEL $PVP -_ACEOF - - - -CHANGELOG_CMD="(GIT_DIR=\$(top_srcdir)/.git git log > .changelog.tmp && \ -mv .changelog.tmp ChangeLog) || (rm -f .changelog.tmp; touch ChangeLog; \ -echo 'git directory not found: installing possibly empty changelog.' >&2)" - -distcleancheck_listfiles='find . -type f ! -name ChangeLog -print' - - - - - -if test x$APP_MAN_SUFFIX = x ; then - APP_MAN_SUFFIX=1 -fi -if test x$APP_MAN_DIR = x ; then - APP_MAN_DIR='$(mandir)/man$(APP_MAN_SUFFIX)' -fi - -if test x$LIB_MAN_SUFFIX = x ; then - LIB_MAN_SUFFIX=3 -fi -if test x$LIB_MAN_DIR = x ; then - LIB_MAN_DIR='$(mandir)/man$(LIB_MAN_SUFFIX)' -fi - -if test x$FILE_MAN_SUFFIX = x ; then - case $host_os in - solaris*) FILE_MAN_SUFFIX=4 ;; - *) FILE_MAN_SUFFIX=5 ;; - esac -fi -if test x$FILE_MAN_DIR = x ; then - FILE_MAN_DIR='$(mandir)/man$(FILE_MAN_SUFFIX)' -fi - -if test x$MISC_MAN_SUFFIX = x ; then - case $host_os in - solaris*) MISC_MAN_SUFFIX=5 ;; - *) MISC_MAN_SUFFIX=7 ;; - esac -fi -if test x$MISC_MAN_DIR = x ; then - MISC_MAN_DIR='$(mandir)/man$(MISC_MAN_SUFFIX)' -fi - -if test x$DRIVER_MAN_SUFFIX = x ; then - case $host_os in - solaris*) DRIVER_MAN_SUFFIX=7 ;; - *) DRIVER_MAN_SUFFIX=4 ;; - esac -fi -if test x$DRIVER_MAN_DIR = x ; then - DRIVER_MAN_DIR='$(mandir)/man$(DRIVER_MAN_SUFFIX)' -fi - -if test x$ADMIN_MAN_SUFFIX = x ; then - case $host_os in - solaris*) ADMIN_MAN_SUFFIX=1m ;; - *) ADMIN_MAN_SUFFIX=8 ;; - esac -fi -if test x$ADMIN_MAN_DIR = x ; then - ADMIN_MAN_DIR='$(mandir)/man$(ADMIN_MAN_SUFFIX)' -fi - - - - - - - - - - - - - - - - -XDMCP_CFLAGS="$CWARNFLAGS $XDMCP_CFLAGS" - - if test -f ${srcdir}/Wraphelp.c; then @@ -21343,7 +21802,8 @@ fi -# Allow checking code with lint, sparse, etc. + + # Check whether --with-lint was given. if test "${with_lint+set}" = set; then @@ -21352,28 +21812,92 @@ else use_lint=no fi -if test "x$use_lint" = "xyes" ; then - LINT="lint" + +# Obtain platform specific info like program name and options +# The lint program on FreeBSD and NetBSD is different from the one on Solaris +case $host_os in + *linux* | *openbsd* | kfreebsd*-gnu | darwin* | cygwin*) + lint_name=splint + lint_options="-badflag" + ;; + *freebsd* | *netbsd*) + lint_name=lint + lint_options="-u -b" + ;; + *solaris*) + lint_name=lint + lint_options="-u -b -h -erroff=E_INDISTING_FROM_TRUNC2" + ;; +esac + +# Test for the presence of the program (either guessed by the code or spelled out by the user) +if test "x$use_lint" = x"yes" ; then + # Extract the first word of "$lint_name", so it can be a program name with args. +set dummy $lint_name; ac_word=$2 +{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if test "${ac_cv_path_LINT+set}" = set; then + $as_echo_n "(cached) " >&6 else - LINT="$use_lint" + case $LINT in + [\\/]* | ?:[\\/]*) + ac_cv_path_LINT="$LINT" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + ac_cv_path_LINT="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done +done +IFS=$as_save_IFS + + ;; +esac fi -if test "x$LINT_FLAGS" = "x" -a "x$LINT" != "xno" ; then - case $LINT in - lint|*/lint) - case $host_os in - solaris*) - LINT_FLAGS="-u -b -h -erroff=E_INDISTING_FROM_TRUNC2" - ;; - esac - ;; - esac +LINT=$ac_cv_path_LINT +if test -n "$LINT"; then + { $as_echo "$as_me:$LINENO: result: $LINT" >&5 +$as_echo "$LINT" >&6; } +else + { $as_echo "$as_me:$LINENO: result: no" >&5 +$as_echo "no" >&6; } +fi + + + if test "x$LINT" = "x"; then + { { $as_echo "$as_me:$LINENO: error: --with-lint=yes specified but lint-style tool not found in PATH" >&5 +$as_echo "$as_me: error: --with-lint=yes specified but lint-style tool not found in PATH" >&2;} + { (exit 1); exit 1; }; } + fi +elif test "x$use_lint" = x"no" ; then + if test "x$LINT" != "x"; then + { $as_echo "$as_me:$LINENO: WARNING: ignoring LINT environment variable since --with-lint=no was specified" >&5 +$as_echo "$as_me: WARNING: ignoring LINT environment variable since --with-lint=no was specified" >&2;} + fi +else + { { $as_echo "$as_me:$LINENO: error: --with-lint expects 'yes' or 'no'. Use LINT variable to specify path." >&5 +$as_echo "$as_me: error: --with-lint expects 'yes' or 'no'. Use LINT variable to specify path." >&2;} + { (exit 1); exit 1; }; } fi +# User supplied flags override default flags +if test "x$LINT_FLAGS" != "x"; then + lint_options=$LINT_FLAGS +fi +LINT_FLAGS=$lint_options -if test x$LINT != xno; then +if test "x$LINT" != x; then LINT_TRUE= LINT_FALSE='#' else @@ -21385,7 +21909,6 @@ fi -# Build lint "library" for more indepth checks of programs calling this library # Check whether --enable-lint-library was given. if test "${enable_lint_library+set}" = set; then enableval=$enable_lint_library; make_lint_lib=$enableval @@ -21393,21 +21916,23 @@ else make_lint_lib=no fi -if test "x$make_lint_lib" != "xno" ; then - if test "x$LINT" = "xno" ; then - { { $as_echo "$as_me:$LINENO: error: Cannot make lint library without --with-lint" >&5 + +if test "x$make_lint_lib" = x"yes" ; then + LINTLIB=llib-lXdmcp.ln + if test "x$LINT" = "x"; then + { { $as_echo "$as_me:$LINENO: error: Cannot make lint library without --with-lint" >&5 $as_echo "$as_me: error: Cannot make lint library without --with-lint" >&2;} { (exit 1); exit 1; }; } - fi - if test "x$make_lint_lib" = "xyes" ; then - LINTLIB=llib-lXdmcp.ln - else - LINTLIB=$make_lint_lib - fi + fi +elif test "x$make_lint_lib" != x"no" ; then + { { $as_echo "$as_me:$LINENO: error: --enable-lint-library expects 'yes' or 'no'." >&5 +$as_echo "$as_me: error: --enable-lint-library expects 'yes' or 'no'." >&2;} + { (exit 1); exit 1; }; } fi + if test x$make_lint_lib != xno; then MAKE_LINT_LIB_TRUE= MAKE_LINT_LIB_FALSE='#' @@ -21419,7 +21944,7 @@ fi -ac_config_files="$ac_config_files Makefile xdmcp.pc" +ac_config_files="$ac_config_files Makefile doc/Makefile xdmcp.pc" cat >confcache <<\_ACEOF # This file is a shell script that caches the results of configure @@ -21539,6 +22064,41 @@ $as_echo "$as_me: error: conditional \"am__fastdepCC\" was never defined. Usually this means the macro was only invoked conditionally." >&2;} { (exit 1); exit 1; }; } fi +if test -z "${ENABLE_DOCS_TRUE}" && test -z "${ENABLE_DOCS_FALSE}"; then + { { $as_echo "$as_me:$LINENO: error: conditional \"ENABLE_DOCS\" was never defined. +Usually this means the macro was only invoked conditionally." >&5 +$as_echo "$as_me: error: conditional \"ENABLE_DOCS\" was never defined. +Usually this means the macro was only invoked conditionally." >&2;} + { (exit 1); exit 1; }; } +fi +if test -z "${HAVE_XMLTO_TEXT_TRUE}" && test -z "${HAVE_XMLTO_TEXT_FALSE}"; then + { { $as_echo "$as_me:$LINENO: error: conditional \"HAVE_XMLTO_TEXT\" was never defined. +Usually this means the macro was only invoked conditionally." >&5 +$as_echo "$as_me: error: conditional \"HAVE_XMLTO_TEXT\" was never defined. +Usually this means the macro was only invoked conditionally." >&2;} + { (exit 1); exit 1; }; } +fi +if test -z "${HAVE_XMLTO_TRUE}" && test -z "${HAVE_XMLTO_FALSE}"; then + { { $as_echo "$as_me:$LINENO: error: conditional \"HAVE_XMLTO\" was never defined. +Usually this means the macro was only invoked conditionally." >&5 +$as_echo "$as_me: error: conditional \"HAVE_XMLTO\" was never defined. +Usually this means the macro was only invoked conditionally." >&2;} + { (exit 1); exit 1; }; } +fi +if test -z "${HAVE_FOP_TRUE}" && test -z "${HAVE_FOP_FALSE}"; then + { { $as_echo "$as_me:$LINENO: error: conditional \"HAVE_FOP\" was never defined. +Usually this means the macro was only invoked conditionally." >&5 +$as_echo "$as_me: error: conditional \"HAVE_FOP\" was never defined. +Usually this means the macro was only invoked conditionally." >&2;} + { (exit 1); exit 1; }; } +fi +if test -z "${HAVE_STYLESHEETS_TRUE}" && test -z "${HAVE_STYLESHEETS_FALSE}"; then + { { $as_echo "$as_me:$LINENO: error: conditional \"HAVE_STYLESHEETS\" was never defined. +Usually this means the macro was only invoked conditionally." >&5 +$as_echo "$as_me: error: conditional \"HAVE_STYLESHEETS\" was never defined. +Usually this means the macro was only invoked conditionally." >&2;} + { (exit 1); exit 1; }; } +fi if test -z "${am__fastdepCXX_TRUE}" && test -z "${am__fastdepCXX_FALSE}"; then { { $as_echo "$as_me:$LINENO: error: conditional \"am__fastdepCXX\" was never defined. Usually this means the macro was only invoked conditionally." >&5 @@ -21889,7 +22449,7 @@ exec 6>&1 # report actual input values of CONFIG_FILES etc. instead of their # values after options handling. ac_log=" -This file was extended by libXdmcp $as_me 1.0.3, which was +This file was extended by libXdmcp $as_me 1.1.0, which was generated by GNU Autoconf 2.62. Invocation command line was CONFIG_FILES = $CONFIG_FILES @@ -21942,7 +22502,7 @@ Report bugs to <bug-autoconf@gnu.org>." _ACEOF cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 ac_cs_version="\\ -libXdmcp config.status 1.0.3 +libXdmcp config.status 1.1.0 configured by $0, generated by GNU Autoconf 2.62, with options \\"`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\" @@ -22067,6 +22627,7 @@ do "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h" ;; "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;; "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;; + "doc/Makefile") CONFIG_FILES="$CONFIG_FILES doc/Makefile" ;; "xdmcp.pc") CONFIG_FILES="$CONFIG_FILES xdmcp.pc" ;; *) { { $as_echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5 diff --git a/lib/libXdmcp/configure.ac b/lib/libXdmcp/configure.ac index 4b548e9c2..5de378ab2 100644 --- a/lib/libXdmcp/configure.ac +++ b/lib/libXdmcp/configure.ac @@ -21,19 +21,24 @@ dnl PERFORMANCE OF THIS SOFTWARE. dnl dnl Process this file with autoconf to create configure. -AC_PREREQ([2.57]) -AC_INIT(libXdmcp, 1.0.3, [https://bugs.freedesktop.org/enter_bug.cgi?product=xorg],libXdmcp) -AM_INIT_AUTOMAKE([dist-bzip2]) +AC_PREREQ([2.60]) +AC_INIT([libXdmcp], [1.1.0], + [https://bugs.freedesktop.org/enter_bug.cgi?product=xorg], [libXdmcp]) +AM_INIT_AUTOMAKE([foreign dist-bzip2]) AM_MAINTAINER_MODE AM_CONFIG_HEADER(config.h) -# Require xorg-macros: XORG_WITH_LINT, XORG_CWARNFLAGS, XORG_CHANGELOG -m4_ifndef([XORG_MACROS_VERSION], [AC_FATAL([must install xorg-macros 1.3 or later before running autoconf/autogen])]) -XORG_MACROS_VERSION(1.3) +# Require xorg-macros minimum of 1.10 for HAVE_STYLESHEETS in XORG_CHECK_SGML_DOCTOOLS +m4_ifndef([XORG_MACROS_VERSION], + [m4_fatal([must install xorg-macros 1.10 or later before running autoconf/autogen])]) +XORG_MACROS_VERSION(1.10) +XORG_DEFAULT_OPTIONS +XORG_ENABLE_DOCS +XORG_WITH_XMLTO(0.0.20) +XORG_WITH_FOP +XORG_CHECK_SGML_DOCTOOLS(1.5) -AC_PROG_CC -AC_PROG_INSTALL AC_PROG_LN_S AC_LIBTOOL_WIN32_DLL AM_PROG_LIBTOOL @@ -44,10 +49,6 @@ AC_CHECK_FUNCS([srand48 lrand48]) AC_SEARCH_LIBS([recvfrom],[socket]) PKG_CHECK_MODULES(XDMCP, xproto) -XORG_DEFAULT_OPTIONS -XDMCP_CFLAGS="$CWARNFLAGS $XDMCP_CFLAGS" -AC_SUBST(XDMCP_CFLAGS) -AC_SUBST(XDMCP_LIBS) if test -f ${srcdir}/Wraphelp.c; then AC_DEFINE(HASXDMAUTH,1,[Has Wraphelp.c needed for XDM AUTH protocols]) @@ -63,4 +64,5 @@ XORG_WITH_LINT XORG_LINT_LIBRARY([Xdmcp]) AC_OUTPUT([Makefile + doc/Makefile xdmcp.pc]) diff --git a/lib/libXdmcp/doc/Makefile.am b/lib/libXdmcp/doc/Makefile.am new file mode 100644 index 000000000..c2aa67169 --- /dev/null +++ b/lib/libXdmcp/doc/Makefile.am @@ -0,0 +1,64 @@ +# +# Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved. +# +# Permission is hereby granted, free of charge, to any person obtaining a +# copy of this software and associated documentation files (the "Software"), +# to deal in the Software without restriction, including without limitation +# the rights to use, copy, modify, merge, publish, distribute, sublicense, +# and/or sell copies of the Software, and to permit persons to whom the +# Software is furnished to do so, subject to the following conditions: +# +# The above copyright notice and this permission notice (including the next +# paragraph) shall be included in all copies or substantial portions of the +# Software. +# +# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL +# THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING +# FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER +# DEALINGS IN THE SOFTWARE. +# + +if ENABLE_DOCS +doc_sources = xdmcp.xml +dist_doc_DATA = $(doc_sources) + +if HAVE_XMLTO +doc_DATA = $(doc_sources:.xml=.html) + +if HAVE_FOP +doc_DATA += $(doc_sources:.xml=.ps) $(doc_sources:.xml=.pdf) +endif + +if HAVE_XMLTO_TEXT +doc_DATA += $(doc_sources:.xml=.txt) +endif + +if HAVE_STYLESHEETS +XMLTO_FLAGS = -m $(XSL_STYLESHEET) + +doc_DATA += xorg.css +xorg.css: $(STYLESHEET_SRCDIR)/xorg.css + $(AM_V_GEN)cp -pf $(STYLESHEET_SRCDIR)/xorg.css $@ +endif + +CLEANFILES = $(doc_DATA) + +SUFFIXES = .xml .ps .pdf .txt .html + +.xml.txt: + $(AM_V_GEN)$(XMLTO) $(XMLTO_FLAGS) txt $< + +.xml.html: + $(AM_V_GEN)$(XMLTO) $(XMLTO_FLAGS) xhtml-nochunks $< + +.xml.pdf: + $(AM_V_GEN)$(XMLTO) $(XMLTO_FLAGS) --with-fop pdf $< + +.xml.ps: + $(AM_V_GEN)$(XMLTO) $(XMLTO_FLAGS) --with-fop ps $< + +endif HAVE_XMLTO +endif ENABLE_DOCS diff --git a/lib/libXdmcp/doc/Makefile.in b/lib/libXdmcp/doc/Makefile.in new file mode 100644 index 000000000..79c9b438a --- /dev/null +++ b/lib/libXdmcp/doc/Makefile.in @@ -0,0 +1,471 @@ +# Makefile.in generated by automake 1.9.6 from Makefile.am. +# @configure_input@ + +# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, +# 2003, 2004, 2005 Free Software Foundation, Inc. +# This Makefile.in is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY, to the extent permitted by law; without +# even the implied warranty of MERCHANTABILITY or FITNESS FOR A +# PARTICULAR PURPOSE. + +@SET_MAKE@ + +# +# Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved. +# +# Permission is hereby granted, free of charge, to any person obtaining a +# copy of this software and associated documentation files (the "Software"), +# to deal in the Software without restriction, including without limitation +# the rights to use, copy, modify, merge, publish, distribute, sublicense, +# and/or sell copies of the Software, and to permit persons to whom the +# Software is furnished to do so, subject to the following conditions: +# +# The above copyright notice and this permission notice (including the next +# paragraph) shall be included in all copies or substantial portions of the +# Software. +# +# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL +# THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING +# FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER +# DEALINGS IN THE SOFTWARE. +# + +srcdir = @srcdir@ +top_srcdir = @top_srcdir@ +VPATH = @srcdir@ +pkgdatadir = $(datadir)/@PACKAGE@ +pkglibdir = $(libdir)/@PACKAGE@ +pkgincludedir = $(includedir)/@PACKAGE@ +top_builddir = .. +am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd +INSTALL = @INSTALL@ +install_sh_DATA = $(install_sh) -c -m 644 +install_sh_PROGRAM = $(install_sh) -c +install_sh_SCRIPT = $(install_sh) -c +INSTALL_HEADER = $(INSTALL_DATA) +transform = $(program_transform_name) +NORMAL_INSTALL = : +PRE_INSTALL = : +POST_INSTALL = : +NORMAL_UNINSTALL = : +PRE_UNINSTALL = : +POST_UNINSTALL = : +build_triplet = @build@ +host_triplet = @host@ +@ENABLE_DOCS_TRUE@@HAVE_FOP_TRUE@@HAVE_XMLTO_TRUE@am__append_1 = $(doc_sources:.xml=.ps) $(doc_sources:.xml=.pdf) +@ENABLE_DOCS_TRUE@@HAVE_XMLTO_TEXT_TRUE@@HAVE_XMLTO_TRUE@am__append_2 = $(doc_sources:.xml=.txt) +@ENABLE_DOCS_TRUE@@HAVE_STYLESHEETS_TRUE@@HAVE_XMLTO_TRUE@am__append_3 = xorg.css +subdir = doc +DIST_COMMON = $(am__dist_doc_DATA_DIST) $(srcdir)/Makefile.am \ + $(srcdir)/Makefile.in +ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 +am__aclocal_m4_deps = $(top_srcdir)/configure.ac +am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ + $(ACLOCAL_M4) +mkinstalldirs = $(SHELL) $(install_sh) -d +CONFIG_HEADER = $(top_builddir)/config.h +CONFIG_CLEAN_FILES = +SOURCES = +DIST_SOURCES = +am__dist_doc_DATA_DIST = xdmcp.xml +am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; +am__vpath_adj = case $$p in \ + $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ + *) f=$$p;; \ + esac; +am__strip_dir = `echo $$p | sed -e 's|^.*/||'`; +am__installdirs = "$(DESTDIR)$(docdir)" "$(DESTDIR)$(docdir)" +dist_docDATA_INSTALL = $(INSTALL_DATA) +docDATA_INSTALL = $(INSTALL_DATA) +DATA = $(dist_doc_DATA) $(doc_DATA) +DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) +ACLOCAL = @ACLOCAL@ +ADMIN_MAN_DIR = @ADMIN_MAN_DIR@ +ADMIN_MAN_SUFFIX = @ADMIN_MAN_SUFFIX@ +AMDEP_FALSE = @AMDEP_FALSE@ +AMDEP_TRUE = @AMDEP_TRUE@ +AMTAR = @AMTAR@ +AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ +APP_MAN_DIR = @APP_MAN_DIR@ +APP_MAN_SUFFIX = @APP_MAN_SUFFIX@ +AR = @AR@ +AS = @AS@ +AUTOCONF = @AUTOCONF@ +AUTOHEADER = @AUTOHEADER@ +AUTOMAKE = @AUTOMAKE@ +AWK = @AWK@ +CC = @CC@ +CCDEPMODE = @CCDEPMODE@ +CFLAGS = @CFLAGS@ +CHANGELOG_CMD = @CHANGELOG_CMD@ +CPP = @CPP@ +CPPFLAGS = @CPPFLAGS@ +CWARNFLAGS = @CWARNFLAGS@ +CXX = @CXX@ +CXXCPP = @CXXCPP@ +CXXDEPMODE = @CXXDEPMODE@ +CXXFLAGS = @CXXFLAGS@ +CYGPATH_W = @CYGPATH_W@ +DEFS = @DEFS@ +DEPDIR = @DEPDIR@ +DLLTOOL = @DLLTOOL@ +DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ +DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ +DSYMUTIL = @DSYMUTIL@ +ECHO = @ECHO@ +ECHO_C = @ECHO_C@ +ECHO_N = @ECHO_N@ +ECHO_T = @ECHO_T@ +EGREP = @EGREP@ +ENABLE_DOCS_FALSE = @ENABLE_DOCS_FALSE@ +ENABLE_DOCS_TRUE = @ENABLE_DOCS_TRUE@ +EXEEXT = @EXEEXT@ +F77 = @F77@ +FFLAGS = @FFLAGS@ +FILE_MAN_DIR = @FILE_MAN_DIR@ +FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ +FOP = @FOP@ +GREP = @GREP@ +HASXDMAUTH_FALSE = @HASXDMAUTH_FALSE@ +HASXDMAUTH_TRUE = @HASXDMAUTH_TRUE@ +HAVE_FOP_FALSE = @HAVE_FOP_FALSE@ +HAVE_FOP_TRUE = @HAVE_FOP_TRUE@ +HAVE_STYLESHEETS_FALSE = @HAVE_STYLESHEETS_FALSE@ +HAVE_STYLESHEETS_TRUE = @HAVE_STYLESHEETS_TRUE@ +HAVE_XMLTO_FALSE = @HAVE_XMLTO_FALSE@ +HAVE_XMLTO_TEXT_FALSE = @HAVE_XMLTO_TEXT_FALSE@ +HAVE_XMLTO_TEXT_TRUE = @HAVE_XMLTO_TEXT_TRUE@ +HAVE_XMLTO_TRUE = @HAVE_XMLTO_TRUE@ +INSTALL_CMD = @INSTALL_CMD@ +INSTALL_DATA = @INSTALL_DATA@ +INSTALL_PROGRAM = @INSTALL_PROGRAM@ +INSTALL_SCRIPT = @INSTALL_SCRIPT@ +INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ +LDFLAGS = @LDFLAGS@ +LIBOBJS = @LIBOBJS@ +LIBS = @LIBS@ +LIBTOOL = @LIBTOOL@ +LIB_MAN_DIR = @LIB_MAN_DIR@ +LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ +LINT = @LINT@ +LINTLIB = @LINTLIB@ +LINT_FALSE = @LINT_FALSE@ +LINT_FLAGS = @LINT_FLAGS@ +LINT_TRUE = @LINT_TRUE@ +LN_S = @LN_S@ +LTLIBOBJS = @LTLIBOBJS@ +MAINT = @MAINT@ +MAINTAINER_MODE_FALSE = @MAINTAINER_MODE_FALSE@ +MAINTAINER_MODE_TRUE = @MAINTAINER_MODE_TRUE@ +MAKEINFO = @MAKEINFO@ +MAKE_LINT_LIB_FALSE = @MAKE_LINT_LIB_FALSE@ +MAKE_LINT_LIB_TRUE = @MAKE_LINT_LIB_TRUE@ +MAN_SUBSTS = @MAN_SUBSTS@ +MISC_MAN_DIR = @MISC_MAN_DIR@ +MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ +NMEDIT = @NMEDIT@ +OBJDUMP = @OBJDUMP@ +OBJEXT = @OBJEXT@ +PACKAGE = @PACKAGE@ +PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ +PACKAGE_NAME = @PACKAGE_NAME@ +PACKAGE_STRING = @PACKAGE_STRING@ +PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_SEPARATOR = @PATH_SEPARATOR@ +PKG_CONFIG = @PKG_CONFIG@ +RANLIB = @RANLIB@ +SED = @SED@ +SET_MAKE = @SET_MAKE@ +SHELL = @SHELL@ +STRIP = @STRIP@ +STYLESHEET_SRCDIR = @STYLESHEET_SRCDIR@ +VERSION = @VERSION@ +XDMCP_CFLAGS = @XDMCP_CFLAGS@ +XDMCP_LIBS = @XDMCP_LIBS@ +XMLTO = @XMLTO@ +XORG_MAN_PAGE = @XORG_MAN_PAGE@ +XORG_SGML_PATH = @XORG_SGML_PATH@ +XSL_STYLESHEET = @XSL_STYLESHEET@ +ac_ct_CC = @ac_ct_CC@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ +am__fastdepCC_FALSE = @am__fastdepCC_FALSE@ +am__fastdepCC_TRUE = @am__fastdepCC_TRUE@ +am__fastdepCXX_FALSE = @am__fastdepCXX_FALSE@ +am__fastdepCXX_TRUE = @am__fastdepCXX_TRUE@ +am__include = @am__include@ +am__leading_dot = @am__leading_dot@ +am__quote = @am__quote@ +am__tar = @am__tar@ +am__untar = @am__untar@ +bindir = @bindir@ +build = @build@ +build_alias = @build_alias@ +build_cpu = @build_cpu@ +build_os = @build_os@ +build_vendor = @build_vendor@ +datadir = @datadir@ +datarootdir = @datarootdir@ +docdir = @docdir@ +dvidir = @dvidir@ +exec_prefix = @exec_prefix@ +host = @host@ +host_alias = @host_alias@ +host_cpu = @host_cpu@ +host_os = @host_os@ +host_vendor = @host_vendor@ +htmldir = @htmldir@ +includedir = @includedir@ +infodir = @infodir@ +install_sh = @install_sh@ +libdir = @libdir@ +libexecdir = @libexecdir@ +localedir = @localedir@ +localstatedir = @localstatedir@ +mandir = @mandir@ +mkdir_p = @mkdir_p@ +oldincludedir = @oldincludedir@ +pdfdir = @pdfdir@ +prefix = @prefix@ +program_transform_name = @program_transform_name@ +psdir = @psdir@ +sbindir = @sbindir@ +sharedstatedir = @sharedstatedir@ +sysconfdir = @sysconfdir@ +target_alias = @target_alias@ +@ENABLE_DOCS_TRUE@doc_sources = xdmcp.xml +@ENABLE_DOCS_TRUE@dist_doc_DATA = $(doc_sources) +@ENABLE_DOCS_TRUE@@HAVE_XMLTO_TRUE@doc_DATA = \ +@ENABLE_DOCS_TRUE@@HAVE_XMLTO_TRUE@ $(doc_sources:.xml=.html) \ +@ENABLE_DOCS_TRUE@@HAVE_XMLTO_TRUE@ $(am__append_1) \ +@ENABLE_DOCS_TRUE@@HAVE_XMLTO_TRUE@ $(am__append_2) \ +@ENABLE_DOCS_TRUE@@HAVE_XMLTO_TRUE@ $(am__append_3) +@ENABLE_DOCS_TRUE@@HAVE_STYLESHEETS_TRUE@@HAVE_XMLTO_TRUE@XMLTO_FLAGS = -m $(XSL_STYLESHEET) +@ENABLE_DOCS_TRUE@@HAVE_XMLTO_TRUE@CLEANFILES = $(doc_DATA) +@ENABLE_DOCS_TRUE@@HAVE_XMLTO_TRUE@SUFFIXES = .xml .ps .pdf .txt .html +all: all-am + +.SUFFIXES: +.SUFFIXES: .xml .ps .pdf .txt .html +$(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps) + @for dep in $?; do \ + case '$(am__configure_deps)' in \ + *$$dep*) \ + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh \ + && exit 0; \ + exit 1;; \ + esac; \ + done; \ + echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign doc/Makefile'; \ + cd $(top_srcdir) && \ + $(AUTOMAKE) --foreign doc/Makefile +.PRECIOUS: Makefile +Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status + @case '$?' in \ + *config.status*) \ + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ + *) \ + echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ + esac; + +$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh + +$(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh + +mostlyclean-libtool: + -rm -f *.lo + +clean-libtool: + -rm -rf .libs _libs + +distclean-libtool: + -rm -f libtool +uninstall-info-am: +install-dist_docDATA: $(dist_doc_DATA) + @$(NORMAL_INSTALL) + test -z "$(docdir)" || $(mkdir_p) "$(DESTDIR)$(docdir)" + @list='$(dist_doc_DATA)'; for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + f=$(am__strip_dir) \ + echo " $(dist_docDATA_INSTALL) '$$d$$p' '$(DESTDIR)$(docdir)/$$f'"; \ + $(dist_docDATA_INSTALL) "$$d$$p" "$(DESTDIR)$(docdir)/$$f"; \ + done + +uninstall-dist_docDATA: + @$(NORMAL_UNINSTALL) + @list='$(dist_doc_DATA)'; for p in $$list; do \ + f=$(am__strip_dir) \ + echo " rm -f '$(DESTDIR)$(docdir)/$$f'"; \ + rm -f "$(DESTDIR)$(docdir)/$$f"; \ + done +install-docDATA: $(doc_DATA) + @$(NORMAL_INSTALL) + test -z "$(docdir)" || $(mkdir_p) "$(DESTDIR)$(docdir)" + @list='$(doc_DATA)'; for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + f=$(am__strip_dir) \ + echo " $(docDATA_INSTALL) '$$d$$p' '$(DESTDIR)$(docdir)/$$f'"; \ + $(docDATA_INSTALL) "$$d$$p" "$(DESTDIR)$(docdir)/$$f"; \ + done + +uninstall-docDATA: + @$(NORMAL_UNINSTALL) + @list='$(doc_DATA)'; for p in $$list; do \ + f=$(am__strip_dir) \ + echo " rm -f '$(DESTDIR)$(docdir)/$$f'"; \ + rm -f "$(DESTDIR)$(docdir)/$$f"; \ + done +tags: TAGS +TAGS: + +ctags: CTAGS +CTAGS: + + +distdir: $(DISTFILES) + @srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; \ + topsrcdirstrip=`echo "$(top_srcdir)" | sed 's|.|.|g'`; \ + list='$(DISTFILES)'; for file in $$list; do \ + case $$file in \ + $(srcdir)/*) file=`echo "$$file" | sed "s|^$$srcdirstrip/||"`;; \ + $(top_srcdir)/*) file=`echo "$$file" | sed "s|^$$topsrcdirstrip/|$(top_builddir)/|"`;; \ + esac; \ + if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ + dir=`echo "$$file" | sed -e 's,/[^/]*$$,,'`; \ + if test "$$dir" != "$$file" && test "$$dir" != "."; then \ + dir="/$$dir"; \ + $(mkdir_p) "$(distdir)$$dir"; \ + else \ + dir=''; \ + fi; \ + if test -d $$d/$$file; then \ + if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ + cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \ + fi; \ + cp -pR $$d/$$file $(distdir)$$dir || exit 1; \ + else \ + test -f $(distdir)/$$file \ + || cp -p $$d/$$file $(distdir)/$$file \ + || exit 1; \ + fi; \ + done +check-am: all-am +check: check-am +all-am: Makefile $(DATA) +installdirs: + for dir in "$(DESTDIR)$(docdir)" "$(DESTDIR)$(docdir)"; do \ + test -z "$$dir" || $(mkdir_p) "$$dir"; \ + done +install: install-am +install-exec: install-exec-am +install-data: install-data-am +uninstall: uninstall-am + +install-am: all-am + @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am + +installcheck: installcheck-am +install-strip: + $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ + install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + `test -z '$(STRIP)' || \ + echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install +mostlyclean-generic: + +clean-generic: + -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES) + +distclean-generic: + -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) + +maintainer-clean-generic: + @echo "This command is intended for maintainers to use" + @echo "it deletes files that may require special tools to rebuild." +clean: clean-am + +clean-am: clean-generic clean-libtool mostlyclean-am + +distclean: distclean-am + -rm -f Makefile +distclean-am: clean-am distclean-generic distclean-libtool + +dvi: dvi-am + +dvi-am: + +html: html-am + +info: info-am + +info-am: + +install-data-am: install-dist_docDATA install-docDATA + +install-exec-am: + +install-info: install-info-am + +install-man: + +installcheck-am: + +maintainer-clean: maintainer-clean-am + -rm -f Makefile +maintainer-clean-am: distclean-am maintainer-clean-generic + +mostlyclean: mostlyclean-am + +mostlyclean-am: mostlyclean-generic mostlyclean-libtool + +pdf: pdf-am + +pdf-am: + +ps: ps-am + +ps-am: + +uninstall-am: uninstall-dist_docDATA uninstall-docDATA \ + uninstall-info-am + +.PHONY: all all-am check check-am clean clean-generic clean-libtool \ + distclean distclean-generic distclean-libtool distdir dvi \ + dvi-am html html-am info info-am install install-am \ + install-data install-data-am install-dist_docDATA \ + install-docDATA install-exec install-exec-am install-info \ + install-info-am install-man install-strip installcheck \ + installcheck-am installdirs maintainer-clean \ + maintainer-clean-generic mostlyclean mostlyclean-generic \ + mostlyclean-libtool pdf pdf-am ps ps-am uninstall uninstall-am \ + uninstall-dist_docDATA uninstall-docDATA uninstall-info-am + +@ENABLE_DOCS_TRUE@@HAVE_STYLESHEETS_TRUE@@HAVE_XMLTO_TRUE@xorg.css: $(STYLESHEET_SRCDIR)/xorg.css +@ENABLE_DOCS_TRUE@@HAVE_STYLESHEETS_TRUE@@HAVE_XMLTO_TRUE@ $(AM_V_GEN)cp -pf $(STYLESHEET_SRCDIR)/xorg.css $@ + +@ENABLE_DOCS_TRUE@@HAVE_XMLTO_TRUE@.xml.txt: +@ENABLE_DOCS_TRUE@@HAVE_XMLTO_TRUE@ $(AM_V_GEN)$(XMLTO) $(XMLTO_FLAGS) txt $< + +@ENABLE_DOCS_TRUE@@HAVE_XMLTO_TRUE@.xml.html: +@ENABLE_DOCS_TRUE@@HAVE_XMLTO_TRUE@ $(AM_V_GEN)$(XMLTO) $(XMLTO_FLAGS) xhtml-nochunks $< + +@ENABLE_DOCS_TRUE@@HAVE_XMLTO_TRUE@.xml.pdf: +@ENABLE_DOCS_TRUE@@HAVE_XMLTO_TRUE@ $(AM_V_GEN)$(XMLTO) $(XMLTO_FLAGS) --with-fop pdf $< + +@ENABLE_DOCS_TRUE@@HAVE_XMLTO_TRUE@.xml.ps: +@ENABLE_DOCS_TRUE@@HAVE_XMLTO_TRUE@ $(AM_V_GEN)$(XMLTO) $(XMLTO_FLAGS) --with-fop ps $< +# Tell versions [3.59,3.63) of GNU make to not export all variables. +# Otherwise a system limit (for SysV at least) may be exceeded. +.NOEXPORT: diff --git a/lib/libXdmcp/doc/xdmcp.xml b/lib/libXdmcp/doc/xdmcp.xml new file mode 100644 index 000000000..22bccc610 --- /dev/null +++ b/lib/libXdmcp/doc/xdmcp.xml @@ -0,0 +1,3895 @@ +<?xml version="1.0" encoding="UTF-8" ?> +<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.3//EN" + "http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd"> + +<book id="xdmcp"> + +<bookinfo> + <title>X Display Manager Control Protocol</title> + <subtitle>X.Org Standard</subtitle> + <releaseinfo>Version 1.1</releaseinfo> + <authorgroup> + <author> + <firstname>Keith</firstname><surname>Packard</surname> + <affiliation><orgname> +X Consortium, +Laboratory for Computer Science, +Massachusetts Institute of Technology + </orgname></affiliation> + </author> + </authorgroup> + + <copyright><year>1989</year><holder>The Open Group</holder></copyright> + <copyright><year>2004</year><holder>The Open Group</holder></copyright> + <productnumber>X Version 11, Release 6.8</productnumber> + +<legalnotice> + + + +<para> +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: +</para> +<para> +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. +</para> +<para> +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN +AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +</para> +<para> +Except as contained in this notice, the name of The Open Group shall not be +used in advertising or otherwise to promote the sale, use or other dealings +in this Software without prior written authorization from The Open Group. +</para> + +<para> +<emphasis remap='I'>X Window System</emphasis> is a trademark of The Open Group. +</para> +</legalnotice> +</bookinfo> + +<chapter id="TITLE"> +<title>TITLE</title> +<sect1 id="Purpose_and_Goals"> +<title>Purpose and Goals</title> +<!-- .XS --> +<!-- (SN Purpose and Goals --> +<!-- .XE --> +<para> +<!-- .LP --> +The purpose of the X Display Manager Control Protocol (XDMCP) +is to provide a uniform mechanism for an autonomous +display to request login service from a remote host. +By autonomous, we mean +the display consists of hardware and processes that are independent of any +particular host where login service is desired. (For example, the server +cannot simply be started by a +<function>fork/exec</function> +sequence on the host.) +An X terminal (screen, keyboard, mouse, processor, network interface) +is a prime example of an autonomous display. +</para> + +<para> +From the point of view of the end user, it is very important to make +autonomous displays as easy to use as traditional hardwired character +terminals. Specifically, you can typically just power on a hardwired +terminal and be greeted with a login prompt. The same should be possible +with autonomous displays. However, in a network environment with multiple +hosts, the end user may want to choose which host(s) to connect to. In an +environment with many displays and many hosts, a site administrator may want +to associate particular collections of hosts with particular displays. We +would like to support the following options: +</para> + +<itemizedlist> + <listitem> + <para> +The display has a single, fixed host to which it should connect. It should be +possible to power on the display and receive a login prompt, without user +intervention. + </para> + </listitem> + <listitem> + <para> +Any one of several hosts on a network or subnetwork may be acceptable +for accepting login from the display. +(For example, the user's file systems can be mounted onto +any such host, providing comparable environments.) It should be possible +for the display to broadcast to find such hosts and to have the display +either automatically choose a host or present the possible hosts to the +user for selection. + </para> + </listitem> + <listitem> + <para> +The display has a fixed set of hosts that it can connect to. It should be +possible for the display to have that set stored in RAM, but it should also be +possible for a site administrator to be able to maintain host sets for a +large number of displays using a centralized facility, without having to +interact (physically or electronically) with each individual display. +Particular hosts should be allowed to refuse login service, based on +whatever local criteria are desired. + </para> + </listitem> +</itemizedlist> + +<para> +The control protocol should be designed in such a way that it can be used over +a reasonable variety of communication transport layers. In fact, it is quite +desirable if every major network protocol family that supports the standard X +protocol is also capable of supporting XDMCP, because the end result of XDMCP +negotiation will be standard X protocol connections to the display. +However, because the number of displays per host may be large, +a connection-based protocol appears less desirable +than a connection-less protocol. For this reason the protocol is designed +to use datagram services with the display responsible for sequencing and +retransmission. +</para> +<para> +<!-- .LP --> +To keep the burden on displays at a minimum (because display cost is not +a factor that can be ignored), it is desirable that displays not be required +to maintain permanent state (across power cycles) for the purposes +of the control protocol, +and it is desirable to keep required state at a minimum while the +display is powered on. +</para> +<para> +<!-- .LP --> +Security is an important consideration and must be an integral part of the +design. The important security goals in the context of XDMCP are: +</para> +<itemizedlist> + <listitem> + <para> +It should be possible for the display to verify that it is communicating +with a legitimate host login service. Because the user will present +credentials (for example, password) to this service, +it is important to avoid spoof attacks. + </para> + </listitem> + <listitem> + <para> +It should be possible for the display and the login service to negotiate the +authorization mechanism to be used for the standard X protocol. + </para> + </listitem> + <listitem> + <para> +It should be possible to provide the same level of security in verifying the +login service as is provided by the negotiated authorization mechanism. + </para> + </listitem> + <listitem> + <para> +Because there are no firm standards yet in the area of security, +XDMCP must be flexible enough to accomodate a variety of security mechanisms. + </para> + </listitem> +</itemizedlist> +</sect1> + +<sect1 id="Overview_of_the_Protocol"> +<title>Overview of the Protocol</title> +<!-- .XS --> +<!-- (SN Overview of the Protocol --> +<!-- .XE --> +<para> +<!-- .LP --> +XDMCP is designed to provide authenticated access to display management +services for remote displays. A new network server, called a \fIDisplay +Manager\fP, will use XDMCP to communicate with displays to negotiate the +startup of X sessions. The protocol allows the display to authenticate the +manager. It also allows most of the configuration information to be +centralized with the manager and to ease the burden of system administration +in a large network of displays. +The essential goal is to provide plug-and-play +services similar to those provided in the familiar mainframe/terminal world. +</para> +<para> +<!-- .LP --> +Displays may be turned off by the user at any time. Any existing session +running on a display that has been turned off must be identifiable. This +is made possible by requiring a three-way handshake to start a session. If +the handshake succeeds, any existing session is terminated immediately and a +new session started. There is the problem (at least with TCP) that +connections may not be closed when the display is turned off. In most +environments, the manager should reduce this problem by periodically XSync'ing +on its own connection, perhaps every five to ten minutes, and terminating the +session if its own connection ever closes. +</para> +<para> +<!-- .LP --> +Displays should not be required to retain permanent state for purposes of +the control protocol. One solution to packets received out of sequence +would be to use monotonically increasing message identifiers in each message +to allow both sides to ignore messages that arrive out-of-sequence. For +this to work, displays would at a minimum have to increment a stable crash +count each time they are powered on and use that number as part of a +larger sequence number. But if displays cannot retain permanent state this +cannot work. Instead, the manager assumes the responsibility for permanent +state by generating unique numbers that identify a particular session and +the protocol simply ignores packets that correspond to an invalid session. +</para> +<para> +<!-- .LP --> +The Manager must not be responsible for packet reception. To prevent the +Manager from becoming stuck because of a hostile display, no portion of the +protocol requires the Manager to retransmit a packet. Part of this means +that any valid packet that the Manager does receive must be +acknowledged in some way to prevent the display from continuously resending +packets. The display can keep the protocol running as it will always know +when the Manager has received (at least one copy of) a packet. On the +Manager side, this means that any packet may be received more than once (if +the response was lost) and duplicates must be ignored. +</para> +</sect1> + +<sect1 id="Data_Types"> +<title>Data Types</title> +<!-- .XS --> +<!-- (SN Data Types --> +<!-- .XE --> +<para> +<!-- .LP --> +XDMCP packets contain several types of data. Integer values are always +stored most significant byte first in the packet ("Big Endian" order). +As XDMCP will not be used to transport large quantities of data, this +restriction will not substantially hamper the efficiency of any +implementation. Also, no padding of any sort will occur within the packets. +</para> + +<informaltable frame="none"> + <tgroup cols='3' align='left'> + <colspec colname='c1' colsep="0"/> + <colspec colname='c2' colsep="0"/> + <colspec colname='c3' colsep="0"/> + <thead> + <row> + <entry>Type Name</entry> + <entry>Length (Bytes)</entry> + <entry>Description</entry> + </row> + </thead> + <tbody> + <row rowsep="0"> + <entry>CARD8</entry> + <entry>1</entry> + <entry>A single byte unsigned integer</entry> + </row> + <row rowsep="0"> + <entry>CARD16</entry> + <entry>2</entry> + <entry>Two byte unsigned integer</entry> + </row> + <row rowsep="0"> + <entry>CARD32</entry> + <entry>4</entry> + <entry>Four byte unsigned integer</entry> + </row> + <row rowsep="0"> + <entry>ARRAY8</entry> + <entry>n+2</entry> + <entry> +This is actually a CARD16 followed by +a collection of CARD8. The value of the CARD16 +field (n) specifies the number of CARD8 values to follow + </entry> + </row> + <row rowsep="0"> + <entry>ARRAY16</entry> + <entry>2*m+1</entry> + <entry> +This is a CARD8 (m) which specifies the +number of CARD16 values to follow + </entry> + </row> + <row rowsep="0"> + <entry>ARRAY32</entry> + <entry>4*l+1</entry> + <entry> +This is a CARD8 (l) which specifies the +number of CARD32 values to follow + </entry> + </row> + <row rowsep="0"> + <entry>ARRAYofARRAY8</entry> + <entry>?</entry> + <entry> +This is a CARD8 which specifies the +number of ARRAY8 values to follow. + </entry> + </row> + </tbody> + </tgroup> +</informaltable> +</sect1> + +<sect1 id="Packet_Format"> +<title>Packet Format</title> +<!-- .XS --> +<!-- (SN Packet Format --> +<!-- .XE --> +<para> +All XDMCP packets have the following information: +</para> + +<informaltable frame="none"> + <tgroup cols='3' align='left'> + <colspec colname='c1' colsep="0"/> + <colspec colname='c2' colsep="0"/> + <colspec colname='c3' colsep="0"/> + <thead> + <row> + <entry>Length (Bytes)</entry> + <entry>Field Type</entry> + <entry>Description</entry> + </row> + </thead> + <tbody> + <row rowsep="0"> + <entry>2</entry> + <entry>CARD16</entry> + <entry>version number</entry> + </row> + <row rowsep="0"> + <entry>2</entry> + <entry>CARD16</entry> + <entry>opcode packet header</entry> + </row> + <row rowsep="0"> + <entry>2</entry> + <entry>CARD16</entry> + <entry>n = length of remaining data in bytes</entry> + </row> + <row rowsep="0"> + <entry>n</entry> + <entry>???</entry> + <entry>packet-specific data</entry> + </row> + </tbody> + </tgroup> +</informaltable> + +<para> +<!-- .LP --> +The fields are as follows: +</para> + +<variablelist> + <varlistentry> + <term>Version number</term> + <listitem> + <para> +This specifies the version of XDMCP that generated this packet in +case changes in this protocol are required. Displays and +managers may choose to support older versions for compatibility. +This field will initially be one (1). + </para> + </listitem> + </varlistentry> + <varlistentry> + <term>Opcode</term> + <listitem> + <para> +This specifies what step of the protocol this packet represents and should +contain one of the following values (encoding provided in section below): +<emphasis role="bold">BroadcastQuery</emphasis>, +<emphasis role="bold">Query</emphasis>, +<emphasis role="bold">IndirectQuery</emphasis>, +<emphasis role="bold">ForwardQuery</emphasis>, +<emphasis role="bold">Willing</emphasis>, +<emphasis role="bold">Unwilling</emphasis>, +<emphasis role="bold">Request</emphasis>, +<emphasis role="bold">Accept</emphasis>, +<emphasis role="bold">Decline</emphasis>, +<emphasis role="bold">Manage</emphasis>, +<emphasis role="bold">Refuse</emphasis>, +<emphasis role="bold">Failed</emphasis>, +<emphasis role="bold">KeepAlive</emphasis> +or +<emphasis role="bold">Alive</emphasis>. + </para> + </listitem> + </varlistentry> + <varlistentry> + <term>Length of data in bytes</term> + <listitem> + <para> +This specifies the length of the information following the first 6 bytes. +Each packet-type has a different format and will need to be separately +length-checked against this value. Because every data item has either an +explicit or implicit length, this can be easily accomplished. +Packets that have too little or too much data should be ignored. + </para> + </listitem> + </varlistentry> +</variablelist> +<para> +Packets should be checked to make sure that they satisfy the following +conditions: +</para> + +<orderedlist> + <listitem> + <para> +They must contain valid opcodes. + </para> + </listitem> + <listitem> + <para> +The length of the remaining data should correspond to the sum of the +lengths of the individual remaining data items. + </para> + </listitem> + <listitem> + <para> +The opcode should be expected (a finite state diagram is given +in a later section). + </para> + </listitem> + <listitem> + <para> +If the packet is of type +<emphasis role="bold">Manage</emphasis> or +<emphasis role="bold">Refuse</emphasis>, +the Session ID should match the value sent in the preceding +<emphasis role="bold">Accept</emphasis> packet. + </para> + </listitem> +</orderedlist> +</sect1> + +<sect1 id="Protocol"> +<title>Protocol</title> +<!-- .XS --> +<!-- (SN Protocol --> +<!-- .XE --> +<para> +Each of the opcodes is described below. Because a given packet type is only +ever sent one way, each packet description below indicates the direction. +Most of the packets have additional information included beyond the +description above. The additional information is appended to the packet +header in the order described without padding, and the length field is +computed accordingly. +</para> + +<informaltable frame="none"> + <tgroup cols='10' align='left'> + <colspec colname='col1' colsep="0" colwidth="1*"/> + <colspec colname='col2' colsep="0" colwidth="1*"/> + <colspec colname='col3' colsep="0" colwidth="1*"/> + <colspec colname='col4' colsep="0" colwidth="1*"/> + <colspec colname='col5' colsep="0" colwidth="1*"/> + <colspec colname='col6' colsep="0" colwidth="1*"/> + <colspec colname='col7' colsep="0" colwidth="1*"/> + <colspec colname='col8' colsep="0" colwidth="1*"/> + <colspec colname='col9' colsep="0" colwidth="1*"/> + <colspec colname='col10' colsep="0" colwidth="1*"/> + <spanspec namest="col1" nameend="col10" spanname="col1_on" align="left"/> + <spanspec namest="col2" nameend="col10" spanname="col2_on" align="left"/> + <spanspec namest="col3" nameend="col10" spanname="col3_on" align="left"/> + <spanspec namest="col4" nameend="col10" spanname="col4_on" align="left"/> + <spanspec namest="col5" nameend="col10" spanname="col5_on" align="left"/> + <tbody> + <row rowsep="0"> + <entry spanname="col1_on"><emphasis role="bold">Query</emphasis></entry> + </row> + <row rowsep="0"> + <entry spanname="col1_on"><emphasis role="bold">BroadcastQuery</emphasis></entry> + </row> + <row rowsep="0"> + <entry spanname="col1_on"><emphasis role="bold">IndirectQuery</emphasis></entry> + </row> + <row rowsep="0"> + <entry></entry> + <entry spanname="col2_on">Display -> Manager</entry> + </row> + <row rowsep="0"> + <entry></entry> + <entry spanname="col2_on">Additional Fields:</entry> + </row> + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +<emphasis>Authentication Names</emphasis>: ARRAYofARRAY8 + </entry> + </row> + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Specifies a list of authentication names that the display supports. The +manager will choose one of these and return it in the +<emphasis role="bold">Willing</emphasis> packet. + </entry> + </row> +<!-- AAAAAAAAAAAAA --> + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry>Semantics</entry> + </row> + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +<para> +A <function>Query</function> +packet is sent from the display to a specific host to ask if +that host is willing to provide management services to this display. The +host should respond with +<function>Willing</function> +if it is willing to service the display or +<function>Unwilling</function> +if it is not. +</para> + +<para> +A +<function>BroadcastQuery</function> +packet is similar to the +<function>Query</function> +packet except that it is intended to be received by all hosts on the network +(or subnetwork). However, unlike +<function>Query</function> +requests, hosts that are not willing to service the display +should simply ignore +<function>BroadcastQuery</function> +requests. +</para> + +<para> +An +<function>IndirectQuery</function> +packet is sent to a well known manager that forwards +the request to a larger collection of secondary managers using +<function>ForwardQuery</function> +packets. +In this way, the collection of managers that respond can be grouped +on other than network boundaries; the use of a central manager reduces +system administrative overhead. +The primary manager may also send a +<function>Willing</function> +packet in response to this packet. +</para> + +<para> +Each packet type has slightly different semantics: +</para> + </entry> + </row> + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col5_on"> +<para> +The +<function>Query</function> +packet is destined only for a single host. +If the display is instructed to +<function>Query</function> +multiple managers, it will send multiple +<function>Query</function> +packets. The +<function>Query</function> +packet also demands a response from the manager, either +<function>Willing</function> +or +<function>Unwilling</function>. + </para> + <para> +The +<function>BroadcastQuery</function> +packet is sent to many hosts. +Each manager that receives this packet will not respond with an +<function>Unwilling</function> +packet. + </para> + <para> +The +<function>IndirectQuery</function> +packet is sent to only one manager with the request +that the request be forwarded to a larger list of managers using +<function>ForwardQuery</function> +packets. This list is expected to be maintained at one +central site to reduce administrative overhead. +The function of this packet type is similar to +<function>BroadcastQuery except that</function> +<function>BroadcastQuery</function> +is not forwarded. + </para> + </entry> + </row> + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on">Valid Responses:</entry> + </row> + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +<function>Willing</function>, +<function>Unwilling</function> + </entry> + </row> + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on">Problems/Solutions:</entry> + </row> + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on">Problem:</entry> + </row> + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +<para>Not all managers receive the query packet.</para> +<para>Indication:</para> + </entry> + </row> + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col5_on"> +None if +<function>BroadcastQuery</function> +or +<function>IndirectQuery</function> +was sent, else failure to receive +<function>Willing</function>. + </entry> + </row> + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on">Solution:</entry> + </row> + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col5_on"> +Repeatedly send the packet while waiting for user to choose a manager. + </entry> + </row> + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +Timeout/Retransmission policy: + </entry> + </row> + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +An exponential backoff algorithm should be used here to reduce network load +for long-standing idle displays. Start at 2 seconds, back off by factors of +2 to 32 seconds, and discontinue retransmit after 126 seconds. The display +should reset the timeout when user-input is detected. In this way, the +display will wakeup when touched by the user. + </entry> + </row> + <row rowsep="0"> + <entry spanname="col1_on"> +<function>ForwardQuery</function> + </entry> + </row> + <row rowsep="0"> + <entry></entry> + <entry spanname="col2_on"> +<para>Primary Manager -> Secondary Manager</para> +<para>Additional Fields:</para> + </entry> + </row> + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +<emphasis remap='I'>Client Address</emphasis>: ARRAY8 + </entry> + </row> + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Specifies the network address of the client display. + </entry> + </row> + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +<emphasis remap='I'>Client Port</emphasis>: ARRAY8 + </entry> + </row> + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Specifies an identification of the client task on the client display. + </entry> + </row> + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +<emphasis remap='I'>Authentication Names</emphasis>: ARRAYofARRAY8 + </entry> + </row> + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Is a duplicate of Authentication Names array that was received +in the +<function>IndirectQuery</function> +packet. + </entry> + </row> + <row rowsep="0"> + <entry></entry> + <entry spanname="col2_on"> +Semantics: + </entry> + </row> + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> + <para> +When primary manager receives a +<function>IndirectQuery</function> +packet, it is responsible for sending +<function>ForwardQuery</function> +packets to an appropriate list of +managers that can provide service to the display using the same network +type as the one the original +<function>IndirectQuery</function> +packet was received from. +The Client Address and Client Port fields must contain an +address that the secondary manager can use to reach the display also using +this same network. Each secondary manager sends a +<function>Willing</function> +packet to the display if it is willing to provide service. + </para> + + <para> +<function>ForwardQuery</function> +packets are similar to +<function>BroadcastQuery</function> +packets in that managers that are not willing to service +particular displays should not send a +<function>Unwilling</function> +packet. + </para> + </entry> + </row> + <row rowsep="0"> + <entry></entry> + <entry spanname="col2_on"> +Valid Responses: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +<function>Willing</function> + </entry> + </row> + <row rowsep="0"> + <entry></entry> + <entry spanname="col2_on"> +Problems/Solutions: + </entry> + </row> + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +Identical to +<function>BroadcastQuery</function> + </entry> + </row> + <row rowsep="0"> + <entry></entry> + <entry spanname="col2_on"> +Timeout/Retransmission policy: + </entry> + </row> + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +Like all packets sent from a manager, this packet should never be +retransmitted. + </entry> + </row> + + <row rowsep="0"> + <entry spanname="col1_on"> +<function>Willing</function> + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry spanname="col2_on"> + <para> +Manager -> Display + </para> + <para> +Additional Fields: + </para> + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +<emphasis remap='I'>Authentication Name</emphasis>: ARRAY8 + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +<para> +Specifies the authentication method, selected from the list offered in the +<function>Query ,</function> +<function>BroadcastQuery ,</function> +or +<function>IndirectQuery</function> +packet that the manger expects the display to use in the subsequent +<function>Request</function> +packet. +This choice should remain as constant as feasible so that displays that +send multiple +<function>Query</function> +packets can use the Authentication Name from any +<function>Willing</function> +packet that arrives. +</para> +<para> +The display is free to ignore managers that request an insufficient level +of authentication. +</para> + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +<emphasis remap='I'>Hostname</emphasis>: ARRAY8 + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Is a human readable string describing the host from which the packet was sent. +The protocol specifies no interpretation of the data in this field. + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +<emphasis remap='I'>Status</emphasis>: ARRAY8 + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Is a human readable string describing the status of the host. This could +include load average/number of users connected or other information. The +protocol specifies no interpretation of the data in this field. + </entry> + </row> + + + <row rowsep="0"> + <entry></entry> + <entry spanname="col2_on"> +Semantics: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +A +<function>Willing</function> +packet is sent by managers that may service connections from +this display. It is sent in response to either a +<function>Query ,</function> +<function>BroadcastQuery ,</function> +or +<function>ForwardQuery</function> +but does not imply a commitment to provide service +(for example, it may later decide that it has accepted enough +connections already). + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry spanname="col2_on"> +Problems/Solutions: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +Problem: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +<para> +<function>Willing</function> +not received by the display. +</para> +<para> +Indication: +</para> + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col5_on"> +None if +<function>BroadcastQuery</function> +or +<function>IndirectQuery</function> +was sent, else failure to receive +<function>Willing .</function> + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Solution: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col5_on"> +The display should continue to send the query until a response is received. + </entry> + </row> + + + + <row rowsep="0"> + <entry></entry> + <entry spanname="col2_on"> +Timeout/Retransmission policy: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +Like all packets sent from the manager to the display, this packet should +never be retransmitted. + </entry> + </row> + + <row rowsep="0"> + <entry spanname="col1_on"> +<function>Unwilling</function> + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry spanname="col2_on"> + <para> +Manager -> Display + </para> + <para> +Additional Fields: + </para> + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +The Hostname and Status fields as in the +<function>Willing</function> +packet. +The Status field should indicate to the user a reason +for the refusal of service. + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry spanname="col2_on"> +Semantics: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +An +<function>Unwilling</function> +packet is sent by managers in response to direct +<function>Query</function> +requests (as opposed to +<function>BroadcastQuery</function> +or +<function>IndirectQuery</function> +requests) if the manager will not accept requests for management. +This is typically sent by managers that wish to only service +particular displays or that handle a limited number of displays at once. + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry spanname="col2_on"> +Problems/Solutions: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +Problem: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +<para> +<function>Unwilling</function> +not received by the display. +</para> +<para> +Indication: +</para> + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col5_on"> +Display fails to receive +<function>Unwilling .</function> + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Solution: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col5_on"> +The display should continue to send +<function>Query</function> +messages until a response is received. + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry spanname="col2_on"> +Timeout/Retransmission policy: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +Like all packets sent from the manager to the display, this packet should +never be retransmitted. + </entry> + </row> + <row rowsep="0"> + <entry spanname="col1_on"> +<function>Request</function> + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry spanname="col2_on"> + <para> +Display -> Manager + </para> + <para> +Additional Fields: + </para> + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +<emphasis remap='I'>Display Number</emphasis>: CARD16 + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Specifies the index of this particular server for the host +on which the display is resident. +This value will be zero for most autonomous displays. + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +<emphasis remap='I'>Connection Types</emphasis>: ARRAY16 + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Specifies an array indicating the stream services accepted by the display. +If the high-order byte in a particular entry is zero, the low-order byte +corresponds to an X-protocol host family type. + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +<emphasis remap='I'>Connection Addresses</emphasis>: ARRAYofARRAY8 + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +For each connection type in the previous array, the corresponding entry in +this array indicates the network address of the display device. + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> + <para> +<emphasis remap='I'>Authentication Name</emphasis>: ARRAY8 + </para> + <para> +<emphasis remap='I'>Authentication Data</emphasis>: ARRAY8 + </para> + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Specifies the authentication protocol that the display expects +the manager to validate itself with. The Authentication Data is +expected to contain data that the manager will interpret, modify +and use to authenticate itself. + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +<emphasis remap='I'>Authorization Names</emphasis>: ARRAYofARRAY8 + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Specifies which types of authorization the display supports. The +manager may decide to reject displays with which it cannot perform +authorization. + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +<emphasis remap='I'>Manufacturer Display ID</emphasis>: ARRAY8 + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Can be used by the manager to determine how to decrypt the +Authentication Data field in this packet. See the section below on +Manufacturer Display ID Format. + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry spanname="col2_on"> +Semantics: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +A +<function>Request</function> +packet is sent by a display to a specific host to request a +session ID in preparation for a establishing a connection. If the manager +is willing to service a connection to this display, it should return an +<function>Accept</function> +packet with a valid session ID and should be ready for a subsequent +<function>Manage</function> +request. Otherwise, it should return a +<function>Decline</function> +packet. + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry spanname="col2_on"> +Valid Responses: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +<function>Accept ,</function> +<function>Decline</function> + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry spanname="col2_on"> +Problems/Solutions: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +Problem: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Request not received by manager. + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Indication: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col5_on"> +Display timeout waiting for response. + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Solution: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col5_on"> +Display resends +<function>Request</function> +message. + </entry> + </row> + + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Problem: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col5_on"> +Message received out of order by manager. + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Indication: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col5_on"> +None. + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Solution: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col5_on"> +Each time a +<function>Request</function> +is sent, the manager sends the Session ID +associated with the next session in the +<function>Accept .</function> +If that next session is not yet started, +the manager will simply resend with the same Session ID. +If the session is in progress, the manager will reply +with a new Session ID; in which case, the +<function>Accept</function> +will be discarded by the display. + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry spanname="col2_on"> +Timeout/Retransmission policy: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +Timeout after 2 seconds, exponential backoff to 32 seconds. +After no more than 126 seconds, give up and report an error to the user. + </entry> + </row> + + <row rowsep="0"> + <entry spanname="col1_on"> +<function>Accept</function> + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry spanname="col2_on"> + <para> +Manager -> Display + </para> + <para> +Additional Fields: + </para> + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +<emphasis remap='I'>Session ID</emphasis>: CARD32 + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Identifies the session that can be started by the manager. + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> + <para> +<emphasis remap='I'>Authentication Name</emphasis>: ARRAY8 + </para> + <para> +<emphasis remap='I'>Authentication Data</emphasis>: ARRAY8 + </para> + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Is the data sent back to the display to authenticate the manager. +If the Authentication Data is not the value expected by the display, it +should terminate the protocol at this point and display an error to the user. + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> + <para> +<emphasis remap='I'>Authorization Name</emphasis>: ARRAY8 + </para> + <para> +<emphasis remap='I'>Authorization Data</emphasis>: ARRAY8 + </para> + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Is the data sent to the display to indicate the type of authorization the +manager will be using in the first call to +<function>XOpenDisplay</function> +after the +<function>Manage</function> +packet is received. + </entry> + </row> + + + <row rowsep="0"> + <entry></entry> + <entry spanname="col2_on"> +Semantics: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +<para> +An +<function>Accept</function> +packet is sent by a manager in response to a +<function>Request</function> +packet if the manager is willing to establish a connection for the display. +The Session ID is used to identify this connection from any preceding +ones and will be used by the display in its subsequent +<function>Manage</function> +packet. +The Session ID is a 32-bit number that is incremented each time an +<function>Accept</function> +packet is sent as it must be unique over a reasonably long period of time. +</para> +<para> +If the authentication information is invalid, a +<function>Decline</function> +packet will be returned with an appropriate +<function>Status</function> +message. +</para> + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry spanname="col2_on"> +Problems/Solutions: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +Problem: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +<function>Accept</function> +or +<function>Decline</function> +not received by display. + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Indication: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col5_on"> +Display timeout waiting for response to +<function>Request .</function> + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Solution: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col5_on"> +Display resends +<function>Request</function> +message. + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +Problem: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Message received out of order by display. + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Indication: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col5_on"> +Display receives +<function>Accept</function> +after +<function>Manage</function> +has been sent. + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Solution: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col5_on"> +Display discards +<function>Accept</function> +messages after it has sent a +<function>Manage</function> +message. + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry spanname="col2_on"> +Timeout/Retransmission policy: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +Like all packets sent from the manager to the display, this packet should +never be retransmitted. + </entry> + </row> + + <row rowsep="0"> + <entry spanname="col1_on"> +<function>Decline</function> + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry spanname="col2_on"> + <para> +Manager -> Display + </para> + <para> +Additional Fields: + </para> + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +<emphasis remap='I'>Status</emphasis>: ARRAY8 + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Is a human readable string indicating the reason for refusal of +service. + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> + <para> +<emphasis remap='I'>Authentication Name</emphasis>: +ARRAY8 + </para> + <para> +<emphasis remap='I'>Authentication Data</emphasis>: +ARRAY8 + </para> + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Is the data sent back to the display to authenticate the manager. If the +Authentication Data is not the value expected by the display, it +should terminate the protocol at this point and display an error to the user. + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry spanname="col2_on"> +Semantics: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +A +<function>Decline</function> +packet is sent by a manager in response to a +<function>Request</function> +packet if the manager is unwilling to establish a connection for the +display. +This is allowed even if the manager had responded +<function>Willing</function> +to a previous query. + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry spanname="col2_on"> +Problems/Solutions: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +Same as for +<function>Accept .</function> + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry spanname="col2_on"> +Timeout/Retransmission policy: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +Like all packets sent from a manager to a display, this packet should never +be retransmitted. + </entry> + </row> + + <row rowsep="0"> + <entry spanname="col1_on"> +<function>Manage</function> + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry spanname="col2_on"> + <para> +Display -> Manager + </para> + <para> +Additional Fields: + </para> + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +<emphasis remap='I'>Session ID</emphasis>: CARD32 + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Should contain the nonzero session ID returned in the +<function>Accept</function> +packet. + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +<emphasis remap='I'>Display Number</emphasis>: CARD16 + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Must match the value sent in the previous +<function>Request</function> +packet. + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +<emphasis remap='I'>Display Class</emphasis>: ARRAY8 + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Specifies the class of the display. +See the Display Class Format section, +which discusses the format of this field. + </entry> + </row> + + + <row rowsep="0"> + <entry></entry> + <entry spanname="col2_on"> +Semantics: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +A +<function>Manage</function> +packet is sent by a display to ask the manager to begin a +session on the display. If the Session ID is correct the manager +should open a connection; otherwise, it should respond with a +<function>Refuse</function> +or +<function>Failed</function> +packet, unless the Session ID matches a currently +running session or a session that has not yet successfully opened the +display but has not given up the attempt. In this latter case, the +<function>Manage</function> +packet should be ignored. +This will work as stream connections give positive success indication +to both halves of the stream, and positive failure indication +to the connection initiator (which will eventually generate a +<function>Failed</function> +packet). + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry spanname="col2_on"> +Valid Responses: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +X connection with correct auth info, +<function>Refuse ,</function> +<function>Failed .</function> + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry spanname="col2_on"> +Problems/Solutions: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +Problem: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +<function>Manage</function> +not received by manager. + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Indication: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col5_on"> +Display timeout waiting for response. + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Solution: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col5_on"> +Display resends +<function>Manage</function> +message. + </entry> + </row> + + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +Problem: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +<function>Manage</function> +received out of order by manager. + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Indication: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col5_on"> +Session already in progress with matching Session ID. + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Solution: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col5_on"> +<function>Manage</function> +packet ignored. + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Indication: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col5_on"> +Session ID does not match next Session ID. + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Solution: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col5_on"> +<function>Refuse</function> +message is sent. + </entry> + </row> + + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +Problem: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Display cannot be opened on selected stream. + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Indication: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col5_on"> +Display connection setup fails. + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Solution: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col5_on"> +<function>Failed</function> +message is sent including a human readable reason. + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +Problem: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Display open does not succeed before a second manage packet is received +because of a timeout occuring in the display. + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Indication: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col5_on"> +<function>Manage</function> +packet received with Session ID matching the session +attempting to connect to the display. + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Solution: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col5_on"> +<function>Manage</function> +packet is ignored. As the stream connection will either +succeed, which will result in an active session, or the stream will +eventually give up hope of connecting and send a +<function>Failed</function> +packet; no response to this +<function>Manage</function> +packet is necessary. + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry spanname="col2_on"> +Timeout/Retransmission policy: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +Timeout after 2 seconds, exponential backoff to 32 seconds. After no more +than 126 seconds, give up and report an error to the user. + </entry> + </row> + + <row rowsep="0"> + <entry spanname="col1_on"> +<function>Refuse</function> + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry spanname="col2_on"> + <para> +Manager -> Display + </para> + <para> +Additional Fields: + </para> + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +<emphasis remap='I'>Session ID</emphasis>: CARD32 + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Should be set to the Session ID received in the +<function>Manage</function> +packet. + </entry> + </row> + + + <row rowsep="0"> + <entry></entry> + <entry spanname="col2_on"> +Semantics: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +A +<function>Refuse</function> +packet is sent by a manager when the Session ID received in the +<function>Manage</function> +packet does not match the current Session ID. +The display should assume that it received an old +<function>Accept</function> +packet and should resend its +<function>Request</function> +packet. + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry spanname="col2_on"> +Problems/Solutions: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +Problem: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Error message is lost. + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Indication: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col5_on"> +Display times out waiting for +new connection, +<function>Refuse</function> +or +<function>Failed .</function> + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Solution: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col5_on"> +Display resends +<function>Manage</function> +message. + </entry> + </row> + + + + <row rowsep="0"> + <entry></entry> + <entry spanname="col2_on"> +Timeout/Retransmission policy: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +Like all packets sent from a manager to a display, this packet should never be +retransmitted. + </entry> + </row> + + <row rowsep="0"> + <entry spanname="col1_on"> +<function>Failed</function> + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry spanname="col2_on"> + <para> +Manager -> Display + </para> + <para> +Additional Fields: + </para> + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +<emphasis remap='I'>Session ID</emphasis>: CARD32 + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Should be set to the Session ID received in the +<function>Manage</function> +packet. + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +<emphasis remap='I'>Status</emphasis>: ARRAY8 + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Is a human readable string indicating the reason for failure. + </entry> + </row> + + + <row rowsep="0"> + <entry></entry> + <entry spanname="col2_on"> +Semantics: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +A +<function>Failed</function> +packet is sent by a manager when it has problems establishing +the initial X connection in response to the +<function>Manage</function> +packet. + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry spanname="col2_on"> +Problems/Solutions + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +Same as for +<function>Refuse .</function> + </entry> + </row> + + <row rowsep="0"> + <entry spanname="col1_on"> +<function>KeepAlive</function> + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry spanname="col2_on"> + <para> +Display -> Manager + </para> + <para> +Additional Fields: + </para> + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +<emphasis remap='I'>Display Number</emphasis>: CARD16 + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Set to the display index for the display host. + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +<emphasis remap='I'>Session ID</emphasis>: CARD32 + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Should be set to the Session ID received in the +<function>Manage</function> +packet during the negotiation for the current session. + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry spanname="col2_on"> +Sematics: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> + <para> +A +<function>KeepAlive</function> +packet can be sent at any time during the session by a +display to discover if the manager is running. +The manager should respond with +<function>Alive</function> +whenever it receives this type of packet. + </para> + <para> +This allows the display to discover when the manager host +is no longer running. +A display is not required to send +<function>KeepAlive</function> +packets and, upon lack of receipt of +<function>Alive</function> +packets, is not required to perform any specific action. + </para> + <para> +The expected use of this packet is to terminate an active session when the +manager host or network link fails. The display should keep track of the +time since any packet has been received from the manager host and use +<function>KeepAlive</function> +packets when a substantial time has elapsed since the +most recent packet. + </para> + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry spanname="col2_on"> +Valid Responses: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +<function>Alive</function> + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry spanname="col2_on"> +Problems/Solutions: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +Problem: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Manager does not receive the packet or display does not receive the response. + </entry> + </row> + + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Indication: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col5_on"> +No +<function>Alive</function> +packet is returned. + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Solution: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col5_on"> +Retransmit the packet with an exponential backoff; start at 2 seconds and +assume the host is not up after no less than 30 seconds. + </entry> + </row> + + <row rowsep="0"> + <entry spanname="col1_on"> +<function>Alive</function> + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry spanname="col2_on"> + <para> +Manager -> Display + </para> + <para> +Additional Fields: + </para> + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +<emphasis remap='I'>Session Running</emphasis>: CARD8 + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Indicates that the session identified by Session ID is +currently active. The value is zero if no session is active +or one if a session +is active. + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +<emphasis remap='I'>Session ID</emphasis>: CARD32 + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry></entry> + <entry spanname="col4_on"> +Specifies the ID of the currently running session; if any. +When no session is active this field should be zero. + </entry> + </row> + + + <row rowsep="0"> + <entry></entry> + <entry spanname="col2_on"> +Semantics: + </entry> + </row> + + <row rowsep="0"> + <entry></entry> + <entry></entry> + <entry spanname="col3_on"> +An +<function>Alive</function> +packet is sent in response to a +<function>KeepAlive</function> +request. +If a session is currently active on the display, the manager includes the +Session ID in the packet. The display can use this information to +determine the status of the manager. + </entry> + </row> + </tbody> + </tgroup> +</informaltable> + +</sect1> + +<sect1 id="Session_Termination"> +<title>Session Termination</title> +<para> +When the session is over, the initial connection with the display (the one +that acknowledges the +<function>Manage</function> +packet) will be closed by the manager. +If only a single session was active on the display, +all other connections should be closed by the display +and the display should be reset. If multiple sessions +are active simultaneously and the display can identify which connections +belong to the terminated sesssion, those connections should be closed. +Otherwise, all connections should be closed and the display reset only when +all sessions have been terminated (that is, all initial connections closed). +</para> + +<para> +The session may also be terminated at any time by the display if the +managing host no longer responds to +<function>KeepAlive</function> +packets. +The exact time-outs for sending +<function>KeepAlive</function> +packets is not specified in this protocol as the trade off +should not be fixed between loading an otherwise idle system with spurious +<function>KeepAlive</function> +packets and not noticing that the manager host is down for a long time. +</para> +</sect1> + +<sect1 id="State_Diagrams"> +<title>State Diagrams</title> +<!-- .XS --> +<!-- (SN State Diagrams --> +<!-- .XE --> +<para> +<!-- .LP --> +The following state diagrams are designed to cover all actions of both +the display and the manager. Any packet that is received out-of-sequence +will be ignored. +</para> +<para> +<!-- .LP --> +Display: +</para> + +<variablelist> + <varlistentry> + <term><emphasis remap='I'>start</emphasis>:</term> + <listitem> + <para> +User-requested connect to one host -> <emphasis remap='I'>query</emphasis> + </para> + <para> +User-requested connect to some host -> <emphasis remap='I'>broadcast</emphasis> + </para> + <para> +User-requested connect to site host-list -> <emphasis remap='I'>indirect</emphasis> + </para> + </listitem> + </varlistentry> + <varlistentry> + <term><emphasis remap='I'>query</emphasis>:</term> + <listitem> + <para> +Send <function>Query</function> packet +-> <emphasis remap='I'>collect-query</emphasis> + </para> + </listitem> + </varlistentry> + <varlistentry> + <term><emphasis remap='I'>collect-query</emphasis>:</term> + <listitem> + <para> +Receive <function>Willing</function> -> +<emphasis remap='I'>start-connection</emphasis> + </para> + <para> +Receive <function>Unwilling</function> -> +<emphasis remap='I'>stop-connection</emphasis> + </para> + <para> +Timeout -> <emphasis remap='I'>query</emphasis> + </para> + </listitem> + </varlistentry> + + <varlistentry> + <term><emphasis remap='I'>broadcast</emphasis>:</term> + <listitem> + <para> +Send <function>BroadcastQuery</function> packet + </para> + <para> +-> <emphasis remap='I'>collect-broadcast-query</emphasis> + </para> + </listitem> + </varlistentry> + <varlistentry> + <term><emphasis remap='I'>collect-broadcast-query</emphasis>:</term> + <listitem> + <para> +Receive <function>Willing</function> -> +<emphasis remap='I'>update-broadcast-willing</emphasis> + </para> + <para> +User-requested connect to one host -> +<emphasis remap='I'>start-connection</emphasis> + </para> + <para> +Timeout -> <emphasis remap='I'>broadcast</emphasis> + </para> + </listitem> + </varlistentry> + <varlistentry> + <term><emphasis remap='I'>update-broadcast-willing</emphasis>:</term> + <listitem> + <para> +Add new host to the host list presented to the user + </para> + <para> +-> <emphasis remap='I'>collect-broadcast-query</emphasis> + </para> + </listitem> + </varlistentry> + <varlistentry> + <term><emphasis remap='I'>indirect</emphasis>:</term> + <listitem> + <para> +Send <function>IndirectQuery</function> packet + </para> + <para> +-> <emphasis remap='I'>collect-indirect-query</emphasis> + </para> + </listitem> + </varlistentry> + <varlistentry> + <term><emphasis remap='I'>collect-indirect-query</emphasis>:</term> + <listitem> + <para> +Receive <function>Willing</function> -> +<emphasis remap='I'>update-indirect-willing</emphasis> + </para> + <para> +User-requested connect to one host -> +<emphasis remap='I'>start-connection</emphasis> + </para> + <para> +Timeout -> <emphasis remap='I'>indirect</emphasis> + </para> + </listitem> + </varlistentry> + <varlistentry> + <term><emphasis remap='I'>update-indirect-willing</emphasis>:</term> + <listitem> + <para> +Add new host to the host list presented to the user + </para> + <para> +-> <emphasis remap='I'>collect-indirect-query</emphasis> + </para> + </listitem> + </varlistentry> + + <varlistentry> + <term><emphasis remap='I'>start-connection</emphasis>:</term> + <listitem> + <para> +Send <function>Request</function> packet + </para> + <para> +-> <emphasis remap='I'>await-request-response</emphasis> + </para> + </listitem> + </varlistentry> + <varlistentry> + <term><emphasis remap='I'>await-request-response</emphasis>:</term> + <listitem> + <para> +Receive <function>Accept</function> -> +<emphasis remap='I'>manage</emphasis> + </para> + <para> +Receive <function>Decline</function> -> +<emphasis remap='I'>stop-connection</emphasis> + </para> + <para> +Timeout -> <emphasis remap='I'>start-connection</emphasis> + </para> + </listitem> + </varlistentry> + <varlistentry> + <term><emphasis remap='I'>manage</emphasis>:</term> + <listitem> + <para> +Save Session ID + </para> + <para> +Send <function>Manage</function> packet with Session ID + </para> + <para> +-> <emphasis remap='I'>await-manage-response</emphasis> + </para> + </listitem> + </varlistentry> + <varlistentry> + <term><emphasis remap='I'>await-manage-response</emphasis>:</term> + <listitem> + <para> +Receive <function>XOpenDisplay :</function> -> +<emphasis remap='I'>run-session</emphasis> + </para> + <para> +Receive <function>Refuse</function> with matching Session ID +-> <emphasis remap='I'>start-connection</emphasis> + </para> + <para> +Receive <function>Failed</function> with matching Session ID +-> <emphasis remap='I'>stop-connection</emphasis> + </para> + <para> +Timeout -> <emphasis remap='I'>manage</emphasis> + </para> + </listitem> + </varlistentry> + <varlistentry> + <term><emphasis remap='I'>stop-connection</emphasis>:</term> + <listitem> + <para> +Display cause of termination to user + </para> + <para> +-> <emphasis remap='I'>start</emphasis> + </para> + </listitem> + </varlistentry> + <varlistentry> + <term><emphasis remap='I'>run-session</emphasis>:</term> + <listitem> + <para> +Decide to send <function>KeepAlive</function> packet -> +<emphasis remap='I'>keep-alive</emphasis> + </para> + <para> +wait close of first display connection + </para> + <para> +-> <emphasis remap='I'>reset-display</emphasis> + </para> + </listitem> + </varlistentry> + <varlistentry> + <term><emphasis remap='I'>keep-alive</emphasis>:</term> + <listitem> + <para> +Send <function>KeepAlive</function> packet with current Session ID + </para> + <para> +-> <emphasis remap='I'>await-alive</emphasis> + </para> + </listitem> + </varlistentry> + <varlistentry> + <term><emphasis remap='I'>await-alive</emphasis>:</term> + <listitem> + <para> +Receive <function>Alive</function> with matching Session ID -> +<emphasis remap='I'>run-session</emphasis> + </para> + <para> +Receive <function>Alive</function> with nonmatching Session ID +or FALSE Session Running -> <emphasis remap='I'>reset-display</emphasis> + </para> + <para> +Final timeout without receiving <function>Alive</function> +packet -> <emphasis remap='I'>reset-display</emphasis> + </para> + <para> +Timeout -> <emphasis remap='I'>keep-alive</emphasis> + </para> + </listitem> + </varlistentry> + <varlistentry> + <term><emphasis remap='I'>reset-display</emphasis>:</term> + <listitem> + <para> +(if possible) -> close all display connections associated with this session + </para> + <para> +Last session -> close all display connections + </para> + <para> +-> <emphasis remap='I'>start</emphasis> + </para> + </listitem> + </varlistentry> +</variablelist> + + +<para> +Manager: +</para> + +<variablelist> + <varlistentry> + <term><emphasis remap='I'>idle</emphasis>:</term> + <listitem> + <para> +Receive <function>Query</function> -> +<emphasis remap='I'>query-respond</emphasis> + </para> + <para> +Receive +<function>BroadcastQuery</function> +-> <emphasis remap='I'>broadcast-respond</emphasis> + </para> + <para> +Receive +<function>IndirectQuery</function> +-> <emphasis remap='I'>indirect-respond</emphasis> + </para> + <para> +Receive +<function>ForwardQuery</function> +-> <emphasis remap='I'>forward-respond</emphasis> +Receive + </para> + <para> +<function>Request</function> +-> <emphasis remap='I'>request-respond</emphasis> + </para> + <para> +Receive +<function>Manage</function> +-> <emphasis remap='I'>manage</emphasis> + </para> + <para> +An active session terminates +-> <emphasis remap='I'>finish-session</emphasis> + </para> + <para> +Receive <function>KeepAlive</function> +-> <emphasis remap='I'>send-alive</emphasis> + </para> + <para> +-> <emphasis remap='I'>idle</emphasis> + </para> + </listitem> + </varlistentry> + <varlistentry> + <term><emphasis remap='I'>query-respond</emphasis>:</term> + <listitem> + <para> +If willing to manage -> <emphasis remap='I'>send-willing</emphasis> + </para> + <para> +-> <emphasis remap='I'>send-unwilling</emphasis> + </para> + </listitem> + </varlistentry> + <varlistentry> + <term><emphasis remap='I'>broadcast-respond</emphasis>:</term> + <listitem> + <para> +If willing to manage -> <emphasis remap='I'>send-willing</emphasis> + </para> + <para> +-> <emphasis remap='I'>idle</emphasis> + </para> + </listitem> + </varlistentry> + <varlistentry> + <term><emphasis remap='I'>indirect-respond</emphasis>:</term> + <listitem> + <para> +Send <function>ForwardQuery</function> +packets to all managers on redirect list + </para> + <para> +If willing to manage -> <emphasis remap='I'>send-willing</emphasis> + </para> + <para> +-> <emphasis remap='I'>idle</emphasis> + </para> + </listitem> + </varlistentry> + <varlistentry> + <term><emphasis remap='I'>forward-respond</emphasis>:</term> + <listitem> + <para> +Decode destination address, if willing to manage -> +<emphasis remap='I'>send-willing</emphasis> + </para> + <para> +-> <emphasis remap='I'>idle</emphasis> + </para> + </listitem> + </varlistentry> + <varlistentry> + <term><emphasis remap='I'>send-willing</emphasis>:</term> + <listitem> + <para> +Send <function>Willing</function> packet + </para> + <para> +-> <emphasis remap='I'>idle</emphasis> + </para> + </listitem> + </varlistentry> + <varlistentry> + <term><emphasis remap='I'>send-unwilling</emphasis>:</term> + <listitem> + <para> +Send <function>Unwilling</function> packet +-> <emphasis remap='I'>idle</emphasis> + </para> + </listitem> + </varlistentry> + <varlistentry> + <term><emphasis remap='I'>request-respond</emphasis>:</term> + <listitem> + <para> +If manager is willing to allow a session on display +-> <emphasis remap='I'>accept-session</emphasis> + </para> + <para> +-> <emphasis remap='I'>decline-session</emphasis> + </para> + </listitem> + </varlistentry> + <varlistentry> + <term><emphasis remap='I'>accept-session</emphasis>:</term> + <listitem> + <para> +Generate Session ID and save Session ID, display address, and +display number somewhere + </para> + <para> +Send <function>Accept</function> packet + </para> + <para> +-> <emphasis remap='I'>idle</emphasis> + </para> + </listitem> + </varlistentry> + <varlistentry> + <term><emphasis remap='I'>decline-session</emphasis>:</term> + <listitem> + <para> +Send <function>Decline</function> packet + </para> + <para> +-> <emphasis remap='I'>idle</emphasis> + </para> + </listitem> + </varlistentry> + <varlistentry> + <term><emphasis remap='I'>manage</emphasis>:</term> + <listitem> + <para> +If Session ID matches saved Session ID -> +<emphasis remap='I'>run-session</emphasis> + </para> + <para> +If Session ID matches Session ID of session in process of +starting up, or currently active session -> +<emphasis remap='I'>idle</emphasis> + </para> + <para> +-> <emphasis remap='I'>refuse</emphasis> + </para> + </listitem> + </varlistentry> + <varlistentry> + <term><emphasis remap='I'>refuse</emphasis>:</term> + <listitem> + <para> +Send <function>Refuse</function> packet + </para> + <para> +-> <emphasis remap='I'>idle</emphasis> + </para> + </listitem> + </varlistentry> + <varlistentry> + <term><emphasis remap='I'>run-session</emphasis>:</term> + <listitem> + <para> +Terminate any session in progress + </para> + <para> +<function>XOpenDisplay</function> + </para> + <para> +Open display succeeds -> +<emphasis remap='I'>start-session</emphasis> + </para> + <para> +-> <emphasis remap='I'>failed</emphasis> + </para> + </listitem> + </varlistentry> + <varlistentry> + <term><emphasis remap='I'>failed</emphasis>:</term> + <listitem> + <para> +Send <function>Failed</function> packet + </para> + <para> +-> <emphasis remap='I'>idle</emphasis> + </para> + </listitem> + </varlistentry> + <varlistentry> + <term><emphasis remap='I'>start-session</emphasis>:</term> + <listitem> + <para> +Start a new session + </para> + <para> +-> <emphasis remap='I'>idle</emphasis> + </para> + </listitem> + </varlistentry> + <varlistentry> + <term><emphasis remap='I'>finish-session</emphasis>:</term> + <listitem> + <para> +<function>XCloseDisplay</function> + </para> + <para> +-> <emphasis remap='I'>idle</emphasis> + </para> + </listitem> + </varlistentry> + <varlistentry> + <term><emphasis remap='I'>send-alive</emphasis>:</term> + <listitem> + <para> +Send <function>Alive</function> packet containing current status + </para> + <para> +-> <emphasis remap='I'>idle</emphasis> + </para> + </listitem> + </varlistentry> +</variablelist> + +</sect1> + +<sect1 id="Protocol_Encoding"> +<title>Protocol Encoding</title> +<para> +When XDMCP is implemented on top of the Internet User Datagram Protocol (UDP), +port number 177 is to be used. When using UDP over IPv4, Broadcast Query +packets are sent via UDP broadcast. When using UDP over IPv6, Broadcast Query +packets are sent via multicast, either to an address in the IANA registered +XDMCP multicast address range of +FF0<emphasis remap='I'>X</emphasis>:0:0:0:0:0:0:12B +(where the <emphasis remap='I'>X</emphasis> is replaced by a valid scope id) +or to a locally assigned +multicast address. The version number in all packets will be 1. +Packet opcodes are 16-bit integers. +</para> + +<informaltable frame="none"> + <tgroup cols='2' align='left'> + <colspec colname='c1' colsep="0"/> + <colspec colname='c2' colsep="0"/> + <thead> + <row> + <entry>Packet Name</entry> + <entry>Encoding</entry> + </row> + </thead> + <tbody> + <row rowsep="0"> + <entry>BroadcastQuery</entry> + <entry>1</entry> + </row> + <row rowsep="0"> + <entry>Query</entry> + <entry>2</entry> + </row> + <row rowsep="0"> + <entry>IndirectQuery</entry> + <entry>3</entry> + </row> + <row rowsep="0"> + <entry>ForwardQuery</entry> + <entry>4</entry> + </row> + <row rowsep="0"> + <entry>Willing</entry> + <entry>5</entry> + </row> + <row rowsep="0"> + <entry>Unwilling</entry> + <entry>6</entry> + </row> + <row rowsep="0"> + <entry>Request</entry> + <entry>7</entry> + </row> + <row rowsep="0"> + <entry>Accept</entry> + <entry>8</entry> + </row> + <row rowsep="0"> + <entry>Decline</entry> + <entry>9</entry> + </row> + <row rowsep="0"> + <entry>Manage</entry> + <entry>10</entry> + </row> + <row rowsep="0"> + <entry>Refuse</entry> + <entry>11</entry> + </row> + <row rowsep="0"> + <entry>Failed</entry> + <entry>12</entry> + </row> + <row rowsep="0"> + <entry>KeepAlive</entry> + <entry>13 +<footnote><para> +A previous version of this document incorrectly reversed the opcodes of +<emphasis role="bold">Alive</emphasis> and +<emphasis role="bold">KeepAlive</emphasis>. +</para></footnote> + </entry> + </row> + <row rowsep="0"> + <entry>Alive</entry> + <entry>14 +<footnote><para> +A previous version of this document incorrectly reversed the opcodes of +<emphasis role="bold">Alive</emphasis> and +<emphasis role="bold">KeepAlive</emphasis>. +</para></footnote> + </entry> + </row> + </tbody> + </tgroup> +</informaltable> + +<para> +Per packet information follows: +</para> + +<para> +<function>Query</function>, +<function>BroadcastQuery</function>, +<function>IndirectQuery</function> +</para> + +<literallayout class="monospaced"> + 2 CARD16 version number (always 1) + 2 CARD16 opcode (always Query, BroadcastQuery or IndirectQuery) + 2 CARD16 length + 1 CARD8 number of Authentication Names sent (m) + 2 CARD16 length of first Authentication Name (m<emphasis role="subscript">1</emphasis>) + m<emphasis role="subscript">1</emphasis> CARD8 first Authentication Name + ... Other Authentication Names +</literallayout> + +<para> +Note that these three packets are identical except for the opcode field. +</para> + +<literallayout class="monospaced"> +<function>ForwardQuery</function> + 2 CARD16 version number (always 1) + 2 CARD16 opcode (always ForwardQuery) + 2 CARD16 length + 2 CARD16 length of Client Address (m) + m CARD8 Client Address + 2 CARD16 length of Client Port (n) + n CARD8 Client Port + 1 CARD8 number of Authentication Names sent (o) + 2 CARD16 length of first Authentication Name (o<emphasis role="subscript">1</emphasis>) + o<emphasis role="subscript">1</emphasis> CARD8 first Authentication Name + ... Other Authentication Names +</literallayout> + +<literallayout class="monospaced"> +<function>Willing</function> + 2 CARD16 version number (always 1) + 2 CARD16 opcode (always Willing) + 2 CARD16 length (6 + m + n + o) + 2 CARD16 Length of Authentication Name (m) + m CARD8 Authentication Name + 2 CARD16 Hostname length (n) + n CARD8 Hostname + 2 CARD16 Status length (o) + o CARD8 Status +</literallayout> + +<literallayout class="monospaced"> +<function>Unwilling</function> + 2 CARD16 version number (always 1) + 2 CARD16 opcode (always Unwilling) + 2 CARD16 length (4 + m + n) + 2 CARD16 Hostname length (m) + m CARD8 Hostname + 2 CARD16 Status length (n) + n CARD8 Status +</literallayout> + +<literallayout class="monospaced"> +<function>Request</function> + 2 CARD16 version number (always 1) + 2 CARD16 opcode (always Request) + 2 CARD16 length + 2 CARD16 Display Number + 1 CARD8 Count of Connection Types (m) + 2xm CARD16 Connection Types + 1 CARD8 Count of Connection Addresses (n) + 2 CARD16 Length of first Connection Address (n<emphasis role="subscript">1</emphasis>) + n<emphasis role="subscript">1</emphasis> CARD8 First Connection Address + ... Other connection addresses + 2 CARD16 Length of Authentication Name (o) + o CARD8 Authentication Name + 2 CARD16 Length of Authentication Data (p) + p CARD8 Authentication Data + 1 CARD8 Count of Authorization Names (q) + 2 CARD16 Length of first Authorization Name (q<emphasis role="subscript">1</emphasis>) + q<emphasis role="subscript">1</emphasis> CARD8 First Authorization Name + ... Other authorization names + 2 CARD16 Length of Manufacturer Display ID (r) + r CARD8 Manufacturer Display ID +</literallayout> + +<literallayout class="monospaced"> +<function>Accept</function> + 2 CARD16 version number (always 1) + 2 CARD16 opcode (always Accept) + 2 CARD16 length (12 + n + m + o + p) + 4 CARD32 Session ID + 2 CARD16 Length of Authentication Name (n) + n CARD8 Authentication Name + 2 CARD16 Length of Authentication Data (m) + m CARD8 Authentication Data + 2 CARD16 Length of Authorization Name (o) + o CARD8 Authorization Name + 2 CARD16 Length of Authorization Data (p) + p CARD8 Authorization Data +</literallayout> + +<literallayout class="monospaced"> +<function>Decline</function> + 2 CARD16 version number (always 1) + 2 CARD16 opcode (always Decline) + 2 CARD16 length (6 + m + n + o) + 2 CARD16 Length of Status (m) + m CARD8 Status + 2 CARD16 Length of Authentication Name (n) + n CARD8 Authentication Name + 2 CARD16 Length of Authentication Data (o) + o CARD8 Authentication Data +</literallayout> + +<literallayout class="monospaced"> +<function>Manage</function> + 2 CARD16 version number (always 1) + 2 CARD16 opcode (always Manage) + 2 CARD16 length (8 + m) + 4 CARD32 Session ID + 2 CARD16 Display Number + 2 CARD16 Length of Display Class (m) + m CARD8 Display Class +</literallayout> + +<literallayout class="monospaced"> +<function>Refuse</function> + 2 CARD16 version number (always 1) + 2 CARD16 opcode (always Refuse) + 2 CARD16 length (4) + 4 CARD32 Session ID +</literallayout> + +<literallayout class="monospaced"> +<function>Failed</function> + 2 CARD16 version number (always 1) + 2 CARD16 opcode (always Failed) + 2 CARD16 length (6 + m) + 4 CARD32 Session ID + 2 CARD16 Length of Status (m) + m CARD8 Status +</literallayout> + +<literallayout class="monospaced"> +<function>KeepAlive</function> + 2 CARD16 version number (always 1) + 2 CARD16 opcode (always KeepAlive) + 2 CARD16 length (6) + 2 CARD16 Display Number + 4 CARD32 Session ID +</literallayout> + +<literallayout class="monospaced"> +<function>Alive</function> + 2 CARD16 version number (always 1) + 2 CARD16 opcode (always Alive) + 2 CARD16 length (5) + 1 CARD8 Session Running (0: not running 1: running) + 4 CARD32 Session ID (0: not running) +</literallayout> +</sect1> + +<sect1 id="Display_Class_Format"> +<title>Display Class Format</title> +<!-- .XS --> +<!-- (SN Display Class Format --> +<!-- .XE --> +<para> +The Display Class field of the +<function>Manage</function> +packet is used by the display manager to collect common sorts of +displays into manageable groups. This field is a string encoded of +ISO-LATIN-1 characters in the following format: +</para> + +<literallayout class="monospaced"> +<emphasis remap='I'>ManufacturerID</emphasis>-<emphasis remap='I'>ModelNumber</emphasis> +</literallayout> + +<para> +Both elements of this string must exclude characters of the set +{ <function>-</function>, +<function>.</function>, +<function>:</function>, +<function>*</function>, +<function>?</function>, +<emphasis remap='I'><space></emphasis> }. +The ManufacturerID is a string that should be registered +with the X Consortium. +The ModelNumber is designed to identify characteristics of the display +within the manufacturer's product line. +This string should be documented in the users manual for the +particular device and should probably not be specifiable by the +display user to avoid unexpected configuration errors. +</para> +</sect1> + +<sect1 id="Manufacturer_Display_ID_Format"> +<title>Manufacturer Display ID Format</title> +<!-- .XS --> +<!-- (SN Manufacturer Display ID Format --> +<!-- .XE --> +<para> +To authenticate the manager, the display and manager will share a private +key. +The manager, then, must be able to discover which key to use for a +particular device. +The Manufacturer Display ID field of the +<function>Request</function> +packet is intended for this purpose. Typically, the manager host will +contain a map between this number and the key. This field is intended to be +unique per display, possibly the ethernet address of the display in the form: +</para> + +<literallayout class="monospaced"> +-Ethernet-8:0:2b:a:f:d2 +</literallayout> + +<para> +It can also be a string of the form: +</para> + +<literallayout class="monospaced"> +<emphasis remap='I'>ManufacturerID</emphasis>-<emphasis remap='I'>ModelNumber</emphasis>-<emphasis remap='I'>SerialNumber</emphasis> +</literallayout> + +<para> +The ManufacturerID, ModelNumber and SerialNumber are encoded using +ISO-LATIN-1 characters, excluding { +<function>-</function>, +<function>.</function>, +<function>*</function>, +<function>?</function>, +<emphasis remap='I'><space></emphasis> } +</para> + +<para> +When the display is shipped to a customer, it should include both the +Manufacturer Display ID and the private key in the documentation set. +This information should not be modifiable by the display user. +</para> + +</sect1> + +<sect1 id="Authentication"> +<title>Authentication</title> +<!-- .XS --> +<!-- (SN Authentication --> +<!-- .XE --> +<para> +In an environment where authentication is not needed, XDMCP can disable +authentication by having the display send empty Authentication Name +and Authentication Data fields in the +<function>Request</function> +packet. +In this case, the manager will not attempt to authenticate itself. +Other authentication protocols may be developed, depending on local needs. +</para> + +<para> +In an unsecure environment, the display must be able to verify that the +source of the various packets is a trusted manager. These packets will +contain authentication information. As an example of such a system, the +following discussion describes the "XDM-AUTHENTICATION-1" authentication +system. This system uses a 56-bit shared private key, and 64 bits of +authentication data. An associated example X authorization protocol +"XDM-AUTHORIZATION-1" will also be discussed. The 56-bit key is represented +as a 64-bit number in network order (big endian). This means that the first +octet in the representation will be zero. When incrementing a 64-bit value, +the 8 octets of data will be interpreted in network order (big endian). +That is, the last octet will be incremented, subsequent carries propogate +towards the first octet. +</para> + +<para> +Assumptions: +</para> + +<orderedlist> + <listitem> + <para> +The display and manager share a private key. This key could be programmed +into the display by the manufacturer and shipped with the unit. It must not +be available from the display itself, but should allow the value to be +modified in some way. The system administrator would be responsible for +managing a database of terminal keys. + </para> + </listitem> + <listitem> + <para> +The display can generate random authentication numbers. + </para> + </listitem> +</orderedlist> + +<para> +Some definitions first: +</para> + +<!-- FIXME: --> +<!-- double chk math symbols, use mathml to display them? --> +<itemizedlist> + <listitem> + <para> +{D}= encryption of plain text D by key κ + </para> + </listitem> + <listitem> + <para> +{Δ}*κ = decryption of crypto text Δ with key κ + </para> + </listitem> + <listitem> + <para> +τ = private key shared by display and manager + </para> + </listitem> + <listitem> + <para> +ρ = 64 bit random number generated by display + </para> + </listitem> + <listitem> + <para> +α = authentication data in XDMCP packets + </para> + </listitem> + <listitem> + <para> +σ = per-session private key, generated by manager + </para> + </listitem> + <listitem> + <para> +β = authorization data + </para> + </listitem> +</itemizedlist> + +<para> +Encryption will use the Data Encryption Standard (DES, FIPS 46-3); blocks +shorter than 64 bits will be zero-filled +on the right to 64 bits. Blocks longer than 64 bits will use block chaining: +</para> +<para> +{D}κ = {D1 }κ {D2 xor {D1 }κ }κ +</para> + +<para> +The display generates the first authentication data in the +<function>Request</function> +packet: +</para> + +<para> +αRequest = {ρ}τ + +</para> + +<para> +For the <function>Accept</function> +packet, the manager decrypts the initial message and returns +αAccept: + +</para> + +<para> +ρ = {α Request } *τ +</para> + +<para> +α Accept = { ρ + 1}τ +</para> + +<para> +The <function>Accept</function> +packet also contains the authorization intended for use by +the X server. A description of authorization type "XDM-AUTHORIZATION-1" +follows. +</para> + +<para> +The <function>Accept</function> +packet contains the authorization name +"XDM-AUTHORIZATION-1". The authorization data is the string: +</para> +<para> +β Accept = {σ}τ +</para> + +<para> +To create authorization information for connection setup with the X server +using the XDM-AUTHORIZATION-1 authorization protocol, the client computes the +following: +</para> +<para> +N mark = "X client identifier" +</para> +<para> +T lineup = "Current time in seconds on client host (32 bits)" +</para> +<para> +β = {ρNT}σ +</para> + +<para> +For TCP connections @N@ is 48 bits long and contains the 32-bit IPv4 address of +the client host followed by the 16-bit port number of the client socket. +Formats for other connections must be registered. +The resulting value, β, is 192 bits of authorization data that is sent +in the connection setup to the server. The server receives the packet, +decrypts the contents. To accept the connection, the following must hold: +</para> + +<itemizedlist> + <listitem> + <para> +ρ must match the value generated for the most recent XDMCP negotiation. + </para> + </listitem> + <listitem> + <para> +T must be within 1200 seconds of the internally stored time. If no time +been received before, the current time is set to @T@. + </para> + </listitem> + <listitem> + <para> +No packet containing the same pair (N, T) can have been received +in the last 1200 seconds (20 minutes). + </para> + </listitem> +</itemizedlist> +</sect1> +</chapter> +</book> diff --git a/lib/libXdmcp/include/X11/Xdmcp.h b/lib/libXdmcp/include/X11/Xdmcp.h index 254848565..74ae4b3a0 100644 --- a/lib/libXdmcp/include/X11/Xdmcp.h +++ b/lib/libXdmcp/include/X11/Xdmcp.h @@ -1,5 +1,3 @@ -/* $XdotOrg: xc/lib/Xdmcp/Xdmcp.h,v 1.2 2004/04/23 18:43:41 eich Exp $ */ -/* $Xorg: Xdmcp.h,v 1.7 2001/04/13 14:43:00 steve Exp $ */ /* * Copyright 1989 Network Computing Devices, Inc., Mountain View, California. * @@ -14,7 +12,6 @@ * without express or implied warranty. * */ -/* $XFree86: xc/lib/Xdmcp/Xdmcp.h,v 3.7 2003/07/09 15:27:29 tsi Exp $ */ #ifndef _XDMCP_H_ #define _XDMCP_H_ @@ -121,14 +118,14 @@ typedef struct _XdmAuthKey { typedef char *XdmcpNetaddr; -extern int XdmcpWriteARRAY16(XdmcpBufferPtr buffer, ARRAY16Ptr array); -extern int XdmcpWriteARRAY32(XdmcpBufferPtr buffer, ARRAY32Ptr array); -extern int XdmcpWriteARRAY8(XdmcpBufferPtr buffer, ARRAY8Ptr array); -extern int XdmcpWriteARRAYofARRAY8(XdmcpBufferPtr buffer, ARRAYofARRAY8Ptr array); +extern int XdmcpWriteARRAY16(XdmcpBufferPtr buffer, const ARRAY16Ptr array); +extern int XdmcpWriteARRAY32(XdmcpBufferPtr buffer, const ARRAY32Ptr array); +extern int XdmcpWriteARRAY8(XdmcpBufferPtr buffer, const ARRAY8Ptr array); +extern int XdmcpWriteARRAYofARRAY8(XdmcpBufferPtr buffer, const ARRAYofARRAY8Ptr array); extern int XdmcpWriteCARD16(XdmcpBufferPtr buffer, unsigned value); extern int XdmcpWriteCARD32(XdmcpBufferPtr buffer, unsigned value); extern int XdmcpWriteCARD8(XdmcpBufferPtr buffer, unsigned value); -extern int XdmcpWriteHeader(XdmcpBufferPtr buffer, XdmcpHeaderPtr header); +extern int XdmcpWriteHeader(XdmcpBufferPtr buffer, const XdmcpHeaderPtr header); extern int XdmcpFlush(int fd, XdmcpBufferPtr buffer, XdmcpNetaddr to, int tolen); @@ -143,16 +140,16 @@ extern int XdmcpReadHeader(XdmcpBufferPtr buffer, XdmcpHeaderPtr header); extern int XdmcpFill(int fd, XdmcpBufferPtr buffer, XdmcpNetaddr from, int *fromlen); -extern int XdmcpReadRemaining(XdmcpBufferPtr buffer); +extern int XdmcpReadRemaining(const XdmcpBufferPtr buffer); extern void XdmcpDisposeARRAY8(ARRAY8Ptr array); extern void XdmcpDisposeARRAY16(ARRAY16Ptr array); extern void XdmcpDisposeARRAY32(ARRAY32Ptr array); extern void XdmcpDisposeARRAYofARRAY8(ARRAYofARRAY8Ptr array); -extern int XdmcpCopyARRAY8(ARRAY8Ptr src, ARRAY8Ptr dst); +extern int XdmcpCopyARRAY8(const ARRAY8Ptr src, ARRAY8Ptr dst); -extern int XdmcpARRAY8Equal(ARRAY8Ptr array1, ARRAY8Ptr array2); +extern int XdmcpARRAY8Equal(const ARRAY8Ptr array1, const ARRAY8Ptr array2); extern void XdmcpGenerateKey (XdmAuthKeyPtr key); extern void XdmcpIncrementKey (XdmAuthKeyPtr key); @@ -167,13 +164,7 @@ extern void XdmcpUnwrap(unsigned char *input, unsigned char *wrapper, unsigned c #define FALSE 0 #endif -#if !defined(Xalloc) && !defined(xalloc) && !defined(Xrealloc) -extern void *Xalloc (unsigned long amount); -extern void *Xrealloc (void *old, unsigned long amount); -extern void Xfree(void *old); -#endif - -extern int XdmcpCompareKeys (XdmAuthKeyPtr a, XdmAuthKeyPtr b); +extern int XdmcpCompareKeys (const XdmAuthKeyPtr a, const XdmAuthKeyPtr b); extern int XdmcpAllocARRAY16 (ARRAY16Ptr array, int length); extern int XdmcpAllocARRAY32 (ARRAY32Ptr array, int length); |