Hello community,
here is the log from the commit of package xorg-x11-xtrans-devel for openSUSE:Factory
checked in at Wed Apr 7 13:15:35 CEST 2010.
--------
--- xorg-x11-xtrans-devel/xorg-x11-xtrans-devel.changes 2009-12-14 16:59:54.000000000 +0100
+++ /mounts/work_src_done/STABLE/xorg-x11-xtrans-devel/xorg-x11-xtrans-devel.changes 2010-04-04 16:14:21.000000000 +0200
@@ -1,0 +2,7 @@
+Sun Apr 4 16:05:52 CEST 2010 - sndirsch@suse.de
+
+- xtrans 1.2.5
+- adjusted p_xauth.diff
+- bumped version number to 7.5
+
+-------------------------------------------------------------------
calling whatdependson for head-i586
Old:
----
xtrans-1.2.4.tar.bz2
New:
----
xtrans-1.2.5.tar.bz2
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ xorg-x11-xtrans-devel.spec ++++++
--- /var/tmp/diff_new_pack.xzGk4K/_old 2010-04-07 13:15:26.000000000 +0200
+++ /var/tmp/diff_new_pack.xzGk4K/_new 2010-04-07 13:15:26.000000000 +0200
@@ -1,7 +1,7 @@
#
-# spec file for package xorg-x11-xtrans-devel (Version 7.4)
+# spec file for package xorg-x11-xtrans-devel (Version 7.5)
#
-# Copyright (c) 2009 SUSE LINUX Products GmbH, Nuernberg, Germany.
+# Copyright (c) 2010 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
@@ -20,9 +20,9 @@
Name: xorg-x11-xtrans-devel
Url: http://xorg.freedesktop.org/
-%define tarball_version 1.2.4
-Version: 7.4
-Release: 7
+%define tarball_version 1.2.5
+Version: 7.5
+Release: 1
License: MIT License (or similar)
BuildRoot: %{_tmppath}/%{name}-%{version}-build
Group: Development/Libraries/X11
@@ -53,7 +53,7 @@
%prep
%setup -n xtrans-%{tarball_version}
-%patch -p2
+%patch -p0
%build
#autoreconf -fi
@@ -75,7 +75,7 @@
%defattr(-,root,root)
%dir /usr/include/X11/Xtrans
/usr/include/X11/Xtrans/*
-/usr/%{_lib}/pkgconfig/*.pc
+%{_datadir}/pkgconfig/*.pc
/usr/share/aclocal/*.m4
%changelog
++++++ p_xauth.diff ++++++
--- /var/tmp/diff_new_pack.xzGk4K/_old 2010-04-07 13:15:26.000000000 +0200
+++ /var/tmp/diff_new_pack.xzGk4K/_new 2010-04-07 13:15:26.000000000 +0200
@@ -1,21 +1,18 @@
---- lib/xtrans/Xtranssock.c 2005-11-30 11:35:05.000000000 +0100
-+++ lib/xtrans/Xtranssock.c 2006-03-28 12:11:36.000000000 +0200
-@@ -1804,6 +1804,7 @@
+--- Xtranssock.c.orig 2009-10-16 23:25:57.000000000 +0200
++++ Xtranssock.c 2010-04-04 16:10:29.000000000 +0200
+@@ -1790,12 +1790,15 @@
{
char hostnamebuf[256];
+ char* xauthlocalname = getenv("XAUTHLOCALHOSTNAME");
- #if defined(IPv6) && defined(AF_INET6)
- if (getaddrinfo == NULL)
-@@ -1816,6 +1817,10 @@
+ TRANS(GetHostname) (hostnamebuf, sizeof (hostnamebuf));
+
+ if (strcmp (hostnamebuf, host) == 0)
{
return (1);
- }
-+ else if(xauthlocalname && strcmp (xauthlocalname, host) == 0)
-+ {
++ } else if(xauthlocalname && strcmp (xauthlocalname, host) == 0) {
+ return (1);
-+ }
+ } else {
#if defined(IPv6) && defined(AF_INET6)
- else if (haveIPv6)
- {
+ struct addrinfo *localhostaddr;
++++++ xtrans-1.2.4.tar.bz2 -> xtrans-1.2.5.tar.bz2 ++++++
++++ 12571 lines of diff (skipped)
++++ retrying with extended exclude list
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/xtrans-1.2.4/ChangeLog new/xtrans-1.2.5/ChangeLog
--- old/xtrans-1.2.4/ChangeLog 2009-08-01 02:26:08.000000000 +0200
+++ new/xtrans-1.2.5/ChangeLog 2009-10-17 22:18:25.000000000 +0200
@@ -1,3 +1,76 @@
+commit 1127b8ec766ed8c48cc49b0779647fb697a07ebd
+Author: Alan Coopersmith
+Date: Sat Oct 17 13:14:03 2009 -0700
+
+ xtrans 1.2.5
+
+ Signed-off-by: Alan Coopersmith
+
+commit 628b125ff9c72ec93090005b06228690f0dd6004
+Author: Alan Coopersmith
+Date: Sat Oct 17 13:06:26 2009 -0700
+
+ Move Xtrans interface docs from xorg-docs module
+
+ Only built/installed if --enable-docs is requested, since few people should
+ be writing code using xtrans interfaces directly.
+
+ Signed-off-by: Alan Coopersmith
+
+commit 3b0fc7a5a6d4b4b6903a9ad6685e2441f9fe83a7
+Author: Alan Coopersmith
+Date: Thu Oct 15 17:07:10 2009 -0700
+
+ Migrate to xorg macros 1.3 & XORG_DEFAULT_OPTIONS
+
+ Signed-off-by: Alan Coopersmith
+
+commit 69334376346a96beb3df120a3eeeb7935923c388
+Author: Yaakov Selkowitz
+Date: Thu Oct 15 15:25:58 2009 -0500
+
+ Silence root ownership warnings on Cygwin
+
+ XWin need not be run as root, nor do Administrators have uid of 0.
+
+ Signed-off-by: Yaakov Selkowitz
+
+commit d009d995d85dc499dc3f1add34da551fdf703b60
+Author: Yaakov Selkowitz
+Date: Thu Oct 15 15:25:57 2009 -0500
+
+ Don't use -lws2_32 on Cygwin
+
+ On Cygwin, both the (builtin) *NIX socket API and WinSock (via w32api) are
+ available, but they cannot be mixed. We use *NIX APIs for everything else,
+ so we do not want to mix in WinSock here.
+
+ Signed-off-by: Yaakov Selkowitz
+
+commit 773478581913bafa5e98a7bff3260efb0c4f2ab6
+Author: Mikhail Gusarov
+Date: Sat Sep 26 04:39:20 2009 +0700
+
+ Move xtrans.pc to /usr/share/pkg-config
+
+ This fixes configuration in cross-compilation mode:
+ pkg-config does not look for .pc in /usr/lib/pkg-config during
+ cross-compilation to avoid picking up wrong libraries.
+
+ Signed-off-by: Mikhail Gusarov
+ Acked-by: Julien Cristau
+
+commit 336d4cfb58c784a81beca74fe03a0af0abb224ba
+Author: Julien Cristau
+Date: Fri Aug 7 16:58:58 2009 +0200
+
+ Xtranssock: assume that we have getaddrinfo if ipv6 is enabled
+
+ If IPv6 is enabled at build time, assume that the C library will have
+ getaddrinfo at runtime.
+
+ Signed-off-by: Alan Coopersmith
+
commit 4f82ca502d8ec33b0038700675d54539d85d723c
Author: Alan Coopersmith
Date: Fri Jul 31 17:24:25 2009 -0700
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/xtrans-1.2.4/INSTALL new/xtrans-1.2.5/INSTALL
--- old/xtrans-1.2.4/INSTALL 2009-08-01 02:25:53.000000000 +0200
+++ new/xtrans-1.2.5/INSTALL 2009-10-17 22:14:43.000000000 +0200
@@ -2,15 +2,15 @@
*************************
Copyright (C) 1994, 1995, 1996, 1999, 2000, 2001, 2002, 2004, 2005,
-2006 Free Software Foundation, Inc.
+2006, 2007, 2008, 2009 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
==================
-Briefly, the shell commands `./configure; make; make install' should
+ 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.
@@ -67,12 +67,15 @@
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
@@ -85,7 +88,7 @@
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 can use GNU `make'. `cd' to the
directory where you want the object files and executables to go and run
@@ -97,10 +100,24 @@
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'.
@@ -123,7 +140,7 @@
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
@@ -135,14 +152,46 @@
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 -D_XOPEN_SOURCE=500"
+
+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 `' 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"
+
+ On Solaris, don't put `/usr/ucb' early in your `PATH'. This
+directory contains several dysfunctional programs; working variants of
+these programs are available in `/usr/bin'. So, if you need `/usr/ucb'
+in your `PATH', put it _after_ `/usr/bin'.
+
+ On Haiku, software installed for all users goes in `/boot/common',
+not `/usr/local'. It is recommended to use the following options:
+
+ ./configure --prefix=/boot/common
+
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:
@@ -150,7 +199,8 @@
where SYSTEM can have one of these forms:
- OS KERNEL-OS
+ OS
+ KERNEL-OS
See the file `config.sub' for the possible values of each field. If
`config.sub' isn't included in this package, then this package doesn't
@@ -168,9 +218,9 @@
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.
@@ -179,7 +229,7 @@
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
@@ -198,11 +248,19 @@
`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'
@@ -229,6 +287,16 @@
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 -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/xtrans-1.2.4/Makefile.am new/xtrans-1.2.5/Makefile.am
--- old/xtrans-1.2.4/Makefile.am 2009-01-31 04:48:03.000000000 +0100
+++ new/xtrans-1.2.5/Makefile.am 2009-10-17 22:03:12.000000000 +0200
@@ -12,10 +12,10 @@
aclocaldir = $(datadir)/aclocal
aclocal_DATA = xtrans.m4
-pkgconfigdir = $(libdir)/pkgconfig
+pkgconfigdir = $(datadir)/pkgconfig
pkgconfig_DATA = xtrans.pc
-EXTRA_DIST = xtrans.pc.in ${aclocal_DATA} ChangeLog
+EXTRA_DIST = xtrans.pc.in ${aclocal_DATA} ChangeLog Xtrans.mm
MAINTAINERCLEANFILES = ChangeLog
@@ -25,3 +25,45 @@
$(CHANGELOG_CMD)
dist-hook: ChangeLog
+
+# Rules to convert documentation from troff to other formats
+doc_sources = Xtrans.mm
+
+if HAVE_PS2PDF
+printable_format = .pdf
+else
+printable_format = .ps
+endif
+
+if BUILD_DOCS
+doc_DATA = $(doc_sources:.mm=.txt) \
+ $(doc_sources:.mm=$(printable_format)) \
+ $(doc_sources:.mm=.html)
+
+CLEANFILES = $(doc_DATA)
+MOSTLYCLEANFILES = index.*
+
+# Pass version string as a troff string for substitution
+GROFF_DEFS = -dxV="$(PACKAGE_STRING)"
+
+# -t to run through tbl
+GROFF_FLAGS = -t -mm $(GROFF_DEFS)
+
+SUFFIXES = .mm .ps .txt .html .pdf
+
+.mm.ps:
+ -$(AM_V_GEN) $(GROFF) -Tps $(GROFF_FLAGS) $< 2> index.$@.raw > $@
+ @if grep '^[^1-9.]' index.$@.raw | grep -v warning; then exit 1; \
+ else test $$? -le 1; fi
+
+.mm.txt:
+ $(AM_V_GEN) env GROFF_NO_SGR=TRUE $(GROFF) -Tutf8 $(GROFF_FLAGS) \
+ $< 2> index.$@.raw > $@
+
+.mm.html:
+ $(AM_V_GEN) $(GROFF) -Thtml $(GROFF_FLAGS) $< 2> index.$@.raw > $@
+
+.ps.pdf:
+ $(AM_V_GEN) $(PS2PDF) $< $@
+
+endif BUILD_DOCS
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/xtrans-1.2.4/Xtrans.mm new/xtrans-1.2.5/Xtrans.mm
--- old/xtrans-1.2.4/Xtrans.mm 1970-01-01 01:00:00.000000000 +0100
+++ new/xtrans-1.2.5/Xtrans.mm 2009-10-16 23:37:57.000000000 +0200
@@ -0,0 +1,789 @@
+.\" $XFree86: xc/doc/specs/xtrans/Xtrans.mm,v 1.2 2003/07/09 15:27:27 tsi Exp $
+'\".nr Ej 1
+.PH "'''"
+.ce
+\fBX Transport Interface\fR
+.sp
+Copyright (c) 1993, 1994 NCR Corporation - Dayton, Ohio, USA
+.sp
+All Rights Reserved
+.sp
+Permission to use, copy, modify, and distribute this software and its
+documentation for any purpose and without fee is hereby granted, provided
+that the above copyright notice appear in all copies and that both that
+copyright notice and this permission notice appear in supporting
+documentation, and that the name NCR not be used in advertising
+or publicity pertaining to distribution of the software without specific,
+written prior permission. NCR makes no representations about the
+suitability of this software for any purpose. It is provided "as is"
+without express or implied warranty.
+.sp
+NCR DISCLAIM ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
+INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN
+NO EVENT SHALL NCR BE LIABLE FOR ANY SPECIAL, INDIRECT OR
+CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS
+OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT,
+NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN
+CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+.sp
+Copyright 1993, 1994, 2002 The Open Group
+.sp
+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:
+.sp
+The above copyright notice and this permission notice shall be included in
+all copies or substantial portions of the Software.
+.sp
+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.
+.sp
+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.
+.sp
+X Window System is a trademark of The Open Group, Inc.
+.sp
+Designed by Stuart Anderson (NCR) with help from Ralph Mor (X Consortium)
+.sp
+.ce
+\fIDraft Version 0.6\fR
+.sp
+NOTE: This documentation does not completely match the implementation in R6
+(as a result of some late changes made in the code). Specifically, support
+was added for font server cloning, and conditional compliation was introduced
+for client vs. server code.
+.bp
+.H 1 "Purposes and Goals"
+.P
+The X Transport Interface is intended to combine all system and transport
+specific code into a single place in the source tree. This API should be used
+by all libraries, clients and servers of the X Window System. Use of this API
+should allow the addition of new types of transports and support for new
+platforms without making any changes to the source except in the X Transport
+Interface code.
+.P
+This interface should solve the problem of multiple #ifdef TRANSPORT and
+#ifdef PLATFORM statements scattered throughout the source tree.
+.P
+This interface should provide enough functionality to support all types of
+protocols, including connection oriented protocols such as X11 and FS, and
+connection-less oriented protocols such as XDMCP.
+.H 1 "Overview of the interface"
+.P
+The interface provides an API for use by applications. The functions in this
+API perform work that is common to all transports and systems, such as
+parsing an address into a host and port number. The functions in this API
+call transport specific functions that are contained in a table whose
+contents are defined at compile time. This table contains an entry for each
+type of transport. Each entry is a record containing mostly pointers to
+function that implements the interface for the given transport.
+.P
+This API does not provide an abstraction for select() or poll().
+These function are themselves transport independent, so an additional interface
+is not needed for these functions. It is also unclear how such an interface
+would affect performance.
+.H 1 "Definition of Address Specification Format"
+.P
+Addresses are specified in the following syntax,
+.sp
+\fIprotocol/host:port\fR
+.sp
+where \fIprotocol\fR specifies a protocol family or an alias for a protocol
+family. A definition of common protocol families is given in a later section.
+.P
+The \fIhost\fR part specifies the name of a host or other transport dependent
+entity that could be interpreted as a Network Service Access Point (NSAP).
+.P
+The \fIport\fR part specifies the name of a Transport Service Access Point
+(TSAP). The format of the TSAP is defined by the underlying transport
+implementation, but it is represented using a string format when it is part
+of an address.
+.H 1 "Internal Data Structures"
+.P
+There are two major data structures associated with the transport independent
+portion of this interface. Additional data structures may be used internally
+by each transport.
+.H 2 "Xtransport"
+.P
+Each transport supported has an entry in the transport table.
+The transport table is an array of \fIXtransport\fR records. Each record
+contains all the entry points for a single transport. This record is defined as:
+.DS
+.nf
+typedef struct _Xtransport {
+
+ char *TransName;
+ int flags;
+
+ XtransConnInfo (*OpenCOTSClient)(
+ struct _Xtransport *, /* transport */
+ char *, /* protocol */
+ char *, /* host */
+ char * /* port */
+ );
+
+ XtransConnInfo (*OpenCOTSServer)(
+ struct _Xtransport *, /* transport */
+ char *, /* protocol */
+ char *, /* host */
+ char * /* port */
+ );
+
+ XtransConnInfo (*OpenCLTSClient)(
+ struct _Xtransport *, /* transport */
+ char *, /* protocol */
+ char *, /* host */
+ char * /* port */
+ );
+
+ XtransConnInfo (*OpenCLTSServer)(
+ struct _Xtransport *, /* transport */
+ char *, /* protocol */
+ char *, /* host */
+ char * /* port */
+ );
+
+ int (*SetOption)(
+ XtransConnInfo, /* connection */
+ int, /* option */
+ int /* arg */
+ );
+
+ int (*CreateListener)(
+ XtransConnInfo, /* connection */
+ char *, /* port */
+ int /* flags */
+ );
+
+ int (*ResetListener)(
+ XtransConnInfo /* connection */
+ );
+
+ XtransConnInfo (*Accept)(
+ XtransConnInfo /* connection */
+ );
+
+ int (*Connect)(
+ XtransConnInfo, /* connection */
+ char *, /* host */
+ char * /* port */
+ );
+
+ int (*BytesReadable)(
+ XtransConnInfo, /* connection */
+ BytesReadable_t * /* pend */
+ );
+
+ int (*Read)(
+ XtransConnInfo, /* connection */
+ char *, /* buf */
+ int /* size */
+ );
+
+ int (*Write)(
+ XtransConnInfo, /* connection */
+ char *, /* buf */
+ int /* size */
+ );
+
+ int (*Readv)(
+ XtransConnInfo, /* connection */
+ struct iovec *, /* buf */
+ int /* size */
+ );
+
+ int (*Writev)(
+ XtransConnInfo, /* connection */
+ struct iovec *, /* buf */
+ int /* size */
+ );
+
+ int (*Disconnect)(
+ XtransConnInfo /* connection */
+ );
+
+ int (*Close)(
+ XtransConnInfo /* connection */
+ );
+
+} Xtransport;
+
+.fi
+.DE
+.P
+The \fIflags\fR field can contain an OR of the following masks:
+.sp
+\fITRANS_ALIAS\fR: indicates that this record is providing an alias,
+and should not be used to create a listner.
+.sp
+\fITRANS_LOCAL\fR: indicates that this is a LOCALCONN transport.
+
+.H 2 "XtransConnInfo"
+.P
+Each connection will have an opaque \fIXtransConnInfo\fR transport connection
+object allocated for it. This record contains information specific to the
+connection. The record is defined
+as:
+.DS
+.nf
+typedef struct _XtransConnInfo *XtransConnInfo;
+
+struct _XtransConnInfo {
+ struct _Xtransport *transptr;
+ char *priv;
+ int flags;
+ int fd;
+ int family;
+ char *addr;
+ int addrlen;
+ char *peeraddr;
+ int peeraddrlen;
+};
+.fi
+.DE
+.H 1 "Exposed Transport Independent API"
+.P
+This API is included in each library and server that uses it. The API
+may be used by the library, but it is not added to the public API for that
+library. This interface is simply an implementation
+facilitator. This API contains a low level set of core primitives, and a few
+utility functions that are built on top of the primitives. The utility
+functions exist to provide a more familiar interface that can be used to
+port existing code.
+.P
+A macro is defined in Xtrans.h for TRANS(func) that creates a unique function
+name depending on where the code is compiled. For example, when built for Xlib,
+TRANS(OpenCOTSClient) becomes _X11TransOpenCOTSClient.
+.P
+All failures are considered fatal, and the connection should be closed and
+re-established if desired. In most cases, however, the value of errno will
+be available for debugging purposes.
+.H 2 "Core Interface API"
+.BL
+.LI
+XtransConnInfo
+TRANS(OpenCOTSClient)(char *address)
+.P
+This function creates a Connection-Oriented Transport that is suitable for
+use by a client.
+The parameter \fIaddress\fR contains the full address of the
+server to which this endpoint will be connected.
+This functions returns an opaque transport connection object on success,
+or NULL on failure.
+.LI
+XtransConnInfo
+TRANS(OpenCOTSServer)(char *address)
+.P
+This function creates a Connection-Oriented Transport that is suitable for
+use by a server.
+The parameter \fIaddress\fR contains the full address to which this
+server will be bound.
+This functions returns an opaque transport connection object on success,
+or NULL on failure.
+.LI
+XtransConnInfo
+TRANS(OpenCLTSClient)(char *address)
+.P
+This function creates a Connection-Less Transport that is suitable for
+use by a client.
+The parameter \fIaddress\fR contains the full address of the
+server to which this endpoint will be connected.
+This functions returns an opaque transport connection object on success,
+or NULL on failure.
+.LI
+XtransConnInfo
+TRANS(OpenCLTSServer)(char *address)
+.P
+This function creates a Connection-Less Transport that is suitable for
+use by a server.
+The parameter \fIaddress\fR contains the full address to which this
+server will be bound.
+This functions returns an opaque transport connection object on success,
+or NULL on failure.
+.LI
+int TRANS(SetOption)(XtransConnInfo connection, int option, int arg)
+.P
+This function sets transport options, similar to the way setsockopt() and
+ioctl() work.
+The parameter \fIconnection\fR is an endpoint that was obtained from
+_XTransOpen*() functions.
+The parameter \fIoption\fR contains the option that will be set. The actual
+values for \fIoption\fR are defined in a later section.
+The parameter \fIarg\fR can be used to pass in an additional value that may
+be required by some options.
+This function return 0 on success and -1 on failure.
+.P
+Note: Based on current usage, the complimentary function TRANS(GetOption)()
+is not necessary.
+.LI
+int TRANS(CreateListener)(XtransConnInfo connection, char *port, int flags)
+.P
+This function sets up the server endpoint for listening.
+The parameter \fIconnection\fR is an endpoint that was obtained from
+TRANS(OpenCOTSServer)() or TRANS(OpenCLTSServer)().
+The parameter \fIport\fR specifies the port to which this endpoint
+should be bound for listening.
+If \fIport\fR is NULL, then the transport may attempt to allocate any
+available TSAP for this connection. If the transport cannot support this,
+then this function will return a failure.
+The \fIflags\fR parameter can be set to ADDR_IN_USE_ALLOWED to allow
+the call to the underlying binding function to fail with a EADDRINUSE
+error without causing the TRANS(CreateListener) function itself to
+fail.
+This function return 0 on success and -1 on failure.
+.LI
+int TRANS(ResetListener)(XtransConnInfo connection)
+.P
+When a server is restarted, certain listen ports may need to be reset.
+For example, unix domain needs to check that the file used for communication
+has not been deleted. If it has, it must be recreated.
+The parameter \fIconnection\fR is an opened and bound endpoint that was
+obtained from TRANS(OpenCOTSServer)() and passed to TRANS(CreateListener)().
+This function will return one of the following values: TRANS_RESET_NOOP,
+TRANS_RESET_NEW_FD, or TRANS_RESET_FAILURE.
+.LI
+XtransConnInfo
+TRANS(Accept)(XtransConnInfo connection)
+.P
+Once a connection indication is received, this function can be called to
+accept the connection.
+The parameter \fIconnection\fR is an opened and bound endpoint that was
+obtained from TRANS(OpenCOTSServer)() and passed to TRANS(CreateListener)().
+This function will return a new opaque transport connection object upon
+success, NULL otherwise.
+.LI
+int TRANS(Connect)(XtransConnInfo connection, char *address)
+.P
+This function creates a connection to a server.
+The parameter \fIconnection\fR is an endpoint that was obtained from
+TRANS(OpenCOTSClient)().
+The parameters \fIaddress\fR specify the TSAP to which this
+endpoint should connect. If the protocol is included in the address, it will
+be ignored.
+This function return 0 on success and -1 on failure.
+.LI
+int TRANS(BytesReadable)(XtransConnInfo connection, BytesReadable_t *pend);
+.P
+This function provides the same functionality as the BytesReadable macro.
+.LI
+int TRANS(Read)(XtransConnInfo connection, char *buf, int size)
+.P
+This function will return the number of bytes requested on a COTS connection,
+and will return the minimum of the number bytes requested or the size of
+the incoming packet on a CLTS connection.
+.LI
+int TRANS(Write)(XtransConnInfo connection, char *buf, int size)
+.P
+This function will write the requested number of bytes on a COTS connection, and
+will send a packet of the requested size on a CLTS connection.
+.LI
+int TRANS(Readv)(XtransConnInfo connection, struct iovec *buf, int size)
+.P
+Similar to TRANS(Read)().
+.LI
+int TRANS(Writev)(XtransConnInfo connection, struct iovec *buf, int size)
+.P
+Similar to TRANS(Write)().
+.LI
+int TRANS(Disconnect)(XtransConnInfo connection)
+.P
+This function is used when an orderly disconnect is desired. This function
+breaks the connection on the transport. It is similar to the
+socket function shutdown().
+.LI
+int TRANS(Close)(XtransConnInfo connection)
+.P
+This function closes the transport, unbinds it, and frees all resources that
+was associated with the transport. If a TRANS(Disconnect) call was not made
+on the connection, a disorderly disconnect may occur.
+.LI
+int TRANS(IsLocal)(XtransConnInfo connection)
+.P
+Returns TRUE if it is a local transport.
+.LI
+int TRANS(GetMyAddr)(XtransConnInfo connection,
+.br
+ int *familyp, int *addrlenp, Xtransaddr **addrp)
+.P
+This function is similar to getsockname(). This function will allocate space
+for the address, so it must be freed by the caller. Not all transports will
+have a valid address until a connection is established. This function should
+not be used until the connection is established with Connect() or Accept().
+.LI
+int TRANS(GetPeerAddr)(XtransConnInfo connection,
+.br
+ int *familyp, int *addrlenp, Xtransaddr **addrp)
+.P
+This function is similar to getpeername(). This function will allocate space
+for the address, so it must be freed by the caller. Not all transports will
+have a valid address until a connection is established. This function should
+not be used until the connection is established with Connect() or Accept().
+.LI
+int TRANS(GetConnectionNumber)(XtransConnInfo connection)
+.P
+Returns the file descriptor associated with this transport.
+.LI
+int TRANS(MakeAllCOTSServerListeners)(
+.br
+ char *port, int *partial_ret, int *count_ret, XtransConnInfo **connections_ret)
+.P
+This function should be used by most servers. It will try to establish a COTS
+server endpoint for each transport listed in the transport table.
+\fIpartial_ret\fR will be set to True if only a partial network could be
+created. \fIcount_ret\fR is the number of transports returns, and
+\fIconnections_ret\fR is the list of transports.
+.LI
+int TRANS(MakeAllCLTSServerListeners)(
+.br
+ char *port, int *partial_ret, int *count_ret, XtransConnInfo **connections_ret)
+.P
+This function should be used by most servers. It will try to establish a CLTS
+server endpoint for each transport listed in the transport table.
+\fIpartial_ret\fR will be set to True if only a partial network could be
+created. \fIcount_ret\fR is the number of transports returns, and
+\fIconnections_ret\fR is the list of transports.
+.LE
+.H 2 "Utility API"
+.P
+This section describes a few useful functions that have been implemented on top
+of the Core Interface API. These functions are being provided as a convenience.
+.BL
+.LI
+int TRANS(ConvertAddress)(int *familyp, int *addrlenp, Xtransaddr *addrp)
+.P
+This function converts a sockaddr based address to an
+X authorization based address (ie AF_INET, AF_UNIX to the
+X protocol definition (ie FamilyInternet, FamilyLocal)).
+
+.LE
+.H 1 "Transport Option Definition"
+.P
+The following options are defined for the TRANS(SetOption)() function. If an
+OS or transport does not support any of these options, then it will silently
+ignore the option.
+.BL
+.LI
+TRANS_NONBLOCKING
+.P
+This option controls the blocking mode of the connection. If the argument
+is set to 1, then the connection will be set to blocking. If the argument
+is set to 0, then the connection will be set to non-blocking.
+.LI
+TRANS_CLOSEONEXEC
+.P
+This option determines what will happen to the connection when an exec
+is encountered. If the argument is set to 1, then the connection will be
+closed when an exec occurs. If the argument is set to 0, then the connection
+will not be closed when an exec occurs.
+.LE
+.H 1 "Hidden Transport Dependent API"
+.P
+The hidden transport dependent functions are placed in the Xtransport record.
+These function are similar to the Exposed Transport Independent API, but some
+of the parameters and return values are slightly different.
+Stuff like the #ifdef SUNSYSV should be handled inside these functions.
+.BL
+.LI
+XtransConnInfo *OpenCOTSClient (
+.br
+ struct _Xtransport *thistrans, char *protocol, char *host, char *port)
+.P
+This function creates a Connection-Oriented Transport. The parameter
+\fIthistrans\fR points to an Xtransport entry in the transport table. The
+parameters \fIprotocol\fR, \fIhost\fR, and \fIport\fR point to strings
+containing the corresponding parts of the address that was passed into
+TRANS(OpenCOTSClient)().
+.P
+This function must allocate and initialize the contents of the XtransConnInfo
+structure that is returned by this function. This function will open the
+transport, and bind it into the transport namespace if applicable. The
+local address portion of the XtransConnInfo structure will also be filled
+in by this function.
+.LI
+XtransConnInfo *OpenCOTSServer (
+.br
+ struct _Xtransport *thistrans, char *protocol, char *host, char *port)
+.P
+This function creates a Connection-Oriented Transport. The parameter
+\fIthistrans\fR points to an Xtransport entry in the transport table. The
+parameters \fIprotocol\fR, \fIhost\fR, and \fIport\fR point to strings
+containing the corresponding parts of the address that was passed into
+TRANS(OpenCOTSClient)().
+.P
+This function must allocate and initialize the contents of the XtransConnInfo
+structure that is returned by this function. This function will open the
+transport.
+.LI
+XtransConnInfo *OpenCLTSClient (
+.br
+ struct _Xtransport *thistrans, char *protocol, char *host, char *port)
+.P
+This function creates a Connection-Less Transport. The parameter
+\fIthistrans\fR points to an Xtransport entry in the transport table. The
+parameters \fIprotocol\fR, \fIhost\fR, and \fIport\fR point to strings
+containing the corresponding parts of the address that was passed into
+TRANS(OpenCOTSClient)().
+.P
+This function must allocate and initialize the contents of the XtransConnInfo
+structure that is returned by this function. This function will open the
+transport, and bind it into the transport namespace if applicable. The
+local address portion of the XtransConnInfo structure will also be filled
+in by this function.
+.LI
+XtransConnInfo *OpenCLTSServer (
+.br
+ struct _Xtransport *thistrans, char *protocol, char *host, char *port)
+.P
+This function creates a Connection-Less Transport. The parameter
+\fIthistrans\fR points to an Xtransport entry in the transport table. The
+parameters \fIprotocol\fR, \fIhost\fR, and \fIport\fR point to strings
+containing the corresponding parts of the address that was passed into
+TRANS(OpenCOTSClient)().
+.P
+This function must allocate and initialize the contents of the XtransConnInfo
+structure that is returned by this function. This function will open the
+transport.
+.LI
+int SetOption (struct _Xtransport *thistrans, int option, int arg)
+.P
+This function provides a transport dependent way of implementing the options
+defined by the X Transport Interface. In the current prototype, this function
+is not being used, because all of the option defined so far, are transport
+independent. This function will have to be used if a radically different
+transport type is added, or a transport dependent option is defined.
+.LI
+int CreateListener (struct _Xtransport *thistrans, char *port, int flags )
+.P
+This function takes a transport endpoint opened for a server, and sets it
+up to listen for incoming connection requests. The parameter \fIport\fR
+should contain the port portion of the address that was passed to the Open
+function.
+.P
+The parameter \fIflags\fR should be set to ADDR_IN_USE_ALLOWED if the
+underlying transport endpoint may be already bound and this should not
+be considered as an error. Otherwise \fIflags\fR sould be set to 0.
+This is used by IPv6 code, where the same socket can be bound to both
+an IPv6 address and then to a IPv4 address.
+.P
+This function will bind the transport into the transport name space if
+applicable, and fill in the local address portion of the XtransConnInfo
+structure. The transport endpoint will then be set to listen for
+incoming connection requests.
+.LI
+int ResetListener (struct _Xtransport *thistrans)
+.P
+This function resets the transport for listening.
+.LI
+XtransConnInfo Accept(struct _Xtransport *thistrans)
+.P
+This function creates a new transport endpoint as a result of an incoming
+connection request. The parameter \fIthistrans\fR is the endpoint that was opened
+for listening by the server. The new endpoint is opened and bound into the
+transport's namespace. A XtransConnInfo structure describing the new endpoint
+is returned from this function
+.LI
+int Connect(struct _Xtransport *thistrans, char *host, char *port )
+.P
+This function establishes a connection to a server. The parameters \fIhost\fR
+and \fIport\fR describe the server to which the connection should be
+established. The connection will be established so that Read() and Write()
+call can be made.
+.LI
+int BytesReadable(struct _Xtransport *thistrans, BytesReadable_t *pend )
+.P
+This function replaces the BytesReadable() macro. This allows each transport
+to have it's own mechanism for determining how much data is ready to be read.
+.LI
+int Read(struct _Xtransport *thistrans, char *buf, int size )
+.P
+This function reads \fIsize\fR bytes into \fIbuf\fR from the connection.
+.LI
+int Write(struct _Xtransport *thistrans, char *buf, int size )
+.P
+This function writes \fIsize\fR bytes from \fIbuf\fR to the connection.
+.LI
+int Readv(struct _Xtransport *thistrans, struct iovec *buf, int size )
+.P
+This function performs a readv() on the connection.
+.LI
+int Writev(struct _Xtransport *thistrans, struct iovec *buf, int size )
+.P
+This function performs a writev() on the connection.
+.LI
+int Disconnect(struct _Xtransport *thistrans)
+.P
+This function initiates an orderly shutdown of a connection. If a transport
+does not distinguish between orderly and disorderly disconnects, then a
+call to this function will have no affect.
+.LI
+int Close(struct _Xtransport *thistrans)
+.P
+This function will break the connection, and close the endpoint.
+.LE
+.H 1 "Configuration"
+.P
+The implementation of each transport can be platform specific. It is expected
+that existing connection types such as TCPCONN, UNIXCONN, LOCALCONN and
+STREAMSCONN will be replaced with flags for each possible transport type.
+.P
+Below are the flags that can be set in \fIConnectionFlags\fR in the vendor.cf
+or site.def config files.
+.TS
+center;
+l l .
+TCPCONN Enables the INET (IPv4) Domain Socket based transport
+IPv6 Extends TCPCONN to enable IPv6 Socket based transport
+UNIXCONN Enables the UNIX Domain Sokcet based transport
+STREAMSCONN Enables the TLI based transports
+LOCALCONN Enables the SYSV Local connection transports
+DNETCONN Enables the DECnet transports
+.TE
+.H 1 "Transport Specific Definitions"
+.TS
+center box;
+lb | cb sb sb
+lb | cb | cb | cb
+lb | cb | cb | cb
+l | l | l | l.
+Protocol Address Component
+ _ _ _
+Family protocol host port
+=
+Internet T{
+inet
+.br
+inet6
+.br
+tcp
+.br
+udp
+T} name of an internet addressable host T{
+string containing the name of a service or a valid port number.
+.br
+Example: "xserver0", "7100"
+T}
+_
+DECnet decnet name of a DECnet addressable host T{
+string containing the complete name of the object.
+.br
+Example: "X$X0"
+T}
+_
+NETware ipx name of a NETware addressable host T{
+Not sure of the specifics yet.
+T}
+_
+OSI osi name of an OSI addressable host T{
+Not sure of the specifics yet.
+T}
+_
+Local T{
+local
+.br
+pts
+.br
+named
+.br
+sco
+.br
+isc
+T} (ignored) T{
+String containing the port name, ie "xserver0", "fontserver0".
+T}
+.TE
+.H 1 "Implementation Notes"
+.P
+This section refers to the prototype implementation that is being developed
+concurrently with this document. This prototype has been able to flush out
+many details and problems as the specification was being developed.
+.P
+All of the source code for this interface is located in xc/lib/xtrans.
+.P
+All functions names in the source are of the format TRANS(func)(). The TRANS()
+macro is defined as
+.DS
+.sp
+#if (__STDC__ && !defined(UNIXCPP)) || defined(ANSICPP)
+#define TRANS(func) _PROTOCOLTrans##func
+#else
+#define TRANS(func) _PROTOCOLTrans/**/func
+#endif
+.sp
+.DE
+PROTOCOL will be uniquely defined in each directory where this code
+is compiled. PROTOCOL will be defined to be the name of the protocol that is
+implemented by the library or server, such as X11, FS, and ICE.
+.P
+All libraries and servers that use the X Transport Interface should have a new
+file called transport.c. This file will include the transports based
+on the configuration flags \fIConnectionFlags\fR. Below is an example
+transport.c.
+.DS
+.nf
+#include "Xtransint.h"
+
+#ifdef DNETCONN
+#include "Xtransdnet.c"
+#endif
+#ifdef LOCALCONN
+#include "Xtranslocal.c"
+#endif
+#ifdef TCPCONN
+#include "Xtranssock.c"
+#endif
+#ifdef STREAMSCONN
+#include "Xtranstli.c"
+#endif
+#include "Xtrans.c"
+#include "Xtransutil.c"
+.fi
+.DE
+.P
+The source files for this interface are listed below.
+.DS
+.TS
+center;
+l l.
+Xtrans.h T{
+Function prototypes and defines for
+the Transport Independent API.
+T}
+Xtransint.h T{
+Used by the interface implementation only.
+Contains the internal data structures.
+T}
+Xtranssock.c T{
+Socket implementation of the Transport Dependent API.
+T}
+Xtranstli.c T{
+TLI implementation of the Transport Dependent API.
+T}
+Xtransdnet.c T{
+DECnet implementation of the Transport Dependent API.
+T}
+Xtranslocal.c T{
+Implementation of the Transport Dependent API for
+SYSV Local connections.
+T}
+Xtrans.c T{
+Exposed Transport Independent API Functions.
+T}
+Xtransutil.c T{
+Collection of Utility functions that use the
+X Transport Interface.
+T}
+.TE
+.DE
+.P
+The file \fIXtransint.h\fR contains much of the transport related code that
+previously in Xlibint.h and Xlibnet.h. This will make the definitions
+available for all transport users. This should also obsolete the equivalent
+code in other libraries.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/xtrans-1.2.4/Xtranssock.c new/xtrans-1.2.5/Xtranssock.c
--- old/xtrans-1.2.4/Xtranssock.c 2009-07-31 01:06:14.000000000 +0200
+++ new/xtrans-1.2.5/Xtranssock.c 2009-10-16 23:25:57.000000000 +0200
@@ -229,19 +229,6 @@
#endif
/*
- * This provides compatibility for apps linked against system libraries
- * that don't have IPv6 support.
- */
-#if defined(IPv6) && defined(AF_INET6)
-static const struct in6_addr local_in6addr_any = IN6ADDR_ANY_INIT;
-#pragma weak in6addr_any = local_in6addr_any
-#ifndef __USLC__
-#pragma weak getaddrinfo
-#endif
-static int haveIPv6 = 1;
-#endif
-
-/*
* These are some utility function used by the real interface function below.
*/
@@ -274,25 +261,21 @@
{
#if defined(IPv6) && defined(AF_INET6)
struct sockaddr_storage socknamev6;
-#endif
+#else
struct sockaddr_in socknamev4;
+#endif
void *socknamePtr;
SOCKLEN_T namelen;
PRMSG (3,"SocketINETGetAddr(%p)\n", ciptr, 0, 0);
#if defined(IPv6) && defined(AF_INET6)
- if (haveIPv6)
- {
- namelen = sizeof(socknamev6);
- socknamePtr = &socknamev6;
- }
- else
+ namelen = sizeof(socknamev6);
+ socknamePtr = &socknamev6;
+#else
+ namelen = sizeof(socknamev4);
+ socknamePtr = &socknamev4;
#endif
- {
- namelen = sizeof(socknamev4);
- socknamePtr = &socknamev4;
- }
bzero(socknamePtr, namelen);
@@ -320,15 +303,10 @@
}
#if defined(IPv6) && defined(AF_INET6)
- if (haveIPv6)
- {
- ciptr->family = ((struct sockaddr *)socknamePtr)->sa_family;
- }
- else
+ ciptr->family = ((struct sockaddr *)socknamePtr)->sa_family;
+#else
+ ciptr->family = socknamev4.sin_family;
#endif
- {
- ciptr->family = socknamev4.sin_family;
- }
ciptr->addrlen = namelen;
memcpy (ciptr->addr, socknamePtr, ciptr->addrlen);
@@ -353,7 +331,7 @@
SOCKLEN_T namelen;
#if defined(IPv6) && defined(AF_INET6)
- if (haveIPv6 && ciptr->family == AF_INET6)
+ if (ciptr->family == AF_INET6)
{
namelen = sizeof(socknamev6);
socknamePtr = &socknamev6;
@@ -407,14 +385,6 @@
PRMSG (3,"SocketOpen(%d,%d)\n", i, type, 0);
-#if defined(IPv6) && defined(AF_INET6)
- if (getaddrinfo == NULL)
- haveIPv6 = 0;
-
- if (!haveIPv6 && Sockettrans2devtab[i].family == AF_INET6)
- return NULL;
-#endif
-
if ((ciptr = (XtransConnInfo) xcalloc (
1, sizeof(struct _XtransConnInfo))) == NULL)
{
@@ -1483,7 +1453,7 @@
#endif
#if defined(IPv6) && defined(AF_INET6)
- if (haveIPv6) {
+ {
if (addrlist != NULL) {
if (strcmp(host,addrlist->host) || strcmp(port,addrlist->port)) {
if (addrlist->firstaddr)
@@ -1625,8 +1595,8 @@
addrlist->addr = addrlist->addr->ai_next;
}
}
- } else
-#endif
+ }
+#else
{
/*
* Build the socket name.
@@ -1700,6 +1670,7 @@
socketaddr = (struct sockaddr *) &sockname;
socketaddrlen = sizeof(sockname);
}
+#endif
/*
* Turn on socket keepalive so the client process will eventually
@@ -1750,7 +1721,7 @@
if (olderrno == ECONNREFUSED || olderrno == EINTR
#if defined(IPv6) && defined(AF_INET6)
- || (haveIPv6 && ((addrlist->addr->ai_next != NULL) ||
+ || (((addrlist->addr->ai_next != NULL) ||
(addrlist->addr != addrlist->firstaddr)) &&
(olderrno == ENETUNREACH || olderrno == EAFNOSUPPORT ||
olderrno == EADDRNOTAVAIL || olderrno == ETIMEDOUT
@@ -1796,7 +1767,7 @@
}
#if defined(IPv6) && defined(AF_INET6)
- if (haveIPv6 && res != 0) {
+ if (res != 0) {
addrlist->addr = addrlist->addr->ai_next;
}
#endif
@@ -1820,20 +1791,13 @@
{
char hostnamebuf[256];
-#if defined(IPv6) && defined(AF_INET6)
- if (getaddrinfo == NULL)
- haveIPv6 = 0;
-#endif
-
TRANS(GetHostname) (hostnamebuf, sizeof (hostnamebuf));
if (strcmp (hostnamebuf, host) == 0)
{
return (1);
- }
+ } else {
#if defined(IPv6) && defined(AF_INET6)
- else if (haveIPv6)
- {
struct addrinfo *localhostaddr;
struct addrinfo *otherhostaddr;
struct addrinfo *i, *j;
@@ -1879,10 +1843,7 @@
freeaddrinfo(localhostaddr);
freeaddrinfo(otherhostaddr);
return equiv;
- }
-#endif
- else
- {
+#else
/*
* A host may have more than one network address. If any of the
* network addresses of 'host' (specified to the connect call)
@@ -1951,6 +1912,7 @@
i++;
}
return (equiv);
+#endif
}
}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/xtrans-1.2.4/Xtransutil.c new/xtrans-1.2.5/Xtransutil.c
--- old/xtrans-1.2.4/Xtransutil.c 2009-02-10 06:33:34.000000000 +0100
+++ new/xtrans-1.2.5/Xtransutil.c 2009-10-16 23:25:57.000000000 +0200
@@ -491,7 +491,7 @@
}
/* Dir doesn't exist. Try to create it */
-#ifndef WIN32
+#if !defined(WIN32) && !defined(__CYGWIN__)
/*
* 'sticky' bit requested: assume application makes
* certain security implications. If effective user ID
@@ -616,7 +616,7 @@
return -1;
}
#endif
-#ifndef __APPLE_CC__
+#if !defined(__APPLE_CC__) && !defined(__CYGWIN__)
PRMSG(1, "mkdir: Owner of %s should be set to root\n",
path, 0, 0);
#endif
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/xtrans-1.2.4/configure.ac new/xtrans-1.2.5/configure.ac
--- old/xtrans-1.2.4/configure.ac 2009-07-31 01:15:37.000000000 +0200
+++ new/xtrans-1.2.5/configure.ac 2009-10-17 22:13:37.000000000 +0200
@@ -21,13 +21,15 @@
dnl Process this file with autoconf to create configure.
AC_PREREQ([2.57])
-AC_INIT(xtrans, 1.2.4, [https://bugs.freedesktop.org/enter_bug.cgi?product=xorg], xtrans)
+AC_INIT(xtrans, [1.2.5], [https://bugs.freedesktop.org/enter_bug.cgi?product=xorg], xtrans)
AM_INIT_AUTOMAKE([dist-bzip2])
AM_MAINTAINER_MODE
-# Require xorg-macros version 1.2.0 or newer for XORG_CHANGELOG macro
-m4_ifndef([XORG_MACROS_VERSION], [AC_FATAL([must install xorg-macros 1.2 or later before running autoconf/autogen])])
-XORG_MACROS_VERSION(1.2)
+# Require xorg-macros 1.3 or later: XORG_DEFAULT_OPTIONS
+m4_ifndef([XORG_MACROS_VERSION],
+ [m4_fatal([must install xorg-macros 1.3 or later before running autoconf/autogen])])
+XORG_MACROS_VERSION(1.3)
+XORG_DEFAULT_OPTIONS
# Because xtrans is included into other modules rather than being linked
# with, these defines have to be added to the cflags line
@@ -47,8 +49,21 @@
AC_SUBST(sticky_bit_define)
-XORG_RELEASE_VERSION
-XORG_CHANGELOG
+# Documentation is currently provided in troff format, built on request
+AC_PATH_PROGS([GROFF], [groff], [none], [$PATH:/usr/gnu/bin])
+AC_PATH_PROGS([PS2PDF], [ps2pdf], [none], [$PATH:/usr/gnu/bin])
+
+AC_MSG_CHECKING([whether to build documentation])
+AC_ARG_ENABLE(docs, AC_HELP_STRING([--enable-docs],
+ [Enable building of documentation]),
+ [build_docs="${enableval}"], [build_docs="no"])
+AC_MSG_RESULT([${build_docs}])
+if test "x${build_docs}" = xyes && test "x${GROFF}" = xnone ; then
+ AC_MSG_ERROR([can't build documentation without groff])
+fi
+
+AM_CONDITIONAL(BUILD_DOCS, [test x$build_docs = xyes])
+AM_CONDITIONAL(HAVE_PS2PDF, [test x$PS2PDF != xnone])
AC_OUTPUT([Makefile
xtrans.pc])
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/xtrans-1.2.4/missing new/xtrans-1.2.5/missing
--- old/xtrans-1.2.4/missing 2009-08-01 02:25:53.000000000 +0200
+++ new/xtrans-1.2.5/missing 2009-10-17 22:14:43.000000000 +0200
@@ -1,10 +1,10 @@
#! /bin/sh
# Common stub for a few missing GNU programs while installing.
-scriptversion=2006-05-10.23
+scriptversion=2009-04-28.21; # UTC
-# Copyright (C) 1996, 1997, 1999, 2000, 2002, 2003, 2004, 2005, 2006
-# Free Software Foundation, Inc.
+# Copyright (C) 1996, 1997, 1999, 2000, 2002, 2003, 2004, 2005, 2006,
+# 2008, 2009 Free Software Foundation, Inc.
# Originally by Fran,cois Pinard , 1996.
# This program is free software; you can redistribute it and/or modify
@@ -18,9 +18,7 @@
# GNU General Public License for more details.
# You should have received a copy of the GNU General Public License
-# along with this program; if not, write to the Free Software
-# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
-# 02110-1301, USA.
+# along with this program. If not, see http://www.gnu.org/licenses/.
# As a special exception to the GNU General Public License, if you
# distribute this file as part of a program that contains a
@@ -89,6 +87,9 @@
tar try tar, gnutar, gtar, then tar without non-portable flags
yacc create \`y.tab.[ch]', if possible, from existing .[ch]
+Version suffixes to PROGRAM as well as the prefixes \`gnu-', \`gnu', and
+\`g' are ignored when checking the name.
+
Send bug reports to ."
exit $?
;;
@@ -106,15 +107,22 @@
esac
+# normalize program name to check for.
+program=`echo "$1" | sed '
+ s/^gnu-//; t
+ s/^gnu//; t
+ s/^g//; t'`
+
# Now exit if we have it, but it failed. Also exit now if we
# don't have it and --version was passed (most likely to detect
-# the program).
+# the program). This is about non-GNU programs, so use $1 not
+# $program.
case $1 in
- lex|yacc)
+ lex*|yacc*)
# Not GNU programs, they don't have --version.
;;
- tar)
+ tar*)
if test -n "$run"; then
echo 1>&2 "ERROR: \`tar' requires --run"
exit 1
@@ -138,7 +146,7 @@
# If it does not exist, or fails to run (possibly an outdated version),
# try to emulate it.
-case $1 in
+case $program in
aclocal*)
echo 1>&2 "\
WARNING: \`$1' is $msg. You should only need it if
@@ -148,7 +156,7 @@
touch aclocal.m4
;;
- autoconf)
+ autoconf*)
echo 1>&2 "\
WARNING: \`$1' is $msg. You should only need it if
you modified \`${configure_ac}'. You might want to install the
@@ -157,7 +165,7 @@
touch configure
;;
- autoheader)
+ autoheader*)
echo 1>&2 "\
WARNING: \`$1' is $msg. You should only need it if
you modified \`acconfig.h' or \`${configure_ac}'. You might want
@@ -187,7 +195,7 @@
while read f; do touch "$f"; done
;;
- autom4te)
+ autom4te*)
echo 1>&2 "\
WARNING: \`$1' is needed, but is $msg.
You might have modified some files without having the
@@ -210,7 +218,7 @@
fi
;;
- bison|yacc)
+ bison*|yacc*)
echo 1>&2 "\
WARNING: \`$1' $msg. You should only need it if
you modified a \`.y' file. You may need the \`Bison' package
@@ -240,7 +248,7 @@
fi
;;
- lex|flex)
+ lex*|flex*)
echo 1>&2 "\
WARNING: \`$1' is $msg. You should only need it if
you modified a \`.l' file. You may need the \`Flex' package
@@ -263,7 +271,7 @@
fi
;;
- help2man)
+ help2man*)
echo 1>&2 "\
WARNING: \`$1' is $msg. You should only need it if
you modified a dependency of a manual page. You may need the
@@ -277,11 +285,11 @@
else
test -z "$file" || exec >$file
echo ".ab help2man is required to generate this page"
- exit 1
+ exit $?
fi
;;
- makeinfo)
+ makeinfo*)
echo 1>&2 "\
WARNING: \`$1' is $msg. You should only need it if
you modified a \`.texi' or \`.texinfo' file, or any other file
@@ -310,7 +318,7 @@
touch $file
;;
- tar)
+ tar*)
shift
# We have already tried tar in the generic part.
@@ -363,5 +371,6 @@
# eval: (add-hook 'write-file-hooks 'time-stamp)
# time-stamp-start: "scriptversion="
# time-stamp-format: "%:y-%02m-%02d.%02H"
-# time-stamp-end: "$"
+# time-stamp-time-zone: "UTC"
+# time-stamp-end: "; # UTC"
# End:
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/xtrans-1.2.4/xtrans.m4 new/xtrans-1.2.5/xtrans.m4
--- old/xtrans-1.2.4/xtrans.m4 2008-12-01 17:09:13.000000000 +0100
+++ new/xtrans-1.2.5/xtrans.m4 2009-10-16 23:25:57.000000000 +0200
@@ -32,7 +32,9 @@
# SVR4 hides these in libraries other than libc
AC_SEARCH_LIBS(socket, [socket])
AC_SEARCH_LIBS(gethostbyname, [nsl])
- AC_HAVE_LIBRARY([ws2_32])
+ if test "$ac_cv_search_socket$ac_cv_search_gethostbyname" = "nono"; then
+ AC_HAVE_LIBRARY([ws2_32])
+ fi
# Needs to come after above checks for libsocket & libnsl for SVR4 systems
AC_ARG_ENABLE(ipv6,
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Remember to have fun...
--
To unsubscribe, e-mail: opensuse-commit+unsubscribe@opensuse.org
For additional commands, e-mail: opensuse-commit+help@opensuse.org