From b567a3027bceabc0f1f42dd162268f06f15e8149 Mon Sep 17 00:00:00 2001 From: marha Date: Sun, 18 Oct 2009 12:07:02 +0000 Subject: Updated following packages: libX11-1.3.1 xtrans-1.2.5 --- libX11/ChangeLog | 137 +- libX11/Makefile.am | 2 +- libX11/Makefile.in | 25 +- libX11/acinclude.m4 | 3 + libX11/aclocal.m4 | 16283 +++++++-------- libX11/config.guess | 51 +- libX11/config.sub | 54 +- libX11/configure | 33267 +++++++++++++++++++----------- libX11/configure.ac | 37 +- libX11/cpprules.in | 10 +- libX11/include/Makefile.in | 21 +- libX11/ltmain.sh | 13232 ++++++------ libX11/man/Makefile.am | 286 +- libX11/man/Makefile.in | 314 +- libX11/man/xkb/Makefile.am | 2 +- libX11/man/xkb/Makefile.in | 30 +- libX11/modules/Makefile.in | 21 +- libX11/modules/im/Makefile.in | 21 +- libX11/modules/im/ximcp/Makefile.am | 6 +- libX11/modules/im/ximcp/Makefile.in | 27 +- libX11/modules/lc/Makefile.in | 21 +- libX11/modules/lc/Utf8/Makefile.am | 6 +- libX11/modules/lc/Utf8/Makefile.in | 27 +- libX11/modules/lc/def/Makefile.am | 8 +- libX11/modules/lc/def/Makefile.in | 29 +- libX11/modules/lc/gen/Makefile.am | 8 +- libX11/modules/lc/gen/Makefile.in | 29 +- libX11/modules/lc/xlocale/Makefile.am | 8 +- libX11/modules/lc/xlocale/Makefile.in | 29 +- libX11/modules/om/Makefile.in | 21 +- libX11/modules/om/generic/Makefile.am | 6 +- libX11/modules/om/generic/Makefile.in | 27 +- libX11/nls/C/Makefile.in | 28 +- libX11/nls/Makefile.am | 6 +- libX11/nls/Makefile.in | 34 +- libX11/nls/am_ET.UTF-8/Makefile.in | 28 +- libX11/nls/armscii-8/Makefile.in | 28 +- libX11/nls/el_GR.UTF-8/Makefile.in | 28 +- libX11/nls/en_US.UTF-8/Makefile.in | 28 +- libX11/nls/fi_FI.UTF-8/Makefile.in | 28 +- libX11/nls/georgian-academy/Makefile.in | 28 +- libX11/nls/georgian-ps/Makefile.in | 28 +- libX11/nls/ibm-cp1133/Makefile.in | 28 +- libX11/nls/iscii-dev/Makefile.in | 28 +- libX11/nls/isiri-3342/Makefile.in | 28 +- libX11/nls/iso8859-1/Makefile.in | 28 +- libX11/nls/iso8859-10/Makefile.in | 28 +- libX11/nls/iso8859-11/Makefile.in | 28 +- libX11/nls/iso8859-13/Makefile.in | 28 +- libX11/nls/iso8859-14/Makefile.in | 28 +- libX11/nls/iso8859-15/Makefile.in | 28 +- libX11/nls/iso8859-2/Makefile.in | 28 +- libX11/nls/iso8859-3/Makefile.in | 28 +- libX11/nls/iso8859-4/Makefile.in | 28 +- libX11/nls/iso8859-5/Makefile.in | 28 +- libX11/nls/iso8859-6/Makefile.in | 28 +- libX11/nls/iso8859-7/Makefile.in | 28 +- libX11/nls/iso8859-8/Makefile.in | 28 +- libX11/nls/iso8859-9/Makefile.in | 28 +- libX11/nls/iso8859-9e/Makefile.in | 28 +- libX11/nls/ja.JIS/Makefile.in | 28 +- libX11/nls/ja.S90/Makefile.in | 28 +- libX11/nls/ja.SJIS/Makefile.in | 28 +- libX11/nls/ja.U90/Makefile.in | 28 +- libX11/nls/ja/Makefile.in | 28 +- libX11/nls/ja_JP.UTF-8/Makefile.in | 28 +- libX11/nls/ko/Makefile.in | 28 +- libX11/nls/ko_KR.UTF-8/Makefile.in | 28 +- libX11/nls/koi8-c/Makefile.in | 28 +- libX11/nls/koi8-r/Makefile.in | 28 +- libX11/nls/koi8-u/Makefile.in | 28 +- libX11/nls/microsoft-cp1251/Makefile.in | 28 +- libX11/nls/microsoft-cp1255/Makefile.in | 28 +- libX11/nls/microsoft-cp1256/Makefile.in | 28 +- libX11/nls/mulelao-1/Makefile.in | 28 +- libX11/nls/nokhchi-1/Makefile.in | 28 +- libX11/nls/pt_BR.UTF-8/Makefile.in | 28 +- libX11/nls/ru_RU.UTF-8/Makefile.in | 28 +- libX11/nls/tatar-cyr/Makefile.in | 28 +- libX11/nls/th_TH.UTF-8/Makefile.in | 28 +- libX11/nls/th_TH/Makefile.in | 28 +- libX11/nls/tscii-0/Makefile.in | 28 +- libX11/nls/vi_VN.tcvn/Makefile.in | 28 +- libX11/nls/vi_VN.viscii/Makefile.in | 28 +- libX11/nls/zh_CN.UTF-8/Makefile.in | 28 +- libX11/nls/zh_CN.gb18030/Makefile.in | 28 +- libX11/nls/zh_CN.gbk/Makefile.in | 28 +- libX11/nls/zh_CN/Makefile.in | 28 +- libX11/nls/zh_HK.UTF-8/Makefile.in | 28 +- libX11/nls/zh_HK.big5/Makefile.in | 28 +- libX11/nls/zh_HK.big5hkscs/Makefile.in | 28 +- libX11/nls/zh_TW.UTF-8/Makefile.in | 28 +- libX11/nls/zh_TW.big5/Makefile.in | 28 +- libX11/nls/zh_TW/Makefile.in | 28 +- libX11/specs/Makefile.am | 3 + libX11/specs/Makefile.in | 618 + libX11/specs/XIM/Makefile.am | 33 + libX11/specs/XIM/Makefile.in | 554 + libX11/specs/XIM/xim.ms | 4279 ++++ libX11/specs/i18n/Framework.ms | 1567 ++ libX11/specs/i18n/LocaleDB.ms | 502 + libX11/specs/i18n/Makefile.am | 33 + libX11/specs/i18n/Makefile.in | 554 + libX11/specs/i18n/Trans.ms | 1148 ++ libX11/specs/libX11/AppA | 604 + libX11/specs/libX11/AppB | 101 + libX11/specs/libX11/AppC | 2230 ++ libX11/specs/libX11/AppD | 1183 ++ libX11/specs/libX11/CH01 | 663 + libX11/specs/libX11/CH02 | 2052 ++ libX11/specs/libX11/CH03 | 3121 +++ libX11/specs/libX11/CH04 | 1595 ++ libX11/specs/libX11/CH05 | 518 + libX11/specs/libX11/CH06 | 4773 +++++ libX11/specs/libX11/CH07 | 2357 +++ libX11/specs/libX11/CH08 | 3468 ++++ libX11/specs/libX11/CH09 | 1290 ++ libX11/specs/libX11/CH10 | 3886 ++++ libX11/specs/libX11/CH11 | 1664 ++ libX11/specs/libX11/CH12 | 2680 +++ libX11/specs/libX11/CH13 | 7673 +++++++ libX11/specs/libX11/CH14 | 3590 ++++ libX11/specs/libX11/CH15 | 1628 ++ libX11/specs/libX11/CH16 | 2364 +++ libX11/specs/libX11/Makefile.am | 62 + libX11/specs/libX11/Makefile.in | 580 + libX11/specs/libX11/abstract.t | 106 + libX11/specs/libX11/credits.t | 216 + libX11/specs/libX11/glossary | 1484 ++ libX11/specs/libX11/libX11.ms | 24 + libX11/specs/libX11/postproc | 17 + libX11/specs/macros.t | 226 + libX11/specs/troffrules.in | 68 + libX11/src/Makefile.am | 6 +- libX11/src/Makefile.in | 27 +- libX11/src/OpenDis.c | 35 +- libX11/src/SetLocale.c | 4 +- libX11/src/config.h.in | 7 +- libX11/src/util/Makefile.in | 21 +- libX11/src/xcb_io.c | 7 + libX11/src/xcms/Makefile.am | 6 +- libX11/src/xcms/Makefile.in | 27 +- libX11/src/xkb/Makefile.am | 6 +- libX11/src/xkb/Makefile.in | 27 +- libX11/src/xlibi18n/Makefile.am | 6 +- libX11/src/xlibi18n/Makefile.in | 27 +- 146 files changed, 95251 insertions(+), 30237 deletions(-) create mode 100644 libX11/specs/Makefile.am create mode 100644 libX11/specs/Makefile.in create mode 100644 libX11/specs/XIM/Makefile.am create mode 100644 libX11/specs/XIM/Makefile.in create mode 100644 libX11/specs/XIM/xim.ms create mode 100644 libX11/specs/i18n/Framework.ms create mode 100644 libX11/specs/i18n/LocaleDB.ms create mode 100644 libX11/specs/i18n/Makefile.am create mode 100644 libX11/specs/i18n/Makefile.in create mode 100644 libX11/specs/i18n/Trans.ms create mode 100644 libX11/specs/libX11/AppA create mode 100644 libX11/specs/libX11/AppB create mode 100644 libX11/specs/libX11/AppC create mode 100644 libX11/specs/libX11/AppD create mode 100644 libX11/specs/libX11/CH01 create mode 100644 libX11/specs/libX11/CH02 create mode 100644 libX11/specs/libX11/CH03 create mode 100644 libX11/specs/libX11/CH04 create mode 100644 libX11/specs/libX11/CH05 create mode 100644 libX11/specs/libX11/CH06 create mode 100644 libX11/specs/libX11/CH07 create mode 100644 libX11/specs/libX11/CH08 create mode 100644 libX11/specs/libX11/CH09 create mode 100644 libX11/specs/libX11/CH10 create mode 100644 libX11/specs/libX11/CH11 create mode 100644 libX11/specs/libX11/CH12 create mode 100644 libX11/specs/libX11/CH13 create mode 100644 libX11/specs/libX11/CH14 create mode 100644 libX11/specs/libX11/CH15 create mode 100644 libX11/specs/libX11/CH16 create mode 100644 libX11/specs/libX11/Makefile.am create mode 100644 libX11/specs/libX11/Makefile.in create mode 100644 libX11/specs/libX11/abstract.t create mode 100644 libX11/specs/libX11/credits.t create mode 100644 libX11/specs/libX11/glossary create mode 100644 libX11/specs/libX11/libX11.ms create mode 100644 libX11/specs/libX11/postproc create mode 100644 libX11/specs/macros.t create mode 100644 libX11/specs/troffrules.in (limited to 'libX11') diff --git a/libX11/ChangeLog b/libX11/ChangeLog index 79e6b707e..4c74e7fc1 100644 --- a/libX11/ChangeLog +++ b/libX11/ChangeLog @@ -1,3 +1,110 @@ +commit ad15e1a89d30ccc11d80745897b83def1448e8c0 +Author: Alan Coopersmith +Date: Sat Oct 17 16:14:34 2009 -0700 + + libX11 1.3.1 + + Signed-off-by: Alan Coopersmith + +commit 0cbf98c17a7484bb58b2464b98d63bb3b4ea2594 +Author: Alan Coopersmith +Date: Sat Oct 17 16:28:25 2009 -0700 + + Fix make distcheck + + Signed-off-by: Alan Coopersmith + +commit 082e62ad268ef16a3bebc5a3c9fa008dbdc483ed +Author: Alan Coopersmith +Date: Fri Oct 16 19:25:35 2009 -0700 + + Use $(AM_V_GEN) to silence echo commands for generating shadow man pages + + Signed-off-by: Alan Coopersmith + +commit 4e66da0783b2e5e3b288aaecd3c89396ed425c20 +Author: Alan Coopersmith +Date: Wed Oct 14 16:18:24 2009 -0700 + + Move libX11 & XIM/locale specs from xorg-docs + + If groff is found, and --disable-specs is not passed to configure, + specs will be converted to text, html and ps (or pdf if ps2pdf is + found) and installed to $(docdir) + + Signed-off-by: Alan Coopersmith + +commit 5d3d817a42ddcc8d0c6efd33efd1442fe14f5c6b +Author: Yaakov Selkowitz +Date: Tue Oct 13 19:15:51 2009 -0500 + + Provide _Xsetlocale compat wrappers on Cygwin + + Previous versions of Cygwin did not have proper locale support, so Cygwin/X + defined X_LOCALE, using _Xsetlocale instead. Cygwin 1.7 has added locale + support, but we can't remove the _Xsetlocale entry point without breaking + ABI. + + Signed-off-by: Yaakov Selkowitz + +commit 2c8b3a877a713bb66a6316a7051b43c46af6e1a0 +Author: Yaakov Selkowitz +Date: Tue Oct 13 19:15:49 2009 -0500 + + dolt: add Cygwin to supported platforms + + Signed-off-by: Yaakov Selkowitz + +commit a2c8e3e34b15b57ff881a52101fc961a602f35e4 +Author: Alan Coopersmith +Date: Wed Oct 14 13:23:30 2009 -0700 + + Recognize XSUNBUFFERSIZE alias for XLIBBUFFERSIZE on Solaris + + Also fix indenting of the XLIBBUFFERSIZE code to match surrounding code + + Signed-off-by: Alan Coopersmith + +commit 34ddfca7b7d58240b0fe74bec6b2e0652d15c051 +Author: Jon TURNEY +Date: Tue Feb 10 17:47:25 2009 +0000 + + Include sys/select.h for select() and struct timeval, if it exists + + This is a cygwin build fix + +commit 383165916ddac91740d4c780174d4c0d07cdb994 +Author: Xake +Date: Sun Sep 27 11:16:36 2009 +0200 + + Use AM_V_GEN instead of customized macros for AM_SILENT_RULES + + Signed-off-by: Alan Coopersmith + +commit 854269d55cdda8caf425515bfed2855e211a5ada +Author: Julien Cristau +Date: Tue Oct 6 16:11:24 2009 +0200 + + configure: quote argument to m4_pattern_forbid + + Without this, configure spits out + ../configure: line 12364: ac_fn_c_check_member: command not found + ../configure: line 12378: ac_fn_c_check_type: command not found + + Also anchor the pattern to make it stricter. + + Signed-off-by: Julien Cristau + +commit 3bb020587ce74e0737ec7aceb20041f1e77d3b87 +Author: Jeremy Huddleston +Date: Thu Oct 1 22:20:38 2009 -0700 + + Split CFLAGS into CPPFLAGS and CFLAGS + + On some build systems, CPPFLAGS is set to "-I/some/prefix/include". If older + X11 headers are in /some/prefix/include, they will be preferred over the + shipped headers. This corrects that problem. + commit d54caf1c9c55af8247621b7ba6afb20b23699839 Author: Peter Hutterer Date: Fri Oct 2 10:59:08 2009 +1000 @@ -1739,7 +1846,7 @@ Date: Tue Jun 10 20:07:30 2008 +0300 Add some Khmer digraphs to all locales with a Compose.pre. commit e54cffb649b1622c17457e470cfab8cc56d38c97 -Merge: 19802cc 721b574 +Merge: 19802cc... 721b574... Author: Daniel Stone Date: Tue Jun 10 20:04:30 2008 +0300 @@ -1758,7 +1865,7 @@ Date: Wed May 28 17:31:59 2008 +0930 Require xproto 7.0.13 and libxcb 1.1.90 (for GenericEvents) commit e9195db7257e418f83707233baeeb84b225caf4f -Merge: c34f76f a7f8556 +Merge: c34f76f... a7f8556... Author: Peter Hutterer Date: Thu May 22 12:14:28 2008 +0930 @@ -1794,7 +1901,7 @@ Date: Mon May 12 21:46:24 2008 +0930 Build with xcb as transport layer highly recommended. commit c9b2ff1e6a607463993afa4a8d085857d97cc2f3 -Merge: 17d7dcb 9129057 +Merge: 17d7dcb... 9129057... Author: Peter Hutterer Date: Mon May 12 17:58:37 2008 +0930 @@ -2001,7 +2108,7 @@ Date: Sat Dec 22 21:45:23 2007 +0100 X.Org bug#13786 commit 32115c563b87d2f37e3f9de70fbd0f4d9e424aea -Merge: 8f0bd3f e8d4cef +Merge: 8f0bd3f... e8d4cef... Author: James Cloos Date: Fri Dec 14 22:43:47 2007 -0500 @@ -2032,14 +2139,14 @@ Date: Mon Dec 10 23:00:44 2007 -0800 Added launchd support. commit 17d7dcbfced4a9417b33507bd3fd9b7dd8268242 -Merge: 5dfefd3 13ac804 +Merge: 5dfefd3... 13ac804... Author: Peter Hutterer Date: Thu Dec 6 14:08:29 2007 +1030 Merge branch 'master' into xge commit 5dfefd3829d3ba7e41d5db0ad28e9dfee92fadd5 -Merge: a68a1cd eff33ae +Merge: a68a1cd... eff33ae... Author: Peter Hutterer Date: Thu Dec 6 13:57:09 2007 +1030 @@ -2095,7 +2202,7 @@ Date: Tue Dec 4 17:25:39 2007 -0500 2] https://bugs.freedesktop.org/show_bug.cgi?id=5129 commit 02e04059c89e175f51647e3b031344f743286b34 -Merge: 1254c57 b57129e +Merge: 1254c57... b57129e... Author: James Cloos Date: Tue Dec 4 06:55:04 2007 -0500 @@ -2273,7 +2380,7 @@ Date: Tue Jan 2 08:40:00 2007 -0800 X.Org Bugzilla #9516 commit d8fe979fc929833e8c754aed32641786d5a0622b -Merge: 21ca953 4ec1723 +Merge: 21ca953... 4ec1723... Author: James Cloos Date: Mon Aug 20 15:34:50 2007 -0400 @@ -2893,7 +3000,7 @@ Date: Sat Dec 16 00:45:19 2006 +0200 Since XlibConf.h is built by configure, don't distribute it. commit dd1705ced2cac6b4b6b21e79272fcf9bed4bf376 -Merge: 129bbb9 769b985 +Merge: 129bbb9... 769b985... Author: Jeremy C. Reed Date: Thu Dec 14 14:23:20 2006 -0600 @@ -3133,7 +3240,7 @@ Date: Sat Oct 7 21:00:36 2006 -0700 Release libX11 1.1 RC1 (1.0.99.1). commit bf237409c5fce32c557d298f62f44d456c2b5bc8 -Merge: ba47719 2d426d1 +Merge: ba47719... 2d426d1... Author: Jamey Sharp Date: Sat Oct 7 21:07:16 2006 -0700 @@ -3570,7 +3677,7 @@ Date: Sat Jun 3 13:51:51 2006 +0300 (cherry picked from e3acee88cfcc4ef0fa8a7db39763a5ebe2e985cb commit) commit c336eb6b80a6f91da1d0b3d28634a2cfde324670 -Merge: 33556ca ad9ebbd +Merge: 33556ca... ad9ebbd... Author: Donnie Berkholz Date: Thu Jun 22 14:25:35 2006 -0700 @@ -3583,14 +3690,14 @@ Date: Thu Jun 22 17:20:59 2006 +0300 Bump to 1.0.99.0 to avoid confusion. commit efedfd68e31bcee2d21ac340be8dc9e1825ec890 -Merge: e3acee8 4b8eb5d +Merge: e3acee8... 4b8eb5d... Author: Daniel Stone Date: Thu Jun 22 16:53:45 2006 +0300 Merge branch 'master' of git+ssh://git.freedesktop.org/srv/git.freedesktop.org/git/xorg/lib/libX11 commit 4b8eb5d4a1da73a94b5a6ab12e34784aae4c79c5 -Merge: 5169d0e eff50c9 +Merge: 5169d0e... eff50c9... Author: Matthieu Herrb Date: Tue Jun 20 21:05:15 2006 +0200 @@ -3923,7 +4030,7 @@ Date: Wed May 10 14:51:37 2006 +0300 Fix typo (be_BG.UTF-8 rather than bg_BG.UTF-8) in locale.alias.pre. commit 9cac8c9824874ca7d835f001a4efa910b7fdd822 -Merge: 19b8840 e514bc8 +Merge: 19b8840... e514bc8... Author: Daniel Stone Date: Wed May 10 14:50:37 2006 +0300 @@ -4016,7 +4123,7 @@ Date: Fri Mar 17 15:58:39 2006 +0200 Properly clip bounds when only one point is defining an outline. commit e876efb8aa410f2f5c87aaaa7042f847c4ff96f7 -Merge: be266b2 f71ea0b +Merge: be266b2... f71ea0b... Author: Matthieu Herrb Date: Sat Mar 11 15:40:35 2006 +0100 diff --git a/libX11/Makefile.am b/libX11/Makefile.am index 4fcad1c19..e471ff4ac 100644 --- a/libX11/Makefile.am +++ b/libX11/Makefile.am @@ -3,7 +3,7 @@ ORDER=src modules else ORDER=modules src endif -SUBDIRS=include $(ORDER) nls man +SUBDIRS=include $(ORDER) nls man specs pkgconfigdir = $(libdir)/pkgconfig pkgconfig_DATA = x11.pc diff --git a/libX11/Makefile.in b/libX11/Makefile.in index 183297dd5..550b9b24f 100644 --- a/libX11/Makefile.in +++ b/libX11/Makefile.in @@ -99,7 +99,7 @@ AM_RECURSIVE_TARGETS = $(RECURSIVE_TARGETS:-recursive=) \ distdir dist dist-all distcheck ETAGS = etags CTAGS = ctags -DIST_SUBDIRS = include modules src nls man +DIST_SUBDIRS = include modules src nls man specs DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) distdir = $(PACKAGE)-$(VERSION) top_distdir = $(distdir) @@ -157,6 +157,10 @@ 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@ @@ -164,16 +168,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -182,7 +188,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -192,7 +197,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -203,12 +207,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -218,6 +218,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -256,7 +257,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -288,7 +290,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -306,7 +307,7 @@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ @XLIB_LOADABLE_I18N_FALSE@ORDER = modules src @XLIB_LOADABLE_I18N_TRUE@ORDER = src modules -SUBDIRS = include $(ORDER) nls man +SUBDIRS = include $(ORDER) nls man specs pkgconfigdir = $(libdir)/pkgconfig pkgconfig_DATA = x11.pc $(am__append_1) EXTRA_DIST = x11.pc.in x11-xcb.pc.in ChangeLog diff --git a/libX11/acinclude.m4 b/libX11/acinclude.m4 index 1485a8cf6..922145fdc 100644 --- a/libX11/acinclude.m4 +++ b/libX11/acinclude.m4 @@ -76,6 +76,9 @@ i?86-*-linux*|x86_64-*-linux*|powerpc-*-linux* \ |amd64-*-freebsd*|i?86-*-freebsd*|ia64-*-freebsd*) pic_options='-fPIC' ;; +i?86-pc-cygwin*) + pic_options='-DDLL_EXPORT' + ;; i?86-apple-darwin*) pic_options='-fno-common' ;; diff --git a/libX11/aclocal.m4 b/libX11/aclocal.m4 index f3a50b526..1d8a73686 100644 --- a/libX11/aclocal.m4 +++ b/libX11/aclocal.m4 @@ -19,5238 +19,4514 @@ You have another version of autoconf. It may work, but is not guaranteed to. If you have problems, you may need to regenerate the build system entirely. To do so, use the procedure documented by the package, typically `autoreconf'.])]) -# libtool.m4 - Configure libtool for the host system. -*-Autoconf-*- +# Copyright (C) 2002, 2003, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. # -# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, -# 2006, 2007, 2008 Free Software Foundation, Inc. -# Written by Gordon Matzigkeit, 1996 +# This file 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. + +# AM_AUTOMAKE_VERSION(VERSION) +# ---------------------------- +# Automake X.Y traces this macro to ensure aclocal.m4 has been +# generated from the m4 files accompanying Automake X.Y. +# (This private macro should not be called outside this file.) +AC_DEFUN([AM_AUTOMAKE_VERSION], +[am__api_version='1.11' +dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to +dnl require some minimum version. Point them to the right macro. +m4_if([$1], [1.11], [], + [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl +]) + +# _AM_AUTOCONF_VERSION(VERSION) +# ----------------------------- +# aclocal traces this macro to find the Autoconf version. +# This is a private macro too. Using m4_define simplifies +# the logic in aclocal, which can simply ignore this definition. +m4_define([_AM_AUTOCONF_VERSION], []) + +# AM_SET_CURRENT_AUTOMAKE_VERSION +# ------------------------------- +# Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced. +# This function is AC_REQUIREd by AM_INIT_AUTOMAKE. +AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION], +[AM_AUTOMAKE_VERSION([1.11])dnl +m4_ifndef([AC_AUTOCONF_VERSION], + [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl +_AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))]) + +# AM_AUX_DIR_EXPAND -*- Autoconf -*- + +# Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc. # -# This file 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. - -m4_define([_LT_COPYING], [dnl -# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, -# 2006, 2007, 2008 Free Software Foundation, Inc. -# Written by Gordon Matzigkeit, 1996 +# This file 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. + +# For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets +# $ac_aux_dir to `$srcdir/foo'. In other projects, it is set to +# `$srcdir', `$srcdir/..', or `$srcdir/../..'. # -# This file is part of GNU Libtool. +# Of course, Automake must honor this variable whenever it calls a +# tool from the auxiliary directory. The problem is that $srcdir (and +# therefore $ac_aux_dir as well) can be either absolute or relative, +# depending on how configure is run. This is pretty annoying, since +# it makes $ac_aux_dir quite unusable in subdirectories: in the top +# source directory, any form will work fine, but in subdirectories a +# relative path needs to be adjusted first. # -# GNU Libtool is free software; you can redistribute it and/or -# modify it under the terms of the GNU General Public License as -# published by the Free Software Foundation; either version 2 of -# the License, or (at your option) any later version. +# $ac_aux_dir/missing +# fails when called from a subdirectory if $ac_aux_dir is relative +# $top_srcdir/$ac_aux_dir/missing +# fails if $ac_aux_dir is absolute, +# fails when called from a subdirectory in a VPATH build with +# a relative $ac_aux_dir # -# As a special exception to the GNU General Public License, -# if you distribute this file as part of a program or library that -# is built using GNU Libtool, you may include this file under the -# same distribution terms that you use for the rest of that program. +# The reason of the latter failure is that $top_srcdir and $ac_aux_dir +# are both prefixed by $srcdir. In an in-source build this is usually +# harmless because $srcdir is `.', but things will broke when you +# start a VPATH build or use an absolute $srcdir. # -# GNU Libtool is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. +# So we could use something similar to $top_srcdir/$ac_aux_dir/missing, +# iff we strip the leading $srcdir from $ac_aux_dir. That would be: +# am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"` +# and then we would define $MISSING as +# MISSING="\${SHELL} $am_aux_dir/missing" +# This will work as long as MISSING is not called from configure, because +# unfortunately $(top_srcdir) has no meaning in configure. +# However there are other variables, like CC, which are often used in +# configure, and could therefore not use this "fixed" $ac_aux_dir. # -# You should have received a copy of the GNU General Public License -# along with GNU Libtool; see the file COPYING. If not, a copy -# can be downloaded from http://www.gnu.org/licenses/gpl.html, or -# obtained by writing to the Free Software Foundation, Inc., -# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. -]) - -# serial 56 LT_INIT - - -# LT_PREREQ(VERSION) -# ------------------ -# Complain and exit if this libtool version is less that VERSION. -m4_defun([LT_PREREQ], -[m4_if(m4_version_compare(m4_defn([LT_PACKAGE_VERSION]), [$1]), -1, - [m4_default([$3], - [m4_fatal([Libtool version $1 or higher is required], - 63)])], - [$2])]) - +# Another solution, used here, is to always expand $ac_aux_dir to an +# absolute PATH. The drawback is that using absolute paths prevent a +# configured tree to be moved without reconfiguration. -# _LT_CHECK_BUILDDIR -# ------------------ -# Complain if the absolute build directory name contains unusual characters -m4_defun([_LT_CHECK_BUILDDIR], -[case `pwd` in - *\ * | *\ *) - AC_MSG_WARN([Libtool does not cope well with whitespace in `pwd`]) ;; -esac +AC_DEFUN([AM_AUX_DIR_EXPAND], +[dnl Rely on autoconf to set up CDPATH properly. +AC_PREREQ([2.50])dnl +# expand $ac_aux_dir to an absolute path +am_aux_dir=`cd $ac_aux_dir && pwd` ]) +# AM_CONDITIONAL -*- Autoconf -*- -# LT_INIT([OPTIONS]) -# ------------------ -AC_DEFUN([LT_INIT], -[AC_PREREQ([2.58])dnl We use AC_INCLUDES_DEFAULT -AC_BEFORE([$0], [LT_LANG])dnl -AC_BEFORE([$0], [LT_OUTPUT])dnl -AC_BEFORE([$0], [LTDL_INIT])dnl -m4_require([_LT_CHECK_BUILDDIR])dnl - -dnl Autoconf doesn't catch unexpanded LT_ macros by default: -m4_pattern_forbid([^_?LT_[A-Z_]+$])dnl -m4_pattern_allow([^(_LT_EOF|LT_DLGLOBAL|LT_DLLAZY_OR_NOW|LT_MULTI_MODULE)$])dnl -dnl aclocal doesn't pull ltoptions.m4, ltsugar.m4, or ltversion.m4 -dnl unless we require an AC_DEFUNed macro: -AC_REQUIRE([LTOPTIONS_VERSION])dnl -AC_REQUIRE([LTSUGAR_VERSION])dnl -AC_REQUIRE([LTVERSION_VERSION])dnl -AC_REQUIRE([LTOBSOLETE_VERSION])dnl -m4_require([_LT_PROG_LTMAIN])dnl - -dnl Parse OPTIONS -_LT_SET_OPTIONS([$0], [$1]) - -# This can be used to rebuild libtool when needed -LIBTOOL_DEPS="$ltmain" - -# Always use our own libtool. -LIBTOOL='$(SHELL) $(top_builddir)/libtool' -AC_SUBST(LIBTOOL)dnl +# Copyright (C) 1997, 2000, 2001, 2003, 2004, 2005, 2006, 2008 +# Free Software Foundation, Inc. +# +# This file 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. -_LT_SETUP +# serial 9 -# Only expand once: -m4_define([LT_INIT]) -])# LT_INIT +# AM_CONDITIONAL(NAME, SHELL-CONDITION) +# ------------------------------------- +# Define a conditional. +AC_DEFUN([AM_CONDITIONAL], +[AC_PREREQ(2.52)dnl + ifelse([$1], [TRUE], [AC_FATAL([$0: invalid condition: $1])], + [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl +AC_SUBST([$1_TRUE])dnl +AC_SUBST([$1_FALSE])dnl +_AM_SUBST_NOTMAKE([$1_TRUE])dnl +_AM_SUBST_NOTMAKE([$1_FALSE])dnl +m4_define([_AM_COND_VALUE_$1], [$2])dnl +if $2; then + $1_TRUE= + $1_FALSE='#' +else + $1_TRUE='#' + $1_FALSE= +fi +AC_CONFIG_COMMANDS_PRE( +[if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then + AC_MSG_ERROR([[conditional "$1" was never defined. +Usually this means the macro was only invoked conditionally.]]) +fi])]) -# Old names: -AU_ALIAS([AC_PROG_LIBTOOL], [LT_INIT]) -AU_ALIAS([AM_PROG_LIBTOOL], [LT_INIT]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_PROG_LIBTOOL], []) -dnl AC_DEFUN([AM_PROG_LIBTOOL], []) +# Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2009 +# Free Software Foundation, Inc. +# +# This file 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. +# serial 10 -# _LT_CC_BASENAME(CC) -# ------------------- -# Calculate cc_basename. Skip known compiler wrappers and cross-prefix. -m4_defun([_LT_CC_BASENAME], -[for cc_temp in $1""; do - case $cc_temp in - compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;; - distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;; - \-*) ;; - *) break;; - esac -done -cc_basename=`$ECHO "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` -]) +# There are a few dirty hacks below to avoid letting `AC_PROG_CC' be +# written in clear, in which case automake, when reading aclocal.m4, +# will think it sees a *use*, and therefore will trigger all it's +# C support machinery. Also note that it means that autoscan, seeing +# CC etc. in the Makefile, will ask for an AC_PROG_CC use... -# _LT_FILEUTILS_DEFAULTS +# _AM_DEPENDENCIES(NAME) # ---------------------- -# It is okay to use these file commands and assume they have been set -# sensibly after `m4_require([_LT_FILEUTILS_DEFAULTS])'. -m4_defun([_LT_FILEUTILS_DEFAULTS], -[: ${CP="cp -f"} -: ${MV="mv -f"} -: ${RM="rm -f"} -])# _LT_FILEUTILS_DEFAULTS - - -# _LT_SETUP -# --------- -m4_defun([_LT_SETUP], -[AC_REQUIRE([AC_CANONICAL_HOST])dnl -AC_REQUIRE([AC_CANONICAL_BUILD])dnl -_LT_DECL([], [host_alias], [0], [The host system])dnl -_LT_DECL([], [host], [0])dnl -_LT_DECL([], [host_os], [0])dnl -dnl -_LT_DECL([], [build_alias], [0], [The build system])dnl -_LT_DECL([], [build], [0])dnl -_LT_DECL([], [build_os], [0])dnl -dnl -AC_REQUIRE([AC_PROG_CC])dnl -AC_REQUIRE([LT_PATH_LD])dnl -AC_REQUIRE([LT_PATH_NM])dnl -dnl -AC_REQUIRE([AC_PROG_LN_S])dnl -test -z "$LN_S" && LN_S="ln -s" -_LT_DECL([], [LN_S], [1], [Whether we need soft or hard links])dnl -dnl -AC_REQUIRE([LT_CMD_MAX_LEN])dnl -_LT_DECL([objext], [ac_objext], [0], [Object file suffix (normally "o")])dnl -_LT_DECL([], [exeext], [0], [Executable file suffix (normally "")])dnl -dnl -m4_require([_LT_FILEUTILS_DEFAULTS])dnl -m4_require([_LT_CHECK_SHELL_FEATURES])dnl -m4_require([_LT_CMD_RELOAD])dnl -m4_require([_LT_CHECK_MAGIC_METHOD])dnl -m4_require([_LT_CMD_OLD_ARCHIVE])dnl -m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl - -_LT_CONFIG_LIBTOOL_INIT([ -# See if we are running on zsh, and set the options which allow our -# commands through without removal of \ escapes INIT. -if test -n "\${ZSH_VERSION+set}" ; then - setopt NO_GLOB_SUBST -fi -]) -if test -n "${ZSH_VERSION+set}" ; then - setopt NO_GLOB_SUBST -fi +# See how the compiler implements dependency checking. +# NAME is "CC", "CXX", "GCJ", or "OBJC". +# We try a few techniques and use that to set a single cache variable. +# +# We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was +# modified to invoke _AM_DEPENDENCIES(CC); we would have a circular +# dependency, and given that the user is not expected to run this macro, +# just rely on AC_PROG_CC. +AC_DEFUN([_AM_DEPENDENCIES], +[AC_REQUIRE([AM_SET_DEPDIR])dnl +AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl +AC_REQUIRE([AM_MAKE_INCLUDE])dnl +AC_REQUIRE([AM_DEP_TRACK])dnl -_LT_CHECK_OBJDIR +ifelse([$1], CC, [depcc="$CC" am_compiler_list=], + [$1], CXX, [depcc="$CXX" am_compiler_list=], + [$1], OBJC, [depcc="$OBJC" am_compiler_list='gcc3 gcc'], + [$1], UPC, [depcc="$UPC" am_compiler_list=], + [$1], GCJ, [depcc="$GCJ" am_compiler_list='gcc3 gcc'], + [depcc="$$1" am_compiler_list=]) -m4_require([_LT_TAG_COMPILER])dnl -_LT_PROG_ECHO_BACKSLASH +AC_CACHE_CHECK([dependency style of $depcc], + [am_cv_$1_dependencies_compiler_type], +[if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then + # We make a subdir and do the tests there. Otherwise we can end up + # making bogus files that we don't know about and never remove. For + # instance it was reported that on HP-UX the gcc test will end up + # making a dummy file named `D' -- because `-MD' means `put the output + # in D'. + mkdir conftest.dir + # Copy depcomp to subdir because otherwise we won't find it if we're + # using a relative directory. + cp "$am_depcomp" conftest.dir + cd conftest.dir + # We will build objects and dependencies in a subdirectory because + # it helps to detect inapplicable dependency modes. For instance + # both Tru64's cc and ICC support -MD to output dependencies as a + # side effect of compilation, but ICC will put the dependencies in + # the current directory while Tru64 will put them in the object + # directory. + mkdir sub -case $host_os in -aix3*) - # AIX sometimes has problems with the GCC collect2 program. For some - # reason, if we set the COLLECT_NAMES environment variable, the problems - # vanish in a puff of smoke. - if test "X${COLLECT_NAMES+set}" != Xset; then - COLLECT_NAMES= - export COLLECT_NAMES + am_cv_$1_dependencies_compiler_type=none + if test "$am_compiler_list" = ""; then + am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp` fi - ;; -esac - -# Sed substitution that helps us do robust quoting. It backslashifies -# metacharacters that are still active within double-quoted strings. -sed_quote_subst='s/\([["`$\\]]\)/\\\1/g' - -# Same as above, but do not quote variable references. -double_quote_subst='s/\([["`\\]]\)/\\\1/g' - -# Sed substitution to delay expansion of an escaped shell variable in a -# double_quote_subst'ed string. -delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g' - -# Sed substitution to delay expansion of an escaped single quote. -delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g' + am__universal=false + m4_case([$1], [CC], + [case " $depcc " in #( + *\ -arch\ *\ -arch\ *) am__universal=true ;; + esac], + [CXX], + [case " $depcc " in #( + *\ -arch\ *\ -arch\ *) am__universal=true ;; + esac]) -# Sed substitution to avoid accidental globbing in evaled expressions -no_glob_subst='s/\*/\\\*/g' - -# Global variables: -ofile=libtool -can_build_shared=yes - -# All known linkers require a `.a' archive for static linking (except MSVC, -# which needs '.lib'). -libext=a - -with_gnu_ld="$lt_cv_prog_gnu_ld" - -old_CC="$CC" -old_CFLAGS="$CFLAGS" - -# Set sane defaults for various variables -test -z "$CC" && CC=cc -test -z "$LTCC" && LTCC=$CC -test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS -test -z "$LD" && LD=ld -test -z "$ac_objext" && ac_objext=o - -_LT_CC_BASENAME([$compiler]) - -# Only perform the check for file, if the check method requires it -test -z "$MAGIC_CMD" && MAGIC_CMD=file -case $deplibs_check_method in -file_magic*) - if test "$file_magic_cmd" = '$MAGIC_CMD'; then - _LT_PATH_MAGIC - fi - ;; -esac - -# Use C for the default configuration in the libtool script -LT_SUPPORTED_TAG([CC]) -_LT_LANG_C_CONFIG -_LT_LANG_DEFAULT_CONFIG -_LT_CONFIG_COMMANDS -])# _LT_SETUP - - -# _LT_PROG_LTMAIN -# --------------- -# Note that this code is called both from `configure', and `config.status' -# now that we use AC_CONFIG_COMMANDS to generate libtool. Notably, -# `config.status' has no value for ac_aux_dir unless we are using Automake, -# so we pass a copy along to make sure it has a sensible value anyway. -m4_defun([_LT_PROG_LTMAIN], -[m4_ifdef([AC_REQUIRE_AUX_FILE], [AC_REQUIRE_AUX_FILE([ltmain.sh])])dnl -_LT_CONFIG_LIBTOOL_INIT([ac_aux_dir='$ac_aux_dir']) -ltmain="$ac_aux_dir/ltmain.sh" -])# _LT_PROG_LTMAIN - - - -# So that we can recreate a full libtool script including additional -# tags, we accumulate the chunks of code to send to AC_CONFIG_COMMANDS -# in macros and then make a single call at the end using the `libtool' -# label. - - -# _LT_CONFIG_LIBTOOL_INIT([INIT-COMMANDS]) -# ---------------------------------------- -# Register INIT-COMMANDS to be passed to AC_CONFIG_COMMANDS later. -m4_define([_LT_CONFIG_LIBTOOL_INIT], -[m4_ifval([$1], - [m4_append([_LT_OUTPUT_LIBTOOL_INIT], - [$1 -])])]) - -# Initialize. -m4_define([_LT_OUTPUT_LIBTOOL_INIT]) + for depmode in $am_compiler_list; do + # Setup a source with many dependencies, because some compilers + # like to wrap large dependency lists on column 80 (with \), and + # we should not choose a depcomp mode which is confused by this. + # + # We need to recreate these files for each test, as the compiler may + # overwrite some of them when testing with obscure command lines. + # This happens at least with the AIX C compiler. + : > sub/conftest.c + for i in 1 2 3 4 5 6; do + echo '#include "conftst'$i'.h"' >> sub/conftest.c + # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with + # Solaris 8's {/usr,}/bin/sh. + touch sub/conftst$i.h + done + echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf + # We check with `-c' and `-o' for the sake of the "dashmstdout" + # mode. It turns out that the SunPro C++ compiler does not properly + # handle `-M -o', and we need to detect this. Also, some Intel + # versions had trouble with output in subdirs + am__obj=sub/conftest.${OBJEXT-o} + am__minus_obj="-o $am__obj" + case $depmode in + gcc) + # This depmode causes a compiler race in universal mode. + test "$am__universal" = false || continue + ;; + nosideeffect) + # after this tag, mechanisms are not by side-effect, so they'll + # only be used when explicitly requested + if test "x$enable_dependency_tracking" = xyes; then + continue + else + break + fi + ;; + msvisualcpp | msvcmsys) + # This compiler won't grok `-c -o', but also, the minuso test has + # not run yet. These depmodes are late enough in the game, and + # so weak that their functioning should not be impacted. + am__obj=conftest.${OBJEXT-o} + am__minus_obj= + ;; + none) break ;; + esac + if depmode=$depmode \ + source=sub/conftest.c object=$am__obj \ + depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ + $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \ + >/dev/null 2>conftest.err && + grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 && + grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && + grep $am__obj sub/conftest.Po > /dev/null 2>&1 && + ${MAKE-make} -s -f confmf > /dev/null 2>&1; then + # icc doesn't choke on unknown options, it will just issue warnings + # or remarks (even with -Werror). So we grep stderr for any message + # that says an option was ignored or not supported. + # When given -MP, icc 7.0 and 7.1 complain thusly: + # icc: Command line warning: ignoring option '-M'; no argument required + # The diagnosis changed in icc 8.0: + # icc: Command line remark: option '-MP' not supported + if (grep 'ignoring option' conftest.err || + grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else + am_cv_$1_dependencies_compiler_type=$depmode + break + fi + fi + done -# _LT_CONFIG_LIBTOOL([COMMANDS]) -# ------------------------------ -# Register COMMANDS to be passed to AC_CONFIG_COMMANDS later. -m4_define([_LT_CONFIG_LIBTOOL], -[m4_ifval([$1], - [m4_append([_LT_OUTPUT_LIBTOOL_COMMANDS], - [$1 -])])]) - -# Initialize. -m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS]) - - -# _LT_CONFIG_SAVE_COMMANDS([COMMANDS], [INIT_COMMANDS]) -# ----------------------------------------------------- -m4_defun([_LT_CONFIG_SAVE_COMMANDS], -[_LT_CONFIG_LIBTOOL([$1]) -_LT_CONFIG_LIBTOOL_INIT([$2]) + cd .. + rm -rf conftest.dir +else + am_cv_$1_dependencies_compiler_type=none +fi ]) - - -# _LT_FORMAT_COMMENT([COMMENT]) -# ----------------------------- -# Add leading comment marks to the start of each line, and a trailing -# full-stop to the whole comment if one is not present already. -m4_define([_LT_FORMAT_COMMENT], -[m4_ifval([$1], [ -m4_bpatsubst([m4_bpatsubst([$1], [^ *], [# ])], - [['`$\]], [\\\&])]m4_bmatch([$1], [[!?.]$], [], [.]) -)]) - - - - - -# _LT_DECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION], [IS-TAGGED?]) -# ------------------------------------------------------------------- -# CONFIGNAME is the name given to the value in the libtool script. -# VARNAME is the (base) name used in the configure script. -# VALUE may be 0, 1 or 2 for a computed quote escaped value based on -# VARNAME. Any other value will be used directly. -m4_define([_LT_DECL], -[lt_if_append_uniq([lt_decl_varnames], [$2], [, ], - [lt_dict_add_subkey([lt_decl_dict], [$2], [libtool_name], - [m4_ifval([$1], [$1], [$2])]) - lt_dict_add_subkey([lt_decl_dict], [$2], [value], [$3]) - m4_ifval([$4], - [lt_dict_add_subkey([lt_decl_dict], [$2], [description], [$4])]) - lt_dict_add_subkey([lt_decl_dict], [$2], - [tagged?], [m4_ifval([$5], [yes], [no])])]) +AC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type]) +AM_CONDITIONAL([am__fastdep$1], [ + test "x$enable_dependency_tracking" != xno \ + && test "$am_cv_$1_dependencies_compiler_type" = gcc3]) ]) -# _LT_TAGDECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION]) -# -------------------------------------------------------- -m4_define([_LT_TAGDECL], [_LT_DECL([$1], [$2], [$3], [$4], [yes])]) - - -# lt_decl_tag_varnames([SEPARATOR], [VARNAME1...]) -# ------------------------------------------------ -m4_define([lt_decl_tag_varnames], -[_lt_decl_filter([tagged?], [yes], $@)]) - - -# _lt_decl_filter(SUBKEY, VALUE, [SEPARATOR], [VARNAME1..]) -# --------------------------------------------------------- -m4_define([_lt_decl_filter], -[m4_case([$#], - [0], [m4_fatal([$0: too few arguments: $#])], - [1], [m4_fatal([$0: too few arguments: $#: $1])], - [2], [lt_dict_filter([lt_decl_dict], [$1], [$2], [], lt_decl_varnames)], - [3], [lt_dict_filter([lt_decl_dict], [$1], [$2], [$3], lt_decl_varnames)], - [lt_dict_filter([lt_decl_dict], $@)])[]dnl +# AM_SET_DEPDIR +# ------------- +# Choose a directory name for dependency files. +# This macro is AC_REQUIREd in _AM_DEPENDENCIES +AC_DEFUN([AM_SET_DEPDIR], +[AC_REQUIRE([AM_SET_LEADING_DOT])dnl +AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl ]) -# lt_decl_quote_varnames([SEPARATOR], [VARNAME1...]) -# -------------------------------------------------- -m4_define([lt_decl_quote_varnames], -[_lt_decl_filter([value], [1], $@)]) - - -# lt_decl_dquote_varnames([SEPARATOR], [VARNAME1...]) -# --------------------------------------------------- -m4_define([lt_decl_dquote_varnames], -[_lt_decl_filter([value], [2], $@)]) - - -# lt_decl_varnames_tagged([SEPARATOR], [VARNAME1...]) -# --------------------------------------------------- -m4_define([lt_decl_varnames_tagged], -[m4_assert([$# <= 2])dnl -_$0(m4_quote(m4_default([$1], [[, ]])), - m4_ifval([$2], [[$2]], [m4_dquote(lt_decl_tag_varnames)]), - m4_split(m4_normalize(m4_quote(_LT_TAGS)), [ ]))]) -m4_define([_lt_decl_varnames_tagged], -[m4_ifval([$3], [lt_combine([$1], [$2], [_], $3)])]) - - -# lt_decl_all_varnames([SEPARATOR], [VARNAME1...]) -# ------------------------------------------------ -m4_define([lt_decl_all_varnames], -[_$0(m4_quote(m4_default([$1], [[, ]])), - m4_if([$2], [], - m4_quote(lt_decl_varnames), - m4_quote(m4_shift($@))))[]dnl -]) -m4_define([_lt_decl_all_varnames], -[lt_join($@, lt_decl_varnames_tagged([$1], - lt_decl_tag_varnames([[, ]], m4_shift($@))))dnl +# AM_DEP_TRACK +# ------------ +AC_DEFUN([AM_DEP_TRACK], +[AC_ARG_ENABLE(dependency-tracking, +[ --disable-dependency-tracking speeds up one-time build + --enable-dependency-tracking do not reject slow dependency extractors]) +if test "x$enable_dependency_tracking" != xno; then + am_depcomp="$ac_aux_dir/depcomp" + AMDEPBACKSLASH='\' +fi +AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno]) +AC_SUBST([AMDEPBACKSLASH])dnl +_AM_SUBST_NOTMAKE([AMDEPBACKSLASH])dnl ]) +# Generate code to set up dependency tracking. -*- Autoconf -*- -# _LT_CONFIG_STATUS_DECLARE([VARNAME]) -# ------------------------------------ -# Quote a variable value, and forward it to `config.status' so that its -# declaration there will have the same value as in `configure'. VARNAME -# must have a single quote delimited value for this to work. -m4_define([_LT_CONFIG_STATUS_DECLARE], -[$1='`$ECHO "X$][$1" | $Xsed -e "$delay_single_quote_subst"`']) - - -# _LT_CONFIG_STATUS_DECLARATIONS -# ------------------------------ -# We delimit libtool config variables with single quotes, so when -# we write them to config.status, we have to be sure to quote all -# embedded single quotes properly. In configure, this macro expands -# each variable declared with _LT_DECL (and _LT_TAGDECL) into: +# Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2008 +# Free Software Foundation, Inc. # -# ='`$ECHO "X$" | $Xsed -e "$delay_single_quote_subst"`' -m4_defun([_LT_CONFIG_STATUS_DECLARATIONS], -[m4_foreach([_lt_var], m4_quote(lt_decl_all_varnames), - [m4_n([_LT_CONFIG_STATUS_DECLARE(_lt_var)])])]) +# This file 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. +#serial 5 -# _LT_LIBTOOL_TAGS -# ---------------- -# Output comment and list of tags supported by the script -m4_defun([_LT_LIBTOOL_TAGS], -[_LT_FORMAT_COMMENT([The names of the tagged configurations supported by this script])dnl -available_tags="_LT_TAGS"dnl -]) +# _AM_OUTPUT_DEPENDENCY_COMMANDS +# ------------------------------ +AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS], +[{ + # Autoconf 2.62 quotes --file arguments for eval, but not when files + # are listed without --file. Let's play safe and only enable the eval + # if we detect the quoting. + case $CONFIG_FILES in + *\'*) eval set x "$CONFIG_FILES" ;; + *) set x $CONFIG_FILES ;; + esac + shift + for mf + do + # Strip MF so we end up with the name of the file. + mf=`echo "$mf" | sed -e 's/:.*$//'` + # Check whether this is an Automake generated Makefile or not. + # We used to match only the files named `Makefile.in', but + # some people rename them; so instead we look at the file content. + # Grep'ing the first line is not enough: some people post-process + # each Makefile.in and add a new line on top of each file to say so. + # Grep'ing the whole file is not good either: AIX grep has a line + # limit of 2048, but all sed's we know have understand at least 4000. + if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then + dirpart=`AS_DIRNAME("$mf")` + else + continue + fi + # Extract the definition of DEPDIR, am__include, and am__quote + # from the Makefile without running `make'. + DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"` + test -z "$DEPDIR" && continue + am__include=`sed -n 's/^am__include = //p' < "$mf"` + test -z "am__include" && continue + am__quote=`sed -n 's/^am__quote = //p' < "$mf"` + # When using ansi2knr, U may be empty or an underscore; expand it + U=`sed -n 's/^U = //p' < "$mf"` + # Find all dependency output files, they are included files with + # $(DEPDIR) in their names. We invoke sed twice because it is the + # simplest approach to changing $(DEPDIR) to its actual value in the + # expansion. + for file in `sed -n " + s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \ + sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do + # Make sure the directory exists. + test -f "$dirpart/$file" && continue + fdir=`AS_DIRNAME(["$file"])` + AS_MKDIR_P([$dirpart/$fdir]) + # echo "creating $dirpart/$file" + echo '# dummy' > "$dirpart/$file" + done + done +} +])# _AM_OUTPUT_DEPENDENCY_COMMANDS -# _LT_LIBTOOL_DECLARE(VARNAME, [TAG]) -# ----------------------------------- -# Extract the dictionary values for VARNAME (optionally with TAG) and -# expand to a commented shell variable setting: +# AM_OUTPUT_DEPENDENCY_COMMANDS +# ----------------------------- +# This macro should only be invoked once -- use via AC_REQUIRE. # -# # Some comment about what VAR is for. -# visible_name=$lt_internal_name -m4_define([_LT_LIBTOOL_DECLARE], -[_LT_FORMAT_COMMENT(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], - [description])))[]dnl -m4_pushdef([_libtool_name], - m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [libtool_name])))[]dnl -m4_case(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [value])), - [0], [_libtool_name=[$]$1], - [1], [_libtool_name=$lt_[]$1], - [2], [_libtool_name=$lt_[]$1], - [_libtool_name=lt_dict_fetch([lt_decl_dict], [$1], [value])])[]dnl -m4_ifval([$2], [_$2])[]m4_popdef([_libtool_name])[]dnl +# This code is only required when automatic dependency tracking +# is enabled. FIXME. This creates each `.P' file that we will +# need in order to bootstrap the dependency handling code. +AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS], +[AC_CONFIG_COMMANDS([depfiles], + [test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS], + [AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"]) ]) +# Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005 +# Free Software Foundation, Inc. +# +# This file 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. -# _LT_LIBTOOL_CONFIG_VARS -# ----------------------- -# Produce commented declarations of non-tagged libtool config variables -# suitable for insertion in the LIBTOOL CONFIG section of the `libtool' -# script. Tagged libtool config variables (even for the LIBTOOL CONFIG -# section) are produced by _LT_LIBTOOL_TAG_VARS. -m4_defun([_LT_LIBTOOL_CONFIG_VARS], -[m4_foreach([_lt_var], - m4_quote(_lt_decl_filter([tagged?], [no], [], lt_decl_varnames)), - [m4_n([_LT_LIBTOOL_DECLARE(_lt_var)])])]) - - -# _LT_LIBTOOL_TAG_VARS(TAG) -# ------------------------- -m4_define([_LT_LIBTOOL_TAG_VARS], -[m4_foreach([_lt_var], m4_quote(lt_decl_tag_varnames), - [m4_n([_LT_LIBTOOL_DECLARE(_lt_var, [$1])])])]) - +# serial 8 -# _LT_TAGVAR(VARNAME, [TAGNAME]) -# ------------------------------ -m4_define([_LT_TAGVAR], [m4_ifval([$2], [$1_$2], [$1])]) +# AM_CONFIG_HEADER is obsolete. It has been replaced by AC_CONFIG_HEADERS. +AU_DEFUN([AM_CONFIG_HEADER], [AC_CONFIG_HEADERS($@)]) +# Do all the work for Automake. -*- Autoconf -*- -# _LT_CONFIG_COMMANDS -# ------------------- -# Send accumulated output to $CONFIG_STATUS. Thanks to the lists of -# variables for single and double quote escaping we saved from calls -# to _LT_DECL, we can put quote escaped variables declarations -# into `config.status', and then the shell code to quote escape them in -# for loops in `config.status'. Finally, any additional code accumulated -# from calls to _LT_CONFIG_LIBTOOL_INIT is expanded. -m4_defun([_LT_CONFIG_COMMANDS], -[AC_PROVIDE_IFELSE([LT_OUTPUT], - dnl If the libtool generation code has been placed in $CONFIG_LT, - dnl instead of duplicating it all over again into config.status, - dnl then we will have config.status run $CONFIG_LT later, so it - dnl needs to know what name is stored there: - [AC_CONFIG_COMMANDS([libtool], - [$SHELL $CONFIG_LT || AS_EXIT(1)], [CONFIG_LT='$CONFIG_LT'])], - dnl If the libtool generation code is destined for config.status, - dnl expand the accumulated commands and init code now: - [AC_CONFIG_COMMANDS([libtool], - [_LT_OUTPUT_LIBTOOL_COMMANDS], [_LT_OUTPUT_LIBTOOL_COMMANDS_INIT])]) -])#_LT_CONFIG_COMMANDS - - -# Initialize. -m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS_INIT], -[ +# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, +# 2005, 2006, 2008, 2009 Free Software Foundation, Inc. +# +# This file 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. -# The HP-UX ksh and POSIX shell print the target directory to stdout -# if CDPATH is set. -(unset CDPATH) >/dev/null 2>&1 && unset CDPATH +# serial 16 -sed_quote_subst='$sed_quote_subst' -double_quote_subst='$double_quote_subst' -delay_variable_subst='$delay_variable_subst' -_LT_CONFIG_STATUS_DECLARATIONS -LTCC='$LTCC' -LTCFLAGS='$LTCFLAGS' -compiler='$compiler_DEFAULT' - -# Quote evaled strings. -for var in lt_decl_all_varnames([[ \ -]], lt_decl_quote_varnames); do - case \`eval \\\\\$ECHO "X\\\\\$\$var"\` in - *[[\\\\\\\`\\"\\\$]]*) - eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"X\\\$\$var\\" | \\\$Xsed -e \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" - ;; - *) - eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" - ;; - esac -done - -# Double-quote double-evaled strings. -for var in lt_decl_all_varnames([[ \ -]], lt_decl_dquote_varnames); do - case \`eval \\\\\$ECHO "X\\\\\$\$var"\` in - *[[\\\\\\\`\\"\\\$]]*) - eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"X\\\$\$var\\" | \\\$Xsed -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" - ;; - *) - eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" - ;; - esac -done - -# Fix-up fallback echo if it was mangled by the above quoting rules. -case \$lt_ECHO in -*'\\\[$]0 --fallback-echo"')dnl " - lt_ECHO=\`\$ECHO "X\$lt_ECHO" | \$Xsed -e 's/\\\\\\\\\\\\\\\[$]0 --fallback-echo"\[$]/\[$]0 --fallback-echo"/'\` - ;; -esac - -_LT_OUTPUT_LIBTOOL_INIT -]) +# This macro actually does too much. Some checks are only needed if +# your package does certain things. But this isn't really a big deal. +# AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE]) +# AM_INIT_AUTOMAKE([OPTIONS]) +# ----------------------------------------------- +# The call with PACKAGE and VERSION arguments is the old style +# call (pre autoconf-2.50), which is being phased out. PACKAGE +# and VERSION should now be passed to AC_INIT and removed from +# the call to AM_INIT_AUTOMAKE. +# We support both call styles for the transition. After +# the next Automake release, Autoconf can make the AC_INIT +# arguments mandatory, and then we can depend on a new Autoconf +# release and drop the old call support. +AC_DEFUN([AM_INIT_AUTOMAKE], +[AC_PREREQ([2.62])dnl +dnl Autoconf wants to disallow AM_ names. We explicitly allow +dnl the ones we care about. +m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl +AC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl +AC_REQUIRE([AC_PROG_INSTALL])dnl +if test "`cd $srcdir && pwd`" != "`pwd`"; then + # Use -I$(srcdir) only when $(srcdir) != ., so that make's output + # is not polluted with repeated "-I." + AC_SUBST([am__isrc], [' -I$(srcdir)'])_AM_SUBST_NOTMAKE([am__isrc])dnl + # test to see if srcdir already configured + if test -f $srcdir/config.status; then + AC_MSG_ERROR([source directory already configured; run "make distclean" there first]) + fi +fi -# LT_OUTPUT -# --------- -# This macro allows early generation of the libtool script (before -# AC_OUTPUT is called), incase it is used in configure for compilation -# tests. -AC_DEFUN([LT_OUTPUT], -[: ${CONFIG_LT=./config.lt} -AC_MSG_NOTICE([creating $CONFIG_LT]) -cat >"$CONFIG_LT" <<_LTEOF -#! $SHELL -# Generated by $as_me. -# Run this file to recreate a libtool stub with the current configuration. - -lt_cl_silent=false -SHELL=\${CONFIG_SHELL-$SHELL} -_LTEOF - -cat >>"$CONFIG_LT" <<\_LTEOF -AS_SHELL_SANITIZE -_AS_PREPARE - -exec AS_MESSAGE_FD>&1 -exec AS_MESSAGE_LOG_FD>>config.log -{ - echo - AS_BOX([Running $as_me.]) -} >&AS_MESSAGE_LOG_FD +# test whether we have cygpath +if test -z "$CYGPATH_W"; then + if (cygpath --version) >/dev/null 2>/dev/null; then + CYGPATH_W='cygpath -w' + else + CYGPATH_W=echo + fi +fi +AC_SUBST([CYGPATH_W]) -lt_cl_help="\ -\`$as_me' creates a local libtool stub from the current configuration, -for use in further configure time tests before the real libtool is -generated. +# Define the identity of the package. +dnl Distinguish between old-style and new-style calls. +m4_ifval([$2], +[m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl + AC_SUBST([PACKAGE], [$1])dnl + AC_SUBST([VERSION], [$2])], +[_AM_SET_OPTIONS([$1])dnl +dnl Diagnose old-style AC_INIT with new-style AM_AUTOMAKE_INIT. +m4_if(m4_ifdef([AC_PACKAGE_NAME], 1)m4_ifdef([AC_PACKAGE_VERSION], 1), 11,, + [m4_fatal([AC_INIT should be called with package and version arguments])])dnl + AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl + AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl -Usage: $[0] [[OPTIONS]] +_AM_IF_OPTION([no-define],, +[AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package]) + AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package])])dnl - -h, --help print this help, then exit - -V, --version print version number, then exit - -q, --quiet do not print progress messages - -d, --debug don't remove temporary files +# Some tools Automake needs. +AC_REQUIRE([AM_SANITY_CHECK])dnl +AC_REQUIRE([AC_ARG_PROGRAM])dnl +AM_MISSING_PROG(ACLOCAL, aclocal-${am__api_version}) +AM_MISSING_PROG(AUTOCONF, autoconf) +AM_MISSING_PROG(AUTOMAKE, automake-${am__api_version}) +AM_MISSING_PROG(AUTOHEADER, autoheader) +AM_MISSING_PROG(MAKEINFO, makeinfo) +AC_REQUIRE([AM_PROG_INSTALL_SH])dnl +AC_REQUIRE([AM_PROG_INSTALL_STRIP])dnl +AC_REQUIRE([AM_PROG_MKDIR_P])dnl +# We need awk for the "check" target. The system "awk" is bad on +# some platforms. +AC_REQUIRE([AC_PROG_AWK])dnl +AC_REQUIRE([AC_PROG_MAKE_SET])dnl +AC_REQUIRE([AM_SET_LEADING_DOT])dnl +_AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])], + [_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])], + [_AM_PROG_TAR([v7])])]) +_AM_IF_OPTION([no-dependencies],, +[AC_PROVIDE_IFELSE([AC_PROG_CC], + [_AM_DEPENDENCIES(CC)], + [define([AC_PROG_CC], + defn([AC_PROG_CC])[_AM_DEPENDENCIES(CC)])])dnl +AC_PROVIDE_IFELSE([AC_PROG_CXX], + [_AM_DEPENDENCIES(CXX)], + [define([AC_PROG_CXX], + defn([AC_PROG_CXX])[_AM_DEPENDENCIES(CXX)])])dnl +AC_PROVIDE_IFELSE([AC_PROG_OBJC], + [_AM_DEPENDENCIES(OBJC)], + [define([AC_PROG_OBJC], + defn([AC_PROG_OBJC])[_AM_DEPENDENCIES(OBJC)])])dnl +]) +_AM_IF_OPTION([silent-rules], [AC_REQUIRE([AM_SILENT_RULES])])dnl +dnl The `parallel-tests' driver may need to know about EXEEXT, so add the +dnl `am__EXEEXT' conditional if _AM_COMPILER_EXEEXT was seen. This macro +dnl is hooked onto _AC_COMPILER_EXEEXT early, see below. +AC_CONFIG_COMMANDS_PRE(dnl +[m4_provide_if([_AM_COMPILER_EXEEXT], + [AM_CONDITIONAL([am__EXEEXT], [test -n "$EXEEXT"])])])dnl +]) -Report bugs to ." +dnl Hook into `_AC_COMPILER_EXEEXT' early to learn its expansion. Do not +dnl add the conditional right here, as _AC_COMPILER_EXEEXT may be further +dnl mangled by Autoconf and run in a shell conditional statement. +m4_define([_AC_COMPILER_EXEEXT], +m4_defn([_AC_COMPILER_EXEEXT])[m4_provide([_AM_COMPILER_EXEEXT])]) -lt_cl_version="\ -m4_ifset([AC_PACKAGE_NAME], [AC_PACKAGE_NAME ])config.lt[]dnl -m4_ifset([AC_PACKAGE_VERSION], [ AC_PACKAGE_VERSION]) -configured by $[0], generated by m4_PACKAGE_STRING. -Copyright (C) 2008 Free Software Foundation, Inc. -This config.lt script is free software; the Free Software Foundation -gives unlimited permision to copy, distribute and modify it." +# When config.status generates a header, we must update the stamp-h file. +# This file resides in the same directory as the config header +# that is generated. The stamp files are numbered to have different names. -while test $[#] != 0 -do - case $[1] in - --version | --v* | -V ) - echo "$lt_cl_version"; exit 0 ;; - --help | --h* | -h ) - echo "$lt_cl_help"; exit 0 ;; - --debug | --d* | -d ) - debug=: ;; - --quiet | --q* | --silent | --s* | -q ) - lt_cl_silent=: ;; - - -*) AC_MSG_ERROR([unrecognized option: $[1] -Try \`$[0] --help' for more information.]) ;; - - *) AC_MSG_ERROR([unrecognized argument: $[1] -Try \`$[0] --help' for more information.]) ;; +# Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the +# loop where config.status creates the headers, so we can generate +# our stamp files there. +AC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK], +[# Compute $1's index in $config_headers. +_am_arg=$1 +_am_stamp_count=1 +for _am_header in $config_headers :; do + case $_am_header in + $_am_arg | $_am_arg:* ) + break ;; + * ) + _am_stamp_count=`expr $_am_stamp_count + 1` ;; esac - shift done +echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count]) -if $lt_cl_silent; then - exec AS_MESSAGE_FD>/dev/null -fi -_LTEOF - -cat >>"$CONFIG_LT" <<_LTEOF -_LT_OUTPUT_LIBTOOL_COMMANDS_INIT -_LTEOF - -cat >>"$CONFIG_LT" <<\_LTEOF -AC_MSG_NOTICE([creating $ofile]) -_LT_OUTPUT_LIBTOOL_COMMANDS -AS_EXIT(0) -_LTEOF -chmod +x "$CONFIG_LT" - -# configure is writing to config.log, but config.lt does its own redirection, -# appending to config.log, which fails on DOS, as config.log is still kept -# open by configure. Here we exec the FD to /dev/null, effectively closing -# config.log, so it can be properly (re)opened and appended to by config.lt. -if test "$no_create" != yes; then - lt_cl_success=: - test "$silent" = yes && - lt_config_lt_args="$lt_config_lt_args --quiet" - exec AS_MESSAGE_LOG_FD>/dev/null - $SHELL "$CONFIG_LT" $lt_config_lt_args || lt_cl_success=false - exec AS_MESSAGE_LOG_FD>>config.log - $lt_cl_success || AS_EXIT(1) -fi -])# LT_OUTPUT - - -# _LT_CONFIG(TAG) -# --------------- -# If TAG is the built-in tag, create an initial libtool script with a -# default configuration from the untagged config vars. Otherwise add code -# to config.status for appending the configuration named by TAG from the -# matching tagged config vars. -m4_defun([_LT_CONFIG], -[m4_require([_LT_FILEUTILS_DEFAULTS])dnl -_LT_CONFIG_SAVE_COMMANDS([ - m4_define([_LT_TAG], m4_if([$1], [], [C], [$1]))dnl - m4_if(_LT_TAG, [C], [ - # See if we are running on zsh, and set the options which allow our - # commands through without removal of \ escapes. - if test -n "${ZSH_VERSION+set}" ; then - setopt NO_GLOB_SUBST - fi - - cfgfile="${ofile}T" - trap "$RM \"$cfgfile\"; exit 1" 1 2 15 - $RM "$cfgfile" - - cat <<_LT_EOF >> "$cfgfile" -#! $SHELL - -# `$ECHO "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services. -# Generated automatically by $as_me ($PACKAGE$TIMESTAMP) $VERSION -# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: -# NOTE: Changes made to this file will be lost: look at ltmain.sh. +# Copyright (C) 2001, 2003, 2005, 2008 Free Software Foundation, Inc. # -_LT_COPYING -_LT_LIBTOOL_TAGS - -# ### BEGIN LIBTOOL CONFIG -_LT_LIBTOOL_CONFIG_VARS -_LT_LIBTOOL_TAG_VARS -# ### END LIBTOOL CONFIG - -_LT_EOF +# This file 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. - case $host_os in - aix3*) - cat <<\_LT_EOF >> "$cfgfile" -# AIX sometimes has problems with the GCC collect2 program. For some -# reason, if we set the COLLECT_NAMES environment variable, the problems -# vanish in a puff of smoke. -if test "X${COLLECT_NAMES+set}" != Xset; then - COLLECT_NAMES= - export COLLECT_NAMES -fi -_LT_EOF - ;; +# AM_PROG_INSTALL_SH +# ------------------ +# Define $install_sh. +AC_DEFUN([AM_PROG_INSTALL_SH], +[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl +if test x"${install_sh}" != xset; then + case $am_aux_dir in + *\ * | *\ *) + install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;; + *) + install_sh="\${SHELL} $am_aux_dir/install-sh" esac +fi +AC_SUBST(install_sh)]) - _LT_PROG_LTMAIN - - # We use sed instead of cat because bash on DJGPP gets confused if - # if finds mixed CR/LF and LF-only lines. Since sed operates in - # text mode, it properly converts lines to CR/LF. This bash problem - # is reportedly fixed, but why not run on old versions too? - sed '/^# Generated shell functions inserted here/q' "$ltmain" >> "$cfgfile" \ - || (rm -f "$cfgfile"; exit 1) - - _LT_PROG_XSI_SHELLFNS - - sed -n '/^# Generated shell functions inserted here/,$p' "$ltmain" >> "$cfgfile" \ - || (rm -f "$cfgfile"; exit 1) - - mv -f "$cfgfile" "$ofile" || - (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") - chmod +x "$ofile" -], -[cat <<_LT_EOF >> "$ofile" - -dnl Unfortunately we have to use $1 here, since _LT_TAG is not expanded -dnl in a comment (ie after a #). -# ### BEGIN LIBTOOL TAG CONFIG: $1 -_LT_LIBTOOL_TAG_VARS(_LT_TAG) -# ### END LIBTOOL TAG CONFIG: $1 -_LT_EOF -])dnl /m4_if -], -[m4_if([$1], [], [ - PACKAGE='$PACKAGE' - VERSION='$VERSION' - TIMESTAMP='$TIMESTAMP' - RM='$RM' - ofile='$ofile'], []) -])dnl /_LT_CONFIG_SAVE_COMMANDS -])# _LT_CONFIG - - -# LT_SUPPORTED_TAG(TAG) -# --------------------- -# Trace this macro to discover what tags are supported by the libtool -# --tag option, using: -# autoconf --trace 'LT_SUPPORTED_TAG:$1' -AC_DEFUN([LT_SUPPORTED_TAG], []) - +# Copyright (C) 2003, 2005 Free Software Foundation, Inc. +# +# This file 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. -# C support is built-in for now -m4_define([_LT_LANG_C_enabled], []) -m4_define([_LT_TAGS], []) +# serial 2 +# Check whether the underlying file-system supports filenames +# with a leading dot. For instance MS-DOS doesn't. +AC_DEFUN([AM_SET_LEADING_DOT], +[rm -rf .tst 2>/dev/null +mkdir .tst 2>/dev/null +if test -d .tst; then + am__leading_dot=. +else + am__leading_dot=_ +fi +rmdir .tst 2>/dev/null +AC_SUBST([am__leading_dot])]) -# LT_LANG(LANG) -# ------------- -# Enable libtool support for the given language if not already enabled. -AC_DEFUN([LT_LANG], -[AC_BEFORE([$0], [LT_OUTPUT])dnl -m4_case([$1], - [C], [_LT_LANG(C)], - [C++], [_LT_LANG(CXX)], - [Java], [_LT_LANG(GCJ)], - [Fortran 77], [_LT_LANG(F77)], - [Fortran], [_LT_LANG(FC)], - [Windows Resource], [_LT_LANG(RC)], - [m4_ifdef([_LT_LANG_]$1[_CONFIG], - [_LT_LANG($1)], - [m4_fatal([$0: unsupported language: "$1"])])])dnl -])# LT_LANG - - -# _LT_LANG(LANGNAME) -# ------------------ -m4_defun([_LT_LANG], -[m4_ifdef([_LT_LANG_]$1[_enabled], [], - [LT_SUPPORTED_TAG([$1])dnl - m4_append([_LT_TAGS], [$1 ])dnl - m4_define([_LT_LANG_]$1[_enabled], [])dnl - _LT_LANG_$1_CONFIG($1)])dnl -])# _LT_LANG +# Add --enable-maintainer-mode option to configure. -*- Autoconf -*- +# From Jim Meyering +# Copyright (C) 1996, 1998, 2000, 2001, 2002, 2003, 2004, 2005, 2008 +# Free Software Foundation, Inc. +# +# This file 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. -# _LT_LANG_DEFAULT_CONFIG -# ----------------------- -m4_defun([_LT_LANG_DEFAULT_CONFIG], -[AC_PROVIDE_IFELSE([AC_PROG_CXX], - [LT_LANG(CXX)], - [m4_define([AC_PROG_CXX], defn([AC_PROG_CXX])[LT_LANG(CXX)])]) - -AC_PROVIDE_IFELSE([AC_PROG_F77], - [LT_LANG(F77)], - [m4_define([AC_PROG_F77], defn([AC_PROG_F77])[LT_LANG(F77)])]) - -AC_PROVIDE_IFELSE([AC_PROG_FC], - [LT_LANG(FC)], - [m4_define([AC_PROG_FC], defn([AC_PROG_FC])[LT_LANG(FC)])]) - -dnl The call to [A][M_PROG_GCJ] is quoted like that to stop aclocal -dnl pulling things in needlessly. -AC_PROVIDE_IFELSE([AC_PROG_GCJ], - [LT_LANG(GCJ)], - [AC_PROVIDE_IFELSE([A][M_PROG_GCJ], - [LT_LANG(GCJ)], - [AC_PROVIDE_IFELSE([LT_PROG_GCJ], - [LT_LANG(GCJ)], - [m4_ifdef([AC_PROG_GCJ], - [m4_define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[LT_LANG(GCJ)])]) - m4_ifdef([A][M_PROG_GCJ], - [m4_define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[LT_LANG(GCJ)])]) - m4_ifdef([LT_PROG_GCJ], - [m4_define([LT_PROG_GCJ], defn([LT_PROG_GCJ])[LT_LANG(GCJ)])])])])]) - -AC_PROVIDE_IFELSE([LT_PROG_RC], - [LT_LANG(RC)], - [m4_define([LT_PROG_RC], defn([LT_PROG_RC])[LT_LANG(RC)])]) -])# _LT_LANG_DEFAULT_CONFIG - -# Obsolete macros: -AU_DEFUN([AC_LIBTOOL_CXX], [LT_LANG(C++)]) -AU_DEFUN([AC_LIBTOOL_F77], [LT_LANG(Fortran 77)]) -AU_DEFUN([AC_LIBTOOL_FC], [LT_LANG(Fortran)]) -AU_DEFUN([AC_LIBTOOL_GCJ], [LT_LANG(Java)]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_LIBTOOL_CXX], []) -dnl AC_DEFUN([AC_LIBTOOL_F77], []) -dnl AC_DEFUN([AC_LIBTOOL_FC], []) -dnl AC_DEFUN([AC_LIBTOOL_GCJ], []) - - -# _LT_TAG_COMPILER -# ---------------- -m4_defun([_LT_TAG_COMPILER], -[AC_REQUIRE([AC_PROG_CC])dnl +# serial 5 -_LT_DECL([LTCC], [CC], [1], [A C compiler])dnl -_LT_DECL([LTCFLAGS], [CFLAGS], [1], [LTCC compiler flags])dnl -_LT_TAGDECL([CC], [compiler], [1], [A language specific compiler])dnl -_LT_TAGDECL([with_gcc], [GCC], [0], [Is the compiler the GNU compiler?])dnl +# AM_MAINTAINER_MODE([DEFAULT-MODE]) +# ---------------------------------- +# Control maintainer-specific portions of Makefiles. +# Default is to disable them, unless `enable' is passed literally. +# For symmetry, `disable' may be passed as well. Anyway, the user +# can override the default with the --enable/--disable switch. +AC_DEFUN([AM_MAINTAINER_MODE], +[m4_case(m4_default([$1], [disable]), + [enable], [m4_define([am_maintainer_other], [disable])], + [disable], [m4_define([am_maintainer_other], [enable])], + [m4_define([am_maintainer_other], [enable]) + m4_warn([syntax], [unexpected argument to AM@&t@_MAINTAINER_MODE: $1])]) +AC_MSG_CHECKING([whether to am_maintainer_other maintainer-specific portions of Makefiles]) + dnl maintainer-mode's default is 'disable' unless 'enable' is passed + AC_ARG_ENABLE([maintainer-mode], +[ --][am_maintainer_other][-maintainer-mode am_maintainer_other make rules and dependencies not useful + (and sometimes confusing) to the casual installer], + [USE_MAINTAINER_MODE=$enableval], + [USE_MAINTAINER_MODE=]m4_if(am_maintainer_other, [enable], [no], [yes])) + AC_MSG_RESULT([$USE_MAINTAINER_MODE]) + AM_CONDITIONAL([MAINTAINER_MODE], [test $USE_MAINTAINER_MODE = yes]) + MAINT=$MAINTAINER_MODE_TRUE + AC_SUBST([MAINT])dnl +] +) -# If no C compiler was specified, use CC. -LTCC=${LTCC-"$CC"} +AU_DEFUN([jm_MAINTAINER_MODE], [AM_MAINTAINER_MODE]) -# If no C compiler flags were specified, use CFLAGS. -LTCFLAGS=${LTCFLAGS-"$CFLAGS"} +# Check to see how 'make' treats includes. -*- Autoconf -*- -# Allow CC to be a program name with arguments. -compiler=$CC -])# _LT_TAG_COMPILER +# Copyright (C) 2001, 2002, 2003, 2005, 2009 Free Software Foundation, Inc. +# +# This file 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. +# serial 4 -# _LT_COMPILER_BOILERPLATE -# ------------------------ -# Check for compiler boilerplate output or warnings with -# the simple compiler test code. -m4_defun([_LT_COMPILER_BOILERPLATE], -[m4_require([_LT_DECL_SED])dnl -ac_outfile=conftest.$ac_objext -echo "$lt_simple_compile_test_code" >conftest.$ac_ext -eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err -_lt_compiler_boilerplate=`cat conftest.err` -$RM conftest* -])# _LT_COMPILER_BOILERPLATE +# AM_MAKE_INCLUDE() +# ----------------- +# Check to see how make treats includes. +AC_DEFUN([AM_MAKE_INCLUDE], +[am_make=${MAKE-make} +cat > confinc << 'END' +am__doit: + @echo this is the am__doit target +.PHONY: am__doit +END +# If we don't find an include directive, just comment out the code. +AC_MSG_CHECKING([for style of include used by $am_make]) +am__include="#" +am__quote= +_am_result=none +# First try GNU make style include. +echo "include confinc" > confmf +# Ignore all kinds of additional output from `make'. +case `$am_make -s -f confmf 2> /dev/null` in #( +*the\ am__doit\ target*) + am__include=include + am__quote= + _am_result=GNU + ;; +esac +# Now try BSD make style include. +if test "$am__include" = "#"; then + echo '.include "confinc"' > confmf + case `$am_make -s -f confmf 2> /dev/null` in #( + *the\ am__doit\ target*) + am__include=.include + am__quote="\"" + _am_result=BSD + ;; + esac +fi +AC_SUBST([am__include]) +AC_SUBST([am__quote]) +AC_MSG_RESULT([$_am_result]) +rm -f confinc confmf +]) +# Fake the existence of programs that GNU maintainers use. -*- Autoconf -*- -# _LT_LINKER_BOILERPLATE -# ---------------------- -# Check for linker boilerplate output or warnings with -# the simple link test code. -m4_defun([_LT_LINKER_BOILERPLATE], -[m4_require([_LT_DECL_SED])dnl -ac_outfile=conftest.$ac_objext -echo "$lt_simple_link_test_code" >conftest.$ac_ext -eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err -_lt_linker_boilerplate=`cat conftest.err` -$RM -r conftest* -])# _LT_LINKER_BOILERPLATE +# Copyright (C) 1997, 1999, 2000, 2001, 2003, 2004, 2005, 2008 +# Free Software Foundation, Inc. +# +# This file 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. -# _LT_REQUIRED_DARWIN_CHECKS -# ------------------------- -m4_defun_once([_LT_REQUIRED_DARWIN_CHECKS],[ - case $host_os in - rhapsody* | darwin*) - AC_CHECK_TOOL([DSYMUTIL], [dsymutil], [:]) - AC_CHECK_TOOL([NMEDIT], [nmedit], [:]) - AC_CHECK_TOOL([LIPO], [lipo], [:]) - AC_CHECK_TOOL([OTOOL], [otool], [:]) - AC_CHECK_TOOL([OTOOL64], [otool64], [:]) - _LT_DECL([], [DSYMUTIL], [1], - [Tool to manipulate archived DWARF debug symbol files on Mac OS X]) - _LT_DECL([], [NMEDIT], [1], - [Tool to change global to local symbols on Mac OS X]) - _LT_DECL([], [LIPO], [1], - [Tool to manipulate fat objects and archives on Mac OS X]) - _LT_DECL([], [OTOOL], [1], - [ldd/readelf like tool for Mach-O binaries on Mac OS X]) - _LT_DECL([], [OTOOL64], [1], - [ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4]) +# serial 6 - AC_CACHE_CHECK([for -single_module linker flag],[lt_cv_apple_cc_single_mod], - [lt_cv_apple_cc_single_mod=no - if test -z "${LT_MULTI_MODULE}"; then - # By default we will add the -single_module flag. You can override - # by either setting the environment variable LT_MULTI_MODULE - # non-empty at configure time, or by adding -multi_module to the - # link flags. - rm -rf libconftest.dylib* - echo "int foo(void){return 1;}" > conftest.c - echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ --dynamiclib -Wl,-single_module conftest.c" >&AS_MESSAGE_LOG_FD - $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ - -dynamiclib -Wl,-single_module conftest.c 2>conftest.err - _lt_result=$? - if test -f libconftest.dylib && test ! -s conftest.err && test $_lt_result = 0; then - lt_cv_apple_cc_single_mod=yes - else - cat conftest.err >&AS_MESSAGE_LOG_FD - fi - rm -rf libconftest.dylib* - rm -f conftest.* - fi]) - AC_CACHE_CHECK([for -exported_symbols_list linker flag], - [lt_cv_ld_exported_symbols_list], - [lt_cv_ld_exported_symbols_list=no - save_LDFLAGS=$LDFLAGS - echo "_main" > conftest.sym - LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym" - AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])], - [lt_cv_ld_exported_symbols_list=yes], - [lt_cv_ld_exported_symbols_list=no]) - LDFLAGS="$save_LDFLAGS" - ]) - case $host_os in - rhapsody* | darwin1.[[012]]) - _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;; - darwin1.*) - _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; - darwin*) # darwin 5.x on - # if running on 10.5 or later, the deployment target defaults - # to the OS version, if on x86, and 10.4, the deployment - # target defaults to 10.4. Don't you love it? - case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in - 10.0,*86*-darwin8*|10.0,*-darwin[[91]]*) - _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; - 10.[[012]]*) - _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; - 10.*) - _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; - esac - ;; - esac - if test "$lt_cv_apple_cc_single_mod" = "yes"; then - _lt_dar_single_mod='$single_module' - fi - if test "$lt_cv_ld_exported_symbols_list" = "yes"; then - _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym' - else - _lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}' - fi - if test "$DSYMUTIL" != ":"; then - _lt_dsymutil='~$DSYMUTIL $lib || :' - else - _lt_dsymutil= - fi - ;; - esac -]) +# AM_MISSING_PROG(NAME, PROGRAM) +# ------------------------------ +AC_DEFUN([AM_MISSING_PROG], +[AC_REQUIRE([AM_MISSING_HAS_RUN]) +$1=${$1-"${am_missing_run}$2"} +AC_SUBST($1)]) -# _LT_DARWIN_LINKER_FEATURES -# -------------------------- -# Checks for linker and compiler features on darwin -m4_defun([_LT_DARWIN_LINKER_FEATURES], -[ - m4_require([_LT_REQUIRED_DARWIN_CHECKS]) - _LT_TAGVAR(archive_cmds_need_lc, $1)=no - _LT_TAGVAR(hardcode_direct, $1)=no - _LT_TAGVAR(hardcode_automatic, $1)=yes - _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported - _LT_TAGVAR(whole_archive_flag_spec, $1)='' - _LT_TAGVAR(link_all_deplibs, $1)=yes - _LT_TAGVAR(allow_undefined_flag, $1)="$_lt_dar_allow_undefined" - case $cc_basename in - ifort*) _lt_dar_can_shared=yes ;; - *) _lt_dar_can_shared=$GCC ;; +# AM_MISSING_HAS_RUN +# ------------------ +# Define MISSING if not defined so far and test if it supports --run. +# If it does, set am_missing_run to use it, otherwise, to nothing. +AC_DEFUN([AM_MISSING_HAS_RUN], +[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl +AC_REQUIRE_AUX_FILE([missing])dnl +if test x"${MISSING+set}" != xset; then + case $am_aux_dir in + *\ * | *\ *) + MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;; + *) + MISSING="\${SHELL} $am_aux_dir/missing" ;; esac - if test "$_lt_dar_can_shared" = "yes"; then - output_verbose_link_cmd=echo - _LT_TAGVAR(archive_cmds, $1)="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}" - _LT_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}" - _LT_TAGVAR(archive_expsym_cmds, $1)="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}" - _LT_TAGVAR(module_expsym_cmds, $1)="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}" - m4_if([$1], [CXX], -[ if test "$lt_cv_apple_cc_single_mod" != "yes"; then - _LT_TAGVAR(archive_cmds, $1)="\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dsymutil}" - _LT_TAGVAR(archive_expsym_cmds, $1)="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dar_export_syms}${_lt_dsymutil}" - fi -],[]) - else - _LT_TAGVAR(ld_shlibs, $1)=no - fi +fi +# Use eval to expand $SHELL +if eval "$MISSING --run true"; then + am_missing_run="$MISSING --run " +else + am_missing_run= + AC_MSG_WARN([`missing' script is too old or missing]) +fi ]) -# _LT_SYS_MODULE_PATH_AIX -# ----------------------- -# Links a minimal program and checks the executable -# for the system default hardcoded library path. In most cases, -# this is /usr/lib:/lib, but when the MPI compilers are used -# the location of the communication and MPI libs are included too. -# If we don't find anything, use the default library path according -# to the aix ld manual. -m4_defun([_LT_SYS_MODULE_PATH_AIX], -[m4_require([_LT_DECL_SED])dnl -AC_LINK_IFELSE(AC_LANG_PROGRAM,[ -lt_aix_libpath_sed=' - /Import File Strings/,/^$/ { - /^0/ { - s/^0 *\(.*\)$/\1/ - p - } - }' -aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` -# Check for a 64-bit object if we didn't find anything. -if test -z "$aix_libpath"; then - aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` -fi],[]) -if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi -])# _LT_SYS_MODULE_PATH_AIX +# Copyright (C) 2003, 2004, 2005, 2006 Free Software Foundation, Inc. +# +# This file 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. +# AM_PROG_MKDIR_P +# --------------- +# Check for `mkdir -p'. +AC_DEFUN([AM_PROG_MKDIR_P], +[AC_PREREQ([2.60])dnl +AC_REQUIRE([AC_PROG_MKDIR_P])dnl +dnl Automake 1.8 to 1.9.6 used to define mkdir_p. We now use MKDIR_P, +dnl while keeping a definition of mkdir_p for backward compatibility. +dnl @MKDIR_P@ is magic: AC_OUTPUT adjusts its value for each Makefile. +dnl However we cannot define mkdir_p as $(MKDIR_P) for the sake of +dnl Makefile.ins that do not define MKDIR_P, so we do our own +dnl adjustment using top_builddir (which is defined more often than +dnl MKDIR_P). +AC_SUBST([mkdir_p], ["$MKDIR_P"])dnl +case $mkdir_p in + [[\\/$]]* | ?:[[\\/]]*) ;; + */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;; +esac +]) -# _LT_SHELL_INIT(ARG) -# ------------------- -m4_define([_LT_SHELL_INIT], -[ifdef([AC_DIVERSION_NOTICE], - [AC_DIVERT_PUSH(AC_DIVERSION_NOTICE)], - [AC_DIVERT_PUSH(NOTICE)]) -$1 -AC_DIVERT_POP -])# _LT_SHELL_INIT +# Helper functions for option handling. -*- Autoconf -*- +# Copyright (C) 2001, 2002, 2003, 2005, 2008 Free Software Foundation, Inc. +# +# This file 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. -# _LT_PROG_ECHO_BACKSLASH -# ----------------------- -# Add some code to the start of the generated configure script which -# will find an echo command which doesn't interpret backslashes. -m4_defun([_LT_PROG_ECHO_BACKSLASH], -[_LT_SHELL_INIT([ -# Check that we are running under the correct shell. -SHELL=${CONFIG_SHELL-/bin/sh} +# serial 4 -case X$lt_ECHO in -X*--fallback-echo) - # Remove one level of quotation (which was required for Make). - ECHO=`echo "$lt_ECHO" | sed 's,\\\\\[$]\\[$]0,'[$]0','` - ;; -esac +# _AM_MANGLE_OPTION(NAME) +# ----------------------- +AC_DEFUN([_AM_MANGLE_OPTION], +[[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])]) -ECHO=${lt_ECHO-echo} -if test "X[$]1" = X--no-reexec; then - # Discard the --no-reexec flag, and continue. - shift -elif test "X[$]1" = X--fallback-echo; then - # Avoid inline document here, it may be left over - : -elif test "X`{ $ECHO '\t'; } 2>/dev/null`" = 'X\t' ; then - # Yippee, $ECHO works! - : -else - # Restart under the correct shell. - exec $SHELL "[$]0" --no-reexec ${1+"[$]@"} -fi +# _AM_SET_OPTION(NAME) +# ------------------------------ +# Set option NAME. Presently that only means defining a flag for this option. +AC_DEFUN([_AM_SET_OPTION], +[m4_define(_AM_MANGLE_OPTION([$1]), 1)]) -if test "X[$]1" = X--fallback-echo; then - # used as fallback echo - shift - cat <<_LT_EOF -[$]* -_LT_EOF - exit 0 -fi +# _AM_SET_OPTIONS(OPTIONS) +# ---------------------------------- +# OPTIONS is a space-separated list of Automake options. +AC_DEFUN([_AM_SET_OPTIONS], +[m4_foreach_w([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])]) -# The HP-UX ksh and POSIX shell print the target directory to stdout -# if CDPATH is set. -(unset CDPATH) >/dev/null 2>&1 && unset CDPATH +# _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET]) +# ------------------------------------------- +# Execute IF-SET if OPTION is set, IF-NOT-SET otherwise. +AC_DEFUN([_AM_IF_OPTION], +[m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])]) -if test -z "$lt_ECHO"; then - if test "X${echo_test_string+set}" != Xset; then - # find a string as large as possible, as long as the shell can cope with it - for cmd in 'sed 50q "[$]0"' 'sed 20q "[$]0"' 'sed 10q "[$]0"' 'sed 2q "[$]0"' 'echo test'; do - # expected sizes: less than 2Kb, 1Kb, 512 bytes, 16 bytes, ... - if { echo_test_string=`eval $cmd`; } 2>/dev/null && - { test "X$echo_test_string" = "X$echo_test_string"; } 2>/dev/null - then - break - fi - done - fi +# Check to make sure that the build environment is sane. -*- Autoconf -*- - if test "X`{ $ECHO '\t'; } 2>/dev/null`" = 'X\t' && - echo_testing_string=`{ $ECHO "$echo_test_string"; } 2>/dev/null` && - test "X$echo_testing_string" = "X$echo_test_string"; then - : - else - # The Solaris, AIX, and Digital Unix default echo programs unquote - # backslashes. This makes it impossible to quote backslashes using - # echo "$something" | sed 's/\\/\\\\/g' - # - # So, first we look for a working echo in the user's PATH. +# Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005, 2008 +# Free Software Foundation, Inc. +# +# This file 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. - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR - for dir in $PATH /usr/ucb; do - IFS="$lt_save_ifs" - if (test -f $dir/echo || test -f $dir/echo$ac_exeext) && - test "X`($dir/echo '\t') 2>/dev/null`" = 'X\t' && - echo_testing_string=`($dir/echo "$echo_test_string") 2>/dev/null` && - test "X$echo_testing_string" = "X$echo_test_string"; then - ECHO="$dir/echo" - break - fi - done - IFS="$lt_save_ifs" +# serial 5 - if test "X$ECHO" = Xecho; then - # We didn't find a better echo, so look for alternatives. - if test "X`{ print -r '\t'; } 2>/dev/null`" = 'X\t' && - echo_testing_string=`{ print -r "$echo_test_string"; } 2>/dev/null` && - test "X$echo_testing_string" = "X$echo_test_string"; then - # This shell has a builtin print -r that does the trick. - ECHO='print -r' - elif { test -f /bin/ksh || test -f /bin/ksh$ac_exeext; } && - test "X$CONFIG_SHELL" != X/bin/ksh; then - # If we have ksh, try running configure again with it. - ORIGINAL_CONFIG_SHELL=${CONFIG_SHELL-/bin/sh} - export ORIGINAL_CONFIG_SHELL - CONFIG_SHELL=/bin/ksh - export CONFIG_SHELL - exec $CONFIG_SHELL "[$]0" --no-reexec ${1+"[$]@"} - else - # Try using printf. - ECHO='printf %s\n' - if test "X`{ $ECHO '\t'; } 2>/dev/null`" = 'X\t' && - echo_testing_string=`{ $ECHO "$echo_test_string"; } 2>/dev/null` && - test "X$echo_testing_string" = "X$echo_test_string"; then - # Cool, printf works - : - elif echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` && - test "X$echo_testing_string" = 'X\t' && - echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` && - test "X$echo_testing_string" = "X$echo_test_string"; then - CONFIG_SHELL=$ORIGINAL_CONFIG_SHELL - export CONFIG_SHELL - SHELL="$CONFIG_SHELL" - export SHELL - ECHO="$CONFIG_SHELL [$]0 --fallback-echo" - elif echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` && - test "X$echo_testing_string" = 'X\t' && - echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` && - test "X$echo_testing_string" = "X$echo_test_string"; then - ECHO="$CONFIG_SHELL [$]0 --fallback-echo" - else - # maybe with a smaller string... - prev=: +# AM_SANITY_CHECK +# --------------- +AC_DEFUN([AM_SANITY_CHECK], +[AC_MSG_CHECKING([whether build environment is sane]) +# Just in case +sleep 1 +echo timestamp > conftest.file +# Reject unsafe characters in $srcdir or the absolute working directory +# name. Accept space and tab only in the latter. +am_lf=' +' +case `pwd` in + *[[\\\"\#\$\&\'\`$am_lf]]*) + AC_MSG_ERROR([unsafe absolute working directory name]);; +esac +case $srcdir in + *[[\\\"\#\$\&\'\`$am_lf\ \ ]]*) + AC_MSG_ERROR([unsafe srcdir value: `$srcdir']);; +esac - for cmd in 'echo test' 'sed 2q "[$]0"' 'sed 10q "[$]0"' 'sed 20q "[$]0"' 'sed 50q "[$]0"'; do - if { test "X$echo_test_string" = "X`eval $cmd`"; } 2>/dev/null - then - break - fi - prev="$cmd" - done +# Do `set' in a subshell so we don't clobber the current shell's +# arguments. Must try -L first in case configure is actually a +# symlink; some systems play weird games with the mod time of symlinks +# (eg FreeBSD returns the mod time of the symlink's containing +# directory). +if ( + set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null` + if test "$[*]" = "X"; then + # -L didn't work. + set X `ls -t "$srcdir/configure" conftest.file` + fi + rm -f conftest.file + if test "$[*]" != "X $srcdir/configure conftest.file" \ + && test "$[*]" != "X conftest.file $srcdir/configure"; then - if test "$prev" != 'sed 50q "[$]0"'; then - echo_test_string=`eval $prev` - export echo_test_string - exec ${ORIGINAL_CONFIG_SHELL-${CONFIG_SHELL-/bin/sh}} "[$]0" ${1+"[$]@"} - else - # Oops. We lost completely, so just stick with echo. - ECHO=echo - fi - fi - fi - fi - fi -fi + # If neither matched, then we have a broken ls. This can happen + # if, for instance, CONFIG_SHELL is bash and it inherits a + # broken ls alias from the environment. This has actually + # happened. Such a system could not be considered "sane". + AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken +alias in your environment]) + fi -# Copy echo and quote the copy suitably for passing to libtool from -# the Makefile, instead of quoting the original, which is used later. -lt_ECHO=$ECHO -if test "X$lt_ECHO" = "X$CONFIG_SHELL [$]0 --fallback-echo"; then - lt_ECHO="$CONFIG_SHELL \\\$\[$]0 --fallback-echo" + test "$[2]" = conftest.file + ) +then + # Ok. + : +else + AC_MSG_ERROR([newly created file is older than distributed files! +Check your system clock]) fi +AC_MSG_RESULT(yes)]) -AC_SUBST(lt_ECHO) -]) -_LT_DECL([], [SHELL], [1], [Shell to use when invoking shell scripts]) -_LT_DECL([], [ECHO], [1], - [An echo program that does not interpret backslashes]) -])# _LT_PROG_ECHO_BACKSLASH +# Copyright (C) 2009 Free Software Foundation, Inc. +# +# This file 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. +# serial 1 -# _LT_ENABLE_LOCK -# --------------- -m4_defun([_LT_ENABLE_LOCK], -[AC_ARG_ENABLE([libtool-lock], - [AS_HELP_STRING([--disable-libtool-lock], - [avoid locking (might break parallel builds)])]) -test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes +# AM_SILENT_RULES([DEFAULT]) +# -------------------------- +# Enable less verbose build rules; with the default set to DEFAULT +# (`yes' being less verbose, `no' or empty being verbose). +AC_DEFUN([AM_SILENT_RULES], +[AC_ARG_ENABLE([silent-rules], +[ --enable-silent-rules less verbose build output (undo: `make V=1') + --disable-silent-rules verbose build output (undo: `make V=0')]) +case $enable_silent_rules in +yes) AM_DEFAULT_VERBOSITY=0;; +no) AM_DEFAULT_VERBOSITY=1;; +*) AM_DEFAULT_VERBOSITY=m4_if([$1], [yes], [0], [1]);; +esac +AC_SUBST([AM_DEFAULT_VERBOSITY])dnl +AM_BACKSLASH='\' +AC_SUBST([AM_BACKSLASH])dnl +_AM_SUBST_NOTMAKE([AM_BACKSLASH])dnl +]) -# Some flags need to be propagated to the compiler or linker for good -# libtool support. -case $host in -ia64-*-hpux*) - # Find out which ABI we are using. - echo 'int i;' > conftest.$ac_ext - if AC_TRY_EVAL(ac_compile); then - case `/usr/bin/file conftest.$ac_objext` in - *ELF-32*) - HPUX_IA64_MODE="32" - ;; - *ELF-64*) - HPUX_IA64_MODE="64" - ;; - esac - fi - rm -rf conftest* - ;; -*-*-irix6*) - # Find out which ABI we are using. - echo '[#]line __oline__ "configure"' > conftest.$ac_ext - if AC_TRY_EVAL(ac_compile); then - if test "$lt_cv_prog_gnu_ld" = yes; then - case `/usr/bin/file conftest.$ac_objext` in - *32-bit*) - LD="${LD-ld} -melf32bsmip" - ;; - *N32*) - LD="${LD-ld} -melf32bmipn32" - ;; - *64-bit*) - LD="${LD-ld} -melf64bmip" - ;; - esac - else - case `/usr/bin/file conftest.$ac_objext` in - *32-bit*) - LD="${LD-ld} -32" - ;; - *N32*) - LD="${LD-ld} -n32" - ;; - *64-bit*) - LD="${LD-ld} -64" - ;; - esac - fi - fi - rm -rf conftest* - ;; +# Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc. +# +# This file 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. -x86_64-*kfreebsd*-gnu|x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*| \ -s390*-*linux*|s390*-*tpf*|sparc*-*linux*) - # Find out which ABI we are using. - echo 'int i;' > conftest.$ac_ext - if AC_TRY_EVAL(ac_compile); then - case `/usr/bin/file conftest.o` in - *32-bit*) - case $host in - x86_64-*kfreebsd*-gnu) - LD="${LD-ld} -m elf_i386_fbsd" - ;; - x86_64-*linux*) - LD="${LD-ld} -m elf_i386" - ;; - ppc64-*linux*|powerpc64-*linux*) - LD="${LD-ld} -m elf32ppclinux" - ;; - s390x-*linux*) - LD="${LD-ld} -m elf_s390" - ;; - sparc64-*linux*) - LD="${LD-ld} -m elf32_sparc" - ;; - esac - ;; - *64-bit*) - case $host in - x86_64-*kfreebsd*-gnu) - LD="${LD-ld} -m elf_x86_64_fbsd" - ;; - x86_64-*linux*) - LD="${LD-ld} -m elf_x86_64" - ;; - ppc*-*linux*|powerpc*-*linux*) - LD="${LD-ld} -m elf64ppc" - ;; - s390*-*linux*|s390*-*tpf*) - LD="${LD-ld} -m elf64_s390" - ;; - sparc*-*linux*) - LD="${LD-ld} -m elf64_sparc" - ;; - esac - ;; - esac - fi - rm -rf conftest* - ;; +# AM_PROG_INSTALL_STRIP +# --------------------- +# One issue with vendor `install' (even GNU) is that you can't +# specify the program used to strip binaries. This is especially +# annoying in cross-compiling environments, where the build's strip +# is unlikely to handle the host's binaries. +# Fortunately install-sh will honor a STRIPPROG variable, so we +# always use install-sh in `make install-strip', and initialize +# STRIPPROG with the value of the STRIP variable (set by the user). +AC_DEFUN([AM_PROG_INSTALL_STRIP], +[AC_REQUIRE([AM_PROG_INSTALL_SH])dnl +# Installed binaries are usually stripped using `strip' when the user +# run `make install-strip'. However `strip' might not be the right +# tool to use in cross-compilation environments, therefore Automake +# will honor the `STRIP' environment variable to overrule this program. +dnl Don't test for $cross_compiling = yes, because it might be `maybe'. +if test "$cross_compiling" != no; then + AC_CHECK_TOOL([STRIP], [strip], :) +fi +INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s" +AC_SUBST([INSTALL_STRIP_PROGRAM])]) -*-*-sco3.2v5*) - # On SCO OpenServer 5, we need -belf to get full-featured binaries. - SAVE_CFLAGS="$CFLAGS" - CFLAGS="$CFLAGS -belf" - AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf, - [AC_LANG_PUSH(C) - AC_LINK_IFELSE([AC_LANG_PROGRAM([[]],[[]])],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no]) - AC_LANG_POP]) - if test x"$lt_cv_cc_needs_belf" != x"yes"; then - # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf - CFLAGS="$SAVE_CFLAGS" - fi - ;; -sparc*-*solaris*) - # Find out which ABI we are using. - echo 'int i;' > conftest.$ac_ext - if AC_TRY_EVAL(ac_compile); then - case `/usr/bin/file conftest.o` in - *64-bit*) - case $lt_cv_prog_gnu_ld in - yes*) LD="${LD-ld} -m elf64_sparc" ;; - *) - if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then - LD="${LD-ld} -64" - fi - ;; - esac - ;; - esac - fi - rm -rf conftest* - ;; -esac +# Copyright (C) 2006, 2008 Free Software Foundation, Inc. +# +# This file 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. -need_locks="$enable_libtool_lock" -])# _LT_ENABLE_LOCK +# serial 2 +# _AM_SUBST_NOTMAKE(VARIABLE) +# --------------------------- +# Prevent Automake from outputting VARIABLE = @VARIABLE@ in Makefile.in. +# This macro is traced by Automake. +AC_DEFUN([_AM_SUBST_NOTMAKE]) -# _LT_CMD_OLD_ARCHIVE -# ------------------- -m4_defun([_LT_CMD_OLD_ARCHIVE], -[AC_CHECK_TOOL(AR, ar, false) -test -z "$AR" && AR=ar -test -z "$AR_FLAGS" && AR_FLAGS=cru -_LT_DECL([], [AR], [1], [The archiver]) -_LT_DECL([], [AR_FLAGS], [1]) +# AM_SUBST_NOTMAKE(VARIABLE) +# --------------------------- +# Public sister of _AM_SUBST_NOTMAKE. +AC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)]) -AC_CHECK_TOOL(STRIP, strip, :) -test -z "$STRIP" && STRIP=: -_LT_DECL([], [STRIP], [1], [A symbol stripping program]) +# Check how to create a tarball. -*- Autoconf -*- -AC_CHECK_TOOL(RANLIB, ranlib, :) -test -z "$RANLIB" && RANLIB=: -_LT_DECL([], [RANLIB], [1], - [Commands used to install an old-style archive]) +# Copyright (C) 2004, 2005 Free Software Foundation, Inc. +# +# This file 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. -# Determine commands to create old-style static archives. -old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs' -old_postinstall_cmds='chmod 644 $oldlib' -old_postuninstall_cmds= +# serial 2 -if test -n "$RANLIB"; then - case $host_os in - openbsd*) - old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$oldlib" - ;; - *) - old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$oldlib" +# _AM_PROG_TAR(FORMAT) +# -------------------- +# Check how to create a tarball in format FORMAT. +# FORMAT should be one of `v7', `ustar', or `pax'. +# +# Substitute a variable $(am__tar) that is a command +# writing to stdout a FORMAT-tarball containing the directory +# $tardir. +# tardir=directory && $(am__tar) > result.tar +# +# Substitute a variable $(am__untar) that extract such +# a tarball read from stdin. +# $(am__untar) < result.tar +AC_DEFUN([_AM_PROG_TAR], +[# Always define AMTAR for backward compatibility. +AM_MISSING_PROG([AMTAR], [tar]) +m4_if([$1], [v7], + [am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'], + [m4_case([$1], [ustar],, [pax],, + [m4_fatal([Unknown tar format])]) +AC_MSG_CHECKING([how to create a $1 tar archive]) +# Loop over all known methods to create a tar archive until one works. +_am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none' +_am_tools=${am_cv_prog_tar_$1-$_am_tools} +# Do not fold the above two line into one, because Tru64 sh and +# Solaris sh will not grok spaces in the rhs of `-'. +for _am_tool in $_am_tools +do + case $_am_tool in + gnutar) + for _am_tar in tar gnutar gtar; + do + AM_RUN_LOG([$_am_tar --version]) && break + done + am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"' + am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"' + am__untar="$_am_tar -xf -" + ;; + plaintar) + # Must skip GNU tar: if it does not support --format= it doesn't create + # ustar tarball either. + (tar --version) >/dev/null 2>&1 && continue + am__tar='tar chf - "$$tardir"' + am__tar_='tar chf - "$tardir"' + am__untar='tar xf -' + ;; + pax) + am__tar='pax -L -x $1 -w "$$tardir"' + am__tar_='pax -L -x $1 -w "$tardir"' + am__untar='pax -r' + ;; + cpio) + am__tar='find "$$tardir" -print | cpio -o -H $1 -L' + am__tar_='find "$tardir" -print | cpio -o -H $1 -L' + am__untar='cpio -i -H $1 -d' + ;; + none) + am__tar=false + am__tar_=false + am__untar=false ;; esac - old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib" -fi -_LT_DECL([], [old_postinstall_cmds], [2]) -_LT_DECL([], [old_postuninstall_cmds], [2]) -_LT_TAGDECL([], [old_archive_cmds], [2], - [Commands used to build an old-style archive]) -])# _LT_CMD_OLD_ARCHIVE + # If the value was cached, stop now. We just wanted to have am__tar + # and am__untar set. + test -n "${am_cv_prog_tar_$1}" && break -# _LT_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, -# [OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE]) -# ---------------------------------------------------------------- -# Check whether the given compiler option works -AC_DEFUN([_LT_COMPILER_OPTION], -[m4_require([_LT_FILEUTILS_DEFAULTS])dnl -m4_require([_LT_DECL_SED])dnl -AC_CACHE_CHECK([$1], [$2], - [$2=no - m4_if([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4]) - echo "$lt_simple_compile_test_code" > conftest.$ac_ext - lt_compiler_flag="$3" - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - # The option is referenced via a variable to avoid confusing sed. - lt_compile=`echo "$ac_compile" | $SED \ - -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:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD) - (eval "$lt_compile" 2>conftest.err) - ac_status=$? - cat conftest.err >&AS_MESSAGE_LOG_FD - echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD - 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. - $ECHO "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp - $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 - if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then - $2=yes - fi - fi - $RM conftest* -]) + # tar/untar a dummy directory, and stop if the command works + rm -rf conftest.dir + mkdir conftest.dir + echo GrepMe > conftest.dir/file + AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar]) + rm -rf conftest.dir + if test -s conftest.tar; then + AM_RUN_LOG([$am__untar /dev/null 2>&1 && break + fi +done +rm -rf conftest.dir -if test x"[$]$2" = xyes; then - m4_if([$5], , :, [$5]) -else - m4_if([$6], , :, [$6]) -fi -])# _LT_COMPILER_OPTION +AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool]) +AC_MSG_RESULT([$am_cv_prog_tar_$1])]) +AC_SUBST([am__tar]) +AC_SUBST([am__untar]) +]) # _AM_PROG_TAR -# Old name: -AU_ALIAS([AC_LIBTOOL_COMPILER_OPTION], [_LT_COMPILER_OPTION]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION], []) +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 +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 +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 +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. +# XORG_MACROS_VERSION(required-version) +# ------------------------------------- +# Minimum version: 1.1.0 +# +# If you're using a macro added in Version 1.1 or newer, include this in +# your configure.ac with the minimum required version, such as: +# XORG_MACROS_VERSION(1.1) +# +# To ensure that this macro is defined, also add: +# m4_ifndef([XORG_MACROS_VERSION], +# [m4_fatal([must install xorg-macros 1.1 or later before running autoconf/autogen])]) +# +# +# 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([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,, + [m4_fatal([xorg-macros major version ]maj_needed[ is required but ]vers_have[ found])]) +m4_if(m4_version_compare(vers_have, [$1]), -1, + [m4_fatal([xorg-macros version $1 or higher is required but ]vers_have[ found])]) +m4_undefine([vers_have]) +m4_undefine([maj_have]) +m4_undefine([maj_needed]) +]) # XORG_MACROS_VERSION -# _LT_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, -# [ACTION-SUCCESS], [ACTION-FAILURE]) -# ---------------------------------------------------- -# Check whether the given linker option works -AC_DEFUN([_LT_LINKER_OPTION], -[m4_require([_LT_FILEUTILS_DEFAULTS])dnl -m4_require([_LT_DECL_SED])dnl -AC_CACHE_CHECK([$1], [$2], - [$2=no - save_LDFLAGS="$LDFLAGS" - LDFLAGS="$LDFLAGS $3" - echo "$lt_simple_link_test_code" > conftest.$ac_ext - if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then - # The linker can only warn and ignore the option if not recognized - # So say no if there are warnings - if test -s conftest.err; then - # Append any errors to the config.log. - cat conftest.err 1>&AS_MESSAGE_LOG_FD - $ECHO "X$_lt_linker_boilerplate" | $Xsed -e '/^$/d' > conftest.exp - $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 - if diff conftest.exp conftest.er2 >/dev/null; then - $2=yes - fi - else - $2=yes - fi - fi - $RM -r conftest* - LDFLAGS="$save_LDFLAGS" -]) +# XORG_PROG_RAWCPP() +# ------------------ +# Minimum version: 1.0.0 +# +# Find cpp program and necessary flags for use in pre-processing text files +# such as man pages and config files +AC_DEFUN([XORG_PROG_RAWCPP],[ +AC_REQUIRE([AC_PROG_CPP]) +AC_PATH_PROGS(RAWCPP, [cpp], [${CPP}], + [$PATH:/bin:/usr/bin:/usr/lib:/usr/libexec:/usr/ccs/lib:/usr/ccs/lbin:/lib]) -if test x"[$]$2" = xyes; then - m4_if([$4], , :, [$4]) +# Check for flag to avoid builtin definitions - assumes unix is predefined, +# which is not the best choice for supporting other OS'es, but covers most +# of the ones we need for now. +AC_MSG_CHECKING([if $RAWCPP requires -undef]) +AC_LANG_CONFTEST([Does cpp redefine unix ?]) +if test `${RAWCPP} < conftest.$ac_ext | grep -c 'unix'` -eq 1 ; then + AC_MSG_RESULT([no]) else - m4_if([$5], , :, [$5]) + if test `${RAWCPP} -undef < conftest.$ac_ext | grep -c 'unix'` -eq 1 ; then + RAWCPPFLAGS=-undef + AC_MSG_RESULT([yes]) + # under Cygwin unix is still defined even with -undef + elif test `${RAWCPP} -undef -ansi < conftest.$ac_ext | grep -c 'unix'` -eq 1 ; then + RAWCPPFLAGS="-undef -ansi" + AC_MSG_RESULT([yes, with -ansi]) + else + AC_MSG_ERROR([${RAWCPP} defines unix with or without -undef. I don't know what to do.]) + fi fi -])# _LT_LINKER_OPTION +rm -f conftest.$ac_ext -# Old name: -AU_ALIAS([AC_LIBTOOL_LINKER_OPTION], [_LT_LINKER_OPTION]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_LIBTOOL_LINKER_OPTION], []) +AC_MSG_CHECKING([if $RAWCPP requires -traditional]) +AC_LANG_CONFTEST([Does cpp preserve "whitespace"?]) +if test `${RAWCPP} < conftest.$ac_ext | grep -c 'preserve \"'` -eq 1 ; then + AC_MSG_RESULT([no]) +else + if test `${RAWCPP} -traditional < conftest.$ac_ext | grep -c 'preserve \"'` -eq 1 ; then + RAWCPPFLAGS="${RAWCPPFLAGS} -traditional" + AC_MSG_RESULT([yes]) + else + AC_MSG_ERROR([${RAWCPP} does not preserve whitespace with or without -traditional. I don't know what to do.]) + fi +fi +rm -f conftest.$ac_ext +AC_SUBST(RAWCPPFLAGS) +]) # XORG_PROG_RAWCPP +# XORG_MANPAGE_SECTIONS() +# ----------------------- +# Minimum version: 1.0.0 +# +# Determine which sections man pages go in for the different man page types +# 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 -# LT_CMD_MAX_LEN -#--------------- -AC_DEFUN([LT_CMD_MAX_LEN], -[AC_REQUIRE([AC_CANONICAL_HOST])dnl -# find the maximum length of command line arguments -AC_MSG_CHECKING([the maximum length of command line arguments]) -AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl - i=0 - teststring="ABCD" +AC_DEFUN([XORG_MANPAGE_SECTIONS],[ +AC_REQUIRE([AC_CANONICAL_HOST]) - case $build_os in - msdosdjgpp*) - # On DJGPP, this test can blow up pretty badly due to problems in libc - # (any single argument exceeding 2000 bytes causes a buffer overrun - # during glob expansion). Even if it were fixed, the result of this - # check would be larger than it should be. - lt_cv_sys_max_cmd_len=12288; # 12K is about right - ;; - - gnu*) - # Under GNU Hurd, this test is not required because there is - # no limit to the length of command line arguments. - # Libtool will interpret -1 as no limit whatsoever - lt_cv_sys_max_cmd_len=-1; - ;; - - cygwin* | mingw* | cegcc*) - # On Win9x/ME, this test blows up -- it succeeds, but takes - # about 5 minutes as the teststring grows exponentially. - # Worse, since 9x/ME are not pre-emptively multitasking, - # you end up with a "frozen" computer, even though with patience - # the test eventually succeeds (with a max line length of 256k). - # Instead, let's just punt: use the minimum linelength reported by - # all of the supported platforms: 8192 (on NT/2K/XP). - lt_cv_sys_max_cmd_len=8192; - ;; +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 - amigaos*) - # On AmigaOS with pdksh, this test takes hours, literally. - # So we just punt and use a minimum line length of 8192. - lt_cv_sys_max_cmd_len=8192; - ;; +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 - netbsd* | freebsd* | openbsd* | darwin* | dragonfly*) - # This has been around since 386BSD, at least. Likely further. - if test -x /sbin/sysctl; then - lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` - elif test -x /usr/sbin/sysctl; then - lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax` - else - lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs - fi - # And add a safety zone - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` - ;; +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 - interix*) - # We know the value 262144 and hardcode it with a safety zone (like BSD) - lt_cv_sys_max_cmd_len=196608 - ;; +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 - osf*) - # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure - # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not - # nice to cause kernel panics so lets avoid the loop below. - # First set a reasonable default. - lt_cv_sys_max_cmd_len=16384 - # - if test -x /sbin/sysconfig; then - case `/sbin/sysconfig -q proc exec_disable_arg_limit` in - *1*) lt_cv_sys_max_cmd_len=-1 ;; - esac - fi - ;; - sco3.2v5*) - lt_cv_sys_max_cmd_len=102400 - ;; - sysv5* | sco5v6* | sysv4.2uw2*) - kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null` - if test -n "$kargmax"; then - lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[[ ]]//'` - else - lt_cv_sys_max_cmd_len=32768 - fi - ;; - *) - lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null` - if test -n "$lt_cv_sys_max_cmd_len"; then - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` - else - # Make teststring a little bigger before we do anything with it. - # a 1K string should be a reasonable start. - for i in 1 2 3 4 5 6 7 8 ; do - teststring=$teststring$teststring - done - SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}} - # If test is not a shell built-in, we'll probably end up computing a - # maximum length that is only half of the actual maximum length, but - # we can't tell. - while { test "X"`$SHELL [$]0 --fallback-echo "X$teststring$teststring" 2>/dev/null` \ - = "XX$teststring$teststring"; } >/dev/null 2>&1 && - test $i != 17 # 1/2 MB should be enough - do - i=`expr $i + 1` - teststring=$teststring$teststring - done - # Only check the string length outside the loop. - lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1` - teststring= - # Add a significant safety factor because C++ compilers can tack on - # massive amounts of additional arguments before passing them to the - # linker. It appears as though 1/2 is a usable value. - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2` - fi - ;; - esac -]) -if test -n $lt_cv_sys_max_cmd_len ; then - AC_MSG_RESULT($lt_cv_sys_max_cmd_len) -else - AC_MSG_RESULT(none) +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 -max_cmd_len=$lt_cv_sys_max_cmd_len -_LT_DECL([], [max_cmd_len], [0], - [What is the maximum length of a command?]) -])# LT_CMD_MAX_LEN -# Old name: -AU_ALIAS([AC_LIBTOOL_SYS_MAX_CMD_LEN], [LT_CMD_MAX_LEN]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN], []) +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 -# _LT_HEADER_DLFCN -# ---------------- -m4_defun([_LT_HEADER_DLFCN], -[AC_CHECK_HEADERS([dlfcn.h], [], [], [AC_INCLUDES_DEFAULT])dnl -])# _LT_HEADER_DLFCN +AC_SUBST([APP_MAN_SUFFIX]) +AC_SUBST([LIB_MAN_SUFFIX]) +AC_SUBST([FILE_MAN_SUFFIX]) +AC_SUBST([MISC_MAN_SUFFIX]) +AC_SUBST([DRIVER_MAN_SUFFIX]) +AC_SUBST([ADMIN_MAN_SUFFIX]) +AC_SUBST([APP_MAN_DIR]) +AC_SUBST([LIB_MAN_DIR]) +AC_SUBST([FILE_MAN_DIR]) +AC_SUBST([MISC_MAN_DIR]) +AC_SUBST([DRIVER_MAN_DIR]) +AC_SUBST([ADMIN_MAN_DIR]) +]) # XORG_MANPAGE_SECTIONS +# XORG_CHECK_LINUXDOC +# ------------------- +# Minimum version: 1.0.0 +# +# Defines the variable MAKE_TEXT if the necessary tools and +# files are found. $(MAKE_TEXT) blah.sgml will then produce blah.txt. +# 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= -# _LT_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE, -# ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING) -# ---------------------------------------------------------------- -m4_defun([_LT_TRY_DLOPEN_SELF], -[m4_require([_LT_HEADER_DLFCN])dnl -if test "$cross_compiling" = yes; then : - [$4] +if test x"$cross_compiling" = x"yes" ; then + HAVE_DEFS_ENT=no else - lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 - lt_status=$lt_dlunknown - cat > conftest.$ac_ext <<_LT_EOF -[#line __oline__ "configure" -#include "confdefs.h" + AC_CHECK_FILE([$XORG_SGML_PATH/X11/defs.ent], [HAVE_DEFS_ENT=yes]) +fi -#if HAVE_DLFCN_H -#include -#endif +AC_PATH_PROG(LINUXDOC, linuxdoc) +AC_PATH_PROG(PS2PDF, ps2pdf) -#include +AC_MSG_CHECKING([Whether to build documentation]) -#ifdef RTLD_GLOBAL -# define LT_DLGLOBAL RTLD_GLOBAL -#else -# ifdef DL_GLOBAL -# define LT_DLGLOBAL DL_GLOBAL -# else -# define LT_DLGLOBAL 0 -# endif -#endif +if test x$HAVE_DEFS_ENT != x && test x$LINUXDOC != x ; then + BUILDDOC=yes +else + BUILDDOC=no +fi -/* We may have to define LT_DLLAZY_OR_NOW in the command line if we - find out it does not work in some platform. */ -#ifndef LT_DLLAZY_OR_NOW -# ifdef RTLD_LAZY -# define LT_DLLAZY_OR_NOW RTLD_LAZY -# else -# ifdef DL_LAZY -# define LT_DLLAZY_OR_NOW DL_LAZY -# else -# ifdef RTLD_NOW -# define LT_DLLAZY_OR_NOW RTLD_NOW -# else -# ifdef DL_NOW -# define LT_DLLAZY_OR_NOW DL_NOW -# else -# define LT_DLLAZY_OR_NOW 0 -# endif -# endif -# endif -# endif -#endif +AM_CONDITIONAL(BUILD_LINUXDOC, [test x$BUILDDOC = xyes]) -void fnord() { int i=42;} -int main () -{ - void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); - int status = $lt_dlunknown; +AC_MSG_RESULT([$BUILDDOC]) - if (self) - { - if (dlsym (self,"fnord")) status = $lt_dlno_uscore; - else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; - /* dlclose (self); */ - } - else - puts (dlerror ()); +AC_MSG_CHECKING([Whether to build pdf documentation]) - return status; -}] -_LT_EOF - if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext} 2>/dev/null; then - (./conftest; exit; ) >&AS_MESSAGE_LOG_FD 2>/dev/null - lt_status=$? - case x$lt_status in - x$lt_dlno_uscore) $1 ;; - x$lt_dlneed_uscore) $2 ;; - x$lt_dlunknown|x*) $3 ;; - esac - else : - # compilation failed - $3 - fi +if test x$PS2PDF != x && test x$BUILD_PDFDOC != xno; then + BUILDPDFDOC=yes +else + BUILDPDFDOC=no fi -rm -fr conftest* -])# _LT_TRY_DLOPEN_SELF +AM_CONDITIONAL(BUILD_PDFDOC, [test x$BUILDPDFDOC = xyes]) -# LT_SYS_DLOPEN_SELF -# ------------------ -AC_DEFUN([LT_SYS_DLOPEN_SELF], -[m4_require([_LT_HEADER_DLFCN])dnl -if test "x$enable_dlopen" != xyes; then - enable_dlopen=unknown - enable_dlopen_self=unknown - enable_dlopen_self_static=unknown -else - lt_cv_dlopen=no - lt_cv_dlopen_libs= - - case $host_os in - beos*) - lt_cv_dlopen="load_add_on" - lt_cv_dlopen_libs= - lt_cv_dlopen_self=yes - ;; - - mingw* | pw32* | cegcc*) - lt_cv_dlopen="LoadLibrary" - lt_cv_dlopen_libs= - ;; - - cygwin*) - lt_cv_dlopen="dlopen" - lt_cv_dlopen_libs= - ;; - - darwin*) - # if libdl is installed we need to link against it - AC_CHECK_LIB([dl], [dlopen], - [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],[ - lt_cv_dlopen="dyld" - lt_cv_dlopen_libs= - lt_cv_dlopen_self=yes - ]) - ;; - - *) - AC_CHECK_FUNC([shl_load], - [lt_cv_dlopen="shl_load"], - [AC_CHECK_LIB([dld], [shl_load], - [lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld"], - [AC_CHECK_FUNC([dlopen], - [lt_cv_dlopen="dlopen"], - [AC_CHECK_LIB([dl], [dlopen], - [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"], - [AC_CHECK_LIB([svld], [dlopen], - [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"], - [AC_CHECK_LIB([dld], [dld_link], - [lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"]) - ]) - ]) - ]) - ]) - ]) - ;; - esac - - if test "x$lt_cv_dlopen" != xno; then - enable_dlopen=yes - else - enable_dlopen=no - fi - - case $lt_cv_dlopen in - dlopen) - save_CPPFLAGS="$CPPFLAGS" - test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" +AC_MSG_RESULT([$BUILDPDFDOC]) - save_LDFLAGS="$LDFLAGS" - wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" +MAKE_TEXT="SGML_SEARCH_PATH=$XORG_SGML_PATH GROFF_NO_SGR=y $LINUXDOC -B txt" +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" - save_LIBS="$LIBS" - LIBS="$lt_cv_dlopen_libs $LIBS" +AC_SUBST(MAKE_TEXT) +AC_SUBST(MAKE_PS) +AC_SUBST(MAKE_PDF) +AC_SUBST(MAKE_HTML) +]) # XORG_CHECK_LINUXDOC - AC_CACHE_CHECK([whether a program can dlopen itself], - lt_cv_dlopen_self, [dnl - _LT_TRY_DLOPEN_SELF( - lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes, - lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross) - ]) +# XORG_CHECK_DOCBOOK +# ------------------- +# Minimum version: 1.0.0 +# +# Checks for the ability to build output formats from SGML DocBook source. +# For XXX in {TXT, PDF, PS, HTML}, the AM_CONDITIONAL "BUILD_XXXDOC" +# 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= +BUILDTXTDOC=no +BUILDPDFDOC=no +BUILDPSDOC=no +BUILDHTMLDOC=no - if test "x$lt_cv_dlopen_self" = xyes; then - wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\" - AC_CACHE_CHECK([whether a statically linked program can dlopen itself], - lt_cv_dlopen_self_static, [dnl - _LT_TRY_DLOPEN_SELF( - lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes, - lt_cv_dlopen_self_static=no, lt_cv_dlopen_self_static=cross) - ]) - fi +AC_CHECK_FILE([$XORG_SGML_PATH/X11/defs.ent], [HAVE_DEFS_ENT=yes]) - CPPFLAGS="$save_CPPFLAGS" - LDFLAGS="$save_LDFLAGS" - LIBS="$save_LIBS" - ;; - esac +AC_PATH_PROG(DOCBOOKPS, docbook2ps) +AC_PATH_PROG(DOCBOOKPDF, docbook2pdf) +AC_PATH_PROG(DOCBOOKHTML, docbook2html) +AC_PATH_PROG(DOCBOOKTXT, docbook2txt) - case $lt_cv_dlopen_self in - yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; - *) enable_dlopen_self=unknown ;; - esac +AC_MSG_CHECKING([Whether to build text documentation]) +if test x$HAVE_DEFS_ENT != 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]) - case $lt_cv_dlopen_self_static in - yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;; - *) enable_dlopen_self_static=unknown ;; - esac +AC_MSG_CHECKING([Whether to build PDF documentation]) +if test x$HAVE_DEFS_ENT != x && test x$DOCBOOKPDF != x && + test x$BUILD_PDFDOC != xno; then + BUILDPDFDOC=yes fi -_LT_DECL([dlopen_support], [enable_dlopen], [0], - [Whether dlopen is supported]) -_LT_DECL([dlopen_self], [enable_dlopen_self], [0], - [Whether dlopen of programs is supported]) -_LT_DECL([dlopen_self_static], [enable_dlopen_self_static], [0], - [Whether dlopen of statically linked programs is supported]) -])# LT_SYS_DLOPEN_SELF +AM_CONDITIONAL(BUILD_PDFDOC, [test x$BUILDPDFDOC = xyes]) +AC_MSG_RESULT([$BUILDPDFDOC]) -# Old name: -AU_ALIAS([AC_LIBTOOL_DLOPEN_SELF], [LT_SYS_DLOPEN_SELF]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF], []) +AC_MSG_CHECKING([Whether to build PostScript documentation]) +if test x$HAVE_DEFS_ENT != 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 && + test x$BUILD_HTMLDOC != xno; then + BUILDHTMLDOC=yes +fi +AM_CONDITIONAL(BUILD_HTMLDOC, [test x$BUILDHTMLDOC = xyes]) +AC_MSG_RESULT([$BUILDHTMLDOC]) -# _LT_COMPILER_C_O([TAGNAME]) -# --------------------------- -# Check to see if options -c and -o are simultaneously supported by compiler. -# This macro does not hard code the compiler like AC_PROG_CC_C_O. -m4_defun([_LT_COMPILER_C_O], -[m4_require([_LT_DECL_SED])dnl -m4_require([_LT_FILEUTILS_DEFAULTS])dnl -m4_require([_LT_TAG_COMPILER])dnl -AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext], - [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)], - [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no - $RM -r conftest 2>/dev/null - mkdir conftest - cd conftest - mkdir out - echo "$lt_simple_compile_test_code" > conftest.$ac_ext +MAKE_TEXT="SGML_SEARCH_PATH=$XORG_SGML_PATH $DOCBOOKTXT" +MAKE_PS="SGML_SEARCH_PATH=$XORG_SGML_PATH $DOCBOOKPS" +MAKE_PDF="SGML_SEARCH_PATH=$XORG_SGML_PATH $DOCBOOKPDF" +MAKE_HTML="SGML_SEARCH_PATH=$XORG_SGML_PATH $DOCBOOKHTML" - lt_compiler_flag="-o out/conftest2.$ac_objext" - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - lt_compile=`echo "$ac_compile" | $SED \ - -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:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD) - (eval "$lt_compile" 2>out/conftest.err) - ac_status=$? - cat out/conftest.err >&AS_MESSAGE_LOG_FD - echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD - if (exit $ac_status) && test -s out/conftest2.$ac_objext - then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings - $ECHO "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp - $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 - if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then - _LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes - fi - fi - chmod u+w . 2>&AS_MESSAGE_LOG_FD - $RM conftest* - # SGI C++ compiler will create directory out/ii_files/ for - # template instantiation - test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files - $RM out/* && rmdir out - cd .. - $RM -r conftest - $RM conftest* -]) -_LT_TAGDECL([compiler_c_o], [lt_cv_prog_compiler_c_o], [1], - [Does compiler simultaneously support -c and -o options?]) -])# _LT_COMPILER_C_O +AC_SUBST(MAKE_TEXT) +AC_SUBST(MAKE_PS) +AC_SUBST(MAKE_PDF) +AC_SUBST(MAKE_HTML) +]) # XORG_CHECK_DOCBOOK +# XORG_CHECK_MALLOC_ZERO +# ---------------------- +# Minimum version: 1.0.0 +# +# Defines {MALLOC,XMALLOC,XTMALLOC}_ZERO_CFLAGS appropriately if +# malloc(0) returns NULL. Packages should add one of these cflags to +# their AM_CFLAGS (or other appropriate *_CFLAGS) to use them. +AC_DEFUN([XORG_CHECK_MALLOC_ZERO],[ +AC_ARG_ENABLE(malloc0returnsnull, + AS_HELP_STRING([--enable-malloc0returnsnull], + [malloc(0) returns NULL (default: auto)]), + [MALLOC_ZERO_RETURNS_NULL=$enableval], + [MALLOC_ZERO_RETURNS_NULL=auto]) -# _LT_COMPILER_FILE_LOCKS([TAGNAME]) -# ---------------------------------- -# Check to see if we can do hard links to lock some files if needed -m4_defun([_LT_COMPILER_FILE_LOCKS], -[m4_require([_LT_ENABLE_LOCK])dnl -m4_require([_LT_FILEUTILS_DEFAULTS])dnl -_LT_COMPILER_C_O([$1]) +AC_MSG_CHECKING([whether malloc(0) returns NULL]) +if test "x$MALLOC_ZERO_RETURNS_NULL" = xauto; then + AC_RUN_IFELSE([ +char *malloc(); +char *realloc(); +char *calloc(); +main() { + char *m0, *r0, *c0, *p; + m0 = malloc(0); + p = malloc(10); + r0 = realloc(p,0); + c0 = calloc(0); + exit(m0 == 0 || r0 == 0 || c0 == 0 ? 0 : 1); +}], + [MALLOC_ZERO_RETURNS_NULL=yes], + [MALLOC_ZERO_RETURNS_NULL=no]) +fi +AC_MSG_RESULT([$MALLOC_ZERO_RETURNS_NULL]) -hard_links="nottested" -if test "$_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)" = no && test "$need_locks" != no; then - # do not overwrite the value of need_locks provided by the user - AC_MSG_CHECKING([if we can lock with hard links]) - hard_links=yes - $RM conftest* - ln conftest.a conftest.b 2>/dev/null && hard_links=no - touch conftest.a - ln conftest.a conftest.b 2>&5 || hard_links=no - ln conftest.a conftest.b 2>/dev/null && hard_links=no - AC_MSG_RESULT([$hard_links]) - if test "$hard_links" = no; then - AC_MSG_WARN([`$CC' does not support `-c -o', so `make -j' may be unsafe]) - need_locks=warn - fi +if test "x$MALLOC_ZERO_RETURNS_NULL" = xyes; then + MALLOC_ZERO_CFLAGS="-DMALLOC_0_RETURNS_NULL" + XMALLOC_ZERO_CFLAGS=$MALLOC_ZERO_CFLAGS + XTMALLOC_ZERO_CFLAGS="$MALLOC_ZERO_CFLAGS -DXTMALLOC_BC" else - need_locks=no + MALLOC_ZERO_CFLAGS="" + XMALLOC_ZERO_CFLAGS="" + XTMALLOC_ZERO_CFLAGS="" fi -_LT_DECL([], [need_locks], [1], [Must we lock files when doing compilation?]) -])# _LT_COMPILER_FILE_LOCKS +AC_SUBST([MALLOC_ZERO_CFLAGS]) +AC_SUBST([XMALLOC_ZERO_CFLAGS]) +AC_SUBST([XTMALLOC_ZERO_CFLAGS]) +]) # XORG_CHECK_MALLOC_ZERO -# _LT_CHECK_OBJDIR +# XORG_WITH_LINT() # ---------------- -m4_defun([_LT_CHECK_OBJDIR], -[AC_CACHE_CHECK([for objdir], [lt_cv_objdir], -[rm -f .libs 2>/dev/null -mkdir .libs 2>/dev/null -if test -d .libs; then - lt_cv_objdir=.libs +# 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) +# +AC_DEFUN([XORG_WITH_LINT],[ + +# Allow checking code with lint, sparse, etc. +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" else - # MS-DOS does not allow filenames that begin with a dot. - lt_cv_objdir=_libs + LINT="$use_lint" +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 fi -rmdir .libs 2>/dev/null]) -objdir=$lt_cv_objdir -_LT_DECL([], [objdir], [0], - [The name of the directory that contains temporary libtool files])dnl -m4_pattern_allow([LT_OBJDIR])dnl -AC_DEFINE_UNQUOTED(LT_OBJDIR, "$lt_cv_objdir/", - [Define to the sub-directory in which libtool stores uninstalled libraries.]) -])# _LT_CHECK_OBJDIR +AC_SUBST(LINT) +AC_SUBST(LINT_FLAGS) +AM_CONDITIONAL(LINT, [test x$LINT != xno]) -# _LT_LINKER_HARDCODE_LIBPATH([TAGNAME]) -# -------------------------------------- -# Check hardcoding attributes. -m4_defun([_LT_LINKER_HARDCODE_LIBPATH], -[AC_MSG_CHECKING([how to hardcode library paths into programs]) -_LT_TAGVAR(hardcode_action, $1)= -if test -n "$_LT_TAGVAR(hardcode_libdir_flag_spec, $1)" || - test -n "$_LT_TAGVAR(runpath_var, $1)" || - test "X$_LT_TAGVAR(hardcode_automatic, $1)" = "Xyes" ; then +]) # XORG_WITH_LINT - # We can hardcode non-existent directories. - if test "$_LT_TAGVAR(hardcode_direct, $1)" != no && - # If the only mechanism to avoid hardcoding is shlibpath_var, we - # have to relink, otherwise we might link with an installed library - # when we should be linking with a yet-to-be-installed one - ## test "$_LT_TAGVAR(hardcode_shlibpath_var, $1)" != no && - test "$_LT_TAGVAR(hardcode_minus_L, $1)" != no; then - # Linking always hardcodes the temporary library directory. - _LT_TAGVAR(hardcode_action, $1)=relink - else - # We can link without hardcoding, and we can hardcode nonexisting dirs. - _LT_TAGVAR(hardcode_action, $1)=immediate - fi -else - # We cannot hardcode anything, or else we can only hardcode existing - # directories. - _LT_TAGVAR(hardcode_action, $1)=unsupported -fi -AC_MSG_RESULT([$_LT_TAGVAR(hardcode_action, $1)]) +# XORG_LINT_LIBRARY(LIBNAME) +# -------------------------- +# Minimum version: 1.1.0 +# +# 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 +# -if test "$_LT_TAGVAR(hardcode_action, $1)" = relink || - test "$_LT_TAGVAR(inherit_rpath, $1)" = yes; then - # Fast installation is not supported - enable_fast_install=no -elif test "$shlibpath_overrides_runpath" = yes || - test "$enable_shared" = no; then - # Fast installation is not necessary - enable_fast_install=needless +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 fi -_LT_TAGDECL([], [hardcode_action], [0], - [How to hardcode a shared library path into an executable]) -])# _LT_LINKER_HARDCODE_LIBPATH +AC_SUBST(LINTLIB) +AM_CONDITIONAL(MAKE_LINT_LIB, [test x$make_lint_lib != xno]) +]) # XORG_LINT_LIBRARY -# _LT_CMD_STRIPLIB -# ---------------- -m4_defun([_LT_CMD_STRIPLIB], -[m4_require([_LT_DECL_EGREP]) -striplib= -old_striplib= -AC_MSG_CHECKING([whether stripping libraries is possible]) -if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then - test -z "$old_striplib" && old_striplib="$STRIP --strip-debug" - test -z "$striplib" && striplib="$STRIP --strip-unneeded" - AC_MSG_RESULT([yes]) +# XORG_CWARNFLAGS +# --------------- +# Minimum version: 1.2.0 +# +# Defines CWARNFLAGS to enable C compiler warnings. +# +AC_DEFUN([XORG_CWARNFLAGS], [ +AC_REQUIRE([AC_PROG_CC]) +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 -# FIXME - insert some real tests, host_os isn't really good enough - case $host_os in - darwin*) - if test -n "$STRIP" ; then - striplib="$STRIP -x" - old_striplib="$STRIP -S" - AC_MSG_RESULT([yes]) - else - AC_MSG_RESULT([no]) + AC_CHECK_DECL([__SUNPRO_C], [SUNCC="yes"], [SUNCC="no"]) + if test "x$SUNCC" = "xyes"; then + CWARNFLAGS="-v" fi - ;; - *) - AC_MSG_RESULT([no]) - ;; - esac fi -_LT_DECL([], [old_striplib], [1], [Commands to strip libraries]) -_LT_DECL([], [striplib], [1]) -])# _LT_CMD_STRIPLIB +AC_SUBST(CWARNFLAGS) +m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])]) +]) # XORG_CWARNFLAGS +# XORG_STRICT_OPTION +# ----------------------- +# Minimum version: 1.3.0 +# +# Add configure option to enable strict compilation +AC_DEFUN([XORG_STRICT_OPTION], [ +AC_REQUIRE([AC_PROG_CC]) +AC_REQUIRE([AC_PROG_CC_C99]) +AC_REQUIRE([XORG_CWARNFLAGS]) -# _LT_SYS_DYNAMIC_LINKER([TAG]) -# ----------------------------- -# PORTME Fill in your ld.so characteristics -m4_defun([_LT_SYS_DYNAMIC_LINKER], -[AC_REQUIRE([AC_CANONICAL_HOST])dnl -m4_require([_LT_DECL_EGREP])dnl -m4_require([_LT_FILEUTILS_DEFAULTS])dnl -m4_require([_LT_DECL_OBJDUMP])dnl -m4_require([_LT_DECL_SED])dnl -AC_MSG_CHECKING([dynamic linker characteristics]) -m4_if([$1], - [], [ -if test "$GCC" = yes; then - case $host_os in - darwin*) lt_awk_arg="/^libraries:/,/LR/" ;; - *) lt_awk_arg="/^libraries:/" ;; - esac - lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e "s,=/,/,g"` - if $ECHO "$lt_search_path_spec" | $GREP ';' >/dev/null ; then - # if the path contains ";" then we assume it to be the separator - # otherwise default to the standard path separator (i.e. ":") - it is - # assumed that no part of a normal pathname contains ";" but that should - # okay in the real world where ";" in dirpaths is itself problematic. - lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED -e 's/;/ /g'` - else - lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` - fi - # Ok, now we have the path, separated by spaces, we can step through it - # and add multilib dir if necessary. - lt_tmp_lt_search_path_spec= - lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null` - for lt_sys_path in $lt_search_path_spec; do - if test -d "$lt_sys_path/$lt_multi_os_dir"; then - lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir" - else - test -d "$lt_sys_path" && \ - lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path" - fi - done - lt_search_path_spec=`$ECHO $lt_tmp_lt_search_path_spec | awk ' -BEGIN {RS=" "; FS="/|\n";} { - lt_foo=""; - lt_count=0; - for (lt_i = NF; lt_i > 0; lt_i--) { - if ($lt_i != "" && $lt_i != ".") { - if ($lt_i == "..") { - lt_count++; - } else { - if (lt_count == 0) { - lt_foo="/" $lt_i lt_foo; - } else { - lt_count--; - } - } - } - } - if (lt_foo != "") { lt_freq[[lt_foo]]++; } - if (lt_freq[[lt_foo]] == 1) { print lt_foo; } -}'` - sys_lib_search_path_spec=`$ECHO $lt_search_path_spec` -else - sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" -fi]) -library_names_spec= -libname_spec='lib$name' -soname_spec= -shrext_cmds=".so" -postinstall_cmds= -postuninstall_cmds= -finish_cmds= -finish_eval= -shlibpath_var= -shlibpath_overrides_runpath=unknown -version_type=none -dynamic_linker="$host_os ld.so" -sys_lib_dlsearch_path_spec="/lib /usr/lib" -need_lib_prefix=unknown -hardcode_into_libs=no +AC_ARG_ENABLE(strict-compilation, + AS_HELP_STRING([--enable-strict-compilation], + [Enable all warnings from compiler and make them errors (default: disabled)]), + [STRICT_COMPILE=$enableval], [STRICT_COMPILE=no]) +if test "x$STRICT_COMPILE" = "xyes"; then + AC_CHECK_DECL([__SUNPRO_C], [SUNCC="yes"], [SUNCC="no"]) + AC_CHECK_DECL([__INTEL_COMPILER], [INTELCC="yes"], [INTELCC="no"]) + 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" +AC_SUBST([CWARNFLAGS]) +]) # XORG_STRICT_OPTION -# when you set need_version to no, make sure it does not cause -set_version -# flags to be left without arguments -need_version=unknown +# XORG_DEFAULT_OPTIONS +# -------------------- +# Minimum version: 1.3.0 +# +# Defines default options for X.Org modules. +# +AC_DEFUN([XORG_DEFAULT_OPTIONS], [ +XORG_CWARNFLAGS +XORG_STRICT_OPTION +XORG_RELEASE_VERSION +XORG_CHANGELOG +XORG_MANPAGE_SECTIONS +]) # XORG_DEFAULT_OPTIONS +dnl Copyright 2005 Red Hat, Inc +dnl +dnl Permission to use, copy, modify, distribute, and sell this software and its +dnl documentation for any purpose is hereby granted without fee, provided that +dnl the above copyright notice appear in all copies and that both that +dnl copyright notice and this permission notice appear in supporting +dnl documentation. +dnl +dnl The above copyright notice and this permission notice shall be included +dnl in all copies or substantial portions of the Software. +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 IN NO EVENT SHALL THE OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR +dnl OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, +dnl ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR +dnl OTHER DEALINGS IN THE SOFTWARE. +dnl +dnl Except as contained in this notice, the name of the copyright holders shall +dnl not be used in advertising or otherwise to promote the sale, use or +dnl other dealings in this Software without prior written authorization +dnl from the copyright holders. +dnl -case $host_os in -aix3*) - version_type=linux - library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a' - shlibpath_var=LIBPATH +# 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. + +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]) + PVM=`echo $PACKAGE_VERSION | cut -d . -f 2 | cut -d - -f 1` + if test "x$PVM" = "x"; then + PVM="0" + fi + AC_DEFINE_UNQUOTED([PACKAGE_VERSION_MINOR], + [$PVM], + [Minor version of this package]) + PVP=`echo $PACKAGE_VERSION | cut -d . -f 3 | cut -d - -f 1` + if test "x$PVP" = "x"; then + PVP="0" + fi + AC_DEFINE_UNQUOTED([PACKAGE_VERSION_PATCHLEVEL], + [$PVP], + [Patch version of this package]) +]) - # AIX 3 has no versioning support, so we append a major version to the name. - soname_spec='${libname}${release}${shared_ext}$major' - ;; +# XORG_CHANGELOG() +# ---------------- +# Minimum version: 1.2.0 +# +# 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; \ +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 -aix[[4-9]]*) - version_type=linux - need_lib_prefix=no - need_version=no - hardcode_into_libs=yes - if test "$host_cpu" = ia64; then - # AIX 5 supports IA64 - library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - else - # With GCC up to 2.95.x, collect2 would create an import file - # for dependence libraries. The import file would start with - # the line `#! .'. This would cause the generated library to - # depend on `.', always an invalid library. This was fixed in - # development snapshots of GCC prior to 3.0. - case $host_os in - aix4 | aix4.[[01]] | aix4.[[01]].*) - if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' - echo ' yes ' - echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then - : - else - can_build_shared=no - fi - ;; - esac - # AIX (on Power*) has no versioning support, so currently we can not hardcode correct - # soname into executable. Probably we can add versioning support to - # collect2, so additional links can be useful in future. - if test "$aix_use_runtimelinking" = yes; then - # If using run time linking (on AIX 4.2 or later) use lib.so - # instead of lib.a to let people know that these are not - # typical AIX shared libraries. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - else - # We preserve .a as extension for shared libraries through AIX4.2 - # and later when we are not doing run time linking. - library_names_spec='${libname}${release}.a $libname.a' - soname_spec='${libname}${release}${shared_ext}$major' - fi - shlibpath_var=LIBPATH - fi - ;; +dnl $XdotOrg: lib/xtrans/xtrans.m4,v 1.6 2005/07/26 18:59:11 alanc Exp $ +dnl +dnl Copyright 2005 Sun Microsystems, Inc. All rights reserved. +dnl +dnl Permission to use, copy, modify, distribute, and sell this software and its +dnl documentation for any purpose is hereby granted without fee, provided that +dnl the above copyright notice appear in all copies and that both that +dnl copyright notice and this permission notice appear in supporting +dnl documentation. +dnl +dnl The above copyright notice and this permission notice shall be included +dnl in all copies or substantial portions of the Software. +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 IN NO EVENT SHALL THE OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR +dnl OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, +dnl ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR +dnl OTHER DEALINGS IN THE SOFTWARE. +dnl +dnl Except as contained in this notice, the name of the copyright holders shall +dnl not be used in advertising or otherwise to promote the sale, use or +dnl other dealings in this Software without prior written authorization +dnl from the copyright holders. +dnl -amigaos*) - case $host_cpu in - powerpc) - # Since July 2007 AmigaOS4 officially supports .so libraries. - # When compiling the executable, add -use-dynld -Lsobjs: to the compileline. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - ;; - m68k) - library_names_spec='$libname.ixlibrary $libname.a' - # Create ${libname}_ixlibrary.a entries in /sys/libs. - finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$ECHO "X$lib" | $Xsed -e '\''s%^.*/\([[^/]]*\)\.ixlibrary$%\1%'\''`; test $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' - ;; - esac - ;; +# XTRANS_TCP_FLAGS() +# ------------------ +# Find needed libraries for TCP sockets, and check for IPv6 support +AC_DEFUN([XTRANS_TCP_FLAGS],[ + # SVR4 hides these in libraries other than libc + AC_SEARCH_LIBS(socket, [socket]) + AC_SEARCH_LIBS(gethostbyname, [nsl]) + if test "$ac_cv_search_socket$ac_cv_search_gethostbyname" = "nono"; then + AC_HAVE_LIBRARY([ws2_32]) + fi -beos*) - library_names_spec='${libname}${shared_ext}' - dynamic_linker="$host_os ld.so" - shlibpath_var=LIBRARY_PATH - ;; + # Needs to come after above checks for libsocket & libnsl for SVR4 systems + AC_ARG_ENABLE(ipv6, + AC_HELP_STRING([--enable-ipv6],[Enable IPv6 support]), + [IPV6CONN=$enableval], + [AC_CHECK_FUNC(getaddrinfo,[IPV6CONN=yes],[IPV6CONN=no])]) + AC_MSG_CHECKING([if IPv6 support should be built]) + if test "$IPV6CONN" = "yes"; then + AC_DEFINE(IPv6,1,[Support IPv6 for TCP connections]) + fi + AC_MSG_RESULT($IPV6CONN) -bsdi[[45]]*) - version_type=linux - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' - shlibpath_var=LD_LIBRARY_PATH - sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" - sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" - # the default ld.so.conf also contains /usr/contrib/lib and - # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow - # libtool to hard-code these into programs + # 4.3BSD-Reno added a new member to struct sockaddr_in + AC_CHECK_MEMBER([struct sockaddr_in.sin_len], + AC_DEFINE([BSD44SOCKETS],1, + [Define to 1 if `struct sockaddr_in' has a `sin_len' member]), [], [ +#include +#include +#include + ]) + + # POSIX.1g changed the type of pointer passed to getsockname/getpeername/etc. + AC_CHECK_TYPES([socklen_t], [], [], [ +AC_INCLUDES_DEFAULT +#include ]) + +]) # XTRANS_TCP_FLAGS + +# XTRANS_CONNECTION_FLAGS() +# ------------------------- +# Standard checks for which Xtrans transports to use by the Xorg packages +# that use Xtrans functions +AC_DEFUN([XTRANS_CONNECTION_FLAGS],[ + AC_REQUIRE([AC_CANONICAL_HOST]) + AC_REQUIRE([AC_TYPE_SIGNAL]) + [case $host_os in + mingw*) unixdef="no" ;; + *) unixdef="yes" ;; + esac] + AC_ARG_ENABLE(unix-transport, + AC_HELP_STRING([--enable-unix-transport],[Enable UNIX domain socket transport]), + [UNIXCONN=$enableval], [UNIXCONN=$unixdef]) + AC_MSG_CHECKING([if Xtrans should support UNIX socket connections]) + if test "$UNIXCONN" = "yes"; then + AC_DEFINE(UNIXCONN,1,[Support UNIX socket connections]) + fi + AC_MSG_RESULT($UNIXCONN) + AC_ARG_ENABLE(tcp-transport, + AC_HELP_STRING([--enable-tcp-transport],[Enable TCP socket transport]), + [TCPCONN=$enableval], [TCPCONN=yes]) + AC_MSG_CHECKING([if Xtrans should support TCP socket connections]) + AC_MSG_RESULT($TCPCONN) + if test "$TCPCONN" = "yes"; then + AC_DEFINE(TCPCONN,1,[Support TCP socket connections]) + XTRANS_TCP_FLAGS + fi + [case $host_os in + solaris*|sco*|sysv4*) localdef="yes" ;; + *) localdef="no" ;; + esac] + AC_ARG_ENABLE(local-transport, + AC_HELP_STRING([--enable-local-transport],[Enable os-specific local transport]), + [LOCALCONN=$enableval], [LOCALCONN=$localdef]) + AC_MSG_CHECKING([if Xtrans should support os-specific local connections]) + AC_MSG_RESULT($LOCALCONN) + if test "$LOCALCONN" = "yes"; then + AC_DEFINE(LOCALCONN,1,[Support os-specific local connections]) + fi + +]) # XTRANS_CONNECTION_FLAGS + + +# XTRANS_SECURE_RPC_FLAGS() +# ------------------------- +# Check for Secure RPC functions - must come after XTRANS_TCP_FLAGS +# so that any necessary networking libraries are already found +AC_DEFUN([XTRANS_SECURE_RPC_FLAGS], +[AC_REQUIRE([XTRANS_TCP_FLAGS]) + AC_ARG_ENABLE(secure-rpc, + AC_HELP_STRING([--enable-secure-rpc],[Enable Secure RPC]), + [SECURE_RPC=$enableval], [SECURE_RPC="try"]) + + if test "x$SECURE_RPC" = "xyes" -o "x$SECURE_RPC" = "xtry" ; then + FOUND_SECURE_RPC="no" + AC_CHECK_FUNCS([authdes_seccreate authdes_create], + [FOUND_SECURE_RPC="yes"]) + if test "x$FOUND_SECURE_RPC" = "xno" ; then + if test "x$SECURE_RPC" = "xyes" ; then + AC_MSG_ERROR([Secure RPC requested, but required functions not found]) + fi + SECURE_RPC="no" + else + dnl FreeBSD keeps getsecretkey in librpcsvc + AC_SEARCH_LIBS(getsecretkey, [rpcsvc]) + SECURE_RPC="yes" + fi + fi + AC_MSG_CHECKING([if Secure RPC authentication ("SUN-DES-1") should be supported]) + if test "x$SECURE_RPC" = "xyes" ; then + AC_DEFINE(SECURE_RPC, 1, [Support Secure RPC ("SUN-DES-1") authentication for X11 clients]) + fi + AC_MSG_RESULT($SECURE_RPC) +]) # XTRANS_SECURE_RPC_FLAGS + + +# libtool.m4 - Configure libtool for the host system. -*-Autoconf-*- + +# serial 52 AC_PROG_LIBTOOL + + +# AC_PROVIDE_IFELSE(MACRO-NAME, IF-PROVIDED, IF-NOT-PROVIDED) +# ----------------------------------------------------------- +# If this macro is not defined by Autoconf, define it here. +m4_ifdef([AC_PROVIDE_IFELSE], + [], + [m4_define([AC_PROVIDE_IFELSE], + [m4_ifdef([AC_PROVIDE_$1], + [$2], [$3])])]) + + +# AC_PROG_LIBTOOL +# --------------- +AC_DEFUN([AC_PROG_LIBTOOL], +[AC_REQUIRE([_AC_PROG_LIBTOOL])dnl +dnl If AC_PROG_CXX has already been expanded, run AC_LIBTOOL_CXX +dnl immediately, otherwise, hook it in at the end of AC_PROG_CXX. + AC_PROVIDE_IFELSE([AC_PROG_CXX], + [AC_LIBTOOL_CXX], + [define([AC_PROG_CXX], defn([AC_PROG_CXX])[AC_LIBTOOL_CXX + ])]) +dnl And a similar setup for Fortran 77 support + AC_PROVIDE_IFELSE([AC_PROG_F77], + [AC_LIBTOOL_F77], + [define([AC_PROG_F77], defn([AC_PROG_F77])[AC_LIBTOOL_F77 +])]) + +dnl Quote A][M_PROG_GCJ so that aclocal doesn't bring it in needlessly. +dnl If either AC_PROG_GCJ or A][M_PROG_GCJ have already been expanded, run +dnl AC_LIBTOOL_GCJ immediately, otherwise, hook it in at the end of both. + AC_PROVIDE_IFELSE([AC_PROG_GCJ], + [AC_LIBTOOL_GCJ], + [AC_PROVIDE_IFELSE([A][M_PROG_GCJ], + [AC_LIBTOOL_GCJ], + [AC_PROVIDE_IFELSE([LT_AC_PROG_GCJ], + [AC_LIBTOOL_GCJ], + [ifdef([AC_PROG_GCJ], + [define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[AC_LIBTOOL_GCJ])]) + ifdef([A][M_PROG_GCJ], + [define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[AC_LIBTOOL_GCJ])]) + ifdef([LT_AC_PROG_GCJ], + [define([LT_AC_PROG_GCJ], + defn([LT_AC_PROG_GCJ])[AC_LIBTOOL_GCJ])])])]) +])])# AC_PROG_LIBTOOL + + +# _AC_PROG_LIBTOOL +# ---------------- +AC_DEFUN([_AC_PROG_LIBTOOL], +[AC_REQUIRE([AC_LIBTOOL_SETUP])dnl +AC_BEFORE([$0],[AC_LIBTOOL_CXX])dnl +AC_BEFORE([$0],[AC_LIBTOOL_F77])dnl +AC_BEFORE([$0],[AC_LIBTOOL_GCJ])dnl + +# This can be used to rebuild libtool when needed +LIBTOOL_DEPS="$ac_aux_dir/ltmain.sh" + +# Always use our own libtool. +LIBTOOL='$(SHELL) $(top_builddir)/libtool' +AC_SUBST(LIBTOOL)dnl + +# Prevent multiple expansion +define([AC_PROG_LIBTOOL], []) +])# _AC_PROG_LIBTOOL + + +# AC_LIBTOOL_SETUP +# ---------------- +AC_DEFUN([AC_LIBTOOL_SETUP], +[AC_PREREQ(2.50)dnl +AC_REQUIRE([AC_ENABLE_SHARED])dnl +AC_REQUIRE([AC_ENABLE_STATIC])dnl +AC_REQUIRE([AC_ENABLE_FAST_INSTALL])dnl +AC_REQUIRE([AC_CANONICAL_HOST])dnl +AC_REQUIRE([AC_CANONICAL_BUILD])dnl +AC_REQUIRE([AC_PROG_CC])dnl +AC_REQUIRE([AC_PROG_LD])dnl +AC_REQUIRE([AC_PROG_LD_RELOAD_FLAG])dnl +AC_REQUIRE([AC_PROG_NM])dnl + +AC_REQUIRE([AC_PROG_LN_S])dnl +AC_REQUIRE([AC_DEPLIBS_CHECK_METHOD])dnl +# Autoconf 2.13's AC_OBJEXT and AC_EXEEXT macros only works for C compilers! +AC_REQUIRE([AC_OBJEXT])dnl +AC_REQUIRE([AC_EXEEXT])dnl +dnl +AC_LIBTOOL_SYS_MAX_CMD_LEN +AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE +AC_LIBTOOL_OBJDIR + +AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl +_LT_AC_PROG_ECHO_BACKSLASH + +case $host_os in +aix3*) + # AIX sometimes has problems with the GCC collect2 program. For some + # reason, if we set the COLLECT_NAMES environment variable, the problems + # vanish in a puff of smoke. + if test "X${COLLECT_NAMES+set}" != Xset; then + COLLECT_NAMES= + export COLLECT_NAMES + fi ;; +esac -cygwin* | mingw* | pw32* | cegcc*) - version_type=windows - shrext_cmds=".dll" - need_version=no - need_lib_prefix=no +# Sed substitution that helps us do robust quoting. It backslashifies +# metacharacters that are still active within double-quoted strings. +Xsed='sed -e 1s/^X//' +[sed_quote_subst='s/\([\\"\\`$\\\\]\)/\\\1/g'] - case $GCC,$host_os in - yes,cygwin* | yes,mingw* | yes,pw32* | yes,cegcc*) - library_names_spec='$libname.dll.a' - # DLL is installed to $(libdir)/../bin by postinstall_cmds - postinstall_cmds='base_file=`basename \${file}`~ - dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~ - dldir=$destdir/`dirname \$dlpath`~ - test -d \$dldir || mkdir -p \$dldir~ - $install_prog $dir/$dlname \$dldir/$dlname~ - chmod a+x \$dldir/$dlname~ - if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then - eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; - fi' - postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ - dlpath=$dir/\$dldll~ - $RM \$dlpath' - shlibpath_overrides_runpath=yes +# Same as above, but do not quote variable references. +[double_quote_subst='s/\([\\"\\`\\\\]\)/\\\1/g'] - case $host_os in - cygwin*) - # Cygwin DLLs use 'cyg' prefix rather than 'lib' - soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' - sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib" - ;; - mingw* | cegcc*) - # MinGW DLLs use traditional 'lib' prefix - soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' - sys_lib_search_path_spec=`$CC -print-search-dirs | $GREP "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"` - if $ECHO "$sys_lib_search_path_spec" | [$GREP ';[c-zC-Z]:/' >/dev/null]; then - # It is most probably a Windows format PATH printed by - # mingw gcc, but we are running on Cygwin. Gcc prints its search - # path with ; separators, and with drive letters. We can handle the - # drive letters (cygwin fileutils understands them), so leave them, - # especially as we might pass files found there to a mingw objdump, - # which wouldn't understand a cygwinified path. Ahh. - sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` - else - sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` - fi - ;; - pw32*) - # pw32 DLLs use 'pw' prefix rather than 'lib' - library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' - ;; - esac - ;; +# Sed substitution to delay expansion of an escaped shell variable in a +# double_quote_subst'ed string. +delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g' - *) - library_names_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext} $libname.lib' - ;; - esac - dynamic_linker='Win32 ld.exe' - # FIXME: first we should search . and the directory the executable is in - shlibpath_var=PATH - ;; +# Sed substitution to avoid accidental globbing in evaled expressions +no_glob_subst='s/\*/\\\*/g' -darwin* | rhapsody*) - dynamic_linker="$host_os dyld" - version_type=darwin - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext' - soname_spec='${libname}${release}${major}$shared_ext' - shlibpath_overrides_runpath=yes - shlibpath_var=DYLD_LIBRARY_PATH - shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' -m4_if([$1], [],[ - sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"]) - sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' - ;; +# Constants: +rm="rm -f" -dgux*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - ;; +# Global variables: +default_ofile=libtool +can_build_shared=yes -freebsd1*) - dynamic_linker=no - ;; +# All known linkers require a `.a' archive for static linking (except MSVC, +# which needs '.lib'). +libext=a +ltmain="$ac_aux_dir/ltmain.sh" +ofile="$default_ofile" +with_gnu_ld="$lt_cv_prog_gnu_ld" -freebsd* | dragonfly*) - # DragonFly does not have aout. When/if they implement a new - # versioning mechanism, adjust this. - if test -x /usr/bin/objformat; then - objformat=`/usr/bin/objformat` - else - case $host_os in - freebsd[[123]]*) objformat=aout ;; - *) objformat=elf ;; - esac - fi - version_type=freebsd-$objformat - case $version_type in - freebsd-elf*) - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' - need_version=no - need_lib_prefix=no - ;; - freebsd-*) - library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' - need_version=yes - ;; - esac - shlibpath_var=LD_LIBRARY_PATH - case $host_os in - freebsd2*) - shlibpath_overrides_runpath=yes - ;; - freebsd3.[[01]]* | freebsdelf3.[[01]]*) - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - ;; - freebsd3.[[2-9]]* | freebsdelf3.[[2-9]]* | \ - freebsd4.[[0-5]] | freebsdelf4.[[0-5]] | freebsd4.1.1 | freebsdelf4.1.1) - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - ;; - *) # from 4.6 on, and DragonFly - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - ;; - esac - ;; +AC_CHECK_TOOL(AR, ar, false) +AC_CHECK_TOOL(RANLIB, ranlib, :) +AC_CHECK_TOOL(STRIP, strip, :) -gnu*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - hardcode_into_libs=yes - ;; +old_CC="$CC" +old_CFLAGS="$CFLAGS" -hpux9* | hpux10* | hpux11*) - # Give a soname corresponding to the major version so that dld.sl refuses to - # link against other versions. - version_type=sunos - need_lib_prefix=no - need_version=no - case $host_cpu in - ia64*) - shrext_cmds='.so' - hardcode_into_libs=yes - dynamic_linker="$host_os dld.so" - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - if test "X$HPUX_IA64_MODE" = X32; then - sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" - else - sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" - fi - sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec - ;; - hppa*64*) - shrext_cmds='.sl' - hardcode_into_libs=yes - dynamic_linker="$host_os dld.sl" - shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH - shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" - sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec - ;; - *) - shrext_cmds='.sl' - dynamic_linker="$host_os dld.sl" - shlibpath_var=SHLIB_PATH - shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - ;; - esac - # HP-UX runs *really* slowly unless shared libraries are mode 555. - postinstall_cmds='chmod 555 $lib' - ;; +# Set sane defaults for various variables +test -z "$AR" && AR=ar +test -z "$AR_FLAGS" && AR_FLAGS=cru +test -z "$AS" && AS=as +test -z "$CC" && CC=cc +test -z "$LTCC" && LTCC=$CC +test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS +test -z "$DLLTOOL" && DLLTOOL=dlltool +test -z "$LD" && LD=ld +test -z "$LN_S" && LN_S="ln -s" +test -z "$MAGIC_CMD" && MAGIC_CMD=file +test -z "$NM" && NM=nm +test -z "$SED" && SED=sed +test -z "$OBJDUMP" && OBJDUMP=objdump +test -z "$RANLIB" && RANLIB=: +test -z "$STRIP" && STRIP=: +test -z "$ac_objext" && ac_objext=o -interix[[3-9]]*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - ;; +# Determine commands to create old-style static archives. +old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs' +old_postinstall_cmds='chmod 644 $oldlib' +old_postuninstall_cmds= -irix5* | irix6* | nonstopux*) - case $host_os in - nonstopux*) version_type=nonstopux ;; - *) - if test "$lt_cv_prog_gnu_ld" = yes; then - version_type=linux - else - version_type=irix - fi ;; - esac - need_lib_prefix=no - need_version=no - soname_spec='${libname}${release}${shared_ext}$major' - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}' +if test -n "$RANLIB"; then case $host_os in - irix5* | nonstopux*) - libsuff= shlibsuff= + openbsd*) + old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$oldlib" ;; *) - case $LD in # libtool.m4 will add one of these switches to LD - *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") - libsuff= shlibsuff= libmagic=32-bit;; - *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") - libsuff=32 shlibsuff=N32 libmagic=N32;; - *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") - libsuff=64 shlibsuff=64 libmagic=64-bit;; - *) libsuff= shlibsuff= libmagic=never-match;; - esac + old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$oldlib" ;; esac - shlibpath_var=LD_LIBRARY${shlibsuff}_PATH - shlibpath_overrides_runpath=no - sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" - sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" - hardcode_into_libs=yes - ;; + old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib" +fi + +_LT_CC_BASENAME([$compiler]) -# No shared lib support for Linux oldld, aout, or coff. -linux*oldld* | linux*aout* | linux*coff*) - dynamic_linker=no +# Only perform the check for file, if the check method requires it +case $deplibs_check_method in +file_magic*) + if test "$file_magic_cmd" = '$MAGIC_CMD'; then + AC_PATH_MAGIC + fi ;; +esac -# This must be Linux ELF. -linux* | k*bsd*-gnu) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - # Some binutils ld are patched to set DT_RUNPATH - save_LDFLAGS=$LDFLAGS - save_libdir=$libdir - eval "libdir=/foo; wl=\"$_LT_TAGVAR(lt_prog_compiler_wl, $1)\"; \ - LDFLAGS=\"\$LDFLAGS $_LT_TAGVAR(hardcode_libdir_flag_spec, $1)\"" - AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])], - [AS_IF([ ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null], - [shlibpath_overrides_runpath=yes])]) - LDFLAGS=$save_LDFLAGS - libdir=$save_libdir +_LT_REQUIRED_DARWIN_CHECKS - # This implies no fast_install, which is unacceptable. - # Some rework will be needed to allow for fast_install - # before this can be enabled. - hardcode_into_libs=yes +AC_PROVIDE_IFELSE([AC_LIBTOOL_DLOPEN], enable_dlopen=yes, enable_dlopen=no) +AC_PROVIDE_IFELSE([AC_LIBTOOL_WIN32_DLL], +enable_win32_dll=yes, enable_win32_dll=no) - # Add ABI-specific directories to the system library path. - sys_lib_dlsearch_path_spec="/lib64 /usr/lib64 /lib /usr/lib" +AC_ARG_ENABLE([libtool-lock], + [AC_HELP_STRING([--disable-libtool-lock], + [avoid locking (might break parallel builds)])]) +test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes - # Append ld.so.conf contents to the search path - if test -f /etc/ld.so.conf; then - lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \[$]2)); skip = 1; } { if (!skip) print \[$]0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '` - sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec $lt_ld_extra" - fi +AC_ARG_WITH([pic], + [AC_HELP_STRING([--with-pic], + [try to use only PIC/non-PIC objects @<:@default=use both@:>@])], + [pic_mode="$withval"], + [pic_mode=default]) +test -z "$pic_mode" && pic_mode=default - # We used to test for /lib/ld.so.1 and disable shared libraries on - # powerpc, because MkLinux only supported shared libraries with the - # GNU dynamic linker. Since this was broken with cross compilers, - # most powerpc-linux boxes support dynamic linking these days and - # people can always --disable-shared, the test was removed, and we - # assume the GNU/Linux dynamic linker is in use. - dynamic_linker='GNU/Linux ld.so' - ;; +# Use C for the default configuration in the libtool script +tagname= +AC_LIBTOOL_LANG_C_CONFIG +_LT_AC_TAGCONFIG +])# AC_LIBTOOL_SETUP -netbsd*) - version_type=sunos - need_lib_prefix=no - need_version=no - if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' - dynamic_linker='NetBSD (a.out) ld.so' - else - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - dynamic_linker='NetBSD ld.elf_so' - fi - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - ;; -newsos6) - version_type=linux - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - ;; +# _LT_AC_SYS_COMPILER +# ------------------- +AC_DEFUN([_LT_AC_SYS_COMPILER], +[AC_REQUIRE([AC_PROG_CC])dnl -*nto* | *qnx*) - version_type=qnx - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - dynamic_linker='ldqnx.so' - ;; +# If no C compiler was specified, use CC. +LTCC=${LTCC-"$CC"} -openbsd*) - version_type=sunos - sys_lib_dlsearch_path_spec="/usr/lib" - need_lib_prefix=no - # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs. - case $host_os in - openbsd3.3 | openbsd3.3.*) need_version=yes ;; - *) need_version=no ;; +# If no C compiler flags were specified, use CFLAGS. +LTCFLAGS=${LTCFLAGS-"$CFLAGS"} + +# Allow CC to be a program name with arguments. +compiler=$CC +])# _LT_AC_SYS_COMPILER + + +# _LT_CC_BASENAME(CC) +# ------------------- +# Calculate cc_basename. Skip known compiler wrappers and cross-prefix. +AC_DEFUN([_LT_CC_BASENAME], +[for cc_temp in $1""; do + case $cc_temp in + compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;; + distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;; + \-*) ;; + *) break;; esac - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' - shlibpath_var=LD_LIBRARY_PATH - if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - case $host_os in - openbsd2.[[89]] | openbsd2.[[89]].*) - shlibpath_overrides_runpath=no - ;; - *) - shlibpath_overrides_runpath=yes - ;; - esac - else - shlibpath_overrides_runpath=yes - fi - ;; +done +cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` +]) -os2*) - libname_spec='$name' - shrext_cmds=".dll" - need_lib_prefix=no - library_names_spec='$libname${shared_ext} $libname.a' - dynamic_linker='OS/2 ld.exe' - shlibpath_var=LIBPATH - ;; -osf3* | osf4* | osf5*) - version_type=osf - need_lib_prefix=no - need_version=no - soname_spec='${libname}${release}${shared_ext}$major' - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" - sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" - ;; +# _LT_COMPILER_BOILERPLATE +# ------------------------ +# Check for compiler boilerplate output or warnings with +# the simple compiler test code. +AC_DEFUN([_LT_COMPILER_BOILERPLATE], +[AC_REQUIRE([LT_AC_PROG_SED])dnl +ac_outfile=conftest.$ac_objext +echo "$lt_simple_compile_test_code" >conftest.$ac_ext +eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err +_lt_compiler_boilerplate=`cat conftest.err` +$rm conftest* +])# _LT_COMPILER_BOILERPLATE -rdos*) - dynamic_linker=no - ;; -solaris*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - # ldd complains unless libraries are executable - postinstall_cmds='chmod +x $lib' - ;; +# _LT_LINKER_BOILERPLATE +# ---------------------- +# Check for linker boilerplate output or warnings with +# the simple link test code. +AC_DEFUN([_LT_LINKER_BOILERPLATE], +[AC_REQUIRE([LT_AC_PROG_SED])dnl +ac_outfile=conftest.$ac_objext +echo "$lt_simple_link_test_code" >conftest.$ac_ext +eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err +_lt_linker_boilerplate=`cat conftest.err` +$rm -r conftest* +])# _LT_LINKER_BOILERPLATE -sunos4*) - version_type=sunos - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' - finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - if test "$with_gnu_ld" = yes; then - need_lib_prefix=no - fi - need_version=yes - ;; +# _LT_REQUIRED_DARWIN_CHECKS +# -------------------------- +# Check for some things on darwin +AC_DEFUN([_LT_REQUIRED_DARWIN_CHECKS],[ + case $host_os in + rhapsody* | darwin*) + AC_CHECK_TOOL([DSYMUTIL], [dsymutil], [:]) + AC_CHECK_TOOL([NMEDIT], [nmedit], [:]) -sysv4 | sysv4.3*) - version_type=linux - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - case $host_vendor in - sni) - shlibpath_overrides_runpath=no - need_lib_prefix=no - runpath_var=LD_RUN_PATH - ;; - siemens) - need_lib_prefix=no - ;; - motorola) - need_lib_prefix=no - need_version=no - shlibpath_overrides_runpath=no - sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' - ;; + AC_CACHE_CHECK([for -single_module linker flag],[lt_cv_apple_cc_single_mod], + [lt_cv_apple_cc_single_mod=no + if test -z "${LT_MULTI_MODULE}"; then + # By default we will add the -single_module flag. You can override + # by either setting the environment variable LT_MULTI_MODULE + # non-empty at configure time, or by adding -multi_module to the + # link flags. + echo "int foo(void){return 1;}" > conftest.c + $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ + -dynamiclib ${wl}-single_module conftest.c + if test -f libconftest.dylib; then + lt_cv_apple_cc_single_mod=yes + rm -rf libconftest.dylib* + fi + rm conftest.c + fi]) + AC_CACHE_CHECK([for -exported_symbols_list linker flag], + [lt_cv_ld_exported_symbols_list], + [lt_cv_ld_exported_symbols_list=no + save_LDFLAGS=$LDFLAGS + echo "_main" > conftest.sym + LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym" + AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])], + [lt_cv_ld_exported_symbols_list=yes], + [lt_cv_ld_exported_symbols_list=no]) + LDFLAGS="$save_LDFLAGS" + ]) + case $host_os in + rhapsody* | darwin1.[[0123]]) + _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;; + darwin1.*) + _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; + darwin*) + # if running on 10.5 or later, the deployment target defaults + # to the OS version, if on x86, and 10.4, the deployment + # target defaults to 10.4. Don't you love it? + case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in + 10.0,*86*-darwin8*|10.0,*-darwin[[91]]*) + _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; + 10.[[012]]*) + _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; + 10.*) + _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; + esac + ;; esac - ;; + if test "$lt_cv_apple_cc_single_mod" = "yes"; then + _lt_dar_single_mod='$single_module' + fi + if test "$lt_cv_ld_exported_symbols_list" = "yes"; then + _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym' + else + _lt_dar_export_syms="~$NMEDIT -s \$output_objdir/\${libname}-symbols.expsym \${lib}" + fi + if test "$DSYMUTIL" != ":"; then + _lt_dsymutil="~$DSYMUTIL \$lib || :" + else + _lt_dsymutil= + fi + ;; + esac +]) + +# _LT_AC_SYS_LIBPATH_AIX +# ---------------------- +# Links a minimal program and checks the executable +# for the system default hardcoded library path. In most cases, +# this is /usr/lib:/lib, but when the MPI compilers are used +# the location of the communication and MPI libs are included too. +# If we don't find anything, use the default library path according +# to the aix ld manual. +AC_DEFUN([_LT_AC_SYS_LIBPATH_AIX], +[AC_REQUIRE([LT_AC_PROG_SED])dnl +AC_LINK_IFELSE(AC_LANG_PROGRAM,[ +lt_aix_libpath_sed=' + /Import File Strings/,/^$/ { + /^0/ { + s/^0 *\(.*\)$/\1/ + p + } + }' +aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` +# Check for a 64-bit object if we didn't find anything. +if test -z "$aix_libpath"; then + aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` +fi],[]) +if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi +])# _LT_AC_SYS_LIBPATH_AIX -sysv4*MP*) - if test -d /usr/nec ;then - version_type=linux - library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' - soname_spec='$libname${shared_ext}.$major' - shlibpath_var=LD_LIBRARY_PATH - fi - ;; -sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) - version_type=freebsd-elf - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - if test "$with_gnu_ld" = yes; then - sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' - else - sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' - case $host_os in - sco3.2v5*) - sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" - ;; - esac - fi - sys_lib_dlsearch_path_spec='/usr/lib' - ;; +# _LT_AC_SHELL_INIT(ARG) +# ---------------------- +AC_DEFUN([_LT_AC_SHELL_INIT], +[ifdef([AC_DIVERSION_NOTICE], + [AC_DIVERT_PUSH(AC_DIVERSION_NOTICE)], + [AC_DIVERT_PUSH(NOTICE)]) +$1 +AC_DIVERT_POP +])# _LT_AC_SHELL_INIT -tpf*) - # TPF is a cross-target only. Preferred cross-host = GNU/Linux. - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - ;; -uts4*) - version_type=linux - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - ;; +# _LT_AC_PROG_ECHO_BACKSLASH +# -------------------------- +# Add some code to the start of the generated configure script which +# will find an echo command which doesn't interpret backslashes. +AC_DEFUN([_LT_AC_PROG_ECHO_BACKSLASH], +[_LT_AC_SHELL_INIT([ +# Check that we are running under the correct shell. +SHELL=${CONFIG_SHELL-/bin/sh} -*) - dynamic_linker=no +case X$ECHO in +X*--fallback-echo) + # Remove one level of quotation (which was required for Make). + ECHO=`echo "$ECHO" | sed 's,\\\\\[$]\\[$]0,'[$]0','` ;; esac -AC_MSG_RESULT([$dynamic_linker]) -test "$dynamic_linker" = no && can_build_shared=no -variables_saved_for_relink="PATH $shlibpath_var $runpath_var" -if test "$GCC" = yes; then - variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" +echo=${ECHO-echo} +if test "X[$]1" = X--no-reexec; then + # Discard the --no-reexec flag, and continue. + shift +elif test "X[$]1" = X--fallback-echo; then + # Avoid inline document here, it may be left over + : +elif test "X`($echo '\t') 2>/dev/null`" = 'X\t' ; then + # Yippee, $echo works! + : +else + # Restart under the correct shell. + exec $SHELL "[$]0" --no-reexec ${1+"[$]@"} fi -if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then - sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec" -fi -if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then - sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec" +if test "X[$]1" = X--fallback-echo; then + # used as fallback echo + shift + cat < /dev/null | - $EGREP "$file_magic_regex" > /dev/null; then - : - else - cat <<_LT_EOF 1>&2 - -*** Warning: the command libtool uses to detect shared libraries, -*** $file_magic_cmd, produces output that libtool cannot recognize. -*** The result is that libtool may fail to recognize shared libraries -*** as such. This will affect the creation of libtool libraries that -*** depend on shared libraries, but programs linked with such libtool -*** libraries will work regardless of this problem. Nevertheless, you -*** may want to report the problem to your system manager and/or to -*** bug-libtool@gnu.org +# The HP-UX ksh and POSIX shell print the target directory to stdout +# if CDPATH is set. +(unset CDPATH) >/dev/null 2>&1 && unset CDPATH -_LT_EOF - fi ;; - esac - fi +if test -z "$ECHO"; then +if test "X${echo_test_string+set}" != Xset; then +# find a string as large as possible, as long as the shell can cope with it + for cmd in 'sed 50q "[$]0"' 'sed 20q "[$]0"' 'sed 10q "[$]0"' 'sed 2q "[$]0"' 'echo test'; do + # expected sizes: less than 2Kb, 1Kb, 512 bytes, 16 bytes, ... + if (echo_test_string=`eval $cmd`) 2>/dev/null && + echo_test_string=`eval $cmd` && + (test "X$echo_test_string" = "X$echo_test_string") 2>/dev/null + then break fi done - IFS="$lt_save_ifs" - MAGIC_CMD="$lt_save_MAGIC_CMD" - ;; -esac]) -MAGIC_CMD="$lt_cv_path_MAGIC_CMD" -if test -n "$MAGIC_CMD"; then - AC_MSG_RESULT($MAGIC_CMD) -else - AC_MSG_RESULT(no) -fi -_LT_DECL([], [MAGIC_CMD], [0], - [Used to examine libraries when file_magic_cmd begins with "file"])dnl -])# _LT_PATH_TOOL_PREFIX - -# Old name: -AU_ALIAS([AC_PATH_TOOL_PREFIX], [_LT_PATH_TOOL_PREFIX]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_PATH_TOOL_PREFIX], []) - - -# _LT_PATH_MAGIC -# -------------- -# find a file program which can recognize a shared library -m4_defun([_LT_PATH_MAGIC], -[_LT_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH) -if test -z "$lt_cv_path_MAGIC_CMD"; then - if test -n "$ac_tool_prefix"; then - _LT_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH) - else - MAGIC_CMD=: - fi fi -])# _LT_PATH_MAGIC - - -# LT_PATH_LD -# ---------- -# find the pathname to the GNU or non-GNU linker -AC_DEFUN([LT_PATH_LD], -[AC_REQUIRE([AC_PROG_CC])dnl -AC_REQUIRE([AC_CANONICAL_HOST])dnl -AC_REQUIRE([AC_CANONICAL_BUILD])dnl -m4_require([_LT_DECL_SED])dnl -m4_require([_LT_DECL_EGREP])dnl - -AC_ARG_WITH([gnu-ld], - [AS_HELP_STRING([--with-gnu-ld], - [assume the C compiler uses GNU ld @<:@default=no@:>@])], - [test "$withval" = no || with_gnu_ld=yes], - [with_gnu_ld=no])dnl -ac_prog=ld -if test "$GCC" = yes; then - # Check if gcc -print-prog-name=ld gives a path. - AC_MSG_CHECKING([for ld used by $CC]) - case $host in - *-*-mingw*) - # gcc leaves a trailing carriage return which upsets mingw - ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; - *) - ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; - esac - case $ac_prog in - # Accept absolute paths. - [[\\/]]* | ?:[[\\/]]*) - re_direlt='/[[^/]][[^/]]*/\.\./' - # Canonicalize the pathname of ld - ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'` - while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do - ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"` - done - test -z "$LD" && LD="$ac_prog" - ;; - "") - # If it fails, then pretend we aren't using GCC. - ac_prog=ld - ;; - *) - # If it is relative, then search for the first ld in PATH. - with_gnu_ld=unknown - ;; - esac -elif test "$with_gnu_ld" = yes; then - AC_MSG_CHECKING([for GNU ld]) +if test "X`($echo '\t') 2>/dev/null`" = 'X\t' && + echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` && + test "X$echo_testing_string" = "X$echo_test_string"; then + : else - AC_MSG_CHECKING([for non-GNU ld]) -fi -AC_CACHE_VAL(lt_cv_path_LD, -[if test -z "$LD"; then + # The Solaris, AIX, and Digital Unix default echo programs unquote + # backslashes. This makes it impossible to quote backslashes using + # echo "$something" | sed 's/\\/\\\\/g' + # + # So, first we look for a working echo in the user's PATH. + lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR - for ac_dir in $PATH; do + for dir in $PATH /usr/ucb; do IFS="$lt_save_ifs" - test -z "$ac_dir" && ac_dir=. - if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then - lt_cv_path_LD="$ac_dir/$ac_prog" - # Check to see if the program is GNU ld. I'd rather use --version, - # but apparently some variants of GNU ld only accept -v. - # Break only if it was the GNU/non-GNU ld that we prefer. - case `"$lt_cv_path_LD" -v 2>&1 /dev/null`" = 'X\t' && + echo_testing_string=`($dir/echo "$echo_test_string") 2>/dev/null` && + test "X$echo_testing_string" = "X$echo_test_string"; then + echo="$dir/echo" + break fi done IFS="$lt_save_ifs" -else - lt_cv_path_LD="$LD" # Let the user override the test with a path. -fi]) -LD="$lt_cv_path_LD" -if test -n "$LD"; then - AC_MSG_RESULT($LD) -else - AC_MSG_RESULT(no) -fi -test -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH]) -_LT_PATH_LD_GNU -AC_SUBST([LD]) - -_LT_TAGDECL([], [LD], [1], [The linker used to build libraries]) -])# LT_PATH_LD - -# Old names: -AU_ALIAS([AM_PROG_LD], [LT_PATH_LD]) -AU_ALIAS([AC_PROG_LD], [LT_PATH_LD]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AM_PROG_LD], []) -dnl AC_DEFUN([AC_PROG_LD], []) - - -# _LT_PATH_LD_GNU -#- -------------- -m4_defun([_LT_PATH_LD_GNU], -[AC_CACHE_CHECK([if the linker ($LD) is GNU ld], lt_cv_prog_gnu_ld, -[# I'd rather use --version here, but apparently some GNU lds only accept -v. -case `$LD -v 2>&1 /dev/null`" = 'X\t' && + echo_testing_string=`(print -r "$echo_test_string") 2>/dev/null` && + test "X$echo_testing_string" = "X$echo_test_string"; then + # This shell has a builtin print -r that does the trick. + echo='print -r' + elif (test -f /bin/ksh || test -f /bin/ksh$ac_exeext) && + test "X$CONFIG_SHELL" != X/bin/ksh; then + # If we have ksh, try running configure again with it. + ORIGINAL_CONFIG_SHELL=${CONFIG_SHELL-/bin/sh} + export ORIGINAL_CONFIG_SHELL + CONFIG_SHELL=/bin/ksh + export CONFIG_SHELL + exec $CONFIG_SHELL "[$]0" --no-reexec ${1+"[$]@"} + else + # Try using printf. + echo='printf %s\n' + if test "X`($echo '\t') 2>/dev/null`" = 'X\t' && + echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` && + test "X$echo_testing_string" = "X$echo_test_string"; then + # Cool, printf works + : + elif echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` && + test "X$echo_testing_string" = 'X\t' && + echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` && + test "X$echo_testing_string" = "X$echo_test_string"; then + CONFIG_SHELL=$ORIGINAL_CONFIG_SHELL + export CONFIG_SHELL + SHELL="$CONFIG_SHELL" + export SHELL + echo="$CONFIG_SHELL [$]0 --fallback-echo" + elif echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` && + test "X$echo_testing_string" = 'X\t' && + echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` && + test "X$echo_testing_string" = "X$echo_test_string"; then + echo="$CONFIG_SHELL [$]0 --fallback-echo" + else + # maybe with a smaller string... + prev=: -# _LT_CHECK_MAGIC_METHOD -# ---------------------- -# how to check for library dependencies -# -- PORTME fill in with the dynamic library characteristics -m4_defun([_LT_CHECK_MAGIC_METHOD], -[m4_require([_LT_DECL_EGREP]) -m4_require([_LT_DECL_OBJDUMP]) -AC_CACHE_CHECK([how to recognize dependent libraries], -lt_cv_deplibs_check_method, -[lt_cv_file_magic_cmd='$MAGIC_CMD' -lt_cv_file_magic_test_file= -lt_cv_deplibs_check_method='unknown' -# Need to set the preceding variable on all platforms that support -# interlibrary dependencies. -# 'none' -- dependencies not supported. -# `unknown' -- same as none, but documents that we really don't know. -# 'pass_all' -- all dependencies passed with no checks. -# 'test_compile' -- check by making test program. -# 'file_magic [[regex]]' -- check by looking for files in library path -# which responds to the $file_magic_cmd with a given extended regex. -# If you have `file' or equivalent on your system and you're not sure -# whether `pass_all' will *always* work, you probably want this one. + for cmd in 'echo test' 'sed 2q "[$]0"' 'sed 10q "[$]0"' 'sed 20q "[$]0"' 'sed 50q "[$]0"'; do + if (test "X$echo_test_string" = "X`eval $cmd`") 2>/dev/null + then + break + fi + prev="$cmd" + done -case $host_os in -aix[[4-9]]*) - lt_cv_deplibs_check_method=pass_all - ;; + if test "$prev" != 'sed 50q "[$]0"'; then + echo_test_string=`eval $prev` + export echo_test_string + exec ${ORIGINAL_CONFIG_SHELL-${CONFIG_SHELL-/bin/sh}} "[$]0" ${1+"[$]@"} + else + # Oops. We lost completely, so just stick with echo. + echo=echo + fi + fi + fi + fi +fi +fi -beos*) - lt_cv_deplibs_check_method=pass_all - ;; +# Copy echo and quote the copy suitably for passing to libtool from +# the Makefile, instead of quoting the original, which is used later. +ECHO=$echo +if test "X$ECHO" = "X$CONFIG_SHELL [$]0 --fallback-echo"; then + ECHO="$CONFIG_SHELL \\\$\[$]0 --fallback-echo" +fi -bsdi[[45]]*) - lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib)' - lt_cv_file_magic_cmd='/usr/bin/file -L' - lt_cv_file_magic_test_file=/shlib/libc.so - ;; +AC_SUBST(ECHO) +])])# _LT_AC_PROG_ECHO_BACKSLASH -cygwin*) - # func_win32_libid is a shell function defined in ltmain.sh - lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' - lt_cv_file_magic_cmd='func_win32_libid' - ;; -mingw* | pw32*) - # Base MSYS/MinGW do not provide the 'file' command needed by - # func_win32_libid shell function, so use a weaker test based on 'objdump', - # unless we find 'file', for example because we are cross-compiling. - if ( file / ) >/dev/null 2>&1; then - lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' - lt_cv_file_magic_cmd='func_win32_libid' - else - lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?' - lt_cv_file_magic_cmd='$OBJDUMP -f' +# _LT_AC_LOCK +# ----------- +AC_DEFUN([_LT_AC_LOCK], +[AC_ARG_ENABLE([libtool-lock], + [AC_HELP_STRING([--disable-libtool-lock], + [avoid locking (might break parallel builds)])]) +test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes + +# Some flags need to be propagated to the compiler or linker for good +# libtool support. +case $host in +ia64-*-hpux*) + # Find out which ABI we are using. + echo 'int i;' > conftest.$ac_ext + if AC_TRY_EVAL(ac_compile); then + case `/usr/bin/file conftest.$ac_objext` in + *ELF-32*) + HPUX_IA64_MODE="32" + ;; + *ELF-64*) + HPUX_IA64_MODE="64" + ;; + esac fi + rm -rf conftest* ;; - -cegcc) - # use the weaker test based on 'objdump'. See mingw*. - lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?' - lt_cv_file_magic_cmd='$OBJDUMP -f' +*-*-irix6*) + # Find out which ABI we are using. + echo '[#]line __oline__ "configure"' > conftest.$ac_ext + if AC_TRY_EVAL(ac_compile); then + if test "$lt_cv_prog_gnu_ld" = yes; then + case `/usr/bin/file conftest.$ac_objext` in + *32-bit*) + LD="${LD-ld} -melf32bsmip" + ;; + *N32*) + LD="${LD-ld} -melf32bmipn32" + ;; + *64-bit*) + LD="${LD-ld} -melf64bmip" + ;; + esac + else + case `/usr/bin/file conftest.$ac_objext` in + *32-bit*) + LD="${LD-ld} -32" + ;; + *N32*) + LD="${LD-ld} -n32" + ;; + *64-bit*) + LD="${LD-ld} -64" + ;; + esac + fi + fi + rm -rf conftest* ;; -darwin* | rhapsody*) - lt_cv_deplibs_check_method=pass_all +x86_64-*kfreebsd*-gnu|x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*| \ +s390*-*linux*|sparc*-*linux*) + # Find out which ABI we are using. + echo 'int i;' > conftest.$ac_ext + if AC_TRY_EVAL(ac_compile); then + case `/usr/bin/file conftest.o` in + *32-bit*) + case $host in + x86_64-*kfreebsd*-gnu) + LD="${LD-ld} -m elf_i386_fbsd" + ;; + x86_64-*linux*) + LD="${LD-ld} -m elf_i386" + ;; + ppc64-*linux*|powerpc64-*linux*) + LD="${LD-ld} -m elf32ppclinux" + ;; + s390x-*linux*) + LD="${LD-ld} -m elf_s390" + ;; + sparc64-*linux*) + LD="${LD-ld} -m elf32_sparc" + ;; + esac + ;; + *64-bit*) + case $host in + x86_64-*kfreebsd*-gnu) + LD="${LD-ld} -m elf_x86_64_fbsd" + ;; + x86_64-*linux*) + LD="${LD-ld} -m elf_x86_64" + ;; + ppc*-*linux*|powerpc*-*linux*) + LD="${LD-ld} -m elf64ppc" + ;; + s390*-*linux*) + LD="${LD-ld} -m elf64_s390" + ;; + sparc*-*linux*) + LD="${LD-ld} -m elf64_sparc" + ;; + esac + ;; + esac + fi + rm -rf conftest* ;; -freebsd* | dragonfly*) - if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then - case $host_cpu in - i*86 ) - # Not sure whether the presence of OpenBSD here was a mistake. - # Let's accept both of them until this is cleared up. - lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[[3-9]]86 (compact )?demand paged shared library' - lt_cv_file_magic_cmd=/usr/bin/file - lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` +*-*-sco3.2v5*) + # On SCO OpenServer 5, we need -belf to get full-featured binaries. + SAVE_CFLAGS="$CFLAGS" + CFLAGS="$CFLAGS -belf" + AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf, + [AC_LANG_PUSH(C) + AC_TRY_LINK([],[],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no]) + AC_LANG_POP]) + if test x"$lt_cv_cc_needs_belf" != x"yes"; then + # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf + CFLAGS="$SAVE_CFLAGS" + fi + ;; +sparc*-*solaris*) + # Find out which ABI we are using. + echo 'int i;' > conftest.$ac_ext + if AC_TRY_EVAL(ac_compile); then + case `/usr/bin/file conftest.o` in + *64-bit*) + case $lt_cv_prog_gnu_ld in + yes*) LD="${LD-ld} -m elf64_sparc" ;; + *) + if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then + LD="${LD-ld} -64" + fi + ;; + esac ;; esac - else - lt_cv_deplibs_check_method=pass_all fi + rm -rf conftest* + ;; + +AC_PROVIDE_IFELSE([AC_LIBTOOL_WIN32_DLL], +[*-*-cygwin* | *-*-mingw* | *-*-pw32*) + AC_CHECK_TOOL(DLLTOOL, dlltool, false) + AC_CHECK_TOOL(AS, as, false) + AC_CHECK_TOOL(OBJDUMP, objdump, false) ;; + ]) +esac + +need_locks="$enable_libtool_lock" + +])# _LT_AC_LOCK + + +# AC_LIBTOOL_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, +# [OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE]) +# ---------------------------------------------------------------- +# Check whether the given compiler option works +AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION], +[AC_REQUIRE([LT_AC_PROG_SED]) +AC_CACHE_CHECK([$1], [$2], + [$2=no + ifelse([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4]) + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + lt_compiler_flag="$3" + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + # The option is referenced via a variable to avoid confusing sed. + lt_compile=`echo "$ac_compile" | $SED \ + -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:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD) + (eval "$lt_compile" 2>conftest.err) + ac_status=$? + cat conftest.err >&AS_MESSAGE_LOG_FD + echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD + 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. + $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then + $2=yes + fi + fi + $rm conftest* +]) + +if test x"[$]$2" = xyes; then + ifelse([$5], , :, [$5]) +else + ifelse([$6], , :, [$6]) +fi +])# AC_LIBTOOL_COMPILER_OPTION + + +# AC_LIBTOOL_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, +# [ACTION-SUCCESS], [ACTION-FAILURE]) +# ------------------------------------------------------------ +# Check whether the given compiler option works +AC_DEFUN([AC_LIBTOOL_LINKER_OPTION], +[AC_REQUIRE([LT_AC_PROG_SED])dnl +AC_CACHE_CHECK([$1], [$2], + [$2=no + save_LDFLAGS="$LDFLAGS" + LDFLAGS="$LDFLAGS $3" + echo "$lt_simple_link_test_code" > conftest.$ac_ext + if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then + # The linker can only warn and ignore the option if not recognized + # So say no if there are warnings + if test -s conftest.err; then + # Append any errors to the config.log. + cat conftest.err 1>&AS_MESSAGE_LOG_FD + $echo "X$_lt_linker_boilerplate" | $Xsed -e '/^$/d' > conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if diff conftest.exp conftest.er2 >/dev/null; then + $2=yes + fi + else + $2=yes + fi + fi + $rm -r conftest* + LDFLAGS="$save_LDFLAGS" +]) + +if test x"[$]$2" = xyes; then + ifelse([$4], , :, [$4]) +else + ifelse([$5], , :, [$5]) +fi +])# AC_LIBTOOL_LINKER_OPTION + + +# AC_LIBTOOL_SYS_MAX_CMD_LEN +# -------------------------- +AC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN], +[# find the maximum length of command line arguments +AC_MSG_CHECKING([the maximum length of command line arguments]) +AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl + i=0 + teststring="ABCD" + + case $build_os in + msdosdjgpp*) + # On DJGPP, this test can blow up pretty badly due to problems in libc + # (any single argument exceeding 2000 bytes causes a buffer overrun + # during glob expansion). Even if it were fixed, the result of this + # check would be larger than it should be. + lt_cv_sys_max_cmd_len=12288; # 12K is about right + ;; + + gnu*) + # Under GNU Hurd, this test is not required because there is + # no limit to the length of command line arguments. + # Libtool will interpret -1 as no limit whatsoever + lt_cv_sys_max_cmd_len=-1; + ;; + + cygwin* | mingw*) + # On Win9x/ME, this test blows up -- it succeeds, but takes + # about 5 minutes as the teststring grows exponentially. + # Worse, since 9x/ME are not pre-emptively multitasking, + # you end up with a "frozen" computer, even though with patience + # the test eventually succeeds (with a max line length of 256k). + # Instead, let's just punt: use the minimum linelength reported by + # all of the supported platforms: 8192 (on NT/2K/XP). + lt_cv_sys_max_cmd_len=8192; + ;; -gnu*) - lt_cv_deplibs_check_method=pass_all - ;; + amigaos*) + # On AmigaOS with pdksh, this test takes hours, literally. + # So we just punt and use a minimum line length of 8192. + lt_cv_sys_max_cmd_len=8192; + ;; -hpux10.20* | hpux11*) - lt_cv_file_magic_cmd=/usr/bin/file - case $host_cpu in - ia64*) - lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64' - lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so + netbsd* | freebsd* | openbsd* | darwin* | dragonfly*) + # This has been around since 386BSD, at least. Likely further. + if test -x /sbin/sysctl; then + lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` + elif test -x /usr/sbin/sysctl; then + lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax` + else + lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs + fi + # And add a safety zone + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` ;; - hppa*64*) - [lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - PA-RISC [0-9].[0-9]'] - lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl + + interix*) + # We know the value 262144 and hardcode it with a safety zone (like BSD) + lt_cv_sys_max_cmd_len=196608 + ;; + + osf*) + # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure + # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not + # nice to cause kernel panics so lets avoid the loop below. + # First set a reasonable default. + lt_cv_sys_max_cmd_len=16384 + # + if test -x /sbin/sysconfig; then + case `/sbin/sysconfig -q proc exec_disable_arg_limit` in + *1*) lt_cv_sys_max_cmd_len=-1 ;; + esac + fi + ;; + sco3.2v5*) + lt_cv_sys_max_cmd_len=102400 + ;; + sysv5* | sco5v6* | sysv4.2uw2*) + kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null` + if test -n "$kargmax"; then + lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[[ ]]//'` + else + lt_cv_sys_max_cmd_len=32768 + fi ;; *) - lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]].[[0-9]]) shared library' - lt_cv_file_magic_test_file=/usr/lib/libc.sl + lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null` + if test -n "$lt_cv_sys_max_cmd_len"; then + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` + else + SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}} + while (test "X"`$SHELL [$]0 --fallback-echo "X$teststring" 2>/dev/null` \ + = "XX$teststring") >/dev/null 2>&1 && + new_result=`expr "X$teststring" : ".*" 2>&1` && + lt_cv_sys_max_cmd_len=$new_result && + test $i != 17 # 1/2 MB should be enough + do + i=`expr $i + 1` + teststring=$teststring$teststring + done + teststring= + # Add a significant safety factor because C++ compilers can tack on massive + # amounts of additional arguments before passing them to the linker. + # It appears as though 1/2 is a usable value. + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2` + fi ;; esac - ;; +]) +if test -n $lt_cv_sys_max_cmd_len ; then + AC_MSG_RESULT($lt_cv_sys_max_cmd_len) +else + AC_MSG_RESULT(none) +fi +])# AC_LIBTOOL_SYS_MAX_CMD_LEN -interix[[3-9]]*) - # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here - lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|\.a)$' - ;; -irix5* | irix6* | nonstopux*) - case $LD in - *-32|*"-32 ") libmagic=32-bit;; - *-n32|*"-n32 ") libmagic=N32;; - *-64|*"-64 ") libmagic=64-bit;; - *) libmagic=never-match;; - esac - lt_cv_deplibs_check_method=pass_all - ;; +# _LT_AC_CHECK_DLFCN +# ------------------ +AC_DEFUN([_LT_AC_CHECK_DLFCN], +[AC_CHECK_HEADERS(dlfcn.h)dnl +])# _LT_AC_CHECK_DLFCN -# This must be Linux ELF. -linux* | k*bsd*-gnu) - lt_cv_deplibs_check_method=pass_all - ;; -netbsd*) - if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then - lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' - else - lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$' - fi - ;; +# _LT_AC_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE, +# ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING) +# --------------------------------------------------------------------- +AC_DEFUN([_LT_AC_TRY_DLOPEN_SELF], +[AC_REQUIRE([_LT_AC_CHECK_DLFCN])dnl +if test "$cross_compiling" = yes; then : + [$4] +else + lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 + lt_status=$lt_dlunknown + cat > conftest.$ac_ext < +#endif -*nto* | *qnx*) - lt_cv_deplibs_check_method=pass_all - ;; +#include -openbsd*) - if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$' - else - lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' - fi - ;; +#ifdef RTLD_GLOBAL +# define LT_DLGLOBAL RTLD_GLOBAL +#else +# ifdef DL_GLOBAL +# define LT_DLGLOBAL DL_GLOBAL +# else +# define LT_DLGLOBAL 0 +# endif +#endif -osf3* | osf4* | osf5*) - lt_cv_deplibs_check_method=pass_all - ;; +/* We may have to define LT_DLLAZY_OR_NOW in the command line if we + find out it does not work in some platform. */ +#ifndef LT_DLLAZY_OR_NOW +# ifdef RTLD_LAZY +# define LT_DLLAZY_OR_NOW RTLD_LAZY +# else +# ifdef DL_LAZY +# define LT_DLLAZY_OR_NOW DL_LAZY +# else +# ifdef RTLD_NOW +# define LT_DLLAZY_OR_NOW RTLD_NOW +# else +# ifdef DL_NOW +# define LT_DLLAZY_OR_NOW DL_NOW +# else +# define LT_DLLAZY_OR_NOW 0 +# endif +# endif +# endif +# endif +#endif -rdos*) - lt_cv_deplibs_check_method=pass_all - ;; +#ifdef __cplusplus +extern "C" void exit (int); +#endif -solaris*) - lt_cv_deplibs_check_method=pass_all - ;; +void fnord() { int i=42;} +int main () +{ + void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); + int status = $lt_dlunknown; -sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) - lt_cv_deplibs_check_method=pass_all - ;; + if (self) + { + if (dlsym (self,"fnord")) status = $lt_dlno_uscore; + else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; + /* dlclose (self); */ + } + else + puts (dlerror ()); -sysv4 | sysv4.3*) - case $host_vendor in - motorola) - lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib) M[[0-9]][[0-9]]* Version [[0-9]]' - lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*` - ;; - ncr) - lt_cv_deplibs_check_method=pass_all - ;; - sequent) - lt_cv_file_magic_cmd='/bin/file' - lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )' - ;; - sni) - lt_cv_file_magic_cmd='/bin/file' - lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib" - lt_cv_file_magic_test_file=/lib/libc.so - ;; - siemens) - lt_cv_deplibs_check_method=pass_all - ;; - pc) - lt_cv_deplibs_check_method=pass_all + exit (status); +}] +EOF + if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext} 2>/dev/null; then + (./conftest; exit; ) >&AS_MESSAGE_LOG_FD 2>/dev/null + lt_status=$? + case x$lt_status in + x$lt_dlno_uscore) $1 ;; + x$lt_dlneed_uscore) $2 ;; + x$lt_dlunknown|x*) $3 ;; + esac + else : + # compilation failed + $3 + fi +fi +rm -fr conftest* +])# _LT_AC_TRY_DLOPEN_SELF + + +# AC_LIBTOOL_DLOPEN_SELF +# ---------------------- +AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF], +[AC_REQUIRE([_LT_AC_CHECK_DLFCN])dnl +if test "x$enable_dlopen" != xyes; then + enable_dlopen=unknown + enable_dlopen_self=unknown + enable_dlopen_self_static=unknown +else + lt_cv_dlopen=no + lt_cv_dlopen_libs= + + case $host_os in + beos*) + lt_cv_dlopen="load_add_on" + lt_cv_dlopen_libs= + lt_cv_dlopen_self=yes ;; - esac - ;; -tpf*) - lt_cv_deplibs_check_method=pass_all - ;; -esac -]) -file_magic_cmd=$lt_cv_file_magic_cmd -deplibs_check_method=$lt_cv_deplibs_check_method -test -z "$deplibs_check_method" && deplibs_check_method=unknown + mingw* | pw32*) + lt_cv_dlopen="LoadLibrary" + lt_cv_dlopen_libs= + ;; + + cygwin*) + lt_cv_dlopen="dlopen" + lt_cv_dlopen_libs= + ;; -_LT_DECL([], [deplibs_check_method], [1], - [Method to check whether dependent libraries are shared objects]) -_LT_DECL([], [file_magic_cmd], [1], - [Command to use when deplibs_check_method == "file_magic"]) -])# _LT_CHECK_MAGIC_METHOD + darwin*) + # if libdl is installed we need to link against it + AC_CHECK_LIB([dl], [dlopen], + [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],[ + lt_cv_dlopen="dyld" + lt_cv_dlopen_libs= + lt_cv_dlopen_self=yes + ]) + ;; + *) + AC_CHECK_FUNC([shl_load], + [lt_cv_dlopen="shl_load"], + [AC_CHECK_LIB([dld], [shl_load], + [lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld"], + [AC_CHECK_FUNC([dlopen], + [lt_cv_dlopen="dlopen"], + [AC_CHECK_LIB([dl], [dlopen], + [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"], + [AC_CHECK_LIB([svld], [dlopen], + [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"], + [AC_CHECK_LIB([dld], [dld_link], + [lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"]) + ]) + ]) + ]) + ]) + ]) + ;; + esac -# LT_PATH_NM -# ---------- -# find the pathname to a BSD- or MS-compatible name lister -AC_DEFUN([LT_PATH_NM], -[AC_REQUIRE([AC_PROG_CC])dnl -AC_CACHE_CHECK([for BSD- or MS-compatible name lister (nm)], lt_cv_path_NM, -[if test -n "$NM"; then - # Let the user override the test. - lt_cv_path_NM="$NM" -else - lt_nm_to_check="${ac_tool_prefix}nm" - if test -n "$ac_tool_prefix" && test "$build" = "$host"; then - lt_nm_to_check="$lt_nm_to_check nm" - fi - for lt_tmp_nm in $lt_nm_to_check; do - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR - for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do - IFS="$lt_save_ifs" - test -z "$ac_dir" && ac_dir=. - tmp_nm="$ac_dir/$lt_tmp_nm" - if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then - # Check to see if the nm accepts a BSD-compat flag. - # Adding the `sed 1q' prevents false positives on HP-UX, which says: - # nm: unknown option "B" ignored - # Tru64's nm complains that /dev/null is an invalid object file - case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in - */dev/null* | *'Invalid file or object type'*) - lt_cv_path_NM="$tmp_nm -B" - break - ;; - *) - case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in - */dev/null*) - lt_cv_path_NM="$tmp_nm -p" - break - ;; - *) - lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but - continue # so that we can try to find one that supports BSD flags - ;; - esac - ;; - esac - fi - done - IFS="$lt_save_ifs" - done - : ${lt_cv_path_NM=no} -fi]) -if test "$lt_cv_path_NM" != "no"; then - NM="$lt_cv_path_NM" -else - # Didn't find any BSD compatible name lister, look for dumpbin. - AC_CHECK_TOOLS(DUMPBIN, ["dumpbin -symbols" "link -dump -symbols"], :) - AC_SUBST([DUMPBIN]) - if test "$DUMPBIN" != ":"; then - NM="$DUMPBIN" - fi -fi -test -z "$NM" && NM=nm -AC_SUBST([NM]) -_LT_DECL([], [NM], [1], [A BSD- or MS-compatible name lister])dnl - -AC_CACHE_CHECK([the name lister ($NM) interface], [lt_cv_nm_interface], - [lt_cv_nm_interface="BSD nm" - echo "int some_variable = 0;" > conftest.$ac_ext - (eval echo "\"\$as_me:__oline__: $ac_compile\"" >&AS_MESSAGE_LOG_FD) - (eval "$ac_compile" 2>conftest.err) - cat conftest.err >&AS_MESSAGE_LOG_FD - (eval echo "\"\$as_me:__oline__: $NM \\\"conftest.$ac_objext\\\"\"" >&AS_MESSAGE_LOG_FD) - (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out) - cat conftest.err >&AS_MESSAGE_LOG_FD - (eval echo "\"\$as_me:__oline__: output\"" >&AS_MESSAGE_LOG_FD) - cat conftest.out >&AS_MESSAGE_LOG_FD - if $GREP 'External.*some_variable' conftest.out > /dev/null; then - lt_cv_nm_interface="MS dumpbin" + if test "x$lt_cv_dlopen" != xno; then + enable_dlopen=yes + else + enable_dlopen=no fi - rm -f conftest*]) -])# LT_PATH_NM - -# Old names: -AU_ALIAS([AM_PROG_NM], [LT_PATH_NM]) -AU_ALIAS([AC_PROG_NM], [LT_PATH_NM]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AM_PROG_NM], []) -dnl AC_DEFUN([AC_PROG_NM], []) + case $lt_cv_dlopen in + dlopen) + save_CPPFLAGS="$CPPFLAGS" + test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" -# LT_LIB_M -# -------- -# check for math library -AC_DEFUN([LT_LIB_M], -[AC_REQUIRE([AC_CANONICAL_HOST])dnl -LIBM= -case $host in -*-*-beos* | *-*-cygwin* | *-*-pw32* | *-*-darwin*) - # These system don't have libm, or don't need it - ;; -*-ncr-sysv4.3*) - AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM="-lmw") - AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm") - ;; -*) - AC_CHECK_LIB(m, cos, LIBM="-lm") - ;; -esac -AC_SUBST([LIBM]) -])# LT_LIB_M + save_LDFLAGS="$LDFLAGS" + wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" -# Old name: -AU_ALIAS([AC_CHECK_LIBM], [LT_LIB_M]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_CHECK_LIBM], []) + save_LIBS="$LIBS" + LIBS="$lt_cv_dlopen_libs $LIBS" + AC_CACHE_CHECK([whether a program can dlopen itself], + lt_cv_dlopen_self, [dnl + _LT_AC_TRY_DLOPEN_SELF( + lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes, + lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross) + ]) -# _LT_COMPILER_NO_RTTI([TAGNAME]) -# ------------------------------- -m4_defun([_LT_COMPILER_NO_RTTI], -[m4_require([_LT_TAG_COMPILER])dnl + if test "x$lt_cv_dlopen_self" = xyes; then + wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\" + AC_CACHE_CHECK([whether a statically linked program can dlopen itself], + lt_cv_dlopen_self_static, [dnl + _LT_AC_TRY_DLOPEN_SELF( + lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes, + lt_cv_dlopen_self_static=no, lt_cv_dlopen_self_static=cross) + ]) + fi -_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= + CPPFLAGS="$save_CPPFLAGS" + LDFLAGS="$save_LDFLAGS" + LIBS="$save_LIBS" + ;; + esac -if test "$GCC" = yes; then - _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' + case $lt_cv_dlopen_self in + yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; + *) enable_dlopen_self=unknown ;; + esac - _LT_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions], - lt_cv_prog_compiler_rtti_exceptions, - [-fno-rtti -fno-exceptions], [], - [_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"]) + case $lt_cv_dlopen_self_static in + yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;; + *) enable_dlopen_self_static=unknown ;; + esac fi -_LT_TAGDECL([no_builtin_flag], [lt_prog_compiler_no_builtin_flag], [1], - [Compiler flag to turn off builtin functions]) -])# _LT_COMPILER_NO_RTTI +])# AC_LIBTOOL_DLOPEN_SELF -# _LT_CMD_GLOBAL_SYMBOLS -# ---------------------- -m4_defun([_LT_CMD_GLOBAL_SYMBOLS], -[AC_REQUIRE([AC_CANONICAL_HOST])dnl -AC_REQUIRE([AC_PROG_CC])dnl -AC_REQUIRE([LT_PATH_NM])dnl -AC_REQUIRE([LT_PATH_LD])dnl -m4_require([_LT_DECL_SED])dnl -m4_require([_LT_DECL_EGREP])dnl -m4_require([_LT_TAG_COMPILER])dnl +# AC_LIBTOOL_PROG_CC_C_O([TAGNAME]) +# --------------------------------- +# Check to see if options -c and -o are simultaneously supported by compiler +AC_DEFUN([AC_LIBTOOL_PROG_CC_C_O], +[AC_REQUIRE([LT_AC_PROG_SED])dnl +AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl +AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext], + [_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)], + [_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no + $rm -r conftest 2>/dev/null + mkdir conftest + cd conftest + mkdir out + echo "$lt_simple_compile_test_code" > conftest.$ac_ext -# Check for command to grab the raw symbol name followed by C symbol from nm. -AC_MSG_CHECKING([command to parse $NM output from $compiler object]) -AC_CACHE_VAL([lt_cv_sys_global_symbol_pipe], -[ -# These are sane defaults that work on at least a few old systems. -# [They come from Ultrix. What could be older than Ultrix?!! ;)] + lt_compiler_flag="-o out/conftest2.$ac_objext" + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + lt_compile=`echo "$ac_compile" | $SED \ + -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:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD) + (eval "$lt_compile" 2>out/conftest.err) + ac_status=$? + cat out/conftest.err >&AS_MESSAGE_LOG_FD + echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD + if (exit $ac_status) && test -s out/conftest2.$ac_objext + then + # The compiler can only warn and ignore the option if not recognized + # So say no if there are warnings + $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp + $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 + if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then + _LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes + fi + fi + chmod u+w . 2>&AS_MESSAGE_LOG_FD + $rm conftest* + # SGI C++ compiler will create directory out/ii_files/ for + # template instantiation + test -d out/ii_files && $rm out/ii_files/* && rmdir out/ii_files + $rm out/* && rmdir out + cd .. + rmdir conftest + $rm conftest* +]) +])# AC_LIBTOOL_PROG_CC_C_O -# Character class describing NM global symbol codes. -symcode='[[BCDEGRST]]' -# Regexp to match symbols that can be accessed directly from C. -sympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)' +# AC_LIBTOOL_SYS_HARD_LINK_LOCKS([TAGNAME]) +# ----------------------------------------- +# Check to see if we can do hard links to lock some files if needed +AC_DEFUN([AC_LIBTOOL_SYS_HARD_LINK_LOCKS], +[AC_REQUIRE([_LT_AC_LOCK])dnl -# Define system-specific variables. -case $host_os in -aix*) - symcode='[[BCDT]]' - ;; -cygwin* | mingw* | pw32* | cegcc*) - symcode='[[ABCDGISTW]]' - ;; -hpux*) - if test "$host_cpu" = ia64; then - symcode='[[ABCDEGRST]]' +hard_links="nottested" +if test "$_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)" = no && test "$need_locks" != no; then + # do not overwrite the value of need_locks provided by the user + AC_MSG_CHECKING([if we can lock with hard links]) + hard_links=yes + $rm conftest* + ln conftest.a conftest.b 2>/dev/null && hard_links=no + touch conftest.a + ln conftest.a conftest.b 2>&5 || hard_links=no + ln conftest.a conftest.b 2>/dev/null && hard_links=no + AC_MSG_RESULT([$hard_links]) + if test "$hard_links" = no; then + AC_MSG_WARN([`$CC' does not support `-c -o', so `make -j' may be unsafe]) + need_locks=warn fi - ;; -irix* | nonstopux*) - symcode='[[BCDEGRST]]' - ;; -osf*) - symcode='[[BCDEGQRST]]' - ;; -solaris*) - symcode='[[BDRT]]' - ;; -sco3.2v5*) - symcode='[[DT]]' - ;; -sysv4.2uw2*) - symcode='[[DT]]' - ;; -sysv5* | sco5v6* | unixware* | OpenUNIX*) - symcode='[[ABDT]]' - ;; -sysv4) - symcode='[[DFNSTU]]' - ;; -esac - -# If we're using GNU nm, then use its standard symbol codes. -case `$NM -V 2>&1` in -*GNU* | *'with BFD'*) - symcode='[[ABCDGIRSTW]]' ;; -esac - -# Transform an extracted symbol line into a proper C declaration. -# Some systems (esp. on ia64) link data and code symbols differently, -# so use this general approach. -lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'" +else + need_locks=no +fi +])# AC_LIBTOOL_SYS_HARD_LINK_LOCKS -# Transform an extracted symbol line into symbol name and symbol address -lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (void *) \&\2},/p'" -lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \(lib[[^ ]]*\)$/ {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"lib\2\", (void *) \&\2},/p'" -# Handle CRLF in mingw tool chain -opt_cr= -case $build_os in -mingw*) - opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp - ;; -esac +# AC_LIBTOOL_OBJDIR +# ----------------- +AC_DEFUN([AC_LIBTOOL_OBJDIR], +[AC_CACHE_CHECK([for objdir], [lt_cv_objdir], +[rm -f .libs 2>/dev/null +mkdir .libs 2>/dev/null +if test -d .libs; then + lt_cv_objdir=.libs +else + # MS-DOS does not allow filenames that begin with a dot. + lt_cv_objdir=_libs +fi +rmdir .libs 2>/dev/null]) +objdir=$lt_cv_objdir +])# AC_LIBTOOL_OBJDIR -# Try without a prefix underscore, then with it. -for ac_symprfx in "" "_"; do - # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol. - symxfrm="\\1 $ac_symprfx\\2 \\2" +# AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH([TAGNAME]) +# ---------------------------------------------- +# Check hardcoding attributes. +AC_DEFUN([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH], +[AC_MSG_CHECKING([how to hardcode library paths into programs]) +_LT_AC_TAGVAR(hardcode_action, $1)= +if test -n "$_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)" || \ + test -n "$_LT_AC_TAGVAR(runpath_var, $1)" || \ + test "X$_LT_AC_TAGVAR(hardcode_automatic, $1)" = "Xyes" ; then - # Write the raw and C identifiers. - if test "$lt_cv_nm_interface" = "MS dumpbin"; then - # Fake it for dumpbin and say T for any non-static function - # and D for any global variable. - # Also find C++ and __fastcall symbols from MSVC++, - # which start with @ or ?. - lt_cv_sys_global_symbol_pipe="$AWK ['"\ -" {last_section=section; section=\$ 3};"\ -" /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\ -" \$ 0!~/External *\|/{next};"\ -" / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\ -" {if(hide[section]) next};"\ -" {f=0}; \$ 0~/\(\).*\|/{f=1}; {printf f ? \"T \" : \"D \"};"\ -" {split(\$ 0, a, /\||\r/); split(a[2], s)};"\ -" s[1]~/^[@?]/{print s[1], s[1]; next};"\ -" s[1]~prfx {split(s[1],t,\"@\"); print t[1], substr(t[1],length(prfx))}"\ -" ' prfx=^$ac_symprfx]" + # We can hardcode non-existant directories. + if test "$_LT_AC_TAGVAR(hardcode_direct, $1)" != no && + # If the only mechanism to avoid hardcoding is shlibpath_var, we + # have to relink, otherwise we might link with an installed library + # when we should be linking with a yet-to-be-installed one + ## test "$_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)" != no && + test "$_LT_AC_TAGVAR(hardcode_minus_L, $1)" != no; then + # Linking always hardcodes the temporary library directory. + _LT_AC_TAGVAR(hardcode_action, $1)=relink else - lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" + # We can link without hardcoding, and we can hardcode nonexisting dirs. + _LT_AC_TAGVAR(hardcode_action, $1)=immediate fi +else + # We cannot hardcode anything, or else we can only hardcode existing + # directories. + _LT_AC_TAGVAR(hardcode_action, $1)=unsupported +fi +AC_MSG_RESULT([$_LT_AC_TAGVAR(hardcode_action, $1)]) - # Check to see that the pipe works correctly. - pipe_works=no +if test "$_LT_AC_TAGVAR(hardcode_action, $1)" = relink; then + # Fast installation is not supported + enable_fast_install=no +elif test "$shlibpath_overrides_runpath" = yes || + test "$enable_shared" = no; then + # Fast installation is not necessary + enable_fast_install=needless +fi +])# AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH - rm -f conftest* - cat > conftest.$ac_ext <<_LT_EOF -#ifdef __cplusplus -extern "C" { -#endif -char nm_test_var; -void nm_test_func(void); -void nm_test_func(void){} -#ifdef __cplusplus -} -#endif -int main(){nm_test_var='a';nm_test_func();return(0);} -_LT_EOF - if AC_TRY_EVAL(ac_compile); then - # Now try to grab the symbols. - nlist=conftest.nm - if AC_TRY_EVAL(NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist) && test -s "$nlist"; then - # Try sorting and uniquifying the output. - if sort "$nlist" | uniq > "$nlist"T; then - mv -f "$nlist"T "$nlist" - else - rm -f "$nlist"T - fi +# AC_LIBTOOL_SYS_LIB_STRIP +# ------------------------ +AC_DEFUN([AC_LIBTOOL_SYS_LIB_STRIP], +[striplib= +old_striplib= +AC_MSG_CHECKING([whether stripping libraries is possible]) +if test -n "$STRIP" && $STRIP -V 2>&1 | grep "GNU strip" >/dev/null; then + test -z "$old_striplib" && old_striplib="$STRIP --strip-debug" + test -z "$striplib" && striplib="$STRIP --strip-unneeded" + AC_MSG_RESULT([yes]) +else +# FIXME - insert some real tests, host_os isn't really good enough + case $host_os in + darwin*) + if test -n "$STRIP" ; then + striplib="$STRIP -x" + old_striplib="$STRIP -S" + AC_MSG_RESULT([yes]) + else + AC_MSG_RESULT([no]) +fi + ;; + *) + AC_MSG_RESULT([no]) + ;; + esac +fi +])# AC_LIBTOOL_SYS_LIB_STRIP - # Make sure that we snagged all the symbols we need. - if $GREP ' nm_test_var$' "$nlist" >/dev/null; then - if $GREP ' nm_test_func$' "$nlist" >/dev/null; then - cat <<_LT_EOF > conftest.$ac_ext -#ifdef __cplusplus -extern "C" { -#endif -_LT_EOF - # Now generate the symbol file. - eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext' +# AC_LIBTOOL_SYS_DYNAMIC_LINKER +# ----------------------------- +# PORTME Fill in your ld.so characteristics +AC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER], +[AC_REQUIRE([LT_AC_PROG_SED])dnl +AC_MSG_CHECKING([dynamic linker characteristics]) +library_names_spec= +libname_spec='lib$name' +soname_spec= +shrext_cmds=".so" +postinstall_cmds= +postuninstall_cmds= +finish_cmds= +finish_eval= +shlibpath_var= +shlibpath_overrides_runpath=unknown +version_type=none +dynamic_linker="$host_os ld.so" +sys_lib_dlsearch_path_spec="/lib /usr/lib" +m4_if($1,[],[ +if test "$GCC" = yes; then + case $host_os in + darwin*) lt_awk_arg="/^libraries:/,/LR/" ;; + *) lt_awk_arg="/^libraries:/" ;; + esac + lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e "s,=/,/,g"` + if echo "$lt_search_path_spec" | grep ';' >/dev/null ; then + # if the path contains ";" then we assume it to be the separator + # otherwise default to the standard path separator (i.e. ":") - it is + # assumed that no part of a normal pathname contains ";" but that should + # okay in the real world where ";" in dirpaths is itself problematic. + lt_search_path_spec=`echo "$lt_search_path_spec" | $SED -e 's/;/ /g'` + else + lt_search_path_spec=`echo "$lt_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` + fi + # Ok, now we have the path, separated by spaces, we can step through it + # and add multilib dir if necessary. + lt_tmp_lt_search_path_spec= + lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null` + for lt_sys_path in $lt_search_path_spec; do + if test -d "$lt_sys_path/$lt_multi_os_dir"; then + lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir" + else + test -d "$lt_sys_path" && \ + lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path" + fi + done + lt_search_path_spec=`echo $lt_tmp_lt_search_path_spec | awk ' +BEGIN {RS=" "; FS="/|\n";} { + lt_foo=""; + lt_count=0; + for (lt_i = NF; lt_i > 0; lt_i--) { + if ($lt_i != "" && $lt_i != ".") { + if ($lt_i == "..") { + lt_count++; + } else { + if (lt_count == 0) { + lt_foo="/" $lt_i lt_foo; + } else { + lt_count--; + } + } + } + } + if (lt_foo != "") { lt_freq[[lt_foo]]++; } + if (lt_freq[[lt_foo]] == 1) { print lt_foo; } +}'` + sys_lib_search_path_spec=`echo $lt_search_path_spec` +else + sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" +fi]) +need_lib_prefix=unknown +hardcode_into_libs=no - cat <<_LT_EOF >> conftest.$ac_ext +# when you set need_version to no, make sure it does not cause -set_version +# flags to be left without arguments +need_version=unknown -/* The mapping between symbol names and symbols. */ -const struct { - const char *name; - void *address; -} -lt__PROGRAM__LTX_preloaded_symbols[[]] = -{ - { "@PROGRAM@", (void *) 0 }, -_LT_EOF - $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (void *) \&\2},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext - cat <<\_LT_EOF >> conftest.$ac_ext - {0, (void *) 0} -}; +case $host_os in +aix3*) + version_type=linux + library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a' + shlibpath_var=LIBPATH -/* This works around a problem in FreeBSD linker */ -#ifdef FREEBSD_WORKAROUND -static const void *lt_preloaded_setup() { - return lt__PROGRAM__LTX_preloaded_symbols; -} -#endif + # AIX 3 has no versioning support, so we append a major version to the name. + soname_spec='${libname}${release}${shared_ext}$major' + ;; -#ifdef __cplusplus -} -#endif -_LT_EOF - # Now try linking the two files. - mv conftest.$ac_objext conftstm.$ac_objext - lt_save_LIBS="$LIBS" - lt_save_CFLAGS="$CFLAGS" - LIBS="conftstm.$ac_objext" - CFLAGS="$CFLAGS$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)" - if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext}; then - pipe_works=yes - fi - LIBS="$lt_save_LIBS" - CFLAGS="$lt_save_CFLAGS" - else - echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD - fi +aix[[4-9]]*) + version_type=linux + need_lib_prefix=no + need_version=no + hardcode_into_libs=yes + if test "$host_cpu" = ia64; then + # AIX 5 supports IA64 + library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + else + # With GCC up to 2.95.x, collect2 would create an import file + # for dependence libraries. The import file would start with + # the line `#! .'. This would cause the generated library to + # depend on `.', always an invalid library. This was fixed in + # development snapshots of GCC prior to 3.0. + case $host_os in + aix4 | aix4.[[01]] | aix4.[[01]].*) + if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' + echo ' yes ' + echo '#endif'; } | ${CC} -E - | grep yes > /dev/null; then + : else - echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD + can_build_shared=no fi + ;; + esac + # AIX (on Power*) has no versioning support, so currently we can not hardcode correct + # soname into executable. Probably we can add versioning support to + # collect2, so additional links can be useful in future. + if test "$aix_use_runtimelinking" = yes; then + # If using run time linking (on AIX 4.2 or later) use lib.so + # instead of lib.a to let people know that these are not + # typical AIX shared libraries. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' else - echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD + # We preserve .a as extension for shared libraries through AIX4.2 + # and later when we are not doing run time linking. + library_names_spec='${libname}${release}.a $libname.a' + soname_spec='${libname}${release}${shared_ext}$major' fi - else - echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD - cat conftest.$ac_ext >&5 - fi - rm -rf conftest* conftst* - - # Do not use the global_symbol_pipe unless it works. - if test "$pipe_works" = yes; then - break - else - lt_cv_sys_global_symbol_pipe= + shlibpath_var=LIBPATH fi -done -]) -if test -z "$lt_cv_sys_global_symbol_pipe"; then - lt_cv_sys_global_symbol_to_cdecl= -fi -if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then - AC_MSG_RESULT(failed) -else - AC_MSG_RESULT(ok) -fi - -_LT_DECL([global_symbol_pipe], [lt_cv_sys_global_symbol_pipe], [1], - [Take the output of nm and produce a listing of raw symbols and C names]) -_LT_DECL([global_symbol_to_cdecl], [lt_cv_sys_global_symbol_to_cdecl], [1], - [Transform the output of nm in a proper C declaration]) -_LT_DECL([global_symbol_to_c_name_address], - [lt_cv_sys_global_symbol_to_c_name_address], [1], - [Transform the output of nm in a C name address pair]) -_LT_DECL([global_symbol_to_c_name_address_lib_prefix], - [lt_cv_sys_global_symbol_to_c_name_address_lib_prefix], [1], - [Transform the output of nm in a C name address pair when lib prefix is needed]) -]) # _LT_CMD_GLOBAL_SYMBOLS + ;; +amigaos*) + library_names_spec='$libname.ixlibrary $libname.a' + # Create ${libname}_ixlibrary.a entries in /sys/libs. + finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$echo "X$lib" | $Xsed -e '\''s%^.*/\([[^/]]*\)\.ixlibrary$%\1%'\''`; test $rm /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' + ;; -# _LT_COMPILER_PIC([TAGNAME]) -# --------------------------- -m4_defun([_LT_COMPILER_PIC], -[m4_require([_LT_TAG_COMPILER])dnl -_LT_TAGVAR(lt_prog_compiler_wl, $1)= -_LT_TAGVAR(lt_prog_compiler_pic, $1)= -_LT_TAGVAR(lt_prog_compiler_static, $1)= +beos*) + library_names_spec='${libname}${shared_ext}' + dynamic_linker="$host_os ld.so" + shlibpath_var=LIBRARY_PATH + ;; -AC_MSG_CHECKING([for $compiler option to produce PIC]) -m4_if([$1], [CXX], [ - # C++ specific cases for pic, static, wl, etc. - if test "$GXX" = yes; then - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' +bsdi[[45]]*) + version_type=linux + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' + shlibpath_var=LD_LIBRARY_PATH + sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" + sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" + # the default ld.so.conf also contains /usr/contrib/lib and + # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow + # libtool to hard-code these into programs + ;; - case $host_os in - aix*) - # All AIX code is PIC. - if test "$host_cpu" = ia64; then - # AIX 5 now supports IA64 processor - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - fi - ;; +cygwin* | mingw* | pw32*) + version_type=windows + shrext_cmds=".dll" + need_version=no + need_lib_prefix=no - amigaos*) - case $host_cpu in - powerpc) - # see comment about AmigaOS4 .so support - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - ;; - m68k) - # FIXME: we need at least 68020 code to build shared libraries, but - # adding the `-m68020' flag to GCC prevents building anything better, - # like `-m68040'. - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' - ;; - esac - ;; + case $GCC,$host_os in + yes,cygwin* | yes,mingw* | yes,pw32*) + library_names_spec='$libname.dll.a' + # DLL is installed to $(libdir)/../bin by postinstall_cmds + postinstall_cmds='base_file=`basename \${file}`~ + dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i;echo \$dlname'\''`~ + dldir=$destdir/`dirname \$dlpath`~ + test -d \$dldir || mkdir -p \$dldir~ + $install_prog $dir/$dlname \$dldir/$dlname~ + chmod a+x \$dldir/$dlname' + postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ + dlpath=$dir/\$dldll~ + $rm \$dlpath' + shlibpath_overrides_runpath=yes - beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) - # PIC is the default for these OSes. - ;; - mingw* | cygwin* | os2* | pw32* | cegcc*) - # This hack is so that the source file can tell whether it is being - # built for inclusion in a dll (and should export symbols for example). - # Although the cygwin gcc ignores -fPIC, still need this for old-style - # (--disable-auto-import) libraries - m4_if([$1], [GCJ], [], - [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) - ;; - darwin* | rhapsody*) - # PIC is the default on this platform - # Common symbols not allowed in MH_DYLIB files - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' - ;; - *djgpp*) - # DJGPP does not support shared libraries at all - _LT_TAGVAR(lt_prog_compiler_pic, $1)= - ;; - interix[[3-9]]*) - # Interix 3.x gcc -fpic/-fPIC options generate broken code. - # Instead, we relocate shared libraries at runtime. + case $host_os in + cygwin*) + # Cygwin DLLs use 'cyg' prefix rather than 'lib' + soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' + sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib" ;; - sysv4*MP*) - if test -d /usr/nec; then - _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic + mingw*) + # MinGW DLLs use traditional 'lib' prefix + soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' + sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"` + if echo "$sys_lib_search_path_spec" | [grep ';[c-zC-Z]:/' >/dev/null]; then + # It is most probably a Windows format PATH printed by + # mingw gcc, but we are running on Cygwin. Gcc prints its search + # path with ; separators, and with drive letters. We can handle the + # drive letters (cygwin fileutils understands them), so leave them, + # especially as we might pass files found there to a mingw objdump, + # which wouldn't understand a cygwinified path. Ahh. + sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` + else + sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` fi ;; - hpux*) - # PIC is the default for 64-bit PA HP-UX, but not for 32-bit - # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag - # sets the default TLS model and affects inlining. - case $host_cpu in - hppa*64*) - ;; - *) - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - ;; - esac - ;; - *qnx* | *nto*) - # QNX uses GNU C++, but need to define -shared option too, otherwise - # it will coredump. - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' - ;; - *) - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + pw32*) + # pw32 DLLs use 'pw' prefix rather than 'lib' + library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' ;; esac - else - case $host_os in - aix[[4-9]]*) - # All AIX code is PIC. - if test "$host_cpu" = ia64; then - # AIX 5 now supports IA64 processor - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - else - _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' - fi - ;; - chorus*) - case $cc_basename in - cxch68*) - # Green Hills C++ Compiler - # _LT_TAGVAR(lt_prog_compiler_static, $1)="--no_auto_instantiation -u __main -u __premain -u _abort -r $COOL_DIR/lib/libOrb.a $MVME_DIR/lib/CC/libC.a $MVME_DIR/lib/classix/libcx.s.a" - ;; - esac - ;; - dgux*) - case $cc_basename in - ec++*) - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - ;; - ghcx*) - # Green Hills C++ Compiler - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' - ;; - *) - ;; - esac - ;; - freebsd* | dragonfly*) - # FreeBSD uses GNU C++ - ;; - hpux9* | hpux10* | hpux11*) - case $cc_basename in - CC*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' - if test "$host_cpu" != ia64; then - _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' - fi - ;; - aCC*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' - case $host_cpu in - hppa*64*|ia64*) - # +Z the default - ;; - *) - _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' - ;; - esac - ;; - *) - ;; - esac - ;; - interix*) - # This is c89, which is MS Visual C++ (no shared libs) - # Anyone wants to do a port? - ;; - irix5* | irix6* | nonstopux*) - case $cc_basename in - CC*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' - # CC pic flag -KPIC is the default. - ;; - *) - ;; - esac - ;; - linux* | k*bsd*-gnu) - case $cc_basename in - KCC*) - # KAI C++ Compiler - _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - ;; - ecpc* ) - # old Intel C++ for x86_64 which still supported -KPIC. - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' - ;; - icpc* ) - # Intel C++, used to be incompatible with GCC. - # ICC 10 doesn't accept -KPIC any more. - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' - ;; - pgCC* | pgcpp*) - # Portland Group C++ compiler - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - cxx*) - # Compaq C++ - # Make sure the PIC flag is empty. It appears that all Alpha - # Linux and Compaq Tru64 Unix objects are PIC. - _LT_TAGVAR(lt_prog_compiler_pic, $1)= - _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' - ;; - xlc* | xlC*) - # IBM XL 8.0 on PPC - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink' - ;; - *) - case `$CC -V 2>&1 | sed 5q` in - *Sun\ C*) - # Sun C++ 5.9 - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' - ;; - esac - ;; - esac - ;; - lynxos*) - ;; - m88k*) - ;; - mvs*) - case $cc_basename in - cxx*) - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall' - ;; - *) - ;; - esac - ;; - netbsd*) - ;; - *qnx* | *nto*) - # QNX uses GNU C++, but need to define -shared option too, otherwise - # it will coredump. - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' - ;; - osf3* | osf4* | osf5*) - case $cc_basename in - KCC*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' - ;; - RCC*) - # Rational C++ 2.4.1 - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' - ;; - cxx*) - # Digital/Compaq C++ - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - # Make sure the PIC flag is empty. It appears that all Alpha - # Linux and Compaq Tru64 Unix objects are PIC. - _LT_TAGVAR(lt_prog_compiler_pic, $1)= - _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' - ;; - *) - ;; - esac - ;; - psos*) - ;; - solaris*) - case $cc_basename in - CC*) - # Sun C++ 4.2, 5.x and Centerline C++ - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' - ;; - gcx*) - # Green Hills C++ Compiler - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' - ;; - *) - ;; - esac - ;; - sunos4*) - case $cc_basename in - CC*) - # Sun C++ 4.x - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - lcc*) - # Lucid - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' - ;; - *) - ;; - esac - ;; - sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) - case $cc_basename in - CC*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - esac - ;; - tandem*) - case $cc_basename in - NCC*) - # NonStop-UX NCC 3.20 - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - ;; - *) - ;; - esac - ;; - vxworks*) - ;; - *) - _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no - ;; - esac - fi -], -[ - if test "$GCC" = yes; then - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' - - case $host_os in - aix*) - # All AIX code is PIC. - if test "$host_cpu" = ia64; then - # AIX 5 now supports IA64 processor - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - fi - ;; + ;; - amigaos*) - case $host_cpu in - powerpc) - # see comment about AmigaOS4 .so support - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - ;; - m68k) - # FIXME: we need at least 68020 code to build shared libraries, but - # adding the `-m68020' flag to GCC prevents building anything better, - # like `-m68040'. - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' - ;; - esac - ;; + *) + library_names_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext} $libname.lib' + ;; + esac + dynamic_linker='Win32 ld.exe' + # FIXME: first we should search . and the directory the executable is in + shlibpath_var=PATH + ;; - beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) - # PIC is the default for these OSes. - ;; +darwin* | rhapsody*) + dynamic_linker="$host_os dyld" + version_type=darwin + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${versuffix}$shared_ext ${libname}${release}${major}$shared_ext ${libname}$shared_ext' + soname_spec='${libname}${release}${major}$shared_ext' + shlibpath_overrides_runpath=yes + shlibpath_var=DYLD_LIBRARY_PATH + shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' + m4_if([$1], [],[ + sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"]) + sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' + ;; - mingw* | cygwin* | pw32* | os2* | cegcc*) - # This hack is so that the source file can tell whether it is being - # built for inclusion in a dll (and should export symbols for example). - # Although the cygwin gcc ignores -fPIC, still need this for old-style - # (--disable-auto-import) libraries - m4_if([$1], [GCJ], [], - [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) - ;; +dgux*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + ;; - darwin* | rhapsody*) - # PIC is the default on this platform - # Common symbols not allowed in MH_DYLIB files - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' - ;; +freebsd1*) + dynamic_linker=no + ;; - hpux*) - # PIC is the default for 64-bit PA HP-UX, but not for 32-bit - # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag - # sets the default TLS model and affects inlining. - case $host_cpu in - hppa*64*) - # +Z the default - ;; - *) - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - ;; - esac +freebsd* | dragonfly*) + # DragonFly does not have aout. When/if they implement a new + # versioning mechanism, adjust this. + if test -x /usr/bin/objformat; then + objformat=`/usr/bin/objformat` + else + case $host_os in + freebsd[[123]]*) objformat=aout ;; + *) objformat=elf ;; + esac + fi + version_type=freebsd-$objformat + case $version_type in + freebsd-elf*) + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' + need_version=no + need_lib_prefix=no ;; - - interix[[3-9]]*) - # Interix 3.x gcc -fpic/-fPIC options generate broken code. - # Instead, we relocate shared libraries at runtime. + freebsd-*) + library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' + need_version=yes ;; + esac + shlibpath_var=LD_LIBRARY_PATH + case $host_os in + freebsd2*) + shlibpath_overrides_runpath=yes + ;; + freebsd3.[[01]]* | freebsdelf3.[[01]]*) + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; + freebsd3.[[2-9]]* | freebsdelf3.[[2-9]]* | \ + freebsd4.[[0-5]] | freebsdelf4.[[0-5]] | freebsd4.1.1 | freebsdelf4.1.1) + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; + *) # from 4.6 on, and DragonFly + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; + esac + ;; - msdosdjgpp*) - # Just because we use GCC doesn't mean we suddenly get shared libraries - # on systems that don't support them. - _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no - enable_shared=no - ;; +gnu*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + hardcode_into_libs=yes + ;; - *nto* | *qnx*) - # QNX uses GNU C++, but need to define -shared option too, otherwise - # it will coredump. - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' - ;; +hpux9* | hpux10* | hpux11*) + # Give a soname corresponding to the major version so that dld.sl refuses to + # link against other versions. + version_type=sunos + need_lib_prefix=no + need_version=no + case $host_cpu in + ia64*) + shrext_cmds='.so' + hardcode_into_libs=yes + dynamic_linker="$host_os dld.so" + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + if test "X$HPUX_IA64_MODE" = X32; then + sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" + else + sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" + fi + sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec + ;; + hppa*64*) + shrext_cmds='.sl' + hardcode_into_libs=yes + dynamic_linker="$host_os dld.sl" + shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH + shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" + sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec + ;; + *) + shrext_cmds='.sl' + dynamic_linker="$host_os dld.sl" + shlibpath_var=SHLIB_PATH + shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + ;; + esac + # HP-UX runs *really* slowly unless shared libraries are mode 555. + postinstall_cmds='chmod 555 $lib' + ;; - sysv4*MP*) - if test -d /usr/nec; then - _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic - fi - ;; +interix[[3-9]]*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; +irix5* | irix6* | nonstopux*) + case $host_os in + nonstopux*) version_type=nonstopux ;; *) - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - ;; + if test "$lt_cv_prog_gnu_ld" = yes; then + version_type=linux + else + version_type=irix + fi ;; + esac + need_lib_prefix=no + need_version=no + soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}' + case $host_os in + irix5* | nonstopux*) + libsuff= shlibsuff= + ;; + *) + case $LD in # libtool.m4 will add one of these switches to LD + *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") + libsuff= shlibsuff= libmagic=32-bit;; + *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") + libsuff=32 shlibsuff=N32 libmagic=N32;; + *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") + libsuff=64 shlibsuff=64 libmagic=64-bit;; + *) libsuff= shlibsuff= libmagic=never-match;; esac - else - # PORTME Check for flag to pass linker flags through the system compiler. - case $host_os in - aix*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - if test "$host_cpu" = ia64; then - # AIX 5 now supports IA64 processor - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - else - _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' - fi - ;; + ;; + esac + shlibpath_var=LD_LIBRARY${shlibsuff}_PATH + shlibpath_overrides_runpath=no + sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" + sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" + hardcode_into_libs=yes + ;; - mingw* | cygwin* | pw32* | os2* | cegcc*) - # This hack is so that the source file can tell whether it is being - # built for inclusion in a dll (and should export symbols for example). - m4_if([$1], [GCJ], [], - [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) - ;; +# No shared lib support for Linux oldld, aout, or coff. +linux*oldld* | linux*aout* | linux*coff*) + dynamic_linker=no + ;; - hpux9* | hpux10* | hpux11*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but - # not for PA HP-UX. - case $host_cpu in - hppa*64*|ia64*) - # +Z the default - ;; - *) - _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' - ;; - esac - # Is there a better lt_prog_compiler_static that works with the bundled CC? - _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' - ;; +# This must be Linux ELF. +linux* | k*bsd*-gnu) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + # This implies no fast_install, which is unacceptable. + # Some rework will be needed to allow for fast_install + # before this can be enabled. + hardcode_into_libs=yes + + # Append ld.so.conf contents to the search path + if test -f /etc/ld.so.conf; then + lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \[$]2)); skip = 1; } { if (!skip) print \[$]0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '` + sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" + fi + + # We used to test for /lib/ld.so.1 and disable shared libraries on + # powerpc, because MkLinux only supported shared libraries with the + # GNU dynamic linker. Since this was broken with cross compilers, + # most powerpc-linux boxes support dynamic linking these days and + # people can always --disable-shared, the test was removed, and we + # assume the GNU/Linux dynamic linker is in use. + dynamic_linker='GNU/Linux ld.so' + ;; + +netbsd*) + version_type=sunos + need_lib_prefix=no + need_version=no + if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' + dynamic_linker='NetBSD (a.out) ld.so' + else + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + dynamic_linker='NetBSD ld.elf_so' + fi + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; - irix5* | irix6* | nonstopux*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - # PIC (with -KPIC) is the default. - _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' - ;; +newsos6) + version_type=linux + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + ;; - linux* | k*bsd*-gnu) - case $cc_basename in - # old Intel for x86_64 which still supported -KPIC. - ecc*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' - ;; - # icc used to be incompatible with GCC. - # ICC 10 doesn't accept -KPIC any more. - icc* | ifort*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' - ;; - # Lahey Fortran 8.1. - lf95*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='--shared' - _LT_TAGVAR(lt_prog_compiler_static, $1)='--static' - ;; - pgcc* | pgf77* | pgf90* | pgf95*) - # Portland Group compilers (*not* the Pentium gcc compiler, - # which looks to be a dead project) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - ccc*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - # All Alpha code is PIC. - _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' - ;; - xl*) - # IBM XL C 8.0/Fortran 10.1 on PPC - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink' +nto-qnx*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + ;; + +openbsd*) + version_type=sunos + sys_lib_dlsearch_path_spec="/usr/lib" + need_lib_prefix=no + # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs. + case $host_os in + openbsd3.3 | openbsd3.3.*) need_version=yes ;; + *) need_version=no ;; + esac + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' + shlibpath_var=LD_LIBRARY_PATH + if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then + case $host_os in + openbsd2.[[89]] | openbsd2.[[89]].*) + shlibpath_overrides_runpath=no ;; *) - case `$CC -V 2>&1 | sed 5q` in - *Sun\ C*) - # Sun C 5.9 - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - ;; - *Sun\ F*) - # Sun Fortran 8.3 passes all unrecognized flags to the linker - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - _LT_TAGVAR(lt_prog_compiler_wl, $1)='' - ;; - esac + shlibpath_overrides_runpath=yes ;; esac - ;; - - newsos6) - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - - *nto* | *qnx*) - # QNX uses GNU C++, but need to define -shared option too, otherwise - # it will coredump. - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' - ;; + else + shlibpath_overrides_runpath=yes + fi + ;; - osf3* | osf4* | osf5*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - # All OSF/1 code is PIC. - _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' - ;; +os2*) + libname_spec='$name' + shrext_cmds=".dll" + need_lib_prefix=no + library_names_spec='$libname${shared_ext} $libname.a' + dynamic_linker='OS/2 ld.exe' + shlibpath_var=LIBPATH + ;; - rdos*) - _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' - ;; +osf3* | osf4* | osf5*) + version_type=osf + need_lib_prefix=no + need_version=no + soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" + sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" + ;; - solaris*) - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - case $cc_basename in - f77* | f90* | f95*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';; - *) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';; - esac - ;; +rdos*) + dynamic_linker=no + ;; - sunos4*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; +solaris*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + # ldd complains unless libraries are executable + postinstall_cmds='chmod +x $lib' + ;; - sysv4 | sysv4.2uw2* | sysv4.3*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; +sunos4*) + version_type=sunos + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' + finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + if test "$with_gnu_ld" = yes; then + need_lib_prefix=no + fi + need_version=yes + ;; - sysv4*MP*) - if test -d /usr/nec ;then - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - fi +sysv4 | sysv4.3*) + version_type=linux + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + case $host_vendor in + sni) + shlibpath_overrides_runpath=no + need_lib_prefix=no + export_dynamic_flag_spec='${wl}-Blargedynsym' + runpath_var=LD_RUN_PATH ;; - - sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + siemens) + need_lib_prefix=no ;; - - unicos*) - _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no + motorola) + need_lib_prefix=no + need_version=no + shlibpath_overrides_runpath=no + sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' ;; + esac + ;; - uts4*) - _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' - _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; +sysv4*MP*) + if test -d /usr/nec ;then + version_type=linux + library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' + soname_spec='$libname${shared_ext}.$major' + shlibpath_var=LD_LIBRARY_PATH + fi + ;; - *) - _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no - ;; +sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) + version_type=freebsd-elf + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + hardcode_into_libs=yes + if test "$with_gnu_ld" = yes; then + sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' + shlibpath_overrides_runpath=no + else + sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' + shlibpath_overrides_runpath=yes + case $host_os in + sco3.2v5*) + sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" + ;; esac fi -]) -case $host_os in - # For platforms which do not support PIC, -DPIC is meaningless: - *djgpp*) - _LT_TAGVAR(lt_prog_compiler_pic, $1)= - ;; - *) - _LT_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])" - ;; -esac -AC_MSG_RESULT([$_LT_TAGVAR(lt_prog_compiler_pic, $1)]) -_LT_TAGDECL([wl], [lt_prog_compiler_wl], [1], - [How to pass a linker flag through the compiler]) - -# -# Check to make sure the PIC flag actually works. -# -if test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then - _LT_COMPILER_OPTION([if $compiler PIC flag $_LT_TAGVAR(lt_prog_compiler_pic, $1) works], - [_LT_TAGVAR(lt_cv_prog_compiler_pic_works, $1)], - [$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])], [], - [case $_LT_TAGVAR(lt_prog_compiler_pic, $1) in - "" | " "*) ;; - *) _LT_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_TAGVAR(lt_prog_compiler_pic, $1)" ;; - esac], - [_LT_TAGVAR(lt_prog_compiler_pic, $1)= - _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no]) -fi -_LT_TAGDECL([pic_flag], [lt_prog_compiler_pic], [1], - [Additional compiler flags for building library objects]) - -# -# Check to make sure the static flag actually works. -# -wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) eval lt_tmp_static_flag=\"$_LT_TAGVAR(lt_prog_compiler_static, $1)\" -_LT_LINKER_OPTION([if $compiler static flag $lt_tmp_static_flag works], - _LT_TAGVAR(lt_cv_prog_compiler_static_works, $1), - $lt_tmp_static_flag, - [], - [_LT_TAGVAR(lt_prog_compiler_static, $1)=]) -_LT_TAGDECL([link_static_flag], [lt_prog_compiler_static], [1], - [Compiler flag to prevent dynamic linking]) -])# _LT_COMPILER_PIC - - -# _LT_LINKER_SHLIBS([TAGNAME]) -# ---------------------------- -# See if the linker supports building shared libraries. -m4_defun([_LT_LINKER_SHLIBS], -[AC_REQUIRE([LT_PATH_LD])dnl -AC_REQUIRE([LT_PATH_NM])dnl -m4_require([_LT_FILEUTILS_DEFAULTS])dnl -m4_require([_LT_DECL_EGREP])dnl -m4_require([_LT_DECL_SED])dnl -m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl -m4_require([_LT_TAG_COMPILER])dnl -AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) -m4_if([$1], [CXX], [ - _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' - case $host_os in - aix[[4-9]]*) - # If we're using GNU nm, then we don't want the "-C" option. - # -C means demangle to AIX nm, but means don't demangle with GNU nm - if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then - _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols' - else - _LT_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols' - fi - ;; - pw32*) - _LT_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds" - ;; - cygwin* | mingw* | cegcc*) - _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;/^.*[[ ]]__nm__/s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols' - ;; - *) - _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' + sys_lib_dlsearch_path_spec='/usr/lib' ;; - esac - _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'] -], [ - runpath_var= - _LT_TAGVAR(allow_undefined_flag, $1)= - _LT_TAGVAR(always_export_symbols, $1)=no - _LT_TAGVAR(archive_cmds, $1)= - _LT_TAGVAR(archive_expsym_cmds, $1)= - _LT_TAGVAR(compiler_needs_object, $1)=no - _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no - _LT_TAGVAR(export_dynamic_flag_spec, $1)= - _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' - _LT_TAGVAR(hardcode_automatic, $1)=no - _LT_TAGVAR(hardcode_direct, $1)=no - _LT_TAGVAR(hardcode_direct_absolute, $1)=no - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= - _LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)= - _LT_TAGVAR(hardcode_libdir_separator, $1)= - _LT_TAGVAR(hardcode_minus_L, $1)=no - _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported - _LT_TAGVAR(inherit_rpath, $1)=no - _LT_TAGVAR(link_all_deplibs, $1)=unknown - _LT_TAGVAR(module_cmds, $1)= - _LT_TAGVAR(module_expsym_cmds, $1)= - _LT_TAGVAR(old_archive_from_new_cmds, $1)= - _LT_TAGVAR(old_archive_from_expsyms_cmds, $1)= - _LT_TAGVAR(thread_safe_flag_spec, $1)= - _LT_TAGVAR(whole_archive_flag_spec, $1)= - # include_expsyms should be a list of space-separated symbols to be *always* - # included in the symbol list - _LT_TAGVAR(include_expsyms, $1)= - # exclude_expsyms can be an extended regexp of symbols to exclude - # it will be wrapped by ` (' and `)$', so one must not match beginning or - # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc', - # as well as any symbol that contains `d'. - _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'] - # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out - # platforms (ab)use it in PIC code, but their linkers get confused if - # the symbol is explicitly referenced. Since portable code cannot - # rely on this symbol name, it's probably fine to never include it in - # preloaded symbol tables. - # Exclude shared library initialization/finalization symbols. -dnl Note also adjust exclude_expsyms for C++ above. - extract_expsyms_cmds= - case $host_os in - cygwin* | mingw* | pw32* | cegcc*) - # FIXME: the MSVC++ port hasn't been tested in a loooong time - # When not using gcc, we currently assume that we are using - # Microsoft Visual C++. - if test "$GCC" != yes; then - with_gnu_ld=no - fi - ;; - interix*) - # we just hope/assume this is gcc and not c89 (= MSVC++) - with_gnu_ld=yes - ;; - openbsd*) - with_gnu_ld=no - ;; - esac +uts4*) + version_type=linux + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + ;; - _LT_TAGVAR(ld_shlibs, $1)=yes - if test "$with_gnu_ld" = yes; then - # If archive_cmds runs LD, not CC, wlarc should be empty - wlarc='${wl}' +*) + dynamic_linker=no + ;; +esac +AC_MSG_RESULT([$dynamic_linker]) +test "$dynamic_linker" = no && can_build_shared=no - # Set some defaults for GNU ld with shared library support. These - # are reset later if shared libraries are not supported. Putting them - # here allows them to be overridden if necessary. - runpath_var=LD_RUN_PATH - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' - # ancient GNU ld didn't support --whole-archive et. al. - if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then - _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' +AC_CACHE_VAL([lt_cv_sys_lib_search_path_spec], +[lt_cv_sys_lib_search_path_spec="$sys_lib_search_path_spec"]) +sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec" +AC_CACHE_VAL([lt_cv_sys_lib_dlsearch_path_spec], +[lt_cv_sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec"]) +sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec" + +variables_saved_for_relink="PATH $shlibpath_var $runpath_var" +if test "$GCC" = yes; then + variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" +fi +])# AC_LIBTOOL_SYS_DYNAMIC_LINKER + + +# _LT_AC_TAGCONFIG +# ---------------- +AC_DEFUN([_LT_AC_TAGCONFIG], +[AC_REQUIRE([LT_AC_PROG_SED])dnl +AC_ARG_WITH([tags], + [AC_HELP_STRING([--with-tags@<:@=TAGS@:>@], + [include additional configurations @<:@automatic@:>@])], + [tagnames="$withval"]) + +if test -f "$ltmain" && test -n "$tagnames"; then + if test ! -f "${ofile}"; then + AC_MSG_WARN([output file `$ofile' does not exist]) + fi + + if test -z "$LTCC"; then + eval "`$SHELL ${ofile} --config | grep '^LTCC='`" + if test -z "$LTCC"; then + AC_MSG_WARN([output file `$ofile' does not look like a libtool script]) else - _LT_TAGVAR(whole_archive_flag_spec, $1)= + AC_MSG_WARN([using `LTCC=$LTCC', extracted from `$ofile']) fi - supports_anon_versioning=no - case `$LD -v 2>&1` in - *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11 - *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... - *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... - *\ 2.11.*) ;; # other 2.11 versions - *) supports_anon_versioning=yes ;; + fi + if test -z "$LTCFLAGS"; then + eval "`$SHELL ${ofile} --config | grep '^LTCFLAGS='`" + fi + + # Extract list of available tagged configurations in $ofile. + # Note that this assumes the entire list is on one line. + available_tags=`grep "^available_tags=" "${ofile}" | $SED -e 's/available_tags=\(.*$\)/\1/' -e 's/\"//g'` + + lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," + for tagname in $tagnames; do + IFS="$lt_save_ifs" + # Check whether tagname contains only valid characters + case `$echo "X$tagname" | $Xsed -e 's:[[-_ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz1234567890,/]]::g'` in + "") ;; + *) AC_MSG_ERROR([invalid tag name: $tagname]) + ;; esac - # See if GNU ld supports shared libraries. - case $host_os in - aix[[3-9]]*) - # On AIX/PPC, the GNU linker is very broken - if test "$host_cpu" != ia64; then - _LT_TAGVAR(ld_shlibs, $1)=no - cat <<_LT_EOF 1>&2 + if grep "^# ### BEGIN LIBTOOL TAG CONFIG: $tagname$" < "${ofile}" > /dev/null + then + AC_MSG_ERROR([tag name \"$tagname\" already exists]) + fi -*** Warning: the GNU linker, at least up to release 2.9.1, is reported -*** to be unable to reliably create shared libraries on AIX. -*** Therefore, libtool is disabling shared libraries support. If you -*** really care for shared libraries, you may want to modify your PATH -*** so that a non-GNU linker is found, and then restart. + # Update the list of available tags. + if test -n "$tagname"; then + echo appending configuration tag \"$tagname\" to $ofile -_LT_EOF - fi - ;; + case $tagname in + CXX) + if test -n "$CXX" && ( test "X$CXX" != "Xno" && + ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) || + (test "X$CXX" != "Xg++"))) ; then + AC_LIBTOOL_LANG_CXX_CONFIG + else + tagname="" + fi + ;; - amigaos*) - case $host_cpu in - powerpc) - # see comment about AmigaOS4 .so support - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='' - ;; - m68k) - _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_TAGVAR(hardcode_minus_L, $1)=yes - ;; + F77) + if test -n "$F77" && test "X$F77" != "Xno"; then + AC_LIBTOOL_LANG_F77_CONFIG + else + tagname="" + fi + ;; + + GCJ) + if test -n "$GCJ" && test "X$GCJ" != "Xno"; then + AC_LIBTOOL_LANG_GCJ_CONFIG + else + tagname="" + fi + ;; + + RC) + AC_LIBTOOL_LANG_RC_CONFIG + ;; + + *) + AC_MSG_ERROR([Unsupported tag name: $tagname]) + ;; esac - ;; - beos*) - if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then - _LT_TAGVAR(allow_undefined_flag, $1)=unsupported - # Joseph Beckenbach says some releases of gcc - # support --undefined. This deserves some investigation. FIXME - _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - else - _LT_TAGVAR(ld_shlibs, $1)=no - fi - ;; + # Append the new tag name to the list of available tags. + if test -n "$tagname" ; then + available_tags="$available_tags $tagname" + fi + fi + done + IFS="$lt_save_ifs" - cygwin* | mingw* | pw32* | cegcc*) - # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, - # as there is no search path for DLLs. - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_TAGVAR(allow_undefined_flag, $1)=unsupported - _LT_TAGVAR(always_export_symbols, $1)=no - _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes - _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/'\'' | $SED -e '\''/^[[AITW]][[ ]]/s/.*[[ ]]//'\'' | sort | uniq > $export_symbols' - - if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' - # If the export-symbols file already is a .def file (1st line - # is EXPORTS), use it as is; otherwise, prepend... - _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then - cp $export_symbols $output_objdir/$soname.def; - else - echo EXPORTS > $output_objdir/$soname.def; - cat $export_symbols >> $output_objdir/$soname.def; - fi~ - $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' - else - _LT_TAGVAR(ld_shlibs, $1)=no - fi - ;; + # Now substitute the updated list of available tags. + if eval "sed -e 's/^available_tags=.*\$/available_tags=\"$available_tags\"/' \"$ofile\" > \"${ofile}T\""; then + mv "${ofile}T" "$ofile" + chmod +x "$ofile" + else + rm -f "${ofile}T" + AC_MSG_ERROR([unable to update list of available tagged configurations.]) + fi +fi +])# _LT_AC_TAGCONFIG - interix[[3-9]]*) - _LT_TAGVAR(hardcode_direct, $1)=no - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' - # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. - # Instead, shared libraries are loaded at an image base (0x10000000 by - # default) and relocated if they conflict, which is a slow very memory - # consuming and fragmenting process. To avoid this, we pick a random, - # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link - # time. Moving up from 0x10000000 also allows more sbrk(2) space. - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' - ;; - gnu* | linux* | tpf* | k*bsd*-gnu) - tmp_diet=no - if test "$host_os" = linux-dietlibc; then - case $cc_basename in - diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn) - esac - fi - if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \ - && test "$tmp_diet" = no - then - tmp_addflag= - tmp_sharedflag='-shared' - case $cc_basename,$host_cpu in - pgcc*) # Portland Group C compiler - _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive' - tmp_addflag=' $pic_flag' - ;; - pgf77* | pgf90* | pgf95*) # Portland Group f77 and f90 compilers - _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive' - tmp_addflag=' $pic_flag -Mnomain' ;; - ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 - tmp_addflag=' -i_dynamic' ;; - efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 - tmp_addflag=' -i_dynamic -nofor_main' ;; - ifc* | ifort*) # Intel Fortran compiler - tmp_addflag=' -nofor_main' ;; - lf95*) # Lahey Fortran 8.1 - _LT_TAGVAR(whole_archive_flag_spec, $1)= - tmp_sharedflag='--shared' ;; - xl[[cC]]*) # IBM XL C 8.0 on PPC (deal with xlf below) - tmp_sharedflag='-qmkshrobj' - tmp_addflag= ;; - esac - case `$CC -V 2>&1 | sed 5q` in - *Sun\ C*) # Sun C 5.9 - _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive' - _LT_TAGVAR(compiler_needs_object, $1)=yes - tmp_sharedflag='-G' ;; - *Sun\ F*) # Sun Fortran 8.3 - tmp_sharedflag='-G' ;; - esac - _LT_TAGVAR(archive_cmds, $1)='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' +# AC_LIBTOOL_DLOPEN +# ----------------- +# enable checks for dlopen support +AC_DEFUN([AC_LIBTOOL_DLOPEN], + [AC_BEFORE([$0],[AC_LIBTOOL_SETUP]) +])# AC_LIBTOOL_DLOPEN - if test "x$supports_anon_versioning" = xyes; then - _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ - cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ - echo "local: *; };" >> $output_objdir/$libname.ver~ - $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' - fi - case $cc_basename in - xlf*) - # IBM XL Fortran 10.1 on PPC cannot create shared libs itself - _LT_TAGVAR(whole_archive_flag_spec, $1)='--whole-archive$convenience --no-whole-archive' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= - _LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='-rpath $libdir' - _LT_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $compiler_flags -soname $soname -o $lib' - if test "x$supports_anon_versioning" = xyes; then - _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ - cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ - echo "local: *; };" >> $output_objdir/$libname.ver~ - $LD -shared $libobjs $deplibs $compiler_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib' - fi - ;; - esac - else - _LT_TAGVAR(ld_shlibs, $1)=no - fi +# AC_LIBTOOL_WIN32_DLL +# -------------------- +# declare package support for building win32 DLLs +AC_DEFUN([AC_LIBTOOL_WIN32_DLL], +[AC_BEFORE([$0], [AC_LIBTOOL_SETUP]) +])# AC_LIBTOOL_WIN32_DLL + + +# AC_ENABLE_SHARED([DEFAULT]) +# --------------------------- +# implement the --enable-shared flag +# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. +AC_DEFUN([AC_ENABLE_SHARED], +[define([AC_ENABLE_SHARED_DEFAULT], ifelse($1, no, no, yes))dnl +AC_ARG_ENABLE([shared], + [AC_HELP_STRING([--enable-shared@<:@=PKGS@:>@], + [build shared libraries @<:@default=]AC_ENABLE_SHARED_DEFAULT[@:>@])], + [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], + [enable_shared=]AC_ENABLE_SHARED_DEFAULT) +])# AC_ENABLE_SHARED - netbsd*) - if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then - _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' - wlarc= - else - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - fi + +# AC_DISABLE_SHARED +# ----------------- +# set the default shared flag to --disable-shared +AC_DEFUN([AC_DISABLE_SHARED], +[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl +AC_ENABLE_SHARED(no) +])# AC_DISABLE_SHARED + + +# AC_ENABLE_STATIC([DEFAULT]) +# --------------------------- +# implement the --enable-static flag +# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. +AC_DEFUN([AC_ENABLE_STATIC], +[define([AC_ENABLE_STATIC_DEFAULT], ifelse($1, no, no, yes))dnl +AC_ARG_ENABLE([static], + [AC_HELP_STRING([--enable-static@<:@=PKGS@:>@], + [build static libraries @<:@default=]AC_ENABLE_STATIC_DEFAULT[@:>@])], + [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], + [enable_static=]AC_ENABLE_STATIC_DEFAULT) +])# AC_ENABLE_STATIC - solaris*) - if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then - _LT_TAGVAR(ld_shlibs, $1)=no - cat <<_LT_EOF 1>&2 -*** Warning: The releases 2.8.* of the GNU linker cannot reliably -*** create shared libraries on Solaris systems. Therefore, libtool -*** is disabling shared libraries support. We urge you to upgrade GNU -*** binutils to release 2.9.1 or newer. Another option is to modify -*** your PATH or compiler configuration so that the native linker is -*** used, and then restart. +# AC_DISABLE_STATIC +# ----------------- +# set the default static flag to --disable-static +AC_DEFUN([AC_DISABLE_STATIC], +[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl +AC_ENABLE_STATIC(no) +])# AC_DISABLE_STATIC -_LT_EOF - elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - else - _LT_TAGVAR(ld_shlibs, $1)=no - fi + +# AC_ENABLE_FAST_INSTALL([DEFAULT]) +# --------------------------------- +# implement the --enable-fast-install flag +# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. +AC_DEFUN([AC_ENABLE_FAST_INSTALL], +[define([AC_ENABLE_FAST_INSTALL_DEFAULT], ifelse($1, no, no, yes))dnl +AC_ARG_ENABLE([fast-install], + [AC_HELP_STRING([--enable-fast-install@<:@=PKGS@:>@], + [optimize for fast installation @<:@default=]AC_ENABLE_FAST_INSTALL_DEFAULT[@:>@])], + [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], + [enable_fast_install=]AC_ENABLE_FAST_INSTALL_DEFAULT) +])# AC_ENABLE_FAST_INSTALL - sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*) - case `$LD -v 2>&1` in - *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.1[[0-5]].*) - _LT_TAGVAR(ld_shlibs, $1)=no - cat <<_LT_EOF 1>&2 -*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not -*** reliably create shared libraries on SCO systems. Therefore, libtool -*** is disabling shared libraries support. We urge you to upgrade GNU -*** binutils to release 2.16.91.0.3 or newer. Another option is to modify -*** your PATH or compiler configuration so that the native linker is -*** used, and then restart. +# AC_DISABLE_FAST_INSTALL +# ----------------------- +# set the default to --disable-fast-install +AC_DEFUN([AC_DISABLE_FAST_INSTALL], +[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl +AC_ENABLE_FAST_INSTALL(no) +])# AC_DISABLE_FAST_INSTALL -_LT_EOF - ;; - *) - # For security reasons, it is highly recommended that you always - # use absolute paths for naming shared libraries, and exclude the - # DT_RUNPATH tag from executables and libraries. But doing so - # requires that you compile everything twice, which is a pain. - if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + +# AC_LIBTOOL_PICMODE([MODE]) +# -------------------------- +# implement the --with-pic flag +# MODE is either `yes' or `no'. If omitted, it defaults to `both'. +AC_DEFUN([AC_LIBTOOL_PICMODE], +[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl +pic_mode=ifelse($#,1,$1,default) +])# AC_LIBTOOL_PICMODE + + +# AC_PROG_EGREP +# ------------- +# This is predefined starting with Autoconf 2.54, so this conditional +# definition can be removed once we require Autoconf 2.54 or later. +m4_ifndef([AC_PROG_EGREP], [AC_DEFUN([AC_PROG_EGREP], +[AC_CACHE_CHECK([for egrep], [ac_cv_prog_egrep], + [if echo a | (grep -E '(a|b)') >/dev/null 2>&1 + then ac_cv_prog_egrep='grep -E' + else ac_cv_prog_egrep='egrep' + fi]) + EGREP=$ac_cv_prog_egrep + AC_SUBST([EGREP]) +])]) + + +# AC_PATH_TOOL_PREFIX +# ------------------- +# find a file program which can recognize shared library +AC_DEFUN([AC_PATH_TOOL_PREFIX], +[AC_REQUIRE([AC_PROG_EGREP])dnl +AC_MSG_CHECKING([for $1]) +AC_CACHE_VAL(lt_cv_path_MAGIC_CMD, +[case $MAGIC_CMD in +[[\\/*] | ?:[\\/]*]) + lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. + ;; +*) + lt_save_MAGIC_CMD="$MAGIC_CMD" + lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR +dnl $ac_dummy forces splitting on constant user-supplied paths. +dnl POSIX.2 word splitting is done only on the output of word expansions, +dnl not every word. This closes a longstanding sh security hole. + ac_dummy="ifelse([$2], , $PATH, [$2])" + for ac_dir in $ac_dummy; do + IFS="$lt_save_ifs" + test -z "$ac_dir" && ac_dir=. + if test -f $ac_dir/$1; then + lt_cv_path_MAGIC_CMD="$ac_dir/$1" + if test -n "$file_magic_test_file"; then + case $deplibs_check_method in + "file_magic "*) + file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` + MAGIC_CMD="$lt_cv_path_MAGIC_CMD" + if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | + $EGREP "$file_magic_regex" > /dev/null; then + : else - _LT_TAGVAR(ld_shlibs, $1)=no - fi - ;; - esac - ;; + cat <&2 - sunos4*) - _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' - wlarc= - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; +*** Warning: the command libtool uses to detect shared libraries, +*** $file_magic_cmd, produces output that libtool cannot recognize. +*** The result is that libtool may fail to recognize shared libraries +*** as such. This will affect the creation of libtool libraries that +*** depend on shared libraries, but programs linked with such libtool +*** libraries will work regardless of this problem. Nevertheless, you +*** may want to report the problem to your system manager and/or to +*** bug-libtool@gnu.org - *) - if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - else - _LT_TAGVAR(ld_shlibs, $1)=no +EOF + fi ;; + esac fi - ;; - esac - - if test "$_LT_TAGVAR(ld_shlibs, $1)" = no; then - runpath_var= - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= - _LT_TAGVAR(export_dynamic_flag_spec, $1)= - _LT_TAGVAR(whole_archive_flag_spec, $1)= + break fi - else - # PORTME fill in a description of your system's linker (not GNU ld) - case $host_os in - aix3*) - _LT_TAGVAR(allow_undefined_flag, $1)=unsupported - _LT_TAGVAR(always_export_symbols, $1)=yes - _LT_TAGVAR(archive_expsym_cmds, $1)='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname' - # Note: this linker hardcodes the directories in LIBPATH if there - # are no directories specified by -L. - _LT_TAGVAR(hardcode_minus_L, $1)=yes - if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then - # Neither direct hardcoding nor static linking is supported with a - # broken collect2. - _LT_TAGVAR(hardcode_direct, $1)=unsupported - fi - ;; + done + IFS="$lt_save_ifs" + MAGIC_CMD="$lt_save_MAGIC_CMD" + ;; +esac]) +MAGIC_CMD="$lt_cv_path_MAGIC_CMD" +if test -n "$MAGIC_CMD"; then + AC_MSG_RESULT($MAGIC_CMD) +else + AC_MSG_RESULT(no) +fi +])# AC_PATH_TOOL_PREFIX - aix[[4-9]]*) - if test "$host_cpu" = ia64; then - # On IA64, the linker does run time linking by default, so we don't - # have to do anything special. - aix_use_runtimelinking=no - exp_sym_flag='-Bexport' - no_entry_flag="" - else - # If we're using GNU nm, then we don't want the "-C" option. - # -C means demangle to AIX nm, but means don't demangle with GNU nm - if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then - _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols' - else - _LT_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols' - fi - aix_use_runtimelinking=no - # Test if we are trying to use run time linking or normal - # AIX style linking. If -brtl is somewhere in LDFLAGS, we - # need to do runtime linking. - case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*) - for ld_flag in $LDFLAGS; do - if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then - aix_use_runtimelinking=yes - break - fi - done - ;; - esac +# AC_PATH_MAGIC +# ------------- +# find a file program which can recognize a shared library +AC_DEFUN([AC_PATH_MAGIC], +[AC_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH) +if test -z "$lt_cv_path_MAGIC_CMD"; then + if test -n "$ac_tool_prefix"; then + AC_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH) + else + MAGIC_CMD=: + fi +fi +])# AC_PATH_MAGIC - exp_sym_flag='-bexport' - no_entry_flag='-bnoentry' - fi - # When large executables or shared objects are built, AIX ld can - # have problems creating the table of contents. If linking a library - # or program results in "error TOC overflow" add -mminimal-toc to - # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not - # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. +# AC_PROG_LD +# ---------- +# find the pathname to the GNU or non-GNU linker +AC_DEFUN([AC_PROG_LD], +[AC_ARG_WITH([gnu-ld], + [AC_HELP_STRING([--with-gnu-ld], + [assume the C compiler uses GNU ld @<:@default=no@:>@])], + [test "$withval" = no || with_gnu_ld=yes], + [with_gnu_ld=no]) +AC_REQUIRE([LT_AC_PROG_SED])dnl +AC_REQUIRE([AC_PROG_CC])dnl +AC_REQUIRE([AC_CANONICAL_HOST])dnl +AC_REQUIRE([AC_CANONICAL_BUILD])dnl +ac_prog=ld +if test "$GCC" = yes; then + # Check if gcc -print-prog-name=ld gives a path. + AC_MSG_CHECKING([for ld used by $CC]) + case $host in + *-*-mingw*) + # gcc leaves a trailing carriage return which upsets mingw + ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; + *) + ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; + esac + case $ac_prog in + # Accept absolute paths. + [[\\/]]* | ?:[[\\/]]*) + re_direlt='/[[^/]][[^/]]*/\.\./' + # Canonicalize the pathname of ld + ac_prog=`echo $ac_prog| $SED 's%\\\\%/%g'` + while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do + ac_prog=`echo $ac_prog| $SED "s%$re_direlt%/%"` + done + test -z "$LD" && LD="$ac_prog" + ;; + "") + # If it fails, then pretend we aren't using GCC. + ac_prog=ld + ;; + *) + # If it is relative, then search for the first ld in PATH. + with_gnu_ld=unknown + ;; + esac +elif test "$with_gnu_ld" = yes; then + AC_MSG_CHECKING([for GNU ld]) +else + AC_MSG_CHECKING([for non-GNU ld]) +fi +AC_CACHE_VAL(lt_cv_path_LD, +[if test -z "$LD"; then + lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR + for ac_dir in $PATH; do + IFS="$lt_save_ifs" + test -z "$ac_dir" && ac_dir=. + if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then + lt_cv_path_LD="$ac_dir/$ac_prog" + # Check to see if the program is GNU ld. I'd rather use --version, + # but apparently some variants of GNU ld only accept -v. + # Break only if it was the GNU/non-GNU ld that we prefer. + case `"$lt_cv_path_LD" -v 2>&1 /dev/null - then - # We have reworked collect2 - : - else - # We have old collect2 - _LT_TAGVAR(hardcode_direct, $1)=unsupported - # It fails to find uninstalled libraries when the uninstalled - # path is not listed in the libpath. Setting hardcode_minus_L - # to unsupported forces relinking - _LT_TAGVAR(hardcode_minus_L, $1)=yes - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)= - fi - ;; - esac - shared_flag='-shared' - if test "$aix_use_runtimelinking" = yes; then - shared_flag="$shared_flag "'${wl}-G' - fi - else - # not using gcc - if test "$host_cpu" = ia64; then - # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release - # chokes on -Wl,-G. The following line is correct: - shared_flag='-G' - else - if test "$aix_use_runtimelinking" = yes; then - shared_flag='${wl}-G' - else - shared_flag='${wl}-bM:SRE' - fi - fi - fi +# AC_PROG_LD_GNU +# -------------- +AC_DEFUN([AC_PROG_LD_GNU], +[AC_REQUIRE([AC_PROG_EGREP])dnl +AC_CACHE_CHECK([if the linker ($LD) is GNU ld], lt_cv_prog_gnu_ld, +[# I'd rather use --version here, but apparently some GNU lds only accept -v. +case `$LD -v 2>&1 /dev/null 2>&1; then + lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' + lt_cv_file_magic_cmd='func_win32_libid' + else + lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?' + lt_cv_file_magic_cmd='$OBJDUMP -f' + fi + ;; - # FreeBSD 3 and greater uses gcc -shared to do shared libraries. - freebsd* | dragonfly*) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no +darwin* | rhapsody*) + lt_cv_deplibs_check_method=pass_all + ;; + +freebsd* | dragonfly*) + if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then + case $host_cpu in + i*86 ) + # Not sure whether the presence of OpenBSD here was a mistake. + # Let's accept both of them until this is cleared up. + lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[[3-9]]86 (compact )?demand paged shared library' + lt_cv_file_magic_cmd=/usr/bin/file + lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` ;; + esac + else + lt_cv_deplibs_check_method=pass_all + fi + ;; - hpux9*) - if test "$GCC" = yes; then - _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' - else - _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' - fi - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)=: - _LT_TAGVAR(hardcode_direct, $1)=yes +gnu*) + lt_cv_deplibs_check_method=pass_all + ;; - # hardcode_minus_L: Not really in the search PATH, - # but as the default location of the library. - _LT_TAGVAR(hardcode_minus_L, $1)=yes - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' - ;; +hpux10.20* | hpux11*) + lt_cv_file_magic_cmd=/usr/bin/file + case $host_cpu in + ia64*) + lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64' + lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so + ;; + hppa*64*) + [lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - PA-RISC [0-9].[0-9]'] + lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl + ;; + *) + lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]].[[0-9]]) shared library' + lt_cv_file_magic_test_file=/usr/lib/libc.sl + ;; + esac + ;; - hpux10*) - if test "$GCC" = yes -a "$with_gnu_ld" = no; then - _LT_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' - else - _LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' - fi - if test "$with_gnu_ld" = no; then - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' - _LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='+b $libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)=: - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_direct_absolute, $1)=yes - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' - # hardcode_minus_L: Not really in the search PATH, - # but as the default location of the library. - _LT_TAGVAR(hardcode_minus_L, $1)=yes - fi - ;; +interix[[3-9]]*) + # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here + lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|\.a)$' + ;; - hpux11*) - if test "$GCC" = yes -a "$with_gnu_ld" = no; then - case $host_cpu in - hppa*64*) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - ;; - ia64*) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' - ;; - *) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' - ;; - esac - else - case $host_cpu in - hppa*64*) - _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - ;; - ia64*) - _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' - ;; - *) - _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' - ;; - esac - fi - if test "$with_gnu_ld" = no; then - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)=: +irix5* | irix6* | nonstopux*) + case $LD in + *-32|*"-32 ") libmagic=32-bit;; + *-n32|*"-n32 ") libmagic=N32;; + *-64|*"-64 ") libmagic=64-bit;; + *) libmagic=never-match;; + esac + lt_cv_deplibs_check_method=pass_all + ;; - case $host_cpu in - hppa*64*|ia64*) - _LT_TAGVAR(hardcode_direct, $1)=no - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - *) - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_direct_absolute, $1)=yes - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' +# This must be Linux ELF. +linux* | k*bsd*-gnu) + lt_cv_deplibs_check_method=pass_all + ;; - # hardcode_minus_L: Not really in the search PATH, - # but as the default location of the library. - _LT_TAGVAR(hardcode_minus_L, $1)=yes - ;; - esac - fi - ;; +netbsd*) + if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then + lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' + else + lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$' + fi + ;; - irix5* | irix6* | nonstopux*) - if test "$GCC" = yes; then - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' - # Try to use the -exported_symbol ld option, if it does not - # work, assume that -exports_file does not work either and - # implicitly export all symbols. - save_LDFLAGS="$LDFLAGS" - LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null" - AC_LINK_IFELSE(int foo(void) {}, - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib' - ) - LDFLAGS="$save_LDFLAGS" - else - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib' - fi - _LT_TAGVAR(archive_cmds_need_lc, $1)='no' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)=: - _LT_TAGVAR(inherit_rpath, $1)=yes - _LT_TAGVAR(link_all_deplibs, $1)=yes - ;; +newos6*) + lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)' + lt_cv_file_magic_cmd=/usr/bin/file + lt_cv_file_magic_test_file=/usr/lib/libnls.so + ;; - netbsd*) - if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then - _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out - else - _LT_TAGVAR(archive_cmds, $1)='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF - fi - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; +nto-qnx*) + lt_cv_deplibs_check_method=unknown + ;; - newsos6) - _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)=: - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; +openbsd*) + if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then + lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$' + else + lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' + fi + ;; - *nto* | *qnx*) - ;; +osf3* | osf4* | osf5*) + lt_cv_deplibs_check_method=pass_all + ;; - openbsd*) - if test -f /usr/libexec/ld.so; then - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - _LT_TAGVAR(hardcode_direct_absolute, $1)=yes - if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' - else - case $host_os in - openbsd[[01]].* | openbsd2.[[0-7]] | openbsd2.[[0-7]].*) - _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - ;; - *) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - ;; - esac - fi - else - _LT_TAGVAR(ld_shlibs, $1)=no - fi - ;; +rdos*) + lt_cv_deplibs_check_method=pass_all + ;; - os2*) - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_TAGVAR(hardcode_minus_L, $1)=yes - _LT_TAGVAR(allow_undefined_flag, $1)=unsupported - _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~$ECHO DATA >> $output_objdir/$libname.def~$ECHO " SINGLE NONSHARED" >> $output_objdir/$libname.def~$ECHO EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def' - _LT_TAGVAR(old_archive_from_new_cmds, $1)='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def' - ;; +solaris*) + lt_cv_deplibs_check_method=pass_all + ;; - osf3*) - if test "$GCC" = yes; then - _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' - _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' - else - _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' - _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib' - fi - _LT_TAGVAR(archive_cmds_need_lc, $1)='no' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)=: - ;; +sysv4 | sysv4.3*) + case $host_vendor in + motorola) + lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib) M[[0-9]][[0-9]]* Version [[0-9]]' + lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*` + ;; + ncr) + lt_cv_deplibs_check_method=pass_all + ;; + sequent) + lt_cv_file_magic_cmd='/bin/file' + lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )' + ;; + sni) + lt_cv_file_magic_cmd='/bin/file' + lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib" + lt_cv_file_magic_test_file=/lib/libc.so + ;; + siemens) + lt_cv_deplibs_check_method=pass_all + ;; + pc) + lt_cv_deplibs_check_method=pass_all + ;; + esac + ;; - osf4* | osf5*) # as osf3* with the addition of -msym flag - if test "$GCC" = yes; then - _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' - _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - else - _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' - _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; printf "%s\\n" "-hidden">> $lib.exp~ - $CC -shared${allow_undefined_flag} ${wl}-input ${wl}$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib~$RM $lib.exp' +sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) + lt_cv_deplibs_check_method=pass_all + ;; +esac +]) +file_magic_cmd=$lt_cv_file_magic_cmd +deplibs_check_method=$lt_cv_deplibs_check_method +test -z "$deplibs_check_method" && deplibs_check_method=unknown +])# AC_DEPLIBS_CHECK_METHOD - # Both c and cxx compiler support -rpath directly - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' - fi - _LT_TAGVAR(archive_cmds_need_lc, $1)='no' - _LT_TAGVAR(hardcode_libdir_separator, $1)=: - ;; - solaris*) - _LT_TAGVAR(no_undefined_flag, $1)=' -z defs' - if test "$GCC" = yes; then - wlarc='${wl}' - _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $CC -shared ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' - else - case `$CC -V 2>&1` in - *"Compilers 5.0"*) - wlarc='' - _LT_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp' +# AC_PROG_NM +# ---------- +# find the pathname to a BSD-compatible name lister +AC_DEFUN([AC_PROG_NM], +[AC_CACHE_CHECK([for BSD-compatible nm], lt_cv_path_NM, +[if test -n "$NM"; then + # Let the user override the test. + lt_cv_path_NM="$NM" +else + lt_nm_to_check="${ac_tool_prefix}nm" + if test -n "$ac_tool_prefix" && test "$build" = "$host"; then + lt_nm_to_check="$lt_nm_to_check nm" + fi + for lt_tmp_nm in $lt_nm_to_check; do + lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR + for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do + IFS="$lt_save_ifs" + test -z "$ac_dir" && ac_dir=. + tmp_nm="$ac_dir/$lt_tmp_nm" + if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then + # Check to see if the nm accepts a BSD-compat flag. + # Adding the `sed 1q' prevents false positives on HP-UX, which says: + # nm: unknown option "B" ignored + # Tru64's nm complains that /dev/null is an invalid object file + case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in + */dev/null* | *'Invalid file or object type'*) + lt_cv_path_NM="$tmp_nm -B" + break ;; *) - wlarc='${wl}' - _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $CC -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' + case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in + */dev/null*) + lt_cv_path_NM="$tmp_nm -p" + break + ;; + *) + lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but + continue # so that we can try to find one that supports BSD flags + ;; + esac ;; esac fi - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - case $host_os in - solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; - *) - # The compiler driver will combine and reorder linker options, - # but understands `-z linker_flag'. GCC discards it without `$wl', - # but is careful enough not to reorder. - # Supported since Solaris 2.6 (maybe 2.5.1?) - if test "$GCC" = yes; then - _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' - else - _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' - fi - ;; - esac - _LT_TAGVAR(link_all_deplibs, $1)=yes - ;; + done + IFS="$lt_save_ifs" + done + test -z "$lt_cv_path_NM" && lt_cv_path_NM=nm +fi]) +NM="$lt_cv_path_NM" +])# AC_PROG_NM - sunos4*) - if test "x$host_vendor" = xsequent; then - # Use $CC to link under sequent, because it throws in some extra .o - # files that make .init and .fini sections work. - _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags' - else - _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' - fi - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_minus_L, $1)=yes - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - sysv4) - case $host_vendor in - sni) - _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_TAGVAR(hardcode_direct, $1)=yes # is this really true??? - ;; - siemens) - ## LD is ld it makes a PLAMLIB - ## CC just makes a GrossModule. - _LT_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags' - _LT_TAGVAR(reload_cmds, $1)='$CC -r -o $output$reload_objs' - _LT_TAGVAR(hardcode_direct, $1)=no - ;; - motorola) - _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_TAGVAR(hardcode_direct, $1)=no #Motorola manual says yes, but my tests say they lie - ;; - esac - runpath_var='LD_RUN_PATH' - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; +# AC_CHECK_LIBM +# ------------- +# check for math library +AC_DEFUN([AC_CHECK_LIBM], +[AC_REQUIRE([AC_CANONICAL_HOST])dnl +LIBM= +case $host in +*-*-beos* | *-*-cygwin* | *-*-pw32* | *-*-darwin*) + # These system don't have libm, or don't need it + ;; +*-ncr-sysv4.3*) + AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM="-lmw") + AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm") + ;; +*) + AC_CHECK_LIB(m, cos, LIBM="-lm") + ;; +esac +])# AC_CHECK_LIBM - sysv4.3*) - _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - _LT_TAGVAR(export_dynamic_flag_spec, $1)='-Bexport' - ;; - sysv4*MP*) - if test -d /usr/nec; then - _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - runpath_var=LD_RUN_PATH - hardcode_runpath_var=yes - _LT_TAGVAR(ld_shlibs, $1)=yes - fi - ;; +# AC_LIBLTDL_CONVENIENCE([DIRECTORY]) +# ----------------------------------- +# sets LIBLTDL to the link flags for the libltdl convenience library and +# LTDLINCL to the include flags for the libltdl header and adds +# --enable-ltdl-convenience to the configure arguments. Note that +# AC_CONFIG_SUBDIRS is not called here. If DIRECTORY is not provided, +# it is assumed to be `libltdl'. LIBLTDL will be prefixed with +# '${top_builddir}/' and LTDLINCL will be prefixed with '${top_srcdir}/' +# (note the single quotes!). If your package is not flat and you're not +# using automake, define top_builddir and top_srcdir appropriately in +# the Makefiles. +AC_DEFUN([AC_LIBLTDL_CONVENIENCE], +[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl + case $enable_ltdl_convenience in + no) AC_MSG_ERROR([this package needs a convenience libltdl]) ;; + "") enable_ltdl_convenience=yes + ac_configure_args="$ac_configure_args --enable-ltdl-convenience" ;; + esac + LIBLTDL='${top_builddir}/'ifelse($#,1,[$1],['libltdl'])/libltdlc.la + LTDLINCL='-I${top_srcdir}/'ifelse($#,1,[$1],['libltdl']) + # For backwards non-gettext consistent compatibility... + INCLTDL="$LTDLINCL" +])# AC_LIBLTDL_CONVENIENCE - sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*) - _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' - _LT_TAGVAR(archive_cmds_need_lc, $1)=no - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - runpath_var='LD_RUN_PATH' - if test "$GCC" = yes; then - _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - else - _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - fi - ;; +# AC_LIBLTDL_INSTALLABLE([DIRECTORY]) +# ----------------------------------- +# sets LIBLTDL to the link flags for the libltdl installable library and +# LTDLINCL to the include flags for the libltdl header and adds +# --enable-ltdl-install to the configure arguments. Note that +# AC_CONFIG_SUBDIRS is not called here. If DIRECTORY is not provided, +# and an installed libltdl is not found, it is assumed to be `libltdl'. +# LIBLTDL will be prefixed with '${top_builddir}/'# and LTDLINCL with +# '${top_srcdir}/' (note the single quotes!). If your package is not +# flat and you're not using automake, define top_builddir and top_srcdir +# appropriately in the Makefiles. +# In the future, this macro may have to be called after AC_PROG_LIBTOOL. +AC_DEFUN([AC_LIBLTDL_INSTALLABLE], +[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl + AC_CHECK_LIB(ltdl, lt_dlinit, + [test x"$enable_ltdl_install" != xyes && enable_ltdl_install=no], + [if test x"$enable_ltdl_install" = xno; then + AC_MSG_WARN([libltdl not installed, but installation disabled]) + else + enable_ltdl_install=yes + fi + ]) + if test x"$enable_ltdl_install" = x"yes"; then + ac_configure_args="$ac_configure_args --enable-ltdl-install" + LIBLTDL='${top_builddir}/'ifelse($#,1,[$1],['libltdl'])/libltdl.la + LTDLINCL='-I${top_srcdir}/'ifelse($#,1,[$1],['libltdl']) + else + ac_configure_args="$ac_configure_args --enable-ltdl-install=no" + LIBLTDL="-lltdl" + LTDLINCL= + fi + # For backwards non-gettext consistent compatibility... + INCLTDL="$LTDLINCL" +])# AC_LIBLTDL_INSTALLABLE - sysv5* | sco3.2v5* | sco5v6*) - # Note: We can NOT use -z defs as we might desire, because we do not - # link with -lc, and that would cause any symbols used from libc to - # always be unresolved, which means just about no library would - # ever link correctly. If we're not using GNU ld we use -z text - # though, which does catch some bad symbols but isn't as heavy-handed - # as -z defs. - _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' - _LT_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs' - _LT_TAGVAR(archive_cmds_need_lc, $1)=no - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R,$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)=':' - _LT_TAGVAR(link_all_deplibs, $1)=yes - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport' - runpath_var='LD_RUN_PATH' - if test "$GCC" = yes; then - _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - else - _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - fi - ;; +# AC_LIBTOOL_CXX +# -------------- +# enable support for C++ libraries +AC_DEFUN([AC_LIBTOOL_CXX], +[AC_REQUIRE([_LT_AC_LANG_CXX]) +])# AC_LIBTOOL_CXX - uts4*) - _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - *) - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - esac +# _LT_AC_LANG_CXX +# --------------- +AC_DEFUN([_LT_AC_LANG_CXX], +[AC_REQUIRE([AC_PROG_CXX]) +AC_REQUIRE([_LT_AC_PROG_CXXCPP]) +_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}CXX]) +])# _LT_AC_LANG_CXX - if test x$host_vendor = xsni; then - case $host in - sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Blargedynsym' - ;; - esac - fi - fi -]) -AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)]) -test "$_LT_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no +# _LT_AC_PROG_CXXCPP +# ------------------ +AC_DEFUN([_LT_AC_PROG_CXXCPP], +[ +AC_REQUIRE([AC_PROG_CXX]) +if test -n "$CXX" && ( test "X$CXX" != "Xno" && + ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) || + (test "X$CXX" != "Xg++"))) ; then + AC_PROG_CXXCPP +fi +])# _LT_AC_PROG_CXXCPP -_LT_TAGVAR(with_gnu_ld, $1)=$with_gnu_ld +# AC_LIBTOOL_F77 +# -------------- +# enable support for Fortran 77 libraries +AC_DEFUN([AC_LIBTOOL_F77], +[AC_REQUIRE([_LT_AC_LANG_F77]) +])# AC_LIBTOOL_F77 -_LT_DECL([], [libext], [0], [Old archive suffix (normally "a")])dnl -_LT_DECL([], [shrext_cmds], [1], [Shared library suffix (normally ".so")])dnl -_LT_DECL([], [extract_expsyms_cmds], [2], - [The commands to extract the exported symbol list from a shared archive]) -# -# Do we need to explicitly link libc? -# -case "x$_LT_TAGVAR(archive_cmds_need_lc, $1)" in -x|xyes) - # Assume -lc should be added - _LT_TAGVAR(archive_cmds_need_lc, $1)=yes +# _LT_AC_LANG_F77 +# --------------- +AC_DEFUN([_LT_AC_LANG_F77], +[AC_REQUIRE([AC_PROG_F77]) +_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}F77]) +])# _LT_AC_LANG_F77 - if test "$enable_shared" = yes && test "$GCC" = yes; then - case $_LT_TAGVAR(archive_cmds, $1) in - *'~'*) - # FIXME: we may have to deal with multi-command sequences. - ;; - '$CC '*) - # Test whether the compiler implicitly links with -lc since on some - # systems, -lgcc has to come before -lc. If gcc already passes -lc - # to ld, don't add -lc before -lgcc. - AC_MSG_CHECKING([whether -lc should be explicitly linked in]) - $RM conftest* - echo "$lt_simple_compile_test_code" > conftest.$ac_ext - if AC_TRY_EVAL(ac_compile) 2>conftest.err; then - soname=conftest - lib=conftest - libobjs=conftest.$ac_objext - deplibs= - wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) - pic_flag=$_LT_TAGVAR(lt_prog_compiler_pic, $1) - compiler_flags=-v - linker_flags=-v - verstring= - output_objdir=. - libname=conftest - lt_save_allow_undefined_flag=$_LT_TAGVAR(allow_undefined_flag, $1) - _LT_TAGVAR(allow_undefined_flag, $1)= - if AC_TRY_EVAL(_LT_TAGVAR(archive_cmds, $1) 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) - then - _LT_TAGVAR(archive_cmds_need_lc, $1)=no - else - _LT_TAGVAR(archive_cmds_need_lc, $1)=yes - fi - _LT_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag - else - cat conftest.err 1>&5 - fi - $RM conftest* - AC_MSG_RESULT([$_LT_TAGVAR(archive_cmds_need_lc, $1)]) - ;; - esac - fi - ;; -esac +# AC_LIBTOOL_GCJ +# -------------- +# enable support for GCJ libraries +AC_DEFUN([AC_LIBTOOL_GCJ], +[AC_REQUIRE([_LT_AC_LANG_GCJ]) +])# AC_LIBTOOL_GCJ + + +# _LT_AC_LANG_GCJ +# --------------- +AC_DEFUN([_LT_AC_LANG_GCJ], +[AC_PROVIDE_IFELSE([AC_PROG_GCJ],[], + [AC_PROVIDE_IFELSE([A][M_PROG_GCJ],[], + [AC_PROVIDE_IFELSE([LT_AC_PROG_GCJ],[], + [ifdef([AC_PROG_GCJ],[AC_REQUIRE([AC_PROG_GCJ])], + [ifdef([A][M_PROG_GCJ],[AC_REQUIRE([A][M_PROG_GCJ])], + [AC_REQUIRE([A][C_PROG_GCJ_OR_A][M_PROG_GCJ])])])])])]) +_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}GCJ]) +])# _LT_AC_LANG_GCJ + + +# AC_LIBTOOL_RC +# ------------- +# enable support for Windows resource files +AC_DEFUN([AC_LIBTOOL_RC], +[AC_REQUIRE([LT_AC_PROG_RC]) +_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}RC]) +])# AC_LIBTOOL_RC + -_LT_TAGDECL([build_libtool_need_lc], [archive_cmds_need_lc], [0], - [Whether or not to add -lc for building shared libraries]) -_LT_TAGDECL([allow_libtool_libs_with_static_runtimes], - [enable_shared_with_static_runtimes], [0], - [Whether or not to disallow shared libs when runtime libs are static]) -_LT_TAGDECL([], [export_dynamic_flag_spec], [1], - [Compiler flag to allow reflexive dlopens]) -_LT_TAGDECL([], [whole_archive_flag_spec], [1], - [Compiler flag to generate shared objects directly from archives]) -_LT_TAGDECL([], [compiler_needs_object], [1], - [Whether the compiler copes with passing no objects directly]) -_LT_TAGDECL([], [old_archive_from_new_cmds], [2], - [Create an old-style archive from a shared archive]) -_LT_TAGDECL([], [old_archive_from_expsyms_cmds], [2], - [Create a temporary old-style archive to link instead of a shared archive]) -_LT_TAGDECL([], [archive_cmds], [2], [Commands used to build a shared archive]) -_LT_TAGDECL([], [archive_expsym_cmds], [2]) -_LT_TAGDECL([], [module_cmds], [2], - [Commands used to build a loadable module if different from building - a shared archive.]) -_LT_TAGDECL([], [module_expsym_cmds], [2]) -_LT_TAGDECL([], [with_gnu_ld], [1], - [Whether we are building with GNU ld or not]) -_LT_TAGDECL([], [allow_undefined_flag], [1], - [Flag that allows shared libraries with undefined symbols to be built]) -_LT_TAGDECL([], [no_undefined_flag], [1], - [Flag that enforces no undefined symbols]) -_LT_TAGDECL([], [hardcode_libdir_flag_spec], [1], - [Flag to hardcode $libdir into a binary during linking. - This must work even if $libdir does not exist]) -_LT_TAGDECL([], [hardcode_libdir_flag_spec_ld], [1], - [[If ld is used when linking, flag to hardcode $libdir into a binary - during linking. This must work even if $libdir does not exist]]) -_LT_TAGDECL([], [hardcode_libdir_separator], [1], - [Whether we need a single "-rpath" flag with a separated argument]) -_LT_TAGDECL([], [hardcode_direct], [0], - [Set to "yes" if using DIR/libNAME${shared_ext} during linking hardcodes - DIR into the resulting binary]) -_LT_TAGDECL([], [hardcode_direct_absolute], [0], - [Set to "yes" if using DIR/libNAME${shared_ext} during linking hardcodes - DIR into the resulting binary and the resulting library dependency is - "absolute", i.e impossible to change by setting ${shlibpath_var} if the - library is relocated]) -_LT_TAGDECL([], [hardcode_minus_L], [0], - [Set to "yes" if using the -LDIR flag during linking hardcodes DIR - into the resulting binary]) -_LT_TAGDECL([], [hardcode_shlibpath_var], [0], - [Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR - into the resulting binary]) -_LT_TAGDECL([], [hardcode_automatic], [0], - [Set to "yes" if building a shared library automatically hardcodes DIR - into the library and all subsequent libraries and executables linked - against it]) -_LT_TAGDECL([], [inherit_rpath], [0], - [Set to yes if linker adds runtime paths of dependent libraries - to runtime path list]) -_LT_TAGDECL([], [link_all_deplibs], [0], - [Whether libtool must link a program against all its dependency libraries]) -_LT_TAGDECL([], [fix_srcfile_path], [1], - [Fix the shell variable $srcfile for the compiler]) -_LT_TAGDECL([], [always_export_symbols], [0], - [Set to "yes" if exported symbols are required]) -_LT_TAGDECL([], [export_symbols_cmds], [2], - [The commands to list exported symbols]) -_LT_TAGDECL([], [exclude_expsyms], [1], - [Symbols that should not be listed in the preloaded symbols]) -_LT_TAGDECL([], [include_expsyms], [1], - [Symbols that must always be exported]) -_LT_TAGDECL([], [prelink_cmds], [2], - [Commands necessary for linking programs (against libraries) with templates]) -_LT_TAGDECL([], [file_list_spec], [1], - [Specify filename containing input files]) -dnl FIXME: Not yet implemented -dnl _LT_TAGDECL([], [thread_safe_flag_spec], [1], -dnl [Compiler flag to generate thread safe objects]) -])# _LT_LINKER_SHLIBS - - -# _LT_LANG_C_CONFIG([TAG]) +# AC_LIBTOOL_LANG_C_CONFIG # ------------------------ -# Ensure that the configuration variables for a C compiler are suitably -# defined. These variables are subsequently used by _LT_CONFIG to write -# the compiler configuration to `libtool'. -m4_defun([_LT_LANG_C_CONFIG], -[m4_require([_LT_DECL_EGREP])dnl -lt_save_CC="$CC" +# Ensure that the configuration vars for the C compiler are +# suitably defined. Those variables are subsequently used by +# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'. +AC_DEFUN([AC_LIBTOOL_LANG_C_CONFIG], [_LT_AC_LANG_C_CONFIG]) +AC_DEFUN([_LT_AC_LANG_C_CONFIG], +[lt_save_CC="$CC" AC_LANG_PUSH(C) # Source file extension for C test sources. @@ -5258,7 +4534,7 @@ ac_ext=c # Object file extension for compiled C test sources. objext=o -_LT_TAGVAR(objext, $1)=$objext +_LT_AC_TAGVAR(objext, $1)=$objext # Code to be used in simple compile tests lt_simple_compile_test_code="int some_variable = 0;" @@ -5266,1115 +4542,1080 @@ lt_simple_compile_test_code="int some_variable = 0;" # Code to be used in simple link tests lt_simple_link_test_code='int main(){return(0);}' -_LT_TAG_COMPILER -# Save the default compiler, since it gets overwritten when the other -# tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP. -compiler_DEFAULT=$CC +_LT_AC_SYS_COMPILER # save warnings/boilerplate of simple test code _LT_COMPILER_BOILERPLATE _LT_LINKER_BOILERPLATE -if test -n "$compiler"; then - _LT_COMPILER_NO_RTTI($1) - _LT_COMPILER_PIC($1) - _LT_COMPILER_C_O($1) - _LT_COMPILER_FILE_LOCKS($1) - _LT_LINKER_SHLIBS($1) - _LT_SYS_DYNAMIC_LINKER($1) - _LT_LINKER_HARDCODE_LIBPATH($1) - LT_SYS_DLOPEN_SELF - _LT_CMD_STRIPLIB - - # Report which library types will actually be built - AC_MSG_CHECKING([if libtool supports shared libraries]) - AC_MSG_RESULT([$can_build_shared]) - - AC_MSG_CHECKING([whether to build shared libraries]) - test "$can_build_shared" = "no" && enable_shared=no - - # On AIX, shared libraries and static libraries use the same namespace, and - # are all built from PIC. - case $host_os in - aix3*) +AC_LIBTOOL_PROG_COMPILER_NO_RTTI($1) +AC_LIBTOOL_PROG_COMPILER_PIC($1) +AC_LIBTOOL_PROG_CC_C_O($1) +AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1) +AC_LIBTOOL_PROG_LD_SHLIBS($1) +AC_LIBTOOL_SYS_DYNAMIC_LINKER($1) +AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1) +AC_LIBTOOL_SYS_LIB_STRIP +AC_LIBTOOL_DLOPEN_SELF + +# Report which library types will actually be built +AC_MSG_CHECKING([if libtool supports shared libraries]) +AC_MSG_RESULT([$can_build_shared]) + +AC_MSG_CHECKING([whether to build shared libraries]) +test "$can_build_shared" = "no" && enable_shared=no + +# On AIX, shared libraries and static libraries use the same namespace, and +# are all built from PIC. +case $host_os in +aix3*) + test "$enable_shared" = yes && enable_static=no + if test -n "$RANLIB"; then + archive_cmds="$archive_cmds~\$RANLIB \$lib" + postinstall_cmds='$RANLIB $lib' + fi + ;; + +aix[[4-9]]*) + if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then test "$enable_shared" = yes && enable_static=no - if test -n "$RANLIB"; then - archive_cmds="$archive_cmds~\$RANLIB \$lib" - postinstall_cmds='$RANLIB $lib' - fi + fi ;; +esac +AC_MSG_RESULT([$enable_shared]) - aix[[4-9]]*) - if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then - test "$enable_shared" = yes && enable_static=no - fi - ;; - esac - AC_MSG_RESULT([$enable_shared]) +AC_MSG_CHECKING([whether to build static libraries]) +# Make sure either enable_shared or enable_static is yes. +test "$enable_shared" = yes || enable_static=yes +AC_MSG_RESULT([$enable_static]) + +AC_LIBTOOL_CONFIG($1) + +AC_LANG_POP +CC="$lt_save_CC" +])# AC_LIBTOOL_LANG_C_CONFIG + + +# AC_LIBTOOL_LANG_CXX_CONFIG +# -------------------------- +# Ensure that the configuration vars for the C compiler are +# suitably defined. Those variables are subsequently used by +# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'. +AC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG], [_LT_AC_LANG_CXX_CONFIG(CXX)]) +AC_DEFUN([_LT_AC_LANG_CXX_CONFIG], +[AC_LANG_PUSH(C++) +AC_REQUIRE([AC_PROG_CXX]) +AC_REQUIRE([_LT_AC_PROG_CXXCPP]) + +_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no +_LT_AC_TAGVAR(allow_undefined_flag, $1)= +_LT_AC_TAGVAR(always_export_symbols, $1)=no +_LT_AC_TAGVAR(archive_expsym_cmds, $1)= +_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)= +_LT_AC_TAGVAR(hardcode_direct, $1)=no +_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)= +_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)= +_LT_AC_TAGVAR(hardcode_libdir_separator, $1)= +_LT_AC_TAGVAR(hardcode_minus_L, $1)=no +_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported +_LT_AC_TAGVAR(hardcode_automatic, $1)=no +_LT_AC_TAGVAR(module_cmds, $1)= +_LT_AC_TAGVAR(module_expsym_cmds, $1)= +_LT_AC_TAGVAR(link_all_deplibs, $1)=unknown +_LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds +_LT_AC_TAGVAR(no_undefined_flag, $1)= +_LT_AC_TAGVAR(whole_archive_flag_spec, $1)= +_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no + +# Dependencies to place before and after the object being linked: +_LT_AC_TAGVAR(predep_objects, $1)= +_LT_AC_TAGVAR(postdep_objects, $1)= +_LT_AC_TAGVAR(predeps, $1)= +_LT_AC_TAGVAR(postdeps, $1)= +_LT_AC_TAGVAR(compiler_lib_search_path, $1)= +_LT_AC_TAGVAR(compiler_lib_search_dirs, $1)= + +# Source file extension for C++ test sources. +ac_ext=cpp + +# Object file extension for compiled C++ test sources. +objext=o +_LT_AC_TAGVAR(objext, $1)=$objext + +# Code to be used in simple compile tests +lt_simple_compile_test_code="int some_variable = 0;" + +# Code to be used in simple link tests +lt_simple_link_test_code='int main(int, char *[[]]) { return(0); }' + +# ltmain only uses $CC for tagged configurations so make sure $CC is set. +_LT_AC_SYS_COMPILER - AC_MSG_CHECKING([whether to build static libraries]) - # Make sure either enable_shared or enable_static is yes. - test "$enable_shared" = yes || enable_static=yes - AC_MSG_RESULT([$enable_static]) +# save warnings/boilerplate of simple test code +_LT_COMPILER_BOILERPLATE +_LT_LINKER_BOILERPLATE - _LT_CONFIG($1) +# Allow CC to be a program name with arguments. +lt_save_CC=$CC +lt_save_LD=$LD +lt_save_GCC=$GCC +GCC=$GXX +lt_save_with_gnu_ld=$with_gnu_ld +lt_save_path_LD=$lt_cv_path_LD +if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then + lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx +else + $as_unset lt_cv_prog_gnu_ld +fi +if test -n "${lt_cv_path_LDCXX+set}"; then + lt_cv_path_LD=$lt_cv_path_LDCXX +else + $as_unset lt_cv_path_LD fi -AC_LANG_POP -CC="$lt_save_CC" -])# _LT_LANG_C_CONFIG - +test -z "${LDCXX+set}" || LD=$LDCXX +CC=${CXX-"c++"} +compiler=$CC +_LT_AC_TAGVAR(compiler, $1)=$CC +_LT_CC_BASENAME([$compiler]) -# _LT_PROG_CXX -# ------------ -# Since AC_PROG_CXX is broken, in that it returns g++ if there is no c++ -# compiler, we have our own version here. -m4_defun([_LT_PROG_CXX], -[ -pushdef([AC_MSG_ERROR], [_lt_caught_CXX_error=yes]) -AC_PROG_CXX -if test -n "$CXX" && ( test "X$CXX" != "Xno" && - ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) || - (test "X$CXX" != "Xg++"))) ; then - AC_PROG_CXXCPP +# We don't want -fno-exception wen compiling C++ code, so set the +# no_builtin_flag separately +if test "$GXX" = yes; then + _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' else - _lt_caught_CXX_error=yes + _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= fi -popdef([AC_MSG_ERROR]) -])# _LT_PROG_CXX -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([_LT_PROG_CXX], []) +if test "$GXX" = yes; then + # Set up default GNU C++ configuration + AC_PROG_LD -# _LT_LANG_CXX_CONFIG([TAG]) -# -------------------------- -# Ensure that the configuration variables for a C++ compiler are suitably -# defined. These variables are subsequently used by _LT_CONFIG to write -# the compiler configuration to `libtool'. -m4_defun([_LT_LANG_CXX_CONFIG], -[AC_REQUIRE([_LT_PROG_CXX])dnl -m4_require([_LT_FILEUTILS_DEFAULTS])dnl -m4_require([_LT_DECL_EGREP])dnl - -AC_LANG_PUSH(C++) -_LT_TAGVAR(archive_cmds_need_lc, $1)=no -_LT_TAGVAR(allow_undefined_flag, $1)= -_LT_TAGVAR(always_export_symbols, $1)=no -_LT_TAGVAR(archive_expsym_cmds, $1)= -_LT_TAGVAR(compiler_needs_object, $1)=no -_LT_TAGVAR(export_dynamic_flag_spec, $1)= -_LT_TAGVAR(hardcode_direct, $1)=no -_LT_TAGVAR(hardcode_direct_absolute, $1)=no -_LT_TAGVAR(hardcode_libdir_flag_spec, $1)= -_LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)= -_LT_TAGVAR(hardcode_libdir_separator, $1)= -_LT_TAGVAR(hardcode_minus_L, $1)=no -_LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported -_LT_TAGVAR(hardcode_automatic, $1)=no -_LT_TAGVAR(inherit_rpath, $1)=no -_LT_TAGVAR(module_cmds, $1)= -_LT_TAGVAR(module_expsym_cmds, $1)= -_LT_TAGVAR(link_all_deplibs, $1)=unknown -_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds -_LT_TAGVAR(no_undefined_flag, $1)= -_LT_TAGVAR(whole_archive_flag_spec, $1)= -_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no + # Check if GNU C++ uses GNU ld as the underlying linker, since the + # archiving commands below assume that GNU ld is being used. + if test "$with_gnu_ld" = yes; then + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' + _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' -# Source file extension for C++ test sources. -ac_ext=cpp + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir' + _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' -# Object file extension for compiled C++ test sources. -objext=o -_LT_TAGVAR(objext, $1)=$objext - -# No sense in running all these tests if we already determined that -# the CXX compiler isn't working. Some variables (like enable_shared) -# are currently assumed to apply to all compilers on this platform, -# and will be corrupted by setting them based on a non-working compiler. -if test "$_lt_caught_CXX_error" != yes; then - # Code to be used in simple compile tests - lt_simple_compile_test_code="int some_variable = 0;" - - # Code to be used in simple link tests - lt_simple_link_test_code='int main(int, char *[[]]) { return(0); }' - - # ltmain only uses $CC for tagged configurations so make sure $CC is set. - _LT_TAG_COMPILER - - # save warnings/boilerplate of simple test code - _LT_COMPILER_BOILERPLATE - _LT_LINKER_BOILERPLATE - - # Allow CC to be a program name with arguments. - lt_save_CC=$CC - lt_save_LD=$LD - lt_save_GCC=$GCC - GCC=$GXX - lt_save_with_gnu_ld=$with_gnu_ld - lt_save_path_LD=$lt_cv_path_LD - if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then - lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx - else - $as_unset lt_cv_prog_gnu_ld - fi - if test -n "${lt_cv_path_LDCXX+set}"; then - lt_cv_path_LD=$lt_cv_path_LDCXX - else - $as_unset lt_cv_path_LD - fi - test -z "${LDCXX+set}" || LD=$LDCXX - CC=${CXX-"c++"} - compiler=$CC - _LT_TAGVAR(compiler, $1)=$CC - _LT_CC_BASENAME([$compiler]) + # If archive_cmds runs LD, not CC, wlarc should be empty + # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to + # investigate it a little bit more. (MM) + wlarc='${wl}' - if test -n "$compiler"; then - # We don't want -fno-exception when compiling C++ code, so set the - # no_builtin_flag separately - if test "$GXX" = yes; then - _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' + # ancient GNU ld didn't support --whole-archive et. al. + if eval "`$CC -print-prog-name=ld` --help 2>&1" | \ + grep 'no-whole-archive' > /dev/null; then + _LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' else - _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= + _LT_AC_TAGVAR(whole_archive_flag_spec, $1)= fi + else + with_gnu_ld=no + wlarc= + + # A generic and very simple default shared library creation + # command for GNU C++ for the case where it uses the native + # linker, instead of GNU ld. If possible, this setting should + # overridden to take advantage of the native linker features on + # the platform it is being used on. + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' + fi - if test "$GXX" = yes; then - # Set up default GNU C++ configuration - - LT_PATH_LD - - # Check if GNU C++ uses GNU ld as the underlying linker, since the - # archiving commands below assume that GNU ld is being used. - if test "$with_gnu_ld" = yes; then - _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' - - # If archive_cmds runs LD, not CC, wlarc should be empty - # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to - # investigate it a little bit more. (MM) - wlarc='${wl}' - - # ancient GNU ld didn't support --whole-archive et. al. - if eval "`$CC -print-prog-name=ld` --help 2>&1" | - $GREP 'no-whole-archive' > /dev/null; then - _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' - else - _LT_TAGVAR(whole_archive_flag_spec, $1)= - fi - else - with_gnu_ld=no - wlarc= - - # A generic and very simple default shared library creation - # command for GNU C++ for the case where it uses the native - # linker, instead of GNU ld. If possible, this setting should - # overridden to take advantage of the native linker features on - # the platform it is being used on. - _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' - fi + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"' - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "\-L"' +else + GXX=no + with_gnu_ld=no + wlarc= +fi +# PORTME: fill in a description of your system's C++ link characteristics +AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) +_LT_AC_TAGVAR(ld_shlibs, $1)=yes +case $host_os in + aix3*) + # FIXME: insert proper C++ library support + _LT_AC_TAGVAR(ld_shlibs, $1)=no + ;; + aix[[4-9]]*) + if test "$host_cpu" = ia64; then + # On IA64, the linker does run time linking by default, so we don't + # have to do anything special. + aix_use_runtimelinking=no + exp_sym_flag='-Bexport' + no_entry_flag="" else - GXX=no - with_gnu_ld=no - wlarc= - fi - - # PORTME: fill in a description of your system's C++ link characteristics - AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) - _LT_TAGVAR(ld_shlibs, $1)=yes - case $host_os in - aix3*) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - aix[[4-9]]*) - if test "$host_cpu" = ia64; then - # On IA64, the linker does run time linking by default, so we don't - # have to do anything special. - aix_use_runtimelinking=no - exp_sym_flag='-Bexport' - no_entry_flag="" - else - aix_use_runtimelinking=no - - # Test if we are trying to use run time linking or normal - # AIX style linking. If -brtl is somewhere in LDFLAGS, we - # need to do runtime linking. - case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*) - for ld_flag in $LDFLAGS; do - case $ld_flag in - *-brtl*) - aix_use_runtimelinking=yes - break - ;; - esac - done + aix_use_runtimelinking=no + + # Test if we are trying to use run time linking or normal + # AIX style linking. If -brtl is somewhere in LDFLAGS, we + # need to do runtime linking. + case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*) + for ld_flag in $LDFLAGS; do + case $ld_flag in + *-brtl*) + aix_use_runtimelinking=yes + break ;; - esac + esac + done + ;; + esac - exp_sym_flag='-bexport' - no_entry_flag='-bnoentry' - fi + exp_sym_flag='-bexport' + no_entry_flag='-bnoentry' + fi - # When large executables or shared objects are built, AIX ld can - # have problems creating the table of contents. If linking a library - # or program results in "error TOC overflow" add -mminimal-toc to - # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not - # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. - - _LT_TAGVAR(archive_cmds, $1)='' - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_direct_absolute, $1)=yes - _LT_TAGVAR(hardcode_libdir_separator, $1)=':' - _LT_TAGVAR(link_all_deplibs, $1)=yes - _LT_TAGVAR(file_list_spec, $1)='${wl}-f,' - - if test "$GXX" = yes; then - case $host_os in aix4.[[012]]|aix4.[[012]].*) - # We only want to do this on AIX 4.2 and lower, the check - # below for broken collect2 doesn't work under 4.3+ - collect2name=`${CC} -print-prog-name=collect2` - if test -f "$collect2name" && - strings "$collect2name" | $GREP resolve_lib_name >/dev/null - then - # We have reworked collect2 - : - else - # We have old collect2 - _LT_TAGVAR(hardcode_direct, $1)=unsupported - # It fails to find uninstalled libraries when the uninstalled - # path is not listed in the libpath. Setting hardcode_minus_L - # to unsupported forces relinking - _LT_TAGVAR(hardcode_minus_L, $1)=yes - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)= - fi - esac - shared_flag='-shared' - if test "$aix_use_runtimelinking" = yes; then - shared_flag="$shared_flag "'${wl}-G' - fi - else - # not using gcc - if test "$host_cpu" = ia64; then - # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release - # chokes on -Wl,-G. The following line is correct: - shared_flag='-G' - else - if test "$aix_use_runtimelinking" = yes; then - shared_flag='${wl}-G' - else - shared_flag='${wl}-bM:SRE' - fi - fi - fi + # When large executables or shared objects are built, AIX ld can + # have problems creating the table of contents. If linking a library + # or program results in "error TOC overflow" add -mminimal-toc to + # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not + # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-bexpall' - # It seems that -bexpall does not export symbols beginning with - # underscore (_), so it is better to generate a list of symbols to - # export. - _LT_TAGVAR(always_export_symbols, $1)=yes - if test "$aix_use_runtimelinking" = yes; then - # Warning - without using the other runtime loading flags (-brtl), - # -berok will link without error, but may produce a broken library. - _LT_TAGVAR(allow_undefined_flag, $1)='-berok' - # Determine the default libpath from the value encoded in an empty - # executable. - _LT_SYS_MODULE_PATH_AIX - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" - - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then $ECHO "X${wl}${allow_undefined_flag}" | $Xsed; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag" - else - if test "$host_cpu" = ia64; then - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib' - _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs" - _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols" - else - # Determine the default libpath from the value encoded in an - # empty executable. - _LT_SYS_MODULE_PATH_AIX - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" - # Warning - without using the other run time loading flags, - # -berok will link without error, but may produce a broken library. - _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok' - _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok' - # Exported symbols can be pulled into shared objects from archives - _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience' - _LT_TAGVAR(archive_cmds_need_lc, $1)=yes - # This is similar to how AIX traditionally builds its shared - # libraries. - _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' - fi - fi - ;; + _LT_AC_TAGVAR(archive_cmds, $1)='' + _LT_AC_TAGVAR(hardcode_direct, $1)=yes + _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':' + _LT_AC_TAGVAR(link_all_deplibs, $1)=yes - beos*) - if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then - _LT_TAGVAR(allow_undefined_flag, $1)=unsupported - # Joseph Beckenbach says some releases of gcc - # support --undefined. This deserves some investigation. FIXME - _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + if test "$GXX" = yes; then + case $host_os in aix4.[[012]]|aix4.[[012]].*) + # We only want to do this on AIX 4.2 and lower, the check + # below for broken collect2 doesn't work under 4.3+ + collect2name=`${CC} -print-prog-name=collect2` + if test -f "$collect2name" && \ + strings "$collect2name" | grep resolve_lib_name >/dev/null + then + # We have reworked collect2 + : else - _LT_TAGVAR(ld_shlibs, $1)=no + # We have old collect2 + _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported + # It fails to find uninstalled libraries when the uninstalled + # path is not listed in the libpath. Setting hardcode_minus_L + # to unsupported forces relinking + _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_AC_TAGVAR(hardcode_libdir_separator, $1)= fi ;; + esac + shared_flag='-shared' + if test "$aix_use_runtimelinking" = yes; then + shared_flag="$shared_flag "'${wl}-G' + fi + else + # not using gcc + if test "$host_cpu" = ia64; then + # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release + # chokes on -Wl,-G. The following line is correct: + shared_flag='-G' + else + if test "$aix_use_runtimelinking" = yes; then + shared_flag='${wl}-G' + else + shared_flag='${wl}-bM:SRE' + fi + fi + fi - chorus*) - case $cc_basename in - *) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - esac - ;; - - cygwin* | mingw* | pw32* | cegcc*) - # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, - # as there is no search path for DLLs. - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_TAGVAR(allow_undefined_flag, $1)=unsupported - _LT_TAGVAR(always_export_symbols, $1)=no - _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes - - if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then - _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' - # If the export-symbols file already is a .def file (1st line - # is EXPORTS), use it as is; otherwise, prepend... - _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then - cp $export_symbols $output_objdir/$soname.def; - else - echo EXPORTS > $output_objdir/$soname.def; - cat $export_symbols >> $output_objdir/$soname.def; - fi~ - $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' - else - _LT_TAGVAR(ld_shlibs, $1)=no - fi - ;; - darwin* | rhapsody*) - _LT_DARWIN_LINKER_FEATURES($1) - ;; - - dgux*) - case $cc_basename in - ec++*) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - ghcx*) - # Green Hills C++ Compiler - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - *) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - esac - ;; - - freebsd[[12]]*) - # C++ shared libraries reported to be fairly broken before - # switch to ELF - _LT_TAGVAR(ld_shlibs, $1)=no - ;; + # It seems that -bexpall does not export symbols beginning with + # underscore (_), so it is better to generate a list of symbols to export. + _LT_AC_TAGVAR(always_export_symbols, $1)=yes + if test "$aix_use_runtimelinking" = yes; then + # Warning - without using the other runtime loading flags (-brtl), + # -berok will link without error, but may produce a broken library. + _LT_AC_TAGVAR(allow_undefined_flag, $1)='-berok' + # Determine the default libpath from the value encoded in an empty executable. + _LT_AC_SYS_LIBPATH_AIX + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" + + _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag" + else + if test "$host_cpu" = ia64; then + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib' + _LT_AC_TAGVAR(allow_undefined_flag, $1)="-z nodefs" + _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols" + else + # Determine the default libpath from the value encoded in an empty executable. + _LT_AC_SYS_LIBPATH_AIX + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" + # Warning - without using the other run time loading flags, + # -berok will link without error, but may produce a broken library. + _LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok' + _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok' + # Exported symbols can be pulled into shared objects from archives + _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='$convenience' + _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes + # This is similar to how AIX traditionally builds its shared libraries. + _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' + fi + fi + ;; - freebsd-elf*) - _LT_TAGVAR(archive_cmds_need_lc, $1)=no - ;; + beos*) + if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then + _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported + # Joseph Beckenbach says some releases of gcc + # support --undefined. This deserves some investigation. FIXME + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + else + _LT_AC_TAGVAR(ld_shlibs, $1)=no + fi + ;; - freebsd* | dragonfly*) - # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF - # conventions - _LT_TAGVAR(ld_shlibs, $1)=yes - ;; + chorus*) + case $cc_basename in + *) + # FIXME: insert proper C++ library support + _LT_AC_TAGVAR(ld_shlibs, $1)=no + ;; + esac + ;; - gnu*) + cygwin* | mingw* | pw32*) + # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, + # as there is no search path for DLLs. + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported + _LT_AC_TAGVAR(always_export_symbols, $1)=no + _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes + + if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + # If the export-symbols file already is a .def file (1st line + # is EXPORTS), use it as is; otherwise, prepend... + _LT_AC_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then + cp $export_symbols $output_objdir/$soname.def; + else + echo EXPORTS > $output_objdir/$soname.def; + cat $export_symbols >> $output_objdir/$soname.def; + fi~ + $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + else + _LT_AC_TAGVAR(ld_shlibs, $1)=no + fi + ;; + darwin* | rhapsody*) + _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no + _LT_AC_TAGVAR(hardcode_direct, $1)=no + _LT_AC_TAGVAR(hardcode_automatic, $1)=yes + _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported + _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='' + _LT_AC_TAGVAR(link_all_deplibs, $1)=yes + _LT_AC_TAGVAR(allow_undefined_flag, $1)="$_lt_dar_allow_undefined" + if test "$GXX" = yes ; then + output_verbose_link_cmd='echo' + _LT_AC_TAGVAR(archive_cmds, $1)="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}" + _LT_AC_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}" + _LT_AC_TAGVAR(archive_expsym_cmds, $1)="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}" + _LT_AC_TAGVAR(module_expsym_cmds, $1)="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}" + if test "$lt_cv_apple_cc_single_mod" != "yes"; then + _LT_AC_TAGVAR(archive_cmds, $1)="\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dsymutil}" + _LT_AC_TAGVAR(archive_expsym_cmds, $1)="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dar_export_syms}${_lt_dsymutil}" + fi + else + case $cc_basename in + xlc*) + output_verbose_link_cmd='echo' + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj ${wl}-single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $xlcverstring' + _LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags' + # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds + _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj ${wl}-single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $xlcverstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' + _LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' + ;; + *) + _LT_AC_TAGVAR(ld_shlibs, $1)=no + ;; + esac + fi ;; - hpux9*) - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)=: - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, - # but as the default - # location of the library. - - case $cc_basename in - CC*) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - aCC*) - _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -b ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - # - # There doesn't appear to be a way to prevent this compiler from - # explicitly linking system object files so we need to strip them - # from the output so that they don't get included in the library - # dependencies. - output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; $ECHO "X$list" | $Xsed' - ;; - *) - if test "$GXX" = yes; then - _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared -nostdlib -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' - else - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - fi - ;; - esac - ;; + dgux*) + case $cc_basename in + ec++*) + # FIXME: insert proper C++ library support + _LT_AC_TAGVAR(ld_shlibs, $1)=no + ;; + ghcx*) + # Green Hills C++ Compiler + # FIXME: insert proper C++ library support + _LT_AC_TAGVAR(ld_shlibs, $1)=no + ;; + *) + # FIXME: insert proper C++ library support + _LT_AC_TAGVAR(ld_shlibs, $1)=no + ;; + esac + ;; + freebsd[[12]]*) + # C++ shared libraries reported to be fairly broken before switch to ELF + _LT_AC_TAGVAR(ld_shlibs, $1)=no + ;; + freebsd-elf*) + _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no + ;; + freebsd* | dragonfly*) + # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF + # conventions + _LT_AC_TAGVAR(ld_shlibs, $1)=yes + ;; + gnu*) + ;; + hpux9*) + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' + _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: + _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' + _LT_AC_TAGVAR(hardcode_direct, $1)=yes + _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, + # but as the default + # location of the library. + + case $cc_basename in + CC*) + # FIXME: insert proper C++ library support + _LT_AC_TAGVAR(ld_shlibs, $1)=no + ;; + aCC*) + _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/$soname~$CC -b ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | grep "[[-]]L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' + ;; + *) + if test "$GXX" = yes; then + _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/$soname~$CC -shared -nostdlib -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' + else + # FIXME: insert proper C++ library support + _LT_AC_TAGVAR(ld_shlibs, $1)=no + fi + ;; + esac + ;; + hpux10*|hpux11*) + if test $with_gnu_ld = no; then + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' + _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - hpux10*|hpux11*) - if test $with_gnu_ld = no; then - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)=: - - case $host_cpu in - hppa*64*|ia64*) - ;; - *) - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' - ;; - esac - fi - case $host_cpu in - hppa*64*|ia64*) - _LT_TAGVAR(hardcode_direct, $1)=no - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - *) - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_direct_absolute, $1)=yes - _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, - # but as the default - # location of the library. - ;; - esac - - case $cc_basename in - CC*) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - aCC*) - case $host_cpu in - hppa*64*) - _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - ;; - ia64*) - _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - ;; - *) - _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - ;; - esac - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - # - # There doesn't appear to be a way to prevent this compiler from - # explicitly linking system object files so we need to strip them - # from the output so that they don't get included in the library - # dependencies. - output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $GREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; $ECHO "X$list" | $Xsed' - ;; - *) - if test "$GXX" = yes; then - if test $with_gnu_ld = no; then - case $host_cpu in - hppa*64*) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - ;; - ia64*) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - ;; - *) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - ;; - esac - fi - else - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - fi - ;; - esac + case $host_cpu in + hppa*64*|ia64*) ;; + *) + _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' ;; + esac + fi + case $host_cpu in + hppa*64*|ia64*) + _LT_AC_TAGVAR(hardcode_direct, $1)=no + _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; + *) + _LT_AC_TAGVAR(hardcode_direct, $1)=yes + _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, + # but as the default + # location of the library. + ;; + esac - interix[[3-9]]*) - _LT_TAGVAR(hardcode_direct, $1)=no - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' - # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. - # Instead, shared libraries are loaded at an image base (0x10000000 by - # default) and relocated if they conflict, which is a slow very memory - # consuming and fragmenting process. To avoid this, we pick a random, - # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link - # time. Moving up from 0x10000000 also allows more sbrk(2) space. - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + case $cc_basename in + CC*) + # FIXME: insert proper C++ library support + _LT_AC_TAGVAR(ld_shlibs, $1)=no ;; - irix5* | irix6*) - case $cc_basename in - CC*) - # SGI C++ - _LT_TAGVAR(archive_cmds, $1)='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib' - - # Archives containing C++ object files must be created using - # "CC -ar", where "CC" is the IRIX C++ compiler. This is - # necessary to make sure instantiated templates are included - # in the archive. - _LT_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs' - ;; - *) - if test "$GXX" = yes; then - if test "$with_gnu_ld" = no; then - _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' - else - _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` -o $lib' - fi - fi - _LT_TAGVAR(link_all_deplibs, $1)=yes - ;; - esac - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)=: - _LT_TAGVAR(inherit_rpath, $1)=yes - ;; - - linux* | k*bsd*-gnu) - case $cc_basename in - KCC*) - # Kuck and Associates, Inc. (KAI) C++ Compiler - - # KCC will only create a shared library if the output file - # ends with ".so" (or ".sl" for HP-UX), so rename the library - # to its proper name (with version) after linking. - _LT_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib ${wl}-retain-symbols-file,$export_symbols; mv \$templib $lib' - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - # - # There doesn't appear to be a way to prevent this compiler from - # explicitly linking system object files so we need to strip them - # from the output so that they don't get included in the library - # dependencies. - output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | $GREP "ld"`; rm -f libconftest$shared_ext; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; $ECHO "X$list" | $Xsed' - - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' - - # Archives containing C++ object files must be created using - # "CC -Bstatic", where "CC" is the KAI C++ compiler. - _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' - ;; - icpc* | ecpc* ) - # Intel C++ - with_gnu_ld=yes - # version 8.0 and above of icpc choke on multiply defined symbols - # if we add $predep_objects and $postdep_objects, however 7.1 and - # earlier do not add the objects themselves. - case `$CC -V 2>&1` in - *"Version 7."*) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - ;; - *) # Version 8.0 or newer - tmp_idyn= - case $host_cpu in - ia64*) tmp_idyn=' -i_dynamic';; - esac - _LT_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - ;; - esac - _LT_TAGVAR(archive_cmds_need_lc, $1)=no - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' - _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive' - ;; - pgCC* | pgcpp*) - # Portland Group C++ compiler - case `$CC -V` in - *pgCC\ [[1-5]]* | *pgcpp\ [[1-5]]*) - _LT_TAGVAR(prelink_cmds, $1)='tpldir=Template.dir~ - rm -rf $tpldir~ - $CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~ - compile_command="$compile_command `find $tpldir -name \*.o | $NL2SP`"' - _LT_TAGVAR(old_archive_cmds, $1)='tpldir=Template.dir~ - rm -rf $tpldir~ - $CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~ - $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | $NL2SP`~ - $RANLIB $oldlib' - _LT_TAGVAR(archive_cmds, $1)='tpldir=Template.dir~ - rm -rf $tpldir~ - $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ - $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='tpldir=Template.dir~ - rm -rf $tpldir~ - $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ - $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib' + aCC*) + case $host_cpu in + hppa*64*) + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + ia64*) + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + *) + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + esac + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | grep "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' + ;; + *) + if test "$GXX" = yes; then + if test $with_gnu_ld = no; then + case $host_cpu in + hppa*64*) + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; - *) # Version 6 will use weak symbols - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib' + ia64*) + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; - esac - - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' - _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive' - ;; - cxx*) - # Compaq C++ - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib ${wl}-retain-symbols-file $wl$export_symbols' - - runpath_var=LD_RUN_PATH - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)=: - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - # - # There doesn't appear to be a way to prevent this compiler from - # explicitly linking system object files so we need to strip them - # from the output so that they don't get included in the library - # dependencies. - output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld"`; templist=`$ECHO "X$templist" | $Xsed -e "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; $ECHO "X$list" | $Xsed' - ;; - xl*) - # IBM XL 8.0 on PPC, with GNU ld - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' - _LT_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - if test "x$supports_anon_versioning" = xyes; then - _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ - cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ - echo "local: *; };" >> $output_objdir/$libname.ver~ - $CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' - fi - ;; - *) - case `$CC -V 2>&1 | sed 5q` in - *Sun\ C*) - # Sun C++ 5.9 - _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs' - _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file ${wl}$export_symbols' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive' - _LT_TAGVAR(compiler_needs_object, $1)=yes - - # Not sure whether something based on - # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 - # would be better. - output_verbose_link_cmd='echo' - - # Archives containing C++ object files must be created using - # "CC -xar", where "CC" is the Sun C++ compiler. This is - # necessary to make sure instantiated templates are included - # in the archive. - _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs' + *) + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; esac - ;; - esac + fi + else + # FIXME: insert proper C++ library support + _LT_AC_TAGVAR(ld_shlibs, $1)=no + fi ;; - - lynxos*) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no + esac + ;; + interix[[3-9]]*) + _LT_AC_TAGVAR(hardcode_direct, $1)=no + _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' + _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' + # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. + # Instead, shared libraries are loaded at an image base (0x10000000 by + # default) and relocated if they conflict, which is a slow very memory + # consuming and fragmenting process. To avoid this, we pick a random, + # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link + # time. Moving up from 0x10000000 also allows more sbrk(2) space. + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + ;; + irix5* | irix6*) + case $cc_basename in + CC*) + # SGI C++ + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' + + # Archives containing C++ object files must be created using + # "CC -ar", where "CC" is the IRIX C++ compiler. This is + # necessary to make sure instantiated templates are included + # in the archive. + _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs' + ;; + *) + if test "$GXX" = yes; then + if test "$with_gnu_ld" = no; then + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + else + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` -o $lib' + fi + fi + _LT_AC_TAGVAR(link_all_deplibs, $1)=yes + ;; + esac + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' + _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: + ;; + linux* | k*bsd*-gnu) + case $cc_basename in + KCC*) + # Kuck and Associates, Inc. (KAI) C++ Compiler + + # KCC will only create a shared library if the output file + # ends with ".so" (or ".sl" for HP-UX), so rename the library + # to its proper name (with version) after linking. + _LT_AC_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' + _LT_AC_TAGVAR(archive_expsym_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib ${wl}-retain-symbols-file,$export_symbols; mv \$templib $lib' + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | grep "ld"`; rm -f libconftest$shared_ext; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' + + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath,$libdir' + _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' + + # Archives containing C++ object files must be created using + # "CC -Bstatic", where "CC" is the KAI C++ compiler. + _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' + ;; + icpc*) + # Intel C++ + with_gnu_ld=yes + # version 8.0 and above of icpc choke on multiply defined symbols + # if we add $predep_objects and $postdep_objects, however 7.1 and + # earlier do not add the objects themselves. + case `$CC -V 2>&1` in + *"Version 7."*) + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' + _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + ;; + *) # Version 8.0 or newer + tmp_idyn= + case $host_cpu in + ia64*) tmp_idyn=' -i_dynamic';; + esac + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + ;; + esac + _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' + _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' + _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive' ;; + pgCC* | pgcpp*) + # Portland Group C++ compiler + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib' + _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib' + + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir' + _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' + _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' + ;; + cxx*) + # Compaq C++ + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' + _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib ${wl}-retain-symbols-file $wl$export_symbols' - m88k*) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no + runpath_var=LD_RUN_PATH + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' + _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld"`; templist=`echo $templist | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' ;; - - mvs*) - case $cc_basename in - cxx*) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - *) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; + *) + case `$CC -V 2>&1 | sed 5q` in + *Sun\ C*) + # Sun C++ 5.9 + _LT_AC_TAGVAR(no_undefined_flag, $1)=' -zdefs' + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file ${wl}$export_symbols' + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' + _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' + + # Not sure whether something based on + # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 + # would be better. + output_verbose_link_cmd='echo' + + # Archives containing C++ object files must be created using + # "CC -xar", where "CC" is the Sun C++ compiler. This is + # necessary to make sure instantiated templates are included + # in the archive. + _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs' + ;; esac ;; - - netbsd*) - if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then - _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags' - wlarc= - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - fi - # Workaround some broken pre-1.5 toolchains - output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"' + esac + ;; + lynxos*) + # FIXME: insert proper C++ library support + _LT_AC_TAGVAR(ld_shlibs, $1)=no + ;; + m88k*) + # FIXME: insert proper C++ library support + _LT_AC_TAGVAR(ld_shlibs, $1)=no + ;; + mvs*) + case $cc_basename in + cxx*) + # FIXME: insert proper C++ library support + _LT_AC_TAGVAR(ld_shlibs, $1)=no ;; - - *nto* | *qnx*) - _LT_TAGVAR(ld_shlibs, $1)=yes + *) + # FIXME: insert proper C++ library support + _LT_AC_TAGVAR(ld_shlibs, $1)=no ;; + esac + ;; + netbsd*) + if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then + _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags' + wlarc= + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' + _LT_AC_TAGVAR(hardcode_direct, $1)=yes + _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no + fi + # Workaround some broken pre-1.5 toolchains + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"' + ;; + openbsd2*) + # C++ shared libraries are fairly broken + _LT_AC_TAGVAR(ld_shlibs, $1)=no + ;; + openbsd*) + if test -f /usr/libexec/ld.so; then + _LT_AC_TAGVAR(hardcode_direct, $1)=yes + _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' + if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then + _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file,$export_symbols -o $lib' + _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' + _LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' + fi + output_verbose_link_cmd='echo' + else + _LT_AC_TAGVAR(ld_shlibs, $1)=no + fi + ;; + osf3*) + case $cc_basename in + KCC*) + # Kuck and Associates, Inc. (KAI) C++ Compiler + + # KCC will only create a shared library if the output file + # ends with ".so" (or ".sl" for HP-UX), so rename the library + # to its proper name (with version) after linking. + _LT_AC_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' + + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' + _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - openbsd2*) - # C++ shared libraries are fairly broken - _LT_TAGVAR(ld_shlibs, $1)=no + # Archives containing C++ object files must be created using + # "CC -Bstatic", where "CC" is the KAI C++ compiler. + _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' + + ;; + RCC*) + # Rational C++ 2.4.1 + # FIXME: insert proper C++ library support + _LT_AC_TAGVAR(ld_shlibs, $1)=no ;; + cxx*) + _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $soname `test -n "$verstring" && echo ${wl}-set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' + + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' + _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld" | grep -v "ld:"`; templist=`echo $templist | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' + ;; + *) + if test "$GXX" = yes && test "$with_gnu_ld" = no; then + _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' + _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"' - openbsd*) - if test -f /usr/libexec/ld.so; then - _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - _LT_TAGVAR(hardcode_direct_absolute, $1)=yes - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file,$export_symbols -o $lib' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' - _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' - fi - output_verbose_link_cmd=echo else - _LT_TAGVAR(ld_shlibs, $1)=no + # FIXME: insert proper C++ library support + _LT_AC_TAGVAR(ld_shlibs, $1)=no fi ;; + esac + ;; + osf4* | osf5*) + case $cc_basename in + KCC*) + # Kuck and Associates, Inc. (KAI) C++ Compiler + + # KCC will only create a shared library if the output file + # ends with ".so" (or ".sl" for HP-UX), so rename the library + # to its proper name (with version) after linking. + _LT_AC_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' + + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' + _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: + + # Archives containing C++ object files must be created using + # the KAI C++ compiler. + _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -o $oldlib $oldobjs' + ;; + RCC*) + # Rational C++ 2.4.1 + # FIXME: insert proper C++ library support + _LT_AC_TAGVAR(ld_shlibs, $1)=no + ;; + cxx*) + _LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' + _LT_AC_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~ + echo "-hidden">> $lib.exp~ + $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname -Wl,-input -Wl,$lib.exp `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib~ + $rm $lib.exp' + + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' + _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld" | grep -v "ld:"`; templist=`echo $templist | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' + ;; + *) + if test "$GXX" = yes && test "$with_gnu_ld" = no; then + _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' - osf3* | osf4* | osf5*) - case $cc_basename in - KCC*) - # Kuck and Associates, Inc. (KAI) C++ Compiler - - # KCC will only create a shared library if the output file - # ends with ".so" (or ".sl" for HP-UX), so rename the library - # to its proper name (with version) after linking. - _LT_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo "$lib" | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' - - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)=: - - # Archives containing C++ object files must be created using - # the KAI C++ compiler. - case $host in - osf3*) _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' ;; - *) _LT_TAGVAR(old_archive_cmds, $1)='$CC -o $oldlib $oldobjs' ;; - esac - ;; - RCC*) - # Rational C++ 2.4.1 - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - cxx*) - case $host in - osf3*) - _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' - _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $soname `test -n "$verstring" && $ECHO "X${wl}-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - ;; - *) - _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' - _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~ - echo "-hidden">> $lib.exp~ - $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname ${wl}-input ${wl}$lib.exp `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib~ - $RM $lib.exp' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' - ;; - esac + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' + _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - _LT_TAGVAR(hardcode_libdir_separator, $1)=: + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"' - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - # - # There doesn't appear to be a way to prevent this compiler from - # explicitly linking system object files so we need to strip them - # from the output so that they don't get included in the library - # dependencies. - output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld" | $GREP -v "ld:"`; templist=`$ECHO "X$templist" | $Xsed -e "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; $ECHO "X$list" | $Xsed' - ;; + else + # FIXME: insert proper C++ library support + _LT_AC_TAGVAR(ld_shlibs, $1)=no + fi + ;; + esac + ;; + psos*) + # FIXME: insert proper C++ library support + _LT_AC_TAGVAR(ld_shlibs, $1)=no + ;; + sunos4*) + case $cc_basename in + CC*) + # Sun C++ 4.x + # FIXME: insert proper C++ library support + _LT_AC_TAGVAR(ld_shlibs, $1)=no + ;; + lcc*) + # Lucid + # FIXME: insert proper C++ library support + _LT_AC_TAGVAR(ld_shlibs, $1)=no + ;; + *) + # FIXME: insert proper C++ library support + _LT_AC_TAGVAR(ld_shlibs, $1)=no + ;; + esac + ;; + solaris*) + case $cc_basename in + CC*) + # Sun C++ 4.2, 5.x and Centerline C++ + _LT_AC_TAGVAR(archive_cmds_need_lc,$1)=yes + _LT_AC_TAGVAR(no_undefined_flag, $1)=' -zdefs' + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ + $CC -G${allow_undefined_flag} ${wl}-M ${wl}$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp' + + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' + _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no + case $host_os in + solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; *) - if test "$GXX" = yes && test "$with_gnu_ld" = no; then - _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' - case $host in - osf3*) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' - ;; - *) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' - ;; - esac - - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)=: - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "\-L"' - - else - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - fi - ;; - esac - ;; - - psos*) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - - sunos4*) - case $cc_basename in - CC*) - # Sun C++ 4.x - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - lcc*) - # Lucid - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - *) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no + # The compiler driver will combine and reorder linker options, + # but understands `-z linker_flag'. + # Supported since Solaris 2.6 (maybe 2.5.1?) + _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' ;; - esac - ;; - - solaris*) - case $cc_basename in - CC*) - # Sun C++ 4.2, 5.x and Centerline C++ - _LT_TAGVAR(archive_cmds_need_lc,$1)=yes - _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs' - _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $CC -G${allow_undefined_flag} ${wl}-M ${wl}$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' - - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - case $host_os in - solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; - *) - # The compiler driver will combine and reorder linker options, - # but understands `-z linker_flag'. - # Supported since Solaris 2.6 (maybe 2.5.1?) - _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' - ;; - esac - _LT_TAGVAR(link_all_deplibs, $1)=yes - - output_verbose_link_cmd='echo' + esac + _LT_AC_TAGVAR(link_all_deplibs, $1)=yes - # Archives containing C++ object files must be created using - # "CC -xar", where "CC" is the Sun C++ compiler. This is - # necessary to make sure instantiated templates are included - # in the archive. - _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs' - ;; - gcx*) - # Green Hills C++ Compiler - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' + output_verbose_link_cmd='echo' - # The C++ compiler must be used to create the archive. - _LT_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs' - ;; - *) - # GNU C++ compiler with Solaris linker - if test "$GXX" = yes && test "$with_gnu_ld" = no; then - _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-z ${wl}defs' - if $CC --version | $GREP -v '^2\.7' > /dev/null; then - _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $CC -shared -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "\-L"' - else - # g++ 2.7 appears to require `-G' NOT `-shared' on this - # platform. - _LT_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP "\-L"' - fi - - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $wl$libdir' - case $host_os in - solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; - *) - _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' - ;; - esac - fi - ;; - esac - ;; + # Archives containing C++ object files must be created using + # "CC -xar", where "CC" is the Sun C++ compiler. This is + # necessary to make sure instantiated templates are included + # in the archive. + _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs' + ;; + gcx*) + # Green Hills C++ Compiler + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' - sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*) - _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' - _LT_TAGVAR(archive_cmds_need_lc, $1)=no - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - runpath_var='LD_RUN_PATH' + # The C++ compiler must be used to create the archive. + _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs' + ;; + *) + # GNU C++ compiler with Solaris linker + if test "$GXX" = yes && test "$with_gnu_ld" = no; then + _LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-z ${wl}defs' + if $CC --version | grep -v '^2\.7' > /dev/null; then + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' + _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ + $CC -shared -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp' - case $cc_basename in - CC*) - _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - ;; - *) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - ;; - esac - ;; + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + output_verbose_link_cmd="$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep \"\-L\"" + else + # g++ 2.7 appears to require `-G' NOT `-shared' on this + # platform. + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' + _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ + $CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp' - sysv5* | sco3.2v5* | sco5v6*) - # Note: We can NOT use -z defs as we might desire, because we do not - # link with -lc, and that would cause any symbols used from libc to - # always be unresolved, which means just about no library would - # ever link correctly. If we're not using GNU ld we use -z text - # though, which does catch some bad symbols but isn't as heavy-handed - # as -z defs. - _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' - _LT_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs' - _LT_TAGVAR(archive_cmds_need_lc, $1)=no - _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R,$libdir' - _LT_TAGVAR(hardcode_libdir_separator, $1)=':' - _LT_TAGVAR(link_all_deplibs, $1)=yes - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport' - runpath_var='LD_RUN_PATH' + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + output_verbose_link_cmd="$CC -G $CFLAGS -v conftest.$objext 2>&1 | grep \"\-L\"" + fi - case $cc_basename in - CC*) - _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - ;; + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $wl$libdir' + case $host_os in + solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; *) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - ;; - esac - ;; - - tandem*) - case $cc_basename in - NCC*) - # NonStop-UX NCC 3.20 - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no + _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' ;; - *) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - esac - ;; - - vxworks*) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - + esac + fi + ;; + esac + ;; + sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*) + _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' + _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no + _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no + runpath_var='LD_RUN_PATH' + + case $cc_basename in + CC*) + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; *) - # FIXME: insert proper C++ library support - _LT_TAGVAR(ld_shlibs, $1)=no - ;; + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; esac + ;; + sysv5* | sco3.2v5* | sco5v6*) + # Note: We can NOT use -z defs as we might desire, because we do not + # link with -lc, and that would cause any symbols used from libc to + # always be unresolved, which means just about no library would + # ever link correctly. If we're not using GNU ld we use -z text + # though, which does catch some bad symbols but isn't as heavy-handed + # as -z defs. + # For security reasons, it is highly recommended that you always + # use absolute paths for naming shared libraries, and exclude the + # DT_RUNPATH tag from executables and libraries. But doing so + # requires that you compile everything twice, which is a pain. + # So that behaviour is only enabled if SCOABSPATH is set to a + # non-empty value in the environment. Most likely only useful for + # creating official distributions of packages. + # This is a hack until libtool officially supports absolute path + # names for shared libraries. + _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' + _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs' + _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no + _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='`test -z "$SCOABSPATH" && echo ${wl}-R,$libdir`' + _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':' + _LT_AC_TAGVAR(link_all_deplibs, $1)=yes + _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport' + runpath_var='LD_RUN_PATH' + + case $cc_basename in + CC*) + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + *) + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + esac + ;; + tandem*) + case $cc_basename in + NCC*) + # NonStop-UX NCC 3.20 + # FIXME: insert proper C++ library support + _LT_AC_TAGVAR(ld_shlibs, $1)=no + ;; + *) + # FIXME: insert proper C++ library support + _LT_AC_TAGVAR(ld_shlibs, $1)=no + ;; + esac + ;; + vxworks*) + # FIXME: insert proper C++ library support + _LT_AC_TAGVAR(ld_shlibs, $1)=no + ;; + *) + # FIXME: insert proper C++ library support + _LT_AC_TAGVAR(ld_shlibs, $1)=no + ;; +esac +AC_MSG_RESULT([$_LT_AC_TAGVAR(ld_shlibs, $1)]) +test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no - AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)]) - test "$_LT_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no - - _LT_TAGVAR(GCC, $1)="$GXX" - _LT_TAGVAR(LD, $1)="$LD" - - ## CAVEAT EMPTOR: - ## There is no encapsulation within the following macros, do not change - ## the running order or otherwise move them around unless you know exactly - ## what you are doing... - _LT_SYS_HIDDEN_LIBDEPS($1) - _LT_COMPILER_PIC($1) - _LT_COMPILER_C_O($1) - _LT_COMPILER_FILE_LOCKS($1) - _LT_LINKER_SHLIBS($1) - _LT_SYS_DYNAMIC_LINKER($1) - _LT_LINKER_HARDCODE_LIBPATH($1) - - _LT_CONFIG($1) - fi # test -n "$compiler" - - CC=$lt_save_CC - LDCXX=$LD - LD=$lt_save_LD - GCC=$lt_save_GCC - with_gnu_ld=$lt_save_with_gnu_ld - lt_cv_path_LDCXX=$lt_cv_path_LD - lt_cv_path_LD=$lt_save_path_LD - lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld - lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld -fi # test "$_lt_caught_CXX_error" != yes +_LT_AC_TAGVAR(GCC, $1)="$GXX" +_LT_AC_TAGVAR(LD, $1)="$LD" -AC_LANG_POP -])# _LT_LANG_CXX_CONFIG +AC_LIBTOOL_POSTDEP_PREDEP($1) +AC_LIBTOOL_PROG_COMPILER_PIC($1) +AC_LIBTOOL_PROG_CC_C_O($1) +AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1) +AC_LIBTOOL_PROG_LD_SHLIBS($1) +AC_LIBTOOL_SYS_DYNAMIC_LINKER($1) +AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1) +AC_LIBTOOL_CONFIG($1) -# _LT_SYS_HIDDEN_LIBDEPS([TAGNAME]) -# --------------------------------- +AC_LANG_POP +CC=$lt_save_CC +LDCXX=$LD +LD=$lt_save_LD +GCC=$lt_save_GCC +with_gnu_ldcxx=$with_gnu_ld +with_gnu_ld=$lt_save_with_gnu_ld +lt_cv_path_LDCXX=$lt_cv_path_LD +lt_cv_path_LD=$lt_save_path_LD +lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld +lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld +])# AC_LIBTOOL_LANG_CXX_CONFIG + +# AC_LIBTOOL_POSTDEP_PREDEP([TAGNAME]) +# ------------------------------------ # Figure out "hidden" library dependencies from verbose # compiler output when linking a shared library. # Parse the compiler output and extract the necessary # objects, libraries and library flags. -m4_defun([_LT_SYS_HIDDEN_LIBDEPS], -[m4_require([_LT_FILEUTILS_DEFAULTS])dnl -# Dependencies to place before and after the object being linked: -_LT_TAGVAR(predep_objects, $1)= -_LT_TAGVAR(postdep_objects, $1)= -_LT_TAGVAR(predeps, $1)= -_LT_TAGVAR(postdeps, $1)= -_LT_TAGVAR(compiler_lib_search_path, $1)= - +AC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP], +[AC_REQUIRE([LT_AC_PROG_SED])dnl dnl we can't use the lt_simple_compile_test_code here, dnl because it contains code intended for an executable, dnl not a library. It's possible we should let each dnl tag define a new lt_????_link_test_code variable, dnl but it's only used here... -m4_if([$1], [], [cat > conftest.$ac_ext <<_LT_EOF +ifelse([$1],[],[cat > conftest.$ac_ext < conftest.$ac_ext <<_LT_EOF +EOF +],[$1],[CXX],[cat > conftest.$ac_ext < conftest.$ac_ext <<_LT_EOF +EOF +],[$1],[F77],[cat > conftest.$ac_ext < conftest.$ac_ext <<_LT_EOF - subroutine foo - implicit none - integer a - a=0 - return - end -_LT_EOF -], [$1], [GCJ], [cat > conftest.$ac_ext <<_LT_EOF +EOF +],[$1],[GCJ],[cat > conftest.$ac_ext <&1 | sed 5q` in *Sun\ C*) # Sun C++ 5.9 - + # # The more standards-conforming stlport4 library is # incompatible with the Cstd library. Avoid specifying # it if it's in CXXFLAGS. Ignore libCrun as @@ -6517,9 +5760,8 @@ linux*) solaris_use_stlport4=yes ;; esac - if test "$solaris_use_stlport4" != yes; then - _LT_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun' + _LT_AC_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun' fi ;; esac @@ -6542,348 +5784,69 @@ solaris*) # Sun compiler versions before 5.6, else PIC objects from an old # archive will be linked into the output, leading to subtle bugs. if test "$solaris_use_stlport4" != yes; then - _LT_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun' + _LT_AC_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun' fi ;; esac ;; esac ]) - -case " $_LT_TAGVAR(postdeps, $1) " in -*" -lc "*) _LT_TAGVAR(archive_cmds_need_lc, $1)=no ;; +case " $_LT_AC_TAGVAR(postdeps, $1) " in +*" -lc "*) _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no ;; esac - _LT_TAGVAR(compiler_lib_search_dirs, $1)= -if test -n "${_LT_TAGVAR(compiler_lib_search_path, $1)}"; then - _LT_TAGVAR(compiler_lib_search_dirs, $1)=`echo " ${_LT_TAGVAR(compiler_lib_search_path, $1)}" | ${SED} -e 's! -L! !g' -e 's!^ !!'` -fi -_LT_TAGDECL([], [compiler_lib_search_dirs], [1], - [The directories searched by this compiler when creating a shared library]) -_LT_TAGDECL([], [predep_objects], [1], - [Dependencies to place before and after the objects being linked to - create a shared library]) -_LT_TAGDECL([], [postdep_objects], [1]) -_LT_TAGDECL([], [predeps], [1]) -_LT_TAGDECL([], [postdeps], [1]) -_LT_TAGDECL([], [compiler_lib_search_path], [1], - [The library search path used internally by the compiler when linking - a shared library]) -])# _LT_SYS_HIDDEN_LIBDEPS - - -# _LT_PROG_F77 -# ------------ -# Since AC_PROG_F77 is broken, in that it returns the empty string -# if there is no fortran compiler, we have our own version here. -m4_defun([_LT_PROG_F77], -[ -pushdef([AC_MSG_ERROR], [_lt_disable_F77=yes]) -AC_PROG_F77 -if test -z "$F77" || test "X$F77" = "Xno"; then - _lt_disable_F77=yes -fi -popdef([AC_MSG_ERROR]) -])# _LT_PROG_F77 - -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([_LT_PROG_F77], []) +])# AC_LIBTOOL_POSTDEP_PREDEP - -# _LT_LANG_F77_CONFIG([TAG]) +# AC_LIBTOOL_LANG_F77_CONFIG # -------------------------- -# Ensure that the configuration variables for a Fortran 77 compiler are -# suitably defined. These variables are subsequently used by _LT_CONFIG -# to write the compiler configuration to `libtool'. -m4_defun([_LT_LANG_F77_CONFIG], -[AC_REQUIRE([_LT_PROG_F77])dnl +# Ensure that the configuration vars for the C compiler are +# suitably defined. Those variables are subsequently used by +# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'. +AC_DEFUN([AC_LIBTOOL_LANG_F77_CONFIG], [_LT_AC_LANG_F77_CONFIG(F77)]) +AC_DEFUN([_LT_AC_LANG_F77_CONFIG], +[AC_REQUIRE([AC_PROG_F77]) AC_LANG_PUSH(Fortran 77) -_LT_TAGVAR(archive_cmds_need_lc, $1)=no -_LT_TAGVAR(allow_undefined_flag, $1)= -_LT_TAGVAR(always_export_symbols, $1)=no -_LT_TAGVAR(archive_expsym_cmds, $1)= -_LT_TAGVAR(export_dynamic_flag_spec, $1)= -_LT_TAGVAR(hardcode_direct, $1)=no -_LT_TAGVAR(hardcode_direct_absolute, $1)=no -_LT_TAGVAR(hardcode_libdir_flag_spec, $1)= -_LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)= -_LT_TAGVAR(hardcode_libdir_separator, $1)= -_LT_TAGVAR(hardcode_minus_L, $1)=no -_LT_TAGVAR(hardcode_automatic, $1)=no -_LT_TAGVAR(inherit_rpath, $1)=no -_LT_TAGVAR(module_cmds, $1)= -_LT_TAGVAR(module_expsym_cmds, $1)= -_LT_TAGVAR(link_all_deplibs, $1)=unknown -_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds -_LT_TAGVAR(no_undefined_flag, $1)= -_LT_TAGVAR(whole_archive_flag_spec, $1)= -_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no - -# Source file extension for f77 test sources. -ac_ext=f - -# Object file extension for compiled f77 test sources. -objext=o -_LT_TAGVAR(objext, $1)=$objext - -# No sense in running all these tests if we already determined that -# the F77 compiler isn't working. Some variables (like enable_shared) -# are currently assumed to apply to all compilers on this platform, -# and will be corrupted by setting them based on a non-working compiler. -if test "$_lt_disable_F77" != yes; then - # Code to be used in simple compile tests - lt_simple_compile_test_code="\ - subroutine t - return - end -" - - # Code to be used in simple link tests - lt_simple_link_test_code="\ - program t - end -" - - # ltmain only uses $CC for tagged configurations so make sure $CC is set. - _LT_TAG_COMPILER - - # save warnings/boilerplate of simple test code - _LT_COMPILER_BOILERPLATE - _LT_LINKER_BOILERPLATE - - # Allow CC to be a program name with arguments. - lt_save_CC="$CC" - lt_save_GCC=$GCC - CC=${F77-"f77"} - compiler=$CC - _LT_TAGVAR(compiler, $1)=$CC - _LT_CC_BASENAME([$compiler]) - GCC=$G77 - if test -n "$compiler"; then - AC_MSG_CHECKING([if libtool supports shared libraries]) - AC_MSG_RESULT([$can_build_shared]) - - AC_MSG_CHECKING([whether to build shared libraries]) - test "$can_build_shared" = "no" && enable_shared=no - - # On AIX, shared libraries and static libraries use the same namespace, and - # are all built from PIC. - case $host_os in - aix3*) - test "$enable_shared" = yes && enable_static=no - if test -n "$RANLIB"; then - archive_cmds="$archive_cmds~\$RANLIB \$lib" - postinstall_cmds='$RANLIB $lib' - fi - ;; - aix[[4-9]]*) - if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then - test "$enable_shared" = yes && enable_static=no - fi - ;; - esac - AC_MSG_RESULT([$enable_shared]) - - AC_MSG_CHECKING([whether to build static libraries]) - # Make sure either enable_shared or enable_static is yes. - test "$enable_shared" = yes || enable_static=yes - AC_MSG_RESULT([$enable_static]) - - _LT_TAGVAR(GCC, $1)="$G77" - _LT_TAGVAR(LD, $1)="$LD" - - ## CAVEAT EMPTOR: - ## There is no encapsulation within the following macros, do not change - ## the running order or otherwise move them around unless you know exactly - ## what you are doing... - _LT_COMPILER_PIC($1) - _LT_COMPILER_C_O($1) - _LT_COMPILER_FILE_LOCKS($1) - _LT_LINKER_SHLIBS($1) - _LT_SYS_DYNAMIC_LINKER($1) - _LT_LINKER_HARDCODE_LIBPATH($1) - - _LT_CONFIG($1) - fi # test -n "$compiler" - - GCC=$lt_save_GCC - CC="$lt_save_CC" -fi # test "$_lt_disable_F77" != yes - -AC_LANG_POP -])# _LT_LANG_F77_CONFIG - - -# _LT_PROG_FC -# ----------- -# Since AC_PROG_FC is broken, in that it returns the empty string -# if there is no fortran compiler, we have our own version here. -m4_defun([_LT_PROG_FC], -[ -pushdef([AC_MSG_ERROR], [_lt_disable_FC=yes]) -AC_PROG_FC -if test -z "$FC" || test "X$FC" = "Xno"; then - _lt_disable_FC=yes -fi -popdef([AC_MSG_ERROR]) -])# _LT_PROG_FC - -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([_LT_PROG_FC], []) - - -# _LT_LANG_FC_CONFIG([TAG]) -# ------------------------- -# Ensure that the configuration variables for a Fortran compiler are -# suitably defined. These variables are subsequently used by _LT_CONFIG -# to write the compiler configuration to `libtool'. -m4_defun([_LT_LANG_FC_CONFIG], -[AC_REQUIRE([_LT_PROG_FC])dnl -AC_LANG_PUSH(Fortran) - -_LT_TAGVAR(archive_cmds_need_lc, $1)=no -_LT_TAGVAR(allow_undefined_flag, $1)= -_LT_TAGVAR(always_export_symbols, $1)=no -_LT_TAGVAR(archive_expsym_cmds, $1)= -_LT_TAGVAR(export_dynamic_flag_spec, $1)= -_LT_TAGVAR(hardcode_direct, $1)=no -_LT_TAGVAR(hardcode_direct_absolute, $1)=no -_LT_TAGVAR(hardcode_libdir_flag_spec, $1)= -_LT_TAGVAR(hardcode_libdir_flag_spec_ld, $1)= -_LT_TAGVAR(hardcode_libdir_separator, $1)= -_LT_TAGVAR(hardcode_minus_L, $1)=no -_LT_TAGVAR(hardcode_automatic, $1)=no -_LT_TAGVAR(inherit_rpath, $1)=no -_LT_TAGVAR(module_cmds, $1)= -_LT_TAGVAR(module_expsym_cmds, $1)= -_LT_TAGVAR(link_all_deplibs, $1)=unknown -_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds -_LT_TAGVAR(no_undefined_flag, $1)= -_LT_TAGVAR(whole_archive_flag_spec, $1)= -_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no - -# Source file extension for fc test sources. -ac_ext=${ac_fc_srcext-f} - -# Object file extension for compiled fc test sources. -objext=o -_LT_TAGVAR(objext, $1)=$objext - -# No sense in running all these tests if we already determined that -# the FC compiler isn't working. Some variables (like enable_shared) -# are currently assumed to apply to all compilers on this platform, -# and will be corrupted by setting them based on a non-working compiler. -if test "$_lt_disable_FC" != yes; then - # Code to be used in simple compile tests - lt_simple_compile_test_code="\ - subroutine t - return - end -" - - # Code to be used in simple link tests - lt_simple_link_test_code="\ - program t - end -" - - # ltmain only uses $CC for tagged configurations so make sure $CC is set. - _LT_TAG_COMPILER - - # save warnings/boilerplate of simple test code - _LT_COMPILER_BOILERPLATE - _LT_LINKER_BOILERPLATE - - # Allow CC to be a program name with arguments. - lt_save_CC="$CC" - lt_save_GCC=$GCC - CC=${FC-"f95"} - compiler=$CC - GCC=$ac_cv_fc_compiler_gnu - - _LT_TAGVAR(compiler, $1)=$CC - _LT_CC_BASENAME([$compiler]) - - if test -n "$compiler"; then - AC_MSG_CHECKING([if libtool supports shared libraries]) - AC_MSG_RESULT([$can_build_shared]) - - AC_MSG_CHECKING([whether to build shared libraries]) - test "$can_build_shared" = "no" && enable_shared=no - - # On AIX, shared libraries and static libraries use the same namespace, and - # are all built from PIC. - case $host_os in - aix3*) - test "$enable_shared" = yes && enable_static=no - if test -n "$RANLIB"; then - archive_cmds="$archive_cmds~\$RANLIB \$lib" - postinstall_cmds='$RANLIB $lib' - fi - ;; - aix[[4-9]]*) - if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then - test "$enable_shared" = yes && enable_static=no - fi - ;; - esac - AC_MSG_RESULT([$enable_shared]) - - AC_MSG_CHECKING([whether to build static libraries]) - # Make sure either enable_shared or enable_static is yes. - test "$enable_shared" = yes || enable_static=yes - AC_MSG_RESULT([$enable_static]) - - _LT_TAGVAR(GCC, $1)="$ac_cv_fc_compiler_gnu" - _LT_TAGVAR(LD, $1)="$LD" - - ## CAVEAT EMPTOR: - ## There is no encapsulation within the following macros, do not change - ## the running order or otherwise move them around unless you know exactly - ## what you are doing... - _LT_SYS_HIDDEN_LIBDEPS($1) - _LT_COMPILER_PIC($1) - _LT_COMPILER_C_O($1) - _LT_COMPILER_FILE_LOCKS($1) - _LT_LINKER_SHLIBS($1) - _LT_SYS_DYNAMIC_LINKER($1) - _LT_LINKER_HARDCODE_LIBPATH($1) - - _LT_CONFIG($1) - fi # test -n "$compiler" - - GCC=$lt_save_GCC - CC="$lt_save_CC" -fi # test "$_lt_disable_FC" != yes - -AC_LANG_POP -])# _LT_LANG_FC_CONFIG - - -# _LT_LANG_GCJ_CONFIG([TAG]) -# -------------------------- -# Ensure that the configuration variables for the GNU Java Compiler compiler -# are suitably defined. These variables are subsequently used by _LT_CONFIG -# to write the compiler configuration to `libtool'. -m4_defun([_LT_LANG_GCJ_CONFIG], -[AC_REQUIRE([LT_PROG_GCJ])dnl -AC_LANG_SAVE +_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no +_LT_AC_TAGVAR(allow_undefined_flag, $1)= +_LT_AC_TAGVAR(always_export_symbols, $1)=no +_LT_AC_TAGVAR(archive_expsym_cmds, $1)= +_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)= +_LT_AC_TAGVAR(hardcode_direct, $1)=no +_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)= +_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)= +_LT_AC_TAGVAR(hardcode_libdir_separator, $1)= +_LT_AC_TAGVAR(hardcode_minus_L, $1)=no +_LT_AC_TAGVAR(hardcode_automatic, $1)=no +_LT_AC_TAGVAR(module_cmds, $1)= +_LT_AC_TAGVAR(module_expsym_cmds, $1)= +_LT_AC_TAGVAR(link_all_deplibs, $1)=unknown +_LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds +_LT_AC_TAGVAR(no_undefined_flag, $1)= +_LT_AC_TAGVAR(whole_archive_flag_spec, $1)= +_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no -# Source file extension for Java test sources. -ac_ext=java +# Source file extension for f77 test sources. +ac_ext=f -# Object file extension for compiled Java test sources. +# Object file extension for compiled f77 test sources. objext=o -_LT_TAGVAR(objext, $1)=$objext +_LT_AC_TAGVAR(objext, $1)=$objext # Code to be used in simple compile tests -lt_simple_compile_test_code="class foo {}" +lt_simple_compile_test_code="\ + subroutine t + return + end +" # Code to be used in simple link tests -lt_simple_link_test_code='public class conftest { public static void main(String[[]] argv) {}; }' +lt_simple_link_test_code="\ + program t + end +" # ltmain only uses $CC for tagged configurations so make sure $CC is set. -_LT_TAG_COMPILER +_LT_AC_SYS_COMPILER # save warnings/boilerplate of simple test code _LT_COMPILER_BOILERPLATE @@ -6891,61 +5854,81 @@ _LT_LINKER_BOILERPLATE # Allow CC to be a program name with arguments. lt_save_CC="$CC" -lt_save_GCC=$GCC -GCC=yes -CC=${GCJ-"gcj"} +CC=${F77-"f77"} compiler=$CC -_LT_TAGVAR(compiler, $1)=$CC -_LT_TAGVAR(LD, $1)="$LD" +_LT_AC_TAGVAR(compiler, $1)=$CC _LT_CC_BASENAME([$compiler]) -# GCJ did not exist at the time GCC didn't implicitly link libc in. -_LT_TAGVAR(archive_cmds_need_lc, $1)=no +AC_MSG_CHECKING([if libtool supports shared libraries]) +AC_MSG_RESULT([$can_build_shared]) + +AC_MSG_CHECKING([whether to build shared libraries]) +test "$can_build_shared" = "no" && enable_shared=no + +# On AIX, shared libraries and static libraries use the same namespace, and +# are all built from PIC. +case $host_os in +aix3*) + test "$enable_shared" = yes && enable_static=no + if test -n "$RANLIB"; then + archive_cmds="$archive_cmds~\$RANLIB \$lib" + postinstall_cmds='$RANLIB $lib' + fi + ;; +aix[[4-9]]*) + if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then + test "$enable_shared" = yes && enable_static=no + fi + ;; +esac +AC_MSG_RESULT([$enable_shared]) -_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds +AC_MSG_CHECKING([whether to build static libraries]) +# Make sure either enable_shared or enable_static is yes. +test "$enable_shared" = yes || enable_static=yes +AC_MSG_RESULT([$enable_static]) -if test -n "$compiler"; then - _LT_COMPILER_NO_RTTI($1) - _LT_COMPILER_PIC($1) - _LT_COMPILER_C_O($1) - _LT_COMPILER_FILE_LOCKS($1) - _LT_LINKER_SHLIBS($1) - _LT_LINKER_HARDCODE_LIBPATH($1) +_LT_AC_TAGVAR(GCC, $1)="$G77" +_LT_AC_TAGVAR(LD, $1)="$LD" - _LT_CONFIG($1) -fi +AC_LIBTOOL_PROG_COMPILER_PIC($1) +AC_LIBTOOL_PROG_CC_C_O($1) +AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1) +AC_LIBTOOL_PROG_LD_SHLIBS($1) +AC_LIBTOOL_SYS_DYNAMIC_LINKER($1) +AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1) -AC_LANG_RESTORE +AC_LIBTOOL_CONFIG($1) -GCC=$lt_save_GCC +AC_LANG_POP CC="$lt_save_CC" -])# _LT_LANG_GCJ_CONFIG +])# AC_LIBTOOL_LANG_F77_CONFIG -# _LT_LANG_RC_CONFIG([TAG]) -# ------------------------- -# Ensure that the configuration variables for the Windows resource compiler -# are suitably defined. These variables are subsequently used by _LT_CONFIG -# to write the compiler configuration to `libtool'. -m4_defun([_LT_LANG_RC_CONFIG], -[AC_REQUIRE([LT_PROG_RC])dnl -AC_LANG_SAVE +# AC_LIBTOOL_LANG_GCJ_CONFIG +# -------------------------- +# Ensure that the configuration vars for the C compiler are +# suitably defined. Those variables are subsequently used by +# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'. +AC_DEFUN([AC_LIBTOOL_LANG_GCJ_CONFIG], [_LT_AC_LANG_GCJ_CONFIG(GCJ)]) +AC_DEFUN([_LT_AC_LANG_GCJ_CONFIG], +[AC_LANG_SAVE -# Source file extension for RC test sources. -ac_ext=rc +# Source file extension for Java test sources. +ac_ext=java -# Object file extension for compiled RC test sources. +# Object file extension for compiled Java test sources. objext=o -_LT_TAGVAR(objext, $1)=$objext +_LT_AC_TAGVAR(objext, $1)=$objext # Code to be used in simple compile tests -lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }' +lt_simple_compile_test_code="class foo {}" # Code to be used in simple link tests -lt_simple_link_test_code="$lt_simple_compile_test_code" +lt_simple_link_test_code='public class conftest { public static void main(String[[]] argv) {}; }' # ltmain only uses $CC for tagged configurations so make sure $CC is set. -_LT_TAG_COMPILER +_LT_AC_SYS_COMPILER # save warnings/boilerplate of simple test code _LT_COMPILER_BOILERPLATE @@ -6953,2904 +5936,2610 @@ _LT_LINKER_BOILERPLATE # Allow CC to be a program name with arguments. lt_save_CC="$CC" -lt_save_GCC=$GCC -GCC= -CC=${RC-"windres"} +CC=${GCJ-"gcj"} compiler=$CC -_LT_TAGVAR(compiler, $1)=$CC +_LT_AC_TAGVAR(compiler, $1)=$CC _LT_CC_BASENAME([$compiler]) -_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes - -if test -n "$compiler"; then - : - _LT_CONFIG($1) -fi - -GCC=$lt_save_GCC -AC_LANG_RESTORE -CC="$lt_save_CC" -])# _LT_LANG_RC_CONFIG - - -# LT_PROG_GCJ -# ----------- -AC_DEFUN([LT_PROG_GCJ], -[m4_ifdef([AC_PROG_GCJ], [AC_PROG_GCJ], - [m4_ifdef([A][M_PROG_GCJ], [A][M_PROG_GCJ], - [AC_CHECK_TOOL(GCJ, gcj,) - test "x${GCJFLAGS+set}" = xset || GCJFLAGS="-g -O2" - AC_SUBST(GCJFLAGS)])])[]dnl -]) - -# Old name: -AU_ALIAS([LT_AC_PROG_GCJ], [LT_PROG_GCJ]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([LT_AC_PROG_GCJ], []) - - -# LT_PROG_RC -# ---------- -AC_DEFUN([LT_PROG_RC], -[AC_CHECK_TOOL(RC, windres,) -]) - -# Old name: -AU_ALIAS([LT_AC_PROG_RC], [LT_PROG_RC]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([LT_AC_PROG_RC], []) - - -# _LT_DECL_EGREP -# -------------- -# If we don't have a new enough Autoconf to choose the best grep -# available, choose the one first in the user's PATH. -m4_defun([_LT_DECL_EGREP], -[AC_REQUIRE([AC_PROG_EGREP])dnl -AC_REQUIRE([AC_PROG_FGREP])dnl -test -z "$GREP" && GREP=grep -_LT_DECL([], [GREP], [1], [A grep program that handles long lines]) -_LT_DECL([], [EGREP], [1], [An ERE matcher]) -_LT_DECL([], [FGREP], [1], [A literal string matcher]) -dnl Non-bleeding-edge autoconf doesn't subst GREP, so do it here too -AC_SUBST([GREP]) -]) - - -# _LT_DECL_OBJDUMP -# -------------- -# If we don't have a new enough Autoconf to choose the best objdump -# available, choose the one first in the user's PATH. -m4_defun([_LT_DECL_OBJDUMP], -[AC_CHECK_TOOL(OBJDUMP, objdump, false) -test -z "$OBJDUMP" && OBJDUMP=objdump -_LT_DECL([], [OBJDUMP], [1], [An object symbol dumper]) -AC_SUBST([OBJDUMP]) -]) - - -# _LT_DECL_SED -# ------------ -# Check for a fully-functional sed program, that truncates -# as few characters as possible. Prefer GNU sed if found. -m4_defun([_LT_DECL_SED], -[AC_PROG_SED -test -z "$SED" && SED=sed -Xsed="$SED -e 1s/^X//" -_LT_DECL([], [SED], [1], [A sed program that does not truncate output]) -_LT_DECL([], [Xsed], ["\$SED -e 1s/^X//"], - [Sed that helps us avoid accidentally triggering echo(1) options like -n]) -])# _LT_DECL_SED - -m4_ifndef([AC_PROG_SED], [ -# NOTE: This macro has been submitted for inclusion into # -# GNU Autoconf as AC_PROG_SED. When it is available in # -# a released version of Autoconf we should remove this # -# macro and use it instead. # - -m4_defun([AC_PROG_SED], -[AC_MSG_CHECKING([for a sed that does not truncate output]) -AC_CACHE_VAL(lt_cv_path_SED, -[# 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 $as_executable_p "$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 -]) -SED=$lt_cv_path_SED -AC_SUBST([SED]) -AC_MSG_RESULT([$SED]) -])#AC_PROG_SED -])#m4_ifndef - -# Old name: -AU_ALIAS([LT_AC_PROG_SED], [AC_PROG_SED]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([LT_AC_PROG_SED], []) - - -# _LT_CHECK_SHELL_FEATURES -# ------------------------ -# Find out whether the shell is Bourne or XSI compatible, -# or has some other useful features. -m4_defun([_LT_CHECK_SHELL_FEATURES], -[AC_MSG_CHECKING([whether the shell understands some XSI constructs]) -# Try some XSI features -xsi_shell=no -( _lt_dummy="a/b/c" - test "${_lt_dummy##*/},${_lt_dummy%/*},"${_lt_dummy%"$_lt_dummy"}, \ - = c,a/b,, \ - && eval 'test $(( 1 + 1 )) -eq 2 \ - && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \ - && xsi_shell=yes -AC_MSG_RESULT([$xsi_shell]) -_LT_CONFIG_LIBTOOL_INIT([xsi_shell='$xsi_shell']) - -AC_MSG_CHECKING([whether the shell understands "+="]) -lt_shell_append=no -( foo=bar; set foo baz; eval "$[1]+=\$[2]" && test "$foo" = barbaz ) \ - >/dev/null 2>&1 \ - && lt_shell_append=yes -AC_MSG_RESULT([$lt_shell_append]) -_LT_CONFIG_LIBTOOL_INIT([lt_shell_append='$lt_shell_append']) - -if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then - lt_unset=unset -else - lt_unset=false -fi -_LT_DECL([], [lt_unset], [0], [whether the shell understands "unset"])dnl - -# test EBCDIC or ASCII -case `echo X|tr X '\101'` in - A) # ASCII based system - # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr - lt_SP2NL='tr \040 \012' - lt_NL2SP='tr \015\012 \040\040' - ;; - *) # EBCDIC based system - lt_SP2NL='tr \100 \n' - lt_NL2SP='tr \r\n \100\100' - ;; -esac -_LT_DECL([SP2NL], [lt_SP2NL], [1], [turn spaces into newlines])dnl -_LT_DECL([NL2SP], [lt_NL2SP], [1], [turn newlines into spaces])dnl -])# _LT_CHECK_SHELL_FEATURES - - -# _LT_PROG_XSI_SHELLFNS -# --------------------- -# Bourne and XSI compatible variants of some useful shell functions. -m4_defun([_LT_PROG_XSI_SHELLFNS], -[case $xsi_shell in - yes) - cat << \_LT_EOF >> "$cfgfile" - -# func_dirname file append nondir_replacement -# Compute the dirname of FILE. If nonempty, add APPEND to the result, -# otherwise set result to NONDIR_REPLACEMENT. -func_dirname () -{ - case ${1} in - */*) func_dirname_result="${1%/*}${2}" ;; - * ) func_dirname_result="${3}" ;; - esac -} - -# func_basename file -func_basename () -{ - func_basename_result="${1##*/}" -} - -# func_dirname_and_basename file append nondir_replacement -# perform func_basename and func_dirname in a single function -# call: -# dirname: Compute the dirname of FILE. If nonempty, -# add APPEND to the result, otherwise set result -# to NONDIR_REPLACEMENT. -# value returned in "$func_dirname_result" -# basename: Compute filename of FILE. -# value retuned in "$func_basename_result" -# Implementation must be kept synchronized with func_dirname -# and func_basename. For efficiency, we do not delegate to -# those functions but instead duplicate the functionality here. -func_dirname_and_basename () -{ - case ${1} in - */*) func_dirname_result="${1%/*}${2}" ;; - * ) func_dirname_result="${3}" ;; - esac - func_basename_result="${1##*/}" -} - -# func_stripname prefix suffix name -# strip PREFIX and SUFFIX off of NAME. -# PREFIX and SUFFIX must not contain globbing or regex special -# characters, hashes, percent signs, but SUFFIX may contain a leading -# dot (in which case that matches only a dot). -func_stripname () -{ - # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are - # positional parameters, so assign one to ordinary parameter first. - func_stripname_result=${3} - func_stripname_result=${func_stripname_result#"${1}"} - func_stripname_result=${func_stripname_result%"${2}"} -} - -# func_opt_split -func_opt_split () -{ - func_opt_split_opt=${1%%=*} - func_opt_split_arg=${1#*=} -} - -# func_lo2o object -func_lo2o () -{ - case ${1} in - *.lo) func_lo2o_result=${1%.lo}.${objext} ;; - *) func_lo2o_result=${1} ;; - esac -} - -# func_xform libobj-or-source -func_xform () -{ - func_xform_result=${1%.*}.lo -} - -# func_arith arithmetic-term... -func_arith () -{ - func_arith_result=$(( $[*] )) -} - -# func_len string -# STRING may not start with a hyphen. -func_len () -{ - func_len_result=${#1} -} - -_LT_EOF - ;; - *) # Bourne compatible functions. - cat << \_LT_EOF >> "$cfgfile" - -# func_dirname file append nondir_replacement -# Compute the dirname of FILE. If nonempty, add APPEND to the result, -# otherwise set result to NONDIR_REPLACEMENT. -func_dirname () -{ - # Extract subdirectory from the argument. - func_dirname_result=`$ECHO "X${1}" | $Xsed -e "$dirname"` - if test "X$func_dirname_result" = "X${1}"; then - func_dirname_result="${3}" - else - func_dirname_result="$func_dirname_result${2}" - fi -} - -# func_basename file -func_basename () -{ - func_basename_result=`$ECHO "X${1}" | $Xsed -e "$basename"` -} - -dnl func_dirname_and_basename -dnl A portable version of this function is already defined in general.m4sh -dnl so there is no need for it here. - -# func_stripname prefix suffix name -# strip PREFIX and SUFFIX off of NAME. -# PREFIX and SUFFIX must not contain globbing or regex special -# characters, hashes, percent signs, but SUFFIX may contain a leading -# dot (in which case that matches only a dot). -# func_strip_suffix prefix name -func_stripname () -{ - case ${2} in - .*) func_stripname_result=`$ECHO "X${3}" \ - | $Xsed -e "s%^${1}%%" -e "s%\\\\${2}\$%%"`;; - *) func_stripname_result=`$ECHO "X${3}" \ - | $Xsed -e "s%^${1}%%" -e "s%${2}\$%%"`;; - esac -} - -# sed scripts: -my_sed_long_opt='1s/^\(-[[^=]]*\)=.*/\1/;q' -my_sed_long_arg='1s/^-[[^=]]*=//' - -# func_opt_split -func_opt_split () -{ - func_opt_split_opt=`$ECHO "X${1}" | $Xsed -e "$my_sed_long_opt"` - func_opt_split_arg=`$ECHO "X${1}" | $Xsed -e "$my_sed_long_arg"` -} - -# func_lo2o object -func_lo2o () -{ - func_lo2o_result=`$ECHO "X${1}" | $Xsed -e "$lo2o"` -} - -# func_xform libobj-or-source -func_xform () -{ - func_xform_result=`$ECHO "X${1}" | $Xsed -e 's/\.[[^.]]*$/.lo/'` -} - -# func_arith arithmetic-term... -func_arith () -{ - func_arith_result=`expr "$[@]"` -} - -# func_len string -# STRING may not start with a hyphen. -func_len () -{ - func_len_result=`expr "$[1]" : ".*" 2>/dev/null || echo $max_cmd_len` -} - -_LT_EOF -esac - -case $lt_shell_append in - yes) - cat << \_LT_EOF >> "$cfgfile" - -# func_append var value -# Append VALUE to the end of shell variable VAR. -func_append () -{ - eval "$[1]+=\$[2]" -} -_LT_EOF - ;; - *) - cat << \_LT_EOF >> "$cfgfile" - -# func_append var value -# Append VALUE to the end of shell variable VAR. -func_append () -{ - eval "$[1]=\$$[1]\$[2]" -} - -_LT_EOF - ;; - esac -]) - -# Helper functions for option handling. -*- Autoconf -*- -# -# Copyright (C) 2004, 2005, 2007, 2008 Free Software Foundation, Inc. -# Written by Gary V. Vaughan, 2004 -# -# This file 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. - -# serial 6 ltoptions.m4 - -# This is to help aclocal find these macros, as it can't see m4_define. -AC_DEFUN([LTOPTIONS_VERSION], [m4_if([1])]) - - -# _LT_MANGLE_OPTION(MACRO-NAME, OPTION-NAME) -# ------------------------------------------ -m4_define([_LT_MANGLE_OPTION], -[[_LT_OPTION_]m4_bpatsubst($1__$2, [[^a-zA-Z0-9_]], [_])]) - - -# _LT_SET_OPTION(MACRO-NAME, OPTION-NAME) -# --------------------------------------- -# Set option OPTION-NAME for macro MACRO-NAME, and if there is a -# matching handler defined, dispatch to it. Other OPTION-NAMEs are -# saved as a flag. -m4_define([_LT_SET_OPTION], -[m4_define(_LT_MANGLE_OPTION([$1], [$2]))dnl -m4_ifdef(_LT_MANGLE_DEFUN([$1], [$2]), - _LT_MANGLE_DEFUN([$1], [$2]), - [m4_warning([Unknown $1 option `$2'])])[]dnl -]) - - -# _LT_IF_OPTION(MACRO-NAME, OPTION-NAME, IF-SET, [IF-NOT-SET]) -# ------------------------------------------------------------ -# Execute IF-SET if OPTION is set, IF-NOT-SET otherwise. -m4_define([_LT_IF_OPTION], -[m4_ifdef(_LT_MANGLE_OPTION([$1], [$2]), [$3], [$4])]) - - -# _LT_UNLESS_OPTIONS(MACRO-NAME, OPTION-LIST, IF-NOT-SET) -# ------------------------------------------------------- -# Execute IF-NOT-SET unless all options in OPTION-LIST for MACRO-NAME -# are set. -m4_define([_LT_UNLESS_OPTIONS], -[m4_foreach([_LT_Option], m4_split(m4_normalize([$2])), - [m4_ifdef(_LT_MANGLE_OPTION([$1], _LT_Option), - [m4_define([$0_found])])])[]dnl -m4_ifdef([$0_found], [m4_undefine([$0_found])], [$3 -])[]dnl -]) - - -# _LT_SET_OPTIONS(MACRO-NAME, OPTION-LIST) -# ---------------------------------------- -# OPTION-LIST is a space-separated list of Libtool options associated -# with MACRO-NAME. If any OPTION has a matching handler declared with -# LT_OPTION_DEFINE, dispatch to that macro; otherwise complain about -# the unknown option and exit. -m4_defun([_LT_SET_OPTIONS], -[# Set options -m4_foreach([_LT_Option], m4_split(m4_normalize([$2])), - [_LT_SET_OPTION([$1], _LT_Option)]) - -m4_if([$1],[LT_INIT],[ - dnl - dnl Simply set some default values (i.e off) if boolean options were not - dnl specified: - _LT_UNLESS_OPTIONS([LT_INIT], [dlopen], [enable_dlopen=no - ]) - _LT_UNLESS_OPTIONS([LT_INIT], [win32-dll], [enable_win32_dll=no - ]) - dnl - dnl If no reference was made to various pairs of opposing options, then - dnl we run the default mode handler for the pair. For example, if neither - dnl `shared' nor `disable-shared' was passed, we enable building of shared - dnl archives by default: - _LT_UNLESS_OPTIONS([LT_INIT], [shared disable-shared], [_LT_ENABLE_SHARED]) - _LT_UNLESS_OPTIONS([LT_INIT], [static disable-static], [_LT_ENABLE_STATIC]) - _LT_UNLESS_OPTIONS([LT_INIT], [pic-only no-pic], [_LT_WITH_PIC]) - _LT_UNLESS_OPTIONS([LT_INIT], [fast-install disable-fast-install], - [_LT_ENABLE_FAST_INSTALL]) - ]) -])# _LT_SET_OPTIONS - +# GCJ did not exist at the time GCC didn't implicitly link libc in. +_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no -# _LT_MANGLE_DEFUN(MACRO-NAME, OPTION-NAME) -# ----------------------------------------- -m4_define([_LT_MANGLE_DEFUN], -[[_LT_OPTION_DEFUN_]m4_bpatsubst(m4_toupper([$1__$2]), [[^A-Z0-9_]], [_])]) +_LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds +AC_LIBTOOL_PROG_COMPILER_NO_RTTI($1) +AC_LIBTOOL_PROG_COMPILER_PIC($1) +AC_LIBTOOL_PROG_CC_C_O($1) +AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1) +AC_LIBTOOL_PROG_LD_SHLIBS($1) +AC_LIBTOOL_SYS_DYNAMIC_LINKER($1) +AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1) -# LT_OPTION_DEFINE(MACRO-NAME, OPTION-NAME, CODE) -# ----------------------------------------------- -m4_define([LT_OPTION_DEFINE], -[m4_define(_LT_MANGLE_DEFUN([$1], [$2]), [$3])[]dnl -])# LT_OPTION_DEFINE +AC_LIBTOOL_CONFIG($1) +AC_LANG_RESTORE +CC="$lt_save_CC" +])# AC_LIBTOOL_LANG_GCJ_CONFIG -# dlopen -# ------ -LT_OPTION_DEFINE([LT_INIT], [dlopen], [enable_dlopen=yes -]) -AU_DEFUN([AC_LIBTOOL_DLOPEN], -[_LT_SET_OPTION([LT_INIT], [dlopen]) -AC_DIAGNOSE([obsolete], -[$0: Remove this warning and the call to _LT_SET_OPTION when you -put the `dlopen' option into LT_INIT's first parameter.]) -]) +# AC_LIBTOOL_LANG_RC_CONFIG +# ------------------------- +# Ensure that the configuration vars for the Windows resource compiler are +# suitably defined. Those variables are subsequently used by +# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'. +AC_DEFUN([AC_LIBTOOL_LANG_RC_CONFIG], [_LT_AC_LANG_RC_CONFIG(RC)]) +AC_DEFUN([_LT_AC_LANG_RC_CONFIG], +[AC_LANG_SAVE -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_LIBTOOL_DLOPEN], []) +# Source file extension for RC test sources. +ac_ext=rc +# Object file extension for compiled RC test sources. +objext=o +_LT_AC_TAGVAR(objext, $1)=$objext -# win32-dll -# --------- -# Declare package support for building win32 dll's. -LT_OPTION_DEFINE([LT_INIT], [win32-dll], -[enable_win32_dll=yes +# Code to be used in simple compile tests +lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }' -case $host in -*-*-cygwin* | *-*-mingw* | *-*-pw32* | *-cegcc*) - AC_CHECK_TOOL(AS, as, false) - AC_CHECK_TOOL(DLLTOOL, dlltool, false) - AC_CHECK_TOOL(OBJDUMP, objdump, false) - ;; -esac +# Code to be used in simple link tests +lt_simple_link_test_code="$lt_simple_compile_test_code" -test -z "$AS" && AS=as -_LT_DECL([], [AS], [0], [Assembler program])dnl +# ltmain only uses $CC for tagged configurations so make sure $CC is set. +_LT_AC_SYS_COMPILER -test -z "$DLLTOOL" && DLLTOOL=dlltool -_LT_DECL([], [DLLTOOL], [0], [DLL creation program])dnl +# save warnings/boilerplate of simple test code +_LT_COMPILER_BOILERPLATE +_LT_LINKER_BOILERPLATE -test -z "$OBJDUMP" && OBJDUMP=objdump -_LT_DECL([], [OBJDUMP], [0], [Object dumper program])dnl -])# win32-dll +# Allow CC to be a program name with arguments. +lt_save_CC="$CC" +CC=${RC-"windres"} +compiler=$CC +_LT_AC_TAGVAR(compiler, $1)=$CC +_LT_CC_BASENAME([$compiler]) +_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes -AU_DEFUN([AC_LIBTOOL_WIN32_DLL], -[AC_REQUIRE([AC_CANONICAL_HOST])dnl -_LT_SET_OPTION([LT_INIT], [win32-dll]) -AC_DIAGNOSE([obsolete], -[$0: Remove this warning and the call to _LT_SET_OPTION when you -put the `win32-dll' option into LT_INIT's first parameter.]) -]) +AC_LIBTOOL_CONFIG($1) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_LIBTOOL_WIN32_DLL], []) +AC_LANG_RESTORE +CC="$lt_save_CC" +])# AC_LIBTOOL_LANG_RC_CONFIG -# _LT_ENABLE_SHARED([DEFAULT]) +# AC_LIBTOOL_CONFIG([TAGNAME]) # ---------------------------- -# implement the --enable-shared flag, and supports the `shared' and -# `disable-shared' LT_INIT options. -# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. -m4_define([_LT_ENABLE_SHARED], -[m4_define([_LT_ENABLE_SHARED_DEFAULT], [m4_if($1, no, no, yes)])dnl -AC_ARG_ENABLE([shared], - [AS_HELP_STRING([--enable-shared@<:@=PKGS@:>@], - [build shared libraries @<:@default=]_LT_ENABLE_SHARED_DEFAULT[@:>@])], - [p=${PACKAGE-default} - case $enableval in - yes) enable_shared=yes ;; - no) enable_shared=no ;; +# If TAGNAME is not passed, then create an initial libtool script +# with a default configuration from the untagged config vars. Otherwise +# add code to config.status for appending the configuration named by +# TAGNAME from the matching tagged config vars. +AC_DEFUN([AC_LIBTOOL_CONFIG], +[# The else clause should only fire when bootstrapping the +# libtool distribution, otherwise you forgot to ship ltmain.sh +# with your package, and you will get complaints that there are +# no rules to generate ltmain.sh. +if test -f "$ltmain"; then + # See if we are running on zsh, and set the options which allow our commands through + # without removal of \ escapes. + if test -n "${ZSH_VERSION+set}" ; then + setopt NO_GLOB_SUBST + fi + # Now quote all the things that may contain metacharacters while being + # careful not to overquote the AC_SUBSTed values. We take copies of the + # variables and quote the copies for generation of the libtool script. + for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC LTCFLAGS NM \ + SED SHELL STRIP \ + libname_spec library_names_spec soname_spec extract_expsyms_cmds \ + old_striplib striplib file_magic_cmd finish_cmds finish_eval \ + deplibs_check_method reload_flag reload_cmds need_locks \ + lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \ + lt_cv_sys_global_symbol_to_c_name_address \ + sys_lib_search_path_spec sys_lib_dlsearch_path_spec \ + old_postinstall_cmds old_postuninstall_cmds \ + _LT_AC_TAGVAR(compiler, $1) \ + _LT_AC_TAGVAR(CC, $1) \ + _LT_AC_TAGVAR(LD, $1) \ + _LT_AC_TAGVAR(lt_prog_compiler_wl, $1) \ + _LT_AC_TAGVAR(lt_prog_compiler_pic, $1) \ + _LT_AC_TAGVAR(lt_prog_compiler_static, $1) \ + _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) \ + _LT_AC_TAGVAR(export_dynamic_flag_spec, $1) \ + _LT_AC_TAGVAR(thread_safe_flag_spec, $1) \ + _LT_AC_TAGVAR(whole_archive_flag_spec, $1) \ + _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1) \ + _LT_AC_TAGVAR(old_archive_cmds, $1) \ + _LT_AC_TAGVAR(old_archive_from_new_cmds, $1) \ + _LT_AC_TAGVAR(predep_objects, $1) \ + _LT_AC_TAGVAR(postdep_objects, $1) \ + _LT_AC_TAGVAR(predeps, $1) \ + _LT_AC_TAGVAR(postdeps, $1) \ + _LT_AC_TAGVAR(compiler_lib_search_path, $1) \ + _LT_AC_TAGVAR(compiler_lib_search_dirs, $1) \ + _LT_AC_TAGVAR(archive_cmds, $1) \ + _LT_AC_TAGVAR(archive_expsym_cmds, $1) \ + _LT_AC_TAGVAR(postinstall_cmds, $1) \ + _LT_AC_TAGVAR(postuninstall_cmds, $1) \ + _LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1) \ + _LT_AC_TAGVAR(allow_undefined_flag, $1) \ + _LT_AC_TAGVAR(no_undefined_flag, $1) \ + _LT_AC_TAGVAR(export_symbols_cmds, $1) \ + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) \ + _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1) \ + _LT_AC_TAGVAR(hardcode_libdir_separator, $1) \ + _LT_AC_TAGVAR(hardcode_automatic, $1) \ + _LT_AC_TAGVAR(module_cmds, $1) \ + _LT_AC_TAGVAR(module_expsym_cmds, $1) \ + _LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1) \ + _LT_AC_TAGVAR(fix_srcfile_path, $1) \ + _LT_AC_TAGVAR(exclude_expsyms, $1) \ + _LT_AC_TAGVAR(include_expsyms, $1); do + + case $var in + _LT_AC_TAGVAR(old_archive_cmds, $1) | \ + _LT_AC_TAGVAR(old_archive_from_new_cmds, $1) | \ + _LT_AC_TAGVAR(archive_cmds, $1) | \ + _LT_AC_TAGVAR(archive_expsym_cmds, $1) | \ + _LT_AC_TAGVAR(module_cmds, $1) | \ + _LT_AC_TAGVAR(module_expsym_cmds, $1) | \ + _LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1) | \ + _LT_AC_TAGVAR(export_symbols_cmds, $1) | \ + extract_expsyms_cmds | reload_cmds | finish_cmds | \ + postinstall_cmds | postuninstall_cmds | \ + old_postinstall_cmds | old_postuninstall_cmds | \ + sys_lib_search_path_spec | sys_lib_dlsearch_path_spec) + # Double-quote double-evaled strings. + eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\"" + ;; *) - 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" + eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\"" ;; - esac], - [enable_shared=]_LT_ENABLE_SHARED_DEFAULT) + esac + done - _LT_DECL([build_libtool_libs], [enable_shared], [0], - [Whether or not to build shared libraries]) -])# _LT_ENABLE_SHARED + case $lt_echo in + *'\[$]0 --fallback-echo"') + lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\[$]0 --fallback-echo"[$]/[$]0 --fallback-echo"/'` + ;; + esac -LT_OPTION_DEFINE([LT_INIT], [shared], [_LT_ENABLE_SHARED([yes])]) -LT_OPTION_DEFINE([LT_INIT], [disable-shared], [_LT_ENABLE_SHARED([no])]) +ifelse([$1], [], + [cfgfile="${ofile}T" + trap "$rm \"$cfgfile\"; exit 1" 1 2 15 + $rm -f "$cfgfile" + AC_MSG_NOTICE([creating $ofile])], + [cfgfile="$ofile"]) -# Old names: -AC_DEFUN([AC_ENABLE_SHARED], -[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[shared]) -]) + cat <<__EOF__ >> "$cfgfile" +ifelse([$1], [], +[#! $SHELL -AC_DEFUN([AC_DISABLE_SHARED], -[_LT_SET_OPTION([LT_INIT], [disable-shared]) -]) +# `$echo "$cfgfile" | sed 's%^.*/%%'` - Provide generalized library-building support services. +# Generated automatically by $PROGRAM (GNU $PACKAGE $VERSION$TIMESTAMP) +# NOTE: Changes made to this file will be lost: look at ltmain.sh. +# +# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 +# Free Software Foundation, Inc. +# +# This file is part of GNU Libtool: +# Originally by Gordon Matzigkeit , 1996 +# +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2 of the License, or +# (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, but +# WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 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. +# +# As a special exception to the GNU General Public License, if you +# distribute this file as part of a program that contains a +# configuration script generated by Autoconf, you may include it under +# the same distribution terms that you use for the rest of that program. -AU_DEFUN([AM_ENABLE_SHARED], [AC_ENABLE_SHARED($@)]) -AU_DEFUN([AM_DISABLE_SHARED], [AC_DISABLE_SHARED($@)]) +# A sed program that does not truncate output. +SED=$lt_SED -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AM_ENABLE_SHARED], []) -dnl AC_DEFUN([AM_DISABLE_SHARED], []) +# Sed that helps us avoid accidentally triggering echo(1) options like -n. +Xsed="$SED -e 1s/^X//" +# The HP-UX ksh and POSIX shell print the target directory to stdout +# if CDPATH is set. +(unset CDPATH) >/dev/null 2>&1 && unset CDPATH +# The names of the tagged configurations supported by this script. +available_tags= -# _LT_ENABLE_STATIC([DEFAULT]) -# ---------------------------- -# implement the --enable-static flag, and support the `static' and -# `disable-static' LT_INIT options. -# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. -m4_define([_LT_ENABLE_STATIC], -[m4_define([_LT_ENABLE_STATIC_DEFAULT], [m4_if($1, no, no, yes)])dnl -AC_ARG_ENABLE([static], - [AS_HELP_STRING([--enable-static@<:@=PKGS@:>@], - [build static libraries @<:@default=]_LT_ENABLE_STATIC_DEFAULT[@:>@])], - [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], - [enable_static=]_LT_ENABLE_STATIC_DEFAULT) +# ### BEGIN LIBTOOL CONFIG], +[# ### BEGIN LIBTOOL TAG CONFIG: $tagname]) - _LT_DECL([build_old_libs], [enable_static], [0], - [Whether or not to build static libraries]) -])# _LT_ENABLE_STATIC +# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: -LT_OPTION_DEFINE([LT_INIT], [static], [_LT_ENABLE_STATIC([yes])]) -LT_OPTION_DEFINE([LT_INIT], [disable-static], [_LT_ENABLE_STATIC([no])]) +# Shell to use when invoking shell scripts. +SHELL=$lt_SHELL -# Old names: -AC_DEFUN([AC_ENABLE_STATIC], -[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[static]) -]) +# Whether or not to build shared libraries. +build_libtool_libs=$enable_shared -AC_DEFUN([AC_DISABLE_STATIC], -[_LT_SET_OPTION([LT_INIT], [disable-static]) -]) +# Whether or not to build static libraries. +build_old_libs=$enable_static -AU_DEFUN([AM_ENABLE_STATIC], [AC_ENABLE_STATIC($@)]) -AU_DEFUN([AM_DISABLE_STATIC], [AC_DISABLE_STATIC($@)]) +# Whether or not to add -lc for building shared libraries. +build_libtool_need_lc=$_LT_AC_TAGVAR(archive_cmds_need_lc, $1) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AM_ENABLE_STATIC], []) -dnl AC_DEFUN([AM_DISABLE_STATIC], []) +# Whether or not to disallow shared libs when runtime libs are static +allow_libtool_libs_with_static_runtimes=$_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1) +# Whether or not to optimize for fast installation. +fast_install=$enable_fast_install +# The host system. +host_alias=$host_alias +host=$host +host_os=$host_os -# _LT_ENABLE_FAST_INSTALL([DEFAULT]) -# ---------------------------------- -# implement the --enable-fast-install flag, and support the `fast-install' -# and `disable-fast-install' LT_INIT options. -# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. -m4_define([_LT_ENABLE_FAST_INSTALL], -[m4_define([_LT_ENABLE_FAST_INSTALL_DEFAULT], [m4_if($1, no, no, yes)])dnl -AC_ARG_ENABLE([fast-install], - [AS_HELP_STRING([--enable-fast-install@<:@=PKGS@:>@], - [optimize for fast installation @<:@default=]_LT_ENABLE_FAST_INSTALL_DEFAULT[@:>@])], - [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], - [enable_fast_install=]_LT_ENABLE_FAST_INSTALL_DEFAULT) +# The build system. +build_alias=$build_alias +build=$build +build_os=$build_os -_LT_DECL([fast_install], [enable_fast_install], [0], - [Whether or not to optimize for fast installation])dnl -])# _LT_ENABLE_FAST_INSTALL +# An echo program that does not interpret backslashes. +echo=$lt_echo -LT_OPTION_DEFINE([LT_INIT], [fast-install], [_LT_ENABLE_FAST_INSTALL([yes])]) -LT_OPTION_DEFINE([LT_INIT], [disable-fast-install], [_LT_ENABLE_FAST_INSTALL([no])]) +# The archiver. +AR=$lt_AR +AR_FLAGS=$lt_AR_FLAGS -# Old names: -AU_DEFUN([AC_ENABLE_FAST_INSTALL], -[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[fast-install]) -AC_DIAGNOSE([obsolete], -[$0: Remove this warning and the call to _LT_SET_OPTION when you put -the `fast-install' option into LT_INIT's first parameter.]) -]) +# A C compiler. +LTCC=$lt_LTCC -AU_DEFUN([AC_DISABLE_FAST_INSTALL], -[_LT_SET_OPTION([LT_INIT], [disable-fast-install]) -AC_DIAGNOSE([obsolete], -[$0: Remove this warning and the call to _LT_SET_OPTION when you put -the `disable-fast-install' option into LT_INIT's first parameter.]) -]) +# LTCC compiler flags. +LTCFLAGS=$lt_LTCFLAGS -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_ENABLE_FAST_INSTALL], []) -dnl AC_DEFUN([AM_DISABLE_FAST_INSTALL], []) +# A language-specific compiler. +CC=$lt_[]_LT_AC_TAGVAR(compiler, $1) +# Is the compiler the GNU C compiler? +with_gcc=$_LT_AC_TAGVAR(GCC, $1) -# _LT_WITH_PIC([MODE]) -# -------------------- -# implement the --with-pic flag, and support the `pic-only' and `no-pic' -# LT_INIT options. -# MODE is either `yes' or `no'. If omitted, it defaults to `both'. -m4_define([_LT_WITH_PIC], -[AC_ARG_WITH([pic], - [AS_HELP_STRING([--with-pic], - [try to use only PIC/non-PIC objects @<:@default=use both@:>@])], - [pic_mode="$withval"], - [pic_mode=default]) +# An ERE matcher. +EGREP=$lt_EGREP -test -z "$pic_mode" && pic_mode=m4_default([$1], [default]) +# The linker used to build libraries. +LD=$lt_[]_LT_AC_TAGVAR(LD, $1) -_LT_DECL([], [pic_mode], [0], [What type of objects to build])dnl -])# _LT_WITH_PIC +# Whether we need hard or soft links. +LN_S=$lt_LN_S -LT_OPTION_DEFINE([LT_INIT], [pic-only], [_LT_WITH_PIC([yes])]) -LT_OPTION_DEFINE([LT_INIT], [no-pic], [_LT_WITH_PIC([no])]) +# A BSD-compatible nm program. +NM=$lt_NM -# Old name: -AU_DEFUN([AC_LIBTOOL_PICMODE], -[_LT_SET_OPTION([LT_INIT], [pic-only]) -AC_DIAGNOSE([obsolete], -[$0: Remove this warning and the call to _LT_SET_OPTION when you -put the `pic-only' option into LT_INIT's first parameter.]) -]) +# A symbol stripping program +STRIP=$lt_STRIP -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_LIBTOOL_PICMODE], []) +# Used to examine libraries when file_magic_cmd begins "file" +MAGIC_CMD=$MAGIC_CMD +# Used on cygwin: DLL creation program. +DLLTOOL="$DLLTOOL" -m4_define([_LTDL_MODE], []) -LT_OPTION_DEFINE([LTDL_INIT], [nonrecursive], - [m4_define([_LTDL_MODE], [nonrecursive])]) -LT_OPTION_DEFINE([LTDL_INIT], [recursive], - [m4_define([_LTDL_MODE], [recursive])]) -LT_OPTION_DEFINE([LTDL_INIT], [subproject], - [m4_define([_LTDL_MODE], [subproject])]) +# Used on cygwin: object dumper. +OBJDUMP="$OBJDUMP" -m4_define([_LTDL_TYPE], []) -LT_OPTION_DEFINE([LTDL_INIT], [installable], - [m4_define([_LTDL_TYPE], [installable])]) -LT_OPTION_DEFINE([LTDL_INIT], [convenience], - [m4_define([_LTDL_TYPE], [convenience])]) +# Used on cygwin: assembler. +AS="$AS" -# ltsugar.m4 -- libtool m4 base layer. -*-Autoconf-*- -# -# Copyright (C) 2004, 2005, 2007, 2008 Free Software Foundation, Inc. -# Written by Gary V. Vaughan, 2004 -# -# This file 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. +# The name of the directory that contains temporary libtool files. +objdir=$objdir -# serial 6 ltsugar.m4 +# How to create reloadable object files. +reload_flag=$lt_reload_flag +reload_cmds=$lt_reload_cmds -# This is to help aclocal find these macros, as it can't see m4_define. -AC_DEFUN([LTSUGAR_VERSION], [m4_if([0.1])]) +# How to pass a linker flag through the compiler. +wl=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_wl, $1) +# Object file suffix (normally "o"). +objext="$ac_objext" -# lt_join(SEP, ARG1, [ARG2...]) -# ----------------------------- -# Produce ARG1SEPARG2...SEPARGn, omitting [] arguments and their -# associated separator. -# Needed until we can rely on m4_join from Autoconf 2.62, since all earlier -# versions in m4sugar had bugs. -m4_define([lt_join], -[m4_if([$#], [1], [], - [$#], [2], [[$2]], - [m4_if([$2], [], [], [[$2]_])$0([$1], m4_shift(m4_shift($@)))])]) -m4_define([_lt_join], -[m4_if([$#$2], [2], [], - [m4_if([$2], [], [], [[$1$2]])$0([$1], m4_shift(m4_shift($@)))])]) - - -# lt_car(LIST) -# lt_cdr(LIST) -# ------------ -# Manipulate m4 lists. -# These macros are necessary as long as will still need to support -# Autoconf-2.59 which quotes differently. -m4_define([lt_car], [[$1]]) -m4_define([lt_cdr], -[m4_if([$#], 0, [m4_fatal([$0: cannot be called without arguments])], - [$#], 1, [], - [m4_dquote(m4_shift($@))])]) -m4_define([lt_unquote], $1) - - -# lt_append(MACRO-NAME, STRING, [SEPARATOR]) -# ------------------------------------------ -# Redefine MACRO-NAME to hold its former content plus `SEPARATOR'`STRING'. -# Note that neither SEPARATOR nor STRING are expanded; they are appended -# to MACRO-NAME as is (leaving the expansion for when MACRO-NAME is invoked). -# No SEPARATOR is output if MACRO-NAME was previously undefined (different -# than defined and empty). -# -# This macro is needed until we can rely on Autoconf 2.62, since earlier -# versions of m4sugar mistakenly expanded SEPARATOR but not STRING. -m4_define([lt_append], -[m4_define([$1], - m4_ifdef([$1], [m4_defn([$1])[$3]])[$2])]) - - - -# lt_combine(SEP, PREFIX-LIST, INFIX, SUFFIX1, [SUFFIX2...]) -# ---------------------------------------------------------- -# Produce a SEP delimited list of all paired combinations of elements of -# PREFIX-LIST with SUFFIX1 through SUFFIXn. Each element of the list -# has the form PREFIXmINFIXSUFFIXn. -# Needed until we can rely on m4_combine added in Autoconf 2.62. -m4_define([lt_combine], -[m4_if(m4_eval([$# > 3]), [1], - [m4_pushdef([_Lt_sep], [m4_define([_Lt_sep], m4_defn([lt_car]))])]]dnl -[[m4_foreach([_Lt_prefix], [$2], - [m4_foreach([_Lt_suffix], - ]m4_dquote(m4_dquote(m4_shift(m4_shift(m4_shift($@)))))[, - [_Lt_sep([$1])[]m4_defn([_Lt_prefix])[$3]m4_defn([_Lt_suffix])])])])]) - - -# lt_if_append_uniq(MACRO-NAME, VARNAME, [SEPARATOR], [UNIQ], [NOT-UNIQ]) -# ----------------------------------------------------------------------- -# Iff MACRO-NAME does not yet contain VARNAME, then append it (delimited -# by SEPARATOR if supplied) and expand UNIQ, else NOT-UNIQ. -m4_define([lt_if_append_uniq], -[m4_ifdef([$1], - [m4_if(m4_index([$3]m4_defn([$1])[$3], [$3$2$3]), [-1], - [lt_append([$1], [$2], [$3])$4], - [$5])], - [lt_append([$1], [$2], [$3])$4])]) - - -# lt_dict_add(DICT, KEY, VALUE) -# ----------------------------- -m4_define([lt_dict_add], -[m4_define([$1($2)], [$3])]) +# Old archive suffix (normally "a"). +libext="$libext" +# Shared library suffix (normally ".so"). +shrext_cmds='$shrext_cmds' -# lt_dict_add_subkey(DICT, KEY, SUBKEY, VALUE) -# -------------------------------------------- -m4_define([lt_dict_add_subkey], -[m4_define([$1($2:$3)], [$4])]) +# Executable file suffix (normally ""). +exeext="$exeext" +# Additional compiler flags for building library objects. +pic_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) +pic_mode=$pic_mode -# lt_dict_fetch(DICT, KEY, [SUBKEY]) -# ---------------------------------- -m4_define([lt_dict_fetch], -[m4_ifval([$3], - m4_ifdef([$1($2:$3)], [m4_defn([$1($2:$3)])]), - m4_ifdef([$1($2)], [m4_defn([$1($2)])]))]) +# What is the maximum length of a command? +max_cmd_len=$lt_cv_sys_max_cmd_len +# Does compiler simultaneously support -c and -o options? +compiler_c_o=$lt_[]_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1) -# lt_if_dict_fetch(DICT, KEY, [SUBKEY], VALUE, IF-TRUE, [IF-FALSE]) -# ----------------------------------------------------------------- -m4_define([lt_if_dict_fetch], -[m4_if(lt_dict_fetch([$1], [$2], [$3]), [$4], - [$5], - [$6])]) +# Must we lock files when doing compilation? +need_locks=$lt_need_locks +# Do we need the lib prefix for modules? +need_lib_prefix=$need_lib_prefix -# lt_dict_filter(DICT, [SUBKEY], VALUE, [SEPARATOR], KEY, [...]) -# -------------------------------------------------------------- -m4_define([lt_dict_filter], -[m4_if([$5], [], [], - [lt_join(m4_quote(m4_default([$4], [[, ]])), - lt_unquote(m4_split(m4_normalize(m4_foreach(_Lt_key, lt_car([m4_shiftn(4, $@)]), - [lt_if_dict_fetch([$1], _Lt_key, [$2], [$3], [_Lt_key ])])))))])[]dnl -]) +# Do we need a version for libraries? +need_version=$need_version -# ltversion.m4 -- version numbers -*- Autoconf -*- -# -# Copyright (C) 2004 Free Software Foundation, Inc. -# Written by Scott James Remnant, 2004 -# -# This file 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. +# Whether dlopen is supported. +dlopen_support=$enable_dlopen -# Generated from ltversion.in. +# Whether dlopen of programs is supported. +dlopen_self=$enable_dlopen_self -# serial 3012 ltversion.m4 -# This file is part of GNU Libtool +# Whether dlopen of statically linked programs is supported. +dlopen_self_static=$enable_dlopen_self_static -m4_define([LT_PACKAGE_VERSION], [2.2.6]) -m4_define([LT_PACKAGE_REVISION], [1.3012]) +# Compiler flag to prevent dynamic linking. +link_static_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_static, $1) -AC_DEFUN([LTVERSION_VERSION], -[macro_version='2.2.6' -macro_revision='1.3012' -_LT_DECL(, macro_version, 0, [Which release of libtool.m4 was used?]) -_LT_DECL(, macro_revision, 0) -]) +# Compiler flag to turn off builtin functions. +no_builtin_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -# lt~obsolete.m4 -- aclocal satisfying obsolete definitions. -*-Autoconf-*- -# -# Copyright (C) 2004, 2005, 2007 Free Software Foundation, Inc. -# Written by Scott James Remnant, 2004. -# -# This file 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. +# Compiler flag to allow reflexive dlopens. +export_dynamic_flag_spec=$lt_[]_LT_AC_TAGVAR(export_dynamic_flag_spec, $1) -# serial 4 lt~obsolete.m4 +# Compiler flag to generate shared objects directly from archives. +whole_archive_flag_spec=$lt_[]_LT_AC_TAGVAR(whole_archive_flag_spec, $1) -# These exist entirely to fool aclocal when bootstrapping libtool. -# -# In the past libtool.m4 has provided macros via AC_DEFUN (or AU_DEFUN) -# which have later been changed to m4_define as they aren't part of the -# exported API, or moved to Autoconf or Automake where they belong. -# -# The trouble is, aclocal is a bit thick. It'll see the old AC_DEFUN -# in /usr/share/aclocal/libtool.m4 and remember it, then when it sees us -# using a macro with the same name in our local m4/libtool.m4 it'll -# pull the old libtool.m4 in (it doesn't see our shiny new m4_define -# and doesn't know about Autoconf macros at all.) -# -# So we provide this file, which has a silly filename so it's always -# included after everything else. This provides aclocal with the -# AC_DEFUNs it wants, but when m4 processes it, it doesn't do anything -# because those macros already exist, or will be overwritten later. -# We use AC_DEFUN over AU_DEFUN for compatibility with aclocal-1.6. -# -# Anytime we withdraw an AC_DEFUN or AU_DEFUN, remember to add it here. -# Yes, that means every name once taken will need to remain here until -# we give up compatibility with versions before 1.7, at which point -# we need to keep only those names which we still refer to. - -# This is to help aclocal find these macros, as it can't see m4_define. -AC_DEFUN([LTOBSOLETE_VERSION], [m4_if([1])]) - -m4_ifndef([AC_LIBTOOL_LINKER_OPTION], [AC_DEFUN([AC_LIBTOOL_LINKER_OPTION])]) -m4_ifndef([AC_PROG_EGREP], [AC_DEFUN([AC_PROG_EGREP])]) -m4_ifndef([_LT_AC_PROG_ECHO_BACKSLASH], [AC_DEFUN([_LT_AC_PROG_ECHO_BACKSLASH])]) -m4_ifndef([_LT_AC_SHELL_INIT], [AC_DEFUN([_LT_AC_SHELL_INIT])]) -m4_ifndef([_LT_AC_SYS_LIBPATH_AIX], [AC_DEFUN([_LT_AC_SYS_LIBPATH_AIX])]) -m4_ifndef([_LT_PROG_LTMAIN], [AC_DEFUN([_LT_PROG_LTMAIN])]) -m4_ifndef([_LT_AC_TAGVAR], [AC_DEFUN([_LT_AC_TAGVAR])]) -m4_ifndef([AC_LTDL_ENABLE_INSTALL], [AC_DEFUN([AC_LTDL_ENABLE_INSTALL])]) -m4_ifndef([AC_LTDL_PREOPEN], [AC_DEFUN([AC_LTDL_PREOPEN])]) -m4_ifndef([_LT_AC_SYS_COMPILER], [AC_DEFUN([_LT_AC_SYS_COMPILER])]) -m4_ifndef([_LT_AC_LOCK], [AC_DEFUN([_LT_AC_LOCK])]) -m4_ifndef([AC_LIBTOOL_SYS_OLD_ARCHIVE], [AC_DEFUN([AC_LIBTOOL_SYS_OLD_ARCHIVE])]) -m4_ifndef([_LT_AC_TRY_DLOPEN_SELF], [AC_DEFUN([_LT_AC_TRY_DLOPEN_SELF])]) -m4_ifndef([AC_LIBTOOL_PROG_CC_C_O], [AC_DEFUN([AC_LIBTOOL_PROG_CC_C_O])]) -m4_ifndef([AC_LIBTOOL_SYS_HARD_LINK_LOCKS], [AC_DEFUN([AC_LIBTOOL_SYS_HARD_LINK_LOCKS])]) -m4_ifndef([AC_LIBTOOL_OBJDIR], [AC_DEFUN([AC_LIBTOOL_OBJDIR])]) -m4_ifndef([AC_LTDL_OBJDIR], [AC_DEFUN([AC_LTDL_OBJDIR])]) -m4_ifndef([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH], [AC_DEFUN([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH])]) -m4_ifndef([AC_LIBTOOL_SYS_LIB_STRIP], [AC_DEFUN([AC_LIBTOOL_SYS_LIB_STRIP])]) -m4_ifndef([AC_PATH_MAGIC], [AC_DEFUN([AC_PATH_MAGIC])]) -m4_ifndef([AC_PROG_LD_GNU], [AC_DEFUN([AC_PROG_LD_GNU])]) -m4_ifndef([AC_PROG_LD_RELOAD_FLAG], [AC_DEFUN([AC_PROG_LD_RELOAD_FLAG])]) -m4_ifndef([AC_DEPLIBS_CHECK_METHOD], [AC_DEFUN([AC_DEPLIBS_CHECK_METHOD])]) -m4_ifndef([AC_LIBTOOL_PROG_COMPILER_NO_RTTI], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_NO_RTTI])]) -m4_ifndef([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE], [AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE])]) -m4_ifndef([AC_LIBTOOL_PROG_COMPILER_PIC], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_PIC])]) -m4_ifndef([AC_LIBTOOL_PROG_LD_SHLIBS], [AC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS])]) -m4_ifndef([AC_LIBTOOL_POSTDEP_PREDEP], [AC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP])]) -m4_ifndef([LT_AC_PROG_EGREP], [AC_DEFUN([LT_AC_PROG_EGREP])]) -m4_ifndef([LT_AC_PROG_SED], [AC_DEFUN([LT_AC_PROG_SED])]) -m4_ifndef([_LT_CC_BASENAME], [AC_DEFUN([_LT_CC_BASENAME])]) -m4_ifndef([_LT_COMPILER_BOILERPLATE], [AC_DEFUN([_LT_COMPILER_BOILERPLATE])]) -m4_ifndef([_LT_LINKER_BOILERPLATE], [AC_DEFUN([_LT_LINKER_BOILERPLATE])]) -m4_ifndef([_AC_PROG_LIBTOOL], [AC_DEFUN([_AC_PROG_LIBTOOL])]) -m4_ifndef([AC_LIBTOOL_SETUP], [AC_DEFUN([AC_LIBTOOL_SETUP])]) -m4_ifndef([_LT_AC_CHECK_DLFCN], [AC_DEFUN([_LT_AC_CHECK_DLFCN])]) -m4_ifndef([AC_LIBTOOL_SYS_DYNAMIC_LINKER], [AC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER])]) -m4_ifndef([_LT_AC_TAGCONFIG], [AC_DEFUN([_LT_AC_TAGCONFIG])]) -m4_ifndef([AC_DISABLE_FAST_INSTALL], [AC_DEFUN([AC_DISABLE_FAST_INSTALL])]) -m4_ifndef([_LT_AC_LANG_CXX], [AC_DEFUN([_LT_AC_LANG_CXX])]) -m4_ifndef([_LT_AC_LANG_F77], [AC_DEFUN([_LT_AC_LANG_F77])]) -m4_ifndef([_LT_AC_LANG_GCJ], [AC_DEFUN([_LT_AC_LANG_GCJ])]) -m4_ifndef([AC_LIBTOOL_RC], [AC_DEFUN([AC_LIBTOOL_RC])]) -m4_ifndef([AC_LIBTOOL_LANG_C_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_C_CONFIG])]) -m4_ifndef([_LT_AC_LANG_C_CONFIG], [AC_DEFUN([_LT_AC_LANG_C_CONFIG])]) -m4_ifndef([AC_LIBTOOL_LANG_CXX_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG])]) -m4_ifndef([_LT_AC_LANG_CXX_CONFIG], [AC_DEFUN([_LT_AC_LANG_CXX_CONFIG])]) -m4_ifndef([AC_LIBTOOL_LANG_F77_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_F77_CONFIG])]) -m4_ifndef([_LT_AC_LANG_F77_CONFIG], [AC_DEFUN([_LT_AC_LANG_F77_CONFIG])]) -m4_ifndef([AC_LIBTOOL_LANG_GCJ_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_GCJ_CONFIG])]) -m4_ifndef([_LT_AC_LANG_GCJ_CONFIG], [AC_DEFUN([_LT_AC_LANG_GCJ_CONFIG])]) -m4_ifndef([AC_LIBTOOL_LANG_RC_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_RC_CONFIG])]) -m4_ifndef([_LT_AC_LANG_RC_CONFIG], [AC_DEFUN([_LT_AC_LANG_RC_CONFIG])]) -m4_ifndef([AC_LIBTOOL_CONFIG], [AC_DEFUN([AC_LIBTOOL_CONFIG])]) -m4_ifndef([_LT_AC_FILE_LTDLL_C], [AC_DEFUN([_LT_AC_FILE_LTDLL_C])]) +# Compiler flag to generate thread-safe objects. +thread_safe_flag_spec=$lt_[]_LT_AC_TAGVAR(thread_safe_flag_spec, $1) -# pkg.m4 - Macros to locate and utilise pkg-config. -*- Autoconf -*- -# -# Copyright © 2004 Scott James Remnant . -# -# This program is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 2 of the License, or -# (at your option) any later version. -# -# This program is distributed in the hope that it will be useful, but -# WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 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., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. -# -# As a special exception to the GNU General Public License, if you -# distribute this file as part of a program that contains a -# configuration script generated by Autoconf, you may include it under -# the same distribution terms that you use for the rest of that program. +# Library versioning type. +version_type=$version_type -# PKG_PROG_PKG_CONFIG([MIN-VERSION]) -# ---------------------------------- -AC_DEFUN([PKG_PROG_PKG_CONFIG], -[m4_pattern_forbid([^_?PKG_[A-Z_]+$]) -m4_pattern_allow([^PKG_CONFIG(_PATH)?$]) -AC_ARG_VAR([PKG_CONFIG], [path to pkg-config utility])dnl -if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then - AC_PATH_TOOL([PKG_CONFIG], [pkg-config]) -fi -if test -n "$PKG_CONFIG"; then - _pkg_min_version=m4_default([$1], [0.9.0]) - AC_MSG_CHECKING([pkg-config is at least version $_pkg_min_version]) - if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then - AC_MSG_RESULT([yes]) - else - AC_MSG_RESULT([no]) - PKG_CONFIG="" - fi - -fi[]dnl -])# PKG_PROG_PKG_CONFIG +# Format of library name prefix. +libname_spec=$lt_libname_spec -# PKG_CHECK_EXISTS(MODULES, [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND]) -# -# Check to see whether a particular set of modules exists. Similar -# to PKG_CHECK_MODULES(), but does not set variables or print errors. -# -# -# Similar to PKG_CHECK_MODULES, make sure that the first instance of -# this or PKG_CHECK_MODULES is called, or make sure to call -# PKG_CHECK_EXISTS manually -# -------------------------------------------------------------- -AC_DEFUN([PKG_CHECK_EXISTS], -[AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl -if test -n "$PKG_CONFIG" && \ - AC_RUN_LOG([$PKG_CONFIG --exists --print-errors "$1"]); then - m4_ifval([$2], [$2], [:]) -m4_ifvaln([$3], [else - $3])dnl -fi]) +# List of archive names. First name is the real one, the rest are links. +# The last name is the one that the linker finds with -lNAME. +library_names_spec=$lt_library_names_spec +# The coded name of the library, if different from the real name. +soname_spec=$lt_soname_spec -# _PKG_CONFIG([VARIABLE], [COMMAND], [MODULES]) -# --------------------------------------------- -m4_define([_PKG_CONFIG], -[if test -n "$$1"; then - pkg_cv_[]$1="$$1" - elif test -n "$PKG_CONFIG"; then - PKG_CHECK_EXISTS([$3], - [pkg_cv_[]$1=`$PKG_CONFIG --[]$2 "$3" 2>/dev/null`], - [pkg_failed=yes]) - else - pkg_failed=untried -fi[]dnl -])# _PKG_CONFIG +# Commands used to build and install an old-style archive. +RANLIB=$lt_RANLIB +old_archive_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_cmds, $1) +old_postinstall_cmds=$lt_old_postinstall_cmds +old_postuninstall_cmds=$lt_old_postuninstall_cmds -# _PKG_SHORT_ERRORS_SUPPORTED -# ----------------------------- -AC_DEFUN([_PKG_SHORT_ERRORS_SUPPORTED], -[AC_REQUIRE([PKG_PROG_PKG_CONFIG]) -if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then - _pkg_short_errors_supported=yes -else - _pkg_short_errors_supported=no -fi[]dnl -])# _PKG_SHORT_ERRORS_SUPPORTED +# Create an old-style archive from a shared archive. +old_archive_from_new_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_from_new_cmds, $1) +# Create a temporary old-style archive to link instead of a shared archive. +old_archive_from_expsyms_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1) -# PKG_CHECK_MODULES(VARIABLE-PREFIX, MODULES, [ACTION-IF-FOUND], -# [ACTION-IF-NOT-FOUND]) -# -# -# Note that if there is a possibility the first call to -# PKG_CHECK_MODULES might not happen, you should be sure to include an -# explicit call to PKG_PROG_PKG_CONFIG in your configure.ac -# -# -# -------------------------------------------------------------- -AC_DEFUN([PKG_CHECK_MODULES], -[AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl -AC_ARG_VAR([$1][_CFLAGS], [C compiler flags for $1, overriding pkg-config])dnl -AC_ARG_VAR([$1][_LIBS], [linker flags for $1, overriding pkg-config])dnl +# Commands used to build and install a shared archive. +archive_cmds=$lt_[]_LT_AC_TAGVAR(archive_cmds, $1) +archive_expsym_cmds=$lt_[]_LT_AC_TAGVAR(archive_expsym_cmds, $1) +postinstall_cmds=$lt_postinstall_cmds +postuninstall_cmds=$lt_postuninstall_cmds -pkg_failed=no -AC_MSG_CHECKING([for $1]) +# Commands used to build a loadable module (assumed same as above if empty) +module_cmds=$lt_[]_LT_AC_TAGVAR(module_cmds, $1) +module_expsym_cmds=$lt_[]_LT_AC_TAGVAR(module_expsym_cmds, $1) -_PKG_CONFIG([$1][_CFLAGS], [cflags], [$2]) -_PKG_CONFIG([$1][_LIBS], [libs], [$2]) +# Commands to strip libraries. +old_striplib=$lt_old_striplib +striplib=$lt_striplib -m4_define([_PKG_TEXT], [Alternatively, you may set the environment variables $1[]_CFLAGS -and $1[]_LIBS to avoid the need to call pkg-config. -See the pkg-config man page for more details.]) +# Dependencies to place before the objects being linked to create a +# shared library. +predep_objects=$lt_[]_LT_AC_TAGVAR(predep_objects, $1) -if test $pkg_failed = yes; then - _PKG_SHORT_ERRORS_SUPPORTED - if test $_pkg_short_errors_supported = yes; then - $1[]_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "$2" 2>&1` - else - $1[]_PKG_ERRORS=`$PKG_CONFIG --print-errors "$2" 2>&1` - fi - # Put the nasty error message in config.log where it belongs - echo "$$1[]_PKG_ERRORS" >&AS_MESSAGE_LOG_FD +# Dependencies to place after the objects being linked to create a +# shared library. +postdep_objects=$lt_[]_LT_AC_TAGVAR(postdep_objects, $1) - ifelse([$4], , [AC_MSG_ERROR(dnl -[Package requirements ($2) were not met: +# Dependencies to place before the objects being linked to create a +# shared library. +predeps=$lt_[]_LT_AC_TAGVAR(predeps, $1) -$$1_PKG_ERRORS +# Dependencies to place after the objects being linked to create a +# shared library. +postdeps=$lt_[]_LT_AC_TAGVAR(postdeps, $1) -Consider adjusting the PKG_CONFIG_PATH environment variable if you -installed software in a non-standard prefix. +# The directories searched by this compiler when creating a shared +# library +compiler_lib_search_dirs=$lt_[]_LT_AC_TAGVAR(compiler_lib_search_dirs, $1) -_PKG_TEXT -])], - [AC_MSG_RESULT([no]) - $4]) -elif test $pkg_failed = untried; then - ifelse([$4], , [AC_MSG_FAILURE(dnl -[The pkg-config script could not be found or is too old. Make sure it -is in your PATH or set the PKG_CONFIG environment variable to the full -path to pkg-config. +# The library search path used internally by the compiler when linking +# a shared library. +compiler_lib_search_path=$lt_[]_LT_AC_TAGVAR(compiler_lib_search_path, $1) -_PKG_TEXT +# Method to check whether dependent libraries are shared objects. +deplibs_check_method=$lt_deplibs_check_method -To get pkg-config, see .])], - [$4]) -else - $1[]_CFLAGS=$pkg_cv_[]$1[]_CFLAGS - $1[]_LIBS=$pkg_cv_[]$1[]_LIBS - AC_MSG_RESULT([yes]) - ifelse([$3], , :, [$3]) -fi[]dnl -])# PKG_CHECK_MODULES +# Command to use when deplibs_check_method == file_magic. +file_magic_cmd=$lt_file_magic_cmd -# Copyright (C) 2002, 2003, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. -# -# This file 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. +# Flag that allows shared libraries with undefined symbols to be built. +allow_undefined_flag=$lt_[]_LT_AC_TAGVAR(allow_undefined_flag, $1) -# AM_AUTOMAKE_VERSION(VERSION) -# ---------------------------- -# Automake X.Y traces this macro to ensure aclocal.m4 has been -# generated from the m4 files accompanying Automake X.Y. -# (This private macro should not be called outside this file.) -AC_DEFUN([AM_AUTOMAKE_VERSION], -[am__api_version='1.11' -dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to -dnl require some minimum version. Point them to the right macro. -m4_if([$1], [1.11], [], - [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl -]) +# Flag that forces no undefined symbols. +no_undefined_flag=$lt_[]_LT_AC_TAGVAR(no_undefined_flag, $1) -# _AM_AUTOCONF_VERSION(VERSION) -# ----------------------------- -# aclocal traces this macro to find the Autoconf version. -# This is a private macro too. Using m4_define simplifies -# the logic in aclocal, which can simply ignore this definition. -m4_define([_AM_AUTOCONF_VERSION], []) +# Commands used to finish a libtool library installation in a directory. +finish_cmds=$lt_finish_cmds -# AM_SET_CURRENT_AUTOMAKE_VERSION -# ------------------------------- -# Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced. -# This function is AC_REQUIREd by AM_INIT_AUTOMAKE. -AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION], -[AM_AUTOMAKE_VERSION([1.11])dnl -m4_ifndef([AC_AUTOCONF_VERSION], - [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl -_AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))]) +# Same as above, but a single script fragment to be evaled but not shown. +finish_eval=$lt_finish_eval -# AM_AUX_DIR_EXPAND -*- Autoconf -*- +# Take the output of nm and produce a listing of raw symbols and C names. +global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe -# Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc. -# -# This file 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. +# Transform the output of nm in a proper C declaration +global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl -# For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets -# $ac_aux_dir to `$srcdir/foo'. In other projects, it is set to -# `$srcdir', `$srcdir/..', or `$srcdir/../..'. -# -# Of course, Automake must honor this variable whenever it calls a -# tool from the auxiliary directory. The problem is that $srcdir (and -# therefore $ac_aux_dir as well) can be either absolute or relative, -# depending on how configure is run. This is pretty annoying, since -# it makes $ac_aux_dir quite unusable in subdirectories: in the top -# source directory, any form will work fine, but in subdirectories a -# relative path needs to be adjusted first. -# -# $ac_aux_dir/missing -# fails when called from a subdirectory if $ac_aux_dir is relative -# $top_srcdir/$ac_aux_dir/missing -# fails if $ac_aux_dir is absolute, -# fails when called from a subdirectory in a VPATH build with -# a relative $ac_aux_dir -# -# The reason of the latter failure is that $top_srcdir and $ac_aux_dir -# are both prefixed by $srcdir. In an in-source build this is usually -# harmless because $srcdir is `.', but things will broke when you -# start a VPATH build or use an absolute $srcdir. -# -# So we could use something similar to $top_srcdir/$ac_aux_dir/missing, -# iff we strip the leading $srcdir from $ac_aux_dir. That would be: -# am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"` -# and then we would define $MISSING as -# MISSING="\${SHELL} $am_aux_dir/missing" -# This will work as long as MISSING is not called from configure, because -# unfortunately $(top_srcdir) has no meaning in configure. -# However there are other variables, like CC, which are often used in -# configure, and could therefore not use this "fixed" $ac_aux_dir. -# -# Another solution, used here, is to always expand $ac_aux_dir to an -# absolute PATH. The drawback is that using absolute paths prevent a -# configured tree to be moved without reconfiguration. +# Transform the output of nm in a C name address pair +global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address -AC_DEFUN([AM_AUX_DIR_EXPAND], -[dnl Rely on autoconf to set up CDPATH properly. -AC_PREREQ([2.50])dnl -# expand $ac_aux_dir to an absolute path -am_aux_dir=`cd $ac_aux_dir && pwd` -]) +# This is the shared library runtime path variable. +runpath_var=$runpath_var -# AM_CONDITIONAL -*- Autoconf -*- +# This is the shared library path variable. +shlibpath_var=$shlibpath_var -# Copyright (C) 1997, 2000, 2001, 2003, 2004, 2005, 2006, 2008 -# Free Software Foundation, Inc. -# -# This file 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. +# Is shlibpath searched before the hard-coded library search path? +shlibpath_overrides_runpath=$shlibpath_overrides_runpath -# serial 9 +# How to hardcode a shared library path into an executable. +hardcode_action=$_LT_AC_TAGVAR(hardcode_action, $1) -# AM_CONDITIONAL(NAME, SHELL-CONDITION) -# ------------------------------------- -# Define a conditional. -AC_DEFUN([AM_CONDITIONAL], -[AC_PREREQ(2.52)dnl - ifelse([$1], [TRUE], [AC_FATAL([$0: invalid condition: $1])], - [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl -AC_SUBST([$1_TRUE])dnl -AC_SUBST([$1_FALSE])dnl -_AM_SUBST_NOTMAKE([$1_TRUE])dnl -_AM_SUBST_NOTMAKE([$1_FALSE])dnl -m4_define([_AM_COND_VALUE_$1], [$2])dnl -if $2; then - $1_TRUE= - $1_FALSE='#' -else - $1_TRUE='#' - $1_FALSE= -fi -AC_CONFIG_COMMANDS_PRE( -[if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then - AC_MSG_ERROR([[conditional "$1" was never defined. -Usually this means the macro was only invoked conditionally.]]) -fi])]) +# Whether we should hardcode library paths into libraries. +hardcode_into_libs=$hardcode_into_libs -# Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2009 -# Free Software Foundation, Inc. -# -# This file 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. +# Flag to hardcode \$libdir into a binary during linking. +# This must work even if \$libdir does not exist. +hardcode_libdir_flag_spec=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) -# serial 10 +# If ld is used when linking, flag to hardcode \$libdir into +# a binary during linking. This must work even if \$libdir does +# not exist. +hardcode_libdir_flag_spec_ld=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1) -# There are a few dirty hacks below to avoid letting `AC_PROG_CC' be -# written in clear, in which case automake, when reading aclocal.m4, -# will think it sees a *use*, and therefore will trigger all it's -# C support machinery. Also note that it means that autoscan, seeing -# CC etc. in the Makefile, will ask for an AC_PROG_CC use... +# Whether we need a single -rpath flag with a separated argument. +hardcode_libdir_separator=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_separator, $1) +# Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the +# resulting binary. +hardcode_direct=$_LT_AC_TAGVAR(hardcode_direct, $1) -# _AM_DEPENDENCIES(NAME) -# ---------------------- -# See how the compiler implements dependency checking. -# NAME is "CC", "CXX", "GCJ", or "OBJC". -# We try a few techniques and use that to set a single cache variable. -# -# We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was -# modified to invoke _AM_DEPENDENCIES(CC); we would have a circular -# dependency, and given that the user is not expected to run this macro, -# just rely on AC_PROG_CC. -AC_DEFUN([_AM_DEPENDENCIES], -[AC_REQUIRE([AM_SET_DEPDIR])dnl -AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl -AC_REQUIRE([AM_MAKE_INCLUDE])dnl -AC_REQUIRE([AM_DEP_TRACK])dnl +# Set to yes if using the -LDIR flag during linking hardcodes DIR into the +# resulting binary. +hardcode_minus_L=$_LT_AC_TAGVAR(hardcode_minus_L, $1) -ifelse([$1], CC, [depcc="$CC" am_compiler_list=], - [$1], CXX, [depcc="$CXX" am_compiler_list=], - [$1], OBJC, [depcc="$OBJC" am_compiler_list='gcc3 gcc'], - [$1], UPC, [depcc="$UPC" am_compiler_list=], - [$1], GCJ, [depcc="$GCJ" am_compiler_list='gcc3 gcc'], - [depcc="$$1" am_compiler_list=]) +# Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into +# the resulting binary. +hardcode_shlibpath_var=$_LT_AC_TAGVAR(hardcode_shlibpath_var, $1) -AC_CACHE_CHECK([dependency style of $depcc], - [am_cv_$1_dependencies_compiler_type], -[if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then - # We make a subdir and do the tests there. Otherwise we can end up - # making bogus files that we don't know about and never remove. For - # instance it was reported that on HP-UX the gcc test will end up - # making a dummy file named `D' -- because `-MD' means `put the output - # in D'. - mkdir conftest.dir - # Copy depcomp to subdir because otherwise we won't find it if we're - # using a relative directory. - cp "$am_depcomp" conftest.dir - cd conftest.dir - # We will build objects and dependencies in a subdirectory because - # it helps to detect inapplicable dependency modes. For instance - # both Tru64's cc and ICC support -MD to output dependencies as a - # side effect of compilation, but ICC will put the dependencies in - # the current directory while Tru64 will put them in the object - # directory. - mkdir sub +# Set to yes if building a shared library automatically hardcodes DIR into the library +# and all subsequent libraries and executables linked against it. +hardcode_automatic=$_LT_AC_TAGVAR(hardcode_automatic, $1) - am_cv_$1_dependencies_compiler_type=none - if test "$am_compiler_list" = ""; then - am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp` - fi - am__universal=false - m4_case([$1], [CC], - [case " $depcc " in #( - *\ -arch\ *\ -arch\ *) am__universal=true ;; - esac], - [CXX], - [case " $depcc " in #( - *\ -arch\ *\ -arch\ *) am__universal=true ;; - esac]) +# Variables whose values should be saved in libtool wrapper scripts and +# restored at relink time. +variables_saved_for_relink="$variables_saved_for_relink" - for depmode in $am_compiler_list; do - # Setup a source with many dependencies, because some compilers - # like to wrap large dependency lists on column 80 (with \), and - # we should not choose a depcomp mode which is confused by this. - # - # We need to recreate these files for each test, as the compiler may - # overwrite some of them when testing with obscure command lines. - # This happens at least with the AIX C compiler. - : > sub/conftest.c - for i in 1 2 3 4 5 6; do - echo '#include "conftst'$i'.h"' >> sub/conftest.c - # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with - # Solaris 8's {/usr,}/bin/sh. - touch sub/conftst$i.h - done - echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf +# Whether libtool must link a program against all its dependency libraries. +link_all_deplibs=$_LT_AC_TAGVAR(link_all_deplibs, $1) + +# Compile-time system search path for libraries +sys_lib_search_path_spec=$lt_sys_lib_search_path_spec + +# Run-time system search path for libraries +sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec + +# Fix the shell variable \$srcfile for the compiler. +fix_srcfile_path=$lt_fix_srcfile_path + +# Set to yes if exported symbols are required. +always_export_symbols=$_LT_AC_TAGVAR(always_export_symbols, $1) + +# The commands to list exported symbols. +export_symbols_cmds=$lt_[]_LT_AC_TAGVAR(export_symbols_cmds, $1) + +# The commands to extract the exported symbol list from a shared archive. +extract_expsyms_cmds=$lt_extract_expsyms_cmds + +# Symbols that should not be listed in the preloaded symbols. +exclude_expsyms=$lt_[]_LT_AC_TAGVAR(exclude_expsyms, $1) + +# Symbols that must always be exported. +include_expsyms=$lt_[]_LT_AC_TAGVAR(include_expsyms, $1) + +ifelse([$1],[], +[# ### END LIBTOOL CONFIG], +[# ### END LIBTOOL TAG CONFIG: $tagname]) + +__EOF__ + +ifelse([$1],[], [ + case $host_os in + aix3*) + cat <<\EOF >> "$cfgfile" + +# AIX sometimes has problems with the GCC collect2 program. For some +# reason, if we set the COLLECT_NAMES environment variable, the problems +# vanish in a puff of smoke. +if test "X${COLLECT_NAMES+set}" != Xset; then + COLLECT_NAMES= + export COLLECT_NAMES +fi +EOF + ;; + esac - # We check with `-c' and `-o' for the sake of the "dashmstdout" - # mode. It turns out that the SunPro C++ compiler does not properly - # handle `-M -o', and we need to detect this. Also, some Intel - # versions had trouble with output in subdirs - am__obj=sub/conftest.${OBJEXT-o} - am__minus_obj="-o $am__obj" - case $depmode in - gcc) - # This depmode causes a compiler race in universal mode. - test "$am__universal" = false || continue - ;; - nosideeffect) - # after this tag, mechanisms are not by side-effect, so they'll - # only be used when explicitly requested - if test "x$enable_dependency_tracking" = xyes; then - continue - else - break - fi - ;; - msvisualcpp | msvcmsys) - # This compiler won't grok `-c -o', but also, the minuso test has - # not run yet. These depmodes are late enough in the game, and - # so weak that their functioning should not be impacted. - am__obj=conftest.${OBJEXT-o} - am__minus_obj= - ;; - none) break ;; - esac - if depmode=$depmode \ - source=sub/conftest.c object=$am__obj \ - depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ - $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \ - >/dev/null 2>conftest.err && - grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 && - grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && - grep $am__obj sub/conftest.Po > /dev/null 2>&1 && - ${MAKE-make} -s -f confmf > /dev/null 2>&1; then - # icc doesn't choke on unknown options, it will just issue warnings - # or remarks (even with -Werror). So we grep stderr for any message - # that says an option was ignored or not supported. - # When given -MP, icc 7.0 and 7.1 complain thusly: - # icc: Command line warning: ignoring option '-M'; no argument required - # The diagnosis changed in icc 8.0: - # icc: Command line remark: option '-MP' not supported - if (grep 'ignoring option' conftest.err || - grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else - am_cv_$1_dependencies_compiler_type=$depmode - break - fi - fi - done + # We use sed instead of cat because bash on DJGPP gets confused if + # if finds mixed CR/LF and LF-only lines. Since sed operates in + # text mode, it properly converts lines to CR/LF. This bash problem + # is reportedly fixed, but why not run on old versions too? + sed '$q' "$ltmain" >> "$cfgfile" || (rm -f "$cfgfile"; exit 1) - cd .. - rm -rf conftest.dir + mv -f "$cfgfile" "$ofile" || \ + (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") + chmod +x "$ofile" +]) else - am_cv_$1_dependencies_compiler_type=none + # If there is no Makefile yet, we rely on a make rule to execute + # `config.status --recheck' to rerun these tests and create the + # libtool script then. + ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'` + if test -f "$ltmain_in"; then + test -f Makefile && make "$ltmain" + fi fi -]) -AC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type]) -AM_CONDITIONAL([am__fastdep$1], [ - test "x$enable_dependency_tracking" != xno \ - && test "$am_cv_$1_dependencies_compiler_type" = gcc3]) -]) +])# AC_LIBTOOL_CONFIG -# AM_SET_DEPDIR -# ------------- -# Choose a directory name for dependency files. -# This macro is AC_REQUIREd in _AM_DEPENDENCIES -AC_DEFUN([AM_SET_DEPDIR], -[AC_REQUIRE([AM_SET_LEADING_DOT])dnl -AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl -]) +# AC_LIBTOOL_PROG_COMPILER_NO_RTTI([TAGNAME]) +# ------------------------------------------- +AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_NO_RTTI], +[AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl +_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= -# AM_DEP_TRACK -# ------------ -AC_DEFUN([AM_DEP_TRACK], -[AC_ARG_ENABLE(dependency-tracking, -[ --disable-dependency-tracking speeds up one-time build - --enable-dependency-tracking do not reject slow dependency extractors]) -if test "x$enable_dependency_tracking" != xno; then - am_depcomp="$ac_aux_dir/depcomp" - AMDEPBACKSLASH='\' +if test "$GCC" = yes; then + _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' + + AC_LIBTOOL_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions], + lt_cv_prog_compiler_rtti_exceptions, + [-fno-rtti -fno-exceptions], [], + [_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"]) fi -AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno]) -AC_SUBST([AMDEPBACKSLASH])dnl -_AM_SUBST_NOTMAKE([AMDEPBACKSLASH])dnl -]) +])# AC_LIBTOOL_PROG_COMPILER_NO_RTTI -# Generate code to set up dependency tracking. -*- Autoconf -*- -# Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2008 -# Free Software Foundation, Inc. -# -# This file 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. +# AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE +# --------------------------------- +AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE], +[AC_REQUIRE([AC_CANONICAL_HOST]) +AC_REQUIRE([LT_AC_PROG_SED]) +AC_REQUIRE([AC_PROG_NM]) +AC_REQUIRE([AC_OBJEXT]) +# Check for command to grab the raw symbol name followed by C symbol from nm. +AC_MSG_CHECKING([command to parse $NM output from $compiler object]) +AC_CACHE_VAL([lt_cv_sys_global_symbol_pipe], +[ +# These are sane defaults that work on at least a few old systems. +# [They come from Ultrix. What could be older than Ultrix?!! ;)] -#serial 5 +# Character class describing NM global symbol codes. +symcode='[[BCDEGRST]]' -# _AM_OUTPUT_DEPENDENCY_COMMANDS -# ------------------------------ -AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS], -[{ - # Autoconf 2.62 quotes --file arguments for eval, but not when files - # are listed without --file. Let's play safe and only enable the eval - # if we detect the quoting. - case $CONFIG_FILES in - *\'*) eval set x "$CONFIG_FILES" ;; - *) set x $CONFIG_FILES ;; - esac - shift - for mf - do - # Strip MF so we end up with the name of the file. - mf=`echo "$mf" | sed -e 's/:.*$//'` - # Check whether this is an Automake generated Makefile or not. - # We used to match only the files named `Makefile.in', but - # some people rename them; so instead we look at the file content. - # Grep'ing the first line is not enough: some people post-process - # each Makefile.in and add a new line on top of each file to say so. - # Grep'ing the whole file is not good either: AIX grep has a line - # limit of 2048, but all sed's we know have understand at least 4000. - if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then - dirpart=`AS_DIRNAME("$mf")` - else - continue - fi - # Extract the definition of DEPDIR, am__include, and am__quote - # from the Makefile without running `make'. - DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"` - test -z "$DEPDIR" && continue - am__include=`sed -n 's/^am__include = //p' < "$mf"` - test -z "am__include" && continue - am__quote=`sed -n 's/^am__quote = //p' < "$mf"` - # When using ansi2knr, U may be empty or an underscore; expand it - U=`sed -n 's/^U = //p' < "$mf"` - # Find all dependency output files, they are included files with - # $(DEPDIR) in their names. We invoke sed twice because it is the - # simplest approach to changing $(DEPDIR) to its actual value in the - # expansion. - for file in `sed -n " - s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \ - sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do - # Make sure the directory exists. - test -f "$dirpart/$file" && continue - fdir=`AS_DIRNAME(["$file"])` - AS_MKDIR_P([$dirpart/$fdir]) - # echo "creating $dirpart/$file" - echo '# dummy' > "$dirpart/$file" - done - done -} -])# _AM_OUTPUT_DEPENDENCY_COMMANDS +# Regexp to match symbols that can be accessed directly from C. +sympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)' +# Transform an extracted symbol line into a proper C declaration +lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^. .* \(.*\)$/extern int \1;/p'" -# AM_OUTPUT_DEPENDENCY_COMMANDS -# ----------------------------- -# This macro should only be invoked once -- use via AC_REQUIRE. -# -# This code is only required when automatic dependency tracking -# is enabled. FIXME. This creates each `.P' file that we will -# need in order to bootstrap the dependency handling code. -AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS], -[AC_CONFIG_COMMANDS([depfiles], - [test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS], - [AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"]) -]) +# Transform an extracted symbol line into symbol name and symbol address +lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'" -# Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005 -# Free Software Foundation, Inc. -# -# This file 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. +# Define system-specific variables. +case $host_os in +aix*) + symcode='[[BCDT]]' + ;; +cygwin* | mingw* | pw32*) + symcode='[[ABCDGISTW]]' + ;; +hpux*) # Its linker distinguishes data from code symbols + if test "$host_cpu" = ia64; then + symcode='[[ABCDEGRST]]' + fi + lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'" + lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'" + ;; +linux* | k*bsd*-gnu) + if test "$host_cpu" = ia64; then + symcode='[[ABCDGIRSTW]]' + lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'" + lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'" + fi + ;; +irix* | nonstopux*) + symcode='[[BCDEGRST]]' + ;; +osf*) + symcode='[[BCDEGQRST]]' + ;; +solaris*) + symcode='[[BDRT]]' + ;; +sco3.2v5*) + symcode='[[DT]]' + ;; +sysv4.2uw2*) + symcode='[[DT]]' + ;; +sysv5* | sco5v6* | unixware* | OpenUNIX*) + symcode='[[ABDT]]' + ;; +sysv4) + symcode='[[DFNSTU]]' + ;; +esac + +# Handle CRLF in mingw tool chain +opt_cr= +case $build_os in +mingw*) + opt_cr=`echo 'x\{0,1\}' | tr x '\015'` # option cr in regexp + ;; +esac + +# If we're using GNU nm, then use its standard symbol codes. +case `$NM -V 2>&1` in +*GNU* | *'with BFD'*) + symcode='[[ABCDGIRSTW]]' ;; +esac + +# Try without a prefix undercore, then with it. +for ac_symprfx in "" "_"; do + + # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol. + symxfrm="\\1 $ac_symprfx\\2 \\2" + + # Write the raw and C identifiers. + lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" + + # Check to see that the pipe works correctly. + pipe_works=no + + rm -f conftest* + cat > conftest.$ac_ext < $nlist) && test -s "$nlist"; then + # Try sorting and uniquifying the output. + if sort "$nlist" | uniq > "$nlist"T; then + mv -f "$nlist"T "$nlist" + else + rm -f "$nlist"T + fi -# AM_CONFIG_HEADER is obsolete. It has been replaced by AC_CONFIG_HEADERS. -AU_DEFUN([AM_CONFIG_HEADER], [AC_CONFIG_HEADERS($@)]) + # Make sure that we snagged all the symbols we need. + if grep ' nm_test_var$' "$nlist" >/dev/null; then + if grep ' nm_test_func$' "$nlist" >/dev/null; then + cat < conftest.$ac_ext +#ifdef __cplusplus +extern "C" { +#endif -# Do all the work for Automake. -*- Autoconf -*- +EOF + # Now generate the symbol file. + eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | grep -v main >> conftest.$ac_ext' -# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, -# 2005, 2006, 2008, 2009 Free Software Foundation, Inc. -# -# This file 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. + cat <> conftest.$ac_ext +#if defined (__STDC__) && __STDC__ +# define lt_ptr_t void * +#else +# define lt_ptr_t char * +# define const +#endif -# serial 16 +/* The mapping between symbol names and symbols. */ +const struct { + const char *name; + lt_ptr_t address; +} +lt_preloaded_symbols[[]] = +{ +EOF + $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (lt_ptr_t) \&\2},/" < "$nlist" | grep -v main >> conftest.$ac_ext + cat <<\EOF >> conftest.$ac_ext + {0, (lt_ptr_t) 0} +}; -# This macro actually does too much. Some checks are only needed if -# your package does certain things. But this isn't really a big deal. +#ifdef __cplusplus +} +#endif +EOF + # Now try linking the two files. + mv conftest.$ac_objext conftstm.$ac_objext + lt_save_LIBS="$LIBS" + lt_save_CFLAGS="$CFLAGS" + LIBS="conftstm.$ac_objext" + CFLAGS="$CFLAGS$_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)" + if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext}; then + pipe_works=yes + fi + LIBS="$lt_save_LIBS" + CFLAGS="$lt_save_CFLAGS" + else + echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD + fi + else + echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD + fi + else + echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD + fi + else + echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD + cat conftest.$ac_ext >&5 + fi + rm -rf conftest* conftst* -# AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE]) -# AM_INIT_AUTOMAKE([OPTIONS]) -# ----------------------------------------------- -# The call with PACKAGE and VERSION arguments is the old style -# call (pre autoconf-2.50), which is being phased out. PACKAGE -# and VERSION should now be passed to AC_INIT and removed from -# the call to AM_INIT_AUTOMAKE. -# We support both call styles for the transition. After -# the next Automake release, Autoconf can make the AC_INIT -# arguments mandatory, and then we can depend on a new Autoconf -# release and drop the old call support. -AC_DEFUN([AM_INIT_AUTOMAKE], -[AC_PREREQ([2.62])dnl -dnl Autoconf wants to disallow AM_ names. We explicitly allow -dnl the ones we care about. -m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl -AC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl -AC_REQUIRE([AC_PROG_INSTALL])dnl -if test "`cd $srcdir && pwd`" != "`pwd`"; then - # Use -I$(srcdir) only when $(srcdir) != ., so that make's output - # is not polluted with repeated "-I." - AC_SUBST([am__isrc], [' -I$(srcdir)'])_AM_SUBST_NOTMAKE([am__isrc])dnl - # test to see if srcdir already configured - if test -f $srcdir/config.status; then - AC_MSG_ERROR([source directory already configured; run "make distclean" there first]) + # Do not use the global_symbol_pipe unless it works. + if test "$pipe_works" = yes; then + break + else + lt_cv_sys_global_symbol_pipe= fi +done +]) +if test -z "$lt_cv_sys_global_symbol_pipe"; then + lt_cv_sys_global_symbol_to_cdecl= +fi +if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then + AC_MSG_RESULT(failed) +else + AC_MSG_RESULT(ok) fi +]) # AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE -# test whether we have cygpath -if test -z "$CYGPATH_W"; then - if (cygpath --version) >/dev/null 2>/dev/null; then - CYGPATH_W='cygpath -w' + +# AC_LIBTOOL_PROG_COMPILER_PIC([TAGNAME]) +# --------------------------------------- +AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_PIC], +[_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)= +_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)= +_LT_AC_TAGVAR(lt_prog_compiler_static, $1)= + +AC_MSG_CHECKING([for $compiler option to produce PIC]) + ifelse([$1],[CXX],[ + # C++ specific cases for pic, static, wl, etc. + if test "$GXX" = yes; then + _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static' + + case $host_os in + aix*) + # All AIX code is PIC. + if test "$host_cpu" = ia64; then + # AIX 5 now supports IA64 processor + _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + fi + ;; + amigaos*) + # FIXME: we need at least 68020 code to build shared libraries, but + # adding the `-m68020' flag to GCC prevents building anything better, + # like `-m68040'. + _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' + ;; + beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) + # PIC is the default for these OSes. + ;; + mingw* | cygwin* | os2* | pw32*) + # This hack is so that the source file can tell whether it is being + # built for inclusion in a dll (and should export symbols for example). + # Although the cygwin gcc ignores -fPIC, still need this for old-style + # (--disable-auto-import) libraries + m4_if([$1], [GCJ], [], + [_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) + ;; + darwin* | rhapsody*) + # PIC is the default on this platform + # Common symbols not allowed in MH_DYLIB files + _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' + ;; + *djgpp*) + # DJGPP does not support shared libraries at all + _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)= + ;; + interix[[3-9]]*) + # Interix 3.x gcc -fpic/-fPIC options generate broken code. + # Instead, we relocate shared libraries at runtime. + ;; + sysv4*MP*) + if test -d /usr/nec; then + _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic + fi + ;; + hpux*) + # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but + # not for PA HP-UX. + case $host_cpu in + hppa*64*|ia64*) + ;; + *) + _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + ;; + esac + ;; + *) + _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + ;; + esac else - CYGPATH_W=echo + case $host_os in + aix[[4-9]]*) + # All AIX code is PIC. + if test "$host_cpu" = ia64; then + # AIX 5 now supports IA64 processor + _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + else + _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' + fi + ;; + chorus*) + case $cc_basename in + cxch68*) + # Green Hills C++ Compiler + # _LT_AC_TAGVAR(lt_prog_compiler_static, $1)="--no_auto_instantiation -u __main -u __premain -u _abort -r $COOL_DIR/lib/libOrb.a $MVME_DIR/lib/CC/libC.a $MVME_DIR/lib/classix/libcx.s.a" + ;; + esac + ;; + darwin*) + # PIC is the default on this platform + # Common symbols not allowed in MH_DYLIB files + case $cc_basename in + xlc*) + _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-qnocommon' + _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + ;; + esac + ;; + dgux*) + case $cc_basename in + ec++*) + _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + ;; + ghcx*) + # Green Hills C++ Compiler + _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic' + ;; + *) + ;; + esac + ;; + freebsd* | dragonfly*) + # FreeBSD uses GNU C++ + ;; + hpux9* | hpux10* | hpux11*) + case $cc_basename in + CC*) + _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' + if test "$host_cpu" != ia64; then + _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z' + fi + ;; + aCC*) + _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' + case $host_cpu in + hppa*64*|ia64*) + # +Z the default + ;; + *) + _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z' + ;; + esac + ;; + *) + ;; + esac + ;; + interix*) + # This is c89, which is MS Visual C++ (no shared libs) + # Anyone wants to do a port? + ;; + irix5* | irix6* | nonstopux*) + case $cc_basename in + CC*) + _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' + # CC pic flag -KPIC is the default. + ;; + *) + ;; + esac + ;; + linux* | k*bsd*-gnu) + case $cc_basename in + KCC*) + # KAI C++ Compiler + _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' + _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + ;; + icpc* | ecpc*) + # Intel C++ + _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static' + ;; + pgCC* | pgcpp*) + # Portland Group C++ compiler. + _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' + _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; + cxx*) + # Compaq C++ + # Make sure the PIC flag is empty. It appears that all Alpha + # Linux and Compaq Tru64 Unix objects are PIC. + _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)= + _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' + ;; + *) + case `$CC -V 2>&1 | sed 5q` in + *Sun\ C*) + # Sun C++ 5.9 + _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' + ;; + esac + ;; + esac + ;; + lynxos*) + ;; + m88k*) + ;; + mvs*) + case $cc_basename in + cxx*) + _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall' + ;; + *) + ;; + esac + ;; + netbsd*) + ;; + osf3* | osf4* | osf5*) + case $cc_basename in + KCC*) + _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' + ;; + RCC*) + # Rational C++ 2.4.1 + _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic' + ;; + cxx*) + # Digital/Compaq C++ + _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + # Make sure the PIC flag is empty. It appears that all Alpha + # Linux and Compaq Tru64 Unix objects are PIC. + _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)= + _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' + ;; + *) + ;; + esac + ;; + psos*) + ;; + solaris*) + case $cc_basename in + CC*) + # Sun C++ 4.2, 5.x and Centerline C++ + _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' + ;; + gcx*) + # Green Hills C++ Compiler + _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' + ;; + *) + ;; + esac + ;; + sunos4*) + case $cc_basename in + CC*) + # Sun C++ 4.x + _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic' + _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; + lcc*) + # Lucid + _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic' + ;; + *) + ;; + esac + ;; + tandem*) + case $cc_basename in + NCC*) + # NonStop-UX NCC 3.20 + _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + ;; + *) + ;; + esac + ;; + sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) + case $cc_basename in + CC*) + _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; + esac + ;; + vxworks*) + ;; + *) + _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no + ;; + esac fi -fi -AC_SUBST([CYGPATH_W]) - -# Define the identity of the package. -dnl Distinguish between old-style and new-style calls. -m4_ifval([$2], -[m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl - AC_SUBST([PACKAGE], [$1])dnl - AC_SUBST([VERSION], [$2])], -[_AM_SET_OPTIONS([$1])dnl -dnl Diagnose old-style AC_INIT with new-style AM_AUTOMAKE_INIT. -m4_if(m4_ifdef([AC_PACKAGE_NAME], 1)m4_ifdef([AC_PACKAGE_VERSION], 1), 11,, - [m4_fatal([AC_INIT should be called with package and version arguments])])dnl - AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl - AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl - -_AM_IF_OPTION([no-define],, -[AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package]) - AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package])])dnl +], +[ + if test "$GCC" = yes; then + _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static' -# Some tools Automake needs. -AC_REQUIRE([AM_SANITY_CHECK])dnl -AC_REQUIRE([AC_ARG_PROGRAM])dnl -AM_MISSING_PROG(ACLOCAL, aclocal-${am__api_version}) -AM_MISSING_PROG(AUTOCONF, autoconf) -AM_MISSING_PROG(AUTOMAKE, automake-${am__api_version}) -AM_MISSING_PROG(AUTOHEADER, autoheader) -AM_MISSING_PROG(MAKEINFO, makeinfo) -AC_REQUIRE([AM_PROG_INSTALL_SH])dnl -AC_REQUIRE([AM_PROG_INSTALL_STRIP])dnl -AC_REQUIRE([AM_PROG_MKDIR_P])dnl -# We need awk for the "check" target. The system "awk" is bad on -# some platforms. -AC_REQUIRE([AC_PROG_AWK])dnl -AC_REQUIRE([AC_PROG_MAKE_SET])dnl -AC_REQUIRE([AM_SET_LEADING_DOT])dnl -_AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])], - [_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])], - [_AM_PROG_TAR([v7])])]) -_AM_IF_OPTION([no-dependencies],, -[AC_PROVIDE_IFELSE([AC_PROG_CC], - [_AM_DEPENDENCIES(CC)], - [define([AC_PROG_CC], - defn([AC_PROG_CC])[_AM_DEPENDENCIES(CC)])])dnl -AC_PROVIDE_IFELSE([AC_PROG_CXX], - [_AM_DEPENDENCIES(CXX)], - [define([AC_PROG_CXX], - defn([AC_PROG_CXX])[_AM_DEPENDENCIES(CXX)])])dnl -AC_PROVIDE_IFELSE([AC_PROG_OBJC], - [_AM_DEPENDENCIES(OBJC)], - [define([AC_PROG_OBJC], - defn([AC_PROG_OBJC])[_AM_DEPENDENCIES(OBJC)])])dnl -]) -_AM_IF_OPTION([silent-rules], [AC_REQUIRE([AM_SILENT_RULES])])dnl -dnl The `parallel-tests' driver may need to know about EXEEXT, so add the -dnl `am__EXEEXT' conditional if _AM_COMPILER_EXEEXT was seen. This macro -dnl is hooked onto _AC_COMPILER_EXEEXT early, see below. -AC_CONFIG_COMMANDS_PRE(dnl -[m4_provide_if([_AM_COMPILER_EXEEXT], - [AM_CONDITIONAL([am__EXEEXT], [test -n "$EXEEXT"])])])dnl -]) + case $host_os in + aix*) + # All AIX code is PIC. + if test "$host_cpu" = ia64; then + # AIX 5 now supports IA64 processor + _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + fi + ;; -dnl Hook into `_AC_COMPILER_EXEEXT' early to learn its expansion. Do not -dnl add the conditional right here, as _AC_COMPILER_EXEEXT may be further -dnl mangled by Autoconf and run in a shell conditional statement. -m4_define([_AC_COMPILER_EXEEXT], -m4_defn([_AC_COMPILER_EXEEXT])[m4_provide([_AM_COMPILER_EXEEXT])]) + amigaos*) + # FIXME: we need at least 68020 code to build shared libraries, but + # adding the `-m68020' flag to GCC prevents building anything better, + # like `-m68040'. + _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' + ;; + beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) + # PIC is the default for these OSes. + ;; -# When config.status generates a header, we must update the stamp-h file. -# This file resides in the same directory as the config header -# that is generated. The stamp files are numbered to have different names. + mingw* | cygwin* | pw32* | os2*) + # This hack is so that the source file can tell whether it is being + # built for inclusion in a dll (and should export symbols for example). + # Although the cygwin gcc ignores -fPIC, still need this for old-style + # (--disable-auto-import) libraries + m4_if([$1], [GCJ], [], + [_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) + ;; -# Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the -# loop where config.status creates the headers, so we can generate -# our stamp files there. -AC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK], -[# Compute $1's index in $config_headers. -_am_arg=$1 -_am_stamp_count=1 -for _am_header in $config_headers :; do - case $_am_header in - $_am_arg | $_am_arg:* ) - break ;; - * ) - _am_stamp_count=`expr $_am_stamp_count + 1` ;; - esac -done -echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count]) + darwin* | rhapsody*) + # PIC is the default on this platform + # Common symbols not allowed in MH_DYLIB files + _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' + ;; -# Copyright (C) 2001, 2003, 2005, 2008 Free Software Foundation, Inc. -# -# This file 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. + interix[[3-9]]*) + # Interix 3.x gcc -fpic/-fPIC options generate broken code. + # Instead, we relocate shared libraries at runtime. + ;; -# AM_PROG_INSTALL_SH -# ------------------ -# Define $install_sh. -AC_DEFUN([AM_PROG_INSTALL_SH], -[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl -if test x"${install_sh}" != xset; then - case $am_aux_dir in - *\ * | *\ *) - install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;; - *) - install_sh="\${SHELL} $am_aux_dir/install-sh" - esac -fi -AC_SUBST(install_sh)]) + msdosdjgpp*) + # Just because we use GCC doesn't mean we suddenly get shared libraries + # on systems that don't support them. + _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no + enable_shared=no + ;; -# Copyright (C) 2003, 2005 Free Software Foundation, Inc. -# -# This file 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. + sysv4*MP*) + if test -d /usr/nec; then + _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic + fi + ;; -# serial 2 + hpux*) + # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but + # not for PA HP-UX. + case $host_cpu in + hppa*64*|ia64*) + # +Z the default + ;; + *) + _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + ;; + esac + ;; -# Check whether the underlying file-system supports filenames -# with a leading dot. For instance MS-DOS doesn't. -AC_DEFUN([AM_SET_LEADING_DOT], -[rm -rf .tst 2>/dev/null -mkdir .tst 2>/dev/null -if test -d .tst; then - am__leading_dot=. -else - am__leading_dot=_ -fi -rmdir .tst 2>/dev/null -AC_SUBST([am__leading_dot])]) + *) + _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + ;; + esac + else + # PORTME Check for flag to pass linker flags through the system compiler. + case $host_os in + aix*) + _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + if test "$host_cpu" = ia64; then + # AIX 5 now supports IA64 processor + _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + else + _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' + fi + ;; + darwin*) + # PIC is the default on this platform + # Common symbols not allowed in MH_DYLIB files + case $cc_basename in + xlc*) + _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-qnocommon' + _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + ;; + esac + ;; -# Add --enable-maintainer-mode option to configure. -*- Autoconf -*- -# From Jim Meyering + mingw* | cygwin* | pw32* | os2*) + # This hack is so that the source file can tell whether it is being + # built for inclusion in a dll (and should export symbols for example). + m4_if([$1], [GCJ], [], + [_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) + ;; -# Copyright (C) 1996, 1998, 2000, 2001, 2002, 2003, 2004, 2005, 2008 -# Free Software Foundation, Inc. -# -# This file 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. + hpux9* | hpux10* | hpux11*) + _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but + # not for PA HP-UX. + case $host_cpu in + hppa*64*|ia64*) + # +Z the default + ;; + *) + _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z' + ;; + esac + # Is there a better lt_prog_compiler_static that works with the bundled CC? + _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' + ;; -# serial 5 + irix5* | irix6* | nonstopux*) + _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + # PIC (with -KPIC) is the default. + _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' + ;; -# AM_MAINTAINER_MODE([DEFAULT-MODE]) -# ---------------------------------- -# Control maintainer-specific portions of Makefiles. -# Default is to disable them, unless `enable' is passed literally. -# For symmetry, `disable' may be passed as well. Anyway, the user -# can override the default with the --enable/--disable switch. -AC_DEFUN([AM_MAINTAINER_MODE], -[m4_case(m4_default([$1], [disable]), - [enable], [m4_define([am_maintainer_other], [disable])], - [disable], [m4_define([am_maintainer_other], [enable])], - [m4_define([am_maintainer_other], [enable]) - m4_warn([syntax], [unexpected argument to AM@&t@_MAINTAINER_MODE: $1])]) -AC_MSG_CHECKING([whether to am_maintainer_other maintainer-specific portions of Makefiles]) - dnl maintainer-mode's default is 'disable' unless 'enable' is passed - AC_ARG_ENABLE([maintainer-mode], -[ --][am_maintainer_other][-maintainer-mode am_maintainer_other make rules and dependencies not useful - (and sometimes confusing) to the casual installer], - [USE_MAINTAINER_MODE=$enableval], - [USE_MAINTAINER_MODE=]m4_if(am_maintainer_other, [enable], [no], [yes])) - AC_MSG_RESULT([$USE_MAINTAINER_MODE]) - AM_CONDITIONAL([MAINTAINER_MODE], [test $USE_MAINTAINER_MODE = yes]) - MAINT=$MAINTAINER_MODE_TRUE - AC_SUBST([MAINT])dnl -] -) + newsos6) + _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; -AU_DEFUN([jm_MAINTAINER_MODE], [AM_MAINTAINER_MODE]) + linux* | k*bsd*-gnu) + case $cc_basename in + icc* | ecc*) + _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static' + ;; + pgcc* | pgf77* | pgf90* | pgf95*) + # Portland Group compilers (*not* the Pentium gcc compiler, + # which looks to be a dead project) + _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' + _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; + ccc*) + _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + # All Alpha code is PIC. + _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' + ;; + *) + case `$CC -V 2>&1 | sed 5q` in + *Sun\ C*) + # Sun C 5.9 + _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + ;; + *Sun\ F*) + # Sun Fortran 8.3 passes all unrecognized flags to the linker + _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='' + ;; + esac + ;; + esac + ;; -# Check to see how 'make' treats includes. -*- Autoconf -*- + osf3* | osf4* | osf5*) + _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + # All OSF/1 code is PIC. + _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' + ;; -# Copyright (C) 2001, 2002, 2003, 2005, 2009 Free Software Foundation, Inc. -# -# This file 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. + rdos*) + _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' + ;; -# serial 4 + solaris*) + _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + case $cc_basename in + f77* | f90* | f95*) + _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';; + *) + _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';; + esac + ;; -# AM_MAKE_INCLUDE() -# ----------------- -# Check to see how make treats includes. -AC_DEFUN([AM_MAKE_INCLUDE], -[am_make=${MAKE-make} -cat > confinc << 'END' -am__doit: - @echo this is the am__doit target -.PHONY: am__doit -END -# If we don't find an include directive, just comment out the code. -AC_MSG_CHECKING([for style of include used by $am_make]) -am__include="#" -am__quote= -_am_result=none -# First try GNU make style include. -echo "include confinc" > confmf -# Ignore all kinds of additional output from `make'. -case `$am_make -s -f confmf 2> /dev/null` in #( -*the\ am__doit\ target*) - am__include=include - am__quote= - _am_result=GNU - ;; -esac -# Now try BSD make style include. -if test "$am__include" = "#"; then - echo '.include "confinc"' > confmf - case `$am_make -s -f confmf 2> /dev/null` in #( - *the\ am__doit\ target*) - am__include=.include - am__quote="\"" - _am_result=BSD - ;; - esac -fi -AC_SUBST([am__include]) -AC_SUBST([am__quote]) -AC_MSG_RESULT([$_am_result]) -rm -f confinc confmf -]) + sunos4*) + _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' + _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' + _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; -# Fake the existence of programs that GNU maintainers use. -*- Autoconf -*- + sysv4 | sysv4.2uw2* | sysv4.3*) + _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; -# Copyright (C) 1997, 1999, 2000, 2001, 2003, 2004, 2005, 2008 -# Free Software Foundation, Inc. -# -# This file 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. + sysv4*MP*) + if test -d /usr/nec ;then + _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic' + _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + fi + ;; -# serial 6 + sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) + _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' + _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; -# AM_MISSING_PROG(NAME, PROGRAM) -# ------------------------------ -AC_DEFUN([AM_MISSING_PROG], -[AC_REQUIRE([AM_MISSING_HAS_RUN]) -$1=${$1-"${am_missing_run}$2"} -AC_SUBST($1)]) + unicos*) + _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no + ;; + uts4*) + _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic' + _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; -# AM_MISSING_HAS_RUN -# ------------------ -# Define MISSING if not defined so far and test if it supports --run. -# If it does, set am_missing_run to use it, otherwise, to nothing. -AC_DEFUN([AM_MISSING_HAS_RUN], -[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl -AC_REQUIRE_AUX_FILE([missing])dnl -if test x"${MISSING+set}" != xset; then - case $am_aux_dir in - *\ * | *\ *) - MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;; - *) - MISSING="\${SHELL} $am_aux_dir/missing" ;; - esac -fi -# Use eval to expand $SHELL -if eval "$MISSING --run true"; then - am_missing_run="$MISSING --run " -else - am_missing_run= - AC_MSG_WARN([`missing' script is too old or missing]) -fi + *) + _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no + ;; + esac + fi ]) +AC_MSG_RESULT([$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)]) -# Copyright (C) 2003, 2004, 2005, 2006 Free Software Foundation, Inc. # -# This file 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. - -# AM_PROG_MKDIR_P -# --------------- -# Check for `mkdir -p'. -AC_DEFUN([AM_PROG_MKDIR_P], -[AC_PREREQ([2.60])dnl -AC_REQUIRE([AC_PROG_MKDIR_P])dnl -dnl Automake 1.8 to 1.9.6 used to define mkdir_p. We now use MKDIR_P, -dnl while keeping a definition of mkdir_p for backward compatibility. -dnl @MKDIR_P@ is magic: AC_OUTPUT adjusts its value for each Makefile. -dnl However we cannot define mkdir_p as $(MKDIR_P) for the sake of -dnl Makefile.ins that do not define MKDIR_P, so we do our own -dnl adjustment using top_builddir (which is defined more often than -dnl MKDIR_P). -AC_SUBST([mkdir_p], ["$MKDIR_P"])dnl -case $mkdir_p in - [[\\/$]]* | ?:[[\\/]]*) ;; - */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;; +# Check to make sure the PIC flag actually works. +# +if test -n "$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)"; then + AC_LIBTOOL_COMPILER_OPTION([if $compiler PIC flag $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) works], + _LT_AC_TAGVAR(lt_cv_prog_compiler_pic_works, $1), + [$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)ifelse([$1],[],[ -DPIC],[ifelse([$1],[CXX],[ -DPIC],[])])], [], + [case $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) in + "" | " "*) ;; + *) _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)" ;; + esac], + [_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)= + _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no]) +fi +case $host_os in + # For platforms which do not support PIC, -DPIC is meaningless: + *djgpp*) + _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)= + ;; + *) + _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)ifelse([$1],[],[ -DPIC],[ifelse([$1],[CXX],[ -DPIC],[])])" + ;; esac -]) - -# Helper functions for option handling. -*- Autoconf -*- -# Copyright (C) 2001, 2002, 2003, 2005, 2008 Free Software Foundation, Inc. # -# This file 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. - -# serial 4 - -# _AM_MANGLE_OPTION(NAME) -# ----------------------- -AC_DEFUN([_AM_MANGLE_OPTION], -[[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])]) - -# _AM_SET_OPTION(NAME) -# ------------------------------ -# Set option NAME. Presently that only means defining a flag for this option. -AC_DEFUN([_AM_SET_OPTION], -[m4_define(_AM_MANGLE_OPTION([$1]), 1)]) - -# _AM_SET_OPTIONS(OPTIONS) -# ---------------------------------- -# OPTIONS is a space-separated list of Automake options. -AC_DEFUN([_AM_SET_OPTIONS], -[m4_foreach_w([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])]) +# Check to make sure the static flag actually works. +# +wl=$_LT_AC_TAGVAR(lt_prog_compiler_wl, $1) eval lt_tmp_static_flag=\"$_LT_AC_TAGVAR(lt_prog_compiler_static, $1)\" +AC_LIBTOOL_LINKER_OPTION([if $compiler static flag $lt_tmp_static_flag works], + _LT_AC_TAGVAR(lt_cv_prog_compiler_static_works, $1), + $lt_tmp_static_flag, + [], + [_LT_AC_TAGVAR(lt_prog_compiler_static, $1)=]) +]) -# _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET]) -# ------------------------------------------- -# Execute IF-SET if OPTION is set, IF-NOT-SET otherwise. -AC_DEFUN([_AM_IF_OPTION], -[m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])]) -# Check to make sure that the build environment is sane. -*- Autoconf -*- +# AC_LIBTOOL_PROG_LD_SHLIBS([TAGNAME]) +# ------------------------------------ +# See if the linker supports building shared libraries. +AC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS], +[AC_REQUIRE([LT_AC_PROG_SED])dnl +AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) +ifelse([$1],[CXX],[ + _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' + case $host_os in + aix[[4-9]]*) + # If we're using GNU nm, then we don't want the "-C" option. + # -C means demangle to AIX nm, but means don't demangle with GNU nm + if $NM -V 2>&1 | grep 'GNU' > /dev/null; then + _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols' + else + _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols' + fi + ;; + pw32*) + _LT_AC_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds" + ;; + cygwin* | mingw*) + _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;/^.*[[ ]]__nm__/s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.*[[ ]]//'\'' | sort | uniq > $export_symbols' + ;; + *) + _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' + ;; + esac + _LT_AC_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'] +],[ + runpath_var= + _LT_AC_TAGVAR(allow_undefined_flag, $1)= + _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no + _LT_AC_TAGVAR(archive_cmds, $1)= + _LT_AC_TAGVAR(archive_expsym_cmds, $1)= + _LT_AC_TAGVAR(old_archive_From_new_cmds, $1)= + _LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1)= + _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)= + _LT_AC_TAGVAR(whole_archive_flag_spec, $1)= + _LT_AC_TAGVAR(thread_safe_flag_spec, $1)= + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)= + _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)= + _LT_AC_TAGVAR(hardcode_libdir_separator, $1)= + _LT_AC_TAGVAR(hardcode_direct, $1)=no + _LT_AC_TAGVAR(hardcode_minus_L, $1)=no + _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported + _LT_AC_TAGVAR(link_all_deplibs, $1)=unknown + _LT_AC_TAGVAR(hardcode_automatic, $1)=no + _LT_AC_TAGVAR(module_cmds, $1)= + _LT_AC_TAGVAR(module_expsym_cmds, $1)= + _LT_AC_TAGVAR(always_export_symbols, $1)=no + _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' + # include_expsyms should be a list of space-separated symbols to be *always* + # included in the symbol list + _LT_AC_TAGVAR(include_expsyms, $1)= + # exclude_expsyms can be an extended regexp of symbols to exclude + # it will be wrapped by ` (' and `)$', so one must not match beginning or + # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc', + # as well as any symbol that contains `d'. + _LT_AC_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'] + # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out + # platforms (ab)use it in PIC code, but their linkers get confused if + # the symbol is explicitly referenced. Since portable code cannot + # rely on this symbol name, it's probably fine to never include it in + # preloaded symbol tables. + # Exclude shared library initialization/finalization symbols. +dnl Note also adjust exclude_expsyms for C++ above. + extract_expsyms_cmds= + # Just being paranoid about ensuring that cc_basename is set. + _LT_CC_BASENAME([$compiler]) + case $host_os in + cygwin* | mingw* | pw32*) + # FIXME: the MSVC++ port hasn't been tested in a loooong time + # When not using gcc, we currently assume that we are using + # Microsoft Visual C++. + if test "$GCC" != yes; then + with_gnu_ld=no + fi + ;; + interix*) + # we just hope/assume this is gcc and not c89 (= MSVC++) + with_gnu_ld=yes + ;; + openbsd*) + with_gnu_ld=no + ;; + esac -# Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005, 2008 -# Free Software Foundation, Inc. -# -# This file 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. + _LT_AC_TAGVAR(ld_shlibs, $1)=yes + if test "$with_gnu_ld" = yes; then + # If archive_cmds runs LD, not CC, wlarc should be empty + wlarc='${wl}' -# serial 5 + # Set some defaults for GNU ld with shared library support. These + # are reset later if shared libraries are not supported. Putting them + # here allows them to be overridden if necessary. + runpath_var=LD_RUN_PATH + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir' + _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' + # ancient GNU ld didn't support --whole-archive et. al. + if $LD --help 2>&1 | grep 'no-whole-archive' > /dev/null; then + _LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' + else + _LT_AC_TAGVAR(whole_archive_flag_spec, $1)= + fi + supports_anon_versioning=no + case `$LD -v 2>/dev/null` in + *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11 + *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... + *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... + *\ 2.11.*) ;; # other 2.11 versions + *) supports_anon_versioning=yes ;; + esac -# AM_SANITY_CHECK -# --------------- -AC_DEFUN([AM_SANITY_CHECK], -[AC_MSG_CHECKING([whether build environment is sane]) -# Just in case -sleep 1 -echo timestamp > conftest.file -# Reject unsafe characters in $srcdir or the absolute working directory -# name. Accept space and tab only in the latter. -am_lf=' -' -case `pwd` in - *[[\\\"\#\$\&\'\`$am_lf]]*) - AC_MSG_ERROR([unsafe absolute working directory name]);; -esac -case $srcdir in - *[[\\\"\#\$\&\'\`$am_lf\ \ ]]*) - AC_MSG_ERROR([unsafe srcdir value: `$srcdir']);; -esac + # See if GNU ld supports shared libraries. + case $host_os in + aix[[3-9]]*) + # On AIX/PPC, the GNU linker is very broken + if test "$host_cpu" != ia64; then + _LT_AC_TAGVAR(ld_shlibs, $1)=no + cat <&2 -# Do `set' in a subshell so we don't clobber the current shell's -# arguments. Must try -L first in case configure is actually a -# symlink; some systems play weird games with the mod time of symlinks -# (eg FreeBSD returns the mod time of the symlink's containing -# directory). -if ( - set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null` - if test "$[*]" = "X"; then - # -L didn't work. - set X `ls -t "$srcdir/configure" conftest.file` - fi - rm -f conftest.file - if test "$[*]" != "X $srcdir/configure conftest.file" \ - && test "$[*]" != "X conftest.file $srcdir/configure"; then +*** Warning: the GNU linker, at least up to release 2.9.1, is reported +*** to be unable to reliably create shared libraries on AIX. +*** Therefore, libtool is disabling shared libraries support. If you +*** really care for shared libraries, you may want to modify your PATH +*** so that a non-GNU linker is found, and then restart. - # If neither matched, then we have a broken ls. This can happen - # if, for instance, CONFIG_SHELL is bash and it inherits a - # broken ls alias from the environment. This has actually - # happened. Such a system could not be considered "sane". - AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken -alias in your environment]) - fi +EOF + fi + ;; - test "$[2]" = conftest.file - ) -then - # Ok. - : -else - AC_MSG_ERROR([newly created file is older than distributed files! -Check your system clock]) -fi -AC_MSG_RESULT(yes)]) + amigaos*) + _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes + + # Samuel A. Falvo II reports + # that the semantics of dynamic libraries on AmigaOS, at least up + # to version 4, is to share data among multiple programs linked + # with the same dynamic library. Since this doesn't match the + # behavior of shared libraries on other platforms, we can't use + # them. + _LT_AC_TAGVAR(ld_shlibs, $1)=no + ;; -# Copyright (C) 2009 Free Software Foundation, Inc. -# -# This file 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. + beos*) + if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then + _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported + # Joseph Beckenbach says some releases of gcc + # support --undefined. This deserves some investigation. FIXME + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + else + _LT_AC_TAGVAR(ld_shlibs, $1)=no + fi + ;; -# serial 1 + cygwin* | mingw* | pw32*) + # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, + # as there is no search path for DLLs. + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported + _LT_AC_TAGVAR(always_export_symbols, $1)=no + _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes + _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/'\'' -e '\''/^[[AITW]][[ ]]/s/.*[[ ]]//'\'' | sort | uniq > $export_symbols' + + if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + # If the export-symbols file already is a .def file (1st line + # is EXPORTS), use it as is; otherwise, prepend... + _LT_AC_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then + cp $export_symbols $output_objdir/$soname.def; + else + echo EXPORTS > $output_objdir/$soname.def; + cat $export_symbols >> $output_objdir/$soname.def; + fi~ + $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + else + _LT_AC_TAGVAR(ld_shlibs, $1)=no + fi + ;; -# AM_SILENT_RULES([DEFAULT]) -# -------------------------- -# Enable less verbose build rules; with the default set to DEFAULT -# (`yes' being less verbose, `no' or empty being verbose). -AC_DEFUN([AM_SILENT_RULES], -[AC_ARG_ENABLE([silent-rules], -[ --enable-silent-rules less verbose build output (undo: `make V=1') - --disable-silent-rules verbose build output (undo: `make V=0')]) -case $enable_silent_rules in -yes) AM_DEFAULT_VERBOSITY=0;; -no) AM_DEFAULT_VERBOSITY=1;; -*) AM_DEFAULT_VERBOSITY=m4_if([$1], [yes], [0], [1]);; -esac -AC_SUBST([AM_DEFAULT_VERBOSITY])dnl -AM_BACKSLASH='\' -AC_SUBST([AM_BACKSLASH])dnl -_AM_SUBST_NOTMAKE([AM_BACKSLASH])dnl -]) + interix[[3-9]]*) + _LT_AC_TAGVAR(hardcode_direct, $1)=no + _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' + _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' + # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. + # Instead, shared libraries are loaded at an image base (0x10000000 by + # default) and relocated if they conflict, which is a slow very memory + # consuming and fragmenting process. To avoid this, we pick a random, + # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link + # time. Moving up from 0x10000000 also allows more sbrk(2) space. + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + ;; -# Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc. -# -# This file 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. + gnu* | linux* | k*bsd*-gnu) + if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then + tmp_addflag= + case $cc_basename,$host_cpu in + pgcc*) # Portland Group C compiler + _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' + tmp_addflag=' $pic_flag' + ;; + pgf77* | pgf90* | pgf95*) # Portland Group f77 and f90 compilers + _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' + tmp_addflag=' $pic_flag -Mnomain' ;; + ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 + tmp_addflag=' -i_dynamic' ;; + efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 + tmp_addflag=' -i_dynamic -nofor_main' ;; + ifc* | ifort*) # Intel Fortran compiler + tmp_addflag=' -nofor_main' ;; + esac + case `$CC -V 2>&1 | sed 5q` in + *Sun\ C*) # Sun C 5.9 + _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' + tmp_sharedflag='-G' ;; + *Sun\ F*) # Sun Fortran 8.3 + tmp_sharedflag='-G' ;; + *) + tmp_sharedflag='-shared' ;; + esac + _LT_AC_TAGVAR(archive_cmds, $1)='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' -# AM_PROG_INSTALL_STRIP -# --------------------- -# One issue with vendor `install' (even GNU) is that you can't -# specify the program used to strip binaries. This is especially -# annoying in cross-compiling environments, where the build's strip -# is unlikely to handle the host's binaries. -# Fortunately install-sh will honor a STRIPPROG variable, so we -# always use install-sh in `make install-strip', and initialize -# STRIPPROG with the value of the STRIP variable (set by the user). -AC_DEFUN([AM_PROG_INSTALL_STRIP], -[AC_REQUIRE([AM_PROG_INSTALL_SH])dnl -# Installed binaries are usually stripped using `strip' when the user -# run `make install-strip'. However `strip' might not be the right -# tool to use in cross-compilation environments, therefore Automake -# will honor the `STRIP' environment variable to overrule this program. -dnl Don't test for $cross_compiling = yes, because it might be `maybe'. -if test "$cross_compiling" != no; then - AC_CHECK_TOOL([STRIP], [strip], :) -fi -INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s" -AC_SUBST([INSTALL_STRIP_PROGRAM])]) + if test $supports_anon_versioning = yes; then + _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $output_objdir/$libname.ver~ + cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ + $echo "local: *; };" >> $output_objdir/$libname.ver~ + $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' + fi + else + _LT_AC_TAGVAR(ld_shlibs, $1)=no + fi + ;; -# Copyright (C) 2006, 2008 Free Software Foundation, Inc. -# -# This file 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. + netbsd*) + if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then + _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' + wlarc= + else + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + fi + ;; -# serial 2 + solaris*) + if $LD -v 2>&1 | grep 'BFD 2\.8' > /dev/null; then + _LT_AC_TAGVAR(ld_shlibs, $1)=no + cat <&2 -# _AM_SUBST_NOTMAKE(VARIABLE) -# --------------------------- -# Prevent Automake from outputting VARIABLE = @VARIABLE@ in Makefile.in. -# This macro is traced by Automake. -AC_DEFUN([_AM_SUBST_NOTMAKE]) +*** Warning: The releases 2.8.* of the GNU linker cannot reliably +*** create shared libraries on Solaris systems. Therefore, libtool +*** is disabling shared libraries support. We urge you to upgrade GNU +*** binutils to release 2.9.1 or newer. Another option is to modify +*** your PATH or compiler configuration so that the native linker is +*** used, and then restart. -# AM_SUBST_NOTMAKE(VARIABLE) -# --------------------------- -# Public sister of _AM_SUBST_NOTMAKE. -AC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)]) +EOF + elif $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + else + _LT_AC_TAGVAR(ld_shlibs, $1)=no + fi + ;; -# Check how to create a tarball. -*- Autoconf -*- + sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*) + case `$LD -v 2>&1` in + *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.1[[0-5]].*) + _LT_AC_TAGVAR(ld_shlibs, $1)=no + cat <<_LT_EOF 1>&2 -# Copyright (C) 2004, 2005 Free Software Foundation, Inc. -# -# This file 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. +*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not +*** reliably create shared libraries on SCO systems. Therefore, libtool +*** is disabling shared libraries support. We urge you to upgrade GNU +*** binutils to release 2.16.91.0.3 or newer. Another option is to modify +*** your PATH or compiler configuration so that the native linker is +*** used, and then restart. -# serial 2 +_LT_EOF + ;; + *) + if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='`test -z "$SCOABSPATH" && echo ${wl}-rpath,$libdir`' + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib' + _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname,\${SCOABSPATH:+${install_libdir}/}$soname,-retain-symbols-file,$export_symbols -o $lib' + else + _LT_AC_TAGVAR(ld_shlibs, $1)=no + fi + ;; + esac + ;; -# _AM_PROG_TAR(FORMAT) -# -------------------- -# Check how to create a tarball in format FORMAT. -# FORMAT should be one of `v7', `ustar', or `pax'. -# -# Substitute a variable $(am__tar) that is a command -# writing to stdout a FORMAT-tarball containing the directory -# $tardir. -# tardir=directory && $(am__tar) > result.tar -# -# Substitute a variable $(am__untar) that extract such -# a tarball read from stdin. -# $(am__untar) < result.tar -AC_DEFUN([_AM_PROG_TAR], -[# Always define AMTAR for backward compatibility. -AM_MISSING_PROG([AMTAR], [tar]) -m4_if([$1], [v7], - [am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'], - [m4_case([$1], [ustar],, [pax],, - [m4_fatal([Unknown tar format])]) -AC_MSG_CHECKING([how to create a $1 tar archive]) -# Loop over all known methods to create a tar archive until one works. -_am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none' -_am_tools=${am_cv_prog_tar_$1-$_am_tools} -# Do not fold the above two line into one, because Tru64 sh and -# Solaris sh will not grok spaces in the rhs of `-'. -for _am_tool in $_am_tools -do - case $_am_tool in - gnutar) - for _am_tar in tar gnutar gtar; - do - AM_RUN_LOG([$_am_tar --version]) && break - done - am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"' - am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"' - am__untar="$_am_tar -xf -" - ;; - plaintar) - # Must skip GNU tar: if it does not support --format= it doesn't create - # ustar tarball either. - (tar --version) >/dev/null 2>&1 && continue - am__tar='tar chf - "$$tardir"' - am__tar_='tar chf - "$tardir"' - am__untar='tar xf -' - ;; - pax) - am__tar='pax -L -x $1 -w "$$tardir"' - am__tar_='pax -L -x $1 -w "$tardir"' - am__untar='pax -r' - ;; - cpio) - am__tar='find "$$tardir" -print | cpio -o -H $1 -L' - am__tar_='find "$tardir" -print | cpio -o -H $1 -L' - am__untar='cpio -i -H $1 -d' - ;; - none) - am__tar=false - am__tar_=false - am__untar=false - ;; - esac + sunos4*) + _LT_AC_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' + wlarc= + _LT_AC_TAGVAR(hardcode_direct, $1)=yes + _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; - # If the value was cached, stop now. We just wanted to have am__tar - # and am__untar set. - test -n "${am_cv_prog_tar_$1}" && break + *) + if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + else + _LT_AC_TAGVAR(ld_shlibs, $1)=no + fi + ;; + esac - # tar/untar a dummy directory, and stop if the command works - rm -rf conftest.dir - mkdir conftest.dir - echo GrepMe > conftest.dir/file - AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar]) - rm -rf conftest.dir - if test -s conftest.tar; then - AM_RUN_LOG([$am__untar /dev/null 2>&1 && break - fi -done -rm -rf conftest.dir + if test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no; then + runpath_var= + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)= + _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)= + _LT_AC_TAGVAR(whole_archive_flag_spec, $1)= + fi + else + # PORTME fill in a description of your system's linker (not GNU ld) + case $host_os in + aix3*) + _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported + _LT_AC_TAGVAR(always_export_symbols, $1)=yes + _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname' + # Note: this linker hardcodes the directories in LIBPATH if there + # are no directories specified by -L. + _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes + if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then + # Neither direct hardcoding nor static linking is supported with a + # broken collect2. + _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported + fi + ;; -AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool]) -AC_MSG_RESULT([$am_cv_prog_tar_$1])]) -AC_SUBST([am__tar]) -AC_SUBST([am__untar]) -]) # _AM_PROG_TAR + aix[[4-9]]*) + if test "$host_cpu" = ia64; then + # On IA64, the linker does run time linking by default, so we don't + # have to do anything special. + aix_use_runtimelinking=no + exp_sym_flag='-Bexport' + no_entry_flag="" + else + # If we're using GNU nm, then we don't want the "-C" option. + # -C means demangle to AIX nm, but means don't demangle with GNU nm + if $NM -V 2>&1 | grep 'GNU' > /dev/null; then + _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols' + else + _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols' + fi + aix_use_runtimelinking=no -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 -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 -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 -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. + # Test if we are trying to use run time linking or normal + # AIX style linking. If -brtl is somewhere in LDFLAGS, we + # need to do runtime linking. + case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*) + for ld_flag in $LDFLAGS; do + if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then + aix_use_runtimelinking=yes + break + fi + done + ;; + esac -# XORG_MACROS_VERSION(required-version) -# ------------------------------------- -# Minimum version: 1.1.0 -# -# If you're using a macro added in Version 1.1 or newer, include this in -# your configure.ac with the minimum required version, such as: -# XORG_MACROS_VERSION(1.1) -# -# To ensure that this macro is defined, also add: -# m4_ifndef([XORG_MACROS_VERSION], -# [m4_fatal([must install xorg-macros 1.1 or later before running autoconf/autogen])]) -# -# -# 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([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,, - [m4_fatal([xorg-macros major version ]maj_needed[ is required but ]vers_have[ found])]) -m4_if(m4_version_compare(vers_have, [$1]), -1, - [m4_fatal([xorg-macros version $1 or higher is required but ]vers_have[ found])]) -m4_undefine([vers_have]) -m4_undefine([maj_have]) -m4_undefine([maj_needed]) -]) # XORG_MACROS_VERSION + exp_sym_flag='-bexport' + no_entry_flag='-bnoentry' + fi -# XORG_PROG_RAWCPP() -# ------------------ -# Minimum version: 1.0.0 -# -# Find cpp program and necessary flags for use in pre-processing text files -# such as man pages and config files -AC_DEFUN([XORG_PROG_RAWCPP],[ -AC_REQUIRE([AC_PROG_CPP]) -AC_PATH_PROGS(RAWCPP, [cpp], [${CPP}], - [$PATH:/bin:/usr/bin:/usr/lib:/usr/libexec:/usr/ccs/lib:/usr/ccs/lbin:/lib]) + # When large executables or shared objects are built, AIX ld can + # have problems creating the table of contents. If linking a library + # or program results in "error TOC overflow" add -mminimal-toc to + # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not + # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. -# Check for flag to avoid builtin definitions - assumes unix is predefined, -# which is not the best choice for supporting other OS'es, but covers most -# of the ones we need for now. -AC_MSG_CHECKING([if $RAWCPP requires -undef]) -AC_LANG_CONFTEST([Does cpp redefine unix ?]) -if test `${RAWCPP} < conftest.$ac_ext | grep -c 'unix'` -eq 1 ; then - AC_MSG_RESULT([no]) -else - if test `${RAWCPP} -undef < conftest.$ac_ext | grep -c 'unix'` -eq 1 ; then - RAWCPPFLAGS=-undef - AC_MSG_RESULT([yes]) - # under Cygwin unix is still defined even with -undef - elif test `${RAWCPP} -undef -ansi < conftest.$ac_ext | grep -c 'unix'` -eq 1 ; then - RAWCPPFLAGS="-undef -ansi" - AC_MSG_RESULT([yes, with -ansi]) + _LT_AC_TAGVAR(archive_cmds, $1)='' + _LT_AC_TAGVAR(hardcode_direct, $1)=yes + _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':' + _LT_AC_TAGVAR(link_all_deplibs, $1)=yes + + if test "$GCC" = yes; then + case $host_os in aix4.[[012]]|aix4.[[012]].*) + # We only want to do this on AIX 4.2 and lower, the check + # below for broken collect2 doesn't work under 4.3+ + collect2name=`${CC} -print-prog-name=collect2` + if test -f "$collect2name" && \ + strings "$collect2name" | grep resolve_lib_name >/dev/null + then + # We have reworked collect2 + : + else + # We have old collect2 + _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported + # It fails to find uninstalled libraries when the uninstalled + # path is not listed in the libpath. Setting hardcode_minus_L + # to unsupported forces relinking + _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_AC_TAGVAR(hardcode_libdir_separator, $1)= + fi + ;; + esac + shared_flag='-shared' + if test "$aix_use_runtimelinking" = yes; then + shared_flag="$shared_flag "'${wl}-G' + fi + else + # not using gcc + if test "$host_cpu" = ia64; then + # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release + # chokes on -Wl,-G. The following line is correct: + shared_flag='-G' else - AC_MSG_ERROR([${RAWCPP} defines unix with or without -undef. I don't know what to do.]) + if test "$aix_use_runtimelinking" = yes; then + shared_flag='${wl}-G' + else + shared_flag='${wl}-bM:SRE' + fi fi -fi -rm -f conftest.$ac_ext + fi -AC_MSG_CHECKING([if $RAWCPP requires -traditional]) -AC_LANG_CONFTEST([Does cpp preserve "whitespace"?]) -if test `${RAWCPP} < conftest.$ac_ext | grep -c 'preserve \"'` -eq 1 ; then - AC_MSG_RESULT([no]) -else - if test `${RAWCPP} -traditional < conftest.$ac_ext | grep -c 'preserve \"'` -eq 1 ; then - RAWCPPFLAGS="${RAWCPPFLAGS} -traditional" - AC_MSG_RESULT([yes]) + # It seems that -bexpall does not export symbols beginning with + # underscore (_), so it is better to generate a list of symbols to export. + _LT_AC_TAGVAR(always_export_symbols, $1)=yes + if test "$aix_use_runtimelinking" = yes; then + # Warning - without using the other runtime loading flags (-brtl), + # -berok will link without error, but may produce a broken library. + _LT_AC_TAGVAR(allow_undefined_flag, $1)='-berok' + # Determine the default libpath from the value encoded in an empty executable. + _LT_AC_SYS_LIBPATH_AIX + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" + _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag" + else + if test "$host_cpu" = ia64; then + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib' + _LT_AC_TAGVAR(allow_undefined_flag, $1)="-z nodefs" + _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols" else - AC_MSG_ERROR([${RAWCPP} does not preserve whitespace with or without -traditional. I don't know what to do.]) + # Determine the default libpath from the value encoded in an empty executable. + _LT_AC_SYS_LIBPATH_AIX + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" + # Warning - without using the other run time loading flags, + # -berok will link without error, but may produce a broken library. + _LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok' + _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok' + # Exported symbols can be pulled into shared objects from archives + _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='$convenience' + _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes + # This is similar to how AIX traditionally builds its shared libraries. + _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' fi -fi -rm -f conftest.$ac_ext -AC_SUBST(RAWCPPFLAGS) -]) # XORG_PROG_RAWCPP + fi + ;; -# XORG_MANPAGE_SECTIONS() -# ----------------------- -# Minimum version: 1.0.0 -# -# Determine which sections man pages go in for the different man page types -# 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 + amigaos*) + _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes + # see comment about different semantics on the GNU ld section + _LT_AC_TAGVAR(ld_shlibs, $1)=no + ;; -AC_DEFUN([XORG_MANPAGE_SECTIONS],[ -AC_REQUIRE([AC_CANONICAL_HOST]) + bsdi[[45]]*) + _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic + ;; -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 + cygwin* | mingw* | pw32*) + # When not using gcc, we currently assume that we are using + # Microsoft Visual C++. + # hardcode_libdir_flag_spec is actually meaningless, as there is + # no search path for DLLs. + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' + _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported + # Tell ltmain to make .lib files, not .a files. + libext=lib + # Tell ltmain to make .dll files, not .so files. + shrext_cmds=".dll" + # FIXME: Setting linknames here is a bad hack. + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `echo "$deplibs" | $SED -e '\''s/ -lc$//'\''` -link -dll~linknames=' + # The linker will automatically build a .lib file if we build a DLL. + _LT_AC_TAGVAR(old_archive_From_new_cmds, $1)='true' + # FIXME: Should let the user specify the lib program. + _LT_AC_TAGVAR(old_archive_cmds, $1)='lib -OUT:$oldlib$oldobjs$old_deplibs' + _LT_AC_TAGVAR(fix_srcfile_path, $1)='`cygpath -w "$srcfile"`' + _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes + ;; -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 + darwin* | rhapsody*) + case $host_os in + rhapsody* | darwin1.[[012]]) + _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}suppress' + ;; + *) # Darwin 1.3 on + if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then + _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' + else + case ${MACOSX_DEPLOYMENT_TARGET} in + 10.[[012]]) + _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' + ;; + 10.*) + _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}dynamic_lookup' + ;; + esac + fi + ;; + esac + _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no + _LT_AC_TAGVAR(hardcode_direct, $1)=no + _LT_AC_TAGVAR(hardcode_automatic, $1)=yes + _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported + _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='' + _LT_AC_TAGVAR(link_all_deplibs, $1)=yes + if test "$GCC" = yes ; then + output_verbose_link_cmd='echo' + _LT_AC_TAGVAR(archive_cmds, $1)="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}" + _LT_AC_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}" + _LT_AC_TAGVAR(archive_expsym_cmds, $1)="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}" + _LT_AC_TAGVAR(module_expsym_cmds, $1)="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}" + else + case $cc_basename in + xlc*) + output_verbose_link_cmd='echo' + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $xlcverstring' + _LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags' + # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds + _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $xlcverstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' + _LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' + ;; + *) + _LT_AC_TAGVAR(ld_shlibs, $1)=no + ;; + esac + 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 + dgux*) + _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; -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 + freebsd1*) + _LT_AC_TAGVAR(ld_shlibs, $1)=no + ;; -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 + # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor + # support. Future versions do this automatically, but an explicit c++rt0.o + # does not break anything, and helps significantly (at the cost of a little + # extra space). + freebsd2.2*) + _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' + _LT_AC_TAGVAR(hardcode_direct, $1)=yes + _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; -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 + # Unfortunately, older versions of FreeBSD 2 do not have this feature. + freebsd2*) + _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' + _LT_AC_TAGVAR(hardcode_direct, $1)=yes + _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes + _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; + # FreeBSD 3 and greater uses gcc -shared to do shared libraries. + freebsd* | dragonfly*) + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -o $lib $libobjs $deplibs $compiler_flags' + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' + _LT_AC_TAGVAR(hardcode_direct, $1)=yes + _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; -AC_SUBST([APP_MAN_SUFFIX]) -AC_SUBST([LIB_MAN_SUFFIX]) -AC_SUBST([FILE_MAN_SUFFIX]) -AC_SUBST([MISC_MAN_SUFFIX]) -AC_SUBST([DRIVER_MAN_SUFFIX]) -AC_SUBST([ADMIN_MAN_SUFFIX]) -AC_SUBST([APP_MAN_DIR]) -AC_SUBST([LIB_MAN_DIR]) -AC_SUBST([FILE_MAN_DIR]) -AC_SUBST([MISC_MAN_DIR]) -AC_SUBST([DRIVER_MAN_DIR]) -AC_SUBST([ADMIN_MAN_DIR]) -]) # XORG_MANPAGE_SECTIONS + hpux9*) + if test "$GCC" = yes; then + _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' + else + _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' + fi + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' + _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: + _LT_AC_TAGVAR(hardcode_direct, $1)=yes -# XORG_CHECK_LINUXDOC -# ------------------- -# Minimum version: 1.0.0 -# -# Defines the variable MAKE_TEXT if the necessary tools and -# files are found. $(MAKE_TEXT) blah.sgml will then produce blah.txt. -# 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= + # hardcode_minus_L: Not really in the search PATH, + # but as the default location of the library. + _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes + _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' + ;; -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 + hpux10*) + if test "$GCC" = yes -a "$with_gnu_ld" = no; then + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' + else + _LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' + fi + if test "$with_gnu_ld" = no; then + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' + _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: -AC_PATH_PROG(LINUXDOC, linuxdoc) -AC_PATH_PROG(PS2PDF, ps2pdf) + _LT_AC_TAGVAR(hardcode_direct, $1)=yes + _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' -AC_MSG_CHECKING([Whether to build documentation]) + # hardcode_minus_L: Not really in the search PATH, + # but as the default location of the library. + _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes + fi + ;; -if test x$HAVE_DEFS_ENT != x && test x$LINUXDOC != x ; then - BUILDDOC=yes -else - BUILDDOC=no -fi + hpux11*) + if test "$GCC" = yes -a "$with_gnu_ld" = no; then + case $host_cpu in + hppa*64*) + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + ia64*) + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' + ;; + *) + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' + ;; + esac + else + case $host_cpu in + hppa*64*) + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + ia64*) + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' + ;; + *) + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' + ;; + esac + fi + if test "$with_gnu_ld" = no; then + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' + _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: -AM_CONDITIONAL(BUILD_LINUXDOC, [test x$BUILDDOC = xyes]) + case $host_cpu in + hppa*64*|ia64*) + _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='+b $libdir' + _LT_AC_TAGVAR(hardcode_direct, $1)=no + _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; + *) + _LT_AC_TAGVAR(hardcode_direct, $1)=yes + _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' -AC_MSG_RESULT([$BUILDDOC]) + # hardcode_minus_L: Not really in the search PATH, + # but as the default location of the library. + _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes + ;; + esac + fi + ;; -AC_MSG_CHECKING([Whether to build pdf documentation]) + irix5* | irix6* | nonstopux*) + if test "$GCC" = yes; then + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + else + _LT_AC_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' + _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='-rpath $libdir' + fi + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' + _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: + _LT_AC_TAGVAR(link_all_deplibs, $1)=yes + ;; -if test x$PS2PDF != x && test x$BUILD_PDFDOC != xno; then - BUILDPDFDOC=yes -else - BUILDPDFDOC=no -fi + netbsd*) + if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then + _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out + else + _LT_AC_TAGVAR(archive_cmds, $1)='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF + fi + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' + _LT_AC_TAGVAR(hardcode_direct, $1)=yes + _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; -AM_CONDITIONAL(BUILD_PDFDOC, [test x$BUILDPDFDOC = xyes]) + newsos6) + _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + _LT_AC_TAGVAR(hardcode_direct, $1)=yes + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' + _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: + _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; -AC_MSG_RESULT([$BUILDPDFDOC]) + openbsd*) + if test -f /usr/libexec/ld.so; then + _LT_AC_TAGVAR(hardcode_direct, $1)=yes + _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no + if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' + _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols' + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' + _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' + else + case $host_os in + openbsd[[01]].* | openbsd2.[[0-7]] | openbsd2.[[0-7]].*) + _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' + ;; + *) + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' + ;; + esac + fi + else + _LT_AC_TAGVAR(ld_shlibs, $1)=no + fi + ;; -MAKE_TEXT="SGML_SEARCH_PATH=$XORG_SGML_PATH GROFF_NO_SGR=y $LINUXDOC -B txt" -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" + os2*) + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes + _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported + _LT_AC_TAGVAR(archive_cmds, $1)='$echo "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$echo "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~$echo DATA >> $output_objdir/$libname.def~$echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~$echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def' + _LT_AC_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def' + ;; -AC_SUBST(MAKE_TEXT) -AC_SUBST(MAKE_PS) -AC_SUBST(MAKE_PDF) -AC_SUBST(MAKE_HTML) -]) # XORG_CHECK_LINUXDOC + osf3*) + if test "$GCC" = yes; then + _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + else + _LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' + _LT_AC_TAGVAR(archive_cmds, $1)='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' + fi + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' + _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: + ;; -# XORG_CHECK_DOCBOOK -# ------------------- -# Minimum version: 1.0.0 -# -# Checks for the ability to build output formats from SGML DocBook source. -# For XXX in {TXT, PDF, PS, HTML}, the AM_CONDITIONAL "BUILD_XXXDOC" -# 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= -BUILDTXTDOC=no -BUILDPDFDOC=no -BUILDPSDOC=no -BUILDHTMLDOC=no + osf4* | osf5*) # as osf3* with the addition of -msym flag + if test "$GCC" = yes; then + _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' + else + _LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' + _LT_AC_TAGVAR(archive_cmds, $1)='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -msym -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' + _LT_AC_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; echo "-hidden">> $lib.exp~ + $LD -shared${allow_undefined_flag} -input $lib.exp $linker_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib~$rm $lib.exp' -AC_CHECK_FILE([$XORG_SGML_PATH/X11/defs.ent], [HAVE_DEFS_ENT=yes]) + # Both c and cxx compiler support -rpath directly + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' + fi + _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: + ;; -AC_PATH_PROG(DOCBOOKPS, docbook2ps) -AC_PATH_PROG(DOCBOOKPDF, docbook2pdf) -AC_PATH_PROG(DOCBOOKHTML, docbook2html) -AC_PATH_PROG(DOCBOOKTXT, docbook2txt) + solaris*) + _LT_AC_TAGVAR(no_undefined_flag, $1)=' -z text' + if test "$GCC" = yes; then + wlarc='${wl}' + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ + $CC -shared ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$rm $lib.exp' + else + wlarc='' + _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' + _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ + $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp' + fi + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' + _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no + case $host_os in + solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; + *) + # The compiler driver will combine and reorder linker options, + # but understands `-z linker_flag'. GCC discards it without `$wl', + # but is careful enough not to reorder. + # Supported since Solaris 2.6 (maybe 2.5.1?) + if test "$GCC" = yes; then + _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' + else + _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' + fi + ;; + esac + _LT_AC_TAGVAR(link_all_deplibs, $1)=yes + ;; -AC_MSG_CHECKING([Whether to build text documentation]) -if test x$HAVE_DEFS_ENT != 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]) + sunos4*) + if test "x$host_vendor" = xsequent; then + # Use $CC to link under sequent, because it throws in some extra .o + # files that make .init and .fini sections work. + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags' + else + _LT_AC_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' + fi + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_AC_TAGVAR(hardcode_direct, $1)=yes + _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes + _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; -AC_MSG_CHECKING([Whether to build PDF documentation]) -if test x$HAVE_DEFS_ENT != 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]) + sysv4) + case $host_vendor in + sni) + _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + _LT_AC_TAGVAR(hardcode_direct, $1)=yes # is this really true??? + ;; + siemens) + ## LD is ld it makes a PLAMLIB + ## CC just makes a GrossModule. + _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags' + _LT_AC_TAGVAR(reload_cmds, $1)='$CC -r -o $output$reload_objs' + _LT_AC_TAGVAR(hardcode_direct, $1)=no + ;; + motorola) + _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + _LT_AC_TAGVAR(hardcode_direct, $1)=no #Motorola manual says yes, but my tests say they lie + ;; + esac + runpath_var='LD_RUN_PATH' + _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; -AC_MSG_CHECKING([Whether to build PostScript documentation]) -if test x$HAVE_DEFS_ENT != 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]) + sysv4.3*) + _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no + _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='-Bexport' + ;; -AC_MSG_CHECKING([Whether to build HTML documentation]) -if test x$HAVE_DEFS_ENT != x && test x$DOCBOOKHTML != x && - test x$BUILD_HTMLDOC != xno; then - BUILDHTMLDOC=yes -fi -AM_CONDITIONAL(BUILD_HTMLDOC, [test x$BUILDHTMLDOC = xyes]) -AC_MSG_RESULT([$BUILDHTMLDOC]) + sysv4*MP*) + if test -d /usr/nec; then + _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no + runpath_var=LD_RUN_PATH + hardcode_runpath_var=yes + _LT_AC_TAGVAR(ld_shlibs, $1)=yes + fi + ;; -MAKE_TEXT="SGML_SEARCH_PATH=$XORG_SGML_PATH $DOCBOOKTXT" -MAKE_PS="SGML_SEARCH_PATH=$XORG_SGML_PATH $DOCBOOKPS" -MAKE_PDF="SGML_SEARCH_PATH=$XORG_SGML_PATH $DOCBOOKPDF" -MAKE_HTML="SGML_SEARCH_PATH=$XORG_SGML_PATH $DOCBOOKHTML" + sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*) + _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' + _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no + _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no + runpath_var='LD_RUN_PATH' -AC_SUBST(MAKE_TEXT) -AC_SUBST(MAKE_PS) -AC_SUBST(MAKE_PDF) -AC_SUBST(MAKE_HTML) -]) # XORG_CHECK_DOCBOOK + if test "$GCC" = yes; then + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + else + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + fi + ;; -# XORG_CHECK_MALLOC_ZERO -# ---------------------- -# Minimum version: 1.0.0 -# -# Defines {MALLOC,XMALLOC,XTMALLOC}_ZERO_CFLAGS appropriately if -# malloc(0) returns NULL. Packages should add one of these cflags to -# their AM_CFLAGS (or other appropriate *_CFLAGS) to use them. -AC_DEFUN([XORG_CHECK_MALLOC_ZERO],[ -AC_ARG_ENABLE(malloc0returnsnull, - AS_HELP_STRING([--enable-malloc0returnsnull], - [malloc(0) returns NULL (default: auto)]), - [MALLOC_ZERO_RETURNS_NULL=$enableval], - [MALLOC_ZERO_RETURNS_NULL=auto]) + sysv5* | sco3.2v5* | sco5v6*) + # Note: We can NOT use -z defs as we might desire, because we do not + # link with -lc, and that would cause any symbols used from libc to + # always be unresolved, which means just about no library would + # ever link correctly. If we're not using GNU ld we use -z text + # though, which does catch some bad symbols but isn't as heavy-handed + # as -z defs. + _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' + _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs' + _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no + _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='`test -z "$SCOABSPATH" && echo ${wl}-R,$libdir`' + _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':' + _LT_AC_TAGVAR(link_all_deplibs, $1)=yes + _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport' + runpath_var='LD_RUN_PATH' -AC_MSG_CHECKING([whether malloc(0) returns NULL]) -if test "x$MALLOC_ZERO_RETURNS_NULL" = xauto; then - AC_RUN_IFELSE([ -char *malloc(); -char *realloc(); -char *calloc(); -main() { - char *m0, *r0, *c0, *p; - m0 = malloc(0); - p = malloc(10); - r0 = realloc(p,0); - c0 = calloc(0); - exit(m0 == 0 || r0 == 0 || c0 == 0 ? 0 : 1); -}], - [MALLOC_ZERO_RETURNS_NULL=yes], - [MALLOC_ZERO_RETURNS_NULL=no]) -fi -AC_MSG_RESULT([$MALLOC_ZERO_RETURNS_NULL]) + if test "$GCC" = yes; then + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' + else + _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' + fi + ;; -if test "x$MALLOC_ZERO_RETURNS_NULL" = xyes; then - MALLOC_ZERO_CFLAGS="-DMALLOC_0_RETURNS_NULL" - XMALLOC_ZERO_CFLAGS=$MALLOC_ZERO_CFLAGS - XTMALLOC_ZERO_CFLAGS="$MALLOC_ZERO_CFLAGS -DXTMALLOC_BC" -else - MALLOC_ZERO_CFLAGS="" - XMALLOC_ZERO_CFLAGS="" - XTMALLOC_ZERO_CFLAGS="" -fi + uts4*) + _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no + ;; -AC_SUBST([MALLOC_ZERO_CFLAGS]) -AC_SUBST([XMALLOC_ZERO_CFLAGS]) -AC_SUBST([XTMALLOC_ZERO_CFLAGS]) -]) # XORG_CHECK_MALLOC_ZERO + *) + _LT_AC_TAGVAR(ld_shlibs, $1)=no + ;; + esac + fi +]) +AC_MSG_RESULT([$_LT_AC_TAGVAR(ld_shlibs, $1)]) +test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no -# XORG_WITH_LINT() -# ---------------- -# 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) +# Do we need to explicitly link libc? # -AC_DEFUN([XORG_WITH_LINT],[ +case "x$_LT_AC_TAGVAR(archive_cmds_need_lc, $1)" in +x|xyes) + # Assume -lc should be added + _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes -# Allow checking code with lint, sparse, etc. -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" -else - LINT="$use_lint" -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 - ;; + if test "$enable_shared" = yes && test "$GCC" = yes; then + case $_LT_AC_TAGVAR(archive_cmds, $1) in + *'~'*) + # FIXME: we may have to deal with multi-command sequences. + ;; + '$CC '*) + # Test whether the compiler implicitly links with -lc since on some + # systems, -lgcc has to come before -lc. If gcc already passes -lc + # to ld, don't add -lc before -lgcc. + AC_MSG_CHECKING([whether -lc should be explicitly linked in]) + $rm conftest* + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + + if AC_TRY_EVAL(ac_compile) 2>conftest.err; then + soname=conftest + lib=conftest + libobjs=conftest.$ac_objext + deplibs= + wl=$_LT_AC_TAGVAR(lt_prog_compiler_wl, $1) + pic_flag=$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) + compiler_flags=-v + linker_flags=-v + verstring= + output_objdir=. + libname=conftest + lt_save_allow_undefined_flag=$_LT_AC_TAGVAR(allow_undefined_flag, $1) + _LT_AC_TAGVAR(allow_undefined_flag, $1)= + if AC_TRY_EVAL(_LT_AC_TAGVAR(archive_cmds, $1) 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1) + then + _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no + else + _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes + fi + _LT_AC_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag + else + cat conftest.err 1>&5 + fi + $rm conftest* + AC_MSG_RESULT([$_LT_AC_TAGVAR(archive_cmds_need_lc, $1)]) + ;; esac -fi - -AC_SUBST(LINT) -AC_SUBST(LINT_FLAGS) -AM_CONDITIONAL(LINT, [test x$LINT != xno]) + fi + ;; +esac +])# AC_LIBTOOL_PROG_LD_SHLIBS -]) # XORG_WITH_LINT -# XORG_LINT_LIBRARY(LIBNAME) -# -------------------------- -# Minimum version: 1.1.0 +# _LT_AC_FILE_LTDLL_C +# ------------------- +# Be careful that the start marker always follows a newline. +AC_DEFUN([_LT_AC_FILE_LTDLL_C], [ +# /* ltdll.c starts here */ +# #define WIN32_LEAN_AND_MEAN +# #include +# #undef WIN32_LEAN_AND_MEAN +# #include # -# 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 +# #ifndef __CYGWIN__ +# # ifdef __CYGWIN32__ +# # define __CYGWIN__ __CYGWIN32__ +# # endif +# #endif # +# #ifdef __cplusplus +# extern "C" { +# #endif +# BOOL APIENTRY DllMain (HINSTANCE hInst, DWORD reason, LPVOID reserved); +# #ifdef __cplusplus +# } +# #endif +# +# #ifdef __CYGWIN__ +# #include +# DECLARE_CYGWIN_DLL( DllMain ); +# #endif +# HINSTANCE __hDllInstance_base; +# +# BOOL APIENTRY +# DllMain (HINSTANCE hInst, DWORD reason, LPVOID reserved) +# { +# __hDllInstance_base = hInst; +# return TRUE; +# } +# /* ltdll.c ends here */ +])# _LT_AC_FILE_LTDLL_C -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 -fi -AC_SUBST(LINTLIB) -AM_CONDITIONAL(MAKE_LINT_LIB, [test x$make_lint_lib != xno]) -]) # XORG_LINT_LIBRARY +# _LT_AC_TAGVAR(VARNAME, [TAGNAME]) +# --------------------------------- +AC_DEFUN([_LT_AC_TAGVAR], [ifelse([$2], [], [$1], [$1_$2])]) -# XORG_CWARNFLAGS -# --------------- -# Minimum version: 1.2.0 -# -# Defines CWARNFLAGS to enable C compiler warnings. -# -AC_DEFUN([XORG_CWARNFLAGS], [ -AC_REQUIRE([AC_PROG_CC]) -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 + +# old names +AC_DEFUN([AM_PROG_LIBTOOL], [AC_PROG_LIBTOOL]) +AC_DEFUN([AM_ENABLE_SHARED], [AC_ENABLE_SHARED($@)]) +AC_DEFUN([AM_ENABLE_STATIC], [AC_ENABLE_STATIC($@)]) +AC_DEFUN([AM_DISABLE_SHARED], [AC_DISABLE_SHARED($@)]) +AC_DEFUN([AM_DISABLE_STATIC], [AC_DISABLE_STATIC($@)]) +AC_DEFUN([AM_PROG_LD], [AC_PROG_LD]) +AC_DEFUN([AM_PROG_NM], [AC_PROG_NM]) + +# This is just to silence aclocal about the macro not being used +ifelse([AC_DISABLE_FAST_INSTALL]) + +AC_DEFUN([LT_AC_PROG_GCJ], +[AC_CHECK_TOOL(GCJ, gcj, no) + test "x${GCJFLAGS+set}" = xset || GCJFLAGS="-g -O2" + AC_SUBST(GCJFLAGS) +]) + +AC_DEFUN([LT_AC_PROG_RC], +[AC_CHECK_TOOL(RC, windres, no) +]) + + +# Cheap backport of AS_EXECUTABLE_P and required macros +# from Autoconf 2.59; we should not use $as_executable_p directly. + +# _AS_TEST_PREPARE +# ---------------- +m4_ifndef([_AS_TEST_PREPARE], +[m4_defun([_AS_TEST_PREPARE], +[if test -x / >/dev/null 2>&1; then + as_executable_p='test -x' else - AC_CHECK_DECL([__SUNPRO_C], [SUNCC="yes"], [SUNCC="no"]) - if test "x$SUNCC" = "xyes"; then - CWARNFLAGS="-v" - fi + as_executable_p='test -f' fi -AC_SUBST(CWARNFLAGS) -m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])]) -]) # XORG_CWARNFLAGS +])])# _AS_TEST_PREPARE -# XORG_STRICT_OPTION -# ----------------------- -# Minimum version: 1.3.0 -# -# Add configure option to enable strict compilation -AC_DEFUN([XORG_STRICT_OPTION], [ -AC_REQUIRE([AC_PROG_CC]) -AC_REQUIRE([AC_PROG_CC_C99]) -AC_REQUIRE([XORG_CWARNFLAGS]) +# AS_EXECUTABLE_P +# --------------- +# Check whether a file is executable. +m4_ifndef([AS_EXECUTABLE_P], +[m4_defun([AS_EXECUTABLE_P], +[AS_REQUIRE([_AS_TEST_PREPARE])dnl +$as_executable_p $1[]dnl +])])# AS_EXECUTABLE_P -AC_ARG_ENABLE(strict-compilation, - AS_HELP_STRING([--enable-strict-compilation], - [Enable all warnings from compiler and make them errors (default: disabled)]), - [STRICT_COMPILE=$enableval], [STRICT_COMPILE=no]) -if test "x$STRICT_COMPILE" = "xyes"; then - AC_CHECK_DECL([__SUNPRO_C], [SUNCC="yes"], [SUNCC="no"]) - AC_CHECK_DECL([__INTEL_COMPILER], [INTELCC="yes"], [INTELCC="no"]) - 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" -AC_SUBST([CWARNFLAGS]) -]) # XORG_STRICT_OPTION +# NOTE: This macro has been submitted for inclusion into # +# GNU Autoconf as AC_PROG_SED. When it is available in # +# a released version of Autoconf we should remove this # +# macro and use it instead. # +# LT_AC_PROG_SED +# -------------- +# Check for a fully-functional sed program, that truncates +# as few characters as possible. Prefer GNU sed if found. +AC_DEFUN([LT_AC_PROG_SED], +[AC_MSG_CHECKING([for a sed that does not truncate output]) +AC_CACHE_VAL(lt_cv_path_SED, +[# 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 AS_EXECUTABLE_P(["$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 +]) +SED=$lt_cv_path_SED +AC_SUBST([SED]) +AC_MSG_RESULT([$SED]) +]) -# XORG_DEFAULT_OPTIONS -# -------------------- -# Minimum version: 1.3.0 +# pkg.m4 - Macros to locate and utilise pkg-config. -*- Autoconf -*- +# +# Copyright © 2004 Scott James Remnant . # -# Defines default options for X.Org modules. +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2 of the License, or +# (at your option) any later version. # -AC_DEFUN([XORG_DEFAULT_OPTIONS], [ -XORG_CWARNFLAGS -XORG_STRICT_OPTION -XORG_RELEASE_VERSION -XORG_CHANGELOG -XORG_MANPAGE_SECTIONS -]) # XORG_DEFAULT_OPTIONS -dnl Copyright 2005 Red Hat, Inc -dnl -dnl Permission to use, copy, modify, distribute, and sell this software and its -dnl documentation for any purpose is hereby granted without fee, provided that -dnl the above copyright notice appear in all copies and that both that -dnl copyright notice and this permission notice appear in supporting -dnl documentation. -dnl -dnl The above copyright notice and this permission notice shall be included -dnl in all copies or substantial portions of the Software. -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 IN NO EVENT SHALL THE OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR -dnl OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, -dnl ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR -dnl OTHER DEALINGS IN THE SOFTWARE. -dnl -dnl Except as contained in this notice, the name of the copyright holders shall -dnl not be used in advertising or otherwise to promote the sale, use or -dnl other dealings in this Software without prior written authorization -dnl from the copyright holders. -dnl +# This program is distributed in the hope that it will be useful, but +# WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 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., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. +# +# As a special exception to the GNU General Public License, if you +# distribute this file as part of a program that contains a +# configuration script generated by Autoconf, you may include it under +# the same distribution terms that you use for the rest of that program. -# 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. - -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]) - PVM=`echo $PACKAGE_VERSION | cut -d . -f 2 | cut -d - -f 1` - if test "x$PVM" = "x"; then - PVM="0" - fi - AC_DEFINE_UNQUOTED([PACKAGE_VERSION_MINOR], - [$PVM], - [Minor version of this package]) - PVP=`echo $PACKAGE_VERSION | cut -d . -f 3 | cut -d - -f 1` - if test "x$PVP" = "x"; then - PVP="0" +# PKG_PROG_PKG_CONFIG([MIN-VERSION]) +# ---------------------------------- +AC_DEFUN([PKG_PROG_PKG_CONFIG], +[m4_pattern_forbid([^_?PKG_[A-Z_]+$]) +m4_pattern_allow([^PKG_CONFIG(_PATH)?$]) +AC_ARG_VAR([PKG_CONFIG], [path to pkg-config utility])dnl +if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then + AC_PATH_TOOL([PKG_CONFIG], [pkg-config]) +fi +if test -n "$PKG_CONFIG"; then + _pkg_min_version=m4_default([$1], [0.9.0]) + AC_MSG_CHECKING([pkg-config is at least version $_pkg_min_version]) + if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then + AC_MSG_RESULT([yes]) + else + AC_MSG_RESULT([no]) + PKG_CONFIG="" fi - AC_DEFINE_UNQUOTED([PACKAGE_VERSION_PATCHLEVEL], - [$PVP], - [Patch version of this package]) -]) + +fi[]dnl +])# PKG_PROG_PKG_CONFIG -# XORG_CHANGELOG() -# ---------------- -# Minimum version: 1.2.0 +# PKG_CHECK_EXISTS(MODULES, [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND]) # -# Defines the variable CHANGELOG_CMD as the command to generate -# ChangeLog from git. +# Check to see whether a particular set of modules exists. Similar +# to PKG_CHECK_MODULES(), but does not set variables or print errors. # -# 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; \ -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 +# Similar to PKG_CHECK_MODULES, make sure that the first instance of +# this or PKG_CHECK_MODULES is called, or make sure to call +# PKG_CHECK_EXISTS manually +# -------------------------------------------------------------- +AC_DEFUN([PKG_CHECK_EXISTS], +[AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl +if test -n "$PKG_CONFIG" && \ + AC_RUN_LOG([$PKG_CONFIG --exists --print-errors "$1"]); then + m4_ifval([$2], [$2], [:]) +m4_ifvaln([$3], [else + $3])dnl +fi]) -dnl $XdotOrg: lib/xtrans/xtrans.m4,v 1.6 2005/07/26 18:59:11 alanc Exp $ -dnl -dnl Copyright 2005 Sun Microsystems, Inc. All rights reserved. -dnl -dnl Permission to use, copy, modify, distribute, and sell this software and its -dnl documentation for any purpose is hereby granted without fee, provided that -dnl the above copyright notice appear in all copies and that both that -dnl copyright notice and this permission notice appear in supporting -dnl documentation. -dnl -dnl The above copyright notice and this permission notice shall be included -dnl in all copies or substantial portions of the Software. -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 IN NO EVENT SHALL THE OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR -dnl OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, -dnl ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR -dnl OTHER DEALINGS IN THE SOFTWARE. -dnl -dnl Except as contained in this notice, the name of the copyright holders shall -dnl not be used in advertising or otherwise to promote the sale, use or -dnl other dealings in this Software without prior written authorization -dnl from the copyright holders. -dnl -# XTRANS_TCP_FLAGS() -# ------------------ -# Find needed libraries for TCP sockets, and check for IPv6 support -AC_DEFUN([XTRANS_TCP_FLAGS],[ - # SVR4 hides these in libraries other than libc - AC_SEARCH_LIBS(socket, [socket]) - AC_SEARCH_LIBS(gethostbyname, [nsl]) - AC_HAVE_LIBRARY([ws2_32]) +# _PKG_CONFIG([VARIABLE], [COMMAND], [MODULES]) +# --------------------------------------------- +m4_define([_PKG_CONFIG], +[if test -n "$$1"; then + pkg_cv_[]$1="$$1" + elif test -n "$PKG_CONFIG"; then + PKG_CHECK_EXISTS([$3], + [pkg_cv_[]$1=`$PKG_CONFIG --[]$2 "$3" 2>/dev/null`], + [pkg_failed=yes]) + else + pkg_failed=untried +fi[]dnl +])# _PKG_CONFIG - # Needs to come after above checks for libsocket & libnsl for SVR4 systems - AC_ARG_ENABLE(ipv6, - AC_HELP_STRING([--enable-ipv6],[Enable IPv6 support]), - [IPV6CONN=$enableval], - [AC_CHECK_FUNC(getaddrinfo,[IPV6CONN=yes],[IPV6CONN=no])]) - AC_MSG_CHECKING([if IPv6 support should be built]) - if test "$IPV6CONN" = "yes"; then - AC_DEFINE(IPv6,1,[Support IPv6 for TCP connections]) - fi - AC_MSG_RESULT($IPV6CONN) +# _PKG_SHORT_ERRORS_SUPPORTED +# ----------------------------- +AC_DEFUN([_PKG_SHORT_ERRORS_SUPPORTED], +[AC_REQUIRE([PKG_PROG_PKG_CONFIG]) +if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then + _pkg_short_errors_supported=yes +else + _pkg_short_errors_supported=no +fi[]dnl +])# _PKG_SHORT_ERRORS_SUPPORTED - # 4.3BSD-Reno added a new member to struct sockaddr_in - AC_CHECK_MEMBER([struct sockaddr_in.sin_len], - AC_DEFINE([BSD44SOCKETS],1, - [Define to 1 if `struct sockaddr_in' has a `sin_len' member]), [], [ -#include -#include -#include - ]) - # POSIX.1g changed the type of pointer passed to getsockname/getpeername/etc. - AC_CHECK_TYPES([socklen_t], [], [], [ -AC_INCLUDES_DEFAULT -#include ]) - -]) # XTRANS_TCP_FLAGS +# PKG_CHECK_MODULES(VARIABLE-PREFIX, MODULES, [ACTION-IF-FOUND], +# [ACTION-IF-NOT-FOUND]) +# +# +# Note that if there is a possibility the first call to +# PKG_CHECK_MODULES might not happen, you should be sure to include an +# explicit call to PKG_PROG_PKG_CONFIG in your configure.ac +# +# +# -------------------------------------------------------------- +AC_DEFUN([PKG_CHECK_MODULES], +[AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl +AC_ARG_VAR([$1][_CFLAGS], [C compiler flags for $1, overriding pkg-config])dnl +AC_ARG_VAR([$1][_LIBS], [linker flags for $1, overriding pkg-config])dnl -# XTRANS_CONNECTION_FLAGS() -# ------------------------- -# Standard checks for which Xtrans transports to use by the Xorg packages -# that use Xtrans functions -AC_DEFUN([XTRANS_CONNECTION_FLAGS],[ - AC_REQUIRE([AC_CANONICAL_HOST]) - AC_REQUIRE([AC_TYPE_SIGNAL]) - [case $host_os in - mingw*) unixdef="no" ;; - *) unixdef="yes" ;; - esac] - AC_ARG_ENABLE(unix-transport, - AC_HELP_STRING([--enable-unix-transport],[Enable UNIX domain socket transport]), - [UNIXCONN=$enableval], [UNIXCONN=$unixdef]) - AC_MSG_CHECKING([if Xtrans should support UNIX socket connections]) - if test "$UNIXCONN" = "yes"; then - AC_DEFINE(UNIXCONN,1,[Support UNIX socket connections]) - fi - AC_MSG_RESULT($UNIXCONN) - AC_ARG_ENABLE(tcp-transport, - AC_HELP_STRING([--enable-tcp-transport],[Enable TCP socket transport]), - [TCPCONN=$enableval], [TCPCONN=yes]) - AC_MSG_CHECKING([if Xtrans should support TCP socket connections]) - AC_MSG_RESULT($TCPCONN) - if test "$TCPCONN" = "yes"; then - AC_DEFINE(TCPCONN,1,[Support TCP socket connections]) - XTRANS_TCP_FLAGS - fi - [case $host_os in - solaris*|sco*|sysv4*) localdef="yes" ;; - *) localdef="no" ;; - esac] - AC_ARG_ENABLE(local-transport, - AC_HELP_STRING([--enable-local-transport],[Enable os-specific local transport]), - [LOCALCONN=$enableval], [LOCALCONN=$localdef]) - AC_MSG_CHECKING([if Xtrans should support os-specific local connections]) - AC_MSG_RESULT($LOCALCONN) - if test "$LOCALCONN" = "yes"; then - AC_DEFINE(LOCALCONN,1,[Support os-specific local connections]) - fi - -]) # XTRANS_CONNECTION_FLAGS +pkg_failed=no +AC_MSG_CHECKING([for $1]) +_PKG_CONFIG([$1][_CFLAGS], [cflags], [$2]) +_PKG_CONFIG([$1][_LIBS], [libs], [$2]) -# XTRANS_SECURE_RPC_FLAGS() -# ------------------------- -# Check for Secure RPC functions - must come after XTRANS_TCP_FLAGS -# so that any necessary networking libraries are already found -AC_DEFUN([XTRANS_SECURE_RPC_FLAGS], -[AC_REQUIRE([XTRANS_TCP_FLAGS]) - AC_ARG_ENABLE(secure-rpc, - AC_HELP_STRING([--enable-secure-rpc],[Enable Secure RPC]), - [SECURE_RPC=$enableval], [SECURE_RPC="try"]) +m4_define([_PKG_TEXT], [Alternatively, you may set the environment variables $1[]_CFLAGS +and $1[]_LIBS to avoid the need to call pkg-config. +See the pkg-config man page for more details.]) - if test "x$SECURE_RPC" = "xyes" -o "x$SECURE_RPC" = "xtry" ; then - FOUND_SECURE_RPC="no" - AC_CHECK_FUNCS([authdes_seccreate authdes_create], - [FOUND_SECURE_RPC="yes"]) - if test "x$FOUND_SECURE_RPC" = "xno" ; then - if test "x$SECURE_RPC" = "xyes" ; then - AC_MSG_ERROR([Secure RPC requested, but required functions not found]) - fi - SECURE_RPC="no" - else - dnl FreeBSD keeps getsecretkey in librpcsvc - AC_SEARCH_LIBS(getsecretkey, [rpcsvc]) - SECURE_RPC="yes" - fi - fi - AC_MSG_CHECKING([if Secure RPC authentication ("SUN-DES-1") should be supported]) - if test "x$SECURE_RPC" = "xyes" ; then - AC_DEFINE(SECURE_RPC, 1, [Support Secure RPC ("SUN-DES-1") authentication for X11 clients]) - fi - AC_MSG_RESULT($SECURE_RPC) -]) # XTRANS_SECURE_RPC_FLAGS +if test $pkg_failed = yes; then + _PKG_SHORT_ERRORS_SUPPORTED + if test $_pkg_short_errors_supported = yes; then + $1[]_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "$2" 2>&1` + else + $1[]_PKG_ERRORS=`$PKG_CONFIG --print-errors "$2" 2>&1` + fi + # Put the nasty error message in config.log where it belongs + echo "$$1[]_PKG_ERRORS" >&AS_MESSAGE_LOG_FD + + ifelse([$4], , [AC_MSG_ERROR(dnl +[Package requirements ($2) were not met: + +$$1_PKG_ERRORS + +Consider adjusting the PKG_CONFIG_PATH environment variable if you +installed software in a non-standard prefix. + +_PKG_TEXT +])], + [AC_MSG_RESULT([no]) + $4]) +elif test $pkg_failed = untried; then + ifelse([$4], , [AC_MSG_FAILURE(dnl +[The pkg-config script could not be found or is too old. Make sure it +is in your PATH or set the PKG_CONFIG environment variable to the full +path to pkg-config. + +_PKG_TEXT +To get pkg-config, see .])], + [$4]) +else + $1[]_CFLAGS=$pkg_cv_[]$1[]_CFLAGS + $1[]_LIBS=$pkg_cv_[]$1[]_LIBS + AC_MSG_RESULT([yes]) + ifelse([$3], , :, [$3]) +fi[]dnl +])# PKG_CHECK_MODULES m4_include([acinclude.m4]) diff --git a/libX11/config.guess b/libX11/config.guess index da8331460..f32079abd 100644 --- a/libX11/config.guess +++ b/libX11/config.guess @@ -4,7 +4,7 @@ # 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 # Free Software Foundation, Inc. -timestamp='2009-04-27' +timestamp='2008-01-23' # This file is free software; you can redistribute it and/or modify it # under the terms of the GNU General Public License as published by @@ -324,9 +324,6 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in case `/usr/bin/uname -p` in sparc) echo sparc-icl-nx7; exit ;; esac ;; - s390x:SunOS:*:*) - echo ${UNAME_MACHINE}-ibm-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` - exit ;; sun4H:SunOS:5.*:*) echo sparc-hal-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` exit ;; @@ -334,20 +331,7 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in echo sparc-sun-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` exit ;; i86pc:SunOS:5.*:* | i86xen:SunOS:5.*:*) - eval $set_cc_for_build - SUN_ARCH="i386" - # If there is a compiler, see if it is configured for 64-bit objects. - # Note that the Sun cc does not turn __LP64__ into 1 like gcc does. - # This test works for both compilers. - if [ "$CC_FOR_BUILD" != 'no_compiler_found' ]; then - if (echo '#ifdef __amd64'; echo IS_64BIT_ARCH; echo '#endif') | \ - (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | \ - grep IS_64BIT_ARCH >/dev/null - then - SUN_ARCH="x86_64" - fi - fi - echo ${SUN_ARCH}-pc-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` + echo i386-pc-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` exit ;; sun4*:SunOS:6*:*) # According to config.sub, this is the proper way to canonicalize @@ -812,7 +796,7 @@ EOF x86) echo i586-pc-interix${UNAME_RELEASE} exit ;; - EM64T | authenticamd | genuineintel) + EM64T | authenticamd) echo x86_64-unknown-interix${UNAME_RELEASE} exit ;; IA64) @@ -951,9 +935,6 @@ EOF if test "$?" = 0 ; then LIBC="libc1" ; else LIBC="" ; fi echo ${UNAME_MACHINE}-unknown-linux-gnu${LIBC} exit ;; - padre:Linux:*:*) - echo sparc-unknown-linux-gnu - exit ;; parisc:Linux:*:* | hppa:Linux:*:*) # Look for CPU level case `grep '^cpu[^a-z]*:' /proc/cpuinfo 2>/dev/null | cut -d' ' -f2` in @@ -1004,6 +985,9 @@ EOF a.out-i386-linux) echo "${UNAME_MACHINE}-pc-linux-gnuaout" exit ;; + coff-i386) + echo "${UNAME_MACHINE}-pc-linux-gnucoff" + exit ;; "") # Either a pre-BFD a.out linker (linux-gnuoldld) or # one that does not give us useful --help. @@ -1118,11 +1102,8 @@ EOF pc:*:*:*) # Left here for compatibility: # uname -m prints for DJGPP always 'pc', but it prints nothing about - # the processor, so we play safe by assuming i586. - # Note: whatever this is, it MUST be the same as what config.sub - # prints for the "djgpp" host, or else GDB configury will decide that - # this is a cross-build. - echo i586-pc-msdosdjgpp + # the processor, so we play safe by assuming i386. + echo i386-pc-msdosdjgpp exit ;; Intel:Mach:3*:*) echo i386-pc-mach3 @@ -1160,16 +1141,6 @@ EOF 3[34]??:*:4.0:* | 3[34]??,*:*:4.0:*) /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ && { echo i486-ncr-sysv4; exit; } ;; - NCR*:*:4.2:* | MPRAS*:*:4.2:*) - OS_REL='.3' - test -r /etc/.relid \ - && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid` - /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ - && { echo i486-ncr-sysv4.3${OS_REL}; exit; } - /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \ - && { echo i586-ncr-sysv4.3${OS_REL}; exit; } - /bin/uname -p 2>/dev/null | /bin/grep pteron >/dev/null \ - && { echo i586-ncr-sysv4.3${OS_REL}; exit; } ;; m68*:LynxOS:2.*:* | m68*:LynxOS:3.0*:*) echo m68k-unknown-lynxos${UNAME_RELEASE} exit ;; @@ -1245,9 +1216,6 @@ EOF BePC:BeOS:*:*) # BeOS running on Intel PC compatible. echo i586-pc-beos exit ;; - BePC:Haiku:*:*) # Haiku running on Intel PC compatible. - echo i586-pc-haiku - exit ;; SX-4:SUPER-UX:*:*) echo sx4-nec-superux${UNAME_RELEASE} exit ;; @@ -1356,9 +1324,6 @@ EOF i*86:rdos:*:*) echo ${UNAME_MACHINE}-pc-rdos exit ;; - i*86:AROS:*:*) - echo ${UNAME_MACHINE}-pc-aros - exit ;; esac #echo '(No uname command or uname output not recognized.)' 1>&2 diff --git a/libX11/config.sub b/libX11/config.sub index a39437d01..6759825a5 100644 --- a/libX11/config.sub +++ b/libX11/config.sub @@ -4,7 +4,7 @@ # 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 # Free Software Foundation, Inc. -timestamp='2009-04-17' +timestamp='2008-01-16' # This file is (in principle) common to ALL GNU software. # The presence of a machine in this file suggests that SOME GNU software @@ -122,7 +122,6 @@ maybe_os=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\2/'` case $maybe_os in nto-qnx* | linux-gnu* | linux-dietlibc | linux-newlib* | linux-uclibc* | \ uclinux-uclibc* | uclinux-gnu* | kfreebsd*-gnu* | knetbsd*-gnu* | netbsd*-gnu* | \ - kopensolaris*-gnu* | \ storm-chaos* | os2-emx* | rtmk-nova*) os=-$maybe_os basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'` @@ -250,16 +249,13 @@ case $basic_machine in | h8300 | h8500 | hppa | hppa1.[01] | hppa2.0 | hppa2.0[nw] | hppa64 \ | i370 | i860 | i960 | ia64 \ | ip2k | iq2000 \ - | lm32 \ | m32c | m32r | m32rle | m68000 | m68k | m88k \ - | maxq | mb | microblaze | mcore | mep | metag \ + | maxq | mb | microblaze | mcore | mep \ | mips | mipsbe | mipseb | mipsel | mipsle \ | mips16 \ | mips64 | mips64el \ - | mips64octeon | mips64octeonel \ - | mips64orion | mips64orionel \ - | mips64r5900 | mips64r5900el \ | mips64vr | mips64vrel \ + | mips64orion | mips64orionel \ | mips64vr4100 | mips64vr4100el \ | mips64vr4300 | mips64vr4300el \ | mips64vr5000 | mips64vr5000el \ @@ -272,7 +268,6 @@ case $basic_machine in | mipsisa64sr71k | mipsisa64sr71kel \ | mipstx39 | mipstx39el \ | mn10200 | mn10300 \ - | moxie \ | mt \ | msp430 \ | nios | nios2 \ @@ -282,7 +277,7 @@ case $basic_machine in | powerpc | powerpc64 | powerpc64le | powerpcle | ppcbe \ | pyramid \ | score \ - | sh | sh[1234] | sh[24]a | sh[24]aeb | sh[23]e | sh[34]eb | sheb | shbe | shle | sh[1234]le | sh3ele \ + | sh | sh[1234] | sh[24]a | sh[23]e | sh[34]eb | sheb | shbe | shle | sh[1234]le | sh3ele \ | sh64 | sh64le \ | sparc | sparc64 | sparc64b | sparc64v | sparc86x | sparclet | sparclite \ | sparcv8 | sparcv9 | sparcv9b | sparcv9v \ @@ -291,7 +286,7 @@ case $basic_machine in | v850 | v850e \ | we32k \ | x86 | xc16x | xscale | xscalee[bl] | xstormy16 | xtensa \ - | z8k | z80) + | z8k) basic_machine=$basic_machine-unknown ;; m6811 | m68hc11 | m6812 | m68hc12) @@ -334,17 +329,14 @@ case $basic_machine in | hppa-* | hppa1.[01]-* | hppa2.0-* | hppa2.0[nw]-* | hppa64-* \ | i*86-* | i860-* | i960-* | ia64-* \ | ip2k-* | iq2000-* \ - | lm32-* \ | m32c-* | m32r-* | m32rle-* \ | m68000-* | m680[012346]0-* | m68360-* | m683?2-* | m68k-* \ - | m88110-* | m88k-* | maxq-* | mcore-* | metag-* \ + | m88110-* | m88k-* | maxq-* | mcore-* \ | mips-* | mipsbe-* | mipseb-* | mipsel-* | mipsle-* \ | mips16-* \ | mips64-* | mips64el-* \ - | mips64octeon-* | mips64octeonel-* \ - | mips64orion-* | mips64orionel-* \ - | mips64r5900-* | mips64r5900el-* \ | mips64vr-* | mips64vrel-* \ + | mips64orion-* | mips64orionel-* \ | mips64vr4100-* | mips64vr4100el-* \ | mips64vr4300-* | mips64vr4300el-* \ | mips64vr5000-* | mips64vr5000el-* \ @@ -366,20 +358,20 @@ case $basic_machine in | powerpc-* | powerpc64-* | powerpc64le-* | powerpcle-* | ppcbe-* \ | pyramid-* \ | romp-* | rs6000-* \ - | sh-* | sh[1234]-* | sh[24]a-* | sh[24]aeb-* | sh[23]e-* | sh[34]eb-* | sheb-* | shbe-* \ + | sh-* | sh[1234]-* | sh[24]a-* | sh[23]e-* | sh[34]eb-* | sheb-* | shbe-* \ | shle-* | sh[1234]le-* | sh3ele-* | sh64-* | sh64le-* \ | sparc-* | sparc64-* | sparc64b-* | sparc64v-* | sparc86x-* | sparclet-* \ | sparclite-* \ | sparcv8-* | sparcv9-* | sparcv9b-* | sparcv9v-* | strongarm-* | sv1-* | sx?-* \ | tahoe-* | thumb-* \ - | tic30-* | tic4x-* | tic54x-* | tic55x-* | tic6x-* | tic80-* | tile-* \ + | tic30-* | tic4x-* | tic54x-* | tic55x-* | tic6x-* | tic80-* \ | tron-* \ | v850-* | v850e-* | vax-* \ | we32k-* \ | x86-* | x86_64-* | xc16x-* | xps100-* | xscale-* | xscalee[bl]-* \ | xstormy16-* | xtensa*-* \ | ymp-* \ - | z8k-* | z80-*) + | z8k-*) ;; # Recognize the basic CPU types without company name, with glob match. xtensa*) @@ -447,10 +439,6 @@ case $basic_machine in basic_machine=m68k-apollo os=-bsd ;; - aros) - basic_machine=i386-pc - os=-aros - ;; aux) basic_machine=m68k-apple os=-aux @@ -471,10 +459,6 @@ case $basic_machine in basic_machine=c90-cray os=-unicos ;; - cegcc) - basic_machine=arm-unknown - os=-cegcc - ;; convex-c1) basic_machine=c1-convex os=-bsd @@ -542,10 +526,6 @@ case $basic_machine in basic_machine=m88k-motorola os=-sysv3 ;; - dicos) - basic_machine=i686-pc - os=-dicos - ;; djgpp) basic_machine=i586-pc os=-msdosdjgpp @@ -1148,10 +1128,6 @@ case $basic_machine in basic_machine=z8k-unknown os=-sim ;; - z80-*-coff) - basic_machine=z80-unknown - os=-sim - ;; none) basic_machine=none-none os=-none @@ -1190,7 +1166,7 @@ case $basic_machine in we32k) basic_machine=we32k-att ;; - sh[1234] | sh[24]a | sh[24]aeb | sh[34]eb | sh[1234]le | sh[23]ele) + sh[1234] | sh[24]a | sh[34]eb | sh[1234]le | sh[23]ele) basic_machine=sh-unknown ;; sparc | sparcv8 | sparcv9 | sparcv9b | sparcv9v) @@ -1262,9 +1238,8 @@ case $os in -gnu* | -bsd* | -mach* | -minix* | -genix* | -ultrix* | -irix* \ | -*vms* | -sco* | -esix* | -isc* | -aix* | -sunos | -sunos[34]*\ | -hpux* | -unos* | -osf* | -luna* | -dgux* | -solaris* | -sym* \ - | -kopensolaris* \ | -amigaos* | -amigados* | -msdos* | -newsos* | -unicos* | -aof* \ - | -aos* | -aros* \ + | -aos* \ | -nindy* | -vxsim* | -vxworks* | -ebmon* | -hms* | -mvs* \ | -clix* | -riscos* | -uniplus* | -iris* | -rtu* | -xenix* \ | -hiux* | -386bsd* | -knetbsd* | -mirbsd* | -netbsd* \ @@ -1273,7 +1248,7 @@ case $os in | -bosx* | -nextstep* | -cxux* | -aout* | -elf* | -oabi* \ | -ptx* | -coff* | -ecoff* | -winnt* | -domain* | -vsta* \ | -udi* | -eabi* | -lites* | -ieee* | -go32* | -aux* \ - | -chorusos* | -chorusrdb* | -cegcc* \ + | -chorusos* | -chorusrdb* \ | -cygwin* | -pe* | -psos* | -moss* | -proelf* | -rtems* \ | -mingw32* | -linux-gnu* | -linux-newlib* | -linux-uclibc* \ | -uxpv* | -beos* | -mpeix* | -udk* \ @@ -1413,9 +1388,6 @@ case $os in -zvmoe) os=-zvmoe ;; - -dicos*) - os=-dicos - ;; -none) ;; *) diff --git a/libX11/configure b/libX11/configure index 307b8fdcc..1306cc785 100644 --- a/libX11/configure +++ b/libX11/configure @@ -1,6 +1,6 @@ #! /bin/sh # Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.63 for libX11 1.3. +# Generated by GNU Autoconf 2.63 for libX11 1.3.1. # # Report bugs to . # @@ -577,22 +577,22 @@ as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" # Check that we are running under the correct shell. SHELL=${CONFIG_SHELL-/bin/sh} -case X$lt_ECHO in +case X$ECHO in X*--fallback-echo) # Remove one level of quotation (which was required for Make). - ECHO=`echo "$lt_ECHO" | sed 's,\\\\\$\\$0,'$0','` + ECHO=`echo "$ECHO" | sed 's,\\\\\$\\$0,'$0','` ;; esac -ECHO=${lt_ECHO-echo} +echo=${ECHO-echo} if test "X$1" = X--no-reexec; then # Discard the --no-reexec flag, and continue. shift elif test "X$1" = X--fallback-echo; then # Avoid inline document here, it may be left over : -elif test "X`{ $ECHO '\t'; } 2>/dev/null`" = 'X\t' ; then - # Yippee, $ECHO works! +elif test "X`($echo '\t') 2>/dev/null`" = 'X\t' ; then + # Yippee, $echo works! : else # Restart under the correct shell. @@ -602,9 +602,9 @@ fi if test "X$1" = X--fallback-echo; then # used as fallback echo shift - cat <<_LT_EOF + cat </dev/null 2>&1 && unset CDPATH -if test -z "$lt_ECHO"; then - if test "X${echo_test_string+set}" != Xset; then - # find a string as large as possible, as long as the shell can cope with it - for cmd in 'sed 50q "$0"' 'sed 20q "$0"' 'sed 10q "$0"' 'sed 2q "$0"' 'echo test'; do - # expected sizes: less than 2Kb, 1Kb, 512 bytes, 16 bytes, ... - if { echo_test_string=`eval $cmd`; } 2>/dev/null && - { test "X$echo_test_string" = "X$echo_test_string"; } 2>/dev/null - then - break - fi - done - fi +if test -z "$ECHO"; then +if test "X${echo_test_string+set}" != Xset; then +# find a string as large as possible, as long as the shell can cope with it + for cmd in 'sed 50q "$0"' 'sed 20q "$0"' 'sed 10q "$0"' 'sed 2q "$0"' 'echo test'; do + # expected sizes: less than 2Kb, 1Kb, 512 bytes, 16 bytes, ... + if (echo_test_string=`eval $cmd`) 2>/dev/null && + echo_test_string=`eval $cmd` && + (test "X$echo_test_string" = "X$echo_test_string") 2>/dev/null + then + break + fi + done +fi - if test "X`{ $ECHO '\t'; } 2>/dev/null`" = 'X\t' && - echo_testing_string=`{ $ECHO "$echo_test_string"; } 2>/dev/null` && - test "X$echo_testing_string" = "X$echo_test_string"; then - : - else - # The Solaris, AIX, and Digital Unix default echo programs unquote - # backslashes. This makes it impossible to quote backslashes using - # echo "$something" | sed 's/\\/\\\\/g' - # - # So, first we look for a working echo in the user's PATH. +if test "X`($echo '\t') 2>/dev/null`" = 'X\t' && + echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` && + test "X$echo_testing_string" = "X$echo_test_string"; then + : +else + # The Solaris, AIX, and Digital Unix default echo programs unquote + # backslashes. This makes it impossible to quote backslashes using + # echo "$something" | sed 's/\\/\\\\/g' + # + # So, first we look for a working echo in the user's PATH. - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR - for dir in $PATH /usr/ucb; do - IFS="$lt_save_ifs" - if (test -f $dir/echo || test -f $dir/echo$ac_exeext) && - test "X`($dir/echo '\t') 2>/dev/null`" = 'X\t' && - echo_testing_string=`($dir/echo "$echo_test_string") 2>/dev/null` && - test "X$echo_testing_string" = "X$echo_test_string"; then - ECHO="$dir/echo" - break - fi - done + lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR + for dir in $PATH /usr/ucb; do IFS="$lt_save_ifs" + if (test -f $dir/echo || test -f $dir/echo$ac_exeext) && + test "X`($dir/echo '\t') 2>/dev/null`" = 'X\t' && + echo_testing_string=`($dir/echo "$echo_test_string") 2>/dev/null` && + test "X$echo_testing_string" = "X$echo_test_string"; then + echo="$dir/echo" + break + fi + done + IFS="$lt_save_ifs" - if test "X$ECHO" = Xecho; then - # We didn't find a better echo, so look for alternatives. - if test "X`{ print -r '\t'; } 2>/dev/null`" = 'X\t' && - echo_testing_string=`{ print -r "$echo_test_string"; } 2>/dev/null` && - test "X$echo_testing_string" = "X$echo_test_string"; then - # This shell has a builtin print -r that does the trick. - ECHO='print -r' - elif { test -f /bin/ksh || test -f /bin/ksh$ac_exeext; } && - test "X$CONFIG_SHELL" != X/bin/ksh; then - # If we have ksh, try running configure again with it. - ORIGINAL_CONFIG_SHELL=${CONFIG_SHELL-/bin/sh} - export ORIGINAL_CONFIG_SHELL - CONFIG_SHELL=/bin/ksh - export CONFIG_SHELL - exec $CONFIG_SHELL "$0" --no-reexec ${1+"$@"} - else - # Try using printf. - ECHO='printf %s\n' - if test "X`{ $ECHO '\t'; } 2>/dev/null`" = 'X\t' && - echo_testing_string=`{ $ECHO "$echo_test_string"; } 2>/dev/null` && + if test "X$echo" = Xecho; then + # We didn't find a better echo, so look for alternatives. + if test "X`(print -r '\t') 2>/dev/null`" = 'X\t' && + echo_testing_string=`(print -r "$echo_test_string") 2>/dev/null` && + test "X$echo_testing_string" = "X$echo_test_string"; then + # This shell has a builtin print -r that does the trick. + echo='print -r' + elif (test -f /bin/ksh || test -f /bin/ksh$ac_exeext) && + test "X$CONFIG_SHELL" != X/bin/ksh; then + # If we have ksh, try running configure again with it. + ORIGINAL_CONFIG_SHELL=${CONFIG_SHELL-/bin/sh} + export ORIGINAL_CONFIG_SHELL + CONFIG_SHELL=/bin/ksh + export CONFIG_SHELL + exec $CONFIG_SHELL "$0" --no-reexec ${1+"$@"} + else + # Try using printf. + echo='printf %s\n' + if test "X`($echo '\t') 2>/dev/null`" = 'X\t' && + echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` && + test "X$echo_testing_string" = "X$echo_test_string"; then + # Cool, printf works + : + elif echo_testing_string=`($ORIGINAL_CONFIG_SHELL "$0" --fallback-echo '\t') 2>/dev/null` && + test "X$echo_testing_string" = 'X\t' && + echo_testing_string=`($ORIGINAL_CONFIG_SHELL "$0" --fallback-echo "$echo_test_string") 2>/dev/null` && test "X$echo_testing_string" = "X$echo_test_string"; then - # Cool, printf works - : - elif echo_testing_string=`($ORIGINAL_CONFIG_SHELL "$0" --fallback-echo '\t') 2>/dev/null` && - test "X$echo_testing_string" = 'X\t' && - echo_testing_string=`($ORIGINAL_CONFIG_SHELL "$0" --fallback-echo "$echo_test_string") 2>/dev/null` && - test "X$echo_testing_string" = "X$echo_test_string"; then - CONFIG_SHELL=$ORIGINAL_CONFIG_SHELL - export CONFIG_SHELL - SHELL="$CONFIG_SHELL" - export SHELL - ECHO="$CONFIG_SHELL $0 --fallback-echo" - elif echo_testing_string=`($CONFIG_SHELL "$0" --fallback-echo '\t') 2>/dev/null` && - test "X$echo_testing_string" = 'X\t' && - echo_testing_string=`($CONFIG_SHELL "$0" --fallback-echo "$echo_test_string") 2>/dev/null` && - test "X$echo_testing_string" = "X$echo_test_string"; then - ECHO="$CONFIG_SHELL $0 --fallback-echo" - else - # maybe with a smaller string... - prev=: - - for cmd in 'echo test' 'sed 2q "$0"' 'sed 10q "$0"' 'sed 20q "$0"' 'sed 50q "$0"'; do - if { test "X$echo_test_string" = "X`eval $cmd`"; } 2>/dev/null - then - break - fi - prev="$cmd" - done + CONFIG_SHELL=$ORIGINAL_CONFIG_SHELL + export CONFIG_SHELL + SHELL="$CONFIG_SHELL" + export SHELL + echo="$CONFIG_SHELL $0 --fallback-echo" + elif echo_testing_string=`($CONFIG_SHELL "$0" --fallback-echo '\t') 2>/dev/null` && + test "X$echo_testing_string" = 'X\t' && + echo_testing_string=`($CONFIG_SHELL "$0" --fallback-echo "$echo_test_string") 2>/dev/null` && + test "X$echo_testing_string" = "X$echo_test_string"; then + echo="$CONFIG_SHELL $0 --fallback-echo" + else + # maybe with a smaller string... + prev=: - if test "$prev" != 'sed 50q "$0"'; then - echo_test_string=`eval $prev` - export echo_test_string - exec ${ORIGINAL_CONFIG_SHELL-${CONFIG_SHELL-/bin/sh}} "$0" ${1+"$@"} - else - # Oops. We lost completely, so just stick with echo. - ECHO=echo + for cmd in 'echo test' 'sed 2q "$0"' 'sed 10q "$0"' 'sed 20q "$0"' 'sed 50q "$0"'; do + if (test "X$echo_test_string" = "X`eval $cmd`") 2>/dev/null + then + break fi - fi + prev="$cmd" + done + + if test "$prev" != 'sed 50q "$0"'; then + echo_test_string=`eval $prev` + export echo_test_string + exec ${ORIGINAL_CONFIG_SHELL-${CONFIG_SHELL-/bin/sh}} "$0" ${1+"$@"} + else + # Oops. We lost completely, so just stick with echo. + echo=echo + fi fi fi fi fi +fi # Copy echo and quote the copy suitably for passing to libtool from # the Makefile, instead of quoting the original, which is used later. -lt_ECHO=$ECHO -if test "X$lt_ECHO" = "X$CONFIG_SHELL $0 --fallback-echo"; then - lt_ECHO="$CONFIG_SHELL \\\$\$0 --fallback-echo" +ECHO=$echo +if test "X$ECHO" = "X$CONFIG_SHELL $0 --fallback-echo"; then + ECHO="$CONFIG_SHELL \\\$\$0 --fallback-echo" fi +tagnames=${tagnames+${tagnames},}CXX + +tagnames=${tagnames+${tagnames},}F77 + exec 7<&0 &1 # Name of the host. @@ -745,8 +750,8 @@ SHELL=${CONFIG_SHELL-/bin/sh} # Identity of this package. PACKAGE_NAME='libX11' PACKAGE_TARNAME='libX11' -PACKAGE_VERSION='1.3' -PACKAGE_STRING='libX11 1.3' +PACKAGE_VERSION='1.3.1' +PACKAGE_STRING='libX11 1.3.1' PACKAGE_BUGREPORT='https://bugs.freedesktop.org/enter_bug.cgi?product=xorg' ac_unique_file="Makefile.am" @@ -790,8 +795,12 @@ ac_subst_vars='am__EXEEXT_FALSE am__EXEEXT_TRUE LTLIBOBJS LIBOBJS -HAVE_AM_SILENT_RULES_FALSE -HAVE_AM_SILENT_RULES_TRUE +HAVE_PS2PDF_FALSE +HAVE_PS2PDF_TRUE +BUILD_SPECS_FALSE +BUILD_SPECS_TRUE +PS2PDF +GROFF XTMALLOC_ZERO_CFLAGS XMALLOC_ZERO_CFLAGS MALLOC_ZERO_CFLAGS @@ -875,21 +884,23 @@ CWARNFLAGS LTCXXCOMPILE LTCOMPILE DOLT_BASH -OTOOL64 -OTOOL -LIPO +LIBTOOL +ac_ct_F77 +FFLAGS +F77 +CXXCPP +am__fastdepCXX_FALSE +am__fastdepCXX_TRUE +CXXDEPMODE +ac_ct_CXX +CXXFLAGS +CXX NMEDIT DSYMUTIL -lt_ECHO RANLIB AR -OBJDUMP +ECHO LN_S -NM -ac_ct_DUMPBIN -DUMPBIN -LD -FGREP SED host_os host_vendor @@ -899,7 +910,6 @@ build_os build_vendor build_cpu build -LIBTOOL EGREP GREP CPP @@ -989,10 +999,11 @@ enable_maintainer_mode enable_dependency_tracking enable_shared enable_static -with_pic enable_fast_install with_gnu_ld enable_libtool_lock +with_pic +with_tags enable_silent_rules enable_strict_compilation with_release_version @@ -1019,6 +1030,7 @@ with_lint enable_lint_library with_locale_lib_dir enable_malloc0returnsnull +enable_specs ' ac_precious_vars='build_alias host_alias @@ -1029,6 +1041,12 @@ LDFLAGS LIBS CPPFLAGS CPP +CXX +CXXFLAGS +CCC +CXXCPP +F77 +FFLAGS PKG_CONFIG XPROTO_CFLAGS XPROTO_LIBS @@ -1592,7 +1610,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 libX11 1.3 to adapt to many kinds of systems. +\`configure' configures libX11 1.3.1 to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... @@ -1662,7 +1680,7 @@ fi if test -n "$ac_init_help"; then case $ac_init_help in - short | recursive ) echo "Configuration of libX11 1.3:";; + short | recursive ) echo "Configuration of libX11 1.3.1:";; esac cat <<\_ACEOF @@ -1684,6 +1702,11 @@ Optional Features: --enable-strict-compilation Enable all warnings from compiler and make them errors (default: disabled) + --enable-unix-transport Enable UNIX domain socket transport + --enable-tcp-transport Enable TCP socket transport + --enable-ipv6 Enable IPv6 support + --enable-local-transport + Enable os-specific local transport --enable-secure-rpc Enable Secure RPC --enable-loadable-i18n Controls loadable i18n module support --disable-loadable-xcursor @@ -1700,13 +1723,15 @@ Optional Features: --enable-lint-library Create lint library (default: disabled) --enable-malloc0returnsnull malloc(0) returns NULL (default: auto) + --enable-specs Enable building of specification docs Optional Packages: --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) + --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-gnu-ld assume the C compiler uses GNU ld [default=no] + --with-tags[=TAGS] include additional configurations [automatic] --with-release-version=STRING Use release version string in package name --with-perl= path to perl interpreter for build-time tests @@ -1731,6 +1756,11 @@ Some influential environment variables: CPPFLAGS C/C++/Objective C preprocessor flags, e.g. -I if you have headers in a nonstandard directory CPP C preprocessor + 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 XPROTO_CFLAGS C compiler flags for XPROTO, overriding pkg-config @@ -1815,7 +1845,7 @@ fi test -n "$ac_init_help" && exit $ac_status if $ac_init_version; then cat <<\_ACEOF -libX11 configure 1.3 +libX11 configure 1.3.1 generated by GNU Autoconf 2.63 Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, @@ -1829,7 +1859,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 libX11 $as_me 1.3, which was +It was created by libX11 $as_me 1.3.1, which was generated by GNU Autoconf 2.63. Invocation command line was $ $0 $@ @@ -2679,7 +2709,7 @@ fi # Define the identity of the package. PACKAGE='libX11' - VERSION='1.3' + VERSION='1.3.1' cat >>confdefs.h <<_ACEOF @@ -4746,30 +4776,77 @@ _ACEOF # Checks for programs. -case `pwd` in - *\ * | *\ *) - { $as_echo "$as_me:$LINENO: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&5 -$as_echo "$as_me: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&2;} ;; -esac - - - -macro_version='2.2.6' -macro_revision='1.3012' - - - - - - - - +# 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 -ltmain="$ac_aux_dir/ltmain.sh" # Make sure we can run config.sub. $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 || @@ -4856,175 +4933,62 @@ 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 "${ac_cv_path_SED+set}" = set; then +if test "${lt_cv_path_SED+set}" = set; then $as_echo_n "(cached) " >&6 else - 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 + # 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 ac_prog in sed gsed; do + for lt_ac_prog in sed gsed; do for ac_exec_ext in '' $ac_executable_extensions; do - 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_SED="$ac_path_SED" ac_path_SED_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 '' >> "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_SED_max-0}; then - # Best one so far, save it but keep looking for a better one - 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 - done - rm -f conftest.in conftest.tmp conftest.nl conftest.out;; -esac - - $ac_path_SED_found && break 3 + 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 - 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; }; } +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 -else - ac_cv_path_SED=$SED -fi - -fi -{ $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 - -test -z "$SED" && SED=sed -Xsed="$SED -e 1s/^X//" - - - - - - - - - - - -{ $as_echo "$as_me:$LINENO: checking for fgrep" >&5 -$as_echo_n "checking for fgrep... " >&6; } -if test "${ac_cv_path_FGREP+set}" = set; then - $as_echo_n "(cached) " >&6 -else - if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1 - then ac_cv_path_FGREP="$GREP -F" - else - if test -z "$FGREP"; then - ac_path_FGREP_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 fgrep; do - for ac_exec_ext in '' $ac_executable_extensions; do - ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext" - { test -f "$ac_path_FGREP" && $as_test_x "$ac_path_FGREP"; } || continue -# Check for GNU ac_path_FGREP and select it if it is found. - # Check for GNU $ac_path_FGREP -case `"$ac_path_FGREP" --version 2>&1` in -*GNU*) - ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_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 'FGREP' >> "conftest.nl" - "$ac_path_FGREP" FGREP < "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_FGREP_max-0}; then - # Best one so far, save it but keep looking for a better one - ac_cv_path_FGREP="$ac_path_FGREP" - ac_path_FGREP_max=$ac_count + 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 - # 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_FGREP_found && break 3 - done done done -IFS=$as_save_IFS - if test -z "$ac_cv_path_FGREP"; then - { { $as_echo "$as_me:$LINENO: error: no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5 -$as_echo "$as_me: error: no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;} - { (exit 1); exit 1; }; } - fi -else - ac_cv_path_FGREP=$FGREP -fi - fi fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_path_FGREP" >&5 -$as_echo "$ac_cv_path_FGREP" >&6; } - FGREP="$ac_cv_path_FGREP" - - -test -z "$GREP" && GREP=grep - - - - - - - - - - - - - - - +SED=$lt_cv_path_SED +{ $as_echo "$as_me:$LINENO: result: $SED" >&5 +$as_echo "$SED" >&6; } # Check whether --with-gnu-ld was given. @@ -5051,9 +5015,9 @@ $as_echo_n "checking for ld used by $CC... " >&6; } [\\/]* | ?:[\\/]*) re_direlt='/[^/][^/]*/\.\./' # Canonicalize the pathname of ld - ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'` - while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do - ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"` + ac_prog=`echo $ac_prog| $SED 's%\\\\%/%g'` + while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do + ac_prog=`echo $ac_prog| $SED "s%$re_direlt%/%"` done test -z "$LD" && LD="$ac_prog" ;; @@ -5133,36 +5097,54 @@ $as_echo "$lt_cv_prog_gnu_ld" >&6; } with_gnu_ld=$lt_cv_prog_gnu_ld - - - - - - - -{ $as_echo "$as_me:$LINENO: checking for BSD- or MS-compatible name lister (nm)" >&5 -$as_echo_n "checking for BSD- or MS-compatible name lister (nm)... " >&6; } -if test "${lt_cv_path_NM+set}" = set; then +{ $as_echo "$as_me:$LINENO: checking for $LD option to reload object files" >&5 +$as_echo_n "checking for $LD option to reload object files... " >&6; } +if test "${lt_cv_ld_reload_flag+set}" = set; then $as_echo_n "(cached) " >&6 else - if test -n "$NM"; then - # Let the user override the test. - lt_cv_path_NM="$NM" -else - lt_nm_to_check="${ac_tool_prefix}nm" - if test -n "$ac_tool_prefix" && test "$build" = "$host"; then - lt_nm_to_check="$lt_nm_to_check nm" - fi - for lt_tmp_nm in $lt_nm_to_check; do - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR - for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do - IFS="$lt_save_ifs" - test -z "$ac_dir" && ac_dir=. - tmp_nm="$ac_dir/$lt_tmp_nm" - if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then - # Check to see if the nm accepts a BSD-compat flag. - # Adding the `sed 1q' prevents false positives on HP-UX, which says: - # nm: unknown option "B" ignored + lt_cv_ld_reload_flag='-r' +fi +{ $as_echo "$as_me:$LINENO: result: $lt_cv_ld_reload_flag" >&5 +$as_echo "$lt_cv_ld_reload_flag" >&6; } +reload_flag=$lt_cv_ld_reload_flag +case $reload_flag in +"" | " "*) ;; +*) reload_flag=" $reload_flag" ;; +esac +reload_cmds='$LD$reload_flag -o $output$reload_objs' +case $host_os in + darwin*) + if test "$GCC" = yes; then + reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs' + else + reload_cmds='$LD$reload_flag -o $output$reload_objs' + fi + ;; +esac + +{ $as_echo "$as_me:$LINENO: checking for BSD-compatible nm" >&5 +$as_echo_n "checking for BSD-compatible nm... " >&6; } +if test "${lt_cv_path_NM+set}" = set; then + $as_echo_n "(cached) " >&6 +else + if test -n "$NM"; then + # Let the user override the test. + lt_cv_path_NM="$NM" +else + lt_nm_to_check="${ac_tool_prefix}nm" + if test -n "$ac_tool_prefix" && test "$build" = "$host"; then + lt_nm_to_check="$lt_nm_to_check nm" + fi + for lt_tmp_nm in $lt_nm_to_check; do + lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR + for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do + IFS="$lt_save_ifs" + test -z "$ac_dir" && ac_dir=. + tmp_nm="$ac_dir/$lt_tmp_nm" + if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then + # Check to see if the nm accepts a BSD-compat flag. + # Adding the `sed 1q' prevents false positives on HP-UX, which says: + # nm: unknown option "B" ignored # Tru64's nm complains that /dev/null is an invalid object file case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in */dev/null* | *'Invalid file or object type'*) @@ -5186,397 +5168,625 @@ else done IFS="$lt_save_ifs" done - : ${lt_cv_path_NM=no} + test -z "$lt_cv_path_NM" && lt_cv_path_NM=nm fi fi { $as_echo "$as_me:$LINENO: result: $lt_cv_path_NM" >&5 $as_echo "$lt_cv_path_NM" >&6; } -if test "$lt_cv_path_NM" != "no"; then - NM="$lt_cv_path_NM" -else - # Didn't find any BSD compatible name lister, look for dumpbin. - if test -n "$ac_tool_prefix"; then - for ac_prog in "dumpbin -symbols" "link -dump -symbols" - do - # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. -set dummy $ac_tool_prefix$ac_prog; 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_prog_DUMPBIN+set}" = set; then - $as_echo_n "(cached) " >&6 -else - if test -n "$DUMPBIN"; then - ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test. -else -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_prog_DUMPBIN="$ac_tool_prefix$ac_prog" - $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done -done -IFS=$as_save_IFS +NM="$lt_cv_path_NM" -fi -fi -DUMPBIN=$ac_cv_prog_DUMPBIN -if test -n "$DUMPBIN"; then - { $as_echo "$as_me:$LINENO: result: $DUMPBIN" >&5 -$as_echo "$DUMPBIN" >&6; } +{ $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" >&5 -$as_echo "no" >&6; } + { $as_echo "$as_me:$LINENO: result: no, using $LN_S" >&5 +$as_echo "no, using $LN_S" >&6; } fi - - test -n "$DUMPBIN" && break - done -fi -if test -z "$DUMPBIN"; then - ac_ct_DUMPBIN=$DUMPBIN - for ac_prog in "dumpbin -symbols" "link -dump -symbols" -do - # Extract the first word of "$ac_prog", so it can be a program name with args. -set dummy $ac_prog; 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_prog_ac_ct_DUMPBIN+set}" = set; then +{ $as_echo "$as_me:$LINENO: checking how to recognize dependent libraries" >&5 +$as_echo_n "checking how to recognize dependent libraries... " >&6; } +if test "${lt_cv_deplibs_check_method+set}" = set; then $as_echo_n "(cached) " >&6 else - if test -n "$ac_ct_DUMPBIN"; then - ac_cv_prog_ac_ct_DUMPBIN="$ac_ct_DUMPBIN" # Let the user override the test. -else -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_prog_ac_ct_DUMPBIN="$ac_prog" - $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done -done -IFS=$as_save_IFS + lt_cv_file_magic_cmd='$MAGIC_CMD' +lt_cv_file_magic_test_file= +lt_cv_deplibs_check_method='unknown' +# Need to set the preceding variable on all platforms that support +# interlibrary dependencies. +# 'none' -- dependencies not supported. +# `unknown' -- same as none, but documents that we really don't know. +# 'pass_all' -- all dependencies passed with no checks. +# 'test_compile' -- check by making test program. +# 'file_magic [[regex]]' -- check by looking for files in library path +# which responds to the $file_magic_cmd with a given extended regex. +# If you have `file' or equivalent on your system and you're not sure +# whether `pass_all' will *always* work, you probably want this one. -fi -fi -ac_ct_DUMPBIN=$ac_cv_prog_ac_ct_DUMPBIN -if test -n "$ac_ct_DUMPBIN"; then - { $as_echo "$as_me:$LINENO: result: $ac_ct_DUMPBIN" >&5 -$as_echo "$ac_ct_DUMPBIN" >&6; } -else - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } -fi +case $host_os in +aix[4-9]*) + lt_cv_deplibs_check_method=pass_all + ;; +beos*) + lt_cv_deplibs_check_method=pass_all + ;; - test -n "$ac_ct_DUMPBIN" && break -done +bsdi[45]*) + lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)' + lt_cv_file_magic_cmd='/usr/bin/file -L' + lt_cv_file_magic_test_file=/shlib/libc.so + ;; + +cygwin*) + # func_win32_libid is a shell function defined in ltmain.sh + lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' + lt_cv_file_magic_cmd='func_win32_libid' + ;; - if test "x$ac_ct_DUMPBIN" = x; then - DUMPBIN=":" +mingw* | pw32*) + # Base MSYS/MinGW do not provide the 'file' command needed by + # func_win32_libid shell function, so use a weaker test based on 'objdump', + # unless we find 'file', for example because we are cross-compiling. + if ( file / ) >/dev/null 2>&1; then + lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' + lt_cv_file_magic_cmd='func_win32_libid' else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - DUMPBIN=$ac_ct_DUMPBIN + lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?' + lt_cv_file_magic_cmd='$OBJDUMP -f' fi -fi + ;; +darwin* | rhapsody*) + lt_cv_deplibs_check_method=pass_all + ;; - if test "$DUMPBIN" != ":"; then - NM="$DUMPBIN" +freebsd* | dragonfly*) + if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then + case $host_cpu in + i*86 ) + # Not sure whether the presence of OpenBSD here was a mistake. + # Let's accept both of them until this is cleared up. + lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[3-9]86 (compact )?demand paged shared library' + lt_cv_file_magic_cmd=/usr/bin/file + lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` + ;; + esac + else + lt_cv_deplibs_check_method=pass_all fi -fi -test -z "$NM" && NM=nm + ;; +gnu*) + lt_cv_deplibs_check_method=pass_all + ;; +hpux10.20* | hpux11*) + lt_cv_file_magic_cmd=/usr/bin/file + case $host_cpu in + ia64*) + lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64' + lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so + ;; + hppa*64*) + lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - PA-RISC [0-9].[0-9]' + lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl + ;; + *) + lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9].[0-9]) shared library' + lt_cv_file_magic_test_file=/usr/lib/libc.sl + ;; + esac + ;; +interix[3-9]*) + # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here + lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|\.a)$' + ;; +irix5* | irix6* | nonstopux*) + case $LD in + *-32|*"-32 ") libmagic=32-bit;; + *-n32|*"-n32 ") libmagic=N32;; + *-64|*"-64 ") libmagic=64-bit;; + *) libmagic=never-match;; + esac + lt_cv_deplibs_check_method=pass_all + ;; +# This must be Linux ELF. +linux* | k*bsd*-gnu) + lt_cv_deplibs_check_method=pass_all + ;; -{ $as_echo "$as_me:$LINENO: checking the name lister ($NM) interface" >&5 -$as_echo_n "checking the name lister ($NM) interface... " >&6; } -if test "${lt_cv_nm_interface+set}" = set; then - $as_echo_n "(cached) " >&6 -else - lt_cv_nm_interface="BSD nm" - echo "int some_variable = 0;" > conftest.$ac_ext - (eval echo "\"\$as_me:5317: $ac_compile\"" >&5) - (eval "$ac_compile" 2>conftest.err) - cat conftest.err >&5 - (eval echo "\"\$as_me:5320: $NM \\\"conftest.$ac_objext\\\"\"" >&5) - (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out) - cat conftest.err >&5 - (eval echo "\"\$as_me:5323: output\"" >&5) - cat conftest.out >&5 - if $GREP 'External.*some_variable' conftest.out > /dev/null; then - lt_cv_nm_interface="MS dumpbin" +netbsd*) + if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then + lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$' + else + lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|_pic\.a)$' fi - rm -f conftest* -fi -{ $as_echo "$as_me:$LINENO: result: $lt_cv_nm_interface" >&5 -$as_echo "$lt_cv_nm_interface" >&6; } - -{ $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 + ;; -# find the maximum length of command line arguments -{ $as_echo "$as_me:$LINENO: checking the maximum length of command line arguments" >&5 -$as_echo_n "checking the maximum length of command line arguments... " >&6; } -if test "${lt_cv_sys_max_cmd_len+set}" = set; then - $as_echo_n "(cached) " >&6 -else - i=0 - teststring="ABCD" +newos6*) + lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)' + lt_cv_file_magic_cmd=/usr/bin/file + lt_cv_file_magic_test_file=/usr/lib/libnls.so + ;; - case $build_os in - msdosdjgpp*) - # On DJGPP, this test can blow up pretty badly due to problems in libc - # (any single argument exceeding 2000 bytes causes a buffer overrun - # during glob expansion). Even if it were fixed, the result of this - # check would be larger than it should be. - lt_cv_sys_max_cmd_len=12288; # 12K is about right - ;; +nto-qnx*) + lt_cv_deplibs_check_method=unknown + ;; - gnu*) - # Under GNU Hurd, this test is not required because there is - # no limit to the length of command line arguments. - # Libtool will interpret -1 as no limit whatsoever - lt_cv_sys_max_cmd_len=-1; - ;; +openbsd*) + if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then + lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|\.so|_pic\.a)$' + else + lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$' + fi + ;; - cygwin* | mingw* | cegcc*) - # On Win9x/ME, this test blows up -- it succeeds, but takes - # about 5 minutes as the teststring grows exponentially. - # Worse, since 9x/ME are not pre-emptively multitasking, - # you end up with a "frozen" computer, even though with patience - # the test eventually succeeds (with a max line length of 256k). - # Instead, let's just punt: use the minimum linelength reported by - # all of the supported platforms: 8192 (on NT/2K/XP). - lt_cv_sys_max_cmd_len=8192; - ;; +osf3* | osf4* | osf5*) + lt_cv_deplibs_check_method=pass_all + ;; - amigaos*) - # On AmigaOS with pdksh, this test takes hours, literally. - # So we just punt and use a minimum line length of 8192. - lt_cv_sys_max_cmd_len=8192; - ;; +rdos*) + lt_cv_deplibs_check_method=pass_all + ;; - netbsd* | freebsd* | openbsd* | darwin* | dragonfly*) - # This has been around since 386BSD, at least. Likely further. - if test -x /sbin/sysctl; then - lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` - elif test -x /usr/sbin/sysctl; then - lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax` - else - lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs - fi - # And add a safety zone - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` - ;; +solaris*) + lt_cv_deplibs_check_method=pass_all + ;; - interix*) - # We know the value 262144 and hardcode it with a safety zone (like BSD) - lt_cv_sys_max_cmd_len=196608 +sysv4 | sysv4.3*) + case $host_vendor in + motorola) + lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib) M[0-9][0-9]* Version [0-9]' + lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*` ;; - - osf*) - # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure - # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not - # nice to cause kernel panics so lets avoid the loop below. - # First set a reasonable default. - lt_cv_sys_max_cmd_len=16384 - # - if test -x /sbin/sysconfig; then - case `/sbin/sysconfig -q proc exec_disable_arg_limit` in - *1*) lt_cv_sys_max_cmd_len=-1 ;; - esac - fi + ncr) + lt_cv_deplibs_check_method=pass_all ;; - sco3.2v5*) - lt_cv_sys_max_cmd_len=102400 + sequent) + lt_cv_file_magic_cmd='/bin/file' + lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )' ;; - sysv5* | sco5v6* | sysv4.2uw2*) - kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null` - if test -n "$kargmax"; then - lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[ ]//'` - else - lt_cv_sys_max_cmd_len=32768 - fi + sni) + lt_cv_file_magic_cmd='/bin/file' + lt_cv_deplibs_check_method="file_magic ELF [0-9][0-9]*-bit [LM]SB dynamic lib" + lt_cv_file_magic_test_file=/lib/libc.so ;; - *) - lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null` - if test -n "$lt_cv_sys_max_cmd_len"; then - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` - else - # Make teststring a little bigger before we do anything with it. - # a 1K string should be a reasonable start. - for i in 1 2 3 4 5 6 7 8 ; do - teststring=$teststring$teststring - done - SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}} - # If test is not a shell built-in, we'll probably end up computing a - # maximum length that is only half of the actual maximum length, but - # we can't tell. - while { test "X"`$SHELL $0 --fallback-echo "X$teststring$teststring" 2>/dev/null` \ - = "XX$teststring$teststring"; } >/dev/null 2>&1 && - test $i != 17 # 1/2 MB should be enough - do - i=`expr $i + 1` - teststring=$teststring$teststring - done - # Only check the string length outside the loop. - lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1` - teststring= - # Add a significant safety factor because C++ compilers can tack on - # massive amounts of additional arguments before passing them to the - # linker. It appears as though 1/2 is a usable value. - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2` - fi + siemens) + lt_cv_deplibs_check_method=pass_all + ;; + pc) + lt_cv_deplibs_check_method=pass_all ;; esac + ;; -fi +sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) + lt_cv_deplibs_check_method=pass_all + ;; +esac -if test -n $lt_cv_sys_max_cmd_len ; then - { $as_echo "$as_me:$LINENO: result: $lt_cv_sys_max_cmd_len" >&5 -$as_echo "$lt_cv_sys_max_cmd_len" >&6; } -else - { $as_echo "$as_me:$LINENO: result: none" >&5 -$as_echo "none" >&6; } fi -max_cmd_len=$lt_cv_sys_max_cmd_len - - - - +{ $as_echo "$as_me:$LINENO: result: $lt_cv_deplibs_check_method" >&5 +$as_echo "$lt_cv_deplibs_check_method" >&6; } +file_magic_cmd=$lt_cv_file_magic_cmd +deplibs_check_method=$lt_cv_deplibs_check_method +test -z "$deplibs_check_method" && deplibs_check_method=unknown -: ${CP="cp -f"} -: ${MV="mv -f"} -: ${RM="rm -f"} -{ $as_echo "$as_me:$LINENO: checking whether the shell understands some XSI constructs" >&5 -$as_echo_n "checking whether the shell understands some XSI constructs... " >&6; } -# Try some XSI features -xsi_shell=no -( _lt_dummy="a/b/c" - test "${_lt_dummy##*/},${_lt_dummy%/*},"${_lt_dummy%"$_lt_dummy"}, \ - = c,a/b,, \ - && eval 'test $(( 1 + 1 )) -eq 2 \ - && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \ - && xsi_shell=yes -{ $as_echo "$as_me:$LINENO: result: $xsi_shell" >&5 -$as_echo "$xsi_shell" >&6; } +# If no C compiler was specified, use CC. +LTCC=${LTCC-"$CC"} -{ $as_echo "$as_me:$LINENO: checking whether the shell understands \"+=\"" >&5 -$as_echo_n "checking whether the shell understands \"+=\"... " >&6; } -lt_shell_append=no -( foo=bar; set foo baz; eval "$1+=\$2" && test "$foo" = barbaz ) \ - >/dev/null 2>&1 \ - && lt_shell_append=yes -{ $as_echo "$as_me:$LINENO: result: $lt_shell_append" >&5 -$as_echo "$lt_shell_append" >&6; } +# If no C compiler flags were specified, use CFLAGS. +LTCFLAGS=${LTCFLAGS-"$CFLAGS"} +# Allow CC to be a program name with arguments. +compiler=$CC -if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then - lt_unset=unset -else - lt_unset=false +# Check whether --enable-libtool-lock was given. +if test "${enable_libtool_lock+set}" = set; then + enableval=$enable_libtool_lock; fi +test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes - - - -# test EBCDIC or ASCII -case `echo X|tr X '\101'` in - A) # ASCII based system - # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr - lt_SP2NL='tr \040 \012' - lt_NL2SP='tr \015\012 \040\040' +# Some flags need to be propagated to the compiler or linker for good +# libtool support. +case $host in +ia64-*-hpux*) + # Find out which ABI we are using. + echo 'int i;' > conftest.$ac_ext + if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; then + case `/usr/bin/file conftest.$ac_objext` in + *ELF-32*) + HPUX_IA64_MODE="32" + ;; + *ELF-64*) + HPUX_IA64_MODE="64" + ;; + esac + fi + rm -rf conftest* ;; - *) # EBCDIC based system - lt_SP2NL='tr \100 \n' - lt_NL2SP='tr \r\n \100\100' +*-*-irix6*) + # Find out which ABI we are using. + echo '#line 5424 "configure"' > conftest.$ac_ext + if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; then + if test "$lt_cv_prog_gnu_ld" = yes; then + case `/usr/bin/file conftest.$ac_objext` in + *32-bit*) + LD="${LD-ld} -melf32bsmip" + ;; + *N32*) + LD="${LD-ld} -melf32bmipn32" + ;; + *64-bit*) + LD="${LD-ld} -melf64bmip" + ;; + esac + else + case `/usr/bin/file conftest.$ac_objext` in + *32-bit*) + LD="${LD-ld} -32" + ;; + *N32*) + LD="${LD-ld} -n32" + ;; + *64-bit*) + LD="${LD-ld} -64" + ;; + esac + fi + fi + rm -rf conftest* ;; -esac - - - - - - - +x86_64-*kfreebsd*-gnu|x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*| \ +s390*-*linux*|sparc*-*linux*) + # Find out which ABI we are using. + echo 'int i;' > conftest.$ac_ext + if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; then + case `/usr/bin/file conftest.o` in + *32-bit*) + case $host in + x86_64-*kfreebsd*-gnu) + LD="${LD-ld} -m elf_i386_fbsd" + ;; + x86_64-*linux*) + LD="${LD-ld} -m elf_i386" + ;; + ppc64-*linux*|powerpc64-*linux*) + LD="${LD-ld} -m elf32ppclinux" + ;; + s390x-*linux*) + LD="${LD-ld} -m elf_s390" + ;; + sparc64-*linux*) + LD="${LD-ld} -m elf32_sparc" + ;; + esac + ;; + *64-bit*) + case $host in + x86_64-*kfreebsd*-gnu) + LD="${LD-ld} -m elf_x86_64_fbsd" + ;; + x86_64-*linux*) + LD="${LD-ld} -m elf_x86_64" + ;; + ppc*-*linux*|powerpc*-*linux*) + LD="${LD-ld} -m elf64ppc" + ;; + s390*-*linux*) + LD="${LD-ld} -m elf64_s390" + ;; + sparc*-*linux*) + LD="${LD-ld} -m elf64_sparc" + ;; + esac + ;; + esac + fi + rm -rf conftest* + ;; -{ $as_echo "$as_me:$LINENO: checking for $LD option to reload object files" >&5 -$as_echo_n "checking for $LD option to reload object files... " >&6; } -if test "${lt_cv_ld_reload_flag+set}" = set; then +*-*-sco3.2v5*) + # On SCO OpenServer 5, we need -belf to get full-featured binaries. + SAVE_CFLAGS="$CFLAGS" + CFLAGS="$CFLAGS -belf" + { $as_echo "$as_me:$LINENO: checking whether the C compiler needs -belf" >&5 +$as_echo_n "checking whether the C compiler needs -belf... " >&6; } +if test "${lt_cv_cc_needs_belf+set}" = set; then $as_echo_n "(cached) " >&6 else - lt_cv_ld_reload_flag='-r' -fi -{ $as_echo "$as_me:$LINENO: result: $lt_cv_ld_reload_flag" >&5 -$as_echo "$lt_cv_ld_reload_flag" >&6; } -reload_flag=$lt_cv_ld_reload_flag -case $reload_flag in -"" | " "*) ;; -*) reload_flag=" $reload_flag" ;; -esac -reload_cmds='$LD$reload_flag -o $output$reload_objs' -case $host_os in - darwin*) - if test "$GCC" = yes; then - reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs' - else - reload_cmds='$LD$reload_flag -o $output$reload_objs' - fi - ;; -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 + cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ +int +main () +{ + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext 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>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_exeext && { + test "$cross_compiling" = yes || + $as_test_x conftest$ac_exeext + }; then + lt_cv_cc_needs_belf=yes +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + lt_cv_cc_needs_belf=no +fi + +rm -rf conftest.dSYM +rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ + conftest$ac_exeext conftest.$ac_ext + 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 + +fi +{ $as_echo "$as_me:$LINENO: result: $lt_cv_cc_needs_belf" >&5 +$as_echo "$lt_cv_cc_needs_belf" >&6; } + if test x"$lt_cv_cc_needs_belf" != x"yes"; then + # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf + CFLAGS="$SAVE_CFLAGS" + fi + ;; +sparc*-*solaris*) + # Find out which ABI we are using. + echo 'int i;' > conftest.$ac_ext + if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; then + case `/usr/bin/file conftest.o` in + *64-bit*) + case $lt_cv_prog_gnu_ld in + yes*) LD="${LD-ld} -m elf64_sparc" ;; + *) + if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then + LD="${LD-ld} -64" + fi + ;; + esac + ;; + esac + fi + rm -rf conftest* + ;; +esac + +need_locks="$enable_libtool_lock" -if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args. -set dummy ${ac_tool_prefix}objdump; ac_word=$2 +for ac_header in dlfcn.h +do +as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then + { $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 +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; } +else + # Is the header compilable? +{ $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5 +$as_echo_n "checking $ac_header usability... " >&6; } +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 + ac_header_compiler=yes +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_header_compiler=no +fi + +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +{ $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 +$as_echo "$ac_header_compiler" >&6; } + +# Is the header present? +{ $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5 +$as_echo_n "checking $ac_header presence... " >&6; } +cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ +#include <$ac_header> +_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 + ac_header_preproc=yes +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_header_preproc=no +fi + +rm -f conftest.err conftest.$ac_ext +{ $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 +$as_echo "$ac_header_preproc" >&6; } + +# So? What about this header? +case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in + yes:no: ) + { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5 +$as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;} + { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5 +$as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;} + ac_header_preproc=yes + ;; + no:yes:* ) + { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5 +$as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;} + { $as_echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5 +$as_echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;} + { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5 +$as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;} + { $as_echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5 +$as_echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;} + { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5 +$as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;} + { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5 +$as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;} + ( cat <<\_ASBOX +## ---------------------------------------------------------------------- ## +## Report this to https://bugs.freedesktop.org/enter_bug.cgi?product=xorg ## +## ---------------------------------------------------------------------- ## +_ASBOX + ) | sed "s/^/$as_me: WARNING: /" >&2 + ;; +esac +{ $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 + eval "$as_ac_Header=\$ac_header_preproc" +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; } + +fi +as_val=`eval 'as_val=${'$as_ac_Header'} + $as_echo "$as_val"'` + if test "x$as_val" = x""yes; then + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + +fi + +done + +ac_ext=cpp +ac_cpp='$CXXCPP $CPPFLAGS' +ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_cxx_compiler_gnu +if test -z "$CXX"; then + if test -n "$CCC"; then + CXX=$CCC + else + if test -n "$ac_tool_prefix"; then + for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC + do + # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. +set dummy $ac_tool_prefix$ac_prog; 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_prog_OBJDUMP+set}" = set; then +if test "${ac_cv_prog_CXX+set}" = set; then $as_echo_n "(cached) " >&6 else - if test -n "$OBJDUMP"; then - ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test. + if test -n "$CXX"; then + ac_cv_prog_CXX="$CXX" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH @@ -5585,7 +5795,7 @@ do 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_prog_OBJDUMP="${ac_tool_prefix}objdump" + ac_cv_prog_CXX="$ac_tool_prefix$ac_prog" $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi @@ -5595,28 +5805,32 @@ IFS=$as_save_IFS fi fi -OBJDUMP=$ac_cv_prog_OBJDUMP -if test -n "$OBJDUMP"; then - { $as_echo "$as_me:$LINENO: result: $OBJDUMP" >&5 -$as_echo "$OBJDUMP" >&6; } +CXX=$ac_cv_prog_CXX +if test -n "$CXX"; then + { $as_echo "$as_me:$LINENO: result: $CXX" >&5 +$as_echo "$CXX" >&6; } else { $as_echo "$as_me:$LINENO: result: no" >&5 $as_echo "no" >&6; } fi + test -n "$CXX" && break + done fi -if test -z "$ac_cv_prog_OBJDUMP"; then - ac_ct_OBJDUMP=$OBJDUMP - # Extract the first word of "objdump", so it can be a program name with args. -set dummy objdump; ac_word=$2 +if test -z "$CXX"; then + ac_ct_CXX=$CXX + for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; 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_prog_ac_ct_OBJDUMP+set}" = set; then +if test "${ac_cv_prog_ac_ct_CXX+set}" = set; then $as_echo_n "(cached) " >&6 else - if test -n "$ac_ct_OBJDUMP"; then - ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test. + if test -n "$ac_ct_CXX"; then + ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH @@ -5625,7 +5839,7 @@ do 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_prog_ac_ct_OBJDUMP="objdump" + ac_cv_prog_ac_ct_CXX="$ac_prog" $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi @@ -5635,17 +5849,21 @@ IFS=$as_save_IFS fi fi -ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP -if test -n "$ac_ct_OBJDUMP"; then - { $as_echo "$as_me:$LINENO: result: $ac_ct_OBJDUMP" >&5 -$as_echo "$ac_ct_OBJDUMP" >&6; } +ac_ct_CXX=$ac_cv_prog_ac_ct_CXX +if test -n "$ac_ct_CXX"; then + { $as_echo "$as_me:$LINENO: result: $ac_ct_CXX" >&5 +$as_echo "$ac_ct_CXX" >&6; } else { $as_echo "$as_me:$LINENO: result: no" >&5 $as_echo "no" >&6; } fi - if test "x$ac_ct_OBJDUMP" = x; then - OBJDUMP="false" + + test -n "$ac_ct_CXX" && break +done + + if test "x$ac_ct_CXX" = x; then + CXX="g++" else case $cross_compiling:$ac_tool_warned in yes:) @@ -5653,350 +5871,656 @@ yes:) $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac - OBJDUMP=$ac_ct_OBJDUMP + CXX=$ac_ct_CXX fi -else - OBJDUMP="$ac_cv_prog_OBJDUMP" fi -test -z "$OBJDUMP" && OBJDUMP=objdump - - - - - - - - - -{ $as_echo "$as_me:$LINENO: checking how to recognize dependent libraries" >&5 -$as_echo_n "checking how to recognize dependent libraries... " >&6; } -if test "${lt_cv_deplibs_check_method+set}" = set; then - $as_echo_n "(cached) " >&6 -else - lt_cv_file_magic_cmd='$MAGIC_CMD' -lt_cv_file_magic_test_file= -lt_cv_deplibs_check_method='unknown' -# Need to set the preceding variable on all platforms that support -# interlibrary dependencies. -# 'none' -- dependencies not supported. -# `unknown' -- same as none, but documents that we really don't know. -# 'pass_all' -- all dependencies passed with no checks. -# 'test_compile' -- check by making test program. -# 'file_magic [[regex]]' -- check by looking for files in library path -# which responds to the $file_magic_cmd with a given extended regex. -# If you have `file' or equivalent on your system and you're not sure -# whether `pass_all' will *always* work, you probably want this one. - -case $host_os in -aix[4-9]*) - lt_cv_deplibs_check_method=pass_all - ;; + fi +fi +# Provide some information about the compiler. +$as_echo "$as_me:$LINENO: checking for C++ compiler version" >&5 +set X $ac_compile +ac_compiler=$2 +{ (ac_try="$ac_compiler --version >&5" +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_compiler --version >&5") 2>&5 + ac_status=$? + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } +{ (ac_try="$ac_compiler -v >&5" +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_compiler -v >&5") 2>&5 + ac_status=$? + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } +{ (ac_try="$ac_compiler -V >&5" +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_compiler -V >&5") 2>&5 + ac_status=$? + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } -beos*) - lt_cv_deplibs_check_method=pass_all - ;; +{ $as_echo "$as_me:$LINENO: checking whether we are using the GNU C++ compiler" >&5 +$as_echo_n "checking whether we are using the GNU C++ compiler... " >&6; } +if test "${ac_cv_cxx_compiler_gnu+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. */ -bsdi[45]*) - lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)' - lt_cv_file_magic_cmd='/usr/bin/file -L' - lt_cv_file_magic_test_file=/shlib/libc.so - ;; +int +main () +{ +#ifndef __GNUC__ + choke me +#endif -cygwin*) - # func_win32_libid is a shell function defined in ltmain.sh - lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' - lt_cv_file_magic_cmd='func_win32_libid' - ;; + ; + 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_cxx_werror_flag" || + test ! -s conftest.err + } && test -s conftest.$ac_objext; then + ac_compiler_gnu=yes +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 -mingw* | pw32*) - # Base MSYS/MinGW do not provide the 'file' command needed by - # func_win32_libid shell function, so use a weaker test based on 'objdump', - # unless we find 'file', for example because we are cross-compiling. - if ( file / ) >/dev/null 2>&1; then - lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' - lt_cv_file_magic_cmd='func_win32_libid' - else - lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?' - lt_cv_file_magic_cmd='$OBJDUMP -f' - fi - ;; + ac_compiler_gnu=no +fi -cegcc) - # use the weaker test based on 'objdump'. See mingw*. - lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?' - lt_cv_file_magic_cmd='$OBJDUMP -f' - ;; +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +ac_cv_cxx_compiler_gnu=$ac_compiler_gnu -darwin* | rhapsody*) - lt_cv_deplibs_check_method=pass_all - ;; +fi +{ $as_echo "$as_me:$LINENO: result: $ac_cv_cxx_compiler_gnu" >&5 +$as_echo "$ac_cv_cxx_compiler_gnu" >&6; } +if test $ac_compiler_gnu = yes; then + GXX=yes +else + GXX= +fi +ac_test_CXXFLAGS=${CXXFLAGS+set} +ac_save_CXXFLAGS=$CXXFLAGS +{ $as_echo "$as_me:$LINENO: checking whether $CXX accepts -g" >&5 +$as_echo_n "checking whether $CXX accepts -g... " >&6; } +if test "${ac_cv_prog_cxx_g+set}" = set; then + $as_echo_n "(cached) " >&6 +else + ac_save_cxx_werror_flag=$ac_cxx_werror_flag + ac_cxx_werror_flag=yes + ac_cv_prog_cxx_g=no + CXXFLAGS="-g" + cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ -freebsd* | dragonfly*) - if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then - case $host_cpu in - i*86 ) - # Not sure whether the presence of OpenBSD here was a mistake. - # Let's accept both of them until this is cleared up. - lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[3-9]86 (compact )?demand paged shared library' - lt_cv_file_magic_cmd=/usr/bin/file - lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` - ;; - esac - else - lt_cv_deplibs_check_method=pass_all - fi - ;; +int +main () +{ -gnu*) - lt_cv_deplibs_check_method=pass_all - ;; + ; + 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_cxx_werror_flag" || + test ! -s conftest.err + } && test -s conftest.$ac_objext; then + ac_cv_prog_cxx_g=yes +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 -hpux10.20* | hpux11*) - lt_cv_file_magic_cmd=/usr/bin/file - case $host_cpu in - ia64*) - lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64' - lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so - ;; - hppa*64*) - lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - PA-RISC [0-9].[0-9]' - lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl - ;; - *) - lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9].[0-9]) shared library' - lt_cv_file_magic_test_file=/usr/lib/libc.sl - ;; - esac - ;; + CXXFLAGS="" + cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ -interix[3-9]*) - # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here - lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|\.a)$' - ;; +int +main () +{ -irix5* | irix6* | nonstopux*) - case $LD in - *-32|*"-32 ") libmagic=32-bit;; - *-n32|*"-n32 ") libmagic=N32;; - *-64|*"-64 ") libmagic=64-bit;; - *) libmagic=never-match;; - esac - lt_cv_deplibs_check_method=pass_all - ;; + ; + 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_cxx_werror_flag" || + test ! -s conftest.err + } && test -s conftest.$ac_objext; then + : +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 -# This must be Linux ELF. -linux* | k*bsd*-gnu) - lt_cv_deplibs_check_method=pass_all - ;; + ac_cxx_werror_flag=$ac_save_cxx_werror_flag + CXXFLAGS="-g" + cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ -netbsd*) - if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then - lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$' - else - lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|_pic\.a)$' - fi - ;; - -newos6*) - lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)' - lt_cv_file_magic_cmd=/usr/bin/file - lt_cv_file_magic_test_file=/usr/lib/libnls.so - ;; - -*nto* | *qnx*) - lt_cv_deplibs_check_method=pass_all - ;; - -openbsd*) - if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|\.so|_pic\.a)$' - else - lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$' - fi - ;; - -osf3* | osf4* | osf5*) - lt_cv_deplibs_check_method=pass_all - ;; - -rdos*) - lt_cv_deplibs_check_method=pass_all - ;; - -solaris*) - lt_cv_deplibs_check_method=pass_all - ;; - -sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) - lt_cv_deplibs_check_method=pass_all - ;; - -sysv4 | sysv4.3*) - case $host_vendor in - motorola) - lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib) M[0-9][0-9]* Version [0-9]' - lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*` - ;; - ncr) - lt_cv_deplibs_check_method=pass_all - ;; - sequent) - lt_cv_file_magic_cmd='/bin/file' - lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )' - ;; - sni) - lt_cv_file_magic_cmd='/bin/file' - lt_cv_deplibs_check_method="file_magic ELF [0-9][0-9]*-bit [LM]SB dynamic lib" - lt_cv_file_magic_test_file=/lib/libc.so - ;; - siemens) - lt_cv_deplibs_check_method=pass_all - ;; - pc) - lt_cv_deplibs_check_method=pass_all - ;; - esac - ;; +int +main () +{ -tpf*) - lt_cv_deplibs_check_method=pass_all - ;; + ; + 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 - -fi -{ $as_echo "$as_me:$LINENO: result: $lt_cv_deplibs_check_method" >&5 -$as_echo "$lt_cv_deplibs_check_method" >&6; } -file_magic_cmd=$lt_cv_file_magic_cmd -deplibs_check_method=$lt_cv_deplibs_check_method -test -z "$deplibs_check_method" && deplibs_check_method=unknown - +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_cxx_werror_flag" || + test ! -s conftest.err + } && test -s conftest.$ac_objext; then + ac_cv_prog_cxx_g=yes +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + ac_cxx_werror_flag=$ac_save_cxx_werror_flag +fi +{ $as_echo "$as_me:$LINENO: result: $ac_cv_prog_cxx_g" >&5 +$as_echo "$ac_cv_prog_cxx_g" >&6; } +if test "$ac_test_CXXFLAGS" = set; then + CXXFLAGS=$ac_save_CXXFLAGS +elif test $ac_cv_prog_cxx_g = yes; then + if test "$GXX" = yes; then + CXXFLAGS="-g -O2" + else + CXXFLAGS="-g" + fi +else + if test "$GXX" = yes; then + CXXFLAGS="-O2" + else + CXXFLAGS= + fi +fi +ac_ext=cpp +ac_cpp='$CXXCPP $CPPFLAGS' +ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_cxx_compiler_gnu +depcc="$CXX" am_compiler_list= +{ $as_echo "$as_me:$LINENO: checking dependency style of $depcc" >&5 +$as_echo_n "checking dependency style of $depcc... " >&6; } +if test "${am_cv_CXX_dependencies_compiler_type+set}" = set; then + $as_echo_n "(cached) " >&6 +else + if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then + # We make a subdir and do the tests there. Otherwise we can end up + # making bogus files that we don't know about and never remove. For + # instance it was reported that on HP-UX the gcc test will end up + # making a dummy file named `D' -- because `-MD' means `put the output + # in D'. + mkdir conftest.dir + # Copy depcomp to subdir because otherwise we won't find it if we're + # using a relative directory. + cp "$am_depcomp" conftest.dir + cd conftest.dir + # We will build objects and dependencies in a subdirectory because + # it helps to detect inapplicable dependency modes. For instance + # both Tru64's cc and ICC support -MD to output dependencies as a + # side effect of compilation, but ICC will put the dependencies in + # the current directory while Tru64 will put them in the object + # directory. + mkdir sub + am_cv_CXX_dependencies_compiler_type=none + if test "$am_compiler_list" = ""; then + am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp` + fi + am__universal=false + case " $depcc " in #( + *\ -arch\ *\ -arch\ *) am__universal=true ;; + esac + for depmode in $am_compiler_list; do + # Setup a source with many dependencies, because some compilers + # like to wrap large dependency lists on column 80 (with \), and + # we should not choose a depcomp mode which is confused by this. + # + # We need to recreate these files for each test, as the compiler may + # overwrite some of them when testing with obscure command lines. + # This happens at least with the AIX C compiler. + : > sub/conftest.c + for i in 1 2 3 4 5 6; do + echo '#include "conftst'$i'.h"' >> sub/conftest.c + # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with + # Solaris 8's {/usr,}/bin/sh. + touch sub/conftst$i.h + done + echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf + # We check with `-c' and `-o' for the sake of the "dashmstdout" + # mode. It turns out that the SunPro C++ compiler does not properly + # handle `-M -o', and we need to detect this. Also, some Intel + # versions had trouble with output in subdirs + am__obj=sub/conftest.${OBJEXT-o} + am__minus_obj="-o $am__obj" + case $depmode in + gcc) + # This depmode causes a compiler race in universal mode. + test "$am__universal" = false || continue + ;; + nosideeffect) + # after this tag, mechanisms are not by side-effect, so they'll + # only be used when explicitly requested + if test "x$enable_dependency_tracking" = xyes; then + continue + else + break + fi + ;; + msvisualcpp | msvcmsys) + # This compiler won't grok `-c -o', but also, the minuso test has + # not run yet. These depmodes are late enough in the game, and + # so weak that their functioning should not be impacted. + am__obj=conftest.${OBJEXT-o} + am__minus_obj= + ;; + none) break ;; + esac + if depmode=$depmode \ + source=sub/conftest.c object=$am__obj \ + depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ + $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \ + >/dev/null 2>conftest.err && + grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 && + grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && + grep $am__obj sub/conftest.Po > /dev/null 2>&1 && + ${MAKE-make} -s -f confmf > /dev/null 2>&1; then + # icc doesn't choke on unknown options, it will just issue warnings + # or remarks (even with -Werror). So we grep stderr for any message + # that says an option was ignored or not supported. + # When given -MP, icc 7.0 and 7.1 complain thusly: + # icc: Command line warning: ignoring option '-M'; no argument required + # The diagnosis changed in icc 8.0: + # icc: Command line remark: option '-MP' not supported + if (grep 'ignoring option' conftest.err || + grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else + am_cv_CXX_dependencies_compiler_type=$depmode + break + fi + fi + done -if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args. -set dummy ${ac_tool_prefix}ar; 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_prog_AR+set}" = set; then - $as_echo_n "(cached) " >&6 -else - if test -n "$AR"; then - ac_cv_prog_AR="$AR" # Let the user override the test. + cd .. + rm -rf conftest.dir else -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_prog_AR="${ac_tool_prefix}ar" - $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done -done -IFS=$as_save_IFS - + am_cv_CXX_dependencies_compiler_type=none fi + fi -AR=$ac_cv_prog_AR -if test -n "$AR"; then - { $as_echo "$as_me:$LINENO: result: $AR" >&5 -$as_echo "$AR" >&6; } +{ $as_echo "$as_me:$LINENO: result: $am_cv_CXX_dependencies_compiler_type" >&5 +$as_echo "$am_cv_CXX_dependencies_compiler_type" >&6; } +CXXDEPMODE=depmode=$am_cv_CXX_dependencies_compiler_type + + if + test "x$enable_dependency_tracking" != xno \ + && test "$am_cv_CXX_dependencies_compiler_type" = gcc3; then + am__fastdepCXX_TRUE= + am__fastdepCXX_FALSE='#' else - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } + am__fastdepCXX_TRUE='#' + am__fastdepCXX_FALSE= fi -fi -if test -z "$ac_cv_prog_AR"; then - ac_ct_AR=$AR - # Extract the first word of "ar", so it can be a program name with args. -set dummy ar; 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_prog_ac_ct_AR+set}" = set; then + + +if test -n "$CXX" && ( test "X$CXX" != "Xno" && + ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) || + (test "X$CXX" != "Xg++"))) ; then + ac_ext=cpp +ac_cpp='$CXXCPP $CPPFLAGS' +ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_cxx_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; } +if test -z "$CXXCPP"; then + if test "${ac_cv_prog_CXXCPP+set}" = set; then $as_echo_n "(cached) " >&6 else - if test -n "$ac_ct_AR"; then - ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH + # Double quotes because CXXCPP needs to be expanded + for CXXCPP in "$CXX -E" "/lib/cpp" + do + ac_preproc_ok=false +for ac_cxx_preproc_warn_flag in '' yes 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_prog_ac_ct_AR="ar" - $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done -done -IFS=$as_save_IFS - -fi -fi -ac_ct_AR=$ac_cv_prog_ac_ct_AR -if test -n "$ac_ct_AR"; then - { $as_echo "$as_me:$LINENO: result: $ac_ct_AR" >&5 -$as_echo "$ac_ct_AR" >&6; } + # Use a header file that comes with gcc, so configuring glibc + # with a fresh cross-compiler works. + # Prefer to if __STDC__ is defined, since + # 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 +#else +# include +#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_cxx_preproc_warn_flag$ac_cxx_werror_flag" || + test ! -s conftest.err + }; then + : else - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + # Broken: fails on valid input. +continue fi - if test "x$ac_ct_AR" = x; then - AR="false" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; +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 +_ACEOF +if { (ac_try="$ac_cpp conftest.$ac_ext" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; esac - AR=$ac_ct_AR - fi +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_cxx_preproc_warn_flag$ac_cxx_werror_flag" || + test ! -s conftest.err + }; then + # Broken: success on invalid input. +continue else - AR="$ac_cv_prog_AR" + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + # Passes both tests. +ac_preproc_ok=: +break fi -test -z "$AR" && AR=ar -test -z "$AR_FLAGS" && AR_FLAGS=cru +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_CXXCPP=$CXXCPP +fi + CXXCPP=$ac_cv_prog_CXXCPP +else + ac_cv_prog_CXXCPP=$CXXCPP +fi +{ $as_echo "$as_me:$LINENO: result: $CXXCPP" >&5 +$as_echo "$CXXCPP" >&6; } +ac_preproc_ok=false +for ac_cxx_preproc_warn_flag in '' yes +do + # Use a header file that comes with gcc, so configuring glibc + # with a fresh cross-compiler works. + # Prefer to if __STDC__ is defined, since + # 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 +#else +# include +#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_cxx_preproc_warn_flag$ac_cxx_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 +_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_cxx_preproc_warn_flag$ac_cxx_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: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +{ { $as_echo "$as_me:$LINENO: error: C++ preprocessor \"$CXXCPP\" fails sanity check +See \`config.log' for more details." >&5 +$as_echo "$as_me: error: C++ preprocessor \"$CXXCPP\" fails sanity check +See \`config.log' for more details." >&2;} + { (exit 1); exit 1; }; }; } +fi +ac_ext=cpp +ac_cpp='$CXXCPP $CPPFLAGS' +ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_cxx_compiler_gnu +fi +ac_ext=f +ac_compile='$F77 -c $FFLAGS conftest.$ac_ext >&5' +ac_link='$F77 -o conftest$ac_exeext $FFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_f77_compiler_gnu if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args. -set dummy ${ac_tool_prefix}strip; ac_word=$2 + for ac_prog in g77 xlf f77 frt pgf77 cf77 fort77 fl32 af77 xlf90 f90 pgf90 pghpf epcf90 gfortran g95 xlf95 f95 fort ifort ifc efc pgf95 lf95 ftn + do + # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. +set dummy $ac_tool_prefix$ac_prog; 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_prog_STRIP+set}" = set; then +if test "${ac_cv_prog_F77+set}" = set; then $as_echo_n "(cached) " >&6 else - if test -n "$STRIP"; then - ac_cv_prog_STRIP="$STRIP" # Let the user override the test. + if test -n "$F77"; then + ac_cv_prog_F77="$F77" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH @@ -6005,7 +6529,7 @@ do 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_prog_STRIP="${ac_tool_prefix}strip" + ac_cv_prog_F77="$ac_tool_prefix$ac_prog" $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi @@ -6015,28 +6539,32 @@ IFS=$as_save_IFS fi fi -STRIP=$ac_cv_prog_STRIP -if test -n "$STRIP"; then - { $as_echo "$as_me:$LINENO: result: $STRIP" >&5 -$as_echo "$STRIP" >&6; } +F77=$ac_cv_prog_F77 +if test -n "$F77"; then + { $as_echo "$as_me:$LINENO: result: $F77" >&5 +$as_echo "$F77" >&6; } else { $as_echo "$as_me:$LINENO: result: no" >&5 $as_echo "no" >&6; } fi + test -n "$F77" && break + done fi -if test -z "$ac_cv_prog_STRIP"; then - ac_ct_STRIP=$STRIP - # Extract the first word of "strip", so it can be a program name with args. -set dummy strip; ac_word=$2 +if test -z "$F77"; then + ac_ct_F77=$F77 + for ac_prog in g77 xlf f77 frt pgf77 cf77 fort77 fl32 af77 xlf90 f90 pgf90 pghpf epcf90 gfortran g95 xlf95 f95 fort ifort ifc efc pgf95 lf95 ftn +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; 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_prog_ac_ct_STRIP+set}" = set; then +if test "${ac_cv_prog_ac_ct_F77+set}" = set; then $as_echo_n "(cached) " >&6 else - if test -n "$ac_ct_STRIP"; then - ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. + if test -n "$ac_ct_F77"; then + ac_cv_prog_ac_ct_F77="$ac_ct_F77" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH @@ -6045,7 +6573,7 @@ do 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_prog_ac_ct_STRIP="strip" + ac_cv_prog_ac_ct_F77="$ac_prog" $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi @@ -6055,17 +6583,21 @@ IFS=$as_save_IFS fi fi -ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP -if test -n "$ac_ct_STRIP"; then - { $as_echo "$as_me:$LINENO: result: $ac_ct_STRIP" >&5 -$as_echo "$ac_ct_STRIP" >&6; } +ac_ct_F77=$ac_cv_prog_ac_ct_F77 +if test -n "$ac_ct_F77"; then + { $as_echo "$as_me:$LINENO: result: $ac_ct_F77" >&5 +$as_echo "$ac_ct_F77" >&6; } else { $as_echo "$as_me:$LINENO: result: no" >&5 $as_echo "no" >&6; } fi - if test "x$ac_ct_STRIP" = x; then - STRIP=":" + + test -n "$ac_ct_F77" && break +done + + if test "x$ac_ct_F77" = x; then + F77="" else case $cross_compiling:$ac_tool_warned in yes:) @@ -6073,176 +6605,297 @@ yes:) $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac - STRIP=$ac_ct_STRIP + F77=$ac_ct_F77 fi -else - STRIP="$ac_cv_prog_STRIP" fi -test -z "$STRIP" && STRIP=: - - - - - -if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args. -set dummy ${ac_tool_prefix}ranlib; 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_prog_RANLIB+set}" = set; then +# Provide some information about the compiler. +$as_echo "$as_me:$LINENO: checking for Fortran 77 compiler version" >&5 +set X $ac_compile +ac_compiler=$2 +{ (ac_try="$ac_compiler --version >&5" +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_compiler --version >&5") 2>&5 + ac_status=$? + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } +{ (ac_try="$ac_compiler -v >&5" +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_compiler -v >&5") 2>&5 + ac_status=$? + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } +{ (ac_try="$ac_compiler -V >&5" +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_compiler -V >&5") 2>&5 + ac_status=$? + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } +rm -f a.out + +# If we don't use `.F' as extension, the preprocessor is not run on the +# input file. (Note that this only needs to work for GNU compilers.) +ac_save_ext=$ac_ext +ac_ext=F +{ $as_echo "$as_me:$LINENO: checking whether we are using the GNU Fortran 77 compiler" >&5 +$as_echo_n "checking whether we are using the GNU Fortran 77 compiler... " >&6; } +if test "${ac_cv_f77_compiler_gnu+set}" = set; then $as_echo_n "(cached) " >&6 else - if test -n "$RANLIB"; then - ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. -else -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_prog_RANLIB="${ac_tool_prefix}ranlib" - $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done -done -IFS=$as_save_IFS + cat >conftest.$ac_ext <<_ACEOF + program main +#ifndef __GNUC__ + choke me +#endif -fi -fi -RANLIB=$ac_cv_prog_RANLIB -if test -n "$RANLIB"; then - { $as_echo "$as_me:$LINENO: result: $RANLIB" >&5 -$as_echo "$RANLIB" >&6; } + end +_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_f77_werror_flag" || + test ! -s conftest.err + } && test -s conftest.$ac_objext; then + ac_compiler_gnu=yes else - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } -fi - + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + ac_compiler_gnu=no fi -if test -z "$ac_cv_prog_RANLIB"; then - ac_ct_RANLIB=$RANLIB - # Extract the first word of "ranlib", so it can be a program name with args. -set dummy ranlib; 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_prog_ac_ct_RANLIB+set}" = set; then + +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +ac_cv_f77_compiler_gnu=$ac_compiler_gnu + +fi +{ $as_echo "$as_me:$LINENO: result: $ac_cv_f77_compiler_gnu" >&5 +$as_echo "$ac_cv_f77_compiler_gnu" >&6; } +ac_ext=$ac_save_ext +ac_test_FFLAGS=${FFLAGS+set} +ac_save_FFLAGS=$FFLAGS +FFLAGS= +{ $as_echo "$as_me:$LINENO: checking whether $F77 accepts -g" >&5 +$as_echo_n "checking whether $F77 accepts -g... " >&6; } +if test "${ac_cv_prog_f77_g+set}" = set; then $as_echo_n "(cached) " >&6 else - if test -n "$ac_ct_RANLIB"; then - ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test. -else -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_prog_ac_ct_RANLIB="ranlib" - $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done -done -IFS=$as_save_IFS + FFLAGS=-g +cat >conftest.$ac_ext <<_ACEOF + program main -fi -fi -ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB -if test -n "$ac_ct_RANLIB"; then - { $as_echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5 -$as_echo "$ac_ct_RANLIB" >&6; } + end +_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_f77_werror_flag" || + test ! -s conftest.err + } && test -s conftest.$ac_objext; then + ac_cv_prog_f77_g=yes else - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_cv_prog_f77_g=no fi - if test "x$ac_ct_RANLIB" = x; then - RANLIB=":" +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + +fi +{ $as_echo "$as_me:$LINENO: result: $ac_cv_prog_f77_g" >&5 +$as_echo "$ac_cv_prog_f77_g" >&6; } +if test "$ac_test_FFLAGS" = set; then + FFLAGS=$ac_save_FFLAGS +elif test $ac_cv_prog_f77_g = yes; then + if test "x$ac_cv_f77_compiler_gnu" = xyes; then + FFLAGS="-g -O2" else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - RANLIB=$ac_ct_RANLIB + FFLAGS="-g" fi else - RANLIB="$ac_cv_prog_RANLIB" + if test "x$ac_cv_f77_compiler_gnu" = xyes; then + FFLAGS="-O2" + else + FFLAGS= + fi fi -test -z "$RANLIB" && RANLIB=: - - - +if test $ac_compiler_gnu = yes; then + G77=yes +else + G77= +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 -# Determine commands to create old-style static archives. -old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs' -old_postinstall_cmds='chmod 644 $oldlib' -old_postuninstall_cmds= +# Autoconf 2.13's AC_OBJEXT and AC_EXEEXT macros only works for C compilers! +# find the maximum length of command line arguments +{ $as_echo "$as_me:$LINENO: checking the maximum length of command line arguments" >&5 +$as_echo_n "checking the maximum length of command line arguments... " >&6; } +if test "${lt_cv_sys_max_cmd_len+set}" = set; then + $as_echo_n "(cached) " >&6 +else + i=0 + teststring="ABCD" -if test -n "$RANLIB"; then - case $host_os in - openbsd*) - old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$oldlib" - ;; - *) - old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$oldlib" + case $build_os in + msdosdjgpp*) + # On DJGPP, this test can blow up pretty badly due to problems in libc + # (any single argument exceeding 2000 bytes causes a buffer overrun + # during glob expansion). Even if it were fixed, the result of this + # check would be larger than it should be. + lt_cv_sys_max_cmd_len=12288; # 12K is about right ;; - esac - old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib" -fi - - - - - - - - - - - - - - - - - - - - - - - - - + gnu*) + # Under GNU Hurd, this test is not required because there is + # no limit to the length of command line arguments. + # Libtool will interpret -1 as no limit whatsoever + lt_cv_sys_max_cmd_len=-1; + ;; + cygwin* | mingw*) + # On Win9x/ME, this test blows up -- it succeeds, but takes + # about 5 minutes as the teststring grows exponentially. + # Worse, since 9x/ME are not pre-emptively multitasking, + # you end up with a "frozen" computer, even though with patience + # the test eventually succeeds (with a max line length of 256k). + # Instead, let's just punt: use the minimum linelength reported by + # all of the supported platforms: 8192 (on NT/2K/XP). + lt_cv_sys_max_cmd_len=8192; + ;; + amigaos*) + # On AmigaOS with pdksh, this test takes hours, literally. + # So we just punt and use a minimum line length of 8192. + lt_cv_sys_max_cmd_len=8192; + ;; + netbsd* | freebsd* | openbsd* | darwin* | dragonfly*) + # This has been around since 386BSD, at least. Likely further. + if test -x /sbin/sysctl; then + lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` + elif test -x /usr/sbin/sysctl; then + lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax` + else + lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs + fi + # And add a safety zone + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` + ;; + interix*) + # We know the value 262144 and hardcode it with a safety zone (like BSD) + lt_cv_sys_max_cmd_len=196608 + ;; + osf*) + # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure + # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not + # nice to cause kernel panics so lets avoid the loop below. + # First set a reasonable default. + lt_cv_sys_max_cmd_len=16384 + # + if test -x /sbin/sysconfig; then + case `/sbin/sysconfig -q proc exec_disable_arg_limit` in + *1*) lt_cv_sys_max_cmd_len=-1 ;; + esac + fi + ;; + sco3.2v5*) + lt_cv_sys_max_cmd_len=102400 + ;; + sysv5* | sco5v6* | sysv4.2uw2*) + kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null` + if test -n "$kargmax"; then + lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[ ]//'` + else + lt_cv_sys_max_cmd_len=32768 + fi + ;; + *) + lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null` + if test -n "$lt_cv_sys_max_cmd_len"; then + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` + else + SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}} + while (test "X"`$SHELL $0 --fallback-echo "X$teststring" 2>/dev/null` \ + = "XX$teststring") >/dev/null 2>&1 && + new_result=`expr "X$teststring" : ".*" 2>&1` && + lt_cv_sys_max_cmd_len=$new_result && + test $i != 17 # 1/2 MB should be enough + do + i=`expr $i + 1` + teststring=$teststring$teststring + done + teststring= + # Add a significant safety factor because C++ compilers can tack on massive + # amounts of additional arguments before passing them to the linker. + # It appears as though 1/2 is a usable value. + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2` + fi + ;; + esac +fi +if test -n $lt_cv_sys_max_cmd_len ; then + { $as_echo "$as_me:$LINENO: result: $lt_cv_sys_max_cmd_len" >&5 +$as_echo "$lt_cv_sys_max_cmd_len" >&6; } +else + { $as_echo "$as_me:$LINENO: result: none" >&5 +$as_echo "none" >&6; } +fi -# If no C compiler was specified, use CC. -LTCC=${LTCC-"$CC"} -# If no C compiler flags were specified, use CFLAGS. -LTCFLAGS=${LTCFLAGS-"$CFLAGS"} -# Allow CC to be a program name with arguments. -compiler=$CC # Check for command to grab the raw symbol name followed by C symbol from nm. @@ -6261,18 +6914,33 @@ symcode='[BCDEGRST]' # Regexp to match symbols that can be accessed directly from C. sympat='\([_A-Za-z][_A-Za-z0-9]*\)' +# Transform an extracted symbol line into a proper C declaration +lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^. .* \(.*\)$/extern int \1;/p'" + +# Transform an extracted symbol line into symbol name and symbol address +lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode \([^ ]*\) \([^ ]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'" + # Define system-specific variables. case $host_os in aix*) symcode='[BCDT]' ;; -cygwin* | mingw* | pw32* | cegcc*) +cygwin* | mingw* | pw32*) symcode='[ABCDGISTW]' ;; -hpux*) +hpux*) # Its linker distinguishes data from code symbols if test "$host_cpu" = ia64; then symcode='[ABCDEGRST]' fi + lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'" + lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'" + ;; +linux* | k*bsd*-gnu) + if test "$host_cpu" = ia64; then + symcode='[ABCDGIRSTW]' + lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'" + lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'" + fi ;; irix* | nonstopux*) symcode='[BCDEGRST]' @@ -6297,72 +6965,44 @@ sysv4) ;; esac -# If we're using GNU nm, then use its standard symbol codes. -case `$NM -V 2>&1` in -*GNU* | *'with BFD'*) - symcode='[ABCDGIRSTW]' ;; -esac - -# Transform an extracted symbol line into a proper C declaration. -# Some systems (esp. on ia64) link data and code symbols differently, -# so use this general approach. -lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'" - -# Transform an extracted symbol line into symbol name and symbol address -lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\) $/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"\2\", (void *) \&\2},/p'" -lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([^ ]*\) $/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \(lib[^ ]*\)$/ {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"lib\2\", (void *) \&\2},/p'" - # Handle CRLF in mingw tool chain opt_cr= case $build_os in mingw*) - opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp + opt_cr=`echo 'x\{0,1\}' | tr x '\015'` # option cr in regexp ;; esac -# Try without a prefix underscore, then with it. +# If we're using GNU nm, then use its standard symbol codes. +case `$NM -V 2>&1` in +*GNU* | *'with BFD'*) + symcode='[ABCDGIRSTW]' ;; +esac + +# Try without a prefix undercore, then with it. for ac_symprfx in "" "_"; do # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol. symxfrm="\\1 $ac_symprfx\\2 \\2" # Write the raw and C identifiers. - if test "$lt_cv_nm_interface" = "MS dumpbin"; then - # Fake it for dumpbin and say T for any non-static function - # and D for any global variable. - # Also find C++ and __fastcall symbols from MSVC++, - # which start with @ or ?. - lt_cv_sys_global_symbol_pipe="$AWK '"\ -" {last_section=section; section=\$ 3};"\ -" /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\ -" \$ 0!~/External *\|/{next};"\ -" / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\ -" {if(hide[section]) next};"\ -" {f=0}; \$ 0~/\(\).*\|/{f=1}; {printf f ? \"T \" : \"D \"};"\ -" {split(\$ 0, a, /\||\r/); split(a[2], s)};"\ -" s[1]~/^[@?]/{print s[1], s[1]; next};"\ -" s[1]~prfx {split(s[1],t,\"@\"); print t[1], substr(t[1],length(prfx))}"\ -" ' prfx=^$ac_symprfx" - else - lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[ ]\($symcode$symcode*\)[ ][ ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" - fi + lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[ ]\($symcode$symcode*\)[ ][ ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" # Check to see that the pipe works correctly. pipe_works=no rm -f conftest* - cat > conftest.$ac_ext <<_LT_EOF + cat > conftest.$ac_ext <&5 (eval $ac_compile) 2>&5 @@ -6384,44 +7024,42 @@ _LT_EOF fi # Make sure that we snagged all the symbols we need. - if $GREP ' nm_test_var$' "$nlist" >/dev/null; then - if $GREP ' nm_test_func$' "$nlist" >/dev/null; then - cat <<_LT_EOF > conftest.$ac_ext + if grep ' nm_test_var$' "$nlist" >/dev/null; then + if grep ' nm_test_func$' "$nlist" >/dev/null; then + cat < conftest.$ac_ext #ifdef __cplusplus extern "C" { #endif -_LT_EOF +EOF # Now generate the symbol file. - eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext' + eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | grep -v main >> conftest.$ac_ext' - cat <<_LT_EOF >> conftest.$ac_ext + cat <> conftest.$ac_ext +#if defined (__STDC__) && __STDC__ +# define lt_ptr_t void * +#else +# define lt_ptr_t char * +# define const +#endif -/* The mapping between symbol names and symbols. */ +/* The mapping between symbol names and symbols. */ const struct { const char *name; - void *address; + lt_ptr_t address; } -lt__PROGRAM__LTX_preloaded_symbols[] = +lt_preloaded_symbols[] = { - { "@PROGRAM@", (void *) 0 }, -_LT_EOF - $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (void *) \&\2},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext - cat <<\_LT_EOF >> conftest.$ac_ext - {0, (void *) 0} +EOF + $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (lt_ptr_t) \&\2},/" < "$nlist" | grep -v main >> conftest.$ac_ext + cat <<\EOF >> conftest.$ac_ext + {0, (lt_ptr_t) 0} }; -/* This works around a problem in FreeBSD linker */ -#ifdef FREEBSD_WORKAROUND -static const void *lt_preloaded_setup() { - return lt__PROGRAM__LTX_preloaded_symbols; -} -#endif - #ifdef __cplusplus } #endif -_LT_EOF +EOF # Now try linking the two files. mv conftest.$ac_objext conftstm.$ac_objext lt_save_LIBS="$LIBS" @@ -6473,262 +7111,172 @@ else $as_echo "ok" >&6; } fi +{ $as_echo "$as_me:$LINENO: checking for objdir" >&5 +$as_echo_n "checking for objdir... " >&6; } +if test "${lt_cv_objdir+set}" = set; then + $as_echo_n "(cached) " >&6 +else + rm -f .libs 2>/dev/null +mkdir .libs 2>/dev/null +if test -d .libs; then + lt_cv_objdir=.libs +else + # MS-DOS does not allow filenames that begin with a dot. + lt_cv_objdir=_libs +fi +rmdir .libs 2>/dev/null +fi +{ $as_echo "$as_me:$LINENO: result: $lt_cv_objdir" >&5 +$as_echo "$lt_cv_objdir" >&6; } +objdir=$lt_cv_objdir +case $host_os in +aix3*) + # AIX sometimes has problems with the GCC collect2 program. For some + # reason, if we set the COLLECT_NAMES environment variable, the problems + # vanish in a puff of smoke. + if test "X${COLLECT_NAMES+set}" != Xset; then + COLLECT_NAMES= + export COLLECT_NAMES + fi + ;; +esac +# Sed substitution that helps us do robust quoting. It backslashifies +# metacharacters that are still active within double-quoted strings. +Xsed='sed -e 1s/^X//' +sed_quote_subst='s/\([\\"\\`$\\\\]\)/\\\1/g' +# Same as above, but do not quote variable references. +double_quote_subst='s/\([\\"\\`\\\\]\)/\\\1/g' +# Sed substitution to delay expansion of an escaped shell variable in a +# double_quote_subst'ed string. +delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g' +# Sed substitution to avoid accidental globbing in evaled expressions +no_glob_subst='s/\*/\\\*/g' +# Constants: +rm="rm -f" +# Global variables: +default_ofile=libtool +can_build_shared=yes +# All known linkers require a `.a' archive for static linking (except MSVC, +# which needs '.lib'). +libext=a +ltmain="$ac_aux_dir/ltmain.sh" +ofile="$default_ofile" +with_gnu_ld="$lt_cv_prog_gnu_ld" +if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args. +set dummy ${ac_tool_prefix}ar; 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_prog_AR+set}" = set; then + $as_echo_n "(cached) " >&6 +else + if test -n "$AR"; then + ac_cv_prog_AR="$AR" # Let the user override the test. +else +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_prog_AR="${ac_tool_prefix}ar" + $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done +done +IFS=$as_save_IFS +fi +fi +AR=$ac_cv_prog_AR +if test -n "$AR"; then + { $as_echo "$as_me:$LINENO: result: $AR" >&5 +$as_echo "$AR" >&6; } +else + { $as_echo "$as_me:$LINENO: result: no" >&5 +$as_echo "no" >&6; } +fi +fi +if test -z "$ac_cv_prog_AR"; then + ac_ct_AR=$AR + # Extract the first word of "ar", so it can be a program name with args. +set dummy ar; 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_prog_ac_ct_AR+set}" = set; then + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_AR"; then + ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. +else +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_prog_ac_ct_AR="ar" + $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done +done +IFS=$as_save_IFS - - - - -# Check whether --enable-libtool-lock was given. -if test "${enable_libtool_lock+set}" = set; then - enableval=$enable_libtool_lock; +fi +fi +ac_ct_AR=$ac_cv_prog_ac_ct_AR +if test -n "$ac_ct_AR"; then + { $as_echo "$as_me:$LINENO: result: $ac_ct_AR" >&5 +$as_echo "$ac_ct_AR" >&6; } +else + { $as_echo "$as_me:$LINENO: result: no" >&5 +$as_echo "no" >&6; } fi -test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes + if test "x$ac_ct_AR" = x; then + AR="false" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + AR=$ac_ct_AR + fi +else + AR="$ac_cv_prog_AR" +fi -# Some flags need to be propagated to the compiler or linker for good -# libtool support. -case $host in -ia64-*-hpux*) - # Find out which ABI we are using. - echo 'int i;' > conftest.$ac_ext - if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; then - case `/usr/bin/file conftest.$ac_objext` in - *ELF-32*) - HPUX_IA64_MODE="32" - ;; - *ELF-64*) - HPUX_IA64_MODE="64" - ;; - esac - fi - rm -rf conftest* - ;; -*-*-irix6*) - # Find out which ABI we are using. - echo '#line 6528 "configure"' > conftest.$ac_ext - if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; then - if test "$lt_cv_prog_gnu_ld" = yes; then - case `/usr/bin/file conftest.$ac_objext` in - *32-bit*) - LD="${LD-ld} -melf32bsmip" - ;; - *N32*) - LD="${LD-ld} -melf32bmipn32" - ;; - *64-bit*) - LD="${LD-ld} -melf64bmip" - ;; - esac - else - case `/usr/bin/file conftest.$ac_objext` in - *32-bit*) - LD="${LD-ld} -32" - ;; - *N32*) - LD="${LD-ld} -n32" - ;; - *64-bit*) - LD="${LD-ld} -64" - ;; - esac - fi - fi - rm -rf conftest* - ;; - -x86_64-*kfreebsd*-gnu|x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*| \ -s390*-*linux*|s390*-*tpf*|sparc*-*linux*) - # Find out which ABI we are using. - echo 'int i;' > conftest.$ac_ext - if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; then - case `/usr/bin/file conftest.o` in - *32-bit*) - case $host in - x86_64-*kfreebsd*-gnu) - LD="${LD-ld} -m elf_i386_fbsd" - ;; - x86_64-*linux*) - LD="${LD-ld} -m elf_i386" - ;; - ppc64-*linux*|powerpc64-*linux*) - LD="${LD-ld} -m elf32ppclinux" - ;; - s390x-*linux*) - LD="${LD-ld} -m elf_s390" - ;; - sparc64-*linux*) - LD="${LD-ld} -m elf32_sparc" - ;; - esac - ;; - *64-bit*) - case $host in - x86_64-*kfreebsd*-gnu) - LD="${LD-ld} -m elf_x86_64_fbsd" - ;; - x86_64-*linux*) - LD="${LD-ld} -m elf_x86_64" - ;; - ppc*-*linux*|powerpc*-*linux*) - LD="${LD-ld} -m elf64ppc" - ;; - s390*-*linux*|s390*-*tpf*) - LD="${LD-ld} -m elf64_s390" - ;; - sparc*-*linux*) - LD="${LD-ld} -m elf64_sparc" - ;; - esac - ;; - esac - fi - rm -rf conftest* - ;; - -*-*-sco3.2v5*) - # On SCO OpenServer 5, we need -belf to get full-featured binaries. - SAVE_CFLAGS="$CFLAGS" - CFLAGS="$CFLAGS -belf" - { $as_echo "$as_me:$LINENO: checking whether the C compiler needs -belf" >&5 -$as_echo_n "checking whether the C compiler needs -belf... " >&6; } -if test "${lt_cv_cc_needs_belf+set}" = set; then - $as_echo_n "(cached) " >&6 -else - 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 - - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext 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>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_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - lt_cv_cc_needs_belf=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - lt_cv_cc_needs_belf=no -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext - 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 - -fi -{ $as_echo "$as_me:$LINENO: result: $lt_cv_cc_needs_belf" >&5 -$as_echo "$lt_cv_cc_needs_belf" >&6; } - if test x"$lt_cv_cc_needs_belf" != x"yes"; then - # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf - CFLAGS="$SAVE_CFLAGS" - fi - ;; -sparc*-*solaris*) - # Find out which ABI we are using. - echo 'int i;' > conftest.$ac_ext - if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; then - case `/usr/bin/file conftest.o` in - *64-bit*) - case $lt_cv_prog_gnu_ld in - yes*) LD="${LD-ld} -m elf64_sparc" ;; - *) - if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then - LD="${LD-ld} -64" - fi - ;; - esac - ;; - esac - fi - rm -rf conftest* - ;; -esac - -need_locks="$enable_libtool_lock" - - - case $host_os in - rhapsody* | darwin*) - if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}dsymutil", so it can be a program name with args. -set dummy ${ac_tool_prefix}dsymutil; ac_word=$2 +if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args. +set dummy ${ac_tool_prefix}ranlib; 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_prog_DSYMUTIL+set}" = set; then +if test "${ac_cv_prog_RANLIB+set}" = set; then $as_echo_n "(cached) " >&6 else - if test -n "$DSYMUTIL"; then - ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test. + if test -n "$RANLIB"; then + ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH @@ -6737,7 +7285,7 @@ do 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_prog_DSYMUTIL="${ac_tool_prefix}dsymutil" + ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib" $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi @@ -6747,10 +7295,10 @@ IFS=$as_save_IFS fi fi -DSYMUTIL=$ac_cv_prog_DSYMUTIL -if test -n "$DSYMUTIL"; then - { $as_echo "$as_me:$LINENO: result: $DSYMUTIL" >&5 -$as_echo "$DSYMUTIL" >&6; } +RANLIB=$ac_cv_prog_RANLIB +if test -n "$RANLIB"; then + { $as_echo "$as_me:$LINENO: result: $RANLIB" >&5 +$as_echo "$RANLIB" >&6; } else { $as_echo "$as_me:$LINENO: result: no" >&5 $as_echo "no" >&6; } @@ -6758,17 +7306,17 @@ fi fi -if test -z "$ac_cv_prog_DSYMUTIL"; then - ac_ct_DSYMUTIL=$DSYMUTIL - # Extract the first word of "dsymutil", so it can be a program name with args. -set dummy dsymutil; ac_word=$2 +if test -z "$ac_cv_prog_RANLIB"; then + ac_ct_RANLIB=$RANLIB + # Extract the first word of "ranlib", so it can be a program name with args. +set dummy ranlib; 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_prog_ac_ct_DSYMUTIL+set}" = set; then +if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then $as_echo_n "(cached) " >&6 else - if test -n "$ac_ct_DSYMUTIL"; then - ac_cv_prog_ac_ct_DSYMUTIL="$ac_ct_DSYMUTIL" # Let the user override the test. + if test -n "$ac_ct_RANLIB"; then + ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH @@ -6777,7 +7325,7 @@ do 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_prog_ac_ct_DSYMUTIL="dsymutil" + ac_cv_prog_ac_ct_RANLIB="ranlib" $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi @@ -6787,17 +7335,17 @@ IFS=$as_save_IFS fi fi -ac_ct_DSYMUTIL=$ac_cv_prog_ac_ct_DSYMUTIL -if test -n "$ac_ct_DSYMUTIL"; then - { $as_echo "$as_me:$LINENO: result: $ac_ct_DSYMUTIL" >&5 -$as_echo "$ac_ct_DSYMUTIL" >&6; } +ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB +if test -n "$ac_ct_RANLIB"; then + { $as_echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5 +$as_echo "$ac_ct_RANLIB" >&6; } else { $as_echo "$as_me:$LINENO: result: no" >&5 $as_echo "no" >&6; } fi - if test "x$ac_ct_DSYMUTIL" = x; then - DSYMUTIL=":" + if test "x$ac_ct_RANLIB" = x; then + RANLIB=":" else case $cross_compiling:$ac_tool_warned in yes:) @@ -6805,22 +7353,22 @@ yes:) $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac - DSYMUTIL=$ac_ct_DSYMUTIL + RANLIB=$ac_ct_RANLIB fi else - DSYMUTIL="$ac_cv_prog_DSYMUTIL" + RANLIB="$ac_cv_prog_RANLIB" fi - if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}nmedit", so it can be a program name with args. -set dummy ${ac_tool_prefix}nmedit; ac_word=$2 +if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args. +set dummy ${ac_tool_prefix}strip; 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_prog_NMEDIT+set}" = set; then +if test "${ac_cv_prog_STRIP+set}" = set; then $as_echo_n "(cached) " >&6 else - if test -n "$NMEDIT"; then - ac_cv_prog_NMEDIT="$NMEDIT" # Let the user override the test. + if test -n "$STRIP"; then + ac_cv_prog_STRIP="$STRIP" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH @@ -6829,7 +7377,7 @@ do 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_prog_NMEDIT="${ac_tool_prefix}nmedit" + ac_cv_prog_STRIP="${ac_tool_prefix}strip" $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi @@ -6839,10 +7387,10 @@ IFS=$as_save_IFS fi fi -NMEDIT=$ac_cv_prog_NMEDIT -if test -n "$NMEDIT"; then - { $as_echo "$as_me:$LINENO: result: $NMEDIT" >&5 -$as_echo "$NMEDIT" >&6; } +STRIP=$ac_cv_prog_STRIP +if test -n "$STRIP"; then + { $as_echo "$as_me:$LINENO: result: $STRIP" >&5 +$as_echo "$STRIP" >&6; } else { $as_echo "$as_me:$LINENO: result: no" >&5 $as_echo "no" >&6; } @@ -6850,17 +7398,17 @@ fi fi -if test -z "$ac_cv_prog_NMEDIT"; then - ac_ct_NMEDIT=$NMEDIT - # Extract the first word of "nmedit", so it can be a program name with args. -set dummy nmedit; ac_word=$2 +if test -z "$ac_cv_prog_STRIP"; then + ac_ct_STRIP=$STRIP + # Extract the first word of "strip", so it can be a program name with args. +set dummy strip; 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_prog_ac_ct_NMEDIT+set}" = set; then +if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then $as_echo_n "(cached) " >&6 else - if test -n "$ac_ct_NMEDIT"; then - ac_cv_prog_ac_ct_NMEDIT="$ac_ct_NMEDIT" # Let the user override the test. + if test -n "$ac_ct_STRIP"; then + ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH @@ -6869,7 +7417,7 @@ do 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_prog_ac_ct_NMEDIT="nmedit" + ac_cv_prog_ac_ct_STRIP="strip" $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi @@ -6879,17 +7427,17 @@ IFS=$as_save_IFS fi fi -ac_ct_NMEDIT=$ac_cv_prog_ac_ct_NMEDIT -if test -n "$ac_ct_NMEDIT"; then - { $as_echo "$as_me:$LINENO: result: $ac_ct_NMEDIT" >&5 -$as_echo "$ac_ct_NMEDIT" >&6; } +ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP +if test -n "$ac_ct_STRIP"; then + { $as_echo "$as_me:$LINENO: result: $ac_ct_STRIP" >&5 +$as_echo "$ac_ct_STRIP" >&6; } else { $as_echo "$as_me:$LINENO: result: no" >&5 $as_echo "no" >&6; } fi - if test "x$ac_ct_NMEDIT" = x; then - NMEDIT=":" + if test "x$ac_ct_STRIP" = x; then + STRIP=":" else case $cross_compiling:$ac_tool_warned in yes:) @@ -6897,22 +7445,210 @@ yes:) $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac - NMEDIT=$ac_ct_NMEDIT + STRIP=$ac_ct_STRIP fi else - NMEDIT="$ac_cv_prog_NMEDIT" + STRIP="$ac_cv_prog_STRIP" +fi + + +old_CC="$CC" +old_CFLAGS="$CFLAGS" + +# Set sane defaults for various variables +test -z "$AR" && AR=ar +test -z "$AR_FLAGS" && AR_FLAGS=cru +test -z "$AS" && AS=as +test -z "$CC" && CC=cc +test -z "$LTCC" && LTCC=$CC +test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS +test -z "$DLLTOOL" && DLLTOOL=dlltool +test -z "$LD" && LD=ld +test -z "$LN_S" && LN_S="ln -s" +test -z "$MAGIC_CMD" && MAGIC_CMD=file +test -z "$NM" && NM=nm +test -z "$SED" && SED=sed +test -z "$OBJDUMP" && OBJDUMP=objdump +test -z "$RANLIB" && RANLIB=: +test -z "$STRIP" && STRIP=: +test -z "$ac_objext" && ac_objext=o + +# Determine commands to create old-style static archives. +old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs' +old_postinstall_cmds='chmod 644 $oldlib' +old_postuninstall_cmds= + +if test -n "$RANLIB"; then + case $host_os in + openbsd*) + old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$oldlib" + ;; + *) + old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$oldlib" + ;; + esac + old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib" +fi + +for cc_temp in $compiler""; do + case $cc_temp in + compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; + distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; + \-*) ;; + *) break;; + esac +done +cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` + + +# Only perform the check for file, if the check method requires it +case $deplibs_check_method in +file_magic*) + if test "$file_magic_cmd" = '$MAGIC_CMD'; then + { $as_echo "$as_me:$LINENO: checking for ${ac_tool_prefix}file" >&5 +$as_echo_n "checking for ${ac_tool_prefix}file... " >&6; } +if test "${lt_cv_path_MAGIC_CMD+set}" = set; then + $as_echo_n "(cached) " >&6 +else + case $MAGIC_CMD in +[\\/*] | ?:[\\/]*) + lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. + ;; +*) + lt_save_MAGIC_CMD="$MAGIC_CMD" + lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR + ac_dummy="/usr/bin$PATH_SEPARATOR$PATH" + for ac_dir in $ac_dummy; do + IFS="$lt_save_ifs" + test -z "$ac_dir" && ac_dir=. + if test -f $ac_dir/${ac_tool_prefix}file; then + lt_cv_path_MAGIC_CMD="$ac_dir/${ac_tool_prefix}file" + if test -n "$file_magic_test_file"; then + case $deplibs_check_method in + "file_magic "*) + file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` + MAGIC_CMD="$lt_cv_path_MAGIC_CMD" + if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | + $EGREP "$file_magic_regex" > /dev/null; then + : + else + cat <&2 + +*** Warning: the command libtool uses to detect shared libraries, +*** $file_magic_cmd, produces output that libtool cannot recognize. +*** The result is that libtool may fail to recognize shared libraries +*** as such. This will affect the creation of libtool libraries that +*** depend on shared libraries, but programs linked with such libtool +*** libraries will work regardless of this problem. Nevertheless, you +*** may want to report the problem to your system manager and/or to +*** bug-libtool@gnu.org + +EOF + fi ;; + esac + fi + break + fi + done + IFS="$lt_save_ifs" + MAGIC_CMD="$lt_save_MAGIC_CMD" + ;; +esac +fi + +MAGIC_CMD="$lt_cv_path_MAGIC_CMD" +if test -n "$MAGIC_CMD"; then + { $as_echo "$as_me:$LINENO: result: $MAGIC_CMD" >&5 +$as_echo "$MAGIC_CMD" >&6; } +else + { $as_echo "$as_me:$LINENO: result: no" >&5 +$as_echo "no" >&6; } +fi + +if test -z "$lt_cv_path_MAGIC_CMD"; then + if test -n "$ac_tool_prefix"; then + { $as_echo "$as_me:$LINENO: checking for file" >&5 +$as_echo_n "checking for file... " >&6; } +if test "${lt_cv_path_MAGIC_CMD+set}" = set; then + $as_echo_n "(cached) " >&6 +else + case $MAGIC_CMD in +[\\/*] | ?:[\\/]*) + lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. + ;; +*) + lt_save_MAGIC_CMD="$MAGIC_CMD" + lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR + ac_dummy="/usr/bin$PATH_SEPARATOR$PATH" + for ac_dir in $ac_dummy; do + IFS="$lt_save_ifs" + test -z "$ac_dir" && ac_dir=. + if test -f $ac_dir/file; then + lt_cv_path_MAGIC_CMD="$ac_dir/file" + if test -n "$file_magic_test_file"; then + case $deplibs_check_method in + "file_magic "*) + file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` + MAGIC_CMD="$lt_cv_path_MAGIC_CMD" + if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | + $EGREP "$file_magic_regex" > /dev/null; then + : + else + cat <&2 + +*** Warning: the command libtool uses to detect shared libraries, +*** $file_magic_cmd, produces output that libtool cannot recognize. +*** The result is that libtool may fail to recognize shared libraries +*** as such. This will affect the creation of libtool libraries that +*** depend on shared libraries, but programs linked with such libtool +*** libraries will work regardless of this problem. Nevertheless, you +*** may want to report the problem to your system manager and/or to +*** bug-libtool@gnu.org + +EOF + fi ;; + esac + fi + break + fi + done + IFS="$lt_save_ifs" + MAGIC_CMD="$lt_save_MAGIC_CMD" + ;; +esac +fi + +MAGIC_CMD="$lt_cv_path_MAGIC_CMD" +if test -n "$MAGIC_CMD"; then + { $as_echo "$as_me:$LINENO: result: $MAGIC_CMD" >&5 +$as_echo "$MAGIC_CMD" >&6; } +else + { $as_echo "$as_me:$LINENO: result: no" >&5 +$as_echo "no" >&6; } fi + else + MAGIC_CMD=: + fi +fi + + fi + ;; +esac + + + case $host_os in + rhapsody* | darwin*) if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}lipo", so it can be a program name with args. -set dummy ${ac_tool_prefix}lipo; ac_word=$2 + # Extract the first word of "${ac_tool_prefix}dsymutil", so it can be a program name with args. +set dummy ${ac_tool_prefix}dsymutil; 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_prog_LIPO+set}" = set; then +if test "${ac_cv_prog_DSYMUTIL+set}" = set; then $as_echo_n "(cached) " >&6 else - if test -n "$LIPO"; then - ac_cv_prog_LIPO="$LIPO" # Let the user override the test. + if test -n "$DSYMUTIL"; then + ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH @@ -6921,7 +7657,7 @@ do 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_prog_LIPO="${ac_tool_prefix}lipo" + ac_cv_prog_DSYMUTIL="${ac_tool_prefix}dsymutil" $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi @@ -6931,10 +7667,10 @@ IFS=$as_save_IFS fi fi -LIPO=$ac_cv_prog_LIPO -if test -n "$LIPO"; then - { $as_echo "$as_me:$LINENO: result: $LIPO" >&5 -$as_echo "$LIPO" >&6; } +DSYMUTIL=$ac_cv_prog_DSYMUTIL +if test -n "$DSYMUTIL"; then + { $as_echo "$as_me:$LINENO: result: $DSYMUTIL" >&5 +$as_echo "$DSYMUTIL" >&6; } else { $as_echo "$as_me:$LINENO: result: no" >&5 $as_echo "no" >&6; } @@ -6942,17 +7678,17 @@ fi fi -if test -z "$ac_cv_prog_LIPO"; then - ac_ct_LIPO=$LIPO - # Extract the first word of "lipo", so it can be a program name with args. -set dummy lipo; ac_word=$2 +if test -z "$ac_cv_prog_DSYMUTIL"; then + ac_ct_DSYMUTIL=$DSYMUTIL + # Extract the first word of "dsymutil", so it can be a program name with args. +set dummy dsymutil; 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_prog_ac_ct_LIPO+set}" = set; then +if test "${ac_cv_prog_ac_ct_DSYMUTIL+set}" = set; then $as_echo_n "(cached) " >&6 else - if test -n "$ac_ct_LIPO"; then - ac_cv_prog_ac_ct_LIPO="$ac_ct_LIPO" # Let the user override the test. + if test -n "$ac_ct_DSYMUTIL"; then + ac_cv_prog_ac_ct_DSYMUTIL="$ac_ct_DSYMUTIL" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH @@ -6961,7 +7697,7 @@ do 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_prog_ac_ct_LIPO="lipo" + ac_cv_prog_ac_ct_DSYMUTIL="dsymutil" $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi @@ -6971,17 +7707,17 @@ IFS=$as_save_IFS fi fi -ac_ct_LIPO=$ac_cv_prog_ac_ct_LIPO -if test -n "$ac_ct_LIPO"; then - { $as_echo "$as_me:$LINENO: result: $ac_ct_LIPO" >&5 -$as_echo "$ac_ct_LIPO" >&6; } +ac_ct_DSYMUTIL=$ac_cv_prog_ac_ct_DSYMUTIL +if test -n "$ac_ct_DSYMUTIL"; then + { $as_echo "$as_me:$LINENO: result: $ac_ct_DSYMUTIL" >&5 +$as_echo "$ac_ct_DSYMUTIL" >&6; } else { $as_echo "$as_me:$LINENO: result: no" >&5 $as_echo "no" >&6; } fi - if test "x$ac_ct_LIPO" = x; then - LIPO=":" + if test "x$ac_ct_DSYMUTIL" = x; then + DSYMUTIL=":" else case $cross_compiling:$ac_tool_warned in yes:) @@ -6989,22 +7725,22 @@ yes:) $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac - LIPO=$ac_ct_LIPO + DSYMUTIL=$ac_ct_DSYMUTIL fi else - LIPO="$ac_cv_prog_LIPO" + DSYMUTIL="$ac_cv_prog_DSYMUTIL" fi if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}otool", so it can be a program name with args. -set dummy ${ac_tool_prefix}otool; ac_word=$2 + # Extract the first word of "${ac_tool_prefix}nmedit", so it can be a program name with args. +set dummy ${ac_tool_prefix}nmedit; 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_prog_OTOOL+set}" = set; then +if test "${ac_cv_prog_NMEDIT+set}" = set; then $as_echo_n "(cached) " >&6 else - if test -n "$OTOOL"; then - ac_cv_prog_OTOOL="$OTOOL" # Let the user override the test. + if test -n "$NMEDIT"; then + ac_cv_prog_NMEDIT="$NMEDIT" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH @@ -7013,7 +7749,7 @@ do 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_prog_OTOOL="${ac_tool_prefix}otool" + ac_cv_prog_NMEDIT="${ac_tool_prefix}nmedit" $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi @@ -7023,10 +7759,10 @@ IFS=$as_save_IFS fi fi -OTOOL=$ac_cv_prog_OTOOL -if test -n "$OTOOL"; then - { $as_echo "$as_me:$LINENO: result: $OTOOL" >&5 -$as_echo "$OTOOL" >&6; } +NMEDIT=$ac_cv_prog_NMEDIT +if test -n "$NMEDIT"; then + { $as_echo "$as_me:$LINENO: result: $NMEDIT" >&5 +$as_echo "$NMEDIT" >&6; } else { $as_echo "$as_me:$LINENO: result: no" >&5 $as_echo "no" >&6; } @@ -7034,17 +7770,17 @@ fi fi -if test -z "$ac_cv_prog_OTOOL"; then - ac_ct_OTOOL=$OTOOL - # Extract the first word of "otool", so it can be a program name with args. -set dummy otool; ac_word=$2 +if test -z "$ac_cv_prog_NMEDIT"; then + ac_ct_NMEDIT=$NMEDIT + # Extract the first word of "nmedit", so it can be a program name with args. +set dummy nmedit; 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_prog_ac_ct_OTOOL+set}" = set; then +if test "${ac_cv_prog_ac_ct_NMEDIT+set}" = set; then $as_echo_n "(cached) " >&6 else - if test -n "$ac_ct_OTOOL"; then - ac_cv_prog_ac_ct_OTOOL="$ac_ct_OTOOL" # Let the user override the test. + if test -n "$ac_ct_NMEDIT"; then + ac_cv_prog_ac_ct_NMEDIT="$ac_ct_NMEDIT" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH @@ -7053,7 +7789,7 @@ do 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_prog_ac_ct_OTOOL="otool" + ac_cv_prog_ac_ct_NMEDIT="nmedit" $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi @@ -7063,17 +7799,17 @@ IFS=$as_save_IFS fi fi -ac_ct_OTOOL=$ac_cv_prog_ac_ct_OTOOL -if test -n "$ac_ct_OTOOL"; then - { $as_echo "$as_me:$LINENO: result: $ac_ct_OTOOL" >&5 -$as_echo "$ac_ct_OTOOL" >&6; } +ac_ct_NMEDIT=$ac_cv_prog_ac_ct_NMEDIT +if test -n "$ac_ct_NMEDIT"; then + { $as_echo "$as_me:$LINENO: result: $ac_ct_NMEDIT" >&5 +$as_echo "$ac_ct_NMEDIT" >&6; } else { $as_echo "$as_me:$LINENO: result: no" >&5 $as_echo "no" >&6; } fi - if test "x$ac_ct_OTOOL" = x; then - OTOOL=":" + if test "x$ac_ct_NMEDIT" = x; then + NMEDIT=":" else case $cross_compiling:$ac_tool_warned in yes:) @@ -7081,155 +7817,32 @@ yes:) $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac - OTOOL=$ac_ct_OTOOL + NMEDIT=$ac_ct_NMEDIT fi else - OTOOL="$ac_cv_prog_OTOOL" + NMEDIT="$ac_cv_prog_NMEDIT" fi - if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}otool64", so it can be a program name with args. -set dummy ${ac_tool_prefix}otool64; 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_prog_OTOOL64+set}" = set; then - $as_echo_n "(cached) " >&6 -else - if test -n "$OTOOL64"; then - ac_cv_prog_OTOOL64="$OTOOL64" # Let the user override the test. -else -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_prog_OTOOL64="${ac_tool_prefix}otool64" - $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done -done -IFS=$as_save_IFS - -fi -fi -OTOOL64=$ac_cv_prog_OTOOL64 -if test -n "$OTOOL64"; then - { $as_echo "$as_me:$LINENO: result: $OTOOL64" >&5 -$as_echo "$OTOOL64" >&6; } -else - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_OTOOL64"; then - ac_ct_OTOOL64=$OTOOL64 - # Extract the first word of "otool64", so it can be a program name with args. -set dummy otool64; 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_prog_ac_ct_OTOOL64+set}" = set; then - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_OTOOL64"; then - ac_cv_prog_ac_ct_OTOOL64="$ac_ct_OTOOL64" # Let the user override the test. -else -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_prog_ac_ct_OTOOL64="otool64" - $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done -done -IFS=$as_save_IFS - -fi -fi -ac_ct_OTOOL64=$ac_cv_prog_ac_ct_OTOOL64 -if test -n "$ac_ct_OTOOL64"; then - { $as_echo "$as_me:$LINENO: result: $ac_ct_OTOOL64" >&5 -$as_echo "$ac_ct_OTOOL64" >&6; } -else - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } -fi - - if test "x$ac_ct_OTOOL64" = x; then - OTOOL64=":" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - OTOOL64=$ac_ct_OTOOL64 - fi -else - OTOOL64="$ac_cv_prog_OTOOL64" -fi - - - - - - - - - - - - - - - - - - - - - - - - - - - - { $as_echo "$as_me:$LINENO: checking for -single_module linker flag" >&5 -$as_echo_n "checking for -single_module linker flag... " >&6; } -if test "${lt_cv_apple_cc_single_mod+set}" = set; then + + { $as_echo "$as_me:$LINENO: checking for -single_module linker flag" >&5 +$as_echo_n "checking for -single_module linker flag... " >&6; } +if test "${lt_cv_apple_cc_single_mod+set}" = set; then $as_echo_n "(cached) " >&6 else lt_cv_apple_cc_single_mod=no if test -z "${LT_MULTI_MODULE}"; then - # By default we will add the -single_module flag. You can override - # by either setting the environment variable LT_MULTI_MODULE - # non-empty at configure time, or by adding -multi_module to the - # link flags. - rm -rf libconftest.dylib* - echo "int foo(void){return 1;}" > conftest.c - echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ --dynamiclib -Wl,-single_module conftest.c" >&5 - $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ - -dynamiclib -Wl,-single_module conftest.c 2>conftest.err - _lt_result=$? - if test -f libconftest.dylib && test ! -s conftest.err && test $_lt_result = 0; then - lt_cv_apple_cc_single_mod=yes - else - cat conftest.err >&5 - fi - rm -rf libconftest.dylib* - rm -f conftest.* + # By default we will add the -single_module flag. You can override + # by either setting the environment variable LT_MULTI_MODULE + # non-empty at configure time, or by adding -multi_module to the + # link flags. + echo "int foo(void){return 1;}" > conftest.c + $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ + -dynamiclib ${wl}-single_module conftest.c + if test -f libconftest.dylib; then + lt_cv_apple_cc_single_mod=yes + rm -rf libconftest.dylib* + fi + rm conftest.c fi fi { $as_echo "$as_me:$LINENO: result: $lt_cv_apple_cc_single_mod" >&5 @@ -7290,27 +7903,27 @@ fi rm -rf conftest.dSYM rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext - LDFLAGS="$save_LDFLAGS" + LDFLAGS="$save_LDFLAGS" fi { $as_echo "$as_me:$LINENO: result: $lt_cv_ld_exported_symbols_list" >&5 $as_echo "$lt_cv_ld_exported_symbols_list" >&6; } case $host_os in - rhapsody* | darwin1.[012]) + rhapsody* | darwin1.[0123]) _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;; darwin1.*) - _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; - darwin*) # darwin 5.x on + _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; + darwin*) # if running on 10.5 or later, the deployment target defaults # to the OS version, if on x86, and 10.4, the deployment # target defaults to 10.4. Don't you love it? case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in - 10.0,*86*-darwin8*|10.0,*-darwin[91]*) - _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; - 10.[012]*) - _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; - 10.*) - _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; + 10.0,*86*-darwin8*|10.0,*-darwin[91]*) + _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; + 10.[012]*) + _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; + 10.*) + _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; esac ;; esac @@ -7320,10 +7933,10 @@ $as_echo "$lt_cv_ld_exported_symbols_list" >&6; } if test "$lt_cv_ld_exported_symbols_list" = "yes"; then _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym' else - _lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}' + _lt_dar_export_syms="~$NMEDIT -s \$output_objdir/\${libname}-symbols.expsym \${lib}" fi if test "$DSYMUTIL" != ":"; then - _lt_dsymutil='~$DSYMUTIL $lib || :' + _lt_dsymutil="~$DSYMUTIL \$lib || :" else _lt_dsymutil= fi @@ -7331,1576 +7944,2345 @@ $as_echo "$lt_cv_ld_exported_symbols_list" >&6; } esac -for ac_header in dlfcn.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; } -as_val=`eval 'as_val=${'$as_ac_Header'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 -_ACEOF +enable_dlopen=no +enable_win32_dll=no +# Check whether --enable-libtool-lock was given. +if test "${enable_libtool_lock+set}" = set; then + enableval=$enable_libtool_lock; fi -done - - - -# Set options - - - - enable_dlopen=no - - - enable_win32_dll=no +test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes - # 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 +# Check whether --with-pic was given. +if test "${with_pic+set}" = set; then + withval=$with_pic; pic_mode="$withval" else - enable_shared=yes + pic_mode=default fi +test -z "$pic_mode" && pic_mode=default +# Use C for the default configuration in the libtool script +tagname= +lt_save_CC="$CC" +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 +# Source file extension for C test sources. +ac_ext=c +# Object file extension for compiled C test sources. +objext=o +objext=$objext +# Code to be used in simple compile tests +lt_simple_compile_test_code="int some_variable = 0;" +# Code to be used in simple link tests +lt_simple_link_test_code='int main(){return(0);}' - # 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 - - - - - - +# If no C compiler was specified, use CC. +LTCC=${LTCC-"$CC"} +# If no C compiler flags were specified, use CFLAGS. +LTCFLAGS=${LTCFLAGS-"$CFLAGS"} +# Allow CC to be a program name with arguments. +compiler=$CC -# Check whether --with-pic was given. -if test "${with_pic+set}" = set; then - withval=$with_pic; pic_mode="$withval" -else - pic_mode=default -fi +# save warnings/boilerplate of simple test code +ac_outfile=conftest.$ac_objext +echo "$lt_simple_compile_test_code" >conftest.$ac_ext +eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err +_lt_compiler_boilerplate=`cat conftest.err` +$rm conftest* +ac_outfile=conftest.$ac_objext +echo "$lt_simple_link_test_code" >conftest.$ac_ext +eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err +_lt_linker_boilerplate=`cat conftest.err` +$rm -r conftest* -test -z "$pic_mode" && pic_mode=default +lt_prog_compiler_no_builtin_flag= +if test "$GCC" = yes; then + lt_prog_compiler_no_builtin_flag=' -fno-builtin' +{ $as_echo "$as_me:$LINENO: checking if $compiler supports -fno-rtti -fno-exceptions" >&5 +$as_echo_n "checking if $compiler supports -fno-rtti -fno-exceptions... " >&6; } +if test "${lt_cv_prog_compiler_rtti_exceptions+set}" = set; then + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_rtti_exceptions=no + ac_outfile=conftest.$ac_objext + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + lt_compiler_flag="-fno-rtti -fno-exceptions" + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + # The option is referenced via a variable to avoid confusing sed. + lt_compile=`echo "$ac_compile" | $SED \ + -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:8040: $lt_compile\"" >&5) + (eval "$lt_compile" 2>conftest.err) + ac_status=$? + cat conftest.err >&5 + echo "$as_me:8044: \$? = $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. + $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then + lt_cv_prog_compiler_rtti_exceptions=yes + fi + fi + $rm conftest* +fi +{ $as_echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_rtti_exceptions" >&5 +$as_echo "$lt_cv_prog_compiler_rtti_exceptions" >&6; } - # 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 +if test x"$lt_cv_prog_compiler_rtti_exceptions" = xyes; then + lt_prog_compiler_no_builtin_flag="$lt_prog_compiler_no_builtin_flag -fno-rtti -fno-exceptions" else - enable_fast_install=yes + : fi +fi +lt_prog_compiler_wl= +lt_prog_compiler_pic= +lt_prog_compiler_static= +{ $as_echo "$as_me:$LINENO: checking for $compiler option to produce PIC" >&5 +$as_echo_n "checking for $compiler option to produce PIC... " >&6; } + if test "$GCC" = yes; then + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_static='-static' + case $host_os in + aix*) + # All AIX code is PIC. + if test "$host_cpu" = ia64; then + # AIX 5 now supports IA64 processor + lt_prog_compiler_static='-Bstatic' + fi + ;; + amigaos*) + # FIXME: we need at least 68020 code to build shared libraries, but + # adding the `-m68020' flag to GCC prevents building anything better, + # like `-m68040'. + lt_prog_compiler_pic='-m68020 -resident32 -malways-restore-a4' + ;; + beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) + # PIC is the default for these OSes. + ;; + mingw* | cygwin* | pw32* | os2*) + # This hack is so that the source file can tell whether it is being + # built for inclusion in a dll (and should export symbols for example). + # Although the cygwin gcc ignores -fPIC, still need this for old-style + # (--disable-auto-import) libraries + lt_prog_compiler_pic='-DDLL_EXPORT' + ;; + darwin* | rhapsody*) + # PIC is the default on this platform + # Common symbols not allowed in MH_DYLIB files + lt_prog_compiler_pic='-fno-common' + ;; + interix[3-9]*) + # Interix 3.x gcc -fpic/-fPIC options generate broken code. + # Instead, we relocate shared libraries at runtime. + ;; -# This can be used to rebuild libtool when needed -LIBTOOL_DEPS="$ltmain" - -# Always use our own libtool. -LIBTOOL='$(SHELL) $(top_builddir)/libtool' - - - + msdosdjgpp*) + # Just because we use GCC doesn't mean we suddenly get shared libraries + # on systems that don't support them. + lt_prog_compiler_can_build_shared=no + enable_shared=no + ;; + sysv4*MP*) + if test -d /usr/nec; then + lt_prog_compiler_pic=-Kconform_pic + fi + ;; + hpux*) + # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but + # not for PA HP-UX. + case $host_cpu in + hppa*64*|ia64*) + # +Z the default + ;; + *) + lt_prog_compiler_pic='-fPIC' + ;; + esac + ;; + *) + lt_prog_compiler_pic='-fPIC' + ;; + esac + else + # PORTME Check for flag to pass linker flags through the system compiler. + case $host_os in + aix*) + lt_prog_compiler_wl='-Wl,' + if test "$host_cpu" = ia64; then + # AIX 5 now supports IA64 processor + lt_prog_compiler_static='-Bstatic' + else + lt_prog_compiler_static='-bnso -bI:/lib/syscalls.exp' + fi + ;; + darwin*) + # PIC is the default on this platform + # Common symbols not allowed in MH_DYLIB files + case $cc_basename in + xlc*) + lt_prog_compiler_pic='-qnocommon' + lt_prog_compiler_wl='-Wl,' + ;; + esac + ;; + mingw* | cygwin* | pw32* | os2*) + # This hack is so that the source file can tell whether it is being + # built for inclusion in a dll (and should export symbols for example). + lt_prog_compiler_pic='-DDLL_EXPORT' + ;; + hpux9* | hpux10* | hpux11*) + lt_prog_compiler_wl='-Wl,' + # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but + # not for PA HP-UX. + case $host_cpu in + hppa*64*|ia64*) + # +Z the default + ;; + *) + lt_prog_compiler_pic='+Z' + ;; + esac + # Is there a better lt_prog_compiler_static that works with the bundled CC? + lt_prog_compiler_static='${wl}-a ${wl}archive' + ;; + irix5* | irix6* | nonstopux*) + lt_prog_compiler_wl='-Wl,' + # PIC (with -KPIC) is the default. + lt_prog_compiler_static='-non_shared' + ;; + newsos6) + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-Bstatic' + ;; + linux* | k*bsd*-gnu) + case $cc_basename in + icc* | ecc*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-static' + ;; + pgcc* | pgf77* | pgf90* | pgf95*) + # Portland Group compilers (*not* the Pentium gcc compiler, + # which looks to be a dead project) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-fpic' + lt_prog_compiler_static='-Bstatic' + ;; + ccc*) + lt_prog_compiler_wl='-Wl,' + # All Alpha code is PIC. + lt_prog_compiler_static='-non_shared' + ;; + *) + case `$CC -V 2>&1 | sed 5q` in + *Sun\ C*) + # Sun C 5.9 + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-Bstatic' + lt_prog_compiler_wl='-Wl,' + ;; + *Sun\ F*) + # Sun Fortran 8.3 passes all unrecognized flags to the linker + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-Bstatic' + lt_prog_compiler_wl='' + ;; + esac + ;; + esac + ;; + osf3* | osf4* | osf5*) + lt_prog_compiler_wl='-Wl,' + # All OSF/1 code is PIC. + lt_prog_compiler_static='-non_shared' + ;; + rdos*) + lt_prog_compiler_static='-non_shared' + ;; + solaris*) + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-Bstatic' + case $cc_basename in + f77* | f90* | f95*) + lt_prog_compiler_wl='-Qoption ld ';; + *) + lt_prog_compiler_wl='-Wl,';; + esac + ;; + sunos4*) + lt_prog_compiler_wl='-Qoption ld ' + lt_prog_compiler_pic='-PIC' + lt_prog_compiler_static='-Bstatic' + ;; + sysv4 | sysv4.2uw2* | sysv4.3*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-Bstatic' + ;; + sysv4*MP*) + if test -d /usr/nec ;then + lt_prog_compiler_pic='-Kconform_pic' + lt_prog_compiler_static='-Bstatic' + fi + ;; + sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-Bstatic' + ;; + unicos*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_can_build_shared=no + ;; + uts4*) + lt_prog_compiler_pic='-pic' + lt_prog_compiler_static='-Bstatic' + ;; + *) + lt_prog_compiler_can_build_shared=no + ;; + esac + fi +{ $as_echo "$as_me:$LINENO: result: $lt_prog_compiler_pic" >&5 +$as_echo "$lt_prog_compiler_pic" >&6; } +# +# Check to make sure the PIC flag actually works. +# +if test -n "$lt_prog_compiler_pic"; then +{ $as_echo "$as_me:$LINENO: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5 +$as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic works... " >&6; } +if test "${lt_cv_prog_compiler_pic_works+set}" = set; then + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_pic_works=no + ac_outfile=conftest.$ac_objext + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + lt_compiler_flag="$lt_prog_compiler_pic -DPIC" + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + # The option is referenced via a variable to avoid confusing sed. + lt_compile=`echo "$ac_compile" | $SED \ + -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:8330: $lt_compile\"" >&5) + (eval "$lt_compile" 2>conftest.err) + ac_status=$? + cat conftest.err >&5 + echo "$as_me:8334: \$? = $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. + $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then + lt_cv_prog_compiler_pic_works=yes + fi + fi + $rm conftest* -test -z "$LN_S" && LN_S="ln -s" - - - - - +fi +{ $as_echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_pic_works" >&5 +$as_echo "$lt_cv_prog_compiler_pic_works" >&6; } +if test x"$lt_cv_prog_compiler_pic_works" = xyes; then + case $lt_prog_compiler_pic in + "" | " "*) ;; + *) lt_prog_compiler_pic=" $lt_prog_compiler_pic" ;; + esac +else + lt_prog_compiler_pic= + lt_prog_compiler_can_build_shared=no +fi +fi +case $host_os in + # For platforms which do not support PIC, -DPIC is meaningless: + *djgpp*) + lt_prog_compiler_pic= + ;; + *) + lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC" + ;; +esac +# +# Check to make sure the static flag actually works. +# +wl=$lt_prog_compiler_wl eval lt_tmp_static_flag=\"$lt_prog_compiler_static\" +{ $as_echo "$as_me:$LINENO: checking if $compiler static flag $lt_tmp_static_flag works" >&5 +$as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; } +if test "${lt_cv_prog_compiler_static_works+set}" = set; then + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_static_works=no + save_LDFLAGS="$LDFLAGS" + LDFLAGS="$LDFLAGS $lt_tmp_static_flag" + echo "$lt_simple_link_test_code" > conftest.$ac_ext + if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then + # The linker can only warn and ignore the option if not recognized + # So say no if there are warnings + if test -s conftest.err; then + # Append any errors to the config.log. + cat conftest.err 1>&5 + $echo "X$_lt_linker_boilerplate" | $Xsed -e '/^$/d' > conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if diff conftest.exp conftest.er2 >/dev/null; then + lt_cv_prog_compiler_static_works=yes + fi + else + lt_cv_prog_compiler_static_works=yes + fi + fi + $rm -r conftest* + LDFLAGS="$save_LDFLAGS" +fi +{ $as_echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_static_works" >&5 +$as_echo "$lt_cv_prog_compiler_static_works" >&6; } +if test x"$lt_cv_prog_compiler_static_works" = xyes; then + : +else + lt_prog_compiler_static= +fi +{ $as_echo "$as_me:$LINENO: checking if $compiler supports -c -o file.$ac_objext" >&5 +$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } +if test "${lt_cv_prog_compiler_c_o+set}" = set; then + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_c_o=no + $rm -r conftest 2>/dev/null + mkdir conftest + cd conftest + mkdir out + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + lt_compiler_flag="-o out/conftest2.$ac_objext" + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + lt_compile=`echo "$ac_compile" | $SED \ + -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:8434: $lt_compile\"" >&5) + (eval "$lt_compile" 2>out/conftest.err) + ac_status=$? + cat out/conftest.err >&5 + echo "$as_me:8438: \$? = $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 + # So say no if there are warnings + $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp + $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 + if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then + lt_cv_prog_compiler_c_o=yes + fi + fi + chmod u+w . 2>&5 + $rm conftest* + # SGI C++ compiler will create directory out/ii_files/ for + # template instantiation + test -d out/ii_files && $rm out/ii_files/* && rmdir out/ii_files + $rm out/* && rmdir out + cd .. + rmdir conftest + $rm conftest* -if test -n "${ZSH_VERSION+set}" ; then - setopt NO_GLOB_SUBST fi +{ $as_echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_c_o" >&5 +$as_echo "$lt_cv_prog_compiler_c_o" >&6; } -{ $as_echo "$as_me:$LINENO: checking for objdir" >&5 -$as_echo_n "checking for objdir... " >&6; } -if test "${lt_cv_objdir+set}" = set; then - $as_echo_n "(cached) " >&6 -else - rm -f .libs 2>/dev/null -mkdir .libs 2>/dev/null -if test -d .libs; then - lt_cv_objdir=.libs + +hard_links="nottested" +if test "$lt_cv_prog_compiler_c_o" = no && test "$need_locks" != no; then + # do not overwrite the value of need_locks provided by the user + { $as_echo "$as_me:$LINENO: checking if we can lock with hard links" >&5 +$as_echo_n "checking if we can lock with hard links... " >&6; } + hard_links=yes + $rm conftest* + ln conftest.a conftest.b 2>/dev/null && hard_links=no + touch conftest.a + ln conftest.a conftest.b 2>&5 || hard_links=no + ln conftest.a conftest.b 2>/dev/null && hard_links=no + { $as_echo "$as_me:$LINENO: result: $hard_links" >&5 +$as_echo "$hard_links" >&6; } + if test "$hard_links" = no; then + { $as_echo "$as_me:$LINENO: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5 +$as_echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;} + need_locks=warn + fi else - # MS-DOS does not allow filenames that begin with a dot. - lt_cv_objdir=_libs -fi -rmdir .libs 2>/dev/null + need_locks=no fi -{ $as_echo "$as_me:$LINENO: result: $lt_cv_objdir" >&5 -$as_echo "$lt_cv_objdir" >&6; } -objdir=$lt_cv_objdir +{ $as_echo "$as_me:$LINENO: checking whether the $compiler linker ($LD) supports shared libraries" >&5 +$as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; } + runpath_var= + allow_undefined_flag= + enable_shared_with_static_runtimes=no + archive_cmds= + archive_expsym_cmds= + old_archive_From_new_cmds= + old_archive_from_expsyms_cmds= + export_dynamic_flag_spec= + whole_archive_flag_spec= + thread_safe_flag_spec= + hardcode_libdir_flag_spec= + hardcode_libdir_flag_spec_ld= + hardcode_libdir_separator= + hardcode_direct=no + hardcode_minus_L=no + hardcode_shlibpath_var=unsupported + link_all_deplibs=unknown + hardcode_automatic=no + module_cmds= + module_expsym_cmds= + always_export_symbols=no + export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' + # include_expsyms should be a list of space-separated symbols to be *always* + # included in the symbol list + include_expsyms= + # exclude_expsyms can be an extended regexp of symbols to exclude + # it will be wrapped by ` (' and `)$', so one must not match beginning or + # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc', + # as well as any symbol that contains `d'. + exclude_expsyms='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*' + # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out + # platforms (ab)use it in PIC code, but their linkers get confused if + # the symbol is explicitly referenced. Since portable code cannot + # rely on this symbol name, it's probably fine to never include it in + # preloaded symbol tables. + # Exclude shared library initialization/finalization symbols. + extract_expsyms_cmds= + # Just being paranoid about ensuring that cc_basename is set. + for cc_temp in $compiler""; do + case $cc_temp in + compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; + distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; + \-*) ;; + *) break;; + esac +done +cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` + case $host_os in + cygwin* | mingw* | pw32*) + # FIXME: the MSVC++ port hasn't been tested in a loooong time + # When not using gcc, we currently assume that we are using + # Microsoft Visual C++. + if test "$GCC" != yes; then + with_gnu_ld=no + fi + ;; + interix*) + # we just hope/assume this is gcc and not c89 (= MSVC++) + with_gnu_ld=yes + ;; + openbsd*) + with_gnu_ld=no + ;; + esac + ld_shlibs=yes + if test "$with_gnu_ld" = yes; then + # If archive_cmds runs LD, not CC, wlarc should be empty + wlarc='${wl}' -cat >>confdefs.h <<_ACEOF -#define LT_OBJDIR "$lt_cv_objdir/" -_ACEOF - - + # Set some defaults for GNU ld with shared library support. These + # are reset later if shared libraries are not supported. Putting them + # here allows them to be overridden if necessary. + runpath_var=LD_RUN_PATH + hardcode_libdir_flag_spec='${wl}--rpath ${wl}$libdir' + export_dynamic_flag_spec='${wl}--export-dynamic' + # ancient GNU ld didn't support --whole-archive et. al. + if $LD --help 2>&1 | grep 'no-whole-archive' > /dev/null; then + whole_archive_flag_spec="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' + else + whole_archive_flag_spec= + fi + supports_anon_versioning=no + case `$LD -v 2>/dev/null` in + *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11 + *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... + *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... + *\ 2.11.*) ;; # other 2.11 versions + *) supports_anon_versioning=yes ;; + esac + # See if GNU ld supports shared libraries. + case $host_os in + aix[3-9]*) + # On AIX/PPC, the GNU linker is very broken + if test "$host_cpu" != ia64; then + ld_shlibs=no + cat <&2 +*** Warning: the GNU linker, at least up to release 2.9.1, is reported +*** to be unable to reliably create shared libraries on AIX. +*** Therefore, libtool is disabling shared libraries support. If you +*** really care for shared libraries, you may want to modify your PATH +*** so that a non-GNU linker is found, and then restart. +EOF + fi + ;; + amigaos*) + archive_cmds='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' + hardcode_libdir_flag_spec='-L$libdir' + hardcode_minus_L=yes + # Samuel A. Falvo II reports + # that the semantics of dynamic libraries on AmigaOS, at least up + # to version 4, is to share data among multiple programs linked + # with the same dynamic library. Since this doesn't match the + # behavior of shared libraries on other platforms, we can't use + # them. + ld_shlibs=no + ;; + beos*) + if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then + allow_undefined_flag=unsupported + # Joseph Beckenbach says some releases of gcc + # support --undefined. This deserves some investigation. FIXME + archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + else + ld_shlibs=no + fi + ;; + cygwin* | mingw* | pw32*) + # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, ) is actually meaningless, + # as there is no search path for DLLs. + hardcode_libdir_flag_spec='-L$libdir' + allow_undefined_flag=unsupported + always_export_symbols=no + enable_shared_with_static_runtimes=yes + export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/'\'' -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols' + if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then + archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + # If the export-symbols file already is a .def file (1st line + # is EXPORTS), use it as is; otherwise, prepend... + archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then + cp $export_symbols $output_objdir/$soname.def; + else + echo EXPORTS > $output_objdir/$soname.def; + cat $export_symbols >> $output_objdir/$soname.def; + fi~ + $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + else + ld_shlibs=no + fi + ;; + interix[3-9]*) + hardcode_direct=no + hardcode_shlibpath_var=no + hardcode_libdir_flag_spec='${wl}-rpath,$libdir' + export_dynamic_flag_spec='${wl}-E' + # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. + # Instead, shared libraries are loaded at an image base (0x10000000 by + # default) and relocated if they conflict, which is a slow very memory + # consuming and fragmenting process. To avoid this, we pick a random, + # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link + # time. Moving up from 0x10000000 also allows more sbrk(2) space. + archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + archive_expsym_cmds='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + ;; + gnu* | linux* | k*bsd*-gnu) + if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then + tmp_addflag= + case $cc_basename,$host_cpu in + pgcc*) # Portland Group C compiler + whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' + tmp_addflag=' $pic_flag' + ;; + pgf77* | pgf90* | pgf95*) # Portland Group f77 and f90 compilers + whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' + tmp_addflag=' $pic_flag -Mnomain' ;; + ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 + tmp_addflag=' -i_dynamic' ;; + efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 + tmp_addflag=' -i_dynamic -nofor_main' ;; + ifc* | ifort*) # Intel Fortran compiler + tmp_addflag=' -nofor_main' ;; + esac + case `$CC -V 2>&1 | sed 5q` in + *Sun\ C*) # Sun C 5.9 + whole_archive_flag_spec='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' + tmp_sharedflag='-G' ;; + *Sun\ F*) # Sun Fortran 8.3 + tmp_sharedflag='-G' ;; + *) + tmp_sharedflag='-shared' ;; + esac + archive_cmds='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + if test $supports_anon_versioning = yes; then + archive_expsym_cmds='$echo "{ global:" > $output_objdir/$libname.ver~ + cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ + $echo "local: *; };" >> $output_objdir/$libname.ver~ + $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' + fi + else + ld_shlibs=no + fi + ;; + netbsd*) + if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then + archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' + wlarc= + else + archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + fi + ;; + solaris*) + if $LD -v 2>&1 | grep 'BFD 2\.8' > /dev/null; then + ld_shlibs=no + cat <&2 +*** Warning: The releases 2.8.* of the GNU linker cannot reliably +*** create shared libraries on Solaris systems. Therefore, libtool +*** is disabling shared libraries support. We urge you to upgrade GNU +*** binutils to release 2.9.1 or newer. Another option is to modify +*** your PATH or compiler configuration so that the native linker is +*** used, and then restart. -case $host_os in -aix3*) - # AIX sometimes has problems with the GCC collect2 program. For some - # reason, if we set the COLLECT_NAMES environment variable, the problems - # vanish in a puff of smoke. - if test "X${COLLECT_NAMES+set}" != Xset; then - COLLECT_NAMES= - export COLLECT_NAMES - fi - ;; -esac +EOF + elif $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then + archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + else + ld_shlibs=no + fi + ;; -# Sed substitution that helps us do robust quoting. It backslashifies -# metacharacters that are still active within double-quoted strings. -sed_quote_subst='s/\(["`$\\]\)/\\\1/g' + sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*) + case `$LD -v 2>&1` in + *\ [01].* | *\ 2.[0-9].* | *\ 2.1[0-5].*) + ld_shlibs=no + cat <<_LT_EOF 1>&2 -# Same as above, but do not quote variable references. -double_quote_subst='s/\(["`\\]\)/\\\1/g' +*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not +*** reliably create shared libraries on SCO systems. Therefore, libtool +*** is disabling shared libraries support. We urge you to upgrade GNU +*** binutils to release 2.16.91.0.3 or newer. Another option is to modify +*** your PATH or compiler configuration so that the native linker is +*** used, and then restart. -# Sed substitution to delay expansion of an escaped shell variable in a -# double_quote_subst'ed string. -delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g' +_LT_EOF + ;; + *) + if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then + hardcode_libdir_flag_spec='`test -z "$SCOABSPATH" && echo ${wl}-rpath,$libdir`' + archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib' + archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname,\${SCOABSPATH:+${install_libdir}/}$soname,-retain-symbols-file,$export_symbols -o $lib' + else + ld_shlibs=no + fi + ;; + esac + ;; -# Sed substitution to delay expansion of an escaped single quote. -delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g' + sunos4*) + archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' + wlarc= + hardcode_direct=yes + hardcode_shlibpath_var=no + ;; -# Sed substitution to avoid accidental globbing in evaled expressions -no_glob_subst='s/\*/\\\*/g' + *) + if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then + archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + else + ld_shlibs=no + fi + ;; + esac -# Global variables: -ofile=libtool -can_build_shared=yes + if test "$ld_shlibs" = no; then + runpath_var= + hardcode_libdir_flag_spec= + export_dynamic_flag_spec= + whole_archive_flag_spec= + fi + else + # PORTME fill in a description of your system's linker (not GNU ld) + case $host_os in + aix3*) + allow_undefined_flag=unsupported + always_export_symbols=yes + archive_expsym_cmds='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname' + # Note: this linker hardcodes the directories in LIBPATH if there + # are no directories specified by -L. + hardcode_minus_L=yes + if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then + # Neither direct hardcoding nor static linking is supported with a + # broken collect2. + hardcode_direct=unsupported + fi + ;; -# All known linkers require a `.a' archive for static linking (except MSVC, -# which needs '.lib'). -libext=a + aix[4-9]*) + if test "$host_cpu" = ia64; then + # On IA64, the linker does run time linking by default, so we don't + # have to do anything special. + aix_use_runtimelinking=no + exp_sym_flag='-Bexport' + no_entry_flag="" + else + # If we're using GNU nm, then we don't want the "-C" option. + # -C means demangle to AIX nm, but means don't demangle with GNU nm + if $NM -V 2>&1 | grep 'GNU' > /dev/null; then + export_symbols_cmds='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$2 == "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print \$3 } }'\'' | sort -u > $export_symbols' + else + export_symbols_cmds='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$2 == "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print \$3 } }'\'' | sort -u > $export_symbols' + fi + aix_use_runtimelinking=no -with_gnu_ld="$lt_cv_prog_gnu_ld" + # Test if we are trying to use run time linking or normal + # AIX style linking. If -brtl is somewhere in LDFLAGS, we + # need to do runtime linking. + case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*) + for ld_flag in $LDFLAGS; do + if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then + aix_use_runtimelinking=yes + break + fi + done + ;; + esac -old_CC="$CC" -old_CFLAGS="$CFLAGS" + exp_sym_flag='-bexport' + no_entry_flag='-bnoentry' + fi -# Set sane defaults for various variables -test -z "$CC" && CC=cc -test -z "$LTCC" && LTCC=$CC -test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS -test -z "$LD" && LD=ld -test -z "$ac_objext" && ac_objext=o + # When large executables or shared objects are built, AIX ld can + # have problems creating the table of contents. If linking a library + # or program results in "error TOC overflow" add -mminimal-toc to + # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not + # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. -for cc_temp in $compiler""; do - case $cc_temp in - compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; - distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; - \-*) ;; - *) break;; - esac -done -cc_basename=`$ECHO "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` + archive_cmds='' + hardcode_direct=yes + hardcode_libdir_separator=':' + link_all_deplibs=yes + if test "$GCC" = yes; then + case $host_os in aix4.[012]|aix4.[012].*) + # We only want to do this on AIX 4.2 and lower, the check + # below for broken collect2 doesn't work under 4.3+ + collect2name=`${CC} -print-prog-name=collect2` + if test -f "$collect2name" && \ + strings "$collect2name" | grep resolve_lib_name >/dev/null + then + # We have reworked collect2 + : + else + # We have old collect2 + hardcode_direct=unsupported + # It fails to find uninstalled libraries when the uninstalled + # path is not listed in the libpath. Setting hardcode_minus_L + # to unsupported forces relinking + hardcode_minus_L=yes + hardcode_libdir_flag_spec='-L$libdir' + hardcode_libdir_separator= + fi + ;; + esac + shared_flag='-shared' + if test "$aix_use_runtimelinking" = yes; then + shared_flag="$shared_flag "'${wl}-G' + fi + else + # not using gcc + if test "$host_cpu" = ia64; then + # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release + # chokes on -Wl,-G. The following line is correct: + shared_flag='-G' + else + if test "$aix_use_runtimelinking" = yes; then + shared_flag='${wl}-G' + else + shared_flag='${wl}-bM:SRE' + fi + fi + fi -# Only perform the check for file, if the check method requires it -test -z "$MAGIC_CMD" && MAGIC_CMD=file -case $deplibs_check_method in -file_magic*) - if test "$file_magic_cmd" = '$MAGIC_CMD'; then - { $as_echo "$as_me:$LINENO: checking for ${ac_tool_prefix}file" >&5 -$as_echo_n "checking for ${ac_tool_prefix}file... " >&6; } -if test "${lt_cv_path_MAGIC_CMD+set}" = set; then - $as_echo_n "(cached) " >&6 -else - case $MAGIC_CMD in -[\\/*] | ?:[\\/]*) - lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. - ;; -*) - lt_save_MAGIC_CMD="$MAGIC_CMD" - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR - ac_dummy="/usr/bin$PATH_SEPARATOR$PATH" - for ac_dir in $ac_dummy; do - IFS="$lt_save_ifs" - test -z "$ac_dir" && ac_dir=. - if test -f $ac_dir/${ac_tool_prefix}file; then - lt_cv_path_MAGIC_CMD="$ac_dir/${ac_tool_prefix}file" - if test -n "$file_magic_test_file"; then - case $deplibs_check_method in - "file_magic "*) - file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` - MAGIC_CMD="$lt_cv_path_MAGIC_CMD" - if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | - $EGREP "$file_magic_regex" > /dev/null; then - : - else - cat <<_LT_EOF 1>&2 + # It seems that -bexpall does not export symbols beginning with + # underscore (_), so it is better to generate a list of symbols to export. + always_export_symbols=yes + if test "$aix_use_runtimelinking" = yes; then + # Warning - without using the other runtime loading flags (-brtl), + # -berok will link without error, but may produce a broken library. + allow_undefined_flag='-berok' + # Determine the default libpath from the value encoded in an empty executable. + cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ -*** Warning: the command libtool uses to detect shared libraries, -*** $file_magic_cmd, produces output that libtool cannot recognize. -*** The result is that libtool may fail to recognize shared libraries -*** as such. This will affect the creation of libtool libraries that -*** depend on shared libraries, but programs linked with such libtool -*** libraries will work regardless of this problem. Nevertheless, you -*** may want to report the problem to your system manager and/or to -*** bug-libtool@gnu.org +int +main () +{ -_LT_EOF - fi ;; - esac - fi - break - fi - done - IFS="$lt_save_ifs" - MAGIC_CMD="$lt_save_MAGIC_CMD" - ;; + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext conftest$ac_exeext +if { (ac_try="$ac_link" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; esac -fi +eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" +$as_echo "$ac_try_echo") >&5 + (eval "$ac_link") 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_exeext && { + test "$cross_compiling" = yes || + $as_test_x conftest$ac_exeext + }; then -MAGIC_CMD="$lt_cv_path_MAGIC_CMD" -if test -n "$MAGIC_CMD"; then - { $as_echo "$as_me:$LINENO: result: $MAGIC_CMD" >&5 -$as_echo "$MAGIC_CMD" >&6; } -else - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } +lt_aix_libpath_sed=' + /Import File Strings/,/^$/ { + /^0/ { + s/^0 *\(.*\)$/\1/ + p + } + }' +aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` +# Check for a 64-bit object if we didn't find anything. +if test -z "$aix_libpath"; then + aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` fi +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 +fi +rm -rf conftest.dSYM +rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ + conftest$ac_exeext conftest.$ac_ext +if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi + hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath" + archive_expsym_cmds="\$CC"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag" + else + if test "$host_cpu" = ia64; then + hardcode_libdir_flag_spec='${wl}-R $libdir:/usr/lib:/lib' + allow_undefined_flag="-z nodefs" + archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols" + else + # Determine the default libpath from the value encoded in an empty executable. + cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ -if test -z "$lt_cv_path_MAGIC_CMD"; then - if test -n "$ac_tool_prefix"; then - { $as_echo "$as_me:$LINENO: checking for file" >&5 -$as_echo_n "checking for file... " >&6; } -if test "${lt_cv_path_MAGIC_CMD+set}" = set; then - $as_echo_n "(cached) " >&6 -else - case $MAGIC_CMD in -[\\/*] | ?:[\\/]*) - lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. - ;; -*) - lt_save_MAGIC_CMD="$MAGIC_CMD" - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR - ac_dummy="/usr/bin$PATH_SEPARATOR$PATH" - for ac_dir in $ac_dummy; do - IFS="$lt_save_ifs" - test -z "$ac_dir" && ac_dir=. - if test -f $ac_dir/file; then - lt_cv_path_MAGIC_CMD="$ac_dir/file" - if test -n "$file_magic_test_file"; then - case $deplibs_check_method in - "file_magic "*) - file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` - MAGIC_CMD="$lt_cv_path_MAGIC_CMD" - if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | - $EGREP "$file_magic_regex" > /dev/null; then - : - else - cat <<_LT_EOF 1>&2 - -*** Warning: the command libtool uses to detect shared libraries, -*** $file_magic_cmd, produces output that libtool cannot recognize. -*** The result is that libtool may fail to recognize shared libraries -*** as such. This will affect the creation of libtool libraries that -*** depend on shared libraries, but programs linked with such libtool -*** libraries will work regardless of this problem. Nevertheless, you -*** may want to report the problem to your system manager and/or to -*** bug-libtool@gnu.org +int +main () +{ -_LT_EOF - fi ;; - esac - fi - break - fi - done - IFS="$lt_save_ifs" - MAGIC_CMD="$lt_save_MAGIC_CMD" - ;; + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext conftest$ac_exeext +if { (ac_try="$ac_link" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; esac -fi +eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" +$as_echo "$ac_try_echo") >&5 + (eval "$ac_link") 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_exeext && { + test "$cross_compiling" = yes || + $as_test_x conftest$ac_exeext + }; then -MAGIC_CMD="$lt_cv_path_MAGIC_CMD" -if test -n "$MAGIC_CMD"; then - { $as_echo "$as_me:$LINENO: result: $MAGIC_CMD" >&5 -$as_echo "$MAGIC_CMD" >&6; } -else - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } +lt_aix_libpath_sed=' + /Import File Strings/,/^$/ { + /^0/ { + s/^0 *\(.*\)$/\1/ + p + } + }' +aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` +# Check for a 64-bit object if we didn't find anything. +if test -z "$aix_libpath"; then + aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` fi +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 - else - MAGIC_CMD=: - fi fi - fi - ;; -esac - -# Use C for the default configuration in the libtool script +rm -rf conftest.dSYM +rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ + conftest$ac_exeext conftest.$ac_ext +if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi -lt_save_CC="$CC" -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 + hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath" + # Warning - without using the other run time loading flags, + # -berok will link without error, but may produce a broken library. + no_undefined_flag=' ${wl}-bernotok' + allow_undefined_flag=' ${wl}-berok' + # Exported symbols can be pulled into shared objects from archives + whole_archive_flag_spec='$convenience' + archive_cmds_need_lc=yes + # This is similar to how AIX traditionally builds its shared libraries. + archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' + fi + fi + ;; + amigaos*) + archive_cmds='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' + hardcode_libdir_flag_spec='-L$libdir' + hardcode_minus_L=yes + # see comment about different semantics on the GNU ld section + ld_shlibs=no + ;; -# Source file extension for C test sources. -ac_ext=c - -# Object file extension for compiled C test sources. -objext=o -objext=$objext - -# Code to be used in simple compile tests -lt_simple_compile_test_code="int some_variable = 0;" - -# Code to be used in simple link tests -lt_simple_link_test_code='int main(){return(0);}' - - - - - - - -# If no C compiler was specified, use CC. -LTCC=${LTCC-"$CC"} - -# If no C compiler flags were specified, use CFLAGS. -LTCFLAGS=${LTCFLAGS-"$CFLAGS"} - -# Allow CC to be a program name with arguments. -compiler=$CC - -# Save the default compiler, since it gets overwritten when the other -# tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP. -compiler_DEFAULT=$CC - -# save warnings/boilerplate of simple test code -ac_outfile=conftest.$ac_objext -echo "$lt_simple_compile_test_code" >conftest.$ac_ext -eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err -_lt_compiler_boilerplate=`cat conftest.err` -$RM conftest* - -ac_outfile=conftest.$ac_objext -echo "$lt_simple_link_test_code" >conftest.$ac_ext -eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err -_lt_linker_boilerplate=`cat conftest.err` -$RM -r conftest* - - -if test -n "$compiler"; then - -lt_prog_compiler_no_builtin_flag= - -if test "$GCC" = yes; then - lt_prog_compiler_no_builtin_flag=' -fno-builtin' - - { $as_echo "$as_me:$LINENO: checking if $compiler supports -fno-rtti -fno-exceptions" >&5 -$as_echo_n "checking if $compiler supports -fno-rtti -fno-exceptions... " >&6; } -if test "${lt_cv_prog_compiler_rtti_exceptions+set}" = set; then - $as_echo_n "(cached) " >&6 -else - lt_cv_prog_compiler_rtti_exceptions=no - ac_outfile=conftest.$ac_objext - echo "$lt_simple_compile_test_code" > conftest.$ac_ext - lt_compiler_flag="-fno-rtti -fno-exceptions" - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - # The option is referenced via a variable to avoid confusing sed. - lt_compile=`echo "$ac_compile" | $SED \ - -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:7893: $lt_compile\"" >&5) - (eval "$lt_compile" 2>conftest.err) - ac_status=$? - cat conftest.err >&5 - echo "$as_me:7897: \$? = $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. - $ECHO "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp - $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 - if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then - lt_cv_prog_compiler_rtti_exceptions=yes - fi - fi - $RM conftest* - -fi -{ $as_echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_rtti_exceptions" >&5 -$as_echo "$lt_cv_prog_compiler_rtti_exceptions" >&6; } - -if test x"$lt_cv_prog_compiler_rtti_exceptions" = xyes; then - lt_prog_compiler_no_builtin_flag="$lt_prog_compiler_no_builtin_flag -fno-rtti -fno-exceptions" -else - : -fi - -fi - - - - - - - lt_prog_compiler_wl= -lt_prog_compiler_pic= -lt_prog_compiler_static= - -{ $as_echo "$as_me:$LINENO: checking for $compiler option to produce PIC" >&5 -$as_echo_n "checking for $compiler option to produce PIC... " >&6; } - - if test "$GCC" = yes; then - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_static='-static' - - case $host_os in - aix*) - # All AIX code is PIC. - if test "$host_cpu" = ia64; then - # AIX 5 now supports IA64 processor - lt_prog_compiler_static='-Bstatic' - fi - ;; - - amigaos*) - case $host_cpu in - powerpc) - # see comment about AmigaOS4 .so support - lt_prog_compiler_pic='-fPIC' - ;; - m68k) - # FIXME: we need at least 68020 code to build shared libraries, but - # adding the `-m68020' flag to GCC prevents building anything better, - # like `-m68040'. - lt_prog_compiler_pic='-m68020 -resident32 -malways-restore-a4' - ;; - esac + bsdi[45]*) + export_dynamic_flag_spec=-rdynamic ;; - beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) - # PIC is the default for these OSes. + cygwin* | mingw* | pw32*) + # When not using gcc, we currently assume that we are using + # Microsoft Visual C++. + # hardcode_libdir_flag_spec is actually meaningless, as there is + # no search path for DLLs. + hardcode_libdir_flag_spec=' ' + allow_undefined_flag=unsupported + # Tell ltmain to make .lib files, not .a files. + libext=lib + # Tell ltmain to make .dll files, not .so files. + shrext_cmds=".dll" + # FIXME: Setting linknames here is a bad hack. + archive_cmds='$CC -o $lib $libobjs $compiler_flags `echo "$deplibs" | $SED -e '\''s/ -lc$//'\''` -link -dll~linknames=' + # The linker will automatically build a .lib file if we build a DLL. + old_archive_From_new_cmds='true' + # FIXME: Should let the user specify the lib program. + old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs' + fix_srcfile_path='`cygpath -w "$srcfile"`' + enable_shared_with_static_runtimes=yes ;; - mingw* | cygwin* | pw32* | os2* | cegcc*) - # This hack is so that the source file can tell whether it is being - # built for inclusion in a dll (and should export symbols for example). - # Although the cygwin gcc ignores -fPIC, still need this for old-style - # (--disable-auto-import) libraries - lt_prog_compiler_pic='-DDLL_EXPORT' + darwin* | rhapsody*) + case $host_os in + rhapsody* | darwin1.[012]) + allow_undefined_flag='${wl}-undefined ${wl}suppress' + ;; + *) # Darwin 1.3 on + if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then + allow_undefined_flag='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' + else + case ${MACOSX_DEPLOYMENT_TARGET} in + 10.[012]) + allow_undefined_flag='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' + ;; + 10.*) + allow_undefined_flag='${wl}-undefined ${wl}dynamic_lookup' + ;; + esac + fi + ;; + esac + archive_cmds_need_lc=no + hardcode_direct=no + hardcode_automatic=yes + hardcode_shlibpath_var=unsupported + whole_archive_flag_spec='' + link_all_deplibs=yes + if test "$GCC" = yes ; then + output_verbose_link_cmd='echo' + archive_cmds="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}" + module_cmds="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}" + archive_expsym_cmds="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}" + module_expsym_cmds="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}" + else + case $cc_basename in + xlc*) + output_verbose_link_cmd='echo' + archive_cmds='$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $xlcverstring' + module_cmds='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags' + # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds + archive_expsym_cmds='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $xlcverstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' + module_expsym_cmds='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' + ;; + *) + ld_shlibs=no + ;; + esac + fi ;; - darwin* | rhapsody*) - # PIC is the default on this platform - # Common symbols not allowed in MH_DYLIB files - lt_prog_compiler_pic='-fno-common' + dgux*) + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_libdir_flag_spec='-L$libdir' + hardcode_shlibpath_var=no ;; - hpux*) - # PIC is the default for 64-bit PA HP-UX, but not for 32-bit - # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag - # sets the default TLS model and affects inlining. - case $host_cpu in - hppa*64*) - # +Z the default - ;; - *) - lt_prog_compiler_pic='-fPIC' - ;; - esac + freebsd1*) + ld_shlibs=no ;; - interix[3-9]*) - # Interix 3.x gcc -fpic/-fPIC options generate broken code. - # Instead, we relocate shared libraries at runtime. + # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor + # support. Future versions do this automatically, but an explicit c++rt0.o + # does not break anything, and helps significantly (at the cost of a little + # extra space). + freebsd2.2*) + archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' + hardcode_libdir_flag_spec='-R$libdir' + hardcode_direct=yes + hardcode_shlibpath_var=no ;; - msdosdjgpp*) - # Just because we use GCC doesn't mean we suddenly get shared libraries - # on systems that don't support them. - lt_prog_compiler_can_build_shared=no - enable_shared=no + # Unfortunately, older versions of FreeBSD 2 do not have this feature. + freebsd2*) + archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' + hardcode_direct=yes + hardcode_minus_L=yes + hardcode_shlibpath_var=no ;; - *nto* | *qnx*) - # QNX uses GNU C++, but need to define -shared option too, otherwise - # it will coredump. - lt_prog_compiler_pic='-fPIC -shared' + # FreeBSD 3 and greater uses gcc -shared to do shared libraries. + freebsd* | dragonfly*) + archive_cmds='$CC -shared -o $lib $libobjs $deplibs $compiler_flags' + hardcode_libdir_flag_spec='-R$libdir' + hardcode_direct=yes + hardcode_shlibpath_var=no ;; - sysv4*MP*) - if test -d /usr/nec; then - lt_prog_compiler_pic=-Kconform_pic + hpux9*) + if test "$GCC" = yes; then + archive_cmds='$rm $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' + else + archive_cmds='$rm $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' fi - ;; + hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' + hardcode_libdir_separator=: + hardcode_direct=yes - *) - lt_prog_compiler_pic='-fPIC' + # hardcode_minus_L: Not really in the search PATH, + # but as the default location of the library. + hardcode_minus_L=yes + export_dynamic_flag_spec='${wl}-E' ;; - esac - else - # PORTME Check for flag to pass linker flags through the system compiler. - case $host_os in - aix*) - lt_prog_compiler_wl='-Wl,' - if test "$host_cpu" = ia64; then - # AIX 5 now supports IA64 processor - lt_prog_compiler_static='-Bstatic' + + hpux10*) + if test "$GCC" = yes -a "$with_gnu_ld" = no; then + archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' else - lt_prog_compiler_static='-bnso -bI:/lib/syscalls.exp' + archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' fi - ;; + if test "$with_gnu_ld" = no; then + hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' + hardcode_libdir_separator=: - mingw* | cygwin* | pw32* | os2* | cegcc*) - # This hack is so that the source file can tell whether it is being - # built for inclusion in a dll (and should export symbols for example). - lt_prog_compiler_pic='-DDLL_EXPORT' + hardcode_direct=yes + export_dynamic_flag_spec='${wl}-E' + + # hardcode_minus_L: Not really in the search PATH, + # but as the default location of the library. + hardcode_minus_L=yes + fi ;; - hpux9* | hpux10* | hpux11*) - lt_prog_compiler_wl='-Wl,' - # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but - # not for PA HP-UX. - case $host_cpu in - hppa*64*|ia64*) - # +Z the default - ;; - *) - lt_prog_compiler_pic='+Z' - ;; - esac - # Is there a better lt_prog_compiler_static that works with the bundled CC? - lt_prog_compiler_static='${wl}-a ${wl}archive' + hpux11*) + if test "$GCC" = yes -a "$with_gnu_ld" = no; then + case $host_cpu in + hppa*64*) + archive_cmds='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + ia64*) + archive_cmds='$CC -shared ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' + ;; + *) + archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' + ;; + esac + else + case $host_cpu in + hppa*64*) + archive_cmds='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + ia64*) + archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' + ;; + *) + archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' + ;; + esac + fi + if test "$with_gnu_ld" = no; then + hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' + hardcode_libdir_separator=: + + case $host_cpu in + hppa*64*|ia64*) + hardcode_libdir_flag_spec_ld='+b $libdir' + hardcode_direct=no + hardcode_shlibpath_var=no + ;; + *) + hardcode_direct=yes + export_dynamic_flag_spec='${wl}-E' + + # hardcode_minus_L: Not really in the search PATH, + # but as the default location of the library. + hardcode_minus_L=yes + ;; + esac + fi ;; irix5* | irix6* | nonstopux*) - lt_prog_compiler_wl='-Wl,' - # PIC (with -KPIC) is the default. - lt_prog_compiler_static='-non_shared' + if test "$GCC" = yes; then + archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + else + archive_cmds='$LD -shared $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' + hardcode_libdir_flag_spec_ld='-rpath $libdir' + fi + hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' + hardcode_libdir_separator=: + link_all_deplibs=yes ;; - linux* | k*bsd*-gnu) - case $cc_basename in - # old Intel for x86_64 which still supported -KPIC. - ecc*) - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_pic='-KPIC' - lt_prog_compiler_static='-static' - ;; - # icc used to be incompatible with GCC. - # ICC 10 doesn't accept -KPIC any more. - icc* | ifort*) - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_pic='-fPIC' - lt_prog_compiler_static='-static' - ;; - # Lahey Fortran 8.1. - lf95*) - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_pic='--shared' - lt_prog_compiler_static='--static' - ;; - pgcc* | pgf77* | pgf90* | pgf95*) - # Portland Group compilers (*not* the Pentium gcc compiler, - # which looks to be a dead project) - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_pic='-fpic' - lt_prog_compiler_static='-Bstatic' - ;; - ccc*) - lt_prog_compiler_wl='-Wl,' - # All Alpha code is PIC. - lt_prog_compiler_static='-non_shared' - ;; - xl*) - # IBM XL C 8.0/Fortran 10.1 on PPC - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_pic='-qpic' - lt_prog_compiler_static='-qstaticlink' - ;; - *) - case `$CC -V 2>&1 | sed 5q` in - *Sun\ C*) - # Sun C 5.9 - lt_prog_compiler_pic='-KPIC' - lt_prog_compiler_static='-Bstatic' - lt_prog_compiler_wl='-Wl,' - ;; - *Sun\ F*) - # Sun Fortran 8.3 passes all unrecognized flags to the linker - lt_prog_compiler_pic='-KPIC' - lt_prog_compiler_static='-Bstatic' - lt_prog_compiler_wl='' - ;; - esac - ;; - esac + netbsd*) + if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then + archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out + else + archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF + fi + hardcode_libdir_flag_spec='-R$libdir' + hardcode_direct=yes + hardcode_shlibpath_var=no ;; newsos6) - lt_prog_compiler_pic='-KPIC' - lt_prog_compiler_static='-Bstatic' + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_direct=yes + hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' + hardcode_libdir_separator=: + hardcode_shlibpath_var=no + ;; + + openbsd*) + if test -f /usr/libexec/ld.so; then + hardcode_direct=yes + hardcode_shlibpath_var=no + if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then + archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols' + hardcode_libdir_flag_spec='${wl}-rpath,$libdir' + export_dynamic_flag_spec='${wl}-E' + else + case $host_os in + openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*) + archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' + hardcode_libdir_flag_spec='-R$libdir' + ;; + *) + archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' + hardcode_libdir_flag_spec='${wl}-rpath,$libdir' + ;; + esac + fi + else + ld_shlibs=no + fi ;; - *nto* | *qnx*) - # QNX uses GNU C++, but need to define -shared option too, otherwise - # it will coredump. - lt_prog_compiler_pic='-fPIC -shared' + os2*) + hardcode_libdir_flag_spec='-L$libdir' + hardcode_minus_L=yes + allow_undefined_flag=unsupported + archive_cmds='$echo "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$echo "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~$echo DATA >> $output_objdir/$libname.def~$echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~$echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def' + old_archive_From_new_cmds='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def' ;; - osf3* | osf4* | osf5*) - lt_prog_compiler_wl='-Wl,' - # All OSF/1 code is PIC. - lt_prog_compiler_static='-non_shared' + osf3*) + if test "$GCC" = yes; then + allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*' + archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + else + allow_undefined_flag=' -expect_unresolved \*' + archive_cmds='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' + fi + hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' + hardcode_libdir_separator=: ;; - rdos*) - lt_prog_compiler_static='-non_shared' + osf4* | osf5*) # as osf3* with the addition of -msym flag + if test "$GCC" = yes; then + allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*' + archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' + else + allow_undefined_flag=' -expect_unresolved \*' + archive_cmds='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -msym -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' + archive_expsym_cmds='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; echo "-hidden">> $lib.exp~ + $LD -shared${allow_undefined_flag} -input $lib.exp $linker_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib~$rm $lib.exp' + + # Both c and cxx compiler support -rpath directly + hardcode_libdir_flag_spec='-rpath $libdir' + fi + hardcode_libdir_separator=: ;; solaris*) - lt_prog_compiler_pic='-KPIC' - lt_prog_compiler_static='-Bstatic' - case $cc_basename in - f77* | f90* | f95*) - lt_prog_compiler_wl='-Qoption ld ';; + no_undefined_flag=' -z text' + if test "$GCC" = yes; then + wlarc='${wl}' + archive_cmds='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ + $CC -shared ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$rm $lib.exp' + else + wlarc='' + archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' + archive_expsym_cmds='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ + $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp' + fi + hardcode_libdir_flag_spec='-R$libdir' + hardcode_shlibpath_var=no + case $host_os in + solaris2.[0-5] | solaris2.[0-5].*) ;; *) - lt_prog_compiler_wl='-Wl,';; + # The compiler driver will combine and reorder linker options, + # but understands `-z linker_flag'. GCC discards it without `$wl', + # but is careful enough not to reorder. + # Supported since Solaris 2.6 (maybe 2.5.1?) + if test "$GCC" = yes; then + whole_archive_flag_spec='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' + else + whole_archive_flag_spec='-z allextract$convenience -z defaultextract' + fi + ;; esac + link_all_deplibs=yes ;; sunos4*) - lt_prog_compiler_wl='-Qoption ld ' - lt_prog_compiler_pic='-PIC' - lt_prog_compiler_static='-Bstatic' + if test "x$host_vendor" = xsequent; then + # Use $CC to link under sequent, because it throws in some extra .o + # files that make .init and .fini sections work. + archive_cmds='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags' + else + archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' + fi + hardcode_libdir_flag_spec='-L$libdir' + hardcode_direct=yes + hardcode_minus_L=yes + hardcode_shlibpath_var=no ;; - sysv4 | sysv4.2uw2* | sysv4.3*) - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_pic='-KPIC' - lt_prog_compiler_static='-Bstatic' + sysv4) + case $host_vendor in + sni) + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_direct=yes # is this really true??? + ;; + siemens) + ## LD is ld it makes a PLAMLIB + ## CC just makes a GrossModule. + archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags' + reload_cmds='$CC -r -o $output$reload_objs' + hardcode_direct=no + ;; + motorola) + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_direct=no #Motorola manual says yes, but my tests say they lie + ;; + esac + runpath_var='LD_RUN_PATH' + hardcode_shlibpath_var=no + ;; + + sysv4.3*) + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_shlibpath_var=no + export_dynamic_flag_spec='-Bexport' ;; sysv4*MP*) - if test -d /usr/nec ;then - lt_prog_compiler_pic='-Kconform_pic' - lt_prog_compiler_static='-Bstatic' + if test -d /usr/nec; then + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_shlibpath_var=no + runpath_var=LD_RUN_PATH + hardcode_runpath_var=yes + ld_shlibs=yes fi ;; - sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_pic='-KPIC' - lt_prog_compiler_static='-Bstatic' - ;; + sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*) + no_undefined_flag='${wl}-z,text' + archive_cmds_need_lc=no + hardcode_shlibpath_var=no + runpath_var='LD_RUN_PATH' - unicos*) - lt_prog_compiler_wl='-Wl,' - lt_prog_compiler_can_build_shared=no + if test "$GCC" = yes; then + archive_cmds='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + else + archive_cmds='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + fi + ;; + + sysv5* | sco3.2v5* | sco5v6*) + # Note: We can NOT use -z defs as we might desire, because we do not + # link with -lc, and that would cause any symbols used from libc to + # always be unresolved, which means just about no library would + # ever link correctly. If we're not using GNU ld we use -z text + # though, which does catch some bad symbols but isn't as heavy-handed + # as -z defs. + no_undefined_flag='${wl}-z,text' + allow_undefined_flag='${wl}-z,nodefs' + archive_cmds_need_lc=no + hardcode_shlibpath_var=no + hardcode_libdir_flag_spec='`test -z "$SCOABSPATH" && echo ${wl}-R,$libdir`' + hardcode_libdir_separator=':' + link_all_deplibs=yes + export_dynamic_flag_spec='${wl}-Bexport' + runpath_var='LD_RUN_PATH' + + if test "$GCC" = yes; then + archive_cmds='$CC -shared ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' + else + archive_cmds='$CC -G ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' + fi ;; uts4*) - lt_prog_compiler_pic='-pic' - lt_prog_compiler_static='-Bstatic' + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_libdir_flag_spec='-L$libdir' + hardcode_shlibpath_var=no ;; *) - lt_prog_compiler_can_build_shared=no + ld_shlibs=no ;; esac fi -case $host_os in - # For platforms which do not support PIC, -DPIC is meaningless: - *djgpp*) - lt_prog_compiler_pic= - ;; - *) - lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC" - ;; -esac -{ $as_echo "$as_me:$LINENO: result: $lt_prog_compiler_pic" >&5 -$as_echo "$lt_prog_compiler_pic" >&6; } - - - - - +{ $as_echo "$as_me:$LINENO: result: $ld_shlibs" >&5 +$as_echo "$ld_shlibs" >&6; } +test "$ld_shlibs" = no && can_build_shared=no # -# Check to make sure the PIC flag actually works. +# Do we need to explicitly link libc? # -if test -n "$lt_prog_compiler_pic"; then - { $as_echo "$as_me:$LINENO: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5 -$as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic works... " >&6; } -if test "${lt_cv_prog_compiler_pic_works+set}" = set; then - $as_echo_n "(cached) " >&6 -else - lt_cv_prog_compiler_pic_works=no - ac_outfile=conftest.$ac_objext - echo "$lt_simple_compile_test_code" > conftest.$ac_ext - lt_compiler_flag="$lt_prog_compiler_pic -DPIC" - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - # The option is referenced via a variable to avoid confusing sed. - lt_compile=`echo "$ac_compile" | $SED \ - -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:8232: $lt_compile\"" >&5) - (eval "$lt_compile" 2>conftest.err) - ac_status=$? - cat conftest.err >&5 - echo "$as_me:8236: \$? = $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. - $ECHO "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp - $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 - if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then - lt_cv_prog_compiler_pic_works=yes - fi - fi - $RM conftest* - -fi -{ $as_echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_pic_works" >&5 -$as_echo "$lt_cv_prog_compiler_pic_works" >&6; } - -if test x"$lt_cv_prog_compiler_pic_works" = xyes; then - case $lt_prog_compiler_pic in - "" | " "*) ;; - *) lt_prog_compiler_pic=" $lt_prog_compiler_pic" ;; - esac -else - lt_prog_compiler_pic= - lt_prog_compiler_can_build_shared=no -fi - -fi - - - - +case "x$archive_cmds_need_lc" in +x|xyes) + # Assume -lc should be added + archive_cmds_need_lc=yes + if test "$enable_shared" = yes && test "$GCC" = yes; then + case $archive_cmds in + *'~'*) + # FIXME: we may have to deal with multi-command sequences. + ;; + '$CC '*) + # Test whether the compiler implicitly links with -lc since on some + # systems, -lgcc has to come before -lc. If gcc already passes -lc + # to ld, don't add -lc before -lgcc. + { $as_echo "$as_me:$LINENO: checking whether -lc should be explicitly linked in" >&5 +$as_echo_n "checking whether -lc should be explicitly linked in... " >&6; } + $rm conftest* + echo "$lt_simple_compile_test_code" > conftest.$ac_ext -# -# Check to make sure the static flag actually works. -# -wl=$lt_prog_compiler_wl eval lt_tmp_static_flag=\"$lt_prog_compiler_static\" -{ $as_echo "$as_me:$LINENO: checking if $compiler static flag $lt_tmp_static_flag works" >&5 -$as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; } -if test "${lt_cv_prog_compiler_static_works+set}" = set; then - $as_echo_n "(cached) " >&6 -else - lt_cv_prog_compiler_static_works=no - save_LDFLAGS="$LDFLAGS" - LDFLAGS="$LDFLAGS $lt_tmp_static_flag" - echo "$lt_simple_link_test_code" > conftest.$ac_ext - if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then - # The linker can only warn and ignore the option if not recognized - # So say no if there are warnings - if test -s conftest.err; then - # Append any errors to the config.log. - cat conftest.err 1>&5 - $ECHO "X$_lt_linker_boilerplate" | $Xsed -e '/^$/d' > conftest.exp - $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 - if diff conftest.exp conftest.er2 >/dev/null; then - lt_cv_prog_compiler_static_works=yes - fi - else - lt_cv_prog_compiler_static_works=yes - fi - fi - $RM -r conftest* - LDFLAGS="$save_LDFLAGS" + if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } 2>conftest.err; then + soname=conftest + lib=conftest + libobjs=conftest.$ac_objext + deplibs= + wl=$lt_prog_compiler_wl + pic_flag=$lt_prog_compiler_pic + compiler_flags=-v + linker_flags=-v + verstring= + output_objdir=. + libname=conftest + lt_save_allow_undefined_flag=$allow_undefined_flag + allow_undefined_flag= + if { (eval echo "$as_me:$LINENO: \"$archive_cmds 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1\"") >&5 + (eval $archive_cmds 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1) 2>&5 + ac_status=$? + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } + then + archive_cmds_need_lc=no + else + archive_cmds_need_lc=yes + fi + allow_undefined_flag=$lt_save_allow_undefined_flag + else + cat conftest.err 1>&5 + fi + $rm conftest* + { $as_echo "$as_me:$LINENO: result: $archive_cmds_need_lc" >&5 +$as_echo "$archive_cmds_need_lc" >&6; } + ;; + esac + fi + ;; +esac -fi -{ $as_echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_static_works" >&5 -$as_echo "$lt_cv_prog_compiler_static_works" >&6; } +{ $as_echo "$as_me:$LINENO: checking dynamic linker characteristics" >&5 +$as_echo_n "checking dynamic linker characteristics... " >&6; } +library_names_spec= +libname_spec='lib$name' +soname_spec= +shrext_cmds=".so" +postinstall_cmds= +postuninstall_cmds= +finish_cmds= +finish_eval= +shlibpath_var= +shlibpath_overrides_runpath=unknown +version_type=none +dynamic_linker="$host_os ld.so" +sys_lib_dlsearch_path_spec="/lib /usr/lib" -if test x"$lt_cv_prog_compiler_static_works" = xyes; then - : +if test "$GCC" = yes; then + case $host_os in + darwin*) lt_awk_arg="/^libraries:/,/LR/" ;; + *) lt_awk_arg="/^libraries:/" ;; + esac + lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e "s,=/,/,g"` + if echo "$lt_search_path_spec" | grep ';' >/dev/null ; then + # if the path contains ";" then we assume it to be the separator + # otherwise default to the standard path separator (i.e. ":") - it is + # assumed that no part of a normal pathname contains ";" but that should + # okay in the real world where ";" in dirpaths is itself problematic. + lt_search_path_spec=`echo "$lt_search_path_spec" | $SED -e 's/;/ /g'` + else + lt_search_path_spec=`echo "$lt_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` + fi + # Ok, now we have the path, separated by spaces, we can step through it + # and add multilib dir if necessary. + lt_tmp_lt_search_path_spec= + lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null` + for lt_sys_path in $lt_search_path_spec; do + if test -d "$lt_sys_path/$lt_multi_os_dir"; then + lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir" + else + test -d "$lt_sys_path" && \ + lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path" + fi + done + lt_search_path_spec=`echo $lt_tmp_lt_search_path_spec | awk ' +BEGIN {RS=" "; FS="/|\n";} { + lt_foo=""; + lt_count=0; + for (lt_i = NF; lt_i > 0; lt_i--) { + if ($lt_i != "" && $lt_i != ".") { + if ($lt_i == "..") { + lt_count++; + } else { + if (lt_count == 0) { + lt_foo="/" $lt_i lt_foo; + } else { + lt_count--; + } + } + } + } + if (lt_foo != "") { lt_freq[lt_foo]++; } + if (lt_freq[lt_foo] == 1) { print lt_foo; } +}'` + sys_lib_search_path_spec=`echo $lt_search_path_spec` else - lt_prog_compiler_static= + sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" fi +need_lib_prefix=unknown +hardcode_into_libs=no +# when you set need_version to no, make sure it does not cause -set_version +# flags to be left without arguments +need_version=unknown +case $host_os in +aix3*) + version_type=linux + library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a' + shlibpath_var=LIBPATH + # AIX 3 has no versioning support, so we append a major version to the name. + soname_spec='${libname}${release}${shared_ext}$major' + ;; +aix[4-9]*) + version_type=linux + need_lib_prefix=no + need_version=no + hardcode_into_libs=yes + if test "$host_cpu" = ia64; then + # AIX 5 supports IA64 + library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + else + # With GCC up to 2.95.x, collect2 would create an import file + # for dependence libraries. The import file would start with + # the line `#! .'. This would cause the generated library to + # depend on `.', always an invalid library. This was fixed in + # development snapshots of GCC prior to 3.0. + case $host_os in + aix4 | aix4.[01] | aix4.[01].*) + if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' + echo ' yes ' + echo '#endif'; } | ${CC} -E - | grep yes > /dev/null; then + : + else + can_build_shared=no + fi + ;; + esac + # AIX (on Power*) has no versioning support, so currently we can not hardcode correct + # soname into executable. Probably we can add versioning support to + # collect2, so additional links can be useful in future. + if test "$aix_use_runtimelinking" = yes; then + # If using run time linking (on AIX 4.2 or later) use lib.so + # instead of lib.a to let people know that these are not + # typical AIX shared libraries. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + else + # We preserve .a as extension for shared libraries through AIX4.2 + # and later when we are not doing run time linking. + library_names_spec='${libname}${release}.a $libname.a' + soname_spec='${libname}${release}${shared_ext}$major' + fi + shlibpath_var=LIBPATH + fi + ;; +amigaos*) + library_names_spec='$libname.ixlibrary $libname.a' + # Create ${libname}_ixlibrary.a entries in /sys/libs. + finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$echo "X$lib" | $Xsed -e '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $rm /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' + ;; +beos*) + library_names_spec='${libname}${shared_ext}' + dynamic_linker="$host_os ld.so" + shlibpath_var=LIBRARY_PATH + ;; - { $as_echo "$as_me:$LINENO: checking if $compiler supports -c -o file.$ac_objext" >&5 -$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } -if test "${lt_cv_prog_compiler_c_o+set}" = set; then - $as_echo_n "(cached) " >&6 -else - lt_cv_prog_compiler_c_o=no - $RM -r conftest 2>/dev/null - mkdir conftest - cd conftest - mkdir out - echo "$lt_simple_compile_test_code" > conftest.$ac_ext - - lt_compiler_flag="-o out/conftest2.$ac_objext" - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - lt_compile=`echo "$ac_compile" | $SED \ - -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:8337: $lt_compile\"" >&5) - (eval "$lt_compile" 2>out/conftest.err) - ac_status=$? - cat out/conftest.err >&5 - echo "$as_me:8341: \$? = $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 - # So say no if there are warnings - $ECHO "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp - $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 - if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then - lt_cv_prog_compiler_c_o=yes - fi - fi - chmod u+w . 2>&5 - $RM conftest* - # SGI C++ compiler will create directory out/ii_files/ for - # template instantiation - test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files - $RM out/* && rmdir out - cd .. - $RM -r conftest - $RM conftest* - -fi -{ $as_echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_c_o" >&5 -$as_echo "$lt_cv_prog_compiler_c_o" >&6; } - - - +bsdi[45]*) + version_type=linux + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' + shlibpath_var=LD_LIBRARY_PATH + sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" + sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" + # the default ld.so.conf also contains /usr/contrib/lib and + # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow + # libtool to hard-code these into programs + ;; +cygwin* | mingw* | pw32*) + version_type=windows + shrext_cmds=".dll" + need_version=no + need_lib_prefix=no + case $GCC,$host_os in + yes,cygwin* | yes,mingw* | yes,pw32*) + library_names_spec='$libname.dll.a' + # DLL is installed to $(libdir)/../bin by postinstall_cmds + postinstall_cmds='base_file=`basename \${file}`~ + dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i;echo \$dlname'\''`~ + dldir=$destdir/`dirname \$dlpath`~ + test -d \$dldir || mkdir -p \$dldir~ + $install_prog $dir/$dlname \$dldir/$dlname~ + chmod a+x \$dldir/$dlname' + postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ + dlpath=$dir/\$dldll~ + $rm \$dlpath' + shlibpath_overrides_runpath=yes - { $as_echo "$as_me:$LINENO: checking if $compiler supports -c -o file.$ac_objext" >&5 -$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } -if test "${lt_cv_prog_compiler_c_o+set}" = set; then - $as_echo_n "(cached) " >&6 -else - lt_cv_prog_compiler_c_o=no - $RM -r conftest 2>/dev/null - mkdir conftest - cd conftest - mkdir out - echo "$lt_simple_compile_test_code" > conftest.$ac_ext + case $host_os in + cygwin*) + # Cygwin DLLs use 'cyg' prefix rather than 'lib' + soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' + sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib" + ;; + mingw*) + # MinGW DLLs use traditional 'lib' prefix + soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' + sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"` + if echo "$sys_lib_search_path_spec" | grep ';[c-zC-Z]:/' >/dev/null; then + # It is most probably a Windows format PATH printed by + # mingw gcc, but we are running on Cygwin. Gcc prints its search + # path with ; separators, and with drive letters. We can handle the + # drive letters (cygwin fileutils understands them), so leave them, + # especially as we might pass files found there to a mingw objdump, + # which wouldn't understand a cygwinified path. Ahh. + sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` + else + sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` + fi + ;; + pw32*) + # pw32 DLLs use 'pw' prefix rather than 'lib' + library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' + ;; + esac + ;; - lt_compiler_flag="-o out/conftest2.$ac_objext" - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - lt_compile=`echo "$ac_compile" | $SED \ - -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:8392: $lt_compile\"" >&5) - (eval "$lt_compile" 2>out/conftest.err) - ac_status=$? - cat out/conftest.err >&5 - echo "$as_me:8396: \$? = $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 - # So say no if there are warnings - $ECHO "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp - $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 - if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then - lt_cv_prog_compiler_c_o=yes - fi - fi - chmod u+w . 2>&5 - $RM conftest* - # SGI C++ compiler will create directory out/ii_files/ for - # template instantiation - test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files - $RM out/* && rmdir out - cd .. - $RM -r conftest - $RM conftest* + *) + library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib' + ;; + esac + dynamic_linker='Win32 ld.exe' + # FIXME: first we should search . and the directory the executable is in + shlibpath_var=PATH + ;; -fi -{ $as_echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_c_o" >&5 -$as_echo "$lt_cv_prog_compiler_c_o" >&6; } +darwin* | rhapsody*) + dynamic_linker="$host_os dyld" + version_type=darwin + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${versuffix}$shared_ext ${libname}${release}${major}$shared_ext ${libname}$shared_ext' + soname_spec='${libname}${release}${major}$shared_ext' + shlibpath_overrides_runpath=yes + shlibpath_var=DYLD_LIBRARY_PATH + shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' + sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib" + sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' + ;; +dgux*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + ;; +freebsd1*) + dynamic_linker=no + ;; -hard_links="nottested" -if test "$lt_cv_prog_compiler_c_o" = no && test "$need_locks" != no; then - # do not overwrite the value of need_locks provided by the user - { $as_echo "$as_me:$LINENO: checking if we can lock with hard links" >&5 -$as_echo_n "checking if we can lock with hard links... " >&6; } - hard_links=yes - $RM conftest* - ln conftest.a conftest.b 2>/dev/null && hard_links=no - touch conftest.a - ln conftest.a conftest.b 2>&5 || hard_links=no - ln conftest.a conftest.b 2>/dev/null && hard_links=no - { $as_echo "$as_me:$LINENO: result: $hard_links" >&5 -$as_echo "$hard_links" >&6; } - if test "$hard_links" = no; then - { $as_echo "$as_me:$LINENO: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5 -$as_echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;} - need_locks=warn +freebsd* | dragonfly*) + # DragonFly does not have aout. When/if they implement a new + # versioning mechanism, adjust this. + if test -x /usr/bin/objformat; then + objformat=`/usr/bin/objformat` + else + case $host_os in + freebsd[123]*) objformat=aout ;; + *) objformat=elf ;; + esac fi -else - need_locks=no -fi - - - - - - - { $as_echo "$as_me:$LINENO: checking whether the $compiler linker ($LD) supports shared libraries" >&5 -$as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; } - - runpath_var= - allow_undefined_flag= - always_export_symbols=no - archive_cmds= - archive_expsym_cmds= - compiler_needs_object=no - enable_shared_with_static_runtimes=no - export_dynamic_flag_spec= - export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' - hardcode_automatic=no - hardcode_direct=no - hardcode_direct_absolute=no - hardcode_libdir_flag_spec= - hardcode_libdir_flag_spec_ld= - hardcode_libdir_separator= - hardcode_minus_L=no - hardcode_shlibpath_var=unsupported - inherit_rpath=no - link_all_deplibs=unknown - module_cmds= - module_expsym_cmds= - old_archive_from_new_cmds= - old_archive_from_expsyms_cmds= - thread_safe_flag_spec= - whole_archive_flag_spec= - # include_expsyms should be a list of space-separated symbols to be *always* - # included in the symbol list - include_expsyms= - # exclude_expsyms can be an extended regexp of symbols to exclude - # it will be wrapped by ` (' and `)$', so one must not match beginning or - # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc', - # as well as any symbol that contains `d'. - exclude_expsyms='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*' - # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out - # platforms (ab)use it in PIC code, but their linkers get confused if - # the symbol is explicitly referenced. Since portable code cannot - # rely on this symbol name, it's probably fine to never include it in - # preloaded symbol tables. - # Exclude shared library initialization/finalization symbols. - extract_expsyms_cmds= - + version_type=freebsd-$objformat + case $version_type in + freebsd-elf*) + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' + need_version=no + need_lib_prefix=no + ;; + freebsd-*) + library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' + need_version=yes + ;; + esac + shlibpath_var=LD_LIBRARY_PATH case $host_os in - cygwin* | mingw* | pw32* | cegcc*) - # FIXME: the MSVC++ port hasn't been tested in a loooong time - # When not using gcc, we currently assume that we are using - # Microsoft Visual C++. - if test "$GCC" != yes; then - with_gnu_ld=no - fi + freebsd2*) + shlibpath_overrides_runpath=yes ;; - interix*) - # we just hope/assume this is gcc and not c89 (= MSVC++) - with_gnu_ld=yes + freebsd3.[01]* | freebsdelf3.[01]*) + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes ;; - openbsd*) - with_gnu_ld=no + freebsd3.[2-9]* | freebsdelf3.[2-9]* | \ + freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1) + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; + *) # from 4.6 on, and DragonFly + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes ;; esac + ;; - ld_shlibs=yes - if test "$with_gnu_ld" = yes; then - # If archive_cmds runs LD, not CC, wlarc should be empty - wlarc='${wl}' +gnu*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + hardcode_into_libs=yes + ;; - # Set some defaults for GNU ld with shared library support. These - # are reset later if shared libraries are not supported. Putting them - # here allows them to be overridden if necessary. - runpath_var=LD_RUN_PATH - hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' - export_dynamic_flag_spec='${wl}--export-dynamic' - # ancient GNU ld didn't support --whole-archive et. al. - if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then - whole_archive_flag_spec="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' +hpux9* | hpux10* | hpux11*) + # Give a soname corresponding to the major version so that dld.sl refuses to + # link against other versions. + version_type=sunos + need_lib_prefix=no + need_version=no + case $host_cpu in + ia64*) + shrext_cmds='.so' + hardcode_into_libs=yes + dynamic_linker="$host_os dld.so" + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + if test "X$HPUX_IA64_MODE" = X32; then + sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" else - whole_archive_flag_spec= + sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" fi - supports_anon_versioning=no - case `$LD -v 2>&1` in - *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11 - *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... - *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... - *\ 2.11.*) ;; # other 2.11 versions - *) supports_anon_versioning=yes ;; - esac - - # See if GNU ld supports shared libraries. - case $host_os in - aix[3-9]*) - # On AIX/PPC, the GNU linker is very broken - if test "$host_cpu" != ia64; then - ld_shlibs=no - cat <<_LT_EOF 1>&2 + sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec + ;; + hppa*64*) + shrext_cmds='.sl' + hardcode_into_libs=yes + dynamic_linker="$host_os dld.sl" + shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH + shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" + sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec + ;; + *) + shrext_cmds='.sl' + dynamic_linker="$host_os dld.sl" + shlibpath_var=SHLIB_PATH + shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + ;; + esac + # HP-UX runs *really* slowly unless shared libraries are mode 555. + postinstall_cmds='chmod 555 $lib' + ;; -*** Warning: the GNU linker, at least up to release 2.9.1, is reported -*** to be unable to reliably create shared libraries on AIX. -*** Therefore, libtool is disabling shared libraries support. If you -*** really care for shared libraries, you may want to modify your PATH -*** so that a non-GNU linker is found, and then restart. +interix[3-9]*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; -_LT_EOF - fi - ;; +irix5* | irix6* | nonstopux*) + case $host_os in + nonstopux*) version_type=nonstopux ;; + *) + if test "$lt_cv_prog_gnu_ld" = yes; then + version_type=linux + else + version_type=irix + fi ;; + esac + need_lib_prefix=no + need_version=no + soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}' + case $host_os in + irix5* | nonstopux*) + libsuff= shlibsuff= + ;; + *) + case $LD in # libtool.m4 will add one of these switches to LD + *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") + libsuff= shlibsuff= libmagic=32-bit;; + *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") + libsuff=32 shlibsuff=N32 libmagic=N32;; + *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") + libsuff=64 shlibsuff=64 libmagic=64-bit;; + *) libsuff= shlibsuff= libmagic=never-match;; + esac + ;; + esac + shlibpath_var=LD_LIBRARY${shlibsuff}_PATH + shlibpath_overrides_runpath=no + sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" + sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" + hardcode_into_libs=yes + ;; - amigaos*) - case $host_cpu in - powerpc) - # see comment about AmigaOS4 .so support - archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - archive_expsym_cmds='' - ;; - m68k) - archive_cmds='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' - hardcode_libdir_flag_spec='-L$libdir' - hardcode_minus_L=yes - ;; - esac - ;; +# No shared lib support for Linux oldld, aout, or coff. +linux*oldld* | linux*aout* | linux*coff*) + dynamic_linker=no + ;; - beos*) - if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then - allow_undefined_flag=unsupported - # Joseph Beckenbach says some releases of gcc - # support --undefined. This deserves some investigation. FIXME - archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - else - ld_shlibs=no - fi - ;; +# This must be Linux ELF. +linux* | k*bsd*-gnu) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + # This implies no fast_install, which is unacceptable. + # Some rework will be needed to allow for fast_install + # before this can be enabled. + hardcode_into_libs=yes - cygwin* | mingw* | pw32* | cegcc*) - # _LT_TAGVAR(hardcode_libdir_flag_spec, ) is actually meaningless, - # as there is no search path for DLLs. - hardcode_libdir_flag_spec='-L$libdir' - allow_undefined_flag=unsupported - always_export_symbols=no - enable_shared_with_static_runtimes=yes - export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols' + # Append ld.so.conf contents to the search path + if test -f /etc/ld.so.conf; then + lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '` + sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" + fi - if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then - archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' - # If the export-symbols file already is a .def file (1st line - # is EXPORTS), use it as is; otherwise, prepend... - archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then - cp $export_symbols $output_objdir/$soname.def; - else - echo EXPORTS > $output_objdir/$soname.def; - cat $export_symbols >> $output_objdir/$soname.def; - fi~ - $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' - else - ld_shlibs=no - fi - ;; + # We used to test for /lib/ld.so.1 and disable shared libraries on + # powerpc, because MkLinux only supported shared libraries with the + # GNU dynamic linker. Since this was broken with cross compilers, + # most powerpc-linux boxes support dynamic linking these days and + # people can always --disable-shared, the test was removed, and we + # assume the GNU/Linux dynamic linker is in use. + dynamic_linker='GNU/Linux ld.so' + ;; - interix[3-9]*) - hardcode_direct=no - hardcode_shlibpath_var=no - hardcode_libdir_flag_spec='${wl}-rpath,$libdir' - export_dynamic_flag_spec='${wl}-E' - # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. - # Instead, shared libraries are loaded at an image base (0x10000000 by - # default) and relocated if they conflict, which is a slow very memory - # consuming and fragmenting process. To avoid this, we pick a random, - # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link - # time. Moving up from 0x10000000 also allows more sbrk(2) space. - archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' - archive_expsym_cmds='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' - ;; - - gnu* | linux* | tpf* | k*bsd*-gnu) - tmp_diet=no - if test "$host_os" = linux-dietlibc; then - case $cc_basename in - diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn) - esac - fi - if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \ - && test "$tmp_diet" = no - then - tmp_addflag= - tmp_sharedflag='-shared' - case $cc_basename,$host_cpu in - pgcc*) # Portland Group C compiler - whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive' - tmp_addflag=' $pic_flag' - ;; - pgf77* | pgf90* | pgf95*) # Portland Group f77 and f90 compilers - whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive' - tmp_addflag=' $pic_flag -Mnomain' ;; - ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 - tmp_addflag=' -i_dynamic' ;; - efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 - tmp_addflag=' -i_dynamic -nofor_main' ;; - ifc* | ifort*) # Intel Fortran compiler - tmp_addflag=' -nofor_main' ;; - lf95*) # Lahey Fortran 8.1 - whole_archive_flag_spec= - tmp_sharedflag='--shared' ;; - xl[cC]*) # IBM XL C 8.0 on PPC (deal with xlf below) - tmp_sharedflag='-qmkshrobj' - tmp_addflag= ;; - esac - case `$CC -V 2>&1 | sed 5q` in - *Sun\ C*) # Sun C 5.9 - whole_archive_flag_spec='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $ECHO \"$new_convenience\"` ${wl}--no-whole-archive' - compiler_needs_object=yes - tmp_sharedflag='-G' ;; - *Sun\ F*) # Sun Fortran 8.3 - tmp_sharedflag='-G' ;; - esac - archive_cmds='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' +netbsd*) + version_type=sunos + need_lib_prefix=no + need_version=no + if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' + dynamic_linker='NetBSD (a.out) ld.so' + else + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + dynamic_linker='NetBSD ld.elf_so' + fi + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; - if test "x$supports_anon_versioning" = xyes; then - archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~ - cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ - echo "local: *; };" >> $output_objdir/$libname.ver~ - $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' - fi +newsos6) + version_type=linux + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + ;; - case $cc_basename in - xlf*) - # IBM XL Fortran 10.1 on PPC cannot create shared libs itself - whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive' - hardcode_libdir_flag_spec= - hardcode_libdir_flag_spec_ld='-rpath $libdir' - archive_cmds='$LD -shared $libobjs $deplibs $compiler_flags -soname $soname -o $lib' - if test "x$supports_anon_versioning" = xyes; then - archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~ - cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ - echo "local: *; };" >> $output_objdir/$libname.ver~ - $LD -shared $libobjs $deplibs $compiler_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib' - fi - ;; - esac - else - ld_shlibs=no - fi - ;; +nto-qnx*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + ;; - netbsd*) - if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then - archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' - wlarc= - else - archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - fi - ;; +openbsd*) + version_type=sunos + sys_lib_dlsearch_path_spec="/usr/lib" + need_lib_prefix=no + # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs. + case $host_os in + openbsd3.3 | openbsd3.3.*) need_version=yes ;; + *) need_version=no ;; + esac + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' + shlibpath_var=LD_LIBRARY_PATH + if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then + case $host_os in + openbsd2.[89] | openbsd2.[89].*) + shlibpath_overrides_runpath=no + ;; + *) + shlibpath_overrides_runpath=yes + ;; + esac + else + shlibpath_overrides_runpath=yes + fi + ;; - solaris*) - if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then - ld_shlibs=no - cat <<_LT_EOF 1>&2 +os2*) + libname_spec='$name' + shrext_cmds=".dll" + need_lib_prefix=no + library_names_spec='$libname${shared_ext} $libname.a' + dynamic_linker='OS/2 ld.exe' + shlibpath_var=LIBPATH + ;; -*** Warning: The releases 2.8.* of the GNU linker cannot reliably -*** create shared libraries on Solaris systems. Therefore, libtool -*** is disabling shared libraries support. We urge you to upgrade GNU -*** binutils to release 2.9.1 or newer. Another option is to modify -*** your PATH or compiler configuration so that the native linker is -*** used, and then restart. +osf3* | osf4* | osf5*) + version_type=osf + need_lib_prefix=no + need_version=no + soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" + sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" + ;; -_LT_EOF - elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then - archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - else - ld_shlibs=no - fi - ;; +rdos*) + dynamic_linker=no + ;; - sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*) - case `$LD -v 2>&1` in - *\ [01].* | *\ 2.[0-9].* | *\ 2.1[0-5].*) - ld_shlibs=no - cat <<_LT_EOF 1>&2 +solaris*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + # ldd complains unless libraries are executable + postinstall_cmds='chmod +x $lib' + ;; -*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not -*** reliably create shared libraries on SCO systems. Therefore, libtool -*** is disabling shared libraries support. We urge you to upgrade GNU -*** binutils to release 2.16.91.0.3 or newer. Another option is to modify -*** your PATH or compiler configuration so that the native linker is -*** used, and then restart. +sunos4*) + version_type=sunos + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' + finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + if test "$with_gnu_ld" = yes; then + need_lib_prefix=no + fi + need_version=yes + ;; -_LT_EOF - ;; - *) - # For security reasons, it is highly recommended that you always - # use absolute paths for naming shared libraries, and exclude the - # DT_RUNPATH tag from executables and libraries. But doing so - # requires that you compile everything twice, which is a pain. - if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then - hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' - archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - else - ld_shlibs=no - fi - ;; - esac +sysv4 | sysv4.3*) + version_type=linux + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + case $host_vendor in + sni) + shlibpath_overrides_runpath=no + need_lib_prefix=no + export_dynamic_flag_spec='${wl}-Blargedynsym' + runpath_var=LD_RUN_PATH ;; - - sunos4*) - archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' - wlarc= - hardcode_direct=yes - hardcode_shlibpath_var=no + siemens) + need_lib_prefix=no ;; - - *) - if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then - archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - else - ld_shlibs=no - fi + motorola) + need_lib_prefix=no + need_version=no + shlibpath_overrides_runpath=no + sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' ;; - esac + esac + ;; - if test "$ld_shlibs" = no; then - runpath_var= - hardcode_libdir_flag_spec= - export_dynamic_flag_spec= - whole_archive_flag_spec= - fi +sysv4*MP*) + if test -d /usr/nec ;then + version_type=linux + library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' + soname_spec='$libname${shared_ext}.$major' + shlibpath_var=LD_LIBRARY_PATH + fi + ;; + +sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) + version_type=freebsd-elf + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + hardcode_into_libs=yes + if test "$with_gnu_ld" = yes; then + sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' + shlibpath_overrides_runpath=no else - # PORTME fill in a description of your system's linker (not GNU ld) + sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' + shlibpath_overrides_runpath=yes case $host_os in - aix3*) - allow_undefined_flag=unsupported - always_export_symbols=yes - archive_expsym_cmds='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname' - # Note: this linker hardcodes the directories in LIBPATH if there - # are no directories specified by -L. - hardcode_minus_L=yes - if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then - # Neither direct hardcoding nor static linking is supported with a - # broken collect2. - hardcode_direct=unsupported - fi - ;; + sco3.2v5*) + sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" + ;; + esac + fi + sys_lib_dlsearch_path_spec='/usr/lib' + ;; - aix[4-9]*) - if test "$host_cpu" = ia64; then - # On IA64, the linker does run time linking by default, so we don't - # have to do anything special. - aix_use_runtimelinking=no - exp_sym_flag='-Bexport' - no_entry_flag="" - else - # If we're using GNU nm, then we don't want the "-C" option. - # -C means demangle to AIX nm, but means don't demangle with GNU nm - if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then - export_symbols_cmds='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols' - else - export_symbols_cmds='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols' - fi - aix_use_runtimelinking=no +uts4*) + version_type=linux + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + ;; - # Test if we are trying to use run time linking or normal - # AIX style linking. If -brtl is somewhere in LDFLAGS, we - # need to do runtime linking. - case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*) - for ld_flag in $LDFLAGS; do - if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then - aix_use_runtimelinking=yes - break - fi - done - ;; - esac +*) + dynamic_linker=no + ;; +esac +{ $as_echo "$as_me:$LINENO: result: $dynamic_linker" >&5 +$as_echo "$dynamic_linker" >&6; } +test "$dynamic_linker" = no && can_build_shared=no - exp_sym_flag='-bexport' - no_entry_flag='-bnoentry' - fi +if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then + $as_echo_n "(cached) " >&6 +else + lt_cv_sys_lib_search_path_spec="$sys_lib_search_path_spec" +fi - # When large executables or shared objects are built, AIX ld can - # have problems creating the table of contents. If linking a library - # or program results in "error TOC overflow" add -mminimal-toc to - # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not - # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. +sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec" +if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then + $as_echo_n "(cached) " >&6 +else + lt_cv_sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec" +fi - archive_cmds='' - hardcode_direct=yes - hardcode_direct_absolute=yes - hardcode_libdir_separator=':' - link_all_deplibs=yes - file_list_spec='${wl}-f,' +sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec" - if test "$GCC" = yes; then - case $host_os in aix4.[012]|aix4.[012].*) - # We only want to do this on AIX 4.2 and lower, the check - # below for broken collect2 doesn't work under 4.3+ - collect2name=`${CC} -print-prog-name=collect2` - if test -f "$collect2name" && - strings "$collect2name" | $GREP resolve_lib_name >/dev/null - then - # We have reworked collect2 - : - else - # We have old collect2 - hardcode_direct=unsupported - # It fails to find uninstalled libraries when the uninstalled - # path is not listed in the libpath. Setting hardcode_minus_L - # to unsupported forces relinking - hardcode_minus_L=yes - hardcode_libdir_flag_spec='-L$libdir' - hardcode_libdir_separator= - fi - ;; - esac - shared_flag='-shared' - if test "$aix_use_runtimelinking" = yes; then - shared_flag="$shared_flag "'${wl}-G' - fi - else - # not using gcc - if test "$host_cpu" = ia64; then - # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release - # chokes on -Wl,-G. The following line is correct: - shared_flag='-G' - else - if test "$aix_use_runtimelinking" = yes; then - shared_flag='${wl}-G' - else - shared_flag='${wl}-bM:SRE' - fi - fi - fi +variables_saved_for_relink="PATH $shlibpath_var $runpath_var" +if test "$GCC" = yes; then + variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" +fi - export_dynamic_flag_spec='${wl}-bexpall' - # It seems that -bexpall does not export symbols beginning with - # underscore (_), so it is better to generate a list of symbols to export. - always_export_symbols=yes - if test "$aix_use_runtimelinking" = yes; then - # Warning - without using the other runtime loading flags (-brtl), - # -berok will link without error, but may produce a broken library. - allow_undefined_flag='-berok' - # Determine the default libpath from the value encoded in an - # empty executable. - cat >conftest.$ac_ext <<_ACEOF +{ $as_echo "$as_me:$LINENO: checking how to hardcode library paths into programs" >&5 +$as_echo_n "checking how to hardcode library paths into programs... " >&6; } +hardcode_action= +if test -n "$hardcode_libdir_flag_spec" || \ + test -n "$runpath_var" || \ + test "X$hardcode_automatic" = "Xyes" ; then + + # We can hardcode non-existant directories. + if test "$hardcode_direct" != no && + # If the only mechanism to avoid hardcoding is shlibpath_var, we + # have to relink, otherwise we might link with an installed library + # when we should be linking with a yet-to-be-installed one + ## test "$_LT_AC_TAGVAR(hardcode_shlibpath_var, )" != no && + test "$hardcode_minus_L" != no; then + # Linking always hardcodes the temporary library directory. + hardcode_action=relink + else + # We can link without hardcoding, and we can hardcode nonexisting dirs. + hardcode_action=immediate + fi +else + # We cannot hardcode anything, or else we can only hardcode existing + # directories. + hardcode_action=unsupported +fi +{ $as_echo "$as_me:$LINENO: result: $hardcode_action" >&5 +$as_echo "$hardcode_action" >&6; } + +if test "$hardcode_action" = relink; then + # Fast installation is not supported + enable_fast_install=no +elif test "$shlibpath_overrides_runpath" = yes || + test "$enable_shared" = no; then + # Fast installation is not necessary + enable_fast_install=needless +fi + +striplib= +old_striplib= +{ $as_echo "$as_me:$LINENO: checking whether stripping libraries is possible" >&5 +$as_echo_n "checking whether stripping libraries is possible... " >&6; } +if test -n "$STRIP" && $STRIP -V 2>&1 | grep "GNU strip" >/dev/null; then + test -z "$old_striplib" && old_striplib="$STRIP --strip-debug" + test -z "$striplib" && striplib="$STRIP --strip-unneeded" + { $as_echo "$as_me:$LINENO: result: yes" >&5 +$as_echo "yes" >&6; } +else +# FIXME - insert some real tests, host_os isn't really good enough + case $host_os in + darwin*) + if test -n "$STRIP" ; then + striplib="$STRIP -x" + old_striplib="$STRIP -S" + { $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; } +fi + ;; + *) + { $as_echo "$as_me:$LINENO: result: no" >&5 +$as_echo "no" >&6; } + ;; + esac +fi + +if test "x$enable_dlopen" != xyes; then + enable_dlopen=unknown + enable_dlopen_self=unknown + enable_dlopen_self_static=unknown +else + lt_cv_dlopen=no + lt_cv_dlopen_libs= + + case $host_os in + beos*) + lt_cv_dlopen="load_add_on" + lt_cv_dlopen_libs= + lt_cv_dlopen_self=yes + ;; + + mingw* | pw32*) + lt_cv_dlopen="LoadLibrary" + lt_cv_dlopen_libs= + ;; + + cygwin*) + lt_cv_dlopen="dlopen" + lt_cv_dlopen_libs= + ;; + + darwin*) + # if libdl is installed we need to link against it + { $as_echo "$as_me:$LINENO: checking for dlopen in -ldl" >&5 +$as_echo_n "checking for dlopen in -ldl... " >&6; } +if test "${ac_cv_lib_dl_dlopen+set}" = set; then + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-ldl $LIBS" +cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char dlopen (); int main () { - +return dlopen (); ; return 0; } @@ -8926,52 +10308,80 @@ $as_echo "$ac_try_echo") >&5 test "$cross_compiling" = yes || $as_test_x conftest$ac_exeext }; then - -lt_aix_libpath_sed=' - /Import File Strings/,/^$/ { - /^0/ { - s/^0 *\(.*\)$/\1/ - p - } - }' -aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` -# Check for a 64-bit object if we didn't find anything. -if test -z "$aix_libpath"; then - aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` -fi + ac_cv_lib_dl_dlopen=yes else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 - + ac_cv_lib_dl_dlopen=no fi rm -rf conftest.dSYM rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext -if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_dl_dlopen" >&5 +$as_echo "$ac_cv_lib_dl_dlopen" >&6; } +if test "x$ac_cv_lib_dl_dlopen" = x""yes; then + lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl" +else - hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath" - archive_expsym_cmds='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then $ECHO "X${wl}${allow_undefined_flag}" | $Xsed; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag" - else - if test "$host_cpu" = ia64; then - hardcode_libdir_flag_spec='${wl}-R $libdir:/usr/lib:/lib' - allow_undefined_flag="-z nodefs" - archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols" - else - # Determine the default libpath from the value encoded in an - # empty executable. - cat >conftest.$ac_ext <<_ACEOF + lt_cv_dlopen="dyld" + lt_cv_dlopen_libs= + lt_cv_dlopen_self=yes + +fi + + ;; + + *) + { $as_echo "$as_me:$LINENO: checking for shl_load" >&5 +$as_echo_n "checking for shl_load... " >&6; } +if test "${ac_cv_func_shl_load+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. */ +/* Define shl_load to an innocuous variant, in case declares shl_load. + For example, HP-UX 11i declares gettimeofday. */ +#define shl_load innocuous_shl_load -int -main () -{ +/* System header to define __stub macros and hopefully few prototypes, + which can conflict with char shl_load (); below. + Prefer to if __STDC__ is defined, since + exists even on freestanding compilers. */ + +#ifdef __STDC__ +# include +#else +# include +#endif + +#undef shl_load + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char shl_load (); +/* The GNU C library defines this for functions which it implements + to always fail with ENOSYS. Some functions are actually named + something starting with __ and the normal name is an alias. */ +#if defined __stub_shl_load || defined __stub___shl_load +choke me +#endif +int +main () +{ +return shl_load (); ; return 0; } @@ -8997,242 +10407,51 @@ $as_echo "$ac_try_echo") >&5 test "$cross_compiling" = yes || $as_test_x conftest$ac_exeext }; then - -lt_aix_libpath_sed=' - /Import File Strings/,/^$/ { - /^0/ { - s/^0 *\(.*\)$/\1/ - p - } - }' -aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` -# Check for a 64-bit object if we didn't find anything. -if test -z "$aix_libpath"; then - aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` -fi + ac_cv_func_shl_load=yes else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 - + ac_cv_func_shl_load=no fi rm -rf conftest.dSYM rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext -if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi - - hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath" - # Warning - without using the other run time loading flags, - # -berok will link without error, but may produce a broken library. - no_undefined_flag=' ${wl}-bernotok' - allow_undefined_flag=' ${wl}-berok' - # Exported symbols can be pulled into shared objects from archives - whole_archive_flag_spec='$convenience' - archive_cmds_need_lc=yes - # This is similar to how AIX traditionally builds its shared libraries. - archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' - fi - fi - ;; - - amigaos*) - case $host_cpu in - powerpc) - # see comment about AmigaOS4 .so support - archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - archive_expsym_cmds='' - ;; - m68k) - archive_cmds='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' - hardcode_libdir_flag_spec='-L$libdir' - hardcode_minus_L=yes - ;; - esac - ;; - - bsdi[45]*) - export_dynamic_flag_spec=-rdynamic - ;; - - cygwin* | mingw* | pw32* | cegcc*) - # When not using gcc, we currently assume that we are using - # Microsoft Visual C++. - # hardcode_libdir_flag_spec is actually meaningless, as there is - # no search path for DLLs. - hardcode_libdir_flag_spec=' ' - allow_undefined_flag=unsupported - # Tell ltmain to make .lib files, not .a files. - libext=lib - # Tell ltmain to make .dll files, not .so files. - shrext_cmds=".dll" - # FIXME: Setting linknames here is a bad hack. - archive_cmds='$CC -o $lib $libobjs $compiler_flags `$ECHO "X$deplibs" | $Xsed -e '\''s/ -lc$//'\''` -link -dll~linknames=' - # The linker will automatically build a .lib file if we build a DLL. - old_archive_from_new_cmds='true' - # FIXME: Should let the user specify the lib program. - old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs' - fix_srcfile_path='`cygpath -w "$srcfile"`' - enable_shared_with_static_runtimes=yes - ;; - - darwin* | rhapsody*) - - - archive_cmds_need_lc=no - hardcode_direct=no - hardcode_automatic=yes - hardcode_shlibpath_var=unsupported - whole_archive_flag_spec='' - link_all_deplibs=yes - allow_undefined_flag="$_lt_dar_allow_undefined" - case $cc_basename in - ifort*) _lt_dar_can_shared=yes ;; - *) _lt_dar_can_shared=$GCC ;; - esac - if test "$_lt_dar_can_shared" = "yes"; then - output_verbose_link_cmd=echo - archive_cmds="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}" - module_cmds="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}" - archive_expsym_cmds="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}" - module_expsym_cmds="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}" - - else - ld_shlibs=no - fi - - ;; - - dgux*) - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_libdir_flag_spec='-L$libdir' - hardcode_shlibpath_var=no - ;; - - freebsd1*) - ld_shlibs=no - ;; - - # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor - # support. Future versions do this automatically, but an explicit c++rt0.o - # does not break anything, and helps significantly (at the cost of a little - # extra space). - freebsd2.2*) - archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' - hardcode_libdir_flag_spec='-R$libdir' - hardcode_direct=yes - hardcode_shlibpath_var=no - ;; - - # Unfortunately, older versions of FreeBSD 2 do not have this feature. - freebsd2*) - archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' - hardcode_direct=yes - hardcode_minus_L=yes - hardcode_shlibpath_var=no - ;; - - # FreeBSD 3 and greater uses gcc -shared to do shared libraries. - freebsd* | dragonfly*) - archive_cmds='$CC -shared -o $lib $libobjs $deplibs $compiler_flags' - hardcode_libdir_flag_spec='-R$libdir' - hardcode_direct=yes - hardcode_shlibpath_var=no - ;; - - hpux9*) - if test "$GCC" = yes; then - archive_cmds='$RM $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' - else - archive_cmds='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' - fi - hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' - hardcode_libdir_separator=: - hardcode_direct=yes - - # hardcode_minus_L: Not really in the search PATH, - # but as the default location of the library. - hardcode_minus_L=yes - export_dynamic_flag_spec='${wl}-E' - ;; - - hpux10*) - if test "$GCC" = yes -a "$with_gnu_ld" = no; then - archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' - else - archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' - fi - if test "$with_gnu_ld" = no; then - hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' - hardcode_libdir_flag_spec_ld='+b $libdir' - hardcode_libdir_separator=: - hardcode_direct=yes - hardcode_direct_absolute=yes - export_dynamic_flag_spec='${wl}-E' - # hardcode_minus_L: Not really in the search PATH, - # but as the default location of the library. - hardcode_minus_L=yes - fi - ;; - - hpux11*) - if test "$GCC" = yes -a "$with_gnu_ld" = no; then - case $host_cpu in - hppa*64*) - archive_cmds='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - ;; - ia64*) - archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' - ;; - *) - archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' - ;; - esac - else - case $host_cpu in - hppa*64*) - archive_cmds='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - ;; - ia64*) - archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' - ;; - *) - archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' - ;; - esac - fi - if test "$with_gnu_ld" = no; then - hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' - hardcode_libdir_separator=: - - case $host_cpu in - hppa*64*|ia64*) - hardcode_direct=no - hardcode_shlibpath_var=no - ;; - *) - hardcode_direct=yes - hardcode_direct_absolute=yes - export_dynamic_flag_spec='${wl}-E' - - # hardcode_minus_L: Not really in the search PATH, - # but as the default location of the library. - hardcode_minus_L=yes - ;; - esac - fi - ;; +fi +{ $as_echo "$as_me:$LINENO: result: $ac_cv_func_shl_load" >&5 +$as_echo "$ac_cv_func_shl_load" >&6; } +if test "x$ac_cv_func_shl_load" = x""yes; then + lt_cv_dlopen="shl_load" +else + { $as_echo "$as_me:$LINENO: checking for shl_load in -ldld" >&5 +$as_echo_n "checking for shl_load in -ldld... " >&6; } +if test "${ac_cv_lib_dld_shl_load+set}" = set; then + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-ldld $LIBS" +cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ - irix5* | irix6* | nonstopux*) - if test "$GCC" = yes; then - archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' - # Try to use the -exported_symbol ld option, if it does not - # work, assume that -exports_file does not work either and - # implicitly export all symbols. - save_LDFLAGS="$LDFLAGS" - LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null" - cat >conftest.$ac_ext <<_ACEOF -int foo(void) {} +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char shl_load (); +int +main () +{ +return shl_load (); + ; + return 0; +} _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" @@ -9255,935 +10474,1530 @@ $as_echo "$ac_try_echo") >&5 test "$cross_compiling" = yes || $as_test_x conftest$ac_exeext }; then - archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib' - + ac_cv_lib_dld_shl_load=yes else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 - + ac_cv_lib_dld_shl_load=no fi rm -rf conftest.dSYM rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext - LDFLAGS="$save_LDFLAGS" - else - archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib' - archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib' - fi - archive_cmds_need_lc='no' - hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' - hardcode_libdir_separator=: - inherit_rpath=yes - link_all_deplibs=yes - ;; - - netbsd*) - if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then - archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out - else - archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF - fi - hardcode_libdir_flag_spec='-R$libdir' - hardcode_direct=yes - hardcode_shlibpath_var=no - ;; +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_dld_shl_load" >&5 +$as_echo "$ac_cv_lib_dld_shl_load" >&6; } +if test "x$ac_cv_lib_dld_shl_load" = x""yes; then + lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld" +else + { $as_echo "$as_me:$LINENO: checking for dlopen" >&5 +$as_echo_n "checking for dlopen... " >&6; } +if test "${ac_cv_func_dlopen+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. */ +/* Define dlopen to an innocuous variant, in case declares dlopen. + For example, HP-UX 11i declares gettimeofday. */ +#define dlopen innocuous_dlopen - newsos6) - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_direct=yes - hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' - hardcode_libdir_separator=: - hardcode_shlibpath_var=no - ;; +/* System header to define __stub macros and hopefully few prototypes, + which can conflict with char dlopen (); below. + Prefer to if __STDC__ is defined, since + exists even on freestanding compilers. */ - *nto* | *qnx*) - ;; +#ifdef __STDC__ +# include +#else +# include +#endif - openbsd*) - if test -f /usr/libexec/ld.so; then - hardcode_direct=yes - hardcode_shlibpath_var=no - hardcode_direct_absolute=yes - if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' - archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols' - hardcode_libdir_flag_spec='${wl}-rpath,$libdir' - export_dynamic_flag_spec='${wl}-E' - else - case $host_os in - openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*) - archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' - hardcode_libdir_flag_spec='-R$libdir' - ;; - *) - archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' - hardcode_libdir_flag_spec='${wl}-rpath,$libdir' - ;; - esac - fi - else - ld_shlibs=no - fi - ;; +#undef dlopen - os2*) - hardcode_libdir_flag_spec='-L$libdir' - hardcode_minus_L=yes - allow_undefined_flag=unsupported - archive_cmds='$ECHO "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~$ECHO DATA >> $output_objdir/$libname.def~$ECHO " SINGLE NONSHARED" >> $output_objdir/$libname.def~$ECHO EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def' - old_archive_from_new_cmds='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def' - ;; +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char dlopen (); +/* The GNU C library defines this for functions which it implements + to always fail with ENOSYS. Some functions are actually named + something starting with __ and the normal name is an alias. */ +#if defined __stub_dlopen || defined __stub___dlopen +choke me +#endif - osf3*) - if test "$GCC" = yes; then - allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*' - archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' - else - allow_undefined_flag=' -expect_unresolved \*' - archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib' - fi - archive_cmds_need_lc='no' - hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' - hardcode_libdir_separator=: - ;; +int +main () +{ +return dlopen (); + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext 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>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_exeext && { + test "$cross_compiling" = yes || + $as_test_x conftest$ac_exeext + }; then + ac_cv_func_dlopen=yes +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 - osf4* | osf5*) # as osf3* with the addition of -msym flag - if test "$GCC" = yes; then - allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*' - archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' - hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' - else - allow_undefined_flag=' -expect_unresolved \*' - archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib' - archive_expsym_cmds='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; printf "%s\\n" "-hidden">> $lib.exp~ - $CC -shared${allow_undefined_flag} ${wl}-input ${wl}$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib~$RM $lib.exp' + ac_cv_func_dlopen=no +fi - # Both c and cxx compiler support -rpath directly - hardcode_libdir_flag_spec='-rpath $libdir' - fi - archive_cmds_need_lc='no' - hardcode_libdir_separator=: - ;; +rm -rf conftest.dSYM +rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ + conftest$ac_exeext conftest.$ac_ext +fi +{ $as_echo "$as_me:$LINENO: result: $ac_cv_func_dlopen" >&5 +$as_echo "$ac_cv_func_dlopen" >&6; } +if test "x$ac_cv_func_dlopen" = x""yes; then + lt_cv_dlopen="dlopen" +else + { $as_echo "$as_me:$LINENO: checking for dlopen in -ldl" >&5 +$as_echo_n "checking for dlopen in -ldl... " >&6; } +if test "${ac_cv_lib_dl_dlopen+set}" = set; then + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-ldl $LIBS" +cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ - solaris*) - no_undefined_flag=' -z defs' - if test "$GCC" = yes; then - wlarc='${wl}' - archive_cmds='$CC -shared ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $CC -shared ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' - else - case `$CC -V 2>&1` in - *"Compilers 5.0"*) - wlarc='' - archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' - archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp' - ;; - *) - wlarc='${wl}' - archive_cmds='$CC -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $compiler_flags' - archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $CC -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' - ;; - esac - fi - hardcode_libdir_flag_spec='-R$libdir' - hardcode_shlibpath_var=no - case $host_os in - solaris2.[0-5] | solaris2.[0-5].*) ;; - *) - # The compiler driver will combine and reorder linker options, - # but understands `-z linker_flag'. GCC discards it without `$wl', - # but is careful enough not to reorder. - # Supported since Solaris 2.6 (maybe 2.5.1?) - if test "$GCC" = yes; then - whole_archive_flag_spec='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' - else - whole_archive_flag_spec='-z allextract$convenience -z defaultextract' - fi - ;; - esac - link_all_deplibs=yes - ;; +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char dlopen (); +int +main () +{ +return dlopen (); + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext 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>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_exeext && { + test "$cross_compiling" = yes || + $as_test_x conftest$ac_exeext + }; then + ac_cv_lib_dl_dlopen=yes +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 - sunos4*) - if test "x$host_vendor" = xsequent; then - # Use $CC to link under sequent, because it throws in some extra .o - # files that make .init and .fini sections work. - archive_cmds='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags' - else - archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' - fi - hardcode_libdir_flag_spec='-L$libdir' - hardcode_direct=yes - hardcode_minus_L=yes - hardcode_shlibpath_var=no - ;; + ac_cv_lib_dl_dlopen=no +fi - sysv4) - case $host_vendor in - sni) - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_direct=yes # is this really true??? - ;; - siemens) - ## LD is ld it makes a PLAMLIB - ## CC just makes a GrossModule. - archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags' - reload_cmds='$CC -r -o $output$reload_objs' - hardcode_direct=no - ;; - motorola) - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_direct=no #Motorola manual says yes, but my tests say they lie - ;; - esac - runpath_var='LD_RUN_PATH' - hardcode_shlibpath_var=no - ;; - - sysv4.3*) - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_shlibpath_var=no - export_dynamic_flag_spec='-Bexport' - ;; - - sysv4*MP*) - if test -d /usr/nec; then - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_shlibpath_var=no - runpath_var=LD_RUN_PATH - hardcode_runpath_var=yes - ld_shlibs=yes - fi - ;; - - sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*) - no_undefined_flag='${wl}-z,text' - archive_cmds_need_lc=no - hardcode_shlibpath_var=no - runpath_var='LD_RUN_PATH' - - if test "$GCC" = yes; then - archive_cmds='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - else - archive_cmds='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - fi - ;; +rm -rf conftest.dSYM +rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_dl_dlopen" >&5 +$as_echo "$ac_cv_lib_dl_dlopen" >&6; } +if test "x$ac_cv_lib_dl_dlopen" = x""yes; then + lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl" +else + { $as_echo "$as_me:$LINENO: checking for dlopen in -lsvld" >&5 +$as_echo_n "checking for dlopen in -lsvld... " >&6; } +if test "${ac_cv_lib_svld_dlopen+set}" = set; then + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lsvld $LIBS" +cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ - sysv5* | sco3.2v5* | sco5v6*) - # Note: We can NOT use -z defs as we might desire, because we do not - # link with -lc, and that would cause any symbols used from libc to - # always be unresolved, which means just about no library would - # ever link correctly. If we're not using GNU ld we use -z text - # though, which does catch some bad symbols but isn't as heavy-handed - # as -z defs. - no_undefined_flag='${wl}-z,text' - allow_undefined_flag='${wl}-z,nodefs' - archive_cmds_need_lc=no - hardcode_shlibpath_var=no - hardcode_libdir_flag_spec='${wl}-R,$libdir' - hardcode_libdir_separator=':' - link_all_deplibs=yes - export_dynamic_flag_spec='${wl}-Bexport' - runpath_var='LD_RUN_PATH' +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char dlopen (); +int +main () +{ +return dlopen (); + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext 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>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_exeext && { + test "$cross_compiling" = yes || + $as_test_x conftest$ac_exeext + }; then + ac_cv_lib_svld_dlopen=yes +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 - if test "$GCC" = yes; then - archive_cmds='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - else - archive_cmds='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - fi - ;; + ac_cv_lib_svld_dlopen=no +fi - uts4*) - archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - hardcode_libdir_flag_spec='-L$libdir' - hardcode_shlibpath_var=no - ;; +rm -rf conftest.dSYM +rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_svld_dlopen" >&5 +$as_echo "$ac_cv_lib_svld_dlopen" >&6; } +if test "x$ac_cv_lib_svld_dlopen" = x""yes; then + lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld" +else + { $as_echo "$as_me:$LINENO: checking for dld_link in -ldld" >&5 +$as_echo_n "checking for dld_link in -ldld... " >&6; } +if test "${ac_cv_lib_dld_dld_link+set}" = set; then + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-ldld $LIBS" +cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ - *) - ld_shlibs=no - ;; - esac +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char dld_link (); +int +main () +{ +return dld_link (); + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext 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>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_exeext && { + test "$cross_compiling" = yes || + $as_test_x conftest$ac_exeext + }; then + ac_cv_lib_dld_dld_link=yes +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 - if test x$host_vendor = xsni; then - case $host in - sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) - export_dynamic_flag_spec='${wl}-Blargedynsym' - ;; - esac - fi - fi + ac_cv_lib_dld_dld_link=no +fi -{ $as_echo "$as_me:$LINENO: result: $ld_shlibs" >&5 -$as_echo "$ld_shlibs" >&6; } -test "$ld_shlibs" = no && can_build_shared=no +rm -rf conftest.dSYM +rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_dld_dld_link" >&5 +$as_echo "$ac_cv_lib_dld_dld_link" >&6; } +if test "x$ac_cv_lib_dld_dld_link" = x""yes; then + lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld" +fi -with_gnu_ld=$with_gnu_ld +fi +fi +fi +fi +fi + ;; + esac + if test "x$lt_cv_dlopen" != xno; then + enable_dlopen=yes + else + enable_dlopen=no + fi + case $lt_cv_dlopen in + dlopen) + save_CPPFLAGS="$CPPFLAGS" + test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" + save_LDFLAGS="$LDFLAGS" + wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" + save_LIBS="$LIBS" + LIBS="$lt_cv_dlopen_libs $LIBS" -# -# Do we need to explicitly link libc? -# -case "x$archive_cmds_need_lc" in -x|xyes) - # Assume -lc should be added - archive_cmds_need_lc=yes + { $as_echo "$as_me:$LINENO: checking whether a program can dlopen itself" >&5 +$as_echo_n "checking whether a program can dlopen itself... " >&6; } +if test "${lt_cv_dlopen_self+set}" = set; then + $as_echo_n "(cached) " >&6 +else + if test "$cross_compiling" = yes; then : + lt_cv_dlopen_self=cross +else + lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 + lt_status=$lt_dlunknown + cat > conftest.$ac_ext <&5 -$as_echo_n "checking whether -lc should be explicitly linked in... " >&6; } - $RM conftest* - echo "$lt_simple_compile_test_code" > conftest.$ac_ext +#if HAVE_DLFCN_H +#include +#endif - if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } 2>conftest.err; then - soname=conftest - lib=conftest - libobjs=conftest.$ac_objext - deplibs= - wl=$lt_prog_compiler_wl - pic_flag=$lt_prog_compiler_pic - compiler_flags=-v - linker_flags=-v - verstring= - output_objdir=. - libname=conftest - lt_save_allow_undefined_flag=$allow_undefined_flag - allow_undefined_flag= - if { (eval echo "$as_me:$LINENO: \"$archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\"") >&5 - (eval $archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5 +#include + +#ifdef RTLD_GLOBAL +# define LT_DLGLOBAL RTLD_GLOBAL +#else +# ifdef DL_GLOBAL +# define LT_DLGLOBAL DL_GLOBAL +# else +# define LT_DLGLOBAL 0 +# endif +#endif + +/* We may have to define LT_DLLAZY_OR_NOW in the command line if we + find out it does not work in some platform. */ +#ifndef LT_DLLAZY_OR_NOW +# ifdef RTLD_LAZY +# define LT_DLLAZY_OR_NOW RTLD_LAZY +# else +# ifdef DL_LAZY +# define LT_DLLAZY_OR_NOW DL_LAZY +# else +# ifdef RTLD_NOW +# define LT_DLLAZY_OR_NOW RTLD_NOW +# else +# ifdef DL_NOW +# define LT_DLLAZY_OR_NOW DL_NOW +# else +# define LT_DLLAZY_OR_NOW 0 +# endif +# endif +# endif +# endif +#endif + +#ifdef __cplusplus +extern "C" void exit (int); +#endif + +void fnord() { int i=42;} +int main () +{ + void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); + int status = $lt_dlunknown; + + if (self) + { + if (dlsym (self,"fnord")) status = $lt_dlno_uscore; + else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; + /* dlclose (self); */ + } + else + puts (dlerror ()); + + exit (status); +} +EOF + if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 + (eval $ac_link) 2>&5 ac_status=$? $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } - then - archive_cmds_need_lc=no - else - archive_cmds_need_lc=yes - fi - allow_undefined_flag=$lt_save_allow_undefined_flag - else - cat conftest.err 1>&5 - fi - $RM conftest* - { $as_echo "$as_me:$LINENO: result: $archive_cmds_need_lc" >&5 -$as_echo "$archive_cmds_need_lc" >&6; } - ;; + (exit $ac_status); } && test -s conftest${ac_exeext} 2>/dev/null; then + (./conftest; exit; ) >&5 2>/dev/null + lt_status=$? + case x$lt_status in + x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;; + x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;; + x$lt_dlunknown|x*) lt_cv_dlopen_self=no ;; esac + else : + # compilation failed + lt_cv_dlopen_self=no fi - ;; -esac +fi +rm -fr conftest* +fi +{ $as_echo "$as_me:$LINENO: result: $lt_cv_dlopen_self" >&5 +$as_echo "$lt_cv_dlopen_self" >&6; } + if test "x$lt_cv_dlopen_self" = xyes; then + wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\" + { $as_echo "$as_me:$LINENO: checking whether a statically linked program can dlopen itself" >&5 +$as_echo_n "checking whether a statically linked program can dlopen itself... " >&6; } +if test "${lt_cv_dlopen_self_static+set}" = set; then + $as_echo_n "(cached) " >&6 +else + if test "$cross_compiling" = yes; then : + lt_cv_dlopen_self_static=cross +else + lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 + lt_status=$lt_dlunknown + cat > conftest.$ac_ext < +#endif +#include +#ifdef RTLD_GLOBAL +# define LT_DLGLOBAL RTLD_GLOBAL +#else +# ifdef DL_GLOBAL +# define LT_DLGLOBAL DL_GLOBAL +# else +# define LT_DLGLOBAL 0 +# endif +#endif +/* We may have to define LT_DLLAZY_OR_NOW in the command line if we + find out it does not work in some platform. */ +#ifndef LT_DLLAZY_OR_NOW +# ifdef RTLD_LAZY +# define LT_DLLAZY_OR_NOW RTLD_LAZY +# else +# ifdef DL_LAZY +# define LT_DLLAZY_OR_NOW DL_LAZY +# else +# ifdef RTLD_NOW +# define LT_DLLAZY_OR_NOW RTLD_NOW +# else +# ifdef DL_NOW +# define LT_DLLAZY_OR_NOW DL_NOW +# else +# define LT_DLLAZY_OR_NOW 0 +# endif +# endif +# endif +# endif +#endif +#ifdef __cplusplus +extern "C" void exit (int); +#endif +void fnord() { int i=42;} +int main () +{ + void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); + int status = $lt_dlunknown; + if (self) + { + if (dlsym (self,"fnord")) status = $lt_dlno_uscore; + else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; + /* dlclose (self); */ + } + else + puts (dlerror ()); + exit (status); +} +EOF + if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 + (eval $ac_link) 2>&5 + ac_status=$? + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && test -s conftest${ac_exeext} 2>/dev/null; then + (./conftest; exit; ) >&5 2>/dev/null + lt_status=$? + case x$lt_status in + x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;; + x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;; + x$lt_dlunknown|x*) lt_cv_dlopen_self_static=no ;; + esac + else : + # compilation failed + lt_cv_dlopen_self_static=no + fi +fi +rm -fr conftest* +fi +{ $as_echo "$as_me:$LINENO: result: $lt_cv_dlopen_self_static" >&5 +$as_echo "$lt_cv_dlopen_self_static" >&6; } + fi + CPPFLAGS="$save_CPPFLAGS" + LDFLAGS="$save_LDFLAGS" + LIBS="$save_LIBS" + ;; + esac + case $lt_cv_dlopen_self in + yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; + *) enable_dlopen_self=unknown ;; + esac + case $lt_cv_dlopen_self_static in + yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;; + *) enable_dlopen_self_static=unknown ;; + esac +fi +# Report which library types will actually be built +{ $as_echo "$as_me:$LINENO: checking if libtool supports shared libraries" >&5 +$as_echo_n "checking if libtool supports shared libraries... " >&6; } +{ $as_echo "$as_me:$LINENO: result: $can_build_shared" >&5 +$as_echo "$can_build_shared" >&6; } +{ $as_echo "$as_me:$LINENO: checking whether to build shared libraries" >&5 +$as_echo_n "checking whether to build shared libraries... " >&6; } +test "$can_build_shared" = "no" && enable_shared=no +# On AIX, shared libraries and static libraries use the same namespace, and +# are all built from PIC. +case $host_os in +aix3*) + test "$enable_shared" = yes && enable_static=no + if test -n "$RANLIB"; then + archive_cmds="$archive_cmds~\$RANLIB \$lib" + postinstall_cmds='$RANLIB $lib' + fi + ;; +aix[4-9]*) + if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then + test "$enable_shared" = yes && enable_static=no + fi + ;; +esac +{ $as_echo "$as_me:$LINENO: result: $enable_shared" >&5 +$as_echo "$enable_shared" >&6; } +{ $as_echo "$as_me:$LINENO: checking whether to build static libraries" >&5 +$as_echo_n "checking whether to build static libraries... " >&6; } +# Make sure either enable_shared or enable_static is yes. +test "$enable_shared" = yes || enable_static=yes +{ $as_echo "$as_me:$LINENO: result: $enable_static" >&5 +$as_echo "$enable_static" >&6; } +# The else clause should only fire when bootstrapping the +# libtool distribution, otherwise you forgot to ship ltmain.sh +# with your package, and you will get complaints that there are +# no rules to generate ltmain.sh. +if test -f "$ltmain"; then + # See if we are running on zsh, and set the options which allow our commands through + # without removal of \ escapes. + if test -n "${ZSH_VERSION+set}" ; then + setopt NO_GLOB_SUBST + fi + # Now quote all the things that may contain metacharacters while being + # careful not to overquote the AC_SUBSTed values. We take copies of the + # variables and quote the copies for generation of the libtool script. + for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC LTCFLAGS NM \ + SED SHELL STRIP \ + libname_spec library_names_spec soname_spec extract_expsyms_cmds \ + old_striplib striplib file_magic_cmd finish_cmds finish_eval \ + deplibs_check_method reload_flag reload_cmds need_locks \ + lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \ + lt_cv_sys_global_symbol_to_c_name_address \ + sys_lib_search_path_spec sys_lib_dlsearch_path_spec \ + old_postinstall_cmds old_postuninstall_cmds \ + compiler \ + CC \ + LD \ + lt_prog_compiler_wl \ + lt_prog_compiler_pic \ + lt_prog_compiler_static \ + lt_prog_compiler_no_builtin_flag \ + export_dynamic_flag_spec \ + thread_safe_flag_spec \ + whole_archive_flag_spec \ + enable_shared_with_static_runtimes \ + old_archive_cmds \ + old_archive_from_new_cmds \ + predep_objects \ + postdep_objects \ + predeps \ + postdeps \ + compiler_lib_search_path \ + compiler_lib_search_dirs \ + archive_cmds \ + archive_expsym_cmds \ + postinstall_cmds \ + postuninstall_cmds \ + old_archive_from_expsyms_cmds \ + allow_undefined_flag \ + no_undefined_flag \ + export_symbols_cmds \ + hardcode_libdir_flag_spec \ + hardcode_libdir_flag_spec_ld \ + hardcode_libdir_separator \ + hardcode_automatic \ + module_cmds \ + module_expsym_cmds \ + lt_cv_prog_compiler_c_o \ + fix_srcfile_path \ + exclude_expsyms \ + include_expsyms; do + + case $var in + old_archive_cmds | \ + old_archive_from_new_cmds | \ + archive_cmds | \ + archive_expsym_cmds | \ + module_cmds | \ + module_expsym_cmds | \ + old_archive_from_expsyms_cmds | \ + export_symbols_cmds | \ + extract_expsyms_cmds | reload_cmds | finish_cmds | \ + postinstall_cmds | postuninstall_cmds | \ + old_postinstall_cmds | old_postuninstall_cmds | \ + sys_lib_search_path_spec | sys_lib_dlsearch_path_spec) + # Double-quote double-evaled strings. + eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\"" + ;; + *) + eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\"" + ;; + esac + done + case $lt_echo in + *'\$0 --fallback-echo"') + lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\$0 --fallback-echo"$/$0 --fallback-echo"/'` + ;; + esac +cfgfile="${ofile}T" + trap "$rm \"$cfgfile\"; exit 1" 1 2 15 + $rm -f "$cfgfile" + { $as_echo "$as_me:$LINENO: creating $ofile" >&5 +$as_echo "$as_me: creating $ofile" >&6;} + cat <<__EOF__ >> "$cfgfile" +#! $SHELL +# `$echo "$cfgfile" | sed 's%^.*/%%'` - Provide generalized library-building support services. +# Generated automatically by $PROGRAM (GNU $PACKAGE $VERSION$TIMESTAMP) +# NOTE: Changes made to this file will be lost: look at ltmain.sh. +# +# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 +# Free Software Foundation, Inc. +# +# This file is part of GNU Libtool: +# Originally by Gordon Matzigkeit , 1996 +# +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2 of the License, or +# (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, but +# WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 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. +# +# As a special exception to the GNU General Public License, if you +# distribute this file as part of a program that contains a +# configuration script generated by Autoconf, you may include it under +# the same distribution terms that you use for the rest of that program. + +# A sed program that does not truncate output. +SED=$lt_SED + +# Sed that helps us avoid accidentally triggering echo(1) options like -n. +Xsed="$SED -e 1s/^X//" + +# The HP-UX ksh and POSIX shell print the target directory to stdout +# if CDPATH is set. +(unset CDPATH) >/dev/null 2>&1 && unset CDPATH +# The names of the tagged configurations supported by this script. +available_tags= +# ### BEGIN LIBTOOL CONFIG +# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: +# Shell to use when invoking shell scripts. +SHELL=$lt_SHELL +# Whether or not to build shared libraries. +build_libtool_libs=$enable_shared +# Whether or not to build static libraries. +build_old_libs=$enable_static +# Whether or not to add -lc for building shared libraries. +build_libtool_need_lc=$archive_cmds_need_lc +# Whether or not to disallow shared libs when runtime libs are static +allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes +# Whether or not to optimize for fast installation. +fast_install=$enable_fast_install +# The host system. +host_alias=$host_alias +host=$host +host_os=$host_os +# The build system. +build_alias=$build_alias +build=$build +build_os=$build_os +# An echo program that does not interpret backslashes. +echo=$lt_echo +# The archiver. +AR=$lt_AR +AR_FLAGS=$lt_AR_FLAGS +# A C compiler. +LTCC=$lt_LTCC +# LTCC compiler flags. +LTCFLAGS=$lt_LTCFLAGS +# A language-specific compiler. +CC=$lt_compiler +# Is the compiler the GNU C compiler? +with_gcc=$GCC +# An ERE matcher. +EGREP=$lt_EGREP +# The linker used to build libraries. +LD=$lt_LD +# Whether we need hard or soft links. +LN_S=$lt_LN_S +# A BSD-compatible nm program. +NM=$lt_NM +# A symbol stripping program +STRIP=$lt_STRIP +# Used to examine libraries when file_magic_cmd begins "file" +MAGIC_CMD=$MAGIC_CMD +# Used on cygwin: DLL creation program. +DLLTOOL="$DLLTOOL" +# Used on cygwin: object dumper. +OBJDUMP="$OBJDUMP" +# Used on cygwin: assembler. +AS="$AS" +# The name of the directory that contains temporary libtool files. +objdir=$objdir +# How to create reloadable object files. +reload_flag=$lt_reload_flag +reload_cmds=$lt_reload_cmds +# How to pass a linker flag through the compiler. +wl=$lt_lt_prog_compiler_wl +# Object file suffix (normally "o"). +objext="$ac_objext" +# Old archive suffix (normally "a"). +libext="$libext" +# Shared library suffix (normally ".so"). +shrext_cmds='$shrext_cmds' +# Executable file suffix (normally ""). +exeext="$exeext" +# Additional compiler flags for building library objects. +pic_flag=$lt_lt_prog_compiler_pic +pic_mode=$pic_mode +# What is the maximum length of a command? +max_cmd_len=$lt_cv_sys_max_cmd_len +# Does compiler simultaneously support -c and -o options? +compiler_c_o=$lt_lt_cv_prog_compiler_c_o +# Must we lock files when doing compilation? +need_locks=$lt_need_locks +# Do we need the lib prefix for modules? +need_lib_prefix=$need_lib_prefix +# Do we need a version for libraries? +need_version=$need_version +# Whether dlopen is supported. +dlopen_support=$enable_dlopen +# Whether dlopen of programs is supported. +dlopen_self=$enable_dlopen_self +# Whether dlopen of statically linked programs is supported. +dlopen_self_static=$enable_dlopen_self_static +# Compiler flag to prevent dynamic linking. +link_static_flag=$lt_lt_prog_compiler_static +# Compiler flag to turn off builtin functions. +no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag +# Compiler flag to allow reflexive dlopens. +export_dynamic_flag_spec=$lt_export_dynamic_flag_spec +# Compiler flag to generate shared objects directly from archives. +whole_archive_flag_spec=$lt_whole_archive_flag_spec +# Compiler flag to generate thread-safe objects. +thread_safe_flag_spec=$lt_thread_safe_flag_spec +# Library versioning type. +version_type=$version_type +# Format of library name prefix. +libname_spec=$lt_libname_spec +# List of archive names. First name is the real one, the rest are links. +# The last name is the one that the linker finds with -lNAME. +library_names_spec=$lt_library_names_spec +# The coded name of the library, if different from the real name. +soname_spec=$lt_soname_spec +# Commands used to build and install an old-style archive. +RANLIB=$lt_RANLIB +old_archive_cmds=$lt_old_archive_cmds +old_postinstall_cmds=$lt_old_postinstall_cmds +old_postuninstall_cmds=$lt_old_postuninstall_cmds +# Create an old-style archive from a shared archive. +old_archive_from_new_cmds=$lt_old_archive_from_new_cmds +# Create a temporary old-style archive to link instead of a shared archive. +old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds +# Commands used to build and install a shared archive. +archive_cmds=$lt_archive_cmds +archive_expsym_cmds=$lt_archive_expsym_cmds +postinstall_cmds=$lt_postinstall_cmds +postuninstall_cmds=$lt_postuninstall_cmds +# Commands used to build a loadable module (assumed same as above if empty) +module_cmds=$lt_module_cmds +module_expsym_cmds=$lt_module_expsym_cmds +# Commands to strip libraries. +old_striplib=$lt_old_striplib +striplib=$lt_striplib +# Dependencies to place before the objects being linked to create a +# shared library. +predep_objects=$lt_predep_objects +# Dependencies to place after the objects being linked to create a +# shared library. +postdep_objects=$lt_postdep_objects +# Dependencies to place before the objects being linked to create a +# shared library. +predeps=$lt_predeps +# Dependencies to place after the objects being linked to create a +# shared library. +postdeps=$lt_postdeps +# The directories searched by this compiler when creating a shared +# library +compiler_lib_search_dirs=$lt_compiler_lib_search_dirs +# The library search path used internally by the compiler when linking +# a shared library. +compiler_lib_search_path=$lt_compiler_lib_search_path +# Method to check whether dependent libraries are shared objects. +deplibs_check_method=$lt_deplibs_check_method +# Command to use when deplibs_check_method == file_magic. +file_magic_cmd=$lt_file_magic_cmd +# Flag that allows shared libraries with undefined symbols to be built. +allow_undefined_flag=$lt_allow_undefined_flag +# Flag that forces no undefined symbols. +no_undefined_flag=$lt_no_undefined_flag +# Commands used to finish a libtool library installation in a directory. +finish_cmds=$lt_finish_cmds +# Same as above, but a single script fragment to be evaled but not shown. +finish_eval=$lt_finish_eval +# Take the output of nm and produce a listing of raw symbols and C names. +global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe +# Transform the output of nm in a proper C declaration +global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl +# Transform the output of nm in a C name address pair +global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address +# This is the shared library runtime path variable. +runpath_var=$runpath_var +# This is the shared library path variable. +shlibpath_var=$shlibpath_var +# Is shlibpath searched before the hard-coded library search path? +shlibpath_overrides_runpath=$shlibpath_overrides_runpath +# How to hardcode a shared library path into an executable. +hardcode_action=$hardcode_action +# Whether we should hardcode library paths into libraries. +hardcode_into_libs=$hardcode_into_libs +# Flag to hardcode \$libdir into a binary during linking. +# This must work even if \$libdir does not exist. +hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec +# If ld is used when linking, flag to hardcode \$libdir into +# a binary during linking. This must work even if \$libdir does +# not exist. +hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld +# Whether we need a single -rpath flag with a separated argument. +hardcode_libdir_separator=$lt_hardcode_libdir_separator +# Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the +# resulting binary. +hardcode_direct=$hardcode_direct +# Set to yes if using the -LDIR flag during linking hardcodes DIR into the +# resulting binary. +hardcode_minus_L=$hardcode_minus_L +# Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into +# the resulting binary. +hardcode_shlibpath_var=$hardcode_shlibpath_var +# Set to yes if building a shared library automatically hardcodes DIR into the library +# and all subsequent libraries and executables linked against it. +hardcode_automatic=$hardcode_automatic +# Variables whose values should be saved in libtool wrapper scripts and +# restored at relink time. +variables_saved_for_relink="$variables_saved_for_relink" +# Whether libtool must link a program against all its dependency libraries. +link_all_deplibs=$link_all_deplibs +# Compile-time system search path for libraries +sys_lib_search_path_spec=$lt_sys_lib_search_path_spec +# Run-time system search path for libraries +sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec +# Fix the shell variable \$srcfile for the compiler. +fix_srcfile_path=$lt_fix_srcfile_path +# Set to yes if exported symbols are required. +always_export_symbols=$always_export_symbols +# The commands to list exported symbols. +export_symbols_cmds=$lt_export_symbols_cmds +# The commands to extract the exported symbol list from a shared archive. +extract_expsyms_cmds=$lt_extract_expsyms_cmds +# Symbols that should not be listed in the preloaded symbols. +exclude_expsyms=$lt_exclude_expsyms +# Symbols that must always be exported. +include_expsyms=$lt_include_expsyms +# ### END LIBTOOL CONFIG +__EOF__ + case $host_os in + aix3*) + cat <<\EOF >> "$cfgfile" +# AIX sometimes has problems with the GCC collect2 program. For some +# reason, if we set the COLLECT_NAMES environment variable, the problems +# vanish in a puff of smoke. +if test "X${COLLECT_NAMES+set}" != Xset; then + COLLECT_NAMES= + export COLLECT_NAMES +fi +EOF + ;; + esac + # We use sed instead of cat because bash on DJGPP gets confused if + # if finds mixed CR/LF and LF-only lines. Since sed operates in + # text mode, it properly converts lines to CR/LF. This bash problem + # is reportedly fixed, but why not run on old versions too? + sed '$q' "$ltmain" >> "$cfgfile" || (rm -f "$cfgfile"; exit 1) + mv -f "$cfgfile" "$ofile" || \ + (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") + chmod +x "$ofile" +else + # If there is no Makefile yet, we rely on a make rule to execute + # `config.status --recheck' to rerun these tests and create the + # libtool script then. + ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'` + if test -f "$ltmain_in"; then + test -f Makefile && make "$ltmain" + fi +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 +CC="$lt_save_CC" +# Check whether --with-tags was given. +if test "${with_tags+set}" = set; then + withval=$with_tags; tagnames="$withval" +fi +if test -f "$ltmain" && test -n "$tagnames"; then + if test ! -f "${ofile}"; then + { $as_echo "$as_me:$LINENO: WARNING: output file \`$ofile' does not exist" >&5 +$as_echo "$as_me: WARNING: output file \`$ofile' does not exist" >&2;} + fi + if test -z "$LTCC"; then + eval "`$SHELL ${ofile} --config | grep '^LTCC='`" + if test -z "$LTCC"; then + { $as_echo "$as_me:$LINENO: WARNING: output file \`$ofile' does not look like a libtool script" >&5 +$as_echo "$as_me: WARNING: output file \`$ofile' does not look like a libtool script" >&2;} + else + { $as_echo "$as_me:$LINENO: WARNING: using \`LTCC=$LTCC', extracted from \`$ofile'" >&5 +$as_echo "$as_me: WARNING: using \`LTCC=$LTCC', extracted from \`$ofile'" >&2;} + fi + fi + if test -z "$LTCFLAGS"; then + eval "`$SHELL ${ofile} --config | grep '^LTCFLAGS='`" + fi + # Extract list of available tagged configurations in $ofile. + # Note that this assumes the entire list is on one line. + available_tags=`grep "^available_tags=" "${ofile}" | $SED -e 's/available_tags=\(.*$\)/\1/' -e 's/\"//g'` + lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," + for tagname in $tagnames; do + IFS="$lt_save_ifs" + # Check whether tagname contains only valid characters + case `$echo "X$tagname" | $Xsed -e 's:[-_ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz1234567890,/]::g'` in + "") ;; + *) { { $as_echo "$as_me:$LINENO: error: invalid tag name: $tagname" >&5 +$as_echo "$as_me: error: invalid tag name: $tagname" >&2;} + { (exit 1); exit 1; }; } + ;; + esac + if grep "^# ### BEGIN LIBTOOL TAG CONFIG: $tagname$" < "${ofile}" > /dev/null + then + { { $as_echo "$as_me:$LINENO: error: tag name \"$tagname\" already exists" >&5 +$as_echo "$as_me: error: tag name \"$tagname\" already exists" >&2;} + { (exit 1); exit 1; }; } + fi + # Update the list of available tags. + if test -n "$tagname"; then + echo appending configuration tag \"$tagname\" to $ofile + + case $tagname in + CXX) + if test -n "$CXX" && ( test "X$CXX" != "Xno" && + ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) || + (test "X$CXX" != "Xg++"))) ; then + ac_ext=cpp +ac_cpp='$CXXCPP $CPPFLAGS' +ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_cxx_compiler_gnu + + + + +archive_cmds_need_lc_CXX=no +allow_undefined_flag_CXX= +always_export_symbols_CXX=no +archive_expsym_cmds_CXX= +export_dynamic_flag_spec_CXX= +hardcode_direct_CXX=no +hardcode_libdir_flag_spec_CXX= +hardcode_libdir_flag_spec_ld_CXX= +hardcode_libdir_separator_CXX= +hardcode_minus_L_CXX=no +hardcode_shlibpath_var_CXX=unsupported +hardcode_automatic_CXX=no +module_cmds_CXX= +module_expsym_cmds_CXX= +link_all_deplibs_CXX=unknown +old_archive_cmds_CXX=$old_archive_cmds +no_undefined_flag_CXX= +whole_archive_flag_spec_CXX= +enable_shared_with_static_runtimes_CXX=no + +# Dependencies to place before and after the object being linked: +predep_objects_CXX= +postdep_objects_CXX= +predeps_CXX= +postdeps_CXX= +compiler_lib_search_path_CXX= +compiler_lib_search_dirs_CXX= + +# Source file extension for C++ test sources. +ac_ext=cpp + +# Object file extension for compiled C++ test sources. +objext=o +objext_CXX=$objext +# Code to be used in simple compile tests +lt_simple_compile_test_code="int some_variable = 0;" +# Code to be used in simple link tests +lt_simple_link_test_code='int main(int, char *[]) { return(0); }' +# ltmain only uses $CC for tagged configurations so make sure $CC is set. +# If no C compiler was specified, use CC. +LTCC=${LTCC-"$CC"} +# If no C compiler flags were specified, use CFLAGS. +LTCFLAGS=${LTCFLAGS-"$CFLAGS"} +# Allow CC to be a program name with arguments. +compiler=$CC +# save warnings/boilerplate of simple test code +ac_outfile=conftest.$ac_objext +echo "$lt_simple_compile_test_code" >conftest.$ac_ext +eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err +_lt_compiler_boilerplate=`cat conftest.err` +$rm conftest* +ac_outfile=conftest.$ac_objext +echo "$lt_simple_link_test_code" >conftest.$ac_ext +eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err +_lt_linker_boilerplate=`cat conftest.err` +$rm -r conftest* +# Allow CC to be a program name with arguments. +lt_save_CC=$CC +lt_save_LD=$LD +lt_save_GCC=$GCC +GCC=$GXX +lt_save_with_gnu_ld=$with_gnu_ld +lt_save_path_LD=$lt_cv_path_LD +if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then + lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx +else + $as_unset lt_cv_prog_gnu_ld +fi +if test -n "${lt_cv_path_LDCXX+set}"; then + lt_cv_path_LD=$lt_cv_path_LDCXX +else + $as_unset lt_cv_path_LD +fi +test -z "${LDCXX+set}" || LD=$LDCXX +CC=${CXX-"c++"} +compiler=$CC +compiler_CXX=$CC +for cc_temp in $compiler""; do + case $cc_temp in + compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; + distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; + \-*) ;; + *) break;; + esac +done +cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` +# We don't want -fno-exception wen compiling C++ code, so set the +# no_builtin_flag separately +if test "$GXX" = yes; then + lt_prog_compiler_no_builtin_flag_CXX=' -fno-builtin' +else + lt_prog_compiler_no_builtin_flag_CXX= +fi +if test "$GXX" = yes; then + # Set up default GNU C++ configuration - { $as_echo "$as_me:$LINENO: checking dynamic linker characteristics" >&5 -$as_echo_n "checking dynamic linker characteristics... " >&6; } +# Check whether --with-gnu-ld was given. +if test "${with_gnu_ld+set}" = set; then + withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes +else + with_gnu_ld=no +fi +ac_prog=ld if test "$GCC" = yes; then - case $host_os in - darwin*) lt_awk_arg="/^libraries:/,/LR/" ;; - *) lt_awk_arg="/^libraries:/" ;; - esac - lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e "s,=/,/,g"` - if $ECHO "$lt_search_path_spec" | $GREP ';' >/dev/null ; then - # if the path contains ";" then we assume it to be the separator - # otherwise default to the standard path separator (i.e. ":") - it is - # assumed that no part of a normal pathname contains ";" but that should - # okay in the real world where ";" in dirpaths is itself problematic. - lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED -e 's/;/ /g'` - else - lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` - fi - # Ok, now we have the path, separated by spaces, we can step through it - # and add multilib dir if necessary. - lt_tmp_lt_search_path_spec= - lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null` - for lt_sys_path in $lt_search_path_spec; do - if test -d "$lt_sys_path/$lt_multi_os_dir"; then - lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir" - else - test -d "$lt_sys_path" && \ - lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path" + # Check if gcc -print-prog-name=ld gives a path. + { $as_echo "$as_me:$LINENO: checking for ld used by $CC" >&5 +$as_echo_n "checking for ld used by $CC... " >&6; } + case $host in + *-*-mingw*) + # gcc leaves a trailing carriage return which upsets mingw + ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; + *) + ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; + esac + case $ac_prog in + # Accept absolute paths. + [\\/]* | ?:[\\/]*) + re_direlt='/[^/][^/]*/\.\./' + # Canonicalize the pathname of ld + ac_prog=`echo $ac_prog| $SED 's%\\\\%/%g'` + while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do + ac_prog=`echo $ac_prog| $SED "s%$re_direlt%/%"` + done + test -z "$LD" && LD="$ac_prog" + ;; + "") + # If it fails, then pretend we aren't using GCC. + ac_prog=ld + ;; + *) + # If it is relative, then search for the first ld in PATH. + with_gnu_ld=unknown + ;; + esac +elif test "$with_gnu_ld" = yes; then + { $as_echo "$as_me:$LINENO: checking for GNU ld" >&5 +$as_echo_n "checking for GNU ld... " >&6; } +else + { $as_echo "$as_me:$LINENO: checking for non-GNU ld" >&5 +$as_echo_n "checking for non-GNU ld... " >&6; } +fi +if test "${lt_cv_path_LD+set}" = set; then + $as_echo_n "(cached) " >&6 +else + if test -z "$LD"; then + lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR + for ac_dir in $PATH; do + IFS="$lt_save_ifs" + test -z "$ac_dir" && ac_dir=. + if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then + lt_cv_path_LD="$ac_dir/$ac_prog" + # Check to see if the program is GNU ld. I'd rather use --version, + # but apparently some variants of GNU ld only accept -v. + # Break only if it was the GNU/non-GNU ld that we prefer. + case `"$lt_cv_path_LD" -v 2>&1 0; lt_i--) { - if ($lt_i != "" && $lt_i != ".") { - if ($lt_i == "..") { - lt_count++; - } else { - if (lt_count == 0) { - lt_foo="/" $lt_i lt_foo; - } else { - lt_count--; - } - } - } - } - if (lt_foo != "") { lt_freq[lt_foo]++; } - if (lt_freq[lt_foo] == 1) { print lt_foo; } -}'` - sys_lib_search_path_spec=`$ECHO $lt_search_path_spec` + IFS="$lt_save_ifs" else - sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" + lt_cv_path_LD="$LD" # Let the user override the test with a path. +fi fi -library_names_spec= -libname_spec='lib$name' -soname_spec= -shrext_cmds=".so" -postinstall_cmds= -postuninstall_cmds= -finish_cmds= -finish_eval= -shlibpath_var= -shlibpath_overrides_runpath=unknown -version_type=none -dynamic_linker="$host_os ld.so" -sys_lib_dlsearch_path_spec="/lib /usr/lib" -need_lib_prefix=unknown -hardcode_into_libs=no -# when you set need_version to no, make sure it does not cause -set_version -# flags to be left without arguments -need_version=unknown +LD="$lt_cv_path_LD" +if test -n "$LD"; then + { $as_echo "$as_me:$LINENO: result: $LD" >&5 +$as_echo "$LD" >&6; } +else + { $as_echo "$as_me:$LINENO: result: no" >&5 +$as_echo "no" >&6; } +fi +test -z "$LD" && { { $as_echo "$as_me:$LINENO: error: no acceptable ld found in \$PATH" >&5 +$as_echo "$as_me: error: no acceptable ld found in \$PATH" >&2;} + { (exit 1); exit 1; }; } +{ $as_echo "$as_me:$LINENO: checking if the linker ($LD) is GNU ld" >&5 +$as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; } +if test "${lt_cv_prog_gnu_ld+set}" = set; then + $as_echo_n "(cached) " >&6 +else + # I'd rather use --version here, but apparently some GNU lds only accept -v. +case `$LD -v 2>&1 &5 +$as_echo "$lt_cv_prog_gnu_ld" >&6; } +with_gnu_ld=$lt_cv_prog_gnu_ld -case $host_os in -aix3*) - version_type=linux - library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a' - shlibpath_var=LIBPATH - # AIX 3 has no versioning support, so we append a major version to the name. - soname_spec='${libname}${release}${shared_ext}$major' - ;; -aix[4-9]*) - version_type=linux - need_lib_prefix=no - need_version=no - hardcode_into_libs=yes - if test "$host_cpu" = ia64; then - # AIX 5 supports IA64 - library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - else - # With GCC up to 2.95.x, collect2 would create an import file - # for dependence libraries. The import file would start with - # the line `#! .'. This would cause the generated library to - # depend on `.', always an invalid library. This was fixed in - # development snapshots of GCC prior to 3.0. - case $host_os in - aix4 | aix4.[01] | aix4.[01].*) - if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' - echo ' yes ' - echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then - : - else - can_build_shared=no - fi - ;; - esac - # AIX (on Power*) has no versioning support, so currently we can not hardcode correct - # soname into executable. Probably we can add versioning support to - # collect2, so additional links can be useful in future. - if test "$aix_use_runtimelinking" = yes; then - # If using run time linking (on AIX 4.2 or later) use lib.so - # instead of lib.a to let people know that these are not - # typical AIX shared libraries. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + # Check if GNU C++ uses GNU ld as the underlying linker, since the + # archiving commands below assume that GNU ld is being used. + if test "$with_gnu_ld" = yes; then + archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + + hardcode_libdir_flag_spec_CXX='${wl}--rpath ${wl}$libdir' + export_dynamic_flag_spec_CXX='${wl}--export-dynamic' + + # If archive_cmds runs LD, not CC, wlarc should be empty + # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to + # investigate it a little bit more. (MM) + wlarc='${wl}' + + # ancient GNU ld didn't support --whole-archive et. al. + if eval "`$CC -print-prog-name=ld` --help 2>&1" | \ + grep 'no-whole-archive' > /dev/null; then + whole_archive_flag_spec_CXX="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' else - # We preserve .a as extension for shared libraries through AIX4.2 - # and later when we are not doing run time linking. - library_names_spec='${libname}${release}.a $libname.a' - soname_spec='${libname}${release}${shared_ext}$major' + whole_archive_flag_spec_CXX= fi - shlibpath_var=LIBPATH + else + with_gnu_ld=no + wlarc= + + # A generic and very simple default shared library creation + # command for GNU C++ for the case where it uses the native + # linker, instead of GNU ld. If possible, this setting should + # overridden to take advantage of the native linker features on + # the platform it is being used on. + archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' fi - ;; - -amigaos*) - case $host_cpu in - powerpc) - # Since July 2007 AmigaOS4 officially supports .so libraries. - # When compiling the executable, add -use-dynld -Lsobjs: to the compileline. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - ;; - m68k) - library_names_spec='$libname.ixlibrary $libname.a' - # Create ${libname}_ixlibrary.a entries in /sys/libs. - finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$ECHO "X$lib" | $Xsed -e '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' - ;; - esac - ;; -beos*) - library_names_spec='${libname}${shared_ext}' - dynamic_linker="$host_os ld.so" - shlibpath_var=LIBRARY_PATH - ;; + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"' -bsdi[45]*) - version_type=linux - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' - shlibpath_var=LD_LIBRARY_PATH - sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" - sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" - # the default ld.so.conf also contains /usr/contrib/lib and - # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow - # libtool to hard-code these into programs - ;; +else + GXX=no + with_gnu_ld=no + wlarc= +fi -cygwin* | mingw* | pw32* | cegcc*) - version_type=windows - shrext_cmds=".dll" - need_version=no - need_lib_prefix=no +# PORTME: fill in a description of your system's C++ link characteristics +{ $as_echo "$as_me:$LINENO: checking whether the $compiler linker ($LD) supports shared libraries" >&5 +$as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; } +ld_shlibs_CXX=yes +case $host_os in + aix3*) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + aix[4-9]*) + if test "$host_cpu" = ia64; then + # On IA64, the linker does run time linking by default, so we don't + # have to do anything special. + aix_use_runtimelinking=no + exp_sym_flag='-Bexport' + no_entry_flag="" + else + aix_use_runtimelinking=no + + # Test if we are trying to use run time linking or normal + # AIX style linking. If -brtl is somewhere in LDFLAGS, we + # need to do runtime linking. + case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*) + for ld_flag in $LDFLAGS; do + case $ld_flag in + *-brtl*) + aix_use_runtimelinking=yes + break + ;; + esac + done + ;; + esac - case $GCC,$host_os in - yes,cygwin* | yes,mingw* | yes,pw32* | yes,cegcc*) - library_names_spec='$libname.dll.a' - # DLL is installed to $(libdir)/../bin by postinstall_cmds - postinstall_cmds='base_file=`basename \${file}`~ - dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~ - dldir=$destdir/`dirname \$dlpath`~ - test -d \$dldir || mkdir -p \$dldir~ - $install_prog $dir/$dlname \$dldir/$dlname~ - chmod a+x \$dldir/$dlname~ - if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then - eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; - fi' - postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ - dlpath=$dir/\$dldll~ - $RM \$dlpath' - shlibpath_overrides_runpath=yes + exp_sym_flag='-bexport' + no_entry_flag='-bnoentry' + fi - case $host_os in - cygwin*) - # Cygwin DLLs use 'cyg' prefix rather than 'lib' - soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' - sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib" - ;; - mingw* | cegcc*) - # MinGW DLLs use traditional 'lib' prefix - soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' - sys_lib_search_path_spec=`$CC -print-search-dirs | $GREP "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"` - if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then - # It is most probably a Windows format PATH printed by - # mingw gcc, but we are running on Cygwin. Gcc prints its search - # path with ; separators, and with drive letters. We can handle the - # drive letters (cygwin fileutils understands them), so leave them, - # especially as we might pass files found there to a mingw objdump, - # which wouldn't understand a cygwinified path. Ahh. - sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` - else - sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` + # When large executables or shared objects are built, AIX ld can + # have problems creating the table of contents. If linking a library + # or program results in "error TOC overflow" add -mminimal-toc to + # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not + # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. + + archive_cmds_CXX='' + hardcode_direct_CXX=yes + hardcode_libdir_separator_CXX=':' + link_all_deplibs_CXX=yes + + if test "$GXX" = yes; then + case $host_os in aix4.[012]|aix4.[012].*) + # We only want to do this on AIX 4.2 and lower, the check + # below for broken collect2 doesn't work under 4.3+ + collect2name=`${CC} -print-prog-name=collect2` + if test -f "$collect2name" && \ + strings "$collect2name" | grep resolve_lib_name >/dev/null + then + # We have reworked collect2 + : + else + # We have old collect2 + hardcode_direct_CXX=unsupported + # It fails to find uninstalled libraries when the uninstalled + # path is not listed in the libpath. Setting hardcode_minus_L + # to unsupported forces relinking + hardcode_minus_L_CXX=yes + hardcode_libdir_flag_spec_CXX='-L$libdir' + hardcode_libdir_separator_CXX= + fi + ;; + esac + shared_flag='-shared' + if test "$aix_use_runtimelinking" = yes; then + shared_flag="$shared_flag "'${wl}-G' fi - ;; - pw32*) - # pw32 DLLs use 'pw' prefix rather than 'lib' - library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' - ;; - esac - ;; - - *) - library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib' - ;; - esac - dynamic_linker='Win32 ld.exe' - # FIXME: first we should search . and the directory the executable is in - shlibpath_var=PATH - ;; - -darwin* | rhapsody*) - dynamic_linker="$host_os dyld" - version_type=darwin - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext' - soname_spec='${libname}${release}${major}$shared_ext' - shlibpath_overrides_runpath=yes - shlibpath_var=DYLD_LIBRARY_PATH - shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' - - sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib" - sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' - ;; - -dgux*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - ;; - -freebsd1*) - dynamic_linker=no - ;; - -freebsd* | dragonfly*) - # DragonFly does not have aout. When/if they implement a new - # versioning mechanism, adjust this. - if test -x /usr/bin/objformat; then - objformat=`/usr/bin/objformat` - else - case $host_os in - freebsd[123]*) objformat=aout ;; - *) objformat=elf ;; - esac - fi - version_type=freebsd-$objformat - case $version_type in - freebsd-elf*) - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' - need_version=no - need_lib_prefix=no - ;; - freebsd-*) - library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' - need_version=yes - ;; - esac - shlibpath_var=LD_LIBRARY_PATH - case $host_os in - freebsd2*) - shlibpath_overrides_runpath=yes - ;; - freebsd3.[01]* | freebsdelf3.[01]*) - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - ;; - freebsd3.[2-9]* | freebsdelf3.[2-9]* | \ - freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1) - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - ;; - *) # from 4.6 on, and DragonFly - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - ;; - esac - ;; - -gnu*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - hardcode_into_libs=yes - ;; - -hpux9* | hpux10* | hpux11*) - # Give a soname corresponding to the major version so that dld.sl refuses to - # link against other versions. - version_type=sunos - need_lib_prefix=no - need_version=no - case $host_cpu in - ia64*) - shrext_cmds='.so' - hardcode_into_libs=yes - dynamic_linker="$host_os dld.so" - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - if test "X$HPUX_IA64_MODE" = X32; then - sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" else - sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" - fi - sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec - ;; - hppa*64*) - shrext_cmds='.sl' - hardcode_into_libs=yes - dynamic_linker="$host_os dld.sl" - shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH - shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" - sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec - ;; - *) - shrext_cmds='.sl' - dynamic_linker="$host_os dld.sl" - shlibpath_var=SHLIB_PATH - shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - ;; - esac - # HP-UX runs *really* slowly unless shared libraries are mode 555. - postinstall_cmds='chmod 555 $lib' - ;; - -interix[3-9]*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - ;; - -irix5* | irix6* | nonstopux*) - case $host_os in - nonstopux*) version_type=nonstopux ;; - *) - if test "$lt_cv_prog_gnu_ld" = yes; then - version_type=linux + # not using gcc + if test "$host_cpu" = ia64; then + # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release + # chokes on -Wl,-G. The following line is correct: + shared_flag='-G' + else + if test "$aix_use_runtimelinking" = yes; then + shared_flag='${wl}-G' else - version_type=irix - fi ;; - esac - need_lib_prefix=no - need_version=no - soname_spec='${libname}${release}${shared_ext}$major' - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}' - case $host_os in - irix5* | nonstopux*) - libsuff= shlibsuff= - ;; - *) - case $LD in # libtool.m4 will add one of these switches to LD - *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") - libsuff= shlibsuff= libmagic=32-bit;; - *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") - libsuff=32 shlibsuff=N32 libmagic=N32;; - *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") - libsuff=64 shlibsuff=64 libmagic=64-bit;; - *) libsuff= shlibsuff= libmagic=never-match;; - esac - ;; - esac - shlibpath_var=LD_LIBRARY${shlibsuff}_PATH - shlibpath_overrides_runpath=no - sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" - sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" - hardcode_into_libs=yes - ;; - -# No shared lib support for Linux oldld, aout, or coff. -linux*oldld* | linux*aout* | linux*coff*) - dynamic_linker=no - ;; + shared_flag='${wl}-bM:SRE' + fi + fi + fi -# This must be Linux ELF. -linux* | k*bsd*-gnu) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - # Some binutils ld are patched to set DT_RUNPATH - save_LDFLAGS=$LDFLAGS - save_libdir=$libdir - eval "libdir=/foo; wl=\"$lt_prog_compiler_wl\"; \ - LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec\"" - cat >conftest.$ac_ext <<_ACEOF + # It seems that -bexpall does not export symbols beginning with + # underscore (_), so it is better to generate a list of symbols to export. + always_export_symbols_CXX=yes + if test "$aix_use_runtimelinking" = yes; then + # Warning - without using the other runtime loading flags (-brtl), + # -berok will link without error, but may produce a broken library. + allow_undefined_flag_CXX='-berok' + # Determine the default libpath from the value encoded in an empty executable. + cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext @@ -10213,16 +12027,25 @@ $as_echo "$ac_try_echo") >&5 cat conftest.err >&5 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || + test -z "$ac_cxx_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && { test "$cross_compiling" = yes || $as_test_x conftest$ac_exeext }; then - if ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then - shlibpath_overrides_runpath=yes -fi +lt_aix_libpath_sed=' + /Import File Strings/,/^$/ { + /^0/ { + s/^0 *\(.*\)$/\1/ + p + } + }' +aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` +# Check for a 64-bit object if we didn't find anything. +if test -z "$aix_libpath"; then + aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` +fi else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 @@ -10233,5370 +12056,6163 @@ fi rm -rf conftest.dSYM rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext - LDFLAGS=$save_LDFLAGS - libdir=$save_libdir - - # This implies no fast_install, which is unacceptable. - # Some rework will be needed to allow for fast_install - # before this can be enabled. - hardcode_into_libs=yes +if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi - # Add ABI-specific directories to the system library path. - sys_lib_dlsearch_path_spec="/lib64 /usr/lib64 /lib /usr/lib" + hardcode_libdir_flag_spec_CXX='${wl}-blibpath:$libdir:'"$aix_libpath" - # Append ld.so.conf contents to the search path - if test -f /etc/ld.so.conf; then - lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '` - sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec $lt_ld_extra" - fi + archive_expsym_cmds_CXX="\$CC"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag" + else + if test "$host_cpu" = ia64; then + hardcode_libdir_flag_spec_CXX='${wl}-R $libdir:/usr/lib:/lib' + allow_undefined_flag_CXX="-z nodefs" + archive_expsym_cmds_CXX="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols" + else + # Determine the default libpath from the value encoded in an empty executable. + cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ - # We used to test for /lib/ld.so.1 and disable shared libraries on - # powerpc, because MkLinux only supported shared libraries with the - # GNU dynamic linker. Since this was broken with cross compilers, - # most powerpc-linux boxes support dynamic linking these days and - # people can always --disable-shared, the test was removed, and we - # assume the GNU/Linux dynamic linker is in use. - dynamic_linker='GNU/Linux ld.so' - ;; +int +main () +{ -netbsd*) - version_type=sunos - need_lib_prefix=no - need_version=no - if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' - dynamic_linker='NetBSD (a.out) ld.so' - else - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - dynamic_linker='NetBSD ld.elf_so' - fi - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - ;; + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext 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>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_cxx_werror_flag" || + test ! -s conftest.err + } && test -s conftest$ac_exeext && { + test "$cross_compiling" = yes || + $as_test_x conftest$ac_exeext + }; then -newsos6) - version_type=linux - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - ;; +lt_aix_libpath_sed=' + /Import File Strings/,/^$/ { + /^0/ { + s/^0 *\(.*\)$/\1/ + p + } + }' +aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` +# Check for a 64-bit object if we didn't find anything. +if test -z "$aix_libpath"; then + aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` +fi +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 -*nto* | *qnx*) - version_type=qnx - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - dynamic_linker='ldqnx.so' - ;; -openbsd*) - version_type=sunos - sys_lib_dlsearch_path_spec="/usr/lib" - need_lib_prefix=no - # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs. - case $host_os in - openbsd3.3 | openbsd3.3.*) need_version=yes ;; - *) need_version=no ;; - esac - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' - shlibpath_var=LD_LIBRARY_PATH - if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - case $host_os in - openbsd2.[89] | openbsd2.[89].*) - shlibpath_overrides_runpath=no - ;; - *) - shlibpath_overrides_runpath=yes - ;; - esac - else - shlibpath_overrides_runpath=yes - fi - ;; +fi -os2*) - libname_spec='$name' - shrext_cmds=".dll" - need_lib_prefix=no - library_names_spec='$libname${shared_ext} $libname.a' - dynamic_linker='OS/2 ld.exe' - shlibpath_var=LIBPATH - ;; +rm -rf conftest.dSYM +rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ + conftest$ac_exeext conftest.$ac_ext +if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi -osf3* | osf4* | osf5*) - version_type=osf - need_lib_prefix=no - need_version=no - soname_spec='${libname}${release}${shared_ext}$major' - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" - sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" - ;; + hardcode_libdir_flag_spec_CXX='${wl}-blibpath:$libdir:'"$aix_libpath" + # Warning - without using the other run time loading flags, + # -berok will link without error, but may produce a broken library. + no_undefined_flag_CXX=' ${wl}-bernotok' + allow_undefined_flag_CXX=' ${wl}-berok' + # Exported symbols can be pulled into shared objects from archives + whole_archive_flag_spec_CXX='$convenience' + archive_cmds_need_lc_CXX=yes + # This is similar to how AIX traditionally builds its shared libraries. + archive_expsym_cmds_CXX="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' + fi + fi + ;; -rdos*) - dynamic_linker=no - ;; + beos*) + if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then + allow_undefined_flag_CXX=unsupported + # Joseph Beckenbach says some releases of gcc + # support --undefined. This deserves some investigation. FIXME + archive_cmds_CXX='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + else + ld_shlibs_CXX=no + fi + ;; -solaris*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - # ldd complains unless libraries are executable - postinstall_cmds='chmod +x $lib' - ;; + chorus*) + case $cc_basename in + *) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + esac + ;; -sunos4*) - version_type=sunos - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' - finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - if test "$with_gnu_ld" = yes; then - need_lib_prefix=no - fi - need_version=yes + cygwin* | mingw* | pw32*) + # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, CXX) is actually meaningless, + # as there is no search path for DLLs. + hardcode_libdir_flag_spec_CXX='-L$libdir' + allow_undefined_flag_CXX=unsupported + always_export_symbols_CXX=no + enable_shared_with_static_runtimes_CXX=yes + + if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then + archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + # If the export-symbols file already is a .def file (1st line + # is EXPORTS), use it as is; otherwise, prepend... + archive_expsym_cmds_CXX='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then + cp $export_symbols $output_objdir/$soname.def; + else + echo EXPORTS > $output_objdir/$soname.def; + cat $export_symbols >> $output_objdir/$soname.def; + fi~ + $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + else + ld_shlibs_CXX=no + fi ;; + darwin* | rhapsody*) + archive_cmds_need_lc_CXX=no + hardcode_direct_CXX=no + hardcode_automatic_CXX=yes + hardcode_shlibpath_var_CXX=unsupported + whole_archive_flag_spec_CXX='' + link_all_deplibs_CXX=yes + allow_undefined_flag_CXX="$_lt_dar_allow_undefined" + if test "$GXX" = yes ; then + output_verbose_link_cmd='echo' + archive_cmds_CXX="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}" + module_cmds_CXX="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}" + archive_expsym_cmds_CXX="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}" + module_expsym_cmds_CXX="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}" + if test "$lt_cv_apple_cc_single_mod" != "yes"; then + archive_cmds_CXX="\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dsymutil}" + archive_expsym_cmds_CXX="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dar_export_syms}${_lt_dsymutil}" + fi + else + case $cc_basename in + xlc*) + output_verbose_link_cmd='echo' + archive_cmds_CXX='$CC -qmkshrobj ${wl}-single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $xlcverstring' + module_cmds_CXX='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags' + # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds + archive_expsym_cmds_CXX='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj ${wl}-single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $xlcverstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' + module_expsym_cmds_CXX='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' + ;; + *) + ld_shlibs_CXX=no + ;; + esac + fi + ;; -sysv4 | sysv4.3*) - version_type=linux - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - case $host_vendor in - sni) - shlibpath_overrides_runpath=no - need_lib_prefix=no - runpath_var=LD_RUN_PATH + dgux*) + case $cc_basename in + ec++*) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + ghcx*) + # Green Hills C++ Compiler + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + *) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + esac + ;; + freebsd[12]*) + # C++ shared libraries reported to be fairly broken before switch to ELF + ld_shlibs_CXX=no + ;; + freebsd-elf*) + archive_cmds_need_lc_CXX=no + ;; + freebsd* | dragonfly*) + # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF + # conventions + ld_shlibs_CXX=yes + ;; + gnu*) + ;; + hpux9*) + hardcode_libdir_flag_spec_CXX='${wl}+b ${wl}$libdir' + hardcode_libdir_separator_CXX=: + export_dynamic_flag_spec_CXX='${wl}-E' + hardcode_direct_CXX=yes + hardcode_minus_L_CXX=yes # Not in the search PATH, + # but as the default + # location of the library. + + case $cc_basename in + CC*) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no ;; - siemens) - need_lib_prefix=no + aCC*) + archive_cmds_CXX='$rm $output_objdir/$soname~$CC -b ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | grep "[-]L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' ;; - motorola) - need_lib_prefix=no - need_version=no - shlibpath_overrides_runpath=no - sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' + *) + if test "$GXX" = yes; then + archive_cmds_CXX='$rm $output_objdir/$soname~$CC -shared -nostdlib -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' + else + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + fi ;; - esac - ;; - -sysv4*MP*) - if test -d /usr/nec ;then - version_type=linux - library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' - soname_spec='$libname${shared_ext}.$major' - shlibpath_var=LD_LIBRARY_PATH - fi - ;; + esac + ;; + hpux10*|hpux11*) + if test $with_gnu_ld = no; then + hardcode_libdir_flag_spec_CXX='${wl}+b ${wl}$libdir' + hardcode_libdir_separator_CXX=: -sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) - version_type=freebsd-elf - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - if test "$with_gnu_ld" = yes; then - sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' - else - sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' - case $host_os in - sco3.2v5*) - sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" - ;; + case $host_cpu in + hppa*64*|ia64*) ;; + *) + export_dynamic_flag_spec_CXX='${wl}-E' + ;; + esac + fi + case $host_cpu in + hppa*64*|ia64*) + hardcode_direct_CXX=no + hardcode_shlibpath_var_CXX=no + ;; + *) + hardcode_direct_CXX=yes + hardcode_minus_L_CXX=yes # Not in the search PATH, + # but as the default + # location of the library. + ;; esac - fi - sys_lib_dlsearch_path_spec='/usr/lib' - ;; - -tpf*) - # TPF is a cross-target only. Preferred cross-host = GNU/Linux. - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - ;; - -uts4*) - version_type=linux - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - ;; - -*) - dynamic_linker=no - ;; -esac -{ $as_echo "$as_me:$LINENO: result: $dynamic_linker" >&5 -$as_echo "$dynamic_linker" >&6; } -test "$dynamic_linker" = no && can_build_shared=no - -variables_saved_for_relink="PATH $shlibpath_var $runpath_var" -if test "$GCC" = yes; then - variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" -fi - -if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then - sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec" -fi -if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then - sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec" -fi - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + case $cc_basename in + CC*) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + aCC*) + case $host_cpu in + hppa*64*) + archive_cmds_CXX='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + ia64*) + archive_cmds_CXX='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + *) + archive_cmds_CXX='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + esac + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | grep "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' + ;; + *) + if test "$GXX" = yes; then + if test $with_gnu_ld = no; then + case $host_cpu in + hppa*64*) + archive_cmds_CXX='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + ia64*) + archive_cmds_CXX='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + *) + archive_cmds_CXX='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + ;; + esac + fi + else + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + fi + ;; + esac + ;; + interix[3-9]*) + hardcode_direct_CXX=no + hardcode_shlibpath_var_CXX=no + hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir' + export_dynamic_flag_spec_CXX='${wl}-E' + # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. + # Instead, shared libraries are loaded at an image base (0x10000000 by + # default) and relocated if they conflict, which is a slow very memory + # consuming and fragmenting process. To avoid this, we pick a random, + # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link + # time. Moving up from 0x10000000 also allows more sbrk(2) space. + archive_cmds_CXX='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + archive_expsym_cmds_CXX='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + ;; + irix5* | irix6*) + case $cc_basename in + CC*) + # SGI C++ + archive_cmds_CXX='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' + + # Archives containing C++ object files must be created using + # "CC -ar", where "CC" is the IRIX C++ compiler. This is + # necessary to make sure instantiated templates are included + # in the archive. + old_archive_cmds_CXX='$CC -ar -WR,-u -o $oldlib $oldobjs' + ;; + *) + if test "$GXX" = yes; then + if test "$with_gnu_ld" = no; then + archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + else + archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` -o $lib' + fi + fi + link_all_deplibs_CXX=yes + ;; + esac + hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir' + hardcode_libdir_separator_CXX=: + ;; + linux* | k*bsd*-gnu) + case $cc_basename in + KCC*) + # Kuck and Associates, Inc. (KAI) C++ Compiler + + # KCC will only create a shared library if the output file + # ends with ".so" (or ".sl" for HP-UX), so rename the library + # to its proper name (with version) after linking. + archive_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' + archive_expsym_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib ${wl}-retain-symbols-file,$export_symbols; mv \$templib $lib' + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | grep "ld"`; rm -f libconftest$shared_ext; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' + + hardcode_libdir_flag_spec_CXX='${wl}--rpath,$libdir' + export_dynamic_flag_spec_CXX='${wl}--export-dynamic' + + # Archives containing C++ object files must be created using + # "CC -Bstatic", where "CC" is the KAI C++ compiler. + old_archive_cmds_CXX='$CC -Bstatic -o $oldlib $oldobjs' + ;; + icpc*) + # Intel C++ + with_gnu_ld=yes + # version 8.0 and above of icpc choke on multiply defined symbols + # if we add $predep_objects and $postdep_objects, however 7.1 and + # earlier do not add the objects themselves. + case `$CC -V 2>&1` in + *"Version 7."*) + archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + ;; + *) # Version 8.0 or newer + tmp_idyn= + case $host_cpu in + ia64*) tmp_idyn=' -i_dynamic';; + esac + archive_cmds_CXX='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds_CXX='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + ;; + esac + archive_cmds_need_lc_CXX=no + hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir' + export_dynamic_flag_spec_CXX='${wl}--export-dynamic' + whole_archive_flag_spec_CXX='${wl}--whole-archive$convenience ${wl}--no-whole-archive' + ;; + pgCC* | pgcpp*) + # Portland Group C++ compiler + archive_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib' + archive_expsym_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib' + + hardcode_libdir_flag_spec_CXX='${wl}--rpath ${wl}$libdir' + export_dynamic_flag_spec_CXX='${wl}--export-dynamic' + whole_archive_flag_spec_CXX='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' + ;; + cxx*) + # Compaq C++ + archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib ${wl}-retain-symbols-file $wl$export_symbols' + runpath_var=LD_RUN_PATH + hardcode_libdir_flag_spec_CXX='-rpath $libdir' + hardcode_libdir_separator_CXX=: + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld"`; templist=`echo $templist | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' + ;; + *) + case `$CC -V 2>&1 | sed 5q` in + *Sun\ C*) + # Sun C++ 5.9 + no_undefined_flag_CXX=' -zdefs' + archive_cmds_CXX='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + archive_expsym_cmds_CXX='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file ${wl}$export_symbols' + hardcode_libdir_flag_spec_CXX='-R$libdir' + whole_archive_flag_spec_CXX='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' + + # Not sure whether something based on + # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 + # would be better. + output_verbose_link_cmd='echo' + + # Archives containing C++ object files must be created using + # "CC -xar", where "CC" is the Sun C++ compiler. This is + # necessary to make sure instantiated templates are included + # in the archive. + old_archive_cmds_CXX='$CC -xar -o $oldlib $oldobjs' + ;; + esac + ;; + esac + ;; + lynxos*) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + m88k*) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + mvs*) + case $cc_basename in + cxx*) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + *) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + esac + ;; + netbsd*) + if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then + archive_cmds_CXX='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags' + wlarc= + hardcode_libdir_flag_spec_CXX='-R$libdir' + hardcode_direct_CXX=yes + hardcode_shlibpath_var_CXX=no + fi + # Workaround some broken pre-1.5 toolchains + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"' + ;; + openbsd2*) + # C++ shared libraries are fairly broken + ld_shlibs_CXX=no + ;; + openbsd*) + if test -f /usr/libexec/ld.so; then + hardcode_direct_CXX=yes + hardcode_shlibpath_var_CXX=no + archive_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' + hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir' + if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then + archive_expsym_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file,$export_symbols -o $lib' + export_dynamic_flag_spec_CXX='${wl}-E' + whole_archive_flag_spec_CXX="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' + fi + output_verbose_link_cmd='echo' + else + ld_shlibs_CXX=no + fi + ;; + osf3*) + case $cc_basename in + KCC*) + # Kuck and Associates, Inc. (KAI) C++ Compiler + # KCC will only create a shared library if the output file + # ends with ".so" (or ".sl" for HP-UX), so rename the library + # to its proper name (with version) after linking. + archive_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' + hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir' + hardcode_libdir_separator_CXX=: + # Archives containing C++ object files must be created using + # "CC -Bstatic", where "CC" is the KAI C++ compiler. + old_archive_cmds_CXX='$CC -Bstatic -o $oldlib $oldobjs' + ;; + RCC*) + # Rational C++ 2.4.1 + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + cxx*) + allow_undefined_flag_CXX=' ${wl}-expect_unresolved ${wl}\*' + archive_cmds_CXX='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $soname `test -n "$verstring" && echo ${wl}-set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' + + hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir' + hardcode_libdir_separator_CXX=: + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld" | grep -v "ld:"`; templist=`echo $templist | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' + ;; + *) + if test "$GXX" = yes && test "$with_gnu_ld" = no; then + allow_undefined_flag_CXX=' ${wl}-expect_unresolved ${wl}\*' + archive_cmds_CXX='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir' + hardcode_libdir_separator_CXX=: + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"' + else + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + fi + ;; + esac + ;; + osf4* | osf5*) + case $cc_basename in + KCC*) + # Kuck and Associates, Inc. (KAI) C++ Compiler + + # KCC will only create a shared library if the output file + # ends with ".so" (or ".sl" for HP-UX), so rename the library + # to its proper name (with version) after linking. + archive_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' + + hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir' + hardcode_libdir_separator_CXX=: + + # Archives containing C++ object files must be created using + # the KAI C++ compiler. + old_archive_cmds_CXX='$CC -o $oldlib $oldobjs' + ;; + RCC*) + # Rational C++ 2.4.1 + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + cxx*) + allow_undefined_flag_CXX=' -expect_unresolved \*' + archive_cmds_CXX='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' + archive_expsym_cmds_CXX='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~ + echo "-hidden">> $lib.exp~ + $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname -Wl,-input -Wl,$lib.exp `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib~ + $rm $lib.exp' + + hardcode_libdir_flag_spec_CXX='-rpath $libdir' + hardcode_libdir_separator_CXX=: + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + # + # There doesn't appear to be a way to prevent this compiler from + # explicitly linking system object files so we need to strip them + # from the output so that they don't get included in the library + # dependencies. + output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld" | grep -v "ld:"`; templist=`echo $templist | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' + ;; + *) + if test "$GXX" = yes && test "$with_gnu_ld" = no; then + allow_undefined_flag_CXX=' ${wl}-expect_unresolved ${wl}\*' + archive_cmds_CXX='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir' + hardcode_libdir_separator_CXX=: + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"' + else + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + fi + ;; + esac + ;; + psos*) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + sunos4*) + case $cc_basename in + CC*) + # Sun C++ 4.x + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + lcc*) + # Lucid + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + *) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + esac + ;; + solaris*) + case $cc_basename in + CC*) + # Sun C++ 4.2, 5.x and Centerline C++ + archive_cmds_need_lc_CXX=yes + no_undefined_flag_CXX=' -zdefs' + archive_cmds_CXX='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + archive_expsym_cmds_CXX='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ + $CC -G${allow_undefined_flag} ${wl}-M ${wl}$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp' + + hardcode_libdir_flag_spec_CXX='-R$libdir' + hardcode_shlibpath_var_CXX=no + case $host_os in + solaris2.[0-5] | solaris2.[0-5].*) ;; + *) + # The compiler driver will combine and reorder linker options, + # but understands `-z linker_flag'. + # Supported since Solaris 2.6 (maybe 2.5.1?) + whole_archive_flag_spec_CXX='-z allextract$convenience -z defaultextract' + ;; + esac + link_all_deplibs_CXX=yes + output_verbose_link_cmd='echo' + # Archives containing C++ object files must be created using + # "CC -xar", where "CC" is the Sun C++ compiler. This is + # necessary to make sure instantiated templates are included + # in the archive. + old_archive_cmds_CXX='$CC -xar -o $oldlib $oldobjs' + ;; + gcx*) + # Green Hills C++ Compiler + archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' + # The C++ compiler must be used to create the archive. + old_archive_cmds_CXX='$CC $LDFLAGS -archive -o $oldlib $oldobjs' + ;; + *) + # GNU C++ compiler with Solaris linker + if test "$GXX" = yes && test "$with_gnu_ld" = no; then + no_undefined_flag_CXX=' ${wl}-z ${wl}defs' + if $CC --version | grep -v '^2\.7' > /dev/null; then + archive_cmds_CXX='$CC -shared -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' + archive_expsym_cmds_CXX='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ + $CC -shared -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp' + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + output_verbose_link_cmd="$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep \"\-L\"" + else + # g++ 2.7 appears to require `-G' NOT `-shared' on this + # platform. + archive_cmds_CXX='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' + archive_expsym_cmds_CXX='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ + $CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp' + + # Commands to make compiler produce verbose output that lists + # what "hidden" libraries, object files and flags are used when + # linking a shared library. + output_verbose_link_cmd="$CC -G $CFLAGS -v conftest.$objext 2>&1 | grep \"\-L\"" + fi + hardcode_libdir_flag_spec_CXX='${wl}-R $wl$libdir' + case $host_os in + solaris2.[0-5] | solaris2.[0-5].*) ;; + *) + whole_archive_flag_spec_CXX='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' + ;; + esac + fi + ;; + esac + ;; + sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*) + no_undefined_flag_CXX='${wl}-z,text' + archive_cmds_need_lc_CXX=no + hardcode_shlibpath_var_CXX=no + runpath_var='LD_RUN_PATH' + + case $cc_basename in + CC*) + archive_cmds_CXX='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds_CXX='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + *) + archive_cmds_CXX='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds_CXX='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + esac + ;; + sysv5* | sco3.2v5* | sco5v6*) + # Note: We can NOT use -z defs as we might desire, because we do not + # link with -lc, and that would cause any symbols used from libc to + # always be unresolved, which means just about no library would + # ever link correctly. If we're not using GNU ld we use -z text + # though, which does catch some bad symbols but isn't as heavy-handed + # as -z defs. + # For security reasons, it is highly recommended that you always + # use absolute paths for naming shared libraries, and exclude the + # DT_RUNPATH tag from executables and libraries. But doing so + # requires that you compile everything twice, which is a pain. + # So that behaviour is only enabled if SCOABSPATH is set to a + # non-empty value in the environment. Most likely only useful for + # creating official distributions of packages. + # This is a hack until libtool officially supports absolute path + # names for shared libraries. + no_undefined_flag_CXX='${wl}-z,text' + allow_undefined_flag_CXX='${wl}-z,nodefs' + archive_cmds_need_lc_CXX=no + hardcode_shlibpath_var_CXX=no + hardcode_libdir_flag_spec_CXX='`test -z "$SCOABSPATH" && echo ${wl}-R,$libdir`' + hardcode_libdir_separator_CXX=':' + link_all_deplibs_CXX=yes + export_dynamic_flag_spec_CXX='${wl}-Bexport' + runpath_var='LD_RUN_PATH' + + case $cc_basename in + CC*) + archive_cmds_CXX='$CC -G ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds_CXX='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + *) + archive_cmds_CXX='$CC -shared ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds_CXX='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + esac + ;; + tandem*) + case $cc_basename in + NCC*) + # NonStop-UX NCC 3.20 + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + *) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + esac + ;; + vxworks*) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; + *) + # FIXME: insert proper C++ library support + ld_shlibs_CXX=no + ;; +esac +{ $as_echo "$as_me:$LINENO: result: $ld_shlibs_CXX" >&5 +$as_echo "$ld_shlibs_CXX" >&6; } +test "$ld_shlibs_CXX" = no && can_build_shared=no +GCC_CXX="$GXX" +LD_CXX="$LD" +cat > conftest.$ac_ext <&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; then + # Parse the compiler output and extract the necessary + # objects, libraries and library flags. + + # Sentinel used to keep track of whether or not we are before + # the conftest object file. + pre_test_object_deps_done=no + + # The `*' in the case matches for architectures that use `case' in + # $output_verbose_cmd can trigger glob expansion during the loop + # eval without this substitution. + output_verbose_link_cmd=`$echo "X$output_verbose_link_cmd" | $Xsed -e "$no_glob_subst"` + + for p in `eval $output_verbose_link_cmd`; do + case $p in + + -L* | -R* | -l*) + # Some compilers place space between "-{L,R}" and the path. + # Remove the space. + if test $p = "-L" \ + || test $p = "-R"; then + prev=$p + continue + else + prev= + fi + if test "$pre_test_object_deps_done" = no; then + case $p in + -L* | -R*) + # Internal compiler library paths should come after those + # provided the user. The postdeps already come after the + # user supplied libs so there is no need to process them. + if test -z "$compiler_lib_search_path_CXX"; then + compiler_lib_search_path_CXX="${prev}${p}" + else + compiler_lib_search_path_CXX="${compiler_lib_search_path_CXX} ${prev}${p}" + fi + ;; + # The "-l" case would never come before the object being + # linked, so don't bother handling this case. + esac + else + if test -z "$postdeps_CXX"; then + postdeps_CXX="${prev}${p}" + else + postdeps_CXX="${postdeps_CXX} ${prev}${p}" + fi + fi + ;; + + *.$objext) + # This assumes that the test object file only shows up + # once in the compiler output. + if test "$p" = "conftest.$objext"; then + pre_test_object_deps_done=yes + continue + fi + if test "$pre_test_object_deps_done" = no; then + if test -z "$predep_objects_CXX"; then + predep_objects_CXX="$p" + else + predep_objects_CXX="$predep_objects_CXX $p" + fi + else + if test -z "$postdep_objects_CXX"; then + postdep_objects_CXX="$p" + else + postdep_objects_CXX="$postdep_objects_CXX $p" + fi + fi + ;; + *) ;; # Ignore the rest. + esac + done + # Clean up. + rm -f a.out a.exe +else + echo "libtool.m4: error: problem compiling CXX test program" +fi +$rm -f confest.$objext +compiler_lib_search_dirs_CXX= +if test -n "$compiler_lib_search_path_CXX"; then + compiler_lib_search_dirs_CXX=`echo " ${compiler_lib_search_path_CXX}" | ${SED} -e 's! -L! !g' -e 's!^ !!'` +fi +# PORTME: override above test on systems where it is broken +case $host_os in +interix[3-9]*) + # Interix 3.5 installs completely hosed .la files for C++, so rather than + # hack all around it, let's just trust "g++" to DTRT. + predep_objects_CXX= + postdep_objects_CXX= + postdeps_CXX= + ;; +linux*) + case `$CC -V 2>&1 | sed 5q` in + *Sun\ C*) + # Sun C++ 5.9 + # + # The more standards-conforming stlport4 library is + # incompatible with the Cstd library. Avoid specifying + # it if it's in CXXFLAGS. Ignore libCrun as + # -library=stlport4 depends on it. + case " $CXX $CXXFLAGS " in + *" -library=stlport4 "*) + solaris_use_stlport4=yes + ;; + esac + if test "$solaris_use_stlport4" != yes; then + postdeps_CXX='-library=Cstd -library=Crun' + fi + ;; + esac + ;; +solaris*) + case $cc_basename in + CC*) + # The more standards-conforming stlport4 library is + # incompatible with the Cstd library. Avoid specifying + # it if it's in CXXFLAGS. Ignore libCrun as + # -library=stlport4 depends on it. + case " $CXX $CXXFLAGS " in + *" -library=stlport4 "*) + solaris_use_stlport4=yes + ;; + esac + # Adding this requires a known-good setup of shared libraries for + # Sun compiler versions before 5.6, else PIC objects from an old + # archive will be linked into the output, leading to subtle bugs. + if test "$solaris_use_stlport4" != yes; then + postdeps_CXX='-library=Cstd -library=Crun' + fi + ;; + esac + ;; +esac +case " $postdeps_CXX " in +*" -lc "*) archive_cmds_need_lc_CXX=no ;; +esac +lt_prog_compiler_wl_CXX= +lt_prog_compiler_pic_CXX= +lt_prog_compiler_static_CXX= +{ $as_echo "$as_me:$LINENO: checking for $compiler option to produce PIC" >&5 +$as_echo_n "checking for $compiler option to produce PIC... " >&6; } - { $as_echo "$as_me:$LINENO: checking how to hardcode library paths into programs" >&5 -$as_echo_n "checking how to hardcode library paths into programs... " >&6; } -hardcode_action= -if test -n "$hardcode_libdir_flag_spec" || - test -n "$runpath_var" || - test "X$hardcode_automatic" = "Xyes" ; then + # C++ specific cases for pic, static, wl, etc. + if test "$GXX" = yes; then + lt_prog_compiler_wl_CXX='-Wl,' + lt_prog_compiler_static_CXX='-static' - # We can hardcode non-existent directories. - if test "$hardcode_direct" != no && - # If the only mechanism to avoid hardcoding is shlibpath_var, we - # have to relink, otherwise we might link with an installed library - # when we should be linking with a yet-to-be-installed one - ## test "$_LT_TAGVAR(hardcode_shlibpath_var, )" != no && - test "$hardcode_minus_L" != no; then - # Linking always hardcodes the temporary library directory. - hardcode_action=relink - else - # We can link without hardcoding, and we can hardcode nonexisting dirs. - hardcode_action=immediate + case $host_os in + aix*) + # All AIX code is PIC. + if test "$host_cpu" = ia64; then + # AIX 5 now supports IA64 processor + lt_prog_compiler_static_CXX='-Bstatic' + fi + ;; + amigaos*) + # FIXME: we need at least 68020 code to build shared libraries, but + # adding the `-m68020' flag to GCC prevents building anything better, + # like `-m68040'. + lt_prog_compiler_pic_CXX='-m68020 -resident32 -malways-restore-a4' + ;; + beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) + # PIC is the default for these OSes. + ;; + mingw* | cygwin* | os2* | pw32*) + # This hack is so that the source file can tell whether it is being + # built for inclusion in a dll (and should export symbols for example). + # Although the cygwin gcc ignores -fPIC, still need this for old-style + # (--disable-auto-import) libraries + lt_prog_compiler_pic_CXX='-DDLL_EXPORT' + ;; + darwin* | rhapsody*) + # PIC is the default on this platform + # Common symbols not allowed in MH_DYLIB files + lt_prog_compiler_pic_CXX='-fno-common' + ;; + *djgpp*) + # DJGPP does not support shared libraries at all + lt_prog_compiler_pic_CXX= + ;; + interix[3-9]*) + # Interix 3.x gcc -fpic/-fPIC options generate broken code. + # Instead, we relocate shared libraries at runtime. + ;; + sysv4*MP*) + if test -d /usr/nec; then + lt_prog_compiler_pic_CXX=-Kconform_pic + fi + ;; + hpux*) + # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but + # not for PA HP-UX. + case $host_cpu in + hppa*64*|ia64*) + ;; + *) + lt_prog_compiler_pic_CXX='-fPIC' + ;; + esac + ;; + *) + lt_prog_compiler_pic_CXX='-fPIC' + ;; + esac + else + case $host_os in + aix[4-9]*) + # All AIX code is PIC. + if test "$host_cpu" = ia64; then + # AIX 5 now supports IA64 processor + lt_prog_compiler_static_CXX='-Bstatic' + else + lt_prog_compiler_static_CXX='-bnso -bI:/lib/syscalls.exp' + fi + ;; + chorus*) + case $cc_basename in + cxch68*) + # Green Hills C++ Compiler + # _LT_AC_TAGVAR(lt_prog_compiler_static, CXX)="--no_auto_instantiation -u __main -u __premain -u _abort -r $COOL_DIR/lib/libOrb.a $MVME_DIR/lib/CC/libC.a $MVME_DIR/lib/classix/libcx.s.a" + ;; + esac + ;; + darwin*) + # PIC is the default on this platform + # Common symbols not allowed in MH_DYLIB files + case $cc_basename in + xlc*) + lt_prog_compiler_pic_CXX='-qnocommon' + lt_prog_compiler_wl_CXX='-Wl,' + ;; + esac + ;; + dgux*) + case $cc_basename in + ec++*) + lt_prog_compiler_pic_CXX='-KPIC' + ;; + ghcx*) + # Green Hills C++ Compiler + lt_prog_compiler_pic_CXX='-pic' + ;; + *) + ;; + esac + ;; + freebsd* | dragonfly*) + # FreeBSD uses GNU C++ + ;; + hpux9* | hpux10* | hpux11*) + case $cc_basename in + CC*) + lt_prog_compiler_wl_CXX='-Wl,' + lt_prog_compiler_static_CXX='${wl}-a ${wl}archive' + if test "$host_cpu" != ia64; then + lt_prog_compiler_pic_CXX='+Z' + fi + ;; + aCC*) + lt_prog_compiler_wl_CXX='-Wl,' + lt_prog_compiler_static_CXX='${wl}-a ${wl}archive' + case $host_cpu in + hppa*64*|ia64*) + # +Z the default + ;; + *) + lt_prog_compiler_pic_CXX='+Z' + ;; + esac + ;; + *) + ;; + esac + ;; + interix*) + # This is c89, which is MS Visual C++ (no shared libs) + # Anyone wants to do a port? + ;; + irix5* | irix6* | nonstopux*) + case $cc_basename in + CC*) + lt_prog_compiler_wl_CXX='-Wl,' + lt_prog_compiler_static_CXX='-non_shared' + # CC pic flag -KPIC is the default. + ;; + *) + ;; + esac + ;; + linux* | k*bsd*-gnu) + case $cc_basename in + KCC*) + # KAI C++ Compiler + lt_prog_compiler_wl_CXX='--backend -Wl,' + lt_prog_compiler_pic_CXX='-fPIC' + ;; + icpc* | ecpc*) + # Intel C++ + lt_prog_compiler_wl_CXX='-Wl,' + lt_prog_compiler_pic_CXX='-KPIC' + lt_prog_compiler_static_CXX='-static' + ;; + pgCC* | pgcpp*) + # Portland Group C++ compiler. + lt_prog_compiler_wl_CXX='-Wl,' + lt_prog_compiler_pic_CXX='-fpic' + lt_prog_compiler_static_CXX='-Bstatic' + ;; + cxx*) + # Compaq C++ + # Make sure the PIC flag is empty. It appears that all Alpha + # Linux and Compaq Tru64 Unix objects are PIC. + lt_prog_compiler_pic_CXX= + lt_prog_compiler_static_CXX='-non_shared' + ;; + *) + case `$CC -V 2>&1 | sed 5q` in + *Sun\ C*) + # Sun C++ 5.9 + lt_prog_compiler_pic_CXX='-KPIC' + lt_prog_compiler_static_CXX='-Bstatic' + lt_prog_compiler_wl_CXX='-Qoption ld ' + ;; + esac + ;; + esac + ;; + lynxos*) + ;; + m88k*) + ;; + mvs*) + case $cc_basename in + cxx*) + lt_prog_compiler_pic_CXX='-W c,exportall' + ;; + *) + ;; + esac + ;; + netbsd*) + ;; + osf3* | osf4* | osf5*) + case $cc_basename in + KCC*) + lt_prog_compiler_wl_CXX='--backend -Wl,' + ;; + RCC*) + # Rational C++ 2.4.1 + lt_prog_compiler_pic_CXX='-pic' + ;; + cxx*) + # Digital/Compaq C++ + lt_prog_compiler_wl_CXX='-Wl,' + # Make sure the PIC flag is empty. It appears that all Alpha + # Linux and Compaq Tru64 Unix objects are PIC. + lt_prog_compiler_pic_CXX= + lt_prog_compiler_static_CXX='-non_shared' + ;; + *) + ;; + esac + ;; + psos*) + ;; + solaris*) + case $cc_basename in + CC*) + # Sun C++ 4.2, 5.x and Centerline C++ + lt_prog_compiler_pic_CXX='-KPIC' + lt_prog_compiler_static_CXX='-Bstatic' + lt_prog_compiler_wl_CXX='-Qoption ld ' + ;; + gcx*) + # Green Hills C++ Compiler + lt_prog_compiler_pic_CXX='-PIC' + ;; + *) + ;; + esac + ;; + sunos4*) + case $cc_basename in + CC*) + # Sun C++ 4.x + lt_prog_compiler_pic_CXX='-pic' + lt_prog_compiler_static_CXX='-Bstatic' + ;; + lcc*) + # Lucid + lt_prog_compiler_pic_CXX='-pic' + ;; + *) + ;; + esac + ;; + tandem*) + case $cc_basename in + NCC*) + # NonStop-UX NCC 3.20 + lt_prog_compiler_pic_CXX='-KPIC' + ;; + *) + ;; + esac + ;; + sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) + case $cc_basename in + CC*) + lt_prog_compiler_wl_CXX='-Wl,' + lt_prog_compiler_pic_CXX='-KPIC' + lt_prog_compiler_static_CXX='-Bstatic' + ;; + esac + ;; + vxworks*) + ;; + *) + lt_prog_compiler_can_build_shared_CXX=no + ;; + esac fi -else - # We cannot hardcode anything, or else we can only hardcode existing - # directories. - hardcode_action=unsupported -fi -{ $as_echo "$as_me:$LINENO: result: $hardcode_action" >&5 -$as_echo "$hardcode_action" >&6; } -if test "$hardcode_action" = relink || - test "$inherit_rpath" = yes; then - # Fast installation is not supported - enable_fast_install=no -elif test "$shlibpath_overrides_runpath" = yes || - test "$enable_shared" = no; then - # Fast installation is not necessary - enable_fast_install=needless -fi +{ $as_echo "$as_me:$LINENO: result: $lt_prog_compiler_pic_CXX" >&5 +$as_echo "$lt_prog_compiler_pic_CXX" >&6; } +# +# Check to make sure the PIC flag actually works. +# +if test -n "$lt_prog_compiler_pic_CXX"; then +{ $as_echo "$as_me:$LINENO: checking if $compiler PIC flag $lt_prog_compiler_pic_CXX works" >&5 +$as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic_CXX works... " >&6; } +if test "${lt_cv_prog_compiler_pic_works_CXX+set}" = set; then + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_pic_works_CXX=no + ac_outfile=conftest.$ac_objext + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + lt_compiler_flag="$lt_prog_compiler_pic_CXX -DPIC" + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + # The option is referenced via a variable to avoid confusing sed. + lt_compile=`echo "$ac_compile" | $SED \ + -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:13343: $lt_compile\"" >&5) + (eval "$lt_compile" 2>conftest.err) + ac_status=$? + cat conftest.err >&5 + echo "$as_me:13347: \$? = $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. + $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then + lt_cv_prog_compiler_pic_works_CXX=yes + fi + fi + $rm conftest* +fi +{ $as_echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_pic_works_CXX" >&5 +$as_echo "$lt_cv_prog_compiler_pic_works_CXX" >&6; } +if test x"$lt_cv_prog_compiler_pic_works_CXX" = xyes; then + case $lt_prog_compiler_pic_CXX in + "" | " "*) ;; + *) lt_prog_compiler_pic_CXX=" $lt_prog_compiler_pic_CXX" ;; + esac +else + lt_prog_compiler_pic_CXX= + lt_prog_compiler_can_build_shared_CXX=no +fi +fi +case $host_os in + # For platforms which do not support PIC, -DPIC is meaningless: + *djgpp*) + lt_prog_compiler_pic_CXX= + ;; + *) + lt_prog_compiler_pic_CXX="$lt_prog_compiler_pic_CXX -DPIC" + ;; +esac - if test "x$enable_dlopen" != xyes; then - enable_dlopen=unknown - enable_dlopen_self=unknown - enable_dlopen_self_static=unknown +# +# Check to make sure the static flag actually works. +# +wl=$lt_prog_compiler_wl_CXX eval lt_tmp_static_flag=\"$lt_prog_compiler_static_CXX\" +{ $as_echo "$as_me:$LINENO: checking if $compiler static flag $lt_tmp_static_flag works" >&5 +$as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; } +if test "${lt_cv_prog_compiler_static_works_CXX+set}" = set; then + $as_echo_n "(cached) " >&6 else - lt_cv_dlopen=no - lt_cv_dlopen_libs= + lt_cv_prog_compiler_static_works_CXX=no + save_LDFLAGS="$LDFLAGS" + LDFLAGS="$LDFLAGS $lt_tmp_static_flag" + echo "$lt_simple_link_test_code" > conftest.$ac_ext + if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then + # The linker can only warn and ignore the option if not recognized + # So say no if there are warnings + if test -s conftest.err; then + # Append any errors to the config.log. + cat conftest.err 1>&5 + $echo "X$_lt_linker_boilerplate" | $Xsed -e '/^$/d' > conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if diff conftest.exp conftest.er2 >/dev/null; then + lt_cv_prog_compiler_static_works_CXX=yes + fi + else + lt_cv_prog_compiler_static_works_CXX=yes + fi + fi + $rm -r conftest* + LDFLAGS="$save_LDFLAGS" - case $host_os in - beos*) - lt_cv_dlopen="load_add_on" - lt_cv_dlopen_libs= - lt_cv_dlopen_self=yes - ;; +fi +{ $as_echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_static_works_CXX" >&5 +$as_echo "$lt_cv_prog_compiler_static_works_CXX" >&6; } - mingw* | pw32* | cegcc*) - lt_cv_dlopen="LoadLibrary" - lt_cv_dlopen_libs= - ;; +if test x"$lt_cv_prog_compiler_static_works_CXX" = xyes; then + : +else + lt_prog_compiler_static_CXX= +fi - cygwin*) - lt_cv_dlopen="dlopen" - lt_cv_dlopen_libs= - ;; - darwin*) - # if libdl is installed we need to link against it - { $as_echo "$as_me:$LINENO: checking for dlopen in -ldl" >&5 -$as_echo_n "checking for dlopen in -ldl... " >&6; } -if test "${ac_cv_lib_dl_dlopen+set}" = set; then +{ $as_echo "$as_me:$LINENO: checking if $compiler supports -c -o file.$ac_objext" >&5 +$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } +if test "${lt_cv_prog_compiler_c_o_CXX+set}" = set; then $as_echo_n "(cached) " >&6 else - ac_check_lib_save_LIBS=$LIBS -LIBS="-ldl $LIBS" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ + lt_cv_prog_compiler_c_o_CXX=no + $rm -r conftest 2>/dev/null + mkdir conftest + cd conftest + mkdir out + echo "$lt_simple_compile_test_code" > conftest.$ac_ext -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char dlopen (); -int -main () -{ -return dlopen (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext 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>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_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - ac_cv_lib_dl_dlopen=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_lib_dl_dlopen=no -fi + lt_compiler_flag="-o out/conftest2.$ac_objext" + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + lt_compile=`echo "$ac_compile" | $SED \ + -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:13447: $lt_compile\"" >&5) + (eval "$lt_compile" 2>out/conftest.err) + ac_status=$? + cat out/conftest.err >&5 + echo "$as_me:13451: \$? = $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 + # So say no if there are warnings + $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp + $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 + if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then + lt_cv_prog_compiler_c_o_CXX=yes + fi + fi + chmod u+w . 2>&5 + $rm conftest* + # SGI C++ compiler will create directory out/ii_files/ for + # template instantiation + test -d out/ii_files && $rm out/ii_files/* && rmdir out/ii_files + $rm out/* && rmdir out + cd .. + rmdir conftest + $rm conftest* -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_dl_dlopen" >&5 -$as_echo "$ac_cv_lib_dl_dlopen" >&6; } -if test "x$ac_cv_lib_dl_dlopen" = x""yes; then - lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl" -else +{ $as_echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_c_o_CXX" >&5 +$as_echo "$lt_cv_prog_compiler_c_o_CXX" >&6; } - lt_cv_dlopen="dyld" - lt_cv_dlopen_libs= - lt_cv_dlopen_self=yes +hard_links="nottested" +if test "$lt_cv_prog_compiler_c_o_CXX" = no && test "$need_locks" != no; then + # do not overwrite the value of need_locks provided by the user + { $as_echo "$as_me:$LINENO: checking if we can lock with hard links" >&5 +$as_echo_n "checking if we can lock with hard links... " >&6; } + hard_links=yes + $rm conftest* + ln conftest.a conftest.b 2>/dev/null && hard_links=no + touch conftest.a + ln conftest.a conftest.b 2>&5 || hard_links=no + ln conftest.a conftest.b 2>/dev/null && hard_links=no + { $as_echo "$as_me:$LINENO: result: $hard_links" >&5 +$as_echo "$hard_links" >&6; } + if test "$hard_links" = no; then + { $as_echo "$as_me:$LINENO: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5 +$as_echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;} + need_locks=warn + fi +else + need_locks=no fi - ;; +{ $as_echo "$as_me:$LINENO: checking whether the $compiler linker ($LD) supports shared libraries" >&5 +$as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; } + export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' + case $host_os in + aix[4-9]*) + # If we're using GNU nm, then we don't want the "-C" option. + # -C means demangle to AIX nm, but means don't demangle with GNU nm + if $NM -V 2>&1 | grep 'GNU' > /dev/null; then + export_symbols_cmds_CXX='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$2 == "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print \$3 } }'\'' | sort -u > $export_symbols' + else + export_symbols_cmds_CXX='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$2 == "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print \$3 } }'\'' | sort -u > $export_symbols' + fi + ;; + pw32*) + export_symbols_cmds_CXX="$ltdll_cmds" + ;; + cygwin* | mingw*) + export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/;/^.*[ ]__nm__/s/^.*[ ]__nm__\([^ ]*\)[ ][^ ]*/\1 DATA/;/^I[ ]/d;/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols' + ;; *) - { $as_echo "$as_me:$LINENO: checking for shl_load" >&5 -$as_echo_n "checking for shl_load... " >&6; } -if test "${ac_cv_func_shl_load+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. */ -/* Define shl_load to an innocuous variant, in case declares shl_load. - For example, HP-UX 11i declares gettimeofday. */ -#define shl_load innocuous_shl_load - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char shl_load (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ + export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' + ;; + esac + exclude_expsyms_CXX='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*' -#ifdef __STDC__ -# include -#else -# include -#endif +{ $as_echo "$as_me:$LINENO: result: $ld_shlibs_CXX" >&5 +$as_echo "$ld_shlibs_CXX" >&6; } +test "$ld_shlibs_CXX" = no && can_build_shared=no -#undef shl_load +# +# Do we need to explicitly link libc? +# +case "x$archive_cmds_need_lc_CXX" in +x|xyes) + # Assume -lc should be added + archive_cmds_need_lc_CXX=yes -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char shl_load (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_shl_load || defined __stub___shl_load -choke me -#endif + if test "$enable_shared" = yes && test "$GCC" = yes; then + case $archive_cmds_CXX in + *'~'*) + # FIXME: we may have to deal with multi-command sequences. + ;; + '$CC '*) + # Test whether the compiler implicitly links with -lc since on some + # systems, -lgcc has to come before -lc. If gcc already passes -lc + # to ld, don't add -lc before -lgcc. + { $as_echo "$as_me:$LINENO: checking whether -lc should be explicitly linked in" >&5 +$as_echo_n "checking whether -lc should be explicitly linked in... " >&6; } + $rm conftest* + echo "$lt_simple_compile_test_code" > conftest.$ac_ext -int -main () -{ -return shl_load (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext 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>conftest.er1 + if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 + (eval $ac_compile) 2>&5 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_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - ac_cv_func_shl_load=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 + (exit $ac_status); } 2>conftest.err; then + soname=conftest + lib=conftest + libobjs=conftest.$ac_objext + deplibs= + wl=$lt_prog_compiler_wl_CXX + pic_flag=$lt_prog_compiler_pic_CXX + compiler_flags=-v + linker_flags=-v + verstring= + output_objdir=. + libname=conftest + lt_save_allow_undefined_flag=$allow_undefined_flag_CXX + allow_undefined_flag_CXX= + if { (eval echo "$as_me:$LINENO: \"$archive_cmds_CXX 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1\"") >&5 + (eval $archive_cmds_CXX 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1) 2>&5 + ac_status=$? + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } + then + archive_cmds_need_lc_CXX=no + else + archive_cmds_need_lc_CXX=yes + fi + allow_undefined_flag_CXX=$lt_save_allow_undefined_flag + else + cat conftest.err 1>&5 + fi + $rm conftest* + { $as_echo "$as_me:$LINENO: result: $archive_cmds_need_lc_CXX" >&5 +$as_echo "$archive_cmds_need_lc_CXX" >&6; } + ;; + esac + fi + ;; +esac - ac_cv_func_shl_load=no -fi +{ $as_echo "$as_me:$LINENO: checking dynamic linker characteristics" >&5 +$as_echo_n "checking dynamic linker characteristics... " >&6; } +library_names_spec= +libname_spec='lib$name' +soname_spec= +shrext_cmds=".so" +postinstall_cmds= +postuninstall_cmds= +finish_cmds= +finish_eval= +shlibpath_var= +shlibpath_overrides_runpath=unknown +version_type=none +dynamic_linker="$host_os ld.so" +sys_lib_dlsearch_path_spec="/lib /usr/lib" -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_func_shl_load" >&5 -$as_echo "$ac_cv_func_shl_load" >&6; } -if test "x$ac_cv_func_shl_load" = x""yes; then - lt_cv_dlopen="shl_load" -else - { $as_echo "$as_me:$LINENO: checking for shl_load in -ldld" >&5 -$as_echo_n "checking for shl_load in -ldld... " >&6; } -if test "${ac_cv_lib_dld_shl_load+set}" = set; then - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS -LIBS="-ldld $LIBS" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ +need_lib_prefix=unknown +hardcode_into_libs=no -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char shl_load (); -int -main () -{ -return shl_load (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext 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>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_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - ac_cv_lib_dld_shl_load=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 +# when you set need_version to no, make sure it does not cause -set_version +# flags to be left without arguments +need_version=unknown - ac_cv_lib_dld_shl_load=no -fi +case $host_os in +aix3*) + version_type=linux + library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a' + shlibpath_var=LIBPATH -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_dld_shl_load" >&5 -$as_echo "$ac_cv_lib_dld_shl_load" >&6; } -if test "x$ac_cv_lib_dld_shl_load" = x""yes; then - lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld" -else - { $as_echo "$as_me:$LINENO: checking for dlopen" >&5 -$as_echo_n "checking for dlopen... " >&6; } -if test "${ac_cv_func_dlopen+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. */ -/* Define dlopen to an innocuous variant, in case declares dlopen. - For example, HP-UX 11i declares gettimeofday. */ -#define dlopen innocuous_dlopen + # AIX 3 has no versioning support, so we append a major version to the name. + soname_spec='${libname}${release}${shared_ext}$major' + ;; -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char dlopen (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ +aix[4-9]*) + version_type=linux + need_lib_prefix=no + need_version=no + hardcode_into_libs=yes + if test "$host_cpu" = ia64; then + # AIX 5 supports IA64 + library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + else + # With GCC up to 2.95.x, collect2 would create an import file + # for dependence libraries. The import file would start with + # the line `#! .'. This would cause the generated library to + # depend on `.', always an invalid library. This was fixed in + # development snapshots of GCC prior to 3.0. + case $host_os in + aix4 | aix4.[01] | aix4.[01].*) + if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' + echo ' yes ' + echo '#endif'; } | ${CC} -E - | grep yes > /dev/null; then + : + else + can_build_shared=no + fi + ;; + esac + # AIX (on Power*) has no versioning support, so currently we can not hardcode correct + # soname into executable. Probably we can add versioning support to + # collect2, so additional links can be useful in future. + if test "$aix_use_runtimelinking" = yes; then + # If using run time linking (on AIX 4.2 or later) use lib.so + # instead of lib.a to let people know that these are not + # typical AIX shared libraries. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + else + # We preserve .a as extension for shared libraries through AIX4.2 + # and later when we are not doing run time linking. + library_names_spec='${libname}${release}.a $libname.a' + soname_spec='${libname}${release}${shared_ext}$major' + fi + shlibpath_var=LIBPATH + fi + ;; -#ifdef __STDC__ -# include -#else -# include -#endif +amigaos*) + library_names_spec='$libname.ixlibrary $libname.a' + # Create ${libname}_ixlibrary.a entries in /sys/libs. + finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$echo "X$lib" | $Xsed -e '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $rm /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' + ;; -#undef dlopen +beos*) + library_names_spec='${libname}${shared_ext}' + dynamic_linker="$host_os ld.so" + shlibpath_var=LIBRARY_PATH + ;; -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char dlopen (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_dlopen || defined __stub___dlopen -choke me -#endif +bsdi[45]*) + version_type=linux + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' + shlibpath_var=LD_LIBRARY_PATH + sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" + sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" + # the default ld.so.conf also contains /usr/contrib/lib and + # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow + # libtool to hard-code these into programs + ;; -int -main () -{ -return dlopen (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext 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>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_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - ac_cv_func_dlopen=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 +cygwin* | mingw* | pw32*) + version_type=windows + shrext_cmds=".dll" + need_version=no + need_lib_prefix=no - ac_cv_func_dlopen=no -fi + case $GCC,$host_os in + yes,cygwin* | yes,mingw* | yes,pw32*) + library_names_spec='$libname.dll.a' + # DLL is installed to $(libdir)/../bin by postinstall_cmds + postinstall_cmds='base_file=`basename \${file}`~ + dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i;echo \$dlname'\''`~ + dldir=$destdir/`dirname \$dlpath`~ + test -d \$dldir || mkdir -p \$dldir~ + $install_prog $dir/$dlname \$dldir/$dlname~ + chmod a+x \$dldir/$dlname' + postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ + dlpath=$dir/\$dldll~ + $rm \$dlpath' + shlibpath_overrides_runpath=yes -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_func_dlopen" >&5 -$as_echo "$ac_cv_func_dlopen" >&6; } -if test "x$ac_cv_func_dlopen" = x""yes; then - lt_cv_dlopen="dlopen" -else - { $as_echo "$as_me:$LINENO: checking for dlopen in -ldl" >&5 -$as_echo_n "checking for dlopen in -ldl... " >&6; } -if test "${ac_cv_lib_dl_dlopen+set}" = set; then - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS -LIBS="-ldl $LIBS" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char dlopen (); -int -main () -{ -return dlopen (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext 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>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_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - ac_cv_lib_dl_dlopen=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_lib_dl_dlopen=no -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_dl_dlopen" >&5 -$as_echo "$ac_cv_lib_dl_dlopen" >&6; } -if test "x$ac_cv_lib_dl_dlopen" = x""yes; then - lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl" -else - { $as_echo "$as_me:$LINENO: checking for dlopen in -lsvld" >&5 -$as_echo_n "checking for dlopen in -lsvld... " >&6; } -if test "${ac_cv_lib_svld_dlopen+set}" = set; then - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS -LIBS="-lsvld $LIBS" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char dlopen (); -int -main () -{ -return dlopen (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext 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>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_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - ac_cv_lib_svld_dlopen=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_lib_svld_dlopen=no -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_svld_dlopen" >&5 -$as_echo "$ac_cv_lib_svld_dlopen" >&6; } -if test "x$ac_cv_lib_svld_dlopen" = x""yes; then - lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld" -else - { $as_echo "$as_me:$LINENO: checking for dld_link in -ldld" >&5 -$as_echo_n "checking for dld_link in -ldld... " >&6; } -if test "${ac_cv_lib_dld_dld_link+set}" = set; then - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS -LIBS="-ldld $LIBS" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char dld_link (); -int -main () -{ -return dld_link (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext 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>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_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - ac_cv_lib_dld_dld_link=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_lib_dld_dld_link=no -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_dld_dld_link" >&5 -$as_echo "$ac_cv_lib_dld_dld_link" >&6; } -if test "x$ac_cv_lib_dld_dld_link" = x""yes; then - lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld" -fi - - -fi - - -fi - - -fi - - -fi - - -fi + case $host_os in + cygwin*) + # Cygwin DLLs use 'cyg' prefix rather than 'lib' + soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' + sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib" + ;; + mingw*) + # MinGW DLLs use traditional 'lib' prefix + soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' + sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"` + if echo "$sys_lib_search_path_spec" | grep ';[c-zC-Z]:/' >/dev/null; then + # It is most probably a Windows format PATH printed by + # mingw gcc, but we are running on Cygwin. Gcc prints its search + # path with ; separators, and with drive letters. We can handle the + # drive letters (cygwin fileutils understands them), so leave them, + # especially as we might pass files found there to a mingw objdump, + # which wouldn't understand a cygwinified path. Ahh. + sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` + else + sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` + fi + ;; + pw32*) + # pw32 DLLs use 'pw' prefix rather than 'lib' + library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' + ;; + esac + ;; + *) + library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib' ;; esac + dynamic_linker='Win32 ld.exe' + # FIXME: first we should search . and the directory the executable is in + shlibpath_var=PATH + ;; - if test "x$lt_cv_dlopen" != xno; then - enable_dlopen=yes - else - enable_dlopen=no - fi - - case $lt_cv_dlopen in - dlopen) - save_CPPFLAGS="$CPPFLAGS" - test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" +darwin* | rhapsody*) + dynamic_linker="$host_os dyld" + version_type=darwin + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${versuffix}$shared_ext ${libname}${release}${major}$shared_ext ${libname}$shared_ext' + soname_spec='${libname}${release}${major}$shared_ext' + shlibpath_overrides_runpath=yes + shlibpath_var=DYLD_LIBRARY_PATH + shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' - save_LDFLAGS="$LDFLAGS" - wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" + sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' + ;; - save_LIBS="$LIBS" - LIBS="$lt_cv_dlopen_libs $LIBS" +dgux*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + ;; - { $as_echo "$as_me:$LINENO: checking whether a program can dlopen itself" >&5 -$as_echo_n "checking whether a program can dlopen itself... " >&6; } -if test "${lt_cv_dlopen_self+set}" = set; then - $as_echo_n "(cached) " >&6 -else - if test "$cross_compiling" = yes; then : - lt_cv_dlopen_self=cross -else - lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 - lt_status=$lt_dlunknown - cat > conftest.$ac_ext <<_LT_EOF -#line 11195 "configure" -#include "confdefs.h" +freebsd1*) + dynamic_linker=no + ;; -#if HAVE_DLFCN_H -#include -#endif - -#include - -#ifdef RTLD_GLOBAL -# define LT_DLGLOBAL RTLD_GLOBAL -#else -# ifdef DL_GLOBAL -# define LT_DLGLOBAL DL_GLOBAL -# else -# define LT_DLGLOBAL 0 -# endif -#endif - -/* We may have to define LT_DLLAZY_OR_NOW in the command line if we - find out it does not work in some platform. */ -#ifndef LT_DLLAZY_OR_NOW -# ifdef RTLD_LAZY -# define LT_DLLAZY_OR_NOW RTLD_LAZY -# else -# ifdef DL_LAZY -# define LT_DLLAZY_OR_NOW DL_LAZY -# else -# ifdef RTLD_NOW -# define LT_DLLAZY_OR_NOW RTLD_NOW -# else -# ifdef DL_NOW -# define LT_DLLAZY_OR_NOW DL_NOW -# else -# define LT_DLLAZY_OR_NOW 0 -# endif -# endif -# endif -# endif -#endif - -void fnord() { int i=42;} -int main () -{ - void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); - int status = $lt_dlunknown; - - if (self) - { - if (dlsym (self,"fnord")) status = $lt_dlno_uscore; - else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; - /* dlclose (self); */ - } +freebsd* | dragonfly*) + # DragonFly does not have aout. When/if they implement a new + # versioning mechanism, adjust this. + if test -x /usr/bin/objformat; then + objformat=`/usr/bin/objformat` else - puts (dlerror ()); - - return status; -} -_LT_EOF - if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 - (eval $ac_link) 2>&5 - ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && test -s conftest${ac_exeext} 2>/dev/null; then - (./conftest; exit; ) >&5 2>/dev/null - lt_status=$? - case x$lt_status in - x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;; - x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;; - x$lt_dlunknown|x*) lt_cv_dlopen_self=no ;; + case $host_os in + freebsd[123]*) objformat=aout ;; + *) objformat=elf ;; esac - else : - # compilation failed - lt_cv_dlopen_self=no fi -fi -rm -fr conftest* + version_type=freebsd-$objformat + case $version_type in + freebsd-elf*) + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' + need_version=no + need_lib_prefix=no + ;; + freebsd-*) + library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' + need_version=yes + ;; + esac + shlibpath_var=LD_LIBRARY_PATH + case $host_os in + freebsd2*) + shlibpath_overrides_runpath=yes + ;; + freebsd3.[01]* | freebsdelf3.[01]*) + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; + freebsd3.[2-9]* | freebsdelf3.[2-9]* | \ + freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1) + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; + *) # from 4.6 on, and DragonFly + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; + esac + ;; +gnu*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + hardcode_into_libs=yes + ;; -fi -{ $as_echo "$as_me:$LINENO: result: $lt_cv_dlopen_self" >&5 -$as_echo "$lt_cv_dlopen_self" >&6; } +hpux9* | hpux10* | hpux11*) + # Give a soname corresponding to the major version so that dld.sl refuses to + # link against other versions. + version_type=sunos + need_lib_prefix=no + need_version=no + case $host_cpu in + ia64*) + shrext_cmds='.so' + hardcode_into_libs=yes + dynamic_linker="$host_os dld.so" + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + if test "X$HPUX_IA64_MODE" = X32; then + sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" + else + sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" + fi + sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec + ;; + hppa*64*) + shrext_cmds='.sl' + hardcode_into_libs=yes + dynamic_linker="$host_os dld.sl" + shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH + shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" + sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec + ;; + *) + shrext_cmds='.sl' + dynamic_linker="$host_os dld.sl" + shlibpath_var=SHLIB_PATH + shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + ;; + esac + # HP-UX runs *really* slowly unless shared libraries are mode 555. + postinstall_cmds='chmod 555 $lib' + ;; - if test "x$lt_cv_dlopen_self" = xyes; then - wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\" - { $as_echo "$as_me:$LINENO: checking whether a statically linked program can dlopen itself" >&5 -$as_echo_n "checking whether a statically linked program can dlopen itself... " >&6; } -if test "${lt_cv_dlopen_self_static+set}" = set; then - $as_echo_n "(cached) " >&6 -else - if test "$cross_compiling" = yes; then : - lt_cv_dlopen_self_static=cross -else - lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 - lt_status=$lt_dlunknown - cat > conftest.$ac_ext <<_LT_EOF -#line 11291 "configure" -#include "confdefs.h" +interix[3-9]*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; -#if HAVE_DLFCN_H -#include -#endif +irix5* | irix6* | nonstopux*) + case $host_os in + nonstopux*) version_type=nonstopux ;; + *) + if test "$lt_cv_prog_gnu_ld" = yes; then + version_type=linux + else + version_type=irix + fi ;; + esac + need_lib_prefix=no + need_version=no + soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}' + case $host_os in + irix5* | nonstopux*) + libsuff= shlibsuff= + ;; + *) + case $LD in # libtool.m4 will add one of these switches to LD + *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") + libsuff= shlibsuff= libmagic=32-bit;; + *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") + libsuff=32 shlibsuff=N32 libmagic=N32;; + *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") + libsuff=64 shlibsuff=64 libmagic=64-bit;; + *) libsuff= shlibsuff= libmagic=never-match;; + esac + ;; + esac + shlibpath_var=LD_LIBRARY${shlibsuff}_PATH + shlibpath_overrides_runpath=no + sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" + sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" + hardcode_into_libs=yes + ;; -#include +# No shared lib support for Linux oldld, aout, or coff. +linux*oldld* | linux*aout* | linux*coff*) + dynamic_linker=no + ;; -#ifdef RTLD_GLOBAL -# define LT_DLGLOBAL RTLD_GLOBAL -#else -# ifdef DL_GLOBAL -# define LT_DLGLOBAL DL_GLOBAL -# else -# define LT_DLGLOBAL 0 -# endif -#endif +# This must be Linux ELF. +linux* | k*bsd*-gnu) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + # This implies no fast_install, which is unacceptable. + # Some rework will be needed to allow for fast_install + # before this can be enabled. + hardcode_into_libs=yes -/* We may have to define LT_DLLAZY_OR_NOW in the command line if we - find out it does not work in some platform. */ -#ifndef LT_DLLAZY_OR_NOW -# ifdef RTLD_LAZY -# define LT_DLLAZY_OR_NOW RTLD_LAZY -# else -# ifdef DL_LAZY -# define LT_DLLAZY_OR_NOW DL_LAZY -# else -# ifdef RTLD_NOW -# define LT_DLLAZY_OR_NOW RTLD_NOW -# else -# ifdef DL_NOW -# define LT_DLLAZY_OR_NOW DL_NOW -# else -# define LT_DLLAZY_OR_NOW 0 -# endif -# endif -# endif -# endif -#endif + # Append ld.so.conf contents to the search path + if test -f /etc/ld.so.conf; then + lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '` + sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" + fi -void fnord() { int i=42;} -int main () -{ - void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); - int status = $lt_dlunknown; + # We used to test for /lib/ld.so.1 and disable shared libraries on + # powerpc, because MkLinux only supported shared libraries with the + # GNU dynamic linker. Since this was broken with cross compilers, + # most powerpc-linux boxes support dynamic linking these days and + # people can always --disable-shared, the test was removed, and we + # assume the GNU/Linux dynamic linker is in use. + dynamic_linker='GNU/Linux ld.so' + ;; - if (self) - { - if (dlsym (self,"fnord")) status = $lt_dlno_uscore; - else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; - /* dlclose (self); */ - } +netbsd*) + version_type=sunos + need_lib_prefix=no + need_version=no + if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' + dynamic_linker='NetBSD (a.out) ld.so' else - puts (dlerror ()); - - return status; -} -_LT_EOF - if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 - (eval $ac_link) 2>&5 - ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && test -s conftest${ac_exeext} 2>/dev/null; then - (./conftest; exit; ) >&5 2>/dev/null - lt_status=$? - case x$lt_status in - x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;; - x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;; - x$lt_dlunknown|x*) lt_cv_dlopen_self_static=no ;; - esac - else : - # compilation failed - lt_cv_dlopen_self_static=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + dynamic_linker='NetBSD ld.elf_so' fi -fi -rm -fr conftest* - - -fi -{ $as_echo "$as_me:$LINENO: result: $lt_cv_dlopen_self_static" >&5 -$as_echo "$lt_cv_dlopen_self_static" >&6; } - fi + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; - CPPFLAGS="$save_CPPFLAGS" - LDFLAGS="$save_LDFLAGS" - LIBS="$save_LIBS" - ;; - esac +newsos6) + version_type=linux + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + ;; - case $lt_cv_dlopen_self in - yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; - *) enable_dlopen_self=unknown ;; - esac +nto-qnx*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + ;; - case $lt_cv_dlopen_self_static in - yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;; - *) enable_dlopen_self_static=unknown ;; +openbsd*) + version_type=sunos + sys_lib_dlsearch_path_spec="/usr/lib" + need_lib_prefix=no + # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs. + case $host_os in + openbsd3.3 | openbsd3.3.*) need_version=yes ;; + *) need_version=no ;; esac -fi + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' + shlibpath_var=LD_LIBRARY_PATH + if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then + case $host_os in + openbsd2.[89] | openbsd2.[89].*) + shlibpath_overrides_runpath=no + ;; + *) + shlibpath_overrides_runpath=yes + ;; + esac + else + shlibpath_overrides_runpath=yes + fi + ;; +os2*) + libname_spec='$name' + shrext_cmds=".dll" + need_lib_prefix=no + library_names_spec='$libname${shared_ext} $libname.a' + dynamic_linker='OS/2 ld.exe' + shlibpath_var=LIBPATH + ;; +osf3* | osf4* | osf5*) + version_type=osf + need_lib_prefix=no + need_version=no + soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" + sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" + ;; +rdos*) + dynamic_linker=no + ;; +solaris*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + # ldd complains unless libraries are executable + postinstall_cmds='chmod +x $lib' + ;; +sunos4*) + version_type=sunos + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' + finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + if test "$with_gnu_ld" = yes; then + need_lib_prefix=no + fi + need_version=yes + ;; +sysv4 | sysv4.3*) + version_type=linux + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + case $host_vendor in + sni) + shlibpath_overrides_runpath=no + need_lib_prefix=no + export_dynamic_flag_spec='${wl}-Blargedynsym' + runpath_var=LD_RUN_PATH + ;; + siemens) + need_lib_prefix=no + ;; + motorola) + need_lib_prefix=no + need_version=no + shlibpath_overrides_runpath=no + sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' + ;; + esac + ;; +sysv4*MP*) + if test -d /usr/nec ;then + version_type=linux + library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' + soname_spec='$libname${shared_ext}.$major' + shlibpath_var=LD_LIBRARY_PATH + fi + ;; +sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) + version_type=freebsd-elf + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + hardcode_into_libs=yes + if test "$with_gnu_ld" = yes; then + sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' + shlibpath_overrides_runpath=no + else + sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' + shlibpath_overrides_runpath=yes + case $host_os in + sco3.2v5*) + sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" + ;; + esac + fi + sys_lib_dlsearch_path_spec='/usr/lib' + ;; +uts4*) + version_type=linux + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + ;; +*) + dynamic_linker=no + ;; +esac +{ $as_echo "$as_me:$LINENO: result: $dynamic_linker" >&5 +$as_echo "$dynamic_linker" >&6; } +test "$dynamic_linker" = no && can_build_shared=no +if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then + $as_echo_n "(cached) " >&6 +else + lt_cv_sys_lib_search_path_spec="$sys_lib_search_path_spec" +fi +sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec" +if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then + $as_echo_n "(cached) " >&6 +else + lt_cv_sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec" +fi +sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec" +variables_saved_for_relink="PATH $shlibpath_var $runpath_var" +if test "$GCC" = yes; then + variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" +fi +{ $as_echo "$as_me:$LINENO: checking how to hardcode library paths into programs" >&5 +$as_echo_n "checking how to hardcode library paths into programs... " >&6; } +hardcode_action_CXX= +if test -n "$hardcode_libdir_flag_spec_CXX" || \ + test -n "$runpath_var_CXX" || \ + test "X$hardcode_automatic_CXX" = "Xyes" ; then + # We can hardcode non-existant directories. + if test "$hardcode_direct_CXX" != no && + # If the only mechanism to avoid hardcoding is shlibpath_var, we + # have to relink, otherwise we might link with an installed library + # when we should be linking with a yet-to-be-installed one + ## test "$_LT_AC_TAGVAR(hardcode_shlibpath_var, CXX)" != no && + test "$hardcode_minus_L_CXX" != no; then + # Linking always hardcodes the temporary library directory. + hardcode_action_CXX=relink + else + # We can link without hardcoding, and we can hardcode nonexisting dirs. + hardcode_action_CXX=immediate + fi +else + # We cannot hardcode anything, or else we can only hardcode existing + # directories. + hardcode_action_CXX=unsupported +fi +{ $as_echo "$as_me:$LINENO: result: $hardcode_action_CXX" >&5 +$as_echo "$hardcode_action_CXX" >&6; } -striplib= -old_striplib= -{ $as_echo "$as_me:$LINENO: checking whether stripping libraries is possible" >&5 -$as_echo_n "checking whether stripping libraries is possible... " >&6; } -if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then - test -z "$old_striplib" && old_striplib="$STRIP --strip-debug" - test -z "$striplib" && striplib="$STRIP --strip-unneeded" - { $as_echo "$as_me:$LINENO: result: yes" >&5 -$as_echo "yes" >&6; } -else -# FIXME - insert some real tests, host_os isn't really good enough - case $host_os in - darwin*) - if test -n "$STRIP" ; then - striplib="$STRIP -x" - old_striplib="$STRIP -S" - { $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; } - fi - ;; - *) - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } - ;; - esac +if test "$hardcode_action_CXX" = relink; then + # Fast installation is not supported + enable_fast_install=no +elif test "$shlibpath_overrides_runpath" = yes || + test "$enable_shared" = no; then + # Fast installation is not necessary + enable_fast_install=needless fi +# The else clause should only fire when bootstrapping the +# libtool distribution, otherwise you forgot to ship ltmain.sh +# with your package, and you will get complaints that there are +# no rules to generate ltmain.sh. +if test -f "$ltmain"; then + # See if we are running on zsh, and set the options which allow our commands through + # without removal of \ escapes. + if test -n "${ZSH_VERSION+set}" ; then + setopt NO_GLOB_SUBST + fi + # Now quote all the things that may contain metacharacters while being + # careful not to overquote the AC_SUBSTed values. We take copies of the + # variables and quote the copies for generation of the libtool script. + for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC LTCFLAGS NM \ + SED SHELL STRIP \ + libname_spec library_names_spec soname_spec extract_expsyms_cmds \ + old_striplib striplib file_magic_cmd finish_cmds finish_eval \ + deplibs_check_method reload_flag reload_cmds need_locks \ + lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \ + lt_cv_sys_global_symbol_to_c_name_address \ + sys_lib_search_path_spec sys_lib_dlsearch_path_spec \ + old_postinstall_cmds old_postuninstall_cmds \ + compiler_CXX \ + CC_CXX \ + LD_CXX \ + lt_prog_compiler_wl_CXX \ + lt_prog_compiler_pic_CXX \ + lt_prog_compiler_static_CXX \ + lt_prog_compiler_no_builtin_flag_CXX \ + export_dynamic_flag_spec_CXX \ + thread_safe_flag_spec_CXX \ + whole_archive_flag_spec_CXX \ + enable_shared_with_static_runtimes_CXX \ + old_archive_cmds_CXX \ + old_archive_from_new_cmds_CXX \ + predep_objects_CXX \ + postdep_objects_CXX \ + predeps_CXX \ + postdeps_CXX \ + compiler_lib_search_path_CXX \ + compiler_lib_search_dirs_CXX \ + archive_cmds_CXX \ + archive_expsym_cmds_CXX \ + postinstall_cmds_CXX \ + postuninstall_cmds_CXX \ + old_archive_from_expsyms_cmds_CXX \ + allow_undefined_flag_CXX \ + no_undefined_flag_CXX \ + export_symbols_cmds_CXX \ + hardcode_libdir_flag_spec_CXX \ + hardcode_libdir_flag_spec_ld_CXX \ + hardcode_libdir_separator_CXX \ + hardcode_automatic_CXX \ + module_cmds_CXX \ + module_expsym_cmds_CXX \ + lt_cv_prog_compiler_c_o_CXX \ + fix_srcfile_path_CXX \ + exclude_expsyms_CXX \ + include_expsyms_CXX; do + + case $var in + old_archive_cmds_CXX | \ + old_archive_from_new_cmds_CXX | \ + archive_cmds_CXX | \ + archive_expsym_cmds_CXX | \ + module_cmds_CXX | \ + module_expsym_cmds_CXX | \ + old_archive_from_expsyms_cmds_CXX | \ + export_symbols_cmds_CXX | \ + extract_expsyms_cmds | reload_cmds | finish_cmds | \ + postinstall_cmds | postuninstall_cmds | \ + old_postinstall_cmds | old_postuninstall_cmds | \ + sys_lib_search_path_spec | sys_lib_dlsearch_path_spec) + # Double-quote double-evaled strings. + eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\"" + ;; + *) + eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\"" + ;; + esac + done + case $lt_echo in + *'\$0 --fallback-echo"') + lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\$0 --fallback-echo"$/$0 --fallback-echo"/'` + ;; + esac +cfgfile="$ofile" + cat <<__EOF__ >> "$cfgfile" +# ### BEGIN LIBTOOL TAG CONFIG: $tagname +# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: +# Shell to use when invoking shell scripts. +SHELL=$lt_SHELL +# Whether or not to build shared libraries. +build_libtool_libs=$enable_shared +# Whether or not to build static libraries. +build_old_libs=$enable_static +# Whether or not to add -lc for building shared libraries. +build_libtool_need_lc=$archive_cmds_need_lc_CXX +# Whether or not to disallow shared libs when runtime libs are static +allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes_CXX - # Report which library types will actually be built - { $as_echo "$as_me:$LINENO: checking if libtool supports shared libraries" >&5 -$as_echo_n "checking if libtool supports shared libraries... " >&6; } - { $as_echo "$as_me:$LINENO: result: $can_build_shared" >&5 -$as_echo "$can_build_shared" >&6; } +# Whether or not to optimize for fast installation. +fast_install=$enable_fast_install - { $as_echo "$as_me:$LINENO: checking whether to build shared libraries" >&5 -$as_echo_n "checking whether to build shared libraries... " >&6; } - test "$can_build_shared" = "no" && enable_shared=no +# The host system. +host_alias=$host_alias +host=$host +host_os=$host_os - # On AIX, shared libraries and static libraries use the same namespace, and - # are all built from PIC. - case $host_os in - aix3*) - test "$enable_shared" = yes && enable_static=no - if test -n "$RANLIB"; then - archive_cmds="$archive_cmds~\$RANLIB \$lib" - postinstall_cmds='$RANLIB $lib' - fi - ;; +# The build system. +build_alias=$build_alias +build=$build +build_os=$build_os - aix[4-9]*) - if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then - test "$enable_shared" = yes && enable_static=no - fi - ;; - esac - { $as_echo "$as_me:$LINENO: result: $enable_shared" >&5 -$as_echo "$enable_shared" >&6; } +# An echo program that does not interpret backslashes. +echo=$lt_echo - { $as_echo "$as_me:$LINENO: checking whether to build static libraries" >&5 -$as_echo_n "checking whether to build static libraries... " >&6; } - # Make sure either enable_shared or enable_static is yes. - test "$enable_shared" = yes || enable_static=yes - { $as_echo "$as_me:$LINENO: result: $enable_static" >&5 -$as_echo "$enable_static" >&6; } +# The archiver. +AR=$lt_AR +AR_FLAGS=$lt_AR_FLAGS +# A C compiler. +LTCC=$lt_LTCC +# LTCC compiler flags. +LTCFLAGS=$lt_LTCFLAGS +# A language-specific compiler. +CC=$lt_compiler_CXX -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 +# Is the compiler the GNU C compiler? +with_gcc=$GCC_CXX -CC="$lt_save_CC" +# An ERE matcher. +EGREP=$lt_EGREP +# The linker used to build libraries. +LD=$lt_LD_CXX +# Whether we need hard or soft links. +LN_S=$lt_LN_S +# A BSD-compatible nm program. +NM=$lt_NM +# A symbol stripping program +STRIP=$lt_STRIP +# Used to examine libraries when file_magic_cmd begins "file" +MAGIC_CMD=$MAGIC_CMD +# Used on cygwin: DLL creation program. +DLLTOOL="$DLLTOOL" +# Used on cygwin: object dumper. +OBJDUMP="$OBJDUMP" +# Used on cygwin: assembler. +AS="$AS" +# The name of the directory that contains temporary libtool files. +objdir=$objdir +# How to create reloadable object files. +reload_flag=$lt_reload_flag +reload_cmds=$lt_reload_cmds +# How to pass a linker flag through the compiler. +wl=$lt_lt_prog_compiler_wl_CXX +# Object file suffix (normally "o"). +objext="$ac_objext" - ac_config_commands="$ac_config_commands libtool" +# Old archive suffix (normally "a"). +libext="$libext" +# Shared library suffix (normally ".so"). +shrext_cmds='$shrext_cmds' +# Executable file suffix (normally ""). +exeext="$exeext" +# Additional compiler flags for building library objects. +pic_flag=$lt_lt_prog_compiler_pic_CXX +pic_mode=$pic_mode -# Only expand once: +# What is the maximum length of a command? +max_cmd_len=$lt_cv_sys_max_cmd_len +# Does compiler simultaneously support -c and -o options? +compiler_c_o=$lt_lt_cv_prog_compiler_c_o_CXX +# Must we lock files when doing compilation? +need_locks=$lt_need_locks +# Do we need the lib prefix for modules? +need_lib_prefix=$need_lib_prefix -# dolt, a replacement for libtool -# Josh Triplett -# Extract the first word of "bash", so it can be a program name with args. -set dummy bash; 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_DOLT_BASH+set}" = set; then - $as_echo_n "(cached) " >&6 -else - case $DOLT_BASH in - [\\/]* | ?:[\\/]*) - ac_cv_path_DOLT_BASH="$DOLT_BASH" # 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_DOLT_BASH="$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 +# Do we need a version for libraries? +need_version=$need_version - ;; -esac -fi -DOLT_BASH=$ac_cv_path_DOLT_BASH -if test -n "$DOLT_BASH"; then - { $as_echo "$as_me:$LINENO: result: $DOLT_BASH" >&5 -$as_echo "$DOLT_BASH" >&6; } -else - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } -fi +# Whether dlopen is supported. +dlopen_support=$enable_dlopen +# Whether dlopen of programs is supported. +dlopen_self=$enable_dlopen_self -{ $as_echo "$as_me:$LINENO: checking if dolt supports this host" >&5 -$as_echo_n "checking if dolt supports this host... " >&6; } -dolt_supported=yes -if test x$DOLT_BASH = x; then - dolt_supported=no -fi -if test x$GCC != xyes; then - dolt_supported=no -fi -case $host in -i?86-*-linux*|x86_64-*-linux*|powerpc-*-linux* \ -|amd64-*-freebsd*|i?86-*-freebsd*|ia64-*-freebsd*) - pic_options='-fPIC' - ;; -i?86-apple-darwin*) - pic_options='-fno-common' - ;; -*) - dolt_supported=no - ;; -esac -if test x$dolt_supported = xno ; then - { $as_echo "$as_me:$LINENO: result: no, falling back to libtool" >&5 -$as_echo "no, falling back to libtool" >&6; } - LTCOMPILE='$(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(COMPILE)' - LTCXXCOMPILE='$(LIBTOOL) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXXCOMPILE)' -else - { $as_echo "$as_me:$LINENO: result: yes, replacing libtool" >&5 -$as_echo "yes, replacing libtool" >&6; } +# Whether dlopen of statically linked programs is supported. +dlopen_self_static=$enable_dlopen_self_static - cat <<__DOLTCOMPILE__EOF__ >doltcompile -#!$DOLT_BASH -__DOLTCOMPILE__EOF__ - cat <<'__DOLTCOMPILE__EOF__' >>doltcompile -args=("$@") -for ((arg=0; arg<${#args[@]}; arg++)) ; do - if test x"${args[$arg]}" = x-o ; then - objarg=$((arg+1)) - break - fi -done -if test x$objarg = x ; then - echo 'Error: no -o on compiler command line' 1>&2 - exit 1 -fi -lo="${args[$objarg]}" -obj="${lo%.lo}" -if test x"$lo" = x"$obj" ; then - echo "Error: libtool object file name \"$lo\" does not end in .lo" 1>&2 - exit 1 -fi -objbase="${obj##*/}" -__DOLTCOMPILE__EOF__ +# Compiler flag to prevent dynamic linking. +link_static_flag=$lt_lt_prog_compiler_static_CXX - if test x$enable_shared = xyes; then - cat <<'__DOLTCOMPILE__EOF__' >>doltcompile -libobjdir="${obj%$objbase}.libs" -if test ! -d "$libobjdir" ; then - mkdir_out="$(mkdir "$libobjdir" 2>&1)" - mkdir_ret=$? - if test "$mkdir_ret" -ne 0 && test ! -d "$libobjdir" ; then - echo "$mkdir_out" 1>&2 - exit $mkdir_ret - fi -fi -pic_object="$libobjdir/$objbase.o" -args[$objarg]="$pic_object" -__DOLTCOMPILE__EOF__ - cat <<__DOLTCOMPILE__EOF__ >>doltcompile -"\${args[@]}" $pic_options -DPIC || exit \$? -__DOLTCOMPILE__EOF__ - fi +# Compiler flag to turn off builtin functions. +no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag_CXX - if test x$enable_static = xyes; then - cat <<'__DOLTCOMPILE__EOF__' >>doltcompile -non_pic_object="$obj.o" -args[$objarg]="$non_pic_object" -__DOLTCOMPILE__EOF__ - if test x$enable_shared = xyes; then - cat <<'__DOLTCOMPILE__EOF__' >>doltcompile -"${args[@]}" >/dev/null 2>&1 || exit $? -__DOLTCOMPILE__EOF__ - else - cat <<'__DOLTCOMPILE__EOF__' >>doltcompile -"${args[@]}" || exit $? -__DOLTCOMPILE__EOF__ - fi - fi +# Compiler flag to allow reflexive dlopens. +export_dynamic_flag_spec=$lt_export_dynamic_flag_spec_CXX - cat <<'__DOLTCOMPILE__EOF__' >>doltcompile -{ -echo "# $lo - a libtool object file" -echo "# Generated by doltcompile, not libtool" -__DOLTCOMPILE__EOF__ +# Compiler flag to generate shared objects directly from archives. +whole_archive_flag_spec=$lt_whole_archive_flag_spec_CXX - if test x$enable_shared = xyes; then - cat <<'__DOLTCOMPILE__EOF__' >>doltcompile -echo "pic_object='.libs/${objbase}.o'" -__DOLTCOMPILE__EOF__ - else - cat <<'__DOLTCOMPILE__EOF__' >>doltcompile -echo pic_object=none -__DOLTCOMPILE__EOF__ - fi +# Compiler flag to generate thread-safe objects. +thread_safe_flag_spec=$lt_thread_safe_flag_spec_CXX - if test x$enable_static = xyes; then - cat <<'__DOLTCOMPILE__EOF__' >>doltcompile -echo "non_pic_object='${objbase}.o'" -__DOLTCOMPILE__EOF__ - else - cat <<'__DOLTCOMPILE__EOF__' >>doltcompile -echo non_pic_object=none -__DOLTCOMPILE__EOF__ - fi +# Library versioning type. +version_type=$version_type - cat <<'__DOLTCOMPILE__EOF__' >>doltcompile -} > "$lo" -__DOLTCOMPILE__EOF__ +# Format of library name prefix. +libname_spec=$lt_libname_spec - chmod +x doltcompile - LTCOMPILE='$(top_builddir)/doltcompile $(COMPILE)' - LTCXXCOMPILE='$(top_builddir)/doltcompile $(CXXCOMPILE)' +# List of archive names. First name is the real one, the rest are links. +# The last name is the one that the linker finds with -lNAME. +library_names_spec=$lt_library_names_spec - cat <<__DOLTLIBTOOL__EOF__ > doltlibtool -#!$DOLT_BASH -__DOLTLIBTOOL__EOF__ - cat <<'__DOLTLIBTOOL__EOF__' >>doltlibtool -top_builddir_slash="${0%%doltlibtool}" -: ${top_builddir_slash:=./} -args=() -modeok=false -tagok=false -for arg in "$@"; do - case "$arg" in - --mode=compile) modeok=true ;; - --tag=CC|--tag=CXX) tagok=true ;; - *) args[${#args[@]}]="$arg" ;; - esac -done -if $modeok && $tagok ; then - . ${top_builddir_slash}doltcompile "${args[@]}" -else - exec ${top_builddir_slash}libtool "$@" -fi -__DOLTLIBTOOL__EOF__ +# The coded name of the library, if different from the real name. +soname_spec=$lt_soname_spec - chmod +x doltlibtool - LIBTOOL='$(top_builddir)/doltlibtool' -fi +# Commands used to build and install an old-style archive. +RANLIB=$lt_RANLIB +old_archive_cmds=$lt_old_archive_cmds_CXX +old_postinstall_cmds=$lt_old_postinstall_cmds +old_postuninstall_cmds=$lt_old_postuninstall_cmds +# Create an old-style archive from a shared archive. +old_archive_from_new_cmds=$lt_old_archive_from_new_cmds_CXX -# end dolt +# Create a temporary old-style archive to link instead of a shared archive. +old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds_CXX -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 -if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args. -set dummy ${ac_tool_prefix}gcc; 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_prog_CC+set}" = set; then - $as_echo_n "(cached) " >&6 -else - if test -n "$CC"; then - ac_cv_prog_CC="$CC" # Let the user override the test. -else -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_prog_CC="${ac_tool_prefix}gcc" - $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done -done -IFS=$as_save_IFS +# Commands used to build and install a shared archive. +archive_cmds=$lt_archive_cmds_CXX +archive_expsym_cmds=$lt_archive_expsym_cmds_CXX +postinstall_cmds=$lt_postinstall_cmds +postuninstall_cmds=$lt_postuninstall_cmds -fi -fi -CC=$ac_cv_prog_CC -if test -n "$CC"; then - { $as_echo "$as_me:$LINENO: result: $CC" >&5 -$as_echo "$CC" >&6; } -else - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } -fi +# Commands used to build a loadable module (assumed same as above if empty) +module_cmds=$lt_module_cmds_CXX +module_expsym_cmds=$lt_module_expsym_cmds_CXX +# Commands to strip libraries. +old_striplib=$lt_old_striplib +striplib=$lt_striplib -fi -if test -z "$ac_cv_prog_CC"; then - ac_ct_CC=$CC - # Extract the first word of "gcc", so it can be a program name with args. -set dummy gcc; 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_prog_ac_ct_CC+set}" = set; then - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_CC"; then - ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. -else -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_prog_ac_ct_CC="gcc" - $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done -done -IFS=$as_save_IFS +# Dependencies to place before the objects being linked to create a +# shared library. +predep_objects=$lt_predep_objects_CXX -fi -fi -ac_ct_CC=$ac_cv_prog_ac_ct_CC -if test -n "$ac_ct_CC"; then - { $as_echo "$as_me:$LINENO: result: $ac_ct_CC" >&5 -$as_echo "$ac_ct_CC" >&6; } -else - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } -fi +# Dependencies to place after the objects being linked to create a +# shared library. +postdep_objects=$lt_postdep_objects_CXX - if test "x$ac_ct_CC" = x; then - CC="" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - CC=$ac_ct_CC - fi -else - CC="$ac_cv_prog_CC" -fi +# Dependencies to place before the objects being linked to create a +# shared library. +predeps=$lt_predeps_CXX -if test -z "$CC"; then - if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args. -set dummy ${ac_tool_prefix}cc; 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_prog_CC+set}" = set; then - $as_echo_n "(cached) " >&6 -else - if test -n "$CC"; then - ac_cv_prog_CC="$CC" # Let the user override the test. -else -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_prog_CC="${ac_tool_prefix}cc" - $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done -done -IFS=$as_save_IFS +# Dependencies to place after the objects being linked to create a +# shared library. +postdeps=$lt_postdeps_CXX -fi -fi -CC=$ac_cv_prog_CC -if test -n "$CC"; then - { $as_echo "$as_me:$LINENO: result: $CC" >&5 -$as_echo "$CC" >&6; } -else - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } -fi +# The directories searched by this compiler when creating a shared +# library +compiler_lib_search_dirs=$lt_compiler_lib_search_dirs_CXX +# The library search path used internally by the compiler when linking +# a shared library. +compiler_lib_search_path=$lt_compiler_lib_search_path_CXX - fi -fi -if test -z "$CC"; then - # Extract the first word of "cc", so it can be a program name with args. -set dummy cc; 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_prog_CC+set}" = set; then - $as_echo_n "(cached) " >&6 -else - if test -n "$CC"; then - ac_cv_prog_CC="$CC" # Let the user override the test. -else - ac_prog_rejected=no -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 - if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then - ac_prog_rejected=yes - continue - fi - ac_cv_prog_CC="cc" - $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done -done -IFS=$as_save_IFS +# Method to check whether dependent libraries are shared objects. +deplibs_check_method=$lt_deplibs_check_method -if test $ac_prog_rejected = yes; then - # We found a bogon in the path, so make sure we never use it. - set dummy $ac_cv_prog_CC - shift - if test $# != 0; then - # We chose a different compiler from the bogus one. - # However, it has the same basename, so the bogon will be chosen - # first if we set CC to just the basename; use the full file name. - shift - ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@" - fi -fi -fi -fi -CC=$ac_cv_prog_CC -if test -n "$CC"; then - { $as_echo "$as_me:$LINENO: result: $CC" >&5 -$as_echo "$CC" >&6; } -else - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } -fi +# Command to use when deplibs_check_method == file_magic. +file_magic_cmd=$lt_file_magic_cmd +# Flag that allows shared libraries with undefined symbols to be built. +allow_undefined_flag=$lt_allow_undefined_flag_CXX -fi -if test -z "$CC"; then - if test -n "$ac_tool_prefix"; then - for ac_prog in cl.exe - do - # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. -set dummy $ac_tool_prefix$ac_prog; 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_prog_CC+set}" = set; then - $as_echo_n "(cached) " >&6 -else - if test -n "$CC"; then - ac_cv_prog_CC="$CC" # Let the user override the test. -else -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_prog_CC="$ac_tool_prefix$ac_prog" - $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done -done -IFS=$as_save_IFS +# Flag that forces no undefined symbols. +no_undefined_flag=$lt_no_undefined_flag_CXX -fi -fi -CC=$ac_cv_prog_CC -if test -n "$CC"; then - { $as_echo "$as_me:$LINENO: result: $CC" >&5 -$as_echo "$CC" >&6; } -else - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } -fi +# Commands used to finish a libtool library installation in a directory. +finish_cmds=$lt_finish_cmds +# Same as above, but a single script fragment to be evaled but not shown. +finish_eval=$lt_finish_eval - test -n "$CC" && break - done -fi -if test -z "$CC"; then - ac_ct_CC=$CC - for ac_prog in cl.exe -do - # Extract the first word of "$ac_prog", so it can be a program name with args. -set dummy $ac_prog; 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_prog_ac_ct_CC+set}" = set; then - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_CC"; then - ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. -else -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_prog_ac_ct_CC="$ac_prog" - $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done -done -IFS=$as_save_IFS +# Take the output of nm and produce a listing of raw symbols and C names. +global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe -fi -fi -ac_ct_CC=$ac_cv_prog_ac_ct_CC -if test -n "$ac_ct_CC"; then - { $as_echo "$as_me:$LINENO: result: $ac_ct_CC" >&5 -$as_echo "$ac_ct_CC" >&6; } -else - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } -fi +# Transform the output of nm in a proper C declaration +global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl +# Transform the output of nm in a C name address pair +global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address - test -n "$ac_ct_CC" && break -done +# This is the shared library runtime path variable. +runpath_var=$runpath_var - if test "x$ac_ct_CC" = x; then - CC="" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - CC=$ac_ct_CC - fi -fi +# This is the shared library path variable. +shlibpath_var=$shlibpath_var -fi +# Is shlibpath searched before the hard-coded library search path? +shlibpath_overrides_runpath=$shlibpath_overrides_runpath +# How to hardcode a shared library path into an executable. +hardcode_action=$hardcode_action_CXX -test -z "$CC" && { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -{ { $as_echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH -See \`config.log' for more details." >&5 -$as_echo "$as_me: error: no acceptable C compiler found in \$PATH -See \`config.log' for more details." >&2;} - { (exit 1); exit 1; }; }; } +# Whether we should hardcode library paths into libraries. +hardcode_into_libs=$hardcode_into_libs -# Provide some information about the compiler. -$as_echo "$as_me:$LINENO: checking for C compiler version" >&5 -set X $ac_compile -ac_compiler=$2 -{ (ac_try="$ac_compiler --version >&5" -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_compiler --version >&5") 2>&5 - ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } -{ (ac_try="$ac_compiler -v >&5" -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_compiler -v >&5") 2>&5 - ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } -{ (ac_try="$ac_compiler -V >&5" -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_compiler -V >&5") 2>&5 - ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } +# Flag to hardcode \$libdir into a binary during linking. +# This must work even if \$libdir does not exist. +hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec_CXX -{ $as_echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5 -$as_echo_n "checking whether we are using the GNU C compiler... " >&6; } -if test "${ac_cv_c_compiler_gnu+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. */ +# If ld is used when linking, flag to hardcode \$libdir into +# a binary during linking. This must work even if \$libdir does +# not exist. +hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld_CXX -int -main () -{ -#ifndef __GNUC__ - choke me -#endif +# Whether we need a single -rpath flag with a separated argument. +hardcode_libdir_separator=$lt_hardcode_libdir_separator_CXX - ; - 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_compiler_gnu=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 +# Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the +# resulting binary. +hardcode_direct=$hardcode_direct_CXX - ac_compiler_gnu=no -fi +# Set to yes if using the -LDIR flag during linking hardcodes DIR into the +# resulting binary. +hardcode_minus_L=$hardcode_minus_L_CXX -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -ac_cv_c_compiler_gnu=$ac_compiler_gnu +# Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into +# the resulting binary. +hardcode_shlibpath_var=$hardcode_shlibpath_var_CXX -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5 -$as_echo "$ac_cv_c_compiler_gnu" >&6; } -if test $ac_compiler_gnu = yes; then - GCC=yes -else - GCC= -fi -ac_test_CFLAGS=${CFLAGS+set} -ac_save_CFLAGS=$CFLAGS -{ $as_echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5 -$as_echo_n "checking whether $CC accepts -g... " >&6; } -if test "${ac_cv_prog_cc_g+set}" = set; then - $as_echo_n "(cached) " >&6 -else - ac_save_c_werror_flag=$ac_c_werror_flag - ac_c_werror_flag=yes - ac_cv_prog_cc_g=no - CFLAGS="-g" - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ +# Set to yes if building a shared library automatically hardcodes DIR into the library +# and all subsequent libraries and executables linked against it. +hardcode_automatic=$hardcode_automatic_CXX -int -main () -{ +# Variables whose values should be saved in libtool wrapper scripts and +# restored at relink time. +variables_saved_for_relink="$variables_saved_for_relink" - ; - 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_prog_cc_g=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 +# Whether libtool must link a program against all its dependency libraries. +link_all_deplibs=$link_all_deplibs_CXX - CFLAGS="" - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ +# Compile-time system search path for libraries +sys_lib_search_path_spec=$lt_sys_lib_search_path_spec -int -main () -{ +# Run-time system search path for libraries +sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec - ; - 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 - : -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 +# Fix the shell variable \$srcfile for the compiler. +fix_srcfile_path=$lt_fix_srcfile_path - ac_c_werror_flag=$ac_save_c_werror_flag - CFLAGS="-g" - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ +# Set to yes if exported symbols are required. +always_export_symbols=$always_export_symbols_CXX -int -main () -{ +# The commands to list exported symbols. +export_symbols_cmds=$lt_export_symbols_cmds_CXX - ; - 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_prog_cc_g=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 +# The commands to extract the exported symbol list from a shared archive. +extract_expsyms_cmds=$lt_extract_expsyms_cmds +# Symbols that should not be listed in the preloaded symbols. +exclude_expsyms=$lt_exclude_expsyms_CXX -fi +# Symbols that must always be exported. +include_expsyms=$lt_include_expsyms_CXX -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi +# ### END LIBTOOL TAG CONFIG: $tagname + +__EOF__ -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - ac_c_werror_flag=$ac_save_c_werror_flag -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5 -$as_echo "$ac_cv_prog_cc_g" >&6; } -if test "$ac_test_CFLAGS" = set; then - CFLAGS=$ac_save_CFLAGS -elif test $ac_cv_prog_cc_g = yes; then - if test "$GCC" = yes; then - CFLAGS="-g -O2" - else - CFLAGS="-g" - fi else - if test "$GCC" = yes; then - CFLAGS="-O2" - else - CFLAGS= + # If there is no Makefile yet, we rely on a make rule to execute + # `config.status --recheck' to rerun these tests and create the + # libtool script then. + ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'` + if test -f "$ltmain_in"; then + test -f Makefile && make "$ltmain" fi fi -{ $as_echo "$as_me:$LINENO: checking for $CC option to accept ISO C89" >&5 -$as_echo_n "checking for $CC option to accept ISO C89... " >&6; } -if test "${ac_cv_prog_cc_c89+set}" = set; then - $as_echo_n "(cached) " >&6 -else - ac_cv_prog_cc_c89=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 -#include -#include -#include -/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ -struct buf { int x; }; -FILE * (*rcsopen) (struct buf *, struct stat *, int); -static char *e (p, i) - char **p; - int i; -{ - return p[i]; -} -static char *f (char * (*g) (char **, int), char **p, ...) -{ - char *s; - va_list v; - va_start (v,p); - s = g (p, va_arg (v,int)); - va_end (v); - return s; -} -/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has - function prototypes and stuff, but not '\xHH' hex character constants. - These don't provoke an error unfortunately, instead are silently treated - as 'x'. The following induces an error, until -std is added to get - proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an - array size at least. It's necessary to write '\x00'==0 to get something - that's true only with -std. */ -int osf4_cc_array ['\x00' == 0 ? 1 : -1]; -/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters - inside strings and character constants. */ -#define FOO(x) 'x' -int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; +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 -int test (int i, double x); -struct s1 {int (*f) (int a);}; -struct s2 {int (*f) (double a);}; -int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); -int argc; -char **argv; -int -main () -{ -return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; - ; - return 0; -} -_ACEOF -for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ - -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" -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_c89=$ac_arg -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 +CC=$lt_save_CC +LDCXX=$LD +LD=$lt_save_LD +GCC=$lt_save_GCC +with_gnu_ldcxx=$with_gnu_ld +with_gnu_ld=$lt_save_with_gnu_ld +lt_cv_path_LDCXX=$lt_cv_path_LD +lt_cv_path_LD=$lt_save_path_LD +lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld +lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld + else + tagname="" + fi + ;; -fi + F77) + if test -n "$F77" && test "X$F77" != "Xno"; then + +ac_ext=f +ac_compile='$F77 -c $FFLAGS conftest.$ac_ext >&5' +ac_link='$F77 -o conftest$ac_exeext $FFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_f77_compiler_gnu + + +archive_cmds_need_lc_F77=no +allow_undefined_flag_F77= +always_export_symbols_F77=no +archive_expsym_cmds_F77= +export_dynamic_flag_spec_F77= +hardcode_direct_F77=no +hardcode_libdir_flag_spec_F77= +hardcode_libdir_flag_spec_ld_F77= +hardcode_libdir_separator_F77= +hardcode_minus_L_F77=no +hardcode_automatic_F77=no +module_cmds_F77= +module_expsym_cmds_F77= +link_all_deplibs_F77=unknown +old_archive_cmds_F77=$old_archive_cmds +no_undefined_flag_F77= +whole_archive_flag_spec_F77= +enable_shared_with_static_runtimes_F77=no + +# Source file extension for f77 test sources. +ac_ext=f + +# Object file extension for compiled f77 test sources. +objext=o +objext_F77=$objext -rm -f core conftest.err conftest.$ac_objext - test "x$ac_cv_prog_cc_c89" != "xno" && break -done -rm -f conftest.$ac_ext -CC=$ac_save_CC +# Code to be used in simple compile tests +lt_simple_compile_test_code="\ + subroutine t + return + end +" -fi -# AC_CACHE_VAL -case "x$ac_cv_prog_cc_c89" 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_c89" - { $as_echo "$as_me:$LINENO: result: $ac_cv_prog_cc_c89" >&5 -$as_echo "$ac_cv_prog_cc_c89" >&6; } ;; -esac +# Code to be used in simple link tests +lt_simple_link_test_code="\ + program t + end +" +# ltmain only uses $CC for tagged configurations so make sure $CC is set. -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 +# If no C compiler was specified, use CC. +LTCC=${LTCC-"$CC"} -depcc="$CC" am_compiler_list= +# If no C compiler flags were specified, use CFLAGS. +LTCFLAGS=${LTCFLAGS-"$CFLAGS"} -{ $as_echo "$as_me:$LINENO: checking dependency style of $depcc" >&5 -$as_echo_n "checking dependency style of $depcc... " >&6; } -if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then - $as_echo_n "(cached) " >&6 -else - if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then - # We make a subdir and do the tests there. Otherwise we can end up - # making bogus files that we don't know about and never remove. For - # instance it was reported that on HP-UX the gcc test will end up - # making a dummy file named `D' -- because `-MD' means `put the output - # in D'. - mkdir conftest.dir - # Copy depcomp to subdir because otherwise we won't find it if we're - # using a relative directory. - cp "$am_depcomp" conftest.dir - cd conftest.dir - # We will build objects and dependencies in a subdirectory because - # it helps to detect inapplicable dependency modes. For instance - # both Tru64's cc and ICC support -MD to output dependencies as a - # side effect of compilation, but ICC will put the dependencies in - # the current directory while Tru64 will put them in the object - # directory. - mkdir sub +# Allow CC to be a program name with arguments. +compiler=$CC - am_cv_CC_dependencies_compiler_type=none - if test "$am_compiler_list" = ""; then - am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp` - fi - am__universal=false - case " $depcc " in #( - *\ -arch\ *\ -arch\ *) am__universal=true ;; - esac - for depmode in $am_compiler_list; do - # Setup a source with many dependencies, because some compilers - # like to wrap large dependency lists on column 80 (with \), and - # we should not choose a depcomp mode which is confused by this. - # - # We need to recreate these files for each test, as the compiler may - # overwrite some of them when testing with obscure command lines. - # This happens at least with the AIX C compiler. - : > sub/conftest.c - for i in 1 2 3 4 5 6; do - echo '#include "conftst'$i'.h"' >> sub/conftest.c - # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with - # Solaris 8's {/usr,}/bin/sh. - touch sub/conftst$i.h - done - echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf +# save warnings/boilerplate of simple test code +ac_outfile=conftest.$ac_objext +echo "$lt_simple_compile_test_code" >conftest.$ac_ext +eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err +_lt_compiler_boilerplate=`cat conftest.err` +$rm conftest* - # We check with `-c' and `-o' for the sake of the "dashmstdout" - # mode. It turns out that the SunPro C++ compiler does not properly - # handle `-M -o', and we need to detect this. Also, some Intel - # versions had trouble with output in subdirs - am__obj=sub/conftest.${OBJEXT-o} - am__minus_obj="-o $am__obj" - case $depmode in - gcc) - # This depmode causes a compiler race in universal mode. - test "$am__universal" = false || continue - ;; - nosideeffect) - # after this tag, mechanisms are not by side-effect, so they'll - # only be used when explicitly requested - if test "x$enable_dependency_tracking" = xyes; then - continue - else - break - fi - ;; - msvisualcpp | msvcmsys) - # This compiler won't grok `-c -o', but also, the minuso test has - # not run yet. These depmodes are late enough in the game, and - # so weak that their functioning should not be impacted. - am__obj=conftest.${OBJEXT-o} - am__minus_obj= - ;; - none) break ;; - esac - if depmode=$depmode \ - source=sub/conftest.c object=$am__obj \ - depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ - $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \ - >/dev/null 2>conftest.err && - grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 && - grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && - grep $am__obj sub/conftest.Po > /dev/null 2>&1 && - ${MAKE-make} -s -f confmf > /dev/null 2>&1; then - # icc doesn't choke on unknown options, it will just issue warnings - # or remarks (even with -Werror). So we grep stderr for any message - # that says an option was ignored or not supported. - # When given -MP, icc 7.0 and 7.1 complain thusly: - # icc: Command line warning: ignoring option '-M'; no argument required - # The diagnosis changed in icc 8.0: - # icc: Command line remark: option '-MP' not supported - if (grep 'ignoring option' conftest.err || - grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else - am_cv_CC_dependencies_compiler_type=$depmode - break - fi - fi - done +ac_outfile=conftest.$ac_objext +echo "$lt_simple_link_test_code" >conftest.$ac_ext +eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err +_lt_linker_boilerplate=`cat conftest.err` +$rm -r conftest* - cd .. - rm -rf conftest.dir -else - am_cv_CC_dependencies_compiler_type=none -fi -fi -{ $as_echo "$as_me:$LINENO: result: $am_cv_CC_dependencies_compiler_type" >&5 -$as_echo "$am_cv_CC_dependencies_compiler_type" >&6; } -CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type +# Allow CC to be a program name with arguments. +lt_save_CC="$CC" +CC=${F77-"f77"} +compiler=$CC +compiler_F77=$CC +for cc_temp in $compiler""; do + case $cc_temp in + compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; + distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; + \-*) ;; + *) break;; + esac +done +cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` - if - test "x$enable_dependency_tracking" != xno \ - && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then - am__fastdepCC_TRUE= - am__fastdepCC_FALSE='#' -else - am__fastdepCC_TRUE='#' - am__fastdepCC_FALSE= -fi +{ $as_echo "$as_me:$LINENO: checking if libtool supports shared libraries" >&5 +$as_echo_n "checking if libtool supports shared libraries... " >&6; } +{ $as_echo "$as_me:$LINENO: result: $can_build_shared" >&5 +$as_echo "$can_build_shared" >&6; } - { $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 -#include -#include -#include -#include +{ $as_echo "$as_me:$LINENO: checking whether to build shared libraries" >&5 +$as_echo_n "checking whether to build shared libraries... " >&6; } +test "$can_build_shared" = "no" && enable_shared=no -// 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); -} +# On AIX, shared libraries and static libraries use the same namespace, and +# are all built from PIC. +case $host_os in +aix3*) + test "$enable_shared" = yes && enable_static=no + if test -n "$RANLIB"; then + archive_cmds="$archive_cmds~\$RANLIB \$lib" + postinstall_cmds='$RANLIB $lib' + fi + ;; +aix[4-9]*) + if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then + test "$enable_shared" = yes && enable_static=no + fi + ;; +esac +{ $as_echo "$as_me:$LINENO: result: $enable_shared" >&5 +$as_echo "$enable_shared" >&6; } -// 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; +{ $as_echo "$as_me:$LINENO: checking whether to build static libraries" >&5 +$as_echo_n "checking whether to build static libraries... " >&6; } +# Make sure either enable_shared or enable_static is yes. +test "$enable_shared" = yes || enable_static=yes +{ $as_echo "$as_me:$LINENO: result: $enable_static" >&5 +$as_echo "$enable_static" >&6; } -struct incomplete_array -{ - int datasize; - double data[]; -}; +GCC_F77="$G77" +LD_F77="$LD" -struct named_init { - int number; - const wchar_t *name; - double average; -}; +lt_prog_compiler_wl_F77= +lt_prog_compiler_pic_F77= +lt_prog_compiler_static_F77= -typedef const char *ccp; +{ $as_echo "$as_me:$LINENO: checking for $compiler option to produce PIC" >&5 +$as_echo_n "checking for $compiler option to produce PIC... " >&6; } -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; -} + if test "$GCC" = yes; then + lt_prog_compiler_wl_F77='-Wl,' + lt_prog_compiler_static_F77='-static' -// 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); + case $host_os in + aix*) + # All AIX code is PIC. + if test "$host_cpu" = ia64; then + # AIX 5 now supports IA64 processor + lt_prog_compiler_static_F77='-Bstatic' + fi + ;; - const char *str; - int number; - float fnumber; + amigaos*) + # FIXME: we need at least 68020 code to build shared libraries, but + # adding the `-m68020' flag to GCC prevents building anything better, + # like `-m68040'. + lt_prog_compiler_pic_F77='-m68020 -resident32 -malways-restore-a4' + ;; - 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); -} + beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) + # PIC is the default for these OSes. + ;; -int -main () -{ + mingw* | cygwin* | pw32* | os2*) + # This hack is so that the source file can tell whether it is being + # built for inclusion in a dll (and should export symbols for example). + # Although the cygwin gcc ignores -fPIC, still need this for old-style + # (--disable-auto-import) libraries + lt_prog_compiler_pic_F77='-DDLL_EXPORT' + ;; - // Check bool. - _Bool success = false; + darwin* | rhapsody*) + # PIC is the default on this platform + # Common symbols not allowed in MH_DYLIB files + lt_prog_compiler_pic_F77='-fno-common' + ;; - // Check restrict. - if (test_restrict ("String literal") == 0) - success = true; - char *restrict newvar = "Another string"; + interix[3-9]*) + # Interix 3.x gcc -fpic/-fPIC options generate broken code. + # Instead, we relocate shared libraries at runtime. + ;; - // Check varargs. - test_varargs ("s, d' f .", "string", 65, 34.234); - test_varargs_macros (); + msdosdjgpp*) + # Just because we use GCC doesn't mean we suddenly get shared libraries + # on systems that don't support them. + lt_prog_compiler_can_build_shared_F77=no + enable_shared=no + ;; - // 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; + sysv4*MP*) + if test -d /usr/nec; then + lt_prog_compiler_pic_F77=-Kconform_pic + fi + ;; - // Check named initializers. - struct named_init ni = { - .number = 34, - .name = L"Test wide string", - .average = 543.34343, - }; + hpux*) + # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but + # not for PA HP-UX. + case $host_cpu in + hppa*64*|ia64*) + # +Z the default + ;; + *) + lt_prog_compiler_pic_F77='-fPIC' + ;; + esac + ;; - ni.number = 58; + *) + lt_prog_compiler_pic_F77='-fPIC' + ;; + esac + else + # PORTME Check for flag to pass linker flags through the system compiler. + case $host_os in + aix*) + lt_prog_compiler_wl_F77='-Wl,' + if test "$host_cpu" = ia64; then + # AIX 5 now supports IA64 processor + lt_prog_compiler_static_F77='-Bstatic' + else + lt_prog_compiler_static_F77='-bnso -bI:/lib/syscalls.exp' + fi + ;; + darwin*) + # PIC is the default on this platform + # Common symbols not allowed in MH_DYLIB files + case $cc_basename in + xlc*) + lt_prog_compiler_pic_F77='-qnocommon' + lt_prog_compiler_wl_F77='-Wl,' + ;; + esac + ;; - int dynamic_array[ni.number]; - dynamic_array[ni.number - 1] = 543; + mingw* | cygwin* | pw32* | os2*) + # This hack is so that the source file can tell whether it is being + # built for inclusion in a dll (and should export symbols for example). + lt_prog_compiler_pic_F77='-DDLL_EXPORT' + ;; - // work around unused variable warnings - return (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == 'x' - || dynamic_array[ni.number - 1] != 543); + hpux9* | hpux10* | hpux11*) + lt_prog_compiler_wl_F77='-Wl,' + # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but + # not for PA HP-UX. + case $host_cpu in + hppa*64*|ia64*) + # +Z the default + ;; + *) + lt_prog_compiler_pic_F77='+Z' + ;; + esac + # Is there a better lt_prog_compiler_static that works with the bundled CC? + lt_prog_compiler_static_F77='${wl}-a ${wl}archive' + ;; - ; - 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 + irix5* | irix6* | nonstopux*) + lt_prog_compiler_wl_F77='-Wl,' + # PIC (with -KPIC) is the default. + lt_prog_compiler_static_F77='-non_shared' + ;; + newsos6) + lt_prog_compiler_pic_F77='-KPIC' + lt_prog_compiler_static_F77='-Bstatic' + ;; -fi + linux* | k*bsd*-gnu) + case $cc_basename in + icc* | ecc*) + lt_prog_compiler_wl_F77='-Wl,' + lt_prog_compiler_pic_F77='-KPIC' + lt_prog_compiler_static_F77='-static' + ;; + pgcc* | pgf77* | pgf90* | pgf95*) + # Portland Group compilers (*not* the Pentium gcc compiler, + # which looks to be a dead project) + lt_prog_compiler_wl_F77='-Wl,' + lt_prog_compiler_pic_F77='-fpic' + lt_prog_compiler_static_F77='-Bstatic' + ;; + ccc*) + lt_prog_compiler_wl_F77='-Wl,' + # All Alpha code is PIC. + lt_prog_compiler_static_F77='-non_shared' + ;; + *) + case `$CC -V 2>&1 | sed 5q` in + *Sun\ C*) + # Sun C 5.9 + lt_prog_compiler_pic_F77='-KPIC' + lt_prog_compiler_static_F77='-Bstatic' + lt_prog_compiler_wl_F77='-Wl,' + ;; + *Sun\ F*) + # Sun Fortran 8.3 passes all unrecognized flags to the linker + lt_prog_compiler_pic_F77='-KPIC' + lt_prog_compiler_static_F77='-Bstatic' + lt_prog_compiler_wl_F77='' + ;; + esac + ;; + esac + ;; -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 + osf3* | osf4* | osf5*) + lt_prog_compiler_wl_F77='-Wl,' + # All OSF/1 code is PIC. + lt_prog_compiler_static_F77='-non_shared' + ;; -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 + rdos*) + lt_prog_compiler_static_F77='-non_shared' + ;; + + solaris*) + lt_prog_compiler_pic_F77='-KPIC' + lt_prog_compiler_static_F77='-Bstatic' + case $cc_basename in + f77* | f90* | f95*) + lt_prog_compiler_wl_F77='-Qoption ld ';; + *) + lt_prog_compiler_wl_F77='-Wl,';; + esac + ;; + + sunos4*) + lt_prog_compiler_wl_F77='-Qoption ld ' + lt_prog_compiler_pic_F77='-PIC' + lt_prog_compiler_static_F77='-Bstatic' + ;; + sysv4 | sysv4.2uw2* | sysv4.3*) + lt_prog_compiler_wl_F77='-Wl,' + lt_prog_compiler_pic_F77='-KPIC' + lt_prog_compiler_static_F77='-Bstatic' + ;; + sysv4*MP*) + if test -d /usr/nec ;then + lt_prog_compiler_pic_F77='-Kconform_pic' + lt_prog_compiler_static_F77='-Bstatic' + fi + ;; + sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) + lt_prog_compiler_wl_F77='-Wl,' + lt_prog_compiler_pic_F77='-KPIC' + lt_prog_compiler_static_F77='-Bstatic' + ;; + unicos*) + lt_prog_compiler_wl_F77='-Wl,' + lt_prog_compiler_can_build_shared_F77=no + ;; + uts4*) + lt_prog_compiler_pic_F77='-pic' + lt_prog_compiler_static_F77='-Bstatic' + ;; -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" - ;; + *) + lt_prog_compiler_can_build_shared_F77=no + ;; 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 + fi + +{ $as_echo "$as_me:$LINENO: result: $lt_prog_compiler_pic_F77" >&5 +$as_echo "$lt_prog_compiler_pic_F77" >&6; } + +# +# Check to make sure the PIC flag actually works. +# +if test -n "$lt_prog_compiler_pic_F77"; then + +{ $as_echo "$as_me:$LINENO: checking if $compiler PIC flag $lt_prog_compiler_pic_F77 works" >&5 +$as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic_F77 works... " >&6; } +if test "${lt_cv_prog_compiler_pic_works_F77+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 + lt_cv_prog_compiler_pic_works_F77=no + ac_outfile=conftest.$ac_objext + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + lt_compiler_flag="$lt_prog_compiler_pic_F77" + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + # The option is referenced via a variable to avoid confusing sed. + lt_compile=`echo "$ac_compile" | $SED \ + -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:15030: $lt_compile\"" >&5) + (eval "$lt_compile" 2>conftest.err) + ac_status=$? + cat conftest.err >&5 + echo "$as_me:15034: \$? = $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. + $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then + lt_cv_prog_compiler_pic_works_F77=yes + fi + fi + $rm conftest* - ; - 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 +fi +{ $as_echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_pic_works_F77" >&5 +$as_echo "$lt_cv_prog_compiler_pic_works_F77" >&6; } - ac_cv_have_decl___SUNPRO_C=no +if test x"$lt_cv_prog_compiler_pic_works_F77" = xyes; then + case $lt_prog_compiler_pic_F77 in + "" | " "*) ;; + *) lt_prog_compiler_pic_F77=" $lt_prog_compiler_pic_F77" ;; + esac +else + lt_prog_compiler_pic_F77= + lt_prog_compiler_can_build_shared_F77=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 "x$ac_cv_have_decl___SUNPRO_C" = x""yes; then - SUNCC="yes" -else - SUNCC="no" -fi - - if test "x$SUNCC" = "xyes"; then - CWARNFLAGS="-v" - fi -fi - -# Check whether --enable-silent-rules was given. -if test "${enable_silent_rules+set}" = set; then - enableval=$enable_silent_rules; -fi - -case $enable_silent_rules in -yes) AM_DEFAULT_VERBOSITY=0;; -no) AM_DEFAULT_VERBOSITY=1;; -*) AM_DEFAULT_VERBOSITY=0;; +case $host_os in + # For platforms which do not support PIC, -DPIC is meaningless: + *djgpp*) + lt_prog_compiler_pic_F77= + ;; + *) + lt_prog_compiler_pic_F77="$lt_prog_compiler_pic_F77" + ;; esac -AM_BACKSLASH='\' - - - - - - -# 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 +# +# Check to make sure the static flag actually works. +# +wl=$lt_prog_compiler_wl_F77 eval lt_tmp_static_flag=\"$lt_prog_compiler_static_F77\" +{ $as_echo "$as_me:$LINENO: checking if $compiler static flag $lt_tmp_static_flag works" >&5 +$as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; } +if test "${lt_cv_prog_compiler_static_works_F77+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 + lt_cv_prog_compiler_static_works_F77=no + save_LDFLAGS="$LDFLAGS" + LDFLAGS="$LDFLAGS $lt_tmp_static_flag" + echo "$lt_simple_link_test_code" > conftest.$ac_ext + if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then + # The linker can only warn and ignore the option if not recognized + # So say no if there are warnings + if test -s conftest.err; then + # Append any errors to the config.log. + cat conftest.err 1>&5 + $echo "X$_lt_linker_boilerplate" | $Xsed -e '/^$/d' > conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if diff conftest.exp conftest.er2 >/dev/null; then + lt_cv_prog_compiler_static_works_F77=yes + fi + else + lt_cv_prog_compiler_static_works_F77=yes + fi + fi + $rm -r conftest* + LDFLAGS="$save_LDFLAGS" - ac_cv_have_decl___SUNPRO_C=no fi +{ $as_echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_static_works_F77" >&5 +$as_echo "$lt_cv_prog_compiler_static_works_F77" >&6; } -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 "x$ac_cv_have_decl___SUNPRO_C" = x""yes; then - SUNCC="yes" +if test x"$lt_cv_prog_compiler_static_works_F77" = xyes; then + : else - SUNCC="no" + lt_prog_compiler_static_F77= 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 +{ $as_echo "$as_me:$LINENO: checking if $compiler supports -c -o file.$ac_objext" >&5 +$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } +if test "${lt_cv_prog_compiler_c_o_F77+set}" = set; then + $as_echo_n "(cached) " >&6 else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_have_decl___INTEL_COMPILER=no -fi + lt_cv_prog_compiler_c_o_F77=no + $rm -r conftest 2>/dev/null + mkdir conftest + cd conftest + mkdir out + echo "$lt_simple_compile_test_code" > conftest.$ac_ext -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 "x$ac_cv_have_decl___INTEL_COMPILER" = x""yes; then - INTELCC="yes" -else - INTELCC="no" -fi + lt_compiler_flag="-o out/conftest2.$ac_objext" + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + lt_compile=`echo "$ac_compile" | $SED \ + -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:15134: $lt_compile\"" >&5) + (eval "$lt_compile" 2>out/conftest.err) + ac_status=$? + cat out/conftest.err >&5 + echo "$as_me:15138: \$? = $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 + # So say no if there are warnings + $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp + $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 + if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then + lt_cv_prog_compiler_c_o_F77=yes + fi + fi + chmod u+w . 2>&5 + $rm conftest* + # SGI C++ compiler will create directory out/ii_files/ for + # template instantiation + test -d out/ii_files && $rm out/ii_files/* && rmdir out/ii_files + $rm out/* && rmdir out + cd .. + rmdir conftest + $rm conftest* - 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" +{ $as_echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_c_o_F77" >&5 +$as_echo "$lt_cv_prog_compiler_c_o_F77" >&6; } - - -# Check whether --with-release-version was given. -if test "${with_release_version+set}" = set; then - withval=$with_release_version; RELEASE_VERSION="$withval" +hard_links="nottested" +if test "$lt_cv_prog_compiler_c_o_F77" = no && test "$need_locks" != no; then + # do not overwrite the value of need_locks provided by the user + { $as_echo "$as_me:$LINENO: checking if we can lock with hard links" >&5 +$as_echo_n "checking if we can lock with hard links... " >&6; } + hard_links=yes + $rm conftest* + ln conftest.a conftest.b 2>/dev/null && hard_links=no + touch conftest.a + ln conftest.a conftest.b 2>&5 || hard_links=no + ln conftest.a conftest.b 2>/dev/null && hard_links=no + { $as_echo "$as_me:$LINENO: result: $hard_links" >&5 +$as_echo "$hard_links" >&6; } + if test "$hard_links" = no; then + { $as_echo "$as_me:$LINENO: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5 +$as_echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;} + need_locks=warn + fi else - RELEASE_VERSION="" + need_locks=no 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 +{ $as_echo "$as_me:$LINENO: checking whether the $compiler linker ($LD) supports shared libraries" >&5 +$as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; } + runpath_var= + allow_undefined_flag_F77= + enable_shared_with_static_runtimes_F77=no + archive_cmds_F77= + archive_expsym_cmds_F77= + old_archive_From_new_cmds_F77= + old_archive_from_expsyms_cmds_F77= + export_dynamic_flag_spec_F77= + whole_archive_flag_spec_F77= + thread_safe_flag_spec_F77= + hardcode_libdir_flag_spec_F77= + hardcode_libdir_flag_spec_ld_F77= + hardcode_libdir_separator_F77= + hardcode_direct_F77=no + hardcode_minus_L_F77=no + hardcode_shlibpath_var_F77=unsupported + link_all_deplibs_F77=unknown + hardcode_automatic_F77=no + module_cmds_F77= + module_expsym_cmds_F77= + always_export_symbols_F77=no + export_symbols_cmds_F77='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' + # include_expsyms should be a list of space-separated symbols to be *always* + # included in the symbol list + include_expsyms_F77= + # exclude_expsyms can be an extended regexp of symbols to exclude + # it will be wrapped by ` (' and `)$', so one must not match beginning or + # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc', + # as well as any symbol that contains `d'. + exclude_expsyms_F77='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*' + # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out + # platforms (ab)use it in PIC code, but their linkers get confused if + # the symbol is explicitly referenced. Since portable code cannot + # rely on this symbol name, it's probably fine to never include it in + # preloaded symbol tables. + # Exclude shared library initialization/finalization symbols. + extract_expsyms_cmds= + # Just being paranoid about ensuring that cc_basename is set. + for cc_temp in $compiler""; do + case $cc_temp in + compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; + distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; + \-*) ;; + *) break;; + esac +done +cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` + case $host_os in + cygwin* | mingw* | pw32*) + # FIXME: the MSVC++ port hasn't been tested in a loooong time + # When not using gcc, we currently assume that we are using + # Microsoft Visual C++. + if test "$GCC" != yes; then + with_gnu_ld=no + fi + ;; + interix*) + # we just hope/assume this is gcc and not c89 (= MSVC++) + with_gnu_ld=yes + ;; + openbsd*) + with_gnu_ld=no + ;; + esac -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)" + ld_shlibs_F77=yes + if test "$with_gnu_ld" = yes; then + # If archive_cmds runs LD, not CC, wlarc should be empty + wlarc='${wl}' -distcleancheck_listfiles='find . -type f ! -name ChangeLog -print' + # Set some defaults for GNU ld with shared library support. These + # are reset later if shared libraries are not supported. Putting them + # here allows them to be overridden if necessary. + runpath_var=LD_RUN_PATH + hardcode_libdir_flag_spec_F77='${wl}--rpath ${wl}$libdir' + export_dynamic_flag_spec_F77='${wl}--export-dynamic' + # ancient GNU ld didn't support --whole-archive et. al. + if $LD --help 2>&1 | grep 'no-whole-archive' > /dev/null; then + whole_archive_flag_spec_F77="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' + else + whole_archive_flag_spec_F77= + fi + supports_anon_versioning=no + case `$LD -v 2>/dev/null` in + *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11 + *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... + *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... + *\ 2.11.*) ;; # other 2.11 versions + *) supports_anon_versioning=yes ;; + esac + # See if GNU ld supports shared libraries. + case $host_os in + aix[3-9]*) + # On AIX/PPC, the GNU linker is very broken + if test "$host_cpu" != ia64; then + ld_shlibs_F77=no + cat <&2 +*** Warning: the GNU linker, at least up to release 2.9.1, is reported +*** to be unable to reliably create shared libraries on AIX. +*** Therefore, libtool is disabling shared libraries support. If you +*** really care for shared libraries, you may want to modify your PATH +*** so that a non-GNU linker is found, and then restart. +EOF + fi + ;; + amigaos*) + archive_cmds_F77='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' + hardcode_libdir_flag_spec_F77='-L$libdir' + hardcode_minus_L_F77=yes + + # Samuel A. Falvo II reports + # that the semantics of dynamic libraries on AmigaOS, at least up + # to version 4, is to share data among multiple programs linked + # with the same dynamic library. Since this doesn't match the + # behavior of shared libraries on other platforms, we can't use + # them. + ld_shlibs_F77=no + ;; -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 + beos*) + if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then + allow_undefined_flag_F77=unsupported + # Joseph Beckenbach says some releases of gcc + # support --undefined. This deserves some investigation. FIXME + archive_cmds_F77='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + else + ld_shlibs_F77=no + 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 + cygwin* | mingw* | pw32*) + # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, F77) is actually meaningless, + # as there is no search path for DLLs. + hardcode_libdir_flag_spec_F77='-L$libdir' + allow_undefined_flag_F77=unsupported + always_export_symbols_F77=no + enable_shared_with_static_runtimes_F77=yes + export_symbols_cmds_F77='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/'\'' -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols' + + if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then + archive_cmds_F77='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + # If the export-symbols file already is a .def file (1st line + # is EXPORTS), use it as is; otherwise, prepend... + archive_expsym_cmds_F77='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then + cp $export_symbols $output_objdir/$soname.def; + else + echo EXPORTS > $output_objdir/$soname.def; + cat $export_symbols >> $output_objdir/$soname.def; + fi~ + $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + else + ld_shlibs_F77=no + 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 + interix[3-9]*) + hardcode_direct_F77=no + hardcode_shlibpath_var_F77=no + hardcode_libdir_flag_spec_F77='${wl}-rpath,$libdir' + export_dynamic_flag_spec_F77='${wl}-E' + # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. + # Instead, shared libraries are loaded at an image base (0x10000000 by + # default) and relocated if they conflict, which is a slow very memory + # consuming and fragmenting process. To avoid this, we pick a random, + # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link + # time. Moving up from 0x10000000 also allows more sbrk(2) space. + archive_cmds_F77='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + archive_expsym_cmds_F77='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + ;; -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 + gnu* | linux* | k*bsd*-gnu) + if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then + tmp_addflag= + case $cc_basename,$host_cpu in + pgcc*) # Portland Group C compiler + whole_archive_flag_spec_F77='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' + tmp_addflag=' $pic_flag' + ;; + pgf77* | pgf90* | pgf95*) # Portland Group f77 and f90 compilers + whole_archive_flag_spec_F77='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' + tmp_addflag=' $pic_flag -Mnomain' ;; + ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 + tmp_addflag=' -i_dynamic' ;; + efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 + tmp_addflag=' -i_dynamic -nofor_main' ;; + ifc* | ifort*) # Intel Fortran compiler + tmp_addflag=' -nofor_main' ;; + esac + case `$CC -V 2>&1 | sed 5q` in + *Sun\ C*) # Sun C 5.9 + whole_archive_flag_spec_F77='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' + tmp_sharedflag='-G' ;; + *Sun\ F*) # Sun Fortran 8.3 + tmp_sharedflag='-G' ;; + *) + tmp_sharedflag='-shared' ;; + esac + archive_cmds_F77='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' -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 $supports_anon_versioning = yes; then + archive_expsym_cmds_F77='$echo "{ global:" > $output_objdir/$libname.ver~ + cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ + $echo "local: *; };" >> $output_objdir/$libname.ver~ + $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' + fi + else + ld_shlibs_F77=no + 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 + netbsd*) + if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then + archive_cmds_F77='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' + wlarc= + else + archive_cmds_F77='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds_F77='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + fi + ;; + solaris*) + if $LD -v 2>&1 | grep 'BFD 2\.8' > /dev/null; then + ld_shlibs_F77=no + cat <&2 +*** Warning: The releases 2.8.* of the GNU linker cannot reliably +*** create shared libraries on Solaris systems. Therefore, libtool +*** is disabling shared libraries support. We urge you to upgrade GNU +*** binutils to release 2.9.1 or newer. Another option is to modify +*** your PATH or compiler configuration so that the native linker is +*** used, and then restart. +EOF + elif $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then + archive_cmds_F77='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds_F77='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + else + ld_shlibs_F77=no + fi + ;; + sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*) + case `$LD -v 2>&1` in + *\ [01].* | *\ 2.[0-9].* | *\ 2.1[0-5].*) + ld_shlibs_F77=no + cat <<_LT_EOF 1>&2 +*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not +*** reliably create shared libraries on SCO systems. Therefore, libtool +*** is disabling shared libraries support. We urge you to upgrade GNU +*** binutils to release 2.16.91.0.3 or newer. Another option is to modify +*** your PATH or compiler configuration so that the native linker is +*** used, and then restart. +_LT_EOF + ;; + *) + if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then + hardcode_libdir_flag_spec_F77='`test -z "$SCOABSPATH" && echo ${wl}-rpath,$libdir`' + archive_cmds_F77='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib' + archive_expsym_cmds_F77='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname,\${SCOABSPATH:+${install_libdir}/}$soname,-retain-symbols-file,$export_symbols -o $lib' + else + ld_shlibs_F77=no + fi + ;; + esac + ;; + sunos4*) + archive_cmds_F77='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' + wlarc= + hardcode_direct_F77=yes + hardcode_shlibpath_var_F77=no + ;; + *) + if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then + archive_cmds_F77='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds_F77='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + else + ld_shlibs_F77=no + fi + ;; + esac + if test "$ld_shlibs_F77" = no; then + runpath_var= + hardcode_libdir_flag_spec_F77= + export_dynamic_flag_spec_F77= + whole_archive_flag_spec_F77= + fi + else + # PORTME fill in a description of your system's linker (not GNU ld) + case $host_os in + aix3*) + allow_undefined_flag_F77=unsupported + always_export_symbols_F77=yes + archive_expsym_cmds_F77='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname' + # Note: this linker hardcodes the directories in LIBPATH if there + # are no directories specified by -L. + hardcode_minus_L_F77=yes + if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then + # Neither direct hardcoding nor static linking is supported with a + # broken collect2. + hardcode_direct_F77=unsupported + fi + ;; + aix[4-9]*) + if test "$host_cpu" = ia64; then + # On IA64, the linker does run time linking by default, so we don't + # have to do anything special. + aix_use_runtimelinking=no + exp_sym_flag='-Bexport' + no_entry_flag="" + else + # If we're using GNU nm, then we don't want the "-C" option. + # -C means demangle to AIX nm, but means don't demangle with GNU nm + if $NM -V 2>&1 | grep 'GNU' > /dev/null; then + export_symbols_cmds_F77='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$2 == "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print \$3 } }'\'' | sort -u > $export_symbols' + else + export_symbols_cmds_F77='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$2 == "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print \$3 } }'\'' | sort -u > $export_symbols' + fi + aix_use_runtimelinking=no + # Test if we are trying to use run time linking or normal + # AIX style linking. If -brtl is somewhere in LDFLAGS, we + # need to do runtime linking. + case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*) + for ld_flag in $LDFLAGS; do + if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then + aix_use_runtimelinking=yes + break + fi + done + ;; + esac + exp_sym_flag='-bexport' + no_entry_flag='-bnoentry' + fi + # When large executables or shared objects are built, AIX ld can + # have problems creating the table of contents. If linking a library + # or program results in "error TOC overflow" add -mminimal-toc to + # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not + # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. + archive_cmds_F77='' + hardcode_direct_F77=yes + hardcode_libdir_separator_F77=':' + link_all_deplibs_F77=yes + if test "$GCC" = yes; then + case $host_os in aix4.[012]|aix4.[012].*) + # We only want to do this on AIX 4.2 and lower, the check + # below for broken collect2 doesn't work under 4.3+ + collect2name=`${CC} -print-prog-name=collect2` + if test -f "$collect2name" && \ + strings "$collect2name" | grep resolve_lib_name >/dev/null + then + # We have reworked collect2 + : + else + # We have old collect2 + hardcode_direct_F77=unsupported + # It fails to find uninstalled libraries when the uninstalled + # path is not listed in the libpath. Setting hardcode_minus_L + # to unsupported forces relinking + hardcode_minus_L_F77=yes + hardcode_libdir_flag_spec_F77='-L$libdir' + hardcode_libdir_separator_F77= + fi + ;; + esac + shared_flag='-shared' + if test "$aix_use_runtimelinking" = yes; then + shared_flag="$shared_flag "'${wl}-G' + fi + else + # not using gcc + if test "$host_cpu" = ia64; then + # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release + # chokes on -Wl,-G. The following line is correct: + shared_flag='-G' + else + if test "$aix_use_runtimelinking" = yes; then + shared_flag='${wl}-G' + else + shared_flag='${wl}-bM:SRE' + fi + fi + fi + # It seems that -bexpall does not export symbols beginning with + # underscore (_), so it is better to generate a list of symbols to export. + always_export_symbols_F77=yes + if test "$aix_use_runtimelinking" = yes; then + # Warning - without using the other runtime loading flags (-brtl), + # -berok will link without error, but may produce a broken library. + allow_undefined_flag_F77='-berok' + # Determine the default libpath from the value encoded in an empty executable. + cat >conftest.$ac_ext <<_ACEOF + program main -if test x"$CC_FOR_BUILD" = x; then - if test x"$cross_compiling" = xyes; then - for ac_prog in gcc cc -do - # Extract the first word of "$ac_prog", so it can be a program name with args. -set dummy $ac_prog; 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_prog_CC_FOR_BUILD+set}" = set; then - $as_echo_n "(cached) " >&6 -else - if test -n "$CC_FOR_BUILD"; then - ac_cv_prog_CC_FOR_BUILD="$CC_FOR_BUILD" # Let the user override the test. -else -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_prog_CC_FOR_BUILD="$ac_prog" - $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done -done -IFS=$as_save_IFS + end +_ACEOF +rm -f conftest.$ac_objext 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>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_f77_werror_flag" || + test ! -s conftest.err + } && test -s conftest$ac_exeext && { + test "$cross_compiling" = yes || + $as_test_x conftest$ac_exeext + }; then +lt_aix_libpath_sed=' + /Import File Strings/,/^$/ { + /^0/ { + s/^0 *\(.*\)$/\1/ + p + } + }' +aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` +# Check for a 64-bit object if we didn't find anything. +if test -z "$aix_libpath"; then + aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` fi -fi -CC_FOR_BUILD=$ac_cv_prog_CC_FOR_BUILD -if test -n "$CC_FOR_BUILD"; then - { $as_echo "$as_me:$LINENO: result: $CC_FOR_BUILD" >&5 -$as_echo "$CC_FOR_BUILD" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } -fi - + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 - test -n "$CC_FOR_BUILD" && break -done - else - CC_FOR_BUILD="$CC" - fi fi +rm -rf conftest.dSYM +rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ + conftest$ac_exeext conftest.$ac_ext +if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi + hardcode_libdir_flag_spec_F77='${wl}-blibpath:$libdir:'"$aix_libpath" + archive_expsym_cmds_F77="\$CC"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag" + else + if test "$host_cpu" = ia64; then + hardcode_libdir_flag_spec_F77='${wl}-R $libdir:/usr/lib:/lib' + allow_undefined_flag_F77="-z nodefs" + archive_expsym_cmds_F77="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols" + else + # Determine the default libpath from the value encoded in an empty executable. + cat >conftest.$ac_ext <<_ACEOF + program main - -for ac_prog in cpp -do - # Extract the first word of "$ac_prog", so it can be a program name with args. -set dummy $ac_prog; 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_RAWCPP+set}" = set; then - $as_echo_n "(cached) " >&6 -else - case $RAWCPP in - [\\/]* | ?:[\\/]*) - ac_cv_path_RAWCPP="$RAWCPP" # Let the user override the test with a path. - ;; - *) - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -as_dummy="$PATH:/bin:/usr/bin:/usr/lib:/usr/libexec:/usr/ccs/lib:/usr/ccs/lbin:/lib" -for as_dir in $as_dummy -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_RAWCPP="$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 - - ;; + end +_ACEOF +rm -f conftest.$ac_objext 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>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_f77_werror_flag" || + test ! -s conftest.err + } && test -s conftest$ac_exeext && { + test "$cross_compiling" = yes || + $as_test_x conftest$ac_exeext + }; then + +lt_aix_libpath_sed=' + /Import File Strings/,/^$/ { + /^0/ { + s/^0 *\(.*\)$/\1/ + p + } + }' +aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` +# Check for a 64-bit object if we didn't find anything. +if test -z "$aix_libpath"; then + aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` fi -RAWCPP=$ac_cv_path_RAWCPP -if test -n "$RAWCPP"; then - { $as_echo "$as_me:$LINENO: result: $RAWCPP" >&5 -$as_echo "$RAWCPP" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } -fi - - - test -n "$RAWCPP" && break -done -test -n "$RAWCPP" || RAWCPP="${CPP}" + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 -# Check for flag to avoid builtin definitions - assumes unix is predefined, -# which is not the best choice for supporting other OS'es, but covers most -# of the ones we need for now. -{ $as_echo "$as_me:$LINENO: checking if $RAWCPP requires -undef" >&5 -$as_echo_n "checking if $RAWCPP requires -undef... " >&6; } -cat >conftest.$ac_ext <<_ACEOF -Does cpp redefine unix ? -_ACEOF -if test `${RAWCPP} < conftest.$ac_ext | grep -c 'unix'` -eq 1 ; then - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } -else - if test `${RAWCPP} -undef < conftest.$ac_ext | grep -c 'unix'` -eq 1 ; then - RAWCPPFLAGS=-undef - { $as_echo "$as_me:$LINENO: result: yes" >&5 -$as_echo "yes" >&6; } - # under Cygwin unix is still defined even with -undef - elif test `${RAWCPP} -undef -ansi < conftest.$ac_ext | grep -c 'unix'` -eq 1 ; then - RAWCPPFLAGS="-undef -ansi" - { $as_echo "$as_me:$LINENO: result: yes, with -ansi" >&5 -$as_echo "yes, with -ansi" >&6; } - else - { { $as_echo "$as_me:$LINENO: error: ${RAWCPP} defines unix with or without -undef. I don't know what to do." >&5 -$as_echo "$as_me: error: ${RAWCPP} defines unix with or without -undef. I don't know what to do." >&2;} - { (exit 1); exit 1; }; } - fi fi -rm -f conftest.$ac_ext -{ $as_echo "$as_me:$LINENO: checking if $RAWCPP requires -traditional" >&5 -$as_echo_n "checking if $RAWCPP requires -traditional... " >&6; } -cat >conftest.$ac_ext <<_ACEOF -Does cpp preserve "whitespace"? -_ACEOF -if test `${RAWCPP} < conftest.$ac_ext | grep -c 'preserve \"'` -eq 1 ; then - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } -else - if test `${RAWCPP} -traditional < conftest.$ac_ext | grep -c 'preserve \"'` -eq 1 ; then - RAWCPPFLAGS="${RAWCPPFLAGS} -traditional" - { $as_echo "$as_me:$LINENO: result: yes" >&5 -$as_echo "yes" >&6; } - else - { { $as_echo "$as_me:$LINENO: error: ${RAWCPP} does not preserve whitespace with or without -traditional. I don't know what to do." >&5 -$as_echo "$as_me: error: ${RAWCPP} does not preserve whitespace with or without -traditional. I don't know what to do." >&2;} - { (exit 1); exit 1; }; } - fi -fi -rm -f conftest.$ac_ext +rm -rf conftest.dSYM +rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ + conftest$ac_exeext conftest.$ac_ext +if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi + hardcode_libdir_flag_spec_F77='${wl}-blibpath:$libdir:'"$aix_libpath" + # Warning - without using the other run time loading flags, + # -berok will link without error, but may produce a broken library. + no_undefined_flag_F77=' ${wl}-bernotok' + allow_undefined_flag_F77=' ${wl}-berok' + # Exported symbols can be pulled into shared objects from archives + whole_archive_flag_spec_F77='$convenience' + archive_cmds_need_lc_F77=yes + # This is similar to how AIX traditionally builds its shared libraries. + archive_expsym_cmds_F77="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' + fi + fi + ;; + amigaos*) + archive_cmds_F77='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' + hardcode_libdir_flag_spec_F77='-L$libdir' + hardcode_minus_L_F77=yes + # see comment about different semantics on the GNU ld section + ld_shlibs_F77=no + ;; -# Find perl for "make check" tests in nls/localerules.in + bsdi[45]*) + export_dynamic_flag_spec_F77=-rdynamic + ;; -# Check whether --with-perl was given. -if test "${with_perl+set}" = set; then - withval=$with_perl; PERL=$withval ; { $as_echo "$as_me:$LINENO: checking perl" >&5 -$as_echo_n "checking perl... " >&6; } ; - { $as_echo "$as_me:$LINENO: result: (from --with-perl) $PERL" >&5 -$as_echo "(from --with-perl) $PERL" >&6; } -else - for ac_prog in perl -do - # Extract the first word of "$ac_prog", so it can be a program name with args. -set dummy $ac_prog; 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_prog_PERL+set}" = set; then - $as_echo_n "(cached) " >&6 -else - if test -n "$PERL"; then - ac_cv_prog_PERL="$PERL" # Let the user override the test. -else -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_prog_PERL="$ac_prog" - $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done -done -IFS=$as_save_IFS + cygwin* | mingw* | pw32*) + # When not using gcc, we currently assume that we are using + # Microsoft Visual C++. + # hardcode_libdir_flag_spec is actually meaningless, as there is + # no search path for DLLs. + hardcode_libdir_flag_spec_F77=' ' + allow_undefined_flag_F77=unsupported + # Tell ltmain to make .lib files, not .a files. + libext=lib + # Tell ltmain to make .dll files, not .so files. + shrext_cmds=".dll" + # FIXME: Setting linknames here is a bad hack. + archive_cmds_F77='$CC -o $lib $libobjs $compiler_flags `echo "$deplibs" | $SED -e '\''s/ -lc$//'\''` -link -dll~linknames=' + # The linker will automatically build a .lib file if we build a DLL. + old_archive_From_new_cmds_F77='true' + # FIXME: Should let the user specify the lib program. + old_archive_cmds_F77='lib -OUT:$oldlib$oldobjs$old_deplibs' + fix_srcfile_path_F77='`cygpath -w "$srcfile"`' + enable_shared_with_static_runtimes_F77=yes + ;; -fi -fi -PERL=$ac_cv_prog_PERL -if test -n "$PERL"; then - { $as_echo "$as_me:$LINENO: result: $PERL" >&5 -$as_echo "$PERL" >&6; } -else - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } -fi + darwin* | rhapsody*) + case $host_os in + rhapsody* | darwin1.[012]) + allow_undefined_flag_F77='${wl}-undefined ${wl}suppress' + ;; + *) # Darwin 1.3 on + if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then + allow_undefined_flag_F77='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' + else + case ${MACOSX_DEPLOYMENT_TARGET} in + 10.[012]) + allow_undefined_flag_F77='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' + ;; + 10.*) + allow_undefined_flag_F77='${wl}-undefined ${wl}dynamic_lookup' + ;; + esac + fi + ;; + esac + archive_cmds_need_lc_F77=no + hardcode_direct_F77=no + hardcode_automatic_F77=yes + hardcode_shlibpath_var_F77=unsupported + whole_archive_flag_spec_F77='' + link_all_deplibs_F77=yes + if test "$GCC" = yes ; then + output_verbose_link_cmd='echo' + archive_cmds_F77="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}" + module_cmds_F77="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}" + archive_expsym_cmds_F77="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}" + module_expsym_cmds_F77="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}" + else + case $cc_basename in + xlc*) + output_verbose_link_cmd='echo' + archive_cmds_F77='$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $xlcverstring' + module_cmds_F77='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags' + # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds + archive_expsym_cmds_F77='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $xlcverstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' + module_expsym_cmds_F77='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' + ;; + *) + ld_shlibs_F77=no + ;; + esac + fi + ;; + dgux*) + archive_cmds_F77='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_libdir_flag_spec_F77='-L$libdir' + hardcode_shlibpath_var_F77=no + ;; - test -n "$PERL" && break -done -test -n "$PERL" || PERL="no" + freebsd1*) + ld_shlibs_F77=no + ;; -fi + # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor + # support. Future versions do this automatically, but an explicit c++rt0.o + # does not break anything, and helps significantly (at the cost of a little + # extra space). + freebsd2.2*) + archive_cmds_F77='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' + hardcode_libdir_flag_spec_F77='-R$libdir' + hardcode_direct_F77=yes + hardcode_shlibpath_var_F77=no + ;; - if test x$PERL != xno; then - HAVE_PERL_TRUE= - HAVE_PERL_FALSE='#' -else - HAVE_PERL_TRUE='#' - HAVE_PERL_FALSE= -fi + # Unfortunately, older versions of FreeBSD 2 do not have this feature. + freebsd2*) + archive_cmds_F77='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' + hardcode_direct_F77=yes + hardcode_minus_L_F77=yes + hardcode_shlibpath_var_F77=no + ;; + # FreeBSD 3 and greater uses gcc -shared to do shared libraries. + freebsd* | dragonfly*) + archive_cmds_F77='$CC -shared -o $lib $libobjs $deplibs $compiler_flags' + hardcode_libdir_flag_spec_F77='-R$libdir' + hardcode_direct_F77=yes + hardcode_shlibpath_var_F77=no + ;; -# Build with XCB support? + hpux9*) + if test "$GCC" = yes; then + archive_cmds_F77='$rm $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' + else + archive_cmds_F77='$rm $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' + fi + hardcode_libdir_flag_spec_F77='${wl}+b ${wl}$libdir' + hardcode_libdir_separator_F77=: + hardcode_direct_F77=yes -# Check whether --with-xcb was given. -if test "${with_xcb+set}" = set; then - withval=$with_xcb; ac_cv_use_xcb=$withval -else - ac_cv_use_xcb=yes -fi + # hardcode_minus_L: Not really in the search PATH, + # but as the default location of the library. + hardcode_minus_L_F77=yes + export_dynamic_flag_spec_F77='${wl}-E' + ;; -{ $as_echo "$as_me:$LINENO: checking whether to use XCB" >&5 -$as_echo_n "checking whether to use XCB... " >&6; } -if test "${ac_cv_use_xcb+set}" = set; then - $as_echo_n "(cached) " >&6 -else - ac_cv_use_xcb=yes -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_use_xcb" >&5 -$as_echo "$ac_cv_use_xcb" >&6; } - if test x$ac_cv_use_xcb != xno; then - XCB_TRUE= - XCB_FALSE='#' -else - XCB_TRUE='#' - XCB_FALSE= -fi + hpux10*) + if test "$GCC" = yes -a "$with_gnu_ld" = no; then + archive_cmds_F77='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' + else + archive_cmds_F77='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' + fi + if test "$with_gnu_ld" = no; then + hardcode_libdir_flag_spec_F77='${wl}+b ${wl}$libdir' + hardcode_libdir_separator_F77=: + hardcode_direct_F77=yes + export_dynamic_flag_spec_F77='${wl}-E' -# Checks for pkg-config packages + # hardcode_minus_L: Not really in the search PATH, + # but as the default location of the library. + hardcode_minus_L_F77=yes + fi + ;; + hpux11*) + if test "$GCC" = yes -a "$with_gnu_ld" = no; then + case $host_cpu in + hppa*64*) + archive_cmds_F77='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + ia64*) + archive_cmds_F77='$CC -shared ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' + ;; + *) + archive_cmds_F77='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' + ;; + esac + else + case $host_cpu in + hppa*64*) + archive_cmds_F77='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + ia64*) + archive_cmds_F77='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' + ;; + *) + archive_cmds_F77='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' + ;; + esac + fi + if test "$with_gnu_ld" = no; then + hardcode_libdir_flag_spec_F77='${wl}+b ${wl}$libdir' + hardcode_libdir_separator_F77=: -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 + case $host_cpu in + hppa*64*|ia64*) + hardcode_libdir_flag_spec_ld_F77='+b $libdir' + hardcode_direct_F77=no + hardcode_shlibpath_var_F77=no + ;; + *) + hardcode_direct_F77=yes + export_dynamic_flag_spec_F77='${wl}-E' - ;; -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 + # hardcode_minus_L: Not really in the search PATH, + # but as the default location of the library. + hardcode_minus_L_F77=yes + ;; + esac + fi + ;; + irix5* | irix6* | nonstopux*) + if test "$GCC" = yes; then + archive_cmds_F77='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + else + archive_cmds_F77='$LD -shared $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' + hardcode_libdir_flag_spec_ld_F77='-rpath $libdir' + fi + hardcode_libdir_flag_spec_F77='${wl}-rpath ${wl}$libdir' + hardcode_libdir_separator_F77=: + link_all_deplibs_F77=yes + ;; -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 + netbsd*) + if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then + archive_cmds_F77='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out + else + archive_cmds_F77='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF + fi + hardcode_libdir_flag_spec_F77='-R$libdir' + hardcode_direct_F77=yes + hardcode_shlibpath_var_F77=no + ;; - ;; -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 + newsos6) + archive_cmds_F77='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_direct_F77=yes + hardcode_libdir_flag_spec_F77='${wl}-rpath ${wl}$libdir' + hardcode_libdir_separator_F77=: + hardcode_shlibpath_var_F77=no + ;; - 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: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&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; } + openbsd*) + if test -f /usr/libexec/ld.so; then + hardcode_direct_F77=yes + hardcode_shlibpath_var_F77=no + if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then + archive_cmds_F77='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds_F77='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols' + hardcode_libdir_flag_spec_F77='${wl}-rpath,$libdir' + export_dynamic_flag_spec_F77='${wl}-E' 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 XPROTO" >&5 -$as_echo_n "checking for XPROTO... " >&6; } - -if test -n "$XPROTO_CFLAGS"; then - pkg_cv_XPROTO_CFLAGS="$XPROTO_CFLAGS" - elif test -n "$PKG_CONFIG"; then - if test -n "$PKG_CONFIG" && \ - { ($as_echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \"xproto >= 7.0.13\"") >&5 - ($PKG_CONFIG --exists --print-errors "xproto >= 7.0.13") 2>&5 - ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; then - pkg_cv_XPROTO_CFLAGS=`$PKG_CONFIG --cflags "xproto >= 7.0.13" 2>/dev/null` -else - pkg_failed=yes -fi - else - pkg_failed=untried -fi -if test -n "$XPROTO_LIBS"; then - pkg_cv_XPROTO_LIBS="$XPROTO_LIBS" - elif test -n "$PKG_CONFIG"; then - if test -n "$PKG_CONFIG" && \ - { ($as_echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \"xproto >= 7.0.13\"") >&5 - ($PKG_CONFIG --exists --print-errors "xproto >= 7.0.13") 2>&5 - ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; then - pkg_cv_XPROTO_LIBS=`$PKG_CONFIG --libs "xproto >= 7.0.13" 2>/dev/null` -else - pkg_failed=yes -fi - else - pkg_failed=untried -fi + case $host_os in + openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*) + archive_cmds_F77='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' + hardcode_libdir_flag_spec_F77='-R$libdir' + ;; + *) + archive_cmds_F77='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' + hardcode_libdir_flag_spec_F77='${wl}-rpath,$libdir' + ;; + esac + fi + else + ld_shlibs_F77=no + fi + ;; + os2*) + hardcode_libdir_flag_spec_F77='-L$libdir' + hardcode_minus_L_F77=yes + allow_undefined_flag_F77=unsupported + archive_cmds_F77='$echo "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$echo "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~$echo DATA >> $output_objdir/$libname.def~$echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~$echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def' + old_archive_From_new_cmds_F77='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def' + ;; + osf3*) + if test "$GCC" = yes; then + allow_undefined_flag_F77=' ${wl}-expect_unresolved ${wl}\*' + archive_cmds_F77='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + else + allow_undefined_flag_F77=' -expect_unresolved \*' + archive_cmds_F77='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' + fi + hardcode_libdir_flag_spec_F77='${wl}-rpath ${wl}$libdir' + hardcode_libdir_separator_F77=: + ;; -if test $pkg_failed = yes; then + osf4* | osf5*) # as osf3* with the addition of -msym flag + if test "$GCC" = yes; then + allow_undefined_flag_F77=' ${wl}-expect_unresolved ${wl}\*' + archive_cmds_F77='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + hardcode_libdir_flag_spec_F77='${wl}-rpath ${wl}$libdir' + else + allow_undefined_flag_F77=' -expect_unresolved \*' + archive_cmds_F77='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -msym -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' + archive_expsym_cmds_F77='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; echo "-hidden">> $lib.exp~ + $LD -shared${allow_undefined_flag} -input $lib.exp $linker_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib~$rm $lib.exp' -if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then - _pkg_short_errors_supported=yes -else - _pkg_short_errors_supported=no -fi - if test $_pkg_short_errors_supported = yes; then - XPROTO_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "xproto >= 7.0.13" 2>&1` - else - XPROTO_PKG_ERRORS=`$PKG_CONFIG --print-errors "xproto >= 7.0.13" 2>&1` - fi - # Put the nasty error message in config.log where it belongs - echo "$XPROTO_PKG_ERRORS" >&5 + # Both c and cxx compiler support -rpath directly + hardcode_libdir_flag_spec_F77='-rpath $libdir' + fi + hardcode_libdir_separator_F77=: + ;; - { { $as_echo "$as_me:$LINENO: error: Package requirements (xproto >= 7.0.13) were not met: + solaris*) + no_undefined_flag_F77=' -z text' + if test "$GCC" = yes; then + wlarc='${wl}' + archive_cmds_F77='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds_F77='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ + $CC -shared ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$rm $lib.exp' + else + wlarc='' + archive_cmds_F77='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' + archive_expsym_cmds_F77='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ + $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp' + fi + hardcode_libdir_flag_spec_F77='-R$libdir' + hardcode_shlibpath_var_F77=no + case $host_os in + solaris2.[0-5] | solaris2.[0-5].*) ;; + *) + # The compiler driver will combine and reorder linker options, + # but understands `-z linker_flag'. GCC discards it without `$wl', + # but is careful enough not to reorder. + # Supported since Solaris 2.6 (maybe 2.5.1?) + if test "$GCC" = yes; then + whole_archive_flag_spec_F77='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' + else + whole_archive_flag_spec_F77='-z allextract$convenience -z defaultextract' + fi + ;; + esac + link_all_deplibs_F77=yes + ;; -$XPROTO_PKG_ERRORS + sunos4*) + if test "x$host_vendor" = xsequent; then + # Use $CC to link under sequent, because it throws in some extra .o + # files that make .init and .fini sections work. + archive_cmds_F77='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags' + else + archive_cmds_F77='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' + fi + hardcode_libdir_flag_spec_F77='-L$libdir' + hardcode_direct_F77=yes + hardcode_minus_L_F77=yes + hardcode_shlibpath_var_F77=no + ;; -Consider adjusting the PKG_CONFIG_PATH environment variable if you -installed software in a non-standard prefix. + sysv4) + case $host_vendor in + sni) + archive_cmds_F77='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_direct_F77=yes # is this really true??? + ;; + siemens) + ## LD is ld it makes a PLAMLIB + ## CC just makes a GrossModule. + archive_cmds_F77='$LD -G -o $lib $libobjs $deplibs $linker_flags' + reload_cmds_F77='$CC -r -o $output$reload_objs' + hardcode_direct_F77=no + ;; + motorola) + archive_cmds_F77='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_direct_F77=no #Motorola manual says yes, but my tests say they lie + ;; + esac + runpath_var='LD_RUN_PATH' + hardcode_shlibpath_var_F77=no + ;; -Alternatively, you may set the environment variables XPROTO_CFLAGS -and XPROTO_LIBS to avoid the need to call pkg-config. -See the pkg-config man page for more details. -" >&5 -$as_echo "$as_me: error: Package requirements (xproto >= 7.0.13) were not met: + sysv4.3*) + archive_cmds_F77='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_shlibpath_var_F77=no + export_dynamic_flag_spec_F77='-Bexport' + ;; -$XPROTO_PKG_ERRORS + sysv4*MP*) + if test -d /usr/nec; then + archive_cmds_F77='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_shlibpath_var_F77=no + runpath_var=LD_RUN_PATH + hardcode_runpath_var=yes + ld_shlibs_F77=yes + fi + ;; -Consider adjusting the PKG_CONFIG_PATH environment variable if you -installed software in a non-standard prefix. + sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*) + no_undefined_flag_F77='${wl}-z,text' + archive_cmds_need_lc_F77=no + hardcode_shlibpath_var_F77=no + runpath_var='LD_RUN_PATH' -Alternatively, you may set the environment variables XPROTO_CFLAGS -and XPROTO_LIBS to avoid the need to call pkg-config. -See the pkg-config man page for more details. -" >&2;} - { (exit 1); exit 1; }; } -elif test $pkg_failed = untried; then - { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -{ { $as_echo "$as_me:$LINENO: error: The pkg-config script could not be found or is too old. Make sure it -is in your PATH or set the PKG_CONFIG environment variable to the full -path to pkg-config. + if test "$GCC" = yes; then + archive_cmds_F77='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds_F77='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + else + archive_cmds_F77='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds_F77='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + fi + ;; -Alternatively, you may set the environment variables XPROTO_CFLAGS -and XPROTO_LIBS to avoid the need to call pkg-config. -See the pkg-config man page for more details. + sysv5* | sco3.2v5* | sco5v6*) + # Note: We can NOT use -z defs as we might desire, because we do not + # link with -lc, and that would cause any symbols used from libc to + # always be unresolved, which means just about no library would + # ever link correctly. If we're not using GNU ld we use -z text + # though, which does catch some bad symbols but isn't as heavy-handed + # as -z defs. + no_undefined_flag_F77='${wl}-z,text' + allow_undefined_flag_F77='${wl}-z,nodefs' + archive_cmds_need_lc_F77=no + hardcode_shlibpath_var_F77=no + hardcode_libdir_flag_spec_F77='`test -z "$SCOABSPATH" && echo ${wl}-R,$libdir`' + hardcode_libdir_separator_F77=':' + link_all_deplibs_F77=yes + export_dynamic_flag_spec_F77='${wl}-Bexport' + runpath_var='LD_RUN_PATH' -To get pkg-config, see . -See \`config.log' for more details." >&5 -$as_echo "$as_me: error: The pkg-config script could not be found or is too old. Make sure it -is in your PATH or set the PKG_CONFIG environment variable to the full -path to pkg-config. + if test "$GCC" = yes; then + archive_cmds_F77='$CC -shared ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds_F77='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' + else + archive_cmds_F77='$CC -G ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds_F77='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' + fi + ;; -Alternatively, you may set the environment variables XPROTO_CFLAGS -and XPROTO_LIBS to avoid the need to call pkg-config. -See the pkg-config man page for more details. + uts4*) + archive_cmds_F77='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_libdir_flag_spec_F77='-L$libdir' + hardcode_shlibpath_var_F77=no + ;; -To get pkg-config, see . -See \`config.log' for more details." >&2;} - { (exit 1); exit 1; }; }; } -else - XPROTO_CFLAGS=$pkg_cv_XPROTO_CFLAGS - XPROTO_LIBS=$pkg_cv_XPROTO_LIBS - { $as_echo "$as_me:$LINENO: result: yes" >&5 -$as_echo "yes" >&6; } - : -fi + *) + ld_shlibs_F77=no + ;; + esac + fi +{ $as_echo "$as_me:$LINENO: result: $ld_shlibs_F77" >&5 +$as_echo "$ld_shlibs_F77" >&6; } +test "$ld_shlibs_F77" = no && can_build_shared=no -case "$ac_cv_use_xcb" in -no) - X11_REQUIRES="xau xcmiscproto bigreqsproto" - X11_EXTRA_DEPS="xau" +# +# Do we need to explicitly link libc? +# +case "x$archive_cmds_need_lc_F77" in +x|xyes) + # Assume -lc should be added + archive_cmds_need_lc_F77=yes -pkg_failed=no -{ $as_echo "$as_me:$LINENO: checking for XDMCP" >&5 -$as_echo_n "checking for XDMCP... " >&6; } + if test "$enable_shared" = yes && test "$GCC" = yes; then + case $archive_cmds_F77 in + *'~'*) + # FIXME: we may have to deal with multi-command sequences. + ;; + '$CC '*) + # Test whether the compiler implicitly links with -lc since on some + # systems, -lgcc has to come before -lc. If gcc already passes -lc + # to ld, don't add -lc before -lgcc. + { $as_echo "$as_me:$LINENO: checking whether -lc should be explicitly linked in" >&5 +$as_echo_n "checking whether -lc should be explicitly linked in... " >&6; } + $rm conftest* + echo "$lt_simple_compile_test_code" > conftest.$ac_ext -if test -n "$XDMCP_CFLAGS"; then - pkg_cv_XDMCP_CFLAGS="$XDMCP_CFLAGS" - elif test -n "$PKG_CONFIG"; then - if test -n "$PKG_CONFIG" && \ - { ($as_echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \"xdmcp\"") >&5 - ($PKG_CONFIG --exists --print-errors "xdmcp") 2>&5 + if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 + (eval $ac_compile) 2>&5 ac_status=$? $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; then - pkg_cv_XDMCP_CFLAGS=`$PKG_CONFIG --cflags "xdmcp" 2>/dev/null` -else - pkg_failed=yes -fi - else - pkg_failed=untried -fi -if test -n "$XDMCP_LIBS"; then - pkg_cv_XDMCP_LIBS="$XDMCP_LIBS" - elif test -n "$PKG_CONFIG"; then - if test -n "$PKG_CONFIG" && \ - { ($as_echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \"xdmcp\"") >&5 - ($PKG_CONFIG --exists --print-errors "xdmcp") 2>&5 + (exit $ac_status); } 2>conftest.err; then + soname=conftest + lib=conftest + libobjs=conftest.$ac_objext + deplibs= + wl=$lt_prog_compiler_wl_F77 + pic_flag=$lt_prog_compiler_pic_F77 + compiler_flags=-v + linker_flags=-v + verstring= + output_objdir=. + libname=conftest + lt_save_allow_undefined_flag=$allow_undefined_flag_F77 + allow_undefined_flag_F77= + if { (eval echo "$as_me:$LINENO: \"$archive_cmds_F77 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1\"") >&5 + (eval $archive_cmds_F77 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1) 2>&5 ac_status=$? $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; then - pkg_cv_XDMCP_LIBS=`$PKG_CONFIG --libs "xdmcp" 2>/dev/null` -else - pkg_failed=yes -fi - else - pkg_failed=untried -fi - - - -if test $pkg_failed = yes; then - -if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then - _pkg_short_errors_supported=yes -else - _pkg_short_errors_supported=no -fi - if test $_pkg_short_errors_supported = yes; then - XDMCP_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "xdmcp" 2>&1` + (exit $ac_status); } + then + archive_cmds_need_lc_F77=no else - XDMCP_PKG_ERRORS=`$PKG_CONFIG --print-errors "xdmcp" 2>&1` + archive_cmds_need_lc_F77=yes fi - # Put the nasty error message in config.log where it belongs - echo "$XDMCP_PKG_ERRORS" >&5 - - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } -elif test $pkg_failed = untried; then - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } -else - XDMCP_CFLAGS=$pkg_cv_XDMCP_CFLAGS - XDMCP_LIBS=$pkg_cv_XDMCP_LIBS - { $as_echo "$as_me:$LINENO: result: yes" >&5 -$as_echo "yes" >&6; } - { $as_echo "$as_me:$LINENO: checking for XdmcpWrap in -lXdmcp" >&5 -$as_echo_n "checking for XdmcpWrap in -lXdmcp... " >&6; } -if test "${ac_cv_lib_Xdmcp_XdmcpWrap+set}" = set; then - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS -LIBS="-lXdmcp $XDMCP_LIBS $LIBS" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char XdmcpWrap (); -int -main () -{ -return XdmcpWrap (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; + allow_undefined_flag_F77=$lt_save_allow_undefined_flag + else + cat conftest.err 1>&5 + fi + $rm conftest* + { $as_echo "$as_me:$LINENO: result: $archive_cmds_need_lc_F77" >&5 +$as_echo "$archive_cmds_need_lc_F77" >&6; } + ;; + esac + fi + ;; esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 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_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - ac_cv_lib_Xdmcp_XdmcpWrap=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - ac_cv_lib_Xdmcp_XdmcpWrap=no -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_Xdmcp_XdmcpWrap" >&5 -$as_echo "$ac_cv_lib_Xdmcp_XdmcpWrap" >&6; } -if test "x$ac_cv_lib_Xdmcp_XdmcpWrap" = x""yes; then +{ $as_echo "$as_me:$LINENO: checking dynamic linker characteristics" >&5 +$as_echo_n "checking dynamic linker characteristics... " >&6; } +library_names_spec= +libname_spec='lib$name' +soname_spec= +shrext_cmds=".so" +postinstall_cmds= +postuninstall_cmds= +finish_cmds= +finish_eval= +shlibpath_var= +shlibpath_overrides_runpath=unknown +version_type=none +dynamic_linker="$host_os ld.so" +sys_lib_dlsearch_path_spec="/lib /usr/lib" - { $as_echo "$as_me:$LINENO: checking for XdmcpWrap in -lXdmcp" >&5 -$as_echo_n "checking for XdmcpWrap in -lXdmcp... " >&6; } -if test "${ac_cv_lib_Xdmcp_XdmcpWrap+set}" = set; then - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS -LIBS="-lXdmcp $XDMCP_LIBS $LIBS" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ +need_lib_prefix=unknown +hardcode_into_libs=no -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char XdmcpWrap (); -int -main () -{ -return XdmcpWrap (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext 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>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_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - ac_cv_lib_Xdmcp_XdmcpWrap=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 +# when you set need_version to no, make sure it does not cause -set_version +# flags to be left without arguments +need_version=unknown - ac_cv_lib_Xdmcp_XdmcpWrap=no -fi +case $host_os in +aix3*) + version_type=linux + library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a' + shlibpath_var=LIBPATH -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_Xdmcp_XdmcpWrap" >&5 -$as_echo "$ac_cv_lib_Xdmcp_XdmcpWrap" >&6; } -if test "x$ac_cv_lib_Xdmcp_XdmcpWrap" = x""yes; then - xdmauth="yes" -else - xdmauth="no" -fi + # AIX 3 has no versioning support, so we append a major version to the name. + soname_spec='${libname}${release}${shared_ext}$major' + ;; - X11_EXTRA_DEPS="$X11_EXTRA_DEPS xdmcp" +aix[4-9]*) + version_type=linux + need_lib_prefix=no + need_version=no + hardcode_into_libs=yes + if test "$host_cpu" = ia64; then + # AIX 5 supports IA64 + library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + else + # With GCC up to 2.95.x, collect2 would create an import file + # for dependence libraries. The import file would start with + # the line `#! .'. This would cause the generated library to + # depend on `.', always an invalid library. This was fixed in + # development snapshots of GCC prior to 3.0. + case $host_os in + aix4 | aix4.[01] | aix4.[01].*) + if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' + echo ' yes ' + echo '#endif'; } | ${CC} -E - | grep yes > /dev/null; then + : + else + can_build_shared=no + fi + ;; + esac + # AIX (on Power*) has no versioning support, so currently we can not hardcode correct + # soname into executable. Probably we can add versioning support to + # collect2, so additional links can be useful in future. + if test "$aix_use_runtimelinking" = yes; then + # If using run time linking (on AIX 4.2 or later) use lib.so + # instead of lib.a to let people know that these are not + # typical AIX shared libraries. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + else + # We preserve .a as extension for shared libraries through AIX4.2 + # and later when we are not doing run time linking. + library_names_spec='${libname}${release}.a $libname.a' + soname_spec='${libname}${release}${shared_ext}$major' + fi + shlibpath_var=LIBPATH + fi + ;; -else - - XDMCP_CFLAGS= - XDMCP_LIBS= - -fi +amigaos*) + library_names_spec='$libname.ixlibrary $libname.a' + # Create ${libname}_ixlibrary.a entries in /sys/libs. + finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$echo "X$lib" | $Xsed -e '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $rm /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' + ;; -fi +beos*) + library_names_spec='${libname}${shared_ext}' + dynamic_linker="$host_os ld.so" + shlibpath_var=LIBRARY_PATH + ;; -cat >>confdefs.h <<\_ACEOF -#define USE_XCB 0 -_ACEOF +bsdi[45]*) + version_type=linux + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' + shlibpath_var=LD_LIBRARY_PATH + sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" + sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" + # the default ld.so.conf also contains /usr/contrib/lib and + # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow + # libtool to hard-code these into programs + ;; - ;; -*) - X11_REQUIRES="xcb >= 1.1.92" - X11_EXTRA_DEPS="xcb >= 1.1.92" - xdmauth="no" # XCB handles all auth +cygwin* | mingw* | pw32*) + version_type=windows + shrext_cmds=".dll" + need_version=no + need_lib_prefix=no -cat >>confdefs.h <<\_ACEOF -#define USE_XCB 1 -_ACEOF + case $GCC,$host_os in + yes,cygwin* | yes,mingw* | yes,pw32*) + library_names_spec='$libname.dll.a' + # DLL is installed to $(libdir)/../bin by postinstall_cmds + postinstall_cmds='base_file=`basename \${file}`~ + dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i;echo \$dlname'\''`~ + dldir=$destdir/`dirname \$dlpath`~ + test -d \$dldir || mkdir -p \$dldir~ + $install_prog $dir/$dlname \$dldir/$dlname~ + chmod a+x \$dldir/$dlname' + postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ + dlpath=$dir/\$dldll~ + $rm \$dlpath' + shlibpath_overrides_runpath=yes - ;; -esac + case $host_os in + cygwin*) + # Cygwin DLLs use 'cyg' prefix rather than 'lib' + soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' + sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib" + ;; + mingw*) + # MinGW DLLs use traditional 'lib' prefix + soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' + sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"` + if echo "$sys_lib_search_path_spec" | grep ';[c-zC-Z]:/' >/dev/null; then + # It is most probably a Windows format PATH printed by + # mingw gcc, but we are running on Cygwin. Gcc prints its search + # path with ; separators, and with drive letters. We can handle the + # drive letters (cygwin fileutils understands them), so leave them, + # especially as we might pass files found there to a mingw objdump, + # which wouldn't understand a cygwinified path. Ahh. + sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` + else + sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` + fi + ;; + pw32*) + # pw32 DLLs use 'pw' prefix rather than 'lib' + library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' + ;; + esac + ;; + *) + library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib' + ;; + esac + dynamic_linker='Win32 ld.exe' + # FIXME: first we should search . and the directory the executable is in + shlibpath_var=PATH + ;; -pkg_failed=no -{ $as_echo "$as_me:$LINENO: checking for X11" >&5 -$as_echo_n "checking for X11... " >&6; } +darwin* | rhapsody*) + dynamic_linker="$host_os dyld" + version_type=darwin + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${versuffix}$shared_ext ${libname}${release}${major}$shared_ext ${libname}$shared_ext' + soname_spec='${libname}${release}${major}$shared_ext' + shlibpath_overrides_runpath=yes + shlibpath_var=DYLD_LIBRARY_PATH + shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' -if test -n "$X11_CFLAGS"; then - pkg_cv_X11_CFLAGS="$X11_CFLAGS" - elif test -n "$PKG_CONFIG"; then - if test -n "$PKG_CONFIG" && \ - { ($as_echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \"xextproto xtrans \$X11_REQUIRES\"") >&5 - ($PKG_CONFIG --exists --print-errors "xextproto xtrans $X11_REQUIRES") 2>&5 - ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; then - pkg_cv_X11_CFLAGS=`$PKG_CONFIG --cflags "xextproto xtrans $X11_REQUIRES" 2>/dev/null` -else - pkg_failed=yes -fi - else - pkg_failed=untried -fi -if test -n "$X11_LIBS"; then - pkg_cv_X11_LIBS="$X11_LIBS" - elif test -n "$PKG_CONFIG"; then - if test -n "$PKG_CONFIG" && \ - { ($as_echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \"xextproto xtrans \$X11_REQUIRES\"") >&5 - ($PKG_CONFIG --exists --print-errors "xextproto xtrans $X11_REQUIRES") 2>&5 - ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; then - pkg_cv_X11_LIBS=`$PKG_CONFIG --libs "xextproto xtrans $X11_REQUIRES" 2>/dev/null` -else - pkg_failed=yes -fi - else - pkg_failed=untried -fi + sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' + ;; +dgux*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + ;; +freebsd1*) + dynamic_linker=no + ;; -if test $pkg_failed = yes; then +freebsd* | dragonfly*) + # DragonFly does not have aout. When/if they implement a new + # versioning mechanism, adjust this. + if test -x /usr/bin/objformat; then + objformat=`/usr/bin/objformat` + else + case $host_os in + freebsd[123]*) objformat=aout ;; + *) objformat=elf ;; + esac + fi + version_type=freebsd-$objformat + case $version_type in + freebsd-elf*) + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' + need_version=no + need_lib_prefix=no + ;; + freebsd-*) + library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' + need_version=yes + ;; + esac + shlibpath_var=LD_LIBRARY_PATH + case $host_os in + freebsd2*) + shlibpath_overrides_runpath=yes + ;; + freebsd3.[01]* | freebsdelf3.[01]*) + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; + freebsd3.[2-9]* | freebsdelf3.[2-9]* | \ + freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1) + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; + *) # from 4.6 on, and DragonFly + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; + esac + ;; -if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then - _pkg_short_errors_supported=yes -else - _pkg_short_errors_supported=no -fi - if test $_pkg_short_errors_supported = yes; then - X11_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "xextproto xtrans $X11_REQUIRES" 2>&1` - else - X11_PKG_ERRORS=`$PKG_CONFIG --print-errors "xextproto xtrans $X11_REQUIRES" 2>&1` - fi - # Put the nasty error message in config.log where it belongs - echo "$X11_PKG_ERRORS" >&5 +gnu*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + hardcode_into_libs=yes + ;; - { { $as_echo "$as_me:$LINENO: error: Package requirements (xextproto xtrans $X11_REQUIRES) were not met: +hpux9* | hpux10* | hpux11*) + # Give a soname corresponding to the major version so that dld.sl refuses to + # link against other versions. + version_type=sunos + need_lib_prefix=no + need_version=no + case $host_cpu in + ia64*) + shrext_cmds='.so' + hardcode_into_libs=yes + dynamic_linker="$host_os dld.so" + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + if test "X$HPUX_IA64_MODE" = X32; then + sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" + else + sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" + fi + sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec + ;; + hppa*64*) + shrext_cmds='.sl' + hardcode_into_libs=yes + dynamic_linker="$host_os dld.sl" + shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH + shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" + sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec + ;; + *) + shrext_cmds='.sl' + dynamic_linker="$host_os dld.sl" + shlibpath_var=SHLIB_PATH + shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + ;; + esac + # HP-UX runs *really* slowly unless shared libraries are mode 555. + postinstall_cmds='chmod 555 $lib' + ;; -$X11_PKG_ERRORS +interix[3-9]*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; -Consider adjusting the PKG_CONFIG_PATH environment variable if you -installed software in a non-standard prefix. - -Alternatively, you may set the environment variables X11_CFLAGS -and X11_LIBS to avoid the need to call pkg-config. -See the pkg-config man page for more details. -" >&5 -$as_echo "$as_me: error: Package requirements (xextproto xtrans $X11_REQUIRES) were not met: +irix5* | irix6* | nonstopux*) + case $host_os in + nonstopux*) version_type=nonstopux ;; + *) + if test "$lt_cv_prog_gnu_ld" = yes; then + version_type=linux + else + version_type=irix + fi ;; + esac + need_lib_prefix=no + need_version=no + soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}' + case $host_os in + irix5* | nonstopux*) + libsuff= shlibsuff= + ;; + *) + case $LD in # libtool.m4 will add one of these switches to LD + *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") + libsuff= shlibsuff= libmagic=32-bit;; + *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") + libsuff=32 shlibsuff=N32 libmagic=N32;; + *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") + libsuff=64 shlibsuff=64 libmagic=64-bit;; + *) libsuff= shlibsuff= libmagic=never-match;; + esac + ;; + esac + shlibpath_var=LD_LIBRARY${shlibsuff}_PATH + shlibpath_overrides_runpath=no + sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" + sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" + hardcode_into_libs=yes + ;; -$X11_PKG_ERRORS +# No shared lib support for Linux oldld, aout, or coff. +linux*oldld* | linux*aout* | linux*coff*) + dynamic_linker=no + ;; -Consider adjusting the PKG_CONFIG_PATH environment variable if you -installed software in a non-standard prefix. +# This must be Linux ELF. +linux* | k*bsd*-gnu) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + # This implies no fast_install, which is unacceptable. + # Some rework will be needed to allow for fast_install + # before this can be enabled. + hardcode_into_libs=yes -Alternatively, you may set the environment variables X11_CFLAGS -and X11_LIBS to avoid the need to call pkg-config. -See the pkg-config man page for more details. -" >&2;} - { (exit 1); exit 1; }; } -elif test $pkg_failed = untried; then - { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -{ { $as_echo "$as_me:$LINENO: error: The pkg-config script could not be found or is too old. Make sure it -is in your PATH or set the PKG_CONFIG environment variable to the full -path to pkg-config. + # Append ld.so.conf contents to the search path + if test -f /etc/ld.so.conf; then + lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '` + sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" + fi -Alternatively, you may set the environment variables X11_CFLAGS -and X11_LIBS to avoid the need to call pkg-config. -See the pkg-config man page for more details. + # We used to test for /lib/ld.so.1 and disable shared libraries on + # powerpc, because MkLinux only supported shared libraries with the + # GNU dynamic linker. Since this was broken with cross compilers, + # most powerpc-linux boxes support dynamic linking these days and + # people can always --disable-shared, the test was removed, and we + # assume the GNU/Linux dynamic linker is in use. + dynamic_linker='GNU/Linux ld.so' + ;; -To get pkg-config, see . -See \`config.log' for more details." >&5 -$as_echo "$as_me: error: The pkg-config script could not be found or is too old. Make sure it -is in your PATH or set the PKG_CONFIG environment variable to the full -path to pkg-config. +netbsd*) + version_type=sunos + need_lib_prefix=no + need_version=no + if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' + dynamic_linker='NetBSD (a.out) ld.so' + else + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + dynamic_linker='NetBSD ld.elf_so' + fi + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; -Alternatively, you may set the environment variables X11_CFLAGS -and X11_LIBS to avoid the need to call pkg-config. -See the pkg-config man page for more details. +newsos6) + version_type=linux + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + ;; -To get pkg-config, see . -See \`config.log' for more details." >&2;} - { (exit 1); exit 1; }; }; } -else - X11_CFLAGS=$pkg_cv_X11_CFLAGS - X11_LIBS=$pkg_cv_X11_LIBS - { $as_echo "$as_me:$LINENO: result: yes" >&5 -$as_echo "yes" >&6; } - : -fi +nto-qnx*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + ;; +openbsd*) + version_type=sunos + sys_lib_dlsearch_path_spec="/usr/lib" + need_lib_prefix=no + # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs. + case $host_os in + openbsd3.3 | openbsd3.3.*) need_version=yes ;; + *) need_version=no ;; + esac + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' + shlibpath_var=LD_LIBRARY_PATH + if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then + case $host_os in + openbsd2.[89] | openbsd2.[89].*) + shlibpath_overrides_runpath=no + ;; + *) + shlibpath_overrides_runpath=yes + ;; + esac + else + shlibpath_overrides_runpath=yes + fi + ;; +os2*) + libname_spec='$name' + shrext_cmds=".dll" + need_lib_prefix=no + library_names_spec='$libname${shared_ext} $libname.a' + dynamic_linker='OS/2 ld.exe' + shlibpath_var=LIBPATH + ;; -# Transport selection macro from xtrans.m4 +osf3* | osf4* | osf5*) + version_type=osf + need_lib_prefix=no + need_version=no + soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" + sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" + ;; +rdos*) + dynamic_linker=no + ;; +solaris*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + # ldd complains unless libraries are executable + postinstall_cmds='chmod +x $lib' + ;; - case $host_os in - mingw*) unixdef="no" ;; - *) unixdef="yes" ;; - esac - # Check whether --enable-unix-transport was given. -if test "${enable_unix_transport+set}" = set; then - enableval=$enable_unix_transport; UNIXCONN=$enableval -else - UNIXCONN=$unixdef -fi +sunos4*) + version_type=sunos + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' + finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + if test "$with_gnu_ld" = yes; then + need_lib_prefix=no + fi + need_version=yes + ;; - { $as_echo "$as_me:$LINENO: checking if Xtrans should support UNIX socket connections" >&5 -$as_echo_n "checking if Xtrans should support UNIX socket connections... " >&6; } - if test "$UNIXCONN" = "yes"; then +sysv4 | sysv4.3*) + version_type=linux + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + case $host_vendor in + sni) + shlibpath_overrides_runpath=no + need_lib_prefix=no + export_dynamic_flag_spec='${wl}-Blargedynsym' + runpath_var=LD_RUN_PATH + ;; + siemens) + need_lib_prefix=no + ;; + motorola) + need_lib_prefix=no + need_version=no + shlibpath_overrides_runpath=no + sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' + ;; + esac + ;; -cat >>confdefs.h <<\_ACEOF -#define UNIXCONN 1 -_ACEOF +sysv4*MP*) + if test -d /usr/nec ;then + version_type=linux + library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' + soname_spec='$libname${shared_ext}.$major' + shlibpath_var=LD_LIBRARY_PATH + fi + ;; - fi - { $as_echo "$as_me:$LINENO: result: $UNIXCONN" >&5 -$as_echo "$UNIXCONN" >&6; } - # Check whether --enable-tcp-transport was given. -if test "${enable_tcp_transport+set}" = set; then - enableval=$enable_tcp_transport; TCPCONN=$enableval -else - TCPCONN=yes -fi - - { $as_echo "$as_me:$LINENO: checking if Xtrans should support TCP socket connections" >&5 -$as_echo_n "checking if Xtrans should support TCP socket connections... " >&6; } - { $as_echo "$as_me:$LINENO: result: $TCPCONN" >&5 -$as_echo "$TCPCONN" >&6; } - if test "$TCPCONN" = "yes"; then +sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) + version_type=freebsd-elf + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + hardcode_into_libs=yes + if test "$with_gnu_ld" = yes; then + sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' + shlibpath_overrides_runpath=no + else + sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' + shlibpath_overrides_runpath=yes + case $host_os in + sco3.2v5*) + sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" + ;; + esac + fi + sys_lib_dlsearch_path_spec='/usr/lib' + ;; -cat >>confdefs.h <<\_ACEOF -#define TCPCONN 1 -_ACEOF +uts4*) + version_type=linux + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + ;; +*) + dynamic_linker=no + ;; +esac +{ $as_echo "$as_me:$LINENO: result: $dynamic_linker" >&5 +$as_echo "$dynamic_linker" >&6; } +test "$dynamic_linker" = no && can_build_shared=no - # SVR4 hides these in libraries other than libc - { $as_echo "$as_me:$LINENO: checking for library containing socket" >&5 -$as_echo_n "checking for library containing socket... " >&6; } -if test "${ac_cv_search_socket+set}" = set; then +if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then $as_echo_n "(cached) " >&6 else - ac_func_search_save_LIBS=$LIBS -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ + lt_cv_sys_lib_search_path_spec="$sys_lib_search_path_spec" +fi -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char socket (); -int -main () -{ -return socket (); - ; - return 0; -} -_ACEOF -for ac_lib in '' socket; do - if test -z "$ac_lib"; then - ac_res="none required" - else - ac_res=-l$ac_lib - LIBS="-l$ac_lib $ac_func_search_save_LIBS" - fi - rm -f conftest.$ac_objext 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>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_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - ac_cv_search_socket=$ac_res +sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec" +if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then + $as_echo_n "(cached) " >&6 else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 + lt_cv_sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec" +fi +sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec" +variables_saved_for_relink="PATH $shlibpath_var $runpath_var" +if test "$GCC" = yes; then + variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" fi -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext - if test "${ac_cv_search_socket+set}" = set; then - break -fi -done -if test "${ac_cv_search_socket+set}" = set; then - : +{ $as_echo "$as_me:$LINENO: checking how to hardcode library paths into programs" >&5 +$as_echo_n "checking how to hardcode library paths into programs... " >&6; } +hardcode_action_F77= +if test -n "$hardcode_libdir_flag_spec_F77" || \ + test -n "$runpath_var_F77" || \ + test "X$hardcode_automatic_F77" = "Xyes" ; then + + # We can hardcode non-existant directories. + if test "$hardcode_direct_F77" != no && + # If the only mechanism to avoid hardcoding is shlibpath_var, we + # have to relink, otherwise we might link with an installed library + # when we should be linking with a yet-to-be-installed one + ## test "$_LT_AC_TAGVAR(hardcode_shlibpath_var, F77)" != no && + test "$hardcode_minus_L_F77" != no; then + # Linking always hardcodes the temporary library directory. + hardcode_action_F77=relink + else + # We can link without hardcoding, and we can hardcode nonexisting dirs. + hardcode_action_F77=immediate + fi else - ac_cv_search_socket=no -fi -rm conftest.$ac_ext -LIBS=$ac_func_search_save_LIBS + # We cannot hardcode anything, or else we can only hardcode existing + # directories. + hardcode_action_F77=unsupported fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_search_socket" >&5 -$as_echo "$ac_cv_search_socket" >&6; } -ac_res=$ac_cv_search_socket -if test "$ac_res" != no; then - test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" +{ $as_echo "$as_me:$LINENO: result: $hardcode_action_F77" >&5 +$as_echo "$hardcode_action_F77" >&6; } +if test "$hardcode_action_F77" = relink; then + # Fast installation is not supported + enable_fast_install=no +elif test "$shlibpath_overrides_runpath" = yes || + test "$enable_shared" = no; then + # Fast installation is not necessary + enable_fast_install=needless fi - { $as_echo "$as_me:$LINENO: checking for library containing gethostbyname" >&5 -$as_echo_n "checking for library containing gethostbyname... " >&6; } -if test "${ac_cv_search_gethostbyname+set}" = set; then - $as_echo_n "(cached) " >&6 -else - ac_func_search_save_LIBS=$LIBS -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char gethostbyname (); -int -main () -{ -return gethostbyname (); - ; - return 0; -} -_ACEOF -for ac_lib in '' nsl; do - if test -z "$ac_lib"; then - ac_res="none required" - else - ac_res=-l$ac_lib - LIBS="-l$ac_lib $ac_func_search_save_LIBS" +# The else clause should only fire when bootstrapping the +# libtool distribution, otherwise you forgot to ship ltmain.sh +# with your package, and you will get complaints that there are +# no rules to generate ltmain.sh. +if test -f "$ltmain"; then + # See if we are running on zsh, and set the options which allow our commands through + # without removal of \ escapes. + if test -n "${ZSH_VERSION+set}" ; then + setopt NO_GLOB_SUBST fi - rm -f conftest.$ac_objext 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>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_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - ac_cv_search_gethostbyname=$ac_res -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 + # Now quote all the things that may contain metacharacters while being + # careful not to overquote the AC_SUBSTed values. We take copies of the + # variables and quote the copies for generation of the libtool script. + for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC LTCFLAGS NM \ + SED SHELL STRIP \ + libname_spec library_names_spec soname_spec extract_expsyms_cmds \ + old_striplib striplib file_magic_cmd finish_cmds finish_eval \ + deplibs_check_method reload_flag reload_cmds need_locks \ + lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \ + lt_cv_sys_global_symbol_to_c_name_address \ + sys_lib_search_path_spec sys_lib_dlsearch_path_spec \ + old_postinstall_cmds old_postuninstall_cmds \ + compiler_F77 \ + CC_F77 \ + LD_F77 \ + lt_prog_compiler_wl_F77 \ + lt_prog_compiler_pic_F77 \ + lt_prog_compiler_static_F77 \ + lt_prog_compiler_no_builtin_flag_F77 \ + export_dynamic_flag_spec_F77 \ + thread_safe_flag_spec_F77 \ + whole_archive_flag_spec_F77 \ + enable_shared_with_static_runtimes_F77 \ + old_archive_cmds_F77 \ + old_archive_from_new_cmds_F77 \ + predep_objects_F77 \ + postdep_objects_F77 \ + predeps_F77 \ + postdeps_F77 \ + compiler_lib_search_path_F77 \ + compiler_lib_search_dirs_F77 \ + archive_cmds_F77 \ + archive_expsym_cmds_F77 \ + postinstall_cmds_F77 \ + postuninstall_cmds_F77 \ + old_archive_from_expsyms_cmds_F77 \ + allow_undefined_flag_F77 \ + no_undefined_flag_F77 \ + export_symbols_cmds_F77 \ + hardcode_libdir_flag_spec_F77 \ + hardcode_libdir_flag_spec_ld_F77 \ + hardcode_libdir_separator_F77 \ + hardcode_automatic_F77 \ + module_cmds_F77 \ + module_expsym_cmds_F77 \ + lt_cv_prog_compiler_c_o_F77 \ + fix_srcfile_path_F77 \ + exclude_expsyms_F77 \ + include_expsyms_F77; do + + case $var in + old_archive_cmds_F77 | \ + old_archive_from_new_cmds_F77 | \ + archive_cmds_F77 | \ + archive_expsym_cmds_F77 | \ + module_cmds_F77 | \ + module_expsym_cmds_F77 | \ + old_archive_from_expsyms_cmds_F77 | \ + export_symbols_cmds_F77 | \ + extract_expsyms_cmds | reload_cmds | finish_cmds | \ + postinstall_cmds | postuninstall_cmds | \ + old_postinstall_cmds | old_postuninstall_cmds | \ + sys_lib_search_path_spec | sys_lib_dlsearch_path_spec) + # Double-quote double-evaled strings. + eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\"" + ;; + *) + eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\"" + ;; + esac + done + case $lt_echo in + *'\$0 --fallback-echo"') + lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\$0 --fallback-echo"$/$0 --fallback-echo"/'` + ;; + esac -fi +cfgfile="$ofile" -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext - if test "${ac_cv_search_gethostbyname+set}" = set; then - break -fi -done -if test "${ac_cv_search_gethostbyname+set}" = set; then - : -else - ac_cv_search_gethostbyname=no -fi -rm conftest.$ac_ext -LIBS=$ac_func_search_save_LIBS -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_search_gethostbyname" >&5 -$as_echo "$ac_cv_search_gethostbyname" >&6; } -ac_res=$ac_cv_search_gethostbyname -if test "$ac_res" != no; then - test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" + cat <<__EOF__ >> "$cfgfile" +# ### BEGIN LIBTOOL TAG CONFIG: $tagname -fi +# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: +# Shell to use when invoking shell scripts. +SHELL=$lt_SHELL -{ $as_echo "$as_me:$LINENO: checking for main in -lws2_32" >&5 -$as_echo_n "checking for main in -lws2_32... " >&6; } -if test "${ac_cv_lib_ws2_32_main+set}" = set; then - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS -LIBS="-lws2_32 $LIBS" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ +# Whether or not to build shared libraries. +build_libtool_libs=$enable_shared +# Whether or not to build static libraries. +build_old_libs=$enable_static -int -main () -{ -return main (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext 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>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_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - ac_cv_lib_ws2_32_main=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 +# Whether or not to add -lc for building shared libraries. +build_libtool_need_lc=$archive_cmds_need_lc_F77 - ac_cv_lib_ws2_32_main=no -fi +# Whether or not to disallow shared libs when runtime libs are static +allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes_F77 -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_ws2_32_main" >&5 -$as_echo "$ac_cv_lib_ws2_32_main" >&6; } -if test "x$ac_cv_lib_ws2_32_main" = x""yes; then - cat >>confdefs.h <<_ACEOF -#define HAVE_LIBWS2_32 1 -_ACEOF +# Whether or not to optimize for fast installation. +fast_install=$enable_fast_install - LIBS="-lws2_32 $LIBS" +# The host system. +host_alias=$host_alias +host=$host +host_os=$host_os -fi -ac_cv_lib_ws2_32=ac_cv_lib_ws2_32_main +# The build system. +build_alias=$build_alias +build=$build +build_os=$build_os +# An echo program that does not interpret backslashes. +echo=$lt_echo - # Needs to come after above checks for libsocket & libnsl for SVR4 systems - # Check whether --enable-ipv6 was given. -if test "${enable_ipv6+set}" = set; then - enableval=$enable_ipv6; IPV6CONN=$enableval -else - { $as_echo "$as_me:$LINENO: checking for getaddrinfo" >&5 -$as_echo_n "checking for getaddrinfo... " >&6; } -if test "${ac_cv_func_getaddrinfo+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. */ -/* Define getaddrinfo to an innocuous variant, in case declares getaddrinfo. - For example, HP-UX 11i declares gettimeofday. */ -#define getaddrinfo innocuous_getaddrinfo +# The archiver. +AR=$lt_AR +AR_FLAGS=$lt_AR_FLAGS -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char getaddrinfo (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ +# A C compiler. +LTCC=$lt_LTCC -#ifdef __STDC__ -# include -#else -# include -#endif +# LTCC compiler flags. +LTCFLAGS=$lt_LTCFLAGS -#undef getaddrinfo +# A language-specific compiler. +CC=$lt_compiler_F77 -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char getaddrinfo (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_getaddrinfo || defined __stub___getaddrinfo -choke me -#endif +# Is the compiler the GNU C compiler? +with_gcc=$GCC_F77 -int -main () -{ -return getaddrinfo (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext 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>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_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - ac_cv_func_getaddrinfo=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 +# An ERE matcher. +EGREP=$lt_EGREP - ac_cv_func_getaddrinfo=no -fi +# The linker used to build libraries. +LD=$lt_LD_F77 -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_func_getaddrinfo" >&5 -$as_echo "$ac_cv_func_getaddrinfo" >&6; } -if test "x$ac_cv_func_getaddrinfo" = x""yes; then - IPV6CONN=yes -else - IPV6CONN=no -fi +# Whether we need hard or soft links. +LN_S=$lt_LN_S -fi +# A BSD-compatible nm program. +NM=$lt_NM - { $as_echo "$as_me:$LINENO: checking if IPv6 support should be built" >&5 -$as_echo_n "checking if IPv6 support should be built... " >&6; } - if test "$IPV6CONN" = "yes"; then +# A symbol stripping program +STRIP=$lt_STRIP -cat >>confdefs.h <<\_ACEOF -#define IPv6 1 -_ACEOF +# Used to examine libraries when file_magic_cmd begins "file" +MAGIC_CMD=$MAGIC_CMD - fi - { $as_echo "$as_me:$LINENO: result: $IPV6CONN" >&5 -$as_echo "$IPV6CONN" >&6; } +# Used on cygwin: DLL creation program. +DLLTOOL="$DLLTOOL" - # 4.3BSD-Reno added a new member to struct sockaddr_in - { $as_echo "$as_me:$LINENO: checking for struct sockaddr_in.sin_len" >&5 -$as_echo_n "checking for struct sockaddr_in.sin_len... " >&6; } -if test "${ac_cv_member_struct_sockaddr_in_sin_len+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. */ +# Used on cygwin: object dumper. +OBJDUMP="$OBJDUMP" -#include -#include -#include +# Used on cygwin: assembler. +AS="$AS" +# The name of the directory that contains temporary libtool files. +objdir=$objdir -int -main () -{ -static struct sockaddr_in ac_aggr; -if (ac_aggr.sin_len) -return 0; - ; - 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_member_struct_sockaddr_in_sin_len=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 +# How to create reloadable object files. +reload_flag=$lt_reload_flag +reload_cmds=$lt_reload_cmds - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ +# How to pass a linker flag through the compiler. +wl=$lt_lt_prog_compiler_wl_F77 -#include -#include -#include +# Object file suffix (normally "o"). +objext="$ac_objext" +# Old archive suffix (normally "a"). +libext="$libext" -int -main () -{ -static struct sockaddr_in ac_aggr; -if (sizeof ac_aggr.sin_len) -return 0; - ; - 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_member_struct_sockaddr_in_sin_len=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 +# Shared library suffix (normally ".so"). +shrext_cmds='$shrext_cmds' - ac_cv_member_struct_sockaddr_in_sin_len=no -fi +# Executable file suffix (normally ""). +exeext="$exeext" -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi +# Additional compiler flags for building library objects. +pic_flag=$lt_lt_prog_compiler_pic_F77 +pic_mode=$pic_mode -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_in_sin_len" >&5 -$as_echo "$ac_cv_member_struct_sockaddr_in_sin_len" >&6; } -if test "x$ac_cv_member_struct_sockaddr_in_sin_len" = x""yes; then +# What is the maximum length of a command? +max_cmd_len=$lt_cv_sys_max_cmd_len -cat >>confdefs.h <<\_ACEOF -#define BSD44SOCKETS 1 -_ACEOF +# Does compiler simultaneously support -c and -o options? +compiler_c_o=$lt_lt_cv_prog_compiler_c_o_F77 -fi +# Must we lock files when doing compilation? +need_locks=$lt_need_locks +# Do we need the lib prefix for modules? +need_lib_prefix=$need_lib_prefix - # POSIX.1g changed the type of pointer passed to getsockname/getpeername/etc. - { $as_echo "$as_me:$LINENO: checking for socklen_t" >&5 -$as_echo_n "checking for socklen_t... " >&6; } -if test "${ac_cv_type_socklen_t+set}" = set; then - $as_echo_n "(cached) " >&6 -else - ac_cv_type_socklen_t=no -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ +# Do we need a version for libraries? +need_version=$need_version -$ac_includes_default -#include +# Whether dlopen is supported. +dlopen_support=$enable_dlopen -int -main () -{ -if (sizeof (socklen_t)) - return 0; - ; - 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 - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ +# Whether dlopen of programs is supported. +dlopen_self=$enable_dlopen_self -$ac_includes_default -#include +# Whether dlopen of statically linked programs is supported. +dlopen_self_static=$enable_dlopen_self_static -int -main () -{ -if (sizeof ((socklen_t))) - return 0; - ; - 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 - : -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 +# Compiler flag to prevent dynamic linking. +link_static_flag=$lt_lt_prog_compiler_static_F77 - ac_cv_type_socklen_t=yes -fi +# Compiler flag to turn off builtin functions. +no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag_F77 -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 +# Compiler flag to allow reflexive dlopens. +export_dynamic_flag_spec=$lt_export_dynamic_flag_spec_F77 +# Compiler flag to generate shared objects directly from archives. +whole_archive_flag_spec=$lt_whole_archive_flag_spec_F77 -fi +# Compiler flag to generate thread-safe objects. +thread_safe_flag_spec=$lt_thread_safe_flag_spec_F77 -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_type_socklen_t" >&5 -$as_echo "$ac_cv_type_socklen_t" >&6; } -if test "x$ac_cv_type_socklen_t" = x""yes; then +# Library versioning type. +version_type=$version_type -cat >>confdefs.h <<_ACEOF -#define HAVE_SOCKLEN_T 1 -_ACEOF +# Format of library name prefix. +libname_spec=$lt_libname_spec +# List of archive names. First name is the real one, the rest are links. +# The last name is the one that the linker finds with -lNAME. +library_names_spec=$lt_library_names_spec -fi +# The coded name of the library, if different from the real name. +soname_spec=$lt_soname_spec +# Commands used to build and install an old-style archive. +RANLIB=$lt_RANLIB +old_archive_cmds=$lt_old_archive_cmds_F77 +old_postinstall_cmds=$lt_old_postinstall_cmds +old_postuninstall_cmds=$lt_old_postuninstall_cmds +# Create an old-style archive from a shared archive. +old_archive_from_new_cmds=$lt_old_archive_from_new_cmds_F77 - fi - case $host_os in - solaris*|sco*|sysv4*) localdef="yes" ;; - *) localdef="no" ;; - esac - # Check whether --enable-local-transport was given. -if test "${enable_local_transport+set}" = set; then - enableval=$enable_local_transport; LOCALCONN=$enableval -else - LOCALCONN=$localdef -fi +# Create a temporary old-style archive to link instead of a shared archive. +old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds_F77 - { $as_echo "$as_me:$LINENO: checking if Xtrans should support os-specific local connections" >&5 -$as_echo_n "checking if Xtrans should support os-specific local connections... " >&6; } - { $as_echo "$as_me:$LINENO: result: $LOCALCONN" >&5 -$as_echo "$LOCALCONN" >&6; } - if test "$LOCALCONN" = "yes"; then +# Commands used to build and install a shared archive. +archive_cmds=$lt_archive_cmds_F77 +archive_expsym_cmds=$lt_archive_expsym_cmds_F77 +postinstall_cmds=$lt_postinstall_cmds +postuninstall_cmds=$lt_postuninstall_cmds -cat >>confdefs.h <<\_ACEOF -#define LOCALCONN 1 -_ACEOF +# Commands used to build a loadable module (assumed same as above if empty) +module_cmds=$lt_module_cmds_F77 +module_expsym_cmds=$lt_module_expsym_cmds_F77 - fi +# Commands to strip libraries. +old_striplib=$lt_old_striplib +striplib=$lt_striplib +# Dependencies to place before the objects being linked to create a +# shared library. +predep_objects=$lt_predep_objects_F77 +# Dependencies to place after the objects being linked to create a +# shared library. +postdep_objects=$lt_postdep_objects_F77 -# Secure RPC detection macro from xtrans.m4 +# Dependencies to place before the objects being linked to create a +# shared library. +predeps=$lt_predeps_F77 - # Check whether --enable-secure-rpc was given. -if test "${enable_secure_rpc+set}" = set; then - enableval=$enable_secure_rpc; SECURE_RPC=$enableval -else - SECURE_RPC="try" -fi +# Dependencies to place after the objects being linked to create a +# shared library. +postdeps=$lt_postdeps_F77 +# The directories searched by this compiler when creating a shared +# library +compiler_lib_search_dirs=$lt_compiler_lib_search_dirs_F77 - if test "x$SECURE_RPC" = "xyes" -o "x$SECURE_RPC" = "xtry" ; then - FOUND_SECURE_RPC="no" +# The library search path used internally by the compiler when linking +# a shared library. +compiler_lib_search_path=$lt_compiler_lib_search_path_F77 +# Method to check whether dependent libraries are shared objects. +deplibs_check_method=$lt_deplibs_check_method -for ac_func in authdes_seccreate authdes_create -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; 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. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func +# Command to use when deplibs_check_method == file_magic. +file_magic_cmd=$lt_file_magic_cmd -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ +# Flag that allows shared libraries with undefined symbols to be built. +allow_undefined_flag=$lt_allow_undefined_flag_F77 -#ifdef __STDC__ -# include -#else -# include -#endif +# Flag that forces no undefined symbols. +no_undefined_flag=$lt_no_undefined_flag_F77 -#undef $ac_func +# Commands used to finish a libtool library installation in a directory. +finish_cmds=$lt_finish_cmds -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif +# Same as above, but a single script fragment to be evaled but not shown. +finish_eval=$lt_finish_eval -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext 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>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_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 +# Take the output of nm and produce a listing of raw symbols and C names. +global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe - eval "$as_ac_var=no" -fi +# Transform the output of nm in a proper C declaration +global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 -_ACEOF - FOUND_SECURE_RPC="yes" -fi -done +# Transform the output of nm in a C name address pair +global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address - if test "x$FOUND_SECURE_RPC" = "xno" ; then - if test "x$SECURE_RPC" = "xyes" ; then - { { $as_echo "$as_me:$LINENO: error: Secure RPC requested, but required functions not found" >&5 -$as_echo "$as_me: error: Secure RPC requested, but required functions not found" >&2;} - { (exit 1); exit 1; }; } - fi - SECURE_RPC="no" - else - { $as_echo "$as_me:$LINENO: checking for library containing getsecretkey" >&5 -$as_echo_n "checking for library containing getsecretkey... " >&6; } -if test "${ac_cv_search_getsecretkey+set}" = set; then - $as_echo_n "(cached) " >&6 -else - ac_func_search_save_LIBS=$LIBS -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ +# This is the shared library runtime path variable. +runpath_var=$runpath_var -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char getsecretkey (); -int -main () -{ -return getsecretkey (); - ; - return 0; -} -_ACEOF -for ac_lib in '' rpcsvc; do - if test -z "$ac_lib"; then - ac_res="none required" - else - ac_res=-l$ac_lib - LIBS="-l$ac_lib $ac_func_search_save_LIBS" - fi - rm -f conftest.$ac_objext 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>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_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - ac_cv_search_getsecretkey=$ac_res -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 +# This is the shared library path variable. +shlibpath_var=$shlibpath_var +# Is shlibpath searched before the hard-coded library search path? +shlibpath_overrides_runpath=$shlibpath_overrides_runpath -fi +# How to hardcode a shared library path into an executable. +hardcode_action=$hardcode_action_F77 -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext - if test "${ac_cv_search_getsecretkey+set}" = set; then - break -fi -done -if test "${ac_cv_search_getsecretkey+set}" = set; then - : -else - ac_cv_search_getsecretkey=no -fi -rm conftest.$ac_ext -LIBS=$ac_func_search_save_LIBS -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_search_getsecretkey" >&5 -$as_echo "$ac_cv_search_getsecretkey" >&6; } -ac_res=$ac_cv_search_getsecretkey -if test "$ac_res" != no; then - test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" +# Whether we should hardcode library paths into libraries. +hardcode_into_libs=$hardcode_into_libs -fi +# Flag to hardcode \$libdir into a binary during linking. +# This must work even if \$libdir does not exist. +hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec_F77 - SECURE_RPC="yes" - fi - fi - { $as_echo "$as_me:$LINENO: checking if Secure RPC authentication (\"SUN-DES-1\") should be supported" >&5 -$as_echo_n "checking if Secure RPC authentication (\"SUN-DES-1\") should be supported... " >&6; } - if test "x$SECURE_RPC" = "xyes" ; then +# If ld is used when linking, flag to hardcode \$libdir into +# a binary during linking. This must work even if \$libdir does +# not exist. +hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld_F77 -cat >>confdefs.h <<\_ACEOF -#define SECURE_RPC 1 -_ACEOF +# Whether we need a single -rpath flag with a separated argument. +hardcode_libdir_separator=$lt_hardcode_libdir_separator_F77 - fi - { $as_echo "$as_me:$LINENO: result: $SECURE_RPC" >&5 -$as_echo "$SECURE_RPC" >&6; } +# Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the +# resulting binary. +hardcode_direct=$hardcode_direct_F77 +# Set to yes if using the -LDIR flag during linking hardcodes DIR into the +# resulting binary. +hardcode_minus_L=$hardcode_minus_L_F77 -# Preferred order to try transports for local connections -{ $as_echo "$as_me:$LINENO: checking what order to try transports in for local connections" >&5 -$as_echo_n "checking what order to try transports in for local connections... " >&6; } -case $host_os in - solaris*) - # On Solaris 2.6 through 9, named pipes (LOCAL_TRANS) were - # faster than Unix domain sockets, but on Solaris 10 & later, - # Unix domain sockets are faster now. - DEFAULT_LOCAL_TRANS="UNIX_TRANS,LOCAL_TRANS,TCP_TRANS" - ;; - *) - if test "$LOCALCONN" = "yes"; then - DEFAULT_LOCAL_TRANS="LOCAL_TRANS,UNIX_TRANS,TCP_TRANS" - else - DEFAULT_LOCAL_TRANS="UNIX_TRANS,TCP_TRANS" - fi - ;; -esac +# Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into +# the resulting binary. +hardcode_shlibpath_var=$hardcode_shlibpath_var_F77 +# Set to yes if building a shared library automatically hardcodes DIR into the library +# and all subsequent libraries and executables linked against it. +hardcode_automatic=$hardcode_automatic_F77 -# Check whether --with-local-transport-order was given. -if test "${with_local_transport_order+set}" = set; then - withval=$with_local_transport_order; LOCAL_TRANSPORT_LIST=$withval -else - LOCAL_TRANSPORT_LIST=$DEFAULT_LOCAL_TRANS -fi +# Variables whose values should be saved in libtool wrapper scripts and +# restored at relink time. +variables_saved_for_relink="$variables_saved_for_relink" +# Whether libtool must link a program against all its dependency libraries. +link_all_deplibs=$link_all_deplibs_F77 -cat >>confdefs.h <<_ACEOF -#define LOCAL_TRANSPORT_LIST $LOCAL_TRANSPORT_LIST -_ACEOF +# Compile-time system search path for libraries +sys_lib_search_path_spec=$lt_sys_lib_search_path_spec -{ $as_echo "$as_me:$LINENO: result: $LOCAL_TRANSPORT_LIST" >&5 -$as_echo "$LOCAL_TRANSPORT_LIST" >&6; } +# Run-time system search path for libraries +sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec -# Check for dlopen -{ $as_echo "$as_me:$LINENO: checking if run-time linking is supported" >&5 -$as_echo_n "checking if run-time linking is supported... " >&6; } -{ $as_echo "$as_me:$LINENO: checking for library containing dlopen" >&5 -$as_echo_n "checking for library containing dlopen... " >&6; } -if test "${ac_cv_search_dlopen+set}" = set; then - $as_echo_n "(cached) " >&6 -else - ac_func_search_save_LIBS=$LIBS -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ +# Fix the shell variable \$srcfile for the compiler. +fix_srcfile_path=$lt_fix_srcfile_path -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char dlopen (); -int -main () -{ -return dlopen (); - ; - return 0; -} -_ACEOF -for ac_lib in '' dl svld; do - if test -z "$ac_lib"; then - ac_res="none required" - else - ac_res=-l$ac_lib - LIBS="-l$ac_lib $ac_func_search_save_LIBS" - fi - rm -f conftest.$ac_objext 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>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_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - ac_cv_search_dlopen=$ac_res -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 +# Set to yes if exported symbols are required. +always_export_symbols=$always_export_symbols_F77 +# The commands to list exported symbols. +export_symbols_cmds=$lt_export_symbols_cmds_F77 + +# The commands to extract the exported symbol list from a shared archive. +extract_expsyms_cmds=$lt_extract_expsyms_cmds + +# Symbols that should not be listed in the preloaded symbols. +exclude_expsyms=$lt_exclude_expsyms_F77 + +# Symbols that must always be exported. +include_expsyms=$lt_include_expsyms_F77 +# ### END LIBTOOL TAG CONFIG: $tagname + +__EOF__ + + +else + # If there is no Makefile yet, we rely on a make rule to execute + # `config.status --recheck' to rerun these tests and create the + # libtool script then. + ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'` + if test -f "$ltmain_in"; then + test -f Makefile && make "$ltmain" + fi fi -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext - if test "${ac_cv_search_dlopen+set}" = set; then - break -fi -done -if test "${ac_cv_search_dlopen+set}" = set; then - : -else - ac_cv_search_dlopen=no -fi -rm conftest.$ac_ext -LIBS=$ac_func_search_save_LIBS -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_search_dlopen" >&5 -$as_echo "$ac_cv_search_dlopen" >&6; } -ac_res=$ac_cv_search_dlopen -if test "$ac_res" != no; then - test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" -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 -if test "x$ac_cv_search_dlopen" = xno; then - { $as_echo "$as_me:$LINENO: checking for library containing shl_load" >&5 -$as_echo_n "checking for library containing shl_load... " >&6; } -if test "${ac_cv_search_shl_load+set}" = set; then - $as_echo_n "(cached) " >&6 -else - ac_func_search_save_LIBS=$LIBS -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ +CC="$lt_save_CC" -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char shl_load (); -int -main () -{ -return shl_load (); - ; - return 0; -} -_ACEOF -for ac_lib in '' dld; do - if test -z "$ac_lib"; then - ac_res="none required" - else - ac_res=-l$ac_lib - LIBS="-l$ac_lib $ac_func_search_save_LIBS" - fi - rm -f conftest.$ac_objext 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>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_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - ac_cv_search_shl_load=$ac_res -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 + else + tagname="" + fi + ;; + GCJ) + if test -n "$GCJ" && test "X$GCJ" != "Xno"; then -fi -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext - if test "${ac_cv_search_shl_load+set}" = set; then - break -fi +# Source file extension for Java test sources. +ac_ext=java + +# Object file extension for compiled Java test sources. +objext=o +objext_GCJ=$objext + +# Code to be used in simple compile tests +lt_simple_compile_test_code="class foo {}" + +# Code to be used in simple link tests +lt_simple_link_test_code='public class conftest { public static void main(String[] argv) {}; }' + +# ltmain only uses $CC for tagged configurations so make sure $CC is set. + +# If no C compiler was specified, use CC. +LTCC=${LTCC-"$CC"} + +# If no C compiler flags were specified, use CFLAGS. +LTCFLAGS=${LTCFLAGS-"$CFLAGS"} + +# Allow CC to be a program name with arguments. +compiler=$CC + + +# save warnings/boilerplate of simple test code +ac_outfile=conftest.$ac_objext +echo "$lt_simple_compile_test_code" >conftest.$ac_ext +eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err +_lt_compiler_boilerplate=`cat conftest.err` +$rm conftest* + +ac_outfile=conftest.$ac_objext +echo "$lt_simple_link_test_code" >conftest.$ac_ext +eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err +_lt_linker_boilerplate=`cat conftest.err` +$rm -r conftest* + + +# Allow CC to be a program name with arguments. +lt_save_CC="$CC" +CC=${GCJ-"gcj"} +compiler=$CC +compiler_GCJ=$CC +for cc_temp in $compiler""; do + case $cc_temp in + compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; + distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; + \-*) ;; + *) break;; + esac done -if test "${ac_cv_search_shl_load+set}" = set; then - : -else - ac_cv_search_shl_load=no -fi -rm conftest.$ac_ext -LIBS=$ac_func_search_save_LIBS -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_search_shl_load" >&5 -$as_echo "$ac_cv_search_shl_load" >&6; } -ac_res=$ac_cv_search_shl_load -if test "$ac_res" != no; then - test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" +cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` -fi - if test "x$ac_cv_search_shl_load" != xno; then +# GCJ did not exist at the time GCC didn't implicitly link libc in. +archive_cmds_need_lc_GCJ=no -cat >>confdefs.h <<\_ACEOF -#define HAVE_SHL_LOAD 1 -_ACEOF +old_archive_cmds_GCJ=$old_archive_cmds -for ac_header in dl.h -do -as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` -if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then - { $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 +lt_prog_compiler_no_builtin_flag_GCJ= + +if test "$GCC" = yes; then + lt_prog_compiler_no_builtin_flag_GCJ=' -fno-builtin' + + +{ $as_echo "$as_me:$LINENO: checking if $compiler supports -fno-rtti -fno-exceptions" >&5 +$as_echo_n "checking if $compiler supports -fno-rtti -fno-exceptions... " >&6; } +if test "${lt_cv_prog_compiler_rtti_exceptions+set}" = set; then $as_echo_n "(cached) " >&6 -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; } else - # Is the header compilable? -{ $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5 -$as_echo_n "checking $ac_header usability... " >&6; } -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 - ac_header_compiler=yes + lt_cv_prog_compiler_rtti_exceptions=no + ac_outfile=conftest.$ac_objext + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + lt_compiler_flag="-fno-rtti -fno-exceptions" + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + # The option is referenced via a variable to avoid confusing sed. + lt_compile=`echo "$ac_compile" | $SED \ + -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:17349: $lt_compile\"" >&5) + (eval "$lt_compile" 2>conftest.err) + ac_status=$? + cat conftest.err >&5 + echo "$as_me:17353: \$? = $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. + $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then + lt_cv_prog_compiler_rtti_exceptions=yes + fi + fi + $rm conftest* + +fi +{ $as_echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_rtti_exceptions" >&5 +$as_echo "$lt_cv_prog_compiler_rtti_exceptions" >&6; } + +if test x"$lt_cv_prog_compiler_rtti_exceptions" = xyes; then + lt_prog_compiler_no_builtin_flag_GCJ="$lt_prog_compiler_no_builtin_flag_GCJ -fno-rtti -fno-exceptions" else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 + : +fi - ac_header_compiler=no fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -{ $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 -$as_echo "$ac_header_compiler" >&6; } +lt_prog_compiler_wl_GCJ= +lt_prog_compiler_pic_GCJ= +lt_prog_compiler_static_GCJ= -# Is the header present? -{ $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5 -$as_echo_n "checking $ac_header presence... " >&6; } -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include <$ac_header> -_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 - ac_header_preproc=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 +{ $as_echo "$as_me:$LINENO: checking for $compiler option to produce PIC" >&5 +$as_echo_n "checking for $compiler option to produce PIC... " >&6; } - ac_header_preproc=no -fi + if test "$GCC" = yes; then + lt_prog_compiler_wl_GCJ='-Wl,' + lt_prog_compiler_static_GCJ='-static' -rm -f conftest.err conftest.$ac_ext -{ $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 -$as_echo "$ac_header_preproc" >&6; } + case $host_os in + aix*) + # All AIX code is PIC. + if test "$host_cpu" = ia64; then + # AIX 5 now supports IA64 processor + lt_prog_compiler_static_GCJ='-Bstatic' + fi + ;; -# So? What about this header? -case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in - yes:no: ) - { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5 -$as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;} - { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5 -$as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;} - ac_header_preproc=yes - ;; - no:yes:* ) - { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5 -$as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;} - { $as_echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5 -$as_echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;} - { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5 -$as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;} - { $as_echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5 -$as_echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;} - { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5 -$as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;} - { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5 -$as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;} - ( cat <<\_ASBOX -## ---------------------------------------------------------------------- ## -## Report this to https://bugs.freedesktop.org/enter_bug.cgi?product=xorg ## -## ---------------------------------------------------------------------- ## -_ASBOX - ) | sed "s/^/$as_me: WARNING: /" >&2 - ;; -esac -{ $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 - eval "$as_ac_Header=\$ac_header_preproc" -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; } + amigaos*) + # FIXME: we need at least 68020 code to build shared libraries, but + # adding the `-m68020' flag to GCC prevents building anything better, + # like `-m68040'. + lt_prog_compiler_pic_GCJ='-m68020 -resident32 -malways-restore-a4' + ;; -fi -as_val=`eval 'as_val=${'$as_ac_Header'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 -_ACEOF + beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) + # PIC is the default for these OSes. + ;; -fi + mingw* | cygwin* | pw32* | os2*) + # This hack is so that the source file can tell whether it is being + # built for inclusion in a dll (and should export symbols for example). + # Although the cygwin gcc ignores -fPIC, still need this for old-style + # (--disable-auto-import) libraries -done + ;; - fi -else + darwin* | rhapsody*) + # PIC is the default on this platform + # Common symbols not allowed in MH_DYLIB files + lt_prog_compiler_pic_GCJ='-fno-common' + ;; -cat >>confdefs.h <<\_ACEOF -#define HAVE_DLOPEN 1 -_ACEOF + interix[3-9]*) + # Interix 3.x gcc -fpic/-fPIC options generate broken code. + # Instead, we relocate shared libraries at runtime. + ;; + msdosdjgpp*) + # Just because we use GCC doesn't mean we suddenly get shared libraries + # on systems that don't support them. + lt_prog_compiler_can_build_shared_GCJ=no + enable_shared=no + ;; -for ac_header in dlfcn.h -do -as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` -if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then - { $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 -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; } -else - # Is the header compilable? -{ $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5 -$as_echo_n "checking $ac_header usability... " >&6; } -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 - ac_header_compiler=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 + sysv4*MP*) + if test -d /usr/nec; then + lt_prog_compiler_pic_GCJ=-Kconform_pic + fi + ;; - ac_header_compiler=no -fi + hpux*) + # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but + # not for PA HP-UX. + case $host_cpu in + hppa*64*|ia64*) + # +Z the default + ;; + *) + lt_prog_compiler_pic_GCJ='-fPIC' + ;; + esac + ;; -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -{ $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 -$as_echo "$ac_header_compiler" >&6; } + *) + lt_prog_compiler_pic_GCJ='-fPIC' + ;; + esac + else + # PORTME Check for flag to pass linker flags through the system compiler. + case $host_os in + aix*) + lt_prog_compiler_wl_GCJ='-Wl,' + if test "$host_cpu" = ia64; then + # AIX 5 now supports IA64 processor + lt_prog_compiler_static_GCJ='-Bstatic' + else + lt_prog_compiler_static_GCJ='-bnso -bI:/lib/syscalls.exp' + fi + ;; + darwin*) + # PIC is the default on this platform + # Common symbols not allowed in MH_DYLIB files + case $cc_basename in + xlc*) + lt_prog_compiler_pic_GCJ='-qnocommon' + lt_prog_compiler_wl_GCJ='-Wl,' + ;; + esac + ;; -# Is the header present? -{ $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5 -$as_echo_n "checking $ac_header presence... " >&6; } -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include <$ac_header> -_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 - ac_header_preproc=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 + mingw* | cygwin* | pw32* | os2*) + # This hack is so that the source file can tell whether it is being + # built for inclusion in a dll (and should export symbols for example). - ac_header_preproc=no -fi + ;; -rm -f conftest.err conftest.$ac_ext -{ $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 -$as_echo "$ac_header_preproc" >&6; } + hpux9* | hpux10* | hpux11*) + lt_prog_compiler_wl_GCJ='-Wl,' + # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but + # not for PA HP-UX. + case $host_cpu in + hppa*64*|ia64*) + # +Z the default + ;; + *) + lt_prog_compiler_pic_GCJ='+Z' + ;; + esac + # Is there a better lt_prog_compiler_static that works with the bundled CC? + lt_prog_compiler_static_GCJ='${wl}-a ${wl}archive' + ;; -# So? What about this header? -case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in - yes:no: ) - { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5 -$as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;} - { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5 -$as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;} - ac_header_preproc=yes - ;; - no:yes:* ) - { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5 -$as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;} - { $as_echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5 -$as_echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;} - { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5 -$as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;} - { $as_echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5 -$as_echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;} - { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5 -$as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;} - { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5 -$as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;} - ( cat <<\_ASBOX -## ---------------------------------------------------------------------- ## -## Report this to https://bugs.freedesktop.org/enter_bug.cgi?product=xorg ## -## ---------------------------------------------------------------------- ## -_ASBOX - ) | sed "s/^/$as_me: WARNING: /" >&2 - ;; -esac -{ $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 - eval "$as_ac_Header=\$ac_header_preproc" -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; } - -fi -as_val=`eval 'as_val=${'$as_ac_Header'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 -_ACEOF + irix5* | irix6* | nonstopux*) + lt_prog_compiler_wl_GCJ='-Wl,' + # PIC (with -KPIC) is the default. + lt_prog_compiler_static_GCJ='-non_shared' + ;; -fi + newsos6) + lt_prog_compiler_pic_GCJ='-KPIC' + lt_prog_compiler_static_GCJ='-Bstatic' + ;; -done + linux* | k*bsd*-gnu) + case $cc_basename in + icc* | ecc*) + lt_prog_compiler_wl_GCJ='-Wl,' + lt_prog_compiler_pic_GCJ='-KPIC' + lt_prog_compiler_static_GCJ='-static' + ;; + pgcc* | pgf77* | pgf90* | pgf95*) + # Portland Group compilers (*not* the Pentium gcc compiler, + # which looks to be a dead project) + lt_prog_compiler_wl_GCJ='-Wl,' + lt_prog_compiler_pic_GCJ='-fpic' + lt_prog_compiler_static_GCJ='-Bstatic' + ;; + ccc*) + lt_prog_compiler_wl_GCJ='-Wl,' + # All Alpha code is PIC. + lt_prog_compiler_static_GCJ='-non_shared' + ;; + *) + case `$CC -V 2>&1 | sed 5q` in + *Sun\ C*) + # Sun C 5.9 + lt_prog_compiler_pic_GCJ='-KPIC' + lt_prog_compiler_static_GCJ='-Bstatic' + lt_prog_compiler_wl_GCJ='-Wl,' + ;; + *Sun\ F*) + # Sun Fortran 8.3 passes all unrecognized flags to the linker + lt_prog_compiler_pic_GCJ='-KPIC' + lt_prog_compiler_static_GCJ='-Bstatic' + lt_prog_compiler_wl_GCJ='' + ;; + esac + ;; + esac + ;; -fi -if test x$ac_cv_header_dlcfn_h -o x$ac_cv_header_dl_h; then - HAVE_LOADABLE_MODULES=yes -else - HAVE_LOADABLE_MODULES=no -fi -{ $as_echo "$as_me:$LINENO: result: $HAVE_LOADABLE_MODULES" >&5 -$as_echo "$HAVE_LOADABLE_MODULES" >&6; } + osf3* | osf4* | osf5*) + lt_prog_compiler_wl_GCJ='-Wl,' + # All OSF/1 code is PIC. + lt_prog_compiler_static_GCJ='-non_shared' + ;; -{ $as_echo "$as_me:$LINENO: checking if loadable i18n module support should be enabled" >&5 -$as_echo_n "checking if loadable i18n module support should be enabled... " >&6; } -# Check whether --enable-loadable-i18n was given. -if test "${enable_loadable_i18n+set}" = set; then - enableval=$enable_loadable_i18n; XLIB_LOADABLE_I18N=$enableval -else - XLIB_LOADABLE_I18N="no" -fi + rdos*) + lt_prog_compiler_static_GCJ='-non_shared' + ;; -if test x$XLIB_LOADABLE_I18N = xyes; then - if test x$HAVE_LOADABLE_MODULES = xno; then - { { $as_echo "$as_me:$LINENO: error: Loadable module support is required to enable loadable i18n module support" >&5 -$as_echo "$as_me: error: Loadable module support is required to enable loadable i18n module support" >&2;} - { (exit 1); exit 1; }; } - fi + solaris*) + lt_prog_compiler_pic_GCJ='-KPIC' + lt_prog_compiler_static_GCJ='-Bstatic' + case $cc_basename in + f77* | f90* | f95*) + lt_prog_compiler_wl_GCJ='-Qoption ld ';; + *) + lt_prog_compiler_wl_GCJ='-Wl,';; + esac + ;; -cat >>confdefs.h <<\_ACEOF -#define USE_DYNAMIC_LC 1 -_ACEOF + sunos4*) + lt_prog_compiler_wl_GCJ='-Qoption ld ' + lt_prog_compiler_pic_GCJ='-PIC' + lt_prog_compiler_static_GCJ='-Bstatic' + ;; - I18N_MODULE_LIBS='${top_builddir}/src/libX11.la' + sysv4 | sysv4.2uw2* | sysv4.3*) + lt_prog_compiler_wl_GCJ='-Wl,' + lt_prog_compiler_pic_GCJ='-KPIC' + lt_prog_compiler_static_GCJ='-Bstatic' + ;; -fi -{ $as_echo "$as_me:$LINENO: result: $XLIB_LOADABLE_I18N" >&5 -$as_echo "$XLIB_LOADABLE_I18N" >&6; } + sysv4*MP*) + if test -d /usr/nec ;then + lt_prog_compiler_pic_GCJ='-Kconform_pic' + lt_prog_compiler_static_GCJ='-Bstatic' + fi + ;; - if test x$XLIB_LOADABLE_I18N = xyes; then - XLIB_LOADABLE_I18N_TRUE= - XLIB_LOADABLE_I18N_FALSE='#' -else - XLIB_LOADABLE_I18N_TRUE='#' - XLIB_LOADABLE_I18N_FALSE= -fi + sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) + lt_prog_compiler_wl_GCJ='-Wl,' + lt_prog_compiler_pic_GCJ='-KPIC' + lt_prog_compiler_static_GCJ='-Bstatic' + ;; + unicos*) + lt_prog_compiler_wl_GCJ='-Wl,' + lt_prog_compiler_can_build_shared_GCJ=no + ;; -{ $as_echo "$as_me:$LINENO: checking if loadable Xcursor library support should be enabled" >&5 -$as_echo_n "checking if loadable Xcursor library support should be enabled... " >&6; } -# Check whether --enable-loadable-xcursor was given. -if test "${enable_loadable_xcursor+set}" = set; then - enableval=$enable_loadable_xcursor; XLIB_LOADABLE_XCURSOR=$enableval -else - XLIB_LOADABLE_XCURSOR=$HAVE_LOADABLE_MODULES -fi + uts4*) + lt_prog_compiler_pic_GCJ='-pic' + lt_prog_compiler_static_GCJ='-Bstatic' + ;; -if test x$XLIB_LOADABLE_XCURSOR = xyes; then + *) + lt_prog_compiler_can_build_shared_GCJ=no + ;; + esac + fi -cat >>confdefs.h <<\_ACEOF -#define USE_DYNAMIC_XCURSOR 1 -_ACEOF +{ $as_echo "$as_me:$LINENO: result: $lt_prog_compiler_pic_GCJ" >&5 +$as_echo "$lt_prog_compiler_pic_GCJ" >&6; } -fi -{ $as_echo "$as_me:$LINENO: result: $XLIB_LOADABLE_XCURSOR" >&5 -$as_echo "$XLIB_LOADABLE_XCURSOR" >&6; } +# +# Check to make sure the PIC flag actually works. +# +if test -n "$lt_prog_compiler_pic_GCJ"; then -# Checks for header files. -{ $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 "$as_me:$LINENO: checking if $compiler PIC flag $lt_prog_compiler_pic_GCJ works" >&5 +$as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic_GCJ works... " >&6; } +if test "${lt_cv_prog_compiler_pic_works_GCJ+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 -#include -#include -#include + lt_cv_prog_compiler_pic_works_GCJ=no + ac_outfile=conftest.$ac_objext + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + lt_compiler_flag="$lt_prog_compiler_pic_GCJ" + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + # The option is referenced via a variable to avoid confusing sed. + lt_compile=`echo "$ac_compile" | $SED \ + -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:17639: $lt_compile\"" >&5) + (eval "$lt_compile" 2>conftest.err) + ac_status=$? + cat conftest.err >&5 + echo "$as_me:17643: \$? = $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. + $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then + lt_cv_prog_compiler_pic_works_GCJ=yes + fi + fi + $rm conftest* -int -main () -{ +fi +{ $as_echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_pic_works_GCJ" >&5 +$as_echo "$lt_cv_prog_compiler_pic_works_GCJ" >&6; } - ; - 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;; +if test x"$lt_cv_prog_compiler_pic_works_GCJ" = xyes; then + case $lt_prog_compiler_pic_GCJ in + "" | " "*) ;; + *) lt_prog_compiler_pic_GCJ=" $lt_prog_compiler_pic_GCJ" ;; + esac +else + lt_prog_compiler_pic_GCJ= + lt_prog_compiler_can_build_shared_GCJ=no +fi + +fi +case $host_os in + # For platforms which do not support PIC, -DPIC is meaningless: + *djgpp*) + lt_prog_compiler_pic_GCJ= + ;; + *) + lt_prog_compiler_pic_GCJ="$lt_prog_compiler_pic_GCJ" + ;; 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 + +# +# Check to make sure the static flag actually works. +# +wl=$lt_prog_compiler_wl_GCJ eval lt_tmp_static_flag=\"$lt_prog_compiler_static_GCJ\" +{ $as_echo "$as_me:$LINENO: checking if $compiler static flag $lt_tmp_static_flag works" >&5 +$as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; } +if test "${lt_cv_prog_compiler_static_works_GCJ+set}" = set; then + $as_echo_n "(cached) " >&6 else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 + lt_cv_prog_compiler_static_works_GCJ=no + save_LDFLAGS="$LDFLAGS" + LDFLAGS="$LDFLAGS $lt_tmp_static_flag" + echo "$lt_simple_link_test_code" > conftest.$ac_ext + if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then + # The linker can only warn and ignore the option if not recognized + # So say no if there are warnings + if test -s conftest.err; then + # Append any errors to the config.log. + cat conftest.err 1>&5 + $echo "X$_lt_linker_boilerplate" | $Xsed -e '/^$/d' > conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if diff conftest.exp conftest.er2 >/dev/null; then + lt_cv_prog_compiler_static_works_GCJ=yes + fi + else + lt_cv_prog_compiler_static_works_GCJ=yes + fi + fi + $rm -r conftest* + LDFLAGS="$save_LDFLAGS" - ac_cv_header_stdc=no fi +{ $as_echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_static_works_GCJ" >&5 +$as_echo "$lt_cv_prog_compiler_static_works_GCJ" >&6; } -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +if test x"$lt_cv_prog_compiler_static_works_GCJ" = xyes; then + : +else + lt_prog_compiler_static_GCJ= +fi -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 -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "memchr" >/dev/null 2>&1; then - : +{ $as_echo "$as_me:$LINENO: checking if $compiler supports -c -o file.$ac_objext" >&5 +$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } +if test "${lt_cv_prog_compiler_c_o_GCJ+set}" = set; then + $as_echo_n "(cached) " >&6 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 + lt_cv_prog_compiler_c_o_GCJ=no + $rm -r conftest 2>/dev/null + mkdir conftest + cd conftest + mkdir out + echo "$lt_simple_compile_test_code" > conftest.$ac_ext -_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* + lt_compiler_flag="-o out/conftest2.$ac_objext" + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + lt_compile=`echo "$ac_compile" | $SED \ + -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:17743: $lt_compile\"" >&5) + (eval "$lt_compile" 2>out/conftest.err) + ac_status=$? + cat out/conftest.err >&5 + echo "$as_me:17747: \$? = $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 + # So say no if there are warnings + $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp + $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 + if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then + lt_cv_prog_compiler_c_o_GCJ=yes + fi + fi + chmod u+w . 2>&5 + $rm conftest* + # SGI C++ compiler will create directory out/ii_files/ for + # template instantiation + test -d out/ii_files && $rm out/ii_files/* && rmdir out/ii_files + $rm out/* && rmdir out + cd .. + rmdir conftest + $rm conftest* fi +{ $as_echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_c_o_GCJ" >&5 +$as_echo "$lt_cv_prog_compiler_c_o_GCJ" >&6; } -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 -#include -#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 - : +hard_links="nottested" +if test "$lt_cv_prog_compiler_c_o_GCJ" = no && test "$need_locks" != no; then + # do not overwrite the value of need_locks provided by the user + { $as_echo "$as_me:$LINENO: checking if we can lock with hard links" >&5 +$as_echo_n "checking if we can lock with hard links... " >&6; } + hard_links=yes + $rm conftest* + ln conftest.a conftest.b 2>/dev/null && hard_links=no + touch conftest.a + ln conftest.a conftest.b 2>&5 || hard_links=no + ln conftest.a conftest.b 2>/dev/null && hard_links=no + { $as_echo "$as_me:$LINENO: result: $hard_links" >&5 +$as_echo "$hard_links" >&6; } + if test "$hard_links" = no; then + { $as_echo "$as_me:$LINENO: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5 +$as_echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;} + need_locks=warn + fi 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 + need_locks=no fi +{ $as_echo "$as_me:$LINENO: checking whether the $compiler linker ($LD) supports shared libraries" >&5 +$as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; } -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 + runpath_var= + allow_undefined_flag_GCJ= + enable_shared_with_static_runtimes_GCJ=no + archive_cmds_GCJ= + archive_expsym_cmds_GCJ= + old_archive_From_new_cmds_GCJ= + old_archive_from_expsyms_cmds_GCJ= + export_dynamic_flag_spec_GCJ= + whole_archive_flag_spec_GCJ= + thread_safe_flag_spec_GCJ= + hardcode_libdir_flag_spec_GCJ= + hardcode_libdir_flag_spec_ld_GCJ= + hardcode_libdir_separator_GCJ= + hardcode_direct_GCJ=no + hardcode_minus_L_GCJ=no + hardcode_shlibpath_var_GCJ=unsupported + link_all_deplibs_GCJ=unknown + hardcode_automatic_GCJ=no + module_cmds_GCJ= + module_expsym_cmds_GCJ= + always_export_symbols_GCJ=no + export_symbols_cmds_GCJ='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' + # include_expsyms should be a list of space-separated symbols to be *always* + # included in the symbol list + include_expsyms_GCJ= + # exclude_expsyms can be an extended regexp of symbols to exclude + # it will be wrapped by ` (' and `)$', so one must not match beginning or + # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc', + # as well as any symbol that contains `d'. + exclude_expsyms_GCJ='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*' + # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out + # platforms (ab)use it in PIC code, but their linkers get confused if + # the symbol is explicitly referenced. Since portable code cannot + # rely on this symbol name, it's probably fine to never include it in + # preloaded symbol tables. + # Exclude shared library initialization/finalization symbols. + extract_expsyms_cmds= + # Just being paranoid about ensuring that cc_basename is set. + for cc_temp in $compiler""; do + case $cc_temp in + compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; + distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; + \-*) ;; + *) break;; + esac +done +cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` -fi + case $host_os in + cygwin* | mingw* | pw32*) + # FIXME: the MSVC++ port hasn't been tested in a loooong time + # When not using gcc, we currently assume that we are using + # Microsoft Visual C++. + if test "$GCC" != yes; then + with_gnu_ld=no + fi + ;; + interix*) + # we just hope/assume this is gcc and not c89 (= MSVC++) + with_gnu_ld=yes + ;; + openbsd*) + with_gnu_ld=no + ;; + esac + ld_shlibs_GCJ=yes + if test "$with_gnu_ld" = yes; then + # If archive_cmds runs LD, not CC, wlarc should be empty + wlarc='${wl}' -# Checks for typedefs, structures, and compiler characteristics. + # Set some defaults for GNU ld with shared library support. These + # are reset later if shared libraries are not supported. Putting them + # here allows them to be overridden if necessary. + runpath_var=LD_RUN_PATH + hardcode_libdir_flag_spec_GCJ='${wl}--rpath ${wl}$libdir' + export_dynamic_flag_spec_GCJ='${wl}--export-dynamic' + # ancient GNU ld didn't support --whole-archive et. al. + if $LD --help 2>&1 | grep 'no-whole-archive' > /dev/null; then + whole_archive_flag_spec_GCJ="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' + else + whole_archive_flag_spec_GCJ= + fi + supports_anon_versioning=no + case `$LD -v 2>/dev/null` in + *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11 + *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... + *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... + *\ 2.11.*) ;; # other 2.11 versions + *) supports_anon_versioning=yes ;; + esac -# Checks for library functions. + # See if GNU ld supports shared libraries. + case $host_os in + aix[3-9]*) + # On AIX/PPC, the GNU linker is very broken + if test "$host_cpu" != ia64; then + ld_shlibs_GCJ=no + cat <&2 -for ac_func in strtol -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; 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. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func +*** Warning: the GNU linker, at least up to release 2.9.1, is reported +*** to be unable to reliably create shared libraries on AIX. +*** Therefore, libtool is disabling shared libraries support. If you +*** really care for shared libraries, you may want to modify your PATH +*** so that a non-GNU linker is found, and then restart. -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ +EOF + fi + ;; -#ifdef __STDC__ -# include -#else -# include -#endif + amigaos*) + archive_cmds_GCJ='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' + hardcode_libdir_flag_spec_GCJ='-L$libdir' + hardcode_minus_L_GCJ=yes + + # Samuel A. Falvo II reports + # that the semantics of dynamic libraries on AmigaOS, at least up + # to version 4, is to share data among multiple programs linked + # with the same dynamic library. Since this doesn't match the + # behavior of shared libraries on other platforms, we can't use + # them. + ld_shlibs_GCJ=no + ;; -#undef $ac_func + beos*) + if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then + allow_undefined_flag_GCJ=unsupported + # Joseph Beckenbach says some releases of gcc + # support --undefined. This deserves some investigation. FIXME + archive_cmds_GCJ='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + else + ld_shlibs_GCJ=no + fi + ;; -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif + cygwin* | mingw* | pw32*) + # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, GCJ) is actually meaningless, + # as there is no search path for DLLs. + hardcode_libdir_flag_spec_GCJ='-L$libdir' + allow_undefined_flag_GCJ=unsupported + always_export_symbols_GCJ=no + enable_shared_with_static_runtimes_GCJ=yes + export_symbols_cmds_GCJ='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/'\'' -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols' + + if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then + archive_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + # If the export-symbols file already is a .def file (1st line + # is EXPORTS), use it as is; otherwise, prepend... + archive_expsym_cmds_GCJ='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then + cp $export_symbols $output_objdir/$soname.def; + else + echo EXPORTS > $output_objdir/$soname.def; + cat $export_symbols >> $output_objdir/$soname.def; + fi~ + $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + else + ld_shlibs_GCJ=no + fi + ;; + + interix[3-9]*) + hardcode_direct_GCJ=no + hardcode_shlibpath_var_GCJ=no + hardcode_libdir_flag_spec_GCJ='${wl}-rpath,$libdir' + export_dynamic_flag_spec_GCJ='${wl}-E' + # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. + # Instead, shared libraries are loaded at an image base (0x10000000 by + # default) and relocated if they conflict, which is a slow very memory + # consuming and fragmenting process. To avoid this, we pick a random, + # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link + # time. Moving up from 0x10000000 also allows more sbrk(2) space. + archive_cmds_GCJ='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + archive_expsym_cmds_GCJ='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + ;; + + gnu* | linux* | k*bsd*-gnu) + if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then + tmp_addflag= + case $cc_basename,$host_cpu in + pgcc*) # Portland Group C compiler + whole_archive_flag_spec_GCJ='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' + tmp_addflag=' $pic_flag' + ;; + pgf77* | pgf90* | pgf95*) # Portland Group f77 and f90 compilers + whole_archive_flag_spec_GCJ='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' + tmp_addflag=' $pic_flag -Mnomain' ;; + ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 + tmp_addflag=' -i_dynamic' ;; + efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 + tmp_addflag=' -i_dynamic -nofor_main' ;; + ifc* | ifort*) # Intel Fortran compiler + tmp_addflag=' -nofor_main' ;; + esac + case `$CC -V 2>&1 | sed 5q` in + *Sun\ C*) # Sun C 5.9 + whole_archive_flag_spec_GCJ='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' + tmp_sharedflag='-G' ;; + *Sun\ F*) # Sun Fortran 8.3 + tmp_sharedflag='-G' ;; + *) + tmp_sharedflag='-shared' ;; + esac + archive_cmds_GCJ='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + + if test $supports_anon_versioning = yes; then + archive_expsym_cmds_GCJ='$echo "{ global:" > $output_objdir/$libname.ver~ + cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ + $echo "local: *; };" >> $output_objdir/$libname.ver~ + $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' + fi + else + ld_shlibs_GCJ=no + fi + ;; + + netbsd*) + if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then + archive_cmds_GCJ='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' + wlarc= + else + archive_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + fi + ;; + + solaris*) + if $LD -v 2>&1 | grep 'BFD 2\.8' > /dev/null; then + ld_shlibs_GCJ=no + cat <&2 + +*** Warning: The releases 2.8.* of the GNU linker cannot reliably +*** create shared libraries on Solaris systems. Therefore, libtool +*** is disabling shared libraries support. We urge you to upgrade GNU +*** binutils to release 2.9.1 or newer. Another option is to modify +*** your PATH or compiler configuration so that the native linker is +*** used, and then restart. + +EOF + elif $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then + archive_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + else + ld_shlibs_GCJ=no + fi + ;; + + sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*) + case `$LD -v 2>&1` in + *\ [01].* | *\ 2.[0-9].* | *\ 2.1[0-5].*) + ld_shlibs_GCJ=no + cat <<_LT_EOF 1>&2 + +*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not +*** reliably create shared libraries on SCO systems. Therefore, libtool +*** is disabling shared libraries support. We urge you to upgrade GNU +*** binutils to release 2.16.91.0.3 or newer. Another option is to modify +*** your PATH or compiler configuration so that the native linker is +*** used, and then restart. + +_LT_EOF + ;; + *) + if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then + hardcode_libdir_flag_spec_GCJ='`test -z "$SCOABSPATH" && echo ${wl}-rpath,$libdir`' + archive_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib' + archive_expsym_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname,\${SCOABSPATH:+${install_libdir}/}$soname,-retain-symbols-file,$export_symbols -o $lib' + else + ld_shlibs_GCJ=no + fi + ;; + esac + ;; + + sunos4*) + archive_cmds_GCJ='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' + wlarc= + hardcode_direct_GCJ=yes + hardcode_shlibpath_var_GCJ=no + ;; + + *) + if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then + archive_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + else + ld_shlibs_GCJ=no + fi + ;; + esac + + if test "$ld_shlibs_GCJ" = no; then + runpath_var= + hardcode_libdir_flag_spec_GCJ= + export_dynamic_flag_spec_GCJ= + whole_archive_flag_spec_GCJ= + fi + else + # PORTME fill in a description of your system's linker (not GNU ld) + case $host_os in + aix3*) + allow_undefined_flag_GCJ=unsupported + always_export_symbols_GCJ=yes + archive_expsym_cmds_GCJ='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname' + # Note: this linker hardcodes the directories in LIBPATH if there + # are no directories specified by -L. + hardcode_minus_L_GCJ=yes + if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then + # Neither direct hardcoding nor static linking is supported with a + # broken collect2. + hardcode_direct_GCJ=unsupported + fi + ;; + + aix[4-9]*) + if test "$host_cpu" = ia64; then + # On IA64, the linker does run time linking by default, so we don't + # have to do anything special. + aix_use_runtimelinking=no + exp_sym_flag='-Bexport' + no_entry_flag="" + else + # If we're using GNU nm, then we don't want the "-C" option. + # -C means demangle to AIX nm, but means don't demangle with GNU nm + if $NM -V 2>&1 | grep 'GNU' > /dev/null; then + export_symbols_cmds_GCJ='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$2 == "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print \$3 } }'\'' | sort -u > $export_symbols' + else + export_symbols_cmds_GCJ='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$2 == "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print \$3 } }'\'' | sort -u > $export_symbols' + fi + aix_use_runtimelinking=no + + # Test if we are trying to use run time linking or normal + # AIX style linking. If -brtl is somewhere in LDFLAGS, we + # need to do runtime linking. + case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*) + for ld_flag in $LDFLAGS; do + if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then + aix_use_runtimelinking=yes + break + fi + done + ;; + esac + + exp_sym_flag='-bexport' + no_entry_flag='-bnoentry' + fi + + # When large executables or shared objects are built, AIX ld can + # have problems creating the table of contents. If linking a library + # or program results in "error TOC overflow" add -mminimal-toc to + # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not + # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. + + archive_cmds_GCJ='' + hardcode_direct_GCJ=yes + hardcode_libdir_separator_GCJ=':' + link_all_deplibs_GCJ=yes + + if test "$GCC" = yes; then + case $host_os in aix4.[012]|aix4.[012].*) + # We only want to do this on AIX 4.2 and lower, the check + # below for broken collect2 doesn't work under 4.3+ + collect2name=`${CC} -print-prog-name=collect2` + if test -f "$collect2name" && \ + strings "$collect2name" | grep resolve_lib_name >/dev/null + then + # We have reworked collect2 + : + else + # We have old collect2 + hardcode_direct_GCJ=unsupported + # It fails to find uninstalled libraries when the uninstalled + # path is not listed in the libpath. Setting hardcode_minus_L + # to unsupported forces relinking + hardcode_minus_L_GCJ=yes + hardcode_libdir_flag_spec_GCJ='-L$libdir' + hardcode_libdir_separator_GCJ= + fi + ;; + esac + shared_flag='-shared' + if test "$aix_use_runtimelinking" = yes; then + shared_flag="$shared_flag "'${wl}-G' + fi + else + # not using gcc + if test "$host_cpu" = ia64; then + # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release + # chokes on -Wl,-G. The following line is correct: + shared_flag='-G' + else + if test "$aix_use_runtimelinking" = yes; then + shared_flag='${wl}-G' + else + shared_flag='${wl}-bM:SRE' + fi + fi + fi + + # It seems that -bexpall does not export symbols beginning with + # underscore (_), so it is better to generate a list of symbols to export. + always_export_symbols_GCJ=yes + if test "$aix_use_runtimelinking" = yes; then + # Warning - without using the other runtime loading flags (-brtl), + # -berok will link without error, but may produce a broken library. + allow_undefined_flag_GCJ='-berok' + # Determine the default libpath from the value encoded in an empty executable. + cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ int main () { -return $ac_func (); + ; return 0; } @@ -15622,80 +18238,51 @@ $as_echo "$ac_try_echo") >&5 test "$cross_compiling" = yes || $as_test_x conftest$ac_exeext }; then - eval "$as_ac_var=yes" + +lt_aix_libpath_sed=' + /Import File Strings/,/^$/ { + /^0/ { + s/^0 *\(.*\)$/\1/ + p + } + }' +aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` +# Check for a 64-bit object if we didn't find anything. +if test -z "$aix_libpath"; then + aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` +fi else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 - eval "$as_ac_var=no" + fi rm -rf conftest.dSYM rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 -_ACEOF - -fi -done +if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi -# Used in lcFile.c (see also --enable-xlocaledir settings below) -XLOCALEDIR_IS_SAFE="no" -{ $as_echo "$as_me:$LINENO: checking for issetugid" >&5 -$as_echo_n "checking for issetugid... " >&6; } -if test "${ac_cv_func_issetugid+set}" = set; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF + hardcode_libdir_flag_spec_GCJ='${wl}-blibpath:$libdir:'"$aix_libpath" + archive_expsym_cmds_GCJ="\$CC"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag" + else + if test "$host_cpu" = ia64; then + hardcode_libdir_flag_spec_GCJ='${wl}-R $libdir:/usr/lib:/lib' + allow_undefined_flag_GCJ="-z nodefs" + archive_expsym_cmds_GCJ="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols" + else + # Determine the default libpath from the value encoded in an empty executable. + cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ -/* Define issetugid to an innocuous variant, in case declares issetugid. - For example, HP-UX 11i declares gettimeofday. */ -#define issetugid innocuous_issetugid -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char issetugid (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef issetugid +int +main () +{ -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char issetugid (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_issetugid || defined __stub___issetugid -choke me -#endif - -int -main () -{ -return issetugid (); ; return 0; } @@ -15721,4330 +18308,10122 @@ $as_echo "$ac_try_echo") >&5 test "$cross_compiling" = yes || $as_test_x conftest$ac_exeext }; then - ac_cv_func_issetugid=yes + +lt_aix_libpath_sed=' + /Import File Strings/,/^$/ { + /^0/ { + s/^0 *\(.*\)$/\1/ + p + } + }' +aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` +# Check for a 64-bit object if we didn't find anything. +if test -z "$aix_libpath"; then + aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` +fi else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 - ac_cv_func_issetugid=no + fi rm -rf conftest.dSYM rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_func_issetugid" >&5 -$as_echo "$ac_cv_func_issetugid" >&6; } -if test "x$ac_cv_func_issetugid" = x""yes; then - XLOCALEDIR_IS_SAFE="yes" +if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi -cat >>confdefs.h <<\_ACEOF -#define HASSETUGID 1 -_ACEOF + hardcode_libdir_flag_spec_GCJ='${wl}-blibpath:$libdir:'"$aix_libpath" + # Warning - without using the other run time loading flags, + # -berok will link without error, but may produce a broken library. + no_undefined_flag_GCJ=' ${wl}-bernotok' + allow_undefined_flag_GCJ=' ${wl}-berok' + # Exported symbols can be pulled into shared objects from archives + whole_archive_flag_spec_GCJ='$convenience' + archive_cmds_need_lc_GCJ=yes + # This is similar to how AIX traditionally builds its shared libraries. + archive_expsym_cmds_GCJ="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' + fi + fi + ;; -fi + amigaos*) + archive_cmds_GCJ='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' + hardcode_libdir_flag_spec_GCJ='-L$libdir' + hardcode_minus_L_GCJ=yes + # see comment about different semantics on the GNU ld section + ld_shlibs_GCJ=no + ;; -{ $as_echo "$as_me:$LINENO: checking for getresuid" >&5 -$as_echo_n "checking for getresuid... " >&6; } -if test "${ac_cv_func_getresuid+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. */ -/* Define getresuid to an innocuous variant, in case declares getresuid. - For example, HP-UX 11i declares gettimeofday. */ -#define getresuid innocuous_getresuid + bsdi[45]*) + export_dynamic_flag_spec_GCJ=-rdynamic + ;; -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char getresuid (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ + cygwin* | mingw* | pw32*) + # When not using gcc, we currently assume that we are using + # Microsoft Visual C++. + # hardcode_libdir_flag_spec is actually meaningless, as there is + # no search path for DLLs. + hardcode_libdir_flag_spec_GCJ=' ' + allow_undefined_flag_GCJ=unsupported + # Tell ltmain to make .lib files, not .a files. + libext=lib + # Tell ltmain to make .dll files, not .so files. + shrext_cmds=".dll" + # FIXME: Setting linknames here is a bad hack. + archive_cmds_GCJ='$CC -o $lib $libobjs $compiler_flags `echo "$deplibs" | $SED -e '\''s/ -lc$//'\''` -link -dll~linknames=' + # The linker will automatically build a .lib file if we build a DLL. + old_archive_From_new_cmds_GCJ='true' + # FIXME: Should let the user specify the lib program. + old_archive_cmds_GCJ='lib -OUT:$oldlib$oldobjs$old_deplibs' + fix_srcfile_path_GCJ='`cygpath -w "$srcfile"`' + enable_shared_with_static_runtimes_GCJ=yes + ;; -#ifdef __STDC__ -# include -#else -# include -#endif + darwin* | rhapsody*) + case $host_os in + rhapsody* | darwin1.[012]) + allow_undefined_flag_GCJ='${wl}-undefined ${wl}suppress' + ;; + *) # Darwin 1.3 on + if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then + allow_undefined_flag_GCJ='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' + else + case ${MACOSX_DEPLOYMENT_TARGET} in + 10.[012]) + allow_undefined_flag_GCJ='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' + ;; + 10.*) + allow_undefined_flag_GCJ='${wl}-undefined ${wl}dynamic_lookup' + ;; + esac + fi + ;; + esac + archive_cmds_need_lc_GCJ=no + hardcode_direct_GCJ=no + hardcode_automatic_GCJ=yes + hardcode_shlibpath_var_GCJ=unsupported + whole_archive_flag_spec_GCJ='' + link_all_deplibs_GCJ=yes + if test "$GCC" = yes ; then + output_verbose_link_cmd='echo' + archive_cmds_GCJ="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}" + module_cmds_GCJ="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}" + archive_expsym_cmds_GCJ="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}" + module_expsym_cmds_GCJ="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}" + else + case $cc_basename in + xlc*) + output_verbose_link_cmd='echo' + archive_cmds_GCJ='$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $xlcverstring' + module_cmds_GCJ='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags' + # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds + archive_expsym_cmds_GCJ='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $xlcverstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' + module_expsym_cmds_GCJ='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' + ;; + *) + ld_shlibs_GCJ=no + ;; + esac + fi + ;; -#undef getresuid + dgux*) + archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_libdir_flag_spec_GCJ='-L$libdir' + hardcode_shlibpath_var_GCJ=no + ;; -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char getresuid (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_getresuid || defined __stub___getresuid -choke me -#endif + freebsd1*) + ld_shlibs_GCJ=no + ;; -int -main () -{ -return getresuid (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext 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>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_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - ac_cv_func_getresuid=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 + # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor + # support. Future versions do this automatically, but an explicit c++rt0.o + # does not break anything, and helps significantly (at the cost of a little + # extra space). + freebsd2.2*) + archive_cmds_GCJ='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' + hardcode_libdir_flag_spec_GCJ='-R$libdir' + hardcode_direct_GCJ=yes + hardcode_shlibpath_var_GCJ=no + ;; - ac_cv_func_getresuid=no -fi + # Unfortunately, older versions of FreeBSD 2 do not have this feature. + freebsd2*) + archive_cmds_GCJ='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' + hardcode_direct_GCJ=yes + hardcode_minus_L_GCJ=yes + hardcode_shlibpath_var_GCJ=no + ;; -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_func_getresuid" >&5 -$as_echo "$ac_cv_func_getresuid" >&6; } -if test "x$ac_cv_func_getresuid" = x""yes; then - XLOCALEDIR_IS_SAFE="yes" + # FreeBSD 3 and greater uses gcc -shared to do shared libraries. + freebsd* | dragonfly*) + archive_cmds_GCJ='$CC -shared -o $lib $libobjs $deplibs $compiler_flags' + hardcode_libdir_flag_spec_GCJ='-R$libdir' + hardcode_direct_GCJ=yes + hardcode_shlibpath_var_GCJ=no + ;; -cat >>confdefs.h <<\_ACEOF -#define HASGETRESUID 1 -_ACEOF + hpux9*) + if test "$GCC" = yes; then + archive_cmds_GCJ='$rm $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' + else + archive_cmds_GCJ='$rm $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' + fi + hardcode_libdir_flag_spec_GCJ='${wl}+b ${wl}$libdir' + hardcode_libdir_separator_GCJ=: + hardcode_direct_GCJ=yes -fi + # hardcode_minus_L: Not really in the search PATH, + # but as the default location of the library. + hardcode_minus_L_GCJ=yes + export_dynamic_flag_spec_GCJ='${wl}-E' + ;; -# Used in Font.c -{ $as_echo "$as_me:$LINENO: checking for shmat" >&5 -$as_echo_n "checking for shmat... " >&6; } -if test "${ac_cv_func_shmat+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. */ -/* Define shmat to an innocuous variant, in case declares shmat. - For example, HP-UX 11i declares gettimeofday. */ -#define shmat innocuous_shmat + hpux10*) + if test "$GCC" = yes -a "$with_gnu_ld" = no; then + archive_cmds_GCJ='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' + else + archive_cmds_GCJ='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' + fi + if test "$with_gnu_ld" = no; then + hardcode_libdir_flag_spec_GCJ='${wl}+b ${wl}$libdir' + hardcode_libdir_separator_GCJ=: -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char shmat (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ + hardcode_direct_GCJ=yes + export_dynamic_flag_spec_GCJ='${wl}-E' -#ifdef __STDC__ -# include -#else -# include -#endif + # hardcode_minus_L: Not really in the search PATH, + # but as the default location of the library. + hardcode_minus_L_GCJ=yes + fi + ;; -#undef shmat + hpux11*) + if test "$GCC" = yes -a "$with_gnu_ld" = no; then + case $host_cpu in + hppa*64*) + archive_cmds_GCJ='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + ia64*) + archive_cmds_GCJ='$CC -shared ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' + ;; + *) + archive_cmds_GCJ='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' + ;; + esac + else + case $host_cpu in + hppa*64*) + archive_cmds_GCJ='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' + ;; + ia64*) + archive_cmds_GCJ='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' + ;; + *) + archive_cmds_GCJ='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' + ;; + esac + fi + if test "$with_gnu_ld" = no; then + hardcode_libdir_flag_spec_GCJ='${wl}+b ${wl}$libdir' + hardcode_libdir_separator_GCJ=: -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char shmat (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_shmat || defined __stub___shmat -choke me -#endif + case $host_cpu in + hppa*64*|ia64*) + hardcode_libdir_flag_spec_ld_GCJ='+b $libdir' + hardcode_direct_GCJ=no + hardcode_shlibpath_var_GCJ=no + ;; + *) + hardcode_direct_GCJ=yes + export_dynamic_flag_spec_GCJ='${wl}-E' -int -main () -{ -return shmat (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext 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>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_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - ac_cv_func_shmat=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_func_shmat=no -fi + # hardcode_minus_L: Not really in the search PATH, + # but as the default location of the library. + hardcode_minus_L_GCJ=yes + ;; + esac + fi + ;; -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_func_shmat" >&5 -$as_echo "$ac_cv_func_shmat" >&6; } -if test "x$ac_cv_func_shmat" = x""yes; then + irix5* | irix6* | nonstopux*) + if test "$GCC" = yes; then + archive_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + else + archive_cmds_GCJ='$LD -shared $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' + hardcode_libdir_flag_spec_ld_GCJ='-rpath $libdir' + fi + hardcode_libdir_flag_spec_GCJ='${wl}-rpath ${wl}$libdir' + hardcode_libdir_separator_GCJ=: + link_all_deplibs_GCJ=yes + ;; -cat >>confdefs.h <<\_ACEOF -#define HAS_SHM 1 -_ACEOF + netbsd*) + if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then + archive_cmds_GCJ='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out + else + archive_cmds_GCJ='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF + fi + hardcode_libdir_flag_spec_GCJ='-R$libdir' + hardcode_direct_GCJ=yes + hardcode_shlibpath_var_GCJ=no + ;; -fi + newsos6) + archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_direct_GCJ=yes + hardcode_libdir_flag_spec_GCJ='${wl}-rpath ${wl}$libdir' + hardcode_libdir_separator_GCJ=: + hardcode_shlibpath_var_GCJ=no + ;; + openbsd*) + if test -f /usr/libexec/ld.so; then + hardcode_direct_GCJ=yes + hardcode_shlibpath_var_GCJ=no + if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then + archive_cmds_GCJ='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds_GCJ='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols' + hardcode_libdir_flag_spec_GCJ='${wl}-rpath,$libdir' + export_dynamic_flag_spec_GCJ='${wl}-E' + else + case $host_os in + openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*) + archive_cmds_GCJ='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' + hardcode_libdir_flag_spec_GCJ='-R$libdir' + ;; + *) + archive_cmds_GCJ='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' + hardcode_libdir_flag_spec_GCJ='${wl}-rpath,$libdir' + ;; + esac + fi + else + ld_shlibs_GCJ=no + fi + ;; -# Checks for system services + os2*) + hardcode_libdir_flag_spec_GCJ='-L$libdir' + hardcode_minus_L_GCJ=yes + allow_undefined_flag_GCJ=unsupported + archive_cmds_GCJ='$echo "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$echo "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~$echo DATA >> $output_objdir/$libname.def~$echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~$echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def' + old_archive_From_new_cmds_GCJ='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def' + ;; -# arch specific things -WCHAR32="1" -case $target_alias in - *os2*) os2="true" ; WCHAR32="0" ;; - *) ;; -esac + osf3*) + if test "$GCC" = yes; then + allow_undefined_flag_GCJ=' ${wl}-expect_unresolved ${wl}\*' + archive_cmds_GCJ='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + else + allow_undefined_flag_GCJ=' -expect_unresolved \*' + archive_cmds_GCJ='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' + fi + hardcode_libdir_flag_spec_GCJ='${wl}-rpath ${wl}$libdir' + hardcode_libdir_separator_GCJ=: + ;; + osf4* | osf5*) # as osf3* with the addition of -msym flag + if test "$GCC" = yes; then + allow_undefined_flag_GCJ=' ${wl}-expect_unresolved ${wl}\*' + archive_cmds_GCJ='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + hardcode_libdir_flag_spec_GCJ='${wl}-rpath ${wl}$libdir' + else + allow_undefined_flag_GCJ=' -expect_unresolved \*' + archive_cmds_GCJ='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -msym -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' + archive_expsym_cmds_GCJ='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; echo "-hidden">> $lib.exp~ + $LD -shared${allow_undefined_flag} -input $lib.exp $linker_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib~$rm $lib.exp' - if test x$os2 = xtrue; then - OS2_TRUE= - OS2_FALSE='#' -else - OS2_TRUE='#' - OS2_FALSE= -fi + # Both c and cxx compiler support -rpath directly + hardcode_libdir_flag_spec_GCJ='-rpath $libdir' + fi + hardcode_libdir_separator_GCJ=: + ;; + solaris*) + no_undefined_flag_GCJ=' -z text' + if test "$GCC" = yes; then + wlarc='${wl}' + archive_cmds_GCJ='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds_GCJ='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ + $CC -shared ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$rm $lib.exp' + else + wlarc='' + archive_cmds_GCJ='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' + archive_expsym_cmds_GCJ='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ + $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp' + fi + hardcode_libdir_flag_spec_GCJ='-R$libdir' + hardcode_shlibpath_var_GCJ=no + case $host_os in + solaris2.[0-5] | solaris2.[0-5].*) ;; + *) + # The compiler driver will combine and reorder linker options, + # but understands `-z linker_flag'. GCC discards it without `$wl', + # but is careful enough not to reorder. + # Supported since Solaris 2.6 (maybe 2.5.1?) + if test "$GCC" = yes; then + whole_archive_flag_spec_GCJ='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' + else + whole_archive_flag_spec_GCJ='-z allextract$convenience -z defaultextract' + fi + ;; + esac + link_all_deplibs_GCJ=yes + ;; + sunos4*) + if test "x$host_vendor" = xsequent; then + # Use $CC to link under sequent, because it throws in some extra .o + # files that make .init and .fini sections work. + archive_cmds_GCJ='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags' + else + archive_cmds_GCJ='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' + fi + hardcode_libdir_flag_spec_GCJ='-L$libdir' + hardcode_direct_GCJ=yes + hardcode_minus_L_GCJ=yes + hardcode_shlibpath_var_GCJ=no + ;; -# Check whether --with-launchd was given. -if test "${with_launchd+set}" = set; then - withval=$with_launchd; LAUNCHD=$withval -else - LAUNCHD=auto -fi + sysv4) + case $host_vendor in + sni) + archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_direct_GCJ=yes # is this really true??? + ;; + siemens) + ## LD is ld it makes a PLAMLIB + ## CC just makes a GrossModule. + archive_cmds_GCJ='$LD -G -o $lib $libobjs $deplibs $linker_flags' + reload_cmds_GCJ='$CC -r -o $output$reload_objs' + hardcode_direct_GCJ=no + ;; + motorola) + archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_direct_GCJ=no #Motorola manual says yes, but my tests say they lie + ;; + esac + runpath_var='LD_RUN_PATH' + hardcode_shlibpath_var_GCJ=no + ;; -if test "x$LAUNCHD" = xauto; then - unset LAUNCHD - # Extract the first word of "launchd", so it can be a program name with args. -set dummy launchd; 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_prog_LAUNCHD+set}" = set; then - $as_echo_n "(cached) " >&6 -else - if test -n "$LAUNCHD"; then - ac_cv_prog_LAUNCHD="$LAUNCHD" # Let the user override the test. -else -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_prog_LAUNCHD="yes" - $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done -done -IFS=$as_save_IFS + sysv4.3*) + archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_shlibpath_var_GCJ=no + export_dynamic_flag_spec_GCJ='-Bexport' + ;; - test -z "$ac_cv_prog_LAUNCHD" && ac_cv_prog_LAUNCHD="no" -fi -fi -LAUNCHD=$ac_cv_prog_LAUNCHD -if test -n "$LAUNCHD"; then - { $as_echo "$as_me:$LINENO: result: $LAUNCHD" >&5 -$as_echo "$LAUNCHD" >&6; } -else - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } -fi + sysv4*MP*) + if test -d /usr/nec; then + archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_shlibpath_var_GCJ=no + runpath_var=LD_RUN_PATH + hardcode_runpath_var=yes + ld_shlibs_GCJ=yes + fi + ;; + sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*) + no_undefined_flag_GCJ='${wl}-z,text' + archive_cmds_need_lc_GCJ=no + hardcode_shlibpath_var_GCJ=no + runpath_var='LD_RUN_PATH' -fi + if test "$GCC" = yes; then + archive_cmds_GCJ='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds_GCJ='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + else + archive_cmds_GCJ='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds_GCJ='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + fi + ;; -if test "x$LAUNCHD" = xyes ; then + sysv5* | sco3.2v5* | sco5v6*) + # Note: We can NOT use -z defs as we might desire, because we do not + # link with -lc, and that would cause any symbols used from libc to + # always be unresolved, which means just about no library would + # ever link correctly. If we're not using GNU ld we use -z text + # though, which does catch some bad symbols but isn't as heavy-handed + # as -z defs. + no_undefined_flag_GCJ='${wl}-z,text' + allow_undefined_flag_GCJ='${wl}-z,nodefs' + archive_cmds_need_lc_GCJ=no + hardcode_shlibpath_var_GCJ=no + hardcode_libdir_flag_spec_GCJ='`test -z "$SCOABSPATH" && echo ${wl}-R,$libdir`' + hardcode_libdir_separator_GCJ=':' + link_all_deplibs_GCJ=yes + export_dynamic_flag_spec_GCJ='${wl}-Bexport' + runpath_var='LD_RUN_PATH' -cat >>confdefs.h <<\_ACEOF -#define HAVE_LAUNCHD 1 -_ACEOF + if test "$GCC" = yes; then + archive_cmds_GCJ='$CC -shared ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds_GCJ='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' + else + archive_cmds_GCJ='$CC -G ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' + archive_expsym_cmds_GCJ='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' + fi + ;; + uts4*) + archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' + hardcode_libdir_flag_spec_GCJ='-L$libdir' + hardcode_shlibpath_var_GCJ=no + ;; -cat >>confdefs.h <<\_ACEOF -#define TRANS_REOPEN 1 -_ACEOF + *) + ld_shlibs_GCJ=no + ;; + esac + fi -fi +{ $as_echo "$as_me:$LINENO: result: $ld_shlibs_GCJ" >&5 +$as_echo "$ld_shlibs_GCJ" >&6; } +test "$ld_shlibs_GCJ" = no && can_build_shared=no -# Check whether --enable-xthreads was given. -if test "${enable_xthreads+set}" = set; then - enableval=$enable_xthreads; xthreads=$enableval -else - xthreads=yes -fi +# +# Do we need to explicitly link libc? +# +case "x$archive_cmds_need_lc_GCJ" in +x|xyes) + # Assume -lc should be added + archive_cmds_need_lc_GCJ=yes + if test "$enable_shared" = yes && test "$GCC" = yes; then + case $archive_cmds_GCJ in + *'~'*) + # FIXME: we may have to deal with multi-command sequences. + ;; + '$CC '*) + # Test whether the compiler implicitly links with -lc since on some + # systems, -lgcc has to come before -lc. If gcc already passes -lc + # to ld, don't add -lc before -lgcc. + { $as_echo "$as_me:$LINENO: checking whether -lc should be explicitly linked in" >&5 +$as_echo_n "checking whether -lc should be explicitly linked in... " >&6; } + $rm conftest* + echo "$lt_simple_compile_test_code" > conftest.$ac_ext -{ $as_echo "$as_me:$LINENO: checking for getpwuid_r in -lc" >&5 -$as_echo_n "checking for getpwuid_r in -lc... " >&6; } -if test "${ac_cv_lib_c_getpwuid_r+set}" = set; then - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS -LIBS="-lc $LIBS" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char getpwuid_r (); -int -main () -{ -return getpwuid_r (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext 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>conftest.er1 + if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 + (eval $ac_compile) 2>&5 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_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - ac_cv_lib_c_getpwuid_r=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 + (exit $ac_status); } 2>conftest.err; then + soname=conftest + lib=conftest + libobjs=conftest.$ac_objext + deplibs= + wl=$lt_prog_compiler_wl_GCJ + pic_flag=$lt_prog_compiler_pic_GCJ + compiler_flags=-v + linker_flags=-v + verstring= + output_objdir=. + libname=conftest + lt_save_allow_undefined_flag=$allow_undefined_flag_GCJ + allow_undefined_flag_GCJ= + if { (eval echo "$as_me:$LINENO: \"$archive_cmds_GCJ 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1\"") >&5 + (eval $archive_cmds_GCJ 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1) 2>&5 + ac_status=$? + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } + then + archive_cmds_need_lc_GCJ=no + else + archive_cmds_need_lc_GCJ=yes + fi + allow_undefined_flag_GCJ=$lt_save_allow_undefined_flag + else + cat conftest.err 1>&5 + fi + $rm conftest* + { $as_echo "$as_me:$LINENO: result: $archive_cmds_need_lc_GCJ" >&5 +$as_echo "$archive_cmds_need_lc_GCJ" >&6; } + ;; + esac + fi + ;; +esac - ac_cv_lib_c_getpwuid_r=no -fi +{ $as_echo "$as_me:$LINENO: checking dynamic linker characteristics" >&5 +$as_echo_n "checking dynamic linker characteristics... " >&6; } +library_names_spec= +libname_spec='lib$name' +soname_spec= +shrext_cmds=".so" +postinstall_cmds= +postuninstall_cmds= +finish_cmds= +finish_eval= +shlibpath_var= +shlibpath_overrides_runpath=unknown +version_type=none +dynamic_linker="$host_os ld.so" +sys_lib_dlsearch_path_spec="/lib /usr/lib" -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_c_getpwuid_r" >&5 -$as_echo "$ac_cv_lib_c_getpwuid_r" >&6; } -if test "x$ac_cv_lib_c_getpwuid_r" = x""yes; then - mtsafeapi="yes" -else - mtsafeapi="no" -fi +need_lib_prefix=unknown +hardcode_into_libs=no +# when you set need_version to no, make sure it does not cause -set_version +# flags to be left without arguments +need_version=unknown -case x$xthreads in -xyes) +case $host_os in +aix3*) + version_type=linux + library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a' + shlibpath_var=LIBPATH -cat >>confdefs.h <<\_ACEOF -#define XTHREADS 1 -_ACEOF + # AIX 3 has no versioning support, so we append a major version to the name. + soname_spec='${libname}${release}${shared_ext}$major' + ;; - if test x$mtsafeapi = xyes - then +aix[4-9]*) + version_type=linux + need_lib_prefix=no + need_version=no + hardcode_into_libs=yes + if test "$host_cpu" = ia64; then + # AIX 5 supports IA64 + library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + else + # With GCC up to 2.95.x, collect2 would create an import file + # for dependence libraries. The import file would start with + # the line `#! .'. This would cause the generated library to + # depend on `.', always an invalid library. This was fixed in + # development snapshots of GCC prior to 3.0. + case $host_os in + aix4 | aix4.[01] | aix4.[01].*) + if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' + echo ' yes ' + echo '#endif'; } | ${CC} -E - | grep yes > /dev/null; then + : + else + can_build_shared=no + fi + ;; + esac + # AIX (on Power*) has no versioning support, so currently we can not hardcode correct + # soname into executable. Probably we can add versioning support to + # collect2, so additional links can be useful in future. + if test "$aix_use_runtimelinking" = yes; then + # If using run time linking (on AIX 4.2 or later) use lib.so + # instead of lib.a to let people know that these are not + # typical AIX shared libraries. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + else + # We preserve .a as extension for shared libraries through AIX4.2 + # and later when we are not doing run time linking. + library_names_spec='${libname}${release}.a $libname.a' + soname_spec='${libname}${release}${shared_ext}$major' + fi + shlibpath_var=LIBPATH + fi + ;; -cat >>confdefs.h <<\_ACEOF -#define XUSE_MTSAFE_API 1 -_ACEOF +amigaos*) + library_names_spec='$libname.ixlibrary $libname.a' + # Create ${libname}_ixlibrary.a entries in /sys/libs. + finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$echo "X$lib" | $Xsed -e '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $rm /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' + ;; - fi - ;; -*) - ;; -esac +beos*) + library_names_spec='${libname}${shared_ext}' + dynamic_linker="$host_os ld.so" + shlibpath_var=LIBRARY_PATH + ;; -{ $as_echo "$as_me:$LINENO: checking for pthread_self in -lc" >&5 -$as_echo_n "checking for pthread_self in -lc... " >&6; } -if test "${ac_cv_lib_c_pthread_self+set}" = set; then - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS -LIBS="-lc $LIBS" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ +bsdi[45]*) + version_type=linux + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' + shlibpath_var=LD_LIBRARY_PATH + sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" + sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" + # the default ld.so.conf also contains /usr/contrib/lib and + # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow + # libtool to hard-code these into programs + ;; -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char pthread_self (); -int -main () -{ -return pthread_self (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext 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>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_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - ac_cv_lib_c_pthread_self=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 +cygwin* | mingw* | pw32*) + version_type=windows + shrext_cmds=".dll" + need_version=no + need_lib_prefix=no - ac_cv_lib_c_pthread_self=no -fi + case $GCC,$host_os in + yes,cygwin* | yes,mingw* | yes,pw32*) + library_names_spec='$libname.dll.a' + # DLL is installed to $(libdir)/../bin by postinstall_cmds + postinstall_cmds='base_file=`basename \${file}`~ + dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i;echo \$dlname'\''`~ + dldir=$destdir/`dirname \$dlpath`~ + test -d \$dldir || mkdir -p \$dldir~ + $install_prog $dir/$dlname \$dldir/$dlname~ + chmod a+x \$dldir/$dlname' + postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ + dlpath=$dir/\$dldll~ + $rm \$dlpath' + shlibpath_overrides_runpath=yes -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_c_pthread_self" >&5 -$as_echo "$ac_cv_lib_c_pthread_self" >&6; } -if test "x$ac_cv_lib_c_pthread_self" = x""yes; then - thrstubs="no" -else - thrstubs="yes" -fi - - if test x$thrstubs = xyes; then - THRSTUBS_TRUE= - THRSTUBS_FALSE='#' -else - THRSTUBS_TRUE='#' - THRSTUBS_FALSE= -fi - - -if test x$xthreads = xyes ; then case $host_os in - linux*|openbsd*|gnu*|k*bsd*-gnu) - XTHREADLIB=-lpthread ;; - netbsd*) - XTHREAD_CFLAGS="-D_POSIX_THREAD_SAFE_FUNCTIONS" - XTHREADLIB="-lpthread" ;; - freebsd*) - XTHREAD_CFLAGS="-D_THREAD_SAFE" - XTHREADLIB="-pthread" ;; - dragonfly*) - XTHREADLIB="-pthread" ;; - solaris*) - XTHREAD_CFLAGS="-D_REENTRANT -D_POSIX_PTHREAD_SEMANTICS" ;; + cygwin*) + # Cygwin DLLs use 'cyg' prefix rather than 'lib' + soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' + sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib" + ;; + mingw*) + # MinGW DLLs use traditional 'lib' prefix + soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' + sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"` + if echo "$sys_lib_search_path_spec" | grep ';[c-zC-Z]:/' >/dev/null; then + # It is most probably a Windows format PATH printed by + # mingw gcc, but we are running on Cygwin. Gcc prints its search + # path with ; separators, and with drive letters. We can handle the + # drive letters (cygwin fileutils understands them), so leave them, + # especially as we might pass files found there to a mingw objdump, + # which wouldn't understand a cygwinified path. Ahh. + sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` + else + sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` + fi + ;; + pw32*) + # pw32 DLLs use 'pw' prefix rather than 'lib' + library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' + ;; esac -fi - + ;; -X11_CFLAGS="$X11_CFLAGS $XTHREAD_CFLAGS" + *) + library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib' + ;; + esac + dynamic_linker='Win32 ld.exe' + # FIXME: first we should search . and the directory the executable is in + shlibpath_var=PATH + ;; -case x$xdmauth in -xyes) - XDMCP_CFLAGS="$XDMCP_CFLAGS -DHASXDMAUTH" - ;; -xno) - XDMCP_LIBS="" - ;; -esac +darwin* | rhapsody*) + dynamic_linker="$host_os dyld" + version_type=darwin + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${versuffix}$shared_ext ${libname}${release}${major}$shared_ext ${libname}$shared_ext' + soname_spec='${libname}${release}${major}$shared_ext' + shlibpath_overrides_runpath=yes + shlibpath_var=DYLD_LIBRARY_PATH + shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' + sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' + ;; +dgux*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + ;; -{ $as_echo "$as_me:$LINENO: checking for poll" >&5 -$as_echo_n "checking for poll... " >&6; } -if test "${ac_cv_func_poll+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. */ -/* Define poll to an innocuous variant, in case declares poll. - For example, HP-UX 11i declares gettimeofday. */ -#define poll innocuous_poll +freebsd1*) + dynamic_linker=no + ;; -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char poll (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ +freebsd* | dragonfly*) + # DragonFly does not have aout. When/if they implement a new + # versioning mechanism, adjust this. + if test -x /usr/bin/objformat; then + objformat=`/usr/bin/objformat` + else + case $host_os in + freebsd[123]*) objformat=aout ;; + *) objformat=elf ;; + esac + fi + version_type=freebsd-$objformat + case $version_type in + freebsd-elf*) + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' + need_version=no + need_lib_prefix=no + ;; + freebsd-*) + library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' + need_version=yes + ;; + esac + shlibpath_var=LD_LIBRARY_PATH + case $host_os in + freebsd2*) + shlibpath_overrides_runpath=yes + ;; + freebsd3.[01]* | freebsdelf3.[01]*) + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; + freebsd3.[2-9]* | freebsdelf3.[2-9]* | \ + freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1) + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; + *) # from 4.6 on, and DragonFly + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; + esac + ;; -#ifdef __STDC__ -# include -#else -# include -#endif +gnu*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + hardcode_into_libs=yes + ;; -#undef poll +hpux9* | hpux10* | hpux11*) + # Give a soname corresponding to the major version so that dld.sl refuses to + # link against other versions. + version_type=sunos + need_lib_prefix=no + need_version=no + case $host_cpu in + ia64*) + shrext_cmds='.so' + hardcode_into_libs=yes + dynamic_linker="$host_os dld.so" + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + if test "X$HPUX_IA64_MODE" = X32; then + sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" + else + sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" + fi + sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec + ;; + hppa*64*) + shrext_cmds='.sl' + hardcode_into_libs=yes + dynamic_linker="$host_os dld.sl" + shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH + shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" + sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec + ;; + *) + shrext_cmds='.sl' + dynamic_linker="$host_os dld.sl" + shlibpath_var=SHLIB_PATH + shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + ;; + esac + # HP-UX runs *really* slowly unless shared libraries are mode 555. + postinstall_cmds='chmod 555 $lib' + ;; -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char poll (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_poll || defined __stub___poll -choke me -#endif +interix[3-9]*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; -int -main () -{ -return poll (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext 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>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_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - ac_cv_func_poll=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_func_poll=no -fi +irix5* | irix6* | nonstopux*) + case $host_os in + nonstopux*) version_type=nonstopux ;; + *) + if test "$lt_cv_prog_gnu_ld" = yes; then + version_type=linux + else + version_type=irix + fi ;; + esac + need_lib_prefix=no + need_version=no + soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}' + case $host_os in + irix5* | nonstopux*) + libsuff= shlibsuff= + ;; + *) + case $LD in # libtool.m4 will add one of these switches to LD + *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") + libsuff= shlibsuff= libmagic=32-bit;; + *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") + libsuff=32 shlibsuff=N32 libmagic=N32;; + *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") + libsuff=64 shlibsuff=64 libmagic=64-bit;; + *) libsuff= shlibsuff= libmagic=never-match;; + esac + ;; + esac + shlibpath_var=LD_LIBRARY${shlibsuff}_PATH + shlibpath_overrides_runpath=no + sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" + sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" + hardcode_into_libs=yes + ;; -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_func_poll" >&5 -$as_echo "$ac_cv_func_poll" >&6; } -if test "x$ac_cv_func_poll" = x""yes; then +# No shared lib support for Linux oldld, aout, or coff. +linux*oldld* | linux*aout* | linux*coff*) + dynamic_linker=no + ;; -cat >>confdefs.h <<\_ACEOF -#define USE_POLL 1 -_ACEOF +# This must be Linux ELF. +linux* | k*bsd*-gnu) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + # This implies no fast_install, which is unacceptable. + # Some rework will be needed to allow for fast_install + # before this can be enabled. + hardcode_into_libs=yes -fi + # Append ld.so.conf contents to the search path + if test -f /etc/ld.so.conf; then + lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '` + sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" + fi + # We used to test for /lib/ld.so.1 and disable shared libraries on + # powerpc, because MkLinux only supported shared libraries with the + # GNU dynamic linker. Since this was broken with cross compilers, + # most powerpc-linux boxes support dynamic linking these days and + # people can always --disable-shared, the test was removed, and we + # assume the GNU/Linux dynamic linker is in use. + dynamic_linker='GNU/Linux ld.so' + ;; -# -# Find keysymdef.h -# -{ $as_echo "$as_me:$LINENO: checking keysymdef.h" >&5 -$as_echo_n "checking keysymdef.h... " >&6; } -dir=`pkg-config --variable=includedir xproto` -KEYSYMDEF="$dir/X11/keysymdef.h" -if test -f "$KEYSYMDEF"; then - { $as_echo "$as_me:$LINENO: result: $KEYSYMDEF" >&5 -$as_echo "$KEYSYMDEF" >&6; } -else - { { $as_echo "$as_me:$LINENO: error: Cannot find keysymdef.h" >&5 -$as_echo "$as_me: error: Cannot find keysymdef.h" >&2;} - { (exit 1); exit 1; }; } -fi +netbsd*) + version_type=sunos + need_lib_prefix=no + need_version=no + if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' + dynamic_linker='NetBSD (a.out) ld.so' + else + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + dynamic_linker='NetBSD ld.elf_so' + fi + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; +newsos6) + version_type=linux + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + ;; - if test xfalse = xtrue; then - UDC_TRUE= - UDC_FALSE='#' -else - UDC_TRUE='#' - UDC_FALSE= -fi +nto-qnx*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + ;; +openbsd*) + version_type=sunos + sys_lib_dlsearch_path_spec="/usr/lib" + need_lib_prefix=no + # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs. + case $host_os in + openbsd3.3 | openbsd3.3.*) need_version=yes ;; + *) need_version=no ;; + esac + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' + shlibpath_var=LD_LIBRARY_PATH + if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then + case $host_os in + openbsd2.[89] | openbsd2.[89].*) + shlibpath_overrides_runpath=no + ;; + *) + shlibpath_overrides_runpath=yes + ;; + esac + else + shlibpath_overrides_runpath=yes + fi + ;; -# Check whether --enable-xcms was given. -if test "${enable_xcms+set}" = set; then - enableval=$enable_xcms; XCMS=$enableval -else - XCMS=yes -fi +os2*) + libname_spec='$name' + shrext_cmds=".dll" + need_lib_prefix=no + library_names_spec='$libname${shared_ext} $libname.a' + dynamic_linker='OS/2 ld.exe' + shlibpath_var=LIBPATH + ;; - if test x$XCMS = xyes ; then - XCMS_TRUE= - XCMS_FALSE='#' -else - XCMS_TRUE='#' - XCMS_FALSE= -fi +osf3* | osf4* | osf5*) + version_type=osf + need_lib_prefix=no + need_version=no + soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + shlibpath_var=LD_LIBRARY_PATH + sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" + sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" + ;; -if test x"$XCMS" = "xyes"; then +rdos*) + dynamic_linker=no + ;; -cat >>confdefs.h <<\_ACEOF -#define XCMS 1 -_ACEOF +solaris*) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + # ldd complains unless libraries are executable + postinstall_cmds='chmod +x $lib' + ;; -fi +sunos4*) + version_type=sunos + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' + finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + if test "$with_gnu_ld" = yes; then + need_lib_prefix=no + fi + need_version=yes + ;; -# Check whether --enable-xlocale was given. -if test "${enable_xlocale+set}" = set; then - enableval=$enable_xlocale; XLOCALE=$enableval -else - XLOCALE=yes -fi +sysv4 | sysv4.3*) + version_type=linux + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + case $host_vendor in + sni) + shlibpath_overrides_runpath=no + need_lib_prefix=no + export_dynamic_flag_spec='${wl}-Blargedynsym' + runpath_var=LD_RUN_PATH + ;; + siemens) + need_lib_prefix=no + ;; + motorola) + need_lib_prefix=no + need_version=no + shlibpath_overrides_runpath=no + sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' + ;; + esac + ;; +sysv4*MP*) + if test -d /usr/nec ;then + version_type=linux + library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' + soname_spec='$libname${shared_ext}.$major' + shlibpath_var=LD_LIBRARY_PATH + fi + ;; - if test x$XLOCALE = xyes ; then - XLOCALE_TRUE= - XLOCALE_FALSE='#' -else - XLOCALE_TRUE='#' - XLOCALE_FALSE= -fi +sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) + version_type=freebsd-elf + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + hardcode_into_libs=yes + if test "$with_gnu_ld" = yes; then + sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' + shlibpath_overrides_runpath=no + else + sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' + shlibpath_overrides_runpath=yes + case $host_os in + sco3.2v5*) + sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" + ;; + esac + fi + sys_lib_dlsearch_path_spec='/usr/lib' + ;; -if test x"$XLOCALE" = "xyes"; then +uts4*) + version_type=linux + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + ;; -cat >>confdefs.h <<\_ACEOF -#define XLOCALE 1 -_ACEOF +*) + dynamic_linker=no + ;; +esac +{ $as_echo "$as_me:$LINENO: result: $dynamic_linker" >&5 +$as_echo "$dynamic_linker" >&6; } +test "$dynamic_linker" = no && can_build_shared=no +if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then + $as_echo_n "(cached) " >&6 +else + lt_cv_sys_lib_search_path_spec="$sys_lib_search_path_spec" fi -# This disables XLOCALEDIR. Set it if you're using BuildLoadableXlibI18n, -# don't have either issetugid() or getresuid(), and you need to protect -# clients that are setgid or setuid to an id other than 0. -{ $as_echo "$as_me:$LINENO: checking if XLOCALEDIR support should be enabled" >&5 -$as_echo_n "checking if XLOCALEDIR support should be enabled... " >&6; } -# Check whether --enable-xlocaledir was given. -if test "${enable_xlocaledir+set}" = set; then - enableval=$enable_xlocaledir; ENABLE_XLOCALEDIR=$enableval +sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec" +if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then + $as_echo_n "(cached) " >&6 else - ENABLE_XLOCALEDIR=$XLOCALEDIR_IS_SAFE + lt_cv_sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec" fi -if test "x$ENABLE_XLOCALEDIR" = "xno"; then - -cat >>confdefs.h <<\_ACEOF -#define NO_XLOCALEDIR 1 -_ACEOF - -fi -{ $as_echo "$as_me:$LINENO: result: $ENABLE_XLOCALEDIR" >&5 -$as_echo "$ENABLE_XLOCALEDIR" >&6; } +sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec" -# Check whether --enable-xf86bigfont was given. -if test "${enable_xf86bigfont+set}" = set; then - enableval=$enable_xf86bigfont; XF86BIGFONT=$enableval -else - XF86BIGFONT="yes" +variables_saved_for_relink="PATH $shlibpath_var $runpath_var" +if test "$GCC" = yes; then + variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" fi -if test "x$XF86BIGFONT" = "xyes"; then - -pkg_failed=no -{ $as_echo "$as_me:$LINENO: checking for BIGFONT" >&5 -$as_echo_n "checking for BIGFONT... " >&6; } +{ $as_echo "$as_me:$LINENO: checking how to hardcode library paths into programs" >&5 +$as_echo_n "checking how to hardcode library paths into programs... " >&6; } +hardcode_action_GCJ= +if test -n "$hardcode_libdir_flag_spec_GCJ" || \ + test -n "$runpath_var_GCJ" || \ + test "X$hardcode_automatic_GCJ" = "Xyes" ; then -if test -n "$BIGFONT_CFLAGS"; then - pkg_cv_BIGFONT_CFLAGS="$BIGFONT_CFLAGS" - elif test -n "$PKG_CONFIG"; then - if test -n "$PKG_CONFIG" && \ - { ($as_echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \"xf86bigfontproto\"") >&5 - ($PKG_CONFIG --exists --print-errors "xf86bigfontproto") 2>&5 - ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; then - pkg_cv_BIGFONT_CFLAGS=`$PKG_CONFIG --cflags "xf86bigfontproto" 2>/dev/null` -else - pkg_failed=yes -fi - else - pkg_failed=untried -fi -if test -n "$BIGFONT_LIBS"; then - pkg_cv_BIGFONT_LIBS="$BIGFONT_LIBS" - elif test -n "$PKG_CONFIG"; then - if test -n "$PKG_CONFIG" && \ - { ($as_echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \"xf86bigfontproto\"") >&5 - ($PKG_CONFIG --exists --print-errors "xf86bigfontproto") 2>&5 - ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; then - pkg_cv_BIGFONT_LIBS=`$PKG_CONFIG --libs "xf86bigfontproto" 2>/dev/null` + # We can hardcode non-existant directories. + if test "$hardcode_direct_GCJ" != no && + # If the only mechanism to avoid hardcoding is shlibpath_var, we + # have to relink, otherwise we might link with an installed library + # when we should be linking with a yet-to-be-installed one + ## test "$_LT_AC_TAGVAR(hardcode_shlibpath_var, GCJ)" != no && + test "$hardcode_minus_L_GCJ" != no; then + # Linking always hardcodes the temporary library directory. + hardcode_action_GCJ=relink + else + # We can link without hardcoding, and we can hardcode nonexisting dirs. + hardcode_action_GCJ=immediate + fi else - pkg_failed=yes + # We cannot hardcode anything, or else we can only hardcode existing + # directories. + hardcode_action_GCJ=unsupported fi - else - pkg_failed=untried +{ $as_echo "$as_me:$LINENO: result: $hardcode_action_GCJ" >&5 +$as_echo "$hardcode_action_GCJ" >&6; } + +if test "$hardcode_action_GCJ" = relink; then + # Fast installation is not supported + enable_fast_install=no +elif test "$shlibpath_overrides_runpath" = yes || + test "$enable_shared" = no; then + # Fast installation is not necessary + enable_fast_install=needless fi +# The else clause should only fire when bootstrapping the +# libtool distribution, otherwise you forgot to ship ltmain.sh +# with your package, and you will get complaints that there are +# no rules to generate ltmain.sh. +if test -f "$ltmain"; then + # See if we are running on zsh, and set the options which allow our commands through + # without removal of \ escapes. + if test -n "${ZSH_VERSION+set}" ; then + setopt NO_GLOB_SUBST + fi + # Now quote all the things that may contain metacharacters while being + # careful not to overquote the AC_SUBSTed values. We take copies of the + # variables and quote the copies for generation of the libtool script. + for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC LTCFLAGS NM \ + SED SHELL STRIP \ + libname_spec library_names_spec soname_spec extract_expsyms_cmds \ + old_striplib striplib file_magic_cmd finish_cmds finish_eval \ + deplibs_check_method reload_flag reload_cmds need_locks \ + lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \ + lt_cv_sys_global_symbol_to_c_name_address \ + sys_lib_search_path_spec sys_lib_dlsearch_path_spec \ + old_postinstall_cmds old_postuninstall_cmds \ + compiler_GCJ \ + CC_GCJ \ + LD_GCJ \ + lt_prog_compiler_wl_GCJ \ + lt_prog_compiler_pic_GCJ \ + lt_prog_compiler_static_GCJ \ + lt_prog_compiler_no_builtin_flag_GCJ \ + export_dynamic_flag_spec_GCJ \ + thread_safe_flag_spec_GCJ \ + whole_archive_flag_spec_GCJ \ + enable_shared_with_static_runtimes_GCJ \ + old_archive_cmds_GCJ \ + old_archive_from_new_cmds_GCJ \ + predep_objects_GCJ \ + postdep_objects_GCJ \ + predeps_GCJ \ + postdeps_GCJ \ + compiler_lib_search_path_GCJ \ + compiler_lib_search_dirs_GCJ \ + archive_cmds_GCJ \ + archive_expsym_cmds_GCJ \ + postinstall_cmds_GCJ \ + postuninstall_cmds_GCJ \ + old_archive_from_expsyms_cmds_GCJ \ + allow_undefined_flag_GCJ \ + no_undefined_flag_GCJ \ + export_symbols_cmds_GCJ \ + hardcode_libdir_flag_spec_GCJ \ + hardcode_libdir_flag_spec_ld_GCJ \ + hardcode_libdir_separator_GCJ \ + hardcode_automatic_GCJ \ + module_cmds_GCJ \ + module_expsym_cmds_GCJ \ + lt_cv_prog_compiler_c_o_GCJ \ + fix_srcfile_path_GCJ \ + exclude_expsyms_GCJ \ + include_expsyms_GCJ; do + + case $var in + old_archive_cmds_GCJ | \ + old_archive_from_new_cmds_GCJ | \ + archive_cmds_GCJ | \ + archive_expsym_cmds_GCJ | \ + module_cmds_GCJ | \ + module_expsym_cmds_GCJ | \ + old_archive_from_expsyms_cmds_GCJ | \ + export_symbols_cmds_GCJ | \ + extract_expsyms_cmds | reload_cmds | finish_cmds | \ + postinstall_cmds | postuninstall_cmds | \ + old_postinstall_cmds | old_postuninstall_cmds | \ + sys_lib_search_path_spec | sys_lib_dlsearch_path_spec) + # Double-quote double-evaled strings. + eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\"" + ;; + *) + eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\"" + ;; + esac + done -if test $pkg_failed = yes; then + case $lt_echo in + *'\$0 --fallback-echo"') + lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\$0 --fallback-echo"$/$0 --fallback-echo"/'` + ;; + esac -if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then - _pkg_short_errors_supported=yes -else - _pkg_short_errors_supported=no -fi - if test $_pkg_short_errors_supported = yes; then - BIGFONT_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "xf86bigfontproto" 2>&1` - else - BIGFONT_PKG_ERRORS=`$PKG_CONFIG --print-errors "xf86bigfontproto" 2>&1` - fi - # Put the nasty error message in config.log where it belongs - echo "$BIGFONT_PKG_ERRORS" >&5 +cfgfile="$ofile" - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } - XF86BIGFONT="no" -elif test $pkg_failed = untried; then - XF86BIGFONT="no" -else - BIGFONT_CFLAGS=$pkg_cv_BIGFONT_CFLAGS - BIGFONT_LIBS=$pkg_cv_BIGFONT_LIBS - { $as_echo "$as_me:$LINENO: result: yes" >&5 -$as_echo "yes" >&6; } + cat <<__EOF__ >> "$cfgfile" +# ### BEGIN LIBTOOL TAG CONFIG: $tagname -cat >>confdefs.h <<\_ACEOF -#define XF86BIGFONT 1 -_ACEOF +# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: -fi +# Shell to use when invoking shell scripts. +SHELL=$lt_SHELL +# Whether or not to build shared libraries. +build_libtool_libs=$enable_shared -fi +# Whether or not to build static libraries. +build_old_libs=$enable_static -# Check whether --enable-xkb was given. -if test "${enable_xkb+set}" = set; then - enableval=$enable_xkb; XKB=$enableval -else - XKB=yes -fi +# Whether or not to add -lc for building shared libraries. +build_libtool_need_lc=$archive_cmds_need_lc_GCJ +# Whether or not to disallow shared libs when runtime libs are static +allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes_GCJ -# Check whether --enable-man-pages was given. -if test "${enable_man_pages+set}" = set; then - enableval=$enable_man_pages; LIBMAN=$enableval -else - LIBMAN=yes -fi +# Whether or not to optimize for fast installation. +fast_install=$enable_fast_install +# The host system. +host_alias=$host_alias +host=$host +host_os=$host_os -if test "x$LIBMAN" != "xyes"; then - LIB_MAN_SUFFIX=$LIBMAN -fi +# The build system. +build_alias=$build_alias +build=$build +build_os=$build_os - if test x$LIBMAN '!=' xno ; then - MANPAGES_TRUE= - MANPAGES_FALSE='#' -else - MANPAGES_TRUE='#' - MANPAGES_FALSE= -fi +# An echo program that does not interpret backslashes. +echo=$lt_echo +# The archiver. +AR=$lt_AR +AR_FLAGS=$lt_AR_FLAGS - if test x$XKB = xyes ; then - XKB_TRUE= - XKB_FALSE='#' -else - XKB_TRUE='#' - XKB_FALSE= -fi +# A C compiler. +LTCC=$lt_LTCC -if test x"$XKB" = "xyes"; then - XKBPROTO_REQUIRES="kbproto" +# LTCC compiler flags. +LTCFLAGS=$lt_LTCFLAGS -pkg_failed=no -{ $as_echo "$as_me:$LINENO: checking for XKBPROTO" >&5 -$as_echo_n "checking for XKBPROTO... " >&6; } +# A language-specific compiler. +CC=$lt_compiler_GCJ -if test -n "$XKBPROTO_CFLAGS"; then - pkg_cv_XKBPROTO_CFLAGS="$XKBPROTO_CFLAGS" - elif test -n "$PKG_CONFIG"; then - if test -n "$PKG_CONFIG" && \ - { ($as_echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \"kbproto inputproto\"") >&5 - ($PKG_CONFIG --exists --print-errors "kbproto inputproto") 2>&5 - ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; then - pkg_cv_XKBPROTO_CFLAGS=`$PKG_CONFIG --cflags "kbproto inputproto" 2>/dev/null` -else - pkg_failed=yes -fi - else - pkg_failed=untried -fi -if test -n "$XKBPROTO_LIBS"; then - pkg_cv_XKBPROTO_LIBS="$XKBPROTO_LIBS" - elif test -n "$PKG_CONFIG"; then - if test -n "$PKG_CONFIG" && \ - { ($as_echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \"kbproto inputproto\"") >&5 - ($PKG_CONFIG --exists --print-errors "kbproto inputproto") 2>&5 - ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; then - pkg_cv_XKBPROTO_LIBS=`$PKG_CONFIG --libs "kbproto inputproto" 2>/dev/null` -else - pkg_failed=yes -fi - else - pkg_failed=untried -fi +# Is the compiler the GNU C compiler? +with_gcc=$GCC_GCJ +# An ERE matcher. +EGREP=$lt_EGREP +# The linker used to build libraries. +LD=$lt_LD_GCJ -if test $pkg_failed = yes; then +# Whether we need hard or soft links. +LN_S=$lt_LN_S -if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then - _pkg_short_errors_supported=yes -else - _pkg_short_errors_supported=no -fi - if test $_pkg_short_errors_supported = yes; then - XKBPROTO_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "kbproto inputproto" 2>&1` - else - XKBPROTO_PKG_ERRORS=`$PKG_CONFIG --print-errors "kbproto inputproto" 2>&1` - fi - # Put the nasty error message in config.log where it belongs - echo "$XKBPROTO_PKG_ERRORS" >&5 +# A BSD-compatible nm program. +NM=$lt_NM - { { $as_echo "$as_me:$LINENO: error: Package requirements (kbproto inputproto) were not met: +# A symbol stripping program +STRIP=$lt_STRIP -$XKBPROTO_PKG_ERRORS +# Used to examine libraries when file_magic_cmd begins "file" +MAGIC_CMD=$MAGIC_CMD -Consider adjusting the PKG_CONFIG_PATH environment variable if you -installed software in a non-standard prefix. +# Used on cygwin: DLL creation program. +DLLTOOL="$DLLTOOL" -Alternatively, you may set the environment variables XKBPROTO_CFLAGS -and XKBPROTO_LIBS to avoid the need to call pkg-config. -See the pkg-config man page for more details. -" >&5 -$as_echo "$as_me: error: Package requirements (kbproto inputproto) were not met: +# Used on cygwin: object dumper. +OBJDUMP="$OBJDUMP" -$XKBPROTO_PKG_ERRORS +# Used on cygwin: assembler. +AS="$AS" -Consider adjusting the PKG_CONFIG_PATH environment variable if you -installed software in a non-standard prefix. +# The name of the directory that contains temporary libtool files. +objdir=$objdir -Alternatively, you may set the environment variables XKBPROTO_CFLAGS -and XKBPROTO_LIBS to avoid the need to call pkg-config. -See the pkg-config man page for more details. -" >&2;} - { (exit 1); exit 1; }; } -elif test $pkg_failed = untried; then - { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -{ { $as_echo "$as_me:$LINENO: error: The pkg-config script could not be found or is too old. Make sure it -is in your PATH or set the PKG_CONFIG environment variable to the full -path to pkg-config. +# How to create reloadable object files. +reload_flag=$lt_reload_flag +reload_cmds=$lt_reload_cmds -Alternatively, you may set the environment variables XKBPROTO_CFLAGS -and XKBPROTO_LIBS to avoid the need to call pkg-config. -See the pkg-config man page for more details. +# How to pass a linker flag through the compiler. +wl=$lt_lt_prog_compiler_wl_GCJ -To get pkg-config, see . -See \`config.log' for more details." >&5 -$as_echo "$as_me: error: The pkg-config script could not be found or is too old. Make sure it -is in your PATH or set the PKG_CONFIG environment variable to the full -path to pkg-config. +# Object file suffix (normally "o"). +objext="$ac_objext" -Alternatively, you may set the environment variables XKBPROTO_CFLAGS -and XKBPROTO_LIBS to avoid the need to call pkg-config. -See the pkg-config man page for more details. +# Old archive suffix (normally "a"). +libext="$libext" -To get pkg-config, see . -See \`config.log' for more details." >&2;} - { (exit 1); exit 1; }; }; } -else - XKBPROTO_CFLAGS=$pkg_cv_XKBPROTO_CFLAGS - XKBPROTO_LIBS=$pkg_cv_XKBPROTO_LIBS - { $as_echo "$as_me:$LINENO: result: yes" >&5 -$as_echo "yes" >&6; } - : -fi +# Shared library suffix (normally ".so"). +shrext_cmds='$shrext_cmds' -cat >>confdefs.h <<\_ACEOF -#define XKB 1 -_ACEOF +# Executable file suffix (normally ""). +exeext="$exeext" - X11_CFLAGS="$X11_CFLAGS $XKBPROTO_CFLAGS" - X11_LIBS="$X11_LIBS $XKBPROTO_LIBS" -else - XKBPROTO_REQUIRES="" -fi +# Additional compiler flags for building library objects. +pic_flag=$lt_lt_prog_compiler_pic_GCJ +pic_mode=$pic_mode +# What is the maximum length of a command? +max_cmd_len=$lt_cv_sys_max_cmd_len +# Does compiler simultaneously support -c and -o options? +compiler_c_o=$lt_lt_cv_prog_compiler_c_o_GCJ +# Must we lock files when doing compilation? +need_locks=$lt_need_locks -for ac_header in stdlib.h unistd.h -do -as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` -if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then - { $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 -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; } -else - # Is the header compilable? -{ $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5 -$as_echo_n "checking $ac_header usability... " >&6; } -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 - ac_header_compiler=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 +# Do we need the lib prefix for modules? +need_lib_prefix=$need_lib_prefix - ac_header_compiler=no -fi +# Do we need a version for libraries? +need_version=$need_version -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -{ $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 -$as_echo "$ac_header_compiler" >&6; } +# Whether dlopen is supported. +dlopen_support=$enable_dlopen -# Is the header present? -{ $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5 -$as_echo_n "checking $ac_header presence... " >&6; } -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include <$ac_header> -_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 - ac_header_preproc=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 +# Whether dlopen of programs is supported. +dlopen_self=$enable_dlopen_self - ac_header_preproc=no -fi +# Whether dlopen of statically linked programs is supported. +dlopen_self_static=$enable_dlopen_self_static -rm -f conftest.err conftest.$ac_ext -{ $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 -$as_echo "$ac_header_preproc" >&6; } +# Compiler flag to prevent dynamic linking. +link_static_flag=$lt_lt_prog_compiler_static_GCJ -# So? What about this header? -case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in - yes:no: ) - { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5 -$as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;} - { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5 -$as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;} - ac_header_preproc=yes - ;; - no:yes:* ) - { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5 -$as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;} - { $as_echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5 -$as_echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;} - { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5 -$as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;} - { $as_echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5 -$as_echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;} - { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5 -$as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;} - { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5 -$as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;} - ( cat <<\_ASBOX -## ---------------------------------------------------------------------- ## -## Report this to https://bugs.freedesktop.org/enter_bug.cgi?product=xorg ## -## ---------------------------------------------------------------------- ## -_ASBOX - ) | sed "s/^/$as_me: WARNING: /" >&2 - ;; -esac -{ $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 - eval "$as_ac_Header=\$ac_header_preproc" -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; } +# Compiler flag to turn off builtin functions. +no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag_GCJ -fi -as_val=`eval 'as_val=${'$as_ac_Header'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 -_ACEOF +# Compiler flag to allow reflexive dlopens. +export_dynamic_flag_spec=$lt_export_dynamic_flag_spec_GCJ -fi +# Compiler flag to generate shared objects directly from archives. +whole_archive_flag_spec=$lt_whole_archive_flag_spec_GCJ -done +# Compiler flag to generate thread-safe objects. +thread_safe_flag_spec=$lt_thread_safe_flag_spec_GCJ +# Library versioning type. +version_type=$version_type -for ac_func in getpagesize -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; 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. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func +# Format of library name prefix. +libname_spec=$lt_libname_spec -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ +# List of archive names. First name is the real one, the rest are links. +# The last name is the one that the linker finds with -lNAME. +library_names_spec=$lt_library_names_spec -#ifdef __STDC__ -# include -#else -# include -#endif +# The coded name of the library, if different from the real name. +soname_spec=$lt_soname_spec -#undef $ac_func +# Commands used to build and install an old-style archive. +RANLIB=$lt_RANLIB +old_archive_cmds=$lt_old_archive_cmds_GCJ +old_postinstall_cmds=$lt_old_postinstall_cmds +old_postuninstall_cmds=$lt_old_postuninstall_cmds -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif +# Create an old-style archive from a shared archive. +old_archive_from_new_cmds=$lt_old_archive_from_new_cmds_GCJ -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext 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>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_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 +# Create a temporary old-style archive to link instead of a shared archive. +old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds_GCJ - eval "$as_ac_var=no" -fi +# Commands used to build and install a shared archive. +archive_cmds=$lt_archive_cmds_GCJ +archive_expsym_cmds=$lt_archive_expsym_cmds_GCJ +postinstall_cmds=$lt_postinstall_cmds +postuninstall_cmds=$lt_postuninstall_cmds -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 -_ACEOF +# Commands used to build a loadable module (assumed same as above if empty) +module_cmds=$lt_module_cmds_GCJ +module_expsym_cmds=$lt_module_expsym_cmds_GCJ -fi -done +# Commands to strip libraries. +old_striplib=$lt_old_striplib +striplib=$lt_striplib -{ $as_echo "$as_me:$LINENO: checking for working mmap" >&5 -$as_echo_n "checking for working mmap... " >&6; } -if test "${ac_cv_func_mmap_fixed_mapped+set}" = set; then - $as_echo_n "(cached) " >&6 -else - if test "$cross_compiling" = yes; then - ac_cv_func_mmap_fixed_mapped=no -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 -/* malloc might have been renamed as rpl_malloc. */ -#undef malloc +# Dependencies to place before the objects being linked to create a +# shared library. +predep_objects=$lt_predep_objects_GCJ -/* Thanks to Mike Haertel and Jim Avera for this test. - Here is a matrix of mmap possibilities: - mmap private not fixed - mmap private fixed at somewhere currently unmapped - mmap private fixed at somewhere already mapped - mmap shared not fixed - mmap shared fixed at somewhere currently unmapped - mmap shared fixed at somewhere already mapped - For private mappings, we should verify that changes cannot be read() - back from the file, nor mmap's back from the file at a different - address. (There have been systems where private was not correctly - implemented like the infamous i386 svr4.0, and systems where the - VM page cache was not coherent with the file system buffer cache - like early versions of FreeBSD and possibly contemporary NetBSD.) - For shared mappings, we should conversely verify that changes get - propagated back to all the places they're supposed to be. +# Dependencies to place after the objects being linked to create a +# shared library. +postdep_objects=$lt_postdep_objects_GCJ - Grep wants private fixed already mapped. - The main things grep needs to know about mmap are: - * does it exist and is it safe to write into the mmap'd area - * how to use it (BSD variants) */ +# Dependencies to place before the objects being linked to create a +# shared library. +predeps=$lt_predeps_GCJ -#include -#include +# Dependencies to place after the objects being linked to create a +# shared library. +postdeps=$lt_postdeps_GCJ -#if !defined STDC_HEADERS && !defined HAVE_STDLIB_H -char *malloc (); -#endif +# The directories searched by this compiler when creating a shared +# library +compiler_lib_search_dirs=$lt_compiler_lib_search_dirs_GCJ -/* This mess was copied from the GNU getpagesize.h. */ -#ifndef HAVE_GETPAGESIZE -/* Assume that all systems that can run configure have sys/param.h. */ -# ifndef HAVE_SYS_PARAM_H -# define HAVE_SYS_PARAM_H 1 -# endif +# The library search path used internally by the compiler when linking +# a shared library. +compiler_lib_search_path=$lt_compiler_lib_search_path_GCJ -# ifdef _SC_PAGESIZE -# define getpagesize() sysconf(_SC_PAGESIZE) -# else /* no _SC_PAGESIZE */ -# ifdef HAVE_SYS_PARAM_H -# include -# ifdef EXEC_PAGESIZE -# define getpagesize() EXEC_PAGESIZE -# else /* no EXEC_PAGESIZE */ -# ifdef NBPG -# define getpagesize() NBPG * CLSIZE -# ifndef CLSIZE -# define CLSIZE 1 -# endif /* no CLSIZE */ -# else /* no NBPG */ -# ifdef NBPC -# define getpagesize() NBPC -# else /* no NBPC */ -# ifdef PAGESIZE -# define getpagesize() PAGESIZE -# endif /* PAGESIZE */ -# endif /* no NBPC */ -# endif /* no NBPG */ -# endif /* no EXEC_PAGESIZE */ -# else /* no HAVE_SYS_PARAM_H */ -# define getpagesize() 8192 /* punt totally */ -# endif /* no HAVE_SYS_PARAM_H */ -# endif /* no _SC_PAGESIZE */ +# Method to check whether dependent libraries are shared objects. +deplibs_check_method=$lt_deplibs_check_method -#endif /* no HAVE_GETPAGESIZE */ +# Command to use when deplibs_check_method == file_magic. +file_magic_cmd=$lt_file_magic_cmd -int -main () -{ - char *data, *data2, *data3; - int i, pagesize; - int fd; +# Flag that allows shared libraries with undefined symbols to be built. +allow_undefined_flag=$lt_allow_undefined_flag_GCJ - pagesize = getpagesize (); +# Flag that forces no undefined symbols. +no_undefined_flag=$lt_no_undefined_flag_GCJ - /* First, make a file with some known garbage in it. */ - data = (char *) malloc (pagesize); - if (!data) - return 1; - for (i = 0; i < pagesize; ++i) - *(data + i) = rand (); - umask (0); - fd = creat ("conftest.mmap", 0600); - if (fd < 0) - return 1; - if (write (fd, data, pagesize) != pagesize) - return 1; - close (fd); +# Commands used to finish a libtool library installation in a directory. +finish_cmds=$lt_finish_cmds - /* Next, try to mmap the file at a fixed address which already has - something else allocated at it. If we can, also make sure that - we see the same garbage. */ - fd = open ("conftest.mmap", O_RDWR); - if (fd < 0) - return 1; - data2 = (char *) malloc (2 * pagesize); - if (!data2) - return 1; - data2 += (pagesize - ((long int) data2 & (pagesize - 1))) & (pagesize - 1); - if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE, - MAP_PRIVATE | MAP_FIXED, fd, 0L)) - return 1; - for (i = 0; i < pagesize; ++i) - if (*(data + i) != *(data2 + i)) - return 1; +# Same as above, but a single script fragment to be evaled but not shown. +finish_eval=$lt_finish_eval - /* Finally, make sure that changes to the mapped area do not - percolate back to the file as seen by read(). (This is a bug on - some variants of i386 svr4.0.) */ - for (i = 0; i < pagesize; ++i) - *(data2 + i) = *(data2 + i) + 1; - data3 = (char *) malloc (pagesize); - if (!data3) - return 1; - if (read (fd, data3, pagesize) != pagesize) - return 1; - for (i = 0; i < pagesize; ++i) - if (*(data + i) != *(data3 + i)) - return 1; - close (fd); - 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 - ac_cv_func_mmap_fixed_mapped=yes -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_func_mmap_fixed_mapped=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 -{ $as_echo "$as_me:$LINENO: result: $ac_cv_func_mmap_fixed_mapped" >&5 -$as_echo "$ac_cv_func_mmap_fixed_mapped" >&6; } -if test $ac_cv_func_mmap_fixed_mapped = yes; then - -cat >>confdefs.h <<\_ACEOF -#define HAVE_MMAP 1 -_ACEOF +# Take the output of nm and produce a listing of raw symbols and C names. +global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe -fi -rm -f conftest.mmap +# Transform the output of nm in a proper C declaration +global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl -composecache_default=$ac_cv_func_mmap_fixed_mapped -{ $as_echo "$as_me:$LINENO: checking for nl_langinfo" >&5 -$as_echo_n "checking for nl_langinfo... " >&6; } -if test "${ac_cv_func_nl_langinfo+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. */ -/* Define nl_langinfo to an innocuous variant, in case declares nl_langinfo. - For example, HP-UX 11i declares gettimeofday. */ -#define nl_langinfo innocuous_nl_langinfo +# Transform the output of nm in a C name address pair +global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char nl_langinfo (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ +# This is the shared library runtime path variable. +runpath_var=$runpath_var -#ifdef __STDC__ -# include -#else -# include -#endif +# This is the shared library path variable. +shlibpath_var=$shlibpath_var -#undef nl_langinfo +# Is shlibpath searched before the hard-coded library search path? +shlibpath_overrides_runpath=$shlibpath_overrides_runpath -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char nl_langinfo (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_nl_langinfo || defined __stub___nl_langinfo -choke me -#endif +# How to hardcode a shared library path into an executable. +hardcode_action=$hardcode_action_GCJ -int -main () -{ -return nl_langinfo (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext 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>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_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - ac_cv_func_nl_langinfo=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 +# Whether we should hardcode library paths into libraries. +hardcode_into_libs=$hardcode_into_libs - ac_cv_func_nl_langinfo=no -fi +# Flag to hardcode \$libdir into a binary during linking. +# This must work even if \$libdir does not exist. +hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec_GCJ -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_func_nl_langinfo" >&5 -$as_echo "$ac_cv_func_nl_langinfo" >&6; } -if test "x$ac_cv_func_nl_langinfo" = x""yes; then - : -else - composecache_default=no -fi +# If ld is used when linking, flag to hardcode \$libdir into +# a binary during linking. This must work even if \$libdir does +# not exist. +hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld_GCJ -# Check whether --enable-composecache was given. -if test "${enable_composecache+set}" = set; then - enableval=$enable_composecache; COMPOSECACHE=$enableval -else - COMPOSECACHE=$composecache_default -fi +# Whether we need a single -rpath flag with a separated argument. +hardcode_libdir_separator=$lt_hardcode_libdir_separator_GCJ -if test x"$COMPOSECACHE" = "xyes"; then +# Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the +# resulting binary. +hardcode_direct=$hardcode_direct_GCJ -cat >>confdefs.h <<\_ACEOF -#define COMPOSECACHE 1 -_ACEOF +# Set to yes if using the -LDIR flag during linking hardcodes DIR into the +# resulting binary. +hardcode_minus_L=$hardcode_minus_L_GCJ -fi +# Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into +# the resulting binary. +hardcode_shlibpath_var=$hardcode_shlibpath_var_GCJ +# Set to yes if building a shared library automatically hardcodes DIR into the library +# and all subsequent libraries and executables linked against it. +hardcode_automatic=$hardcode_automatic_GCJ +# Variables whose values should be saved in libtool wrapper scripts and +# restored at relink time. +variables_saved_for_relink="$variables_saved_for_relink" -# Allow checking code with lint, sparse, etc. +# Whether libtool must link a program against all its dependency libraries. +link_all_deplibs=$link_all_deplibs_GCJ -# Check whether --with-lint was given. -if test "${with_lint+set}" = set; then - withval=$with_lint; use_lint=$withval -else - use_lint=no -fi +# Compile-time system search path for libraries +sys_lib_search_path_spec=$lt_sys_lib_search_path_spec -if test "x$use_lint" = "xyes" ; then - LINT="lint" -else - LINT="$use_lint" -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 -fi +# Run-time system search path for libraries +sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec +# Fix the shell variable \$srcfile for the compiler. +fix_srcfile_path=$lt_fix_srcfile_path +# Set to yes if exported symbols are required. +always_export_symbols=$always_export_symbols_GCJ - if test x$LINT != xno; then - LINT_TRUE= - LINT_FALSE='#' -else - LINT_TRUE='#' - LINT_FALSE= -fi +# The commands to list exported symbols. +export_symbols_cmds=$lt_export_symbols_cmds_GCJ +# The commands to extract the exported symbol list from a shared archive. +extract_expsyms_cmds=$lt_extract_expsyms_cmds +# Symbols that should not be listed in the preloaded symbols. +exclude_expsyms=$lt_exclude_expsyms_GCJ +# Symbols that must always be exported. +include_expsyms=$lt_include_expsyms_GCJ +# ### END LIBTOOL TAG CONFIG: $tagname -# 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 -else - make_lint_lib=no -fi +__EOF__ -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 -$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-lX11.ln - else - LINTLIB=$make_lint_lib - fi -fi - if test x$make_lint_lib != xno; then - MAKE_LINT_LIB_TRUE= - MAKE_LINT_LIB_FALSE='#' else - MAKE_LINT_LIB_TRUE='#' - MAKE_LINT_LIB_FALSE= + # If there is no Makefile yet, we rely on a make rule to execute + # `config.status --recheck' to rerun these tests and create the + # libtool script then. + ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'` + if test -f "$ltmain_in"; then + test -f Makefile && make "$ltmain" + fi 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 -LINT_FLAGS="${LINT_FLAGS} ${X11_CFLAGS} ${XPROTO_CFLAGS}" - -if test "x$GCC" = "xyes"; then - GCC_WARNINGS="-Wall -Wpointer-arith -Wstrict-prototypes \ - -Wmissing-prototypes -Wmissing-declarations \ - -Wnested-externs -fno-strict-aliasing" - X11_CFLAGS="$GCC_WARNINGS $X11_CFLAGS" -fi - -X11_DATADIR="${datadir}/X11" - - prefix_NONE= - exec_prefix_NONE= - test "x$prefix" = xNONE && prefix_NONE=yes && prefix=$ac_default_prefix - test "x$exec_prefix" = xNONE && exec_prefix_NONE=yes && exec_prefix=$prefix - eval ac_define_dir="\"$X11_DATADIR\"" - eval ac_define_dir="\"$ac_define_dir\"" - X11_DATADIR="$ac_define_dir" +CC="$lt_save_CC" + else + tagname="" + fi + ;; -cat >>confdefs.h <<_ACEOF -#define X11_DATADIR "$ac_define_dir" -_ACEOF + RC) - test "$prefix_NONE" && prefix=NONE - test "$exec_prefix_NONE" && exec_prefix=NONE +# Source file extension for RC test sources. +ac_ext=rc +# Object file extension for compiled RC test sources. +objext=o +objext_RC=$objext -X11_LIBDIR="${libdir}/X11" +# Code to be used in simple compile tests +lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }' - prefix_NONE= - exec_prefix_NONE= - test "x$prefix" = xNONE && prefix_NONE=yes && prefix=$ac_default_prefix - test "x$exec_prefix" = xNONE && exec_prefix_NONE=yes && exec_prefix=$prefix - eval ac_define_dir="\"$X11_LIBDIR\"" - eval ac_define_dir="\"$ac_define_dir\"" - X11_LIBDIR="$ac_define_dir" +# Code to be used in simple link tests +lt_simple_link_test_code="$lt_simple_compile_test_code" +# ltmain only uses $CC for tagged configurations so make sure $CC is set. -cat >>confdefs.h <<_ACEOF -#define X11_LIBDIR "$ac_define_dir" -_ACEOF +# If no C compiler was specified, use CC. +LTCC=${LTCC-"$CC"} - test "$prefix_NONE" && prefix=NONE - test "$exec_prefix_NONE" && exec_prefix=NONE +# If no C compiler flags were specified, use CFLAGS. +LTCFLAGS=${LTCFLAGS-"$CFLAGS"} +# Allow CC to be a program name with arguments. +compiler=$CC -X11_CFLAGS="$CWARNFLAGS $X11_CFLAGS $XPROTO_CFLAGS" +# save warnings/boilerplate of simple test code +ac_outfile=conftest.$ac_objext +echo "$lt_simple_compile_test_code" >conftest.$ac_ext +eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err +_lt_compiler_boilerplate=`cat conftest.err` +$rm conftest* +ac_outfile=conftest.$ac_objext +echo "$lt_simple_link_test_code" >conftest.$ac_ext +eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err +_lt_linker_boilerplate=`cat conftest.err` +$rm -r conftest* -# -# Yes, it would be nice to put the locale data in -# /usr/share, but the locale stuff includes loadable -# libraries which must be located in the same directory -# as the other locale data, so for now, everything lives -# in ${libdir} -# +# Allow CC to be a program name with arguments. +lt_save_CC="$CC" +CC=${RC-"windres"} +compiler=$CC +compiler_RC=$CC +for cc_temp in $compiler""; do + case $cc_temp in + compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; + distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; + \-*) ;; + *) break;; + esac +done +cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` + +lt_cv_prog_compiler_c_o_RC=yes + +# The else clause should only fire when bootstrapping the +# libtool distribution, otherwise you forgot to ship ltmain.sh +# with your package, and you will get complaints that there are +# no rules to generate ltmain.sh. +if test -f "$ltmain"; then + # See if we are running on zsh, and set the options which allow our commands through + # without removal of \ escapes. + if test -n "${ZSH_VERSION+set}" ; then + setopt NO_GLOB_SUBST + fi + # Now quote all the things that may contain metacharacters while being + # careful not to overquote the AC_SUBSTed values. We take copies of the + # variables and quote the copies for generation of the libtool script. + for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC LTCFLAGS NM \ + SED SHELL STRIP \ + libname_spec library_names_spec soname_spec extract_expsyms_cmds \ + old_striplib striplib file_magic_cmd finish_cmds finish_eval \ + deplibs_check_method reload_flag reload_cmds need_locks \ + lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \ + lt_cv_sys_global_symbol_to_c_name_address \ + sys_lib_search_path_spec sys_lib_dlsearch_path_spec \ + old_postinstall_cmds old_postuninstall_cmds \ + compiler_RC \ + CC_RC \ + LD_RC \ + lt_prog_compiler_wl_RC \ + lt_prog_compiler_pic_RC \ + lt_prog_compiler_static_RC \ + lt_prog_compiler_no_builtin_flag_RC \ + export_dynamic_flag_spec_RC \ + thread_safe_flag_spec_RC \ + whole_archive_flag_spec_RC \ + enable_shared_with_static_runtimes_RC \ + old_archive_cmds_RC \ + old_archive_from_new_cmds_RC \ + predep_objects_RC \ + postdep_objects_RC \ + predeps_RC \ + postdeps_RC \ + compiler_lib_search_path_RC \ + compiler_lib_search_dirs_RC \ + archive_cmds_RC \ + archive_expsym_cmds_RC \ + postinstall_cmds_RC \ + postuninstall_cmds_RC \ + old_archive_from_expsyms_cmds_RC \ + allow_undefined_flag_RC \ + no_undefined_flag_RC \ + export_symbols_cmds_RC \ + hardcode_libdir_flag_spec_RC \ + hardcode_libdir_flag_spec_ld_RC \ + hardcode_libdir_separator_RC \ + hardcode_automatic_RC \ + module_cmds_RC \ + module_expsym_cmds_RC \ + lt_cv_prog_compiler_c_o_RC \ + fix_srcfile_path_RC \ + exclude_expsyms_RC \ + include_expsyms_RC; do + + case $var in + old_archive_cmds_RC | \ + old_archive_from_new_cmds_RC | \ + archive_cmds_RC | \ + archive_expsym_cmds_RC | \ + module_cmds_RC | \ + module_expsym_cmds_RC | \ + old_archive_from_expsyms_cmds_RC | \ + export_symbols_cmds_RC | \ + extract_expsyms_cmds | reload_cmds | finish_cmds | \ + postinstall_cmds | postuninstall_cmds | \ + old_postinstall_cmds | old_postuninstall_cmds | \ + sys_lib_search_path_spec | sys_lib_dlsearch_path_spec) + # Double-quote double-evaled strings. + eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\"" + ;; + *) + eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\"" + ;; + esac + done -X11_LOCALEDATADIR="${X11_DATADIR}/locale" + case $lt_echo in + *'\$0 --fallback-echo"') + lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\$0 --fallback-echo"$/$0 --fallback-echo"/'` + ;; + esac - prefix_NONE= - exec_prefix_NONE= - test "x$prefix" = xNONE && prefix_NONE=yes && prefix=$ac_default_prefix - test "x$exec_prefix" = xNONE && exec_prefix_NONE=yes && exec_prefix=$prefix - eval ac_define_dir="\"$X11_LOCALEDATADIR\"" - eval ac_define_dir="\"$ac_define_dir\"" - XLOCALEDATADIR="$ac_define_dir" +cfgfile="$ofile" + cat <<__EOF__ >> "$cfgfile" +# ### BEGIN LIBTOOL TAG CONFIG: $tagname -cat >>confdefs.h <<_ACEOF -#define XLOCALEDATADIR "$ac_define_dir" -_ACEOF +# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: - test "$prefix_NONE" && prefix=NONE - test "$exec_prefix_NONE" && exec_prefix=NONE +# Shell to use when invoking shell scripts. +SHELL=$lt_SHELL +# Whether or not to build shared libraries. +build_libtool_libs=$enable_shared +# Whether or not to build static libraries. +build_old_libs=$enable_static +# Whether or not to add -lc for building shared libraries. +build_libtool_need_lc=$archive_cmds_need_lc_RC -# Check whether --with-locale-lib-dir was given. -if test "${with_locale_lib_dir+set}" = set; then - withval=$with_locale_lib_dir; X11_LOCALELIBDIR="$withval" -else - X11_LOCALELIBDIR="${X11_LIBDIR}/locale" -fi +# Whether or not to disallow shared libs when runtime libs are static +allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes_RC +# Whether or not to optimize for fast installation. +fast_install=$enable_fast_install - prefix_NONE= - exec_prefix_NONE= - test "x$prefix" = xNONE && prefix_NONE=yes && prefix=$ac_default_prefix - test "x$exec_prefix" = xNONE && exec_prefix_NONE=yes && exec_prefix=$prefix - eval ac_define_dir="\"$X11_LOCALELIBDIR\"" - eval ac_define_dir="\"$ac_define_dir\"" - XLOCALELIBDIR="$ac_define_dir" +# The host system. +host_alias=$host_alias +host=$host +host_os=$host_os +# The build system. +build_alias=$build_alias +build=$build +build_os=$build_os -cat >>confdefs.h <<_ACEOF -#define XLOCALELIBDIR "$ac_define_dir" -_ACEOF +# An echo program that does not interpret backslashes. +echo=$lt_echo - test "$prefix_NONE" && prefix=NONE - test "$exec_prefix_NONE" && exec_prefix=NONE +# The archiver. +AR=$lt_AR +AR_FLAGS=$lt_AR_FLAGS +# A C compiler. +LTCC=$lt_LTCC +# LTCC compiler flags. +LTCFLAGS=$lt_LTCFLAGS -X11_LOCALEDIR="${X11_LOCALEDATADIR}" +# A language-specific compiler. +CC=$lt_compiler_RC - prefix_NONE= - exec_prefix_NONE= - test "x$prefix" = xNONE && prefix_NONE=yes && prefix=$ac_default_prefix - test "x$exec_prefix" = xNONE && exec_prefix_NONE=yes && exec_prefix=$prefix - eval ac_define_dir="\"$X11_LOCALEDIR\"" - eval ac_define_dir="\"$ac_define_dir\"" - XLOCALEDIR="$ac_define_dir" +# Is the compiler the GNU C compiler? +with_gcc=$GCC_RC +# An ERE matcher. +EGREP=$lt_EGREP -cat >>confdefs.h <<_ACEOF -#define XLOCALEDIR "$ac_define_dir" -_ACEOF +# The linker used to build libraries. +LD=$lt_LD_RC - test "$prefix_NONE" && prefix=NONE - test "$exec_prefix_NONE" && exec_prefix=NONE +# Whether we need hard or soft links. +LN_S=$lt_LN_S +# A BSD-compatible nm program. +NM=$lt_NM +# A symbol stripping program +STRIP=$lt_STRIP -XKEYSYMDB="${X11_DATADIR}/XKeysymDB" +# Used to examine libraries when file_magic_cmd begins "file" +MAGIC_CMD=$MAGIC_CMD - prefix_NONE= - exec_prefix_NONE= - test "x$prefix" = xNONE && prefix_NONE=yes && prefix=$ac_default_prefix - test "x$exec_prefix" = xNONE && exec_prefix_NONE=yes && exec_prefix=$prefix - eval ac_define_dir="\"$XKEYSYMDB\"" - eval ac_define_dir="\"$ac_define_dir\"" - XKEYSYMDB="$ac_define_dir" +# Used on cygwin: DLL creation program. +DLLTOOL="$DLLTOOL" +# Used on cygwin: object dumper. +OBJDUMP="$OBJDUMP" -cat >>confdefs.h <<_ACEOF -#define XKEYSYMDB "$ac_define_dir" -_ACEOF +# Used on cygwin: assembler. +AS="$AS" - test "$prefix_NONE" && prefix=NONE - test "$exec_prefix_NONE" && exec_prefix=NONE +# The name of the directory that contains temporary libtool files. +objdir=$objdir +# How to create reloadable object files. +reload_flag=$lt_reload_flag +reload_cmds=$lt_reload_cmds -XERRORDB="${X11_DATADIR}/XErrorDB" +# How to pass a linker flag through the compiler. +wl=$lt_lt_prog_compiler_wl_RC - prefix_NONE= - exec_prefix_NONE= - test "x$prefix" = xNONE && prefix_NONE=yes && prefix=$ac_default_prefix - test "x$exec_prefix" = xNONE && exec_prefix_NONE=yes && exec_prefix=$prefix - eval ac_define_dir="\"$XERRORDB\"" - eval ac_define_dir="\"$ac_define_dir\"" - XERRORDB="$ac_define_dir" +# Object file suffix (normally "o"). +objext="$ac_objext" +# Old archive suffix (normally "a"). +libext="$libext" -cat >>confdefs.h <<_ACEOF -#define XERRORDB "$ac_define_dir" -_ACEOF +# Shared library suffix (normally ".so"). +shrext_cmds='$shrext_cmds' - test "$prefix_NONE" && prefix=NONE - test "$exec_prefix_NONE" && exec_prefix=NONE +# Executable file suffix (normally ""). +exeext="$exeext" +# Additional compiler flags for building library objects. +pic_flag=$lt_lt_prog_compiler_pic_RC +pic_mode=$pic_mode +# What is the maximum length of a command? +max_cmd_len=$lt_cv_sys_max_cmd_len -# Check whether --enable-malloc0returnsnull was given. -if test "${enable_malloc0returnsnull+set}" = set; then - enableval=$enable_malloc0returnsnull; MALLOC_ZERO_RETURNS_NULL=$enableval -else - MALLOC_ZERO_RETURNS_NULL=auto -fi +# Does compiler simultaneously support -c and -o options? +compiler_c_o=$lt_lt_cv_prog_compiler_c_o_RC +# Must we lock files when doing compilation? +need_locks=$lt_need_locks -{ $as_echo "$as_me:$LINENO: checking whether malloc(0) returns NULL" >&5 -$as_echo_n "checking whether malloc(0) returns NULL... " >&6; } -if test "x$MALLOC_ZERO_RETURNS_NULL" = xauto; then - if test "$cross_compiling" = yes; then - { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -{ { $as_echo "$as_me:$LINENO: error: cannot run test program while cross compiling -See \`config.log' for more details." >&5 -$as_echo "$as_me: error: cannot run test program while cross compiling -See \`config.log' for more details." >&2;} - { (exit 1); exit 1; }; }; } -else - cat >conftest.$ac_ext <<_ACEOF +# Do we need the lib prefix for modules? +need_lib_prefix=$need_lib_prefix -char *malloc(); -char *realloc(); -char *calloc(); -main() { - char *m0, *r0, *c0, *p; - m0 = malloc(0); - p = malloc(10); - r0 = realloc(p,0); - c0 = calloc(0); - exit(m0 == 0 || r0 == 0 || c0 == 0 ? 0 : 1); -} -_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 - MALLOC_ZERO_RETURNS_NULL=yes -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 +# Do we need a version for libraries? +need_version=$need_version -( exit $ac_status ) -MALLOC_ZERO_RETURNS_NULL=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 +# Whether dlopen is supported. +dlopen_support=$enable_dlopen +# Whether dlopen of programs is supported. +dlopen_self=$enable_dlopen_self -fi -{ $as_echo "$as_me:$LINENO: result: $MALLOC_ZERO_RETURNS_NULL" >&5 -$as_echo "$MALLOC_ZERO_RETURNS_NULL" >&6; } +# Whether dlopen of statically linked programs is supported. +dlopen_self_static=$enable_dlopen_self_static -if test "x$MALLOC_ZERO_RETURNS_NULL" = xyes; then - MALLOC_ZERO_CFLAGS="-DMALLOC_0_RETURNS_NULL" - XMALLOC_ZERO_CFLAGS=$MALLOC_ZERO_CFLAGS - XTMALLOC_ZERO_CFLAGS="$MALLOC_ZERO_CFLAGS -DXTMALLOC_BC" -else - MALLOC_ZERO_CFLAGS="" - XMALLOC_ZERO_CFLAGS="" - XTMALLOC_ZERO_CFLAGS="" -fi +# Compiler flag to prevent dynamic linking. +link_static_flag=$lt_lt_prog_compiler_static_RC +# Compiler flag to turn off builtin functions. +no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag_RC +# Compiler flag to allow reflexive dlopens. +export_dynamic_flag_spec=$lt_export_dynamic_flag_spec_RC +# Compiler flag to generate shared objects directly from archives. +whole_archive_flag_spec=$lt_whole_archive_flag_spec_RC +# Compiler flag to generate thread-safe objects. +thread_safe_flag_spec=$lt_thread_safe_flag_spec_RC +# Library versioning type. +version_type=$version_type -# Support AM_SILENT_RULES if automake-1.11 or later is used -HAVE_AM_SILENT_RULES=yes - if test x$HAVE_AM_SILENT_RULES != x; then - HAVE_AM_SILENT_RULES_TRUE= - HAVE_AM_SILENT_RULES_FALSE='#' -else - HAVE_AM_SILENT_RULES_TRUE='#' - HAVE_AM_SILENT_RULES_FALSE= -fi +# Format of library name prefix. +libname_spec=$lt_libname_spec +# List of archive names. First name is the real one, the rest are links. +# The last name is the one that the linker finds with -lNAME. +library_names_spec=$lt_library_names_spec -ac_config_files="$ac_config_files Makefile include/Makefile man/Makefile man/xkb/Makefile src/Makefile src/util/Makefile src/xcms/Makefile src/xlibi18n/Makefile modules/Makefile modules/im/Makefile modules/im/ximcp/Makefile modules/lc/Makefile modules/lc/def/Makefile modules/lc/gen/Makefile modules/lc/Utf8/Makefile modules/lc/xlocale/Makefile modules/om/Makefile modules/om/generic/Makefile src/xkb/Makefile nls/Makefile nls/am_ET.UTF-8/Makefile nls/armscii-8/Makefile nls/C/Makefile nls/el_GR.UTF-8/Makefile nls/en_US.UTF-8/Makefile nls/fi_FI.UTF-8/Makefile nls/georgian-academy/Makefile nls/georgian-ps/Makefile nls/ibm-cp1133/Makefile nls/iscii-dev/Makefile nls/isiri-3342/Makefile nls/iso8859-1/Makefile nls/iso8859-10/Makefile nls/iso8859-11/Makefile nls/iso8859-13/Makefile nls/iso8859-14/Makefile nls/iso8859-15/Makefile nls/iso8859-2/Makefile nls/iso8859-3/Makefile nls/iso8859-4/Makefile nls/iso8859-5/Makefile nls/iso8859-6/Makefile nls/iso8859-7/Makefile nls/iso8859-8/Makefile nls/iso8859-9/Makefile nls/iso8859-9e/Makefile nls/ja/Makefile nls/ja.JIS/Makefile nls/ja_JP.UTF-8/Makefile nls/ja.S90/Makefile nls/ja.SJIS/Makefile nls/ja.U90/Makefile nls/ko/Makefile nls/koi8-c/Makefile nls/koi8-r/Makefile nls/koi8-u/Makefile nls/ko_KR.UTF-8/Makefile nls/microsoft-cp1251/Makefile nls/microsoft-cp1255/Makefile nls/microsoft-cp1256/Makefile nls/mulelao-1/Makefile nls/nokhchi-1/Makefile nls/pt_BR.UTF-8/Makefile nls/ru_RU.UTF-8/Makefile nls/tatar-cyr/Makefile nls/th_TH/Makefile nls/th_TH.UTF-8/Makefile nls/tscii-0/Makefile nls/vi_VN.tcvn/Makefile nls/vi_VN.viscii/Makefile nls/zh_CN/Makefile nls/zh_CN.gb18030/Makefile nls/zh_CN.gbk/Makefile nls/zh_CN.UTF-8/Makefile nls/zh_HK.big5/Makefile nls/zh_HK.big5hkscs/Makefile nls/zh_HK.UTF-8/Makefile nls/zh_TW/Makefile nls/zh_TW.big5/Makefile nls/zh_TW.UTF-8/Makefile x11.pc x11-xcb.pc" +# The coded name of the library, if different from the real name. +soname_spec=$lt_soname_spec -cat >confcache <<\_ACEOF -# This file is a shell script that caches the results of configure -# tests run on this system so they can be shared between configure -# scripts and configure runs, see configure's option --config-cache. -# It is not useful on other systems. If it contains results you don't -# want to keep, you may remove or edit it. -# -# config.status only pays attention to the cache file if you give it -# the --recheck option to rerun configure. -# -# `ac_cv_env_foo' variables (set or unset) will be overridden when -# loading this file, other *unset* `ac_cv_foo' will be assigned the -# following values. +# Commands used to build and install an old-style archive. +RANLIB=$lt_RANLIB +old_archive_cmds=$lt_old_archive_cmds_RC +old_postinstall_cmds=$lt_old_postinstall_cmds +old_postuninstall_cmds=$lt_old_postuninstall_cmds -_ACEOF +# Create an old-style archive from a shared archive. +old_archive_from_new_cmds=$lt_old_archive_from_new_cmds_RC -# The following way of writing the cache mishandles newlines in values, -# but we know of no workaround that is simple, portable, and efficient. -# So, we kill variables containing newlines. -# Ultrix sh set writes to stderr and can't be redirected directly, -# and sets the high bit in the cache file unless we assign to the vars. -( - for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do - eval ac_val=\$$ac_var - case $ac_val in #( - *${as_nl}*) - case $ac_var in #( - *_cv_*) { $as_echo "$as_me:$LINENO: WARNING: cache variable $ac_var contains a newline" >&5 -$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; - esac - case $ac_var in #( - _ | IFS | as_nl) ;; #( - BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( - *) $as_unset $ac_var ;; - esac ;; - esac - done +# Create a temporary old-style archive to link instead of a shared archive. +old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds_RC - (set) 2>&1 | - case $as_nl`(ac_space=' '; set) 2>&1` in #( - *${as_nl}ac_space=\ *) - # `set' does not quote correctly, so add quotes (double-quote - # substitution turns \\\\ into \\, and sed turns \\ into \). - sed -n \ - "s/'/'\\\\''/g; - s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" - ;; #( - *) - # `set' quotes correctly as required by POSIX, so do not add quotes. - sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" - ;; - esac | - sort -) | - sed ' - /^ac_cv_env_/b end - t clear - :clear - s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ - t end - s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ - :end' >>confcache -if diff "$cache_file" confcache >/dev/null 2>&1; then :; else - if test -w "$cache_file"; then - test "x$cache_file" != "x/dev/null" && - { $as_echo "$as_me:$LINENO: updating cache $cache_file" >&5 -$as_echo "$as_me: updating cache $cache_file" >&6;} - cat confcache >$cache_file - else - { $as_echo "$as_me:$LINENO: not updating unwritable cache $cache_file" >&5 -$as_echo "$as_me: not updating unwritable cache $cache_file" >&6;} - fi -fi -rm -f confcache +# Commands used to build and install a shared archive. +archive_cmds=$lt_archive_cmds_RC +archive_expsym_cmds=$lt_archive_expsym_cmds_RC +postinstall_cmds=$lt_postinstall_cmds +postuninstall_cmds=$lt_postuninstall_cmds -test "x$prefix" = xNONE && prefix=$ac_default_prefix -# Let make expand exec_prefix. -test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' +# Commands used to build a loadable module (assumed same as above if empty) +module_cmds=$lt_module_cmds_RC +module_expsym_cmds=$lt_module_expsym_cmds_RC -DEFS=-DHAVE_CONFIG_H +# Commands to strip libraries. +old_striplib=$lt_old_striplib +striplib=$lt_striplib -ac_libobjs= -ac_ltlibobjs= -for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue - # 1. Remove the extension, and $U if already installed. - ac_script='s/\$U\././;s/\.o$//;s/\.obj$//' - ac_i=`$as_echo "$ac_i" | sed "$ac_script"` - # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR - # will be set to the directory where LIBOBJS objects are built. - ac_libobjs="$ac_libobjs \${LIBOBJDIR}$ac_i\$U.$ac_objext" - ac_ltlibobjs="$ac_ltlibobjs \${LIBOBJDIR}$ac_i"'$U.lo' -done -LIBOBJS=$ac_libobjs +# Dependencies to place before the objects being linked to create a +# shared library. +predep_objects=$lt_predep_objects_RC -LTLIBOBJS=$ac_ltlibobjs +# Dependencies to place after the objects being linked to create a +# shared library. +postdep_objects=$lt_postdep_objects_RC +# Dependencies to place before the objects being linked to create a +# shared library. +predeps=$lt_predeps_RC - if test -n "$EXEEXT"; then - am__EXEEXT_TRUE= - am__EXEEXT_FALSE='#' -else - am__EXEEXT_TRUE='#' - am__EXEEXT_FALSE= -fi +# Dependencies to place after the objects being linked to create a +# shared library. +postdeps=$lt_postdeps_RC -if test -z "${MAINTAINER_MODE_TRUE}" && test -z "${MAINTAINER_MODE_FALSE}"; then - { { $as_echo "$as_me:$LINENO: error: conditional \"MAINTAINER_MODE\" was never defined. -Usually this means the macro was only invoked conditionally." >&5 -$as_echo "$as_me: error: conditional \"MAINTAINER_MODE\" was never defined. -Usually this means the macro was only invoked conditionally." >&2;} - { (exit 1); exit 1; }; } -fi -if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then - { { $as_echo "$as_me:$LINENO: error: conditional \"AMDEP\" was never defined. -Usually this means the macro was only invoked conditionally." >&5 -$as_echo "$as_me: error: conditional \"AMDEP\" was never defined. -Usually this means the macro was only invoked conditionally." >&2;} - { (exit 1); exit 1; }; } -fi -if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then - { { $as_echo "$as_me:$LINENO: error: conditional \"am__fastdepCC\" was never defined. -Usually this means the macro was only invoked conditionally." >&5 -$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 "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then - { { $as_echo "$as_me:$LINENO: error: conditional \"am__fastdepCC\" was never defined. -Usually this means the macro was only invoked conditionally." >&5 -$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 "${HAVE_PERL_TRUE}" && test -z "${HAVE_PERL_FALSE}"; then - { { $as_echo "$as_me:$LINENO: error: conditional \"HAVE_PERL\" was never defined. -Usually this means the macro was only invoked conditionally." >&5 -$as_echo "$as_me: error: conditional \"HAVE_PERL\" was never defined. -Usually this means the macro was only invoked conditionally." >&2;} - { (exit 1); exit 1; }; } -fi -if test -z "${XCB_TRUE}" && test -z "${XCB_FALSE}"; then - { { $as_echo "$as_me:$LINENO: error: conditional \"XCB\" was never defined. -Usually this means the macro was only invoked conditionally." >&5 -$as_echo "$as_me: error: conditional \"XCB\" was never defined. -Usually this means the macro was only invoked conditionally." >&2;} - { (exit 1); exit 1; }; } -fi -if test -z "${XLIB_LOADABLE_I18N_TRUE}" && test -z "${XLIB_LOADABLE_I18N_FALSE}"; then - { { $as_echo "$as_me:$LINENO: error: conditional \"XLIB_LOADABLE_I18N\" was never defined. -Usually this means the macro was only invoked conditionally." >&5 -$as_echo "$as_me: error: conditional \"XLIB_LOADABLE_I18N\" was never defined. -Usually this means the macro was only invoked conditionally." >&2;} - { (exit 1); exit 1; }; } -fi -if test -z "${OS2_TRUE}" && test -z "${OS2_FALSE}"; then - { { $as_echo "$as_me:$LINENO: error: conditional \"OS2\" was never defined. -Usually this means the macro was only invoked conditionally." >&5 -$as_echo "$as_me: error: conditional \"OS2\" was never defined. -Usually this means the macro was only invoked conditionally." >&2;} - { (exit 1); exit 1; }; } -fi -if test -z "${THRSTUBS_TRUE}" && test -z "${THRSTUBS_FALSE}"; then - { { $as_echo "$as_me:$LINENO: error: conditional \"THRSTUBS\" was never defined. -Usually this means the macro was only invoked conditionally." >&5 -$as_echo "$as_me: error: conditional \"THRSTUBS\" was never defined. -Usually this means the macro was only invoked conditionally." >&2;} - { (exit 1); exit 1; }; } -fi -if test -z "${UDC_TRUE}" && test -z "${UDC_FALSE}"; then - { { $as_echo "$as_me:$LINENO: error: conditional \"UDC\" was never defined. -Usually this means the macro was only invoked conditionally." >&5 -$as_echo "$as_me: error: conditional \"UDC\" was never defined. -Usually this means the macro was only invoked conditionally." >&2;} - { (exit 1); exit 1; }; } -fi -if test -z "${XCMS_TRUE}" && test -z "${XCMS_FALSE}"; then - { { $as_echo "$as_me:$LINENO: error: conditional \"XCMS\" was never defined. -Usually this means the macro was only invoked conditionally." >&5 -$as_echo "$as_me: error: conditional \"XCMS\" was never defined. -Usually this means the macro was only invoked conditionally." >&2;} - { (exit 1); exit 1; }; } -fi -if test -z "${XLOCALE_TRUE}" && test -z "${XLOCALE_FALSE}"; then - { { $as_echo "$as_me:$LINENO: error: conditional \"XLOCALE\" was never defined. -Usually this means the macro was only invoked conditionally." >&5 -$as_echo "$as_me: error: conditional \"XLOCALE\" was never defined. -Usually this means the macro was only invoked conditionally." >&2;} - { (exit 1); exit 1; }; } -fi -if test -z "${MANPAGES_TRUE}" && test -z "${MANPAGES_FALSE}"; then - { { $as_echo "$as_me:$LINENO: error: conditional \"MANPAGES\" was never defined. -Usually this means the macro was only invoked conditionally." >&5 -$as_echo "$as_me: error: conditional \"MANPAGES\" was never defined. -Usually this means the macro was only invoked conditionally." >&2;} - { (exit 1); exit 1; }; } -fi -if test -z "${XKB_TRUE}" && test -z "${XKB_FALSE}"; then - { { $as_echo "$as_me:$LINENO: error: conditional \"XKB\" was never defined. -Usually this means the macro was only invoked conditionally." >&5 -$as_echo "$as_me: error: conditional \"XKB\" was never defined. -Usually this means the macro was only invoked conditionally." >&2;} - { (exit 1); exit 1; }; } -fi -if test -z "${LINT_TRUE}" && test -z "${LINT_FALSE}"; then - { { $as_echo "$as_me:$LINENO: error: conditional \"LINT\" was never defined. -Usually this means the macro was only invoked conditionally." >&5 -$as_echo "$as_me: error: conditional \"LINT\" was never defined. -Usually this means the macro was only invoked conditionally." >&2;} - { (exit 1); exit 1; }; } -fi -if test -z "${MAKE_LINT_LIB_TRUE}" && test -z "${MAKE_LINT_LIB_FALSE}"; then - { { $as_echo "$as_me:$LINENO: error: conditional \"MAKE_LINT_LIB\" was never defined. -Usually this means the macro was only invoked conditionally." >&5 -$as_echo "$as_me: error: conditional \"MAKE_LINT_LIB\" was never defined. -Usually this means the macro was only invoked conditionally." >&2;} - { (exit 1); exit 1; }; } -fi -if test -z "${HAVE_AM_SILENT_RULES_TRUE}" && test -z "${HAVE_AM_SILENT_RULES_FALSE}"; then - { { $as_echo "$as_me:$LINENO: error: conditional \"HAVE_AM_SILENT_RULES\" was never defined. -Usually this means the macro was only invoked conditionally." >&5 -$as_echo "$as_me: error: conditional \"HAVE_AM_SILENT_RULES\" was never defined. -Usually this means the macro was only invoked conditionally." >&2;} - { (exit 1); exit 1; }; } -fi +# The directories searched by this compiler when creating a shared +# library +compiler_lib_search_dirs=$lt_compiler_lib_search_dirs_RC -: ${CONFIG_STATUS=./config.status} -ac_write_fail=0 -ac_clean_files_save=$ac_clean_files -ac_clean_files="$ac_clean_files $CONFIG_STATUS" -{ $as_echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5 -$as_echo "$as_me: creating $CONFIG_STATUS" >&6;} -cat >$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -#! $SHELL -# Generated by $as_me. -# Run this file to recreate the current configuration. -# Compiler output produced by configure, useful for debugging -# configure, is in config.log if it exists. +# The library search path used internally by the compiler when linking +# a shared library. +compiler_lib_search_path=$lt_compiler_lib_search_path_RC -debug=false -ac_cs_recheck=false -ac_cs_silent=false -SHELL=\${CONFIG_SHELL-$SHELL} -_ACEOF +# Method to check whether dependent libraries are shared objects. +deplibs_check_method=$lt_deplibs_check_method -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -## --------------------- ## -## M4sh Initialization. ## -## --------------------- ## +# Command to use when deplibs_check_method == file_magic. +file_magic_cmd=$lt_file_magic_cmd -# Be more Bourne compatible -DUALCASE=1; export DUALCASE # for MKS sh -if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then - emulate sh - NULLCMD=: - # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which - # is contrary to our usage. Disable this feature. - alias -g '${1+"$@"}'='"$@"' - setopt NO_GLOB_SUBST -else - case `(set -o) 2>/dev/null` in - *posix*) set -o posix ;; -esac +# Flag that allows shared libraries with undefined symbols to be built. +allow_undefined_flag=$lt_allow_undefined_flag_RC -fi +# Flag that forces no undefined symbols. +no_undefined_flag=$lt_no_undefined_flag_RC +# Commands used to finish a libtool library installation in a directory. +finish_cmds=$lt_finish_cmds +# Same as above, but a single script fragment to be evaled but not shown. +finish_eval=$lt_finish_eval +# Take the output of nm and produce a listing of raw symbols and C names. +global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe -# PATH needs CR -# Avoid depending upon Character Ranges. -as_cr_letters='abcdefghijklmnopqrstuvwxyz' -as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' -as_cr_Letters=$as_cr_letters$as_cr_LETTERS -as_cr_digits='0123456789' -as_cr_alnum=$as_cr_Letters$as_cr_digits +# Transform the output of nm in a proper C declaration +global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl -as_nl=' -' -export as_nl -# Printing a long string crashes Solaris 7 /usr/bin/printf. -as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' -as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo -as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo -if (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then - as_echo='printf %s\n' - as_echo_n='printf %s' -else - if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then - as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' - as_echo_n='/usr/ucb/echo -n' - else - as_echo_body='eval expr "X$1" : "X\\(.*\\)"' - as_echo_n_body='eval - arg=$1; - case $arg in - *"$as_nl"*) - expr "X$arg" : "X\\(.*\\)$as_nl"; - arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; - esac; - expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" - ' - export as_echo_n_body - as_echo_n='sh -c $as_echo_n_body as_echo' - fi - export as_echo_body - as_echo='sh -c $as_echo_body as_echo' -fi +# Transform the output of nm in a C name address pair +global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address -# The user is always right. -if test "${PATH_SEPARATOR+set}" != set; then - PATH_SEPARATOR=: - (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { - (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || - PATH_SEPARATOR=';' - } -fi +# This is the shared library runtime path variable. +runpath_var=$runpath_var -# Support unset when possible. -if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then - as_unset=unset -else - as_unset=false -fi +# This is the shared library path variable. +shlibpath_var=$shlibpath_var +# Is shlibpath searched before the hard-coded library search path? +shlibpath_overrides_runpath=$shlibpath_overrides_runpath -# IFS -# We need space, tab and new line, in precisely that order. Quoting is -# there to prevent editors from complaining about space-tab. -# (If _AS_PATH_WALK were called with IFS unset, it would disable word -# splitting by setting IFS to empty value.) -IFS=" "" $as_nl" +# How to hardcode a shared library path into an executable. +hardcode_action=$hardcode_action_RC -# Find who we are. Look in the path if we contain no directory separator. -case $0 in - *[\\/]* ) as_myself=$0 ;; - *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break -done -IFS=$as_save_IFS +# Whether we should hardcode library paths into libraries. +hardcode_into_libs=$hardcode_into_libs - ;; -esac -# We did not find ourselves, most probably we were run as `sh COMMAND' -# in which case we are not to be found in the path. -if test "x$as_myself" = x; then - as_myself=$0 -fi -if test ! -f "$as_myself"; then - $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 - { (exit 1); exit 1; } -fi +# Flag to hardcode \$libdir into a binary during linking. +# This must work even if \$libdir does not exist. +hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec_RC -# Work around bugs in pre-3.0 UWIN ksh. -for as_var in ENV MAIL MAILPATH -do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var -done -PS1='$ ' -PS2='> ' -PS4='+ ' +# If ld is used when linking, flag to hardcode \$libdir into +# a binary during linking. This must work even if \$libdir does +# not exist. +hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld_RC -# NLS nuisances. -LC_ALL=C -export LC_ALL -LANGUAGE=C -export LANGUAGE +# Whether we need a single -rpath flag with a separated argument. +hardcode_libdir_separator=$lt_hardcode_libdir_separator_RC -# Required to use basename. -if expr a : '\(a\)' >/dev/null 2>&1 && - test "X`expr 00001 : '.*\(...\)'`" = X001; then - as_expr=expr -else - as_expr=false -fi +# Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the +# resulting binary. +hardcode_direct=$hardcode_direct_RC -if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then - as_basename=basename -else - as_basename=false -fi +# Set to yes if using the -LDIR flag during linking hardcodes DIR into the +# resulting binary. +hardcode_minus_L=$hardcode_minus_L_RC +# Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into +# the resulting binary. +hardcode_shlibpath_var=$hardcode_shlibpath_var_RC -# Name of the executable. -as_me=`$as_basename -- "$0" || -$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ - X"$0" : 'X\(//\)$' \| \ - X"$0" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X/"$0" | - sed '/^.*\/\([^/][^/]*\)\/*$/{ - s//\1/ - q - } - /^X\/\(\/\/\)$/{ - s//\1/ - q - } - /^X\/\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` +# Set to yes if building a shared library automatically hardcodes DIR into the library +# and all subsequent libraries and executables linked against it. +hardcode_automatic=$hardcode_automatic_RC -# CDPATH. -$as_unset CDPATH +# Variables whose values should be saved in libtool wrapper scripts and +# restored at relink time. +variables_saved_for_relink="$variables_saved_for_relink" +# Whether libtool must link a program against all its dependency libraries. +link_all_deplibs=$link_all_deplibs_RC +# Compile-time system search path for libraries +sys_lib_search_path_spec=$lt_sys_lib_search_path_spec - as_lineno_1=$LINENO - as_lineno_2=$LINENO - test "x$as_lineno_1" != "x$as_lineno_2" && - test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2" || { +# Run-time system search path for libraries +sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec - # Create $as_me.lineno as a copy of $as_myself, but with $LINENO - # uniformly replaced by the line number. The first 'sed' inserts a - # line-number line after each line using $LINENO; the second 'sed' - # does the real work. The second script uses 'N' to pair each - # line-number line with the line containing $LINENO, and appends - # trailing '-' during substitution so that $LINENO is not a special - # case at line end. - # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the - # scripts with optimization help from Paolo Bonzini. Blame Lee - # E. McMahon (1931-1989) for sed's syntax. :-) - sed -n ' - p - /[$]LINENO/= - ' <$as_myself | - sed ' - s/[$]LINENO.*/&-/ - t lineno - b - :lineno - N - :loop - s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/ - t loop - s/-\n.*// - ' >$as_me.lineno && - chmod +x "$as_me.lineno" || - { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2 - { (exit 1); exit 1; }; } +# Fix the shell variable \$srcfile for the compiler. +fix_srcfile_path=$lt_fix_srcfile_path - # Don't try to exec as it changes $[0], causing all sort of problems - # (the dirname of $[0] is not the place where we might find the - # original and so on. Autoconf is especially sensitive to this). - . "./$as_me.lineno" - # Exit status is that of the last command. - exit -} +# Set to yes if exported symbols are required. +always_export_symbols=$always_export_symbols_RC +# The commands to list exported symbols. +export_symbols_cmds=$lt_export_symbols_cmds_RC -if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then - as_dirname=dirname -else - as_dirname=false -fi +# The commands to extract the exported symbol list from a shared archive. +extract_expsyms_cmds=$lt_extract_expsyms_cmds -ECHO_C= ECHO_N= ECHO_T= -case `echo -n x` in --n*) - case `echo 'x\c'` in - *c*) ECHO_T=' ';; # ECHO_T is single tab character. - *) ECHO_C='\c';; - esac;; -*) - ECHO_N='-n';; -esac -if expr a : '\(a\)' >/dev/null 2>&1 && - test "X`expr 00001 : '.*\(...\)'`" = X001; then - as_expr=expr -else - as_expr=false -fi +# Symbols that should not be listed in the preloaded symbols. +exclude_expsyms=$lt_exclude_expsyms_RC -rm -f conf$$ conf$$.exe conf$$.file -if test -d conf$$.dir; then - rm -f conf$$.dir/conf$$.file -else - rm -f conf$$.dir - mkdir conf$$.dir 2>/dev/null -fi -if (echo >conf$$.file) 2>/dev/null; then - if ln -s conf$$.file conf$$ 2>/dev/null; then - as_ln_s='ln -s' - # ... but there are two gotchas: - # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. - # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. - # In both cases, we have to default to `cp -p'. - ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || - as_ln_s='cp -p' - elif ln conf$$.file conf$$ 2>/dev/null; then - as_ln_s=ln - else - as_ln_s='cp -p' - fi -else - as_ln_s='cp -p' -fi -rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file -rmdir conf$$.dir 2>/dev/null +# Symbols that must always be exported. +include_expsyms=$lt_include_expsyms_RC + +# ### END LIBTOOL TAG CONFIG: $tagname + +__EOF__ -if mkdir -p . 2>/dev/null; then - as_mkdir_p=: -else - test -d ./-p && rmdir ./-p - as_mkdir_p=false -fi -if test -x / >/dev/null 2>&1; then - as_test_x='test -x' else - if ls -dL / >/dev/null 2>&1; then - as_ls_L_option=L - else - as_ls_L_option= + # If there is no Makefile yet, we rely on a make rule to execute + # `config.status --recheck' to rerun these tests and create the + # libtool script then. + ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'` + if test -f "$ltmain_in"; then + test -f Makefile && make "$ltmain" fi - as_test_x=' - eval sh -c '\'' - if test -d "$1"; then - test -d "$1/."; - else - case $1 in - -*)set "./$1";; - esac; - case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in - ???[sx]*):;;*)false;;esac;fi - '\'' sh - ' fi -as_executable_p=$as_test_x -# Sed expression to map a string onto a valid CPP name. -as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" - -# Sed expression to map a string onto a valid variable name. -as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" +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 -exec 6>&1 - -# Save the log message, to keep $[0] and so on meaningful, and to -# report actual input values of CONFIG_FILES etc. instead of their -# values after options handling. -ac_log=" -This file was extended by libX11 $as_me 1.3, which was -generated by GNU Autoconf 2.63. Invocation command line was +CC="$lt_save_CC" - CONFIG_FILES = $CONFIG_FILES - CONFIG_HEADERS = $CONFIG_HEADERS - CONFIG_LINKS = $CONFIG_LINKS - CONFIG_COMMANDS = $CONFIG_COMMANDS - $ $0 $@ + ;; -on `(hostname || uname -n) 2>/dev/null | sed 1q` -" + *) + { { $as_echo "$as_me:$LINENO: error: Unsupported tag name: $tagname" >&5 +$as_echo "$as_me: error: Unsupported tag name: $tagname" >&2;} + { (exit 1); exit 1; }; } + ;; + esac -_ACEOF + # Append the new tag name to the list of available tags. + if test -n "$tagname" ; then + available_tags="$available_tags $tagname" + fi + fi + done + IFS="$lt_save_ifs" -case $ac_config_files in *" -"*) set x $ac_config_files; shift; ac_config_files=$*;; -esac + # Now substitute the updated list of available tags. + if eval "sed -e 's/^available_tags=.*\$/available_tags=\"$available_tags\"/' \"$ofile\" > \"${ofile}T\""; then + mv "${ofile}T" "$ofile" + chmod +x "$ofile" + else + rm -f "${ofile}T" + { { $as_echo "$as_me:$LINENO: error: unable to update list of available tagged configurations." >&5 +$as_echo "$as_me: error: unable to update list of available tagged configurations." >&2;} + { (exit 1); exit 1; }; } + fi +fi -case $ac_config_headers in *" -"*) set x $ac_config_headers; shift; ac_config_headers=$*;; -esac -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -# Files that config.status was made for. -config_files="$ac_config_files" -config_headers="$ac_config_headers" -config_commands="$ac_config_commands" +# This can be used to rebuild libtool when needed +LIBTOOL_DEPS="$ac_aux_dir/ltmain.sh" -_ACEOF +# Always use our own libtool. +LIBTOOL='$(SHELL) $(top_builddir)/libtool' -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -ac_cs_usage="\ -\`$as_me' instantiates files from templates according to the -current configuration. +# Prevent multiple expansion -Usage: $0 [OPTION]... [FILE]... - -h, --help print this help, then exit - -V, --version print version number and configuration settings, then exit - -q, --quiet, --silent - do not print progress messages - -d, --debug don't remove temporary files - --recheck update $as_me by reconfiguring in the same conditions - --file=FILE[:TEMPLATE] - instantiate the configuration file FILE - --header=FILE[:TEMPLATE] - instantiate the configuration header FILE -Configuration files: -$config_files -Configuration headers: -$config_headers -Configuration commands: -$config_commands -Report bugs to ." -_ACEOF -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -ac_cs_version="\\ -libX11 config.status 1.3 -configured by $0, generated by GNU Autoconf 2.63, - with options \\"`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\" -Copyright (C) 2008 Free Software Foundation, Inc. -This config.status script is free software; the Free Software Foundation -gives unlimited permission to copy, distribute and modify it." -ac_pwd='$ac_pwd' -srcdir='$srcdir' -INSTALL='$INSTALL' -MKDIR_P='$MKDIR_P' -AWK='$AWK' -test -n "\$AWK" || AWK=awk -_ACEOF -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -# The default lists apply if the user does not specify any file. -ac_need_defaults=: -while test $# != 0 -do - case $1 in - --*=*) - ac_option=`expr "X$1" : 'X\([^=]*\)='` - ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` - ac_shift=: - ;; - *) - ac_option=$1 - ac_optarg=$2 - ac_shift=shift - ;; - esac - case $ac_option in - # Handling of the options. - -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) - ac_cs_recheck=: ;; - --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) - $as_echo "$ac_cs_version"; exit ;; - --debug | --debu | --deb | --de | --d | -d ) - debug=: ;; - --file | --fil | --fi | --f ) - $ac_shift - case $ac_optarg in - *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; - esac - CONFIG_FILES="$CONFIG_FILES '$ac_optarg'" - ac_need_defaults=false;; - --header | --heade | --head | --hea ) - $ac_shift - case $ac_optarg in - *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; - esac - CONFIG_HEADERS="$CONFIG_HEADERS '$ac_optarg'" - ac_need_defaults=false;; - --he | --h) - # Conflict between --help and --header - { $as_echo "$as_me: error: ambiguous option: $1 -Try \`$0 --help' for more information." >&2 - { (exit 1); exit 1; }; };; - --help | --hel | -h ) - $as_echo "$ac_cs_usage"; exit ;; - -q | -quiet | --quiet | --quie | --qui | --qu | --q \ - | -silent | --silent | --silen | --sile | --sil | --si | --s) - ac_cs_silent=: ;; - # This is an error. - -*) { $as_echo "$as_me: error: unrecognized option: $1 -Try \`$0 --help' for more information." >&2 - { (exit 1); exit 1; }; } ;; - *) ac_config_targets="$ac_config_targets $1" - ac_need_defaults=false ;; - esac - shift -done -ac_configure_extra_args= -if $ac_cs_silent; then - exec 6>/dev/null - ac_configure_extra_args="$ac_configure_extra_args --silent" -fi -_ACEOF -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -if \$ac_cs_recheck; then - set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion - shift - \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6 - CONFIG_SHELL='$SHELL' - export CONFIG_SHELL - exec "\$@" -fi -_ACEOF -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -exec 5>>config.log -{ - echo - sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX -## Running $as_me. ## -_ASBOX - $as_echo "$ac_log" -} >&5 -_ACEOF -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -# -# INIT-COMMANDS -# -AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir" -# The HP-UX ksh and POSIX shell print the target directory to stdout -# if CDPATH is set. -(unset CDPATH) >/dev/null 2>&1 && unset CDPATH -sed_quote_subst='$sed_quote_subst' -double_quote_subst='$double_quote_subst' -delay_variable_subst='$delay_variable_subst' -macro_version='`$ECHO "X$macro_version" | $Xsed -e "$delay_single_quote_subst"`' -macro_revision='`$ECHO "X$macro_revision" | $Xsed -e "$delay_single_quote_subst"`' -enable_shared='`$ECHO "X$enable_shared" | $Xsed -e "$delay_single_quote_subst"`' -enable_static='`$ECHO "X$enable_static" | $Xsed -e "$delay_single_quote_subst"`' -pic_mode='`$ECHO "X$pic_mode" | $Xsed -e "$delay_single_quote_subst"`' -enable_fast_install='`$ECHO "X$enable_fast_install" | $Xsed -e "$delay_single_quote_subst"`' -host_alias='`$ECHO "X$host_alias" | $Xsed -e "$delay_single_quote_subst"`' -host='`$ECHO "X$host" | $Xsed -e "$delay_single_quote_subst"`' -host_os='`$ECHO "X$host_os" | $Xsed -e "$delay_single_quote_subst"`' -build_alias='`$ECHO "X$build_alias" | $Xsed -e "$delay_single_quote_subst"`' -build='`$ECHO "X$build" | $Xsed -e "$delay_single_quote_subst"`' -build_os='`$ECHO "X$build_os" | $Xsed -e "$delay_single_quote_subst"`' -SED='`$ECHO "X$SED" | $Xsed -e "$delay_single_quote_subst"`' -Xsed='`$ECHO "X$Xsed" | $Xsed -e "$delay_single_quote_subst"`' -GREP='`$ECHO "X$GREP" | $Xsed -e "$delay_single_quote_subst"`' -EGREP='`$ECHO "X$EGREP" | $Xsed -e "$delay_single_quote_subst"`' -FGREP='`$ECHO "X$FGREP" | $Xsed -e "$delay_single_quote_subst"`' -LD='`$ECHO "X$LD" | $Xsed -e "$delay_single_quote_subst"`' -NM='`$ECHO "X$NM" | $Xsed -e "$delay_single_quote_subst"`' -LN_S='`$ECHO "X$LN_S" | $Xsed -e "$delay_single_quote_subst"`' -max_cmd_len='`$ECHO "X$max_cmd_len" | $Xsed -e "$delay_single_quote_subst"`' -ac_objext='`$ECHO "X$ac_objext" | $Xsed -e "$delay_single_quote_subst"`' -exeext='`$ECHO "X$exeext" | $Xsed -e "$delay_single_quote_subst"`' -lt_unset='`$ECHO "X$lt_unset" | $Xsed -e "$delay_single_quote_subst"`' -lt_SP2NL='`$ECHO "X$lt_SP2NL" | $Xsed -e "$delay_single_quote_subst"`' -lt_NL2SP='`$ECHO "X$lt_NL2SP" | $Xsed -e "$delay_single_quote_subst"`' -reload_flag='`$ECHO "X$reload_flag" | $Xsed -e "$delay_single_quote_subst"`' -reload_cmds='`$ECHO "X$reload_cmds" | $Xsed -e "$delay_single_quote_subst"`' -OBJDUMP='`$ECHO "X$OBJDUMP" | $Xsed -e "$delay_single_quote_subst"`' -deplibs_check_method='`$ECHO "X$deplibs_check_method" | $Xsed -e "$delay_single_quote_subst"`' -file_magic_cmd='`$ECHO "X$file_magic_cmd" | $Xsed -e "$delay_single_quote_subst"`' -AR='`$ECHO "X$AR" | $Xsed -e "$delay_single_quote_subst"`' -AR_FLAGS='`$ECHO "X$AR_FLAGS" | $Xsed -e "$delay_single_quote_subst"`' -STRIP='`$ECHO "X$STRIP" | $Xsed -e "$delay_single_quote_subst"`' -RANLIB='`$ECHO "X$RANLIB" | $Xsed -e "$delay_single_quote_subst"`' -old_postinstall_cmds='`$ECHO "X$old_postinstall_cmds" | $Xsed -e "$delay_single_quote_subst"`' -old_postuninstall_cmds='`$ECHO "X$old_postuninstall_cmds" | $Xsed -e "$delay_single_quote_subst"`' -old_archive_cmds='`$ECHO "X$old_archive_cmds" | $Xsed -e "$delay_single_quote_subst"`' -CC='`$ECHO "X$CC" | $Xsed -e "$delay_single_quote_subst"`' -CFLAGS='`$ECHO "X$CFLAGS" | $Xsed -e "$delay_single_quote_subst"`' -compiler='`$ECHO "X$compiler" | $Xsed -e "$delay_single_quote_subst"`' -GCC='`$ECHO "X$GCC" | $Xsed -e "$delay_single_quote_subst"`' -lt_cv_sys_global_symbol_pipe='`$ECHO "X$lt_cv_sys_global_symbol_pipe" | $Xsed -e "$delay_single_quote_subst"`' -lt_cv_sys_global_symbol_to_cdecl='`$ECHO "X$lt_cv_sys_global_symbol_to_cdecl" | $Xsed -e "$delay_single_quote_subst"`' -lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "X$lt_cv_sys_global_symbol_to_c_name_address" | $Xsed -e "$delay_single_quote_subst"`' -lt_cv_sys_global_symbol_to_c_name_address_lib_prefix='`$ECHO "X$lt_cv_sys_global_symbol_to_c_name_address_lib_prefix" | $Xsed -e "$delay_single_quote_subst"`' -objdir='`$ECHO "X$objdir" | $Xsed -e "$delay_single_quote_subst"`' -SHELL='`$ECHO "X$SHELL" | $Xsed -e "$delay_single_quote_subst"`' -ECHO='`$ECHO "X$ECHO" | $Xsed -e "$delay_single_quote_subst"`' -MAGIC_CMD='`$ECHO "X$MAGIC_CMD" | $Xsed -e "$delay_single_quote_subst"`' -lt_prog_compiler_no_builtin_flag='`$ECHO "X$lt_prog_compiler_no_builtin_flag" | $Xsed -e "$delay_single_quote_subst"`' -lt_prog_compiler_wl='`$ECHO "X$lt_prog_compiler_wl" | $Xsed -e "$delay_single_quote_subst"`' -lt_prog_compiler_pic='`$ECHO "X$lt_prog_compiler_pic" | $Xsed -e "$delay_single_quote_subst"`' -lt_prog_compiler_static='`$ECHO "X$lt_prog_compiler_static" | $Xsed -e "$delay_single_quote_subst"`' -lt_cv_prog_compiler_c_o='`$ECHO "X$lt_cv_prog_compiler_c_o" | $Xsed -e "$delay_single_quote_subst"`' -need_locks='`$ECHO "X$need_locks" | $Xsed -e "$delay_single_quote_subst"`' -DSYMUTIL='`$ECHO "X$DSYMUTIL" | $Xsed -e "$delay_single_quote_subst"`' -NMEDIT='`$ECHO "X$NMEDIT" | $Xsed -e "$delay_single_quote_subst"`' -LIPO='`$ECHO "X$LIPO" | $Xsed -e "$delay_single_quote_subst"`' -OTOOL='`$ECHO "X$OTOOL" | $Xsed -e "$delay_single_quote_subst"`' -OTOOL64='`$ECHO "X$OTOOL64" | $Xsed -e "$delay_single_quote_subst"`' -libext='`$ECHO "X$libext" | $Xsed -e "$delay_single_quote_subst"`' -shrext_cmds='`$ECHO "X$shrext_cmds" | $Xsed -e "$delay_single_quote_subst"`' -extract_expsyms_cmds='`$ECHO "X$extract_expsyms_cmds" | $Xsed -e "$delay_single_quote_subst"`' -archive_cmds_need_lc='`$ECHO "X$archive_cmds_need_lc" | $Xsed -e "$delay_single_quote_subst"`' -enable_shared_with_static_runtimes='`$ECHO "X$enable_shared_with_static_runtimes" | $Xsed -e "$delay_single_quote_subst"`' -export_dynamic_flag_spec='`$ECHO "X$export_dynamic_flag_spec" | $Xsed -e "$delay_single_quote_subst"`' -whole_archive_flag_spec='`$ECHO "X$whole_archive_flag_spec" | $Xsed -e "$delay_single_quote_subst"`' -compiler_needs_object='`$ECHO "X$compiler_needs_object" | $Xsed -e "$delay_single_quote_subst"`' -old_archive_from_new_cmds='`$ECHO "X$old_archive_from_new_cmds" | $Xsed -e "$delay_single_quote_subst"`' -old_archive_from_expsyms_cmds='`$ECHO "X$old_archive_from_expsyms_cmds" | $Xsed -e "$delay_single_quote_subst"`' -archive_cmds='`$ECHO "X$archive_cmds" | $Xsed -e "$delay_single_quote_subst"`' -archive_expsym_cmds='`$ECHO "X$archive_expsym_cmds" | $Xsed -e "$delay_single_quote_subst"`' -module_cmds='`$ECHO "X$module_cmds" | $Xsed -e "$delay_single_quote_subst"`' -module_expsym_cmds='`$ECHO "X$module_expsym_cmds" | $Xsed -e "$delay_single_quote_subst"`' -with_gnu_ld='`$ECHO "X$with_gnu_ld" | $Xsed -e "$delay_single_quote_subst"`' -allow_undefined_flag='`$ECHO "X$allow_undefined_flag" | $Xsed -e "$delay_single_quote_subst"`' -no_undefined_flag='`$ECHO "X$no_undefined_flag" | $Xsed -e "$delay_single_quote_subst"`' -hardcode_libdir_flag_spec='`$ECHO "X$hardcode_libdir_flag_spec" | $Xsed -e "$delay_single_quote_subst"`' -hardcode_libdir_flag_spec_ld='`$ECHO "X$hardcode_libdir_flag_spec_ld" | $Xsed -e "$delay_single_quote_subst"`' -hardcode_libdir_separator='`$ECHO "X$hardcode_libdir_separator" | $Xsed -e "$delay_single_quote_subst"`' -hardcode_direct='`$ECHO "X$hardcode_direct" | $Xsed -e "$delay_single_quote_subst"`' -hardcode_direct_absolute='`$ECHO "X$hardcode_direct_absolute" | $Xsed -e "$delay_single_quote_subst"`' -hardcode_minus_L='`$ECHO "X$hardcode_minus_L" | $Xsed -e "$delay_single_quote_subst"`' -hardcode_shlibpath_var='`$ECHO "X$hardcode_shlibpath_var" | $Xsed -e "$delay_single_quote_subst"`' -hardcode_automatic='`$ECHO "X$hardcode_automatic" | $Xsed -e "$delay_single_quote_subst"`' -inherit_rpath='`$ECHO "X$inherit_rpath" | $Xsed -e "$delay_single_quote_subst"`' -link_all_deplibs='`$ECHO "X$link_all_deplibs" | $Xsed -e "$delay_single_quote_subst"`' -fix_srcfile_path='`$ECHO "X$fix_srcfile_path" | $Xsed -e "$delay_single_quote_subst"`' -always_export_symbols='`$ECHO "X$always_export_symbols" | $Xsed -e "$delay_single_quote_subst"`' -export_symbols_cmds='`$ECHO "X$export_symbols_cmds" | $Xsed -e "$delay_single_quote_subst"`' -exclude_expsyms='`$ECHO "X$exclude_expsyms" | $Xsed -e "$delay_single_quote_subst"`' -include_expsyms='`$ECHO "X$include_expsyms" | $Xsed -e "$delay_single_quote_subst"`' -prelink_cmds='`$ECHO "X$prelink_cmds" | $Xsed -e "$delay_single_quote_subst"`' -file_list_spec='`$ECHO "X$file_list_spec" | $Xsed -e "$delay_single_quote_subst"`' -variables_saved_for_relink='`$ECHO "X$variables_saved_for_relink" | $Xsed -e "$delay_single_quote_subst"`' -need_lib_prefix='`$ECHO "X$need_lib_prefix" | $Xsed -e "$delay_single_quote_subst"`' -need_version='`$ECHO "X$need_version" | $Xsed -e "$delay_single_quote_subst"`' -version_type='`$ECHO "X$version_type" | $Xsed -e "$delay_single_quote_subst"`' -runpath_var='`$ECHO "X$runpath_var" | $Xsed -e "$delay_single_quote_subst"`' -shlibpath_var='`$ECHO "X$shlibpath_var" | $Xsed -e "$delay_single_quote_subst"`' -shlibpath_overrides_runpath='`$ECHO "X$shlibpath_overrides_runpath" | $Xsed -e "$delay_single_quote_subst"`' -libname_spec='`$ECHO "X$libname_spec" | $Xsed -e "$delay_single_quote_subst"`' -library_names_spec='`$ECHO "X$library_names_spec" | $Xsed -e "$delay_single_quote_subst"`' -soname_spec='`$ECHO "X$soname_spec" | $Xsed -e "$delay_single_quote_subst"`' -postinstall_cmds='`$ECHO "X$postinstall_cmds" | $Xsed -e "$delay_single_quote_subst"`' -postuninstall_cmds='`$ECHO "X$postuninstall_cmds" | $Xsed -e "$delay_single_quote_subst"`' -finish_cmds='`$ECHO "X$finish_cmds" | $Xsed -e "$delay_single_quote_subst"`' -finish_eval='`$ECHO "X$finish_eval" | $Xsed -e "$delay_single_quote_subst"`' -hardcode_into_libs='`$ECHO "X$hardcode_into_libs" | $Xsed -e "$delay_single_quote_subst"`' -sys_lib_search_path_spec='`$ECHO "X$sys_lib_search_path_spec" | $Xsed -e "$delay_single_quote_subst"`' -sys_lib_dlsearch_path_spec='`$ECHO "X$sys_lib_dlsearch_path_spec" | $Xsed -e "$delay_single_quote_subst"`' -hardcode_action='`$ECHO "X$hardcode_action" | $Xsed -e "$delay_single_quote_subst"`' -enable_dlopen='`$ECHO "X$enable_dlopen" | $Xsed -e "$delay_single_quote_subst"`' -enable_dlopen_self='`$ECHO "X$enable_dlopen_self" | $Xsed -e "$delay_single_quote_subst"`' -enable_dlopen_self_static='`$ECHO "X$enable_dlopen_self_static" | $Xsed -e "$delay_single_quote_subst"`' -old_striplib='`$ECHO "X$old_striplib" | $Xsed -e "$delay_single_quote_subst"`' -striplib='`$ECHO "X$striplib" | $Xsed -e "$delay_single_quote_subst"`' - -LTCC='$LTCC' -LTCFLAGS='$LTCFLAGS' -compiler='$compiler_DEFAULT' - -# Quote evaled strings. -for var in SED \ -GREP \ -EGREP \ -FGREP \ -LD \ -NM \ -LN_S \ -lt_SP2NL \ -lt_NL2SP \ -reload_flag \ -OBJDUMP \ -deplibs_check_method \ -file_magic_cmd \ -AR \ -AR_FLAGS \ -STRIP \ -RANLIB \ -CC \ -CFLAGS \ -compiler \ -lt_cv_sys_global_symbol_pipe \ -lt_cv_sys_global_symbol_to_cdecl \ -lt_cv_sys_global_symbol_to_c_name_address \ -lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \ -SHELL \ -ECHO \ -lt_prog_compiler_no_builtin_flag \ -lt_prog_compiler_wl \ -lt_prog_compiler_pic \ -lt_prog_compiler_static \ -lt_cv_prog_compiler_c_o \ -need_locks \ -DSYMUTIL \ -NMEDIT \ -LIPO \ -OTOOL \ -OTOOL64 \ -shrext_cmds \ -export_dynamic_flag_spec \ -whole_archive_flag_spec \ -compiler_needs_object \ -with_gnu_ld \ -allow_undefined_flag \ -no_undefined_flag \ -hardcode_libdir_flag_spec \ -hardcode_libdir_flag_spec_ld \ -hardcode_libdir_separator \ -fix_srcfile_path \ -exclude_expsyms \ -include_expsyms \ -file_list_spec \ -variables_saved_for_relink \ -libname_spec \ -library_names_spec \ -soname_spec \ -finish_eval \ -old_striplib \ -striplib; do - case \`eval \\\\\$ECHO "X\\\\\$\$var"\` in - *[\\\\\\\`\\"\\\$]*) - eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"X\\\$\$var\\" | \\\$Xsed -e \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" - ;; - *) - eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" - ;; - esac +# dolt, a replacement for libtool +# Josh Triplett +# Extract the first word of "bash", so it can be a program name with args. +set dummy bash; 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_DOLT_BASH+set}" = set; then + $as_echo_n "(cached) " >&6 +else + case $DOLT_BASH in + [\\/]* | ?:[\\/]*) + ac_cv_path_DOLT_BASH="$DOLT_BASH" # 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_DOLT_BASH="$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 - -# Double-quote double-evaled strings. -for var in reload_cmds \ -old_postinstall_cmds \ -old_postuninstall_cmds \ -old_archive_cmds \ -extract_expsyms_cmds \ -old_archive_from_new_cmds \ -old_archive_from_expsyms_cmds \ -archive_cmds \ -archive_expsym_cmds \ -module_cmds \ -module_expsym_cmds \ -export_symbols_cmds \ -prelink_cmds \ -postinstall_cmds \ -postuninstall_cmds \ -finish_cmds \ -sys_lib_search_path_spec \ -sys_lib_dlsearch_path_spec; do - case \`eval \\\\\$ECHO "X\\\\\$\$var"\` in - *[\\\\\\\`\\"\\\$]*) - eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"X\\\$\$var\\" | \\\$Xsed -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" - ;; - *) - eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" - ;; - esac done +IFS=$as_save_IFS -# Fix-up fallback echo if it was mangled by the above quoting rules. -case \$lt_ECHO in -*'\\\$0 --fallback-echo"') lt_ECHO=\`\$ECHO "X\$lt_ECHO" | \$Xsed -e 's/\\\\\\\\\\\\\\\$0 --fallback-echo"\$/\$0 --fallback-echo"/'\` ;; esac +fi +DOLT_BASH=$ac_cv_path_DOLT_BASH +if test -n "$DOLT_BASH"; then + { $as_echo "$as_me:$LINENO: result: $DOLT_BASH" >&5 +$as_echo "$DOLT_BASH" >&6; } +else + { $as_echo "$as_me:$LINENO: result: no" >&5 +$as_echo "no" >&6; } +fi -ac_aux_dir='$ac_aux_dir' -xsi_shell='$xsi_shell' -lt_shell_append='$lt_shell_append' -# See if we are running on zsh, and set the options which allow our -# commands through without removal of \ escapes INIT. -if test -n "\${ZSH_VERSION+set}" ; then - setopt NO_GLOB_SUBST +{ $as_echo "$as_me:$LINENO: checking if dolt supports this host" >&5 +$as_echo_n "checking if dolt supports this host... " >&6; } +dolt_supported=yes +if test x$DOLT_BASH = x; then + dolt_supported=no fi +if test x$GCC != xyes; then + dolt_supported=no +fi +case $host in +i?86-*-linux*|x86_64-*-linux*|powerpc-*-linux* \ +|amd64-*-freebsd*|i?86-*-freebsd*|ia64-*-freebsd*) + pic_options='-fPIC' + ;; +i?86-pc-cygwin*) + pic_options='-DDLL_EXPORT' + ;; +i?86-apple-darwin*) + pic_options='-fno-common' + ;; +*) + dolt_supported=no + ;; +esac +if test x$dolt_supported = xno ; then + { $as_echo "$as_me:$LINENO: result: no, falling back to libtool" >&5 +$as_echo "no, falling back to libtool" >&6; } + LTCOMPILE='$(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(COMPILE)' + LTCXXCOMPILE='$(LIBTOOL) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXXCOMPILE)' +else + { $as_echo "$as_me:$LINENO: result: yes, replacing libtool" >&5 +$as_echo "yes, replacing libtool" >&6; } - - PACKAGE='$PACKAGE' - VERSION='$VERSION' - TIMESTAMP='$TIMESTAMP' - RM='$RM' - ofile='$ofile' - - - - -_ACEOF - -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 - -# Handling of arguments. -for ac_config_target in $ac_config_targets -do - case $ac_config_target in - "src/config.h") CONFIG_HEADERS="$CONFIG_HEADERS src/config.h" ;; - "include/X11/XlibConf.h") CONFIG_HEADERS="$CONFIG_HEADERS include/X11/XlibConf.h" ;; - "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;; - "libtool") CONFIG_COMMANDS="$CONFIG_COMMANDS libtool" ;; - "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;; - "include/Makefile") CONFIG_FILES="$CONFIG_FILES include/Makefile" ;; - "man/Makefile") CONFIG_FILES="$CONFIG_FILES man/Makefile" ;; - "man/xkb/Makefile") CONFIG_FILES="$CONFIG_FILES man/xkb/Makefile" ;; - "src/Makefile") CONFIG_FILES="$CONFIG_FILES src/Makefile" ;; - "src/util/Makefile") CONFIG_FILES="$CONFIG_FILES src/util/Makefile" ;; - "src/xcms/Makefile") CONFIG_FILES="$CONFIG_FILES src/xcms/Makefile" ;; - "src/xlibi18n/Makefile") CONFIG_FILES="$CONFIG_FILES src/xlibi18n/Makefile" ;; - "modules/Makefile") CONFIG_FILES="$CONFIG_FILES modules/Makefile" ;; - "modules/im/Makefile") CONFIG_FILES="$CONFIG_FILES modules/im/Makefile" ;; - "modules/im/ximcp/Makefile") CONFIG_FILES="$CONFIG_FILES modules/im/ximcp/Makefile" ;; - "modules/lc/Makefile") CONFIG_FILES="$CONFIG_FILES modules/lc/Makefile" ;; - "modules/lc/def/Makefile") CONFIG_FILES="$CONFIG_FILES modules/lc/def/Makefile" ;; - "modules/lc/gen/Makefile") CONFIG_FILES="$CONFIG_FILES modules/lc/gen/Makefile" ;; - "modules/lc/Utf8/Makefile") CONFIG_FILES="$CONFIG_FILES modules/lc/Utf8/Makefile" ;; - "modules/lc/xlocale/Makefile") CONFIG_FILES="$CONFIG_FILES modules/lc/xlocale/Makefile" ;; - "modules/om/Makefile") CONFIG_FILES="$CONFIG_FILES modules/om/Makefile" ;; - "modules/om/generic/Makefile") CONFIG_FILES="$CONFIG_FILES modules/om/generic/Makefile" ;; - "src/xkb/Makefile") CONFIG_FILES="$CONFIG_FILES src/xkb/Makefile" ;; - "nls/Makefile") CONFIG_FILES="$CONFIG_FILES nls/Makefile" ;; - "nls/am_ET.UTF-8/Makefile") CONFIG_FILES="$CONFIG_FILES nls/am_ET.UTF-8/Makefile" ;; - "nls/armscii-8/Makefile") CONFIG_FILES="$CONFIG_FILES nls/armscii-8/Makefile" ;; - "nls/C/Makefile") CONFIG_FILES="$CONFIG_FILES nls/C/Makefile" ;; - "nls/el_GR.UTF-8/Makefile") CONFIG_FILES="$CONFIG_FILES nls/el_GR.UTF-8/Makefile" ;; - "nls/en_US.UTF-8/Makefile") CONFIG_FILES="$CONFIG_FILES nls/en_US.UTF-8/Makefile" ;; - "nls/fi_FI.UTF-8/Makefile") CONFIG_FILES="$CONFIG_FILES nls/fi_FI.UTF-8/Makefile" ;; - "nls/georgian-academy/Makefile") CONFIG_FILES="$CONFIG_FILES nls/georgian-academy/Makefile" ;; - "nls/georgian-ps/Makefile") CONFIG_FILES="$CONFIG_FILES nls/georgian-ps/Makefile" ;; - "nls/ibm-cp1133/Makefile") CONFIG_FILES="$CONFIG_FILES nls/ibm-cp1133/Makefile" ;; - "nls/iscii-dev/Makefile") CONFIG_FILES="$CONFIG_FILES nls/iscii-dev/Makefile" ;; - "nls/isiri-3342/Makefile") CONFIG_FILES="$CONFIG_FILES nls/isiri-3342/Makefile" ;; - "nls/iso8859-1/Makefile") CONFIG_FILES="$CONFIG_FILES nls/iso8859-1/Makefile" ;; - "nls/iso8859-10/Makefile") CONFIG_FILES="$CONFIG_FILES nls/iso8859-10/Makefile" ;; - "nls/iso8859-11/Makefile") CONFIG_FILES="$CONFIG_FILES nls/iso8859-11/Makefile" ;; - "nls/iso8859-13/Makefile") CONFIG_FILES="$CONFIG_FILES nls/iso8859-13/Makefile" ;; - "nls/iso8859-14/Makefile") CONFIG_FILES="$CONFIG_FILES nls/iso8859-14/Makefile" ;; - "nls/iso8859-15/Makefile") CONFIG_FILES="$CONFIG_FILES nls/iso8859-15/Makefile" ;; - "nls/iso8859-2/Makefile") CONFIG_FILES="$CONFIG_FILES nls/iso8859-2/Makefile" ;; - "nls/iso8859-3/Makefile") CONFIG_FILES="$CONFIG_FILES nls/iso8859-3/Makefile" ;; - "nls/iso8859-4/Makefile") CONFIG_FILES="$CONFIG_FILES nls/iso8859-4/Makefile" ;; - "nls/iso8859-5/Makefile") CONFIG_FILES="$CONFIG_FILES nls/iso8859-5/Makefile" ;; - "nls/iso8859-6/Makefile") CONFIG_FILES="$CONFIG_FILES nls/iso8859-6/Makefile" ;; - "nls/iso8859-7/Makefile") CONFIG_FILES="$CONFIG_FILES nls/iso8859-7/Makefile" ;; - "nls/iso8859-8/Makefile") CONFIG_FILES="$CONFIG_FILES nls/iso8859-8/Makefile" ;; - "nls/iso8859-9/Makefile") CONFIG_FILES="$CONFIG_FILES nls/iso8859-9/Makefile" ;; - "nls/iso8859-9e/Makefile") CONFIG_FILES="$CONFIG_FILES nls/iso8859-9e/Makefile" ;; - "nls/ja/Makefile") CONFIG_FILES="$CONFIG_FILES nls/ja/Makefile" ;; - "nls/ja.JIS/Makefile") CONFIG_FILES="$CONFIG_FILES nls/ja.JIS/Makefile" ;; - "nls/ja_JP.UTF-8/Makefile") CONFIG_FILES="$CONFIG_FILES nls/ja_JP.UTF-8/Makefile" ;; - "nls/ja.S90/Makefile") CONFIG_FILES="$CONFIG_FILES nls/ja.S90/Makefile" ;; - "nls/ja.SJIS/Makefile") CONFIG_FILES="$CONFIG_FILES nls/ja.SJIS/Makefile" ;; - "nls/ja.U90/Makefile") CONFIG_FILES="$CONFIG_FILES nls/ja.U90/Makefile" ;; - "nls/ko/Makefile") CONFIG_FILES="$CONFIG_FILES nls/ko/Makefile" ;; - "nls/koi8-c/Makefile") CONFIG_FILES="$CONFIG_FILES nls/koi8-c/Makefile" ;; - "nls/koi8-r/Makefile") CONFIG_FILES="$CONFIG_FILES nls/koi8-r/Makefile" ;; - "nls/koi8-u/Makefile") CONFIG_FILES="$CONFIG_FILES nls/koi8-u/Makefile" ;; - "nls/ko_KR.UTF-8/Makefile") CONFIG_FILES="$CONFIG_FILES nls/ko_KR.UTF-8/Makefile" ;; - "nls/microsoft-cp1251/Makefile") CONFIG_FILES="$CONFIG_FILES nls/microsoft-cp1251/Makefile" ;; - "nls/microsoft-cp1255/Makefile") CONFIG_FILES="$CONFIG_FILES nls/microsoft-cp1255/Makefile" ;; - "nls/microsoft-cp1256/Makefile") CONFIG_FILES="$CONFIG_FILES nls/microsoft-cp1256/Makefile" ;; - "nls/mulelao-1/Makefile") CONFIG_FILES="$CONFIG_FILES nls/mulelao-1/Makefile" ;; - "nls/nokhchi-1/Makefile") CONFIG_FILES="$CONFIG_FILES nls/nokhchi-1/Makefile" ;; - "nls/pt_BR.UTF-8/Makefile") CONFIG_FILES="$CONFIG_FILES nls/pt_BR.UTF-8/Makefile" ;; - "nls/ru_RU.UTF-8/Makefile") CONFIG_FILES="$CONFIG_FILES nls/ru_RU.UTF-8/Makefile" ;; - "nls/tatar-cyr/Makefile") CONFIG_FILES="$CONFIG_FILES nls/tatar-cyr/Makefile" ;; - "nls/th_TH/Makefile") CONFIG_FILES="$CONFIG_FILES nls/th_TH/Makefile" ;; - "nls/th_TH.UTF-8/Makefile") CONFIG_FILES="$CONFIG_FILES nls/th_TH.UTF-8/Makefile" ;; - "nls/tscii-0/Makefile") CONFIG_FILES="$CONFIG_FILES nls/tscii-0/Makefile" ;; - "nls/vi_VN.tcvn/Makefile") CONFIG_FILES="$CONFIG_FILES nls/vi_VN.tcvn/Makefile" ;; - "nls/vi_VN.viscii/Makefile") CONFIG_FILES="$CONFIG_FILES nls/vi_VN.viscii/Makefile" ;; - "nls/zh_CN/Makefile") CONFIG_FILES="$CONFIG_FILES nls/zh_CN/Makefile" ;; - "nls/zh_CN.gb18030/Makefile") CONFIG_FILES="$CONFIG_FILES nls/zh_CN.gb18030/Makefile" ;; - "nls/zh_CN.gbk/Makefile") CONFIG_FILES="$CONFIG_FILES nls/zh_CN.gbk/Makefile" ;; - "nls/zh_CN.UTF-8/Makefile") CONFIG_FILES="$CONFIG_FILES nls/zh_CN.UTF-8/Makefile" ;; - "nls/zh_HK.big5/Makefile") CONFIG_FILES="$CONFIG_FILES nls/zh_HK.big5/Makefile" ;; - "nls/zh_HK.big5hkscs/Makefile") CONFIG_FILES="$CONFIG_FILES nls/zh_HK.big5hkscs/Makefile" ;; - "nls/zh_HK.UTF-8/Makefile") CONFIG_FILES="$CONFIG_FILES nls/zh_HK.UTF-8/Makefile" ;; - "nls/zh_TW/Makefile") CONFIG_FILES="$CONFIG_FILES nls/zh_TW/Makefile" ;; - "nls/zh_TW.big5/Makefile") CONFIG_FILES="$CONFIG_FILES nls/zh_TW.big5/Makefile" ;; - "nls/zh_TW.UTF-8/Makefile") CONFIG_FILES="$CONFIG_FILES nls/zh_TW.UTF-8/Makefile" ;; - "x11.pc") CONFIG_FILES="$CONFIG_FILES x11.pc" ;; - "x11-xcb.pc") CONFIG_FILES="$CONFIG_FILES x11-xcb.pc" ;; - - *) { { $as_echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5 -$as_echo "$as_me: error: invalid argument: $ac_config_target" >&2;} - { (exit 1); exit 1; }; };; - esac + cat <<__DOLTCOMPILE__EOF__ >doltcompile +#!$DOLT_BASH +__DOLTCOMPILE__EOF__ + cat <<'__DOLTCOMPILE__EOF__' >>doltcompile +args=("$@") +for ((arg=0; arg<${#args[@]}; arg++)) ; do + if test x"${args[$arg]}" = x-o ; then + objarg=$((arg+1)) + break + fi done +if test x$objarg = x ; then + echo 'Error: no -o on compiler command line' 1>&2 + exit 1 +fi +lo="${args[$objarg]}" +obj="${lo%.lo}" +if test x"$lo" = x"$obj" ; then + echo "Error: libtool object file name \"$lo\" does not end in .lo" 1>&2 + exit 1 +fi +objbase="${obj##*/}" +__DOLTCOMPILE__EOF__ - -# If the user did not use the arguments to specify the items to instantiate, -# then the envvar interface is used. Set only those that are not. -# We use the long form for the default assignment because of an extremely -# bizarre bug on SunOS 4.1.3. -if $ac_need_defaults; then - test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files - test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers - test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands + if test x$enable_shared = xyes; then + cat <<'__DOLTCOMPILE__EOF__' >>doltcompile +libobjdir="${obj%$objbase}.libs" +if test ! -d "$libobjdir" ; then + mkdir_out="$(mkdir "$libobjdir" 2>&1)" + mkdir_ret=$? + if test "$mkdir_ret" -ne 0 && test ! -d "$libobjdir" ; then + echo "$mkdir_out" 1>&2 + exit $mkdir_ret + fi fi +pic_object="$libobjdir/$objbase.o" +args[$objarg]="$pic_object" +__DOLTCOMPILE__EOF__ + cat <<__DOLTCOMPILE__EOF__ >>doltcompile +"\${args[@]}" $pic_options -DPIC || exit \$? +__DOLTCOMPILE__EOF__ + fi -# Have a temporary directory for convenience. Make it in the build tree -# simply because there is no reason against having it here, and in addition, -# creating and moving files from /tmp can sometimes cause problems. -# Hook for its removal unless debugging. -# Note that there is a small window in which the directory will not be cleaned: -# after its creation but before its name has been assigned to `$tmp'. -$debug || -{ - tmp= - trap 'exit_status=$? - { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status -' 0 - trap '{ (exit 1); exit 1; }' 1 2 13 15 -} -# Create a (secure) tmp directory for tmp files. + if test x$enable_static = xyes; then + cat <<'__DOLTCOMPILE__EOF__' >>doltcompile +non_pic_object="$obj.o" +args[$objarg]="$non_pic_object" +__DOLTCOMPILE__EOF__ + if test x$enable_shared = xyes; then + cat <<'__DOLTCOMPILE__EOF__' >>doltcompile +"${args[@]}" >/dev/null 2>&1 || exit $? +__DOLTCOMPILE__EOF__ + else + cat <<'__DOLTCOMPILE__EOF__' >>doltcompile +"${args[@]}" || exit $? +__DOLTCOMPILE__EOF__ + fi + fi + cat <<'__DOLTCOMPILE__EOF__' >>doltcompile { - tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && - test -n "$tmp" && test -d "$tmp" -} || -{ - tmp=./conf$$-$RANDOM - (umask 077 && mkdir "$tmp") -} || -{ - $as_echo "$as_me: cannot create a temporary directory in ." >&2 - { (exit 1); exit 1; } -} +echo "# $lo - a libtool object file" +echo "# Generated by doltcompile, not libtool" +__DOLTCOMPILE__EOF__ -# Set up the scripts for CONFIG_FILES section. -# No need to generate them if there are no CONFIG_FILES. -# This happens for instance with `./config.status config.h'. -if test -n "$CONFIG_FILES"; then + if test x$enable_shared = xyes; then + cat <<'__DOLTCOMPILE__EOF__' >>doltcompile +echo "pic_object='.libs/${objbase}.o'" +__DOLTCOMPILE__EOF__ + else + cat <<'__DOLTCOMPILE__EOF__' >>doltcompile +echo pic_object=none +__DOLTCOMPILE__EOF__ + fi + if test x$enable_static = xyes; then + cat <<'__DOLTCOMPILE__EOF__' >>doltcompile +echo "non_pic_object='${objbase}.o'" +__DOLTCOMPILE__EOF__ + else + cat <<'__DOLTCOMPILE__EOF__' >>doltcompile +echo non_pic_object=none +__DOLTCOMPILE__EOF__ + fi -ac_cr=' ' -ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' /dev/null` -if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then - ac_cs_awk_cr='\\r' + cat <<'__DOLTCOMPILE__EOF__' >>doltcompile +} > "$lo" +__DOLTCOMPILE__EOF__ + + chmod +x doltcompile + LTCOMPILE='$(top_builddir)/doltcompile $(COMPILE)' + LTCXXCOMPILE='$(top_builddir)/doltcompile $(CXXCOMPILE)' + + cat <<__DOLTLIBTOOL__EOF__ > doltlibtool +#!$DOLT_BASH +__DOLTLIBTOOL__EOF__ + cat <<'__DOLTLIBTOOL__EOF__' >>doltlibtool +top_builddir_slash="${0%%doltlibtool}" +: ${top_builddir_slash:=./} +args=() +modeok=false +tagok=false +for arg in "$@"; do + case "$arg" in + --mode=compile) modeok=true ;; + --tag=CC|--tag=CXX) tagok=true ;; + *) args[${#args[@]}]="$arg" ;; + esac +done +if $modeok && $tagok ; then + . ${top_builddir_slash}doltcompile "${args[@]}" else - ac_cs_awk_cr=$ac_cr + exec ${top_builddir_slash}libtool "$@" fi +__DOLTLIBTOOL__EOF__ -echo 'BEGIN {' >"$tmp/subs1.awk" && -_ACEOF + chmod +x doltlibtool + LIBTOOL='$(top_builddir)/doltlibtool' +fi -{ - echo "cat >conf$$subs.awk <<_ACEOF" && - echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' && - echo "_ACEOF" -} >conf$$subs.sh || - { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5 -$as_echo "$as_me: error: could not make $CONFIG_STATUS" >&2;} - { (exit 1); exit 1; }; } -ac_delim_num=`echo "$ac_subst_vars" | grep -c '$'` -ac_delim='%!_!# ' -for ac_last_try in false false false false false :; do - . ./conf$$subs.sh || - { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5 -$as_echo "$as_me: error: could not make $CONFIG_STATUS" >&2;} - { (exit 1); exit 1; }; } +# end dolt - ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X` - if test $ac_delim_n = $ac_delim_num; then - break - elif $ac_last_try; then - { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5 -$as_echo "$as_me: error: could not make $CONFIG_STATUS" >&2;} - { (exit 1); exit 1; }; } - else - ac_delim="$ac_delim!$ac_delim _$ac_delim!! " +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 +if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args. +set dummy ${ac_tool_prefix}gcc; 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_prog_CC+set}" = set; then + $as_echo_n "(cached) " >&6 +else + if test -n "$CC"; then + ac_cv_prog_CC="$CC" # Let the user override the test. +else +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_prog_CC="${ac_tool_prefix}gcc" + $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 fi done -rm -f conf$$subs.sh +done +IFS=$as_save_IFS -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -cat >>"\$tmp/subs1.awk" <<\\_ACAWK && -_ACEOF -sed -n ' -h -s/^/S["/; s/!.*/"]=/ -p -g -s/^[^!]*!// -:repl -t repl -s/'"$ac_delim"'$// -t delim -:nl -h -s/\(.\{148\}\).*/\1/ -t more1 -s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/ -p -n -b repl -:more1 -s/["\\]/\\&/g; s/^/"/; s/$/"\\/ -p -g -s/.\{148\}// -t nl -:delim -h -s/\(.\{148\}\).*/\1/ -t more2 -s/["\\]/\\&/g; s/^/"/; s/$/"/ -p -b -:more2 -s/["\\]/\\&/g; s/^/"/; s/$/"\\/ -p -g -s/.\{148\}// -t delim -' >$CONFIG_STATUS || ac_write_fail=1 -rm -f conf$$subs.awk -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -_ACAWK -cat >>"\$tmp/subs1.awk" <<_ACAWK && - for (key in S) S_is_set[key] = 1 - FS = "" +fi +fi +CC=$ac_cv_prog_CC +if test -n "$CC"; then + { $as_echo "$as_me:$LINENO: result: $CC" >&5 +$as_echo "$CC" >&6; } +else + { $as_echo "$as_me:$LINENO: result: no" >&5 +$as_echo "no" >&6; } +fi -} -{ - line = $ 0 - nfields = split(line, field, "@") - substed = 0 - len = length(field[1]) - for (i = 2; i < nfields; i++) { - key = field[i] - keylen = length(key) - if (S_is_set[key]) { - value = S[key] - line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3) - len += length(value) + length(field[++i]) - substed = 1 - } else - len += 1 + keylen - } - print line -} +fi +if test -z "$ac_cv_prog_CC"; then + ac_ct_CC=$CC + # Extract the first word of "gcc", so it can be a program name with args. +set dummy gcc; 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_prog_ac_ct_CC+set}" = set; then + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_CC"; then + ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. +else +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_prog_ac_ct_CC="gcc" + $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done +done +IFS=$as_save_IFS -_ACAWK -_ACEOF -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then - sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g" +fi +fi +ac_ct_CC=$ac_cv_prog_ac_ct_CC +if test -n "$ac_ct_CC"; then + { $as_echo "$as_me:$LINENO: result: $ac_ct_CC" >&5 +$as_echo "$ac_ct_CC" >&6; } else - cat -fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \ - || { { $as_echo "$as_me:$LINENO: error: could not setup config files machinery" >&5 -$as_echo "$as_me: error: could not setup config files machinery" >&2;} - { (exit 1); exit 1; }; } -_ACEOF + { $as_echo "$as_me:$LINENO: result: no" >&5 +$as_echo "no" >&6; } +fi -# VPATH may cause trouble with some makes, so we remove $(srcdir), -# ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and -# trailing colons and then remove the whole line if VPATH becomes empty -# (actually we leave an empty line to preserve line numbers). -if test "x$srcdir" = x.; then - ac_vpsub='/^[ ]*VPATH[ ]*=/{ -s/:*\$(srcdir):*/:/ -s/:*\${srcdir}:*/:/ -s/:*@srcdir@:*/:/ -s/^\([^=]*=[ ]*\):*/\1/ -s/:*$// -s/^[^=]*=[ ]*$// -}' + if test "x$ac_ct_CC" = x; then + CC="" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + CC=$ac_ct_CC + fi +else + CC="$ac_cv_prog_CC" fi -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -fi # test -n "$CONFIG_FILES" +if test -z "$CC"; then + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args. +set dummy ${ac_tool_prefix}cc; 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_prog_CC+set}" = set; then + $as_echo_n "(cached) " >&6 +else + if test -n "$CC"; then + ac_cv_prog_CC="$CC" # Let the user override the test. +else +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_prog_CC="${ac_tool_prefix}cc" + $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done +done +IFS=$as_save_IFS -# Set up the scripts for CONFIG_HEADERS section. -# No need to generate them if there are no CONFIG_HEADERS. -# This happens for instance with `./config.status Makefile'. -if test -n "$CONFIG_HEADERS"; then -cat >"$tmp/defines.awk" <<\_ACAWK || -BEGIN { -_ACEOF +fi +fi +CC=$ac_cv_prog_CC +if test -n "$CC"; then + { $as_echo "$as_me:$LINENO: result: $CC" >&5 +$as_echo "$CC" >&6; } +else + { $as_echo "$as_me:$LINENO: result: no" >&5 +$as_echo "no" >&6; } +fi -# Transform confdefs.h into an awk script `defines.awk', embedded as -# here-document in config.status, that substitutes the proper values into -# config.h.in to produce config.h. -# Create a delimiter string that does not exist in confdefs.h, to ease -# handling of long lines. -ac_delim='%!_!# ' -for ac_last_try in false false :; do - ac_t=`sed -n "/$ac_delim/p" confdefs.h` - if test -z "$ac_t"; then - break - elif $ac_last_try; then - { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_HEADERS" >&5 -$as_echo "$as_me: error: could not make $CONFIG_HEADERS" >&2;} - { (exit 1); exit 1; }; } - else - ac_delim="$ac_delim!$ac_delim _$ac_delim!! " + fi +fi +if test -z "$CC"; then + # Extract the first word of "cc", so it can be a program name with args. +set dummy cc; 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_prog_CC+set}" = set; then + $as_echo_n "(cached) " >&6 +else + if test -n "$CC"; then + ac_cv_prog_CC="$CC" # Let the user override the test. +else + ac_prog_rejected=no +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 + if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then + ac_prog_rejected=yes + continue + fi + ac_cv_prog_CC="cc" + $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 fi done +done +IFS=$as_save_IFS -# For the awk script, D is an array of macro values keyed by name, -# likewise P contains macro parameters if any. Preserve backslash -# newline sequences. - -ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]* -sed -n ' -s/.\{148\}/&'"$ac_delim"'/g -t rset -:rset -s/^[ ]*#[ ]*define[ ][ ]*/ / -t def -d -:def -s/\\$// -t bsnl -s/["\\]/\\&/g -s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ -D["\1"]=" \3"/p -s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p -d -:bsnl -s/["\\]/\\&/g -s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ -D["\1"]=" \3\\\\\\n"\\/p -t cont -s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p -t cont -d -:cont -n -s/.\{148\}/&'"$ac_delim"'/g -t clear -:clear -s/\\$// -t bsnlc -s/["\\]/\\&/g; s/^/"/; s/$/"/p -d -:bsnlc -s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p -b cont -' >$CONFIG_STATUS || ac_write_fail=1 - -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 - for (key in D) D_is_set[key] = 1 - FS = "" -} -/^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ { - line = \$ 0 - split(line, arg, " ") - if (arg[1] == "#") { - defundef = arg[2] - mac1 = arg[3] - } else { - defundef = substr(arg[1], 2) - mac1 = arg[2] - } - split(mac1, mac2, "(") #) - macro = mac2[1] - prefix = substr(line, 1, index(line, defundef) - 1) - if (D_is_set[macro]) { - # Preserve the white space surrounding the "#". - print prefix "define", macro P[macro] D[macro] - next - } else { - # Replace #undef with comments. This is necessary, for example, - # in the case of _POSIX_SOURCE, which is predefined and required - # on some systems where configure will not decide to define it. - if (defundef == "undef") { - print "/*", prefix defundef, macro, "*/" - next - } - } -} -{ print } -_ACAWK -_ACEOF -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 - { { $as_echo "$as_me:$LINENO: error: could not setup config headers machinery" >&5 -$as_echo "$as_me: error: could not setup config headers machinery" >&2;} - { (exit 1); exit 1; }; } -fi # test -n "$CONFIG_HEADERS" +if test $ac_prog_rejected = yes; then + # We found a bogon in the path, so make sure we never use it. + set dummy $ac_cv_prog_CC + shift + if test $# != 0; then + # We chose a different compiler from the bogus one. + # However, it has the same basename, so the bogon will be chosen + # first if we set CC to just the basename; use the full file name. + shift + ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@" + fi +fi +fi +fi +CC=$ac_cv_prog_CC +if test -n "$CC"; then + { $as_echo "$as_me:$LINENO: result: $CC" >&5 +$as_echo "$CC" >&6; } +else + { $as_echo "$as_me:$LINENO: result: no" >&5 +$as_echo "no" >&6; } +fi -eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS" -shift -for ac_tag +fi +if test -z "$CC"; then + if test -n "$ac_tool_prefix"; then + for ac_prog in cl.exe + do + # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. +set dummy $ac_tool_prefix$ac_prog; 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_prog_CC+set}" = set; then + $as_echo_n "(cached) " >&6 +else + if test -n "$CC"; then + ac_cv_prog_CC="$CC" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH do - case $ac_tag in - :[FHLC]) ac_mode=$ac_tag; continue;; - esac - case $ac_mode$ac_tag in - :[FHL]*:*);; - :L* | :C*:*) { { $as_echo "$as_me:$LINENO: error: invalid tag $ac_tag" >&5 -$as_echo "$as_me: error: invalid tag $ac_tag" >&2;} - { (exit 1); exit 1; }; };; - :[FH]-) ac_tag=-:-;; - :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; - esac - ac_save_IFS=$IFS - IFS=: - set x $ac_tag - IFS=$ac_save_IFS - shift - ac_file=$1 - shift - - case $ac_mode in - :L) ac_source=$1;; - :[FH]) - ac_file_inputs= - for ac_f - do - case $ac_f in - -) ac_f="$tmp/stdin";; - *) # Look for the file first in the build tree, then in the source tree - # (if the path is not absolute). The absolute path cannot be DOS-style, - # because $ac_f cannot contain `:'. - test -f "$ac_f" || - case $ac_f in - [\\/$]*) false;; - *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; - esac || - { { $as_echo "$as_me:$LINENO: error: cannot find input file: $ac_f" >&5 -$as_echo "$as_me: error: cannot find input file: $ac_f" >&2;} - { (exit 1); exit 1; }; };; - esac - case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac - ac_file_inputs="$ac_file_inputs '$ac_f'" - done + 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_prog_CC="$ac_tool_prefix$ac_prog" + $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done +done +IFS=$as_save_IFS - # Let's still pretend it is `configure' which instantiates (i.e., don't - # use $as_me), people would be surprised to read: - # /* config.h. Generated by config.status. */ - configure_input='Generated from '` - $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g' - `' by configure.' - if test x"$ac_file" != x-; then - configure_input="$ac_file. $configure_input" - { $as_echo "$as_me:$LINENO: creating $ac_file" >&5 -$as_echo "$as_me: creating $ac_file" >&6;} - fi - # Neutralize special characters interpreted by sed in replacement strings. - case $configure_input in #( - *\&* | *\|* | *\\* ) - ac_sed_conf_input=`$as_echo "$configure_input" | - sed 's/[\\\\&|]/\\\\&/g'`;; #( - *) ac_sed_conf_input=$configure_input;; - esac +fi +fi +CC=$ac_cv_prog_CC +if test -n "$CC"; then + { $as_echo "$as_me:$LINENO: result: $CC" >&5 +$as_echo "$CC" >&6; } +else + { $as_echo "$as_me:$LINENO: result: no" >&5 +$as_echo "no" >&6; } +fi - case $ac_tag in - *:-:* | *:-) cat >"$tmp/stdin" \ - || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5 -$as_echo "$as_me: error: could not create $ac_file" >&2;} - { (exit 1); exit 1; }; } ;; - esac - ;; - esac - ac_dir=`$as_dirname -- "$ac_file" || -$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$ac_file" : 'X\(//\)[^/]' \| \ - X"$ac_file" : 'X\(//\)$' \| \ - X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X"$ac_file" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - { as_dir="$ac_dir" - case $as_dir in #( - -*) as_dir=./$as_dir;; - esac - test -d "$as_dir" || { $as_mkdir_p && mkdir -p "$as_dir"; } || { - as_dirs= - while :; do - case $as_dir in #( - *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( - *) as_qdir=$as_dir;; - esac - as_dirs="'$as_qdir' $as_dirs" - as_dir=`$as_dirname -- "$as_dir" || -$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$as_dir" : 'X\(//\)[^/]' \| \ - X"$as_dir" : 'X\(//\)$' \| \ - X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X"$as_dir" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - test -d "$as_dir" && break - done - test -z "$as_dirs" || eval "mkdir $as_dirs" - } || test -d "$as_dir" || { { $as_echo "$as_me:$LINENO: error: cannot create directory $as_dir" >&5 -$as_echo "$as_me: error: cannot create directory $as_dir" >&2;} - { (exit 1); exit 1; }; }; } - ac_builddir=. + test -n "$CC" && break + done +fi +if test -z "$CC"; then + ac_ct_CC=$CC + for ac_prog in cl.exe +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; 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_prog_ac_ct_CC+set}" = set; then + $as_echo_n "(cached) " >&6 +else + if test -n "$ac_ct_CC"; then + ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. +else +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_prog_ac_ct_CC="$ac_prog" + $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done +done +IFS=$as_save_IFS -case "$ac_dir" in -.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; -*) - ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` - # A ".." for each directory in $ac_dir_suffix. - ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` - case $ac_top_builddir_sub in - "") ac_top_builddir_sub=. ac_top_build_prefix= ;; - *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; - esac ;; -esac -ac_abs_top_builddir=$ac_pwd -ac_abs_builddir=$ac_pwd$ac_dir_suffix -# for backward compatibility: -ac_top_builddir=$ac_top_build_prefix +fi +fi +ac_ct_CC=$ac_cv_prog_ac_ct_CC +if test -n "$ac_ct_CC"; then + { $as_echo "$as_me:$LINENO: result: $ac_ct_CC" >&5 +$as_echo "$ac_ct_CC" >&6; } +else + { $as_echo "$as_me:$LINENO: result: no" >&5 +$as_echo "no" >&6; } +fi -case $srcdir in - .) # We are building in place. - ac_srcdir=. - ac_top_srcdir=$ac_top_builddir_sub - ac_abs_top_srcdir=$ac_pwd ;; - [\\/]* | ?:[\\/]* ) # Absolute name. - ac_srcdir=$srcdir$ac_dir_suffix; - ac_top_srcdir=$srcdir - ac_abs_top_srcdir=$srcdir ;; - *) # Relative name. - ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix - ac_top_srcdir=$ac_top_build_prefix$srcdir - ac_abs_top_srcdir=$ac_pwd/$srcdir ;; + + test -n "$ac_ct_CC" && break +done + + if test "x$ac_ct_CC" = x; then + CC="" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; esac -ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix + CC=$ac_ct_CC + fi +fi +fi - case $ac_mode in - :F) - # - # CONFIG_FILE - # - case $INSTALL in - [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;; - *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;; - esac - ac_MKDIR_P=$MKDIR_P - case $MKDIR_P in - [\\/$]* | ?:[\\/]* ) ;; - */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;; - esac +test -z "$CC" && { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +{ { $as_echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH +See \`config.log' for more details." >&5 +$as_echo "$as_me: error: no acceptable C compiler found in \$PATH +See \`config.log' for more details." >&2;} + { (exit 1); exit 1; }; }; } + +# Provide some information about the compiler. +$as_echo "$as_me:$LINENO: checking for C compiler version" >&5 +set X $ac_compile +ac_compiler=$2 +{ (ac_try="$ac_compiler --version >&5" +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_compiler --version >&5") 2>&5 + ac_status=$? + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } +{ (ac_try="$ac_compiler -v >&5" +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_compiler -v >&5") 2>&5 + ac_status=$? + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } +{ (ac_try="$ac_compiler -V >&5" +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_compiler -V >&5") 2>&5 + ac_status=$? + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } + +{ $as_echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5 +$as_echo_n "checking whether we are using the GNU C compiler... " >&6; } +if test "${ac_cv_c_compiler_gnu+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. */ -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -# If the template does not know about datarootdir, expand it. -# FIXME: This hack should be removed a few years after 2.60. -ac_datarootdir_hack=; ac_datarootdir_seen= +int +main () +{ +#ifndef __GNUC__ + choke me +#endif -ac_sed_dataroot=' -/datarootdir/ { - p - q + ; + return 0; } -/@datadir@/p -/@docdir@/p -/@infodir@/p -/@localedir@/p -/@mandir@/p -' -case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in -*datarootdir*) ac_datarootdir_seen=yes;; -*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) - { $as_echo "$as_me:$LINENO: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 -$as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;} _ACEOF -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 - ac_datarootdir_hack=' - s&@datadir@&$datadir&g - s&@docdir@&$docdir&g - s&@infodir@&$infodir&g - s&@localedir@&$localedir&g - s&@mandir@&$mandir&g - s&\\\${datarootdir}&$datarootdir&g' ;; +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_compiler_gnu=yes +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_compiler_gnu=no +fi + +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +ac_cv_c_compiler_gnu=$ac_compiler_gnu + +fi +{ $as_echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5 +$as_echo "$ac_cv_c_compiler_gnu" >&6; } +if test $ac_compiler_gnu = yes; then + GCC=yes +else + GCC= +fi +ac_test_CFLAGS=${CFLAGS+set} +ac_save_CFLAGS=$CFLAGS +{ $as_echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5 +$as_echo_n "checking whether $CC accepts -g... " >&6; } +if test "${ac_cv_prog_cc_g+set}" = set; then + $as_echo_n "(cached) " >&6 +else + ac_save_c_werror_flag=$ac_c_werror_flag + ac_c_werror_flag=yes + ac_cv_prog_cc_g=no + CFLAGS="-g" + cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ _ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ -# Neutralize VPATH when `$srcdir' = `.'. -# Shell code in configure.ac might set extrasub. -# FIXME: do we really want to maintain this feature? -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -ac_sed_extra="$ac_vpsub -$extrasub +int +main () +{ + + ; + return 0; +} _ACEOF -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -:t -/@[a-zA-Z_][a-zA-Z_0-9]*@/!b -s|@configure_input@|$ac_sed_conf_input|;t t -s&@top_builddir@&$ac_top_builddir_sub&;t t -s&@top_build_prefix@&$ac_top_build_prefix&;t t -s&@srcdir@&$ac_srcdir&;t t -s&@abs_srcdir@&$ac_abs_srcdir&;t t -s&@top_srcdir@&$ac_top_srcdir&;t t -s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t -s&@builddir@&$ac_builddir&;t t -s&@abs_builddir@&$ac_abs_builddir&;t t -s&@abs_top_builddir@&$ac_abs_top_builddir&;t t -s&@INSTALL@&$ac_INSTALL&;t t -s&@MKDIR_P@&$ac_MKDIR_P&;t t -$ac_datarootdir_hack -" -eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$tmp/subs.awk" >$tmp/out \ - || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5 -$as_echo "$as_me: error: could not create $ac_file" >&2;} - { (exit 1); exit 1; }; } +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_g=yes +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 -test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && - { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } && - { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } && - { $as_echo "$as_me:$LINENO: WARNING: $ac_file contains a reference to the variable \`datarootdir' -which seems to be undefined. Please make sure it is defined." >&5 -$as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' -which seems to be undefined. Please make sure it is defined." >&2;} + CFLAGS="" + cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ - rm -f "$tmp/stdin" - case $ac_file in - -) cat "$tmp/out" && rm -f "$tmp/out";; - *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";; - esac \ - || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5 -$as_echo "$as_me: error: could not create $ac_file" >&2;} - { (exit 1); exit 1; }; } - ;; - :H) - # - # CONFIG_HEADER - # - if test x"$ac_file" != x-; then - { - $as_echo "/* $configure_input */" \ - && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" - } >"$tmp/config.h" \ - || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5 -$as_echo "$as_me: error: could not create $ac_file" >&2;} - { (exit 1); exit 1; }; } - if diff "$ac_file" "$tmp/config.h" >/dev/null 2>&1; then - { $as_echo "$as_me:$LINENO: $ac_file is unchanged" >&5 -$as_echo "$as_me: $ac_file is unchanged" >&6;} - else - rm -f "$ac_file" - mv "$tmp/config.h" "$ac_file" \ - || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5 -$as_echo "$as_me: error: could not create $ac_file" >&2;} - { (exit 1); exit 1; }; } - fi - else - $as_echo "/* $configure_input */" \ - && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" \ - || { { $as_echo "$as_me:$LINENO: error: could not create -" >&5 -$as_echo "$as_me: error: could not create -" >&2;} - { (exit 1); exit 1; }; } - fi -# Compute "$ac_file"'s index in $config_headers. -_am_arg="$ac_file" -_am_stamp_count=1 -for _am_header in $config_headers :; do - case $_am_header in - $_am_arg | $_am_arg:* ) - break ;; - * ) - _am_stamp_count=`expr $_am_stamp_count + 1` ;; - esac -done -echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" || -$as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$_am_arg" : 'X\(//\)[^/]' \| \ - X"$_am_arg" : 'X\(//\)$' \| \ - X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X"$_am_arg" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'`/stamp-h$_am_stamp_count - ;; +int +main () +{ - :C) { $as_echo "$as_me:$LINENO: executing $ac_file commands" >&5 -$as_echo "$as_me: executing $ac_file commands" >&6;} - ;; - esac + ; + 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 + : +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + ac_c_werror_flag=$ac_save_c_werror_flag + CFLAGS="-g" + cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ - case $ac_file$ac_mode in - "depfiles":C) test x"$AMDEP_TRUE" != x"" || { - # Autoconf 2.62 quotes --file arguments for eval, but not when files - # are listed without --file. Let's play safe and only enable the eval - # if we detect the quoting. - case $CONFIG_FILES in - *\'*) eval set x "$CONFIG_FILES" ;; - *) set x $CONFIG_FILES ;; - esac - shift - for mf - do - # Strip MF so we end up with the name of the file. - mf=`echo "$mf" | sed -e 's/:.*$//'` - # Check whether this is an Automake generated Makefile or not. - # We used to match only the files named `Makefile.in', but - # some people rename them; so instead we look at the file content. - # Grep'ing the first line is not enough: some people post-process - # each Makefile.in and add a new line on top of each file to say so. - # Grep'ing the whole file is not good either: AIX grep has a line - # limit of 2048, but all sed's we know have understand at least 4000. - if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then - dirpart=`$as_dirname -- "$mf" || -$as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$mf" : 'X\(//\)[^/]' \| \ - X"$mf" : 'X\(//\)$' \| \ - X"$mf" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X"$mf" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - else - continue +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_prog_cc_g=yes +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + +fi + +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi + +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi + +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + ac_c_werror_flag=$ac_save_c_werror_flag +fi +{ $as_echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5 +$as_echo "$ac_cv_prog_cc_g" >&6; } +if test "$ac_test_CFLAGS" = set; then + CFLAGS=$ac_save_CFLAGS +elif test $ac_cv_prog_cc_g = yes; then + if test "$GCC" = yes; then + CFLAGS="-g -O2" + else + CFLAGS="-g" + fi +else + if test "$GCC" = yes; then + CFLAGS="-O2" + else + CFLAGS= + fi +fi +{ $as_echo "$as_me:$LINENO: checking for $CC option to accept ISO C89" >&5 +$as_echo_n "checking for $CC option to accept ISO C89... " >&6; } +if test "${ac_cv_prog_cc_c89+set}" = set; then + $as_echo_n "(cached) " >&6 +else + ac_cv_prog_cc_c89=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 +#include +#include +#include +/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ +struct buf { int x; }; +FILE * (*rcsopen) (struct buf *, struct stat *, int); +static char *e (p, i) + char **p; + int i; +{ + return p[i]; +} +static char *f (char * (*g) (char **, int), char **p, ...) +{ + char *s; + va_list v; + va_start (v,p); + s = g (p, va_arg (v,int)); + va_end (v); + return s; +} + +/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has + function prototypes and stuff, but not '\xHH' hex character constants. + These don't provoke an error unfortunately, instead are silently treated + as 'x'. The following induces an error, until -std is added to get + proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an + array size at least. It's necessary to write '\x00'==0 to get something + that's true only with -std. */ +int osf4_cc_array ['\x00' == 0 ? 1 : -1]; + +/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters + inside strings and character constants. */ +#define FOO(x) 'x' +int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; + +int test (int i, double x); +struct s1 {int (*f) (int a);}; +struct s2 {int (*f) (double a);}; +int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); +int argc; +char **argv; +int +main () +{ +return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; + ; + return 0; +} +_ACEOF +for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ + -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" +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_c89=$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_c89" != "xno" && break +done +rm -f conftest.$ac_ext +CC=$ac_save_CC + +fi +# AC_CACHE_VAL +case "x$ac_cv_prog_cc_c89" 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_c89" + { $as_echo "$as_me:$LINENO: result: $ac_cv_prog_cc_c89" >&5 +$as_echo "$ac_cv_prog_cc_c89" >&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 + +depcc="$CC" am_compiler_list= + +{ $as_echo "$as_me:$LINENO: checking dependency style of $depcc" >&5 +$as_echo_n "checking dependency style of $depcc... " >&6; } +if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then + $as_echo_n "(cached) " >&6 +else + if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then + # We make a subdir and do the tests there. Otherwise we can end up + # making bogus files that we don't know about and never remove. For + # instance it was reported that on HP-UX the gcc test will end up + # making a dummy file named `D' -- because `-MD' means `put the output + # in D'. + mkdir conftest.dir + # Copy depcomp to subdir because otherwise we won't find it if we're + # using a relative directory. + cp "$am_depcomp" conftest.dir + cd conftest.dir + # We will build objects and dependencies in a subdirectory because + # it helps to detect inapplicable dependency modes. For instance + # both Tru64's cc and ICC support -MD to output dependencies as a + # side effect of compilation, but ICC will put the dependencies in + # the current directory while Tru64 will put them in the object + # directory. + mkdir sub + + am_cv_CC_dependencies_compiler_type=none + if test "$am_compiler_list" = ""; then + am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp` + fi + am__universal=false + case " $depcc " in #( + *\ -arch\ *\ -arch\ *) am__universal=true ;; + esac + + for depmode in $am_compiler_list; do + # Setup a source with many dependencies, because some compilers + # like to wrap large dependency lists on column 80 (with \), and + # we should not choose a depcomp mode which is confused by this. + # + # We need to recreate these files for each test, as the compiler may + # overwrite some of them when testing with obscure command lines. + # This happens at least with the AIX C compiler. + : > sub/conftest.c + for i in 1 2 3 4 5 6; do + echo '#include "conftst'$i'.h"' >> sub/conftest.c + # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with + # Solaris 8's {/usr,}/bin/sh. + touch sub/conftst$i.h + done + echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf + + # We check with `-c' and `-o' for the sake of the "dashmstdout" + # mode. It turns out that the SunPro C++ compiler does not properly + # handle `-M -o', and we need to detect this. Also, some Intel + # versions had trouble with output in subdirs + am__obj=sub/conftest.${OBJEXT-o} + am__minus_obj="-o $am__obj" + case $depmode in + gcc) + # This depmode causes a compiler race in universal mode. + test "$am__universal" = false || continue + ;; + nosideeffect) + # after this tag, mechanisms are not by side-effect, so they'll + # only be used when explicitly requested + if test "x$enable_dependency_tracking" = xyes; then + continue + else + break + fi + ;; + msvisualcpp | msvcmsys) + # This compiler won't grok `-c -o', but also, the minuso test has + # not run yet. These depmodes are late enough in the game, and + # so weak that their functioning should not be impacted. + am__obj=conftest.${OBJEXT-o} + am__minus_obj= + ;; + none) break ;; + esac + if depmode=$depmode \ + source=sub/conftest.c object=$am__obj \ + depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ + $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \ + >/dev/null 2>conftest.err && + grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 && + grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && + grep $am__obj sub/conftest.Po > /dev/null 2>&1 && + ${MAKE-make} -s -f confmf > /dev/null 2>&1; then + # icc doesn't choke on unknown options, it will just issue warnings + # or remarks (even with -Werror). So we grep stderr for any message + # that says an option was ignored or not supported. + # When given -MP, icc 7.0 and 7.1 complain thusly: + # icc: Command line warning: ignoring option '-M'; no argument required + # The diagnosis changed in icc 8.0: + # icc: Command line remark: option '-MP' not supported + if (grep 'ignoring option' conftest.err || + grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else + am_cv_CC_dependencies_compiler_type=$depmode + break + fi + fi + done + + cd .. + rm -rf conftest.dir +else + am_cv_CC_dependencies_compiler_type=none +fi + +fi +{ $as_echo "$as_me:$LINENO: result: $am_cv_CC_dependencies_compiler_type" >&5 +$as_echo "$am_cv_CC_dependencies_compiler_type" >&6; } +CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type + + if + test "x$enable_dependency_tracking" != xno \ + && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then + am__fastdepCC_TRUE= + am__fastdepCC_FALSE='#' +else + am__fastdepCC_TRUE='#' + am__fastdepCC_FALSE= +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 +#include +#include +#include +#include + +// 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 "x$ac_cv_have_decl___SUNPRO_C" = x""yes; then + SUNCC="yes" +else + SUNCC="no" +fi + + if test "x$SUNCC" = "xyes"; then + CWARNFLAGS="-v" fi - # Extract the definition of DEPDIR, am__include, and am__quote - # from the Makefile without running `make'. - DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"` - test -z "$DEPDIR" && continue - am__include=`sed -n 's/^am__include = //p' < "$mf"` - test -z "am__include" && continue - am__quote=`sed -n 's/^am__quote = //p' < "$mf"` - # When using ansi2knr, U may be empty or an underscore; expand it - U=`sed -n 's/^U = //p' < "$mf"` - # Find all dependency output files, they are included files with - # $(DEPDIR) in their names. We invoke sed twice because it is the - # simplest approach to changing $(DEPDIR) to its actual value in the - # expansion. - for file in `sed -n " - s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \ - sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do - # Make sure the directory exists. - test -f "$dirpart/$file" && continue - fdir=`$as_dirname -- "$file" || -$as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$file" : 'X\(//\)[^/]' \| \ - X"$file" : 'X\(//\)$' \| \ - X"$file" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X"$file" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - { as_dir=$dirpart/$fdir - case $as_dir in #( - -*) as_dir=./$as_dir;; - esac - test -d "$as_dir" || { $as_mkdir_p && mkdir -p "$as_dir"; } || { - as_dirs= - while :; do - case $as_dir in #( - *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( - *) as_qdir=$as_dir;; +fi + +# Check whether --enable-silent-rules was given. +if test "${enable_silent_rules+set}" = set; then + enableval=$enable_silent_rules; +fi + +case $enable_silent_rules in +yes) AM_DEFAULT_VERBOSITY=0;; +no) AM_DEFAULT_VERBOSITY=1;; +*) AM_DEFAULT_VERBOSITY=0;; +esac +AM_BACKSLASH='\' + + + + + + + +# 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 "x$ac_cv_have_decl___SUNPRO_C" = x""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 "x$ac_cv_have_decl___INTEL_COMPILER" = x""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 + + + + + + + + + + + + + + + + + +if test x"$CC_FOR_BUILD" = x; then + if test x"$cross_compiling" = xyes; then + for ac_prog in gcc cc +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; 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_prog_CC_FOR_BUILD+set}" = set; then + $as_echo_n "(cached) " >&6 +else + if test -n "$CC_FOR_BUILD"; then + ac_cv_prog_CC_FOR_BUILD="$CC_FOR_BUILD" # Let the user override the test. +else +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_prog_CC_FOR_BUILD="$ac_prog" + $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done +done +IFS=$as_save_IFS + +fi +fi +CC_FOR_BUILD=$ac_cv_prog_CC_FOR_BUILD +if test -n "$CC_FOR_BUILD"; then + { $as_echo "$as_me:$LINENO: result: $CC_FOR_BUILD" >&5 +$as_echo "$CC_FOR_BUILD" >&6; } +else + { $as_echo "$as_me:$LINENO: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$CC_FOR_BUILD" && break +done + + else + CC_FOR_BUILD="$CC" + fi +fi + + + + +for ac_prog in cpp +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; 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_RAWCPP+set}" = set; then + $as_echo_n "(cached) " >&6 +else + case $RAWCPP in + [\\/]* | ?:[\\/]*) + ac_cv_path_RAWCPP="$RAWCPP" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +as_dummy="$PATH:/bin:/usr/bin:/usr/lib:/usr/libexec:/usr/ccs/lib:/usr/ccs/lbin:/lib" +for as_dir in $as_dummy +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_RAWCPP="$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 +RAWCPP=$ac_cv_path_RAWCPP +if test -n "$RAWCPP"; then + { $as_echo "$as_me:$LINENO: result: $RAWCPP" >&5 +$as_echo "$RAWCPP" >&6; } +else + { $as_echo "$as_me:$LINENO: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$RAWCPP" && break +done +test -n "$RAWCPP" || RAWCPP="${CPP}" + + +# Check for flag to avoid builtin definitions - assumes unix is predefined, +# which is not the best choice for supporting other OS'es, but covers most +# of the ones we need for now. +{ $as_echo "$as_me:$LINENO: checking if $RAWCPP requires -undef" >&5 +$as_echo_n "checking if $RAWCPP requires -undef... " >&6; } +cat >conftest.$ac_ext <<_ACEOF +Does cpp redefine unix ? +_ACEOF +if test `${RAWCPP} < conftest.$ac_ext | grep -c 'unix'` -eq 1 ; then + { $as_echo "$as_me:$LINENO: result: no" >&5 +$as_echo "no" >&6; } +else + if test `${RAWCPP} -undef < conftest.$ac_ext | grep -c 'unix'` -eq 1 ; then + RAWCPPFLAGS=-undef + { $as_echo "$as_me:$LINENO: result: yes" >&5 +$as_echo "yes" >&6; } + # under Cygwin unix is still defined even with -undef + elif test `${RAWCPP} -undef -ansi < conftest.$ac_ext | grep -c 'unix'` -eq 1 ; then + RAWCPPFLAGS="-undef -ansi" + { $as_echo "$as_me:$LINENO: result: yes, with -ansi" >&5 +$as_echo "yes, with -ansi" >&6; } + else + { { $as_echo "$as_me:$LINENO: error: ${RAWCPP} defines unix with or without -undef. I don't know what to do." >&5 +$as_echo "$as_me: error: ${RAWCPP} defines unix with or without -undef. I don't know what to do." >&2;} + { (exit 1); exit 1; }; } + fi +fi +rm -f conftest.$ac_ext + +{ $as_echo "$as_me:$LINENO: checking if $RAWCPP requires -traditional" >&5 +$as_echo_n "checking if $RAWCPP requires -traditional... " >&6; } +cat >conftest.$ac_ext <<_ACEOF +Does cpp preserve "whitespace"? +_ACEOF +if test `${RAWCPP} < conftest.$ac_ext | grep -c 'preserve \"'` -eq 1 ; then + { $as_echo "$as_me:$LINENO: result: no" >&5 +$as_echo "no" >&6; } +else + if test `${RAWCPP} -traditional < conftest.$ac_ext | grep -c 'preserve \"'` -eq 1 ; then + RAWCPPFLAGS="${RAWCPPFLAGS} -traditional" + { $as_echo "$as_me:$LINENO: result: yes" >&5 +$as_echo "yes" >&6; } + else + { { $as_echo "$as_me:$LINENO: error: ${RAWCPP} does not preserve whitespace with or without -traditional. I don't know what to do." >&5 +$as_echo "$as_me: error: ${RAWCPP} does not preserve whitespace with or without -traditional. I don't know what to do." >&2;} + { (exit 1); exit 1; }; } + fi +fi +rm -f conftest.$ac_ext + + + +# Find perl for "make check" tests in nls/localerules.in + +# Check whether --with-perl was given. +if test "${with_perl+set}" = set; then + withval=$with_perl; PERL=$withval ; { $as_echo "$as_me:$LINENO: checking perl" >&5 +$as_echo_n "checking perl... " >&6; } ; + { $as_echo "$as_me:$LINENO: result: (from --with-perl) $PERL" >&5 +$as_echo "(from --with-perl) $PERL" >&6; } +else + for ac_prog in perl +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; 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_prog_PERL+set}" = set; then + $as_echo_n "(cached) " >&6 +else + if test -n "$PERL"; then + ac_cv_prog_PERL="$PERL" # Let the user override the test. +else +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_prog_PERL="$ac_prog" + $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done +done +IFS=$as_save_IFS + +fi +fi +PERL=$ac_cv_prog_PERL +if test -n "$PERL"; then + { $as_echo "$as_me:$LINENO: result: $PERL" >&5 +$as_echo "$PERL" >&6; } +else + { $as_echo "$as_me:$LINENO: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$PERL" && break +done +test -n "$PERL" || PERL="no" + +fi + + if test x$PERL != xno; then + HAVE_PERL_TRUE= + HAVE_PERL_FALSE='#' +else + HAVE_PERL_TRUE='#' + HAVE_PERL_FALSE= +fi + + +# Build with XCB support? + +# Check whether --with-xcb was given. +if test "${with_xcb+set}" = set; then + withval=$with_xcb; ac_cv_use_xcb=$withval +else + ac_cv_use_xcb=yes +fi + +{ $as_echo "$as_me:$LINENO: checking whether to use XCB" >&5 +$as_echo_n "checking whether to use XCB... " >&6; } +if test "${ac_cv_use_xcb+set}" = set; then + $as_echo_n "(cached) " >&6 +else + ac_cv_use_xcb=yes +fi +{ $as_echo "$as_me:$LINENO: result: $ac_cv_use_xcb" >&5 +$as_echo "$ac_cv_use_xcb" >&6; } + if test x$ac_cv_use_xcb != xno; then + XCB_TRUE= + XCB_FALSE='#' +else + XCB_TRUE='#' + XCB_FALSE= +fi + + +# Checks for pkg-config packages + + +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: using cross tools not prefixed with host triplet" >&5 +$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&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 XPROTO" >&5 +$as_echo_n "checking for XPROTO... " >&6; } + +if test -n "$XPROTO_CFLAGS"; then + pkg_cv_XPROTO_CFLAGS="$XPROTO_CFLAGS" + elif test -n "$PKG_CONFIG"; then + if test -n "$PKG_CONFIG" && \ + { ($as_echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \"xproto >= 7.0.13\"") >&5 + ($PKG_CONFIG --exists --print-errors "xproto >= 7.0.13") 2>&5 + ac_status=$? + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; then + pkg_cv_XPROTO_CFLAGS=`$PKG_CONFIG --cflags "xproto >= 7.0.13" 2>/dev/null` +else + pkg_failed=yes +fi + else + pkg_failed=untried +fi +if test -n "$XPROTO_LIBS"; then + pkg_cv_XPROTO_LIBS="$XPROTO_LIBS" + elif test -n "$PKG_CONFIG"; then + if test -n "$PKG_CONFIG" && \ + { ($as_echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \"xproto >= 7.0.13\"") >&5 + ($PKG_CONFIG --exists --print-errors "xproto >= 7.0.13") 2>&5 + ac_status=$? + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; then + pkg_cv_XPROTO_LIBS=`$PKG_CONFIG --libs "xproto >= 7.0.13" 2>/dev/null` +else + pkg_failed=yes +fi + else + pkg_failed=untried +fi + + + +if test $pkg_failed = yes; then + +if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then + _pkg_short_errors_supported=yes +else + _pkg_short_errors_supported=no +fi + if test $_pkg_short_errors_supported = yes; then + XPROTO_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "xproto >= 7.0.13" 2>&1` + else + XPROTO_PKG_ERRORS=`$PKG_CONFIG --print-errors "xproto >= 7.0.13" 2>&1` + fi + # Put the nasty error message in config.log where it belongs + echo "$XPROTO_PKG_ERRORS" >&5 + + { { $as_echo "$as_me:$LINENO: error: Package requirements (xproto >= 7.0.13) were not met: + +$XPROTO_PKG_ERRORS + +Consider adjusting the PKG_CONFIG_PATH environment variable if you +installed software in a non-standard prefix. + +Alternatively, you may set the environment variables XPROTO_CFLAGS +and XPROTO_LIBS to avoid the need to call pkg-config. +See the pkg-config man page for more details. +" >&5 +$as_echo "$as_me: error: Package requirements (xproto >= 7.0.13) were not met: + +$XPROTO_PKG_ERRORS + +Consider adjusting the PKG_CONFIG_PATH environment variable if you +installed software in a non-standard prefix. + +Alternatively, you may set the environment variables XPROTO_CFLAGS +and XPROTO_LIBS to avoid the need to call pkg-config. +See the pkg-config man page for more details. +" >&2;} + { (exit 1); exit 1; }; } +elif test $pkg_failed = untried; then + { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +{ { $as_echo "$as_me:$LINENO: error: The pkg-config script could not be found or is too old. Make sure it +is in your PATH or set the PKG_CONFIG environment variable to the full +path to pkg-config. + +Alternatively, you may set the environment variables XPROTO_CFLAGS +and XPROTO_LIBS to avoid the need to call pkg-config. +See the pkg-config man page for more details. + +To get pkg-config, see . +See \`config.log' for more details." >&5 +$as_echo "$as_me: error: The pkg-config script could not be found or is too old. Make sure it +is in your PATH or set the PKG_CONFIG environment variable to the full +path to pkg-config. + +Alternatively, you may set the environment variables XPROTO_CFLAGS +and XPROTO_LIBS to avoid the need to call pkg-config. +See the pkg-config man page for more details. + +To get pkg-config, see . +See \`config.log' for more details." >&2;} + { (exit 1); exit 1; }; }; } +else + XPROTO_CFLAGS=$pkg_cv_XPROTO_CFLAGS + XPROTO_LIBS=$pkg_cv_XPROTO_LIBS + { $as_echo "$as_me:$LINENO: result: yes" >&5 +$as_echo "yes" >&6; } + : +fi + + +case "$ac_cv_use_xcb" in +no) + X11_REQUIRES="xau xcmiscproto bigreqsproto" + X11_EXTRA_DEPS="xau" + +pkg_failed=no +{ $as_echo "$as_me:$LINENO: checking for XDMCP" >&5 +$as_echo_n "checking for XDMCP... " >&6; } + +if test -n "$XDMCP_CFLAGS"; then + pkg_cv_XDMCP_CFLAGS="$XDMCP_CFLAGS" + elif test -n "$PKG_CONFIG"; then + if test -n "$PKG_CONFIG" && \ + { ($as_echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \"xdmcp\"") >&5 + ($PKG_CONFIG --exists --print-errors "xdmcp") 2>&5 + ac_status=$? + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; then + pkg_cv_XDMCP_CFLAGS=`$PKG_CONFIG --cflags "xdmcp" 2>/dev/null` +else + pkg_failed=yes +fi + else + pkg_failed=untried +fi +if test -n "$XDMCP_LIBS"; then + pkg_cv_XDMCP_LIBS="$XDMCP_LIBS" + elif test -n "$PKG_CONFIG"; then + if test -n "$PKG_CONFIG" && \ + { ($as_echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \"xdmcp\"") >&5 + ($PKG_CONFIG --exists --print-errors "xdmcp") 2>&5 + ac_status=$? + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; then + pkg_cv_XDMCP_LIBS=`$PKG_CONFIG --libs "xdmcp" 2>/dev/null` +else + pkg_failed=yes +fi + else + pkg_failed=untried +fi + + + +if test $pkg_failed = yes; then + +if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then + _pkg_short_errors_supported=yes +else + _pkg_short_errors_supported=no +fi + if test $_pkg_short_errors_supported = yes; then + XDMCP_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "xdmcp" 2>&1` + else + XDMCP_PKG_ERRORS=`$PKG_CONFIG --print-errors "xdmcp" 2>&1` + fi + # Put the nasty error message in config.log where it belongs + echo "$XDMCP_PKG_ERRORS" >&5 + + { $as_echo "$as_me:$LINENO: result: no" >&5 +$as_echo "no" >&6; } + { $as_echo "$as_me:$LINENO: result: no" >&5 +$as_echo "no" >&6; } +elif test $pkg_failed = untried; then + { $as_echo "$as_me:$LINENO: result: no" >&5 +$as_echo "no" >&6; } +else + XDMCP_CFLAGS=$pkg_cv_XDMCP_CFLAGS + XDMCP_LIBS=$pkg_cv_XDMCP_LIBS + { $as_echo "$as_me:$LINENO: result: yes" >&5 +$as_echo "yes" >&6; } + { $as_echo "$as_me:$LINENO: checking for XdmcpWrap in -lXdmcp" >&5 +$as_echo_n "checking for XdmcpWrap in -lXdmcp... " >&6; } +if test "${ac_cv_lib_Xdmcp_XdmcpWrap+set}" = set; then + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lXdmcp $XDMCP_LIBS $LIBS" +cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char XdmcpWrap (); +int +main () +{ +return XdmcpWrap (); + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext 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>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_exeext && { + test "$cross_compiling" = yes || + $as_test_x conftest$ac_exeext + }; then + ac_cv_lib_Xdmcp_XdmcpWrap=yes +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_cv_lib_Xdmcp_XdmcpWrap=no +fi + +rm -rf conftest.dSYM +rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_Xdmcp_XdmcpWrap" >&5 +$as_echo "$ac_cv_lib_Xdmcp_XdmcpWrap" >&6; } +if test "x$ac_cv_lib_Xdmcp_XdmcpWrap" = x""yes; then + + { $as_echo "$as_me:$LINENO: checking for XdmcpWrap in -lXdmcp" >&5 +$as_echo_n "checking for XdmcpWrap in -lXdmcp... " >&6; } +if test "${ac_cv_lib_Xdmcp_XdmcpWrap+set}" = set; then + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lXdmcp $XDMCP_LIBS $LIBS" +cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char XdmcpWrap (); +int +main () +{ +return XdmcpWrap (); + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext 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>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_exeext && { + test "$cross_compiling" = yes || + $as_test_x conftest$ac_exeext + }; then + ac_cv_lib_Xdmcp_XdmcpWrap=yes +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_cv_lib_Xdmcp_XdmcpWrap=no +fi + +rm -rf conftest.dSYM +rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_Xdmcp_XdmcpWrap" >&5 +$as_echo "$ac_cv_lib_Xdmcp_XdmcpWrap" >&6; } +if test "x$ac_cv_lib_Xdmcp_XdmcpWrap" = x""yes; then + xdmauth="yes" +else + xdmauth="no" +fi + + X11_EXTRA_DEPS="$X11_EXTRA_DEPS xdmcp" + +else + + XDMCP_CFLAGS= + XDMCP_LIBS= + +fi + +fi + +cat >>confdefs.h <<\_ACEOF +#define USE_XCB 0 +_ACEOF + + ;; +*) + X11_REQUIRES="xcb >= 1.1.92" + X11_EXTRA_DEPS="xcb >= 1.1.92" + xdmauth="no" # XCB handles all auth + +cat >>confdefs.h <<\_ACEOF +#define USE_XCB 1 +_ACEOF + + ;; +esac + + +pkg_failed=no +{ $as_echo "$as_me:$LINENO: checking for X11" >&5 +$as_echo_n "checking for X11... " >&6; } + +if test -n "$X11_CFLAGS"; then + pkg_cv_X11_CFLAGS="$X11_CFLAGS" + elif test -n "$PKG_CONFIG"; then + if test -n "$PKG_CONFIG" && \ + { ($as_echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \"xextproto xtrans \$X11_REQUIRES\"") >&5 + ($PKG_CONFIG --exists --print-errors "xextproto xtrans $X11_REQUIRES") 2>&5 + ac_status=$? + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; then + pkg_cv_X11_CFLAGS=`$PKG_CONFIG --cflags "xextproto xtrans $X11_REQUIRES" 2>/dev/null` +else + pkg_failed=yes +fi + else + pkg_failed=untried +fi +if test -n "$X11_LIBS"; then + pkg_cv_X11_LIBS="$X11_LIBS" + elif test -n "$PKG_CONFIG"; then + if test -n "$PKG_CONFIG" && \ + { ($as_echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \"xextproto xtrans \$X11_REQUIRES\"") >&5 + ($PKG_CONFIG --exists --print-errors "xextproto xtrans $X11_REQUIRES") 2>&5 + ac_status=$? + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; then + pkg_cv_X11_LIBS=`$PKG_CONFIG --libs "xextproto xtrans $X11_REQUIRES" 2>/dev/null` +else + pkg_failed=yes +fi + else + pkg_failed=untried +fi + + + +if test $pkg_failed = yes; then + +if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then + _pkg_short_errors_supported=yes +else + _pkg_short_errors_supported=no +fi + if test $_pkg_short_errors_supported = yes; then + X11_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "xextproto xtrans $X11_REQUIRES" 2>&1` + else + X11_PKG_ERRORS=`$PKG_CONFIG --print-errors "xextproto xtrans $X11_REQUIRES" 2>&1` + fi + # Put the nasty error message in config.log where it belongs + echo "$X11_PKG_ERRORS" >&5 + + { { $as_echo "$as_me:$LINENO: error: Package requirements (xextproto xtrans $X11_REQUIRES) were not met: + +$X11_PKG_ERRORS + +Consider adjusting the PKG_CONFIG_PATH environment variable if you +installed software in a non-standard prefix. + +Alternatively, you may set the environment variables X11_CFLAGS +and X11_LIBS to avoid the need to call pkg-config. +See the pkg-config man page for more details. +" >&5 +$as_echo "$as_me: error: Package requirements (xextproto xtrans $X11_REQUIRES) were not met: + +$X11_PKG_ERRORS + +Consider adjusting the PKG_CONFIG_PATH environment variable if you +installed software in a non-standard prefix. + +Alternatively, you may set the environment variables X11_CFLAGS +and X11_LIBS to avoid the need to call pkg-config. +See the pkg-config man page for more details. +" >&2;} + { (exit 1); exit 1; }; } +elif test $pkg_failed = untried; then + { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +{ { $as_echo "$as_me:$LINENO: error: The pkg-config script could not be found or is too old. Make sure it +is in your PATH or set the PKG_CONFIG environment variable to the full +path to pkg-config. + +Alternatively, you may set the environment variables X11_CFLAGS +and X11_LIBS to avoid the need to call pkg-config. +See the pkg-config man page for more details. + +To get pkg-config, see . +See \`config.log' for more details." >&5 +$as_echo "$as_me: error: The pkg-config script could not be found or is too old. Make sure it +is in your PATH or set the PKG_CONFIG environment variable to the full +path to pkg-config. + +Alternatively, you may set the environment variables X11_CFLAGS +and X11_LIBS to avoid the need to call pkg-config. +See the pkg-config man page for more details. + +To get pkg-config, see . +See \`config.log' for more details." >&2;} + { (exit 1); exit 1; }; }; } +else + X11_CFLAGS=$pkg_cv_X11_CFLAGS + X11_LIBS=$pkg_cv_X11_LIBS + { $as_echo "$as_me:$LINENO: result: yes" >&5 +$as_echo "yes" >&6; } + : +fi + + + +# Transport selection macro from xtrans.m4 +{ $as_echo "$as_me:$LINENO: checking return type of signal handlers" >&5 +$as_echo_n "checking return type of signal handlers... " >&6; } +if test "${ac_cv_type_signal+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 +#include + +int +main () +{ +return *(signal (0, 0)) (0) == 1; + ; + 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_type_signal=int +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_cv_type_signal=void +fi + +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +{ $as_echo "$as_me:$LINENO: result: $ac_cv_type_signal" >&5 +$as_echo "$ac_cv_type_signal" >&6; } + +cat >>confdefs.h <<_ACEOF +#define RETSIGTYPE $ac_cv_type_signal +_ACEOF + + + + + + case $host_os in + mingw*) unixdef="no" ;; + *) unixdef="yes" ;; + esac + # Check whether --enable-unix-transport was given. +if test "${enable_unix_transport+set}" = set; then + enableval=$enable_unix_transport; UNIXCONN=$enableval +else + UNIXCONN=$unixdef +fi + + { $as_echo "$as_me:$LINENO: checking if Xtrans should support UNIX socket connections" >&5 +$as_echo_n "checking if Xtrans should support UNIX socket connections... " >&6; } + if test "$UNIXCONN" = "yes"; then + +cat >>confdefs.h <<\_ACEOF +#define UNIXCONN 1 +_ACEOF + + fi + { $as_echo "$as_me:$LINENO: result: $UNIXCONN" >&5 +$as_echo "$UNIXCONN" >&6; } + # Check whether --enable-tcp-transport was given. +if test "${enable_tcp_transport+set}" = set; then + enableval=$enable_tcp_transport; TCPCONN=$enableval +else + TCPCONN=yes +fi + + { $as_echo "$as_me:$LINENO: checking if Xtrans should support TCP socket connections" >&5 +$as_echo_n "checking if Xtrans should support TCP socket connections... " >&6; } + { $as_echo "$as_me:$LINENO: result: $TCPCONN" >&5 +$as_echo "$TCPCONN" >&6; } + if test "$TCPCONN" = "yes"; then + +cat >>confdefs.h <<\_ACEOF +#define TCPCONN 1 +_ACEOF + + + # SVR4 hides these in libraries other than libc + { $as_echo "$as_me:$LINENO: checking for library containing socket" >&5 +$as_echo_n "checking for library containing socket... " >&6; } +if test "${ac_cv_search_socket+set}" = set; then + $as_echo_n "(cached) " >&6 +else + ac_func_search_save_LIBS=$LIBS +cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char socket (); +int +main () +{ +return socket (); + ; + return 0; +} +_ACEOF +for ac_lib in '' socket; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + rm -f conftest.$ac_objext 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>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_exeext && { + test "$cross_compiling" = yes || + $as_test_x conftest$ac_exeext + }; then + ac_cv_search_socket=$ac_res +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + +fi + +rm -rf conftest.dSYM +rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ + conftest$ac_exeext + if test "${ac_cv_search_socket+set}" = set; then + break +fi +done +if test "${ac_cv_search_socket+set}" = set; then + : +else + ac_cv_search_socket=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:$LINENO: result: $ac_cv_search_socket" >&5 +$as_echo "$ac_cv_search_socket" >&6; } +ac_res=$ac_cv_search_socket +if test "$ac_res" != no; then + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" + +fi + + { $as_echo "$as_me:$LINENO: checking for library containing gethostbyname" >&5 +$as_echo_n "checking for library containing gethostbyname... " >&6; } +if test "${ac_cv_search_gethostbyname+set}" = set; then + $as_echo_n "(cached) " >&6 +else + ac_func_search_save_LIBS=$LIBS +cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char gethostbyname (); +int +main () +{ +return gethostbyname (); + ; + return 0; +} +_ACEOF +for ac_lib in '' nsl; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + rm -f conftest.$ac_objext 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>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_exeext && { + test "$cross_compiling" = yes || + $as_test_x conftest$ac_exeext + }; then + ac_cv_search_gethostbyname=$ac_res +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + +fi + +rm -rf conftest.dSYM +rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ + conftest$ac_exeext + if test "${ac_cv_search_gethostbyname+set}" = set; then + break +fi +done +if test "${ac_cv_search_gethostbyname+set}" = set; then + : +else + ac_cv_search_gethostbyname=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:$LINENO: result: $ac_cv_search_gethostbyname" >&5 +$as_echo "$ac_cv_search_gethostbyname" >&6; } +ac_res=$ac_cv_search_gethostbyname +if test "$ac_res" != no; then + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" + +fi + + if test "$ac_cv_search_socket$ac_cv_search_gethostbyname" = "nono"; then + +{ $as_echo "$as_me:$LINENO: checking for main in -lws2_32" >&5 +$as_echo_n "checking for main in -lws2_32... " >&6; } +if test "${ac_cv_lib_ws2_32_main+set}" = set; then + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lws2_32 $LIBS" +cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ + + +int +main () +{ +return main (); + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext 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>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_exeext && { + test "$cross_compiling" = yes || + $as_test_x conftest$ac_exeext + }; then + ac_cv_lib_ws2_32_main=yes +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_cv_lib_ws2_32_main=no +fi + +rm -rf conftest.dSYM +rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_ws2_32_main" >&5 +$as_echo "$ac_cv_lib_ws2_32_main" >&6; } +if test "x$ac_cv_lib_ws2_32_main" = x""yes; then + cat >>confdefs.h <<_ACEOF +#define HAVE_LIBWS2_32 1 +_ACEOF + + LIBS="-lws2_32 $LIBS" + +fi +ac_cv_lib_ws2_32=ac_cv_lib_ws2_32_main + + fi + + # Needs to come after above checks for libsocket & libnsl for SVR4 systems + # Check whether --enable-ipv6 was given. +if test "${enable_ipv6+set}" = set; then + enableval=$enable_ipv6; IPV6CONN=$enableval +else + { $as_echo "$as_me:$LINENO: checking for getaddrinfo" >&5 +$as_echo_n "checking for getaddrinfo... " >&6; } +if test "${ac_cv_func_getaddrinfo+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. */ +/* Define getaddrinfo to an innocuous variant, in case declares getaddrinfo. + For example, HP-UX 11i declares gettimeofday. */ +#define getaddrinfo innocuous_getaddrinfo + +/* System header to define __stub macros and hopefully few prototypes, + which can conflict with char getaddrinfo (); below. + Prefer to if __STDC__ is defined, since + exists even on freestanding compilers. */ + +#ifdef __STDC__ +# include +#else +# include +#endif + +#undef getaddrinfo + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char getaddrinfo (); +/* The GNU C library defines this for functions which it implements + to always fail with ENOSYS. Some functions are actually named + something starting with __ and the normal name is an alias. */ +#if defined __stub_getaddrinfo || defined __stub___getaddrinfo +choke me +#endif + +int +main () +{ +return getaddrinfo (); + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext 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>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_exeext && { + test "$cross_compiling" = yes || + $as_test_x conftest$ac_exeext + }; then + ac_cv_func_getaddrinfo=yes +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_cv_func_getaddrinfo=no +fi + +rm -rf conftest.dSYM +rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ + conftest$ac_exeext conftest.$ac_ext +fi +{ $as_echo "$as_me:$LINENO: result: $ac_cv_func_getaddrinfo" >&5 +$as_echo "$ac_cv_func_getaddrinfo" >&6; } +if test "x$ac_cv_func_getaddrinfo" = x""yes; then + IPV6CONN=yes +else + IPV6CONN=no +fi + +fi + + { $as_echo "$as_me:$LINENO: checking if IPv6 support should be built" >&5 +$as_echo_n "checking if IPv6 support should be built... " >&6; } + if test "$IPV6CONN" = "yes"; then + +cat >>confdefs.h <<\_ACEOF +#define IPv6 1 +_ACEOF + + fi + { $as_echo "$as_me:$LINENO: result: $IPV6CONN" >&5 +$as_echo "$IPV6CONN" >&6; } + + # 4.3BSD-Reno added a new member to struct sockaddr_in + { $as_echo "$as_me:$LINENO: checking for struct sockaddr_in.sin_len" >&5 +$as_echo_n "checking for struct sockaddr_in.sin_len... " >&6; } +if test "${ac_cv_member_struct_sockaddr_in_sin_len+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 +#include +#include + + +int +main () +{ +static struct sockaddr_in ac_aggr; +if (ac_aggr.sin_len) +return 0; + ; + 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_member_struct_sockaddr_in_sin_len=yes +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ + +#include +#include +#include + + +int +main () +{ +static struct sockaddr_in ac_aggr; +if (sizeof ac_aggr.sin_len) +return 0; + ; + 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_member_struct_sockaddr_in_sin_len=yes +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_cv_member_struct_sockaddr_in_sin_len=no +fi + +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi + +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +{ $as_echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_in_sin_len" >&5 +$as_echo "$ac_cv_member_struct_sockaddr_in_sin_len" >&6; } +if test "x$ac_cv_member_struct_sockaddr_in_sin_len" = x""yes; then + +cat >>confdefs.h <<\_ACEOF +#define BSD44SOCKETS 1 +_ACEOF + +fi + + + # POSIX.1g changed the type of pointer passed to getsockname/getpeername/etc. + { $as_echo "$as_me:$LINENO: checking for socklen_t" >&5 +$as_echo_n "checking for socklen_t... " >&6; } +if test "${ac_cv_type_socklen_t+set}" = set; then + $as_echo_n "(cached) " >&6 +else + ac_cv_type_socklen_t=no +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 + +int +main () +{ +if (sizeof (socklen_t)) + return 0; + ; + 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 + 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 + +int +main () +{ +if (sizeof ((socklen_t))) + return 0; + ; + 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 + : +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_cv_type_socklen_t=yes +fi + +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + +fi + +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +{ $as_echo "$as_me:$LINENO: result: $ac_cv_type_socklen_t" >&5 +$as_echo "$ac_cv_type_socklen_t" >&6; } +if test "x$ac_cv_type_socklen_t" = x""yes; then + +cat >>confdefs.h <<_ACEOF +#define HAVE_SOCKLEN_T 1 +_ACEOF + + +fi + + + + fi + case $host_os in + solaris*|sco*|sysv4*) localdef="yes" ;; + *) localdef="no" ;; + esac + # Check whether --enable-local-transport was given. +if test "${enable_local_transport+set}" = set; then + enableval=$enable_local_transport; LOCALCONN=$enableval +else + LOCALCONN=$localdef +fi + + { $as_echo "$as_me:$LINENO: checking if Xtrans should support os-specific local connections" >&5 +$as_echo_n "checking if Xtrans should support os-specific local connections... " >&6; } + { $as_echo "$as_me:$LINENO: result: $LOCALCONN" >&5 +$as_echo "$LOCALCONN" >&6; } + if test "$LOCALCONN" = "yes"; then + +cat >>confdefs.h <<\_ACEOF +#define LOCALCONN 1 +_ACEOF + + fi + + + +# Secure RPC detection macro from xtrans.m4 + + # Check whether --enable-secure-rpc was given. +if test "${enable_secure_rpc+set}" = set; then + enableval=$enable_secure_rpc; SECURE_RPC=$enableval +else + SECURE_RPC="try" +fi + + + if test "x$SECURE_RPC" = "xyes" -o "x$SECURE_RPC" = "xtry" ; then + FOUND_SECURE_RPC="no" + + +for ac_func in authdes_seccreate authdes_create +do +as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` +{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 +$as_echo_n "checking for $ac_func... " >&6; } +if { as_var=$as_ac_var; 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. */ +/* Define $ac_func to an innocuous variant, in case declares $ac_func. + For example, HP-UX 11i declares gettimeofday. */ +#define $ac_func innocuous_$ac_func + +/* System header to define __stub macros and hopefully few prototypes, + which can conflict with char $ac_func (); below. + Prefer to if __STDC__ is defined, since + exists even on freestanding compilers. */ + +#ifdef __STDC__ +# include +#else +# include +#endif + +#undef $ac_func + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char $ac_func (); +/* The GNU C library defines this for functions which it implements + to always fail with ENOSYS. Some functions are actually named + something starting with __ and the normal name is an alias. */ +#if defined __stub_$ac_func || defined __stub___$ac_func +choke me +#endif + +int +main () +{ +return $ac_func (); + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext 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>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_exeext && { + test "$cross_compiling" = yes || + $as_test_x conftest$ac_exeext + }; then + eval "$as_ac_var=yes" +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + eval "$as_ac_var=no" +fi + +rm -rf conftest.dSYM +rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ + conftest$ac_exeext conftest.$ac_ext +fi +ac_res=`eval 'as_val=${'$as_ac_var'} + $as_echo "$as_val"'` + { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 +$as_echo "$ac_res" >&6; } +as_val=`eval 'as_val=${'$as_ac_var'} + $as_echo "$as_val"'` + if test "x$as_val" = x""yes; then + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +_ACEOF + FOUND_SECURE_RPC="yes" +fi +done + + if test "x$FOUND_SECURE_RPC" = "xno" ; then + if test "x$SECURE_RPC" = "xyes" ; then + { { $as_echo "$as_me:$LINENO: error: Secure RPC requested, but required functions not found" >&5 +$as_echo "$as_me: error: Secure RPC requested, but required functions not found" >&2;} + { (exit 1); exit 1; }; } + fi + SECURE_RPC="no" + else + { $as_echo "$as_me:$LINENO: checking for library containing getsecretkey" >&5 +$as_echo_n "checking for library containing getsecretkey... " >&6; } +if test "${ac_cv_search_getsecretkey+set}" = set; then + $as_echo_n "(cached) " >&6 +else + ac_func_search_save_LIBS=$LIBS +cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char getsecretkey (); +int +main () +{ +return getsecretkey (); + ; + return 0; +} +_ACEOF +for ac_lib in '' rpcsvc; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + rm -f conftest.$ac_objext 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>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_exeext && { + test "$cross_compiling" = yes || + $as_test_x conftest$ac_exeext + }; then + ac_cv_search_getsecretkey=$ac_res +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + +fi + +rm -rf conftest.dSYM +rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ + conftest$ac_exeext + if test "${ac_cv_search_getsecretkey+set}" = set; then + break +fi +done +if test "${ac_cv_search_getsecretkey+set}" = set; then + : +else + ac_cv_search_getsecretkey=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:$LINENO: result: $ac_cv_search_getsecretkey" >&5 +$as_echo "$ac_cv_search_getsecretkey" >&6; } +ac_res=$ac_cv_search_getsecretkey +if test "$ac_res" != no; then + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" + +fi + + SECURE_RPC="yes" + fi + fi + { $as_echo "$as_me:$LINENO: checking if Secure RPC authentication (\"SUN-DES-1\") should be supported" >&5 +$as_echo_n "checking if Secure RPC authentication (\"SUN-DES-1\") should be supported... " >&6; } + if test "x$SECURE_RPC" = "xyes" ; then + +cat >>confdefs.h <<\_ACEOF +#define SECURE_RPC 1 +_ACEOF + + fi + { $as_echo "$as_me:$LINENO: result: $SECURE_RPC" >&5 +$as_echo "$SECURE_RPC" >&6; } + + +# Preferred order to try transports for local connections +{ $as_echo "$as_me:$LINENO: checking what order to try transports in for local connections" >&5 +$as_echo_n "checking what order to try transports in for local connections... " >&6; } +case $host_os in + solaris*) + # On Solaris 2.6 through 9, named pipes (LOCAL_TRANS) were + # faster than Unix domain sockets, but on Solaris 10 & later, + # Unix domain sockets are faster now. + DEFAULT_LOCAL_TRANS="UNIX_TRANS,LOCAL_TRANS,TCP_TRANS" + ;; + *) + if test "$LOCALCONN" = "yes"; then + DEFAULT_LOCAL_TRANS="LOCAL_TRANS,UNIX_TRANS,TCP_TRANS" + else + DEFAULT_LOCAL_TRANS="UNIX_TRANS,TCP_TRANS" + fi + ;; +esac + + +# Check whether --with-local-transport-order was given. +if test "${with_local_transport_order+set}" = set; then + withval=$with_local_transport_order; LOCAL_TRANSPORT_LIST=$withval +else + LOCAL_TRANSPORT_LIST=$DEFAULT_LOCAL_TRANS +fi + + +cat >>confdefs.h <<_ACEOF +#define LOCAL_TRANSPORT_LIST $LOCAL_TRANSPORT_LIST +_ACEOF + +{ $as_echo "$as_me:$LINENO: result: $LOCAL_TRANSPORT_LIST" >&5 +$as_echo "$LOCAL_TRANSPORT_LIST" >&6; } + +# Check for dlopen +{ $as_echo "$as_me:$LINENO: checking if run-time linking is supported" >&5 +$as_echo_n "checking if run-time linking is supported... " >&6; } +{ $as_echo "$as_me:$LINENO: checking for library containing dlopen" >&5 +$as_echo_n "checking for library containing dlopen... " >&6; } +if test "${ac_cv_search_dlopen+set}" = set; then + $as_echo_n "(cached) " >&6 +else + ac_func_search_save_LIBS=$LIBS +cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char dlopen (); +int +main () +{ +return dlopen (); + ; + return 0; +} +_ACEOF +for ac_lib in '' dl svld; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + rm -f conftest.$ac_objext 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>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_exeext && { + test "$cross_compiling" = yes || + $as_test_x conftest$ac_exeext + }; then + ac_cv_search_dlopen=$ac_res +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + +fi + +rm -rf conftest.dSYM +rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ + conftest$ac_exeext + if test "${ac_cv_search_dlopen+set}" = set; then + break +fi +done +if test "${ac_cv_search_dlopen+set}" = set; then + : +else + ac_cv_search_dlopen=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:$LINENO: result: $ac_cv_search_dlopen" >&5 +$as_echo "$ac_cv_search_dlopen" >&6; } +ac_res=$ac_cv_search_dlopen +if test "$ac_res" != no; then + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" + +fi + +if test "x$ac_cv_search_dlopen" = xno; then + { $as_echo "$as_me:$LINENO: checking for library containing shl_load" >&5 +$as_echo_n "checking for library containing shl_load... " >&6; } +if test "${ac_cv_search_shl_load+set}" = set; then + $as_echo_n "(cached) " >&6 +else + ac_func_search_save_LIBS=$LIBS +cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char shl_load (); +int +main () +{ +return shl_load (); + ; + return 0; +} +_ACEOF +for ac_lib in '' dld; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + rm -f conftest.$ac_objext 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>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_exeext && { + test "$cross_compiling" = yes || + $as_test_x conftest$ac_exeext + }; then + ac_cv_search_shl_load=$ac_res +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + +fi + +rm -rf conftest.dSYM +rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ + conftest$ac_exeext + if test "${ac_cv_search_shl_load+set}" = set; then + break +fi +done +if test "${ac_cv_search_shl_load+set}" = set; then + : +else + ac_cv_search_shl_load=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:$LINENO: result: $ac_cv_search_shl_load" >&5 +$as_echo "$ac_cv_search_shl_load" >&6; } +ac_res=$ac_cv_search_shl_load +if test "$ac_res" != no; then + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" + +fi + + if test "x$ac_cv_search_shl_load" != xno; then + +cat >>confdefs.h <<\_ACEOF +#define HAVE_SHL_LOAD 1 +_ACEOF + + +for ac_header in dl.h +do +as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then + { $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 +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; } +else + # Is the header compilable? +{ $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5 +$as_echo_n "checking $ac_header usability... " >&6; } +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 + ac_header_compiler=yes +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_header_compiler=no +fi + +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +{ $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 +$as_echo "$ac_header_compiler" >&6; } + +# Is the header present? +{ $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5 +$as_echo_n "checking $ac_header presence... " >&6; } +cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ +#include <$ac_header> +_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 + ac_header_preproc=yes +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_header_preproc=no +fi + +rm -f conftest.err conftest.$ac_ext +{ $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 +$as_echo "$ac_header_preproc" >&6; } + +# So? What about this header? +case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in + yes:no: ) + { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5 +$as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;} + { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5 +$as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;} + ac_header_preproc=yes + ;; + no:yes:* ) + { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5 +$as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;} + { $as_echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5 +$as_echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;} + { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5 +$as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;} + { $as_echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5 +$as_echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;} + { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5 +$as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;} + { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5 +$as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;} + ( cat <<\_ASBOX +## ---------------------------------------------------------------------- ## +## Report this to https://bugs.freedesktop.org/enter_bug.cgi?product=xorg ## +## ---------------------------------------------------------------------- ## +_ASBOX + ) | sed "s/^/$as_me: WARNING: /" >&2 + ;; +esac +{ $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 + eval "$as_ac_Header=\$ac_header_preproc" +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; } + +fi +as_val=`eval 'as_val=${'$as_ac_Header'} + $as_echo "$as_val"'` + if test "x$as_val" = x""yes; then + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + +fi + +done + + fi +else + +cat >>confdefs.h <<\_ACEOF +#define HAVE_DLOPEN 1 +_ACEOF + + +for ac_header in dlfcn.h +do +as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then + { $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 +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; } +else + # Is the header compilable? +{ $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5 +$as_echo_n "checking $ac_header usability... " >&6; } +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 + ac_header_compiler=yes +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_header_compiler=no +fi + +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +{ $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 +$as_echo "$ac_header_compiler" >&6; } + +# Is the header present? +{ $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5 +$as_echo_n "checking $ac_header presence... " >&6; } +cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ +#include <$ac_header> +_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 + ac_header_preproc=yes +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_header_preproc=no +fi + +rm -f conftest.err conftest.$ac_ext +{ $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 +$as_echo "$ac_header_preproc" >&6; } + +# So? What about this header? +case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in + yes:no: ) + { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5 +$as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;} + { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5 +$as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;} + ac_header_preproc=yes + ;; + no:yes:* ) + { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5 +$as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;} + { $as_echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5 +$as_echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;} + { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5 +$as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;} + { $as_echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5 +$as_echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;} + { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5 +$as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;} + { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5 +$as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;} + ( cat <<\_ASBOX +## ---------------------------------------------------------------------- ## +## Report this to https://bugs.freedesktop.org/enter_bug.cgi?product=xorg ## +## ---------------------------------------------------------------------- ## +_ASBOX + ) | sed "s/^/$as_me: WARNING: /" >&2 + ;; +esac +{ $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 + eval "$as_ac_Header=\$ac_header_preproc" +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; } + +fi +as_val=`eval 'as_val=${'$as_ac_Header'} + $as_echo "$as_val"'` + if test "x$as_val" = x""yes; then + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + +fi + +done + +fi +if test x$ac_cv_header_dlcfn_h -o x$ac_cv_header_dl_h; then + HAVE_LOADABLE_MODULES=yes +else + HAVE_LOADABLE_MODULES=no +fi +{ $as_echo "$as_me:$LINENO: result: $HAVE_LOADABLE_MODULES" >&5 +$as_echo "$HAVE_LOADABLE_MODULES" >&6; } + +{ $as_echo "$as_me:$LINENO: checking if loadable i18n module support should be enabled" >&5 +$as_echo_n "checking if loadable i18n module support should be enabled... " >&6; } +# Check whether --enable-loadable-i18n was given. +if test "${enable_loadable_i18n+set}" = set; then + enableval=$enable_loadable_i18n; XLIB_LOADABLE_I18N=$enableval +else + XLIB_LOADABLE_I18N="no" +fi + +if test x$XLIB_LOADABLE_I18N = xyes; then + if test x$HAVE_LOADABLE_MODULES = xno; then + { { $as_echo "$as_me:$LINENO: error: Loadable module support is required to enable loadable i18n module support" >&5 +$as_echo "$as_me: error: Loadable module support is required to enable loadable i18n module support" >&2;} + { (exit 1); exit 1; }; } + fi + +cat >>confdefs.h <<\_ACEOF +#define USE_DYNAMIC_LC 1 +_ACEOF + + I18N_MODULE_LIBS='${top_builddir}/src/libX11.la' + +fi +{ $as_echo "$as_me:$LINENO: result: $XLIB_LOADABLE_I18N" >&5 +$as_echo "$XLIB_LOADABLE_I18N" >&6; } + + if test x$XLIB_LOADABLE_I18N = xyes; then + XLIB_LOADABLE_I18N_TRUE= + XLIB_LOADABLE_I18N_FALSE='#' +else + XLIB_LOADABLE_I18N_TRUE='#' + XLIB_LOADABLE_I18N_FALSE= +fi + + +{ $as_echo "$as_me:$LINENO: checking if loadable Xcursor library support should be enabled" >&5 +$as_echo_n "checking if loadable Xcursor library support should be enabled... " >&6; } +# Check whether --enable-loadable-xcursor was given. +if test "${enable_loadable_xcursor+set}" = set; then + enableval=$enable_loadable_xcursor; XLIB_LOADABLE_XCURSOR=$enableval +else + XLIB_LOADABLE_XCURSOR=$HAVE_LOADABLE_MODULES +fi + +if test x$XLIB_LOADABLE_XCURSOR = xyes; then + +cat >>confdefs.h <<\_ACEOF +#define USE_DYNAMIC_XCURSOR 1 +_ACEOF + +fi +{ $as_echo "$as_me:$LINENO: result: $XLIB_LOADABLE_XCURSOR" >&5 +$as_echo "$XLIB_LOADABLE_XCURSOR" >&6; } + +# Checks for header files. +{ $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 +#include +#include +#include + +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 + +_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 + +_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 +#include +#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 + + +for ac_header in sys/select.h +do +as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then + { $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 +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; } +else + # Is the header compilable? +{ $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5 +$as_echo_n "checking $ac_header usability... " >&6; } +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 + ac_header_compiler=yes +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_header_compiler=no +fi + +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +{ $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 +$as_echo "$ac_header_compiler" >&6; } + +# Is the header present? +{ $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5 +$as_echo_n "checking $ac_header presence... " >&6; } +cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ +#include <$ac_header> +_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 + ac_header_preproc=yes +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_header_preproc=no +fi + +rm -f conftest.err conftest.$ac_ext +{ $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 +$as_echo "$ac_header_preproc" >&6; } + +# So? What about this header? +case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in + yes:no: ) + { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5 +$as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;} + { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5 +$as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;} + ac_header_preproc=yes + ;; + no:yes:* ) + { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5 +$as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;} + { $as_echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5 +$as_echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;} + { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5 +$as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;} + { $as_echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5 +$as_echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;} + { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5 +$as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;} + { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5 +$as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;} + ( cat <<\_ASBOX +## ---------------------------------------------------------------------- ## +## Report this to https://bugs.freedesktop.org/enter_bug.cgi?product=xorg ## +## ---------------------------------------------------------------------- ## +_ASBOX + ) | sed "s/^/$as_me: WARNING: /" >&2 + ;; +esac +{ $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 + eval "$as_ac_Header=\$ac_header_preproc" +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; } + +fi +as_val=`eval 'as_val=${'$as_ac_Header'} + $as_echo "$as_val"'` + if test "x$as_val" = x""yes; then + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + +fi + +done + + +# Checks for typedefs, structures, and compiler characteristics. + +# Checks for library functions. + +for ac_func in strtol +do +as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` +{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 +$as_echo_n "checking for $ac_func... " >&6; } +if { as_var=$as_ac_var; 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. */ +/* Define $ac_func to an innocuous variant, in case declares $ac_func. + For example, HP-UX 11i declares gettimeofday. */ +#define $ac_func innocuous_$ac_func + +/* System header to define __stub macros and hopefully few prototypes, + which can conflict with char $ac_func (); below. + Prefer to if __STDC__ is defined, since + exists even on freestanding compilers. */ + +#ifdef __STDC__ +# include +#else +# include +#endif + +#undef $ac_func + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char $ac_func (); +/* The GNU C library defines this for functions which it implements + to always fail with ENOSYS. Some functions are actually named + something starting with __ and the normal name is an alias. */ +#if defined __stub_$ac_func || defined __stub___$ac_func +choke me +#endif + +int +main () +{ +return $ac_func (); + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext 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>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_exeext && { + test "$cross_compiling" = yes || + $as_test_x conftest$ac_exeext + }; then + eval "$as_ac_var=yes" +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + eval "$as_ac_var=no" +fi + +rm -rf conftest.dSYM +rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ + conftest$ac_exeext conftest.$ac_ext +fi +ac_res=`eval 'as_val=${'$as_ac_var'} + $as_echo "$as_val"'` + { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 +$as_echo "$ac_res" >&6; } +as_val=`eval 'as_val=${'$as_ac_var'} + $as_echo "$as_val"'` + if test "x$as_val" = x""yes; then + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +_ACEOF + +fi +done + +# Used in lcFile.c (see also --enable-xlocaledir settings below) +XLOCALEDIR_IS_SAFE="no" +{ $as_echo "$as_me:$LINENO: checking for issetugid" >&5 +$as_echo_n "checking for issetugid... " >&6; } +if test "${ac_cv_func_issetugid+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. */ +/* Define issetugid to an innocuous variant, in case declares issetugid. + For example, HP-UX 11i declares gettimeofday. */ +#define issetugid innocuous_issetugid + +/* System header to define __stub macros and hopefully few prototypes, + which can conflict with char issetugid (); below. + Prefer to if __STDC__ is defined, since + exists even on freestanding compilers. */ + +#ifdef __STDC__ +# include +#else +# include +#endif + +#undef issetugid + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char issetugid (); +/* The GNU C library defines this for functions which it implements + to always fail with ENOSYS. Some functions are actually named + something starting with __ and the normal name is an alias. */ +#if defined __stub_issetugid || defined __stub___issetugid +choke me +#endif + +int +main () +{ +return issetugid (); + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext 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>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_exeext && { + test "$cross_compiling" = yes || + $as_test_x conftest$ac_exeext + }; then + ac_cv_func_issetugid=yes +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_cv_func_issetugid=no +fi + +rm -rf conftest.dSYM +rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ + conftest$ac_exeext conftest.$ac_ext +fi +{ $as_echo "$as_me:$LINENO: result: $ac_cv_func_issetugid" >&5 +$as_echo "$ac_cv_func_issetugid" >&6; } +if test "x$ac_cv_func_issetugid" = x""yes; then + XLOCALEDIR_IS_SAFE="yes" + +cat >>confdefs.h <<\_ACEOF +#define HASSETUGID 1 +_ACEOF + +fi + +{ $as_echo "$as_me:$LINENO: checking for getresuid" >&5 +$as_echo_n "checking for getresuid... " >&6; } +if test "${ac_cv_func_getresuid+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. */ +/* Define getresuid to an innocuous variant, in case declares getresuid. + For example, HP-UX 11i declares gettimeofday. */ +#define getresuid innocuous_getresuid + +/* System header to define __stub macros and hopefully few prototypes, + which can conflict with char getresuid (); below. + Prefer to if __STDC__ is defined, since + exists even on freestanding compilers. */ + +#ifdef __STDC__ +# include +#else +# include +#endif + +#undef getresuid + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char getresuid (); +/* The GNU C library defines this for functions which it implements + to always fail with ENOSYS. Some functions are actually named + something starting with __ and the normal name is an alias. */ +#if defined __stub_getresuid || defined __stub___getresuid +choke me +#endif + +int +main () +{ +return getresuid (); + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext 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>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_exeext && { + test "$cross_compiling" = yes || + $as_test_x conftest$ac_exeext + }; then + ac_cv_func_getresuid=yes +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_cv_func_getresuid=no +fi + +rm -rf conftest.dSYM +rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ + conftest$ac_exeext conftest.$ac_ext +fi +{ $as_echo "$as_me:$LINENO: result: $ac_cv_func_getresuid" >&5 +$as_echo "$ac_cv_func_getresuid" >&6; } +if test "x$ac_cv_func_getresuid" = x""yes; then + XLOCALEDIR_IS_SAFE="yes" + +cat >>confdefs.h <<\_ACEOF +#define HASGETRESUID 1 +_ACEOF + +fi + +# Used in Font.c +{ $as_echo "$as_me:$LINENO: checking for shmat" >&5 +$as_echo_n "checking for shmat... " >&6; } +if test "${ac_cv_func_shmat+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. */ +/* Define shmat to an innocuous variant, in case declares shmat. + For example, HP-UX 11i declares gettimeofday. */ +#define shmat innocuous_shmat + +/* System header to define __stub macros and hopefully few prototypes, + which can conflict with char shmat (); below. + Prefer to if __STDC__ is defined, since + exists even on freestanding compilers. */ + +#ifdef __STDC__ +# include +#else +# include +#endif + +#undef shmat + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char shmat (); +/* The GNU C library defines this for functions which it implements + to always fail with ENOSYS. Some functions are actually named + something starting with __ and the normal name is an alias. */ +#if defined __stub_shmat || defined __stub___shmat +choke me +#endif + +int +main () +{ +return shmat (); + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext 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>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_exeext && { + test "$cross_compiling" = yes || + $as_test_x conftest$ac_exeext + }; then + ac_cv_func_shmat=yes +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_cv_func_shmat=no +fi + +rm -rf conftest.dSYM +rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ + conftest$ac_exeext conftest.$ac_ext +fi +{ $as_echo "$as_me:$LINENO: result: $ac_cv_func_shmat" >&5 +$as_echo "$ac_cv_func_shmat" >&6; } +if test "x$ac_cv_func_shmat" = x""yes; then + +cat >>confdefs.h <<\_ACEOF +#define HAS_SHM 1 +_ACEOF + +fi + + +# Checks for system services + +# arch specific things +WCHAR32="1" +case $target_alias in + *os2*) os2="true" ; WCHAR32="0" ;; + *) ;; +esac + + + if test x$os2 = xtrue; then + OS2_TRUE= + OS2_FALSE='#' +else + OS2_TRUE='#' + OS2_FALSE= +fi + + + +# Check whether --with-launchd was given. +if test "${with_launchd+set}" = set; then + withval=$with_launchd; LAUNCHD=$withval +else + LAUNCHD=auto +fi + +if test "x$LAUNCHD" = xauto; then + unset LAUNCHD + # Extract the first word of "launchd", so it can be a program name with args. +set dummy launchd; 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_prog_LAUNCHD+set}" = set; then + $as_echo_n "(cached) " >&6 +else + if test -n "$LAUNCHD"; then + ac_cv_prog_LAUNCHD="$LAUNCHD" # Let the user override the test. +else +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_prog_LAUNCHD="yes" + $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done +done +IFS=$as_save_IFS + + test -z "$ac_cv_prog_LAUNCHD" && ac_cv_prog_LAUNCHD="no" +fi +fi +LAUNCHD=$ac_cv_prog_LAUNCHD +if test -n "$LAUNCHD"; then + { $as_echo "$as_me:$LINENO: result: $LAUNCHD" >&5 +$as_echo "$LAUNCHD" >&6; } +else + { $as_echo "$as_me:$LINENO: result: no" >&5 +$as_echo "no" >&6; } +fi + + +fi + +if test "x$LAUNCHD" = xyes ; then + +cat >>confdefs.h <<\_ACEOF +#define HAVE_LAUNCHD 1 +_ACEOF + + +cat >>confdefs.h <<\_ACEOF +#define TRANS_REOPEN 1 +_ACEOF + +fi + +# Check whether --enable-xthreads was given. +if test "${enable_xthreads+set}" = set; then + enableval=$enable_xthreads; xthreads=$enableval +else + xthreads=yes +fi + + +{ $as_echo "$as_me:$LINENO: checking for getpwuid_r in -lc" >&5 +$as_echo_n "checking for getpwuid_r in -lc... " >&6; } +if test "${ac_cv_lib_c_getpwuid_r+set}" = set; then + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lc $LIBS" +cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char getpwuid_r (); +int +main () +{ +return getpwuid_r (); + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext 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>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_exeext && { + test "$cross_compiling" = yes || + $as_test_x conftest$ac_exeext + }; then + ac_cv_lib_c_getpwuid_r=yes +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_cv_lib_c_getpwuid_r=no +fi + +rm -rf conftest.dSYM +rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_c_getpwuid_r" >&5 +$as_echo "$ac_cv_lib_c_getpwuid_r" >&6; } +if test "x$ac_cv_lib_c_getpwuid_r" = x""yes; then + mtsafeapi="yes" +else + mtsafeapi="no" +fi + + +case x$xthreads in +xyes) + +cat >>confdefs.h <<\_ACEOF +#define XTHREADS 1 +_ACEOF + + if test x$mtsafeapi = xyes + then + +cat >>confdefs.h <<\_ACEOF +#define XUSE_MTSAFE_API 1 +_ACEOF + + fi + ;; +*) + ;; +esac + +{ $as_echo "$as_me:$LINENO: checking for pthread_self in -lc" >&5 +$as_echo_n "checking for pthread_self in -lc... " >&6; } +if test "${ac_cv_lib_c_pthread_self+set}" = set; then + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lc $LIBS" +cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char pthread_self (); +int +main () +{ +return pthread_self (); + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext 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>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_exeext && { + test "$cross_compiling" = yes || + $as_test_x conftest$ac_exeext + }; then + ac_cv_lib_c_pthread_self=yes +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_cv_lib_c_pthread_self=no +fi + +rm -rf conftest.dSYM +rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_c_pthread_self" >&5 +$as_echo "$ac_cv_lib_c_pthread_self" >&6; } +if test "x$ac_cv_lib_c_pthread_self" = x""yes; then + thrstubs="no" +else + thrstubs="yes" +fi + + if test x$thrstubs = xyes; then + THRSTUBS_TRUE= + THRSTUBS_FALSE='#' +else + THRSTUBS_TRUE='#' + THRSTUBS_FALSE= +fi + + +if test x$xthreads = xyes ; then + case $host_os in + linux*|openbsd*|gnu*|k*bsd*-gnu) + XTHREADLIB=-lpthread ;; + netbsd*) + XTHREAD_CFLAGS="-D_POSIX_THREAD_SAFE_FUNCTIONS" + XTHREADLIB="-lpthread" ;; + freebsd*) + XTHREAD_CFLAGS="-D_THREAD_SAFE" + XTHREADLIB="-pthread" ;; + dragonfly*) + XTHREADLIB="-pthread" ;; + solaris*) + XTHREAD_CFLAGS="-D_REENTRANT -D_POSIX_PTHREAD_SEMANTICS" ;; + esac +fi + + +X11_CFLAGS="$X11_CFLAGS $XTHREAD_CFLAGS" + +case x$xdmauth in +xyes) + XDMCP_CFLAGS="$XDMCP_CFLAGS -DHASXDMAUTH" + ;; +xno) + XDMCP_LIBS="" + ;; +esac + + + +{ $as_echo "$as_me:$LINENO: checking for poll" >&5 +$as_echo_n "checking for poll... " >&6; } +if test "${ac_cv_func_poll+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. */ +/* Define poll to an innocuous variant, in case declares poll. + For example, HP-UX 11i declares gettimeofday. */ +#define poll innocuous_poll + +/* System header to define __stub macros and hopefully few prototypes, + which can conflict with char poll (); below. + Prefer to if __STDC__ is defined, since + exists even on freestanding compilers. */ + +#ifdef __STDC__ +# include +#else +# include +#endif + +#undef poll + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char poll (); +/* The GNU C library defines this for functions which it implements + to always fail with ENOSYS. Some functions are actually named + something starting with __ and the normal name is an alias. */ +#if defined __stub_poll || defined __stub___poll +choke me +#endif + +int +main () +{ +return poll (); + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext 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>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_exeext && { + test "$cross_compiling" = yes || + $as_test_x conftest$ac_exeext + }; then + ac_cv_func_poll=yes +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_cv_func_poll=no +fi + +rm -rf conftest.dSYM +rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ + conftest$ac_exeext conftest.$ac_ext +fi +{ $as_echo "$as_me:$LINENO: result: $ac_cv_func_poll" >&5 +$as_echo "$ac_cv_func_poll" >&6; } +if test "x$ac_cv_func_poll" = x""yes; then + +cat >>confdefs.h <<\_ACEOF +#define USE_POLL 1 +_ACEOF + +fi + + +# +# Find keysymdef.h +# +{ $as_echo "$as_me:$LINENO: checking keysymdef.h" >&5 +$as_echo_n "checking keysymdef.h... " >&6; } +dir=`pkg-config --variable=includedir xproto` +KEYSYMDEF="$dir/X11/keysymdef.h" +if test -f "$KEYSYMDEF"; then + { $as_echo "$as_me:$LINENO: result: $KEYSYMDEF" >&5 +$as_echo "$KEYSYMDEF" >&6; } +else + { { $as_echo "$as_me:$LINENO: error: Cannot find keysymdef.h" >&5 +$as_echo "$as_me: error: Cannot find keysymdef.h" >&2;} + { (exit 1); exit 1; }; } +fi + + + if test xfalse = xtrue; then + UDC_TRUE= + UDC_FALSE='#' +else + UDC_TRUE='#' + UDC_FALSE= +fi + + +# Check whether --enable-xcms was given. +if test "${enable_xcms+set}" = set; then + enableval=$enable_xcms; XCMS=$enableval +else + XCMS=yes +fi + + if test x$XCMS = xyes ; then + XCMS_TRUE= + XCMS_FALSE='#' +else + XCMS_TRUE='#' + XCMS_FALSE= +fi + +if test x"$XCMS" = "xyes"; then + +cat >>confdefs.h <<\_ACEOF +#define XCMS 1 +_ACEOF + +fi + +# Check whether --enable-xlocale was given. +if test "${enable_xlocale+set}" = set; then + enableval=$enable_xlocale; XLOCALE=$enableval +else + XLOCALE=yes +fi + + + if test x$XLOCALE = xyes ; then + XLOCALE_TRUE= + XLOCALE_FALSE='#' +else + XLOCALE_TRUE='#' + XLOCALE_FALSE= +fi + +if test x"$XLOCALE" = "xyes"; then + +cat >>confdefs.h <<\_ACEOF +#define XLOCALE 1 +_ACEOF + +fi + +# This disables XLOCALEDIR. Set it if you're using BuildLoadableXlibI18n, +# don't have either issetugid() or getresuid(), and you need to protect +# clients that are setgid or setuid to an id other than 0. +{ $as_echo "$as_me:$LINENO: checking if XLOCALEDIR support should be enabled" >&5 +$as_echo_n "checking if XLOCALEDIR support should be enabled... " >&6; } +# Check whether --enable-xlocaledir was given. +if test "${enable_xlocaledir+set}" = set; then + enableval=$enable_xlocaledir; ENABLE_XLOCALEDIR=$enableval +else + ENABLE_XLOCALEDIR=$XLOCALEDIR_IS_SAFE +fi + +if test "x$ENABLE_XLOCALEDIR" = "xno"; then + +cat >>confdefs.h <<\_ACEOF +#define NO_XLOCALEDIR 1 +_ACEOF + +fi +{ $as_echo "$as_me:$LINENO: result: $ENABLE_XLOCALEDIR" >&5 +$as_echo "$ENABLE_XLOCALEDIR" >&6; } + +# Check whether --enable-xf86bigfont was given. +if test "${enable_xf86bigfont+set}" = set; then + enableval=$enable_xf86bigfont; XF86BIGFONT=$enableval +else + XF86BIGFONT="yes" +fi + +if test "x$XF86BIGFONT" = "xyes"; then + +pkg_failed=no +{ $as_echo "$as_me:$LINENO: checking for BIGFONT" >&5 +$as_echo_n "checking for BIGFONT... " >&6; } + +if test -n "$BIGFONT_CFLAGS"; then + pkg_cv_BIGFONT_CFLAGS="$BIGFONT_CFLAGS" + elif test -n "$PKG_CONFIG"; then + if test -n "$PKG_CONFIG" && \ + { ($as_echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \"xf86bigfontproto\"") >&5 + ($PKG_CONFIG --exists --print-errors "xf86bigfontproto") 2>&5 + ac_status=$? + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; then + pkg_cv_BIGFONT_CFLAGS=`$PKG_CONFIG --cflags "xf86bigfontproto" 2>/dev/null` +else + pkg_failed=yes +fi + else + pkg_failed=untried +fi +if test -n "$BIGFONT_LIBS"; then + pkg_cv_BIGFONT_LIBS="$BIGFONT_LIBS" + elif test -n "$PKG_CONFIG"; then + if test -n "$PKG_CONFIG" && \ + { ($as_echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \"xf86bigfontproto\"") >&5 + ($PKG_CONFIG --exists --print-errors "xf86bigfontproto") 2>&5 + ac_status=$? + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; then + pkg_cv_BIGFONT_LIBS=`$PKG_CONFIG --libs "xf86bigfontproto" 2>/dev/null` +else + pkg_failed=yes +fi + else + pkg_failed=untried +fi + + + +if test $pkg_failed = yes; then + +if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then + _pkg_short_errors_supported=yes +else + _pkg_short_errors_supported=no +fi + if test $_pkg_short_errors_supported = yes; then + BIGFONT_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "xf86bigfontproto" 2>&1` + else + BIGFONT_PKG_ERRORS=`$PKG_CONFIG --print-errors "xf86bigfontproto" 2>&1` + fi + # Put the nasty error message in config.log where it belongs + echo "$BIGFONT_PKG_ERRORS" >&5 + + { $as_echo "$as_me:$LINENO: result: no" >&5 +$as_echo "no" >&6; } + XF86BIGFONT="no" +elif test $pkg_failed = untried; then + XF86BIGFONT="no" +else + BIGFONT_CFLAGS=$pkg_cv_BIGFONT_CFLAGS + BIGFONT_LIBS=$pkg_cv_BIGFONT_LIBS + { $as_echo "$as_me:$LINENO: result: yes" >&5 +$as_echo "yes" >&6; } + +cat >>confdefs.h <<\_ACEOF +#define XF86BIGFONT 1 +_ACEOF + +fi + + +fi + +# Check whether --enable-xkb was given. +if test "${enable_xkb+set}" = set; then + enableval=$enable_xkb; XKB=$enableval +else + XKB=yes +fi + + +# Check whether --enable-man-pages was given. +if test "${enable_man_pages+set}" = set; then + enableval=$enable_man_pages; LIBMAN=$enableval +else + LIBMAN=yes +fi + + +if test "x$LIBMAN" != "xyes"; then + LIB_MAN_SUFFIX=$LIBMAN +fi + + if test x$LIBMAN '!=' xno ; then + MANPAGES_TRUE= + MANPAGES_FALSE='#' +else + MANPAGES_TRUE='#' + MANPAGES_FALSE= +fi + + + if test x$XKB = xyes ; then + XKB_TRUE= + XKB_FALSE='#' +else + XKB_TRUE='#' + XKB_FALSE= +fi + +if test x"$XKB" = "xyes"; then + XKBPROTO_REQUIRES="kbproto" + +pkg_failed=no +{ $as_echo "$as_me:$LINENO: checking for XKBPROTO" >&5 +$as_echo_n "checking for XKBPROTO... " >&6; } + +if test -n "$XKBPROTO_CFLAGS"; then + pkg_cv_XKBPROTO_CFLAGS="$XKBPROTO_CFLAGS" + elif test -n "$PKG_CONFIG"; then + if test -n "$PKG_CONFIG" && \ + { ($as_echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \"kbproto inputproto\"") >&5 + ($PKG_CONFIG --exists --print-errors "kbproto inputproto") 2>&5 + ac_status=$? + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; then + pkg_cv_XKBPROTO_CFLAGS=`$PKG_CONFIG --cflags "kbproto inputproto" 2>/dev/null` +else + pkg_failed=yes +fi + else + pkg_failed=untried +fi +if test -n "$XKBPROTO_LIBS"; then + pkg_cv_XKBPROTO_LIBS="$XKBPROTO_LIBS" + elif test -n "$PKG_CONFIG"; then + if test -n "$PKG_CONFIG" && \ + { ($as_echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \"kbproto inputproto\"") >&5 + ($PKG_CONFIG --exists --print-errors "kbproto inputproto") 2>&5 + ac_status=$? + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; then + pkg_cv_XKBPROTO_LIBS=`$PKG_CONFIG --libs "kbproto inputproto" 2>/dev/null` +else + pkg_failed=yes +fi + else + pkg_failed=untried +fi + + + +if test $pkg_failed = yes; then + +if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then + _pkg_short_errors_supported=yes +else + _pkg_short_errors_supported=no +fi + if test $_pkg_short_errors_supported = yes; then + XKBPROTO_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "kbproto inputproto" 2>&1` + else + XKBPROTO_PKG_ERRORS=`$PKG_CONFIG --print-errors "kbproto inputproto" 2>&1` + fi + # Put the nasty error message in config.log where it belongs + echo "$XKBPROTO_PKG_ERRORS" >&5 + + { { $as_echo "$as_me:$LINENO: error: Package requirements (kbproto inputproto) were not met: + +$XKBPROTO_PKG_ERRORS + +Consider adjusting the PKG_CONFIG_PATH environment variable if you +installed software in a non-standard prefix. + +Alternatively, you may set the environment variables XKBPROTO_CFLAGS +and XKBPROTO_LIBS to avoid the need to call pkg-config. +See the pkg-config man page for more details. +" >&5 +$as_echo "$as_me: error: Package requirements (kbproto inputproto) were not met: + +$XKBPROTO_PKG_ERRORS + +Consider adjusting the PKG_CONFIG_PATH environment variable if you +installed software in a non-standard prefix. + +Alternatively, you may set the environment variables XKBPROTO_CFLAGS +and XKBPROTO_LIBS to avoid the need to call pkg-config. +See the pkg-config man page for more details. +" >&2;} + { (exit 1); exit 1; }; } +elif test $pkg_failed = untried; then + { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +{ { $as_echo "$as_me:$LINENO: error: The pkg-config script could not be found or is too old. Make sure it +is in your PATH or set the PKG_CONFIG environment variable to the full +path to pkg-config. + +Alternatively, you may set the environment variables XKBPROTO_CFLAGS +and XKBPROTO_LIBS to avoid the need to call pkg-config. +See the pkg-config man page for more details. + +To get pkg-config, see . +See \`config.log' for more details." >&5 +$as_echo "$as_me: error: The pkg-config script could not be found or is too old. Make sure it +is in your PATH or set the PKG_CONFIG environment variable to the full +path to pkg-config. + +Alternatively, you may set the environment variables XKBPROTO_CFLAGS +and XKBPROTO_LIBS to avoid the need to call pkg-config. +See the pkg-config man page for more details. + +To get pkg-config, see . +See \`config.log' for more details." >&2;} + { (exit 1); exit 1; }; }; } +else + XKBPROTO_CFLAGS=$pkg_cv_XKBPROTO_CFLAGS + XKBPROTO_LIBS=$pkg_cv_XKBPROTO_LIBS + { $as_echo "$as_me:$LINENO: result: yes" >&5 +$as_echo "yes" >&6; } + : +fi + +cat >>confdefs.h <<\_ACEOF +#define XKB 1 +_ACEOF + + X11_CFLAGS="$X11_CFLAGS $XKBPROTO_CFLAGS" + X11_LIBS="$X11_LIBS $XKBPROTO_LIBS" +else + XKBPROTO_REQUIRES="" +fi + + + + +for ac_header in stdlib.h unistd.h +do +as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then + { $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 +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; } +else + # Is the header compilable? +{ $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5 +$as_echo_n "checking $ac_header usability... " >&6; } +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 + ac_header_compiler=yes +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_header_compiler=no +fi + +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +{ $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 +$as_echo "$ac_header_compiler" >&6; } + +# Is the header present? +{ $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5 +$as_echo_n "checking $ac_header presence... " >&6; } +cat >conftest.$ac_ext <<_ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h >>conftest.$ac_ext +cat >>conftest.$ac_ext <<_ACEOF +/* end confdefs.h. */ +#include <$ac_header> +_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 + ac_header_preproc=yes +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_header_preproc=no +fi + +rm -f conftest.err conftest.$ac_ext +{ $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 +$as_echo "$ac_header_preproc" >&6; } + +# So? What about this header? +case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in + yes:no: ) + { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5 +$as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;} + { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5 +$as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;} + ac_header_preproc=yes + ;; + no:yes:* ) + { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5 +$as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;} + { $as_echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5 +$as_echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;} + { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5 +$as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;} + { $as_echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5 +$as_echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;} + { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5 +$as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;} + { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5 +$as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;} + ( cat <<\_ASBOX +## ---------------------------------------------------------------------- ## +## Report this to https://bugs.freedesktop.org/enter_bug.cgi?product=xorg ## +## ---------------------------------------------------------------------- ## +_ASBOX + ) | sed "s/^/$as_me: WARNING: /" >&2 + ;; +esac +{ $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 + eval "$as_ac_Header=\$ac_header_preproc" +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; } + +fi +as_val=`eval 'as_val=${'$as_ac_Header'} + $as_echo "$as_val"'` + if test "x$as_val" = x""yes; then + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF + +fi + +done + + +for ac_func in getpagesize +do +as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` +{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 +$as_echo_n "checking for $ac_func... " >&6; } +if { as_var=$as_ac_var; 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. */ +/* Define $ac_func to an innocuous variant, in case declares $ac_func. + For example, HP-UX 11i declares gettimeofday. */ +#define $ac_func innocuous_$ac_func + +/* System header to define __stub macros and hopefully few prototypes, + which can conflict with char $ac_func (); below. + Prefer to if __STDC__ is defined, since + exists even on freestanding compilers. */ + +#ifdef __STDC__ +# include +#else +# include +#endif + +#undef $ac_func + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char $ac_func (); +/* The GNU C library defines this for functions which it implements + to always fail with ENOSYS. Some functions are actually named + something starting with __ and the normal name is an alias. */ +#if defined __stub_$ac_func || defined __stub___$ac_func +choke me +#endif + +int +main () +{ +return $ac_func (); + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext 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>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_exeext && { + test "$cross_compiling" = yes || + $as_test_x conftest$ac_exeext + }; then + eval "$as_ac_var=yes" +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + eval "$as_ac_var=no" +fi + +rm -rf conftest.dSYM +rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ + conftest$ac_exeext conftest.$ac_ext +fi +ac_res=`eval 'as_val=${'$as_ac_var'} + $as_echo "$as_val"'` + { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 +$as_echo "$ac_res" >&6; } +as_val=`eval 'as_val=${'$as_ac_var'} + $as_echo "$as_val"'` + if test "x$as_val" = x""yes; then + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +_ACEOF + +fi +done + +{ $as_echo "$as_me:$LINENO: checking for working mmap" >&5 +$as_echo_n "checking for working mmap... " >&6; } +if test "${ac_cv_func_mmap_fixed_mapped+set}" = set; then + $as_echo_n "(cached) " >&6 +else + if test "$cross_compiling" = yes; then + ac_cv_func_mmap_fixed_mapped=no +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 +/* malloc might have been renamed as rpl_malloc. */ +#undef malloc + +/* Thanks to Mike Haertel and Jim Avera for this test. + Here is a matrix of mmap possibilities: + mmap private not fixed + mmap private fixed at somewhere currently unmapped + mmap private fixed at somewhere already mapped + mmap shared not fixed + mmap shared fixed at somewhere currently unmapped + mmap shared fixed at somewhere already mapped + For private mappings, we should verify that changes cannot be read() + back from the file, nor mmap's back from the file at a different + address. (There have been systems where private was not correctly + implemented like the infamous i386 svr4.0, and systems where the + VM page cache was not coherent with the file system buffer cache + like early versions of FreeBSD and possibly contemporary NetBSD.) + For shared mappings, we should conversely verify that changes get + propagated back to all the places they're supposed to be. + + Grep wants private fixed already mapped. + The main things grep needs to know about mmap are: + * does it exist and is it safe to write into the mmap'd area + * how to use it (BSD variants) */ + +#include +#include + +#if !defined STDC_HEADERS && !defined HAVE_STDLIB_H +char *malloc (); +#endif + +/* This mess was copied from the GNU getpagesize.h. */ +#ifndef HAVE_GETPAGESIZE +/* Assume that all systems that can run configure have sys/param.h. */ +# ifndef HAVE_SYS_PARAM_H +# define HAVE_SYS_PARAM_H 1 +# endif + +# ifdef _SC_PAGESIZE +# define getpagesize() sysconf(_SC_PAGESIZE) +# else /* no _SC_PAGESIZE */ +# ifdef HAVE_SYS_PARAM_H +# include +# ifdef EXEC_PAGESIZE +# define getpagesize() EXEC_PAGESIZE +# else /* no EXEC_PAGESIZE */ +# ifdef NBPG +# define getpagesize() NBPG * CLSIZE +# ifndef CLSIZE +# define CLSIZE 1 +# endif /* no CLSIZE */ +# else /* no NBPG */ +# ifdef NBPC +# define getpagesize() NBPC +# else /* no NBPC */ +# ifdef PAGESIZE +# define getpagesize() PAGESIZE +# endif /* PAGESIZE */ +# endif /* no NBPC */ +# endif /* no NBPG */ +# endif /* no EXEC_PAGESIZE */ +# else /* no HAVE_SYS_PARAM_H */ +# define getpagesize() 8192 /* punt totally */ +# endif /* no HAVE_SYS_PARAM_H */ +# endif /* no _SC_PAGESIZE */ + +#endif /* no HAVE_GETPAGESIZE */ + +int +main () +{ + char *data, *data2, *data3; + int i, pagesize; + int fd; + + pagesize = getpagesize (); + + /* First, make a file with some known garbage in it. */ + data = (char *) malloc (pagesize); + if (!data) + return 1; + for (i = 0; i < pagesize; ++i) + *(data + i) = rand (); + umask (0); + fd = creat ("conftest.mmap", 0600); + if (fd < 0) + return 1; + if (write (fd, data, pagesize) != pagesize) + return 1; + close (fd); + + /* Next, try to mmap the file at a fixed address which already has + something else allocated at it. If we can, also make sure that + we see the same garbage. */ + fd = open ("conftest.mmap", O_RDWR); + if (fd < 0) + return 1; + data2 = (char *) malloc (2 * pagesize); + if (!data2) + return 1; + data2 += (pagesize - ((long int) data2 & (pagesize - 1))) & (pagesize - 1); + if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE, + MAP_PRIVATE | MAP_FIXED, fd, 0L)) + return 1; + for (i = 0; i < pagesize; ++i) + if (*(data + i) != *(data2 + i)) + return 1; + + /* Finally, make sure that changes to the mapped area do not + percolate back to the file as seen by read(). (This is a bug on + some variants of i386 svr4.0.) */ + for (i = 0; i < pagesize; ++i) + *(data2 + i) = *(data2 + i) + 1; + data3 = (char *) malloc (pagesize); + if (!data3) + return 1; + if (read (fd, data3, pagesize) != pagesize) + return 1; + for (i = 0; i < pagesize; ++i) + if (*(data + i) != *(data3 + i)) + return 1; + close (fd); + 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 + ac_cv_func_mmap_fixed_mapped=yes +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_func_mmap_fixed_mapped=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 +{ $as_echo "$as_me:$LINENO: result: $ac_cv_func_mmap_fixed_mapped" >&5 +$as_echo "$ac_cv_func_mmap_fixed_mapped" >&6; } +if test $ac_cv_func_mmap_fixed_mapped = yes; then + +cat >>confdefs.h <<\_ACEOF +#define HAVE_MMAP 1 +_ACEOF + +fi +rm -f conftest.mmap + +composecache_default=$ac_cv_func_mmap_fixed_mapped +{ $as_echo "$as_me:$LINENO: checking for nl_langinfo" >&5 +$as_echo_n "checking for nl_langinfo... " >&6; } +if test "${ac_cv_func_nl_langinfo+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. */ +/* Define nl_langinfo to an innocuous variant, in case declares nl_langinfo. + For example, HP-UX 11i declares gettimeofday. */ +#define nl_langinfo innocuous_nl_langinfo + +/* System header to define __stub macros and hopefully few prototypes, + which can conflict with char nl_langinfo (); below. + Prefer to if __STDC__ is defined, since + exists even on freestanding compilers. */ + +#ifdef __STDC__ +# include +#else +# include +#endif + +#undef nl_langinfo + +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char nl_langinfo (); +/* The GNU C library defines this for functions which it implements + to always fail with ENOSYS. Some functions are actually named + something starting with __ and the normal name is an alias. */ +#if defined __stub_nl_langinfo || defined __stub___nl_langinfo +choke me +#endif + +int +main () +{ +return nl_langinfo (); + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext 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>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_exeext && { + test "$cross_compiling" = yes || + $as_test_x conftest$ac_exeext + }; then + ac_cv_func_nl_langinfo=yes +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_cv_func_nl_langinfo=no +fi + +rm -rf conftest.dSYM +rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ + conftest$ac_exeext conftest.$ac_ext +fi +{ $as_echo "$as_me:$LINENO: result: $ac_cv_func_nl_langinfo" >&5 +$as_echo "$ac_cv_func_nl_langinfo" >&6; } +if test "x$ac_cv_func_nl_langinfo" = x""yes; then + : +else + composecache_default=no +fi + +# Check whether --enable-composecache was given. +if test "${enable_composecache+set}" = set; then + enableval=$enable_composecache; COMPOSECACHE=$enableval +else + COMPOSECACHE=$composecache_default +fi + +if test x"$COMPOSECACHE" = "xyes"; then + +cat >>confdefs.h <<\_ACEOF +#define COMPOSECACHE 1 +_ACEOF + +fi + + + +# Allow checking code with lint, sparse, etc. + +# Check whether --with-lint was given. +if test "${with_lint+set}" = set; then + withval=$with_lint; use_lint=$withval +else + use_lint=no +fi + +if test "x$use_lint" = "xyes" ; then + LINT="lint" +else + LINT="$use_lint" +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 +fi + + + + if test x$LINT != xno; then + LINT_TRUE= + LINT_FALSE='#' +else + LINT_TRUE='#' + LINT_FALSE= +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 +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 +$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-lX11.ln + else + LINTLIB=$make_lint_lib + fi +fi + + if test x$make_lint_lib != xno; then + MAKE_LINT_LIB_TRUE= + MAKE_LINT_LIB_FALSE='#' +else + MAKE_LINT_LIB_TRUE='#' + MAKE_LINT_LIB_FALSE= +fi + + + +LINT_FLAGS="${LINT_FLAGS} ${X11_CFLAGS} ${XPROTO_CFLAGS}" + +if test "x$GCC" = "xyes"; then + GCC_WARNINGS="-Wall -Wpointer-arith -Wstrict-prototypes \ + -Wmissing-prototypes -Wmissing-declarations \ + -Wnested-externs -fno-strict-aliasing" + X11_CFLAGS="$GCC_WARNINGS $X11_CFLAGS" +fi + +X11_DATADIR="${datadir}/X11" + + prefix_NONE= + exec_prefix_NONE= + test "x$prefix" = xNONE && prefix_NONE=yes && prefix=$ac_default_prefix + test "x$exec_prefix" = xNONE && exec_prefix_NONE=yes && exec_prefix=$prefix + eval ac_define_dir="\"$X11_DATADIR\"" + eval ac_define_dir="\"$ac_define_dir\"" + X11_DATADIR="$ac_define_dir" + + +cat >>confdefs.h <<_ACEOF +#define X11_DATADIR "$ac_define_dir" +_ACEOF + + test "$prefix_NONE" && prefix=NONE + test "$exec_prefix_NONE" && exec_prefix=NONE + + + +X11_LIBDIR="${libdir}/X11" + + prefix_NONE= + exec_prefix_NONE= + test "x$prefix" = xNONE && prefix_NONE=yes && prefix=$ac_default_prefix + test "x$exec_prefix" = xNONE && exec_prefix_NONE=yes && exec_prefix=$prefix + eval ac_define_dir="\"$X11_LIBDIR\"" + eval ac_define_dir="\"$ac_define_dir\"" + X11_LIBDIR="$ac_define_dir" + + +cat >>confdefs.h <<_ACEOF +#define X11_LIBDIR "$ac_define_dir" +_ACEOF + + test "$prefix_NONE" && prefix=NONE + test "$exec_prefix_NONE" && exec_prefix=NONE + + + +X11_CFLAGS="$CWARNFLAGS $X11_CFLAGS $XPROTO_CFLAGS" + + + +# +# Yes, it would be nice to put the locale data in +# /usr/share, but the locale stuff includes loadable +# libraries which must be located in the same directory +# as the other locale data, so for now, everything lives +# in ${libdir} +# + +X11_LOCALEDATADIR="${X11_DATADIR}/locale" + + prefix_NONE= + exec_prefix_NONE= + test "x$prefix" = xNONE && prefix_NONE=yes && prefix=$ac_default_prefix + test "x$exec_prefix" = xNONE && exec_prefix_NONE=yes && exec_prefix=$prefix + eval ac_define_dir="\"$X11_LOCALEDATADIR\"" + eval ac_define_dir="\"$ac_define_dir\"" + XLOCALEDATADIR="$ac_define_dir" + + +cat >>confdefs.h <<_ACEOF +#define XLOCALEDATADIR "$ac_define_dir" +_ACEOF + + test "$prefix_NONE" && prefix=NONE + test "$exec_prefix_NONE" && exec_prefix=NONE + + + + +# Check whether --with-locale-lib-dir was given. +if test "${with_locale_lib_dir+set}" = set; then + withval=$with_locale_lib_dir; X11_LOCALELIBDIR="$withval" +else + X11_LOCALELIBDIR="${X11_LIBDIR}/locale" +fi + + + prefix_NONE= + exec_prefix_NONE= + test "x$prefix" = xNONE && prefix_NONE=yes && prefix=$ac_default_prefix + test "x$exec_prefix" = xNONE && exec_prefix_NONE=yes && exec_prefix=$prefix + eval ac_define_dir="\"$X11_LOCALELIBDIR\"" + eval ac_define_dir="\"$ac_define_dir\"" + XLOCALELIBDIR="$ac_define_dir" + + +cat >>confdefs.h <<_ACEOF +#define XLOCALELIBDIR "$ac_define_dir" +_ACEOF + + test "$prefix_NONE" && prefix=NONE + test "$exec_prefix_NONE" && exec_prefix=NONE + + + +X11_LOCALEDIR="${X11_LOCALEDATADIR}" + + prefix_NONE= + exec_prefix_NONE= + test "x$prefix" = xNONE && prefix_NONE=yes && prefix=$ac_default_prefix + test "x$exec_prefix" = xNONE && exec_prefix_NONE=yes && exec_prefix=$prefix + eval ac_define_dir="\"$X11_LOCALEDIR\"" + eval ac_define_dir="\"$ac_define_dir\"" + XLOCALEDIR="$ac_define_dir" + + +cat >>confdefs.h <<_ACEOF +#define XLOCALEDIR "$ac_define_dir" +_ACEOF + + test "$prefix_NONE" && prefix=NONE + test "$exec_prefix_NONE" && exec_prefix=NONE + + + +XKEYSYMDB="${X11_DATADIR}/XKeysymDB" + + prefix_NONE= + exec_prefix_NONE= + test "x$prefix" = xNONE && prefix_NONE=yes && prefix=$ac_default_prefix + test "x$exec_prefix" = xNONE && exec_prefix_NONE=yes && exec_prefix=$prefix + eval ac_define_dir="\"$XKEYSYMDB\"" + eval ac_define_dir="\"$ac_define_dir\"" + XKEYSYMDB="$ac_define_dir" + + +cat >>confdefs.h <<_ACEOF +#define XKEYSYMDB "$ac_define_dir" +_ACEOF + + test "$prefix_NONE" && prefix=NONE + test "$exec_prefix_NONE" && exec_prefix=NONE + + +XERRORDB="${X11_DATADIR}/XErrorDB" + + prefix_NONE= + exec_prefix_NONE= + test "x$prefix" = xNONE && prefix_NONE=yes && prefix=$ac_default_prefix + test "x$exec_prefix" = xNONE && exec_prefix_NONE=yes && exec_prefix=$prefix + eval ac_define_dir="\"$XERRORDB\"" + eval ac_define_dir="\"$ac_define_dir\"" + XERRORDB="$ac_define_dir" + + +cat >>confdefs.h <<_ACEOF +#define XERRORDB "$ac_define_dir" +_ACEOF + + test "$prefix_NONE" && prefix=NONE + test "$exec_prefix_NONE" && exec_prefix=NONE + + + +# Check whether --enable-malloc0returnsnull was given. +if test "${enable_malloc0returnsnull+set}" = set; then + enableval=$enable_malloc0returnsnull; MALLOC_ZERO_RETURNS_NULL=$enableval +else + MALLOC_ZERO_RETURNS_NULL=auto +fi + + +{ $as_echo "$as_me:$LINENO: checking whether malloc(0) returns NULL" >&5 +$as_echo_n "checking whether malloc(0) returns NULL... " >&6; } +if test "x$MALLOC_ZERO_RETURNS_NULL" = xauto; then + if test "$cross_compiling" = yes; then + { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +{ { $as_echo "$as_me:$LINENO: error: cannot run test program while cross compiling +See \`config.log' for more details." >&5 +$as_echo "$as_me: error: cannot run test program while cross compiling +See \`config.log' for more details." >&2;} + { (exit 1); exit 1; }; }; } +else + cat >conftest.$ac_ext <<_ACEOF + +char *malloc(); +char *realloc(); +char *calloc(); +main() { + char *m0, *r0, *c0, *p; + m0 = malloc(0); + p = malloc(10); + r0 = realloc(p,0); + c0 = calloc(0); + exit(m0 == 0 || r0 == 0 || c0 == 0 ? 0 : 1); +} +_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 + MALLOC_ZERO_RETURNS_NULL=yes +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 ) +MALLOC_ZERO_RETURNS_NULL=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 +{ $as_echo "$as_me:$LINENO: result: $MALLOC_ZERO_RETURNS_NULL" >&5 +$as_echo "$MALLOC_ZERO_RETURNS_NULL" >&6; } + +if test "x$MALLOC_ZERO_RETURNS_NULL" = xyes; then + MALLOC_ZERO_CFLAGS="-DMALLOC_0_RETURNS_NULL" + XMALLOC_ZERO_CFLAGS=$MALLOC_ZERO_CFLAGS + XTMALLOC_ZERO_CFLAGS="$MALLOC_ZERO_CFLAGS -DXTMALLOC_BC" +else + MALLOC_ZERO_CFLAGS="" + XMALLOC_ZERO_CFLAGS="" + XTMALLOC_ZERO_CFLAGS="" +fi + + + + + + +# Specification documents are currently provided in troff format +for ac_prog in groff +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; 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_GROFF+set}" = set; then + $as_echo_n "(cached) " >&6 +else + case $GROFF in + [\\/]* | ?:[\\/]*) + ac_cv_path_GROFF="$GROFF" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +as_dummy="$PATH:/usr/gnu/bin" +for as_dir in $as_dummy +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_GROFF="$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 +GROFF=$ac_cv_path_GROFF +if test -n "$GROFF"; then + { $as_echo "$as_me:$LINENO: result: $GROFF" >&5 +$as_echo "$GROFF" >&6; } +else + { $as_echo "$as_me:$LINENO: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$GROFF" && break +done +test -n "$GROFF" || GROFF="none" + +for ac_prog in ps2pdf +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; 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_PS2PDF+set}" = set; then + $as_echo_n "(cached) " >&6 +else + case $PS2PDF in + [\\/]* | ?:[\\/]*) + ac_cv_path_PS2PDF="$PS2PDF" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +as_dummy="$PATH:/usr/gnu/bin" +for as_dir in $as_dummy +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_PS2PDF="$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 +PS2PDF=$ac_cv_path_PS2PDF +if test -n "$PS2PDF"; then + { $as_echo "$as_me:$LINENO: result: $PS2PDF" >&5 +$as_echo "$PS2PDF" >&6; } +else + { $as_echo "$as_me:$LINENO: result: no" >&5 +$as_echo "no" >&6; } +fi + + + test -n "$PS2PDF" && break +done +test -n "$PS2PDF" || PS2PDF="none" + + +{ $as_echo "$as_me:$LINENO: checking whether to build specifications" >&5 +$as_echo_n "checking whether to build specifications... " >&6; } +# Check whether --enable-specs was given. +if test "${enable_specs+set}" = set; then + enableval=$enable_specs; build_specs="${enableval}" +else + build_specs="auto" +fi + + +if test "x${build_specs}" = xauto; then + if test "x${GROFF}" = xnone ; then + build_specs=no + else + build_specs=yes + fi +fi +{ $as_echo "$as_me:$LINENO: result: ${build_specs}" >&5 +$as_echo "${build_specs}" >&6; } +if test "x${build_specs}" = xyes && test "x${GROFF}" = xnone ; then + { { $as_echo "$as_me:$LINENO: error: can't build documentation without groff" >&5 +$as_echo "$as_me: error: can't build documentation without groff" >&2;} + { (exit 1); exit 1; }; } +fi + + if test x$build_specs = xyes; then + BUILD_SPECS_TRUE= + BUILD_SPECS_FALSE='#' +else + BUILD_SPECS_TRUE='#' + BUILD_SPECS_FALSE= +fi + + if test x$PS2PDF != xnone; then + HAVE_PS2PDF_TRUE= + HAVE_PS2PDF_FALSE='#' +else + HAVE_PS2PDF_TRUE='#' + HAVE_PS2PDF_FALSE= +fi + + + +ac_config_files="$ac_config_files Makefile include/Makefile man/Makefile man/xkb/Makefile src/Makefile src/util/Makefile src/xcms/Makefile src/xlibi18n/Makefile modules/Makefile modules/im/Makefile modules/im/ximcp/Makefile modules/lc/Makefile modules/lc/def/Makefile modules/lc/gen/Makefile modules/lc/Utf8/Makefile modules/lc/xlocale/Makefile modules/om/Makefile modules/om/generic/Makefile src/xkb/Makefile nls/Makefile nls/am_ET.UTF-8/Makefile nls/armscii-8/Makefile nls/C/Makefile nls/el_GR.UTF-8/Makefile nls/en_US.UTF-8/Makefile nls/fi_FI.UTF-8/Makefile nls/georgian-academy/Makefile nls/georgian-ps/Makefile nls/ibm-cp1133/Makefile nls/iscii-dev/Makefile nls/isiri-3342/Makefile nls/iso8859-1/Makefile nls/iso8859-10/Makefile nls/iso8859-11/Makefile nls/iso8859-13/Makefile nls/iso8859-14/Makefile nls/iso8859-15/Makefile nls/iso8859-2/Makefile nls/iso8859-3/Makefile nls/iso8859-4/Makefile nls/iso8859-5/Makefile nls/iso8859-6/Makefile nls/iso8859-7/Makefile nls/iso8859-8/Makefile nls/iso8859-9/Makefile nls/iso8859-9e/Makefile nls/ja/Makefile nls/ja.JIS/Makefile nls/ja_JP.UTF-8/Makefile nls/ja.S90/Makefile nls/ja.SJIS/Makefile nls/ja.U90/Makefile nls/ko/Makefile nls/koi8-c/Makefile nls/koi8-r/Makefile nls/koi8-u/Makefile nls/ko_KR.UTF-8/Makefile nls/microsoft-cp1251/Makefile nls/microsoft-cp1255/Makefile nls/microsoft-cp1256/Makefile nls/mulelao-1/Makefile nls/nokhchi-1/Makefile nls/pt_BR.UTF-8/Makefile nls/ru_RU.UTF-8/Makefile nls/tatar-cyr/Makefile nls/th_TH/Makefile nls/th_TH.UTF-8/Makefile nls/tscii-0/Makefile nls/vi_VN.tcvn/Makefile nls/vi_VN.viscii/Makefile nls/zh_CN/Makefile nls/zh_CN.gb18030/Makefile nls/zh_CN.gbk/Makefile nls/zh_CN.UTF-8/Makefile nls/zh_HK.big5/Makefile nls/zh_HK.big5hkscs/Makefile nls/zh_HK.UTF-8/Makefile nls/zh_TW/Makefile nls/zh_TW.big5/Makefile nls/zh_TW.UTF-8/Makefile specs/Makefile specs/i18n/Makefile specs/libX11/Makefile specs/XIM/Makefile x11.pc x11-xcb.pc" + +cat >confcache <<\_ACEOF +# This file is a shell script that caches the results of configure +# tests run on this system so they can be shared between configure +# scripts and configure runs, see configure's option --config-cache. +# It is not useful on other systems. If it contains results you don't +# want to keep, you may remove or edit it. +# +# config.status only pays attention to the cache file if you give it +# the --recheck option to rerun configure. +# +# `ac_cv_env_foo' variables (set or unset) will be overridden when +# loading this file, other *unset* `ac_cv_foo' will be assigned the +# following values. + +_ACEOF + +# The following way of writing the cache mishandles newlines in values, +# but we know of no workaround that is simple, portable, and efficient. +# So, we kill variables containing newlines. +# Ultrix sh set writes to stderr and can't be redirected directly, +# and sets the high bit in the cache file unless we assign to the vars. +( + for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do + eval ac_val=\$$ac_var + case $ac_val in #( + *${as_nl}*) + case $ac_var in #( + *_cv_*) { $as_echo "$as_me:$LINENO: WARNING: cache variable $ac_var contains a newline" >&5 +$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; esac - as_dirs="'$as_qdir' $as_dirs" - as_dir=`$as_dirname -- "$as_dir" || -$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$as_dir" : 'X\(//\)[^/]' \| \ - X"$as_dir" : 'X\(//\)$' \| \ - X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X"$as_dir" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - test -d "$as_dir" && break - done - test -z "$as_dirs" || eval "mkdir $as_dirs" - } || test -d "$as_dir" || { { $as_echo "$as_me:$LINENO: error: cannot create directory $as_dir" >&5 -$as_echo "$as_me: error: cannot create directory $as_dir" >&2;} - { (exit 1); exit 1; }; }; } - # echo "creating $dirpart/$file" - echo '# dummy' > "$dirpart/$file" - done + case $ac_var in #( + _ | IFS | as_nl) ;; #( + BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( + *) $as_unset $ac_var ;; + esac ;; + esac done -} - ;; - "libtool":C) - # See if we are running on zsh, and set the options which allow our - # commands through without removal of \ escapes. - if test -n "${ZSH_VERSION+set}" ; then - setopt NO_GLOB_SUBST - fi + (set) 2>&1 | + case $as_nl`(ac_space=' '; set) 2>&1` in #( + *${as_nl}ac_space=\ *) + # `set' does not quote correctly, so add quotes (double-quote + # substitution turns \\\\ into \\, and sed turns \\ into \). + sed -n \ + "s/'/'\\\\''/g; + s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" + ;; #( + *) + # `set' quotes correctly as required by POSIX, so do not add quotes. + sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" + ;; + esac | + sort +) | + sed ' + /^ac_cv_env_/b end + t clear + :clear + s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ + t end + s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ + :end' >>confcache +if diff "$cache_file" confcache >/dev/null 2>&1; then :; else + if test -w "$cache_file"; then + test "x$cache_file" != "x/dev/null" && + { $as_echo "$as_me:$LINENO: updating cache $cache_file" >&5 +$as_echo "$as_me: updating cache $cache_file" >&6;} + cat confcache >$cache_file + else + { $as_echo "$as_me:$LINENO: not updating unwritable cache $cache_file" >&5 +$as_echo "$as_me: not updating unwritable cache $cache_file" >&6;} + fi +fi +rm -f confcache + +test "x$prefix" = xNONE && prefix=$ac_default_prefix +# Let make expand exec_prefix. +test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' + +DEFS=-DHAVE_CONFIG_H + +ac_libobjs= +ac_ltlibobjs= +for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue + # 1. Remove the extension, and $U if already installed. + ac_script='s/\$U\././;s/\.o$//;s/\.obj$//' + ac_i=`$as_echo "$ac_i" | sed "$ac_script"` + # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR + # will be set to the directory where LIBOBJS objects are built. + ac_libobjs="$ac_libobjs \${LIBOBJDIR}$ac_i\$U.$ac_objext" + ac_ltlibobjs="$ac_ltlibobjs \${LIBOBJDIR}$ac_i"'$U.lo' +done +LIBOBJS=$ac_libobjs + +LTLIBOBJS=$ac_ltlibobjs - cfgfile="${ofile}T" - trap "$RM \"$cfgfile\"; exit 1" 1 2 15 - $RM "$cfgfile" - cat <<_LT_EOF >> "$cfgfile" + if test -n "$EXEEXT"; then + am__EXEEXT_TRUE= + am__EXEEXT_FALSE='#' +else + am__EXEEXT_TRUE='#' + am__EXEEXT_FALSE= +fi + +if test -z "${MAINTAINER_MODE_TRUE}" && test -z "${MAINTAINER_MODE_FALSE}"; then + { { $as_echo "$as_me:$LINENO: error: conditional \"MAINTAINER_MODE\" was never defined. +Usually this means the macro was only invoked conditionally." >&5 +$as_echo "$as_me: error: conditional \"MAINTAINER_MODE\" was never defined. +Usually this means the macro was only invoked conditionally." >&2;} + { (exit 1); exit 1; }; } +fi +if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then + { { $as_echo "$as_me:$LINENO: error: conditional \"AMDEP\" was never defined. +Usually this means the macro was only invoked conditionally." >&5 +$as_echo "$as_me: error: conditional \"AMDEP\" was never defined. +Usually this means the macro was only invoked conditionally." >&2;} + { (exit 1); exit 1; }; } +fi +if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then + { { $as_echo "$as_me:$LINENO: error: conditional \"am__fastdepCC\" was never defined. +Usually this means the macro was only invoked conditionally." >&5 +$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 "${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 +$as_echo "$as_me: error: conditional \"am__fastdepCXX\" was never defined. +Usually this means the macro was only invoked conditionally." >&2;} + { (exit 1); exit 1; }; } +fi +if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then + { { $as_echo "$as_me:$LINENO: error: conditional \"am__fastdepCC\" was never defined. +Usually this means the macro was only invoked conditionally." >&5 +$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 "${HAVE_PERL_TRUE}" && test -z "${HAVE_PERL_FALSE}"; then + { { $as_echo "$as_me:$LINENO: error: conditional \"HAVE_PERL\" was never defined. +Usually this means the macro was only invoked conditionally." >&5 +$as_echo "$as_me: error: conditional \"HAVE_PERL\" was never defined. +Usually this means the macro was only invoked conditionally." >&2;} + { (exit 1); exit 1; }; } +fi +if test -z "${XCB_TRUE}" && test -z "${XCB_FALSE}"; then + { { $as_echo "$as_me:$LINENO: error: conditional \"XCB\" was never defined. +Usually this means the macro was only invoked conditionally." >&5 +$as_echo "$as_me: error: conditional \"XCB\" was never defined. +Usually this means the macro was only invoked conditionally." >&2;} + { (exit 1); exit 1; }; } +fi +if test -z "${XLIB_LOADABLE_I18N_TRUE}" && test -z "${XLIB_LOADABLE_I18N_FALSE}"; then + { { $as_echo "$as_me:$LINENO: error: conditional \"XLIB_LOADABLE_I18N\" was never defined. +Usually this means the macro was only invoked conditionally." >&5 +$as_echo "$as_me: error: conditional \"XLIB_LOADABLE_I18N\" was never defined. +Usually this means the macro was only invoked conditionally." >&2;} + { (exit 1); exit 1; }; } +fi +if test -z "${OS2_TRUE}" && test -z "${OS2_FALSE}"; then + { { $as_echo "$as_me:$LINENO: error: conditional \"OS2\" was never defined. +Usually this means the macro was only invoked conditionally." >&5 +$as_echo "$as_me: error: conditional \"OS2\" was never defined. +Usually this means the macro was only invoked conditionally." >&2;} + { (exit 1); exit 1; }; } +fi +if test -z "${THRSTUBS_TRUE}" && test -z "${THRSTUBS_FALSE}"; then + { { $as_echo "$as_me:$LINENO: error: conditional \"THRSTUBS\" was never defined. +Usually this means the macro was only invoked conditionally." >&5 +$as_echo "$as_me: error: conditional \"THRSTUBS\" was never defined. +Usually this means the macro was only invoked conditionally." >&2;} + { (exit 1); exit 1; }; } +fi +if test -z "${UDC_TRUE}" && test -z "${UDC_FALSE}"; then + { { $as_echo "$as_me:$LINENO: error: conditional \"UDC\" was never defined. +Usually this means the macro was only invoked conditionally." >&5 +$as_echo "$as_me: error: conditional \"UDC\" was never defined. +Usually this means the macro was only invoked conditionally." >&2;} + { (exit 1); exit 1; }; } +fi +if test -z "${XCMS_TRUE}" && test -z "${XCMS_FALSE}"; then + { { $as_echo "$as_me:$LINENO: error: conditional \"XCMS\" was never defined. +Usually this means the macro was only invoked conditionally." >&5 +$as_echo "$as_me: error: conditional \"XCMS\" was never defined. +Usually this means the macro was only invoked conditionally." >&2;} + { (exit 1); exit 1; }; } +fi +if test -z "${XLOCALE_TRUE}" && test -z "${XLOCALE_FALSE}"; then + { { $as_echo "$as_me:$LINENO: error: conditional \"XLOCALE\" was never defined. +Usually this means the macro was only invoked conditionally." >&5 +$as_echo "$as_me: error: conditional \"XLOCALE\" was never defined. +Usually this means the macro was only invoked conditionally." >&2;} + { (exit 1); exit 1; }; } +fi +if test -z "${MANPAGES_TRUE}" && test -z "${MANPAGES_FALSE}"; then + { { $as_echo "$as_me:$LINENO: error: conditional \"MANPAGES\" was never defined. +Usually this means the macro was only invoked conditionally." >&5 +$as_echo "$as_me: error: conditional \"MANPAGES\" was never defined. +Usually this means the macro was only invoked conditionally." >&2;} + { (exit 1); exit 1; }; } +fi +if test -z "${XKB_TRUE}" && test -z "${XKB_FALSE}"; then + { { $as_echo "$as_me:$LINENO: error: conditional \"XKB\" was never defined. +Usually this means the macro was only invoked conditionally." >&5 +$as_echo "$as_me: error: conditional \"XKB\" was never defined. +Usually this means the macro was only invoked conditionally." >&2;} + { (exit 1); exit 1; }; } +fi +if test -z "${LINT_TRUE}" && test -z "${LINT_FALSE}"; then + { { $as_echo "$as_me:$LINENO: error: conditional \"LINT\" was never defined. +Usually this means the macro was only invoked conditionally." >&5 +$as_echo "$as_me: error: conditional \"LINT\" was never defined. +Usually this means the macro was only invoked conditionally." >&2;} + { (exit 1); exit 1; }; } +fi +if test -z "${MAKE_LINT_LIB_TRUE}" && test -z "${MAKE_LINT_LIB_FALSE}"; then + { { $as_echo "$as_me:$LINENO: error: conditional \"MAKE_LINT_LIB\" was never defined. +Usually this means the macro was only invoked conditionally." >&5 +$as_echo "$as_me: error: conditional \"MAKE_LINT_LIB\" was never defined. +Usually this means the macro was only invoked conditionally." >&2;} + { (exit 1); exit 1; }; } +fi +if test -z "${BUILD_SPECS_TRUE}" && test -z "${BUILD_SPECS_FALSE}"; then + { { $as_echo "$as_me:$LINENO: error: conditional \"BUILD_SPECS\" was never defined. +Usually this means the macro was only invoked conditionally." >&5 +$as_echo "$as_me: error: conditional \"BUILD_SPECS\" was never defined. +Usually this means the macro was only invoked conditionally." >&2;} + { (exit 1); exit 1; }; } +fi +if test -z "${HAVE_PS2PDF_TRUE}" && test -z "${HAVE_PS2PDF_FALSE}"; then + { { $as_echo "$as_me:$LINENO: error: conditional \"HAVE_PS2PDF\" was never defined. +Usually this means the macro was only invoked conditionally." >&5 +$as_echo "$as_me: error: conditional \"HAVE_PS2PDF\" was never defined. +Usually this means the macro was only invoked conditionally." >&2;} + { (exit 1); exit 1; }; } +fi + +: ${CONFIG_STATUS=./config.status} +ac_write_fail=0 +ac_clean_files_save=$ac_clean_files +ac_clean_files="$ac_clean_files $CONFIG_STATUS" +{ $as_echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5 +$as_echo "$as_me: creating $CONFIG_STATUS" >&6;} +cat >$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 #! $SHELL +# Generated by $as_me. +# Run this file to recreate the current configuration. +# Compiler output produced by configure, useful for debugging +# configure, is in config.log if it exists. -# `$ECHO "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services. -# Generated automatically by $as_me ($PACKAGE$TIMESTAMP) $VERSION -# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: -# NOTE: Changes made to this file will be lost: look at ltmain.sh. -# -# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, -# 2006, 2007, 2008 Free Software Foundation, Inc. -# Written by Gordon Matzigkeit, 1996 -# -# This file is part of GNU Libtool. -# -# GNU Libtool is free software; you can redistribute it and/or -# modify it under the terms of the GNU General Public License as -# published by the Free Software Foundation; either version 2 of -# the License, or (at your option) any later version. -# -# As a special exception to the GNU General Public License, -# if you distribute this file as part of a program or library that -# is built using GNU Libtool, you may include this file under the -# same distribution terms that you use for the rest of that program. -# -# GNU Libtool is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with GNU Libtool; see the file COPYING. If not, a copy -# can be downloaded from http://www.gnu.org/licenses/gpl.html, or -# obtained by writing to the Free Software Foundation, Inc., -# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. - - -# The names of the tagged configurations supported by this script. -available_tags="" - -# ### BEGIN LIBTOOL CONFIG - -# Which release of libtool.m4 was used? -macro_version=$macro_version -macro_revision=$macro_revision - -# Whether or not to build shared libraries. -build_libtool_libs=$enable_shared - -# Whether or not to build static libraries. -build_old_libs=$enable_static - -# What type of objects to build. -pic_mode=$pic_mode - -# Whether or not to optimize for fast installation. -fast_install=$enable_fast_install - -# The host system. -host_alias=$host_alias -host=$host -host_os=$host_os - -# The build system. -build_alias=$build_alias -build=$build -build_os=$build_os - -# A sed program that does not truncate output. -SED=$lt_SED - -# Sed that helps us avoid accidentally triggering echo(1) options like -n. -Xsed="\$SED -e 1s/^X//" - -# A grep program that handles long lines. -GREP=$lt_GREP - -# An ERE matcher. -EGREP=$lt_EGREP - -# A literal string matcher. -FGREP=$lt_FGREP - -# A BSD- or MS-compatible name lister. -NM=$lt_NM - -# Whether we need soft or hard links. -LN_S=$lt_LN_S - -# What is the maximum length of a command? -max_cmd_len=$max_cmd_len - -# Object file suffix (normally "o"). -objext=$ac_objext +debug=false +ac_cs_recheck=false +ac_cs_silent=false +SHELL=\${CONFIG_SHELL-$SHELL} +_ACEOF -# Executable file suffix (normally ""). -exeext=$exeext +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +## --------------------- ## +## M4sh Initialization. ## +## --------------------- ## -# whether the shell understands "unset". -lt_unset=$lt_unset +# Be more Bourne compatible +DUALCASE=1; export DUALCASE # for MKS sh +if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then + emulate sh + NULLCMD=: + # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which + # is contrary to our usage. Disable this feature. + alias -g '${1+"$@"}'='"$@"' + setopt NO_GLOB_SUBST +else + case `(set -o) 2>/dev/null` in + *posix*) set -o posix ;; +esac -# turn spaces into newlines. -SP2NL=$lt_lt_SP2NL +fi -# turn newlines into spaces. -NL2SP=$lt_lt_NL2SP -# How to create reloadable object files. -reload_flag=$lt_reload_flag -reload_cmds=$lt_reload_cmds -# An object symbol dumper. -OBJDUMP=$lt_OBJDUMP -# Method to check whether dependent libraries are shared objects. -deplibs_check_method=$lt_deplibs_check_method +# PATH needs CR +# Avoid depending upon Character Ranges. +as_cr_letters='abcdefghijklmnopqrstuvwxyz' +as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' +as_cr_Letters=$as_cr_letters$as_cr_LETTERS +as_cr_digits='0123456789' +as_cr_alnum=$as_cr_Letters$as_cr_digits -# Command to use when deplibs_check_method == "file_magic". -file_magic_cmd=$lt_file_magic_cmd +as_nl=' +' +export as_nl +# Printing a long string crashes Solaris 7 /usr/bin/printf. +as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' +as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo +as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo +if (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then + as_echo='printf %s\n' + as_echo_n='printf %s' +else + if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then + as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' + as_echo_n='/usr/ucb/echo -n' + else + as_echo_body='eval expr "X$1" : "X\\(.*\\)"' + as_echo_n_body='eval + arg=$1; + case $arg in + *"$as_nl"*) + expr "X$arg" : "X\\(.*\\)$as_nl"; + arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; + esac; + expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" + ' + export as_echo_n_body + as_echo_n='sh -c $as_echo_n_body as_echo' + fi + export as_echo_body + as_echo='sh -c $as_echo_body as_echo' +fi -# The archiver. -AR=$lt_AR -AR_FLAGS=$lt_AR_FLAGS +# The user is always right. +if test "${PATH_SEPARATOR+set}" != set; then + PATH_SEPARATOR=: + (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { + (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || + PATH_SEPARATOR=';' + } +fi -# A symbol stripping program. -STRIP=$lt_STRIP +# Support unset when possible. +if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then + as_unset=unset +else + as_unset=false +fi -# Commands used to install an old-style archive. -RANLIB=$lt_RANLIB -old_postinstall_cmds=$lt_old_postinstall_cmds -old_postuninstall_cmds=$lt_old_postuninstall_cmds -# A C compiler. -LTCC=$lt_CC +# IFS +# We need space, tab and new line, in precisely that order. Quoting is +# there to prevent editors from complaining about space-tab. +# (If _AS_PATH_WALK were called with IFS unset, it would disable word +# splitting by setting IFS to empty value.) +IFS=" "" $as_nl" -# LTCC compiler flags. -LTCFLAGS=$lt_CFLAGS +# Find who we are. Look in the path if we contain no directory separator. +case $0 in + *[\\/]* ) as_myself=$0 ;; + *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break +done +IFS=$as_save_IFS -# Take the output of nm and produce a listing of raw symbols and C names. -global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe + ;; +esac +# We did not find ourselves, most probably we were run as `sh COMMAND' +# in which case we are not to be found in the path. +if test "x$as_myself" = x; then + as_myself=$0 +fi +if test ! -f "$as_myself"; then + $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 + { (exit 1); exit 1; } +fi -# Transform the output of nm in a proper C declaration. -global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl +# Work around bugs in pre-3.0 UWIN ksh. +for as_var in ENV MAIL MAILPATH +do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var +done +PS1='$ ' +PS2='> ' +PS4='+ ' -# Transform the output of nm in a C name address pair. -global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address +# NLS nuisances. +LC_ALL=C +export LC_ALL +LANGUAGE=C +export LANGUAGE -# Transform the output of nm in a C name address pair when lib prefix is needed. -global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix +# Required to use basename. +if expr a : '\(a\)' >/dev/null 2>&1 && + test "X`expr 00001 : '.*\(...\)'`" = X001; then + as_expr=expr +else + as_expr=false +fi -# The name of the directory that contains temporary libtool files. -objdir=$objdir +if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then + as_basename=basename +else + as_basename=false +fi -# Shell to use when invoking shell scripts. -SHELL=$lt_SHELL -# An echo program that does not interpret backslashes. -ECHO=$lt_ECHO +# Name of the executable. +as_me=`$as_basename -- "$0" || +$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ + X"$0" : 'X\(//\)$' \| \ + X"$0" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X/"$0" | + sed '/^.*\/\([^/][^/]*\)\/*$/{ + s//\1/ + q + } + /^X\/\(\/\/\)$/{ + s//\1/ + q + } + /^X\/\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q'` -# Used to examine libraries when file_magic_cmd begins with "file". -MAGIC_CMD=$MAGIC_CMD +# CDPATH. +$as_unset CDPATH -# Must we lock files when doing compilation? -need_locks=$lt_need_locks -# Tool to manipulate archived DWARF debug symbol files on Mac OS X. -DSYMUTIL=$lt_DSYMUTIL -# Tool to change global to local symbols on Mac OS X. -NMEDIT=$lt_NMEDIT + as_lineno_1=$LINENO + as_lineno_2=$LINENO + test "x$as_lineno_1" != "x$as_lineno_2" && + test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2" || { -# Tool to manipulate fat objects and archives on Mac OS X. -LIPO=$lt_LIPO + # Create $as_me.lineno as a copy of $as_myself, but with $LINENO + # uniformly replaced by the line number. The first 'sed' inserts a + # line-number line after each line using $LINENO; the second 'sed' + # does the real work. The second script uses 'N' to pair each + # line-number line with the line containing $LINENO, and appends + # trailing '-' during substitution so that $LINENO is not a special + # case at line end. + # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the + # scripts with optimization help from Paolo Bonzini. Blame Lee + # E. McMahon (1931-1989) for sed's syntax. :-) + sed -n ' + p + /[$]LINENO/= + ' <$as_myself | + sed ' + s/[$]LINENO.*/&-/ + t lineno + b + :lineno + N + :loop + s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/ + t loop + s/-\n.*// + ' >$as_me.lineno && + chmod +x "$as_me.lineno" || + { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2 + { (exit 1); exit 1; }; } -# ldd/readelf like tool for Mach-O binaries on Mac OS X. -OTOOL=$lt_OTOOL + # Don't try to exec as it changes $[0], causing all sort of problems + # (the dirname of $[0] is not the place where we might find the + # original and so on. Autoconf is especially sensitive to this). + . "./$as_me.lineno" + # Exit status is that of the last command. + exit +} -# ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4. -OTOOL64=$lt_OTOOL64 -# Old archive suffix (normally "a"). -libext=$libext +if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then + as_dirname=dirname +else + as_dirname=false +fi -# Shared library suffix (normally ".so"). -shrext_cmds=$lt_shrext_cmds +ECHO_C= ECHO_N= ECHO_T= +case `echo -n x` in +-n*) + case `echo 'x\c'` in + *c*) ECHO_T=' ';; # ECHO_T is single tab character. + *) ECHO_C='\c';; + esac;; +*) + ECHO_N='-n';; +esac +if expr a : '\(a\)' >/dev/null 2>&1 && + test "X`expr 00001 : '.*\(...\)'`" = X001; then + as_expr=expr +else + as_expr=false +fi -# The commands to extract the exported symbol list from a shared archive. -extract_expsyms_cmds=$lt_extract_expsyms_cmds +rm -f conf$$ conf$$.exe conf$$.file +if test -d conf$$.dir; then + rm -f conf$$.dir/conf$$.file +else + rm -f conf$$.dir + mkdir conf$$.dir 2>/dev/null +fi +if (echo >conf$$.file) 2>/dev/null; then + if ln -s conf$$.file conf$$ 2>/dev/null; then + as_ln_s='ln -s' + # ... but there are two gotchas: + # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. + # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. + # In both cases, we have to default to `cp -p'. + ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || + as_ln_s='cp -p' + elif ln conf$$.file conf$$ 2>/dev/null; then + as_ln_s=ln + else + as_ln_s='cp -p' + fi +else + as_ln_s='cp -p' +fi +rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file +rmdir conf$$.dir 2>/dev/null -# Variables whose values should be saved in libtool wrapper scripts and -# restored at link time. -variables_saved_for_relink=$lt_variables_saved_for_relink +if mkdir -p . 2>/dev/null; then + as_mkdir_p=: +else + test -d ./-p && rmdir ./-p + as_mkdir_p=false +fi -# Do we need the "lib" prefix for modules? -need_lib_prefix=$need_lib_prefix +if test -x / >/dev/null 2>&1; then + as_test_x='test -x' +else + if ls -dL / >/dev/null 2>&1; then + as_ls_L_option=L + else + as_ls_L_option= + fi + as_test_x=' + eval sh -c '\'' + if test -d "$1"; then + test -d "$1/."; + else + case $1 in + -*)set "./$1";; + esac; + case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in + ???[sx]*):;;*)false;;esac;fi + '\'' sh + ' +fi +as_executable_p=$as_test_x -# Do we need a version for libraries? -need_version=$need_version +# Sed expression to map a string onto a valid CPP name. +as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" -# Library versioning type. -version_type=$version_type +# Sed expression to map a string onto a valid variable name. +as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" -# Shared library runtime path variable. -runpath_var=$runpath_var -# Shared library path variable. -shlibpath_var=$shlibpath_var +exec 6>&1 -# Is shlibpath searched before the hard-coded library search path? -shlibpath_overrides_runpath=$shlibpath_overrides_runpath +# Save the log message, to keep $[0] and so on meaningful, and to +# report actual input values of CONFIG_FILES etc. instead of their +# values after options handling. +ac_log=" +This file was extended by libX11 $as_me 1.3.1, which was +generated by GNU Autoconf 2.63. Invocation command line was -# Format of library name prefix. -libname_spec=$lt_libname_spec + CONFIG_FILES = $CONFIG_FILES + CONFIG_HEADERS = $CONFIG_HEADERS + CONFIG_LINKS = $CONFIG_LINKS + CONFIG_COMMANDS = $CONFIG_COMMANDS + $ $0 $@ -# List of archive names. First name is the real one, the rest are links. -# The last name is the one that the linker finds with -lNAME -library_names_spec=$lt_library_names_spec +on `(hostname || uname -n) 2>/dev/null | sed 1q` +" -# The coded name of the library, if different from the real name. -soname_spec=$lt_soname_spec +_ACEOF -# Command to use after installation of a shared archive. -postinstall_cmds=$lt_postinstall_cmds +case $ac_config_files in *" +"*) set x $ac_config_files; shift; ac_config_files=$*;; +esac -# Command to use after uninstallation of a shared archive. -postuninstall_cmds=$lt_postuninstall_cmds +case $ac_config_headers in *" +"*) set x $ac_config_headers; shift; ac_config_headers=$*;; +esac -# Commands used to finish a libtool library installation in a directory. -finish_cmds=$lt_finish_cmds -# As "finish_cmds", except a single script fragment to be evaled but -# not shown. -finish_eval=$lt_finish_eval +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 +# Files that config.status was made for. +config_files="$ac_config_files" +config_headers="$ac_config_headers" +config_commands="$ac_config_commands" -# Whether we should hardcode library paths into libraries. -hardcode_into_libs=$hardcode_into_libs +_ACEOF -# Compile-time system search path for libraries. -sys_lib_search_path_spec=$lt_sys_lib_search_path_spec +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +ac_cs_usage="\ +\`$as_me' instantiates files from templates according to the +current configuration. -# Run-time system search path for libraries. -sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec +Usage: $0 [OPTION]... [FILE]... -# Whether dlopen is supported. -dlopen_support=$enable_dlopen + -h, --help print this help, then exit + -V, --version print version number and configuration settings, then exit + -q, --quiet, --silent + do not print progress messages + -d, --debug don't remove temporary files + --recheck update $as_me by reconfiguring in the same conditions + --file=FILE[:TEMPLATE] + instantiate the configuration file FILE + --header=FILE[:TEMPLATE] + instantiate the configuration header FILE -# Whether dlopen of programs is supported. -dlopen_self=$enable_dlopen_self +Configuration files: +$config_files -# Whether dlopen of statically linked programs is supported. -dlopen_self_static=$enable_dlopen_self_static +Configuration headers: +$config_headers -# Commands to strip libraries. -old_striplib=$lt_old_striplib -striplib=$lt_striplib +Configuration commands: +$config_commands +Report bugs to ." -# The linker used to build libraries. -LD=$lt_LD +_ACEOF +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 +ac_cs_version="\\ +libX11 config.status 1.3.1 +configured by $0, generated by GNU Autoconf 2.63, + with options \\"`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\" -# Commands used to build an old-style archive. -old_archive_cmds=$lt_old_archive_cmds +Copyright (C) 2008 Free Software Foundation, Inc. +This config.status script is free software; the Free Software Foundation +gives unlimited permission to copy, distribute and modify it." -# A language specific compiler. -CC=$lt_compiler +ac_pwd='$ac_pwd' +srcdir='$srcdir' +INSTALL='$INSTALL' +MKDIR_P='$MKDIR_P' +AWK='$AWK' +test -n "\$AWK" || AWK=awk +_ACEOF -# Is the compiler the GNU compiler? -with_gcc=$GCC +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +# The default lists apply if the user does not specify any file. +ac_need_defaults=: +while test $# != 0 +do + case $1 in + --*=*) + ac_option=`expr "X$1" : 'X\([^=]*\)='` + ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` + ac_shift=: + ;; + *) + ac_option=$1 + ac_optarg=$2 + ac_shift=shift + ;; + esac -# Compiler flag to turn off builtin functions. -no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag + case $ac_option in + # Handling of the options. + -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) + ac_cs_recheck=: ;; + --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) + $as_echo "$ac_cs_version"; exit ;; + --debug | --debu | --deb | --de | --d | -d ) + debug=: ;; + --file | --fil | --fi | --f ) + $ac_shift + case $ac_optarg in + *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; + esac + CONFIG_FILES="$CONFIG_FILES '$ac_optarg'" + ac_need_defaults=false;; + --header | --heade | --head | --hea ) + $ac_shift + case $ac_optarg in + *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; + esac + CONFIG_HEADERS="$CONFIG_HEADERS '$ac_optarg'" + ac_need_defaults=false;; + --he | --h) + # Conflict between --help and --header + { $as_echo "$as_me: error: ambiguous option: $1 +Try \`$0 --help' for more information." >&2 + { (exit 1); exit 1; }; };; + --help | --hel | -h ) + $as_echo "$ac_cs_usage"; exit ;; + -q | -quiet | --quiet | --quie | --qui | --qu | --q \ + | -silent | --silent | --silen | --sile | --sil | --si | --s) + ac_cs_silent=: ;; -# How to pass a linker flag through the compiler. -wl=$lt_lt_prog_compiler_wl + # This is an error. + -*) { $as_echo "$as_me: error: unrecognized option: $1 +Try \`$0 --help' for more information." >&2 + { (exit 1); exit 1; }; } ;; -# Additional compiler flags for building library objects. -pic_flag=$lt_lt_prog_compiler_pic + *) ac_config_targets="$ac_config_targets $1" + ac_need_defaults=false ;; -# Compiler flag to prevent dynamic linking. -link_static_flag=$lt_lt_prog_compiler_static + esac + shift +done -# Does compiler simultaneously support -c and -o options? -compiler_c_o=$lt_lt_cv_prog_compiler_c_o +ac_configure_extra_args= -# Whether or not to add -lc for building shared libraries. -build_libtool_need_lc=$archive_cmds_need_lc +if $ac_cs_silent; then + exec 6>/dev/null + ac_configure_extra_args="$ac_configure_extra_args --silent" +fi -# Whether or not to disallow shared libs when runtime libs are static. -allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes +_ACEOF +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 +if \$ac_cs_recheck; then + set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion + shift + \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6 + CONFIG_SHELL='$SHELL' + export CONFIG_SHELL + exec "\$@" +fi -# Compiler flag to allow reflexive dlopens. -export_dynamic_flag_spec=$lt_export_dynamic_flag_spec +_ACEOF +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +exec 5>>config.log +{ + echo + sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX +## Running $as_me. ## +_ASBOX + $as_echo "$ac_log" +} >&5 -# Compiler flag to generate shared objects directly from archives. -whole_archive_flag_spec=$lt_whole_archive_flag_spec +_ACEOF +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 +# +# INIT-COMMANDS +# +AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir" -# Whether the compiler copes with passing no objects directly. -compiler_needs_object=$lt_compiler_needs_object +_ACEOF -# Create an old-style archive from a shared archive. -old_archive_from_new_cmds=$lt_old_archive_from_new_cmds +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 -# Create a temporary old-style archive to link instead of a shared archive. -old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds +# Handling of arguments. +for ac_config_target in $ac_config_targets +do + case $ac_config_target in + "src/config.h") CONFIG_HEADERS="$CONFIG_HEADERS src/config.h" ;; + "include/X11/XlibConf.h") CONFIG_HEADERS="$CONFIG_HEADERS include/X11/XlibConf.h" ;; + "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;; + "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;; + "include/Makefile") CONFIG_FILES="$CONFIG_FILES include/Makefile" ;; + "man/Makefile") CONFIG_FILES="$CONFIG_FILES man/Makefile" ;; + "man/xkb/Makefile") CONFIG_FILES="$CONFIG_FILES man/xkb/Makefile" ;; + "src/Makefile") CONFIG_FILES="$CONFIG_FILES src/Makefile" ;; + "src/util/Makefile") CONFIG_FILES="$CONFIG_FILES src/util/Makefile" ;; + "src/xcms/Makefile") CONFIG_FILES="$CONFIG_FILES src/xcms/Makefile" ;; + "src/xlibi18n/Makefile") CONFIG_FILES="$CONFIG_FILES src/xlibi18n/Makefile" ;; + "modules/Makefile") CONFIG_FILES="$CONFIG_FILES modules/Makefile" ;; + "modules/im/Makefile") CONFIG_FILES="$CONFIG_FILES modules/im/Makefile" ;; + "modules/im/ximcp/Makefile") CONFIG_FILES="$CONFIG_FILES modules/im/ximcp/Makefile" ;; + "modules/lc/Makefile") CONFIG_FILES="$CONFIG_FILES modules/lc/Makefile" ;; + "modules/lc/def/Makefile") CONFIG_FILES="$CONFIG_FILES modules/lc/def/Makefile" ;; + "modules/lc/gen/Makefile") CONFIG_FILES="$CONFIG_FILES modules/lc/gen/Makefile" ;; + "modules/lc/Utf8/Makefile") CONFIG_FILES="$CONFIG_FILES modules/lc/Utf8/Makefile" ;; + "modules/lc/xlocale/Makefile") CONFIG_FILES="$CONFIG_FILES modules/lc/xlocale/Makefile" ;; + "modules/om/Makefile") CONFIG_FILES="$CONFIG_FILES modules/om/Makefile" ;; + "modules/om/generic/Makefile") CONFIG_FILES="$CONFIG_FILES modules/om/generic/Makefile" ;; + "src/xkb/Makefile") CONFIG_FILES="$CONFIG_FILES src/xkb/Makefile" ;; + "nls/Makefile") CONFIG_FILES="$CONFIG_FILES nls/Makefile" ;; + "nls/am_ET.UTF-8/Makefile") CONFIG_FILES="$CONFIG_FILES nls/am_ET.UTF-8/Makefile" ;; + "nls/armscii-8/Makefile") CONFIG_FILES="$CONFIG_FILES nls/armscii-8/Makefile" ;; + "nls/C/Makefile") CONFIG_FILES="$CONFIG_FILES nls/C/Makefile" ;; + "nls/el_GR.UTF-8/Makefile") CONFIG_FILES="$CONFIG_FILES nls/el_GR.UTF-8/Makefile" ;; + "nls/en_US.UTF-8/Makefile") CONFIG_FILES="$CONFIG_FILES nls/en_US.UTF-8/Makefile" ;; + "nls/fi_FI.UTF-8/Makefile") CONFIG_FILES="$CONFIG_FILES nls/fi_FI.UTF-8/Makefile" ;; + "nls/georgian-academy/Makefile") CONFIG_FILES="$CONFIG_FILES nls/georgian-academy/Makefile" ;; + "nls/georgian-ps/Makefile") CONFIG_FILES="$CONFIG_FILES nls/georgian-ps/Makefile" ;; + "nls/ibm-cp1133/Makefile") CONFIG_FILES="$CONFIG_FILES nls/ibm-cp1133/Makefile" ;; + "nls/iscii-dev/Makefile") CONFIG_FILES="$CONFIG_FILES nls/iscii-dev/Makefile" ;; + "nls/isiri-3342/Makefile") CONFIG_FILES="$CONFIG_FILES nls/isiri-3342/Makefile" ;; + "nls/iso8859-1/Makefile") CONFIG_FILES="$CONFIG_FILES nls/iso8859-1/Makefile" ;; + "nls/iso8859-10/Makefile") CONFIG_FILES="$CONFIG_FILES nls/iso8859-10/Makefile" ;; + "nls/iso8859-11/Makefile") CONFIG_FILES="$CONFIG_FILES nls/iso8859-11/Makefile" ;; + "nls/iso8859-13/Makefile") CONFIG_FILES="$CONFIG_FILES nls/iso8859-13/Makefile" ;; + "nls/iso8859-14/Makefile") CONFIG_FILES="$CONFIG_FILES nls/iso8859-14/Makefile" ;; + "nls/iso8859-15/Makefile") CONFIG_FILES="$CONFIG_FILES nls/iso8859-15/Makefile" ;; + "nls/iso8859-2/Makefile") CONFIG_FILES="$CONFIG_FILES nls/iso8859-2/Makefile" ;; + "nls/iso8859-3/Makefile") CONFIG_FILES="$CONFIG_FILES nls/iso8859-3/Makefile" ;; + "nls/iso8859-4/Makefile") CONFIG_FILES="$CONFIG_FILES nls/iso8859-4/Makefile" ;; + "nls/iso8859-5/Makefile") CONFIG_FILES="$CONFIG_FILES nls/iso8859-5/Makefile" ;; + "nls/iso8859-6/Makefile") CONFIG_FILES="$CONFIG_FILES nls/iso8859-6/Makefile" ;; + "nls/iso8859-7/Makefile") CONFIG_FILES="$CONFIG_FILES nls/iso8859-7/Makefile" ;; + "nls/iso8859-8/Makefile") CONFIG_FILES="$CONFIG_FILES nls/iso8859-8/Makefile" ;; + "nls/iso8859-9/Makefile") CONFIG_FILES="$CONFIG_FILES nls/iso8859-9/Makefile" ;; + "nls/iso8859-9e/Makefile") CONFIG_FILES="$CONFIG_FILES nls/iso8859-9e/Makefile" ;; + "nls/ja/Makefile") CONFIG_FILES="$CONFIG_FILES nls/ja/Makefile" ;; + "nls/ja.JIS/Makefile") CONFIG_FILES="$CONFIG_FILES nls/ja.JIS/Makefile" ;; + "nls/ja_JP.UTF-8/Makefile") CONFIG_FILES="$CONFIG_FILES nls/ja_JP.UTF-8/Makefile" ;; + "nls/ja.S90/Makefile") CONFIG_FILES="$CONFIG_FILES nls/ja.S90/Makefile" ;; + "nls/ja.SJIS/Makefile") CONFIG_FILES="$CONFIG_FILES nls/ja.SJIS/Makefile" ;; + "nls/ja.U90/Makefile") CONFIG_FILES="$CONFIG_FILES nls/ja.U90/Makefile" ;; + "nls/ko/Makefile") CONFIG_FILES="$CONFIG_FILES nls/ko/Makefile" ;; + "nls/koi8-c/Makefile") CONFIG_FILES="$CONFIG_FILES nls/koi8-c/Makefile" ;; + "nls/koi8-r/Makefile") CONFIG_FILES="$CONFIG_FILES nls/koi8-r/Makefile" ;; + "nls/koi8-u/Makefile") CONFIG_FILES="$CONFIG_FILES nls/koi8-u/Makefile" ;; + "nls/ko_KR.UTF-8/Makefile") CONFIG_FILES="$CONFIG_FILES nls/ko_KR.UTF-8/Makefile" ;; + "nls/microsoft-cp1251/Makefile") CONFIG_FILES="$CONFIG_FILES nls/microsoft-cp1251/Makefile" ;; + "nls/microsoft-cp1255/Makefile") CONFIG_FILES="$CONFIG_FILES nls/microsoft-cp1255/Makefile" ;; + "nls/microsoft-cp1256/Makefile") CONFIG_FILES="$CONFIG_FILES nls/microsoft-cp1256/Makefile" ;; + "nls/mulelao-1/Makefile") CONFIG_FILES="$CONFIG_FILES nls/mulelao-1/Makefile" ;; + "nls/nokhchi-1/Makefile") CONFIG_FILES="$CONFIG_FILES nls/nokhchi-1/Makefile" ;; + "nls/pt_BR.UTF-8/Makefile") CONFIG_FILES="$CONFIG_FILES nls/pt_BR.UTF-8/Makefile" ;; + "nls/ru_RU.UTF-8/Makefile") CONFIG_FILES="$CONFIG_FILES nls/ru_RU.UTF-8/Makefile" ;; + "nls/tatar-cyr/Makefile") CONFIG_FILES="$CONFIG_FILES nls/tatar-cyr/Makefile" ;; + "nls/th_TH/Makefile") CONFIG_FILES="$CONFIG_FILES nls/th_TH/Makefile" ;; + "nls/th_TH.UTF-8/Makefile") CONFIG_FILES="$CONFIG_FILES nls/th_TH.UTF-8/Makefile" ;; + "nls/tscii-0/Makefile") CONFIG_FILES="$CONFIG_FILES nls/tscii-0/Makefile" ;; + "nls/vi_VN.tcvn/Makefile") CONFIG_FILES="$CONFIG_FILES nls/vi_VN.tcvn/Makefile" ;; + "nls/vi_VN.viscii/Makefile") CONFIG_FILES="$CONFIG_FILES nls/vi_VN.viscii/Makefile" ;; + "nls/zh_CN/Makefile") CONFIG_FILES="$CONFIG_FILES nls/zh_CN/Makefile" ;; + "nls/zh_CN.gb18030/Makefile") CONFIG_FILES="$CONFIG_FILES nls/zh_CN.gb18030/Makefile" ;; + "nls/zh_CN.gbk/Makefile") CONFIG_FILES="$CONFIG_FILES nls/zh_CN.gbk/Makefile" ;; + "nls/zh_CN.UTF-8/Makefile") CONFIG_FILES="$CONFIG_FILES nls/zh_CN.UTF-8/Makefile" ;; + "nls/zh_HK.big5/Makefile") CONFIG_FILES="$CONFIG_FILES nls/zh_HK.big5/Makefile" ;; + "nls/zh_HK.big5hkscs/Makefile") CONFIG_FILES="$CONFIG_FILES nls/zh_HK.big5hkscs/Makefile" ;; + "nls/zh_HK.UTF-8/Makefile") CONFIG_FILES="$CONFIG_FILES nls/zh_HK.UTF-8/Makefile" ;; + "nls/zh_TW/Makefile") CONFIG_FILES="$CONFIG_FILES nls/zh_TW/Makefile" ;; + "nls/zh_TW.big5/Makefile") CONFIG_FILES="$CONFIG_FILES nls/zh_TW.big5/Makefile" ;; + "nls/zh_TW.UTF-8/Makefile") CONFIG_FILES="$CONFIG_FILES nls/zh_TW.UTF-8/Makefile" ;; + "specs/Makefile") CONFIG_FILES="$CONFIG_FILES specs/Makefile" ;; + "specs/i18n/Makefile") CONFIG_FILES="$CONFIG_FILES specs/i18n/Makefile" ;; + "specs/libX11/Makefile") CONFIG_FILES="$CONFIG_FILES specs/libX11/Makefile" ;; + "specs/XIM/Makefile") CONFIG_FILES="$CONFIG_FILES specs/XIM/Makefile" ;; + "x11.pc") CONFIG_FILES="$CONFIG_FILES x11.pc" ;; + "x11-xcb.pc") CONFIG_FILES="$CONFIG_FILES x11-xcb.pc" ;; -# Commands used to build a shared archive. -archive_cmds=$lt_archive_cmds -archive_expsym_cmds=$lt_archive_expsym_cmds + *) { { $as_echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5 +$as_echo "$as_me: error: invalid argument: $ac_config_target" >&2;} + { (exit 1); exit 1; }; };; + esac +done -# Commands used to build a loadable module if different from building -# a shared archive. -module_cmds=$lt_module_cmds -module_expsym_cmds=$lt_module_expsym_cmds -# Whether we are building with GNU ld or not. -with_gnu_ld=$lt_with_gnu_ld +# If the user did not use the arguments to specify the items to instantiate, +# then the envvar interface is used. Set only those that are not. +# We use the long form for the default assignment because of an extremely +# bizarre bug on SunOS 4.1.3. +if $ac_need_defaults; then + test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files + test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers + test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands +fi -# Flag that allows shared libraries with undefined symbols to be built. -allow_undefined_flag=$lt_allow_undefined_flag +# Have a temporary directory for convenience. Make it in the build tree +# simply because there is no reason against having it here, and in addition, +# creating and moving files from /tmp can sometimes cause problems. +# Hook for its removal unless debugging. +# Note that there is a small window in which the directory will not be cleaned: +# after its creation but before its name has been assigned to `$tmp'. +$debug || +{ + tmp= + trap 'exit_status=$? + { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status +' 0 + trap '{ (exit 1); exit 1; }' 1 2 13 15 +} +# Create a (secure) tmp directory for tmp files. -# Flag that enforces no undefined symbols. -no_undefined_flag=$lt_no_undefined_flag +{ + tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && + test -n "$tmp" && test -d "$tmp" +} || +{ + tmp=./conf$$-$RANDOM + (umask 077 && mkdir "$tmp") +} || +{ + $as_echo "$as_me: cannot create a temporary directory in ." >&2 + { (exit 1); exit 1; } +} -# Flag to hardcode \$libdir into a binary during linking. -# This must work even if \$libdir does not exist -hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec +# Set up the scripts for CONFIG_FILES section. +# No need to generate them if there are no CONFIG_FILES. +# This happens for instance with `./config.status config.h'. +if test -n "$CONFIG_FILES"; then -# If ld is used when linking, flag to hardcode \$libdir into a binary -# during linking. This must work even if \$libdir does not exist. -hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld -# Whether we need a single "-rpath" flag with a separated argument. -hardcode_libdir_separator=$lt_hardcode_libdir_separator +ac_cr=' ' +ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' /dev/null` +if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then + ac_cs_awk_cr='\\r' +else + ac_cs_awk_cr=$ac_cr +fi -# Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes -# DIR into the resulting binary. -hardcode_direct=$hardcode_direct +echo 'BEGIN {' >"$tmp/subs1.awk" && +_ACEOF -# Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes -# DIR into the resulting binary and the resulting library dependency is -# "absolute",i.e impossible to change by setting \${shlibpath_var} if the -# library is relocated. -hardcode_direct_absolute=$hardcode_direct_absolute -# Set to "yes" if using the -LDIR flag during linking hardcodes DIR -# into the resulting binary. -hardcode_minus_L=$hardcode_minus_L +{ + echo "cat >conf$$subs.awk <<_ACEOF" && + echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' && + echo "_ACEOF" +} >conf$$subs.sh || + { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5 +$as_echo "$as_me: error: could not make $CONFIG_STATUS" >&2;} + { (exit 1); exit 1; }; } +ac_delim_num=`echo "$ac_subst_vars" | grep -c '$'` +ac_delim='%!_!# ' +for ac_last_try in false false false false false :; do + . ./conf$$subs.sh || + { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5 +$as_echo "$as_me: error: could not make $CONFIG_STATUS" >&2;} + { (exit 1); exit 1; }; } -# Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR -# into the resulting binary. -hardcode_shlibpath_var=$hardcode_shlibpath_var + ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X` + if test $ac_delim_n = $ac_delim_num; then + break + elif $ac_last_try; then + { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5 +$as_echo "$as_me: error: could not make $CONFIG_STATUS" >&2;} + { (exit 1); exit 1; }; } + else + ac_delim="$ac_delim!$ac_delim _$ac_delim!! " + fi +done +rm -f conf$$subs.sh -# Set to "yes" if building a shared library automatically hardcodes DIR -# into the library and all subsequent libraries and executables linked -# against it. -hardcode_automatic=$hardcode_automatic +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 +cat >>"\$tmp/subs1.awk" <<\\_ACAWK && +_ACEOF +sed -n ' +h +s/^/S["/; s/!.*/"]=/ +p +g +s/^[^!]*!// +:repl +t repl +s/'"$ac_delim"'$// +t delim +:nl +h +s/\(.\{148\}\).*/\1/ +t more1 +s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/ +p +n +b repl +:more1 +s/["\\]/\\&/g; s/^/"/; s/$/"\\/ +p +g +s/.\{148\}// +t nl +:delim +h +s/\(.\{148\}\).*/\1/ +t more2 +s/["\\]/\\&/g; s/^/"/; s/$/"/ +p +b +:more2 +s/["\\]/\\&/g; s/^/"/; s/$/"\\/ +p +g +s/.\{148\}// +t delim +' >$CONFIG_STATUS || ac_write_fail=1 +rm -f conf$$subs.awk +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 +_ACAWK +cat >>"\$tmp/subs1.awk" <<_ACAWK && + for (key in S) S_is_set[key] = 1 + FS = "" -# Set to yes if linker adds runtime paths of dependent libraries -# to runtime path list. -inherit_rpath=$inherit_rpath +} +{ + line = $ 0 + nfields = split(line, field, "@") + substed = 0 + len = length(field[1]) + for (i = 2; i < nfields; i++) { + key = field[i] + keylen = length(key) + if (S_is_set[key]) { + value = S[key] + line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3) + len += length(value) + length(field[++i]) + substed = 1 + } else + len += 1 + keylen + } -# Whether libtool must link a program against all its dependency libraries. -link_all_deplibs=$link_all_deplibs + print line +} -# Fix the shell variable \$srcfile for the compiler. -fix_srcfile_path=$lt_fix_srcfile_path +_ACAWK +_ACEOF +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then + sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g" +else + cat +fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \ + || { { $as_echo "$as_me:$LINENO: error: could not setup config files machinery" >&5 +$as_echo "$as_me: error: could not setup config files machinery" >&2;} + { (exit 1); exit 1; }; } +_ACEOF -# Set to "yes" if exported symbols are required. -always_export_symbols=$always_export_symbols +# VPATH may cause trouble with some makes, so we remove $(srcdir), +# ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and +# trailing colons and then remove the whole line if VPATH becomes empty +# (actually we leave an empty line to preserve line numbers). +if test "x$srcdir" = x.; then + ac_vpsub='/^[ ]*VPATH[ ]*=/{ +s/:*\$(srcdir):*/:/ +s/:*\${srcdir}:*/:/ +s/:*@srcdir@:*/:/ +s/^\([^=]*=[ ]*\):*/\1/ +s/:*$// +s/^[^=]*=[ ]*$// +}' +fi -# The commands to list exported symbols. -export_symbols_cmds=$lt_export_symbols_cmds +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +fi # test -n "$CONFIG_FILES" -# Symbols that should not be listed in the preloaded symbols. -exclude_expsyms=$lt_exclude_expsyms +# Set up the scripts for CONFIG_HEADERS section. +# No need to generate them if there are no CONFIG_HEADERS. +# This happens for instance with `./config.status Makefile'. +if test -n "$CONFIG_HEADERS"; then +cat >"$tmp/defines.awk" <<\_ACAWK || +BEGIN { +_ACEOF -# Symbols that must always be exported. -include_expsyms=$lt_include_expsyms +# Transform confdefs.h into an awk script `defines.awk', embedded as +# here-document in config.status, that substitutes the proper values into +# config.h.in to produce config.h. -# Commands necessary for linking programs (against libraries) with templates. -prelink_cmds=$lt_prelink_cmds +# Create a delimiter string that does not exist in confdefs.h, to ease +# handling of long lines. +ac_delim='%!_!# ' +for ac_last_try in false false :; do + ac_t=`sed -n "/$ac_delim/p" confdefs.h` + if test -z "$ac_t"; then + break + elif $ac_last_try; then + { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_HEADERS" >&5 +$as_echo "$as_me: error: could not make $CONFIG_HEADERS" >&2;} + { (exit 1); exit 1; }; } + else + ac_delim="$ac_delim!$ac_delim _$ac_delim!! " + fi +done -# Specify filename containing input files. -file_list_spec=$lt_file_list_spec +# For the awk script, D is an array of macro values keyed by name, +# likewise P contains macro parameters if any. Preserve backslash +# newline sequences. -# How to hardcode a shared library path into an executable. -hardcode_action=$hardcode_action +ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]* +sed -n ' +s/.\{148\}/&'"$ac_delim"'/g +t rset +:rset +s/^[ ]*#[ ]*define[ ][ ]*/ / +t def +d +:def +s/\\$// +t bsnl +s/["\\]/\\&/g +s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ +D["\1"]=" \3"/p +s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p +d +:bsnl +s/["\\]/\\&/g +s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ +D["\1"]=" \3\\\\\\n"\\/p +t cont +s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p +t cont +d +:cont +n +s/.\{148\}/&'"$ac_delim"'/g +t clear +:clear +s/\\$// +t bsnlc +s/["\\]/\\&/g; s/^/"/; s/$/"/p +d +:bsnlc +s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p +b cont +' >$CONFIG_STATUS || ac_write_fail=1 -# ### END LIBTOOL CONFIG +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 + for (key in D) D_is_set[key] = 1 + FS = "" +} +/^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ { + line = \$ 0 + split(line, arg, " ") + if (arg[1] == "#") { + defundef = arg[2] + mac1 = arg[3] + } else { + defundef = substr(arg[1], 2) + mac1 = arg[2] + } + split(mac1, mac2, "(") #) + macro = mac2[1] + prefix = substr(line, 1, index(line, defundef) - 1) + if (D_is_set[macro]) { + # Preserve the white space surrounding the "#". + print prefix "define", macro P[macro] D[macro] + next + } else { + # Replace #undef with comments. This is necessary, for example, + # in the case of _POSIX_SOURCE, which is predefined and required + # on some systems where configure will not decide to define it. + if (defundef == "undef") { + print "/*", prefix defundef, macro, "*/" + next + } + } +} +{ print } +_ACAWK +_ACEOF +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 + { { $as_echo "$as_me:$LINENO: error: could not setup config headers machinery" >&5 +$as_echo "$as_me: error: could not setup config headers machinery" >&2;} + { (exit 1); exit 1; }; } +fi # test -n "$CONFIG_HEADERS" -_LT_EOF - case $host_os in - aix3*) - cat <<\_LT_EOF >> "$cfgfile" -# AIX sometimes has problems with the GCC collect2 program. For some -# reason, if we set the COLLECT_NAMES environment variable, the problems -# vanish in a puff of smoke. -if test "X${COLLECT_NAMES+set}" != Xset; then - COLLECT_NAMES= - export COLLECT_NAMES -fi -_LT_EOF - ;; +eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS" +shift +for ac_tag +do + case $ac_tag in + :[FHLC]) ac_mode=$ac_tag; continue;; + esac + case $ac_mode$ac_tag in + :[FHL]*:*);; + :L* | :C*:*) { { $as_echo "$as_me:$LINENO: error: invalid tag $ac_tag" >&5 +$as_echo "$as_me: error: invalid tag $ac_tag" >&2;} + { (exit 1); exit 1; }; };; + :[FH]-) ac_tag=-:-;; + :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; esac + ac_save_IFS=$IFS + IFS=: + set x $ac_tag + IFS=$ac_save_IFS + shift + ac_file=$1 + shift + case $ac_mode in + :L) ac_source=$1;; + :[FH]) + ac_file_inputs= + for ac_f + do + case $ac_f in + -) ac_f="$tmp/stdin";; + *) # Look for the file first in the build tree, then in the source tree + # (if the path is not absolute). The absolute path cannot be DOS-style, + # because $ac_f cannot contain `:'. + test -f "$ac_f" || + case $ac_f in + [\\/$]*) false;; + *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; + esac || + { { $as_echo "$as_me:$LINENO: error: cannot find input file: $ac_f" >&5 +$as_echo "$as_me: error: cannot find input file: $ac_f" >&2;} + { (exit 1); exit 1; }; };; + esac + case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac + ac_file_inputs="$ac_file_inputs '$ac_f'" + done -ltmain="$ac_aux_dir/ltmain.sh" - - - # We use sed instead of cat because bash on DJGPP gets confused if - # if finds mixed CR/LF and LF-only lines. Since sed operates in - # text mode, it properly converts lines to CR/LF. This bash problem - # is reportedly fixed, but why not run on old versions too? - sed '/^# Generated shell functions inserted here/q' "$ltmain" >> "$cfgfile" \ - || (rm -f "$cfgfile"; exit 1) + # Let's still pretend it is `configure' which instantiates (i.e., don't + # use $as_me), people would be surprised to read: + # /* config.h. Generated by config.status. */ + configure_input='Generated from '` + $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g' + `' by configure.' + if test x"$ac_file" != x-; then + configure_input="$ac_file. $configure_input" + { $as_echo "$as_me:$LINENO: creating $ac_file" >&5 +$as_echo "$as_me: creating $ac_file" >&6;} + fi + # Neutralize special characters interpreted by sed in replacement strings. + case $configure_input in #( + *\&* | *\|* | *\\* ) + ac_sed_conf_input=`$as_echo "$configure_input" | + sed 's/[\\\\&|]/\\\\&/g'`;; #( + *) ac_sed_conf_input=$configure_input;; + esac - case $xsi_shell in - yes) - cat << \_LT_EOF >> "$cfgfile" + case $ac_tag in + *:-:* | *:-) cat >"$tmp/stdin" \ + || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5 +$as_echo "$as_me: error: could not create $ac_file" >&2;} + { (exit 1); exit 1; }; } ;; + esac + ;; + esac -# func_dirname file append nondir_replacement -# Compute the dirname of FILE. If nonempty, add APPEND to the result, -# otherwise set result to NONDIR_REPLACEMENT. -func_dirname () -{ - case ${1} in - */*) func_dirname_result="${1%/*}${2}" ;; - * ) func_dirname_result="${3}" ;; + ac_dir=`$as_dirname -- "$ac_file" || +$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ + X"$ac_file" : 'X\(//\)[^/]' \| \ + X"$ac_file" : 'X\(//\)$' \| \ + X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X"$ac_file" | + sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ + s//\1/ + q + } + /^X\(\/\/\)[^/].*/{ + s//\1/ + q + } + /^X\(\/\/\)$/{ + s//\1/ + q + } + /^X\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q'` + { as_dir="$ac_dir" + case $as_dir in #( + -*) as_dir=./$as_dir;; esac -} + test -d "$as_dir" || { $as_mkdir_p && mkdir -p "$as_dir"; } || { + as_dirs= + while :; do + case $as_dir in #( + *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( + *) as_qdir=$as_dir;; + esac + as_dirs="'$as_qdir' $as_dirs" + as_dir=`$as_dirname -- "$as_dir" || +$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ + X"$as_dir" : 'X\(//\)[^/]' \| \ + X"$as_dir" : 'X\(//\)$' \| \ + X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X"$as_dir" | + sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ + s//\1/ + q + } + /^X\(\/\/\)[^/].*/{ + s//\1/ + q + } + /^X\(\/\/\)$/{ + s//\1/ + q + } + /^X\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q'` + test -d "$as_dir" && break + done + test -z "$as_dirs" || eval "mkdir $as_dirs" + } || test -d "$as_dir" || { { $as_echo "$as_me:$LINENO: error: cannot create directory $as_dir" >&5 +$as_echo "$as_me: error: cannot create directory $as_dir" >&2;} + { (exit 1); exit 1; }; }; } + ac_builddir=. -# func_basename file -func_basename () -{ - func_basename_result="${1##*/}" -} +case "$ac_dir" in +.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; +*) + ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` + # A ".." for each directory in $ac_dir_suffix. + ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` + case $ac_top_builddir_sub in + "") ac_top_builddir_sub=. ac_top_build_prefix= ;; + *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; + esac ;; +esac +ac_abs_top_builddir=$ac_pwd +ac_abs_builddir=$ac_pwd$ac_dir_suffix +# for backward compatibility: +ac_top_builddir=$ac_top_build_prefix -# func_dirname_and_basename file append nondir_replacement -# perform func_basename and func_dirname in a single function -# call: -# dirname: Compute the dirname of FILE. If nonempty, -# add APPEND to the result, otherwise set result -# to NONDIR_REPLACEMENT. -# value returned in "$func_dirname_result" -# basename: Compute filename of FILE. -# value retuned in "$func_basename_result" -# Implementation must be kept synchronized with func_dirname -# and func_basename. For efficiency, we do not delegate to -# those functions but instead duplicate the functionality here. -func_dirname_and_basename () -{ - case ${1} in - */*) func_dirname_result="${1%/*}${2}" ;; - * ) func_dirname_result="${3}" ;; - esac - func_basename_result="${1##*/}" -} +case $srcdir in + .) # We are building in place. + ac_srcdir=. + ac_top_srcdir=$ac_top_builddir_sub + ac_abs_top_srcdir=$ac_pwd ;; + [\\/]* | ?:[\\/]* ) # Absolute name. + ac_srcdir=$srcdir$ac_dir_suffix; + ac_top_srcdir=$srcdir + ac_abs_top_srcdir=$srcdir ;; + *) # Relative name. + ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix + ac_top_srcdir=$ac_top_build_prefix$srcdir + ac_abs_top_srcdir=$ac_pwd/$srcdir ;; +esac +ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix -# func_stripname prefix suffix name -# strip PREFIX and SUFFIX off of NAME. -# PREFIX and SUFFIX must not contain globbing or regex special -# characters, hashes, percent signs, but SUFFIX may contain a leading -# dot (in which case that matches only a dot). -func_stripname () -{ - # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are - # positional parameters, so assign one to ordinary parameter first. - func_stripname_result=${3} - func_stripname_result=${func_stripname_result#"${1}"} - func_stripname_result=${func_stripname_result%"${2}"} -} -# func_opt_split -func_opt_split () -{ - func_opt_split_opt=${1%%=*} - func_opt_split_arg=${1#*=} -} + case $ac_mode in + :F) + # + # CONFIG_FILE + # -# func_lo2o object -func_lo2o () -{ - case ${1} in - *.lo) func_lo2o_result=${1%.lo}.${objext} ;; - *) func_lo2o_result=${1} ;; + case $INSTALL in + [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;; + *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;; esac -} + ac_MKDIR_P=$MKDIR_P + case $MKDIR_P in + [\\/$]* | ?:[\\/]* ) ;; + */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;; + esac +_ACEOF -# func_xform libobj-or-source -func_xform () -{ - func_xform_result=${1%.*}.lo -} +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +# If the template does not know about datarootdir, expand it. +# FIXME: This hack should be removed a few years after 2.60. +ac_datarootdir_hack=; ac_datarootdir_seen= -# func_arith arithmetic-term... -func_arith () -{ - func_arith_result=$(( $* )) +ac_sed_dataroot=' +/datarootdir/ { + p + q } +/@datadir@/p +/@docdir@/p +/@infodir@/p +/@localedir@/p +/@mandir@/p +' +case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in +*datarootdir*) ac_datarootdir_seen=yes;; +*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) + { $as_echo "$as_me:$LINENO: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 +$as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;} +_ACEOF +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 + ac_datarootdir_hack=' + s&@datadir@&$datadir&g + s&@docdir@&$docdir&g + s&@infodir@&$infodir&g + s&@localedir@&$localedir&g + s&@mandir@&$mandir&g + s&\\\${datarootdir}&$datarootdir&g' ;; +esac +_ACEOF -# func_len string -# STRING may not start with a hyphen. -func_len () -{ - func_len_result=${#1} -} +# Neutralize VPATH when `$srcdir' = `.'. +# Shell code in configure.ac might set extrasub. +# FIXME: do we really want to maintain this feature? +cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 +ac_sed_extra="$ac_vpsub +$extrasub +_ACEOF +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +:t +/@[a-zA-Z_][a-zA-Z_0-9]*@/!b +s|@configure_input@|$ac_sed_conf_input|;t t +s&@top_builddir@&$ac_top_builddir_sub&;t t +s&@top_build_prefix@&$ac_top_build_prefix&;t t +s&@srcdir@&$ac_srcdir&;t t +s&@abs_srcdir@&$ac_abs_srcdir&;t t +s&@top_srcdir@&$ac_top_srcdir&;t t +s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t +s&@builddir@&$ac_builddir&;t t +s&@abs_builddir@&$ac_abs_builddir&;t t +s&@abs_top_builddir@&$ac_abs_top_builddir&;t t +s&@INSTALL@&$ac_INSTALL&;t t +s&@MKDIR_P@&$ac_MKDIR_P&;t t +$ac_datarootdir_hack +" +eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$tmp/subs.awk" >$tmp/out \ + || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5 +$as_echo "$as_me: error: could not create $ac_file" >&2;} + { (exit 1); exit 1; }; } -_LT_EOF - ;; - *) # Bourne compatible functions. - cat << \_LT_EOF >> "$cfgfile" +test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && + { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } && + { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } && + { $as_echo "$as_me:$LINENO: WARNING: $ac_file contains a reference to the variable \`datarootdir' +which seems to be undefined. Please make sure it is defined." >&5 +$as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' +which seems to be undefined. Please make sure it is defined." >&2;} -# func_dirname file append nondir_replacement -# Compute the dirname of FILE. If nonempty, add APPEND to the result, -# otherwise set result to NONDIR_REPLACEMENT. -func_dirname () -{ - # Extract subdirectory from the argument. - func_dirname_result=`$ECHO "X${1}" | $Xsed -e "$dirname"` - if test "X$func_dirname_result" = "X${1}"; then - func_dirname_result="${3}" + rm -f "$tmp/stdin" + case $ac_file in + -) cat "$tmp/out" && rm -f "$tmp/out";; + *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";; + esac \ + || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5 +$as_echo "$as_me: error: could not create $ac_file" >&2;} + { (exit 1); exit 1; }; } + ;; + :H) + # + # CONFIG_HEADER + # + if test x"$ac_file" != x-; then + { + $as_echo "/* $configure_input */" \ + && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" + } >"$tmp/config.h" \ + || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5 +$as_echo "$as_me: error: could not create $ac_file" >&2;} + { (exit 1); exit 1; }; } + if diff "$ac_file" "$tmp/config.h" >/dev/null 2>&1; then + { $as_echo "$as_me:$LINENO: $ac_file is unchanged" >&5 +$as_echo "$as_me: $ac_file is unchanged" >&6;} + else + rm -f "$ac_file" + mv "$tmp/config.h" "$ac_file" \ + || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5 +$as_echo "$as_me: error: could not create $ac_file" >&2;} + { (exit 1); exit 1; }; } + fi else - func_dirname_result="$func_dirname_result${2}" + $as_echo "/* $configure_input */" \ + && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" \ + || { { $as_echo "$as_me:$LINENO: error: could not create -" >&5 +$as_echo "$as_me: error: could not create -" >&2;} + { (exit 1); exit 1; }; } fi -} - -# func_basename file -func_basename () -{ - func_basename_result=`$ECHO "X${1}" | $Xsed -e "$basename"` -} - - -# func_stripname prefix suffix name -# strip PREFIX and SUFFIX off of NAME. -# PREFIX and SUFFIX must not contain globbing or regex special -# characters, hashes, percent signs, but SUFFIX may contain a leading -# dot (in which case that matches only a dot). -# func_strip_suffix prefix name -func_stripname () -{ - case ${2} in - .*) func_stripname_result=`$ECHO "X${3}" \ - | $Xsed -e "s%^${1}%%" -e "s%\\\\${2}\$%%"`;; - *) func_stripname_result=`$ECHO "X${3}" \ - | $Xsed -e "s%^${1}%%" -e "s%${2}\$%%"`;; +# Compute "$ac_file"'s index in $config_headers. +_am_arg="$ac_file" +_am_stamp_count=1 +for _am_header in $config_headers :; do + case $_am_header in + $_am_arg | $_am_arg:* ) + break ;; + * ) + _am_stamp_count=`expr $_am_stamp_count + 1` ;; esac -} - -# sed scripts: -my_sed_long_opt='1s/^\(-[^=]*\)=.*/\1/;q' -my_sed_long_arg='1s/^-[^=]*=//' - -# func_opt_split -func_opt_split () -{ - func_opt_split_opt=`$ECHO "X${1}" | $Xsed -e "$my_sed_long_opt"` - func_opt_split_arg=`$ECHO "X${1}" | $Xsed -e "$my_sed_long_arg"` -} - -# func_lo2o object -func_lo2o () -{ - func_lo2o_result=`$ECHO "X${1}" | $Xsed -e "$lo2o"` -} - -# func_xform libobj-or-source -func_xform () -{ - func_xform_result=`$ECHO "X${1}" | $Xsed -e 's/\.[^.]*$/.lo/'` -} - -# func_arith arithmetic-term... -func_arith () -{ - func_arith_result=`expr "$@"` -} - -# func_len string -# STRING may not start with a hyphen. -func_len () -{ - func_len_result=`expr "$1" : ".*" 2>/dev/null || echo $max_cmd_len` -} - -_LT_EOF -esac - -case $lt_shell_append in - yes) - cat << \_LT_EOF >> "$cfgfile" - -# func_append var value -# Append VALUE to the end of shell variable VAR. -func_append () -{ - eval "$1+=\$2" -} -_LT_EOF - ;; - *) - cat << \_LT_EOF >> "$cfgfile" - -# func_append var value -# Append VALUE to the end of shell variable VAR. -func_append () -{ - eval "$1=\$$1\$2" -} +done +echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" || +$as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ + X"$_am_arg" : 'X\(//\)[^/]' \| \ + X"$_am_arg" : 'X\(//\)$' \| \ + X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X"$_am_arg" | + sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ + s//\1/ + q + } + /^X\(\/\/\)[^/].*/{ + s//\1/ + q + } + /^X\(\/\/\)$/{ + s//\1/ + q + } + /^X\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q'`/stamp-h$_am_stamp_count + ;; -_LT_EOF - ;; + :C) { $as_echo "$as_me:$LINENO: executing $ac_file commands" >&5 +$as_echo "$as_me: executing $ac_file commands" >&6;} + ;; esac - sed -n '/^# Generated shell functions inserted here/,$p' "$ltmain" >> "$cfgfile" \ - || (rm -f "$cfgfile"; exit 1) - - mv -f "$cfgfile" "$ofile" || - (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") - chmod +x "$ofile" - + case $ac_file$ac_mode in + "depfiles":C) test x"$AMDEP_TRUE" != x"" || { + # Autoconf 2.62 quotes --file arguments for eval, but not when files + # are listed without --file. Let's play safe and only enable the eval + # if we detect the quoting. + case $CONFIG_FILES in + *\'*) eval set x "$CONFIG_FILES" ;; + *) set x $CONFIG_FILES ;; + esac + shift + for mf + do + # Strip MF so we end up with the name of the file. + mf=`echo "$mf" | sed -e 's/:.*$//'` + # Check whether this is an Automake generated Makefile or not. + # We used to match only the files named `Makefile.in', but + # some people rename them; so instead we look at the file content. + # Grep'ing the first line is not enough: some people post-process + # each Makefile.in and add a new line on top of each file to say so. + # Grep'ing the whole file is not good either: AIX grep has a line + # limit of 2048, but all sed's we know have understand at least 4000. + if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then + dirpart=`$as_dirname -- "$mf" || +$as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ + X"$mf" : 'X\(//\)[^/]' \| \ + X"$mf" : 'X\(//\)$' \| \ + X"$mf" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X"$mf" | + sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ + s//\1/ + q + } + /^X\(\/\/\)[^/].*/{ + s//\1/ + q + } + /^X\(\/\/\)$/{ + s//\1/ + q + } + /^X\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q'` + else + continue + fi + # Extract the definition of DEPDIR, am__include, and am__quote + # from the Makefile without running `make'. + DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"` + test -z "$DEPDIR" && continue + am__include=`sed -n 's/^am__include = //p' < "$mf"` + test -z "am__include" && continue + am__quote=`sed -n 's/^am__quote = //p' < "$mf"` + # When using ansi2knr, U may be empty or an underscore; expand it + U=`sed -n 's/^U = //p' < "$mf"` + # Find all dependency output files, they are included files with + # $(DEPDIR) in their names. We invoke sed twice because it is the + # simplest approach to changing $(DEPDIR) to its actual value in the + # expansion. + for file in `sed -n " + s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \ + sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do + # Make sure the directory exists. + test -f "$dirpart/$file" && continue + fdir=`$as_dirname -- "$file" || +$as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ + X"$file" : 'X\(//\)[^/]' \| \ + X"$file" : 'X\(//\)$' \| \ + X"$file" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X"$file" | + sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ + s//\1/ + q + } + /^X\(\/\/\)[^/].*/{ + s//\1/ + q + } + /^X\(\/\/\)$/{ + s//\1/ + q + } + /^X\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q'` + { as_dir=$dirpart/$fdir + case $as_dir in #( + -*) as_dir=./$as_dir;; + esac + test -d "$as_dir" || { $as_mkdir_p && mkdir -p "$as_dir"; } || { + as_dirs= + while :; do + case $as_dir in #( + *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( + *) as_qdir=$as_dir;; + esac + as_dirs="'$as_qdir' $as_dirs" + as_dir=`$as_dirname -- "$as_dir" || +$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ + X"$as_dir" : 'X\(//\)[^/]' \| \ + X"$as_dir" : 'X\(//\)$' \| \ + X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || +$as_echo X"$as_dir" | + sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ + s//\1/ + q + } + /^X\(\/\/\)[^/].*/{ + s//\1/ + q + } + /^X\(\/\/\)$/{ + s//\1/ + q + } + /^X\(\/\).*/{ + s//\1/ + q + } + s/.*/./; q'` + test -d "$as_dir" && break + done + test -z "$as_dirs" || eval "mkdir $as_dirs" + } || test -d "$as_dir" || { { $as_echo "$as_me:$LINENO: error: cannot create directory $as_dir" >&5 +$as_echo "$as_me: error: cannot create directory $as_dir" >&2;} + { (exit 1); exit 1; }; }; } + # echo "creating $dirpart/$file" + echo '# dummy' > "$dirpart/$file" + done + done +} ;; esac diff --git a/libX11/configure.ac b/libX11/configure.ac index 655ea400f..db83f262a 100644 --- a/libX11/configure.ac +++ b/libX11/configure.ac @@ -3,7 +3,7 @@ AC_PREREQ(2.60) AC_INIT([libX11], - 1.3, + 1.3.1, [https://bugs.freedesktop.org/enter_bug.cgi?product=xorg], libX11) AC_CONFIG_SRCDIR([Makefile.am]) @@ -94,7 +94,7 @@ dnl If you're seeing an error here, be sure you installed the lib/xtrans module dnl first and if it's not in the default location, that you set the ACLOCAL dnl environment variable to find it, such as: dnl ACLOCAL="aclocal -I ${PREFIX}/share/aclocal" -m4_pattern_forbid(XTRANS_CONNECTION_FLAGS) +m4_pattern_forbid([^XTRANS_CONNECTION_FLAGS$]) # Transport selection macro from xtrans.m4 XTRANS_CONNECTION_FLAGS @@ -181,7 +181,7 @@ AC_MSG_RESULT($XLIB_LOADABLE_XCURSOR) # Checks for header files. AC_HEADER_STDC -dnl AC_CHECK_HEADERS([stdio.h stdlib.h math.h]) +AC_CHECK_HEADERS([sys/select.h]) # Checks for typedefs, structures, and compiler characteristics. @@ -428,9 +428,30 @@ AC_DEFINE_DIR(XERRORDB, XERRORDB, [Location of error message database]) XORG_CHECK_MALLOC_ZERO -# Support AM_SILENT_RULES if automake-1.11 or later is used -m4_ifdef([AM_SILENT_RULES],[HAVE_AM_SILENT_RULES=yes]) -AM_CONDITIONAL(HAVE_AM_SILENT_RULES, test x$HAVE_AM_SILENT_RULES != x) +# Specification documents are currently provided in troff format +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 specifications]) +AC_ARG_ENABLE(specs, AC_HELP_STRING([--enable-specs], + [Enable building of specification docs]), + [build_specs="${enableval}"], [build_specs="auto"]) + +if test "x${build_specs}" = xauto; then + if test "x${GROFF}" = xnone ; then + build_specs=no + else + build_specs=yes + fi +fi +AC_MSG_RESULT([${build_specs}]) +if test "x${build_specs}" = xyes && test "x${GROFF}" = xnone ; then + AC_MSG_ERROR([can't build documentation without groff]) +fi + +AM_CONDITIONAL(BUILD_SPECS, [test x$build_specs = xyes]) +AM_CONDITIONAL(HAVE_PS2PDF, [test x$PS2PDF != xnone]) + AC_OUTPUT([Makefile include/Makefile @@ -512,6 +533,10 @@ AC_OUTPUT([Makefile nls/zh_TW/Makefile nls/zh_TW.big5/Makefile nls/zh_TW.UTF-8/Makefile + specs/Makefile + specs/i18n/Makefile + specs/libX11/Makefile + specs/XIM/Makefile x11.pc x11-xcb.pc]) diff --git a/libX11/cpprules.in b/libX11/cpprules.in index e49341f09..845e242e6 100644 --- a/libX11/cpprules.in +++ b/libX11/cpprules.in @@ -25,13 +25,5 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -if HAVE_AM_SILENT_RULES -# Support for automake 1.11 AM_SILENT_RULES -cpp_verbose = $(cpp_verbose_$(V)) -cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -cpp_verbose_0 = @echo " CPP " $@; -endif HAVE_AM_SILENT_RULES - .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ diff --git a/libX11/include/Makefile.in b/libX11/include/Makefile.in index 245351169..cbe83ee0d 100644 --- a/libX11/include/Makefile.in +++ b/libX11/include/Makefile.in @@ -108,6 +108,10 @@ 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@ @@ -115,16 +119,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -133,7 +139,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -143,7 +148,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -154,12 +158,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -169,6 +169,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -207,7 +208,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -239,7 +241,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ diff --git a/libX11/ltmain.sh b/libX11/ltmain.sh index 6939dcc4a..27d498a08 100644 --- a/libX11/ltmain.sh +++ b/libX11/ltmain.sh @@ -1,83 +1,52 @@ -# Generated from ltmain.m4sh. - -# ltmain.sh (GNU libtool) 2.2.6 -# Written by Gordon Matzigkeit , 1996 - -# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, 2006, 2007 2008 Free Software Foundation, Inc. -# This is free software; see the source for copying conditions. There is NO -# warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. - -# GNU Libtool is free software; you can redistribute it and/or modify +# ltmain.sh - Provide generalized library-building support services. +# NOTE: Changing this file will not affect anything until you rerun configure. +# +# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, 2006, +# 2007, 2008 Free Software Foundation, Inc. +# Originally by Gordon Matzigkeit , 1996 +# +# This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # (at your option) any later version. # -# As a special exception to the GNU General Public License, -# if you distribute this file as part of a program or library that -# is built using GNU Libtool, you may include this file under the -# same distribution terms that you use for the rest of that program. -# -# GNU Libtool is distributed in the hope that it will be useful, but +# This program is distributed in the hope that it will be useful, but # WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU # General Public License for more details. # # You should have received a copy of the GNU General Public License -# along with GNU Libtool; see the file COPYING. If not, a copy -# can be downloaded from http://www.gnu.org/licenses/gpl.html, -# or obtained by writing to the Free Software Foundation, Inc., -# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. - -# Usage: $progname [OPTION]... [MODE-ARG]... -# -# Provide generalized library-building support services. +# along with this program; if not, write to the Free Software +# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. # -# --config show all configuration variables -# --debug enable verbose shell tracing -# -n, --dry-run display commands without modifying any files -# --features display basic configuration information and exit -# --mode=MODE use operation mode MODE -# --preserve-dup-deps don't remove duplicate dependency libraries -# --quiet, --silent don't print informational messages -# --tag=TAG use configuration variables from tag TAG -# -v, --verbose print informational messages (default) -# --version print version information -# -h, --help print short or long help message -# -# MODE must be one of the following: -# -# clean remove files from the build directory -# compile compile a source file into a libtool object -# execute automatically set library path, then run a program -# finish complete the installation of libtool libraries -# install install libraries or executables -# link create a library or an executable -# uninstall remove libraries from an installed directory -# -# MODE-ARGS vary depending on the MODE. -# Try `$progname --help --mode=MODE' for a more detailed description of MODE. -# -# When reporting a bug, please describe a test case to reproduce it and -# include the following information: -# -# host-triplet: $host -# shell: $SHELL -# compiler: $LTCC -# compiler flags: $LTCFLAGS -# linker: $LD (gnu? $with_gnu_ld) -# $progname: (GNU libtool) 2.2.6 -# automake: $automake_version -# autoconf: $autoconf_version -# -# Report bugs to . +# As a special exception to the GNU General Public License, if you +# distribute this file as part of a program that contains a +# configuration script generated by Autoconf, you may include it under +# the same distribution terms that you use for the rest of that program. + +basename="s,^.*/,,g" + +# Work around backward compatibility issue on IRIX 6.5. On IRIX 6.4+, sh +# is ksh but when the shell is invoked as "sh" and the current value of +# the _XPG environment variable is not equal to 1 (one), the special +# positional parameter $0, within a function call, is the name of the +# function. +progpath="$0" + +# The name of this program: +progname=`echo "$progpath" | $SED $basename` +modename="$progname" + +# Global variables: +EXIT_SUCCESS=0 +EXIT_FAILURE=1 PROGRAM=ltmain.sh PACKAGE=libtool -VERSION=2.2.6 -TIMESTAMP="" -package_revision=1.3012 +VERSION=1.5.26 +TIMESTAMP=" (1.1220.2.492 2008/01/30 06:40:56)" -# Be Bourne compatible +# Be Bourne compatible (taken from Autoconf:_AS_BOURNE_COMPATIBLE). if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then emulate sh NULLCMD=: @@ -91,261 +60,104 @@ fi BIN_SH=xpg4; export BIN_SH # for Tru64 DUALCASE=1; export DUALCASE # for MKS sh -# NLS nuisances: We save the old values to restore during execute mode. +# Check that we have a working $echo. +if test "X$1" = X--no-reexec; then + # Discard the --no-reexec flag, and continue. + shift +elif test "X$1" = X--fallback-echo; then + # Avoid inline document here, it may be left over + : +elif test "X`($echo '\t') 2>/dev/null`" = 'X\t'; then + # Yippee, $echo works! + : +else + # Restart under the correct shell, and then maybe $echo will work. + exec $SHELL "$progpath" --no-reexec ${1+"$@"} +fi + +if test "X$1" = X--fallback-echo; then + # used as fallback echo + shift + cat <&2 -} - -# func_warning arg... -# Echo program name prefixed warning message to standard error. -func_warning () -{ - $opt_warning && $ECHO "$progname${mode+: }$mode: warning: "${1+"$@"} 1>&2 - - # bash bug again: - : -} - -# func_fatal_error arg... -# Echo program name prefixed message to standard error, and exit. -func_fatal_error () -{ - func_error ${1+"$@"} - exit $EXIT_FAILURE -} - -# func_fatal_help arg... -# Echo program name prefixed message to standard error, followed by -# a help hint, and exit. -func_fatal_help () -{ - func_error ${1+"$@"} - func_fatal_error "$help" -} -help="Try \`$progname --help' for more information." ## default - - -# func_grep expression filename -# Check whether EXPRESSION matches any line of FILENAME, without output. -func_grep () -{ - $GREP "$1" "$2" >/dev/null 2>&1 -} - - -# func_mkdir_p directory-path -# Make sure the entire path to DIRECTORY-PATH is available. -func_mkdir_p () -{ - my_directory_path="$1" - my_dir_list= - - if test -n "$my_directory_path" && test "$opt_dry_run" != ":"; then - - # Protect directory names starting with `-' - case $my_directory_path in - -*) my_directory_path="./$my_directory_path" ;; - esac - - # While some portion of DIR does not yet exist... - while test ! -d "$my_directory_path"; do - # ...make a list in topmost first order. Use a colon delimited - # list incase some portion of path contains whitespace. - my_dir_list="$my_directory_path:$my_dir_list" - - # If the last portion added has no slash in it, the list is done - case $my_directory_path in */*) ;; *) break ;; esac - - # ...otherwise throw away the child directory and loop - my_directory_path=`$ECHO "X$my_directory_path" | $Xsed -e "$dirname"` - done - my_dir_list=`$ECHO "X$my_dir_list" | $Xsed -e 's,:*$,,'` - - save_mkdir_p_IFS="$IFS"; IFS=':' - for my_dir in $my_dir_list; do - IFS="$save_mkdir_p_IFS" - # mkdir can fail with a `File exist' error if two processes - # try to create one of the directories concurrently. Don't - # stop in that case! - $MKDIR "$my_dir" 2>/dev/null || : - done - IFS="$save_mkdir_p_IFS" +if test "$build_libtool_libs" != yes && test "$build_old_libs" != yes; then + $echo "$modename: not configured to build any kind of library" 1>&2 + $echo "Fatal configuration error. See the $PACKAGE docs for more information." 1>&2 + exit $EXIT_FAILURE +fi - # Bail out if we (or some other process) failed to create a directory. - test -d "$my_directory_path" || \ - func_fatal_error "Failed to create \`$1'" - fi -} +# Global variables. +mode=$default_mode +nonopt= +prev= +prevopt= +run= +show="$echo" +show_help= +execute_dlfiles= +duplicate_deps=no +preserve_args= +lo2o="s/\\.lo\$/.${objext}/" +o2lo="s/\\.${objext}\$/.lo/" +extracted_archives= +extracted_serial=0 +##################################### +# Shell function definitions: +# This seems to be the best place for them # func_mktempdir [string] # Make a temporary directory that won't clash with other running @@ -355,7 +167,7 @@ func_mktempdir () { my_template="${TMPDIR-/tmp}/${1-$progname}" - if test "$opt_dry_run" = ":"; then + if test "$run" = ":"; then # Return a directory name, but don't create it in dry-run mode my_tmpdir="${my_template}-$$" else @@ -364,787 +176,526 @@ func_mktempdir () my_tmpdir=`mktemp -d "${my_template}-XXXXXXXX" 2>/dev/null` if test ! -d "$my_tmpdir"; then - # Failing that, at least try and use $RANDOM to avoid a race - my_tmpdir="${my_template}-${RANDOM-0}$$" + # Failing that, at least try and use $RANDOM to avoid a race + my_tmpdir="${my_template}-${RANDOM-0}$$" - save_mktempdir_umask=`umask` - umask 0077 - $MKDIR "$my_tmpdir" - umask $save_mktempdir_umask + save_mktempdir_umask=`umask` + umask 0077 + $mkdir "$my_tmpdir" + umask $save_mktempdir_umask fi # If we're not in dry-run mode, bomb out on failure - test -d "$my_tmpdir" || \ - func_fatal_error "cannot create temporary directory \`$my_tmpdir'" + test -d "$my_tmpdir" || { + $echo "cannot create temporary directory \`$my_tmpdir'" 1>&2 + exit $EXIT_FAILURE + } fi - $ECHO "X$my_tmpdir" | $Xsed + $echo "X$my_tmpdir" | $Xsed } -# func_quote_for_eval arg -# Aesthetically quote ARG to be evaled later. -# This function returns two values: FUNC_QUOTE_FOR_EVAL_RESULT -# is double-quoted, suitable for a subsequent eval, whereas -# FUNC_QUOTE_FOR_EVAL_UNQUOTED_RESULT has merely all characters -# which are still active within double quotes backslashified. -func_quote_for_eval () +# func_win32_libid arg +# return the library type of file 'arg' +# +# Need a lot of goo to handle *both* DLLs and import libs +# Has to be a shell function in order to 'eat' the argument +# that is supplied when $file_magic_command is called. +func_win32_libid () { - case $1 in - *[\\\`\"\$]*) - func_quote_for_eval_unquoted_result=`$ECHO "X$1" | $Xsed -e "$sed_quote_subst"` ;; - *) - func_quote_for_eval_unquoted_result="$1" ;; - esac - - case $func_quote_for_eval_unquoted_result in - # Double-quote args containing shell metacharacters to delay - # word splitting, command substitution and and variable - # expansion for a subsequent eval. - # Many Bourne shells cannot handle close brackets correctly - # in scan sets, so we specify it separately. - *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") - func_quote_for_eval_result="\"$func_quote_for_eval_unquoted_result\"" - ;; - *) - func_quote_for_eval_result="$func_quote_for_eval_unquoted_result" + win32_libid_type="unknown" + win32_fileres=`file -L $1 2>/dev/null` + case $win32_fileres in + *ar\ archive\ import\ library*) # definitely import + win32_libid_type="x86 archive import" + ;; + *ar\ archive*) # could be an import, or static + if eval $OBJDUMP -f $1 | $SED -e '10q' 2>/dev/null | \ + $EGREP -e 'file format pe-i386(.*architecture: i386)?' >/dev/null ; then + win32_nmres=`eval $NM -f posix -A $1 | \ + $SED -n -e '1,100{ + / I /{ + s,.*,import, + p + q + } + }'` + case $win32_nmres in + import*) win32_libid_type="x86 archive import";; + *) win32_libid_type="x86 archive static";; + esac + fi + ;; + *DLL*) + win32_libid_type="x86 DLL" + ;; + *executable*) # but shell scripts are "executable" too... + case $win32_fileres in + *MS\ Windows\ PE\ Intel*) + win32_libid_type="x86 DLL" + ;; esac + ;; + esac + $echo $win32_libid_type } -# func_quote_for_expand arg -# Aesthetically quote ARG to be evaled later; same as above, -# but do not quote variable references. -func_quote_for_expand () +# func_infer_tag arg +# Infer tagged configuration to use if any are available and +# if one wasn't chosen via the "--tag" command line option. +# Only attempt this if the compiler in the base compile +# command doesn't match the default compiler. +# arg is usually of the form 'gcc ...' +func_infer_tag () { - case $1 in - *[\\\`\"]*) - my_arg=`$ECHO "X$1" | $Xsed \ - -e "$double_quote_subst" -e "$sed_double_backslash"` ;; + if test -n "$available_tags" && test -z "$tagname"; then + CC_quoted= + for arg in $CC; do + case $arg in + *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") + arg="\"$arg\"" + ;; + esac + CC_quoted="$CC_quoted $arg" + done + case $@ in + # Blanks in the command may have been stripped by the calling shell, + # but not from the CC environment variable when configure was run. + " $CC "* | "$CC "* | " `$echo $CC` "* | "`$echo $CC` "* | " $CC_quoted"* | "$CC_quoted "* | " `$echo $CC_quoted` "* | "`$echo $CC_quoted` "*) ;; + # Blanks at the start of $base_compile will cause this to fail + # if we don't check for them as well. *) - my_arg="$1" ;; - esac - - case $my_arg in - # Double-quote args containing shell metacharacters to delay - # word splitting and command substitution for a subsequent eval. - # Many Bourne shells cannot handle close brackets correctly - # in scan sets, so we specify it separately. - *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") - my_arg="\"$my_arg\"" - ;; - esac - - func_quote_for_expand_result="$my_arg" + for z in $available_tags; do + if grep "^# ### BEGIN LIBTOOL TAG CONFIG: $z$" < "$progpath" > /dev/null; then + # Evaluate the configuration. + eval "`${SED} -n -e '/^# ### BEGIN LIBTOOL TAG CONFIG: '$z'$/,/^# ### END LIBTOOL TAG CONFIG: '$z'$/p' < $progpath`" + CC_quoted= + for arg in $CC; do + # Double-quote args containing other shell metacharacters. + case $arg in + *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") + arg="\"$arg\"" + ;; + esac + CC_quoted="$CC_quoted $arg" + done + case "$@ " in + " $CC "* | "$CC "* | " `$echo $CC` "* | "`$echo $CC` "* | " $CC_quoted"* | "$CC_quoted "* | " `$echo $CC_quoted` "* | "`$echo $CC_quoted` "*) + # The compiler in the base compile command matches + # the one in the tagged configuration. + # Assume this is the tagged configuration we want. + tagname=$z + break + ;; + esac + fi + done + # If $tagname still isn't set, then no tagged configuration + # was found and let the user know that the "--tag" command + # line option must be used. + if test -z "$tagname"; then + $echo "$modename: unable to infer tagged configuration" + $echo "$modename: specify a tag with \`--tag'" 1>&2 + exit $EXIT_FAILURE +# else +# $echo "$modename: using $tagname tagged configuration" + fi + ;; + esac + fi } -# func_show_eval cmd [fail_exp] -# Unless opt_silent is true, then output CMD. Then, if opt_dryrun is -# not true, evaluate CMD. If the evaluation of CMD fails, and FAIL_EXP -# is given, then evaluate it. -func_show_eval () +# func_extract_an_archive dir oldlib +func_extract_an_archive () { - my_cmd="$1" - my_fail_exp="${2-:}" - - ${opt_silent-false} || { - func_quote_for_expand "$my_cmd" - eval "func_echo $func_quote_for_expand_result" - } + f_ex_an_ar_dir="$1"; shift + f_ex_an_ar_oldlib="$1" - if ${opt_dry_run-false}; then :; else - eval "$my_cmd" - my_status=$? - if test "$my_status" -eq 0; then :; else - eval "(exit $my_status); $my_fail_exp" - fi + $show "(cd $f_ex_an_ar_dir && $AR x $f_ex_an_ar_oldlib)" + $run eval "(cd \$f_ex_an_ar_dir && $AR x \$f_ex_an_ar_oldlib)" || exit $? + if ($AR t "$f_ex_an_ar_oldlib" | sort | sort -uc >/dev/null 2>&1); then + : + else + $echo "$modename: ERROR: object name conflicts: $f_ex_an_ar_dir/$f_ex_an_ar_oldlib" 1>&2 + exit $EXIT_FAILURE fi } - -# func_show_eval_locale cmd [fail_exp] -# Unless opt_silent is true, then output CMD. Then, if opt_dryrun is -# not true, evaluate CMD. If the evaluation of CMD fails, and FAIL_EXP -# is given, then evaluate it. Use the saved locale for evaluation. -func_show_eval_locale () +# func_extract_archives gentop oldlib ... +func_extract_archives () { - my_cmd="$1" - my_fail_exp="${2-:}" - - ${opt_silent-false} || { - func_quote_for_expand "$my_cmd" - eval "func_echo $func_quote_for_expand_result" - } - - if ${opt_dry_run-false}; then :; else - eval "$lt_user_locale - $my_cmd" - my_status=$? - eval "$lt_safe_locale" - if test "$my_status" -eq 0; then :; else - eval "(exit $my_status); $my_fail_exp" - fi + my_gentop="$1"; shift + my_oldlibs=${1+"$@"} + my_oldobjs="" + my_xlib="" + my_xabs="" + my_xdir="" + my_status="" + + $show "${rm}r $my_gentop" + $run ${rm}r "$my_gentop" + $show "$mkdir $my_gentop" + $run $mkdir "$my_gentop" + my_status=$? + if test "$my_status" -ne 0 && test ! -d "$my_gentop"; then + exit $my_status fi -} - + for my_xlib in $my_oldlibs; do + # Extract the objects. + case $my_xlib in + [\\/]* | [A-Za-z]:[\\/]*) my_xabs="$my_xlib" ;; + *) my_xabs=`pwd`"/$my_xlib" ;; + esac + my_xlib=`$echo "X$my_xlib" | $Xsed -e 's%^.*/%%'` + my_xlib_u=$my_xlib + while :; do + case " $extracted_archives " in + *" $my_xlib_u "*) + extracted_serial=`expr $extracted_serial + 1` + my_xlib_u=lt$extracted_serial-$my_xlib ;; + *) break ;; + esac + done + extracted_archives="$extracted_archives $my_xlib_u" + my_xdir="$my_gentop/$my_xlib_u" - - -# func_version -# Echo version message to standard output and exit. -func_version () -{ - $SED -n '/^# '$PROGRAM' (GNU /,/# warranty; / { - s/^# // - s/^# *$// - s/\((C)\)[ 0-9,-]*\( [1-9][0-9]*\)/\1\2/ - p - }' < "$progpath" - exit $? -} - -# func_usage -# Echo short help message to standard output and exit. -func_usage () -{ - $SED -n '/^# Usage:/,/# -h/ { - s/^# // - s/^# *$// - s/\$progname/'$progname'/ - p - }' < "$progpath" - $ECHO - $ECHO "run \`$progname --help | more' for full usage" - exit $? -} - -# func_help -# Echo long help message to standard output and exit. -func_help () -{ - $SED -n '/^# Usage:/,/# Report bugs to/ { - s/^# // - s/^# *$// - s*\$progname*'$progname'* - s*\$host*'"$host"'* - s*\$SHELL*'"$SHELL"'* - s*\$LTCC*'"$LTCC"'* - s*\$LTCFLAGS*'"$LTCFLAGS"'* - s*\$LD*'"$LD"'* - s/\$with_gnu_ld/'"$with_gnu_ld"'/ - s/\$automake_version/'"`(automake --version) 2>/dev/null |$SED 1q`"'/ - s/\$autoconf_version/'"`(autoconf --version) 2>/dev/null |$SED 1q`"'/ - p - }' < "$progpath" - exit $? -} - -# func_missing_arg argname -# Echo program name prefixed message to standard error and set global -# exit_cmd. -func_missing_arg () -{ - func_error "missing argument for $1" - exit_cmd=exit + $show "${rm}r $my_xdir" + $run ${rm}r "$my_xdir" + $show "$mkdir $my_xdir" + $run $mkdir "$my_xdir" + exit_status=$? + if test "$exit_status" -ne 0 && test ! -d "$my_xdir"; then + exit $exit_status + fi + case $host in + *-darwin*) + $show "Extracting $my_xabs" + # Do not bother doing anything if just a dry run + if test -z "$run"; then + darwin_orig_dir=`pwd` + cd $my_xdir || exit $? + darwin_archive=$my_xabs + darwin_curdir=`pwd` + darwin_base_archive=`$echo "X$darwin_archive" | $Xsed -e 's%^.*/%%'` + darwin_arches=`lipo -info "$darwin_archive" 2>/dev/null | $EGREP Architectures 2>/dev/null` + if test -n "$darwin_arches"; then + darwin_arches=`echo "$darwin_arches" | $SED -e 's/.*are://'` + darwin_arch= + $show "$darwin_base_archive has multiple architectures $darwin_arches" + for darwin_arch in $darwin_arches ; do + mkdir -p "unfat-$$/${darwin_base_archive}-${darwin_arch}" + lipo -thin $darwin_arch -output "unfat-$$/${darwin_base_archive}-${darwin_arch}/${darwin_base_archive}" "${darwin_archive}" + cd "unfat-$$/${darwin_base_archive}-${darwin_arch}" + func_extract_an_archive "`pwd`" "${darwin_base_archive}" + cd "$darwin_curdir" + $rm "unfat-$$/${darwin_base_archive}-${darwin_arch}/${darwin_base_archive}" + done # $darwin_arches + ## Okay now we have a bunch of thin objects, gotta fatten them up :) + darwin_filelist=`find unfat-$$ -type f -name \*.o -print -o -name \*.lo -print| xargs basename | sort -u | $NL2SP` + darwin_file= + darwin_files= + for darwin_file in $darwin_filelist; do + darwin_files=`find unfat-$$ -name $darwin_file -print | $NL2SP` + lipo -create -output "$darwin_file" $darwin_files + done # $darwin_filelist + ${rm}r unfat-$$ + cd "$darwin_orig_dir" + else + cd "$darwin_orig_dir" + func_extract_an_archive "$my_xdir" "$my_xabs" + fi # $darwin_arches + fi # $run + ;; + *) + func_extract_an_archive "$my_xdir" "$my_xabs" + ;; + esac + my_oldobjs="$my_oldobjs "`find $my_xdir -name \*.$objext -print -o -name \*.lo -print | $NL2SP` + done + func_extract_archives_result="$my_oldobjs" } +# End of Shell function definitions +##################################### -exit_cmd=: - - +# Darwin sucks +eval std_shrext=\"$shrext_cmds\" +disable_libs=no - -# Check that we have a working $ECHO. -if test "X$1" = X--no-reexec; then - # Discard the --no-reexec flag, and continue. - shift -elif test "X$1" = X--fallback-echo; then - # Avoid inline document here, it may be left over - : -elif test "X`{ $ECHO '\t'; } 2>/dev/null`" = 'X\t'; then - # Yippee, $ECHO works! - : -else - # Restart under the correct shell, and then maybe $ECHO will work. - exec $SHELL "$progpath" --no-reexec ${1+"$@"} -fi - -if test "X$1" = X--fallback-echo; then - # used as fallback echo +# Parse our command line options once, thoroughly. +while test "$#" -gt 0 +do + arg="$1" shift - cat <&2 + exit $EXIT_FAILURE + ;; + esac -# If this variable is set in any of the actions, the command in it -# will be execed at the end. This prevents here-documents from being -# left over by shells. -exec_cmd= + case $tagname in + CC) + # Don't test for the "default" C tag, as we know, it's there, but + # not specially marked. + ;; + *) + if grep "^# ### BEGIN LIBTOOL TAG CONFIG: $tagname$" < "$progpath" > /dev/null; then + taglist="$taglist $tagname" + # Evaluate the configuration. + eval "`${SED} -n -e '/^# ### BEGIN LIBTOOL TAG CONFIG: '$tagname'$/,/^# ### END LIBTOOL TAG CONFIG: '$tagname'$/p' < $progpath`" + else + $echo "$progname: ignoring unknown tag $tagname" 1>&2 + fi + ;; + esac + ;; + *) + eval "$prev=\$arg" + ;; + esac -# func_fatal_configuration arg... -# Echo program name prefixed message to standard error, followed by -# a configuration failure hint, and exit. -func_fatal_configuration () -{ - func_error ${1+"$@"} - func_error "See the $PACKAGE documentation for more information." - func_fatal_error "Fatal configuration error." -} + prev= + prevopt= + continue + fi + # Have we seen a non-optional argument yet? + case $arg in + --help) + show_help=yes + ;; -# func_config -# Display the configuration for all the tags in this script. -func_config () -{ - re_begincf='^# ### BEGIN LIBTOOL' - re_endcf='^# ### END LIBTOOL' + --version) + echo "\ +$PROGRAM (GNU $PACKAGE) $VERSION$TIMESTAMP - # Default configuration. - $SED "1,/$re_begincf CONFIG/d;/$re_endcf CONFIG/,\$d" < "$progpath" +Copyright (C) 2008 Free Software Foundation, Inc. +This is free software; see the source for copying conditions. There is NO +warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." + exit $? + ;; + --config) + ${SED} -e '1,/^# ### BEGIN LIBTOOL CONFIG/d' -e '/^# ### END LIBTOOL CONFIG/,$d' $progpath # Now print the configurations for the tags. for tagname in $taglist; do - $SED -n "/$re_begincf TAG CONFIG: $tagname\$/,/$re_endcf TAG CONFIG: $tagname\$/p" < "$progpath" + ${SED} -n -e "/^# ### BEGIN LIBTOOL TAG CONFIG: $tagname$/,/^# ### END LIBTOOL TAG CONFIG: $tagname$/p" < "$progpath" done - exit $? -} + ;; -# func_features -# Display the features supported by this script. -func_features () -{ - $ECHO "host: $host" + --debug) + $echo "$progname: enabling shell trace mode" + set -x + preserve_args="$preserve_args $arg" + ;; + + --dry-run | -n) + run=: + ;; + + --features) + $echo "host: $host" if test "$build_libtool_libs" = yes; then - $ECHO "enable shared libraries" + $echo "enable shared libraries" else - $ECHO "disable shared libraries" + $echo "disable shared libraries" fi if test "$build_old_libs" = yes; then - $ECHO "enable static libraries" + $echo "enable static libraries" else - $ECHO "disable static libraries" + $echo "disable static libraries" fi - exit $? -} - -# func_enable_tag tagname -# Verify that TAGNAME is valid, and either flag an error and exit, or -# enable the TAGNAME tag. We also add TAGNAME to the global $taglist -# variable here. -func_enable_tag () -{ - # Global variable: - tagname="$1" - - re_begincf="^# ### BEGIN LIBTOOL TAG CONFIG: $tagname\$" - re_endcf="^# ### END LIBTOOL TAG CONFIG: $tagname\$" - sed_extractcf="/$re_begincf/,/$re_endcf/p" + ;; - # Validate tagname. - case $tagname in - *[!-_A-Za-z0-9,/]*) - func_fatal_error "invalid tag name: $tagname" - ;; - esac + --finish) mode="finish" ;; - # Don't test for the "default" C tag, as we know it's - # there but not specially marked. - case $tagname in - CC) ;; - *) - if $GREP "$re_begincf" "$progpath" >/dev/null 2>&1; then - taglist="$taglist $tagname" - - # Evaluate the configuration. Be careful to quote the path - # and the sed script, to avoid splitting on whitespace, but - # also don't use non-portable quotes within backquotes within - # quotes we have to do it in 2 steps: - extractedcf=`$SED -n -e "$sed_extractcf" < "$progpath"` - eval "$extractedcf" - else - func_error "ignoring unknown tag $tagname" - fi - ;; - esac -} + --mode) prevopt="--mode" prev=mode ;; + --mode=*) mode="$optarg" ;; -# Parse options once, thoroughly. This comes as soon as possible in -# the script to make things like `libtool --version' happen quickly. -{ + --preserve-dup-deps) duplicate_deps="yes" ;; - # Shorthand for --mode=foo, only valid as the first argument - case $1 in - clean|clea|cle|cl) - shift; set dummy --mode clean ${1+"$@"}; shift + --quiet | --silent) + show=: + preserve_args="$preserve_args $arg" ;; - compile|compil|compi|comp|com|co|c) - shift; set dummy --mode compile ${1+"$@"}; shift - ;; - execute|execut|execu|exec|exe|ex|e) - shift; set dummy --mode execute ${1+"$@"}; shift + + --tag) + prevopt="--tag" + prev=tag + preserve_args="$preserve_args --tag" ;; - finish|finis|fini|fin|fi|f) - shift; set dummy --mode finish ${1+"$@"}; shift + --tag=*) + set tag "$optarg" ${1+"$@"} + shift + prev=tag + preserve_args="$preserve_args --tag" ;; - install|instal|insta|inst|ins|in|i) - shift; set dummy --mode install ${1+"$@"}; shift + + -dlopen) + prevopt="-dlopen" + prev=execute_dlfiles ;; - link|lin|li|l) - shift; set dummy --mode link ${1+"$@"}; shift + + -*) + $echo "$modename: unrecognized option \`$arg'" 1>&2 + $echo "$help" 1>&2 + exit $EXIT_FAILURE ;; - uninstall|uninstal|uninsta|uninst|unins|unin|uni|un|u) - shift; set dummy --mode uninstall ${1+"$@"}; shift + + *) + nonopt="$arg" + break ;; esac +done - # Parse non-mode specific arguments: - while test "$#" -gt 0; do - opt="$1" - shift - - case $opt in - --config) func_config ;; - - --debug) preserve_args="$preserve_args $opt" - func_echo "enabling shell trace mode" - opt_debug='set -x' - $opt_debug - ;; - - -dlopen) test "$#" -eq 0 && func_missing_arg "$opt" && break - execute_dlfiles="$execute_dlfiles $1" - shift - ;; - - --dry-run | -n) opt_dry_run=: ;; - --features) func_features ;; - --finish) mode="finish" ;; - - --mode) test "$#" -eq 0 && func_missing_arg "$opt" && break - case $1 in - # Valid mode arguments: - clean) ;; - compile) ;; - execute) ;; - finish) ;; - install) ;; - link) ;; - relink) ;; - uninstall) ;; - - # Catch anything else as an error - *) func_error "invalid argument for $opt" - exit_cmd=exit - break - ;; - esac - - mode="$1" - shift - ;; - - --preserve-dup-deps) - opt_duplicate_deps=: ;; - - --quiet|--silent) preserve_args="$preserve_args $opt" - opt_silent=: - ;; - - --verbose| -v) preserve_args="$preserve_args $opt" - opt_silent=false - ;; - - --tag) test "$#" -eq 0 && func_missing_arg "$opt" && break - preserve_args="$preserve_args $opt $1" - func_enable_tag "$1" # tagname is set here - shift - ;; - - # Separate optargs to long options: - -dlopen=*|--mode=*|--tag=*) - func_opt_split "$opt" - set dummy "$func_opt_split_opt" "$func_opt_split_arg" ${1+"$@"} - shift - ;; - - -\?|-h) func_usage ;; - --help) opt_help=: ;; - --version) func_version ;; +if test -n "$prevopt"; then + $echo "$modename: option \`$prevopt' requires an argument" 1>&2 + $echo "$help" 1>&2 + exit $EXIT_FAILURE +fi - -*) func_fatal_help "unrecognized option \`$opt'" ;; +case $disable_libs in +no) + ;; +shared) + build_libtool_libs=no + build_old_libs=yes + ;; +static) + build_old_libs=`case $build_libtool_libs in yes) echo no;; *) echo yes;; esac` + ;; +esac - *) nonopt="$opt" - break - ;; - esac - done +# If this variable is set in any of the actions, the command in it +# will be execed at the end. This prevents here-documents from being +# left over by shells. +exec_cmd= +if test -z "$show_help"; then - case $host in - *cygwin* | *mingw* | *pw32* | *cegcc*) - # don't eliminate duplications in $postdeps and $predeps - opt_duplicate_compiler_generated_deps=: + # Infer the operation mode. + if test -z "$mode"; then + $echo "*** Warning: inferring the mode of operation is deprecated." 1>&2 + $echo "*** Future versions of Libtool will require --mode=MODE be specified." 1>&2 + case $nonopt in + *cc | cc* | *++ | gcc* | *-gcc* | g++* | xlc*) + mode=link + for arg + do + case $arg in + -c) + mode=compile + break + ;; + esac + done ;; - *) - opt_duplicate_compiler_generated_deps=$opt_duplicate_deps + *db | *dbx | *strace | *truss) + mode=execute ;; - esac - - # Having warned about all mis-specified options, bail out if - # anything was wrong. - $exit_cmd $EXIT_FAILURE -} + *install*|cp|mv) + mode=install + ;; + *rm) + mode=uninstall + ;; + *) + # If we have no mode, but dlfiles were specified, then do execute mode. + test -n "$execute_dlfiles" && mode=execute -# func_check_version_match -# Ensure that we are using m4 macros, and libtool script from the same -# release of libtool. -func_check_version_match () -{ - if test "$package_revision" != "$macro_revision"; then - if test "$VERSION" != "$macro_version"; then - if test -z "$macro_version"; then - cat >&2 <<_LT_EOF -$progname: Version mismatch error. This is $PACKAGE $VERSION, but the -$progname: definition of this LT_INIT comes from an older release. -$progname: You should recreate aclocal.m4 with macros from $PACKAGE $VERSION -$progname: and run autoconf again. -_LT_EOF - else - cat >&2 <<_LT_EOF -$progname: Version mismatch error. This is $PACKAGE $VERSION, but the -$progname: definition of this LT_INIT comes from $PACKAGE $macro_version. -$progname: You should recreate aclocal.m4 with macros from $PACKAGE $VERSION -$progname: and run autoconf again. -_LT_EOF + # Just use the default operation mode. + if test -z "$mode"; then + if test -n "$nonopt"; then + $echo "$modename: warning: cannot infer operation mode from \`$nonopt'" 1>&2 + else + $echo "$modename: warning: cannot infer operation mode without MODE-ARGS" 1>&2 + fi fi - else - cat >&2 <<_LT_EOF -$progname: Version mismatch error. This is $PACKAGE $VERSION, revision $package_revision, -$progname: but the definition of this LT_INIT comes from revision $macro_revision. -$progname: You should recreate aclocal.m4 with macros from revision $package_revision -$progname: of $PACKAGE $VERSION and run autoconf again. -_LT_EOF - fi - - exit $EXIT_MISMATCH - fi -} - - -## ----------- ## -## Main. ## -## ----------- ## - -$opt_help || { - # Sanity checks first: - func_check_version_match - - if test "$build_libtool_libs" != yes && test "$build_old_libs" != yes; then - func_fatal_configuration "not configured to build any kind of library" + ;; + esac fi - test -z "$mode" && func_fatal_error "error: you must specify a MODE." - - - # Darwin sucks - eval std_shrext=\"$shrext_cmds\" - - # Only execute mode is allowed to have -dlopen flags. if test -n "$execute_dlfiles" && test "$mode" != execute; then - func_error "unrecognized option \`-dlopen'" - $ECHO "$help" 1>&2 + $echo "$modename: unrecognized option \`-dlopen'" 1>&2 + $echo "$help" 1>&2 exit $EXIT_FAILURE fi # Change the help message to a mode-specific one. generic_help="$help" - help="Try \`$progname --help --mode=$mode' for more information." -} + help="Try \`$modename --help --mode=$mode' for more information." + # These modes are in order of execution frequency so that they run quickly. + case $mode in + # libtool compile mode + compile) + modename="$modename: compile" + # Get the compilation command and the source file. + base_compile= + srcfile="$nonopt" # always keep a non-empty value in "srcfile" + suppress_opt=yes + suppress_output= + arg_mode=normal + libobj= + later= -# func_lalib_p file -# True iff FILE is a libtool `.la' library or `.lo' object file. -# This function is only a basic sanity check; it will hardly flush out -# determined imposters. -func_lalib_p () -{ - test -f "$1" && - $SED -e 4q "$1" 2>/dev/null \ - | $GREP "^# Generated by .*$PACKAGE" > /dev/null 2>&1 -} + for arg + do + case $arg_mode in + arg ) + # do not "continue". Instead, add this to base_compile + lastarg="$arg" + arg_mode=normal + ;; -# func_lalib_unsafe_p file -# True iff FILE is a libtool `.la' library or `.lo' object file. -# This function implements the same check as func_lalib_p without -# resorting to external programs. To this end, it redirects stdin and -# closes it afterwards, without saving the original file descriptor. -# As a safety measure, use it only where a negative result would be -# fatal anyway. Works if `file' does not exist. -func_lalib_unsafe_p () -{ - lalib_p=no - if test -f "$1" && test -r "$1" && exec 5<&0 <"$1"; then - for lalib_p_l in 1 2 3 4 - do - read lalib_p_line - case "$lalib_p_line" in - \#\ Generated\ by\ *$PACKAGE* ) lalib_p=yes; break;; - esac - done - exec 0<&5 5<&- - fi - test "$lalib_p" = yes -} + target ) + libobj="$arg" + arg_mode=normal + continue + ;; -# func_ltwrapper_script_p file -# True iff FILE is a libtool wrapper script -# This function is only a basic sanity check; it will hardly flush out -# determined imposters. -func_ltwrapper_script_p () -{ - func_lalib_p "$1" -} + normal ) + # Accept any command-line options. + case $arg in + -o) + if test -n "$libobj" ; then + $echo "$modename: you cannot specify \`-o' more than once" 1>&2 + exit $EXIT_FAILURE + fi + arg_mode=target + continue + ;; -# func_ltwrapper_executable_p file -# True iff FILE is a libtool wrapper executable -# This function is only a basic sanity check; it will hardly flush out -# determined imposters. -func_ltwrapper_executable_p () -{ - func_ltwrapper_exec_suffix= - case $1 in - *.exe) ;; - *) func_ltwrapper_exec_suffix=.exe ;; - esac - $GREP "$magic_exe" "$1$func_ltwrapper_exec_suffix" >/dev/null 2>&1 -} - -# func_ltwrapper_scriptname file -# Assumes file is an ltwrapper_executable -# uses $file to determine the appropriate filename for a -# temporary ltwrapper_script. -func_ltwrapper_scriptname () -{ - func_ltwrapper_scriptname_result="" - if func_ltwrapper_executable_p "$1"; then - func_dirname_and_basename "$1" "" "." - func_stripname '' '.exe' "$func_basename_result" - func_ltwrapper_scriptname_result="$func_dirname_result/$objdir/${func_stripname_result}_ltshwrapper" - fi -} - -# func_ltwrapper_p file -# True iff FILE is a libtool wrapper script or wrapper executable -# This function is only a basic sanity check; it will hardly flush out -# determined imposters. -func_ltwrapper_p () -{ - func_ltwrapper_script_p "$1" || func_ltwrapper_executable_p "$1" -} - - -# func_execute_cmds commands fail_cmd -# Execute tilde-delimited COMMANDS. -# If FAIL_CMD is given, eval that upon failure. -# FAIL_CMD may read-access the current command in variable CMD! -func_execute_cmds () -{ - $opt_debug - save_ifs=$IFS; IFS='~' - for cmd in $1; do - IFS=$save_ifs - eval cmd=\"$cmd\" - func_show_eval "$cmd" "${2-:}" - done - IFS=$save_ifs -} - - -# func_source file -# Source FILE, adding directory component if necessary. -# Note that it is not necessary on cygwin/mingw to append a dot to -# FILE even if both FILE and FILE.exe exist: automatic-append-.exe -# behavior happens only for exec(3), not for open(2)! Also, sourcing -# `FILE.' does not work on cygwin managed mounts. -func_source () -{ - $opt_debug - case $1 in - */* | *\\*) . "$1" ;; - *) . "./$1" ;; - esac -} - - -# func_infer_tag arg -# Infer tagged configuration to use if any are available and -# if one wasn't chosen via the "--tag" command line option. -# Only attempt this if the compiler in the base compile -# command doesn't match the default compiler. -# arg is usually of the form 'gcc ...' -func_infer_tag () -{ - $opt_debug - if test -n "$available_tags" && test -z "$tagname"; then - CC_quoted= - for arg in $CC; do - func_quote_for_eval "$arg" - CC_quoted="$CC_quoted $func_quote_for_eval_result" - done - case $@ in - # Blanks in the command may have been stripped by the calling shell, - # but not from the CC environment variable when configure was run. - " $CC "* | "$CC "* | " `$ECHO $CC` "* | "`$ECHO $CC` "* | " $CC_quoted"* | "$CC_quoted "* | " `$ECHO $CC_quoted` "* | "`$ECHO $CC_quoted` "*) ;; - # Blanks at the start of $base_compile will cause this to fail - # if we don't check for them as well. - *) - for z in $available_tags; do - if $GREP "^# ### BEGIN LIBTOOL TAG CONFIG: $z$" < "$progpath" > /dev/null; then - # Evaluate the configuration. - eval "`${SED} -n -e '/^# ### BEGIN LIBTOOL TAG CONFIG: '$z'$/,/^# ### END LIBTOOL TAG CONFIG: '$z'$/p' < $progpath`" - CC_quoted= - for arg in $CC; do - # Double-quote args containing other shell metacharacters. - func_quote_for_eval "$arg" - CC_quoted="$CC_quoted $func_quote_for_eval_result" - done - case "$@ " in - " $CC "* | "$CC "* | " `$ECHO $CC` "* | "`$ECHO $CC` "* | " $CC_quoted"* | "$CC_quoted "* | " `$ECHO $CC_quoted` "* | "`$ECHO $CC_quoted` "*) - # The compiler in the base compile command matches - # the one in the tagged configuration. - # Assume this is the tagged configuration we want. - tagname=$z - break - ;; - esac - fi - done - # If $tagname still isn't set, then no tagged configuration - # was found and let the user know that the "--tag" command - # line option must be used. - if test -z "$tagname"; then - func_echo "unable to infer tagged configuration" - func_fatal_error "specify a tag with \`--tag'" -# else -# func_verbose "using $tagname tagged configuration" - fi - ;; - esac - fi -} - - - -# func_write_libtool_object output_name pic_name nonpic_name -# Create a libtool object file (analogous to a ".la" file), -# but don't create it if we're doing a dry run. -func_write_libtool_object () -{ - write_libobj=${1} - if test "$build_libtool_libs" = yes; then - write_lobj=\'${2}\' - else - write_lobj=none - fi - - if test "$build_old_libs" = yes; then - write_oldobj=\'${3}\' - else - write_oldobj=none - fi - - $opt_dry_run || { - cat >${write_libobj}T <\?\'\ \ ]*|*]*|"") + arg="\"$arg\"" + ;; + esac + lastarg="$lastarg $arg" done IFS="$save_ifs" - func_stripname ' ' '' "$lastarg" - lastarg=$func_stripname_result + lastarg=`$echo "X$lastarg" | $Xsed -e "s/^ //"` # Add the arguments to base_compile. base_compile="$base_compile $lastarg" continue ;; - *) + * ) # Accept the current argument as the source file. # The previous "srcfile" becomes the current argument. # @@ -1187,42 +744,66 @@ func_mode_compile () esac # case $arg_mode # Aesthetically quote the previous argument. - func_quote_for_eval "$lastarg" - base_compile="$base_compile $func_quote_for_eval_result" + lastarg=`$echo "X$lastarg" | $Xsed -e "$sed_quote_subst"` + + case $lastarg in + # Double-quote args containing other shell metacharacters. + # Many Bourne shells cannot handle close brackets correctly + # in scan sets, and some SunOS ksh mistreat backslash-escaping + # in scan sets (worked around with variable expansion), + # and furthermore cannot handle '|' '&' '(' ')' in scan sets + # at all, so we specify them separately. + *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") + lastarg="\"$lastarg\"" + ;; + esac + + base_compile="$base_compile $lastarg" done # for arg case $arg_mode in arg) - func_fatal_error "you must specify an argument for -Xcompile" + $echo "$modename: you must specify an argument for -Xcompile" + exit $EXIT_FAILURE ;; target) - func_fatal_error "you must specify a target with \`-o'" + $echo "$modename: you must specify a target with \`-o'" 1>&2 + exit $EXIT_FAILURE ;; *) # Get the name of the library object. - test -z "$libobj" && { - func_basename "$srcfile" - libobj="$func_basename_result" - } + [ -z "$libobj" ] && libobj=`$echo "X$srcfile" | $Xsed -e 's%^.*/%%'` ;; esac # Recognize several different file suffixes. # If the user specifies -o file.o, it is replaced with file.lo + xform='[cCFSifmso]' case $libobj in - *.[cCFSifmso] | \ - *.ada | *.adb | *.ads | *.asm | \ - *.c++ | *.cc | *.ii | *.class | *.cpp | *.cxx | \ - *.[fF][09]? | *.for | *.java | *.obj | *.sx) - func_xform "$libobj" - libobj=$func_xform_result - ;; + *.ada) xform=ada ;; + *.adb) xform=adb ;; + *.ads) xform=ads ;; + *.asm) xform=asm ;; + *.c++) xform=c++ ;; + *.cc) xform=cc ;; + *.ii) xform=ii ;; + *.class) xform=class ;; + *.cpp) xform=cpp ;; + *.cxx) xform=cxx ;; + *.[fF][09]?) xform=[fF][09]. ;; + *.for) xform=for ;; + *.java) xform=java ;; + *.obj) xform=obj ;; + *.sx) xform=sx ;; esac + libobj=`$echo "X$libobj" | $Xsed -e "s/\.$xform$/.lo/"` + case $libobj in - *.lo) func_lo2o "$libobj"; obj=$func_lo2o_result ;; + *.lo) obj=`$echo "X$libobj" | $Xsed -e "$lo2o"` ;; *) - func_fatal_error "cannot determine name of library object from \`$libobj'" + $echo "$modename: cannot determine name of library object from \`$libobj'" 1>&2 + exit $EXIT_FAILURE ;; esac @@ -1230,15 +811,7 @@ func_mode_compile () for arg in $later; do case $arg in - -shared) - test "$build_libtool_libs" != yes && \ - func_fatal_configuration "can not build a shared library" - build_old_libs=no - continue - ;; - -static) - build_libtool_libs=no build_old_libs=yes continue ;; @@ -1255,17 +828,28 @@ func_mode_compile () esac done - func_quote_for_eval "$libobj" - test "X$libobj" != "X$func_quote_for_eval_result" \ - && $ECHO "X$libobj" | $GREP '[]~#^*{};<>?"'"'"' &()|`$[]' \ - && func_warning "libobj name \`$libobj' may not contain shell special characters." - func_dirname_and_basename "$obj" "/" "" - objname="$func_basename_result" - xdir="$func_dirname_result" + qlibobj=`$echo "X$libobj" | $Xsed -e "$sed_quote_subst"` + case $qlibobj in + *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") + qlibobj="\"$qlibobj\"" ;; + esac + test "X$libobj" != "X$qlibobj" \ + && $echo "X$libobj" | grep '[]~#^*{};<>?"'"'"' &()|`$[]' \ + && $echo "$modename: libobj name \`$libobj' may not contain shell special characters." + objname=`$echo "X$obj" | $Xsed -e 's%^.*/%%'` + xdir=`$echo "X$obj" | $Xsed -e 's%/[^/]*$%%'` + if test "X$xdir" = "X$obj"; then + xdir= + else + xdir=$xdir/ + fi lobj=${xdir}$objdir/$objname - test -z "$base_compile" && \ - func_fatal_help "you must specify a compilation command" + if test -z "$base_compile"; then + $echo "$modename: you must specify a compilation command" 1>&2 + $echo "$help" 1>&2 + exit $EXIT_FAILURE + fi # Delete any leftover library objects. if test "$build_old_libs" = yes; then @@ -1274,9 +858,12 @@ func_mode_compile () removelist="$lobj $libobj ${libobj}T" fi + $run $rm $removelist + trap "$run $rm $removelist; exit $EXIT_FAILURE" 1 2 15 + # On Cygwin there's no "real" PIC flag so we must build both object types case $host_os in - cygwin* | mingw* | pw32* | os2* | cegcc*) + cygwin* | mingw* | pw32* | os2*) pic_mode=default ;; esac @@ -1288,8 +875,10 @@ func_mode_compile () # Calculate the filename of the output object if compiler does # not support -o with -c if test "$compiler_c_o" = no; then - output_obj=`$ECHO "X$srcfile" | $Xsed -e 's%^.*/%%' -e 's%\.[^.]*$%%'`.${objext} + output_obj=`$echo "X$srcfile" | $Xsed -e 's%^.*/%%' -e 's%\.[^.]*$%%'`.${objext} lockfile="$output_obj.lock" + removelist="$removelist $output_obj $lockfile" + trap "$run $rm $removelist; exit $EXIT_FAILURE" 1 2 15 else output_obj= need_locks=no @@ -1299,13 +888,13 @@ func_mode_compile () # Lock this critical section if it is needed # We use this script file to make the link, it avoids creating a new file if test "$need_locks" = yes; then - until $opt_dry_run || ln "$progpath" "$lockfile" 2>/dev/null; do - func_echo "Waiting for $lockfile to be removed" + until $run ln "$progpath" "$lockfile" 2>/dev/null; do + $show "Waiting for $lockfile to be removed" sleep 2 done elif test "$need_locks" = warn; then if test -f "$lockfile"; then - $ECHO "\ + $echo "\ *** ERROR, $lockfile exists and contains: `cat $lockfile 2>/dev/null` @@ -1316,22 +905,34 @@ repeat this compilation, it may succeed, by chance, but you had better avoid parallel builds (make -j) in this platform, or get a better compiler." - $opt_dry_run || $RM $removelist + $run $rm $removelist exit $EXIT_FAILURE fi - removelist="$removelist $output_obj" - $ECHO "$srcfile" > "$lockfile" + $echo "$srcfile" > "$lockfile" fi - $opt_dry_run || $RM $removelist - removelist="$removelist $lockfile" - trap '$opt_dry_run || $RM $removelist; exit $EXIT_FAILURE' 1 2 15 - if test -n "$fix_srcfile_path"; then eval srcfile=\"$fix_srcfile_path\" fi - func_quote_for_eval "$srcfile" - qsrcfile=$func_quote_for_eval_result + qsrcfile=`$echo "X$srcfile" | $Xsed -e "$sed_quote_subst"` + case $qsrcfile in + *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") + qsrcfile="\"$qsrcfile\"" ;; + esac + + $run $rm "$libobj" "${libobj}T" + + # Create a libtool object file (analogous to a ".la" file), + # but don't create it if we're doing a dry run. + test -z "$run" && cat > ${libobj}T </dev/null`" != "X$srcfile"; then - $ECHO "\ + $echo "\ *** ERROR, $lockfile contains: `cat $lockfile 2>/dev/null` @@ -1371,27 +985,45 @@ repeat this compilation, it may succeed, by chance, but you had better avoid parallel builds (make -j) in this platform, or get a better compiler." - $opt_dry_run || $RM $removelist + $run $rm $removelist exit $EXIT_FAILURE fi # Just move the object if needed, then go on to compile the next one if test -n "$output_obj" && test "X$output_obj" != "X$lobj"; then - func_show_eval '$MV "$output_obj" "$lobj"' \ - 'error=$?; $opt_dry_run || $RM $removelist; exit $error' + $show "$mv $output_obj $lobj" + if $run $mv $output_obj $lobj; then : + else + error=$? + $run $rm $removelist + exit $error + fi fi + # Append the name of the PIC object to the libtool object file. + test -z "$run" && cat >> ${libobj}T <> ${libobj}T </dev/null`" != "X$srcfile"; then - $ECHO "\ + $echo "\ *** ERROR, $lockfile contains: `cat $lockfile 2>/dev/null` @@ -1420,6777 +1057,5477 @@ repeat this compilation, it may succeed, by chance, but you had better avoid parallel builds (make -j) in this platform, or get a better compiler." - $opt_dry_run || $RM $removelist + $run $rm $removelist exit $EXIT_FAILURE fi # Just move the object if needed if test -n "$output_obj" && test "X$output_obj" != "X$obj"; then - func_show_eval '$MV "$output_obj" "$obj"' \ - 'error=$?; $opt_dry_run || $RM $removelist; exit $error' + $show "$mv $output_obj $obj" + if $run $mv $output_obj $obj; then : + else + error=$? + $run $rm $removelist + exit $error + fi fi + + # Append the name of the non-PIC object the libtool object file. + # Only append if the libtool object file exists. + test -z "$run" && cat >> ${libobj}T <> ${libobj}T <&2 + fi + if test -n "$link_static_flag"; then + dlopen_self=$dlopen_self_static + fi + prefer_static_libs=yes + ;; + -static) + if test -z "$pic_flag" && test -n "$link_static_flag"; then + dlopen_self=$dlopen_self_static + fi + prefer_static_libs=built + ;; + -static-libtool-libs) + if test -z "$pic_flag" && test -n "$link_static_flag"; then + dlopen_self=$dlopen_self_static + fi + prefer_static_libs=yes + ;; + esac + build_libtool_libs=no + build_old_libs=yes + break + ;; + esac + done -Complete the installation of libtool libraries. + # See if our shared archives depend on static archives. + test -n "$old_archive_from_new_cmds" && build_old_libs=yes -Each LIBDIR is a directory that contains libtool libraries. + # Go through the arguments, transforming them on the way. + while test "$#" -gt 0; do + arg="$1" + shift + case $arg in + *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") + qarg=\"`$echo "X$arg" | $Xsed -e "$sed_quote_subst"`\" ### testsuite: skip nested quoting test + ;; + *) qarg=$arg ;; + esac + libtool_args="$libtool_args $qarg" -The commands that this mode executes may require superuser privileges. Use -the \`--dry-run' option if you just want to see what would be executed." - ;; + # If the previous option needs an argument, assign it. + if test -n "$prev"; then + case $prev in + output) + compile_command="$compile_command @OUTPUT@" + finalize_command="$finalize_command @OUTPUT@" + ;; + esac - install) - $ECHO \ -"Usage: $progname [OPTION]... --mode=install INSTALL-COMMAND... + case $prev in + dlfiles|dlprefiles) + if test "$preload" = no; then + # Add the symbol object into the linking commands. + compile_command="$compile_command @SYMFILE@" + finalize_command="$finalize_command @SYMFILE@" + preload=yes + fi + case $arg in + *.la | *.lo) ;; # We handle these cases below. + force) + if test "$dlself" = no; then + dlself=needless + export_dynamic=yes + fi + prev= + continue + ;; + self) + if test "$prev" = dlprefiles; then + dlself=yes + elif test "$prev" = dlfiles && test "$dlopen_self" != yes; then + dlself=yes + else + dlself=needless + export_dynamic=yes + fi + prev= + continue + ;; + *) + if test "$prev" = dlfiles; then + dlfiles="$dlfiles $arg" + else + dlprefiles="$dlprefiles $arg" + fi + prev= + continue + ;; + esac + ;; + expsyms) + export_symbols="$arg" + if test ! -f "$arg"; then + $echo "$modename: symbol file \`$arg' does not exist" + exit $EXIT_FAILURE + fi + prev= + continue + ;; + expsyms_regex) + export_symbols_regex="$arg" + prev= + continue + ;; + inst_prefix) + inst_prefix_dir="$arg" + prev= + continue + ;; + precious_regex) + precious_files_regex="$arg" + prev= + continue + ;; + release) + release="-$arg" + prev= + continue + ;; + objectlist) + if test -f "$arg"; then + save_arg=$arg + moreargs= + for fil in `cat $save_arg` + do +# moreargs="$moreargs $fil" + arg=$fil + # A libtool-controlled object. -Install executables or libraries. + # Check to see that this really is a libtool object. + if (${SED} -e '2q' $arg | grep "^# Generated by .*$PACKAGE") >/dev/null 2>&1; then + pic_object= + non_pic_object= -INSTALL-COMMAND is the installation command. The first component should be -either the \`install' or \`cp' program. + # Read the .lo file + # If there is no directory component, then add one. + case $arg in + */* | *\\*) . $arg ;; + *) . ./$arg ;; + esac -The following components of INSTALL-COMMAND are treated specially: + if test -z "$pic_object" || \ + test -z "$non_pic_object" || + test "$pic_object" = none && \ + test "$non_pic_object" = none; then + $echo "$modename: cannot find name of object for \`$arg'" 1>&2 + exit $EXIT_FAILURE + fi - -inst-prefix PREFIX-DIR Use PREFIX-DIR as a staging area for installation + # Extract subdirectory from the argument. + xdir=`$echo "X$arg" | $Xsed -e 's%/[^/]*$%%'` + if test "X$xdir" = "X$arg"; then + xdir= + else + xdir="$xdir/" + fi -The rest of the components are interpreted as arguments to that command (only -BSD-compatible install options are recognized)." - ;; + if test "$pic_object" != none; then + # Prepend the subdirectory the object is found in. + pic_object="$xdir$pic_object" - link) - $ECHO \ -"Usage: $progname [OPTION]... --mode=link LINK-COMMAND... + if test "$prev" = dlfiles; then + if test "$build_libtool_libs" = yes && test "$dlopen_support" = yes; then + dlfiles="$dlfiles $pic_object" + prev= + continue + else + # If libtool objects are unsupported, then we need to preload. + prev=dlprefiles + fi + fi -Link object files or libraries together to form another library, or to -create an executable program. + # CHECK ME: I think I busted this. -Ossama + if test "$prev" = dlprefiles; then + # Preload the old-style object. + dlprefiles="$dlprefiles $pic_object" + prev= + fi -LINK-COMMAND is a command using the C compiler that you would use to create -a program from several object files. + # A PIC object. + libobjs="$libobjs $pic_object" + arg="$pic_object" + fi -The following components of LINK-COMMAND are treated specially: + # Non-PIC object. + if test "$non_pic_object" != none; then + # Prepend the subdirectory the object is found in. + non_pic_object="$xdir$non_pic_object" - -all-static do not do any dynamic linking at all - -avoid-version do not add a version suffix if possible - -dlopen FILE \`-dlpreopen' FILE if it cannot be dlopened at runtime - -dlpreopen FILE link in FILE and add its symbols to lt_preloaded_symbols - -export-dynamic allow symbols from OUTPUT-FILE to be resolved with dlsym(3) - -export-symbols SYMFILE - try to export only the symbols listed in SYMFILE - -export-symbols-regex REGEX - try to export only the symbols matching REGEX - -LLIBDIR search LIBDIR for required installed libraries - -lNAME OUTPUT-FILE requires the installed library libNAME - -module build a library that can dlopened - -no-fast-install disable the fast-install mode - -no-install link a not-installable executable - -no-undefined declare that a library does not refer to external symbols - -o OUTPUT-FILE create OUTPUT-FILE from the specified objects - -objectlist FILE Use a list of object files found in FILE to specify objects - -precious-files-regex REGEX - don't remove output files matching REGEX - -release RELEASE specify package release information - -rpath LIBDIR the created library will eventually be installed in LIBDIR - -R[ ]LIBDIR add LIBDIR to the runtime path of programs and libraries - -shared only do dynamic linking of libtool libraries - -shrext SUFFIX override the standard shared library file extension - -static do not do any dynamic linking of uninstalled libtool libraries - -static-libtool-libs - do not do any dynamic linking of libtool libraries - -version-info CURRENT[:REVISION[:AGE]] - specify library version info [each variable defaults to 0] - -weak LIBNAME declare that the target provides the LIBNAME interface + # A standard non-PIC object + non_pic_objects="$non_pic_objects $non_pic_object" + if test -z "$pic_object" || test "$pic_object" = none ; then + arg="$non_pic_object" + fi + else + # If the PIC object exists, use it instead. + # $xdir was prepended to $pic_object above. + non_pic_object="$pic_object" + non_pic_objects="$non_pic_objects $non_pic_object" + fi + else + # Only an error if not doing a dry-run. + if test -z "$run"; then + $echo "$modename: \`$arg' is not a valid libtool object" 1>&2 + exit $EXIT_FAILURE + else + # Dry-run case. -All other options (arguments beginning with \`-') are ignored. + # Extract subdirectory from the argument. + xdir=`$echo "X$arg" | $Xsed -e 's%/[^/]*$%%'` + if test "X$xdir" = "X$arg"; then + xdir= + else + xdir="$xdir/" + fi -Every other argument is treated as a filename. Files ending in \`.la' are -treated as uninstalled libtool libraries, other files are standard or library -object files. - -If the OUTPUT-FILE ends in \`.la', then a libtool library is created, -only library objects (\`.lo' files) may be specified, and \`-rpath' is -required, except when creating a convenience library. - -If OUTPUT-FILE ends in \`.a' or \`.lib', then a standard library is created -using \`ar' and \`ranlib', or on Windows using \`lib'. - -If OUTPUT-FILE ends in \`.lo' or \`.${objext}', then a reloadable object file -is created, otherwise an executable program is created." - ;; - - uninstall) - $ECHO \ -"Usage: $progname [OPTION]... --mode=uninstall RM [RM-OPTION]... FILE... + pic_object=`$echo "X${xdir}${objdir}/${arg}" | $Xsed -e "$lo2o"` + non_pic_object=`$echo "X${xdir}${arg}" | $Xsed -e "$lo2o"` + libobjs="$libobjs $pic_object" + non_pic_objects="$non_pic_objects $non_pic_object" + fi + fi + done + else + $echo "$modename: link input file \`$save_arg' does not exist" + exit $EXIT_FAILURE + fi + arg=$save_arg + prev= + continue + ;; + rpath | xrpath) + # We need an absolute path. + case $arg in + [\\/]* | [A-Za-z]:[\\/]*) ;; + *) + $echo "$modename: only absolute run-paths are allowed" 1>&2 + exit $EXIT_FAILURE + ;; + esac + if test "$prev" = rpath; then + case "$rpath " in + *" $arg "*) ;; + *) rpath="$rpath $arg" ;; + esac + else + case "$xrpath " in + *" $arg "*) ;; + *) xrpath="$xrpath $arg" ;; + esac + fi + prev= + continue + ;; + xcompiler) + compiler_flags="$compiler_flags $qarg" + prev= + compile_command="$compile_command $qarg" + finalize_command="$finalize_command $qarg" + continue + ;; + xlinker) + linker_flags="$linker_flags $qarg" + compiler_flags="$compiler_flags $wl$qarg" + prev= + compile_command="$compile_command $wl$qarg" + finalize_command="$finalize_command $wl$qarg" + continue + ;; + xcclinker) + linker_flags="$linker_flags $qarg" + compiler_flags="$compiler_flags $qarg" + prev= + compile_command="$compile_command $qarg" + finalize_command="$finalize_command $qarg" + continue + ;; + shrext) + shrext_cmds="$arg" + prev= + continue + ;; + darwin_framework|darwin_framework_skip) + test "$prev" = "darwin_framework" && compiler_flags="$compiler_flags $arg" + compile_command="$compile_command $arg" + finalize_command="$finalize_command $arg" + prev= + continue + ;; + *) + eval "$prev=\"\$arg\"" + prev= + continue + ;; + esac + fi # test -n "$prev" -Remove libraries from an installation directory. + prevarg="$arg" -RM is the name of the program to use to delete files associated with each FILE -(typically \`/bin/rm'). RM-OPTIONS are options (such as \`-f') to be passed -to RM. + case $arg in + -all-static) + if test -n "$link_static_flag"; then + compile_command="$compile_command $link_static_flag" + finalize_command="$finalize_command $link_static_flag" + fi + continue + ;; -If FILE is a libtool library, all the files associated with it are deleted. -Otherwise, only FILE itself is deleted using RM." - ;; + -allow-undefined) + # FIXME: remove this flag sometime in the future. + $echo "$modename: \`-allow-undefined' is deprecated because it is the default" 1>&2 + continue + ;; - *) - func_fatal_help "invalid operation mode \`$mode'" - ;; - esac + -avoid-version) + avoid_version=yes + continue + ;; - $ECHO - $ECHO "Try \`$progname --help' for more information about other modes." + -dlopen) + prev=dlfiles + continue + ;; - exit $? -} + -dlpreopen) + prev=dlprefiles + continue + ;; - # Now that we've collected a possible --mode arg, show help if necessary - $opt_help && func_mode_help + -export-dynamic) + export_dynamic=yes + continue + ;; + -export-symbols | -export-symbols-regex) + if test -n "$export_symbols" || test -n "$export_symbols_regex"; then + $echo "$modename: more than one -exported-symbols argument is not allowed" + exit $EXIT_FAILURE + fi + if test "X$arg" = "X-export-symbols"; then + prev=expsyms + else + prev=expsyms_regex + fi + continue + ;; -# func_mode_execute arg... -func_mode_execute () -{ - $opt_debug - # The first argument is the command name. - cmd="$nonopt" - test -z "$cmd" && \ - func_fatal_help "you must specify a COMMAND" + -framework|-arch|-isysroot) + case " $CC " in + *" ${arg} ${1} "* | *" ${arg} ${1} "*) + prev=darwin_framework_skip ;; + *) compiler_flags="$compiler_flags $arg" + prev=darwin_framework ;; + esac + compile_command="$compile_command $arg" + finalize_command="$finalize_command $arg" + continue + ;; - # Handle -dlopen flags immediately. - for file in $execute_dlfiles; do - test -f "$file" \ - || func_fatal_help "\`$file' is not a file" + -inst-prefix-dir) + prev=inst_prefix + continue + ;; - dir= - case $file in - *.la) - # Check to see that this really is a libtool archive. - func_lalib_unsafe_p "$file" \ - || func_fatal_help "\`$lib' is not a valid libtool archive" + # The native IRIX linker understands -LANG:*, -LIST:* and -LNO:* + # so, if we see these flags be careful not to treat them like -L + -L[A-Z][A-Z]*:*) + case $with_gcc/$host in + no/*-*-irix* | /*-*-irix*) + compile_command="$compile_command $arg" + finalize_command="$finalize_command $arg" + ;; + esac + continue + ;; - # Read the libtool library. - dlname= - library_names= - func_source "$file" + -L*) + dir=`$echo "X$arg" | $Xsed -e 's/^-L//'` + # We need an absolute path. + case $dir in + [\\/]* | [A-Za-z]:[\\/]*) ;; + *) + absdir=`cd "$dir" && pwd` + if test -z "$absdir"; then + $echo "$modename: cannot determine absolute directory name of \`$dir'" 1>&2 + absdir="$dir" + notinst_path="$notinst_path $dir" + fi + dir="$absdir" + ;; + esac + case "$deplibs " in + *" -L$dir "*) ;; + *) + deplibs="$deplibs -L$dir" + lib_search_path="$lib_search_path $dir" + ;; + esac + case $host in + *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2*) + testbindir=`$echo "X$dir" | $Xsed -e 's*/lib$*/bin*'` + case :$dllsearchpath: in + *":$dir:"*) ;; + *) dllsearchpath="$dllsearchpath:$dir";; + esac + case :$dllsearchpath: in + *":$testbindir:"*) ;; + *) dllsearchpath="$dllsearchpath:$testbindir";; + esac + ;; + esac + continue + ;; - # Skip this library if it cannot be dlopened. - if test -z "$dlname"; then - # Warn if it was a shared library. - test -n "$library_names" && \ - func_warning "\`$file' was not linked with \`-export-dynamic'" - continue + -l*) + if test "X$arg" = "X-lc" || test "X$arg" = "X-lm"; then + case $host in + *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-beos*) + # These systems don't actually have a C or math library (as such) + continue + ;; + *-*-os2*) + # These systems don't actually have a C library (as such) + test "X$arg" = "X-lc" && continue + ;; + *-*-openbsd* | *-*-freebsd* | *-*-dragonfly*) + # Do not include libc due to us having libc/libc_r. + test "X$arg" = "X-lc" && continue + ;; + *-*-rhapsody* | *-*-darwin1.[012]) + # Rhapsody C and math libraries are in the System framework + deplibs="$deplibs -framework System" + continue + ;; + *-*-sco3.2v5* | *-*-sco5v6*) + # Causes problems with __ctype + test "X$arg" = "X-lc" && continue + ;; + *-*-sysv4.2uw2* | *-*-sysv5* | *-*-unixware* | *-*-OpenUNIX*) + # Compiler inserts libc in the correct place for threads to work + test "X$arg" = "X-lc" && continue + ;; + esac + elif test "X$arg" = "X-lc_r"; then + case $host in + *-*-openbsd* | *-*-freebsd* | *-*-dragonfly*) + # Do not include libc_r directly, use -pthread flag. + continue + ;; + esac fi + deplibs="$deplibs $arg" + continue + ;; - func_dirname "$file" "" "." - dir="$func_dirname_result" - - if test -f "$dir/$objdir/$dlname"; then - dir="$dir/$objdir" - else - if test ! -f "$dir/$dlname"; then - func_fatal_error "cannot find \`$dlname' in \`$dir' or \`$dir/$objdir'" - fi - fi + # Tru64 UNIX uses -model [arg] to determine the layout of C++ + # classes, name mangling, and exception handling. + -model) + compile_command="$compile_command $arg" + compiler_flags="$compiler_flags $arg" + finalize_command="$finalize_command $arg" + prev=xcompiler + continue ;; - *.lo) - # Just add the directory containing the .lo file. - func_dirname "$file" "" "." - dir="$func_dirname_result" + -mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe|-threads) + compiler_flags="$compiler_flags $arg" + compile_command="$compile_command $arg" + finalize_command="$finalize_command $arg" + continue ;; - *) - func_warning "\`-dlopen' is ignored for non-libtool libraries and objects" + -multi_module) + single_module="${wl}-multi_module" continue ;; - esac - # Get the absolute pathname. - absdir=`cd "$dir" && pwd` - test -n "$absdir" && dir="$absdir" + -module) + module=yes + continue + ;; - # Now add the directory to shlibpath_var. - if eval "test -z \"\$$shlibpath_var\""; then - eval "$shlibpath_var=\"\$dir\"" - else - eval "$shlibpath_var=\"\$dir:\$$shlibpath_var\"" - fi - done + # -64, -mips[0-9] enable 64-bit mode on the SGI compiler + # -r[0-9][0-9]* specifies the processor on the SGI compiler + # -xarch=*, -xtarget=* enable 64-bit mode on the Sun compiler + # +DA*, +DD* enable 64-bit mode on the HP compiler + # -q* pass through compiler args for the IBM compiler + # -m* pass through architecture-specific compiler args for GCC + # -m*, -t[45]*, -txscale* pass through architecture-specific + # compiler args for GCC + # -p, -pg, --coverage, -fprofile-* pass through profiling flag for GCC + # -F/path gives path to uninstalled frameworks, gcc on darwin + # @file GCC response files + -64|-mips[0-9]|-r[0-9][0-9]*|-xarch=*|-xtarget=*|+DA*|+DD*|-q*|-m*| \ + -t[45]*|-txscale*|-p|-pg|--coverage|-fprofile-*|-F*|@*) - # This variable tells wrapper scripts just to set shlibpath_var - # rather than running their programs. - libtool_execute_magic="$magic" + # Unknown arguments in both finalize_command and compile_command need + # to be aesthetically quoted because they are evaled later. + arg=`$echo "X$arg" | $Xsed -e "$sed_quote_subst"` + case $arg in + *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") + arg="\"$arg\"" + ;; + esac + compile_command="$compile_command $arg" + finalize_command="$finalize_command $arg" + compiler_flags="$compiler_flags $arg" + continue + ;; - # Check if any of the arguments is a wrapper script. - args= - for file - do - case $file in - -*) ;; - *) - # Do a test to see if this is really a libtool program. - if func_ltwrapper_script_p "$file"; then - func_source "$file" - # Transform arg to wrapped name. - file="$progdir/$program" - elif func_ltwrapper_executable_p "$file"; then - func_ltwrapper_scriptname "$file" - func_source "$func_ltwrapper_scriptname_result" - # Transform arg to wrapped name. - file="$progdir/$program" - fi + -shrext) + prev=shrext + continue ;; - esac - # Quote arguments (to preserve shell metacharacters). - func_quote_for_eval "$file" - args="$args $func_quote_for_eval_result" - done - - if test "X$opt_dry_run" = Xfalse; then - if test -n "$shlibpath_var"; then - # Export the shlibpath_var. - eval "export $shlibpath_var" - fi - - # Restore saved environment variables - for lt_var in LANG LANGUAGE LC_ALL LC_CTYPE LC_COLLATE LC_MESSAGES - do - eval "if test \"\${save_$lt_var+set}\" = set; then - $lt_var=\$save_$lt_var; export $lt_var - else - $lt_unset $lt_var - fi" - done - - # Now prepare to actually exec the command. - exec_cmd="\$cmd$args" - else - # Display what would be done. - if test -n "$shlibpath_var"; then - eval "\$ECHO \"\$shlibpath_var=\$$shlibpath_var\"" - $ECHO "export $shlibpath_var" - fi - $ECHO "$cmd$args" - exit $EXIT_SUCCESS - fi -} - -test "$mode" = execute && func_mode_execute ${1+"$@"} - - -# func_mode_finish arg... -func_mode_finish () -{ - $opt_debug - libdirs="$nonopt" - admincmds= - - if test -n "$finish_cmds$finish_eval" && test -n "$libdirs"; then - for dir - do - libdirs="$libdirs $dir" - done - - for libdir in $libdirs; do - if test -n "$finish_cmds"; then - # Do each command in the finish commands. - func_execute_cmds "$finish_cmds" 'admincmds="$admincmds -'"$cmd"'"' - fi - if test -n "$finish_eval"; then - # Do the single finish_eval. - eval cmds=\"$finish_eval\" - $opt_dry_run || eval "$cmds" || admincmds="$admincmds - $cmds" - fi - done - fi - # Exit here if they wanted silent mode. - $opt_silent && exit $EXIT_SUCCESS + -no-fast-install) + fast_install=no + continue + ;; - $ECHO "X----------------------------------------------------------------------" | $Xsed - $ECHO "Libraries have been installed in:" - for libdir in $libdirs; do - $ECHO " $libdir" - done - $ECHO - $ECHO "If you ever happen to want to link against installed libraries" - $ECHO "in a given directory, LIBDIR, you must either use libtool, and" - $ECHO "specify the full pathname of the library, or use the \`-LLIBDIR'" - $ECHO "flag during linking and do at least one of the following:" - if test -n "$shlibpath_var"; then - $ECHO " - add LIBDIR to the \`$shlibpath_var' environment variable" - $ECHO " during execution" - fi - if test -n "$runpath_var"; then - $ECHO " - add LIBDIR to the \`$runpath_var' environment variable" - $ECHO " during linking" - fi - if test -n "$hardcode_libdir_flag_spec"; then - libdir=LIBDIR - eval flag=\"$hardcode_libdir_flag_spec\" + -no-install) + case $host in + *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-*-darwin*) + # The PATH hackery in wrapper scripts is required on Windows + # and Darwin in order for the loader to find any dlls it needs. + $echo "$modename: warning: \`-no-install' is ignored for $host" 1>&2 + $echo "$modename: warning: assuming \`-no-fast-install' instead" 1>&2 + fast_install=no + ;; + *) no_install=yes ;; + esac + continue + ;; - $ECHO " - use the \`$flag' linker flag" - fi - if test -n "$admincmds"; then - $ECHO " - have your system administrator run these commands:$admincmds" - fi - if test -f /etc/ld.so.conf; then - $ECHO " - have your system administrator add LIBDIR to \`/etc/ld.so.conf'" - fi - $ECHO + -no-undefined) + allow_undefined=no + continue + ;; - $ECHO "See any operating system documentation about shared libraries for" - case $host in - solaris2.[6789]|solaris2.1[0-9]) - $ECHO "more information, such as the ld(1), crle(1) and ld.so(8) manual" - $ECHO "pages." + -objectlist) + prev=objectlist + continue ;; - *) - $ECHO "more information, such as the ld(1) and ld.so(8) manual pages." - ;; - esac - $ECHO "X----------------------------------------------------------------------" | $Xsed - exit $EXIT_SUCCESS -} -test "$mode" = finish && func_mode_finish ${1+"$@"} + -o) prev=output ;; + -precious-files-regex) + prev=precious_regex + continue + ;; -# func_mode_install arg... -func_mode_install () -{ - $opt_debug - # There may be an optional sh(1) argument at the beginning of - # install_prog (especially on Windows NT). - if test "$nonopt" = "$SHELL" || test "$nonopt" = /bin/sh || - # Allow the use of GNU shtool's install command. - $ECHO "X$nonopt" | $GREP shtool >/dev/null; then - # Aesthetically quote it. - func_quote_for_eval "$nonopt" - install_prog="$func_quote_for_eval_result " - arg=$1 - shift - else - install_prog= - arg=$nonopt - fi + -release) + prev=release + continue + ;; - # The real first argument should be the name of the installation program. - # Aesthetically quote it. - func_quote_for_eval "$arg" - install_prog="$install_prog$func_quote_for_eval_result" + -rpath) + prev=rpath + continue + ;; - # We need to accept at least all the BSD install flags. - dest= - files= - opts= - prev= - install_type= - isdir=no - stripme= - for arg - do - if test -n "$dest"; then - files="$files $dest" - dest=$arg + -R) + prev=xrpath continue - fi + ;; - case $arg in - -d) isdir=yes ;; - -f) - case " $install_prog " in - *[\\\ /]cp\ *) ;; - *) prev=$arg ;; + -R*) + dir=`$echo "X$arg" | $Xsed -e 's/^-R//'` + # We need an absolute path. + case $dir in + [\\/]* | [A-Za-z]:[\\/]*) ;; + *) + $echo "$modename: only absolute run-paths are allowed" 1>&2 + exit $EXIT_FAILURE + ;; + esac + case "$xrpath " in + *" $dir "*) ;; + *) xrpath="$xrpath $dir" ;; esac + continue ;; - -g | -m | -o) - prev=$arg + + -static | -static-libtool-libs) + # The effects of -static are defined in a previous loop. + # We used to do the same as -all-static on platforms that + # didn't have a PIC flag, but the assumption that the effects + # would be equivalent was wrong. It would break on at least + # Digital Unix and AIX. + continue ;; - -s) - stripme=" -s" + + -thread-safe) + thread_safe=yes continue ;; - -*) + + -version-info) + prev=vinfo + continue ;; - *) - # If the previous option needed an argument, then skip it. - if test -n "$prev"; then - prev= - else - dest=$arg - continue - fi + -version-number) + prev=vinfo + vinfo_number=yes + continue ;; - esac - - # Aesthetically quote the argument. - func_quote_for_eval "$arg" - install_prog="$install_prog $func_quote_for_eval_result" - done - test -z "$install_prog" && \ - func_fatal_help "you must specify an install program" + -Wc,*) + args=`$echo "X$arg" | $Xsed -e "$sed_quote_subst" -e 's/^-Wc,//'` + arg= + save_ifs="$IFS"; IFS=',' + for flag in $args; do + IFS="$save_ifs" + case $flag in + *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") + flag="\"$flag\"" + ;; + esac + arg="$arg $wl$flag" + compiler_flags="$compiler_flags $flag" + done + IFS="$save_ifs" + arg=`$echo "X$arg" | $Xsed -e "s/^ //"` + ;; - test -n "$prev" && \ - func_fatal_help "the \`$prev' option requires an argument" + -Wl,*) + args=`$echo "X$arg" | $Xsed -e "$sed_quote_subst" -e 's/^-Wl,//'` + arg= + save_ifs="$IFS"; IFS=',' + for flag in $args; do + IFS="$save_ifs" + case $flag in + *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") + flag="\"$flag\"" + ;; + esac + arg="$arg $wl$flag" + compiler_flags="$compiler_flags $wl$flag" + linker_flags="$linker_flags $flag" + done + IFS="$save_ifs" + arg=`$echo "X$arg" | $Xsed -e "s/^ //"` + ;; - if test -z "$files"; then - if test -z "$dest"; then - func_fatal_help "no file or destination specified" - else - func_fatal_help "you must specify a destination" - fi - fi + -Xcompiler) + prev=xcompiler + continue + ;; - # Strip any trailing slash from the destination. - func_stripname '' '/' "$dest" - dest=$func_stripname_result + -Xlinker) + prev=xlinker + continue + ;; - # Check to see that the destination is a directory. - test -d "$dest" && isdir=yes - if test "$isdir" = yes; then - destdir="$dest" - destname= - else - func_dirname_and_basename "$dest" "" "." - destdir="$func_dirname_result" - destname="$func_basename_result" + -XCClinker) + prev=xcclinker + continue + ;; - # Not a directory, so check to see that there is only one file specified. - set dummy $files; shift - test "$#" -gt 1 && \ - func_fatal_help "\`$dest' is not a directory" - fi - case $destdir in - [\\/]* | [A-Za-z]:[\\/]*) ;; - *) - for file in $files; do - case $file in - *.lo) ;; - *) - func_fatal_help "\`$destdir' must be an absolute directory name" + # Some other compiler flag. + -* | +*) + # Unknown arguments in both finalize_command and compile_command need + # to be aesthetically quoted because they are evaled later. + arg=`$echo "X$arg" | $Xsed -e "$sed_quote_subst"` + case $arg in + *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") + arg="\"$arg\"" ;; esac - done - ;; - esac - - # This variable tells wrapper scripts just to set variables rather - # than running their programs. - libtool_install_magic="$magic" - - staticlibs= - future_libdirs= - current_libdirs= - for file in $files; do + ;; - # Do each installation. - case $file in - *.$libext) - # Do the static libraries later. - staticlibs="$staticlibs $file" + *.$objext) + # A standard object. + objs="$objs $arg" ;; - *.la) - # Check to see that this really is a libtool archive. - func_lalib_unsafe_p "$file" \ - || func_fatal_help "\`$file' is not a valid libtool archive" + *.lo) + # A libtool-controlled object. - library_names= - old_library= - relink_command= - func_source "$file" + # Check to see that this really is a libtool object. + if (${SED} -e '2q' $arg | grep "^# Generated by .*$PACKAGE") >/dev/null 2>&1; then + pic_object= + non_pic_object= - # Add the libdir to current_libdirs if it is the destination. - if test "X$destdir" = "X$libdir"; then - case "$current_libdirs " in - *" $libdir "*) ;; - *) current_libdirs="$current_libdirs $libdir" ;; - esac - else - # Note the libdir as a future libdir. - case "$future_libdirs " in - *" $libdir "*) ;; - *) future_libdirs="$future_libdirs $libdir" ;; + # Read the .lo file + # If there is no directory component, then add one. + case $arg in + */* | *\\*) . $arg ;; + *) . ./$arg ;; esac - fi - - func_dirname "$file" "/" "" - dir="$func_dirname_result" - dir="$dir$objdir" - - if test -n "$relink_command"; then - # Determine the prefix the user has applied to our future dir. - inst_prefix_dir=`$ECHO "X$destdir" | $Xsed -e "s%$libdir\$%%"` - # Don't allow the user to place us outside of our expected - # location b/c this prevents finding dependent libraries that - # are installed to the same prefix. - # At present, this check doesn't affect windows .dll's that - # are installed into $libdir/../bin (currently, that works fine) - # but it's something to keep an eye on. - test "$inst_prefix_dir" = "$destdir" && \ - func_fatal_error "error: cannot install \`$file' to a directory not ending in $libdir" + if test -z "$pic_object" || \ + test -z "$non_pic_object" || + test "$pic_object" = none && \ + test "$non_pic_object" = none; then + $echo "$modename: cannot find name of object for \`$arg'" 1>&2 + exit $EXIT_FAILURE + fi - if test -n "$inst_prefix_dir"; then - # Stick the inst_prefix_dir data into the link command. - relink_command=`$ECHO "X$relink_command" | $Xsed -e "s%@inst_prefix_dir@%-inst-prefix-dir $inst_prefix_dir%"` - else - relink_command=`$ECHO "X$relink_command" | $Xsed -e "s%@inst_prefix_dir@%%"` + # Extract subdirectory from the argument. + xdir=`$echo "X$arg" | $Xsed -e 's%/[^/]*$%%'` + if test "X$xdir" = "X$arg"; then + xdir= + else + xdir="$xdir/" fi - func_warning "relinking \`$file'" - func_show_eval "$relink_command" \ - 'func_fatal_error "error: relink \`$file'\'' with the above command before installing it"' - fi + if test "$pic_object" != none; then + # Prepend the subdirectory the object is found in. + pic_object="$xdir$pic_object" - # See the names of the shared library. - set dummy $library_names; shift - if test -n "$1"; then - realname="$1" - shift + if test "$prev" = dlfiles; then + if test "$build_libtool_libs" = yes && test "$dlopen_support" = yes; then + dlfiles="$dlfiles $pic_object" + prev= + continue + else + # If libtool objects are unsupported, then we need to preload. + prev=dlprefiles + fi + fi - srcname="$realname" - test -n "$relink_command" && srcname="$realname"T + # CHECK ME: I think I busted this. -Ossama + if test "$prev" = dlprefiles; then + # Preload the old-style object. + dlprefiles="$dlprefiles $pic_object" + prev= + fi - # Install the shared library and build the symlinks. - func_show_eval "$install_prog $dir/$srcname $destdir/$realname" \ - 'exit $?' - tstripme="$stripme" - case $host_os in - cygwin* | mingw* | pw32* | cegcc*) - case $realname in - *.dll.a) - tstripme="" - ;; - esac - ;; - esac - if test -n "$tstripme" && test -n "$striplib"; then - func_show_eval "$striplib $destdir/$realname" 'exit $?' + # A PIC object. + libobjs="$libobjs $pic_object" + arg="$pic_object" fi - if test "$#" -gt 0; then - # Delete the old symlinks, and create new ones. - # Try `ln -sf' first, because the `ln' binary might depend on - # the symlink we replace! Solaris /bin/ln does not understand -f, - # so we also need to try rm && ln -s. - for linkname - do - test "$linkname" != "$realname" \ - && func_show_eval "(cd $destdir && { $LN_S -f $realname $linkname || { $RM $linkname && $LN_S $realname $linkname; }; })" - done + # Non-PIC object. + if test "$non_pic_object" != none; then + # Prepend the subdirectory the object is found in. + non_pic_object="$xdir$non_pic_object" + + # A standard non-PIC object + non_pic_objects="$non_pic_objects $non_pic_object" + if test -z "$pic_object" || test "$pic_object" = none ; then + arg="$non_pic_object" + fi + else + # If the PIC object exists, use it instead. + # $xdir was prepended to $pic_object above. + non_pic_object="$pic_object" + non_pic_objects="$non_pic_objects $non_pic_object" fi + else + # Only an error if not doing a dry-run. + if test -z "$run"; then + $echo "$modename: \`$arg' is not a valid libtool object" 1>&2 + exit $EXIT_FAILURE + else + # Dry-run case. - # Do each command in the postinstall commands. - lib="$destdir/$realname" - func_execute_cmds "$postinstall_cmds" 'exit $?' - fi + # Extract subdirectory from the argument. + xdir=`$echo "X$arg" | $Xsed -e 's%/[^/]*$%%'` + if test "X$xdir" = "X$arg"; then + xdir= + else + xdir="$xdir/" + fi - # Install the pseudo-library for information purposes. - func_basename "$file" - name="$func_basename_result" - instname="$dir/$name"i - func_show_eval "$install_prog $instname $destdir/$name" 'exit $?' + pic_object=`$echo "X${xdir}${objdir}/${arg}" | $Xsed -e "$lo2o"` + non_pic_object=`$echo "X${xdir}${arg}" | $Xsed -e "$lo2o"` + libobjs="$libobjs $pic_object" + non_pic_objects="$non_pic_objects $non_pic_object" + fi + fi + ;; - # Maybe install the static library, too. - test -n "$old_library" && staticlibs="$staticlibs $dir/$old_library" + *.$libext) + # An archive. + deplibs="$deplibs $arg" + old_deplibs="$old_deplibs $arg" + continue ;; - *.lo) - # Install (i.e. copy) a libtool object. + *.la) + # A libtool-controlled library. - # Figure out destination file name, if it wasn't already specified. - if test -n "$destname"; then - destfile="$destdir/$destname" + if test "$prev" = dlfiles; then + # This library was specified with -dlopen. + dlfiles="$dlfiles $arg" + prev= + elif test "$prev" = dlprefiles; then + # The library was specified with -dlpreopen. + dlprefiles="$dlprefiles $arg" + prev= else - func_basename "$file" - destfile="$func_basename_result" - destfile="$destdir/$destfile" + deplibs="$deplibs $arg" fi + continue + ;; - # Deduce the name of the destination old-style object file. - case $destfile in - *.lo) - func_lo2o "$destfile" - staticdest=$func_lo2o_result - ;; - *.$objext) - staticdest="$destfile" - destfile= - ;; - *) - func_fatal_help "cannot copy a libtool object to \`$destfile'" + # Some other compiler argument. + *) + # Unknown arguments in both finalize_command and compile_command need + # to be aesthetically quoted because they are evaled later. + arg=`$echo "X$arg" | $Xsed -e "$sed_quote_subst"` + case $arg in + *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") + arg="\"$arg\"" ;; esac - - # Install the libtool object if requested. - test -n "$destfile" && \ - func_show_eval "$install_prog $file $destfile" 'exit $?' - - # Install the old object if enabled. - if test "$build_old_libs" = yes; then - # Deduce the name of the old-style object file. - func_lo2o "$file" - staticobj=$func_lo2o_result - func_show_eval "$install_prog \$staticobj \$staticdest" 'exit $?' - fi - exit $EXIT_SUCCESS ;; + esac # arg - *) - # Figure out destination file name, if it wasn't already specified. - if test -n "$destname"; then - destfile="$destdir/$destname" - else - func_basename "$file" - destfile="$func_basename_result" - destfile="$destdir/$destfile" - fi + # Now actually substitute the argument into the commands. + if test -n "$arg"; then + compile_command="$compile_command $arg" + finalize_command="$finalize_command $arg" + fi + done # argument parsing loop - # If the file is missing, and there is a .exe on the end, strip it - # because it is most likely a libtool script we actually want to - # install - stripped_ext="" - case $file in - *.exe) - if test ! -f "$file"; then - func_stripname '' '.exe' "$file" - file=$func_stripname_result - stripped_ext=".exe" - fi - ;; - esac + if test -n "$prev"; then + $echo "$modename: the \`$prevarg' option requires an argument" 1>&2 + $echo "$help" 1>&2 + exit $EXIT_FAILURE + fi - # Do a test to see if this is really a libtool program. - case $host in - *cygwin* | *mingw*) - if func_ltwrapper_executable_p "$file"; then - func_ltwrapper_scriptname "$file" - wrapper=$func_ltwrapper_scriptname_result - else - func_stripname '' '.exe' "$file" - wrapper=$func_stripname_result - fi - ;; - *) - wrapper=$file - ;; - esac - if func_ltwrapper_script_p "$wrapper"; then - notinst_deplibs= - relink_command= + if test "$export_dynamic" = yes && test -n "$export_dynamic_flag_spec"; then + eval arg=\"$export_dynamic_flag_spec\" + compile_command="$compile_command $arg" + finalize_command="$finalize_command $arg" + fi - func_source "$wrapper" + oldlibs= + # calculate the name of the file, without its directory + outputname=`$echo "X$output" | $Xsed -e 's%^.*/%%'` + libobjs_save="$libobjs" - # Check the variables that should have been set. - test -z "$generated_by_libtool_version" && \ - func_fatal_error "invalid libtool wrapper script \`$wrapper'" + if test -n "$shlibpath_var"; then + # get the directories listed in $shlibpath_var + eval shlib_search_path=\`\$echo \"X\${$shlibpath_var}\" \| \$Xsed -e \'s/:/ /g\'\` + else + shlib_search_path= + fi + eval sys_lib_search_path=\"$sys_lib_search_path_spec\" + eval sys_lib_dlsearch_path=\"$sys_lib_dlsearch_path_spec\" - finalize=yes - for lib in $notinst_deplibs; do - # Check to see that each library is installed. - libdir= - if test -f "$lib"; then - func_source "$lib" - fi - libfile="$libdir/"`$ECHO "X$lib" | $Xsed -e 's%^.*/%%g'` ### testsuite: skip nested quoting test - if test -n "$libdir" && test ! -f "$libfile"; then - func_warning "\`$lib' has not been installed in \`$libdir'" - finalize=no - fi - done - - relink_command= - func_source "$wrapper" - - outputname= - if test "$fast_install" = no && test -n "$relink_command"; then - $opt_dry_run || { - if test "$finalize" = yes; then - tmpdir=`func_mktempdir` - func_basename "$file$stripped_ext" - file="$func_basename_result" - outputname="$tmpdir/$file" - # Replace the output file specification. - relink_command=`$ECHO "X$relink_command" | $Xsed -e 's%@OUTPUT@%'"$outputname"'%g'` - - $opt_silent || { - func_quote_for_expand "$relink_command" - eval "func_echo $func_quote_for_expand_result" - } - if eval "$relink_command"; then : - else - func_error "error: relink \`$file' with the above command before installing it" - $opt_dry_run || ${RM}r "$tmpdir" - continue - fi - file="$outputname" - else - func_warning "cannot relink \`$file'" - fi - } - else - # Install the binary that we compiled earlier. - file=`$ECHO "X$file$stripped_ext" | $Xsed -e "s%\([^/]*\)$%$objdir/\1%"` - fi - fi - - # remove .exe since cygwin /usr/bin/install will append another - # one anyway - case $install_prog,$host in - */usr/bin/install*,*cygwin*) - case $file:$destfile in - *.exe:*.exe) - # this is ok - ;; - *.exe:*) - destfile=$destfile.exe - ;; - *:*.exe) - func_stripname '' '.exe' "$destfile" - destfile=$func_stripname_result - ;; - esac - ;; - esac - func_show_eval "$install_prog\$stripme \$file \$destfile" 'exit $?' - $opt_dry_run || if test -n "$outputname"; then - ${RM}r "$tmpdir" - fi - ;; - esac - done - - for file in $staticlibs; do - func_basename "$file" - name="$func_basename_result" - - # Set up the ranlib parameters. - oldlib="$destdir/$name" - - func_show_eval "$install_prog \$file \$oldlib" 'exit $?' - - if test -n "$stripme" && test -n "$old_striplib"; then - func_show_eval "$old_striplib $oldlib" 'exit $?' - fi - - # Do each command in the postinstall commands. - func_execute_cmds "$old_postinstall_cmds" 'exit $?' - done - - test -n "$future_libdirs" && \ - func_warning "remember to run \`$progname --finish$future_libdirs'" - - if test -n "$current_libdirs"; then - # Maybe just do a dry run. - $opt_dry_run && current_libdirs=" -n$current_libdirs" - exec_cmd='$SHELL $progpath $preserve_args --finish$current_libdirs' + output_objdir=`$echo "X$output" | $Xsed -e 's%/[^/]*$%%'` + if test "X$output_objdir" = "X$output"; then + output_objdir="$objdir" else - exit $EXIT_SUCCESS + output_objdir="$output_objdir/$objdir" fi -} - -test "$mode" = install && func_mode_install ${1+"$@"} - - -# func_generate_dlsyms outputname originator pic_p -# Extract symbols from dlprefiles and create ${outputname}S.o with -# a dlpreopen symbol table. -func_generate_dlsyms () -{ - $opt_debug - my_outputname="$1" - my_originator="$2" - my_pic_p="${3-no}" - my_prefix=`$ECHO "$my_originator" | sed 's%[^a-zA-Z0-9]%_%g'` - my_dlsyms= - - if test -n "$dlfiles$dlprefiles" || test "$dlself" != no; then - if test -n "$NM" && test -n "$global_symbol_pipe"; then - my_dlsyms="${my_outputname}S.c" - else - func_error "not configured to extract global symbols from dlpreopened files" + # Create the object directory. + if test ! -d "$output_objdir"; then + $show "$mkdir $output_objdir" + $run $mkdir $output_objdir + exit_status=$? + if test "$exit_status" -ne 0 && test ! -d "$output_objdir"; then + exit $exit_status fi fi - if test -n "$my_dlsyms"; then - case $my_dlsyms in - "") ;; - *.c) - # Discover the nlist of each of the dlfiles. - nlist="$output_objdir/${my_outputname}.nm" - - func_show_eval "$RM $nlist ${nlist}S ${nlist}T" - - # Parse the name list into a source file. - func_verbose "creating $output_objdir/$my_dlsyms" - - $opt_dry_run || $ECHO > "$output_objdir/$my_dlsyms" "\ -/* $my_dlsyms - symbol resolution table for \`$my_outputname' dlsym emulation. */ -/* Generated by $PROGRAM (GNU $PACKAGE$TIMESTAMP) $VERSION */ - -#ifdef __cplusplus -extern \"C\" { -#endif - -/* External symbol declarations for the compiler. */\ -" - - if test "$dlself" = yes; then - func_verbose "generating symbol list for \`$output'" - - $opt_dry_run || echo ': @PROGRAM@ ' > "$nlist" - - # Add our own program objects to the symbol list. - progfiles=`$ECHO "X$objs$old_deplibs" | $SP2NL | $Xsed -e "$lo2o" | $NL2SP` - for progfile in $progfiles; do - func_verbose "extracting global C symbols from \`$progfile'" - $opt_dry_run || eval "$NM $progfile | $global_symbol_pipe >> '$nlist'" - done - - if test -n "$exclude_expsyms"; then - $opt_dry_run || { - eval '$EGREP -v " ($exclude_expsyms)$" "$nlist" > "$nlist"T' - eval '$MV "$nlist"T "$nlist"' - } - fi - - if test -n "$export_symbols_regex"; then - $opt_dry_run || { - eval '$EGREP -e "$export_symbols_regex" "$nlist" > "$nlist"T' - eval '$MV "$nlist"T "$nlist"' - } - fi - - # Prepare the list of exported symbols - if test -z "$export_symbols"; then - export_symbols="$output_objdir/$outputname.exp" - $opt_dry_run || { - $RM $export_symbols - eval "${SED} -n -e '/^: @PROGRAM@ $/d' -e 's/^.* \(.*\)$/\1/p' "'< "$nlist" > "$export_symbols"' - case $host in - *cygwin* | *mingw* | *cegcc* ) - eval "echo EXPORTS "'> "$output_objdir/$outputname.def"' - eval 'cat "$export_symbols" >> "$output_objdir/$outputname.def"' - ;; - esac - } - else - $opt_dry_run || { - eval "${SED} -e 's/\([].[*^$]\)/\\\\\1/g' -e 's/^/ /' -e 's/$/$/'"' < "$export_symbols" > "$output_objdir/$outputname.exp"' - eval '$GREP -f "$output_objdir/$outputname.exp" < "$nlist" > "$nlist"T' - eval '$MV "$nlist"T "$nlist"' - case $host in - *cygwin | *mingw* | *cegcc* ) - eval "echo EXPORTS "'> "$output_objdir/$outputname.def"' - eval 'cat "$nlist" >> "$output_objdir/$outputname.def"' - ;; - esac - } - fi - fi - - for dlprefile in $dlprefiles; do - func_verbose "extracting global C symbols from \`$dlprefile'" - func_basename "$dlprefile" - name="$func_basename_result" - $opt_dry_run || { - eval '$ECHO ": $name " >> "$nlist"' - eval "$NM $dlprefile 2>/dev/null | $global_symbol_pipe >> '$nlist'" - } - done - - $opt_dry_run || { - # Make sure we have at least an empty file. - test -f "$nlist" || : > "$nlist" - - if test -n "$exclude_expsyms"; then - $EGREP -v " ($exclude_expsyms)$" "$nlist" > "$nlist"T - $MV "$nlist"T "$nlist" - fi - - # Try sorting and uniquifying the output. - if $GREP -v "^: " < "$nlist" | - if sort -k 3 /dev/null 2>&1; then - sort -k 3 - else - sort +2 - fi | - uniq > "$nlist"S; then - : - else - $GREP -v "^: " < "$nlist" > "$nlist"S - fi - - if test -f "$nlist"S; then - eval "$global_symbol_to_cdecl"' < "$nlist"S >> "$output_objdir/$my_dlsyms"' - else - $ECHO '/* NONE */' >> "$output_objdir/$my_dlsyms" - fi + # Determine the type of output + case $output in + "") + $echo "$modename: you must specify an output file" 1>&2 + $echo "$help" 1>&2 + exit $EXIT_FAILURE + ;; + *.$libext) linkmode=oldlib ;; + *.lo | *.$objext) linkmode=obj ;; + *.la) linkmode=lib ;; + *) linkmode=prog ;; # Anything else should be a program. + esac - $ECHO >> "$output_objdir/$my_dlsyms" "\ + case $host in + *cygwin* | *mingw* | *pw32*) + # don't eliminate duplications in $postdeps and $predeps + duplicate_compiler_generated_deps=yes + ;; + *) + duplicate_compiler_generated_deps=$duplicate_deps + ;; + esac + specialdeplibs= -/* The mapping between symbol names and symbols. */ -typedef struct { - const char *name; - void *address; -} lt_dlsymlist; -" - case $host in - *cygwin* | *mingw* | *cegcc* ) - $ECHO >> "$output_objdir/$my_dlsyms" "\ -/* DATA imports from DLLs on WIN32 con't be const, because - runtime relocations are performed -- see ld's documentation - on pseudo-relocs. */" - lt_dlsym_const= ;; - *osf5*) - echo >> "$output_objdir/$my_dlsyms" "\ -/* This system does not cope well with relocations in const data */" - lt_dlsym_const= ;; - *) - lt_dlsym_const=const ;; - esac + libs= + # Find all interdependent deplibs by searching for libraries + # that are linked more than once (e.g. -la -lb -la) + for deplib in $deplibs; do + if test "X$duplicate_deps" = "Xyes" ; then + case "$libs " in + *" $deplib "*) specialdeplibs="$specialdeplibs $deplib" ;; + esac + fi + libs="$libs $deplib" + done - $ECHO >> "$output_objdir/$my_dlsyms" "\ -extern $lt_dlsym_const lt_dlsymlist -lt_${my_prefix}_LTX_preloaded_symbols[]; -$lt_dlsym_const lt_dlsymlist -lt_${my_prefix}_LTX_preloaded_symbols[] = -{\ - { \"$my_originator\", (void *) 0 }," + if test "$linkmode" = lib; then + libs="$predeps $libs $compiler_lib_search_path $postdeps" - case $need_lib_prefix in - no) - eval "$global_symbol_to_c_name_address" < "$nlist" >> "$output_objdir/$my_dlsyms" - ;; - *) - eval "$global_symbol_to_c_name_address_lib_prefix" < "$nlist" >> "$output_objdir/$my_dlsyms" - ;; + # Compute libraries that are listed more than once in $predeps + # $postdeps and mark them as special (i.e., whose duplicates are + # not to be eliminated). + pre_post_deps= + if test "X$duplicate_compiler_generated_deps" = "Xyes" ; then + for pre_post_dep in $predeps $postdeps; do + case "$pre_post_deps " in + *" $pre_post_dep "*) specialdeplibs="$specialdeplibs $pre_post_deps" ;; esac - $ECHO >> "$output_objdir/$my_dlsyms" "\ - {0, (void *) 0} -}; - -/* This works around a problem in FreeBSD linker */ -#ifdef FREEBSD_WORKAROUND -static const void *lt_preloaded_setup() { - return lt_${my_prefix}_LTX_preloaded_symbols; -} -#endif - -#ifdef __cplusplus -} -#endif\ -" - } # !$opt_dry_run + pre_post_deps="$pre_post_deps $pre_post_dep" + done + fi + pre_post_deps= + fi - pic_flag_for_symtable= - case "$compile_command " in - *" -static "*) ;; - *) - case $host in - # compiling the symbol table file with pic_flag works around - # a FreeBSD bug that causes programs to crash when -lm is - # linked before any other PIC object. But we must not use - # pic_flag when linking with -static. The problem exists in - # FreeBSD 2.2.6 and is fixed in FreeBSD 3.1. - *-*-freebsd2*|*-*-freebsd3.0*|*-*-freebsdelf3.0*) - pic_flag_for_symtable=" $pic_flag -DFREEBSD_WORKAROUND" ;; - *-*-hpux*) - pic_flag_for_symtable=" $pic_flag" ;; + deplibs= + newdependency_libs= + newlib_search_path= + need_relink=no # whether we're linking any uninstalled libtool libraries + notinst_deplibs= # not-installed libtool libraries + case $linkmode in + lib) + passes="conv link" + for file in $dlfiles $dlprefiles; do + case $file in + *.la) ;; *) - if test "X$my_pic_p" != Xno; then - pic_flag_for_symtable=" $pic_flag" - fi + $echo "$modename: libraries can \`-dlopen' only libtool libraries: $file" 1>&2 + exit $EXIT_FAILURE ;; esac - ;; - esac - symtab_cflags= - for arg in $LTCFLAGS; do - case $arg in - -pie | -fpie | -fPIE) ;; - *) symtab_cflags="$symtab_cflags $arg" ;; - esac done - - # Now compile the dynamic symbol file. - func_show_eval '(cd $output_objdir && $LTCC$symtab_cflags -c$no_builtin_flag$pic_flag_for_symtable "$my_dlsyms")' 'exit $?' - - # Clean up the generated files. - func_show_eval '$RM "$output_objdir/$my_dlsyms" "$nlist" "${nlist}S" "${nlist}T"' - - # Transform the symbol file into the correct name. - symfileobj="$output_objdir/${my_outputname}S.$objext" - case $host in - *cygwin* | *mingw* | *cegcc* ) - if test -f "$output_objdir/$my_outputname.def"; then - compile_command=`$ECHO "X$compile_command" | $Xsed -e "s%@SYMFILE@%$output_objdir/$my_outputname.def $symfileobj%"` - finalize_command=`$ECHO "X$finalize_command" | $Xsed -e "s%@SYMFILE@%$output_objdir/$my_outputname.def $symfileobj%"` - else - compile_command=`$ECHO "X$compile_command" | $Xsed -e "s%@SYMFILE@%$symfileobj%"` - finalize_command=`$ECHO "X$finalize_command" | $Xsed -e "s%@SYMFILE@%$symfileobj%"` - fi - ;; - *) - compile_command=`$ECHO "X$compile_command" | $Xsed -e "s%@SYMFILE@%$symfileobj%"` - finalize_command=`$ECHO "X$finalize_command" | $Xsed -e "s%@SYMFILE@%$symfileobj%"` - ;; - esac ;; - *) - func_fatal_error "unknown suffix for \`$my_dlsyms'" + prog) + compile_deplibs= + finalize_deplibs= + alldeplibs=no + newdlfiles= + newdlprefiles= + passes="conv scan dlopen dlpreopen link" + ;; + *) passes="conv" ;; - esac - else - # We keep going just in case the user didn't refer to - # lt_preloaded_symbols. The linker will fail if global_symbol_pipe - # really was required. - - # Nullify the symbol file. - compile_command=`$ECHO "X$compile_command" | $Xsed -e "s% @SYMFILE@%%"` - finalize_command=`$ECHO "X$finalize_command" | $Xsed -e "s% @SYMFILE@%%"` - fi -} - -# func_win32_libid arg -# return the library type of file 'arg' -# -# Need a lot of goo to handle *both* DLLs and import libs -# Has to be a shell function in order to 'eat' the argument -# that is supplied when $file_magic_command is called. -func_win32_libid () -{ - $opt_debug - win32_libid_type="unknown" - win32_fileres=`file -L $1 2>/dev/null` - case $win32_fileres in - *ar\ archive\ import\ library*) # definitely import - win32_libid_type="x86 archive import" - ;; - *ar\ archive*) # could be an import, or static - if eval $OBJDUMP -f $1 | $SED -e '10q' 2>/dev/null | - $EGREP 'file format pe-i386(.*architecture: i386)?' >/dev/null ; then - win32_nmres=`eval $NM -f posix -A $1 | - $SED -n -e ' - 1,100{ - / I /{ - s,.*,import, - p - q - } - }'` - case $win32_nmres in - import*) win32_libid_type="x86 archive import";; - *) win32_libid_type="x86 archive static";; - esac - fi - ;; - *DLL*) - win32_libid_type="x86 DLL" - ;; - *executable*) # but shell scripts are "executable" too... - case $win32_fileres in - *MS\ Windows\ PE\ Intel*) - win32_libid_type="x86 DLL" - ;; esac - ;; - esac - $ECHO "$win32_libid_type" -} - + for pass in $passes; do + if test "$linkmode,$pass" = "lib,link" || + test "$linkmode,$pass" = "prog,scan"; then + libs="$deplibs" + deplibs= + fi + if test "$linkmode" = prog; then + case $pass in + dlopen) libs="$dlfiles" ;; + dlpreopen) libs="$dlprefiles" ;; + link) libs="$deplibs %DEPLIBS% $dependency_libs" ;; + esac + fi + if test "$pass" = dlopen; then + # Collect dlpreopened libraries + save_deplibs="$deplibs" + deplibs= + fi + for deplib in $libs; do + lib= + found=no + case $deplib in + -mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe|-threads) + if test "$linkmode,$pass" = "prog,link"; then + compile_deplibs="$deplib $compile_deplibs" + finalize_deplibs="$deplib $finalize_deplibs" + else + compiler_flags="$compiler_flags $deplib" + fi + continue + ;; + -l*) + if test "$linkmode" != lib && test "$linkmode" != prog; then + $echo "$modename: warning: \`-l' is ignored for archives/objects" 1>&2 + continue + fi + name=`$echo "X$deplib" | $Xsed -e 's/^-l//'` + if test "$linkmode" = lib; then + searchdirs="$newlib_search_path $lib_search_path $compiler_lib_search_dirs $sys_lib_search_path $shlib_search_path" + else + searchdirs="$newlib_search_path $lib_search_path $sys_lib_search_path $shlib_search_path" + fi + for searchdir in $searchdirs; do + for search_ext in .la $std_shrext .so .a; do + # Search the libtool library + lib="$searchdir/lib${name}${search_ext}" + if test -f "$lib"; then + if test "$search_ext" = ".la"; then + found=yes + else + found=no + fi + break 2 + fi + done + done + if test "$found" != yes; then + # deplib doesn't seem to be a libtool library + if test "$linkmode,$pass" = "prog,link"; then + compile_deplibs="$deplib $compile_deplibs" + finalize_deplibs="$deplib $finalize_deplibs" + else + deplibs="$deplib $deplibs" + test "$linkmode" = lib && newdependency_libs="$deplib $newdependency_libs" + fi + continue + else # deplib is a libtool library + # If $allow_libtool_libs_with_static_runtimes && $deplib is a stdlib, + # We need to do some special things here, and not later. + if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then + case " $predeps $postdeps " in + *" $deplib "*) + if (${SED} -e '2q' $lib | + grep "^# Generated by .*$PACKAGE") >/dev/null 2>&1; then + library_names= + old_library= + case $lib in + */* | *\\*) . $lib ;; + *) . ./$lib ;; + esac + for l in $old_library $library_names; do + ll="$l" + done + if test "X$ll" = "X$old_library" ; then # only static version available + found=no + ladir=`$echo "X$lib" | $Xsed -e 's%/[^/]*$%%'` + test "X$ladir" = "X$lib" && ladir="." + lib=$ladir/$old_library + if test "$linkmode,$pass" = "prog,link"; then + compile_deplibs="$deplib $compile_deplibs" + finalize_deplibs="$deplib $finalize_deplibs" + else + deplibs="$deplib $deplibs" + test "$linkmode" = lib && newdependency_libs="$deplib $newdependency_libs" + fi + continue + fi + fi + ;; + *) ;; + esac + fi + fi + ;; # -l + -L*) + case $linkmode in + lib) + deplibs="$deplib $deplibs" + test "$pass" = conv && continue + newdependency_libs="$deplib $newdependency_libs" + newlib_search_path="$newlib_search_path "`$echo "X$deplib" | $Xsed -e 's/^-L//'` + ;; + prog) + if test "$pass" = conv; then + deplibs="$deplib $deplibs" + continue + fi + if test "$pass" = scan; then + deplibs="$deplib $deplibs" + else + compile_deplibs="$deplib $compile_deplibs" + finalize_deplibs="$deplib $finalize_deplibs" + fi + newlib_search_path="$newlib_search_path "`$echo "X$deplib" | $Xsed -e 's/^-L//'` + ;; + *) + $echo "$modename: warning: \`-L' is ignored for archives/objects" 1>&2 + ;; + esac # linkmode + continue + ;; # -L + -R*) + if test "$pass" = link; then + dir=`$echo "X$deplib" | $Xsed -e 's/^-R//'` + # Make sure the xrpath contains only unique directories. + case "$xrpath " in + *" $dir "*) ;; + *) xrpath="$xrpath $dir" ;; + esac + fi + deplibs="$deplib $deplibs" + continue + ;; + *.la) lib="$deplib" ;; + *.$libext) + if test "$pass" = conv; then + deplibs="$deplib $deplibs" + continue + fi + case $linkmode in + lib) + valid_a_lib=no + case $deplibs_check_method in + match_pattern*) + set dummy $deplibs_check_method + match_pattern_regex=`expr "$deplibs_check_method" : "$2 \(.*\)"` + if eval $echo \"$deplib\" 2>/dev/null \ + | $SED 10q \ + | $EGREP "$match_pattern_regex" > /dev/null; then + valid_a_lib=yes + fi + ;; + pass_all) + valid_a_lib=yes + ;; + esac + if test "$valid_a_lib" != yes; then + $echo + $echo "*** Warning: Trying to link with static lib archive $deplib." + $echo "*** I have the capability to make that library automatically link in when" + $echo "*** you link to this library. But I can only do this if you have a" + $echo "*** shared version of the library, which you do not appear to have" + $echo "*** because the file extensions .$libext of this argument makes me believe" + $echo "*** that it is just a static archive that I should not used here." + else + $echo + $echo "*** Warning: Linking the shared library $output against the" + $echo "*** static library $deplib is not portable!" + deplibs="$deplib $deplibs" + fi + continue + ;; + prog) + if test "$pass" != link; then + deplibs="$deplib $deplibs" + else + compile_deplibs="$deplib $compile_deplibs" + finalize_deplibs="$deplib $finalize_deplibs" + fi + continue + ;; + esac # linkmode + ;; # *.$libext + *.lo | *.$objext) + if test "$pass" = conv; then + deplibs="$deplib $deplibs" + elif test "$linkmode" = prog; then + if test "$pass" = dlpreopen || test "$dlopen_support" != yes || test "$build_libtool_libs" = no; then + # If there is no dlopen support or we're linking statically, + # we need to preload. + newdlprefiles="$newdlprefiles $deplib" + compile_deplibs="$deplib $compile_deplibs" + finalize_deplibs="$deplib $finalize_deplibs" + else + newdlfiles="$newdlfiles $deplib" + fi + fi + continue + ;; + %DEPLIBS%) + alldeplibs=yes + continue + ;; + esac # case $deplib + if test "$found" = yes || test -f "$lib"; then : + else + $echo "$modename: cannot find the library \`$lib' or unhandled argument \`$deplib'" 1>&2 + exit $EXIT_FAILURE + fi + # Check to see that this really is a libtool archive. + if (${SED} -e '2q' $lib | grep "^# Generated by .*$PACKAGE") >/dev/null 2>&1; then : + else + $echo "$modename: \`$lib' is not a valid libtool archive" 1>&2 + exit $EXIT_FAILURE + fi -# func_extract_an_archive dir oldlib -func_extract_an_archive () -{ - $opt_debug - f_ex_an_ar_dir="$1"; shift - f_ex_an_ar_oldlib="$1" - func_show_eval "(cd \$f_ex_an_ar_dir && $AR x \"\$f_ex_an_ar_oldlib\")" 'exit $?' - if ($AR t "$f_ex_an_ar_oldlib" | sort | sort -uc >/dev/null 2>&1); then - : - else - func_fatal_error "object name conflicts in archive: $f_ex_an_ar_dir/$f_ex_an_ar_oldlib" - fi -} + ladir=`$echo "X$lib" | $Xsed -e 's%/[^/]*$%%'` + test "X$ladir" = "X$lib" && ladir="." + dlname= + dlopen= + dlpreopen= + libdir= + library_names= + old_library= + # If the library was installed with an old release of libtool, + # it will not redefine variables installed, or shouldnotlink + installed=yes + shouldnotlink=no + avoidtemprpath= -# func_extract_archives gentop oldlib ... -func_extract_archives () -{ - $opt_debug - my_gentop="$1"; shift - my_oldlibs=${1+"$@"} - my_oldobjs="" - my_xlib="" - my_xabs="" - my_xdir="" - for my_xlib in $my_oldlibs; do - # Extract the objects. - case $my_xlib in - [\\/]* | [A-Za-z]:[\\/]*) my_xabs="$my_xlib" ;; - *) my_xabs=`pwd`"/$my_xlib" ;; - esac - func_basename "$my_xlib" - my_xlib="$func_basename_result" - my_xlib_u=$my_xlib - while :; do - case " $extracted_archives " in - *" $my_xlib_u "*) - func_arith $extracted_serial + 1 - extracted_serial=$func_arith_result - my_xlib_u=lt$extracted_serial-$my_xlib ;; - *) break ;; + # Read the .la file + case $lib in + */* | *\\*) . $lib ;; + *) . ./$lib ;; esac - done - extracted_archives="$extracted_archives $my_xlib_u" - my_xdir="$my_gentop/$my_xlib_u" - func_mkdir_p "$my_xdir" - - case $host in - *-darwin*) - func_verbose "Extracting $my_xabs" - # Do not bother doing anything if just a dry run - $opt_dry_run || { - darwin_orig_dir=`pwd` - cd $my_xdir || exit $? - darwin_archive=$my_xabs - darwin_curdir=`pwd` - darwin_base_archive=`basename "$darwin_archive"` - darwin_arches=`$LIPO -info "$darwin_archive" 2>/dev/null | $GREP Architectures 2>/dev/null || true` - if test -n "$darwin_arches"; then - darwin_arches=`$ECHO "$darwin_arches" | $SED -e 's/.*are://'` - darwin_arch= - func_verbose "$darwin_base_archive has multiple architectures $darwin_arches" - for darwin_arch in $darwin_arches ; do - func_mkdir_p "unfat-$$/${darwin_base_archive}-${darwin_arch}" - $LIPO -thin $darwin_arch -output "unfat-$$/${darwin_base_archive}-${darwin_arch}/${darwin_base_archive}" "${darwin_archive}" - cd "unfat-$$/${darwin_base_archive}-${darwin_arch}" - func_extract_an_archive "`pwd`" "${darwin_base_archive}" - cd "$darwin_curdir" - $RM "unfat-$$/${darwin_base_archive}-${darwin_arch}/${darwin_base_archive}" - done # $darwin_arches - ## Okay now we've a bunch of thin objects, gotta fatten them up :) - darwin_filelist=`find unfat-$$ -type f -name \*.o -print -o -name \*.lo -print | $SED -e "$basename" | sort -u` - darwin_file= - darwin_files= - for darwin_file in $darwin_filelist; do - darwin_files=`find unfat-$$ -name $darwin_file -print | $NL2SP` - $LIPO -create -output "$darwin_file" $darwin_files - done # $darwin_filelist - $RM -rf unfat-$$ - cd "$darwin_orig_dir" - else - cd $darwin_orig_dir - func_extract_an_archive "$my_xdir" "$my_xabs" - fi # $darwin_arches - } # !$opt_dry_run - ;; - *) - func_extract_an_archive "$my_xdir" "$my_xabs" - ;; - esac - my_oldobjs="$my_oldobjs "`find $my_xdir -name \*.$objext -print -o -name \*.lo -print | $NL2SP` - done - - func_extract_archives_result="$my_oldobjs" -} + if test "$linkmode,$pass" = "lib,link" || + test "$linkmode,$pass" = "prog,scan" || + { test "$linkmode" != prog && test "$linkmode" != lib; }; then + test -n "$dlopen" && dlfiles="$dlfiles $dlopen" + test -n "$dlpreopen" && dlprefiles="$dlprefiles $dlpreopen" + fi + if test "$pass" = conv; then + # Only check for convenience libraries + deplibs="$lib $deplibs" + if test -z "$libdir"; then + if test -z "$old_library"; then + $echo "$modename: cannot find name of link library for \`$lib'" 1>&2 + exit $EXIT_FAILURE + fi + # It is a libtool convenience library, so add in its objects. + convenience="$convenience $ladir/$objdir/$old_library" + old_convenience="$old_convenience $ladir/$objdir/$old_library" + tmp_libs= + for deplib in $dependency_libs; do + deplibs="$deplib $deplibs" + if test "X$duplicate_deps" = "Xyes" ; then + case "$tmp_libs " in + *" $deplib "*) specialdeplibs="$specialdeplibs $deplib" ;; + esac + fi + tmp_libs="$tmp_libs $deplib" + done + elif test "$linkmode" != prog && test "$linkmode" != lib; then + $echo "$modename: \`$lib' is not a convenience library" 1>&2 + exit $EXIT_FAILURE + fi + continue + fi # $pass = conv -# func_emit_wrapper_part1 [arg=no] -# -# Emit the first part of a libtool wrapper script on stdout. -# For more information, see the description associated with -# func_emit_wrapper(), below. -func_emit_wrapper_part1 () -{ - func_emit_wrapper_part1_arg1=no - if test -n "$1" ; then - func_emit_wrapper_part1_arg1=$1 + # Get the name of the library we link against. + linklib= + for l in $old_library $library_names; do + linklib="$l" + done + if test -z "$linklib"; then + $echo "$modename: cannot find name of link library for \`$lib'" 1>&2 + exit $EXIT_FAILURE fi - $ECHO "\ -#! $SHELL + # This library was specified with -dlopen. + if test "$pass" = dlopen; then + if test -z "$libdir"; then + $echo "$modename: cannot -dlopen a convenience library: \`$lib'" 1>&2 + exit $EXIT_FAILURE + fi + if test -z "$dlname" || + test "$dlopen_support" != yes || + test "$build_libtool_libs" = no; then + # If there is no dlname, no dlopen support or we're linking + # statically, we need to preload. We also need to preload any + # dependent libraries so libltdl's deplib preloader doesn't + # bomb out in the load deplibs phase. + dlprefiles="$dlprefiles $lib $dependency_libs" + else + newdlfiles="$newdlfiles $lib" + fi + continue + fi # $pass = dlopen -# $output - temporary wrapper script for $objdir/$outputname -# Generated by $PROGRAM (GNU $PACKAGE$TIMESTAMP) $VERSION -# -# The $output program cannot be directly executed until all the libtool -# libraries that it depends on are installed. -# -# This wrapper script should never be moved out of the build directory. -# If it is, it will not operate correctly. + # We need an absolute path. + case $ladir in + [\\/]* | [A-Za-z]:[\\/]*) abs_ladir="$ladir" ;; + *) + abs_ladir=`cd "$ladir" && pwd` + if test -z "$abs_ladir"; then + $echo "$modename: warning: cannot determine absolute directory name of \`$ladir'" 1>&2 + $echo "$modename: passing it literally to the linker, although it might fail" 1>&2 + abs_ladir="$ladir" + fi + ;; + esac + laname=`$echo "X$lib" | $Xsed -e 's%^.*/%%'` -# Sed substitution that helps us do robust quoting. It backslashifies -# metacharacters that are still active within double-quoted strings. -Xsed='${SED} -e 1s/^X//' -sed_quote_subst='$sed_quote_subst' + # Find the relevant object directory and library name. + if test "X$installed" = Xyes; then + if test ! -f "$libdir/$linklib" && test -f "$abs_ladir/$linklib"; then + $echo "$modename: warning: library \`$lib' was moved." 1>&2 + dir="$ladir" + absdir="$abs_ladir" + libdir="$abs_ladir" + else + dir="$libdir" + absdir="$libdir" + fi + test "X$hardcode_automatic" = Xyes && avoidtemprpath=yes + else + if test ! -f "$ladir/$objdir/$linklib" && test -f "$abs_ladir/$linklib"; then + dir="$ladir" + absdir="$abs_ladir" + # Remove this search path later + notinst_path="$notinst_path $abs_ladir" + else + dir="$ladir/$objdir" + absdir="$abs_ladir/$objdir" + # Remove this search path later + notinst_path="$notinst_path $abs_ladir" + fi + fi # $installed = yes + name=`$echo "X$laname" | $Xsed -e 's/\.la$//' -e 's/^lib//'` -# Be Bourne compatible -if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then - emulate sh - NULLCMD=: - # Zsh 3.x and 4.x performs word splitting on \${1+\"\$@\"}, which - # is contrary to our usage. Disable this feature. - alias -g '\${1+\"\$@\"}'='\"\$@\"' - setopt NO_GLOB_SUBST -else - case \`(set -o) 2>/dev/null\` in *posix*) set -o posix;; esac -fi -BIN_SH=xpg4; export BIN_SH # for Tru64 -DUALCASE=1; export DUALCASE # for MKS sh + # This library was specified with -dlpreopen. + if test "$pass" = dlpreopen; then + if test -z "$libdir"; then + $echo "$modename: cannot -dlpreopen a convenience library: \`$lib'" 1>&2 + exit $EXIT_FAILURE + fi + # Prefer using a static library (so that no silly _DYNAMIC symbols + # are required to link). + if test -n "$old_library"; then + newdlprefiles="$newdlprefiles $dir/$old_library" + # Otherwise, use the dlname, so that lt_dlopen finds it. + elif test -n "$dlname"; then + newdlprefiles="$newdlprefiles $dir/$dlname" + else + newdlprefiles="$newdlprefiles $dir/$linklib" + fi + fi # $pass = dlpreopen -# The HP-UX ksh and POSIX shell print the target directory to stdout -# if CDPATH is set. -(unset CDPATH) >/dev/null 2>&1 && unset CDPATH + if test -z "$libdir"; then + # Link the convenience library + if test "$linkmode" = lib; then + deplibs="$dir/$old_library $deplibs" + elif test "$linkmode,$pass" = "prog,link"; then + compile_deplibs="$dir/$old_library $compile_deplibs" + finalize_deplibs="$dir/$old_library $finalize_deplibs" + else + deplibs="$lib $deplibs" # used for prog,scan pass + fi + continue + fi -relink_command=\"$relink_command\" -# This environment variable determines our operation mode. -if test \"\$libtool_install_magic\" = \"$magic\"; then - # install mode needs the following variables: - generated_by_libtool_version='$macro_version' - notinst_deplibs='$notinst_deplibs' -else - # When we are sourced in execute mode, \$file and \$ECHO are already set. - if test \"\$libtool_execute_magic\" != \"$magic\"; then - ECHO=\"$qecho\" - file=\"\$0\" - # Make sure echo works. - if test \"X\$1\" = X--no-reexec; then - # Discard the --no-reexec flag, and continue. - shift - elif test \"X\`{ \$ECHO '\t'; } 2>/dev/null\`\" = 'X\t'; then - # Yippee, \$ECHO works! - : - else - # Restart under the correct shell, and then maybe \$ECHO will work. - exec $SHELL \"\$0\" --no-reexec \${1+\"\$@\"} - fi - fi\ -" - $ECHO "\ + if test "$linkmode" = prog && test "$pass" != link; then + newlib_search_path="$newlib_search_path $ladir" + deplibs="$lib $deplibs" - # Find the directory that this script lives in. - thisdir=\`\$ECHO \"X\$file\" | \$Xsed -e 's%/[^/]*$%%'\` - test \"x\$thisdir\" = \"x\$file\" && thisdir=. + linkalldeplibs=no + if test "$link_all_deplibs" != no || test -z "$library_names" || + test "$build_libtool_libs" = no; then + linkalldeplibs=yes + fi - # Follow symbolic links until we get to the real thisdir. - file=\`ls -ld \"\$file\" | ${SED} -n 's/.*-> //p'\` - while test -n \"\$file\"; do - destdir=\`\$ECHO \"X\$file\" | \$Xsed -e 's%/[^/]*\$%%'\` + tmp_libs= + for deplib in $dependency_libs; do + case $deplib in + -L*) newlib_search_path="$newlib_search_path "`$echo "X$deplib" | $Xsed -e 's/^-L//'`;; ### testsuite: skip nested quoting test + esac + # Need to link against all dependency_libs? + if test "$linkalldeplibs" = yes; then + deplibs="$deplib $deplibs" + else + # Need to hardcode shared library paths + # or/and link against static libraries + newdependency_libs="$deplib $newdependency_libs" + fi + if test "X$duplicate_deps" = "Xyes" ; then + case "$tmp_libs " in + *" $deplib "*) specialdeplibs="$specialdeplibs $deplib" ;; + esac + fi + tmp_libs="$tmp_libs $deplib" + done # for deplib + continue + fi # $linkmode = prog... - # If there was a directory component, then change thisdir. - if test \"x\$destdir\" != \"x\$file\"; then - case \"\$destdir\" in - [\\\\/]* | [A-Za-z]:[\\\\/]*) thisdir=\"\$destdir\" ;; - *) thisdir=\"\$thisdir/\$destdir\" ;; - esac - fi + if test "$linkmode,$pass" = "prog,link"; then + if test -n "$library_names" && + { { test "$prefer_static_libs" = no || + test "$prefer_static_libs,$installed" = "built,yes"; } || + test -z "$old_library"; }; then + # We need to hardcode the library path + if test -n "$shlibpath_var" && test -z "$avoidtemprpath" ; then + # Make sure the rpath contains only unique directories. + case "$temp_rpath " in + *" $dir "*) ;; + *" $absdir "*) ;; + *) temp_rpath="$temp_rpath $absdir" ;; + esac + fi - file=\`\$ECHO \"X\$file\" | \$Xsed -e 's%^.*/%%'\` - file=\`ls -ld \"\$thisdir/\$file\" | ${SED} -n 's/.*-> //p'\` - done -" -} -# end: func_emit_wrapper_part1 + # Hardcode the library path. + # Skip directories that are in the system default run-time + # search path. + case " $sys_lib_dlsearch_path " in + *" $absdir "*) ;; + *) + case "$compile_rpath " in + *" $absdir "*) ;; + *) compile_rpath="$compile_rpath $absdir" + esac + ;; + esac + case " $sys_lib_dlsearch_path " in + *" $libdir "*) ;; + *) + case "$finalize_rpath " in + *" $libdir "*) ;; + *) finalize_rpath="$finalize_rpath $libdir" + esac + ;; + esac + fi # $linkmode,$pass = prog,link... -# func_emit_wrapper_part2 [arg=no] -# -# Emit the second part of a libtool wrapper script on stdout. -# For more information, see the description associated with -# func_emit_wrapper(), below. -func_emit_wrapper_part2 () -{ - func_emit_wrapper_part2_arg1=no - if test -n "$1" ; then - func_emit_wrapper_part2_arg1=$1 + if test "$alldeplibs" = yes && + { test "$deplibs_check_method" = pass_all || + { test "$build_libtool_libs" = yes && + test -n "$library_names"; }; }; then + # We only need to search for static libraries + continue + fi fi - $ECHO "\ + link_static=no # Whether the deplib will be linked statically + use_static_libs=$prefer_static_libs + if test "$use_static_libs" = built && test "$installed" = yes ; then + use_static_libs=no + fi + if test -n "$library_names" && + { test "$use_static_libs" = no || test -z "$old_library"; }; then + if test "$installed" = no; then + notinst_deplibs="$notinst_deplibs $lib" + need_relink=yes + fi + # This is a shared library - # Usually 'no', except on cygwin/mingw when embedded into - # the cwrapper. - WRAPPER_SCRIPT_BELONGS_IN_OBJDIR=$func_emit_wrapper_part2_arg1 - if test \"\$WRAPPER_SCRIPT_BELONGS_IN_OBJDIR\" = \"yes\"; then - # special case for '.' - if test \"\$thisdir\" = \".\"; then - thisdir=\`pwd\` - fi - # remove .libs from thisdir - case \"\$thisdir\" in - *[\\\\/]$objdir ) thisdir=\`\$ECHO \"X\$thisdir\" | \$Xsed -e 's%[\\\\/][^\\\\/]*$%%'\` ;; - $objdir ) thisdir=. ;; - esac - fi - - # Try to get the absolute directory name. - absdir=\`cd \"\$thisdir\" && pwd\` - test -n \"\$absdir\" && thisdir=\"\$absdir\" -" - - if test "$fast_install" = yes; then - $ECHO "\ - program=lt-'$outputname'$exeext - progdir=\"\$thisdir/$objdir\" - - if test ! -f \"\$progdir/\$program\" || - { file=\`ls -1dt \"\$progdir/\$program\" \"\$progdir/../\$program\" 2>/dev/null | ${SED} 1q\`; \\ - test \"X\$file\" != \"X\$progdir/\$program\"; }; then + # Warn about portability, can't link against -module's on + # some systems (darwin) + if test "$shouldnotlink" = yes && test "$pass" = link ; then + $echo + if test "$linkmode" = prog; then + $echo "*** Warning: Linking the executable $output against the loadable module" + else + $echo "*** Warning: Linking the shared library $output against the loadable module" + fi + $echo "*** $linklib is not portable!" + fi + if test "$linkmode" = lib && + test "$hardcode_into_libs" = yes; then + # Hardcode the library path. + # Skip directories that are in the system default run-time + # search path. + case " $sys_lib_dlsearch_path " in + *" $absdir "*) ;; + *) + case "$compile_rpath " in + *" $absdir "*) ;; + *) compile_rpath="$compile_rpath $absdir" + esac + ;; + esac + case " $sys_lib_dlsearch_path " in + *" $libdir "*) ;; + *) + case "$finalize_rpath " in + *" $libdir "*) ;; + *) finalize_rpath="$finalize_rpath $libdir" + esac + ;; + esac + fi - file=\"\$\$-\$program\" + if test -n "$old_archive_from_expsyms_cmds"; then + # figure out the soname + set dummy $library_names + realname="$2" + shift; shift + libname=`eval \\$echo \"$libname_spec\"` + # use dlname if we got it. it's perfectly good, no? + if test -n "$dlname"; then + soname="$dlname" + elif test -n "$soname_spec"; then + # bleh windows + case $host in + *cygwin* | mingw*) + major=`expr $current - $age` + versuffix="-$major" + ;; + esac + eval soname=\"$soname_spec\" + else + soname="$realname" + fi - if test ! -d \"\$progdir\"; then - $MKDIR \"\$progdir\" - else - $RM \"\$progdir/\$file\" - fi" + # Make a new name for the extract_expsyms_cmds to use + soroot="$soname" + soname=`$echo $soroot | ${SED} -e 's/^.*\///'` + newlib="libimp-`$echo $soname | ${SED} 's/^lib//;s/\.dll$//'`.a" - $ECHO "\ + # If the library has no export list, then create one now + if test -f "$output_objdir/$soname-def"; then : + else + $show "extracting exported symbol list from \`$soname'" + save_ifs="$IFS"; IFS='~' + cmds=$extract_expsyms_cmds + for cmd in $cmds; do + IFS="$save_ifs" + eval cmd=\"$cmd\" + $show "$cmd" + $run eval "$cmd" || exit $? + done + IFS="$save_ifs" + fi - # relink executable if necessary - if test -n \"\$relink_command\"; then - if relink_command_output=\`eval \$relink_command 2>&1\`; then : - else - $ECHO \"\$relink_command_output\" >&2 - $RM \"\$progdir/\$file\" - exit 1 - fi - fi + # Create $newlib + if test -f "$output_objdir/$newlib"; then :; else + $show "generating import library for \`$soname'" + save_ifs="$IFS"; IFS='~' + cmds=$old_archive_from_expsyms_cmds + for cmd in $cmds; do + IFS="$save_ifs" + eval cmd=\"$cmd\" + $show "$cmd" + $run eval "$cmd" || exit $? + done + IFS="$save_ifs" + fi + # make sure the library variables are pointing to the new library + dir=$output_objdir + linklib=$newlib + fi # test -n "$old_archive_from_expsyms_cmds" - $MV \"\$progdir/\$file\" \"\$progdir/\$program\" 2>/dev/null || - { $RM \"\$progdir/\$program\"; - $MV \"\$progdir/\$file\" \"\$progdir/\$program\"; } - $RM \"\$progdir/\$file\" - fi" - else - $ECHO "\ - program='$outputname' - progdir=\"\$thisdir/$objdir\" -" - fi + if test "$linkmode" = prog || test "$mode" != relink; then + add_shlibpath= + add_dir= + add= + lib_linked=yes + case $hardcode_action in + immediate | unsupported) + if test "$hardcode_direct" = no; then + add="$dir/$linklib" + case $host in + *-*-sco3.2v5.0.[024]*) add_dir="-L$dir" ;; + *-*-sysv4*uw2*) add_dir="-L$dir" ;; + *-*-sysv5OpenUNIX* | *-*-sysv5UnixWare7.[01].[10]* | \ + *-*-unixware7*) add_dir="-L$dir" ;; + *-*-darwin* ) + # if the lib is a module then we can not link against + # it, someone is ignoring the new warnings I added + if /usr/bin/file -L $add 2> /dev/null | + $EGREP ": [^:]* bundle" >/dev/null ; then + $echo "** Warning, lib $linklib is a module, not a shared library" + if test -z "$old_library" ; then + $echo + $echo "** And there doesn't seem to be a static archive available" + $echo "** The link will probably fail, sorry" + else + add="$dir/$old_library" + fi + fi + esac + elif test "$hardcode_minus_L" = no; then + case $host in + *-*-sunos*) add_shlibpath="$dir" ;; + esac + add_dir="-L$dir" + add="-l$name" + elif test "$hardcode_shlibpath_var" = no; then + add_shlibpath="$dir" + add="-l$name" + else + lib_linked=no + fi + ;; + relink) + if test "$hardcode_direct" = yes; then + add="$dir/$linklib" + elif test "$hardcode_minus_L" = yes; then + add_dir="-L$dir" + # Try looking first in the location we're being installed to. + if test -n "$inst_prefix_dir"; then + case $libdir in + [\\/]*) + add_dir="$add_dir -L$inst_prefix_dir$libdir" + ;; + esac + fi + add="-l$name" + elif test "$hardcode_shlibpath_var" = yes; then + add_shlibpath="$dir" + add="-l$name" + else + lib_linked=no + fi + ;; + *) lib_linked=no ;; + esac - $ECHO "\ + if test "$lib_linked" != yes; then + $echo "$modename: configuration error: unsupported hardcode properties" + exit $EXIT_FAILURE + fi - if test -f \"\$progdir/\$program\"; then" + if test -n "$add_shlibpath"; then + case :$compile_shlibpath: in + *":$add_shlibpath:"*) ;; + *) compile_shlibpath="$compile_shlibpath$add_shlibpath:" ;; + esac + fi + if test "$linkmode" = prog; then + test -n "$add_dir" && compile_deplibs="$add_dir $compile_deplibs" + test -n "$add" && compile_deplibs="$add $compile_deplibs" + else + test -n "$add_dir" && deplibs="$add_dir $deplibs" + test -n "$add" && deplibs="$add $deplibs" + if test "$hardcode_direct" != yes && \ + test "$hardcode_minus_L" != yes && \ + test "$hardcode_shlibpath_var" = yes; then + case :$finalize_shlibpath: in + *":$libdir:"*) ;; + *) finalize_shlibpath="$finalize_shlibpath$libdir:" ;; + esac + fi + fi + fi - # Export our shlibpath_var if we have one. - if test "$shlibpath_overrides_runpath" = yes && test -n "$shlibpath_var" && test -n "$temp_rpath"; then - $ECHO "\ - # Add our own library path to $shlibpath_var - $shlibpath_var=\"$temp_rpath\$$shlibpath_var\" + if test "$linkmode" = prog || test "$mode" = relink; then + add_shlibpath= + add_dir= + add= + # Finalize command for both is simple: just hardcode it. + if test "$hardcode_direct" = yes; then + add="$libdir/$linklib" + elif test "$hardcode_minus_L" = yes; then + add_dir="-L$libdir" + add="-l$name" + elif test "$hardcode_shlibpath_var" = yes; then + case :$finalize_shlibpath: in + *":$libdir:"*) ;; + *) finalize_shlibpath="$finalize_shlibpath$libdir:" ;; + esac + add="-l$name" + elif test "$hardcode_automatic" = yes; then + if test -n "$inst_prefix_dir" && + test -f "$inst_prefix_dir$libdir/$linklib" ; then + add="$inst_prefix_dir$libdir/$linklib" + else + add="$libdir/$linklib" + fi + else + # We cannot seem to hardcode it, guess we'll fake it. + add_dir="-L$libdir" + # Try looking first in the location we're being installed to. + if test -n "$inst_prefix_dir"; then + case $libdir in + [\\/]*) + add_dir="$add_dir -L$inst_prefix_dir$libdir" + ;; + esac + fi + add="-l$name" + fi - # Some systems cannot cope with colon-terminated $shlibpath_var - # The second colon is a workaround for a bug in BeOS R4 sed - $shlibpath_var=\`\$ECHO \"X\$$shlibpath_var\" | \$Xsed -e 's/::*\$//'\` + if test "$linkmode" = prog; then + test -n "$add_dir" && finalize_deplibs="$add_dir $finalize_deplibs" + test -n "$add" && finalize_deplibs="$add $finalize_deplibs" + else + test -n "$add_dir" && deplibs="$add_dir $deplibs" + test -n "$add" && deplibs="$add $deplibs" + fi + fi + elif test "$linkmode" = prog; then + # Here we assume that one of hardcode_direct or hardcode_minus_L + # is not unsupported. This is valid on all known static and + # shared platforms. + if test "$hardcode_direct" != unsupported; then + test -n "$old_library" && linklib="$old_library" + compile_deplibs="$dir/$linklib $compile_deplibs" + finalize_deplibs="$dir/$linklib $finalize_deplibs" + else + compile_deplibs="-l$name -L$dir $compile_deplibs" + finalize_deplibs="-l$name -L$dir $finalize_deplibs" + fi + elif test "$build_libtool_libs" = yes; then + # Not a shared library + if test "$deplibs_check_method" != pass_all; then + # We're trying link a shared library against a static one + # but the system doesn't support it. - export $shlibpath_var -" - fi + # Just print a warning and add the library to dependency_libs so + # that the program can be linked against the static library. + $echo + $echo "*** Warning: This system can not link to static lib archive $lib." + $echo "*** I have the capability to make that library automatically link in when" + $echo "*** you link to this library. But I can only do this if you have a" + $echo "*** shared version of the library, which you do not appear to have." + if test "$module" = yes; then + $echo "*** But as you try to build a module library, libtool will still create " + $echo "*** a static module, that should work as long as the dlopening application" + $echo "*** is linked with the -dlopen flag to resolve symbols at runtime." + if test -z "$global_symbol_pipe"; then + $echo + $echo "*** However, this would only work if libtool was able to extract symbol" + $echo "*** lists from a program, using \`nm' or equivalent, but libtool could" + $echo "*** not find such a program. So, this module is probably useless." + $echo "*** \`nm' from GNU binutils and a full rebuild may help." + fi + if test "$build_old_libs" = no; then + build_libtool_libs=module + build_old_libs=yes + else + build_libtool_libs=no + fi + fi + else + deplibs="$dir/$old_library $deplibs" + link_static=yes + fi + fi # link shared/static library? - # fixup the dll searchpath if we need to. - if test -n "$dllsearchpath"; then - $ECHO "\ - # Add the dll search path components to the executable PATH - PATH=$dllsearchpath:\$PATH -" - fi + if test "$linkmode" = lib; then + if test -n "$dependency_libs" && + { test "$hardcode_into_libs" != yes || + test "$build_old_libs" = yes || + test "$link_static" = yes; }; then + # Extract -R from dependency_libs + temp_deplibs= + for libdir in $dependency_libs; do + case $libdir in + -R*) temp_xrpath=`$echo "X$libdir" | $Xsed -e 's/^-R//'` + case " $xrpath " in + *" $temp_xrpath "*) ;; + *) xrpath="$xrpath $temp_xrpath";; + esac;; + *) temp_deplibs="$temp_deplibs $libdir";; + esac + done + dependency_libs="$temp_deplibs" + fi - $ECHO "\ - if test \"\$libtool_execute_magic\" != \"$magic\"; then - # Run the actual program with our arguments. -" - case $host in - # Backslashes separate directories on plain windows - *-*-mingw | *-*-os2* | *-cegcc*) - $ECHO "\ - exec \"\$progdir\\\\\$program\" \${1+\"\$@\"} -" - ;; + newlib_search_path="$newlib_search_path $absdir" + # Link against this library + test "$link_static" = no && newdependency_libs="$abs_ladir/$laname $newdependency_libs" + # ... and its dependency_libs + tmp_libs= + for deplib in $dependency_libs; do + newdependency_libs="$deplib $newdependency_libs" + if test "X$duplicate_deps" = "Xyes" ; then + case "$tmp_libs " in + *" $deplib "*) specialdeplibs="$specialdeplibs $deplib" ;; + esac + fi + tmp_libs="$tmp_libs $deplib" + done - *) - $ECHO "\ - exec \"\$progdir/\$program\" \${1+\"\$@\"} -" + if test "$link_all_deplibs" != no; then + # Add the search paths of all dependency libraries + for deplib in $dependency_libs; do + case $deplib in + -L*) path="$deplib" ;; + *.la) + dir=`$echo "X$deplib" | $Xsed -e 's%/[^/]*$%%'` + test "X$dir" = "X$deplib" && dir="." + # We need an absolute path. + case $dir in + [\\/]* | [A-Za-z]:[\\/]*) absdir="$dir" ;; + *) + absdir=`cd "$dir" && pwd` + if test -z "$absdir"; then + $echo "$modename: warning: cannot determine absolute directory name of \`$dir'" 1>&2 + absdir="$dir" + fi + ;; + esac + if grep "^installed=no" $deplib > /dev/null; then + path="$absdir/$objdir" + else + eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $deplib` + if test -z "$libdir"; then + $echo "$modename: \`$deplib' is not a valid libtool archive" 1>&2 + exit $EXIT_FAILURE + fi + if test "$absdir" != "$libdir"; then + $echo "$modename: warning: \`$deplib' seems to be moved" 1>&2 + fi + path="$absdir" + fi + depdepl= + case $host in + *-*-darwin*) + # we do not want to link against static libs, + # but need to link against shared + eval deplibrary_names=`${SED} -n -e 's/^library_names=\(.*\)$/\1/p' $deplib` + eval deplibdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $deplib` + if test -n "$deplibrary_names" ; then + for tmp in $deplibrary_names ; do + depdepl=$tmp + done + if test -f "$deplibdir/$depdepl" ; then + depdepl="$deplibdir/$depdepl" + elif test -f "$path/$depdepl" ; then + depdepl="$path/$depdepl" + else + # Can't find it, oh well... + depdepl= + fi + # do not add paths which are already there + case " $newlib_search_path " in + *" $path "*) ;; + *) newlib_search_path="$newlib_search_path $path";; + esac + fi + path="" + ;; + *) + path="-L$path" + ;; + esac + ;; + -l*) + case $host in + *-*-darwin*) + # Again, we only want to link against shared libraries + eval tmp_libs=`$echo "X$deplib" | $Xsed -e "s,^\-l,,"` + for tmp in $newlib_search_path ; do + if test -f "$tmp/lib$tmp_libs.dylib" ; then + eval depdepl="$tmp/lib$tmp_libs.dylib" + break + fi + done + path="" + ;; + *) continue ;; + esac + ;; + *) continue ;; + esac + case " $deplibs " in + *" $path "*) ;; + *) deplibs="$path $deplibs" ;; + esac + case " $deplibs " in + *" $depdepl "*) ;; + *) deplibs="$depdepl $deplibs" ;; + esac + done + fi # link_all_deplibs != no + fi # linkmode = lib + done # for deplib in $libs + dependency_libs="$newdependency_libs" + if test "$pass" = dlpreopen; then + # Link the dlpreopened libraries before other libraries + for deplib in $save_deplibs; do + deplibs="$deplib $deplibs" + done + fi + if test "$pass" != dlopen; then + if test "$pass" != conv; then + # Make sure lib_search_path contains only unique directories. + lib_search_path= + for dir in $newlib_search_path; do + case "$lib_search_path " in + *" $dir "*) ;; + *) lib_search_path="$lib_search_path $dir" ;; + esac + done + newlib_search_path= + fi + + if test "$linkmode,$pass" != "prog,link"; then + vars="deplibs" + else + vars="compile_deplibs finalize_deplibs" + fi + for var in $vars dependency_libs; do + # Add libraries to $var in reverse order + eval tmp_libs=\"\$$var\" + new_libs= + for deplib in $tmp_libs; do + # FIXME: Pedantically, this is the right thing to do, so + # that some nasty dependency loop isn't accidentally + # broken: + #new_libs="$deplib $new_libs" + # Pragmatically, this seems to cause very few problems in + # practice: + case $deplib in + -L*) new_libs="$deplib $new_libs" ;; + -R*) ;; + *) + # And here is the reason: when a library appears more + # than once as an explicit dependence of a library, or + # is implicitly linked in more than once by the + # compiler, it is considered special, and multiple + # occurrences thereof are not removed. Compare this + # with having the same library being listed as a + # dependency of multiple other libraries: in this case, + # we know (pedantically, we assume) the library does not + # need to be listed more than once, so we keep only the + # last copy. This is not always right, but it is rare + # enough that we require users that really mean to play + # such unportable linking tricks to link the library + # using -Wl,-lname, so that libtool does not consider it + # for duplicate removal. + case " $specialdeplibs " in + *" $deplib "*) new_libs="$deplib $new_libs" ;; + *) + case " $new_libs " in + *" $deplib "*) ;; + *) new_libs="$deplib $new_libs" ;; + esac + ;; + esac + ;; + esac + done + tmp_libs= + for deplib in $new_libs; do + case $deplib in + -L*) + case " $tmp_libs " in + *" $deplib "*) ;; + *) tmp_libs="$tmp_libs $deplib" ;; + esac + ;; + *) tmp_libs="$tmp_libs $deplib" ;; + esac + done + eval $var=\"$tmp_libs\" + done # for var + fi + # Last step: remove runtime libs from dependency_libs + # (they stay in deplibs) + tmp_libs= + for i in $dependency_libs ; do + case " $predeps $postdeps $compiler_lib_search_path " in + *" $i "*) + i="" ;; esac - $ECHO "\ - \$ECHO \"\$0: cannot exec \$program \$*\" 1>&2 - exit 1 + if test -n "$i" ; then + tmp_libs="$tmp_libs $i" + fi + done + dependency_libs=$tmp_libs + done # for pass + if test "$linkmode" = prog; then + dlfiles="$newdlfiles" + dlprefiles="$newdlprefiles" fi - else - # The program doesn't exist. - \$ECHO \"\$0: error: \\\`\$progdir/\$program' does not exist\" 1>&2 - \$ECHO \"This script is just a wrapper for \$program.\" 1>&2 - $ECHO \"See the $PACKAGE documentation for more information.\" 1>&2 - exit 1 - fi -fi\ -" -} -# end: func_emit_wrapper_part2 + case $linkmode in + oldlib) + case " $deplibs" in + *\ -l* | *\ -L*) + $echo "$modename: warning: \`-l' and \`-L' are ignored for archives" 1>&2 ;; + esac -# func_emit_wrapper [arg=no] -# -# Emit a libtool wrapper script on stdout. -# Don't directly open a file because we may want to -# incorporate the script contents within a cygwin/mingw -# wrapper executable. Must ONLY be called from within -# func_mode_link because it depends on a number of variables -# set therein. -# -# ARG is the value that the WRAPPER_SCRIPT_BELONGS_IN_OBJDIR -# variable will take. If 'yes', then the emitted script -# will assume that the directory in which it is stored is -# the $objdir directory. This is a cygwin/mingw-specific -# behavior. -func_emit_wrapper () -{ - func_emit_wrapper_arg1=no - if test -n "$1" ; then - func_emit_wrapper_arg1=$1 - fi + if test -n "$dlfiles$dlprefiles" || test "$dlself" != no; then + $echo "$modename: warning: \`-dlopen' is ignored for archives" 1>&2 + fi - # split this up so that func_emit_cwrapperexe_src - # can call each part independently. - func_emit_wrapper_part1 "${func_emit_wrapper_arg1}" - func_emit_wrapper_part2 "${func_emit_wrapper_arg1}" -} + if test -n "$rpath"; then + $echo "$modename: warning: \`-rpath' is ignored for archives" 1>&2 + fi + if test -n "$xrpath"; then + $echo "$modename: warning: \`-R' is ignored for archives" 1>&2 + fi -# func_to_host_path arg -# -# Convert paths to host format when used with build tools. -# Intended for use with "native" mingw (where libtool itself -# is running under the msys shell), or in the following cross- -# build environments: -# $build $host -# mingw (msys) mingw [e.g. native] -# cygwin mingw -# *nix + wine mingw -# where wine is equipped with the `winepath' executable. -# In the native mingw case, the (msys) shell automatically -# converts paths for any non-msys applications it launches, -# but that facility isn't available from inside the cwrapper. -# Similar accommodations are necessary for $host mingw and -# $build cygwin. Calling this function does no harm for other -# $host/$build combinations not listed above. -# -# ARG is the path (on $build) that should be converted to -# the proper representation for $host. The result is stored -# in $func_to_host_path_result. -func_to_host_path () -{ - func_to_host_path_result="$1" - if test -n "$1" ; then - case $host in - *mingw* ) - lt_sed_naive_backslashify='s|\\\\*|\\|g;s|/|\\|g;s|\\|\\\\|g' - case $build in - *mingw* ) # actually, msys - # awkward: cmd appends spaces to result - lt_sed_strip_trailing_spaces="s/[ ]*\$//" - func_to_host_path_tmp1=`( cmd //c echo "$1" |\ - $SED -e "$lt_sed_strip_trailing_spaces" ) 2>/dev/null || echo ""` - func_to_host_path_result=`echo "$func_to_host_path_tmp1" |\ - $SED -e "$lt_sed_naive_backslashify"` - ;; - *cygwin* ) - func_to_host_path_tmp1=`cygpath -w "$1"` - func_to_host_path_result=`echo "$func_to_host_path_tmp1" |\ - $SED -e "$lt_sed_naive_backslashify"` - ;; - * ) - # Unfortunately, winepath does not exit with a non-zero - # error code, so we are forced to check the contents of - # stdout. On the other hand, if the command is not - # found, the shell will set an exit code of 127 and print - # *an error message* to stdout. So we must check for both - # error code of zero AND non-empty stdout, which explains - # the odd construction: - func_to_host_path_tmp1=`winepath -w "$1" 2>/dev/null` - if test "$?" -eq 0 && test -n "${func_to_host_path_tmp1}"; then - func_to_host_path_result=`echo "$func_to_host_path_tmp1" |\ - $SED -e "$lt_sed_naive_backslashify"` - else - # Allow warning below. - func_to_host_path_result="" - fi - ;; - esac - if test -z "$func_to_host_path_result" ; then - func_error "Could not determine host path corresponding to" - func_error " '$1'" - func_error "Continuing, but uninstalled executables may not work." - # Fallback: - func_to_host_path_result="$1" - fi - ;; - esac - fi -} -# end: func_to_host_path + if test -n "$vinfo"; then + $echo "$modename: warning: \`-version-info/-version-number' is ignored for archives" 1>&2 + fi -# func_to_host_pathlist arg -# -# Convert pathlists to host format when used with build tools. -# See func_to_host_path(), above. This function supports the -# following $build/$host combinations (but does no harm for -# combinations not listed here): -# $build $host -# mingw (msys) mingw [e.g. native] -# cygwin mingw -# *nix + wine mingw -# -# Path separators are also converted from $build format to -# $host format. If ARG begins or ends with a path separator -# character, it is preserved (but converted to $host format) -# on output. -# -# ARG is a pathlist (on $build) that should be converted to -# the proper representation on $host. The result is stored -# in $func_to_host_pathlist_result. -func_to_host_pathlist () -{ - func_to_host_pathlist_result="$1" - if test -n "$1" ; then - case $host in - *mingw* ) - lt_sed_naive_backslashify='s|\\\\*|\\|g;s|/|\\|g;s|\\|\\\\|g' - # Remove leading and trailing path separator characters from - # ARG. msys behavior is inconsistent here, cygpath turns them - # into '.;' and ';.', and winepath ignores them completely. - func_to_host_pathlist_tmp2="$1" - # Once set for this call, this variable should not be - # reassigned. It is used in tha fallback case. - func_to_host_pathlist_tmp1=`echo "$func_to_host_pathlist_tmp2" |\ - $SED -e 's|^:*||' -e 's|:*$||'` - case $build in - *mingw* ) # Actually, msys. - # Awkward: cmd appends spaces to result. - lt_sed_strip_trailing_spaces="s/[ ]*\$//" - func_to_host_pathlist_tmp2=`( cmd //c echo "$func_to_host_pathlist_tmp1" |\ - $SED -e "$lt_sed_strip_trailing_spaces" ) 2>/dev/null || echo ""` - func_to_host_pathlist_result=`echo "$func_to_host_pathlist_tmp2" |\ - $SED -e "$lt_sed_naive_backslashify"` - ;; - *cygwin* ) - func_to_host_pathlist_tmp2=`cygpath -w -p "$func_to_host_pathlist_tmp1"` - func_to_host_pathlist_result=`echo "$func_to_host_pathlist_tmp2" |\ - $SED -e "$lt_sed_naive_backslashify"` - ;; - * ) - # unfortunately, winepath doesn't convert pathlists - func_to_host_pathlist_result="" - func_to_host_pathlist_oldIFS=$IFS - IFS=: - for func_to_host_pathlist_f in $func_to_host_pathlist_tmp1 ; do - IFS=$func_to_host_pathlist_oldIFS - if test -n "$func_to_host_pathlist_f" ; then - func_to_host_path "$func_to_host_pathlist_f" - if test -n "$func_to_host_path_result" ; then - if test -z "$func_to_host_pathlist_result" ; then - func_to_host_pathlist_result="$func_to_host_path_result" - else - func_to_host_pathlist_result="$func_to_host_pathlist_result;$func_to_host_path_result" - fi - fi - fi - IFS=: - done - IFS=$func_to_host_pathlist_oldIFS - ;; - esac - if test -z "$func_to_host_pathlist_result" ; then - func_error "Could not determine the host path(s) corresponding to" - func_error " '$1'" - func_error "Continuing, but uninstalled executables may not work." - # Fallback. This may break if $1 contains DOS-style drive - # specifications. The fix is not to complicate the expression - # below, but for the user to provide a working wine installation - # with winepath so that path translation in the cross-to-mingw - # case works properly. - lt_replace_pathsep_nix_to_dos="s|:|;|g" - func_to_host_pathlist_result=`echo "$func_to_host_pathlist_tmp1" |\ - $SED -e "$lt_replace_pathsep_nix_to_dos"` - fi - # Now, add the leading and trailing path separators back - case "$1" in - :* ) func_to_host_pathlist_result=";$func_to_host_pathlist_result" - ;; - esac - case "$1" in - *: ) func_to_host_pathlist_result="$func_to_host_pathlist_result;" - ;; - esac - ;; - esac - fi -} -# end: func_to_host_pathlist + if test -n "$release"; then + $echo "$modename: warning: \`-release' is ignored for archives" 1>&2 + fi -# func_emit_cwrapperexe_src -# emit the source code for a wrapper executable on stdout -# Must ONLY be called from within func_mode_link because -# it depends on a number of variable set therein. -func_emit_cwrapperexe_src () -{ - cat <&2 + fi - The $output program cannot be directly executed until all the libtool - libraries that it depends on are installed. + # Now set the variables for building old libraries. + build_libtool_libs=no + oldlibs="$output" + objs="$objs$old_deplibs" + ;; - This wrapper executable should never be moved out of the build directory. - If it is, it will not operate correctly. + lib) + # Make sure we only generate libraries of the form `libNAME.la'. + case $outputname in + lib*) + name=`$echo "X$outputname" | $Xsed -e 's/\.la$//' -e 's/^lib//'` + eval shared_ext=\"$shrext_cmds\" + eval libname=\"$libname_spec\" + ;; + *) + if test "$module" = no; then + $echo "$modename: libtool library \`$output' must begin with \`lib'" 1>&2 + $echo "$help" 1>&2 + exit $EXIT_FAILURE + fi + if test "$need_lib_prefix" != no; then + # Add the "lib" prefix for modules if required + name=`$echo "X$outputname" | $Xsed -e 's/\.la$//'` + eval shared_ext=\"$shrext_cmds\" + eval libname=\"$libname_spec\" + else + libname=`$echo "X$outputname" | $Xsed -e 's/\.la$//'` + fi + ;; + esac - Currently, it simply execs the wrapper *script* "$SHELL $output", - but could eventually absorb all of the scripts functionality and - exec $objdir/$outputname directly. -*/ -EOF - cat <<"EOF" -#include -#include -#ifdef _MSC_VER -# include -# include -# include -# define setmode _setmode -#else -# include -# include -# ifdef __CYGWIN__ -# include -# define HAVE_SETENV -# ifdef __STRICT_ANSI__ -char *realpath (const char *, char *); -int putenv (char *); -int setenv (const char *, const char *, int); -# endif -# endif -#endif -#include -#include -#include -#include -#include -#include -#include -#include + if test -n "$objs"; then + if test "$deplibs_check_method" != pass_all; then + $echo "$modename: cannot build libtool library \`$output' from non-libtool objects on this host:$objs" 2>&1 + exit $EXIT_FAILURE + else + $echo + $echo "*** Warning: Linking the shared library $output against the non-libtool" + $echo "*** objects $objs is not portable!" + libobjs="$libobjs $objs" + fi + fi -#if defined(PATH_MAX) -# define LT_PATHMAX PATH_MAX -#elif defined(MAXPATHLEN) -# define LT_PATHMAX MAXPATHLEN -#else -# define LT_PATHMAX 1024 -#endif + if test "$dlself" != no; then + $echo "$modename: warning: \`-dlopen self' is ignored for libtool libraries" 1>&2 + fi -#ifndef S_IXOTH -# define S_IXOTH 0 -#endif -#ifndef S_IXGRP -# define S_IXGRP 0 -#endif + set dummy $rpath + if test "$#" -gt 2; then + $echo "$modename: warning: ignoring multiple \`-rpath's for a libtool library" 1>&2 + fi + install_libdir="$2" -#ifdef _MSC_VER -# define S_IXUSR _S_IEXEC -# define stat _stat -# ifndef _INTPTR_T_DEFINED -# define intptr_t int -# endif -#endif + oldlibs= + if test -z "$rpath"; then + if test "$build_libtool_libs" = yes; then + # Building a libtool convenience library. + # Some compilers have problems with a `.al' extension so + # convenience libraries should have the same extension an + # archive normally would. + oldlibs="$output_objdir/$libname.$libext $oldlibs" + build_libtool_libs=convenience + build_old_libs=yes + fi -#ifndef DIR_SEPARATOR -# define DIR_SEPARATOR '/' -# define PATH_SEPARATOR ':' -#endif + if test -n "$vinfo"; then + $echo "$modename: warning: \`-version-info/-version-number' is ignored for convenience libraries" 1>&2 + fi -#if defined (_WIN32) || defined (__MSDOS__) || defined (__DJGPP__) || \ - defined (__OS2__) -# define HAVE_DOS_BASED_FILE_SYSTEM -# define FOPEN_WB "wb" -# ifndef DIR_SEPARATOR_2 -# define DIR_SEPARATOR_2 '\\' -# endif -# ifndef PATH_SEPARATOR_2 -# define PATH_SEPARATOR_2 ';' -# endif -#endif + if test -n "$release"; then + $echo "$modename: warning: \`-release' is ignored for convenience libraries" 1>&2 + fi + else -#ifndef DIR_SEPARATOR_2 -# define IS_DIR_SEPARATOR(ch) ((ch) == DIR_SEPARATOR) -#else /* DIR_SEPARATOR_2 */ -# define IS_DIR_SEPARATOR(ch) \ - (((ch) == DIR_SEPARATOR) || ((ch) == DIR_SEPARATOR_2)) -#endif /* DIR_SEPARATOR_2 */ + # Parse the version information argument. + save_ifs="$IFS"; IFS=':' + set dummy $vinfo 0 0 0 + IFS="$save_ifs" -#ifndef PATH_SEPARATOR_2 -# define IS_PATH_SEPARATOR(ch) ((ch) == PATH_SEPARATOR) -#else /* PATH_SEPARATOR_2 */ -# define IS_PATH_SEPARATOR(ch) ((ch) == PATH_SEPARATOR_2) -#endif /* PATH_SEPARATOR_2 */ + if test -n "$8"; then + $echo "$modename: too many parameters to \`-version-info'" 1>&2 + $echo "$help" 1>&2 + exit $EXIT_FAILURE + fi -#ifdef __CYGWIN__ -# define FOPEN_WB "wb" -#endif + # convert absolute version numbers to libtool ages + # this retains compatibility with .la files and attempts + # to make the code below a bit more comprehensible -#ifndef FOPEN_WB -# define FOPEN_WB "w" -#endif -#ifndef _O_BINARY -# define _O_BINARY 0 -#endif + case $vinfo_number in + yes) + number_major="$2" + number_minor="$3" + number_revision="$4" + # + # There are really only two kinds -- those that + # use the current revision as the major version + # and those that subtract age and use age as + # a minor version. But, then there is irix + # which has an extra 1 added just for fun + # + case $version_type in + darwin|linux|osf|windows|none) + current=`expr $number_major + $number_minor` + age="$number_minor" + revision="$number_revision" + ;; + freebsd-aout|freebsd-elf|sunos) + current="$number_major" + revision="$number_minor" + age="0" + ;; + irix|nonstopux) + current=`expr $number_major + $number_minor` + age="$number_minor" + revision="$number_minor" + lt_irix_increment=no + ;; + esac + ;; + no) + current="$2" + revision="$3" + age="$4" + ;; + esac -#define XMALLOC(type, num) ((type *) xmalloc ((num) * sizeof(type))) -#define XFREE(stale) do { \ - if (stale) { free ((void *) stale); stale = 0; } \ -} while (0) + # Check that each of the things are valid numbers. + case $current in + 0|[1-9]|[1-9][0-9]|[1-9][0-9][0-9]|[1-9][0-9][0-9][0-9]|[1-9][0-9][0-9][0-9][0-9]) ;; + *) + $echo "$modename: CURRENT \`$current' must be a nonnegative integer" 1>&2 + $echo "$modename: \`$vinfo' is not valid version information" 1>&2 + exit $EXIT_FAILURE + ;; + esac -#undef LTWRAPPER_DEBUGPRINTF -#if defined DEBUGWRAPPER -# define LTWRAPPER_DEBUGPRINTF(args) ltwrapper_debugprintf args -static void -ltwrapper_debugprintf (const char *fmt, ...) -{ - va_list args; - va_start (args, fmt); - (void) vfprintf (stderr, fmt, args); - va_end (args); -} -#else -# define LTWRAPPER_DEBUGPRINTF(args) -#endif + case $revision in + 0|[1-9]|[1-9][0-9]|[1-9][0-9][0-9]|[1-9][0-9][0-9][0-9]|[1-9][0-9][0-9][0-9][0-9]) ;; + *) + $echo "$modename: REVISION \`$revision' must be a nonnegative integer" 1>&2 + $echo "$modename: \`$vinfo' is not valid version information" 1>&2 + exit $EXIT_FAILURE + ;; + esac -const char *program_name = NULL; + case $age in + 0|[1-9]|[1-9][0-9]|[1-9][0-9][0-9]|[1-9][0-9][0-9][0-9]|[1-9][0-9][0-9][0-9][0-9]) ;; + *) + $echo "$modename: AGE \`$age' must be a nonnegative integer" 1>&2 + $echo "$modename: \`$vinfo' is not valid version information" 1>&2 + exit $EXIT_FAILURE + ;; + esac -void *xmalloc (size_t num); -char *xstrdup (const char *string); -const char *base_name (const char *name); -char *find_executable (const char *wrapper); -char *chase_symlinks (const char *pathspec); -int make_executable (const char *path); -int check_executable (const char *path); -char *strendzap (char *str, const char *pat); -void lt_fatal (const char *message, ...); -void lt_setenv (const char *name, const char *value); -char *lt_extend_str (const char *orig_value, const char *add, int to_end); -void lt_opt_process_env_set (const char *arg); -void lt_opt_process_env_prepend (const char *arg); -void lt_opt_process_env_append (const char *arg); -int lt_split_name_value (const char *arg, char** name, char** value); -void lt_update_exe_path (const char *name, const char *value); -void lt_update_lib_path (const char *name, const char *value); - -static const char *script_text_part1 = -EOF + if test "$age" -gt "$current"; then + $echo "$modename: AGE \`$age' is greater than the current interface number \`$current'" 1>&2 + $echo "$modename: \`$vinfo' is not valid version information" 1>&2 + exit $EXIT_FAILURE + fi - func_emit_wrapper_part1 yes | - $SED -e 's/\([\\"]\)/\\\1/g' \ - -e 's/^/ "/' -e 's/$/\\n"/' - echo ";" - cat <&2 + $echo "Fatal configuration error. See the $PACKAGE docs for more information." 1>&2 + exit $EXIT_FAILURE + ;; + esac - int i; - - program_name = (char *) xstrdup (base_name (argv[0])); - LTWRAPPER_DEBUGPRINTF (("(main) argv[0] : %s\n", argv[0])); - LTWRAPPER_DEBUGPRINTF (("(main) program_name : %s\n", program_name)); - - /* very simple arg parsing; don't want to rely on getopt */ - for (i = 1; i < argc; i++) - { - if (strcmp (argv[i], dumpscript_opt) == 0) - { -EOF - case "$host" in - *mingw* | *cygwin* ) - # make stdout use "unix" line endings - echo " setmode(1,_O_BINARY);" - ;; - esac - - cat <<"EOF" - printf ("%s", script_text_part1); - printf ("%s", script_text_part2); - return 0; - } - } - - newargz = XMALLOC (char *, argc + 1); - tmp_pathspec = find_executable (argv[0]); - if (tmp_pathspec == NULL) - lt_fatal ("Couldn't find %s", argv[0]); - LTWRAPPER_DEBUGPRINTF (("(main) found exe (before symlink chase) at : %s\n", - tmp_pathspec)); - - actual_cwrapper_path = chase_symlinks (tmp_pathspec); - LTWRAPPER_DEBUGPRINTF (("(main) found exe (after symlink chase) at : %s\n", - actual_cwrapper_path)); - XFREE (tmp_pathspec); - - actual_cwrapper_name = xstrdup( base_name (actual_cwrapper_path)); - strendzap (actual_cwrapper_path, actual_cwrapper_name); - - /* wrapper name transforms */ - strendzap (actual_cwrapper_name, ".exe"); - tmp_pathspec = lt_extend_str (actual_cwrapper_name, ".exe", 1); - XFREE (actual_cwrapper_name); - actual_cwrapper_name = tmp_pathspec; - tmp_pathspec = 0; - - /* target_name transforms -- use actual target program name; might have lt- prefix */ - target_name = xstrdup (base_name (TARGET_PROGRAM_NAME)); - strendzap (target_name, ".exe"); - tmp_pathspec = lt_extend_str (target_name, ".exe", 1); - XFREE (target_name); - target_name = tmp_pathspec; - tmp_pathspec = 0; - - LTWRAPPER_DEBUGPRINTF (("(main) libtool target name: %s\n", - target_name)); -EOF - - cat <"))); - for (i = 0; i < newargc; i++) - { - LTWRAPPER_DEBUGPRINTF (("(main) newargz[%d] : %s\n", i, (newargz[i] ? newargz[i] : ""))); - } - -EOF - - case $host_os in - mingw*) - cat <<"EOF" - /* execv doesn't actually work on mingw as expected on unix */ - rval = _spawnv (_P_WAIT, lt_argv_zero, (const char * const *) newargz); - if (rval == -1) - { - /* failed to start process */ - LTWRAPPER_DEBUGPRINTF (("(main) failed to launch target \"%s\": errno = %d\n", lt_argv_zero, errno)); - return 127; - } - return rval; -EOF - ;; - *) - cat <<"EOF" - execv (lt_argv_zero, newargz); - return rval; /* =127, but avoids unused variable warning */ -EOF - ;; - esac - - cat <<"EOF" -} - -void * -xmalloc (size_t num) -{ - void *p = (void *) malloc (num); - if (!p) - lt_fatal ("Memory exhausted"); - - return p; -} - -char * -xstrdup (const char *string) -{ - return string ? strcpy ((char *) xmalloc (strlen (string) + 1), - string) : NULL; -} - -const char * -base_name (const char *name) -{ - const char *base; - -#if defined (HAVE_DOS_BASED_FILE_SYSTEM) - /* Skip over the disk name in MSDOS pathnames. */ - if (isalpha ((unsigned char) name[0]) && name[1] == ':') - name += 2; -#endif - - for (base = name; *name; name++) - if (IS_DIR_SEPARATOR (*name)) - base = name + 1; - return base; -} + *) + verstring="0.0" + ;; + esac + if test "$need_version" = no; then + versuffix= + else + versuffix=".0.0" + fi + fi -int -check_executable (const char *path) -{ - struct stat st; + # Remove version info from name if versioning should be avoided + if test "$avoid_version" = yes && test "$need_version" = no; then + major= + versuffix= + verstring="" + fi - LTWRAPPER_DEBUGPRINTF (("(check_executable) : %s\n", - path ? (*path ? path : "EMPTY!") : "NULL!")); - if ((!path) || (!*path)) - return 0; + # Check to see if the archive will have undefined symbols. + if test "$allow_undefined" = yes; then + if test "$allow_undefined_flag" = unsupported; then + $echo "$modename: warning: undefined symbols not allowed in $host shared libraries" 1>&2 + build_libtool_libs=no + build_old_libs=yes + fi + else + # Don't allow undefined symbols. + allow_undefined_flag="$no_undefined_flag" + fi + fi - if ((stat (path, &st) >= 0) - && (st.st_mode & (S_IXUSR | S_IXGRP | S_IXOTH))) - return 1; - else - return 0; -} + if test "$mode" != relink; then + # Remove our outputs, but don't remove object files since they + # may have been created when compiling PIC objects. + removelist= + tempremovelist=`$echo "$output_objdir/*"` + for p in $tempremovelist; do + case $p in + *.$objext) + ;; + $output_objdir/$outputname | $output_objdir/$libname.* | $output_objdir/${libname}${release}.*) + if test "X$precious_files_regex" != "X"; then + if echo $p | $EGREP -e "$precious_files_regex" >/dev/null 2>&1 + then + continue + fi + fi + removelist="$removelist $p" + ;; + *) ;; + esac + done + if test -n "$removelist"; then + $show "${rm}r $removelist" + $run ${rm}r $removelist + fi + fi -int -make_executable (const char *path) -{ - int rval = 0; - struct stat st; + # Now set the variables for building old libraries. + if test "$build_old_libs" = yes && test "$build_libtool_libs" != convenience ; then + oldlibs="$oldlibs $output_objdir/$libname.$libext" - LTWRAPPER_DEBUGPRINTF (("(make_executable) : %s\n", - path ? (*path ? path : "EMPTY!") : "NULL!")); - if ((!path) || (!*path)) - return 0; + # Transform .lo files to .o files. + oldobjs="$objs "`$echo "X$libobjs" | $SP2NL | $Xsed -e '/\.'${libext}'$/d' -e "$lo2o" | $NL2SP` + fi - if (stat (path, &st) >= 0) - { - rval = chmod (path, st.st_mode | S_IXOTH | S_IXGRP | S_IXUSR); - } - return rval; -} + # Eliminate all temporary directories. + #for path in $notinst_path; do + # lib_search_path=`$echo "$lib_search_path " | ${SED} -e "s% $path % %g"` + # deplibs=`$echo "$deplibs " | ${SED} -e "s% -L$path % %g"` + # dependency_libs=`$echo "$dependency_libs " | ${SED} -e "s% -L$path % %g"` + #done -/* Searches for the full path of the wrapper. Returns - newly allocated full path name if found, NULL otherwise - Does not chase symlinks, even on platforms that support them. -*/ -char * -find_executable (const char *wrapper) -{ - int has_slash = 0; - const char *p; - const char *p_next; - /* static buffer for getcwd */ - char tmp[LT_PATHMAX + 1]; - int tmp_len; - char *concat_name; + if test -n "$xrpath"; then + # If the user specified any rpath flags, then add them. + temp_xrpath= + for libdir in $xrpath; do + temp_xrpath="$temp_xrpath -R$libdir" + case "$finalize_rpath " in + *" $libdir "*) ;; + *) finalize_rpath="$finalize_rpath $libdir" ;; + esac + done + if test "$hardcode_into_libs" != yes || test "$build_old_libs" = yes; then + dependency_libs="$temp_xrpath $dependency_libs" + fi + fi - LTWRAPPER_DEBUGPRINTF (("(find_executable) : %s\n", - wrapper ? (*wrapper ? wrapper : "EMPTY!") : "NULL!")); + # Make sure dlfiles contains only unique files that won't be dlpreopened + old_dlfiles="$dlfiles" + dlfiles= + for lib in $old_dlfiles; do + case " $dlprefiles $dlfiles " in + *" $lib "*) ;; + *) dlfiles="$dlfiles $lib" ;; + esac + done - if ((wrapper == NULL) || (*wrapper == '\0')) - return NULL; + # Make sure dlprefiles contains only unique files + old_dlprefiles="$dlprefiles" + dlprefiles= + for lib in $old_dlprefiles; do + case "$dlprefiles " in + *" $lib "*) ;; + *) dlprefiles="$dlprefiles $lib" ;; + esac + done - /* Absolute path? */ -#if defined (HAVE_DOS_BASED_FILE_SYSTEM) - if (isalpha ((unsigned char) wrapper[0]) && wrapper[1] == ':') - { - concat_name = xstrdup (wrapper); - if (check_executable (concat_name)) - return concat_name; - XFREE (concat_name); - } - else - { -#endif - if (IS_DIR_SEPARATOR (wrapper[0])) - { - concat_name = xstrdup (wrapper); - if (check_executable (concat_name)) - return concat_name; - XFREE (concat_name); - } -#if defined (HAVE_DOS_BASED_FILE_SYSTEM) - } -#endif + if test "$build_libtool_libs" = yes; then + if test -n "$rpath"; then + case $host in + *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-*-beos*) + # these systems don't actually have a c library (as such)! + ;; + *-*-rhapsody* | *-*-darwin1.[012]) + # Rhapsody C library is in the System framework + deplibs="$deplibs -framework System" + ;; + *-*-netbsd*) + # Don't link with libc until the a.out ld.so is fixed. + ;; + *-*-openbsd* | *-*-freebsd* | *-*-dragonfly*) + # Do not include libc due to us having libc/libc_r. + ;; + *-*-sco3.2v5* | *-*-sco5v6*) + # Causes problems with __ctype + ;; + *-*-sysv4.2uw2* | *-*-sysv5* | *-*-unixware* | *-*-OpenUNIX*) + # Compiler inserts libc in the correct place for threads to work + ;; + *) + # Add libc to deplibs on all other systems if necessary. + if test "$build_libtool_need_lc" = "yes"; then + deplibs="$deplibs -lc" + fi + ;; + esac + fi - for (p = wrapper; *p; p++) - if (*p == '/') - { - has_slash = 1; - break; - } - if (!has_slash) - { - /* no slashes; search PATH */ - const char *path = getenv ("PATH"); - if (path != NULL) - { - for (p = path; *p; p = p_next) - { - const char *q; - size_t p_len; - for (q = p; *q; q++) - if (IS_PATH_SEPARATOR (*q)) - break; - p_len = q - p; - p_next = (*q == '\0' ? q : q + 1); - if (p_len == 0) - { - /* empty path: current directory */ - if (getcwd (tmp, LT_PATHMAX) == NULL) - lt_fatal ("getcwd failed"); - tmp_len = strlen (tmp); - concat_name = - XMALLOC (char, tmp_len + 1 + strlen (wrapper) + 1); - memcpy (concat_name, tmp, tmp_len); - concat_name[tmp_len] = '/'; - strcpy (concat_name + tmp_len + 1, wrapper); - } - else - { - concat_name = - XMALLOC (char, p_len + 1 + strlen (wrapper) + 1); - memcpy (concat_name, p, p_len); - concat_name[p_len] = '/'; - strcpy (concat_name + p_len + 1, wrapper); - } - if (check_executable (concat_name)) - return concat_name; - XFREE (concat_name); - } - } - /* not found in PATH; assume curdir */ - } - /* Relative path | not found in path: prepend cwd */ - if (getcwd (tmp, LT_PATHMAX) == NULL) - lt_fatal ("getcwd failed"); - tmp_len = strlen (tmp); - concat_name = XMALLOC (char, tmp_len + 1 + strlen (wrapper) + 1); - memcpy (concat_name, tmp, tmp_len); - concat_name[tmp_len] = '/'; - strcpy (concat_name + tmp_len + 1, wrapper); - - if (check_executable (concat_name)) - return concat_name; - XFREE (concat_name); - return NULL; -} - -char * -chase_symlinks (const char *pathspec) -{ -#ifndef S_ISLNK - return xstrdup (pathspec); -#else - char buf[LT_PATHMAX]; - struct stat s; - char *tmp_pathspec = xstrdup (pathspec); - char *p; - int has_symlinks = 0; - while (strlen (tmp_pathspec) && !has_symlinks) - { - LTWRAPPER_DEBUGPRINTF (("checking path component for symlinks: %s\n", - tmp_pathspec)); - if (lstat (tmp_pathspec, &s) == 0) - { - if (S_ISLNK (s.st_mode) != 0) - { - has_symlinks = 1; - break; - } - - /* search backwards for last DIR_SEPARATOR */ - p = tmp_pathspec + strlen (tmp_pathspec) - 1; - while ((p > tmp_pathspec) && (!IS_DIR_SEPARATOR (*p))) - p--; - if ((p == tmp_pathspec) && (!IS_DIR_SEPARATOR (*p))) - { - /* no more DIR_SEPARATORS left */ - break; - } - *p = '\0'; - } - else - { - char *errstr = strerror (errno); - lt_fatal ("Error accessing file %s (%s)", tmp_pathspec, errstr); - } - } - XFREE (tmp_pathspec); - - if (!has_symlinks) - { - return xstrdup (pathspec); - } - - tmp_pathspec = realpath (pathspec, buf); - if (tmp_pathspec == 0) - { - lt_fatal ("Could not follow symlinks for %s", pathspec); - } - return xstrdup (tmp_pathspec); -#endif -} - -char * -strendzap (char *str, const char *pat) -{ - size_t len, patlen; + # Transform deplibs into only deplibs that can be linked in shared. + name_save=$name + libname_save=$libname + release_save=$release + versuffix_save=$versuffix + major_save=$major + # I'm not sure if I'm treating the release correctly. I think + # release should show up in the -l (ie -lgmp5) so we don't want to + # add it in twice. Is that correct? + release="" + versuffix="" + major="" + newdeplibs= + droppeddeps=no + case $deplibs_check_method in + pass_all) + # Don't check for shared/static. Everything works. + # This might be a little naive. We might want to check + # whether the library exists or not. But this is on + # osf3 & osf4 and I'm not really sure... Just + # implementing what was already the behavior. + newdeplibs=$deplibs + ;; + test_compile) + # This code stresses the "libraries are programs" paradigm to its + # limits. Maybe even breaks it. We compile a program, linking it + # against the deplibs as a proxy for the library. Then we can check + # whether they linked in statically or dynamically with ldd. + $rm conftest.c + cat > conftest.c </dev/null` + for potent_lib in $potential_libs; do + # Follow soft links. + if ls -lLd "$potent_lib" 2>/dev/null \ + | grep " -> " >/dev/null; then + continue + fi + # The statement above tries to avoid entering an + # endless loop below, in case of cyclic links. + # We might still enter an endless loop, since a link + # loop can be closed while we follow links, + # but so what? + potlib="$potent_lib" + while test -h "$potlib" 2>/dev/null; do + potliblink=`ls -ld $potlib | ${SED} 's/.* -> //'` + case $potliblink in + [\\/]* | [A-Za-z]:[\\/]*) potlib="$potliblink";; + *) potlib=`$echo "X$potlib" | $Xsed -e 's,[^/]*$,,'`"$potliblink";; + esac + done + if eval $file_magic_cmd \"\$potlib\" 2>/dev/null \ + | ${SED} 10q \ + | $EGREP "$file_magic_regex" > /dev/null; then + newdeplibs="$newdeplibs $a_deplib" + a_deplib="" + break 2 + fi + done + done + fi + if test -n "$a_deplib" ; then + droppeddeps=yes + $echo + $echo "*** Warning: linker path does not have real file for library $a_deplib." + $echo "*** I have the capability to make that library automatically link in when" + $echo "*** you link to this library. But I can only do this if you have a" + $echo "*** shared version of the library, which you do not appear to have" + $echo "*** because I did check the linker path looking for a file starting" + if test -z "$potlib" ; then + $echo "*** with $libname but no candidates were found. (...for file magic test)" + else + $echo "*** with $libname and none of the candidates passed a file format test" + $echo "*** using a file magic. Last file checked: $potlib" + fi + fi + else + # Add a -L argument. + newdeplibs="$newdeplibs $a_deplib" + fi + done # Gone through all deplibs. + ;; + match_pattern*) + set dummy $deplibs_check_method + match_pattern_regex=`expr "$deplibs_check_method" : "$2 \(.*\)"` + for a_deplib in $deplibs; do + name=`expr $a_deplib : '-l\(.*\)'` + # If $name is empty we are operating on a -L argument. + if test -n "$name" && test "$name" != "0"; then + if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then + case " $predeps $postdeps " in + *" $a_deplib "*) + newdeplibs="$newdeplibs $a_deplib" + a_deplib="" + ;; + esac + fi + if test -n "$a_deplib" ; then + libname=`eval \\$echo \"$libname_spec\"` + for i in $lib_search_path $sys_lib_search_path $shlib_search_path; do + potential_libs=`ls $i/$libname[.-]* 2>/dev/null` + for potent_lib in $potential_libs; do + potlib="$potent_lib" # see symlink-check above in file_magic test + if eval $echo \"$potent_lib\" 2>/dev/null \ + | ${SED} 10q \ + | $EGREP "$match_pattern_regex" > /dev/null; then + newdeplibs="$newdeplibs $a_deplib" + a_deplib="" + break 2 + fi + done + done + fi + if test -n "$a_deplib" ; then + droppeddeps=yes + $echo + $echo "*** Warning: linker path does not have real file for library $a_deplib." + $echo "*** I have the capability to make that library automatically link in when" + $echo "*** you link to this library. But I can only do this if you have a" + $echo "*** shared version of the library, which you do not appear to have" + $echo "*** because I did check the linker path looking for a file starting" + if test -z "$potlib" ; then + $echo "*** with $libname but no candidates were found. (...for regex pattern test)" + else + $echo "*** with $libname and none of the candidates passed a file format test" + $echo "*** using a regex pattern. Last file checked: $potlib" + fi + fi + else + # Add a -L argument. + newdeplibs="$newdeplibs $a_deplib" + fi + done # Gone through all deplibs. + ;; + none | unknown | *) + newdeplibs="" + tmp_deplibs=`$echo "X $deplibs" | $Xsed -e 's/ -lc$//' \ + -e 's/ -[LR][^ ]*//g'` + if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then + for i in $predeps $postdeps ; do + # can't use Xsed below, because $i might contain '/' + tmp_deplibs=`$echo "X $tmp_deplibs" | ${SED} -e "1s,^X,," -e "s,$i,,"` + done + fi + if $echo "X $tmp_deplibs" | $Xsed -e 's/[ ]//g' \ + | grep . >/dev/null; then + $echo + if test "X$deplibs_check_method" = "Xnone"; then + $echo "*** Warning: inter-library dependencies are not supported in this platform." + else + $echo "*** Warning: inter-library dependencies are not known to be supported." + fi + $echo "*** All declared inter-library dependencies are being dropped." + droppeddeps=yes + fi + ;; + esac + versuffix=$versuffix_save + major=$major_save + release=$release_save + libname=$libname_save + name=$name_save - assert (str != NULL); - assert (pat != NULL); + case $host in + *-*-rhapsody* | *-*-darwin1.[012]) + # On Rhapsody replace the C library is the System framework + newdeplibs=`$echo "X $newdeplibs" | $Xsed -e 's/ -lc / -framework System /'` + ;; + esac - len = strlen (str); - patlen = strlen (pat); + if test "$droppeddeps" = yes; then + if test "$module" = yes; then + $echo + $echo "*** Warning: libtool could not satisfy all declared inter-library" + $echo "*** dependencies of module $libname. Therefore, libtool will create" + $echo "*** a static module, that should work as long as the dlopening" + $echo "*** application is linked with the -dlopen flag." + if test -z "$global_symbol_pipe"; then + $echo + $echo "*** However, this would only work if libtool was able to extract symbol" + $echo "*** lists from a program, using \`nm' or equivalent, but libtool could" + $echo "*** not find such a program. So, this module is probably useless." + $echo "*** \`nm' from GNU binutils and a full rebuild may help." + fi + if test "$build_old_libs" = no; then + oldlibs="$output_objdir/$libname.$libext" + build_libtool_libs=module + build_old_libs=yes + else + build_libtool_libs=no + fi + else + $echo "*** The inter-library dependencies that have been dropped here will be" + $echo "*** automatically added whenever a program is linked with this library" + $echo "*** or is declared to -dlopen it." - if (patlen <= len) - { - str += len - patlen; - if (strcmp (str, pat) == 0) - *str = '\0'; - } - return str; -} + if test "$allow_undefined" = no; then + $echo + $echo "*** Since this library must not contain undefined symbols," + $echo "*** because either the platform does not support them or" + $echo "*** it was explicitly requested with -no-undefined," + $echo "*** libtool will only create a static version of it." + if test "$build_old_libs" = no; then + oldlibs="$output_objdir/$libname.$libext" + build_libtool_libs=module + build_old_libs=yes + else + build_libtool_libs=no + fi + fi + fi + fi + # Done checking deplibs! + deplibs=$newdeplibs + fi -static void -lt_error_core (int exit_status, const char *mode, - const char *message, va_list ap) -{ - fprintf (stderr, "%s: %s: ", program_name, mode); - vfprintf (stderr, message, ap); - fprintf (stderr, ".\n"); - if (exit_status >= 0) - exit (exit_status); -} + # move library search paths that coincide with paths to not yet + # installed libraries to the beginning of the library search list + new_libs= + for path in $notinst_path; do + case " $new_libs " in + *" -L$path/$objdir "*) ;; + *) + case " $deplibs " in + *" -L$path/$objdir "*) + new_libs="$new_libs -L$path/$objdir" ;; + esac + ;; + esac + done + for deplib in $deplibs; do + case $deplib in + -L*) + case " $new_libs " in + *" $deplib "*) ;; + *) new_libs="$new_libs $deplib" ;; + esac + ;; + *) new_libs="$new_libs $deplib" ;; + esac + done + deplibs="$new_libs" -void -lt_fatal (const char *message, ...) -{ - va_list ap; - va_start (ap, message); - lt_error_core (EXIT_FAILURE, "FATAL", message, ap); - va_end (ap); -} -void -lt_setenv (const char *name, const char *value) -{ - LTWRAPPER_DEBUGPRINTF (("(lt_setenv) setting '%s' to '%s'\n", - (name ? name : ""), - (value ? value : ""))); - { -#ifdef HAVE_SETENV - /* always make a copy, for consistency with !HAVE_SETENV */ - char *str = xstrdup (value); - setenv (name, str, 1); -#else - int len = strlen (name) + 1 + strlen (value) + 1; - char *str = XMALLOC (char, len); - sprintf (str, "%s=%s", name, value); - if (putenv (str) != EXIT_SUCCESS) - { - XFREE (str); - } -#endif - } -} + # All the library-specific variables (install_libdir is set above). + library_names= + old_library= + dlname= -char * -lt_extend_str (const char *orig_value, const char *add, int to_end) -{ - char *new_value; - if (orig_value && *orig_value) - { - int orig_value_len = strlen (orig_value); - int add_len = strlen (add); - new_value = XMALLOC (char, add_len + orig_value_len + 1); - if (to_end) - { - strcpy (new_value, orig_value); - strcpy (new_value + orig_value_len, add); - } - else - { - strcpy (new_value, add); - strcpy (new_value + add_len, orig_value); - } - } - else - { - new_value = xstrdup (add); - } - return new_value; -} + # Test again, we may have decided not to build it any more + if test "$build_libtool_libs" = yes; then + if test "$hardcode_into_libs" = yes; then + # Hardcode the library paths + hardcode_libdirs= + dep_rpath= + rpath="$finalize_rpath" + test "$mode" != relink && rpath="$compile_rpath$rpath" + for libdir in $rpath; do + if test -n "$hardcode_libdir_flag_spec"; then + if test -n "$hardcode_libdir_separator"; then + if test -z "$hardcode_libdirs"; then + hardcode_libdirs="$libdir" + else + # Just accumulate the unique libdirs. + case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in + *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) + ;; + *) + hardcode_libdirs="$hardcode_libdirs$hardcode_libdir_separator$libdir" + ;; + esac + fi + else + eval flag=\"$hardcode_libdir_flag_spec\" + dep_rpath="$dep_rpath $flag" + fi + elif test -n "$runpath_var"; then + case "$perm_rpath " in + *" $libdir "*) ;; + *) perm_rpath="$perm_rpath $libdir" ;; + esac + fi + done + # Substitute the hardcoded libdirs into the rpath. + if test -n "$hardcode_libdir_separator" && + test -n "$hardcode_libdirs"; then + libdir="$hardcode_libdirs" + if test -n "$hardcode_libdir_flag_spec_ld"; then + case $archive_cmds in + *\$LD*) eval dep_rpath=\"$hardcode_libdir_flag_spec_ld\" ;; + *) eval dep_rpath=\"$hardcode_libdir_flag_spec\" ;; + esac + else + eval dep_rpath=\"$hardcode_libdir_flag_spec\" + fi + fi + if test -n "$runpath_var" && test -n "$perm_rpath"; then + # We should set the runpath_var. + rpath= + for dir in $perm_rpath; do + rpath="$rpath$dir:" + done + eval "$runpath_var='$rpath\$$runpath_var'; export $runpath_var" + fi + test -n "$dep_rpath" && deplibs="$dep_rpath $deplibs" + fi -int -lt_split_name_value (const char *arg, char** name, char** value) -{ - const char *p; - int len; - if (!arg || !*arg) - return 1; + shlibpath="$finalize_shlibpath" + test "$mode" != relink && shlibpath="$compile_shlibpath$shlibpath" + if test -n "$shlibpath"; then + eval "$shlibpath_var='$shlibpath\$$shlibpath_var'; export $shlibpath_var" + fi - p = strchr (arg, (int)'='); + # Get the real and link names of the library. + eval shared_ext=\"$shrext_cmds\" + eval library_names=\"$library_names_spec\" + set dummy $library_names + realname="$2" + shift; shift - if (!p) - return 1; + if test -n "$soname_spec"; then + eval soname=\"$soname_spec\" + else + soname="$realname" + fi + if test -z "$dlname"; then + dlname=$soname + fi - *value = xstrdup (++p); + lib="$output_objdir/$realname" + linknames= + for link + do + linknames="$linknames $link" + done - len = strlen (arg) - strlen (*value); - *name = XMALLOC (char, len); - strncpy (*name, arg, len-1); - (*name)[len - 1] = '\0'; + # Use standard objects if they are pic + test -z "$pic_flag" && libobjs=`$echo "X$libobjs" | $SP2NL | $Xsed -e "$lo2o" | $NL2SP` - return 0; -} + # Prepare the list of exported symbols + if test -z "$export_symbols"; then + if test "$always_export_symbols" = yes || test -n "$export_symbols_regex"; then + $show "generating symbol list for \`$libname.la'" + export_symbols="$output_objdir/$libname.exp" + $run $rm $export_symbols + cmds=$export_symbols_cmds + save_ifs="$IFS"; IFS='~' + for cmd in $cmds; do + IFS="$save_ifs" + eval cmd=\"$cmd\" + if len=`expr "X$cmd" : ".*"` && + test "$len" -le "$max_cmd_len" || test "$max_cmd_len" -le -1; then + $show "$cmd" + $run eval "$cmd" || exit $? + skipped_export=false + else + # The command line is too long to execute in one step. + $show "using reloadable object file for export list..." + skipped_export=: + # Break out early, otherwise skipped_export may be + # set to false by a later but shorter cmd. + break + fi + done + IFS="$save_ifs" + if test -n "$export_symbols_regex"; then + $show "$EGREP -e \"$export_symbols_regex\" \"$export_symbols\" > \"${export_symbols}T\"" + $run eval '$EGREP -e "$export_symbols_regex" "$export_symbols" > "${export_symbols}T"' + $show "$mv \"${export_symbols}T\" \"$export_symbols\"" + $run eval '$mv "${export_symbols}T" "$export_symbols"' + fi + fi + fi -void -lt_opt_process_env_set (const char *arg) -{ - char *name = NULL; - char *value = NULL; + if test -n "$export_symbols" && test -n "$include_expsyms"; then + $run eval '$echo "X$include_expsyms" | $SP2NL >> "$export_symbols"' + fi - if (lt_split_name_value (arg, &name, &value) != 0) - { - XFREE (name); - XFREE (value); - lt_fatal ("bad argument for %s: '%s'", env_set_opt, arg); - } + tmp_deplibs= + for test_deplib in $deplibs; do + case " $convenience " in + *" $test_deplib "*) ;; + *) + tmp_deplibs="$tmp_deplibs $test_deplib" + ;; + esac + done + deplibs="$tmp_deplibs" - lt_setenv (name, value); - XFREE (name); - XFREE (value); -} + if test -n "$convenience"; then + if test -n "$whole_archive_flag_spec"; then + save_libobjs=$libobjs + eval libobjs=\"\$libobjs $whole_archive_flag_spec\" + else + gentop="$output_objdir/${outputname}x" + generated="$generated $gentop" -void -lt_opt_process_env_prepend (const char *arg) -{ - char *name = NULL; - char *value = NULL; - char *new_value = NULL; + func_extract_archives $gentop $convenience + libobjs="$libobjs $func_extract_archives_result" + fi + fi + + if test "$thread_safe" = yes && test -n "$thread_safe_flag_spec"; then + eval flag=\"$thread_safe_flag_spec\" + linker_flags="$linker_flags $flag" + fi - if (lt_split_name_value (arg, &name, &value) != 0) - { - XFREE (name); - XFREE (value); - lt_fatal ("bad argument for %s: '%s'", env_prepend_opt, arg); - } + # Make a backup of the uninstalled library when relinking + if test "$mode" = relink; then + $run eval '(cd $output_objdir && $rm ${realname}U && $mv $realname ${realname}U)' || exit $? + fi - new_value = lt_extend_str (getenv (name), value, 0); - lt_setenv (name, new_value); - XFREE (new_value); - XFREE (name); - XFREE (value); -} + # Do each of the archive commands. + if test "$module" = yes && test -n "$module_cmds" ; then + if test -n "$export_symbols" && test -n "$module_expsym_cmds"; then + eval test_cmds=\"$module_expsym_cmds\" + cmds=$module_expsym_cmds + else + eval test_cmds=\"$module_cmds\" + cmds=$module_cmds + fi + else + if test -n "$export_symbols" && test -n "$archive_expsym_cmds"; then + eval test_cmds=\"$archive_expsym_cmds\" + cmds=$archive_expsym_cmds + else + eval test_cmds=\"$archive_cmds\" + cmds=$archive_cmds + fi + fi -void -lt_opt_process_env_append (const char *arg) -{ - char *name = NULL; - char *value = NULL; - char *new_value = NULL; + if test "X$skipped_export" != "X:" && + len=`expr "X$test_cmds" : ".*" 2>/dev/null` && + test "$len" -le "$max_cmd_len" || test "$max_cmd_len" -le -1; then + : + else + # The command line is too long to link in one step, link piecewise. + $echo "creating reloadable object files..." - if (lt_split_name_value (arg, &name, &value) != 0) - { - XFREE (name); - XFREE (value); - lt_fatal ("bad argument for %s: '%s'", env_append_opt, arg); - } + # Save the value of $output and $libobjs because we want to + # use them later. If we have whole_archive_flag_spec, we + # want to use save_libobjs as it was before + # whole_archive_flag_spec was expanded, because we can't + # assume the linker understands whole_archive_flag_spec. + # This may have to be revisited, in case too many + # convenience libraries get linked in and end up exceeding + # the spec. + if test -z "$convenience" || test -z "$whole_archive_flag_spec"; then + save_libobjs=$libobjs + fi + save_output=$output + output_la=`$echo "X$output" | $Xsed -e "$basename"` - new_value = lt_extend_str (getenv (name), value, 1); - lt_setenv (name, new_value); - XFREE (new_value); - XFREE (name); - XFREE (value); -} + # Clear the reloadable object creation command queue and + # initialize k to one. + test_cmds= + concat_cmds= + objlist= + delfiles= + last_robj= + k=1 + output=$output_objdir/$output_la-${k}.$objext + # Loop over the list of objects to be linked. + for obj in $save_libobjs + do + eval test_cmds=\"$reload_cmds $objlist $last_robj\" + if test "X$objlist" = X || + { len=`expr "X$test_cmds" : ".*" 2>/dev/null` && + test "$len" -le "$max_cmd_len"; }; then + objlist="$objlist $obj" + else + # The command $test_cmds is almost too long, add a + # command to the queue. + if test "$k" -eq 1 ; then + # The first file doesn't have a previous command to add. + eval concat_cmds=\"$reload_cmds $objlist $last_robj\" + else + # All subsequent reloadable object files will link in + # the last one created. + eval concat_cmds=\"\$concat_cmds~$reload_cmds $objlist $last_robj\" + fi + last_robj=$output_objdir/$output_la-${k}.$objext + k=`expr $k + 1` + output=$output_objdir/$output_la-${k}.$objext + objlist=$obj + len=1 + fi + done + # Handle the remaining objects by creating one last + # reloadable object file. All subsequent reloadable object + # files will link in the last one created. + test -z "$concat_cmds" || concat_cmds=$concat_cmds~ + eval concat_cmds=\"\${concat_cmds}$reload_cmds $objlist $last_robj\" + + if ${skipped_export-false}; then + $show "generating symbol list for \`$libname.la'" + export_symbols="$output_objdir/$libname.exp" + $run $rm $export_symbols + libobjs=$output + # Append the command to create the export file. + eval concat_cmds=\"\$concat_cmds~$export_symbols_cmds\" + fi + + # Set up a command to remove the reloadable object files + # after they are used. + i=0 + while test "$i" -lt "$k" + do + i=`expr $i + 1` + delfiles="$delfiles $output_objdir/$output_la-${i}.$objext" + done -void -lt_update_exe_path (const char *name, const char *value) -{ - LTWRAPPER_DEBUGPRINTF (("(lt_update_exe_path) modifying '%s' by prepending '%s'\n", - (name ? name : ""), - (value ? value : ""))); + $echo "creating a temporary reloadable object file: $output" - if (name && *name && value && *value) - { - char *new_value = lt_extend_str (getenv (name), value, 0); - /* some systems can't cope with a ':'-terminated path #' */ - int len = strlen (new_value); - while (((len = strlen (new_value)) > 0) && IS_PATH_SEPARATOR (new_value[len-1])) - { - new_value[len-1] = '\0'; - } - lt_setenv (name, new_value); - XFREE (new_value); - } -} + # Loop through the commands generated above and execute them. + save_ifs="$IFS"; IFS='~' + for cmd in $concat_cmds; do + IFS="$save_ifs" + $show "$cmd" + $run eval "$cmd" || exit $? + done + IFS="$save_ifs" -void -lt_update_lib_path (const char *name, const char *value) -{ - LTWRAPPER_DEBUGPRINTF (("(lt_update_lib_path) modifying '%s' by prepending '%s'\n", - (name ? name : ""), - (value ? value : ""))); + libobjs=$output + # Restore the value of output. + output=$save_output - if (name && *name && value && *value) - { - char *new_value = lt_extend_str (getenv (name), value, 0); - lt_setenv (name, new_value); - XFREE (new_value); - } -} + if test -n "$convenience" && test -n "$whole_archive_flag_spec"; then + eval libobjs=\"\$libobjs $whole_archive_flag_spec\" + fi + # Expand the library linking commands again to reset the + # value of $libobjs for piecewise linking. + # Do each of the archive commands. + if test "$module" = yes && test -n "$module_cmds" ; then + if test -n "$export_symbols" && test -n "$module_expsym_cmds"; then + cmds=$module_expsym_cmds + else + cmds=$module_cmds + fi + else + if test -n "$export_symbols" && test -n "$archive_expsym_cmds"; then + cmds=$archive_expsym_cmds + else + cmds=$archive_cmds + fi + fi -EOF -} -# end: func_emit_cwrapperexe_src + # Append the command to remove the reloadable object files + # to the just-reset $cmds. + eval cmds=\"\$cmds~\$rm $delfiles\" + fi + save_ifs="$IFS"; IFS='~' + for cmd in $cmds; do + IFS="$save_ifs" + eval cmd=\"$cmd\" + $show "$cmd" + $run eval "$cmd" || { + lt_exit=$? -# func_mode_link arg... -func_mode_link () -{ - $opt_debug - case $host in - *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-cegcc*) - # It is impossible to link a dll without this setting, and - # we shouldn't force the makefile maintainer to figure out - # which system we are compiling for in order to pass an extra - # flag for every libtool invocation. - # allow_undefined=no + # Restore the uninstalled library and exit + if test "$mode" = relink; then + $run eval '(cd $output_objdir && $rm ${realname}T && $mv ${realname}U $realname)' + fi - # FIXME: Unfortunately, there are problems with the above when trying - # to make a dll which has undefined symbols, in which case not - # even a static library is built. For now, we need to specify - # -no-undefined on the libtool link line when we can be certain - # that all symbols are satisfied, otherwise we get a static library. - allow_undefined=yes - ;; - *) - allow_undefined=yes + exit $lt_exit + } + done + IFS="$save_ifs" + + # Restore the uninstalled library and exit + if test "$mode" = relink; then + $run eval '(cd $output_objdir && $rm ${realname}T && $mv $realname ${realname}T && $mv "$realname"U $realname)' || exit $? + + if test -n "$convenience"; then + if test -z "$whole_archive_flag_spec"; then + $show "${rm}r $gentop" + $run ${rm}r "$gentop" + fi + fi + + exit $EXIT_SUCCESS + fi + + # Create links to the real library. + for linkname in $linknames; do + if test "$realname" != "$linkname"; then + $show "(cd $output_objdir && $rm $linkname && $LN_S $realname $linkname)" + $run eval '(cd $output_objdir && $rm $linkname && $LN_S $realname $linkname)' || exit $? + fi + done + + # If -module or -export-dynamic was specified, set the dlname. + if test "$module" = yes || test "$export_dynamic" = yes; then + # On all known operating systems, these are identical. + dlname="$soname" + fi + fi ;; - esac - libtool_args=$nonopt - base_compile="$nonopt $@" - compile_command=$nonopt - finalize_command=$nonopt - compile_rpath= - finalize_rpath= - compile_shlibpath= - finalize_shlibpath= - convenience= - old_convenience= - deplibs= - old_deplibs= - compiler_flags= - linker_flags= - dllsearchpath= - lib_search_path=`pwd` - inst_prefix_dir= - new_inherited_linker_flags= + obj) + case " $deplibs" in + *\ -l* | *\ -L*) + $echo "$modename: warning: \`-l' and \`-L' are ignored for objects" 1>&2 ;; + esac - avoid_version=no - dlfiles= - dlprefiles= - dlself=no - export_dynamic=no - export_symbols= - export_symbols_regex= - generated= - libobjs= - ltlibs= - module=no - no_install=no - objs= - non_pic_objects= - precious_files_regex= - prefer_static_libs=no - preload=no - prev= - prevarg= - release= - rpath= - xrpath= - perm_rpath= - temp_rpath= - thread_safe=no - vinfo= - vinfo_number=no - weak_libs= - single_module="${wl}-single_module" - func_infer_tag $base_compile + if test -n "$dlfiles$dlprefiles" || test "$dlself" != no; then + $echo "$modename: warning: \`-dlopen' is ignored for objects" 1>&2 + fi - # We need to know -static, to get the right output filenames. - for arg - do - case $arg in - -shared) - test "$build_libtool_libs" != yes && \ - func_fatal_configuration "can not build a shared library" - build_old_libs=no - break + if test -n "$rpath"; then + $echo "$modename: warning: \`-rpath' is ignored for objects" 1>&2 + fi + + if test -n "$xrpath"; then + $echo "$modename: warning: \`-R' is ignored for objects" 1>&2 + fi + + if test -n "$vinfo"; then + $echo "$modename: warning: \`-version-info' is ignored for objects" 1>&2 + fi + + if test -n "$release"; then + $echo "$modename: warning: \`-release' is ignored for objects" 1>&2 + fi + + case $output in + *.lo) + if test -n "$objs$old_deplibs"; then + $echo "$modename: cannot build library object \`$output' from non-libtool objects" 1>&2 + exit $EXIT_FAILURE + fi + libobj="$output" + obj=`$echo "X$output" | $Xsed -e "$lo2o"` ;; - -all-static | -static | -static-libtool-libs) - case $arg in - -all-static) - if test "$build_libtool_libs" = yes && test -z "$link_static_flag"; then - func_warning "complete static linking is impossible in this configuration" - fi - if test -n "$link_static_flag"; then - dlopen_self=$dlopen_self_static - fi - prefer_static_libs=yes - ;; - -static) - if test -z "$pic_flag" && test -n "$link_static_flag"; then - dlopen_self=$dlopen_self_static - fi - prefer_static_libs=built - ;; - -static-libtool-libs) - if test -z "$pic_flag" && test -n "$link_static_flag"; then - dlopen_self=$dlopen_self_static - fi - prefer_static_libs=yes - ;; - esac - build_libtool_libs=no - build_old_libs=yes - break + *) + libobj= + obj="$output" ;; esac - done - # See if our shared archives depend on static archives. - test -n "$old_archive_from_new_cmds" && build_old_libs=yes + # Delete the old objects. + $run $rm $obj $libobj - # Go through the arguments, transforming them on the way. - while test "$#" -gt 0; do - arg="$1" - shift - func_quote_for_eval "$arg" - qarg=$func_quote_for_eval_unquoted_result - func_append libtool_args " $func_quote_for_eval_result" + # Objects from convenience libraries. This assumes + # single-version convenience libraries. Whenever we create + # different ones for PIC/non-PIC, this we'll have to duplicate + # the extraction. + reload_conv_objs= + gentop= + # reload_cmds runs $LD directly, so let us get rid of + # -Wl from whole_archive_flag_spec and hope we can get by with + # turning comma into space.. + wl= - # If the previous option needs an argument, assign it. - if test -n "$prev"; then - case $prev in - output) - func_append compile_command " @OUTPUT@" - func_append finalize_command " @OUTPUT@" - ;; - esac + if test -n "$convenience"; then + if test -n "$whole_archive_flag_spec"; then + eval tmp_whole_archive_flags=\"$whole_archive_flag_spec\" + reload_conv_objs=$reload_objs\ `$echo "X$tmp_whole_archive_flags" | $Xsed -e 's|,| |g'` + else + gentop="$output_objdir/${obj}x" + generated="$generated $gentop" - case $prev in - dlfiles|dlprefiles) - if test "$preload" = no; then - # Add the symbol object into the linking commands. - func_append compile_command " @SYMFILE@" - func_append finalize_command " @SYMFILE@" - preload=yes - fi - case $arg in - *.la | *.lo) ;; # We handle these cases below. - force) - if test "$dlself" = no; then - dlself=needless - export_dynamic=yes - fi - prev= - continue - ;; - self) - if test "$prev" = dlprefiles; then - dlself=yes - elif test "$prev" = dlfiles && test "$dlopen_self" != yes; then - dlself=yes - else - dlself=needless - export_dynamic=yes - fi - prev= - continue - ;; - *) - if test "$prev" = dlfiles; then - dlfiles="$dlfiles $arg" - else - dlprefiles="$dlprefiles $arg" - fi - prev= - continue - ;; - esac - ;; - expsyms) - export_symbols="$arg" - test -f "$arg" \ - || func_fatal_error "symbol file \`$arg' does not exist" - prev= - continue - ;; - expsyms_regex) - export_symbols_regex="$arg" - prev= - continue - ;; - framework) - case $host in - *-*-darwin*) - case "$deplibs " in - *" $qarg.ltframework "*) ;; - *) deplibs="$deplibs $qarg.ltframework" # this is fixed later - ;; - esac - ;; - esac - prev= - continue - ;; - inst_prefix) - inst_prefix_dir="$arg" - prev= - continue - ;; - objectlist) - if test -f "$arg"; then - save_arg=$arg - moreargs= - for fil in `cat "$save_arg"` - do -# moreargs="$moreargs $fil" - arg=$fil - # A libtool-controlled object. + func_extract_archives $gentop $convenience + reload_conv_objs="$reload_objs $func_extract_archives_result" + fi + fi - # Check to see that this really is a libtool object. - if func_lalib_unsafe_p "$arg"; then - pic_object= - non_pic_object= + # Create the old-style object. + reload_objs="$objs$old_deplibs "`$echo "X$libobjs" | $SP2NL | $Xsed -e '/\.'${libext}$'/d' -e '/\.lib$/d' -e "$lo2o" | $NL2SP`" $reload_conv_objs" ### testsuite: skip nested quoting test - # Read the .lo file - func_source "$arg" + output="$obj" + cmds=$reload_cmds + save_ifs="$IFS"; IFS='~' + for cmd in $cmds; do + IFS="$save_ifs" + eval cmd=\"$cmd\" + $show "$cmd" + $run eval "$cmd" || exit $? + done + IFS="$save_ifs" - if test -z "$pic_object" || - test -z "$non_pic_object" || - test "$pic_object" = none && - test "$non_pic_object" = none; then - func_fatal_error "cannot find name of object for \`$arg'" - fi + # Exit if we aren't doing a library object file. + if test -z "$libobj"; then + if test -n "$gentop"; then + $show "${rm}r $gentop" + $run ${rm}r $gentop + fi - # Extract subdirectory from the argument. - func_dirname "$arg" "/" "" - xdir="$func_dirname_result" + exit $EXIT_SUCCESS + fi - if test "$pic_object" != none; then - # Prepend the subdirectory the object is found in. - pic_object="$xdir$pic_object" + if test "$build_libtool_libs" != yes; then + if test -n "$gentop"; then + $show "${rm}r $gentop" + $run ${rm}r $gentop + fi - if test "$prev" = dlfiles; then - if test "$build_libtool_libs" = yes && test "$dlopen_support" = yes; then - dlfiles="$dlfiles $pic_object" - prev= - continue - else - # If libtool objects are unsupported, then we need to preload. - prev=dlprefiles - fi - fi + # Create an invalid libtool object if no PIC, so that we don't + # accidentally link it into a program. + # $show "echo timestamp > $libobj" + # $run eval "echo timestamp > $libobj" || exit $? + exit $EXIT_SUCCESS + fi - # CHECK ME: I think I busted this. -Ossama - if test "$prev" = dlprefiles; then - # Preload the old-style object. - dlprefiles="$dlprefiles $pic_object" - prev= - fi + if test -n "$pic_flag" || test "$pic_mode" != default; then + # Only do commands if we really have different PIC objects. + reload_objs="$libobjs $reload_conv_objs" + output="$libobj" + cmds=$reload_cmds + save_ifs="$IFS"; IFS='~' + for cmd in $cmds; do + IFS="$save_ifs" + eval cmd=\"$cmd\" + $show "$cmd" + $run eval "$cmd" || exit $? + done + IFS="$save_ifs" + fi - # A PIC object. - func_append libobjs " $pic_object" - arg="$pic_object" - fi + if test -n "$gentop"; then + $show "${rm}r $gentop" + $run ${rm}r $gentop + fi - # Non-PIC object. - if test "$non_pic_object" != none; then - # Prepend the subdirectory the object is found in. - non_pic_object="$xdir$non_pic_object" + exit $EXIT_SUCCESS + ;; - # A standard non-PIC object - func_append non_pic_objects " $non_pic_object" - if test -z "$pic_object" || test "$pic_object" = none ; then - arg="$non_pic_object" - fi - else - # If the PIC object exists, use it instead. - # $xdir was prepended to $pic_object above. - non_pic_object="$pic_object" - func_append non_pic_objects " $non_pic_object" - fi - else - # Only an error if not doing a dry-run. - if $opt_dry_run; then - # Extract subdirectory from the argument. - func_dirname "$arg" "/" "" - xdir="$func_dirname_result" - - func_lo2o "$arg" - pic_object=$xdir$objdir/$func_lo2o_result - non_pic_object=$xdir$func_lo2o_result - func_append libobjs " $pic_object" - func_append non_pic_objects " $non_pic_object" - else - func_fatal_error "\`$arg' is not a valid libtool object" - fi - fi - done - else - func_fatal_error "link input file \`$arg' does not exist" - fi - arg=$save_arg - prev= - continue - ;; - precious_regex) - precious_files_regex="$arg" - prev= - continue - ;; - release) - release="-$arg" - prev= - continue - ;; - rpath | xrpath) - # We need an absolute path. - case $arg in - [\\/]* | [A-Za-z]:[\\/]*) ;; - *) - func_fatal_error "only absolute run-paths are allowed" - ;; - esac - if test "$prev" = rpath; then - case "$rpath " in - *" $arg "*) ;; - *) rpath="$rpath $arg" ;; - esac - else - case "$xrpath " in - *" $arg "*) ;; - *) xrpath="$xrpath $arg" ;; - esac - fi - prev= - continue - ;; - shrext) - shrext_cmds="$arg" - prev= - continue - ;; - weak) - weak_libs="$weak_libs $arg" - prev= - continue - ;; - xcclinker) - linker_flags="$linker_flags $qarg" - compiler_flags="$compiler_flags $qarg" - prev= - func_append compile_command " $qarg" - func_append finalize_command " $qarg" - continue - ;; - xcompiler) - compiler_flags="$compiler_flags $qarg" - prev= - func_append compile_command " $qarg" - func_append finalize_command " $qarg" - continue - ;; - xlinker) - linker_flags="$linker_flags $qarg" - compiler_flags="$compiler_flags $wl$qarg" - prev= - func_append compile_command " $wl$qarg" - func_append finalize_command " $wl$qarg" - continue - ;; - *) - eval "$prev=\"\$arg\"" - prev= - continue - ;; - esac - fi # test -n "$prev" + prog) + case $host in + *cygwin*) output=`$echo $output | ${SED} -e 's,.exe$,,;s,$,.exe,'` ;; + esac + if test -n "$vinfo"; then + $echo "$modename: warning: \`-version-info' is ignored for programs" 1>&2 + fi - prevarg="$arg" + if test -n "$release"; then + $echo "$modename: warning: \`-release' is ignored for programs" 1>&2 + fi - case $arg in - -all-static) - if test -n "$link_static_flag"; then - # See comment for -static flag below, for more details. - func_append compile_command " $link_static_flag" - func_append finalize_command " $link_static_flag" + if test "$preload" = yes; then + if test "$dlopen_support" = unknown && test "$dlopen_self" = unknown && + test "$dlopen_self_static" = unknown; then + $echo "$modename: warning: \`AC_LIBTOOL_DLOPEN' not used. Assuming no dlopen support." fi - continue - ;; + fi - -allow-undefined) - # FIXME: remove this flag sometime in the future. - func_fatal_error "\`-allow-undefined' must not be used because it is the default" + case $host in + *-*-rhapsody* | *-*-darwin1.[012]) + # On Rhapsody replace the C library is the System framework + compile_deplibs=`$echo "X $compile_deplibs" | $Xsed -e 's/ -lc / -framework System /'` + finalize_deplibs=`$echo "X $finalize_deplibs" | $Xsed -e 's/ -lc / -framework System /'` ;; + esac - -avoid-version) - avoid_version=yes - continue - ;; + case $host in + *darwin*) + # Don't allow lazy linking, it breaks C++ global constructors + if test "$tagname" = CXX ; then + compile_command="$compile_command ${wl}-bind_at_load" + finalize_command="$finalize_command ${wl}-bind_at_load" + fi + ;; + esac - -dlopen) - prev=dlfiles - continue - ;; - -dlpreopen) - prev=dlprefiles - continue - ;; + # move library search paths that coincide with paths to not yet + # installed libraries to the beginning of the library search list + new_libs= + for path in $notinst_path; do + case " $new_libs " in + *" -L$path/$objdir "*) ;; + *) + case " $compile_deplibs " in + *" -L$path/$objdir "*) + new_libs="$new_libs -L$path/$objdir" ;; + esac + ;; + esac + done + for deplib in $compile_deplibs; do + case $deplib in + -L*) + case " $new_libs " in + *" $deplib "*) ;; + *) new_libs="$new_libs $deplib" ;; + esac + ;; + *) new_libs="$new_libs $deplib" ;; + esac + done + compile_deplibs="$new_libs" - -export-dynamic) - export_dynamic=yes - continue - ;; - -export-symbols | -export-symbols-regex) - if test -n "$export_symbols" || test -n "$export_symbols_regex"; then - func_fatal_error "more than one -exported-symbols argument is not allowed" - fi - if test "X$arg" = "X-export-symbols"; then - prev=expsyms - else - prev=expsyms_regex - fi - continue - ;; - - -framework) - prev=framework - continue - ;; - - -inst-prefix-dir) - prev=inst_prefix - continue - ;; + compile_command="$compile_command $compile_deplibs" + finalize_command="$finalize_command $finalize_deplibs" - # The native IRIX linker understands -LANG:*, -LIST:* and -LNO:* - # so, if we see these flags be careful not to treat them like -L - -L[A-Z][A-Z]*:*) - case $with_gcc/$host in - no/*-*-irix* | /*-*-irix*) - func_append compile_command " $arg" - func_append finalize_command " $arg" - ;; - esac - continue - ;; + if test -n "$rpath$xrpath"; then + # If the user specified any rpath flags, then add them. + for libdir in $rpath $xrpath; do + # This is the magic to use -rpath. + case "$finalize_rpath " in + *" $libdir "*) ;; + *) finalize_rpath="$finalize_rpath $libdir" ;; + esac + done + fi - -L*) - func_stripname '-L' '' "$arg" - dir=$func_stripname_result - if test -z "$dir"; then - if test "$#" -gt 0; then - func_fatal_error "require no space between \`-L' and \`$1'" + # Now hardcode the library paths + rpath= + hardcode_libdirs= + for libdir in $compile_rpath $finalize_rpath; do + if test -n "$hardcode_libdir_flag_spec"; then + if test -n "$hardcode_libdir_separator"; then + if test -z "$hardcode_libdirs"; then + hardcode_libdirs="$libdir" + else + # Just accumulate the unique libdirs. + case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in + *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) + ;; + *) + hardcode_libdirs="$hardcode_libdirs$hardcode_libdir_separator$libdir" + ;; + esac + fi else - func_fatal_error "need path for \`-L' option" + eval flag=\"$hardcode_libdir_flag_spec\" + rpath="$rpath $flag" fi + elif test -n "$runpath_var"; then + case "$perm_rpath " in + *" $libdir "*) ;; + *) perm_rpath="$perm_rpath $libdir" ;; + esac fi - # We need an absolute path. - case $dir in - [\\/]* | [A-Za-z]:[\\/]*) ;; - *) - absdir=`cd "$dir" && pwd` - test -z "$absdir" && \ - func_fatal_error "cannot determine absolute directory name of \`$dir'" - dir="$absdir" - ;; - esac - case "$deplibs " in - *" -L$dir "*) ;; - *) - deplibs="$deplibs -L$dir" - lib_search_path="$lib_search_path $dir" - ;; - esac case $host in - *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-cegcc*) - testbindir=`$ECHO "X$dir" | $Xsed -e 's*/lib$*/bin*'` + *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2*) + testbindir=`$echo "X$libdir" | $Xsed -e 's*/lib$*/bin*'` case :$dllsearchpath: in - *":$dir:"*) ;; - ::) dllsearchpath=$dir;; - *) dllsearchpath="$dllsearchpath:$dir";; + *":$libdir:"*) ;; + *) dllsearchpath="$dllsearchpath:$libdir";; esac case :$dllsearchpath: in *":$testbindir:"*) ;; - ::) dllsearchpath=$testbindir;; *) dllsearchpath="$dllsearchpath:$testbindir";; esac ;; esac - continue - ;; + done + # Substitute the hardcoded libdirs into the rpath. + if test -n "$hardcode_libdir_separator" && + test -n "$hardcode_libdirs"; then + libdir="$hardcode_libdirs" + eval rpath=\" $hardcode_libdir_flag_spec\" + fi + compile_rpath="$rpath" - -l*) - if test "X$arg" = "X-lc" || test "X$arg" = "X-lm"; then - case $host in - *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-beos* | *-cegcc*) - # These systems don't actually have a C or math library (as such) - continue - ;; - *-*-os2*) - # These systems don't actually have a C library (as such) - test "X$arg" = "X-lc" && continue - ;; - *-*-openbsd* | *-*-freebsd* | *-*-dragonfly*) - # Do not include libc due to us having libc/libc_r. - test "X$arg" = "X-lc" && continue - ;; - *-*-rhapsody* | *-*-darwin1.[012]) - # Rhapsody C and math libraries are in the System framework - deplibs="$deplibs System.ltframework" - continue - ;; - *-*-sco3.2v5* | *-*-sco5v6*) - # Causes problems with __ctype - test "X$arg" = "X-lc" && continue - ;; - *-*-sysv4.2uw2* | *-*-sysv5* | *-*-unixware* | *-*-OpenUNIX*) - # Compiler inserts libc in the correct place for threads to work - test "X$arg" = "X-lc" && continue - ;; + rpath= + hardcode_libdirs= + for libdir in $finalize_rpath; do + if test -n "$hardcode_libdir_flag_spec"; then + if test -n "$hardcode_libdir_separator"; then + if test -z "$hardcode_libdirs"; then + hardcode_libdirs="$libdir" + else + # Just accumulate the unique libdirs. + case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in + *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) + ;; + *) + hardcode_libdirs="$hardcode_libdirs$hardcode_libdir_separator$libdir" + ;; + esac + fi + else + eval flag=\"$hardcode_libdir_flag_spec\" + rpath="$rpath $flag" + fi + elif test -n "$runpath_var"; then + case "$finalize_perm_rpath " in + *" $libdir "*) ;; + *) finalize_perm_rpath="$finalize_perm_rpath $libdir" ;; esac - elif test "X$arg" = "X-lc_r"; then - case $host in - *-*-openbsd* | *-*-freebsd* | *-*-dragonfly*) - # Do not include libc_r directly, use -pthread flag. - continue - ;; - esac fi - deplibs="$deplibs $arg" - continue - ;; + done + # Substitute the hardcoded libdirs into the rpath. + if test -n "$hardcode_libdir_separator" && + test -n "$hardcode_libdirs"; then + libdir="$hardcode_libdirs" + eval rpath=\" $hardcode_libdir_flag_spec\" + fi + finalize_rpath="$rpath" - -module) - module=yes - continue - ;; + if test -n "$libobjs" && test "$build_old_libs" = yes; then + # Transform all the library objects into standard objects. + compile_command=`$echo "X$compile_command" | $SP2NL | $Xsed -e "$lo2o" | $NL2SP` + finalize_command=`$echo "X$finalize_command" | $SP2NL | $Xsed -e "$lo2o" | $NL2SP` + fi - # Tru64 UNIX uses -model [arg] to determine the layout of C++ - # classes, name mangling, and exception handling. - # Darwin uses the -arch flag to determine output architecture. - -model|-arch|-isysroot) - compiler_flags="$compiler_flags $arg" - func_append compile_command " $arg" - func_append finalize_command " $arg" - prev=xcompiler - continue - ;; + dlsyms= + if test -n "$dlfiles$dlprefiles" || test "$dlself" != no; then + if test -n "$NM" && test -n "$global_symbol_pipe"; then + dlsyms="${outputname}S.c" + else + $echo "$modename: not configured to extract global symbols from dlpreopened files" 1>&2 + fi + fi - -mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe|-threads) - compiler_flags="$compiler_flags $arg" - func_append compile_command " $arg" - func_append finalize_command " $arg" - case "$new_inherited_linker_flags " in - *" $arg "*) ;; - * ) new_inherited_linker_flags="$new_inherited_linker_flags $arg" ;; - esac - continue - ;; + if test -n "$dlsyms"; then + case $dlsyms in + "") ;; + *.c) + # Discover the nlist of each of the dlfiles. + nlist="$output_objdir/${outputname}.nm" - -multi_module) - single_module="${wl}-multi_module" - continue - ;; + $show "$rm $nlist ${nlist}S ${nlist}T" + $run $rm "$nlist" "${nlist}S" "${nlist}T" - -no-fast-install) - fast_install=no - continue - ;; + # Parse the name list into a source file. + $show "creating $output_objdir/$dlsyms" - -no-install) - case $host in - *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-*-darwin* | *-cegcc*) - # The PATH hackery in wrapper scripts is required on Windows - # and Darwin in order for the loader to find any dlls it needs. - func_warning "\`-no-install' is ignored for $host" - func_warning "assuming \`-no-fast-install' instead" - fast_install=no - ;; - *) no_install=yes ;; - esac - continue - ;; + test -z "$run" && $echo > "$output_objdir/$dlsyms" "\ +/* $dlsyms - symbol resolution table for \`$outputname' dlsym emulation. */ +/* Generated by $PROGRAM - GNU $PACKAGE $VERSION$TIMESTAMP */ - -no-undefined) - allow_undefined=no - continue - ;; +#ifdef __cplusplus +extern \"C\" { +#endif - -objectlist) - prev=objectlist - continue - ;; +/* Prevent the only kind of declaration conflicts we can make. */ +#define lt_preloaded_symbols some_other_symbol - -o) prev=output ;; +/* External symbol declarations for the compiler. */\ +" - -precious-files-regex) - prev=precious_regex - continue - ;; + if test "$dlself" = yes; then + $show "generating symbol list for \`$output'" - -release) - prev=release - continue - ;; + test -z "$run" && $echo ': @PROGRAM@ ' > "$nlist" - -rpath) - prev=rpath - continue - ;; + # Add our own program objects to the symbol list. + progfiles=`$echo "X$objs$old_deplibs" | $SP2NL | $Xsed -e "$lo2o" | $NL2SP` + for arg in $progfiles; do + $show "extracting global C symbols from \`$arg'" + $run eval "$NM $arg | $global_symbol_pipe >> '$nlist'" + done - -R) - prev=xrpath - continue - ;; + if test -n "$exclude_expsyms"; then + $run eval '$EGREP -v " ($exclude_expsyms)$" "$nlist" > "$nlist"T' + $run eval '$mv "$nlist"T "$nlist"' + fi - -R*) - func_stripname '-R' '' "$arg" - dir=$func_stripname_result - # We need an absolute path. - case $dir in - [\\/]* | [A-Za-z]:[\\/]*) ;; - *) - func_fatal_error "only absolute run-paths are allowed" - ;; - esac - case "$xrpath " in - *" $dir "*) ;; - *) xrpath="$xrpath $dir" ;; - esac - continue - ;; + if test -n "$export_symbols_regex"; then + $run eval '$EGREP -e "$export_symbols_regex" "$nlist" > "$nlist"T' + $run eval '$mv "$nlist"T "$nlist"' + fi - -shared) - # The effects of -shared are defined in a previous loop. - continue - ;; + # Prepare the list of exported symbols + if test -z "$export_symbols"; then + export_symbols="$output_objdir/$outputname.exp" + $run $rm $export_symbols + $run eval "${SED} -n -e '/^: @PROGRAM@ $/d' -e 's/^.* \(.*\)$/\1/p' "'< "$nlist" > "$export_symbols"' + case $host in + *cygwin* | *mingw* ) + $run eval "echo EXPORTS "'> "$output_objdir/$outputname.def"' + $run eval 'cat "$export_symbols" >> "$output_objdir/$outputname.def"' + ;; + esac + else + $run eval "${SED} -e 's/\([].[*^$]\)/\\\\\1/g' -e 's/^/ /' -e 's/$/$/'"' < "$export_symbols" > "$output_objdir/$outputname.exp"' + $run eval 'grep -f "$output_objdir/$outputname.exp" < "$nlist" > "$nlist"T' + $run eval 'mv "$nlist"T "$nlist"' + case $host in + *cygwin* | *mingw* ) + $run eval "echo EXPORTS "'> "$output_objdir/$outputname.def"' + $run eval 'cat "$nlist" >> "$output_objdir/$outputname.def"' + ;; + esac + fi + fi - -shrext) - prev=shrext - continue - ;; + for arg in $dlprefiles; do + $show "extracting global C symbols from \`$arg'" + name=`$echo "$arg" | ${SED} -e 's%^.*/%%'` + $run eval '$echo ": $name " >> "$nlist"' + $run eval "$NM $arg | $global_symbol_pipe >> '$nlist'" + done - -static | -static-libtool-libs) - # The effects of -static are defined in a previous loop. - # We used to do the same as -all-static on platforms that - # didn't have a PIC flag, but the assumption that the effects - # would be equivalent was wrong. It would break on at least - # Digital Unix and AIX. - continue - ;; - - -thread-safe) - thread_safe=yes - continue - ;; - - -version-info) - prev=vinfo - continue - ;; - - -version-number) - prev=vinfo - vinfo_number=yes - continue - ;; + if test -z "$run"; then + # Make sure we have at least an empty file. + test -f "$nlist" || : > "$nlist" - -weak) - prev=weak - continue - ;; + if test -n "$exclude_expsyms"; then + $EGREP -v " ($exclude_expsyms)$" "$nlist" > "$nlist"T + $mv "$nlist"T "$nlist" + fi - -Wc,*) - func_stripname '-Wc,' '' "$arg" - args=$func_stripname_result - arg= - save_ifs="$IFS"; IFS=',' - for flag in $args; do - IFS="$save_ifs" - func_quote_for_eval "$flag" - arg="$arg $wl$func_quote_for_eval_result" - compiler_flags="$compiler_flags $func_quote_for_eval_result" - done - IFS="$save_ifs" - func_stripname ' ' '' "$arg" - arg=$func_stripname_result - ;; + # Try sorting and uniquifying the output. + if grep -v "^: " < "$nlist" | + if sort -k 3 /dev/null 2>&1; then + sort -k 3 + else + sort +2 + fi | + uniq > "$nlist"S; then + : + else + grep -v "^: " < "$nlist" > "$nlist"S + fi - -Wl,*) - func_stripname '-Wl,' '' "$arg" - args=$func_stripname_result - arg= - save_ifs="$IFS"; IFS=',' - for flag in $args; do - IFS="$save_ifs" - func_quote_for_eval "$flag" - arg="$arg $wl$func_quote_for_eval_result" - compiler_flags="$compiler_flags $wl$func_quote_for_eval_result" - linker_flags="$linker_flags $func_quote_for_eval_result" - done - IFS="$save_ifs" - func_stripname ' ' '' "$arg" - arg=$func_stripname_result - ;; + if test -f "$nlist"S; then + eval "$global_symbol_to_cdecl"' < "$nlist"S >> "$output_objdir/$dlsyms"' + else + $echo '/* NONE */' >> "$output_objdir/$dlsyms" + fi - -Xcompiler) - prev=xcompiler - continue - ;; + $echo >> "$output_objdir/$dlsyms" "\ - -Xlinker) - prev=xlinker - continue - ;; +#undef lt_preloaded_symbols - -XCClinker) - prev=xcclinker - continue - ;; +#if defined (__STDC__) && __STDC__ +# define lt_ptr void * +#else +# define lt_ptr char * +# define const +#endif - # -msg_* for osf cc - -msg_*) - func_quote_for_eval "$arg" - arg="$func_quote_for_eval_result" - ;; +/* The mapping between symbol names and symbols. */ +" - # -64, -mips[0-9] enable 64-bit mode on the SGI compiler - # -r[0-9][0-9]* specifies the processor on the SGI compiler - # -xarch=*, -xtarget=* enable 64-bit mode on the Sun compiler - # +DA*, +DD* enable 64-bit mode on the HP compiler - # -q* pass through compiler args for the IBM compiler - # -m*, -t[45]*, -txscale* pass through architecture-specific - # compiler args for GCC - # -F/path gives path to uninstalled frameworks, gcc on darwin - # -p, -pg, --coverage, -fprofile-* pass through profiling flag for GCC - # @file GCC response files - -64|-mips[0-9]|-r[0-9][0-9]*|-xarch=*|-xtarget=*|+DA*|+DD*|-q*|-m*| \ - -t[45]*|-txscale*|-p|-pg|--coverage|-fprofile-*|-F*|@*) - func_quote_for_eval "$arg" - arg="$func_quote_for_eval_result" - func_append compile_command " $arg" - func_append finalize_command " $arg" - compiler_flags="$compiler_flags $arg" - continue - ;; + case $host in + *cygwin* | *mingw* ) + $echo >> "$output_objdir/$dlsyms" "\ +/* DATA imports from DLLs on WIN32 can't be const, because + runtime relocations are performed -- see ld's documentation + on pseudo-relocs */ +struct { +" + ;; + * ) + $echo >> "$output_objdir/$dlsyms" "\ +const struct { +" + ;; + esac - # Some other compiler flag. - -* | +*) - func_quote_for_eval "$arg" - arg="$func_quote_for_eval_result" - ;; - *.$objext) - # A standard object. - objs="$objs $arg" - ;; + $echo >> "$output_objdir/$dlsyms" "\ + const char *name; + lt_ptr address; +} +lt_preloaded_symbols[] = +{\ +" - *.lo) - # A libtool-controlled object. + eval "$global_symbol_to_c_name_address" < "$nlist" >> "$output_objdir/$dlsyms" - # Check to see that this really is a libtool object. - if func_lalib_unsafe_p "$arg"; then - pic_object= - non_pic_object= + $echo >> "$output_objdir/$dlsyms" "\ + {0, (lt_ptr) 0} +}; - # Read the .lo file - func_source "$arg" +/* This works around a problem in FreeBSD linker */ +#ifdef FREEBSD_WORKAROUND +static const void *lt_preloaded_setup() { + return lt_preloaded_symbols; +} +#endif - if test -z "$pic_object" || - test -z "$non_pic_object" || - test "$pic_object" = none && - test "$non_pic_object" = none; then - func_fatal_error "cannot find name of object for \`$arg'" +#ifdef __cplusplus +} +#endif\ +" fi - # Extract subdirectory from the argument. - func_dirname "$arg" "/" "" - xdir="$func_dirname_result" - - if test "$pic_object" != none; then - # Prepend the subdirectory the object is found in. - pic_object="$xdir$pic_object" - - if test "$prev" = dlfiles; then - if test "$build_libtool_libs" = yes && test "$dlopen_support" = yes; then - dlfiles="$dlfiles $pic_object" - prev= - continue - else - # If libtool objects are unsupported, then we need to preload. - prev=dlprefiles - fi - fi + pic_flag_for_symtable= + case $host in + # compiling the symbol table file with pic_flag works around + # a FreeBSD bug that causes programs to crash when -lm is + # linked before any other PIC object. But we must not use + # pic_flag when linking with -static. The problem exists in + # FreeBSD 2.2.6 and is fixed in FreeBSD 3.1. + *-*-freebsd2*|*-*-freebsd3.0*|*-*-freebsdelf3.0*) + case "$compile_command " in + *" -static "*) ;; + *) pic_flag_for_symtable=" $pic_flag -DFREEBSD_WORKAROUND";; + esac;; + *-*-hpux*) + case "$compile_command " in + *" -static "*) ;; + *) pic_flag_for_symtable=" $pic_flag";; + esac + esac - # CHECK ME: I think I busted this. -Ossama - if test "$prev" = dlprefiles; then - # Preload the old-style object. - dlprefiles="$dlprefiles $pic_object" - prev= - fi + # Now compile the dynamic symbol file. + $show "(cd $output_objdir && $LTCC $LTCFLAGS -c$no_builtin_flag$pic_flag_for_symtable \"$dlsyms\")" + $run eval '(cd $output_objdir && $LTCC $LTCFLAGS -c$no_builtin_flag$pic_flag_for_symtable "$dlsyms")' || exit $? - # A PIC object. - func_append libobjs " $pic_object" - arg="$pic_object" - fi + # Clean up the generated files. + $show "$rm $output_objdir/$dlsyms $nlist ${nlist}S ${nlist}T" + $run $rm "$output_objdir/$dlsyms" "$nlist" "${nlist}S" "${nlist}T" - # Non-PIC object. - if test "$non_pic_object" != none; then - # Prepend the subdirectory the object is found in. - non_pic_object="$xdir$non_pic_object" + # Transform the symbol file into the correct name. + case $host in + *cygwin* | *mingw* ) + if test -f "$output_objdir/${outputname}.def" ; then + compile_command=`$echo "X$compile_command" | $SP2NL | $Xsed -e "s%@SYMFILE@%$output_objdir/${outputname}.def $output_objdir/${outputname}S.${objext}%" | $NL2SP` + finalize_command=`$echo "X$finalize_command" | $SP2NL | $Xsed -e "s%@SYMFILE@%$output_objdir/${outputname}.def $output_objdir/${outputname}S.${objext}%" | $NL2SP` + else + compile_command=`$echo "X$compile_command" | $SP2NL | $Xsed -e "s%@SYMFILE@%$output_objdir/${outputname}S.${objext}%" | $NL2SP` + finalize_command=`$echo "X$finalize_command" | $SP2NL | $Xsed -e "s%@SYMFILE@%$output_objdir/${outputname}S.${objext}%" | $NL2SP` + fi + ;; + * ) + compile_command=`$echo "X$compile_command" | $SP2NL | $Xsed -e "s%@SYMFILE@%$output_objdir/${outputname}S.${objext}%" | $NL2SP` + finalize_command=`$echo "X$finalize_command" | $SP2NL | $Xsed -e "s%@SYMFILE@%$output_objdir/${outputname}S.${objext}%" | $NL2SP` + ;; + esac + ;; + *) + $echo "$modename: unknown suffix for \`$dlsyms'" 1>&2 + exit $EXIT_FAILURE + ;; + esac + else + # We keep going just in case the user didn't refer to + # lt_preloaded_symbols. The linker will fail if global_symbol_pipe + # really was required. - # A standard non-PIC object - func_append non_pic_objects " $non_pic_object" - if test -z "$pic_object" || test "$pic_object" = none ; then - arg="$non_pic_object" - fi - else - # If the PIC object exists, use it instead. - # $xdir was prepended to $pic_object above. - non_pic_object="$pic_object" - func_append non_pic_objects " $non_pic_object" - fi - else - # Only an error if not doing a dry-run. - if $opt_dry_run; then - # Extract subdirectory from the argument. - func_dirname "$arg" "/" "" - xdir="$func_dirname_result" - - func_lo2o "$arg" - pic_object=$xdir$objdir/$func_lo2o_result - non_pic_object=$xdir$func_lo2o_result - func_append libobjs " $pic_object" - func_append non_pic_objects " $non_pic_object" - else - func_fatal_error "\`$arg' is not a valid libtool object" - fi - fi - ;; + # Nullify the symbol file. + compile_command=`$echo "X$compile_command" | $SP2NL | $Xsed -e "s% @SYMFILE@%%" | $NL2SP` + finalize_command=`$echo "X$finalize_command" | $SP2NL | $Xsed -e "s% @SYMFILE@%%" | $NL2SP` + fi - *.$libext) - # An archive. - deplibs="$deplibs $arg" - old_deplibs="$old_deplibs $arg" - continue - ;; + if test "$need_relink" = no || test "$build_libtool_libs" != yes; then + # Replace the output file specification. + compile_command=`$echo "X$compile_command" | $SP2NL | $Xsed -e 's%@OUTPUT@%'"$output"'%g' | $NL2SP` + link_command="$compile_command$compile_rpath" - *.la) - # A libtool-controlled library. + # We have no uninstalled library dependencies, so finalize right now. + $show "$link_command" + $run eval "$link_command" + exit_status=$? - if test "$prev" = dlfiles; then - # This library was specified with -dlopen. - dlfiles="$dlfiles $arg" - prev= - elif test "$prev" = dlprefiles; then - # The library was specified with -dlpreopen. - dlprefiles="$dlprefiles $arg" - prev= - else - deplibs="$deplibs $arg" + # Delete the generated files. + if test -n "$dlsyms"; then + $show "$rm $output_objdir/${outputname}S.${objext}" + $run $rm "$output_objdir/${outputname}S.${objext}" fi - continue - ;; - # Some other compiler argument. - *) - # Unknown arguments in both finalize_command and compile_command need - # to be aesthetically quoted because they are evaled later. - func_quote_for_eval "$arg" - arg="$func_quote_for_eval_result" - ;; - esac # arg + exit $exit_status + fi - # Now actually substitute the argument into the commands. - if test -n "$arg"; then - func_append compile_command " $arg" - func_append finalize_command " $arg" + if test -n "$shlibpath_var"; then + # We should set the shlibpath_var + rpath= + for dir in $temp_rpath; do + case $dir in + [\\/]* | [A-Za-z]:[\\/]*) + # Absolute path. + rpath="$rpath$dir:" + ;; + *) + # Relative path: add a thisdir entry. + rpath="$rpath\$thisdir/$dir:" + ;; + esac + done + temp_rpath="$rpath" fi - done # argument parsing loop - test -n "$prev" && \ - func_fatal_help "the \`$prevarg' option requires an argument" + if test -n "$compile_shlibpath$finalize_shlibpath"; then + compile_command="$shlibpath_var=\"$compile_shlibpath$finalize_shlibpath\$$shlibpath_var\" $compile_command" + fi + if test -n "$finalize_shlibpath"; then + finalize_command="$shlibpath_var=\"$finalize_shlibpath\$$shlibpath_var\" $finalize_command" + fi - if test "$export_dynamic" = yes && test -n "$export_dynamic_flag_spec"; then - eval arg=\"$export_dynamic_flag_spec\" - func_append compile_command " $arg" - func_append finalize_command " $arg" - fi + compile_var= + finalize_var= + if test -n "$runpath_var"; then + if test -n "$perm_rpath"; then + # We should set the runpath_var. + rpath= + for dir in $perm_rpath; do + rpath="$rpath$dir:" + done + compile_var="$runpath_var=\"$rpath\$$runpath_var\" " + fi + if test -n "$finalize_perm_rpath"; then + # We should set the runpath_var. + rpath= + for dir in $finalize_perm_rpath; do + rpath="$rpath$dir:" + done + finalize_var="$runpath_var=\"$rpath\$$runpath_var\" " + fi + fi - oldlibs= - # calculate the name of the file, without its directory - func_basename "$output" - outputname="$func_basename_result" - libobjs_save="$libobjs" + if test "$no_install" = yes; then + # We don't need to create a wrapper script. + link_command="$compile_var$compile_command$compile_rpath" + # Replace the output file specification. + link_command=`$echo "X$link_command" | $Xsed -e 's%@OUTPUT@%'"$output"'%g'` + # Delete the old output file. + $run $rm $output + # Link the executable and exit + $show "$link_command" + $run eval "$link_command" || exit $? + exit $EXIT_SUCCESS + fi - if test -n "$shlibpath_var"; then - # get the directories listed in $shlibpath_var - eval shlib_search_path=\`\$ECHO \"X\${$shlibpath_var}\" \| \$Xsed -e \'s/:/ /g\'\` - else - shlib_search_path= - fi - eval sys_lib_search_path=\"$sys_lib_search_path_spec\" - eval sys_lib_dlsearch_path=\"$sys_lib_dlsearch_path_spec\" - - func_dirname "$output" "/" "" - output_objdir="$func_dirname_result$objdir" - # Create the object directory. - func_mkdir_p "$output_objdir" - - # Determine the type of output - case $output in - "") - func_fatal_help "you must specify an output file" - ;; - *.$libext) linkmode=oldlib ;; - *.lo | *.$objext) linkmode=obj ;; - *.la) linkmode=lib ;; - *) linkmode=prog ;; # Anything else should be a program. - esac - - specialdeplibs= + if test "$hardcode_action" = relink; then + # Fast installation is not supported + link_command="$compile_var$compile_command$compile_rpath" + relink_command="$finalize_var$finalize_command$finalize_rpath" - libs= - # Find all interdependent deplibs by searching for libraries - # that are linked more than once (e.g. -la -lb -la) - for deplib in $deplibs; do - if $opt_duplicate_deps ; then - case "$libs " in - *" $deplib "*) specialdeplibs="$specialdeplibs $deplib" ;; - esac + $echo "$modename: warning: this platform does not like uninstalled shared libraries" 1>&2 + $echo "$modename: \`$output' will be relinked during installation" 1>&2 + else + if test "$fast_install" != no; then + link_command="$finalize_var$compile_command$finalize_rpath" + if test "$fast_install" = yes; then + relink_command=`$echo "X$compile_var$compile_command$compile_rpath" | $SP2NL | $Xsed -e 's%@OUTPUT@%\$progdir/\$file%g' | $NL2SP` + else + # fast_install is set to needless + relink_command= + fi + else + link_command="$compile_var$compile_command$compile_rpath" + relink_command="$finalize_var$finalize_command$finalize_rpath" + fi fi - libs="$libs $deplib" - done - if test "$linkmode" = lib; then - libs="$predeps $libs $compiler_lib_search_path $postdeps" + # Replace the output file specification. + link_command=`$echo "X$link_command" | $Xsed -e 's%@OUTPUT@%'"$output_objdir/$outputname"'%g'` - # Compute libraries that are listed more than once in $predeps - # $postdeps and mark them as special (i.e., whose duplicates are - # not to be eliminated). - pre_post_deps= - if $opt_duplicate_compiler_generated_deps; then - for pre_post_dep in $predeps $postdeps; do - case "$pre_post_deps " in - *" $pre_post_dep "*) specialdeplibs="$specialdeplibs $pre_post_deps" ;; - esac - pre_post_deps="$pre_post_deps $pre_post_dep" - done - fi - pre_post_deps= - fi + # Delete the old output files. + $run $rm $output $output_objdir/$outputname $output_objdir/lt-$outputname - deplibs= - newdependency_libs= - newlib_search_path= - need_relink=no # whether we're linking any uninstalled libtool libraries - notinst_deplibs= # not-installed libtool libraries - notinst_path= # paths that contain not-installed libtool libraries + $show "$link_command" + $run eval "$link_command" || exit $? - case $linkmode in - lib) - passes="conv dlpreopen link" - for file in $dlfiles $dlprefiles; do - case $file in - *.la) ;; - *) - func_fatal_help "libraries can \`-dlopen' only libtool libraries: $file" - ;; - esac - done - ;; - prog) - compile_deplibs= - finalize_deplibs= - alldeplibs=no - newdlfiles= - newdlprefiles= - passes="conv scan dlopen dlpreopen link" - ;; - *) passes="conv" - ;; - esac + # Now create the wrapper script. + $show "creating $output" - for pass in $passes; do - # The preopen pass in lib mode reverses $deplibs; put it back here - # so that -L comes before libs that need it for instance... - if test "$linkmode,$pass" = "lib,link"; then - ## FIXME: Find the place where the list is rebuilt in the wrong - ## order, and fix it there properly - tmp_deplibs= - for deplib in $deplibs; do - tmp_deplibs="$deplib $tmp_deplibs" + # Quote the relink command for shipping. + if test -n "$relink_command"; then + # Preserve any variables that may affect compiler behavior + for var in $variables_saved_for_relink; do + if eval test -z \"\${$var+set}\"; then + relink_command="{ test -z \"\${$var+set}\" || unset $var || { $var=; export $var; }; }; $relink_command" + elif eval var_value=\$$var; test -z "$var_value"; then + relink_command="$var=; export $var; $relink_command" + else + var_value=`$echo "X$var_value" | $Xsed -e "$sed_quote_subst"` + relink_command="$var=\"$var_value\"; export $var; $relink_command" + fi done - deplibs="$tmp_deplibs" + relink_command="(cd `pwd`; $relink_command)" + relink_command=`$echo "X$relink_command" | $SP2NL | $Xsed -e "$sed_quote_subst" | $NL2SP` fi - if test "$linkmode,$pass" = "lib,link" || - test "$linkmode,$pass" = "prog,scan"; then - libs="$deplibs" - deplibs= - fi - if test "$linkmode" = prog; then - case $pass in - dlopen) libs="$dlfiles" ;; - dlpreopen) libs="$dlprefiles" ;; - link) libs="$deplibs %DEPLIBS% $dependency_libs" ;; + # Quote $echo for shipping. + if test "X$echo" = "X$SHELL $progpath --fallback-echo"; then + case $progpath in + [\\/]* | [A-Za-z]:[\\/]*) qecho="$SHELL $progpath --fallback-echo";; + *) qecho="$SHELL `pwd`/$progpath --fallback-echo";; esac + qecho=`$echo "X$qecho" | $Xsed -e "$sed_quote_subst"` + else + qecho=`$echo "X$echo" | $Xsed -e "$sed_quote_subst"` fi - if test "$linkmode,$pass" = "lib,dlpreopen"; then - # Collect and forward deplibs of preopened libtool libs - for lib in $dlprefiles; do - # Ignore non-libtool-libs - dependency_libs= - case $lib in - *.la) func_source "$lib" ;; - esac - # Collect preopened libtool deplibs, except any this library - # has declared as weak libs - for deplib in $dependency_libs; do - deplib_base=`$ECHO "X$deplib" | $Xsed -e "$basename"` - case " $weak_libs " in - *" $deplib_base "*) ;; - *) deplibs="$deplibs $deplib" ;; - esac - done - done - libs="$dlprefiles" - fi - if test "$pass" = dlopen; then - # Collect dlpreopened libraries - save_deplibs="$deplibs" - deplibs= - fi + # Only actually do things if our run command is non-null. + if test -z "$run"; then + # win32 will think the script is a binary if it has + # a .exe suffix, so we strip it off here. + case $output in + *.exe) output=`$echo $output|${SED} 's,.exe$,,'` ;; + esac + # test for cygwin because mv fails w/o .exe extensions + case $host in + *cygwin*) + exeext=.exe + outputname=`$echo $outputname|${SED} 's,.exe$,,'` ;; + *) exeext= ;; + esac + case $host in + *cygwin* | *mingw* ) + output_name=`basename $output` + output_path=`dirname $output` + cwrappersource="$output_path/$objdir/lt-$output_name.c" + cwrapper="$output_path/$output_name.exe" + $rm $cwrappersource $cwrapper + trap "$rm $cwrappersource $cwrapper; exit $EXIT_FAILURE" 1 2 15 - for deplib in $libs; do - lib= - found=no - case $deplib in - -mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe|-threads) - if test "$linkmode,$pass" = "prog,link"; then - compile_deplibs="$deplib $compile_deplibs" - finalize_deplibs="$deplib $finalize_deplibs" - else - compiler_flags="$compiler_flags $deplib" - if test "$linkmode" = lib ; then - case "$new_inherited_linker_flags " in - *" $deplib "*) ;; - * ) new_inherited_linker_flags="$new_inherited_linker_flags $deplib" ;; - esac - fi - fi - continue - ;; - -l*) - if test "$linkmode" != lib && test "$linkmode" != prog; then - func_warning "\`-l' is ignored for archives/objects" - continue - fi - func_stripname '-l' '' "$deplib" - name=$func_stripname_result - if test "$linkmode" = lib; then - searchdirs="$newlib_search_path $lib_search_path $compiler_lib_search_dirs $sys_lib_search_path $shlib_search_path" - else - searchdirs="$newlib_search_path $lib_search_path $sys_lib_search_path $shlib_search_path" - fi - for searchdir in $searchdirs; do - for search_ext in .la $std_shrext .so .a; do - # Search the libtool library - lib="$searchdir/lib${name}${search_ext}" - if test -f "$lib"; then - if test "$search_ext" = ".la"; then - found=yes - else - found=no - fi - break 2 - fi - done - done - if test "$found" != yes; then - # deplib doesn't seem to be a libtool library - if test "$linkmode,$pass" = "prog,link"; then - compile_deplibs="$deplib $compile_deplibs" - finalize_deplibs="$deplib $finalize_deplibs" - else - deplibs="$deplib $deplibs" - test "$linkmode" = lib && newdependency_libs="$deplib $newdependency_libs" - fi - continue - else # deplib is a libtool library - # If $allow_libtool_libs_with_static_runtimes && $deplib is a stdlib, - # We need to do some special things here, and not later. - if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then - case " $predeps $postdeps " in - *" $deplib "*) - if func_lalib_p "$lib"; then - library_names= - old_library= - func_source "$lib" - for l in $old_library $library_names; do - ll="$l" - done - if test "X$ll" = "X$old_library" ; then # only static version available - found=no - func_dirname "$lib" "" "." - ladir="$func_dirname_result" - lib=$ladir/$old_library - if test "$linkmode,$pass" = "prog,link"; then - compile_deplibs="$deplib $compile_deplibs" - finalize_deplibs="$deplib $finalize_deplibs" - else - deplibs="$deplib $deplibs" - test "$linkmode" = lib && newdependency_libs="$deplib $newdependency_libs" - fi - continue - fi - fi - ;; - *) ;; - esac - fi - fi - ;; # -l - *.ltframework) - if test "$linkmode,$pass" = "prog,link"; then - compile_deplibs="$deplib $compile_deplibs" - finalize_deplibs="$deplib $finalize_deplibs" - else - deplibs="$deplib $deplibs" - if test "$linkmode" = lib ; then - case "$new_inherited_linker_flags " in - *" $deplib "*) ;; - * ) new_inherited_linker_flags="$new_inherited_linker_flags $deplib" ;; - esac - fi - fi - continue - ;; - -L*) - case $linkmode in - lib) - deplibs="$deplib $deplibs" - test "$pass" = conv && continue - newdependency_libs="$deplib $newdependency_libs" - func_stripname '-L' '' "$deplib" - newlib_search_path="$newlib_search_path $func_stripname_result" - ;; - prog) - if test "$pass" = conv; then - deplibs="$deplib $deplibs" - continue - fi - if test "$pass" = scan; then - deplibs="$deplib $deplibs" - else - compile_deplibs="$deplib $compile_deplibs" - finalize_deplibs="$deplib $finalize_deplibs" - fi - func_stripname '-L' '' "$deplib" - newlib_search_path="$newlib_search_path $func_stripname_result" - ;; - *) - func_warning "\`-L' is ignored for archives/objects" - ;; - esac # linkmode - continue - ;; # -L - -R*) - if test "$pass" = link; then - func_stripname '-R' '' "$deplib" - dir=$func_stripname_result - # Make sure the xrpath contains only unique directories. - case "$xrpath " in - *" $dir "*) ;; - *) xrpath="$xrpath $dir" ;; - esac - fi - deplibs="$deplib $deplibs" - continue - ;; - *.la) lib="$deplib" ;; - *.$libext) - if test "$pass" = conv; then - deplibs="$deplib $deplibs" - continue - fi - case $linkmode in - lib) - # Linking convenience modules into shared libraries is allowed, - # but linking other static libraries is non-portable. - case " $dlpreconveniencelibs " in - *" $deplib "*) ;; - *) - valid_a_lib=no - case $deplibs_check_method in - match_pattern*) - set dummy $deplibs_check_method; shift - match_pattern_regex=`expr "$deplibs_check_method" : "$1 \(.*\)"` - if eval "\$ECHO \"X$deplib\"" 2>/dev/null | $Xsed -e 10q \ - | $EGREP "$match_pattern_regex" > /dev/null; then - valid_a_lib=yes - fi - ;; - pass_all) - valid_a_lib=yes - ;; - esac - if test "$valid_a_lib" != yes; then - $ECHO - $ECHO "*** Warning: Trying to link with static lib archive $deplib." - $ECHO "*** I have the capability to make that library automatically link in when" - $ECHO "*** you link to this library. But I can only do this if you have a" - $ECHO "*** shared version of the library, which you do not appear to have" - $ECHO "*** because the file extensions .$libext of this argument makes me believe" - $ECHO "*** that it is just a static archive that I should not use here." - else - $ECHO - $ECHO "*** Warning: Linking the shared library $output against the" - $ECHO "*** static library $deplib is not portable!" - deplibs="$deplib $deplibs" - fi - ;; - esac - continue - ;; - prog) - if test "$pass" != link; then - deplibs="$deplib $deplibs" - else - compile_deplibs="$deplib $compile_deplibs" - finalize_deplibs="$deplib $finalize_deplibs" - fi - continue - ;; - esac # linkmode - ;; # *.$libext - *.lo | *.$objext) - if test "$pass" = conv; then - deplibs="$deplib $deplibs" - elif test "$linkmode" = prog; then - if test "$pass" = dlpreopen || test "$dlopen_support" != yes || test "$build_libtool_libs" = no; then - # If there is no dlopen support or we're linking statically, - # we need to preload. - newdlprefiles="$newdlprefiles $deplib" - compile_deplibs="$deplib $compile_deplibs" - finalize_deplibs="$deplib $finalize_deplibs" - else - newdlfiles="$newdlfiles $deplib" - fi - fi - continue - ;; - %DEPLIBS%) - alldeplibs=yes - continue - ;; - esac # case $deplib + cat > $cwrappersource <> $cwrappersource<<"EOF" +#include +#include +#include +#include +#include +#include +#include +#include +#include +#if defined(PATH_MAX) +# define LT_PATHMAX PATH_MAX +#elif defined(MAXPATHLEN) +# define LT_PATHMAX MAXPATHLEN +#else +# define LT_PATHMAX 1024 +#endif - # Read the .la file - func_source "$lib" - - # Convert "-framework foo" to "foo.ltframework" - if test -n "$inherited_linker_flags"; then - tmp_inherited_linker_flags=`$ECHO "X$inherited_linker_flags" | $Xsed -e 's/-framework \([^ $]*\)/\1.ltframework/g'` - for tmp_inherited_linker_flag in $tmp_inherited_linker_flags; do - case " $new_inherited_linker_flags " in - *" $tmp_inherited_linker_flag "*) ;; - *) new_inherited_linker_flags="$new_inherited_linker_flags $tmp_inherited_linker_flag";; - esac - done - fi - dependency_libs=`$ECHO "X $dependency_libs" | $Xsed -e 's% \([^ $]*\).ltframework% -framework \1%g'` - if test "$linkmode,$pass" = "lib,link" || - test "$linkmode,$pass" = "prog,scan" || - { test "$linkmode" != prog && test "$linkmode" != lib; }; then - test -n "$dlopen" && dlfiles="$dlfiles $dlopen" - test -n "$dlpreopen" && dlprefiles="$dlprefiles $dlpreopen" - fi +#ifndef DIR_SEPARATOR +# define DIR_SEPARATOR '/' +# define PATH_SEPARATOR ':' +#endif - if test "$pass" = conv; then - # Only check for convenience libraries - deplibs="$lib $deplibs" - if test -z "$libdir"; then - if test -z "$old_library"; then - func_fatal_error "cannot find name of link library for \`$lib'" - fi - # It is a libtool convenience library, so add in its objects. - convenience="$convenience $ladir/$objdir/$old_library" - old_convenience="$old_convenience $ladir/$objdir/$old_library" - elif test "$linkmode" != prog && test "$linkmode" != lib; then - func_fatal_error "\`$lib' is not a convenience library" - fi - tmp_libs= - for deplib in $dependency_libs; do - deplibs="$deplib $deplibs" - if $opt_duplicate_deps ; then - case "$tmp_libs " in - *" $deplib "*) specialdeplibs="$specialdeplibs $deplib" ;; - esac - fi - tmp_libs="$tmp_libs $deplib" - done - continue - fi # $pass = conv +#if defined (_WIN32) || defined (__MSDOS__) || defined (__DJGPP__) || \ + defined (__OS2__) +# define HAVE_DOS_BASED_FILE_SYSTEM +# ifndef DIR_SEPARATOR_2 +# define DIR_SEPARATOR_2 '\\' +# endif +# ifndef PATH_SEPARATOR_2 +# define PATH_SEPARATOR_2 ';' +# endif +#endif +#ifndef DIR_SEPARATOR_2 +# define IS_DIR_SEPARATOR(ch) ((ch) == DIR_SEPARATOR) +#else /* DIR_SEPARATOR_2 */ +# define IS_DIR_SEPARATOR(ch) \ + (((ch) == DIR_SEPARATOR) || ((ch) == DIR_SEPARATOR_2)) +#endif /* DIR_SEPARATOR_2 */ - # Get the name of the library we link against. - linklib= - for l in $old_library $library_names; do - linklib="$l" - done - if test -z "$linklib"; then - func_fatal_error "cannot find name of link library for \`$lib'" - fi +#ifndef PATH_SEPARATOR_2 +# define IS_PATH_SEPARATOR(ch) ((ch) == PATH_SEPARATOR) +#else /* PATH_SEPARATOR_2 */ +# define IS_PATH_SEPARATOR(ch) ((ch) == PATH_SEPARATOR_2) +#endif /* PATH_SEPARATOR_2 */ - # This library was specified with -dlopen. - if test "$pass" = dlopen; then - if test -z "$libdir"; then - func_fatal_error "cannot -dlopen a convenience library: \`$lib'" - fi - if test -z "$dlname" || - test "$dlopen_support" != yes || - test "$build_libtool_libs" = no; then - # If there is no dlname, no dlopen support or we're linking - # statically, we need to preload. We also need to preload any - # dependent libraries so libltdl's deplib preloader doesn't - # bomb out in the load deplibs phase. - dlprefiles="$dlprefiles $lib $dependency_libs" - else - newdlfiles="$newdlfiles $lib" - fi - continue - fi # $pass = dlopen +#define XMALLOC(type, num) ((type *) xmalloc ((num) * sizeof(type))) +#define XFREE(stale) do { \ + if (stale) { free ((void *) stale); stale = 0; } \ +} while (0) - # We need an absolute path. - case $ladir in - [\\/]* | [A-Za-z]:[\\/]*) abs_ladir="$ladir" ;; - *) - abs_ladir=`cd "$ladir" && pwd` - if test -z "$abs_ladir"; then - func_warning "cannot determine absolute directory name of \`$ladir'" - func_warning "passing it literally to the linker, although it might fail" - abs_ladir="$ladir" - fi - ;; - esac - func_basename "$lib" - laname="$func_basename_result" +/* -DDEBUG is fairly common in CFLAGS. */ +#undef DEBUG +#if defined DEBUGWRAPPER +# define DEBUG(format, ...) fprintf(stderr, format, __VA_ARGS__) +#else +# define DEBUG(format, ...) +#endif - # Find the relevant object directory and library name. - if test "X$installed" = Xyes; then - if test ! -f "$libdir/$linklib" && test -f "$abs_ladir/$linklib"; then - func_warning "library \`$lib' was moved." - dir="$ladir" - absdir="$abs_ladir" - libdir="$abs_ladir" - else - dir="$libdir" - absdir="$libdir" - fi - test "X$hardcode_automatic" = Xyes && avoidtemprpath=yes - else - if test ! -f "$ladir/$objdir/$linklib" && test -f "$abs_ladir/$linklib"; then - dir="$ladir" - absdir="$abs_ladir" - # Remove this search path later - notinst_path="$notinst_path $abs_ladir" - else - dir="$ladir/$objdir" - absdir="$abs_ladir/$objdir" - # Remove this search path later - notinst_path="$notinst_path $abs_ladir" - fi - fi # $installed = yes - func_stripname 'lib' '.la' "$laname" - name=$func_stripname_result +const char *program_name = NULL; - # This library was specified with -dlpreopen. - if test "$pass" = dlpreopen; then - if test -z "$libdir" && test "$linkmode" = prog; then - func_fatal_error "only libraries may -dlpreopen a convenience library: \`$lib'" - fi - # Prefer using a static library (so that no silly _DYNAMIC symbols - # are required to link). - if test -n "$old_library"; then - newdlprefiles="$newdlprefiles $dir/$old_library" - # Keep a list of preopened convenience libraries to check - # that they are being used correctly in the link pass. - test -z "$libdir" && \ - dlpreconveniencelibs="$dlpreconveniencelibs $dir/$old_library" - # Otherwise, use the dlname, so that lt_dlopen finds it. - elif test -n "$dlname"; then - newdlprefiles="$newdlprefiles $dir/$dlname" - else - newdlprefiles="$newdlprefiles $dir/$linklib" - fi - fi # $pass = dlpreopen +void * xmalloc (size_t num); +char * xstrdup (const char *string); +const char * base_name (const char *name); +char * find_executable(const char *wrapper); +int check_executable(const char *path); +char * strendzap(char *str, const char *pat); +void lt_fatal (const char *message, ...); - if test -z "$libdir"; then - # Link the convenience library - if test "$linkmode" = lib; then - deplibs="$dir/$old_library $deplibs" - elif test "$linkmode,$pass" = "prog,link"; then - compile_deplibs="$dir/$old_library $compile_deplibs" - finalize_deplibs="$dir/$old_library $finalize_deplibs" - else - deplibs="$lib $deplibs" # used for prog,scan pass - fi - continue - fi +int +main (int argc, char *argv[]) +{ + char **newargz; + int i; + program_name = (char *) xstrdup (base_name (argv[0])); + DEBUG("(main) argv[0] : %s\n",argv[0]); + DEBUG("(main) program_name : %s\n",program_name); + newargz = XMALLOC(char *, argc+2); +EOF - if test "$linkmode" = prog && test "$pass" != link; then - newlib_search_path="$newlib_search_path $ladir" - deplibs="$lib $deplibs" - - linkalldeplibs=no - if test "$link_all_deplibs" != no || test -z "$library_names" || - test "$build_libtool_libs" = no; then - linkalldeplibs=yes - fi - - tmp_libs= - for deplib in $dependency_libs; do - case $deplib in - -L*) func_stripname '-L' '' "$deplib" - newlib_search_path="$newlib_search_path $func_stripname_result" - ;; - esac - # Need to link against all dependency_libs? - if test "$linkalldeplibs" = yes; then - deplibs="$deplib $deplibs" - else - # Need to hardcode shared library paths - # or/and link against static libraries - newdependency_libs="$deplib $newdependency_libs" - fi - if $opt_duplicate_deps ; then - case "$tmp_libs " in - *" $deplib "*) specialdeplibs="$specialdeplibs $deplib" ;; - esac - fi - tmp_libs="$tmp_libs $deplib" - done # for deplib - continue - fi # $linkmode = prog... - - if test "$linkmode,$pass" = "prog,link"; then - if test -n "$library_names" && - { { test "$prefer_static_libs" = no || - test "$prefer_static_libs,$installed" = "built,yes"; } || - test -z "$old_library"; }; then - # We need to hardcode the library path - if test -n "$shlibpath_var" && test -z "$avoidtemprpath" ; then - # Make sure the rpath contains only unique directories. - case "$temp_rpath:" in - *"$absdir:"*) ;; - *) temp_rpath="$temp_rpath$absdir:" ;; - esac - fi - - # Hardcode the library path. - # Skip directories that are in the system default run-time - # search path. - case " $sys_lib_dlsearch_path " in - *" $absdir "*) ;; - *) - case "$compile_rpath " in - *" $absdir "*) ;; - *) compile_rpath="$compile_rpath $absdir" - esac - ;; - esac - case " $sys_lib_dlsearch_path " in - *" $libdir "*) ;; - *) - case "$finalize_rpath " in - *" $libdir "*) ;; - *) finalize_rpath="$finalize_rpath $libdir" - esac - ;; - esac - fi # $linkmode,$pass = prog,link... + cat >> $cwrappersource <> $cwrappersource <<"EOF" + newargz[1] = find_executable(argv[0]); + if (newargz[1] == NULL) + lt_fatal("Couldn't find %s", argv[0]); + DEBUG("(main) found exe at : %s\n",newargz[1]); + /* we know the script has the same name, without the .exe */ + /* so make sure newargz[1] doesn't end in .exe */ + strendzap(newargz[1],".exe"); + for (i = 1; i < argc; i++) + newargz[i+1] = xstrdup(argv[i]); + newargz[argc+1] = NULL; - link_static=no # Whether the deplib will be linked statically - use_static_libs=$prefer_static_libs - if test "$use_static_libs" = built && test "$installed" = yes; then - use_static_libs=no - fi - if test -n "$library_names" && - { test "$use_static_libs" = no || test -z "$old_library"; }; then - case $host in - *cygwin* | *mingw* | *cegcc*) - # No point in relinking DLLs because paths are not encoded - notinst_deplibs="$notinst_deplibs $lib" - need_relink=no - ;; - *) - if test "$installed" = no; then - notinst_deplibs="$notinst_deplibs $lib" - need_relink=yes - fi - ;; - esac - # This is a shared library + for (i=0; i> $cwrappersource <> $cwrappersource <> $cwrappersource <<"EOF" + return 127; +} - # If the library has no export list, then create one now - if test -f "$output_objdir/$soname-def"; then : - else - func_verbose "extracting exported symbol list from \`$soname'" - func_execute_cmds "$extract_expsyms_cmds" 'exit $?' - fi +void * +xmalloc (size_t num) +{ + void * p = (void *) malloc (num); + if (!p) + lt_fatal ("Memory exhausted"); - # Create $newlib - if test -f "$output_objdir/$newlib"; then :; else - func_verbose "generating import library for \`$soname'" - func_execute_cmds "$old_archive_from_expsyms_cmds" 'exit $?' - fi - # make sure the library variables are pointing to the new library - dir=$output_objdir - linklib=$newlib - fi # test -n "$old_archive_from_expsyms_cmds" + return p; +} - if test "$linkmode" = prog || test "$mode" != relink; then - add_shlibpath= - add_dir= - add= - lib_linked=yes - case $hardcode_action in - immediate | unsupported) - if test "$hardcode_direct" = no; then - add="$dir/$linklib" - case $host in - *-*-sco3.2v5.0.[024]*) add_dir="-L$dir" ;; - *-*-sysv4*uw2*) add_dir="-L$dir" ;; - *-*-sysv5OpenUNIX* | *-*-sysv5UnixWare7.[01].[10]* | \ - *-*-unixware7*) add_dir="-L$dir" ;; - *-*-darwin* ) - # if the lib is a (non-dlopened) module then we can not - # link against it, someone is ignoring the earlier warnings - if /usr/bin/file -L $add 2> /dev/null | - $GREP ": [^:]* bundle" >/dev/null ; then - if test "X$dlopenmodule" != "X$lib"; then - $ECHO "*** Warning: lib $linklib is a module, not a shared library" - if test -z "$old_library" ; then - $ECHO - $ECHO "*** And there doesn't seem to be a static archive available" - $ECHO "*** The link will probably fail, sorry" - else - add="$dir/$old_library" - fi - elif test -n "$old_library"; then - add="$dir/$old_library" - fi - fi - esac - elif test "$hardcode_minus_L" = no; then - case $host in - *-*-sunos*) add_shlibpath="$dir" ;; - esac - add_dir="-L$dir" - add="-l$name" - elif test "$hardcode_shlibpath_var" = no; then - add_shlibpath="$dir" - add="-l$name" - else - lib_linked=no - fi - ;; - relink) - if test "$hardcode_direct" = yes && - test "$hardcode_direct_absolute" = no; then - add="$dir/$linklib" - elif test "$hardcode_minus_L" = yes; then - add_dir="-L$dir" - # Try looking first in the location we're being installed to. - if test -n "$inst_prefix_dir"; then - case $libdir in - [\\/]*) - add_dir="$add_dir -L$inst_prefix_dir$libdir" - ;; - esac - fi - add="-l$name" - elif test "$hardcode_shlibpath_var" = yes; then - add_shlibpath="$dir" - add="-l$name" - else - lib_linked=no - fi - ;; - *) lib_linked=no ;; - esac +char * +xstrdup (const char *string) +{ + return string ? strcpy ((char *) xmalloc (strlen (string) + 1), string) : NULL +; +} - if test "$lib_linked" != yes; then - func_fatal_configuration "unsupported hardcode properties" - fi +const char * +base_name (const char *name) +{ + const char *base; - if test -n "$add_shlibpath"; then - case :$compile_shlibpath: in - *":$add_shlibpath:"*) ;; - *) compile_shlibpath="$compile_shlibpath$add_shlibpath:" ;; - esac - fi - if test "$linkmode" = prog; then - test -n "$add_dir" && compile_deplibs="$add_dir $compile_deplibs" - test -n "$add" && compile_deplibs="$add $compile_deplibs" - else - test -n "$add_dir" && deplibs="$add_dir $deplibs" - test -n "$add" && deplibs="$add $deplibs" - if test "$hardcode_direct" != yes && - test "$hardcode_minus_L" != yes && - test "$hardcode_shlibpath_var" = yes; then - case :$finalize_shlibpath: in - *":$libdir:"*) ;; - *) finalize_shlibpath="$finalize_shlibpath$libdir:" ;; - esac - fi - fi - fi +#if defined (HAVE_DOS_BASED_FILE_SYSTEM) + /* Skip over the disk name in MSDOS pathnames. */ + if (isalpha ((unsigned char)name[0]) && name[1] == ':') + name += 2; +#endif - if test "$linkmode" = prog || test "$mode" = relink; then - add_shlibpath= - add_dir= - add= - # Finalize command for both is simple: just hardcode it. - if test "$hardcode_direct" = yes && - test "$hardcode_direct_absolute" = no; then - add="$libdir/$linklib" - elif test "$hardcode_minus_L" = yes; then - add_dir="-L$libdir" - add="-l$name" - elif test "$hardcode_shlibpath_var" = yes; then - case :$finalize_shlibpath: in - *":$libdir:"*) ;; - *) finalize_shlibpath="$finalize_shlibpath$libdir:" ;; - esac - add="-l$name" - elif test "$hardcode_automatic" = yes; then - if test -n "$inst_prefix_dir" && - test -f "$inst_prefix_dir$libdir/$linklib" ; then - add="$inst_prefix_dir$libdir/$linklib" - else - add="$libdir/$linklib" - fi - else - # We cannot seem to hardcode it, guess we'll fake it. - add_dir="-L$libdir" - # Try looking first in the location we're being installed to. - if test -n "$inst_prefix_dir"; then - case $libdir in - [\\/]*) - add_dir="$add_dir -L$inst_prefix_dir$libdir" - ;; - esac - fi - add="-l$name" - fi - - if test "$linkmode" = prog; then - test -n "$add_dir" && finalize_deplibs="$add_dir $finalize_deplibs" - test -n "$add" && finalize_deplibs="$add $finalize_deplibs" - else - test -n "$add_dir" && deplibs="$add_dir $deplibs" - test -n "$add" && deplibs="$add $deplibs" - fi - fi - elif test "$linkmode" = prog; then - # Here we assume that one of hardcode_direct or hardcode_minus_L - # is not unsupported. This is valid on all known static and - # shared platforms. - if test "$hardcode_direct" != unsupported; then - test -n "$old_library" && linklib="$old_library" - compile_deplibs="$dir/$linklib $compile_deplibs" - finalize_deplibs="$dir/$linklib $finalize_deplibs" - else - compile_deplibs="-l$name -L$dir $compile_deplibs" - finalize_deplibs="-l$name -L$dir $finalize_deplibs" - fi - elif test "$build_libtool_libs" = yes; then - # Not a shared library - if test "$deplibs_check_method" != pass_all; then - # We're trying link a shared library against a static one - # but the system doesn't support it. - - # Just print a warning and add the library to dependency_libs so - # that the program can be linked against the static library. - $ECHO - $ECHO "*** Warning: This system can not link to static lib archive $lib." - $ECHO "*** I have the capability to make that library automatically link in when" - $ECHO "*** you link to this library. But I can only do this if you have a" - $ECHO "*** shared version of the library, which you do not appear to have." - if test "$module" = yes; then - $ECHO "*** But as you try to build a module library, libtool will still create " - $ECHO "*** a static module, that should work as long as the dlopening application" - $ECHO "*** is linked with the -dlopen flag to resolve symbols at runtime." - if test -z "$global_symbol_pipe"; then - $ECHO - $ECHO "*** However, this would only work if libtool was able to extract symbol" - $ECHO "*** lists from a program, using \`nm' or equivalent, but libtool could" - $ECHO "*** not find such a program. So, this module is probably useless." - $ECHO "*** \`nm' from GNU binutils and a full rebuild may help." - fi - if test "$build_old_libs" = no; then - build_libtool_libs=module - build_old_libs=yes - else - build_libtool_libs=no - fi - fi - else - deplibs="$dir/$old_library $deplibs" - link_static=yes - fi - fi # link shared/static library? - - if test "$linkmode" = lib; then - if test -n "$dependency_libs" && - { test "$hardcode_into_libs" != yes || - test "$build_old_libs" = yes || - test "$link_static" = yes; }; then - # Extract -R from dependency_libs - temp_deplibs= - for libdir in $dependency_libs; do - case $libdir in - -R*) func_stripname '-R' '' "$libdir" - temp_xrpath=$func_stripname_result - case " $xrpath " in - *" $temp_xrpath "*) ;; - *) xrpath="$xrpath $temp_xrpath";; - esac;; - *) temp_deplibs="$temp_deplibs $libdir";; - esac - done - dependency_libs="$temp_deplibs" - fi - - newlib_search_path="$newlib_search_path $absdir" - # Link against this library - test "$link_static" = no && newdependency_libs="$abs_ladir/$laname $newdependency_libs" - # ... and its dependency_libs - tmp_libs= - for deplib in $dependency_libs; do - newdependency_libs="$deplib $newdependency_libs" - if $opt_duplicate_deps ; then - case "$tmp_libs " in - *" $deplib "*) specialdeplibs="$specialdeplibs $deplib" ;; - esac - fi - tmp_libs="$tmp_libs $deplib" - done - - if test "$link_all_deplibs" != no; then - # Add the search paths of all dependency libraries - for deplib in $dependency_libs; do - case $deplib in - -L*) path="$deplib" ;; - *.la) - func_dirname "$deplib" "" "." - dir="$func_dirname_result" - # We need an absolute path. - case $dir in - [\\/]* | [A-Za-z]:[\\/]*) absdir="$dir" ;; - *) - absdir=`cd "$dir" && pwd` - if test -z "$absdir"; then - func_warning "cannot determine absolute directory name of \`$dir'" - absdir="$dir" - fi - ;; - esac - if $GREP "^installed=no" $deplib > /dev/null; then - case $host in - *-*-darwin*) - depdepl= - eval deplibrary_names=`${SED} -n -e 's/^library_names=\(.*\)$/\1/p' $deplib` - if test -n "$deplibrary_names" ; then - for tmp in $deplibrary_names ; do - depdepl=$tmp - done - if test -f "$absdir/$objdir/$depdepl" ; then - depdepl="$absdir/$objdir/$depdepl" - darwin_install_name=`${OTOOL} -L $depdepl | awk '{if (NR == 2) {print $1;exit}}'` - if test -z "$darwin_install_name"; then - darwin_install_name=`${OTOOL64} -L $depdepl | awk '{if (NR == 2) {print $1;exit}}'` - fi - compiler_flags="$compiler_flags ${wl}-dylib_file ${wl}${darwin_install_name}:${depdepl}" - linker_flags="$linker_flags -dylib_file ${darwin_install_name}:${depdepl}" - path= - fi - fi - ;; - *) - path="-L$absdir/$objdir" - ;; - esac - else - eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $deplib` - test -z "$libdir" && \ - func_fatal_error "\`$deplib' is not a valid libtool archive" - test "$absdir" != "$libdir" && \ - func_warning "\`$deplib' seems to be moved" - - path="-L$absdir" - fi - ;; - esac - case " $deplibs " in - *" $path "*) ;; - *) deplibs="$path $deplibs" ;; - esac - done - fi # link_all_deplibs != no - fi # linkmode = lib - done # for deplib in $libs - if test "$pass" = link; then - if test "$linkmode" = "prog"; then - compile_deplibs="$new_inherited_linker_flags $compile_deplibs" - finalize_deplibs="$new_inherited_linker_flags $finalize_deplibs" - else - compiler_flags="$compiler_flags "`$ECHO "X $new_inherited_linker_flags" | $Xsed -e 's% \([^ $]*\).ltframework% -framework \1%g'` - fi - fi - dependency_libs="$newdependency_libs" - if test "$pass" = dlpreopen; then - # Link the dlpreopened libraries before other libraries - for deplib in $save_deplibs; do - deplibs="$deplib $deplibs" - done - fi - if test "$pass" != dlopen; then - if test "$pass" != conv; then - # Make sure lib_search_path contains only unique directories. - lib_search_path= - for dir in $newlib_search_path; do - case "$lib_search_path " in - *" $dir "*) ;; - *) lib_search_path="$lib_search_path $dir" ;; - esac - done - newlib_search_path= - fi - - if test "$linkmode,$pass" != "prog,link"; then - vars="deplibs" - else - vars="compile_deplibs finalize_deplibs" - fi - for var in $vars dependency_libs; do - # Add libraries to $var in reverse order - eval tmp_libs=\"\$$var\" - new_libs= - for deplib in $tmp_libs; do - # FIXME: Pedantically, this is the right thing to do, so - # that some nasty dependency loop isn't accidentally - # broken: - #new_libs="$deplib $new_libs" - # Pragmatically, this seems to cause very few problems in - # practice: - case $deplib in - -L*) new_libs="$deplib $new_libs" ;; - -R*) ;; - *) - # And here is the reason: when a library appears more - # than once as an explicit dependence of a library, or - # is implicitly linked in more than once by the - # compiler, it is considered special, and multiple - # occurrences thereof are not removed. Compare this - # with having the same library being listed as a - # dependency of multiple other libraries: in this case, - # we know (pedantically, we assume) the library does not - # need to be listed more than once, so we keep only the - # last copy. This is not always right, but it is rare - # enough that we require users that really mean to play - # such unportable linking tricks to link the library - # using -Wl,-lname, so that libtool does not consider it - # for duplicate removal. - case " $specialdeplibs " in - *" $deplib "*) new_libs="$deplib $new_libs" ;; - *) - case " $new_libs " in - *" $deplib "*) ;; - *) new_libs="$deplib $new_libs" ;; - esac - ;; - esac - ;; - esac - done - tmp_libs= - for deplib in $new_libs; do - case $deplib in - -L*) - case " $tmp_libs " in - *" $deplib "*) ;; - *) tmp_libs="$tmp_libs $deplib" ;; - esac - ;; - *) tmp_libs="$tmp_libs $deplib" ;; - esac - done - eval $var=\"$tmp_libs\" - done # for var - fi - # Last step: remove runtime libs from dependency_libs - # (they stay in deplibs) - tmp_libs= - for i in $dependency_libs ; do - case " $predeps $postdeps $compiler_lib_search_path " in - *" $i "*) - i="" - ;; - esac - if test -n "$i" ; then - tmp_libs="$tmp_libs $i" - fi - done - dependency_libs=$tmp_libs - done # for pass - if test "$linkmode" = prog; then - dlfiles="$newdlfiles" - fi - if test "$linkmode" = prog || test "$linkmode" = lib; then - dlprefiles="$newdlprefiles" - fi - - case $linkmode in - oldlib) - if test -n "$dlfiles$dlprefiles" || test "$dlself" != no; then - func_warning "\`-dlopen' is ignored for archives" - fi - - case " $deplibs" in - *\ -l* | *\ -L*) - func_warning "\`-l' and \`-L' are ignored for archives" ;; - esac - - test -n "$rpath" && \ - func_warning "\`-rpath' is ignored for archives" - - test -n "$xrpath" && \ - func_warning "\`-R' is ignored for archives" - - test -n "$vinfo" && \ - func_warning "\`-version-info/-version-number' is ignored for archives" - - test -n "$release" && \ - func_warning "\`-release' is ignored for archives" - - test -n "$export_symbols$export_symbols_regex" && \ - func_warning "\`-export-symbols' is ignored for archives" - - # Now set the variables for building old libraries. - build_libtool_libs=no - oldlibs="$output" - objs="$objs$old_deplibs" - ;; - - lib) - # Make sure we only generate libraries of the form `libNAME.la'. - case $outputname in - lib*) - func_stripname 'lib' '.la' "$outputname" - name=$func_stripname_result - eval shared_ext=\"$shrext_cmds\" - eval libname=\"$libname_spec\" - ;; - *) - test "$module" = no && \ - func_fatal_help "libtool library \`$output' must begin with \`lib'" - - if test "$need_lib_prefix" != no; then - # Add the "lib" prefix for modules if required - func_stripname '' '.la' "$outputname" - name=$func_stripname_result - eval shared_ext=\"$shrext_cmds\" - eval libname=\"$libname_spec\" - else - func_stripname '' '.la' "$outputname" - libname=$func_stripname_result - fi - ;; - esac - - if test -n "$objs"; then - if test "$deplibs_check_method" != pass_all; then - func_fatal_error "cannot build libtool library \`$output' from non-libtool objects on this host:$objs" - else - $ECHO - $ECHO "*** Warning: Linking the shared library $output against the non-libtool" - $ECHO "*** objects $objs is not portable!" - libobjs="$libobjs $objs" - fi - fi - - test "$dlself" != no && \ - func_warning "\`-dlopen self' is ignored for libtool libraries" - - set dummy $rpath - shift - test "$#" -gt 1 && \ - func_warning "ignoring multiple \`-rpath's for a libtool library" - - install_libdir="$1" - - oldlibs= - if test -z "$rpath"; then - if test "$build_libtool_libs" = yes; then - # Building a libtool convenience library. - # Some compilers have problems with a `.al' extension so - # convenience libraries should have the same extension an - # archive normally would. - oldlibs="$output_objdir/$libname.$libext $oldlibs" - build_libtool_libs=convenience - build_old_libs=yes - fi - - test -n "$vinfo" && \ - func_warning "\`-version-info/-version-number' is ignored for convenience libraries" - - test -n "$release" && \ - func_warning "\`-release' is ignored for convenience libraries" - else - - # Parse the version information argument. - save_ifs="$IFS"; IFS=':' - set dummy $vinfo 0 0 0 - shift - IFS="$save_ifs" - - test -n "$7" && \ - func_fatal_help "too many parameters to \`-version-info'" - - # convert absolute version numbers to libtool ages - # this retains compatibility with .la files and attempts - # to make the code below a bit more comprehensible - - case $vinfo_number in - yes) - number_major="$1" - number_minor="$2" - number_revision="$3" - # - # There are really only two kinds -- those that - # use the current revision as the major version - # and those that subtract age and use age as - # a minor version. But, then there is irix - # which has an extra 1 added just for fun - # - case $version_type in - darwin|linux|osf|windows|none) - func_arith $number_major + $number_minor - current=$func_arith_result - age="$number_minor" - revision="$number_revision" - ;; - freebsd-aout|freebsd-elf|sunos) - current="$number_major" - revision="$number_minor" - age="0" - ;; - irix|nonstopux) - func_arith $number_major + $number_minor - current=$func_arith_result - age="$number_minor" - revision="$number_minor" - lt_irix_increment=no - ;; - esac - ;; - no) - current="$1" - revision="$2" - age="$3" - ;; - esac - - # Check that each of the things are valid numbers. - case $current in - 0|[1-9]|[1-9][0-9]|[1-9][0-9][0-9]|[1-9][0-9][0-9][0-9]|[1-9][0-9][0-9][0-9][0-9]) ;; - *) - func_error "CURRENT \`$current' must be a nonnegative integer" - func_fatal_error "\`$vinfo' is not valid version information" - ;; - esac - - case $revision in - 0|[1-9]|[1-9][0-9]|[1-9][0-9][0-9]|[1-9][0-9][0-9][0-9]|[1-9][0-9][0-9][0-9][0-9]) ;; - *) - func_error "REVISION \`$revision' must be a nonnegative integer" - func_fatal_error "\`$vinfo' is not valid version information" - ;; - esac - - case $age in - 0|[1-9]|[1-9][0-9]|[1-9][0-9][0-9]|[1-9][0-9][0-9][0-9]|[1-9][0-9][0-9][0-9][0-9]) ;; - *) - func_error "AGE \`$age' must be a nonnegative integer" - func_fatal_error "\`$vinfo' is not valid version information" - ;; - esac - - if test "$age" -gt "$current"; then - func_error "AGE \`$age' is greater than the current interface number \`$current'" - func_fatal_error "\`$vinfo' is not valid version information" - fi - - # Calculate the version variables. - major= - versuffix= - verstring= - case $version_type in - none) ;; - - darwin) - # Like Linux, but with the current version available in - # verstring for coding it into the library header - func_arith $current - $age - major=.$func_arith_result - versuffix="$major.$age.$revision" - # Darwin ld doesn't like 0 for these options... - func_arith $current + 1 - minor_current=$func_arith_result - xlcverstring="${wl}-compatibility_version ${wl}$minor_current ${wl}-current_version ${wl}$minor_current.$revision" - verstring="-compatibility_version $minor_current -current_version $minor_current.$revision" - ;; - - freebsd-aout) - major=".$current" - versuffix=".$current.$revision"; - ;; - - freebsd-elf) - major=".$current" - versuffix=".$current" - ;; - - irix | nonstopux) - if test "X$lt_irix_increment" = "Xno"; then - func_arith $current - $age - else - func_arith $current - $age + 1 - fi - major=$func_arith_result - - case $version_type in - nonstopux) verstring_prefix=nonstopux ;; - *) verstring_prefix=sgi ;; - esac - verstring="$verstring_prefix$major.$revision" - - # Add in all the interfaces that we are compatible with. - loop=$revision - while test "$loop" -ne 0; do - func_arith $revision - $loop - iface=$func_arith_result - func_arith $loop - 1 - loop=$func_arith_result - verstring="$verstring_prefix$major.$iface:$verstring" - done - - # Before this point, $major must not contain `.'. - major=.$major - versuffix="$major.$revision" - ;; - - linux) - func_arith $current - $age - major=.$func_arith_result - versuffix="$major.$age.$revision" - ;; - - osf) - func_arith $current - $age - major=.$func_arith_result - versuffix=".$current.$age.$revision" - verstring="$current.$age.$revision" - - # Add in all the interfaces that we are compatible with. - loop=$age - while test "$loop" -ne 0; do - func_arith $current - $loop - iface=$func_arith_result - func_arith $loop - 1 - loop=$func_arith_result - verstring="$verstring:${iface}.0" - done - - # Make executables depend on our current version. - verstring="$verstring:${current}.0" - ;; - - qnx) - major=".$current" - versuffix=".$current" - ;; - - sunos) - major=".$current" - versuffix=".$current.$revision" - ;; - - windows) - # Use '-' rather than '.', since we only want one - # extension on DOS 8.3 filesystems. - func_arith $current - $age - major=$func_arith_result - versuffix="-$major" - ;; - - *) - func_fatal_configuration "unknown library version type \`$version_type'" - ;; - esac - - # Clear the version info if we defaulted, and they specified a release. - if test -z "$vinfo" && test -n "$release"; then - major= - case $version_type in - darwin) - # we can't check for "0.0" in archive_cmds due to quoting - # problems, so we reset it completely - verstring= - ;; - *) - verstring="0.0" - ;; - esac - if test "$need_version" = no; then - versuffix= - else - versuffix=".0.0" - fi - fi - - # Remove version info from name if versioning should be avoided - if test "$avoid_version" = yes && test "$need_version" = no; then - major= - versuffix= - verstring="" - fi - - # Check to see if the archive will have undefined symbols. - if test "$allow_undefined" = yes; then - if test "$allow_undefined_flag" = unsupported; then - func_warning "undefined symbols not allowed in $host shared libraries" - build_libtool_libs=no - build_old_libs=yes - fi - else - # Don't allow undefined symbols. - allow_undefined_flag="$no_undefined_flag" - fi - - fi - - func_generate_dlsyms "$libname" "$libname" "yes" - libobjs="$libobjs $symfileobj" - test "X$libobjs" = "X " && libobjs= - - if test "$mode" != relink; then - # Remove our outputs, but don't remove object files since they - # may have been created when compiling PIC objects. - removelist= - tempremovelist=`$ECHO "$output_objdir/*"` - for p in $tempremovelist; do - case $p in - *.$objext | *.gcno) - ;; - $output_objdir/$outputname | $output_objdir/$libname.* | $output_objdir/${libname}${release}.*) - if test "X$precious_files_regex" != "X"; then - if $ECHO "$p" | $EGREP -e "$precious_files_regex" >/dev/null 2>&1 - then - continue - fi - fi - removelist="$removelist $p" - ;; - *) ;; - esac - done - test -n "$removelist" && \ - func_show_eval "${RM}r \$removelist" - fi - - # Now set the variables for building old libraries. - if test "$build_old_libs" = yes && test "$build_libtool_libs" != convenience ; then - oldlibs="$oldlibs $output_objdir/$libname.$libext" - - # Transform .lo files to .o files. - oldobjs="$objs "`$ECHO "X$libobjs" | $SP2NL | $Xsed -e '/\.'${libext}'$/d' -e "$lo2o" | $NL2SP` - fi - - # Eliminate all temporary directories. - #for path in $notinst_path; do - # lib_search_path=`$ECHO "X$lib_search_path " | $Xsed -e "s% $path % %g"` - # deplibs=`$ECHO "X$deplibs " | $Xsed -e "s% -L$path % %g"` - # dependency_libs=`$ECHO "X$dependency_libs " | $Xsed -e "s% -L$path % %g"` - #done - - if test -n "$xrpath"; then - # If the user specified any rpath flags, then add them. - temp_xrpath= - for libdir in $xrpath; do - temp_xrpath="$temp_xrpath -R$libdir" - case "$finalize_rpath " in - *" $libdir "*) ;; - *) finalize_rpath="$finalize_rpath $libdir" ;; - esac - done - if test "$hardcode_into_libs" != yes || test "$build_old_libs" = yes; then - dependency_libs="$temp_xrpath $dependency_libs" - fi - fi - - # Make sure dlfiles contains only unique files that won't be dlpreopened - old_dlfiles="$dlfiles" - dlfiles= - for lib in $old_dlfiles; do - case " $dlprefiles $dlfiles " in - *" $lib "*) ;; - *) dlfiles="$dlfiles $lib" ;; - esac - done - - # Make sure dlprefiles contains only unique files - old_dlprefiles="$dlprefiles" - dlprefiles= - for lib in $old_dlprefiles; do - case "$dlprefiles " in - *" $lib "*) ;; - *) dlprefiles="$dlprefiles $lib" ;; - esac - done - - if test "$build_libtool_libs" = yes; then - if test -n "$rpath"; then - case $host in - *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-*-beos* | *-cegcc*) - # these systems don't actually have a c library (as such)! - ;; - *-*-rhapsody* | *-*-darwin1.[012]) - # Rhapsody C library is in the System framework - deplibs="$deplibs System.ltframework" - ;; - *-*-netbsd*) - # Don't link with libc until the a.out ld.so is fixed. - ;; - *-*-openbsd* | *-*-freebsd* | *-*-dragonfly*) - # Do not include libc due to us having libc/libc_r. - ;; - *-*-sco3.2v5* | *-*-sco5v6*) - # Causes problems with __ctype - ;; - *-*-sysv4.2uw2* | *-*-sysv5* | *-*-unixware* | *-*-OpenUNIX*) - # Compiler inserts libc in the correct place for threads to work - ;; - *) - # Add libc to deplibs on all other systems if necessary. - if test "$build_libtool_need_lc" = "yes"; then - deplibs="$deplibs -lc" - fi - ;; - esac - fi - - # Transform deplibs into only deplibs that can be linked in shared. - name_save=$name - libname_save=$libname - release_save=$release - versuffix_save=$versuffix - major_save=$major - # I'm not sure if I'm treating the release correctly. I think - # release should show up in the -l (ie -lgmp5) so we don't want to - # add it in twice. Is that correct? - release="" - versuffix="" - major="" - newdeplibs= - droppeddeps=no - case $deplibs_check_method in - pass_all) - # Don't check for shared/static. Everything works. - # This might be a little naive. We might want to check - # whether the library exists or not. But this is on - # osf3 & osf4 and I'm not really sure... Just - # implementing what was already the behavior. - newdeplibs=$deplibs - ;; - test_compile) - # This code stresses the "libraries are programs" paradigm to its - # limits. Maybe even breaks it. We compile a program, linking it - # against the deplibs as a proxy for the library. Then we can check - # whether they linked in statically or dynamically with ldd. - $opt_dry_run || $RM conftest.c - cat > conftest.c </dev/null` - for potent_lib in $potential_libs; do - # Follow soft links. - if ls -lLd "$potent_lib" 2>/dev/null | - $GREP " -> " >/dev/null; then - continue - fi - # The statement above tries to avoid entering an - # endless loop below, in case of cyclic links. - # We might still enter an endless loop, since a link - # loop can be closed while we follow links, - # but so what? - potlib="$potent_lib" - while test -h "$potlib" 2>/dev/null; do - potliblink=`ls -ld $potlib | ${SED} 's/.* -> //'` - case $potliblink in - [\\/]* | [A-Za-z]:[\\/]*) potlib="$potliblink";; - *) potlib=`$ECHO "X$potlib" | $Xsed -e 's,[^/]*$,,'`"$potliblink";; - esac - done - if eval $file_magic_cmd \"\$potlib\" 2>/dev/null | - $SED -e 10q | - $EGREP "$file_magic_regex" > /dev/null; then - newdeplibs="$newdeplibs $a_deplib" - a_deplib="" - break 2 - fi - done - done - fi - if test -n "$a_deplib" ; then - droppeddeps=yes - $ECHO - $ECHO "*** Warning: linker path does not have real file for library $a_deplib." - $ECHO "*** I have the capability to make that library automatically link in when" - $ECHO "*** you link to this library. But I can only do this if you have a" - $ECHO "*** shared version of the library, which you do not appear to have" - $ECHO "*** because I did check the linker path looking for a file starting" - if test -z "$potlib" ; then - $ECHO "*** with $libname but no candidates were found. (...for file magic test)" - else - $ECHO "*** with $libname and none of the candidates passed a file format test" - $ECHO "*** using a file magic. Last file checked: $potlib" - fi - fi - ;; - *) - # Add a -L argument. - newdeplibs="$newdeplibs $a_deplib" - ;; - esac - done # Gone through all deplibs. - ;; - match_pattern*) - set dummy $deplibs_check_method; shift - match_pattern_regex=`expr "$deplibs_check_method" : "$1 \(.*\)"` - for a_deplib in $deplibs; do - case $a_deplib in - -l*) - func_stripname -l '' "$a_deplib" - name=$func_stripname_result - if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then - case " $predeps $postdeps " in - *" $a_deplib "*) - newdeplibs="$newdeplibs $a_deplib" - a_deplib="" - ;; - esac - fi - if test -n "$a_deplib" ; then - libname=`eval "\\$ECHO \"$libname_spec\""` - for i in $lib_search_path $sys_lib_search_path $shlib_search_path; do - potential_libs=`ls $i/$libname[.-]* 2>/dev/null` - for potent_lib in $potential_libs; do - potlib="$potent_lib" # see symlink-check above in file_magic test - if eval "\$ECHO \"X$potent_lib\"" 2>/dev/null | $Xsed -e 10q | \ - $EGREP "$match_pattern_regex" > /dev/null; then - newdeplibs="$newdeplibs $a_deplib" - a_deplib="" - break 2 - fi - done - done - fi - if test -n "$a_deplib" ; then - droppeddeps=yes - $ECHO - $ECHO "*** Warning: linker path does not have real file for library $a_deplib." - $ECHO "*** I have the capability to make that library automatically link in when" - $ECHO "*** you link to this library. But I can only do this if you have a" - $ECHO "*** shared version of the library, which you do not appear to have" - $ECHO "*** because I did check the linker path looking for a file starting" - if test -z "$potlib" ; then - $ECHO "*** with $libname but no candidates were found. (...for regex pattern test)" - else - $ECHO "*** with $libname and none of the candidates passed a file format test" - $ECHO "*** using a regex pattern. Last file checked: $potlib" - fi - fi - ;; - *) - # Add a -L argument. - newdeplibs="$newdeplibs $a_deplib" - ;; - esac - done # Gone through all deplibs. - ;; - none | unknown | *) - newdeplibs="" - tmp_deplibs=`$ECHO "X $deplibs" | $Xsed \ - -e 's/ -lc$//' -e 's/ -[LR][^ ]*//g'` - if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then - for i in $predeps $postdeps ; do - # can't use Xsed below, because $i might contain '/' - tmp_deplibs=`$ECHO "X $tmp_deplibs" | $Xsed -e "s,$i,,"` - done - fi - if $ECHO "X $tmp_deplibs" | $Xsed -e 's/[ ]//g' | - $GREP . >/dev/null; then - $ECHO - if test "X$deplibs_check_method" = "Xnone"; then - $ECHO "*** Warning: inter-library dependencies are not supported in this platform." - else - $ECHO "*** Warning: inter-library dependencies are not known to be supported." - fi - $ECHO "*** All declared inter-library dependencies are being dropped." - droppeddeps=yes - fi - ;; - esac - versuffix=$versuffix_save - major=$major_save - release=$release_save - libname=$libname_save - name=$name_save + for (base = name; *name; name++) + if (IS_DIR_SEPARATOR (*name)) + base = name + 1; + return base; +} - case $host in - *-*-rhapsody* | *-*-darwin1.[012]) - # On Rhapsody replace the C library with the System framework - newdeplibs=`$ECHO "X $newdeplibs" | $Xsed -e 's/ -lc / System.ltframework /'` - ;; - esac +int +check_executable(const char * path) +{ + struct stat st; - if test "$droppeddeps" = yes; then - if test "$module" = yes; then - $ECHO - $ECHO "*** Warning: libtool could not satisfy all declared inter-library" - $ECHO "*** dependencies of module $libname. Therefore, libtool will create" - $ECHO "*** a static module, that should work as long as the dlopening" - $ECHO "*** application is linked with the -dlopen flag." - if test -z "$global_symbol_pipe"; then - $ECHO - $ECHO "*** However, this would only work if libtool was able to extract symbol" - $ECHO "*** lists from a program, using \`nm' or equivalent, but libtool could" - $ECHO "*** not find such a program. So, this module is probably useless." - $ECHO "*** \`nm' from GNU binutils and a full rebuild may help." - fi - if test "$build_old_libs" = no; then - oldlibs="$output_objdir/$libname.$libext" - build_libtool_libs=module - build_old_libs=yes - else - build_libtool_libs=no - fi - else - $ECHO "*** The inter-library dependencies that have been dropped here will be" - $ECHO "*** automatically added whenever a program is linked with this library" - $ECHO "*** or is declared to -dlopen it." + DEBUG("(check_executable) : %s\n", path ? (*path ? path : "EMPTY!") : "NULL!"); + if ((!path) || (!*path)) + return 0; - if test "$allow_undefined" = no; then - $ECHO - $ECHO "*** Since this library must not contain undefined symbols," - $ECHO "*** because either the platform does not support them or" - $ECHO "*** it was explicitly requested with -no-undefined," - $ECHO "*** libtool will only create a static version of it." - if test "$build_old_libs" = no; then - oldlibs="$output_objdir/$libname.$libext" - build_libtool_libs=module - build_old_libs=yes - else - build_libtool_libs=no - fi - fi - fi - fi - # Done checking deplibs! - deplibs=$newdeplibs - fi - # Time to change all our "foo.ltframework" stuff back to "-framework foo" - case $host in - *-*-darwin*) - newdeplibs=`$ECHO "X $newdeplibs" | $Xsed -e 's% \([^ $]*\).ltframework% -framework \1%g'` - new_inherited_linker_flags=`$ECHO "X $new_inherited_linker_flags" | $Xsed -e 's% \([^ $]*\).ltframework% -framework \1%g'` - deplibs=`$ECHO "X $deplibs" | $Xsed -e 's% \([^ $]*\).ltframework% -framework \1%g'` - ;; - esac + if ((stat (path, &st) >= 0) && + ( + /* MinGW & native WIN32 do not support S_IXOTH or S_IXGRP */ +#if defined (S_IXOTH) + ((st.st_mode & S_IXOTH) == S_IXOTH) || +#endif +#if defined (S_IXGRP) + ((st.st_mode & S_IXGRP) == S_IXGRP) || +#endif + ((st.st_mode & S_IXUSR) == S_IXUSR)) + ) + return 1; + else + return 0; +} - # move library search paths that coincide with paths to not yet - # installed libraries to the beginning of the library search list - new_libs= - for path in $notinst_path; do - case " $new_libs " in - *" -L$path/$objdir "*) ;; - *) - case " $deplibs " in - *" -L$path/$objdir "*) - new_libs="$new_libs -L$path/$objdir" ;; - esac - ;; - esac - done - for deplib in $deplibs; do - case $deplib in - -L*) - case " $new_libs " in - *" $deplib "*) ;; - *) new_libs="$new_libs $deplib" ;; - esac - ;; - *) new_libs="$new_libs $deplib" ;; - esac - done - deplibs="$new_libs" +/* Searches for the full path of the wrapper. Returns + newly allocated full path name if found, NULL otherwise */ +char * +find_executable (const char* wrapper) +{ + int has_slash = 0; + const char* p; + const char* p_next; + /* static buffer for getcwd */ + char tmp[LT_PATHMAX + 1]; + int tmp_len; + char* concat_name; - # All the library-specific variables (install_libdir is set above). - library_names= - old_library= - dlname= + DEBUG("(find_executable) : %s\n", wrapper ? (*wrapper ? wrapper : "EMPTY!") : "NULL!"); - # Test again, we may have decided not to build it any more - if test "$build_libtool_libs" = yes; then - if test "$hardcode_into_libs" = yes; then - # Hardcode the library paths - hardcode_libdirs= - dep_rpath= - rpath="$finalize_rpath" - test "$mode" != relink && rpath="$compile_rpath$rpath" - for libdir in $rpath; do - if test -n "$hardcode_libdir_flag_spec"; then - if test -n "$hardcode_libdir_separator"; then - if test -z "$hardcode_libdirs"; then - hardcode_libdirs="$libdir" - else - # Just accumulate the unique libdirs. - case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in - *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) - ;; - *) - hardcode_libdirs="$hardcode_libdirs$hardcode_libdir_separator$libdir" - ;; - esac - fi - else - eval flag=\"$hardcode_libdir_flag_spec\" - dep_rpath="$dep_rpath $flag" - fi - elif test -n "$runpath_var"; then - case "$perm_rpath " in - *" $libdir "*) ;; - *) perm_rpath="$perm_rpath $libdir" ;; - esac - fi - done - # Substitute the hardcoded libdirs into the rpath. - if test -n "$hardcode_libdir_separator" && - test -n "$hardcode_libdirs"; then - libdir="$hardcode_libdirs" - if test -n "$hardcode_libdir_flag_spec_ld"; then - eval dep_rpath=\"$hardcode_libdir_flag_spec_ld\" - else - eval dep_rpath=\"$hardcode_libdir_flag_spec\" - fi - fi - if test -n "$runpath_var" && test -n "$perm_rpath"; then - # We should set the runpath_var. - rpath= - for dir in $perm_rpath; do - rpath="$rpath$dir:" - done - eval "$runpath_var='$rpath\$$runpath_var'; export $runpath_var" - fi - test -n "$dep_rpath" && deplibs="$dep_rpath $deplibs" - fi + if ((wrapper == NULL) || (*wrapper == '\0')) + return NULL; - shlibpath="$finalize_shlibpath" - test "$mode" != relink && shlibpath="$compile_shlibpath$shlibpath" - if test -n "$shlibpath"; then - eval "$shlibpath_var='$shlibpath\$$shlibpath_var'; export $shlibpath_var" - fi + /* Absolute path? */ +#if defined (HAVE_DOS_BASED_FILE_SYSTEM) + if (isalpha ((unsigned char)wrapper[0]) && wrapper[1] == ':') + { + concat_name = xstrdup (wrapper); + if (check_executable(concat_name)) + return concat_name; + XFREE(concat_name); + } + else + { +#endif + if (IS_DIR_SEPARATOR (wrapper[0])) + { + concat_name = xstrdup (wrapper); + if (check_executable(concat_name)) + return concat_name; + XFREE(concat_name); + } +#if defined (HAVE_DOS_BASED_FILE_SYSTEM) + } +#endif + + for (p = wrapper; *p; p++) + if (*p == '/') + { + has_slash = 1; + break; + } + if (!has_slash) + { + /* no slashes; search PATH */ + const char* path = getenv ("PATH"); + if (path != NULL) + { + for (p = path; *p; p = p_next) + { + const char* q; + size_t p_len; + for (q = p; *q; q++) + if (IS_PATH_SEPARATOR(*q)) + break; + p_len = q - p; + p_next = (*q == '\0' ? q : q + 1); + if (p_len == 0) + { + /* empty path: current directory */ + if (getcwd (tmp, LT_PATHMAX) == NULL) + lt_fatal ("getcwd failed"); + tmp_len = strlen(tmp); + concat_name = XMALLOC(char, tmp_len + 1 + strlen(wrapper) + 1); + memcpy (concat_name, tmp, tmp_len); + concat_name[tmp_len] = '/'; + strcpy (concat_name + tmp_len + 1, wrapper); + } + else + { + concat_name = XMALLOC(char, p_len + 1 + strlen(wrapper) + 1); + memcpy (concat_name, p, p_len); + concat_name[p_len] = '/'; + strcpy (concat_name + p_len + 1, wrapper); + } + if (check_executable(concat_name)) + return concat_name; + XFREE(concat_name); + } + } + /* not found in PATH; assume curdir */ + } + /* Relative path | not found in path: prepend cwd */ + if (getcwd (tmp, LT_PATHMAX) == NULL) + lt_fatal ("getcwd failed"); + tmp_len = strlen(tmp); + concat_name = XMALLOC(char, tmp_len + 1 + strlen(wrapper) + 1); + memcpy (concat_name, tmp, tmp_len); + concat_name[tmp_len] = '/'; + strcpy (concat_name + tmp_len + 1, wrapper); + + if (check_executable(concat_name)) + return concat_name; + XFREE(concat_name); + return NULL; +} + +char * +strendzap(char *str, const char *pat) +{ + size_t len, patlen; + + assert(str != NULL); + assert(pat != NULL); + + len = strlen(str); + patlen = strlen(pat); + + if (patlen <= len) + { + str += len - patlen; + if (strcmp(str, pat) == 0) + *str = '\0'; + } + return str; +} + +static void +lt_error_core (int exit_status, const char * mode, + const char * message, va_list ap) +{ + fprintf (stderr, "%s: %s: ", program_name, mode); + vfprintf (stderr, message, ap); + fprintf (stderr, ".\n"); + + if (exit_status >= 0) + exit (exit_status); +} + +void +lt_fatal (const char *message, ...) +{ + va_list ap; + va_start (ap, message); + lt_error_core (EXIT_FAILURE, "FATAL", message, ap); + va_end (ap); +} +EOF + # we should really use a build-platform specific compiler + # here, but OTOH, the wrappers (shell script and this C one) + # are only useful if you want to execute the "real" binary. + # Since the "real" binary is built for $host, then this + # wrapper might as well be built for $host, too. + $run $LTCC $LTCFLAGS -s -o $cwrapper $cwrappersource + ;; + esac + $rm $output + trap "$rm $output; exit $EXIT_FAILURE" 1 2 15 + + $echo > $output "\ +#! $SHELL + +# $output - temporary wrapper script for $objdir/$outputname +# Generated by $PROGRAM - GNU $PACKAGE $VERSION$TIMESTAMP +# +# The $output program cannot be directly executed until all the libtool +# libraries that it depends on are installed. +# +# This wrapper script should never be moved out of the build directory. +# If it is, it will not operate correctly. + +# Sed substitution that helps us do robust quoting. It backslashifies +# metacharacters that are still active within double-quoted strings. +Xsed='${SED} -e 1s/^X//' +sed_quote_subst='$sed_quote_subst' + +# Be Bourne compatible (taken from Autoconf:_AS_BOURNE_COMPATIBLE). +if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then + emulate sh + NULLCMD=: + # Zsh 3.x and 4.x performs word splitting on \${1+\"\$@\"}, which + # is contrary to our usage. Disable this feature. + alias -g '\${1+\"\$@\"}'='\"\$@\"' + setopt NO_GLOB_SUBST +else + case \`(set -o) 2>/dev/null\` in *posix*) set -o posix;; esac +fi +BIN_SH=xpg4; export BIN_SH # for Tru64 +DUALCASE=1; export DUALCASE # for MKS sh + +# The HP-UX ksh and POSIX shell print the target directory to stdout +# if CDPATH is set. +(unset CDPATH) >/dev/null 2>&1 && unset CDPATH + +relink_command=\"$relink_command\" + +# This environment variable determines our operation mode. +if test \"\$libtool_install_magic\" = \"$magic\"; then + # install mode needs the following variable: + notinst_deplibs='$notinst_deplibs' +else + # When we are sourced in execute mode, \$file and \$echo are already set. + if test \"\$libtool_execute_magic\" != \"$magic\"; then + echo=\"$qecho\" + file=\"\$0\" + # Make sure echo works. + if test \"X\$1\" = X--no-reexec; then + # Discard the --no-reexec flag, and continue. + shift + elif test \"X\`(\$echo '\t') 2>/dev/null\`\" = 'X\t'; then + # Yippee, \$echo works! + : + else + # Restart under the correct shell, and then maybe \$echo will work. + exec $SHELL \"\$0\" --no-reexec \${1+\"\$@\"} + fi + fi\ +" + $echo >> $output "\ - # Get the real and link names of the library. - eval shared_ext=\"$shrext_cmds\" - eval library_names=\"$library_names_spec\" - set dummy $library_names - shift - realname="$1" - shift + # Find the directory that this script lives in. + thisdir=\`\$echo \"X\$file\" | \$Xsed -e 's%/[^/]*$%%'\` + test \"x\$thisdir\" = \"x\$file\" && thisdir=. - if test -n "$soname_spec"; then - eval soname=\"$soname_spec\" - else - soname="$realname" - fi - if test -z "$dlname"; then - dlname=$soname - fi + # Follow symbolic links until we get to the real thisdir. + file=\`ls -ld \"\$file\" | ${SED} -n 's/.*-> //p'\` + while test -n \"\$file\"; do + destdir=\`\$echo \"X\$file\" | \$Xsed -e 's%/[^/]*\$%%'\` - lib="$output_objdir/$realname" - linknames= - for link - do - linknames="$linknames $link" - done + # If there was a directory component, then change thisdir. + if test \"x\$destdir\" != \"x\$file\"; then + case \"\$destdir\" in + [\\\\/]* | [A-Za-z]:[\\\\/]*) thisdir=\"\$destdir\" ;; + *) thisdir=\"\$thisdir/\$destdir\" ;; + esac + fi - # Use standard objects if they are pic - test -z "$pic_flag" && libobjs=`$ECHO "X$libobjs" | $SP2NL | $Xsed -e "$lo2o" | $NL2SP` - test "X$libobjs" = "X " && libobjs= + file=\`\$echo \"X\$file\" | \$Xsed -e 's%^.*/%%'\` + file=\`ls -ld \"\$thisdir/\$file\" | ${SED} -n 's/.*-> //p'\` + done - delfiles= - if test -n "$export_symbols" && test -n "$include_expsyms"; then - $opt_dry_run || cp "$export_symbols" "$output_objdir/$libname.uexp" - export_symbols="$output_objdir/$libname.uexp" - delfiles="$delfiles $export_symbols" - fi + # Try to get the absolute directory name. + absdir=\`cd \"\$thisdir\" && pwd\` + test -n \"\$absdir\" && thisdir=\"\$absdir\" +" - orig_export_symbols= - case $host_os in - cygwin* | mingw* | cegcc*) - if test -n "$export_symbols" && test -z "$export_symbols_regex"; then - # exporting using user supplied symfile - if test "x`$SED 1q $export_symbols`" != xEXPORTS; then - # and it's NOT already a .def file. Must figure out - # which of the given symbols are data symbols and tag - # them as such. So, trigger use of export_symbols_cmds. - # export_symbols gets reassigned inside the "prepare - # the list of exported symbols" if statement, so the - # include_expsyms logic still works. - orig_export_symbols="$export_symbols" - export_symbols= - always_export_symbols=yes - fi - fi - ;; - esac + if test "$fast_install" = yes; then + $echo >> $output "\ + program=lt-'$outputname'$exeext + progdir=\"\$thisdir/$objdir\" - # Prepare the list of exported symbols - if test -z "$export_symbols"; then - if test "$always_export_symbols" = yes || test -n "$export_symbols_regex"; then - func_verbose "generating symbol list for \`$libname.la'" - export_symbols="$output_objdir/$libname.exp" - $opt_dry_run || $RM $export_symbols - cmds=$export_symbols_cmds - save_ifs="$IFS"; IFS='~' - for cmd in $cmds; do - IFS="$save_ifs" - eval cmd=\"$cmd\" - func_len " $cmd" - len=$func_len_result - if test "$len" -lt "$max_cmd_len" || test "$max_cmd_len" -le -1; then - func_show_eval "$cmd" 'exit $?' - skipped_export=false - else - # The command line is too long to execute in one step. - func_verbose "using reloadable object file for export list..." - skipped_export=: - # Break out early, otherwise skipped_export may be - # set to false by a later but shorter cmd. - break - fi - done - IFS="$save_ifs" - if test -n "$export_symbols_regex" && test "X$skipped_export" != "X:"; then - func_show_eval '$EGREP -e "$export_symbols_regex" "$export_symbols" > "${export_symbols}T"' - func_show_eval '$MV "${export_symbols}T" "$export_symbols"' - fi - fi - fi + if test ! -f \"\$progdir/\$program\" || \\ + { file=\`ls -1dt \"\$progdir/\$program\" \"\$progdir/../\$program\" 2>/dev/null | ${SED} 1q\`; \\ + test \"X\$file\" != \"X\$progdir/\$program\"; }; then - if test -n "$export_symbols" && test -n "$include_expsyms"; then - tmp_export_symbols="$export_symbols" - test -n "$orig_export_symbols" && tmp_export_symbols="$orig_export_symbols" - $opt_dry_run || eval '$ECHO "X$include_expsyms" | $Xsed | $SP2NL >> "$tmp_export_symbols"' - fi + file=\"\$\$-\$program\" - if test "X$skipped_export" != "X:" && test -n "$orig_export_symbols"; then - # The given exports_symbols file has to be filtered, so filter it. - func_verbose "filter symbol list for \`$libname.la' to tag DATA exports" - # FIXME: $output_objdir/$libname.filter potentially contains lots of - # 's' commands which not all seds can handle. GNU sed should be fine - # though. Also, the filter scales superlinearly with the number of - # global variables. join(1) would be nice here, but unfortunately - # isn't a blessed tool. - $opt_dry_run || $SED -e '/[ ,]DATA/!d;s,\(.*\)\([ \,].*\),s|^\1$|\1\2|,' < $export_symbols > $output_objdir/$libname.filter - delfiles="$delfiles $export_symbols $output_objdir/$libname.filter" - export_symbols=$output_objdir/$libname.def - $opt_dry_run || $SED -f $output_objdir/$libname.filter < $orig_export_symbols > $export_symbols - fi + if test ! -d \"\$progdir\"; then + $mkdir \"\$progdir\" + else + $rm \"\$progdir/\$file\" + fi" - tmp_deplibs= - for test_deplib in $deplibs; do - case " $convenience " in - *" $test_deplib "*) ;; - *) - tmp_deplibs="$tmp_deplibs $test_deplib" - ;; - esac - done - deplibs="$tmp_deplibs" + $echo >> $output "\ - if test -n "$convenience"; then - if test -n "$whole_archive_flag_spec" && - test "$compiler_needs_object" = yes && - test -z "$libobjs"; then - # extract the archives, so we have objects to list. - # TODO: could optimize this to just extract one archive. - whole_archive_flag_spec= - fi - if test -n "$whole_archive_flag_spec"; then - save_libobjs=$libobjs - eval libobjs=\"\$libobjs $whole_archive_flag_spec\" - test "X$libobjs" = "X " && libobjs= - else - gentop="$output_objdir/${outputname}x" - generated="$generated $gentop" + # relink executable if necessary + if test -n \"\$relink_command\"; then + if relink_command_output=\`eval \$relink_command 2>&1\`; then : + else + $echo \"\$relink_command_output\" >&2 + $rm \"\$progdir/\$file\" + exit $EXIT_FAILURE + fi + fi - func_extract_archives $gentop $convenience - libobjs="$libobjs $func_extract_archives_result" - test "X$libobjs" = "X " && libobjs= - fi + $mv \"\$progdir/\$file\" \"\$progdir/\$program\" 2>/dev/null || + { $rm \"\$progdir/\$program\"; + $mv \"\$progdir/\$file\" \"\$progdir/\$program\"; } + $rm \"\$progdir/\$file\" + fi" + else + $echo >> $output "\ + program='$outputname' + progdir=\"\$thisdir/$objdir\" +" fi - if test "$thread_safe" = yes && test -n "$thread_safe_flag_spec"; then - eval flag=\"$thread_safe_flag_spec\" - linker_flags="$linker_flags $flag" - fi + $echo >> $output "\ - # Make a backup of the uninstalled library when relinking - if test "$mode" = relink; then - $opt_dry_run || eval '(cd $output_objdir && $RM ${realname}U && $MV $realname ${realname}U)' || exit $? - fi + if test -f \"\$progdir/\$program\"; then" - # Do each of the archive commands. - if test "$module" = yes && test -n "$module_cmds" ; then - if test -n "$export_symbols" && test -n "$module_expsym_cmds"; then - eval test_cmds=\"$module_expsym_cmds\" - cmds=$module_expsym_cmds - else - eval test_cmds=\"$module_cmds\" - cmds=$module_cmds - fi - else - if test -n "$export_symbols" && test -n "$archive_expsym_cmds"; then - eval test_cmds=\"$archive_expsym_cmds\" - cmds=$archive_expsym_cmds - else - eval test_cmds=\"$archive_cmds\" - cmds=$archive_cmds - fi - fi + # Export our shlibpath_var if we have one. + if test "$shlibpath_overrides_runpath" = yes && test -n "$shlibpath_var" && test -n "$temp_rpath"; then + $echo >> $output "\ + # Add our own library path to $shlibpath_var + $shlibpath_var=\"$temp_rpath\$$shlibpath_var\" - if test "X$skipped_export" != "X:" && - func_len " $test_cmds" && - len=$func_len_result && - test "$len" -lt "$max_cmd_len" || test "$max_cmd_len" -le -1; then - : - else - # The command line is too long to link in one step, link piecewise - # or, if using GNU ld and skipped_export is not :, use a linker - # script. + # Some systems cannot cope with colon-terminated $shlibpath_var + # The second colon is a workaround for a bug in BeOS R4 sed + $shlibpath_var=\`\$echo \"X\$$shlibpath_var\" | \$Xsed -e 's/::*\$//'\` - # Save the value of $output and $libobjs because we want to - # use them later. If we have whole_archive_flag_spec, we - # want to use save_libobjs as it was before - # whole_archive_flag_spec was expanded, because we can't - # assume the linker understands whole_archive_flag_spec. - # This may have to be revisited, in case too many - # convenience libraries get linked in and end up exceeding - # the spec. - if test -z "$convenience" || test -z "$whole_archive_flag_spec"; then - save_libobjs=$libobjs - fi - save_output=$output - output_la=`$ECHO "X$output" | $Xsed -e "$basename"` + export $shlibpath_var +" + fi - # Clear the reloadable object creation command queue and - # initialize k to one. - test_cmds= - concat_cmds= - objlist= - last_robj= - k=1 + # fixup the dll searchpath if we need to. + if test -n "$dllsearchpath"; then + $echo >> $output "\ + # Add the dll search path components to the executable PATH + PATH=$dllsearchpath:\$PATH +" + fi - if test -n "$save_libobjs" && test "X$skipped_export" != "X:" && test "$with_gnu_ld" = yes; then - output=${output_objdir}/${output_la}.lnkscript - func_verbose "creating GNU ld script: $output" - $ECHO 'INPUT (' > $output - for obj in $save_libobjs - do - $ECHO "$obj" >> $output - done - $ECHO ')' >> $output - delfiles="$delfiles $output" - elif test -n "$save_libobjs" && test "X$skipped_export" != "X:" && test "X$file_list_spec" != X; then - output=${output_objdir}/${output_la}.lnk - func_verbose "creating linker input file list: $output" - : > $output - set x $save_libobjs - shift - firstobj= - if test "$compiler_needs_object" = yes; then - firstobj="$1 " - shift - fi - for obj - do - $ECHO "$obj" >> $output - done - delfiles="$delfiles $output" - output=$firstobj\"$file_list_spec$output\" - else - if test -n "$save_libobjs"; then - func_verbose "creating reloadable object files..." - output=$output_objdir/$output_la-${k}.$objext - eval test_cmds=\"$reload_cmds\" - func_len " $test_cmds" - len0=$func_len_result - len=$len0 - - # Loop over the list of objects to be linked. - for obj in $save_libobjs - do - func_len " $obj" - func_arith $len + $func_len_result - len=$func_arith_result - if test "X$objlist" = X || - test "$len" -lt "$max_cmd_len"; then - func_append objlist " $obj" - else - # The command $test_cmds is almost too long, add a - # command to the queue. - if test "$k" -eq 1 ; then - # The first file doesn't have a previous command to add. - eval concat_cmds=\"$reload_cmds $objlist $last_robj\" - else - # All subsequent reloadable object files will link in - # the last one created. - eval concat_cmds=\"\$concat_cmds~$reload_cmds $objlist $last_robj~\$RM $last_robj\" - fi - last_robj=$output_objdir/$output_la-${k}.$objext - func_arith $k + 1 - k=$func_arith_result - output=$output_objdir/$output_la-${k}.$objext - objlist=$obj - func_len " $last_robj" - func_arith $len0 + $func_len_result - len=$func_arith_result - fi - done - # Handle the remaining objects by creating one last - # reloadable object file. All subsequent reloadable object - # files will link in the last one created. - test -z "$concat_cmds" || concat_cmds=$concat_cmds~ - eval concat_cmds=\"\${concat_cmds}$reload_cmds $objlist $last_robj\" - if test -n "$last_robj"; then - eval concat_cmds=\"\${concat_cmds}~\$RM $last_robj\" - fi - delfiles="$delfiles $output" + $echo >> $output "\ + if test \"\$libtool_execute_magic\" != \"$magic\"; then + # Run the actual program with our arguments. +" + case $host in + # Backslashes separate directories on plain windows + *-*-mingw | *-*-os2*) + $echo >> $output "\ + exec \"\$progdir\\\\\$program\" \${1+\"\$@\"} +" + ;; - else - output= - fi + *) + $echo >> $output "\ + exec \"\$progdir/\$program\" \${1+\"\$@\"} +" + ;; + esac + $echo >> $output "\ + \$echo \"\$0: cannot exec \$program \$*\" + exit $EXIT_FAILURE + fi + else + # The program doesn't exist. + \$echo \"\$0: error: \\\`\$progdir/\$program' does not exist\" 1>&2 + \$echo \"This script is just a wrapper for \$program.\" 1>&2 + $echo \"See the $PACKAGE documentation for more information.\" 1>&2 + exit $EXIT_FAILURE + fi +fi\ +" + chmod +x $output + fi + exit $EXIT_SUCCESS + ;; + esac - if ${skipped_export-false}; then - func_verbose "generating symbol list for \`$libname.la'" - export_symbols="$output_objdir/$libname.exp" - $opt_dry_run || $RM $export_symbols - libobjs=$output - # Append the command to create the export file. - test -z "$concat_cmds" || concat_cmds=$concat_cmds~ - eval concat_cmds=\"\$concat_cmds$export_symbols_cmds\" - if test -n "$last_robj"; then - eval concat_cmds=\"\$concat_cmds~\$RM $last_robj\" - fi - fi + # See if we need to build an old-fashioned archive. + for oldlib in $oldlibs; do - test -n "$save_libobjs" && - func_verbose "creating a temporary reloadable object file: $output" + if test "$build_libtool_libs" = convenience; then + oldobjs="$libobjs_save" + addlibs="$convenience" + build_libtool_libs=no + else + if test "$build_libtool_libs" = module; then + oldobjs="$libobjs_save" + build_libtool_libs=no + else + oldobjs="$old_deplibs $non_pic_objects" + fi + addlibs="$old_convenience" + fi - # Loop through the commands generated above and execute them. - save_ifs="$IFS"; IFS='~' - for cmd in $concat_cmds; do - IFS="$save_ifs" - $opt_silent || { - func_quote_for_expand "$cmd" - eval "func_echo $func_quote_for_expand_result" - } - $opt_dry_run || eval "$cmd" || { - lt_exit=$? - - # Restore the uninstalled library and exit - if test "$mode" = relink; then - ( cd "$output_objdir" && \ - $RM "${realname}T" && \ - $MV "${realname}U" "$realname" ) - fi + if test -n "$addlibs"; then + gentop="$output_objdir/${outputname}x" + generated="$generated $gentop" - exit $lt_exit - } - done - IFS="$save_ifs" + func_extract_archives $gentop $addlibs + oldobjs="$oldobjs $func_extract_archives_result" + fi - if test -n "$export_symbols_regex" && ${skipped_export-false}; then - func_show_eval '$EGREP -e "$export_symbols_regex" "$export_symbols" > "${export_symbols}T"' - func_show_eval '$MV "${export_symbols}T" "$export_symbols"' - fi - fi + # Do each command in the archive commands. + if test -n "$old_archive_from_new_cmds" && test "$build_libtool_libs" = yes; then + cmds=$old_archive_from_new_cmds + else + # POSIX demands no paths to be encoded in archives. We have + # to avoid creating archives with duplicate basenames if we + # might have to extract them afterwards, e.g., when creating a + # static archive out of a convenience library, or when linking + # the entirety of a libtool archive into another (currently + # not supported by libtool). + if (for obj in $oldobjs + do + $echo "X$obj" | $Xsed -e 's%^.*/%%' + done | sort | sort -uc >/dev/null 2>&1); then + : + else + $echo "copying selected object files to avoid basename conflicts..." - if ${skipped_export-false}; then - if test -n "$export_symbols" && test -n "$include_expsyms"; then - tmp_export_symbols="$export_symbols" - test -n "$orig_export_symbols" && tmp_export_symbols="$orig_export_symbols" - $opt_dry_run || eval '$ECHO "X$include_expsyms" | $Xsed | $SP2NL >> "$tmp_export_symbols"' - fi + if test -z "$gentop"; then + gentop="$output_objdir/${outputname}x" + generated="$generated $gentop" - if test -n "$orig_export_symbols"; then - # The given exports_symbols file has to be filtered, so filter it. - func_verbose "filter symbol list for \`$libname.la' to tag DATA exports" - # FIXME: $output_objdir/$libname.filter potentially contains lots of - # 's' commands which not all seds can handle. GNU sed should be fine - # though. Also, the filter scales superlinearly with the number of - # global variables. join(1) would be nice here, but unfortunately - # isn't a blessed tool. - $opt_dry_run || $SED -e '/[ ,]DATA/!d;s,\(.*\)\([ \,].*\),s|^\1$|\1\2|,' < $export_symbols > $output_objdir/$libname.filter - delfiles="$delfiles $export_symbols $output_objdir/$libname.filter" - export_symbols=$output_objdir/$libname.def - $opt_dry_run || $SED -f $output_objdir/$libname.filter < $orig_export_symbols > $export_symbols + $show "${rm}r $gentop" + $run ${rm}r "$gentop" + $show "$mkdir $gentop" + $run $mkdir "$gentop" + exit_status=$? + if test "$exit_status" -ne 0 && test ! -d "$gentop"; then + exit $exit_status fi fi - libobjs=$output - # Restore the value of output. - output=$save_output + save_oldobjs=$oldobjs + oldobjs= + counter=1 + for obj in $save_oldobjs + do + objbase=`$echo "X$obj" | $Xsed -e 's%^.*/%%'` + case " $oldobjs " in + " ") oldobjs=$obj ;; + *[\ /]"$objbase "*) + while :; do + # Make sure we don't pick an alternate name that also + # overlaps. + newobj=lt$counter-$objbase + counter=`expr $counter + 1` + case " $oldobjs " in + *[\ /]"$newobj "*) ;; + *) if test ! -f "$gentop/$newobj"; then break; fi ;; + esac + done + $show "ln $obj $gentop/$newobj || cp $obj $gentop/$newobj" + $run ln "$obj" "$gentop/$newobj" || + $run cp "$obj" "$gentop/$newobj" + oldobjs="$oldobjs $gentop/$newobj" + ;; + *) oldobjs="$oldobjs $obj" ;; + esac + done + fi - if test -n "$convenience" && test -n "$whole_archive_flag_spec"; then - eval libobjs=\"\$libobjs $whole_archive_flag_spec\" - test "X$libobjs" = "X " && libobjs= - fi - # Expand the library linking commands again to reset the - # value of $libobjs for piecewise linking. + eval cmds=\"$old_archive_cmds\" - # Do each of the archive commands. - if test "$module" = yes && test -n "$module_cmds" ; then - if test -n "$export_symbols" && test -n "$module_expsym_cmds"; then - cmds=$module_expsym_cmds + if len=`expr "X$cmds" : ".*"` && + test "$len" -le "$max_cmd_len" || test "$max_cmd_len" -le -1; then + cmds=$old_archive_cmds + else + # the command line is too long to link in one step, link in parts + $echo "using piecewise archive linking..." + save_RANLIB=$RANLIB + RANLIB=: + objlist= + concat_cmds= + save_oldobjs=$oldobjs + + # Is there a better way of finding the last object in the list? + for obj in $save_oldobjs + do + last_oldobj=$obj + done + for obj in $save_oldobjs + do + oldobjs="$objlist $obj" + objlist="$objlist $obj" + eval test_cmds=\"$old_archive_cmds\" + if len=`expr "X$test_cmds" : ".*" 2>/dev/null` && + test "$len" -le "$max_cmd_len"; then + : else - cmds=$module_cmds + # the above command should be used before it gets too long + oldobjs=$objlist + if test "$obj" = "$last_oldobj" ; then + RANLIB=$save_RANLIB + fi + test -z "$concat_cmds" || concat_cmds=$concat_cmds~ + eval concat_cmds=\"\${concat_cmds}$old_archive_cmds\" + objlist= fi + done + RANLIB=$save_RANLIB + oldobjs=$objlist + if test "X$oldobjs" = "X" ; then + eval cmds=\"\$concat_cmds\" else - if test -n "$export_symbols" && test -n "$archive_expsym_cmds"; then - cmds=$archive_expsym_cmds - else - cmds=$archive_cmds - fi + eval cmds=\"\$concat_cmds~\$old_archive_cmds\" fi fi - - if test -n "$delfiles"; then - # Append the command to remove temporary files to $cmds. - eval cmds=\"\$cmds~\$RM $delfiles\" - fi - - # Add any objects from preloaded convenience libraries - if test -n "$dlprefiles"; then - gentop="$output_objdir/${outputname}x" - generated="$generated $gentop" - - func_extract_archives $gentop $dlprefiles - libobjs="$libobjs $func_extract_archives_result" - test "X$libobjs" = "X " && libobjs= - fi - - save_ifs="$IFS"; IFS='~' - for cmd in $cmds; do - IFS="$save_ifs" - eval cmd=\"$cmd\" - $opt_silent || { - func_quote_for_expand "$cmd" - eval "func_echo $func_quote_for_expand_result" - } - $opt_dry_run || eval "$cmd" || { - lt_exit=$? - - # Restore the uninstalled library and exit - if test "$mode" = relink; then - ( cd "$output_objdir" && \ - $RM "${realname}T" && \ - $MV "${realname}U" "$realname" ) - fi - - exit $lt_exit - } - done + fi + save_ifs="$IFS"; IFS='~' + for cmd in $cmds; do + eval cmd=\"$cmd\" IFS="$save_ifs" + $show "$cmd" + $run eval "$cmd" || exit $? + done + IFS="$save_ifs" + done - # Restore the uninstalled library and exit - if test "$mode" = relink; then - $opt_dry_run || eval '(cd $output_objdir && $RM ${realname}T && $MV $realname ${realname}T && $MV ${realname}U $realname)' || exit $? - - if test -n "$convenience"; then - if test -z "$whole_archive_flag_spec"; then - func_show_eval '${RM}r "$gentop"' - fi - fi - - exit $EXIT_SUCCESS - fi + if test -n "$generated"; then + $show "${rm}r$generated" + $run ${rm}r$generated + fi - # Create links to the real library. - for linkname in $linknames; do - if test "$realname" != "$linkname"; then - func_show_eval '(cd "$output_objdir" && $RM "$linkname" && $LN_S "$realname" "$linkname")' 'exit $?' - fi - done + # Now create the libtool archive. + case $output in + *.la) + old_library= + test "$build_old_libs" = yes && old_library="$libname.$libext" + $show "creating $output" - # If -module or -export-dynamic was specified, set the dlname. - if test "$module" = yes || test "$export_dynamic" = yes; then - # On all known operating systems, these are identical. - dlname="$soname" + # Preserve any variables that may affect compiler behavior + for var in $variables_saved_for_relink; do + if eval test -z \"\${$var+set}\"; then + relink_command="{ test -z \"\${$var+set}\" || unset $var || { $var=; export $var; }; }; $relink_command" + elif eval var_value=\$$var; test -z "$var_value"; then + relink_command="$var=; export $var; $relink_command" + else + var_value=`$echo "X$var_value" | $Xsed -e "$sed_quote_subst"` + relink_command="$var=\"$var_value\"; export $var; $relink_command" fi + done + # Quote the link command for shipping. + relink_command="(cd `pwd`; $SHELL $progpath $preserve_args --mode=relink $libtool_args @inst_prefix_dir@)" + relink_command=`$echo "X$relink_command" | $SP2NL | $Xsed -e "$sed_quote_subst" | $NL2SP` + if test "$hardcode_automatic" = yes ; then + relink_command= fi - ;; - - obj) - if test -n "$dlfiles$dlprefiles" || test "$dlself" != no; then - func_warning "\`-dlopen' is ignored for objects" - fi - - case " $deplibs" in - *\ -l* | *\ -L*) - func_warning "\`-l' and \`-L' are ignored for objects" ;; - esac - - test -n "$rpath" && \ - func_warning "\`-rpath' is ignored for objects" - - test -n "$xrpath" && \ - func_warning "\`-R' is ignored for objects" - - test -n "$vinfo" && \ - func_warning "\`-version-info' is ignored for objects" - - test -n "$release" && \ - func_warning "\`-release' is ignored for objects" - - case $output in - *.lo) - test -n "$objs$old_deplibs" && \ - func_fatal_error "cannot build library object \`$output' from non-libtool objects" - - libobj=$output - func_lo2o "$libobj" - obj=$func_lo2o_result - ;; - *) - libobj= - obj="$output" - ;; - esac - - # Delete the old objects. - $opt_dry_run || $RM $obj $libobj - # Objects from convenience libraries. This assumes - # single-version convenience libraries. Whenever we create - # different ones for PIC/non-PIC, this we'll have to duplicate - # the extraction. - reload_conv_objs= - gentop= - # reload_cmds runs $LD directly, so let us get rid of - # -Wl from whole_archive_flag_spec and hope we can get by with - # turning comma into space.. - wl= - if test -n "$convenience"; then - if test -n "$whole_archive_flag_spec"; then - eval tmp_whole_archive_flags=\"$whole_archive_flag_spec\" - reload_conv_objs=$reload_objs\ `$ECHO "X$tmp_whole_archive_flags" | $Xsed -e 's|,| |g'` - else - gentop="$output_objdir/${obj}x" - generated="$generated $gentop" + # Only create the output if not a dry run. + if test -z "$run"; then + for installed in no yes; do + if test "$installed" = yes; then + if test -z "$install_libdir"; then + break + fi + output="$output_objdir/$outputname"i + # Replace all uninstalled libtool libraries with the installed ones + newdependency_libs= + for deplib in $dependency_libs; do + case $deplib in + *.la) + name=`$echo "X$deplib" | $Xsed -e 's%^.*/%%'` + eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $deplib` + if test -z "$libdir"; then + $echo "$modename: \`$deplib' is not a valid libtool archive" 1>&2 + exit $EXIT_FAILURE + fi + newdependency_libs="$newdependency_libs $libdir/$name" + ;; + *) newdependency_libs="$newdependency_libs $deplib" ;; + esac + done + dependency_libs="$newdependency_libs" + newdlfiles= + for lib in $dlfiles; do + name=`$echo "X$lib" | $Xsed -e 's%^.*/%%'` + eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $lib` + if test -z "$libdir"; then + $echo "$modename: \`$lib' is not a valid libtool archive" 1>&2 + exit $EXIT_FAILURE + fi + newdlfiles="$newdlfiles $libdir/$name" + done + dlfiles="$newdlfiles" + newdlprefiles= + for lib in $dlprefiles; do + name=`$echo "X$lib" | $Xsed -e 's%^.*/%%'` + eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $lib` + if test -z "$libdir"; then + $echo "$modename: \`$lib' is not a valid libtool archive" 1>&2 + exit $EXIT_FAILURE + fi + newdlprefiles="$newdlprefiles $libdir/$name" + done + dlprefiles="$newdlprefiles" + else + newdlfiles= + for lib in $dlfiles; do + case $lib in + [\\/]* | [A-Za-z]:[\\/]*) abs="$lib" ;; + *) abs=`pwd`"/$lib" ;; + esac + newdlfiles="$newdlfiles $abs" + done + dlfiles="$newdlfiles" + newdlprefiles= + for lib in $dlprefiles; do + case $lib in + [\\/]* | [A-Za-z]:[\\/]*) abs="$lib" ;; + *) abs=`pwd`"/$lib" ;; + esac + newdlprefiles="$newdlprefiles $abs" + done + dlprefiles="$newdlprefiles" + fi + $rm $output + # place dlname in correct position for cygwin + tdlname=$dlname + case $host,$output,$installed,$module,$dlname in + *cygwin*,*lai,yes,no,*.dll | *mingw*,*lai,yes,no,*.dll) tdlname=../bin/$dlname ;; + esac + $echo > $output "\ +# $outputname - a libtool library file +# Generated by $PROGRAM - GNU $PACKAGE $VERSION$TIMESTAMP +# +# Please DO NOT delete this file! +# It is necessary for linking the library. - func_extract_archives $gentop $convenience - reload_conv_objs="$reload_objs $func_extract_archives_result" - fi - fi +# The name that we can dlopen(3). +dlname='$tdlname' - # Create the old-style object. - reload_objs="$objs$old_deplibs "`$ECHO "X$libobjs" | $SP2NL | $Xsed -e '/\.'${libext}$'/d' -e '/\.lib$/d' -e "$lo2o" | $NL2SP`" $reload_conv_objs" ### testsuite: skip nested quoting test +# Names of this library. +library_names='$library_names' - output="$obj" - func_execute_cmds "$reload_cmds" 'exit $?' +# The name of the static archive. +old_library='$old_library' - # Exit if we aren't doing a library object file. - if test -z "$libobj"; then - if test -n "$gentop"; then - func_show_eval '${RM}r "$gentop"' - fi +# Libraries that this one depends upon. +dependency_libs='$dependency_libs' - exit $EXIT_SUCCESS - fi +# Version information for $libname. +current=$current +age=$age +revision=$revision - if test "$build_libtool_libs" != yes; then - if test -n "$gentop"; then - func_show_eval '${RM}r "$gentop"' - fi +# Is this an already installed library? +installed=$installed - # Create an invalid libtool object if no PIC, so that we don't - # accidentally link it into a program. - # $show "echo timestamp > $libobj" - # $opt_dry_run || eval "echo timestamp > $libobj" || exit $? - exit $EXIT_SUCCESS - fi +# Should we warn about portability when linking against -modules? +shouldnotlink=$module - if test -n "$pic_flag" || test "$pic_mode" != default; then - # Only do commands if we really have different PIC objects. - reload_objs="$libobjs $reload_conv_objs" - output="$libobj" - func_execute_cmds "$reload_cmds" 'exit $?' - fi +# Files to dlopen/dlpreopen +dlopen='$dlfiles' +dlpreopen='$dlprefiles' - if test -n "$gentop"; then - func_show_eval '${RM}r "$gentop"' +# Directory that this library needs to be installed in: +libdir='$install_libdir'" + if test "$installed" = no && test "$need_relink" = yes; then + $echo >> $output "\ +relink_command=\"$relink_command\"" + fi + done fi - exit $EXIT_SUCCESS + # Do a symbolic link so that the libtool archive can be found in + # LD_LIBRARY_PATH before the program is installed. + $show "(cd $output_objdir && $rm $outputname && $LN_S ../$outputname $outputname)" + $run eval '(cd $output_objdir && $rm $outputname && $LN_S ../$outputname $outputname)' || exit $? ;; + esac + exit $EXIT_SUCCESS + ;; - prog) - case $host in - *cygwin*) func_stripname '' '.exe' "$output" - output=$func_stripname_result.exe;; + # libtool install mode + install) + modename="$modename: install" + + # There may be an optional sh(1) argument at the beginning of + # install_prog (especially on Windows NT). + if test "$nonopt" = "$SHELL" || test "$nonopt" = /bin/sh || + # Allow the use of GNU shtool's install command. + $echo "X$nonopt" | grep shtool > /dev/null; then + # Aesthetically quote it. + arg=`$echo "X$nonopt" | $Xsed -e "$sed_quote_subst"` + case $arg in + *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") + arg="\"$arg\"" + ;; esac - test -n "$vinfo" && \ - func_warning "\`-version-info' is ignored for programs" + install_prog="$arg " + arg="$1" + shift + else + install_prog= + arg=$nonopt + fi - test -n "$release" && \ - func_warning "\`-release' is ignored for programs" + # The real first argument should be the name of the installation program. + # Aesthetically quote it. + arg=`$echo "X$arg" | $Xsed -e "$sed_quote_subst"` + case $arg in + *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") + arg="\"$arg\"" + ;; + esac + install_prog="$install_prog$arg" - test "$preload" = yes \ - && test "$dlopen_support" = unknown \ - && test "$dlopen_self" = unknown \ - && test "$dlopen_self_static" = unknown && \ - func_warning "\`LT_INIT([dlopen])' not used. Assuming no dlopen support." + # We need to accept at least all the BSD install flags. + dest= + files= + opts= + prev= + install_type= + isdir=no + stripme= + for arg + do + if test -n "$dest"; then + files="$files $dest" + dest=$arg + continue + fi - case $host in - *-*-rhapsody* | *-*-darwin1.[012]) - # On Rhapsody replace the C library is the System framework - compile_deplibs=`$ECHO "X $compile_deplibs" | $Xsed -e 's/ -lc / System.ltframework /'` - finalize_deplibs=`$ECHO "X $finalize_deplibs" | $Xsed -e 's/ -lc / System.ltframework /'` + case $arg in + -d) isdir=yes ;; + -f) + case " $install_prog " in + *[\\\ /]cp\ *) ;; + *) prev=$arg ;; + esac + ;; + -g | -m | -o) prev=$arg ;; + -s) + stripme=" -s" + continue + ;; + -*) + ;; + *) + # If the previous option needed an argument, then skip it. + if test -n "$prev"; then + prev= + else + dest=$arg + continue + fi ;; esac - case $host in - *-*-darwin*) - # Don't allow lazy linking, it breaks C++ global constructors - # But is supposedly fixed on 10.4 or later (yay!). - if test "$tagname" = CXX ; then - case ${MACOSX_DEPLOYMENT_TARGET-10.0} in - 10.[0123]) - compile_command="$compile_command ${wl}-bind_at_load" - finalize_command="$finalize_command ${wl}-bind_at_load" - ;; - esac - fi - # Time to change all our "foo.ltframework" stuff back to "-framework foo" - compile_deplibs=`$ECHO "X $compile_deplibs" | $Xsed -e 's% \([^ $]*\).ltframework% -framework \1%g'` - finalize_deplibs=`$ECHO "X $finalize_deplibs" | $Xsed -e 's% \([^ $]*\).ltframework% -framework \1%g'` + # Aesthetically quote the argument. + arg=`$echo "X$arg" | $Xsed -e "$sed_quote_subst"` + case $arg in + *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") + arg="\"$arg\"" ;; esac + install_prog="$install_prog $arg" + done + if test -z "$install_prog"; then + $echo "$modename: you must specify an install program" 1>&2 + $echo "$help" 1>&2 + exit $EXIT_FAILURE + fi - # move library search paths that coincide with paths to not yet - # installed libraries to the beginning of the library search list - new_libs= - for path in $notinst_path; do - case " $new_libs " in - *" -L$path/$objdir "*) ;; + if test -n "$prev"; then + $echo "$modename: the \`$prev' option requires an argument" 1>&2 + $echo "$help" 1>&2 + exit $EXIT_FAILURE + fi + + if test -z "$files"; then + if test -z "$dest"; then + $echo "$modename: no file or destination specified" 1>&2 + else + $echo "$modename: you must specify a destination" 1>&2 + fi + $echo "$help" 1>&2 + exit $EXIT_FAILURE + fi + + # Strip any trailing slash from the destination. + dest=`$echo "X$dest" | $Xsed -e 's%/$%%'` + + # Check to see that the destination is a directory. + test -d "$dest" && isdir=yes + if test "$isdir" = yes; then + destdir="$dest" + destname= + else + destdir=`$echo "X$dest" | $Xsed -e 's%/[^/]*$%%'` + test "X$destdir" = "X$dest" && destdir=. + destname=`$echo "X$dest" | $Xsed -e 's%^.*/%%'` + + # Not a directory, so check to see that there is only one file specified. + set dummy $files + if test "$#" -gt 2; then + $echo "$modename: \`$dest' is not a directory" 1>&2 + $echo "$help" 1>&2 + exit $EXIT_FAILURE + fi + fi + case $destdir in + [\\/]* | [A-Za-z]:[\\/]*) ;; + *) + for file in $files; do + case $file in + *.lo) ;; *) - case " $compile_deplibs " in - *" -L$path/$objdir "*) - new_libs="$new_libs -L$path/$objdir" ;; - esac - ;; - esac - done - for deplib in $compile_deplibs; do - case $deplib in - -L*) - case " $new_libs " in - *" $deplib "*) ;; - *) new_libs="$new_libs $deplib" ;; - esac + $echo "$modename: \`$destdir' must be an absolute directory name" 1>&2 + $echo "$help" 1>&2 + exit $EXIT_FAILURE ;; - *) new_libs="$new_libs $deplib" ;; esac done - compile_deplibs="$new_libs" + ;; + esac + # This variable tells wrapper scripts just to set variables rather + # than running their programs. + libtool_install_magic="$magic" - compile_command="$compile_command $compile_deplibs" - finalize_command="$finalize_command $finalize_deplibs" + staticlibs= + future_libdirs= + current_libdirs= + for file in $files; do - if test -n "$rpath$xrpath"; then - # If the user specified any rpath flags, then add them. - for libdir in $rpath $xrpath; do - # This is the magic to use -rpath. - case "$finalize_rpath " in + # Do each installation. + case $file in + *.$libext) + # Do the static libraries later. + staticlibs="$staticlibs $file" + ;; + + *.la) + # Check to see that this really is a libtool archive. + if (${SED} -e '2q' $file | grep "^# Generated by .*$PACKAGE") >/dev/null 2>&1; then : + else + $echo "$modename: \`$file' is not a valid libtool archive" 1>&2 + $echo "$help" 1>&2 + exit $EXIT_FAILURE + fi + + library_names= + old_library= + relink_command= + # If there is no directory component, then add one. + case $file in + */* | *\\*) . $file ;; + *) . ./$file ;; + esac + + # Add the libdir to current_libdirs if it is the destination. + if test "X$destdir" = "X$libdir"; then + case "$current_libdirs " in *" $libdir "*) ;; - *) finalize_rpath="$finalize_rpath $libdir" ;; + *) current_libdirs="$current_libdirs $libdir" ;; esac - done - fi - - # Now hardcode the library paths - rpath= - hardcode_libdirs= - for libdir in $compile_rpath $finalize_rpath; do - if test -n "$hardcode_libdir_flag_spec"; then - if test -n "$hardcode_libdir_separator"; then - if test -z "$hardcode_libdirs"; then - hardcode_libdirs="$libdir" - else - # Just accumulate the unique libdirs. - case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in - *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) - ;; - *) - hardcode_libdirs="$hardcode_libdirs$hardcode_libdir_separator$libdir" - ;; - esac - fi - else - eval flag=\"$hardcode_libdir_flag_spec\" - rpath="$rpath $flag" - fi - elif test -n "$runpath_var"; then - case "$perm_rpath " in + else + # Note the libdir as a future libdir. + case "$future_libdirs " in *" $libdir "*) ;; - *) perm_rpath="$perm_rpath $libdir" ;; + *) future_libdirs="$future_libdirs $libdir" ;; esac fi - case $host in - *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-cegcc*) - testbindir=`${ECHO} "$libdir" | ${SED} -e 's*/lib$*/bin*'` - case :$dllsearchpath: in - *":$libdir:"*) ;; - ::) dllsearchpath=$libdir;; - *) dllsearchpath="$dllsearchpath:$libdir";; - esac - case :$dllsearchpath: in - *":$testbindir:"*) ;; - ::) dllsearchpath=$testbindir;; - *) dllsearchpath="$dllsearchpath:$testbindir";; - esac - ;; - esac - done - # Substitute the hardcoded libdirs into the rpath. - if test -n "$hardcode_libdir_separator" && - test -n "$hardcode_libdirs"; then - libdir="$hardcode_libdirs" - eval rpath=\" $hardcode_libdir_flag_spec\" - fi - compile_rpath="$rpath" - rpath= - hardcode_libdirs= - for libdir in $finalize_rpath; do - if test -n "$hardcode_libdir_flag_spec"; then - if test -n "$hardcode_libdir_separator"; then - if test -z "$hardcode_libdirs"; then - hardcode_libdirs="$libdir" - else - # Just accumulate the unique libdirs. - case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in - *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) - ;; - *) - hardcode_libdirs="$hardcode_libdirs$hardcode_libdir_separator$libdir" - ;; - esac - fi + dir=`$echo "X$file" | $Xsed -e 's%/[^/]*$%%'`/ + test "X$dir" = "X$file/" && dir= + dir="$dir$objdir" + + if test -n "$relink_command"; then + # Determine the prefix the user has applied to our future dir. + inst_prefix_dir=`$echo "$destdir" | $SED "s%$libdir\$%%"` + + # Don't allow the user to place us outside of our expected + # location b/c this prevents finding dependent libraries that + # are installed to the same prefix. + # At present, this check doesn't affect windows .dll's that + # are installed into $libdir/../bin (currently, that works fine) + # but it's something to keep an eye on. + if test "$inst_prefix_dir" = "$destdir"; then + $echo "$modename: error: cannot install \`$file' to a directory not ending in $libdir" 1>&2 + exit $EXIT_FAILURE + fi + + if test -n "$inst_prefix_dir"; then + # Stick the inst_prefix_dir data into the link command. + relink_command=`$echo "$relink_command" | $SP2NL | $SED "s%@inst_prefix_dir@%-inst-prefix-dir $inst_prefix_dir%" | $NL2SP` + else + relink_command=`$echo "$relink_command" | $SP2NL | $SED "s%@inst_prefix_dir@%%" | $NL2SP` + fi + + $echo "$modename: warning: relinking \`$file'" 1>&2 + $show "$relink_command" + if $run eval "$relink_command"; then : else - eval flag=\"$hardcode_libdir_flag_spec\" - rpath="$rpath $flag" + $echo "$modename: error: relink \`$file' with the above command before installing it" 1>&2 + exit $EXIT_FAILURE fi - elif test -n "$runpath_var"; then - case "$finalize_perm_rpath " in - *" $libdir "*) ;; - *) finalize_perm_rpath="$finalize_perm_rpath $libdir" ;; - esac fi - done - # Substitute the hardcoded libdirs into the rpath. - if test -n "$hardcode_libdir_separator" && - test -n "$hardcode_libdirs"; then - libdir="$hardcode_libdirs" - eval rpath=\" $hardcode_libdir_flag_spec\" - fi - finalize_rpath="$rpath" - if test -n "$libobjs" && test "$build_old_libs" = yes; then - # Transform all the library objects into standard objects. - compile_command=`$ECHO "X$compile_command" | $SP2NL | $Xsed -e "$lo2o" | $NL2SP` - finalize_command=`$ECHO "X$finalize_command" | $SP2NL | $Xsed -e "$lo2o" | $NL2SP` - fi + # See the names of the shared library. + set dummy $library_names + if test -n "$2"; then + realname="$2" + shift + shift - func_generate_dlsyms "$outputname" "@PROGRAM@" "no" + srcname="$realname" + test -n "$relink_command" && srcname="$realname"T - # template prelinking step - if test -n "$prelink_cmds"; then - func_execute_cmds "$prelink_cmds" 'exit $?' - fi + # Install the shared library and build the symlinks. + $show "$install_prog $dir/$srcname $destdir/$realname" + $run eval "$install_prog $dir/$srcname $destdir/$realname" || exit $? + if test -n "$stripme" && test -n "$striplib"; then + $show "$striplib $destdir/$realname" + $run eval "$striplib $destdir/$realname" || exit $? + fi - wrappers_required=yes - case $host in - *cygwin* | *mingw* ) - if test "$build_libtool_libs" != yes; then - wrappers_required=no - fi - ;; - *cegcc) - # Disable wrappers for cegcc, we are cross compiling anyway. - wrappers_required=no - ;; - *) - if test "$need_relink" = no || test "$build_libtool_libs" != yes; then - wrappers_required=no - fi - ;; - esac - if test "$wrappers_required" = no; then - # Replace the output file specification. - compile_command=`$ECHO "X$compile_command" | $Xsed -e 's%@OUTPUT@%'"$output"'%g'` - link_command="$compile_command$compile_rpath" + if test "$#" -gt 0; then + # Delete the old symlinks, and create new ones. + # Try `ln -sf' first, because the `ln' binary might depend on + # the symlink we replace! Solaris /bin/ln does not understand -f, + # so we also need to try rm && ln -s. + for linkname + do + if test "$linkname" != "$realname"; then + $show "(cd $destdir && { $LN_S -f $realname $linkname || { $rm $linkname && $LN_S $realname $linkname; }; })" + $run eval "(cd $destdir && { $LN_S -f $realname $linkname || { $rm $linkname && $LN_S $realname $linkname; }; })" + fi + done + fi - # We have no uninstalled library dependencies, so finalize right now. - exit_status=0 - func_show_eval "$link_command" 'exit_status=$?' + # Do each command in the postinstall commands. + lib="$destdir/$realname" + cmds=$postinstall_cmds + save_ifs="$IFS"; IFS='~' + for cmd in $cmds; do + IFS="$save_ifs" + eval cmd=\"$cmd\" + $show "$cmd" + $run eval "$cmd" || { + lt_exit=$? + + # Restore the uninstalled library and exit + if test "$mode" = relink; then + $run eval '(cd $output_objdir && $rm ${realname}T && $mv ${realname}U $realname)' + fi - # Delete the generated files. - if test -f "$output_objdir/${outputname}S.${objext}"; then - func_show_eval '$RM "$output_objdir/${outputname}S.${objext}"' + exit $lt_exit + } + done + IFS="$save_ifs" fi - exit $exit_status - fi + # Install the pseudo-library for information purposes. + name=`$echo "X$file" | $Xsed -e 's%^.*/%%'` + instname="$dir/$name"i + $show "$install_prog $instname $destdir/$name" + $run eval "$install_prog $instname $destdir/$name" || exit $? - if test -n "$compile_shlibpath$finalize_shlibpath"; then - compile_command="$shlibpath_var=\"$compile_shlibpath$finalize_shlibpath\$$shlibpath_var\" $compile_command" - fi - if test -n "$finalize_shlibpath"; then - finalize_command="$shlibpath_var=\"$finalize_shlibpath\$$shlibpath_var\" $finalize_command" - fi + # Maybe install the static library, too. + test -n "$old_library" && staticlibs="$staticlibs $dir/$old_library" + ;; - compile_var= - finalize_var= - if test -n "$runpath_var"; then - if test -n "$perm_rpath"; then - # We should set the runpath_var. - rpath= - for dir in $perm_rpath; do - rpath="$rpath$dir:" - done - compile_var="$runpath_var=\"$rpath\$$runpath_var\" " + *.lo) + # Install (i.e. copy) a libtool object. + + # Figure out destination file name, if it wasn't already specified. + if test -n "$destname"; then + destfile="$destdir/$destname" + else + destfile=`$echo "X$file" | $Xsed -e 's%^.*/%%'` + destfile="$destdir/$destfile" fi - if test -n "$finalize_perm_rpath"; then - # We should set the runpath_var. - rpath= - for dir in $finalize_perm_rpath; do - rpath="$rpath$dir:" - done - finalize_var="$runpath_var=\"$rpath\$$runpath_var\" " + + # Deduce the name of the destination old-style object file. + case $destfile in + *.lo) + staticdest=`$echo "X$destfile" | $Xsed -e "$lo2o"` + ;; + *.$objext) + staticdest="$destfile" + destfile= + ;; + *) + $echo "$modename: cannot copy a libtool object to \`$destfile'" 1>&2 + $echo "$help" 1>&2 + exit $EXIT_FAILURE + ;; + esac + + # Install the libtool object if requested. + if test -n "$destfile"; then + $show "$install_prog $file $destfile" + $run eval "$install_prog $file $destfile" || exit $? fi - fi - if test "$no_install" = yes; then - # We don't need to create a wrapper script. - link_command="$compile_var$compile_command$compile_rpath" - # Replace the output file specification. - link_command=`$ECHO "X$link_command" | $Xsed -e 's%@OUTPUT@%'"$output"'%g'` - # Delete the old output file. - $opt_dry_run || $RM $output - # Link the executable and exit - func_show_eval "$link_command" 'exit $?' - exit $EXIT_SUCCESS - fi + # Install the old object if enabled. + if test "$build_old_libs" = yes; then + # Deduce the name of the old-style object file. + staticobj=`$echo "X$file" | $Xsed -e "$lo2o"` - if test "$hardcode_action" = relink; then - # Fast installation is not supported - link_command="$compile_var$compile_command$compile_rpath" - relink_command="$finalize_var$finalize_command$finalize_rpath" + $show "$install_prog $staticobj $staticdest" + $run eval "$install_prog \$staticobj \$staticdest" || exit $? + fi + exit $EXIT_SUCCESS + ;; - func_warning "this platform does not like uninstalled shared libraries" - func_warning "\`$output' will be relinked during installation" - else - if test "$fast_install" != no; then - link_command="$finalize_var$compile_command$finalize_rpath" - if test "$fast_install" = yes; then - relink_command=`$ECHO "X$compile_var$compile_command$compile_rpath" | $Xsed -e 's%@OUTPUT@%\$progdir/\$file%g'` - else - # fast_install is set to needless - relink_command= - fi + *) + # Figure out destination file name, if it wasn't already specified. + if test -n "$destname"; then + destfile="$destdir/$destname" else - link_command="$compile_var$compile_command$compile_rpath" - relink_command="$finalize_var$finalize_command$finalize_rpath" + destfile=`$echo "X$file" | $Xsed -e 's%^.*/%%'` + destfile="$destdir/$destfile" fi - fi - # Replace the output file specification. - link_command=`$ECHO "X$link_command" | $Xsed -e 's%@OUTPUT@%'"$output_objdir/$outputname"'%g'` + # If the file is missing, and there is a .exe on the end, strip it + # because it is most likely a libtool script we actually want to + # install + stripped_ext="" + case $file in + *.exe) + if test ! -f "$file"; then + file=`$echo $file|${SED} 's,.exe$,,'` + stripped_ext=".exe" + fi + ;; + esac - # Delete the old output files. - $opt_dry_run || $RM $output $output_objdir/$outputname $output_objdir/lt-$outputname + # Do a test to see if this is really a libtool program. + case $host in + *cygwin*|*mingw*) + wrapper=`$echo $file | ${SED} -e 's,.exe$,,'` + ;; + *) + wrapper=$file + ;; + esac + if (${SED} -e '4q' $wrapper | grep "^# Generated by .*$PACKAGE")>/dev/null 2>&1; then + notinst_deplibs= + relink_command= - func_show_eval "$link_command" 'exit $?' + # Note that it is not necessary on cygwin/mingw to append a dot to + # foo even if both foo and FILE.exe exist: automatic-append-.exe + # behavior happens only for exec(3), not for open(2)! Also, sourcing + # `FILE.' does not work on cygwin managed mounts. + # + # If there is no directory component, then add one. + case $wrapper in + */* | *\\*) . ${wrapper} ;; + *) . ./${wrapper} ;; + esac - # Now create the wrapper script. - func_verbose "creating $output" + # Check the variables that should have been set. + if test -z "$notinst_deplibs"; then + $echo "$modename: invalid libtool wrapper script \`$wrapper'" 1>&2 + exit $EXIT_FAILURE + fi - # Quote the relink command for shipping. - if test -n "$relink_command"; then - # Preserve any variables that may affect compiler behavior - for var in $variables_saved_for_relink; do - if eval test -z \"\${$var+set}\"; then - relink_command="{ test -z \"\${$var+set}\" || $lt_unset $var || { $var=; export $var; }; }; $relink_command" - elif eval var_value=\$$var; test -z "$var_value"; then - relink_command="$var=; export $var; $relink_command" + finalize=yes + for lib in $notinst_deplibs; do + # Check to see that each library is installed. + libdir= + if test -f "$lib"; then + # If there is no directory component, then add one. + case $lib in + */* | *\\*) . $lib ;; + *) . ./$lib ;; + esac + fi + libfile="$libdir/"`$echo "X$lib" | $Xsed -e 's%^.*/%%g'` ### testsuite: skip nested quoting test + if test -n "$libdir" && test ! -f "$libfile"; then + $echo "$modename: warning: \`$lib' has not been installed in \`$libdir'" 1>&2 + finalize=no + fi + done + + relink_command= + # Note that it is not necessary on cygwin/mingw to append a dot to + # foo even if both foo and FILE.exe exist: automatic-append-.exe + # behavior happens only for exec(3), not for open(2)! Also, sourcing + # `FILE.' does not work on cygwin managed mounts. + # + # If there is no directory component, then add one. + case $wrapper in + */* | *\\*) . ${wrapper} ;; + *) . ./${wrapper} ;; + esac + + outputname= + if test "$fast_install" = no && test -n "$relink_command"; then + if test "$finalize" = yes && test -z "$run"; then + tmpdir=`func_mktempdir` + file=`$echo "X$file$stripped_ext" | $Xsed -e 's%^.*/%%'` + outputname="$tmpdir/$file" + # Replace the output file specification. + relink_command=`$echo "X$relink_command" | $SP2NL | $Xsed -e 's%@OUTPUT@%'"$outputname"'%g' | $NL2SP` + + $show "$relink_command" + if $run eval "$relink_command"; then : + else + $echo "$modename: error: relink \`$file' with the above command before installing it" 1>&2 + ${rm}r "$tmpdir" + continue + fi + file="$outputname" + else + $echo "$modename: warning: cannot relink \`$file'" 1>&2 + fi else - func_quote_for_eval "$var_value" - relink_command="$var=$func_quote_for_eval_result; export $var; $relink_command" + # Install the binary that we compiled earlier. + file=`$echo "X$file$stripped_ext" | $Xsed -e "s%\([^/]*\)$%$objdir/\1%"` fi - done - relink_command="(cd `pwd`; $relink_command)" - relink_command=`$ECHO "X$relink_command" | $Xsed -e "$sed_quote_subst"` - fi - - # Quote $ECHO for shipping. - if test "X$ECHO" = "X$SHELL $progpath --fallback-echo"; then - case $progpath in - [\\/]* | [A-Za-z]:[\\/]*) qecho="$SHELL $progpath --fallback-echo";; - *) qecho="$SHELL `pwd`/$progpath --fallback-echo";; - esac - qecho=`$ECHO "X$qecho" | $Xsed -e "$sed_quote_subst"` - else - qecho=`$ECHO "X$ECHO" | $Xsed -e "$sed_quote_subst"` - fi + fi - # Only actually do things if not in dry run mode. - $opt_dry_run || { - # win32 will think the script is a binary if it has - # a .exe suffix, so we strip it off here. - case $output in - *.exe) func_stripname '' '.exe' "$output" - output=$func_stripname_result ;; - esac - # test for cygwin because mv fails w/o .exe extensions - case $host in - *cygwin*) - exeext=.exe - func_stripname '' '.exe' "$outputname" - outputname=$func_stripname_result ;; - *) exeext= ;; + # remove .exe since cygwin /usr/bin/install will append another + # one anyway + case $install_prog,$host in + */usr/bin/install*,*cygwin*) + case $file:$destfile in + *.exe:*.exe) + # this is ok + ;; + *.exe:*) + destfile=$destfile.exe + ;; + *:*.exe) + destfile=`$echo $destfile | ${SED} -e 's,.exe$,,'` + ;; + esac + ;; esac - case $host in - *cygwin* | *mingw* ) - func_dirname_and_basename "$output" "" "." - output_name=$func_basename_result - output_path=$func_dirname_result - cwrappersource="$output_path/$objdir/lt-$output_name.c" - cwrapper="$output_path/$output_name.exe" - $RM $cwrappersource $cwrapper - trap "$RM $cwrappersource $cwrapper; exit $EXIT_FAILURE" 1 2 15 - - func_emit_cwrapperexe_src > $cwrappersource - - # The wrapper executable is built using the $host compiler, - # because it contains $host paths and files. If cross- - # compiling, it, like the target executable, must be - # executed on the $host or under an emulation environment. - $opt_dry_run || { - $LTCC $LTCFLAGS -o $cwrapper $cwrappersource - $STRIP $cwrapper - } + $show "$install_prog$stripme $file $destfile" + $run eval "$install_prog\$stripme \$file \$destfile" || exit $? + test -n "$outputname" && ${rm}r "$tmpdir" + ;; + esac + done - # Now, create the wrapper script for func_source use: - func_ltwrapper_scriptname $cwrapper - $RM $func_ltwrapper_scriptname_result - trap "$RM $func_ltwrapper_scriptname_result; exit $EXIT_FAILURE" 1 2 15 - $opt_dry_run || { - # note: this script will not be executed, so do not chmod. - if test "x$build" = "x$host" ; then - $cwrapper --lt-dump-script > $func_ltwrapper_scriptname_result - else - func_emit_wrapper no > $func_ltwrapper_scriptname_result - fi - } - ;; - * ) - $RM $output - trap "$RM $output; exit $EXIT_FAILURE" 1 2 15 + for file in $staticlibs; do + name=`$echo "X$file" | $Xsed -e 's%^.*/%%'` - func_emit_wrapper no > $output - chmod +x $output - ;; - esac - } - exit $EXIT_SUCCESS - ;; - esac + # Set up the ranlib parameters. + oldlib="$destdir/$name" - # See if we need to build an old-fashioned archive. - for oldlib in $oldlibs; do + $show "$install_prog $file $oldlib" + $run eval "$install_prog \$file \$oldlib" || exit $? - if test "$build_libtool_libs" = convenience; then - oldobjs="$libobjs_save $symfileobj" - addlibs="$convenience" - build_libtool_libs=no - else - if test "$build_libtool_libs" = module; then - oldobjs="$libobjs_save" - build_libtool_libs=no - else - oldobjs="$old_deplibs $non_pic_objects" - if test "$preload" = yes && test -f "$symfileobj"; then - oldobjs="$oldobjs $symfileobj" - fi - fi - addlibs="$old_convenience" + if test -n "$stripme" && test -n "$old_striplib"; then + $show "$old_striplib $oldlib" + $run eval "$old_striplib $oldlib" || exit $? fi - if test -n "$addlibs"; then - gentop="$output_objdir/${outputname}x" - generated="$generated $gentop" + # Do each command in the postinstall commands. + cmds=$old_postinstall_cmds + save_ifs="$IFS"; IFS='~' + for cmd in $cmds; do + IFS="$save_ifs" + eval cmd=\"$cmd\" + $show "$cmd" + $run eval "$cmd" || exit $? + done + IFS="$save_ifs" + done - func_extract_archives $gentop $addlibs - oldobjs="$oldobjs $func_extract_archives_result" - fi + if test -n "$future_libdirs"; then + $echo "$modename: warning: remember to run \`$progname --finish$future_libdirs'" 1>&2 + fi - # Do each command in the archive commands. - if test -n "$old_archive_from_new_cmds" && test "$build_libtool_libs" = yes; then - cmds=$old_archive_from_new_cmds - else + if test -n "$current_libdirs"; then + # Maybe just do a dry run. + test -n "$run" && current_libdirs=" -n$current_libdirs" + exec_cmd='$SHELL $progpath $preserve_args --finish$current_libdirs' + else + exit $EXIT_SUCCESS + fi + ;; - # Add any objects from preloaded convenience libraries - if test -n "$dlprefiles"; then - gentop="$output_objdir/${outputname}x" - generated="$generated $gentop" + # libtool finish mode + finish) + modename="$modename: finish" + libdirs="$nonopt" + admincmds= - func_extract_archives $gentop $dlprefiles - oldobjs="$oldobjs $func_extract_archives_result" - fi + if test -n "$finish_cmds$finish_eval" && test -n "$libdirs"; then + for dir + do + libdirs="$libdirs $dir" + done - # POSIX demands no paths to be encoded in archives. We have - # to avoid creating archives with duplicate basenames if we - # might have to extract them afterwards, e.g., when creating a - # static archive out of a convenience library, or when linking - # the entirety of a libtool archive into another (currently - # not supported by libtool). - if (for obj in $oldobjs - do - func_basename "$obj" - $ECHO "$func_basename_result" - done | sort | sort -uc >/dev/null 2>&1); then - : - else - $ECHO "copying selected object files to avoid basename conflicts..." - gentop="$output_objdir/${outputname}x" - generated="$generated $gentop" - func_mkdir_p "$gentop" - save_oldobjs=$oldobjs - oldobjs= - counter=1 - for obj in $save_oldobjs - do - func_basename "$obj" - objbase="$func_basename_result" - case " $oldobjs " in - " ") oldobjs=$obj ;; - *[\ /]"$objbase "*) - while :; do - # Make sure we don't pick an alternate name that also - # overlaps. - newobj=lt$counter-$objbase - func_arith $counter + 1 - counter=$func_arith_result - case " $oldobjs " in - *[\ /]"$newobj "*) ;; - *) if test ! -f "$gentop/$newobj"; then break; fi ;; - esac - done - func_show_eval "ln $obj $gentop/$newobj || cp $obj $gentop/$newobj" - oldobjs="$oldobjs $gentop/$newobj" - ;; - *) oldobjs="$oldobjs $obj" ;; - esac + for libdir in $libdirs; do + if test -n "$finish_cmds"; then + # Do each command in the finish commands. + cmds=$finish_cmds + save_ifs="$IFS"; IFS='~' + for cmd in $cmds; do + IFS="$save_ifs" + eval cmd=\"$cmd\" + $show "$cmd" + $run eval "$cmd" || admincmds="$admincmds + $cmd" done + IFS="$save_ifs" fi - eval cmds=\"$old_archive_cmds\" - - func_len " $cmds" - len=$func_len_result - if test "$len" -lt "$max_cmd_len" || test "$max_cmd_len" -le -1; then - cmds=$old_archive_cmds - else - # the command line is too long to link in one step, link in parts - func_verbose "using piecewise archive linking..." - save_RANLIB=$RANLIB - RANLIB=: - objlist= - concat_cmds= - save_oldobjs=$oldobjs - oldobjs= - # Is there a better way of finding the last object in the list? - for obj in $save_oldobjs - do - last_oldobj=$obj - done - eval test_cmds=\"$old_archive_cmds\" - func_len " $test_cmds" - len0=$func_len_result - len=$len0 - for obj in $save_oldobjs - do - func_len " $obj" - func_arith $len + $func_len_result - len=$func_arith_result - func_append objlist " $obj" - if test "$len" -lt "$max_cmd_len"; then - : - else - # the above command should be used before it gets too long - oldobjs=$objlist - if test "$obj" = "$last_oldobj" ; then - RANLIB=$save_RANLIB - fi - test -z "$concat_cmds" || concat_cmds=$concat_cmds~ - eval concat_cmds=\"\${concat_cmds}$old_archive_cmds\" - objlist= - len=$len0 - fi - done - RANLIB=$save_RANLIB - oldobjs=$objlist - if test "X$oldobjs" = "X" ; then - eval cmds=\"\$concat_cmds\" - else - eval cmds=\"\$concat_cmds~\$old_archive_cmds\" - fi + if test -n "$finish_eval"; then + # Do the single finish_eval. + eval cmds=\"$finish_eval\" + $run eval "$cmds" || admincmds="$admincmds + $cmds" fi - fi - func_execute_cmds "$cmds" 'exit $?' + done + fi + + # Exit here if they wanted silent mode. + test "$show" = : && exit $EXIT_SUCCESS + + $echo "X----------------------------------------------------------------------" | $Xsed + $echo "Libraries have been installed in:" + for libdir in $libdirs; do + $echo " $libdir" done + $echo + $echo "If you ever happen to want to link against installed libraries" + $echo "in a given directory, LIBDIR, you must either use libtool, and" + $echo "specify the full pathname of the library, or use the \`-LLIBDIR'" + $echo "flag during linking and do at least one of the following:" + if test -n "$shlibpath_var"; then + $echo " - add LIBDIR to the \`$shlibpath_var' environment variable" + $echo " during execution" + fi + if test -n "$runpath_var"; then + $echo " - add LIBDIR to the \`$runpath_var' environment variable" + $echo " during linking" + fi + if test -n "$hardcode_libdir_flag_spec"; then + libdir=LIBDIR + eval flag=\"$hardcode_libdir_flag_spec\" - test -n "$generated" && \ - func_show_eval "${RM}r$generated" + $echo " - use the \`$flag' linker flag" + fi + if test -n "$admincmds"; then + $echo " - have your system administrator run these commands:$admincmds" + fi + if test -f /etc/ld.so.conf; then + $echo " - have your system administrator add LIBDIR to \`/etc/ld.so.conf'" + fi + $echo + $echo "See any operating system documentation about shared libraries for" + $echo "more information, such as the ld(1) and ld.so(8) manual pages." + $echo "X----------------------------------------------------------------------" | $Xsed + exit $EXIT_SUCCESS + ;; - # Now create the libtool archive. - case $output in - *.la) - old_library= - test "$build_old_libs" = yes && old_library="$libname.$libext" - func_verbose "creating $output" + # libtool execute mode + execute) + modename="$modename: execute" - # Preserve any variables that may affect compiler behavior - for var in $variables_saved_for_relink; do - if eval test -z \"\${$var+set}\"; then - relink_command="{ test -z \"\${$var+set}\" || $lt_unset $var || { $var=; export $var; }; }; $relink_command" - elif eval var_value=\$$var; test -z "$var_value"; then - relink_command="$var=; export $var; $relink_command" - else - func_quote_for_eval "$var_value" - relink_command="$var=$func_quote_for_eval_result; export $var; $relink_command" - fi - done - # Quote the link command for shipping. - relink_command="(cd `pwd`; $SHELL $progpath $preserve_args --mode=relink $libtool_args @inst_prefix_dir@)" - relink_command=`$ECHO "X$relink_command" | $Xsed -e "$sed_quote_subst"` - if test "$hardcode_automatic" = yes ; then - relink_command= - fi + # The first argument is the command name. + cmd="$nonopt" + if test -z "$cmd"; then + $echo "$modename: you must specify a COMMAND" 1>&2 + $echo "$help" + exit $EXIT_FAILURE + fi - # Only create the output if not a dry run. - $opt_dry_run || { - for installed in no yes; do - if test "$installed" = yes; then - if test -z "$install_libdir"; then - break - fi - output="$output_objdir/$outputname"i - # Replace all uninstalled libtool libraries with the installed ones - newdependency_libs= - for deplib in $dependency_libs; do - case $deplib in - *.la) - func_basename "$deplib" - name="$func_basename_result" - eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $deplib` - test -z "$libdir" && \ - func_fatal_error "\`$deplib' is not a valid libtool archive" - newdependency_libs="$newdependency_libs $libdir/$name" - ;; - *) newdependency_libs="$newdependency_libs $deplib" ;; - esac - done - dependency_libs="$newdependency_libs" - newdlfiles= + # Handle -dlopen flags immediately. + for file in $execute_dlfiles; do + if test ! -f "$file"; then + $echo "$modename: \`$file' is not a file" 1>&2 + $echo "$help" 1>&2 + exit $EXIT_FAILURE + fi - for lib in $dlfiles; do - case $lib in - *.la) - func_basename "$lib" - name="$func_basename_result" - eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $lib` - test -z "$libdir" && \ - func_fatal_error "\`$lib' is not a valid libtool archive" - newdlfiles="$newdlfiles $libdir/$name" - ;; - *) newdlfiles="$newdlfiles $lib" ;; - esac - done - dlfiles="$newdlfiles" - newdlprefiles= - for lib in $dlprefiles; do - case $lib in - *.la) - # Only pass preopened files to the pseudo-archive (for - # eventual linking with the app. that links it) if we - # didn't already link the preopened objects directly into - # the library: - func_basename "$lib" - name="$func_basename_result" - eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $lib` - test -z "$libdir" && \ - func_fatal_error "\`$lib' is not a valid libtool archive" - newdlprefiles="$newdlprefiles $libdir/$name" - ;; - esac - done - dlprefiles="$newdlprefiles" - else - newdlfiles= - for lib in $dlfiles; do - case $lib in - [\\/]* | [A-Za-z]:[\\/]*) abs="$lib" ;; - *) abs=`pwd`"/$lib" ;; - esac - newdlfiles="$newdlfiles $abs" - done - dlfiles="$newdlfiles" - newdlprefiles= - for lib in $dlprefiles; do - case $lib in - [\\/]* | [A-Za-z]:[\\/]*) abs="$lib" ;; - *) abs=`pwd`"/$lib" ;; - esac - newdlprefiles="$newdlprefiles $abs" - done - dlprefiles="$newdlprefiles" - fi - $RM $output - # place dlname in correct position for cygwin - tdlname=$dlname - case $host,$output,$installed,$module,$dlname in - *cygwin*,*lai,yes,no,*.dll | *mingw*,*lai,yes,no,*.dll | *cegcc*,*lai,yes,no,*.dll) tdlname=../bin/$dlname ;; - esac - $ECHO > $output "\ -# $outputname - a libtool library file -# Generated by $PROGRAM (GNU $PACKAGE$TIMESTAMP) $VERSION -# -# Please DO NOT delete this file! -# It is necessary for linking the library. + dir= + case $file in + *.la) + # Check to see that this really is a libtool archive. + if (${SED} -e '2q' $file | grep "^# Generated by .*$PACKAGE") >/dev/null 2>&1; then : + else + $echo "$modename: \`$lib' is not a valid libtool archive" 1>&2 + $echo "$help" 1>&2 + exit $EXIT_FAILURE + fi -# The name that we can dlopen(3). -dlname='$tdlname' + # Read the libtool library. + dlname= + library_names= -# Names of this library. -library_names='$library_names' + # If there is no directory component, then add one. + case $file in + */* | *\\*) . $file ;; + *) . ./$file ;; + esac -# The name of the static archive. -old_library='$old_library' + # Skip this library if it cannot be dlopened. + if test -z "$dlname"; then + # Warn if it was a shared library. + test -n "$library_names" && $echo "$modename: warning: \`$file' was not linked with \`-export-dynamic'" + continue + fi -# Linker flags that can not go in dependency_libs. -inherited_linker_flags='$new_inherited_linker_flags' + dir=`$echo "X$file" | $Xsed -e 's%/[^/]*$%%'` + test "X$dir" = "X$file" && dir=. -# Libraries that this one depends upon. -dependency_libs='$dependency_libs' + if test -f "$dir/$objdir/$dlname"; then + dir="$dir/$objdir" + else + if test ! -f "$dir/$dlname"; then + $echo "$modename: cannot find \`$dlname' in \`$dir' or \`$dir/$objdir'" 1>&2 + exit $EXIT_FAILURE + fi + fi + ;; -# Names of additional weak libraries provided by this library -weak_library_names='$weak_libs' + *.lo) + # Just add the directory containing the .lo file. + dir=`$echo "X$file" | $Xsed -e 's%/[^/]*$%%'` + test "X$dir" = "X$file" && dir=. + ;; -# Version information for $libname. -current=$current -age=$age -revision=$revision + *) + $echo "$modename: warning \`-dlopen' is ignored for non-libtool libraries and objects" 1>&2 + continue + ;; + esac -# Is this an already installed library? -installed=$installed + # Get the absolute pathname. + absdir=`cd "$dir" && pwd` + test -n "$absdir" && dir="$absdir" -# Should we warn about portability when linking against -modules? -shouldnotlink=$module + # Now add the directory to shlibpath_var. + if eval "test -z \"\$$shlibpath_var\""; then + eval "$shlibpath_var=\"\$dir\"" + else + eval "$shlibpath_var=\"\$dir:\$$shlibpath_var\"" + fi + done -# Files to dlopen/dlpreopen -dlopen='$dlfiles' -dlpreopen='$dlprefiles' + # This variable tells wrapper scripts just to set shlibpath_var + # rather than running their programs. + libtool_execute_magic="$magic" -# Directory that this library needs to be installed in: -libdir='$install_libdir'" - if test "$installed" = no && test "$need_relink" = yes; then - $ECHO >> $output "\ -relink_command=\"$relink_command\"" - fi - done - } + # Check if any of the arguments is a wrapper script. + args= + for file + do + case $file in + -*) ;; + *) + # Do a test to see if this is really a libtool program. + if (${SED} -e '4q' $file | grep "^# Generated by .*$PACKAGE") >/dev/null 2>&1; then + # If there is no directory component, then add one. + case $file in + */* | *\\*) . $file ;; + *) . ./$file ;; + esac - # Do a symbolic link so that the libtool archive can be found in - # LD_LIBRARY_PATH before the program is installed. - func_show_eval '( cd "$output_objdir" && $RM "$outputname" && $LN_S "../$outputname" "$outputname" )' 'exit $?' - ;; - esac - exit $EXIT_SUCCESS -} + # Transform arg to wrapped name. + file="$progdir/$program" + fi + ;; + esac + # Quote arguments (to preserve shell metacharacters). + file=`$echo "X$file" | $Xsed -e "$sed_quote_subst"` + args="$args \"$file\"" + done -{ test "$mode" = link || test "$mode" = relink; } && - func_mode_link ${1+"$@"} + if test -z "$run"; then + if test -n "$shlibpath_var"; then + # Export the shlibpath_var. + eval "export $shlibpath_var" + fi + + # Restore saved environment variables + for lt_var in LANG LANGUAGE LC_ALL LC_CTYPE LC_COLLATE LC_MESSAGES + do + eval "if test \"\${save_$lt_var+set}\" = set; then + $lt_var=\$save_$lt_var; export $lt_var + fi" + done + # Now prepare to actually exec the command. + exec_cmd="\$cmd$args" + else + # Display what would be done. + if test -n "$shlibpath_var"; then + eval "\$echo \"\$shlibpath_var=\$$shlibpath_var\"" + $echo "export $shlibpath_var" + fi + $echo "$cmd$args" + exit $EXIT_SUCCESS + fi + ;; -# func_mode_uninstall arg... -func_mode_uninstall () -{ - $opt_debug - RM="$nonopt" + # libtool clean and uninstall mode + clean | uninstall) + modename="$modename: $mode" + rm="$nonopt" files= rmforce= exit_status=0 @@ -8202,28 +6539,30 @@ func_mode_uninstall () for arg do case $arg in - -f) RM="$RM $arg"; rmforce=yes ;; - -*) RM="$RM $arg" ;; + -f) rm="$rm $arg"; rmforce=yes ;; + -*) rm="$rm $arg" ;; *) files="$files $arg" ;; esac done - test -z "$RM" && \ - func_fatal_help "you must specify an RM program" + if test -z "$rm"; then + $echo "$modename: you must specify an RM program" 1>&2 + $echo "$help" 1>&2 + exit $EXIT_FAILURE + fi rmdirs= origobjdir="$objdir" for file in $files; do - func_dirname "$file" "" "." - dir="$func_dirname_result" - if test "X$dir" = X.; then + dir=`$echo "X$file" | $Xsed -e 's%/[^/]*$%%'` + if test "X$dir" = "X$file"; then + dir=. objdir="$origobjdir" else objdir="$dir/$origobjdir" fi - func_basename "$file" - name="$func_basename_result" + name=`$echo "X$file" | $Xsed -e 's%^.*/%%'` test "$mode" = uninstall && objdir="$dir" # Remember objdir for removal later, being careful to avoid duplicates @@ -8235,9 +6574,9 @@ func_mode_uninstall () fi # Don't error if the file doesn't exist and rm -f was used. - if { test -L "$file"; } >/dev/null 2>&1 || - { test -h "$file"; } >/dev/null 2>&1 || - test -f "$file"; then + if (test -L "$file") >/dev/null 2>&1 \ + || (test -h "$file") >/dev/null 2>&1 \ + || test -f "$file"; then : elif test -d "$file"; then exit_status=1 @@ -8251,8 +6590,8 @@ func_mode_uninstall () case $name in *.la) # Possibly a libtool archive, so verify it. - if func_lalib_p "$file"; then - func_source $dir/$name + if (${SED} -e '2q' $file | grep "^# Generated by .*$PACKAGE") >/dev/null 2>&1; then + . $dir/$name # Delete the libtool libraries and symlinks. for n in $library_names; do @@ -8267,17 +6606,39 @@ func_mode_uninstall () *" $dlname "*) ;; *) rmfiles="$rmfiles $objdir/$dlname" ;; esac - test -n "$libdir" && rmfiles="$rmfiles $objdir/$name $objdir/${name}i" + test -n "$libdir" && rmfiles="$rmfiles $objdir/$name $objdir/${name}i" ;; uninstall) if test -n "$library_names"; then # Do each command in the postuninstall commands. - func_execute_cmds "$postuninstall_cmds" 'test "$rmforce" = yes || exit_status=1' + cmds=$postuninstall_cmds + save_ifs="$IFS"; IFS='~' + for cmd in $cmds; do + IFS="$save_ifs" + eval cmd=\"$cmd\" + $show "$cmd" + $run eval "$cmd" + if test "$?" -ne 0 && test "$rmforce" != yes; then + exit_status=1 + fi + done + IFS="$save_ifs" fi if test -n "$old_library"; then # Do each command in the old_postuninstall commands. - func_execute_cmds "$old_postuninstall_cmds" 'test "$rmforce" = yes || exit_status=1' + cmds=$old_postuninstall_cmds + save_ifs="$IFS"; IFS='~' + for cmd in $cmds; do + IFS="$save_ifs" + eval cmd=\"$cmd\" + $show "$cmd" + $run eval "$cmd" + if test "$?" -ne 0 && test "$rmforce" != yes; then + exit_status=1 + fi + done + IFS="$save_ifs" fi # FIXME: should reinstall the best remaining shared library. ;; @@ -8287,20 +6648,20 @@ func_mode_uninstall () *.lo) # Possibly a libtool object, so verify it. - if func_lalib_p "$file"; then + if (${SED} -e '2q' $file | grep "^# Generated by .*$PACKAGE") >/dev/null 2>&1; then # Read the .lo file - func_source $dir/$name + . $dir/$name # Add PIC object to the list of files to remove. - if test -n "$pic_object" && - test "$pic_object" != none; then + if test -n "$pic_object" \ + && test "$pic_object" != none; then rmfiles="$rmfiles $dir/$pic_object" fi # Add non-PIC object to the list of files to remove. - if test -n "$non_pic_object" && - test "$non_pic_object" != none; then + if test -n "$non_pic_object" \ + && test "$non_pic_object" != none; then rmfiles="$rmfiles $dir/$non_pic_object" fi fi @@ -8311,26 +6672,17 @@ func_mode_uninstall () noexename=$name case $file in *.exe) - func_stripname '' '.exe' "$file" - file=$func_stripname_result - func_stripname '' '.exe' "$name" - noexename=$func_stripname_result + file=`$echo $file|${SED} 's,.exe$,,'` + noexename=`$echo $name|${SED} 's,.exe$,,'` # $file with .exe has already been added to rmfiles, # add $file without .exe rmfiles="$rmfiles $file" ;; esac # Do a test to see if this is a libtool program. - if func_ltwrapper_p "$file"; then - if func_ltwrapper_executable_p "$file"; then - func_ltwrapper_scriptname "$file" - relink_command= - func_source $func_ltwrapper_scriptname_result - rmfiles="$rmfiles $func_ltwrapper_scriptname_result" - else - relink_command= - func_source $dir/$noexename - fi + if (${SED} -e '4q' $file | grep "^# Generated by .*$PACKAGE") >/dev/null 2>&1; then + relink_command= + . $dir/$noexename # note $name still contains .exe if it was in $file originally # as does the version of $file that was added into $rmfiles @@ -8345,38 +6697,239 @@ func_mode_uninstall () fi ;; esac - func_show_eval "$RM $rmfiles" 'exit_status=1' + $show "$rm $rmfiles" + $run $rm $rmfiles || exit_status=1 done objdir="$origobjdir" # Try to remove the ${objdir}s in the directories where we deleted files for dir in $rmdirs; do if test -d "$dir"; then - func_show_eval "rmdir $dir >/dev/null 2>&1" + $show "rmdir $dir" + $run rmdir $dir >/dev/null 2>&1 fi done exit $exit_status -} - -{ test "$mode" = uninstall || test "$mode" = clean; } && - func_mode_uninstall ${1+"$@"} + ;; -test -z "$mode" && { - help="$generic_help" - func_fatal_help "you must specify a MODE" -} + "") + $echo "$modename: you must specify a MODE" 1>&2 + $echo "$generic_help" 1>&2 + exit $EXIT_FAILURE + ;; + esac -test -z "$exec_cmd" && \ - func_fatal_help "invalid operation mode \`$mode'" + if test -z "$exec_cmd"; then + $echo "$modename: invalid operation mode \`$mode'" 1>&2 + $echo "$generic_help" 1>&2 + exit $EXIT_FAILURE + fi +fi # test -z "$show_help" if test -n "$exec_cmd"; then - eval exec "$exec_cmd" + eval exec $exec_cmd exit $EXIT_FAILURE fi -exit $exit_status +# We need to display help for each of the modes. +case $mode in +"") $echo \ +"Usage: $modename [OPTION]... [MODE-ARG]... + +Provide generalized library-building support services. + + --config show all configuration variables + --debug enable verbose shell tracing +-n, --dry-run display commands without modifying any files + --features display basic configuration information and exit + --finish same as \`--mode=finish' + --help display this help message and exit + --mode=MODE use operation mode MODE [default=inferred from MODE-ARGS] + --quiet same as \`--silent' + --silent don't print informational messages + --tag=TAG use configuration variables from tag TAG + --version print version information + +MODE must be one of the following: + + clean remove files from the build directory + compile compile a source file into a libtool object + execute automatically set library path, then run a program + finish complete the installation of libtool libraries + install install libraries or executables + link create a library or an executable + uninstall remove libraries from an installed directory + +MODE-ARGS vary depending on the MODE. Try \`$modename --help --mode=MODE' for +a more detailed description of MODE. + +Report bugs to ." + exit $EXIT_SUCCESS + ;; + +clean) + $echo \ +"Usage: $modename [OPTION]... --mode=clean RM [RM-OPTION]... FILE... + +Remove files from the build directory. + +RM is the name of the program to use to delete files associated with each FILE +(typically \`/bin/rm'). RM-OPTIONS are options (such as \`-f') to be passed +to RM. + +If FILE is a libtool library, object or program, all the files associated +with it are deleted. Otherwise, only FILE itself is deleted using RM." + ;; + +compile) + $echo \ +"Usage: $modename [OPTION]... --mode=compile COMPILE-COMMAND... SOURCEFILE + +Compile a source file into a libtool library object. + +This mode accepts the following additional options: + + -o OUTPUT-FILE set the output file name to OUTPUT-FILE + -prefer-pic try to building PIC objects only + -prefer-non-pic try to building non-PIC objects only + -static always build a \`.o' file suitable for static linking + +COMPILE-COMMAND is a command to be used in creating a \`standard' object file +from the given SOURCEFILE. + +The output file name is determined by removing the directory component from +SOURCEFILE, then substituting the C source code suffix \`.c' with the +library object suffix, \`.lo'." + ;; + +execute) + $echo \ +"Usage: $modename [OPTION]... --mode=execute COMMAND [ARGS]... + +Automatically set library path, then run a program. + +This mode accepts the following additional options: + + -dlopen FILE add the directory containing FILE to the library path + +This mode sets the library path environment variable according to \`-dlopen' +flags. + +If any of the ARGS are libtool executable wrappers, then they are translated +into their corresponding uninstalled binary, and any of their required library +directories are added to the library path. + +Then, COMMAND is executed, with ARGS as arguments." + ;; + +finish) + $echo \ +"Usage: $modename [OPTION]... --mode=finish [LIBDIR]... + +Complete the installation of libtool libraries. + +Each LIBDIR is a directory that contains libtool libraries. + +The commands that this mode executes may require superuser privileges. Use +the \`--dry-run' option if you just want to see what would be executed." + ;; + +install) + $echo \ +"Usage: $modename [OPTION]... --mode=install INSTALL-COMMAND... + +Install executables or libraries. + +INSTALL-COMMAND is the installation command. The first component should be +either the \`install' or \`cp' program. + +The rest of the components are interpreted as arguments to that command (only +BSD-compatible install options are recognized)." + ;; + +link) + $echo \ +"Usage: $modename [OPTION]... --mode=link LINK-COMMAND... + +Link object files or libraries together to form another library, or to +create an executable program. +LINK-COMMAND is a command using the C compiler that you would use to create +a program from several object files. + +The following components of LINK-COMMAND are treated specially: + + -all-static do not do any dynamic linking at all + -avoid-version do not add a version suffix if possible + -dlopen FILE \`-dlpreopen' FILE if it cannot be dlopened at runtime + -dlpreopen FILE link in FILE and add its symbols to lt_preloaded_symbols + -export-dynamic allow symbols from OUTPUT-FILE to be resolved with dlsym(3) + -export-symbols SYMFILE + try to export only the symbols listed in SYMFILE + -export-symbols-regex REGEX + try to export only the symbols matching REGEX + -LLIBDIR search LIBDIR for required installed libraries + -lNAME OUTPUT-FILE requires the installed library libNAME + -module build a library that can dlopened + -no-fast-install disable the fast-install mode + -no-install link a not-installable executable + -no-undefined declare that a library does not refer to external symbols + -o OUTPUT-FILE create OUTPUT-FILE from the specified objects + -objectlist FILE Use a list of object files found in FILE to specify objects + -precious-files-regex REGEX + don't remove output files matching REGEX + -release RELEASE specify package release information + -rpath LIBDIR the created library will eventually be installed in LIBDIR + -R[ ]LIBDIR add LIBDIR to the runtime path of programs and libraries + -static do not do any dynamic linking of uninstalled libtool libraries + -static-libtool-libs + do not do any dynamic linking of libtool libraries + -version-info CURRENT[:REVISION[:AGE]] + specify library version info [each variable defaults to 0] + +All other options (arguments beginning with \`-') are ignored. + +Every other argument is treated as a filename. Files ending in \`.la' are +treated as uninstalled libtool libraries, other files are standard or library +object files. + +If the OUTPUT-FILE ends in \`.la', then a libtool library is created, +only library objects (\`.lo' files) may be specified, and \`-rpath' is +required, except when creating a convenience library. + +If OUTPUT-FILE ends in \`.a' or \`.lib', then a standard library is created +using \`ar' and \`ranlib', or on Windows using \`lib'. + +If OUTPUT-FILE ends in \`.lo' or \`.${objext}', then a reloadable object file +is created, otherwise an executable program is created." + ;; + +uninstall) + $echo \ +"Usage: $modename [OPTION]... --mode=uninstall RM [RM-OPTION]... FILE... + +Remove libraries from an installation directory. + +RM is the name of the program to use to delete files associated with each FILE +(typically \`/bin/rm'). RM-OPTIONS are options (such as \`-f') to be passed +to RM. + +If FILE is a libtool library, all the files associated with it are deleted. +Otherwise, only FILE itself is deleted using RM." + ;; + +*) + $echo "$modename: invalid operation mode \`$mode'" 1>&2 + $echo "$help" 1>&2 + exit $EXIT_FAILURE + ;; +esac + +$echo +$echo "Try \`$modename --help' for more information about other modes." + +exit $? # The TAGs below are defined such that we never get into a situation # in which we disable both kinds of libraries. Given conflicting @@ -8390,17 +6943,14 @@ exit $exit_status # configuration. But we'll never go from static-only to shared-only. # ### BEGIN LIBTOOL TAG CONFIG: disable-shared -build_libtool_libs=no -build_old_libs=yes +disable_libs=shared # ### END LIBTOOL TAG CONFIG: disable-shared # ### BEGIN LIBTOOL TAG CONFIG: disable-static -build_old_libs=`case $build_libtool_libs in yes) echo no;; *) echo yes;; esac` +disable_libs=static # ### END LIBTOOL TAG CONFIG: disable-static # Local Variables: # mode:shell-script # sh-indentation:2 # End: -# vi:sw=2 - diff --git a/libX11/man/Makefile.am b/libX11/man/Makefile.am index 328e386c2..045c7dc5b 100644 --- a/libX11/man/Makefile.am +++ b/libX11/man/Makefile.am @@ -218,7 +218,7 @@ MANDEFS = -D__libmansuffix__=$(LIB_MAN_SUFFIX) \ CPP_MAN_FLAGS = $(MANDEFS) $(EXTRAMANDEFS) .man.$(LIB_MAN_SUFFIX): - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_MAN_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_MAN_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # Generate man page shadow files (Replaces InstallManPageAliases from Imake) all_shadows = \ @@ -1083,568 +1083,568 @@ XmbTextPerCharExtents_shadows = \ AllPlanes_shadowmen = $(AllPlanes_shadows:=.@LIB_MAN_SUFFIX@) $(AllPlanes_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/AllPlanes.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/AllPlanes.$(LIB_MAN_SUFFIX)" > $@ BlackPixelOfScreen_shadowmen = $(BlackPixelOfScreen_shadows:=.@LIB_MAN_SUFFIX@) $(BlackPixelOfScreen_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/BlackPixelOfScreen.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/BlackPixelOfScreen.$(LIB_MAN_SUFFIX)" > $@ DisplayOfCCC_shadowmen = $(DisplayOfCCC_shadows:=.@LIB_MAN_SUFFIX@) $(DisplayOfCCC_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/DisplayOfCCC.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/DisplayOfCCC.$(LIB_MAN_SUFFIX)" > $@ ImageByteOrder_shadowmen = $(ImageByteOrder_shadows:=.@LIB_MAN_SUFFIX@) $(ImageByteOrder_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/ImageByteOrder.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/ImageByteOrder.$(LIB_MAN_SUFFIX)" > $@ IsCursorKey_shadowmen = $(IsCursorKey_shadows:=.@LIB_MAN_SUFFIX@) $(IsCursorKey_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/IsCursorKey.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/IsCursorKey.$(LIB_MAN_SUFFIX)" > $@ XAllocClassHint_shadowmen = $(XAllocClassHint_shadows:=.@LIB_MAN_SUFFIX@) $(XAllocClassHint_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XAllocClassHint.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XAllocClassHint.$(LIB_MAN_SUFFIX)" > $@ XAllocIconSize_shadowmen = $(XAllocIconSize_shadows:=.@LIB_MAN_SUFFIX@) $(XAllocIconSize_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XAllocIconSize.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XAllocIconSize.$(LIB_MAN_SUFFIX)" > $@ XAllocStandardColormap_shadowmen = $(XAllocStandardColormap_shadows:=.@LIB_MAN_SUFFIX@) $(XAllocStandardColormap_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XAllocStandardColormap.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XAllocStandardColormap.$(LIB_MAN_SUFFIX)" > $@ XAllocSizeHints_shadowmen = $(XAllocSizeHints_shadows:=.@LIB_MAN_SUFFIX@) $(XAllocSizeHints_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XAllocSizeHints.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XAllocSizeHints.$(LIB_MAN_SUFFIX)" > $@ XAllocWMHints_shadowmen = $(XAllocWMHints_shadows:=.@LIB_MAN_SUFFIX@) $(XAllocWMHints_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XAllocWMHints.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XAllocWMHints.$(LIB_MAN_SUFFIX)" > $@ XAddHost_shadowmen = $(XAddHost_shadows:=.@LIB_MAN_SUFFIX@) $(XAddHost_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XAddHost.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XAddHost.$(LIB_MAN_SUFFIX)" > $@ XAllocColor_shadowmen = $(XAllocColor_shadows:=.@LIB_MAN_SUFFIX@) $(XAllocColor_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XAllocColor.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XAllocColor.$(LIB_MAN_SUFFIX)" > $@ XAnyEvent_shadowmen = $(XAnyEvent_shadows:=.@LIB_MAN_SUFFIX@) $(XAnyEvent_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XAnyEvent.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XAnyEvent.$(LIB_MAN_SUFFIX)" > $@ XButtonEvent_shadowmen = $(XButtonEvent_shadows:=.@LIB_MAN_SUFFIX@) $(XButtonEvent_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XButtonEvent.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XButtonEvent.$(LIB_MAN_SUFFIX)" > $@ XChangeKeyboardControl_shadowmen = $(XChangeKeyboardControl_shadows:=.@LIB_MAN_SUFFIX@) $(XChangeKeyboardControl_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XChangeKeyboardControl.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XChangeKeyboardControl.$(LIB_MAN_SUFFIX)" > $@ XChangeKeyboardMapping_shadowmen = $(XChangeKeyboardMapping_shadows:=.@LIB_MAN_SUFFIX@) $(XChangeKeyboardMapping_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XChangeKeyboardMapping.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XChangeKeyboardMapping.$(LIB_MAN_SUFFIX)" > $@ XChangePointerControl_shadowmen = $(XChangePointerControl_shadows:=.@LIB_MAN_SUFFIX@) $(XChangePointerControl_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XChangePointerControl.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XChangePointerControl.$(LIB_MAN_SUFFIX)" > $@ XChangeSaveSet_shadowmen = $(XChangeSaveSet_shadows:=.@LIB_MAN_SUFFIX@) $(XChangeSaveSet_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XChangeSaveSet.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XChangeSaveSet.$(LIB_MAN_SUFFIX)" > $@ XChangeWindowAttributes_shadowmen = $(XChangeWindowAttributes_shadows:=.@LIB_MAN_SUFFIX@) $(XChangeWindowAttributes_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XChangeWindowAttributes.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XChangeWindowAttributes.$(LIB_MAN_SUFFIX)" > $@ XClearArea_shadowmen = $(XClearArea_shadows:=.@LIB_MAN_SUFFIX@) $(XClearArea_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XClearArea.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XClearArea.$(LIB_MAN_SUFFIX)" > $@ XConfigureWindow_shadowmen = $(XConfigureWindow_shadows:=.@LIB_MAN_SUFFIX@) $(XConfigureWindow_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XConfigureWindow.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XConfigureWindow.$(LIB_MAN_SUFFIX)" > $@ XCopyArea_shadowmen = $(XCopyArea_shadows:=.@LIB_MAN_SUFFIX@) $(XCopyArea_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XCopyArea.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XCopyArea.$(LIB_MAN_SUFFIX)" > $@ XCreateColormap_shadowmen = $(XCreateColormap_shadows:=.@LIB_MAN_SUFFIX@) $(XCreateColormap_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XCreateColormap.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XCreateColormap.$(LIB_MAN_SUFFIX)" > $@ XCreateFontCursor_shadowmen = $(XCreateFontCursor_shadows:=.@LIB_MAN_SUFFIX@) $(XCreateFontCursor_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XCreateFontCursor.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XCreateFontCursor.$(LIB_MAN_SUFFIX)" > $@ XCreateFontSet_shadowmen = $(XCreateFontSet_shadows:=.@LIB_MAN_SUFFIX@) $(XCreateFontSet_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XCreateFontSet.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XCreateFontSet.$(LIB_MAN_SUFFIX)" > $@ XCreateGC_shadowmen = $(XCreateGC_shadows:=.@LIB_MAN_SUFFIX@) $(XCreateGC_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XCreateGC.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XCreateGC.$(LIB_MAN_SUFFIX)" > $@ XCreateIC_shadowmen = $(XCreateIC_shadows:=.@LIB_MAN_SUFFIX@) $(XCreateIC_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XCreateIC.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XCreateIC.$(LIB_MAN_SUFFIX)" > $@ XInitImage_shadowmen = $(XInitImage_shadows:=.@LIB_MAN_SUFFIX@) $(XInitImage_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XInitImage.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XInitImage.$(LIB_MAN_SUFFIX)" > $@ XCreateOC_shadowmen = $(XCreateOC_shadows:=.@LIB_MAN_SUFFIX@) $(XCreateOC_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XCreateOC.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XCreateOC.$(LIB_MAN_SUFFIX)" > $@ XCreatePixmap_shadowmen = $(XCreatePixmap_shadows:=.@LIB_MAN_SUFFIX@) $(XCreatePixmap_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XCreatePixmap.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XCreatePixmap.$(LIB_MAN_SUFFIX)" > $@ XCreateRegion_shadowmen = $(XCreateRegion_shadows:=.@LIB_MAN_SUFFIX@) $(XCreateRegion_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XCreateRegion.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XCreateRegion.$(LIB_MAN_SUFFIX)" > $@ XCreateWindow_shadowmen = $(XCreateWindow_shadows:=.@LIB_MAN_SUFFIX@) $(XCreateWindow_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XCreateWindow.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XCreateWindow.$(LIB_MAN_SUFFIX)" > $@ XDefineCursor_shadowmen = $(XDefineCursor_shadows:=.@LIB_MAN_SUFFIX@) $(XDefineCursor_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XDefineCursor.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XDefineCursor.$(LIB_MAN_SUFFIX)" > $@ XDestroyWindow_shadowmen = $(XDestroyWindow_shadows:=.@LIB_MAN_SUFFIX@) $(XDestroyWindow_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XDestroyWindow.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XDestroyWindow.$(LIB_MAN_SUFFIX)" > $@ XDrawArc_shadowmen = $(XDrawArc_shadows:=.@LIB_MAN_SUFFIX@) $(XDrawArc_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XDrawArc.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XDrawArc.$(LIB_MAN_SUFFIX)" > $@ XDrawImageString_shadowmen = $(XDrawImageString_shadows:=.@LIB_MAN_SUFFIX@) $(XDrawImageString_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XDrawImageString.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XDrawImageString.$(LIB_MAN_SUFFIX)" > $@ XDrawLine_shadowmen = $(XDrawLine_shadows:=.@LIB_MAN_SUFFIX@) $(XDrawLine_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XDrawLine.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XDrawLine.$(LIB_MAN_SUFFIX)" > $@ XDrawPoint_shadowmen = $(XDrawPoint_shadows:=.@LIB_MAN_SUFFIX@) $(XDrawPoint_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XDrawPoint.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XDrawPoint.$(LIB_MAN_SUFFIX)" > $@ XDrawRectangle_shadowmen = $(XDrawRectangle_shadows:=.@LIB_MAN_SUFFIX@) $(XDrawRectangle_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XDrawRectangle.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XDrawRectangle.$(LIB_MAN_SUFFIX)" > $@ XDrawString_shadowmen = $(XDrawString_shadows:=.@LIB_MAN_SUFFIX@) $(XDrawString_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XDrawString.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XDrawString.$(LIB_MAN_SUFFIX)" > $@ XDrawText_shadowmen = $(XDrawText_shadows:=.@LIB_MAN_SUFFIX@) $(XDrawText_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XDrawText.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XDrawText.$(LIB_MAN_SUFFIX)" > $@ XEmptyRegion_shadowmen = $(XEmptyRegion_shadows:=.@LIB_MAN_SUFFIX@) $(XEmptyRegion_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XEmptyRegion.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XEmptyRegion.$(LIB_MAN_SUFFIX)" > $@ XFillRectangle_shadowmen = $(XFillRectangle_shadows:=.@LIB_MAN_SUFFIX@) $(XFillRectangle_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XFillRectangle.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XFillRectangle.$(LIB_MAN_SUFFIX)" > $@ XFlush_shadowmen = $(XFlush_shadows:=.@LIB_MAN_SUFFIX@) $(XFlush_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XFlush.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XFlush.$(LIB_MAN_SUFFIX)" > $@ XFontsOfFontSet_shadowmen = $(XFontsOfFontSet_shadows:=.@LIB_MAN_SUFFIX@) $(XFontsOfFontSet_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XFontsOfFontSet.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XFontsOfFontSet.$(LIB_MAN_SUFFIX)" > $@ XGraphicsExposeEvent_shadowmen = $(XGraphicsExposeEvent_shadows:=.@LIB_MAN_SUFFIX@) $(XGraphicsExposeEvent_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XGraphicsExposeEvent.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XGraphicsExposeEvent.$(LIB_MAN_SUFFIX)" > $@ XrmGetFileDatabase_shadowmen = $(XrmGetFileDatabase_shadows:=.@LIB_MAN_SUFFIX@) $(XrmGetFileDatabase_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XrmGetFileDatabase.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XrmGetFileDatabase.$(LIB_MAN_SUFFIX)" > $@ XrmGetResource_shadowmen = $(XrmGetResource_shadows:=.@LIB_MAN_SUFFIX@) $(XrmGetResource_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XrmGetResource.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XrmGetResource.$(LIB_MAN_SUFFIX)" > $@ XGetEventData_shadowmen = $(XGetEventData_shadows:=.@LIB_MAN_SUFFIX@) $(XGetEventData_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XGetEventData.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XGetEventData.$(LIB_MAN_SUFFIX)" > $@ XGetVisualInfo_shadowmen = $(XGetVisualInfo_shadows:=.@LIB_MAN_SUFFIX@) $(XGetVisualInfo_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XGetVisualInfo.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XGetVisualInfo.$(LIB_MAN_SUFFIX)" > $@ XGetWindowAttributes_shadowmen = $(XGetWindowAttributes_shadows:=.@LIB_MAN_SUFFIX@) $(XGetWindowAttributes_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XGetWindowAttributes.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XGetWindowAttributes.$(LIB_MAN_SUFFIX)" > $@ XGetWindowProperty_shadowmen = $(XGetWindowProperty_shadows:=.@LIB_MAN_SUFFIX@) $(XGetWindowProperty_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XGetWindowProperty.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XGetWindowProperty.$(LIB_MAN_SUFFIX)" > $@ XGrabButton_shadowmen = $(XGrabButton_shadows:=.@LIB_MAN_SUFFIX@) $(XGrabButton_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XGrabButton.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XGrabButton.$(LIB_MAN_SUFFIX)" > $@ XGrabKey_shadowmen = $(XGrabKey_shadows:=.@LIB_MAN_SUFFIX@) $(XGrabKey_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XGrabKey.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XGrabKey.$(LIB_MAN_SUFFIX)" > $@ XGrabKeyboard_shadowmen = $(XGrabKeyboard_shadows:=.@LIB_MAN_SUFFIX@) $(XGrabKeyboard_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XGrabKeyboard.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XGrabKeyboard.$(LIB_MAN_SUFFIX)" > $@ XGrabPointer_shadowmen = $(XGrabPointer_shadows:=.@LIB_MAN_SUFFIX@) $(XGrabPointer_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XGrabPointer.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XGrabPointer.$(LIB_MAN_SUFFIX)" > $@ XGrabServer_shadowmen = $(XGrabServer_shadows:=.@LIB_MAN_SUFFIX@) $(XGrabServer_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XGrabServer.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XGrabServer.$(LIB_MAN_SUFFIX)" > $@ XIconifyWindow_shadowmen = $(XIconifyWindow_shadows:=.@LIB_MAN_SUFFIX@) $(XIconifyWindow_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XIconifyWindow.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XIconifyWindow.$(LIB_MAN_SUFFIX)" > $@ XIfEvent_shadowmen = $(XIfEvent_shadows:=.@LIB_MAN_SUFFIX@) $(XIfEvent_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XIfEvent.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XIfEvent.$(LIB_MAN_SUFFIX)" > $@ XrmInitialize_shadowmen = $(XrmInitialize_shadows:=.@LIB_MAN_SUFFIX@) $(XrmInitialize_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XrmInitialize.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XrmInitialize.$(LIB_MAN_SUFFIX)" > $@ XInstallColormap_shadowmen = $(XInstallColormap_shadows:=.@LIB_MAN_SUFFIX@) $(XInstallColormap_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XInstallColormap.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XInstallColormap.$(LIB_MAN_SUFFIX)" > $@ XAddConnectionWatch_shadowmen = $(XAddConnectionWatch_shadows:=.@LIB_MAN_SUFFIX@) $(XAddConnectionWatch_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XAddConnectionWatch.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XAddConnectionWatch.$(LIB_MAN_SUFFIX)" > $@ XIntersectRegion_shadowmen = $(XIntersectRegion_shadows:=.@LIB_MAN_SUFFIX@) $(XIntersectRegion_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XIntersectRegion.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XIntersectRegion.$(LIB_MAN_SUFFIX)" > $@ XInternAtom_shadowmen = $(XInternAtom_shadows:=.@LIB_MAN_SUFFIX@) $(XInternAtom_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XInternAtom.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XInternAtom.$(LIB_MAN_SUFFIX)" > $@ XListFonts_shadowmen = $(XListFonts_shadows:=.@LIB_MAN_SUFFIX@) $(XListFonts_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XListFonts.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XListFonts.$(LIB_MAN_SUFFIX)" > $@ XLoadFont_shadowmen = $(XLoadFont_shadows:=.@LIB_MAN_SUFFIX@) $(XLoadFont_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XLoadFont.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XLoadFont.$(LIB_MAN_SUFFIX)" > $@ XLookupKeysym_shadowmen = $(XLookupKeysym_shadows:=.@LIB_MAN_SUFFIX@) $(XLookupKeysym_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XLookupKeysym.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XLookupKeysym.$(LIB_MAN_SUFFIX)" > $@ XrmMergeDatabases_shadowmen = $(XrmMergeDatabases_shadows:=.@LIB_MAN_SUFFIX@) $(XrmMergeDatabases_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XrmMergeDatabases.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XrmMergeDatabases.$(LIB_MAN_SUFFIX)" > $@ XMapEvent_shadowmen = $(XMapEvent_shadows:=.@LIB_MAN_SUFFIX@) $(XMapEvent_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XMapEvent.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XMapEvent.$(LIB_MAN_SUFFIX)" > $@ XMapWindow_shadowmen = $(XMapWindow_shadows:=.@LIB_MAN_SUFFIX@) $(XMapWindow_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XMapWindow.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XMapWindow.$(LIB_MAN_SUFFIX)" > $@ XNextEvent_shadowmen = $(XNextEvent_shadows:=.@LIB_MAN_SUFFIX@) $(XNextEvent_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XNextEvent.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XNextEvent.$(LIB_MAN_SUFFIX)" > $@ XOpenDisplay_shadowmen = $(XOpenDisplay_shadows:=.@LIB_MAN_SUFFIX@) $(XOpenDisplay_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XOpenDisplay.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XOpenDisplay.$(LIB_MAN_SUFFIX)" > $@ XOpenIM_shadowmen = $(XOpenIM_shadows:=.@LIB_MAN_SUFFIX@) $(XOpenIM_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XOpenIM.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XOpenIM.$(LIB_MAN_SUFFIX)" > $@ XOpenOM_shadowmen = $(XOpenOM_shadows:=.@LIB_MAN_SUFFIX@) $(XOpenOM_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XOpenOM.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XOpenOM.$(LIB_MAN_SUFFIX)" > $@ XParseGeometry_shadowmen = $(XParseGeometry_shadows:=.@LIB_MAN_SUFFIX@) $(XParseGeometry_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XParseGeometry.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XParseGeometry.$(LIB_MAN_SUFFIX)" > $@ XPolygonRegion_shadowmen = $(XPolygonRegion_shadows:=.@LIB_MAN_SUFFIX@) $(XPolygonRegion_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XPolygonRegion.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XPolygonRegion.$(LIB_MAN_SUFFIX)" > $@ XPutImage_shadowmen = $(XPutImage_shadows:=.@LIB_MAN_SUFFIX@) $(XPutImage_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XPutImage.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XPutImage.$(LIB_MAN_SUFFIX)" > $@ XrmPutResource_shadowmen = $(XrmPutResource_shadows:=.@LIB_MAN_SUFFIX@) $(XrmPutResource_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XrmPutResource.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XrmPutResource.$(LIB_MAN_SUFFIX)" > $@ XQueryBestSize_shadowmen = $(XQueryBestSize_shadows:=.@LIB_MAN_SUFFIX@) $(XQueryBestSize_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XQueryBestSize.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XQueryBestSize.$(LIB_MAN_SUFFIX)" > $@ XQueryColor_shadowmen = $(XQueryColor_shadows:=.@LIB_MAN_SUFFIX@) $(XQueryColor_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XQueryColor.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XQueryColor.$(LIB_MAN_SUFFIX)" > $@ XQueryExtension_shadowmen = $(XQueryExtension_shadows:=.@LIB_MAN_SUFFIX@) $(XQueryExtension_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XQueryExtension.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XQueryExtension.$(LIB_MAN_SUFFIX)" > $@ XResourceManagerString_shadowmen = $(XResourceManagerString_shadows:=.@LIB_MAN_SUFFIX@) $(XResourceManagerString_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XResourceManagerString.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XResourceManagerString.$(LIB_MAN_SUFFIX)" > $@ XRaiseWindow_shadowmen = $(XRaiseWindow_shadows:=.@LIB_MAN_SUFFIX@) $(XRaiseWindow_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XRaiseWindow.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XRaiseWindow.$(LIB_MAN_SUFFIX)" > $@ XReadBitmapFile_shadowmen = $(XReadBitmapFile_shadows:=.@LIB_MAN_SUFFIX@) $(XReadBitmapFile_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XReadBitmapFile.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XReadBitmapFile.$(LIB_MAN_SUFFIX)" > $@ XRecolorCursor_shadowmen = $(XRecolorCursor_shadows:=.@LIB_MAN_SUFFIX@) $(XRecolorCursor_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XRecolorCursor.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XRecolorCursor.$(LIB_MAN_SUFFIX)" > $@ XSaveContext_shadowmen = $(XSaveContext_shadows:=.@LIB_MAN_SUFFIX@) $(XSaveContext_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSaveContext.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSaveContext.$(LIB_MAN_SUFFIX)" > $@ XSetICFocus_shadowmen = $(XSetICFocus_shadows:=.@LIB_MAN_SUFFIX@) $(XSetICFocus_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetICFocus.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetICFocus.$(LIB_MAN_SUFFIX)" > $@ XSetICValues_shadowmen = $(XSetICValues_shadows:=.@LIB_MAN_SUFFIX@) $(XSetICValues_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetICValues.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetICValues.$(LIB_MAN_SUFFIX)" > $@ XStringListToTextProperty_shadowmen = $(XStringListToTextProperty_shadows:=.@LIB_MAN_SUFFIX@) $(XStringListToTextProperty_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XStringListToTextProperty.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XStringListToTextProperty.$(LIB_MAN_SUFFIX)" > $@ XSetArcMode_shadowmen = $(XSetArcMode_shadows:=.@LIB_MAN_SUFFIX@) $(XSetArcMode_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetArcMode.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetArcMode.$(LIB_MAN_SUFFIX)" > $@ XSetClipOrigin_shadowmen = $(XSetClipOrigin_shadows:=.@LIB_MAN_SUFFIX@) $(XSetClipOrigin_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetClipOrigin.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetClipOrigin.$(LIB_MAN_SUFFIX)" > $@ XSetCloseDownMode_shadowmen = $(XSetCloseDownMode_shadows:=.@LIB_MAN_SUFFIX@) $(XSetCloseDownMode_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetCloseDownMode.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetCloseDownMode.$(LIB_MAN_SUFFIX)" > $@ XSetCommand_shadowmen = $(XSetCommand_shadows:=.@LIB_MAN_SUFFIX@) $(XSetCommand_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetCommand.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetCommand.$(LIB_MAN_SUFFIX)" > $@ XSetErrorHandler_shadowmen = $(XSetErrorHandler_shadows:=.@LIB_MAN_SUFFIX@) $(XSetErrorHandler_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetErrorHandler.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetErrorHandler.$(LIB_MAN_SUFFIX)" > $@ XSendEvent_shadowmen = $(XSendEvent_shadows:=.@LIB_MAN_SUFFIX@) $(XSendEvent_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSendEvent.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSendEvent.$(LIB_MAN_SUFFIX)" > $@ XSetFillStyle_shadowmen = $(XSetFillStyle_shadows:=.@LIB_MAN_SUFFIX@) $(XSetFillStyle_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetFillStyle.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetFillStyle.$(LIB_MAN_SUFFIX)" > $@ XSetFontPath_shadowmen = $(XSetFontPath_shadows:=.@LIB_MAN_SUFFIX@) $(XSetFontPath_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetFontPath.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetFontPath.$(LIB_MAN_SUFFIX)" > $@ XSetInputFocus_shadowmen = $(XSetInputFocus_shadows:=.@LIB_MAN_SUFFIX@) $(XSetInputFocus_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetInputFocus.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetInputFocus.$(LIB_MAN_SUFFIX)" > $@ XSetLineAttributes_shadowmen = $(XSetLineAttributes_shadows:=.@LIB_MAN_SUFFIX@) $(XSetLineAttributes_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetLineAttributes.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetLineAttributes.$(LIB_MAN_SUFFIX)" > $@ XSetPointerMapping_shadowmen = $(XSetPointerMapping_shadows:=.@LIB_MAN_SUFFIX@) $(XSetPointerMapping_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetPointerMapping.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetPointerMapping.$(LIB_MAN_SUFFIX)" > $@ XSetScreenSaver_shadowmen = $(XSetScreenSaver_shadows:=.@LIB_MAN_SUFFIX@) $(XSetScreenSaver_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetScreenSaver.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetScreenSaver.$(LIB_MAN_SUFFIX)" > $@ XSetSelectionOwner_shadowmen = $(XSetSelectionOwner_shadows:=.@LIB_MAN_SUFFIX@) $(XSetSelectionOwner_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetSelectionOwner.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetSelectionOwner.$(LIB_MAN_SUFFIX)" > $@ XSetState_shadowmen = $(XSetState_shadows:=.@LIB_MAN_SUFFIX@) $(XSetState_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetState.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetState.$(LIB_MAN_SUFFIX)" > $@ XSetTransientForHint_shadowmen = $(XSetTransientForHint_shadows:=.@LIB_MAN_SUFFIX@) $(XSetTransientForHint_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetTransientForHint.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetTransientForHint.$(LIB_MAN_SUFFIX)" > $@ XSetTextProperty_shadowmen = $(XSetTextProperty_shadows:=.@LIB_MAN_SUFFIX@) $(XSetTextProperty_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetTextProperty.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetTextProperty.$(LIB_MAN_SUFFIX)" > $@ XSetTile_shadowmen = $(XSetTile_shadows:=.@LIB_MAN_SUFFIX@) $(XSetTile_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetTile.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetTile.$(LIB_MAN_SUFFIX)" > $@ XSetWMClientMachine_shadowmen = $(XSetWMClientMachine_shadows:=.@LIB_MAN_SUFFIX@) $(XSetWMClientMachine_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetWMClientMachine.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetWMClientMachine.$(LIB_MAN_SUFFIX)" > $@ XSetWMColormapWindows_shadowmen = $(XSetWMColormapWindows_shadows:=.@LIB_MAN_SUFFIX@) $(XSetWMColormapWindows_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetWMColormapWindows.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetWMColormapWindows.$(LIB_MAN_SUFFIX)" > $@ XSetWMIconName_shadowmen = $(XSetWMIconName_shadows:=.@LIB_MAN_SUFFIX@) $(XSetWMIconName_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetWMIconName.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetWMIconName.$(LIB_MAN_SUFFIX)" > $@ XSetWMName_shadowmen = $(XSetWMName_shadows:=.@LIB_MAN_SUFFIX@) $(XSetWMName_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetWMName.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetWMName.$(LIB_MAN_SUFFIX)" > $@ XSetWMProperties_shadowmen = $(XSetWMProperties_shadows:=.@LIB_MAN_SUFFIX@) $(XSetWMProperties_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetWMProperties.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetWMProperties.$(LIB_MAN_SUFFIX)" > $@ XSetWMProtocols_shadowmen = $(XSetWMProtocols_shadows:=.@LIB_MAN_SUFFIX@) $(XSetWMProtocols_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetWMProtocols.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetWMProtocols.$(LIB_MAN_SUFFIX)" > $@ XStoreBytes_shadowmen = $(XStoreBytes_shadows:=.@LIB_MAN_SUFFIX@) $(XStoreBytes_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XStoreBytes.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XStoreBytes.$(LIB_MAN_SUFFIX)" > $@ XStoreColors_shadowmen = $(XStoreColors_shadows:=.@LIB_MAN_SUFFIX@) $(XStoreColors_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XStoreColors.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XStoreColors.$(LIB_MAN_SUFFIX)" > $@ XStringToKeysym_shadowmen = $(XStringToKeysym_shadows:=.@LIB_MAN_SUFFIX@) $(XStringToKeysym_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XStringToKeysym.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XStringToKeysym.$(LIB_MAN_SUFFIX)" > $@ XSupportsLocale_shadowmen = $(XSupportsLocale_shadows:=.@LIB_MAN_SUFFIX@) $(XSupportsLocale_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSupportsLocale.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSupportsLocale.$(LIB_MAN_SUFFIX)" > $@ XSynchronize_shadowmen = $(XSynchronize_shadows:=.@LIB_MAN_SUFFIX@) $(XSynchronize_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSynchronize.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSynchronize.$(LIB_MAN_SUFFIX)" > $@ XmbTextListToTextProperty_shadowmen = $(XmbTextListToTextProperty_shadows:=.@LIB_MAN_SUFFIX@) $(XmbTextListToTextProperty_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XmbTextListToTextProperty.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XmbTextListToTextProperty.$(LIB_MAN_SUFFIX)" > $@ XTextExtents_shadowmen = $(XTextExtents_shadows:=.@LIB_MAN_SUFFIX@) $(XTextExtents_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XTextExtents.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XTextExtents.$(LIB_MAN_SUFFIX)" > $@ XTextWidth_shadowmen = $(XTextWidth_shadows:=.@LIB_MAN_SUFFIX@) $(XTextWidth_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XTextWidth.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XTextWidth.$(LIB_MAN_SUFFIX)" > $@ XInitThreads_shadowmen = $(XInitThreads_shadows:=.@LIB_MAN_SUFFIX@) $(XInitThreads_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XInitThreads.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XInitThreads.$(LIB_MAN_SUFFIX)" > $@ XrmUniqueQuark_shadowmen = $(XrmUniqueQuark_shadows:=.@LIB_MAN_SUFFIX@) $(XrmUniqueQuark_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XrmUniqueQuark.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XrmUniqueQuark.$(LIB_MAN_SUFFIX)" > $@ XUnmapWindow_shadowmen = $(XUnmapWindow_shadows:=.@LIB_MAN_SUFFIX@) $(XUnmapWindow_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XUnmapWindow.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XUnmapWindow.$(LIB_MAN_SUFFIX)" > $@ XcmsCCCOfColormap_shadowmen = $(XcmsCCCOfColormap_shadows:=.@LIB_MAN_SUFFIX@) $(XcmsCCCOfColormap_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XcmsCCCOfColormap.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XcmsCCCOfColormap.$(LIB_MAN_SUFFIX)" > $@ XcmsAllocColor_shadowmen = $(XcmsAllocColor_shadows:=.@LIB_MAN_SUFFIX@) $(XcmsAllocColor_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XcmsAllocColor.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XcmsAllocColor.$(LIB_MAN_SUFFIX)" > $@ XcmsColor_shadowmen = $(XcmsColor_shadows:=.@LIB_MAN_SUFFIX@) $(XcmsColor_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XcmsColor.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XcmsColor.$(LIB_MAN_SUFFIX)" > $@ XcmsCreateCCC_shadowmen = $(XcmsCreateCCC_shadows:=.@LIB_MAN_SUFFIX@) $(XcmsCreateCCC_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XcmsCreateCCC.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XcmsCreateCCC.$(LIB_MAN_SUFFIX)" > $@ XcmsCIELabQueryMaxC_shadowmen = $(XcmsCIELabQueryMaxC_shadows:=.@LIB_MAN_SUFFIX@) $(XcmsCIELabQueryMaxC_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XcmsCIELabQueryMaxC.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XcmsCIELabQueryMaxC.$(LIB_MAN_SUFFIX)" > $@ XcmsCIELuvQueryMaxC_shadowmen = $(XcmsCIELuvQueryMaxC_shadows:=.@LIB_MAN_SUFFIX@) $(XcmsCIELuvQueryMaxC_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XcmsCIELuvQueryMaxC.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XcmsCIELuvQueryMaxC.$(LIB_MAN_SUFFIX)" > $@ XcmsQueryBlack_shadowmen = $(XcmsQueryBlack_shadows:=.@LIB_MAN_SUFFIX@) $(XcmsQueryBlack_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XcmsQueryBlack.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XcmsQueryBlack.$(LIB_MAN_SUFFIX)" > $@ XcmsQueryColor_shadowmen = $(XcmsQueryColor_shadows:=.@LIB_MAN_SUFFIX@) $(XcmsQueryColor_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XcmsQueryColor.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XcmsQueryColor.$(LIB_MAN_SUFFIX)" > $@ XcmsStoreColor_shadowmen = $(XcmsStoreColor_shadows:=.@LIB_MAN_SUFFIX@) $(XcmsStoreColor_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XcmsStoreColor.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XcmsStoreColor.$(LIB_MAN_SUFFIX)" > $@ XcmsSetWhitePoint_shadowmen = $(XcmsSetWhitePoint_shadows:=.@LIB_MAN_SUFFIX@) $(XcmsSetWhitePoint_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XcmsSetWhitePoint.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XcmsSetWhitePoint.$(LIB_MAN_SUFFIX)" > $@ XcmsTekHVCQueryMaxC_shadowmen = $(XcmsTekHVCQueryMaxC_shadows:=.@LIB_MAN_SUFFIX@) $(XcmsTekHVCQueryMaxC_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XcmsTekHVCQueryMaxC.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XcmsTekHVCQueryMaxC.$(LIB_MAN_SUFFIX)" > $@ XmbDrawImageString_shadowmen = $(XmbDrawImageString_shadows:=.@LIB_MAN_SUFFIX@) $(XmbDrawImageString_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XmbDrawImageString.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XmbDrawImageString.$(LIB_MAN_SUFFIX)" > $@ XmbDrawString_shadowmen = $(XmbDrawString_shadows:=.@LIB_MAN_SUFFIX@) $(XmbDrawString_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XmbDrawString.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XmbDrawString.$(LIB_MAN_SUFFIX)" > $@ XmbDrawText_shadowmen = $(XmbDrawText_shadows:=.@LIB_MAN_SUFFIX@) $(XmbDrawText_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XmbDrawText.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XmbDrawText.$(LIB_MAN_SUFFIX)" > $@ XmbLookupString_shadowmen = $(XmbLookupString_shadows:=.@LIB_MAN_SUFFIX@) $(XmbLookupString_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XmbLookupString.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XmbLookupString.$(LIB_MAN_SUFFIX)" > $@ XmbResetIC_shadowmen = $(XmbResetIC_shadows:=.@LIB_MAN_SUFFIX@) $(XmbResetIC_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XmbResetIC.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XmbResetIC.$(LIB_MAN_SUFFIX)" > $@ XmbTextEscapement_shadowmen = $(XmbTextEscapement_shadows:=.@LIB_MAN_SUFFIX@) $(XmbTextEscapement_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XmbTextEscapement.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XmbTextEscapement.$(LIB_MAN_SUFFIX)" > $@ XmbTextExtents_shadowmen = $(XmbTextExtents_shadows:=.@LIB_MAN_SUFFIX@) $(XmbTextExtents_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XmbTextExtents.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XmbTextExtents.$(LIB_MAN_SUFFIX)" > $@ XmbTextPerCharExtents_shadowmen = $(XmbTextPerCharExtents_shadows:=.@LIB_MAN_SUFFIX@) $(XmbTextPerCharExtents_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XmbTextPerCharExtents.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XmbTextPerCharExtents.$(LIB_MAN_SUFFIX)" > $@ diff --git a/libX11/man/Makefile.in b/libX11/man/Makefile.in index a4726568d..303f821de 100644 --- a/libX11/man/Makefile.in +++ b/libX11/man/Makefile.in @@ -148,6 +148,10 @@ 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@ @@ -155,16 +159,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -173,7 +179,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -183,7 +188,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -194,12 +198,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -209,6 +209,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -247,7 +248,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -279,7 +281,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -510,11 +511,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; XORGRELSTRING = @PACKAGE_STRING@ XORGMANNAME = X Version 11 MANDEFS = -D__libmansuffix__=$(LIB_MAN_SUFFIX) \ @@ -1898,294 +1894,294 @@ uninstall-am: uninstall-libmanDATA .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ .man.$(LIB_MAN_SUFFIX): - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_MAN_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_MAN_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ $(AllPlanes_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/AllPlanes.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/AllPlanes.$(LIB_MAN_SUFFIX)" > $@ $(BlackPixelOfScreen_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/BlackPixelOfScreen.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/BlackPixelOfScreen.$(LIB_MAN_SUFFIX)" > $@ $(DisplayOfCCC_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/DisplayOfCCC.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/DisplayOfCCC.$(LIB_MAN_SUFFIX)" > $@ $(ImageByteOrder_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/ImageByteOrder.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/ImageByteOrder.$(LIB_MAN_SUFFIX)" > $@ $(IsCursorKey_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/IsCursorKey.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/IsCursorKey.$(LIB_MAN_SUFFIX)" > $@ $(XAllocClassHint_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XAllocClassHint.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XAllocClassHint.$(LIB_MAN_SUFFIX)" > $@ $(XAllocIconSize_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XAllocIconSize.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XAllocIconSize.$(LIB_MAN_SUFFIX)" > $@ $(XAllocStandardColormap_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XAllocStandardColormap.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XAllocStandardColormap.$(LIB_MAN_SUFFIX)" > $@ $(XAllocSizeHints_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XAllocSizeHints.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XAllocSizeHints.$(LIB_MAN_SUFFIX)" > $@ $(XAllocWMHints_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XAllocWMHints.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XAllocWMHints.$(LIB_MAN_SUFFIX)" > $@ $(XAddHost_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XAddHost.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XAddHost.$(LIB_MAN_SUFFIX)" > $@ $(XAllocColor_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XAllocColor.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XAllocColor.$(LIB_MAN_SUFFIX)" > $@ $(XAnyEvent_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XAnyEvent.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XAnyEvent.$(LIB_MAN_SUFFIX)" > $@ $(XButtonEvent_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XButtonEvent.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XButtonEvent.$(LIB_MAN_SUFFIX)" > $@ $(XChangeKeyboardControl_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XChangeKeyboardControl.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XChangeKeyboardControl.$(LIB_MAN_SUFFIX)" > $@ $(XChangeKeyboardMapping_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XChangeKeyboardMapping.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XChangeKeyboardMapping.$(LIB_MAN_SUFFIX)" > $@ $(XChangePointerControl_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XChangePointerControl.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XChangePointerControl.$(LIB_MAN_SUFFIX)" > $@ $(XChangeSaveSet_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XChangeSaveSet.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XChangeSaveSet.$(LIB_MAN_SUFFIX)" > $@ $(XChangeWindowAttributes_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XChangeWindowAttributes.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XChangeWindowAttributes.$(LIB_MAN_SUFFIX)" > $@ $(XClearArea_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XClearArea.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XClearArea.$(LIB_MAN_SUFFIX)" > $@ $(XConfigureWindow_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XConfigureWindow.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XConfigureWindow.$(LIB_MAN_SUFFIX)" > $@ $(XCopyArea_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XCopyArea.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XCopyArea.$(LIB_MAN_SUFFIX)" > $@ $(XCreateColormap_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XCreateColormap.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XCreateColormap.$(LIB_MAN_SUFFIX)" > $@ $(XCreateFontCursor_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XCreateFontCursor.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XCreateFontCursor.$(LIB_MAN_SUFFIX)" > $@ $(XCreateFontSet_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XCreateFontSet.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XCreateFontSet.$(LIB_MAN_SUFFIX)" > $@ $(XCreateGC_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XCreateGC.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XCreateGC.$(LIB_MAN_SUFFIX)" > $@ $(XCreateIC_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XCreateIC.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XCreateIC.$(LIB_MAN_SUFFIX)" > $@ $(XInitImage_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XInitImage.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XInitImage.$(LIB_MAN_SUFFIX)" > $@ $(XCreateOC_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XCreateOC.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XCreateOC.$(LIB_MAN_SUFFIX)" > $@ $(XCreatePixmap_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XCreatePixmap.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XCreatePixmap.$(LIB_MAN_SUFFIX)" > $@ $(XCreateRegion_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XCreateRegion.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XCreateRegion.$(LIB_MAN_SUFFIX)" > $@ $(XCreateWindow_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XCreateWindow.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XCreateWindow.$(LIB_MAN_SUFFIX)" > $@ $(XDefineCursor_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XDefineCursor.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XDefineCursor.$(LIB_MAN_SUFFIX)" > $@ $(XDestroyWindow_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XDestroyWindow.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XDestroyWindow.$(LIB_MAN_SUFFIX)" > $@ $(XDrawArc_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XDrawArc.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XDrawArc.$(LIB_MAN_SUFFIX)" > $@ $(XDrawImageString_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XDrawImageString.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XDrawImageString.$(LIB_MAN_SUFFIX)" > $@ $(XDrawLine_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XDrawLine.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XDrawLine.$(LIB_MAN_SUFFIX)" > $@ $(XDrawPoint_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XDrawPoint.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XDrawPoint.$(LIB_MAN_SUFFIX)" > $@ $(XDrawRectangle_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XDrawRectangle.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XDrawRectangle.$(LIB_MAN_SUFFIX)" > $@ $(XDrawString_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XDrawString.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XDrawString.$(LIB_MAN_SUFFIX)" > $@ $(XDrawText_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XDrawText.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XDrawText.$(LIB_MAN_SUFFIX)" > $@ $(XEmptyRegion_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XEmptyRegion.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XEmptyRegion.$(LIB_MAN_SUFFIX)" > $@ $(XFillRectangle_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XFillRectangle.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XFillRectangle.$(LIB_MAN_SUFFIX)" > $@ $(XFlush_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XFlush.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XFlush.$(LIB_MAN_SUFFIX)" > $@ $(XFontsOfFontSet_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XFontsOfFontSet.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XFontsOfFontSet.$(LIB_MAN_SUFFIX)" > $@ $(XGraphicsExposeEvent_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XGraphicsExposeEvent.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XGraphicsExposeEvent.$(LIB_MAN_SUFFIX)" > $@ $(XrmGetFileDatabase_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XrmGetFileDatabase.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XrmGetFileDatabase.$(LIB_MAN_SUFFIX)" > $@ $(XrmGetResource_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XrmGetResource.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XrmGetResource.$(LIB_MAN_SUFFIX)" > $@ $(XGetEventData_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XGetEventData.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XGetEventData.$(LIB_MAN_SUFFIX)" > $@ $(XGetVisualInfo_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XGetVisualInfo.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XGetVisualInfo.$(LIB_MAN_SUFFIX)" > $@ $(XGetWindowAttributes_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XGetWindowAttributes.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XGetWindowAttributes.$(LIB_MAN_SUFFIX)" > $@ $(XGetWindowProperty_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XGetWindowProperty.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XGetWindowProperty.$(LIB_MAN_SUFFIX)" > $@ $(XGrabButton_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XGrabButton.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XGrabButton.$(LIB_MAN_SUFFIX)" > $@ $(XGrabKey_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XGrabKey.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XGrabKey.$(LIB_MAN_SUFFIX)" > $@ $(XGrabKeyboard_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XGrabKeyboard.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XGrabKeyboard.$(LIB_MAN_SUFFIX)" > $@ $(XGrabPointer_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XGrabPointer.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XGrabPointer.$(LIB_MAN_SUFFIX)" > $@ $(XGrabServer_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XGrabServer.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XGrabServer.$(LIB_MAN_SUFFIX)" > $@ $(XIconifyWindow_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XIconifyWindow.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XIconifyWindow.$(LIB_MAN_SUFFIX)" > $@ $(XIfEvent_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XIfEvent.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XIfEvent.$(LIB_MAN_SUFFIX)" > $@ $(XrmInitialize_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XrmInitialize.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XrmInitialize.$(LIB_MAN_SUFFIX)" > $@ $(XInstallColormap_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XInstallColormap.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XInstallColormap.$(LIB_MAN_SUFFIX)" > $@ $(XAddConnectionWatch_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XAddConnectionWatch.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XAddConnectionWatch.$(LIB_MAN_SUFFIX)" > $@ $(XIntersectRegion_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XIntersectRegion.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XIntersectRegion.$(LIB_MAN_SUFFIX)" > $@ $(XInternAtom_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XInternAtom.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XInternAtom.$(LIB_MAN_SUFFIX)" > $@ $(XListFonts_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XListFonts.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XListFonts.$(LIB_MAN_SUFFIX)" > $@ $(XLoadFont_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XLoadFont.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XLoadFont.$(LIB_MAN_SUFFIX)" > $@ $(XLookupKeysym_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XLookupKeysym.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XLookupKeysym.$(LIB_MAN_SUFFIX)" > $@ $(XrmMergeDatabases_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XrmMergeDatabases.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XrmMergeDatabases.$(LIB_MAN_SUFFIX)" > $@ $(XMapEvent_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XMapEvent.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XMapEvent.$(LIB_MAN_SUFFIX)" > $@ $(XMapWindow_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XMapWindow.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XMapWindow.$(LIB_MAN_SUFFIX)" > $@ $(XNextEvent_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XNextEvent.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XNextEvent.$(LIB_MAN_SUFFIX)" > $@ $(XOpenDisplay_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XOpenDisplay.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XOpenDisplay.$(LIB_MAN_SUFFIX)" > $@ $(XOpenIM_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XOpenIM.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XOpenIM.$(LIB_MAN_SUFFIX)" > $@ $(XOpenOM_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XOpenOM.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XOpenOM.$(LIB_MAN_SUFFIX)" > $@ $(XParseGeometry_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XParseGeometry.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XParseGeometry.$(LIB_MAN_SUFFIX)" > $@ $(XPolygonRegion_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XPolygonRegion.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XPolygonRegion.$(LIB_MAN_SUFFIX)" > $@ $(XPutImage_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XPutImage.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XPutImage.$(LIB_MAN_SUFFIX)" > $@ $(XrmPutResource_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XrmPutResource.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XrmPutResource.$(LIB_MAN_SUFFIX)" > $@ $(XQueryBestSize_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XQueryBestSize.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XQueryBestSize.$(LIB_MAN_SUFFIX)" > $@ $(XQueryColor_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XQueryColor.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XQueryColor.$(LIB_MAN_SUFFIX)" > $@ $(XQueryExtension_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XQueryExtension.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XQueryExtension.$(LIB_MAN_SUFFIX)" > $@ $(XResourceManagerString_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XResourceManagerString.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XResourceManagerString.$(LIB_MAN_SUFFIX)" > $@ $(XRaiseWindow_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XRaiseWindow.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XRaiseWindow.$(LIB_MAN_SUFFIX)" > $@ $(XReadBitmapFile_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XReadBitmapFile.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XReadBitmapFile.$(LIB_MAN_SUFFIX)" > $@ $(XRecolorCursor_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XRecolorCursor.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XRecolorCursor.$(LIB_MAN_SUFFIX)" > $@ $(XSaveContext_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSaveContext.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSaveContext.$(LIB_MAN_SUFFIX)" > $@ $(XSetICFocus_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetICFocus.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetICFocus.$(LIB_MAN_SUFFIX)" > $@ $(XSetICValues_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetICValues.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetICValues.$(LIB_MAN_SUFFIX)" > $@ $(XStringListToTextProperty_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XStringListToTextProperty.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XStringListToTextProperty.$(LIB_MAN_SUFFIX)" > $@ $(XSetArcMode_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetArcMode.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetArcMode.$(LIB_MAN_SUFFIX)" > $@ $(XSetClipOrigin_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetClipOrigin.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetClipOrigin.$(LIB_MAN_SUFFIX)" > $@ $(XSetCloseDownMode_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetCloseDownMode.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetCloseDownMode.$(LIB_MAN_SUFFIX)" > $@ $(XSetCommand_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetCommand.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetCommand.$(LIB_MAN_SUFFIX)" > $@ $(XSetErrorHandler_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetErrorHandler.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetErrorHandler.$(LIB_MAN_SUFFIX)" > $@ $(XSendEvent_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSendEvent.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSendEvent.$(LIB_MAN_SUFFIX)" > $@ $(XSetFillStyle_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetFillStyle.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetFillStyle.$(LIB_MAN_SUFFIX)" > $@ $(XSetFontPath_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetFontPath.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetFontPath.$(LIB_MAN_SUFFIX)" > $@ $(XSetInputFocus_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetInputFocus.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetInputFocus.$(LIB_MAN_SUFFIX)" > $@ $(XSetLineAttributes_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetLineAttributes.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetLineAttributes.$(LIB_MAN_SUFFIX)" > $@ $(XSetPointerMapping_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetPointerMapping.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetPointerMapping.$(LIB_MAN_SUFFIX)" > $@ $(XSetScreenSaver_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetScreenSaver.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetScreenSaver.$(LIB_MAN_SUFFIX)" > $@ $(XSetSelectionOwner_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetSelectionOwner.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetSelectionOwner.$(LIB_MAN_SUFFIX)" > $@ $(XSetState_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetState.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetState.$(LIB_MAN_SUFFIX)" > $@ $(XSetTransientForHint_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetTransientForHint.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetTransientForHint.$(LIB_MAN_SUFFIX)" > $@ $(XSetTextProperty_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetTextProperty.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetTextProperty.$(LIB_MAN_SUFFIX)" > $@ $(XSetTile_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetTile.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetTile.$(LIB_MAN_SUFFIX)" > $@ $(XSetWMClientMachine_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetWMClientMachine.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetWMClientMachine.$(LIB_MAN_SUFFIX)" > $@ $(XSetWMColormapWindows_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetWMColormapWindows.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetWMColormapWindows.$(LIB_MAN_SUFFIX)" > $@ $(XSetWMIconName_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetWMIconName.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetWMIconName.$(LIB_MAN_SUFFIX)" > $@ $(XSetWMName_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetWMName.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetWMName.$(LIB_MAN_SUFFIX)" > $@ $(XSetWMProperties_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetWMProperties.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetWMProperties.$(LIB_MAN_SUFFIX)" > $@ $(XSetWMProtocols_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetWMProtocols.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSetWMProtocols.$(LIB_MAN_SUFFIX)" > $@ $(XStoreBytes_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XStoreBytes.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XStoreBytes.$(LIB_MAN_SUFFIX)" > $@ $(XStoreColors_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XStoreColors.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XStoreColors.$(LIB_MAN_SUFFIX)" > $@ $(XStringToKeysym_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XStringToKeysym.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XStringToKeysym.$(LIB_MAN_SUFFIX)" > $@ $(XSupportsLocale_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSupportsLocale.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSupportsLocale.$(LIB_MAN_SUFFIX)" > $@ $(XSynchronize_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSynchronize.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XSynchronize.$(LIB_MAN_SUFFIX)" > $@ $(XmbTextListToTextProperty_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XmbTextListToTextProperty.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XmbTextListToTextProperty.$(LIB_MAN_SUFFIX)" > $@ $(XTextExtents_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XTextExtents.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XTextExtents.$(LIB_MAN_SUFFIX)" > $@ $(XTextWidth_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XTextWidth.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XTextWidth.$(LIB_MAN_SUFFIX)" > $@ $(XInitThreads_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XInitThreads.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XInitThreads.$(LIB_MAN_SUFFIX)" > $@ $(XrmUniqueQuark_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XrmUniqueQuark.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XrmUniqueQuark.$(LIB_MAN_SUFFIX)" > $@ $(XUnmapWindow_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XUnmapWindow.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XUnmapWindow.$(LIB_MAN_SUFFIX)" > $@ $(XcmsCCCOfColormap_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XcmsCCCOfColormap.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XcmsCCCOfColormap.$(LIB_MAN_SUFFIX)" > $@ $(XcmsAllocColor_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XcmsAllocColor.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XcmsAllocColor.$(LIB_MAN_SUFFIX)" > $@ $(XcmsColor_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XcmsColor.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XcmsColor.$(LIB_MAN_SUFFIX)" > $@ $(XcmsCreateCCC_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XcmsCreateCCC.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XcmsCreateCCC.$(LIB_MAN_SUFFIX)" > $@ $(XcmsCIELabQueryMaxC_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XcmsCIELabQueryMaxC.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XcmsCIELabQueryMaxC.$(LIB_MAN_SUFFIX)" > $@ $(XcmsCIELuvQueryMaxC_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XcmsCIELuvQueryMaxC.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XcmsCIELuvQueryMaxC.$(LIB_MAN_SUFFIX)" > $@ $(XcmsQueryBlack_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XcmsQueryBlack.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XcmsQueryBlack.$(LIB_MAN_SUFFIX)" > $@ $(XcmsQueryColor_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XcmsQueryColor.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XcmsQueryColor.$(LIB_MAN_SUFFIX)" > $@ $(XcmsStoreColor_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XcmsStoreColor.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XcmsStoreColor.$(LIB_MAN_SUFFIX)" > $@ $(XcmsSetWhitePoint_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XcmsSetWhitePoint.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XcmsSetWhitePoint.$(LIB_MAN_SUFFIX)" > $@ $(XcmsTekHVCQueryMaxC_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XcmsTekHVCQueryMaxC.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XcmsTekHVCQueryMaxC.$(LIB_MAN_SUFFIX)" > $@ $(XmbDrawImageString_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XmbDrawImageString.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XmbDrawImageString.$(LIB_MAN_SUFFIX)" > $@ $(XmbDrawString_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XmbDrawString.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XmbDrawString.$(LIB_MAN_SUFFIX)" > $@ $(XmbDrawText_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XmbDrawText.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XmbDrawText.$(LIB_MAN_SUFFIX)" > $@ $(XmbLookupString_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XmbLookupString.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XmbLookupString.$(LIB_MAN_SUFFIX)" > $@ $(XmbResetIC_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XmbResetIC.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XmbResetIC.$(LIB_MAN_SUFFIX)" > $@ $(XmbTextEscapement_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XmbTextEscapement.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XmbTextEscapement.$(LIB_MAN_SUFFIX)" > $@ $(XmbTextExtents_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XmbTextExtents.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XmbTextExtents.$(LIB_MAN_SUFFIX)" > $@ $(XmbTextPerCharExtents_shadowmen): - echo ".so man$(LIB_MAN_DIR_SUFFIX)/XmbTextPerCharExtents.$(LIB_MAN_SUFFIX)" > $@ + $(AM_V_GEN)echo ".so man$(LIB_MAN_DIR_SUFFIX)/XmbTextPerCharExtents.$(LIB_MAN_SUFFIX)" > $@ # 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. diff --git a/libX11/man/xkb/Makefile.am b/libX11/man/xkb/Makefile.am index a15932f4b..a4eaa6bd1 100644 --- a/libX11/man/xkb/Makefile.am +++ b/libX11/man/xkb/Makefile.am @@ -230,5 +230,5 @@ MANDEFS = -D__libmansuffix__=$(LIB_MAN_SUFFIX) \ CPP_MAN_FLAGS = $(MANDEFS) $(EXTRAMANDEFS) .man.$(LIB_MAN_SUFFIX): - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_MAN_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_MAN_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ diff --git a/libX11/man/xkb/Makefile.in b/libX11/man/xkb/Makefile.in index a8639b91e..eac8ce92b 100644 --- a/libX11/man/xkb/Makefile.in +++ b/libX11/man/xkb/Makefile.in @@ -108,6 +108,10 @@ 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@ @@ -115,16 +119,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -133,7 +139,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -143,7 +148,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -154,12 +158,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -169,6 +169,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -207,7 +208,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -239,7 +241,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -482,11 +483,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; XORGRELSTRING = @PACKAGE_STRING@ XORGMANNAME = X Version 11 MANDEFS = -D__libmansuffix__=$(LIB_MAN_SUFFIX) \ @@ -705,10 +701,10 @@ uninstall-am: uninstall-libmanDATA .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ .man.$(LIB_MAN_SUFFIX): - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_MAN_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_MAN_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/modules/Makefile.in b/libX11/modules/Makefile.in index c67aab77d..5fa070d38 100644 --- a/libX11/modules/Makefile.in +++ b/libX11/modules/Makefile.in @@ -116,6 +116,10 @@ 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@ @@ -123,16 +127,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -141,7 +147,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -151,7 +156,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -162,12 +166,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -177,6 +177,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -215,7 +216,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -247,7 +249,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ diff --git a/libX11/modules/im/Makefile.in b/libX11/modules/im/Makefile.in index d690ee65a..9432ee38a 100644 --- a/libX11/modules/im/Makefile.in +++ b/libX11/modules/im/Makefile.in @@ -116,6 +116,10 @@ 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@ @@ -123,16 +127,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -141,7 +147,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -151,7 +156,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -162,12 +166,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -177,6 +177,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -215,7 +216,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -247,7 +249,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ diff --git a/libX11/modules/im/ximcp/Makefile.am b/libX11/modules/im/ximcp/Makefile.am index 914ca3efa..0dc8dfbfb 100644 --- a/libX11/modules/im/ximcp/Makefile.am +++ b/libX11/modules/im/ximcp/Makefile.am @@ -1,4 +1,4 @@ -AM_CFLAGS= \ +AM_CPPFLAGS= \ -I$(top_srcdir)/include \ -I$(top_srcdir)/include/X11 \ -I$(top_builddir)/include \ @@ -6,10 +6,12 @@ AM_CFLAGS= \ -I$(top_srcdir)/src/xcms \ -I$(top_srcdir)/src/xkb \ -I$(top_srcdir)/src/xlibi18n \ + -D_BSD_SOURCE -DXIM_t -DTRANS_CLIENT + +AM_CFLAGS= \ $(X11_CFLAGS) \ $(BIGFONT_CFLAGS) \ $(XDMCP_CFLAGS) \ - -D_BSD_SOURCE -DXIM_t -DTRANS_CLIENT \ $(MALLOC_ZERO_CFLAGS) if XLIB_LOADABLE_I18N diff --git a/libX11/modules/im/ximcp/Makefile.in b/libX11/modules/im/ximcp/Makefile.in index 905d526df..d59582bd6 100644 --- a/libX11/modules/im/ximcp/Makefile.in +++ b/libX11/modules/im/ximcp/Makefile.in @@ -145,6 +145,10 @@ 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@ @@ -152,16 +156,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -170,7 +176,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -180,7 +185,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -191,12 +195,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -206,6 +206,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -244,7 +245,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -276,7 +278,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -292,7 +293,7 @@ target_alias = @target_alias@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ -AM_CFLAGS = \ +AM_CPPFLAGS = \ -I$(top_srcdir)/include \ -I$(top_srcdir)/include/X11 \ -I$(top_builddir)/include \ @@ -300,10 +301,12 @@ AM_CFLAGS = \ -I$(top_srcdir)/src/xcms \ -I$(top_srcdir)/src/xkb \ -I$(top_srcdir)/src/xlibi18n \ + -D_BSD_SOURCE -DXIM_t -DTRANS_CLIENT + +AM_CFLAGS = \ $(X11_CFLAGS) \ $(BIGFONT_CFLAGS) \ $(XDMCP_CFLAGS) \ - -D_BSD_SOURCE -DXIM_t -DTRANS_CLIENT \ $(MALLOC_ZERO_CFLAGS) @XLIB_LOADABLE_I18N_TRUE@commonlibdir = $(X11_LOCALELIBDIR)/common diff --git a/libX11/modules/lc/Makefile.in b/libX11/modules/lc/Makefile.in index dadee07f2..3bc899576 100644 --- a/libX11/modules/lc/Makefile.in +++ b/libX11/modules/lc/Makefile.in @@ -116,6 +116,10 @@ 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@ @@ -123,16 +127,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -141,7 +147,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -151,7 +156,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -162,12 +166,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -177,6 +177,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -215,7 +216,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -247,7 +249,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ diff --git a/libX11/modules/lc/Utf8/Makefile.am b/libX11/modules/lc/Utf8/Makefile.am index d7b096b5c..422b5dc58 100644 --- a/libX11/modules/lc/Utf8/Makefile.am +++ b/libX11/modules/lc/Utf8/Makefile.am @@ -1,4 +1,4 @@ -AM_CFLAGS= \ +AM_CPPFLAGS= \ -I$(top_srcdir)/include \ -I$(top_srcdir)/include/X11 \ -I$(top_builddir)/include \ @@ -6,10 +6,12 @@ AM_CFLAGS= \ -I$(top_srcdir)/src/xcms \ -I$(top_srcdir)/src/xkb \ -I$(top_srcdir)/src/xlibi18n \ + -D_BSD_SOURCE + +AM_CFLAGS= \ $(X11_CFLAGS) \ $(BIGFONT_CFLAGS) \ $(XDMCP_CFLAGS) \ - -D_BSD_SOURCE \ $(MALLOC_ZERO_CFLAGS) if XLIB_LOADABLE_I18N diff --git a/libX11/modules/lc/Utf8/Makefile.in b/libX11/modules/lc/Utf8/Makefile.in index 4078c1c7f..385496e7a 100644 --- a/libX11/modules/lc/Utf8/Makefile.in +++ b/libX11/modules/lc/Utf8/Makefile.in @@ -137,6 +137,10 @@ 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@ @@ -144,16 +148,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -162,7 +168,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -172,7 +177,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -183,12 +187,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -198,6 +198,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -236,7 +237,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -268,7 +270,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -284,7 +285,7 @@ target_alias = @target_alias@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ -AM_CFLAGS = \ +AM_CPPFLAGS = \ -I$(top_srcdir)/include \ -I$(top_srcdir)/include/X11 \ -I$(top_builddir)/include \ @@ -292,10 +293,12 @@ AM_CFLAGS = \ -I$(top_srcdir)/src/xcms \ -I$(top_srcdir)/src/xkb \ -I$(top_srcdir)/src/xlibi18n \ + -D_BSD_SOURCE + +AM_CFLAGS = \ $(X11_CFLAGS) \ $(BIGFONT_CFLAGS) \ $(XDMCP_CFLAGS) \ - -D_BSD_SOURCE \ $(MALLOC_ZERO_CFLAGS) @XLIB_LOADABLE_I18N_TRUE@commonlibdir = $(X11_LOCALELIBDIR)/common diff --git a/libX11/modules/lc/def/Makefile.am b/libX11/modules/lc/def/Makefile.am index 9e9a1a680..fab191e7a 100644 --- a/libX11/modules/lc/def/Makefile.am +++ b/libX11/modules/lc/def/Makefile.am @@ -1,4 +1,4 @@ -AM_CFLAGS= \ +AM_CPPFLAGS= \ -I$(top_srcdir)/include \ -I$(top_srcdir)/include/X11 \ -I$(top_builddir)/include \ @@ -6,10 +6,12 @@ AM_CFLAGS= \ -I$(top_srcdir)/src/xcms \ -I$(top_srcdir)/src/xkb \ -I$(top_srcdir)/src/xlibi18n \ + -D_BSD_SOURCE + +AM_CFLAGS= \ $(X11_CFLAGS) \ $(BIGFONT_CFLAGS) \ - $(XDMCP_CFLAGS) \ - -D_BSD_SOURCE + $(XDMCP_CFLAGS) if XLIB_LOADABLE_I18N diff --git a/libX11/modules/lc/def/Makefile.in b/libX11/modules/lc/def/Makefile.in index b37cec681..9fb1b2ac5 100644 --- a/libX11/modules/lc/def/Makefile.in +++ b/libX11/modules/lc/def/Makefile.in @@ -135,6 +135,10 @@ 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@ @@ -142,16 +146,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -160,7 +166,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -170,7 +175,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -181,12 +185,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -196,6 +196,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -234,7 +235,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -266,7 +268,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -282,7 +283,7 @@ target_alias = @target_alias@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ -AM_CFLAGS = \ +AM_CPPFLAGS = \ -I$(top_srcdir)/include \ -I$(top_srcdir)/include/X11 \ -I$(top_builddir)/include \ @@ -290,10 +291,12 @@ AM_CFLAGS = \ -I$(top_srcdir)/src/xcms \ -I$(top_srcdir)/src/xkb \ -I$(top_srcdir)/src/xlibi18n \ + -D_BSD_SOURCE + +AM_CFLAGS = \ $(X11_CFLAGS) \ $(BIGFONT_CFLAGS) \ - $(XDMCP_CFLAGS) \ - -D_BSD_SOURCE + $(XDMCP_CFLAGS) @XLIB_LOADABLE_I18N_TRUE@commonlibdir = $(X11_LOCALELIBDIR)/common @XLIB_LOADABLE_I18N_TRUE@commonlib_LTLIBRARIES = xlcDef.la diff --git a/libX11/modules/lc/gen/Makefile.am b/libX11/modules/lc/gen/Makefile.am index 2937cb19d..be6497228 100644 --- a/libX11/modules/lc/gen/Makefile.am +++ b/libX11/modules/lc/gen/Makefile.am @@ -1,4 +1,4 @@ -AM_CFLAGS= \ +AM_CPPFLAGS= \ -I$(top_srcdir)/include \ -I$(top_srcdir)/include/X11 \ -I$(top_builddir)/include \ @@ -6,10 +6,12 @@ AM_CFLAGS= \ -I$(top_srcdir)/src/xcms \ -I$(top_srcdir)/src/xkb \ -I$(top_srcdir)/src/xlibi18n \ + -D_BSD_SOURCE + +AM_CFLAGS= \ $(X11_CFLAGS) \ $(BIGFONT_CFLAGS) \ - $(XDMCP_CFLAGS) \ - -D_BSD_SOURCE + $(XDMCP_CFLAGS) if XLIB_LOADABLE_I18N diff --git a/libX11/modules/lc/gen/Makefile.in b/libX11/modules/lc/gen/Makefile.in index 6e2e5229e..9d70b7c6d 100644 --- a/libX11/modules/lc/gen/Makefile.in +++ b/libX11/modules/lc/gen/Makefile.in @@ -135,6 +135,10 @@ 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@ @@ -142,16 +146,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -160,7 +166,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -170,7 +175,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -181,12 +185,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -196,6 +196,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -234,7 +235,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -266,7 +268,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -282,7 +283,7 @@ target_alias = @target_alias@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ -AM_CFLAGS = \ +AM_CPPFLAGS = \ -I$(top_srcdir)/include \ -I$(top_srcdir)/include/X11 \ -I$(top_builddir)/include \ @@ -290,10 +291,12 @@ AM_CFLAGS = \ -I$(top_srcdir)/src/xcms \ -I$(top_srcdir)/src/xkb \ -I$(top_srcdir)/src/xlibi18n \ + -D_BSD_SOURCE + +AM_CFLAGS = \ $(X11_CFLAGS) \ $(BIGFONT_CFLAGS) \ - $(XDMCP_CFLAGS) \ - -D_BSD_SOURCE + $(XDMCP_CFLAGS) @XLIB_LOADABLE_I18N_TRUE@commonlibdir = $(X11_LOCALELIBDIR)/common @XLIB_LOADABLE_I18N_TRUE@commonlib_LTLIBRARIES = xlibi18n.la diff --git a/libX11/modules/lc/xlocale/Makefile.am b/libX11/modules/lc/xlocale/Makefile.am index be8dd41c1..d48d2e96d 100644 --- a/libX11/modules/lc/xlocale/Makefile.am +++ b/libX11/modules/lc/xlocale/Makefile.am @@ -1,4 +1,4 @@ -AM_CFLAGS= \ +AM_CPPFLAGS= \ -I$(top_srcdir)/include \ -I$(top_srcdir)/include/X11 \ -I$(top_builddir)/include \ @@ -6,10 +6,12 @@ AM_CFLAGS= \ -I$(top_srcdir)/src/xcms \ -I$(top_srcdir)/src/xkb \ -I$(top_srcdir)/src/xlibi18n \ + -D_BSD_SOURCE + +AM_CFLAGS= \ $(X11_CFLAGS) \ $(BIGFONT_CFLAGS) \ - $(XDMCP_CFLAGS) \ - -D_BSD_SOURCE + $(XDMCP_CFLAGS) if XLIB_LOADABLE_I18N diff --git a/libX11/modules/lc/xlocale/Makefile.in b/libX11/modules/lc/xlocale/Makefile.in index 7c947ee43..e22e71dda 100644 --- a/libX11/modules/lc/xlocale/Makefile.in +++ b/libX11/modules/lc/xlocale/Makefile.in @@ -135,6 +135,10 @@ 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@ @@ -142,16 +146,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -160,7 +166,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -170,7 +175,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -181,12 +185,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -196,6 +196,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -234,7 +235,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -266,7 +268,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -282,7 +283,7 @@ target_alias = @target_alias@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ -AM_CFLAGS = \ +AM_CPPFLAGS = \ -I$(top_srcdir)/include \ -I$(top_srcdir)/include/X11 \ -I$(top_builddir)/include \ @@ -290,10 +291,12 @@ AM_CFLAGS = \ -I$(top_srcdir)/src/xcms \ -I$(top_srcdir)/src/xkb \ -I$(top_srcdir)/src/xlibi18n \ + -D_BSD_SOURCE + +AM_CFLAGS = \ $(X11_CFLAGS) \ $(BIGFONT_CFLAGS) \ - $(XDMCP_CFLAGS) \ - -D_BSD_SOURCE + $(XDMCP_CFLAGS) @XLIB_LOADABLE_I18N_TRUE@commonlibdir = $(X11_LOCALELIBDIR)/common @XLIB_LOADABLE_I18N_TRUE@commonlib_LTLIBRARIES = xlocale.la diff --git a/libX11/modules/om/Makefile.in b/libX11/modules/om/Makefile.in index e03b58a83..d82ff38e2 100644 --- a/libX11/modules/om/Makefile.in +++ b/libX11/modules/om/Makefile.in @@ -116,6 +116,10 @@ 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@ @@ -123,16 +127,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -141,7 +147,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -151,7 +156,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -162,12 +166,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -177,6 +177,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -215,7 +216,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -247,7 +249,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ diff --git a/libX11/modules/om/generic/Makefile.am b/libX11/modules/om/generic/Makefile.am index 043ee6068..f153b8b98 100644 --- a/libX11/modules/om/generic/Makefile.am +++ b/libX11/modules/om/generic/Makefile.am @@ -1,4 +1,4 @@ -AM_CFLAGS= \ +AM_CPPFLAGS= \ -I$(top_srcdir)/include \ -I$(top_srcdir)/include/X11 \ -I$(top_builddir)/include \ @@ -7,10 +7,12 @@ AM_CFLAGS= \ -I$(top_srcdir)/src/xkb \ -I$(top_srcdir)/src/xlibi18n \ -I$(top_srcdir)/src \ + -D_BSD_SOURCE + +AM_CFLAGS= \ $(X11_CFLAGS) \ $(BIGFONT_CFLAGS) \ $(XDMCP_CFLAGS) \ - -D_BSD_SOURCE \ $(MALLOC_ZERO_CFLAGS) if XLIB_LOADABLE_I18N diff --git a/libX11/modules/om/generic/Makefile.in b/libX11/modules/om/generic/Makefile.in index e39802b44..f9cfeeea4 100644 --- a/libX11/modules/om/generic/Makefile.in +++ b/libX11/modules/om/generic/Makefile.in @@ -138,6 +138,10 @@ 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@ @@ -145,16 +149,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -163,7 +169,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -173,7 +178,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -184,12 +188,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -199,6 +199,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -237,7 +238,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -269,7 +271,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -285,7 +286,7 @@ target_alias = @target_alias@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ -AM_CFLAGS = \ +AM_CPPFLAGS = \ -I$(top_srcdir)/include \ -I$(top_srcdir)/include/X11 \ -I$(top_builddir)/include \ @@ -294,10 +295,12 @@ AM_CFLAGS = \ -I$(top_srcdir)/src/xkb \ -I$(top_srcdir)/src/xlibi18n \ -I$(top_srcdir)/src \ + -D_BSD_SOURCE + +AM_CFLAGS = \ $(X11_CFLAGS) \ $(BIGFONT_CFLAGS) \ $(XDMCP_CFLAGS) \ - -D_BSD_SOURCE \ $(MALLOC_ZERO_CFLAGS) @XLIB_LOADABLE_I18N_TRUE@commonlibdir = $(X11_LOCALELIBDIR)/common diff --git a/libX11/nls/C/Makefile.in b/libX11/nls/C/Makefile.in index 6e3d12a7f..81f8482f5 100644 --- a/libX11/nls/C/Makefile.in +++ b/libX11/nls/C/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/Makefile.am b/libX11/nls/Makefile.am index b4d57ca5e..9a00f9446 100644 --- a/libX11/nls/Makefile.am +++ b/libX11/nls/Makefile.am @@ -75,19 +75,19 @@ SUBDIRS= \ include $(top_srcdir)/cpprules.in locale.alias: locale.alias.pre - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $(srcdir)/locale.alias.pre | $(CPP_SED_MAGIC) > locale.alias.l1 + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $(srcdir)/locale.alias.pre | $(CPP_SED_MAGIC) > locale.alias.l1 sed -e '/^[^#][^ ]*:/s/://' -e '/^[^#].*[ ].*:/d' \ < locale.alias.l1 > locale.alias.l2 cat locale.alias.l2 locale.alias.l1 > locale.alias compose.dir: compose.dir.pre - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $(srcdir)/compose.dir.pre | $(CPP_SED_MAGIC) > compose.dir.l1 + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $(srcdir)/compose.dir.pre | $(CPP_SED_MAGIC) > compose.dir.l1 sed -e '/^[^#][^ ]*:/s/://' -e '/^[^#].*[ ].*:/d' \ < compose.dir.l1 > compose.dir.l2 cat compose.dir.l2 compose.dir.l1 > compose.dir locale.dir: locale.dir.pre - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $(srcdir)/locale.dir.pre | $(CPP_SED_MAGIC) > locale.dir.l1 + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $(srcdir)/locale.dir.pre | $(CPP_SED_MAGIC) > locale.dir.l1 sed -e '/^[^#][^ ]*:/s/://' -e '/^[^#].*[ ].*:/d' \ < locale.dir.l1 > locale.dir.l2 cat locale.dir.l2 locale.dir.l1 > locale.dir diff --git a/libX11/nls/Makefile.in b/libX11/nls/Makefile.in index ca234e4a2..1f15cd1ab 100644 --- a/libX11/nls/Makefile.in +++ b/libX11/nls/Makefile.in @@ -145,6 +145,10 @@ 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@ @@ -152,16 +156,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -170,7 +176,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -180,7 +185,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -191,12 +195,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -206,6 +206,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -244,7 +245,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -276,7 +278,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -381,11 +382,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; all: all-recursive .SUFFIXES: @@ -760,22 +756,22 @@ uninstall-am: uninstall-x11localeDATA .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ locale.alias: locale.alias.pre - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $(srcdir)/locale.alias.pre | $(CPP_SED_MAGIC) > locale.alias.l1 + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $(srcdir)/locale.alias.pre | $(CPP_SED_MAGIC) > locale.alias.l1 sed -e '/^[^#][^ ]*:/s/://' -e '/^[^#].*[ ].*:/d' \ < locale.alias.l1 > locale.alias.l2 cat locale.alias.l2 locale.alias.l1 > locale.alias compose.dir: compose.dir.pre - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $(srcdir)/compose.dir.pre | $(CPP_SED_MAGIC) > compose.dir.l1 + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $(srcdir)/compose.dir.pre | $(CPP_SED_MAGIC) > compose.dir.l1 sed -e '/^[^#][^ ]*:/s/://' -e '/^[^#].*[ ].*:/d' \ < compose.dir.l1 > compose.dir.l2 cat compose.dir.l2 compose.dir.l1 > compose.dir locale.dir: locale.dir.pre - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $(srcdir)/locale.dir.pre | $(CPP_SED_MAGIC) > locale.dir.l1 + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $(srcdir)/locale.dir.pre | $(CPP_SED_MAGIC) > locale.dir.l1 sed -e '/^[^#][^ ]*:/s/://' -e '/^[^#].*[ ].*:/d' \ < locale.dir.l1 > locale.dir.l2 cat locale.dir.l2 locale.dir.l1 > locale.dir diff --git a/libX11/nls/am_ET.UTF-8/Makefile.in b/libX11/nls/am_ET.UTF-8/Makefile.in index b7d905c4b..7233ac42d 100644 --- a/libX11/nls/am_ET.UTF-8/Makefile.in +++ b/libX11/nls/am_ET.UTF-8/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/armscii-8/Makefile.in b/libX11/nls/armscii-8/Makefile.in index c2817ae08..4aeef5122 100644 --- a/libX11/nls/armscii-8/Makefile.in +++ b/libX11/nls/armscii-8/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/el_GR.UTF-8/Makefile.in b/libX11/nls/el_GR.UTF-8/Makefile.in index f3c6566cb..647484ece 100644 --- a/libX11/nls/el_GR.UTF-8/Makefile.in +++ b/libX11/nls/el_GR.UTF-8/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/en_US.UTF-8/Makefile.in b/libX11/nls/en_US.UTF-8/Makefile.in index 6eca0a155..92adad39a 100644 --- a/libX11/nls/en_US.UTF-8/Makefile.in +++ b/libX11/nls/en_US.UTF-8/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/fi_FI.UTF-8/Makefile.in b/libX11/nls/fi_FI.UTF-8/Makefile.in index 98120d6af..4c83858ff 100644 --- a/libX11/nls/fi_FI.UTF-8/Makefile.in +++ b/libX11/nls/fi_FI.UTF-8/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/georgian-academy/Makefile.in b/libX11/nls/georgian-academy/Makefile.in index 18909f216..a70308d8d 100644 --- a/libX11/nls/georgian-academy/Makefile.in +++ b/libX11/nls/georgian-academy/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/georgian-ps/Makefile.in b/libX11/nls/georgian-ps/Makefile.in index bc8a90ad9..0030dc4d8 100644 --- a/libX11/nls/georgian-ps/Makefile.in +++ b/libX11/nls/georgian-ps/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/ibm-cp1133/Makefile.in b/libX11/nls/ibm-cp1133/Makefile.in index 261461814..4496852dc 100644 --- a/libX11/nls/ibm-cp1133/Makefile.in +++ b/libX11/nls/ibm-cp1133/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/iscii-dev/Makefile.in b/libX11/nls/iscii-dev/Makefile.in index 28e202ddc..c23e3e3c5 100644 --- a/libX11/nls/iscii-dev/Makefile.in +++ b/libX11/nls/iscii-dev/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/isiri-3342/Makefile.in b/libX11/nls/isiri-3342/Makefile.in index 39a3d8478..943f0268b 100644 --- a/libX11/nls/isiri-3342/Makefile.in +++ b/libX11/nls/isiri-3342/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/iso8859-1/Makefile.in b/libX11/nls/iso8859-1/Makefile.in index e5f38e8d8..30d574f52 100644 --- a/libX11/nls/iso8859-1/Makefile.in +++ b/libX11/nls/iso8859-1/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/iso8859-10/Makefile.in b/libX11/nls/iso8859-10/Makefile.in index 1255f6ed7..88786f3dc 100644 --- a/libX11/nls/iso8859-10/Makefile.in +++ b/libX11/nls/iso8859-10/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/iso8859-11/Makefile.in b/libX11/nls/iso8859-11/Makefile.in index ea9877b37..fdf7d82dc 100644 --- a/libX11/nls/iso8859-11/Makefile.in +++ b/libX11/nls/iso8859-11/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/iso8859-13/Makefile.in b/libX11/nls/iso8859-13/Makefile.in index ab23c10e3..95b90db08 100644 --- a/libX11/nls/iso8859-13/Makefile.in +++ b/libX11/nls/iso8859-13/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/iso8859-14/Makefile.in b/libX11/nls/iso8859-14/Makefile.in index 38e314b8a..8938ed8a3 100644 --- a/libX11/nls/iso8859-14/Makefile.in +++ b/libX11/nls/iso8859-14/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/iso8859-15/Makefile.in b/libX11/nls/iso8859-15/Makefile.in index 51c955a31..2b5fae03b 100644 --- a/libX11/nls/iso8859-15/Makefile.in +++ b/libX11/nls/iso8859-15/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/iso8859-2/Makefile.in b/libX11/nls/iso8859-2/Makefile.in index bebfc47e2..a6e667b78 100644 --- a/libX11/nls/iso8859-2/Makefile.in +++ b/libX11/nls/iso8859-2/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/iso8859-3/Makefile.in b/libX11/nls/iso8859-3/Makefile.in index 330431f0b..30a2b3ab6 100644 --- a/libX11/nls/iso8859-3/Makefile.in +++ b/libX11/nls/iso8859-3/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/iso8859-4/Makefile.in b/libX11/nls/iso8859-4/Makefile.in index 9b9b7ab7e..ccaf0a52c 100644 --- a/libX11/nls/iso8859-4/Makefile.in +++ b/libX11/nls/iso8859-4/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/iso8859-5/Makefile.in b/libX11/nls/iso8859-5/Makefile.in index d8e2fe680..8da0e0413 100644 --- a/libX11/nls/iso8859-5/Makefile.in +++ b/libX11/nls/iso8859-5/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/iso8859-6/Makefile.in b/libX11/nls/iso8859-6/Makefile.in index d6ccfd2eb..d9a8c8ade 100644 --- a/libX11/nls/iso8859-6/Makefile.in +++ b/libX11/nls/iso8859-6/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/iso8859-7/Makefile.in b/libX11/nls/iso8859-7/Makefile.in index 4c3a4cf2c..2e288aa2e 100644 --- a/libX11/nls/iso8859-7/Makefile.in +++ b/libX11/nls/iso8859-7/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/iso8859-8/Makefile.in b/libX11/nls/iso8859-8/Makefile.in index 515af8b3f..ba2277cae 100644 --- a/libX11/nls/iso8859-8/Makefile.in +++ b/libX11/nls/iso8859-8/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/iso8859-9/Makefile.in b/libX11/nls/iso8859-9/Makefile.in index 0f8e0fbd8..eac8f465c 100644 --- a/libX11/nls/iso8859-9/Makefile.in +++ b/libX11/nls/iso8859-9/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/iso8859-9e/Makefile.in b/libX11/nls/iso8859-9e/Makefile.in index f8b196c7f..26fda2ead 100644 --- a/libX11/nls/iso8859-9e/Makefile.in +++ b/libX11/nls/iso8859-9e/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/ja.JIS/Makefile.in b/libX11/nls/ja.JIS/Makefile.in index 5591cbf54..ca253c09b 100644 --- a/libX11/nls/ja.JIS/Makefile.in +++ b/libX11/nls/ja.JIS/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/ja.S90/Makefile.in b/libX11/nls/ja.S90/Makefile.in index 6ba8cc3e5..7fa06e388 100644 --- a/libX11/nls/ja.S90/Makefile.in +++ b/libX11/nls/ja.S90/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/ja.SJIS/Makefile.in b/libX11/nls/ja.SJIS/Makefile.in index 390dc6386..151d3467e 100644 --- a/libX11/nls/ja.SJIS/Makefile.in +++ b/libX11/nls/ja.SJIS/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/ja.U90/Makefile.in b/libX11/nls/ja.U90/Makefile.in index 277dce85f..44876f6ea 100644 --- a/libX11/nls/ja.U90/Makefile.in +++ b/libX11/nls/ja.U90/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/ja/Makefile.in b/libX11/nls/ja/Makefile.in index 6cd0ede04..35cfa0e5d 100644 --- a/libX11/nls/ja/Makefile.in +++ b/libX11/nls/ja/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/ja_JP.UTF-8/Makefile.in b/libX11/nls/ja_JP.UTF-8/Makefile.in index 857368d34..95be2aa91 100644 --- a/libX11/nls/ja_JP.UTF-8/Makefile.in +++ b/libX11/nls/ja_JP.UTF-8/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/ko/Makefile.in b/libX11/nls/ko/Makefile.in index befcc8180..57574d1c6 100644 --- a/libX11/nls/ko/Makefile.in +++ b/libX11/nls/ko/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/ko_KR.UTF-8/Makefile.in b/libX11/nls/ko_KR.UTF-8/Makefile.in index 4cb0648ba..994f7a8de 100644 --- a/libX11/nls/ko_KR.UTF-8/Makefile.in +++ b/libX11/nls/ko_KR.UTF-8/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/koi8-c/Makefile.in b/libX11/nls/koi8-c/Makefile.in index 3f08bbb84..7d846f4e9 100644 --- a/libX11/nls/koi8-c/Makefile.in +++ b/libX11/nls/koi8-c/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/koi8-r/Makefile.in b/libX11/nls/koi8-r/Makefile.in index 1e3d674a7..844397d7b 100644 --- a/libX11/nls/koi8-r/Makefile.in +++ b/libX11/nls/koi8-r/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/koi8-u/Makefile.in b/libX11/nls/koi8-u/Makefile.in index 507a31e84..b283f2d72 100644 --- a/libX11/nls/koi8-u/Makefile.in +++ b/libX11/nls/koi8-u/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/microsoft-cp1251/Makefile.in b/libX11/nls/microsoft-cp1251/Makefile.in index 0f5168b4e..98cbd7974 100644 --- a/libX11/nls/microsoft-cp1251/Makefile.in +++ b/libX11/nls/microsoft-cp1251/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/microsoft-cp1255/Makefile.in b/libX11/nls/microsoft-cp1255/Makefile.in index 8d333df7e..4d3d3fd5c 100644 --- a/libX11/nls/microsoft-cp1255/Makefile.in +++ b/libX11/nls/microsoft-cp1255/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/microsoft-cp1256/Makefile.in b/libX11/nls/microsoft-cp1256/Makefile.in index 9285052b8..bceaf6551 100644 --- a/libX11/nls/microsoft-cp1256/Makefile.in +++ b/libX11/nls/microsoft-cp1256/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/mulelao-1/Makefile.in b/libX11/nls/mulelao-1/Makefile.in index a6636f527..2462b6b29 100644 --- a/libX11/nls/mulelao-1/Makefile.in +++ b/libX11/nls/mulelao-1/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/nokhchi-1/Makefile.in b/libX11/nls/nokhchi-1/Makefile.in index 4c2cace5c..f12a8b650 100644 --- a/libX11/nls/nokhchi-1/Makefile.in +++ b/libX11/nls/nokhchi-1/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/pt_BR.UTF-8/Makefile.in b/libX11/nls/pt_BR.UTF-8/Makefile.in index 51511c590..86386bb87 100644 --- a/libX11/nls/pt_BR.UTF-8/Makefile.in +++ b/libX11/nls/pt_BR.UTF-8/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/ru_RU.UTF-8/Makefile.in b/libX11/nls/ru_RU.UTF-8/Makefile.in index 682dfc4ec..ec0819866 100644 --- a/libX11/nls/ru_RU.UTF-8/Makefile.in +++ b/libX11/nls/ru_RU.UTF-8/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/tatar-cyr/Makefile.in b/libX11/nls/tatar-cyr/Makefile.in index 5bfdcbab9..d03d5c81a 100644 --- a/libX11/nls/tatar-cyr/Makefile.in +++ b/libX11/nls/tatar-cyr/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/th_TH.UTF-8/Makefile.in b/libX11/nls/th_TH.UTF-8/Makefile.in index 04564e715..f19662b65 100644 --- a/libX11/nls/th_TH.UTF-8/Makefile.in +++ b/libX11/nls/th_TH.UTF-8/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/th_TH/Makefile.in b/libX11/nls/th_TH/Makefile.in index 555654ea8..a0be9ad06 100644 --- a/libX11/nls/th_TH/Makefile.in +++ b/libX11/nls/th_TH/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/tscii-0/Makefile.in b/libX11/nls/tscii-0/Makefile.in index e698344ae..13fb66dd9 100644 --- a/libX11/nls/tscii-0/Makefile.in +++ b/libX11/nls/tscii-0/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/vi_VN.tcvn/Makefile.in b/libX11/nls/vi_VN.tcvn/Makefile.in index 60e1aad3f..38ca1d26c 100644 --- a/libX11/nls/vi_VN.tcvn/Makefile.in +++ b/libX11/nls/vi_VN.tcvn/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/vi_VN.viscii/Makefile.in b/libX11/nls/vi_VN.viscii/Makefile.in index aa88cf235..08b92cd72 100644 --- a/libX11/nls/vi_VN.viscii/Makefile.in +++ b/libX11/nls/vi_VN.viscii/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/zh_CN.UTF-8/Makefile.in b/libX11/nls/zh_CN.UTF-8/Makefile.in index 648a343ac..7a6fb6d51 100644 --- a/libX11/nls/zh_CN.UTF-8/Makefile.in +++ b/libX11/nls/zh_CN.UTF-8/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/zh_CN.gb18030/Makefile.in b/libX11/nls/zh_CN.gb18030/Makefile.in index f8133298d..704a1b96e 100644 --- a/libX11/nls/zh_CN.gb18030/Makefile.in +++ b/libX11/nls/zh_CN.gb18030/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/zh_CN.gbk/Makefile.in b/libX11/nls/zh_CN.gbk/Makefile.in index 16ab2d933..1570db793 100644 --- a/libX11/nls/zh_CN.gbk/Makefile.in +++ b/libX11/nls/zh_CN.gbk/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/zh_CN/Makefile.in b/libX11/nls/zh_CN/Makefile.in index 63c77cfb3..a3d3612de 100644 --- a/libX11/nls/zh_CN/Makefile.in +++ b/libX11/nls/zh_CN/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/zh_HK.UTF-8/Makefile.in b/libX11/nls/zh_HK.UTF-8/Makefile.in index 8d9ec2718..1cb36a1ee 100644 --- a/libX11/nls/zh_HK.UTF-8/Makefile.in +++ b/libX11/nls/zh_HK.UTF-8/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/zh_HK.big5/Makefile.in b/libX11/nls/zh_HK.big5/Makefile.in index 62fb6260b..6ad745f5a 100644 --- a/libX11/nls/zh_HK.big5/Makefile.in +++ b/libX11/nls/zh_HK.big5/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/zh_HK.big5hkscs/Makefile.in b/libX11/nls/zh_HK.big5hkscs/Makefile.in index 60db2a0da..8f287f485 100644 --- a/libX11/nls/zh_HK.big5hkscs/Makefile.in +++ b/libX11/nls/zh_HK.big5hkscs/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/zh_TW.UTF-8/Makefile.in b/libX11/nls/zh_TW.UTF-8/Makefile.in index 999f6c116..7d3fb5d58 100644 --- a/libX11/nls/zh_TW.UTF-8/Makefile.in +++ b/libX11/nls/zh_TW.UTF-8/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/zh_TW.big5/Makefile.in b/libX11/nls/zh_TW.big5/Makefile.in index 845ba6938..c84b05d16 100644 --- a/libX11/nls/zh_TW.big5/Makefile.in +++ b/libX11/nls/zh_TW.big5/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/nls/zh_TW/Makefile.in b/libX11/nls/zh_TW/Makefile.in index fd44de670..61eb68f67 100644 --- a/libX11/nls/zh_TW/Makefile.in +++ b/libX11/nls/zh_TW/Makefile.in @@ -109,6 +109,10 @@ 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@ @@ -116,16 +120,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -134,7 +140,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -144,7 +149,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -155,12 +159,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -170,6 +170,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -208,7 +209,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -240,7 +242,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -275,11 +276,6 @@ CPP_SED_MAGIC = $(SED) -e '/^\# *[0-9][0-9]* *.*$$/d' \ -e 's,X11_LOCALEDATADIR,$(X11_LOCALEDATADIR),g' \ -e '/\@\@$$/s/\@\@$$/\\/' - -# Support for automake 1.11 AM_SILENT_RULES -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose = $(cpp_verbose_$(V)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_ = $(cpp_verbose_$(AM_DEFAULT_VERBOSITY)) -@HAVE_AM_SILENT_RULES_TRUE@cpp_verbose_0 = @echo " CPP " $@; EXTRA_DIST = XLC_LOCALE.pre Compose.pre dist_x11thislocale_DATA = XI18N_OBJS x11thislocale_DATA = XLC_LOCALE Compose @@ -615,7 +611,7 @@ uninstall-am: uninstall-dist_x11thislocaleDATA \ .pre: - $(cpp_verbose)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ + $(AM_V_GEN)$(RAWCPP) $(RAWCPPFLAGS) $(CPP_FILES_FLAGS) < $< | $(CPP_SED_MAGIC) > $@ # 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. diff --git a/libX11/specs/Makefile.am b/libX11/specs/Makefile.am new file mode 100644 index 000000000..4a51cae70 --- /dev/null +++ b/libX11/specs/Makefile.am @@ -0,0 +1,3 @@ +SUBDIRS=libX11 i18n XIM + +EXTRA_DIST=troffrules.in macros.t diff --git a/libX11/specs/Makefile.in b/libX11/specs/Makefile.in new file mode 100644 index 000000000..1b38734f6 --- /dev/null +++ b/libX11/specs/Makefile.in @@ -0,0 +1,618 @@ +# Makefile.in generated by automake 1.11 from Makefile.am. +# @configure_input@ + +# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, +# 2003, 2004, 2005, 2006, 2007, 2008, 2009 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@ +VPATH = @srcdir@ +pkgdatadir = $(datadir)/@PACKAGE@ +pkgincludedir = $(includedir)/@PACKAGE@ +pkglibdir = $(libdir)/@PACKAGE@ +pkglibexecdir = $(libexecdir)/@PACKAGE@ +am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd +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@ +subdir = specs +DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in +ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 +am__aclocal_m4_deps = $(top_srcdir)/acinclude.m4 \ + $(top_srcdir)/configure.ac +am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ + $(ACLOCAL_M4) +mkinstalldirs = $(install_sh) -d +CONFIG_HEADER = $(top_builddir)/src/config.h \ + $(top_builddir)/include/X11/XlibConf.h +CONFIG_CLEAN_FILES = +CONFIG_CLEAN_VPATH_FILES = +AM_V_GEN = $(am__v_GEN_$(V)) +am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY)) +am__v_GEN_0 = @echo " GEN " $@; +AM_V_at = $(am__v_at_$(V)) +am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY)) +am__v_at_0 = @ +SOURCES = +DIST_SOURCES = +RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \ + html-recursive info-recursive install-data-recursive \ + install-dvi-recursive install-exec-recursive \ + install-html-recursive install-info-recursive \ + install-pdf-recursive install-ps-recursive install-recursive \ + installcheck-recursive installdirs-recursive pdf-recursive \ + ps-recursive uninstall-recursive +RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \ + distclean-recursive maintainer-clean-recursive +AM_RECURSIVE_TARGETS = $(RECURSIVE_TARGETS:-recursive=) \ + $(RECURSIVE_CLEAN_TARGETS:-recursive=) tags TAGS ctags CTAGS \ + distdir +ETAGS = etags +CTAGS = ctags +DIST_SUBDIRS = $(SUBDIRS) +DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) +am__relativize = \ + dir0=`pwd`; \ + sed_first='s,^\([^/]*\)/.*$$,\1,'; \ + sed_rest='s,^[^/]*/*,,'; \ + sed_last='s,^.*/\([^/]*\)$$,\1,'; \ + sed_butlast='s,/*[^/]*$$,,'; \ + while test -n "$$dir1"; do \ + first=`echo "$$dir1" | sed -e "$$sed_first"`; \ + if test "$$first" != "."; then \ + if test "$$first" = ".."; then \ + dir2=`echo "$$dir0" | sed -e "$$sed_last"`/"$$dir2"; \ + dir0=`echo "$$dir0" | sed -e "$$sed_butlast"`; \ + else \ + first2=`echo "$$dir2" | sed -e "$$sed_first"`; \ + if test "$$first2" = "$$first"; then \ + dir2=`echo "$$dir2" | sed -e "$$sed_rest"`; \ + else \ + dir2="../$$dir2"; \ + fi; \ + dir0="$$dir0"/"$$first"; \ + fi; \ + fi; \ + dir1=`echo "$$dir1" | sed -e "$$sed_rest"`; \ + done; \ + reldir="$$dir2" +ACLOCAL = @ACLOCAL@ +ADMIN_MAN_DIR = @ADMIN_MAN_DIR@ +ADMIN_MAN_SUFFIX = @ADMIN_MAN_SUFFIX@ +AMTAR = @AMTAR@ +AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ +APP_MAN_DIR = @APP_MAN_DIR@ +APP_MAN_SUFFIX = @APP_MAN_SUFFIX@ +AR = @AR@ +AUTOCONF = @AUTOCONF@ +AUTOHEADER = @AUTOHEADER@ +AUTOMAKE = @AUTOMAKE@ +AWK = @AWK@ +BIGFONT_CFLAGS = @BIGFONT_CFLAGS@ +BIGFONT_LIBS = @BIGFONT_LIBS@ +CC = @CC@ +CCDEPMODE = @CCDEPMODE@ +CC_FOR_BUILD = @CC_FOR_BUILD@ +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@ +DOLT_BASH = @DOLT_BASH@ +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@ +EXEEXT = @EXEEXT@ +F77 = @F77@ +FFLAGS = @FFLAGS@ +FILE_MAN_DIR = @FILE_MAN_DIR@ +FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ +GREP = @GREP@ +GROFF = @GROFF@ +I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ +INSTALL = @INSTALL@ +INSTALL_DATA = @INSTALL_DATA@ +INSTALL_PROGRAM = @INSTALL_PROGRAM@ +INSTALL_SCRIPT = @INSTALL_SCRIPT@ +INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ +KEYSYMDEF = @KEYSYMDEF@ +LAUNCHD = @LAUNCHD@ +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_FLAGS = @LINT_FLAGS@ +LN_S = @LN_S@ +LTCOMPILE = @LTCOMPILE@ +LTCXXCOMPILE = @LTCXXCOMPILE@ +LTLIBOBJS = @LTLIBOBJS@ +MAINT = @MAINT@ +MAKEINFO = @MAKEINFO@ +MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ +MISC_MAN_DIR = @MISC_MAN_DIR@ +MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ +MKDIR_P = @MKDIR_P@ +NMEDIT = @NMEDIT@ +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@ +PERL = @PERL@ +PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ +RANLIB = @RANLIB@ +RAWCPP = @RAWCPP@ +RAWCPPFLAGS = @RAWCPPFLAGS@ +SED = @SED@ +SET_MAKE = @SET_MAKE@ +SHELL = @SHELL@ +STRIP = @STRIP@ +VERSION = @VERSION@ +WCHAR32 = @WCHAR32@ +X11_CFLAGS = @X11_CFLAGS@ +X11_DATADIR = @X11_DATADIR@ +X11_EXTRA_DEPS = @X11_EXTRA_DEPS@ +X11_LIBDIR = @X11_LIBDIR@ +X11_LIBS = @X11_LIBS@ +X11_LOCALEDATADIR = @X11_LOCALEDATADIR@ +X11_LOCALEDIR = @X11_LOCALEDIR@ +X11_LOCALELIBDIR = @X11_LOCALELIBDIR@ +XDMCP_CFLAGS = @XDMCP_CFLAGS@ +XDMCP_LIBS = @XDMCP_LIBS@ +XERRORDB = @XERRORDB@ +XKBPROTO_CFLAGS = @XKBPROTO_CFLAGS@ +XKBPROTO_LIBS = @XKBPROTO_LIBS@ +XKBPROTO_REQUIRES = @XKBPROTO_REQUIRES@ +XKEYSYMDB = @XKEYSYMDB@ +XLOCALEDATADIR = @XLOCALEDATADIR@ +XLOCALEDIR = @XLOCALEDIR@ +XLOCALELIBDIR = @XLOCALELIBDIR@ +XMALLOC_ZERO_CFLAGS = @XMALLOC_ZERO_CFLAGS@ +XPROTO_CFLAGS = @XPROTO_CFLAGS@ +XPROTO_LIBS = @XPROTO_LIBS@ +XTHREADLIB = @XTHREADLIB@ +XTHREAD_CFLAGS = @XTHREAD_CFLAGS@ +XTMALLOC_ZERO_CFLAGS = @XTMALLOC_ZERO_CFLAGS@ +abs_builddir = @abs_builddir@ +abs_srcdir = @abs_srcdir@ +abs_top_builddir = @abs_top_builddir@ +abs_top_srcdir = @abs_top_srcdir@ +ac_ct_CC = @ac_ct_CC@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ +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@ +builddir = @builddir@ +datadir = @datadir@ +datarootdir = @datarootdir@ +distcleancheck_listfiles = @distcleancheck_listfiles@ +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@ +srcdir = @srcdir@ +sysconfdir = @sysconfdir@ +target_alias = @target_alias@ +top_build_prefix = @top_build_prefix@ +top_builddir = @top_builddir@ +top_srcdir = @top_srcdir@ +SUBDIRS = libX11 i18n XIM +EXTRA_DIST = troffrules.in macros.t +all: all-recursive + +.SUFFIXES: +$(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 ) \ + && { if test -f $@; then exit 0; else break; fi; }; \ + exit 1;; \ + esac; \ + done; \ + echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign specs/Makefile'; \ + $(am__cd) $(top_srcdir) && \ + $(AUTOMAKE) --foreign specs/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 +$(am__aclocal_m4_deps): + +mostlyclean-libtool: + -rm -f *.lo + +clean-libtool: + -rm -rf .libs _libs + +# 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; \ + ($(am__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" + +$(RECURSIVE_CLEAN_TARGETS): + @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; \ + ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \ + || eval $$failcom; \ + done && test -z "$$fail" +tags-recursive: + list='$(SUBDIRS)'; for subdir in $$list; do \ + test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) tags); \ + done +ctags-recursive: + list='$(SUBDIRS)'; for subdir in $$list; do \ + test "$$subdir" = . || ($(am__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 \ + if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ + done | \ + $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in files) print i; }; }'`; \ + mkid -fID $$unique +tags: TAGS + +TAGS: tags-recursive $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ + $(TAGS_FILES) $(LISP) + set x; \ + 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 || \ + set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \ + fi; \ + done; \ + list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ + unique=`for i in $$list; do \ + if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ + done | \ + $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in files) print i; }; }'`; \ + shift; \ + if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ + test -n "$$unique" || unique=$$empty_fix; \ + if test $$# -gt 0; then \ + $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ + "$$@" $$unique; \ + else \ + $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ + $$unique; \ + fi; \ + fi +ctags: CTAGS +CTAGS: ctags-recursive $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ + $(TAGS_FILES) $(LISP) + list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ + unique=`for i in $$list; do \ + if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ + done | \ + $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ + END { if (nonempty) { for (i in files) print i; }; }'`; \ + test -z "$(CTAGS_ARGS)$$unique" \ + || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ + $$unique + +GTAGS: + here=`$(am__cd) $(top_builddir) && pwd` \ + && $(am__cd) $(top_srcdir) \ + && gtags -i $(GTAGS_ARGS) "$$here" + +distclean-tags: + -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags + +distdir: $(DISTFILES) + @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + list='$(DISTFILES)'; \ + dist_files=`for file in $$list; do echo $$file; done | \ + sed -e "s|^$$srcdirstrip/||;t" \ + -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ + case $$dist_files in \ + */*) $(MKDIR_P) `echo "$$dist_files" | \ + sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ + sort -u` ;; \ + esac; \ + for file in $$dist_files; do \ + if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ + if test -d $$d/$$file; then \ + dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ + if test -d "$(distdir)/$$file"; then \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ + cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ + else \ + test -f "$(distdir)/$$file" \ + || cp -p $$d/$$file "$(distdir)/$$file" \ + || 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; \ + fi; \ + done + @list='$(DIST_SUBDIRS)'; for subdir in $$list; do \ + if test "$$subdir" = .; then :; else \ + dir1=$$subdir; dir2="$(distdir)/$$subdir"; \ + $(am__relativize); \ + new_distdir=$$reldir; \ + dir1=$$subdir; dir2="$(top_distdir)"; \ + $(am__relativize); \ + new_top_distdir=$$reldir; \ + echo " (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir="$$new_top_distdir" distdir="$$new_distdir" \\"; \ + echo " am__remove_distdir=: am__skip_length_check=: am__skip_mode_fix=: distdir)"; \ + ($(am__cd) $$subdir && \ + $(MAKE) $(AM_MAKEFLAGS) \ + top_distdir="$$new_top_distdir" \ + distdir="$$new_distdir" \ + am__remove_distdir=: \ + am__skip_length_check=: \ + am__skip_mode_fix=: \ + distdir) \ + || exit 1; \ + fi; \ + done +check-am: all-am +check: check-recursive +all-am: Makefile +installdirs: installdirs-recursive +installdirs-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-recursive +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: + +distclean-generic: + -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) + -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_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-recursive + +clean-am: clean-generic clean-libtool mostlyclean-am + +distclean: distclean-recursive + -rm -f Makefile +distclean-am: clean-am distclean-generic distclean-tags + +dvi: dvi-recursive + +dvi-am: + +html: html-recursive + +html-am: + +info: info-recursive + +info-am: + +install-data-am: + +install-dvi: install-dvi-recursive + +install-dvi-am: + +install-exec-am: + +install-html: install-html-recursive + +install-html-am: + +install-info: install-info-recursive + +install-info-am: + +install-man: + +install-pdf: install-pdf-recursive + +install-pdf-am: + +install-ps: install-ps-recursive + +install-ps-am: + +installcheck-am: + +maintainer-clean: maintainer-clean-recursive + -rm -f Makefile +maintainer-clean-am: distclean-am maintainer-clean-generic + +mostlyclean: mostlyclean-recursive + +mostlyclean-am: mostlyclean-generic mostlyclean-libtool + +pdf: pdf-recursive + +pdf-am: + +ps: ps-recursive + +ps-am: + +uninstall-am: + +.MAKE: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) ctags-recursive \ + install-am install-strip tags-recursive + +.PHONY: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) CTAGS GTAGS \ + all all-am check check-am clean clean-generic clean-libtool \ + ctags ctags-recursive distclean distclean-generic \ + distclean-libtool distclean-tags distdir dvi dvi-am html \ + html-am info info-am install install-am install-data \ + install-data-am install-dvi install-dvi-am install-exec \ + install-exec-am install-html install-html-am install-info \ + install-info-am install-man install-pdf install-pdf-am \ + install-ps install-ps-am install-strip installcheck \ + installcheck-am installdirs installdirs-am maintainer-clean \ + maintainer-clean-generic mostlyclean mostlyclean-generic \ + mostlyclean-libtool pdf pdf-am ps ps-am tags tags-recursive \ + uninstall uninstall-am + + +# 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/libX11/specs/XIM/Makefile.am b/libX11/specs/XIM/Makefile.am new file mode 100644 index 000000000..c76a3f720 --- /dev/null +++ b/libX11/specs/XIM/Makefile.am @@ -0,0 +1,33 @@ +# +# Copyright 2009 Sun Microsystems, Inc. All rights reserved. +# +# 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 copyright holders 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 copyright holders. +# + +# Based on xc/doc/specs/XIM/Makefile from X11R6.9 + +doc_sources = xim.ms + +include $(top_srcdir)/specs/troffrules.in + + diff --git a/libX11/specs/XIM/Makefile.in b/libX11/specs/XIM/Makefile.in new file mode 100644 index 000000000..73392a119 --- /dev/null +++ b/libX11/specs/XIM/Makefile.in @@ -0,0 +1,554 @@ +# Makefile.in generated by automake 1.11 from Makefile.am. +# @configure_input@ + +# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, +# 2003, 2004, 2005, 2006, 2007, 2008, 2009 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 2009 Sun Microsystems, Inc. All rights reserved. +# +# 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 copyright holders 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 copyright holders. +# + +# Based on xc/doc/specs/XIM/Makefile from X11R6.9 + +# +# Copyright 2009 Sun Microsystems, Inc. All rights reserved. +# +# 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 copyright holders 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 copyright holders. +# + +# Based on xc/doc/specs/*/Makefile from X11R6.9 + +VPATH = @srcdir@ +pkgdatadir = $(datadir)/@PACKAGE@ +pkgincludedir = $(includedir)/@PACKAGE@ +pkglibdir = $(libdir)/@PACKAGE@ +pkglibexecdir = $(libexecdir)/@PACKAGE@ +am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd +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@ +DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in \ + $(top_srcdir)/specs/troffrules.in +subdir = specs/XIM +ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 +am__aclocal_m4_deps = $(top_srcdir)/acinclude.m4 \ + $(top_srcdir)/configure.ac +am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ + $(ACLOCAL_M4) +mkinstalldirs = $(install_sh) -d +CONFIG_HEADER = $(top_builddir)/src/config.h \ + $(top_builddir)/include/X11/XlibConf.h +CONFIG_CLEAN_FILES = +CONFIG_CLEAN_VPATH_FILES = +AM_V_GEN = $(am__v_GEN_$(V)) +am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY)) +am__v_GEN_0 = @echo " GEN " $@; +AM_V_at = $(am__v_at_$(V)) +am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY)) +am__v_at_0 = @ +SOURCES = +DIST_SOURCES = +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 = f=`echo $$p | sed -e 's|^.*/||'`; +am__install_max = 40 +am__nobase_strip_setup = \ + srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'` +am__nobase_strip = \ + for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||" +am__nobase_list = $(am__nobase_strip_setup); \ + for p in $$list; do echo "$$p $$p"; done | \ + sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \ + $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \ + if (++n[$$2] == $(am__install_max)) \ + { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \ + END { for (dir in files) print dir, files[dir] }' +am__base_list = \ + sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ + sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' +am__installdirs = "$(DESTDIR)$(docdir)" +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@ +AMTAR = @AMTAR@ +AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ +APP_MAN_DIR = @APP_MAN_DIR@ +APP_MAN_SUFFIX = @APP_MAN_SUFFIX@ +AR = @AR@ +AUTOCONF = @AUTOCONF@ +AUTOHEADER = @AUTOHEADER@ +AUTOMAKE = @AUTOMAKE@ +AWK = @AWK@ +BIGFONT_CFLAGS = @BIGFONT_CFLAGS@ +BIGFONT_LIBS = @BIGFONT_LIBS@ +CC = @CC@ +CCDEPMODE = @CCDEPMODE@ +CC_FOR_BUILD = @CC_FOR_BUILD@ +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@ +DOLT_BASH = @DOLT_BASH@ +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@ +EXEEXT = @EXEEXT@ +F77 = @F77@ +FFLAGS = @FFLAGS@ +FILE_MAN_DIR = @FILE_MAN_DIR@ +FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ +GREP = @GREP@ +GROFF = @GROFF@ +I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ +INSTALL = @INSTALL@ +INSTALL_DATA = @INSTALL_DATA@ +INSTALL_PROGRAM = @INSTALL_PROGRAM@ +INSTALL_SCRIPT = @INSTALL_SCRIPT@ +INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ +KEYSYMDEF = @KEYSYMDEF@ +LAUNCHD = @LAUNCHD@ +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_FLAGS = @LINT_FLAGS@ +LN_S = @LN_S@ +LTCOMPILE = @LTCOMPILE@ +LTCXXCOMPILE = @LTCXXCOMPILE@ +LTLIBOBJS = @LTLIBOBJS@ +MAINT = @MAINT@ +MAKEINFO = @MAKEINFO@ +MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ +MISC_MAN_DIR = @MISC_MAN_DIR@ +MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ +MKDIR_P = @MKDIR_P@ +NMEDIT = @NMEDIT@ +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@ +PERL = @PERL@ +PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ +RANLIB = @RANLIB@ +RAWCPP = @RAWCPP@ +RAWCPPFLAGS = @RAWCPPFLAGS@ +SED = @SED@ +SET_MAKE = @SET_MAKE@ +SHELL = @SHELL@ +STRIP = @STRIP@ +VERSION = @VERSION@ +WCHAR32 = @WCHAR32@ +X11_CFLAGS = @X11_CFLAGS@ +X11_DATADIR = @X11_DATADIR@ +X11_EXTRA_DEPS = @X11_EXTRA_DEPS@ +X11_LIBDIR = @X11_LIBDIR@ +X11_LIBS = @X11_LIBS@ +X11_LOCALEDATADIR = @X11_LOCALEDATADIR@ +X11_LOCALEDIR = @X11_LOCALEDIR@ +X11_LOCALELIBDIR = @X11_LOCALELIBDIR@ +XDMCP_CFLAGS = @XDMCP_CFLAGS@ +XDMCP_LIBS = @XDMCP_LIBS@ +XERRORDB = @XERRORDB@ +XKBPROTO_CFLAGS = @XKBPROTO_CFLAGS@ +XKBPROTO_LIBS = @XKBPROTO_LIBS@ +XKBPROTO_REQUIRES = @XKBPROTO_REQUIRES@ +XKEYSYMDB = @XKEYSYMDB@ +XLOCALEDATADIR = @XLOCALEDATADIR@ +XLOCALEDIR = @XLOCALEDIR@ +XLOCALELIBDIR = @XLOCALELIBDIR@ +XMALLOC_ZERO_CFLAGS = @XMALLOC_ZERO_CFLAGS@ +XPROTO_CFLAGS = @XPROTO_CFLAGS@ +XPROTO_LIBS = @XPROTO_LIBS@ +XTHREADLIB = @XTHREADLIB@ +XTHREAD_CFLAGS = @XTHREAD_CFLAGS@ +XTMALLOC_ZERO_CFLAGS = @XTMALLOC_ZERO_CFLAGS@ +abs_builddir = @abs_builddir@ +abs_srcdir = @abs_srcdir@ +abs_top_builddir = @abs_top_builddir@ +abs_top_srcdir = @abs_top_srcdir@ +ac_ct_CC = @ac_ct_CC@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ +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@ +builddir = @builddir@ +datadir = @datadir@ +datarootdir = @datarootdir@ +distcleancheck_listfiles = @distcleancheck_listfiles@ +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@ +srcdir = @srcdir@ +sysconfdir = @sysconfdir@ +target_alias = @target_alias@ +top_build_prefix = @top_build_prefix@ +top_builddir = @top_builddir@ +top_srcdir = @top_srcdir@ +doc_sources = xim.ms +EXTRA_DIST = $(doc_sources) +@HAVE_PS2PDF_FALSE@printable_format = .ps +@HAVE_PS2PDF_TRUE@printable_format = .pdf +@BUILD_SPECS_TRUE@doc_DATA = $(doc_sources:.ms=.txt) \ +@BUILD_SPECS_TRUE@ $(doc_sources:.ms=$(printable_format)) \ +@BUILD_SPECS_TRUE@ $(doc_sources:.ms=.html) + +@BUILD_SPECS_TRUE@CLEANFILES = $(doc_DATA) +@BUILD_SPECS_TRUE@MOSTLYCLEANFILES = index.* + +# Pass version string as a troff string for substitution +@BUILD_SPECS_TRUE@GROFF_DEFS = -dxV="$(PACKAGE_STRING)" + +# -e to run through eqn, -t to run through tbl +@BUILD_SPECS_TRUE@GROFF_FLAGS = -e -t -ms $(GROFF_DEFS) $(top_srcdir)/specs/macros.t +@BUILD_SPECS_TRUE@SUFFIXES = .ms .ps .txt .html .pdf +all: all-am + +.SUFFIXES: +.SUFFIXES: .ms .ps .txt .html .pdf +$(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(top_srcdir)/specs/troffrules.in $(am__configure_deps) + @for dep in $?; do \ + case '$(am__configure_deps)' in \ + *$$dep*) \ + ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ + && { if test -f $@; then exit 0; else break; fi; }; \ + exit 1;; \ + esac; \ + done; \ + echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign specs/XIM/Makefile'; \ + $(am__cd) $(top_srcdir) && \ + $(AUTOMAKE) --foreign specs/XIM/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 +$(am__aclocal_m4_deps): + +mostlyclean-libtool: + -rm -f *.lo + +clean-libtool: + -rm -rf .libs _libs +install-docDATA: $(doc_DATA) + @$(NORMAL_INSTALL) + test -z "$(docdir)" || $(MKDIR_P) "$(DESTDIR)$(docdir)" + @list='$(doc_DATA)'; test -n "$(docdir)" || list=; \ + for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + echo "$$d$$p"; \ + done | $(am__base_list) | \ + while read files; do \ + echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(docdir)'"; \ + $(INSTALL_DATA) $$files "$(DESTDIR)$(docdir)" || exit $$?; \ + done + +uninstall-docDATA: + @$(NORMAL_UNINSTALL) + @list='$(doc_DATA)'; test -n "$(docdir)" || list=; \ + files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ + test -n "$$files" || exit 0; \ + echo " ( cd '$(DESTDIR)$(docdir)' && rm -f" $$files ")"; \ + cd "$(DESTDIR)$(docdir)" && rm -f $$files +tags: TAGS +TAGS: + +ctags: CTAGS +CTAGS: + + +distdir: $(DISTFILES) + @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + list='$(DISTFILES)'; \ + dist_files=`for file in $$list; do echo $$file; done | \ + sed -e "s|^$$srcdirstrip/||;t" \ + -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ + case $$dist_files in \ + */*) $(MKDIR_P) `echo "$$dist_files" | \ + sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ + sort -u` ;; \ + esac; \ + for file in $$dist_files; do \ + if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ + if test -d $$d/$$file; then \ + dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ + if test -d "$(distdir)/$$file"; then \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ + cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + cp -fpR $$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)"; 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: + -test -z "$(MOSTLYCLEANFILES)" || rm -f $(MOSTLYCLEANFILES) + +clean-generic: + -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES) + +distclean-generic: + -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) + -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_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 + +dvi: dvi-am + +dvi-am: + +html: html-am + +html-am: + +info: info-am + +info-am: + +install-data-am: install-docDATA + +install-dvi: install-dvi-am + +install-dvi-am: + +install-exec-am: + +install-html: install-html-am + +install-html-am: + +install-info: install-info-am + +install-info-am: + +install-man: + +install-pdf: install-pdf-am + +install-pdf-am: + +install-ps: install-ps-am + +install-ps-am: + +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-docDATA + +.MAKE: install-am install-strip + +.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-docDATA install-dvi \ + install-dvi-am install-exec install-exec-am install-html \ + install-html-am install-info install-info-am install-man \ + install-pdf install-pdf-am install-ps install-ps-am \ + 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-docDATA + + +@BUILD_SPECS_TRUE@.ms.ps: +@BUILD_SPECS_TRUE@ -$(AM_V_GEN) $(GROFF) -Tps $(GROFF_FLAGS) $< 2> index.$@.raw > $@ +@BUILD_SPECS_TRUE@ @if grep '^[^1-9.]' index.$@.raw | grep -v warning; then exit 1; \ +@BUILD_SPECS_TRUE@ else test $$? -le 1; fi + +@BUILD_SPECS_TRUE@.ms.txt: +@BUILD_SPECS_TRUE@ $(AM_V_GEN) env GROFF_NO_SGR=TRUE $(GROFF) -Tutf8 $(GROFF_FLAGS) \ +@BUILD_SPECS_TRUE@ $< 2> index.$@.raw > $@ + +@BUILD_SPECS_TRUE@.ms.html: +@BUILD_SPECS_TRUE@ $(AM_V_GEN) $(GROFF) -Thtml $(GROFF_FLAGS) $< 2> index.$@.raw > $@ + +@BUILD_SPECS_TRUE@.ps.pdf: +@BUILD_SPECS_TRUE@ $(AM_V_GEN) $(PS2PDF) $< $@ + +# 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/libX11/specs/XIM/xim.ms b/libX11/specs/XIM/xim.ms new file mode 100644 index 000000000..e41e9bcab --- /dev/null +++ b/libX11/specs/XIM/xim.ms @@ -0,0 +1,4279 @@ +.\" $Xorg: xim.ms,v 1.3 2000/08/17 19:42:21 cpqbld Exp $ +.\" To print this out, type tbl macros.t ThisFile | troff -ms +.\" $XFree86: xc/doc/specs/XIM/xim.ms,v 1.2 2000/12/14 17:48:58 dawes Exp $ +.EH '''' +.OH '''' +.EF '''' +.OF '''' +.ps 11 +.nr PS 11 +\& +.sp 8 +.TL +\s+3\fBThe Input Method Protocol\fP\s-3 +.sp +\fBVersion 1.0\fP +.sp +\fBX Consortium Standard\fP +.sp +\fBX Version 11, Release 7\fP +.sp +\fB\*(xV\fP +.sp 3 +.AU +Masahiko Narita +.AI +FUJITSU Limited. +.AU +Hideki Hiura +.AI +SunSoft, Inc. +.sp 3 +.AB +.LP +This specifies a protocol between IM library and IM (Input Method) +Server for internationalized text input, which is independent from +any specific language, any specific input method and the transport layer +used in communication between the IM library and the IM Server, and uses +a client-server model. +This protocol allows user to use his/her favorite input method for all +applications within the stand-alone distributed environment. +.AE +.ce 0 +.br +\& +.LP +.ps 11 +.nr PS 11 +.bp +\& +.ps 9 +.nr PS 9 +.sp 8 +.LP +.DS C +X Window System is a trademark of X Consortium, Inc. +.sp +Copyright \(co 1993, 1994 by X Consortium, Inc. +.DE +.sp 2 +.LP +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: +.LP +The above copyright notice and this permission notice shall be included +in all copies or substantial portions of the Software. +.LP +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 X CONSORTIUM 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. +.LP +Except as contained in this notice, the name of the X Consortium 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 X Consortium. +.sp 3 +.DS C +Copyright \(co 1993, 1994 by FUJITSU LIMITED +.sp +Copyright \(co 1993, 1994 by Sun Microsystems, Inc. +.DE +.sp 2 +.LP +Permission to use, copy, modify, and distribute this documentation +for any purpose and without fee is hereby granted, provided +that the above copyright notice and this permission +notice appear in all copies. +Fujitsu and Sun Microsystems make no representations +about the suitability for any purpose of the information in this document. +This documentation is provided as is without express or implied warranty. +.ps 11 +.nr PS 11 +.bp 1 +.EH '\fBX Input Method Protocol\fP''\fB\*(xV\fP' +.OH '\fBX Input Method Protocol\fP''\fB\*(xV\fP' +.EF ''\fB % \fP'' +.OF ''\fB % \fP'' +.NH 1 +Introduction +.XS +\*(SN Introduction +.XE +.NH 2 +Scope +.XS +\*(SN Scope +.XE +.LP +The internationalization in the +X Window System +Version 11, Release 5 (X11R5) provides a common API which application +developers can use to create portable internationalized programs and to +adapt them to the requirements of different native languages, local customs, +and character string encodings (this is called ``localization''). +As one of its internationalization mechanisms X11R5 has defined a functional +interface for internationalized text input, called XIM (X Input Method). +.LP +When a client-server model is used with an IM (Input Method) implementation, +a protocol must be established between the client and the server. +However, the protocol used to interface Input Method Servers (IM Servers) +with the Input Method libraries (IM libraries) to which applications are +linked was not addressed in X11R5. +This led application developers to depend on vendor-specific input methods, +decreased the user's choice of available input methods, and made it more +difficult for developers to create portable applications. This paper describes +the Input Method Protocol developed for X11R6 to resolve the above problems +and to address the requirements of existing and future input methods. +.LP +The Input Method Protocol is independent from the transport layer used in +communication between the IM library and the IM Server. +Thus, the input method protocol can be built on any inter-process +communication mechanism, such as TCP/IP or the X protocol. +.LP +In addition, the protocol provides for future extensions such as differing +input model types. +.LP +.NH 2 +Background +.XS +\*(SN Background +.XE +.LP +Text input is much more simple for some languages than +others. English, for instance, uses an alphabet of a manageable size, +and input consists of pressing the corresponding key on a keyboard, +perhaps in combination with a shift key for capital letters or special +characters. +.LP +Some languages have larger alphabets, or modifiers such as accents, +which require the addition of special key combinations in order to enter +text. These input methods may require ``dead-keys'' or ``compose-keys'' +which, when followed by different combinations of key strokes, +generate different characters. +.LP +Text input for ideographic languages is much less simple. In these +languages, characters represent actual objects rather than phonetic +sounds used in pronouncing a word, and the number of characters +in these languages may continue to grow. In Japanese, for instance, most +text input methods involve entering characters in a phonetic alphabet, +after which the input method searches a dictionary for possible +ideographic equivalents (of which there may be many). The input method then +presents the candidate characters for the user to choose from. +.LP +In Japanese, either Kana (phonetic symbols) or Roman letters are +typed and then a region is selected for conversion to Kanji. Several +Kanji characters may have the same phonetic representation. If that +is the case with the string entered, a menu of characters is presented +and the user must choose the appropriate one. If no choice is necessary +or a preference has been established, the input method does the +substitution directly. +.LP +These complicated input methods must present state information (Status Area), +text entry and edit space (Preedit Area), and menu/choice presentations +(Auxiliary Area). Much of the protocol between the IM library and the IM +Server involves managing these IM areas. +Because of the size and complexity of these input methods, and because +of how widely they vary from one language or locale to another, they are +usually implemented as separate processes which can serve many client +processes on the same computer or network. +.LP +.NH 2 +Input Method Styles +.XS +\*(SN Input Method Styles +.XE +.LP +X11 internationalization support includes the following four types of +input method: +.RS +.IP "- on-the-spot:" 20 +The client application is directed by the IM Server to display all +pre-edit data at the site of text insertion. The client registers +callbacks invoked by the input method during pre-editing. +.IP "- off-the-spot:" 20 +The client application provides display windows for the pre-edit data +to the input method which displays into them directly. +.IP "- over-the-spot:" 20 +The input method displays pre-edit data in a window which it brings up +directly over the text insertion position. +.IP "- root-window:" 20 +The input method displays all pre-edit data in a separate area of the +screen in a window specific to the input method. +.RE +.LP +Client applications must choose from the available input methods +supported by the IM Server and provide the display areas and callbacks +required by the input method. +.LP +.NH 1 +Architecture +.XS +\*(SN Architecture +.XE +.NH 2 +Implementation Model +.XS +\*(SN Implementation Model +.XE +.LP +Within the X Window System environment, the following two typical +architectural models can be used as an input method's implementation +model. +.RS +.IP "- Client/Server model:" 20 +A separate process, the IM Server, processes input and handles preediting, +converting, and committing. The IM library within the application, acting +as client to the IM Server, simply receives the committed string from the +IM Server. +.IP "- Library model:" 20 +All input is handled by the IM library within the application. The +event process is closed within the IM library and a separate IM Server +process may not be required. +.RE +.LP +Most languages which need complex preediting, such as Asian languages, +are implemented using the Client/Server IM model. Other languages +which need only dead key or compose key processing, such as European +languages, are implemented using the Library model. +.LP +In this paper, we discuss mainly the Client/Server IM model and the +protocol used in communication between the IM library (client) and the IM +Server. +.LP +.NH 2 +Structure of IM +.XS +\*(SN Structure of IM +.XE +.LP +When the client connects or disconnects to the IM Server, an open or close +operation occurs between the client and the IM Server. +.LP +The IM can be specified at the time of XOpenIM() by setting the locale +of the client and a locale modifier. Since the IM remembers +the locale at the time of creation XOpenIM() can be called +multiple times (with the +setting for the locale and the locale modifier changed) to support +multiple languages. +.LP +In addition, the supported IM type can be obtained using XGetIMValues(). +.LP +The client usually holds multiple input (text) fields. Xlib provides a +value type called the ``Input Context'' (IC) to manage each individual +input field. An IC can be created by specifying XIM using XCreateIC(), +and it can be destroyed using XDestroyIC(). +.LP +The IC can specify the type of IM which is supported by XIM for each +input field, so each input field can handle a different type of IM. +.LP +Most importantly information such as the committed string sent from +the IM Server to the client, is exchanged based on each IC. +.LP +Since each IC corresponds to an input field, the focused input field +should be announced to the IM Server using XSetICFocus(). (XUnsetICFocus() +can also be used to change the focus.) +.LP +.NH 2 +Event Handling Model +.XS +\*(SN Event Handling Model +.XE +.LP +Existing input methods support either the FrontEnd method, the BackEnd method, +or both. This protocol specifically supports the BackEnd method as +the default method, but also supports the FrontEnd method as an optional +IM Server extension. +.LP +The difference between the FrontEnd and BackEnd methods is in how +events are delivered to the IM Server. (Fig. 1) +.LP +.NH 3 +BackEnd Method +.XS +\*(SN BackEnd Method +.XE +.LP +In the BackEnd method, client window input events are always delivered +to the IM library, which then passes them to the IM Server. Events are +handled serially in the order delivered, and therefore there is no +synchronization problem between the IM library and the IM Server. +.LP +Using this method, the IM library forwards all KeyPress and KeyRelease +events to the IM Server (as required by the Event Flow Control model +described in section 2.4. ``Event Flow Control''), and synchronizes +with the IM Server (as described in section 4.16. ``Filtering Events''). +.LP +.NH 3 +FrontEnd Method +.XS +\*(SN FrontEnd Method +.XE +.LP +In the FrontEnd method, client window input events are delivered by the +X server directly to both the IM Server and the IM library. Therefore this +method provides much better interactive performance while preediting +(particularly in cases such as when the IM Server is running locally on +the user's workstation and the client application is running on another +workstation over a relatively slow network). +.LP +However, the FrontEnd model may have synchronization problems between +the key events handled in the IM Server and other events handled in the +client, and these problems could possibly cause the loss or duplication +of key events. For this reason, the BackEnd method is the core method +supported, and the FrontEnd method is made available as an extension for +performance purposes. (Refer to Appendix A for more information.) +.LP +.LP +.bp +\^... 0.05 6.513 4.737 10.45 +\^... 0.000i 3.937i 4.687i 0.000i +.nr 00 \n(.u +.nf +.PS 3.937i 4.687i +.br +.ps +.ps 10 +\h'3.687i'\v'3.437i'\v'-.13m'\L'-0.500i\(br'\v'.13m' +.sp -1 +\h'3.712i'\v'3.037i'\D'l-0.025i -0.100i' +.sp -1 +\h'3.687i'\v'2.937i'\D'l-0.025i 0.100i' +.sp -1 +\h'2.187i'\v'1.938i'\v'-.13m'\L'-0.750i\(br'\v'.13m' +.sp -1 +\h'2.187i'\v'1.188i'\l'0.750i' +.sp -1 +\h'2.937i'\v'1.188i'\v'-.13m'\L'1.250i\(br'\v'.13m' +.sp -1 +\h'2.912i'\v'2.338i'\D'l0.025i 0.100i' +.sp -1 +\h'2.937i'\v'2.438i'\D'l0.025i -0.100i' +.sp -1 +\h'2.187i'\v'3.437i'\v'-.13m'\L'-1.499i\(br'\v'.13m' +.sp -1 +\h'2.212i'\v'2.038i'\D'l-0.025i -0.100i' +.sp -1 +\h'2.187i'\v'1.938i'\D'l-0.025i 0.100i' +.sp -1 +\h'1.938i'\v'3.437i'\l'1.999i' +.sp -1 +\h'3.937i'\v'3.437i'\v'-.13m'\L'0.500i\(br'\v'.13m' +.sp -1 +\h'3.937i'\v'3.937i'\l'-1.999i' +.sp -1 +\h'1.938i'\v'3.937i'\v'-.13m'\L'-0.500i\(br'\v'.13m' +.sp -1 +\h'2.562i'\v'2.438i'\l'2.125i' +.sp -1 +\h'4.687i'\v'2.438i'\v'-.13m'\L'0.499i\(br'\v'.13m' +.sp -1 +\h'4.687i'\v'2.937i'\l'-2.125i' +.sp -1 +\h'2.562i'\v'2.937i'\v'-.13m'\L'-0.499i\(br'\v'.13m' +.sp -1 +\h'2.562i'\v'1.438i'\l'1.313i' +.sp -1 +\h'3.875i'\v'1.438i'\v'-.13m'\L'0.437i\(br'\v'.13m' +.sp -1 +\h'3.875i'\v'1.875i'\l'-1.313i' +.sp -1 +\h'2.562i'\v'1.875i'\v'-.13m'\L'-0.437i\(br'\v'.13m' +.sp -1 +\h'1.938i'\v'0.438i'\l'1.999i' +.sp -1 +\h'3.937i'\v'0.438i'\v'-.13m'\L'1.500i\(br'\v'.13m' +.sp -1 +\h'3.937i'\v'1.938i'\l'-1.999i' +.sp -1 +\h'1.938i'\v'1.938i'\v'-.13m'\L'-1.500i\(br'\v'.13m' +.sp -1 +\D'l0.000i 0.000i' +.sp -1 +.ps +.ps 12 +\h'3.812i'\v'3.217i'\h'-0.0m'\v'0.2m'FrontEnd Method (Extension) +.sp -1 +\h'0.813i'\v'3.217i'\h'-0.0m'\v'0.2m'BackEnd Method (Core) +.sp -1 +\h'2.562i'\v'3.779i'\h'-0.0m'\v'0.2m'X Server +.sp -1 +\h'3.062i'\v'2.779i'\h'-0.0m'\v'0.2m'IM Server +.sp -1 +\h'3.062i'\v'1.717i'\h'-0.0m'\v'0.2m'Library +.sp -1 +\h'2.187i'\v'0.904i'\h'-0.0m'\v'0.2m'Application +.sp -1 +.ps +.ft +.sp 1+3.937i +.PE +.if \n(00 .fi +.ce +.sp +Fig.1 The Flow of Events +.LP +.NH 2 +Event Flow Control +.XS +\*(SN Event Flow Control +.XE +.LP +This protocol supports two event flow models for communication between the +IM library and the IM Server (Static and Dynamic). +.LP +Static Event Flow requires that input events always be sent to the IM +Server from the client. +.LP +Dynamic Event Flow, however, requires only that those input events which +need to be processed (converted) be sent to the IM Server from the client. +.LP +For instance, in the case of inputing a combination of ASCII characters +and Chinese characters, ASCII characters do not need to be processed in +the IM Server, so their key events do not have to be sent to the IM +Server. On the other hand, key events necessary for composing Chinese +characters must be sent to the IM Server. +.LP +Thus, by adopting the Dynamic Event Flow, the number of requests among the +X Server, the client, and the IM Server is significantly reduced, and the +number of context switches is also reduced, resulting in improved performance. +The IM Server can send +.PN XIM_REGISTER_TRIGGERKEYS +message in order to switch the event flow in the Dynamic Event Flow. +.LP +The protocol for this process is described in section 4.5. ``Event Flow +Control''. +.LP +.NH 1 +Default Preconnection Convention +.XS +\*(SN Default Preconnection Convention +.XE +.LP +IM Servers are strongly encouraged to register their symbolic +names as the ATOM names into the IM Server directory property, +.PN XIM_SERVERS, +on the root window of the screen_number 0. +This property can contain a list of ATOMs, and the each ATOM represents +each possible IM Server. +IM Server names are restricted to POSIX Portable Filename Character Set. +To discover if the IM Server is active, see if there is an owner for +the selection with that atom name. To learn the address of that IM Server, +convert the selection target +.PN TRANSPORT, +which will return a string form of the transport address(es). +To learn the supported locales of that IM Server, convert the selection target +.PN LOCALES, +which will return a set of names of the supported locales in the syntax +X/Open defines. +.LP +The basic semantics to determine the IM Server if there are +multiple ATOMs are found in +.PN XIM_SERVERS +property, is first fit if the IM Server name is not given as +a X modifier's category +.PN im. +.LP +The address information retrievable from the +.PN TRANSPORT +target is a transport-specific name. +The preregistered formats for transport-specific names are listed in Appendix B. +Additional transport-specific names may be registered with X Consortium. +.LP +For environments that lack X connections, or for IM Servers which +do not use the X Window System, the preconnection convention with IM Server +may be given outside the X Window system (e.g. using a Name Service). +.LP +.NH 1 +Protocol +.XS +\*(SN Protocol +.XE +.LP +The protocol described below uses the bi-directional +synchronous/asynchronous request/reply/error model and is specified +using the same conventions outlined in Section 2 of the core X Window +System protocol [1]: +.LP +.NH 2 +Basic Requests Packet Format +.XS +\*(SN Basic Requests Packet Format +.XE +.LP +This section describes the requests that may be exchanged between the client +and the IM Server. +.LP +The basic request packet header format is as follows. +.RS +.DS + major-opcode: CARD8 + minor-opcode: CARD8 + length: CARD16 +.DE +.RE +The MAJOR-OPCODE specifies which core request or extension package this +packet represents. If the MAJOR-OPCODE corresponds to a core request, +the MINOR-OPCODE contains 8 bits of request-specific data. +(If the MINOR-OPCODE is not used, it is 0.) +Otherwise, the MAJOR-OPCODE and the MINOR-OPCODE are specified by +.PN XIM_QUERY_EXTENSION +message. (Refer to 4.7. Query the supported extension protocol list.) +The LENGTH field specifies the number of 4 bytes elements following the +header. If no additional data is followed by the header, the LENGTH field +will be 0. +.LP +.NH 2 +Data Types +.XS +\*(SN Data Types +.XE +.LP +The following data types are used in the core X IM Server protocol: +.LP +.nf +.ta .2i .5i 2.0i +BITMASK16 + CARD16 +.sp +BITMASK32 + CARD32 +.sp +PADDING FORMAT + Where N is some expression, and Pad(N) is the number of bytes needed to round N up to a + multiple of four. + Pad(N) = (4 - (N mod 4)) mod 4 +.sp +LPCE + 1 A character from the4 X Portable Character Set in Latin Portable + Character Encoding +.bp +STRING + 2 n length of string in bytes + n LISTofLPCE string + p unused, p=Pad(2+n) +.sp +STR + 1 n length of name in bytes + n STRING8 name +.sp +XIMATTR + 2 CARD16 attribute ID (*1) + 2 CARD16 type of the value (*2) + 2 n length of im-attribute + n STRING8 im-attribute + p unused, p = Pad(2+n) +.sp +The im-attribute argument specifies XIM values such as XNQueryInputStyle. +.sp +XICATTR + 2 CARD16 attribute ID (*1) + 2 CARD16 type of the value (*2) + 2 n length of ic-attribute + n STRING8 ic-attribute + p unused, p = Pad(2+n) +.LP +.IP (*1) +XIMATTR and XICATTR are used during the setup stage and XIMATTRIBUTE and +XICATTRIBUTE are used after each attribute ID has been recognized by +the IM Server and the IM library. +.sp +.IP (*2) +The value types are defined as follows: +.TS H +tab(:); +l l l s s +l l l l l +l l l l l +l l l l l +l l l l l +l l l l l +l l l l l +l l l l l +l l l l l +l l l l l +l l l l l +l l l l l +l l l l l +l l l l l +l l l l l +l l l l l +l l l l l +l l l l l +l l l l l +l l l l l +l l l l l +l l l l l +l l l s s +l l l s s +l l l s s +l l l s s +l l l s s +l l l l l. +_ +.sp 6p +.B +values:data:format +.sp 6p +_ +.sp 6p +.TH +.R +#0:Separator of NestedList:----- (*3) +#1:byte data:CARD8 +#2:word data:CARD16 +#3:long data:CARD32 +#4:char data:STRING8 +#5:Window:CARD32 +#10:XIMStyles:2:n:number of XIMStyle list +::2::unused +::n:CARD32:XIMStyle list +#11:XRectangle:2:INT16:X +::2:INT16:Y +::2:CARD16:width +::2:CARD16:height +#12:XPoint:2:INT16:X +::2:INT16:Y +#13:XFontSet:2:n:length of Base font name +::n:STRING8:Base font name list +::p::unused, p = Pad(2+n) +#15:XIMHotKeyTriggers:4:n:T{ +number of XIMTRIGGERKEY list (*4) +T} +::n:XIMTRIGGERKEY:XIMHotkeyTrigger list +#16:XIMHotKeyState::XIMHOTKEYSTATE:T{ +HotKey processing state +T} +#17:XIMStringConversion:XIMSTRCONVTEXT +#18:XIMPreeditState:XIMPREEDITSTATE +#19:XIMResetState:XIMRESETSTATE +#x7fff:NestedList:----- +.sp 6p +_ +.TE +.LP +.IP (*3) +The IC value for the separator of NestedList is defined as follows, +.br + #define XNSeparatorofNestedList ``separatorofNestedList'' +.br +, which is registered in X Consortium and cannot be used for any +other purpose. +.sp +.IP (*4) +LISTofFOO +.RS +A Type name of the form LISTof FOO means a counted list of elements of +type FOO. +The size of the length field may vary (it is not necessarily the same +size as a FOO), and in some cases, it may be implicit. +.RE +.sp +.LP +.nf +.ta .2i .5i 2.0i +XIMTRIGGERKEY + 4 CARD32 keysym + 4 CARD32 modifier + 4 CARD32 modifier mask +.sp +ENCODINGINFO + 2 n length of encoding info + n STRING8 encoding info + p unused, p=Pad(2+n) +.sp +EXT + 1 CARD8 extension major-opcode + 1 CARD8 extension minor-opcode + 2 n length of extension name + n STRING8 extension name + p unused, p = Pad(n) +.sp +XIMATTRIBUTE + 2 CARD16 attribute ID + 2 n value length + n value + p unused, p = Pad(n) +.sp +XICATTRIBUTE + 2 CARD16 attribute ID + 2 n value length + n value + p unused, p = Pad(n) +.sp +.bp +.ta .2i .5i 3.0i +XIMSTRCONVTEXT + 2 CARD16 XIMStringConversionFeedback + #x0000001 XIMStringConversionLeftEdge + #x0000002 XIMStringConversionRightEdge + #x0000004 XIMStringConversionTopEdge + #x0000008 XIMStringConversionBottomEdge + #x0000010 XIMStringConversionConvealed + #x0000020 XIMStringConversionWrapped + 2 n byte length of the retrieved string + n STRING8 retrieved string + p unused, p = Pad(n) + 2 m byte length of feedback array + 2 unused + m LISTofXIMSTRCONVFEEDBACK feedback array(*1) +.IP (*1) +This field is reserved for future use. +.sp +.LP +.nf +.ta .2i .5i 2.0i +XIMFEEDBACK + 4 CARD32 XIMFeedback + #x000001 XIMReverse + #x000002 XIMUnderline + #x000004 XIMHighlight + #x000008 XIMPrimary + #x000010 XIMSecondary + #x000020 XIMTertiary + #x000040 XIMVisibleToForward + #x000080 XIMVisibleToBackward + #x000100 XIMVisibleCenter +.sp +XIMHOTKEYSTATE + 4 CARD32 XIMHotKeyState + #x0000001 XIMHotKeyStateON + #x0000002 XIMHotKeyStateOFF +.sp +XIMPREEDITSTATE + 4 CARD32 XIMPreeditState + #x0000001 XIMPreeditEnable + #x0000002 XIMPreeditDisable +.sp +XIMRESETSTATE + 4 CARD32 XIMResetState + #x0000001 XIMInitialState + #x0000002 XIMPreserveState +.LP +.NH 2 +Error Notification +.XS +\*(SN Error Notification +.XE +.LP +Both the IM Server and the IM library return +.PN XIM_ERROR +messages instead of the corresponding reply messages if any errors occur +during data processing. +.LP +At most one error is generated per request. If more than one error condition +is encountered in processing a request, the choice of which error is returned +is implementation-dependent. +.LP +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_ERROR (IM Server \(<-\(-> IM library) +.sp 6p +:2:CARD16:input-method-ID +:2:CARD16:input-context-ID +:2:BITMASK16:flag (*1) +::#0000:Both Input-Method-ID and Input-Context-ID are invalid +::#0001:Input-Method-ID is valid +::#0002:Input-Context-ID is valid +:2:CARD16:Error Code +::#1:BadAlloc +::#2:BadStyle +::#3:BadClientWindow +::#4:BadFocusWindow +::#5:BadArea +::#6:BadSpotLocation +::#7:BadColormap +::#8:BadAtom +::#9:BadPixel +::#10:BadPixmap +::#11:BadName +::#12:BadCursor +::#13:BadProtocol +::#14:BadForeground +::#15:BadBackground +::#16:LocaleNotSupported +::#999:BadSomething (*2) +:2:n:byte length of error detail. +:2:CARD16:type of error detail (*3) +:n:STRING8:error detail (*4) +:p::unused, p = Pad(n) +.TE +.LP +.IP (*1) +Before an IM is created, both Input-Method-ID and +Input-Context-ID are invalid. +Before an IC is created, only Input-Method-ID is valid. +After that, both of Input-Method-ID and Input-Context-ID are valid. +.IP (*2) +Unspecific error, for example ``language engine died'' +.IP (*3) +This field is reserved for future use. +.IP (*4) +Vendor defined detail error message +.RE +.LP +.NH 2 +Connection Establishment +.XS +\*(SN Connection Establishment +.XE +.LP +.PN XIM_CONNECT +message requests to establish a connection over a mutually-understood virtual +stream. +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_CONNECT (IM library \(-> IM Server) +.sp 6p +:1::byte order +::#x42 MSB first +::#x6c LSB first +:1::unused +:2:CARD16:client-major-protocol-version (*1) +:2:CARD16:client-minor-protocol-version (*1) +:2:CARD16:number of client-auth-protocol-names +:n:LISTofSTRING:client-auth-protocol-names +.TE +.LP +.IP (*1) +Specify the version of IM Protocol that the client supports. +.RE +.sp +.LP +A client must send +.PN XIM_CONNECT +message as the first message on the connection. +The list specifies the names of authentication protocols the sending +IM Server is willing to perform. +(If the client need not authenticate, the list may be omited.) +.LP +.PN XIM_AUTH_REQUIRED +message is used to send the authentication protocol name and protocol-specific +data. +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_AUTH_REQUIRED (IM library \(<-\(-> IM Server) +.sp 6p +:1:CARD8:auth-protocol-index +:3::unused +:2:n:length of authentication data +:2::unused +:n::data +:p::unused, p = Pad(n) +.TE +.RE +.LP +The auth-protocol is specified by an index into the list of names +given in the +.PN XIM_CONNECT +or +.PN XIM_AUTH_SETUP +message. Any protocol-specific data that might be required is also sent. +.LP +The IM library sends +.PN XIM_AUTH_REPLY +message as the reply to +.PN XIM_AUTH_REQUIRED +message, if the IM Server is authenticated. +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_AUTH_REPLY (IM library \(-> IM Server) +.sp 6p +:2:n:length of authentication data +:2::unused +:2:n:length of authentication data +:2::unused +:n::data +:p::unused, p = Pad(n) +.TE +.RE +.LP +The auth data is specific to the authentication protocol in use. +.LP +.PN XIM_AUTH_NEXT +message requests to send more auth data. +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_AUTH_NEXT (IM library \(<-\(-> IM Server) +.sp 6p +:2:n:length of authentication data +:2::unused +:n::data +:p::unused, p = Pad(n) +.TE +.RE +.LP +The auth data is specific to the authentication protocol in use. +.LP +The IM Server sends +.PN XIM_AUTH_SETUP +message to authenticate the client. +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_AUTH_SETUP (IM Server \(-> IM library) +.sp 6p +:2:CARD16:number of client-auth-protocol-names +:2::unused +:n:LISTofSTRING:server-auth-protocol-names +.TE +.RE +.LP +The list specifies the names of authentication protocols the +client is willing to perform. +.LP +.PN XIM_AUTH_NG +message requests to give up the connection. +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_AUTH_NG (IM library \(<-\(-> IM Server) +.TE +.RE +.LP +The IM Server sends +.PN XIM_CONNECT_REPLY +message as the reply to +.PN XIM_CONNECT +or +.PN XIM_AUTH_REQUIRED +message. +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_CONNECT_REPLY (IM Server \(-> IM library) +.sp 6p +:2:CARD16:server-major-protocol-version (*1) +:2:CARD16:server-minor-protocol-version (*1) +.TE +.LP +.IP (*1) +Specify the version of IM Protocol that the IM Server supports. +This document specifies major version one, minor version zero. +.RE +.sp +.LP +Here are the state diagrams for the client and the IM Server. +.sp +.B +State transitions for the client +.R +.RS +.LP +\fIinit_status\fP: +.RS +Use authorization function \(-> \fIclient_ask\fP +.br +Not use authorization function \(-> \fIclient_no_check\fP +.RE +.sp +.LP +\fIstart\fP: +.RS +Send +.PN XIM_CONNECT +.RS +If \fIclient_ask\fP \(-> \fIclient_wait1\fP +.br +If \fIclient_no_check\fP, client-auth-protocol-names may be omited \(-> \fIclient_wait2\fP +.RE +.RE +.sp +.LP +\fIclient_wait1\fP: +.RS +Receive +.PN XIM_AUTH_REQUIRED +\(-> \fIclient_check\fP +.br +Receive \(-> \fIclient_NG\fP +.RE +.sp +.LP +\fIclient_check\fP: +.RS +If no more auth needed, send +.PN XIM_AUTH_REPLY +\(-> \fIclient_wait2\fP +.br +If good auth data, send +.PN XIM_AUTH_NEXT +\(-> \fIclient_wait1\fP +.br +If bad auth data, send +.PN XIM_AUTH_NG +\(-> give up on this protocol +.RE +.sp +.LP +\fIclient_wait2\fP: +.RS +Receive +.PN XIM_CONNECT_REPLY +\(-> connect +.br +Receive +.PN XIM_AUTH_SETUP +\(-> \fIclient_more\fP +.br +Receive +.PN XIM_AUTH_NEXT +\(-> \fIclient_more\fP +.br +Receive +.PN XIM_AUTH_NG +\(-> give up on this protocol +.br +Receive \(-> \fIclient_NG\fP +.RE +.sp +.LP +\fIclient_more\fP: +.RS +Send +.PN XIM_AUTH_REQUIRED +\(-> \fIclient_wait2\fP +.RE +.sp +.LP +\fIclient_NG\fP: +.RS +Send +.PN XIM_AUTH_NG +\(-> give up on this protocol +.RE +.RE +.sp +.LP +.B +State transitions for the IM Server +.R +.RS +.LP +\fIinit-status\fP: +.RS +Use authorization function \(-> \fIserver_ask\fP +.br +Not use authorization function \(-> \fIserver_no_check\fP +.RE +.sp +.LP +\fIstart\fP: +.RS +Receive +.PN XIM_CONNECT +\(-> \fIstart2\fP +.br +Receive \(-> \fIserver_NG\fP +.RE +.sp +.LP +\fIstart2\fP: +.RS +If \fIclient_ask\fP, send +.PN XIM_AUTH_REQUIRED +\(-> \fIserver_wait1\fP +.br +If \fIclient_no_check\fP and \fIserver_ask\fP, send +.PN XIM_AUTH_SETUP +\(-> \fIserver_wait2\fP +.br +If \fIclient_no_check\fP and \fIserver_no_check\fP, send +.PN XIM_CONNECT_REPLY +\(-> connect +.RE +.sp +.LP +\fIserver_wait1\fP: +.RS +Receive +.PN XIM_AUTH_REPLY +\(-> \fIserver2\fP +.br +Receive +.PN XIM_AUTH_NEXT +\(-> \fIserver_more\fP +.br +Receive \(-> \fIserver_NG\fP +.RE +.sp +.LP +\fIserver_more\fP +.RS +Send +.PN XIM_AUTH_REQUIRED +\(-> \fIserver_wait1\fP +.RE +.sp +.LP +\fIserver2\fP +.RS +If \fIserver_ask\fP, send +.PN XIM_AUTH_SETUP +\(-> \fIserver_wait2\fP +.br +If \fIserver_no_check\fP, send +.PN XIM_CONNECT_REPLY +\(-> connect +.RE +.sp +.LP +\fIserver_wait2\fP +.RS +Receive +.PN XIM_AUTH_REQUIRED +\(-> \fIserver_check\fP +.br +Receive \(-> \fIserver_NG\fP +.RE +.sp +.LP +\fIserver_check\fP +.RS +If no more auth data, send +.PN XIM_CONNECT_REPLY +\(-> connect +.br +If bad auth data, send +.PN XIM_AUTH_NG +\(-> give up on this protocol +.br +If good auth data, send +.PN XIM_AUTH_NEXT +\(-> \fIserver_wait2\fP +.RE +.sp +.LP +\fIserver_NG\fP +.RS +Send +.PN XIM_AUTH_NG +\(-> give up on this protocol +.RE +.RE +.sp +.LP +.PN XIM_DISCONNECT +message requests to shutdown the connection over a mutually-understood +virtual stream. +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_DISCONNECT (IM library \(-> IM Server) +.TE +.RE +.LP +.PN XIM_DISCONNECT +is a synchronous request. The IM library should wait until it receives +either an +.PN XIM_DISCONNECT_REPLY +packet or an +.PN XIM_ERROR +packet. +.LP +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_DISCONNECT_REPLY (IM Server \(-> IM library) +.TE +.RE +.LP +.PN XIM_OPEN +requests to establish a logical connection between the IM library and the IM +Server. +.LP +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_OPEN (IM library \(-> IM Server) +.sp 6p +:n:STR:locale name +:p::unused, p = Pad(n) +.TE +.RE +.LP +.PN XIM_OPEN +is a synchronous request. The IM library should wait until receiving +either an +.PN XIM_OPEN_REPLY +packet or an +.PN XIM_ERROR +packet. +.LP +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_OPEN_REPLY (IM Server \(-> IM library) +.sp 6p +:2:CARD16:input-method-ID +:2:n:byte length of IM attributes supported +:n:LISTofXIMATTR:IM attributes supported +:2:m:byte length of IC attributes supported +:2:CARD16:unused +:m:LISTofXICATTR: IC attributes supported +.TE +.RE +.LP +.PN XIM_OPEN_REPLY +message returns all supported IM and IC attributes in LISTofXIMATTR and +LISTofXICATTR. These IM and IC attribute IDs are used to reduce the amount +of data which must be transferred via the network. In addition, this +indicates to the IM library what kinds of IM/IC attributes can be used +in this session, and what types of data will be exchanged. This allows +the IM Server provider and application writer to support IM system +enhancements with new IM/IC attributes, without modifying Xlib. +The IC value for the separator of NestedList must be included in the +LISTofXICATTR. +.LP +.PN XIM_CLOSE +message requests to shutdown the logical connection between the IM library +and the IM Server. +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_CLOSE (IM library \(-> IM Server) +.sp 6p +:2:CARD16:input-method-ID +:2::unused +.TE +.RE +.LP +.PN XIM_CLOSE +is a synchronous request. The IM library should wait until receiving +either an +.PN XIM_CLOSE_REPLY +packet or an +.PN XIM_ERROR +packet. +.LP +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_CLOSE_REPLY (IM Server \(-> IM library) +.sp 6p +:2:CARD16:input-method-ID +:2::unused +.TE +.RE +.LP +.NH 2 +Event Flow Control +.XS +\*(SN Event Flow Control +.XE +.LP +An IM Server must send +.PN XIM_SET_EVENT_MASK +message to the IM library in order for events to be forwarded to the IM +Server, since the IM library initially doesn't forward any events to the +IM Server. In the protocol, the IM Server will specify masks of X events +to be forwarded and which need to be synchronized by the IM library. +.LP +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_SET_EVENT_MASK (IM Server \(-> IM library) +.sp 6p +:2:CARD16:input-method-ID +:2:CARD16:input-context-ID +:4:EVENTMASK:forward-event-mask (*1) +:4:EVENTMASK:synchronous-event-mask (*2) +.TE +.LP +.IP (*1) +Specify all the events to be forwarded to the IM Server by the IM library. +.IP (*2) +Specify the events to be forwarded with synchronous flag on by the IM library. +.RE +.sp +.LP +.PN XIM_SET_EVENT_MASK +is an asynchronous request. The event masks are valid immediately after +they are set until changed by another +.PN XIM_SET_EVENT_MASK +message. If input-context-ID is set to zero, the default value of the +input-method-ID will be changed to the event masks specified in the request. +That value will be used for the IC's which have no individual values. +.LP +Using the Dynamic Event Flow model, an IM Server sends +.PN XIM_REGISTER_TRIGGERKEYS +message to the IM library before sending +.PN XIM_OPEN_REPLY +message. +Or the IM library may suppose that the IM Server uses the Static Event Flow +model. +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_REGISTER_TRIGGERKEYS (IM Server \(-> IM library) +.sp 6p +:2:CARD16:input-method-ID +:2::unused +:4:n:byte length of on-keys +:n:LISTofXIMTRIGGERKEY:on-keys list +:4:m:byte length of off-keys +:m:LISTofXIMTRIGGERKEY:off-keys list +.TE +.RE +.LP +.PN XIM_REGISTER_TRIGGERKEYS +is an asynchronous request. +The IM Server notifys the IM library of on-keys and off-keys lists with +this message. +.LP +The IM library notifys the IM Server with +.PN XIM_TRIGGER_NOTIFY +message that a key event matching either on-keys or off-keys has been occurred. +.LP +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_TRIGGER_NOTIFY (IM library \(-> IM Server) +.sp 6p +:2:CARD16:input-method-ID +:2:CARD16:input-context-ID +:4:CARD32:flag +::#0:on-keys list +::#1:off-keys list +:4:CARD32:index of keys list +:4:EVENTMASK:client-select-event-mask (*1) +.TE +.LP +.IP (*1) +Specify the events currently selected by the IM library with XSelectInput. +.RE +.sp +.LP +.PN XIM_TRIGGER_NOTIFY +is a synchronous request. The IM library should wait until receiving +either an +.PN XIM_TRIGGER_NOTIFY_REPLY +packet or an +.PN XIM_ERROR +packet. +.LP +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_TRIGGER_NOTIFY_REPLY (IM Server \(-> IM library) +.sp 6p +:2:CARD16:input-method-ID +:2:CARD16:input-context-ID +.TE +.RE +.LP +.NH 2 +Encoding Negotiation +.XS +\*(SN Encoding Negotiation +.XE +.LP +.PN XIM_ENCODING_NEGOTIATION +message requests to decide which encoding to be sent across the wire. +When the negotiation fails, the fallback default encoding is Portable +Character Encoding. +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_ENCODING_NEGOTIATION (IM library \(-> IM Server).sp 6p +:2:CARD16:input-method-ID +:2:n:byte length of encodings listed by name +:n:LISTofSTR:list of encodings supported in the IM library. +:p::unused, p = Pad(n) +:2:m:byte length of encodings listed by detailed data +:2::unused +:m:LISTofENCODINGINFO:list of encordings supported in the IM library +.TE +.RE +.LP +The IM Server must choose one encoding from the list sent by the IM library. +If index of the encording determined is -1 to indicate that the negotiation +is failed, the fallback default encoding is used. +The message must be issued after sending +.PN XIM_OPEN +message via XOpenIM(). +The name of encoding may be registered with X Consortium. +.LP +.PN XIM_ENCODING_NEGOTIATION +is a synchronous request. The IM library should wait until receiving +either an +.PN XIM_ENCODING_NEGOTIATION_REPLY +packet or an +.PN XIM_ERROR +packet. +.LP +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_ENCODING_NEGOTIATION_REPLY (IM Server \(-> IM library) +.sp 6p +:2:CARD16:input-method-ID +:2:CARD16:category of the encoding determined. +::#0:name +::#1:detailed data +:2:INT16:index of the encoding determinated. +:2::unused +.TE +.RE +.LP +.NH 2 +Query the supported extension protocol list +.XS +\*(SN Query the supported extension protocol list +.XE +.LP +.PN XIM_QUERY_EXTENSION +message requests to query the IM extensions supported by the IM Server to +which the client is being connected. +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_QUERY_EXTENSION (IM library \(-> IM Server) +.sp 6p +:2:CARD16:input-method-ID +:2:n:T{ +byte length of extensions supported by the IM library +T} +:n:LISTofSTR:extensions supported by the IM library +:p::unused, p = Pad(n) +.TE +.RE +.LP +An example of a supported extension is FrontEnd. +The message must be issued after sending +.PN XIM_OPEN +message via XOpenIM(). +.LP +If n is 0, the IM library queries the IM Server for all extensions. +.LP +If n is not 0, the IM library queries whether the IM Server supports the +contents specified in the list. +.LP +If a client uses an extension request without previously having issued a +.PN XIM_QUERY_EXTENSION +message for that extension, the IM Server responds with a +.PN BadProtocol +error. If the IM Server encounters a request with an unknown MAJOR-OPCODE +or MINOR-OPCODE, it responds with a +.PN BadProtocol +error. +.LP +.PN XIM_QUERY_EXTENSION +is a synchronous request. The IM library should wait until receiving +either an +.PN XIM_QUERY_EXTENSION_REPLY +packet or an +.PN XIM_ERROR +packet. +.LP +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_QUERY_EXTENSION_REPLY (IM Server \(-> IM library) +.sp 6p +:2:CARD16:input-method-ID +:2:n:T{ +byte length of extensions supported by both the IM library and the IM Server +T} +:n:LISTofEXT:T{ +list of extensions supported by both the IM library and the IM Server +T} +.TE +.RE +.LP +.PN XIM_QUERY_EXTENSION_REPLY +message returns the list of extensions supported by both the IM library and +the IM Server. If the list passed in +.PN XIM_QUERY_EXTENSION +message is NULL, the IM Server returns the full list of extensions supported +by the IM Server. If the list is not NULL, the IM Server returns the +extensions in the list that are supported by the IM Server. +.LP +A zero-length string is not a valid extension name. The IM library should +disregard any zero-length strings that are returned in the extension list. +The IM library does not use the requests which are not supported by the IM +Server. +.LP +.NH 2 +Setting IM Values +.XS +\*(SN Setting IM Values +.XE +.LP +.PN XIM_SET_IM_VALUES +requests to set attributes to the IM. +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_SET_IM_VALUES (IM library \(-> IM Server) +.sp 6p +:2:CARD16:input-method-ID +:2:n:byte length of im-attribute +:n:LISTofXIMATTRIBUTE:im-attributes +.TE +.RE +.LP +The im-attributes in +.PN XIM_SET_IM_VALUES +message are specified as a LISTofXIMATTRIBUTE, specifying the attributes +to be set. Attributes other than the ones returned by +.PN XIM_OPEN_REPLY +message should not be specified. +.LP +.PN XIM_SET_IM_VALUES +is a synchronous request. The IM library should wait until receiving +either an +.PN XIM_SET_IM_VALUES_REPLY +packet or an +.PN XIM_ERROR +packet, because it must receive the error attribute if +.PN XIM_ERROR +message is returned. +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_SET_IM_VALUES_REPLY (IM Server \(-> IM library) +.sp 6p +:2:CARD16:input-method-ID +:2::unused +.TE +.RE +.LP +.PN XIM_SET_IM_VALUES_REPLY +message returns the input-method-ID to distinguish replies from multiple IMs. +.LP +.NH 2 +Getting IM Values +.XS +\*(SN getting IM Values +.XE +.LP +.PN XIM_GET_IM_VALUES +requests to query IM values supported by the IM Server currently being +connected. +.LP +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_GET_IM_VALUES (IM library \(-> IM Server) +.sp 6p +:2:CARD16:input-method-ID +:2:n:byte length of im-attribute-id +:n:LISTofCARD16:im-attribute-id +:p::unused, p=Pad(n) +.TE +.RE +.LP +.PN XIM_GET_IM_VALUES +is a synchronous request. The IM library should wait until it receives +either an +.PN XIM_GET_IM_VALUES_REPLY +packet or an +.PN XIM_ERROR +packet. +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_GET_IM_VALUES_REPLY (IM Server \(-> IM library) +.sp 6p +:2:CARD16:input-method-ID +:2:n:byte length of im-attributes returned +:n:LISTofXIMATTRIBUTE:im-attributes returned +.TE +.RE +.LP +The IM Server returns IM values with +.PN XIM_GET_IM_VALUES_REPLY +message. The order of the returned im-attribute values corresponds directly +to that of the list passed with the +.PN XIM_GET_IM_VALUES +message. +.LP +.NH 2 +Creating an IC +.XS +\*(SN Creating an IC +.XE +.LP +.PN XIM_CREATE_IC +message requests to create an IC. +.LP +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_CREATE_IC (IM library \(-> IM Server) +.sp 6p +:2:CARD16:input-method-ID +:2:n:byte length of ic-attributes +:n:LISTofXICATTRIBUTE:ic-attributes +.TE +.RE +.LP +The input-context-id is specified by the IM Server to identify the client +(IC). (It is not specified by the client in +.PN XIM_CREATE_IC +message.), and it should not be set to zero. +.LP +.PN XIM_CREATE_IC +is a synchronous request which returns the input-context-ID. +The IM library should wait until it receives either an +.PN XIM_CREATE_IC_REPLY +packet or an +.PN XIM_ERROR +packet. +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_CREATE_IC_REPLY (IM Server \(-> IM library) +.sp 6p +:2:CARD16:input-method-ID +:2:CARD16:input-context-ID +.TE +.RE +.LP +.NH 2 +Destroying the IC +.XS +\*(SN Destroying the IC +.XE +.LP +.PN XIM_DESTROY_IC +message requests to destroy the IC. +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_DESTROY_IC (IM library \(-> IM Server) +.sp 6p +:2:CARD16:input-method-ID +:2:CARD16:input-context-ID +.TE +.RE +.LP +.PN XIM_DESTROY_IC +is a synchronous request. The IM library should not free its resources +until it receives an +.PN XIM_DESTROY_IC_REPLY +message because +.PN XIM_DESTROY_IC +message may result in Callback packets such as +.PN XIM_PREEDIT_DRAW +and +.PN XIM_PREEDIT_DONE. +.LP +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_DESTROY_IC_REPLY (IM Server \(-> IM library) +.sp 6p +:2:CARD16:input-method-ID +:2:CARD16:input-context-ID +.TE +.RE +.LP +.NH 2 +Setting IC Values +.XS +\*(SN Setting IC Values +.XE +.LP +.PN XIM_SET_IC_VALUES +messages requests to set attributes to the IC. +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_SET_IC_VALUES (IM library \(-> IM Server) +.sp 6p +:2:CARD16:input-method-ID +:2:CARD16:input-context-ID +:2:n:byte length of ic-attributes +:2::unused +:n:LISTofXICATTRIBUTE:ic-attributes +.TE +.RE +.LP +The ic-attributes in +.PN XIM_SET_IC_VALUES +message are specified as a LISTofXICATTRIBUTE, specifying the attributes +to be set. Attributes other than the ones returned by +.PN XIM_OPEN_REPLY +message should not be specified. +.LP +.PN XIM_SET_IC_VALUES +is a synchronous request. The IM library should wait until receiving +either an +.PN XIM_SET_IC_VALUES_REPLY +packet or an +.PN XIM_ERROR +packet, because it must receive the error attribute if +.PN XIM_ERROR +message is returned. +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_SET_IC_VALUES_REPLY (IM Server \(-> IM library) +.sp 6p +:2:CARD16:input-method-ID +:2:CARD16:input-context-ID +.TE +.RE +.LP +.NH 2 +Getting IC Values +.XS +\*(SN Getting IC Values +.XE +.LP +.PN XIM_GET_IC_VALUES +message requests to query IC values supported by the IM Server currently +being connected. +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_GET_IC_VALUES (IM library \(-> IM Server) +.sp 6p +:2:CARD16:input-method-ID +:2:CARD16:input-context-ID +:2:n:byte length of ic-attribute-id +:n:LISTofCARD16:ic-attribute-id +:p::unused, p=Pad(2+n) +.TE +.RE +.LP +In LISTofCARD16, the appearance of the ic-attribute-id for the separator +of NestedList shows the end of the heading nested list. +.LP +.PN XIM_GET_IC_VALUES +is a synchronous request and returns each attribute with its values to +show the correspondence. The IM library should wait until receiving +either an +.PN XIM_GET_IC_VALUES_REPLY +packet or an +.PN XIM_ERROR +packet. +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_GET_IC_VALUES_REPLY (IM Server \(-> IM library) +.sp 6p +:2:CARD16:input-method-ID +:2:CARD16:input-context-ID +:2:n:byte length of ic-attribute +:2::unused +:n:LISTofXICATTRIBUTE:ic-attribute +.TE +.RE +.LP +.NH 2 +Setting IC Focus +.XS +\*(SN Setting IC Focus +.XE +.LP +.PN XIM_SET_IC_FOCUS +message requests to set the focus to the IC. +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_SET_IC_FOCUS (IM library \(-> IM Server) +.sp 6p +:2:CARD16:input-method-ID +:2:CARD16:input-context-ID +.TE +.RE +.LP +.PN XIM_SET_IC_FOCUS +is an asynchronous request. +.LP +.NH 2 +Unsetting IC Focus +.XS +\*(SN Unsetting IC Focus +.XE +.LP +.PN XIM_UNSET_IC_FOCUS +message requests to unset the focus to the focused IC. +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_UNSET_IC_FOCUS (IM library \(-> IM Server) +.sp 6p +:2:CARD16:input-method-ID +:2:CARD16:input-context-ID +.TE +.RE +.LP +.PN XIM_UNSET_IC_FOCUS +is an asynchronous request. +.LP +.NH 2 +Filtering Events +.XS +\*(SN Filtering Events +.XE +.LP +Event filtering is mainly provided for BackEnd method to allow input method +to capture X events transparently to clients. +.LP +X Events are forwarded by +.PN XIM_FORWARD_EVENT +message. +This message can be operated both synchronously and asynchronously. +If the requester sets the synchronous flag, the receiver must send +.PN XIM_SYNC_REPLY +message back to the requester when all the data processing is done. +.sp +.B +Protocol flow of BackEnd model +.R +.LP +.LP +With BackEnd method, the protocol flow can be classified into two +methods in terms of synchronization, depending on the synchronous-eventmask +of +.PN XIM_SET_EVENT_MASK +message. One can be called on-demand-synchronous method and another +can be called as full-synchronous method. +.LP +In on-demand-synchronous method, the IM library always receives +.PN XIM_FORWARD_EVENT +or +.PN XIM_COMMIT +message as a synchronous request. Also, the IM Server needs to synchronously +process the correspondent reply from the IM library and the following +.PN XIM_FORWARD_EVENT +message sent from the IM library when any of the event causes the IM Server +to send +.PN XIM_FORWARD_EVENT +or +.PN XIM_COMMIT +message to the IM library, so that the input service is consistent. If the +IM library gets the control back from the application after receiving the +synchronous request, the IM library replies for the synchronous request before +processing any of the events. In this time, the IM Server blocks +.PN XIM_FORWARD_EVENT +message which is sent by the IM library, and handles it after receiving the +reply. However, the IM Server handles the other protocols at any time. +.LP +In full-synchronous method, the IM library always sends +.PN XIM_FORWARD_EVENT +message to the IM Server as a synchronous request. Therefore, the reply to it +from the IM Server will be put between the +.PN XIM_FORWARD_EVENT +message and its +.PN XIM_SYNC_REPLY +message. +In case of sending +.PN XIM_FORWARD_EVENT +or +.PN XIM_COMMIT +message, the IM Server should set the synchronous flag off. Because the +synchronization can be done by the following +.PN XIM_SYNC_REPLY +message. +.sp +.LP +.B +Sample Protocol flow chart 1 +.R +.LP +Following chart shows one of the simplest protocol flow which only +deals with keyevents for preediting operation. +.LP +.\"====================== event flow figure start ===================== +\^... 0.425 6.888 6.3 10.296 +\^... 0.000i 3.408i 5.875i 0.000i +.nr 00 \n(.u +.nf +.PS 3.408i 5.875i +.br +.ps 11 +\h'3.125i'\v'0.496i'\D'l1.625i 0.250i' +.sp -1 +\h'4.647i'\v'0.756i'\D'l0.103i -0.010i' +.sp -1 +\h'4.655i'\v'0.706i'\D'l0.095i 0.040i' +.sp -1 +\h'3.125i'\v'1.221i'\D'l1.687i 0.188i' +.sp -1 +\h'4.710i'\v'1.423i'\D'l0.102i -0.014i' +.sp -1 +\h'4.715i'\v'1.373i'\D'l0.097i 0.036i' +.sp -1 +\h'4.750i'\v'0.971i'\D'l-1.625i 0.438i' +.sp -1 +\h'3.215i'\v'1.359i'\D'l-0.090i 0.050i' +.sp -1 +\h'3.228i'\v'1.407i'\D'l-0.103i 0.002i' +.sp -1 +\h'2.000i'\v'0.409i'\D'l1.000i 0.062i' +.sp -1 +\h'2.899i'\v'0.490i'\D'l0.101i -0.019i' +.sp -1 +\h'2.902i'\v'0.440i'\D'l0.098i 0.031i' +.sp -1 +\h'2.000i'\v'1.034i'\D'l1.000i 0.125i' +.sp -1 +\h'2.898i'\v'1.171i'\D'l0.102i -0.012i' +.sp -1 +\h'2.904i'\v'1.122i'\D'l0.096i 0.037i' +.sp -1 +\h'3.000i'\v'1.409i'\D'l-1.000i 0.062i' +.sp -1 +\h'2.098i'\v'1.440i'\D'l-0.098i 0.031i' +.sp -1 +\h'2.101i'\v'1.490i'\D'l-0.101i -0.019i' +.sp -1 +\h'1.125i'\v'1.846i'\l'-0.500i' +.sp -1 +\h'0.725i'\v'1.821i'\D'l-0.100i 0.025i' +.sp -1 +\h'0.725i'\v'1.871i'\D'l-0.100i -0.025i' +.sp -1 +\h'0.688i'\v'0.159i'\l'0.437i' +.sp -1 +\h'1.025i'\v'0.184i'\D'l0.100i -0.025i' +.sp -1 +\h'1.025i'\v'0.134i'\D'l0.100i 0.025i' +.sp -1 +\h'0.688i'\v'0.846i'\l'0.437i' +.sp -1 +\h'1.025i'\v'0.871i'\D'l0.100i -0.025i' +.sp -1 +\h'1.025i'\v'0.821i'\D'l0.100i 0.025i' +.sp -1 +\h'5.562i'\v'1.409i'\l'0.313i' +.sp -1 +\h'5.875i'\v'1.409i'\v'-.13m'\L'1.937i\(br'\v'.13m' +.sp -1 +\h'5.875i'\v'3.346i'\D'l-0.250i 0.000i' +.sp -1 +\h'5.725i'\v'3.321i'\D'l-0.100i 0.025i' +.sp -1 +\h'5.725i'\v'3.371i'\D'l-0.100i -0.025i' +.sp -1 +\h'2.062i'\v'2.096i'\l'0.875i' +.sp -1 +\h'2.837i'\v'2.121i'\D'l0.100i -0.025i' +.sp -1 +\h'2.837i'\v'2.071i'\D'l0.100i 0.025i' +.sp -1 +\h'3.000i'\v'0.034i'\v'-.13m'\L'3.374i\(br'\v'.13m' +.sp -1 +\h'4.875i'\v'0.034i'\v'-.13m'\L'3.374i\(br'\v'.13m' +.sp -1 +\h'2.013i'\v'2.871i'\D'l0.937i 0.250i' +.sp -1 +\h'2.847i'\v'3.119i'\D'l0.103i 0.002i' +.sp -1 +\h'2.860i'\v'3.071i'\D'l0.090i 0.050i' +.sp -1 +\h'3.062i'\v'3.134i'\D'l1.688i 0.187i' +.sp -1 +\h'4.648i'\v'3.335i'\D'l0.102i -0.014i' +.sp -1 +\h'4.653i'\v'3.285i'\D'l0.097i 0.036i' +.sp -1 +\h'3.062i'\v'2.533i'\D'l1.750i 0.213i' +.sp -1 +\h'4.710i'\v'2.759i'\D'l0.102i -0.013i' +.sp -1 +\h'4.716i'\v'2.709i'\D'l0.096i 0.037i' +.sp -1 +\h'3.062i'\v'2.096i'\l'1.750i' +.sp -1 +\h'4.712i'\v'2.121i'\D'l0.100i -0.025i' +.sp -1 +\h'4.712i'\v'2.071i'\D'l0.100i 0.025i' +.sp -1 +\h'4.812i'\v'2.284i'\l'-1.750i' +.sp -1 +\h'3.162i'\v'2.259i'\D'l-0.100i 0.025i' +.sp -1 +\h'3.162i'\v'2.309i'\D'l-0.100i -0.025i' +.sp -1 +\h'1.250i'\v'0.193i'\h'-0.0m'\v'0.2m'\s10\fRXNextEvent\fP +.sp -1 +\h'1.250i'\v'0.381i'\h'-0.0m'\v'0.2m'\s10\fRXFilterEvent\fP +.sp -1 +\h'1.250i'\v'0.881i'\h'-0.0m'\v'0.2m'\s10\fRXNextEvent\fP +.sp -1 +\h'1.250i'\v'1.068i'\h'-0.0m'\v'0.2m'\s10\fRXFilterEvent\fP +.sp -1 +\h'1.250i'\v'1.506i'\h'-0.0m'\v'0.2m'\s10\fRXNextEvent\fP +.sp -1 +\h'1.250i'\v'1.881i'\h'-0.0m'\v'0.2m'\s10\fRXmbLookupString\fP +.sp -1 +\h'4.875i'\h'-0.0m'\v'0.2m'\s12\fRIM Server\fP +.sp -1 +\h'2.437i'\h'-0.0m'\v'0.2m'\s12\fRIM library\fP +.sp -1 +\h'1.250i'\v'1.693i'\h'-0.0m'\v'0.2m'\s10\fRXFilterEvent (returns False) \fP +.sp -1 +\v'2.168i'\h'-0.0m'\v'0.2m'\s10\fRthe focus\fP +.sp -1 +\h'1.250i'\h'-0.0m'\v'0.2m'\s12\fRXlib API\fP +.sp -1 +\v'2.006i'\h'-0.0m'\v'0.2m'\s10\fRApplication moves\fP +.sp -1 +\h'3.187i'\v'0.443i'\h'-0.0m'\v'0.2m'\s10\fRXIM_FORWARD_EVENT\fP +.sp -1 +\h'3.187i'\v'0.881i'\h'-0.0m'\v'0.2m'\s10\fRXIM_FORWARD_EVENT\fP +.sp -1 +\h'3.187i'\v'1.631i'\h'-0.0m'\v'0.2m'\s10\fRXIM_FORWARD_EVENT\fP +.sp -1 +\h'3.187i'\v'1.006i'\h'-0.0m'\v'0.2m'\s10\fRor XIM_COMMIT\fP +.sp -1 +\h'5.000i'\v'0.881i'\h'-0.0m'\v'0.2m'\s10\fRsynchronous \fP +.sp -1 +\h'5.000i'\v'1.006i'\h'-0.0m'\v'0.2m'\s10\fRrequest\fP +.sp -1 +\h'0.062i'\v'0.193i'\h'-0.0m'\v'0.2m'\s10\fRKey event\fP +.sp -1 +\h'0.062i'\v'0.881i'\h'-0.0m'\v'0.2m'\s10\fRKey event\fP +.sp -1 +\h'3.187i'\v'1.131i'\h'-0.0m'\v'0.2m'\s10\fR(synchronous) \fP +.sp -1 +\h'5.000i'\v'1.443i'\h'-0.0m'\v'0.2m'\s10\fRPending\fP +.sp -1 +\h'5.000i'\v'2.381i'\h'-0.0m'\v'0.2m'\s10\fRprocessed\fP +.sp -1 +\h'5.000i'\v'2.506i'\h'-0.0m'\v'0.2m'\s10\fR(The focused\fP +.sp -1 +\h'5.000i'\v'2.631i'\h'-0.0m'\v'0.2m'\s10\fRIC is changed) \fP +.sp -1 +\h'5.000i'\v'2.881i'\h'-0.0m'\v'0.2m'\s10\fRprocessed\fP +.sp -1 +\h'1.250i'\v'2.131i'\h'-0.0m'\v'0.2m'\s10\fRXSetICFocus\fP +.sp -1 +\h'3.125i'\v'2.881i'\h'-0.0m'\v'0.2m'\s10\fRXIM_SYNC_REPLY as a reply\fP +.sp -1 +\h'3.125i'\v'3.043i'\h'-0.0m'\v'0.2m'\s10\fRof the XIM_FORWARD_EVENT\fP +.sp -1 +\h'1.250i'\v'2.881i'\h'-0.0m'\v'0.2m'\s10\fRXNextEvent\fP +.sp -1 +\h'3.312i'\v'2.506i'\h'-0.0m'\v'0.2m'\s10\fRXIM_SET_IC_FOCUS\fP +.sp -1 +\h'3.312i'\v'2.006i'\h'-0.0m'\v'0.2m'\s10\fRXIM_SYNC\fP +.sp -1 +\h'3.312i'\v'2.193i'\h'-0.0m'\v'0.2m'\s10\fRXIM_SYNC_REPLY\fP +.sp -1 +\h'5.000i'\v'3.381i'\h'-0.0m'\v'0.2m'\s10\fRprocessed\fP +.sp -1 +.sp 1+3.408i +.PE +.if \n(00 .fi + +.\"====================== event flow figure end ======================= +.ce +.sp +Fig.2 Sample Protocol Flow +.sp +.LP +.B +Sample Protocol flow chart 2 +.R +.LP +Following chart shows one of the complex protocol flow, which deals +with multiple focus windows and button press event as well as keyevent, +and the focus is moved by the application triggered by both of keyevent +and button press event. +.LP +.bp +.\"====================== event2 flow figure start ===================== +\^... 0.425 5.575 6.3 10.296 +\^... 0.000i 4.721i 5.875i 0.000i +.nr 00 \n(.u +.nf +.PS 4.721i 5.875i +.br +.ps 11 +\h'3.125i'\v'0.496i'\D'l1.625i 0.163i' +.sp -1 +\h'4.648i'\v'0.674i'\D'l0.102i -0.015i' +.sp -1 +\h'4.653i'\v'0.624i'\D'l0.097i 0.035i' +.sp -1 +\h'2.000i'\v'0.409i'\D'l1.000i 0.062i' +.sp -1 +\h'2.899i'\v'0.490i'\D'l0.101i -0.019i' +.sp -1 +\h'2.902i'\v'0.440i'\D'l0.098i 0.031i' +.sp -1 +\h'0.688i'\v'0.159i'\l'0.437i' +.sp -1 +\h'1.025i'\v'0.184i'\D'l0.100i -0.025i' +.sp -1 +\h'1.025i'\v'0.134i'\D'l0.100i 0.025i' +.sp -1 +\h'1.250i'\v'0.193i'\h'-0.0m'\v'0.2m'\s10\fRXNextEvent\fP +.sp -1 +\h'1.250i'\v'0.381i'\h'-0.0m'\v'0.2m'\s10\fRXFilterEvent\fP +.sp -1 +\h'3.187i'\v'0.443i'\h'-0.0m'\v'0.2m'\s10\fRXIM_FORWARD_EVENT\fP +.sp -1 +\h'0.062i'\v'0.193i'\h'-0.0m'\v'0.2m'\s10\fRKey event\fP +.sp -1 +\h'3.125i'\v'1.221i'\D'l1.687i 0.125i' +.sp -1 +\h'4.710i'\v'1.364i'\D'l0.102i -0.018i' +.sp -1 +\h'4.714i'\v'1.314i'\D'l0.098i 0.032i' +.sp -1 +\h'4.750i'\v'0.971i'\D'l-1.625i 0.750i' +.sp -1 +\h'3.205i'\v'1.656i'\D'l-0.080i 0.065i' +.sp -1 +\h'3.226i'\v'1.702i'\D'l-0.101i 0.019i' +.sp -1 +\h'2.000i'\v'1.034i'\D'l1.000i 0.125i' +.sp -1 +\h'2.898i'\v'1.171i'\D'l0.102i -0.012i' +.sp -1 +\h'2.904i'\v'1.122i'\D'l0.096i 0.037i' +.sp -1 +\h'0.688i'\v'0.846i'\l'0.437i' +.sp -1 +\h'1.025i'\v'0.871i'\D'l0.100i -0.025i' +.sp -1 +\h'1.025i'\v'0.821i'\D'l0.100i 0.025i' +.sp -1 +\h'3.000i'\v'0.034i'\v'-.13m'\L'4.687i\(br'\v'.13m' +.sp -1 +\h'0.750i'\v'1.346i'\l'0.313i' +.sp -1 +\h'0.963i'\v'1.371i'\D'l0.100i -0.025i' +.sp -1 +\h'0.963i'\v'1.321i'\D'l0.100i 0.025i' +.sp -1 +\h'3.125i'\v'1.509i'\D'l1.687i 0.125i' +.sp -1 +\h'4.710i'\v'1.652i'\D'l0.102i -0.018i' +.sp -1 +\h'4.714i'\v'1.602i'\D'l0.098i 0.032i' +.sp -1 +\h'4.812i'\v'1.721i'\D'l-1.687i 0.188i' +.sp -1 +\h'3.222i'\v'1.873i'\D'l-0.097i 0.036i' +.sp -1 +\h'3.227i'\v'1.923i'\D'l-0.102i -0.014i' +.sp -1 +\h'2.937i'\v'1.971i'\D'l-0.937i 0.188i' +.sp -1 +\h'2.093i'\v'2.115i'\D'l-0.093i 0.044i' +.sp -1 +\h'2.103i'\v'2.164i'\D'l-0.103i -0.005i' +.sp -1 +\h'1.125i'\v'2.533i'\l'-0.500i' +.sp -1 +\h'0.725i'\v'2.508i'\D'l-0.100i 0.025i' +.sp -1 +\h'0.725i'\v'2.558i'\D'l-0.100i -0.025i' +.sp -1 +\h'5.562i'\v'1.346i'\l'0.313i' +.sp -1 +\h'5.875i'\v'1.346i'\v'-.13m'\L'2.687i\(br'\v'.13m' +.sp -1 +\h'5.875i'\v'4.033i'\D'l-0.250i 0.000i' +.sp -1 +\h'5.725i'\v'4.008i'\D'l-0.100i 0.025i' +.sp -1 +\h'5.725i'\v'4.058i'\D'l-0.100i -0.025i' +.sp -1 +\h'2.013i'\v'3.559i'\D'l0.937i 0.250i' +.sp -1 +\h'2.847i'\v'3.807i'\D'l0.103i 0.002i' +.sp -1 +\h'2.860i'\v'3.759i'\D'l0.090i 0.050i' +.sp -1 +\h'3.062i'\v'3.821i'\D'l1.688i 0.188i' +.sp -1 +\h'4.648i'\v'4.023i'\D'l0.102i -0.014i' +.sp -1 +\h'4.653i'\v'3.973i'\D'l0.097i 0.036i' +.sp -1 +\h'2.000i'\v'1.358i'\D'l1.000i 0.126i' +.sp -1 +\h'2.898i'\v'1.496i'\D'l0.102i -0.012i' +.sp -1 +\h'2.904i'\v'1.447i'\D'l0.096i 0.037i' +.sp -1 +\h'3.062i'\v'2.159i'\D'l-0.250i 0.000i' +.sp -1 +\h'2.812i'\v'2.159i'\v'-.13m'\L'1.812i\(br'\v'.13m' +.sp -1 +\h'2.812i'\v'3.971i'\D'l0.125i 0.125i' +.sp -1 +\h'2.849i'\v'4.043i'\D'l0.088i 0.053i' +.sp -1 +\h'2.884i'\v'4.008i'\D'l0.053i 0.088i' +.sp -1 +\h'2.062i'\v'2.783i'\l'0.875i' +.sp -1 +\h'2.837i'\v'2.808i'\D'l0.100i -0.025i' +.sp -1 +\h'2.837i'\v'2.758i'\D'l0.100i 0.025i' +.sp -1 +\h'2.062i'\v'3.783i'\D'l0.813i 0.438i' +.sp -1 +\h'2.775i'\v'4.196i'\D'l0.100i 0.025i' +.sp -1 +\h'2.799i'\v'4.152i'\D'l0.076i 0.069i' +.sp -1 +\h'0.625i'\v'3.533i'\l'0.438i' +.sp -1 +\h'0.963i'\v'3.558i'\D'l0.100i -0.025i' +.sp -1 +\h'0.963i'\v'3.508i'\D'l0.100i 0.025i' +.sp -1 +\h'3.062i'\v'4.346i'\D'l1.625i 0.163i' +.sp -1 +\h'4.585i'\v'4.524i'\D'l0.102i -0.015i' +.sp -1 +\h'4.590i'\v'4.474i'\D'l0.097i 0.035i' +.sp -1 +\h'4.875i'\v'0.034i'\v'-.13m'\L'4.687i\(br'\v'.13m' +.sp -1 +\h'3.062i'\v'4.146i'\D'l1.688i 0.187i' +.sp -1 +\h'4.648i'\v'4.347i'\D'l0.102i -0.014i' +.sp -1 +\h'4.653i'\v'4.297i'\D'l0.097i 0.036i' +.sp -1 +\h'3.062i'\v'2.871i'\D'l1.750i 0.212i' +.sp -1 +\h'4.710i'\v'3.096i'\D'l0.102i -0.013i' +.sp -1 +\h'4.716i'\v'3.046i'\D'l0.096i 0.037i' +.sp -1 +\h'1.250i'\v'0.881i'\h'-0.0m'\v'0.2m'\s10\fRXNextEvent\fP +.sp -1 +\h'1.250i'\v'1.068i'\h'-0.0m'\v'0.2m'\s10\fRXFilterEvent\fP +.sp -1 +\h'4.875i'\h'-0.0m'\v'0.2m'\s12\fRIM Server\fP +.sp -1 +\h'2.437i'\h'-0.0m'\v'0.2m'\s12\fRIM library\fP +.sp -1 +\h'1.250i'\h'-0.0m'\v'0.2m'\s12\fRXlib API\fP +.sp -1 +\h'3.187i'\v'0.881i'\h'-0.0m'\v'0.2m'\s10\fRXIM_FORWARD_EVENT\fP +.sp -1 +\h'5.000i'\v'0.881i'\h'-0.0m'\v'0.2m'\s10\fRsynchronous \fP +.sp -1 +\h'5.000i'\v'1.006i'\h'-0.0m'\v'0.2m'\s10\fRrequest\fP +.sp -1 +\h'0.062i'\v'0.881i'\h'-0.0m'\v'0.2m'\s10\fRKey event\fP +.sp -1 +\h'3.187i'\v'1.131i'\h'-0.0m'\v'0.2m'\s10\fR(synchronous) \fP +.sp -1 +\h'0.062i'\v'1.256i'\h'-0.0m'\v'0.2m'\s10\fRButton press causes\fP +.sp -1 +\h'0.062i'\v'1.381i'\h'-0.0m'\v'0.2m'\s10\fRfocus change\fP +.sp -1 +\h'1.250i'\v'1.381i'\h'-0.0m'\v'0.2m'\s10\fRXSetICFocus\fP +.sp -1 +\h'3.250i'\v'1.006i'\h'-0.0m'\v'0.2m'\s10\fRor XIM_COMMIT\fP +.sp -1 +\h'3.187i'\v'1.443i'\h'-0.0m'\v'0.2m'\s10\fRXIM_FORWARD_EVENT\fP +.sp -1 +\h'3.687i'\v'1.693i'\h'-0.0m'\v'0.2m'\s10\fRXIM_SYNC\fP +.sp -1 +\h'3.375i'\v'2.006i'\h'-0.0m'\v'0.2m'\s10\fRXIM_SYNC_REPLY\fP +.sp -1 +\h'1.250i'\v'2.193i'\h'-0.0m'\v'0.2m'\s10\fRXNextEvent\fP +.sp -1 +\h'1.250i'\v'2.568i'\h'-0.0m'\v'0.2m'\s10\fRXmbLookupString\fP +.sp -1 +\h'1.250i'\v'2.381i'\h'-0.0m'\v'0.2m'\s10\fRXFilterEvent (returns False) \fP +.sp -1 +\v'2.856i'\h'-0.0m'\v'0.2m'\s10\fRthe focus\fP +.sp -1 +\v'2.693i'\h'-0.0m'\v'0.2m'\s10\fRApplication moves\fP +.sp -1 +\h'5.000i'\v'3.068i'\h'-0.0m'\v'0.2m'\s10\fRprocessed\fP +.sp -1 +\h'5.000i'\v'3.193i'\h'-0.0m'\v'0.2m'\s10\fR(The focused\fP +.sp -1 +\h'5.000i'\v'3.318i'\h'-0.0m'\v'0.2m'\s10\fRIC is changed) \fP +.sp -1 +\h'5.000i'\v'3.568i'\h'-0.0m'\v'0.2m'\s10\fRprocessed\fP +.sp -1 +\h'3.125i'\v'3.568i'\h'-0.0m'\v'0.2m'\s10\fRXIM_SYNC_REPLY as a reply\fP +.sp -1 +\h'3.125i'\v'3.731i'\h'-0.0m'\v'0.2m'\s10\fRof the XIM_FORWARD_EVENT\fP +.sp -1 +\h'1.250i'\v'3.568i'\h'-0.0m'\v'0.2m'\s10\fRXNextEvent\fP +.sp -1 +\h'5.000i'\v'4.068i'\h'-0.0m'\v'0.2m'\s10\fRprocessed\fP +.sp -1 +\h'5.000i'\v'1.381i'\h'-0.0m'\v'0.2m'\s10\fRPending\fP +.sp -1 +\h'5.000i'\v'4.256i'\h'-0.0m'\v'0.2m'\s10\fRprocessed\fP +.sp -1 +\h'1.250i'\v'2.818i'\h'-0.0m'\v'0.2m'\s10\fRXSetICFocus\fP +.sp -1 +\h'3.125i'\v'2.443i'\h'-0.0m'\v'0.2m'\s10\fRis started by XIM_COMMIT\fP +.sp -1 +\h'3.125i'\v'2.193i'\h'-0.0m'\v'0.2m'\s10\fRXIM_SET_IC_FOCUS is\fP +.sp -1 +\h'3.125i'\v'2.318i'\h'-0.0m'\v'0.2m'\s10\fRpend because another sync cycle\fP +.sp -1 +\h'2.062i'\v'1.693i'\h'-0.0m'\v'0.2m'\s10\fRsync cycle is done\fP +.sp -1 +\h'2.062i'\v'1.568i'\h'-0.0m'\v'0.2m'\s10\fRPending until\fP +.sp -1 +\v'3.568i'\h'-0.0m'\v'0.2m'\s10\fRKey event\fP +.sp -1 +\h'1.250i'\v'3.756i'\h'-0.0m'\v'0.2m'\s10\fRXFilterEvent\fP +.sp -1 +\h'3.125i'\v'4.631i'\h'-0.0m'\v'0.2m'\s10\fRXIM_FORWARD_EVENT\fP +.sp -1 +\h'3.375i'\v'4.131i'\h'-0.0m'\v'0.2m'\s10\fRXIM_SET_IC_FOCUS\fP +.sp -1 +\h'3.250i'\v'2.818i'\h'-0.0m'\v'0.2m'\s10\fRXIM_SET_IC_FOCUS\fP +.sp -1 +.sp 1+4.721i +.PE +.if \n(00 .fi + +.\"====================== event2 flow figure end ======================= +.ce +.sp +Fig.3 Sample Protocol Flow chart +.LP +.LP +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_FORWARD_EVENT (IM library \(<-\(-> IM Server) +.sp 6p +:2:CARD16:input-method-ID +:2:CARD16:input-context-ID +:2:BITMASK16:flag +::#0001:synchronous +::#0002:request filtering (*1) +::#0004:request lookupstring (*2) +:2:CARD16:serial number +::XEVENT:X event +.TE +.LP +.IP (*1) +Indicate the receiver should filter events and possible preedit may be invoked. +.IP (*2) +Indicate the receiver should only do lookup string. The IM Server is expected +to just do a conversion of the key event to the best candidate. This bit may +affect the state of the preedit state (e.g. compose of dead key sequences). +.RE +.LP +XEVENT format is same as the X Protocol event format(xEvent). +As the value of xEvent's sequenceNumber is the bottom of 16 bit of XEvent's +xany.serial, the top of 16 bit is sent by serial number(INT16). +.LP +.PN XIM_FORWARD_EVENT +message is used for forwarding the events from the IM library to the IM Server +in order for IM to be able to filter the event. On the other hand, this +message is also used for forwarding the events from the IM Server to the IM +library if the event forwarded from the IM library is not filtered. +The IM Server, which receives +.PN XIM_FORWARD_EVENT +message without synchronous bit, should set synchronous bit. +If both ``request event filtering'' and ``request lookupstring'' flag are +set, then both filtering and lookup should be done for the same event. +.LP +.NH 2 +Synchronizing with the IM Server +.XS +\*(SN Synchronizing with the IM Server +.XE +.LP +.PN XIM_SYNC +message requests to synchronize the IM library and the IM Server. +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_SYNC (IM library \(<-\(-> IM Server) +.sp 6p +:2:CARD16:input-method-ID +:2:CARD16:input-context-ID +.TE +.RE +.LP +This synchronization can be started either on the IM library side or on the +IM Server side. The side which receives +.PN XIM_SYNC +message should process all XIM requests before replying. The input-context-ID +is necessary to distinguish the IC with which the IM library and the IM +Server are synchronized. +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_SYNC_REPLY (IM Server \(<-\(-> IM library) +.sp 6p +:2:CARD16:input-method-ID +:2:CARD16:input-context-ID +.TE +.RE +.LP +The side which receives +.PN XIM_FORWARD_EVENT, +.PN XIM_COMMIT +or any other message with synchronous bit, should process all XIM request +before replying, and send +.PN XIM_SYNC_REPLY +message as the reply to the previous message. +.LP +.NH 2 +Sending a committed string +.XS +\*(SN Sending a committed string +.XE +.LP +When the IM Server commits a string, the IM Server sends either the committed +string or list of KeySym, or both, by +.PN XIM_COMMIT +message. +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_COMMIT (IM Server \(-> IM library) +.sp 6p +:2:CARD16:input-method-ID +:2:CARD16:input-context-ID +:2:BITMASK16:flag +::#0001:synchronous +::#0002:XLookupChars +::#0004:XLookupKeySym +::#0006: XLookupBoth = XLookupChars | XLookupKeySym +.TE +.LP +If flag is XLookupKeySym, the arguments continue as follows: +.TS +tab(:); +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +:2::unused +:4:KEYSYM:KeySym +.TE +.LP +If flag is XLookupChars, the arguments continue as follows: +.TS +tab(:); +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +:2:m:byte length of committed string +:m:LISTofBYTE:committed string +:p::unused, p = Pad(m) +.TE +.LP +If flag is XLookupBoth, the arguments continue as follows: +.TS +tab(:); +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +:2::unused +:4:KEYSYM:KeySym +:2:n:byte length of committed string +:n:LISTofBYTE:committed string +:p::unused, p = Pad(2+n) +.TE +.RE +.LP +The IM Server which receives +.PN XIM_COMMIT +message without synchronous bit should set synchronous bit. +.LP +.NH 2 +Reset IC +.XS +\*(SN Reset IC +.XE +.LP +.PN XIM_RESET_IC +message requests to reset the status of IC in the IM Server. +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_RESET_IC (IM library \(-> IM Server) +.sp 6p +:2:CARD16:input-method-ID +:2:CARD16:input-context-ID +.TE +.RE +.LP +.PN XIM_RESET_IC +is a synchronous request. The IM library should wait until receiving either an +.PN XIM_RESET_IC_REPLY +packet or an +.PN XIM_ERROR +packet. +.LP +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_RESET_IC_REPLY (IM Server \(-> IM library) +.sp 6p +:2:CARD16:input-method-ID +:2:CARD16:input-context-ID +:2:n:byte length of preedit string +:n:LISTofBYTE:preedit string +:p::unused, p = Pad(2+n) +.TE +.RE +.LP +.PN XIM_RESET_IC_REPLY +message returns the input-context-ID to distinguish replies from multiple ICs. +.LP +.\"============================== Callbacks =============================== +.NH 2 +Callbacks +.XS +\*(SN Callbacks +.XE +.LP +If XIMStyle has XIMPreeditArea or XIMStatusArea set, XIMGeometryCallback +may be used, and if XIMPreeditCallback and/or XIMStatusCallback are set, +corresponding callbacks may be used. +.LP +Any callback request may be sent from an IM Server to an IM client +asynchronously in response to any request previously sent by the IM client +to the IM Server. +.LP +When an IM Server needs to send a callback request synchronously with +the request previously sent by an IM client, the IM Server sends it +before replying to the previous request. +.LP +.NH 3 +Negotiating geometry +.XS +\*(SN Negotiating geometry +.XE +.LP +The IM Server sends +.PN XIM_GEOMETRY +message to start geometry negotiation, if XIMStyle has XIMPreeditArea or +XIMStatusArea set. +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_GEOMETRY (IM Server \(-> IM library) +.sp 6p +:2:CARD16:input-method-ID +:2:CARD16:input-context-ID +.TE +.RE +.LP +There is always a single Focus Window, even if some input fields have only +one IC. +.LP +.NH 3 +Converting a string +.XS +\*(SN Converting a string +.XE +.LP +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_STR_CONVERSION (IM Server \(-> IM library) +.sp 6p +:2:CARD16:input-method-ID +:2:CARD16:input-context-ID +:2:CARD16:XIMStringConversionPosition +:2::unused +:4:CARD32:XIMCaretDirection +::#0:XIMForwardChar +::#1:XIMBackwardChar +::#2:XIMForwardWord +::#3:XIMBackwardWord +::#4:XIMCaretUp +::#5:XIMCaretDown +::#6:XIMNextLine +::#7:XIMCPreviousLine +::#8:XIMLineStart +::#9:XIMLineEnd +::#10:XIMAbsolutePosition +::#11:XIMDontChange +:2:CARD16:factor +:2:CARD16:XIMStringConversionOperation +::#0001:XIMStringConversionSubstitution +::#0002:XIMStringConversionRetrieval +:2:INT16:T{ +byte length to multiply the XIMStringConversionType +T} +.TE +.RE +.sp +.LP +.PN XIM_STR_CONVERSION +message may be used to start the string conversion from the IM +Server. +.LP +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_STR_CONVERSION_REPLY (IM library \(-> IM Server) +.sp 6p +:2:CARD16:input-method-ID +:2:CARD16:input-context-ID +:4:CARD32:XIMStringConversionFeedback +::XIMSTRCONVTEXT:XIMStringConversionText +.sp +.TE +.RE +.LP +.PN XIM_STR_CONVERSION_REPLY +message returns the string to be converted and the feedback information array. +.LP +.NH 3 +Preedit Callbacks +.XS +\*(SN Preedit Callbacks +.XE +.LP +The IM Server sends +.PN XIM_PREEDIT_START +message to call the XIMPreeditStartCallback function. +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_PREEDIT_START (IM Server \(-> IM library) +.sp 6p +:2:CARD16:input-method-ID +:2:CARD16:input-context-ID +.TE +.RE +.LP +The reply to this message must be sent synchronously. The reply forwards +the return value from the callback function to the IM Server. +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_PREEDIT_START_REPLY (IM library \(-> IM Server) +.sp 6p +:2:CARD16:input-method-ID +:2:CARD16:input-context-ID +:4:INT32:return value +.TE +.RE +.LP +.PN XIM_PREEDIT_START_REPLY +message returns the input-context-ID to distinguish replies from multiple +IC's. The return value contains the return value of the function +XIMPreeditStartCallback. +.LP +The IM Server sends +.PN XIM_PREEDIT_DRAW +message to call the XIMPreeditDrawCallback function. +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_PREEDIT_DRAW (IM Server \(-> IM library) +.sp 6p +:2:CARD16:input-method-ID +:2:CARD16:input-context-ID +:4:INT32:caret +:4:INT32:chg_first +:4:INT32:chg_length +:4:BITMASK32:status +::#x0000001:no string +::#x0000002:no feedback +:2:n:length of preedit string +:n:STRING8:preedit string +:p::unused, p = Pad(2+n) +:2:m:byte length of feedback array +:2::unused +:m:LISTofXIMFEEDBACK:feedback array +.TE +.RE +.LP +The fields ``caret'', ``chg_first'' and ``chg_length'' correspond to the +fields of XIMPreeditDrawCallbackStruct. +When the ``no string'' bit of the status field is set, the text field of +XIMPreeditDrawCallbackStruct is NULL. +When the ``no feedback'' bit of the status field is set, the text feedback +field of XIMPreeditDrawCallbackStruct is NULL. +When the above bits are not set, ``preedit string'' contains the preedit +string to be displayed, and the feedback array contains feedback information. +.LP +The IM Server sends +.PN XIM_PREEDIT_CARET +message to call the PreeditCaretCallback function. +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_PREEDIT_CARET (IM Server \(-> IM library) +.sp 6p +:2:CARD16:input-method-ID +:2:CARD16:input-context-ID +:4:INT32:position +:4:CARD32:direction +::#0:XIMForwardChar +::#1:XIMBackwardChar +::#2:XIMForwardWord +::#3:XIMBackwardWord +::#4:XIMCaretUp +::#5:XIMCaretDown +::#6:XIMNextLine +::#7:XIMCPreviousLine +::#8:XIMLineStart +::#9:XIMLineEnd +::#10:XIMAbsolutePosition +::#11:XIMDontChange +:4:CARD32:style +::#0:XIMInvisible +::#1:XIMCPrimary +::#2:XIMSecondary +.TE +.RE +.LP +Each entry corresponds to a field of XIMPreeditCaretCallbackStruct. +Since this callback sets the caret position, its reply must be sent +synchronously. +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_PREEDIT_CARET_REPLY (IM library \(-> IM Server) +.sp 6p +:2:CARD16:input-method-ID +:2:CARD16:input-context-ID +:4:CARD32:position +.TE +.RE +.LP +The position is the value returned by the callback function after it +has been called. +.LP +The IM Server sends +.PN XIM_PREEDIT_DONE +message to call the XIMPreeditDoneCallback function. +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_PREEDIT_DONE (IM Server \(-> IM library) +.sp 6p +:2:CARD16:input-method-ID +:2:CARD16:input-context-ID +.TE +.RE +.LP +.NH 3 +Preedit state notify +.XS +\*(SN Preedit state notify +.XE +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_PREEDITSTATE (IM Server \(-> IM Library) +.sp 6p +:2:CARD16:input-method-ID +:2:CARD16:input-context-ID +:4:BITMASK32:XIMPreeditState +::#x0000000:XIMPreeditUnknown +::#x0000001:XIMPreeditEnable +::#x0000002:XIMPreeditDisable +.TE +.sp +.TE +.RE +.LP +.PN XIM_PREEDITSTATE +message is used to call the XIMPreeditStateNotifyCallback function. +.LP +.NH 3 +Status Callbacks +.XS +\*(SN Status Callbacks +.XE +.LP +The IM Server sends +.PN XIM_STATUS_START +message to call the XIMStatusStartCallback function. +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_STATUS_START (IM Server \(-> IM library) +.sp 6p +:2:CARD16:input-method-ID +:2:CARD16:input-context-ID +.TE +.RE +.LP +The IM Server sends +.PN XIM_STATUS_DRAW +message to call the XIMStatusDrawCallback function. +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_STATUS_DRAW (IM Server \(-> IM library) +.sp 6p +:2:CARD16:input-method-ID +:2:CARD16:input-context-ID +:4:CARD32:type +::#0:XIMTextType +::#1:XIMBitmapType +.TE +.LP +If type is XIMTextType, the arguments continue as follows. +.TS +tab(:); +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +:4:BITMASK32:status +::#x0000001:no string +::#x0000002:no feedback +:2:n:length of status string +:n:STRING8:status string +:p::unused, p = Pad(2+n) +:2:m:byte length of feedback array +:2::unused +:m:LISTofXIMFEEDBACK:feedback array +.TE +.LP +If type is XIMBitmapType, the arguments continue as follows. +.TS +tab(:); +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +:4:PIXMAP:pixmap data +.TE +.RE +.LP +The field ``type'' corresponds to the field in XIMStatusDrawCallbackStruct. +.LP +The IM Server sends +.PN XIM_STATUS_DONE +message to call the XIMStatusDoneCallback function. +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_STATUS_DONE (IM Server \(-> IM library) +.sp 6p +:2:CARD16:input-method-ID +:2:CARD16:input-context-ID +.TE +.RE +.LP +.bp +.NH 1 +Acknowledgements +.XS +\*(SN Acknowledgements +.XE +.LP +This document represents the culmination of several years of debate and +experiments done under the auspices of the MIT X Consortium i18n working +group. Although this was a group effort, the author remains responsible +for any errors or omissions. +.LP +We would like to thank to all members of this group. +And we would like to make special thanks to the following people +(in alphabetical order) for their participation in the IM Protocol +design, +Hector Chan, Takashi Fujiwara, Yoshio Horiuchi, Makoto Inada, +Hiromu Inukai, Mickael Kung, Seiji Kuwari, Franky Ling, Hiroyuki Machida, +Hiroyuki Miyamoto, Frank Rojas, Bob Scheifler, Makiko Shimamura, +Shoji Sugiyama, Hidetoshi Tajima, Masaki Takeuchi, Makoto Wakamatsu, +Masaki Wakao, Nobuyuki Tanaka, Shigeru Yamada, Katsuhisa Yano, Jinsoo Yoon. +.LP +.NH 1 +References +.XS +\*(SN References +.XE +.LP +All of the following documents are X Consortium standards available from MIT: +.LP +[1] Scheifler, Robert W., \fI``X Window System Protocol Version 11''\fP +.LP +[2] Scheifler, Robert W. etc., \fI``Xlib \- C Language X Interface''\fP +.LP +.bp +.XS +Appendix A \- Common Extensions +.XE +.ce 10 +.sp 5 +\s+2\fBAppendix A\fP\s-2 +.sp +\s+1\fBCommon Extensions\fP\s-1 +.ce 0 +.sp +.LP +Extension opcodes and packet names (e.g. +.PN XIM_EXT_SET_EVENT_MASK +) for additional extensions may be registered with X Consortium. +The following is a commonly well-known extended packet. +.LP +.LP +.IP \fB(1) +Extension to manipulate the event handling\fP +.LP +.PN XIM_EXT_SET_EVENT_MASK +message specifies the set of event masks that the IM library should manipulate. +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_EXT_SET_EVENT_MASK (IM Server \(-> IM library) +.sp 6p +:2:CARD16:input-method-ID +:2:CARD16:input-context-ID +:4:EVENTMASK:filter-event-mask (*1) +:4:EVENTMASK:intercept-event-mask (*2) +:4:EVENTMASK:select-event-mask (*3) +:4:EVENTMASK:forward-event-mask (*4) +:4:EVENTMASK:synchronous-event-mask (*5) +.TE +.IP (*1) +Specify the events to be neglected by the IM library via XFilterEvent. +.IP (*2) +Specify the events to be deselected by the IM library with XSelectInput. +.IP (*3) +Specify the events to be selected by the IM library with XSelectInput. +.IP (*4) +Specify all the events to be forwarded to the IM Server by the IM library. +.IP (*5) +Specify the events to be forwarded with synchronous flag on by the IM library. +.RE +.LP +The IM library must reply +.PN XIM_SYNC_REPLY +message to the IM Server. This request is valid after the ic is created. +.LP +.sp +.IP \fB(2) +Extension for improvement of performance\fR +.LP +The following requests may be used for improvement of performance. +.LP +.PN XIM_EXT_FORWARD_KEYEVENT +message may be used instead of +.PN XIM_FORWARD_EVENT +message. +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_EXT_FORWARD_KEYEVENT (IM Server \(<-\(-> IM library) +.sp 6p +:2:CARD16:input-method-ID +:2:CARD16:input-context-ID +:2:BITMASK16:flag +::#0001:synchronous +:2:CARD16:sequence number +:1:BYTE:xEvent.u.u.type +:1:BYTE:keycode +:2:CARD16:state +:4:CARD32:time +:4:CARD32:window +.TE +.RE +.LP +.bp +.PN XIM_EXT_MOVE +message may be used to change the spot location instead of +.PN +XIM_SET_IC_VALUES +message. +It is effective only if the client specified XIMPreeditPosition. +.RS +.TS +tab(:); +lfB s s s +lw(.25i) lw(.25i) lw(1.75i) lw(3.5i). +XIM_EXT_MOVE (IM library \(-> IM Server) +.sp 6p +:2:CARD16:input-method-ID +:2:CARD16:input-context-ID +:2:INT16:X +:2:INT16:Y +.TE +.RE +.LP +.PN XIM_EXT_MOVE +message is a asynchronous request. +.LP +.bp +.XS +Appendix B \- The list of transport specific IM Server names registered +.XE +.ce 10 +.sp 5 +\s+2\fBAppendix B\fP\s-2 +.sp +\s+1\fBThe list of transport specific IM Server address format registered\fP\s-1 +.ce 0 +.sp +.LP +The following format represents the ATOM contained in +.PN XIM_SERVERS +property and the string returned from the request converting +selection target LOCALES and TRANSPORT. +.DS + ``{@\^\fIcategory\fP\^=[\^\fIvalue\fP,...]}...'' +.DE +.LP +The following categories are currently registered. +.RS +.TS +tab(;); +l l. +\fBserver\fP;: IM Server name (used for XIM_SERVERS) +\fBlocale\fP;: XPG4 locale name (LOCALES) +\fBtransport\fP;: transport-specific name (TRANSPORT) +.TE +.RE +.LP +The preregistered formats for transport-specific names are as follows: +.RS +.LP +\fBTCP/IP Names\fP +.LP +.RS +The following syntax should be used for system internal domain names: +.DS +<\fIlocal name\fP> ::= ``local/''<\fIhostname\fP>``:''<\fIpathname\fP> +.DE +.LP +Where <\fIpathname\fP> is a path name of socket address. +.LP +IM Server's name should be set to <\fIpathname\fP> to run multiple IM Server +at the same time +.LP +The following syntax should be used for Internet domain names: +.DS +<\fITCP name\fP> ::= ``tcp/''<\fIhostname\fP>``:''<\fIipportnumber\fP> +.DE +where <\fIhostname\fP> is either symbolic (such as expo.lcs.mit.edu) or +numeric decimal (such as 18.30.0.212). The <\fIipportnumber\fP> is the +port on which the IM Server is listening for connections. +For example: +.DS +tcp/expo.lcs.mit.edu:8012 +tcp/18.30.0.212:7890 +.DE +.RE +.LP +\fBDECnet Names\fP +.LP +.RS +The following syntax should be used for DECnet names: +.DS +<\fIDECnet name\fP> ::= ``decnet/''<\fInodename\fP>``::IMSERVER$''<\fIobjname\fP> +.DE +where <\fInodename\fP> is either symbolic (such as SRVNOD) or the numeric +decimal form of the DECnet address (such as 44.70). The <\fIobjname\fP> +is normal, case-insensitive DECnet object name. For example: +.DS +DECNET/SRVNOD::IMSERVER$DEFAULT +decnet/44.70::IMSERVER$other +.DE +.RE +.LP +\fBX Names\fP +.LP +.RS +The following syntax should be used for X names: +.DS +<\fIX name\fP> ::= ``X/'' +.DE +.RE +.RE +.LP +If a given category has multiple values, the value is evaluated in order of +setting. +.bp +.XS +Appendix C \- Protocol number +.XE +.ce 10 +.sp 5 +\s+2\fBAppendix C\fP\s-2 +.sp +\s+1\fBProtocol number\fP\s-1 +.ce 0 +.sp +.LP +\fBMajor Protocol number\fP +.TS +center, tab(:); +lw(9c) l. +XIM_CONNECT:#001 +XIM_CONNECT_REPLY:#002 +XIM_DISCONNECT:#003 +XIM_DISCONNECT_REPLY:#004 + +XIM_AUTH_REQUIRED:#010 +XIM_AUTH_REPLY:#011 +XIM_AUTH_NEXT:#012 +XIM_AUTH_SETUP:#013 +XIM_AUTH_NG:#014 + +XIM_ERROR:#020 + +XIM_OPEN:#030 +XIM_OPEN_REPLY:#031 +XIM_CLOSE:#032 +XIM_CLOSE_REPLY:#033 +XIM_REGISTER_TRIGGERKEYS:#034 +XIM_TRIGGER_NOTIFY:#035 +XIM_TRIGGER_NOTIFY_REPLY:#036 +XIM_SET_EVENT_MASK:#037 +XIM_ENCODING_NEGOTIATION:#038 +XIM_ENCODING_NEGOTIATION_REPLY:#039 +XIM_QUERY_EXTENSION:#040 +XIM_QUERY_EXTENSION_REPLY:#041 +XIM_SET_IM_VALUES:#042 +XIM_SET_IM_VALUES_REPLY:#043 +XIM_GET_IM_VALUES:#044 +XIM_GET_IM_VALUES_REPLY:#045 + +XIM_CREATE_IC:#050 +XIM_CREATE_IC_REPLY:#051 +XIM_DESTROY_IC:#052 +XIM_DESTROY_IC_REPLY:#053 +XIM_SET_IC_VALUES:#054 +XIM_SET_IC_VALUES_REPLY:#055 +XIM_GET_IC_VALUES:#056 +XIM_GET_IC_VALUES_REPLY:#057 +XIM_SET_IC_FOCUS:#058 +XIM_UNSET_IC_FOCUS:#059 +XIM_FORWARD_EVENT:#060 +XIM_SYNC:#061 +XIM_SYNC_REPLY:#062 +XIM_COMMIT:#063 +XIM_RESET_IC:#064 +XIM_RESET_IC_REPLY:#065 + +XIM_GEOMETRY:#070 +XIM_STR_CONVERSION:#071 +XIM_STR_CONVERSION_REPLY:#072 +XIM_PREEDIT_START:#073 +XIM_PREEDIT_START_REPLY:#074 +XIM_PREEDIT_DRAW:#075 +XIM_PREEDIT_CARET:#076 +XIM_PREEDIT_CARET_REPLY:#077 +XIM_PREEDIT_DONE:#078 +XIM_STATUS_START:#079 +XIM_STATUS_DRAW:#080 +XIM_STATUS_DONE:#081 +XIM_PREEDITSTATE:#082 +.TE +.sp +(*) The IM Server's extension protocol number should be more than #128. +.bp +.XS +Appendix D \- Implementation Tips +.XE +.ce 10 +.sp 5 +\s+2\fBAppendix D\fP\s-2 +.sp +\s+1\fBImplementation Tips\fP\s-1 +.ce 0 +.sp +.LP +.B +.IP \fB(1) +FrontEnd Method\fP +.LP +FrontEnd method is recognized as a performance acceleration by the +trade off of the variety of the reliability. +.LP +In order to use the FrontEnd method, the IM library must query the IM +Server to see if the FrontEnd extension is available. The query is +made by using the +.PN XIM_QUERY_EXTENSION +message. The IM Server may send +.PN XIM_EXT_SET_EVENT_MASK +message with intercept-event-mask, forward-event-mask, and +synchronous-event-mask values set after replying +.PN XIM_QUERY_EXTENSION_REPLY +message. +.LP +FrontEnd method can be implemented in a couple of ways depending on +how the IM Server utilize +.PN XIM_EXT_SET_EVENT_MASK +message. +.LP +One approach is to update both of the input mask and the filter-event-mask +depending on the preeidting state. The sample protocol sequence using the +static event flow is as follows: +.LP +.\"=================================================================== +.sp +\^... 1.675 6.888 6.237 10.296 +\^... 0.000i 3.408i 4.562i 0.000i +.nr 00 \n(.u +.nf +.PS 3.408i 4.562i +.br +.ps 11 +\h'3.750i'\v'0.034i'\v'-.13m'\L'3.374i\(br'\v'.13m' +.sp -1 +\h'3.912i'\v'1.384i'\D'l-0.100i 0.025i' +.sp -1 +\h'3.912i'\v'1.434i'\D'l-0.100i -0.025i' +.sp -1 +\h'3.812i'\v'1.409i'\l'0.750i' +.sp -1 +\h'3.750i'\h'-0.0m'\v'0.2m'\s12\fRIM Server\fP +.sp -1 +\h'3.812i'\v'0.818i'\h'-0.0m'\v'0.2m'\s10\fRevent mask is changed\fP +.sp -1 +\h'3.812i'\v'1.006i'\h'-0.0m'\v'0.2m'\s10\fRto select the event\fP +.sp -1 +\h'3.875i'\v'2.381i'\h'-0.0m'\v'0.2m'\s10\fRevent mask is changed\fP +.sp -1 +\h'3.875i'\v'2.568i'\h'-0.0m'\v'0.2m'\s10\fRto deselect the event\fP +.sp -1 +\h'3.875i'\v'1.631i'\h'-0.0m'\v'0.2m'\s10\fRX events directly come\fP +.sp -1 +\h'3.875i'\v'1.756i'\h'-0.0m'\v'0.2m'\s10\fRto the IM Server.\fP +.sp -1 +\h'3.875i'\v'2.006i'\h'-0.0m'\v'0.2m'\s10\fRwhen preediting is turning off\fP +.sp -1 +\h'0.625i'\v'0.284i'\l'0.875i' +.sp -1 +\h'1.400i'\v'0.309i'\D'l0.100i -0.025i' +.sp -1 +\h'1.400i'\v'0.259i'\D'l0.100i 0.025i' +.sp -1 +\h'1.750i'\v'0.346i'\l'1.687i' +.sp -1 +\h'3.337i'\v'0.371i'\D'l0.100i -0.025i' +.sp -1 +\h'3.337i'\v'0.321i'\D'l0.100i 0.025i' +.sp -1 +\h'1.850i'\v'2.134i'\D'l-0.100i 0.025i' +.sp -1 +\h'1.850i'\v'2.184i'\D'l-0.100i -0.025i' +.sp -1 +\h'1.750i'\v'2.159i'\l'1.687i' +.sp -1 +\h'1.562i'\v'0.034i'\v'-.13m'\L'3.374i\(br'\v'.13m' +.sp -1 +\h'1.850i'\v'0.446i'\D'l-0.100i 0.025i' +.sp -1 +\h'1.850i'\v'0.496i'\D'l-0.100i -0.025i' +.sp -1 +\h'1.750i'\v'0.471i'\l'1.687i' +.sp -1 +\h'1.687i'\v'0.631i'\h'-0.0m'\v'0.2m'\s10\fRXIM_EXT_SET_EVENT_MASK\fP +.sp -1 +\h'1.875i'\v'0.818i'\h'-0.0m'\v'0.2m'\s10\fRintercept-event-mask is set\fP +.sp -1 +\h'1.687i'\v'2.318i'\h'-0.0m'\v'0.2m'\s10\fRXIM_EXT_SET_EVENT_MASK\fP +.sp -1 +\h'1.875i'\v'2.443i'\h'-0.0m'\v'0.2m'\s10\fRselect-event-mask is set\fP +.sp -1 +\h'0.937i'\h'-0.0m'\v'0.2m'\s12\fRIM library\fP +.sp -1 +\v'0.193i'\h'-0.0m'\v'0.2m'\s10\fRKeys in the on-key-list\fP +.sp -1 +\h'0.250i'\v'2.318i'\h'-0.0m'\v'0.2m'\s10\fRevent mask is changed\fP +.sp -1 +\h'0.250i'\v'2.506i'\h'-0.0m'\v'0.2m'\s10\fRto select the event\fP +.sp -1 +\h'0.250i'\v'1.006i'\h'-0.0m'\v'0.2m'\s10\fRto deselect the event\fP +.sp -1 +\h'0.250i'\v'0.818i'\h'-0.0m'\v'0.2m'\s10\fRevent mask is changed\fP +.sp -1 +\h'1.812i'\v'0.256i'\h'-0.0m'\v'0.2m'\s10\fRXIM_FORWARD_EVENT\fP +.sp -1 +.sp 1+3.408i +.PE +.if \n(00 .fi +.sp +.\"=================================================================== +.LP +To pursuit a maximum performance regardless of the preediting mode, +the IM Server may use the dynamic event flow with the following +sample protocol sequence. +.bp +.LP +.\"=================================================================== +\^... 1.675 6.888 6.237 10.296 +\^... 0.000i 3.408i 4.562i 0.000i +.nr 00 \n(.u +.nf +.PS 3.408i 4.562i +.br +.ps 11 +\h'3.750i'\v'0.034i'\v'-.13m'\L'3.374i\(br'\v'.13m' +.sp -1 +\h'3.912i'\v'1.384i'\D'l-0.100i 0.025i' +.sp -1 +\h'3.912i'\v'1.434i'\D'l-0.100i -0.025i' +.sp -1 +\h'3.812i'\v'1.409i'\l'0.750i' +.sp -1 +\h'3.750i'\h'-0.0m'\v'0.2m'\s12\fRIM Server\fP +.sp -1 +\h'3.812i'\v'0.818i'\h'-0.0m'\v'0.2m'\s10\fRevent mask is changed\fP +.sp -1 +\h'3.812i'\v'1.006i'\h'-0.0m'\v'0.2m'\s10\fRto select the event\fP +.sp -1 +\h'3.875i'\v'2.381i'\h'-0.0m'\v'0.2m'\s10\fRevent mask is changed\fP +.sp -1 +\h'3.875i'\v'2.568i'\h'-0.0m'\v'0.2m'\s10\fRto deselect the event\fP +.sp -1 +\h'3.875i'\v'1.631i'\h'-0.0m'\v'0.2m'\s10\fRX events directly come\fP +.sp -1 +\h'3.875i'\v'1.756i'\h'-0.0m'\v'0.2m'\s10\fRto the IM Server.\fP +.sp -1 +\h'3.875i'\v'2.006i'\h'-0.0m'\v'0.2m'\s10\fRwhen preediting is turning off\fP +.sp -1 +\h'0.625i'\v'0.284i'\l'0.875i' +.sp -1 +\h'1.400i'\v'0.309i'\D'l0.100i -0.025i' +.sp -1 +\h'1.400i'\v'0.259i'\D'l0.100i 0.025i' +.sp -1 +\h'1.750i'\v'0.346i'\l'1.687i' +.sp -1 +\h'3.337i'\v'0.371i'\D'l0.100i -0.025i' +.sp -1 +\h'3.337i'\v'0.321i'\D'l0.100i 0.025i' +.sp -1 +\h'1.850i'\v'1.196i'\D'l-0.100i 0.025i' +.sp -1 +\h'1.850i'\v'1.246i'\D'l-0.100i -0.025i' +.sp -1 +\h'1.750i'\v'1.221i'\l'1.687i' +.sp -1 +\h'1.850i'\v'2.134i'\D'l-0.100i 0.025i' +.sp -1 +\h'1.850i'\v'2.184i'\D'l-0.100i -0.025i' +.sp -1 +\h'1.750i'\v'2.159i'\l'1.687i' +.sp -1 +\h'1.562i'\v'0.034i'\v'-.13m'\L'3.374i\(br'\v'.13m' +.sp -1 +\h'1.850i'\v'0.446i'\D'l-0.100i 0.025i' +.sp -1 +\h'1.850i'\v'0.496i'\D'l-0.100i -0.025i' +.sp -1 +\h'1.750i'\v'0.471i'\l'1.687i' +.sp -1 +\h'1.812i'\v'0.256i'\h'-0.0m'\v'0.2m'\s10\fRXIM_TRIGGER_NOTIFY\fP +.sp -1 +\h'1.687i'\v'1.068i'\h'-0.0m'\v'0.2m'\s10\fRXIM_TRIGGER_NOTIFY_REPLY\fP +.sp -1 +\h'1.687i'\v'0.631i'\h'-0.0m'\v'0.2m'\s10\fRXIM_EXT_SET_EVENT_MASK\fP +.sp -1 +\h'1.875i'\v'0.818i'\h'-0.0m'\v'0.2m'\s10\fRintercept-event-mask is set\fP +.sp -1 +\h'1.687i'\v'2.318i'\h'-0.0m'\v'0.2m'\s10\fRXIM_EXT_SET_EVENT_MASK\fP +.sp -1 +\h'1.875i'\v'2.443i'\h'-0.0m'\v'0.2m'\s10\fRselect-event-mask is set\fP +.sp -1 +\h'0.937i'\h'-0.0m'\v'0.2m'\s12\fRIM library\fP +.sp -1 +\v'0.193i'\h'-0.0m'\v'0.2m'\s10\fRKeys in the on-key-list\fP +.sp -1 +\h'0.250i'\v'2.318i'\h'-0.0m'\v'0.2m'\s10\fRevent mask is changed\fP +.sp -1 +\h'0.250i'\v'2.506i'\h'-0.0m'\v'0.2m'\s10\fRto select the event\fP +.sp -1 +\h'0.250i'\v'1.006i'\h'-0.0m'\v'0.2m'\s10\fRto deselect the event\fP +.sp -1 +\h'0.250i'\v'0.818i'\h'-0.0m'\v'0.2m'\s10\fRevent mask is changed\fP +.sp -1 +.sp 1+3.408i +.PE +.if \n(00 .fi +.\"=================================================================== +.LP +This method can reduce the XIM protocol traffic dramatically +by updating intercept-event-mask and select-event-mask accordingly. +The tradeoff of this performance improvement is that the key +events may be lost or disordered in some particular situation, such as +when the user types the keyboard in following sequence really fast: +.sp 6p +.RS +``some strings''``another string'' +.RE +.sp 6p +Since this method requires the input mask updates to the both the IM Server +and Xlib when turning on and off the preediting, and there is a time lag +till the requests take effect when two client issues the input mask updates +simultaneously. +.LP +Another approach of the FrontEnd method is to update the filter-event-mask +depending on the preediting state and not to update the input mask. +The IM Server must register both of the preediting on key list and off key +list by +.PN XIM_REGISTER_TRIGGERKEYS +message. +In this method, Both the IM Server and the IM client select the same +events on the same client's window, so that the events are delivered +to both of the IM Server and the client. The preediting on and off +states are expressed by whether the key events are filtered or not. +The sample protocol sequence are as follows: +.LP +.bp +<> +.LP +.\"==================================================================== +.sp +\^... 1.488 7.325 6.487 10.358 +\^... 0.000i 3.033i 4.999i 0.000i +.nr 00 \n(.u +.nf +.PS 3.033i 4.999i +.br +.ps 11 +\h'4.099i'\v'0.383i'\D'l-0.100i 0.025i' +.sp -1 +\h'4.099i'\v'0.433i'\D'l-0.100i -0.025i' +.sp -1 +\h'3.999i'\v'0.408i'\l'1.000i' +.sp -1 +\h'4.099i'\v'1.696i'\D'l-0.100i 0.025i' +.sp -1 +\h'4.099i'\v'1.746i'\D'l-0.100i -0.025i' +.sp -1 +\h'3.999i'\v'1.721i'\l'1.000i' +.sp -1 +\h'3.937i'\v'0.096i'\v'-.13m'\L'2.937i\(br'\v'.13m' +.sp -1 +\h'3.937i'\v'0.062i'\h'-0.0m'\v'0.2m'\s12\fRIM Server\fP +.sp -1 +\h'4.062i'\v'0.755i'\h'-0.0m'\v'0.2m'\s10\fRthe specified events\fP +.sp -1 +\h'4.062i'\v'0.943i'\h'-0.0m'\v'0.2m'\s10\fRare being processed\fP +.sp -1 +\h'4.062i'\v'2.255i'\h'-0.0m'\v'0.2m'\s10\fRthe specified events\fP +.sp -1 +\h'4.062i'\v'2.443i'\h'-0.0m'\v'0.2m'\s10\fRare being discarded\fP +.sp -1 +\h'4.249i'\v'1.568i'\h'-0.0m'\v'0.2m'\s10\fRKeys in the off-key-list\fP +.sp -1 +\h'4.187i'\v'0.318i'\h'-0.0m'\v'0.2m'\s10\fRKeys in the on-key-list\fP +.sp -1 +\h'0.812i'\v'0.346i'\l'0.875i' +.sp -1 +\h'1.587i'\v'0.371i'\D'l0.100i -0.025i' +.sp -1 +\h'1.587i'\v'0.321i'\D'l0.100i 0.025i' +.sp -1 +\h'1.937i'\v'0.408i'\l'1.687i' +.sp -1 +\h'3.524i'\v'0.433i'\D'l0.100i -0.025i' +.sp -1 +\h'3.524i'\v'0.383i'\D'l0.100i 0.025i' +.sp -1 +\h'1.749i'\v'0.096i'\v'-.13m'\L'2.937i\(br'\v'.13m' +.sp -1 +\h'2.037i'\v'0.508i'\D'l-0.100i 0.025i' +.sp -1 +\h'2.037i'\v'0.558i'\D'l-0.100i -0.025i' +.sp -1 +\h'1.937i'\v'0.533i'\l'1.687i' +.sp -1 +\h'0.812i'\v'1.721i'\l'0.875i' +.sp -1 +\h'1.587i'\v'1.746i'\D'l0.100i -0.025i' +.sp -1 +\h'1.587i'\v'1.696i'\D'l0.100i 0.025i' +.sp -1 +\h'2.099i'\v'1.758i'\D'l-0.100i 0.025i' +.sp -1 +\h'2.099i'\v'1.808i'\D'l-0.100i -0.025i' +.sp -1 +\h'1.999i'\v'1.783i'\l'1.688i' +.sp -1 +\h'1.874i'\v'0.693i'\h'-0.0m'\v'0.2m'\s10\fRXIM_EXT_SET_EVENT_MASK\fP +.sp -1 +\v'0.255i'\h'-0.0m'\v'0.2m'\s10\fRKeys in the on-key-list\fP +.sp -1 +\h'2.062i'\v'0.880i'\h'-0.0m'\v'0.2m'\s10\fRfilter-event-mask is set\fP +.sp -1 +\h'0.624i'\v'0.755i'\h'-0.0m'\v'0.2m'\s10\fRthe specified events\fP +.sp -1 +\h'0.624i'\v'0.943i'\h'-0.0m'\v'0.2m'\s10\fRare being filtered\fP +.sp -1 +\h'1.937i'\v'1.943i'\h'-0.0m'\v'0.2m'\s10\fRXIM_EXT_SET_EVENT_MASK\fP +.sp -1 +\h'2.124i'\v'2.068i'\h'-0.0m'\v'0.2m'\s10\fRfilter-event-mask is set\fP +.sp -1 +\h'0.062i'\v'1.568i'\h'-0.0m'\v'0.2m'\s10\fRKeys in the off-key-list\fP +.sp -1 +\h'1.062i'\h'-0.0m'\v'0.2m'\s12\fRIM library\fP +.sp -1 +\h'0.624i'\v'2.255i'\h'-0.0m'\v'0.2m'\s10\fRthe specified events\fP +.sp -1 +\h'0.624i'\v'2.443i'\h'-0.0m'\v'0.2m'\s10\fRare being processed\fP +.sp -1 +\h'1.999i'\v'0.318i'\h'-0.0m'\v'0.2m'\s10\fRXIM_FORWARD_EVENT\fP +.sp -1 +.sp 1+3.033i +.PE +.if \n(00 .fi +.\"==================================================================== +.LP +<> +.LP +.\"==================================================================== +\^... 1.488 7.325 6.487 10.358 +\^... 0.000i 3.033i 4.999i 0.000i +.nr 00 \n(.u +.nf +.PS 3.033i 4.999i +.br +.ps 11 +\h'4.099i'\v'0.383i'\D'l-0.100i 0.025i' +.sp -1 +\h'4.099i'\v'0.433i'\D'l-0.100i -0.025i' +.sp -1 +\h'3.999i'\v'0.408i'\l'1.000i' +.sp -1 +\h'4.099i'\v'1.696i'\D'l-0.100i 0.025i' +.sp -1 +\h'4.099i'\v'1.746i'\D'l-0.100i -0.025i' +.sp -1 +\h'3.999i'\v'1.721i'\l'1.000i' +.sp -1 +\h'3.937i'\v'0.096i'\v'-.13m'\L'2.937i\(br'\v'.13m' +.sp -1 +\h'3.937i'\v'0.062i'\h'-0.0m'\v'0.2m'\s12\fRIM Server\fP +.sp -1 +\h'4.062i'\v'0.755i'\h'-0.0m'\v'0.2m'\s10\fRthe specified events\fP +.sp -1 +\h'4.062i'\v'0.943i'\h'-0.0m'\v'0.2m'\s10\fRare being processed\fP +.sp -1 +\h'4.062i'\v'2.255i'\h'-0.0m'\v'0.2m'\s10\fRthe specified events\fP +.sp -1 +\h'4.062i'\v'2.443i'\h'-0.0m'\v'0.2m'\s10\fRare being discarded\fP +.sp -1 +\h'4.249i'\v'1.568i'\h'-0.0m'\v'0.2m'\s10\fRKeys in the off-key-list\fP +.sp -1 +\h'4.187i'\v'0.318i'\h'-0.0m'\v'0.2m'\s10\fRKeys in the on-key-list\fP +.sp -1 +\h'0.812i'\v'0.346i'\l'0.875i' +.sp -1 +\h'1.587i'\v'0.371i'\D'l0.100i -0.025i' +.sp -1 +\h'1.587i'\v'0.321i'\D'l0.100i 0.025i' +.sp -1 +\h'1.937i'\v'0.408i'\l'1.687i' +.sp -1 +\h'3.524i'\v'0.433i'\D'l0.100i -0.025i' +.sp -1 +\h'3.524i'\v'0.383i'\D'l0.100i 0.025i' +.sp -1 +\h'2.037i'\v'1.258i'\D'l-0.100i 0.025i' +.sp -1 +\h'2.037i'\v'1.308i'\D'l-0.100i -0.025i' +.sp -1 +\h'1.937i'\v'1.283i'\l'1.687i' +.sp -1 +\h'1.749i'\v'0.096i'\v'-.13m'\L'2.937i\(br'\v'.13m' +.sp -1 +\h'2.037i'\v'0.508i'\D'l-0.100i 0.025i' +.sp -1 +\h'2.037i'\v'0.558i'\D'l-0.100i -0.025i' +.sp -1 +\h'1.937i'\v'0.533i'\l'1.687i' +.sp -1 +\h'0.812i'\v'1.721i'\l'0.875i' +.sp -1 +\h'1.587i'\v'1.746i'\D'l0.100i -0.025i' +.sp -1 +\h'1.587i'\v'1.696i'\D'l0.100i 0.025i' +.sp -1 +\h'2.099i'\v'1.758i'\D'l-0.100i 0.025i' +.sp -1 +\h'2.099i'\v'1.808i'\D'l-0.100i -0.025i' +.sp -1 +\h'1.999i'\v'1.783i'\l'1.688i' +.sp -1 +\h'1.999i'\v'0.318i'\h'-0.0m'\v'0.2m'\s10\fRXIM_TRIGGER_NOTIFY\fP +.sp -1 +\h'1.874i'\v'1.130i'\h'-0.0m'\v'0.2m'\s10\fRXIM_TRIGGER_NOTIFY_REPLY\fP +.sp -1 +\h'1.874i'\v'0.693i'\h'-0.0m'\v'0.2m'\s10\fRXIM_EXT_SET_EVENT_MASK\fP +.sp -1 +\v'0.255i'\h'-0.0m'\v'0.2m'\s10\fRKeys in the on-key-list\fP +.sp -1 +\h'2.062i'\v'0.880i'\h'-0.0m'\v'0.2m'\s10\fRfilter-event-mask is set\fP +.sp -1 +\h'0.624i'\v'0.755i'\h'-0.0m'\v'0.2m'\s10\fRthe specified events\fP +.sp -1 +\h'0.624i'\v'0.943i'\h'-0.0m'\v'0.2m'\s10\fRare being filtered\fP +.sp -1 +\h'1.937i'\v'1.943i'\h'-0.0m'\v'0.2m'\s10\fRXIM_EXT_SET_EVENT_MASK\fP +.sp -1 +\h'2.124i'\v'2.068i'\h'-0.0m'\v'0.2m'\s10\fRfilter-event-mask is set\fP +.sp -1 +\h'0.062i'\v'1.568i'\h'-0.0m'\v'0.2m'\s10\fRKeys in the off-key-list\fP +.sp -1 +\h'1.062i'\h'-0.0m'\v'0.2m'\s12\fRIM library\fP +.sp -1 +\h'0.624i'\v'2.255i'\h'-0.0m'\v'0.2m'\s10\fRthe specified events\fP +.sp -1 +\h'0.624i'\v'2.443i'\h'-0.0m'\v'0.2m'\s10\fRare being processed\fP +.sp -1 +.sp 1+3.033i +.PE +.if \n(00 .fi + +.\"==================================================================== +.LP +This method does not have the problem of the time lag when going across +the preediting on and off mode, however, the amount of the performance +acceleration is not as good as the method described above. +.LP +In general, the FrontEnd method requires some synchronization to some +of the X protocols, such as the ChangeWindowAttribute protocol for the +event mask change or the GrabKey protocol, since it relies on the X's +principal event dispatching mechanism. Any X protocol bindings do not +consider the synchronization might cause some mis-synchronization +between the IM clients and the IM Server. +.LP +.bp +.IP \fB(2) +Transport Layer\fP +.LP +The Xlib XIM implementation is layered into three functions, a protocol +layer, an interface layer and a transport layer. The purpose of this +layering is to make the protocol independent of transport implementation. +Each function of these layers are: +.RS 3 +.IP "\fIThe protocol layer\fP" +.br +implements overall function of XIM and calls the interface layer +functions when it needs to communicate to IM Server. +.IP "\fIThe interface layer\fP" +.br +separates the implementation of the transport layer from the protocol +layer, in other words, it provides implementation independent hook for +the transport layer functions. +.IP "\fIThe transport layer\fP" +.br +handles actual data communication with IM Server. It is done by a set +of several functions named transporters. +.RE +.LP +The interface layer and the transport layer make various communication +channels usable such as X Protocol, TCP/IP, DECnet or STREAM. +The following is a sample implementation for the transporter using +the X connection. +Refer to "xtrans" for the transporter using Socket Transport. +.LP +At the beginning of the X Transport connection for the XIM transport +mechanism, two different windows must be created either in an Xlib XIM +or in an IM Server, with which the Xlib and the IM Server exchange the +XIM transports by using the ClientMessage events and Window Properties. +In the following, the window created by the Xlib is referred as the +"client communication window", and on the other hand, the window created +by the IM Server is referred as the "IMS communication window". +.LP +.B +Connection +.LP +.RS +In order to establish a connection, a communication window is created. +A ClientMessage in the following event's format is sent to the owner +window of XIM_SERVER selection, which the IM Server has created. +.LP +Refer to "The Input Method Protocol" for the XIM_SERVER atom. +.LP +.ce +Table D-1; The ClientMessage sent to the IMS window. +.TS H +tab(:); +l s|l +l l|l. +_ +.sp 6p +.B +Structure Member:Contents +.sp 6p +_ +.sp 6p +.TH +.R +int:type:ClientMessage +u_long:serial:Set by the X Window System +Bool:send_event:Set by the X Window System +Display:*display:The display to which connects +Window:window:IMS Window ID +Atom:message_type:XInternAtom(display, ``_XIM_XCONNECT'', False) +int:format:32 +long:data.l[0]:client communication window ID +long:data.l[1]:client-major-transport-version (*1) +long:data.l[2]:client-major-transport-version (*1) +.sp 6p +_ +.TE +.LP +In order to establish the connection (to notify the IM Server communication +window), the IM Server sends a ClientMessage in the following event's +format to the client communication window. +.LP +.bp +.ce +Table D-2; The ClientMessage sent by IM Server. +.TS H +tab(:); +l s | l +l l | l. +_ +.sp 6p +.B +Structure Member:Contents +.sp 6p +_ +.sp 6p +.TH +.R +int:type:ClientMessage +u_long:serial:Set by the X Window System +Bool:send_event:Set by the X Window System +Display:*display:The display to which connects +Window:window:client communication window ID +Atom:message_type:XInternAtom(display, ``_XIM_XCONNECT'', False) +int:format:32 +long:data.l[0]:IMS communication window ID +long:data.l[1]:server-major-transport-version (*1) +long:data.l[2]:server-minor-transport-version (*1) +long:data.l[3]:dividing size between ClientMessage and Property (*2) +.sp 6p +_ +.TE +.LP +.IP (*1) +major/minor-transport-version +.RS +The read/write method is decided by the combination of +major/minor-transport-version, as follows: +.LP +.ce +Table D-3; The read/write method and the major/minor-transport-version +.TS +center, tab(:); +| c s | l | +| c | c | l |. +_ +.sp 6p +.B +Transport-version:read/write +.sp 6p +_ +.sp 6p +major:minor: +.sp 6p +_ +.sp 6p +.R +0:0:only-CM & Property-with-CM +:1:only-CM & multi-CM +:2:only-CM & multi-CM & Property-with-CM +.sp 6p +_ +.sp 6p +1:0:PropertyNotify +.sp 6p +_ +.sp 6p +2:0:only-CM & PropertyNotify +:1:only-CM & multi-CM & PropertyNotify +.sp 6p +_ +.TE +.LP +.RS +.TS +center, tab(;); +l n l. +only-CM;:;data is sent via a ClientMessage +multi-CM;:;data is sent via multiple ClientMessages +Property-with-CM;:;T{ +data is written in Property, and its Atom is send via ClientMessage +T} +PropertyNotify;:;T{ +data is written in Property, and its Atom is send via PropertyNotify +T} +.TE +.RE +.LP +The method to decide major/minor-transport-version is as follows: +.LP +.IP (1) +The client sends 0 as major/minor-transport-version to the IM Server. +The client must support all methods in Table D-3. +The client may send another number as major/minor-transport-version to +use other method than the above in the future. +.IP (2) +The IM Server sends its major/minor-transport-version number to +the client. The client sends data using the method specified by the +IM Server. +.IP (3) +If major/minor-transport-version number is not available, it is regarded +as 0. +.RE +.LP +.IP (*2) +dividing size between ClientMessage and Property +.RS +If data is sent via both of multi-CM and Property, specify the dividing +size between ClientMessage and Property. The data, which is smaller than +this size, is sent via multi-CM (or only-CM), and the data, which is +lager than this size, is sent via Property. +.RE +.RE +.LP +.sp +.LP +.B +read/write +.LP +.RS +The data is transferred via either ClientMessage or Window Property in +the X Window System. +.LP +.B +Format for the data from the Client to the IM Server +.LP +.RS +.B +ClientMessage +.LP +If data is sent via ClientMessage event, the format is as follows: +.LP +.ce +Table D-4; The ClientMessage event's format (first or middle) +.TS +tab(;); +l s | l +l l | l. +_ +.sp 6p +.B +Structure Member;Contents +.sp 6p +_ +.sp 6p +.R +int;type;ClientMessage +u_long;serial;Set by the X Window System +Bool;send_event;Set by the X Window System +Display;*display;The display to which connects +Window;window;IMS communication window ID +Atom;message_type;XInternAtom(display, ``_XIM_MOREDATA'', False) +int;format;8 +char;data.b[20];(read/write DATA : 20 byte) +.sp 6p +_ +.TE +.LP +.ce +Table D-5; The ClientMessage event's format (only or last) +.TS H +tab(;); +l s | l +l l | l. +_ +.sp 6p +.B +Structure Member;Contents +.sp 6p +_ +.sp 6p +.TH +.R +int;type;ClientMessage +u_long;serial;Set by the X Window System +Bool;send_event;Set by the X Window System +Display;*display;The display to which connects +Window;window;IMS communication window ID +Atom;message_type;XInternAtom(display, ``_XIM_PROTOCOL'', False) +int;format;8 +char;data.b[20];(read/write DATA : MAX 20 byte) (*1) +.sp 6p +_ +.TE +.IP (*1) +If the data is smaller than 20 byte, all data other than available data +must be 0. +.RE +.LP +.RS +.B +Property +.LP +In the case of large data, data will be sent via the Window Property +for the efficiency. There are the following two methods to notify +Property, and transport-version is decided which method is used. +.LP +.IP (1) +The XChangeProperty function is used to store data in the client +communication window, and Atom of the stored data is notified to the +IM Server via ClientMessage event. +.IP (2) +The XChangeProperty function is used to store data in the client +communication window, and Atom of the stored data is notified to the +IM Server via PropertyNotify event. +.LP +The arguments of the XChangeProperty are as follows: +.LP +.bp +.ce +Table D-6; The XChangeProperty event's format +.TS H +tab(:); +l s | l +l l | l. +_ +.sp 6p +.B +Argument:Contents +.sp 6p +_ +.sp 6p +.TH +.R +Display:*display:The display to which connects +Window:window:IMS communication window ID +Atom:property:read/write property Atom (*1) +Atom:type:XA_STRING +int:format:8 +int:mode:PropModeAppend +u_char:*data:read/write DATA +int:nelements:length of DATA +.sp 6p +_ +.TE +.LP +.IP (*1) +The read/write property ATOM allocates the following strings by +\fBXInternAtom\fP. +.RS +``_clientXXX'' +.RE +.LP +The client changes the property with the mode of PropModeAppend and +the IM Server will read it with the delete mode i.e. (delete = True). +.LP +If Atom is notified via ClientMessage event, the format of the ClientMessage +is as follows: +.LP +.ce +Table D-7; The ClientMessage event's format to send Atom of property +.TS H +tab(:); +l s | l +l l | l. +_ +.sp 6p +.B +Structure Member:Contents +.sp 6p +_ +.sp 6p +.TH +.R +int:type:ClientMessage +u_long:serial:Set by the X Window System +Bool:send_event:Set by the X Window System +Display:*display:The display to which connects +Window:window:IMS communication window ID +Atom:message_type:XInternAtom(display, ``_XIM_PROTOCOL'', False) +int:format:32 +long:data.l[0]:length of read/write property Atom +long:data.l[1]:read/write property Atom +.sp 6p +_ +.TE +.RE +.LP +.B +Format for the data from the IM Server to the Client +.LP +.RS +.B +ClientMessage +.LP +The format of the ClientMessage is as follows: +.LP +.ce +Table D-8; The ClientMessage event's format (first or middle) +.TS H +tab(;); +l s | l +l l | l. +_ +.sp 6p +.B +Structure Member;Contents +.sp 6p +_ +.sp 6p +.TH +.R +int;type;ClientMessage +u_long;serial;Set by the X Window System +Bool;send_event ;Set by the X Window System +Display;*display;The display to which connects +Window;window;client communication window ID +Atom;message_type;XInternAtom(display, ``_XIM_MOREDATA'', False) +int;format;8 +char;data.b[20];(read/write DATA : 20 byte) +.sp 6p +_ +.TE +.LP +.bp +.ce +Table D-9; The ClientMessage event's format (only or last) +.TS +tab(;); +l s | l +l l | l. +_ +.sp 6p +.B +Structure Member;Contents +.sp 6p +_ +.sp 6p +.R +int;type;ClientMessage +u_long;serial;Set by the X Window System +Bool;send_event ;Set by the X Window System +Display;*display;The display to which connects +Window;window;client communication window ID +Atom;message_type;XInternAtom(display, ``_XIM_PROTOCOL'', False) +int;format;8 +char;data.b[20];(read/write DATA : MAX 20 byte) (*1) +.sp 6p +_ +.TE +.LP +.IP (*1) +If the data size is smaller than 20 bytes, all data other than available +data must be 0. +.LP +.B +Property +.LP +In the case of large data, data will be sent via the Window Property +for the efficiency. There are the following two methods to notify +Property, and transport-version is decided which method is used. +.LP +.IP (1) +The XChangeProperty function is used to store data in the IMS +communication window, and Atom of the property is sent via the +ClientMessage event. +.IP (2) +The XChangeProperty function is used to store data in the IMS +communication window, and Atom of the property is sent via +PropertyNotify event. +.LP +The arguments of the XChangeProperty are as follows: +.LP +.ce +Table D-10; The XChangeProperty event's format +.TS H +tab(:); +l s | l +l l | l. +_ +.sp 6p +.B +Argument:Contents +.sp 6p +_ +.sp 6p +.TH +.R +Display:*display:The display which to connects +Window:window:client communication window ID +Atom:property:read/write property Atom (*1) +Atom:type:XA_STRING +int:format:8 +int:mode:PropModeAppend +u_char:*data:read/write DATA +int:nelements:length of DATA +.sp 6p +_ +.TE +.LP +.IP (*1) +The read/write property ATOM allocates some strings, which are not +allocated by the client, by \fBXInternAtom\fP. +.LP +The IM Server changes the property with the mode of PropModeAppend and +the client reads it with the delete mode, i.e. (delete = True). +.LP +If Atom is notified via ClientMessage event, the format of the ClientMessage +is as follows: +.LP +.bp +.ce +Table D-11; The ClientMessage event's format to send Atom of property +.TS H +tab(:); +l s | l +l l | l. +_ +.sp 6p +.B +Structure Member:Contents +.sp 6p +_ +.sp 6p +.TH +.R +int:type:ClientMessage +u_long:serial:Set by the X Window System +Bool:send_event:Set by the X Window System +Display:*display:The display to which connects +Window:window:client communication window ID +Atom:message_type:XInternAtom(display, ``_XIM_PROTOCOL'', False) +int:format:32 +long:data.l[0]:length of read/write property ATOM +long:data.l[1]:read/write property ATOM +.sp 6p +_ +.TE +.RE +.RE +.LP +.B +Closing Connection +.RS +.LP +If the client disconnect with the IM Server, shutdown function should +free the communication window properties and etc.. +.RE +.LP +.bp +.EH '''' +.OH '''' +.EF '''' +.OF '''' +.TC + diff --git a/libX11/specs/i18n/Framework.ms b/libX11/specs/i18n/Framework.ms new file mode 100644 index 000000000..20ff3c7b3 --- /dev/null +++ b/libX11/specs/i18n/Framework.ms @@ -0,0 +1,1567 @@ +.\" $Xorg: Framework.ms,v 1.3 2000/08/17 19:42:49 cpqbld Exp $ +.\" $XdotOrg: xc/doc/specs/i18n/Framework.ms,v 1.2 2004/04/23 18:42:19 eich Exp $ +.\" To print this out, type tbl macros.t ThisFile | troff -ms +.\" $XFree86: xc/doc/specs/i18n/Framework.ms,v 1.4 2001/01/17 16:57:45 dawes Exp $ +.EH '''' +.OH '''' +.EF '''' +.OF '''' +.ps 11 +.nr PS 11 +\& +.TL +\s+3\fBX11R6 Sample Implementation Frame Work\fP\s-3 +.sp 2 +.AU +Katsuhisa Yano +.AI +TOSHIBA Corporation +.AU +Yoshio Horiuchi +.AI +IBM Japan +.LP +.bp +.br +\& +.sp 15 +.ps 9 +.nr PS 9 +.LP +Copyright \(co 1994 by TOSHIBA Corporation +.br +Copyright \(co 1994 by IBM Corporation +.LP +Permission to use, copy, modify, and distribute this documentation +for any purpose and without fee is hereby granted, provided +that the above copyright notice and this permission notice appear +in all copies. +TOSHIBA Corporation and IBM Corporation make no representations about +the suitability for any purpose of the information in this document. +This documentation is provided as is without express or implied warranty. +.sp 5 +Copyright \(co 1994 X Consortium +.LP +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: +.LP +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. +.LP +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 +X CONSORTIUM 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. +.LP +Except as contained in this notice, the name of the X Consortium 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 X Consortium. +.sp 3 +\fIX Window System\fP is a trademark of The Open Group. +.ps 11 +.nr PS 11 +.bp 1 +.EH '\fBSample Implementation Frame Work\fP''\fB\*(xV\fP' +.OH '\fBSample Implementation Frame Work\fP''\fB\*(xV\fP' +.EF ''\fB % \fP'' +.OF ''\fB % \fP'' +.NH 1 +Preface +.XS \*(SN Preface +.XE +.LP +This document proposes to define the structures, methods and their +signatures that are expected to be common to all locale dependent +functions within the Xlib sample implementation. The following +illustration (Fig.1) is proposed to outline the separating of +the components within the sample implementation. +.LP +.\" figure start +.in +1c +\^... 0.237 5.796 5.24 10.14 +\^... 0.000i 4.344i 5.003i 0.000i +.nr 00 \n(.u +.nf +.PS 4.344i 5.003i +.br +.ps 11 +\h'1.753i'\v'2.130i'\v'-.13m'\L'-1.000i\(br'\v'.13m' +.sp -1 +\h'1.753i'\v'1.130i'\l'1.500i' +.sp -1 +\h'3.253i'\v'1.130i'\v'-.13m'\L'1.000i\(br'\v'.13m' +.sp -1 +\h'3.253i'\v'2.130i'\l'-1.500i' +.sp -1 +\h'1.751i'\v'1.628i'\l'1.499i' +.sp -1 +\h'2.500i'\v'1.128i'\v'-.13m'\L'0.500i\(br'\v'.13m' +.sp -1 +\h'1.875i'\v'1.344i'\h'-0.0m'\v'0.2m'\s12\fRInput\fP +.sp -1 +\h'1.875i'\v'1.532i'\h'-0.0m'\v'0.2m'\s12\fRMethod\fP +.sp -1 +\h'2.625i'\v'1.344i'\h'-0.0m'\v'0.2m'\s12\fROutput\fP +.sp -1 +\h'2.625i'\v'1.532i'\h'-0.0m'\v'0.2m'\s12\fRMethod\fP +.sp -1 +\h'1.938i'\v'1.844i'\h'-0.0m'\v'0.2m'\s12\fR\fP +.sp -1 +\h'2.000i'\v'2.032i'\h'-0.0m'\v'0.2m'\s12\fRX Locale Object\fP +.sp -1 +\h'3.503i'\v'1.630i'\v'-.13m'\L'-0.500i\(br'\v'.13m' +.sp -1 +\h'3.503i'\v'1.130i'\l'1.500i' +.sp -1 +\h'5.003i'\v'1.130i'\v'-.13m'\L'0.500i\(br'\v'.13m' +.sp -1 +\h'5.003i'\v'1.630i'\l'-1.500i' +.sp -1 +\h'3.625i'\v'1.344i'\h'-0.0m'\v'0.2m'\s12\fRC Library\fP +.sp -1 +\h'4.250i'\v'1.532i'\h'-0.0m'\v'0.2m'\s12\fRANSI impl.\fP +.sp -1 +\h'0.003i'\v'1.630i'\v'-.13m'\L'-0.500i\(br'\v'.13m' +.sp -1 +\h'0.003i'\v'1.130i'\l'1.500i' +.sp -1 +\h'1.503i'\v'1.130i'\v'-.13m'\L'0.500i\(br'\v'.13m' +.sp -1 +\h'1.503i'\v'1.630i'\l'-1.500i' +.sp -1 +\h'0.125i'\v'1.344i'\h'-0.0m'\v'0.2m'\s12\fRLocale Library\fP +.sp -1 +\h'0.438i'\v'1.507i'\h'-0.0m'\v'0.2m'\s12\fRnon-AnSI impl.\fP +.sp -1 +\h'3.500i'\v'0.782i'\h'-0.0m'\v'0.2m'\s12\fR<< ANSI/MSE API >>\fP +.sp -1 +\h'4.250i'\v'0.969i'\h'-0.0m'\v'0.2m'\h'-\w'\s12\fR(X Contrib)\fP'u/2u'\s12\fR(X Contrib)\fP\h'-\w'\s12\fR(X Contrib)\fP'u/2u' +.sp -1 +\h'0.125i'\v'3.094i'\h'-0.0m'\v'0.2m'\s12\fRXLC_XLOCALE\fP +.sp -1 +\h'0.125i'\v'3.282i'\h'-0.0m'\v'0.2m'\s12\fR- MB_CUR_MAX\fP +.sp -1 +\h'0.125i'\v'3.444i'\h'-0.0m'\v'0.2m'\s12\fR- codeset info\fP +.sp -1 +\h'0.125i'\v'3.607i'\h'-0.0m'\v'0.2m'\s12\fRo char/charset\fP +.sp -1 +\h'0.125i'\v'3.769i'\h'-0.0m'\v'0.2m'\s12\fRo conv/charset\fP +.sp -1 +\h'0.003i'\v'3.880i'\v'-.13m'\L'-1.000i\(br'\v'.13m' +.sp -1 +\h'0.003i'\v'2.880i'\l'1.500i' +.sp -1 +\h'1.503i'\v'2.880i'\v'-.13m'\L'1.000i\(br'\v'.13m' +.sp -1 +\h'1.503i'\v'3.880i'\l'-1.500i' +.sp -1 +\h'1.875i'\v'3.094i'\h'-0.0m'\v'0.2m'\s12\fRXLC_FONTSET\fP +.sp -1 +\h'1.875i'\v'3.282i'\h'-0.0m'\v'0.2m'\s12\fR- fonset info\fP +.sp -1 +\h'1.875i'\v'3.444i'\h'-0.0m'\v'0.2m'\s12\fR- charset info\fP +.sp -1 +\h'1.875i'\v'3.607i'\h'-0.0m'\v'0.2m'\s12\fR- font/charset\fP +.sp -1 +\h'1.875i'\v'3.769i'\h'-0.0m'\v'0.2m'\s12\fR- XLFD, GL/GR\fP +.sp -1 +\h'1.753i'\v'3.880i'\v'-.13m'\L'-1.000i\(br'\v'.13m' +.sp -1 +\h'1.753i'\v'2.880i'\l'1.500i' +.sp -1 +\h'3.253i'\v'2.880i'\v'-.13m'\L'1.000i\(br'\v'.13m' +.sp -1 +\h'3.253i'\v'3.880i'\l'-1.500i' +.sp -1 +\h'3.625i'\v'3.444i'\h'-0.0m'\v'0.2m'\s12\fR- codeset info\fP +.sp -1 +\h'3.625i'\v'3.607i'\h'-0.0m'\v'0.2m'\s12\fRo char/charset\fP +.sp -1 +\h'3.625i'\v'3.769i'\h'-0.0m'\v'0.2m'\s12\fRo conv/charset\fP +.sp -1 +\h'3.625i'\v'3.282i'\h'-0.0m'\v'0.2m'\s12\fR- MB_CUR_MAX\fP +.sp -1 +\h'3.625i'\v'3.094i'\h'-0.0m'\v'0.2m'\s12\fRlocaledef DB\fP +.sp -1 +\h'3.503i'\v'3.880i'\v'-.13m'\L'-1.000i\(br'\v'.13m' +.sp -1 +\h'3.503i'\v'2.880i'\l'1.500i' +.sp -1 +\h'5.003i'\v'2.880i'\v'-.13m'\L'1.000i\(br'\v'.13m' +.sp -1 +\h'5.003i'\v'3.880i'\l'-1.500i' +.sp -1 +\h'0.753i'\v'0.250i'\D'l0.000i -0.250i' +.sp -1 +\h'0.753i'\l'3.500i' +.sp -1 +\h'4.253i'\D'l0.000i 0.250i' +.sp -1 +\h'4.253i'\v'0.250i'\l'-3.500i' +.sp -1 +\h'2.500i'\v'0.157i'\h'-0.0m'\v'0.2m'\h'-\w'\s12\fRApplication\fP'u/2u'\s12\fRApplication\fP\h'-\w'\s12\fRApplication\fP'u/2u' +.sp -1 +\v'0.782i'\h'-0.0m'\v'0.2m'\s12\fR<< ANSI/MSE API >>\fP +.sp -1 +\h'0.751i'\v'0.969i'\h'-0.0m'\v'0.2m'\h'-\w'\s12\fR(X Contrib)\fP'u/2u'\s12\fR(X Contrib)\fP\h'-\w'\s12\fR(X Contrib)\fP'u/2u' +.sp -1 +\h'2.500i'\v'2.128i'\v'-.13m'\L'0.749i\(br'\v'.13m' +.sp -1 +\h'2.475i'\v'2.777i'\D'l0.025i 0.100i' +.sp -1 +\h'2.525i'\v'2.777i'\D'l-0.025i 0.100i' +.sp -1 +\h'2.500i'\v'2.315i'\D'l-0.250i 0.187i' +.sp -1 +\h'2.250i'\v'2.502i'\l'-1.124i' +.sp -1 +\h'1.126i'\v'2.502i'\v'-.13m'\L'0.375i\(br'\v'.13m' +.sp -1 +\h'1.101i'\v'2.777i'\D'l0.025i 0.100i' +.sp -1 +\h'1.151i'\v'2.777i'\D'l-0.025i 0.100i' +.sp -1 +\h'2.500i'\v'2.315i'\D'l0.250i 0.187i' +.sp -1 +\h'2.750i'\v'2.502i'\l'1.125i' +.sp -1 +\h'3.875i'\v'2.502i'\v'-.13m'\L'0.375i\(br'\v'.13m' +.sp -1 +\h'3.850i'\v'2.777i'\D'l0.025i 0.100i' +.sp -1 +\h'3.900i'\v'2.777i'\D'l-0.025i 0.100i' +.sp -1 +\h'0.376i'\v'1.628i'\v'-.13m'\L'1.249i\(br'\v'.13m' +.sp -1 +\h'0.351i'\v'2.777i'\D'l0.025i 0.100i' +.sp -1 +\h'0.401i'\v'2.777i'\D'l-0.025i 0.100i' +.sp -1 +\h'4.625i'\v'1.628i'\v'-.13m'\L'1.249i\(br'\v'.13m' +.sp -1 +\h'4.600i'\v'2.777i'\D'l0.025i 0.100i' +.sp -1 +\h'4.650i'\v'2.777i'\D'l-0.025i 0.100i' +.sp -1 +\h'2.125i'\v'0.253i'\v'-.13m'\L'0.375i\(br'\v'.13m' +.sp -1 +\h'2.100i'\v'0.528i'\D'l0.025i 0.100i' +.sp -1 +\h'2.150i'\v'0.528i'\D'l-0.025i 0.100i' +.sp -1 +\h'2.875i'\v'0.253i'\v'-.13m'\L'0.375i\(br'\v'.13m' +.sp -1 +\h'2.850i'\v'0.528i'\D'l0.025i 0.100i' +.sp -1 +\h'2.900i'\v'0.528i'\D'l-0.025i 0.100i' +.sp -1 +\h'1.126i'\v'0.253i'\v'-.13m'\L'0.375i\(br'\v'.13m' +.sp -1 +\h'1.101i'\v'0.528i'\D'l0.025i 0.100i' +.sp -1 +\h'1.151i'\v'0.528i'\D'l-0.025i 0.100i' +.sp -1 +\h'3.875i'\v'0.253i'\v'-.13m'\L'0.375i\(br'\v'.13m' +.sp -1 +\h'3.850i'\v'0.528i'\D'l0.025i 0.100i' +.sp -1 +\h'3.900i'\v'0.528i'\D'l-0.025i 0.100i' +.sp -1 +\v'4.002i'\D'l0.125i 0.125i' +.sp -1 +\h'0.125i'\v'4.127i'\l'3.000i' +.sp -1 +\h'3.125i'\v'4.127i'\D'l0.125i -0.125i' +.sp -1 +\h'3.500i'\v'4.002i'\D'l0.125i 0.125i' +.sp -1 +\h'3.625i'\v'4.127i'\l'1.250i' +.sp -1 +\h'4.875i'\v'4.127i'\D'l0.125i -0.125i' +.sp -1 +\h'1.626i'\v'4.344i'\h'-0.0m'\v'0.2m'\h'-\w'\s12\fRXLocale Source (X Core)\fP'u/2u'\s12\fRXLocale Source (X Core)\fP\h'-\w'\s12\fRXLocale Source (X Core)\fP'u/2u' +.sp -1 +\h'4.250i'\v'4.344i'\h'-0.0m'\v'0.2m'\h'-\w'\s12\fRSystem LOcale Source\fP'u/2u'\s12\fRSystem LOcale Source\fP\h'-\w'\s12\fRSystem LOcale Source\fP'u/2u' +.sp -1 +\h'2.500i'\v'0.782i'\h'-0.0m'\v'0.2m'\h'-\w'\s12\fRXLib API\fP'u/2u'\s12\fRXLib API\fP\h'-\w'\s12\fRXLib API\fP'u/2u' +.sp -1 +\h'2.500i'\v'0.969i'\h'-0.0m'\v'0.2m'\h'-\w'\s12\fR(X Core)\fP'u/2u'\s12\fR(X Core)\fP\h'-\w'\s12\fR(X Core)\fP'u/2u' +.sp -1 +\h'1.751i'\v'0.782i'\h'-0.0m'\v'0.2m'\s12\fR<<\fP +.sp -1 +\h'3.063i'\v'0.782i'\h'-0.0m'\v'0.2m'\s12\fR>>\fP +.sp -1 +.sp 1+4.344i +.in -1c +.PE +.if \n(00 .fi +.\" figure end +.LP +.ce +.sp 6p +Fig.1 : Frame Work of Locale Service API Proposal +.LP +Generally speaking, the internationalized portion of Xlib (Locale +Dependent X, LDX) consists of three objects; +locale (LC) , input method (IM) and output method (OM). +The LC provides a set of information that depends on user's language +environment. The IM manages text inputing, and the OM manages text +drawing. Both IM and OM highly depend on LC data. +.LP +In X11R5, there are two sample implementations, Ximp and Xsi, for +Xlib internationalization. But in both implementations, IM and OM +actually refer the private extension of LC. It breaks coexistence +of these two sample implementations. For example, if a user creates +a new OM for special purpose as a part of Ximp, it will not work with +Xsi. +.LP +As a solution of this problem, we propose to define the standard +APIs between these three objects, and define the structure that are +common to these objects. +.LP +.NH 1 +Objective +.XS \*(SN Objective +.XE +.LP +.IP \(bu +Explain the current X11R6 sample implementation +.IP \(bu +Document the common set of locale dependent interfaces +.IP \(bu +Provide more flexible pluggable layer +.LP +.NH 1 +Locale Object Binding Functions +.XS \*(SN Locale Object Binding Functions +.XE +.LP +This chapter describes functions related locale object binding for +implementing the pluggable layer. +.LP +A locale loader is an entry point for locale object, which +instantiates XLCd object and binds locale methods with specified +locale name. The behavior of loader is implementation dependent. +And, what kind of loaders are available is also implementation +dependent. +.LP +The loader is called in +.PN _XOpenLC, +but caller of +.PN _XOpenLC +does not need to care about its inside. For example, if the loader is +implemented with dynamic load functions, and the dynamic module is +expected to be unloaded when the corresponding XLCd is freed, +close methods of XLCdMethods should handle unloading. +.LP +.sp +\fBInitializing a locale loader list\fP +.LP +.FD 0 +void _XlcInitLoader() +.FN +The +.PN _XlcInitLoader +function initializes the locale loader list with vendor specific +manner. Each loader is registered with calling +.PN _XlcAddLoader. +The number of loaders and their order in the loader list is +implementation dependent. +.sp +.LP +\fBAdd a loader\fP +.LP +.Ds 0 +.TA .5i 2.5i +.ta .5i 2.5i +typedef XLCd (*XLCdLoadProc)(\fIname\fP); + char \fI*name\fP; + +typedef int XlcPosition; +.De +.TS +lw(.5i) lw(2i) lw(2i). +T{ +#define +T} T{ +XlcHead +T} T{ + 0 +T} +T{ +#define +T} T{ +XlcTail +T} T{ +-1 +T} +.TE +.LP +.FD 0 +Bool _XlcAddLoader(\fIproc, position\fP) +.br + XLCdLoadProc \fIproc\fP; +.br + XlcPosition \fIposition\fP; +.FN +.LP +The +.PN _XlcAddLoader +function registers the specified locale loader ``\fIproc\fP'' to the +internal loader list. The position specifies that the loader +``\fIproc\fP'' should be placed in the top of the loader list(XlcHead) +or last(XlcTail). +.LP +The object loader is called from the top of the loader list in order, +when calling time. +.sp +.LP +\fBRemove a loader\fP +.LP +.FD 0 +void _XlcRemoveLoader(\fIproc\fP) +.br + XLCdLoadProc \fIproc\fP; +.FN +.LP +The +.PN _XlcRemoveLoader +function removes the locale loader specified by ``\fIproc\fP'' from the +loader list. +.LP +Current implementation provides following locale loaders; +.DS +.PN _XlcDefaultLoader +.PN _XlcGenericLoader +.PN _XlcEucLoader +.PN _XlcSjisLoader +.PN _XlcUtfLoader +.PN _XaixOsDynamicLoad +.DE +.LP +.NH 1 +Locale Method Interface +.XS \*(SN Locale Method Interface +.XE +.LP +This chapter describes the locale method API, which is a set of +accessible functions from both IM and OM parts. +The locale method API provides the functionalities; obtaining locale +dependent information, handling charset, converting text, etc. +.LP +As a result of using these APIs instead of accessing vender private +extension of the locale object, we can keep locale, IM and OM +independently each other. +.LP +.NH 1 +Locale Method Functions +.XS \*(SN Locale Method Functions +.XE +.LP +\fBOpen a Locale Method\fP +.LP +.FD 0 +XLCd _XOpenLC(\fIname\fP) +.br + char \fI*name\fP; +.FN +.LP +The +.PN _XOpenLC +function opens a locale method which corresponds to the +specified locale name. +.PN _XOpenLC +calls a locale object loader, which is registered via +.PN _XlcAddLoader into the internal loader list. If the called loader +is valid and successfully opens a locale, +.PN _XOpenLC +returns the XLCd. If the loader is invalid or failed to open a locale, +.PN _XOpenLC +calls the next loader. If all registered loaders cannot open a locale, +.PN _XOpenLC +returns NULL. +.LP +.FD 0 +XLCd _XlcCurrentLC() +.FN +.LP +The +.PN _XlcCurrentLC +function returns an XLCd that are bound to current locale. +.sp +.LP +\fBClose a Locale Method\fP +.LP +.FD 0 +void _XCloseLC(\fIlcd\fP) +.br + XLCd \fIlcd\fP; +.FN +.LP +The +.PN _XCloseLC +function close a locale method the specified lcd. +.sp +.LP +\fBObtain Locale Method values\fP +.LP +.FD 0 +char * _XGetLCValues(\fIlcd\fP, ...) +.br + XLCd \fIlcd\fP; +.FN +.LP +The +.PN _XGetLCValues +function returns NULL if no error occurred; otherwise, it returns the +name of the first argument that could not be obtained. +The following values are defined as standard arguments. Other values +are implementation dependent. +.LP +.TS H +tab(:); +l l l. +_ +.sp 6p +.B +Name:Type:Description +.sp 6p +_ +.sp 6p +.TH +.R +XlcNCodeset:char*:codeset part of locale name +XlcNDefaultString:char*:XDefaultString() +XlcNEncodingName:char*:encoding name +XlcNLanguage:char*:language part of locale name +XlcNMbCurMax:int:ANSI C MB_CUR_MAX +XlcNStateDependentEncoding:Bool:is state-dependent encoding or not +XlcNTerritory:char*:territory part of locale name +.sp 6p +_ +.TE +.LP +.NH 1 +Charset functions +.XS \*(SN +Charset functions +.XE +.LP +The XlcCharSet is an identifier which represents a subset of characters +(character set) in the locale object. +.LP +.Ds 0 +.TA .5i 2.5i +.ta .5i 2.5i +typedef enum { + XlcUnknown, XlcC0, XlcGL, XlcC1, XlcGR, XlcGLGR, XlcOther +} XlcSide; + +typedef struct _XlcCharSetRec *XlcCharSet; + +typedef struct { + char *name; + XPointer value; +} XlcArg, *XlcArgList; + +typedef char* (*XlcGetCSValuesProc)(\fIcharset\fP, \fIargs\fP, \fInum_args\fP); + XlcCharSet \fIcharset\fP; + XlcArgList \fIargs\fP; + int \fInum_args\fP; + +typedef struct _XlcCharSetRec { + char *name; + XrmQuark xrm_name; + char *encoding_name; + XrmQuark xrm_encoding_name; + XlcSide side; + int char_size; + int set_size; + char *ct_sequence; + XlcGetCSValuesProc get_values; +} XlcCharSetRec; +.De +.sp +.LP +\fBGet an XlcCharSet\fP +.LP +.FD 0 +XlcCharSet _XlcGetCharSet(\fIname\fP) +.br + char \fI*name\fP; +.FN +.LP +The +.PN _XlcGetCharSet +function gets an XlcCharSet which corresponds to the charset name +specified by ``\fIname\fP''. +.PN _XlcGetCharSet +returns NULL, if no XlcCharSet bound to specified ``\fIname\fP''. +.LP +The following character sets are pre-registered. +.LP +.TS H +tab(@); +l l. +_ +.sp 6p +.B +Name@Description +.sp 6p +_ +.sp 6p +.TH +.R +ISO8859-1:GL@7-bit ASCII graphics (ANSI X3.4-1968), +@Left half of ISO 8859 sets +JISX0201.1976-0:GL@Left half of JIS X0201-1976 (reaffirmed 1984), +@8-Bit Alphanumeric-Katakana Code +.sp +ISO8859-1:GR@Right half of ISO 8859-1, Latin alphabet No. 1 +ISO8859-2:GR@Right half of ISO 8859-2, Latin alphabet No. 2 +ISO8859-3:GR@Right half of ISO 8859-3, Latin alphabet No. 3 +ISO8859-4:GR@Right half of ISO 8859-4, Latin alphabet No. 4 +ISO8859-7:GR@Right half of ISO 8859-7, Latin/Greek alphabet +ISO8859-6:GR@Right half of ISO 8859-6, Latin/Arabic alphabet +ISO8859-8:GR@Right half of ISO 8859-8, Latin/Hebrew alphabet +ISO8859-5:GR@Right half of ISO 8859-5, Latin/Cyrillic alphabet +ISO8859-9:GR@Right half of ISO 8859-9, Latin alphabet No. 5 +JISX0201.1976-0:GR@Right half of JIS X0201-1976 (reaffirmed 1984), +@8-Bit Alphanumeric-Katakana Code +.sp +GB2312.1980-0:GL@GB2312-1980, China (PRC) Hanzi defined as GL +GB2312.1980-0:GR@GB2312-1980, China (PRC) Hanzi defined as GR +JISX0208.1983-0:GL@JIS X0208-1983, Japanese Graphic Character Set +@defined as GL +JISX0208.1983-0:GR@JIS X0208-1983, Japanese Graphic Character Set +@defined as GR +KSC5601.1987-0:GL@KS C5601-1987, Korean Graphic Character Set +@defined as GL +KSC5601.1987-0:GR@KS C5601-1987, Korean Graphic Character Set +@defined as GR +JISX0212.1990-0:GL@JIS X0212-1990, Japanese Graphic Character Set +@defined as GL +JISX0212.1990-0:GR@JIS X0212-1990, Japanese Graphic Character Set +@defined as GR +.\" CNS11643.1986-0:GL +.\" CNS11643.1986-1:GL +.\" TIS620-0:GR +.sp 6p +_ +.TE +.LP +.sp +\fBAdd an XlcCharSet\fP +.LP +.FD 0 +Bool _XlcAddCharSet(\fIcharset\fP) + XlcCharSet \fIcharset\fP; +.FN +.LP +The +.PN _XlcAddCharSet +function registers XlcCharSet specified by ``\fIcharset\fP''. +.LP +.sp +\fBObtain Character Set values\fP +.LP +.FD 0 +char * _XlcGetCSValues(\fIcharset\fP, ...) +.br + XlcCharSet \fIcharset\fP; +.FN +.LP +The +.PN _XlcGetCSValues +function returns NULL if no error occurred; +otherwise, it returns the name of the first argument that could not +be obtained. The following values are defined as standard arguments. +Other values are implementation dependent. +.LP +.TS H +tab(:); +l l l. +_ +.sp 6p +.B +Name:Type:Description +.sp 6p +_ +.sp 6p +.TH +.R +XlcNName:char*:charset name +XlcNEncodingName:char*:XLFD CharSet Registry and Encoding +XlcNSide:XlcSide:charset side (GL, GR, ...) +XlcNCharSize:int:number of octets per character +XlcNSetSize:int:number of character sets +XlcNControlSequence:char*:control sequence of Compound Text +.sp 6p +_ +.TE +.LP +.NH 1 +Converter Functions +.XS \*(SN Converter Functions +.XE +.LP +We provide a set of the common converter APIs, that are independent +from both of source and destination text type. +.LP +.Ds 0 +.TA .5i 2.5i +.ta .5i 2.5i +typedef struct _XlcConvRec *XlcConv; + +typedef void (*XlcCloseConverterProc)(\fIconv\fP); + XlcConv \fIconv\fP; + +typedef int (*XlcConvertProc)(\fIconv\fP, \fIfrom\fP, \fIfrom_left\fP, \fIto\fP, \fIto_left\fP, \fIargs\fP, \fInum_args\fP); + XlcConv \fIconv\fP; + XPointer \fI*from\fP; + int \fI*from_left\fP; + XPointer \fI*to\fP; + int \fI*to_left\fP; + XPointer \fI*args\fP; + int \fInum_args\fP; + +typedef void (*XlcResetConverterProc)(\fIconv\fP); + XlcConv \fIconv\fP; + +typedef struct _XlcConvMethodsRec { + XlcCloseConverterProc close; + XlcConvertProc convert; + XlcResetConverterProc reset; +} XlcConvMethodsRec, *XlcConvMethods; + +typedef struct _XlcConvRec { + XlcConvMethods methods; + XPointer state; +} XlcConvRec; +.De +.LP +.sp +\fBOpen a converter\fP +.LP +.FD 0 +XlcConv _XlcOpenConverter(\fIfrom_lcd\fP, \fIfrom_type\fP, \fIto_lcd\fP, \fIto_type\fP) +.br + XLCd \fIfrom_lcd\fP; +.br + char \fI*from_type\fP; +.br + XLCd \fIto_lcd\fP; +.br + char \fI*to_type\fP; +.FN +.LP +.PN _XlcOpenConverter +function opens the converter which converts a text from specified +``\fIfrom_type\fP'' to specified ``\fIto_type\fP'' encoding. If the +function cannot find proper converter or cannot open a corresponding +converter, it returns NULL. Otherwise, it returns the conversion +descriptor. +.LP +The following types are pre-defined. Other types are implementation +dependent. +.LP +.TS H +tab(:); +l l l l. +_ +.sp 6p +.B +Name:Type:Description:Arguments +.sp 6p +_ +.sp 6p +.TH +.R +XlcNMultiByte:char *:multibyte:- +XlcNWideChar:wchar_t *:wide character:- +XlcNCompoundText:char *:COMPOUND_TEXT:- +XlcNString:char *:STRING:- +XlcNCharSet:char *:per charset:XlcCharSet +XlcNChar:char *:per character:XlcCharSet +.sp 6p +_ +.TE +.LP +.sp +\fBClose a converter\fP +.LP +.FD 0 +void _XlcCloseConverter(\fIconv\fP) +.br + XlcConv \fIconv\fP; +.FN +.LP +The +.PN _XlcCloseConverter +function closes the specified converter ``\fIconv\fP''. +.LP +.sp +\fBCode conversion\fP +.LP +.FD 0 +int _XlcConvert(\fIconv\fP, \fIfrom\fP, \fIfrom_left\fP, \fIto\fP, \fIto_left\fP, \fIargs\fP, \fInum_args\fP) +.br + XlcConv \fIconv\fP; +.br + XPointer \fI*from\fP; +.br + int \fI*from_left\fP; +.br + XPointer \fI*to\fP; +.br + int \fI*to_left\fP; +.br + XPointer \fI*args\fP; +.br + int \fInum_args\fP; +.FN +.LP +The +.PN _XlcConvert +function converts a sequence of characters from one type, in the array +specified by ``\fIfrom\fP'', into a sequence of corresponding characters +in another type, in the array specified by ``\fIto\fP''. The types are +those specified in the +.PN _XlcOpenConverter() +call that returned the conversion descriptor, ``\fIconv\fP''. +The arguments ``\fIfrom\fP'', ``\fIfrom_left\fP'', ``\fIto\fP'' and +``\fIto_left\fP'' have the same specification of XPG4 iconv function. +.LP +For state-dependent encodings, the conversion descriptor ``\fIconv\fP'' +is placed into its initial shift state by a call for which ``\fIfrom\fP'' +is a NULL pointer, or for which ``\fIfrom\fP'' points to a null pointer. +.LP +The following 2 converters prepared by locale returns appropriate +charset (XlcCharSet) in an area pointed by args[0]. +.LP +.TS +tab(:); +l l l. +_ +.sp 6p +.B +From:To:Description +.sp 6p +_ +.sp 6p +.R +XlcNMultiByte:XlcNCharSet:Segmentation (Decomposing) +XlcNWideChar:XlcNCharSet:Segmentation (Decomposing) +.sp 6p +_ +.TE +.LP +The conversion, from XlcNMultiByte/XlcNWideChar to XlcNCharSet, +extracts a segment which has same charset encoding characters. +More than one segment cannot be converted in a call. +.LP +.sp +\fBReset a converter\fP +.LP +.FD 0 +void _XlcResetConverter(\fIconv\fP) +.br + XlcConv \fIconv\fP; +.FN +.LP +The +.PN _XlcResetConverter +function reset the specified converter ``\fIconv\fP''. +.LP +.sp +\fBRegister a converter\fP +.LP +.Ds 0 +.TA .5i 2.5i +.ta .5i 2.5i +typedef XlcConv (*XlcOpenConverterProc)(\fIfrom_lcd\fP, \fIfrom_type\fP, \fIto_lcd\fP, \fIto_type\fP); + XLCd \fIfrom_lcd\fP; + char \fI*from_type\fP; + XLCd \fIto_lcd\fP; + char \fI*to_type\fP; +.De +.LP +.FD 0 +Bool _XlcSetConverter(\fIfrom_lcd\fP, \fIfrom\fP, \fIto_lcd\fP, \fIto\fP, \fIconverter\fP) +.br + XLCd \fIfrom_lcd\fP; +.br + char \fI*from\fP; +.br + XLCd \fIto_lcd\fP; +.br + char \fI*to\fP; +.br + XlcOpenConverterProc \fIconverter\fP; +.FN +.LP +The \fBXlcSetConverter\fP function registers a converter which convert +from ``\fIfrom_type\fP'' to ``\fIto_type\fP'' into the converter list +(in the specified XLCd). +.LP +.NH 1 +X Locale Database functions +.XS \*(SN X Locale Database functions +.XE +.LP +X Locale Database contains the subset of user's environment that +depends on language. The following APIs are provided for accessing +X Locale Database and other locale relative files. +.LP +For more detail about X Locale Database, please refer +X Locale Database Definition document. +.LP +.sp +\fBGet a resource from database\fP +.LP +.FD 0 +void _XlcGetResource(\fIlcd\fP, \fIcategory\fP, \fIclass\fP, \fIvalue\fP, \fIcount\fP) +.br + XLCd \fIlcd\fP; +.br + char \fI*category\fP; +.br + char \fI*class\fP; +.br + char \fI***value\fP; +.br + int \fI*count\fP; +.FN +.LP +The +.PN _XlcGetResource +function obtains a locale dependent data which is associated with the +locale of specified ``\fIlcd\fP''. +The locale data is provided by system locale or by X Locale Database +file, and what kind of data is available is implementation dependent. +.LP +The specified ``\fIcategory\fP'' and ``\fIclass\fP'' are used for +finding out the objective locale data. +.LP +The returned value is returned in value argument in string list form, +and the returned count shows the number of strings in the value. +.LP +The returned value is owned by locale method, and should not be modified +or freed by caller. +.LP +.sp +\fBGet a locale relative file name\fP +.LP +.FD 0 +char * _XlcFileName(\fIlcd\fP, \fIcategory\fP) +.br + XLCd \fIlcd\fP; +.br + char \fI*category\fP; +.FN +.LP +The +.PN _XlcFileName +functions returns a file name which is bound to the specified ``\fIlcd\fP'' +and ``\fIcategory\fP'', as a null-terminated string. If no file name can +be found, or there is no readable file for the found file name, +.PN _XlcFileName +returns NULL. The returned file name should be freed by caller. +.LP +The rule for searching a file name is implementation dependent. +In current implementation, +.PN _XlcFileName +uses ``{category}.dir'' file as mapping table, which has pairs of +strings, a full locale name and a corresponding file name. +.LP +.NH 1 +Utility Functions +.XS \*(SN Utility Functions +.XE +.LP +\fBCompare Latin-1 strings\fP +.LP +.FD 0 +int _XlcCompareISOLatin1(\fIstr1\fP, \fIstr2\fP) +.br + char \fI*str1\fP, \fI*str2\fP; +.FN +.FD 0 +int _XlcNCompareISOLatin1(\fIstr1\fP, \fIstr2\fP, \fIlen\fP) +.br + char \fI*str1\fP, \fI*str2\fP; +.br + int \fIlen\fP; +.FN +.LP +The +.PN _XlcCompareIsoLatin1 +function to compares two ISO-8859-1 strings. Bytes representing ASCII lower +case letters are converted to upper case before making the comparison. +The value returned is an integer less than, equal to, or greater than +zero, depending on whether ``\fIstr1\fP'' is lexicographicly less than, +equal to, or greater than ``\fIstr2\fP''. +.LP +The +.PN _XlcNCompareIsoLatin1 +function is identical to +.PN _XlcCompareISOLatin1, +except that at most ``\fIlen\fP'' bytes are compared. +.LP +.sp +\fBResource Utility\fP +.LP +.FD 0 +int XlcNumber(\fIarray\fP) + ArrayType \fIarray\fP; +.FN +.LP +Similar to XtNumber. +.LP +.FD 0 +void _XlcCopyFromArg(\fIsrc\fP, \fIdst\fP, \fIsize\fP) +.br + char \fI*src\fP; +.br + char \fI*dst\fP; +.br + int \fIsize\fP; +.FN +.FD 0 +void _XlcCopyToArg(\fIsrc\fP, \fIdst\fP, \fIsize\fP) +.br + char \fI*src\fP; +.br + char \fI**dst\fP; +.br + int \fIsize\fP; +.FN +.LP +Similar to +.PN _XtCopyFromArg +and +.PN _XtCopyToArg. +.LP +.FD 0 +void _XlcCountVaList(\fIvar\fP, \fIcount_ret\fP) +.br + va_list \fIvar\fP; +.br + int \fI*count_ret\fP; +.FN +.LP +Similar to +.PN _XtCountVaList. +.LP +.FD 0 +void _XlcVaToArgList(\fIvar\fP, \fIcount\fP, \fIargs_ret\fP) +.br + va_list \fIvar\fP; +.br + int \fIcount\fP; +.br + XlcArgList \fI*args_ret\fP; +.FN +.LP +Similar to +.PN _XtVaToArgList. +.LP +.Ds 0 +.TA .5i 2.5i +.ta .5i 2.5i +typedef struct _XlcResource { + char *name; + XrmQuark xrm_name; + int size; + int offset; + unsigned long mask; +} XlcResource, *XlcResourceList; +.De +.LP +.TS +lw(.5i) lw(2i) lw(2i). +T{ +#define +T} T{ +XlcCreateMask +T} T{ +(1L<<0) +T} +T{ +#define +T} T{ +XlcDefaultMask +T} T{ +(1L<<1) +T} +T{ +#define +T} T{ +XlcGetMask +T} T{ +(1L<<2) +T} +T{ +#define +T} T{ +XlcSetMask +T} T{ +(1L<<3) +T} +T{ +#define +T} T{ +XlcIgnoreMask +T} T{ +(1L<<4) +T} +.TE +.LP +.FD 0 +void _XlcCompileResourceList(\fIresources\fP, \fInum_resources\fP) +.br + XlcResourceList \fIresources\fP; +.br + int \fInum_resources\fP; +.FN +.LP +Similar to +.PN _XtCompileResourceList. +.LP +.FD 0 +char * _XlcGetValues(\fIbase\fP, \fIresources\fP, \fInum_resources\fP, \fIargs\fP, \fInum_args\fP, \fImask\fP) +.br + XPointer \fIbase\fP; +.br + XlcResourceList \fIresources\fP; +.br + int \fInum_resources\fP; +.br + XlcArgList \fIargs\fP; +.br + int \fInum_args\fP; +.br + unsigned long \fImask\fP; +.FN +.LP +Similar to XtGetSubvalues. +.LP +.FD 0 +char * _XlcSetValues(\fIbase\fP, \fIresources\fP, \fInum_resources\fP, \fIargs\fP, \fInum_args\fP, \fImask\fP) +.br + XPointer \fIbase\fP; +.br + XlcResourceList \fIresources\fP; +.br + int \fInum_resources\fP; +.br + XlcArgList \fIargs\fP; +.br + int \fInum_args\fP; +.br + unsigned long \fImask\fP; +.FN +.LP +Similar to XtSetSubvalues. +.LP +.sp +\fBANSI C Compatible Functions\fP +.LP +The following are ANSI C/MSE Compatible Functions for non-ANSI C environment. +.LP +.FD 0 +int _Xmblen(\fIstr\fP, \fIlen\fP) +.br + char \fI*str\fP; +.br + int \fIlen\fP; +.FN +.LP +The +.PN _Xmblen +function returns the number of characters pointed to by ``\fIstr\fP''. +Only ``\fIlen\fP'' bytes in ``\fIstr\fP'' are used in determining the +character count returned. ``\fIStr\fP'' may point at characters from +any valid codeset in the current locale. +.LP +The call +.PN _Xmblen +is equivalent to +.RS +_Xmbtowc(_Xmbtowc((\fIwchar_t*\fP)NULL, \fIstr\fP, \fIlen\fP)) +.RE +.LP +.FD 0 +int _Xmbtowc(\fIwstr\fP, \fIstr\fP, \fIlen\fP) +.br + wchar_t \fI*wstr\fP; +.br + char \fI*str\fP; +.br + int \fIlen\fP; +.FN +.LP +The +.PN _Xmbtowc +function converts the character(s) pointed to by ``\fIstr\fP'' +to their wide character representation(s) pointed to by ``\fIwstr\fP''. +``\fILen\fP'' is the number of bytes in ``\fIstr\fP'' to be converted. +The return value is the number of characters converted. +.LP +The call +.PN _Xmbtowc +is equivalent to +.RS +_Xlcmbtowc((XLCd)NULL, \fIwstr\fP, \fIstr\fP, \fIlen\fP) +.RE +.LP +.FD 0 +int _Xlcmbtowc(\fIlcd\fP, \fIwstr\fP, \fIstr\fP, \fIlen\fP) +.br + XLCd \fIlcd\fP; +.br + wchar_t \fI*wstr\fP; +.br + char \fI*str\fP; +.br + int \fIlen\fP; +.FN +.LP +The +.PN _Xlcmbtowc +function is identical to +.PN _Xmbtowc, +except that it requires the ``\fIlcd\fP'' argument. If ``\fIlcd\fP'' +is (XLCd) NULL, +.PN _Xlcmbtowc, +calls +.PN _XlcCurrentLC +to determine the current locale. +.LP +.FD 0 +int _Xwctomb(\fIstr\fP, \fIwc\fP) +.br + char \fI*str\fP; +.br + wchar_t \fIwc\fP; +.FN +.LP +The +.PN _Xwctomb +function converts a single wide character pointed to by ``\fIwc\fP'' to +its multibyte representation pointed to by ``\fIstr\fP''. +On success, the return value is 1. +.LP +The call +.PN _Xwctomb +is equivalent to +.RS +_Xlcwctomb((XLCd)NULL, \fIstr\fP, \fIwstr\fP) +.RE +.LP +.FD 0 +int _Xlcwctomb(\fIlcd\fP, \fIstr\fP, \fIwc\fP) +.br + XLCd \fIlcd\fP; +.br + char \fI*str\fP; +.br + wchar_t \fIwc\fP; +.FN +.LP +The +.PN _Xlcwctomb +function is identical to _Xwctomb, except that it requires the +``\fIlcd\fP'' argument. If ``\fIlcd\fP'' is (XLCd) NULL, +.PN _Xlcwctomb, +calls +.PN _XlcCurrentLC +to determine the current locale. +.LP +.FD 0 +int _Xmbstowcs(\fIwstr\fP, \fIstr\fP, \fIlen\fP) +.br + wchar_t \fI*wstr\fP; +.br + char \fI*str\fP; +.br + int \fIlen\fP; +.FN +.LP +The +.PN _Xmbstowcs +function converts the NULL-terminated string pointed to by ``\fIstr\fP'' +to its wide character string representation pointed to by ``\fIwstr\fP''. +``\fILen\fP'' is the number of characters in ``\fIstr\fP'' to be converted. +.LP +The call +.PN _Xmbstowcs +is equivalent to +.RS +_Xlcmbstowcs((XLCd)NULL, \fIwstr\fP, \fIstr\fP, \fIlen\fP) +.RE +.LP +.FD 0 +int _Xlcmbstowcs(\fIlcd\fP, \fIwstr\fP, \fIstr\fP, \fIlen\fP) +.br + XLCd \fIlcd\fP; +.br + wchar_t \fI*wstr\fP; +.br + char \fI*str\fP; +.br + int \fIlen\fP; +.FN +.LP +The +.PN _Xlcmbstowcs +function is identical to _Xmbstowcs, except that it requires the +``\fIlcd\fP'' argument. If ``\fIlcd\fP'' is (XLCd) NULL, +.PN _Xlcmbstowcs, +calls +.PN _XlcCurrentLC +to determine the current locale. +.LP +.FD 0 +int _Xwcstombs(\fIstr\fP, \fIwstr\fP, \fIlen\fP) +.br + char \fI*str\fP; +.br + wchar_t \fI*wstr\fP; +.br + int \fIlen\fP; +.FN +.LP +The +.PN _Xwcstombs +function converts the (wchar_t) NULL terminated wide character string +pointed to by ``\fIwstr\fP'' to the NULL terminated multibyte string +pointed to by ``\fIstr\fP''. +.LP +The call +.PN _Xwcstombs +is equivalent to +.RS +_Xlcwcstombs((XLCd)NULL, \fIstr\fP, \fIwstr\fP, \fIlen\fP) +.RE +.LP +.FD 0 +int _Xlcwcstombs(\fIlcd\fP, \fIstr\fP, \fIwstr\fP, \fIlen\fP) +.br + XLCd \fIlcd\fP; +.br + char \fI*str\fP; +.br + wchar_t \fI*wstr\fP; +.br + int \fIlen\fP; +.FN +.LP +The +.PN _Xlcwcstombs +function is identical to _Xwcstombs, except that it requires the +``\fIlcd\fP'' argument. If ``\fIlcd\fP'' is (XLCd) NULL, +.PN _Xlcwcstombs, +calls +.PN _XlcCurrentLC +to determine the current locale. +.LP +.FD 0 +int _Xwcslen(\fIwstr\fP) +.br + wchar_t \fI*wstr\fP; +.FN +.LP +The +.PN _Xwcslen +function returns the count of wide characters in the (wchar_t) NULL +terminated wide character string pointed to by ``\fIwstr\fP''. +.LP +.FD 0 +wchar_t * _Xwcscpy(\fIwstr1\fP, \fIwstr2\fP) +.br + wchar_t \fI*wstr1\fP, \fI*wstr2\fP; +.FN +.FD 0 +wchar_t * _Xwcsncpy(\fIwstr1\fP, \fIwstr2\fP, \fIlen\fP) +.br + wchar_t \fI*wstr1\fP, \fI*wstr2\fP; +.br + int \fIlen\fP; +.FN +.LP +The +.PN _Xwcscpy +function copies the (wchar_t) NULL terminated wide character string +pointed to by ``\fIwstr2\fP'' to the object pointed at by ``\fIwstr1\fP''. +``\fIWstr1\fP'' is (wchar_t) NULL terminated. The return value is a +pointer to ``\fIwstr1\fP''. +.LP +The +.PN _Xwcsncpy +function is identical to +.PN _Xwcscpy, +except that it copies ``\fIlen\fP'' wide characters from the object +pointed to by ``\fIwstr2\fP'' to the object pointed to ``\fIwstr1\fP''. +.LP +.FD 0 +int _Xwcscmp(\fIwstr1\fP, \fIwstr2\fP) +.br + wchar_t \fI*wstr1\fP, \fI*wstr2\fP; +.FN +.FD 0 +int _Xwcsncmp(\fIwstr1\fP, \fIwstr2\fP, \fIlen\fP) +.br + wchar_t \fI*wstr1\fP, \fI*wstr2\fP; +.br + int \fIlen\fP; +.FN +.LP +The +.PN _Xwcscmp +function compares two (wchar_t) NULL terminated wide character strings. +The value returned is an integer less than, equal to, or greater than zero, +depending on whether ``\fIwstr1\fP'' is lexicographicly less then, equal to, +or greater than ``\fIstr2\fP''. +.LP +The +.PN _Xwcsncmp +function is identical to +.PN _XlcCompareISOLatin1, +except that at most ``\fIlen\fP'' wide characters are compared. +.sp +.\" -------------------------------------------------------------------- +.\" .LP +.\" \fBLocale Method Internal Functions\fP +.\" .LP +.\" .FD 0 +.\" XlcCharSet _XlcCreateDefaultCharSet(\fIname\fP, \fIct_sequence\fP) +.\" .br +.\" char \fI*name\fP; +.\" .br +.\" char \fI*ct_sequence\fP; +.\" .FN +.\" .FD 0 +.\" Bool _XlcParseCharSet(\fIcharset\fP) +.\" .br +.\" XlcCharSet \fIcharset\fP; +.\" .FN +.\" .FD 0 +.\" void _XlcGetLocaleDataBase(\fIlcd\fP, \fIcategory\fP, \fIname\fP, \fIvalue\fP, \fIcount\fP) +.\" .br +.\" XLCd \fIlcd\fP; +.\" .br +.\" char \fI*category\fP; +.\" .br +.\" char \fI*name\fP; +.\" .br +.\" char \fI***value\fP; +.\" .br +.\" int \fI*count\fP; +.\" .FN +.\" .FD 0 +.\" void _XlcDestroyLocaleDataBase(\fIlcd\fP) +.\" .br +.\" XLCd \fIlcd\fP; +.\" .FN +.\" .FD 0 +.\" XPointer _XlcCreateLocaleDataBase(\fIlcd\fP) +.\" .br +.\" XLCd \fIlcd\fP; +.\" .FN +.\" .LP +.\" .sp +.\" \fBObtain an locale database path\fP +.\" .LP +.\" .FD 0 +.\" int _XlcResolveI18NPath(\fIdir\fP) +.\" .br +.\" char \fI*dir\fP; +.\" .FN +.\" .LP +.\" The +.\" .PN _XlcResolveI18NPath +.\" function returns path name list that is related to X Locale Database. +.\" The obtained path is stored into the array which is pointed by +.\" specified ``\fIdir\fP''. The path consists of directory paths which +.\" are separated with colon. +.\" If the environment variable XLOCALEDIR is specified, the path +.\" contains its contents. +.\" .LP +.\" The default path of X Locale Database is implementation dependent. +.\" In current implementation, it's determined in build time. +.\" .LP +.\" .PN _XlcResolveI18NPath +.\" does not check overflow of the array to which the ``\fIdir\fP'' +.\" parameter points. Caller should provide enough buffer to store this +.\" string. +.\" .LP +.\" .sp +.\" \fBObtain a full locale name\fP +.\" .LP +.\" .FD 0 +.\" int _XlcResolveLocaleName(\fIlc_name\fP, \fIfull_name\fP, \fIlanguage\fP, \fIterritory\fP, \fIcodeset\fP) +.\" .br +.\" char \fI*lc_name\fP; +.\" .br +.\" char \fI*full_name\fP; +.\" .br +.\" char \fI*language\fP; +.\" .br +.\" char \fI*territory\fP; +.\" .br +.\" char \fI*codeset\fP; +.\" .FN +.\" .LP +.\" The +.\" .PN _XlcResolveLocaleName +.\" function returns a full locale name. +.\" The obtained full locale name is stored into the array which is +.\" pointed by specified ``\fIfull_name\fP''. +.\" The language, territory and codeset part of the full locale name +.\" are copied to the return arguments, ``\fIlanguage\fP'', +.\" ``\fIterritory\fP'' and ``\fIcodeset\fP'', respectively. +.\" NULL can be specified for these arguments. +.\" .LP +.\" The rule for mapping from locale name to full locale name is +.\" implementation dependent. +.\" .LP +.\" .PN _XlcResolveLocaleName +.\" does not check overflow of the array to which +.\" ``\fIfull_name\fP'', ``\fIlanguage\fP'', ``\fIterritory\fP'' and +.\" ``\fIcodeset\fP'' parameter point. +.\" Caller should provide enough buffer to store those string. +.\" .LP +.\" In current implementation, +.\" .PN _XlcResolveLocaleName +.\" uses locale.alias file as mapping table, which has pairs of strings, +.\" a locale name and a full locale name. +.\" .LP +.\" .FD 0 +.\" int _XlcResolveDBName(\fIlc_name\fP, \fIfile_name\fP) +.\" .br +.\" char \fI*lc_name\fP; +.\" .br +.\" char \fI*file_name\fP; +.\" .FN +.\" .FD 0 +.\" XLCd _XlcCreateLC(\fIname\fP, \fImethods\fP) +.\" .br +.\" char \fI*name\fP; +.\" .br +.\" XLCdMethods \fImethods\fP; +.\" .FN +.\" .FD 0 +.\" void _XlcDestroyLC(\fIlcd\fP) +.\" .br +.\" XLCd \fIlcd\fP; +.\" .FN +.\" .LP +.\" + diff --git a/libX11/specs/i18n/LocaleDB.ms b/libX11/specs/i18n/LocaleDB.ms new file mode 100644 index 000000000..5ba792297 --- /dev/null +++ b/libX11/specs/i18n/LocaleDB.ms @@ -0,0 +1,502 @@ +.\" $Xorg: LocaleDB.ms,v 1.3 2000/08/17 19:42:49 cpqbld Exp $ +.\" $XdotOrg: xc/doc/specs/i18n/LocaleDB.ms,v 1.2 2004/04/23 18:42:19 eich Exp $ +.\" To print this out, type tbl macros.t ThisFile | troff -ms +.EH '''' +.OH '''' +.EF '''' +.OF '''' +.ps 11 +.nr PS 11 +\& +.TL +\s+3\fBX Locale Database Definition\fP\s-3 +.sp 2 +.AU +Yoshio Horiuchi +.AI +IBM Japan +.LP +.bp +.br +\& +.ps 9 +.nr PS 9 +.sp 2 +.LP +Copyright \(co IBM Corporation 1994 +.LP +All Rights Reserved +.LP +License 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 of IBM not be +used in advertising or publicity pertaining to distribution of the +software without specific, written prior permission. +.LP +IBM DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING +ALL IMPLIED WARRANTIES OF MERCHANTABILITY, FITNESS, AND +NONINFRINGEMENT OF THIRD PARTY RIGHTS, IN NO EVENT SHALL +IBM 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 5 +Copyright \(co 1994 X Consortium +.LP +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: +.LP +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. +.LP +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 +X CONSORTIUM 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. +.LP +Except as contained in this notice, the name of the X Consortium 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 X Consortium. +.sp 3 +\fIX Window System\fP is a trademark of The Open Group. +.LP +.bp 1 +.ps 11 +.nr PS 11 +.EH '\fBX Locale Database Definition\fP''\fB\*(xV\fP' +.OH '\fBX Locale Database Definition\fP''\fB\*(xV\fP' +.EF ''\fB % \fP'' +.OF ''\fB % \fP'' +.NH 1 +General +.XS +\*(SN General +.XE +.LP +An X Locale Database contains the subset of a user's environment that +depends on language, in X Window System. It is made up from one or more +categories. Each category consists of some classes and sub-classes. +.LP +It is provided as a plain ASCII text file, so a user can change its +contents easily. It allows a user to customize the behavior of +internationalized portion of Xlib without changing Xlib itself. +.LP +This document describes; +.RS +.IP +Database Format Definition +.IP +Contents of Database in sample implementation +.RE +.LP +Since it is hard to define the set of required information for all +platforms, only the flexible database format is defined. +The available entries in database are implementation dependent. +.LP +.NH 1 +Database Format Definition +.XS +\*(SN Database Format Definition +.XE +.LP +The X Locale Database contains one or more category definitions. +This section describes the format of each category definition. +.LP +The category definition consists of one or more class definitions. +Each class definition has a pair of class name and class value, or +has several subclasses which are enclosed by the left brace ({) and +the right brace (}). +.LP +Comments can be placed by using the number sign character (#). +Putting the number sign character on the top of the line indicates +that the entire line is comment. Also, putting any whitespace character +followed by the number sign character indicates that a part of the line +(from the number sign to the end of the line) is comment. +A line can be continued by placing backslash (\\) character as the +last character on the line; this continuation character will be +discarded from the input. Comment lines cannot be continued on +a subsequent line using an escaped new line character. +.LP +X Locale Database only accepts XPCS, the X Portable Character Set. +The reserved symbols are; the quotation mark("), the number sign (#), +the semicolon(;), the backslash(\\), the left brace({) and +the right brace(}). +.LP +The format of category definition is; +.RS +.TS +tab(@); +l l l +l l l +l l l +l l l +l l l +l l l +l l l +l l l +l l l +l l l +l l l +l l l +l l l +l l l +l r l +l r l +l l l. +CategoryDefinition@::=@CategoryHeader CategorySpec CategoryTrailer +CategoryHeader@::=@CategoryName NL +CategorySpec@::=@{ ClassSpec } +CategoryTrailer@::=@"END" Delimiter CategoryName NL +CategoryName@::=@String +ClassSpec@::=@ClassName Delimiter ClassValue NL +ClassName@::=@String +ClassValue@::=@ValueList | "{" NL { ClassSpec } "}" +ValueList@::=@Value | Value ";" ValueList +Value@::=@ValuePiece | ValuePiece Value +ValuePiece@::=@String | QuotedString | NumericString +String@::=@Char { Char } +QuotedString@::=@""" QuotedChar { QuotedChar } """ +NumericString@::=@"\\\\o" OctDigit { OctDigit } +@|@"\\\\d" DecDigit { DecDigit } +@|@"\\\\x" HexDigit { HexDigit } +Char@::=@ +QuotedChar@::=@ +OctDigit@::=@ +DecDigit@::=@ +HexDigit@::=@ +Delimiter@::=@ Space { Space } +Space@::=@ | +NL@::=@ +.TE +.RE +.LP +Elements separated by vertical bar (|) are alternatives. Curly +braces ({...}) indicate zero or more repetitions of the enclosed +elements. Square brackets ([...]) indicate that the enclosed element +is optional. Quotes ("...") are used around literal characters. +.LP +The backslash, which is not the top character of the NumericString, is +recognized as an escape character, so that the next one character is +treated as a literal character. For example, the two-character +sequence, ``\\"''(the backslash followed by the quotation mark) is +recognized and replaced with a quotation mark character. +Any whitespace character, that is not the Delimiter, unquoted and +unescaped, is ignored. +.LP +.NH 1 +Contents of Database +.XS +\*(SN Contents of Database +.XE +.LP +The available categories and classes depend on implementation, because +different platform will require different information set. +For example, some platform have system locale but some platform don't. +Furthermore, there might be a difference in functionality even if the +platform has system locale. +.LP +In current sample implementation, categories listed below are available. +.RS +.TS +tab(:); +l l. +XLC_FONTSET:XFontSet relative information +XLC_XLOCALE:Character classification and conversion information +.TE +.RE +.LP +.NH 1 +XLC_FONTSET Category +.XS +\*(SN XLC_FONTSET Category +.XE +.LP +The XLC_FONTSET category defines the XFontSet relative information. +It contains the CHARSET_REGISTRY-CHARSET_ENCODING name and character +mapping side (GL, GR, etc), and is used in Output Method (OM). +.RS +.TS H +tab(:); +lw(1.5i) l l. +_ +.sp 6p +.B +class:super class:description +.sp 6p +_ +.sp 6p +.TH +.R +fsN::Nth fontset (N=0,1,2, ...) +.sp +charset:fsN:list of encoding name +font:fsN:list of font encoding name +.sp 6p +_ +.TE +.RE +.LP +.IP "fsN" +.br +Includes an encoding information for Nth charset, where N is +the index number (0,1,2,...). If there are 4 charsets available +in current locale, 4 fontsets, fs0, fs1, fs2 and fs3, should be +defined. +This class has two subclasses, `charset' and `font'. +.IP "charset" +Specifies an encoding information to be used internally in Xlib +for this fontset. The format of value is; +.RS +.TS +tab(;); +l l l. +EncodingInfo;::=;EncodingName [ ":" EncodingSide ] +EncodingName;::=;CHARSET_REGISTRY-CHARSET_ENCODING +EncodingSide;::=;"GL" | "GR" +.TE +.RE +For detail definition of CHARSET_REGISTRY-CHARSET_ENCODING, refer +"X Logical Font Descriptions" document. +.IP +example: +.br + ISO8859-1:GL +.IP "font" +.br +Specifies a list of encoding information which is used for searching +appropriate font for this fontset. The left most entry has highest +priority. +.LP +.NH 1 +XLC_XLOCALE Category +.XS +\*(SN XLC_XLOCALE Category +.XE +.LP +The XLC_XLOCALE category defines character classification, conversion +and other character attributes. +.RS +.TS H +tab(:); +lw(1.5i) l l. +_ +.sp 6p +.B +class:super class:description +.sp 6p +_ +.sp 6p +.TH +.R +encoding_name::codeset name +mb_cur_max::MB_CUR_MAX +state_depend_encoding::state dependent or not +wc_encoding_mask::for parsing wc string +wc_shift_bits::for conversion between wc and mb +csN::Nth charset (N=0,1,2,...) +.sp +side:csN:mapping side (GL, etc) +length:csN:length of a character +mb_encoding:csN:for parsing mb string +wc_encoding:csN:for parsing wc string +ct_encoding:csN:list of encoding name for ct +.sp 6p +_ +.TE +.RE +.LP +.IP "encoding_name" +Specifies a codeset name of current locale. +.IP "mb_cur_max" +Specifies a maximum allowable number of bytes in a multi-byte character. +It is corresponding to MB_CUR_MAX of "ISO/IEC 9899:1990 C Language Standard". +.IP "state_depend_encoding" +Indicates a current locale is state dependent. The value should be +specified "True" or "False". +.IP "wc_encoding_mask" +Specifies a bit-mask for parsing wide-char string. Each wide character is +applied bit-and operation with this bit-mask, then is classified into +the unique charset, by using `wc_encoding'. +.IP "wc_shift_bits" +Specifies a number of bit to be shifted for converting from a multi-byte +character to a wide character, and vice-versa. +.IP "csN" +.br +Includes a character set information for Nth charset, where N is the +index number (0,1,2,...). If there are 4 charsets available in current +locale, cs0, cs1, cs2 and cs3 should be defined. This class has five +subclasses, `side', `length', `mb_encoding' `wc_encoding' and `ct_encoding'. +.IP "side" +.br +Specifies a mapping side of this charset. The format of this value is; +.RS +.TS +tab(@); +l l l. +Side@::=@EncodingSide [``:Default''] +.TE +.RE +The suffix ":Default" can be specified. It indicates that a character +belongs to the specified side is mapped to this charset in initial state. +.IP "length" +.br +Specifies a number of bytes of a multi-byte character of this charset. +It should not contain the length of any single-shift sequence. +.IP "mb_encoding" +Specifies a list of shift sequence for parsing multi-byte string. +The format of this value is; +.RS +.TS +tab(@); +l l l +l r l +l l l +l l l +l l l +l l l +c l s +c l s. +MBEncoding@::=@ShiftType ShiftSequence +@|@ShiftType ShiftSequence ";" MBEncoding +ShiftType@::=@"" | "" | "" +ShiftSequence@::=@SequenceValue | SequenceValue ShiftSequence +SequenceValue@::=@NumericString +.sp +shift types: +@Indicates single shift sequence +@Indicates locking shift left sequence +@Indicates locking shift right sequence +.TE +.RE +example: +.br + \\x1b \\x28 \\x4a; \\x1b \\x28 \\x42 +.LP +.IP "wc_encoding" +Specifies an integer value for parsing wide-char string. +It is used to determine the charset for each wide character, after +applying bit-and operation using `wc_encoding_mask'. +This value should be unique in all csN classes. +.IP "ct_encoding" +Specifies a list of encoding information that can be used for Compound +Text. +.LP +.NH 1 +Sample of X Locale Database +.XS +\*(SN Sample of X Locale Database +.XE +.LP +The following is sample X Locale Database file. +.LP +.sp +.RS +.nf +# $Xorg: LocaleDB.ms,v 1.3 2000/08/17 19:42:49 cpqbld Exp $ +# XLocale Database Sample for ja_JP.euc +# + +# +# XLC_FONTSET category +# +XLC_FONTSET +# fs0 class (7 bit ASCII) +fs0 { + charset ISO8859-1:GL + font ISO8859-1:GL; JISX0201.1976-0:GL +} +# fs1 class (Kanji) +fs1 { + charset JISX0208.1983-0:GL + font JISX0208.1983-0:GL +} +# fs2 class (Half Kana) +fs2 { + charset JISX0201.1976-0:GR + font JISX0201.1976-0:GR +} +# fs3 class (User Defined Character) +# fs3 { +# charset JISX0212.1990-0:GL +# font JISX0212.1990-0:GL +# } +END XLC_FONTSET + +# +# XLC_XLOCALE category +# +XLC_XLOCALE + +encoding_name ja.euc +mb_cur_max 3 +state_depend_encoding False + +wc_encoding_mask \\x00008080 +wc_shift_bits 8 + +# cs0 class +cs0 { + side GL:Default + length 1 + wc_encoding \\x00000000 + ct_encoding ISO8859-1:GL; JISX0201.1976-0:GL +} +# cs1 class +cs1 { + side GR:Default + length 2 + + wc_encoding \\x00008080 + + ct_encoding JISX0208.1983-0:GL; JISX0208.1983-0:GR;\\ + JISX0208.1983-1:GL; JISX0208.1983-1:GR +} + +# cs2 class +cs2 { + side GR + length 1 + mb_encoding \\x8e + + wc_encoding \\x00000080 + + ct_encoding JISX0201.1976-0:GR +} + +# cs3 class +# cs3 { +# side GL +# length 2 +# mb_encoding \\x8f +# #if HasWChar32 +# wc_encoding \\x20000000 +# #else +# wc_encoding \\x00008000 +# #endif +# ct_encoding JISX0212.1990-0:GL; JISX0212.1990-0:GR +# } + +END XLC_XLOCALE +.fi +.RE +.LP +.NH 1 +Reference +.XS +\*(SN Reference +.XE +.LP +.XP +[1] \fIISO/IEC 9899:1990 C Language Standard\fP +.XP +[2] \fIX Logical Font Descriptions\fP +.LP diff --git a/libX11/specs/i18n/Makefile.am b/libX11/specs/i18n/Makefile.am new file mode 100644 index 000000000..dff852d11 --- /dev/null +++ b/libX11/specs/i18n/Makefile.am @@ -0,0 +1,33 @@ +# +# Copyright 2009 Sun Microsystems, Inc. All rights reserved. +# +# 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 copyright holders 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 copyright holders. +# + +# Based on xc/doc/specs/i18n/Makefile from X11R6.9 + +doc_sources = Framework.ms LocaleDB.ms Trans.ms + +include $(top_srcdir)/specs/troffrules.in + + diff --git a/libX11/specs/i18n/Makefile.in b/libX11/specs/i18n/Makefile.in new file mode 100644 index 000000000..defb1686d --- /dev/null +++ b/libX11/specs/i18n/Makefile.in @@ -0,0 +1,554 @@ +# Makefile.in generated by automake 1.11 from Makefile.am. +# @configure_input@ + +# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, +# 2003, 2004, 2005, 2006, 2007, 2008, 2009 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 2009 Sun Microsystems, Inc. All rights reserved. +# +# 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 copyright holders 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 copyright holders. +# + +# Based on xc/doc/specs/i18n/Makefile from X11R6.9 + +# +# Copyright 2009 Sun Microsystems, Inc. All rights reserved. +# +# 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 copyright holders 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 copyright holders. +# + +# Based on xc/doc/specs/*/Makefile from X11R6.9 + +VPATH = @srcdir@ +pkgdatadir = $(datadir)/@PACKAGE@ +pkgincludedir = $(includedir)/@PACKAGE@ +pkglibdir = $(libdir)/@PACKAGE@ +pkglibexecdir = $(libexecdir)/@PACKAGE@ +am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd +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@ +DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in \ + $(top_srcdir)/specs/troffrules.in +subdir = specs/i18n +ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 +am__aclocal_m4_deps = $(top_srcdir)/acinclude.m4 \ + $(top_srcdir)/configure.ac +am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ + $(ACLOCAL_M4) +mkinstalldirs = $(install_sh) -d +CONFIG_HEADER = $(top_builddir)/src/config.h \ + $(top_builddir)/include/X11/XlibConf.h +CONFIG_CLEAN_FILES = +CONFIG_CLEAN_VPATH_FILES = +AM_V_GEN = $(am__v_GEN_$(V)) +am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY)) +am__v_GEN_0 = @echo " GEN " $@; +AM_V_at = $(am__v_at_$(V)) +am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY)) +am__v_at_0 = @ +SOURCES = +DIST_SOURCES = +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 = f=`echo $$p | sed -e 's|^.*/||'`; +am__install_max = 40 +am__nobase_strip_setup = \ + srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'` +am__nobase_strip = \ + for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||" +am__nobase_list = $(am__nobase_strip_setup); \ + for p in $$list; do echo "$$p $$p"; done | \ + sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \ + $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \ + if (++n[$$2] == $(am__install_max)) \ + { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \ + END { for (dir in files) print dir, files[dir] }' +am__base_list = \ + sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ + sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' +am__installdirs = "$(DESTDIR)$(docdir)" +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@ +AMTAR = @AMTAR@ +AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ +APP_MAN_DIR = @APP_MAN_DIR@ +APP_MAN_SUFFIX = @APP_MAN_SUFFIX@ +AR = @AR@ +AUTOCONF = @AUTOCONF@ +AUTOHEADER = @AUTOHEADER@ +AUTOMAKE = @AUTOMAKE@ +AWK = @AWK@ +BIGFONT_CFLAGS = @BIGFONT_CFLAGS@ +BIGFONT_LIBS = @BIGFONT_LIBS@ +CC = @CC@ +CCDEPMODE = @CCDEPMODE@ +CC_FOR_BUILD = @CC_FOR_BUILD@ +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@ +DOLT_BASH = @DOLT_BASH@ +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@ +EXEEXT = @EXEEXT@ +F77 = @F77@ +FFLAGS = @FFLAGS@ +FILE_MAN_DIR = @FILE_MAN_DIR@ +FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ +GREP = @GREP@ +GROFF = @GROFF@ +I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ +INSTALL = @INSTALL@ +INSTALL_DATA = @INSTALL_DATA@ +INSTALL_PROGRAM = @INSTALL_PROGRAM@ +INSTALL_SCRIPT = @INSTALL_SCRIPT@ +INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ +KEYSYMDEF = @KEYSYMDEF@ +LAUNCHD = @LAUNCHD@ +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_FLAGS = @LINT_FLAGS@ +LN_S = @LN_S@ +LTCOMPILE = @LTCOMPILE@ +LTCXXCOMPILE = @LTCXXCOMPILE@ +LTLIBOBJS = @LTLIBOBJS@ +MAINT = @MAINT@ +MAKEINFO = @MAKEINFO@ +MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ +MISC_MAN_DIR = @MISC_MAN_DIR@ +MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ +MKDIR_P = @MKDIR_P@ +NMEDIT = @NMEDIT@ +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@ +PERL = @PERL@ +PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ +RANLIB = @RANLIB@ +RAWCPP = @RAWCPP@ +RAWCPPFLAGS = @RAWCPPFLAGS@ +SED = @SED@ +SET_MAKE = @SET_MAKE@ +SHELL = @SHELL@ +STRIP = @STRIP@ +VERSION = @VERSION@ +WCHAR32 = @WCHAR32@ +X11_CFLAGS = @X11_CFLAGS@ +X11_DATADIR = @X11_DATADIR@ +X11_EXTRA_DEPS = @X11_EXTRA_DEPS@ +X11_LIBDIR = @X11_LIBDIR@ +X11_LIBS = @X11_LIBS@ +X11_LOCALEDATADIR = @X11_LOCALEDATADIR@ +X11_LOCALEDIR = @X11_LOCALEDIR@ +X11_LOCALELIBDIR = @X11_LOCALELIBDIR@ +XDMCP_CFLAGS = @XDMCP_CFLAGS@ +XDMCP_LIBS = @XDMCP_LIBS@ +XERRORDB = @XERRORDB@ +XKBPROTO_CFLAGS = @XKBPROTO_CFLAGS@ +XKBPROTO_LIBS = @XKBPROTO_LIBS@ +XKBPROTO_REQUIRES = @XKBPROTO_REQUIRES@ +XKEYSYMDB = @XKEYSYMDB@ +XLOCALEDATADIR = @XLOCALEDATADIR@ +XLOCALEDIR = @XLOCALEDIR@ +XLOCALELIBDIR = @XLOCALELIBDIR@ +XMALLOC_ZERO_CFLAGS = @XMALLOC_ZERO_CFLAGS@ +XPROTO_CFLAGS = @XPROTO_CFLAGS@ +XPROTO_LIBS = @XPROTO_LIBS@ +XTHREADLIB = @XTHREADLIB@ +XTHREAD_CFLAGS = @XTHREAD_CFLAGS@ +XTMALLOC_ZERO_CFLAGS = @XTMALLOC_ZERO_CFLAGS@ +abs_builddir = @abs_builddir@ +abs_srcdir = @abs_srcdir@ +abs_top_builddir = @abs_top_builddir@ +abs_top_srcdir = @abs_top_srcdir@ +ac_ct_CC = @ac_ct_CC@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ +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@ +builddir = @builddir@ +datadir = @datadir@ +datarootdir = @datarootdir@ +distcleancheck_listfiles = @distcleancheck_listfiles@ +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@ +srcdir = @srcdir@ +sysconfdir = @sysconfdir@ +target_alias = @target_alias@ +top_build_prefix = @top_build_prefix@ +top_builddir = @top_builddir@ +top_srcdir = @top_srcdir@ +doc_sources = Framework.ms LocaleDB.ms Trans.ms +EXTRA_DIST = $(doc_sources) +@HAVE_PS2PDF_FALSE@printable_format = .ps +@HAVE_PS2PDF_TRUE@printable_format = .pdf +@BUILD_SPECS_TRUE@doc_DATA = $(doc_sources:.ms=.txt) \ +@BUILD_SPECS_TRUE@ $(doc_sources:.ms=$(printable_format)) \ +@BUILD_SPECS_TRUE@ $(doc_sources:.ms=.html) + +@BUILD_SPECS_TRUE@CLEANFILES = $(doc_DATA) +@BUILD_SPECS_TRUE@MOSTLYCLEANFILES = index.* + +# Pass version string as a troff string for substitution +@BUILD_SPECS_TRUE@GROFF_DEFS = -dxV="$(PACKAGE_STRING)" + +# -e to run through eqn, -t to run through tbl +@BUILD_SPECS_TRUE@GROFF_FLAGS = -e -t -ms $(GROFF_DEFS) $(top_srcdir)/specs/macros.t +@BUILD_SPECS_TRUE@SUFFIXES = .ms .ps .txt .html .pdf +all: all-am + +.SUFFIXES: +.SUFFIXES: .ms .ps .txt .html .pdf +$(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(top_srcdir)/specs/troffrules.in $(am__configure_deps) + @for dep in $?; do \ + case '$(am__configure_deps)' in \ + *$$dep*) \ + ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ + && { if test -f $@; then exit 0; else break; fi; }; \ + exit 1;; \ + esac; \ + done; \ + echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign specs/i18n/Makefile'; \ + $(am__cd) $(top_srcdir) && \ + $(AUTOMAKE) --foreign specs/i18n/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 +$(am__aclocal_m4_deps): + +mostlyclean-libtool: + -rm -f *.lo + +clean-libtool: + -rm -rf .libs _libs +install-docDATA: $(doc_DATA) + @$(NORMAL_INSTALL) + test -z "$(docdir)" || $(MKDIR_P) "$(DESTDIR)$(docdir)" + @list='$(doc_DATA)'; test -n "$(docdir)" || list=; \ + for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + echo "$$d$$p"; \ + done | $(am__base_list) | \ + while read files; do \ + echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(docdir)'"; \ + $(INSTALL_DATA) $$files "$(DESTDIR)$(docdir)" || exit $$?; \ + done + +uninstall-docDATA: + @$(NORMAL_UNINSTALL) + @list='$(doc_DATA)'; test -n "$(docdir)" || list=; \ + files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ + test -n "$$files" || exit 0; \ + echo " ( cd '$(DESTDIR)$(docdir)' && rm -f" $$files ")"; \ + cd "$(DESTDIR)$(docdir)" && rm -f $$files +tags: TAGS +TAGS: + +ctags: CTAGS +CTAGS: + + +distdir: $(DISTFILES) + @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + list='$(DISTFILES)'; \ + dist_files=`for file in $$list; do echo $$file; done | \ + sed -e "s|^$$srcdirstrip/||;t" \ + -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ + case $$dist_files in \ + */*) $(MKDIR_P) `echo "$$dist_files" | \ + sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ + sort -u` ;; \ + esac; \ + for file in $$dist_files; do \ + if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ + if test -d $$d/$$file; then \ + dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ + if test -d "$(distdir)/$$file"; then \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ + cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + cp -fpR $$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)"; 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: + -test -z "$(MOSTLYCLEANFILES)" || rm -f $(MOSTLYCLEANFILES) + +clean-generic: + -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES) + +distclean-generic: + -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) + -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_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 + +dvi: dvi-am + +dvi-am: + +html: html-am + +html-am: + +info: info-am + +info-am: + +install-data-am: install-docDATA + +install-dvi: install-dvi-am + +install-dvi-am: + +install-exec-am: + +install-html: install-html-am + +install-html-am: + +install-info: install-info-am + +install-info-am: + +install-man: + +install-pdf: install-pdf-am + +install-pdf-am: + +install-ps: install-ps-am + +install-ps-am: + +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-docDATA + +.MAKE: install-am install-strip + +.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-docDATA install-dvi \ + install-dvi-am install-exec install-exec-am install-html \ + install-html-am install-info install-info-am install-man \ + install-pdf install-pdf-am install-ps install-ps-am \ + 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-docDATA + + +@BUILD_SPECS_TRUE@.ms.ps: +@BUILD_SPECS_TRUE@ -$(AM_V_GEN) $(GROFF) -Tps $(GROFF_FLAGS) $< 2> index.$@.raw > $@ +@BUILD_SPECS_TRUE@ @if grep '^[^1-9.]' index.$@.raw | grep -v warning; then exit 1; \ +@BUILD_SPECS_TRUE@ else test $$? -le 1; fi + +@BUILD_SPECS_TRUE@.ms.txt: +@BUILD_SPECS_TRUE@ $(AM_V_GEN) env GROFF_NO_SGR=TRUE $(GROFF) -Tutf8 $(GROFF_FLAGS) \ +@BUILD_SPECS_TRUE@ $< 2> index.$@.raw > $@ + +@BUILD_SPECS_TRUE@.ms.html: +@BUILD_SPECS_TRUE@ $(AM_V_GEN) $(GROFF) -Thtml $(GROFF_FLAGS) $< 2> index.$@.raw > $@ + +@BUILD_SPECS_TRUE@.ps.pdf: +@BUILD_SPECS_TRUE@ $(AM_V_GEN) $(PS2PDF) $< $@ + +# 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/libX11/specs/i18n/Trans.ms b/libX11/specs/i18n/Trans.ms new file mode 100644 index 000000000..19c053949 --- /dev/null +++ b/libX11/specs/i18n/Trans.ms @@ -0,0 +1,1148 @@ +.\" $Xorg: Trans.ms,v 1.3 2000/08/17 19:42:49 cpqbld Exp $ +.\" $XdotOrg: xc/doc/specs/i18n/Trans.ms,v 1.2 2004/04/23 18:42:19 eich Exp $ +.\" To print this out, type tbl macros.t This File | troff -ms +.EH '''' +.OH '''' +.EF '''' +.OF '''' +.ps 11 +.nr PS 11 +.\" .nr PD 1v +.\" .nr DD 1v +\& +.sp 8 +.TL +\s+3\fBThe XIM Transport Specification\s-3\fP +.sp +.sp +\fBRevision 0.1\fP +.sp +\fBX Version 11, Release 7\fP +.sp +\fB\*(xV\fP +.sp 3 +.AU +Takashi Fujiwara +.AI +FUJITSU LIMITED +.sp 3 +.AB +.LP +This specification describes the transport layer interfaces between +Xlib and IM Server, which makes various channels usable such as X +protocol or, TCP/IP, DECnet and etc. +.AE +.ce 0 +.br +.LP +.bp +\& +.ps 9 +.nr PS 9 +.sp 8 +.LP +Copyright \(co 1994 by FUJITSU LIMITED +.LP +Permission to use, copy, modify, and distribute this documentation +for any purpose and without fee is hereby granted, provided +that the above copyright notice and this permission +notice appear in all copies. +Fujitsu makes no representations about the suitability +for any purpose of the information in this document. +This documentation is provided as is without express or implied warranty. +.sp 5 +Copyright \(co 1994 X Consortium +.LP +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: +.LP +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. +.LP +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 +X CONSORTIUM 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. +.LP +Except as contained in this notice, the name of the X Consortium 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 X Consortium. +.sp 3 +\fIX Window System\fP is a trademark of The Open Group. +.ps 11 +.nr PS 11 +.bp 1 +.EH '\fBXIM Transport Specification\fP''\fB\*(xV\fP' +.OH '\fBXIM Transport Specification\fP''\fB\*(xV\fP' +.EF ''\fB % \fP'' +.OF ''\fB % \fP'' +.NH 1 +Introduction +.XS +\*(SN Introduction +.XE +.LP +The Xlib XIM implementation is layered into three functions, a protocol +layer, an interface layer and a transport layer. The purpose of this +layering is to make the protocol independent of transport implementation. +Each function of these layers are: +.RS 3 +.IP "\fIThe protocol layer\fP" +.br +implements overall function of XIM and calls the interface layer +functions when it needs to communicate to IM Server. +.IP "\fIThe interface layer\fP" +.br +separates the implementation of the transport layer from the protocol +layer, in other words, it provides implementation independent hook for +the transport layer functions. +.IP "\fIThe transport layer\fP" +.br +handles actual data communication with IM Server. It is done by a set +of several functions named transporters. +.RE +.LP +This specification describes the interface layer and the transport +layer, which makes various communication channels usable such as +X protocol or, TCP/IP, DECnet, STREAM, etc., and provides +the information needed for adding another new transport layer. +In addition, sample implementations for the transporter using the +X connection is described in section 4. +.NH 1 +Initialization +.XS +\*(SN Initialization +.XE +.NH 2 +Registering structure to initialize +.XS +\*(SN Registering structure to initialize +.XE +.LP +The structure typed as TransportSW contains the list of the transport +layer the specific implementations supports. +.LP +.Ds 0 +.TA .5i 2.5i +.ta .5i 2.5i +typedef struct { +.br + char *transport_name; +.br + Bool (*config); +} TransportSW; +.De +.LP +.IP "\fItransport_name\fP" 15 +name of transport(*1) +.FS +(*1) Refer to "The Input Method Protocol: Appendix B" +.FE +.IP "\fIconfig\fP" 15 +initial configuration function +.LP +A sample entry for the Xlib supporting transporters is shown below: +.LP +.Ds 0 +.TA .5i 2.5i +.ta .5i 2.5i +TransportSW _XimTransportRec[] = { +.sp 3p +/* char \fI*: +\ * transport_name\fP, Bool \fI(*config)()\fP +\ */ + ``X'', _XimXConf, + ``tcp'', _XimTransConf, + ``local'', _XimTransConf, + ``decnet'', _XimTransConf, + ``streams'', _XimTransConf, + (char *)NULL, (Bool (*)())NULL, +}; +.De +.LP +.NH 2 +Initialization function +.XS +\*(SN Initialization function +.XE +.LP +The following function will be called once when Xlib configures the +transporter functions. +.sp 6p +.FD 0 +Bool (*config)(\fIim\fP, \fItransport_data\fP) +.br + XIM \fIim\fP; +.br + char \fI*transport_data\fP; +.br +.FN +.IP \fIim\fP 1i +Specifies XIM structure address. +.IP \fItransport_data\fP 1i +Specifies the data specific to the transporter, in IM Server address. (*1) +.FS +(*1) Refer to "The Input Method Protocol: Appendix B" +.FE +.sp 6p +.LP +This function must setup the transporter function pointers. +.LP +The actual \fIconfig\fP function will be chosen by IM Server at the +pre-connection time, matching by the \fItransport_name\fP specified +in the \fB_XimTransportRec\fP array; The specific members of XimProto +structure listed below must be initialized so that point they +appropriate transporter functions. +.LP +If the specified transporter has been configured successfully, this +function returns True. There is no Alternative Entry for config +function itself. +.LP +The structure XimProto contains the following function pointers: +.DS +.TA .5i 2.5i +.ta .5i 2.5i +Bool (*connect)(); /* Open connection */ +Bool (*shutdown)(); /* Close connection */ +Bool (*write)(); /* Write data */ +Bool (*read)(); /* Read data */ +Bool (*flush)(); /* Flush data buffer */ +Bool (*register_dispatcher)(); /* Register asynchronous data handler */ +Bool (*call_dispatcher)(); /* Call dispatcher */ +.DE +These functions are called when Xlib needs to communicate the +IM Server. These functions must process the appropriate procedure +described below. +.LP +.NH 1 +The interface/transport layer functions +.XS +\*(SN The interface/transport layer functions +.XE +.LP +Following functions are used for the transport interface. +.LP +.ce +Table 3-1; The Transport Layer Functions. +.SM +.TS +tab(:) center box; +cw(4c) | cw(4c) | c +c | c | c +l | l | c. +.B +Alternative Entry:XimProto member:Section +(Interface Layer):(Transport Layer):\^ += +.R +\fB_XimConnect\fP:connect:3.1 +_ +\fB_XimShutdown\fP:shutdown:3.2 +_ +\fB_XimWrite\fP:write:3.3 +_ +\fB_XimRead\fP:read:3.4 +_ +\fB_XimFlush\fP:flush:3.5 +_ +\fB_XimRegisterDispatcher\fP:register_dispatcher:3.6 +_ +\fB_XimCallDispatcher\fP:call_dispatcher:3.7 +.TE +.NL +.LP +The Protocol layer calls the above functions using the Alternative +Entry in the left column. The transport implementation defines +XimProto member function in the right column. The Alternative Entry is +provided so as to make easier to implement the Protocol Layer. +.LP +.NH 2 +Opening connection +.XS +\*(SN Opening connection +.XE +.LP +When \fBXOpenIM\fP is called, the following function is called to connect +with the IM Server. +.sp 6p +.FD 0 +Bool (*connect)(\fIim\fP) +.br + XIM \fIim\fP; +.FN +.IP \fIim\fP 1i +Specifies XIM structure address. +.sp 6p +.LP +This function must establishes the connection to the IM Server. If the +connection is established successfully, this function returns True. +The Alternative Entry for this function is: +.sp 6p +.FD 0 +Bool _XimConnect(\fIim\fP) +.br + XIM \fIim\fP; +.FN +.IP \fIim\fP 1i +Specifies XIM structure address. +.LP +.NH 2 +Closing connection +.XS +\*(SN Closing connection +.XE +.LP +When \fBXCloseIM\fP is called, the following function is called to +disconnect the connection with the IM Server. The Alternative Entry +for this function is: +.sp 6p +.FD 0 +Bool (*shutdown)(\fIim\fP) +.br + XIM \fIim\fP; +.FN +.IP \fIim\fP 1i +Specifies XIM structure address. +.sp 6p +.LP +This function must close connection with the IM Server. If the +connection is closed successfully, this function returns True. The +Alternative Entry for this function is: +.sp 6p +.FD 0 +Bool _XimShutdown(\fIim\fP) +.br + XIM \fIim\fP; +.FN +.IP \fIim\fP +Specifies XIM structure address. +.LP +.NH 2 +Writing data +.XS +\*(SN Writing data +.XE +.LP +The following function is called, when Xlib needs to write data to the +IM Server. +.sp 6p +.FD 0 +Bool (*write)(\fIim\fP, \fIlen\fP, \fIdata\fP) +.br + XIM \fIim\fP; +.br + INT16 \fIlen\fP; +.br + XPointer \fIdata\fP; +.FN +.IP \fIim\fP 1i +Specifies XIM structure address. +.IP \fIlen\fP 1i +Specifies the length of writing data. +.IP \fIdata\fP 1i +Specifies the writing data. +.sp 6p +.LP +This function writes the \fIdata\fP to the IM Server, regardless +of the contents. The number of bytes is passed to \fIlen\fP. The +writing data is passed to \fIdata\fP. If data is sent successfully, +the function returns True. Refer to "The Input Method Protocol" for +the contents of the writing data. The Alternative Entry for this +function is: +.sp 6p +.FD 0 +Bool _XimWrite(\fIim\fP, \fIlen\fP, \fIdata\fP) +.br + XIM \fIim\fP; +.br + INT16 \fIlen\fP; +.br + XPointer \fIdata\fP; +.FN +.IP \fIim\fP 1i +Specifies XIM structure address. +.IP \fIlen\fP 1i +Specifies the length of writing data. +.IP \fIdata\fP 1i +Specifies the writing data. +.LP +.NH 2 +Reading data +.XS +\*(SN Reading data +.XE +.LP +The following function is called when Xlib waits for response from IM +server synchronously. +.sp 6p +.FD 0 +Bool (*read)(\fIim\fP, \fIread_buf\fP, \fIbuf_len\fP, \fIret_len\fP) +.br + XIM \fIim\fP; +.br + XPointer \fIread_buf\fP; +.br + int \fIbuf_len\fP; +.br + int \fI*ret_len\fP; +.FN +.IP \fIim\fP 1i +Specifies XIM structure address. +.IP \fIread_buf\fP 1i +Specifies the buffer to store data. +.IP \fIbuf_len\fP 1i +Specifies the size of the \fIbuffer\fP +.IP \fIret_len\fP +Specifies the length of stored data. +.sp 6p +.LP +This function stores the read data in \fIread_buf\fP, which size is +specified as \fIbuf_len\fP. The size of data is set to \fIret_len\fP. +This function return True, if the data is read normally or reading +data is completed. +.LP +The Alternative Entry for this function is: +.sp 6p +.FD 0 +Bool _XimRead(\fIim\fP, \fIret_len\fP, \fIbuf\fP, \fIbuf_len\fP, \fIpredicate\fP, \fIpredicate_arg\fP) +.br + XIM \fIim\fP; +.br + INT16 \fI*ret_len\fP; +.br + XPointer \fIbuf\fP; +.br + int \fIbuf_len\fP; +.br + Bool \fI(*predicate)()\fP; +.br + XPointer \fIpredicate_arg\fP; +.FN +.IP \fIim\fP 1i +Specifies XIM structure address. +.IP \fIret_len\fP 1i +Specifies the size of the \fIdata\fP buffer. +.IP \fIbuf\fP 1i +Specifies the buffer to store data. +.IP \fIbuf_len\fP 1i +Specifies the length of \fIbuffer\fP. +.IP \fIpredicate\fP 1i +Specifies the predicate for the XIM data. +.IP \fIpredicate_arg\fP 1i +Specifies the predicate specific data. +.sp 6p +.LP +The predicate procedure indicates whether the \fIdata\fP is for the +XIM or not. \fIlen\fP +This function stores the read data in \fIbuf\fP, which size is specified +as \fIbuf_len\fP. The size of data is set to \fIret_len\fP. +If \fIpreedicate()\fP returns True, this function returns True. +If not, it calls the registered callback function. +.LP +The procedure and its arguments are: +.LP +.sp 6p +.FD 0 +Bool (*predicate)(\fIim\fP, \fIlen\fP, \fIdata\fP, \fIpredicate_arg\fP) +.br + XIM \fIim\fP; +.br + INT16 \fIlen\fP; +.br + XPointer \fIdata\fP; +.br + XPointer \fIpredicate_arg\fP; +.FN +.IP \fIim\fP 1i +Specifies XIM structure address. +.IP \fIlen\fP 1i +Specifies the size of the \fIdata\fP buffer. +.IP \fIdata\fP 1i +Specifies the buffer to store data. +.IP \fIpredicate_arg\fP 1i +Specifies the predicate specific data. +.LP +.NH 2 +Flushing buffer +.XS +\*(SN Flushing buffer +.XE +.LP +The following function is called when Xlib needs to flush the data. +.sp 6p +.FD 0 +void (*flush)(\fIim\fP) +.br + XIM \fIim\fP; +.FN +.IP \fIim\fP 1i +Specifies XIM structure address. +.sp 6p +.LP +This function must flush the data stored in internal buffer on the +transport layer. If data transfer is completed, the function returns +True. The Alternative Entry for this function is: +.sp 6p +.FD 0 +void _XimFlush(\fIim\fP) +.br + XIM \fIim\fP; +.FN +.IP \fIim\fP 1i +Specifies XIM structure address. +.LP +.NH 2 +Registering asynchronous data handler +.XS +\*(SN Registering asynchronous data handler +.XE +.LP +Xlib needs to handle asynchronous response from IM Server. This is +because some of the XIM data occur asynchronously to X events. +.LP +Those data will be handled in the \fIFilter\fP, and the \fIFilter\fP +will call asynchronous data handler in the protocol layer. Then it +calls dispatchers in the transport layer. The dispatchers are +implemented by the protocol layer. This function must store the +information and prepare for later call of the dispatchers using +\fB_XimCallDispatcher\fP. +.LP +When multiple dispatchers are registered, they will be called +sequentially in order of registration, on arrival of asynchronous +data. The register_dispatcher is declared as following: +.sp 6p +.FD 0 +Bool (*register_dispatcher)(\fIim\fP, \fIdispatcher\fP, \fIcall_data\fP) +.br + XIM \fIim\fP; +.br + Bool \fI(*dispatcher)()\fP; +.br + XPointer \fIcall_data\fP; +.FN +.IP \fIim\fP 1i +Specifies XIM structure address. +.IP \fIdispatcher\fP 1i +Specifies the dispatcher function to register. +.IP \fIcall_data\fP 1i +Specifies a parameter for the \fIdispatcher\fP. +.LP +The dispatcher is a function of the following type: +.sp 6p +.FD 0 +Bool (*dispatcher)(\fIim\fP, \fIlen\fP, \fIdata\fP, \fIcall_data\fP) +.br + XIM \fIim\fP; +.br + INT16 \fIlen\fP; +.br + XPointer \fIdata\fP; +.br + XPointer \fIcall_data\fP; +.FN +.IP \fIim\fP 1i +Specifies XIM structure address. +.IP \fIlen\fP 1i +Specifies the size of the \fIdata\fP buffer. +.IP \fIdata\fP 1i +Specifies the buffer to store data. +.IP \fIcall_data\fP 1i +Specifies a parameter passed to the register_dispatcher. +.sp 6p +.LP +The dispatcher is provided by the protocol layer. They are called once +for every asynchronous data, in order of registration. If the data is +used, it must return True. otherwise, it must return False. +.LP +If the dispatcher function returns True, the Transport Layer assume +that the data has been processed by the upper layer. The Alternative +Entry for this function is: +.sp 6p +.FD 0 +Bool _XimRegisterDispatcher(\fIim\fP, \fIdispatcher\fP, \fIcall_data\fP) +.br + XIM \fIim\fP; +.br + Bool \fI(*dispatcher)()\fP; +.br + XPointer \fIcall_data\fP; +.FN +.IP \fIim\fP 1i +Specifies XIM structure address. +.IP \fIdispatcher\fP 1i +Specifies the dispatcher function to register. +.IP \fIcall_data\fP 1i +Specifies a parameter for the \fIdispatcher\fP. +.LP +.NH 2 +Calling dispatcher +.XS +\*(SN Calling dispatcher +.XE +.LP +The following function is used to call the registered dispatcher +function, when the asynchronous response from IM Server has arrived. +.sp 6p +.FD 0 +Bool (*call_dispatcher)(\fIim\fP, \fIlen\fP, \fIdata\fP) +.br + XIM \fIim\fP; +.br + INT16 \fIlen\fP; +.br + XPointer \fIdata\fP; +.FN +.IP \fIim\fP 1i +Specifies XIM structure address. +.IP \fIlen\fP 1i +Specifies the size of \fIdata\fP buffer. +.IP \fIdata\fP 1i +Specifies the buffer to store data. +.LP +The call_dispatcher must call the dispatcher function, in order of +their registration. \fIlen\fP and \fIdata\fP are the data passed to +register_dispatcher. +.LP +The return values are checked at each invocation, and if it finds +True, it immediately return with true for its return value. +.LP +It is depend on the upper layer whether the read data is XIM +Protocol packet unit or not. +The Alternative Entry for this function is: +.sp 6p +.FD 0 +Bool _XimCallDispatcher(\fIim\fP, \fIlen\fP, \fIdata\fP) +.br + XIM \fIim\fP; +.br + INT16 \fIlen\fP; +.br + XPointer \fIcall_data\fP; +.FN +.LP +.bp +.NH 1 +Sample implementations for the Transport Layer +.XS +\*(SN Sample implementations for the Transport Layer +.XE +.LP +Sample implementations for the transporter using the X connection is +described here. +.LP +.NH 2 +X Transport +.XS +\*(SN X Transport +.XE +.LP +At the beginning of the X Transport connection for the XIM transport +mechanism, two different windows must be created either in an Xlib XIM +or in an IM Server, with which the Xlib and the IM Server exchange the +XIM transports by using the ClientMessage events and Window Properties. +In the following, the window created by the Xlib is referred as the +"client communication window", and on the other hand, the window created +by the IM Server is referred as the "IMS communication window". +.LP +.NH 3 +Connection +.XS +\*(SN X Connection +.XE +.LP +In order to establish a connection, a communication window is created. +A ClientMessage in the following event's format is sent to the owner +window of XIM_SERVER selection, which the IM Server has created. +.LP +Refer to "The Input Method Protocol" for the XIM_SERVER atom. +.LP +.ce +Table 4-1; The ClientMessage sent to the IMS window. +.TS H +tab(:); +l s|l +l l|l. +_ +.sp 6p +.B +Structure Member:Contents +.sp 6p +_ +.sp 6p +.TH +.R +int:type:ClientMessage +u_long:serial:Set by the X Window System +Bool:send_event:Set by the X Window System +Display:*display:The display to which connects +Window:window:IMS Window ID +Atom:message_type:XInternAtom(display, ``_XIM_XCONNECT'', False) +int:format:32 +long:data.l[0]:client communication window ID +long:data.l[1]:client-major-transport-version (*1) +long:data.l[2]:client-major-transport-version (*1) +.sp 6p +_ +.TE +.LP +In order to establish the connection (to notify the IM Server communication +window), the IM Server sends a ClientMessage in the following event's +format to the client communication window. +.LP +.ce +Table 4-2; The ClientMessage sent by IM Server. +.TS H +tab(:); +l s | l +l l | l. +_ +.sp 6p +.B +Structure Member:Contents +.sp 6p +_ +.sp 6p +.TH +.R +int:type:ClientMessage +u_long:serial:Set by the X Window System +Bool:send_event:Set by the X Window System +Display:*display:The display to which connects +Window:window:client communication window ID +Atom:message_type:XInternAtom(display, ``_XIM_XCONNECT'', False) +int:format:32 +long:data.l[0]:IMS communication window ID +long:data.l[1]:server-major-transport-version (*1) +long:data.l[2]:server-minor-transport-version (*1) +long:data.l[3]:dividing size between ClientMessage and Property (*2) +.sp 6p +_ +.TE +.LP +.IP (*1) +major/minor-transport-version +.RS +The read/write method is decided by the combination of +major/minor-transport-version, as follows: +.LP +.ce +Table 4-3; The read/write method and the major/minor-transport-version +.TS +center, tab(:); +| c s | l | +| c | c | l |. +_ +.sp 6p +.B +Transport-version:read/write +.sp 6p +_ +.sp 6p +major:minor: +.sp 6p +_ +.sp 6p +.R +0:0:only-CM & Property-with-CM +:1:only-CM & multi-CM +:2:only-CM & multi-CM & Property-with-CM +.sp 6p +_ +.sp 6p +1:0:PropertyNotify +.sp 6p +_ +.sp 6p +2:0:only-CM & PropertyNotify +:1:only-CM & multi-CM & PropertyNotify +.sp 6p +_ +.TE +.LP +.RS +.TS +center, tab(;); +l n l. +only-CM;:;data is sent via a ClientMessage +multi-CM;:;data is sent via multiple ClientMessages +Property-with-CM;:;T{ +data is written in Property, and its Atom is send via ClientMessage +T} +PropertyNotify;:;T{ +data is written in Property, and its Atom is send via PropertyNotify +T} +.TE +.RE +.LP +The method to decide major/minor-transport-version is as follows: +.LP +.IP (1) +The client sends 0 as major/minor-transport-version to the IM Server. +The client must support all methods in Table 4-3. +The client may send another number as major/minor-transport-version to +use other method than the above in the future. +.IP (2) +The IM Server sends its major/minor-transport-version number to +the client. The client sends data using the method specified by the +IM Server. +.IP (3) +If major/minor-transport-version number is not available, it is regarded +as 0. +.RE +.LP +.IP (*2) +dividing size between ClientMessage and Property +.RS +If data is sent via both of multi-CM and Property, specify the dividing +size between ClientMessage and Property. The data, which is smaller than +this size, is sent via multi-CM (or only-CM), and the data, which is +lager than this size, is sent via Property. +.RE +.LP +.NH 3 +read/write +.XS +\*(SN read/write +.XE +.LP +The data is transferred via either ClientMessage or Window Property in +the X Window System. +.LP +.NH 4 +Format for the data from the Client to the IM Server +.XS +\*(SN Format for the data from the Client to the IM Server +.XE +.LP +.B +ClientMessage +.LP +.RS +If data is sent via ClientMessage event, the format is as follows: +.LP +.ce +Table 4-4; The ClientMessage event's format (first or middle) +.TS H +tab(;); +l s | l +l l | l. +_ +.sp 6p +.B +Structure Member;Contents +.sp 6p +_ +.sp 6p +.TH +.R +int;type;ClientMessage +u_long;serial;Set by the X Window System +Bool;send_event;Set by the X Window System +Display;*display;The display to which connects +Window;window;IMS communication window ID +Atom;message_type;XInternAtom(display, ``_XIM_MOREDATA'', False) +int;format;8 +char;data.b[20];(read/write DATA : 20 byte) +.sp 6p +_ +.TE +.LP +.ce +Table 4-5; The ClientMessage event's format (only or last) +.TS H +tab(;); +l s | l +l l | l. +_ +.sp 6p +.B +Structure Member;Contents +.sp 6p +_ +.sp 6p +.TH +.R +int;type;ClientMessage +u_long;serial;Set by the X Window System +Bool;send_event;Set by the X Window System +Display;*display;The display to which connects +Window;window;IMS communication window ID +Atom;message_type;XInternAtom(display, ``_XIM_PROTOCOL'', False) +int;format;8 +char;data.b[20];(read/write DATA : MAX 20 byte) (*1) +.sp 6p +_ +.TE +.IP (*1) +If the data is smaller than 20 byte, all data other than available data +must be 0. +.RE +.LP +.B +Property +.LP +.RS +In the case of large data, data will be sent via the Window Property +for the efficiency. There are the following two methods to notify +Property, and transport-version is decided which method is used. +.LP +.IP (1) +The XChangeProperty function is used to store data in the client +communication window, and Atom of the stored data is notified to the +IM Server via ClientMessage event. +.IP (2) +The XChangeProperty function is used to store data in the client +communication window, and Atom of the stored data is notified to the +IM Server via PropertyNotify event. +.LP +The arguments of the XChangeProperty are as follows: +.LP +.ce +Table 4-6; The XChangeProperty event's format +.TS H +tab(:); +l s | l +l l | l. +_ +.sp 6p +.B +Argument:Contents +.sp 6p +_ +.sp 6p +.TH +.R +Display:*display:The display to which connects +Window:window:IMS communication window ID +Atom:property:read/write property Atom (*1) +Atom:type:XA_STRING +int:format:8 +int:mode:PropModeAppend +u_char:*data:read/write DATA +int:nelements:length of DATA +.sp 6p +_ +.TE +.LP +.IP (*1) +The read/write property ATOM allocates the following strings by +\fBXInternAtom\fP. +.RS +``_clientXXX'' +.RE +.LP +The client changes the property with the mode of PropModeAppend and +the IM Server will read it with the delete mode i.e. (delete = True). +.LP +If Atom is notified via ClientMessage event, the format of the ClientMessage +is as follows: +.LP +.ce +Table 4-7; The ClientMessage event's format to send Atom of property +.TS H +tab(:); +l s | l +l l | l. +_ +.sp 6p +.B +Structure Member:Contents +.sp 6p +_ +.sp 6p +.TH +.R +int:type:ClientMessage +u_long:serial:Set by the X Window System +Bool:send_event:Set by the X Window System +Display:*display:The display to which connects +Window:window:IMS communication window ID +Atom:message_type:XInternAtom(display, ``_XIM_PROTOCOL'', False) +int:format:32 +long:data.l[0]:length of read/write property Atom +long:data.l[1]:read/write property Atom +.sp 6p +_ +.TE +.RE +.LP +.NH 4 +Format for the data from the IM Server to the Client +.XS +\*(SN Format for the data from the Client to the Client +.XE +.LP +.B +ClientMessage +.LP +.RS +The format of the ClientMessage is as follows: +.LP +.ce +Table 4-8; The ClientMessage event's format (first or middle) +.TS H +tab(;); +l s | l +l l | l. +_ +.sp 6p +.B +Structure Member;Contents +.sp 6p +_ +.sp 6p +.TH +.R +int;type;ClientMessage +u_long;serial;Set by the X Window System +Bool;send_event ;Set by the X Window System +Display;*display;The display to which connects +Window;window;client communication window ID +Atom;message_type;XInternAtom(display, ``_XIM_MOREDATA'', False) +int;format;8 +char;data.b[20];(read/write DATA : 20 byte) +.sp 6p +_ +.TE +.LP +.ce +Table 4-9; The ClientMessage event's format (only or last) +.TS H +tab(;); +l s | l +l l | l. +_ +.sp 6p +.B +Structure Member;Contents +.sp 6p +_ +.sp 6p +.TH +.R +int;type;ClientMessage +u_long;serial;Set by the X Window System +Bool;send_event ;Set by the X Window System +Display;*display;The display to which connects +Window;window;client communication window ID +Atom;message_type;XInternAtom(display, ``_XIM_PROTOCOL'', False) +int;format;8 +char;data.b[20];(read/write DATA : MAX 20 byte) (*1) +.sp 6p +_ +.TE +.LP +.IP (*1) +If the data size is smaller than 20 bytes, all data other than available +data must be 0. +.RE +.LP +.B +Property +.LP +.RS +In the case of large data, data will be sent via the Window Property +for the efficiency. There are the following two methods to notify +Property, and transport-version is decided which method is used. +.LP +.IP (1) +The XChangeProperty function is used to store data in the IMS +communication window, and Atom of the property is sent via the +ClientMessage event. +.IP (2) +The XChangeProperty function is used to store data in the IMS +communication window, and Atom of the property is sent via +PropertyNotify event. +.LP +The arguments of the XChangeProperty are as follows: +.LP +.ce +Table 4-10; The XChangeProperty event's format +.TS H +tab(:); +l s | l +l l | l. +_ +.sp 6p +.B +Argument:Contents +.sp 6p +_ +.sp 6p +.TH +.R +Display:*display:The display which to connects +Window:window:client communication window ID +Atom:property:read/write property Atom (*1) +Atom:type:XA_STRING +int:format:8 +int:mode:PropModeAppend +u_char:*data:read/write DATA +int:nelements:length of DATA +.sp 6p +_ +.TE +.LP +.IP (*1) +The read/write property ATOM allocates some strings, which are not +allocated by the client, by \fBXInternAtom\fP. +.LP +The IM Server changes the property with the mode of PropModeAppend and +the client reads it with the delete mode, i.e. (delete = True). +.LP +If Atom is notified via ClientMessage event, the format of the ClientMessage +is as follows: +.LP +.ce +Table 4-11; The ClientMessage event's format to send Atom of property +.TS H +tab(:); +l s | l +l l | l. +_ +.sp 6p +.B +Structure Member:Contents +.sp 6p +_ +.sp 6p +.TH +.R +int:type:ClientMessage +u_long:serial:Set by the X Window System +Bool:send_event:Set by the X Window System +Display:*display:The display to which connects +Window:window:client communication window ID +Atom:message_type:XInternAtom(display, ``_XIM_PROTOCOL'', False) +int:format:32 +long:data.l[0]:length of read/write property ATOM +long:data.l[1]:read/write property ATOM +.sp 6p +_ +.TE +.RE +.LP +.NH 3 +Closing Connection +.XS +\*(SN Closing Connection +.XE +.LP +If the client disconnect with the IM Server, shutdown function should +free the communication window properties and etc.. +.LP +.NH 1 +References +.XS +\*(SN References +.XE +.LP +[1] Masahiko Narita and Hideki Hiura, \fI``The Input Method Protocol''\fP +.LP + diff --git a/libX11/specs/libX11/AppA b/libX11/specs/libX11/AppA new file mode 100644 index 000000000..26a1ba32f --- /dev/null +++ b/libX11/specs/libX11/AppA @@ -0,0 +1,604 @@ +.\" Copyright \(co 1985, 1986, 1987, 1988, 1989, 1990, 1991, 1994, 1996 X Consortium +.\" +.\" 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 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 X CONSORTIUM 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 X Consortium 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 X Consortium. +.\" +.\" Copyright \(co 1985, 1986, 1987, 1988, 1989, 1990, 1991 by +.\" Digital Equipment Corporation +.\" +.\" Portions Copyright \(co 1990, 1991 by +.\" Tektronix, Inc. +.\" +.\" Permission to use, copy, modify and distribute this documentation for +.\" any purpose and without fee is hereby granted, provided that the above +.\" copyright notice appears in all copies and that both that copyright notice +.\" and this permission notice appear in all copies, and that the names of +.\" Digital and Tektronix not be used in in advertising or publicity pertaining +.\" to this documentation without specific, written prior permission. +.\" Digital and Tektronix makes no representations about the suitability +.\" of this documentation for any purpose. +.\" It is provided ``as is'' without express or implied warranty. +.\" +\& +.sp 1 +.ce 3 +\s+1\fBAppendix A\fP\s-1 + +\s+1\fBXlib Functions and Protocol Requests\fP\s-1 +.sp 2 +.na +.LP +.XS +Appendix A: Xlib Functions and Protocol Requests +.XE +This appendix provides two tables that relate to Xlib functions +and the X protocol. +The following table lists each Xlib function (in alphabetical order) +and the corresponding protocol request that it generates. +.LP +.TS H +lw(2.5i) lw(2.5i). +_ +.sp 6p +.B +Xlib Function Protocol Request +.sp 6p +_ +.sp 6p +.TH +.R +XActivateScreenSaver ForceScreenSaver +XAddHost ChangeHosts +XAddHosts ChangeHosts +XAddToSaveSet ChangeSaveSet +XAllocColor AllocColor +XAllocColorCells AllocColorCells +XAllocColorPlanes AllocColorPlanes +XAllocNamedColor AllocNamedColor +XAllowEvents AllowEvents +XAutoRepeatOff ChangeKeyboardControl +XAutoRepeatOn ChangeKeyboardControl +XBell Bell +XChangeActivePointerGrab ChangeActivePointerGrab +XChangeGC ChangeGC +XChangeKeyboardControl ChangeKeyboardControl +XChangeKeyboardMapping ChangeKeyboardMapping +XChangePointerControl ChangePointerControl +XChangeProperty ChangeProperty +XChangeSaveSet ChangeSaveSet +XChangeWindowAttributes ChangeWindowAttributes +XCirculateSubwindows CirculateWindow +XCirculateSubwindowsDown CirculateWindow +XCirculateSubwindowsUp CirculateWindow +XClearArea ClearArea +XClearWindow ClearArea +XConfigureWindow ConfigureWindow +XConvertSelection ConvertSelection +XCopyArea CopyArea +XCopyColormapAndFree CopyColormapAndFree +XCopyGC CopyGC +XCopyPlane CopyPlane +XCreateBitmapFromData CreateGC + CreatePixmap + FreeGC + PutImage +XCreateColormap CreateColormap +XCreateFontCursor CreateGlyphCursor +XCreateGC CreateGC +XCreateGlyphCursor CreateGlyphCursor +XCreatePixmap CreatePixmap +XCreatePixmapCursor CreateCursor +XCreatePixmapFromData CreateGC + CreatePixmap + FreeGC + PutImage +XCreateSimpleWindow CreateWindow +XCreateWindow CreateWindow +XDefineCursor ChangeWindowAttributes +XDeleteProperty DeleteProperty +XDestroySubwindows DestroySubwindows +XDestroyWindow DestroyWindow +XDisableAccessControl SetAccessControl +XDrawArc PolyArc +XDrawArcs PolyArc +XDrawImageString ImageText8 +XDrawImageString16 ImageText16 +XDrawLine PolySegment +XDrawLines PolyLine +XDrawPoint PolyPoint +XDrawPoints PolyPoint +XDrawRectangle PolyRectangle +XDrawRectangles PolyRectangle +XDrawSegments PolySegment +XDrawString PolyText8 +XDrawString16 PolyText16 +XDrawText PolyText8 +XDrawText16 PolyText16 +XEnableAccessControl SetAccessControl +XFetchBytes GetProperty +XFetchName GetProperty +XFillArc PolyFillArc +XFillArcs PolyFillArc +XFillPolygon FillPoly +XFillRectangle PolyFillRectangle +XFillRectangles PolyFillRectangle +XForceScreenSaver ForceScreenSaver +XFreeColormap FreeColormap +XFreeColors FreeColors +XFreeCursor FreeCursor +XFreeFont CloseFont +XFreeGC FreeGC +XFreePixmap FreePixmap +XGetAtomName GetAtomName +XGetClassHint GetProperty +XGetFontPath GetFontPath +XGetGeometry GetGeometry +XGetIconName GetProperty +XGetIconSizes GetProperty +XGetImage GetImage +XGetInputFocus GetInputFocus +XGetKeyboardControl GetKeyboardControl +XGetKeyboardMapping GetKeyboardMapping +XGetModifierMapping GetModifierMapping +XGetMotionEvents GetMotionEvents +XGetNormalHints GetProperty +XGetPointerControl GetPointerControl +XGetPointerMapping GetPointerMapping +XGetRGBColormaps GetProperty +XGetScreenSaver GetScreenSaver +XGetSelectionOwner GetSelectionOwner +XGetSizeHints GetProperty +XGetTextProperty GetProperty +XGetTransientForHint GetProperty +XGetWMClientMachine GetProperty +XGetWMColormapWindows GetProperty + InternAtom +XGetWMHints GetProperty +XGetWMIconName GetProperty +XGetWMName GetProperty +XGetWMNormalHints GetProperty +XGetWMProtocols GetProperty + InternAtom +XGetWMSizeHints GetProperty +XGetWindowAttributes GetWindowAttributes + GetGeometry +XGetWindowProperty GetProperty +XGetZoomHints GetProperty +XGrabButton GrabButton +XGrabKey GrabKey +XGrabKeyboard GrabKeyboard +XGrabPointer GrabPointer +XGrabServer GrabServer +XIconifyWindow InternAtom + SendEvent +XInitExtension QueryExtension +XInstallColormap InstallColormap +XInternAtom InternAtom +XKillClient KillClient +XListExtensions ListExtensions +XListFonts ListFonts +XListFontsWithInfo ListFontsWithInfo +XListHosts ListHosts +XListInstalledColormaps ListInstalledColormaps +XListProperties ListProperties +XLoadFont OpenFont +XLoadQueryFont OpenFont + QueryFont +XLookupColor LookupColor +XLowerWindow ConfigureWindow +XMapRaised ConfigureWindow + MapWindow +XMapSubwindows MapSubwindows +XMapWindow MapWindow +XMoveResizeWindow ConfigureWindow +XMoveWindow ConfigureWindow +XNoOp NoOperation +XOpenDisplay CreateGC +XParseColor LookupColor +XPutImage PutImage +XQueryBestCursor QueryBestSize +XQueryBestSize QueryBestSize +XQueryBestStipple QueryBestSize +XQueryBestTile QueryBestSize +XQueryColor QueryColors +XQueryColors QueryColors +XQueryExtension QueryExtension +XQueryFont QueryFont +XQueryKeymap QueryKeymap +XQueryPointer QueryPointer +XQueryTextExtents QueryTextExtents +XQueryTextExtents16 QueryTextExtents +XQueryTree QueryTree +XRaiseWindow ConfigureWindow +XReadBitmapFile CreateGC + CreatePixmap + FreeGC + PutImage +XRecolorCursor RecolorCursor +XReconfigureWMWindow ConfigureWindow + SendEvent +XRemoveFromSaveSet ChangeSaveSet +XRemoveHost ChangeHosts +XRemoveHosts ChangeHosts +XReparentWindow ReparentWindow +XResetScreenSaver ForceScreenSaver +XResizeWindow ConfigureWindow +XRestackWindows ConfigureWindow +XRotateBuffers RotateProperties +XRotateWindowProperties RotateProperties +XSelectInput ChangeWindowAttributes +XSendEvent SendEvent +XSetAccessControl SetAccessControl +XSetArcMode ChangeGC +XSetBackground ChangeGC +XSetClassHint ChangeProperty +XSetClipMask ChangeGC +XSetClipOrigin ChangeGC +XSetClipRectangles SetClipRectangles +XSetCloseDownMode SetCloseDownMode +XSetCommand ChangeProperty +XSetDashes SetDashes +XSetFillRule ChangeGC +XSetFillStyle ChangeGC +XSetFont ChangeGC +XSetFontPath SetFontPath +XSetForeground ChangeGC +XSetFunction ChangeGC +XSetGraphicsExposures ChangeGC +XSetIconName ChangeProperty +XSetIconSizes ChangeProperty +XSetInputFocus SetInputFocus +XSetLineAttributes ChangeGC +XSetModifierMapping SetModifierMapping +XSetNormalHints ChangeProperty +XSetPlaneMask ChangeGC +XSetPointerMapping SetPointerMapping +XSetRGBColormaps ChangeProperty +XSetScreenSaver SetScreenSaver +XSetSelectionOwner SetSelectionOwner +XSetSizeHints ChangeProperty +XSetStandardProperties ChangeProperty +XSetState ChangeGC +XSetStipple ChangeGC +XSetSubwindowMode ChangeGC +XSetTextProperty ChangeProperty +XSetTile ChangeGC +XSetTransientForHint ChangeProperty +XSetTSOrigin ChangeGC +XSetWMClientMachine ChangeProperty +XSetWMColormapWindows ChangeProperty + InternAtom +XSetWMHints ChangeProperty +XSetWMIconName ChangeProperty +XSetWMName ChangeProperty +XSetWMNormalHints ChangeProperty +XSetWMProperties ChangeProperty +XSetWMProtocols ChangeProperty + InternAtom +XSetWMSizeHints ChangeProperty +XSetWindowBackground ChangeWindowAttributes +XSetWindowBackgroundPixmap ChangeWindowAttributes +XSetWindowBorder ChangeWindowAttributes +XSetWindowBorderPixmap ChangeWindowAttributes +XSetWindowBorderWidth ConfigureWindow +XSetWindowColormap ChangeWindowAttributes +XSetZoomHints ChangeProperty +XStoreBuffer ChangeProperty +XStoreBytes ChangeProperty +XStoreColor StoreColors +XStoreColors StoreColors +XStoreName ChangeProperty +XStoreNamedColor StoreNamedColor +XSync GetInputFocus +XSynchronize GetInputFocus +XTranslateCoordinates TranslateCoordinates +XUndefineCursor ChangeWindowAttributes +XUngrabButton UngrabButton +XUngrabKey UngrabKey +XUngrabKeyboard UngrabKeyboard +XUngrabPointer UngrabPointer +XUngrabServer UngrabServer +XUninstallColormap UninstallColormap +XUnloadFont CloseFont +XUnmapSubwindows UnmapSubwindows +XUnmapWindow UnmapWindow +XWarpPointer WarpPointer +XWithdrawWindow SendEvent + UnmapWindow +.TE +.bp +.LP +The following table lists each X protocol request (in alphabetical +order) and the Xlib functions that reference it. +.TS H +lw(2.5i) lw(2.5i). +_ +.sp 6p +.B +Protocol Request Xlib Function +.sp 6p +_ +.sp 6p +.TH +.R +AllocColor XAllocColor +AllocColorCells XAllocColorCells +AllocColorPlanes XAllocColorPlanes +AllocNamedColor XAllocNamedColor +AllowEvents XAllowEvents +Bell XBell +ChangeActivePointerGrab XChangeActivePointerGrab +ChangeGC XChangeGC + XSetArcMode + XSetBackground + XSetClipMask + XSetClipOrigin + XSetFillRule + XSetFillStyle + XSetFont + XSetForeground + XSetFunction + XSetGraphicsExposures + XSetLineAttributes + XSetPlaneMask + XSetState + XSetStipple + XSetSubwindowMode + XSetTile + XSetTSOrigin +ChangeHosts XAddHost + XAddHosts + XRemoveHost + XRemoveHosts +ChangeKeyboardControl XAutoRepeatOff + XAutoRepeatOn + XChangeKeyboardControl +ChangeKeyboardMapping XChangeKeyboardMapping +ChangePointerControl XChangePointerControl +ChangeProperty XChangeProperty + XSetClassHint + XSetCommand + XSetIconName + XSetIconSizes + XSetNormalHints + XSetRGBColormaps + XSetSizeHints + XSetStandardProperties + XSetTextProperty + XSetTransientForHint + XSetWMClientMachine + XSetWMColormapWindows + XSetWMHints + XSetWMIconName + XSetWMName + XSetWMNormalHints + XSetWMProperties + XSetWMProtocols + XSetWMSizeHints + XSetZoomHints + XStoreBuffer + XStoreBytes + XStoreName +ChangeSaveSet XAddToSaveSet + XChangeSaveSet + XRemoveFromSaveSet +ChangeWindowAttributes XChangeWindowAttributes + XDefineCursor + XSelectInput + XSetWindowBackground + XSetWindowBackgroundPixmap + XSetWindowBorder + XSetWindowBorderPixmap + XSetWindowColormap + XUndefineCursor +CirculateWindow XCirculateSubwindowsDown + XCirculateSubwindowsUp + XCirculateSubwindows +ClearArea XClearArea + XClearWindow +CloseFont XFreeFont + XUnloadFont +ConfigureWindow XConfigureWindow + XLowerWindow + XMapRaised + XMoveResizeWindow + XMoveWindow + XRaiseWindow + XReconfigureWMWindow + XResizeWindow + XRestackWindows + XSetWindowBorderWidth +ConvertSelection XConvertSelection +CopyArea XCopyArea +CopyColormapAndFree XCopyColormapAndFree +CopyGC XCopyGC +CopyPlane XCopyPlane +CreateColormap XCreateColormap +CreateCursor XCreatePixmapCursor +CreateGC XCreateGC + XCreateBitmapFromData + XCreatePixmapFromData + XOpenDisplay + XReadBitmapFile +CreateGlyphCursor XCreateFontCursor + XCreateGlyphCursor +CreatePixmap XCreatePixmap + XCreateBitmapFromData + XCreatePixmapFromData + XReadBitmapFile +CreateWindow XCreateSimpleWindow + XCreateWindow +DeleteProperty XDeleteProperty +DestroySubwindows XDestroySubwindows +DestroyWindow XDestroyWindow +FillPoly XFillPolygon +ForceScreenSaver XActivateScreenSaver + XForceScreenSaver + XResetScreenSaver +FreeColormap XFreeColormap +FreeColors XFreeColors +FreeCursor XFreeCursor +FreeGC XFreeGC + XCreateBitmapFromData + XCreatePixmapFromData + XReadBitmapFile +FreePixmap XFreePixmap +GetAtomName XGetAtomName +GetFontPath XGetFontPath +GetGeometry XGetGeometry + XGetWindowAttributes +GetImage XGetImage +GetInputFocus XGetInputFocus + XSync + XSynchronize +GetKeyboardControl XGetKeyboardControl +GetKeyboardMapping XGetKeyboardMapping +GetModifierMapping XGetModifierMapping +GetMotionEvents XGetMotionEvents +GetPointerControl XGetPointerControl +GetPointerMapping XGetPointerMapping +GetProperty XFetchBytes + XFetchName + XGetClassHint + XGetIconName + XGetIconSizes + XGetNormalHints + XGetRGBColormaps + XGetSizeHints + XGetTextProperty + XGetTransientForHint + XGetWMClientMachine + XGetWMColormapWindows + XGetWMHints + XGetWMIconName + XGetWMName + XGetWMNormalHints + XGetWMProtocols + XGetWMSizeHints + XGetWindowProperty + XGetZoomHints +GetSelectionOwner XGetSelectionOwner +GetWindowAttributes XGetWindowAttributes +GrabButton XGrabButton +GrabKey XGrabKey +GrabKeyboard XGrabKeyboard +GrabPointer XGrabPointer +GrabServer XGrabServer +ImageText8 XDrawImageString +ImageText16 XDrawImageString16 +InstallColormap XInstallColormap +InternAtom XGetWMColormapWindows + XGetWMProtocols + XIconifyWindow + XInternAtom + XSetWMColormapWindows + XSetWMProtocols +KillClient XKillClient +ListExtensions XListExtensions +ListFonts XListFonts +ListFontsWithInfo XListFontsWithInfo +ListHosts XListHosts +ListInstalledColormaps XListInstalledColormaps +ListProperties XListProperties +LookupColor XLookupColor + XParseColor +MapSubwindows XMapSubwindows +MapWindow XMapRaised + XMapWindow +NoOperation XNoOp +OpenFont XLoadFont + XLoadQueryFont +PolyArc XDrawArc + XDrawArcs +PolyFillArc XFillArc + XFillArcs +PolyFillRectangle XFillRectangle + XFillRectangles +PolyLine XDrawLines +PolyPoint XDrawPoint + XDrawPoints +PolyRectangle XDrawRectangle + XDrawRectangles +PolySegment XDrawLine + XDrawSegments +PolyText8 XDrawString + XDrawText +PolyText16 XDrawString16 + XDrawText16 +PutImage XPutImage + XCreateBitmapFromData + XCreatePixmapFromData + XReadBitmapFile +QueryBestSize XQueryBestCursor + XQueryBestSize + XQueryBestStipple + XQueryBestTile +QueryColors XQueryColor + XQueryColors +QueryExtension XInitExtension + XQueryExtension +QueryFont XLoadQueryFont + XQueryFont +QueryKeymap XQueryKeymap +QueryPointer XQueryPointer +QueryTextExtents XQueryTextExtents + XQueryTextExtents16 +QueryTree XQueryTree +RecolorCursor XRecolorCursor +ReparentWindow XReparentWindow +RotateProperties XRotateBuffers + XRotateWindowProperties +SendEvent XIconifyWindow + XReconfigureWMWindow + XSendEvent + XWithdrawWindow +SetAccessControl XDisableAccessControl + XEnableAccessControl + XSetAccessControl +SetClipRectangles XSetClipRectangles +SetCloseDownMode XSetCloseDownMode +SetDashes XSetDashes +SetFontPath XSetFontPath +SetInputFocus XSetInputFocus +SetModifierMapping XSetModifierMapping +SetPointerMapping XSetPointerMapping +SetScreenSaver XGetScreenSaver + XSetScreenSaver +SetSelectionOwner XSetSelectionOwner +StoreColors XStoreColor + XStoreColors +StoreNamedColor XStoreNamedColor +TranslateCoordinates XTranslateCoordinates +UngrabButton XUngrabButton +UngrabKey XUngrabKey +UngrabKeyboard XUngrabKeyboard +UngrabPointer XUngrabPointer +UngrabServer XUngrabServer +UninstallColormap XUninstallColormap +UnmapSubwindows XUnmapSubWindows +UnmapWindow XUnmapWindow + XWithdrawWindow +WarpPointer XWarpPointer +.TE +.bp diff --git a/libX11/specs/libX11/AppB b/libX11/specs/libX11/AppB new file mode 100644 index 000000000..2e57ede86 --- /dev/null +++ b/libX11/specs/libX11/AppB @@ -0,0 +1,101 @@ +.\" Copyright \(co 1985, 1986, 1987, 1988, 1989, 1990, 1991, 1994, 1996 X Consortium +.\" +.\" 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 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 X CONSORTIUM 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 X Consortium 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 X Consortium. +.\" +.\" Copyright \(co 1985, 1986, 1987, 1988, 1989, 1990, 1991 by +.\" Digital Equipment Corporation +.\" +.\" Portions Copyright \(co 1990, 1991 by +.\" Tektronix, Inc. +.\" +.\" Permission to use, copy, modify and distribute this documentation for +.\" any purpose and without fee is hereby granted, provided that the above +.\" copyright notice appears in all copies and that both that copyright notice +.\" and this permission notice appear in all copies, and that the names of +.\" Digital and Tektronix not be used in in advertising or publicity pertaining +.\" to this documentation without specific, written prior permission. +.\" Digital and Tektronix makes no representations about the suitability +.\" of this documentation for any purpose. +.\" It is provided ``as is'' without express or implied warranty. +.\" +\& +.sp 1 +.ce 3 +\s+1\fBAppendix B\fP\s-1 + +\s+1\fBX Font Cursors\fP\s-1 +.sp 2 +.na +.LP +.XS +Appendix B: X Font Cursors +.XE +The following are the available cursors that can be used with +.PN XCreateFontCursor . +.LP +.Ds 0 +.TA 3i +.ta 3i +#define XC_X_cursor 0 #define XC_ll_angle 76 +#define XC_arrow 2 #define XC_lr_angle 78 +#define XC_based_arrow_down 4 #define XC_man 80 +#define XC_based_arrow_up 6 #define XC_middlebutton 82 +#define XC_boat 8 #define XC_mouse 84 +#define XC_bogosity 10 #define XC_pencil 86 +#define XC_bottom_left_corner 12 #define XC_pirate 88 +#define XC_bottom_right_corner 14 #define XC_plus 90 +#define XC_bottom_side 16 #define XC_question_arrow 92 +#define XC_bottom_tee 18 #define XC_right_ptr 94 +#define XC_box_spiral 20 #define XC_right_side 96 +#define XC_center_ptr 22 #define XC_right_tee 98 +#define XC_circle 24 #define XC_rightbutton 100 +#define XC_clock 26 #define XC_rtl_logo 102 +#define XC_coffee_mug 28 #define XC_sailboat 104 +#define XC_cross 30 #define XC_sb_down_arrow 106 +#define XC_cross_reverse 32 #define XC_sb_h_double_arrow 108 +#define XC_crosshair 34 #define XC_sb_left_arrow 110 +#define XC_diamond_cross 36 #define XC_sb_right_arrow 112 +#define XC_dot 38 #define XC_sb_up_arrow 114 +#define XC_dot_box_mask 40 #define XC_sb_v_double_arrow 116 +#define XC_double_arrow 42 #define XC_shuttle 118 +#define XC_draft_large 44 #define XC_sizing 120 +#define XC_draft_small 46 #define XC_spider 122 +#define XC_draped_box 48 #define XC_spraycan 124 +#define XC_exchange 50 #define XC_star 126 +#define XC_fleur 52 #define XC_target 128 +#define XC_gobbler 54 #define XC_tcross 130 +#define XC_gumby 56 #define XC_top_left_arrow 132 +#define XC_hand1 58 #define XC_top_left_corner 134 +#define XC_hand2 60 #define XC_top_right_corner 136 +#define XC_heart 62 #define XC_top_side 138 +#define XC_icon 64 #define XC_top_tee 140 +#define XC_iron_cross 66 #define XC_trek 142 +#define XC_left_ptr 68 #define XC_ul_angle 144 +#define XC_left_side 70 #define XC_umbrella 146 +#define XC_left_tee 72 #define XC_ur_angle 148 +#define XC_leftbutton 74 #define XC_watch 150 + #define XC_xterm 152 +.De +.bp diff --git a/libX11/specs/libX11/AppC b/libX11/specs/libX11/AppC new file mode 100644 index 000000000..43261ba83 --- /dev/null +++ b/libX11/specs/libX11/AppC @@ -0,0 +1,2230 @@ +.\" Copyright \(co 1985, 1986, 1987, 1988, 1989, 1990, 1991, 1994, 1996 X Consortium +.\" +.\" 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 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 X CONSORTIUM 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 X Consortium 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 X Consortium. +.\" +.\" Copyright \(co 1985, 1986, 1987, 1988, 1989, 1990, 1991 by +.\" Digital Equipment Corporation +.\" +.\" Portions Copyright \(co 1990, 1991 by +.\" Tektronix, Inc. +.\" +.\" Permission to use, copy, modify and distribute this documentation for +.\" any purpose and without fee is hereby granted, provided that the above +.\" copyright notice appears in all copies and that both that copyright notice +.\" and this permission notice appear in all copies, and that the names of +.\" Digital and Tektronix not be used in in advertising or publicity pertaining +.\" to this documentation without specific, written prior permission. +.\" Digital and Tektronix makes no representations about the suitability +.\" of this documentation for any purpose. +.\" It is provided ``as is'' without express or implied warranty. +.\" +\& +.sp 1 +.ce 3 +\s+1\fBAppendix C\fP\s-1 + +\s+1\fBExtensions\fP\s-1 +.sp 2 +.na +.LP +.XS +Appendix C: Extensions +.XE +Because X can evolve by extensions to the core protocol, +it is important that extensions not be perceived as second-class citizens. +At some point, +your favorite extensions may be adopted as additional parts of the +X Standard. +.LP +Therefore, there should be little to distinguish the use of an extension from +that of the core protocol. +To avoid having to initialize extensions explicitly in application programs, +it is also important that extensions perform lazy evaluations, +automatically initializing themselves when called for the first time. +.LP +This appendix describes techniques for writing extensions to Xlib that will +run at essentially the same performance as the core protocol requests. +.NT +It is expected that a given extension to X consists of multiple +requests. +Defining 10 new features as 10 separate extensions is a bad practice. +Rather, they should be packaged into a single extension +and should use minor opcodes to distinguish the requests. +.NE +.LP +The symbols and macros used for writing stubs to Xlib are listed in +.hN X11/Xlibint.h . +.SH +Basic Protocol Support Routines +.LP +The basic protocol requests for extensions are +.PN XQueryExtension +and +.PN XListExtensions . +.IN "XQueryExtension" "" "@DEF@" +.sM +.FD 0 +Bool XQueryExtension(\^\fIdisplay\fP, \fIname\fP, \fImajor_opcode_return\fP, \ +\fIfirst_event_return\fP, \fIfirst_error_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + char *\fIname;\fP\^ +.br + int *\fImajor_opcode_return\fP\^; +.br + int *\fIfirst_event_return\fP\^; +.br + int *\fIfirst_error_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIname\fP 1i +Specifies the extension name. +.IP \fImajor_opcode_return\fP 1i +Returns the major opcode. +.IP \fIfirst_event_return\fP 1i +Returns the first event code, if any. +.IP \fIfirst_error_return\fP 1i +Returns the first error code, if any. +.LP +.eM +The +.PN XQueryExtension +function determines if the named extension is present. +If the extension is not present, +.PN XQueryExtension +returns +.PN False ; +otherwise, it returns +.PN True . +If the extension is present, +.PN XQueryExtension +returns the major opcode for the extension to major_opcode_return; +otherwise, +it returns zero. +Any minor opcode and the request formats are specific to the +extension. +If the extension involves additional event types, +.PN XQueryExtension +returns the base event type code to first_event_return; +otherwise, +it returns zero. +The format of the events is specific to the extension. +If the extension involves additional error codes, +.PN XQueryExtension +returns the base error code to first_error_return; +otherwise, +it returns zero. +The format of additional data in the errors is specific to the extension. +.LP +If the extension name is not in the Host Portable Character Encoding +the result is implementation-dependent. +Uppercase and lowercase matter; +the strings ``thing'', ``Thing'', and ``thinG'' +are all considered different names. +.IN "XListExtensions" "" "@DEF@" +.sM +.FD 0 +char **XListExtensions(\^\fIdisplay\fP, \fInextensions_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + int *\fInextensions_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fInextensions_return\fP 1i +Returns the number of extensions listed. +.LP +.eM +The +.PN XListExtensions +function returns a list of all extensions supported by the server. +If the data returned by the server is in the Latin Portable Character Encoding, +then the returned strings are in the Host Portable Character Encoding. +Otherwise, the result is implementation-dependent. +.IN "XFreeExtensionList" "" "@DEF@" +.sM +.FD 0 +XFreeExtensionList(\^\fIlist\fP\^) +.br + char **\fIlist\fP\^; +.FN +.IP \fIlist\fP 1i +Specifies the list of extension names. +.LP +.eM +The +.PN XFreeExtensionList +function frees the memory allocated by +.PN XListExtensions . +.SH +Hooking into Xlib +.LP +These functions allow you to hook into the library. +They are not normally used by application programmers but are used +by people who need to extend the core X protocol and +the X library interface. +The functions, which generate protocol requests for X, are typically +called stubs. +.LP +In extensions, stubs first should check to see if they have initialized +themselves on a connection. +If they have not, they then should call +.PN XInitExtension +to attempt to initialize themselves on the connection. +.LP +If the extension needs to be informed of GC/font allocation or +deallocation or if the extension defines new event types, +the functions described here allow the extension to be +called when these events occur. +.LP +The +.PN XExtCodes +structure returns the information from +.PN XInitExtension +and is defined in +.hN X11/Xlib.h : +.LP +.IN "XExtCodes" "" "@DEF@" +.sM +.Ds 0 +.TA .5i 3i +.ta .5i 3i +typedef struct _XExtCodes { /* public to extension, cannot be changed */ + int extension; /* extension number */ + int major_opcode; /* major op-code assigned by server */ + int first_event; /* first event number for the extension */ + int first_error; /* first error number for the extension */ +} XExtCodes; +.De +.LP +.eM +.IN "XInitExtension" "" "@DEF@" +.sM +.FD 0 +XExtCodes *XInitExtension(\^\fIdisplay\fP, \fIname\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + char *\fIname\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIname\fP 1i +Specifies the extension name. +.LP +.eM +The +.PN XInitExtension +function determines if the named extension exists. +Then, it allocates storage for maintaining the +information about the extension on the connection, +chains this onto the extension list for the connection, +and returns the information the stub implementor will need to access +the extension. +If the extension does not exist, +.PN XInitExtension +returns NULL. +.LP +If the extension name is not in the Host Portable Character Encoding, +the result is implementation-dependent. +Uppercase and lowercase matter; +the strings ``thing'', ``Thing'', and ``thinG'' +are all considered different names. +.LP +The extension number in the +.PN XExtCodes +structure is +needed in the other calls that follow. +This extension number is unique only to a single connection. +.LP +.IN "XAddExtension" "" "@DEF@" +.sM +.FD 0 +XExtCodes *XAddExtension\^(\^\fIdisplay\fP\^) +.br + Display *\fIdisplay\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.LP +.eM +For local Xlib extensions, the +.PN XAddExtension +function allocates the +.PN XExtCodes +structure, bumps the extension number count, +and chains the extension onto the extension list. +(This permits extensions to Xlib without requiring server extensions.) +.SH +Hooks into the Library +.LP +These functions allow you to define procedures that are to be +called when various circumstances occur. +The procedures include the creation of a new GC for a connection, +the copying of a GC, the freeing of a GC, the creating and freeing of fonts, +the conversion of events defined by extensions to and from wire +format, and the handling of errors. +.LP +All of these functions return the previous procedure defined for this +extension. +.IN "XESetCloseDisplay" "" "@DEF@" +.sM +.FD 0 +int (*XESetCloseDisplay(\^\fIdisplay\fP, \fIextension\fP, \fIproc\fP\^))(\^) +.br + Display *\fIdisplay\fP\^; +.br + int \fIextension\fP\^; +.br + int (\^*\fIproc\fP\^)(\^); +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIextension\fP 1i +Specifies the extension number. +.IP \fIproc\fP 1i +Specifies the procedure to call when the display is closed. +.LP +.eM +The +.PN XESetCloseDisplay +function defines a procedure to be called whenever +.PN XCloseDisplay +is called. +It returns any previously defined procedure, usually NULL. +.LP +When +.PN XCloseDisplay +is called, +your procedure is called +with these arguments: +.LP +.sM +.Ds 0 +.TA .5i 3i +.ta .5i 3i +.R +(*\fIproc\fP\^)(\^\fIdisplay\fP, \fIcodes\fP\^) + Display *\fIdisplay\fP\^; + XExtCodes *\fIcodes\fP\^; +.De +.LP +.eM +.IN "XESetCreateGC" "" "@DEF@" +.sM +.FD 0 +int (*XESetCreateGC(\^\fIdisplay\fP, \fIextension\fP, \fIproc\fP\^))(\^) +.br + Display *\fIdisplay\fP\^; +.br + int \fIextension\fP\^; +.br + int (\^*\fIproc\fP\^)(\^); +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIextension\fP 1i +Specifies the extension number. +.IP \fIproc\fP 1i +Specifies the procedure to call when a GC is closed. +.LP +.eM +The +.PN XESetCreateGC +function defines a procedure to be called whenever +a new GC is created. +It returns any previously defined procedure, usually NULL. +.LP +When a GC is created, +your procedure is called with these arguments: +.LP +.sM +.Ds 0 +.TA .5i 3i +.ta .5i 3i +.R +(*\fIproc\fP\^)(\^\fIdisplay\fP, \fIgc\fP, \fIcodes\fP\^) + Display *\fIdisplay\fP\^; + GC \fIgc\fP\^; + XExtCodes *\fIcodes\fP\^; +.De +.LP +.eM +.IN "XESetCopyGC" "" "@DEF@" +.sM +.FD 0 +int (*XESetCopyGC(\^\fIdisplay\fP, \fIextension\fP, \fIproc\fP\^))(\^) +.br + Display *\fIdisplay\fP\^; +.br + int \fIextension\fP\^; +.br + int (\^*\fIproc\fP\^)(\^); +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIextension\fP 1i +Specifies the extension number. +.IP \fIproc\fP 1i +Specifies the procedure to call when GC components are copied. +.LP +.eM +The +.PN XESetCopyGC +function defines a procedure to be called whenever +a GC is copied. +It returns any previously defined procedure, usually NULL. +.LP +When a GC is copied, +your procedure is called with these arguments: +.LP +.sM +.Ds 0 +.TA .5i 3i +.ta .5i 3i +.R +(*\fIproc\fP\^)(\^\fIdisplay\fP, \fIgc\fP, \fIcodes\fP\^) + Display *\fIdisplay\fP\^; + GC \fIgc\fP\^; + XExtCodes *\fIcodes\fP\^; +.De +.LP +.eM +.IN "XESetFreeGC" "" "@DEF@" +.sM +.FD 0 +int (*XESetFreeGC(\^\fIdisplay\fP, \fIextension\fP, \fIproc)\fP\^)(\^) +.br + Display *\fIdisplay\fP\^; +.br + int \fIextension\fP\^; +.br + int (\^*\fIproc\fP\^)(\^); +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIextension\fP 1i +Specifies the extension number. +.IP \fIproc\fP 1i +Specifies the procedure to call when a GC is freed. +.LP +.eM +The +.PN XESetFreeGC +function defines a procedure to be called whenever +a GC is freed. +It returns any previously defined procedure, usually NULL. +.LP +When a GC is freed, +your procedure is called with these arguments: +.LP +.sM +.Ds 0 +.TA .5i 3i +.ta .5i 3i +.R +(*\fIproc\fP\^)(\^\fIdisplay\fP, \fIgc\fP, \fIcodes\fP\^) + Display *\fIdisplay\fP\^; + GC \fIgc\fP\^; + XExtCodes *\fIcodes\fP\^; +.De +.LP +.eM +.IN "XESetCreateFont" "" "@DEF@" +.sM +.FD 0 +int (*XESetCreateFont(\^\fIdisplay\fP, \fIextension\fP, \fIproc\fP))(\^) +.br + Display *\fIdisplay\fP\^; +.br + int \fIextension\fP\^; +.br + int (\^*\fIproc\fP\^)(\^); +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIextension\fP 1i +Specifies the extension number. +.IP \fIproc\fP 1i +Specifies the procedure to call when a font is created. +.LP +.eM +The +.PN XESetCreateFont +function defines a procedure to be called whenever +.PN XLoadQueryFont +and +.PN XQueryFont +are called. +It returns any previously defined procedure, usually NULL. +.LP +When +.PN XLoadQueryFont +or +.PN XQueryFont +is called, +your procedure is called with these arguments: +.LP +.sM +.Ds 0 +.TA .5i 3i +.ta .5i 3i +.R +(*\fIproc\fP\^)(\^\fIdisplay\fP, \fIfs\fP, \fIcodes\fP\^) + Display *\fIdisplay\fP\^; + XFontStruct *\fIfs\fP\^; + XExtCodes *\fIcodes\fP\^; +.De +.LP +.eM +.IN "XESetFreeFont" "" "@DEF@" +.sM +.FD 0 +int (*XESetFreeFont(\^\fIdisplay\fP, \fIextension\fP, \fIproc\fP\^))(\^) +.br + Display *\fIdisplay\fP\^; +.br + int \fIextension\fP\^; +.br + int (\^*\fIproc\fP)(\^); +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIextension\fP 1i +Specifies the extension number. +.IP \fIproc\fP 1i +Specifies the procedure to call when a font is freed. +.LP +.eM +The +.PN XESetFreeFont +function defines a procedure to be called whenever +.PN XFreeFont +is called. +It returns any previously defined procedure, usually NULL. +.LP +When +.PN XFreeFont +is called, your procedure is called with these arguments: +.LP +.sM +.Ds 0 +.TA .5i 3i +.ta .5i 3i +.R +(*\fIproc\fP\^)(\^\fIdisplay\fP, \fIfs\fP, \fIcodes\fP\^) + Display *\fIdisplay\fP\^; + XFontStruct *\fIfs\fP\^; + XExtCodes *\fIcodes\fP\^; +.De +.LP +.eM +The +.PN XESetWireToEvent +and +.PN XESetEventToWire +functions allow you to define new events to the library. +An +.PN XEvent +structure always has a type code (type +.PN int ) +as the first component. +This uniquely identifies what kind of event it is. +The second component is always the serial number (type +.PN unsigned +.PN long ) +of the last request processed by the server. +The third component is always a Boolean (type +.PN Bool ) +indicating whether the event came from a +.PN SendEvent +protocol request. +The fourth component is always a pointer to the display +the event was read from. +The fifth component is always a resource ID of one kind or another, +usually a window, carefully selected to be useful to toolkit dispatchers. +The fifth component should always exist, even if +the event does not have a natural destination; +if there is no value +from the protocol to put in this component, initialize it to zero. +.NT +There is an implementation limit such that your host event +structure size cannot be bigger than the size of the +.PN XEvent +union of structures. +There also is no way to guarantee that more than 24 elements or 96 characters +in the structure will be fully portable between machines. +.NE +.IN "XESetWireToEvent" "" "@DEF@" +.sM +.FD 0 +int (*XESetWireToEvent(\^\fIdisplay\fP, \fIevent_number\fP, \fIproc\fP\^))(\^) +.br + Display *\fIdisplay\fP\^; +.br + int \fIevent_number\fP\^; +.br + Status (\^*\fIproc\fP\^)(\^); +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIevent_number\fP 1i +Specifies the event code. +.IP \fIproc\fP 1i +Specifies the procedure to call when converting an event. +.LP +.eM +The +.PN XESetWireToEvent +function defines a procedure to be called when an event +needs to be converted from wire format +.Pn ( xEvent ) +to host format +.Pn ( XEvent ). +The event number defines which protocol event number to install a +conversion procedure for. +.PN XESetWireToEvent +returns any previously defined procedure. +.NT +You can replace a core event conversion function with one +of your own, although this is not encouraged. +It would, however, allow you to intercept a core event +and modify it before being placed in the queue or otherwise examined. +.NE +When Xlib needs to convert an event from wire format to host +format, your procedure is called with these arguments: +.LP +.sM +.Ds 0 +.TA .5i 3i +.ta .5i 3i +.R +Status (*\fIproc\fP\^)(\^\fIdisplay\fP, \fIre\fP, \fIevent\fP\^) + Display *\fIdisplay\fP\^; + XEvent *\fIre\fP\^; + xEvent *\fIevent\fP\^; +.De +.LP +.eM +Your procedure must return status to indicate if the conversion succeeded. +The re argument is a pointer to where the host format event should be stored, +and the event argument is the 32-byte wire event structure. +In the +.PN XEvent +structure you are creating, +you must fill in the five required members of the event structure. +You should fill in the type member with the type specified for the +.PN xEvent +structure. +You should copy all other members from the +.PN xEvent +structure (wire format) to the +.PN XEvent +structure (host format). +Your conversion procedure should return +.PN True +if the event should be placed in the queue or +.PN False +if it should not be placed in the queue. +.LP +To initialize the serial number component of the event, call +.PN _XSetLastRequestRead +with the event and use the return value. +.LP +.IN "_XSetLastRequestRead" "" "@DEF@" +.sM +.FD 0 +unsigned long _XSetLastRequestRead(\^\fIdisplay\fP, \fIrep\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + xGenericReply *\fIrep\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIrep\fP 1i +Specifies the wire event structure. +.LP +.eM +The +.PN _XSetLastRequestRead +function computes and returns a complete serial number from the partial +serial number in the event. +.sp +.LP +.IN "XESetEventToWire" "" "@DEF@" +.sM +.FD 0 +Status (*XESetEventToWire(\^\fIdisplay\fP, \fIevent_number\fP, \fIproc\fP\^))(\^) +.br + Display *\fIdisplay\fP\^; +.br + int \fIevent_number\fP\^; +.br + int (\^*\fIproc\fP\^)(\^); +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIevent_number\fP 1i +Specifies the event code. +.IP \fIproc\fP 1i +Specifies the procedure to call when converting an event. +.LP +.eM +The +.PN XESetEventToWire +function defines a procedure to be called when an event +needs to be converted from host format +.Pn ( XEvent ) +to wire format +.Pn ( xEvent ) +form. +The event number defines which protocol event number to install a +conversion procedure for. +.PN XESetEventToWire +returns any previously defined procedure. +It returns zero if the conversion fails or nonzero otherwise. +.NT +You can replace a core event conversion function with one +of your own, although this is not encouraged. +It would, however, allow you to intercept a core event +and modify it before being sent to another client. +.NE +When Xlib needs to convert an event from host format to wire format, +your procedure is called with these arguments: +.LP +.sM +.Ds 0 +.TA .5i 3i +.ta .5i 3i +.R +(*\fIproc\fP\^)(\^\fIdisplay\fP, \fIre\fP, \fIevent\fP\^) + Display *\fIdisplay\fP\^; + XEvent *\fIre\fP\^; + xEvent *\fIevent\fP\^; +.De +.LP +.eM +The re argument is a pointer to the host format event, +and the event argument is a pointer to where the 32-byte wire event +structure should be stored. +You should fill in the type with the type from the +.PN XEvent +structure. +All other members then should be copied from the host format to the +.PN xEvent +structure. +.IN "XESetWireToError" "" "@DEF@" +.sM +.FD 0 +Bool (*XESetWireToError(\^\fIdisplay\fP, \fIerror_number\fP, \fIproc\fP\^)(\^) +.br + Display *\fIdisplay\fP\^; +.br + int \fIerror_number\fP\^; +.br + Bool (\^*\fIproc\fP\^)(\^); +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIerror_number\fP 1i +Specifies the error code. +.IP \fIproc\fP 1i +Specifies the procedure to call when an error is received. +.LP +.eM +The +.PN XESetWireToError +function defines a procedure to be called when an extension +error needs to be converted from wire format to host format. +The error number defines which protocol error code to install +the conversion procedure for. +.PN XESetWireToError +returns any previously defined procedure. +.LP +Use this function for extension errors that contain additional error values +beyond those in a core X error, when multiple wire errors must be combined +into a single Xlib error, or when it is necessary to intercept an +X error before it is otherwise examined. +.LP +When Xlib needs to convert an error from wire format to host format, +the procedure is called with these arguments: +.LP +.sM +.Ds 0 +.TA .5i 3i +.ta .5i 3i +.R +Bool (*\fIproc\fP\^)(\^\fIdisplay\fP, \fIhe\fP, \fIwe\fP\^) + Display *\fIdisplay\fP\^; + XErrorEvent *\fIhe\fP\^; + xError *\fIwe\fP\^; +.De +.LP +.eM +The he argument is a pointer to where the host format error should be stored. +The structure pointed at by he is guaranteed to be as large as an +.PN XEvent +structure and so can be cast to a type larger than an +.PN XErrorEvent +to store additional values. +If the error is to be completely ignored by Xlib +(for example, several protocol error structures will be combined into +one Xlib error), +then the function should return +.PN False ; +otherwise, it should return +.PN True . +.IN "XESetError" "" "@DEF@" +.sM +.FD 0 +int (*XESetError(\^\fIdisplay\fP, \fIextension\fP, \fIproc\fP\^))(\^) +.br + Display *\fIdisplay\fP\^; +.br + int \fIextension\fP\^; +.br + int (\^*\fIproc\fP\^)(\^); +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIextension\fP 1i +Specifies the extension number. +.IP \fIproc\fP 1i +Specifies the procedure to call when an error is received. +.LP +.eM +Inside Xlib, there are times that you may want to suppress the +calling of the external error handling when an error occurs. +This allows status to be returned on a call at the cost of the call +being synchronous (though most such functions are query operations, in any +case, and are typically programmed to be synchronous). +.LP +When Xlib detects a protocol error in +.PN _XReply , +it calls your procedure with these arguments: +.LP +.sM +.Ds 0 +.TA .5i 3i +.ta .5i 3i +.R +int (*\fIproc\fP\^)(\fIdisplay\fP, \fIerr\fP, \fIcodes\fP, \fIret_code\fP\^) + Display *\fIdisplay\fP\^; + xError *\fIerr\fP\^; + XExtCodes *\fIcodes\fP\^; + int *\fIret_code\fP\^; +.De +.LP +.eM +The err argument is a pointer to the 32-byte wire format error. +The codes argument is a pointer to the extension codes structure. +The ret_code argument is the return code you may want +.PN _XReply +returned to. +.LP +If your procedure returns a zero value, +the error is not suppressed, and +the client's error handler is called. +(For further information, see section 11.8.2.) +If your procedure returns nonzero, +the error is suppressed, and +.PN _XReply +returns the value of ret_code. +.IN "XESetErrorString" "" "@DEF@" +.sM +.FD 0 +char *(*XESetErrorString(\^\fIdisplay\fP, \fIextension\fP, \fIproc\fP\^))(\^) +.br + Display *\fIdisplay\fP\^; +.br + int \fIextension\fP\^; +.br + char *(\^*\fIproc\fP\^)(\^); +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIextension\fP 1i +Specifies the extension number. +.IP \fIproc\fP 1i +Specifies the procedure to call to obtain an error string. +.LP +.eM +The +.PN XGetErrorText +function returns a string to the user for an error. +.PN XESetErrorString +allows you to define a procedure to be called that +should return a pointer to the error message. +The following is an example. +.LP +.sM +.Ds 0 +.TA .5i 3i +.ta .5i 3i +.R +(*\fIproc\fP\^)(\^\fIdisplay\fP, \fIcode\fP, \fIcodes\fP, \fIbuffer\fP, \fInbytes\fP\^) + Display *\fIdisplay\fP\^; + int \fIcode\fP\^; + XExtCodes *\fIcodes\fP\^; + char *\fIbuffer\fP\^; + int \fInbytes\fP\^; +.De +.LP +.eM +Your procedure is called with the error code for every error detected. +You should copy nbytes of a null-terminated string containing the +error message into buffer. +.IN "XESetPrintErrorValues" "" "@DEF@" +.sM +.FD 0 +void (*XESetPrintErrorValues(\^\fIdisplay\fP, \fIextension\fP, \fIproc\fP\^))(\^) +.br + Display *\fIdisplay\fP\^; +.br + int \fIextension\fP\^; +.br + void (\^*\fIproc\fP\^)(\^); +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIextension\fP 1i +Specifies the extension number. +.IP \fIproc\fP 1i +Specifies the procedure to call when an error is printed. +.LP +.eM +The +.PN XESetPrintErrorValues +function defines a procedure to be called when an extension +error is printed, to print the error values. +Use this function for extension errors that contain additional error values +beyond those in a core X error. +It returns any previously defined procedure. +.LP +When Xlib needs to print an error, +the procedure is called with these arguments: +.LP +.sM +.Ds 0 +.TA .5i 3i +.ta .5i 3i +.R +void (*\fIproc\fP\^)(\^\fIdisplay\fP, \fIev\fP, \fIfp\fP\^) + Display *\fIdisplay\fP\^; + XErrorEvent *\fIev\fP\^; + void *\fIfp\fP\^; +.De +.LP +.eM +The structure pointed at by ev is guaranteed to be as large as an +.PN XEvent +structure and so can be cast to a type larger than an +.PN XErrorEvent +to obtain additional values set by using +.PN XESetWireToError . +The underlying type of the fp argument is system dependent; +on a POSIX-compliant system, fp should be cast to type FILE*. +.IN "XESetFlushGC" "" "@DEF@" +.sM +.FD 0 +int (*XESetFlushGC(\^\fIdisplay\fP, \fIextension\fP, \fIproc\fP\^))(\^) +.br + Display *\fIdisplay\fP\^; +.br + int \fIextension\fP\^; +.br + int *(\^*\fIproc\fP\^)(\^); +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIextension\fP 1i +Specifies the extension number. +.IP \fIproc\fP 1i +Specifies the procedure to call when a GC is flushed. +.LP +.eM +The procedure set by the +.PN XESetFlushGC +function has the same interface as the procedure set by the +.PN XESetCopyGC +function, but is called when a GC cache needs to be updated in the server. +.IN "XESetBeforeFlush" "" "@DEF@" +.sM +.FD 0 +int (*XESetBeforeFlush(\^\fIdisplay\fP, \fIextension\fP, \fIproc\fP\^))(\^) +.br + Display *\fIdisplay\fP\^; +.br + int \fIextension\fP\^; +.br + int *(\^*\fIproc\fP\^)(\^); +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIextension\fP 1i +Specifies the extension number. +.IP \fIproc\fP 1i +Specifies the procedure to call when a buffer is flushed. +.LP +.eM +The +.PN XESetBeforeFlush +function defines a procedure to be called when data is about to be +sent to the server. When data is about to be sent, your procedure is +called one or more times with these arguments: +.LP +.sM +.Ds 0 +.TA .5i 3i +.ta .5i 3i +.R +void (*\fIproc\fP\^)(\^\fIdisplay\fP, \fIcodes\fP, \fIdata\fP, \fIlen\fP\^) + Display *\fIdisplay\fP\^; + XExtCodes *\fIcodes\fP\^; + char *\fIdata\fP\^; + long \fIlen\fP\^; +.De +.LP +.eM +The data argument specifies a portion of the outgoing data buffer, +and its length in bytes is specified by the len argument. +Your procedure must not alter the contents of the data and must not +do additional protocol requests to the same display. +.SH +Hooks onto Xlib Data Structures +.LP +Various Xlib data structures have provisions for extension procedures +to chain extension supplied data onto a list. +These structures are +.PN GC , +.PN Visual , +.PN Screen , +.PN ScreenFormat , +.PN Display , +and +.PN XFontStruct . +Because the list pointer is always the first member in the structure, +a single set of procedures can be used to manipulate the data +on these lists. +.LP +The following structure is used in the functions in this section +and is defined in +.hN X11/Xlib.h : +.LP +.IN "XExtData" "" "@DEF@" +.sM +.Ds 0 +.TA .5i 3i +.ta .5i 3i +typedef struct _XExtData { + int number; /* number returned by XInitExtension */ + struct _XExtData *next; /* next item on list of data for structure */ + int (*free_private)(); /* if defined, called to free private */ + XPointer private_data; /* data private to this extension. */ +} XExtData; +.De +.LP +.eM +When any of the data structures listed above are freed, +the list is walked, and the structure's free procedure (if any) is called. +If free is NULL, +then the library frees both the data pointed to by the private_data member +and the structure itself. +.LP +.sM +.Ds 0 +.TA .5i +.ta .5i +union { Display *display; + GC gc; + Visual *visual; + Screen *screen; + ScreenFormat *pixmap_format; + XFontStruct *font } XEDataObject; +.De +.LP +.eM +.IN "XEHeadOfExtensionList" "" "@DEF@" +.sM +.FD 0 +XExtData **XEHeadOfExtensionList(\^\fIobject\fP\^) + XEDataObject \fIobject\fP\^; +.FN +.IP \fIobject\fP 1i +Specifies the object. +.LP +.eM +The +.PN XEHeadOfExtensionList +function returns a pointer to the list of extension structures attached +to the specified object. +In concert with +.PN XAddToExtensionList , +.PN XEHeadOfExtensionList +allows an extension to attach arbitrary data to any of the structures +of types contained in +.PN XEDataObject . +.LP +.IN "XAddToExtensionList" "" "@DEF@" +.sM +.FD 0 +XAddToExtensionList(\^\fIstructure\fP, \fIext_data\fP\^) +.br + XExtData **\fIstructure\fP\^; +.br + XExtData *\fIext_data\fP\^; +.FN +.IP \fIstructure\fP 1i +Specifies the extension list. +.IP \fIext_data\fP 1i +Specifies the extension data structure to add. +.LP +.eM +The structure argument is a pointer to one of the data structures +enumerated above. +You must initialize ext_data->number with the extension number +before calling this function. +.IN "XFindOnExtensionList" "" "@DEF@" +.sM +.FD 0 +XExtData *XFindOnExtensionList(\^\fIstructure\fP, \fInumber\fP\^) +.br + struct _XExtData **\fIstructure\fP\^; +.br + int \fInumber\fP\^; +.FN +.IP \fIstructure\fP 1i +Specifies the extension list. +.IP \fInumber\fP 1i +Specifies the extension number from +.PN XInitExtension . +.LP +.eM +The +.PN XFindOnExtensionList +function returns the first extension data structure +for the extension numbered number. +It is expected that an extension will add at most one extension +data structure to any single data structure's extension data list. +There is no way to find additional structures. +.LP +The +.PN XAllocID +macro, which allocates and returns a resource ID, is defined in +.hN X11/Xlib.h . +.IN "XAllocID" "" "@DEF@" +.sM +.FD 0 +XAllocID\^(\fIdisplay\fP\^) +.br + Display *\fIdisplay\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.LP +.eM +This macro is a call through the +.PN Display +structure to an internal resource ID allocator. +It returns a resource ID that you can use when creating new resources. +.LP +The +.PN XAllocIDs +macro allocates and returns an array of resource ID. +.IN "XAllocIDs" "" "@DEF@" +.sM +.FD 0 +XAllocIDs\^(\fIdisplay\fP, \fIids_return\fP, \fIcount\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + XID *\fIids_return\fP\^; +.br + int \fIcount\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIids_return\fP 1i +Returns the resource IDs. +.IP \fIrep\fP 1i +Specifies the number of resource IDs requested. +.LP +.eM +This macro is a call through the +.PN Display +structure to an internal resource ID allocator. +It returns resource IDs to the array supplied by the caller. +To correctly handle automatic reuse of resource IDs, you must call +.PN XAllocIDs +when requesting multiple resource IDs. This call might generate +protocol requests. +.SH +GC Caching +.LP +GCs are cached by the library to allow merging of independent change +requests to the same GC into single protocol requests. +This is typically called a write-back cache. +Any extension procedure whose behavior depends on the contents of a GC +must flush the GC cache to make sure the server has up-to-date contents +in its GC. +.LP +The +.PN FlushGC +macro checks the dirty bits in the library's GC structure and calls +.PN _XFlushGCCache +if any elements have changed. +The +.PN FlushGC +macro is defined as follows: +.IN "FlushGC" "" "@DEF@" +.sM +.FD 0 +FlushGC\^(\^\fIdisplay\fP\^, \fIgc\fP\^) +.br + Display *\^\fIdisplay\fP\^; +.br + GC \fIgc\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIgc\fP 1i +Specifies the GC. +.LP +.eM +Note that if you extend the GC to add additional resource ID components, +you should ensure that the library stub sends the change request immediately. +This is because a client can free a resource immediately after +using it, so if you only stored the value in the cache without +forcing a protocol request, the resource might be destroyed before being +set into the GC. +You can use the +.PN _XFlushGCCache +procedure +to force the cache to be flushed. +The +.PN _XFlushGCCache +procedure +is defined as follows: +.IN "_XFlushGCCache" "" "@DEF@" +.sM +.FD 0 +_XFlushGCCache\^(\^\fIdisplay\fP\^, \fIgc\fP\^) +.br + Display *\^\fIdisplay\fP\^; +.br + GC \fIgc\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIgc\fP 1i +Specifies the GC. +.LP +.eM +.SH +Graphics Batching +.LP +If you extend X to add more poly graphics primitives, you may be able to +take advantage of facilities in the library to allow back-to-back +single calls to be transformed into poly requests. +This may dramatically improve performance of programs that are not +written using poly requests. +A pointer to an +.PN xReq , +called last_req in the display structure, is the last request being processed. +By checking that the last request +type, drawable, gc, and other options are the same as the new one +and that there is enough space left in the buffer, you may be able +to just extend the previous graphics request by extending the length +field of the request and appending the data to the buffer. +This can improve performance by five times or more in naive programs. +For example, here is the source for the +.PN XDrawPoint +stub. +(Writing extension stubs is discussed in the next section.) +.IP +.sM +.nf + +#include + +/* precompute the maximum size of batching request allowed */ + +static int size = sizeof(xPolyPointReq) + EPERBATCH * sizeof(xPoint); + +XDrawPoint(dpy, d, gc, x, y) + register Display *dpy; + Drawable d; + GC gc; + int x, y; /* INT16 */ +{ + xPoint *point; + LockDisplay(dpy); + FlushGC(dpy, gc); + { + register xPolyPointReq *req = (xPolyPointReq *) dpy->last_req; + /* if same as previous request, with same drawable, batch requests */ + if ( + (req->reqType == X_PolyPoint) + && (req->drawable == d) + && (req->gc == gc->gid) + && (req->coordMode == CoordModeOrigin) + && ((dpy->bufptr + sizeof (xPoint)) <= dpy->bufmax) + && (((char *)dpy->bufptr - (char *)req) < size) ) { + point = (xPoint *) dpy->bufptr; + req->length += sizeof (xPoint) >> 2; + dpy->bufptr += sizeof (xPoint); + } + + else { + GetReqExtra(PolyPoint, 4, req); /* 1 point = 4 bytes */ + req->drawable = d; + req->gc = gc->gid; + req->coordMode = CoordModeOrigin; + point = (xPoint *) (req + 1); + } + point->x = x; + point->y = y; + } + UnlockDisplay(dpy); + SyncHandle(); +} +.fi +.LP +.eM +To keep clients from generating very long requests that may monopolize the +server, +there is a symbol defined in +.hN X11/Xlibint.h +of EPERBATCH on the number of requests batched. +Most of the performance benefit occurs in the first few merged requests. +Note that +.PN FlushGC +is called \fIbefore\fP picking up the value of last_req, +because it may modify this field. +.SH +Writing Extension Stubs +.LP +All X requests always contain the length of the request, +expressed as a 16-bit quantity of 32 bits. +This means that a single request can be no more than 256K bytes in +length. +Some servers may not support single requests of such a length. +The value of dpy->max_request_size contains the maximum length as +defined by the server implementation. +For further information, +see ``X Window System Protocol.'' +.SH +Requests, Replies, and Xproto.h +.LP +The +.hN X11/Xproto.h +file contains three sets of definitions that +are of interest to the stub implementor: +request names, request structures, and reply structures. +.LP +You need to generate a file equivalent to +.hN X11/Xproto.h +for your extension and need to include it in your stub procedure. +Each stub procedure also must include +.hN X11/Xlibint.h . +.LP +The identifiers are deliberately chosen in such a way that, if the +request is called X_DoSomething, then its request structure is +xDoSomethingReq, and its reply is xDoSomethingReply. +The GetReq family of macros, defined in +.hN X11/Xlibint.h , +takes advantage of this naming scheme. +.LP +For each X request, +there is a definition in +.hN X11/Xproto.h +that looks similar to this: +.LP +.Ds +.R +#define X_DoSomething 42 +.De +In your extension header file, +this will be a minor opcode, +instead of a major opcode. +.SH +Request Format +.LP +Every request contains an 8-bit major opcode and a 16-bit length field +expressed in units of 4 bytes. +Every request consists of 4 bytes of header +(containing the major opcode, the length field, and a data byte) followed by +zero or more additional bytes of data. +The length field defines the total length of the request, including the header. +The length field in a request must equal the minimum length required to contain +the request. +If the specified length is smaller or larger than the required length, +the server should generate a +.PN BadLength +error. +Unused bytes in a request are not required to be zero. +Extensions should be designed in such a way that long protocol requests +can be split up into smaller requests, +if it is possible to exceed the maximum request size of the server. +The protocol guarantees the maximum request size to be no smaller than +4096 units (16384 bytes). +.LP +Major opcodes 128 through 255 are reserved for extensions. +Extensions are intended to contain multiple requests, +so extension requests typically have an additional minor opcode encoded +in the second data byte in the request header, +but the placement and interpretation of this minor opcode as well as all +other fields in extension requests are not defined by the core protocol. +Every request is implicitly assigned a sequence number (starting with one) +used in replies, errors, and events. +.LP +To help but not cure portability problems to certain machines, the +.PN B16 +and +.PN B32 +macros have been defined so that they can become bitfield specifications +on some machines. +For example, on a Cray, +these should be used for all 16-bit and 32-bit quantities, as discussed below. +.LP +Most protocol requests have a corresponding structure typedef in +.hN X11/Xproto.h , +which looks like: +.LP +.IN "xDoSomethingReq" "" "@DEF@" +.sM +.Ds 0 +.TA .5i 3i +.ta .5i 3i +typedef struct _DoSomethingReq { + CARD8 reqType; /* X_DoSomething */ + CARD8 someDatum; /* used differently in different requests */ + CARD16 length B16; /* total # of bytes in request, divided by 4 */ + ... + /* request-specific data */ + ... +} xDoSomethingReq; +.De +.LP +.eM +If a core protocol request has a single 32-bit argument, +you need not declare a request structure in your extension header file. +Instead, such requests use the +.PN xResourceReq +structure in +.hN X11/Xproto.h . +This structure is used for any request whose single argument is a +.PN Window , +.PN Pixmap , +.PN Drawable , +.PN GContext , +.PN Font , +.PN Cursor , +.PN Colormap , +.PN Atom , +or +.PN VisualID . +.LP +.IN "xResourceReq" "" "@DEF@" +.sM +.Ds 0 +.TA .5i 3i +.ta .5i 3i +typedef struct _ResourceReq { + CARD8 reqType; /* the request type, e.g. X_DoSomething */ + BYTE pad; /* not used */ + CARD16 length B16; /* 2 (= total # of bytes in request, divided by 4) */ + CARD32 id B32; /* the Window, Drawable, Font, GContext, etc. */ +} xResourceReq; +.De +.LP +.eM +If convenient, +you can do something similar in your extension header file. +.LP +In both of these structures, +the reqType field identifies the type of the request (for example, +X_MapWindow or X_CreatePixmap). +The length field tells how long the request is +in units of 4-byte longwords. +This length includes both the request structure itself and any +variable-length data, such as strings or lists, that follow the +request structure. +Request structures come in different sizes, +but all requests are padded to be multiples of four bytes long. +.LP +A few protocol requests take no arguments at all. +Instead, they use the +.PN xReq +structure in +.hN X11/Xproto.h , +which contains only a reqType and a length (and a pad byte). +.LP +If the protocol request requires a reply, +then +.hN X11/Xproto.h +also contains a reply structure typedef: +.LP +.IN "xDoSomethingReply" "" "@DEF@" +.sM +.Ds 0 +.TA .5i 3i +.ta .5i 3i +typedef struct _DoSomethingReply { + BYTE type; /* always X_Reply */ + BYTE someDatum; /* used differently in different requests */ + CARD16 sequenceNumber B16; /* # of requests sent so far */ + CARD32 length B32; /* # of additional bytes, divided by 4 */ + ... + /* request-specific data */ + ... +} xDoSomethingReply; +.De +.LP +.eM +Most of these reply structures are 32 bytes long. +If there are not that many reply values, +then they contain a sufficient number of pad fields +to bring them up to 32 bytes. +The length field is the total number of bytes in the request minus 32, +divided by 4. +This length will be nonzero only if: +.IP \(bu 5 +The reply structure is followed by variable-length data, +such as a list or string. +.IP \(bu 5 +The reply structure is longer than 32 bytes. +.LP +Only +.PN GetWindowAttributes , +.PN QueryFont , +.PN QueryKeymap , +and +.PN GetKeyboardControl +have reply structures longer than 32 bytes in the core protocol. +.LP +A few protocol requests return replies that contain no data. +.hN X11/Xproto.h +does not define reply structures for these. +Instead, they use the +.PN xGenericReply +structure, which contains only a type, length, +and sequence number (and sufficient padding to make it 32 bytes long). +.SH +Starting to Write a Stub Procedure +.LP +An Xlib stub procedure should start like this: +.LP +.Ds +.R +#include " + +XDoSomething (arguments, ... ) +/* argument declarations */ +{ + +register XDoSomethingReq *req; +\^... +.De +If the protocol request has a reply, +then the variable declarations should include the reply structure for the request. +The following is an example: +.LP +.Ds +.R +xDoSomethingReply rep; +.De +.SH +Locking Data Structures +.LP +To lock the display structure for systems that +want to support multithreaded access to a single display connection, +each stub will need to lock its critical section. +Generally, this section is the point from just before the appropriate GetReq +call until all arguments to the call have been stored into the buffer. +The precise instructions needed for this locking depend upon the machine +architecture. +Two calls, which are generally implemented as macros, have been provided. +.IN "LockDisplay" "" "@DEF@" +.sM +.FD 0 +LockDisplay(\^\fIdisplay\fP\^) +.br + Display *\fIdisplay\fP\^; +.FN +.LP +.IN "UnlockDisplay" "" "@DEF@" +.FD 0 +UnlockDisplay(\^\fIdisplay\fP\^) +.br + Display *\fIdisplay\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.LP +.eM +.SH +Sending the Protocol Request and Arguments +.LP +After the variable declarations, +a stub procedure should call one of four macros defined in +.hN X11/Xlibint.h : +.PN GetReq , +.PN GetReqExtra , +.PN GetResReq , +or +.PN GetEmptyReq . +All of these macros take, as their first argument, +the name of the protocol request as declared in +.hN X11/Xproto.h +except with X_ removed. +Each one declares a +.PN Display +structure pointer, +called dpy, and a pointer to a request structure, called req, +which is of the appropriate type. +The macro then appends the request structure to the output buffer, +fills in its type and length field, and sets req to point to it. +.LP +If the protocol request has no arguments (for instance, X_GrabServer), +then use +.PN GetEmptyReq . +.LP +.Ds +.R +GetEmptyReq (DoSomething, req); +.De +If the protocol request has a single 32-bit argument (such as a +.PN Pixmap , +.PN Window , +.PN Drawable , +.PN Atom , +and so on), +then use +.PN GetResReq . +The second argument to the macro is the 32-bit object. +.PN X_MapWindow +is a good example. +.LP +.Ds +.R +GetResReq (DoSomething, rid, req); +.De +The rid argument is the +.PN Pixmap , +.PN Window , +or other resource ID. +.LP +If the protocol request takes any other argument list, +then call +.PN GetReq . +After the +.PN GetReq , +you need to set all the other fields in the request structure, +usually from arguments to the stub procedure. +.LP +.Ds +.R +GetReq (DoSomething, req); +/* fill in arguments here */ +req->arg1 = arg1; +req->arg2 = arg2; +\^... +.De +A few stub procedures (such as +.PN XCreateGC +and +.PN XCreatePixmap ) +return a resource ID to the caller but pass a resource ID as an argument +to the protocol request. +Such procedures use the macro +.PN XAllocID +to allocate a resource ID from the range of IDs +that were assigned to this client when it opened the connection. +.LP +.Ds +.R +rid = req->rid = XAllocID(); +\^... +return (rid); +.De +Finally, some stub procedures transmit a fixed amount of variable-length +data after the request. +Typically, these procedures (such as +.PN XMoveWindow +and +.PN XSetBackground ) +are special cases of more general functions like +.PN XMoveResizeWindow +and +.PN XChangeGC . +These procedures use +.PN GetReqExtra , +which is the same as +.PN GetReq +except that it takes an additional argument (the number of +extra bytes to allocate in the output buffer after the request structure). +This number should always be a multiple of four. +.SH +Variable Length Arguments +.LP +Some protocol requests take additional variable-length data that +follow the +.PN xDoSomethingReq +structure. +The format of this data varies from request to request. +Some requests require a sequence of 8-bit bytes, +others a sequence of 16-bit or 32-bit entities, +and still others a sequence of structures. +.LP +It is necessary to add the length of any variable-length data to the +length field of the request structure. +That length field is in units of 32-bit longwords. +If the data is a string or other sequence of 8-bit bytes, +then you must round the length up and shift it before adding: +.LP +.Ds +.R +req->length += (nbytes+3)>>2; +.De +To transmit variable-length data, use the +.PN Data +macros. +If the data fits into the output buffer, +then this macro copies it to the buffer. +If it does not fit, however, +the +.PN Data +macro calls +.PN _XSend , +which transmits first the contents of the buffer and then your data. +The +.PN Data +macros take three arguments: +the display, a pointer to the beginning of the data, +and the number of bytes to be sent. +.sM +.FD 0 +Data(\^\fIdisplay\fP, (char *) \fIdata\fP, \fInbytes\fP\^); +.sp +Data16(\^\fIdisplay\fP, (short *) \fIdata\fP, \fInbytes\fP\^); +.sp +Data32(\^\fIdisplay\fP, (long *) \fIdata\fP, \fInbytes\fP\^); +.FN +.LP +.eM +.PN Data , +.PN Data16 , +and +.PN Data32 +are macros that may use their last argument +more than once, so that argument should be a variable rather than +an expression such as ``nitems*sizeof(item)''. +You should do that kind of computation in a separate statement before calling +them. +Use the appropriate macro when sending byte, short, or long data. +.LP +If the protocol request requires a reply, +then call the procedure +.PN _XSend +instead of the +.PN Data +macro. +.PN _XSend +takes the same arguments, but because it sends your data immediately instead of +copying it into the output buffer (which would later be flushed +anyway by the following call on +.PN _XReply ), +it is faster. +.SH +Replies +.LP +If the protocol request has a reply, +then call +.PN _XReply +after you have finished dealing with +all the fixed-length and variable-length arguments. +.PN _XReply +flushes the output buffer and waits for an +.PN xReply +packet to arrive. +If any events arrive in the meantime, +.PN _XReply +places them in the queue for later use. +.IN "_XReply" "" "@DEF@" +.sM +.FD 0 +Status _XReply(\^\fIdisplay\fP, \fIrep\fP, \fIextra\fP, \fIdiscard\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + xReply *\fIrep\fP\^; +.br + int \fIextra\fP\^; +.br + Bool \fIdiscard\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIrep\fP 1i +Specifies the reply structure. +.IP \fIextra\fP 1i +Specifies the number of 32-bit words expected after the replay. +.IP \fIdiscard\fP 1i +Specifies if any data beyond that specified in the extra argument +should be discarded. +.LP +.eM +The +.PN _XReply +function waits for a reply packet and copies its contents into the +specified rep. +.PN _XReply +handles error and event packets that occur before the reply is received. +.PN _XReply +takes four arguments: +.IP \(bu 5 +A +.PN Display +* structure +.IP \(bu 5 +A pointer to a reply structure (which must be cast to an +.PN xReply +*) +.IP \(bu 5 +The number of additional 32-bit words (beyond +.Pn sizeof( xReply ) += 32 bytes) +in the reply structure +.IP \(bu 5 +A Boolean that indicates whether +.PN _XReply +is to discard any additional bytes +beyond those it was told to read +.LP +Because most reply structures are 32 bytes long, +the third argument is usually 0. +The only core protocol exceptions are the replies to +.PN GetWindowAttributes , +.PN QueryFont , +.PN QueryKeymap , +and +.PN GetKeyboardControl , +which have longer replies. +.LP +The last argument should be +.PN False +if the reply structure is followed +by additional variable-length data (such as a list or string). +It should be +.PN True +if there is not any variable-length data. +.NT +This last argument is provided for upward-compatibility reasons +to allow a client to communicate properly with a hypothetical later +version of the server that sends more data than the client expected. +For example, some later version of +.PN GetWindowAttributes +might use a +larger, but compatible, +.PN xGetWindowAttributesReply +that contains additional attribute data at the end. +.NE +.PN _XReply +returns +.PN True +if it received a reply successfully or +.PN False +if it received any sort of error. +.LP +For a request with a reply that is not followed by variable-length +data, you write something like: +.LP +.Ds +.R +_XReply(display, (xReply *)&rep, 0, True); +*ret1 = rep.ret1; +*ret2 = rep.ret2; +*ret3 = rep.ret3; +\^... +UnlockDisplay(dpy); +SyncHandle(); +return (rep.ret4); +} +.De +If there is variable-length data after the reply, +change the +.PN True +to +.PN False , +and use the appropriate +.PN _XRead +function to read the variable-length data. +.LP +.sM +.FD 0 +_XRead(\^\fIdisplay\fP, \fIdata_return\fP, \fInbytes\fP\^) + Display *\fIdisplay\fP\^; + char *\fIdata_return\fP\^; + long \fInbytes\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIdata_return\fP 1i +Specifies the buffer. +.IP \fInbytes\fP 1i +Specifies the number of bytes required. +.LP +.eM +The +.PN _XRead +function reads the specified number of bytes into data_return. +.LP +.sM +.FD 0 +_XRead16(\^\fIdisplay\fP, \fIdata_return\fP, \fInbytes\fP\^) + Display *\fIdisplay\fP\^; + short *\fIdata_return\fP\^; + long \fInbytes\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIdata_return\fP 1i +Specifies the buffer. +.IP \fInbytes\fP 1i +Specifies the number of bytes required. +.LP +.eM +The +.PN _XRead16 +function reads the specified number of bytes, +unpacking them as 16-bit quantities, +into the specified array as shorts. +.LP +.sM +.FD 0 +_XRead32(\^\fIdisplay\fP, \fIdata_return\fP, \fInbytes\fP\^) + Display *\fIdisplay\fP\^; + long *\fIdata_return\fP\^; + long \fInbytes\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIdata_return\fP 1i +Specifies the buffer. +.IP \fInbytes\fP 1i +Specifies the number of bytes required. +.LP +.eM +The +.PN _XRead32 +function reads the specified number of bytes, +unpacking them as 32-bit quantities, +into the specified array as longs. +.LP +.sM +.FD 0 +_XRead16Pad(\^\fIdisplay\fP, \fIdata_return\fP, \fInbytes\fP\^) + Display *\fIdisplay\fP\^; + short *\fIdata_return\fP\^; + long \fInbytes\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIdata_return\fP 1i +Specifies the buffer. +.IP \fInbytes\fP 1i +Specifies the number of bytes required. +.LP +.eM +The +.PN _XRead16Pad +function reads the specified number of bytes, +unpacking them as 16-bit quantities, +into the specified array as shorts. +If the number of bytes is not a multiple of four, +.PN _XRead16Pad +reads and discards up to two additional pad bytes. +.LP +.sM +.FD 0 +_XReadPad(\^\fIdisplay\fP, \fIdata_return\fP, \fInbytes\fP\^) + Display *\fIdisplay\fP\^; + char *\fIdata_return\fP\^; + long \fInbytes\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIdata_return\fP 1i +Specifies the buffer. +.IP \fInbytes\fP 1i +Specifies the number of bytes required. +.LP +.eM +The +.PN _XReadPad +function reads the specified number of bytes into data_return. +If the number of bytes is not a multiple of four, +.PN _XReadPad +reads and discards up to three additional pad bytes. +.LP +Each protocol request is a little different. +For further information, +see the Xlib sources for examples. +.SH +Synchronous Calling +.LP +Each procedure should have a call, just before returning to the user, +to a macro called +.PN SyncHandle . +If synchronous mode is enabled (see +.PN XSynchronize ), +the request is sent immediately. +The library, however, waits until any error the procedure could generate +at the server has been handled. +.SH +Allocating and Deallocating Memory +.LP +To support the possible reentry of these procedures, +you must observe several conventions when allocating and deallocating memory, +most often done when returning data to the user from the window +system of a size the caller could not know in advance +(for example, a list of fonts or a list of extensions). +The standard C library functions on many systems +are not protected against signals or other multithreaded uses. +The following analogies to standard I/O library functions +have been defined: +.TS +l l. +T{ +.PN Xmalloc () +T} T{ +Replaces +.PN malloc () +T} +T{ +.PN XFree () +T} T{ +Replaces +.PN free () +T} +T{ +.PN Xcalloc () +T} T{ +Replaces +.PN calloc () +T} +.TE +.LP +These should be used in place of any calls you would make to the normal +C library functions. +.LP +If you need a single scratch buffer inside a critical section +(for example, to pack and unpack data to and from the wire protocol), +the general memory allocators may be too expensive to use +(particularly in output functions, which are performance critical). +The following function returns a scratch buffer for use within a +critical section: +.IN "_XAllocScratch" "" "@DEF@" +.sM +.FD 0 +char *_XAllocScratch(\^\fIdisplay\fP, \fInbytes\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + unsigned long \fInbytes\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fInbytes\fP 1i +Specifies the number of bytes required. +.LP +.eM +This storage must only be used inside of a critical section of your +stub. The returned pointer cannot be assumed valid after any call +that might permit another thread to execute inside Xlib. For example, +the pointer cannot be assumed valid after any use of the +.PN GetReq +or +.PN Data +families of macros, +after any use of +.PN _XReply , +or after any use of the +.PN _XSend +or +.PN _XRead +families of functions. +.LP +.sp +The following function returns a scratch buffer for use across +critical sections: +.IN "_XAllocTemp" "" "@DEF@" +.sM +.FD 0 +char *_XAllocTemp(\^\fIdisplay\fP, \fInbytes\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + unsigned long \fInbytes\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fInbytes\fP 1i +Specifies the number of bytes required. +.LP +.eM +This storage can be used across calls that might permit another thread to +execute inside Xlib. The storage must be explicitly returned to Xlib. +The following function returns the storage: +.IN "_XFreeTemp" "" "@DEF@" +.sM +.FD 0 +void _XFreeTemp(\^\fIdisplay\fP, \fIbuf\fP, \fInbytes\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + char *\fIbuf\fP\^; +.br + unsigned long \fInbytes\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIbuf\fP 1i +Specifies the buffer to return. +.IP \fInbytes\fP 1i +Specifies the size of the buffer. +.LP +.eM +You must pass back the same pointer and size that were returned by +.PN _XAllocTemp . +.SH +Portability Considerations +.LP +Many machine architectures, +including many of the more recent RISC architectures, +do not correctly access data at unaligned locations; +their compilers pad out structures to preserve this characteristic. +Many other machines capable of unaligned references pad inside of structures +as well to preserve alignment, because accessing aligned data is +usually much faster. +Because the library and the server use structures to access data at +arbitrary points in a byte stream, +all data in request and reply packets \fImust\fP be naturally aligned; +that is, 16-bit data starts on 16-bit boundaries in the request +and 32-bit data on 32-bit boundaries. +All requests \fImust\fP be a multiple of 32 bits in length to preserve +the natural alignment in the data stream. +You must pad structures out to 32-bit boundaries. +Pad information does not have to be zeroed unless you want to +preserve such fields for future use in your protocol requests. +Floating point varies radically between machines and should be +avoided completely if at all possible. +.LP +This code may run on machines with 16-bit ints. +So, if any integer argument, variable, or return value either can take +only nonnegative values or is declared as a +.PN CARD16 +in the protocol, be sure to declare it as +.PN unsigned +.PN int +and not as +.PN int . +(This, of course, does not apply to Booleans or enumerations.) +.LP +Similarly, +if any integer argument or return value is declared +.PN CARD32 +in the protocol, +declare it as an +.PN unsigned +.PN long +and not as +.PN int +or +.PN long . +This also goes for any internal variables that may +take on values larger than the maximum 16-bit +.PN unsigned +.PN int . +.LP +The library currently assumes that a +.PN char +is 8 bits, a +.PN short +is 16 bits, an +.PN int +is 16 or 32 bits, and a +.PN long +is 32 bits. +The +.PN PackData +macro is a half-hearted attempt to deal with the possibility of 32 bit shorts. +However, much more work is needed to make this work properly. +.SH +Deriving the Correct Extension Opcode +.LP +The remaining problem a writer of an extension stub procedure faces that +the core protocol does not face is to map from the call to the proper +major and minor opcodes. +While there are a number of strategies, +the simplest and fastest is outlined below. +.IP 1. 5 +Declare an array of pointers, _NFILE long (this is normally found +in +.hN stdio.h +and is the number of file descriptors supported on the system) +of type +.PN XExtCodes . +Make sure these are all initialized to NULL. +.IP 2. 5 +When your stub is entered, your initialization test is just to use +the display pointer passed in to access the file descriptor and an index +into the array. +If the entry is NULL, then this is the first time you +are entering the procedure for this display. +Call your initialization procedure and pass to it the display pointer. +.IP 3. 5 +Once in your initialization procedure, call +.PN XInitExtension ; +if it succeeds, store the pointer returned into this array. +Make sure to establish a close display handler to allow you to zero the entry. +Do whatever other initialization your extension requires. +(For example, install event handlers and so on.) +Your initialization procedure would normally return a pointer to the +.PN XExtCodes +structure for this extension, which is what would normally +be found in your array of pointers. +.IP 4. 5 +After returning from your initialization procedure, +the stub can now continue normally, because it has its major opcode safely +in its hand in the +.PN XExtCodes +structure. +.bp diff --git a/libX11/specs/libX11/AppD b/libX11/specs/libX11/AppD new file mode 100644 index 000000000..f96e06175 --- /dev/null +++ b/libX11/specs/libX11/AppD @@ -0,0 +1,1183 @@ +.\" Copyright \(co 1985, 1986, 1987, 1988, 1989, 1990, 1991, 1994, 1996 X Consortium +.\" +.\" 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 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 X CONSORTIUM 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 X Consortium 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 X Consortium. +.\" +.\" Copyright \(co 1985, 1986, 1987, 1988, 1989, 1990, 1991 by +.\" Digital Equipment Corporation +.\" +.\" Portions Copyright \(co 1990, 1991 by +.\" Tektronix, Inc. +.\" +.\" Permission to use, copy, modify and distribute this documentation for +.\" any purpose and without fee is hereby granted, provided that the above +.\" copyright notice appears in all copies and that both that copyright notice +.\" and this permission notice appear in all copies, and that the names of +.\" Digital and Tektronix not be used in in advertising or publicity pertaining +.\" to this documentation without specific, written prior permission. +.\" Digital and Tektronix makes no representations about the suitability +.\" of this documentation for any purpose. +.\" It is provided ``as is'' without express or implied warranty. +.\" +\& +.sp 1 +.ce 3 +\s+1\fBAppendix D\fP\s-1 + +\s+1\fBCompatibility Functions\fP\s-1 +.sp 2 +.na +.LP +.XS +Appendix D: Compatibility Functions +.XE +.LP +The X Version 11 and X Version 10 functions discussed in this appendix +are obsolete, have been superseded by newer X Version 11 functions, +and are maintained for compatibility reasons only. +.SH +X Version 11 Compatibility Functions +.LP +You can use the X Version 11 compatibility functions to: +.IP \(bu 5 +Set standard properties +.IP \(bu 5 +Set and get window sizing hints +.IP \(bu 5 +Set and get an +.PN XStandardColormap +structure +.IP \(bu 5 +Parse window geometry +.IP \(bu 5 +Get X environment defaults +.SH +Setting Standard Properties +.LP +To specify a minimum set of properties describing the simplest application, +use +.PN XSetStandardProperties . +This function has been superseded by +.PN XSetWMProperties +and sets all or portions of the +WM_NAME, WM_ICON_NAME, WM_HINTS, WM_COMMAND, +and WM_NORMAL_HINTS properties. +.IN "XSetStandardProperties" "" "@DEF@" +.sM +.FD 0 +XSetStandardProperties\^(\^\fIdisplay\fP, \fIw\fP, \fIwindow_name\fP, \fIicon_name\fP, \fIicon_pixmap\fP, \fIargv\fP, \fIargc\fP, \fIhints\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + char *\fIwindow_name\fP\^; +.br + char *\fIicon_name\fP\^; +.br + Pixmap \fIicon_pixmap\fP\^; +.br + char **\fIargv\fP\^; +.br + int \fIargc\fP\^; +.br + XSizeHints *\fIhints\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fIwindow_name\fP 1i +Specifies the window name, +which should be a null-terminated string. +.IP \fIicon_name\fP 1i +Specifies the icon name, +which should be a null-terminated string. +.IP \fIicon_pixmap\fP 1i +Specifies the bitmap that is to be used for the icon or +.PN None . +.IP \fIargv\fP 1i +Specifies the application's argument list. +.IP \fIargc\fP 1i +Specifies the number of arguments. +.IP \fIhints\fP 1i +Specifies a pointer to the size hints for the window in its normal state. +.LP +.eM +The +.PN XSetStandardProperties +function provides a means by which simple applications set the +most essential properties with a single call. +.PN XSetStandardProperties +should be used to give a window manager some information about +your program's preferences. +It should not be used by applications that need +to communicate more information than is possible with +.PN XSetStandardProperties . +(Typically, argv is the argv array of your main program.) +If the strings are not in the Host Portable Character Encoding, +the result is implementation-dependent. +.LP +.PN XSetStandardProperties +can generate +.PN BadAlloc +and +.PN BadWindow +errors. +.SH +Setting and Getting Window Sizing Hints +.LP +Xlib provides functions that you can use to set or get window sizing hints. +The functions discussed in this section use the flags and the +.PN XSizeHints +structure, as defined in the +.hN X11/Xutil.h +header file and use the WM_NORMAL_HINTS property. +.LP +.sp +To set the size hints for a given window in its normal state, use +.PN XSetNormalHints . +This function has been superseded by +.PN XSetWMNormalHints . +.IN "XSetNormalHints" "" "@DEF@" +.sM +.FD 0 +XSetNormalHints\^(\^\fIdisplay\fP, \fIw\fP, \fIhints\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + XSizeHints *\fIhints\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fIhints\fP 1i +Specifies a pointer to the size hints for the window in its normal state. +.LP +.eM +The +.PN XSetNormalHints +function sets the size hints structure for the specified window. +Applications use +.PN XSetNormalHints +to inform the window manager of the size +or position desirable for that window. +In addition, +an application that wants to move or resize itself should call +.PN XSetNormalHints +and specify its new desired location and size +as well as making direct Xlib calls to move or resize. +This is because window managers may ignore redirected +configure requests, but they pay attention to property changes. +.LP +To set size hints, +an application not only must assign values to the appropriate members +in the hints structure but also must set the flags member of the structure +to indicate which information is present and where it came from. +A call to +.PN XSetNormalHints +is meaningless, unless the flags member is set to indicate which members of +the structure have been assigned values. +.LP +.PN XSetNormalHints +can generate +.PN BadAlloc +and +.PN BadWindow +errors. +.LP +.sp +To return the size hints for a window in its normal state, use +.PN XGetNormalHints . +This function has been superseded by +.PN XGetWMNormalHints . +.IN "XGetNormalHints" "" "@DEF@" +.sM +.FD 0 +Status XGetNormalHints\^(\^\fIdisplay\fP, \fIw\fP, \fIhints_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + XSizeHints *\fIhints_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fIhints_return\fP 1i +Returns the size hints for the window in its normal state. +.LP +.eM +The +.PN XGetNormalHints +function returns the size hints for a window in its normal state. +It returns a nonzero status if it succeeds or zero if +the application specified no normal size hints for this window. +.LP +.PN XGetNormalHints +can generate a +.PN BadWindow +error. +.LP +.sp +The next two functions set and read the WM_ZOOM_HINTS property. +.LP +To set the zoom hints for a window, use +.PN XSetZoomHints . +This function is no longer supported by the +\fIInter-Client Communication Conventions Manual\fP. +.IN "XSetZoomHints" "" "@DEF@" +.sM +.FD 0 +XSetZoomHints\^(\^\fIdisplay\fP, \fIw\fP, \fIzhints\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + XSizeHints *\fIzhints\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fIzhints\fP 1i +Specifies a pointer to the zoom hints. +.LP +.eM +Many window managers think of windows in one of three states: +iconic, normal, or zoomed. +The +.PN XSetZoomHints +function provides the window manager with information for the window in the +zoomed state. +.LP +.PN XSetZoomHints +can generate +.PN BadAlloc +and +.PN BadWindow +errors. +.LP +.sp +To read the zoom hints for a window, use +.PN XGetZoomHints . +This function is no longer supported by the +\fIInter-Client Communication Conventions Manual\fP. +.IN "XGetZoomHints" "" "@DEF@" +.sM +.FD 0 +Status XGetZoomHints\^(\^\fIdisplay\fP, \fIw\fP, \fIzhints_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + XSizeHints *\fIzhints_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fIzhints_return\fP 1i +Returns the zoom hints. +.LP +.eM +The +.PN XGetZoomHints +function returns the size hints for a window in its zoomed state. +It returns a nonzero status if it succeeds or zero if +the application specified no zoom size hints for this window. +.LP +.PN XGetZoomHints +can generate a +.PN BadWindow +error. +.LP +.sp +To set the value of any property of type WM_SIZE_HINTS, use +.PN XSetSizeHints . +This function has been superseded by +.PN XSetWMSizeHints . +.IN "XSetSizeHints" "" "@DEF@" +.sM +.FD 0 +XSetSizeHints\^(\^\fIdisplay\fP, \fIw\fP, \fIhints\fP, \fIproperty\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + XSizeHints *\fIhints\fP\^; +.br + Atom \fIproperty\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fIhints\fP 1i +Specifies a pointer to the size hints. +.IP \fIproperty\fP 1i +Specifies the property name. +.LP +.eM +The +.PN XSetSizeHints +function sets the +.PN XSizeHints +structure for the named property and the specified window. +This is used by +.PN XSetNormalHints +and +.PN XSetZoomHints +and can be used to set the value of any property of type WM_SIZE_HINTS. +Thus, it may be useful if other properties of that type get defined. +.LP +.PN XSetSizeHints +can generate +.PN BadAlloc , +.PN BadAtom , +and +.PN BadWindow +errors. +.LP +.sp +To read the value of any property of type WM_SIZE_HINTS, use +.PN XGetSizeHints . +This function has been superseded by +.PN XGetWMSizeHints . +.IN "XGetSizeHints" "" "@DEF@" +.sM +.FD 0 +Status XGetSizeHints\^(\^\fIdisplay\fP, \fIw\fP, \fIhints_return\fP, \fIproperty\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + XSizeHints *\fIhints_return\fP\^; +.br + Atom \fIproperty\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fIhints_return\fP 1i +Returns the size hints. +.IP \fIproperty\fP 1i +Specifies the property name. +.LP +.eM +The +.PN XGetSizeHints +function returns the +.PN XSizeHints +structure for the named property and the specified window. +This is used by +.PN XGetNormalHints +and +.PN XGetZoomHints . +It also can be used to retrieve the value of any property of type +WM_SIZE_HINTS. +Thus, it may be useful if other properties of that type get defined. +.PN XGetSizeHints +returns a nonzero status if a size hint was defined +or zero otherwise. +.LP +.PN XGetSizeHints +can generate +.PN BadAtom +and +.PN BadWindow +errors. +.SH +Getting and Setting an XStandardColormap Structure +.LP +To get the +.PN XStandardColormap +structure associated with one of the described atoms, use +.PN XGetStandardColormap . +This function has been superseded by +.PN XGetRGBColormap . +.IN "XGetStandardColormap" "" "@DEF@" +.sM +.FD 0 +Status XGetStandardColormap(\^\fIdisplay\fP, \fIw\fP, \fIcolormap_return\fP, \fIproperty\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + XStandardColormap *\fIcolormap_return\fP\^; +.br + Atom \fIproperty\fP\^; /* RGB_BEST_MAP, etc. */ +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fIcolormap_return\fP 1i +Returns the colormap associated with the specified atom. +.IP \fIproperty\fP 1i +Specifies the property name. +.LP +.eM +The +.PN XGetStandardColormap +function returns the colormap definition associated with the atom supplied +as the property argument. +.PN XGetStandardColormap +returns a nonzero status if successful and zero otherwise. +For example, +to fetch the standard +.PN GrayScale +colormap for a display, +you use +.PN XGetStandardColormap +with the following syntax: +.LP +.sM +.Ds 0 +.TA .5i 1.5i +.ta .5i 1.5i +XGetStandardColormap(dpy, DefaultRootWindow(dpy), &cmap, XA_RGB_GRAY_MAP); +.De +.LP +.eM +See section 14.3 for the semantics of standard colormaps. +.LP +.PN XGetStandardColormap +can generate +.PN BadAtom +and +.PN BadWindow +errors. +.LP +.sp +To set a standard colormap, use +.PN XSetStandardColormap . +This function has been superseded by +.PN XSetRGBColormap . +.IN "XSetStandardColormap" "" "@DEF@" +.sM +.FD 0 +XSetStandardColormap(\^\fIdisplay\fP, \fIw\fP, \fIcolormap\fP, \fIproperty\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + XStandardColormap *\fIcolormap\fP\^; +.br + Atom \fIproperty\fP\^; /* RGB_BEST_MAP, etc. */ +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fIcolormap\fP 1i +Specifies the colormap. +.IP \fIproperty\fP 1i +Specifies the property name. +.LP +.eM +The +.PN XSetStandardColormap +function usually is only used by window or session managers. +.LP +.PN XSetStandardColormap +can generate +.PN BadAlloc , +.PN BadAtom , +.PN BadDrawable , +and +.PN BadWindow +errors. +.SH +Parsing Window Geometry +.LP +To parse window geometry given a user-specified position +and a default position, use +.PN XGeometry . +This function has been superseded by +.PN XWMGeometry . +.IN "Window" "determining location" +.IN "XGeometry" "" "@DEF@" +.sM +.FD 0 +int XGeometry\^(\^\fIdisplay\fP, \fIscreen\fP, \fIposition\fP\^, \fIdefault_position\fP\^, \fIbwidth\fP\^, \fIfwidth\fP\^, \fIfheight\fP\^, \fIxadder\fP\^, +.br + \fIyadder\fP\^, \fIx_return\fP\^, \fIy_return\fP\^, \fIwidth_return\fP\^, \fIheight_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + int \fIscreen\fP\^; +.br + char *\fIposition\fP\^, *\fIdefault_position\fP\^; +.br + unsigned int \fIbwidth\fP\^; +.br + unsigned int \fIfwidth\fP\^, \fIfheight\fP\^; +.br + int \fIxadder\fP\^, \fIyadder\fP\^; +.br + int *\fIx_return\fP\^, *\fIy_return\fP\^; +.br + int *\fIwidth_return\fP\^, *\fIheight_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIscreen\fP 1i +Specifies the screen. +.IP \fIposition\fP 1i +.br +.ns +.IP \fIdefault_position\fP 1i +Specify the geometry specifications. +.IP \fIbwidth\fP 1i +Specifies the border width. +.IP \fIfheight\fP 1i +.br +.ns +.IP \fIfwidth\fP 1i +Specify the font height and width in pixels (increment size). +.IP \fIxadder\fP 1i +.br +.ns +.IP \fIyadder\fP 1i +Specify additional interior padding needed in the window. +.IP \fIx_return\fP 1i +.br +.ns +.IP \fIy_return\fP 1i +Return the x and y offsets. +.IP \fIwidth_return\fP 1i +.br +.ns +.IP \fIheight_return\fP 1i +Return the width and height determined. +.LP +.eM +You pass in the border width (bwidth), +size of the increments fwidth and fheight +(typically font width and height), +and any additional interior space (xadder and yadder) +to make it easy to compute the resulting size. +The +.PN XGeometry +function returns the position the window should be placed given a position and +a default position. +.PN XGeometry +determines the placement of +a window using a geometry specification as specified by +.PN XParseGeometry +and the additional information about the window. +Given a fully qualified default geometry specification and +an incomplete geometry specification, +.PN XParseGeometry +returns a bitmask value as defined above in the +.PN XParseGeometry +call, +by using the position argument. +.LP +The returned width and height will be the width and height specified +by default_position as overridden by any user-specified position. +They are not affected by fwidth, fheight, xadder, or yadder. +The x and y coordinates are computed by using the border width, +the screen width and height, padding as specified by xadder and yadder, +and the fheight and fwidth times the width and height from the +geometry specifications. +.SH +Getting the X Environment Defaults +.LP +The +.PN XGetDefault +function provides a primitive interface to the resource manager facilities +discussed in chapter 15. +It is only useful in very simple applications. +.LP +.sp +.IN "XGetDefault" "" "@DEF@" +.sM +.FD 0 +char *XGetDefault\^(\^\fIdisplay\fP, \fIprogram\fP\^, \fIoption\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + char *\fIprogram\fP\^; +.br + char *\fIoption\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIprogram\fP 1i +Specifies the program name for the Xlib defaults (usually argv[0] +of the main program). +.IP \fIoption\fP 1i +Specifies the option name. +.LP +.eM +The +.PN XGetDefault +function returns the value of the resource \fIprog\fP.\fIoption\fP, +where \fIprog\fP is the program argument with the directory prefix removed +and \fIoption\fP must be a single component. +Note that multilevel resources cannot be used with +.PN XGetDefault . +The class "Program.Name" is always used for the resource lookup. +If the specified option name does not exist for this program, +.PN XGetDefault +returns NULL. +The strings returned by +.PN XGetDefault +are owned by Xlib and should not be modified or freed by the client. +.LP +If a database has been set with +.PN XrmSetDatabase , +that database is used for the lookup. +Otherwise, a database is created +and is set in the display (as if by calling +.PN XrmSetDatabase ). +The database is created in the current locale. +To create a database, +.PN XGetDefault +uses resources from the RESOURCE_MANAGER property on the root +window of screen zero. +If no such property exists, +a resource file in the user's home directory is used. +On a POSIX-conformant system, +this file is +.PN "$HOME/.Xdefaults" . +.IN "Files" "$HOME/.Xdefaults" +After loading these defaults, +.PN XGetDefault +merges additional defaults specified by the XENVIRONMENT +environment variable. +If XENVIRONMENT is defined, +it contains a full path name for the additional resource file. +If XENVIRONMENT is not defined, +.PN XGetDefault +looks for +.PN "$HOME/.Xdefaults-\fIname\fP" , +where \fIname\fP specifies the name of the machine on which the application +is running. +.SH +X Version 10 Compatibility Functions +.LP +You can use the X Version 10 compatibility functions to: +.IP \(bu 5 +Draw and fill polygons and curves +.IP \(bu 5 +Associate user data with a value +.SH +Drawing and Filling Polygons and Curves +.LP +Xlib provides functions that you can use to draw or fill +arbitrary polygons or curves. +These functions are provided mainly for compatibility with X Version 10 +and have no server support. +That is, they call other Xlib functions, not the server directly. +Thus, if you just have straight lines to draw, using +.PN XDrawLines +.IN "XDrawLines" +or +.PN XDrawSegments +.IN "XDrawSegments" +is much faster. +.LP +The functions discussed here provide all the functionality of the +X Version 10 functions +.PN XDraw , +.IN "X10 compatibility" "XDraw" +.PN XDrawFilled , +.IN "X10 compatibility" "XDrawFilled" +.PN XDrawPatterned , +.IN "X10 compatibility" "XDrawPatterned" +.PN XDrawDashed , +.IN "X10 compatibility" "XDrawDashed" +and +.PN XDrawTiled . +.IN "X10 compatibility" "XDrawTiled" +They are as compatible as possible given X Version 11's new line-drawing +functions. +One thing to note, however, is that +.PN VertexDrawLastPoint +is no longer supported. +Also, the error status returned is the opposite of what it was under +X Version 10 (this is the X Version 11 standard error status). +.PN XAppendVertex +and +.PN XClearVertexFlag +from X Version 10 also are not supported. +.LP +Just how the graphics context you use is set up actually +determines whether you get dashes or not, and so on. +Lines are properly joined if they connect and include +the closing of a closed figure (see +.PN XDrawLines ). +The functions discussed here fail (return zero) only if they run out of memory +or are passed a +.PN Vertex +list that has a +.PN Vertex +with +.PN VertexStartClosed +set that is not followed by a +.PN Vertex +with +.PN VertexEndClosed +set. +.LP +.sp +To achieve the effects of the X Version 10 +.PN XDraw , +.IN "X10 compatibility" "XDraw" +.PN XDrawDashed , +.IN "X10 compatibility" "XDrawDashed" +and +.PN XDrawPatterned , +.IN "X10 compatibility" "XDrawPatterned" +use +.PN XDraw . +.IN "XDraw" "" "@DEF@" +.sM +.FD 0 +#include + +Status XDraw(\^\fIdisplay\fP, \fId\fP, \fIgc\fP, \fIvlist\fP, \fIvcount\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Drawable \fId\fP\^; +.br + GC \fIgc\fP\^; +.br + Vertex *\fIvlist\fP\^; +.br + int \fIvcount\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fId\fP 1i +Specifies the drawable. +.IP \fIgc\fP 1i +Specifies the GC. +.IP \fIvlist\fP 1i +Specifies a pointer to the list of vertices that indicate what to draw. +.IP \fIvcount\fP 1i +Specifies how many vertices are in vlist. +.LP +.eM +The +.PN XDraw +function draws an arbitrary polygon or curve. +The figure drawn is defined by the specified list of vertices (vlist). +The points are connected by lines as specified in the flags in the +vertex structure. +.LP +Each Vertex, as defined in +.hN X11/X10.h , +is a structure with the following members: +.LP +.IN "Vertex" "" "@DEF@" +.sM +.Ds 0 +.TA .5i 1.5i +.ta .5i 1.5i +typedef struct _Vertex { + short x,y; + unsigned short flags; +} Vertex; +.De +.LP +.eM +The x and y members are the coordinates of the vertex +that are relative to either the upper left inside corner of the drawable +(if +.PN VertexRelative +is zero) or the previous vertex (if +.PN VertexRelative +is one). +.LP +The flags, as defined in +.hN X11/X10.h , +are as follows: +.IN "VertexRelative" "" "@DEF@" +.IN "VertexDontDraw" "" "@DEF@" +.IN "VertexCurved" "" "@DEF@" +.IN "VertexStartClosed" "" "@DEF@" +.IN "VertexEndClosed" "" "@DEF@" +.sM +.TS +l l l. +T{ +.PN VertexRelative +T} T{ +0x0001 +T} T{ +/* else absolute */ +T} +T{ +.PN VertexDontDraw +T} T{ +0x0002 +T} T{ +/* else draw */ +T} +T{ +.PN VertexCurved +T} T{ +0x0004 +T} T{ +/* else straight */ +T} +T{ +.PN VertexStartClosed +T} T{ +0x0008 +T} T{ +/* else not */ +T} +T{ +.PN VertexEndClosed +T} T{ +0x0010 +T} T{ +/* else not */ +T} +.TE +.LP +.eM +.IP \(bu 5 +If +.PN VertexRelative +is not set, +the coordinates are absolute (that is, relative to the drawable's origin). +The first vertex must be an absolute vertex. +.IP \(bu 5 +If +.PN VertexDontDraw +is one, +no line or curve is drawn from the previous vertex to this one. +This is analogous to picking up the pen and moving to another place +before drawing another line. +.IP \(bu 5 +If +.PN VertexCurved +is one, +a spline algorithm is used to draw a smooth curve from the previous vertex +through this one to the next vertex. +Otherwise, a straight line is drawn from the previous vertex to this one. +It makes sense to set +.PN VertexCurved +to one only if a previous and next vertex are both defined +(either explicitly in the array or through the definition of a closed +curve). +.IP \(bu 5 +It is permissible for +.PN VertexDontDraw +bits and +.PN VertexCurved +bits both to be one. +This is useful if you want to define the previous point for the smooth curve +but do not want an actual curve drawing to start until this point. +.IP \(bu 5 +If +.PN VertexStartClosed +is one, +then this point marks the beginning of a closed curve. +This vertex must be followed later in the array by another vertex +whose effective coordinates are identical +and that has a +.PN VertexEndClosed +bit of one. +The points in between form a cycle to determine predecessor +and successor vertices for the spline algorithm. +.LP +This function uses these GC components: +function, plane-mask, line-width, line-style, cap-style, join-style, +fill-style, subwindow-mode, clip-x-origin, clip-y-origin, and +clip-mask. +It also uses these GC mode-dependent components: +foreground, background, tile, stipple, +tile-stipple-x-origin, tile-stipple-y-origin, dash-offset, and dash-list. +.LP +.sp +To achieve the effects of the X Version 10 +.PN XDrawTiled +.IN "X10 compatibility" "XDrawTiled" +and +.PN XDrawFilled , +.IN "X10 compatibility" "XDrawFilled" +use +.PN XDrawFilled . +.IN "XDrawFilled" "" "@DEF@" +.sM +.FD 0 +#include + +Status XDrawFilled(\^\fIdisplay\fP, \fId\fP, \fIgc\fP, \fIvlist\fP, \fIvcount\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Drawable \fId\fP\^; +.br + GC \fIgc\fP\^; +.br + Vertex *\fIvlist\fP\^; +.br + int \fIvcount\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fId\fP 1i +Specifies the drawable. +.IP \fIgc\fP 1i +Specifies the GC. +.IP \fIvlist\fP 1i +Specifies a pointer to the list of vertices that indicate what to draw. +.IP \fIvcount\fP 1i +Specifies how many vertices are in vlist. +.LP +.eM +The +.PN XDrawFilled +function draws arbitrary polygons or curves and then fills them. +.LP +This function uses these GC components: +function, plane-mask, line-width, line-style, cap-style, join-style, +fill-style, subwindow-mode, clip-x-origin, clip-y-origin, and +clip-mask. +It also uses these GC mode-dependent components: +foreground, background, tile, stipple, +tile-stipple-x-origin, tile-stipple-y-origin, +dash-offset, dash-list, fill-style, and fill-rule. +.SH +Associating User Data with a Value +.LP +These functions have been superseded by the context management functions +(see section 16.10). +It is often necessary to associate arbitrary information with resource IDs. +Xlib provides the +.PN XAssocTable +functions that you can use to make such an association. +.IN "Hash Lookup" +.IN "Window" "IDs" +.IN "Resource IDs" +Application programs often need to be able to easily refer to +their own data structures when an event arrives. +The +.PN XAssocTable +system provides users of the X library with a method +for associating their own data structures with X resources +.Pn ( Pixmaps , +.PN Fonts , +.PN Windows , +and so on). +.LP +An +.PN XAssocTable +can be used to type X resources. +For example, the user +may want to have three or four types of windows, +each with different properties. +This can be accomplished by associating each X window ID +with a pointer to a window property data structure defined by the +user. +A generic type has been defined in the X library for resource IDs. +It is called an XID. +.LP +There are a few guidelines that should be observed when using an +.PN XAssocTable : +.IP \(bu 5 +All XIDs are relative to the specified display. +.IP \(bu 5 +Because of the hashing scheme used by the association mechanism, +the following rules for determining the size of a +.PN XAssocTable +should be followed. +Associations will be made and looked up more +efficiently if the table size (number of buckets in the hashing +system) is a power of two and if there are not more than 8 XIDs per +bucket. +.LP +.sp +To return a pointer to a new +.PN XAssocTable , +use +.PN XCreateAssocTable . +.IN "XCreateAssocTable" "" "@DEF@" +.sM +.FD 0 +XAssocTable *XCreateAssocTable\^(\^\fIsize\fP\^) +.br + int \fIsize\fP\^; +.FN +.IP \fIsize\fP 1i +Specifies the number of buckets in the hash system of +.PN XAssocTable . +.LP +.eM +The size argument specifies the number of buckets in the +hash system of +.PN XAssocTable . +For reasons of efficiency the number of buckets +should be a power of two. +Some size suggestions might be: use 32 buckets per 100 objects, +and a reasonable maximum number of objects per buckets is 8. +If an error allocating memory for the +.PN XAssocTable +occurs, +a NULL pointer is returned. +.LP +.sp +To create an entry in a given +.PN XAssocTable , +use +.PN XMakeAssoc . +.IN "XMakeAssoc" "" "@DEF@" +.sM +.FD 0 +XMakeAssoc\^(\^\fIdisplay\fP, \fItable\fP\^, \fIx_id\fP\^, \fIdata\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + XAssocTable *\fItable\fP\^; +.br + XID \fIx_id\fP\^; +.br + char *\fIdata\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fItable\fP 1i +Specifies the assoc table. +.IP \fIx_id\fP 1i +Specifies the X resource ID. +.IP \fIdata\fP 1i +Specifies the data to be associated with the X resource ID. +.LP +.eM +The +.PN XMakeAssoc +function inserts data into an +.PN XAssocTable +keyed on an XID. +Data is inserted into the table only once. +Redundant inserts are ignored. +The queue in each association bucket is sorted from the lowest XID to +the highest XID. +.LP +.sp +To obtain data from a given +.PN XAssocTable , +use +.PN XLookUpAssoc . +.IN "XLookUpAssoc" "" "@DEF@" +.sM +.FD 0 +char *XLookUpAssoc\^(\^\fIdisplay\fP, \fItable\fP\^, \fIx_id\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + XAssocTable *\fItable\fP\^; +.br + XID \fIx_id\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fItable\fP 1i +Specifies the assoc table. +.IP \fIx_id\fP 1i +Specifies the X resource ID. +.LP +.eM +The +.PN XLookUpAssoc +function retrieves the data stored in an +.PN XAssocTable +by its XID. +If an appropriately matching XID can be found in the table, +.PN XLookUpAssoc +returns the data associated with it. +If the x_id cannot be found in the table, +it returns NULL. +.LP +.sp +To delete an entry from a given +.PN XAssocTable , +use +.PN XDeleteAssoc . +.IN "XDeleteAssoc" "" "@DEF@" +.sM +.FD 0 +XDeleteAssoc\^(\^\fIdisplay\fP, \fItable\fP\^, \fIx_id\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + XAssocTable *\fItable\fP\^; +.br + XID \fIx_id\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fItable\fP 1i +Specifies the assoc table. +.IP \fIx_id\fP 1i +Specifies the X resource ID. +.LP +.eM +The +.PN XDeleteAssoc +function deletes an association in an +.PN XAssocTable +keyed on its XID. +Redundant deletes (and deletes of nonexistent XIDs) are ignored. +Deleting associations in no way impairs the performance of an +.PN XAssocTable . +.LP +.sp +To free the memory associated with a given +.PN XAssocTable , +use +.PN XDestroyAssocTable . +.IN "XDestroyAssocTable" "" "@DEF@" +.sM +.FD 0 +XDestroyAssocTable\^(\^\fItable\fP\^) +.br + XAssocTable *\fItable\fP\^; +.FN +.IP \fItable\fP 1i +Specifies the assoc table. +.LP +.eM +.bp diff --git a/libX11/specs/libX11/CH01 b/libX11/specs/libX11/CH01 new file mode 100644 index 000000000..765e4b5fb --- /dev/null +++ b/libX11/specs/libX11/CH01 @@ -0,0 +1,663 @@ +.\" Copyright \(co 1985, 1986, 1987, 1988, 1989, 1990, 1991, 1994, 1996 X Consortium +.\" +.\" 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 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 X CONSORTIUM 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 X Consortium 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 X Consortium. +.\" +.\" Copyright \(co 1985, 1986, 1987, 1988, 1989, 1990, 1991 by +.\" Digital Equipment Corporation +.\" +.\" Portions Copyright \(co 1990, 1991 by +.\" Tektronix, Inc. +.\" +.\" Permission to use, copy, modify and distribute this documentation for +.\" any purpose and without fee is hereby granted, provided that the above +.\" copyright notice appears in all copies and that both that copyright notice +.\" and this permission notice appear in all copies, and that the names of +.\" Digital and Tektronix not be used in in advertising or publicity pertaining +.\" to this documentation without specific, written prior permission. +.\" Digital and Tektronix makes no representations about the suitability +.\" of this documentation for any purpose. +.\" It is provided ``as is'' without express or implied warranty. +.\" +.EH '\fBXlib \- C Library\fP''\fB\*(xV\fP' +.OH '\fBXlib \- C Library\fP''\fB\*(xV\fP' +.EF ''\fB % \fP'' +.OF ''\fB % \fP'' +.hw WM_NORMAL_HINTS +\& +.sp 1 +.ce 3 +\s+1\fBChapter 1\fP\s-1 + +\s+1\fBIntroduction to Xlib\fP\s-1 +.sp 2 +.if \n(GS .nr nh*hl 1 +.nr H1 1 +.nr H2 0 +.nr H3 0 +.nr H4 0 +.nr H5 0 +.na +.LP +.XS +Chapter 1: Introduction to Xlib +.XE +The X Window System is a network-transparent window system +that was designed at MIT. +X display servers run on computers with either monochrome or color +bitmap display hardware. +The server distributes user input to and accepts output requests from various +client programs located either on the same machine or elsewhere in +the network. +Xlib is a C subroutine library that application programs (clients) +use to interface with the window system by means of a stream connection. +Although a client usually runs on the same machine as the X server +it is talking to, this need not be the case. +.LP +\fIXlib \- C Language X Interface\fP is a reference guide to the low-level +C language interface to the X Window System protocol. +It is neither a tutorial nor a user's guide to programming the X Window System. +Rather, it provides a detailed description of each function in the library +as well as a discussion of the related background information. +\fIXlib \- C Language X Interface\fP assumes a basic understanding of a graphics +window system and of the C programming language. +Other higher-level abstractions +(for example, those provided by the toolkits for X) +are built on top of the Xlib library. +For further information about these higher-level libraries, +see the appropriate toolkit documentation. +The \fIX Window System Protocol\fP provides the definitive word on the +behavior of X. +Although additional information appears here, +the protocol document is the ruling document. +.LP +To provide an introduction to X programming, +this chapter discusses: +.IP \(bu 5 +Overview of the X Window System +.IP \(bu 5 +Errors +.IP \(bu 5 +Standard header files +.IP \(bu 5 +Generic values and types +.IP \(bu 5 +Naming and argument conventions within Xlib +.IP \(bu 5 +Programming considerations +.IP \(bu 5 +Character sets and encodings +.IP \(bu 5 +Formatting conventions +.NH 2 +Overview of the X Window System +.XS +\*(SN Overview of the X Window System +.XE +.LP +Some of the terms used in this book are unique to X, +and other terms that are common to other window systems +have different meanings in X. +You may find it helpful to refer to the glossary, +which is located at the end of the book. +.LP +The X Window System supports one or more screens containing +overlapping windows or subwindows. +A screen is a physical monitor and hardware +that can be color, grayscale, or monochrome. +There can be multiple screens for each display or workstation. +A single X server can provide display services for any number of screens. +A set of screens for a single user with one keyboard and one pointer +(usually a mouse) is called a display. +.LP +.IN "Screen" +All the windows in an X server are arranged in strict hierarchies. +At the top of each hierarchy is a root window, +which covers each of the display screens. +Each root window is partially or completely covered by child windows. +All windows, except for root windows, have parents. +There is usually at least one window for each application program. +.IN "Child window" +.IN "Parent Window" +Child windows may in turn have their own children. +In this way, +an application program can create an arbitrarily deep tree +on each screen. +X provides graphics, text, and raster operations for windows. +.LP +A child window can be larger than its parent. +That is, part or all of +the child window can extend beyond the boundaries of the parent, +but all output to a window is clipped by its parent. +.IN "Stacking order" +If several children of a window have overlapping locations, +one of the children is considered to be on top of or raised over the +others, thus obscuring them. +Output to areas covered by other windows is suppressed by the window +system unless the window has backing store. +If a window is obscured by a second window, +the second window obscures only those ancestors of the second window +that are also ancestors of the first window. +.LP +.IN "Window" "" "@DEF@" +A window has a border zero or more pixels in width, which can +be any pattern (pixmap) or solid color you like. +A window usually but not always has a background pattern, +which will be repainted by the window system when uncovered. +Child windows obscure their parents, +and graphic operations in the parent window usually +are clipped by the children. +.LP +Each window and pixmap has its own coordinate system. +The coordinate system has the X axis horizontal and the Y axis vertical +with the origin [0, 0] at the upper-left corner. +Coordinates are integral, +in terms of pixels, +and coincide with pixel centers. +For a window, +the origin is inside the border at the inside, upper-left corner. +.LP +X does not guarantee to preserve the contents of windows. +When part or all of a window is hidden and then brought back onto the screen, +its contents may be lost. +The server then sends the client program an +.PN Expose +event to notify it that part or all of the window needs to be repainted. +Programs must be prepared to regenerate the contents of windows on demand. +.LP +.IN "Pixmap" +.IN "Drawable" +.IN "Tile" +.IN "Bitmap" +X also provides off-screen storage of graphics objects, +called pixmaps. +Single plane (depth 1) pixmaps are sometimes referred to as bitmaps. +Pixmaps can be used in most graphics functions interchangeably with +windows and are used in various graphics operations to define patterns or tiles. +Windows and pixmaps together are referred to as drawables. +.LP +Most of the functions in Xlib just add requests to an output buffer. +These requests later execute asynchronously on the X server. +Functions that return values of information stored in +the server do not return (that is, they block) +until an explicit reply is received or an error occurs. +You can provide an error handler, +which will be called when the error is reported. +.LP +.IN "XSync" +If a client does not want a request to execute asynchronously, +it can follow the request with a call to +.PN XSync , +which blocks until all previously buffered +asynchronous events have been sent and acted on. +As an important side effect, +the output buffer in Xlib is always flushed by a call to any function +that returns a value from the server or waits for input. +.LP +.IN "Resource IDs" +.IN "Resource IDs" "Window" +.IN "Resource IDs" "Font" +.IN "Resource IDs" "Pixmap" +.IN "Resource IDs" "Cursor" +.IN "Resource IDs" "GContext" +Many Xlib functions will return an integer resource ID, +which allows you to refer to objects stored on the X server. +These can be of type +.PN Window , +.PN Font , +.PN Pixmap , +.PN Colormap , +.PN Cursor , +and +.PN GContext , +as defined in the file +.hN X11/X.h . +These resources are created by requests and are destroyed +(or freed) by requests or when connections are closed. +Most of these resources are potentially sharable between +applications, and in fact, windows are manipulated explicitly by +window manager programs. +Fonts and cursors are shared automatically across multiple screens. +Fonts are loaded and unloaded as needed and are shared by multiple clients. +Fonts are often cached in the server. +Xlib provides no support for sharing graphics contexts between applications. +.LP +.IN "Event" +Client programs are informed of events. +Events may either be side effects of a request (for example, restacking windows +generates +.PN Expose +events) or completely asynchronous (for example, from the keyboard). +A client program asks to be informed of events. +Because other applications can send events to your application, +programs must be prepared to handle (or ignore) events of all types. +.LP +Input events (for example, a key pressed or the pointer moved) +arrive asynchronously from the server and are queued until they are +requested by an explicit call (for example, +.PN XNextEvent +or +.PN XWindowEvent ). +In addition, some library +functions (for example, +.PN XRaiseWindow ) +generate +.PN Expose +and +.PN ConfigureRequest +events. +These events also arrive asynchronously, but the client may +.IN "XSync" +wish to explicitly wait for them by calling +.PN XSync +after calling a function that can cause the server to generate events. +.NH 2 +Errors +.XS +\*(SN Errors +.XE +.LP +Some functions return +.PN Status , +an integer error indication. +If the function fails, it returns a zero. +If the function returns a status of zero, +it has not updated the return arguments. +.IN "Status" +Because C does not provide multiple return values, +many functions must return their results by writing into client-passed storage. +.IN "Error" "handling" +By default, errors are handled either by a standard library function +or by one that you provide. +Functions that return pointers to strings return NULL pointers if +the string does not exist. +.LP +The X server reports protocol errors at the time that it detects them. +If more than one error could be generated for a given request, +the server can report any of them. +.LP +Because Xlib usually does not transmit requests to the server immediately +(that is, it buffers them), errors can be reported much later than they +actually occur. +For debugging purposes, however, +Xlib provides a mechanism for forcing synchronous behavior +(see section 11.8.1). +When synchronization is enabled, +errors are reported as they are generated. +.LP +When Xlib detects an error, +it calls an error handler, +which your program can provide. +If you do not provide an error handler, +the error is printed, and your program terminates. +.NH 2 +Standard Header Files +.XS +\*(SN Standard Header Files +.XE +.LP +The following include files are part of the Xlib standard: +.IP \(bu 5 +.hN X11/Xlib.h +.IP +This is the main header file for Xlib. +The majority of all Xlib symbols are declared by including this file. +This file also contains the preprocessor symbol +.PN XlibSpecificationRelease . +.IN "XlibSpecificationRelease" "" "@DEF@" +This symbol is defined to have the 6 in this release of the standard. +(Release 5 of Xlib was the first release to have this symbol.) +.IP \(bu 5 +.hN X11/X.h +.IP +This file declares types and constants for the X protocol that are +to be used by applications. +It is included automatically from +.hN X11/Xlib.h , +so application code should never need to reference this file directly. +.IP \(bu 5 +.hN X11/Xcms.h +.IP +This file contains symbols for much of the color management facilities +described in chapter 6. +All functions, types, and symbols with the prefix ``Xcms'', +plus the Color Conversion Contexts macros, are declared in this file. +.hN X11/Xlib.h +must be included before including this file. +.IP \(bu 5 +.hN X11/Xutil.h +.IP +This file declares various functions, types, and symbols used for +inter-client communication and application utility functions, +which are described in chapters 14 and 16. +.hN X11/Xlib.h +must be included before including this file. +.IP \(bu 5 +.hN X11/Xresource.h +.IP +This file declares all functions, types, and symbols for the +resource manager facilities, which are described in chapter 15. +.hN X11/Xlib.h +must be included before including this file. +.IP \(bu 5 +.hN X11/Xatom.h +.IP +This file declares all predefined atoms, +which are symbols with the prefix ``XA_''. +.IP \(bu 5 +.hN X11/cursorfont.h +.IP +This file declares the cursor symbols for the standard cursor font, +which are listed in appendix B. +All cursor symbols have the prefix ``XC_''. +.IP \(bu 5 +.hN X11/keysymdef.h +.IP +This file declares all standard KeySym values, +which are symbols with the prefix ``XK_''. +The KeySyms are arranged in groups, and a preprocessor symbol controls +inclusion of each group. The preprocessor symbol must be defined +prior to inclusion of the file to obtain the associated values. +The preprocessor symbols are XK_MISCELLANY, XK_XKB_KEYS, XK_3270, +XK_LATIN1, XK_LATIN2, +XK_LATIN3, XK_LATIN4, XK_KATAKANA, XK_ARABIC, XK_CYRILLIC, XK_GREEK, +XK_TECHNICAL, XK_SPECIAL, XK_PUBLISHING, XK_APL, XK_HEBREW, +XK_THAI, and XK_KOREAN. +.IP \(bu 5 +.hN X11/keysym.h +.IP +This file defines the preprocessor symbols +XK_MISCELLANY, XK_XKB_KEYS, XK_LATIN1, XK_LATIN2, XK_LATIN3, +XK_LATIN4, and XK_GREEK +and then includes +.hN X11/keysymdef.h . +.IP \(bu 5 +.hN X11/Xlibint.h +.IP +This file declares all the functions, types, and symbols used for +extensions, which are described in appendix C. +This file automatically includes +.hN X11/Xlib.h . +.IP \(bu 5 +.hN X11/Xproto.h +.IP +This file declares types and symbols for the basic X protocol, +for use in implementing extensions. +It is included automatically from +.hN X11/Xlibint.h , +so application and extension code should never need to +reference this file directly. +.IP \(bu 5 +.hN X11/Xprotostr.h +.IP +This file declares types and symbols for the basic X protocol, +for use in implementing extensions. +It is included automatically from +.hN X11/Xproto.h , +so application and extension code should never need to +reference this file directly. +.IP \(bu 5 +.hN X11/X10.h +.IP +This file declares all the functions, types, and symbols used for the +X10 compatibility functions, which are described in appendix D. +.NH 2 +Generic Values and Types +.XS +\*(SN Generic Values and Types +.XE +.LP +The following symbols are defined by Xlib and used throughout the manual: +.IN "Bool" "" "@DEF@" +.IN "True" "" "@DEF@" +.IN "False" "" "@DEF@" +.IP \(bu 5 +Xlib defines the type +.PN Bool +and the Boolean values +.PN True +and +.PN False . +.IN "None" "" "@DEF@" +.IP \(bu 5 +.PN None +is the universal null resource ID or atom. +.IN "XID" "" "@DEF@" +.IP \(bu 5 +The type +.PN XID +is used for generic resource IDs. +.IN "XPointer" "" "@DEF@" +.IP \(bu 5 +The type +.PN XPointer +is defined to be char\^* and is used as a generic opaque pointer to data. +.NH 2 +Naming and Argument Conventions within Xlib +.XS +\*(SN Naming and Argument Conventions within Xlib +.XE +.LP +Xlib follows a number of conventions for the naming and syntax of the functions. +Given that you remember what information the function requires, +these conventions are intended to make the syntax of the functions more +predictable. +.LP +The major naming conventions are: +.IP \(bu 5 +To differentiate the X symbols from the other symbols, +the library uses mixed case for external symbols. +It leaves lowercase for variables and all uppercase for user macros, +as per existing convention. +.IP \(bu 5 +All Xlib functions begin with a capital X. +.IP \(bu 5 +The beginnings of all function names and symbols are capitalized. +.IP \(bu 5 +All user-visible data structures begin with a capital X. +More generally, +anything that a user might dereference begins with a capital X. +.IP \(bu 5 +Macros and other symbols do not begin with a capital X. +To distinguish them from all user symbols, +each word in the macro is capitalized. +.IP \(bu 5 +All elements of or variables in a data structure are in lowercase. +Compound words, where needed, are constructed with underscores (\^_\^). +.IP \(bu 5 +The display argument, where used, is always first in the argument list. +.IP \(bu 5 +All resource objects, where used, occur at the beginning of the argument list +immediately after the display argument. +.IP \(bu 5 +When a graphics context is present together with +another type of resource (most commonly, a drawable), the +graphics context occurs in the argument list after the other +resource. +Drawables outrank all other resources. +.IP \(bu 5 +Source arguments always precede the destination arguments in the argument list. +.IP \(bu 5 +The x argument always precedes the y argument in the argument list. +.IP \(bu 5 +The width argument always precedes the height argument in the argument list. +.IP \(bu 5 +Where the x, y, width, and height arguments are used together, +the x and y arguments always precede the width and height arguments. +.IP \(bu 5 +Where a mask is accompanied with a structure, +the mask always precedes the pointer to the structure in the argument list. +.NH 2 +Programming Considerations +.XS +\*(SN Programming Considerations +.XE +.LP +The major programming considerations are: +.IP \(bu 5 +Coordinates and sizes in X are actually 16-bit quantities. +This decision was made to minimize the bandwidth required for a +given level of performance. +Coordinates usually are declared as an +.PN int +in the interface. +Values larger than 16 bits are truncated silently. +Sizes (width and height) are declared as unsigned quantities. +.IP \(bu 5 +Keyboards are the greatest variable between different +manufacturers' workstations. +If you want your program to be portable, +you should be particularly conservative here. +.IP \(bu 5 +Many display systems have limited amounts of off-screen memory. +If you can, you should minimize use of pixmaps and backing +store. +.IP \(bu 5 +The user should have control of his screen real estate. +Therefore, you should write your applications to react to window management +rather than presume control of the entire screen. +What you do inside of your top-level window, however, +is up to your application. +For further information, +see chapter 14 +and the \fIInter-Client Communication Conventions Manual\fP. +.NH 2 +Character Sets and Encodings +.XS +\*(SN Character Sets and Encodings +.XE +.LP +Some of the Xlib functions make reference to specific character sets +and character encodings. +The following are the most common: +.IP \(bu 5 +X Portable Character Set +.IP +A basic set of 97 characters, +which are assumed to exist in all locales supported by Xlib. +This set contains the following characters: +.IP +.Ds 0 +.EQ +delim DD +.EN +a..z A..Z 0..9 +!"#$%&'()*+,-./:;<=>?@[\\]^_`{|}~ +, , and +.EQ +delim %% +.EN +.De +.IP +This set is the left/lower half +of the graphic character set of ISO8859-1 plus space, tab, and newline. +It is also the set of graphic characters in 7-bit ASCII plus the same +three control characters. +The actual encoding of these characters on the host is system dependent. +.IP \(bu 5 +Host Portable Character Encoding +.IP +The encoding of the X Portable Character Set on the host. +The encoding itself is not defined by this standard, +but the encoding must be the same in all locales supported by Xlib on the host. +If a string is said to be in the Host Portable Character Encoding, +then it only contains characters from the X Portable Character Set, +in the host encoding. +.IP \(bu 5 +Latin-1 +.IP +The coded character set defined by the ISO8859-1 standard. +.IP \(bu 5 +Latin Portable Character Encoding +.IP +The encoding of the X Portable Character Set using the Latin-1 codepoints +plus ASCII control characters. +If a string is said to be in the Latin Portable Character Encoding, +then it only contains characters from the X Portable Character Set, +not all of Latin-1. +.IP \(bu 5 +STRING Encoding +.IP +Latin-1, plus tab and newline. +.IP \(bu 5 +POSIX Portable Filename Character Set +.IP +The set of 65 characters, +which can be used in naming files on a POSIX-compliant host, +that are correctly processed in all locales. +The set is: +.IP +.Ds 0 +a..z A..Z 0..9 ._- +.De +.NH 2 +Formatting Conventions +.XS +\*(SN Formatting Conventions +.XE +.LP +\fIXlib \- C Language X Interface\fP uses the following conventions: +.IP \(bu 5 +Global symbols are printed in +.PN this +.PN special +.PN font . +These can be either function names, +symbols defined in include files, or structure names. +When declared and defined, +function arguments are printed in \fIitalics\fP. +In the explanatory text that follows, +they usually are printed in regular type. +.IP \(bu 5 +Each function is introduced by a general discussion that +distinguishes it from other functions. +The function declaration itself follows, +and each argument is specifically explained. +Although ANSI C function prototype syntax is not used, +Xlib header files normally declare functions using function prototypes +in ANSI C environments. +General discussion of the function, if any is required, +follows the arguments. +Where applicable, +the last paragraph of the explanation lists the possible +Xlib error codes that the function can generate. +For a complete discussion of the Xlib error codes, +see section 11.8.2. +.IP \(bu 5 +To eliminate any ambiguity between those arguments that you pass and those that +a function returns to you, +the explanations for all arguments that you pass start with the word +\fIspecifies\fP or, in the case of multiple arguments, the word \fIspecify\^\fP. +The explanations for all arguments that are returned to you start with the +word \fIreturns\fP or, in the case of multiple arguments, the word \fIreturn\^\fP. +The explanations for all arguments that you can pass and are returned start +with the words \fIspecifies and returns\^\fP. +.IP \(bu 5 +Any pointer to a structure that is used to return a value is designated as +such by the \fI_return\fP suffix as part of its name. +All other pointers passed to these functions are +used for reading only. +A few arguments use pointers to structures that are used for +both input and output and are indicated by using the \fI_in_out\fP suffix. +.bp diff --git a/libX11/specs/libX11/CH02 b/libX11/specs/libX11/CH02 new file mode 100644 index 000000000..61554b898 --- /dev/null +++ b/libX11/specs/libX11/CH02 @@ -0,0 +1,2052 @@ +.\" Copyright \(co 1985, 1986, 1987, 1988, 1989, 1990, 1991, 1994, 1996, 2000 The Open Group +.\" +.\" 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 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 X CONSORTIUM 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. +.\" +.\" Copyright \(co 1985, 1986, 1987, 1988, 1989, 1990, 1991 by +.\" Digital Equipment Corporation +.\" +.\" Portions Copyright \(co 1990, 1991 by +.\" Tektronix, Inc. +.\" +.\" Permission to use, copy, modify and distribute this documentation for +.\" any purpose and without fee is hereby granted, provided that the above +.\" copyright notice appears in all copies and that both that copyright notice +.\" and this permission notice appear in all copies, and that the names of +.\" Digital and Tektronix not be used in in advertising or publicity pertaining +.\" to this documentation without specific, written prior permission. +.\" Digital and Tektronix makes no representations about the suitability +.\" of this documentation for any purpose. +.\" It is provided ``as is'' without express or implied warranty. +.\" +.\" $XFree86$ +\& +.sp 1 +.ce 3 +\s+1\fBChapter 2\fP\s-1 + +\s+1\fBDisplay Functions\fP\s-1 +.sp 2 +.nr H1 2 +.nr H2 0 +.nr H3 0 +.nr H4 0 +.nr H5 0 +.na +.LP +.XS +Chapter 2: Display Functions +.XE +Before your program can use a display, you must establish a connection +to the X server. +Once you have established a connection, +you then can use the Xlib macros and functions discussed in this chapter +to return information about the display. +This chapter discusses how to: +.IP \(bu 5 +Open (connect to) the display +.IP \(bu 5 +Obtain information about the display, image formats, or screens +.IP \(bu 5 +Generate a +.PN NoOperation +protocol request +.IP \(bu 5 +Free client-created data +.IP \(bu 5 +Close (disconnect from) a display +.IP \(bu 5 +Use X Server connection close operations +.IP \(bu 5 +Use Xlib with threads +.IP \(bu 5 +Use internal connections +.NH 2 +Opening the Display +.XS +\*(SN Opening the Display +.XE +.LP +To open a connection to the X server that controls a display, use +.PN XOpenDisplay . +.IN "XOpenDisplay" "" "@DEF@" +.LP +.sM +.FD 0 +Display *XOpenDisplay\^(\^\fIdisplay_name\fP\^) +.br + char *\fIdisplay_name\fP\^; +.FN +.IP \fIdisplay_name\fP 1i +Specifies the hardware display name, which determines the display +and communications domain to be used. +On a POSIX-conformant system, if the display_name is NULL, +it defaults to the value of the DISPLAY environment variable. +.IN "Environment" "DISPLAY" +.LP +.eM +The encoding and interpretation of the display name are +implementation-dependent. +Strings in the Host Portable Character Encoding are supported; +support for other characters is implementation-dependent. +On POSIX-conformant systems, +the display name or DISPLAY environment variable can be a string in the format: +.LP +.sM +.Ds 0 +.TA 1i +.ta 1i + \fIprotocol\fP\^/\^\fIhostname\fP\^:\^\fInumber\fP\^.\^\fIscreen_number\fP +.De +.IP \fIprotocol\fP 1i +Specifies a protocol family or an alias for a protocol family. Supported +protocol families are implementation dependent. The protocol entry is +optional. If protocol is not specified, the / separating protocol and +hostname must also not be specified. +.IP \fIhostname\fP 1i +Specifies the name of the host machine on which the display is physically +attached. +You follow the hostname with either a single colon (:) or a double colon (::). +.IP \fInumber\fP 1i +Specifies the number of the display server on that host machine. +You may optionally follow this display number with a period (.). +A single CPU can have more than one display. +Multiple displays are usually numbered starting with zero. +.IN "Screen" +.IP \fIscreen_number\fP 1i +Specifies the screen to be used on that server. +Multiple screens can be controlled by a single X server. +The screen_number sets an internal variable that can be accessed by +using the +.PN DefaultScreen +macro or the +.PN XDefaultScreen +function if you are using languages other than C (see section 2.2.1). +.LP +.eM +For example, the following would specify screen 1 of display 0 on the +machine named ``dual-headed'': +.LP +.Ds +dual-headed:0.1 +.De +.LP +The +.PN XOpenDisplay +function returns a +.PN Display +structure that serves as the +connection to the X server and that contains all the information +about that X server. +.PN XOpenDisplay +connects your application to the X server through TCP +or DECnet communications protocols, +or through some local inter-process communication protocol. +.IN "Protocol" "TCP" +.IN "Protocol" "DECnet" +If the protocol is specified as "tcp", "inet", or "inet6", or +if no protocol is specified and the hostname is a host machine name and a single colon (:) +separates the hostname and display number, +.PN XOpenDisplay +connects using TCP streams. (If the protocol is specified as "inet", TCP over +IPv4 is used. If the protocol is specified as "inet6", TCP over IPv6 is used. +Otherwise, the implementation determines which IP version is used.) +If the hostname and protocol are both not specified, +Xlib uses whatever it believes is the fastest transport. +If the hostname is a host machine name and a double colon (::) +separates the hostname and display number, +.PN XOpenDisplay +connects using DECnet. +A single X server can support any or all of these transport mechanisms +simultaneously. +A particular Xlib implementation can support many more of these transport +mechanisms. +.LP +.IN "Display" +If successful, +.PN XOpenDisplay +returns a pointer to a +.PN Display +structure, +which is defined in +.hN X11/Xlib.h . +If +.PN XOpenDisplay +does not succeed, it returns NULL. +After a successful call to +.PN XOpenDisplay , +all of the screens in the display can be used by the client. +The screen number specified in the display_name argument is returned +by the +.PN DefaultScreen +macro (or the +.PN XDefaultScreen +function). +You can access elements of the +.PN Display +and +.PN Screen +structures only by using the information macros or functions. +For information about using macros and functions to obtain information from +the +.PN Display +structure, +see section 2.2.1. +.LP +X servers may implement various types of access control mechanisms +(see section 9.8). +.NH 2 +Obtaining Information about the Display, Image Formats, or Screens +.XS +\*(SN Obtaining Information about the Display, Image Formats, or Screens +.XE +.LP +The Xlib library provides a number of useful macros +and corresponding functions that return data from the +.PN Display +structure. +The macros are used for C programming, +and their corresponding function equivalents are for other language bindings. +This section discusses the: +.IP \(bu 5 +Display macros +.IP \(bu 5 +Image format functions and macros +.IP \(bu 5 +Screen information macros +.LP +.IN "Display" "data structure" +All other members of the +.PN Display +structure (that is, those for which no macros are defined) are private to Xlib +and must not be used. +Applications must never directly modify or inspect these private members of the +.PN Display +structure. +.NT Note +The +.PN XDisplayWidth , +.PN XDisplayHeight , +.PN XDisplayCells , +.PN XDisplayPlanes , +.PN XDisplayWidthMM , +and +.PN XDisplayHeightMM +functions in the next sections are misnamed. +These functions really should be named Screen\fIwhatever\fP +and XScreen\fIwhatever\fP, not Display\fIwhatever\fP or XDisplay\fIwhatever\fP. +Our apologies for the resulting confusion. +.NE +.NH 3 +Display Macros +.XS +\*(SN Display Macros +.XE +.LP +Applications should not directly modify any part of the +.PN Display +and +.PN Screen +structures. +The members should be considered read-only, +although they may change as the result of other operations on the display. +.LP +The following lists the C language macros, +their corresponding function equivalents that are for other language bindings, +and what data both can return. +.LP +.sp +.sM +.FD 0 +AllPlanes +.sp +unsigned long XAllPlanes(\^) +.FN +.LP +.eM +.IN "AllPlanes" "" "@DEF@" +.IN "XAllPlanes" "" "@DEF@" +Both return a value with all bits set to 1 suitable for use in a plane argument to +a procedure. +.LP +.sp +Both +.PN BlackPixel +and +.PN WhitePixel +can be used in implementing a monochrome application. +These pixel values are for permanently allocated entries in the default +colormap. +The actual RGB (red, green, and blue) values are settable on some screens +and, in any case, may not actually be black or white. +The names are intended to convey the expected relative intensity of the colors. +.sM +.FD 0 +BlackPixel\^(\^\fIdisplay\fP\^, \^\fIscreen_number\fP\^) +.sp +unsigned long XBlackPixel\^(\^\fIdisplay\fP\^, \^\fIscreen_number\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + int \fIscreen_number\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIscreen_number\fP 1i +Specifies the appropriate screen number on the host server. +.LP +.eM +.IN "BlackPixel" "" "@DEF@" +.IN "XBlackPixel" "" "@DEF@" +Both return the black pixel value for the specified screen. +.LP +.sp +.sM +.FD 0 +WhitePixel\^(\^\fIdisplay\fP\^, \^\fIscreen_number\fP\^) +.sp +unsigned long XWhitePixel\^(\^\fIdisplay\fP\^, \^\fIscreen_number\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + int \fIscreen_number\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIscreen_number\fP 1i +Specifies the appropriate screen number on the host server. +.LP +.eM +.IN "WhitePixel" "" "@DEF@" +.IN "XWhitePixel" "" "@DEF@" +Both return the white pixel value for the specified screen. +.LP +.sp +.sM +.FD 0 +ConnectionNumber\^(\^\fIdisplay\fP\^) +.sp +int XConnectionNumber\^(\^\fIdisplay\fP\^) +.br + Display *\fIdisplay\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.LP +.eM +.IN "ConnectionNumber" "" "@DEF@" +.IN "XConnectionNumber" "" "@DEF@" +Both return a connection number for the specified display. +On a POSIX-conformant system, +this is the file descriptor of the connection. +.LP +.sp +.sM +.FD 0 +DefaultColormap\^(\^\fIdisplay\fP\^, \^\fIscreen_number\fP\^) +.sp +Colormap XDefaultColormap\^(\^\fIdisplay\fP\^, \^\fIscreen_number\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + int \fIscreen_number\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIscreen_number\fP 1i +Specifies the appropriate screen number on the host server. +.LP +.eM +.IN "DefaultColormap" "" "@DEF@" +.IN "XDefaultColormap" "" "@DEF@" +Both return the default colormap ID for allocation on the specified screen. +Most routine allocations of color should be made out of this colormap. +.LP +.sp +.sM +.FD 0 +DefaultDepth\^(\^\fIdisplay\fP\^, \^\fIscreen_number\fP\^) +.sp +int XDefaultDepth\^(\^\fIdisplay\fP\^, \^\fIscreen_number\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + int \fIscreen_number\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIscreen_number\fP 1i +Specifies the appropriate screen number on the host server. +.LP +.eM +.IN "DefaultDepth" "" "@DEF@" +.IN "XDefaultDepth" "" "@DEF@" +Both return the depth (number of planes) of the default root window for the +specified screen. +Other depths may also be supported on this screen (see +.PN XMatchVisualInfo ). +.LP +.sp +.IN "XListDepths" "" "@DEF@" +To determine the number of depths that are available on a given screen, use +.PN XListDepths . +.sM +.FD 0 +int *XListDepths\^(\^\fIdisplay\fP, \fIscreen_number\fP, \fIcount_return\fP\^) +.br + Display *\fIdisplay\fP; +.br + int \fIscreen_number\fP; +.br + int *\fIcount_return\fP; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIscreen_number\fP 1i +Specifies the appropriate screen number on the host server. +.ds Cn depths +.IP \fIcount_return\fP 1i +Returns the number of \*(Cn. +.LP +.eM +The +.PN XListDepths +function returns the array of depths +that are available on the specified screen. +If the specified screen_number is valid and sufficient memory for the array +can be allocated, +.PN XListDepths +sets count_return to the number of available depths. +Otherwise, it does not set count_return and returns NULL. +To release the memory allocated for the array of depths, use +.PN XFree . +.LP +.sp +.sM +.FD 0 +DefaultGC\^(\^\fIdisplay\fP\^, \^\fIscreen_number\fP\^) +.sp +GC XDefaultGC\^(\^\fIdisplay\fP\^, \^\fIscreen_number\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + int \fIscreen_number\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIscreen_number\fP 1i +Specifies the appropriate screen number on the host server. +.LP +.eM +.IN "DefaultGC" "" "@DEF@" +.IN "XDefaultGC" "" "@DEF@" +Both return the default graphics context for the root window of the +specified screen. +This GC is created for the convenience of simple applications +and contains the default GC components with the foreground and +background pixel values initialized to the black and white +pixels for the screen, respectively. +You can modify its contents freely because it is not used in any Xlib +function. +This GC should never be freed. +.LP +.sp +.sM +.FD 0 +DefaultRootWindow\^(\^\fIdisplay\fP\^) +.sp +Window XDefaultRootWindow\^(\^\fIdisplay\fP\^) +.br + Display *\fIdisplay\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.LP +.eM +.IN "DefaultRootWindow" "" "@DEF@" +.IN "XDefaultRootWindow" "" "@DEF@" +Both return the root window for the default screen. +.LP +.sp +.sM +.FD 0 +DefaultScreenOfDisplay\^(\^\fIdisplay\fP\^) +.sp +Screen *XDefaultScreenOfDisplay\^(\^\fIdisplay\fP\^) +.br + Display *\fIdisplay\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.LP +.eM +.IN "DefaultScreenOfDisplay" "" "@DEF@" +.IN "XDefaultScreenOfDisplay" "" "@DEF@" +Both return a pointer to the default screen. +.LP +.sp +.sM +.FD 0 +ScreenOfDisplay\^(\^\fIdisplay\fP, \fIscreen_number\fP\^) +.sp +Screen *XScreenOfDisplay\^(\^\fIdisplay\fP, \fIscreen_number\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + int \fIscreen_number\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIscreen_number\fP 1i +Specifies the appropriate screen number on the host server. +.LP +.eM +.IN "ScreenOfDisplay" "" "@DEF@" +.IN "XScreenOfDisplay" "" "@DEF@" +Both return a pointer to the indicated screen. +.LP +.sp +.sM +.FD 0 +DefaultScreen\^(\^\fIdisplay\fP\^) +.sp +int XDefaultScreen\^(\^\fIdisplay\fP\^) +.br + Display *\fIdisplay\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.LP +.eM +.IN "DefaultScreen" "" "@DEF@" +.IN "XDefaultScreen" "" "@DEF@" +Both return the default screen number referenced by the +.PN XOpenDisplay +function. +This macro or function should be used to retrieve the screen number +in applications that will use only a single screen. +.LP +.sp +.sM +.FD 0 +DefaultVisual\^(\^\fIdisplay\fP\^, \^\fIscreen_number\fP\^) +.sp +Visual *XDefaultVisual\^(\^\fIdisplay\fP\^, \^\fIscreen_number\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + int \fIscreen_number\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIscreen_number\fP 1i +Specifies the appropriate screen number on the host server. +.LP +.eM +.IN "DefaultVisual" "" "@DEF@" +.IN "XDefaultVisual" "" "@DEF@" +Both return the default visual type for the specified screen. +For further information about visual types, +see section 3.1. +.LP +.sp +.sM +.FD 0 +DisplayCells\^(\^\fIdisplay\fP\^, \^\fIscreen_number\fP\^) +.sp +int XDisplayCells\^(\^\fIdisplay\fP\^, \^\fIscreen_number\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + int \fIscreen_number\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIscreen_number\fP 1i +Specifies the appropriate screen number on the host server. +.LP +.eM +.IN "DisplayCells" "" "@DEF@" +.IN "XDisplayCells" "" "@DEF@" +Both return the number of entries in the default colormap. +.LP +.sp +.sM +.FD 0 +DisplayPlanes\^(\^\fIdisplay\fP\^, \^\fIscreen_number\fP\^) +.sp +int XDisplayPlanes\^(\^\fIdisplay\fP\^, \^\fIscreen_number\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + int \fIscreen_number\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIscreen_number\fP 1i +Specifies the appropriate screen number on the host server. +.LP +.eM +.IN "DisplayPlanes" "" "@DEF@" +.IN "XDisplayPlanes" "" "@DEF@" +Both return the depth of the root window of the specified screen. +For an explanation of depth, +see the glossary. +.LP +.sp +.sM +.FD 0 +DisplayString\^(\^\fIdisplay\fP\^) +.sp +char *XDisplayString\^(\^\fIdisplay\fP\^) +.br + Display *\fIdisplay\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.LP +.eM +.IN "DisplayString" "" "@DEF@" +.IN "XDisplayString" "" "@DEF@" +Both return the string that was passed to +.PN XOpenDisplay +when the current display was opened. +On POSIX-conformant systems, +if the passed string was NULL, these return the value of +the DISPLAY environment variable when the current display was opened. +.IN "POSIX System Call" "fork" +These are useful to applications that invoke the +.PN fork +system call and want to open a new connection to the same display from the +child process as well as for printing error messages. +.LP +.sp +.sM +.FD 0 +long XExtendedMaxRequestSize(\^\fIdisplay\fP\^) + Display *\fIdisplay\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.LP +.eM +.IN "XExtendedMaxRequestSize" "" "@DEF@" +The +.PN XExtendedMaxRequestSize +function returns zero if the specified display does not support an +extended-length protocol encoding; otherwise, +it returns the maximum request size (in 4-byte units) supported +by the server using the extended-length encoding. +The Xlib functions +.PN XDrawLines , +.PN XDrawArcs , +.PN XFillPolygon , +.PN XChangeProperty , +.PN XSetClipRectangles , +and +.PN XSetRegion +will use the extended-length encoding as necessary, if supported +by the server. Use of the extended-length encoding in other Xlib +functions (for example, +.PN XDrawPoints , +.PN XDrawRectangles , +.PN XDrawSegments , +.PN XFillArcs , +.PN XFillRectangles , +.PN XPutImage ) +is permitted but not required; an Xlib implementation may choose to +split the data across multiple smaller requests instead. +.LP +.sp +.sM +.FD 0 +long XMaxRequestSize(\^\fIdisplay\fP\^) + Display *\fIdisplay\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.LP +.eM +.IN "XMaxRequestSize" "" "@DEF@" +The +.PN XMaxRequestSize +function returns the maximum request size (in 4-byte units) supported +by the server without using an extended-length protocol encoding. +Single protocol requests to the server can be no larger than this size +unless an extended-length protocol encoding is supported by the server. +The protocol guarantees the size to be no smaller than 4096 units +(16384 bytes). +Xlib automatically breaks data up into multiple protocol requests +as necessary for the following functions: +.PN XDrawPoints , +.PN XDrawRectangles , +.PN XDrawSegments , +.PN XFillArcs , +.PN XFillRectangles , +and +.PN XPutImage . +.LP +.sp +.sM +.FD 0 +LastKnownRequestProcessed\^(\^\fIdisplay\fP\^) +.sp +unsigned long XLastKnownRequestProcessed\^(\^\fIdisplay\fP\^) +.br + Display *\fIdisplay\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.LP +.eM +.IN "LastKnownRequestProcessed" "" "@DEF@" +.IN "XLastKnownRequestProcessed" "" "@DEF@" +Both extract the full serial number of the last request known by Xlib +to have been processed by the X server. +Xlib automatically sets this number when replies, events, and errors +are received. +.LP +.sp +.sM +.FD 0 +NextRequest\^(\^\fIdisplay\fP\^) +.sp +unsigned long XNextRequest\^(\^\fIdisplay\fP\^) +.br + Display *\fIdisplay\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.LP +.eM +.IN "NextRequest" "" "@DEF@" +.IN "XNextRequest" "" "@DEF@" +Both extract the full serial number that is to be used for the next +request. +Serial numbers are maintained separately for each display connection. +.LP +.sp +.sM +.FD 0 +ProtocolVersion\^(\^\fIdisplay\fP\^) +.sp +int XProtocolVersion\^(\^\fIdisplay\fP\^) +.br + Display *\fIdisplay\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.LP +.eM +.IN "ProtocolVersion" "" "@DEF@" +.IN "XProtocolVersion" "" "@DEF@" +Both return the major version number (11) of the X protocol associated with +the connected display. +.LP +.sp +.sM +.FD 0 +ProtocolRevision\^(\^\fIdisplay\fP\^) +.sp +int XProtocolRevision\^(\^\fIdisplay\fP\^) +.br + Display *\fIdisplay\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.LP +.eM +.IN "ProtocolRevision" "" "@DEF@" +.IN "XProtocolRevision" "" "@DEF@" +Both return the minor protocol revision number of the X server. +.LP +.sp +.sM +.FD 0 +QLength\^(\^\fIdisplay\fP\^) +.sp +int XQLength\^(\^\fIdisplay\fP\^) +.br + Display *\fIdisplay\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.LP +.eM +.IN "QLength" "" "@DEF@" +.IN "XQLength" "" "@DEF@" +Both return the length of the event queue for the connected display. +Note that there may be more events that have not been read into +the queue yet (see +.PN XEventsQueued ). +.LP +.sp +.sM +.FD 0 +RootWindow\^(\^\fIdisplay\fP\^, \^\fIscreen_number\fP\^) +.sp +Window XRootWindow\^(\^\fIdisplay\fP\^, \^\fIscreen_number\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + int \fIscreen_number\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIscreen_number\fP 1i +Specifies the appropriate screen number on the host server. +.LP +.eM +.IN "Window" "RootWindow" +.IN "RootWindow" "" "@DEF@" +.IN "Window" "XRootWindow" +.IN "XRootWindow" "" "@DEF@" +Both return the root window. +These are useful with functions that need a drawable of a particular screen +and for creating top-level windows. +.LP +.sp +.sM +.FD 0 +ScreenCount\^(\^\fIdisplay\fP\^) +.sp +int XScreenCount\^(\^\fIdisplay\fP\^) +.br + Display *\fIdisplay\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.LP +.eM +.IN "ScreenCount" "" "@DEF@" +.IN "XScreenCount" "" "@DEF@" +Both return the number of available screens. +.LP +.sp +.sM +.FD 0 +ServerVendor\^(\^\fIdisplay\fP\^) +.sp +char *XServerVendor\^(\^\fIdisplay\fP\^) +.br + Display *\fIdisplay\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.LP +.eM +.IN "ServerVendor" "" "@DEF@" +.IN "XServerVendor" "" "@DEF@" +Both return a pointer to a null-terminated string that provides +some identification of the owner of the X server implementation. +If the data returned by the server is in the Latin Portable Character Encoding, +then the string is in the Host Portable Character Encoding. +Otherwise, the contents of the string are implementation-dependent. +.LP +.sp +.sM +.FD 0 +VendorRelease\^(\^\fIdisplay\fP\^) +.sp +int XVendorRelease\^(\^\fIdisplay\fP\^) +.br + Display *\fIdisplay\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.LP +.eM +.IN "VendorRelease" "" "@DEF@" +.IN "XVendorRelease" "" "@DEF@" +Both return a number related to a vendor's release of the X server. +.NH 3 +Image Format Functions and Macros +.XS +\*(SN Image Format Functions and Macros +.XE +.LP +Applications are required to present data to the X server +in a format that the server demands. +To help simplify applications, +most of the work required to convert the data is provided by Xlib +(see sections 8.7 and 16.8). +.LP +The +.PN XPixmapFormatValues +structure provides an interface to the pixmap format information +that is returned at the time of a connection setup. +It contains: +.LP +.sM +.Ds 0 +.TA .5i 3i +.ta .5i 3i +typedef struct { + int depth; + int bits_per_pixel; + int scanline_pad; +} XPixmapFormatValues; +.De +.LP +.eM +.sp +To obtain the pixmap format information for a given display, use +.PN XListPixmapFormats . +.IN "XListPixmapFormats" "" "@DEF@" +.sM +.FD 0 +XPixmapFormatValues *XListPixmapFormats\^(\^\fIdisplay\fP, \fIcount_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + int *\fIcount_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.ds Cn pixmap formats that are supported by the display +.IP \fIcount_return\fP 1i +Returns the number of \*(Cn. +.LP +.eM +The +.PN XListPixmapFormats +function returns an array of +.PN XPixmapFormatValues +structures that describe the types of Z format images supported +by the specified display. +If insufficient memory is available, +.PN XListPixmapFormats +returns NULL. +To free the allocated storage for the +.PN XPixmapFormatValues +structures, use +.PN XFree . +.LP +The following lists the C language macros, +their corresponding function equivalents that are for other language bindings, +and what data they both return for the specified server and screen. +These are often used by toolkits as well as by simple applications. +.LP +.sp +.sM +.FD 0 +ImageByteOrder\^(\^\fIdisplay\fP\^) +.sp +int XImageByteOrder\^(\^\fIdisplay\fP\^) +.br + Display *\fIdisplay\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.LP +.eM +.IN "ImageByteOrder" "" "@DEF@" +.IN "XImageByteOrder" "" "@DEF@" +Both specify the required byte order for images for each scanline unit in +XY format (bitmap) or for each pixel value in +Z format. +The macro or function can return either +.PN LSBFirst +or +.PN MSBFirst . +.LP +.sp +.sM +.FD 0 +BitmapUnit\^(\^\fIdisplay\fP\^) +.sp +int XBitmapUnit\^(\^\fIdisplay\fP\^) +.br + Display *\fIdisplay\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.LP +.eM +.IN "BitmapUnit" "" "@DEF@" +.IN "XBitmapUnit" "" "@DEF@" +Both return the size of a bitmap's scanline unit in bits. +The scanline is calculated in multiples of this value. +.LP +.sp +.sM +.FD 0 +BitmapBitOrder\^(\^\fIdisplay\fP\^) +.sp +int XBitmapBitOrder\^(\^\fIdisplay\fP\^) +.br + Display *\fIdisplay\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.LP +.eM +.IN "BitmapBitOrder" "" "@DEF@" +.IN "XBitmapBitOrder" "" "@DEF@" +Within each bitmap unit, the left-most bit in the bitmap as displayed +on the screen is either the least significant or most significant bit in the +unit. +This macro or function can return +.PN LSBFirst +or +.PN MSBFirst . +.LP +.sp +.sM +.FD 0 +BitmapPad\^(\^\fIdisplay\fP\^) +.sp +int XBitmapPad\^(\^\fIdisplay\fP\^) +.br + Display *\fIdisplay\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.LP +.eM +.IN "BitmapPad" "" "@DEF@" +.IN "XBitmapPad" "" "@DEF@" +Each scanline must be padded to a multiple of bits returned +by this macro or function. +.LP +.sp +.sM +.FD 0 +DisplayHeight\^(\^\fIdisplay\fP\^, \^\fIscreen_number\fP\^) +.sp +int XDisplayHeight\^(\^\fIdisplay\fP\^, \^\fIscreen_number\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + int \fIscreen_number\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIscreen_number\fP 1i +Specifies the appropriate screen number on the host server. +.LP +.eM +.IN "DisplayHeight" "" "@DEF@" +.IN "XDisplayHeight" "" "@DEF@" +Both return an integer that describes the height of the screen +in pixels. +.LP +.sp +.sM +.FD 0 +DisplayHeightMM\^(\^\fIdisplay\fP\^, \^\fIscreen_number\fP\^) +.sp +int XDisplayHeightMM\^(\^\fIdisplay\fP\^, \^\fIscreen_number\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + int \fIscreen_number\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIscreen_number\fP 1i +Specifies the appropriate screen number on the host server. +.LP +.eM +.IN "DisplayHeightMM" "" "@DEF@" +.IN "XDisplayHeightMM" "" "@DEF@" +Both return the height of the specified screen in millimeters. +.LP +.sp +.sM +.FD 0 +DisplayWidth\^(\^\fIdisplay\fP\^, \^\fIscreen_number\fP\^) +.sp +int XDisplayWidth\^(\^\fIdisplay\fP\^, \^\fIscreen_number\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + int \fIscreen_number\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIscreen_number\fP 1i +Specifies the appropriate screen number on the host server. +.LP +.eM +.IN "DisplayWidth" "" "@DEF@" +.IN "XDisplayWidth" "" "@DEF@" +Both return the width of the screen in pixels. +.LP +.sp +.sM +.FD 0 +DisplayWidthMM\^(\^\fIdisplay\fP\^, \^\fIscreen_number\fP\^) +.sp +int XDisplayWidthMM\^(\^\fIdisplay\fP\^, \^\fIscreen_number\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + int \fIscreen_number\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIscreen_number\fP 1i +Specifies the appropriate screen number on the host server. +.LP +.eM +.IN "DisplayWidthMM" "" "@DEF@" +.IN "XDisplayWidthMM" "" "@DEF@" +Both return the width of the specified screen in millimeters. +.NH 3 +Screen Information Macros +.XS +\*(SN Screen Information Macros +.XE +.LP +The following lists the C language macros, +their corresponding function equivalents that are for other language bindings, +and what data they both can return. +These macros or functions all take a pointer to the appropriate screen +structure. +.LP +.sp +.sM +.FD 0 +BlackPixelOfScreen\^(\^\fIscreen\fP\^) +.sp +unsigned long XBlackPixelOfScreen\^(\^\fIscreen\fP\^) +.br + Screen *\fIscreen\fP\^; +.FN +.IP \fIscreen\fP 1i +Specifies the appropriate +.PN Screen +structure. +.LP +.eM +.IN "BlackPixelOfScreen" "" "@DEF@" +.IN "XBlackPixelOfScreen" "" "@DEF@" +Both return the black pixel value of the specified screen. +.LP +.sp +.sM +.FD 0 +WhitePixelOfScreen\^(\^\fIscreen\fP\^) +.sp +unsigned long XWhitePixelOfScreen\^(\^\fIscreen\fP\^) +.br + Screen *\fIscreen\fP\^; +.FN +.IP \fIscreen\fP 1i +Specifies the appropriate +.PN Screen +structure. +.LP +.eM +.IN "WhitePixelOfScreen" "" "@DEF@" +.IN "XWhitePixelOfScreen" "" "@DEF@" +Both return the white pixel value of the specified screen. +.LP +.sp +.sM +.FD 0 +CellsOfScreen\^(\^\fIscreen\fP\^) +.sp +int XCellsOfScreen\^(\^\fIscreen\fP\^) +.br + Screen *\fIscreen\fP\^; +.FN +.IP \fIscreen\fP 1i +Specifies the appropriate +.PN Screen +structure. +.LP +.eM +.IN "CellsOfScreen" "" "@DEF@" +.IN "XCellsOfScreen" "" "@DEF@" +Both return the number of colormap cells in the default colormap +of the specified screen. +.LP +.sp +.sM +.FD 0 +DefaultColormapOfScreen\^(\^\fIscreen\fP\^) +.sp +Colormap XDefaultColormapOfScreen\^(\^\fIscreen\fP\^) +.br + Screen *\fIscreen\fP\^; +.FN +.IP \fIscreen\fP 1i +Specifies the appropriate +.PN Screen +structure. +.LP +.eM +.IN "DefaultColormapOfScreen" "" "@DEF@" +.IN "XDefaultColormapOfScreen" "" "@DEF@" +Both return the default colormap of the specified screen. +.LP +.sp +.sM +.FD 0 +DefaultDepthOfScreen\^(\^\fIscreen\fP\^) +.sp +int XDefaultDepthOfScreen\^(\^\fIscreen\fP\^) +.br + Screen *\fIscreen\fP\^; +.FN +.IP \fIscreen\fP 1i +Specifies the appropriate +.PN Screen +structure. +.LP +.eM +.IN "DefaultDepthOfScreen" "" "@DEF@" +.IN "XDefaultDepthOfScreen" "" "@DEF@" +Both return the depth of the root window. +.LP +.sp +.sM +.FD 0 +DefaultGCOfScreen\^(\^\fIscreen\fP\^) +.sp +GC XDefaultGCOfScreen\^(\^\fIscreen\fP\^) +.br + Screen *\fIscreen\fP\^; +.FN +.IP \fIscreen\fP 1i +Specifies the appropriate +.PN Screen +structure. +.LP +.eM +.IN "DefaultGCOfScreen" "" "@DEF@" +.IN "XDefaultGCOfScreen" "" "@DEF@" +Both return a default graphics context (GC) of the specified screen, +which has the same depth as the root window of the screen. +The GC must never be freed. +.LP +.sp +.sM +.FD 0 +DefaultVisualOfScreen\^(\^\fIscreen\fP\^) +.sp +Visual *XDefaultVisualOfScreen\^(\^\fIscreen\fP\^) +.br + Screen *\fIscreen\fP\^; +.FN +.IP \fIscreen\fP 1i +Specifies the appropriate +.PN Screen +structure. +.LP +.eM +.IN "DefaultVisualOfScreen" "" "@DEF@" +.IN "XDefaultVisualOfScreen" "" "@DEF@" +Both return the default visual of the specified screen. +For information on visual types, +see section 3.1. +.LP +.sp +.sM +.FD 0 +DoesBackingStore\^(\^\fIscreen\fP\^) +.sp +int XDoesBackingStore\^(\^\fIscreen\fP\^) +.br + Screen *\fIscreen\fP\^; +.FN +.IP \fIscreen\fP 1i +Specifies the appropriate +.PN Screen +structure. +.LP +.eM +.IN "DoesBackingStore" "" "@DEF@" +.IN "XDoesBackingStore" "" "@DEF@" +Both return a value indicating whether the screen supports backing +stores. +The value returned can be one of +.PN WhenMapped , +.PN NotUseful , +or +.PN Always +(see section 3.2.4). +.LP +.sp +.sM +.FD 0 +DoesSaveUnders\^(\^\fIscreen\fP\^) +.sp +Bool XDoesSaveUnders\^(\^\fIscreen\fP\^) +.br + Screen *\fIscreen\fP\^; +.FN +.IP \fIscreen\fP 1i +Specifies the appropriate +.PN Screen +structure. +.LP +.eM +.IN "DoesSaveUnders" "" "@DEF@" +.IN "XDoesSaveUnders" "" "@DEF@" +Both return a Boolean value indicating whether the +screen supports save unders. +If +.PN True , +the screen supports save unders. +If +.PN False , +the screen does not support save unders (see section 3.2.5). +.LP +.sp +.sM +.FD 0 +DisplayOfScreen\^(\^\fIscreen\fP\^) +.sp +Display *XDisplayOfScreen\^(\^\fIscreen\fP\^) +.br + Screen *\fIscreen\fP\^; +.FN +.IP \fIscreen\fP 1i +Specifies the appropriate +.PN Screen +structure. +.LP +.eM +.IN "DisplayOfScreen" "" "@DEF@" +.IN "XDisplayOfScreen" "" "@DEF@" +Both return the display of the specified screen. +.LP +.sp +.sM +.IN "XScreenNumberOfScreen" "" "@DEF@" +.FD 0 +int XScreenNumberOfScreen\^(\^\fIscreen\fP\^) +.br + Screen *\fIscreen\fP\^; +.FN +.IP \fIscreen\fP 1i +Specifies the appropriate +.PN Screen +structure. +.LP +.eM +The +.PN XScreenNumberOfScreen +function returns the screen index number of the specified screen. +.LP +.sp +.sM +.FD 0 +EventMaskOfScreen\^(\^\fIscreen\fP\^) +.sp +long XEventMaskOfScreen\^(\^\fIscreen\fP\^) +.br + Screen *\fIscreen\fP\^; +.FN +.IP \fIscreen\fP 1i +Specifies the appropriate +.PN Screen +structure. +.LP +.eM +.IN "EventMaskOfScreen" "" "@DEF@" +.IN "XEventMaskOfScreen" "" "@DEF@" +Both return the event mask of the root window for the specified screen +at connection setup time. +.LP +.sp +.sM +.FD 0 +WidthOfScreen\^(\^\fIscreen\fP\^) +.sp +int XWidthOfScreen\^(\^\fIscreen\fP\^) +.br + Screen *\fIscreen\fP\^; +.FN +.IP \fIscreen\fP 1i +Specifies the appropriate +.PN Screen +structure. +.LP +.eM +.IN "WidthOfScreen" "" "@DEF@" +.IN "XWidthOfScreen" "" "@DEF@" +Both return the width of the specified screen in pixels. +.LP +.sp +.sM +.FD 0 +HeightOfScreen\^(\^\fIscreen\fP\^) +.sp +int XHeightOfScreen\^(\^\fIscreen\fP\^) +.br + Screen *\fIscreen\fP\^; +.FN +.IP \fIscreen\fP 1i +Specifies the appropriate +.PN Screen +structure. +.LP +.eM +.IN "HeightOfScreen" "" "@DEF@" +.IN "XHeightOfScreen" "" "@DEF@" +Both return the height of the specified screen in pixels. +.LP +.sp +.sM +.FD 0 +WidthMMOfScreen\^(\^\fIscreen\fP\^) +.sp +int XWidthMMOfScreen\^(\^\fIscreen\fP\^) +.br + Screen *\fIscreen\fP\^; +.FN +.IP \fIscreen\fP 1i +Specifies the appropriate +.PN Screen +structure. +.LP +.eM +.IN "WidthMMOfScreen" "" "@DEF@" +.IN "XWidthMMOfScreen" "" "@DEF@" +Both return the width of the specified screen in millimeters. +.LP +.sp +.sM +.FD 0 +HeightMMOfScreen\^(\^\fIscreen\fP\^) +.sp +int XHeightMMOfScreen\^(\^\fIscreen\fP\^) +.br + Screen *\fIscreen\fP\^; +.FN +.IP \fIscreen\fP 1i +Specifies the appropriate +.PN Screen +structure. +.LP +.eM +.IN "HeightMMOfScreen" "" "@DEF@" +.IN "XHeightMMOfScreen" "" "@DEF@" +Both return the height of the specified screen in millimeters. +.LP +.sp +.sM +.FD 0 +MaxCmapsOfScreen\^(\^\fIscreen\fP\^) +.sp +int XMaxCmapsOfScreen\^(\^\fIscreen\fP\^) +.br + Screen *\fIscreen\fP\^; +.FN +.IP \fIscreen\fP 1i +Specifies the appropriate +.PN Screen +structure. +.LP +.eM +.IN "MaxCmapsOfScreen" "" "@DEF@" +.IN "XMaxCmapsOfScreen" "" "@DEF@" +Both return the maximum number of installed colormaps supported +by the specified screen (see section 9.3). +.LP +.sp +.sM +.FD 0 +MinCmapsOfScreen\^(\^\fIscreen\fP\^) +.sp +int XMinCmapsOfScreen\^(\^\fIscreen\fP\^) +.br + Screen *\fIscreen\fP\^; +.FN +.IP \fIscreen\fP 1i +Specifies the appropriate +.PN Screen +structure. +.LP +.eM +.IN "MinCmapsOfScreen" "" "@DEF@" +.IN "XMinCmapsOfScreen" "" "@DEF@" +Both return the minimum number of installed colormaps supported +by the specified screen (see section 9.3). +.LP +.sp +.sM +.FD 0 +PlanesOfScreen\^(\^\fIscreen\fP\^) +.sp +int XPlanesOfScreen\^(\^\fIscreen\fP\^) +.br + Screen *\fIscreen\fP\^; +.FN +.IP \fIscreen\fP 1i +Specifies the appropriate +.PN Screen +structure. +.LP +.eM +.IN "PlanesOfScreen" "" "@DEF@" +.IN "XPlanesOfScreen" "" "@DEF@" +Both return the depth of the root window. +.LP +.sp +.sM +.FD 0 +RootWindowOfScreen\^(\^\fIscreen\fP\^) +.sp +Window XRootWindowOfScreen\^(\^\fIscreen\fP\^) +.br + Screen *\fIscreen\fP\^; +.FN +.IP \fIscreen\fP 1i +Specifies the appropriate +.PN Screen +structure. +.LP +.eM +.IN "RootWindowOfScreen" "" "@DEF@" +.IN "XRootWindowOfScreen" "" "@DEF@" +Both return the root window of the specified screen. +.NH 2 +Generating a NoOperation Protocol Request +.XS +\*(SN Generating a NoOperation Protocol Request +.XE +.LP +To execute a +.PN NoOperation +protocol request, use +.PN XNoOp . +.IN "XNoOp" "" "@DEF@" +.sM +.FD 0 +XNoOp\^(\^\fIdisplay\fP\^) +.br + Display *\fIdisplay\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.LP +.eM +The +.PN XNoOp +function sends a +.PN NoOperation +protocol request to the X server, +thereby exercising the connection. +.NH 2 +Freeing Client-Created Data +.XS +\*(SN Freeing Client-Created Data +.XE +.LP +To free in-memory data that was created by an Xlib function, use +.PN XFree . +.IN "XFree" "" "@DEF@" +.sM +.FD 0 +XFree\^(\^\fIdata\fP\^) +.br + void *\fIdata\fP\^; +.FN +.IP \fIdata\fP 1i +Specifies the data that is to be freed. +.LP +.eM +The +.PN XFree +function is a general-purpose Xlib routine that frees the specified data. +You must use it to free any objects that were allocated by Xlib, +unless an alternate function is explicitly specified for the object. +A NULL pointer cannot be passed to this function. +.NH 2 +Closing the Display +.XS +\*(SN Closing the Display +.XE +.LP +To close a display or disconnect from the X server, use +.PN XCloseDisplay . +.IN "XCloseDisplay" "" "@DEF@" +.LP +.sM +.FD 0 +XCloseDisplay\^(\fIdisplay\fP\^) +.br + Display *\fIdisplay\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.LP +.eM +The +.PN XCloseDisplay +function closes the connection to the X server for the display specified in the +.PN Display +structure and destroys all windows, resource IDs +.Pn ( Window , +.PN Font , +.PN Pixmap , +.PN Colormap , +.PN Cursor , +and +.PN GContext ), +or other resources that the client has created +on this display, unless the close-down mode of the resource has been changed +(see +.PN XSetCloseDownMode ). +Therefore, these windows, resource IDs, and other resources should never be +referenced again or an error will be generated. +Before exiting, you should call +.PN XCloseDisplay +explicitly so that any pending errors are reported as +.PN XCloseDisplay +performs a final +.PN XSync +operation. +.IN "Resource IDs" +.IN "XCloseDisplay" +.LP +.PN XCloseDisplay +can generate a +.PN BadGC +error. +.sp +.LP +Xlib provides a function to permit the resources owned by a client +to survive after the client's connection is closed. +To change a client's close-down mode, use +.PN XSetCloseDownMode . +.IN "XSetCloseDownMode" "" "@DEF@" +.sM +.FD 0 +XSetCloseDownMode\^(\^\fIdisplay\fP, \fIclose_mode\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + int \fIclose_mode\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIclose_mode\fP 1i +Specifies the client close-down mode. +You can pass +.PN DestroyAll , +.PN RetainPermanent , +or +.PN RetainTemporary . +.LP +.eM +The +.PN XSetCloseDownMode +defines what will happen to the client's resources at connection close. +A connection starts in +.PN DestroyAll +mode. +For information on what happens to the client's resources when the +close_mode argument is +.PN RetainPermanent +or +.PN RetainTemporary , +see section 2.6. +.LP +.PN XSetCloseDownMode +can generate a +.PN BadValue +error. +.NH 2 +Using X Server Connection Close Operations +.XS +\*(SN Using X Server Connection Close Operations +.XE +.LP +When the X server's connection to a client is closed +either by an explicit call to +.PN XCloseDisplay +or by a process that exits, the X server performs the following +automatic operations: +.IP \(bu 5 +It disowns all selections owned by the client +(see +.PN XSetSelectionOwner ). +.IP \(bu 5 +It performs an +.PN XUngrabPointer +and +.PN XUngrabKeyboard +if the client has actively grabbed the pointer +or the keyboard. +.IP \(bu 5 +It performs an +.PN XUngrabServer +if the client has grabbed the server. +.IP \(bu 5 +It releases all passive grabs made by the client. +.IP \(bu 5 +It marks all resources (including colormap entries) allocated +by the client either as permanent or temporary, +depending on whether the close-down mode is +.PN RetainPermanent +or +.PN RetainTemporary . +However, this does not prevent other client applications from explicitly +destroying the resources (see +.PN XSetCloseDownMode ). +.LP +When the close-down mode is +.PN DestroyAll , +the X server destroys all of a client's resources as follows: +.IP \(bu 5 +It examines each window in the client's save-set to determine if it is an inferior +(subwindow) of a window created by the client. +(The save-set is a list of other clients' windows +that are referred to as save-set windows.) +If so, the X server reparents the save-set window to the closest ancestor so +that the save-set window is not an inferior of a window created by the client. +The reparenting leaves unchanged the absolute coordinates (with respect to +the root window) of the upper-left outer corner of the save-set +window. +.IP \(bu 5 +It performs a +.PN MapWindow +request on the save-set window if the save-set window is unmapped. +The X server does this even if the save-set window was not an inferior of +a window created by the client. +.IP \(bu 5 +It destroys all windows created by the client. +.IP \(bu 5 +It performs the appropriate free request on each nonwindow resource created by +the client in the server (for example, +.PN Font , +.PN Pixmap , +.PN Cursor , +.PN Colormap , +and +.PN GContext ). +.IP \(bu 5 +It frees all colors and colormap entries allocated by a client application. +.LP +Additional processing occurs when the last connection to the X server closes. +An X server goes through a cycle of having no connections and having some +connections. +When the last connection to the X server closes as a result of a connection +closing with the close_mode of +.PN DestroyAll , +the X server does the following: +.IP \(bu 5 +It resets its state as if it had just been +started. +The X server begins by destroying all lingering resources from +clients that have terminated in +.PN RetainPermanent +or +.PN RetainTemporary +mode. +.IP \(bu 5 +It deletes all but the predefined atom identifiers. +.IP \(bu 5 +It deletes all properties on all root windows (see section 4.3). +.IP \(bu 5 +It resets all device maps and attributes +(for example, key click, bell volume, and acceleration) +as well as the access control list. +.IP \(bu 5 +It restores the standard root tiles and cursors. +.IP \(bu 5 +It restores the default font path. +.IP \(bu 5 +It restores the input focus to state +.PN PointerRoot . +.LP +However, the X server does not reset if you close a connection with a close-down +mode set to +.PN RetainPermanent +or +.PN RetainTemporary . +.NH 2 +Using Xlib with Threads +.XS +\*(SN Using Xlib with Threads +.XE +.LP +On systems that have threads, support may be provided to permit +multiple threads to use Xlib concurrently. +.LP +.sp +To initialize support for concurrent threads, use +.PN XInitThreads . +.IN "XInitThreads" "" "@DEF@" +.sM +.FD 0 +Status XInitThreads\^(\|); +.FN +.LP +.eM +The +.PN XInitThreads +function initializes Xlib support for concurrent threads. +This function must be the first Xlib function a +multi-threaded program calls, and it must complete +before any other Xlib call is made. +This function returns a nonzero status if initialization was +successful; otherwise, it returns zero. +On systems that do not support threads, this function always returns zero. +.LP +It is only necessary to call this function if multiple threads +might use Xlib concurrently. If all calls to Xlib functions +are protected by some other access mechanism (for example, +a mutual exclusion lock in a toolkit or through explicit client +programming), Xlib thread initialization is not required. +It is recommended that single-threaded programs not call this function. + +.LP +.sp +To lock a display across several Xlib calls, use +.PN XLockDisplay . +.IN "XLockDisplay" "" "@DEF@" +.sM +.FD 0 +void XLockDisplay\^(\^\fIdisplay\fP\^) +.br + Display *\fIdisplay\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.LP +.eM +The +.PN XLockDisplay +function locks out all other threads from using the specified display. +Other threads attempting to use the display will block until +the display is unlocked by this thread. +Nested calls to +.PN XLockDisplay +work correctly; the display will not actually be unlocked until +.PN XUnlockDisplay +has been called the same number of times as +.PN XLockDisplay . +This function has no effect unless Xlib was successfully initialized +for threads using +.PN XInitThreads . +.LP +.sp +To unlock a display, use +.PN XUnlockDisplay . +.IN "XUnlockDisplay" "" "@DEF@" +.sM +.FD 0 +void XUnlockDisplay\^(\^\fIdisplay\fP\^) +.br + Display *\fIdisplay\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.LP +.eM +The +.PN XUnlockDisplay +function allows other threads to use the specified display again. +Any threads that have blocked on the display are allowed to continue. +Nested locking works correctly; if +.PN XLockDisplay +has been called multiple times by a thread, then +.PN XUnlockDisplay +must be called an equal number of times before the display is +actually unlocked. +This function has no effect unless Xlib was successfully initialized +for threads using +.PN XInitThreads . +.NH 2 +Using Internal Connections +.XS +\*(SN Using Internal Connections +.XE +.LP +In addition to the connection to the X server, an Xlib implementation +may require connections to other kinds of servers (for example, to +input method servers as described in chapter 13). Toolkits and clients +that use multiple displays, or that use displays in combination with +other inputs, need to obtain these additional connections to correctly +block until input is available and need to process that input +when it is available. Simple clients that use a single display and +block for input in an Xlib event function do not need to use these +facilities. +.LP +To track internal connections for a display, use +.PN XAddConnectionWatch . +.LP +.IN "XWatchProc" "" "@DEF@" +.IN "XAddConnectionWatch" "" "@DEF@" +.sM +.FD 0 +typedef void (*XConnectionWatchProc)\^(\^\fIdisplay\fP, \fIclient_data\fP, \fIfd\fP, \fIopening\fP, \fIwatch_data\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + XPointer \fIclient_data\fP\^; +.br + int \fIfd\fP\^; +.br + Bool \fIopening\fP\^; +.br + XPointer *\fIwatch_data\fP\^; +.sp +Status XAddConnectionWatch\^(\^\fIdisplay\fP, \fIprocedure\fP\^, \fIclient_data\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + XWatchProc \fIprocedure\fP\^; +.br + XPointer \fIclient_data\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIprocedure\fP 1i +Specifies the procedure to be called. +.IP \fIclient_data\fP 1i +Specifies the additional client data. +.LP +.eM +The +.PN XAddConnectionWatch +function registers a procedure to be called each time Xlib opens or closes an +internal connection for the specified display. The procedure is passed the +display, the specified client_data, the file descriptor for the connection, +a Boolean indicating whether the connection is being opened or closed, and a +pointer to a location for private watch data. If opening is +.PN True , +the procedure can store a pointer to private data in the location pointed +to by watch_data; +when the procedure is later called for this same connection and opening is +.PN False , +the location pointed to by watch_data will hold this same private data pointer. +.LP +This function can be called at any time after a display is opened. +If internal connections already exist, the registered procedure will +immediately be called for each of them, before +.PN XAddConnectionWatch +returns. +.PN XAddConnectionWatch +returns a nonzero status if the procedure is successfully registered; +otherwise, it returns zero. +.LP +The registered procedure should not call any Xlib functions. +If the procedure directly or indirectly causes the state of internal +connections or watch procedures to change, the result is not defined. +If Xlib has been initialized for threads, the procedure is called with +the display locked and the result of a call by the procedure to any +Xlib function that locks the display is not defined unless the executing +thread has externally locked the display using +.PN XLockDisplay . +.LP +.sp +To stop tracking internal connections for a display, use +.PN XRemoveConnectionWatch . +.IN "XRemoveConnectionWatch" "" "@DEF@" +.sM +.FD 0 +Status XRemoveConnectionWatch\^(\^\fIdisplay\fP, \fIprocedure\fP\^, \fIclient_data\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + XWatchProc \fIprocedure\fP\^; +.br + XPointer \fIclient_data\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIprocedure\fP 1i +Specifies the procedure to be called. +.IP \fIclient_data\fP 1i +Specifies the additional client data. +.LP +.eM +The +.PN XRemoveConnectionWatch +function removes a previously registered connection watch procedure. +The client_data must match the client_data used when the procedure +was initially registered. + +.LP +.sp +To process input on an internal connection, use +.PN XProcessInternalConnection . +.IN "XProcessInternalConnection" "" "@DEF@" +.sM +.FD 0 +void XProcessInternalConnection\^(\^\fIdisplay\fP, \fIfd\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + int \fIfd\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIfd\fP 1i +Specifies the file descriptor. +.LP +.eM +The +.PN XProcessInternalConnection +function processes input available on an internal connection. +This function should be called for an internal connection only +after an operating system facility (for example, +.PN select +or +.PN poll ) +has indicated that input is available; otherwise, +the effect is not defined. +.LP +.sp +To obtain all of the current internal connections for a display, use +.PN XInternalConnectionNumbers . +.IN "XInternalConnectionNumbers" "" "@DEF@" +.sM +.FD 0 +Status XInternalConnectionNumbers\^(\^\fIdisplay\fP, \fIfd_return\fP\^, \fIcount_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + int **\fIfd_return\fP\^; +.br + int *\fIcount_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIfd_return\fP 1i +Returns the file descriptors. +.ds Cn file descriptors +.IP \fIcount_return\fP 1i +Returns the number of \*(Cn. +.LP +.eM +The +.PN XInternalConnectionNumbers +function returns a list of the file descriptors for all internal +connections currently open for the specified display. +When the allocated list is no longer needed, +free it by using +.PN XFree . +This functions returns a nonzero status if the list is successfully allocated; +otherwise, it returns zero. +.LP +.bp diff --git a/libX11/specs/libX11/CH03 b/libX11/specs/libX11/CH03 new file mode 100644 index 000000000..f7eb2d4c0 --- /dev/null +++ b/libX11/specs/libX11/CH03 @@ -0,0 +1,3121 @@ +.\" Copyright \(co 1985, 1986, 1987, 1988, 1989, 1990, 1991, 1994, 1996 X Consortium +.\" +.\" 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 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 X CONSORTIUM 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 X Consortium 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 X Consortium. +.\" +.\" Copyright \(co 1985, 1986, 1987, 1988, 1989, 1990, 1991 by +.\" Digital Equipment Corporation +.\" +.\" Portions Copyright \(co 1990, 1991 by +.\" Tektronix, Inc. +.\" +.\" Permission to use, copy, modify and distribute this documentation for +.\" any purpose and without fee is hereby granted, provided that the above +.\" copyright notice appears in all copies and that both that copyright notice +.\" and this permission notice appear in all copies, and that the names of +.\" Digital and Tektronix not be used in in advertising or publicity pertaining +.\" to this documentation without specific, written prior permission. +.\" Digital and Tektronix makes no representations about the suitability +.\" of this documentation for any purpose. +.\" It is provided ``as is'' without express or implied warranty. +.\" +\& +.sp 1 +.ce 3 +\s+1\fBChapter 3\fP\s-1 + +\s+1\fBWindow Functions\fP\s-1 +.sp 2 +.nr H1 3 +.nr H2 0 +.nr H3 0 +.nr H4 0 +.nr H5 0 +.na +.LP +.XS +Chapter 3: Window Functions +.XE +In the X Window System, +a window is a rectangular area on the screen that lets you +view graphic output. +Client applications +can display overlapping and nested windows on one or more +screens that are driven by X servers on one or more machines. +Clients who want to create windows must first +connect their program to the X server +by calling +.PN XOpenDisplay . +This chapter begins with a discussion of +visual types and window attributes. +The chapter continues with a discussion of the Xlib functions you can use to: +.IP \(bu 5 +Create windows +.IP \(bu 5 +Destroy windows +.IP \(bu 5 +Map windows +.IP \(bu 5 +Unmap windows +.IP \(bu 5 +Configure windows +.IP \(bu 5 +Change window stacking order +.IP \(bu 5 +Change window attributes +.LP +This chapter also identifies the window actions that may generate events. +.LP +Note that it is vital that your application conform to the +established conventions for communicating with window managers +for it to work well with the various window managers in use (see section 14.1). +Toolkits generally adhere to these conventions for you, +relieving you of the burden. +Toolkits also often supersede many functions in this chapter +with versions of their own. +For more information, +refer to the documentation for the toolkit that you are using. +.NH 2 +Visual Types +.XS +\*(SN Visual Types +.XE +.LP +.IN "Visual Type" "" "@DEF@" +On some display hardware, +it may be possible to deal with color resources in more than one way. +For example, you may be able to deal with a screen of either 12-bit depth +with arbitrary mapping of pixel to color (pseudo-color) or 24-bit depth +with 8 bits of the pixel dedicated to each of red, green, and blue. +These different ways of dealing with the visual aspects of the screen +are called visuals. +For each screen of the display, there may be a list of valid visual types +supported at different depths of the screen. +Because default windows and visual types are defined for each screen, +most simple applications need not deal with this complexity. +Xlib provides macros and functions that return the default root window, +the default depth of the default root window, and the default visual type +(see sections 2.2.1 and 16.7). +.LP +Xlib uses an opaque +.PN Visual +.IN "Visual" "" "@DEF@" +structure that contains information about the possible color mapping. +The visual utility functions (see section 16.7) use an +.PN XVisualInfo +structure to return this information to an application. +The members of this structure pertinent to this discussion are class, red_mask, +green_mask, blue_mask, bits_per_rgb, and colormap_size. +The class member specifies one of the possible visual classes of the screen +and can be +.IN "Visual Classes" "StaticGray" +.IN "Visual Classes" "StaticColor" +.IN "Visual Classes" "TrueColor" +.IN "Visual Classes" "StaticColor" +.IN "Visual Classes" "GrayScale" +.IN "Visual Classes" "PseudoColor" +.PN StaticGray , +.PN StaticColor , +.PN TrueColor , +.PN GrayScale , +.PN PseudoColor , +or +.PN DirectColor . +.LP +The following concepts may serve to make the explanation of +visual types clearer. +The screen can be color or grayscale, +can have a colormap that is writable or read-only, +and can also have a colormap whose indices are decomposed into separate +RGB pieces, provided one is not on a grayscale screen. +This leads to the following diagram: +.LP +.DS +.TS +center; + c c s c s + c c c c c +| c | c | c | c | c |. + Color Gray-scale + R/O R/W R/O R/W +_ +Undecomposed Static Pseudo Static Gray +Colormap Color Color Gray Scale +_ +.T& +| c | c | c |. +Decomposed True Direct +Colormap Color Color +_ _ _ +.TE +.DE +.LP +Conceptually, +as each pixel is read out of video memory for display on the screen, +it goes through a look-up stage by indexing into a colormap. +Colormaps can be manipulated arbitrarily on some hardware, +in limited ways on other hardware, and not at all on other hardware. +The visual types affect the colormap and +the RGB values in the following ways: +.LP +.IP \(bu 5 +For +.PN PseudoColor , +a pixel value indexes a colormap to produce +independent RGB values, and the RGB values can be changed dynamically. +.IP \(bu 5 +.PN GrayScale +is treated the same way as +.PN PseudoColor +except that the primary that drives the screen is undefined. +Thus, the client should always store the +same value for red, green, and blue in the colormaps. +.IP \(bu 5 +For +.PN DirectColor , +a pixel value is decomposed into separate RGB subfields, and each +subfield separately indexes the colormap for the corresponding value. +The RGB values can be changed dynamically. +.IP \(bu 5 +.PN TrueColor +is treated the same way as +.PN DirectColor +except that the colormap has predefined, read-only RGB values. +These RGB values are server dependent but provide linear or near-linear +ramps in each primary. +.IP \(bu 5 +.PN StaticColor +is treated the same way as +.PN PseudoColor +except that the colormap has predefined, +read-only, server-dependent RGB values. +.IP \(bu 5 +.PN StaticGray +is treated the same way as +.PN StaticColor +except that the RGB values are equal for any single pixel +value, thus resulting in shades of gray. +.PN StaticGray +with a two-entry +colormap can be thought of as monochrome. +.LP +The red_mask, green_mask, and blue_mask members are only defined for +.PN DirectColor +and +.PN TrueColor . +Each has one contiguous set of bits with no +intersections. +The bits_per_rgb member specifies the log base 2 of the +number of distinct color values (individually) of red, green, and blue. +Actual RGB values are unsigned 16-bit numbers. +The colormap_size member defines the number of available colormap entries +in a newly created colormap. +For +.PN DirectColor +and +.PN TrueColor , +this is the size of an individual pixel subfield. +.sp +.LP +To obtain the visual ID from a +.PN Visual , +use +.PN XVisualIDFromVisual . +.IN "XVisualIDFromVisual" "" "@DEF@" +.sM +.FD 0 +VisualID XVisualIDFromVisual\^(\^\fIvisual\fP\^) +.br + Visual *\^\fIvisual\fP\^; +.FN +.IP \fIvisual\fP 1i +Specifies the visual type. +.LP +.eM +The +.PN XVisualIDFromVisual +function returns the visual ID for the specified visual type. +.NH 2 +Window Attributes +.XS +\*(SN Window Attributes +.XE +.LP +.IN "Window" +.IN "Window" "attributes" +All +.PN InputOutput +windows have a border width of zero or more pixels, an optional background, +an event suppression mask (which suppresses propagation of events from +children), and a property list (see section 4.3). +The window border and background can be a solid color or a pattern, called +a tile. +All windows except the root have a parent and are clipped by their parent. +If a window is stacked on top of another window, it obscures that other +window for the purpose of input. +If a window has a background (almost all do), it obscures the other +window for purposes of output. +Attempts to output to the obscured area do nothing, +and no input events (for example, pointer motion) are generated for the +obscured area. +.LP +Windows also have associated property lists (see section 4.3). +.LP +Both +.PN InputOutput +and +.PN InputOnly +windows have the following common attributes, +which are the only attributes of an +.PN InputOnly +window: +.IP \(bu 5 +win-gravity +.IP \(bu 5 +event-mask +.IP \(bu 5 +do-not-propagate-mask +.IP \(bu 5 +override-redirect +.IP \(bu 5 +cursor +.LP +If you specify any other attributes for an +.PN InputOnly +window, +a +.PN BadMatch +error results. +.LP +.PN InputOnly +windows are used for controlling input events in situations where +.PN InputOutput +windows are unnecessary. +.PN InputOnly +windows are invisible; can only be used to control such things as +cursors, input event generation, and grabbing; +and cannot be used in any graphics requests. +Note that +.PN InputOnly +windows cannot have +.PN InputOutput +windows as inferiors. +.LP +Windows have borders of a programmable width and pattern +as well as a background pattern or tile. +.IN "Tile" "pixmaps" +Pixel values can be used for solid colors. +.IN "Resource IDs" "freeing" +.IN "Freeing" "resources" +The background and border pixmaps can be destroyed immediately after +creating the window if no further explicit references to them +are to be made. +.IN "Tile" "mode" +The pattern can either be relative to the parent +or absolute. +If +.PN ParentRelative , +the parent's background is used. +.LP +When windows are first created, +they are not visible (not mapped) on the screen. +Any output to a window that is not visible on the screen +and that does not have backing store will be discarded. +.IN "Window" "mapping" +An application may wish to create a window long before it is +mapped to the screen. +When a window is eventually mapped to the screen +(using +.PN XMapWindow ), +.IN "XMapWindow" +the X server generates an +.PN Expose +event for the window if backing store has not been maintained. +.LP +A window manager can override your choice of size, +border width, and position for a top-level window. +Your program must be prepared to use the actual size and position +of the top window. +It is not acceptable for a client application to resize itself +unless in direct response to a human command to do so. +Instead, either your program should use the space given to it, +or if the space is too small for any useful work, your program +might ask the user to resize the window. +The border of your top-level window is considered fair game +for window managers. +.LP +To set an attribute of a window, +set the appropriate member of the +.PN XSetWindowAttributes +structure and OR in the corresponding value bitmask in your subsequent calls to +.PN XCreateWindow +and +.PN XChangeWindowAttributes , +or use one of the other convenience functions that set the appropriate +attribute. +The symbols for the value mask bits and the +.PN XSetWindowAttributes +structure are: +.sM +.LP +/* Window attribute value mask bits */ +.TS +lw(.5i) lw(2.5i) lw(.8i). +T{ +#define +T} T{ +.PN CWBackPixmap +T} T{ +(1L<<0) +T} +T{ +#define +T} T{ +.PN CWBackPixel +T} T{ +(1L<<1) +T} +T{ +#define +T} T{ +.PN CWBorderPixmap +T} T{ +(1L<<2) +T} +T{ +#define +T} T{ +.PN CWBorderPixel +T} T{ +(1L<<3) +T} +T{ +#define +T} T{ +.PN CWBitGravity +T} T{ +(1L<<4) +T} +T{ +#define +T} T{ +.PN CWWinGravity +T} T{ +(1L<<5) +T} +T{ +#define +T} T{ +.PN CWBackingStore +T} T{ +(1L<<6) +T} +T{ +#define +T} T{ +.PN CWBackingPlanes +T} T{ +(1L<<7) +T} +T{ +#define +T} T{ +.PN CWBackingPixel +T} T{ +(1L<<8) +T} +T{ +#define +T} T{ +.PN CWOverrideRedirect +T} T{ +(1L<<9) +T} +T{ +#define +T} T{ +.PN CWSaveUnder +T} T{ +(1L<<10) +T} +T{ +#define +T} T{ +.PN CWEventMask +T} T{ +(1L<<11) +T} +T{ +#define +T} T{ +.PN CWDontPropagate +T} T{ +(1L<<12) +T} +T{ +#define +T} T{ +.PN CWColormap +T} T{ +(1L<<13) +T} +T{ +#define +T} T{ +.PN CWCursor +T} T{ +(1L<<14) +T} +.TE +.IN "XSetWindowAttributes" "" "@DEF@" +.Ds 0 +.TA .5i 3i +.ta .5i 3i +/* Values */ + +typedef struct { + Pixmap background_pixmap; /* background, None, or ParentRelative */ + unsigned long background_pixel; /* background pixel */ + Pixmap border_pixmap; /* border of the window or CopyFromParent */ + unsigned long border_pixel; /* border pixel value */ + int bit_gravity; /* one of bit gravity values */ + int win_gravity; /* one of the window gravity values */ + int backing_store; /* NotUseful, WhenMapped, Always */ + unsigned long backing_planes; /* planes to be preserved if possible */ + unsigned long backing_pixel; /* value to use in restoring planes */ + Bool save_under; /* should bits under be saved? (popups) */ + long event_mask; /* set of events that should be saved */ + long do_not_propagate_mask; /* set of events that should not propagate */ + Bool override_redirect; /* boolean value for override_redirect */ + Colormap colormap; /* color map to be associated with window */ + Cursor cursor; /* cursor to be displayed (or None) */ +} XSetWindowAttributes; +.De +.LP +.eM +The following lists the defaults for each window attribute and indicates +whether the attribute is applicable to +.PN InputOutput +and +.PN InputOnly +windows: +.TS H +l l l l +lw(1.4i) lw(1.3i) cw(.9i) cw(.8i). +_ +.sp 6p +T{ +.B Attribute +T} T{ +.B Default +T} T{ +.PN InputOutput +T} T{ +.PN InputOnly +T} +.sp 6p +_ +.sp 6p +.TH +.R +T{ +background-pixmap +T} T{ +.PN None +T} T{ +Yes +T} T{ +No +T} +background-pixel Undefined Yes No +T{ +border-pixmap +T} T{ +.PN CopyFromParent +T} T{ +Yes +T} T{ +No +T} +border-pixel Undefined Yes No +T{ +bit-gravity +T} T{ +.PN ForgetGravity +T} T{ +Yes +T} T{ +No +T} +T{ +win-gravity +T} T{ +.PN NorthWestGravity +T} T{ +Yes +T} T{ +Yes +T} +T{ +backing-store +T} T{ +.PN NotUseful +T} T{ +Yes +T} T{ +No +T} +backing-planes All ones Yes No +backing-pixel zero Yes No +T{ +save-under +T} T{ +.PN False +T} T{ +Yes +T} T{ +No +T} +event-mask empty set Yes Yes +do-not-propagate-mask empty set Yes Yes +T{ +override-redirect +T} T{ +.PN False +T} T{ +Yes +T} T{ +Yes +T} +T{ +colormap +T} T{ +.PN CopyFromParent +T} T{ +Yes +T} T{ +No +T} +T{ +cursor +T} T{ +.PN None +T} T{ +Yes +T} T{ +Yes +T} +_ +.TE +.NH 3 +Background Attribute +.XS +\*(SN Background Attribute +.XE +.LP +Only +.PN InputOutput +windows can have a background. +You can set the background of an +.PN InputOutput +window by using a pixel or a pixmap. +.LP +The background-pixmap attribute of a window specifies the pixmap to be used for +a window's background. +This pixmap can be of any size, although some sizes may be faster than others. +The background-pixel attribute of a window specifies a pixel value used to paint +a window's background in a single color. +.LP +You can set the background-pixmap to a pixmap, +.PN None +(default), or +.PN ParentRelative . +You can set the background-pixel of a window to any pixel value (no default). +If you specify a background-pixel, +it overrides either the default background-pixmap +or any value you may have set in the background-pixmap. +A pixmap of an undefined size that is filled with the background-pixel is used +for the background. +Range checking is not performed on the background pixel; +it simply is truncated to the appropriate number of bits. +.LP +If you set the background-pixmap, +it overrides the default. +The background-pixmap and the window must have the same depth, +or a +.PN BadMatch +error results. +If you set background-pixmap to +.PN None , +the window has no defined background. +If you set the background-pixmap to +.PN ParentRelative : +.IP \(bu 5 +The parent window's background-pixmap is used. +The child window, however, must have the same depth as +its parent, +or a +.PN BadMatch +error results. +.IP \(bu 5 +If the parent window has a background-pixmap of +.PN None , +the window also has a background-pixmap of +.PN None . +.IP \(bu 5 +A copy of the parent window's background-pixmap is not made. +The parent's background-pixmap is examined each time the child window's +background-pixmap is required. +.IP \(bu 5 +The background tile origin always aligns with the parent window's +background tile origin. +If the background-pixmap is not +.PN ParentRelative , +the background tile origin is the child window's origin. +.LP +Setting a new background, whether by setting background-pixmap or +background-pixel, overrides any previous background. +The background-pixmap can be freed immediately if no further explicit reference +is made to it (the X server will keep a copy to use when needed). +If you later draw into the pixmap used for the background, +what happens is undefined because the +X implementation is free to make a copy of the pixmap or +to use the same pixmap. +.LP +When no valid contents are available for regions of a window +and either the regions are visible or the server is maintaining backing store, +the server automatically tiles the regions with the window's background +unless the window has a background of +.PN None . +If the background is +.PN None , +the previous screen contents from other windows of the same depth as the window +are simply left in place as long as the contents come from the parent of the +window or an inferior of the parent. +Otherwise, the initial contents of the exposed regions are undefined. +.PN Expose +events are then generated for the regions, even if the background-pixmap +is +.PN None +(see section 10.9). +.NH 3 +Border Attribute +.XS +\*(SN Border Attribute +.XE +.LP +Only +.PN InputOutput +windows can have a border. +You can set the border of an +.PN InputOutput +window by using a pixel or a pixmap. +.LP +The border-pixmap attribute of a window specifies the pixmap to be used +for a window's border. +The border-pixel attribute of a window specifies a pixmap of undefined size +filled with that pixel be used for a window's border. +Range checking is not performed on the background pixel; +it simply is truncated to the appropriate number of bits. +The border tile origin is always the same as the background tile origin. +.LP +You can also set the border-pixmap to a pixmap of any size (some may be faster +than others) or to +.PN CopyFromParent +(default). +You can set the border-pixel to any pixel value (no default). +.LP +If you set a border-pixmap, +it overrides the default. +The border-pixmap and the window must have the same depth, +or a +.PN BadMatch +error results. +If you set the border-pixmap to +.PN CopyFromParent , +the parent window's border-pixmap is copied. +Subsequent changes to the parent window's border attribute do not affect +the child window. +However, the child window must have the same depth as the parent window, +or a +.PN BadMatch +error results. +.LP +The border-pixmap can be freed immediately if no further explicit reference +is made to it. +If you later draw into the pixmap used for the border, +what happens is undefined because the +X implementation is free either to make a copy of the pixmap or +to use the same pixmap. +If you specify a border-pixel, +it overrides either the default border-pixmap +or any value you may have set in the border-pixmap. +All pixels in the window's border will be set to the border-pixel. +Setting a new border, whether by setting border-pixel or by setting +border-pixmap, overrides any previous border. +.LP +Output to a window is always clipped to the inside of the window. +Therefore, graphics operations never affect the window border. +.NH 3 +Gravity Attributes +.XS +\*(SN Gravity Attributes +.XE +.LP +The bit gravity of a window defines which region of the window should be +retained when an +.PN InputOutput +window is resized. +The default value for the bit-gravity attribute is +.PN ForgetGravity . +The window gravity of a window allows you to define how the +.PN InputOutput +or +.PN InputOnly +window should be repositioned if its parent is resized. +The default value for the win-gravity attribute is +.PN NorthWestGravity . +.LP +If the inside width or height of a window is not changed +and if the window is moved or its border is changed, +then the contents of the window are not lost but move with the window. +Changing the inside width or height of the window causes its contents to be +moved or lost (depending on the bit-gravity of the window) and causes +children to be reconfigured (depending on their win-gravity). +For a +change of width and height, the (x, y) pairs are defined: +.LP +.TS +l l +l l. +_ +.sp 6p +.B +Gravity Direction Coordinates +.sp 6p +_ +.sp 6p +.R +T{ +.PN NorthWestGravity +T} T{ +(0, 0) +T} +T{ +.PN NorthGravity +T} T{ +(Width/2, 0) +T} +T{ +.PN NorthEastGravity +T} T{ +(Width, 0) +T} +T{ +.PN WestGravity +T} T{ +(0, Height/2) +T} +T{ +.PN CenterGravity +T} T{ +(Width/2, Height/2) +T} +T{ +.PN EastGravity +T} T{ +(Width, Height/2) +T} +T{ +.PN SouthWestGravity +T} T{ +(0, Height) +T} +T{ +.PN SouthGravity +T} T{ +(Width/2, Height) +T} +T{ +.PN SouthEastGravity +T} T{ +(Width, Height) +T} +.sp 6p +_ +.TE +.LP +When a window with one of these bit-gravity values is resized, +the corresponding pair +defines the change in position of each pixel in the window. +When a window with one of these win-gravities has its parent window resized, +the corresponding pair defines the change in position of the window +within the parent. +When a window is so repositioned, a +.PN GravityNotify +event is generated (see section 10.10.5). +.LP +A bit-gravity of +.PN StaticGravity +indicates that the contents or origin should not move relative to the +origin of the root window. +If the change in size of the window is coupled with a change in position (x, y), +then for bit-gravity the change in position of each pixel is (\-x, \-y), and for +win-gravity the change in position of a child when its parent is so resized is +(\-x, \-y). +Note that +.PN StaticGravity +still only takes effect when the width or height of the window is changed, +not when the window is moved. +.LP +A bit-gravity of +.PN ForgetGravity +indicates that the window's contents are always discarded after a size change, +even if a backing store or save under has been requested. +The window is tiled with its background +and zero or more +.PN Expose +events are generated. +If no background is defined, the existing screen contents are not +altered. +Some X servers may also ignore the specified bit-gravity and +always generate +.PN Expose +events. +.LP +The contents and borders of inferiors are not affected by their parent's +bit-gravity. +A server is permitted to ignore the specified bit-gravity and use +.PN Forget +instead. +.LP +A win-gravity of +.PN UnmapGravity +is like +.PN NorthWestGravity +(the window is not moved), +except the child is also +unmapped when the parent is resized, +and an +.PN UnmapNotify +event is +generated. +.NH 3 +Backing Store Attribute +.XS +\*(SN Backing Store Attribute +.XE +.LP +Some implementations of the X server may choose to maintain the contents of +.PN InputOutput +windows. +If the X server maintains the contents of a window, +the off-screen saved pixels +are known as backing store. +The backing store advises the X server on what to do +with the contents of a window. +The backing-store attribute can be set to +.PN NotUseful +(default), +.PN WhenMapped , +or +.PN Always . +.LP +A backing-store attribute of +.PN NotUseful +advises the X server that +maintaining contents is unnecessary, +although some X implementations may +still choose to maintain contents and, therefore, not generate +.PN Expose +events. +A backing-store attribute of +.PN WhenMapped +advises the X server that maintaining contents of +obscured regions when the window is mapped would be beneficial. +In this case, +the server may generate an +.PN Expose +event when the window is created. +A backing-store attribute of +.PN Always +advises the X server that maintaining contents even when +the window is unmapped would be beneficial. +Even if the window is larger than its parent, +this is a request to the X server to maintain complete contents, +not just the region within the parent window boundaries. +While the X server maintains the window's contents, +.PN Expose +events normally are not generated, +but the X server may stop maintaining +contents at any time. +.LP +When the contents of obscured regions of a window are being maintained, +regions obscured by noninferior windows are included in the destination +of graphics requests (and source, when the window is the source). +However, regions obscured by inferior windows are not included. +.NH 3 +Save Under Flag +.XS +\*(SN Save Under Flag +.XE +.IN "Save Unders" +.LP +Some server implementations may preserve contents of +.PN InputOutput +windows under other +.PN InputOutput +windows. +This is not the same as preserving the contents of a window for you. +You may get better visual +appeal if transient windows (for example, pop-up menus) request that the system +preserve the screen contents under them, +so the temporarily obscured applications do not have to repaint. +.LP +You can set the save-under flag to +.PN True +or +.PN False +(default). +If save-under is +.PN True , +the X server is advised that, when this window is mapped, +saving the contents of windows it obscures would be beneficial. +.NH 3 +Backing Planes and Backing Pixel Attributes +.XS +\*(SN Backing Planes and Backing Pixel Attributes +.XE +.LP +You can set backing planes to indicate (with bits set to 1) +which bit planes of an +.PN InputOutput +window hold dynamic data that must be preserved in backing store +and during save unders. +The default value for the backing-planes attribute is all bits set to 1. +You can set backing pixel to specify what bits to use in planes not +covered by backing planes. +The default value for the backing-pixel attribute is all bits set to 0. +The X server is free to save only the specified bit planes in the backing store +or the save under and is free to regenerate the remaining planes with +the specified pixel value. +Any extraneous bits in these values (that is, those bits beyond +the specified depth of the window) may be simply ignored. +If you request backing store or save unders, +you should use these members to minimize the amount of off-screen memory +required to store your window. +.NH 3 +Event Mask and Do Not Propagate Mask Attributes +.XS +\*(SN Event Mask and Do Not Propagate Mask Attributes +.XE +.LP +The event mask defines which events the client is interested in for this +.PN InputOutput +or +.PN InputOnly +window (or, for some event types, inferiors of this window). +The event mask is the bitwise inclusive OR of zero or more of the +valid event mask bits. +You can specify that no maskable events are reported by setting +.PN NoEventMask +(default). +.LP +The do-not-propagate-mask attribute +defines which events should not be propagated to +ancestor windows when no client has the event type selected in this +.PN InputOutput +or +.PN InputOnly +window. +The do-not-propagate-mask is the bitwise inclusive OR of zero or more +of the following masks: +.PN KeyPress , +.PN KeyRelease , +.PN ButtonPress , +.PN ButtonRelease , +.PN PointerMotion , +.PN Button1Motion , +.PN Button2Motion , +.PN Button3Motion , +.PN Button4Motion , +.PN Button5Motion , +and +.PN ButtonMotion . +You can specify that all events are propagated by setting +.PN NoEventMask +(default). +.NH 3 +Override Redirect Flag +.XS +\*(SN Override Redirect Flag +.XE +.LP +To control window placement or to add decoration, +a window manager often needs to intercept (redirect) any map or configure +request. +Pop-up windows, however, often need to be mapped without a window manager +getting in the way. +To control whether an +.PN InputOutput +or +.PN InputOnly +window is to ignore these structure control facilities, +use the override-redirect flag. +.LP +The override-redirect flag specifies whether map and configure requests +on this window should override a +.PN SubstructureRedirectMask +on the parent. +You can set the override-redirect flag to +.PN True +or +.PN False +(default). +Window managers use this information to avoid tampering with pop-up windows +(see also chapter 14). +.NH 3 +Colormap Attribute +.XS +\*(SN Colormap Attribute +.XE +.LP +The colormap attribute specifies which colormap best reflects the true +colors of the +.PN InputOutput +window. +The colormap must have the same visual type as the window, +or a +.PN BadMatch +error results. +X servers capable of supporting multiple +hardware colormaps can use this information, +and window managers can use it for calls to +.PN XInstallColormap . +You can set the colormap attribute to a colormap or to +.PN CopyFromParent +(default). +.LP +If you set the colormap to +.PN CopyFromParent , +the parent window's colormap is copied and used by its child. +However, the child window must have the same visual type as the parent, +or a +.PN BadMatch +error results. +The parent window must not have a colormap of +.PN None , +or a +.PN BadMatch +error results. +The colormap is copied by sharing the colormap object between the child +and parent, not by making a complete copy of the colormap contents. +Subsequent changes to the parent window's colormap attribute do +not affect the child window. +.NH 3 +Cursor Attribute +.XS +\*(SN Cursor Attribute +.XE +.LP +The cursor attribute specifies which cursor is to be used when the pointer is +in the +.PN InputOutput +or +.PN InputOnly +window. +You can set the cursor to a cursor or +.PN None +(default). +.LP +If you set the cursor to +.PN None , +the parent's cursor is used when the +pointer is in the +.PN InputOutput +or +.PN InputOnly +window, and any change in the parent's cursor will cause an +immediate change in the displayed cursor. +By calling +.PN XFreeCursor , +the cursor can be freed immediately as long as no further explicit reference +to it is made. +.NH 2 +Creating Windows +.XS +\*(SN Creating Windows +.XE +.LP +Xlib provides basic ways for creating windows, +and toolkits often supply higher-level functions specifically for +creating and placing top-level windows, +which are discussed in the appropriate toolkit documentation. +If you do not use a toolkit, however, +you must provide some standard information or hints for the window +manager by using the Xlib inter-client communication functions +(see chapter 14). +.LP +If you use Xlib to create your own top-level windows +(direct children of the root window), +you must observe the following rules so that all applications interact +reasonably across the different styles of window management: +.IP \(bu 5 +You must never fight with the window manager for the size or +placement of your top-level window. +.IP \(bu 5 +You must be able to deal with whatever size window you get, +even if this means that your application just prints a message +like ``Please make me bigger'' in its window. +.IP \(bu 5 +You should only attempt to resize or move top-level windows in +direct response to a user request. +If a request to change the size of a top-level window fails, +you must be prepared to live with what you get. +You are free to resize or move the children of top-level +windows as necessary. +(Toolkits often have facilities for automatic relayout.) +.IP \(bu 5 +If you do not use a toolkit that automatically sets standard window properties, +you should set these properties for top-level windows before mapping them. +.LP +For further information, +see chapter 14 and the \fIInter-Client Communication Conventions Manual\fP. +.LP +.PN XCreateWindow +is the more general function that allows you to set specific window attributes +when you create a window. +.PN XCreateSimpleWindow +creates a window that inherits its attributes from its parent window. +.LP +.IN "Window" "InputOnly" +The X server acts as if +.PN InputOnly +windows do not exist for +the purposes of graphics requests, exposure processing, and +.PN VisibilityNotify +events. +An +.PN InputOnly +window cannot be used as a +drawable (that is, as a source or destination for graphics requests). +.PN InputOnly +and +.PN InputOutput +windows act identically in other respects (properties, +grabs, input control, and so on). +Extension packages can define other classes of windows. +.LP +To create an unmapped window and set its window attributes, use +.PN XCreateWindow . +.IN "XCreateWindow" "" "@DEF@" +.sM +.FD 0 +Window XCreateWindow\^(\^\fIdisplay\fP, \fIparent\fP\^, \fIx\fP\^, \fIy\fP\^, \fIwidth\fP\^, \fIheight\fP\^, \fIborder_width\fP\^, \fIdepth\fP\^, +.br + \fIclass\fP\^, \fIvisual\fP\^, \fIvaluemask\fP\^, \fIattributes\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIparent\fP\^; +.br + int \fIx\fP\^, \fIy\fP\^; +.br + unsigned int \fIwidth\fP\^, \fIheight\fP\^; +.br + unsigned int \fIborder_width\fP\^; +.br + int \fIdepth\fP\^; +.br + unsigned int \fIclass\fP\^; +.br + Visual *\fIvisual\fP\^; +.br + unsigned long \fIvaluemask\fP\^; +.br + XSetWindowAttributes *\fIattributes\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIparent\fP 1i +Specifies the parent window. +.ds Xy , which are the top-left outside corner of the created window's \ +borders and are relative to the inside of the parent window's borders +.IP \fIx\fP 1i +.br +.ns +.IP \fIy\fP 1i +Specify the x and y coordinates\*(Xy. +.ds Wh , which are the created window's inside dimensions \ +and do not include the created window's borders +.IP \fIwidth\fP 1i +.br +.ns +.IP \fIheight\fP 1i +Specify the width and height\*(Wh. +The dimensions must be nonzero, +or a +.PN BadValue +error results. +.IP \fIborder_width\fP 1i +Specifies the width of the created window's border in pixels. +.IP \fIdepth\fP 1i +Specifies the window's depth. +A depth of +.PN CopyFromParent +means the depth is taken from the parent. +.IP \fIclass\fP 1i +Specifies the created window's class. +You can pass +.PN InputOutput , +.PN InputOnly , +or +.PN CopyFromParent . +A class of +.PN CopyFromParent +means the class +is taken from the parent. +.IP \fIvisual\fP 1i +Specifies the visual type. +A visual of +.PN CopyFromParent +means the visual type is taken from the +parent. +.IP \fIvaluemask\fP 1i +Specifies which window attributes are defined in the attributes +argument. +This mask is the bitwise inclusive OR of the valid attribute mask bits. +If valuemask is zero, +the attributes are ignored and are not referenced. +.IP \fIattributes\fP 1i +Specifies the structure from which the values (as specified by the value mask) +are to be taken. +The value mask should have the appropriate bits +set to indicate which attributes have been set in the structure. +.LP +.eM +The +.PN XCreateWindow +function creates an unmapped subwindow for a specified parent window, +returns the window ID of the created window, +and causes the X server to generate a +.PN CreateNotify +event. +The created window is placed on top in the stacking order +with respect to siblings. +.LP +The coordinate system has the X axis horizontal and the Y axis vertical +with the origin [0, 0] at the upper-left corner. +Coordinates are integral, +in terms of pixels, +and coincide with pixel centers. +Each window and pixmap has its own coordinate system. +For a window, +the origin is inside the border at the inside, upper-left corner. +.LP +The border_width for an +.PN InputOnly +window must be zero, or a +.PN BadMatch +error results. +For class +.PN InputOutput , +the visual type and depth must be a combination supported for the screen, +or a +.PN BadMatch +error results. +The depth need not be the same as the parent, +but the parent must not be a window of class +.PN InputOnly , +or a +.PN BadMatch +error results. +For an +.PN InputOnly +window, +the depth must be zero, and the visual must be one supported by the screen. +If either condition is not met, +a +.PN BadMatch +error results. +The parent window, however, may have any depth and class. +If you specify any invalid window attribute for a window, a +.PN BadMatch +error results. +.LP +The created window is not yet displayed (mapped) on the user's display. +To display the window, call +.PN XMapWindow . +The new window initially uses the same cursor as +its parent. +A new cursor can be defined for the new window by calling +.PN XDefineCursor . +.IN "Cursor" "Initial State" +.IN "XDefineCursor" +The window will not be visible on the screen unless it and all of its +ancestors are mapped and it is not obscured by any of its ancestors. +.LP +.PN XCreateWindow +can generate +.PN BadAlloc , +.PN BadColor , +.PN BadCursor , +.PN BadMatch , +.PN BadPixmap , +.PN BadValue , +and +.PN BadWindow +errors. +.LP +.sp +To create an unmapped +.PN InputOutput +subwindow of a given parent window, use +.PN XCreateSimpleWindow . +.IN "XCreateSimpleWindow" "" "@DEF@" +.sM +.FD 0 +Window XCreateSimpleWindow\^(\^\fIdisplay\fP, \fIparent\fP\^, \fIx\fP\^, \fIy\fP\^, \fIwidth\fP\^, \fIheight\fP\^, \fIborder_width\fP\^, +.br + \fIborder\fP\^, \fIbackground\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIparent\fP\^; +.br + int \fIx\fP\^, \fIy\fP\^; +.br + unsigned int \fIwidth\fP\^, \fIheight\fP\^; +.br + unsigned int \fIborder_width\fP\^; +.br + unsigned long \fIborder\fP\^; +.br + unsigned long \fIbackground\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIparent\fP 1i +Specifies the parent window. +.ds Xy , which are the top-left outside corner of the new window's borders \ +and are relative to the inside of the parent window's borders +.IP \fIx\fP 1i +.br +.ns +.IP \fIy\fP 1i +Specify the x and y coordinates\*(Xy. +.ds Wh , which are the created window's inside dimensions \ +and do not include the created window's borders +.IP \fIwidth\fP 1i +.br +.ns +.IP \fIheight\fP 1i +Specify the width and height\*(Wh. +The dimensions must be nonzero, +or a +.PN BadValue +error results. +.IP \fIborder_width\fP 1i +Specifies the width of the created window's border in pixels. +.IP \fIborder\fP 1i +Specifies the border pixel value of the window. +.IP \fIbackground\fP 1i +Specifies the background pixel value of the window. + +.LP +.eM +The +.PN XCreateSimpleWindow +function creates an unmapped +.PN InputOutput +subwindow for a specified parent window, returns the +window ID of the created window, and causes the X server to generate a +.PN CreateNotify +event. +The created window is placed on top in the stacking order with respect to +siblings. +Any part of the window that extends outside its parent window is clipped. +The border_width for an +.PN InputOnly +window must be zero, or a +.PN BadMatch +error results. +.PN XCreateSimpleWindow +inherits its depth, class, and visual from its parent. +All other window attributes, except background and border, +have their default values. +.LP +.PN XCreateSimpleWindow +can generate +.PN BadAlloc , +.PN BadMatch , +.PN BadValue , +and +.PN BadWindow +errors. +.NH 2 +Destroying Windows +.XS +\*(SN Destroying Windows +.XE +.LP +Xlib provides functions that you can use to destroy a window or destroy all +subwindows of a window. +.LP +.sp +To destroy a window and all of its subwindows, use +.PN XDestroyWindow . +.IN "XDestroyWindow" "" "@DEF@" +.sM +.FD 0 +XDestroyWindow\^(\^\fIdisplay\fP, \fIw\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.LP +.eM +The +.PN XDestroyWindow +function destroys the specified window as well as all of its subwindows and causes +the X server to generate a +.PN DestroyNotify +event for each window. +The window should never be referenced again. +If the window specified by the w argument is mapped, +it is unmapped automatically. +The ordering of the +.PN DestroyNotify +events is such that for any given window being destroyed, +.PN DestroyNotify +is generated on any inferiors of the window before being generated on +the window itself. +The ordering among siblings and across subhierarchies is not otherwise +constrained. +If the window you specified is a root window, no windows are destroyed. +Destroying a mapped window will generate +.PN Expose +events on other windows that were obscured by the window being destroyed. +.LP +.PN XDestroyWindow +can generate a +.PN BadWindow +error. +.LP +.sp +To destroy all subwindows of a specified window, use +.PN XDestroySubwindows . +.IN "XDestroySubwindows" "" "@DEF@" +.sM +.FD 0 +XDestroySubwindows\^(\^\fIdisplay\fP, \fIw\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.LP +.eM +The +.PN XDestroySubwindows +function destroys all inferior windows of the specified window, +in bottom-to-top stacking order. +It causes the X server to generate a +.PN DestroyNotify +event for each window. +If any mapped +subwindows were actually destroyed, +.PN XDestroySubwindows +causes the X server to generate +.PN Expose +events on the specified window. +This is much more efficient than deleting many windows +one at a time because much of the work need be performed only once for all +of the windows, rather than for each window. +The subwindows should never be referenced again. +.LP +.PN XDestroySubwindows +can generate a +.PN BadWindow +error. +.NH 2 +Mapping Windows +.XS +\*(SN Mapping Windows +.XE +.LP +A window is considered mapped if an +.PN XMapWindow +call has been made on it. +It may not be visible on the screen for one of the following reasons: +.IP \(bu 5 +It is obscured by another opaque window. +.IP \(bu 5 +One of its ancestors is not mapped. +.IP \(bu 5 +It is entirely clipped by an ancestor. +.LP +.PN Expose +events are generated for the window when part or all of +it becomes visible on the screen. +A client receives the +.PN Expose +events only if it has asked for them. +Windows retain their position in the stacking order when they are unmapped. +.LP +A window manager may want to control the placement of subwindows. +If +.PN SubstructureRedirectMask +has been selected by a window manager +on a parent window (usually a root window), +a map request initiated by other clients on a child window is not performed, +and the window manager is sent a +.PN MapRequest +event. +However, if the override-redirect flag on the child had been set to +.PN True +(usually only on pop-up menus), +the map request is performed. +.LP +A tiling window manager might decide to reposition and resize other clients' +windows and then decide to map the window to its final location. +A window manager that wants to provide decoration might +reparent the child into a frame first. +For further information, +see sections 3.2.8 and 10.10. +Only a single client at a time can select for +.PN SubstructureRedirectMask . +.LP +Similarly, a single client can select for +.PN ResizeRedirectMask +on a parent window. +Then, any attempt to resize the window by another client is suppressed, and +the client receives a +.PN ResizeRequest +event. +.LP +.sp +To map a given window, use +.PN XMapWindow . +.IN "XMapWindow" "" "@DEF@" +.sM +.FD 0 +XMapWindow\^(\^\fIdisplay\fP, \fIw\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.LP +.eM +The +.PN XMapWindow +function +maps the window and all of its +subwindows that have had map requests. +Mapping a window that has an unmapped ancestor does not display the +window but marks it as eligible for display when the ancestor becomes +mapped. +Such a window is called unviewable. +When all its ancestors are mapped, +the window becomes viewable +and will be visible on the screen if it is not obscured by another window. +This function has no effect if the window is already mapped. +.LP +If the override-redirect of the window is +.PN False +and if some other client has selected +.PN SubstructureRedirectMask +on the parent window, then the X server generates a +.PN MapRequest +event, and the +.PN XMapWindow +function does not map the window. +Otherwise, the window is mapped, and the X server generates a +.PN MapNotify +event. +.LP +If the window becomes viewable and no earlier contents for it are remembered, +the X server tiles the window with its background. +If the window's background is undefined, +the existing screen contents are not +altered, and the X server generates zero or more +.PN Expose +events. +If backing-store was maintained while the window was unmapped, no +.PN Expose +events +are generated. +If backing-store will now be maintained, +a full-window exposure is always generated. +Otherwise, only visible regions may be reported. +Similar tiling and exposure take place for any newly viewable inferiors. +.LP +.IN "XMapWindow" +If the window is an +.PN InputOutput +window, +.PN XMapWindow +generates +.PN Expose +events on each +.PN InputOutput +window that it causes to be displayed. +If the client maps and paints the window +and if the client begins processing events, +the window is painted twice. +To avoid this, +first ask for +.PN Expose +events and then map the window, +so the client processes input events as usual. +The event list will include +.PN Expose +for each +window that has appeared on the screen. +The client's normal response to +an +.PN Expose +event should be to repaint the window. +This method usually leads to simpler programs and to proper interaction +with window managers. +.LP +.PN XMapWindow +can generate a +.PN BadWindow +error. +.LP +.sp +To map and raise a window, use +.PN XMapRaised . +.IN "XMapRaised" "" "@DEF@" +.sM +.FD 0 +XMapRaised\^(\^\fIdisplay\fP, \fIw\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.LP +.eM +The +.PN XMapRaised +function +essentially is similar to +.PN XMapWindow +in that it maps the window and all of its +subwindows that have had map requests. +However, it also raises the specified window to the top of the stack. +For additional information, +see +.PN XMapWindow . +.LP +.PN XMapRaised +can generate multiple +.PN BadWindow +errors. +.LP +.sp +To map all subwindows for a specified window, use +.PN XMapSubwindows . +.IN "XMapSubwindows" "" "@DEF@" +.sM +.FD 0 +XMapSubwindows\^(\^\fIdisplay\fP, \fIw\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.LP +.eM +The +.PN XMapSubwindows +.IN "XMapSubwindows" +function maps all subwindows for a specified window in top-to-bottom stacking +order. +The X server generates +.PN Expose +events on each newly displayed window. +This may be much more efficient than mapping many windows +one at a time because the server needs to perform much of the work +only once, for all of the windows, rather than for each window. +.LP +.PN XMapSubwindows +can generate a +.PN BadWindow +error. +.NH 2 +Unmapping Windows +.XS +\*(SN Unmapping Windows +.XE +.LP +Xlib provides functions that you can use to unmap a window or all subwindows. +.LP +.sp +To unmap a window, use +.PN XUnmapWindow . +.IN "XUnmapWindow" "" "@DEF@" +.sM +.FD 0 +XUnmapWindow\^(\^\fIdisplay\fP, \fIw\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.LP +.eM +The +.PN XUnmapWindow +function unmaps the specified window and causes the X server to generate an +.PN UnmapNotify +.IN "UnmapNotify Event" +.IN "XUnmapWindow" +event. +If the specified window is already unmapped, +.PN XUnmapWindow +has no effect. +Normal exposure processing on formerly obscured windows is performed. +Any child window will no longer be visible until another map call is +made on the parent. +In other words, the subwindows are still mapped but are not visible +until the parent is mapped. +Unmapping a window will generate +.PN Expose +events on windows that were formerly obscured by it. +.LP +.PN XUnmapWindow +can generate a +.PN BadWindow +error. +.LP +.sp +To unmap all subwindows for a specified window, use +.PN XUnmapSubwindows . +.IN "XUnmapSubwindows" "" "@DEF@" +.sM +.FD 0 +XUnmapSubwindows\^(\^\fIdisplay\fP, \fIw\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.LP +.eM +The +.PN XUnmapSubwindows +function unmaps all subwindows for the specified window in bottom-to-top +stacking order. +It causes the X server to generate an +.PN UnmapNotify +event on each subwindow and +.PN Expose +events on formerly obscured windows. +.IN "UnmapNotify Event" +Using this function is much more efficient than unmapping multiple windows +one at a time because the server needs to perform much of the work +only once, for all of the windows, rather than for each window. +.LP +.PN XUnmapSubwindows +can generate a +.PN BadWindow +error. +.NH 2 +Configuring Windows +.XS +\*(SN Configuring Windows +.XE +.LP +.LP +Xlib provides functions that you can use to +move a window, resize a window, move and resize a window, or +change a window's border width. +To change one of these parameters, +set the appropriate member of the +.PN XWindowChanges +structure and OR in the corresponding value mask in subsequent calls to +.PN XConfigureWindow . +The symbols for the value mask bits and the +.PN XWindowChanges +structure are: +.sM +.LP +/* Configure window value mask bits */ +.TS +lw(.5i) lw(2.5i) lw(.8i). +T{ +#define +T} T{ +.PN CWX +T} T{ +(1<<0) +T} +T{ +#define +T} T{ +.PN CWY +T} T{ +(1<<1) +T} +T{ +#define +T} T{ +.PN CWWidth +T} T{ +(1<<2) +T} +T{ +#define +T} T{ +.PN CWHeight +T} T{ +(1<<3) +T} +T{ +#define +T} T{ +.PN CWBorderWidth +T} T{ +(1<<4) +T} +T{ +#define +T} T{ +.PN CWSibling +T} T{ +(1<<5) +T} +T{ +#define +T} T{ +.PN CWStackMode +T} T{ +(1<<6) +T} +.TE +.IN "XWindowChanges" "" "@DEF@" +.Ds 0 +.TA .5i 3i +.ta .5i 3i +/* Values */ + +typedef struct { + int x, y; + int width, height; + int border_width; + Window sibling; + int stack_mode; +} XWindowChanges; +.De +.LP +.eM +The x and y members are used to set the window's x and y coordinates, +which are relative to the parent's origin +and indicate the position of the upper-left outer corner of the window. +The width and height members are used to set the inside size of the window, +not including the border, and must be nonzero, or a +.PN BadValue +error results. +Attempts to configure a root window have no effect. +.LP +The border_width member is used to set the width of the border in pixels. +Note that setting just the border width leaves the outer-left corner of the window +in a fixed position but moves the absolute position of the window's origin. +If you attempt to set the border-width attribute of an +.PN InputOnly +window nonzero, a +.PN BadMatch +error results. +.LP +The sibling member is used to set the sibling window for stacking operations. +The stack_mode member is used to set how the window is to be restacked +and can be set to +.PN Above , +.PN Below , +.PN TopIf , +.PN BottomIf , +or +.PN Opposite . +.LP +If the override-redirect flag of the window is +.PN False +and if some other client has selected +.PN SubstructureRedirectMask +on the parent, the X server generates a +.PN ConfigureRequest +event, and no further processing is performed. +Otherwise, +if some other client has selected +.PN ResizeRedirectMask +on the window and the inside +width or height of the window is being changed, +a +.PN ResizeRequest +event is generated, and the current inside width and height are +used instead. +Note that the override-redirect flag of the window has no effect +on +.PN ResizeRedirectMask +and that +.PN SubstructureRedirectMask +on the parent has precedence over +.PN ResizeRedirectMask +on the window. +.LP +When the geometry of the window is changed as specified, +the window is restacked among siblings, and a +.PN ConfigureNotify +event is generated if the state of the window actually changes. +.PN GravityNotify +events are generated after +.PN ConfigureNotify +events. +If the inside width or height of the window has actually changed, +children of the window are affected as specified. +.LP +If a window's size actually changes, +the window's subwindows move according to their window gravity. +Depending on the window's bit gravity, +the contents of the window also may be moved (see section 3.2.3). +.LP +If regions of the window were obscured but now are not, +exposure processing is performed on these formerly obscured windows, +including the window itself and its inferiors. +As a result of increasing the width or height, +exposure processing is also performed on any new regions of the window +and any regions where window contents are lost. +.LP +The restack check (specifically, the computation for +.PN BottomIf , +.PN TopIf , +and +.PN Opposite ) +is performed with respect to the window's final size and position (as +controlled by the other arguments of the request), not its initial position. +If a sibling is specified without a stack_mode, +a +.PN BadMatch +error results. +.LP +If a sibling and a stack_mode are specified, +the window is restacked as follows: +.TS +lw(1i) lw(5i). +T{ +.PN Above +T} T{ +The window is placed just above the sibling. +T} +.sp 6p +T{ +.PN Below +T} T{ +The window is placed just below the sibling. +T} +.sp 6p +T{ +.PN TopIf +T} T{ +If the sibling occludes the window, the window is placed +at the top of the stack. +T} +.sp 6p +T{ +.PN BottomIf +T} T{ +If the window occludes the sibling, the window is +placed at the bottom of the stack. +T} +.sp 6p +T{ +.PN Opposite +T} T{ +If the sibling occludes the window, the window +is placed at the top of the stack. +If the window occludes the sibling, +the window is placed at the bottom of the stack. +T} +.TE +.LP +If a stack_mode is specified but no sibling is specified, +the window is restacked as follows: +.TS +lw(1i) lw(5i). +T{ +.PN Above +T} T{ +The window is placed at the top of the stack. +T} +.sp 6p +T{ +.PN Below +T} T{ +The window is placed at the bottom of the stack. +T} +.sp 6p +T{ +.PN TopIf +T} T{ +If any sibling occludes the window, the window is placed at +the top of the stack. +T} +.sp 6p +T{ +.PN BottomIf +T} T{ +If the window occludes any sibling, the window is placed at +the bottom of the stack. +T} +.sp 6p +T{ +.PN Opposite +T} T{ +If any sibling occludes the window, the window +is placed at the top of the stack. +If the window occludes any sibling, +the window is placed at the bottom of the stack. +T} +.TE +.LP +Attempts to configure a root window have no effect. +.LP +.sp +To configure a window's size, location, stacking, or border, use +.PN XConfigureWindow . +.IN "XConfigureWindow" "" "@DEF@" +.sM +.FD 0 +XConfigureWindow\^(\^\fIdisplay\fP, \fIw\fP\^, \fIvalue_mask\fP\^, \fIvalues\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + unsigned int \fIvalue_mask\fP\^; +.br + XWindowChanges *\fIvalues\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.ds Wi to be reconfigured +.IP \fIw\fP 1i +Specifies the window \*(Wi. +.IP \fIvalue_mask\fP 1i +Specifies which values are to be set using information in +the values structure. +This mask is the bitwise inclusive OR of the valid configure window values bits. +.IP \fIvalues\fP 1i +Specifies the +.PN XWindowChanges +structure. +.LP +.eM +The +.PN XConfigureWindow +function uses the values specified in the +.PN XWindowChanges +structure to reconfigure a window's size, position, border, and stacking order. +Values not specified are taken from the existing geometry of the window. +.LP +If a sibling is specified without a stack_mode or if the window +is not actually a sibling, +a +.PN BadMatch +error results. +Note that the computations for +.PN BottomIf , +.PN TopIf , +and +.PN Opposite +are performed with respect to the window's final geometry (as controlled by the +other arguments passed to +.PN XConfigureWindow ), +not its initial geometry. +Any backing store contents of the window, its +inferiors, and other newly visible windows are either discarded or +changed to reflect the current screen contents +(depending on the implementation). +.LP +.PN XConfigureWindow +can generate +.PN BadMatch , +.PN BadValue , +and +.PN BadWindow +errors. +.LP +.sp +To move a window without changing its size, use +.PN XMoveWindow . +.IN "XMoveWindow" "" "@DEF@" +.sM +.FD 0 +XMoveWindow\^(\^\fIdisplay\fP, \fIw\fP\^, \fIx\fP\^, \fIy\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + int \fIx\fP\^, \fIy\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.ds Wi to be moved +.IP \fIw\fP 1i +Specifies the window \*(Wi. +.ds Xy , which define the new location of the top-left pixel \ +of the window's border or the window itself if it has no border +.IP \fIx\fP 1i +.br +.ns +.IP \fIy\fP 1i +Specify the x and y coordinates\*(Xy. +.LP +.eM +The +.PN XMoveWindow +function moves the specified window to the specified x and y coordinates, +but it does not change the window's size, raise the window, or +change the mapping state of the window. +Moving a mapped window may or may not lose the window's contents +depending on if the window is obscured by nonchildren +and if no backing store exists. +If the contents of the window are lost, +the X server generates +.PN Expose +events. +Moving a mapped window generates +.PN Expose +events on any formerly obscured windows. +.LP +If the override-redirect flag of the window is +.PN False +and some +other client has selected +.PN SubstructureRedirectMask +on the parent, the X server generates a +.PN ConfigureRequest +event, and no further processing is +performed. +Otherwise, the window is moved. +.LP +.PN XMoveWindow +can generate a +.PN BadWindow +error. +.LP +.sp +To change a window's size without changing the upper-left coordinate, use +.PN XResizeWindow . +.IN "XResizeWindow" "" "@DEF@" +.sM +.FD 0 +XResizeWindow\^(\^\fIdisplay\fP, \fIw\fP\^, \fIwidth\fP\^, \fIheight\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + unsigned int \fIwidth\fP\^, \fIheight\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.ds Wh , which are the interior dimensions of the window \ +after the call completes +.IP \fIwidth\fP 1i +.br +.ns +.IP \fIheight\fP 1i +Specify the width and height\*(Wh. +.LP +.eM +The +.PN XResizeWindow +function changes the inside dimensions of the specified window, not including +its borders. +This function does not change the window's upper-left coordinate or +the origin and does not restack the window. +Changing the size of a mapped window may lose its contents and generate +.PN Expose +events. +If a mapped window is made smaller, +changing its size generates +.PN Expose +events on windows that the mapped window formerly obscured. +.LP +If the override-redirect flag of the window is +.PN False +and some +other client has selected +.PN SubstructureRedirectMask +on the parent, the X server generates a +.PN ConfigureRequest +event, and no further processing is performed. +If either width or height is zero, +a +.PN BadValue +error results. +.LP +.PN XResizeWindow +can generate +.PN BadValue +and +.PN BadWindow +errors. +.LP +.sp +To change the size and location of a window, use +.PN XMoveResizeWindow . +.IN "XMoveResizeWindow" "" "@DEF@" +.sM +.FD 0 +XMoveResizeWindow\^(\^\fIdisplay\fP, \fIw\fP\^, \fIx\fP\^, \fIy\fP\^, \fIwidth\fP\^, \fIheight\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + int \fIx\fP\^, \fIy\fP\^; +.br + unsigned int \fIwidth\fP\^, \fIheight\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.ds Wi to be reconfigured +.IP \fIw\fP 1i +Specifies the window \*(Wi. +.ds Xy , which define the new position of the window relative to its parent +.IP \fIx\fP 1i +.br +.ns +.IP \fIy\fP 1i +Specify the x and y coordinates\*(Xy. +.ds Wh , which define the interior size of the window +.IP \fIwidth\fP 1i +.br +.ns +.IP \fIheight\fP 1i +Specify the width and height\*(Wh. +.LP +.eM +The +.PN XMoveResizeWindow +function changes the size and location of the specified window +without raising it. +Moving and resizing a mapped window may generate an +.PN Expose +event on the window. +Depending on the new size and location parameters, +moving and resizing a window may generate +.PN Expose +events on windows that the window formerly obscured. +.LP +If the override-redirect flag of the window is +.PN False +and some +other client has selected +.PN SubstructureRedirectMask +on the parent, the X server generates a +.PN ConfigureRequest +event, and no further processing is performed. +Otherwise, the window size and location are changed. +.LP +.PN XMoveResizeWindow +can generate +.PN BadValue +and +.PN BadWindow +errors. +.LP +.sp +To change the border width of a given window, use +.PN XSetWindowBorderWidth . +.IN "XSetWindowBorderWidth" "" "@DEF@" +.sM +.FD 0 +XSetWindowBorderWidth\^(\^\fIdisplay\fP, \fIw\fP, \fIwidth\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + unsigned int \fIwidth\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fIwidth\fP 1i +Specifies the width of the window border. +.LP +.eM +The +.PN XSetWindowBorderWidth +function sets the specified window's border width to the specified width. +.LP +.PN XSetWindowBorderWidth +can generate a +.PN BadWindow +error. +.NH 2 +Changing Window Stacking Order +.XS +\*(SN Changing Window Stacking Order +.XE +.LP +.LP +Xlib provides functions that you can use to raise, lower, circulate, +or restack windows. +.LP +.sp +To raise a window so that no sibling window obscures it, use +.PN XRaiseWindow . +.IN "XRaiseWindow" "" "@DEF@" +.sM +.FD 0 +XRaiseWindow\^(\^\fIdisplay\fP, \fIw\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.LP +.eM +The +.PN XRaiseWindow +function +raises the specified window to the top of the stack so that no sibling window +obscures it. +If the windows are regarded as overlapping sheets of paper stacked +on a desk, +then raising a window is analogous to moving the sheet to the top of +the stack but leaving its x and y location on the desk constant. +Raising a mapped window may generate +.PN Expose +events for the window and any mapped subwindows that were formerly obscured. +.LP +If the override-redirect attribute of the window is +.PN False +and some +other client has selected +.PN SubstructureRedirectMask +on the parent, the X server generates a +.PN ConfigureRequest +event, and no processing is performed. +Otherwise, the window is raised. +.LP +.PN XRaiseWindow +can generate a +.PN BadWindow +error. +.LP +.sp +To lower a window so that it does not obscure any sibling windows, use +.PN XLowerWindow . +.IN "XLowerWindow" "" "@DEF@" +.sM +.FD 0 +XLowerWindow\^(\^\fIdisplay\fP, \fIw\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.LP +.eM +The +.PN XLowerWindow +function lowers the specified window to the bottom of the stack +so that it does not obscure any sibling +windows. +If the windows are regarded as overlapping sheets of paper +stacked on a desk, then lowering a window is analogous to moving the +sheet to the bottom of the stack but leaving its x and y location on +the desk constant. +Lowering a mapped window will generate +.PN Expose +events on any windows it formerly obscured. +.LP +If the override-redirect attribute of the window is +.PN False +and some +other client has selected +.PN SubstructureRedirectMask +on the parent, the X server generates a +.PN ConfigureRequest +event, and no processing is performed. +Otherwise, the window is lowered to the bottom of the +stack. +.LP +.PN XLowerWindow +can generate a +.PN BadWindow +error. +.LP +.sp +To circulate a subwindow up or down, use +.PN XCirculateSubwindows . +.IN "XCirculateSubwindows" "" "@DEF@" +.sM +.FD 0 +XCirculateSubwindows\^(\^\fIdisplay\fP, \fIw\fP\^, \fIdirection\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + int \fIdirection\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fIdirection\fP 1i +Specifies the direction (up or down) that you want to circulate +the window. +You can pass +.PN RaiseLowest +or +.PN LowerHighest . +.LP +.eM +The +.PN XCirculateSubwindows +function circulates children of the specified window in the specified +direction. +If you specify +.PN RaiseLowest , +.PN XCirculateSubwindows +raises the lowest mapped child (if any) that is occluded +by another child to the top of the stack. +If you specify +.PN LowerHighest , +.PN XCirculateSubwindows +lowers the highest mapped child (if any) that occludes another child +to the bottom of the stack. +Exposure processing is then performed on formerly obscured windows. +If some other client has selected +.PN SubstructureRedirectMask +on the window, the X server generates a +.PN CirculateRequest +event, and no further processing is performed. +If a child is actually restacked, +the X server generates a +.PN CirculateNotify +event. +.LP +.PN XCirculateSubwindows +can generate +.PN BadValue +and +.PN BadWindow +errors. +.LP +.sp +To raise the lowest mapped child of a window that is partially or completely +occluded by another child, use +.PN XCirculateSubwindowsUp . +.IN "XCirculateSubwindowsUp" "" "@DEF@" +.sM +.FD 0 +XCirculateSubwindowsUp\^(\^\fIdisplay\fP, \fIw\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.LP +.eM +The +.PN XCirculateSubwindowsUp +function raises the lowest mapped child of the specified window that +is partially +or completely +occluded by another child. +Completely unobscured children are not affected. +This is a convenience function equivalent to +.PN XCirculateSubwindows +with +.PN RaiseLowest +specified. +.LP +.PN XCirculateSubwindowsUp +can generate a +.PN BadWindow +error. +.LP +.sp +To lower the highest mapped child of a window that partially or +completely occludes another child, use +.PN XCirculateSubwindowsDown . +.IN "XCirculateSubwindowsDown" "" "@DEF@" +.sM +.FD 0 +XCirculateSubwindowsDown\^(\^\fIdisplay\fP, \fIw\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.LP +.eM +The +.PN XCirculateSubwindowsDown +function lowers the highest mapped child of the specified window that partially +or completely occludes another child. +Completely unobscured children are not affected. +This is a convenience function equivalent to +.PN XCirculateSubwindows +with +.PN LowerHighest +specified. +.LP +.PN XCirculateSubwindowsDown +can generate a +.PN BadWindow +error. +.LP +.sp +To restack a set of windows from top to bottom, use +.PN XRestackWindows . +.IN "XRestackWindows" "" "@DEF@" +.sM +.FD 0 +XRestackWindows\^(\^\fIdisplay\fP, \fIwindows\fP\^, \^\fInwindows\fP\^); +.br + Display *\fIdisplay\fP\^; +.br + Window \fIwindows\fP\^[]; +.br + int \fInwindows\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIwindows\fP 1i +Specifies an array containing the windows to be restacked. +.IP \fInwindows\fP 1i +Specifies the number of windows to be restacked. +.LP +.eM +The +.PN XRestackWindows +function restacks the windows in the order specified, +from top to bottom. +The stacking order of the first window in the windows array is unaffected, +but the other windows in the array are stacked underneath the first window, +in the order of the array. +The stacking order of the other windows is not affected. +For each window in the window array that is not a child of the specified window, +a +.PN BadMatch +error results. +.LP +If the override-redirect attribute of a window is +.PN False +and some +other client has selected +.PN SubstructureRedirectMask +on the parent, the X server generates +.PN ConfigureRequest +events for each window whose override-redirect flag is not set, +and no further processing is performed. +Otherwise, the windows will be restacked in top-to-bottom order. +.LP +.PN XRestackWindows +can generate a +.PN BadWindow +error. +.NH 2 +Changing Window Attributes +.XS +\*(SN Changing Window Attributes +.XE +.LP +.LP +Xlib provides functions that you can use to set window attributes. +.PN XChangeWindowAttributes +is the more general function that allows you to set one or more window +attributes provided by the +.PN XSetWindowAttributes +structure. +The other functions described in this section allow you to set one specific +window attribute, such as a window's background. +.LP +.sp +To change one or more attributes for a given window, use +.PN XChangeWindowAttributes . +.IN "XChangeWindowAttributes" "" "@DEF@" +.sM +.FD 0 +XChangeWindowAttributes\^(\^\fIdisplay\fP, \fIw\fP\^, \fIvaluemask\fP\^, \fIattributes\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + unsigned long \fIvaluemask\fP\^; +.br + XSetWindowAttributes *\fIattributes\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fIvaluemask\fP 1i +Specifies which window attributes are defined in the attributes +argument. +This mask is the bitwise inclusive OR of the valid attribute mask bits. +If valuemask is zero, +the attributes are ignored and are not referenced. +The values and restrictions are +the same as for +.PN XCreateWindow . +.IP +.IP \fIattributes\fP 1i +Specifies the structure from which the values (as specified by the value mask) +are to be taken. +The value mask should have the appropriate bits +set to indicate which attributes have been set in the structure +(see section 3.2). +.LP +.eM +Depending on the valuemask, +the +.PN XChangeWindowAttributes +function uses the window attributes in the +.PN XSetWindowAttributes +structure to change the specified window attributes. +Changing the background does not cause the window contents to be +changed. +To repaint the window and its background, use +.PN XClearWindow . +Setting the border or changing the background such that the +border tile origin changes causes the border to be repainted. +Changing the background of a root window to +.PN None +or +.PN ParentRelative +restores the default background pixmap. +Changing the border of a root window to +.PN CopyFromParent +restores the default border pixmap. +Changing the win-gravity does not affect the current position of the +window. +Changing the backing-store of an obscured window to +.PN WhenMapped +or +.PN Always , +or changing the backing-planes, backing-pixel, or +save-under of a mapped window may have no immediate effect. +Changing the colormap of a window (that is, defining a new map, not +changing the contents of the existing map) generates a +.PN ColormapNotify +event. +Changing the colormap of a visible window may have no +immediate effect on the screen because the map may not be installed +(see +.PN XInstallColormap ). +Changing the cursor of a root window to +.PN None +restores the default +cursor. +Whenever possible, you are encouraged to share colormaps. +.LP +Multiple clients can select input on the same window. +Their event masks are maintained separately. +When an event is generated, +it is reported to all interested clients. +However, only one client at a time can select for +.PN SubstructureRedirectMask , +.PN ResizeRedirectMask , +and +.PN ButtonPressMask . +If a client attempts to select any of these event masks +and some other client has already selected one, +a +.PN BadAccess +error results. +There is only one do-not-propagate-mask for a window, +not one per client. +.LP +.PN XChangeWindowAttributes +can generate +.PN BadAccess , +.PN BadColor , +.PN BadCursor , +.PN BadMatch , +.PN BadPixmap , +.PN BadValue , +and +.PN BadWindow +errors. +.LP +.sp +To set the background of a window to a given pixel, use +.PN XSetWindowBackground . +.IN "XSetWindowBackground" "" "@DEF@" +.sM +.FD 0 +XSetWindowBackground\^(\^\fIdisplay\fP, \fIw\fP\^, \fIbackground_pixel\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + unsigned long \fIbackground_pixel\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fIbackground_pixel\fP 1i +Specifies the pixel that is to be used for the background. +.LP +.eM +The +.PN XSetWindowBackground +function sets the background of the window to the specified pixel value. +Changing the background does not cause the window contents to be changed. +.PN XSetWindowBackground +uses a pixmap of undefined size filled with the pixel value you passed. +If you try to change the background of an +.PN InputOnly +window, a +.PN BadMatch +error results. +.LP +.PN XSetWindowBackground +can generate +.PN BadMatch +and +.PN BadWindow +errors. +.LP +.sp +.LP +To set the background of a window to a given pixmap, use +.PN XSetWindowBackgroundPixmap . +.IN "Window" "background" +.IN "XSetWindowBackgroundPixmap" "" "@DEF@" +.sM +.FD 0 +XSetWindowBackgroundPixmap\^(\^\fIdisplay\fP, \fIw\fP\^, \fIbackground_pixmap\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + Pixmap \fIbackground_pixmap\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fIbackground_pixmap\fP 1i +Specifies the background pixmap, +.PN ParentRelative , +or +.PN None . +.LP +.eM +.IN "Resource IDs" "freeing" +.IN "Freeing" "resources" +The +.PN XSetWindowBackgroundPixmap +function sets the background pixmap of the window to the specified pixmap. +The background pixmap can immediately be freed if no further explicit +references to it are to be made. +If +.PN ParentRelative +is specified, +the background pixmap of the window's parent is used, +or on the root window, the default background is restored. +If you try to change the background of an +.PN InputOnly +window, a +.PN BadMatch +error results. +If the background is set to +.PN None , +the window has no defined background. +.LP +.PN XSetWindowBackgroundPixmap +can generate +.PN BadMatch , +.PN BadPixmap , +and +.PN BadWindow +errors. +.NT Note +.PN XSetWindowBackground +and +.PN XSetWindowBackgroundPixmap +do not change the current contents of the window. +.NE +.LP +.sp +To change and repaint a window's border to a given pixel, use +.PN XSetWindowBorder . +.IN "XSetWindowBorder" "" "@DEF@" +.sM +.FD 0 +XSetWindowBorder\^(\^\fIdisplay\fP, \fIw\fP\^, \fIborder_pixel\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + unsigned long \fIborder_pixel\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fIborder_pixel\fP 1i +Specifies the entry in the colormap. +.LP +.eM +The +.PN XSetWindowBorder +function sets the border of the window to the pixel value you specify. +If you attempt to perform this on an +.PN InputOnly +window, a +.PN BadMatch +error results. +.LP +.PN XSetWindowBorder +can generate +.PN BadMatch +and +.PN BadWindow +errors. +.LP +.sp +To change and repaint the border tile of a given window, use +.PN XSetWindowBorderPixmap . +.IN "XSetWindowBorderPixmap" "" "@DEF@" +.sM +.FD 0 +XSetWindowBorderPixmap\^(\^\fIdisplay\fP, \fIw\fP\^, \fIborder_pixmap\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + Pixmap \fIborder_pixmap\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fIborder_pixmap\fP 1i +Specifies the border pixmap or +.PN CopyFromParent . +.LP +.eM +The +.PN XSetWindowBorderPixmap +function sets the border pixmap of the window to the pixmap you specify. +The border pixmap can be freed immediately if no further explicit +references to it are to be made. +If you specify +.PN CopyFromParent , +a copy of the parent window's border pixmap is used. +If you attempt to perform this on an +.PN InputOnly +window, a +.PN BadMatch +error results. +.IN "Resource IDs" "freeing" +.IN "Freeing" "resources" +.LP +.PN XSetWindowBorderPixmap +can generate +.PN BadMatch , +.PN BadPixmap , +and +.PN BadWindow +errors. +.LP +.sp +To set the colormap of a given window, use +.PN XSetWindowColormap . +.IN "XSetWindowColormap" "" "@DEF@" +.sM +.FD 0 +XSetWindowColormap\^(\^\fIdisplay\fP, \fIw\fP\^, \fIcolormap\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + Colormap \fIcolormap\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fIcolormap\fP 1i +Specifies the colormap. +.LP +.eM +The +.PN XSetWindowColormap +function sets the specified colormap of the specified window. +The colormap must have the same visual type as the window, +or a +.PN BadMatch +error results. +.LP +.PN XSetWindowColormap +can generate +.PN BadColor , +.PN BadMatch , +and +.PN BadWindow +errors. +.LP +.sp +To define which cursor will be used in a window, use +.PN XDefineCursor . +.IN "Window" "defining the cursor" +.IN "XDefineCursor" "" "@DEF@" +.sM +.FD 0 +XDefineCursor\^(\^\fIdisplay\fP, \fIw\fP\^, \fIcursor\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + Cursor \fIcursor\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fIcursor\fP 1i +Specifies the cursor that is to be displayed or +.PN None . +.LP +.eM +If a cursor is set, it will be used when the pointer is in the window. +If the cursor is +.PN None , +it is equivalent to +.PN XUndefineCursor . +.LP +.PN XDefineCursor +can generate +.PN BadCursor +and +.PN BadWindow +errors. +.LP +.sp +To undefine the cursor in a given window, use +.PN XUndefineCursor . +.IN "Window" "undefining the cursor" +.IN "XUndefineCursor" "" "@DEF@" +.sM +.FD 0 +XUndefineCursor\^(\^\fIdisplay\fP, \fIw\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.LP +.eM +The +.PN XUndefineCursor +function undoes the effect of a previous +.PN XDefineCursor +for this window. +When the pointer is in the window, +the parent's cursor will now be used. +On the root window, +the default cursor is restored. +.LP +.PN XUndefineCursor +can generate a +.PN BadWindow +error. +.bp diff --git a/libX11/specs/libX11/CH04 b/libX11/specs/libX11/CH04 new file mode 100644 index 000000000..b964198c2 --- /dev/null +++ b/libX11/specs/libX11/CH04 @@ -0,0 +1,1595 @@ +.\" Copyright \(co 1985, 1986, 1987, 1988, 1989, 1990, 1991, 1994, 1996 X Consortium +.\" +.\" 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 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 X CONSORTIUM 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 X Consortium 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 X Consortium. +.\" +.\" Copyright \(co 1985, 1986, 1987, 1988, 1989, 1990, 1991 by +.\" Digital Equipment Corporation +.\" +.\" Portions Copyright \(co 1990, 1991 by +.\" Tektronix, Inc. +.\" +.\" Permission to use, copy, modify and distribute this documentation for +.\" any purpose and without fee is hereby granted, provided that the above +.\" copyright notice appears in all copies and that both that copyright notice +.\" and this permission notice appear in all copies, and that the names of +.\" Digital and Tektronix not be used in in advertising or publicity pertaining +.\" to this documentation without specific, written prior permission. +.\" Digital and Tektronix makes no representations about the suitability +.\" of this documentation for any purpose. +.\" It is provided ``as is'' without express or implied warranty. +.\" +\& +.sp 1 +.ce 3 +\s+1\fBChapter 4\fP\s-1 + +\s+1\fBWindow Information Functions\fP\s-1 +.sp 2 +.nr H1 4 +.nr H2 0 +.nr H3 0 +.nr H4 0 +.nr H5 0 +.na +.LP +.XS +Chapter 4: Window Information Functions +.XE +After you connect the display to the X server and create a window, +you can use the Xlib window information functions to: +.IP \(bu 5 +Obtain information about a window +.IP \(bu 5 +Translate screen coordinates +.IP \(bu 5 +Manipulate property lists +.IP \(bu 5 +Obtain and change window properties +.IP \(bu 5 +Manipulate selections +.NH 2 +Obtaining Window Information +.XS +\*(SN Obtaining Window Information +.XE +.LP +Xlib provides functions that you can use to obtain information about +the window tree, the window's current attributes, +the window's current geometry, or the current pointer coordinates. +Because they are most frequently used by window managers, +these functions all return a status to indicate whether the window still +exists. +.LP +.sp +To obtain the parent, a list of children, and number of children for +a given window, use +.PN XQueryTree . +.IN "Child Window" +.IN "Parent Window" +.IN "XQueryTree" "" "@DEF@" +.sM +.FD 0 +Status XQueryTree\^(\^\fIdisplay\fP, \fIw\fP\^, \fIroot_return\fP\^, \fIparent_return\fP\^, \fIchildren_return\fP\^, \fInchildren_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + Window *\fIroot_return\fP\^; +.br + Window *\fIparent_return\fP\^; +.br + Window **\fIchildren_return\fP\^; +.br + unsigned int *\fInchildren_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.ds Wi whose list of children, root, parent, and number of children \ +you want to obtain +.IP \fIw\fP 1i +Specifies the window \*(Wi. +.IP \fIroot_return\fP 1i +Returns the root window. +.IP \fIparent_return\fP 1i +Returns the parent window. +.IP \fIchildren_return\fP 1i +Returns the list of children. +.IP \fInchildren_return\fP 1i +Returns the number of children. +.LP +.eM +The +.PN XQueryTree +function returns the root ID, the parent window ID, +a pointer to the list of children windows +(NULL when there are no children), +and the number of children in the list for the specified window. +The children are listed in current stacking order, from bottom-most +(first) to top-most (last). +.PN XQueryTree +returns zero if it fails and nonzero if it succeeds. +To free a non-NULL children list when it is no longer needed, use +.PN XFree . +.LP +.PN XQueryTree +can generate a +.PN BadWindow +error. +.LP +.sp +To obtain the current attributes of a given window, use +.PN XGetWindowAttributes . +.IN "XGetWindowAttributes" "" "@DEF@" +.sM +.FD 0 +Status XGetWindowAttributes\^(\^\fIdisplay\fP, \fIw\fP\^, \fIwindow_attributes_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + XWindowAttributes *\fIwindow_attributes_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.ds Wi whose current attributes you want to obtain +.IP \fIw\fP 1i +Specifies the window \*(Wi. +.IP \fIwindow_attributes_return\fP 1i +Returns the specified window's attributes in the +.PN XWindowAttributes +structure. +.LP +.eM +The +.PN XGetWindowAttributes +function returns the current attributes for the specified window to an +.PN XWindowAttributes +structure. +.LP +.IN "XWindowAttributes" "" "@DEF@" +.sM +.Ds 0 +.TA .5i 3i +.ta .5i 3i +typedef struct { + int x, y; /* location of window */ + int width, height; /* width and height of window */ + int border_width; /* border width of window */ + int depth; /* depth of window */ + Visual *visual; /* the associated visual structure */ + Window root; /* root of screen containing window */ + int class; /* InputOutput, InputOnly*/ + int bit_gravity; /* one of the bit gravity values */ + int win_gravity; /* one of the window gravity values */ + int backing_store; /* NotUseful, WhenMapped, Always */ + unsigned long backing_planes; /* planes to be preserved if possible */ + unsigned long backing_pixel; /* value to be used when restoring planes */ + Bool save_under; /* boolean, should bits under be saved? */ + Colormap colormap; /* color map to be associated with window */ + Bool map_installed; /* boolean, is color map currently installed*/ + int map_state; /* IsUnmapped, IsUnviewable, IsViewable */ + long all_event_masks; /* set of events all people have interest in*/ + long your_event_mask; /* my event mask */ + long do_not_propagate_mask; /* set of events that should not propagate */ + Bool override_redirect; /* boolean value for override-redirect */ + Screen *screen; /* back pointer to correct screen */ +} XWindowAttributes; +.De +.LP +.eM +The x and y members are set to the upper-left outer +corner relative to the parent window's origin. +The width and height members are set to the inside size of the window, +not including the border. +The border_width member is set to the window's border width in pixels. +The depth member is set to the depth of the window +(that is, bits per pixel for the object). +The visual member is a pointer to the screen's associated +.PN Visual +structure. +The root member is set to the root window of the screen containing the window. +The class member is set to the window's class and can be either +.PN InputOutput +or +.PN InputOnly . +.LP +The bit_gravity member is set to the window's bit gravity +and can be one of the following: +.LP +.TS +lw(1.5i) lw(1.5i). +T{ +.PN ForgetGravity +T} T{ +.PN EastGravity +T} +T{ +.PN NorthWestGravity +T} T{ +.PN SouthWestGravity +T} +T{ +.PN NorthGravity +T} T{ +.PN SouthGravity +T} +T{ +.PN NorthEastGravity +T} T{ +.PN SouthEastGravity +T} +T{ +.PN WestGravity +T} T{ +.PN StaticGravity +T} +.PN CenterGravity +.TE +.LP +The win_gravity member is set to the window's window gravity +and can be one of the following: +.LP +.TS +lw(1.5i) lw(1.5i). +T{ +.PN UnmapGravity +T} T{ +.PN EastGravity +T} +T{ +.PN NorthWestGravity +T} T{ +.PN SouthWestGravity +T} +T{ +.PN NorthGravity +T} T{ +.PN SouthGravity +T} +T{ +.PN NorthEastGravity +T} T{ +.PN SouthEastGravity +T} +T{ +.PN WestGravity +T} T{ +.PN StaticGravity +T} +.PN CenterGravity +.TE +.LP +For additional information on gravity, +see section 3.2.3. +.LP +The backing_store member is set to indicate how the X server should maintain +the contents of a window +and can be +.PN WhenMapped , +.PN Always , +or +.PN NotUseful . +The backing_planes member is set to indicate (with bits set to 1) which bit +planes of the window hold dynamic data that must be preserved in backing_stores +and during save_unders. +The backing_pixel member is set to indicate what values to use +for planes not set in backing_planes. +.LP +The save_under member is set to +.PN True +or +.PN False . +The colormap member is set to the colormap for the specified window and can be +a colormap ID or +.PN None . +The map_installed member is set to indicate whether the colormap is +currently installed and can be +.PN True +or +.PN False . +The map_state member is set to indicate the state of the window and can be +.PN IsUnmapped , +.PN IsUnviewable , +or +.PN IsViewable . +.PN IsUnviewable +is used if the window is mapped but some ancestor is unmapped. +.LP +The all_event_masks member is set to the bitwise inclusive OR of all event +masks selected on the window by all clients. +The your_event_mask member is set to the bitwise inclusive OR of all event +masks selected by the querying client. +The do_not_propagate_mask member is set to the bitwise inclusive OR of the +set of events that should not propagate. +.LP +The override_redirect member is set to indicate whether this window overrides +structure control facilities and can be +.PN True +or +.PN False . +Window manager clients should ignore the window if this member is +.PN True . +.LP +The screen member is set to a screen pointer that gives you a back pointer +to the correct screen. +This makes it easier to obtain the screen information without +having to loop over the root window fields to see which field matches. +.LP +.PN XGetWindowAttributes +can generate +.PN BadDrawable +and +.PN BadWindow +errors. +.LP +.sp +To obtain the current geometry of a given drawable, use +.PN XGetGeometry . +.IN "XGetGeometry" "" "@DEF@" +.sM +.FD 0 +Status XGetGeometry\^(\^\fIdisplay\fP, \fId\fP\^, \^\fIroot_return\fP\^, \fIx_return\fP\^, \fIy_return\fP\^, \fIwidth_return\fP\^, +.br + \fIheight_return\fP\^, \fIborder_width_return\fP\^, \fIdepth_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Drawable \fId\fP\^; +.br + Window *\fIroot_return\fP\^; +.br + int *\fIx_return\fP\^, *\fIy_return\fP\^; +.br + unsigned int *\fIwidth_return\fP\^, *\fIheight_return\fP\^; +.br + unsigned int *\fIborder_width_return\fP\^; +.br + unsigned int *\fIdepth_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.ds Dr , which can be a window or a pixmap +.IP \fId\fP 1i +Specifies the drawable\*(Dr. +.IP \fIroot_return\fP 1i +Returns the root window. +.IP \fIx_return\fP 1i +.br +.ns +.IP \fIy_return\fP 1i +Return the x and y coordinates that define the location of the drawable. +For a window, +these coordinates specify the upper-left outer corner relative to +its parent's origin. +For pixmaps, these coordinates are always zero. +.IP \fIwidth_return\fP 1i +.br +.ns +.IP \fIheight_return\fP 1i +Return the drawable's dimensions (width and height). +For a window, +these dimensions specify the inside size, not including the border. +.IP \fIborder_width_return\fP 1i +Returns the border width in pixels. +If the drawable is a pixmap, it returns zero. +.IP \fIdepth_return\fP 1i +Returns the depth of the drawable (bits per pixel for the object). +.LP +.eM +The +.PN XGetGeometry +function returns the root window and the current geometry of the drawable. +The geometry of the drawable includes the x and y coordinates, width and height, +border width, and depth. +These are described in the argument list. +It is legal to pass to this function a window whose class is +.PN InputOnly . +.LP +.PN XGetGeometry +can generate a +.PN BadDrawable +error. +.NH 2 +Translating Screen Coordinates +.XS +\*(SN Translating Screen Coordinates +.XE +.LP +Applications sometimes +need to perform a coordinate transformation from the coordinate +space of one window to another window or need to determine which +window the pointing device is in. +.PN XTranslateCoordinates +and +.PN XQueryPointer +fulfill these needs (and avoid any race conditions) by +asking the X server to perform these operations. +.LP +.sp +To translate a coordinate in one window to the coordinate +space of another window, use +.PN XTranslateCoordinates . +.IN "XTranslateCoordinates" "" "@DEF@" +.sM +.FD 0 +Bool XTranslateCoordinates\^(\^\fIdisplay\fP, \fIsrc_w\fP\^, \fIdest_w\fP\^, \fIsrc_x\fP\^, \fIsrc_y\fP\^, \fIdest_x_return\fP\^, +.br + \fIdest_y_return\fP\^, \fIchild_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIsrc_w\fP\^, \fIdest_w\fP\^; +.br + int \fIsrc_x\fP\^, \fIsrc_y\fP\^; +.br + int *\fIdest_x_return\fP\^, *\fIdest_y_return\fP\^; +.br + Window *\fIchild_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIsrc_w\fP 1i +Specifies the source window. +.IP \fIdest_w\fP 1i +Specifies the destination window. +.IP \fIsrc_x\fP 1i +.br +.ns +.IP \fIsrc_y\fP 1i +Specify the x and y coordinates within the source window. +.IP \fIdest_x_return\fP 1i +.br +.ns +.IP \fIdest_y_return\fP 1i +Return the x and y coordinates within the destination window. +.IP \fIchild_return\fP 1i +Returns the child if the coordinates are contained in a mapped child of the +destination window. +.LP +.eM +If +.PN XTranslateCoordinates +returns +.PN True , +it takes the src_x and src_y coordinates relative +to the source window's origin and returns these coordinates to +dest_x_return and dest_y_return +relative to the destination window's origin. +If +.PN XTranslateCoordinates +returns +.PN False , +src_w and dest_w are on different screens, +and dest_x_return and dest_y_return are zero. +If the coordinates are contained in a mapped child of dest_w, +that child is returned to child_return. +Otherwise, child_return is set to +.PN None . +.LP +.PN XTranslateCoordinates +can generate a +.PN BadWindow +error. +.LP +.sp +To obtain the screen coordinates of the pointer +or to determine the pointer coordinates relative to a specified window, use +.PN XQueryPointer . +.IN "XQueryPointer" "" "@DEF@" +.sM +.FD 0 +Bool XQueryPointer\^(\^\fIdisplay\fP, \fIw\fP\^, \fIroot_return\fP\^, \fIchild_return\fP\^, \fIroot_x_return\fP\^, \fIroot_y_return\fP\^, +.br + \fIwin_x_return\fP\^, \fIwin_y_return\fP\^, \fImask_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + Window *\fIroot_return\fP\^, *\fIchild_return\fP\^; +.br + int *\fIroot_x_return\fP\^, *\fIroot_y_return\fP\^; +.br + int *\fIwin_x_return\fP\^, *\fIwin_y_return\fP\^; +.br + unsigned int *\fImask_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.ds Ro that the pointer is in +.IP \fIroot_return\fP 1i +Returns the root window \*(Ro. +.IP \fIchild_return\fP 1i +Returns the child window that the pointer is located in, if any. +.IP \fIroot_x_return\fP 1i +.br +.ns +.IP \fIroot_y_return\fP 1i +Return the pointer coordinates relative to the root window's origin. +.IP \fIwin_x_return\fP 1i +.br +.ns +.IP \fIwin_y_return\fP 1i +Return the pointer coordinates relative to the specified window. +.IP \fImask_return\fP 1i +Returns the current state of the modifier keys and pointer buttons. +.LP +.eM +The +.PN XQueryPointer +function returns the root window the pointer is logically on and the pointer +coordinates relative to the root window's origin. +If +.PN XQueryPointer +returns +.PN False , +the pointer is not on the same screen as the specified window, and +.PN XQueryPointer +returns +.PN None +to child_return and zero to win_x_return and win_y_return. +If +.PN XQueryPointer +returns +.PN True , +the pointer coordinates returned to win_x_return and win_y_return +are relative to the origin of the specified window. +In this case, +.PN XQueryPointer +returns the child that contains the pointer, if any, +or else +.PN None +to child_return. +.LP +.PN XQueryPointer +returns the current logical state of the keyboard buttons +and the modifier keys in mask_return. +It sets mask_return to the bitwise inclusive OR of one or more +of the button or modifier key bitmasks to match +the current state of the mouse buttons and the modifier keys. +.LP +Note that the logical state of a device (as seen through Xlib) +may lag the physical state if device event processing is frozen +(see section 12.1). +.LP +.PN XQueryPointer +can generate a +.PN BadWindow +error. +.NH 2 +Properties and Atoms +.XS +\*(SN Properties and Atoms +.XE +.LP +A property is a collection of named, typed data. +The window system has a set of predefined properties +.IN "Atom" "predefined" +(for example, the name of a window, size hints, and so on), and users can +define any other arbitrary information and associate it with windows. +Each property has a name, +which is an ISO Latin-1 string. +For each named property, +a unique identifier (atom) is associated with it. +A property also has a type, for example, string or integer. +These types are also indicated using atoms, so arbitrary new +types can be defined. +Data of only one type may be associated with a single +property name. +Clients can store and retrieve properties associated with windows. +For efficiency reasons, +an atom is used rather than a character string. +.PN XInternAtom +can be used to obtain the atom for property names. +.IN "Atom" +.LP +A property is also stored in one of several possible formats. +The X server can store the information as 8-bit quantities, 16-bit +quantities, or 32-bit quantities. +This permits the X server to present the data in the byte order that the +client expects. +.NT Note +If you define further properties of complex type, +you must encode and decode them yourself. +These functions must be carefully written if they are to be portable. +For further information about how to write a library extension, +see appendix C. +.NE +The type of a property is defined by an atom, which allows for +arbitrary extension in this type scheme. +.IN "Atom" +.LP +Certain property names are +predefined in the server for commonly used functions. +The atoms for these properties are defined in +.hN X11/Xatom.h . +To avoid name clashes with user symbols, the +.PN #define +name for each atom has the XA_ prefix. +For an explanation of the functions that let you get and set +much of the information stored in these predefined properties, +see chapter 14. +.LP +The core protocol imposes no semantics on these property names, +but semantics are specified in other X Consortium standards, +such as the \fIInter-Client Communication Conventions Manual\fP +and the \fIX Logical Font Description Conventions\fP. +.LP +You can use properties to communicate other information between +applications. +The functions described in this section let you define new properties +and get the unique atom IDs in your applications. +.LP +Although any particular atom can have some client interpretation +within each of the name spaces, +atoms occur in five distinct name spaces within the protocol: +.IP \(bu 5 +Selections +.IP \(bu 5 +Property names +.IP \(bu 5 +Property types +.IP \(bu 5 +Font properties +.IP \(bu 5 +Type of a +.PN ClientMessage +event (none are built into the X server) +.LP +.LP +The built-in selection property names are: +.LP +.Ds 0 +.TA .5i 1.5i 3i +.ta .5i 1.5i 3i +.R +PRIMARY +SECONDARY +.De +.LP +The built-in property names are: +.TS +lw(2i) lw(2i). +.sp 6p +CUT_BUFFER0 RESOURCE_MANAGER +CUT_BUFFER1 WM_CLASS +CUT_BUFFER2 WM_CLIENT_MACHINE +CUT_BUFFER3 WM_COLORMAP_WINDOWS +CUT_BUFFER4 WM_COMMAND +CUT_BUFFER5 WM_HINTS +CUT_BUFFER6 WM_ICON_NAME +CUT_BUFFER7 WM_ICON_SIZE +RGB_BEST_MAP WM_NAME +RGB_BLUE_MAP WM_NORMAL_HINTS +RGB_DEFAULT_MAP WM_PROTOCOLS +RGB_GRAY_MAP WM_STATE +RGB_GREEN_MAP WM_TRANSIENT_FOR +RGB_RED_MAP WM_ZOOM_HINTS +.sp 6p +.TE +.LP +The built-in property types are: +.LP +.TS +lw(2i) lw(2i). +.sp 6p +ARC POINT +ATOM RGB_COLOR_MAP +BITMAP RECTANGLE +CARDINAL STRING +COLORMAP VISUALID +CURSOR WINDOW +DRAWABLE WM_HINTS +FONT WM_SIZE_HINTS +INTEGER +PIXMAP +.sp 6p +.TE +.LP +The built-in font property names are: +.TS +lw(2i) lw(2i). +.sp 6p +MIN_SPACE STRIKEOUT_DESCENT +NORM_SPACE STRIKEOUT_ASCENT +MAX_SPACE ITALIC_ANGLE +END_SPACE X_HEIGHT +SUPERSCRIPT_X QUAD_WIDTH +SUPERSCRIPT_Y WEIGHT +SUBSCRIPT_X POINT_SIZE +SUBSCRIPT_Y RESOLUTION +UNDERLINE_POSITION COPYRIGHT +UNDERLINE_THICKNESS NOTICE +FONT_NAME FAMILY_NAME +FULL_NAME CAP_HEIGHT +.sp 6p +.TE +.LP +For further information about font properties, +see section 8.5. +.LP +.sp +To return an atom for a given name, use +.PN XInternAtom . +.IN "Atom" "interning" +.IN "XInternAtom" "" "@DEF@" +.sM +.FD 0 +Atom XInternAtom\^(\^\fIdisplay\fP, \fIatom_name\fP\^, \fIonly_if_exists\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + char *\fIatom_name\fP\^; +.br + Bool \fIonly_if_exists\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIatom_name\fP 1i +Specifies the name associated with the atom you want returned. +.IP \fIonly_if_exists\fP 1i +Specifies a Boolean value that indicates whether the atom must be created. +.LP +.eM +The +.PN XInternAtom +function returns the atom identifier associated with the specified atom_name +string. +If only_if_exists is +.PN False , +the atom is created if it does not exist. +Therefore, +.PN XInternAtom +can return +.PN None . +If the atom name is not in the Host Portable Character Encoding, +the result is implementation-dependent. +Uppercase and lowercase matter; +the strings ``thing'', ``Thing'', and ``thinG'' +all designate different atoms. +The atom will remain defined even after the client's connection closes. +It will become undefined only when the last connection to +the X server closes. +.LP +.PN XInternAtom +can generate +.PN BadAlloc +and +.PN BadValue +errors. +.LP +.sp +To return atoms for an array of names, use +.PN XInternAtoms . +.IN "Atom" "interning" +.IN "XInternAtoms" "" "@DEF@" +.sM +.FD 0 +Status XInternAtoms\^(\^\fIdisplay\fP, \fInames\fP\^, \fIcount\fP\^, \fIonly_if_exists\fP, \fIatoms_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + char **\fInames\fP\^; +.br + int \fIcount\fP\^; +.br + Bool \fIonly_if_exists\fP\^; +.br + Atom *\fIatoms_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fInames\fP 1i +Specifies the array of atom names. +.ds Cn atom names in the array +.IP \fIcount\fP 1i +Specifies the number of \*(Cn. +.IP \fIonly_if_exists\fP 1i +Specifies a Boolean value that indicates whether the atom must be created. +.IP \fIatoms_return\fP 1i +Returns the atoms. +.LP +.eM +The +.PN XInternAtoms +function returns the atom identifiers associated with the specified names. +The atoms are stored in the atoms_return array supplied by the caller. +Calling this function is equivalent to calling +.PN XInternAtom +for each of the names in turn with the specified value of only_if_exists, +but this function minimizes the number of round-trip protocol exchanges +between the client and the X server. +.LP +This function returns a nonzero status if atoms are returned for +all of the names; +otherwise, it returns zero. +.LP +.PN XInternAtoms +can generate +.PN BadAlloc +and +.PN BadValue +errors. +.LP +.sp +To return a name for a given atom identifier, use +.PN XGetAtomName . +.IN "Atom" "getting name" +.IN "XGetAtomName" "" "@DEF@" +.sM +.FD 0 +char *XGetAtomName\^(\^\fIdisplay\fP, \fIatom\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Atom \fIatom\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIatom\fP 1i +Specifies the atom for the property name you want returned. +.LP +.eM +The +.PN XGetAtomName +function returns the name associated with the specified atom. +If the data returned by the server is in the Latin Portable Character Encoding, +then the returned string is in the Host Portable Character Encoding. +Otherwise, the result is implementation-dependent. +To free the resulting string, +call +.PN XFree . +.LP +.PN XGetAtomName +can generate a +.PN BadAtom +error. +.LP +.sp +To return the names for an array of atom identifiers, use +.PN XGetAtomNames . +.IN "Atom" "getting name" +.IN "XGetAtomNames" "" "@DEF@" +.sM +.FD 0 +Status XGetAtomNames\^(\^\fIdisplay\fP, \fIatoms\fP, \fIcount\fP\^, \fInames_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Atom *\fIatoms\fP\^; +.br + int \fIcount\fP\^; +.br + char **\fInames_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIatoms\fP 1i +Specifies the array of atoms. +.ds Cn atoms in the array +.IP \fIcount\fP 1i +Specifies the number of \*(Cn. +.IP \fInames_return\fP 1i +Returns the atom names. +.LP +.eM +The +.PN XGetAtomNames +function returns the names associated with the specified atoms. +The names are stored in the names_return array supplied by the caller. +Calling this function is equivalent to calling +.PN XGetAtomName +for each of the atoms in turn, +but this function minimizes the number of round-trip protocol exchanges +between the client and the X server. +.LP +This function returns a nonzero status if names are returned for +all of the atoms; +otherwise, it returns zero. +.LP +.PN XGetAtomNames +can generate a +.PN BadAtom +error. +.NH 2 +Obtaining and Changing Window Properties +.XS +\*(SN Obtaining and Changing Window Properties +.XE +.LP +You can attach a property list to every window. +Each property has a name, a type, and a value (see section 4.3). +The value is an array of 8-bit, 16-bit, or 32-bit quantities, +whose interpretation is left to the clients. The type +.PN char +is used to represent 8-bit quantities, the type +.PN short +is used to represent 16-bit quantities, and the type +.PN long +is used to represent 32-bit quantities. +.LP +Xlib provides functions that you can use to obtain, +change, update, or interchange window properties. +In addition, Xlib provides other utility functions for inter-client +communication (see chapter 14). +.LP +.sp +To obtain the type, format, and value of a property of a given window, use +.PN XGetWindowProperty . +.IN "Property" "getting" +.LP +.IN "XGetWindowProperty" "" "@DEF@" +.sM +.FD 0 +int XGetWindowProperty\^(\^\fIdisplay\fP, \fIw\fP\^, \fIproperty\fP\^, \fIlong_offset\fP\^, \fIlong_length\fP\^, \fIdelete\fP\^, \fIreq_type\fP\^, +.br + \fIactual_type_return\fP\^, \fIactual_format_return\fP\^, \fInitems_return\fP\^, \fIbytes_after_return\fP\^, +.br + \fIprop_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + Atom \fIproperty\fP\^; +.br + long \fIlong_offset\fP\^, \fIlong_length\fP\^; +.br + Bool \fIdelete\fP\^; +.br + Atom \fIreq_type\fP\^; +.br + Atom *\fIactual_type_return\fP\^; +.br + int *\fIactual_format_return\fP\^; +.br + unsigned long *\fInitems_return\fP\^; +.br + unsigned long *\fIbytes_after_return\fP\^; +.br + unsigned char **\fIprop_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.ds Wi whose property you want to obtain +.IP \fIw\fP 1i +Specifies the window \*(Wi. +.IP \fIproperty\fP 1i +Specifies the property name. +.IP \fIlong_offset\fP 1i +Specifies the offset in the specified property (in 32-bit quantities) +where the data is to be retrieved. +.IP \fIlong_length\fP 1i +Specifies the length in 32-bit multiples of the data to be retrieved. +.IP \fIdelete\fP 1i +Specifies a Boolean value that determines whether the property is deleted. +.IP \fIreq_type\fP 1i +Specifies the atom identifier associated with the property type or +.PN AnyPropertyType . +.IP \fIactual_type_return\fP 1i +Returns the atom identifier that defines the actual type of the property. +.IP \fIactual_format_return\fP 1i +Returns the actual format of the property. +.IP \fInitems_return\fP 1i +Returns the actual number of 8-bit, 16-bit, or 32-bit items +stored in the prop_return data. +.IP \fIbytes_after_return\fP 1i +Returns the number of bytes remaining to be read in the property if +a partial read was performed. +.IP \fIprop_return\fP 1i +Returns the data in the specified format. +.LP +.eM +The +.PN XGetWindowProperty +function returns the actual type of the property; the actual format of the property; +the number of 8-bit, 16-bit, or 32-bit items transferred; the number of bytes remaining +to be read in the property; and a pointer to the data actually returned. +.PN XGetWindowProperty +sets the return arguments as follows: +.IP \(bu 5 +If the specified property does not exist for the specified window, +.PN XGetWindowProperty +returns +.PN None +to actual_type_return and the value zero to +actual_format_return and bytes_after_return. +The nitems_return argument is empty. +In this case, the delete argument is ignored. +.IP \(bu 5 +If the specified property exists +but its type does not match the specified type, +.PN XGetWindowProperty +returns the actual property type to actual_type_return, +the actual property format (never zero) to actual_format_return, +and the property length in bytes +(even if the actual_format_return is 16 or 32) +to bytes_after_return. +It also ignores the delete argument. +The nitems_return argument is empty. +.IP \(bu 5 +If the specified property exists and either you assign +.PN AnyPropertyType +to the req_type argument or the specified type matches the actual property type, +.PN XGetWindowProperty +returns the actual property type to actual_type_return and the actual +property format (never zero) to actual_format_return. +It also returns a value to bytes_after_return and nitems_return, by +defining the following +values: +.IP +.nf + N = actual length of the stored property in bytes + (even if the format is 16 or 32) + I = 4 * long_offset + T = N - I + L = MINIMUM(T, 4 * long_length) + A = N - (I + L) +.fi +.IP +The returned value starts at byte index I in the property (indexing +from zero), and its length in bytes is L. +If the value for long_offset causes L to be negative, +a +.PN BadValue +error results. +The value of bytes_after_return is A, +giving the number of trailing unread bytes in the stored property. +.LP +If the returned format is 8, the returned data is represented as a +.PN char +array. +If the returned format is 16, the returned data is represented as a +.PN short +array and should be cast to that type to obtain the elements. +If the returned format is 32, the returned data is represented as a +.PN long +array and should be cast to that type to obtain the elements. +.LP +.PN XGetWindowProperty +always allocates one extra byte in prop_return +(even if the property is zero length) +and sets it to zero so that simple properties consisting of characters +do not have to be copied into yet another string before use. +.LP +If delete is +.PN True +and bytes_after_return is zero, +.PN XGetWindowProperty +deletes the property +from the window and generates a +.PN PropertyNotify +event on the window. +.LP +The function returns +.PN Success +if it executes successfully. +To free the resulting data, +use +.PN XFree . +.LP +.PN XGetWindowProperty +can generate +.PN BadAtom , +.PN BadValue , +and +.PN BadWindow +errors. +.LP +.sp +To obtain a given window's property list, use +.PN XListProperties . +.IN "Property" "listing" +.IN "XListProperties" "" "@DEF@" +.sM +.FD 0 +Atom *XListProperties\^(\^\fIdisplay\fP, \fIw\fP\^, \fInum_prop_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + int *\fInum_prop_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.ds Wi whose property list you want to obtain +.IP \fIw\fP 1i +Specifies the window \*(Wi. +.IP \fInum_prop_return\fP 1i +Returns the length of the properties array. +.LP +.eM +The +.PN XListProperties +function returns a pointer to an array of atom properties that are defined for +the specified window or returns NULL if no properties were found. +To free the memory allocated by this function, use +.PN XFree . +.LP +.PN XListProperties +can generate a +.PN BadWindow +error. +.LP +.sp +To change a property of a given window, use +.PN XChangeProperty . +.IN "Property" "changing" +.IN "Property" "appending" +.IN "Property" "prepending" +.IN "Property" "replacing" +.IN "Property" "format" +.IN "Property" "type" +.IN "XChangeProperty" "" "@DEF@" +.sM +.FD 0 +XChangeProperty\^(\^\fIdisplay\fP, \fIw\fP\^, \fIproperty\fP\^, \fItype\fP\^, \fIformat\fP\^, \fImode\fP\^, \fIdata\fP\^, \fInelements\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + Atom \fIproperty\fP\^, \fItype\fP\^; +.br + int \fIformat\fP\^; +.br + int \fImode\fP\^; +.br + unsigned char *\fIdata\fP\^; +.br + int \fInelements\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.ds Wi whose property you want to change +.IP \fIw\fP 1i +Specifies the window \*(Wi. +.IP \fIproperty\fP 1i +Specifies the property name. +.IP \fItype\fP 1i +Specifies the type of the property. +The X server does not interpret the type but simply +passes it back to an application that later calls +.PN XGetWindowProperty . +.IP \fIformat\fP 1i +Specifies whether the data should be viewed as a list +of 8-bit, 16-bit, or 32-bit quantities. +Possible values are 8, 16, and 32. +This information allows the X server to correctly perform +byte-swap operations as necessary. +If the format is 16-bit or 32-bit, +you must explicitly cast your data pointer to an (unsigned char *) in the call +to +.PN XChangeProperty . +.\" Changed name of this file to prop_mode.a on 1/13/87 +.IP \fImode\fP 1i +Specifies the mode of the operation. +You can pass +.PN PropModeReplace , +.PN PropModePrepend , +or +.PN PropModeAppend . +.IP \fIdata\fP 1i +Specifies the property data. +.IP \fInelements\fP 1i +Specifies the number of elements of the specified data format. +.LP +.eM +The +.PN XChangeProperty +function alters the property for the specified window and +causes the X server to generate a +.PN PropertyNotify +event on that window. +.PN XChangeProperty +performs the following: +.IP \(bu 5 +If mode is +.PN PropModeReplace , +.PN XChangeProperty +discards the previous property value and stores the new data. +.IP \(bu 5 +If mode is +.PN PropModePrepend +or +.PN PropModeAppend , +.PN XChangeProperty +inserts the specified data before the beginning of the existing data +or onto the end of the existing data, respectively. +The type and format must match the existing property value, +or a +.PN BadMatch +error results. +If the property is undefined, +it is treated as defined with the correct type and +format with zero-length data. +.LP +If the specified format is 8, the property data must be a +.PN char +array. +If the specified format is 16, the property data must be a +.PN short +array. +If the specified format is 32, the property data must be a +.PN long +array. +.LP +The lifetime of a property is not tied to the storing client. +Properties remain until explicitly deleted, until the window is destroyed, +or until the server resets. +For a discussion of what happens when the connection to the X server is closed, +see section 2.6. +The maximum size of a property is server dependent and can vary dynamically +depending on the amount of memory the server has available. +(If there is insufficient space, a +.PN BadAlloc +error results.) +.LP +.PN XChangeProperty +can generate +.PN BadAlloc , +.PN BadAtom , +.PN BadMatch , +.PN BadValue , +and +.PN BadWindow +errors. +.LP +.sp +To rotate a window's property list, use +.PN XRotateWindowProperties . +.LP +.IN "XRotateWindowProperties" "" "@DEF@" +.sM +.FD 0 +XRotateWindowProperties\^(\^\fIdisplay\fP, \fIw\fP, \fIproperties\fP, \fInum_prop\fP, \fInpositions\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + Atom \fIproperties\fP\^[]\^; +.br + int \fInum_prop\fP\^; +.br + int \fInpositions\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fIproperties\fP 1i +Specifies the array of properties that are to be rotated. +.IP \fInum_prop\fP 1i +Specifies the length of the properties array. +.IP \fInpositions\fP 1i +Specifies the rotation amount. +.LP +.eM +The +.PN XRotateWindowProperties +function allows you to rotate properties on a window and causes +the X server to generate +.PN PropertyNotify +events. +If the property names in the properties array are viewed as being numbered +starting from zero and if there are num_prop property names in the list, +then the value associated with property name I becomes the value associated +with property name (I + npositions) mod N for all I from zero to N \- 1. +The effect is to rotate the states by npositions places around the virtual ring +of property names (right for positive npositions, +left for negative npositions). +If npositions mod N is nonzero, +the X server generates a +.PN PropertyNotify +event for each property in the order that they are listed in the array. +If an atom occurs more than once in the list or no property with that +name is defined for the window, +a +.PN BadMatch +error results. +If a +.PN BadAtom +or +.PN BadMatch +error results, +no properties are changed. +.LP +.PN XRotateWindowProperties +can generate +.PN BadAtom , +.PN BadMatch , +and +.PN BadWindow +errors. +.LP +.sp +To delete a property on a given window, use +.PN XDeleteProperty . +.IN "Property" "deleting" +.IN "XDeleteProperty" "" "@DEF@" +.sM +.FD 0 +XDeleteProperty\^(\^\fIdisplay\fP, \fIw\fP\^, \fIproperty\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + Atom \fIproperty\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.ds Wi whose property you want to delete +.IP \fIw\fP 1i +Specifies the window \*(Wi. +.IP \fIproperty\fP 1i +Specifies the property name. +.LP +.eM +The +.PN XDeleteProperty +function deletes the specified property only if the +property was defined on the specified window +and causes the X server to generate a +.PN PropertyNotify +event on the window unless the property does not exist. +.LP +.PN XDeleteProperty +can generate +.PN BadAtom +and +.PN BadWindow +errors. +.NH 2 +Selections +.XS +\*(SN Selections +.XE +.LP +.IN "Selection" +Selections are one method used by applications to exchange data. +By using the property mechanism, +applications can exchange data of arbitrary types and can negotiate +the type of the data. +A selection can be thought of as an indirect property with a dynamic type. +That is, rather than having the property stored in the X server, +the property is maintained by some client (the owner). +A selection is global in nature (considered to belong to the user +but be maintained by clients) rather than being private to a particular +window subhierarchy or a particular set of clients. +.LP +Xlib provides functions that you can use to set, get, or request conversion +of selections. +This allows applications to implement the notion of current selection, +which requires that notification be sent to applications when they no +longer own the selection. +Applications that support selection often highlight the current selection +and so must be informed when another application has +acquired the selection so that they can unhighlight the selection. +.LP +When a client asks for the contents of +a selection, it specifies a selection target type. +This target type +can be used to control the transmitted representation of the contents. +For example, if the selection is ``the last thing the user clicked on'' +and that is currently an image, then the target type might specify +whether the contents of the image should be sent in XY format or Z format. +.LP +The target type can also be used to control the class of +contents transmitted, for example, +asking for the ``looks'' (fonts, line +spacing, indentation, and so forth) of a paragraph selection, not the +text of the paragraph. +The target type can also be used for other +purposes. +The protocol does not constrain the semantics. +.LP +.sp +To set the selection owner, use +.PN XSetSelectionOwner . +.IN "Selection" "setting the owner" +.IN "XSetSelectionOwner" "" "@DEF@" +.sM +.FD 0 +XSetSelectionOwner\^(\^\fIdisplay\fP, \fIselection\fP\^, \fIowner\fP\^, \fItime\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Atom \fIselection\fP\^; +.br + Window \fIowner\fP\^; +.br + Time \fItime\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIselection\fP 1i +Specifies the selection atom. +.IP \fIowner\fP 1i +Specifies the owner of the specified selection atom. +You can pass a window or +.PN None . +.IP \fItime\fP 1i +Specifies the time. +You can pass either a timestamp or +.PN CurrentTime . +.LP +.eM +The +.PN XSetSelectionOwner +function changes the owner and last-change time for the specified selection +and has no effect if the specified time is earlier than the current +last-change time of the specified selection +or is later than the current X server time. +Otherwise, the last-change time is set to the specified time, +with +.PN CurrentTime +replaced by the current server time. +If the owner window is specified as +.PN None , +then the owner of the selection becomes +.PN None +(that is, no owner). +Otherwise, the owner of the selection becomes the client executing +the request. +.LP +If the new owner (whether a client or +.PN None ) +is not +the same as the current owner of the selection and the current +owner is not +.PN None , +the current owner is sent a +.PN SelectionClear +event. +If the client that is the owner of a selection is later +terminated (that is, its connection is closed) +or if the owner window it has specified in the request is later +destroyed, +the owner of the selection automatically +reverts to +.PN None , +but the last-change time is not affected. +The selection atom is uninterpreted by the X server. +.PN XGetSelectionOwner +returns the owner window, which is reported in +.PN SelectionRequest +and +.PN SelectionClear +events. +Selections are global to the X server. +.LP +.PN XSetSelectionOwner +can generate +.PN BadAtom +and +.PN BadWindow +errors. +.LP +.sp +To return the selection owner, use +.PN XGetSelectionOwner . +.IN "Selection" "getting the owner" +.IN "XGetSelectionOwner" "" "@DEF@" +.sM +.FD 0 +Window XGetSelectionOwner\^(\^\fIdisplay\fP, \fIselection\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Atom \fIselection\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.ds Se whose owner you want returned +.IP \fIselection\fP 1i +Specifies the selection atom \*(Se. +.LP +.eM +The +.PN XGetSelectionOwner +function +returns the window ID associated with the window that currently owns the +specified selection. +If no selection was specified, the function returns the constant +.PN None . +If +.PN None +is returned, +there is no owner for the selection. +.LP +.PN XGetSelectionOwner +can generate a +.PN BadAtom +error. +.LP +.sp +To request conversion of a selection, use +.PN XConvertSelection . +.IN "Selection" "converting" +.IN "XConvertSelection" "" "@DEF@" +.sM +.FD 0 +XConvertSelection\^(\^\fIdisplay\fP, \fIselection\fP\^, \fItarget\fP\^, \fIproperty\fP\^, \fIrequestor\fP\^, \fItime\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Atom \fIselection\fP\^, \fItarget\fP\^; +.br + Atom \fIproperty\fP\^; +.br + Window \fIrequestor\fP\^; +.br + Time \fItime\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIselection\fP 1i +Specifies the selection atom. +.IP \fItarget\fP 1i +Specifies the target atom. +.IP \fIproperty\fP 1i +Specifies the property name. +You also can pass +.PN None . +.IP \fIrequestor\fP 1i +Specifies the requestor. +.IP \fItime\fP 1i +Specifies the time. +You can pass either a timestamp or +.PN CurrentTime . +.LP +.eM +.PN XConvertSelection +requests that the specified selection be converted to the specified target +type: +.IP \(bu 5 +If the specified selection has an owner, the X server sends a +.PN SelectionRequest +event to that owner. +.IP \(bu 5 +If no owner for the specified +selection exists, the X server generates a +.PN SelectionNotify +event to the +requestor with property +.PN None . +.LP +The arguments are passed on unchanged in either of the events. +There are two predefined selection atoms: PRIMARY and SECONDARY. +.LP +.PN XConvertSelection +can generate +.PN BadAtom +and +.PN BadWindow +errors. +.bp diff --git a/libX11/specs/libX11/CH05 b/libX11/specs/libX11/CH05 new file mode 100644 index 000000000..6ea218378 --- /dev/null +++ b/libX11/specs/libX11/CH05 @@ -0,0 +1,518 @@ +.\" Copyright \(co 1985, 1986, 1987, 1988, 1989, 1990, 1991, 1994, 1996 X Consortium +.\" +.\" 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 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 X CONSORTIUM 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 X Consortium 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 X Consortium. +.\" +.\" Copyright \(co 1985, 1986, 1987, 1988, 1989, 1990, 1991 by +.\" Digital Equipment Corporation +.\" +.\" Portions Copyright \(co 1990, 1991 by +.\" Tektronix, Inc. +.\" +.\" Permission to use, copy, modify and distribute this documentation for +.\" any purpose and without fee is hereby granted, provided that the above +.\" copyright notice appears in all copies and that both that copyright notice +.\" and this permission notice appear in all copies, and that the names of +.\" Digital and Tektronix not be used in in advertising or publicity pertaining +.\" to this documentation without specific, written prior permission. +.\" Digital and Tektronix makes no representations about the suitability +.\" of this documentation for any purpose. +.\" It is provided ``as is'' without express or implied warranty. +.\" +\& +.sp 1 +.ce 3 +\s+1\fBChapter 5\fP\s-1 + +\s+1\fBPixmap and Cursor Functions\fP\s-1 +.sp 2 +.nr H1 5 +.nr H2 0 +.nr H3 0 +.nr H4 0 +.nr H5 0 +.na +.LP +.XS +Chapter 5: Pixmap and Cursor Functions +.XE +Once you have connected to an X server, +you can use the Xlib functions to: +.IP \(bu 5 +Create and free pixmaps +.IP \(bu 5 +Create, recolor, and free cursors +.NH 2 +Creating and Freeing Pixmaps +.XS +\*(SN Creating and Freeing Pixmaps +.XE +.LP +Pixmaps can only be used on the screen on which they were created. +Pixmaps are off-screen resources that are used for various operations, +such as defining cursors as tiling patterns +or as the source for certain raster operations. +Most graphics requests can operate either on a window or on a pixmap. +A bitmap is a single bit-plane pixmap. +.LP +.sp +To create a pixmap of a given size, use +.PN XCreatePixmap . +.IN "XCreatePixmap" "" "@DEF@" +.sM +.FD 0 +Pixmap XCreatePixmap\^(\^\fIdisplay\fP, \fId\fP\^, \fIwidth\fP\^, \fIheight\fP\^, \fIdepth\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Drawable \fId\fP\^; +.br + unsigned int \fIwidth\fP\^, \fIheight\fP\^; +.br + unsigned int \fIdepth\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fId\fP 1i +Specifies which screen the pixmap is created on. +.ds Wh , which define the dimensions of the pixmap +.IP \fIwidth\fP 1i +.br +.ns +.IP \fIheight\fP 1i +Specify the width and height\*(Wh. +.IP \fIdepth\fP 1i +Specifies the depth of the pixmap. +.LP +.eM +The +.PN XCreatePixmap +function creates a pixmap of the width, height, and depth you specified +and returns a pixmap ID that identifies it. +It is valid to pass an +.PN InputOnly +window to the drawable argument. +The width and height arguments must be nonzero, +or a +.PN BadValue +error results. +The depth argument must be one of the depths supported by the screen +of the specified drawable, +or a +.PN BadValue +error results. +.LP +The server uses the specified drawable to determine on which screen +to create the pixmap. +The pixmap can be used only on this screen +and only with other drawables of the same depth (see +.PN XCopyPlane +for an exception to this rule). +The initial contents of the pixmap are undefined. +.LP +.PN XCreatePixmap +can generate +.PN BadAlloc , +.PN BadDrawable , +and +.PN BadValue +errors. +.LP +.sp +To free all storage associated with a specified pixmap, use +.PN XFreePixmap . +.IN "XFreePixmap" "" "@DEF@" +.sM +.FD 0 +XFreePixmap\^(\^\fIdisplay\fP, \fIpixmap\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Pixmap \fIpixmap\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIpixmap\fP 1i +Specifies the pixmap. +.LP +.eM +The +.PN XFreePixmap +function first deletes the association between the pixmap ID and the pixmap. +Then, the X server frees the pixmap storage when there are no references to it. +The pixmap should never be referenced again. +.LP +.PN XFreePixmap +can generate a +.PN BadPixmap +error. +.NH 2 +Creating, Recoloring, and Freeing Cursors +.XS +\*(SN Creating, Recoloring, and Freeing Cursors +.XE +.LP +Each window can have a different cursor defined for it. +Whenever the pointer is in a visible window, +it is set to the cursor defined for that window. +If no cursor was defined for that window, +the cursor is the one defined for the parent window. +.LP +From X's perspective, +a cursor consists of a cursor source, mask, colors, and a hotspot. +The mask pixmap determines the shape of the cursor and must be a depth +of one. +The source pixmap must have a depth of one, +and the colors determine the colors of the source. +The hotspot defines the point on the cursor that is reported +when a pointer event occurs. +There may be limitations imposed by the hardware on +cursors as to size and whether a mask is implemented. +.IN "XQueryBestCursor" +.PN XQueryBestCursor +can be used to find out what sizes are possible. +There is a standard font for creating cursors, but +Xlib provides functions that you can use to create cursors +from an arbitrary font or from bitmaps. +.LP +.sp +To create a cursor from the standard cursor font, use +.PN XCreateFontCursor . +.IN "XCreateFontCursor" "" "@DEF@" +.sM +.FD 0 +#include +.sp 6p +Cursor XCreateFontCursor\^(\^\fIdisplay\fP, \fIshape\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + unsigned int \fIshape\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIshape\fP 1i +Specifies the shape of the cursor. +.LP +.eM +X provides a set of standard cursor shapes in a special font named +cursor. +Applications are encouraged to use this interface for their cursors +because the font can be customized for the individual display type. +The shape argument specifies which glyph of the standard fonts +to use. +.LP +The hotspot comes from the information stored in the cursor font. +The initial colors of a cursor are a black foreground and a white +background (see +.PN XRecolorCursor ). +For further information about cursor shapes, +see appendix B. +.LP +.PN XCreateFontCursor +can generate +.PN BadAlloc +and +.PN BadValue +errors. +.LP +.sp +To create a cursor from font glyphs, use +.PN XCreateGlyphCursor . +.IN "XCreateGlyphCursor" "" "@DEF@" +.sM +.FD 0 +Cursor XCreateGlyphCursor\^(\^\fIdisplay\fP, \fIsource_font\fP\^, \fImask_font\fP\^, \fIsource_char\fP\^, \fImask_char\fP\^, +.br + \fIforeground_color\fP\^, \fIbackground_color\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Font \fIsource_font\fP\^, \fImask_font\fP\^; +.br + unsigned int \fIsource_char\fP\^, \fImask_char\fP\^; +.br + XColor *\fIforeground_color\fP\^; +.br + XColor *\fIbackground_color\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIsource_font\fP 1i +Specifies the font for the source glyph. +.IP \fImask_font\fP 1i +Specifies the font for the mask glyph or +.PN None . +.IP \fIsource_char\fP 1i +Specifies the character glyph for the source. +.IP \fImask_char\fP 1i +Specifies the glyph character for the mask. +.IP \fIforeground_color\fP 1i +Specifies the RGB values for the foreground of the source. +.IP \fIbackground_color\fP 1i +Specifies the RGB values for the background of the source. +.LP +.eM +The +.PN XCreateGlyphCursor +function is similar to +.PN XCreatePixmapCursor +except that the source and mask bitmaps are obtained from the specified +font glyphs. +The source_char must be a defined glyph in source_font, +or a +.PN BadValue +error results. +If mask_font is given, +mask_char must be a defined glyph in mask_font, +or a +.PN BadValue +error results. +The mask_font and character are optional. +The origins of the source_char and mask_char (if defined) glyphs are +positioned coincidently and define the hotspot. +The source_char and mask_char need not have the same bounding box metrics, +and there is no restriction on the placement of the hotspot relative to the bounding +boxes. +If no mask_char is given, all pixels of the source are displayed. +You can free the fonts immediately by calling +.PN XFreeFont +if no further explicit references to them are to be made. +.LP +For 2-byte matrix fonts, +the 16-bit value should be formed with the byte1 +member in the most significant byte and the byte2 member in the +least significant byte. +.LP +.PN XCreateGlyphCursor +can generate +.PN BadAlloc , +.PN BadFont , +and +.PN BadValue +errors. +.LP +.sp +To create a cursor from two bitmaps, +use +.PN XCreatePixmapCursor . +.IN "XCreatePixmapCursor" "" "@DEF@" +.sM +.FD 0 +Cursor XCreatePixmapCursor\^(\^\fIdisplay\fP, \fIsource\fP\^, \fImask\fP\^, \fIforeground_color\fP\^, \fIbackground_color\fP\^, \fIx\fP\^, \fIy\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Pixmap \fIsource\fP\^; +.br + Pixmap \fImask\fP\^; +.br + XColor *\fIforeground_color\fP\^; +.br + XColor *\fIbackground_color\fP\^; +.br + unsigned int \fIx\fP\^, \fIy\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIsource\fP 1i +Specifies the shape of the source cursor. +.\" *** JIM: NEED TO CHECK THIS. *** +.IP \fImask\fP 1i +Specifies the cursor's source bits to be displayed or +.PN None . +.IP \fIforeground_color\fP 1i +Specifies the RGB values for the foreground of the source. +.IP \fIbackground_color\fP 1i +Specifies the RGB values for the background of the source. +.ds Xy , which indicate the hotspot relative to the source's origin +.IP \fIx\fP 1i +.br +.ns +.IP \fIy\fP 1i +Specify the x and y coordinates\*(Xy. +.LP +.eM +The +.PN XCreatePixmapCursor +function creates a cursor and returns the cursor ID associated with it. +The foreground and background RGB values must be specified using +foreground_color and background_color, +even if the X server only has a +.PN StaticGray +or +.PN GrayScale +screen. +The foreground color is used for the pixels set to 1 in the +source, and the background color is used for the pixels set to 0. +Both source and mask, if specified, must have depth one (or a +.PN BadMatch +error results) but can have any root. +The mask argument defines the shape of the cursor. +The pixels set to 1 in the mask define which source pixels are displayed, +and the pixels set to 0 define which pixels are ignored. +If no mask is given, +all pixels of the source are displayed. +The mask, if present, must be the same size as the pixmap defined by the +source argument, or a +.PN BadMatch +error results. +The hotspot must be a point within the source, +or a +.PN BadMatch +error results. +.LP +The components of the cursor can be transformed arbitrarily to meet +display limitations. +The pixmaps can be freed immediately if no further explicit references +to them are to be made. +Subsequent drawing in the source or mask pixmap has an undefined effect on the +cursor. +The X server might or might not make a copy of the pixmap. +.LP +.PN XCreatePixmapCursor +can generate +.PN BadAlloc +and +.PN BadPixmap +errors. +.LP +.sp +To determine useful cursor sizes, use +.PN XQueryBestCursor . +.IN "XQueryBestCursor" "" "@DEF@" +.sM +.FD 0 +Status XQueryBestCursor\^(\^\fIdisplay\fP, \fId\fP, \fIwidth\fP\^, \fIheight\fP\^, \fIwidth_return\fP\^, \fIheight_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Drawable \fId\fP\^; +.br + unsigned int \fIwidth\fP\^, \fIheight\fP\^; +.br + unsigned int *\fIwidth_return\fP\^, *\fIheight_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.ds Dr , which indicates the screen +.IP \fId\fP 1i +Specifies the drawable\*(Dr. +.ds Wh \ of the cursor that you want the size information for +.IP \fIwidth\fP 1i +.br +.ns +.IP \fIheight\fP 1i +Specify the width and height\*(Wh. +.IP \fIwidth_return\fP 1i +.br +.ns +.IP \fIheight_return\fP 1i +Return the best width and height that is closest to the specified width +and height. +.LP +.eM +Some displays allow larger cursors than other displays. +The +.PN XQueryBestCursor +function provides a way to find out what size cursors are actually +possible on the display. +.IN "Cursor" "limitations" +It returns the largest size that can be displayed. +Applications should be prepared to use smaller cursors on displays that +cannot support large ones. +.LP +.PN XQueryBestCursor +can generate a +.PN BadDrawable +error. +.LP +.sp +To change the color of a given cursor, use +.PN XRecolorCursor . +.IN "XRecolorCursor" "" "@DEF@" +.sM +.FD 0 +XRecolorCursor\^(\^\fIdisplay\fP, \fIcursor\fP\^, \fIforeground_color\fP\^, \fIbackground_color\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Cursor \fIcursor\fP\^; +.br + XColor *\fIforeground_color\fP\^, *\fIbackground_color\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIcursor\fP 1i +Specifies the cursor. +.IP \fIforeground_color\fP 1i +Specifies the RGB values for the foreground of the source. +.IP \fIbackground_color\fP 1i +Specifies the RGB values for the background of the source. +.LP +.eM +The +.PN XRecolorCursor +function changes the color of the specified cursor, and +if the cursor is being displayed on a screen, +the change is visible immediately. +The pixel members of the +.PN XColor +structures are ignored; only the RGB values are used. +.LP +.PN XRecolorCursor +can generate a +.PN BadCursor +error. +.LP +.sp +To free (destroy) a given cursor, use +.PN XFreeCursor . +.IN "XFreeCursor" "" "@DEF@" +.sM +.FD 0 +XFreeCursor\^(\^\fIdisplay\fP, \fIcursor\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Cursor \fIcursor\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIcursor\fP 1i +Specifies the cursor. +.LP +.eM +The +.PN XFreeCursor +function deletes the association between the cursor resource ID +and the specified cursor. +The cursor storage is freed when no other resource references it. +The specified cursor ID should not be referred to again. +.LP +.PN XFreeCursor +can generate a +.PN BadCursor +error. +.bp diff --git a/libX11/specs/libX11/CH06 b/libX11/specs/libX11/CH06 new file mode 100644 index 000000000..44824d324 --- /dev/null +++ b/libX11/specs/libX11/CH06 @@ -0,0 +1,4773 @@ +.\" Copyright \(co 1985, 1986, 1987, 1988, 1989, 1990, 1991, 1994, 1996 X Consortium +.\" +.\" 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 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 X CONSORTIUM 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 X Consortium 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 X Consortium. +.\" +.\" Copyright \(co 1985, 1986, 1987, 1988, 1989, 1990, 1991 by +.\" Digital Equipment Corporation +.\" +.\" Portions Copyright \(co 1990, 1991 by +.\" Tektronix, Inc. +.\" +.\" Permission to use, copy, modify and distribute this documentation for +.\" any purpose and without fee is hereby granted, provided that the above +.\" copyright notice appears in all copies and that both that copyright notice +.\" and this permission notice appear in all copies, and that the names of +.\" Digital and Tektronix not be used in in advertising or publicity pertaining +.\" to this documentation without specific, written prior permission. +.\" Digital and Tektronix makes no representations about the suitability +.\" of this documentation for any purpose. +.\" It is provided ``as is'' without express or implied warranty. +.\" +\& +.sp 1 +.ce 3 +\s+1\fBChapter 6\fP\s-1 + +\s+1\fBColor Management Functions\fP\s-1 +.sp 2 +.nr H1 6 +.nr H2 0 +.nr H3 0 +.nr H4 0 +.nr H5 0 +.na +.LP +.XS +Chapter 6: Color Management Functions +.XE +Each X window always has an associated colormap that +provides a level of indirection between pixel values and colors displayed +on the screen. +Xlib provides functions that you can use to manipulate a colormap. +The X protocol defines colors using values in the RGB color space. +The RGB color space is device dependent; +rendering an RGB value on differing output devices typically results +in different colors. +Xlib also provides a means for clients to specify color using +device-independent color spaces for consistent results across devices. +Xlib supports device-independent color spaces derivable from the CIE XYZ +color space. +This includes the CIE XYZ, xyY, L*u*v*, and L*a*b* color spaces as well as +the TekHVC color space. +.LP +This chapter discusses how to: +.IP \(bu 5 +Create, copy, and destroy a colormap +.IP \(bu 5 +Specify colors by name or value +.IP \(bu 5 +Allocate, modify, and free color cells +.IP \(bu 5 +Read entries in a colormap +.IP \(bu 5 +Convert between color spaces +.IP \(bu 5 +Control aspects of color conversion +.IP \(bu 5 +Query the color gamut of a screen +.IP \(bu 5 +Add new color spaces +.LP +All functions, types, and symbols in this chapter with the prefix ``Xcms'' +are defined in +.hN X11/Xcms.h . +The remaining functions and types are defined in +.hN X11/Xlib.h . +.LP +Functions in this chapter manipulate the representation of color on the +screen. +For each possible value that a pixel can take in a window, +there is a color cell in the colormap. +For example, +if a window is 4 bits deep, pixel values 0 through 15 are defined. +A colormap is a collection of color cells. +A color cell consists of a triple of red, green, and blue (RGB) values. +The hardware imposes limits on the number of significant +bits in these values. +As each pixel is read out of display memory, the pixel +is looked up in a colormap. +The RGB value of the cell determines what color is displayed on the screen. +On a grayscale display with a black-and-white monitor, +the values are combined to determine the brightness on the screen. +.LP +Typically, an application allocates color cells or sets of color cells +to obtain the desired colors. +The client can allocate read-only cells. +In which case, +the pixel values for these colors can be shared among multiple applications, +and the RGB value of the cell cannot be changed. +If the client allocates read/write cells, +they are exclusively owned by the client, +and the color associated with the pixel value can be changed at will. +Cells must be allocated (and, if read/write, initialized with an RGB value) +by a client to obtain desired colors. +The use of pixel value for an +unallocated cell results in an undefined color. +.LP +Because colormaps are associated with windows, X supports displays +with multiple colormaps and, indeed, different types of colormaps. +If there are insufficient colormap resources in the display, +some windows will display in their true colors, and others +will display with incorrect colors. +A window manager usually controls which windows are displayed +in their true colors if more than one colormap is required for +the color resources the applications are using. +At any time, there is a set of installed colormaps for a screen. +Windows using one of the installed colormaps display with true colors, and +windows using other colormaps generally display with incorrect colors. +You can control the set of installed colormaps by using +.PN XInstallColormap +and +.PN XUninstallColormap . +.LP +Colormaps are local to a particular screen. +Screens always have a default colormap, +and programs typically allocate cells out of this colormap. +Generally, you should not write applications that monopolize +color resources. +Although some hardware supports multiple colormaps installed at one time, +many of the hardware displays +built today support only a single installed colormap, so the primitives +are written to encourage sharing of colormap entries between applications. +.LP +The +.PN DefaultColormap +macro returns the default colormap. +The +.PN DefaultVisual +macro +returns the default visual type for the specified screen. +.IN "Color map" +Possible visual types are +.PN StaticGray , +.PN GrayScale , +.PN StaticColor , +.PN PseudoColor , +.PN TrueColor , +or +.PN DirectColor +(see section 3.1). +.NH 2 +Color Structures +.XS +\*(SN Color Structures +.XE +.LP +Functions that operate only on RGB color space values use an +.PN XColor +structure, which contains: +.LP +.IN "XColor" "" "@DEF@" +.sM +.Ds 0 +.TA .5i 2.5i +.ta .5i 2.5i +typedef struct { + unsigned long pixel; /* pixel value */ + unsigned short red, green, blue; /* rgb values */ + char flags; /* DoRed, DoGreen, DoBlue */ + char pad; +} XColor; +.De +.LP +.eM +The red, green, and blue values are always in the range 0 to 65535 +inclusive, independent of the number of bits actually used in the +display hardware. +The server scales these values down to the range used by the hardware. +Black is represented by (0,0,0), +and white is represented by (65535,65535,65535). +.IN "Color" +In some functions, +the flags member controls which of the red, green, and blue members is used +and can be the inclusive OR of zero or more of +.PN DoRed , +.PN DoGreen , +and +.PN DoBlue . +.LP +.sp +Functions that operate on all color space values use an +.PN XcmsColor +structure. +This structure contains a union of substructures, +each supporting color specification encoding for a particular color space. +Like the +.PN XColor +structure, the +.PN XcmsColor +structure contains pixel +and color specification information (the spec member in the +.PN XcmsColor +structure). +.IN "XcmsColor" "" "@DEF@" +.sM +.LP +.Ds 0 +.TA .5i 1i 2.5i +.ta .5i 1i 2.5i +typedef unsigned long XcmsColorFormat; /* Color Specification Format */ + +typedef struct { + union { + XcmsRGB RGB; + XcmsRGBi RGBi; + XcmsCIEXYZ CIEXYZ; + XcmsCIEuvY CIEuvY; + XcmsCIExyY CIExyY; + XcmsCIELab CIELab; + XcmsCIELuv CIELuv; + XcmsTekHVC TekHVC; + XcmsPad Pad; + } spec; + unsigned long pixel; + XcmsColorFormat format; +} XcmsColor; /* Xcms Color Structure */ +.De +.LP +.eM +Because the color specification can be encoded for the various color spaces, +encoding for the spec member is identified by the format member, +which is of type +.PN XcmsColorFormat . +The following macros define standard formats. +.sM +.TS +lw(.5i) lw(1.6i) lw(1.4i) lw(1.5i). +T{ +#define +T} T{ +.PN XcmsUndefinedFormat +T} T{ +0x00000000 +T} +T{ +#define +T} T{ +.PN XcmsCIEXYZFormat +T} T{ +0x00000001 +T} T{ +/* CIE XYZ */ +T} +T{ +#define +T} T{ +.PN XcmsCIEuvYFormat +T} T{ +0x00000002 +T} T{ +/* CIE u'v'Y */ +T} +T{ +#define +T} T{ +.PN XcmsCIExyYFormat +T} T{ +0x00000003 +T} T{ +/* CIE xyY */ +T} +T{ +#define +T} T{ +.PN XcmsCIELabFormat +T} T{ +0x00000004 +T} T{ +/* CIE L*a*b* */ +T} +T{ +#define +T} T{ +.PN XcmsCIELuvFormat +T} T{ +0x00000005 +T} T{ +/* CIE L*u*v* */ +T} +T{ +#define +T} T{ +.PN XcmsTekHVCFormat +T} T{ +0x00000006 +T} T{ +/* TekHVC */ +T} +T{ +#define +T} T{ +.PN XcmsRGBFormat +T} T{ +0x80000000 +T} T{ +/* RGB Device */ +T} +T{ +#define +T} T{ +.PN XcmsRGBiFormat +T} T{ +0x80000001 +T} T{ +/* RGB Intensity */ +T} +.TE +.LP +.eM +Formats for device-independent color spaces are +distinguishable from those for device-dependent spaces by the 32nd bit. +If this bit is set, +it indicates that the color specification is in a device-dependent form; +otherwise, it is in a device-independent form. +If the 31st bit is set, +this indicates that the color space has been added to Xlib at run time +(see section 6.12.4). +The format value for a color space added at run time may be different each +time the program is executed. +If references to such a color space must be made outside the client +(for example, storing a color specification in a file), +then reference should be made by color space string prefix +(see +.PN XcmsFormatOfPrefix +and +.PN XcmsPrefixOfFormat ). +.LP +Data types that describe the color specification encoding for the various +color spaces are defined as follows: +.sM +.IN "XcmsRGB" "" "@DEF@" +.LP +.Ds 0 +.TA .5i 2.5i +.ta .5i 2.5i +typedef double XcmsFloat; + +typedef struct { + unsigned short red; /* 0x0000 to 0xffff */ + unsigned short green; /* 0x0000 to 0xffff */ + unsigned short blue; /* 0x0000 to 0xffff */ +} XcmsRGB; /* RGB Device */ +.De +.IN "XcmsRGBi" "" "@DEF@" +.LP +.Ds 0 +.TA .5i 2.5i +.ta .5i 2.5i +typedef struct { + XcmsFloat red; /* 0.0 to 1.0 */ + XcmsFloat green; /* 0.0 to 1.0 */ + XcmsFloat blue; /* 0.0 to 1.0 */ +} XcmsRGBi; /* RGB Intensity */ +.De +.IN "XcmsCIEXYZ" "" "@DEF@" +.LP +.Ds 0 +.TA .5i 2.5i +.ta .5i 2.5i +typedef struct { + XcmsFloat X; + XcmsFloat Y; /* 0.0 to 1.0 */ + XcmsFloat Z; +} XcmsCIEXYZ; /* CIE XYZ */ +.De +.IN "XcmsCIEuvY" "" "@DEF@" +.LP +.Ds 0 +.TA .5i 2.5i +.ta .5i 2.5i +typedef struct { + XcmsFloat u_prime; /* 0.0 to ~0.6 */ + XcmsFloat v_prime; /* 0.0 to ~0.6 */ + XcmsFloat Y; /* 0.0 to 1.0 */ +} XcmsCIEuvY; /* CIE u'v'Y */ +.De +.IN "XcmsCIExyY" "" "@DEF@" +.LP +.Ds 0 +.TA .5i 2.5i +.ta .5i 2.5i +typedef struct { + XcmsFloat x; /* 0.0 to ~.75 */ + XcmsFloat y; /* 0.0 to ~.85 */ + XcmsFloat Y; /* 0.0 to 1.0 */ +} XcmsCIExyY; /* CIE xyY */ +.De +.IN "XcmsCIELab" "" "@DEF@" +.LP +.Ds 0 +.TA .5i 2.5i +.ta .5i 2.5i +typedef struct { + XcmsFloat L_star; /* 0.0 to 100.0 */ + XcmsFloat a_star; + XcmsFloat b_star; +} XcmsCIELab; /* CIE L*a*b* */ +.De +.IN "XcmsCIELuv" "" "@DEF@" +.LP +.Ds 0 +.TA .5i 2.5i +.ta .5i 2.5i +typedef struct { + XcmsFloat L_star; /* 0.0 to 100.0 */ + XcmsFloat u_star; + XcmsFloat v_star; +} XcmsCIELuv; /* CIE L*u*v* */ +.De +.IN "XcmsTekHVC" "" "@DEF@" +.LP +.Ds 0 +.TA .5i 2.5i +.ta .5i 2.5i +typedef struct { + XcmsFloat H; /* 0.0 to 360.0 */ + XcmsFloat V; /* 0.0 to 100.0 */ + XcmsFloat C; /* 0.0 to 100.0 */ +} XcmsTekHVC; /* TekHVC */ +.De +.IN "XcmsPad" "" "@DEF@" +.LP +.Ds 0 +.TA .5i 2.5i +.ta .5i 2.5i +typedef struct { + XcmsFloat pad0; + XcmsFloat pad1; + XcmsFloat pad2; + XcmsFloat pad3; +} XcmsPad; /* four doubles */ +.De +.LP +.eM +The device-dependent formats provided allow color specification in: +.IP \(bu 5 +RGB Intensity +.Pn ( XcmsRGBi ) +.IP +Red, green, and blue linear intensity values, +floating-point values from 0.0 to 1.0, +where 1.0 indicates full intensity, 0.5 half intensity, and so on. +.IP \(bu 5 +RGB Device +.Pn ( XcmsRGB ) +.IP +Red, green, and blue values appropriate for the specified output device. +.PN XcmsRGB +values are of type unsigned short, +scaled from 0 to 65535 inclusive, +and are interchangeable with the red, green, and blue values in an +.PN XColor +structure. +.LP +It is important to note that RGB Intensity values are not gamma corrected +values. +In contrast, +RGB Device values generated as a result of converting color specifications +are always gamma corrected, and +RGB Device values acquired as a result of querying a colormap +or passed in by the client are assumed by Xlib to be gamma corrected. +The term \fIRGB value\fP in this manual always refers to an RGB Device value. +.NH 2 +Color Strings +.XS +\*(SN Color Strings +.XE +.LP +Xlib provides a mechanism for using string names for colors. +A color string may either contain an abstract color name +or a numerical color specification. +Color strings are case-insensitive. +.LP +Color strings are used in the following functions: +.IP \(bu 5 +.PN XAllocNamedColor +.IP \(bu 5 +.PN XcmsAllocNamedColor +.IP \(bu 5 +.PN XLookupColor +.IP \(bu 5 +.PN XcmsLookupColor +.IP \(bu 5 +.PN XParseColor +.IP \(bu 5 +.PN XStoreNamedColor +.LP +Xlib supports the use of abstract color names, for example, red or blue. +A value for this abstract name is obtained by searching one or more color +name databases. +Xlib first searches zero or more client-side databases; +the number, location, and content of these databases is +implementation-dependent and might depend on the current locale. +If the name is not found, Xlib then looks for the color in the +X server's database. +If the color name is not in the Host Portable Character Encoding, +the result is implementation-dependent. +.LP +A numerical color specification +consists of a color space name and a set of values in the following syntax: +.LP +.sM +.Ds 0 +\fI\fP:\fI/.../\fP +.De +.LP +.eM +The following are examples of valid color strings. +.LP +.Ds 0 +"CIEXYZ:0.3227/0.28133/0.2493" +"RGBi:1.0/0.0/0.0" +"rgb:00/ff/00" +"CIELuv:50.0/0.0/0.0" +.De +The syntax and semantics of numerical specifications are given +for each standard color space in the following sections. +.NH 3 +RGB Device String Specification +.XS +\*(SN RGB Device String Specification +.XE +.LP +An RGB Device specification is identified by +the prefix ``rgb:'' and conforms to the following syntax: +.LP +.\" Start marker code here +.Ds 0 +rgb:\fI//\fP + + \fI\fP, \fI\fP, \fI\fP := \fIh\fP | \fIhh\fP | \fIhhh\fP | \fIhhhh\fP + \fIh\fP := single hexadecimal digits (case insignificant) +.De +.\" End marker code here +.LP +Note that \fIh\fP indicates the value scaled in 4 bits, +\fIhh\fP the value scaled in 8 bits, +\fIhhh\fP the value scaled in 12 bits, +and \fIhhhh\fP the value scaled in 16 bits, respectively. +.LP +Typical examples are the strings ``rgb:ea/75/52'' and ``rgb:ccc/320/320'', +but mixed numbers of hexadecimal digit strings +(``rgb:ff/a5/0'' and ``rgb:ccc/32/0'') +are also allowed. +.LP +For backward compatibility, an older syntax for RGB Device is +supported, but its continued use is not encouraged. +The syntax is an initial sharp sign character followed by +a numeric specification, in one of the following formats: +.LP +.\" Start marker code here +.Ds 0 +.TA 2i +.ta 2i +#RGB (4 bits each) +#RRGGBB (8 bits each) +#RRRGGGBBB (12 bits each) +#RRRRGGGGBBBB (16 bits each) +.De +.\" End marker code here +.LP +The R, G, and B represent single hexadecimal digits. +When fewer than 16 bits each are specified, +they represent the most significant bits of the value +(unlike the ``rgb:'' syntax, in which values are scaled). +For example, the string ``#3a7'' is the same as ``#3000a0007000''. +.NH 3 +RGB Intensity String Specification +.XS +\*(SN RGB Intensity String Specification +.XE +.LP +An RGB intensity specification is identified +by the prefix ``rgbi:'' and conforms to the following syntax: +.LP +.\" Start marker code here +.Ds 0 +rgbi:\fI//\fP +.De +.\" End marker code here +.LP +Note that red, green, and blue are floating-point values +between 0.0 and 1.0, inclusive. +The input format for these values is an optional sign, +a string of numbers possibly containing a decimal point, +and an optional exponent field containing an E or e +followed by a possibly signed integer string. +.NH 3 +Device-Independent String Specifications +.XS +\*(SN Device-Independent String Specifications +.XE +.LP +The standard device-independent string specifications have +the following syntax: +.LP +.\" Start marker code here +.Ds 0 +CIEXYZ:\fI//\fP +CIEuvY:\fI//\fP +CIExyY:\fI//\fP +CIELab:\fI//\fP +CIELuv:\fI//\fP +TekHVC:\fI//\fP +.De +.\" End marker code here +.LP +All of the values (C, H, V, X, Y, Z, a, b, u, v, y, x) are +floating-point values. +The syntax for these values is an optional plus or minus sign, +a string of digits possibly containing a decimal point, +and an optional exponent field consisting of an ``E'' or ``e'' +followed by an optional plus or minus followed by a string of digits. +.NH 2 +Color Conversion Contexts and Gamut Mapping +.XS +\*(SN Color Conversion Contexts and Gamut Mapping +.XE +.LP +When Xlib converts device-independent color specifications +into device-dependent specifications and vice versa, +it uses knowledge about the color limitations of the screen hardware. +This information, typically called the device profile, +.IN "Device profile" +is available in a Color Conversion Context (CCC). +.IN "Color Conversion Context" +.IN "CCC" +.LP +Because a specified color may be outside the color gamut of the target screen +and the white point associated with the color specification may differ +from the white point inherent to the screen, +Xlib applies gamut mapping when it encounters certain conditions: +.IN "White point" +.IP \(bu 5 +Gamut compression occurs when conversion of device-independent +color specifications to device-dependent color specifications +results in a color out of the target screen's gamut. +.IP \(bu 5 +White adjustment occurs when the inherent white point of the screen +differs from the white point assumed by the client. +.LP +Gamut handling methods are stored as callbacks in the CCC, +which in turn are used by the color space conversion routines. +Client data is also stored in the CCC for each callback. +The CCC also contains the white point the client assumes to be +associated with color specifications (that is, the Client White Point). +.IN "Client White Point" +.IN "Gamut compression" +.IN "Gamut handling" +.IN "White point adjustment" +The client can specify the gamut handling callbacks and client data +as well as the Client White Point. +Xlib does not preclude the X client from performing other +forms of gamut handling (for example, gamut expansion); +however, Xlib does not provide direct support for gamut handling +other than white adjustment and gamut compression. +.LP +Associated with each colormap is an initial CCC transparently generated by +Xlib. +.IN "Color Conversion Context" "creation" +Therefore, +when you specify a colormap as an argument to an Xlib function, +you are indirectly specifying a CCC. +.IN "CCC" "of colormap" +.IN "Color Conversion Context" "of colormap" +There is a default CCC associated with each screen. +Newly created CCCs inherit attributes from the default CCC, +so the default CCC attributes can be modified to affect new CCCs. +.IN "CCC" "default" +.IN "Color Conversion Context" "default" +.LP +Xcms functions in which gamut mapping can occur return +.PN Status +and have specific status values defined for them, +as follows: +.IP \(bu 5 +.PN XcmsFailure +indicates that the function failed. +.IP \(bu 5 +.PN XcmsSuccess +indicates that the function succeeded. +In addition, +if the function performed any color conversion, +the colors did not need to be compressed. +.IP \(bu 5 +.PN XcmsSuccessWithCompression +indicates the function performed color conversion +and at least one of the colors needed to be compressed. +The gamut compression method is determined by the gamut compression +procedure in the CCC that is specified directly as a function argument +or in the CCC indirectly specified by means of the colormap argument. +.NH 2 +Creating, Copying, and Destroying Colormaps +.XS +\*(SN Creating, Copying, and Destroying Colormaps +.XE +.LP +To create a colormap for a screen, use +.PN XCreateColormap . +.IN "XCreateColormap" "" "@DEF@" +.sM +.FD 0 +Colormap XCreateColormap\^(\^\fIdisplay\fP, \fIw\fP\^, \fIvisual\fP\^, \fIalloc\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + Visual *\fIvisual\fP\^; +.br + int \fIalloc\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.ds Wi on whose screen you want to create a colormap +.IP \fIw\fP 1i +Specifies the window \*(Wi. +.IP \fIvisual\fP 1i +Specifies a visual type supported on the screen. +If the visual type is not one supported by the screen, +a +.PN BadMatch +error results. +.IP \fIalloc\fP 1i +Specifies the colormap entries to be allocated. +You can pass +.PN AllocNone +or +.PN AllocAll . +.LP +.eM +The +.PN XCreateColormap +function creates a colormap of the specified visual type for the screen +on which the specified window resides and returns the colormap ID +associated with it. +Note that the specified window is only used to determine the screen. +.LP +The initial values of the colormap entries are undefined for the +visual classes +.PN GrayScale , +.PN PseudoColor , +and +.PN DirectColor . +For +.PN StaticGray , +.PN StaticColor , +and +.PN TrueColor , +the entries have defined values, +but those values are specific to the visual and are not defined by X. +For +.PN StaticGray , +.PN StaticColor , +and +.PN TrueColor , +alloc must be +.PN AllocNone , +or a +.PN BadMatch +error results. +For the other visual classes, +if alloc is +.PN AllocNone , +the colormap initially has no allocated entries, +and clients can allocate them. +For information about the visual types, +see section 3.1. +.LP +If alloc is +.PN AllocAll , +the entire colormap is allocated writable. +The initial values of all allocated entries are undefined. +For +.PN GrayScale +and +.PN PseudoColor , +the effect is as if an +.PN XAllocColorCells +call returned all pixel values from zero to N \- 1, +where N is the colormap entries value in the specified visual. +For +.PN DirectColor , +the effect is as if an +.PN XAllocColorPlanes +call returned a pixel value of zero and red_mask, green_mask, +and blue_mask values containing the same bits as the corresponding +masks in the specified visual. +However, in all cases, +none of these entries can be freed by using +.PN XFreeColors . +.LP +.PN XCreateColormap +can generate +.PN BadAlloc , +.PN BadMatch , +.PN BadValue , +and +.PN BadWindow +errors. +.LP +.sp +To create a new colormap when the allocation out of a previously +shared colormap has failed because of resource exhaustion, use +.PN XCopyColormapAndFree . +.IN "XCopyColormapAndFree" "" "@DEF@" +.sM +.FD 0 +Colormap XCopyColormapAndFree\^(\^\fIdisplay\fP, \fIcolormap\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Colormap \fIcolormap\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIcolormap\fP 1i +Specifies the colormap. +.LP +.eM +The +.PN XCopyColormapAndFree +function creates a colormap of the same visual type and for the same screen +as the specified colormap and returns the new colormap ID. +It also moves all of the client's existing allocation from the specified +colormap to the new colormap with their color values intact +and their read-only or writable characteristics intact and frees those entries +in the specified colormap. +Color values in other entries in the new colormap are undefined. +If the specified colormap was created by the client with alloc set to +.PN AllocAll , +the new colormap is also created with +.PN AllocAll , +all color values for all entries are copied from the specified colormap, +and then all entries in the specified colormap are freed. +If the specified colormap was not created by the client with +.PN AllocAll , +the allocations to be moved are all those pixels and planes +that have been allocated by the client using +.PN XAllocColor , +.PN XAllocNamedColor , +.PN XAllocColorCells , +or +.PN XAllocColorPlanes +and that have not been freed since they were allocated. +.LP +.PN XCopyColormapAndFree +can generate +.PN BadAlloc +and +.PN BadColor +errors. +.LP +.sp +To destroy a colormap, use +.PN XFreeColormap . +.IN "XFreeColormap" "" "@DEF@" +.sM +.FD 0 +XFreeColormap\^(\^\fIdisplay\fP, \fIcolormap\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Colormap \fIcolormap\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.ds Cm that you want to destroy +.IP \fIcolormap\fP 1i +Specifies the colormap \*(Cm. +.LP +.eM +The +.PN XFreeColormap +function deletes the association between the colormap resource ID +and the colormap and frees the colormap storage. +However, this function has no effect on the default colormap for a screen. +If the specified colormap is an installed map for a screen, +it is uninstalled (see +.PN XUninstallColormap ). +If the specified colormap is defined as the colormap for a window (by +.PN XCreateWindow , +.PN XSetWindowColormap , +or +.PN XChangeWindowAttributes ), +.PN XFreeColormap +changes the colormap associated with the window to +.PN None +and generates a +.PN ColormapNotify +event. +X does not define the colors displayed for a window with a colormap of +.PN None . +.LP +.PN XFreeColormap +can generate a +.PN BadColor +error. +.NH 2 +Mapping Color Names to Values +.XS +\*(SN Mapping Color Names to Values +.XE +.LP +.sp +To map a color name to an RGB value, use +.PN XLookupColor . +.IN "Color" "naming" +.IN "XLookupColor" "" "@DEF@" +.sM +.FD 0 +Status XLookupColor\^(\^\fIdisplay\fP, \fIcolormap\fP, \fIcolor_name\fP, \ +\fIexact_def_return\fP\^, \fIscreen_def_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Colormap \fIcolormap\fP\^; +.br + char *\fIcolor_name\fP\^; +.br + XColor *\fIexact_def_return\fP\^, *\fIscreen_def_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIcolormap\fP 1i +Specifies the colormap. +.IP \fIcolor_name\fP 1i +Specifies the color name string (for example, red) whose color +definition structure you want returned. +.IP \fIexact_def_return\fP 1i +Returns the exact RGB values. +.IP \fIscreen_def_return\fP 1i +Returns the closest RGB values provided by the hardware. +.LP +.eM +The +.PN XLookupColor +function looks up the string name of a color with respect to the screen +associated with the specified colormap. +It returns both the exact color values and +the closest values provided by the screen +with respect to the visual type of the specified colormap. +If the color name is not in the Host Portable Character Encoding, +the result is implementation-dependent. +Use of uppercase or lowercase does not matter. +.PN XLookupColor +returns nonzero if the name is resolved; +otherwise, it returns zero. +.LP +.PN XLookupColor +can generate a +.PN BadColor +error. +.LP +.sp +To map a color name to the exact RGB value, use +.PN XParseColor . +.IN "Color" "naming" +.IN "XParseColor" "" "@DEF@" +.sM +.FD 0 +Status XParseColor\^(\^\fIdisplay\fP, \fIcolormap\fP\^, \^\fIspec\fP\^, \fIexact_def_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Colormap \fIcolormap\fP\^; +.br + char *\fIspec\fP\^; +.br + XColor *\fIexact_def_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIcolormap\fP 1i +Specifies the colormap. +.IP \fIspec\fP 1i +Specifies the color name string; +case is ignored. +.IP \fIexact_def_return\fP 1i +Returns the exact color value for later use and sets the +.PN DoRed , +.PN DoGreen , +and +.PN DoBlue +flags. +.LP +.eM +The +.PN XParseColor +function looks up the string name of a color with respect to the screen +associated with the specified colormap. +It returns the exact color value. +If the color name is not in the Host Portable Character Encoding, +the result is implementation-dependent. +Use of uppercase or lowercase does not matter. +.PN XParseColor +returns nonzero if the name is resolved; +otherwise, it returns zero. +.LP +.PN XParseColor +can generate a +.PN BadColor +error. +.LP +.sp +To map a color name to a value in an arbitrary color space, use +.PN XcmsLookupColor . +.IN "Color" "naming" +.IN "XcmsLookupColor" "" "@DEF@" +.sM +.FD 0 +Status XcmsLookupColor\^(\^\fIdisplay\fP, \fIcolormap\fP\^, \fIcolor_string\fP\^, \fIcolor_exact_return\fP\^, \fIcolor_screen_return\fP\^, +.br + \fIresult_format\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Colormap \fIcolormap\fP\^; +.br + char *\fIcolor_string\fP\^; +.br + XcmsColor *\fIcolor_exact_return\fP\^, *\fIcolor_screen_return\fP\^; +.br + XcmsColorFormat \fIresult_format\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIcolormap\fP 1i +Specifies the colormap. +.ds St +.IP \fIcolor_string\fP 1i +Specifies the color string\*(St. +.IP \fIcolor_exact_return\fP 1i +Returns the color specification parsed from the color string +or parsed from the corresponding string found in a color-name database. +.IP \fIcolor_screen_return\fP 1i +Returns the color that can be reproduced on the screen. +.IP \fIresult_format\fP 1i +Specifies the color format for the returned color +specifications (color_screen_return and color_exact_return arguments). +If the format is +.PN XcmsUndefinedFormat +and the color string contains a +numerical color specification, +the specification is returned in the format used in that numerical +color specification. +If the format is +.PN XcmsUndefinedFormat +and the color string contains a color name, +the specification is returned in the format used +to store the color in the database. +.LP +.eM +The +.PN XcmsLookupColor +function looks up the string name of a color with respect to the screen +associated with the specified colormap. +It returns both the exact color values and +the closest values provided by the screen +with respect to the visual type of the specified colormap. +The values are returned in the format specified by result_format. +If the color name is not in the Host Portable Character Encoding, +the result is implementation-dependent. +Use of uppercase or lowercase does not matter. +.PN XcmsLookupColor +returns +.PN XcmsSuccess +or +.PN XcmsSuccessWithCompression +if the name is resolved; otherwise, it returns +.PN XcmsFailure . +If +.PN XcmsSuccessWithCompression +is returned, the color specification returned in +color_screen_return is the result of gamut compression. +.NH 2 +Allocating and Freeing Color Cells +.XS +\*(SN Allocating and Freeing Color Cells +.XE +.LP +There are two ways of allocating color cells: +explicitly as read-only entries, one pixel value at a time, +or read/write, +where you can allocate a number of color cells and planes simultaneously. +.IN "Read-only colormap cells" +A read-only cell has its RGB value set by the server. +.IN "Read/write colormap cells" +Read/write cells do not have defined colors initially; +functions described in the next section must be used to store values into them. +Although it is possible for any client to store values into a read/write +cell allocated by another client, +read/write cells normally should be considered private to the client +that allocated them. +.LP +Read-only colormap cells are shared among clients. +The server counts each allocation and freeing of the cell by clients. +When the last client frees a shared cell, the cell is finally deallocated. +If a single client allocates the same read-only cell multiple +times, the server counts each such allocation, not just the first one. +.LP +.sp +To allocate a read-only color cell with an RGB value, use +.PN XAllocColor . +.IN "Allocation" "read-only colormap cells" +.IN "Read-only colormap cells" "allocating" +.IN "Color" "allocation" +.IN "XAllocColor" "" "@DEF@" +.sM +.FD 0 +Status XAllocColor\^(\^\fIdisplay\fP, \fIcolormap\fP\^, \fIscreen_in_out\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Colormap \fIcolormap\fP\^; +.br + XColor *\fIscreen_in_out\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIcolormap\fP 1i +Specifies the colormap. +.IP \fIscreen_in_out\fP 1i +Specifies and returns the values actually used in the colormap. +.LP +.eM +The +.PN XAllocColor +function allocates a read-only colormap entry corresponding to the closest +RGB value supported by the hardware. +.PN XAllocColor +returns the pixel value of the color closest to the specified +RGB elements supported by the hardware +and returns the RGB value actually used. +The corresponding colormap cell is read-only. +In addition, +.PN XAllocColor +returns nonzero if it succeeded or zero if it failed. +.IN "Color map" +.IN "Color" "allocation" +.IN "Allocation" "colormap" +.IN "read-only colormap cells" +Multiple clients that request the same effective RGB value can be assigned +the same read-only entry, thus allowing entries to be shared. +When the last client deallocates a shared cell, it is deallocated. +.PN XAllocColor +does not use or affect the flags in the +.PN XColor +structure. +.LP +.PN XAllocColor +can generate a +.PN BadColor +error. +.EQ +delim %% +.EN +.LP +.sp +To allocate a read-only color cell with a color in arbitrary format, use +.PN XcmsAllocColor . +.IN "Allocation" "read-only colormap cells" +.IN "Read-only colormap cells" "allocating" +.IN "Color" "allocation" +.IN "XcmsAllocColor" "" "@DEF@" +.sM +.FD 0 +Status XcmsAllocColor\^(\^\fIdisplay\fP\^, \fIcolormap\fP\^, \fIcolor_in_out\fP\^, \fIresult_format\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Colormap \fIcolormap\fP\^; +.br + XcmsColor *\fIcolor_in_out\fP\^; +.br + XcmsColorFormat \fIresult_format\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIcolormap\fP 1i +Specifies the colormap. +.IP \fIcolor_in_out\fP 1i +Specifies the color to allocate and returns the pixel and color +that is actually used in the colormap. +.IP \fIresult_format\fP 1i +Specifies the color format for the returned color specification. +.LP +.eM +The +.PN XcmsAllocColor +function is similar to +.PN XAllocColor +except the color can be specified in any format. +The +.PN XcmsAllocColor +function ultimately calls +.PN XAllocColor +to allocate a read-only color cell (colormap entry) with the specified color. +.PN XcmsAllocColor +first converts the color specified +to an RGB value and then passes this to +.PN XAllocColor . +.PN XcmsAllocColor +returns the pixel value of the color cell and the color specification +actually allocated. +This returned color specification is the result of converting the RGB value +returned by +.PN XAllocColor +into the format specified with the result_format argument. +If there is no interest in a returned color specification, +unnecessary computation can be bypassed if result_format is set to +.PN XcmsRGBFormat . +The corresponding colormap cell is read-only. +If this routine returns +.PN XcmsFailure , +the color_in_out color specification is left unchanged. +.LP +.PN XcmsAllocColor +can generate a +.PN BadColor +error. +.LP +.sp +To allocate a read-only color cell using a color name and return the closest +color supported by the hardware in RGB format, use +.PN XAllocNamedColor . +.IN "Allocation" "read-only colormap cells" +.IN "Read-only colormap cells" "allocating" +.IN "Color" "naming" +.IN "Color" "allocation" +.IN "XAllocNamedColor" "" "@DEF@" +.sM +.FD 0 +Status XAllocNamedColor\^(\^\fIdisplay\fP, \fIcolormap\fP\^, \ +\fIcolor_name\fP\^, \fIscreen_def_return\fP\^, \fIexact_def_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Colormap \fIcolormap\fP\^; +.br + char *\fIcolor_name\fP\^; +.br + XColor *\fIscreen_def_return\fP\^, *\fIexact_def_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIcolormap\fP 1i +Specifies the colormap. +.IP \fIcolor_name\fP 1i +Specifies the color name string (for example, red) whose color +definition structure you want returned. +.IP \fIscreen_def_return\fP 1i +Returns the closest RGB values provided by the hardware. +.IP \fIexact_def_return\fP 1i +Returns the exact RGB values. +.LP +.eM +The +.PN XAllocNamedColor +function looks up the named color with respect to the screen that is +associated with the specified colormap. +It returns both the exact database definition and +the closest color supported by the screen. +The allocated color cell is read-only. +The pixel value is returned in screen_def_return. +If the color name is not in the Host Portable Character Encoding, +the result is implementation-dependent. +Use of uppercase or lowercase does not matter. +If screen_def_return and exact_def_return +point to the same structure, the pixel field will be set correctly, +but the color values are undefined. +.PN XAllocNamedColor +returns nonzero if a cell is allocated; +otherwise, it returns zero. +.LP +.PN XAllocNamedColor +can generate a +.PN BadColor +error. +.LP +.sp +To allocate a read-only color cell using a color name and return the closest +color supported by the hardware in an arbitrary format, use +.PN XcmsAllocNamedColor . +.IN "Allocation" "read-only colormap cells" +.IN "Read-only colormap cells" "allocating" +.IN "Color" "naming" +.IN "Color" "allocation" +.IN "XcmsAllocNamedColor" "" "@DEF@" +.sM +.FD 0 +Status XcmsAllocNamedColor\^(\^\fIdisplay\fP\^, \fIcolormap\fP\^, \fIcolor_string\fP\^, \fIcolor_screen_return\fP\^, \fIcolor_exact_return\fP\^, +.br + \fIresult_format\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Colormap \fIcolormap\fP\^; +.br + char *\fIcolor_string\fP\^; +.br + XcmsColor *\fIcolor_screen_return\fP\^; +.br + XcmsColor *\fIcolor_exact_return\fP\^; +.br + XcmsColorFormat \fIresult_format\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIcolormap\fP 1i +Specifies the colormap. +.ds St \ whose color definition structure is to be returned +.IP \fIcolor_string\fP 1i +Specifies the color string\*(St. +.IP \fIcolor_screen_return\fP 1i +Returns the pixel value of the color cell and color specification +that actually is stored for that cell. +.IP \fIcolor_exact_return\fP 1i +Returns the color specification parsed from the color string +or parsed from the corresponding string found in a color-name database. +.IP \fIresult_format\fP 1i +Specifies the color format for the returned color +specifications (color_screen_return and color_exact_return arguments). +If the format is +.PN XcmsUndefinedFormat +and the color string contains a +numerical color specification, +the specification is returned in the format used in that numerical +color specification. +If the format is +.PN XcmsUndefinedFormat +and the color string contains a color name, +the specification is returned in the format used +to store the color in the database. +.LP +.eM +The +.PN XcmsAllocNamedColor +function is similar to +.PN XAllocNamedColor +except that the color returned can be in any format specified. +This function +ultimately calls +.PN XAllocColor +to allocate a read-only color cell with +the color specified by a color string. +The color string is parsed into an +.PN XcmsColor +structure (see +.PN XcmsLookupColor ), +converted +to an RGB value, and finally passed to +.PN XAllocColor . +If the color name is not in the Host Portable Character Encoding, +the result is implementation-dependent. +Use of uppercase or lowercase does not matter. +.LP +This function returns both the color specification as a result +of parsing (exact specification) and the actual color specification +stored (screen specification). +This screen specification is the result of converting the RGB value +returned by +.PN XAllocColor +into the format specified in result_format. +If there is no interest in a returned color specification, +unnecessary computation can be bypassed if result_format is set to +.PN XcmsRGBFormat . +If color_screen_return and color_exact_return +point to the same structure, the pixel field will be set correctly, +but the color values are undefined. +.LP +.PN XcmsAllocNamedColor +can generate a +.PN BadColor +error. +.LP +.sp +To allocate read/write color cell and color plane combinations for a +.PN PseudoColor +model, use +.PN XAllocColorCells . +.IN "Read/write colormap cells" "allocating" +.IN "Allocation" "read/write colormap cells" +.IN "Color" "allocation" +.IN "XAllocColorCells" "" "@DEF@" +.sM +.FD 0 +Status XAllocColorCells\^(\^\fIdisplay\fP, \fIcolormap\fP\^, \fIcontig\fP\^, \ +\fIplane_masks_return\fP\^, \fInplanes\fP\^, +.br + \fIpixels_return\fP\^, \fInpixels\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Colormap \fIcolormap\fP\^; +.br + Bool \fIcontig\fP\^; +.br + unsigned long \fIplane_masks_return\fP[\^]\^; +.br + unsigned int \fInplanes\fP\^; +.br + unsigned long \fIpixels_return\fP[\^]\^; +.br + unsigned int \fInpixels\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIcolormap\fP 1i +Specifies the colormap. +.IP \fIcontig\fP 1i +Specifies a Boolean value that indicates whether the planes must be contiguous. +.IP \fIplane_mask_return\fP 1i +Returns an array of plane masks. +.\" *** JIM: NEED MORE INFO FOR THIS. *** +.IP \fInplanes\fP 1i +Specifies the number of plane masks that are to be returned in the plane masks +array. +.IP \fIpixels_return\fP 1i +Returns an array of pixel values. +.IP \fInpixels\fP 1i +Specifies the number of pixel values that are to be returned in the +pixels_return array. +.LP +.eM +.EQ +delim %% +.EN +The +.PN XAllocColorCells +function allocates read/write color cells. +The number of colors must be positive and the number of planes nonnegative, +or a +.PN BadValue +error results. +If ncolors and nplanes are requested, +then ncolors pixels +and nplane plane masks are returned. +No mask will have any bits set to 1 in common with +any other mask or with any of the pixels. +By ORing together each pixel with zero or more masks, +ncolors * %2 sup nplanes% distinct pixels can be produced. +All of these are +allocated writable by the request. +For +.PN GrayScale +or +.PN PseudoColor , +each mask has exactly one bit set to 1. +For +.PN DirectColor , +each has exactly three bits set to 1. +If contig is +.PN True +and if all masks are ORed +together, a single contiguous set of bits set to 1 will be formed for +.PN GrayScale +or +.PN PseudoColor +and three contiguous sets of bits set to 1 (one within each +pixel subfield) for +.PN DirectColor . +The RGB values of the allocated +entries are undefined. +.PN XAllocColorCells +returns nonzero if it succeeded or zero if it failed. +.LP +.PN XAllocColorCells +can generate +.PN BadColor +and +.PN BadValue +errors. +.LP +.sp +To allocate read/write color resources for a +.PN DirectColor +model, use +.PN XAllocColorPlanes . +.IN "Read/write colormap planes" "allocating" +.IN "Allocation" "read/write colormap planes" +.IN "Color" "allocation" +.IN "XAllocColorPlanes" "" "@DEF@" +.sM +.FD 0 +Status XAllocColorPlanes\^(\^\fIdisplay\fP, \fIcolormap\fP\^, \fIcontig\fP\^, \fIpixels_return\fP\^, \fIncolors\fP\^, \fInreds\fP\^, \fIngreens\fP\^, +.br + \fInblues\fP\^, \fIrmask_return\fP\^, \fIgmask_return\fP\^, \fIbmask_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Colormap \fIcolormap\fP\^; +.br + Bool \fIcontig\fP\^; +.br + unsigned long \fIpixels_return\fP[\^]\^; +.br + int \fIncolors\fP\^; +.br + int \fInreds\fP\^, \fIngreens\fP\^, \fInblues\fP\^; +.br + unsigned long *\fIrmask_return\fP\^, *\fIgmask_return\fP\^, *\fIbmask_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIcolormap\fP 1i +Specifies the colormap. +.IP \fIcontig\fP 1i +Specifies a Boolean value that indicates whether the planes must be contiguous. +.IP \fIpixels_return\fP 1i +Returns an array of pixel values. +.PN XAllocColorPlanes +returns the pixel values in this array. +.IP \fIncolors\fP 1i +Specifies the number of pixel values that are to be returned in the +pixels_return array. +.IP \fInreds\fP 1i +.br +.ns +.IP \fIngreens\fP 1i +.br +.ns +.IP \fInblues\fP 1i +.br +.ns +Specify the number of red, green, and blue planes. +The value you pass must be nonnegative. +.IP \fIrmask_return\fP 1i +.br +.ns +.IP \fIgmask_return\fP 1i +.br +.ns +.IP \fIbmask_return\fP 1i +Return bit masks for the red, green, and blue planes. +.LP +.eM +.EQ +delim %% +.EN +The specified ncolors must be positive; +and nreds, ngreens, and nblues must be nonnegative, +or a +.PN BadValue +error results. +If ncolors colors, nreds reds, ngreens greens, and nblues blues are requested, +ncolors pixels are returned; and the masks have nreds, ngreens, and +nblues bits set to 1, respectively. +If contig is +.PN True , +each mask will have +a contiguous set of bits set to 1. +No mask will have any bits set to 1 in common with +any other mask or with any of the pixels. +For +.PN DirectColor , +each mask +will lie within the corresponding pixel subfield. +By ORing together +subsets of masks with each pixel value, +ncolors * %2 sup (nreds+ngreens+nblues)% distinct pixel values can be produced. +All of these are allocated by the request. +However, in the +colormap, there are only ncolors * %2 sup nreds% independent red entries, +ncolors * %2 sup ngreens% independent green entries, +and ncolors * %2 sup nblues% independent blue entries. +This is true even for +.PN PseudoColor . +When the colormap entry of a pixel +value is changed (using +.PN XStoreColors , +.PN XStoreColor , +or +.PN XStoreNamedColor ), +the pixel is decomposed according to the masks, +and the corresponding independent entries are updated. +.PN XAllocColorPlanes +returns nonzero if it succeeded or zero if it failed. +.LP +.PN XAllocColorPlanes +can generate +.PN BadColor +and +.PN BadValue +errors. +.LP +.sp +.IN "Freeing" "colors" +To free colormap cells, use +.PN XFreeColors . +.IN "XFreeColors" "" "@DEF@" +.IN "Color" "deallocation" +.sM +.FD 0 +XFreeColors\^(\^\fIdisplay\fP, \fIcolormap\fP\^, \fIpixels\fP\^, \fInpixels\fP\^, \fIplanes\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Colormap \fIcolormap\fP\^; +.br + unsigned long \fIpixels\fP\^[\^]; +.br + int \fInpixels\fP\^; +.br + unsigned long \fIplanes\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIcolormap\fP 1i +Specifies the colormap. +.ds Pi that map to the cells in the specified colormap +.IP \fIpixels\fP 1i +Specifies an array of pixel values \*(Pi. +.IP \fInpixels\fP 1i +Specifies the number of pixels. +.IP \fIplanes\fP 1i +Specifies the planes you want to free. +.LP +.eM +The +.PN XFreeColors +function frees the cells represented by pixels whose values are in the +pixels array. +The planes argument should not have any bits set to 1 in common with any of the +pixels. +The set of all pixels is produced by ORing together subsets of +the planes argument with the pixels. +The request frees all of these pixels that +were allocated by the client (using +.IN XAllocColor +.IN XAllocNamedColor +.IN XAllocColorCells +.IN XAllocColorPlanes +.PN XAllocColor , +.PN XAllocNamedColor , +.PN XAllocColorCells , +and +.PN XAllocColorPlanes ). +Note that freeing an +individual pixel obtained from +.PN XAllocColorPlanes +may not actually allow +it to be reused until all of its related pixels are also freed. +Similarly, +a read-only entry is not actually freed until it has been freed by all clients, +and if a client allocates the same read-only entry multiple times, +it must free the entry that many times before the entry is actually freed. +.LP +All specified pixels that are allocated by the client in the colormap are +freed, even if one or more pixels produce an error. +If a specified pixel is not a valid index into the colormap, a +.PN BadValue +error results. +If a specified pixel is not allocated by the +client (that is, is unallocated or is only allocated by another client) +or if the colormap was created with all entries writable (by passing +.PN AllocAll +to +.PN XCreateColormap ), +a +.PN BadAccess +error results. +If more than one pixel is in error, +the one that gets reported is arbitrary. +.LP +.PN XFreeColors +can generate +.PN BadAccess , +.PN BadColor , +and +.PN BadValue +errors. +.NH 2 +Modifying and Querying Colormap Cells +.XS +\*(SN Modifying and Querying Colormap Cells +.XE +.LP +.sp +To store an RGB value in a single colormap cell, use +.PN XStoreColor . +.IN "Color" "storing" +.IN "XStoreColor" "" "@DEF@" +.sM +.FD 0 +XStoreColor\^(\^\fIdisplay\fP, \fIcolormap\fP\^, \fIcolor\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Colormap \fIcolormap\fP\^; +.br + XColor *\fIcolor\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIcolormap\fP 1i +Specifies the colormap. +.IP \fIcolor\fP 1i +Specifies the pixel and RGB values. +.LP +.eM +The +.PN XStoreColor +function changes the colormap entry of the pixel value specified in the +pixel member of the +.PN XColor +structure. +You specified this value in the +pixel member of the +.PN XColor +structure. +This pixel value must be a read/write cell and a valid index into the colormap. +If a specified pixel is not a valid index into the colormap, +a +.PN BadValue +error results. +.PN XStoreColor +also changes the red, green, and/or blue color components. +You specify which color components are to be changed by setting +.PN DoRed , +.PN DoGreen , +and/or +.PN DoBlue +in the flags member of the +.PN XColor +structure. +If the colormap is an installed map for its screen, +the changes are visible immediately. +.LP +.PN XStoreColor +can generate +.PN BadAccess , +.PN BadColor , +and +.PN BadValue +errors. +.LP +.sp +To store multiple RGB values in multiple colormap cells, use +.PN XStoreColors . +.IN "Color" "storing" +.IN "XStoreColors" "" "@DEF@" +.sM +.FD 0 +XStoreColors\^(\^\fIdisplay\fP, \fIcolormap\fP\^, \fIcolor\fP\^, \fIncolors\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Colormap \fIcolormap\fP\^; +.br + XColor \fIcolor\fP\^[\^]\^; +.br + int \fIncolors\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIcolormap\fP 1i +Specifies the colormap. +.IP \fIcolor\fP 1i +Specifies an array of color definition structures to be stored. +.IP \fIncolors\fP 1i +.\"Specifies the number of color definition structures. +Specifies the number of +.PN XColor +structures in the color definition array. +.LP +.eM +The +.PN XStoreColors +function changes the colormap entries of the pixel values +specified in the pixel members of the +.PN XColor +structures. +You specify which color components are to be changed by setting +.PN DoRed , +.PN DoGreen , +and/or +.PN DoBlue +in the flags member of the +.PN XColor +structures. +If the colormap is an installed map for its screen, the +changes are visible immediately. +.PN XStoreColors +changes the specified pixels if they are allocated writable in the colormap +by any client, even if one or more pixels generates an error. +If a specified pixel is not a valid index into the colormap, a +.PN BadValue +error results. +If a specified pixel either is unallocated or is allocated read-only, a +.PN BadAccess +error results. +If more than one pixel is in error, +the one that gets reported is arbitrary. +.LP +.PN XStoreColors +can generate +.PN BadAccess , +.PN BadColor , +and +.PN BadValue +errors. +.LP +.sp +To store a color of arbitrary format in a single colormap cell, use +.PN XcmsStoreColor . +.IN "Color" "storing" +.IN "XcmsStoreColor" "" "@DEF@" +.sM +.FD 0 +Status XcmsStoreColor\^(\^\fIdisplay\fP, \fIcolormap\fP\^, \fIcolor\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Colormap \fIcolormap\fP\^; +.br + XcmsColor *\fIcolor\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIcolormap\fP 1i +Specifies the colormap. +.IP \fIcolor\fP 1i +Specifies the color cell and the color to store. +Values specified in this +.PN XcmsColor +structure remain unchanged on return. +.LP +.eM +The +.PN XcmsStoreColor +function converts the color specified in the +.PN XcmsColor +structure into RGB values. +It then uses this RGB specification in an +.PN XColor +structure, whose three flags +.Pn ( DoRed , +.PN DoGreen , +and +.PN DoBlue ) +are set, in a call to +.PN XStoreColor +to change the color cell specified by the pixel member of the +.PN XcmsColor +structure. +This pixel value must be a valid index for the specified colormap, +and the color cell specified by the pixel value must be a read/write cell. +If the pixel value is not a valid index, a +.PN BadValue +error results. +If the color cell is unallocated or is allocated read-only, a +.PN BadAccess +error results. +If the colormap is an installed map for its screen, +the changes are visible immediately. +.LP +Note that +.PN XStoreColor +has no return value; therefore, an +.PN XcmsSuccess +return value from this function indicates that the conversion +to RGB succeeded and the call to +.PN XStoreColor +was made. +To obtain the actual color stored, use +.PN XcmsQueryColor . +Because of the screen's hardware limitations or gamut compression, +the color stored in the colormap may not be identical +to the color specified. +.LP +.PN XcmsStoreColor +can generate +.PN BadAccess , +.PN BadColor , +and +.PN BadValue +errors. +.LP +.sp +To store multiple colors of arbitrary format in multiple colormap cells, use +.PN XcmsStoreColors . +.IN "Color" "storing" +.IN "XcmsStoreColors" "" "@DEF@" +.sM +.FD 0 +Status XcmsStoreColors\^(\^\fIdisplay\fP, \fIcolormap\fP\^, \fIcolors\fP\^, \fIncolors\fP\^, \fIcompression_flags_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Colormap \fIcolormap\fP\^; +.br + XcmsColor \fIcolors\fP\^[\^]\^; +.br + int \fIncolors\fP\^; +.br + Bool \fIcompression_flags_return\fP\^[\^]\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIcolormap\fP 1i +Specifies the colormap. +.IP \fIcolors\fP 1i +Specifies the color specification array of +.PN XcmsColor +structures, each specifying a color cell and the color to store in that +cell. +Values specified in the array remain unchanged upon return. +.IP \fIncolors\fP 1i +Specifies the number of +.PN XcmsColor +structures in the color-specification array. +.IP \fIcompression_flags_return\fP 1i +Returns an array of Boolean values indicating compression status. +If a non-NULL pointer is supplied, +each element of the array is set to +.PN True +if the corresponding color was compressed and +.PN False +otherwise. +Pass NULL if the compression status is not useful. +.LP +.eM +The +.PN XcmsStoreColors +function converts the colors specified in the array of +.PN XcmsColor +structures into RGB values and then uses these RGB specifications in +.PN XColor +structures, whose three flags +.Pn ( DoRed , +.PN DoGreen , +and +.PN DoBlue ) +are set, in a call to +.PN XStoreColors +to change the color cells specified by the pixel member of the corresponding +.PN XcmsColor +structure. +Each pixel value must be a valid index for the specified colormap, +and the color cell specified by each pixel value must be a read/write cell. +If a pixel value is not a valid index, a +.PN BadValue +error results. +If a color cell is unallocated or is allocated read-only, a +.PN BadAccess +error results. +If more than one pixel is in error, +the one that gets reported is arbitrary. +If the colormap is an installed map for its screen, +the changes are visible immediately. +.LP +Note that +.PN XStoreColors +has no return value; therefore, an +.PN XcmsSuccess +return value from this function indicates that conversions +to RGB succeeded and the call to +.PN XStoreColors +was made. +To obtain the actual colors stored, use +.PN XcmsQueryColors . +Because of the screen's hardware limitations or gamut compression, +the colors stored in the colormap may not be identical +to the colors specified. +.LP +.PN XcmsStoreColors +can generate +.PN BadAccess , +.PN BadColor , +and +.PN BadValue +errors. +.LP +.sp +To store a color specified by name in a single colormap cell, use +.PN XStoreNamedColor . +.IN "Color" "storing" +.IN "Color" "naming" +.IN "XStoreNamedColor" "" "@DEF@" +.sM +.FD 0 +XStoreNamedColor\^(\^\fIdisplay\fP, \fIcolormap\fP\^, \fIcolor\fP\^, \fIpixel\fP\^, \fIflags\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Colormap \fIcolormap\fP\^; +.br + char *\^\fIcolor\fP\^; +.br + unsigned long \fIpixel\fP\^; +.br + int \fIflags\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIcolormap\fP 1i +Specifies the colormap. +.IP \fIcolor\fP 1i +Specifies the color name string (for example, red). +.IP \fIpixel\fP 1i +Specifies the entry in the colormap. +.IP \fIflags\fP 1i +Specifies which red, green, and blue components are set. +.LP +.eM +The +.PN XStoreNamedColor +function looks up the named color with respect to the screen associated with +the colormap and stores the result in the specified colormap. +The pixel argument determines the entry in the colormap. +The flags argument determines which of the red, green, and blue components +are set. +You can set this member to the +bitwise inclusive OR of the bits +.PN DoRed , +.PN DoGreen , +and +.PN DoBlue . +If the color name is not in the Host Portable Character Encoding, +the result is implementation-dependent. +Use of uppercase or lowercase does not matter. +If the specified pixel is not a valid index into the colormap, a +.PN BadValue +error results. +If the specified pixel either is unallocated or is allocated read-only, a +.PN BadAccess +error results. +.LP +.PN XStoreNamedColor +can generate +.PN BadAccess , +.PN BadColor , +.PN BadName , +and +.PN BadValue +errors. +.LP +The +.PN XQueryColor +and +.PN XQueryColors +functions take pixel values in the pixel member of +.PN XColor +structures and store in the structures the RGB values for those +pixels from the specified colormap. +The values returned for an unallocated entry are undefined. +These functions also set the flags member in the +.PN XColor +structure to all three colors. +If a pixel is not a valid index into the specified colormap, a +.PN BadValue +error results. +If more than one pixel is in error, +the one that gets reported is arbitrary. +.LP +.sp +To query the RGB value of a single colormap cell, use +.PN XQueryColor . +.IN "Color" "querying" +.IN "XQueryColor" "" "@DEF@" +.sM +.FD 0 +XQueryColor\^(\^\fIdisplay\fP, \fIcolormap\fP\^, \fIdef_in_out\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Colormap \fIcolormap\fP\^; +.br + XColor *\fIdef_in_out\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIcolormap\fP 1i +Specifies the colormap. +.IP \fIdef_in_out\fP 1i +Specifies and returns the RGB values for the pixel specified in the structure. +.LP +.eM +The +.PN XQueryColor +function returns the current RGB value for the pixel in the +.PN XColor +structure and sets the +.PN DoRed , +.PN DoGreen , +and +.PN DoBlue +flags. +.LP +.PN XQueryColor +can generate +.PN BadColor +and +.PN BadValue +errors. +.LP +.sp +To query the RGB values of multiple colormap cells, use +.PN XQueryColors . +.IN "Color" "querying" +.IN "XQueryColors" "" "@DEF@" +.sM +.FD 0 +XQueryColors\^(\^\fIdisplay\fP, \fIcolormap\fP\^, \fIdefs_in_out\fP\^, \fIncolors\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Colormap \fIcolormap\fP\^; +.br + XColor \fIdefs_in_out\fP[\^]\^; +.br + int \fIncolors\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIcolormap\fP 1i +Specifies the colormap. +.IP \fIdefs_in_out\fP 1i +Specifies and returns an array of color definition structures for the pixel +specified in the structure. +.IP \fIncolors\fP 1i +.\"Specifies the number of color definition structures. +Specifies the number of +.PN XColor +structures in the color definition array. +.LP +.eM +The +.PN XQueryColors +function returns the RGB value for each pixel in each +.PN XColor +structure and sets the +.PN DoRed , +.PN DoGreen , +and +.PN DoBlue +flags in each structure. + +.LP +.PN XQueryColors +can generate +.PN BadColor +and +.PN BadValue +errors. +.sp +.LP +To query the color of a single colormap cell in an arbitrary format, use +.PN XcmsQueryColor . +.IN "Color" "querying" +.IN "XcmsQueryColor" "" "@DEF@" +.sM +.FD 0 +Status XcmsQueryColor\^(\^\fIdisplay\fP, \fIcolormap\fP\^, \fIcolor_in_out\fP\^, \fIresult_format\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Colormap \fIcolormap\fP\^; +.br + XcmsColor *\fIcolor_in_out\fP\^; +.br + XcmsColorFormat \fIresult_format\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIcolormap\fP 1i +Specifies the colormap. +.IP \fIcolor_in_out\fP 1i +Specifies the pixel member that indicates the color cell to query. +The color specification stored for the color cell is returned in this +.PN XcmsColor +structure. +.IP \fIresult_format\fP 1i +Specifies the color format for the returned color specification. +.LP +.eM +The +.PN XcmsQueryColor +function obtains the RGB value +for the pixel value in the pixel member of the specified +.PN XcmsColor +structure and then +converts the value to the target format as +specified by the result_format argument. +If the pixel is not a valid index in the specified colormap, a +.PN BadValue +error results. +.LP +.PN XcmsQueryColor +can generate +.PN BadColor +and +.PN BadValue +errors. +.sp +.LP +To query the color of multiple colormap cells in an arbitrary format, use +.PN XcmsQueryColors . +.IN "Color" "querying" +.IN "XcmsQueryColors" "" "@DEF@" +.sM +.FD 0 +Status XcmsQueryColors\^(\^\fIdisplay\fP, \fIcolormap\fP\^, \fIcolors_in_out\fP\^, \fIncolors\fP\^, \fIresult_format\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Colormap \fIcolormap\fP\^; +.br + XcmsColor \fIcolors_in_out\fP\^[\^]\^; +.br + unsigned int \fIncolors\fP\^; +.br + XcmsColorFormat \fIresult_format\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIcolormap\fP 1i +Specifies the colormap. +.IP \fIcolors_in_out\fP 1i +Specifies an array of +.PN XcmsColor +structures, each pixel member indicating the color cell to query. +The color specifications for the color cells are returned in these structures. +.IP \fIncolors\fP 1i +Specifies the number of +.PN XcmsColor +structures in the color-specification array. +.IP \fIresult_format\fP 1i +Specifies the color format for the returned color specification. +.LP +.eM +The +.PN XcmsQueryColors +function obtains the RGB values +for pixel values in the pixel members of +.PN XcmsColor +structures and then +converts the values to the target format as +specified by the result_format argument. +If a pixel is not a valid index into the specified colormap, a +.PN BadValue +error results. +If more than one pixel is in error, +the one that gets reported is arbitrary. +.LP +.PN XcmsQueryColors +can generate +.PN BadColor +and +.PN BadValue +errors. +.NH 2 +Color Conversion Context Functions +.XS +\*(SN Color Conversion Context Functions +.XE +.LP +This section describes functions to create, modify, +and query Color Conversion Contexts (CCCs). +.LP +Associated with each colormap is an initial CCC transparently generated by +Xlib. +.IN "Color Conversion Context" "creation" +Therefore, when you specify a colormap as an argument to a function, +you are indirectly specifying a CCC. +.IN "CCC" "of colormap" +.IN "Color Conversion Context" "of colormap" +The CCC attributes that can be modified by the X client are: +.IP \(bu 5 +Client White Point +.IP \(bu 5 +Gamut compression procedure and client data +.IP \(bu 5 +White point adjustment procedure and client data +.LP +The initial values for these attributes are implementation specific. +The CCC attributes for subsequently created CCCs can be defined +by changing the CCC attributes of the default CCC. +.IN "CCC" "default" +.IN "Color Conversion Context" "default" +There is a default CCC associated with each screen. +.NH 3 +Getting and Setting the Color Conversion Context of a Colormap +.XS +\*(SN Getting and Setting the Color Conversion Context of a Colormap +.XE +.LP +.sp +To obtain the CCC associated with a colormap, use +.PN XcmsCCCOfColormap . +.IN "XcmsCCCOfColormap" "" "@DEF@" +.IN "Colormap" "CCC of" +.IN "CCC" "of colormap" +.IN "Color Conversion Context" "of colormap" +.sM +.FD 0 +XcmsCCC XcmsCCCOfColormap\^(\^\fIdisplay\fP, \fIcolormap\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Colormap \fIcolormap\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIcolormap\fP 1i +Specifies the colormap. +.LP +.eM +The +.PN XcmsCCCOfColormap +function returns the CCC associated with the specified colormap. +Once obtained, +the CCC attributes can be queried or modified. +Unless the CCC associated with the specified colormap is changed with +.PN XcmsSetCCCOfColormap , +this CCC is used when the specified colormap is used as an argument +to color functions. +.sp +.LP +To change the CCC associated with a colormap, use +.PN XcmsSetCCCOfColormap . +.IN "XcmsSetCCCOfColormap" "" "@DEF@" +.IN "Colormap" "CCC of" +.IN "CCC" "of colormap" +.IN "Color Conversion Context" "of colormap" +.sM +.FD 0 +XcmsCCC XcmsSetCCCOfColormap\^(\^\fIdisplay\fP, \fIcolormap\fP\^, \fIccc\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Colormap \fIcolormap\fP\^; +.br + XcmsCCC \fIccc\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIcolormap\fP 1i +Specifies the colormap. +.IP \fIccc\fP 1i +Specifies the CCC. +.LP +.eM +The +.PN XcmsSetCCCOfColormap +function changes the CCC associated with the specified colormap. +It returns the CCC previously associated with the colormap. +If they are not used again in the application, +CCCs should be freed by calling +.PN XcmsFreeCCC . +Several colormaps may share the same CCC without restriction; this +includes the CCCs generated by Xlib with each colormap. Xlib, however, +creates a new CCC with each new colormap. +.NH 3 +Obtaining the Default Color Conversion Context +.XS +\*(SN Obtaining the Default Color Conversion Context +.XE +.LP +You can change the default CCC attributes for subsequently created CCCs +by changing the CCC attributes of the default CCC. +.IN "CCC" "default" +.IN "Color Conversion Context" "default" +A default CCC is associated with each screen. +.sp +.LP +To obtain the default CCC for a screen, use +.PN XcmsDefaultCCC . +.IN "XcmsDefaultCCC" "" "@DEF@" +.IN "Color Conversion Context" "default" +.IN "CCC" "default" +.sM +.FD 0 +XcmsCCC XcmsDefaultCCC\^(\^\fIdisplay\fP, \fIscreen_number\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + int \fIscreen_number\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIscreen_number\fP 1i +Specifies the appropriate screen number on the host server. +.LP +.eM +The +.PN XcmsDefaultCCC +function returns the default CCC for the specified screen. +Its visual is the default visual of the screen. +Its initial gamut compression and white point +adjustment procedures as well as the associated client data are implementation +specific. +.NH 3 +Color Conversion Context Macros +.XS +\*(SN Color Conversion Context Macros +.XE +.LP +Applications should not directly modify any part of the +.PN XcmsCCC . +The following lists the C language macros, their corresponding function +equivalents for other language bindings, and what data they both +can return. +.sp +.LP +.IN "DisplayOfCCC" "" "@DEF@" +.IN "XcmsDisplayOfCCC" "" "@DEF@" +.sM +.FD 0 +DisplayOfCCC\^(\^\fIccc\fP\^) +.br + XcmsCCC \fIccc\fP\^; +.sp +Display *XcmsDisplayOfCCC\^(\^\fIccc\fP\^) +.br + XcmsCCC \fIccc\fP\^; +.FN +.IP \fIccc\fP 1i +Specifies the CCC. +.LP +.eM +Both return the display associated with the specified CCC. +.LP +.sp +.IN "VisualOfCCC" "" "@DEF@" +.IN "XcmsVisualOfCCC" "" "@DEF@" +.sM +.FD 0 +VisualOfCCC\^(\^\fIccc\fP\^) +.br + XcmsCCC \fIccc\fP\^; +.sp +Visual *XcmsVisualOfCCC\^(\^\fIccc\fP\^) +.br + XcmsCCC \fIccc\fP\^; +.FN +.IP \fIccc\fP 1i +Specifies the CCC. +.LP +.eM +Both return the visual associated with the specified CCC. +.sp +.LP +.IN "ScreenNumberOfCCC" "" "@DEF@" +.IN "XcmsScreenNumberOfCCC" "" "@DEF@" +.sM +.FD 0 +ScreenNumberOfCCC\^(\^\fIccc\fP\^) +.br + XcmsCCC \fIccc\fP\^; +.sp +int XcmsScreenNumberOfCCC\^(\^\fIccc\fP\^) +.br + XcmsCCC \fIccc\fP\^; +.FN +.IP \fIccc\fP 1i +Specifies the CCC. +.LP +.eM +Both return the number of the screen associated with the specified CCC. +.sp +.LP +.IN "ScreenWhitePointOfCCC" "" "@DEF@" +.IN "XcmsScreenWhitePointOfCCC" "" "@DEF@" +.sM +.FD 0 +ScreenWhitePointOfCCC\^(\^\fIccc\fP\^) +.br + XcmsCCC \fIccc\fP\^; +.sp +XcmsColor *XcmsScreenWhitePointOfCCC\^(\^\fIccc\fP\^) +.br + XcmsCCC \fIccc\fP\^; +.FN +.IP \fIccc\fP 1i +Specifies the CCC. +.LP +.eM +Both return the white point of the screen associated with the specified CCC. +.sp +.LP +.IN "ClientWhitePointOfCCC" "" "@DEF@" +.IN "XcmsClientWhitePointOfCCC" "" "@DEF@" +.sM +.FD 0 +ClientWhitePointOfCCC\^(\^\fIccc\fP\^) +.br + XcmsCCC \fIccc\fP\^; +.sp +XcmsColor *XcmsClientWhitePointOfCCC\^(\^\fIccc\fP\^) +.br + XcmsCCC \fIccc\fP\^; +.FN +.IP \fIccc\fP 1i +Specifies the CCC. +.LP +.eM +Both return the Client White Point of the specified CCC. +.NH 3 +Modifying Attributes of a Color Conversion Context +.XS +\*(SN Modifying Attributes of a Color Conversion Context +.XE +.LP +To set the Client White Point in the CCC, use +.PN XcmsSetWhitePoint . +.IN "XcmsSetWhitePoint" "" "@DEF@" +.IN "Client White Point" "of Color Conversion Context" +.sM +.FD 0 +Status XcmsSetWhitePoint\^(\^\fIccc\fP\^, \fIcolor\fP\^) +.br + XcmsCCC \fIccc\fP\^; +.br + XcmsColor *\fIcolor\fP\^; +.FN +.IP \fIccc\fP 1i +Specifies the CCC. +.ds Co new Client White Point +.IP \fIcolor\fP 1i +Specifies the \*(Co. +.LP +.eM +The +.PN XcmsSetWhitePoint +function changes the Client White Point in the specified CCC. +Note that the pixel member is ignored +and that the color specification is left unchanged upon return. +The format for the new white point must be +.PN XcmsCIEXYZFormat , +.PN XcmsCIEuvYFormat , +.PN XcmsCIExyYFormat , +or +.PN XcmsUndefinedFormat . +If the color argument is NULL, this function sets the format component of the +Client White Point specification to +.PN XcmsUndefinedFormat , +indicating that the Client White Point is assumed to be the same as the +Screen White Point. +.LP +This function returns nonzero status +if the format for the new white point is valid; +otherwise, it returns zero. + +.sp +.LP +To set the gamut compression procedure and corresponding client data +in a specified CCC, use +.PN XcmsSetCompressionProc . +.IN "XcmsSetCompressionProc" "" "@DEF@" +.IN "Gamut compression" "setting in Color Conversion Context" +.IN "Gamut compression" "procedure" +.IN "Gamut compression" "client data" +.sM +.FD 0 +XcmsCompressionProc XcmsSetCompressionProc\^(\^\fIccc\fP\^, \fIcompression_proc\fP\^, \fIclient_data\fP\^) +.br + XcmsCCC \fIccc\fP\^; +.br + XcmsCompressionProc \fIcompression_proc\fP\^; +.br + XPointer \fIclient_data\fP\^; +.FN +.IP \fIccc\fP 1i +Specifies the CCC. +.IP \fIcompression_proc\fP 1i +Specifies the gamut compression procedure that is to be applied +when a color lies outside the screen's color gamut. +If NULL is specified and a function using this CCC must convert +a color specification to a device-dependent format and encounters a color +that lies outside the screen's color gamut, +that function will return +.PN XcmsFailure . +.ds Cd the gamut compression procedure +.IP \fIclient_data\fP 1i +Specifies client data for \*(Cd or NULL. +.LP +.eM +The +.PN XcmsSetCompressionProc +function first sets the gamut compression procedure and client data +in the specified CCC with the newly specified procedure and client data +and then returns the old procedure. +.sp +.LP +To set the white point adjustment procedure and corresponding client data +in a specified CCC, use +.PN XcmsSetWhiteAdjustProc . +.IN "XcmsSetWhiteAdjustProc" "" "@DEF@" +.IN "White point adjustment" "setting in Color Conversion Context" +.IN "White point adjustment" "procedure" +.IN "White point adjustment" "client data" +.FD 0 +.sM +XcmsWhiteAdjustProc XcmsSetWhiteAdjustProc\^(\^\fIccc\fP\^, \fIwhite_adjust_proc\fP\^, \fIclient_data\fP\^) +.br + XcmsCCC \fIccc\fP\^; +.br + XcmsWhiteAdjustProc \fIwhite_adjust_proc\fP\^; +.br + XPointer \fIclient_data\fP\^; +.FN +.IP \fIccc\fP 1i +Specifies the CCC. +.IP \fIwhite_adjust_proc\fP 1i +Specifies the white point adjustment procedure. +.ds Cd the white point adjustment procedure +.IP \fIclient_data\fP 1i +Specifies client data for \*(Cd or NULL. +.LP +.eM +The +.PN XcmsSetWhiteAdjustProc +function first sets the white point adjustment procedure and client data +in the specified CCC with the newly specified procedure and client data +and then returns the old procedure. +.NH 3 +Creating and Freeing a Color Conversion Context +.XS +\*(SN Creating and Freeing a Color Conversion Context +.XE +.LP +You can explicitly create a CCC within your application by calling +.PN XcmsCreateCCC . +These created CCCs can then be used by those functions that explicitly +call for a CCC argument. +Old CCCs that will not be used by the application should be freed using +.PN XcmsFreeCCC . +.sp +.LP +To create a CCC, use +.PN XcmsCreateCCC . +.IN "XcmsCreateCCC" "" "@DEF@" +.IN "Color Conversion Context" "creation" +.IN "CCC" "creation" +.sM +.FD 0 +XcmsCCC XcmsCreateCCC\^(\^\fIdisplay\fP, \fIscreen_number\fP\^, \fIvisual\fP\^, \fIclient_white_point\fP\^, \fIcompression_proc\fP\^, +.br + \fIcompression_client_data\fP\^, \fIwhite_adjust_proc\fP\^, \fIwhite_adjust_client_data\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + int \fIscreen_number\fP\^; +.br + Visual *\fIvisual\fP\^; +.br + XcmsColor *\fIclient_white_point\fP\^; +.br + XcmsCompressionProc \fIcompression_proc\fP\^; +.br + XPointer \fIcompression_client_data\fP\^; +.br + XcmsWhiteAdjustProc \fIwhite_adjust_proc\fP\^; +.br + XPointer \fIwhite_adjust_client_data\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIscreen_number\fP 1i +Specifies the appropriate screen number on the host server. +.IP \fIvisual\fP 1i +Specifies the visual type. +.IP \fIclient_white_point\fP 1i +Specifies the Client White Point. +If NULL is specified, +the Client White Point is to be assumed to be the same as the +Screen White Point. +Note that the pixel member is ignored. +.IP \fIcompression_proc\fP 1i +Specifies the gamut compression procedure that is to be applied +when a color lies outside the screen's color gamut. +If NULL is specified and a function using this CCC must convert +a color specification to a device-dependent format and encounters a color +that lies outside the screen's color gamut, +that function will return +.PN XcmsFailure . +.IP \fIcompression_client_data\fP 1i +Specifies client data for use by the gamut compression procedure or NULL. +.IP \fIwhite_adjust_proc\fP 1i +Specifies the white adjustment procedure that is to be applied +when the Client White Point differs from the Screen White Point. +NULL indicates that no white point adjustment is desired. +.IP \fIwhite_adjust_client_data\fP 1i +Specifies client data for use with the white point adjustment procedure or NULL. +.LP +.eM +The +.PN XcmsCreateCCC +function creates a CCC for the specified display, screen, and visual. +.LP +.sp +To free a CCC, use +.PN XcmsFreeCCC . +.IN "XcmsFreeCCC" "" "@DEF@" +.IN "Color Conversion Context" "freeing" +.IN "CCC" "freeing" +.sM +.FD 0 +void XcmsFreeCCC\^(\^\fIccc\fP\^) +.br + XcmsCCC \fIccc\fP\^; +.FN +.IP \fIccc\fP 1i +Specifies the CCC. +.LP +.eM +The +.PN XcmsFreeCCC +function frees the memory used for the specified CCC. +Note that default CCCs and those currently associated with colormaps +are ignored. +.NH 2 +Converting between Color Spaces +.XS +\*(SN Converting between Color Spaces +.XE +.LP +.sp +To convert an array of color specifications in arbitrary color formats +to a single destination format, use +.PN XcmsConvertColors . +.IN "Color conversion" +.IN "Color" "conversion" +.IN "XcmsConvertColors" "" "@DEF@" +.sM +.FD 0 +Status XcmsConvertColors\^(\^\fIccc\fP\^, \fIcolors_in_out\fP\^, \fIncolors\fP\^, \fItarget_format\fP\^, \fIcompression_flags_return\fP\^) +.br + XcmsCCC \fIccc\fP\^; +.br + XcmsColor \fIcolors_in_out\fP\^[\^]\^; +.br + unsigned int \fIncolors\fP\^; +.br + XcmsColorFormat \fItarget_format\fP\^; +.br + Bool \fIcompression_flags_return\fP\^[\^]\^; +.FN +.IP \fIccc\fP 1i +Specifies the CCC. +If conversion is between device-independent color spaces only +(for example, TekHVC to CIELuv), +the CCC is necessary only to specify the Client White Point. +.IP \fIcolors_in_out\fP 1i +Specifies an array of color specifications. +Pixel members are ignored and remain unchanged upon return. +.IP \fIncolors\fP 1i +Specifies the number of +.PN XcmsColor +structures in the color-specification array. +.IP \fItarget_format\fP 1i +Specifies the target color specification format. +.IP \fIcompression_flags_return\fP 1i +Returns an array of Boolean values indicating compression status. +If a non-NULL pointer is supplied, +each element of the array is set to +.PN True +if the corresponding color was compressed and +.PN False +otherwise. +Pass NULL if the compression status is not useful. +.LP +.eM +The +.PN XcmsConvertColors +function converts the color specifications in the specified array of +.PN XcmsColor +structures from their current format to a single target format, +using the specified CCC. +When the return value is +.PN XcmsFailure , +the contents of the color specification array are left unchanged. +.LP +The array may contain a mixture of color specification formats +(for example, 3 CIE XYZ, 2 CIE Luv, and so on). +When the array contains both device-independent and +device-dependent color specifications and the target_format argument specifies +a device-dependent format (for example, +.PN XcmsRGBiFormat , +.PN XcmsRGBFormat ), +all specifications are converted to CIE XYZ format and then to the target +device-dependent format. +.NH 2 +Callback Functions +.XS +\*(SN Callback Functions +.XE +.LP +This section describes the gamut compression and white point +adjustment callbacks. +.LP +The gamut compression procedure specified in the CCC +is called when an attempt to convert a color specification from +.PN XcmsCIEXYZ +to a device-dependent format (typically +.PN XcmsRGBi ) +results in a color that lies outside the screen's color gamut. +If the gamut compression procedure requires client data, this data is passed +via the gamut compression client data in the CCC. +.LP +During color specification conversion between device-independent +and device-dependent color spaces, +if a white point adjustment procedure is specified in the CCC, +it is triggered when the Client White Point and Screen White Point differ. +If required, the client data is obtained from the CCC. +.NH 3 +Prototype Gamut Compression Procedure +.XS +\*(SN Prototype Gamut Compression Procedure +.XE +.LP +The gamut compression callback interface must adhere to the +following: +.IN "XcmsCompressionProc" "" "@DEF@" +.sM +.FD 0 +typedef Status (*\^XcmsCompressionProc\^)\^(\^\fIccc\fP\^, \fIcolors_in_out\fP\^, \fIncolors\fP\^, \fIindex\fP\^, \fIcompression_flags_return\fP\^) +.br + XcmsCCC \fIccc\fP\^; +.br + XcmsColor \fIcolors_in_out[]\fP\^; +.br + unsigned int \fIncolors\fP\^; +.br + unsigned int \fIindex\fP\^; +.br + Bool \fIcompression_flags_return[]\fP\^; +.FN +.IP \fIccc\fP 1i +Specifies the CCC. +.IP \fIcolors_in_out\fP 1i +Specifies an array of color specifications. +Pixel members should be ignored and must remain unchanged upon return. +.IP \fIncolors\fP 1i +Specifies the number of +.PN XcmsColor +structures in the color-specification array. +.IP \fIindex\fP 1i +Specifies the index into the array of +.PN XcmsColor +structures for the encountered color specification that lies outside the +screen's color gamut. +Valid values are 0 (for the first element) to ncolors \- 1. +.IP \fIcompression_flags_return\fP 1i +Returns an array of Boolean values for indicating compression status. +If a non-NULL pointer is supplied +and a color at a given index is compressed, then +.PN True +should be stored at the corresponding index in this array; +otherwise, the array should not be modified. +.LP +.eM +When implementing a gamut compression procedure, consider the following +rules and assumptions: +.IP \(bu 5 +The gamut compression procedure can attempt to compress one or multiple +specifications at a time. +.IP \(bu 5 +When called, elements 0 to index \- 1 in the color specification +array can be assumed to fall within the screen's color gamut. +In addition, these color specifications are already in some device-dependent +format (typically +.PN XcmsRGBi ). +If any modifications are made to these color specifications, +they must be in their initial device-dependent format upon return. +.IP \(bu 5 +When called, the element in the color specification array specified +by the index argument contains the color specification outside the +screen's color gamut encountered by the calling routine. +In addition, this color specification can be assumed to be in +.PN XcmsCIEXYZ . +Upon return, this color specification must be in +.PN XcmsCIEXYZ . +.IP \(bu 5 +When called, elements from index to ncolors \- 1 +in the color specification array may or may not fall within the +screen's color gamut. +In addition, these color specifications can be assumed to be in +.PN XcmsCIEXYZ . +If any modifications are made to these color specifications, +they must be in +.PN XcmsCIEXYZ +upon return. +.IP \(bu 5 +The color specifications passed to the gamut compression procedure +have already been adjusted to the Screen White Point. +This means that at this point the color specification's white point +is the Screen White Point. +.IP \(bu 5 +If the gamut compression procedure uses a device-independent color space not +initially accessible for use in the color management system, use +.PN XcmsAddColorSpace +to ensure that it is added. +.NH 3 +Supplied Gamut Compression Procedures +.XS +\*(SN Supplied Gamut Compression Procedures +.XE +.LP +The following equations are useful in describing gamut compression +functions: +.EQ +delim %% +.EN +.LP +.Ds 0 +%CIELab~Psychometric~Chroma ~=~ sqrt(a_star sup 2 ~+~ b_star sup 2 )% + +%CIELab~Psychometric~Hue ~=~ tan sup -1 left [ b_star over a_star right ]% + +%CIELuv~Psychometric~Chroma ~=~ sqrt(u_star sup 2 ~+~ v_star sup 2 )% + +%CIELuv~Psychometric~Hue ~=~ tan sup -1 left [ v_star over u_star right ]% +.De +.LP +The gamut compression callback procedures provided by Xlib are as follows: +.IP \(bu 5 +.PN XcmsCIELabClipL +.IP +This brings the encountered out-of-gamut color specification into the +screen's color gamut by reducing or increasing CIE metric lightness (L*) +in the CIE L*a*b* color space until the color is within the gamut. +If the Psychometric Chroma of the color specification +is beyond maximum for the Psychometric Hue Angle, +then while maintaining the same Psychometric Hue Angle, +the color will be clipped to the CIE L*a*b* coordinates of maximum +Psychometric Chroma. +See +.PN XcmsCIELabQueryMaxC . +No client data is necessary. +.IP \(bu 5 +.PN XcmsCIELabClipab +.IP +This brings the encountered out-of-gamut color specification into the +screen's color gamut by reducing Psychometric Chroma, +while maintaining Psychometric Hue Angle, +until the color is within the gamut. +No client data is necessary. +.IP \(bu 5 +.PN XcmsCIELabClipLab +.IP +This brings the encountered out-of-gamut color specification into the +screen's color gamut by replacing it with CIE L*a*b* coordinates +that fall within the color gamut while maintaining the original +Psychometric Hue +Angle and whose vector to the original coordinates is the shortest attainable. +No client data is necessary. +.IP \(bu 5 +.PN XcmsCIELuvClipL +.IP +This brings the encountered out-of-gamut color specification into the +screen's color gamut by reducing or increasing CIE metric lightness (L*) +in the CIE L*u*v* color space until the color is within the gamut. +If the Psychometric Chroma of the color specification +is beyond maximum for the Psychometric Hue Angle, +then, while maintaining the same Psychometric Hue Angle, +the color will be clipped to the CIE L*u*v* coordinates of maximum +Psychometric Chroma. +See +.PN XcmsCIELuvQueryMaxC . +No client data is necessary. +.IP \(bu 5 +.PN XcmsCIELuvClipuv +.IP +This brings the encountered out-of-gamut color specification into the +screen's color gamut by reducing +Psychometric Chroma, while maintaining Psychometric Hue Angle, +until the color is within the gamut. +No client data is necessary. +.IP \(bu 5 +.PN XcmsCIELuvClipLuv +.IP +This brings the encountered out-of-gamut color specification into the +screen's color gamut by replacing it with CIE L*u*v* coordinates +that fall within the color gamut while maintaining the original +Psychometric Hue +Angle and whose vector to the original coordinates is the shortest attainable. +No client data is necessary. +.IP \(bu 5 +.PN XcmsTekHVCClipV +.IP +This brings the encountered out-of-gamut color specification into the +screen's color gamut by reducing or increasing the Value dimension +in the TekHVC color space until the color is within the gamut. +If Chroma of the color specification is beyond maximum for the particular Hue, +then, while maintaining the same Hue, +the color will be clipped to the Value and Chroma coordinates +that represent maximum Chroma for that particular Hue. +No client data is necessary. +.IP \(bu 5 +.PN XcmsTekHVCClipC +.IP +This brings the encountered out-of-gamut color specification into the +screen's color gamut by reducing the Chroma dimension +in the TekHVC color space until the color is within the gamut. +No client data is necessary. +.IP \(bu 5 +.PN XcmsTekHVCClipVC +.IP +This brings the encountered out-of-gamut color specification into the +screen's color gamut by replacing it with TekHVC coordinates +that fall within the color gamut while maintaining the original Hue +and whose vector to the original coordinates is the shortest attainable. +No client data is necessary. +.NH 3 +Prototype White Point Adjustment Procedure +.XS +\*(SN Prototype White Point Adjustment Procedure +.XE +.LP +The white point adjustment procedure interface must adhere to the following: +.IN "XcmsWhiteAdjustProc" "" "@DEF@" +.sM +.FD 0 +typedef Status (*\^XcmsWhiteAdjustProc\^)\^(\^\fIccc\fP\^, \fIinitial_white_point\fP\^, \fItarget_white_point\fP\^, \fItarget_format\fP\^, +.br + \fIcolors_in_out\fP\^, \fIncolors\fP\^, \fIcompression_flags_return\fP\^) +.br + XcmsCCC \fIccc\fP\^; +.br + XcmsColor *\fIinitial_white_point\fP\^; +.br + XcmsColor *\fItarget_white_point\fP\^; +.br + XcmsColorFormat \fItarget_format\fP\^; +.br + XcmsColor \fIcolors_in_out[]\fP\^; +.br + unsigned int \fIncolors\fP\^; +.br + Bool \fIcompression_flags_return[]\fP\^; +.FN +.IP \fIccc\fP 1i +Specifies the CCC. +.IP \fIinitial_white_point\fP 1i +Specifies the initial white point. +.IP \fItarget_white_point\fP 1i +Specifies the target white point. +.IP \fItarget_format\fP 1i +Specifies the target color specification format. +.IP \fIcolors_in_out\fP 1i +Specifies an array of color specifications. +Pixel members should be ignored and must remain unchanged upon return. +.IP \fIncolors\fP 1i +Specifies the number of +.PN XcmsColor +structures in the color-specification array. +.IP \fIcompression_flags_return\fP 1i +Returns an array of Boolean values for indicating compression status. +If a non-NULL pointer is supplied +and a color at a given index is compressed, then +.PN True +should be stored at the corresponding index in this array; +otherwise, the array should not be modified. +.LP +.eM +.NH 3 +Supplied White Point Adjustment Procedures +.XS +\*(SN Supplied White Point Adjustment Procedures +.XE +.LP +White point adjustment procedures provided by Xlib are as follows: +.IP \(bu 5 +.PN XcmsCIELabWhiteShiftColors +.IP +This uses the CIE L*a*b* color space for adjusting the chromatic character +of colors to compensate for the chromatic differences between the source +and destination white points. +This procedure simply converts the color specifications to +.PN XcmsCIELab +using the source white point and then converts to the target specification +format using the destination's white point. +No client data is necessary. +.IP \(bu 5 +.PN XcmsCIELuvWhiteShiftColors +.IP +This uses the CIE L*u*v* color space for adjusting the chromatic character +of colors to compensate for the chromatic differences between the source +and destination white points. +This procedure simply converts the color specifications to +.PN XcmsCIELuv +using the source white point and then converts to the target specification +format using the destination's white point. +No client data is necessary. +.IP \(bu 5 +.PN XcmsTekHVCWhiteShiftColors +.IP +This uses the TekHVC color space for adjusting the chromatic character +of colors to compensate for the chromatic differences between the source +and destination white points. +This procedure simply converts the color specifications to +.PN XcmsTekHVC +using the source white point and then converts to the target specification +format using the destination's white point. +An advantage of this procedure over those previously described +is an attempt to minimize hue shift. +No client data is necessary. +.LP +From an implementation point of view, +these white point adjustment procedures convert the color specifications +to a device-independent but white-point-dependent color space +(for example, CIE L*u*v*, CIE L*a*b*, TekHVC) using one white point +and then converting those specifications to the target color space +using another white point. +In other words, +the specification goes in the color space with one white point +but comes out with another white point, +resulting in a chromatic shift based on the chromatic displacement +between the initial white point and target white point. +The CIE color spaces that are assumed to be white-point-independent +are CIE u'v'Y, CIE XYZ, and CIE xyY. +When developing a custom white point adjustment procedure that uses a +device-independent color space not initially accessible for use in the +color management system, use +.PN XcmsAddColorSpace +to ensure that it is added. +.LP +As an example, +if the CCC specifies a white point adjustment procedure +and if the Client White Point and Screen White Point differ, the +.PN XcmsAllocColor +function will use the white point adjustment +procedure twice: +.IP \(bu 5 +Once to convert to +.PN XcmsRGB +.IP \(bu 5 +A second time to convert from +.PN XcmsRGB +.LP +For example, assume the specification is in +.PN XcmsCIEuvY +and the adjustment procedure is +.PN XcmsCIELuvWhiteShiftColors . +During conversion to +.PN XcmsRGB , +the call to +.PN XcmsAllocColor +results in the following series of color specification conversions: +.\" Do these need to be font coded? +.IP \(bu 5 +From +.PN XcmsCIEuvY +to +.PN XcmsCIELuv +using the Client White Point +.IP \(bu 5 +From +.PN XcmsCIELuv +to +.PN XcmsCIEuvY +using the Screen White Point +.IP \(bu 5 +From +.PN XcmsCIEuvY +to +.PN XcmsCIEXYZ +(CIE u'v'Y and XYZ are white-point-independent color spaces) +.IP \(bu 5 +From +.PN XcmsCIEXYZ +to +.PN XcmsRGBi +.IP \(bu 5 +From +.PN XcmsRGBi +to +.PN XcmsRGB +.LP +The resulting RGB specification is passed to +.PN XAllocColor , +and the RGB +specification returned by +.PN XAllocColor +is converted back to +.PN XcmsCIEuvY +by reversing the color conversion sequence. +.NH 2 +Gamut Querying Functions +.XS +\*(SN Gamut Querying Functions +.XE +.LP +This section describes the gamut querying functions that Xlib provides. +These functions allow the client to query the boundary +of the screen's color gamut in terms of the CIE L*a*b*, CIE L*u*v*, +and TekHVC color spaces. +.IN "Gamut querying" +Functions are also provided that allow you to query +the color specification of: +.IP \(bu 5 +White (full-intensity red, green, and blue) +.IP \(bu 5 +Red (full-intensity red while green and blue are zero) +.IP \(bu 5 +Green (full-intensity green while red and blue are zero) +.IP \(bu 5 +Blue (full-intensity blue while red and green are zero) +.IP \(bu 5 +Black (zero-intensity red, green, and blue) +.LP +The white point associated with color specifications passed to +and returned from these gamut querying +functions is assumed to be the Screen White Point. +.IN "Screen White Point" +This is a reasonable assumption, +because the client is trying to query the screen's color gamut. +.LP +The following naming convention is used for the Max and Min functions: +.LP +.Ds 0 +Xcms\fI\fPQueryMax\fI\fP + +Xcms\fI\fPQueryMin\fI\fP +.De +.LP +The consists of a letter or letters +that identify the dimensions of the color space +that are not fixed. +For example, +.PN XcmsTekHVCQueryMaxC +is given a fixed Hue and Value for which maximum Chroma is found. +.NH 3 +Red, Green, and Blue Queries +.XS +\*(SN Red, Green, and Blue Queries +.XE +.LP +To obtain the color specification for black +(zero-intensity red, green, and blue), use +.PN XcmsQueryBlack . +.IN "XcmsQueryBlack" "" "@DEF@" +.sM +.FD 0 +Status XcmsQueryBlack\^(\^\fIccc\fP\^, \fItarget_format\fP\^, \fIcolor_return\fP\^) +.br + XcmsCCC \fIccc\fP\^; +.br + XcmsColorFormat \fItarget_format\fP\^; +.br + XcmsColor *\fIcolor_return\fP\^; +.FN +.IP \fIccc\fP 1i +Specifies the CCC. +The CCC's Client White Point and white point adjustment procedures +are ignored. +.IP \fItarget_format\fP 1i +Specifies the target color specification format. +.ds Cs zero-intensity red, green, and blue +.IP \fIcolor_return\fP 1i +Returns the color specification in the specified target format +for \*(Cs. +The white point associated with the returned +color specification is the Screen White Point. +The value returned in the pixel member is undefined. +.LP +.eM +The +.PN XcmsQueryBlack +function returns the color specification in the specified target format +for zero-intensity red, green, and blue. +.sp +.LP +To obtain the color specification for blue +(full-intensity blue while red and green are zero), use +.PN XcmsQueryBlue . +.IN "XcmsQueryBlue" "" "@DEF@" +.sM +.FD 0 +Status XcmsQueryBlue\^(\^\fIccc\fP\^, \fItarget_format\fP\^, \fIcolor_return\fP\^) +.br + XcmsCCC \fIccc\fP\^; +.br + XcmsColorFormat \fItarget_format\fP\^; +.br + XcmsColor *\fIcolor_return\fP\^; +.FN +.IP \fIccc\fP 1i +Specifies the CCC. +The CCC's Client White Point and white point adjustment procedures +are ignored. +.IP \fItarget_format\fP 1i +Specifies the target color specification format. +.ds Cs full-intensity blue while red and green are zero +.IP \fIcolor_return\fP 1i +Returns the color specification in the specified target format +for \*(Cs. +The white point associated with the returned +color specification is the Screen White Point. +The value returned in the pixel member is undefined. +.LP +.eM +The +.PN XcmsQueryBlue +function returns the color specification in the specified target format +for full-intensity blue while red and green are zero. +.sp +.LP +To obtain the color specification for green +(full-intensity green while red and blue are zero), use +.PN XcmsQueryGreen . +.IN "XcmsQueryGreen" "" "@DEF@" +.sM +.FD 0 +Status XcmsQueryGreen\^(\^\fIccc\fP\^, \fItarget_format\fP\^, \fIcolor_return\fP\^) +.br + XcmsCCC \fIccc\fP\^; +.br + XcmsColorFormat \fItarget_format\fP\^; +.br + XcmsColor *\fIcolor_return\fP\^; +.FN +.IP \fIccc\fP 1i +Specifies the CCC. +The CCC's Client White Point and white point adjustment procedures +are ignored. +.IP \fItarget_format\fP 1i +Specifies the target color specification format. +.ds Cs full-intensity green while red and blue are zero +.IP \fIcolor_return\fP 1i +Returns the color specification in the specified target format +for \*(Cs. +The white point associated with the returned +color specification is the Screen White Point. +The value returned in the pixel member is undefined. +.LP +.eM +The +.PN XcmsQueryGreen +function returns the color specification in the specified target format +for full-intensity green while red and blue are zero. +.sp +.LP +To obtain the color specification for red +(full-intensity red while green and blue are zero), use +.PN XcmsQueryRed . +.IN "XcmsQueryRed" "" "@DEF@" +.sM +.FD 0 +Status XcmsQueryRed\^(\^\fIccc\fP\^, \fItarget_format\fP\^, \fIcolor_return\fP\^) +.br + XcmsCCC \fIccc\fP\^; +.br + XcmsColorFormat \fItarget_format\fP\^; +.br + XcmsColor *\fIcolor_return\fP\^; +.FN +.IP \fIccc\fP 1i +Specifies the CCC. +The CCC's Client White Point and white point adjustment procedures +are ignored. +.IP \fItarget_format\fP 1i +Specifies the target color specification format. +.ds Cs full-intensity red while green and blue are zero +.IP \fIcolor_return\fP 1i +Returns the color specification in the specified target format +for \*(Cs. +The white point associated with the returned +color specification is the Screen White Point. +The value returned in the pixel member is undefined. +.LP +.eM +The +.PN XcmsQueryRed +function returns the color specification in the specified target format +for full-intensity red while green and blue are zero. +.LP +.sp +To obtain the color specification for white +(full-intensity red, green, and blue), use +.PN XcmsQueryWhite . +.IN "XcmsQueryWhite" "" "@DEF@" +.sM +.FD 0 +Status XcmsQueryWhite\^(\^\fIccc\fP\^, \fItarget_format\fP\^, \fIcolor_return\fP\^) +.br + XcmsCCC \fIccc\fP\^; +.br + XcmsColorFormat \fItarget_format\fP\^; +.br + XcmsColor *\fIcolor_return\fP\^; +.FN +.IP \fIccc\fP 1i +Specifies the CCC. +The CCC's Client White Point and white point adjustment procedures +are ignored. +.IP \fItarget_format\fP 1i +Specifies the target color specification format. +.ds Cs full-intensity red, green, and blue +.IP \fIcolor_return\fP 1i +Returns the color specification in the specified target format +for \*(Cs. +The white point associated with the returned +color specification is the Screen White Point. +The value returned in the pixel member is undefined. +.LP +.eM +The +.PN XcmsQueryWhite +function returns the color specification in the specified target format +for full-intensity red, green, and blue. +.NH 3 +CIELab Queries +.XS +\*(SN CIELab Queries +.XE +.LP +The following equations are useful in describing the CIELab query functions: +.EQ +delim %% +.EN +.LP +.IN "Psychometric Hue Angle" +.IN "CIE metric lightness" +.IN "Psychometric Chroma" +.IN "Psychometric Chroma" "maximum" +.Ds 0 +%CIELab~Psychometric~Chroma ~=~ sqrt(a_star sup 2 ~+~ b_star sup 2 )% + +%CIELab~Psychometric~Hue ~=~ tan sup -1 left [ b_star over a_star right ]% +.De +.sp +To obtain the CIE L*a*b* coordinates of maximum Psychometric Chroma +for a given Psychometric Hue Angle and CIE metric lightness (L*), use +.PN XcmsCIELabQueryMaxC . +.IN "XcmsCIELabQueryMaxC" "" "@DEF@" +.sM +.FD 0 +Status XcmsCIELabQueryMaxC\^(\^\fIccc\fP\^, \fIhue_angle\fP\^, \fIL_star\fP\^, \fIcolor_return\fP\^) +.br + XcmsCCC \fIccc\fP\^; +.br + XcmsFloat \fIhue_angle\fP\^; +.br + XcmsFloat \fIL_star\fP\^; +.br + XcmsColor *\fIcolor_return\fP\^; +.FN +.IP \fIccc\fP 1i +Specifies the CCC. +The CCC's Client White Point and white point adjustment procedures +are ignored. +.ds Ha maximum chroma +.IP \fIhue_angle\fP 1i +Specifies the hue angle (in degrees) at which to find \*(Ha. +.ds Ls maximum chroma +.IP \fIL_star\fP 1i +Specifies the lightness (L*) at which to find \*(Ls. +.ds Lc maximum chroma +.ds lC hue angle and lightness +.IP \fIcolor_return\fP 1i +Returns the CIE L*a*b* coordinates of \*(Lc +displayable by the screen for the given \*(lC. +The white point associated with the returned +color specification is the Screen White Point. +The value returned in the pixel member is undefined. +.LP +.eM +The +.PN XcmsCIELabQueryMaxC +function, given a hue angle and lightness, +finds the point of maximum chroma displayable by the screen. +It returns this point in CIE L*a*b* coordinates. +.LP +.sp +To obtain the CIE L*a*b* coordinates of maximum CIE metric lightness (L*) +for a given Psychometric Hue Angle and Psychometric Chroma, use +.PN XcmsCIELabQueryMaxL . +.IN "Psychometric Hue Angle" +.IN "CIE metric lightness" +.IN "CIE metric lightness" "maximum" +.IN "XcmsCIELabQueryMaxL" "" "@DEF@" +.sM +.FD 0 +Status XcmsCIELabQueryMaxL\^(\^\fIccc\fP\^, \fIhue_angle\fP\^, \fIchroma\fP\^, \fIcolor_return\fP\^) +.br + XcmsCCC \fIccc\fP\^; +.br + XcmsFloat \fIhue_angle\fP\^; +.br + XcmsFloat \fIchroma\fP\^; +.br + XcmsColor *\fIcolor_return\fP\^; +.FN +.IP \fIccc\fP 1i +Specifies the CCC. +The CCC's Client White Point and white point adjustment procedures +are ignored. +.ds Ha maximum lightness +.IP \fIhue_angle\fP 1i +Specifies the hue angle (in degrees) at which to find \*(Ha. +.ds Ch maximum lightness +.IP \fIchroma\fP 1i +Specifies the chroma at which to find \*(Ch. +.ds Lc maximum lightness +.ds lC hue angle and chroma +.IP \fIcolor_return\fP 1i +Returns the CIE L*a*b* coordinates of \*(Lc +displayable by the screen for the given \*(lC. +The white point associated with the returned +color specification is the Screen White Point. +The value returned in the pixel member is undefined. +.LP +.eM +The +.PN XcmsCIELabQueryMaxL +function, given a hue angle and chroma, +finds the point in CIE L*a*b* color space of maximum +lightness (L*) displayable by the screen. +It returns this point in CIE L*a*b* coordinates. +An +.PN XcmsFailure +return value usually indicates that the given chroma +is beyond maximum for the given hue angle. +.sp +.LP +To obtain the CIE L*a*b* coordinates of maximum Psychometric Chroma +for a given Psychometric Hue Angle, use +.PN XcmsCIELabQueryMaxLC . +.IN "Psychometric Hue Angle" +.IN "Psychometric Chroma" +.IN "CIE metric lightness" +.IN "Psychometric Chroma" "maximum" +.IN "CIE metric lightness" "maximum" +.IN "XcmsCIELabQueryMaxLC" "" "@DEF@" +.sM +.FD 0 +Status XcmsCIELabQueryMaxLC\^(\^\fIccc\fP\^, \fIhue_angle\fP\^, \fIcolor_return\fP\^) +.br + XcmsCCC \fIccc\fP\^; +.br + XcmsFloat \fIhue_angle\fP\^; +.br + XcmsColor *\fIcolor_return\fP\^; +.FN +.IP \fIccc\fP 1i +Specifies the CCC. +The CCC's Client White Point and white point adjustment procedures +are ignored. +.ds Ha maximum chroma +.IP \fIhue_angle\fP 1i +Specifies the hue angle (in degrees) at which to find \*(Ha. +.ds Lc maximum chroma +.ds lC hue angle +.IP \fIcolor_return\fP 1i +Returns the CIE L*a*b* coordinates of \*(Lc +displayable by the screen for the given \*(lC. +The white point associated with the returned +color specification is the Screen White Point. +The value returned in the pixel member is undefined. +.LP +.eM +The +.PN XcmsCIELabQueryMaxLC +function, given a hue angle, +finds the point of maximum chroma displayable by the screen. +It returns this point in CIE L*a*b* coordinates. +.sp +.LP +To obtain the CIE L*a*b* coordinates of minimum CIE metric lightness (L*) +for a given Psychometric Hue Angle and Psychometric Chroma, use +.PN XcmsCIELabQueryMinL . +.IN "Psychometric Hue Angle" +.IN "CIE metric lightness" +.IN "CIE metric lightness" "minimum" +.IN "XcmsCIELabQueryMinL" "" "@DEF@" +.sM +.FD 0 +Status XcmsCIELabQueryMinL\^(\^\fIccc\fP\^, \fIhue_angle\fP\^, \fIchroma\fP\^, \fIcolor_return\fP\^) +.br + XcmsCCC \fIccc\fP\^; +.br + XcmsFloat \fIhue_angle\fP\^; +.br + XcmsFloat \fIchroma\fP\^; +.br + XcmsColor *\fIcolor_return\fP\^; +.FN +.IP \fIccc\fP 1i +Specifies the CCC. +The CCC's Client White Point and white point adjustment procedures +are ignored. +.ds Ha minimum lightness +.IP \fIhue_angle\fP 1i +Specifies the hue angle (in degrees) at which to find \*(Ha. +.ds Ch minimum lightness +.IP \fIchroma\fP 1i +Specifies the chroma at which to find \*(Ch. +.ds Lc minimum lightness +.ds lC hue angle and chroma +.IP \fIcolor_return\fP 1i +Returns the CIE L*a*b* coordinates of \*(Lc +displayable by the screen for the given \*(lC. +The white point associated with the returned +color specification is the Screen White Point. +The value returned in the pixel member is undefined. +.LP +.eM +The +.PN XcmsCIELabQueryMinL +function, given a hue angle and chroma, +finds the point of minimum lightness (L*) displayable by the screen. +It returns this point in CIE L*a*b* coordinates. +An +.PN XcmsFailure +return value usually indicates that the given chroma +is beyond maximum for the given hue angle. +.NH 3 +CIELuv Queries +.XS +\*(SN CIELuv Queries +.XE +.LP +The following equations are useful in describing the CIELuv query functions: +.EQ +delim %% +.EN +.LP +.IN "Psychometric Hue Angle" +.IN "CIE metric lightness" +.IN "Psychometric Chroma" +.IN "Psychometric Chroma" "maximum" +.Ds 0 +%CIELuv~Psychometric~Chroma ~=~ sqrt(u_star sup 2 ~+~ v_star sup 2 )% + +%CIELuv~Psychometric~Hue ~=~ tan sup -1 left [ v_star over u_star right ]% +.De +.sp +.LP +To obtain the CIE L*u*v* coordinates of maximum Psychometric Chroma +for a given Psychometric Hue Angle and CIE metric lightness (L*), use +.PN XcmsCIELuvQueryMaxC . +.IN "XcmsCIELuvQueryMaxC" "" "@DEF@" +.sM +.FD 0 +Status XcmsCIELuvQueryMaxC\^(\^\fIccc\fP\^, \fIhue_angle\fP\^, \fIL_star\fP\^, \fIcolor_return\fP\^) +.br + XcmsCCC \fIccc\fP\^; +.br + XcmsFloat \fIhue_angle\fP\^; +.br + XcmsFloat \fIL_star\fP\^; +.br + XcmsColor *\fIcolor_return\fP\^; +.FN +.IP \fIccc\fP 1i +Specifies the CCC. +The CCC's Client White Point and white point adjustment procedures +are ignored. +.ds Ha maximum chroma +.IP \fIhue_angle\fP 1i +Specifies the hue angle (in degrees) at which to find \*(Ha. +.ds Ls maximum chroma +.IP \fIL_star\fP 1i +Specifies the lightness (L*) at which to find \*(Ls. +.ds Lc maximum chroma +.ds lC hue angle and lightness +.IP \fIcolor_return\fP 1i +Returns the CIE L*u*v* coordinates of \*(Lc +displayable by the screen for the given \*(lC. +The white point associated with the returned +color specification is the Screen White Point. +The value returned in the pixel member is undefined. +.LP +.eM +The +.PN XcmsCIELuvQueryMaxC +function, given a hue angle and lightness, +finds the point of maximum chroma displayable by the screen. +It returns this point in CIE L*u*v* coordinates. +.sp +.LP +To obtain the CIE L*u*v* coordinates of maximum CIE metric lightness (L*) +for a given Psychometric Hue Angle and Psychometric Chroma, use +.PN XcmsCIELuvQueryMaxL . +.IN "Psychometric Hue Angle" +.IN "CIE metric lightness" +.IN "CIE metric lightness" "maximum" +.IN "XcmsCIELuvQueryMaxL" "" "@DEF@" +.sM +.FD 0 +Status XcmsCIELuvQueryMaxL\^(\^\fIccc\fP\^, \fIhue_angle\fP\^, \fIchroma\fP\^, \fIcolor_return\fP\^) +.br + XcmsCCC \fIccc\fP\^; +.br + XcmsFloat \fIhue_angle\fP\^; +.br + XcmsFloat \fIchroma\fP\^; +.br + XcmsColor *\fIcolor_return\fP\^; +.FN +.IP \fIccc\fP 1i +Specifies the CCC. +The CCC's Client White Point and white point adjustment procedures +are ignored. +.ds Ha maximum lightness +.IP \fIhue_angle\fP 1i +Specifies the hue angle (in degrees) at which to find \*(Ha. +.ds Ls maximum lightness +.IP \fIL_star\fP 1i +Specifies the lightness (L*) at which to find \*(Ls. +.ds Lc maximum lightness +.ds lC hue angle and chroma +.IP \fIcolor_return\fP 1i +Returns the CIE L*u*v* coordinates of \*(Lc +displayable by the screen for the given \*(lC. +The white point associated with the returned +color specification is the Screen White Point. +The value returned in the pixel member is undefined. +.LP +.eM +The +.PN XcmsCIELuvQueryMaxL +function, given a hue angle and chroma, +finds the point in CIE L*u*v* color space of maximum +lightness (L*) displayable by the screen. +It returns this point in CIE L*u*v* coordinates. +An +.PN XcmsFailure +return value usually indicates that the given chroma +is beyond maximum for the given hue angle. +.sp +.LP +To obtain the CIE L*u*v* coordinates of maximum Psychometric Chroma +for a given Psychometric Hue Angle, use +.PN XcmsCIELuvQueryMaxLC . +.IN "Psychometric Hue Angle" +.IN "Psychometric Chroma" +.IN "CIE metric lightness" +.IN "Psychometric Chroma" "maximum" +.IN "CIE metric lightness" "maximum" +.IN "XcmsCIELuvQueryMaxLC" "" "@DEF@" +.sM +.FD 0 +Status XcmsCIELuvQueryMaxLC\^(\^\fIccc\fP\^, \fIhue_angle\fP\^, \fIcolor_return\fP\^) +.br + XcmsCCC \fIccc\fP\^; +.br + XcmsFloat \fIhue_angle\fP\^; +.br + XcmsColor *\fIcolor_return\fP\^; +.FN +.IP \fIccc\fP 1i +Specifies the CCC. +The CCC's Client White Point and white point adjustment procedures +are ignored. +.ds Ha maximum chroma +.IP \fIhue_angle\fP 1i +Specifies the hue angle (in degrees) at which to find \*(Ha. +.ds Lc maximum chroma +.ds lC hue angle +.IP \fIcolor_return\fP 1i +Returns the CIE L*u*v* coordinates of \*(Lc +displayable by the screen for the given \*(lC. +The white point associated with the returned +color specification is the Screen White Point. +The value returned in the pixel member is undefined. +.LP +.eM +The +.PN XcmsCIELuvQueryMaxLC +function, given a hue angle, +finds the point of maximum chroma displayable by the screen. +It returns this point in CIE L*u*v* coordinates. +.sp +.LP +To obtain the CIE L*u*v* coordinates of minimum CIE metric lightness (L*) +for a given Psychometric Hue Angle and Psychometric Chroma, use +.PN XcmsCIELuvQueryMinL . +.IN "Psychometric Hue Angle" +.IN "CIE metric lightness" +.IN "CIE metric lightness" "minimum" +.IN "XcmsCIELuvQueryMinL" "" "@DEF@" +.sM +.FD 0 +Status XcmsCIELuvQueryMinL\^(\^\fIccc\fP\^, \fIhue_angle\fP\^, \fIchroma\fP\^, \fIcolor_return\fP\^) +.br + XcmsCCC \fIccc\fP\^; +.br + XcmsFloat \fIhue_angle\fP\^; +.br + XcmsFloat \fIchroma\fP\^; +.br + XcmsColor *\fIcolor_return\fP\^; +.FN +.IP \fIccc\fP 1i +Specifies the CCC. +The CCC's Client White Point and white point adjustment procedures +are ignored. +.ds Ha minimum lightness +.IP \fIhue_angle\fP 1i +Specifies the hue angle (in degrees) at which to find \*(Ha. +.ds Ch minimum lightness +.IP \fIchroma\fP 1i +Specifies the chroma at which to find \*(Ch. +.ds Lc minimum lightness +.ds lC hue angle and chroma +.IP \fIcolor_return\fP 1i +Returns the CIE L*u*v* coordinates of \*(Lc +displayable by the screen for the given \*(lC. +The white point associated with the returned +color specification is the Screen White Point. +The value returned in the pixel member is undefined. +.LP +.eM +The +.PN XcmsCIELuvQueryMinL +function, given a hue angle and chroma, +finds the point of minimum lightness (L*) displayable by the screen. +It returns this point in CIE L*u*v* coordinates. +An +.PN XcmsFailure +return value usually indicates that the given chroma +is beyond maximum for the given hue angle. +.NH 3 +TekHVC Queries +.XS +\*(SN TekHVC Queries +.XE +.LP +To obtain the maximum Chroma for a given Hue and Value, use +.PN XcmsTekHVCQueryMaxC . +.IN "Chroma" +.IN "Chroma" "maximum" +.IN "XcmsTekHVCQueryMaxC" "" "@DEF@" +.sM +.FD 0 +Status XcmsTekHVCQueryMaxC\^(\^\fIccc\fP\^, \fIhue\fP\^, \fIvalue\fP\^, \fIcolor_return\fP\^) +.br + XcmsCCC \fIccc\fP\^; +.br + XcmsFloat \fIhue\fP\^; +.br + XcmsFloat \fIvalue\fP\^; +.br + XcmsColor *\fIcolor_return\fP\^; +.FN +.IP \fIccc\fP 1i +Specifies the CCC. +The CCC's Client White Point and white point adjustment procedures +are ignored. +.ds Hu in which to find the maximum Chroma +.IP \fIhue\fP 1i +Specifies the Hue \*(Hu. +.ds Va maximum Chroma +.IP \fIvalue\fP 1i +Specifies the Value in which to find the \*(Va. +.ds Lc maximum Chroma along with the actual Hue and Value +.ds lC maximum Chroma +.IP \fIcolor_return\fP 1i +Returns the \*(Lc at which the \*(lC was found. +The white point associated with the returned +color specification is the Screen White Point. +The value returned in the pixel member is undefined. +.LP +.eM +The +.PN XcmsTekHVCQueryMaxC +function, given a Hue and Value, +determines the maximum Chroma in TekHVC color space +displayable by the screen. +It returns the maximum Chroma along with the actual Hue +and Value at which the maximum Chroma was found. +.sp +.LP +To obtain the maximum Value for a given Hue and Chroma, use +.PN XcmsTekHVCQueryMaxV . +.IN "Value" +.IN "Value" "maximum" +.IN "XcmsTekHVCQueryMaxV" "" "@DEF@" +.sM +.FD 0 +Status XcmsTekHVCQueryMaxV\^(\^\fIccc\fP\^, \fIhue\fP\^, \fIchroma\fP\^, \fIcolor_return\fP\^) +.br + XcmsCCC \fIccc\fP\^; +.br + XcmsFloat \fIhue\fP\^; +.br + XcmsFloat \fIchroma\fP\^; +.br + XcmsColor *\fIcolor_return\fP\^; +.FN +.IP \fIccc\fP 1i +Specifies the CCC. +The CCC's Client White Point and white point adjustment procedures +are ignored. +.ds Hu in which to find the maximum Value +.IP \fIhue\fP 1i +Specifies the Hue \*(Hu. +.ds Ch maximum Value +.IP \fIchroma\fP 1i +Specifies the chroma at which to find \*(Ch. +.ds Lc maximum Value along with the Hue and Chroma +.ds lC maximum Value +.IP \fIcolor_return\fP 1i +Returns the \*(Lc at which the \*(lC was found. +The white point associated with the returned +color specification is the Screen White Point. +The value returned in the pixel member is undefined. +.LP +.eM +The +.PN XcmsTekHVCQueryMaxV +function, given a Hue and Chroma, +determines the maximum Value in TekHVC color space +displayable by the screen. +It returns the maximum Value and the actual Hue and Chroma +at which the maximum Value was found. +.sp +.LP +To obtain the maximum Chroma and Value at which it is reached +for a specified Hue, use +.PN XcmsTekHVCQueryMaxVC . +.IN "Chroma" +.IN "Value" +.IN "Chroma" "maximum" +.IN "Value" "maximum" +.IN "XcmsTekHVCQueryMaxVC" "" "@DEF@" +.sM +.FD 0 +Status XcmsTekHVCQueryMaxVC\^(\^\fIccc\fP\^, \fIhue\fP\^, \fIcolor_return\fP\^) +.br + XcmsCCC \fIccc\fP\^; +.br + XcmsFloat \fIhue\fP\^; +.br + XcmsColor *\fIcolor_return\fP\^; +.FN +.IP \fIccc\fP 1i +Specifies the CCC. +The CCC's Client White Point and white point adjustment procedures +are ignored. +.ds Hu in which to find the maximum Chroma +.IP \fIhue\fP 1i +Specifies the Hue \*(Hu. +.ds Lc color specification in \ +XcmsTekHVC for the maximum Chroma, the Value at which \ +that maximum Chroma is reached, and the actual Hue +.ds lC maximum Chroma +.IP \fIcolor_return\fP 1i +Returns the \*(Lc at which the \*(lC was found. +The white point associated with the returned +color specification is the Screen White Point. +The value returned in the pixel member is undefined. +.LP +.eM +The +.PN XcmsTekHVCQueryMaxVC +function, given a Hue, +determines the maximum Chroma in TekHVC color space displayable by the screen +and the Value at which that maximum Chroma is reached. +It returns the maximum Chroma, +the Value at which that maximum Chroma is reached, +and the actual Hue for which the maximum Chroma was found. +.sp +.LP +To obtain a specified number of TekHVC specifications such that they +contain maximum Values for a specified Hue and the +Chroma at which the maximum Values are reached, use +.PN XcmsTekHVCQueryMaxVSamples . +.IN "Chroma" +.IN "Value" +.IN "Chroma" "maximum" +.IN "Value" "maximum" +.IN "XcmsTekHVCQueryMaxVSamples" "" "@DEF@" +.sM +.FD 0 +Status XcmsTekHVCQueryMaxVSamples\^(\^\fIccc\fP\^, \fIhue\fP\^, \fIcolors_return\fP\^, \fInsamples\fP\^) +.br + XcmsCCC \fIccc\fP\^; +.br + XcmsFloat \fIhue\fP\^; +.br + XcmsColor \fIcolors_return[]\fP\^; +.br + unsigned int \fInsamples\fP\^; +.FN +.IP \fIccc\fP 1i +Specifies the CCC. +The CCC's Client White Point and white point adjustment procedures +are ignored. +.ds Hu for maximum Chroma/Value samples +.IP \fIhue\fP 1i +Specifies the Hue \*(Hu. +.IP \fInsamples\fP 1i +Specifies the number of samples. +.IP \fIcolors_return\fP 1i +Returns nsamples of color specifications in XcmsTekHVC +such that the Chroma is the maximum attainable for the Value and Hue. +The white point associated with the returned +color specification is the Screen White Point. +The value returned in the pixel member is undefined. +.LP +.eM +The +.PN XcmsTekHVCQueryMaxVSamples +returns nsamples of maximum Value, the Chroma at which that maximum Value +is reached, and the actual Hue for which the maximum Chroma was found. +These sample points may then be used to plot the maximum Value/Chroma +boundary of the screen's color gamut for the specified Hue in TekHVC color +space. +.sp +.LP +To obtain the minimum Value for a given Hue and Chroma, use +.PN XcmsTekHVCQueryMinV . +.IN "Value" +.IN "Value" "minimum" +.IN "XcmsTekHVCQueryMinV" "" "@DEF@" +.sM +.FD 0 +Status XcmsTekHVCQueryMinV\^(\^\fIccc\fP\^, \fIhue\fP\^, \fIchroma\fP\^, \fIcolor_return\fP\^) +.br + XcmsCCC \fIccc\fP\^; +.br + XcmsFloat \fIhue\fP\^; +.br + XcmsFloat \fIchroma\fP\^; +.br + XcmsColor *\fIcolor_return\fP\^; +.FN +.IP \fIccc\fP 1i +Specifies the CCC. +The CCC's Client White Point and white point adjustment procedures +are ignored. +.ds Hu in which to find the minimum Value +.IP \fIhue\fP 1i +Specifies the Hue \*(Hu. +.ds Va minimum Value +.IP \fIvalue\fP 1i +Specifies the Value in which to find the \*(Va. +.ds Lc minimum Value and the actual Hue and Chroma +.ds lC minimum Value +.IP \fIcolor_return\fP 1i +Returns the \*(Lc at which the \*(lC was found. +The white point associated with the returned +color specification is the Screen White Point. +The value returned in the pixel member is undefined. +.LP +.eM +The +.PN XcmsTekHVCQueryMinV +function, given a Hue and Chroma, +determines the minimum Value in TekHVC color space displayable by the screen. +It returns the minimum Value and the actual Hue and Chroma at which +the minimum Value was found. +.NH 2 +Color Management Extensions +.XS +\*(SN Color Management Extensions +.XE +.LP +The Xlib color management facilities can be extended in two ways: +.IP \(bu 5 +Device-Independent Color Spaces +.IP +Device-independent color spaces that are derivable to CIE XYZ +space can be added using the +.PN XcmsAddColorSpace +function. +.IP \(bu 5 +Color Characterization Function Set +.IP +A Color Characterization Function Set consists of +device-dependent color spaces and their functions that +convert between these color spaces and the CIE XYZ +color space, bundled together for a specific class of output devices. +A function set can be added using the +.PN XcmsAddFunctionSet +function. +.NH 3 +Color Spaces +.XS +\*(SN Color Spaces +.XE +.LP +The CIE XYZ color space serves as the hub for all +conversions between device-independent and device-dependent color spaces. +Therefore, the knowledge to convert an +.PN XcmsColor +structure to and from CIE XYZ format is associated with each color space. +For example, conversion from CIE L*u*v* to RGB requires the knowledge +to convert from CIE L*u*v* to CIE XYZ and from CIE XYZ to RGB. +This knowledge is stored as an array of functions that, +when applied in series, will convert the +.PN XcmsColor +structure to or from CIE XYZ format. +This color specification conversion mechanism facilitates +the addition of color spaces. +.LP +Of course, when converting between only device-independent color spaces +or only device-dependent color spaces, +shortcuts are taken whenever possible. +For example, conversion from TekHVC to CIE L*u*v* is performed +by intermediate conversion to CIE u*v*Y and then to CIE L*u*v*, +thus bypassing conversion between CIE u*v*Y and CIE XYZ. +.NH 3 +Adding Device-Independent Color Spaces +.XS +\*(SN Adding Device-Independent Color Spaces +.XE +.LP +To add a device-independent color space, use +.PN XcmsAddColorSpace . +.IN "XcmsAddColorSpace" "" "@DEF@" +.sM +.FD 0 +Status XcmsAddColorSpace\^(\^\fIcolor_space\fP\^) +.br + XcmsColorSpace *\fIcolor_space\fP\^; +.FN +.IP \fIcolor_space\fP 1i +Specifies the device-independent color space to add. +.LP +.eM +The +.PN XcmsAddColorSpace +function makes a device-independent color space (actually an +.PN XcmsColorSpace +structure) accessible by the color management system. +Because format values for unregistered color spaces are assigned at run time, +they should be treated as private to the client. +If references to an unregistered color space must be made +outside the client (for example, storing color specifications +in a file using the unregistered color space), +then reference should be made by color space prefix +(see +.PN XcmsFormatOfPrefix +and +.PN XcmsPrefixOfFormat ). +.LP +If the +.PN XcmsColorSpace +structure is already accessible in the color management system, +.PN XcmsAddColorSpace +returns +.PN XcmsSuccess . +.LP +Note that added +.PN XcmsColorSpaces +must be retained for reference by Xlib. +.NH 3 +Querying Color Space Format and Prefix +.XS +\*(SN Querying Color Space Format and Prefix +.XE +.LP +To obtain the format associated with the color space +associated with a specified color string prefix, use +.PN XcmsFormatOfPrefix . +.IN "XcmsFormatOfPrefix" "" "@DEF@" +.sM +.FD 0 +XcmsColorFormat XcmsFormatOfPrefix\^(\^\fIprefix\fP\^) +.br + char *\fIprefix\fP\^; +.FN +.IP \fIprefix\fP 1i +Specifies the string that contains the color space prefix. +.LP +.eM +The +.PN XcmsFormatOfPrefix +function returns the format for the specified color space prefix +(for example, the string ``CIEXYZ''). +The prefix is case-insensitive. +If the color space is not accessible in the color management system, +.PN XcmsFormatOfPrefix +returns +.PN XcmsUndefinedFormat . +.LP +.sp +To obtain the color string prefix associated with the color space +specified by a color format, use +.PN XcmsPrefixOfFormat . +.IN "XcmsPrefixOfFormat" "" "@DEF@" +.sM +.FD 0 +char *XcmsPrefixOfFormat\^(\^\fIformat\fP\^) +.br + XcmsColorFormat \fIformat\fP\^; +.FN +.IP \fIformat\fP 1i +Specifies the color specification format. +.LP +.eM +The +.PN XcmsPrefixOfFormat +function returns the string prefix associated with the color specification +encoding specified by the format argument. +Otherwise, if no encoding is found, it returns NULL. +The returned string must be treated as read-only. +.NH 3 +Creating Additional Color Spaces +.XS +\*(SN Creating Additional Color Spaces +.XE +.LP +Color space specific information necessary +for color space conversion and color string parsing is stored in an +.PN XcmsColorSpace +structure. +Therefore, a new structure containing this information is required +for each additional color space. +In the case of device-independent color spaces, +a handle to this new structure (that is, by means of a global variable) +is usually made accessible to the client program for use with the +.PN XcmsAddColorSpace +function. +.LP +If a new +.PN XcmsColorSpace +structure specifies a color space not registered with the X Consortium, +they should be treated as private to the client +because format values for unregistered color spaces are assigned at run time. +If references to an unregistered color space must be made outside the +client (for example, storing color specifications in a file using the +unregistered color space), then reference should be made by color space prefix +(see +.PN XcmsFormatOfPrefix +and +.PN XcmsPrefixOfFormat ). +.sM +.LP +.Ds 0 +.TA .5i 2.5i +.ta .5i 2.5i +typedef (*XcmsConversionProc)(); +typedef XcmsConversionProc *XcmsFuncListPtr; + /* A NULL terminated list of function pointers*/ + +typedef struct _XcmsColorSpace { + char *prefix; + XcmsColorFormat format; + XcmsParseStringProc parseString; + XcmsFuncListPtr to_CIEXYZ; + XcmsFuncListPtr from_CIEXYZ; + int inverse_flag; +} XcmsColorSpace; +.De +.LP +.eM +The prefix member specifies the prefix that indicates a color string +is in this color space's string format. +For example, the strings ``ciexyz'' or ``CIEXYZ'' for CIE XYZ, +and ``rgb'' or ``RGB'' for RGB. +The prefix is case insensitive. +The format member specifies the color specification format. +Formats for unregistered color spaces are assigned at run time. +The parseString member contains a pointer to the function +that can parse a color string into an +.PN XcmsColor +structure. +This function returns an integer (int): nonzero if it succeeded +and zero otherwise. +The to_CIEXYZ and from_CIEXYZ members contain pointers, +each to a NULL terminated list of function pointers. +When the list of functions is executed in series, +it will convert the color specified in an +.PN XcmsColor +structure from/to the current color space format to/from the CIE XYZ format. +Each function returns an integer (int): nonzero if it succeeded +and zero otherwise. +The white point to be associated with the colors is specified +explicitly, even though white points can be found in the CCC. +The inverse_flag member, if nonzero, specifies that for each function listed +in to_CIEXYZ, +its inverse function can be found in from_CIEXYZ such that: +.LP +.Ds 0 +Given: n = number of functions in each list + +for each i, such that 0 <= i < n + from_CIEXYZ[n - i - 1] is the inverse of to_CIEXYZ[i]. +.De +.LP +This allows Xlib to use the shortest conversion path, +thus bypassing CIE XYZ if possible (for example, TekHVC to CIE L*u*v*). +.NH 3 +Parse String Callback +.XS +\*(SN Parse String Callback +.XE +.LP +The callback in the +.PN XcmsColorSpace +structure for parsing a color string for the particular color space must +adhere to the following software interface specification: +.IN "XcmsParseStringProc" "" "@DEF@" +.sM +.FD 0 +typedef int (*XcmsParseStringProc)\^(\^\fIcolor_string\fP, \fIcolor_return\fP\^) +.br + char *\fIcolor_string\fP\^; +.br + XcmsColor *\fIcolor_return\fP\^; +.FN +.IP \fIcolor_string\fP 1i +Specifies the color string to parse. +.IP \fIcolor_return\fP 1i +Returns the color specification in the color space's format. +.LP +.eM +.NH 3 +Color Specification Conversion Callback +.XS +\*(SN Color Specification Conversion Callback +.XE +.LP +Callback functions in the +.PN XcmsColorSpace +structure for converting a color specification between device-independent +spaces must adhere to the +following software interface specification: +.sM +.FD 0 +Status ConversionProc\^(\^\fIccc\fP, \fIwhite_point\fP, \fIcolors_in_out\fP, \fIncolors\fP\^) +.br + XcmsCCC \fIccc\fP\^; +.br + XcmsColor *\fIwhite_point\fP\^; +.br + XcmsColor *\fIcolors_in_out\fP\^; +.br + unsigned int \fIncolors\fP\^; +.FN +.IP \fIccc\fP 1i +Specifies the CCC. +.IP \fIwhite_point\fP 1i +Specifies the white point associated with color specifications. +The pixel member should be ignored, +and the entire structure remain unchanged upon return. +.IP \fIcolors_in_out\fP 1i +Specifies an array of color specifications. +Pixel members should be ignored and must remain unchanged upon return. +.IP \fIncolors\fP 1i +Specifies the number of +.PN XcmsColor +structures in the color-specification array. +.LP +.eM +.sp +Callback functions in the +.PN XcmsColorSpace +structure for converting a color specification to or from a device-dependent +space must adhere to the +following software interface specification: +.sM +.FD 0 +Status ConversionProc\^(\^\fIccc\fP, \fIcolors_in_out\fP, \fIncolors\fP, \fIcompression_flags_return\fP\^) +.br + XcmsCCC \fIccc\fP\^; +.br + XcmsColor *\fIcolors_in_out\fP\^; +.br + unsigned int \fIncolors\fP\^; +.br + Bool \fIcompression_flags_return\fP\^[\^]\^; +.FN +.IP \fIccc\fP 1i +Specifies the CCC. +.IP \fIcolors_in_out\fP 1i +Specifies an array of color specifications. +Pixel members should be ignored and must remain unchanged upon return. +.IP \fIncolors\fP 1i +Specifies the number of +.PN XcmsColor +structures in the color-specification array. +.IP \fIcompression_flags_return\fP 1i +Returns an array of Boolean values for indicating compression status. +If a non-NULL pointer is supplied +and a color at a given index is compressed, then +.PN True +should be stored at the corresponding index in this array; +otherwise, the array should not be modified. +.LP +.eM +Conversion functions are available globally for use by other color +spaces. +The conversion functions provided by Xlib are: +.TS H +lw(1.8i) lw(1.8i) lw(1.8i). +_ +.sp 6p +.B +Function Converts from Converts to +.sp 6p +_ +.sp 6p +.TH +.R +T{ +.PN XcmsCIELabToCIEXYZ +T} T{ +.PN XcmsCIELabFormat +T} T{ +.PN XcmsCIEXYZFormat +T} +T{ +.PN XcmsCIELuvToCIEuvY +T} T{ +.PN XcmsCIELuvFormat +T} T{ +.PN XcmsCIEuvYFormat +T} +T{ +.PN XcmsCIEXYZToCIELab +T} T{ +.PN XcmsCIEXYZFormat +T} T{ +.PN XcmsCIELabFormat +T} +T{ +.PN XcmsCIEXYZToCIEuvY +T} T{ +.PN XcmsCIEXYZFormat +T} T{ +.PN XcmsCIEuvYFormat +T} +T{ +.PN XcmsCIEXYZToCIExyY +T} T{ +.PN XcmsCIEXYZFormat +T} T{ +.PN XcmsCIExyYFormat +T} +T{ +.PN XcmsCIEXYZToRGBi +T} T{ +.PN XcmsCIEXYZFormat +T} T{ +.PN XcmsRGBiFormat +T} +T{ +.PN XcmsCIEuvYToCIELuv +T} T{ +.PN XcmsCIEuvYFormat +T} T{ +.PN XcmsCIELabFormat +T} +T{ +.PN XcmsCIEuvYToCIEXYZ +T} T{ +.PN XcmsCIEuvYFormat +T} T{ +.PN XcmsCIEXYZFormat +T} +T{ +.PN XcmsCIEuvYToTekHVC +T} T{ +.PN XcmsCIEuvYFormat +T} T{ +.PN XcmsTekHVCFormat +T} +T{ +.PN XcmsCIExyYToCIEXYZ +T} T{ +.PN XcmsCIExyYFormat +T} T{ +.PN XcmsCIEXYZFormat +T} +T{ +.PN XcmsRGBToRGBi +T} T{ +.PN XcmsRGBFormat +T} T{ +.PN XcmsRGBiFormat +T} +T{ +.PN XcmsRGBiToCIEXYZ +T} T{ +.PN XcmsRGBiFormat +T} T{ +.PN XcmsCIEXYZFormat +T} +T{ +.PN XcmsRGBiToRGB +T} T{ +.PN XcmsRGBiFormat +T} T{ +.PN XcmsRGBFormat +T} +T{ +.PN XcmsTekHVCToCIEuvY +T} T{ +.PN XcmsTekHVCFormat +T} T{ +.PN XcmsCIEuvYFormat +T} +.sp 6p +_ +.TE +.NH 3 +Function Sets +.XS +\*(SN Function Sets +.XE +.IN "Function set" +.IN "Function set" "LINEAR_RGB" +.LP +Functions to convert between device-dependent color spaces +and CIE XYZ may differ for different classes of output devices +(for example, color versus gray monitors). +Therefore, the notion of a Color Characterization Function Set +has been developed. +A function set consists of device-dependent color spaces +and the functions that convert color specifications +between these device-dependent color spaces and the CIE XYZ color space +appropriate for a particular class of output devices. +The function set also contains a function that reads +color characterization data off root window properties. +It is this characterization data that will differ between devices within +a class of output devices. +.IN "Device Color Characterization" +For details about how color characterization data is +stored in root window properties, +see the section on Device Color Characterization in the +\fIInter-Client Communication Conventions Manual\fP. +The LINEAR_RGB function set is provided by Xlib +and will support most color monitors. +Function sets may require data that differs +from those needed for the LINEAR_RGB function set. +In that case, +its corresponding data may be stored on different root window properties. +.NH 3 +Adding Function Sets +.XS +\*(SN Adding Function Sets +.XE +.LP +To add a function set, use +.PN XcmsAddFunctionSet . +.IN "XcmsAddFunctionSet" "" "@DEF@" +.sM +.FD 0 +Status XcmsAddFunctionSet\^(\^\fIfunction_set\fP\^) +.br + XcmsFunctionSet *\fIfunction_set\fP\^; +.FN +.IP \fIfunction_set\fP 1i +Specifies the function set to add. +.LP +.eM +The +.PN XcmsAddFunctionSet +function adds a function set to the color management system. +If the function set uses device-dependent +.PN XcmsColorSpace +structures not accessible in the color management system, +.PN XcmsAddFunctionSet +adds them. +If an added +.PN XcmsColorSpace +structure is for a device-dependent color space not registered +with the X Consortium, +they should be treated as private to the client +because format values for unregistered color spaces are assigned at run time. +If references to an unregistered color space must be made outside the +client (for example, storing color specifications in a file +using the unregistered color space), +then reference should be made by color space prefix +(see +.PN XcmsFormatOfPrefix +and +.PN XcmsPrefixOfFormat ). +.LP +Additional function sets should be added before any calls to other +Xlib routines are made. +If not, the +.PN XcmsPerScrnInfo +member of a previously created +.PN XcmsCCC +does not have the opportunity to initialize +with the added function set. +.NH 3 +Creating Additional Function Sets +.XS +\*(SN Creating Additional Function Sets +.XE +.LP +The creation of additional function sets should be +required only when an output device does not conform to existing +function sets or when additional device-dependent color spaces are necessary. +A function set consists primarily of a collection of device-dependent +.PN XcmsColorSpace +structures and a means to read and store a +screen's color characterization data. +This data is stored in an +.PN XcmsFunctionSet +structure. +A handle to this structure (that is, by means of global variable) +is usually made accessible to the client program for use with +.PN XcmsAddFunctionSet . +.LP +If a function set uses new device-dependent +.PN XcmsColorSpace +structures, +they will be transparently processed into the color management system. +Function sets can share an +.PN XcmsColorSpace +structure for a device-dependent color space. +In addition, multiple +.PN XcmsColorSpace +structures are allowed for a device-dependent color space; +however, a function set can reference only one of them. +These +.PN XcmsColorSpace +structures will differ in the functions to convert to and from CIE XYZ, +thus tailored for the specific function set. +.sM +.LP +.Ds 0 +.TA .5i 2.5i +.ta .5i 2.5i +typedef struct _XcmsFunctionSet { + XcmsColorSpace **DDColorSpaces; + XcmsScreenInitProc screenInitProc; + XcmsScreenFreeProc screenFreeProc; +} XcmsFunctionSet; +.De +.LP +.eM +The DDColorSpaces member is a pointer to a NULL terminated list +of pointers to +.PN XcmsColorSpace +structures for the device-dependent color spaces that are supported +by the function set. +The screenInitProc member is set to the callback procedure (see the following +interface specification) that initializes the +.PN XcmsPerScrnInfo +structure for a particular screen. +.LP +The screen initialization callback must adhere to the following software +interface specification: +.IN "XcmsScreenInitProc" "" "@DEF@" +.sM +.FD 0 +typedef Status (*XcmsScreenInitProc)\^(\^\fIdisplay\fP, \fIscreen_number\fP, \fIscreen_info\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + int \fIscreen_number\fP\^; +.br + XcmsPerScrnInfo *\fIscreen_info\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIscreen_number\fP 1i +Specifies the appropriate screen number on the host server. +.IP \fIscreen_info\fP 1i +Specifies the +.PN XcmsPerScrnInfo +structure, which contains the per screen information. +.LP +.eM +The screen initialization callback in the +.PN XcmsFunctionSet +structure fetches the color characterization data (device profile) for +the specified screen, +typically off properties on the +screen's root window. +It then initializes the specified +.PN XcmsPerScrnInfo +structure. +.IN "Device profile" +.IN "Color Characterization Data" +If successful, the procedure fills in the +.PN XcmsPerScrnInfo +structure as follows: +.IP \(bu 5 +It sets the screenData member to the address +of the created device profile data structure +(contents known only by the function set). +.IP \(bu 5 +It next sets the screenWhitePoint member. +.IP \(bu 5 +It next sets the functionSet member to the address of the +.PN XcmsFunctionSet +structure. +.IP \(bu 5 +It then sets the state member to +.PN XcmsInitSuccess +and finally returns +.PN XcmsSuccess . +.LP +If unsuccessful, the procedure sets the state member to +.PN XcmsInitFailure +and returns +.PN XcmsFailure . +.LP +The +.PN XcmsPerScrnInfo +structure contains: +.sM +.LP +.Ds 0 +.TA .5i 2.5i +.ta .5i 2.5i +typedef struct _XcmsPerScrnInfo { + XcmsColor screenWhitePoint; + XPointer functionSet; + XPointer screenData; + unsigned char state; + char pad[3]; +} XcmsPerScrnInfo; +.De +.LP +.eM +The screenWhitePoint member specifies the white point inherent to +the screen. +The functionSet member specifies the appropriate function set. +The screenData member specifies the device profile. +The state member is set to one of the following: +.IP \(bu 5 +.PN XcmsInitNone +indicates initialization has not been previously attempted. +.IP \(bu 5 +.PN XcmsInitFailure +indicates initialization has been previously attempted but failed. +.IP \(bu 5 +.PN XcmsInitSuccess +indicates initialization has been previously attempted and succeeded. +.LP +The screen free callback must adhere to the following software +interface specification: +.IN "XcmsScreenFreeProc" "" "@DEF@" +.sM +.FD 0 +typedef void (*XcmsScreenFreeProc)\^(\^\fIscreenData\fP\^) +.br + XPointer \fIscreenData\fP\^; +.FN +.IP \fIscreenData\fP 1i +Specifies the data to be freed. +.LP +.eM +This function is called to free the screenData stored in an +.PN XcmsPerScrnInfo +structure. +.bp diff --git a/libX11/specs/libX11/CH07 b/libX11/specs/libX11/CH07 new file mode 100644 index 000000000..d6f672289 --- /dev/null +++ b/libX11/specs/libX11/CH07 @@ -0,0 +1,2357 @@ +.\" Copyright \(co 1985, 1986, 1987, 1988, 1989, 1990, 1991, 1994, 1996 X Consortium +.\" +.\" 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 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 X CONSORTIUM 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 X Consortium 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 X Consortium. +.\" +.\" Copyright \(co 1985, 1986, 1987, 1988, 1989, 1990, 1991 by +.\" Digital Equipment Corporation +.\" +.\" Portions Copyright \(co 1990, 1991 by +.\" Tektronix, Inc. +.\" +.\" Permission to use, copy, modify and distribute this documentation for +.\" any purpose and without fee is hereby granted, provided that the above +.\" copyright notice appears in all copies and that both that copyright notice +.\" and this permission notice appear in all copies, and that the names of +.\" Digital and Tektronix not be used in in advertising or publicity pertaining +.\" to this documentation without specific, written prior permission. +.\" Digital and Tektronix makes no representations about the suitability +.\" of this documentation for any purpose. +.\" It is provided ``as is'' without express or implied warranty. +.\" +\& +.sp 1 +.ce 3 +\s+1\fBChapter 7\fP\s-1 + +\s+1\fBGraphics Context Functions\fP\s-1 +.sp 2 +.nr H1 7 +.nr H2 0 +.nr H3 0 +.nr H4 0 +.nr H5 0 +.na +.LP +.XS +Chapter 7: Graphics Context Functions +.XE +A number of resources are used when performing graphics operations in X. +Most information about performing graphics (for example, foreground +color, background color, line style, and so on) is stored in +resources called graphics contexts (GCs). +.IN "Graphics context" +Most graphics operations (see chapter 8) take a +GC as an argument. +Although in theory the X protocol permits sharing of GCs between applications, +it is expected that applications will use their own +GCs when performing operations. +Sharing of GCs is highly discouraged because the library may cache GC state. +.LP +Graphics operations can be performed to either windows or pixmaps, +which collectively are called drawables. +.IN "Root" +Each drawable exists on a single screen. +A GC is created for a specific screen and drawable depth +and can only be used with drawables of matching +screen and depth. +.LP +This chapter discusses how to: +.IP \(bu 5 +Manipulate graphics context/state +.IP \(bu 5 +Use graphics context convenience functions +.NH 2 +Manipulating Graphics Context/State +.XS +\*(SN Manipulating Graphics Context/State +.XE +.LP +Most attributes of graphics operations are stored in GCs. +These include line width, line style, plane mask, foreground, background, +tile, stipple, clipping region, end style, join style, and so on. +Graphics operations (for example, drawing lines) use these values +to determine the actual drawing operation. +Extensions to X may add additional components to GCs. +The contents of a GC are private to Xlib. +.LP +Xlib implements a write-back cache for all elements of a GC that are not +resource IDs to allow Xlib to implement the transparent coalescing of changes +to GCs. +For example, +a call to +.PN XSetForeground +of a GC followed by a call to +.PN XSetLineAttributes +results in only a single-change GC protocol request to the server. +GCs are neither expected nor encouraged to be shared between client +applications, so this write-back caching should present no problems. +Applications cannot share GCs without external synchronization. +Therefore, +sharing GCs between applications is highly discouraged. +.LP +To set an attribute of a GC, +set the appropriate member of the +.PN XGCValues +structure and OR in the corresponding value bitmask in your subsequent calls to +.PN XCreateGC . +The symbols for the value mask bits and the +.PN XGCValues +structure are: +.sM +.LP +/* GC attribute value mask bits */ +.TS +lw(.5i) lw(2.5i) lw(.75i). +#define\ + T{ +.PN GCFunction +T} T{ +(1L<<0) +T} +#define\ + T{ +.PN GCPlaneMask +T} T{ +(1L<<1) +T} +#define\ + T{ +.PN GCForeground +T} T{ +(1L<<2) +T} +#define\ + T{ +.PN GCBackground +T} T{ +(1L<<3) +T} +#define\ + T{ +.PN GCLineWidth +T} T{ +(1L<<4) +T} +#define\ + T{ +.PN GCLineStyle +T} T{ +(1L<<5) +T} +#define\ + T{ +.PN GCCapStyle +T} T{ +(1L<<6) +T} +#define\ + T{ +.PN GCJoinStyle +T} T{ +(1L<<7) +T} +#define\ + T{ +.PN GCFillStyle +T} T{ +(1L<<8) +T} +#define\ + T{ +.PN GCFillRule +T} T{ +(1L<<9) +T} +#define\ + T{ +.PN GCTile +T} T{ +(1L<<10) +T} +#define\ + T{ +.PN GCStipple +T} T{ +(1L<<11) +T} +#define\ + T{ +.PN GCTileStipXOrigin +T} T{ +(1L<<12) +T} +#define\ + T{ +.PN GCTileStipYOrigin +T} T{ +(1L<<13) +T} +#define\ + T{ +.PN GCFont +T} T{ +(1L<<14) +T} +#define\ + T{ +.PN GCSubwindowMode +T} T{ +(1L<<15) +T} +#define\ + T{ +.PN GCGraphicsExposures +T} T{ +(1L<<16) +T} +#define\ + T{ +.PN GCClipXOrigin +T} T{ +(1L<<17) +T} +#define\ + T{ +.PN GCClipYOrigin +T} T{ +(1L<<18) +T} +#define\ + T{ +.PN GCClipMask +T} T{ +(1L<<19) +T} +#define\ + T{ +.PN GCDashOffset +T} T{ +(1L<<20) +T} +#define\ + T{ +.PN GCDashList +T} T{ +(1L<<21) +T} +#define\ + T{ +.PN GCArcMode +T} T{ +(1L<<22) +T} +.TE +.IN "XGCValues" "" "@DEF@" +.Ds 0 +.TA .5i 3i +.ta .5i 3i +/* Values */ + +typedef struct { + int function; /* logical operation */ + unsigned long plane_mask; /* plane mask */ + unsigned long foreground; /* foreground pixel */ + unsigned long background; /* background pixel */ + int line_width; /* line width (in pixels) */ + int line_style; /* LineSolid, LineOnOffDash, LineDoubleDash */ + int cap_style; /* CapNotLast, CapButt, CapRound, CapProjecting */ + int join_style; /* JoinMiter, JoinRound, JoinBevel */ + int fill_style; /* FillSolid, FillTiled, FillStippled FillOpaqueStippled*/ + int fill_rule; /* EvenOddRule, WindingRule */ + int arc_mode; /* ArcChord, ArcPieSlice */ + Pixmap tile; /* tile pixmap for tiling operations */ + Pixmap stipple; /* stipple 1 plane pixmap for stippling */ + int ts_x_origin; /* offset for tile or stipple operations */ + int ts_y_origin; + Font font; /* default text font for text operations */ + int subwindow_mode; /* ClipByChildren, IncludeInferiors */ + Bool graphics_exposures; /* boolean, should exposures be generated */ + int clip_x_origin; /* origin for clipping */ + int clip_y_origin; + Pixmap clip_mask; /* bitmap clipping; other calls for rects */ + int dash_offset; /* patterned/dashed line information */ + char dashes; +} XGCValues; +.De +.LP +.eM +The default GC values are: +.TS H +l l. +_ +.sp 6p +.B +Component Default +.sp 6p +_ +.sp 6p +.TH +.R +T{ +function +T} T{ +.PN GXcopy +T} +plane_mask All ones +foreground 0 +background 1 +line_width 0 +T{ +line_style +T} T{ +.PN LineSolid +T} +T{ +cap_style +T} T{ +.PN CapButt +T} +T{ +join_style +T} T{ +.PN JoinMiter +T} +T{ +fill_style +T} T{ +.PN FillSolid +T} +T{ +fill_rule +T} T{ +.PN EvenOddRule +T} +T{ +arc_mode +T} T{ +.PN ArcPieSlice +T} +tile Pixmap of unspecified size filled with foreground pixel + (that is, client specified pixel if any, else 0) + (subsequent changes to foreground do not affect this pixmap) +stipple Pixmap of unspecified size filled with ones +ts_x_origin 0 +ts_y_origin 0 +font +T{ +subwindow_mode +T} T{ +.PN ClipByChildren +T} +T{ +graphics_exposures +T} T{ +.PN True +T} +clip_x_origin 0 +clip_y_origin 0 +T{ +clip_mask +T} T{ +.PN None +T} +dash_offset 0 +dashes 4 (that is, the list [4, 4]) +.sp 6p +_ +.TE +.LP +Note that foreground and background are not set to any values likely +to be useful in a window. +.LP +.IN "Display Functions" "" "@DEF@" +.IN "Source" "" "@DEF@" +.IN "Destination" "" "@DEF@" +The function attributes of a GC are used when you update a section of +a drawable (the destination) with bits from somewhere else (the source). +The function in a GC defines how the new destination bits are to be +computed from the source bits and the old destination bits. +.PN GXcopy +is typically the most useful because it will work on a color display, +but special applications may use other functions, +particularly in concert with particular planes of a color display. +The 16 GC functions, defined in +.hN X11/X.h , +are: +.\" are listed in Table 5-1 along with the +.\"the associated hexadecimal code +.\" and operation. +.\".CP T 1 +.\"Display Functions +.TS H +lw(1.5i) cw(.5i) lw(2i). +_ +.sp 6p +.B +Function Name Value Operation +.sp 6p +_ +.sp 6p +.TH +T{ +.PN GXclear +T} T{ +0x0 +T} T{ +0 +T} +T{ +.PN GXand +T} T{ +0x1 +T} T{ +src AND dst +T} +T{ +.PN GXandReverse +T} T{ +0x2 +T} T{ +src AND NOT dst +T} +T{ +.PN GXcopy +T} T{ +0x3 +T} T{ +src +T} +T{ +.PN GXandInverted +T} T{ +0x4 +T} T{ +(NOT src) AND dst +T} +T{ +.PN GXnoop +T} T{ +0x5 +T} T{ +dst +T} +T{ +.PN GXxor +T} T{ +0x6 +T} T{ +src XOR dst +T} +T{ +.PN GXor +T} T{ +0x7 +T} T{ +src OR dst +T} +T{ +.PN GXnor +T} T{ +0x8 +T} T{ +(NOT src) AND (NOT dst) +T} +T{ +.PN GXequiv +T} T{ +0x9 +T} T{ +(NOT src) XOR dst +T} +T{ +.PN GXinvert +T} T{ +0xa +T} T{ +NOT dst +T} +T{ +.PN GXorReverse +T} T{ +0xb +T} T{ +src OR (NOT dst) +T} +T{ +.PN GXcopyInverted +T} T{ +0xc +T} T{ +NOT src +T} +T{ +.PN GXorInverted +T} T{ +0xd +T} T{ +(NOT src) OR dst +T} +T{ +.PN GXnand +T} T{ +0xe +T} T{ +(NOT src) OR (NOT dst) +T} +T{ +.PN GXset +T} T{ +0xf +T} T{ +1 +T} +.sp 6p +_ +.TE +.LP +Many graphics operations depend on either pixel values or planes in a GC. +.IN "Pixel value" +The planes attribute is of type long, and it specifies which planes of the +destination are to be modified, one bit per plane. +.IN "Plane" "mask" +A monochrome display has only one plane and +will be the least significant bit of the word. +As planes are added to the display hardware, they will occupy more +significant bits in the plane mask. +.LP +In graphics operations, given a source and destination pixel, +the result is computed bitwise on corresponding bits of the pixels. +That is, a Boolean operation is performed in each bit plane. +The plane_mask restricts the operation to a subset of planes. +A macro constant +.PN AllPlanes +can be used to refer to all planes of the screen simultaneously. +The result is computed by the following: +.LP +.Ds +((src FUNC dst) AND plane-mask) OR (dst AND (NOT plane-mask)) +.De +.LP +Range checking is not performed on the values for foreground, +background, or plane_mask. +They are simply truncated to the appropriate +number of bits. +The line-width is measured in pixels and either can be greater than or equal to +one (wide line) or can be the special value zero (thin line). +.LP +Wide lines are drawn centered on the path described by the graphics request. +Unless otherwise specified by the join-style or cap-style, +the bounding box of a wide line with endpoints [x1, y1], [x2, y2] and +width w is a rectangle with vertices at the following real coordinates: +.LP +.Ds +.TA .5i 2.5i +.ta .5i 2.5i +[x1-(w*sn/2), y1+(w*cs/2)], [x1+(w*sn/2), y1-(w*cs/2)], +[x2-(w*sn/2), y2+(w*cs/2)], [x2+(w*sn/2), y2-(w*cs/2)] +.De +.LP +Here sn is the sine of the angle of the line, +and cs is the cosine of the angle of the line. +A pixel is part of the line and so is drawn +if the center of the pixel is fully inside the bounding box +(which is viewed as having infinitely thin edges). +If the center of the pixel is exactly on the bounding box, +it is part of the line if and only if the interior is immediately to its right +(x increasing direction). +Pixels with centers on a horizontal edge are a special case and are part of +the line if and only if the interior or the boundary is immediately below +(y increasing direction) and the interior or the boundary is immediately +to the right (x increasing direction). +.LP +Thin lines (zero line-width) are one-pixel-wide lines drawn using an +unspecified, device-dependent algorithm. +There are only two constraints on this algorithm. +.IP 1. 5 +If a line is drawn unclipped from [x1,y1] to [x2,y2] and +if another line is drawn unclipped from [x1+dx,y1+dy] to [x2+dx,y2+dy], +a point [x,y] is touched by drawing the first line +if and only if the point [x+dx,y+dy] is touched by drawing the second line. +.IP 2. 5 +The effective set of points comprising a line cannot be affected by clipping. +That is, a point is touched in a clipped line if and only if the point +lies inside the clipping region and the point would be touched +by the line when drawn unclipped. +.LP +A wide line drawn from [x1,y1] to [x2,y2] always draws the same pixels +as a wide line drawn from [x2,y2] to [x1,y1], not counting cap-style +and join-style. +It is recommended that this property be true for thin lines, +but this is not required. +A line-width of zero may differ from a line-width of one in which pixels are +drawn. +This permits the use of many manufacturers' line drawing hardware, +which may run many times faster than the more precisely specified +wide lines. +.LP +In general, +drawing a thin line will be faster than drawing a wide line of width one. +However, because of their different drawing algorithms, +thin lines may not mix well aesthetically with wide lines. +If it is desirable to obtain precise and uniform results across all displays, +a client should always use a line-width of one rather than a line-width of zero. +.LP +The line-style defines which sections of a line are drawn: +.TS +lw(1.3i) lw(4.5i). +T{ +.PN LineSolid +T} T{ +The full path of the line is drawn. +T} +.sp 6p +T{ +.PN LineDoubleDash +T} T{ +The full path of the line is drawn, +but the even dashes are filled differently +from the odd dashes (see fill-style) with +.PN CapButt +style used where even and odd dashes meet. +T} +.sp 6p +T{ +.PN LineOnOffDash +T} T{ +Only the even dashes are drawn, +and cap-style applies to +all internal ends of the individual dashes, +except +.PN CapNotLast +is treated as +.PN CapButt . +T} +.TE +.LP +The cap-style defines how the endpoints of a path are drawn: +.IN "Graphics context" "path" +.TS +lw(1.3i) lw(4.5i). +T{ +.PN CapNotLast +T} T{ +This is equivalent to +.PN CapButt +except that for a line-width of zero the final endpoint is not drawn. +T} +.sp 6p +T{ +.PN CapButt +T} T{ +The line is square at the endpoint (perpendicular to the slope of the line) +with no projection beyond. +T} +.sp 6p +T{ +.PN CapRound +T} T{ +The line has a circular arc with the diameter equal to the line-width, +centered on the endpoint. +(This is equivalent to +.PN CapButt +for line-width of zero). +T} +.sp 6p +T{ +.PN CapProjecting +T} T{ +The line is square at the end, but the path continues beyond the endpoint +for a distance equal to half the line-width. +(This is equivalent to +.PN CapButt +for line-width of zero). +T} +.TE +.LP +The join-style defines how corners are drawn for wide lines: +.TS +lw(1.3i) lw(4.5i). +T{ +.PN JoinMiter +T} T{ +The outer edges of two lines extend to meet at an angle. +However, if the angle is less than 11 degrees, +then a +.PN JoinBevel +join-style is used instead. +T} +.sp 6p +T{ +.PN JoinRound +T} T{ +The corner is a circular arc with the diameter equal to the line-width, +centered on the joinpoint. +T} +.sp 6p +T{ +.PN JoinBevel +T} T{ +The corner has +.PN CapButt +endpoint styles with the triangular notch filled. +T} +.TE +.LP +For a line with coincident endpoints (x1=x2, y1=y2), +when the cap-style is applied to both endpoints, +the semantics depends on the line-width and the cap-style: +.TS +lw(1.3i) lw(.5i) lw(4i). +T{ +.PN CapNotLast +T} T{ +thin +T} T{ +The results are device dependent, +but the desired effect is that nothing is drawn. +T} +.sp 6p +T{ +.PN CapButt +T} T{ +thin +T} T{ +The results are device dependent, +but the desired effect is that a single pixel is drawn. +T} +.sp 6p +T{ +.PN CapRound +T} T{ +thin +T} T{ +The results are the same as for +.PN CapButt /thin. +T} +.sp 6p +T{ +.PN CapProjecting +T} T{ +thin +T} T{ +The results are the same as for +.PN CapButt /thin. +T} +.sp 6p +T{ +.PN CapButt +T} T{ +wide +T} T{ +Nothing is drawn. +T} +.sp 6p +T{ +.PN CapRound +T} T{ +wide +T} T{ +The closed path is a circle, centered at the endpoint, and +with the diameter equal to the line-width. +T} +.sp 6p +T{ +.PN CapProjecting +T} T{ +wide +T} T{ +The closed path is a square, aligned with the coordinate axes, centered at the +endpoint, and with the sides equal to the line-width. +T} +.TE +.LP +For a line with coincident endpoints (x1=x2, y1=y2), +when the join-style is applied at one or both endpoints, +the effect is as if the line was removed from the overall path. +However, if the total path consists of or is reduced to a single point joined +with itself, the effect is the same as when the cap-style is applied at both +endpoints. +.LP +The tile/stipple represents an infinite two-dimensional plane, +with the tile/stipple replicated in all dimensions. +When that plane is superimposed on the drawable +for use in a graphics operation, the upper-left corner +of some instance of the tile/stipple is at the coordinates within +the drawable specified by the tile/stipple origin. +The tile/stipple and clip origins are interpreted relative to the +origin of whatever destination drawable is specified in a graphics +request. +The tile pixmap must have the same root and depth as the GC, +or a +.PN BadMatch +error results. +The stipple pixmap must have depth one and must have the same root as the +GC, or a +.PN BadMatch +error results. +For stipple operations where the fill-style is +.PN FillStippled +but not +.PN FillOpaqueStippled , +the stipple pattern is tiled in a +single plane and acts as an additional clip mask to be ANDed with the clip-mask. +Although some sizes may be faster to use than others, +any size pixmap can be used for tiling or stippling. +.LP +The fill-style defines the contents of the source for line, text, and +fill requests. +For all text and fill requests (for example, +.PN XDrawText , +.PN XDrawText16 , +.PN XFillRectangle , +.PN XFillPolygon , +and +.PN XFillArc ); +for line requests +with line-style +.PN LineSolid +(for example, +.PN XDrawLine , +.PN XDrawSegments , +.PN XDrawRectangle , +.PN XDrawArc ); +and for the even dashes for line requests with line-style +.PN LineOnOffDash +or +.PN LineDoubleDash , +the following apply: +.TS +lw(1.8i) lw(4i). +T{ +.PN FillSolid +T} T{ +Foreground +T} +.sp 6p +T{ +.PN FillTiled +T} T{ +Tile +T} +.sp 6p +T{ +.PN FillOpaqueStippled +T} T{ +A tile with the same width and height as stipple, +but with background everywhere stipple has a zero +and with foreground everywhere stipple has a one +T} +.sp 6p +T{ +.PN FillStippled +T} T{ +Foreground masked by stipple +T} +.TE +.LP +When drawing lines with line-style +.PN LineDoubleDash , +the odd dashes are controlled by the fill-style in the following manner: +.TS +lw(1.8i) lw(4i). +T{ +.PN FillSolid +T} T{ +Background +T} +.sp 6p +T{ +.PN FillTiled +T} T{ +Same as for even dashes +T} +.sp 6p +T{ +.PN FillOpaqueStippled +T} T{ +Same as for even dashes +T} +.sp 6p +T{ +.PN FillStippled +T} T{ +Background masked by stipple +T} +.TE +.LP +Storing a pixmap in a GC might or might not result in a copy +being made. +If the pixmap is later used as the destination for a graphics request, +the change might or might not be reflected in the GC. +If the pixmap is used simultaneously in a graphics request both as +a destination and as a tile or stipple, +the results are undefined. +.LP +For optimum performance, +you should draw as much as possible with the same GC +(without changing its components). +The costs of changing GC components relative to using different GCs +depend on the display hardware and the server implementation. +It is quite likely that some amount of GC information will be +cached in display hardware and that such hardware can only cache a small number +of GCs. +.LP +The dashes value is actually a simplified form of the +more general patterns that can be set with +.PN XSetDashes . +Specifying a +value of N is equivalent to specifying the two-element list [N, N] in +.PN XSetDashes . +The value must be nonzero, +or a +.PN BadValue +error results. +.LP +The clip-mask restricts writes to the destination drawable. +If the clip-mask is set to a pixmap, +it must have depth one and have the same root as the GC, +or a +.PN BadMatch +error results. +If clip-mask is set to +.PN None , +the pixels are always drawn regardless of the clip origin. +The clip-mask also can be set by calling the +.PN XSetClipRectangles +or +.PN XSetRegion +functions. +Only pixels where the clip-mask has a bit set to 1 are drawn. +Pixels are not drawn outside the area covered by the clip-mask +or where the clip-mask has a bit set to 0. +The clip-mask affects all graphics requests. +The clip-mask does not clip sources. +The clip-mask origin is interpreted relative to the origin of whatever +destination drawable is specified in a graphics request. +.LP +You can set the subwindow-mode to +.PN ClipByChildren +or +.PN IncludeInferiors . +For +.PN ClipByChildren , +both source and destination windows are +additionally clipped by all viewable +.PN InputOutput +children. +For +.PN IncludeInferiors , +neither source nor destination window is clipped by inferiors. +This will result in including subwindow contents in the source +and drawing through subwindow boundaries of the destination. +The use of +.PN IncludeInferiors +on a window of one depth with mapped +inferiors of differing depth is not illegal, but the semantics are +undefined by the core protocol. +.LP +The fill-rule defines what pixels are inside (drawn) for +paths given in +.PN XFillPolygon +requests and can be set to +.PN EvenOddRule +or +.PN WindingRule . +For +.PN EvenOddRule , +a point is inside if +an infinite ray with the point as origin crosses the path an odd number +of times. +For +.PN WindingRule , +a point is inside if an infinite ray with the +point as origin crosses an unequal number of clockwise and +counterclockwise directed path segments. +A clockwise directed path segment is one that crosses the ray from left to +right as observed from the point. +A counterclockwise segment is one that crosses the ray from right to left +as observed from the point. +The case where a directed line segment is coincident with the ray is +uninteresting because you can simply choose a different ray that is not +coincident with a segment. +.LP +For both +.PN EvenOddRule +and +.PN WindingRule , +a point is infinitely small, +and the path is an infinitely thin line. +A pixel is inside if the center point of the pixel is inside +and the center point is not on the boundary. +If the center point is on the boundary, +the pixel is inside if and only if the polygon interior is immediately to +its right (x increasing direction). +Pixels with centers on a horizontal edge are a special case +and are inside if and only if the polygon interior is immediately below +(y increasing direction). +.LP +The arc-mode controls filling in the +.PN XFillArcs +function and can be set to +.PN ArcPieSlice +or +.PN ArcChord . +For +.PN ArcPieSlice , +the arcs are pie-slice filled. +For +.PN ArcChord , +the arcs are chord filled. +.LP +The graphics-exposure flag controls +.PN GraphicsExpose +event generation +for +.PN XCopyArea +and +.PN XCopyPlane +requests (and any similar requests defined by extensions). +.LP +.sp +To create a new GC that is usable on a given screen with a +depth of drawable, use +.PN XCreateGC . +.IN "Graphics context" "initializing" +.IN "XCreateGC" "" "@DEF@" +.sM +.FD 0 +GC XCreateGC\^(\^\fIdisplay\fP, \fId\fP\^, \fIvaluemask\fP\^, \fIvalues\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Drawable \fId\fP\^; +.br + unsigned long \fIvaluemask\fP\^; +.br + XGCValues *\^\fIvalues\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fId\fP 1i +Specifies the drawable. +.ds Vm set using the information in the specified values structure +.IP \fIvaluemask\fP 1i +Specifies which components in the GC are to be \*(Vm. +This argument is the bitwise inclusive OR of zero or more of the valid +GC component mask bits. +.IP \fIvalues\fP 1i +Specifies any values as specified by the valuemask. +.LP +.eM +The +.PN XCreateGC +function creates a graphics context and returns a GC. +The GC can be used with any destination drawable having the same root +and depth as the specified drawable. +Use with other drawables results in a +.PN BadMatch +error. +.LP +.PN XCreateGC +can generate +.PN BadAlloc , +.PN BadDrawable , +.PN BadFont , +.PN BadMatch , +.PN BadPixmap , +and +.PN BadValue +errors. +.LP +.sp +To copy components from a source GC to a destination GC, use +.PN XCopyGC . +.IN "XCopyGC" "" "@DEF@" +.sM +.FD 0 +XCopyGC\^(\^\fIdisplay\fP, \fIsrc\fP\^, \fIvaluemask\fP\^, \fIdest\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + GC \fIsrc\fP\^, \fIdest\fP\^; +.br + unsigned long \fIvaluemask\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIsrc\fP 1i +Specifies the components of the source GC. +.ds Vm copied to the destination GC +.IP \fIvaluemask\fP 1i +Specifies which components in the GC are to be \*(Vm. +This argument is the bitwise inclusive OR of zero or more of the valid +GC component mask bits. +.IP \fIdest\fP 1i +Specifies the destination GC. +.LP +.eM +The +.PN XCopyGC +function copies the specified components from the source GC +to the destination GC. +The source and destination GCs must have the same root and depth, +or a +.PN BadMatch +error results. +The valuemask specifies which component to copy, as for +.PN XCreateGC . +.LP +.PN XCopyGC +can generate +.PN BadAlloc , +.PN BadGC , +and +.PN BadMatch +errors. +.LP +.sp +To change the components in a given GC, use +.PN XChangeGC . +.IN "XChangeGC" "" "@DEF@" +.sM +.FD 0 +XChangeGC\^(\^\fIdisplay\fP, \fIgc\fP\^, \fIvaluemask\fP\^, \fIvalues\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + GC \fIgc\fP\^; +.br + unsigned long \fIvaluemask\fP\^; +.br + XGCValues *\^\fIvalues\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIgc\fP 1i +Specifies the GC. +.ds Vm changed using information in the specified values structure +.IP \fIvaluemask\fP 1i +Specifies which components in the GC are to be \*(Vm. +This argument is the bitwise inclusive OR of zero or more of the valid +GC component mask bits. +.IP \fIvalues\fP 1i +Specifies any values as specified by the valuemask. +.LP +.eM +The +.PN XChangeGC +function changes the components specified by valuemask for +the specified GC. +The values argument contains the values to be set. +The values and restrictions are the same as for +.PN XCreateGC . +Changing the clip-mask overrides any previous +.PN XSetClipRectangles +request on the context. +Changing the dash-offset or dash-list +overrides any previous +.PN XSetDashes +request on the context. +The order in which components are verified and altered is server dependent. +If an error is generated, a subset of the components may have been altered. +.LP +.PN XChangeGC +can generate +.PN BadAlloc , +.PN BadFont , +.PN BadGC , +.PN BadMatch , +.PN BadPixmap , +and +.PN BadValue +errors. +.LP +.sp +To obtain components of a given GC, use +.PN XGetGCValues . +.IN "XGetGCValues" "" "@DEF@" +.sM +.FD 0 +Status XGetGCValues\^(\^\fIdisplay\fP, \fIgc\fP, \fIvaluemask\fP, \ +\fIvalues_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + GC \fIgc\fP\^; +.br + unsigned long \fIvaluemask\fP\^; +.br + XGCValues *\fIvalues_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIgc\fP 1i +Specifies the GC. +.ds Vm returned in the values_return argument +.IP \fIvaluemask\fP 1i +Specifies which components in the GC are to be \*(Vm. +This argument is the bitwise inclusive OR of zero or more of the valid +GC component mask bits. +.IP \fIvalues_return\fP 1i +Returns the GC values in the specified +.PN XGCValues +structure. +.LP +.eM +The +.PN XGetGCValues +function returns the components specified by valuemask for the specified GC. +If the valuemask contains a valid set of GC mask bits +.Pn ( GCFunction , +.PN GCPlaneMask , +.PN GCForeground , +.PN GCBackground , +.PN GCLineWidth , +.PN GCLineStyle , +.PN GCCapStyle , +.PN GCJoinStyle , +.PN GCFillStyle , +.PN GCFillRule , +.PN GCTile , +.PN GCStipple , +.PN GCTileStipXOrigin , +.PN GCTileStipYOrigin , +.PN GCFont , +.PN GCSubwindowMode , +.PN GCGraphicsExposures , +.PN GCClipXOrigin , +.PN GCCLipYOrigin , +.PN GCDashOffset , +or +.PN GCArcMode ) +and no error occurs, +.PN XGetGCValues +sets the requested components in values_return and returns a nonzero status. +Otherwise, it returns a zero status. +Note that the clip-mask and dash-list (represented by the +.PN GCClipMask +and +.PN GCDashList +bits, respectively, in the valuemask) +cannot be requested. +Also note that an invalid resource ID (with one or more of the three +most significant bits set to 1) will be returned for +.PN GCFont , +.PN GCTile , +and +.PN GCStipple +if the component has never been explicitly set by the client. +.LP +.sp +To free a given GC, use +.PN XFreeGC . +.IN "XFreeGC" "" "@DEF@" +.sM +.FD 0 +XFreeGC\^(\^\fIdisplay\fP, \fIgc\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + GC \fIgc\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIgc\fP 1i +Specifies the GC. +.LP +.eM +The +.PN XFreeGC +function destroys the specified GC as well as all the associated storage. +.LP +.PN XFreeGC +can generate a +.PN BadGC +error. +.LP +.sp +To obtain the +.PN GContext +resource ID for a given GC, use +.PN XGContextFromGC . +.IN "XGContextFromGC" "" "@DEF@" +.sM +.FD 0 +GContext XGContextFromGC\^(\^\fIgc\fP\^) +.br + GC \fIgc\fP\^; +.FN +.ds Gc for which you want the resource ID +.IP \fIgc\fP 1i +Specifies the GC \*(Gc. +.LP +.eM +.sp +Xlib usually defers sending changes to the components of a GC to the server +until a graphics function is actually called with that GC. +This permits batching of component changes into a single server request. +In some circumstances, however, it may be necessary for the client +to explicitly force sending the changes to the server. +An example might be when a protocol extension uses the GC indirectly, +in such a way that the extension interface cannot know what GC will be used. +To force sending GC component changes, use +.PN XFlushGC . +.IN "XFlushGC" "" "@DEF@" +.sM +.FD 0 +void XFlushGC\^(\^\fIdisplay\fP, \fIgc\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + GC \fIgc\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIgc\fP 1i +Specifies the GC. +.LP +.eM +.NH 2 +Using Graphics Context Convenience Routines +.XS +\*(SN Using Graphics Context Convenience Routines +.XE +.LP +This section discusses how to set the: +.IP \(bu 5 +Foreground, background, plane mask, or function components +.IP \(bu 5 +Line attributes and dashes components +.IP \(bu 5 +Fill style and fill rule components +.IP \(bu 5 +Fill tile and stipple components +.IP \(bu 5 +Font component +.IP \(bu 5 +Clip region component +.IP \(bu 5 +Arc mode, subwindow mode, and graphics exposure components +.NH 3 +Setting the Foreground, Background, Function, or Plane Mask +.XS +\*(SN Setting the Foreground, Background, Function, or Plane Mask +.XE +.LP +To set the foreground, background, plane mask, and function components +for a given GC, use +.PN XSetState . +.IN "XSetState" "" "@DEF@" +.sM +.FD 0 +XSetState\^(\^\fIdisplay\fP, \fIgc\fP\^, \fIforeground\fP\^, \fIbackground\fP\^, \fIfunction\fP\^, \fIplane_mask\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + GC \fIgc\fP\^; +.br + unsigned long \fIforeground\fP\^, \fIbackground\fP\^; +.br + int \fIfunction\fP\^; +.br + unsigned long \fIplane_mask\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIgc\fP 1i +Specifies the GC. +.IP \fIforeground\fP 1i +Specifies the foreground you want to set for the specified GC. +.IP \fIbackground\fP 1i +Specifies the background you want to set for the specified GC. +.IP \fIfunction\fP 1i +Specifies the function you want to set for the specified GC. +.IP \fIplane_mask\fP 1i +Specifies the plane mask. +.\" *** JIM: NEED MORE INFO FOR THIS. *** +.LP +.eM +.PN XSetState +can generate +.PN BadAlloc , +.PN BadGC , +and +.PN BadValue +errors. +.LP +.sp +To set the foreground of a given GC, use +.PN XSetForeground . +.IN "XSetForeground" "" "@DEF@" +.sM +.FD 0 +XSetForeground\^(\^\fIdisplay\fP, \fIgc\fP\^, \fIforeground\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + GC \fIgc\fP\^; +.br + unsigned long \fIforeground\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIgc\fP 1i +Specifies the GC. +.IP \fIforeground\fP 1i +Specifies the foreground you want to set for the specified GC. +.LP +.eM +.PN XSetForeground +can generate +.PN BadAlloc +and +.PN BadGC +errors. +.LP +.sp +To set the background of a given GC, use +.PN XSetBackground . +.IN "XSetBackground" "" "@DEF@" +.sM +.FD 0 +XSetBackground\^(\^\fIdisplay\fP, \fIgc\fP\^, \fIbackground\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + GC \fIgc\fP\^; +.br + unsigned long \fIbackground\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIgc\fP 1i +Specifies the GC. +.IP \fIbackground\fP 1i +Specifies the background you want to set for the specified GC. +.LP +.eM +.PN XSetBackground +can generate +.PN BadAlloc +and +.PN BadGC +errors. +.LP +.sp +To set the display function in a given GC, use +.PN XSetFunction . +.IN "XSetFunction" "" "@DEF@" +.sM +.FD 0 +XSetFunction\^(\^\fIdisplay\fP, \fIgc\fP\^, \fIfunction\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + GC \fIgc\fP\^; +.br + int \fIfunction\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIgc\fP 1i +Specifies the GC. +.IP \fIfunction\fP 1i +Specifies the function you want to set for the specified GC. +.LP +.eM +.PN XSetFunction +can generate +.PN BadAlloc , +.PN BadGC , +and +.PN BadValue +errors. +.LP +.sp +To set the plane mask of a given GC, use +.PN XSetPlaneMask . +.IN "XSetPlaneMask" "" "@DEF@" +.sM +.FD 0 +XSetPlaneMask\^(\^\fIdisplay\fP, \fIgc\fP\^, \fIplane_mask\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + GC \fIgc\fP\^; +.br + unsigned long \fIplane_mask\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIgc\fP 1i +Specifies the GC. +.IP \fIplane_mask\fP 1i +Specifies the plane mask. +.\" *** JIM: NEED MORE INFO FOR THIS. *** +.LP +.eM +.PN XSetPlaneMask +can generate +.PN BadAlloc +and +.PN BadGC +errors. +.NH 3 +Setting the Line Attributes and Dashes +.XS +\*(SN Setting the Line Attributes and Dashes +.XE +.LP +To set the line drawing components of a given GC, use +.PN XSetLineAttributes . +.IN "XSetLineAttributes" "" "@DEF@" +.sM +.FD 0 +XSetLineAttributes\^(\^\fIdisplay\fP, \fIgc\fP\^, \fIline_width\fP\^, \fIline_style\fP\^, \fIcap_style\fP\^, \fIjoin_style\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + GC \fIgc\fP\^; +.br + unsigned int \fIline_width\fP\^; +.br + int \fIline_style\fP\^; +.br + int \fIcap_style\fP\^; +.br + int \fIjoin_style\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIgc\fP 1i +Specifies the GC. +.IP \fIline_width\fP 1i +Specifies the line-width you want to set for the specified GC. +.IP \fIline_style\fP 1i +Specifies the line-style you want to set for the specified GC. +You can pass +.PN LineSolid , +.PN LineOnOffDash , +or +.PN LineDoubleDash . +.IP \fIcap_style\fP 1i +Specifies the line-style and cap-style you want to set for the specified GC. +You can pass +.PN CapNotLast , +.PN CapButt , +.PN CapRound , +or +.PN CapProjecting . +.IP \fIjoin_style\fP 1i +Specifies the line join-style you want to set for the specified GC. +You can pass +.PN JoinMiter , +.PN JoinRound , +or +.PN JoinBevel . +.LP +.eM +.PN XSetLineAttributes +can generate +.PN BadAlloc , +.PN BadGC , +and +.PN BadValue +errors. +.LP +.sp +To set the dash-offset and dash-list for dashed line styles of a given GC, use +.PN XSetDashes . +.IN "XSetDashes" "" "@DEF@" +.sM +.FD 0 +XSetDashes\^(\^\fIdisplay\fP, \fIgc\fP\^, \fIdash_offset\fP\^, \fIdash_list\fP\^, \fIn\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + GC \fIgc\fP\^; +.br + int \fIdash_offset\fP\^; +.br + char \fIdash_list\fP[]\^; +.br + int \fIn\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIgc\fP 1i +Specifies the GC. +.IP \fIdash_offset\fP 1i +Specifies the phase of the pattern for the dashed line-style you want to set +for the specified GC. +.IP \fIdash_list\fP 1i +Specifies the dash-list for the dashed line-style +you want to set for the specified GC. +.IP \fIn\fP 1i +Specifies the number of elements in dash_list. +.LP +.eM +The +.PN XSetDashes +function sets the dash-offset and dash-list attributes for dashed line styles +in the specified GC. +There must be at least one element in the specified dash_list, +or a +.PN BadValue +error results. +The initial and alternating elements (second, fourth, and so on) +of the dash_list are the even dashes, and +the others are the odd dashes. +Each element specifies a dash length in pixels. +All of the elements must be nonzero, +or a +.PN BadValue +error results. +Specifying an odd-length list is equivalent to specifying the same list +concatenated with itself to produce an even-length list. +.LP +The dash-offset defines the phase of the pattern, +specifying how many pixels into the dash-list the pattern +should actually begin in any single graphics request. +Dashing is continuous through path elements combined with a join-style +but is reset to the dash-offset between each sequence of joined lines. +.LP +The unit of measure for dashes is the same for the ordinary coordinate system. +Ideally, a dash length is measured along the slope of the line, but implementations +are only required to match this ideal for horizontal and vertical lines. +Failing the ideal semantics, it is suggested that the length be measured along the +major axis of the line. +The major axis is defined as the x axis for lines drawn at an angle of between +\-45 and +45 degrees or between 135 and 225 degrees from the x axis. +For all other lines, the major axis is the y axis. +.LP +.PN XSetDashes +can generate +.PN BadAlloc , +.PN BadGC , +and +.PN BadValue +errors. +.NH 3 +Setting the Fill Style and Fill Rule +.XS +\*(SN Setting the Fill Style and Fill Rule +.XE +.LP +To set the fill-style of a given GC, use +.PN XSetFillStyle . +.IN "XSetFillStyle" "" "@DEF@" +.sM +.FD 0 +XSetFillStyle\^(\^\fIdisplay\fP, \fIgc\fP\^, \fIfill_style\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + GC \fIgc\fP\^; +.br + int \fIfill_style\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIgc\fP 1i +Specifies the GC. +.IP \fIfill_style\fP 1i +Specifies the fill-style you want to set for the specified GC. +You can pass +.PN FillSolid , +.PN FillTiled , +.PN FillStippled , +or +.PN FillOpaqueStippled . +.LP +.eM +.PN XSetFillStyle +can generate +.PN BadAlloc , +.PN BadGC , +and +.PN BadValue +errors. +.LP +.sp +To set the fill-rule of a given GC, use +.PN XSetFillRule . +.IN "XSetFillRule" "" "@DEF@" +.sM +.FD 0 +XSetFillRule\^(\^\fIdisplay\fP, \fIgc\fP\^, \fIfill_rule\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + GC \fIgc\fP\^; +.br + int \fIfill_rule\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIgc\fP 1i +Specifies the GC. +.IP \fIfill_rule\fP 1i +Specifies the fill-rule you want to set for the specified GC. +You can pass +.PN EvenOddRule +or +.PN WindingRule . +.LP +.eM +.PN XSetFillRule +can generate +.PN BadAlloc , +.PN BadGC , +and +.PN BadValue +errors. +.NH 3 +Setting the Fill Tile and Stipple +.XS +\*(SN Setting the Fill Tile and Stipple +.XE +.LP +Some displays have hardware support for tiling or +stippling with patterns of specific sizes. +Tiling and stippling operations that restrict themselves to those specific +sizes run much faster than such operations with arbitrary size patterns. +Xlib provides functions that you can use to determine the best size, +tile, or stipple for the display +as well as to set the tile or stipple shape and the tile or stipple origin. +.LP +.sp +To obtain the best size of a tile, stipple, or cursor, use +.PN XQueryBestSize . +.IN "XQueryBestSize" "" "@DEF@" +.sM +.FD 0 +Status XQueryBestSize\^(\^\fIdisplay\fP, \fIclass\fP, \fIwhich_screen\fP, \fIwidth\fP, \fIheight\fP, \fIwidth_return\fP, \fIheight_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + int \fIclass\fP\^; +.br + Drawable \fIwhich_screen\fP\^; +.br + unsigned int \fIwidth\fP, \fIheight\fP\^; +.br + unsigned int *\fIwidth_return\fP, *\fIheight_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIclass\fP 1i +Specifies the class that you are interested in. +You can pass +.PN TileShape , +.PN CursorShape , +or +.PN StippleShape . +.IP \fIwhich_screen\fP 1i +Specifies any drawable on the screen. +.IP \fIwidth\fP 1i +.br +.ns +.IP \fIheight\fP 1i +Specify the width and height. +.IP \fIwidth_return\fP 1i +.br +.ns +.IP \fIheight_return\fP 1i +Return the width and height of the object best supported +by the display hardware. +.LP +.eM +The +.PN XQueryBestSize +function returns the best or closest size to the specified size. +For +.PN CursorShape , +this is the largest size that can be fully displayed on the screen specified by +which_screen. +For +.PN TileShape , +this is the size that can be tiled fastest. +For +.PN StippleShape , +this is the size that can be stippled fastest. +For +.PN CursorShape , +the drawable indicates the desired screen. +For +.PN TileShape +and +.PN StippleShape , +the drawable indicates the screen and possibly the window class and depth. +An +.PN InputOnly +window cannot be used as the drawable for +.PN TileShape +or +.PN StippleShape , +or a +.PN BadMatch +error results. +.LP +.PN XQueryBestSize +can generate +.PN BadDrawable , +.PN BadMatch , +and +.PN BadValue +errors. +.LP +.sp +To obtain the best fill tile shape, use +.PN XQueryBestTile . +.IN "XQueryBestTile" "" "@DEF@" +.sM +.FD 0 +Status XQueryBestTile\^(\^\fIdisplay\fP, \fIwhich_screen\fP, \fIwidth\fP, \fIheight\fP, \fIwidth_return\fP, \fIheight_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Drawable \fIwhich_screen\fP\^; +.br + unsigned int \fIwidth\fP, \fIheight\fP\^; +.br + unsigned int *\fIwidth_return\fP, *\fIheight_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIwhich_screen\fP 1i +Specifies any drawable on the screen. +.IP \fIwidth\fP 1i +.br +.ns +.IP \fIheight\fP 1i +Specify the width and height. +.IP \fIwidth_return\fP 1i +.br +.ns +.IP \fIheight_return\fP 1i +Return the width and height of the object best supported +by the display hardware. +.LP +.eM +The +.PN XQueryBestTile +function returns the best or closest size, that is, the size that can be +tiled fastest on the screen specified by which_screen. +The drawable indicates the screen and possibly the window class and depth. +If an +.PN InputOnly +window is used as the drawable, a +.PN BadMatch +error results. +.LP +.PN XQueryBestTile +can generate +.PN BadDrawable +and +.PN BadMatch +errors. +.LP +.sp +To obtain the best stipple shape, use +.PN XQueryBestStipple . +.IN "XQueryBestStipple" "" "@DEF@" +.sM +.FD 0 +Status XQueryBestStipple\^(\^\fIdisplay\fP, \fIwhich_screen\fP, \fIwidth\fP, \fIheight\fP, \fIwidth_return\fP, \fIheight_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Drawable \fIwhich_screen\fP\^; +.br + unsigned int \fIwidth\fP, \fIheight\fP\^; +.br + unsigned int *\fIwidth_return\fP, *\fIheight_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIwhich_screen\fP 1i +Specifies any drawable on the screen. +.IP \fIwidth\fP 1i +.br +.ns +.IP \fIheight\fP 1i +Specify the width and height. +.IP \fIwidth_return\fP 1i +.br +.ns +.IP \fIheight_return\fP 1i +Return the width and height of the object best supported +by the display hardware. +.LP +.eM +The +.PN XQueryBestStipple +function returns the best or closest size, that is, the size that can be +stippled fastest on the screen specified by which_screen. +The drawable indicates the screen and possibly the window class and depth. +If an +.PN InputOnly +window is used as the drawable, a +.PN BadMatch +error results. +.LP +.PN XQueryBestStipple +can generate +.PN BadDrawable +and +.PN BadMatch +errors. +.LP +.sp +To set the fill tile of a given GC, use +.PN XSetTile . +.IN "XSetTile" "" "@DEF@" +.sM +.FD 0 +XSetTile\^(\^\fIdisplay\fP, \fIgc\fP\^, \fItile\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + GC \fIgc\fP\^; +.br + Pixmap \fItile\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIgc\fP 1i +Specifies the GC. +.IP \fItile\fP 1i +Specifies the fill tile you want to set for the specified GC. +.LP +.eM +The tile and GC must have the same depth, +or a +.PN BadMatch +error results. +.LP +.PN XSetTile +can generate +.PN BadAlloc , +.PN BadGC , +.PN BadMatch , +and +.PN BadPixmap +errors. +.LP +.sp +To set the stipple of a given GC, use +.PN XSetStipple . +.IN "XSetStipple" "" "@DEF@" +.sM +.FD 0 +XSetStipple\^(\^\fIdisplay\fP, \fIgc\fP\^, \fIstipple\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + GC \fIgc\fP\^; +.br + Pixmap \fIstipple\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIgc\fP 1i +Specifies the GC. +.IP \fIstipple\fP 1i +Specifies the stipple you want to set for the specified GC. +.LP +.eM +The stipple must have a depth of one, +or a +.PN BadMatch +error results. +.LP +.PN XSetStipple +can generate +.PN BadAlloc , +.PN BadGC , +.PN BadMatch , +and +.PN BadPixmap +errors. +.LP +.sp +To set the tile or stipple origin of a given GC, use +.PN XSetTSOrigin . +.IN "XSetTSOrigin" "" "@DEF@" +.sM +.FD 0 +XSetTSOrigin\^(\^\fIdisplay\fP, \fIgc\fP\^, \fIts_x_origin\fP\^, \fIts_y_origin\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + GC \fIgc\fP\^; +.br + int \fIts_x_origin\fP\^, \fIts_y_origin\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIgc\fP 1i +Specifies the GC. +.IP \fIts_x_origin\fP 1i +.br +.ns +.IP \fIts_y_origin\fP 1i +Specify the x and y coordinates of the tile and stipple origin. +.LP +.eM +When graphics requests call for tiling or stippling, +the parent's origin will be interpreted relative to whatever destination +drawable is specified in the graphics request. +.LP +.PN XSetTSOrigin +can generate +.PN BadAlloc +and +.PN BadGC +errors. +.NH 3 +Setting the Current Font +.XS +\*(SN Setting the Current Font +.XE +.LP +To set the current font of a given GC, use +.PN XSetFont . +.IN "XSetFont" "" "@DEF@" +.sM +.FD 0 +XSetFont\^(\^\fIdisplay\fP, \fIgc\fP\^, \fIfont\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + GC \fIgc\fP\^; +.br + Font \fIfont\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIgc\fP 1i +Specifies the GC. +.IP \fIfont\fP 1i +Specifies the font. +.LP +.eM +.PN XSetFont +can generate +.PN BadAlloc , +.PN BadFont , +and +.PN BadGC +errors. +.NH 3 +Setting the Clip Region +.XS +\*(SN Setting the Clip Region +.XE +.LP +Xlib provides functions that you can use to set the clip-origin +and the clip-mask or set the clip-mask to a list of rectangles. +.LP +.sp +To set the clip-origin of a given GC, use +.PN XSetClipOrigin . +.IN "XSetClipOrigin" "" "@DEF@" +.sM +.FD 0 +XSetClipOrigin\^(\^\fIdisplay\fP, \fIgc\fP\^, \fIclip_x_origin\fP\^, \fIclip_y_origin\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + GC \fIgc\fP\^; +.br + int \fIclip_x_origin\fP\^, \fIclip_y_origin\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIgc\fP 1i +Specifies the GC. +.IP \fIclip_x_origin\fP 1i +.br +.ns +.IP \fIclip_y_origin\fP 1i +Specify the x and y coordinates of the clip-mask origin. +.LP +.eM +The clip-mask origin is interpreted relative to the origin of whatever +destination drawable is specified in the graphics request. +.LP +.PN XSetClipOrigin +can generate +.PN BadAlloc +and +.PN BadGC +errors. +.LP +.sp +To set the clip-mask of a given GC to the specified pixmap, use +.PN XSetClipMask . +.IN "XSetClipMask" "" "@DEF@" +.sM +.FD 0 +XSetClipMask\^(\^\fIdisplay\fP, \fIgc\fP, \fIpixmap\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + GC \fIgc\fP\^; +.br + Pixmap \fIpixmap\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIgc\fP 1i +Specifies the GC. +.IP \fIpixmap\fP 1i +Specifies the pixmap or +.PN None . +.LP +.eM +If the clip-mask is set to +.PN None , +the pixels are always drawn (regardless of the clip-origin). +.LP +.PN XSetClipMask +can generate +.PN BadAlloc , +.PN BadGC , +.PN BadMatch , +and +.PN BadPixmap +errors. +.LP +.sp +To set the clip-mask of a given GC to the specified list of rectangles, use +.PN XSetClipRectangles . +.IN "XSetClipRectangles" "" "@DEF@" +.sM +.FD 0 +XSetClipRectangles\^(\^\fIdisplay\fP, \fIgc\fP\^, \fIclip_x_origin\fP\^, \fIclip_y_origin\fP\^, \fIrectangles\fP\^, \fIn\fP\^, \fIordering\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + GC \fIgc\fP\^; +.br + int \fIclip_x_origin\fP\^, \fIclip_y_origin\fP\^; +.br + XRectangle \fIrectangles\fP[]\^; +.br + int \fIn\fP\^; +.br + int \fIordering\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIgc\fP 1i +Specifies the GC. +.IP \fIclip_x_origin\fP 1i +.br +.ns +.IP \fIclip_y_origin\fP 1i +Specify the x and y coordinates of the clip-mask origin. +.IP \fIrectangles\fP 1i +Specifies an array of rectangles that define the clip-mask. +.IP \fIn\fP 1i +Specifies the number of rectangles. +.IP \fIordering\fP 1i +Specifies the ordering relations on the rectangles. +You can pass +.PN Unsorted , +.PN YSorted , +.PN YXSorted , +or +.PN YXBanded . +.LP +.eM +The +.PN XSetClipRectangles +function changes the clip-mask in the specified GC +to the specified list of rectangles and sets the clip origin. +The output is clipped to remain contained within the +rectangles. +The clip-origin is interpreted relative to the origin of +whatever destination drawable is specified in a graphics request. +The rectangle coordinates are interpreted relative to the clip-origin. +The rectangles should be nonintersecting, or the graphics results will be +undefined. +Note that the list of rectangles can be empty, +which effectively disables output. +This is the opposite of passing +.PN None +as the clip-mask in +.PN XCreateGC , +.PN XChangeGC , +and +.PN XSetClipMask . +.LP +If known by the client, ordering relations on the rectangles can be +specified with the ordering argument. +This may provide faster operation +by the server. +If an incorrect ordering is specified, the X server may generate a +.PN BadMatch +error, but it is not required to do so. +If no error is generated, the graphics +results are undefined. +.PN Unsorted +means the rectangles are in arbitrary order. +.PN YSorted +means that the rectangles are nondecreasing in their Y origin. +.PN YXSorted +additionally constrains +.PN YSorted +order in that all +rectangles with an equal Y origin are nondecreasing in their X +origin. +.PN YXBanded +additionally constrains +.PN YXSorted +by requiring that, +for every possible Y scanline, all rectangles that include that +scanline have an identical Y origins and Y extents. +.LP +.PN XSetClipRectangles +can generate +.PN BadAlloc , +.PN BadGC , +.PN BadMatch , +and +.PN BadValue +errors. +.LP +Xlib provides a set of basic functions for performing +region arithmetic. +For information about these functions, +see section 16.5. +.NH 3 +Setting the Arc Mode, Subwindow Mode, and Graphics Exposure +.XS +\*(SN Setting the Arc Mode, Subwindow Mode, and Graphics Exposure +.XE +.LP +To set the arc mode of a given GC, use +.PN XSetArcMode . +.IN "XSetArcMode" "" "@DEF@" +.sM +.FD 0 +XSetArcMode\^(\^\fIdisplay\fP, \fIgc\fP\^, \fIarc_mode\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + GC \fIgc\fP\^; +.br + int \fIarc_mode\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIgc\fP 1i +Specifies the GC. +.IP \fIarc_mode\fP 1i +Specifies the arc mode. +You can pass +.PN ArcChord +or +.PN ArcPieSlice . +.LP +.eM +.PN XSetArcMode +can generate +.PN BadAlloc , +.PN BadGC , +and +.PN BadValue +errors. +.LP +.sp +To set the subwindow mode of a given GC, use +.PN XSetSubwindowMode . +.IN "XSetSubwindowMode" "" "@DEF@" +.sM +.FD 0 +XSetSubwindowMode\^(\^\fIdisplay\fP, \fIgc\fP\^, \fIsubwindow_mode\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + GC \fIgc\fP\^; +.br + int \fIsubwindow_mode\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIgc\fP 1i +Specifies the GC. +.IP \fIsubwindow_mode\fP 1i +Specifies the subwindow mode. +You can pass +.PN ClipByChildren +or +.PN IncludeInferiors . +.LP +.eM +.PN XSetSubwindowMode +can generate +.PN BadAlloc , +.PN BadGC , +and +.PN BadValue +errors. +.LP +.sp +To set the graphics-exposures flag of a given GC, use +.PN XSetGraphicsExposures . +.IN "XSetGraphicsExposures" "" "@DEF@" +.sM +.FD 0 +XSetGraphicsExposures\^(\^\fIdisplay\fP, \fIgc\fP\^, \fIgraphics_exposures\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + GC \fIgc\fP\^; +.br + Bool \fIgraphics_exposures\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIgc\fP 1i +Specifies the GC. +.IP \fIgraphics_exposures\fP 1i +Specifies a Boolean value that indicates whether you want +.PN GraphicsExpose +and +.PN NoExpose +events to be reported when calling +.PN XCopyArea +and +.PN XCopyPlane +with this GC. +.LP +.eM +.PN XSetGraphicsExposures +can generate +.PN BadAlloc , +.PN BadGC , +and +.PN BadValue +errors. +.bp diff --git a/libX11/specs/libX11/CH08 b/libX11/specs/libX11/CH08 new file mode 100644 index 000000000..3d2161fb2 --- /dev/null +++ b/libX11/specs/libX11/CH08 @@ -0,0 +1,3468 @@ +.\" Copyright \(co 1985, 1986, 1987, 1988, 1989, 1990, 1991, 1994, 1996 X Consortium +.\" +.\" 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 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 X CONSORTIUM 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 X Consortium 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 X Consortium. +.\" +.\" Copyright \(co 1985, 1986, 1987, 1988, 1989, 1990, 1991 by +.\" Digital Equipment Corporation +.\" +.\" Portions Copyright \(co 1990, 1991 by +.\" Tektronix, Inc. +.\" +.\" Permission to use, copy, modify and distribute this documentation for +.\" any purpose and without fee is hereby granted, provided that the above +.\" copyright notice appears in all copies and that both that copyright notice +.\" and this permission notice appear in all copies, and that the names of +.\" Digital and Tektronix not be used in in advertising or publicity pertaining +.\" to this documentation without specific, written prior permission. +.\" Digital and Tektronix makes no representations about the suitability +.\" of this documentation for any purpose. +.\" It is provided ``as is'' without express or implied warranty. +.\" +\& +.sp 1 +.ce 3 +\s+1\fBChapter 8\fP\s-1 + +\s+1\fBGraphics Functions\fP\s-1 +.sp 2 +.nr H1 8 +.nr H2 0 +.nr H3 0 +.nr H4 0 +.nr H5 0 +.na +.LP +.XS +Chapter 8: Graphics Functions +.XE +Once you have established a connection to a display, +you can use the Xlib graphics functions to: +.IP \(bu 5 +Clear and copy areas +.IP \(bu 5 +Draw points, lines, rectangles, and arcs +.IP \(bu 5 +Fill areas +.IP \(bu 5 +Manipulate fonts +.IP \(bu 5 +Draw text +.IP \(bu 5 +Transfer images between clients and the server +.LP +If the same drawable and GC is used for each call, +Xlib batches back-to-back calls to +.PN XDrawPoint , +.PN XDrawLine , +.PN XDrawRectangle , +.PN XFillArc , +and +.PN XFillRectangle . +Note that this reduces the total number of requests sent to the server. +.NH 2 +Clearing Areas +.XS +\*(SN Clearing Areas +.XE +.LP +Xlib provides functions that you can use to clear an area or the entire window. +Because pixmaps do not have defined backgrounds, +they cannot be filled by using the functions described in this section. +Instead, to accomplish an analogous operation on a pixmap, +you should use +.PN XFillRectangle , +which sets the pixmap to a known value. +.LP +.sp +To clear a rectangular area of a given window, use +.PN XClearArea . +.IN "Areas" "clearing" +.IN "Clearing" "areas" +.IN "XClearArea" "" "@DEF@" +.sM +.FD 0 +XClearArea\^(\^\fIdisplay\fP, \fIw\fP\^, \fIx\fP\^, \fIy\fP\^, \fIwidth\fP\^, \fIheight\fP\^, \fIexposures\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + int \fIx\fP\^, \fIy\fP\^; +.br + unsigned int \fIwidth\fP\^, \fIheight\fP\^; +.br + Bool \fIexposures\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.ds Xy , which are relative to the origin of the window \ +and specify the upper-left corner of the rectangle +.IP \fIx\fP 1i +.br +.ns +.IP \fIy\fP 1i +Specify the x and y coordinates\*(Xy. +.ds Wh , which are the dimensions of the rectangle +.IP \fIwidth\fP 1i +.br +.ns +.IP \fIheight\fP 1i +Specify the width and height\*(Wh. +.IP \fIexposures\fP 1i +Specifies a Boolean value that indicates if +.PN Expose +events are to be generated. +.LP +.eM +The +.PN XClearArea +function paints a rectangular area in the specified window according to the +specified dimensions with the window's background pixel or pixmap. +The subwindow-mode effectively is +.PN ClipByChildren . +If width is zero, it +is replaced with the current width of the window minus x. +If height is +zero, it is replaced with the current height of the window minus y. +If the window has a defined background tile, +the rectangle clipped by any children is filled with this tile. +If the window has +background +.PN None , +the contents of the window are not changed. +In either +case, if exposures is +.PN True , +one or more +.PN Expose +events are generated for regions of the rectangle that are either visible or are +being retained in a backing store. +If you specify a window whose class is +.PN InputOnly , +a +.PN BadMatch +error results. +.LP +.PN XClearArea +can generate +.PN BadMatch , +.PN BadValue , +and +.PN BadWindow +errors. +.LP +.sp +To clear the entire area in a given window, use +.PN XClearWindow . +.IN "Window" "clearing" +.IN "Clearing" "windows" +.IN "XClearWindow" "" "@DEF@" +.sM +.FD 0 +XClearWindow\^(\^\fIdisplay\fP, \fIw\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.LP +.eM +The +.PN XClearWindow +function clears the entire area in the specified window and is +equivalent to +.PN XClearArea +(display, w, 0, 0, 0, 0, +.PN False ). +If the window has a defined background tile, the rectangle is tiled with a +plane-mask of all ones and +.PN GXcopy +function. +If the window has +background +.PN None , +the contents of the window are not changed. +If you specify a window whose class is +.PN InputOnly , +a +.PN BadMatch +error results. +.LP +.PN XClearWindow +can generate +.PN BadMatch +and +.PN BadWindow +errors. +.NH 2 +Copying Areas +.XS +\*(SN Copying Areas +.XE +.LP +Xlib provides functions that you can use to copy an area or a bit plane. +.LP +.sp +To copy an area between drawables of the same +root and depth, use +.PN XCopyArea . +.IN "Areas" "copying" +.IN "Copying" "areas" +.IN "XCopyArea" "" "@DEF@" +.sM +.FD 0 +XCopyArea\^(\^\fIdisplay\fP, \fIsrc\fP\^, \fIdest\fP\^, \fIgc\fP\^, \fIsrc_x\fP\^, \fIsrc_y\fP\^, \fIwidth\fP\^, \fIheight\fP\^, \fIdest_x\fP\^, \fIdest_y\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Drawable \fIsrc\fP\^, \fIdest\fP\^; +.br + GC \fIgc\fP\^; +.br + int \fIsrc_x\fP\^, \fIsrc_y\fP\^; +.br + unsigned int \fIwidth\fP\^, \fIheight\fP\^; +.br + int \fIdest_x\fP\^, \fIdest_y\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIsrc\fP 1i +.br +.ns +.IP \fIdest\fP 1i +Specify the source and destination rectangles to be combined. +.IP \fIgc\fP 1i +Specifies the GC. +.IP \fIsrc_x\fP 1i +.br +.ns +.IP \fIsrc_y\fP 1i +Specify the x and y coordinates, +which are relative to the origin of the source rectangle +and specify its upper-left corner. +.ds Wh , which are the dimensions of both the source \ +and destination rectangles +.IP \fIwidth\fP 1i +.br +.ns +.IP \fIheight\fP 1i +Specify the width and height\*(Wh. +.ds Dx , which are relative to the origin of the destination rectangle \ +and specify its upper-left corner +.IP \fIdest_x\fP 1i +.br +.ns +.IP \fIdest_y\fP 1i +Specify the x and y coordinates\*(Dx. +.LP +.eM +The +.PN XCopyArea +function combines the specified rectangle of src with the specified rectangle +of dest. +The drawables must have the same root and depth, +or a +.PN BadMatch +error results. +.LP +If regions of the source rectangle are obscured and have not been +retained in backing store +or if regions outside the boundaries of the source drawable are specified, +those regions are not copied. +Instead, the +following occurs on all corresponding destination regions that are either +visible or are retained in backing store. +If the destination is a window with a background other than +.PN None , +corresponding regions +of the destination are tiled with that background +(with plane-mask of all ones and +.PN GXcopy +function). +Regardless of tiling or whether the destination is a window or a pixmap, +if graphics-exposures is +.PN True , +then +.PN GraphicsExpose +events for all corresponding destination regions are generated. +If graphics-exposures is +.PN True +but no +.PN GraphicsExpose +events are generated, a +.PN NoExpose +event is generated. +Note that by default graphics-exposures is +.PN True +in new GCs. +.LP +This function uses these GC components: function, plane-mask, +subwindow-mode, graphics-exposures, clip-x-origin, +clip-y-origin, and clip-mask. +.LP +.PN XCopyArea +can generate +.PN BadDrawable , +.PN BadGC , +and +.PN BadMatch +errors. +.sp +.LP +To copy a single bit plane of a given drawable, use +.PN XCopyPlane . +.IN "Plane" "copying" +.IN "Copying" "planes" +.IN "XCopyPlane" "" "@DEF@" +.sM +.FD 0 +XCopyPlane\^(\^\fIdisplay\fP, \fIsrc\fP\^, \fIdest\fP\^, \fIgc\fP\^, \fIsrc_x\fP\^, \fIsrc_y\fP\^, \fIwidth\fP\^, \fIheight\fP\^, \fIdest_x\fP\^, \fIdest_y\fP\^, \fIplane\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Drawable \fIsrc\fP\^, \fIdest\fP\^; +.br + GC \fIgc\fP\^; +.br + int \fIsrc_x\fP\^, \fIsrc_y\fP\^; +.br + unsigned int \fIwidth\fP\^, \fIheight\fP\^; +.br + int \fIdest_x\fP\^, \fIdest_y\fP\^; +.br + unsigned long \fIplane\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIsrc\fP 1i +.br +.ns +.IP \fIdest\fP 1i +Specify the source and destination rectangles to be combined. +.IP \fIgc\fP 1i +Specifies the GC. +.IP \fIsrc_x\fP 1i +.br +.ns +.IP \fIsrc_y\fP 1i +Specify the x and y coordinates, +which are relative to the origin of the source rectangle +and specify its upper-left corner. +.ds Wh , which are the dimensions of both the source and destination rectangles +.IP \fIwidth\fP 1i +.br +.ns +.IP \fIheight\fP 1i +Specify the width and height\*(Wh. +.ds Dx , which are relative to the origin of the destination rectangle \ +and specify its upper-left corner +.IP \fIdest_x\fP 1i +.br +.ns +.IP \fIdest_y\fP 1i +Specify the x and y coordinates\*(Dx. +.IP \fIplane\fP 1i +Specifies the bit plane. +You must set exactly one bit to 1. +.LP +.eM +The +.PN XCopyPlane +function uses a single bit plane of the specified source rectangle +combined with the specified GC to modify the specified rectangle of dest. +The drawables must have the same root but need not have the same depth. +If the drawables do not have the same root, a +.PN BadMatch +error results. +If plane does not have exactly one bit set to 1 and the value of plane +is not less than %2 sup n%, where \fIn\fP is the depth of src, a +.PN BadValue +error results. +.LP +Effectively, +.PN XCopyPlane +forms a pixmap of the same depth as the rectangle of dest and with a +size specified by the source region. +It uses the foreground/background pixels in the GC (foreground +everywhere the bit plane in src contains a bit set to 1, +background everywhere the bit plane in src contains a bit set to 0) +and the equivalent of a +.PN CopyArea +protocol request is performed with all the same exposure semantics. +This can also be thought of as using the specified region of the source +bit plane as a stipple with a fill-style of +.PN FillOpaqueStippled +for filling a rectangular area of the destination. +.LP +This function uses these GC components: function, plane-mask, foreground, +background, subwindow-mode, graphics-exposures, clip-x-origin, clip-y-origin, +and clip-mask. +.LP +.PN XCopyPlane +can generate +.PN BadDrawable , +.PN BadGC , +.PN BadMatch , +and +.PN BadValue +errors. +.NH 2 +Drawing Points, Lines, Rectangles, and Arcs +.XS +\*(SN Drawing Points, Lines, Rectangles, and Arcs +.XE +.LP +Xlib provides functions that you can use to draw: +.IP \(bu 5 +A single point or multiple points +.IP \(bu 5 +A single line or multiple lines +.IP \(bu 5 +A single rectangle or multiple rectangles +.IP \(bu 5 +A single arc or multiple arcs +.LP +Some of the functions described in the following sections +use these structures: +.LP +.IN "XSegment" "" "@DEF@" +.sM +.Ds 0 +.TA .5i +.ta .5i +typedef struct { + short x1, y1, x2, y2; +} XSegment; +.De +.LP +.eM +.IN "XPoint" "" "@DEF@" +.sM +.Ds 0 +.TA .5i +.ta .5i +typedef struct { + short x, y; +} XPoint; +.De +.LP +.eM +.IN "XRectangle" "" "@DEF@" +.sM +.Ds 0 +.TA .5i +.ta .5i +typedef struct { + short x, y; + unsigned short width, height; +} XRectangle; +.De +.LP +.eM +.IN "XArc" "" "@DEF@" +.sM +.Ds 0 +.TA .5i 3i +.ta .5i 3i +typedef struct { + short x, y; + unsigned short width, height; + short angle1, angle2; /* Degrees * 64 */ +} XArc; +.De +.LP +.eM +All x and y members are signed integers. +The width and height members are 16-bit unsigned integers. +You should be careful not to generate coordinates and sizes +out of the 16-bit ranges, because the protocol only has 16-bit fields +for these values. +.NH 3 +Drawing Single and Multiple Points +.XS +\*(SN Drawing Single and Multiple Points +.XE +.LP +.IN "Points" "drawing" +.IN "Drawing" "points" +.IN "XDrawPoints" +.IN "XDrawPoint" +.LP +To draw a single point in a given drawable, use +.PN XDrawPoint . +.IN "XDrawPoint" "" "@DEF@" +.sM +.FD 0 +XDrawPoint\^(\^\fIdisplay\fP, \fId\fP\^, \fIgc\fP\^, \fIx\fP\^, \fIy\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Drawable \fId\fP\^; +.br + GC \fIgc\fP\^; +.br + int \fIx\fP\^, \fIy\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fId\fP 1i +Specifies the drawable. +.IP \fIgc\fP 1i +Specifies the GC. +.IP \fIx\fP 1i +.br +.ns +.IP \fIy\fP 1i +Specify the x and y coordinates where you want the point drawn. +.LP +.eM +.sp +To draw multiple points in a given drawable, use +.PN XDrawPoints . +.IN "XDrawPoints" "" "@DEF@" +.sM +.FD 0 +XDrawPoints\^(\^\fIdisplay\fP, \fId\fP\^, \fIgc\fP\^, \fIpoints\fP\^, \fInpoints\fP\^, \fImode\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Drawable \fId\fP\^; +.br + GC \fIgc\fP\^; +.br + XPoint *\fIpoints\fP\^; +.br + int \fInpoints\fP\^; +.br + int \fImode\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fId\fP 1i +Specifies the drawable. +.IP \fIgc\fP 1i +Specifies the GC. +.IP \fIpoints\fP 1i +Specifies an array of points. +.IP \fInpoints\fP 1i +Specifies the number of points in the array. +.IP \fImode\fP 1i +Specifies the coordinate mode. +You can pass +.PN CoordModeOrigin +or +.PN CoordModePrevious . +.LP +.eM +The +.PN XDrawPoint +function uses the foreground pixel and function components of the +GC to draw a single point into the specified drawable; +.PN XDrawPoints +draws multiple points this way. +.PN CoordModeOrigin +treats all coordinates as relative to the origin, +and +.PN CoordModePrevious +treats all coordinates after the first as relative to the previous point. +.PN XDrawPoints +draws the points in the order listed in the array. +.LP +Both functions use these GC components: function, plane-mask, +foreground, subwindow-mode, clip-x-origin, clip-y-origin, and clip-mask. +.LP +.PN XDrawPoint +can generate +.PN BadDrawable , +.PN BadGC , +and +.PN BadMatch +errors. +.PN XDrawPoints +can generate +.PN BadDrawable , +.PN BadGC , +.PN BadMatch , +and +.PN BadValue +errors. +.NH 3 +Drawing Single and Multiple Lines +.XS +\*(SN Drawing Single and Multiple Lines +.XE +.LP +.IN "Lines" "drawing" +.IN "Drawing" "lines" +.IN "XDrawLine" +.IN "XDrawLines" +.IN "Polygons" "drawing" +.IN "Drawing" "polygons" +.IN "XDrawSegments" +.LP +To draw a single line between two points in a given drawable, use +.PN XDrawLine . +.IN "XDrawLine" "" "@DEF@" +.sM +.FD 0 +XDrawLine\^(\^\fIdisplay\fP, \fId\fP\^, \fIgc\fP\^, \fIx1\fP\^, \fIy1\fP\^, \fIx2\fP\^, \fIy2\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Drawable \fId\fP\^; +.br + GC \fIgc\fP\^; +.br + int \fIx1\fP\^, \fIy1\fP\^, \fIx2\fP\^, \fIy2\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fId\fP 1i +Specifies the drawable. +.IP \fIgc\fP 1i +Specifies the GC. +.IP \fIx1\fP 1i +.br +.ns +.IP \fIy1\fP 1i +.br +.ns +.IP \fIx2\fP 1i +.br +.ns +.IP \fIy2\fP 1i +Specify the points (x1, y1) and (x2, y2) to be connected. +.LP +.eM +.sp +To draw multiple lines in a given drawable, use +.PN XDrawLines . +.IN "XDrawLines" "" "@DEF@" +.sM +.FD 0 +XDrawLines\^(\^\fIdisplay\fP, \fId\fP\^, \fIgc\fP\^, \fIpoints\fP\^, \fInpoints\fP\^, \fImode\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Drawable \fId\fP\^; +.br + GC \fIgc\fP\^; +.br + XPoint *\fIpoints\fP\^; +.br + int \fInpoints\fP\^; +.br + int \fImode\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fId\fP 1i +Specifies the drawable. +.IP \fIgc\fP 1i +Specifies the GC. +.IP \fIpoints\fP 1i +Specifies an array of points. +.IP \fInpoints\fP 1i +Specifies the number of points in the array. +.IP \fImode\fP 1i +Specifies the coordinate mode. +You can pass +.PN CoordModeOrigin +or +.PN CoordModePrevious . +.LP +.eM +.sp +To draw multiple, unconnected lines in a given drawable, +use +.PN XDrawSegments . +.IN "XDrawSegments" "" "@DEF@" +.sM +.FD 0 +XDrawSegments\^(\^\fIdisplay\fP, \fId\fP\^, \fIgc\fP\^, \fIsegments\fP\^, \fInsegments\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Drawable \fId\fP\^; +.br + GC \fIgc\fP\^; +.br + XSegment *\fIsegments\fP\^; +.br + int \fInsegments\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fId\fP 1i +Specifies the drawable. +.IP \fIgc\fP 1i +Specifies the GC. +.IP \fIsegments\fP 1i +Specifies an array of segments. +.IP \fInsegments\fP 1i +Specifies the number of segments in the array. +.LP +.eM +The +.PN XDrawLine +function uses the components of the specified GC to +draw a line between the specified set of points (x1, y1) and (x2, y2). +It does not perform joining at coincident endpoints. +For any given line, +.PN XDrawLine +does not draw a pixel more than once. +If lines intersect, the intersecting pixels are drawn multiple times. +.LP +The +.PN XDrawLines +function uses the components of the specified GC to draw +npoints\-1 lines between each pair of points (point[i], point[i+1]) +in the array of +.PN XPoint +structures. +It draws the lines in the order listed in the array. +The lines join correctly at all intermediate points, and if the first and last +points coincide, the first and last lines also join correctly. +For any given line, +.PN XDrawLines +does not draw a pixel more than once. +If thin (zero line-width) lines intersect, +the intersecting pixels are drawn multiple times. +If wide lines intersect, the intersecting pixels are drawn only once, as though +the entire +.PN PolyLine +protocol request were a single, filled shape. +.PN CoordModeOrigin +treats all coordinates as relative to the origin, +and +.PN CoordModePrevious +treats all coordinates after the first as relative to the previous point. +.LP +The +.PN XDrawSegments +function draws multiple, unconnected lines. +For each segment, +.PN XDrawSegments +draws a +line between (x1, y1) and (x2, y2). +It draws the lines in the order listed in the array of +.PN XSegment +structures and does not perform joining at coincident endpoints. +For any given line, +.PN XDrawSegments +does not draw a pixel more than once. +If lines intersect, the intersecting pixels are drawn multiple times. +.LP +All three functions use these GC components: +function, plane-mask, line-width, +line-style, cap-style, fill-style, subwindow-mode, +clip-x-origin, clip-y-origin, and clip-mask. +The +.PN XDrawLines +function also uses the join-style GC component. +All three functions also use these GC mode-dependent components: +foreground, background, tile, stipple, tile-stipple-x-origin, +tile-stipple-y-origin, dash-offset, and dash-list. +.LP +.PN XDrawLine , +.PN XDrawLines , +and +.PN XDrawSegments +can generate +.PN BadDrawable , +.PN BadGC , +and +.PN BadMatch +errors. +.PN XDrawLines +also can generate +.PN BadValue +errors. +.NH 3 +Drawing Single and Multiple Rectangles +.XS +\*(SN Drawing Single and Multiple Rectangles +.XE +.LP +.IN "Rectangles" "drawing" +.IN "Drawing" "rectangles" +.IN "XDrawRectangle" +.IN "XDrawRectangles" +.LP +To draw the outline of a single rectangle in a given drawable, use +.PN XDrawRectangle . +.IN "XDrawRectangle" "" "@DEF@" +.sM +.FD 0 +XDrawRectangle\^(\^\fIdisplay\fP, \fId\fP\^, \fIgc\fP\^, \fIx\fP\^, \fIy\fP\^, \fIwidth\fP\^, \fIheight\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Drawable \fId\fP\^; +.br + GC \fIgc\fP\^; +.br + int \fIx\fP\^, \fIy\fP\^; +.br + unsigned int \fIwidth\fP\^, \fIheight\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fId\fP 1i +Specifies the drawable. +.IP \fIgc\fP 1i +Specifies the GC. +.ds Xy , which specify the upper-left corner of the rectangle +.IP \fIx\fP 1i +.br +.ns +.IP \fIy\fP 1i +Specify the x and y coordinates\*(Xy. +.ds Wh , which specify the dimensions of the rectangle +.IP \fIwidth\fP 1i +.br +.ns +.IP \fIheight\fP 1i +Specify the width and height\*(Wh. +.LP +.eM +.sp +To draw the outline of multiple rectangles +in a given drawable, use +.PN XDrawRectangles . +.IN "XDrawRectangles" "" "@DEF@" +.sM +.FD 0 +XDrawRectangles\^(\^\fIdisplay\fP, \fId\fP\^, \fIgc\fP\^, \fIrectangles\fP\^, \fInrectangles\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Drawable \fId\fP\^; +.br + GC \fIgc\fP\^; +.br + XRectangle \fIrectangles\fP\^[\^]\^; +.br + int \fInrectangles\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fId\fP 1i +Specifies the drawable. +.IP \fIgc\fP 1i +Specifies the GC. +.IP \fIrectangles\fP 1i +Specifies an array of rectangles. +.IP \fInrectangles\fP 1i +Specifies the number of rectangles in the array. +.LP +.eM +The +.PN XDrawRectangle +and +.PN XDrawRectangles +functions draw the outlines of the specified rectangle or rectangles as +if a five-point +.PN PolyLine +protocol request were specified for each rectangle: +.IP +[x,y] [x+width,y] [x+width,y+height] [x,y+height] [x,y] +.LP +For the specified rectangle or rectangles, +these functions do not draw a pixel more than once. +.PN XDrawRectangles +draws the rectangles in the order listed in the array. +If rectangles intersect, +the intersecting pixels are drawn multiple times. +.LP +Both functions use these GC components: +function, plane-mask, line-width, +line-style, cap-style, join-style, fill-style, +subwindow-mode, clip-x-origin, clip-y-origin, and clip-mask. +They also use these GC mode-dependent components: +foreground, background, tile, stipple, tile-stipple-x-origin, +tile-stipple-y-origin, dash-offset, and dash-list. +.LP +.PN XDrawRectangle +and +.PN XDrawRectangles +can generate +.PN BadDrawable , +.PN BadGC , +and +.PN BadMatch +errors. +.NH 3 +Drawing Single and Multiple Arcs +.XS +\*(SN Drawing Single and Multiple Arcs +.XE +.LP +.IN "Drawing" "arcs" +.IN "XDrawArc" +.IN "Arcs" "drawing" +.IN "XDrawArcs" +.LP +.sp +To draw a single arc in a given drawable, use +.PN XDrawArc . +.IN "XDrawArc" "" "@DEF@" +.sM +.FD 0 +XDrawArc\^(\^\fIdisplay\fP, \fId\fP\^, \fIgc\fP\^, \fIx\fP\^, \fIy\fP\^, \fIwidth\fP\^, \fIheight\fP\^, \fIangle1\fP\^, \fIangle2\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Drawable \fId\fP\^; +.br + GC \fIgc\fP\^; +.br + int \fIx\fP\^, \fIy\fP\^; +.br + unsigned int \fIwidth\fP\^, \fIheight\fP\^; +.br + int \fIangle1\fP\^, \fIangle2\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fId\fP 1i +Specifies the drawable. +.IP \fIgc\fP 1i +Specifies the GC. +.ds Xy , which are relative to the origin of the drawable \ +and specify the upper-left corner of the bounding rectangle +.IP \fIx\fP 1i +.br +.ns +.IP \fIy\fP 1i +Specify the x and y coordinates\*(Xy. +.ds Wh , which are the major and minor axes of the arc +.IP \fIwidth\fP 1i +.br +.ns +.IP \fIheight\fP 1i +Specify the width and height\*(Wh. +.IP \fIangle1\fP 1i +Specifies the start of the arc relative to the three-o'clock position +from the center, in units of degrees * 64. +.IP \fIangle2\fP 1i +Specifies the path and extent of the arc relative to the start of the +arc, in units of degrees * 64. +.LP +.eM +.sp +To draw multiple arcs in a given drawable, use +.PN XDrawArcs . +.IN "XDrawArcs" "" "@DEF@" +.sM +.FD 0 +XDrawArcs\^(\^\fIdisplay\fP, \fId\fP\^, \fIgc\fP\^, \fIarcs\fP\^, \fInarcs\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Drawable \fId\fP\^; +.br + GC \fIgc\fP\^; +.br + XArc *\fIarcs\fP\^; +.br + int \fInarcs\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fId\fP 1i +Specifies the drawable. +.IP \fIgc\fP 1i +Specifies the GC. +.IP \fIarcs\fP 1i +Specifies an array of arcs. +.IP \fInarcs\fP 1i +Specifies the number of arcs in the array. +.LP +.eM +.EQ +delim %% +.EN +.PN XDrawArc +draws a single circular or elliptical arc, and +.PN XDrawArcs +draws multiple circular or elliptical arcs. +Each arc is specified by a rectangle and two angles. +The center of the circle or ellipse is the center of the +rectangle, and the major and minor axes are specified by the width and height. +Positive angles indicate counterclockwise motion, +and negative angles indicate clockwise motion. +If the magnitude of angle2 is greater than 360 degrees, +.PN XDrawArc +or +.PN XDrawArcs +truncates it to 360 degrees. +.LP +For an arc specified as %[ ~x, ~y, ~width , ~height, ~angle1, ~angle2 ]%, +the origin of the major and minor axes is at +% [ x +^ {width over 2} , ~y +^ {height over 2} ]%, +and the infinitely thin path describing the entire circle or ellipse +intersects the horizontal axis at % [ x, ~y +^ {height over 2} ]% and +% [ x +^ width , ~y +^ { height over 2 }] % +and intersects the vertical axis at % [ x +^ { width over 2 } , ~y ]% and +% [ x +^ { width over 2 }, ~y +^ height ]%. +These coordinates can be fractional +and so are not truncated to discrete coordinates. +The path should be defined by the ideal mathematical path. +For a wide line with line-width lw, +the bounding outlines for filling are given +by the two infinitely thin paths consisting of all points whose perpendicular +distance from the path of the circle/ellipse is equal to lw/2 +(which may be a fractional value). +The cap-style and join-style are applied the same as for a line +corresponding to the tangent of the circle/ellipse at the endpoint. +.LP +For an arc specified as % [ ~x, ~y, ~width, ~height, ~angle1, ~angle2 ]%, +the angles must be specified +in the effectively skewed coordinate system of the ellipse (for a +circle, the angles and coordinate systems are identical). The +relationship between these angles and angles expressed in the normal +coordinate system of the screen (as measured with a protractor) is as +follows: +.LP +.Ds +% roman "skewed-angle" ~ = ~ atan left ( tan ( roman "normal-angle" ) + * width over height right ) +^ adjust% +.De +.LP +The skewed-angle and normal-angle are expressed in radians (rather +than in degrees scaled by 64) in the range % [ 0 , ~2 pi ]% and where atan +returns a value in the range % [ - pi over 2 , ~pi over 2 ] % +and adjust is: +.LP +.Ds +.TA 1i 2i +.ta 1i 2i +%0% for normal-angle in the range % [ 0 , ~pi over 2 ]% +%pi% for normal-angle in the range % [ pi over 2 , ~{3 pi} over 2 ]% +%2 pi% for normal-angle in the range % [ {3 pi} over 2 , ~2 pi ]% +.De +.LP +For any given arc, +.PN XDrawArc +and +.PN XDrawArcs +do not draw a pixel more than once. +If two arcs join correctly and if the line-width is greater than zero +and the arcs intersect, +.PN XDrawArc +and +.PN XDrawArcs +do not draw a pixel more than once. +Otherwise, +the intersecting pixels of intersecting arcs are drawn multiple times. +Specifying an arc with one endpoint and a clockwise extent draws the same pixels +as specifying the other endpoint and an equivalent counterclockwise extent, +except as it affects joins. +.LP +If the last point in one arc coincides with the first point in the following +arc, the two arcs will join correctly. +If the first point in the first arc coincides with the last point in the last +arc, the two arcs will join correctly. +By specifying one axis to be zero, a horizontal or vertical line can be +drawn. +Angles are computed based solely on the coordinate system and ignore the +aspect ratio. +.LP +Both functions use these GC components: +function, plane-mask, line-width, line-style, cap-style, join-style, +fill-style, subwindow-mode, clip-x-origin, clip-y-origin, and clip-mask. +They also use these GC mode-dependent components: +foreground, background, tile, stipple, tile-stipple-x-origin, +tile-stipple-y-origin, dash-offset, and dash-list. +.LP +.PN XDrawArc +and +.PN XDrawArcs +can generate +.PN BadDrawable , +.PN BadGC , +and +.PN BadMatch +errors. +.NH 2 +Filling Areas +.XS +\*(SN Filling Areas +.XE +.LP +Xlib provides functions that you can use to fill: +.IP \(bu 5 +A single rectangle or multiple rectangles +.IP \(bu 5 +A single polygon +.IP \(bu 5 +A single arc or multiple arcs +.NH 3 +Filling Single and Multiple Rectangles +.XS +\*(SN Filling Single and Multiple Rectangles +.XE +.LP +.IN "Filling" "rectangles" +.IN "XFillRectangle" +.IN "Rectangle" "filling" +.IN "XFillRectangles" +.LP +.sp +To fill a single rectangular area in a given drawable, use +.PN XFillRectangle . +.IN "XFillRectangle" "" "@DEF@" +.sM +.FD 0 +XFillRectangle\^(\^\fIdisplay\fP, \fId\fP\^, \fIgc\fP\^, \fIx\fP\^, \fIy\fP\^, \fIwidth\fP\^, \fIheight\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Drawable \fId\fP\^; +.br + GC \fIgc\fP\^; +.br + int \fIx\fP\^, \fIy\fP\^; +.br + unsigned int \fIwidth\fP\^, \fIheight\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fId\fP 1i +Specifies the drawable. +.IP \fIgc\fP 1i +Specifies the GC. +.ds Xy , which are relative to the origin of the drawable \ +and specify the upper-left corner of the rectangle +.IP \fIx\fP 1i +.br +.ns +.IP \fIy\fP 1i +Specify the x and y coordinates\*(Xy. +.ds Wh , which are the dimensions of the rectangle to be filled +.IP \fIwidth\fP 1i +.br +.ns +.IP \fIheight\fP 1i +Specify the width and height\*(Wh. +.LP +.eM +.sp +To fill multiple rectangular areas in a given drawable, use +.PN XFillRectangles . +.IN "XFillRectangles" "" "@DEF@" +.sM +.FD 0 +XFillRectangles\^(\^\fIdisplay\fP, \fId\fP\^, \fIgc\fP\^, \fIrectangles\fP\^, \fInrectangles\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Drawable \fId\fP\^; +.br + GC \fIgc\fP\^; +.br + XRectangle *\fIrectangles\fP\^; +.br + int \fInrectangles\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fId\fP 1i +Specifies the drawable. +.IP \fIgc\fP 1i +Specifies the GC. +.IP \fIrectangles\fP 1i +Specifies an array of rectangles. +.IP \fInrectangles\fP 1i +Specifies the number of rectangles in the array. +.LP +.eM +The +.PN XFillRectangle +and +.PN XFillRectangles +functions fill the specified rectangle or rectangles +as if a four-point +.PN FillPolygon +protocol request were specified for each rectangle: +.LP +.Ds +[x,y] [x+width,y] [x+width,y+height] [x,y+height] +.De +.LP +Each function uses the x and y coordinates, +width and height dimensions, and GC you specify. +.LP +.PN XFillRectangles +fills the rectangles in the order listed in the array. +For any given rectangle, +.PN XFillRectangle +and +.PN XFillRectangles +do not draw a pixel more than once. +If rectangles intersect, the intersecting pixels are +drawn multiple times. +.LP +Both functions use these GC components: +function, plane-mask, fill-style, subwindow-mode, +clip-x-origin, clip-y-origin, and clip-mask. +They also use these GC mode-dependent components: +foreground, background, tile, stipple, tile-stipple-x-origin, +and tile-stipple-y-origin. +.LP +.PN XFillRectangle +and +.PN XFillRectangles +can generate +.PN BadDrawable , +.PN BadGC , +and +.PN BadMatch +errors. +.NH 3 +Filling a Single Polygon +.XS +\*(SN Filling a Single Polygon +.XE +.LP +.sp +To fill a polygon area in a given drawable, use +.PN XFillPolygon . +.IN "Polygons" "filling" +.IN "Filling" "polygon" +.IN "XFillPolygon" "" "@DEF@" +.sM +.FD 0 +XFillPolygon\^(\^\fIdisplay\fP, \fId\fP\^, \fIgc\fP\^, \fIpoints\fP\^, \fInpoints\fP\^, \fIshape\fP\^, \fImode\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Drawable \fId\fP\^; +.br + GC \fIgc\fP\^; +.br + XPoint *\fIpoints\fP\^; +.br + int \fInpoints\fP\^; +.br + int \fIshape\fP\^; +.br + int \fImode\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fId\fP 1i +Specifies the drawable. +.IP \fIgc\fP 1i +Specifies the GC. +.IP \fIpoints\fP 1i +Specifies an array of points. +.IP \fInpoints\fP 1i +Specifies the number of points in the array. +.IP \fIshape\fP 1i +Specifies a shape that helps the server to improve performance. +You can pass +.PN Complex , +.PN Convex , +or +.PN Nonconvex . +.IP \fImode\fP 1i +Specifies the coordinate mode. +You can pass +.PN CoordModeOrigin +or +.PN CoordModePrevious . +.LP +.eM +.PN XFillPolygon +fills the region closed by the specified path. +The path is closed +automatically if the last point in the list does not coincide with the +first point. +.PN XFillPolygon +does not draw a pixel of the region more than once. +.PN CoordModeOrigin +treats all coordinates as relative to the origin, +and +.PN CoordModePrevious +treats all coordinates after the first as relative to the previous point. +.LP +Depending on the specified shape, the following occurs: +.IP \(bu 5 +If shape is +.PN Complex , +the path may self-intersect. +Note that contiguous coincident points in the path are not treated +as self-intersection. +.IP \(bu 5 +If shape is +.PN Convex , +for every pair of points inside the polygon, +the line segment connecting them does not intersect the path. +If known by the client, +specifying +.PN Convex +can improve performance. +If you specify +.PN Convex +for a path that is not convex, +the graphics results are undefined. +.IP \(bu 5 +If shape is +.PN Nonconvex , +the path does not self-intersect, but the shape is not +wholly convex. +If known by the client, +specifying +.PN Nonconvex +instead of +.PN Complex +may improve performance. +If you specify +.PN Nonconvex +for a self-intersecting path, the graphics results are undefined. +.LP +The fill-rule of the GC controls the filling behavior of +self-intersecting polygons. +.LP +This function uses these GC components: +function, plane-mask, fill-style, fill-rule, subwindow-mode, clip-x-origin, +clip-y-origin, and clip-mask. +It also uses these GC mode-dependent components: +foreground, background, tile, stipple, tile-stipple-x-origin, +and tile-stipple-y-origin. +.LP +.PN XFillPolygon +can generate +.PN BadDrawable , +.PN BadGC , +.PN BadMatch , +and +.PN BadValue +errors. +.NH 3 +Filling Single and Multiple Arcs +.XS +\*(SN Filling Single and Multiple Arcs +.XE +.LP +.IN "XFillArc" +.IN "Arcs" "filling" +.IN "Filling" "arcs" +To fill a single arc in a given drawable, use +.PN XFillArc . +.IN "XFillArc" "" "@DEF@" +.sM +.FD 0 +XFillArc\^(\^\fIdisplay\fP, \fId\fP\^, \fIgc\fP\^, \fIx\fP\^, \fIy\fP\^, \fIwidth\fP\^, \fIheight\fP\^, \fIangle1\fP\^, \fIangle2\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Drawable \fId\fP\^; +.br + GC \fIgc\fP\^; +.br + int \fIx\fP\^, \fIy\fP\^; +.br + unsigned int \fIwidth\fP\^, \fIheight\fP\^; +.br + int \fIangle1\fP\^, \fIangle2\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fId\fP 1i +Specifies the drawable. +.IP \fIgc\fP 1i +Specifies the GC. +.ds Xy , which are relative to the origin of the drawable \ +and specify the upper-left corner of the bounding rectangle +.IP \fIx\fP 1i +.br +.ns +.IP \fIy\fP 1i +Specify the x and y coordinates\*(Xy. +.ds Wh , which are the major and minor axes of the arc +.IP \fIwidth\fP 1i +.br +.ns +.IP \fIheight\fP 1i +Specify the width and height\*(Wh. +.IP \fIangle1\fP 1i +Specifies the start of the arc relative to the three-o'clock position +from the center, in units of degrees * 64. +.IP \fIangle2\fP 1i +Specifies the path and extent of the arc relative to the start of the +arc, in units of degrees * 64. +.LP +.eM +.sp +To fill multiple arcs in a given drawable, use +.PN XFillArcs . +.IN "XFillArcs" "" "@DEF@" +.sM +.FD 0 +XFillArcs\^(\^\fIdisplay\fP, \fId\fP\^, \fIgc\fP\^, \fIarcs\fP\^, \fInarcs\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Drawable \fId\fP\^; +.br + GC \fIgc\fP\^; +.br + XArc *\fIarcs\fP\^; +.br + int \fInarcs\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fId\fP 1i +Specifies the drawable. +.IP \fIgc\fP 1i +Specifies the GC. +.IP \fIarcs\fP 1i +Specifies an array of arcs. +.IP \fInarcs\fP 1i +Specifies the number of arcs in the array. +.LP +.eM +For each arc, +.PN XFillArc +or +.PN XFillArcs +fills the region closed by the infinitely thin path +described by the specified arc and, depending on the +arc-mode specified in the GC, one or two line segments. +For +.PN ArcChord , +the single line segment joining the endpoints of the arc is used. +For +.PN ArcPieSlice , +the two line segments joining the endpoints of the arc with the center +point are used. +.PN XFillArcs +fills the arcs in the order listed in the array. +For any given arc, +.PN XFillArc +and +.PN XFillArcs +do not draw a pixel more than once. +If regions intersect, +the intersecting pixels are drawn multiple times. +.LP +Both functions use these GC components: +function, plane-mask, fill-style, arc-mode, subwindow-mode, clip-x-origin, +clip-y-origin, and clip-mask. +They also use these GC mode-dependent components: +foreground, background, tile, stipple, tile-stipple-x-origin, +and tile-stipple-y-origin. +.LP +.PN XFillArc +and +.PN XFillArcs +can generate +.PN BadDrawable , +.PN BadGC , +and +.PN BadMatch +errors. +.NH 2 +Font Metrics +.XS +\*(SN Font Metrics +.XE +.LP +.IN "Font" +A font is a graphical description of a set of characters that are used to +increase efficiency whenever a set of small, similar sized patterns are +repeatedly used. +.LP +This section discusses how to: +.IP \(bu 5 +Load and free fonts +.IP \(bu 5 +Obtain and free font names +.IP \(bu 5 +Compute character string sizes +.IP \(bu 5 +Compute logical extents +.IP \(bu 5 +Query character string sizes +.LP +The X server loads fonts whenever a program requests a new font. +The server can cache fonts for quick lookup. +Fonts are global across all screens in a server. +Several levels are possible when dealing with fonts. +Most applications simply use +.PN XLoadQueryFont +to load a font and query the font metrics. +.LP +Characters in fonts are regarded as masks. +Except for image text requests, +the only pixels modified are those in which bits are set to 1 in the character. +This means that it makes sense to draw text using stipples or tiles +(for example, many menus gray-out unusable entries). +.LP +.sM +The +.PN XFontStruct +structure contains all of the information for the font +and consists of the font-specific information as well as +a pointer to an array of +.PN XCharStruct +structures for the +characters contained in the font. +The +.PN XFontStruct , +.PN XFontProp , +and +.PN XCharStruct +structures contain: +.LP +.IN "XCharStruct" "" "@DEF@" +.Ds 0 +.TA .5i 3i +.ta .5i 3i +typedef struct { + short lbearing; /* origin to left edge of raster */ + short rbearing; /* origin to right edge of raster */ + short width; /* advance to next char's origin */ + short ascent; /* baseline to top edge of raster */ + short descent; /* baseline to bottom edge of raster */ + unsigned short attributes; /* per char flags (not predefined) */ +} XCharStruct; +.De +.LP +.IN "XFontProp" "" "@DEF@" +.Ds 0 +.TA .5i 1i 3i +.ta .5i 1i 3i +typedef struct { + Atom name; + unsigned long card32; +} XFontProp; +.De +.LP +.IN "XChar2b" "" "@DEF@" +.Ds 0 +.TA .5i 3i +.ta .5i 3i +typedef struct { /* normal 16 bit characters are two bytes */ + unsigned char byte1; + unsigned char byte2; +} XChar2b; +.De +.LP +.IN "XFontStruct" "" "@DEF@" +.Ds 0 +.TA .5i 3i +.ta .5i 3i +typedef struct { + XExtData *ext_data; /* hook for extension to hang data */ + Font fid; /* Font id for this font */ + unsigned direction; /* hint about the direction font is painted */ + unsigned min_char_or_byte2; /* first character */ + unsigned max_char_or_byte2; /* last character */ + unsigned min_byte1; /* first row that exists */ + unsigned max_byte1; /* last row that exists */ + Bool all_chars_exist; /* flag if all characters have nonzero size */ + unsigned default_char; /* char to print for undefined character */ + int n_properties; /* how many properties there are */ + XFontProp *properties; /* pointer to array of additional properties */ + XCharStruct min_bounds; /* minimum bounds over all existing char */ + XCharStruct max_bounds; /* maximum bounds over all existing char */ + XCharStruct *per_char; /* first_char to last_char information */ + int ascent; /* logical extent above baseline for spacing */ + int descent; /* logical descent below baseline for spacing */ +} XFontStruct; +.De +.LP +.eM +X supports single byte/character, two bytes/character matrix, +and 16-bit character text operations. +Note that any of these forms can be used with a font, but a +single byte/character text request can only specify a single byte +(that is, the first row of a 2-byte font). +You should view 2-byte fonts as a two-dimensional matrix of defined +characters: byte1 specifies the range of defined rows and +byte2 defines the range of defined columns of the font. +Single byte/character fonts have one row defined, and the byte2 range +specified in the structure defines a range of characters. +.LP +The bounding box of a character is defined by the +.PN XCharStruct +of that character. +When characters are absent from a font, +the default_char is used. +When fonts have all characters of the same size, +only the information in the +.PN XFontStruct +min and max bounds are used. +.LP +The members of the +.PN XFontStruct +have the following semantics: +.IP \(bu 5 +The direction member can be either +.PN FontLeftToRight +or +.PN FontRightToLeft . +It is just a hint as to whether most +.PN XCharStruct +elements +have a positive +.Pn ( FontLeftToRight ) +or a negative +.Pn ( FontRightToLeft ) +character width +metric. +The core protocol defines no support for vertical text. +.IP \(bu 5 +If the min_byte1 and max_byte1 members are both zero, min_char_or_byte2 +specifies the linear character index corresponding to the first element +of the per_char array, and max_char_or_byte2 specifies the linear character +index of the last element. +.IP +If either min_byte1 or max_byte1 are nonzero, both +min_char_or_byte2 and max_char_or_byte2 are less than 256, +and the 2-byte character index values corresponding to the +per_char array element N (counting from 0) are: +.IP +.nf + byte1 = N/D + min_byte1 +.br + byte2 = N\\D + min_char_or_byte2 +.IP +.fi +where: +.IP +.nf + D = max_char_or_byte2 \- min_char_or_byte2 + 1 + / = integer division + \\ = integer modulus +.fi +.IP \(bu 5 +If the per_char pointer is NULL, +all glyphs between the first and last character indexes +inclusive have the same information, +as given by both min_bounds and max_bounds. +.IP \(bu 5 +If all_chars_exist is +.PN True , +all characters in the per_char array have nonzero bounding boxes. +.IP \(bu 5 +The default_char member specifies the character that will be used when an +undefined or nonexistent character is printed. +The default_char is a 16-bit character (not a 2-byte character). +For a font using 2-byte matrix format, +the default_char has byte1 in the most-significant byte +and byte2 in the least significant byte. +If the default_char itself specifies an undefined or nonexistent character, +no printing is performed for an undefined or nonexistent character. +.IP \(bu 5 +The min_bounds and max_bounds members contain the most extreme values of +each individual +.PN XCharStruct +component over all elements of this array +(and ignore nonexistent characters). +The bounding box of the font (the smallest +rectangle enclosing the shape obtained by superimposing all of the +characters at the same origin [x,y]) has its upper-left coordinate at: +.Ds + [x + min_bounds.lbearing, y \- max_bounds.ascent] +.De +.IP +Its width is: +.Ds + max_bounds.rbearing \- min_bounds.lbearing +.De +.IP +Its height is: +.Ds + max_bounds.ascent + max_bounds.descent +.De +.IP \(bu 5 +The ascent member is the logical extent of the font above the baseline that is +used for determining line spacing. +Specific characters may extend beyond +this. +.IP \(bu 5 +The descent member is the logical extent of the font at or below the +baseline that is used for determining line spacing. +Specific characters may extend beyond this. +.IP \(bu 5 +If the baseline is at Y-coordinate y, +the logical extent of the font is inclusive between the Y-coordinate +values (y \- font.ascent) and (y + font.descent \- 1). +Typically, +the minimum interline spacing between rows of text is given +by ascent + descent. +.LP +For a character origin at [x,y], +the bounding box of a character (that is, +the smallest rectangle that encloses the character's shape) +described in terms of +.PN XCharStruct +components is a rectangle with its upper-left corner at: +.LP +.Ds +[x + lbearing, y \- ascent] +.De +.LP +Its width is: +.LP +.Ds +rbearing \- lbearing +.De +.LP +Its height is: +.LP +.Ds +ascent + descent +.De +.LP +The origin for the next character is defined to be: +.LP +.Ds +[x + width, y] +.De +.LP +The lbearing member defines the extent of the left edge of the character ink +from the origin. +The rbearing member defines the extent of the right edge of the character ink +from the origin. +The ascent member defines the extent of the top edge of the character ink +from the origin. +The descent member defines the extent of the bottom edge of the character ink +from the origin. +The width member defines the logical width of the character. +.LP +Note that the baseline (the y position of the character origin) +is logically viewed as being the scanline just below nondescending characters. +When descent is zero, +only pixels with Y-coordinates less than y are drawn, +and the origin is logically viewed as being coincident with the left edge of +a nonkerned character. +When lbearing is zero, +no pixels with X-coordinate less than x are drawn. +Any of the +.PN XCharStruct +metric members could be negative. +If the width is negative, +the next character will be placed to the left of the current origin. +.LP +The X protocol does not define the interpretation of the attributes member +in the +.PN XCharStruct +structure. +A nonexistent character is represented with all members of its +.PN XCharStruct +set to zero. +.LP +A font is not guaranteed to have any properties. +The interpretation of the property value (for example, long or unsigned long) +must be derived from \fIa priori\fP knowledge of the property. +A basic set of font properties is specified in the X Consortium standard +\fIX Logical Font Description Conventions\fP. +.NH 3 +Loading and Freeing Fonts +.XS +\*(SN Loading and Freeing Fonts +.XE +.LP +Xlib provides functions that you can use to load fonts, get font information, +unload fonts, and free font information. +.IN "Fonts" "getting information" +.IN "Fonts" "unloading" +.IN "Fonts" "freeing font information" +A few font functions use a +.PN GContext +resource ID or a font ID interchangeably. +.LP +.sp +To load a given font, use +.PN XLoadFont . +.IN "XLoadFont" "" "@DEF@" +.sM +.FD 0 +Font XLoadFont\^(\^\fIdisplay\fP, \fIname\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + char *\fIname\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIname\fP 1i +Specifies the name of the font, +which is a null-terminated string. +.LP +.eM +The +.PN XLoadFont +function loads the specified font and returns its associated font ID. +If the font name is not in the Host Portable Character Encoding, +the result is implementation-dependent. +Use of uppercase or lowercase does not matter. +When the characters ``?'' and ``*'' are used in a font name, a +pattern match is performed and any matching font is used. +In the pattern, +the ``?'' character will match any single character, +and the ``*'' character will match any number of characters. +A structured format for font names is specified in the X Consortium standard +\fIX Logical Font Description Conventions\fP. +If +.PN XLoadFont +was unsuccessful at loading the specified font, +a +.PN BadName +error results. +Fonts are not associated with a particular screen +and can be stored as a component +of any GC. +When the font is no longer needed, call +.PN XUnloadFont . +.LP +.PN XLoadFont +can generate +.PN BadAlloc +and +.PN BadName +errors. +.LP +.sp +To return information about an available font, use +.PN XQueryFont . +.IN "XQueryFont" "" "@DEF@" +.sM +.FD 0 +XFontStruct *XQueryFont\^(\^\fIdisplay\fP, \fIfont_ID\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + XID \fIfont_ID\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIfont_ID\fP 1i +Specifies the font ID or the +.PN GContext +ID. +.LP +.eM +The +.PN XQueryFont +function returns a pointer to the +.PN XFontStruct +structure, which contains information associated with the font. +You can query a font or the font stored in a GC. +The font ID stored in the +.PN XFontStruct +structure will be the +.PN GContext +ID, and you need to be careful when using this ID in other functions +(see +.PN XGContextFromGC ). +If the font does not exist, +.PN XQueryFont +returns NULL. +To free this data, use +.PN XFreeFontInfo . +.LP +.sp +To perform a +.PN XLoadFont +and +.PN XQueryFont +in a single operation, use +.PN XLoadQueryFont . +.IN "XLoadQueryFont" "" "@DEF@" +.sM +.FD 0 +XFontStruct *XLoadQueryFont\^(\^\fIdisplay\fP, \fIname\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + char *\fIname\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIname\fP 1i +Specifies the name of the font, +which is a null-terminated string. +.LP +.eM +The +.PN XLoadQueryFont +function provides the most common way for accessing a font. +.PN XLoadQueryFont +both opens (loads) the specified font and returns a pointer to the +appropriate +.PN XFontStruct +structure. +If the font name is not in the Host Portable Character Encoding, +the result is implementation-dependent. +If the font does not exist, +.PN XLoadQueryFont +returns NULL. +.LP +.PN XLoadQueryFont +can generate a +.PN BadAlloc +error. +.LP +.sp +To unload the font and free the storage used by the font structure +that was allocated by +.PN XQueryFont +or +.PN XLoadQueryFont , +use +.PN XFreeFont . +.IN "XFreeFont" "" "@DEF@" +.sM +.FD 0 +XFreeFont\^(\^\fIdisplay\fP, \fIfont_struct\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + XFontStruct *\fIfont_struct\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIfont_struct\fP 1i +Specifies the storage associated with the font. +.LP +.eM +The +.PN XFreeFont +function deletes the association between the font resource ID and the specified +font and frees the +.PN XFontStruct +structure. +The font itself will be freed when no other resource references it. +The data and the font should not be referenced again. +.LP +.PN XFreeFont +can generate a +.PN BadFont +error. +.LP +.sp +To return a given font property, use +.PN XGetFontProperty . +.IN "XGetFontProperty" "" "@DEF@" +.sM +.FD 0 +Bool XGetFontProperty\^(\^\fIfont_struct\fP\^, \^\fIatom\fP\^, \^\fIvalue_return\fP\^) +.br + XFontStruct *\fIfont_struct\fP\^; +.br + Atom \fIatom\fP\^; +.br + unsigned long *\fIvalue_return\fP\^; +.FN +.IP \fIfont_struct\fP 1i +Specifies the storage associated with the font. +.IP \fIatom\fP 1i +Specifies the atom for the property name you want returned. +.IP \fIvalue_return\fP 1i +Returns the value of the font property. +.LP +.eM +Given the atom for that property, +the +.PN XGetFontProperty +function returns the value of the specified font property. +.PN XGetFontProperty +also returns +.PN False +if the property was not defined or +.PN True +if it was defined. +A set of predefined atoms exists for font properties, +which can be found in +.hN X11/Xatom.h . +This set contains the standard properties associated with +a font. +Although it is not guaranteed, +it is likely that the predefined font properties will be present. +.LP +.sp +To unload a font that was loaded by +.PN XLoadFont , +use +.PN XUnloadFont . +.IN "XUnloadFont" "" "@DEF@" +.sM +.FD 0 +XUnloadFont\^(\^\fIdisplay\fP, \fIfont\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Font \fIfont\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIfont\fP 1i +Specifies the font. +.LP +.eM +The +.PN XUnloadFont +function deletes the association between the font resource ID and the specified font. +The font itself will be freed when no other resource references it. +The font should not be referenced again. +.LP +.PN XUnloadFont +can generate a +.PN BadFont +error. +.NH 3 +Obtaining and Freeing Font Names and Information +.XS +\*(SN Obtaining and Freeing Font Names and Information +.XE +.LP +You obtain font names and information by matching a wildcard specification +when querying a font type for a list of available sizes and so on. +.LP +.sp +To return a list of the available font names, use +.PN XListFonts . +.IN "XListFonts" "" "@DEF@" +.sM +.FD 0 +char **XListFonts\^(\^\fIdisplay\fP, \fIpattern\fP\^, \fImaxnames\fP, \fIactual_count_return\fP\^) +.br + Display *\^\fIdisplay\fP\^; +.br + char *\^\fIpattern\fP\^; +.br + int \fImaxnames\fP\^; +.br + int *\^\fIactual_count_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIpattern\fP 1i +Specifies the null-terminated pattern string that can contain wildcard +characters. +.IP \fImaxnames\fP 1i +Specifies the maximum number of names to be returned. +.IP \fIactual_count_return\fP 1i +Returns the actual number of font names. +.LP +.eM +The +.PN XListFonts +function returns an array of available font names +(as controlled by the font search path; see +.PN XSetFontPath ) +that match the string you passed to the pattern argument. +The pattern string can contain any characters, +but each asterisk (*) is a wildcard for any number of characters, +and each question mark (?) is a wildcard for a single character. +If the pattern string is not in the Host Portable Character Encoding, +the result is implementation-dependent. +Use of uppercase or lowercase does not matter. +Each returned string is null-terminated. +If the data returned by the server is in the Latin Portable Character Encoding, +then the returned strings are in the Host Portable Character Encoding. +Otherwise, the result is implementation-dependent. +If there are no matching font names, +.PN XListFonts +returns NULL. +The client should call +.PN XFreeFontNames +when finished with the result to free the memory. +.LP +.sp +To free a font name array, use +.PN XFreeFontNames . +.IN "XFreeFontNames" "" "@DEF@" +.sM +.FD 0 +XFreeFontNames\^(\^\fIlist\fP\^) +.br + char *\fIlist\fP\^[\^]\^; +.FN +.IP \fIlist\fP 1i +Specifies the array of strings you want to free. +.LP +.eM +The +.PN XFreeFontNames +function frees the array and strings returned by +.PN XListFonts +or +.PN XListFontsWithInfo . +.LP +.sp +To obtain the names and information about available fonts, use +.PN XListFontsWithInfo . +.IN "XListFontsWithInfo" "" "@DEF@" +.sM +.FD 0 +char **XListFontsWithInfo\^(\^\fIdisplay\fP, \fIpattern\fP, \fImaxnames\fP, \fIcount_return\fP, \fIinfo_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + char *\fIpattern\fP\^; +.br + int \fImaxnames\fP\^; +.br + int *\fIcount_return\fP\^; +.br + XFontStruct **\fIinfo_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIpattern\fP 1i +Specifies the null-terminated pattern string that can contain wildcard +characters. +.IP \fImaxnames\fP 1i +Specifies the maximum number of names to be returned. +.IP \fIcount_return\fP 1i +Returns the actual number of matched font names. +.IP \fIinfo_return\fP 1i +Returns the font information. +.LP +.eM +The +.PN XListFontsWithInfo +function returns a list of font names that match the specified pattern and their +associated font information. +The list of names is limited to size specified by maxnames. +The information returned for each font is identical to what +.PN XLoadQueryFont +would return except that the per-character metrics are not returned. +The pattern string can contain any characters, +but each asterisk (*) is a wildcard for any number of characters, +and each question mark (?) is a wildcard for a single character. +If the pattern string is not in the Host Portable Character Encoding, +the result is implementation-dependent. +Use of uppercase or lowercase does not matter. +Each returned string is null-terminated. +If the data returned by the server is in the Latin Portable Character Encoding, +then the returned strings are in the Host Portable Character Encoding. +Otherwise, the result is implementation-dependent. +If there are no matching font names, +.PN XListFontsWithInfo +returns NULL. +.LP +To free only the allocated name array, +the client should call +.PN XFreeFontNames . +To free both the name array and the font information array +or to free just the font information array, +the client should call +.PN XFreeFontInfo . +.LP +.sp +To free font structures and font names, use +.PN XFreeFontInfo . +.IN "XFreeFontInfo" "" "@DEF@" +.sM +.FD 0 +XFreeFontInfo(\^\fInames\fP, \fIfree_info\fP, \fIactual_count\fP\^) +.br + char **\fInames\fP\^; +.br + XFontStruct *\fIfree_info\fP; +.br + int \fIactual_count\fP\^; +.FN +.IP \fInames\fP 1i +Specifies the list of font names. + +.IP \fIfree_info\fP 1i +Specifies the font information. + +.IP \fIactual_count\fP 1i +Specifies the actual number of font names. + +.LP +.eM +The +.PN XFreeFontInfo +function frees a font structure or an array of font structures +and optionally an array of font names. +If NULL is passed for names, no font names are freed. +If a font structure for an open font (returned by +.PN XLoadQueryFont ) +is passed, the structure is freed, +but the font is not closed; use +.PN XUnloadFont +to close the font. +.NH 3 +Computing Character String Sizes +.XS +\*(SN Computing Character String Sizes +.XE +.LP +Xlib provides functions that you can use to compute the width, +the logical extents, +and the server information about 8-bit and 2-byte text strings. +.IN "XTextWidth" +.IN "XTextWidth16" +The width is computed by adding the character widths of all the characters. +It does not matter if the font is an 8-bit or 2-byte font. +These functions return the sum of the character metrics in pixels. +.LP +.sp +To determine the width of an 8-bit character string, use +.PN XTextWidth . +.IN "XTextWidth" "" "@DEF@" +.sM +.FD 0 +int XTextWidth\^(\^\fIfont_struct\fP\^, \fIstring\fP, \fIcount\fP\^) +.br + XFontStruct *\fIfont_struct\fP\^; +.br + char *\fIstring\fP\^; +.br + int \fIcount\fP\^; +.FN +.IP \fIfont_struct\fP 1i +Specifies the font used for the width computation. +.IP \fIstring\fP 1i +Specifies the character string. +.IP \fIcount\fP 1i +Specifies the character count in the specified string. +.LP +.eM +.sp +To determine the width of a 2-byte character string, use +.PN XTextWidth16 . +.IN "XTextWidth16" "" "@DEF@" +.sM +.FD 0 +int XTextWidth16\^(\^\fIfont_struct\fP\^, \fIstring\fP, \fIcount\fP\^) +.br + XFontStruct *\fIfont_struct\fP\^; +.br + XChar2b *\fIstring\fP\^; +.br + int \fIcount\fP\^; +.FN +.IP \fIfont_struct\fP 1i +Specifies the font used for the width computation. +.IP \fIstring\fP 1i +Specifies the character string. +.IP \fIcount\fP 1i +Specifies the character count in the specified string. +.LP +.eM +.NH 3 +Computing Logical Extents +.XS +\*(SN Computing Logical Extents +.XE +.LP +To compute the bounding box of an 8-bit character string in a given font, use +.PN XTextExtents . +.IN "XTextExtents" "" "@DEF@" +.sM +.FD 0 +XTextExtents\^(\^\fIfont_struct\fP\^, \fIstring\fP\^, \fInchars\fP\^, \ +\fIdirection_return\fP, \fIfont_ascent_return\fP, +.br + \fIfont_descent_return\fP, \fIoverall_return\fP\^) +.br + XFontStruct *\fIfont_struct\fP\^; +.br + char *\fIstring\fP\^; +.br + int \fInchars\fP\^; +.br + int *\fIdirection_return\fP\^; +.br + int *\fIfont_ascent_return\fP, *\fIfont_descent_return\fP\^; +.br + XCharStruct *\fIoverall_return\fP\^; + +.FN +.IP \fIfont_struct\fP 1i +Specifies the +.PN XFontStruct +structure. +.IP \fIstring\fP 1i +Specifies the character string. +.IP \fInchars\fP 1i +Specifies the number of characters in the character string. +.IP \fIdirection_return\fP 1i +Returns the value of the direction hint +.Pn ( FontLeftToRight +or +.PN FontRightToLeft ). +.IP \fIfont_ascent_return\fP 1i +Returns the font ascent. +.IP \fIfont_descent_return\fP 1i +Returns the font descent. +.IP \fIoverall_return\fP 1i +Returns the overall size in the specified +.PN XCharStruct +structure. +.LP +.eM +.sp +To compute the bounding box of a 2-byte character string in a given font, use +.PN XTextExtents16 . +.IN "XTextExtents16" "" "@DEF@" +.sM +.FD 0 +XTextExtents16\^(\^\fIfont_struct\fP\^, \fIstring\fP\^, \fInchars\fP\^, \ +\fIdirection_return\fP, \fIfont_ascent_return\fP, +.br + \fIfont_descent_return\fP, \fIoverall_return\fP\^) +.br + XFontStruct *\fIfont_struct\fP\^; +.br + XChar2b *\fIstring\fP\^; +.br + int \fInchars\fP\^; +.br + int *\fIdirection_return\fP\^; +.br + int *\fIfont_ascent_return\fP, *\fIfont_descent_return\fP\^; +.br + XCharStruct *\fIoverall_return\fP\^; + +.FN +.IP \fIfont_struct\fP 1i +Specifies the +.PN XFontStruct +structure. +.IP \fIstring\fP 1i +Specifies the character string. +.IP \fInchars\fP 1i +Specifies the number of characters in the character string. +.IP \fIdirection_return\fP 1i +Returns the value of the direction hint +.Pn ( FontLeftToRight +or +.PN FontRightToLeft ). +.IP \fIfont_ascent_return\fP 1i +Returns the font ascent. +.IP \fIfont_descent_return\fP 1i +Returns the font descent. +.IP \fIoverall_return\fP 1i +Returns the overall size in the specified +.PN XCharStruct +structure. +.LP +.eM +The +.PN XTextExtents +and +.PN XTextExtents16 +functions +perform the size computation locally and, thereby, +avoid the round-trip overhead of +.PN XQueryTextExtents +and +.PN XQueryTextExtents16 . +Both functions return an +.PN XCharStruct +structure, whose members are set to the values as follows. +.LP +The ascent member is set to the maximum of the ascent metrics of all +characters in the string. +The descent member is set to the maximum of the descent metrics. +The width member is set to the sum of the character-width metrics of all +characters in the string. +For each character in the string, +let W be the sum of the character-width metrics of all characters preceding +it in the string. +Let L be the left-side-bearing metric of the character plus W. +Let R be the right-side-bearing metric of the character plus W. +The lbearing member is set to the minimum L of all characters in the string. +The rbearing member is set to the maximum R. +.LP +For fonts defined with linear indexing rather than 2-byte matrix indexing, +each +.PN XChar2b +structure is interpreted as a 16-bit number with byte1 as the +most significant byte. +If the font has no defined default character, +undefined characters in the string are taken to have all zero metrics. +.NH 3 +Querying Character String Sizes +.XS +\*(SN Querying Character String Sizes +.XE +.LP +To query the server for the bounding box of an 8-bit character string in a +given font, use +.PN XQueryTextExtents . +.IN "XQueryTextExtents" "" "@DEF@" +.sM +.FD 0 +XQueryTextExtents\^(\^\fIdisplay\fP, \fIfont_ID\fP, \fIstring\fP, \ +\fInchars\fP, \fIdirection_return\fP, \fIfont_ascent_return\fP, +.br + \fIfont_descent_return\fP, \fIoverall_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + XID \fIfont_ID\fP\^; +.br + char *\fIstring\fP\^; +.br + int \fInchars\fP\^; +.br + int *\fIdirection_return\fP\^; +.br + int *\fIfont_ascent_return\fP, *\fIfont_descent_return\fP\^; +.br + XCharStruct *\fIoverall_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIfont_ID\fP 1i +Specifies either the font ID or the +.PN GContext +ID that contains the font. +.IP \fIstring\fP 1i +Specifies the character string. +.IP \fInchars\fP 1i +Specifies the number of characters in the character string. +.IP \fIdirection_return\fP 1i +Returns the value of the direction hint +.Pn ( FontLeftToRight +or +.PN FontRightToLeft ). +.IP \fIfont_ascent_return\fP 1i +Returns the font ascent. +.IP \fIfont_descent_return\fP 1i +Returns the font descent. +.IP \fIoverall_return\fP 1i +Returns the overall size in the specified +.PN XCharStruct +structure. +.LP +.eM +.sp +To query the server for the bounding box of a 2-byte character string +in a given font, use +.PN XQueryTextExtents16 . +.IN "XQueryTextExtents16" "" "@DEF@" +.sM +.FD 0 +XQueryTextExtents16\^(\^\fIdisplay\fP, \fIfont_ID\fP, \fIstring\fP, \ +\fInchars\fP, \fIdirection_return\fP, \fIfont_ascent_return\fP, +.br + \fIfont_descent_return\fP, \fIoverall_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + XID \fIfont_ID\fP\^; +.br + XChar2b *\fIstring\fP\^; +.br + int \fInchars\fP\^; +.br + int *\fIdirection_return\fP\^; +.br + int *\fIfont_ascent_return\fP, *\fIfont_descent_return\fP\^; +.br + XCharStruct *\fIoverall_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIfont_ID\fP 1i +Specifies either the font ID or the +.PN GContext +ID that contains the font. +.IP \fIstring\fP 1i +Specifies the character string. +.IP \fInchars\fP 1i +Specifies the number of characters in the character string. +.IP \fIdirection_return\fP 1i +Returns the value of the direction hint +.Pn ( FontLeftToRight +or +.PN FontRightToLeft ). +.IP \fIfont_ascent_return\fP 1i +Returns the font ascent. +.IP \fIfont_descent_return\fP 1i +Returns the font descent. +.IP \fIoverall_return\fP 1i +Returns the overall size in the specified +.PN XCharStruct +structure. +.LP +.eM +The +.PN XQueryTextExtents +and +.PN XQueryTextExtents16 +functions return the bounding box of the specified 8-bit and 16-bit +character string in the specified font or the font contained in the +specified GC. +These functions query the X server and, therefore, suffer the round-trip +overhead that is avoided by +.PN XTextExtents +and +.PN XTextExtents16 . +Both functions return a +.PN XCharStruct +structure, whose members are set to the values as follows. +.LP +The ascent member is set to the maximum of the ascent metrics +of all characters in the string. +The descent member is set to the maximum of the descent metrics. +The width member is set to the sum of the character-width metrics +of all characters in the string. +For each character in the string, +let W be the sum of the character-width metrics of all characters preceding +it in the string. +Let L be the left-side-bearing metric of the character plus W. +Let R be the right-side-bearing metric of the character plus W. +The lbearing member is set to the minimum L of all characters in the string. +The rbearing member is set to the maximum R. +.LP +For fonts defined with linear indexing rather than 2-byte matrix indexing, +each +.PN XChar2b +structure is interpreted as a 16-bit number with byte1 as the +most significant byte. +If the font has no defined default character, +undefined characters in the string are taken to have all zero metrics. +.LP +Characters with all zero metrics are ignored. +If the font has no defined default_char, +the undefined characters in the string are also ignored. +.LP +.PN XQueryTextExtents +and +.PN XQueryTextExtents16 +can generate +.PN BadFont +and +.PN BadGC +errors. +.NH 2 +Drawing Text +.XS +\*(SN Drawing Text +.XE +.LP +This section discusses how to draw: +.IP \(bu 5 +Complex text +.IP \(bu 5 +Text characters +.IP \(bu 5 +Image text characters +.LP +The fundamental text functions +.PN XDrawText +and +.PN XDrawText16 +use the following structures: +.LP +.IN "XTextItem" "" "@DEF@" +.sM +.Ds 0 +.TA .5i 3i +.ta .5i 3i +typedef struct { + char *chars; /* pointer to string */ + int nchars; /* number of characters */ + int delta; /* delta between strings */ + Font font; /* Font to print it in, None don't change */ +} XTextItem; +.De +.LP +.IN "XTextItem16" "" "@DEF@" +.Ds 0 +.TA .5i 3i +.ta .5i 3i +typedef struct { + XChar2b *chars; /* pointer to two-byte characters */ + int nchars; /* number of characters */ + int delta; /* delta between strings */ + Font font; /* font to print it in, None don't change */ +} XTextItem16; +.De +.LP +.eM +If the font member is not +.PN None , +the font is changed before printing and also is stored in the GC. +If an error was generated during text drawing, +the previous items may have been drawn. +The baseline of the characters are drawn starting at the x and y +coordinates that you pass in the text drawing functions. +.LP +For example, consider the background rectangle drawn by +.PN XDrawImageString . +If you want the upper-left corner of the background rectangle +to be at pixel coordinate (x,y), pass the (x,y + ascent) +as the baseline origin coordinates to the text functions. +The ascent is the font ascent, as given in the +.PN XFontStruct +structure. +If you want the lower-left corner of the background rectangle +to be at pixel coordinate (x,y), pass the (x,y \- descent + 1) +as the baseline origin coordinates to the text functions. +The descent is the font descent, as given in the +.PN XFontStruct +structure. +.NH 3 +Drawing Complex Text +.XS +\*(SN Drawing Complex Text +.XE +.LP +.IN "Text" "drawing" +.IN "Drawing" "text items" +.LP +To draw 8-bit characters in a given drawable, use +.PN XDrawText . +.IN "XDrawText" "" "@DEF@" +.sM +.FD 0 +XDrawText\^(\^\fIdisplay\fP, \fId\fP\^, \fIgc\fP\^, \fIx\fP\^, \fIy\fP\^, \fIitems\fP\^, \fInitems\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Drawable \fId\fP\^; +.br + GC \fIgc\fP\^; +.br + int \fIx\fP\^, \fIy\fP\^; +.br + XTextItem *\fIitems\fP\^; +.br + int \fInitems\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fId\fP 1i +Specifies the drawable. +.IP \fIgc\fP 1i +Specifies the GC. +.ds Xy , which are relative to the origin of the specified drawable \ +and define the origin of the first character +.IP \fIx\fP 1i +.br +.ns +.IP \fIy\fP 1i +Specify the x and y coordinates\*(Xy. +.IP \fIitems\fP 1i +Specifies an array of text items. +.IP \fInitems\fP 1i +Specifies the number of text items in the array. +.LP +.eM +.sp +To draw 2-byte characters in a given drawable, use +.PN XDrawText16 . +.IN "XDrawText16" "" "@DEF@" +.sM +.FD 0 +XDrawText16\^(\^\fIdisplay\fP, \fId\fP\^, \fIgc\fP\^, \fIx\fP\^, \fIy\fP\^, \fIitems\fP\^, \fInitems\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Drawable \fId\fP\^; +.br + GC \fIgc\fP\^; +.br + int \fIx\fP\^, \fIy\fP\^; +.br + XTextItem16 *\fIitems\fP\^; +.br + int \fInitems\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fId\fP 1i +Specifies the drawable. +.IP \fIgc\fP 1i +Specifies the GC. +.ds Xy , which are relative to the origin of the specified drawable \ +and define the origin of the first character +.IP \fIx\fP 1i +.br +.ns +.IP \fIy\fP 1i +Specify the x and y coordinates\*(Xy. +.IP \fIitems\fP 1i +Specifies an array of text items. +.IP \fInitems\fP 1i +Specifies the number of text items in the array. +.LP +.eM +The +.PN XDrawText16 +function is similar to +.PN XDrawText +except that it uses 2-byte or 16-bit characters. +Both functions allow complex spacing and font shifts between counted strings. +.LP +Each text item is processed in turn. +A font member other than +.PN None +in an item causes the font to be stored in the GC +and used for subsequent text. +A text element delta specifies an additional change +in the position along the x axis before the string is drawn. +The delta is always added to the character origin +and is not dependent on any characteristics of the font. +Each character image, as defined by the font in the GC, is treated as an +additional mask for a fill operation on the drawable. +The drawable is modified only where the font character has a bit set to 1. +If a text item generates a +.PN BadFont +error, the previous text items may have been drawn. +.LP +For fonts defined with linear indexing rather than 2-byte matrix indexing, +each +.PN XChar2b +structure is interpreted as a 16-bit number with byte1 as the +most significant byte. +.LP +Both functions use these GC components: +function, plane-mask, fill-style, font, subwindow-mode, +clip-x-origin, clip-y-origin, and clip-mask. +They also use these GC mode-dependent components: +foreground, background, tile, stipple, tile-stipple-x-origin, +and tile-stipple-y-origin. +.LP +.PN XDrawText +and +.PN XDrawText16 +can generate +.PN BadDrawable , +.PN BadFont , +.PN BadGC , +and +.PN BadMatch +errors. +.NH 3 +Drawing Text Characters +.XS +\*(SN Drawing Text Characters +.XE +.LP +.IN "Strings" "drawing" +.IN "Drawing" "strings" +To draw 8-bit characters in a given drawable, use +.PN XDrawString . +.IN "XDrawString" "" "@DEF@" +.sM +.FD 0 +XDrawString\^(\^\fIdisplay\fP, \fId\fP\^, \fIgc\fP\^, \fIx\fP\^, \fIy\fP\^, \fIstring\fP\^, \fIlength\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Drawable \fId\fP\^; +.br + GC \fIgc\fP\^; +.br + int \fIx\fP\^, \fIy\fP\^; +.br + char *\fIstring\fP\^; +.br + int \fIlength\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fId\fP 1i +Specifies the drawable. +.IP \fIgc\fP 1i +Specifies the GC. +.ds Xy , which are relative to the origin of the specified drawable \ +and define the origin of the first character +.IP \fIx\fP 1i +.br +.ns +.IP \fIy\fP 1i +Specify the x and y coordinates\*(Xy. +.IP \fIstring\fP 1i +Specifies the character string. +.IP \fIlength\fP 1i +Specifies the number of characters in the string argument. +.LP +.eM +.sp +To draw 2-byte characters in a given drawable, use +.PN XDrawString16 . +.IN "XDrawString16" "" "@DEF@" +.sM +.FD 0 +XDrawString16\^(\^\fIdisplay\fP, \fId\fP\^, \fIgc\fP\^, \fIx\fP\^, \fIy\fP\^, \fIstring\fP\^, \fIlength\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Drawable \fId\fP\^; +.br + GC \fIgc\fP\^; +.br + int \fIx\fP\^, \fIy\fP\^; +.br + XChar2b *\fIstring\fP\^; +.br + int \fIlength\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fId\fP 1i +Specifies the drawable. +.IP \fIgc\fP 1i +Specifies the GC. +.ds Xy , which are relative to the origin of the specified drawable \ +and define the origin of the first character +.IP \fIx\fP 1i +.br +.ns +.IP \fIy\fP 1i +Specify the x and y coordinates\*(Xy. +.IP \fIstring\fP 1i +Specifies the character string. +.IP \fIlength\fP 1i +Specifies the number of characters in the string argument. +.LP +.eM +Each character image, as defined by the font in the GC, is treated as an +additional mask for a fill operation on the drawable. +The drawable is modified only where the font character has a bit set to 1. +For fonts defined with 2-byte matrix indexing +and used with +.PN XDrawString16 , +each byte is used as a byte2 with a byte1 of zero. +.LP +Both functions use these GC components: +function, plane-mask, fill-style, font, subwindow-mode, clip-x-origin, +clip-y-origin, and clip-mask. +They also use these GC mode-dependent components: +foreground, background, tile, stipple, tile-stipple-x-origin, +and tile-stipple-y-origin. +.LP +.PN XDrawString +and +.PN XDrawString16 +can generate +.PN BadDrawable , +.PN BadGC , +and +.PN BadMatch +errors. +.NH 3 +Drawing Image Text Characters +.XS +\*(SN Drawing Image Text Characters +.XE +.LP +.IN "Image text" "drawing" +.IN "Drawing" "image text" +Some applications, in particular terminal emulators, need to +print image text in which both the foreground and background bits of +each character are painted. +This prevents annoying flicker on many displays. +.IN "XDrawImageString" +.IN "XDrawImageString16" +.LP +.sp +To draw 8-bit image text characters in a given drawable, use +.PN XDrawImageString . +.IN "XDrawImageString" "" "@DEF@" +.sM +.FD 0 +XDrawImageString\^(\^\fIdisplay\fP, \fId\fP\^, \fIgc\fP\^, \fIx\fP\^, \fIy\fP\^, \fIstring\fP\^, \fIlength\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Drawable \fId\fP\^; +.br + GC \fIgc\fP\^; +.br + int \fIx\fP\^, \fIy\fP\^; +.br + char *\fIstring\fP\^; +.br + int \fIlength\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fId\fP 1i +Specifies the drawable. +.IP \fIgc\fP 1i +Specifies the GC. +.ds Xy , which are relative to the origin of the specified drawable \ +and define the origin of the first character +.IP \fIx\fP 1i +.br +.ns +.IP \fIy\fP 1i +Specify the x and y coordinates\*(Xy. +.IP \fIstring\fP 1i +Specifies the character string. +.IP \fIlength\fP 1i +Specifies the number of characters in the string argument. +.LP +.eM +.sp +To draw 2-byte image text characters in a given drawable, use +.PN XDrawImageString16 . +.IN "XDrawImageString16" "" "@DEF@" +.sM +.FD 0 +XDrawImageString16\^(\^\fIdisplay\fP, \fId\fP\^, \fIgc\fP\^, \fIx\fP\^, \fIy\fP\^, \fIstring\fP\^, \fIlength\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Drawable \fId\fP\^; +.br + GC \fIgc\fP\^; +.br + int \fIx\fP\^, \fIy\fP\^; +.br + XChar2b *\fIstring\fP\^; +.br + int \fIlength\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fId\fP 1i +Specifies the drawable. +.IP \fIgc\fP 1i +Specifies the GC. +.ds Xy , which are relative to the origin of the specified drawable \ +and define the origin of the first character +.IP \fIx\fP 1i +.br +.ns +.IP \fIy\fP 1i +Specify the x and y coordinates\*(Xy. +.IP \fIstring\fP 1i +Specifies the character string. +.IP \fIlength\fP 1i +Specifies the number of characters in the string argument. +.LP +.eM +The +.PN XDrawImageString16 +function is similar to +.PN XDrawImageString +except that it uses 2-byte or 16-bit characters. +Both functions also use both the foreground and background pixels +of the GC in the destination. +.LP +The effect is first to fill a +destination rectangle with the background pixel defined in the GC and then +to paint the text with the foreground pixel. +The upper-left corner of the filled rectangle is at: +.LP +.Ds +[x, y \- font-ascent] +.De +.LP +The width is: +.LP +.Ds +overall-width +.De +.LP +The height is: +.LP +.Ds +font-ascent + font-descent +.De +.LP +The overall-width, font-ascent, and font-descent +are as would be returned by +.PN XQueryTextExtents +using gc and string. +The function and fill-style defined in the GC are ignored for these functions. +The effective function is +.PN GXcopy , +and the effective fill-style is +.PN FillSolid . +.LP +For fonts defined with 2-byte matrix indexing +and used with +.PN XDrawImageString , +each byte is used as a byte2 with a byte1 of zero. +.LP +Both functions use these GC components: +plane-mask, foreground, background, font, subwindow-mode, clip-x-origin, +clip-y-origin, and clip-mask. +.LP +.PN XDrawImageString +and +.PN XDrawImageString16 +can generate +.PN BadDrawable , +.PN BadGC , +and +.PN BadMatch +errors. +.LP +.NH 2 +Transferring Images between Client and Server +.XS +\*(SN Transferring Images between Client and Server +.XE +.LP +Xlib provides functions that you can use to transfer images between a client +and the server. +Because the server may require diverse data formats, +Xlib provides an image object that fully describes the data in memory +and that provides for basic operations on that data. +You should reference the data +through the image object rather than referencing the data directly. +However, some implementations of the Xlib library may efficiently deal with +frequently used data formats by replacing +functions in the procedure vector with special case functions. +Supported operations include destroying the image, getting a pixel, +storing a pixel, extracting a subimage of an image, and adding a constant +to an image (see section 16.8). +.LP +All the image manipulation functions discussed in this section make use of +the +.PN XImage +structure, +which describes an image as it exists in the client's memory. +.LP +.IN "XImage" "" "@DEF@" +.sM +.Ds 0 +.TA .5i 1i 3i +.ta .5i 1i 3i +typedef struct _XImage { + int width, height; /* size of image */ + int xoffset; /* number of pixels offset in X direction */ + int format; /* XYBitmap, XYPixmap, ZPixmap */ + char *data; /* pointer to image data */ + int byte_order; /* data byte order, LSBFirst, MSBFirst */ + int bitmap_unit; /* quant. of scanline 8, 16, 32 */ + int bitmap_bit_order; /* LSBFirst, MSBFirst */ + int bitmap_pad; /* 8, 16, 32 either XY or ZPixmap */ + int depth; /* depth of image */ + int bytes_per_line; /* accelerator to next scanline */ + int bits_per_pixel; /* bits per pixel (ZPixmap) */ + unsigned long red_mask; /* bits in z arrangement */ + unsigned long green_mask; + unsigned long blue_mask; + XPointer obdata; /* hook for the object routines to hang on */ + struct funcs { /* image manipulation routines */ + struct _XImage *(*create_image)(); + int (*destroy_image)(); + unsigned long (*get_pixel)(); + int (*put_pixel)(); + struct _XImage *(*sub_image)(); + int (*add_pixel)(); + } f; +} XImage; +.De +.LP +.eM +.sp +To initialize the image manipulation routines of an image structure, use +.PN XInitImage . +.IN "XInitImage" "" "@DEF@" +.sM +.FD 0 +Status XInitImage\^(\^\fIimage\fP\^) +.br + XImage *\fIimage\fP\^; +.FN +.IP \fIximage\fP 1i +Specifies the image. +.LP +.eM +The +.PN XInitImage +function initializes the internal image manipulation routines of an +image structure, based on the values of the various structure members. +All fields other than the manipulation routines must already be initialized. +If the bytes_per_line member is zero, +.PN XInitImage +will assume the image data is contiguous in memory and set the +bytes_per_line member to an appropriate value based on the other +members; otherwise, the value of bytes_per_line is not changed. +All of the manipulation routines are initialized to functions +that other Xlib image manipulation functions need to operate on the +type of image specified by the rest of the structure. +.LP +This function must be called for any image constructed by the client +before passing it to any other Xlib function. +Image structures created or returned by Xlib do not need to be +initialized in this fashion. +.LP +This function returns a nonzero status if initialization of the +structure is successful. It returns zero if it detected some error +or inconsistency in the structure, in which case the image is not changed. +.LP +.sp +To combine an image with a rectangle of a drawable on the display, +use +.PN XPutImage . +.IN "XPutImage" "" "@DEF@" +.sM +.FD 0 +XPutImage\^(\^\fIdisplay\fP, \fId\fP\^, \fIgc\fP\^, \fIimage\fP\^, \fIsrc_x\fP, \fIsrc_y\fP, \fIdest_x\fP\^, \fIdest_y\fP\^, \fIwidth\fP\^, \fIheight\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Drawable \fId\fP\^; +.br + GC \fIgc\fP\^; +.br + XImage *\fIimage\fP\^; +.br + int \fIsrc_x\fP\^, \fIsrc_y\fP\^; +.br + int \fIdest_x\fP\^, \fIdest_y\fP\^; +.br + unsigned int \fIwidth\fP\^, \fIheight\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fId\fP 1i +Specifies the drawable. +.IP \fIgc\fP 1i +Specifies the GC. +.IP \fIimage\fP 1i +Specifies the image you want combined with the rectangle. +.IP \fIsrc_x\fP 1i +Specifies the offset in X from the left edge of the image defined +by the +.PN XImage +structure. +.IP \fIsrc_y\fP 1i +Specifies the offset in Y from the top edge of the image defined +by the +.PN XImage +structure. +.ds Dx , which are relative to the origin of the drawable \ +and are the coordinates of the subimage +.IP \fIdest_x\fP 1i +.br +.ns +.IP \fIdest_y\fP 1i +Specify the x and y coordinates\*(Dx. +.ds Wh \ of the subimage, which define the dimensions of the rectangle +.IP \fIwidth\fP 1i +.br +.ns +.IP \fIheight\fP 1i +Specify the width and height\*(Wh. +.LP +.eM +The +.PN XPutImage +function +combines an image with a rectangle of the specified drawable. +The section of the image defined by the src_x, src_y, width, and height +arguments is drawn on the specified part of the drawable. +If +.PN XYBitmap +format is used, the depth of the image must be one, +or a +.PN BadMatch +error results. +The foreground pixel in the GC defines the source for the one bits in the image, +and the background pixel defines the source for the zero bits. +For +.PN XYPixmap +and +.PN ZPixmap , +the depth of the image must match the depth of the drawable, +or a +.PN BadMatch +error results. +.LP +If the characteristics of the image (for example, byte_order and bitmap_unit) +differ from what the server requires, +.PN XPutImage +automatically makes the appropriate +conversions. +.LP +This function uses these GC components: +function, plane-mask, subwindow-mode, clip-x-origin, clip-y-origin, +and clip-mask. +It also uses these GC mode-dependent components: +foreground and background. +.LP +.PN XPutImage +can generate +.PN BadDrawable , +.PN BadGC , +.PN BadMatch , +and +.PN BadValue +errors. +.LP +.sp +To return the contents of a rectangle in a given drawable on the display, +use +.PN XGetImage . +This function specifically supports rudimentary screen dumps. +.IN "XGetImage" "" "@DEF@" +.sM +.FD 0 +XImage *XGetImage\^(\^\fIdisplay\fP, \fId\fP\^, \fIx\fP\^, \fIy\fP\^, \fIwidth\fP\^, \fIheight\fP\^, \fIplane_mask\fP, \fIformat\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Drawable \fId\fP\^; +.br + int \fIx\fP\^, \fIy\fP\^; +.br + unsigned int \fIwidth\fP\^, \fIheight\fP\^; +.br + unsigned long \fIplane_mask\fP\^; +.br + int \fIformat\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fId\fP 1i +Specifies the drawable. +.ds Xy , which are relative to the origin of the drawable \ +and define the upper-left corner of the rectangle +.IP \fIx\fP 1i +.br +.ns +.IP \fIy\fP 1i +Specify the x and y coordinates\*(Xy. +.ds Wh \ of the subimage, which define the dimensions of the rectangle +.IP \fIwidth\fP 1i +.br +.ns +.IP \fIheight\fP 1i +Specify the width and height\*(Wh. +.IP \fIplane_mask\fP 1i +Specifies the plane mask. +.\" *** JIM: NEED MORE INFO FOR THIS. *** +.IP \fIformat\fP 1i +Specifies the format for the image. +You can pass +.PN XYPixmap +or +.PN ZPixmap . +.LP +.eM +The +.PN XGetImage +function returns a pointer to an +.PN XImage +structure. +This structure provides you with the contents of the specified rectangle of +the drawable in the format you specify. +If the format argument is +.PN XYPixmap , +the image contains only the bit planes you passed to the plane_mask argument. +If the plane_mask argument only requests a subset of the planes of the +display, the depth of the returned image will be the number of planes +requested. +If the format argument is +.PN ZPixmap , +.PN XGetImage +returns as zero the bits in all planes not +specified in the plane_mask argument. +The function performs no range checking on the values in plane_mask and ignores +extraneous bits. +.LP +.PN XGetImage +returns the depth of the image to the depth member of the +.PN XImage +structure. +The depth of the image is as specified when the drawable was created, +except when getting a subset of the planes in +.PN XYPixmap +format, when the depth is given by the number of bits set to 1 in plane_mask. +.LP +If the drawable is a pixmap, +the given rectangle must be wholly contained within the pixmap, +or a +.PN BadMatch +error results. +If the drawable is a window, +the window must be viewable, +and it must be the case that if there were no inferiors or overlapping windows, +the specified rectangle of the window would be fully visible on the screen +and wholly contained within the outside edges of the window, +or a +.PN BadMatch +error results. +Note that the borders of the window can be included and read with +this request. +If the window has backing-store, the backing-store contents are +returned for regions of the window that are obscured by noninferior +windows. +If the window does not have backing-store, +the returned contents of such obscured regions are undefined. +The returned contents of visible regions of inferiors +of a different depth than the specified window's depth are also undefined. +The pointer cursor image is not included in the returned contents. +If a problem occurs, +.PN XGetImage +returns NULL. +.LP +.PN XGetImage +can generate +.PN BadDrawable , +.PN BadMatch , +and +.PN BadValue +errors. +.sp +.LP +To copy the contents of a rectangle on the display +to a location within a preexisting image structure, use +.PN XGetSubImage . +.IN "XGetSubImage" "" "@DEF@" +.sM +.FD 0 +XImage *XGetSubImage\^(\^\fIdisplay\fP, \fId\fP\^, \fIx\fP\^, \fIy\fP\^, \fIwidth\fP\^, \fIheight\fP\^, \fIplane_mask\fP, \fIformat\fP\^, \fIdest_image\fP\^, \fIdest_x\fP\^, +.br + \fIdest_y\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Drawable \fId\fP\^; +.br + int \fIx\fP\^, \fIy\fP\^; +.br + unsigned int \fIwidth\fP\^, \fIheight\fP\^; +.br + unsigned long \fIplane_mask\fP\^; +.br + int \fIformat\fP\^; +.br + XImage *\fIdest_image\fP\^; +.br + int \fIdest_x\fP\^, \fIdest_y\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fId\fP 1i +Specifies the drawable. +.ds Xy , which are relative to the origin of the drawable \ +and define the upper-left corner of the rectangle +.IP \fIx\fP 1i +.br +.ns +.IP \fIy\fP 1i +Specify the x and y coordinates\*(Xy. +.ds Wh \ of the subimage, which define the dimensions of the rectangle +.IP \fIwidth\fP 1i +.br +.ns +.IP \fIheight\fP 1i +Specify the width and height\*(Wh. +.IP \fIplane_mask\fP 1i +Specifies the plane mask. +.\" *** JIM: NEED MORE INFO FOR THIS. *** +.IP \fIformat\fP 1i +Specifies the format for the image. +You can pass +.PN XYPixmap +or +.PN ZPixmap . +.IP \fIdest_image\fP 1i +Specifies the destination image. +.ds Dx , which are relative to the origin of the destination rectangle, \ +specify its upper-left corner, and determine where the subimage \ +is placed in the destination image +.IP \fIdest_x\fP 1i +.br +.ns +.IP \fIdest_y\fP 1i +Specify the x and y coordinates\*(Dx. +.LP +.eM +The +.PN XGetSubImage +function updates dest_image with the specified subimage in the same manner as +.PN XGetImage . +If the format argument is +.PN XYPixmap , +the image contains only the bit planes you passed to the plane_mask argument. +If the format argument is +.PN ZPixmap , +.PN XGetSubImage +returns as zero the bits in all planes not +specified in the plane_mask argument. +The function performs no range checking on the values in plane_mask and ignores +extraneous bits. +As a convenience, +.PN XGetSubImage +returns a pointer to the same +.PN XImage +structure specified by dest_image. +.LP +The depth of the destination +.PN XImage +structure must be the same as that of the drawable. +If the specified subimage does not fit at the specified location +on the destination image, the right and bottom edges are clipped. +If the drawable is a pixmap, +the given rectangle must be wholly contained within the pixmap, +or a +.PN BadMatch +error results. +If the drawable is a window, +the window must be viewable, +and it must be the case that if there were no inferiors or overlapping windows, +the specified rectangle of the window would be fully visible on the screen +and wholly contained within the outside edges of the window, +or a +.PN BadMatch +error results. +If the window has backing-store, +then the backing-store contents are returned for regions of the window +that are obscured by noninferior windows. +If the window does not have backing-store, +the returned contents of such obscured regions are undefined. +The returned contents of visible regions of inferiors +of a different depth than the specified window's depth are also undefined. +If a problem occurs, +.PN XGetSubImage +returns NULL. +.LP +.PN XGetSubImage +can generate +.PN BadDrawable , +.PN BadGC , +.PN BadMatch , +and +.PN BadValue +errors. +.bp diff --git a/libX11/specs/libX11/CH09 b/libX11/specs/libX11/CH09 new file mode 100644 index 000000000..2b79d3880 --- /dev/null +++ b/libX11/specs/libX11/CH09 @@ -0,0 +1,1290 @@ +.\" Copyright \(co 1985, 1986, 1987, 1988, 1989, 1990, 1991, 1994, 1996, 2002 The Open Group +.\" +.\" 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 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 X CONSORTIUM 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. +.\" +.\" Copyright \(co 1985, 1986, 1987, 1988, 1989, 1990, 1991 by +.\" Digital Equipment Corporation +.\" +.\" Portions Copyright \(co 1990, 1991 by +.\" Tektronix, Inc. +.\" +.\" Permission to use, copy, modify and distribute this documentation for +.\" any purpose and without fee is hereby granted, provided that the above +.\" copyright notice appears in all copies and that both that copyright notice +.\" and this permission notice appear in all copies, and that the names of +.\" Digital and Tektronix not be used in in advertising or publicity pertaining +.\" to this documentation without specific, written prior permission. +.\" Digital and Tektronix makes no representations about the suitability +.\" of this documentation for any purpose. +.\" It is provided ``as is'' without express or implied warranty. +.\" +\& +.sp 1 +.ce 3 +\s+1\fBChapter 9\fP\s-1 + +\s+1\fBWindow and Session Manager Functions\fP\s-1 +.sp 2 +.nr H1 9 +.nr H2 0 +.nr H3 0 +.nr H4 0 +.nr H5 0 +.na +.LP +.XS +Chapter 9: Window and Session Manager Functions +.XE +Although it is difficult to categorize functions as exclusively +for an application, a window manager, or a session manager, +the functions in this chapter are most often used by window managers +and session managers. +It is not expected that these functions will be used by most +application programs. +Xlib provides management functions to: +.IP \(bu 5 +Change the parent of a window +.IP \(bu 5 +Control the lifetime of a window +.IP \(bu 5 +Manage installed colormaps +.IP \(bu 5 +Set and retrieve the font search path +.IP \(bu 5 +Grab the server +.IP \(bu 5 +Kill a client +.IP \(bu 5 +Control the screen saver +.IP \(bu 5 +Control host access +.NH 2 +Changing the Parent of a Window +.XS +\*(SN Changing the Parent of a Window +.XE +.LP +To change a window's parent to another window on the same screen, use +.PN XReparentWindow . +There is no way to move a window between screens. +.IN "XReparentWindow" "" "@DEF@" +.sM +.FD 0 +XReparentWindow\^(\^\fIdisplay\fP, \fIw\fP\^, \fIparent\fP\^, \fIx\fP\^, \fIy\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + Window \fIparent\fP\^; +.br + int \fIx\fP\^, \fIy\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fIparent\fP 1i +Specifies the parent window. +.ds Xy \ of the position in the new parent window +.IP \fIx\fP 1i +.br +.ns +.IP \fIy\fP 1i +Specify the x and y coordinates\*(Xy. +.LP +.eM +If the specified window is mapped, +.PN XReparentWindow +automatically performs an +.PN UnmapWindow +request on it, removes it from its current position in the hierarchy, +and inserts it as the child of the specified parent. +The window is placed in the stacking order on top with respect to +sibling windows. +.LP +After reparenting the specified window, +.PN XReparentWindow +causes the X server to generate a +.PN ReparentNotify +event. +The override_redirect member returned in this event is +set to the window's corresponding attribute. +Window manager clients usually should ignore this window if this member +is set to +.PN True . +Finally, if the specified window was originally mapped, +the X server automatically performs a +.PN MapWindow +request on it. +.LP +The X server performs normal exposure processing on formerly obscured +windows. +The X server might not generate +.PN Expose +events for regions from the initial +.PN UnmapWindow +request that are immediately obscured by the final +.PN MapWindow +request. +A +.PN BadMatch +error results if: +.IP \(bu 5 +The new parent window is not on the same screen as +the old parent window. +.IP \(bu 5 +The new parent window is the specified window or an inferior of the +specified window. +.IP \(bu 5 +The new parent is +.PN InputOnly , +and the window is not. +.IP \(bu 5 +The specified window has a +.PN ParentRelative +background, and the new parent window is not the same depth as the +specified window. +.LP +.PN XReparentWindow +can generate +.PN BadMatch +and +.PN BadWindow +errors. +.NH 2 +Controlling the Lifetime of a Window +.XS +\*(SN Controlling the Lifetime of a Window +.XE +.LP +The save-set of a client is a list of other clients' windows that, +if they are inferiors of one of the client's windows at connection close, +should not be destroyed and should be remapped if they are unmapped. +For further information about close-connection processing, +see section 2.6. +To allow an application's window to survive when a window manager that +has reparented a window fails, +Xlib provides the save-set functions that you can +use to control the longevity of subwindows +that are normally destroyed when the parent is destroyed. +For example, a window manager that wants to add decoration +to a window by adding a frame might reparent an application's +window. +When the frame is destroyed, +the application's window should not be destroyed +but be returned to its previous place in the window hierarchy. +.LP +The X server automatically removes windows from the save-set +when they are destroyed. +.LP +.sp +To add or remove a window from the client's save-set, use +.PN XChangeSaveSet . +.IN "XChangeSaveSet" "" "@DEF@" +.sM +.FD 0 +XChangeSaveSet\^(\^\fIdisplay\fP, \fIw\fP\^, \fIchange_mode\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + int \fIchange_mode\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.ds Wi that you want to add to or delete from the client's save-set +.IP \fIw\fP 1i +Specifies the window \*(Wi. +.IP \fIchange_mode\fP 1i +Specifies the mode. +You can pass +.PN SetModeInsert +or +.PN SetModeDelete . +.LP +.eM +Depending on the specified mode, +.PN XChangeSaveSet +either inserts or deletes the specified window from the client's save-set. +The specified window must have been created by some other client, +or a +.PN BadMatch +error results. +.LP +.PN XChangeSaveSet +can generate +.PN BadMatch , +.PN BadValue , +and +.PN BadWindow +errors. +.LP +.sp +To add a window to the client's save-set, use +.PN XAddToSaveSet . +.IN "XAddToSaveSet" "" "@DEF@" +.sM +.FD 0 +XAddToSaveSet\^(\^\fIdisplay\fP, \fIw\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.ds Wi that you want to add to the client's save-set +.IP \fIw\fP 1i +Specifies the window \*(Wi. +.LP +.eM +The +.PN XAddToSaveSet +function adds the specified window to the client's save-set. +The specified window must have been created by some other client, +or a +.PN BadMatch +error results. +.LP +.PN XAddToSaveSet +can generate +.PN BadMatch +and +.PN BadWindow +errors. +.LP +.sp +To remove a window from the client's save-set, use +.PN XRemoveFromSaveSet . +.IN "XRemoveFromSaveSet" "" "@DEF@" +.sM +.FD 0 +XRemoveFromSaveSet\^(\^\fIdisplay\fP, \fIw\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.ds Wi that you want to delete from the client's save-set +.IP \fIw\fP 1i +Specifies the window \*(Wi. +.LP +.eM +The +.PN XRemoveFromSaveSet +function removes the specified window from the client's save-set. +The specified window must have been created by some other client, +or a +.PN BadMatch +error results. +.LP +.PN XRemoveFromSaveSet +can generate +.PN BadMatch +and +.PN BadWindow +errors. +.NH 2 +Managing Installed Colormaps +.XS +\*(SN Managing Installed Colormaps +.XE +.LP +The X server maintains a list of installed colormaps. +Windows using these colormaps are guaranteed to display with +correct colors; windows using other colormaps may or may not display +with correct colors. +Xlib provides functions that you can use to install a colormap, +uninstall a colormap, and obtain a list of installed colormaps. +.LP +At any time, +there is a subset of the installed maps that is viewed as an ordered list +and is called the required list. +The length of the required list is at most M, +where M is the minimum number of installed colormaps specified for the screen +in the connection setup. +The required list is maintained as follows. +When a colormap is specified to +.PN XInstallColormap , +it is added to the head of the list; +the list is truncated at the tail, if necessary, to keep its length to +at most M. +When a colormap is specified to +.PN XUninstallColormap +and it is in the required list, +it is removed from the list. +A colormap is not added to the required list when it is implicitly installed +by the X server, +and the X server cannot implicitly uninstall a colormap that is in the +required list. +.LP +.sp +To install a colormap, use +.PN XInstallColormap . +.IN "XInstallColormap" "" "@DEF@" +.sM +.FD 0 +XInstallColormap\^(\^\fIdisplay\fP, \fIcolormap\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Colormap \fIcolormap\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIcolormap\fP 1i +Specifies the colormap. +.LP +.eM +The +.PN XInstallColormap +function installs the specified colormap for its associated screen. +All windows associated with this colormap immediately display with +true colors. +You associated the windows with this colormap when you created them by calling +.PN XCreateWindow , +.PN XCreateSimpleWindow , +.PN XChangeWindowAttributes , +or +.PN XSetWindowColormap . +.LP +If the specified colormap is not already an installed colormap, +the X server generates a +.PN ColormapNotify +event on each window that has that colormap. +In addition, for every other colormap that is installed as +a result of a call to +.PN XInstallColormap , +the X server generates a +.PN ColormapNotify +event on each window that has that colormap. +.LP +.PN XInstallColormap +can generate a +.PN BadColor +error. +.LP +.sp +To uninstall a colormap, use +.PN XUninstallColormap . +.IN "XUninstallColormap" "" "@DEF@" +.sM +.FD 0 +XUninstallColormap\^(\^\fIdisplay\fP, \fIcolormap\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Colormap \fIcolormap\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIcolormap\fP 1i +Specifies the colormap. +.LP +.eM +The +.PN XUninstallColormap +function removes the specified colormap from the required +list for its screen. +As a result, +the specified colormap might be uninstalled, +and the X server might implicitly install or uninstall additional colormaps. +Which colormaps get installed or uninstalled is server dependent +except that the required list must remain installed. +.LP +If the specified colormap becomes uninstalled, +the X server generates a +.PN ColormapNotify +event on each window that has that colormap. +In addition, for every other colormap that is installed or uninstalled as a +result of a call to +.PN XUninstallColormap , +the X server generates a +.PN ColormapNotify +event on each window that has that colormap. +.LP +.PN XUninstallColormap +can generate a +.PN BadColor +error. +.LP +.sp +To obtain a list of the currently installed colormaps for a given screen, use +.PN XListInstalledColormaps . +.IN "XListInstalledColormaps" "" "@DEF@" +.sM +.FD 0 +Colormap *XListInstalledColormaps\^(\^\fIdisplay\fP, \fIw\fP, \fInum_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + int *\fInum_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.ds Wi that determines the screen +.IP \fIw\fP 1i +Specifies the window \*(Wi. +.IP \fInum_return\fP 1i +Returns the number of currently installed colormaps. +.LP +.eM +The +.PN XListInstalledColormaps +function returns a list of the currently installed colormaps for the screen +of the specified window. +The order of the colormaps in the list is not significant +and is no explicit indication of the required list. +When the allocated list is no longer needed, +free it by using +.PN XFree . +.LP +.PN XListInstalledColormaps +can generate a +.PN BadWindow +error. +.NH 2 +Setting and Retrieving the Font Search Path +.XS +\*(SN Setting and Retrieving the Font Search Path +.XE +.LP +The set of fonts available from a server depends on a font +search path. Xlib provides functions to set and retrieve the +search path for a server. +.LP +.sp +To set the font search path, use +.PN XSetFontPath . +.IN "XSetFontPath" "" "@DEF@" +.sM +.FD 0 +XSetFontPath\^(\^\fIdisplay\fP, \fIdirectories\fP\^, \fIndirs\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + char **\fIdirectories\fP\^; +.br + int \fIndirs\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIdirectories\fP 1i +Specifies the directory path used to look for a font. +Setting the path to the empty list restores the default path defined +for the X server. +.IP \fIndirs\fP 1i +Specifies the number of directories in the path. +.LP +.eM +The +.PN XSetFontPath +function defines the directory search path for font lookup. +There is only one search path per X server, not one per client. +The encoding and interpretation of the strings are implementation-dependent, +but typically they specify directories or font servers to be searched +in the order listed. +An X server is permitted to cache font information internally; +for example, it might cache an entire font from a file and not +check on subsequent opens of that font to see if the underlying +font file has changed. +However, +when the font path is changed, +the X server is guaranteed to flush all cached information about fonts +for which there currently are no explicit resource IDs allocated. +The meaning of an error from this request is implementation-dependent. +.LP +.PN XSetFontPath +can generate a +.PN BadValue +error. +.LP +.sp +To get the current font search path, use +.PN XGetFontPath . +.IN "XGetFontPath" "" "@DEF@" +.sM +.FD 0 +char **XGetFontPath\^(\^\fIdisplay\fP, \fInpaths_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + int *\fInpaths_return\fP\^; + +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fInpaths_return\fP 1i +Returns the number of strings in the font path array. +.LP +.eM +The +.PN XGetFontPath +function allocates and returns an array of strings containing the search path. +The contents of these strings are implementation-dependent +and are not intended to be interpreted by client applications. +When it is no longer needed, +the data in the font path should be freed by using +.PN XFreeFontPath . +.LP +.sp +To free data returned by +.PN XGetFontPath , +use +.PN XFreeFontPath . +.IN "XFreeFontPath" "" "@DEF@" +.sM +.FD 0 +XFreeFontPath\^(\^\fIlist\fP\^) +.br + char **\fIlist\fP\^; + +.FN +.IP \fIlist\fP 1i +Specifies the array of strings you want to free. +.LP +.eM +The +.PN XFreeFontPath +function +frees the data allocated by +.PN XGetFontPath . +.NH 2 +Grabbing the Server +.XS +\*(SN Grabbing the Server +.XE +.LP +Xlib provides functions that you can use to grab and ungrab the server. +These functions can be used to control processing of output on other +connections by the window system server. +While the server is grabbed, +no processing of requests or close downs on any other connection will occur. +A client closing its connection automatically ungrabs the server. +.IN "Menus" +.IN "Window" "managers" +Although grabbing the server is highly discouraged, it is sometimes necessary. +.LP +.sp +To grab the server, use +.PN XGrabServer . +.IN "Server" "grabbing" +.IN "Grabbing" "server" +.IN "XGrabServer" "" "@DEF@" +.sM +.FD 0 +XGrabServer\^(\^\fIdisplay\fP\^) +.br + Display *\fIdisplay\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.LP +.eM +The +.PN XGrabServer +function disables processing of requests and close downs on all other +connections than the one this request arrived on. +You should not grab the X server any more than is absolutely necessary. +.LP +.sp +To ungrab the server, use +.PN XUngrabServer . +.IN "XUngrabServer" "" "@DEF@" +.sM +.FD 0 +XUngrabServer\^(\^\fIdisplay\fP\^) +.br + Display *\fIdisplay\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.LP +.eM +The +.PN XUngrabServer +function restarts processing of requests and close downs on other connections. +You should avoid grabbing the X server as much as possible. +.NH 2 +Killing Clients +.XS +\*(SN Killing Clients +.XE +.LP +Xlib provides a function to cause the connection to +a client to be closed and its resources to be destroyed. +To destroy a client, use +.PN XKillClient . +.IN "XKillClient" "" "@DEF@" +.sM +.FD 0 +XKillClient\^(\^\fIdisplay\fP, \fIresource\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + XID \fIresource\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIresource\fP 1i +Specifies any resource associated with the client that you want to destroy or +.PN AllTemporary . +.LP +.eM +The +.PN XKillClient +function +forces a close down of the client +that created the resource +if a valid resource is specified. +If the client has already terminated in +either +.PN RetainPermanent +or +.PN RetainTemporary +mode, all of the client's +resources are destroyed. +If +.PN AllTemporary +is specified, the resources of all clients that have terminated in +.PN RetainTemporary +are destroyed (see section 2.5). +This permits implementation of window manager facilities that aid debugging. +A client can set its close-down mode to +.PN RetainTemporary . +If the client then crashes, +its windows would not be destroyed. +The programmer can then inspect the application's window tree +and use the window manager to destroy the zombie windows. +.LP +.PN XKillClient +can generate a +.PN BadValue +error. +.NH 2 +Controlling the Screen Saver +.XS +\*(SN Controlling the Screen Saver +.XE +.LP +Xlib provides functions that you can use to set or reset the mode +of the screen saver, to force or activate the screen saver, +or to obtain the current screen saver values. +.LP +.sp +To set the screen saver mode, use +.PN XSetScreenSaver . +.IN "XSetScreenSaver" "" "@DEF@" +.sM +.FD 0 +XSetScreenSaver\^(\^\fIdisplay\fP, \fItimeout\fP\^, \fIinterval\fP\^, \fIprefer_blanking\fP\^, \fIallow_exposures\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + int \fItimeout\fP\^, \fIinterval\fP\^; +.br + int \fIprefer_blanking\fP\^; +.br + int \fIallow_exposures\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fItimeout\fP 1i +Specifies the timeout, in seconds, until the screen saver turns on. +.IP \fIinterval\fP 1i +Specifies the interval, in seconds, between screen saver alterations. +.IP \fIprefer_blanking\fP 1i +Specifies how to enable screen blanking. +You can pass +.PN DontPreferBlanking , +.PN PreferBlanking , +or +.PN DefaultBlanking . +.IP \fIallow_exposures\fP 1i +Specifies the screen save control values. +You can pass +.PN DontAllowExposures , +.PN AllowExposures , +or +.PN DefaultExposures . +.LP +.eM +Timeout and interval are specified in seconds. +A timeout of 0 disables the screen saver +(but an activated screen saver is not deactivated), +and a timeout of \-1 restores the default. +Other negative values generate a +.PN BadValue +error. +If the timeout value is nonzero, +.PN XSetScreenSaver +enables the screen saver. +An interval of 0 disables the random-pattern motion. +If no input from devices (keyboard, mouse, and so on) is generated +for the specified number of timeout seconds once the screen saver is enabled, +the screen saver is activated. +.LP +For each screen, +if blanking is preferred and the hardware supports video blanking, +the screen simply goes blank. +Otherwise, if either exposures are allowed or the screen can be regenerated +without sending +.PN Expose +events to clients, +the screen is tiled with the root window background tile randomly +re-origined each interval seconds. +Otherwise, the screens' state do not change, +and the screen saver is not activated. +The screen saver is deactivated, +and all screen states are restored at the next +keyboard or pointer input or at the next call to +.PN XForceScreenSaver +with mode +.PN ScreenSaverReset . +.LP +If the server-dependent screen saver method supports periodic change, +the interval argument serves as a hint about how long the change period +should be, and zero hints that no periodic change should be made. +Examples of ways to change the screen include scrambling the colormap +periodically, moving an icon image around the screen periodically, or tiling +the screen with the root window background tile, randomly re-origined +periodically. +.LP +.PN XSetScreenSaver +can generate a +.PN BadValue +error. +.LP +.sp +To force the screen saver on or off, use +.PN XForceScreenSaver . +.IN "XForceScreenSaver" "" "@DEF@" +.sM +.FD 0 +XForceScreenSaver\^(\^\fIdisplay\fP\^, \fImode\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + int \fImode\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fImode\fP 1i +Specifies the mode that is to be applied. +You can pass +.PN ScreenSaverActive +or +.PN ScreenSaverReset . +.LP +.eM +If the specified mode is +.PN ScreenSaverActive +and the screen saver currently is deactivated, +.PN XForceScreenSaver +activates the screen saver even if the screen saver had been disabled +with a timeout of zero. +If the specified mode is +.PN ScreenSaverReset +and the screen saver currently is enabled, +.PN XForceScreenSaver +deactivates the screen saver if it was activated, +and the activation timer is reset to its initial state +(as if device input had been received). +.LP +.PN XForceScreenSaver +can generate a +.PN BadValue +error. +.LP +.sp +To activate the screen saver, use +.PN XActivateScreenSaver . +.IN "XActivateScreenSaver" "" "@DEF@" +.sM +.FD 0 +XActivateScreenSaver\^(\^\fIdisplay\fP\^) +.br + Display *\fIdisplay\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.LP +.eM +.sp +To reset the screen saver, use +.PN XResetScreenSaver . +.IN "XResetScreenSaver" "" "@DEF@" +.sM +.FD 0 +XResetScreenSaver\^(\^\fIdisplay\fP\^) +.br + Display *\fIdisplay\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.LP +.eM +.sp +To get the current screen saver values, use +.PN XGetScreenSaver . +.IN "XGetScreenSaver" "" "@DEF@" +.sM +.FD 0 +XGetScreenSaver\^(\^\fIdisplay\fP, \fItimeout_return\fP\^, \fIinterval_return\fP\^, \fIprefer_blanking_return\fP\^, +.br + \fIallow_exposures_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + int *\fItimeout_return\fP\^, *\fIinterval_return\fP\^; +.br + int *\fIprefer_blanking_return\fP\^; +.br + int *\fIallow_exposures_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fItimeout_return\fP 1i +Returns the timeout, in seconds, until the screen saver turns on. +.IP \fIinterval_return\fP 1i +Returns the interval between screen saver invocations. +.IP \fIprefer_blanking_return\fP 1i +Returns the current screen blanking preference +.Pn ( DontPreferBlanking , +.PN PreferBlanking , +or +.PN DefaultBlanking ). +.IP \fIallow_exposures_return\fP 1i +Returns the current screen save control value +.Pn ( DontAllowExposures , +.PN AllowExposures , +or +.PN DefaultExposures ). +.LP +.eM +.NH 2 +Controlling Host Access +.XS +\*(SN Controlling Host Access +.XE +.LP +This section discusses how to: +.IP \(bu 5 +Add, get, or remove hosts from the access control list +.IP \(bu 5 +Change, enable, or disable access +.LP +.IN "Access control list" +.IN "Authentication" +X does not provide any protection on a per-window basis. +If you find out the resource ID of a resource, you can manipulate it. +To provide some minimal level of protection, however, +connections are permitted only from machines you trust. +This is adequate on single-user workstations but obviously +breaks down on timesharing machines. +Although provisions exist in the X protocol for proper connection +authentication, the lack of a standard authentication server +leaves host-level access control as the only common mechanism. +.LP +.IN "Default Protection" +The initial set of hosts allowed to open connections typically consists of: +.IP \(bu 5 +The host the window system is running on. +.IP \(bu 5 +On POSIX-conformant systems, each host listed in the +.PN /etc/X?.hosts +file. +The ? indicates the number of the +display. +.IN "Files" "/etc/X?.hosts" +This file should consist of host names separated by newlines. +DECnet nodes must terminate in :: to distinguish them from Internet hosts. +.LP +If a host is not in the access control list when the access control +mechanism is enabled and if the host attempts to establish a connection, +the server refuses the connection. +To change the access list, +the client must reside on the same host as the server and/or must +have been granted permission in the initial authorization at connection +setup. +.LP +Servers also can implement other access control policies in addition to +or in place of this host access facility. +For further information about other access control implementations, +see ``X Window System Protocol.'' +.NH 3 +Adding, Getting, or Removing Hosts +.XS +\*(SN Adding, Getting, or Removing Hosts +.XE +.LP +Xlib provides functions that you can use to add, get, or remove hosts +from the access control list. +All the host access control functions use the +.PN XHostAddress +structure, which contains: +.LP +.IN "XHostAddress" "" "@DEF@" +.sM +.Ds 0 +.TA .5i 3i +.ta .5i 3i +typedef struct { + int family; /* for example FamilyInternet */ + int length; /* length of address, in bytes */ + char *address; /* pointer to where to find the address */ +} XHostAddress; +.De +.LP +.eM +The family member specifies which protocol address family to use +(for example, TCP/IP or DECnet) and can be +.PN FamilyInternet , +.PN FamilyInternet6 , +.PN FamilyServerInterpreted , +.PN FamilyDECnet , +or +.PN FamilyChaos . +The length member specifies the length of the address in bytes. +The address member specifies a pointer to the address. +.LP +For TCP/IP, the address should be in network byte order. +For IP version 4 addresses, the family should be FamilyInternet +and the length should be 4 bytes. For IP version 6 addresses, the +family should be FamilyInternet6 and the length should be 16 bytes. +.LP +For the DECnet family, +the server performs no automatic swapping on the address bytes. +A Phase IV address is 2 bytes long. +The first byte contains the least significant 8 bits of the node number. +The second byte contains the most significant 2 bits of the +node number in the least significant 2 bits of the byte +and the area in the most significant 6 bits of the byte. +.LP +For the ServerInterpreted family, the length is ignored and the address +member is a pointer to a +.PN XServerInterpretedAddress +structure, which contains: +.LP +.IN "XServerInterpretedAddress" "" "@DEF@" +.sM +.Ds 0 +.TA .5i 3i +.ta .5i 3i +typedef struct { + int typelength; /* length of type string, in bytes */ + int valuelength;/* length of value string, in bytes */ + char *type; /* pointer to where to find the type string */ + char *value; /* pointer to where to find the address */ +} XServerInterpretedAddress; +.De +.LP +.eM +The type and value members point to strings representing the type and value of +the server interpreted entry. These strings may not be NULL-terminated so care +should be used when accessing them. The typelength and valuelength members +specify the length in byte of the type and value strings. +.LP +.sp +To add a single host, use +.PN XAddHost . +.IN "XAddHost" "" "@DEF@" +.sM +.FD 0 +XAddHost\^(\^\fIdisplay\fP, \fIhost\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + XHostAddress *\fIhost\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.ds Ho added +.IP \fIhost\fP 1i +Specifies the host that is to be \*(Ho. +.LP +.eM +The +.PN XAddHost +function adds the specified host to the access control list for that display. +The server must be on the same host as the client issuing the command, or a +.PN BadAccess +error results. +.LP +.PN XAddHost +can generate +.PN BadAccess +and +.PN BadValue +errors. +.LP +.sp +To add multiple hosts at one time, use +.PN XAddHosts . +.IN "XAddHosts" "" "@DEF@" +.sM +.FD 0 +XAddHosts\^(\^\fIdisplay\fP, \fIhosts\fP, \fInum_hosts\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + XHostAddress *\fIhosts\fP\^; +.br + int \fInum_hosts\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.ds Ho added +.IP \fIhosts\fP 1i +Specifies each host that is to be \*(Ho. +.IP \fInum_hosts\fP 1i +Specifies the number of hosts. +.LP +.eM +The +.PN XAddHosts +function adds each specified host to the access control list for that display. +The server must be on the same host as the client issuing the command, or a +.PN BadAccess +error results. +.LP +.PN XAddHosts +can generate +.PN BadAccess +and +.PN BadValue +errors. +.LP +.sp +To obtain a host list, use +.PN XListHosts . +.IN "XListHosts" "" "@DEF@" +.sM +.FD 0 +XHostAddress *XListHosts\^(\^\fIdisplay\fP, \fInhosts_return\fP, \fIstate_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + int *\fInhosts_return\fP\^; +.br + Bool *\fIstate_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fInhosts_return\fP 1i +Returns the number of hosts currently in the access control list. +.IP \fIstate_return\fP 1i +Returns the state of the access control. +.LP +.eM +The +.PN XListHosts +function returns the current access control list as well as whether the use +of the list at connection setup was enabled or disabled. +.PN XListHosts +allows a program to find out what machines can make connections. +It also returns a pointer to a list of host structures that +were allocated by the function. +When no longer needed, +this memory should be freed by calling +.PN XFree . +.LP +.sp +To remove a single host, use +.PN XRemoveHost . +.IN "XRemoveHost" "" "@DEF@" +.sM +.FD 0 +XRemoveHost\^(\^\fIdisplay\fP, \fIhost\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + XHostAddress *\fIhost\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.ds Ho removed +.IP \fIhost\fP 1i +Specifies the host that is to be \*(Ho. +.LP +.eM +The +.PN XRemoveHost +function removes the specified host from the access control list +for that display. +The server must be on the same host as the client process, or a +.PN BadAccess +error results. +If you remove your machine from the access list, +you can no longer connect to that server, +and this operation cannot be reversed unless you reset the server. +.LP +.PN XRemoveHost +can generate +.PN BadAccess +and +.PN BadValue +errors. +.LP +.sp +To remove multiple hosts at one time, use +.PN XRemoveHosts . +.IN "XRemoveHosts" "" "@DEF@" +.sM +.FD 0 +XRemoveHosts\^(\^\fIdisplay\fP, \fIhosts\fP, \fInum_hosts\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + XHostAddress *\fIhosts\fP\^; +.br + int \fInum_hosts\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.ds Ho removed +.IP \fIhosts\fP 1i +Specifies each host that is to be \*(Ho. +.IP \fInum_hosts\fP 1i +Specifies the number of hosts. +.LP +.eM +The +.PN XRemoveHosts +function removes each specified host from the access control list for that +display. +The X server must be on the same host as the client process, or a +.PN BadAccess +error results. +If you remove your machine from the access list, +you can no longer connect to that server, +and this operation cannot be reversed unless you reset the server. +.LP +.PN XRemoveHosts +can generate +.PN BadAccess +and +.PN BadValue +errors. +.NH 3 +Changing, Enabling, or Disabling Access Control +.XS +\*(SN Changing, Enabling, or Disabling Access Control +.XE +.LP +Xlib provides functions that you can use to enable, disable, +or change access control. +.LP +For these functions to execute successfully, +the client application must reside on the same host as the X server +and/or have been given permission in the initial authorization +at connection setup. +.LP +.sp +To change access control, use +.PN XSetAccessControl . +.IN "XSetAccessControl" "" "@DEF@" +.sM +.FD 0 +XSetAccessControl\^(\^\fIdisplay\fP, \fImode\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + int \fImode\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fImode\fP 1i +Specifies the mode. +You can pass +.PN EnableAccess +or +.PN DisableAccess . +.LP +.eM +The +.PN XSetAccessControl +function either enables or disables the use of the access control list +at each connection setup. +.LP +.PN XSetAccessControl +can generate +.PN BadAccess +and +.PN BadValue +errors. +.LP +.sp +To enable access control, use +.PN XEnableAccessControl . +.IN "XEnableAccessControl" "" "@DEF@" +.sM +.FD 0 +XEnableAccessControl\^(\^\fIdisplay\fP\^) +.br + Display *\fIdisplay\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.LP +.eM +The +.PN XEnableAccessControl +function enables the use of the access control list at each connection setup. +.LP +.PN XEnableAccessControl +can generate a +.PN BadAccess +error. +.LP +.sp +To disable access control, use +.PN XDisableAccessControl . +.IN "XDisableAccessControl" "" "@DEF@" +.sM +.FD 0 +XDisableAccessControl\^(\^\fIdisplay\fP\^) +.br + Display *\fIdisplay\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.LP +.eM +The +.PN XDisableAccessControl +function disables the use of the access control list at each connection setup. +.LP +.PN XDisableAccessControl +can generate a +.PN BadAccess +error. +.bp diff --git a/libX11/specs/libX11/CH10 b/libX11/specs/libX11/CH10 new file mode 100644 index 000000000..76502fb9e --- /dev/null +++ b/libX11/specs/libX11/CH10 @@ -0,0 +1,3886 @@ +.\" Copyright \(co 1985, 1986, 1987, 1988, 1989, 1990, 1991, 1994, 1996 X Consortium +.\" +.\" 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 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 X CONSORTIUM 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 X Consortium 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 X Consortium. +.\" +.\" Copyright \(co 1985, 1986, 1987, 1988, 1989, 1990, 1991 by +.\" Digital Equipment Corporation +.\" +.\" Portions Copyright \(co 1990, 1991 by +.\" Tektronix, Inc. +.\" +.\" Permission to use, copy, modify and distribute this documentation for +.\" any purpose and without fee is hereby granted, provided that the above +.\" copyright notice appears in all copies and that both that copyright notice +.\" and this permission notice appear in all copies, and that the names of +.\" Digital and Tektronix not be used in in advertising or publicity pertaining +.\" to this documentation without specific, written prior permission. +.\" Digital and Tektronix makes no representations about the suitability +.\" of this documentation for any purpose. +.\" It is provided ``as is'' without express or implied warranty. +.\" +\& +.sp 1 +.ce 3 +\s+1\fBChapter 10\fP\s-1 + +\s+1\fBEvents\fP\s-1 +.sp 2 +.nr H1 10 +.nr H2 0 +.nr H3 0 +.nr H4 0 +.nr H5 0 +.na +.LP +.XS +Chapter 10: Events +.XE +A client application communicates with the X server through the connection you +establish with the +.PN XOpenDisplay +.IN "XOpenDisplay" +function. +A client application sends requests to the X server over this connection. +.IN "Requests" "" "@DEF@" +These requests are made by the Xlib functions that are +called in the client application. +Many Xlib functions cause the X server to generate events, +and the user's typing or moving the pointer can generate events asynchronously. +The X server returns events to the client on the same connection. +.LP +This chapter discusses the following topics associated with events: +.IP \(bu 5 +Event types +.IP \(bu 5 +Event structures +.IP \(bu 5 +Event masks +.IP \(bu 5 +Event processing +.LP +Functions for handling events are dealt with in the next chapter. +.NH 2 +Event Types +.XS +\*(SN Event Types +.XE +.LP +.IN "Event" "types" +An event is data generated asynchronously by the X server as a result of some +device activity or as side effects of a request sent by an Xlib function. +.IN "Event" +Device-related events propagate from the source window to ancestor windows +until some client application has selected that event type +or until the event is explicitly discarded. +The X server generally sends an event to a client application +only if the client has specifically asked to be informed of that event type, +typically by setting the event-mask attribute of the window. +The mask can also be set when you create a window +or by changing the window's +event-mask. +You can also mask out events that would propagate to ancestor windows +by manipulating the +do-not-propagate mask of the window's attributes. +However, +.PN MappingNotify +events are always sent to all clients. +.IN "Input Control" +.IN "Output Control" +.LP +An event type describes a specific event generated by the X server. +For each event type, +a corresponding constant name is defined in +.hN X11/X.h , +which is used when referring to an event type. +.IN "Event" "categories" +The following table lists the event category +and its associated event type or types. +The processing associated with these events is discussed in section 10.5. +.LP +.\".CP T 1 +.\"Event Categories and Event Types +.LP +.TS H +lw(2.25i) lw(3.5i). +_ +.sp 6p +.B +Event Category Event Type +.sp 6p +_ +.sp 6p +.TH +.R +T{ +Keyboard events +T} T{ +.PN KeyPress , +.PN KeyRelease +T} +.sp 6p +T{ +Pointer events +T} T{ +.PN ButtonPress , +.PN ButtonRelease , +.PN MotionNotify +T} +.sp 6p +T{ +Window crossing events +T} T{ +.PN EnterNotify , +.PN LeaveNotify +T} +.sp 6p +T{ +Input focus events +T} T{ +.PN FocusIn , +.PN FocusOut +T} +.sp 6p +T{ +Keymap state notification event +T} T{ +.PN KeymapNotify +T} +.sp 6p +T{ +Exposure events +T} T{ +.PN Expose , +.PN GraphicsExpose , +.PN NoExpose +T} +.sp 6p +T{ +Structure control events +T} T{ +.PN CirculateRequest , +.PN ConfigureRequest , +.PN MapRequest , +.PN ResizeRequest +T} +.sp 6p +T{ +Window state notification events +T} T{ +.PN CirculateNotify , +.PN ConfigureNotify , +.PN CreateNotify , +.PN DestroyNotify , +.PN GravityNotify , +.PN MapNotify , +.PN MappingNotify , +.PN ReparentNotify , +.PN UnmapNotify , +.br +.PN VisibilityNotify +T} +.sp 6p +T{ +Colormap state notification event +T} T{ +.PN ColormapNotify +T} +.sp 6p +T{ +Client communication events +T} T{ +.PN ClientMessage , +.PN PropertyNotify , +.PN SelectionClear , +.PN SelectionNotify , +.PN SelectionRequest +T} +.sp 6p +_ +.TE +.\".LP +.\"Table 8-1 lists the event types and the Xlib functions that could cause +.\"the X server to generate that event type. +.\"The event types are listed alphabetically. +.\"Note that the error event is not listed in this table. +.\"For a list of the constants associated with an error event, see the Handling +.\"Errors section in this chapter. +.\".LP +.\".so eventtable +.NH 2 +Event Structures +.XS +\*(SN Event Structures +.XE +.LP +For each event type, +a corresponding structure is declared in +.hN X11/Xlib.h . +All the event structures have the following common members: +.LP +.IN "XAnyEvent" "" "@DEF@" +.sM +.Ds 0 +.TA .5i 3i +.ta .5i 3i +typedef struct { + int type; + unsigned long serial; /* # of last request processed by server */ + Bool send_event; /* true if this came from a SendEvent request */ + Display *display; /* Display the event was read from */ + Window window; +} XAnyEvent; +.De +.LP +.eM +The type member is set to the event type constant name that uniquely identifies +it. +For example, when the X server reports a +.PN GraphicsExpose +event to a client application, it sends an +.PN XGraphicsExposeEvent +structure with the type member set to +.PN GraphicsExpose . +The display member is set to a pointer to the display the event was read on. +The send_event member is set to +.PN True +if the event came from a +.PN SendEvent +protocol request. +The serial member is set from the serial number reported in the protocol +but expanded from the 16-bit least-significant bits to a full 32-bit value. +The window member is set to the window that is most useful to toolkit +dispatchers. +.LP +The X server can send events at any time in the input stream. +Xlib stores any events received while waiting for a reply in an event queue +for later use. +Xlib also provides functions that allow you to check events +in the event queue (see section 11.3). +.LP +In addition to the individual structures declared for each event type, the +.PN XEvent +structure is a union of the individual structures declared for each event type. +Depending on the type, +you should access members of each event by using the +.PN XEvent +union. +.LP +.IN "XEvent" "" "@DEF@" +.sM +.Ds 0 +.TA .5i 3i +.ta .5i 3i +typedef union _XEvent { + int type; /* must not be changed */ + XAnyEvent xany; + XKeyEvent xkey; + XButtonEvent xbutton; + XMotionEvent xmotion; + XCrossingEvent xcrossing; + XFocusChangeEvent xfocus; + XExposeEvent xexpose; + XGraphicsExposeEvent xgraphicsexpose; + XNoExposeEvent xnoexpose; + XVisibilityEvent xvisibility; + XCreateWindowEvent xcreatewindow; + XDestroyWindowEvent xdestroywindow; + XUnmapEvent xunmap; + XMapEvent xmap; + XMapRequestEvent xmaprequest; + XReparentEvent xreparent; + XConfigureEvent xconfigure; + XGravityEvent xgravity; + XResizeRequestEvent xresizerequest; + XConfigureRequestEvent xconfigurerequest; + XCirculateEvent xcirculate; + XCirculateRequestEvent xcirculaterequest; + XPropertyEvent xproperty; + XSelectionClearEvent xselectionclear; + XSelectionRequestEvent xselectionrequest; + XSelectionEvent xselection; + XColormapEvent xcolormap; + XClientMessageEvent xclient; + XMappingEvent xmapping; + XErrorEvent xerror; + XKeymapEvent xkeymap; + long pad[24]; +} XEvent; +.De +.LP +.eM +An +.PN XEvent +structure's first entry always is the type member, +which is set to the event type. +The second member always is the serial number of the protocol request +that generated the event. +The third member always is send_event, +which is a +.PN Bool +that indicates if the event was sent by a different client. +The fourth member always is a display, +which is the display that the event was read from. +Except for keymap events, +the fifth member always is a window, +which has been carefully selected to be useful to toolkit dispatchers. +To avoid breaking toolkits, +the order of these first five entries is not to change. +Most events also contain a time member, +which is the time at which an event occurred. +In addition, a pointer to the generic event must be cast before it +is used to access any other information in the structure. +.NH 2 +Event Masks +.XS +\*(SN Event Masks +.XE +.LP +.IN "Event mask" "" "@DEF@" +Clients select event reporting of most events relative to a window. +To do this, pass an event mask to an Xlib event-handling +function that takes an event_mask argument. +The bits of the event mask are defined in +.hN X11/X.h . +Each bit in the event mask maps to an event mask name, +which describes the event or events you want the X server to +return to a client application. +.LP +Unless the client has specifically asked for them, +most events are not reported to clients when they are generated. +Unless the client suppresses them by setting graphics-exposures in the GC to +.PN False , +.PN GraphicsExpose +and +.PN NoExpose +are reported by default as a result of +.PN XCopyPlane +and +.PN XCopyArea . +.PN SelectionClear , +.PN SelectionRequest , +.PN SelectionNotify , +or +.PN ClientMessage +cannot be masked. +Selection-related events are only sent to clients cooperating +with selections (see section 4.5). +When the keyboard or pointer mapping is changed, +.PN MappingNotify +is always sent to clients. +.LP +.\"Table 8-2 +The following table +lists the event mask constants you can pass to +the event_mask argument and +the circumstances in which you would want to specify the +event mask: +.LP +.\" .CP T 2 +.\"Event Mask Definitions +.TS H +lw(2i) lw(3.5i). +_ +.sp 6p +.B +Event Mask Circumstances +.sp 6p +_ +.sp 6p +.TH +.R +T{ +.PN NoEventMask +T} T{ +No events wanted +T} +T{ +.PN KeyPressMask +T} T{ +Keyboard down events wanted +T} +T{ +.PN KeyReleaseMask +T} T{ +Keyboard up events wanted +T} +T{ +.PN ButtonPressMask +T} T{ +Pointer button down events wanted +T} +T{ +.PN ButtonReleaseMask +T} T{ +Pointer button up events wanted +T} +T{ +.PN EnterWindowMask +T} T{ +Pointer window entry events wanted +T} +T{ +.PN LeaveWindowMask +T} T{ +Pointer window leave events wanted +T} +T{ +.PN PointerMotionMask +T} T{ +Pointer motion events wanted +T} +T{ +.PN PointerMotionHintMask +T} T{ +Pointer motion hints wanted +T} +T{ +.PN Button1MotionMask +T} T{ +Pointer motion while button 1 down +T} +T{ +.PN Button2MotionMask +T} T{ +Pointer motion while button 2 down +T} +T{ +.PN Button3MotionMask +T} T{ +Pointer motion while button 3 down +T} +T{ +.PN Button4MotionMask +T} T{ +Pointer motion while button 4 down +T} +T{ +.PN Button5MotionMask +T} T{ +Pointer motion while button 5 down +T} +T{ +.PN ButtonMotionMask +T} T{ +Pointer motion while any button down +T} +T{ +.PN KeymapStateMask +T} T{ +Keyboard state wanted at window entry and focus in +T} +T{ +.PN ExposureMask +T} T{ +Any exposure wanted +T} +T{ +.PN VisibilityChangeMask +T} T{ +Any change in visibility wanted +T} +T{ +.PN StructureNotifyMask +T} T{ +Any change in window structure wanted +T} +T{ +.PN ResizeRedirectMask +T} T{ +Redirect resize of this window +T} +T{ +.PN SubstructureNotifyMask +T} T{ +Substructure notification wanted +T} +T{ +.PN SubstructureRedirectMask +T} T{ +Redirect structure requests on children +T} +T{ +.PN FocusChangeMask +T} T{ +Any change in input focus wanted +T} +T{ +.PN PropertyChangeMask +T} T{ +Any change in property wanted +T} +T{ +.PN ColormapChangeMask +T} T{ +Any change in colormap wanted +T} +T{ +.PN OwnerGrabButtonMask +T} T{ +Automatic grabs should activate with owner_events set to +.PN True +T} +.sp 6p +_ +.TE +.LP +.NH 2 +Event Processing Overview +.XS +\*(SN Event Processing Overview +.XE +.LP +The event reported to a client application during event processing +depends on which event masks you provide as the event-mask attribute +for a window. +For some event masks, there is a one-to-one correspondence between +the event mask constant and the event type constant. +For example, if you pass the event mask +.PN ButtonPressMask , +the X server sends back only +.PN ButtonPress +events. +.IN "CurrentTime" +Most events contain a time member, +which is the time at which an event occurred. +.LP +In other cases, one event mask constant can map to several event type constants. +For example, if you pass the event mask +.PN SubstructureNotifyMask , +the X server can send back +.PN CirculateNotify , +.PN ConfigureNotify , +.PN CreateNotify , +.PN DestroyNotify , +.PN GravityNotify , +.PN MapNotify , +.PN ReparentNotify , +or +.PN UnmapNotify +events. +.LP +In another case, +two event masks can map to one event type. +For example, +if you pass either +.PN PointerMotionMask +or +.PN ButtonMotionMask , +the X server sends back +a +.PN MotionNotify +event. +.LP +The following table +lists the event mask, +its associated event type or types, +and the structure name associated with the event type. +Some of these structures actually are typedefs to a generic structure +that is shared between two event types. +Note that N.A. appears in columns for which the information is not applicable. +.LP +.ps 9 +.nr PS 9 +.TS H +lw(1.5i) lw(1i) lw(1.5i) lw(1.5i). +_ +.sp 6p +.B +Event Mask Event Type Structure Generic Structure +.sp 6p +_ +.sp 6p +.TH +.R +ButtonMotionMask MotionNotify XPointerMovedEvent XMotionEvent +Button1MotionMask +Button2MotionMask +Button3MotionMask +Button4MotionMask +Button5MotionMask +.sp 6p +ButtonPressMask ButtonPress XButtonPressedEvent XButtonEvent +.sp 6p +ButtonReleaseMask ButtonRelease XButtonReleasedEvent XButtonEvent +.sp 6p +ColormapChangeMask ColormapNotify XColormapEvent +.sp 6p +EnterWindowMask EnterNotify XEnterWindowEvent XCrossingEvent +.sp 6p +LeaveWindowMask LeaveNotify XLeaveWindowEvent XCrossingEvent +.sp 6p +ExposureMask Expose XExposeEvent +GCGraphicsExposures in GC GraphicsExpose XGraphicsExposeEvent + NoExpose XNoExposeEvent +.sp 6p +FocusChangeMask FocusIn XFocusInEvent XFocusChangeEvent + FocusOut XFocusOutEvent XFocusChangeEvent +.sp 6p +KeymapStateMask KeymapNotify XKeymapEvent +.sp 6p +KeyPressMask KeyPress XKeyPressedEvent XKeyEvent +KeyReleaseMask KeyRelease XKeyReleasedEvent XKeyEvent +.sp 6p +OwnerGrabButtonMask N.A. N.A. +.sp 6p +PointerMotionMask MotionNotify XPointerMovedEvent XMotionEvent +PointerMotionHintMask N.A. N.A. +.sp 6p +PropertyChangeMask PropertyNotify XPropertyEvent +.sp 6p +ResizeRedirectMask ResizeRequest XResizeRequestEvent +.sp 6p +StructureNotifyMask CirculateNotify XCirculateEvent + ConfigureNotify XConfigureEvent + DestroyNotify XDestroyWindowEvent + GravityNotify XGravityEvent + MapNotify XMapEvent + ReparentNotify XReparentEvent + UnmapNotify XUnmapEvent +.sp 6p +SubstructureNotifyMask CirculateNotify XCirculateEvent + ConfigureNotify XConfigureEvent + CreateNotify XCreateWindowEvent + DestroyNotify XDestroyWindowEvent + GravityNotify XGravityEvent + MapNotify XMapEvent + ReparentNotify XReparentEvent + UnmapNotify XUnmapEvent +.sp 6p +SubstructureRedirectMask CirculateRequest XCirculateRequestEvent + ConfigureRequest XConfigureRequestEvent + MapRequest XMapRequestEvent +.sp 6p +N.A. ClientMessage XClientMessageEvent +.sp 6p +N.A. MappingNotify XMappingEvent +.sp 6p +N.A. SelectionClear XSelectionClearEvent +.sp 6p +N.A. SelectionNotify XSelectionEvent +.sp 6p +N.A. SelectionRequest XSelectionRequestEvent +.sp 6p +VisibilityChangeMask VisibilityNotify XVisibilityEvent +.sp 6p +_ +.TE +.ps 11 +.nr PS 11 +.LP +The sections that follow describe the processing that occurs +when you select the different event masks. +The sections are organized according to these processing categories: +.IP \(bu 5 +Keyboard and pointer events +.IP \(bu 5 +Window crossing events +.IP \(bu 5 +Input focus events +.IP \(bu 5 +Keymap state notification events +.IP \(bu 5 +Exposure events +.IP \(bu 5 +Window state notification events +.IP \(bu 5 +Structure control events +.IP \(bu 5 +Colormap state notification events +.IP \(bu 5 +Client communication events +.NH 2 +Keyboard and Pointer Events +.XS +\*(SN Keyboard and Pointer Events +.XE +.LP +This section discusses: +.IP \(bu 5 +Pointer button events +.IP \(bu 5 +Keyboard and pointer events +.NH 3 +Pointer Button Events +.XS +\*(SN Pointer Button Events +.XE +.LP +The following describes the event processing that occurs when a pointer button +press is processed with the pointer in some window w and +when no active pointer grab is in progress. +.LP +The X server searches the ancestors of w from the root down, +looking for a passive grab to activate. +If no matching passive grab on the button exists, +the X server automatically starts an active grab for the client receiving +the event and sets the last-pointer-grab time to the current server time. +The effect is essentially equivalent to an +.PN XGrabButton +with these client passed arguments: +.TS H +lw(1.5i) lw(3.5i). +_ +.sp 6p +.B +Argument Value +.sp 6p +_ +.sp 6p +.TH +.R +T{ +\fIw\fP +T} T{ +The event window +T} +T{ +\fIevent_mask\fP +T} T{ +The client's selected pointer events on the event window +T} +T{ +\fIpointer_mode\fP +T} T{ +.PN GrabModeAsync +T} +T{ +\fIkeyboard_mode\fP +T} T{ +.PN GrabModeAsync +T} +T{ +\fIowner_events\fP +T} T{ +.PN True , +if the client has selected +.PN OwnerGrabButtonMask +on the event window, +otherwise +.PN False +T} +T{ +\fIconfine_to\fP +T} T{ +.PN None +T} +T{ +\fIcursor\fP +T} T{ +.PN None +T} +.sp 6p +_ +.TE +.LP +The active grab is automatically terminated when +the logical state of the pointer has all buttons released. +Clients can modify the active grab by calling +.PN XUngrabPointer +and +.PN XChangeActivePointerGrab . +.NH 3 +Keyboard and Pointer Events +.XS +\*(SN Keyboard and Pointer Events +.XE +.LP +.IN "Events" "ButtonPress" +.IN "Events" "ButtonRelease" +.IN "Events" "KeyPress" +.IN "Events" "KeyRelease" +.IN "Events" "MotionNotify" +This section discusses the processing that occurs for the +keyboard events +.PN KeyPress +and +.PN KeyRelease +and the pointer events +.PN ButtonPress , +.PN ButtonRelease , +and +.PN MotionNotify . +For information about the keyboard event-handling utilities, +see chapter 11. +.LP +.IN "KeyPress" "" "@DEF@" +.IN "KeyRelease" "" "@DEF@" +The X server reports +.PN KeyPress +or +.PN KeyRelease +events to clients wanting information about keys that logically change state. +Note that these events are generated for all keys, +even those mapped to modifier bits. +.IN "ButtonPress" "" "@DEF@" +.IN "ButtonRelease" "" "@DEF@" +The X server reports +.PN ButtonPress +or +.PN ButtonRelease +events to clients wanting information about buttons that logically change state. +.LP +.IN "MotionNotify" "" "@DEF@" +The X server reports +.PN MotionNotify +events to clients wanting information about when the pointer logically moves. +The X server generates this event whenever the pointer is moved +and the pointer motion begins and ends in the window. +The granularity of +.PN MotionNotify +events is not guaranteed, +but a client that selects this event type is guaranteed +to receive at least one event when the pointer moves and then rests. +.LP +The generation of the logical changes lags the physical changes +if device event processing is frozen. +.LP +To receive +.PN KeyPress , +.PN KeyRelease , +.PN ButtonPress , +and +.PN ButtonRelease +events, set +.PN KeyPressMask , +.PN KeyReleaseMask , +.PN ButtonPressMask , +and +.PN ButtonReleaseMask +bits in the event-mask attribute of the window. +.LP +To receive +.PN MotionNotify +events, set one or more of the following event +masks bits in the event-mask attribute of the window. +.IP \(bu 5 +.PN Button1MotionMask \ \- +.PN Button5MotionMask +.IP +The client application receives +.PN MotionNotify +events only when one or more of the specified buttons is pressed. +.IP \(bu 5 +.PN ButtonMotionMask +.IP +The client application receives +.PN MotionNotify +events only when at least one button is pressed. +.IP \(bu 5 +.PN PointerMotionMask +.IP +The client application receives +.PN MotionNotify +events independent of the state of +the pointer buttons. +.IP \(bu 5 +.PN PointerMotionHintMask +.IP +If +.PN PointerMotionHintMask +is selected in combination with one or more of the above masks, +the X server is free to send only one +.PN MotionNotify +event (with the is_hint member of the +.PN XPointerMovedEvent +structure set to +.PN NotifyHint ) +to the client for the event window, +until either the key or button state changes, +the pointer leaves the event window, or the client calls +.PN XQueryPointer +or +.PN XGetMotionEvents . +The server still may send +.PN MotionNotify +events without is_hint set to +.PN NotifyHint . +.LP +The source of the event is the viewable window that the pointer is in. +The window used by the X server to report these events depends on +the window's position in the window hierarchy +and whether any intervening window prohibits the generation of these events. +Starting with the source window, +the X server searches up the window hierarchy until it locates the first +window specified by a client as having an interest in these events. +If one of the intervening windows has its do-not-propagate-mask +set to prohibit generation of the event type, +the events of those types will be suppressed. +Clients can modify the actual window used for reporting by performing +active grabs and, in the case of keyboard events, by using the focus window. +.LP +The structures for these event types contain: +.LP +.IN "XButtonEvent" "" "@DEF@" +.IN "XButtonPressedEvent" "" "@DEF@" +.IN "XButtonReleasedEvent" "" "@DEF@" +.sM +.Ds 0 +.TA .5i 3i +.ta .5i 3i +typedef struct { + int type; /* ButtonPress or ButtonRelease */ + unsigned long serial; /* # of last request processed by server */ + Bool send_event; /* true if this came from a SendEvent request */ + Display *display; /* Display the event was read from */ + Window window; /* ``event'' window it is reported relative to */ + Window root; /* root window that the event occurred on */ + Window subwindow; /* child window */ + Time time; /* milliseconds */ + int x, y; /* pointer x, y coordinates in event window */ + int x_root, y_root; /* coordinates relative to root */ + unsigned int state; /* key or button mask */ + unsigned int button; /* detail */ + Bool same_screen; /* same screen flag */ +} XButtonEvent; +typedef XButtonEvent XButtonPressedEvent; +typedef XButtonEvent XButtonReleasedEvent; +.De +.LP +.IN "XKeyEvent" "" "@DEF@" +.IN "XKeyPressedEvent" "" "@DEF@" +.IN "XKeyReleasedEvent" "" "@DEF@" +.Ds 0 +.TA .5i 3i +.ta .5i 3i +typedef struct { + int type; /* KeyPress or KeyRelease */ + unsigned long serial; /* # of last request processed by server */ + Bool send_event; /* true if this came from a SendEvent request */ + Display *display; /* Display the event was read from */ + Window window; /* ``event'' window it is reported relative to */ + Window root; /* root window that the event occurred on */ + Window subwindow; /* child window */ + Time time; /* milliseconds */ + int x, y; /* pointer x, y coordinates in event window */ + int x_root, y_root; /* coordinates relative to root */ + unsigned int state; /* key or button mask */ + unsigned int keycode; /* detail */ + Bool same_screen; /* same screen flag */ +} XKeyEvent; +typedef XKeyEvent XKeyPressedEvent; +typedef XKeyEvent XKeyReleasedEvent; +.De +.LP +.IN "XMotionEvent" "" "@DEF@" +.IN "XPointerMovedEvent" "" "@DEF@" +.Ds 0 +.TA .5i 3i +.ta .5i 3i +typedef struct { + int type; /* MotionNotify */ + unsigned long serial; /* # of last request processed by server */ + Bool send_event; /* true if this came from a SendEvent request */ + Display *display; /* Display the event was read from */ + Window window; /* ``event'' window reported relative to */ + Window root; /* root window that the event occurred on */ + Window subwindow; /* child window */ + Time time; /* milliseconds */ + int x, y; /* pointer x, y coordinates in event window */ + int x_root, y_root; /* coordinates relative to root */ + unsigned int state; /* key or button mask */ + char is_hint; /* detail */ + Bool same_screen; /* same screen flag */ +} XMotionEvent; +typedef XMotionEvent XPointerMovedEvent; +.De +.LP +.eM +These structures have the following common members: +window, root, subwindow, time, x, y, x_root, y_root, state, and same_screen. +The window member is set to the window on which the +event was generated and is referred to as the event window. +As long as the conditions previously discussed are met, +this is the window used by the X server to report the event. +The root member is set to the source window's root window. +The x_root and y_root members are set to the pointer's coordinates +relative to the root window's origin at the time of the event. +.LP +The same_screen member is set to indicate whether the event +window is on the same screen +as the root window and can be either +.PN True +or +.PN False . +If +.PN True , +the event and root windows are on the same screen. +If +.PN False , +the event and root windows are not on the same screen. +.LP +If the source window is an inferior of the event window, +the subwindow member of the structure is set to the child of the event window +that is the source window or the child of the event window that is +an ancestor of the source window. +Otherwise, the X server sets the subwindow member to +.PN None . +The time member is set to the time when the event was generated +and is expressed in milliseconds. +.LP +If the event window is on the same screen as the root window, +the x and y members +are set to the coordinates relative to the event window's origin. +Otherwise, these members are set to zero. +.LP +The state member is set to indicate the logical state of the pointer buttons +and modifier keys just prior to the event, +which is the bitwise inclusive OR of one or more of the +button or modifier key masks: +.PN Button1Mask , +.PN Button2Mask , +.PN Button3Mask , +.PN Button4Mask , +.PN Button5Mask , +.PN ShiftMask , +.PN LockMask , +.PN ControlMask , +.PN Mod1Mask , +.PN Mod2Mask , +.PN Mod3Mask , +.PN Mod4Mask , +and +.PN Mod5Mask . +.LP +Each of these structures also has a member that indicates the detail. +For the +.PN XKeyPressedEvent +and +.PN XKeyReleasedEvent +structures, this member is called a keycode. +It is set to a number that represents a physical key on the keyboard. +The keycode is an arbitrary representation for any key on the keyboard +(see sections 12.7 and 16.1). +.LP +For the +.PN XButtonPressedEvent +and +.PN XButtonReleasedEvent +structures, this member is called button. +It represents the pointer button that changed state and can be the +.PN Button1 , +.PN Button2 , +.PN Button3 , +.PN Button4 , +or +.PN Button5 +value. +For the +.PN XPointerMovedEvent +structure, this member is called is_hint. +It can be set to +.PN NotifyNormal +or +.PN NotifyHint . +.LP +Some of the symbols mentioned in this section have fixed values, as +follows: +.TS H +lw(2i) lw(3.5i). +_ +.sp 6p +.B +Symbol Value +.sp 6p +_ +.sp 6p +.TH +.R +T{ +.PN Button1MotionMask +T} T{ +(1L<<8) +T} +T{ +.PN Button2MotionMask +T} T{ +(1L<<9) +T} +T{ +.PN Button3MotionMask +T} T{ +(1L<<10) +T} +T{ +.PN Button4MotionMask +T} T{ +(1L<<11) +T} +T{ +.PN Button5MotionMask +T} T{ +(1L<<12) +T} +T{ +.PN Button1Mask +T} T{ +(1<<8) +T} +T{ +.PN Button2Mask +T} T{ +(1<<9) +T} +T{ +.PN Button3Mask +T} T{ +(1<<10) +T} +T{ +.PN Button4Mask +T} T{ +(1<<11) +T} +T{ +.PN Button5Mask +T} T{ +(1<<12) +T} +T{ +.PN ShiftMask +T} T{ +(1<<0) +T} +T{ +.PN LockMask +T} T{ +(1<<1) +T} +T{ +.PN ControlMask +T} T{ +(1<<2) +T} +T{ +.PN Mod1Mask +T} T{ +(1<<3) +T} +T{ +.PN Mod2Mask +T} T{ +(1<<4) +T} +T{ +.PN Mod3Mask +T} T{ +(1<<5) +T} +T{ +.PN Mod4Mask +T} T{ +(1<<6) +T} +T{ +.PN Mod5Mask +T} T{ +(1<<7) +T} +T{ +.PN Button1 +T} T{ +1 +T} +T{ +.PN Button2 +T} T{ +2 +T} +T{ +.PN Button3 +T} T{ +3 +T} +T{ +.PN Button4 +T} T{ +4 +T} +T{ +.PN Button5 +T} T{ +5 +T} +.sp 6p +_ +.TE +.NH 2 +Window Entry/Exit Events +.XS +\*(SN Window Entry/Exit Events +.XE +.LP +.IN "Events" "EnterNotify" +.IN "Events" "LeaveNotify" +This section describes the processing that +occurs for the window crossing events +.PN EnterNotify +and +.PN LeaveNotify . +.IN "EnterNotify" "" "@DEF@" +.IN "LeaveNotify" "" "@DEF@" +If a pointer motion or a window hierarchy change causes the +pointer to be in a different window than before, the X server reports +.PN EnterNotify +or +.PN LeaveNotify +events to clients who have selected for these events. +All +.PN EnterNotify +and +.PN LeaveNotify +events caused by a hierarchy change are +generated after any hierarchy event +.Pn ( UnmapNotify , +.PN MapNotify , +.PN ConfigureNotify , +.PN GravityNotify , +.PN CirculateNotify ) +caused by that change; +however, the X protocol does not constrain the ordering of +.PN EnterNotify +and +.PN LeaveNotify +events with respect to +.PN FocusOut , +.PN VisibilityNotify , +and +.PN Expose +events. +.LP +This contrasts with +.PN MotionNotify +events, which are also generated when the pointer moves +but only when the pointer motion begins and ends in a single window. +An +.PN EnterNotify +or +.PN LeaveNotify +event also can be generated when some client application calls +.PN XGrabPointer +and +.PN XUngrabPointer . +.LP +To receive +.PN EnterNotify +or +.PN LeaveNotify +events, set the +.PN EnterWindowMask +or +.PN LeaveWindowMask +bits of the event-mask attribute of the window. +.LP +The structure for these event types contains: +.LP +.IN "XCrossingEvent" "" "@DEF@" +.IN "XEnterWindowEvent" "" "@DEF@" +.IN "XLeaveWindowEvent" "" "@DEF@" +.sM +.Ds 0 +.TA .5i 3i +.ta .5i 3i +typedef struct { + int type; /* EnterNotify or LeaveNotify */ + unsigned long serial; /* # of last request processed by server */ + Bool send_event; /* true if this came from a SendEvent request */ + Display *display; /* Display the event was read from */ + Window window; /* ``event'' window reported relative to */ + Window root; /* root window that the event occurred on */ + Window subwindow; /* child window */ + Time time; /* milliseconds */ + int x, y; /* pointer x, y coordinates in event window */ + int x_root, y_root; /* coordinates relative to root */ + int mode; /* NotifyNormal, NotifyGrab, NotifyUngrab */ + int detail; + /* + * NotifyAncestor, NotifyVirtual, NotifyInferior, + * NotifyNonlinear,NotifyNonlinearVirtual + */ + Bool same_screen; /* same screen flag */ + Bool focus; /* boolean focus */ + unsigned int state; /* key or button mask */ +} XCrossingEvent; +typedef XCrossingEvent XEnterWindowEvent; +typedef XCrossingEvent XLeaveWindowEvent; +.De +.LP +.eM +The window member is set to the window on which the +.PN EnterNotify +or +.PN LeaveNotify +event was generated and is referred to as the event window. +This is the window used by the X server to report the event, +and is relative to the root +window on which the event occurred. +The root member is set to the root window of the screen +on which the event occurred. +.LP +For a +.PN LeaveNotify +event, +if a child of the event window contains the initial position of the pointer, +the subwindow component is set to that child. +Otherwise, the X server sets the subwindow member to +.PN None . +For an +.PN EnterNotify +event, if a child of the event window contains the final pointer position, +the subwindow component is set to that child or +.PN None . +.LP +The time member is set to the time when the event was generated +and is expressed in milliseconds. +The x and y members are set to the coordinates of the pointer position in +the event window. +This position is always the pointer's final position, +not its initial position. +If the event window is on the same +screen as the root window, x and y are the pointer coordinates +relative to the event window's origin. +Otherwise, x and y are set to zero. +The x_root and y_root members are set to the pointer's coordinates relative to the +root window's origin at the time of the event. +.LP +The same_screen member is set to indicate whether the event window is on the same screen +as the root window and can be either +.PN True +or +.PN False . +If +.PN True , +the event and root windows are on the same screen. +If +.PN False , +the event and root windows are not on the same screen. +.LP +The focus member is set to indicate whether the event window is the focus window or an +inferior of the focus window. +The X server can set this member to either +.PN True +or +.PN False . +If +.PN True , +the event window is the focus window or an inferior of the focus window. +If +.PN False , +the event window is not the focus window or an inferior of the focus window. +.LP +The state member is set to indicate the state of the pointer buttons and +modifier keys just prior to the +event. +The X server can set this member to the bitwise inclusive OR of one +or more of the button or modifier key masks: +.PN Button1Mask , +.PN Button2Mask , +.PN Button3Mask , +.PN Button4Mask , +.PN Button5Mask , +.PN ShiftMask , +.PN LockMask , +.PN ControlMask , +.PN Mod1Mask , +.PN Mod2Mask , +.PN Mod3Mask , +.PN Mod4Mask , +.PN Mod5Mask . +.LP +The mode member is set to indicate whether the events are normal events, +pseudo-motion events +when a grab activates, or pseudo-motion events when a grab deactivates. +The X server can set this member to +.PN NotifyNormal , +.PN NotifyGrab , +or +.PN NotifyUngrab . +.LP +The detail member is set to indicate the notify detail and can be +.PN NotifyAncestor , +.PN NotifyVirtual , +.PN NotifyInferior , +.PN NotifyNonlinear , +or +.PN NotifyNonlinearVirtual . +.NH 3 +Normal Entry/Exit Events +.XS +\*(SN Normal Entry/Exit Events +.XE +.LP +.PN EnterNotify +and +.PN LeaveNotify +events are generated when the pointer moves from +one window to another window. +Normal events are identified by +.PN XEnterWindowEvent +or +.PN XLeaveWindowEvent +structures whose mode member is set to +.PN NotifyNormal . +.IP \(bu 5 +When the pointer moves from window A to window B and A is an inferior of B, +the X server does the following: +.RS +.IP \- 5 +It generates a +.PN LeaveNotify +event on window A, with the detail member of the +.PN XLeaveWindowEvent +structure set to +.PN NotifyAncestor . +.IP \- 5 +It generates a +.PN LeaveNotify +event on each window between window A and window B, exclusive, +with the detail member of each +.PN XLeaveWindowEvent +structure set to +.PN NotifyVirtual . +.IP \- 5 +It generates an +.PN EnterNotify +event on window B, with the detail member of the +.PN XEnterWindowEvent +structure set to +.PN NotifyInferior . +.RE +.IP \(bu 5 +When the pointer moves from window A to window B and B is an inferior of A, +the X server does the following: +.RS +.IP \- 5 +It generates a +.PN LeaveNotify +event on window A, +with the detail member of the +.PN XLeaveWindowEvent +structure set to +.PN NotifyInferior . +.IP \- 5 +It generates an +.PN EnterNotify +event on each window between window A and window B, exclusive, with the +detail member of each +.PN XEnterWindowEvent +structure set to +.PN NotifyVirtual . +.IP \- 5 +It generates an +.PN EnterNotify +event on window B, with the detail member of the +.PN XEnterWindowEvent +structure set to +.PN NotifyAncestor . +.RE +.IP \(bu 5 +When the pointer moves from window A to window B +and window C is their least common ancestor, +the X server does the following: +.RS +.IP \- 5 +It generates a +.PN LeaveNotify +event on window A, +with the detail member of the +.PN XLeaveWindowEvent +structure set to +.PN NotifyNonlinear . +.IP \- 5 +It generates a +.PN LeaveNotify +event on each window between window A and window C, exclusive, +with the detail member of each +.PN XLeaveWindowEvent +structure set to +.PN NotifyNonlinearVirtual . +.IP \- 5 +It generates an +.PN EnterNotify +event on each window between window C and window B, exclusive, +with the detail member of each +.PN XEnterWindowEvent +structure set to +.PN NotifyNonlinearVirtual . +.IP \- 5 +It generates an +.PN EnterNotify +event on window B, with the detail member of the +.PN XEnterWindowEvent +structure set to +.PN NotifyNonlinear . +.RE +.IP \(bu 5 +When the pointer moves from window A to window B on different screens, +the X server does the following: +.RS +.IP \- 5 +It generates a +.PN LeaveNotify +event on window A, +with the detail member of the +.PN XLeaveWindowEvent +structure set to +.PN NotifyNonlinear . +.IP \- 5 +If window A is not a root window, +it generates a +.PN LeaveNotify +event on each window above window A up to and including its root, +with the detail member of each +.PN XLeaveWindowEvent +structure set to +.PN NotifyNonlinearVirtual . +.IP \- 5 +If window B is not a root window, +it generates an +.PN EnterNotify +event on each window from window B's root down to but not including +window B, with the detail member of each +.PN XEnterWindowEvent +structure set to +.PN NotifyNonlinearVirtual . +.IP \- 5 +It generates an +.PN EnterNotify +event on window B, with the detail member of the +.PN XEnterWindowEvent +structure set to +.PN NotifyNonlinear . +.RE +.\".SH 3 +.NH 3 +Grab and Ungrab Entry/Exit Events +.XS +\*(SN Grab and Ungrab Entry/Exit Events +.XE +.LP +Pseudo-motion mode +.PN EnterNotify +and +.PN LeaveNotify +events are generated when a pointer grab activates or deactivates. +Events in which the pointer grab activates +are identified by +.PN XEnterWindowEvent +or +.PN XLeaveWindowEvent +structures whose mode member is set to +.PN NotifyGrab . +Events in which the pointer grab deactivates +are identified by +.PN XEnterWindowEvent +or +.PN XLeaveWindowEvent +structures whose mode member is set to +.PN NotifyUngrab +(see +.PN XGrabPointer ). +.IP \(bu 5 +When a pointer grab activates after any initial warp into a confine_to +window and before generating any actual +.PN ButtonPress +event that activates the grab, +G is the grab_window for the grab, +and P is the window the pointer is in, +the X server does the following: +.RS +.IP \- 5 +It generates +.PN EnterNotify +and +.PN LeaveNotify +events (see section 10.6.1) +with the mode members of the +.PN XEnterWindowEvent +and +.PN XLeaveWindowEvent +structures set to +.PN NotifyGrab . +These events are generated +as if the pointer were to suddenly warp from +its current position in P to some position in G. +However, the pointer does not warp, and the X server uses the pointer position +as both the initial and final positions for the events. +.RE +.IP \(bu 5 +When a pointer grab deactivates after generating any actual +.PN ButtonRelease +event that deactivates the grab, +G is the grab_window for the grab, +and P is the window the pointer is in, +the X server does the following: +.RS +.IP \- 5 +It generates +.PN EnterNotify +and +.PN LeaveNotify +events (see section 10.6.1) +with the mode members of the +.PN XEnterWindowEvent +and +.PN XLeaveWindowEvent +structures set to +.PN NotifyUngrab . +These events are generated as if the pointer were to suddenly warp from +some position in G to its current position in P. +However, the pointer does not warp, and the X server uses the +current pointer position as both the +initial and final positions for the events. +.RE +.NH 2 +Input Focus Events +.XS +\*(SN Input Focus Events +.XE +.LP +.IN "Events" "FocusIn" +.IN "Events" "FocusOut" +This section describes the processing that occurs for the input focus events +.PN FocusIn +and +.PN FocusOut . +.IN "FocusIn" "" "@DEF@" +.IN "FocusOut" "" "@DEF@" +The X server can report +.PN FocusIn +or +.PN FocusOut +events to clients wanting information about when the input focus changes. +The keyboard is always attached to some window +(typically, the root window or a top-level window), +which is called the focus window. +The focus window and the position of the pointer determine the window that +receives keyboard input. +Clients may need to know when the input focus changes +to control highlighting of areas on the screen. +.LP +To receive +.PN FocusIn +or +.PN FocusOut +events, set the +.PN FocusChangeMask +bit in the event-mask attribute of the window. +.LP +The structure for these event types contains: +.LP +.IN "XFocusChangeEvent" "" "@DEF@" +.IN "XFocusInEvent" "" "@DEF@" +.IN "XFocusOutEvent" "" "@DEF@" +.sM +.Ds 0 +.TA .5i 3i +.ta .5i 3i +typedef struct { + int type; /* FocusIn or FocusOut */ + unsigned long serial; /* # of last request processed by server */ + Bool send_event; /* true if this came from a SendEvent request */ + Display *display; /* Display the event was read from */ + Window window; /* window of event */ + int mode; /* NotifyNormal, NotifyGrab, NotifyUngrab */ + int detail; + /* + * NotifyAncestor, NotifyVirtual, NotifyInferior, + * NotifyNonlinear,NotifyNonlinearVirtual, NotifyPointer, + * NotifyPointerRoot, NotifyDetailNone + */ +} XFocusChangeEvent; +typedef XFocusChangeEvent XFocusInEvent; +typedef XFocusChangeEvent XFocusOutEvent; +.De +.LP +.eM +The window member is set to the window on which the +.PN FocusIn +or +.PN FocusOut +event was generated. +This is the window used by the X server to report the event. +The mode member is set to indicate whether the focus events +are normal focus events, +focus events while grabbed, +focus events +when a grab activates, or focus events when a grab deactivates. +The X server can set the mode member to +.PN NotifyNormal , +.PN NotifyWhileGrabbed , +.PN NotifyGrab , +or +.PN NotifyUngrab . +.LP +All +.PN FocusOut +events caused by a window unmap are generated after any +.PN UnmapNotify +event; however, the X protocol does not constrain the ordering of +.PN FocusOut +events with respect to +generated +.PN EnterNotify , +.PN LeaveNotify , +.PN VisibilityNotify , +and +.PN Expose +events. +.LP +Depending on the event mode, +the detail member is set to indicate the notify detail and can be +.PN NotifyAncestor , +.PN NotifyVirtual , +.PN NotifyInferior , +.PN NotifyNonlinear , +.PN NotifyNonlinearVirtual , +.PN NotifyPointer , +.PN NotifyPointerRoot , +or +.PN NotifyDetailNone . +.NH 3 +Normal Focus Events and Focus Events While Grabbed +.XS +\*(SN Normal Focus Events and Focus Events While Grabbed +.XE +.LP +Normal focus events are identified by +.PN XFocusInEvent +or +.PN XFocusOutEvent +structures whose mode member is set to +.PN NotifyNormal . +Focus events while grabbed are identified by +.PN XFocusInEvent +or +.PN XFocusOutEvent +structures whose mode member is set to +.PN NotifyWhileGrabbed . +The X server processes normal focus and focus events while grabbed according to +the following: +.IP \(bu 5 +When the focus moves from window A to window B, A is an inferior of B, +and the pointer is in window P, +the X server does the following: +.RS +.IP \- 5 +It generates a +.PN FocusOut +event on window A, with the detail member of the +.PN XFocusOutEvent +structure set to +.PN NotifyAncestor . +.IP \- 5 +It generates a +.PN FocusOut +event on each window between window A and window B, exclusive, +with the detail member of each +.PN XFocusOutEvent +structure set to +.PN NotifyVirtual . +.IP \- 5 +It generates a +.PN FocusIn +event on window B, with the detail member of the +.PN XFocusOutEvent +structure set to +.PN NotifyInferior . +.IP \- 5 +If window P is an inferior of window B +but window P is not window A or an inferior or ancestor of window A, +it generates a +.PN FocusIn +event on each window below window B, down to and including window P, +with the detail member of each +.PN XFocusInEvent +structure set to +.PN NotifyPointer . +.RE +.IP \(bu 5 +When the focus moves from window A to window B, B is an inferior of A, +and the pointer is in window P, +the X server does the following: +.RS +.IP \- 5 +If window P is an inferior of window A +but P is not an inferior of window B or an ancestor of B, +it generates a +.PN FocusOut +event on each window from window P up to but not including window A, +with the detail member of each +.PN XFocusOutEvent +structure set to +.PN NotifyPointer . +.IP \- 5 +It generates a +.PN FocusOut +event on window A, +with the detail member of the +.PN XFocusOutEvent +structure set to +.PN NotifyInferior . +.IP \- 5 +It generates a +.PN FocusIn +event on each window between window A and window B, exclusive, with the +detail member of each +.PN XFocusInEvent +structure set to +.PN NotifyVirtual . +.IP \- 5 +It generates a +.PN FocusIn +event on window B, with the detail member of the +.PN XFocusInEvent +structure set to +.PN NotifyAncestor . +.RE +.IP \(bu 5 +When the focus moves from window A to window B, +window C is their least common ancestor, +and the pointer is in window P, +the X server does the following: +.RS +.IP \- 5 +If window P is an inferior of window A, +it generates a +.PN FocusOut +event on each window from window P up to but not including window A, +with the detail member of the +.PN XFocusOutEvent +structure set to +.PN NotifyPointer . +.IP \- 5 +It generates a +.PN FocusOut +event on window A, +with the detail member of the +.PN XFocusOutEvent +structure set to +.PN NotifyNonlinear . +.IP \- 5 +It generates a +.PN FocusOut +event on each window between window A and window C, exclusive, +with the detail member of each +.PN XFocusOutEvent +structure set to +.PN NotifyNonlinearVirtual . +.IP \- 5 +It generates a +.PN FocusIn +event on each window between C and B, exclusive, +with the detail member of each +.PN XFocusInEvent +structure set to +.PN NotifyNonlinearVirtual . +.IP \- 5 +It generates a +.PN FocusIn +event on window B, with the detail member of the +.PN XFocusInEvent +structure set to +.PN NotifyNonlinear . +.IP \- 5 +If window P is an inferior of window B, it generates a +.PN FocusIn +event on each window below window B down to and including window P, +with the detail member of the +.PN XFocusInEvent +structure set to +.PN NotifyPointer . +.RE +.IP \(bu 5 +When the focus moves from window A to window B on different screens +and the pointer is in window P, +the X server does the following: +.RS +.IP \- 5 +If window P is an inferior of window A, it generates a +.PN FocusOut +event on each window from window P up to but not including window A, +with the detail member of each +.PN XFocusOutEvent +structure set to +.PN NotifyPointer . +.IP \- 5 +It generates a +.PN FocusOut +event on window A, +with the detail member of the +.PN XFocusOutEvent +structure set to +.PN NotifyNonlinear . +.IP \- 5 +If window A is not a root window, +it generates a +.PN FocusOut +event on each window above window A up to and including its root, +with the detail member of each +.PN XFocusOutEvent +structure set to +.PN NotifyNonlinearVirtual . +.IP \- 5 +If window B is not a root window, +it generates a +.PN FocusIn +event on each window from window B's root down to but not including +window B, with the detail member of each +.PN XFocusInEvent +structure set to +.PN NotifyNonlinearVirtual . +.IP \- 5 +It generates a +.PN FocusIn +event on window B, with the detail member of each +.PN XFocusInEvent +structure set to +.PN NotifyNonlinear . +.IP \- 5 +If window P is an inferior of window B, it generates a +.PN FocusIn +event on each window below window B down to and including window P, +with the detail member of each +.PN XFocusInEvent +structure set to +.PN NotifyPointer . +.RE +.IP \(bu 5 +When the focus moves from window A to +.PN PointerRoot +(events sent to the window under the pointer) +or +.PN None +(discard), and the pointer is in window P, +the X server does the following: +.RS +.IP \- 5 +If window P is an inferior of window A, it generates a +.PN FocusOut +event on each window from window P up to but not including window A, +with the detail member of each +.PN XFocusOutEvent +structure set to +.PN NotifyPointer . +.IP \- 5 +It generates a +.PN FocusOut +event on window A, with the detail member of the +.PN XFocusOutEvent +structure set to +.PN NotifyNonlinear . +.IP \- 5 +If window A is not a root window, +it generates a +.PN FocusOut +event on each window above window A up to and including its root, +with the detail member of each +.PN XFocusOutEvent +structure set to +.PN NotifyNonlinearVirtual . +.IP \- 5 +It generates a +.PN FocusIn +event on the root window of all screens, with the detail member of each +.PN XFocusInEvent +structure set to +.PN NotifyPointerRoot +(or +.PN NotifyDetailNone ). +.IP \- 5 +If the new focus is +.PN PointerRoot , +it generates a +.PN FocusIn +event on each window from window P's root down to and including window P, +with the detail member of each +.PN XFocusInEvent +structure set to +.PN NotifyPointer . +.RE +.IP \(bu 5 +When the focus moves from +.PN PointerRoot +(events sent to the window under the pointer) +or +.PN None +to window A, and the pointer is in window P, +the X server does the following: +.RS +.IP \- 5 +If the old focus is +.PN PointerRoot , +it generates a +.PN FocusOut +event on each window from window P up to and including window P's root, +with the detail member of each +.PN XFocusOutEvent +structure set to +.PN NotifyPointer . +.IP \- 5 +It generates a +.PN FocusOut +event on all root windows, +with the detail member of each +.PN XFocusOutEvent +structure set to +.PN NotifyPointerRoot +(or +.PN NotifyDetailNone ). +.IP \- 5 +If window A is not a root window, +it generates a +.PN FocusIn +event on each window from window A's root down to but not including window A, +with the detail member of each +.PN XFocusInEvent +structure set to +.PN NotifyNonlinearVirtual . +.IP \- 5 +It generates a +.PN FocusIn +event on window A, +with the detail member of the +.PN XFocusInEvent +structure set to +.PN NotifyNonlinear . +.IP \- 5 +If window P is an inferior of window A, it generates a +.PN FocusIn +event on each window below window A down to and including window P, +with the detail member of each +.PN XFocusInEvent +structure set to +.PN NotifyPointer . +.RE +.IP \(bu 5 +When the focus moves from +.PN PointerRoot +(events sent to the window under the pointer) +to +.PN None +(or vice versa), and the pointer is in window P, +the X server does the following: +.RS +.IP \- 5 +If the old focus is +.PN PointerRoot , +it generates a +.PN FocusOut +event on each window from window P up to and including window P's root, +with the detail member of each +.PN XFocusOutEvent +structure set to +.PN NotifyPointer . +.IP \- 5 +It generates a +.PN FocusOut +event on all root windows, +with the detail member of each +.PN XFocusOutEvent +structure set to either +.PN NotifyPointerRoot +or +.PN NotifyDetailNone . +.IP \- 5 +It generates a +.PN FocusIn +event on all root windows, +with the detail member of each +.PN XFocusInEvent +structure set to +.PN NotifyDetailNone +or +.PN NotifyPointerRoot . +.IP \- 5 +If the new focus is +.PN PointerRoot , +it generates a +.PN FocusIn +event on each window from window P's root down to and including window P, +with the detail member of each +.PN XFocusInEvent +structure set to +.PN NotifyPointer . +.RE +.\".SH 3 +.NH 3 +Focus Events Generated by Grabs +.XS +\*(SN Focus Events Generated by Grabs +.XE +.LP +Focus events in which the keyboard grab activates +are identified by +.PN XFocusInEvent +or +.PN XFocusOutEvent +structures whose mode member is set to +.PN NotifyGrab . +Focus events in which the keyboard grab deactivates +are identified by +.PN XFocusInEvent +or +.PN XFocusOutEvent +structures whose mode member is set to +.PN NotifyUngrab +(see +.PN XGrabKeyboard ). +.IP \(bu 5 +When a keyboard grab activates before generating any actual +.PN KeyPress +event that activates the grab, +G is the grab_window, and F is the current focus, +the X server does the following: +.RS +.IP \- 5 +It generates +.PN FocusIn +and +.PN FocusOut +events, with the mode members of the +.PN XFocusInEvent +and +.PN XFocusOutEvent +structures set to +.PN NotifyGrab . +These events are generated +as if the focus were to change from +F to G. +.RE +.IP \(bu 5 +When a keyboard grab deactivates after generating any actual +.PN KeyRelease +event that deactivates the grab, +G is the grab_window, and F is the current focus, +the X server does the following: +.RS +.IP \- 5 +It generates +.PN FocusIn +and +.PN FocusOut +events, with the mode members of the +.PN XFocusInEvent +and +.PN XFocusOutEvent +structures set to +.PN NotifyUngrab . +These events are generated +as if the focus were to change from +G to F. +.RE +.NH 2 +Key Map State Notification Events +.XS +\*(SN Key Map State Notification Events +.XE +.LP +.IN "Events" "KeymapNotify" +.IN "KeymapNotify" "" "@DEF@" +The X server can report +.PN KeymapNotify +events to clients that want information about changes in their keyboard state. +.LP +To receive +.PN KeymapNotify +events, set the +.PN KeymapStateMask +bit in the event-mask attribute of the window. +The X server generates this event immediately after every +.PN EnterNotify +and +.PN FocusIn +event. +.LP +The structure for this event type contains: +.LP +.IN "XKeymapEvent" "" "@DEF@" +.sM +.Ds 0 +.TA .5i 3i +.ta .5i 3i +/* generated on EnterWindow and FocusIn when KeymapState selected */ +typedef struct { + int type; /* KeymapNotify */ + unsigned long serial; /* # of last request processed by server */ + Bool send_event; /* true if this came from a SendEvent request */ + Display *display; /* Display the event was read from */ + Window window; + char key_vector[32]; +} XKeymapEvent; +.De +.LP +.eM +The window member is not used but is present to aid some toolkits. +The key_vector member is set to the bit vector of the keyboard. +Each bit set to 1 indicates that the corresponding key +is currently pressed. +The vector is represented as 32 bytes. +Byte N (from 0) contains the bits for keys 8N to 8N + 7 +with the least significant bit in the byte representing key 8N. +.NH 2 +Exposure Events +.XS +\*(SN Exposure Events +.XE +.LP +The X protocol does not guarantee to preserve the contents of window +regions when +the windows are obscured or reconfigured. +Some implementations may preserve the contents of windows. +Other implementations are free to destroy the contents of windows +when exposed. +X expects client applications to assume the responsibility for +restoring the contents of an exposed window region. +(An exposed window region describes a formerly obscured window whose +region becomes visible.) +Therefore, the X server sends +.PN Expose +events describing the window and the region of the window that has been exposed. +A naive client application usually redraws the entire window. +A more sophisticated client application redraws only the exposed region. +.NH 3 +Expose Events +.XS +\*(SN Expose Events +.XE +.LP +.IN "Events" "Expose" +.IN "Expose" "" "@DEF@" +The X server can report +.PN Expose +events to clients wanting information about when the contents of window regions +have been lost. +The circumstances in which the X server generates +.PN Expose +events are not as definite as those for other events. +However, the X server never generates +.PN Expose +events on windows whose class you specified as +.PN InputOnly . +The X server can generate +.PN Expose +events when no valid contents are available for regions of a window +and either the regions are visible, +the regions are viewable and the server is (perhaps newly) maintaining +backing store on the window, +or the window is not viewable but the server is (perhaps newly) honoring the +window's backing-store attribute of +.PN Always +or +.PN WhenMapped . +The regions decompose into an (arbitrary) set of rectangles, +and an +.PN Expose +event is generated for each rectangle. +For any given window, +the X server guarantees to report contiguously +all of the regions exposed by some action that causes +.PN Expose +events, such as raising a window. +.LP +To receive +.PN Expose +events, set the +.PN ExposureMask +bit in the event-mask attribute of the window. +.LP +The structure for this event type contains: +.LP +.IN "XExposeEvent" "" "@DEF@" +.sM +.Ds 0 +.TA .5i 3i +.ta .5i 3i +typedef struct { + int type; /* Expose */ + unsigned long serial; /* # of last request processed by server */ + Bool send_event; /* true if this came from a SendEvent request */ + Display *display; /* Display the event was read from */ + Window window; + int x, y; + int width, height; + int count; /* if nonzero, at least this many more */ +} XExposeEvent; +.De +.LP +.eM +The window member is set to the exposed (damaged) window. +The x and y members are set to the coordinates relative to the window's origin +and indicate the upper-left corner of the rectangle. +The width and height members are set to the size (extent) of the rectangle. +The count member is set to the number of +.PN Expose +events that are to follow. +If count is zero, no more +.PN Expose +events follow for this window. +However, if count is nonzero, at least that number of +.PN Expose +events (and possibly more) follow for this window. +Simple applications that do not want to optimize redisplay by distinguishing +between subareas of its window can just ignore all +.PN Expose +events with nonzero counts and perform full redisplays +on events with zero counts. +.NH 3 +GraphicsExpose and NoExpose Events +.XS +\*(SN GraphicsExpose and NoExpose Events +.XE +.LP +.IN "Events" "GraphicsExpose" +.IN "Events" "NoExpose" +.IN "GraphicsExpose" "" "@DEF@" +The X server can report +.PN GraphicsExpose +events to clients wanting information about when a destination region could not +be computed during certain graphics requests: +.PN XCopyArea +or +.PN XCopyPlane . +The X server generates this event whenever a destination region could not be +computed because of an obscured or out-of-bounds source region. +In addition, the X server guarantees to report contiguously all of the regions exposed by +some graphics request +(for example, copying an area of a drawable to a destination +drawable). +.LP +.IN "NoExpose" "" "@DEF@" +The X server generates a +.PN NoExpose +event whenever a graphics request that might +produce a +.PN GraphicsExpose +event does not produce any. +In other words, the client is really asking for a +.PN GraphicsExpose +event but instead receives a +.PN NoExpose +event. +.LP +To receive +.PN GraphicsExpose +or +.PN NoExpose +events, you must first set the graphics-exposure +attribute of the graphics context to +.PN True . +You also can set the graphics-expose attribute when creating a graphics +context using +.PN XCreateGC +or by calling +.PN XSetGraphicsExposures . +.LP +The structures for these event types contain: +.LP +.IN "XGraphicsExposeEvent" "" "@DEF@" +.sM +.Ds 0 +.TA .5i 3i +.ta .5i 3i +typedef struct { + int type; /* GraphicsExpose */ + unsigned long serial; /* # of last request processed by server */ + Bool send_event; /* true if this came from a SendEvent request */ + Display *display; /* Display the event was read from */ + Drawable drawable; + int x, y; + int width, height; + int count; /* if nonzero, at least this many more */ + int major_code; /* core is CopyArea or CopyPlane */ + int minor_code; /* not defined in the core */ +} XGraphicsExposeEvent; +.De +.LP +.IN "XNoExposeEvent" "" "@DEF@" +.Ds 0 +.TA .5i 3i +.ta .5i 3i +typedef struct { + int type; /* NoExpose */ + unsigned long serial; /* # of last request processed by server */ + Bool send_event; /* true if this came from a SendEvent request */ + Display *display; /* Display the event was read from */ + Drawable drawable; + int major_code; /* core is CopyArea or CopyPlane */ + int minor_code; /* not defined in the core */ +} XNoExposeEvent; +.De +.LP +.eM +Both structures have these common members: drawable, major_code, and minor_code. +The drawable member is set to the drawable of the destination region on +which the graphics request was to be performed. +The major_code member is set to the graphics request initiated by the client +and can be either +.PN X_CopyArea +or +.PN X_CopyPlane . +If it is +.PN X_CopyArea , +a call to +.PN XCopyArea +initiated the request. +If it is +.PN X_CopyPlane , +a call to +.PN XCopyPlane +initiated the request. +These constants are defined in +.hN X11/Xproto.h . +The minor_code member, +like the major_code member, +indicates which graphics request was initiated by +the client. +However, the minor_code member is not defined by the core +X protocol and will be zero in these cases, +although it may be used by an extension. +.LP +The +.PN XGraphicsExposeEvent +structure has these additional members: x, y, width, height, and count. +The x and y members are set to the coordinates relative to the drawable's origin +and indicate the upper-left corner of the rectangle. +The width and height members are set to the size (extent) of the rectangle. +The count member is set to the number of +.PN GraphicsExpose +events to follow. +If count is zero, no more +.PN GraphicsExpose +events follow for this window. +However, if count is nonzero, at least that number of +.PN GraphicsExpose +events (and possibly more) are to follow for this window. +.NH 2 +Window State Change Events +.XS +\*(SN Window State Change Events +.XE +.LP +The following sections discuss: +.IP \(bu 5 +.PN CirculateNotify +events +.IP \(bu 5 +.PN ConfigureNotify +events +.IP \(bu 5 +.PN CreateNotify +events +.IP \(bu 5 +.PN DestroyNotify +events +.IP \(bu 5 +.PN GravityNotify +events +.IP \(bu 5 +.PN MapNotify +events +.IP \(bu 5 +.PN MappingNotify +events +.IP \(bu 5 +.PN ReparentNotify +events +.IP \(bu 5 +.PN UnmapNotify +events +.IP \(bu 5 +.PN VisibilityNotify +events +.\" .SH 3 +.NH 3 +CirculateNotify Events +.XS +\*(SN CirculateNotify Events +.XE +.LP +.IN "Events" "CirculateNotify" +.IN "CirculateNotify" "" "@DEF@" +The X server can report +.PN CirculateNotify +events to clients wanting information about when a window changes +its position in the stack. +The X server generates this event type whenever a window is actually restacked +as a result of a client application calling +.PN XCirculateSubwindows , +.PN XCirculateSubwindowsUp , +or +.PN XCirculateSubwindowsDown . +.LP +To receive +.PN CirculateNotify +events, set the +.PN StructureNotifyMask +bit in the event-mask attribute of the window +or the +.PN SubstructureNotifyMask +bit in the event-mask attribute of the parent window +(in which case, circulating any child generates an event). +.LP +The structure for this event type contains: +.LP +.IN "XCirculateEvent" "" "@DEF@" +.sM +.Ds 0 +.TA .5i 3i +.ta .5i 3i +typedef struct { + int type; /* CirculateNotify */ + unsigned long serial; /* # of last request processed by server */ + Bool send_event; /* true if this came from a SendEvent request */ + Display *display; /* Display the event was read from */ + Window event; + Window window; + int place; /* PlaceOnTop, PlaceOnBottom */ +} XCirculateEvent; +.De +.LP +.eM +The event member is set either to the restacked window or to its parent, +depending on whether +.PN StructureNotify +or +.PN SubstructureNotify +was selected. +The window member is set to the window that was restacked. +The place member is set to the window's position after the restack occurs and +is either +.PN PlaceOnTop +or +.PN PlaceOnBottom . +If it is +.PN PlaceOnTop , +the window is now on top of all siblings. +If it is +.PN PlaceOnBottom , +the window is now below all siblings. +.NH 3 +ConfigureNotify Events +.XS +\*(SN ConfigureNotify Events +.XE +.LP +.IN "Events" "ConfigureNotify" +.IN "ConfigureNotify" "" "@DEF@" +The X server can report +.PN ConfigureNotify +events to clients wanting information about actual changes to a window's +state, such as size, position, border, and stacking order. +The X server generates this event type whenever one of the following configure +window requests made by a client application actually completes: +.IP \(bu 5 +A window's size, position, border, and/or stacking order is reconfigured +by calling +.PN XConfigureWindow . +.IP \(bu 5 +The window's position in the stacking order is changed by calling +.PN XLowerWindow , +.PN XRaiseWindow , +or +.PN XRestackWindows . +.IP \(bu 5 +A window is moved by calling +.PN XMoveWindow . +.IP \(bu 5 +A window's size is changed by calling +.PN XResizeWindow . +.IP \(bu 5 +A window's size and location is changed by calling +.PN XMoveResizeWindow . +.IP \(bu 5 +A window is mapped and its position in the stacking order is changed +by calling +.PN XMapRaised . +.IP \(bu 5 +A window's border width is changed by calling +.PN XSetWindowBorderWidth . +.LP +To receive +.PN ConfigureNotify +events, set the +.PN StructureNotifyMask +bit in the event-mask attribute of the window or the +.PN SubstructureNotifyMask +bit in the event-mask attribute of the parent window +(in which case, configuring any child generates an event). +.LP +The structure for this event type contains: +.LP +.IN "XConfigureEvent" "" "@DEF@" +.sM +.Ds 0 +.TA .5i 3i +.ta .5i 3i +typedef struct { + int type; /* ConfigureNotify */ + unsigned long serial; /* # of last request processed by server */ + Bool send_event; /* true if this came from a SendEvent request */ + Display *display; /* Display the event was read from */ + Window event; + Window window; + int x, y; + int width, height; + int border_width; + Window above; + Bool override_redirect; +} XConfigureEvent; +.De +.LP +.eM +The event member is set either to the reconfigured window or to its parent, +depending on whether +.PN StructureNotify +or +.PN SubstructureNotify +was selected. +The window member is set to the window whose size, position, +border, and/or stacking +order was changed. +.LP +The x and y members are set to the coordinates relative to the parent window's +origin and indicate the position of the upper-left outside corner of the window. +The width and height members are set to the inside size of the window, +not including +the border. +The border_width member is set to the width of the window's border, in pixels. +.LP +The above member is set to the sibling window and is used +for stacking operations. +If the X server sets this member to +.PN None , +the window whose state was changed is on the bottom of the stack +with respect to sibling windows. +However, if this member is set to a sibling window, +the window whose state was changed is placed on top of this sibling window. +.LP +The override_redirect member is set to the override-redirect attribute of the +window. +Window manager clients normally should ignore this window if the +override_redirect member +is +.PN True . +.NH 3 +CreateNotify Events +.XS +\*(SN CreateNotify Events +.XE +.LP +.IN "Events" "CreateNotify" +.IN "CreateNotify" "" "@DEF@" +The X server can report +.PN CreateNotify +events to clients wanting information about creation of windows. +The X server generates this event whenever a client +application creates a window by calling +.PN XCreateWindow +or +.PN XCreateSimpleWindow . +.LP +To receive +.PN CreateNotify +events, set the +.PN SubstructureNotifyMask +bit in the event-mask attribute of the window. +Creating any children then generates an event. +.LP +The structure for the event type contains: +.LP +.IN "XCreateWindowEvent" "" "@DEF@" +.sM +.Ds 0 +.TA .5i 3i +.ta .5i 3i +typedef struct { + int type; /* CreateNotify */ + unsigned long serial; /* # of last request processed by server */ + Bool send_event; /* true if this came from a SendEvent request */ + Display *display; /* Display the event was read from */ + Window parent; /* parent of the window */ + Window window; /* window id of window created */ + int x, y; /* window location */ + int width, height; /* size of window */ + int border_width; /* border width */ + Bool override_redirect; /* creation should be overridden */ +} XCreateWindowEvent; +.De +.LP +.eM +The parent member is set to the created window's parent. +The window member specifies the created window. +The x and y members are set to the created window's coordinates relative +to the parent window's origin and indicate the position of the upper-left +outside corner of the created window. +The width and height members are set to the inside size of the created window +(not including the border) and are always nonzero. +The border_width member is set to the width of the created window's border, in pixels. +The override_redirect member is set to the override-redirect attribute of the +window. +Window manager clients normally should ignore this window +if the override_redirect member is +.PN True . +.NH 3 +DestroyNotify Events +.XS +\*(SN DestroyNotify Events +.XE +.LP +.IN "Events" "DestroyNotify" +.IN "DestroyNotify" "" "@DEF@" +The X server can report +.PN DestroyNotify +events to clients wanting information about which windows are destroyed. +The X server generates this event whenever a client application destroys a +window by calling +.PN XDestroyWindow +or +.PN XDestroySubwindows . +.LP +The ordering of the +.PN DestroyNotify +events is such that for any given window, +.PN DestroyNotify +is generated on all inferiors of the window +before being generated on the window itself. +The X protocol does not constrain the ordering among +siblings and across subhierarchies. +.LP +To receive +.PN DestroyNotify +events, set the +.PN StructureNotifyMask +bit in the event-mask attribute of the window or the +.PN SubstructureNotifyMask +bit in the event-mask attribute of the parent window +(in which case, destroying any child generates an event). +.LP +The structure for this event type contains: +.LP +.IN "XDestroyWindowEvent" "" "@DEF@" +.sM +.Ds 0 +.TA .5i 3i +.ta .5i 3i +typedef struct { + int type; /* DestroyNotify */ + unsigned long serial; /* # of last request processed by server */ + Bool send_event; /* true if this came from a SendEvent request */ + Display *display; /* Display the event was read from */ + Window event; + Window window; +} XDestroyWindowEvent; +.De +.LP +.eM +The event member is set either to the destroyed window or to its parent, +depending on whether +.PN StructureNotify +or +.PN SubstructureNotify +was selected. +The window member is set to the window that is destroyed. +.NH 3 +GravityNotify Events +.XS +\*(SN GravityNotify Events +.XE +.LP +.IN "Events" "GravityNotify" +.IN "GravityNotify" "" "@DEF@" +The X server can report +.PN GravityNotify +events to clients wanting information about when a window is moved because of a +change in the size of its parent. +The X server generates this event whenever a client +application actually moves a child window as a result of resizing its parent by calling +.PN XConfigureWindow , +.PN XMoveResizeWindow , +or +.PN XResizeWindow . +.LP +To receive +.PN GravityNotify +events, set the +.PN StructureNotifyMask +bit in the event-mask attribute of the window or the +.PN SubstructureNotifyMask +bit in the event-mask attribute of the parent window +(in which case, any child that is moved because its parent has been resized +generates an event). +.LP +The structure for this event type contains: +.LP +.IN "XGravityEvent" "" "@DEF@" +.sM +.Ds 0 +.TA .5i 3i +.ta .5i 3i +typedef struct { + int type; /* GravityNotify */ + unsigned long serial; /* # of last request processed by server */ + Bool send_event; /* true if this came from a SendEvent request */ + Display *display; /* Display the event was read from */ + Window event; + Window window; + int x, y; +} XGravityEvent; +.De +.LP +.eM +The event member is set either to the window that was moved or to its parent, +depending on whether +.PN StructureNotify +or +.PN SubstructureNotify +was selected. +The window member is set to the child window that was moved. +The x and y members are set to the coordinates relative to the +new parent window's origin +and indicate the position of the upper-left outside corner of the +window. +.NH 3 +MapNotify Events +.XS +\*(SN MapNotify Events +.XE +.LP +.IN "Events" "MapNotify" +.IN "MapNotify" "" "@DEF@" +The X server can report +.PN MapNotify +events to clients wanting information about which windows are mapped. +The X server generates this event type whenever a client application changes the +window's state from unmapped to mapped by calling +.PN XMapWindow , +.PN XMapRaised , +.PN XMapSubwindows , +.PN XReparentWindow , +or as a result of save-set processing. +.LP +To receive +.PN MapNotify +events, set the +.PN StructureNotifyMask +bit in the event-mask attribute of the window or the +.PN SubstructureNotifyMask +bit in the event-mask attribute of the parent window +(in which case, mapping any child generates an event). +.LP +The structure for this event type contains: +.LP +.IN "XMapEvent" "" "@DEF@" +.sM +.Ds 0 +.TA .5i 3i +.ta .5i 3i +typedef struct { + int type; /* MapNotify */ + unsigned long serial; /* # of last request processed by server */ + Bool send_event; /* true if this came from a SendEvent request */ + Display *display; /* Display the event was read from */ + Window event; + Window window; + Bool override_redirect; /* boolean, is override set... */ +} XMapEvent; +.De +.LP +.eM +The event member is set either to the window that was mapped or to its parent, +depending on whether +.PN StructureNotify +or +.PN SubstructureNotify +was selected. +The window member is set to the window that was mapped. +The override_redirect member is set to the override-redirect attribute +of the window. +Window manager clients normally should ignore this window +if the override-redirect attribute is +.PN True , +because these events usually are generated from pop-ups, +which override structure control. +.NH 3 +MappingNotify Events +.XS +\*(SN MappingNotify Events +.XE +.LP +.IN "Events" "MappingNotify" +.IN "MappingNotify" "" "@DEF@" +The X server reports +.PN MappingNotify +events to all clients. +There is no mechanism to express disinterest in this event. +The X server generates this event type whenever a client application +successfully calls: +.IP \(bu 5 +.PN XSetModifierMapping +to indicate which KeyCodes are to be used as modifiers +.IP \(bu 5 +.PN XChangeKeyboardMapping +to change the keyboard mapping +.IP \(bu 5 +.PN XSetPointerMapping +to set the pointer mapping +.LP +The structure for this event type contains: +.LP +.IN "XMappingEvent" "" "@DEF@" +.sM +.Ds 0 +.TA .5i 3i +.ta .5i 3i +typedef struct { + int type; /* MappingNotify */ + unsigned long serial; /* # of last request processed by server */ + Bool send_event; /* true if this came from a SendEvent request */ + Display *display; /* Display the event was read from */ + Window window; /* unused */ + int request; /* one of MappingModifier, MappingKeyboard, + MappingPointer */ + int first_keycode; /* first keycode */ + int count; /* defines range of change w. first_keycode*/ +} XMappingEvent; +.De +.LP +.eM +The request member is set to indicate the kind of mapping change that occurred +and can be +.PN MappingModifier , +.PN MappingKeyboard , +or +.PN MappingPointer . +If it is +.PN MappingModifier , +the modifier mapping was changed. +If it is +.PN MappingKeyboard , +the keyboard mapping was changed. +If it is +.PN MappingPointer , +the pointer button mapping was changed. +The first_keycode and count members are set only +if the request member was set to +.PN MappingKeyboard . +The number in first_keycode represents the first number in the range +of the altered mapping, +and count represents the number of keycodes altered. +.LP +To update the client application's knowledge of the keyboard, +you should call +.PN XRefreshKeyboardMapping . +.NH 3 +ReparentNotify Events +.XS +\*(SN ReparentNotify Events +.XE +.LP +.IN "Events" "ReparentNotify" +.IN "ReparentNotify" "" "@DEF@" +The X server can report +.PN ReparentNotify +events to clients wanting information about changing a window's parent. +The X server generates this event whenever a client +application calls +.PN XReparentWindow +and the window is actually reparented. +.LP +To receive +.PN ReparentNotify +events, set the +.PN StructureNotifyMask +bit in the event-mask attribute of the window or the +.PN SubstructureNotifyMask +bit in the event-mask attribute of either the old or the new parent window +(in which case, reparenting any child generates an event). +.LP +The structure for this event type contains: +.LP +.IN "XReparentEvent" "" "@DEF@" +.sM +.Ds 0 +.TA .5i 3i +.ta .5i 3i +typedef struct { + int type; /* ReparentNotify */ + unsigned long serial; /* # of last request processed by server */ + Bool send_event; /* true if this came from a SendEvent request */ + Display *display; /* Display the event was read from */ + Window event; + Window window; + Window parent; + int x, y; + Bool override_redirect; +} XReparentEvent; +.De +.LP +.eM +The event member is set either to the reparented window +or to the old or the new parent, depending on whether +.PN StructureNotify +or +.PN SubstructureNotify +was selected. +The window member is set to the window that was reparented. +The parent member is set to the new parent window. +The x and y members are set to the reparented window's coordinates relative +to the new parent window's +origin and define the upper-left outer corner of the reparented window. +The override_redirect member is set to the override-redirect attribute of the +window specified by the window member. +Window manager clients normally should ignore this window +if the override_redirect member is +.PN True . +.NH 3 +UnmapNotify Events +.XS +\*(SN UnmapNotify Events +.XE +.LP +.IN "Events" "UnmapNotify" +.IN "UnmapNotify" "" "@DEF@" +The X server can report +.PN UnmapNotify +events to clients wanting information about which windows are unmapped. +The X server generates this event type whenever a client application changes the +window's state from mapped to unmapped. +.LP +To receive +.PN UnmapNotify +events, set the +.PN StructureNotifyMask +bit in the event-mask attribute of the window or the +.PN SubstructureNotifyMask +bit in the event-mask attribute of the parent window +(in which case, unmapping any child window generates an event). +.LP +The structure for this event type contains: +.LP +.IN "XUnmapEvent" "" "@DEF@" +.sM +.Ds 0 +.TA .5i 3i +.ta .5i 3i +typedef struct { + int type; /* UnmapNotify */ + unsigned long serial; /* # of last request processed by server */ + Bool send_event; /* true if this came from a SendEvent request */ + Display *display; /* Display the event was read from */ + Window event; + Window window; + Bool from_configure; +} XUnmapEvent; +.De +.LP +.eM +The event member is set either to the unmapped window or to its parent, +depending on whether +.PN StructureNotify +or +.PN SubstructureNotify +was selected. +This is the window used by the X server to report the event. +The window member is set to the window that was unmapped. +The from_configure member is set to +.PN True +if the event was generated as a result of a resizing of the window's parent when +the window itself had a win_gravity of +.PN UnmapGravity . +.NH 3 +VisibilityNotify Events +.XS +\*(SN VisibilityNotify Events +.XE +.LP +.IN "Events" "VisibilityNotify" +.IN "VisibilityNotify" "" "@DEF@" +The X server can report +.PN VisibilityNotify +events to clients wanting any change in the visibility of the specified window. +A region of a window is visible if someone looking at the screen can +actually see it. +The X server generates this event whenever the visibility changes state. +However, this event is never generated for windows whose class is +.PN InputOnly . +.LP +All +.PN VisibilityNotify +events caused by a hierarchy change are generated +after any hierarchy event +.Pn ( UnmapNotify , +.PN MapNotify , +.PN ConfigureNotify , +.PN GravityNotify , +.PN CirculateNotify ) +caused by that change. Any +.PN VisibilityNotify +event on a given window is generated before any +.PN Expose +events on that window, but it is not required that all +.PN VisibilityNotify +events on all windows be generated before all +.PN Expose +events on all windows. +The X protocol does not constrain the ordering of +.PN VisibilityNotify +events with +respect to +.PN FocusOut , +.PN EnterNotify , +and +.PN LeaveNotify +events. +.LP +To receive +.PN VisibilityNotify +events, set the +.PN VisibilityChangeMask +bit in the event-mask attribute of the window. +.LP +The structure for this event type contains: +.LP +.IN "XVisibilityEvent" "" "@DEF@" +.sM +.Ds 0 +.TA .5i 3i +.ta .5i 3i +typedef struct { + int type; /* VisibilityNotify */ + unsigned long serial; /* # of last request processed by server */ + Bool send_event; /* true if this came from a SendEvent request */ + Display *display; /* Display the event was read from */ + Window window; + int state; +} XVisibilityEvent; +.De +.LP +.eM +The window member is set to the window whose visibility state changes. +The state member is set to the state of the window's visibility and can be +.PN VisibilityUnobscured , +.PN VisibilityPartiallyObscured , +or +.PN VisibilityFullyObscured . +The X server ignores all of a window's subwindows +when determining the visibility state of the window and processes +.PN VisibilityNotify +events according to the following: +.IP \(bu 5 +When the window changes state from partially obscured, fully obscured, +or not viewable to viewable and completely unobscured, +the X server generates the event with the state member of the +.PN XVisibilityEvent +structure set to +.PN VisibilityUnobscured . +.IP \(bu 5 +When the window changes state from viewable and completely unobscured or +not viewable to viewable and partially obscured, +the X server generates the event with the state member of the +.PN XVisibilityEvent +structure set to +.PN VisibilityPartiallyObscured . +.IP \(bu 5 +When the window changes state from viewable and completely unobscured, +viewable and partially obscured, or not viewable to viewable and +fully obscured, +the X server generates the event with the state member of the +.PN XVisibilityEvent +structure set to +.PN VisibilityFullyObscured . +.NH 2 +Structure Control Events +.XS +\*(SN Structure Control Events +.XE +.LP +This section discusses: +.IP \(bu 5 +.PN CirculateRequest +events +.IP \(bu 5 +.PN ConfigureRequest +events +.IP \(bu 5 +.PN MapRequest +events +.IP \(bu 5 +.PN ResizeRequest +events +.NH 3 +CirculateRequest Events +.XS +\*(SN CirculateRequest Events +.XE +.LP +.IN "Events" "CirculateRequest" +.IN "CirculateRequest" "" "@DEF@" +The X server can report +.PN CirculateRequest +events to clients wanting information about +when another client initiates a circulate window request +on a specified window. +The X server generates this event type whenever a client initiates a circulate +window request on a window and a subwindow actually needs to be restacked. +The client initiates a circulate window request on the window by calling +.PN XCirculateSubwindows , +.PN XCirculateSubwindowsUp , +or +.PN XCirculateSubwindowsDown . +.LP +To receive +.PN CirculateRequest +events, set the +.PN SubstructureRedirectMask +in the event-mask attribute of the window. +Then, in the future, +the circulate window request for the specified window is not executed, +and thus, any subwindow's position in the stack is not changed. +For example, suppose a client application calls +.PN XCirculateSubwindowsUp +to raise a subwindow to the top of the stack. +If you had selected +.PN SubstructureRedirectMask +on the window, the X server reports to you a +.PN CirculateRequest +event and does not raise the subwindow to the top of the stack. +.LP +The structure for this event type contains: +.LP +.IN "XCirculateRequestEvent" "" "@DEF@" +.sM +.Ds 0 +.TA .5i 3i +.ta .5i 3i +typedef struct { + int type; /* CirculateRequest */ + unsigned long serial; /* # of last request processed by server */ + Bool send_event; /* true if this came from a SendEvent request */ + Display *display; /* Display the event was read from */ + Window parent; + Window window; + int place; /* PlaceOnTop, PlaceOnBottom */ +} XCirculateRequestEvent; +.De +.LP +.eM +The parent member is set to the parent window. +The window member is set to the subwindow to be restacked. +The place member is set to what the new position in the stacking order should be +and is either +.PN PlaceOnTop +or +.PN PlaceOnBottom . +If it is +.PN PlaceOnTop , +the subwindow should be on top of all siblings. +If it is +.PN PlaceOnBottom , +the subwindow should be below all siblings. +.NH 3 +ConfigureRequest Events +.XS +\*(SN ConfigureRequest Events +.XE +.LP +.IN "Events" "ConfigureRequest" +.IN "ConfigureRequest" "" "@DEF@" +The X server can report +.PN ConfigureRequest +events to clients wanting information about when a different client initiates +a configure window request on any child of a specified window. +The configure window request attempts to +reconfigure a window's size, position, border, and stacking order. +The X server generates this event whenever a different client initiates +a configure window request on a window by calling +.PN XConfigureWindow , +.PN XLowerWindow , +.PN XRaiseWindow , +.PN XMapRaised , +.PN XMoveResizeWindow , +.PN XMoveWindow , +.PN XResizeWindow , +.PN XRestackWindows , +or +.PN XSetWindowBorderWidth . +.LP +To receive +.PN ConfigureRequest +events, set the +.PN SubstructureRedirectMask +bit in the event-mask attribute of the window. +.PN ConfigureRequest +events are generated when a +.PN ConfigureWindow +protocol request is issued on a child window by another client. +For example, suppose a client application calls +.PN XLowerWindow +to lower a window. +If you had selected +.PN SubstructureRedirectMask +on the parent window and if the override-redirect attribute +of the window is set to +.PN False , +the X server reports a +.PN ConfigureRequest +event to you and does not lower the specified window. +.LP +The structure for this event type contains: +.LP +.IN "XConfigureRequestEvent" "" "@DEF@" +.sM +.Ds 0 +.TA .5i 3i +.ta .5i 3i +typedef struct { + int type; /* ConfigureRequest */ + unsigned long serial; /* # of last request processed by server */ + Bool send_event; /* true if this came from a SendEvent request */ + Display *display; /* Display the event was read from */ + Window parent; + Window window; + int x, y; + int width, height; + int border_width; + Window above; + int detail; /* Above, Below, TopIf, BottomIf, Opposite */ + unsigned long value_mask; +} XConfigureRequestEvent; +.De +.LP +.eM +The parent member is set to the parent window. +The window member is set to the window whose size, position, border width, +and/or stacking order is to be reconfigured. +The value_mask member indicates which components were specified in the +.PN ConfigureWindow +protocol request. +The corresponding values are reported as given in the request. +The remaining values are filled in from the current geometry of the window, +except in the case of above (sibling) and detail (stack-mode), +which are reported as +.PN None +and +.PN Above , +respectively, if they are not given in the request. +.NH 3 +MapRequest Events +.XS +\*(SN MapRequest Events +.XE +.LP +.IN "Events" "MapRequest" +.IN "MapRequest" "" "@DEF@" +The X server can report +.PN MapRequest +events to clients wanting information about a different client's desire +to map windows. +A window is considered mapped when a map window request completes. +The X server generates this event whenever a different client initiates +a map window request on an unmapped window whose override_redirect member +is set to +.PN False . +Clients initiate map window requests by calling +.PN XMapWindow , +.PN XMapRaised , +or +.PN XMapSubwindows . +.LP +To receive +.PN MapRequest +events, set the +.PN SubstructureRedirectMask +bit in the event-mask attribute of the window. +This means another client's attempts to map a child window by calling one of +the map window request functions is intercepted, and you are sent a +.PN MapRequest +instead. +For example, suppose a client application calls +.PN XMapWindow +to map a window. +If you (usually a window manager) had selected +.PN SubstructureRedirectMask +on the parent window and if the override-redirect attribute +of the window is set to +.PN False , +the X server reports a +.PN MapRequest +event to you +and does not map the specified window. +Thus, this event gives your window manager client the ability +to control the placement of subwindows. +.LP +The structure for this event type contains: +.LP +.IN "XMapRequestEvent" "" "@DEF@" +.sM +.Ds 0 +.TA .5i 3i +.ta .5i 3i +typedef struct { + int type; /* MapRequest */ + unsigned long serial; /* # of last request processed by server */ + Bool send_event; /* true if this came from a SendEvent request */ + Display *display; /* Display the event was read from */ + Window parent; + Window window; +} XMapRequestEvent; +.De +.LP +.eM +The parent member is set to the parent window. +The window member is set to the window to be mapped. +.NH 3 +ResizeRequest Events +.XS +\*(SN ResizeRequest Events +.XE +.LP +.IN "Events" "ResizeRequest" +.IN "ResizeRequest" "" "@DEF@" +The X server can report +.PN ResizeRequest +events to clients wanting information about another client's attempts to change the +size of a window. +The X server generates this event whenever some other client attempts to change +the size of the specified window by calling +.PN XConfigureWindow , +.PN XResizeWindow , +or +.PN XMoveResizeWindow . +.LP +To receive +.PN ResizeRequest +events, set the +.PN ResizeRedirect +bit in the event-mask attribute of the window. +Any attempts to change the size by other clients are then redirected. +.LP +The structure for this event type contains: +.LP +.IN "XResizeRequestEvent" "" "@DEF@" +.sM +.Ds 0 +.TA .5i 3i +.ta .5i 3i +typedef struct { + int type; /* ResizeRequest */ + unsigned long serial; /* # of last request processed by server */ + Bool send_event; /* true if this came from a SendEvent request */ + Display *display; /* Display the event was read from */ + Window window; + int width, height; +} XResizeRequestEvent; +.De +.LP +.eM +The window member is set to the window whose size another +client attempted to change. +The width and height members are set to the inside size of the window, +excluding the border. +.NH 2 +Colormap State Change Events +.XS +\*(SN Colormap State Change Events +.XE +.LP +.IN "Events" "ColormapNotify" +.IN "ColormapNotify" "" "@DEF@" +The X server can report +.PN ColormapNotify +events to clients wanting information about when the colormap changes +and when a colormap is installed or uninstalled. +The X server generates this event type whenever a client application: +.IP \(bu 5 +Changes the colormap member of the +.PN XSetWindowAttributes +structure by +calling +.PN XChangeWindowAttributes , +.PN XFreeColormap , +or +.PN XSetWindowColormap +.IP \(bu 5 +Installs or uninstalls the colormap by calling +.PN XInstallColormap +or +.PN XUninstallColormap +.LP +To receive +.PN ColormapNotify +events, set the +.PN ColormapChangeMask +bit in the event-mask attribute of the window. +.LP +The structure for this event type contains: +.LP +.IN "XColormapEvent" "" "@DEF@" +.sM +.Ds 0 +.TA .5i 3i +.ta .5i 3i +typedef struct { + int type; /* ColormapNotify */ + unsigned long serial; /* # of last request processed by server */ + Bool send_event; /* true if this came from a SendEvent request */ + Display *display; /* Display the event was read from */ + Window window; + Colormap colormap; /* colormap or None */ + Bool new; + int state; /* ColormapInstalled, ColormapUninstalled */ +} XColormapEvent; +.De +.LP +.eM +The window member is set to the window whose associated +colormap is changed, installed, or uninstalled. +For a colormap that is changed, installed, or uninstalled, +the colormap member is set to the colormap associated with the window. +For a colormap that is changed by a call to +.PN XFreeColormap , +the colormap member is set to +.PN None . +The new member is set to indicate whether the colormap +for the specified window was changed or installed or uninstalled +and can be +.PN True +or +.PN False . +If it is +.PN True , +the colormap was changed. +If it is +.PN False , +the colormap was installed or uninstalled. +The state member is always set to indicate whether the colormap is installed or +uninstalled and can be +.PN ColormapInstalled +or +.PN ColormapUninstalled . +.NH 2 +Client Communication Events +.XS +\*(SN Client Communication Events +.XE +.LP +This section discusses: +.IP \(bu 5 +.PN ClientMessage +events +.IP \(bu 5 +.PN PropertyNotify +events +.IP \(bu 5 +.PN SelectionClear +events +.IP \(bu 5 +.PN SelectionNotify +events +.IP \(bu 5 +.PN SelectionRequest +events +.NH 3 +ClientMessage Events +.XS +\*(SN ClientMessage Events +.XE +.LP +.IN "Events" "ClientMessage" +.IN "ClientMessage" "" "@DEF@" +The X server generates +.PN ClientMessage +events only when a client calls the function +.PN XSendEvent . +.LP +The structure for this event type contains: +.LP +.IN "XClientMessageEvent" "" "@DEF@" +.sM +.Ds 0 +.TA .5i 1i 3i +.ta .5i 1i 3i +typedef struct { + int type; /* ClientMessage */ + unsigned long serial; /* # of last request processed by server */ + Bool send_event; /* true if this came from a SendEvent request */ + Display *display; /* Display the event was read from */ + Window window; + Atom message_type; + int format; + union { + char b[20]; + short s[10]; + long l[5]; + } data; +} XClientMessageEvent; +.De +.LP +.eM +The message_type member is set to an atom that indicates how the data +should be interpreted by the receiving client. +The format member is set to 8, 16, or 32 and specifies whether the data +should be viewed as a list of bytes, shorts, or longs. +The data member is a union that contains the members b, s, and l. +The b, s, and l members represent data of twenty 8-bit values, +ten 16-bit values, and five 32-bit values. +Particular message types might not make use of all these values. +The X server places no interpretation on the values in the window, +message_type, or data members. +.NH 3 +PropertyNotify Events +.XS +\*(SN PropertyNotify Events +.XE +.LP +.IN "Events" "PropertyNotify" +.IN "PropertyNotify" "" "@DEF@" +The X server can report +.PN PropertyNotify +events to clients wanting information about property changes +for a specified window. +.LP +To receive +.PN PropertyNotify +events, set the +.PN PropertyChangeMask +bit in the event-mask attribute of the window. +.LP +The structure for this event type contains: +.LP +.IN "XPropertyEvent" "" "@DEF@" +.sM +.Ds 0 +.TA .5i 3i +.ta .5i 3i +typedef struct { + int type; /* PropertyNotify */ + unsigned long serial; /* # of last request processed by server */ + Bool send_event; /* true if this came from a SendEvent request */ + Display *display; /* Display the event was read from */ + Window window; + Atom atom; + Time time; + int state; /* PropertyNewValue or PropertyDelete */ +} XPropertyEvent; +.De +.LP +.eM +The window member is set to the window whose associated +property was changed. +The atom member is set to the property's atom and indicates which +property was changed or desired. +The time member is set to the server time when the property was changed. +The state member is set to indicate whether the property was changed +to a new value or deleted and can be +.PN PropertyNewValue +or +.PN PropertyDelete . +The state member is set to +.PN PropertyNewValue +when a property of the window is changed using +.PN XChangeProperty +or +.PN XRotateWindowProperties +(even when adding zero-length data using +.PN XChangeProperty ) +and when replacing all or part of a property with identical data using +.PN XChangeProperty +or +.PN XRotateWindowProperties . +The state member is set to +.PN PropertyDelete +when a property of the window is deleted using +.PN XDeleteProperty +or, if the delete argument is +.PN True , +.PN XGetWindowProperty . +.NH 3 +SelectionClear Events +.XS +\*(SN SelectionClear Events +.XE +.LP +.IN "Events" "SelectionClear" +.IN "SelectionClear" "" "@DEF@" +The X server reports +.PN SelectionClear +events to the client losing ownership of a selection. +The X server generates this event type when another client +asserts ownership of the selection by calling +.PN XSetSelectionOwner . +.LP +The structure for this event type contains: +.LP +.IN "XSelectionClearEvent" "" "@DEF@" +.sM +.Ds 0 +.TA .5i 3i +.ta .5i 3i +typedef struct { + int type; /* SelectionClear */ + unsigned long serial; /* # of last request processed by server */ + Bool send_event; /* true if this came from a SendEvent request */ + Display *display; /* Display the event was read from */ + Window window; + Atom selection; + Time time; +} XSelectionClearEvent; +.De +.LP +.eM +The selection member is set to the selection atom. +The time member is set to the last change time recorded for the +selection. +The window member is the window that was specified by the current owner +(the owner losing the selection) in its +.PN XSetSelectionOwner +call. +.NH 3 +SelectionRequest Events +.XS +\*(SN SelectionRequest Events +.XE +.LP +.IN "Events" "SelectionRequest" +.IN "SelectionRequest" "" "@DEF@" +The X server reports +.PN SelectionRequest +events to the owner of a selection. +The X server generates this event whenever a client +requests a selection conversion by calling +.PN XConvertSelection +for the owned selection. +.LP +The structure for this event type contains: +.LP +.IN "XSelectionRequestEvent" "" "@DEF@" +.sM +.Ds 0 +.TA .5i 3i +.ta .5i 3i +typedef struct { + int type; /* SelectionRequest */ + unsigned long serial; /* # of last request processed by server */ + Bool send_event; /* true if this came from a SendEvent request */ + Display *display; /* Display the event was read from */ + Window owner; + Window requestor; + Atom selection; + Atom target; + Atom property; + Time time; +} XSelectionRequestEvent; +.De +.LP +.eM +The owner member is set to the window +that was specified by the current owner in its +.PN XSetSelectionOwner +call. +The requestor member is set to the window requesting the selection. +The selection member is set to the atom that names the selection. +For example, PRIMARY is used to indicate the primary selection. +The target member is set to the atom that indicates the type +the selection is desired in. +The property member can be a property name or +.PN None . +The time member is set to the timestamp or +.PN CurrentTime +value from the +.PN ConvertSelection +request. +.LP +The owner should convert the selection based on the specified target type +and send a +.PN SelectionNotify +event back to the requestor. +A complete specification for using selections is given in the X Consortium +standard \fIInter-Client Communication Conventions Manual\fP. +.NH 3 +SelectionNotify Events +.XS +\*(SN SelectionNotify Events +.XE +.LP +.IN "Events" "SelectionNotify" +.IN "SelectionNotify" "" "@DEF@" +This event is generated by the X server in response to a +.PN ConvertSelection +protocol request when there is no owner for the selection. +When there is an owner, it should be generated by the owner +of the selection by using +.PN XSendEvent . +The owner of a selection should send this event to a requestor when a selection +has been converted and stored as a property +or when a selection conversion could +not be performed (which is indicated by setting the property member to +.PN None ). +.LP +If +.PN None +is specified as the property in the +.PN ConvertSelection +protocol request, the owner should choose a property name, +store the result as that property on the requestor window, +and then send a +.PN SelectionNotify +giving that actual property name. +.LP +The structure for this event type contains: +.LP +.IN "XSelectionEvent" "" "@DEF@" +.sM +.Ds 0 +.TA .5i 3i +.ta .5i 3i +typedef struct { + int type; /* SelectionNotify */ + unsigned long serial; /* # of last request processed by server */ + Bool send_event; /* true if this came from a SendEvent request */ + Display *display; /* Display the event was read from */ + Window requestor; + Atom selection; + Atom target; + Atom property; /* atom or None */ + Time time; +} XSelectionEvent; +.De +.LP +.eM +The requestor member is set to the window associated with +the requestor of the selection. +The selection member is set to the atom that indicates the selection. +For example, PRIMARY is used for the primary selection. +The target member is set to the atom that indicates the converted type. +For example, PIXMAP is used for a pixmap. +The property member is set to the atom that indicates which +property the result was stored on. +If the conversion failed, +the property member is set to +.PN None . +The time member is set to the time the conversion took place and +can be a timestamp or +.PN CurrentTime . +.bp diff --git a/libX11/specs/libX11/CH11 b/libX11/specs/libX11/CH11 new file mode 100644 index 000000000..09d845d35 --- /dev/null +++ b/libX11/specs/libX11/CH11 @@ -0,0 +1,1664 @@ +.\" Copyright \(co 1985, 1986, 1987, 1988, 1989, 1990, 1991, 1994, 1996 X Consortium +.\" +.\" 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 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 X CONSORTIUM 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 X Consortium 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 X Consortium. +.\" +.\" Copyright \(co 1985, 1986, 1987, 1988, 1989, 1990, 1991 by +.\" Digital Equipment Corporation +.\" +.\" Portions Copyright \(co 1990, 1991 by +.\" Tektronix, Inc. +.\" +.\" Permission to use, copy, modify and distribute this documentation for +.\" any purpose and without fee is hereby granted, provided that the above +.\" copyright notice appears in all copies and that both that copyright notice +.\" and this permission notice appear in all copies, and that the names of +.\" Digital and Tektronix not be used in in advertising or publicity pertaining +.\" to this documentation without specific, written prior permission. +.\" Digital and Tektronix makes no representations about the suitability +.\" of this documentation for any purpose. +.\" It is provided ``as is'' without express or implied warranty. +.\" +\& +.sp 1 +.ce 3 +\s+1\fBChapter 11\fP\s-1 + +\s+1\fBEvent Handling Functions\fP\s-1 +.sp 2 +.nr H1 11 +.nr H2 0 +.nr H3 0 +.nr H4 0 +.nr H5 0 +.na +.LP +.XS +Chapter 11: Event Handling Functions +.XE +This chapter discusses the Xlib functions you can use to: +.IP \(bu 5 +Select events +.IP \(bu 5 +Handle the output buffer and the event queue +.IP \(bu 5 +Select events from the event queue +.IP \(bu 5 +Send and get events +.IP \(bu 5 +Handle protocol errors +.NT Note +Some toolkits use their own event-handling functions +and do not allow you to interchange these event-handling functions +with those in Xlib. +For further information, +see the documentation supplied with the toolkit. +.NE +.LP +Most applications simply are event loops: +they wait for an event, decide what to do with it, +execute some amount of code that results in changes to the display, +and then wait for the next event. +.NH 2 +Selecting Events +.XS +\*(SN Selecting Events +.XE +.LP +There are two ways to select the events you want reported to your client +application. +One way is to set the event_mask member of the +.PN XSetWindowAttributes +structure when you call +.PN XCreateWindow +and +.PN XChangeWindowAttributes . +Another way is to use +.PN XSelectInput . +.IN "XSelectInput" "" "@DEF@" +.sM +.FD 0 +XSelectInput\^(\^\fIdisplay\fP, \fIw\fP\^, \fIevent_mask\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + long \fIevent_mask\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.ds Wi whose events you are interested in +.IP \fIw\fP 1i +Specifies the window \*(Wi. +.IP \fIevent_mask\fP 1i +Specifies the event mask. +.LP +.eM +The +.PN XSelectInput +function requests that the X server report the events associated with the +specified event mask. +Initially, X will not report any of these events. +Events are reported relative to a window. +If a window is not interested in a device event, it usually propagates to +the closest ancestor that is interested, +unless the do_not_propagate mask prohibits it. +.IN "Event" "propagation" +.LP +Setting the event-mask attribute of a window overrides any previous call +for the same window but not for other clients. +Multiple clients can select for the same events on the same window +with the following restrictions: +.IP \(bu 5 +Multiple clients can select events on the same window because their event masks +are disjoint. +When the X server generates an event, it reports it +to all interested clients. +.IP \(bu 5 +Only one client at a time can select +.PN CirculateRequest , +.PN ConfigureRequest , +or +.PN MapRequest +events, which are associated with +the event mask +.PN SubstructureRedirectMask . +.IP \(bu 5 +Only one client at a time can select +a +.PN ResizeRequest +event, which is associated with +the event mask +.PN ResizeRedirectMask . +.IP \(bu 5 +Only one client at a time can select a +.PN ButtonPress +event, which is associated with +the event mask +.PN ButtonPressMask . +.LP +The server reports the event to all interested clients. +.LP +.PN XSelectInput +can generate a +.PN BadWindow +error. +.NH 2 +Handling the Output Buffer +.XS +\*(SN Handling the Output Buffer +.XE +.LP +The output buffer is an area used by Xlib to store requests. +The functions described in this section flush the output buffer +if the function would block or not return an event. +That is, all requests residing in the output buffer that +have not yet been sent are transmitted to the X server. +These functions differ in the additional tasks they might perform. +.LP +.sp +To flush the output buffer, use +.PN XFlush . +.IN "XFlush" "" "@DEF@" +.sM +.FD 0 +XFlush\^(\^\fIdisplay\fP\^) +.br + Display *\fIdisplay\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.LP +.eM +The +.PN XFlush +function +flushes the output buffer. +Most client applications need not use this function because the output +buffer is automatically flushed as needed by calls to +.PN XPending , +.PN XNextEvent , +and +.PN XWindowEvent . +.IN "XPending" +.IN "XNextEvent" +.IN "XWindowEvent" +Events generated by the server may be enqueued into the library's event queue. +.LP +.sp +To flush the output buffer and then wait until all requests have been processed, +use +.PN XSync . +.IN "XSync" "" "@DEF@" +.sM +.FD 0 +XSync\^(\^\fIdisplay\fP, \fIdiscard\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Bool \fIdiscard\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIdiscard\fP 1i +Specifies a Boolean value that indicates whether +.PN XSync +discards all events on the event queue. +.LP +.eM +The +.PN XSync +function +flushes the output buffer and then waits until all requests have been received +and processed by the X server. +Any errors generated must be handled by the error handler. +For each protocol error received by Xlib, +.PN XSync +calls the client application's error handling routine (see section 11.8.2). +Any events generated by the server are enqueued into the library's +event queue. +.LP +Finally, if you passed +.PN False , +.PN XSync +does not discard the events in the queue. +If you passed +.PN True , +.PN XSync +discards all events in the queue, +including those events that were on the queue before +.PN XSync +was called. +Client applications seldom need to call +.PN XSync . +.NH 2 +Event Queue Management +.XS +\*(SN Event Queue Management +.XE +.LP +Xlib maintains an event queue. +However, the operating system also may be buffering data +in its network connection that is not yet read into the event queue. +.LP +.sp +To check the number of events in the event queue, use +.PN XEventsQueued . +.IN "XEventsQueued" "" "@DEF@" +.sM +.FD 0 +int XEventsQueued\^(\^\fIdisplay\fP, \fImode\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + int \fImode\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fImode\fP 1i +Specifies the mode. +You can pass +.PN QueuedAlready , +.PN QueuedAfterFlush , +or +.PN QueuedAfterReading . +.LP +.eM +If mode is +.PN QueuedAlready , +.PN XEventsQueued +returns the number of events +already in the event queue (and never performs a system call). +If mode is +.PN QueuedAfterFlush , +.PN XEventsQueued +returns the number of events already in the queue if the number is nonzero. +If there are no events in the queue, +.PN XEventsQueued +flushes the output buffer, +attempts to read more events out of the application's connection, +and returns the number read. +If mode is +.PN QueuedAfterReading , +.PN XEventsQueued +returns the number of events already in the queue if the number is nonzero. +If there are no events in the queue, +.PN XEventsQueued +attempts to read more events out of the application's connection +without flushing the output buffer and returns the number read. +.LP +.PN XEventsQueued +always returns immediately without I/O if there are events already in the +queue. +.PN XEventsQueued +with mode +.PN QueuedAfterFlush +is identical in behavior to +.PN XPending . +.PN XEventsQueued +with mode +.PN QueuedAlready +is identical to the +.PN XQLength +function. +.LP +.sp +To return the number of events that are pending, use +.PN XPending . +.IN "XPending" "" "@DEF@" +.sM +.FD 0 +int XPending\^(\^\fIdisplay\fP\^) +.br + Display *\fIdisplay\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.LP +.eM +The +.PN XPending +function returns the number of events that have been received from the +X server but have not been removed from the event queue. +.PN XPending +is identical to +.PN XEventsQueued +with the mode +.PN QueuedAfterFlush +specified. +.NH 2 +Manipulating the Event Queue +.XS +\*(SN Manipulating the Event Queue +.XE +.LP +Xlib provides functions that let you manipulate the event queue. +This section discusses how to: +.IP \(bu 5 +Obtain events, in order, and remove them from the queue +.IP \(bu 5 +Peek at events in the queue without removing them +.IP \(bu 5 +Obtain events that match the event mask or the arbitrary +predicate procedures that you provide +.NH 3 +Returning the Next Event +.XS +\*(SN Returning the Next Event +.XE +.LP +To get the next event and remove it from the queue, use +.PN XNextEvent . +.IN "XNextEvent" "" "@DEF@" +.sM +.FD 0 +XNextEvent\^(\^\fIdisplay\fP, \fIevent_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + XEvent *\fIevent_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIevent_return\fP 1i +Returns the next event in the queue. +.LP +.eM +The +.PN XNextEvent +function copies the first event from the event queue into the specified +.PN XEvent +structure and then removes it from the queue. +If the event queue is empty, +.PN XNextEvent +flushes the output buffer and blocks until an event is received. +.LP +.sp +To peek at the event queue, use +.PN XPeekEvent . +.IN "XPeekEvent" "" "@DEF@" +.sM +.FD 0 +XPeekEvent\^(\^\fIdisplay\fP, \fIevent_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + XEvent *\fIevent_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIevent_return\fP 1i +Returns a copy of the matched event's associated structure. +.LP +.eM +The +.PN XPeekEvent +function returns the first event from the event queue, +but it does not remove the event from the queue. +If the queue is empty, +.PN XPeekEvent +flushes the output buffer and blocks until an event is received. +It then copies the event into the client-supplied +.PN XEvent +structure without removing it from the event queue. +.NH 3 +Selecting Events Using a Predicate Procedure +.XS +\*(SN Selecting Events Using a Predicate Procedure +.XE +.LP +Each of the functions discussed in this section requires you to +pass a predicate procedure that determines if an event matches +what you want. +Your predicate procedure must decide if the event is useful +without calling any Xlib functions. +If the predicate directly or indirectly causes the state of the event queue +to change, the result is not defined. +If Xlib has been initialized for threads, the predicate is called with +the display locked and the result of a call by the predicate to any +Xlib function that locks the display is not defined unless the caller +has first called +.PN XLockDisplay . +.LP +The predicate procedure and its associated arguments are: +.sM +.FD 0 +Bool (\^*\fIpredicate\fP\^)\^(\^\fIdisplay\fP, \fIevent\fP, \fIarg\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + XEvent *\fIevent\fP\^; +.br + XPointer \fIarg\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIevent\fP 1i +Specifies the +.PN XEvent +structure. +.IP \fIarg\fP 1i +Specifies the argument passed in from the +.PN XIfEvent , +.PN XCheckIfEvent , +or +.PN XPeekIfEvent +function. +.LP +.eM +The predicate procedure is called once for each +event in the queue until it finds a match. +After finding a match, the predicate procedure must return +.PN True . +If it did not find a match, it must return +.PN False . +.LP +.sp +To check the event queue for a matching event +and, if found, remove the event from the queue, use +.PN XIfEvent . +.IN "XIfEvent" "" "@DEF@" +.sM +.FD 0 +XIfEvent\^(\^\fIdisplay\fP, \fIevent_return\fP, \fIpredicate\fP, \fIarg\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + XEvent *\fIevent_return\fP\^; +.br + Bool (\^*\fIpredicate\fP\^)\^(\^)\^; +.br + XPointer \fIarg\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIevent_return\fP 1i +Returns the matched event's associated structure. +.IP \fIpredicate\fP 1i +Specifies the procedure that is to be called to determine +if the next event in the queue matches what you want. +.IP \fIarg\fP 1i +Specifies the user-supplied argument that will be passed to the predicate procedure. +.LP +.eM +The +.PN XIfEvent +function completes only when the specified predicate +procedure returns +.PN True +for an event, +which indicates an event in the queue matches. +.PN XIfEvent +flushes the output buffer if it blocks waiting for additional events. +.PN XIfEvent +removes the matching event from the queue +and copies the structure into the client-supplied +.PN XEvent +structure. +.LP +.sp +To check the event queue for a matching event without blocking, use +.PN XCheckIfEvent . +.IN "XCheckIfEvent" "" "@DEF@" +.sM +.FD 0 +Bool XCheckIfEvent\^(\^\fIdisplay\fP, \fIevent_return\fP, \fIpredicate\fP, \fIarg\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + XEvent *\fIevent_return\fP\^; +.br + Bool (\^*\fIpredicate\fP\^)\^(\^)\^; +.br + XPointer \fIarg\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIevent_return\fP 1i +Returns a copy of the matched event's associated structure. +.IP \fIpredicate\fP 1i +Specifies the procedure that is to be called to determine +if the next event in the queue matches what you want. +.IP \fIarg\fP 1i +Specifies the user-supplied argument that will be passed to the predicate procedure. +.LP +.eM +When the predicate procedure finds a match, +.PN XCheckIfEvent +copies the matched event into the client-supplied +.PN XEvent +structure and returns +.PN True . +(This event is removed from the queue.) +If the predicate procedure finds no match, +.PN XCheckIfEvent +returns +.PN False , +and the output buffer will have been flushed. +All earlier events stored in the queue are not discarded. +.LP +.sp +To check the event queue for a matching event +without removing the event from the queue, use +.PN XPeekIfEvent . +.IN "XPeekIfEvent" "" "@DEF@" +.sM +.FD 0 +XPeekIfEvent\^(\^\fIdisplay\fP, \fIevent_return\fP, \fIpredicate\fP, \fIarg\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + XEvent *\fIevent_return\fP\^; +.br + Bool (\^*\fIpredicate\fP\^)\^(\^)\^; +.br + XPointer \fIarg\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIevent_return\fP 1i +Returns a copy of the matched event's associated structure. +.IP \fIpredicate\fP 1i +Specifies the procedure that is to be called to determine +if the next event in the queue matches what you want. +.IP \fIarg\fP 1i +Specifies the user-supplied argument that will be passed to the predicate procedure. +.LP +.eM +The +.PN XPeekIfEvent +function returns only when the specified predicate +procedure returns +.PN True +for an event. +After the predicate procedure finds a match, +.PN XPeekIfEvent +copies the matched event into the client-supplied +.PN XEvent +structure without removing the event from the queue. +.PN XPeekIfEvent +flushes the output buffer if it blocks waiting for additional events. +.NH 3 +Selecting Events Using a Window or Event Mask +.XS +\*(SN Selecting Events Using a Window or Event Mask +.XE +.LP +The functions discussed in this section let you select events by window +or event types, allowing you to process events out of order. +.LP +.sp +To remove the next event that matches both a window and an event mask, use +.PN XWindowEvent . +.IN "XWindowEvent" "" "@DEF@" +.sM +.FD 0 +XWindowEvent\^(\^\fIdisplay\fP, \fIw\fP\^, \fIevent_mask\fP\^, \fIevent_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + long \fIevent_mask\fP\^; +.br + XEvent *\fIevent_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.ds Wi whose events you are interested in +.IP \fIw\fP 1i +Specifies the window \*(Wi. +.IP \fIevent_mask\fP 1i +Specifies the event mask. +.IP \fIevent_return\fP 1i +Returns the matched event's associated structure. +.LP +.eM +The +.PN XWindowEvent +function searches the event queue for an event that matches both the specified +window and event mask. +When it finds a match, +.PN XWindowEvent +removes that event from the queue and copies it into the specified +.PN XEvent +structure. +The other events stored in the queue are not discarded. +If a matching event is not in the queue, +.PN XWindowEvent +flushes the output buffer and blocks until one is received. +.LP +.sp +To remove the next event that matches both a window and an event mask (if any), +use +.PN XCheckWindowEvent . +.IN "XCheckWindowEvent" +This function is similar to +.PN XWindowEvent +except that it never blocks and it returns a +.PN Bool +indicating if the event was returned. +.IN "XCheckWindowEvent" "" "@DEF@" +.sM +.FD 0 +Bool XCheckWindowEvent\^(\^\fIdisplay\fP, \fIw\fP\^, \fIevent_mask\fP\^, \fIevent_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + long \fIevent_mask\fP\^; +.br + XEvent *\fIevent_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.ds Wi whose events you are interested in +.IP \fIw\fP 1i +Specifies the window \*(Wi. +.IP \fIevent_mask\fP 1i +Specifies the event mask. +.IP \fIevent_return\fP 1i +Returns the matched event's associated structure. +.LP +.eM +The +.PN XCheckWindowEvent +function searches the event queue and then the events available +on the server connection for the first event that matches the specified window +and event mask. +If it finds a match, +.PN XCheckWindowEvent +removes that event, copies it into the specified +.PN XEvent +structure, and returns +.PN True . +The other events stored in the queue are not discarded. +If the event you requested is not available, +.PN XCheckWindowEvent +returns +.PN False , +and the output buffer will have been flushed. +.LP +.sp +To remove the next event that matches an event mask, use +.PN XMaskEvent . +.IN "XMaskEvent" "" "@DEF@" +.sM +.FD 0 +XMaskEvent\^(\^\fIdisplay\fP, \fIevent_mask\fP\^, \fIevent_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + long \fIevent_mask\fP\^; +.br + XEvent *\fIevent_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIevent_mask\fP 1i +Specifies the event mask. +.IP \fIevent_return\fP 1i +Returns the matched event's associated structure. +.LP +.eM +The +.PN XMaskEvent +function searches the event queue for the events associated with the +specified mask. +When it finds a match, +.PN XMaskEvent +removes that event and copies it into the specified +.PN XEvent +structure. +The other events stored in the queue are not discarded. +If the event you requested is not in the queue, +.PN XMaskEvent +flushes the output buffer and blocks until one is received. +.LP +.sp +To return and remove the next event that matches an event mask (if any), use +.PN XCheckMaskEvent . +This function is similar to +.PN XMaskEvent +except that it never blocks and it returns a +.PN Bool +indicating if the event was returned. +.IN "XCheckMaskEvent" "" "@DEF@" +.sM +.FD 0 +Bool XCheckMaskEvent\^(\^\fIdisplay\fP, \fIevent_mask\fP\^, \fIevent_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + long \fIevent_mask\fP\^; +.br + XEvent *\fIevent_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIevent_mask\fP 1i +Specifies the event mask. +.IP \fIevent_return\fP 1i +Returns the matched event's associated structure. +.LP +.eM +The +.PN XCheckMaskEvent +function searches the event queue and then any events available on the +server connection for the first event that matches the specified mask. +If it finds a match, +.PN XCheckMaskEvent +removes that event, copies it into the specified +.PN XEvent +structure, and returns +.PN True . +The other events stored in the queue are not discarded. +If the event you requested is not available, +.PN XCheckMaskEvent +returns +.PN False , +and the output buffer will have been flushed. +.LP +.sp +To return and remove the next event in the queue that matches an event type, use +.PN XCheckTypedEvent . +.IN "XCheckTypedEvent" "" "@DEF@" +.sM +.FD 0 +Bool XCheckTypedEvent\^(\^\fIdisplay\fP, \fIevent_type\fP\^, \fIevent_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + int \fIevent_type\fP\^; +.br + XEvent *\fIevent_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIevent_type\fP 1i +Specifies the event type to be compared. + +.IP \fIevent_return\fP 1i +Returns the matched event's associated structure. +.LP +.eM +The +.PN XCheckTypedEvent +function searches the event queue and then any events available +on the server connection for the first event that matches the specified type. +If it finds a match, +.PN XCheckTypedEvent +removes that event, copies it into the specified +.PN XEvent +structure, and returns +.PN True . +The other events in the queue are not discarded. +If the event is not available, +.PN XCheckTypedEvent +returns +.PN False , +and the output buffer will have been flushed. +.LP +.sp +To return and remove the next event in the queue that matches an event type +and a window, use +.PN XCheckTypedWindowEvent . +.IN "XCheckTypedWindowEvent" "" "@DEF@" +.sM +.FD 0 +Bool XCheckTypedWindowEvent\^(\^\fIdisplay\fP, \fIw\fP\^, \fIevent_type\fP\^, \fIevent_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + int \fIevent_type\fP\^; +.br + XEvent *\fIevent_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fIevent_type\fP 1i +Specifies the event type to be compared. + +.IP \fIevent_return\fP 1i +Returns the matched event's associated structure. +.LP +.eM +The +.PN XCheckTypedWindowEvent +function searches the event queue and then any events available +on the server connection for the first event that matches the specified +type and window. +If it finds a match, +.PN XCheckTypedWindowEvent +removes the event from the queue, copies it into the specified +.PN XEvent +structure, and returns +.PN True . +The other events in the queue are not discarded. +If the event is not available, +.PN XCheckTypedWindowEvent +returns +.PN False , +and the output buffer will have been flushed. +.NH 2 +Putting an Event Back into the Queue +.XS +\*(SN Putting an Event Back into the Queue +.XE +.LP +To push an event back into the event queue, use +.PN XPutBackEvent . +.IN "XPutBackEvent" "" "@DEF@" +.sM +.FD 0 +XPutBackEvent\^(\^\fIdisplay\fP, \fIevent\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + XEvent *\fIevent\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIevent\fP 1i +Specifies the event. +.LP +.eM +The +.PN XPutBackEvent +function pushes an event back onto the head of the display's event queue +by copying the event into the queue. +This can be useful if you read an event and then decide that you +would rather deal with it later. +There is no limit to the number of times in succession that you can call +.PN XPutBackEvent . +.NH 2 +Sending Events to Other Applications +.XS +\*(SN Sending Events to Other Applications +.XE +.LP +To send an event to a specified window, use +.PN XSendEvent . +.IN "XSendEvent" +This function is often used in selection processing. +For example, the owner of a selection should use +.PN XSendEvent +to send a +.PN SelectionNotify +event to a requestor when a selection has been converted +and stored as a property. +.IN "XSendEvent" "" "@DEF@" +.sM +.FD 0 +Status XSendEvent\^(\^\fIdisplay\fP, \fIw\fP\^, \fIpropagate\fP\^, \fIevent_mask\fP\^, \fIevent_send\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + Bool \fIpropagate\fP\^; +.br + long \fIevent_mask\fP\^; +.br + XEvent *\fIevent_send\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window the event is to be sent to, or +.PN PointerWindow , +or +.PN InputFocus . +.IP \fIpropagate\fP 1i +Specifies a Boolean value. +.IP \fIevent_mask\fP 1i +Specifies the event mask. +.IP \fIevent_send\fP 1i +Specifies the event that is to be sent. +.LP +.eM +The +.PN XSendEvent +function identifies the destination window, +determines which clients should receive the specified events, +and ignores any active grabs. +This function requires you to pass an event mask. +For a discussion of the valid event mask names, +see section 10.3. +This function uses the w argument to identify the destination window as follows: +.IP \(bu 5 +If w is +.PN PointerWindow , +the destination window is the window that contains the pointer. +.IP \(bu 5 +If w is +.PN InputFocus +and if the focus window contains the pointer, +the destination window is the window that contains the pointer; +otherwise, the destination window is the focus window. +.LP +To determine which clients should receive the specified events, +.PN XSendEvent +uses the propagate argument as follows: +.IP \(bu 5 +If event_mask is the empty set, +the event is sent to the client that created the destination window. +If that client no longer exists, +no event is sent. +.IP \(bu 5 +If propagate is +.PN False , +the event is sent to every client selecting on destination any of the event +types in the event_mask argument. +.IP \(bu 5 +If propagate is +.PN True +and no clients have selected on destination any of +the event types in event-mask, the destination is replaced with the +closest ancestor of destination for which some client has selected a +type in event-mask and for which no intervening window has that type in its +do-not-propagate-mask. +If no such window exists or if the window is +an ancestor of the focus window and +.PN InputFocus +was originally specified +as the destination, the event is not sent to any clients. +Otherwise, the event is reported to every client selecting on the final +destination any of the types specified in event_mask. +.LP +The event in the +.PN XEvent +structure must be one of the core events or one of the events +defined by an extension (or a +.PN BadValue +error results) so that the X server can correctly byte-swap +the contents as necessary. +The contents of the event are +otherwise unaltered and unchecked by the X server except to force send_event to +.PN True +in the forwarded event and to set the serial number in the event correctly; +therefore these fields +and the display field are ignored by +.PN XSendEvent . +.LP +.PN XSendEvent +returns zero if the conversion to wire protocol format failed +and returns nonzero otherwise. +.LP +.PN XSendEvent +can generate +.PN BadValue +and +.PN BadWindow +errors. +.NH 2 +Getting Pointer Motion History +.XS +\*(SN Getting Pointer Motion History +.XE +.LP +Some X server implementations will maintain a more complete +history of pointer motion than is reported by event notification. +The pointer position at each pointer hardware interrupt may be +stored in a buffer for later retrieval. +This buffer is called the motion history buffer. +For example, a few applications, such as paint programs, +want to have a precise history of where the pointer +traveled. +However, this historical information is highly excessive for most applications. +.LP +.sp +To determine the approximate maximum number of elements in the motion buffer, +use +.PN XDisplayMotionBufferSize . +.IN "XDisplayMotionBufferSize" "" "@DEF@" +.sM +.FD 0 +unsigned long XDisplayMotionBufferSize\^(\^\fIdisplay\fP\^) +.br + Display *\fIdisplay\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.LP +.eM +The server may retain the recent history of the pointer motion +and do so to a finer granularity than is reported by +.PN MotionNotify +events. +The +.PN XGetMotionEvents +function makes this history available. +.LP +.sp +To get the motion history for a specified window and time, use +.PN XGetMotionEvents . +.IN "XGetMotionEvents" "" "@DEF@" +.sM +.FD 0 +XTimeCoord *XGetMotionEvents\^(\^\fIdisplay\fP, \fIw\fP\^, \fIstart\fP\^, \fIstop\fP\^, \fInevents_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + Time \fIstart\fP\^, \fIstop\fP\^; +.br + int *\fInevents_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fIstart\fP 1i +.br +.ns +.IP \fIstop\fP 1i +Specify the time interval in which the events are returned from the motion +history buffer. +You can pass a timestamp or +.PN CurrentTime . +.IP \fInevents_return\fP 1i +Returns the number of events from the motion history buffer. +.LP +.eM +The +.PN XGetMotionEvents +function returns all events in the motion history buffer that fall between the +specified start and stop times, inclusive, and that have coordinates +that lie within the specified window (including its borders) at its present +placement. +If the server does not support motion history, +if the start time is later than the stop time, +or if the start time is in the future, +no events are returned; +.PN XGetMotionEvents +returns NULL. +If the stop time is in the future, it is equivalent to specifying +.PN CurrentTime . +The return type for this function is a structure defined as follows: +.LP +.IN "XTimeCoord" "" "@DEF@" +.sM +.Ds 0 +.TA .5i +.ta .5i +typedef struct { + Time time; + short x, y; +} XTimeCoord; +.De +.LP +.eM +The time member is set to the time, in milliseconds. +The x and y members are set to the coordinates of the pointer and +are reported relative to the origin +of the specified window. +To free the data returned from this call, use +.PN XFree . +.LP +.PN XGetMotionEvents +can generate a +.PN BadWindow +error. +.NH 2 +Handling Protocol Errors +.XS +\*(SN Handling Protocol Errors +.XE +.LP +Xlib provides functions that you can use to enable or disable synchronization +and to use the default error handlers. +.NH 3 +Enabling or Disabling Synchronization +.XS +\*(SN Enabling or Disabling Synchronization +.XE +.LP +When debugging X applications, +it often is very convenient to require Xlib to behave synchronously +so that errors are reported as they occur. +The following function lets you disable or enable synchronous behavior. +Note that graphics may occur 30 or more times more slowly when +synchronization is enabled. +.IN "_Xdebug" +On POSIX-conformant systems, +there is also a global variable +.PN _Xdebug +that, if set to nonzero before starting a program under a debugger, will force +synchronous library behavior. +.LP +After completing their work, +all Xlib functions that generate protocol requests call what is known as +an after function. +.PN XSetAfterFunction +sets which function is to be called. +.IN "XSetAfterFunction" "" "@DEF@" +.sM +.FD 0 +int (*XSetAfterFunction\^(\^\fIdisplay\fP, \fIprocedure\fP\^))() +.br + Display *\fIdisplay\fP\^; +.br + int (\^*\^\fIprocedure\fP\^)\^(); +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIprocedure\fP 1i +Specifies the procedure to be called. +.LP +.eM +The specified procedure is called with only a display pointer. +.PN XSetAfterFunction +returns the previous after function. +.LP +To enable or disable synchronization, use +.PN XSynchronize . +.IN "Debugging" "synchronous mode" +.IN "XSynchronize" "" "@DEF@" +.sM +.FD 0 +int (*XSynchronize\^(\^\fIdisplay\fP, \fIonoff\fP\^)\^)() +.br + Display *\fIdisplay\fP\^; +.br + Bool \fIonoff\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIonoff\fP 1i +Specifies a Boolean value that indicates whether to enable +or disable synchronization. +.LP +.eM +The +.PN XSynchronize +function returns +the previous after function. +If onoff is +.PN True , +.PN XSynchronize +turns on synchronous behavior. +If onoff is +.PN False , +.PN XSynchronize +turns off synchronous behavior. +.NH 3 +Using the Default Error Handlers +.XS +\*(SN Using the Default Error Handlers +.XE +.LP +.IN "Debugging" "error handlers" +.IN "Error" "handlers" +There are two default error handlers in Xlib: +one to handle typically fatal conditions (for example, +the connection to a display server dying because a machine crashed) +and one to handle protocol errors from the X server. +These error handlers can be changed to user-supplied routines if you +prefer your own error handling and can be changed as often as you like. +If either function is passed a NULL pointer, it will +reinvoke the default handler. +The action of the default handlers is to print an explanatory +message and exit. +.LP +.sp +To set the error handler, use +.PN XSetErrorHandler . +.IN "XSetErrorHandler" "" "@DEF@" +.sM +.FD 0 +int (*XSetErrorHandler\^(\^\fIhandler\fP\^)\^)\^(\^) +.br + int (\^*\^\fIhandler\fP\^)\^(Display *, XErrorEvent *) +.FN +.IP \fIhandler\fP 1i +Specifies the program's supplied error handler. +.LP +.eM +Xlib generally calls the program's +supplied error handler whenever an error is received. +It is not called on +.PN BadName +errors from +.PN OpenFont , +.PN LookupColor , +or +.PN AllocNamedColor +protocol requests or on +.PN BadFont +errors from a +.PN QueryFont +protocol request. +These errors generally are reflected back to the program through the +procedural interface. +Because this condition is not assumed to be fatal, +it is acceptable for your error handler to return; +the returned value is ignored. +However, the error handler should not +call any functions (directly or indirectly) on the display +that will generate protocol requests or that will look for input events. +The previous error handler is returned. +.LP +The +.PN XErrorEvent +structure contains: +.IN "Debugging" "error event" +.LP +.IN "XErrorEvent" "" "@DEF" +.Ds 0 +.TA .5i 2.5i +.ta .5i 2.5i +typedef struct { + int type; + Display *display; /* Display the event was read from */ + unsigned long serial; /* serial number of failed request */ + unsigned char error_code; /* error code of failed request */ + unsigned char request_code; /* Major op-code of failed request */ + unsigned char minor_code; /* Minor op-code of failed request */ + XID resourceid; /* resource id */ +} XErrorEvent; +.De +.LP +.IN "Serial Number" +The serial member is the number of requests, starting from one, +sent over the network connection since it was opened. +It is the number that was the value of +.PN NextRequest +immediately before the failing call was made. +The request_code member is a protocol request +of the procedure that failed, as defined in +.hN X11/Xproto.h . +The following error codes can be returned by the functions described in this +chapter: +.br +.ne 13 +.IN "Debugging" "error numbers" +.IN "Error" "codes" +.\".CP T 3 +.\"Error Codes +.IN "BadAccess" "" "@DEF@" +.IN "BadAlloc" "" "@DEF@" +.IN "BadAtom" "" "@DEF@" +.IN "BadColor" "" "@DEF@" +.IN "BadCursor" "" "@DEF@" +.IN "BadDrawable" "" "@DEF@" +.IN "BadFont" "" "@DEF@" +.IN "BadGC" "" "@DEF@" +.IN "BadIDChoice" "" "@DEF@" +.TS H +l c +lw(1.75i) lw(4i). +_ +.sp 6p +.B +Error Code Description +.sp 6p +_ +.sp 6p +.TH +.R +T{ +.PN BadAccess +T} T{ +A client attempts to grab a key/button combination already grabbed +by another client. +.sp 3p +A client attempts to free a colormap entry that it had not already allocated +or to free an entry in a colormap that was created with all entries writable. +.sp 3p +A client attempts to store into a read-only or unallocated colormap entry. +.sp 3p +A client attempts to modify the access control list from other than the local +(or otherwise authorized) host. +.sp 3p +A client attempts to select an event type that another client +has already selected. +T} +.sp 3p +T{ +.PN BadAlloc +T} T{ +The server fails to allocate the requested resource. +Note that the explicit listing of +.PN BadAlloc +errors in requests only covers allocation errors at a very coarse level +and is not intended to (nor can it in practice hope to) cover all cases of +a server running out of allocation space in the middle of service. +The semantics when a server runs out of allocation space are left unspecified, +but a server may generate a +.PN BadAlloc +error on any request for this reason, +and clients should be prepared to receive such errors and handle or discard +them. +T} +.sp 3p +T{ +.PN BadAtom +T} T{ +A value for an atom argument does not name a defined atom. +T} +.sp 3p +T{ +.PN BadColor +T} T{ +A value for a colormap argument does not name a defined colormap. +T} +.sp 3p +T{ +.PN BadCursor +T} T{ +A value for a cursor argument does not name a defined cursor. +T} +.sp 3p +T{ +.PN BadDrawable +T} T{ +A value for a drawable argument does not name a defined window or pixmap. +T} +.sp 3p +T{ +.PN BadFont +T} T{ +A value for a font argument does not name a defined font (or, in some cases, +.PN GContext ). +T} +.sp 3p +T{ +.PN BadGC +T} T{ +A value for a +.PN GContext +argument does not name a defined +.PN GContext . +T} +.sp 3p +T{ +.PN BadIDChoice +T} T{ +The value chosen for a resource identifier either is not included in the +range assigned to the client or is already in use. +Under normal circumstances, +this cannot occur and should be considered a server or Xlib error. +T} +.sp 3p +T{ +.PN BadImplementation +T} T{ +The server does not implement some aspect of the request. +A server that generates this error for a core request is deficient. +As such, this error is not listed for any of the requests, +but clients should be prepared to receive such errors +and handle or discard them. +T} +.sp 3p +T{ +.PN BadLength +T} T{ +The length of a request is shorter or longer than that required to +contain the arguments. +This is an internal Xlib or server error. +.sp 3p +The length of a request exceeds the maximum length accepted by the server. +T} +.sp 3p +T{ +.PN BadMatch +T} T{ +In a graphics request, +the root and depth of the graphics context do not match those of the drawable. +.sp 3p +An +.PN InputOnly +window is used as a drawable. +.sp 3p +Some argument or pair of arguments has the correct type and range, +but it fails to match in some other way required by the request. +.sp 3p +An +.PN InputOnly +window lacks this attribute. +T} +.sp 3p +T{ +.PN BadName +T} T{ +A font or color of the specified name does not exist. +T} +.sp 3p +T{ +.PN BadPixmap +T} T{ +A value for a pixmap argument does not name a defined pixmap. +T} +.sp 3p +T{ +.PN BadRequest +T} T{ +The major or minor opcode does not specify a valid request. +This usually is an Xlib or server error. +T} +.sp 3p +T{ +.PN BadValue +T} T{ +Some numeric value falls outside of the range of values accepted +by the request. +Unless a specific range is specified for an argument, +the full range defined by the argument's type is accepted. +Any argument defined as a set of alternatives typically can generate +this error (due to the encoding). +T} +.sp 3p +T{ +.PN BadWindow +T} T{ +A value for a window argument does not name a defined window. +T} +.sp 6p +_ +.TE +.IN "BadImplementation" "" "@DEF@" +.IN "BadLength" "" "@DEF@" +.IN "BadMatch" "" "@DEF@" +.IN "BadName" "" "@DEF@" +.IN "BadPixmap" "" "@DEF@" +.IN "BadRequest" "" "@DEF@" +.IN "BadValue" "" "@DEF@" +.IN "BadWindow" "" "@DEF@" +.NT Note +The +.PN BadAtom , +.PN BadColor , +.PN BadCursor , +.PN BadDrawable , +.PN BadFont , +.PN BadGC , +.PN BadPixmap , +and +.PN BadWindow +errors are also used when the argument type is extended by a set of +fixed alternatives. +.NE +.sp +.LP +To obtain textual descriptions of the specified error code, use +.PN XGetErrorText . +.IN "XGetErrorText" "" "@DEF@" +.IN "Debugging" "error message strings" +.sM +.FD 0 +XGetErrorText\^(\^\fIdisplay\fP, \fIcode\fP, \fIbuffer_return\fP, \fIlength\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + int \fIcode\fP\^; +.br + char *\fIbuffer_return\fP\^; +.br + int \fIlength\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIcode\fP 1i +Specifies the error code for which you want to obtain a description. +.IP \fIbuffer_return\fP 1i +Returns the error description. +.IP \fIlength\fP 1i +Specifies the size of the buffer. +.LP +.eM +The +.PN XGetErrorText +function copies a null-terminated string describing the specified error code +into the specified buffer. +The returned text is in the encoding of the current locale. +It is recommended that you use this function to obtain an error description +because extensions to Xlib may define their own error codes +and error strings. +.LP +.sp +To obtain error messages from the error database, use +.PN XGetErrorDatabaseText . +.IN "XGetErrorDatabaseText" "" "@DEF@" +.sM +.FD 0 +XGetErrorDatabaseText\^(\^\fIdisplay\fP, \fIname\fP, \fImessage\fP, \fIdefault_string\fP, \fIbuffer_return\fP, \fIlength\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + char *\fIname\fP, *\fImessage\fP\^; +.br + char *\fIdefault_string\fP\^; +.br + char *\fIbuffer_return\fP\^; +.br + int \fIlength\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIname\fP 1i +Specifies the name of the application. +.IP \fImessage\fP 1i +Specifies the type of the error message. +.IP \fIdefault_string\fP 1i +Specifies the default error message if none is found in the database. +.IP \fIbuffer_return\fP 1i +Returns the error description. +.IP \fIlength\fP 1i +Specifies the size of the buffer. +.LP +.eM +The +.PN XGetErrorDatabaseText +function returns a null-terminated message +(or the default message) from the error message +database. +Xlib uses this function internally to look up its error messages. +The text in the default_string argument is assumed +to be in the encoding of the current locale, +and the text stored in the buffer_return argument +is in the encoding of the current locale. +.LP +The name argument should generally be the name of your application. +The message argument should indicate which type of error message you want. +If the name and message are not in the Host Portable Character Encoding, +the result is implementation-dependent. +Xlib uses three predefined ``application names'' to report errors. +In these names, +uppercase and lowercase matter. +.IP XProtoError 1i +The protocol error number is used as a string for the message argument. +.IP XlibMessage 1i +These are the message strings that are used internally by the library. +.IP XRequest 1i +For a core protocol request, +the major request protocol number is used for the message argument. +For an extension request, +the extension name (as given by +.PN InitExtension ) +followed by a period (\.) and the minor request protocol number +is used for the message argument. +If no string is found in the error database, +the default_string is returned to the buffer argument. +.LP +.sp +To report an error to the user when the requested display does not exist, use +.PN XDisplayName . +.IN "XDisplayName" "" "@DEF@" +.sM +.FD 0 +char *XDisplayName\^(\^\fIstring\fP\^) +.br + char *\fIstring\fP\^; +.FN +.IP \fIstring\fP 1i +Specifies the character string. +.LP +.eM +The +.PN XDisplayName +function returns the name of the display that +.PN XOpenDisplay +would attempt to use. +If a NULL string is specified, +.PN XDisplayName +looks in the environment for the display and returns the display name that +.PN XOpenDisplay +would attempt to use. +This makes it easier to report to the user precisely which display the +program attempted to open when the initial connection attempt failed. +.LP +.sp +To handle fatal I/O errors, use +.PN XSetIOErrorHandler . +.IN "XSetIOErrorHandler" "" "@DEF@" +.sM +.FD 0 +int (*XSetIOErrorHandler\^(\^\fIhandler\fP\^)\^)\^(\^) +.br + int (\^*\^\fIhandler\fP\^)(Display *); +.FN +.IP \fIhandler\fP 1i +Specifies the program's supplied error handler. +.LP +.eM +The +.PN XSetIOErrorHandler +sets the fatal I/O error handler. +Xlib calls the program's supplied error handler if any sort of system call +error occurs (for example, the connection to the server was lost). +This is assumed to be a fatal condition, +and the called routine should not return. +If the I/O error handler does return, +the client process exits. +.LP +Note that the previous error handler is returned. +.bp diff --git a/libX11/specs/libX11/CH12 b/libX11/specs/libX11/CH12 new file mode 100644 index 000000000..08b9ba93a --- /dev/null +++ b/libX11/specs/libX11/CH12 @@ -0,0 +1,2680 @@ +.\" Copyright \(co 1985, 1986, 1987, 1988, 1989, 1990, 1991, 1994, 1996 X Consortium +.\" +.\" 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 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 X CONSORTIUM 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 X Consortium 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 X Consortium. +.\" +.\" Copyright \(co 1985, 1986, 1987, 1988, 1989, 1990, 1991 by +.\" Digital Equipment Corporation +.\" +.\" Portions Copyright \(co 1990, 1991 by +.\" Tektronix, Inc. +.\" +.\" Permission to use, copy, modify and distribute this documentation for +.\" any purpose and without fee is hereby granted, provided that the above +.\" copyright notice appears in all copies and that both that copyright notice +.\" and this permission notice appear in all copies, and that the names of +.\" Digital and Tektronix not be used in in advertising or publicity pertaining +.\" to this documentation without specific, written prior permission. +.\" Digital and Tektronix makes no representations about the suitability +.\" of this documentation for any purpose. +.\" It is provided ``as is'' without express or implied warranty. +.\" +\& +.sp 1 +.ce 3 +\s+1\fBChapter 12\fP\s-1 + +\s+1\fBInput Device Functions\fP\s-1 +.sp 2 +.nr H1 12 +.nr H2 0 +.nr H3 0 +.nr H4 0 +.nr H5 0 +.na +.LP +.XS +Chapter 12: Input Device Functions +.XE +You can use the Xlib input device functions to: +.IP \(bu 5 +Grab the pointer and individual buttons on the pointer +.IP \(bu 5 +Grab the keyboard and individual keys on the keyboard +.IP \(bu 5 +Resume event processing +.IP \(bu 5 +Move the pointer +.IP \(bu 5 +Set the input focus +.IP \(bu 5 +Manipulate the keyboard and pointer settings +.IP \(bu 5 +Manipulate the keyboard encoding +.NH 2 +Pointer Grabbing +.XS +\*(SN Pointer Grabbing +.XE +.LP +Xlib provides functions that you can use to control input from the pointer, +which usually is a mouse. +Usually, as soon as keyboard and mouse events occur, +the X server delivers them to the appropriate client, +which is determined by the window and input focus. +The X server provides sufficient control over event delivery to +allow window managers to support mouse ahead and various other +styles of user interface. +Many of these user interfaces depend on synchronous delivery of events. +The delivery of pointer and keyboard events can be controlled +independently. +.LP +When mouse buttons or keyboard keys are grabbed, events +will be sent to the grabbing client rather than the normal +client who would have received the event. +If the keyboard or pointer is in asynchronous mode, +further mouse and keyboard events will continue to be processed. +If the keyboard or pointer is in synchronous mode, no +further events are processed until the grabbing client +allows them (see +.PN XAllowEvents ). +The keyboard or pointer is considered frozen during this +interval. +The event that triggered the grab can also be replayed. +.LP +Note that the logical state of a device (as seen by client applications) +may lag the physical state if device event processing is frozen. +.LP +.IN "Active grab" "" "@DEF@" +There are two kinds of grabs: +active and passive. +An active grab occurs when a single client grabs the keyboard and/or pointer +explicitly (see +.PN XGrabPointer +and +.PN XGrabKeyboard ). +.IN "Passive grab" +A passive grab occurs when clients grab a particular keyboard key +or pointer button in a window, +and the grab will activate when the key or button is actually pressed. +Passive grabs are convenient for implementing reliable pop-up menus. +For example, you can guarantee that the pop-up is mapped +before the up pointer button event occurs by +grabbing a button requesting synchronous behavior. +The down event will trigger the grab and freeze further +processing of pointer events until you have the chance to +map the pop-up window. +You can then allow further event processing. +The up event will then be correctly processed relative to the +pop-up window. +.LP +For many operations, +there are functions that take a time argument. +The X server includes a timestamp in various events. +One special time, called +.IN "CurrentTime" "" "@DEF@" +.IN "Time" "" "@DEF@" +.PN CurrentTime , +represents the current server time. +The X server maintains the time when the input focus was last changed, +when the keyboard was last grabbed, +when the pointer was last grabbed, +or when a selection was last changed. +Your +application may be slow reacting to an event. +You often need some way to specify that your +request should not occur if another application has in the meanwhile +taken control of the keyboard, pointer, or selection. +By providing the timestamp from the event in the request, +you can arrange that the operation not take effect +if someone else has performed an operation in the meanwhile. +.LP +A timestamp is a time value, expressed in milliseconds. +It typically is the time since the last server reset. +Timestamp values wrap around (after about 49.7 days). +The server, given its current time is represented by timestamp T, +always interprets timestamps from clients by treating half of the timestamp +space as being later in time than T. +One timestamp value, named +.PN CurrentTime , +is never generated by the server. +This value is reserved for use in requests to represent the current server time. +.LP +For many functions in this section, +you pass pointer event mask bits. +The valid pointer event mask bits are: +.PN ButtonPressMask , +.PN ButtonReleaseMask , +.PN EnterWindowMask , +.PN LeaveWindowMask , +.PN PointerMotionMask , +.PN PointerMotionHintMask , +.PN Button1MotionMask , +.PN Button2MotionMask , +.PN Button3MotionMask , +.PN Button4MotionMask , +.PN Button5MotionMask , +.PN ButtonMotionMask , +and +.PN KeyMapStateMask . +For other functions in this section, +you pass keymask bits. +The valid keymask bits are: +.PN ShiftMask , +.PN LockMask , +.PN ControlMask , +.PN Mod1Mask , +.PN Mod2Mask , +.PN Mod3Mask , +.PN Mod4Mask , +and +.PN Mod5Mask . +.LP +.sp +To grab the pointer, use +.PN XGrabPointer . +.IN "Grabbing" "pointer" +.IN "Pointer" "grabbing" +.IN "XGrabPointer" "" "@DEF@" +.sM +.FD 0 +int XGrabPointer\^(\^\fIdisplay\fP, \fIgrab_window\fP\^, \fIowner_events\fP\^, \fIevent_mask\fP\^, \fIpointer_mode\fP\^, + \fIkeyboard_mode\fP\^, \fIconfine_to\fP\^, \fIcursor\fP\^, \fItime\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIgrab_window\fP\^; +.br + Bool \fIowner_events\fP\^; +.br + unsigned int \fIevent_mask\fP\^; +.br + int \fIpointer_mode\fP\^, \fIkeyboard_mode\fP\^; +.br + Window \fIconfine_to\fP\^; +.br + Cursor \fIcursor\fP\^; +.br + Time \fItime\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIgrab_window\fP 1i +Specifies the grab window. +.IP \fIowner_events\fP 1i +Specifies a Boolean value that indicates whether the pointer +events are to be reported as usual or reported with respect to the grab window +if selected by the event mask. +.IP \fIevent_mask\fP 1i +Specifies which pointer events are reported to the client. +The mask is the bitwise inclusive OR of the valid pointer event mask bits. +.IP \fIpointer_mode\fP 1i +Specifies further processing of pointer events. +You can pass +.PN GrabModeSync +or +.PN GrabModeAsync . +.IP \fIkeyboard_mode\fP 1i +Specifies further processing of keyboard events. +You can pass +.PN GrabModeSync +or +.PN GrabModeAsync . +.IP \fIconfine_to\fP 1i +Specifies the window to confine the pointer in or +.PN None . +.IP \fIcursor\fP 1i +Specifies the cursor that is to be displayed during the grab or +.PN None . +.IP \fItime\fP 1i +Specifies the time. +You can pass either a timestamp or +.PN CurrentTime . +.LP +.eM +The +.PN XGrabPointer +function actively grabs control of the pointer and returns +.PN GrabSuccess +if the grab was successful. +Further pointer events are reported only to the grabbing client. +.PN XGrabPointer +overrides any active pointer grab by this client. +If owner_events is +.PN False , +all generated pointer events +are reported with respect to grab_window and are reported only if +selected by event_mask. +If owner_events is +.PN True +and if a generated +pointer event would normally be reported to this client, +it is reported as usual. +Otherwise, the event is reported with respect to the +grab_window and is reported only if selected by event_mask. +For either value of owner_events, unreported events are discarded. +.LP +If the pointer_mode is +.PN GrabModeAsync , +pointer event processing continues as usual. +If the pointer is currently frozen by this client, +the processing of events for the pointer is resumed. +If the pointer_mode is +.PN GrabModeSync , +the state of the pointer, as seen by +client applications, +appears to freeze, and the X server generates no further pointer events +until the grabbing client calls +.PN XAllowEvents +or until the pointer grab is released. +Actual pointer changes are not lost while the pointer is frozen; +they are simply queued in the server for later processing. +.LP +If the keyboard_mode is +.PN GrabModeAsync , +keyboard event processing is unaffected by activation of the grab. +If the keyboard_mode is +.PN GrabModeSync , +the state of the keyboard, as seen by +client applications, +appears to freeze, and the X server generates no further keyboard events +until the grabbing client calls +.PN XAllowEvents +or until the pointer grab is released. +Actual keyboard changes are not lost while the pointer is frozen; +they are simply queued in the server for later processing. +.LP +If a cursor is specified, it is displayed regardless of what +window the pointer is in. +If +.PN None +is specified, +the normal cursor for that window is displayed +when the pointer is in grab_window or one of its subwindows; +otherwise, the cursor for grab_window is displayed. +.LP +If a confine_to window is specified, +the pointer is restricted to stay contained in that window. +The confine_to window need have no relationship to the grab_window. +If the pointer is not initially in the confine_to window, +it is warped automatically to the closest edge +just before the grab activates and enter/leave events are generated as usual. +If the confine_to window is subsequently reconfigured, +the pointer is warped automatically, as necessary, +to keep it contained in the window. +.LP +The time argument allows you to avoid certain circumstances that come up +if applications take a long time to respond or if there are long network +delays. +Consider a situation where you have two applications, both +of which normally grab the pointer when clicked on. +If both applications specify the timestamp from the event, +the second application may wake up faster and successfully grab the pointer +before the first application. +The first application then will get an indication that the other application +grabbed the pointer before its request was processed. +.LP +.PN XGrabPointer +generates +.PN EnterNotify +and +.PN LeaveNotify +events. +.LP +Either if grab_window or confine_to window is not viewable +or if the confine_to window lies completely outside the boundaries of the root +window, +.PN XGrabPointer +fails and returns +.PN GrabNotViewable . +If the pointer is actively grabbed by some other client, +it fails and returns +.PN AlreadyGrabbed . +If the pointer is frozen by an active grab of another client, +it fails and returns +.PN GrabFrozen . +If the specified time is earlier than the last-pointer-grab time or later +than the current X server time, it fails and returns +.PN GrabInvalidTime . +Otherwise, the last-pointer-grab time is set to the specified time +.Pn ( CurrentTime +is replaced by the current X server time). +.LP +.PN XGrabPointer +can generate +.PN BadCursor , +.PN BadValue , +and +.PN BadWindow +errors. +.LP +.sp +To ungrab the pointer, use +.PN XUngrabPointer . +.IN "Ungrabbing" "pointer" +.IN "Pointer" "ungrabbing" +.IN "XUngrabPointer" "" "@DEF@" +.sM +.FD 0 +XUngrabPointer\^(\^\fIdisplay\fP, \fItime\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Time \fItime\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fItime\fP 1i +Specifies the time. +You can pass either a timestamp or +.PN CurrentTime . +.LP +.eM +The +.PN XUngrabPointer +function releases the pointer and any queued events +if this client has actively grabbed the pointer from +.PN XGrabPointer , +.PN XGrabButton , +or from a normal button press. +.PN XUngrabPointer +does not release the pointer if the specified +time is earlier than the last-pointer-grab time or is later than the +current X server time. +It also generates +.PN EnterNotify +and +.PN LeaveNotify +events. +The X server performs an +.PN UngrabPointer +request automatically if the event window or confine_to window +for an active pointer grab becomes not viewable +or if window reconfiguration causes the confine_to window to lie completely +outside the boundaries of the root window. +.LP +.sp +To change an active pointer grab, use +.PN XChangeActivePointerGrab . +.IN "Pointer" "grabbing" +.IN "Changing" "pointer grab" +.IN "XChangeActivePointerGrab" "" "@DEF@" +.sM +.FD 0 +XChangeActivePointerGrab\^(\^\fIdisplay\fP, \fIevent_mask\fP\^, \fIcursor\fP\^, \fItime\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + unsigned int \fIevent_mask\fP\^; +.br + Cursor \fIcursor\fP\^; +.br + Time \fItime\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIevent_mask\fP 1i +Specifies which pointer events are reported to the client. +The mask is the bitwise inclusive OR of the valid pointer event mask bits. +.IP \fIcursor\fP 1i +Specifies the cursor that is to be displayed or +.PN None . +.IP \fItime\fP 1i +Specifies the time. +You can pass either a timestamp or +.PN CurrentTime . +.LP +.eM +The +.PN XChangeActivePointerGrab +function changes the specified dynamic parameters if the pointer is actively +grabbed by the client and if the specified time is no earlier than the +last-pointer-grab time and no later than the current X server time. +This function has no effect on the passive parameters of an +.PN XGrabButton . +The interpretation of event_mask and cursor is the same as described in +.PN XGrabPointer . +.LP +.PN XChangeActivePointerGrab +can generate +.PN BadCursor +and +.PN BadValue +errors. +.LP +.sp +To grab a pointer button, use +.PN XGrabButton . +.IN "Grabbing" "buttons" +.IN "Button" "grabbing" +.IN "XGrabButton" "" "@DEF@" +.sM +.FD 0 +XGrabButton\^(\^\fIdisplay\fP, \fIbutton\fP\^, \fImodifiers\fP\^, \fIgrab_window\fP\^, \fIowner_events\fP\^, \fIevent_mask\fP\^, +.br + \fIpointer_mode\fP\^, \fIkeyboard_mode\fP\^, \fIconfine_to\fP\^, \fIcursor\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + unsigned int \fIbutton\fP\^; +.br + unsigned int \fImodifiers\fP\^; +.br + Window \fIgrab_window\fP\^; +.br + Bool \fIowner_events\fP\^; +.br + unsigned int \fIevent_mask\fP\^; +.br + int \fIpointer_mode\fP\^, \fIkeyboard_mode\fP\^; +.br + Window \fIconfine_to\fP\^; +.br + Cursor \fIcursor\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.ds Bu grabbed +.IP \fIbutton\fP 1i +Specifies the pointer button that is to be \*(Bu or +.PN AnyButton . +.IP \fImodifiers\fP 1i +Specifies the set of keymasks or +.PN AnyModifier . +The mask is the bitwise inclusive OR of the valid keymask bits. +.IP \fIgrab_window\fP 1i +Specifies the grab window. +.IP \fIowner_events\fP 1i +Specifies a Boolean value that indicates whether the pointer +events are to be reported as usual or reported with respect to the grab window +if selected by the event mask. +.IP \fIevent_mask\fP 1i +Specifies which pointer events are reported to the client. +The mask is the bitwise inclusive OR of the valid pointer event mask bits. +.IP \fIpointer_mode\fP 1i +Specifies further processing of pointer events. +You can pass +.PN GrabModeSync +or +.PN GrabModeAsync . +.IP \fIkeyboard_mode\fP 1i +Specifies further processing of keyboard events. +You can pass +.PN GrabModeSync +or +.PN GrabModeAsync . +.IP \fIconfine_to\fP 1i +Specifies the window to confine the pointer in or +.PN None . +.IP \fIcursor\fP 1i +Specifies the cursor that is to be displayed or +.PN None . +.LP +.eM +The +.PN XGrabButton +function establishes a passive grab. +In the future, +the pointer is actively grabbed (as for +.PN XGrabPointer ), +the last-pointer-grab time is set to the time at which the button was pressed +(as transmitted in the +.PN ButtonPress +event), and the +.PN ButtonPress +event is reported if all of the following conditions are true: +.IP \(bu 5 +The pointer is not grabbed, and the specified button is logically pressed +when the specified modifier keys are logically down, +and no other buttons or modifier keys are logically down. +.IP \(bu 5 +The grab_window contains the pointer. +.IP \(bu 5 +The confine_to window (if any) is viewable. +.IP \(bu 5 +A passive grab on the same button/key combination does not exist +on any ancestor of grab_window. +.LP +The interpretation of the remaining arguments is as for +.PN XGrabPointer . +The active grab is terminated automatically when the logical state of the +pointer has all buttons released +(independent of the state of the logical modifier keys). +.LP +Note that the logical state of a device (as seen by client applications) +may lag the physical state if device event processing is frozen. +.LP +This request overrides all previous grabs by the same client on the same +button/key combinations on the same window. +A modifiers of +.PN AnyModifier +is equivalent to issuing the grab request for all +possible modifier combinations (including the combination of no modifiers). +It is not required that all modifiers specified have currently assigned +KeyCodes. +A button of +.PN AnyButton +is equivalent to +issuing the request for all possible buttons. +Otherwise, it is not required that the specified button currently be assigned +to a physical button. +.LP +If some other client has already issued an +.PN XGrabButton +with the same button/key combination on the same window, a +.PN BadAccess +error results. +When using +.PN AnyModifier +or +.PN AnyButton , +the request fails completely, +and a +.PN BadAccess +error results (no grabs are +established) if there is a conflicting grab for any combination. +.PN XGrabButton +has no effect on an active grab. +.LP +.PN XGrabButton +can generate +.PN BadCursor , +.PN BadValue , +and +.PN BadWindow +errors. +.LP +.sp +To ungrab a pointer button, use +.PN XUngrabButton . +.IN "Ungrabbing" "buttons" +.IN "Button" "ungrabbing" +.IN "XUngrabButton" "" "@DEF@" +.sM +.FD 0 +XUngrabButton\^(\^\fIdisplay\fP, \fIbutton\fP\^, \fImodifiers\fP\^, \fIgrab_window\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + unsigned int \fIbutton\fP\^; +.br + unsigned int \fImodifiers\fP\^; +.br + Window \fIgrab_window\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.ds Bu released +.IP \fIbutton\fP 1i +Specifies the pointer button that is to be \*(Bu or +.PN AnyButton . +.IP \fImodifiers\fP 1i +Specifies the set of keymasks or +.PN AnyModifier . +The mask is the bitwise inclusive OR of the valid keymask bits. +.IP \fIgrab_window\fP 1i +Specifies the grab window. +.LP +.eM +The +.PN XUngrabButton +function releases the passive button/key combination on the specified window if +it was grabbed by this client. +A modifiers of +.PN AnyModifier +is +equivalent to issuing +the ungrab request for all possible modifier combinations, including +the combination of no modifiers. +A button of +.PN AnyButton +is equivalent to issuing the +request for all possible buttons. +.PN XUngrabButton +has no effect on an active grab. +.LP +.PN XUngrabButton +can generate +.PN BadValue +and +.PN BadWindow +errors. +.NH 2 +Keyboard Grabbing +.XS +\*(SN Keyboard Grabbing +.XE +.LP +Xlib provides functions that you can use to grab or ungrab the keyboard +as well as allow events. +.LP +For many functions in this section, +you pass keymask bits. +The valid keymask bits are: +.PN ShiftMask , +.PN LockMask , +.PN ControlMask , +.PN Mod1Mask , +.PN Mod2Mask , +.PN Mod3Mask , +.PN Mod4Mask , +and +.PN Mod5Mask . +.LP +.sp +To grab the keyboard, use +.PN XGrabKeyboard . +.IN "Keyboard" "grabbing" +.IN "Grabbing" "keyboard" +.IN "XGrabKeyboard" "" "@DEF@" +.sM +.FD 0 +int XGrabKeyboard\^(\^\fIdisplay\fP, \fIgrab_window\fP\^, \fIowner_events\fP\^, \fIpointer_mode\fP\^, \fIkeyboard_mode\fP\^, \fItime\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIgrab_window\fP\^; +.br + Bool \fIowner_events\fP\^; +.br + int \fIpointer_mode\fP\^, \fIkeyboard_mode\fP\^; +.br + Time \fItime\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIgrab_window\fP 1i +Specifies the grab window. +.IP \fIowner_events\fP 1i +Specifies a Boolean value that indicates whether the keyboard events +are to be reported as usual. +.IP \fIpointer_mode\fP 1i +Specifies further processing of pointer events. +You can pass +.PN GrabModeSync +or +.PN GrabModeAsync . +.IP \fIkeyboard_mode\fP 1i +Specifies further processing of keyboard events. +You can pass +.PN GrabModeSync +or +.PN GrabModeAsync . +.IP \fItime\fP 1i +Specifies the time. +You can pass either a timestamp or +.PN CurrentTime . +.LP +.eM +The +.PN XGrabKeyboard +function actively grabs control of the keyboard and generates +.PN FocusIn +and +.PN FocusOut +events. +Further key events are reported only to the +grabbing client. +.PN XGrabKeyboard +overrides any active keyboard grab by this client. +If owner_events is +.PN False , +all generated key events are reported with +respect to grab_window. +If owner_events is +.PN True +and if a generated +key event would normally be reported to this client, it is reported +normally; otherwise, the event is reported with respect to the +grab_window. +Both +.PN KeyPress +and +.PN KeyRelease +events are always reported, +independent of any event selection made by the client. +.LP +If the keyboard_mode argument is +.PN GrabModeAsync , +keyboard event processing continues +as usual. +If the keyboard is currently frozen by this client, +then processing of keyboard events is resumed. +If the keyboard_mode argument is +.PN GrabModeSync , +the state of the keyboard (as seen by client applications) appears to freeze, +and the X server generates no further keyboard events until the +grabbing client issues a releasing +.PN XAllowEvents +call or until the keyboard grab is released. +Actual keyboard changes are not lost while the keyboard is frozen; +they are simply queued in the server for later processing. +.LP +If pointer_mode is +.PN GrabModeAsync , +pointer event processing is unaffected +by activation of the grab. +If pointer_mode is +.PN GrabModeSync , +the state of the pointer (as seen by client applications) appears to freeze, +and the X server generates no further pointer events +until the grabbing client issues a releasing +.PN XAllowEvents +call or until the keyboard grab is released. +Actual pointer changes are not lost while the pointer is frozen; +they are simply queued in the server for later processing. +.LP +If the keyboard is actively grabbed by some other client, +.PN XGrabKeyboard +fails and returns +.PN AlreadyGrabbed . +If grab_window is not viewable, +it fails and returns +.PN GrabNotViewable . +If the keyboard is frozen by an active grab of another client, +it fails and returns +.PN GrabFrozen . +If the specified time is earlier than the last-keyboard-grab time +or later than the current X server time, +it fails and returns +.PN GrabInvalidTime . +Otherwise, the last-keyboard-grab time is set to the specified time +.Pn ( CurrentTime +is replaced by the current X server time). +.LP +.PN XGrabKeyboard +can generate +.PN BadValue +and +.PN BadWindow +errors. +.LP +.sp +To ungrab the keyboard, use +.PN XUngrabKeyboard . +.IN "Keyboard" "ungrabbing" +.IN "Ungrabbing" "keyboard" +.IN "XUngrabKeyboard" "" "@DEF@" +.sM +.FD 0 +XUngrabKeyboard\^(\^\fIdisplay\fP, \fItime\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Time \fItime\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fItime\fP 1i +Specifies the time. +You can pass either a timestamp or +.PN CurrentTime . +.LP +.eM +The +.PN XUngrabKeyboard +function +releases the keyboard and any queued events if this client has it actively grabbed from +either +.PN XGrabKeyboard +or +.PN XGrabKey . +.PN XUngrabKeyboard +does not release the keyboard and any queued events +if the specified time is earlier than +the last-keyboard-grab time or is later than the current X server time. +It also generates +.PN FocusIn +and +.PN FocusOut +events. +The X server automatically performs an +.PN UngrabKeyboard +request if the event window for an +active keyboard grab becomes not viewable. +.LP +.sp +To passively grab a single key of the keyboard, use +.PN XGrabKey . +.IN "Key" "grabbing" +.IN "Grabbing" "keys" +.IN "XGrabKey" "" "@DEF@" +.sM +.FD 0 +XGrabKey\^(\^\fIdisplay\fP, \fIkeycode\fP\^, \fImodifiers\fP\^, \fIgrab_window\fP\^, \fIowner_events\fP\^, \fIpointer_mode\fP\^, +.br + \fIkeyboard_mode\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + int \fIkeycode\fP\^; +.br + unsigned int \fImodifiers\fP\^; +.br + Window \fIgrab_window\fP\^; +.br + Bool \fIowner_events\fP\^; +.br + int \fIpointer_mode\fP\^, \fIkeyboard_mode\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIkeycode\fP 1i +Specifies the KeyCode or +.PN AnyKey . +.IP \fImodifiers\fP 1i +Specifies the set of keymasks or +.PN AnyModifier . +The mask is the bitwise inclusive OR of the valid keymask bits. +.IP \fIgrab_window\fP 1i +Specifies the grab window. +.IP \fIowner_events\fP 1i +Specifies a Boolean value that indicates whether the keyboard events +are to be reported as usual. +.IP \fIpointer_mode\fP 1i +Specifies further processing of pointer events. +You can pass +.PN GrabModeSync +or +.PN GrabModeAsync . +.IP \fIkeyboard_mode\fP 1i +Specifies further processing of keyboard events. +You can pass +.PN GrabModeSync +or +.PN GrabModeAsync . +.LP +.eM +The +.PN XGrabKey +function establishes a passive grab on the keyboard. +In the future, +the keyboard is actively grabbed (as for +.PN XGrabKeyboard ), +the last-keyboard-grab time is set to the time at which the key was pressed +(as transmitted in the +.PN KeyPress +event), and the +.PN KeyPress +event is reported if all of the following conditions are true: +.IP \(bu 5 +The keyboard is not grabbed and the specified key +(which can itself be a modifier key) is logically pressed +when the specified modifier keys are logically down, +and no other modifier keys are logically down. +.IP \(bu 5 +Either the grab_window is an ancestor of (or is) the focus window, +or the grab_window is a descendant of the focus window and contains the pointer. +.IP \(bu 5 +A passive grab on the same key combination does not exist +on any ancestor of grab_window. +.LP +The interpretation of the remaining arguments is as for +.PN XGrabKeyboard . +The active grab is terminated automatically when the logical state of the +keyboard has the specified key released +(independent of the logical state of the modifier keys). +.LP +Note that the logical state of a device (as seen by client applications) +may lag the physical state if device event processing is frozen. +.LP +A modifiers argument of +.PN AnyModifier +is equivalent to issuing the request for all +possible modifier combinations (including the combination of no +modifiers). +It is not required that all modifiers specified have +currently assigned KeyCodes. +A keycode argument of +.PN AnyKey +is equivalent to issuing +the request for all possible KeyCodes. +Otherwise, the specified keycode must be in +the range specified by min_keycode and max_keycode in the connection +setup, +or a +.PN BadValue +error results. +.LP +If some other client has issued a +.PN XGrabKey +with the same key combination on the same window, a +.PN BadAccess +error results. +When using +.PN AnyModifier +or +.PN AnyKey , +the request fails completely, +and a +.PN BadAccess +error results (no grabs are established) +if there is a conflicting grab for any combination. +.LP +.PN XGrabKey +can generate +.PN BadAccess , +.PN BadValue , +and +.PN BadWindow +errors. +.LP +.sp +To ungrab a key, use +.PN XUngrabKey . +.IN "Key" "ungrabbing" +.IN "Ungrabbing" "keys" +.IN "XUngrabKey" "" "@DEF@" +.sM +.FD 0 +XUngrabKey\^(\^\fIdisplay\fP, \fIkeycode\fP\^, \fImodifiers\fP\^, \fIgrab_window\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + int \fIkeycode\fP\^; +.br + unsigned int \fImodifiers\fP\^; +.br + Window \fIgrab_window\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIkeycode\fP 1i +Specifies the KeyCode or +.PN AnyKey . +.IP \fImodifiers\fP 1i +Specifies the set of keymasks or +.PN AnyModifier . +The mask is the bitwise inclusive OR of the valid keymask bits. +.IP \fIgrab_window\fP 1i +Specifies the grab window. +.LP +.eM +The +.PN XUngrabKey +function releases the key combination on the specified window if it was grabbed +by this client. +It has no effect on an active grab. +A modifiers of +.PN AnyModifier +is equivalent to issuing +the request for all possible modifier combinations +(including the combination of no modifiers). +A keycode argument of +.PN AnyKey +is equivalent to issuing the request for all possible key codes. +.LP +.PN XUngrabKey +can generate +.PN BadValue +and +.PN BadWindow +errors. +.NH 2 +Resuming Event Processing +.XS +\*(SN Resuming Event Processing +.XE +.LP +The previous sections discussed grab mechanisms with which processing +of events by the server can be temporarily suspended. This section +describes the mechanism for resuming event processing. +.LP +.sp +To allow further events to be processed when the device has been frozen, use +.PN XAllowEvents . +.IN "XAllowEvents" "" "@DEF@" +.sM +.FD 0 +XAllowEvents\^(\^\fIdisplay\fP, \fIevent_mode\fP\^, \fItime\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + int \fIevent_mode\fP\^; +.br + Time \fItime\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIevent_mode\fP 1i +Specifies the event mode. +You can pass +.PN AsyncPointer , +.PN SyncPointer , +.PN AsyncKeyboard , +.PN SyncKeyboard , +.PN ReplayPointer , +.PN ReplayKeyboard , +.PN AsyncBoth , +or +.PN SyncBoth . +.IP \fItime\fP 1i +Specifies the time. +You can pass either a timestamp or +.PN CurrentTime . +.LP +.eM +The +.PN XAllowEvents +function releases some queued events if the client has caused a device +to freeze. +It has no effect if the specified time is earlier than the last-grab +time of the most recent active grab for the client or if the specified time +is later than the current X server time. +Depending on the event_mode argument, the following occurs: +.TS +lw(1.25i) lw(4.5i). +T{ +.PN AsyncPointer +T} T{ +If the pointer is frozen by the client, +pointer event processing continues as usual. +If the pointer is frozen twice by the client on behalf of two separate grabs, +.PN AsyncPointer +thaws for both. +.PN AsyncPointer +has no effect if the pointer is not frozen by the client, +but the pointer need not be grabbed by the client. +T} +.sp 6p +T{ +.PN SyncPointer +T} T{ +If the pointer is frozen and actively grabbed by the client, +pointer event processing continues as usual until the next +.PN ButtonPress +or +.PN ButtonRelease +event is reported to the client. +At this time, +the pointer again appears to freeze. +However, if the reported event causes the pointer grab to be released, +the pointer does not freeze. +.PN SyncPointer +has no effect if the pointer is not frozen by the client +or if the pointer is not grabbed by the client. +T} +.sp 6p +T{ +.PN ReplayPointer +T} T{ +If the pointer is actively grabbed by the client and is frozen as the result of +an event having been sent to the client (either from the activation of an +.PN XGrabButton +or from a previous +.PN XAllowEvents +with mode +.PN SyncPointer +but not from an +.PN XGrabPointer ), +the pointer grab is released and that event is completely reprocessed. +This time, however, the function ignores any passive grabs at or above +(toward the root of) the grab_window of the grab just released. +The request has no effect if the pointer is not grabbed by the client +or if the pointer is not frozen as the result of an event. +T} +.sp 6p +T{ +.PN AsyncKeyboard +T} T{ +If the keyboard is frozen by the client, +keyboard event processing continues as usual. +If the keyboard is frozen twice by the client on behalf of two separate grabs, +.PN AsyncKeyboard +thaws for both. +.PN AsyncKeyboard +has no effect if the keyboard is not frozen by the client, +but the keyboard need not be grabbed by the client. +T} +.sp 6p +T{ +.PN SyncKeyboard +T} T{ +If the keyboard is frozen and actively grabbed by the client, +keyboard event processing continues as usual until the next +.PN KeyPress +or +.PN KeyRelease +event is reported to the client. +At this time, +the keyboard again appears to freeze. +However, if the reported event causes the keyboard grab to be released, +the keyboard does not freeze. +.PN SyncKeyboard +has no effect if the keyboard is not frozen by the client +or if the keyboard is not grabbed by the client. +T} +.sp 6p +T{ +.PN ReplayKeyboard +T} T{ +If the keyboard is actively grabbed by the client and is frozen +as the result of an event having been sent to the client (either from the +activation of an +.PN XGrabKey +or from a previous +.PN XAllowEvents +with mode +.PN SyncKeyboard +but not from an +.PN XGrabKeyboard ), +the keyboard grab is released and that event is completely reprocessed. +This time, however, the function ignores any passive grabs at or above +(toward the root of) +the grab_window of the grab just released. +The request has no effect if the keyboard is not grabbed by the client +or if the keyboard is not frozen as the result of an event. +T} +.sp 6p +T{ +.PN SyncBoth +T} T{ +If both pointer and keyboard are frozen by the client, +event processing for both devices continues as usual until the next +.PN ButtonPress , +.PN ButtonRelease , +.PN KeyPress , +or +.PN KeyRelease +event is reported to the client for a grabbed device +(button event for the pointer, key event for the keyboard), +at which time the devices again appear to freeze. +However, if the reported event causes the grab to be released, +then the devices do not freeze (but if the other device is still +grabbed, then a subsequent event for it will still cause both devices +to freeze). +.PN SyncBoth +has no effect unless both pointer and keyboard +are frozen by the client. +If the pointer or keyboard is frozen twice +by the client on behalf of two separate grabs, +.PN SyncBoth +thaws for both (but a subsequent freeze for +.PN SyncBoth +will only freeze each device once). +T} +.sp 6p +T{ +.PN AsyncBoth +T} T{ +If the pointer and the keyboard are frozen by the +client, event processing for both devices continues as usual. +If a device is frozen twice by the client on behalf of two separate grabs, +.PN AsyncBoth +thaws for both. +.PN AsyncBoth +has no effect unless both +pointer and keyboard are frozen by the client. +T} +.TE +.LP +.PN AsyncPointer , +.PN SyncPointer , +and +.PN ReplayPointer +have no effect on the +processing of keyboard events. +.PN AsyncKeyboard , +.PN SyncKeyboard , +and +.PN ReplayKeyboard +have no effect on the +processing of pointer events. +It is possible for both a pointer grab and a keyboard grab (by the same +or different clients) to be active simultaneously. +If a device is frozen on behalf of either grab, +no event processing is performed for the device. +It is possible for a single device to be frozen because of both grabs. +In this case, +the freeze must be released on behalf of both grabs before events can +again be processed. +If a device is frozen twice by a single client, +then a single +.PN AllowEvents +releases both. +.LP +.PN XAllowEvents +can generate a +.PN BadValue +error. +.NH 2 +Moving the Pointer +.XS +\*(SN Moving the Pointer +.XE +.LP +Although movement of the pointer normally should be left to the +control of the end user, sometimes it is necessary to move the +pointer to a new position under program control. +.LP +.sp +To move the pointer to an arbitrary point in a window, use +.PN XWarpPointer . +.IN "XWarpPointer" "" "@DEF@" +.sM +.FD 0 +XWarpPointer\^(\^\fIdisplay\fP, \fIsrc_w\fP\^, \fIdest_w\fP\^, \fIsrc_x\fP\^, \fIsrc_y\fP\^, \fIsrc_width\fP\^, \fIsrc_height\fP\^, \fIdest_x\fP\^, +.br + \fIdest_y\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIsrc_w\fP\^, \fIdest_w\fP\^; +.br + int \fIsrc_x\fP\^, \fIsrc_y\fP\^; +.br + unsigned int \fIsrc_width\fP\^, \fIsrc_height\fP\^; +.br + int \fIdest_x\fP\^, \fIdest_y\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIsrc_w\fP 1i +Specifies the source window or +.PN None . +.IP \fIdest_w\fP 1i +Specifies the destination window or +.PN None . +.IP \fIsrc_x\fP 1i +.br +.ns +.IP \fIsrc_y\fP 1i +.br +.ns +.IP \fIsrc_width\fP 1i +.br +.ns +.IP \fIsrc_height\fP 1i +Specify a rectangle in the source window. +.IP \fIdest_x\fP 1i +.br +.ns +.IP \fIdest_y\fP 1i +Specify the x and y coordinates within the destination window. +.LP +.eM +If dest_w is +.PN None , +.PN XWarpPointer +moves the pointer by the offsets (dest_x, dest_y) relative to the current +position of the pointer. +If dest_w is a window, +.PN XWarpPointer +moves the pointer to the offsets (dest_x, dest_y) relative to the origin of +dest_w. +However, if src_w is a window, +the move only takes place if the window src_w contains the pointer +and if the specified rectangle of src_w contains the pointer. +.LP +The src_x and src_y coordinates are relative to the origin of src_w. +If src_height is zero, +it is replaced with the current height of src_w minus src_y. +If src_width is zero, +it is replaced with the current width of src_w minus src_x. +.LP +There is seldom any reason for calling this function. +The pointer should normally be left to the user. +If you do use this function, however, it generates events just as if the user +had instantaneously moved the pointer from one position to another. +Note that you cannot use +.PN XWarpPointer +to move the pointer outside the confine_to window of an active pointer grab. +An attempt to do so will only move the pointer as far as the closest edge of the +confine_to window. +.LP +.PN XWarpPointer +can generate a +.PN BadWindow +error. +.NH 2 +Controlling Input Focus +.XS +\*(SN Controlling Input Focus +.XE +.LP +Xlib provides functions that you can use to set and get the input focus. +The input focus is a shared resource, and cooperation among clients is +required for correct interaction. See the +\fIInter-Client Communication Conventions Manual\fP +for input focus policy. +.LP +.sp +To set the input focus, use +.PN XSetInputFocus . +.IN "XSetInputFocus" "" "@DEF@" +.sM +.FD 0 +XSetInputFocus\^(\^\fIdisplay\fP, \fIfocus\fP\^, \fIrevert_to\fP\^, \fItime\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIfocus\fP\^; +.br + int \fIrevert_to\fP\^; +.br + Time \fItime\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIfocus\fP 1i +Specifies the window, +.PN PointerRoot , +or +.PN None . +.IP \fIrevert_to\fP 1i +Specifies where the input focus reverts to if the window becomes not +viewable. +You can pass +.PN RevertToParent , +.PN RevertToPointerRoot , +or +.PN RevertToNone . +.IP \fItime\fP 1i +Specifies the time. +You can pass either a timestamp or +.PN CurrentTime . +.LP +.eM +The +.PN XSetInputFocus +function changes the input focus and the last-focus-change time. +It has no effect if the specified time is earlier than the current +last-focus-change time or is later than the current X server time. +Otherwise, the last-focus-change time is set to the specified time +.Pn ( CurrentTime +is replaced by the current X server time). +.PN XSetInputFocus +causes the X server to generate +.PN FocusIn +and +.PN FocusOut +events. +.LP +Depending on the focus argument, +the following occurs: +.IP \(bu 5 +If focus is +.PN None , +all keyboard events are discarded until a new focus window is set, +and the revert_to argument is ignored. +.IP \(bu 5 +If focus is a window, +it becomes the keyboard's focus window. +If a generated keyboard event would normally be reported to this window +or one of its inferiors, the event is reported as usual. +Otherwise, the event is reported relative to the focus window. +.IP \(bu 5 +If focus is +.PN PointerRoot , +the focus window is dynamically taken to be the root window of whatever screen +the pointer is on at each keyboard event. +In this case, the revert_to argument is ignored. +.LP +The specified focus window must be viewable at the time +.PN XSetInputFocus +is called, +or a +.PN BadMatch +error results. +If the focus window later becomes not viewable, +the X server +evaluates the revert_to argument to determine the new focus window as follows: +.IP \(bu 5 +If revert_to is +.PN RevertToParent , +the focus reverts to the parent (or the closest viewable ancestor), +and the new revert_to value is taken to be +.PN RevertToNone . +.IP \(bu 5 +If revert_to is +.PN RevertToPointerRoot +or +.PN RevertToNone , +the focus reverts to +.PN PointerRoot +or +.PN None , +respectively. +When the focus reverts, +the X server generates +.PN FocusIn +and +.PN FocusOut +events, but the last-focus-change time is not affected. +.LP +.PN XSetInputFocus +can generate +.PN BadMatch , +.PN BadValue , +and +.PN BadWindow +errors. +.LP +.sp +To obtain the current input focus, use +.PN XGetInputFocus . +.IN "XGetInputFocus" "" "@DEF@" +.sM +.FD 0 +XGetInputFocus\^(\^\fIdisplay\fP, \fIfocus_return\fP\^, \fIrevert_to_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window *\fIfocus_return\fP\^; +.br + int *\fIrevert_to_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIfocus_return\fP 1i +Returns the focus window, +.PN PointerRoot , +or +.PN None . +.IP \fIrevert_to_return\fP 1i +Returns the current focus state +.Pn ( RevertToParent , +.PN RevertToPointerRoot , +or +.PN RevertToNone ). +.LP +.eM +The +.PN XGetInputFocus +function returns the focus window and the current focus state. +.NH 2 +Manipulating the Keyboard and Pointer Settings +.XS +\*(SN Manipulating the Keyboard and Pointer Settings +.XE +.LP +Xlib provides functions that you can use to +change the keyboard control, obtain a list of the auto-repeat keys, +turn keyboard auto-repeat on or off, ring the bell, +set or obtain the pointer button or keyboard mapping, +and obtain a bit vector for the keyboard. +.LP +.IN "Keyboard" "bell volume" +.IN "Keyboard" "keyclick volume" +.IN "Keyboard" "bit vector" +.IN "Mouse" "programming" +This section discusses +the user-preference options of bell, key click, +pointer behavior, and so on. +The default values for many of these options are server dependent. +Not all implementations will actually be able to control all of these +parameters. +.LP +The +.PN XChangeKeyboardControl +function changes control of a keyboard and operates on a +.PN XKeyboardControl +structure: +.sM +.LP +/* Mask bits for ChangeKeyboardControl */ +.TS +lw(.5i) lw(2.5i) lw(.8i). +T{ +#define +T} T{ +.PN KBKeyClickPercent +T} T{ +(1L<<0) +T} +T{ +#define +T} T{ +.PN KBBellPercent +T} T{ +(1L<<1) +T} +T{ +#define +T} T{ +.PN KBBellPitch +T} T{ +(1L<<2) +T} +T{ +#define +T} T{ +.PN KBBellDuration +T} T{ +(1L<<3) +T} +T{ +#define +T} T{ +.PN KBLed +T} T{ +(1L<<4) +T} +T{ +#define +T} T{ +.PN KBLedMode +T} T{ +(1L<<5) +T} +T{ +#define +T} T{ +.PN KBKey +T} T{ +(1L<<6) +T} +T{ +#define +T} T{ +.PN KBAutoRepeatMode +T} T{ +(1L<<7) +T} +.TE +.IN "XKeyboardControl" "" "@DEF@" +.Ds 0 +.TA .5i 2.5i +.ta .5i 2.5i +/* Values */ + +typedef struct { + int key_click_percent; + int bell_percent; + int bell_pitch; + int bell_duration; + int led; + int led_mode; /* LedModeOn, LedModeOff */ + int key; + int auto_repeat_mode; /* AutoRepeatModeOff, AutoRepeatModeOn, + AutoRepeatModeDefault */ +} XKeyboardControl; +.De +.LP +.eM +The key_click_percent member sets the volume for key clicks between 0 (off) +and 100 (loud) inclusive, if possible. +A setting of \-1 restores the default. +Other negative values generate a +.PN BadValue +error. +.LP +The bell_percent sets the base volume for the bell between 0 (off) and 100 +(loud) inclusive, if possible. +A setting of \-1 restores the default. +Other negative values generate a +.PN BadValue +error. +The bell_pitch member sets the pitch (specified in Hz) of the bell, if possible. +A setting of \-1 restores the default. +Other negative values generate a +.PN BadValue +error. +The bell_duration member sets the duration of the +bell specified in milliseconds, if possible. +A setting of \-1 restores the default. +Other negative values generate a +.PN BadValue +error. +.LP +If both the led_mode and led members are specified, +the state of that LED is changed, if possible. +The led_mode member can be set to +.PN LedModeOn +or +.PN LedModeOff . +If only led_mode is specified, the state of +all LEDs are changed, if possible. +At most 32 LEDs numbered from one are supported. +No standard interpretation of LEDs is defined. +If led is specified without led_mode, a +.PN BadMatch +error results. +.LP +If both the auto_repeat_mode and key members are specified, +the auto_repeat_mode of that key is changed (according to +.PN AutoRepeatModeOn , +.PN AutoRepeatModeOff , +or +.PN AutoRepeatModeDefault ), +if possible. +If only auto_repeat_mode is +specified, the global auto_repeat_mode for the entire keyboard is +changed, if possible, and does not affect the per-key settings. +If a key is specified without an auto_repeat_mode, a +.PN BadMatch +error results. +Each key has an individual mode of whether or not it should auto-repeat +and a default setting for the mode. +In addition, +there is a global mode of whether auto-repeat should be enabled or not +and a default setting for that mode. +When global mode is +.PN AutoRepeatModeOn , +keys should obey their individual auto-repeat modes. +When global mode is +.PN AutoRepeatModeOff , +no keys should auto-repeat. +An auto-repeating key generates alternating +.PN KeyPress +and +.PN KeyRelease +events. +When a key is used as a modifier, +it is desirable for the key not to auto-repeat, +regardless of its auto-repeat setting. +.LP +A bell generator connected with the console but not directly on a +keyboard is treated as if it were part of the keyboard. +The order in which controls are verified and altered is server-dependent. +If an error is generated, a subset of the controls may have been altered. +.LP +.sp +.IN "XChangeKeyboardControl" "" "@DEF@" +.sM +.FD 0 +XChangeKeyboardControl\^(\^\fIdisplay\fP, \fIvalue_mask\fP\^, \fIvalues\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + unsigned long \fIvalue_mask\fP\^; +.br + XKeyboardControl *\fIvalues\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIvalue_mask\fP 1i +Specifies which controls to change. +This mask is the bitwise inclusive OR of the valid control mask bits. +.IP \fIvalues\fP 1i +Specifies one value for each bit set to 1 in the mask. +.LP +.eM +The +.PN XChangeKeyboardControl +function controls the keyboard characteristics defined by the +.PN XKeyboardControl +structure. +The value_mask argument specifies which values are to be changed. +.LP +.PN XChangeKeyboardControl +can generate +.PN BadMatch +and +.PN BadValue +errors. +.LP +.sp +To obtain the current control values for the keyboard, use +.PN XGetKeyboardControl . +.IN "XGetKeyboardControl" "" "@DEF@" +.sM +.FD 0 +XGetKeyboardControl\^(\^\fIdisplay\fP, \fIvalues_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + XKeyboardState *\fIvalues_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIvalues_return\fP 1i +Returns the current keyboard controls in the specified +.PN XKeyboardState +structure. +.LP +.eM +The +.PN XGetKeyboardControl +function returns the current control values for the keyboard to the +.PN XKeyboardState +structure. +.LP +.IN "XGetKeyboardControl" +.IN "XKeyboardState" "" "@DEF@" +.sM +.Ds 0 +.TA .5i +.ta .5i +typedef struct { + int key_click_percent; + int bell_percent; + unsigned int bell_pitch, bell_duration; + unsigned long led_mask; + int global_auto_repeat; + char auto_repeats[32]; +} XKeyboardState; +.De +.LP +.eM +For the LEDs, +the least significant bit of led_mask corresponds to LED one, +and each bit set to 1 in led_mask indicates an LED that is lit. +The global_auto_repeat member can be set to +.PN AutoRepeatModeOn +or +.PN AutoRepeatModeOff . +The auto_repeats member is a bit vector. +Each bit set to 1 indicates that auto-repeat is enabled +for the corresponding key. +The vector is represented as 32 bytes. +Byte N (from 0) contains the bits for keys 8N to 8N + 7 +with the least significant bit in the byte representing key 8N. +.LP +.sp +To turn on keyboard auto-repeat, use +.PN XAutoRepeatOn . +.IN "XAutoRepeatOn" "" "@DEF@" +.sM +.FD 0 +XAutoRepeatOn\^(\^\fIdisplay\fP\^) +.br + Display *\fIdisplay\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.LP +.eM +The +.PN XAutoRepeatOn +function turns on auto-repeat for the keyboard on the specified display. +.LP +.sp +To turn off keyboard auto-repeat, use +.PN XAutoRepeatOff . +.IN "XAutoRepeatOff" "" "@DEF@" +.sM +.FD 0 +XAutoRepeatOff\^(\^\fIdisplay\fP\^) +.br + Display *\fIdisplay\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.LP +.eM +The +.PN XAutoRepeatOff +function turns off auto-repeat for the keyboard on the specified display. +.LP +.sp +To ring the bell, use +.PN XBell . +.IN "XBell" "" "@DEF@" +.sM +.FD 0 +XBell\^(\^\fIdisplay\fP, \fIpercent\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + int \fIpercent\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIpercent\fP 1i +Specifies the volume for the bell, +which can range from \-100 to 100 inclusive. +.LP +.eM +The +.PN XBell +function rings the bell on the keyboard on the specified display, if possible. +The specified volume is relative to the base volume for the keyboard. +If the value for the percent argument is not in the range \-100 to 100 +inclusive, a +.PN BadValue +error results. +The volume at which the bell rings +when the percent argument is nonnegative is: +.IP +base \- [(base * percent) / 100] + percent +.LP +The volume at which the bell rings +when the percent argument is negative is: +.IP +base + [(base * percent) / 100] +.LP +To change the base volume of the bell, use +.PN XChangeKeyboardControl . +.LP +.PN XBell +can generate a +.PN BadValue +error. +.LP +.sp +To obtain a bit vector that describes the state of the keyboard, use +.PN XQueryKeymap . +.IN "XQueryKeymap" "" "@DEF@" +.sM +.FD 0 +XQueryKeymap\^(\^\fIdisplay\fP, \fIkeys_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + char \fIkeys_return\fP[32]\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIkeys_return\fP 1i +Returns an array of bytes that identifies which keys are pressed down. +Each bit represents one key of the keyboard. +.LP +.eM +The +.PN XQueryKeymap +function returns a bit vector for the logical state of the keyboard, +where each bit set to 1 indicates that the corresponding key is currently +pressed down. +The vector is represented as 32 bytes. +Byte N (from 0) contains the bits for keys 8N to 8N + 7 +with the least significant bit in the byte representing key 8N. +.LP +Note that the logical state of a device (as seen by client applications) +may lag the physical state if device event processing is frozen. +.LP +.sp +To set the mapping of the pointer buttons, use +.PN XSetPointerMapping . +.IN "XSetPointerMapping" "" "@DEF@" +.sM +.FD 0 +int XSetPointerMapping\^(\^\fIdisplay\fP, \fImap\fP, \fInmap\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + unsigned char \fImap\fP\^[]\^; +.br + int \fInmap\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fImap\fP 1i +Specifies the mapping list. +.IP \fInmap\fP 1i +Specifies the number of items in the mapping list. +.LP +.eM +The +.PN XSetPointerMapping +function sets the mapping of the pointer. +If it succeeds, the X server generates a +.PN MappingNotify +event, and +.PN XSetPointerMapping +returns +.PN MappingSuccess . +Element map[i] defines the logical button number for the physical button +i+1. +The length of the list must be the same as +.PN XGetPointerMapping +would return, +or a +.PN BadValue +error results. +A zero element disables a button, and elements are not restricted in +value by the number of physical buttons. +However, no two elements can have the same nonzero value, +or a +.PN BadValue +error results. +If any of the buttons to be altered are logically in the down state, +.PN XSetPointerMapping +returns +.PN MappingBusy , +and the mapping is not changed. +.LP +.PN XSetPointerMapping +can generate a +.PN BadValue +error. +.LP +.sp +To get the pointer mapping, use +.PN XGetPointerMapping . +.IN "XGetPointerMapping" "" "@DEF@" +.sM +.FD 0 +int XGetPointerMapping\^(\^\fIdisplay\fP, \fImap_return\fP, \fInmap\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + unsigned char \fImap_return\fP\^[]\^; +.br + int \fInmap\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fImap_return\fP 1i +Returns the mapping list. +.IP \fInmap\fP 1i +Specifies the number of items in the mapping list. +.LP +.eM +The +.PN XGetPointerMapping +function returns the current mapping of the pointer. +Pointer buttons are numbered starting from one. +.PN XGetPointerMapping +returns the number of physical buttons actually on the pointer. +The nominal mapping for a pointer is map[i]=i+1. +The nmap argument specifies the length of the array where the pointer +mapping is returned, and only the first nmap elements are returned +in map_return. +.LP +.sp +To control the pointer's interactive feel, use +.PN XChangePointerControl . +.IN "XChangePointerControl" "" "@DEF@" +.sM +.FD 0 +XChangePointerControl\^(\^\fIdisplay\fP, \fIdo_accel\fP\^, \fIdo_threshold\fP\^, \fIaccel_numerator\fP\^, +.br + \fIaccel_denominator\fP\^, \fIthreshold\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Bool \fIdo_accel\fP\^, \fIdo_threshold\fP\^; +.br + int \fIaccel_numerator\fP\^, \fIaccel_denominator\fP\^; +.br + int \fIthreshold\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIdo_accel\fP 1i +Specifies a Boolean value that controls whether the values for +the accel_numerator or accel_denominator are used. +.IP \fIdo_threshold\fP 1i +Specifies a Boolean value that controls whether the value for the +threshold is used. +.IP \fIaccel_numerator\fP 1i +Specifies the numerator for the acceleration multiplier. +.IP \fIaccel_denominator\fP 1i +Specifies the denominator for the acceleration multiplier. +.IP \fIthreshold\fP 1i +Specifies the acceleration threshold. +.LP +.eM +The +.PN XChangePointerControl +function defines how the pointing device moves. +The acceleration, expressed as a fraction, is a +multiplier for movement. +For example, +specifying 3/1 means the pointer moves three times as fast as normal. +The fraction may be rounded arbitrarily by the X server. +Acceleration +only takes effect if the pointer moves more than threshold pixels at +once and only applies to the amount beyond the value in the threshold argument. +Setting a value to \-1 restores the default. +The values of the do_accel and do_threshold arguments must be +.PN True +for the pointer values to be set, +or the parameters are unchanged. +Negative values (other than \-1) generate a +.PN BadValue +error, as does a zero value +for the accel_denominator argument. +.LP +.PN XChangePointerControl +can generate a +.PN BadValue +error. +.LP +.sp +To get the current pointer parameters, use +.PN XGetPointerControl . +.IN "XGetPointerControl" "" "@DEF@" +.sM +.FD 0 +XGetPointerControl\^(\^\fIdisplay\fP, \fIaccel_numerator_return\fP\^, \fIaccel_denominator_return\fP\^, +.br + \fIthreshold_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + int *\fIaccel_numerator_return\fP\^, *\fIaccel_denominator_return\fP\^; +.br + int *\fIthreshold_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIaccel_numerator_return\fP 1i +Returns the numerator for the acceleration multiplier. +.IP \fIaccel_denominator_return\fP 1i +Returns the denominator for the acceleration multiplier. +.IP \fIthreshold_return\fP 1i +Returns the acceleration threshold. +.LP +.eM +The +.PN XGetPointerControl +function returns the pointer's current acceleration multiplier +and acceleration threshold. +.NH 2 +Manipulating the Keyboard Encoding +.XS +\*(SN Manipulating the Keyboard Encoding +.XE +.LP +A KeyCode represents a physical (or logical) key. +KeyCodes lie in the inclusive range [8,255]. +A KeyCode value carries no intrinsic information, +although server implementors may attempt to encode geometry +(for example, matrix) information in some fashion so that it can +be interpreted in a server-dependent fashion. +The mapping between keys and KeyCodes cannot be changed. +.LP +A KeySym is an encoding of a symbol on the cap of a key. +The set of defined KeySyms includes the ISO Latin character sets (1\-4), +Katakana, Arabic, Cyrillic, Greek, Technical, +Special, Publishing, APL, Hebrew, Thai, Korean +and a miscellany of keys found +on keyboards (Return, Help, Tab, and so on). +To the extent possible, these sets are derived from international +standards. +In areas where no standards exist, +some of these sets are derived from Digital Equipment Corporation standards. +The list of defined symbols can be found in +.hN X11/keysymdef.h . +Unfortunately, some C preprocessors have +limits on the number of defined symbols. +If you must use KeySyms not +in the Latin 1\-4, Greek, and miscellaneous classes, +you may have to define a symbol for those sets. +Most applications usually only include +.hN X11/keysym.h , +which defines symbols for ISO Latin 1\-4, Greek, and miscellaneous. +.LP +A list of KeySyms is associated with each KeyCode. +The list is intended to convey the set of symbols on the corresponding key. +If the list (ignoring trailing +.PN NoSymbol +entries) is +a single KeySym ``\fIK\fP'', +then the list is treated as if it were the list +``\fIK\fP NoSymbol \fIK\fP NoSymbol''. +If the list (ignoring trailing +.PN NoSymbol +entries) is a pair of KeySyms ``\fIK1 K2\fP'', +then the list is treated as if it were the list ``\fIK1 K2 K1 K2\fP''. +If the list (ignoring trailing +.PN NoSymbol +entries) is a triple of KeySyms ``\fIK1 K2 K3\fP'', +then the list is treated as if it were the list ``\fIK1 K2 K3\fP NoSymbol''. +When an explicit ``void'' element is desired in the list, +the value +.PN VoidSymbol +can be used. +.LP +The first four elements of the list are split into two groups of KeySyms. +Group 1 contains the first and second KeySyms; +Group 2 contains the third and fourth KeySyms. +Within each group, +if the second element of the group is +.PN NoSymbol , +then the group should be treated as if the second element were +the same as the first element, +except when the first element is an alphabetic KeySym ``\fIK\fP'' +for which both lowercase and uppercase forms are defined. +In that case, +the group should be treated as if the first element were +the lowercase form of ``\fIK\fP'' and the second element were +the uppercase form of ``\fIK\fP''. +.LP +The standard rules for obtaining a KeySym from a +.PN KeyPress +event make use of only the Group 1 and Group 2 KeySyms; +no interpretation of other KeySyms in the list is given. +Which group to use is determined by the modifier state. +Switching between groups is controlled by the KeySym named MODE SWITCH, +by attaching that KeySym to some KeyCode and attaching +that KeyCode to any one of the modifiers +.PN Mod1 +through +.PN Mod5 . +This modifier is called the \fIgroup modifier\fP\^. +For any KeyCode, +Group 1 is used when the group modifier is off, +and Group 2 is used when the group modifier is on. +.LP +The +.PN Lock +modifier is interpreted as CapsLock when the KeySym named XK_Caps_Lock +is attached to some KeyCode and that KeyCode is attached to the +.PN Lock +modifier. The +.PN Lock +modifier is interpreted as ShiftLock when the KeySym named XK_Shift_Lock +is attached to some KeyCode and that KeyCode is attached to the +.PN Lock +modifier. If the +.PN Lock +modifier could be interpreted as both +CapsLock and ShiftLock, the CapsLock interpretation is used. +.LP +The operation of keypad keys is controlled by the KeySym named XK_Num_Lock, +by attaching that KeySym to some KeyCode and attaching that KeyCode to any +one of the modifiers +.PN Mod1 +through +.PN Mod5 . +This modifier is called the +\fInumlock modifier\fP\^. The standard KeySyms with the prefix ``XK_KP_'' +in their +name are called keypad KeySyms; these are KeySyms with numeric value in +the hexadecimal range 0xFF80 to 0xFFBD inclusive. In addition, +vendor-specific KeySyms in the hexadecimal range 0x11000000 to 0x1100FFFF +are also keypad KeySyms. +.LP +Within a group, the choice of KeySym is determined by applying the first +rule that is satisfied from the following list: +.IP \(bu 5 +The numlock modifier is on and the second KeySym is a keypad KeySym. In +this case, if the +.PN Shift +modifier is on, or if the +.PN Lock +modifier is on and +is interpreted as ShiftLock, then the first KeySym is used, otherwise the +second KeySym is used. +.IP \(bu 5 +The +.PN Shift +and +.PN Lock +modifiers are both off. In this case, the first +KeySym is used. +.IP \(bu 5 +The +.PN Shift +modifier is off, and the +.PN Lock +modifier is on and is +interpreted as CapsLock. In this case, the first KeySym is used, but if +that KeySym is lowercase alphabetic, then the corresponding uppercase +KeySym is used instead. +.IP \(bu 5 +The +.PN Shift +modifier is on, and the +.PN Lock +modifier is on and is interpreted +as CapsLock. In this case, the second KeySym is used, but if that KeySym +is lowercase alphabetic, then the corresponding uppercase KeySym is used +instead. +.IP \(bu 5 +The +.PN Shift +modifier is on, or the +.PN Lock +modifier is on and is interpreted +as ShiftLock, or both. In this case, the second KeySym is used. +.LP +No spatial geometry of the symbols on the key is defined by +their order in the KeySym list, +although a geometry might be defined on a +server-specific basis. +The X server does not use the mapping between KeyCodes and KeySyms. +Rather, it merely stores it for reading and writing by clients. +.sp +.LP +To obtain the legal KeyCodes for a display, use +.PN XDisplayKeycodes . +.IN "XDisplayKeycodes" "" "@DEF@" +.sM +.FD 0 +XDisplayKeycodes\^(\^\fIdisplay\fP\^, \fImin_keycodes_return\fP\^, \ +\fImax_keycodes_return\fP\^) +.br + Display *\^\fIdisplay\fP\^; +.br + int *\^\fImin_keycodes_return\fP\^, *\^\fImax_keycodes_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fImin_keycodes_return\fP 1i +Returns the minimum number of KeyCodes. +.IP \fImax_keycodes_return\fP 1i +Returns the maximum number of KeyCodes. +.LP +.eM +The +.PN XDisplayKeycodes +function returns the min-keycodes and max-keycodes supported by the +specified display. +The minimum number of KeyCodes returned is never less than 8, +and the maximum number of KeyCodes returned is never greater than 255. +Not all KeyCodes in this range are required to have corresponding keys. +.sp +.LP +To obtain the symbols for the specified KeyCodes, use +.PN XGetKeyboardMapping . +.IN "XGetKeyboardMapping" "" "@DEF@" +.sM +.FD 0 +KeySym *XGetKeyboardMapping(\^\fIdisplay\fP, \fIfirst_keycode\fP, \fIkeycode_count\fP, +.br + \fIkeysyms_per_keycode_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + KeyCode \fIfirst_keycode\fP\^; +.br + int \fIkeycode_count\fP\^; +.br + int *\fIkeysyms_per_keycode_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.ds Kc returned +.IP \fIfirst_keycode\fP 1i +Specifies the first KeyCode that is to be \*(Kc. +.IP \fIkeycode_count\fP 1i +Specifies the number of KeyCodes that are to be returned. +.IP \fIkeysyms_per_keycode_return\fP 1i +Returns the number of KeySyms per KeyCode. +.LP +.eM +The +.PN XGetKeyboardMapping +function returns the symbols for the specified number of KeyCodes +starting with first_keycode. +The value specified in first_keycode must be greater than +or equal to min_keycode as returned by +.PN XDisplayKeycodes , +or a +.PN BadValue +error results. +In addition, the following expression must be less than or equal +to max_keycode as returned by +.PN XDisplayKeycodes : +.LP +.Ds +first_keycode + keycode_count \- 1 +.De +.LP +If this is not the case, a +.PN BadValue +error results. +The number of elements in the KeySyms list is: +.LP +.Ds +keycode_count * keysyms_per_keycode_return +.De +.LP +KeySym number N, counting from zero, for KeyCode K has the following index +in the list, counting from zero: +.Ds +(K \- first_code) * keysyms_per_code_return + N +.De +.LP +The X server arbitrarily chooses the keysyms_per_keycode_return value +to be large enough to report all requested symbols. +A special KeySym value of +.PN NoSymbol +is used to fill in unused elements for +individual KeyCodes. +To free the storage returned by +.PN XGetKeyboardMapping , +use +.PN XFree . +.LP +.PN XGetKeyboardMapping +can generate a +.PN BadValue +error. +.LP +.sp +To change the keyboard mapping, use +.PN XChangeKeyboardMapping . +.IN "XChangeKeyboardMapping" "" "@DEF@" +.sM +.FD 0 +XChangeKeyboardMapping(\^\fIdisplay\fP, \fIfirst_keycode\fP, \fIkeysyms_per_keycode\fP, \fIkeysyms\fP, \fInum_codes\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + int \fIfirst_keycode\fP\^; +.br + int \fIkeysyms_per_keycode\fP\^; +.br + KeySym *\fIkeysyms\fP\^; +.br + int \fInum_codes\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.ds Kc changed +.IP \fIfirst_keycode\fP 1i +Specifies the first KeyCode that is to be \*(Kc. +.IP \fIkeysyms_per_keycode\fP 1i +Specifies the number of KeySyms per KeyCode. +.IP \fIkeysyms\fP 1i +Specifies an array of KeySyms. +.IP \fInum_codes\fP 1i +Specifies the number of KeyCodes that are to be changed. +.LP +.eM +The +.PN XChangeKeyboardMapping +function defines the symbols for the specified number of KeyCodes +starting with first_keycode. +The symbols for KeyCodes outside this range remain unchanged. +The number of elements in keysyms must be: +.LP +.Ds +num_codes * keysyms_per_keycode +.De +.LP +The specified first_keycode must be greater than or equal to min_keycode +returned by +.PN XDisplayKeycodes , +or a +.PN BadValue +error results. +In addition, the following expression must be less than or equal to +max_keycode as returned by +.PN XDisplayKeycodes , +or a +.PN BadValue +error results: +.LP +.Ds +first_keycode + num_codes \- 1 +.De +.LP +KeySym number N, counting from zero, for KeyCode K has the following index +in keysyms, counting from zero: +.LP +.Ds +(K \- first_keycode) * keysyms_per_keycode + N +.De +.LP +The specified keysyms_per_keycode can be chosen arbitrarily by the client +to be large enough to hold all desired symbols. +A special KeySym value of +.PN NoSymbol +should be used to fill in unused elements +for individual KeyCodes. +It is legal for +.PN NoSymbol +to appear in nontrailing positions +of the effective list for a KeyCode. +.PN XChangeKeyboardMapping +generates a +.PN MappingNotify +event. +.LP +There is no requirement that the X server interpret this mapping. +It is merely stored for reading and writing by clients. +.LP +.PN XChangeKeyboardMapping +can generate +.PN BadAlloc +and +.PN BadValue +errors. +.LP +The next six functions make use of the +.PN XModifierKeymap +data structure, which contains: +.LP +.IN "XModifierKeymap" "" "@DEF@" +.sM +.Ds 0 +.TA .5i 2.5i +.ta .5i 2.5i +typedef struct { + int max_keypermod; /* This server's max number of keys per modifier */ + KeyCode *modifiermap; /* An 8 by max_keypermod array of the modifiers */ +} XModifierKeymap; +.De +.LP +.eM +To create an +.PN XModifierKeymap +structure, use +.PN XNewModifiermap . +.IN "XNewModifiermap" "" "@DEF@" +.sM +.FD 0 +XModifierKeymap *XNewModifiermap(\^\fImax_keys_per_mod\fP\^) +.br + int \fImax_keys_per_mod\fP\^; +.FN +.IP \fImax_keys_per_mod\fP 1i +Specifies the number of KeyCode entries preallocated to the modifiers +in the map. +.LP +.eM +The +.PN XNewModifiermap +function returns a pointer to +.PN XModifierKeymap +structure for later use. +.LP +.sp +To add a new entry to an +.PN XModifierKeymap +structure, use +.PN XInsertModifiermapEntry . +.IN "XInsertModifiermapEntry" "" "@DEF@" +.sM +.FD 0 +XModifierKeymap *XInsertModifiermapEntry\^(\^\fImodmap\fP, \ +\fIkeycode_entry\fP, \fImodifier\fP\^) +.br + XModifierKeymap *\fImodmap\fP\^; +.br + KeyCode \fIkeycode_entry\fP\^; +.br + int \fImodifier\fP\^; +.FN +.IP \fImodmap\fP 1i +Specifies the +.PN XModifierKeymap +structure. +.IP \fIkeycode_entry\fP 1i +Specifies the KeyCode. +.IP \fImodifier\fP 1i +Specifies the modifier. +.LP +.eM +The +.PN XInsertModifiermapEntry +function adds the specified KeyCode to the set that controls the specified +modifier and returns the resulting +.PN XModifierKeymap +structure (expanded as needed). +.LP +.sp +To delete an entry from an +.PN XModifierKeymap +structure, use +.PN XDeleteModifiermapEntry . +.IN "XDeleteModifiermapEntry" "" "@DEF@" +.sM +.FD 0 +XModifierKeymap *XDeleteModifiermapEntry\^(\^\fImodmap\fP, \ +\fIkeycode_entry\fP, \fImodifier\fP\^) +.br + XModifierKeymap *\fImodmap\fP\^; +.br + KeyCode \fIkeycode_entry\fP\^; +.br + int \fImodifier\fP\^; +.FN +.IP \fImodmap\fP 1i +Specifies the +.PN XModifierKeymap +structure. +.IP \fIkeycode_entry\fP 1i +Specifies the KeyCode. +.IP \fImodifier\fP 1i +Specifies the modifier. +.LP +.eM +The +.PN XDeleteModifiermapEntry +function deletes the specified KeyCode from the set that controls the +specified modifier and returns a pointer to the resulting +.PN XModifierKeymap +structure. +.LP +.sp +To destroy an +.PN XModifierKeymap +structure, use +.PN XFreeModifiermap . +.IN "XFreeModifiermap" "" "@DEF@" +.sM +.FD 0 +XFreeModifiermap(\^\fImodmap\fP\^) +.br + XModifierKeymap *\fImodmap\fP; +.FN +.IP \fImodmap\fP 1i +Specifies the +.PN XModifierKeymap +structure. +.LP +.eM +The +.PN XFreeModifiermap +function frees the specified +.PN XModifierKeymap +structure. +.LP +.sp +To set the KeyCodes to be used as modifiers, use +.PN XSetModifierMapping . +.IN "XSetModifierMapping" "" "@DEF@" +.sM +.FD 0 +int XSetModifierMapping(\^\fIdisplay\fP, \fImodmap\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + XModifierKeymap *\fImodmap\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fImodmap\fP 1i +Specifies the +.PN XModifierKeymap +structure. +.LP +.eM +The +.PN XSetModifierMapping +function specifies the KeyCodes of the keys (if any) that are to be used +as modifiers. +If it succeeds, +the X server generates a +.PN MappingNotify +event, and +.PN XSetModifierMapping +returns +.PN MappingSuccess . +X permits at most 8 modifier keys. +If more than 8 are specified in the +.PN XModifierKeymap +structure, a +.PN BadLength +error results. +.LP +The modifiermap member of the +.PN XModifierKeymap +structure contains 8 sets of max_keypermod KeyCodes, +one for each modifier in the order +.PN Shift , +.PN Lock , +.PN Control , +.PN Mod1 , +.PN Mod2 , +.PN Mod3 , +.PN Mod4 , +and +.PN Mod5 . +Only nonzero KeyCodes have meaning in each set, +and zero KeyCodes are ignored. +In addition, all of the nonzero KeyCodes must be in the range specified by +min_keycode and max_keycode in the +.PN Display +structure, +or a +.PN BadValue +error results. +.LP +An X server can impose restrictions on how modifiers can be changed, +for example, +if certain keys do not generate up transitions in hardware, +if auto-repeat cannot be disabled on certain keys, +or if multiple modifier keys are not supported. +If some such restriction is violated, +the status reply is +.PN MappingFailed , +and none of the modifiers are changed. +If the new KeyCodes specified for a modifier differ from those +currently defined and any (current or new) keys for that modifier are +in the logically down state, +.PN XSetModifierMapping +returns +.PN MappingBusy , +and none of the modifiers is changed. +.LP +.PN XSetModifierMapping +can generate +.PN BadAlloc +and +.PN BadValue +errors. +.LP +.sp +To obtain the KeyCodes used as modifiers, use +.PN XGetModifierMapping . +.IN "XGetModifierMapping" "" "@DEF@" +.sM +.FD 0 +XModifierKeymap *XGetModifierMapping(\^\fIdisplay\fP\^) +.br + Display *\fIdisplay\fP\^; + +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.LP +.eM +The +.PN XGetModifierMapping +function returns a pointer to a newly created +.PN XModifierKeymap +structure that contains the keys being used as modifiers. +The structure should be freed after use by calling +.PN XFreeModifiermap . +If only zero values appear in the set for any modifier, +that modifier is disabled. +.bp diff --git a/libX11/specs/libX11/CH13 b/libX11/specs/libX11/CH13 new file mode 100644 index 000000000..ed143c690 --- /dev/null +++ b/libX11/specs/libX11/CH13 @@ -0,0 +1,7673 @@ +.\" Copyright \(co 1985, 1986, 1987, 1988, 1989, 1990, 1991, 1994, 1996 X Consortium +.\" +.\" 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 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 X CONSORTIUM 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 X Consortium 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 X Consortium. +.\" +.\" Copyright \(co 1985, 1986, 1987, 1988, 1989, 1990, 1991 by +.\" Digital Equipment Corporation +.\" +.\" Portions Copyright \(co 1990, 1991 by +.\" Tektronix, Inc. +.\" +.\" Permission to use, copy, modify and distribute this documentation for +.\" any purpose and without fee is hereby granted, provided that the above +.\" copyright notice appears in all copies and that both that copyright notice +.\" and this permission notice appear in all copies, and that the names of +.\" Digital and Tektronix not be used in in advertising or publicity pertaining +.\" to this documentation without specific, written prior permission. +.\" Digital and Tektronix makes no representations about the suitability +.\" of this documentation for any purpose. +.\" It is provided ``as is'' without express or implied warranty. +.\" +\& +.sp 1 +.ce 3 +\s+1\fBChapter 13\fP\s-1 + +\s+1\fBLocales and Internationalized Text Functions\fP\s-1 +.sp 2 +.nr H1 13 +.nr H2 0 +.nr H3 0 +.nr H4 0 +.nr H5 0 +.na +.LP +.XS +Chapter 13: Locales and Internationalized Text Functions +.XE +An internationalized application is one that is adaptable to the requirements +of different native languages, local customs, and character string encodings. +The process of adapting the operation to a particular native language, +local custom, or string encoding is called \fIlocalization\fP\^. +A goal of internationalization is to permit localization +without program source modifications or recompilation. +.LP +As one of the localization mechanisms, +Xlib provides an X Input Method +.Pn ( XIM ) +functional interface for internationalized text input +and an X Output Method +.Pn ( XOM ) +functional interface for internationalized text output. +.LP +Internationalization in X is based on the concept of a \fIlocale\fP. +A locale defines the localized behavior of a program at run time. +Locales affect Xlib in its: +.IP \(bu 5 +Encoding and processing of input method text +.IP \(bu 5 +Encoding of resource files and values +.IP \(bu 5 +Encoding and imaging of text strings +.IP \(bu 5 +Encoding and decoding for inter-client text communication +.LP +Characters from various languages are represented in a computer +using an encoding. +Different languages have different encodings, +and there are even different encodings for the same characters +in the same language. +.LP +This chapter defines support for localized text imaging and text input +and describes the locale mechanism that controls all locale-dependent +Xlib functions. +Sets of functions are provided for multibyte (char *) text as well as +wide character (wchar_t) text in the form supported +by the host C language environment. +The multibyte and wide character functions +are equivalent except for the form of the text argument. +.LP +The Xlib internationalization functions are not meant to provide +support for multilingual applications (mixing multiple languages +within a single piece of text), but they make it possible to +implement applications that work in limited fashion with more than +one language in independent contexts. +.LP +The remainder of this chapter discusses: +.IP \(bu 5 +X locale management +.IP \(bu 5 +Locale and modifier dependencies +.IP \(bu 5 +Variable argument lists +.IP \(bu 5 +Output methods +.IP \(bu 5 +Input methods +.IP \(bu 5 +String constants +.NH 2 +X Locale Management +.XS +\*(SN X Locale Management +.XE +.LP +X supports one or more of the locales defined by the host environment. +On implementations that conform to the ANSI C library, +the locale announcement method is +.PN setlocale . +This function configures the locale operation of both +the host C library and Xlib. +The operation of Xlib is governed by the LC_CTYPE category; +this is called the \fIcurrent locale\fP. +An implementation is permitted to provide implementation-dependent +mechanisms for announcing the locale in addition to +.PN setlocale . +.LP +On implementations that do not conform to the ANSI C library, +the locale announcement method is Xlib implementation-dependent. +.LP +The mechanism by which the semantic operation of Xlib is defined +for a specific locale is implementation-dependent. +.LP +.sp +X is not required to support all the locales supported by the host. +To determine if the current locale is supported by X, use +.PN XSupportsLocale . +.IN "XSupportsLocale" "" "@DEF@" +.sM +.FD 0 +Bool XSupportsLocale\^(\|) +.FN +.LP +.eM +The +.PN XSupportsLocale +function returns +.PN True +if Xlib functions are capable of operating under the current locale. +If it returns +.PN False , +Xlib locale-dependent functions for which the +.PN XLocaleNotSupported +return status is defined will return +.PN XLocaleNotSupported . +Other Xlib locale-dependent routines will operate in the ``C'' locale. +.LP +The client is responsible for selecting its locale and X modifiers. +Clients should provide a means for the user to override the clients' +locale selection at client invocation. +Most single-display X clients operate in a single locale +for both X and the host processing environment. +They will configure the locale by calling three functions: +the host locale configuration function, +.PN XSupportsLocale , +and +.PN XSetLocaleModifiers . +.LP +The semantics of certain categories of X internationalization capabilities +can be configured by setting modifiers. +Modifiers are named by implementation-dependent and locale-specific strings. +The only standard use for this capability at present +is selecting one of several styles of keyboard input method. +.LP +.sp +To configure Xlib locale modifiers for the current locale, use +.PN XSetLocaleModifiers . +.IN "XSetLocaleModifiers" "" "@DEF@" +.sM +.FD 0 +char *XSetLocaleModifiers\^(\^\fImodifier_list\fP\^) +.br + char *\fImodifier_list\fP\^; +.FN +.IP \fImodifier_list\fP 1i +Specifies the modifiers. +.LP +.eM +The +.PN XSetLocaleModifiers +function sets the X modifiers for the current locale setting. +The modifier_list argument is a null-terminated string of the form +``{@\^\fIcategory\fP\^=\^\fIvalue\fP\^}'', that is, +having zero or more concatenated ``@\^\fIcategory\fP\^=\^\fIvalue\fP\^'' +entries, where \fIcategory\fP is a category name +and \fIvalue\fP is the (possibly empty) setting for that category. +The values are encoded in the current locale. +Category names are restricted to the POSIX Portable Filename Character Set. +.LP +The local host X locale modifiers announcer (on POSIX-compliant systems, +the XMODIFIERS environment variable) is appended to the modifier_list to +provide default values on the local host. +If a given category appears more than once in the list, +the first setting in the list is used. +If a given category is not included in the full modifier list, +the category is set to an implementation-dependent default +for the current locale. +An empty value for a category explicitly specifies the +implementation-dependent default. +.LP +If the function is successful, it returns a pointer to a string. +The contents of the string are such that a subsequent call with that string +(in the same locale) will restore the modifiers to the same settings. +If modifier_list is a NULL pointer, +.PN XSetLocaleModifiers +also returns a pointer to such a string, +and the current locale modifiers are not changed. +.LP +If invalid values are given for one or more modifier categories supported by +the locale, a NULL pointer is returned, and none of the +current modifiers are changed. +.LP +At program startup, +the modifiers that are in effect are unspecified until +the first successful call to set them. Whenever the locale is changed, the +modifiers that are in effect become unspecified until the next successful call +to set them. +Clients should always call +.PN XSetLocaleModifiers +with a non-NULL modifier_list after setting the locale +before they call any locale-dependent Xlib routine. +.LP +The only standard modifier category currently defined is ``im'', +which identifies the desired input method. +The values for input method are not standardized. +A single locale may use multiple input methods, +switching input method under user control. +The modifier may specify the initial input method in effect +or an ordered list of input methods. +Multiple input methods may be specified in a single im value string +in an implementation-dependent manner. +.LP +The returned modifiers string is owned by Xlib and should not be modified or +freed by the client. +It may be freed by Xlib after the current locale or modifiers are changed. +Until freed, it will not be modified by Xlib. +.LP +The recommended procedure for clients initializing their locale and modifiers +is to obtain locale and modifier announcers separately from +one of the following prioritized sources: +.IP \(bu 5 +A command line option +.IP \(bu 5 +A resource +.IP \(bu 5 +The empty string ("\^") +.LP +The first of these that is defined should be used. +Note that when a locale command line option or locale resource is defined, +the effect should be to set all categories to the specified locale, +overriding any category-specific settings in the local host environment. +.NH 2 +Locale and Modifier Dependencies +.XS +\*(SN Locale and Modifier Dependencies +.XE +.LP +The internationalized Xlib functions operate in the current locale +configured by the host environment and X locale modifiers set by +.PN XSetLocaleModifiers +or in the locale and modifiers configured at the time +some object supplied to the function was created. +For each locale-dependent function, +the following table describes the locale (and modifiers) dependency: +.TS H +lw(1.25i) lw(2.5i) lw(2i). +_ +.sp 6p +.B +Locale from Affects the Function In +.sp 6p +_ +.sp 6p +.TH +.R + Locale Query/Configuration: +.sp 6p +T{ +.PN setlocale +T} T{ +.PN XSupportsLocale +T} T{ +Locale queried +T} + T{ +.PN XSetLocaleModifiers +T} T{ +Locale modified +T} +.sp + Resources: +.sp 6p +T{ +.PN setlocale +T} T{ +.PN XrmGetFileDatabase +T} T{ +Locale of +.PN XrmDatabase +T} + T{ +.PN XrmGetStringDatabase +T} +T{ +.PN XrmDatabase +T} T{ +.PN XrmPutFileDatabase +T} T{ +Locale of +.PN XrmDatabase +T} + T{ +.PN XrmLocaleOfDatabase +T} +.sp + Setting Standard Properties: +.sp 6p +T{ +.PN setlocale +T} T{ +.PN XmbSetWMProperties +T} T{ +Encoding of supplied/returned +T} + text (some WM_ property + text in environment locale) +.sp 6p +T{ +.PN setlocale +T} T{ +.PN XmbTextPropertyToTextList +T} T{ +Encoding of supplied/returned text +T} + T{ +.PN XwcTextPropertyToTextList +T} + T{ +.PN XmbTextListToTextProperty +T} + T{ +.PN XwcTextListToTextProperty +T} +.sp + Text Input: +.sp 6p +T{ +.PN setlocale +T} T{ +.PN XOpenIM +T} T{ +XIM input method selection +T} + T{ +.PN XRegisterIMInstantiateCallback +T} T{ +XIM selection +T} + T{ +.PN XUnregisterIMInstantiateCallback +T} T{ +XIM selection +T} +T{ +.PN XIM +T} T{ +.PN XCreateIC +T} T{ +XIC input method configuration +T} + T{ +.PN XLocaleOfIM , +and so on +T} T{ +Queried locale +T} +T{ +.PN XIC +T} T{ +.PN XmbLookupString +T} T{ +Keyboard layout +T} + T{ +.PN XwcLookupString +T} T{ +Encoding of returned text +T} +.sp + Text Drawing: +.sp 6p +T{ +.PN setlocale +T} T{ +.PN XOpenOM +T} T{ +XOM output method selection +T} + T{ +.PN XCreateFontSet +T} T{ +Charsets of fonts in +.PN XFontSet +T} +T{ +.PN XOM +T} T{ +.PN XCreateOC +T} T{ +XOC output method configuration +T} + T{ +.PN XLocaleOfOM , +and so on +T} T{ +Queried locale +T} +T{ +.PN XFontSet +T} T{ +.PN XmbDrawText , +T} T{ +Locale of supplied text +T} + T{ +.PN XwcDrawText , +and so on +T} T{ +Locale of supplied text +T} + T{ +.PN XExtentsOfFontSet , +and so on +T} T{ +Locale-dependent metrics +T} + T{ +.PN XmbTextExtents , +T} + T{ +.PN XwcTextExtents , +and so on +T} +.sp + Xlib Errors: +.sp 6p +T{ +.PN setlocale +T} T{ +.PN XGetErrorDatabaseText +T} T{ +Locale of error message +T} + T{ +.PN XGetErrorText +T} +.sp 6p +_ +.TE +.LP +Clients may assume that a locale-encoded text string returned +by an X function can be passed to a C library routine, or vice versa, +if the locale is the same at the two calls. +.LP +All text strings processed by internationalized Xlib functions are assumed +to begin in the initial state of the encoding of the locale, if the encoding +is state-dependent. +.LP +All Xlib functions behave as if they do not change the current locale +or X modifier setting. +(This means that if they do change locale or call +.PN XSetLocaleModifiers +with a non-NULL argument, they must save and restore the current state on +entry and exit.) +Also, Xlib functions on implementations that conform to the ANSI C library do +not alter the global state associated with the ANSI C functions +.PN mblen , +.PN mbtowc , +.PN wctomb , +and +.PN strtok . +.NH 2 +Variable Argument Lists +.XS +\*(SN Variable Argument Lists +.XE +.LP +Various functions in this chapter have arguments that conform +to the ANSI C variable argument list calling convention. +Each function denoted with an argument of the form ``...'' takes +a variable-length list of name and value pairs, +where each name is a string and each value is of type +.PN XPointer . +A name argument that is NULL identifies the end of the list. +.LP +A variable-length argument list may contain a nested list. +If the name +.PN XNVaNestedList +is specified in place of an argument name, +then the following value is interpreted as an +.PN XVaNestedList +value that specifies a list of values logically inserted into the +original list at the point of declaration. +A NULL identifies the end of a nested list. +.LP +.sp +To allocate a nested variable argument list dynamically, use +.PN XVaCreateNestedList . +.IN "XVaCreateNestedList" "" @DEF@" +.sM +.FD 0 +typedef void * XVaNestedList; + +XVaNestedList XVaCreateNestedList\^(\^\fIdummy\fP\^, ...) +.br + int \fIdummy\fP\^; +.FN +.IP \fIdummy\fP 1i +Specifies an unused argument (required by ANSI C). +.ds Al +.IP ... 1i +Specifies the variable length argument list\*(Al. +.LP +.eM +The +.PN XVaCreateNestedList +function allocates memory and copies its arguments into +a single list pointer, +which may be used as a value for arguments requiring a list value. +Any entries are copied as specified. +Data passed by reference is not copied; +the caller must ensure data remains valid for the lifetime +of the nested list. +The list should be freed using +.PN XFree +when it is no longer needed. +.NH 2 +Output Methods +.XS +\*(SN Output Methods +.XE +.LP +This section provides discussions of the following X Output Method +(XOM) topics: +.IP \(bu 5 +Output method overview +.IP \(bu 5 +Output method functions +.IP \(bu 5 +Output method values +.IP \(bu 5 +Output context functions +.IP \(bu 5 +Output context values +.IP \(bu 5 +Creating and freeing a font set +.IP \(bu 5 +Obtaining font set metrics +.IP \(bu 5 +Drawing text using font sets +.NH 3 +Output Method Overview +.XS +\*(SN Output Method Overview +.XE +.LP +Locale-dependent text may include one or more text components, each of +which may require different fonts and character set encodings. +In some languages, each component might have a different +drawing direction, and some components might contain +context-dependent characters that change shape based on +relationships with neighboring characters. +.LP +When drawing such locale-dependent text, some locale-specific +knowledge is required; +for example, what fonts are required to draw the text, +how the text can be separated into components, and which +fonts are selected to draw each component. +Further, when bidirectional text must be drawn, +the internal representation order of the text must be changed +into the visual representation order to be drawn. +.LP +An X Output Method provides a functional interface so that clients +do not have to deal directly with such locale-dependent details. +Output methods provide the following capabilities: +.IP \(bu 5 +Creating a set of fonts required to draw locale-dependent text. +.IP \(bu 5 +Drawing locale-dependent text with a font set without the caller +needing to be aware of locale dependencies. +.IP \(bu 5 +Obtaining the escapement and extents in pixels of locale-dependent text. +.IP \(bu 5 +Determining if bidirectional or context-dependent drawing is required +in a specific locale with a specific font set. +.LP +Two different abstractions are used in the representation of +the output method for clients. +.LP +The abstraction used to communicate with an output method +is an opaque data structure represented by the +.PN XOM +data type. +The abstraction for representing the state of a particular output thread +is called an \fIoutput context\fP. +The Xlib representation of an output context is an +.PN XOC , +which is compatible with +.PN XFontSet +in terms of its functional interface, but is +a broader, more generalized abstraction. +.NH 3 +Output Method Functions +.XS +\*(SN Output Method Functions +.XE +.LP +To open an output method, use +.PN XOpenOM . +.IN "XOpenOM" "" "@DEF@" +.sM +.FD 0 +XOM XOpenOM\^(\^\fIdisplay\fP\^, \fIdb\fP\^, \fIres_name\fP\^, \fIres_class\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + XrmDatabase \fIdb\fP\^; +.br + char *\fIres_name\fP\^; +.br + char *\fIres_class\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIdb\fP 1i +Specifies a pointer to the resource database. +.IP \fIres_name\fP 1i +Specifies the full resource name of the application. +.IP \fIres_class\fP 1i +Specifies the full class name of the application. +.LP +.eM +The +.PN XOpenOM +function opens an output method +matching the current locale and modifiers specification. +The current locale and modifiers are bound to the output method +when +.PN XOpenOM +is called. +The locale associated with an output method cannot be changed. +.LP +The specific output method to which this call will be routed +is identified on the basis of the current locale and modifiers. +.PN XOpenOM +will identify a default output method corresponding to the +current locale. +That default can be modified using +.PN XSetLocaleModifiers +to set the output method modifier. +.LP +The db argument is the resource database to be used by the output method +for looking up resources that are private to the output method. +It is not intended that this database be used to look +up values that can be set as OC values in an output context. +If db is NULL, +no database is passed to the output method. +.LP +The res_name and res_class arguments specify the resource name +and class of the application. +They are intended to be used as prefixes by the output method +when looking up resources that are common to all output contexts +that may be created for this output method. +The characters used for resource names and classes must be in the +X Portable Character Set. +The resources looked up are not fully specified +if res_name or res_class is NULL. +.LP +The res_name and res_class arguments are not assumed to exist beyond +the call to +.PN XOpenOM . +The specified resource database is assumed to exist for the lifetime +of the output method. +.LP +.PN XOpenOM +returns NULL if no output method could be opened. +.LP +.sp +To close an output method, use +.PN XCloseOM . +.IN "XCloseOM" "" "@DEF@" +.sM +.FD 0 +Status XCloseOM\^(\^\fIom\fP\^) +.br + XOM \fIom\fP\^; +.FN +.IP \fIom\fP 1i +Specifies the output method. +.LP +.eM +The +.PN XCloseOM +function closes the specified output method. +.LP +.sp +To set output method attributes, use +.PN XSetOMValues . +.IN "XSetOMValues" "" "@DEF@" +.sM +.FD 0 +char * XSetOMValues\^(\^\fIom\fP\^, ...) +.br + XOM \fIom\fP\^; +.FN +.IP \fIom\fP 1i +Specifies the output method. +.ds Al \ to set XOM values +.IP ... 1i +Specifies the variable-length argument list\*(Al. +.LP +.eM +The +.PN XSetOMValues +function presents a variable argument list programming interface +for setting properties or features of the specified output method. +This function returns NULL if it succeeds; +otherwise, +it returns the name of the first argument that could not be obtained. +.LP +No standard arguments are currently defined by Xlib. +.LP +.sp +To query an output method, use +.PN XGetOMValues . +.IN "XGetOMValues" "" "@DEF@" +.sM +.FD 0 +char * XGetOMValues\^(\^\fIom\fP\^, ...) +.br + XOM \fIom\fP\^; +.FN +.IP \fIom\fP 1i +Specifies the output method. +.ds Al \ to get XOM values +.IP ... 1i +Specifies the variable-length argument list\*(Al. +.LP +.eM +The +.PN XGetOMValues +function presents a variable argument list programming interface +for querying properties or features of the specified output method. +This function returns NULL if it succeeds; +otherwise, +it returns the name of the first argument that could not be obtained. +.LP +To obtain the display associated with an output method, use +.PN XDisplayOfOM . +.IN "XDisplayOfOM" "" "@DEF@" +.sM +.FD 0 +Display * XDisplayOfOM\^(\^\fIom\fP\^) +.br + XOM \fIom\fP\^; +.FN +.IP \fIom\fP 1i +Specifies the output method. +.LP +.eM +The +.PN XDisplayOfOM +function returns the display associated with the specified output method. +.LP +.sp +To get the locale associated with an output method, use +.PN XLocaleOfOM . +.IN "XLocaleOfOM" "" "@DEF@" +.sM +.FD 0 +char * XLocaleOfOM\^(\^\fIom\fP\^) +.br + XOM \fIom\fP\^; +.FN +.IP \fIom\fP 1i +Specifies the output method. +.LP +.eM +The +.PN XLocaleOfOM +returns the locale associated with the specified output method. +.NH 3 +X Output Method Values +.XS +\*(SN X Output Method Values +.XE +.LP +The following table describes how XOM values are interpreted by an +output method. +The first column lists the XOM values. The second column indicates +how each of the XOM values are treated by a particular output style. +.LP +.LP +The following key applies to this table. +.TS H +lw(1i) lw(4.75i). +_ +.sp 6p +.B +Key Explanation +.sp 6p +_ +.sp 6p +.TH +.R +G T{ +This value may be read using +.PN XGetOMValues . +T} +.sp 6p +_ +.TE +.LP +.TS H +lw(2.25i) c +lw(2.25i) c. +_ +.sp 6p +.B +XOM Value Key +.sp 6p +_ +.sp 6p +.TH +.R +T{ +.PN XNRequiredCharSet +T} T{ +G +T} +T{ +.PN XNQueryOrientation +T} T{ +G +T} +T{ +.PN XNDirectionalDependentDrawing +T} T{ +G +T} +T{ +.PN XNContextualDrawing +T} T{ +G +T} +.sp 6p +_ +.TE +.LP +.NH 4 +Required Char Set +.XS +\*(SN Required Char Set +.XE +.LP +The +.PN XNRequiredCharSet +argument returns the list of charsets that are required for loading the fonts +needed for the locale. +The value of the argument is a pointer to a structure of type +.PN XOMCharSetList . +.LP +The +.PN XOMCharSetList +structure is defined as follows: +.IN "XOMCharSetList" "" "@DEF@" +.sM +.LP +.Ds 0 +.TA .5i 2.5i +.ta .5i 2.5i +typedef struct { + int charset_count; + char **charset_list; +} XOMCharSetList; +.De +.LP +.eM +The charset_list member is a list of one or more null-terminated +charset names, and the charset_count member is the number of +charset names. +.LP +The required charset list is owned by Xlib and should not be modified or +freed by the client. +It will be freed by a call to +.PN XCloseOM +with the associated +.PN XOM . +Until freed, its contents will not be modified by Xlib. +.LP +.NH 4 +Query Orientation +.XS +\*(SN Query Orientation +.XE +.LP +The +.PN XNQueryOrientation +argument returns the global orientation of text when drawn. +Other than +.PN XOMOrientation_LTR_TTB , +the set of orientations supported is locale-dependent. +The value of the argument is a pointer to a structure of type +.PN XOMOrientation . +Clients are responsible for freeing the +.PN XOMOrientation +structure by using +.PN XFree ; +this also frees the contents of the structure. +.LP +.sM +.Ds 0 +.TA .5i 2.5i +.ta .5i 2.5i +typedef struct { + int num_orientation; + XOrientation *orientation; /* Input Text description */ +} XOMOrientation; + +typedef enum { + XOMOrientation_LTR_TTB, + XOMOrientation_RTL_TTB, + XOMOrientation_TTB_LTR, + XOMOrientation_TTB_RTL, + XOMOrientation_Context +} XOrientation; +.De +.LP +.eM +The possible value for XOrientation may be: +.IP \(bu 5 +.PN XOMOrientation_LTR_TTB +left-to-right, top-to-bottom global orientation +.IP \(bu 5 +.PN XOMOrientation_RTL_TTB +right-to-left, top-to-bottom global orientation +.IP \(bu 5 +.PN XOMOrientation_TTB_LTR +top-to-bottom, left-to-right global orientation +.IP \(bu 5 +.PN XOMOrientation_TTB_RTL +top-to-bottom, right-to-left global orientation +.IP \(bu 5 +.PN XOMOrientation_Context +contextual global orientation +.LP +.NH 4 +Directional Dependent Drawing +.XS +\*(SN Directional Dependent Drawing +.XE +.LP +The +.PN XNDirectionalDependentDrawing +argument indicates whether the text rendering functions +implement implicit handling of directional text. If this value +is +.PN True , +the output method has knowledge of directional +dependencies and reorders text as necessary when +rendering text. If this value is +.PN False , +the output method does not implement any directional text +handling, and all character directions are assumed to be left-to-right. +.LP +Regardless of the rendering order of characters, +the origins of all characters are on the primary draw direction side +of the drawing origin. +.LP +This OM value presents functionality identical to the +.PN XDirectionalDependentDrawing +function. +.NH 4 +Context Dependent Drawing +.XS +\*(SN Context Dependent Drawing +.XE +.LP +The +.PN XNContextualDrawing +argument indicates whether the text rendering functions +implement implicit context-dependent drawing. If this value is +.PN True , +the output method has knowledge of context dependencies and +performs character shape editing, combining glyphs to present +a single character as necessary. The actual shape editing is +dependent on the locale implementation and the font set used. +.LP +This OM value presents functionality identical to the +.PN XContextualDrawing +function. +.NH 3 +Output Context Functions +.XS +\*(SN Output Context Functions +.XE +.LP +An output context is an abstraction that contains both the data +required by an output method and the information required +to display that data. +There can be multiple output contexts for one output method. +The programming interfaces for creating, reading, or modifying +an output context use a variable argument list. +The name elements of the argument lists are referred to as XOC values. +It is intended that output methods be controlled by these XOC values. +As new XOC values are created, +they should be registered with the X Consortium. +An +.PN XOC +can be used anywhere an +.PN XFontSet +can be used, and vice versa; +.PN XFontSet +is retained for compatibility with previous releases. +The concepts of output methods and output contexts include broader, +more generalized abstraction than font set, +supporting complex and more intelligent text display, and dealing not only +with multiple fonts but also with context dependencies. +However, +.PN XFontSet +is widely used in several interfaces, so +.PN XOC +is defined as an upward compatible type of +.PN XFontSet . +.LP +.sp +To create an output context, use +.PN XCreateOC . +.IN "XCreateOC" "" "@DEF@" +.sM +.FD 0 +XOC XCreateOC\^(\^\fIom\fP\^, ...) +.br + XOM \fIom\fP\^; +.FN +.IP \fIom\fP 1i +Specifies the output method. +.ds Al \ to set XOC values +.IP ... 1i +Specifies the variable-length argument list\*(Al. +.LP +.eM +The +.PN XCreateOC +function creates an output context within the specified output method. +.LP +The base font names argument is mandatory at creation time, and +the output context will not be created unless it is provided. +All other output context values can be set later. +.LP +.PN XCreateOC +returns NULL if no output context could be created. +NULL can be returned for any of the following reasons: +.IP \(bu 5 +A required argument was not set. +.IP \(bu 5 +A read-only argument was set. +.IP \(bu 5 +An argument name is not recognized. +.IP \(bu 5 +The output method encountered an output method implementation-dependent error. +.LP +.PN XCreateOC +can generate a +.PN BadAtom +error. +.LP +.sp +To destroy an output context, use +.PN XDestroyOC . +.IN "XDestroyOC" "" "@DEF@" +.sM +.FD 0 +void XDestroyOC\^(\^\fIoc\fP\^) +.br + XOC \fIoc\fP\^; +.FN +.IP \fIoc\fP 1i +Specifies the output context. +.LP +.eM +The +.PN XDestroyOC +function destroys the specified output context. +.LP +.sp +To get the output method associated with an output context, use +.PN XOMOfOC . +.IN "XOMOfOC" "" "@DEF@" +.sM +.FD 0 +XOM XOMOfOC\^(\^\fIoc\fP\^) +.br + XOC \fIoc\fP\^; +.FN +.IP \fIoc\fP 1i +Specifies the output context. +.LP +.eM +The +.PN XOMOfOC +function returns the output method associated with the +specified output context. +.LP +.sp +Xlib provides two functions for setting and reading output context values, +respectively, +.PN XSetOCValues +and +.PN XGetOCValues . +Both functions have a variable-length argument list. +In that argument list, any XOC value's name must be denoted +with a character string using the X Portable Character Set. +.LP +.sp +To set XOC values, use +.PN XSetOCValues . +.IN "XSetOCValues" "" "@DEF@" +.sM +.FD 0 +char * XSetOCValues\^(\^\fIoc\fP\^, ...) +.br + XOC \fIoc\fP\^; +.FN +.IP \fIoc\fP 1i +Specifies the output context. +.ds Al \ to set XOC values +.IP ... 1i +Specifies the variable-length argument list\*(Al. +.LP +.eM +The +.PN XSetOCValues +function returns NULL if no error occurred; +otherwise, +it returns the name of the first argument that could not be set. +An argument might not be set for any of the following reasons: +.IP \(bu 5 +The argument is read-only. +.IP \(bu 5 +The argument name is not recognized. +.IP \(bu 5 +An implementation-dependent error occurs. +.LP +Each value to be set must be an appropriate datum, +matching the data type imposed by the semantics of the argument. +.LP +.PN XSetOCValues +can generate a +.PN BadAtom +error. +.LP +.sp +To obtain XOC values, use +.PN XGetOCValues . +.IN "XGetOCValues" "" "@DEF@" +.sM +.FD 0 +char * XGetOCValues\^(\^\fIoc\fP\^, ...) +.br + XOC \fIoc\fP\^; +.FN +.IP \fIoc\fP 1i +Specifies the output context. +.ds Al \ to get XOC values +.IP ... 1i +Specifies the variable-length argument list\*(Al. +.LP +.eM +The +.PN XGetOCValues +function returns NULL if no error occurred; otherwise, +it returns the name of the first argument that could not be obtained. +An argument might not be obtained for any of the following reasons: +.IP \(bu 5 +The argument name is not recognized. +.IP \(bu 5 +An implementation-dependent error occurs. +.LP +Each argument value +following a name must point to a location where the value is to be stored. +.NH 3 +Output Context Values +.XS +\*(SN Output Context Values +.XE +.LP +The following table describes how XOC values are interpreted +by an output method. +The first column lists the XOC values. +The second column indicates the alternative interfaces that function +identically and are provided for compatibility with previous releases. +The third column indicates how each of the XOC values is treated. +.LP +The following keys apply to this table. +.TS H +lw(1i) lw(4.75i). +_ +.sp 6p +.B +Key Explanation +.sp 6p +_ +.TH +.R +C T{ +This value must be set with +.PN XCreateOC . +T} +D T{ +This value may be set using +.PN XCreateOC . +If it is not set, +.br +a default is provided. +T} +G T{ +This value may be read using +.PN XGetOCValues . +T} +S T{ +This value must be set using +.PN XSetOCValues . +T} +.sp 6p +_ +.TE +.LP +.TS H +l c c +l c c. +_ +.sp 6p +.B +XOC Value Alternative Interface Key +.sp 6p +_ +.sp 6p +.TH +.R +T{ +BaseFontName +T} T{ +.PN XCreateFontSet +T} T{ +C-G +T} +T{ +MissingCharSet +T} T{ +.PN XCreateFontSet +T} T{ +G +T} +T{ +DefaultString +T} T{ +.PN XCreateFontSet +T} T{ +G +T} +T{ +Orientation +T} T{ +\- +T} T{ +D-S-G +T} +T{ +ResourceName +T} T{ +\- +T} T{ +S-G +T} +T{ +ResourceClass +T} T{ +\- +T} T{ +S-G +T} +T{ +FontInfo +T} T{ +.PN XFontsOfFontSet +T} T{ +G +T} +T{ +OMAutomatic +T} T{ +\- +T} T{ +G +T} +.sp 6p +_ +.TE +.LP +.NH 4 +Base Font Name +.XS +\*(SN Base Font Name +.XE +.LP +The +.PN XNBaseFontName +argument is a list of base font names that Xlib uses +to load the fonts needed for the locale. +The base font names are a comma-separated list. The string is null-terminated +and is assumed to be in the Host Portable Character Encoding; +otherwise, the result is implementation-dependent. +White space immediately on either side of a separating comma is ignored. +.LP +Use of XLFD font names permits Xlib to obtain the fonts needed for a +variety of locales from a single locale-independent base font name. +The single base font name should name a family of fonts whose members +are encoded in the various charsets needed by the locales of interest. +.LP +An XLFD base font name can explicitly name a charset needed for the locale. +This allows the user to specify an exact font for use with a charset required +by a locale, fully controlling the font selection. +.LP +If a base font name is not an XLFD name, +Xlib will attempt to obtain an XLFD name from the font properties +for the font. +If Xlib is successful, the +.PN XGetOCValues +function will return this XLFD name instead of the client-supplied name. +.LP +This argument must be set at creation time +and cannot be changed. +If no fonts exist for any of the required charsets, +or if the locale definition in Xlib requires that a font exist +for a particular charset and a font is not found for that charset, +.PN XCreateOC +returns NULL. +.LP +When querying for the +.PN XNBaseFontName +XOC value, +.PN XGetOCValues +returns a null-terminated string identifying the base font names that +Xlib used to load the fonts needed for the locale. +This string is owned by Xlib and should not be modified or freed by +the client. +The string will be freed by a call to +.PN XDestroyOC +with the associated +.PN XOC . +Until freed, the string contents will not be modified by Xlib. +.NH 4 +Missing CharSet +.XS +\*(SN Missing CharSet +.XE +.LP +The +.PN XNMissingCharSet +argument returns the list of required charsets that are missing from the +font set. +The value of the argument is a pointer to a structure of type +.PN XOMCharSetList . +.LP +If fonts exist for all of the charsets required by the current locale, +charset_list is set to NULL and charset_count is set to zero. +If no fonts exist for one or more of the required charsets, +charset_list is set to a list of one or more null-terminated charset names +for which no fonts exist, and charset_count is set to the number of +missing charsets. +The charsets are from the list of the required charsets for +the encoding of the locale and do not include any charsets to which Xlib +may be able to remap a required charset. +.LP +The missing charset list is owned by Xlib and should not be modified or +freed by the client. +It will be freed by a call to +.PN XDestroyOC +with the associated +.PN XOC . +Until freed, its contents will not be modified by Xlib. +.NH 4 +Default String +.XS +\*(SN Default String +.XE +.LP +When a drawing or measuring function is called with an +.PN XOC +that has missing charsets, some characters in the locale will not be +drawable. +The +.PN XNDefaultString +argument returns a pointer to a string that represents the glyphs +that are drawn with this +.PN XOC +when the charsets of the available fonts do not include all glyphs +required to draw a character. +The string does not necessarily consist of valid characters +in the current locale and is not necessarily drawn with +the fonts loaded for the font set, +but the client can draw or measure the default glyphs +by including this string in a string being drawn or measured with the +.PN XOC . +.LP +If the +.PN XNDefaultString +argument returned the empty string ("\^"), +no glyphs are drawn and the escapement is zero. +The returned string is null-terminated. +It is owned by Xlib and should not be modified or freed by the client. +It will be freed by a call to +.PN XDestroyOC +with the associated +.PN XOC . +Until freed, its contents will not be modified by Xlib. +.NH 4 +Orientation +.XS +\*(SN Orientation +.XE +.LP +The +.PN XNOrientation +argument specifies the current orientation of text when drawn. The value of +this argument is one of the values returned by the +.PN XGetOMValues +function with the +.PN XNQueryOrientation +argument specified in the +.PN XOrientation +list. +The value of the argument is of type +.PN XOrientation . +When +.PN XNOrientation +is queried, the value specifies the current orientation. +When +.PN XNOrientation +is set, a value is used to set the current orientation. +.LP +When +.PN XOMOrientation_Context +is set, the text orientation of the +text is determined according to an implementation-defined method +(for example, ISO 6429 control sequences), and the initial text orientation for +locale-dependent Xlib functions is assumed to +be +.PN XOMOrientation_LTR_TTB . +.LP +The +.PN XNOrientation +value does not change the prime drawing direction +for Xlib drawing functions. +.NH 4 +Resource Name and Class +.XS +\*(SN Resource Name and Class +.XE +.LP +The +.PN XNResourceName +and +.PN XNResourceClass +arguments are strings that specify the full name and class +used by the client to obtain resources for the display of the output context. +These values should be used as prefixes for name and class +when looking up resources that may vary according to the output context. +If these values are not set, +the resources will not be fully specified. +.LP +It is not intended that values that can be set as XOM values be +set as resources. +.LP +When querying for the +.PN XNResourceName +or +.PN XNResourceClass +XOC value, +.PN XGetOCValues +returns a null-terminated string. +This string is owned by Xlib and should not be modified or freed by +the client. +The string will be freed by a call to +.PN XDestroyOC +with the associated +.PN XOC +or when the associated value is changed via +.PN XSetOCValues . +Until freed, the string contents will not be modified by Xlib. +.NH 4 +Font Info +.XS +\*(SN Font Info +.XE +.LP +The +.PN XNFontInfo +argument specifies a list of one or more +.PN XFontStruct +structures +and font names for the fonts used for drawing by the given output context. +The value of the argument is a pointer to a structure of type +.PN XOMFontInfo . +.LP +.sM +.Ds 0 +.TA .5i 2.5i +.ta .5i 2.5i +typedef struct { + int num_font; + XFontStruct **font_struct_list; + char **font_name_list; +} XOMFontInfo; +.De +.LP +.eM +A list of pointers to the +.PN XFontStruct +structures is returned to font_struct_list. +A list of pointers to null-terminated, fully-specified font name strings +in the locale of the output context is returned to font_name_list. +The font_name_list order corresponds to the font_struct_list order. +The number of +.PN XFontStruct +structures and font names is returned to num_font. +.LP +Because it is not guaranteed that a given character will be imaged using a +single font glyph, +there is no provision for mapping a character or default string +to the font properties, font ID, or direction hint for the font +for the character. +The client may access the +.PN XFontStruct +list to obtain these values for all the fonts currently in use. +.LP +Xlib does not guarantee that fonts are loaded from the server +at the creation of an +.PN XOC . +Xlib may choose to cache font data, loading it only as needed to draw text +or compute text dimensions. +Therefore, existence of the per_char metrics in the +.PN XFontStruct +structures in the +.PN XFontStructSet +is undefined. +Also, note that all properties in the +.PN XFontStruct +structures are in the STRING encoding. +.LP +The client must not free the +.PN XOMFontInfo +struct itself; it will be freed when the +.PN XOC +is closed. +.NH 4 +OM Automatic +.XS +\*(SN OM Automatic +.XE +.LP +The +.PN XNOMAutomatic +argument returns whether the associated output context was created by +.PN XCreateFontSet +or not. Because the +.PN XFreeFontSet +function not only destroys the output context but also closes the implicit +output method associated with it, +.PN XFreeFontSet +should be used with any output context created by +.PN XCreateFontSet . +However, it is possible that a client does not know how the output context +was created. +Before a client destroys the output context, +it can query whether +.PN XNOMAutomatic +is set to determine whether +.PN XFreeFontSet +or +.PN XDestroyOC +should be used to destroy the output context. +.NH 3 +Creating and Freeing a Font Set +.XS +\*(SN Creating and Freeing a Font Set +.XE +.LP +Xlib international text drawing is done using a set of one or more fonts, +as needed for the locale of the text. +Fonts are loaded according to a list of base font names +supplied by the client and the charsets required by the locale. +The +.PN XFontSet +is an opaque type representing the state of a particular output thread +and is equivalent to the type +.PN XOC . +.LP +.sp +The +.PN XCreateFontSet +function is a convenience function for creating an output context using +only default values. The returned +.PN XFontSet +has an implicitly created +.PN XOM . +This +.PN XOM +has an OM value +.PN XNOMAutomatic +automatically set to +.PN True +so that the output context self indicates whether it was created by +.PN XCreateOC +or +.PN XCreateFontSet . +.IN "XCreateFontSet" "" "@DEF@" +.sM +.FD 0 +XFontSet XCreateFontSet\^(\^\fIdisplay\fP\^, \fIbase_font_name_list\fP\^, \fImissing_charset_list_return\fP\^, +.br + \fImissing_charset_count_return\fP\^, \fIdef_string_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + char *\fIbase_font_name_list\fP\^; +.br + char ***\fImissing_charset_list_return\fP\^; +.br + int *\fImissing_charset_count_return\fP\^; +.br + char **\fIdef_string_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIbase_font_name_list\fP 1i +Specifies the base font names. +.IP \fImissing_charset_list_return\fP 1i +Returns the missing charsets. +.IP \fImissing_charset_count_return\fP 1i +Returns the number of missing charsets. +.IP \fIdef_string_return\fP 1i +Returns the string drawn for missing charsets. +.LP +.eM +The +.PN XCreateFontSet +function creates a font set for the specified display. +The font set is bound to the current locale when +.PN XCreateFontSet +is called. +The font set may be used in subsequent calls to obtain font +and character information and to image text in the locale of the font set. +.LP +The base_font_name_list argument is a list of base font names +that Xlib uses to load the fonts needed for the locale. +The base font names are a comma-separated list. +The string is null-terminated +and is assumed to be in the Host Portable Character Encoding; +otherwise, the result is implementation-dependent. +White space immediately on either side of a separating comma is ignored. +.LP +Use of XLFD font names permits Xlib to obtain the fonts needed for a +variety of locales from a single locale-independent base font name. +The single base font name should name a family of fonts whose members +are encoded in the various charsets needed by the locales of interest. +.LP +An XLFD base font name can explicitly name a charset needed for the locale. +This allows the user to specify an exact font for use with a charset required +by a locale, fully controlling the font selection. +.LP +If a base font name is not an XLFD name, +Xlib will attempt to obtain an XLFD name from the font properties +for the font. +If this action is successful in obtaining an XLFD name, the +.PN XBaseFontNameListOfFontSet +function will return this XLFD name instead of the client-supplied name. +.LP +Xlib uses the following algorithm to select the fonts +that will be used to display text with the +.PN XFontSet . +.LP +For each font charset required by the locale, +the base font name list is searched for the first appearance of one +of the following cases that names a set of fonts that exist at the server: +.IP \(bu 5 +The first XLFD-conforming base font name that specifies the required +charset or a superset of the required charset in its +.PN CharSetRegistry +and +.PN CharSetEncoding +fields. +The implementation may use a base font name whose specified charset +is a superset of the required charset, for example, +an ISO8859-1 font for an ASCII charset. +.IP \(bu 5 +The first set of one or more XLFD-conforming base font names +that specify one or more charsets that can be remapped to support the +required charset. +The Xlib implementation may recognize various mappings +from a required charset to one or more other charsets +and use the fonts for those charsets. +For example, JIS Roman is ASCII with tilde and backslash replaced +by yen and overbar; +Xlib may load an ISO8859-1 font to support this character set +if a JIS Roman font is not available. +.IP \(bu 5 +The first XLFD-conforming font name or the first non-XLFD font name +for which an XLFD font name can be obtained, combined with the +required charset (replacing the +.PN CharSetRegistry +and +.PN CharSetEncoding +fields in the XLFD font name). +As in case 1, +the implementation may use a charset that is a superset +of the required charset. +.IP \(bu 5 +The first font name that can be mapped in some implementation-dependent +manner to one or more fonts that support imaging text in the charset. +.LP +For example, assume that a locale required the charsets: +.LP +.Ds 0 +ISO8859-1 +JISX0208.1983 +JISX0201.1976 +GB2312-1980.0 +.De +.LP +The user could supply a base_font_name_list that explicitly specifies the +charsets, ensuring that specific fonts are used if they exist. +For example: +.LP +.Ds 0 +"-JIS-Fixed-Medium-R-Normal--26-180-100-100-C-240-JISX0208.1983-0,\\ +-JIS-Fixed-Medium-R-Normal--26-180-100-100-C-120-JISX0201.1976-0,\\ +-GB-Fixed-Medium-R-Normal--26-180-100-100-C-240-GB2312-1980.0,\\ +-Adobe-Courier-Bold-R-Normal--25-180-75-75-M-150-ISO8859-1" +.De +.LP +Alternatively, the user could supply a base_font_name_list +that omits the charsets, +letting Xlib select font charsets required for the locale. +For example: +.LP +.Ds 0 +"-JIS-Fixed-Medium-R-Normal--26-180-100-100-C-240,\\ +-JIS-Fixed-Medium-R-Normal--26-180-100-100-C-120,\\ +-GB-Fixed-Medium-R-Normal--26-180-100-100-C-240,\\ +-Adobe-Courier-Bold-R-Normal--25-180-100-100-M-150" +.De +.LP +Alternatively, the user could simply supply a single base font name +that allows Xlib to select from all available fonts +that meet certain minimum XLFD property requirements. +For example: +.LP +.Ds 0 +"-*-*-*-R-Normal--*-180-100-100-*-*" +.De +.LP +If +.PN XCreateFontSet +is unable to create the font set, +either because there is insufficient memory or because the current locale +is not supported, +.PN XCreateFontSet +returns NULL, missing_charset_list_return is set to NULL, +and missing_charset_count_return +is set to zero. +If fonts exist for all of the charsets required by the current locale, +.PN XCreateFontSet +returns a valid +.PN XFontSet , +missing_charset_list_return is set to NULL, +and missing_charset_count_return is set to zero. +.LP +If no font exists for one or more of the required charsets, +.PN XCreateFontSet +sets missing_charset_list_return to a +list of one or more null-terminated charset names for which no font exists +and sets missing_charset_count_return to the number of missing fonts. +The charsets are from the list of the required charsets for +the encoding of the locale and do not include any charsets to which Xlib +may be able to remap a required charset. +.LP +If no font exists for any of the required charsets +or if the locale definition in Xlib requires that a font exist +for a particular charset and a font is not found for that charset, +.PN XCreateFontSet +returns NULL. +Otherwise, +.PN XCreateFontSet +returns a valid +.PN XFontSet +to font_set. +.LP +When an Xmb/wc drawing or measuring function is called with an +.PN XFontSet +that has missing charsets, some characters in the locale will not be +drawable. +If def_string_return is non-NULL, +.PN XCreateFontSet +returns a pointer to a string that represents the glyphs +that are drawn with this +.PN XFontSet +when the charsets of the available fonts do not include all font glyphs +required to draw a codepoint. +The string does not necessarily consist of valid characters +in the current locale and is not necessarily drawn with +the fonts loaded for the font set, +but the client can draw and measure the default glyphs +by including this string in a string being drawn or measured with the +.PN XFontSet . +.LP +If the string returned to def_string_return is the empty string ("\^"), +no glyphs are drawn, and the escapement is zero. +The returned string is null-terminated. +It is owned by Xlib and should not be modified or freed by the client. +It will be freed by a call to +.PN XFreeFontSet +with the associated +.PN XFontSet . +Until freed, its contents will not be modified by Xlib. +.LP +The client is responsible for constructing an error message from the +missing charset and default string information and may choose to continue +operation in the case that some fonts did not exist. +.LP +The returned +.PN XFontSet +and missing charset list should be freed with +.PN XFreeFontSet +and +.PN XFreeStringList , +respectively. +The client-supplied base_font_name_list may be freed +by the client after calling +.PN XCreateFontSet . +.LP +.sp +To obtain a list of +.PN XFontStruct +structures and full font names given an +.PN XFontSet , +use +.PN XFontsOfFontSet . +.IN "XFontsOfFontSet" "" "@DEF@" +.sM +.FD 0 +int XFontsOfFontSet\^(\^\fIfont_set\fP\^, \fIfont_struct_list_return\fP\^, \fIfont_name_list_return\fP\^) +.br + XFontSet \fIfont_set\fP\^; +.br + XFontStruct ***\fIfont_struct_list_return\fP\^; +.br + char ***\fIfont_name_list_return\fP\^; +.FN +.IP \fIfont_set\fP 1i +Specifies the font set. +.IP \fIfont_struct_list_return\fP 1i +Returns the list of font structs. +.IP \fIfont_name_list_return\fP 1i +Returns the list of font names. +.LP +.eM +The +.PN XFontsOfFontSet +function returns a list of one or more +.PN XFontStructs +and font names for the fonts used by the Xmb and Xwc layers +for the given font set. +A list of pointers to the +.PN XFontStruct +structures is returned to font_struct_list_return. +A list of pointers to null-terminated, fully specified font name strings +in the locale of the font set is returned to font_name_list_return. +The font_name_list order corresponds to the font_struct_list order. +The number of +.PN XFontStruct +structures and font names is returned as the value of the function. +.LP +Because it is not guaranteed that a given character will be imaged using a +single font glyph, +there is no provision for mapping a character or default string +to the font properties, font ID, or direction hint for the font +for the character. +The client may access the +.PN XFontStruct +list to obtain these values for all the fonts currently in use. +.LP +Xlib does not guarantee that fonts are loaded from the server +at the creation of an +.PN XFontSet . +Xlib may choose to cache font data, loading it only as needed to draw text +or compute text dimensions. +Therefore, existence of the per_char metrics in the +.PN XFontStruct +structures in the +.PN XFontStructSet +is undefined. +Also, note that all properties in the +.PN XFontStruct +structures are in the STRING encoding. +.LP +The +.PN XFontStruct +and font name lists are owned by Xlib +and should not be modified or freed by the client. +They will be freed by a call to +.PN XFreeFontSet +with the associated +.PN XFontSet . +Until freed, their contents will not be modified by Xlib. +.LP +.sp +To obtain the base font name list and the selected font name list given an +.PN XFontSet , +use +.PN XBaseFontNameListOfFontSet . +.IN "XBaseFontNameListOfFontSet" "" "@DEF@" +.sM +.FD 0 +char *XBaseFontNameListOfFontSet\^(\^\fIfont_set\fP\^) +.br + XFontSet \fIfont_set\fP\^; +.FN +.IP \fIfont_set\fP 1i +Specifies the font set. +.LP +.eM +The +.PN XBaseFontNameListOfFontSet +function returns the original base font name list supplied +by the client when the +.PN XFontSet +was created. +A null-terminated string containing a list of +comma-separated font names is returned +as the value of the function. +White space may appear immediately on either side of separating commas. +.LP +If +.PN XCreateFontSet +obtained an XLFD name from the font properties for the font specified +by a non-XLFD base name, the +.PN XBaseFontNameListOfFontSet +function will return the XLFD name instead of the non-XLFD base name. +.LP +The base font name list is owned by Xlib and should not be modified or +freed by the client. +It will be freed by a call to +.PN XFreeFontSet +with the associated +.PN XFontSet . +Until freed, its contents will not be modified by Xlib. +.LP +.sp +To obtain the locale name given an +.PN XFontSet , +use +.PN XLocaleOfFontSet . +.IN "XLocaleOfFontSet" "" "@DEF@" +.sM +.FD 0 +char *XLocaleOfFontSet\^(\^\fIfont_set\fP\^) +.br + XFontSet \fIfont_set\fP\^; +.FN +.IP \fIfont_set\fP 1i +Specifies the font set. +.LP +.eM +The +.PN XLocaleOfFontSet +function +returns the name of the locale bound to the specified +.PN XFontSet , +as a null-terminated string. +.LP +The returned locale name string is owned by Xlib +and should not be modified or freed by the client. +It may be freed by a call to +.PN XFreeFontSet +with the associated +.PN XFontSet . +Until freed, it will not be modified by Xlib. +.LP +.sp +The +.PN XFreeFontSet +function is a convenience function for freeing an output context. +.PN XFreeFontSet +also frees its associated +.PN XOM +if the output context was created by +.PN XCreateFontSet . +.IN "XFreeFontSet" "" "@DEF@" +.sM +.FD 0 +void XFreeFontSet\^(\^\fIdisplay\fP\^, \fIfont_set\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + XFontSet \fIfont_set\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIfont_set\fP 1i +Specifies the font set. +.LP +.eM +The +.PN XFreeFontSet +function frees the specified font set. +The associated base font name list, font name list, +.PN XFontStruct +list, and +.PN XFontSetExtents , +if any, are freed. +.NH 3 +Obtaining Font Set Metrics +.XS +\*(SN Obtaining Font Set Metrics +.XE +.LP +Metrics for the internationalized text drawing functions +are defined in terms of a primary draw direction, +which is the default direction in which the character origin advances +for each succeeding character in the string. +The Xlib interface is currently defined to support only a left-to-right +primary draw direction. +The drawing origin is the position passed to the drawing function +when the text is drawn. +The baseline is a line drawn through the drawing origin parallel +to the primary draw direction. +Character ink is the pixels painted in the foreground color +and does not include interline or intercharacter spacing +or image text background pixels. +.LP +The drawing functions are allowed to implement implicit text +directionality control, reversing the order in which characters are +rendered along the primary draw direction in response to locale-specific +lexical analysis of the string. +.LP +Regardless of the character rendering order, +the origins of all characters are on the primary draw direction side +of the drawing origin. +The screen location of a particular character image may be determined with +.PN XmbTextPerCharExtents +or +.PN XwcTextPerCharExtents . +.LP +The drawing functions are allowed to implement context-dependent +rendering, where the glyphs drawn for a string are not simply a +concatenation of the glyphs that represent each individual character. +A string of two characters drawn with +.PN XmbDrawString +may render differently than if the two characters +were drawn with separate calls to +.PN XmbDrawString . +If the client appends or inserts a character +in a previously drawn string, +the client may need to redraw some adjacent characters +to obtain proper rendering. +.LP +.sp +To find out about direction-dependent rendering, use +.PN XDirectionalDependentDrawing . +.IN "XDirectionalDependentDrawing" "" "@DEF@" +.sM +.FD 0 +Bool XDirectionalDependentDrawing\^(\^\fIfont_set\fP\^) +.br + XFontSet \fIfont_set\fP\^; +.FN +.IP \fIfont_set\fP 1i +Specifies the font set. +.LP +.eM +The +.PN XDirectionalDependentDrawing +function returns +.PN True +if the drawing functions implement implicit text directionality; +otherwise, it returns +.PN False . +.LP +.sp +To find out about context-dependent rendering, use +.PN XContextualDrawing . +.IN "XContextualDrawing" "" "@DEF@" +.sM +.FD 0 +Bool XContextualDrawing\^(\^\fIfont_set\fP\^) +.br + XFontSet \fIfont_set\fP\^; +.FN +.IP \fIfont_set\fP 1i +Specifies the font set. +.LP +.eM +The +.PN XContextualDrawing +function returns +.PN True +if text drawn with the font set might include context-dependent drawing; +otherwise, it returns +.PN False . +.LP +.sp +To find out about context-dependent or direction-dependent rendering, use +.PN XContextDependentDrawing . +.IN "XContextDependentDrawing" "" "@DEF@" +.sM +.FD 0 +Bool XContextDependentDrawing\^(\^\fIfont_set\fP\^) +.br + XFontSet \fIfont_set\fP\^; +.FN +.IP \fIfont_set\fP 1i +Specifies the font set. +.LP +.eM +The +.PN XContextDependentDrawing +function returns +.PN True +if the drawing functions implement implicit text directionality or +if text drawn with the font_set might include context-dependent drawing; +otherwise, it returns +.PN False . +.LP +The drawing functions do not interpret newline, tab, or other control +characters. +The behavior when nonprinting characters other than space are drawn +is implementation-dependent. +It is the client's responsibility to interpret control characters +in a text stream. +.LP +The maximum character extents for the fonts that are used by the text +drawing layers can be accessed by the +.PN XFontSetExtents +structure: +.IN "XFontSetExtents" "" "@DEF@" +.LP +.Ds 0 +.TA .5i 3i +.ta .5i 3i +typedef struct { + XRectangle max_ink_extent; /* over all drawable characters */ + XRectangle max_logical_extent; /* over all drawable characters */ +} XFontSetExtents; +.De +.LP +The +.PN XRectangle +structures used to return font set metrics are the usual Xlib screen-oriented +rectangles +with x, y giving the upper left corner, and width and height always positive. +.LP +The max_ink_extent member gives the maximum extent, over all drawable characters, of +the rectangles that bound the character glyph image drawn in the +foreground color, relative to a constant origin. +See +.PN XmbTextExtents +and +.PN XwcTextExtents +for detailed semantics. +.LP +The max_logical_extent member gives the maximum extent, +over all drawable characters, of the rectangles +that specify minimum spacing to other graphical features, +relative to a constant origin. +Other graphical features drawn by the client, for example, +a border surrounding the text, should not intersect this rectangle. +The max_logical_extent member should be used to compute minimum +interline spacing and the minimum area that must be allowed +in a text field to draw a given number of arbitrary characters. +.LP +Due to context-dependent rendering, +appending a given character to a string may change +the string's extent by an amount other than that character's +individual extent. +.LP +The rectangles for a given character in a string can be obtained from +.PN XmbPerCharExtents +or +.PN XwcPerCharExtents . +.LP +.sp +To obtain the maximum extents structure given an +.PN XFontSet , +use +.PN XExtentsOfFontSet . +.IN "XExtentsOfFontSet" "" "@DEF@" +.sM +.FD 0 +XFontSetExtents *XExtentsOfFontSet\^(\^\fIfont_set\fP\^) +.br + XFontSet \fIfont_set\fP\^; +.FN +.IP \fIfont_set\fP 1i +Specifies the font set. +.LP +.eM +The +.PN XExtentsOfFontSet +function returns an +.PN XFontSetExtents +structure for the fonts used by the Xmb and Xwc layers +for the given font set. +.LP +The +.PN XFontSetExtents +structure is owned by Xlib and should not be modified +or freed by the client. +It will be freed by a call to +.PN XFreeFontSet +with the associated +.PN XFontSet . +Until freed, its contents will not be modified by Xlib. +.LP +.sp +To obtain the escapement in pixels of the specified text as a value, +use +.PN XmbTextEscapement +or +.PN XwcTextEscapement . +.IN "XmbTextEscapement" "" "@DEF@" +.IN "XwcTextEscapement" "" "@DEF@" +.sM +.FD 0 +int XmbTextEscapement\^(\^\fIfont_set\fP\^, \fIstring\fP\^, \fInum_bytes\fP\^) +.br + XFontSet \fIfont_set\fP\^; +.br + char *\fIstring\fP\^; +.br + int \fInum_bytes\fP\^; +.FN +.FD 0 +int XwcTextEscapement\^(\^\fIfont_set\fP\^, \fIstring\fP\^, \fInum_wchars\fP\^) +.br + XFontSet \fIfont_set\fP\^; +.br + wchar_t *\fIstring\fP\^; +.br + int \fInum_wchars\fP\^; +.FN +.IP \fIfont_set\fP 1i +Specifies the font set. +.IP \fIstring\fP 1i +Specifies the character string. +.IP \fInum_bytes\fP 1i +Specifies the number of bytes in the string argument. +.IP \fInum_wchars\fP 1i +Specifies the number of characters in the string argument. +.LP +.eM +The +.PN XmbTextEscapement +and +.PN XwcTextEscapement +functions return the escapement in pixels of the specified string as a value, +using the fonts loaded for the specified font set. +The escapement is the distance in pixels in the primary draw +direction from the drawing origin to the origin of the next character to +be drawn, assuming that the rendering of the next character is not +dependent on the supplied string. +.LP +Regardless of the character rendering order, +the escapement is always positive. +.LP +.sp +To obtain the overall_ink_return and overall_logical_return arguments, +the overall bounding box of the string's image, and a logical bounding box, +use +.PN XmbTextExtents + or +.PN XwcTextExtents . +.IN "XmbTextExtents" "" "@DEF@" +.IN "XwcTextExtents" "" "@DEF@" +.sM +.FD 0 +int XmbTextExtents\^(\^\fIfont_set\fP\^, \fIstring\fP\^, \fInum_bytes\fP\^, \fIoverall_ink_return\fP\^, \fIoverall_logical_return\fP\^) +.br + XFontSet \fIfont_set\fP\^; +.br + char *\fIstring\fP\^; +.br + int \fInum_bytes\fP\^; +.br + XRectangle *\fIoverall_ink_return\fP\^; +.br + XRectangle *\fIoverall_logical_return\fP\^; +.FN +.FD 0 +int XwcTextExtents\^(\^\fIfont_set\fP\^, \fIstring\fP\^, \fInum_wchars\fP\^, +\fIoverall_ink_return\fP\^, \fIoverall_logical_return\fP\^) +.br + XFontSet \fIfont_set\fP\^; +.br + wchar_t *\fIstring\fP\^; +.br + int \fInum_wchars\fP\^; +.br + XRectangle *\fIoverall_ink_return\fP\^; +.br + XRectangle *\fIoverall_logical_return\fP\^; +.FN +.IP \fIfont_set\fP 1i +Specifies the font set. +.IP \fIstring\fP 1i +Specifies the character string. +.IP \fInum_bytes\fP 1i +Specifies the number of bytes in the string argument. +.IP \fInum_wchars\fP 1i +Specifies the number of characters in the string argument. +.ds Ov dimensions +.IP \fIoverall_ink_return\fP 1i +Returns the overall ink \*(Ov. +.IP \fIoverall_logical_return\fP 1i +Returns the overall logical \*(Ov. +.LP +.eM +The +.PN XmbTextExtents +and +.PN XwcTextExtents +functions set the components of the specified overall_ink_return and +overall_logical_return +arguments to the overall bounding box of the string's image +and a logical bounding box for spacing purposes, respectively. +They return the value returned by +.PN XmbTextEscapement +or +.PN XwcTextEscapement . +These metrics are relative to the drawing origin of the string, +using the fonts loaded for the specified font set. +.LP +If the overall_ink_return argument is non-NULL, +it is set to the bounding box of the string's character ink. +The overall_ink_return for a nondescending, horizontally drawn +Latin character is conventionally entirely above the baseline; +that is, overall_ink_return.height <= \-overall_ink_return.y. +The overall_ink_return for a nonkerned character +is entirely at, and to the right of, the origin; +that is, overall_ink_return.x >= 0. +A character consisting of a single pixel at the origin would set +overall_ink_return fields y = 0, x = 0, width = 1, and height = 1. +.LP +If the overall_logical_return argument is non-NULL, +it is set to the bounding box that provides minimum spacing +to other graphical features for the string. +Other graphical features, for example, a border surrounding the text, +should not intersect this rectangle. +.LP +When the +.PN XFontSet +has missing charsets, +metrics for each unavailable character are taken +from the default string returned by +.PN XCreateFontSet +so that the metrics represent the text as it will actually be drawn. +The behavior for an invalid codepoint is undefined. +.LP +To determine the effective drawing origin for a character in a drawn string, +the client should call +.PN XmbTextPerCharExtents +on the entire string, then on the character, +and subtract the x values of the returned +rectangles for the character. +This is useful to redraw portions of a line of text +or to justify words, but for context-dependent rendering, +the client should not assume that it can redraw the character by itself +and get the same rendering. +.LP +.sp +To obtain per-character information for a text string, +use +.PN XmbTextPerCharExtents +or +.PN XwcTextPerCharExtents . +.IN "XmbTextPerCharExtents" "" "@DEF@" +.IN "XwcTextPerCharExtents" "" "@DEF@" +.sM +.FD 0 +Status XmbTextPerCharExtents\^(\^\fIfont_set\fP\^, \fIstring\fP\^, \fInum_bytes\fP\^, \fIink_array_return\fP\^, +.br + \fIlogical_array_return\fP\^, \fIarray_size\fP\^, \fInum_chars_return\fP\^, \fIoverall_ink_return\fP\^, \fIoverall_logical_return\fP\^) +.br + XFontSet \fIfont_set\fP\^; +.br + char *\fIstring\fP\^; +.br + int \fInum_bytes\fP\^; +.br + XRectangle *\fIink_array_return\fP\^; +.br + XRectangle *\fIlogical_array_return\fP\^; +.br + int \fIarray_size\fP\^; +.br + int *\fInum_chars_return\fP\^; +.br + XRectangle *\fIoverall_ink_return\fP\^; +.br + XRectangle *\fIoverall_logical_return\fP\^; +.FN +.FD 0 +Status XwcTextPerCharExtents\^(\^\fIfont_set\fP\^, \fIstring\fP\^, \fInum_wchars\fP\^, \fIink_array_return\fP\^, +.br + \fIlogical_array_return\fP\^, \fIarray_size\fP\^, \fInum_chars_return\fP\^, \fIoverall_ink_return\fP\^, \fIoverall_ink_return\fP\^) +.br + XFontSet \fIfont_set\fP\^; +.br + wchar_t *\fIstring\fP\^; +.br + int \fInum_wchars\fP\^; +.br + XRectangle *\fIink_array_return\fP\^; +.br + XRectangle *\fIlogical_array_return\fP; +.br + int \fIarray_size\fP\^; +.br + int *\fInum_chars_return\fP\^; +.br + XRectangle *\fIoverall_ink_return\fP\^; +.br + XRectangle *\fIoverall_logical_return\fP\^; +.FN +.IP \fIfont_set\fP 1i +Specifies the font set. +.IP \fIstring\fP 1i +Specifies the character string. +.IP \fInum_bytes\fP 1i +Specifies the number of bytes in the string argument. +.IP \fInum_wchars\fP 1i +Specifies the number of characters in the string argument. +.IP \fIink_array_return\fP 1i +Returns the ink dimensions for each character. +.IP \fIlogical_array_return\fP 1i +Returns the logical dimensions for each character. +.IP \fIarray_size\fP 1i +Specifies the size of ink_array_return and logical_array_return. +The caller must pass in arrays of this size. +.IP \fInum_chars_return\fP 1i +Returns the number of characters in the string argument. +.ds Ov extents of the entire string +.IP \fIoverall_ink_return\fP 1i +Returns the overall ink \*(Ov. +.IP \fIoverall_logical_return\fP 1i +Returns the overall logical \*(Ov. +.LP +.eM +The +.PN XmbTextPerCharExtents +and +.PN XwcTextPerCharExtents +functions return the text dimensions of each character of the specified text, +using the fonts loaded for the specified font set. +Each successive element of ink_array_return and logical_array_return +is set to the successive character's drawn metrics, +relative to the drawing origin of the string and one +rectangle +for each character in the supplied text string. +The number of elements of ink_array_return and logical_array_return +that have been set is returned to num_chars_return. +.LP +Each element of ink_array_return is set to the bounding box +of the corresponding character's drawn foreground color. +Each element of logical_array_return is set to the bounding box +that provides minimum spacing to other graphical features +for the corresponding character. +Other graphical features should not intersect any of the +logical_array_return rectangles. +.LP +Note that an +.PN XRectangle +represents the effective drawing dimensions of the character, +regardless of the number of font glyphs that are used to draw +the character or the direction in which the character is drawn. +If multiple characters map to a single character glyph, +the dimensions of all the +.PN XRectangles +of those characters are the same. +.LP +When the +.PN XFontSet +has missing charsets, metrics for each unavailable +character are taken from the default string returned by +.PN XCreateFontSet +so that the metrics represent the text as it will actually be drawn. +The behavior for an invalid codepoint is undefined. +.LP +If the array_size is too small for the number of characters in the +supplied text, the functions return zero +and num_chars_return is set to the number of rectangles required. +Otherwise, the functions return a nonzero value. +.LP +If the overall_ink_return or overall_logical_return argument is non-NULL, +.PN XmbTextPerCharExtents +and +.PN XwcTextPerCharExtents +return the maximum extent of the string's metrics to overall_ink_return +or overall_logical_return, as returned by +.PN XmbTextExtents +or +.PN XwcTextExtents . +.NH 3 +Drawing Text Using Font Sets +.XS +\*(SN Drawing Text Using Font Sets +.XE +.LP +The functions defined in this section +draw text at a specified location in a drawable. +They are similar to the functions +.PN XDrawText , +.PN XDrawString , +and +.PN XDrawImageString +except that they work with font sets instead of single fonts +and interpret the text based on the locale of the font set +instead of treating the bytes of the string as direct font indexes. +See section 8.6 for details of the use of Graphics Contexts (GCs) +and possible protocol errors. +If a +.PN BadFont +error is generated, +characters prior to the offending character may have been drawn. +.LP +The text is drawn using the fonts loaded for the specified font set; +the font in the GC is ignored and may be modified by the functions. +No validation that all fonts conform to some width rule is performed. +.LP +The text functions +.PN XmbDrawText +and +.PN XwcDrawText +use the following structures: +.LP +.IN "XmbTextItem" "" "@DEF@" +.sM +.Ds 0 +.TA .5i 2.5i +.ta .5i 2.5i +typedef struct { + char *chars; /* pointer to string */ + int nchars; /* number of bytes */ + int delta; /* pixel delta between strings */ + XFontSet font_set; /* fonts, None means don't change */ +} XmbTextItem; +.De +.LP +.IN "XwcTextItem" "" "@DEF@" +.Ds 0 +.TA .5i 2.5i +.ta .5i 2.5i +typedef struct { + wchar_t *chars; /* pointer to wide char string */ + int nchars; /* number of wide characters */ + int delta; /* pixel delta between strings */ + XFontSet font_set; /* fonts, None means don't change */ +} XwcTextItem; +.De +.LP +.eM +.sp +To draw text using multiple font sets in a given drawable, use +.PN XmbDrawText +or +.PN XwcDrawText . +.IN "XmbDrawText" "" "@DEF@" +.IN "XwcDrawText" "" "@DEF@" +.sM +.FD 0 +void XmbDrawText\^(\^\fIdisplay\fP\^, \fId\fP\^, \fIgc\fP\^, \fIx\fP\^, \fIy\fP\^, \fIitems\fP\^, \fInitems\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Drawable \fId\fP\^; +.br + GC \fIgc\fP\^; +.br + int \fIx\fP\^, \fIy\fP\^; +.br + XmbTextItem *\fIitems\fP\^; +.br + int \fInitems\fP\^; +.FN +.FD 0 +void XwcDrawText\^(\^\fIdisplay\fP\^, \fId\fP\^, \fIgc\fP\^, \fIx\fP\^, \fIy\fP\^, \fIitems\fP\^, \fInitems\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Drawable \fId\fP\^; +.br + GC \fIgc\fP\^; +.br + int \fIx\fP\^, \fIy\fP\^; +.br + XwcTextItem *\fIitems\fP\^; +.br + int \fInitems\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fId\fP 1i +Specifies the drawable. +.IP \fIgc\fP 1i +Specifies the GC. +.ds Xy +.IP \fIx\fP 1i +.br +.ns +.IP \fIy\fP 1i +Specify the x and y coordinates\*(Xy. +.IP \fIitems\fP 1i +Specifies an array of text items. +.IP \fInitems\fP 1i +Specifies the number of text items in the array. +.LP +.eM +The +.PN XmbDrawText +and +.PN XwcDrawText +functions allow complex spacing and font set shifts between text strings. +Each text item is processed in turn, with the origin of a text +element advanced in the primary draw direction by the escapement of the +previous text item. +A text item delta specifies an additional escapement of the text item +drawing origin in the primary draw direction. +A font_set member other than +.PN None +in an item causes the font set to be used for this and subsequent text items +in the text_items list. +Leading text items with a font_set member set to +.PN None +will not be drawn. +.LP +.PN XmbDrawText +and +.PN XwcDrawText +do not perform any context-dependent rendering between text segments. +Clients may compute the drawing metrics by passing each text segment to +.PN XmbTextExtents +and +.PN XwcTextExtents +or +.PN XmbTextPerCharExtents +and +.PN XwcTextPerCharExtents . +When the +.PN XFontSet +has missing charsets, each unavailable character is drawn +with the default string returned by +.PN XCreateFontSet . +The behavior for an invalid codepoint is undefined. +.LP +.sp +To draw text using a single font set in a given drawable, use +.PN XmbDrawString +or +.PN XwcDrawString . +.IN "XmbDrawString" "" "@DEF@" +.IN "XwcDrawString" "" "@DEF@" +.sM +.FD 0 +void XmbDrawString\^(\^\fIdisplay\fP\^, \fId\fP\^, \fIfont_set\fP\^, \fIgc\fP\^, \fIx\fP\^, \fIy\fP\^, \fIstring\fP\^, \fInum_bytes\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Drawable \fId\fP\^; +.br + XFontSet \fIfont_set\fP\^; +.br + GC \fIgc\fP\^; +.br + int \fIx\fP\^, \fIy\fP\^; +.br + char *\fIstring\fP\^; +.br + int \fInum_bytes\fP\^; +.FN +.FD 0 +void XwcDrawString\^(\^\fIdisplay\fP\^, \fId\fP\^, \fIfont_set\fP\^, \fIgc\fP\^, \fIx\fP\^, \fIy\fP\^, \fIstring\fP\^, \fInum_wchars\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Drawable \fId\fP\^; +.br + XFontSet \fIfont_set\fP\^; +.br + GC \fIgc\fP\^; +.br + int \fIx\fP\^, \fIy\fP\^; +.br + wchar_t *\fIstring\fP\^; +.br + int \fInum_wchars\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fId\fP 1i +Specifies the drawable. +.IP \fIfont_set\fP 1i +Specifies the font set. +.IP \fIgc\fP 1i +Specifies the GC. +.ds Xy +.IP \fIx\fP 1i +.br +.ns +.IP \fIy\fP 1i +Specify the x and y coordinates\*(Xy. +.IP \fIstring\fP 1i +Specifies the character string. +.IP \fInum_bytes\fP 1i +Specifies the number of bytes in the string argument. +.IP \fInum_wchars\fP 1i +Specifies the number of characters in the string argument. +.LP +.eM +The +.PN XmbDrawString +and +.PN XwcDrawString +functions draw the specified text with the foreground pixel. +When the +.PN XFontSet +has missing charsets, each unavailable character is drawn +with the default string returned by +.PN XCreateFontSet . +The behavior for an invalid codepoint is undefined. +.LP +.sp +To draw image text using a single font set in a given drawable, use +.PN XmbDrawImageString +or +.PN XwcDrawImageString . +.IN "XmbDrawImageString" "" "@DEF@" +.IN "XwcDrawImageString" "" "@DEF@" +.sM +.FD 0 +void XmbDrawImageString\^(\^\fIdisplay\fP\^, \fId\fP\^, \fIfont_set\fP\^, \fIgc\fP\^, \fIx\fP\^, \fIy\fP\^, \fIstring\fP\^, \fInum_bytes\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Drawable \fId\fP\^; +.br + XFontSet \fIfont_set\fP\^; +.br + GC \fIgc\fP\^; +.br + int \fIx\fP\^, \fIy\fP\^; +.br + char *\fIstring\fP\^; +.br + int \fInum_bytes\fP\^; +.FN +.FD 0 +void XwcDrawImageString\^(\^\fIdisplay\fP\^, \fId\fP\^, \fIfont_set\fP\^, \fIgc\fP\^, \fIx\fP\^, \fIy\fP\^, \fIstring\fP\^, \fInum_wchars\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Drawable \fId\fP\^; +.br + XFontSet \fIfont_set\fP\^; +.br + GC \fIgc\fP\^; +.br + int \fIx\fP\^, \fIy\fP\^; +.br + wchar_t *\fIstring\fP\^; +.br + int \fInum_wchars\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fId\fP 1i +Specifies the drawable. +.IP \fIfont_set\fP 1i +Specifies the font set. +.IP \fIgc\fP 1i +Specifies the GC. +.ds Xy +.IP \fIx\fP 1i +.br +.ns +.IP \fIy\fP 1i +Specify the x and y coordinates\*(Xy. +.IP \fIstring\fP 1i +Specifies the character string. +.IP \fInum_bytes\fP 1i +Specifies the number of bytes in the string argument. +.IP \fInum_wchars\fP 1i +Specifies the number of characters in the string argument. +.LP +.eM +The +.PN XmbDrawImageString +and +.PN XwcDrawImageString +functions fill a destination rectangle with the background pixel defined +in the GC and then paint the text with the foreground pixel. +The filled rectangle is the rectangle returned to overall_logical_return by +.PN XmbTextExtents +or +.PN XwcTextExtents +for the same text and +.PN XFontSet . +.LP +When the +.PN XFontSet +has missing charsets, each unavailable character is drawn +with the default string returned by +.PN XCreateFontSet . +The behavior for an invalid codepoint is undefined. +.NH 2 +Input Methods +.XS +\*(SN Input Methods +.XE +.LP +This section provides discussions of the following X Input Method +(XIM) topics: +.IP \(bu 5 +Input method overview +.IP \(bu 5 +Input method management +.IP \(bu 5 +Input method functions +.IP \(bu 5 +Input method values +.IP \(bu 5 +Input context functions +.IP \(bu 5 +Input context values +.IP \(bu 5 +Input method callback semantics +.IP \(bu 5 +Event filtering +.IP \(bu 5 +Getting keyboard input +.IP \(bu 5 +Input method conventions +.NH 3 +Input Method Overview +.XS +\*(SN Input Method Overview +.XE +.LP +This section provides definitions for terms and concepts used +for internationalized text input and a brief overview of the +intended use of the mechanisms provided by Xlib. +.LP +A large number of languages in the world use alphabets +consisting of a small set of symbols (letters) to form words. +To enter text into a computer in an alphabetic language, +a user usually has a keyboard on which there exist key symbols corresponding +to the alphabet. +Sometimes, a few characters of an alphabetic language are missing +on the keyboard. +Many computer users who speak a Latin-alphabet-based language +only have an English-based keyboard. +They need to hit a combination of keystrokes +to enter a character that does not exist directly on the keyboard. +A number of algorithms have been developed for entering such characters. +These are known as European input methods, compose input methods, +or dead-key input methods. +.LP +Japanese is an example of a language with a phonetic symbol set, +where each symbol represents a specific sound. +There are two phonetic symbol sets in Japanese: Katakana and Hiragana. +In general, +Katakana is used for words that are of foreign origin, +and Hiragana is used for writing native Japanese words. +Collectively, the two systems are called Kana. +Each set consists of 48 characters. +.LP +Korean also has a phonetic symbol set, called Hangul. +Each of the 24 basic phonetic symbols (14 consonants and 10 vowels) +represents a specific sound. +A syllable is composed of two or three parts: +the initial consonants, the vowels, and the optional last consonants. +With Hangul, +syllables can be treated as the basic units on which text processing is done. +For example, +a delete operation may work on a phonetic symbol or a syllable. +Korean code sets include several thousands of these syllables. +A user types the phonetic symbols that make up the syllables of the words +to be entered. +The display may change as each phonetic symbol is entered. +For example, +when the second phonetic symbol of a syllable is entered, +the first phonetic symbol may change its shape and size. +Likewise, when the third phonetic symbol is entered, +the first two phonetic symbols may change their shape and size. +.LP +Not all languages rely solely on alphabetic or phonetic systems. +Some languages, including Japanese and Korean, employ an +ideographic writing system. +In an ideographic system, rather than taking a small set of +symbols and combining them in different ways to create words, +each word consists of one unique symbol (or, occasionally, several symbols). +The number of symbols can be very large: +approximately 50,000 have been identified in Hanzi, +the Chinese ideographic system. +.LP +Two major aspects of ideographic systems impact their use with computers. +First, the standard computer character sets in Japan, China, and Korea +include roughly 8,000 characters, +while sets in Taiwan have between 15,000 and 30,000 characters. +This makes it necessary to use more than one byte to represent a character. +Second, it obviously is impractical to have a keyboard that includes +all of a given language's ideographic symbols. +Therefore, a mechanism is required for entering characters +so that a keyboard with a reasonable number of keys can be used. +Those input methods are usually based on phonetics, +but there also exist methods based on the graphical properties of +characters. +.LP +In Japan, both Kana and the ideographic system Kanji are used. +In Korea, Hangul and sometimes the ideographic system Hanja are used. +Now consider entering ideographs in Japan, Korea, China, and Taiwan. +.LP +In Japan, either Kana or English characters are typed and then a region +is selected (sometimes automatically) for conversion to Kanji. +Several Kanji characters may have the same phonetic representation. +If that is the case with the string entered, +a menu of characters is presented and +the user must choose the appropriate one. +If no choice is necessary or a preference has been established, +the input method does the substitution directly. +When Latin characters are converted to Kana or Kanji, +it is called a romaji conversion. +.LP +In Korea, it is usually acceptable to keep Korean text in Hangul form, +but some people may choose to write Hanja-originated words in Hanja +rather than in Hangul. +To change Hangul to Hanja, +the user selects a region for conversion +and then follows the same basic method as that described for Japanese. +.LP +Probably because there are well-accepted phonetic writing systems +for Japanese and Korean, +computer input methods in these countries for entering ideographs +are fairly standard. +Keyboard keys have both English characters and phonetic symbols +engraved on them, and the user can switch between the two sets. +.LP +The situation is different for Chinese. +While there is a phonetic system called Pinyin promoted by authorities, +there is no consensus for entering Chinese text. +Some vendors use a phonetic decomposition (Pinyin or another), +others use ideographic decomposition of Chinese words, +with various implementations and keyboard layouts. +There are about 16 known methods, none of which is a clear standard. +.LP +Also, there are actually two ideographic sets used: +Traditional Chinese (the original written Chinese) +and Simplified Chinese. +Several years ago, +the People's Republic of China launched a campaign to simplify +some ideographic characters and eliminate redundancies altogether. +Under the plan, +characters would be streamlined every five years. +Characters have been revised several times now, +resulting in the smaller, simpler set that makes up Simplified Chinese. +.NH 4 +Input Method Architecture +.XS +\*(SN Input Method Architecture +.XE +.LP +As shown in the previous section, +there are many different input methods in use today, +each varying with language, culture, and history. +A common feature of many input methods is that the user may type +multiple keystrokes to compose a single character (or set +of characters). +The process of composing characters from keystrokes is called +\fIpreediting\fP. +It may require complex algorithms and large dictionaries +involving substantial computer resources. +.LP +Input methods may require one or more areas in which to show the +feedback of the actual keystrokes, to propose disambiguation to the +user, to list dictionaries, and so on. +The input method areas of concern are as follows: +.IP \(bu 5 +The \fIstatus\fP area is a logical extension of the +LEDs that exist on the physical keyboard. +It is a window that is intended to present the internal state +of the input method that is critical to the user. +The status area may consist of text data and bitmaps or some combination. +.IP \(bu 5 +The \fIpreedit\fP area displays the +intermediate text for those languages that are composing prior to +the client handling the data. +.IP \(bu 5 +The \fIauxiliary\fP area is used for pop-up menus and customizing +dialogs that may be required for an input method. +There may be multiple auxiliary areas for an input method. +Auxiliary areas are managed by the input method independent of the client. +Auxiliary areas are assumed to be separate dialogs, +which are maintained by the input method. +.LP +There are various user interaction styles used for preediting. +The ones supported by Xlib are as follows: +.IP \(bu 5 +For \fIon-the-spot\fP input methods, +preediting data will be displayed directly in the application window. +Application data is moved to allow preedit data to appear +at the point of insertion. +.IP \(bu 5 +\fIOver-the-spot\fP preediting means that the data is displayed in +a preedit window that is placed over the point of insertion. +.IP \(bu 5 +\fIOff-the-spot\fP preediting means that the preedit window is +inside the application window but not at the point of insertion. +Often, this type of window is placed at the bottom of the application window. +.IP \(bu 5 +\fIRoot-window\fP preediting refers to input methods that use a preedit +window that is the child of +.PN RootWindow . +.LP +It would require a lot of computing resources if portable applications +had to include input methods for all the languages in the world. +To avoid this, +a goal of the Xlib design is to allow an application +to communicate with an input method placed in a separate process. +Such a process is called an \fIinput server\fP. +The server to which the application should connect is dependent on +the environment when the application is started up, +that is, the user language and the actual encoding to be used for it. +The input method connection is said to be \fIlocale-dependent\fP. +It is also user-dependent. +For a given language, the user can choose, to some extent, +the user interface style of input method (if choice is possible among +several). +.LP +Using an input server implies communication overhead, +but applications can be migrated without relinking. +Input methods can be implemented either as a +stub communicating to an input server or as a local library. +.LP +An input method may be based on a \fIfront-end\fP or a \fIback-end\fP +architecture. +In a front-end architecture, +there are two separate connections to the X server: +keystrokes go directly from the X server to the input method on +one connection and other events to the regular client connection. +The input method is then acting as a filter and sends composed strings +to the client. +A front-end architecture requires synchronization between the +two connections to avoid lost key events or locking issues. +.LP +In a back-end architecture, +a single X server connection is used. +A dispatching mechanism must decide on this channel to delegate appropriate +keystrokes to the input method. +For instance, +it may retain a Help keystroke for its own purpose. +In the case where the input method is a separate process (that is, a server), +there must be a special communication protocol between the back-end client +and the input server. +.LP +A front-end architecture introduces synchronization issues +and a filtering mechanism for noncharacter keystrokes +(Function keys, Help, and so on). +A back-end architecture sometimes implies more communication overhead +and more process switching. +If all three processes (X server, input server, client) +are running on a single workstation, +there are two process switches for each keystroke in a back-end +architecture, +but there is only one in a front-end architecture. +.LP +The abstraction used by a client to communicate with an input method +is an opaque data structure represented by the +.PN XIM +data type. +This data structure is returned by the +.PN XOpenIM +function, which opens an input method on a given display. +Subsequent operations on this data structure encapsulate all communication +between client and input method. +There is no need for an X client to use any networking library +or natural language package to use an input method. +.LP +A single input server may be used for one or more languages, +supporting one or more encoding schemes. +But the strings returned from an input method will always be encoded +in the (single) locale associated with the +.PN XIM +object. +.NH 4 +Input Contexts +.XS +\*(SN Input Contexts +.XE +.LP +Xlib provides the ability to manage a multi-threaded state for text input. +A client may be using multiple windows, +each window with multiple text entry areas, +and the user possibly switching among them at any time. +The abstraction for representing the state of a particular input thread +is called an \fIinput context\fP. +The Xlib representation of an input context is an +.PN XIC . +.LP +An input context is the abstraction retaining the state, properties, +and semantics of communication between a client and an input method. +An input context is a combination of an input method, a locale +specifying the encoding of the character strings to be returned, +a client window, internal state information, +and various layout or appearance characteristics. +The input context concept somewhat matches for input the graphics context +abstraction defined for graphics output. +.LP +One input context belongs to exactly one input method. +Different input contexts may be associated with the same input method, +possibly with the same client window. +An +.PN XIC +is created with the +.PN XCreateIC +function, providing an +.PN XIM +argument and affiliating the input context to the input method +for its lifetime. +When an input method is closed with +.PN XCloseIM , +all of its affiliated input contexts should not be used any more +(and should preferably be destroyed before closing the input method). +.LP +Considering the example of a client window with multiple text entry areas, +the application programmer could, for example, choose to implement as follows: +.IP \(bu 5 +As many input contexts are created as text entry areas, and the client +will get the input accumulated on each context each time it looks up +in that context. +.IP \(bu 5 +A single context is created for a top-level window in the application. +If such a window contains several text entry areas, +each time the user moves to another text entry area, +the client has to indicate changes in the context. +.LP +A range of choices can be made by application designers to use +either a single or multiple input contexts, +according to the needs of their application. +.NH 4 +Getting Keyboard Input +.XS +\*(SN Getting Keyboard Input +.XE +.LP +To obtain characters from an input method, +a client must call the function +.PN XmbLookupString +or +.PN XwcLookupString +with an input context created from that input method. +Both a locale and display are bound to an input method when it is opened, +and an input context inherits this locale and display. +Any strings returned by +.PN XmbLookupString +or +.PN XwcLookupString +will be encoded in that locale. +.NH 4 +Focus Management +.XS +\*(SN Focus Management +.XE +.LP +For each text entry area in which the +.PN XmbLookupString +or +.PN XwcLookupString +functions are used, +there will be an associated input context. +.LP +When the application focus moves to a text entry area, +the application must set the input context focus to the +input context associated with that area. +The input context focus is set by calling +.PN XSetICFocus +with the appropriate input context. +.LP +Also, when the application focus moves out of a text entry area, the +application should unset the focus for the associated input context +by calling +.PN XUnsetICFocus . +As an optimization, if +.PN XSetICFocus +is called successively on two different input contexts, +setting the focus on the second +will automatically unset the focus on the first. +.LP +To set and unset the input context focus correctly, +it is necessary to track application-level focus changes. +Such focus changes do not necessarily correspond to X server focus changes. +.LP +If a single input context +is being used to do input for +multiple text entry areas, it will also be necessary +to set the focus window of the +input context whenever the focus window changes +(see section 13.5.6.3). +.NH 4 +Geometry Management +.XS +\*(SN Geometry Management +.XE +.LP +In most input method architectures +(on-the-spot being the notable exception), +the input method will perform the display of its own data. +To provide better visual locality, +it is often desirable to have the input method areas embedded within a client. +To do this, +the client may need to allocate space for an input method. +Xlib provides support that allows the size and position of input method +areas to be provided by a client. +The input method areas that are supported for geometry management +are the status area and the preedit area. +.LP +The fundamental concept on which geometry management for input method windows +is based is the proper division of responsibilities between the +client (or toolkit) and the input method. +The division of responsibilities is as follows: +.IP \(bu 5 +The client is responsible for the geometry of the input method window. +.IP \(bu 5 +The input method is responsible for the contents of the input method window. +.LP +An input method is able to suggest a size to the client, +but it cannot suggest a placement. +Also the input method can only suggest a size. +It does not determine the size, +and it must accept the size it is given. +.LP +Before a client provides geometry management for an input method, +it must determine if geometry management is needed. +The input method indicates the need for geometry management +by setting +.PN XIMPreeditArea +or +.PN XIMStatusArea +in its +.PN XIMStyles +value returned by +.PN XGetIMValues . +When a client has decided that it will provide geometry management +for an input method, +it indicates that decision by setting the +.PN XNInputStyle +value in the +.PN XIC . +.LP +After a client has established with the input method +that it will do geometry management, +the client must negotiate the geometry with the input method. +The geometry is negotiated by the following steps: +.IP \(bu 5 +The client suggests an area to the input method by setting the +.PN XNAreaNeeded +value for that area. +If the client has no constraints for the input method, +it either will not suggest an area or will set the width and height to zero. +Otherwise, it will set one of the values. +.IP \(bu 5 +The client will get the XIC value +.PN XNAreaNeeded . +The input method will return its suggested size in this value. +The input method should pay attention to any constraints suggested +by the client. +.IP \(bu 5 +The client sets the XIC value +.PN XNArea +to inform the input method of the geometry of its window. +The client should try to honor the geometry requested by the input method. +The input method must accept this geometry. +.LP +Clients doing geometry management must be aware that setting other +XIC values may affect the geometry desired by an input method. +For example, +.PN XNFontSet +and +.PN XNLineSpacing +may change the geometry desired by the input method. +.LP +The table of XIC values (see section 13.5.6) +indicates the values that can cause the desired geometry to change +when they are set. +It is the responsibility of the client to renegotiate the geometry +of the input method window when it is needed. +.LP +In addition, +a geometry management callback is provided +by which an input method can initiate a geometry change. +.NH 4 +Event Filtering +.XS +\*(SN Event Filtering +.XE +.LP +A filtering mechanism is provided to allow input methods +to capture X events transparently to clients. +It is expected that toolkits (or clients) using +.PN XmbLookupString +or +.PN XwcLookupString +will call this filter at some point in the event processing mechanism +to make sure that events needed by an input method can be filtered +by that input method. +.LP +If there were no filter, +a client could receive and discard events that are necessary +for the proper functioning of an input method. +The following provides a few examples of such events: +.IP \(bu 5 +Expose events on preedit window in local mode. +.IP \(bu 5 +Events may be used by an input method to communicate with an input server. +Such input server protocol-related events have to be intercepted +if one does not want to disturb client code. +.IP \(bu 5 +Key events can be sent to a filter before they are bound +to translations such as those the X Toolkit Intrinsics library provides. +.LP +Clients are expected to get the XIC value +.PN XNFilterEvents +and augment the event mask for the client window with that event mask. +This mask may be zero. +.NH 4 +Callbacks +.XS +\*(SN Callbacks +.XE +.LP +When an on-the-spot input method is implemented, +only the client can insert or delete preedit data in place +and possibly scroll existing text. +This means that the echo of the keystrokes has to be achieved +by the client itself, tightly coupled with the input method logic. +.LP +When the user enters a keystroke, +the client calls +.PN XmbLookupString +or +.PN XwcLookupString . +At this point, in the on-the-spot case, +the echo of the keystroke in the preedit has not yet been done. +Before returning to the client logic that handles the input characters, +the look-up function +must call the echoing logic to insert the new keystroke. +If the keystrokes entered so far make up a character, +the keystrokes entered need to be deleted, +and the composed character will be returned. +Hence, what happens is that, while being called by client code, +the input method logic has to call back to the client before it returns. +The client code, that is, a callback procedure, +is called from the input method logic. +.LP +There are a number of cases where the input method logic has to +call back the client. +Each of those cases is associated with a well-defined callback action. +It is possible for the client to specify, for each input context, +what callback is to be called for each action. +.LP +There are also callbacks provided for feedback of status information +and a callback to initiate a geometry request for an input method. +.NH 4 +Visible Position Feedback Masks +.XS +\*(SN Visible Position Feedback Masks +.XE +.LP +In the on-the-spot input style, there is a problem when +attempting to draw preedit strings that are longer than the +available space. Once the display area is exceeded, it is not +clear how best to display the preedit string. +The visible position feedback masks of +.PN XIMText +help resolve this problem by allowing the input method to specify hints that +indicate the essential portions of the preedit string. +For example, such hints can help developers implement +scrolling of a long preedit string within a short preedit display area. +.NH 4 +Preedit String Management +.XS +\*(SN Preedit String Management +.XE +.LP +As highlighted before, the input method architecture provides +preediting, which supports a type of preprocessor input composition. +In this case, composition consists of interpreting a sequence +of key events and returning a committed string via +.PN XmbLookupString +or +.PN XwcLookupString . +This provides the basics for input methods. +.LP +In addition to preediting based on key events, a general framework +is provided to give a client that desires it more advanced preediting based +on the text within the client. This framework is called +\fIstring conversion\fP and is provided using XIC values. +The fundamental concept of string conversion +is to allow the input method to manipulate the client's +text independent of any user preediting operation. +.LP +The need for string conversion is based on +language needs and input method capabilities. +The following are some examples of string conversion: +.IP \(bu 5 +Transliteration conversion provides language-specific conversions +within the input method. +In the case of Korean input, users wish to convert a Hangul string +into a Hanja string while in preediting, after preediting, +or in other situations (for example, on a selected string). +The conversion is triggered when the user +presses a Hangul-to-Hanja key sequence (which may be input method specific). +Sometimes the user may want to invoke the conversion after finishing +preediting or on a user-selected string. +Thus, the string to be converted is in an application buffer, not in +the preedit area of the input method. The string conversion services +allow the client to request this transliteration conversion from the +input method. +There are many other transliteration conversions defined for +various languages, for example, Kana-to-Kanji conversion in Japanese. +.sp +The key to remember is that transliteration conversions are triggered +at the request of the user and returned to the client +immediately without affecting the preedit area of the input method. +.IP \(bu 5 +Reconversion of a previously committed string or +a selected string is supported by many input methods as a +convenience to the user. +For example, a user tends to mistype the commit key while +preediting. In that case, some input methods provide a special +key sequence to request a ``reconvert'' operation on the +committed string, similiar to the undo facility provided by most +text editors. +Another example is where the user is proofreading a document +that has some misconversions from preediting and wants to correct +the misconverted text. Such reconversion is again triggered +by the user invoking some special action, but reconversions should +not affect the state of the preedit area. +.IP \(bu 5 +Context-sensitive conversion is required for some languages +and input methods that need to retrieve text that surrounds the +current spot location (cursor position) of the client's buffer. +Such text is needed when the preediting operation depends on +some surrounding characters (usually preceding the spot location). +For example, +in Thai language input, certain character sequences may be invalid and +the input method may want to check whether characters constitute a +valid word. Input methods that do such context-dependent +checking need to retrieve the characters surrounding the current +cursor position to obtain complete words. +.sp +Unlike other conversions, this conversion is not explicitly +requested by the user. +Input methods that provide such context-sensitive conversion +continuously need to request context from the client, and any change +in the context of the spot location may affect such conversions. +The client's context would be needed if the user moves the cursor +and starts editing again. +.sp +For this reason, an input method supporting this type of conversion +should take notice of when the client calls +.PN XmbResetIC +or +.PN XwcResetIC , +which is usually an indication of a context change. +.LP +Context-sensitive conversions just need a copy of the client's text, +while other conversions replace the client's text with new text +to achieve the reconversion or transliteration. Yet in all +cases the result of a conversion, either immediately or via preediting, +is returned by the +.PN XmbLookupString +and +.PN XwcLookupString +functions. +.LP +String conversion support is dependent on the availability of the +.PN XNStringConversion +or +.PN XNStringConversionCallback +XIC values. +Because the input method may not support string conversions, +clients have to query the availability of string conversion +operations by checking the supported XIC values list by calling +.PN XGetIMValues +with the +.PN XNQueryICValuesList +IM value. +.LP +The difference between these two values is whether the +conversion is invoked by the client or the input method. +The +.PN XNStringConversion +XIC value is used by clients to request +a string conversion from the input method. The client +is responsible for determining which events are used +to trigger the string conversion and whether the string to be +converted should be copied or deleted. The type of conversion +is determined by the input method; the client can only +pass the string to be converted. The client is guaranteed that +no +.PN XNStringConversionCallback +will be issued when this value is set; thus, the client need +only set one of these values. +.LP +The +.PN XNStringConversionCallback +XIC value is used by the client to notify the input method that +it will accept requests from the input method for string conversion. +If this value is set, +it is the input method's responsibility to determine which +events are used to trigger the string conversion. +When such events occur, the input method issues a call to the +client-supplied procedure to retrieve the string to be converted. The client's +callback procedure is notified whether to copy or delete the string and +is provided with hints as to the amount of text needed. +The +.PN XIMStringConversionCallbackStruct +specifies which text should be passed back to the input method. +.LP +Finally, the input method may call the client's +.PN XNStringConversionCallback +procedure multiple times if the string returned from the callback is +not sufficient to perform a successful conversion. The arguments +to the client's procedure allow the input method to define a +position (in character units) relative to the client's cursor position +and the size of the text needed. By varying the position and size of +the desired text in subsequent callbacks, the input method can retrieve +additional text. +.LP +.NH 3 +Input Method Management +.XS +\*(SN Input Method Management +.XE +.LP +The interface to input methods might appear to be simply creating +an input method +.Pn ( XOpenIM ) +and freeing an input method +.Pn ( XCloseIM ). +However, input methods may +require complex communication with input method servers (IM servers), +for example: +.IP \(bu 5 +If the X server, IM server, and X clients are started asynchronously, +some clients may attempt to connect to the IM server before it is +fully operational, and fail. +Therefore, some mechanism is needed to allow clients to detect when an IM +server has started. +.LP +It is up to clients to decide what should be done when an IM server is +not available (for example, wait, or use some other IM server). +.LP +.IP \(bu 5 +Some input methods may allow the underlying IM server to be switched. +Such customization may be desired without restarting the entire client. +.LP +To support management of input methods in these cases, the following +functions are provided: +.TS +lw(2.4i) lw(3.3i). +T{ +.PN XRegisterIMInstantiateCallback +T} T{ +This function allows clients to register a callback procedure +to be called when Xlib detects that an IM server is up and available. +T} +T{ +.PN XOpenIM +T} T{ +A client calls this function as a result of the callback procedure +being called. +T} +T{ +.PN XSetIMValue , +.PN XSetICValue +T} T{ +These functions use the XIM and XIC values, +.PN XNDestroyCallback , +to allow a client +to register a callback procedure to be called when Xlib detects that +an IM server that was associated with an opened +input method is no longer available. +.sp 4p +In addition, this function can be used to switch IM servers for those input +methods that support such functionality. The IM value for switching IM +servers is implementation-dependent; see the description below about +switching IM servers. +T} +T{ +.PN XUnregisterIMInstantiateCallback +T} T{ +This function removes a callback procedure registered by the client. +T} +.TE +.LP +Input methods that support switching of IM servers may exhibit some +side-effects: +.IP \(bu 5 +The input method will ensure that any new IM server supports any of the +input styles being used by input contexts already associated with the +input method. +However, the list of supported input styles may be different. +.LP +.IP \(bu 5 +Geometry management requests on previously created input contexts +may be initiated by the new IM server. +.LP +.NH 4 +Hot Keys +.XS +\*(SN Hot Keys +.XE +.LP +Some clients need to guarantee which keys can be used to escape from the +input method, regardless of the input method state; +for example, the client-specific Help key or the keys to move the +input focus. +The HotKey mechanism allows clients +to specify a set of keys for this purpose. However, the input +method might not allow clients to specify hot keys. +Therefore, clients have to query support of hot keys by checking the +supported XIC values list by calling +.PN XGetIMValues +with the +.PN XNQueryICValuesList +IM value. +When the hot keys specified conflict with the key bindings of the +input method, hot keys take precedence over the key bindings of the input +method. +.LP +.NH 4 +Preedit State Operation +.XS +\*(SN Preedit State Operation +.XE +.LP +An input method may have several internal states, depending on its +implementation and the locale. However, one state that is +independent of locale and implementation is whether the input method +is currently performing a preediting operation. +Xlib provides the ability for an application to manage the preedit state +programmatically. Two methods are provided for +retrieving the preedit state of an input context. +One method is to query the state by calling +.PN XGetICValues +with the +.PN XNPreeditState +XIC value. +Another method is to receive notification whenever +the preedit state is changed. To receive such notification, +an application needs to register a callback by calling +.PN XSetICValues +with the +.PN XNPreeditStateNotifyCallback +XIC value. +In order to change the preedit state programmatically, an application +needs to call +.PN XSetICValues +with +.PN XNPreeditState. +.LP +Availability of the preedit state is input method dependent. The input +method may not provide the ability to set the state or to +retrieve the state programmatically. Therefore, clients have to +query availability of preedit state operations by checking the +supported XIC values list by calling +.PN XGetIMValues +with the +.PN XNQueryICValuesList +IM value. +.NH 3 +Input Method Functions +.XS +\*(SN Input Method Functions +.XE +.LP +To open a connection, use +.PN XOpenIM . +.IN "XOpenIM" "" "@DEF@" +.sM +.FD 0 +XIM XOpenIM\^(\^\fIdisplay\fP\^, \fIdb\fP\^, \fIres_name\fP\^, \fIres_class\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + XrmDatabase \fIdb\fP\^; +.br + char *\fIres_name\fP\^; +.br + char *\fIres_class\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIdb\fP 1i +Specifies a pointer to the resource database. +.IP \fIres_name\fP 1i +Specifies the full resource name of the application. +.IP \fIres_class\fP 1i +Specifies the full class name of the application. +.LP +.eM +The +.PN XOpenIM +function opens an input method, +matching the current locale and modifiers specification. +Current locale and modifiers are bound to the input method at opening time. +The locale associated with an input method cannot be changed dynamically. +This implies that the strings returned by +.PN XmbLookupString +or +.PN XwcLookupString , +for any input context affiliated with a given input method, +will be encoded in the locale current at the time the input method is opened. +.LP +The specific input method to which this call will be routed +is identified on the basis of the current locale. +.PN XOpenIM +will identify a default input method corresponding to the +current locale. +That default can be modified using +.PN XSetLocaleModifiers +for the input method modifier. +.LP +The db argument is the resource database to be used by the input method +for looking up resources that are private to the input method. +It is not intended that this database be used to look +up values that can be set as IC values in an input context. +If db is NULL, +no database is passed to the input method. +.LP +The res_name and res_class arguments specify the resource name +and class of the application. +They are intended to be used as prefixes by the input method +when looking up resources that are common to all input contexts +that may be created for this input method. +The characters used for resource names and classes must be in the +X Portable Character Set. +The resources looked up are not fully specified +if res_name or res_class is NULL. +.LP +The res_name and res_class arguments are not assumed to exist beyond +the call to +.PN XOpenIM . +The specified resource database is assumed to exist for the lifetime +of the input method. +.LP +.PN XOpenIM +returns NULL if no input method could be opened. +.LP +.sp +To close a connection, use +.PN XCloseIM . +.IN "XCloseIM" "" "@DEF@" +.sM +.FD 0 +Status XCloseIM\^(\^\fIim\fP\^) +.br + XIM \fIim\fP\^; +.FN +.IP \fIim\fP 1i +Specifies the input method. +.LP +.eM +The +.PN XCloseIM +function closes the specified input method. +.LP +.sp +To set input method attributes, use +.PN XSetIMValues . +.IN "XSetIMValues" "" "@DEF@" +.sM +.FD 0 +char * XSetIMValues\^(\^\fIim\fP\^, ...) +.br + XIM \fIim\fP\^; +.FN +.IP \fIim\fP 1i +Specifies the input method. +.ds Al \ to set XIM values +.IP ... 1i +Specifies the variable-length argument list\*(Al. +.LP +.eM +The +.PN XSetIMValues +function presents a variable argument list programming interface +for setting attributes of the specified input method. +It returns NULL if it succeeds; +otherwise, +it returns the name of the first argument that could not be set. +Xlib does not attempt to set arguments from the supplied list that +follow the failed argument; +all arguments in the list preceding the failed argument have been set +correctly. +.LP +.sp +To query an input method, use +.PN XGetIMValues . +.IN "XGetIMValues" "" "@DEF@" +.sM +.FD 0 +char * XGetIMValues\^(\^\fIim\fP\^, ...) +.br + XIM \fIim\fP\^; +.FN +.IP \fIim\fP 1i +Specifies the input method. +.ds Al \ to get XIM values +.IP ... 1i +Specifies the variable length argument list\*(Al. +.LP +.eM +The +.PN XGetIMValues +function presents a variable argument list programming interface +for querying properties or features of the specified input method. +This function returns NULL if it succeeds; +otherwise, +it returns the name of the first argument that could not be obtained. +.LP +Each XIM value argument (following a name) must point to +a location where the XIM value is to be stored. +That is, if the XIM value is of type T, +the argument must be of type T*. +If T itself is a pointer type, +then +.PN XGetIMValues +allocates memory to store the actual data, +and the client is responsible for freeing this data by calling +.PN XFree +with the returned pointer. +.LP +.sp +To obtain the display associated with an input method, use +.PN XDisplayOfIM . +.IN "XDisplayOfIM" "" "@DEF@" +.sM +.FD 0 +Display * XDisplayOfIM\^(\^\fIim\fP\^) +.br + XIM \fIim\fP\^; +.FN +.IP \fIim\fP 1i +Specifies the input method. +.LP +.eM +The +.PN XDisplayOfIM +function returns the display associated with the specified input method. +.LP +.sp +To get the locale associated with an input method, use +.PN XLocaleOfIM . +.IN "XLocaleOfIM" "" "@DEF@" +.sM +.FD 0 +char * XLocaleOfIM\^(\^\fIim\fP\^) +.br + XIM \fIim\fP\^; +.FN +.IP \fIim\fP 1i +Specifies the input method. +.LP +.eM +The +.PN XLocaleOfIM +function returns the locale associated with the specified input method. +.LP +.sp +To register an input method instantiate callback, use +.PN XRegisterIMInstantiateCallback . +.IN "XRegisterIMInstantiateCallback" "" "@DEF@" +.sM +.FD 0 +Bool XRegisterIMInstantiateCallback\^(\^\fIdisplay\fP\^, \fIdb\fP\^, \fIres_name\fP\^, \fIres_class\fP\^, \fIcallback\fP\^, \fIclient_data\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + XrmDatabase \fIdb\fP\^; +.br + char *\fIres_name\fP\^; +.br + char *\fIres_class\fP\^; +.br + XIMProc \fIcallback\fP\^; +.br + XPointer *\fIclient_data\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIdb\fP 1i +Specifies a pointer to the resource database. +.IP \fIres_name\fP 1i +Specifies the full resource name of the application. +.IP \fIres_class\fP 1i +Specifies the full class name of the application. +.IP \fIcallback\fP 1i +Specifies a pointer to the input method instantiate callback. +.IP \fIclient_data\fP 1i +Specifies the additional client data. +.LP +.eM +The +.PN XRegisterIMInstantiateCallback +function registers a callback to be invoked whenever a new input method +becomes available for the specified display that matches the current +locale and modifiers. +.LP +The function returns +.PN True + if it succeeds; otherwise, it returns +.PN False . +.LP +The generic prototype is as follows: +.IN "IMInstantiateCallback" "" "@DEF@" +.sM +.FD 0 +void IMInstantiateCallback\^(\^\fIdisplay\fP\^, \fIclient_data\fP\^, \fIcall_data\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + XPointer \fIclient_data\fP\^; +.br + XPointer \fIcall_data\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIclient_data\fP 1i +Specifies the additional client data. +.IP \fIcall_data\fP 1i +Not used for this callback and always passed as NULL. +.LP +.eM +To unregister an input method instantiation callback, use +.PN XUnregisterIMInstantiateCallback . +.IN "XUnregisterIMInstantiateCallback" "" "@DEF@" +.sM +.FD 0 +Bool XUnregisterIMInstantiateCallback\^(\^\fIdisplay\fP\^, \fIdb\fP\^, \fIres_name\fP\^, \fIres_class\fP\^, \fIcallback\fP\^, \fIclient_data\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + XrmDatabase \fIdb\fP\^; +.br + char *\fIres_name\fP\^; +.br + char *\fIres_class\fP\^; +.br + XIMProc \fIcallback\fP\^; +.br + XPointer *\fIclient_data\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIdb\fP 1i +Specifies a pointer to the resource database. +.IP \fIres_name\fP 1i +Specifies the full resource name of the application. +.IP \fIres_class\fP 1i +Specifies the full class name of the application. +.IP \fIcallback\fP 1i +Specifies a pointer to the input method instantiate callback. +.IP \fIclient_data\fP 1i +Specifies the additional client data. +.LP +.eM +The +.PN XUnregisterIMInstantiateCallback +function removes an input method instantiation callback previously +registered. +The function returns +.PN True +if it succeeds; otherwise, it returns +.PN False . +.NH 3 +Input Method Values +.XS +\*(SN Input Method Values +.XE +.LP +The following table describes how XIM values are interpreted +by an input method. +The first column lists the XIM values. +The second column indicates how each of the XIM values +are treated by that input style. +.LP +.LP +The following keys apply to this table. +.TS H +lw(1i) lw(4.75i). +_ +.sp 6p +.B +Key Explanation +.sp 6p +_ +.TH +.R +D T{ +This value may be set using +.PN XSetIMValues . +If it is not set, +.br +a default is provided. +T} +S T{ +This value may be set using +.PN XSetIMValues . +T} +G T{ +This value may be read using +.PN XGetIMValues . +T} +.sp 6p +_ +.TE +.LP +.TS H +lw(2.25i) c +lw(2.25i) c. +_ +.sp 6p +.B +XIM Value Key +.sp 6p +_ +.sp 6p +.TH +.R +T{ +.PN XNQueryInputStyle +T} T{ +G +T} +T{ +.PN XNResourceName +T} T{ +D-S-G +T} +T{ +.PN XNResourceClass +T} T{ +D-S-G +T} +T{ +.PN XNDestroyCallback +T} T{ +D-S-G +T} +T{ +.PN XNQueryIMValuesList +T} T{ +G +T} +T{ +.PN XNQueryICValuesList +T} T{ +G +T} +T{ +.PN XNVisiblePosition +T} T{ +G +T} +T{ +.PN XNR6PreeditCallbackBehavior +T} T{ +D-S-G +T} +.sp 6p +_ +.TE +.LP +.PN XNR6PreeditCallbackBehavior +is obsolete and its use is not recommended (see section 13.5.4.6). +.LP +.NH 4 +Query Input Style +.XS +\*(SN Query Input Style +.XE +.LP +A client should always query the input method to determine which input +styles are supported. +The client should then find an input style it is capable of supporting. +.LP +If the client cannot find an input style that it can support, +it should negotiate with the user the continuation of the program +(exit, choose another input method, and so on). +.LP +The argument value must be a pointer to a location +where the returned value will be stored. +The returned value is a pointer to a structure of type +.PN XIMStyles . +Clients are responsible for freeing the +.PN XIMStyles +structure. +To do so, use +.PN XFree . +.LP +The +.PN XIMStyles +structure is defined as follows: +.LP +.IN "XIMStyle" "" "@DEF@" +.IN "XIMPreeditArea" "" "@DEF@" +.IN "XIMPreeditCallbacks" "" "@DEF@" +.IN "XIMPreeditPosition" "" "@DEF@" +.IN "XIMPreeditNothing" "" "@DEF@" +.IN "XIMPreeditNone" "" "@DEF@" +.IN "XIMStatusArea" "" "@DEF@" +.IN "XIMStatusCallbacks" "" "@DEF@" +.IN "XIMStatusNothing" "" "@DEF@" +.IN "XIMStatusNone" "" "@DEF@" +.IN "XIMStyles" "" "@DEF@" +.sM +.Ds 0 +typedef unsigned long XIMStyle; +.De +.TS +lw(.5i) lw(2i) lw(2.5i). +T{ +#define +T} T{ +.PN XIMPreeditArea +T} T{ +0x0001L +T} +T{ +#define +T} T{ +.PN XIMPreeditCallbacks +T} T{ +0x0002L +T} +T{ +#define +T} T{ +.PN XIMPreeditPosition +T} T{ +0x0004L +T} +T{ +#define +T} T{ +.PN XIMPreeditNothing +T} T{ +0x0008L +T} +T{ +#define +T} T{ +.PN XIMPreeditNone +T} T{ +0x0010L +T} +.sp +T{ +#define +T} T{ +.PN XIMStatusArea +T} T{ +0x0100L +T} +T{ +#define +T} T{ +.PN XIMStatusCallbacks +T} T{ +0x0200L +T} +T{ +#define +T} T{ +.PN XIMStatusNothing +T} T{ +0x0400L +T} +T{ +#define +T} T{ +.PN XIMStatusNone +T} T{ +0x0800L +T} +.TE +.Ds 0 +.TA .5i 2.5i +.ta .5i 2.5i +typedef struct { + unsigned short count_styles; + XIMStyle * supported_styles; +} XIMStyles; +.De +.LP +.eM +An +.PN XIMStyles +structure contains the number of input styles supported +in its count_styles field. +This is also the size of the supported_styles array. +.LP +The supported styles is a list of bitmask combinations, +which indicate the combination of styles for each of the areas supported. +These areas are described later. +Each element in the list should select one of the bitmask values for +each area. +The list describes the complete set of combinations supported. +Only these combinations are supported by the input method. +.LP +The preedit category defines what type of support is provided +by the input method for preedit information. +.IN "XIMPreeditArea" "" "@DEF@" +.IN "XIMPreeditPosition" "" "@DEF@" +.IN "XIMPreeditCallbacks" "" "@DEF@" +.IN "XIMPreeditNothing" "" "@DEF@" +.IN "XIMPreeditNone" "" "@DEF@" +.TS +lw(1.5i) lw(4.25i). +T{ +.PN XIMPreeditArea +T} T{ +If chosen, +the input method would require the client to provide some area values +for it to do its preediting. +Refer to XIC values +.PN XNArea +and +.PN XNAreaNeeded . +T} +T{ +.PN XIMPreeditPosition +T} T{ +If chosen, +the input method would require the client to provide positional values. +Refer to XIC values +.PN XNSpotLocation +and +.PN XNFocusWindow . +T} +T{ +.PN XIMPreeditCallbacks +T} T{ +If chosen, +the input method would require the client to define the set of preedit callbacks. +Refer to XIC values +.PN XNPreeditStartCallback , +.PN XNPreeditDoneCallback , +.PN XNPreeditDrawCallback , +and +.PN XNPreeditCaretCallback . +T} +T{ +.PN XIMPreeditNothing +T} T{ +If chosen, the input method can function without any preedit values. +T} +T{ +.PN XIMPreeditNone +T} T{ +The input method does not provide any preedit feedback. +Any preedit value is ignored. +This style is mutually exclusive with the other preedit styles. +T} +.TE +.LP +The status category defines what type of support is provided +by the input method for status information. +.IN "XIMStatusArea" "" "@DEF@" +.IN "XIMStatusCallbacks" "" "@DEF@" +.IN "XIMStatusNothing" "" "@DEF@" +.IN "XIMStatusNone" "" "@DEF@" +.TS +lw(1.5i) lw(4.25i). +T{ +.PN XIMStatusArea +T} T{ +The input method requires the client to provide +some area values for it to do its status feedback. +See +.PN XNArea +and +.PN XNAreaNeeded . +T} +T{ +.PN XIMStatusCallbacks +T} T{ +The input method requires the client to define the set of status callbacks, +.PN XNStatusStartCallback , +.PN XNStatusDoneCallback , +and +.PN XNStatusDrawCallback . +T} +T{ +.PN XIMStatusNothing +T} T{ +The input method can function without any status values. +T} +T{ +.PN XIMStatusNone +T} T{ +The input method does not provide any status feedback. +If chosen, any status value is ignored. +This style is mutually exclusive with the other status styles. +T} +.TE +.NH 4 +Resource Name and Class +.XS +\*(SN Resource Name and Class +.XE +.LP +The +.PN XNResourceName +and +.PN XNResourceClass +arguments are strings that specify the full name and class +used by the input method. +These values should be used as prefixes for the name and class +when looking up resources that may vary according to the input method. +If these values are not set, +the resources will not be fully specified. +.LP +It is not intended that values that can be set as XIM values be +set as resources. +.LP +.NH 4 +Destroy Callback +.XS +\*(SN Destroy Callback +.XE +.LP +The +.PN XNDestroyCallback +argument is a pointer to a structure of type +.PN XIMCallback . +.PN XNDestroyCallback +is triggered when an input method stops its service for any reason. +After the callback is invoked, the input method is closed and the +associated input context(s) are destroyed by Xlib. +Therefore, the client should not call +.PN XCloseIM +or +.PN XDestroyIC . +.LP +The generic prototype of this callback function is as follows: +.IN "DestroyCallback" "" "@DEF@" +.sM +.FD 0 +void DestroyCallback\^(\^\fIim\fP\^, \fIclient_data\fP\^, \fIcall_data\fP\^) +.br + XIM \fIim\fP\^; +.br + XPointer \fIclient_data\fP\^; +.br + XPointer \fIcall_data\fP\^; +.FN +.IP \fIim\fP 1i +Specifies the input method. +.IP \fIclient_data\fP 1i +Specifies the additional client data. +.IP \fIcall_data\fP 1i +Not used for this callback and always passed as NULL. +.LP +.eM +A DestroyCallback is always called with a NULL call_data argument. +.LP +.NH 4 +Query IM/IC Values List +.XS +\*(SN Query IM/IC Values List +.XE +.LP +.PN XNQueryIMValuesList +and +.PN XNQueryICValuesList +are used to query about XIM and XIC values supported by the input method. +.LP +The argument value must be a pointer to a location where the returned +value will be stored. The returned value is a pointer to a structure +of type +.PN XIMValuesList . +Clients are responsible for freeing the +.PN XIMValuesList +structure. +To do so, use +.PN XFree . +.LP +The +.PN XIMValuesList +structure is defined as follows: +.sM +.Ds 0 +.TA .5i 2.5i +.ta .5i 2.5i +typedef struct { + unsigned short count_values; + char **supported_values; +} XIMValuesList; +.De +.LP +.eM +.NH 4 +Visible Position +.XS +\*(SN Visible Position +.XE +.LP +The +.PN XNVisiblePosition +argument indicates whether the visible position masks of +.PN XIMFeedback +in +.PN XIMText +are available. +.LP +The argument value must be a pointer to a location where the returned +value will be stored. The returned value is of type +.PN Bool . +If the returned value is +.PN True , +the input method uses the visible position masks of +.PN XIMFeedback +in +.PN XIMText ; +otherwise, the input method does not use the masks. +.LP +Because this XIM value is optional, a client should call +.PN XGetIMValues +with argument +.PN XNQueryIMValues +before using this argument. +If the +.PN XNVisiblePosition +does not exist in the IM values list returned from +.PN XNQueryIMValues , +the visible position masks of +.PN XIMFeedback +in +.PN XIMText +are not used to indicate the visible position. +.LP +.NH 4 +Preedit Callback Behavior +.XS +\*(SN Preedit Callback Behavior +.XE +.LP +The +.PN XNR6PreeditCallbackBehavior +argument originally included in the X11R6 specification has been +deprecated.\(dg +.\" If XNR6PreeditCallbackBehavior is not deprecated, then its type +.\" should be changed from *Bool to Bool. +.FS \(dg +During formulation of the X11R6 specification, the behavior of +the R6 PreeditDrawCallbacks was going to differ significantly from +that of the R5 callbacks. +Late changes to the specification converged the R5 and R6 behaviors, +eliminating the need for +.PN XNR6PreeditCallbackBehavior . +Unfortunately, this argument was not removed from the R6 specification +before it was published. +.FE +.LP +The +.PN XNR6PreeditCallbackBehavior +argument indicates whether the behavior of preedit callbacks regarding +.PN XIMPreeditDrawCallbackStruct +values follows Release 5 or Release 6 semantics. +.LP +The value is of type +.PN Bool . +When querying for +.PN XNR6PreeditCallbackBehavior , +if the returned value is +.PN True , +the input method uses the Release 6 behavior; +otherwise, it uses the Release 5 behavior. +The default value is +.PN False . +In order to use Release 6 semantics, the value of +.PN XNR6PreeditCallbackBehavior +must be set to +.PN True . +.LP +Because this XIM value is optional, a client should call +.PN XGetIMValues +with argument +.PN XNQueryIMValues +before using this argument. +If the +.PN XNR6PreeditCallbackBehavior +does not exist in the IM values list returned from +.PN XNQueryIMValues , +the PreeditCallback behavior is Release 5 semantics. +.LP +.NH 3 +Input Context Functions +.XS +\*(SN Input Context Functions +.XE +.LP +An input context is an abstraction that is used to contain both the data +required (if any) by an input method and the information required +to display that data. +There may be multiple input contexts for one input method. +The programming interfaces for creating, reading, or modifying +an input context use a variable argument list. +The name elements of the argument lists are referred to as XIC values. +It is intended that input methods be controlled by these XIC values. +As new XIC values are created, +they should be registered with the X Consortium. +.LP +.sp +To create an input context, use +.PN XCreateIC . +.IN "XCreateIC" "" "@DEF@" +.sM +.FD 0 +XIC XCreateIC\^(\^\fIim\fP\^, ...) +.br + XIM \fIim\fP\^; +.FN +.IP \fIim\fP 1i +Specifies the input method. +.ds Al \ to set XIC values +.IP ... 1i +Specifies the variable length argument list\*(Al. +.LP +.eM +The +.PN XCreateIC +function creates a context within the specified input method. +.LP +Some of the arguments are mandatory at creation time, and +the input context will not be created if those arguments are not provided. +The mandatory arguments are the input style and the set of text callbacks +(if the input style selected requires callbacks). +All other input context values can be set later. +.LP +.PN XCreateIC +returns a NULL value if no input context could be created. +A NULL value could be returned for any of the following reasons: +.IP \(bu 5 +A required argument was not set. +.IP \(bu 5 +A read-only argument was set (for example, +.PN XNFilterEvents ). +.IP \(bu 5 +The argument name is not recognized. +.IP \(bu 5 +The input method encountered an input method implementation-dependent error. +.LP +.PN XCreateIC +can generate +.PN BadAtom , +.PN BadColor , +.PN BadPixmap , +and +.PN BadWindow +errors. +.LP +.sp +To destroy an input context, use +.PN XDestroyIC . +.IN "XDestroyIC" "" "@DEF@" +.sM +.FD 0 +void XDestroyIC\^(\^\fIic\fP\^) +.br + XIC \fIic\fP\^; +.FN +.IP \fIic\fP 1i +Specifies the input context. +.LP +.eM +.PN XDestroyIC +destroys the specified input context. +.LP +.sp +To communicate to and synchronize with input method +for any changes in keyboard focus from the client side, +use +.PN XSetICFocus +and +.PN XUnsetICFocus . +.IN "XSetICFocus" "" "@DEF@" +.sM +.FD 0 +void XSetICFocus\^(\^\fIic\fP\^) +.br + XIC \fIic\fP\^; +.FN +.IP \fIic\fP 1i +Specifies the input context. +.LP +.eM +The +.PN XSetICFocus +function allows a client to notify an input method that the focus window +attached to the specified input context has received keyboard focus. +The input method should take action to provide appropriate feedback. +Complete feedback specification is a matter of user interface policy. +.LP +Calling +.PN XSetICFocus +does not affect the focus window value. +.LP +.sp +.IN "XUnsetICFocus" "" "@DEF@" +.sM +.FD 0 +void XUnsetICFocus\^(\^\fIic\fP\^) +.br + XIC \fIic\fP\^; +.FN +.IP \fIic\fP 1i +Specifies the input context. +.LP +.eM +The +.PN XUnsetICFocus +function allows a client to notify an input method that the specified input context +has lost the keyboard focus and that no more input is expected on the focus window +attached to that input context. +The input method should take action to provide appropriate feedback. +Complete feedback specification is a matter of user interface policy. +.LP +Calling +.PN XUnsetICFocus +does not affect the focus window value; +the client may still receive +events from the input method that are directed to the focus window. +.LP +.sp +To reset the state of an input context to its initial state, use +.PN XmbResetIC +or +.PN XwcResetIC . +.IN "XmbResetIC" "" "@DEF@" +.IN "XwcResetIC" "" "@DE@" +.sM +.FD 0 +char * XmbResetIC\^(\^\fIic\fP\^) +.br + XIC \fIic\fP\^; +.FN +.FD 0 +wchar_t * XwcResetIC\^(\^\fIic\fP\^) +.br + XIC \fIic\fP\^; +.FN +.IP \fIic\fP 1i +Specifies the input context. +.LP +.eM +When +.PN XNResetState +is set to +.PN XIMInitialState , +.PN XmbResetIC +and +.PN XwcResetIC +reset an input context to its initial state; +when +.PN XNResetState +is set to +.PN XIMPreserveState , +the current input context state is preserved. +In both cases, any input pending on that context is deleted. +The input method is required to clear the preedit area, if any, +and update the status accordingly. +Calling +.PN XmbResetIC +or +.PN XwcResetIC +does not change the focus. +.LP +The return value of +.PN XmbResetIC +is its current preedit string as a multibyte string. +If there is any preedit text drawn or visible to the user, +then these procedures must return a non-NULL string. +If there is no visible preedit text, +then it is input method implementation-dependent +whether these procedures return a non-NULL string or NULL. +.LP +The client should free the returned string by calling +.PN XFree . +.LP +.sp +To get the input method associated with an input context, use +.PN XIMOfIC . +.IN "XIMOfIC" "" "@DEF@" +.sM +.FD 0 +XIM XIMOfIC\^(\^\fIic\fP\^) +.br + XIC \fIic\fP\^; +.FN +.IP \fIic\fP 1i +Specifies the input context. +.LP +.eM +The +.PN XIMOfIC +function returns the input method associated with the specified input context. +.LP +.sp +Xlib provides two functions for setting and reading XIC values, respectively, +.PN XSetICValues +and +.PN XGetICValues . +Both functions have a variable-length argument list. +In that argument list, any XIC value's name must be denoted +with a character string using the X Portable Character Set. +.LP +.sp +To set XIC values, use +.PN XSetICValues . +.IN "XSetICValues" "" "@DEF@" +.sM +.FD 0 +char * XSetICValues\^(\^\fIic\fP\^, ...) +.br + XIC \fIic\fP\^; +.FN +.IP \fIic\fP 1i +Specifies the input context. +.ds Al \ to set XIC values +.IP ... 1i +Specifies the variable length argument list\*(Al. +.LP +.eM +The +.PN XSetICValues +function returns NULL if no error occurred; +otherwise, +it returns the name of the first argument that could not be set. +An argument might not be set for any of the following reasons: +.IP \(bu 5 +The argument is read-only (for example, +.PN XNFilterEvents ). +.IP \(bu 5 +The argument name is not recognized. +.IP \(bu 5 +An implementation-dependent error occurs. +.LP +Each value to be set must be an appropriate datum, +matching the data type imposed by the semantics of the argument. +.LP +.PN XSetICValues +can generate +.PN BadAtom , +.PN BadColor , +.PN BadCursor , +.PN BadPixmap , +and +.PN BadWindow +errors. +.LP +.sp +To obtain XIC values, use +.PN XGetICValues . +.IN "XGetICValues" "" "@DEF@" +.sM +.FD 0 +char * XGetICValues\^(\^\fIic\fP\^, ...) +.br + XIC \fIic\fP\^; +.FN +.IP \fIic\fP 1i +Specifies the input context. +.ds Al \ to get XIC values +.IP ... 1i +Specifies the variable length argument list\*(Al. +.LP +.eM +The +.PN XGetICValues +function returns NULL if no error occurred; otherwise, +it returns the name of the first argument that could not be obtained. +An argument could not be obtained for any of the following reasons: +.IP \(bu 5 +The argument name is not recognized. +.IP \(bu 5 +The input method encountered an implementation-dependent error. +.LP +Each IC attribute value argument (following a name) must point to +a location where the IC value is to be stored. +That is, if the IC value is of type T, +the argument must be of type T*. +If T itself is a pointer type, +then +.PN XGetICValues +allocates memory to store the actual data, +and the client is responsible for freeing this data by calling +.PN XFree +with the returned pointer. +The exception to this rule is for an IC value of type +.PN XVaNestedList +(for preedit and status attributes). +In this case, the argument must also be of type +.PN XVaNestedList . +Then, the rule of changing type T to T* and freeing the allocated data +applies to each element of the nested list. +.NH 3 +Input Context Values +.XS +\*(SN Input Context Values +.XE +.LP +The following tables describe how XIC values are interpreted +by an input method depending on the input style chosen by the +user. +.LP +The first column lists the XIC values. +The second column indicates which values are involved in affecting, +negotiating, and setting the geometry of the input method windows. +The subentries under the third column indicate the different +input styles that are supported. +Each of these columns indicates how each of the XIC values +are treated by that input style. +.LP +The following keys apply to these tables. +.TS H +lw(1i) lw(4.75i). +_ +.sp 6p +.B +Key Explanation +.sp 6p +_ +.TH +.R +C T{ +This value must be set with +.PN XCreateIC . +T} +D T{ +This value may be set using +.PN XCreateIC . +If it is not set, +a default is provided. +T} +G T{ +This value may be read using +.PN XGetICValues . +T} +GN T{ +This value may cause geometry negotiation when its value is set by means of +.PN XCreateIC +or +.PN XSetICValues . +T} +GR T{ +This value will be the response of the input method when any +GN value is changed. +T} +GS T{ +This value will cause the geometry of the input method window to be set. +T} +O T{ +This value must be set once and only once. +It need not be set at create time. +T} +S T{ +This value may be set with +.PN XSetICValues . +T} +Ignored T{ +This value is ignored by the input method for the given input style. +T} +.sp 6p +_ +.TE +.LP +.TS H +c c c s s s s +l c c c c c c +c c c c c c c +l c c c c c c. +_ +.sp 6p +.B + Input Style +XIC Value Geometry Preedit Preedit Preedit Preedit Preedit + Management Callback Position Area Nothing None +.sp 6p +_ +.sp 6p +.TH +.R +Input Style C-G C-G C-G C-G C-G +Client Window O-G O-G O-G O-G Ignored +Focus Window GN D-S-G D-S-G D-S-G D-S-G Ignored +Resource Name Ignored D-S-G D-S-G D-S-G Ignored +Resource Class Ignored D-S-G D-S-G D-S-G Ignored +Geometry Callback Ignored Ignored D-S-G Ignored Ignored +Filter Events G G G G Ignored +Destroy Callback D-S-G D-S-G D-S-G D-S-G D-S-G +String Conversion Callback S-G S-G S-G S-G S-G +String Conversion D-S-G D-S-G D-S-G D-S-G D-S-G +Reset State D-S-G D-S-G D-S-G D-S-G Ignored +HotKey S-G S-G S-G S-G Ignored +HotKeyState D-S-G D-S-G D-S-G D-S-G Ignored +.sp 6p +\fBPreedit\fP +Area GS Ignored D-S-G D-S-G Ignored Ignored +Area Needed GN-GR Ignored Ignored S-G Ignored Ignored +Spot Location Ignored D-S-G Ignored Ignored Ignored +Colormap Ignored D-S-G D-S-G D-S-G Ignored +Foreground Ignored D-S-G D-S-G D-S-G Ignored +Background Ignored D-S-G D-S-G D-S-G Ignored +Background Pixmap Ignored D-S-G D-S-G D-S-G Ignored +Font Set GN Ignored D-S-G D-S-G D-S-G Ignored +Line Spacing GN Ignored D-S-G D-S-G D-S-G Ignored +Cursor Ignored D-S-G D-S-G D-S-G Ignored +Preedit State D-S-G D-S-G D-S-G D-S-G Ignored +Preedit State Notify Callback S-G S-G S-G S-G Ignored +Preedit Callbacks C-S-G Ignored Ignored Ignored Ignored +.sp 6p +_ +.TE +.LP +.TS H +c c c s s s +l c c c c c +c c c c c c +l c c c c c. +_ +.sp 6p +.B + Input Style +XIC Value Geometry Status Status Status Status + Management Callback Area Nothing None +.sp 6p +_ +.sp 6p +.TH +.R +Input Style C-G C-G C-G C-G +Client Window O-G O-G O-G Ignored +Focus Window GN D-S-G D-S-G D-S-G Ignored +Resource Name Ignored D-S-G D-S-G Ignored +Resource Class Ignored D-S-G D-S-G Ignored +Geometry Callback Ignored D-S-G Ignored Ignored +Filter Events G G G G +.sp 6p +\fBStatus\fP +Area GS Ignored D-S-G Ignored Ignored +Area Needed GN-GR Ignored S-G Ignored Ignored +Colormap Ignored D-S-G D-S-G Ignored +Foreground Ignored D-S-G D-S-G Ignored +Background Ignored D-S-G D-S-G Ignored +Background Pixmap Ignored D-S-G D-S-G Ignored +Font Set GN Ignored D-S-G D-S-G Ignored +Line Spacing GN Ignored D-S-G D-S-G Ignored +Cursor Ignored D-S-G D-S-G Ignored +Status Callbacks C-S-G Ignored Ignored Ignored +.sp 6p +_ +.TE +.NH 4 +Input Style +.XS +\*(SN Input Style +.XE +.LP +The +.PN XNInputStyle +argument specifies the input style to be used. +The value of this argument must be one of the values returned by the +.PN XGetIMValues +function with the +.PN XNQueryInputStyle +argument specified in the supported_styles list. +.LP +Note that this argument must be set at creation time +and cannot be changed. +.NH 4 +Client Window +.XS +\*(SN Client Window +.XE +.LP +.IN "XNClientWindow" "" "@DEF@" +The +.PN XNClientWindow +argument specifies to the input method the client window in +which the input method +can display data or create subwindows. +Geometry values for input method areas are given with respect to the client +window. +Dynamic change of client window is not supported. +This argument may be set only once and +should be set before any input is done using this input context. +If it is not set, +the input method may not operate correctly. +.LP +If an attempt is made to set this value a second time with +.PN XSetICValues , +the string +.PN XNClientWindow +will be returned by +.PN XSetICValues , +and the client window will not be changed. +.LP +If the client window is not a valid window ID on the display +attached to the input method, +a +.PN BadWindow +error can be generated when this value is used by the input method. +.NH 4 +Focus Window +.XS +\*(SN Focus Window +.XE +.LP +.IN "XNFocusWindow" "" "@DEF@" +The +.PN XNFocusWindow +argument specifies the focus window. +The primary purpose of the +.PN XNFocusWindow +is to identify the window that will receive the key event when input +is composed. +In addition, the input method may possibly affect the focus window +as follows: +.IP \(bu 5 +Select events on it +.IP \(bu 5 +Send events to it +.IP \(bu 5 +Modify its properties +.IP \(bu 5 +Grab the keyboard within that window +.LP +The associated value must be of type +.PN Window . +If the focus window is not a valid window ID on the display +attached to the input method, +a +.PN BadWindow +error can be generated when this value is used by the input method. +.LP +When this XIC value is left unspecified, +the input method will use the client window as the default focus window. +.NH 4 +Resource Name and Class +.XS +\*(SN Resource Name and Class +.XE +.LP +.IN "XNResourceName" "" "@DEF@" +.IN "XNResourceClass" "" "@DEF@" +The +.PN XNResourceName +and +.PN XNResourceClass +arguments are strings that specify the full name and class +used by the client to obtain resources for the client window. +These values should be used as prefixes for name and class +when looking up resources that may vary according to the input context. +If these values are not set, +the resources will not be fully specified. +.LP +It is not intended that values that can be set as XIC values be +set as resources. +.NH 4 +Geometry Callback +.XS +\*(SN Geometry Callback +.XE +.LP +.IN "XNGeometryCallback" "" "@DEF@" +The +.PN XNGeometryCallback +argument is a structure of type +.PN XIMCallback +(see section 13.5.6.13.12). +.LP +The +.PN XNGeometryCallback +argument specifies the geometry callback that a client can set. +This callback is not required for correct operation of either +an input method or a client. +It can be set for a client whose user interface policy permits +an input method to request the dynamic change of that input +method's window. +An input method that does dynamic change will need to filter any +events that it uses to initiate the change. +.NH 4 +Filter Events +.XS +\*(SN Filter Events +.XE +.LP +.IN "XNFilterEvents" "" "@DEF@" +The +.PN XNFilterEvents +argument returns the event mask that an input method needs +to have selected for. +The client is expected to augment its own event mask +for the client window with this one. +.LP +This argument is read-only, is set by the input method at create time, +and is never changed. +.LP +The type of this argument is +.PN unsigned +.PN long . +Setting this value will cause an error. +.NH 4 +Destroy Callback +.XS +\*(SN Destroy Callback +.XE +.LP +The +.PN XNDestroyCallback +argument is a pointer to a structure of type +.PN XIMCallback +(see section 13.5.6.13.12). This callback is triggered when the input method +stops its service for any reason; for example, when a connection to an IM +server is broken. After the destroy callback is called, +the input context is destroyed and the input method is closed. +Therefore, the client should not call +.PN XDestroyIC +and +.PN XCloseIM . +.LP +.NH 4 +String Conversion Callback +.XS +\*(SN String Conversion Callback +.XE +.LP +The +.PN XNStringConversionCallback +argument is a structure of type +.PN XIMCallback +(see section 13.5.6.13.12). +.LP +The +.PN XNStringConversionCallback +argument specifies a string conversion callback. This callback +is not required for correct operation of +either the input method or the client. It can be set by a client +to support string conversions that may be requested +by the input method. An input method that does string conversions +will filter any events that it uses to initiate the conversion. +.LP +Because this XIC value is optional, a client should call +.PN XGetIMValues +with argument +.PN XNQueryICValuesList +before using this argument. +.LP +.NH 4 +String Conversion +.XS +\*(SN String Conversion +.XE +.LP +The +.PN XNStringConversion +argument is a structure of type +.PN XIMStringConversionText . +.LP +The +.PN XNStringConversion +argument specifies the string to be converted by an input method. +This argument is not required for correct operation of either +the input method or the client. +.LP +String conversion facilitates the manipulation of text independent +of preediting. +It is essential for some input methods and clients to manipulate +text by performing context-sensitive conversion, +reconversion, or transliteration conversion on it. +.LP +Because this XIC value is optional, a client should call +.PN XGetIMValues +with argument +.PN XNQueryICValuesList +before using this argument. +.LP +The +.PN XIMStringConversionText +structure is defined as follows: +.LP +.sM +.Ds 0 + +typedef struct _XIMStringConversionText { + unsigned short length; + XIMStringConversionFeedback *feedback; + Bool encoding_is_wchar; + union { + char *mbs; + wchar_t *wcs; + } string; +} XIMStringConversionText; + +typedef unsigned long XIMStringConversionFeedback; +.De +.LP +.eM +The feedback member is reserved for future use. The text to be +converted is defined by the string and length members. The length +is indicated in characters. To prevent the library from freeing memory +pointed to by an uninitialized pointer, the client should set the feedback +element to NULL. +.LP +.NH 4 +Reset State +.XS +\*(SN Reset State +.XE +.LP +The +.PN XNResetState +argument specifies the state the input context will return to after calling +.PN XmbResetIC +or +.PN XwcResetIC . +.LP +The XIC state may be set to its initial state, as specified by the +.PN XNPreeditState +value when +.PN XCreateIC +was called, or it may be set to preserve the current state. +.LP +The valid masks for +.PN XIMResetState +are as follows: +.LP +.IN "XIMInitialState" "" "@DEF@" +.IN "XINPreserveState" "" "@DEF@" +.sM +.LP +.Ds 0 +typedef unsigned long XIMResetState; +.De +.TS +lw(.5i) lw(2i) lw(2i). +T{ +#define +T} T{ +.PN XIMInitialState +T} T{ +(1L) +T} +T{ +#define +T} T{ +.PN XIMPreserveState +T} T{ +(1L<<1) +T} +.TE +.LP +.eM +If +.PN XIMInitialState +is set, then +.PN XmbResetIC +and +.PN XwcResetIC +will return to the initial +.PN XNPreeditState +state of the XIC. +.LP +If +.PN XIMPreserveState +is set, then +.PN XmbResetIC +and +.PN XwcResetIC +will preserve the current state of the XIC. +.LP +If +.PN XNResetState +is left unspecified, the default is +.PN XIMInitialState . +.LP +.PN XIMResetState +values other than those specified above will default to +.PN XIMInitialState . +.LP +Because this XIC value is optional, a client should call +.PN XGetIMValues +with argument +.PN XNQueryICValuesList +before using this argument. +.LP +.NH 4 +Hot Keys +.XS +\*(SN Hot Keys +.XE +.LP +The +.PN XNHotKey +argument specifies the hot key list to the XIC. +The hot key list is a pointer to the structure of type +.PN XIMHotKeyTriggers , +which specifies the key events that must be received +without any interruption of the input method. +For the hot key list set with this argument to be utilized, the client +must also set +.PN XNHotKeyState +to +.PN XIMHotKeyStateON . +.LP +Because this XIC value is optional, a client should call +.PN XGetIMValues +with argument +.PN XNQueryICValuesList +before using this functionality. +.LP +The value of the argument is a pointer to a structure of type +.PN XIMHotKeyTriggers . +.LP +If an event for a key in the hot key list is found, then the process will +receive the event and it will be processed inside the client. +.LP +.sM +.Ds 0 +.TA .5i 2.5i +.ta .5i 2.5i +typedef struct { + KeySym keysym; + unsigned int modifier; + unsigned int modifier_mask; +} XIMHotKeyTrigger; + +typedef struct { + int num_hot_key; + XIMHotKeyTrigger *key; +} XIMHotKeyTriggers; +.De +.LP +.eM +.LP +The combination of modifier and modifier_mask are used to represent one of +three states for each modifier: +either the modifier must be on, or the modifier must be off, or the modifier +is a ``don't care'' \- it may be on or off. +When a modifier_mask bit is set to 0, the state of the associated modifier +is ignored when evaluating whether the key is hot or not. +.TS H +lw(1i) lw(1i) lw(3i). +_ +.sp 6p +.B +Modifier Bit Mask Bit Meaning +.sp 6p +_ +.sp 6p +.TH +.R +T{ +0 +T} T{ +1 +T} T{ +The modifier must be off. +T} +T{ +1 +T} T{ +1 +T} T{ +The modifier must be on. +T} +T{ +n/a +T} T{ +0 +T} T{ +Do not care if the modifier is on or off. +T} +.sp 6p +_ +.TE +.NH 4 +Hot Key State +.XS +\*(SN Hot Key State +.XE +.LP +The +.PN XNHotKeyState +argument specifies the hot key state of the input method. +This is usually used to switch the input method between hot key +operation and normal input processing. +.LP +The value of the argument is a pointer to a structure of type +XIMHotKeyState . +.LP +.sM +.Ds 0 +.TA .5i 2.5i +.ta .5i 2.5i +typedef unsigned long XIMHotKeyState; +.De +.TS +lw(.5i) lw(3i) lw(2i). +T{ +#define +T} T{ +.PN XIMHotKeyStateON +T} T{ +(0x0001L) +T} +T{ +#define +T} T{ +.PN XIMHotKeyStateOFF +T} T{ +(0x0002L) +T} +.TE +.LP +.eM +.LP +If not specified, the default is +.PN XIMHotKeyStateOFF . +.LP +.NH 4 +Preedit and Status Attributes +.XS +\*(SN Preedit and Status Attributes +.XE +.LP +.IN "XNPreeditAttributes" "" "@DEF@" +.IN "XNStatusAttributes" "" "@DEF@" +The +.PN XNPreeditAttributes +and +.PN XNStatusAttributes +arguments specify to an input method the attributes to be used for the +preedit and status areas, +if any. +Those attributes are passed to +.PN XSetICValues +or +.PN XGetICValues +as a nested variable-length list. +The names to be used in these lists are described in the following sections. +.NH 5 +Area +.XS +\*(SN Area +.XE +.LP +.IN "XNArea" "" "@DEF@" +The value of the +.PN XNArea +argument must be a pointer to a structure of type +.PN XRectangle. +The interpretation of the +.PN XNArea +argument is dependent on the input method style that has been set. +.LP +If the input method style is +.PN XIMPreeditPosition , +.PN XNArea +specifies the clipping region within which preediting will take place. +If the focus window has been set, +the coordinates are assumed to be relative to the focus window. +Otherwise, the coordinates are assumed to be relative to the client window. +If neither has been set, +the results are undefined. +.LP +If +.PN XNArea +is not specified, is set to NULL, or is invalid, +the input method will default the clipping region +to the geometry of the +.PN XNFocusWindow . +If the area specified is NULL or invalid, +the results are undefined. +.LP +If the input style is +.PN XIMPreeditArea +or +.PN XIMStatusArea , +.PN XNArea +specifies the geometry provided by the client to the input method. +The input method may use this area to display its data, +either preedit or status depending on the area designated. +The input method may create a window as a child of the client window +with dimensions that fit the +.PN XNArea . +The coordinates are relative to the client window. +If the client window has not been set yet, +the input method should save these values +and apply them when the client window is set. +If +.PN XNArea +is not specified, is set to NULL, or is invalid, +the results are undefined. +.NH 5 +Area Needed +.XS +\*(SN Area Needed +.XE +.LP +.IN "XNAreaNeeded" "" "@DEF@" +When set, the +.PN XNAreaNeeded +argument specifies the geometry suggested by the client for this area +(preedit or status). +The value associated with the argument must be a pointer to a +structure of type +.PN XRectangle . +Note that the x, y values are not used +and that nonzero values for width or height are the constraints +that the client wishes the input method to respect. +.LP +When read, the +.PN XNAreaNeeded +argument specifies the preferred geometry desired by the input method +for the area. +.LP +This argument is only valid if the input style is +.PN XIMPreeditArea +or +.PN XIMStatusArea . +It is used for geometry negotiation between the client and the input method +and has no other effect on the input method +(see section 13.5.1.5). +.NH 5 +Spot Location +.XS +\*(SN Spot Location +.XE +.LP +.IN "XNSpotLocation" "" "@DEF@" +The +.PN XNSpotLocation +argument specifies to the input method the coordinates of the spot +to be used by an input method executing with +.PN XNInputStyle +set to +.PN XIMPreeditPosition . +When specified to any input method other than +.PN XIMPreeditPosition , +this XIC value is ignored. +.LP +The x coordinate specifies the position where the next character +would be inserted. +The y coordinate is the position of the baseline used +by the current text line in the focus window. +The x and y coordinates are relative to the focus window, if it has been set; +otherwise, they are relative to the client window. +If neither the focus window nor the client window has been set, +the results are undefined. +.LP +The value of the argument is a pointer to a structure of type +.PN XPoint . +.NH 5 +Colormap +.XS +\*(SN Colormap +.XE +.LP +Two different arguments can be used to indicate what colormap the input method +should use to allocate colors, a colormap ID, or a standard colormap name. +.LP +.IN "XNColormap" "" "@DEF@" +The +.PN XNColormap +argument is used to specify a colormap ID. +The argument value is of type +.PN Colormap . +An invalid argument may generate a +.PN BadColor +error when it is used by the input method. +.LP +.IN "XNStdColormap" "" "@DEF@" +The +.PN XNStdColormap +argument is used to indicate the name of the standard colormap +in which the input method should allocate colors. +The argument value is an +.PN Atom +that should be a valid atom for calling +.PN XGetRGBColormaps . +An invalid argument may generate a +.PN BadAtom +error when it is used by the input method. +.LP +If the colormap is left unspecified, +the client window colormap becomes the default. +.NH 5 +Foreground and Background +.XS +\*(SN Foreground and Background +.XE +.LP +.IN "XNForeground" "" "@DEF@" +.IN "XNBackground" "" "@DEF@" +The +.PN XNForeground +and +.PN XNBackground +arguments specify the foreground and background pixel, respectively. +The argument value is of type +.PN unsigned +.PN long . +It must be a valid pixel in the input method colormap. +.LP +If these values are left unspecified, +the default is determined by the input method. +.NH 5 +Background Pixmap +.XS +\*(SN Background Pixmap +.XE +.LP +The +.PN XNBackgroundPixmap +argument specifies a background pixmap to be used as the background of the +window. +The value must be of type +.PN Pixmap . +An invalid argument may generate a +.PN BadPixmap +error when it is used by the input method. +.LP +If this value is left unspecified, +the default is determined by the input method. +.NH 5 +Font Set +.XS +\*(SN Font Set +.XE +.LP +.IN "XNFontSet" "" "@DEF@" +The +.PN XNFontSet +argument specifies to the input method what font set is to be used. +The argument value is of type +.PN XFontSet . +.LP +If this value is left unspecified, +the default is determined by the input method. +.NH 5 +Line Spacing +.XS +\*(SN Line Spacing +.XE +.LP +The +.PN XNLineSpace +argument specifies to the input method what line spacing is to be used +in the preedit window if more than one line is to be used. +This argument is of type +.PN int . +.LP +If this value is left unspecified, +the default is determined by the input method. +.NH 5 +Cursor +.XS +\*(SN Cursor +.XE +.LP +.IN "XNCursor" "" "DEF@" +The +.PN XNCursor +argument specifies to the input method what cursor is to be used +in the specified window. +This argument is of type +.PN Cursor . +.LP +An invalid argument may generate a +.PN BadCursor +error when it is used by the input method. +If this value is left unspecified, +the default is determined by the input method. +.NH 5 +Preedit State +.XS +\*(SN Preedit State +.XE +.LP +The +.PN XNPreeditState +argument specifies the state of input preediting for the input method. +Input preediting can be on or off. +.LP +The valid mask names for +.PN XNPreeditState +are as follows: +.LP +.IN "XIMPreeditUnknown" "" "@DEV@" +.IN "XIMPreeditEnable" "" "@DEF@" +.IN "XIMPreeditDisable" "" "@DEV@" +.sM +.LP +.Ds 0 +typedef unsigned long XIMPreeditState; +.De +.TS +lw(.5i) lw(2i) lw(2i). +T{ +#define +T} T{ +.PN XIMPreeditUnknown +T} T{ +0L +T} +T{ +#define +T} T{ +.PN XIMPreeditEnable +T} T{ +1L +T} +T{ +#define +T} T{ +.PN XIMPreeditDisable +T} T{ +(1L<<1) +T} +.TE +.LP +.eM +If a value of +.PN XIMPreeditEnable +is set, then input preediting is turned on by the input method. +.LP +If a value of +.PN XIMPreeditDisable +is set, then input preediting is turned off by the input method. +.LP +If +.PN XNPreeditState +is left unspecified, then the state will be implementation-dependent. +.LP +When +.PN XNResetState +is set to +.PN XIMInitialState , +the +.PN XNPreeditState +value specified at the creation time will be reflected as the initial state for +.PN XmbResetIC +and +.PN XwcResetIC . +.LP +Because this XIC value is optional, a client should call +.PN XGetIMValues +with argument +.PN XNQueryICValuesList +before using this argument. +.NH 5 +Preedit State Notify Callback +.XS +\*(SN Preedit State Notify Callback +.XE +.LP +The preedit state notify callback is triggered by the input method +when the preediting state has changed. +The value of the +.PN XNPreeditStateNotifyCallback +argument is a pointer to a structure of type +.PN XIMCallback . +The generic prototype is as follows: +.IN "PreeditStateNotifyCallback" "" "@DEF@" +.sM +.FD 0 +void PreeditStateNotifyCallback\^(\^\fIic\fP\^, \fIclient_data\fP\^, \fIcall_data\fP\^) +.br + XIC \fIic\fP\^; +.br + XPointer \fIclient_data\fP\^; +.br + XIMPreeditStateNotifyCallbackStruct *\fIcall_data\fP\^; +.FN +.IP \fIic\fP 1i +Specifies the input context. +.IP \fIclient_data\fP 1i +Specifies the additional client data. +.IP \fIcall_data\fP 1i +Specifies the current preedit state. +.LP +.eM +The +.PN XIMPreeditStateNotifyCallbackStruct +structure is defined as follows: +.LP +.IN "XIMPreeditStateNotifyCallbackStruct" "" "@DEF@" +.sM +.Ds 0 +.TA .5i 2.5i +.ta .5i 2.5i +typedef struct _XIMPreeditStateNotifyCallbackStruct { + XIMPreeditState state; +} XIMPreeditStateNotifyCallbackStruct; +.De +.LP +.eM +.LP +Because this XIC value is optional, a client should call +.PN XGetIMValues +with argument +.PN XNQueryICValuesList +before using this argument. +.NH 5 +Preedit and Status Callbacks +.XS +\*(SN Preedit and Status Callbacks +.XE +.LP +A client that wants to support the input style +.PN XIMPreeditCallbacks +must provide a set of preedit callbacks to the input method. +The set of preedit callbacks is as follows: +.IN "XNPreeditStartCallback" "" "@DEF@" +.IN "XNPreeditDoneCallback" "" "@DEF@" +.IN "XNPreeditDrawCallback" "" "@DEF@" +.IN "XNPreeditCaretCallback" "" "@DEF@" +.TS +lw(1.75i) lw(4i). +T{ +.PN XNPreeditStartCallback +T} T{ +This is called when the input method starts preedit. +T} +T{ +.PN XNPreeditDoneCallback +T} T{ +This is called when the input method stops preedit. +T} +T{ +.PN XNPreeditDrawCallback +T} T{ +This is called when a number of preedit keystrokes should be echoed. +T} +T{ +.PN XNPreeditCaretCallback +T} T{ +This is called to move the text insertion point within the preedit string. +T} +.TE +.LP +A client that wants to support the input style +.PN XIMStatusCallbacks +must provide a set of status callbacks to the input method. +The set of status callbacks is as follows: +.IN "XNStatusStartCallback" "" "@DEF@" +.IN "XNStatusDoneCallback" "" "@DEF@" +.IN "XNStatusDrawCallback" "" "@DEF@" +.TS +lw(1.75i) lw(4i). +T{ +.PN XNStatusStartCallback +T} T{ +This is called when the input method initializes the status area. +T} +T{ +.PN XNStatusDoneCallback +T} T{ +This is called when the input method no longer needs the status area. +T} +T{ +.PN XNStatusDrawCallback +T} T{ +This is called when updating of the status area is required. +T} +.TE +.LP +The value of any status or preedit argument is a pointer +to a structure of type +.PN XIMCallback . +.IN "XIMProc" "" "@DEF@" +.IN "XIMCallback" "" "@DEF@" +.sM +.LP +.Ds 0 +.TA .5i 2.5i +.ta .5i 2.5i +typedef void (*XIMProc)(); + +typedef struct { + XPointer client_data; + XIMProc callback; +} XIMCallback; +.De +.LP +.eM +Each callback has some particular semantics and will carry the data +that expresses the environment necessary to the client +into a specific data structure. +This paragraph only describes the arguments to be used to set +the callback. +.LP +Setting any of these values while doing preedit +may cause unexpected results. +.NH 3 +Input Method Callback Semantics +.XS +\*(SN Input Method Callback Semantics +.XE +.LP +XIM callbacks are procedures defined by clients or text drawing packages +that are to be called from the input method when selected events occur. +Most clients will use a text editing package or a toolkit +and, hence, will not need to define such callbacks. +This section defines the callback semantics, when they are triggered, +and what their arguments are. +This information is mostly useful for X toolkit implementors. +.LP +Callbacks are mostly provided so that clients (or text editing +packages) can implement on-the-spot preediting in their own window. +In that case, +the input method needs to communicate and synchronize with the client. +The input method needs to communicate changes in the preedit window +when it is under control of the client. +Those callbacks allow the client to initialize the preedit area, +display a new preedit string, +move the text insertion point during preedit, +terminate preedit, or update the status area. +.LP +All callback procedures follow the generic prototype: +.IN "CallbackPrototype" "" "@DEF@" +.sM +.FD 0 +void CallbackPrototype\^(\^\fIic\fP\^, \fIclient_data\fP\^, \fIcall_data\fP\^) +.br + XIC \fIic\fP\^; +.br + XPointer \fIclient_data\fP\^; +.br + SomeType \fIcall_data\fP\^; +.FN +.IP \fIic\fP 1i +Specifies the input context. +.IP \fIclient_data\fP 1i +Specifies the additional client data. +.IP \fIcall_data\fP 1i +Specifies data specific to the callback. +.LP +.eM +The call_data argument is a structure that expresses the arguments needed +to achieve the semantics; +that is, +it is a specific data structure appropriate to the callback. +In cases where no data is needed in the callback, +this call_data argument is NULL. +The client_data argument is a closure that has been initially specified +by the client when specifying the callback and passed back. +It may serve, for example, to inherit application context in the callback. +.LP +The following paragraphs describe the programming semantics +and specific data structure associated with the different reasons. +.NH 4 +Geometry Callback +.XS +\*(SN Geometry Callback +.XE +.LP +The geometry callback is triggered by the input method +to indicate that it wants the client to negotiate geometry. +The generic prototype is as follows: +.IN "GeometryCallback" "" "@DEF@" +.sM +.FD 0 +void GeometryCallback\^(\^\fIic\fP\^, \fIclient_data\fP\^, \fIcall_data\fP\^) +.br + XIC \fIic\fP\^; +.br + XPointer \fIclient_data\fP\^; +.br + XPointer \fIcall_data\fP\^; +.FN +.IP \fIic\fP 1i +Specifies the input context. +.IP \fIclient_data\fP 1i +Specifies the additional client data. +.IP \fIcall_data\fP 1i +Not used for this callback and always passed as NULL. +.LP +.eM +The callback is called with a NULL call_data argument. +.NH 4 +Destroy Callback +.XS +\*(SN Destroy Callback +.XE +.LP +The destroy callback is triggered by the input method +when it stops service for any reason. +After the callback is invoked, the input context will be freed by Xlib. +The generic prototype is as follows: +.IN "DestroyCallback" "" "@DEF@" +.sM +.FD 0 +void DestroyCallback\^(\^\fIic\fP\^, \fIclient_data\fP\^, \fIcall_data\fP\^) +.br + XIC \fIic\fP\^; +.br + XPointer \fIclient_data\fP\^; +.br + XPointer \fIcall_data\fP\^; +.FN +.IP \fIic\fP 1i +Specifies the input context. +.IP \fIclient_data\fP 1i +Specifies the additional client data. +.IP \fIcall_data\fP 1i +Not used for this callback and always passed as NULL. +.LP +.eM +The callback is called with a NULL call_data argument. +.NH 4 +String Conversion Callback +.XS +\*(SN String Conversion Callback +.XE +.LP +The string conversion callback is triggered by the input method +to request the client to return the string to be converted. The +returned string may be either a multibyte or wide character string, +with an encoding matching the locale bound to the input context. +The callback prototype is as follows: +.IN "StringConversionCallback" "" "@DEF@" +.sM +.FD 0 +void StringConversionCallback\^(\^\fIic\fP\^, \fIclient_data\fP\^, \fIcall_data\fP\^) +.br + XIC \fIic\fP\^; +.br + XPointer \fIclient_data\fP\^; +.br + XIMStringConversionCallbackStruct *\fIcall_data\fP\^; +.FN +.IP \fIic\fP 1i +Specifies the input method. +.IP \fIclient_data\fP 1i +Specifies the additional client data. +.IP \fIcall_data\fP 1i +Specifies the amount of the string to be converted. +.LP +.eM +The callback is passed an +.PN XIMStringConversionCallbackStruct +structure in the call_data argument. +The text member is an +.PN XIMStringConversionText +structure (see section 13.5.6.9) to be filled in by the client +and describes the text to be sent to the input method. +The data pointed to by the +string and feedback elements of the +.PN XIMStringConversionText +structure will be freed using +.PN XFree +by the input method +after the callback returns. So the client should not point to +internal buffers that are critical to the client. +Similarly, because the feedback element is currently reserved for future +use, the client should set feedback to NULL to prevent the library from +freeing memory at some random location due to an uninitialized pointer. +.LP +The +.PN XIMStringConversionCallbackStruct +structure is defined as follows: +.LP +.IN "XIMStringConversionCallbackStruct" "" "@DEF@" +.sM +.LP +.Ds 0 +typedef struct _XIMStringConversionCallbackStruct { + XIMStringConversionPosition position; + XIMCaretDirection direction; + short factor; + XIMStringConversionOperation operation; + XIMStringConversionText *text; +} XIMStringConversionCallbackStruct; + +typedef short XIMStringConversionPosition; + +typedef unsigned short XIMStringConversionOperation; + +.De +.LP +.TS +lw(.5i) lw(3i) lw(2i). +T{ +#define +T} T{ +.PN XIMStringConversionSubstitution +T} T{ +(0x0001) +T} +T{ +#define +T} T{ +.PN XIMStringConversionRetrieval +T} T{ +(0x0002) +T} +.TE +.LP +.eM +.PN XIMStringConversionPosition +specifies the starting position of the string to be returned +in the +.PN XIMStringConversionText +structure. The value identifies a position, in units of characters, +relative to the client's cursor position in the client's buffer. +.LP +The ending position of the text buffer is determined by +the direction and factor members. Specifically, it is the character position +relative to the starting point as defined by the +.PN XIMCaretDirection . +The factor member of +.PN XIMStringConversionCallbackStruct +specifies the number of +.PN XIMCaretDirection +positions to be applied. For example, if the direction specifies +.PN XIMLineEnd +and factor is 1, then all characters from the starting position to +the end of the current display line are returned. If the direction +specifies +.PN XIMForwardChar +or +.PN XIMBackwardChar , +then the factor specifies a relative position, indicated in characters, +from the starting position. +.LP +.PN XIMStringConversionOperation +specifies whether the string to be converted should be +deleted (substitution) or copied (retrieval) from the client's +buffer. When the +.PN XIMStringConversionOperation +is +.PN XIMStringConversionSubstitution , +the client must delete the string to be converted from its own buffer. +When the +.PN XIMStringConversionOperation +is +.PN XIMStringConversionRetrieval , +the client must not delete the string to be converted from its buffer. +The substitute operation is typically used for reconversion and +transliteration conversion, +while the retrieval operation is typically used for context-sensitive +conversion. +.NH 4 +Preedit State Callbacks +.XS +\*(SN Preedit State Callbacks +.XE +.LP +When the input method turns preediting on or off, a +.PN PreeditStartCallback +or +.PN PreeditDoneCallback +callback is triggered to let the toolkit do the setup +or the cleanup for the preedit region. +.IN "PreeditStartCallback" "" "@DEF@" +.sM +.FD 0 +int PreeditStartCallback\^(\^\fIic\fP\^, \fIclient_data\fP\^, \fIcall_data\fP\^) +.br + XIC \fIic\fP\^; +.br + XPointer \fIclient_data\fP\^; +.br + XPointer \fIcall_data\fP\^; +.FN +.IP \fIic\fP 1i +Specifies the input context. +.IP \fIclient_data\fP 1i +Specifies the additional client data. +.IP \fIcall_data\fP 1i +Not used for this callback and always passed as NULL. +.LP +.eM +When preedit starts on the specified input context, +the callback is called with a NULL call_data argument. +.PN PreeditStartCallback +will return the maximum size of the preedit string. +A positive number indicates the maximum number of bytes allowed +in the preedit string, +and a value of \-1 indicates there is no limit. +.IN "PreeditDoneCallback" "" "@DEF@" +.sM +.FD 0 +void PreeditDoneCallback\^(\^\fIic\fP\^, \fIclient_data\fP\^, \fIcall_data\fP\^) +.br + XIC \fIic\fP\^; +.br + XPointer \fIclient_data\fP\^; +.br + XPointer \fIcall_data\fP\^; +.FN +.IP \fIic\fP 1i +Specifies the input context. +.IP \fIclient_data\fP 1i +Specifies the additional client data. +.IP \fIcall_data\fP 1i +Not used for this callback and always passed as NULL. +.LP +.eM +When preedit stops on the specified input context, +the callback is called with a NULL call_data argument. +The client can release the data allocated by +.PN PreeditStartCallback . +.LP +.PN PreeditStartCallback +should initialize appropriate data needed for +displaying preedit information and for handling further +.PN PreeditDrawCallback +calls. +Once +.PN PreeditStartCallback +is called, it will not be called again before +.PN PreeditDoneCallback +has been called. +.NH 4 +Preedit Draw Callback +.XS +\*(SN Preedit Draw Callback +.XE +.LP +This callback is triggered to draw and insert, delete or replace, +preedit text in the preedit region. +The preedit text may include unconverted input text such as Japanese Kana, +converted text such as Japanese Kanji characters, or characters of both kinds. +That string is either a multibyte or wide character string, +whose encoding matches the locale bound to the input context. +The callback prototype +is as follows: +.IN "PreeditDrawCallback" "" "@DEF@" +.sM +.FD 0 +void PreeditDrawCallback\^(\^\fIic\fP\^, \fIclient_data\fP\^, \fIcall_data\fP\^) +.br + XIC \fIic\fP\^; +.br + XPointer \fIclient_data\fP\^; +.br + XIMPreeditDrawCallbackStruct *\fIcall_data\fP\^; +.FN +.IP \fIic\fP 1i +Specifies the input context. +.IP \fIclient_data\fP 1i +Specifies the additional client data. +.IP \fIcall_data\fP 1i +Specifies the preedit drawing information. +.LP +.eM +The callback is passed an +.PN XIMPreeditDrawCallbackStruct +structure in the call_data argument. +The text member of this structure contains the text to be drawn. +After the string has been drawn, +the caret should be moved to the specified location. +.LP +The +.PN XIMPreeditDrawCallbackStruct +structure is defined as follows: +.LP +.IN "XIMPreeditDrawCallbackStruct" "" "@DEF@" +.sM +.Ds 0 +.TA .5i 2.5i +.ta .5i 2.5i +typedef struct _XIMPreeditDrawCallbackStruct { + int caret; /* Cursor offset within preedit string */ + int chg_first; /* Starting change position */ + int chg_length; /* Length of the change in character count */ + XIMText *text; +} XIMPreeditDrawCallbackStruct; +.De +.LP +.eM +The client must keep updating a buffer of the preedit text +and the callback arguments referring to indexes in that buffer. +The call_data fields have specific meanings according to the operation, +as follows: +.IP \(bu 5 +To indicate text deletion, +the call_data member specifies a NULL text field. +The text to be deleted is then the current text in the buffer +from position chg_first (starting at zero) on a character length +of chg_length. +.IP \(bu 5 +When text is non-NULL, +it indicates insertion or replacement of text in the buffer. +.IP +The chg_length member +identifies the number of characters in the current preedit buffer +that are affected by this call. +A positive chg_length indicates that chg_length number of characters, starting +at chg_first, must be deleted or must be replaced by text, whose length is +specified in the +.PN XIMText +structure. +.IP +A chg_length value of zero indicates that text must be inserted +right at the position specified by chg_first. +A value of zero for chg_first specifies the first character in the buffer. +.IP +chg_length and chg_first combine to identify the modification required to +the preedit buffer; beginning at chg_first, replace chg_length number of +characters with the text in the supplied +.PN XIMText +structure. For example, suppose the preedit buffer contains the string "ABCDE". +.IP +.DS I +.ft C +Text: A B C D E + ^ ^ ^ ^ ^ ^ +CharPos: 0 1 2 3 4 5 +.sp +.ft P +.DE +The CharPos in the diagram shows the location of the character position +relative to the character. +.IP +If the value of chg_first is 1 and the value of chg_length is 3, this +says to replace 3 characters beginning at character position 1 with the +string in the +.PN XIMText +structure. +Hence, BCD would be replaced by the value in the structure. +.IP +Though chg_length and chg_first are both signed integers they will +never have a negative value. +.IP \(bu 5 +The caret member +identifies the character position before which the cursor should +be placed \- after modification to the preedit buffer has been completed. +For example, if caret is zero, the cursor is at +the beginning of the buffer. If the caret is one, the cursor is between +the first and second character. +.LP +.IN "XIMText" "" @DEF@" +.sM +.Ds +.TA .5i 1.5i 3i +typedef struct _XIMText { + unsigned short length; + XIMFeedback * feedback; + Bool encoding_is_wchar; + union { + char * multi_byte; + wchar_t * wide_char; + } string; +} XIMText; +.De +.LP +.eM +The text string passed is actually a structure specifying as follows: +.IP \(bu 5 +The length member is the text length in characters. +.IP \(bu 5 +The encoding_is_wchar member is a value that indicates +if the text string is encoded in wide character or multibyte format. +The text string may be passed either as multibyte or as wide character; +the input method controls in which form data is passed. +The client's +callback routine must be able to handle data passed in either form. +.IP \(bu 5 +The string member is the text string. +.IP \(bu 5 +The feedback member indicates rendering type for each character in the +string member. +If string is NULL (indicating that only highlighting of the existing +preedit buffer should be updated), feedback points to length highlight +elements that should be applied to the existing preedit buffer, beginning +at chg_first. +.LP +The feedback member expresses the types of rendering feedback +the callback should apply when drawing text. +Rendering of the text to be drawn is specified either in generic ways +(for example, primary, secondary) or in specific ways (reverse, underline). +When generic indications are given, +the client is free to choose the rendering style. +It is necessary, however, that primary and secondary be mapped +to two distinct rendering styles. +.LP +If an input method wants to control display of the preedit string, an +input method can indicate the visibility hints using feedbacks in +a specific way. +The +.PN XIMVisibleToForward , +.PN XIMVisibleToBackward , +and +.PN XIMVisibleCenter +masks are exclusively used for these visibility hints. +The +.PN XIMVisibleToForward +mask +indicates that the preedit text is preferably displayed in the +primary draw direction from the +caret position in the preedit area forward. +The +.PN XIMVisibleToBackward +mask +indicates that the preedit text is preferably displayed from +the caret position in the preedit area backward, relative to the primary +draw direction. +The +.PN XIMVisibleCenter +mask +indicates that the preedit text is preferably displayed with +the caret position in the preedit area centered. +.LP +The insertion point of the preedit string could exist outside of +the visible area when visibility hints are used. +Only one of the +masks +is valid for the entire preedit string, and only one character +can hold one of these feedbacks for a given input context at one time. +This feedback may be OR'ed together with another highlight (such as +.PN XIMReverse ). +Only the most recently set feedback is valid, and any previous +feedback is automatically canceled. This is a hint to the client, and +the client is free to choose how to display the preedit string. +.LP +The feedback member also specifies how rendering of the text argument +should be performed. +If the feedback is NULL, +the callback should apply the same feedback as is used for the surrounding +characters in the preedit buffer; if chg_first is at a highlight boundary, +the client can choose which of the two highlights to use. +If feedback is not NULL, feedback specifies an array defining the +rendering for each +character of the string, and the length of the array is thus length. +.LP +If an input method wants to indicate that it is only updating the feedback of +the preedit text without changing the content of it, +the +.PN XIMText +structure will contain a NULL value for the string field, +the number of characters affected (relative to chg_first) +will be in the length field, +and the feedback field will point to an array of +.PN XIMFeedback . +.LP +Each element in the feedback array is a bitmask represented by a value of type +.PN XIMFeedback . +The valid mask names are as follows: +.LP +.IN "XIMReverse" "" "@DEF@" +.IN "XIMUnderline" "" "@DEF@" +.IN "XIMHighlight" "" "@DEF@" +.IN "XIMPrimary" "" "@DEF@" +.IN "XIMSecondary" "" "@DEF@" +.IN "XIMTertiary" "" "@DEF@" +.IN "XIMVisibleToForward" "" "@DEF@" +.IN "XIMVisibleToBackward" "" "@DEF@" +.IN "XIMVisibleCenter" "" "@DEF@" +.sM +.LP +.Ds 0 +typedef unsigned long XIMFeedback; +.De +.TS +lw(.5i) lw(2i) lw(2i). +T{ +#define +T} T{ +.PN XIMReverse +T} T{ +1L +T} +T{ +#define +T} T{ +.PN XIMUnderline +T} T{ +(1L<<1) +T} +T{ +#define +T} T{ +.PN XIMHighlight +T} T{ +(1L<<2) +T} +T{ +#define +T} T{ +.PN XIMPrimary +T} T{ +(1L<<5)\(dg +T} +T{ +#define +T} T{ +.PN XIMSecondary +T} T{ +(1L<<6)\(dg +T} +T{ +#define +T} T{ +.PN XIMTertiary +T} T{ +(1L<<7)\(dg +T} +T{ +#define +T} T{ +.PN XIMVisibleToForward +T} T{ +(1L<<8) +T} +T{ +#define +T} T{ +.PN XIMVisibleToBackward +T} T{ +(1L<<9) +T} +T{ +#define +T} T{ +.PN XIMVisibleCenter +T} T{ +(1L<<10) +T} +.TE +.LP +.eM +.LP +Characters drawn with the +.PN XIMReverse +highlight should be drawn by swapping the foreground and background colors +used to draw normal, unhighlighted characters. +Characters drawn with the +.PN XIMUnderline +highlight should be underlined. +Characters drawn with the +.PN XIMHighlight , +.PN XIMPrimary , +.PN XIMSecondary , +and +.PN XIMTertiary +highlights should be drawn in some unique manner that must be different +from +.PN XIMReverse +and +.PN XIMUnderline . +.FS \(dg +The values for +.PN XIMPrimary , +.PN XIMSecondary , +and +.PN XIMTertiary +were incorrectly defined in the R5 specification. +The X Consortium's X11R5 +implementation correctly implemented the values for these highlights. +The value of these highlights has been corrected in this specification +to agree with the values in the Consortium's X11R5 and X11R6 implementations. +.FE +.NH 4 +Preedit Caret Callback +.XS +\*(SN Preedit Caret Callback +.XE +.LP +An input method may have its own navigation keys to allow the user +to move the text insertion point in the preedit area +(for example, to move backward or forward). +Consequently, input method needs to indicate to the client that it +should move the text insertion point. +It then calls the PreeditCaretCallback. +.IN "PreeditCaretCallback" "" "@DEF@" +.sM +.FD 0 +void PreeditCaretCallback\^(\^\fIic\fP\^, \fIclient_data\fP\^, \fIcall_data\fP\^) +.br + XIC \fIic\fP\^; +.br + XPointer \fIclient_data\fP\^; +.br + XIMPreeditCaretCallbackStruct *\fIcall_data\fP\^; +.FN +.IP \fIic\fP 1i +Specifies the input context. +.IP \fIclient_data\fP 1i +Specifies the additional client data. +.IP \fIcall_data\fP 1i +Specifies the preedit caret information. +.LP +.eM +The input method will trigger PreeditCaretCallback +to move the text insertion point during preedit. +The call_data argument contains a pointer to an +.PN XIMPreeditCaretCallbackStruct +structure, +which indicates where the caret should be moved. +The callback must move the insertion point to its new location +and return, in field position, the new offset value from the initial position. +.LP +The +.PN XIMPreeditCaretCallbackStruct +structure is defined as follows: +.IN "XIMPreeditCaretCallbackStruct" "" "@DEF@" +.LP +.sM +.Ds 0 +.TA .5i 2.5i +.ta .5i 2.5i +typedef struct _XIMPreeditCaretCallbackStruct { + int position; /* Caret offset within preedit string */ + XIMCaretDirection direction; /* Caret moves direction */ + XIMCaretStyle style; /* Feedback of the caret */ +} XIMPreeditCaretCallbackStruct; +.De +.LP +.eM +The +.PN XIMCaretStyle +structure is defined as follows: +.LP +.IN "XIMCaretStyle" "" "@DEF@" +.sM +.Ds 0 +.TA .5i 2.5i +.ta .5i 2.5i +typedef enum { + XIMIsInvisible, /* Disable caret feedback */ + XIMIsPrimary, /* UI defined caret feedback */ + XIMIsSecondary, /* UI defined caret feedback */ +} XIMCaretStyle; +.De +.LP +.eM +The +.PN XIMCaretDirection +structure is defined as follows: +.IN "XIMCaretDirection" "" "@DEF@" +.LP +.sM +.Ds 0 +.TA .5i 2.5i +.ta .5i 2.5i +typedef enum { + XIMForwardChar, XIMBackwardChar, + XIMForwardWord, XIMBackwardWord, + XIMCaretUp, XIMCaretDown, + XIMNextLine, XIMPreviousLine, + XIMLineStart, XIMLineEnd, + XIMAbsolutePosition, + XIMDontChange, + } XIMCaretDirection; +.De +.LP +.eM +These values are defined as follows: +.IN "XIMForwardChar" "" "@DEF@" +.IN "XIMBackwardChar" "" "@DEF@" +.IN "XIMForwardWord" "" "@DEF@" +.IN "XIMBackwardWord" "" "@DEF@" +.IN "XIMCaretUp" "" "@DEF@" +.IN "XIMCaretDown" "" "@DEF@" +.TS +lw(1.5i) lw(4.25i). +T{ +.PN XIMForwardChar +T} T{ +Move the caret forward one character position. +T} +T{ +.PN XIMBackwardChar +T} T{ +Move the caret backward one character position. +T} +T{ +.PN XIMForwardWord +T} T{ +Move the caret forward one word. +T} +T{ +.PN XIMBackwardWord +T} T{ +Move the caret backward one word. +T} +T{ +.PN XIMCaretUp +T} T{ +Move the caret up one line keeping the current horizontal offset. +T} +T{ +.PN XIMCaretDown +T} T{ +Move the caret down one line keeping the current horizontal offset. +T} +T{ +.PN XIMPreviousLine +T} T{ +Move the caret to the beginning of the previous line. +T} +T{ +.PN XIMNextLine +T} T{ +Move the caret to the beginning of the next line. +T} +T{ +.PN XIMLineStart +T} T{ +Move the caret to the beginning of the current display line +that contains the caret. +T} +T{ +.PN XIMLineEnd +T} T{ +Move the caret to the end of the current display line +that contains the caret. +T} +T{ +.PN XIMAbsolutePosition +T} T{ +The callback must move to the location specified by the position field +of the callback data, indicated in characters, starting from the beginning +of the preedit text. +Hence, a value of zero means move back to the beginning of the preedit text. +T} +T{ +.PN XIMDontChange +T} T{ +The caret position does not change. +T} +.TE +.IN "XIMNextLine" "" "@DEF@" +.IN "XIMPreviousLine" "" "@DEF@" +.IN "XIMLineStart" "" "@DEF@" +.IN "XIMLineEnd" "" "@DEF@" +.IN "XIMAbsolutePosition" "" "@DEF@" +.IN "XIMDontChange" "" "@DEF@" +.NH 4 +Status Callbacks +.XS +\*(SN Status Callbacks +.XE +.LP +An input method may communicate changes in the status of an input context +(for example, created, destroyed, or focus changes) with three status +callbacks: StatusStartCallback, StatusDoneCallback, and StatusDrawCallback. +.LP +.sp +When the input context is created or gains focus, +the input method calls the StatusStartCallback callback. +.IN "StatusStartCallback" "" "@DEF@" +.sM +.FD 0 +void StatusStartCallback\^(\^\fIic\fP\^, \fIclient_data\fP\^, \fIcall_data\fP\^) +.br + XIC \fIic\fP\^; +.br + XPointer \fIclient_data\fP\^; +.br + XPointer \fIcall_data\fP\^; +.FN +.IP \fIic\fP 1i +Specifies the input context. +.IP \fIclient_data\fP 1i +Specifies the additional client data. +.IP \fIcall_data\fP 1i +Not used for this callback and always passed as NULL. +.LP +.eM +The callback should initialize appropriate data for displaying status +and for responding to StatusDrawCallback calls. +Once StatusStartCallback is called, +it will not be called again before StatusDoneCallback has been called. +.LP +.sp +When an input context +is destroyed or when it loses focus, the input method calls StatusDoneCallback. +.IN "StatusDoneCallback" "" "@DEF@" +.sM +.FD 0 +void StatusDoneCallback\^(\^\fIic\fP\^, \fIclient_data\fP\^, \fIcall_data\fP\^) +.br + XIC \fIic\fP\^; +.br + XPointer \fIclient_data\fP\^; +.br + XPointer \fIcall_data\fP\^; +.FN +.IP \fIic\fP 1i +Specifies the input context. +.IP \fIclient_data\fP 1i +Specifies the additional client data. +.IP \fIcall_data\fP 1i +Not used for this callback and always passed as NULL. +.LP +.eM +The callback may release any data allocated on +.PN StatusStart . +.LP +.sp +When an input context status has to be updated, the input method calls +StatusDrawCallback. +.IN "StatusDrawCallback" "" "@DEF@" +.sM +.FD 0 +void StatusDrawCallback\^(\^\fIic\fP\^, \fIclient_data\fP\^, \fIcall_data\fP\^) +.br + XIC \fIic\fP\^; +.br + XPointer \fIclient_data\fP\^; +.br + XIMStatusDrawCallbackStruct *\fIcall_data\fP\^; +.FN +.IP \fIic\fP 1i +Specifies the input context. +.IP \fIclient_data\fP 1i +Specifies the additional client data. +.IP \fIcall_data\fP 1i +Specifies the status drawing information. +.LP +.eM +The callback should update the status area by either drawing a string +or imaging a bitmap in the status area. +.LP +The +.PN XIMStatusDataType +and +.PN XIMStatusDrawCallbackStruct +structures are defined as follows: +.IN "XIMStatusDataType" "" "@DEF@" +.IN "XIMStatusDrawCallbackStruct" "" "@DEF@" +.LP +.sM +.Ds 0 +.TA .5i 1i 3i +.ta .5i 1i 3i +typedef enum { + XIMTextType, + XIMBitmapType, +} XIMStatusDataType; + +typedef struct _XIMStatusDrawCallbackStruct { + XIMStatusDataType type; + union { + XIMText *text; + Pixmap bitmap; + } data; +} XIMStatusDrawCallbackStruct; +.De +.LP +.eM +.LP +The feedback styles +.PN XIMVisibleToForward , +.PN XIMVisibleToBackward , +and +.PN XIMVisibleToCenter +are not relevant and will not appear in the +.PN XIMFeedback +element of the +.PN XIMText +structure. +.LP +.NH 3 +Event Filtering +.XS +\*(SN Event Filtering +.XE +.LP +Xlib provides the ability for an input method +to register a filter internal to Xlib. +This filter is called by a client (or toolkit) by calling +.PN XFilterEvent +after calling +.PN XNextEvent . +Any client that uses the +.PN XIM +interface should call +.PN XFilterEvent +to allow input methods to process their events without knowledge +of the client's dispatching mechanism. +A client's user interface policy may determine the priority +of event filters with respect to other event-handling mechanisms +(for example, modal grabs). +.LP +Clients may not know how many filters there are, if any, +and what they do. +They may only know if an event has been filtered on return of +.PN XFilterEvent . +Clients should discard filtered events. +.sp +.LP +To filter an event, use +.PN XFilterEvent . +.IN "XFilterEvent" "" "@DEF@" +.sM +.FD 0 +Bool XFilterEvent\^(\^\fIevent\fP\^, \fIw\fP\^) +.br + XEvent *\fIevent\fP\^; +.br + Window \fIw\fP\^; +.FN +.ds Ev event to filter +.IP \fIevent\fP 1i +Specifies the \*(Ev. +.ds Wi for which the filter is to be applied +.IP \fIw\fP 1i +Specifies the window \*(Wi. +.LP +.eM +If the window argument is +.PN None , +.PN XFilterEvent +applies the filter to the window specified in the +.PN XEvent +structure. +The window argument is provided so that layers above Xlib +that do event redirection can indicate to which window an event +has been redirected. +.LP +If +.PN XFilterEvent +returns +.PN True , +then some input method has filtered the event, +and the client should discard the event. +If +.PN XFilterEvent +returns +.PN False , +then the client should continue processing the event. +.LP +If a grab has occurred in the client and +.PN XFilterEvent +returns +.PN True , +the client should ungrab the keyboard. +.NH 3 +Getting Keyboard Input +.XS +\*(SN Getting Keyboard Input +.XE +.LP +To get composed input from an input method, +use +.PN XmbLookupString +or +.PN XwcLookupString . +.IN "XmbLookupString" "" "@DEF@" +.IN "XwcLookupString" "" "@DEF@" +.sM +.FD 0 +int XmbLookupString\^(\^\fIic\fP\^, \fIevent\fP\^, \fIbuffer_return\fP\^, \fIbytes_buffer\fP\^, \fIkeysym_return\fP\^, \fIstatus_return\fP\^) +.br + XIC \fIic\fP\^; +.br + XKeyPressedEvent *\fIevent\fP; +.br + char *\fIbuffer_return\fP\^; +.br + int \fIbytes_buffer\fP\^; +.br + KeySym *\fIkeysym_return\fP\^; +.br + Status *\fIstatus_return\fP\^; +.FN +.FD 0 +int XwcLookupString\^(\^\fIic\fP\^, \fIevent\fP\^, \fIbuffer_return\fP\^, \fIbytes_buffer\fP\^, \fIkeysym_return\fP\^, \fIstatus_return\fP\^) +.br + XIC \fIic\fP\^; +.br + XKeyPressedEvent *\fIevent\fP\^; +.br + wchar_t *\fIbuffer_return\fP\^; +.br + int \fIwchars_buffer\fP\^; +.br + KeySym *\fIkeysym_return\fP\^; +.br + Status *\fIstatus_return\fP\^; +.FN +.IP \fIic\fP 1i +Specifies the input context. +.ds Ev key event to be used +.IP \fIevent\fP 1i +Specifies the \*(Ev. +.IP \fIbuffer_return\fP 1i +Returns a multibyte string or wide character string (if any) +from the input method. +.IP \fIbytes_buffer\fP 1i +.br +.ns +.IP \fIwchars_buffer\fP 1i +Specifies space available in the return buffer. +.IP \fIkeysym_return\fP 1i +Returns the KeySym computed from the event if this argument is not NULL. +.IP \fIstatus_return\fP 1i +Returns a value indicating what kind of data is returned. +.LP +.eM +The +.PN XmbLookupString +and +.PN XwcLookupString +functions return the string from the input method specified +in the buffer_return argument. +If no string is returned, +the buffer_return argument is unchanged. +.LP +The KeySym into which the KeyCode from the event was mapped is returned +in the keysym_return argument if it is non-NULL and the status_return +argument indicates that a KeySym was returned. +If both a string and a KeySym are returned, +the KeySym value does not necessarily correspond to the string returned. +.LP +.PN XmbLookupString +returns the length of the string in bytes, and +.PN XwcLookupString +returns the length of the string in characters. +Both +.PN XmbLookupString +and +.PN XwcLookupString +return text in the encoding of the locale bound to the input method +of the specified input context. +.LP +Each string returned by +.PN XmbLookupString +and +.PN XwcLookupString +begins in the initial state of the encoding of the locale +(if the encoding of the locale is state-dependent). +.NT +To insure proper input processing, +it is essential that the client pass only +.PN KeyPress +events to +.PN XmbLookupString +and +.PN XwcLookupString . +Their behavior when a client passes a +.PN KeyRelease +event is undefined. +.NE +.LP +Clients should check the status_return argument before +using the other returned values. +These two functions both return a value to status_return +that indicates what has been returned in the other arguments. +The possible values returned are: +.TS +lw(1.5i) lw(4.3i). +T{ +.PN XBufferOverflow +T} T{ +The input string to be returned is too large for the supplied buffer_return. +The required size +.Pn ( XmbLookupString +in bytes; +.PN XwcLookupString +in characters) is returned as the value of the function, +and the contents of buffer_return and keysym_return are not modified. +The client should recall the function with the same event +and a buffer of adequate size to obtain the string. +T} +T{ +.PN XLookupNone +T} T{ +No consistent input has been composed so far. +The contents of buffer_return and keysym_return are not modified, +and the function returns zero. +T} +T{ +.PN XLookupChars +T} T{ +Some input characters have been composed. +They are placed in the buffer_return argument, +and the string length is returned as the value of the function. +The string is encoded in the locale bound to the input context. +The content of the keysym_return argument is not modified. +T} +T{ +.PN XLookupKeySym +T} T{ +A KeySym has been returned instead of a string +and is returned in keysym_return. +The content of the buffer_return argument is not modified, +and the function returns zero. +T} +T{ +.PN XLookupBoth +T} T{ +Both a KeySym and a string are returned; +.PN XLookupChars +and +.PN XLookupKeySym +occur simultaneously. +T} +.TE +.LP +It does not make any difference if the input context passed as an argument to +.PN XmbLookupString +and +.PN XwcLookupString +is the one currently in possession of the focus or not. +Input may have been composed within an input context before it lost the focus, +and that input may be returned on subsequent calls to +.PN XmbLookupString +or +.PN XwcLookupString +even though it does not have any more keyboard focus. +.NH 3 +Input Method Conventions +.XS +\*(SN Input Method Conventions +.XE +.LP +The input method architecture is transparent to the client. +However, clients should respect a number of conventions in order +to work properly. +Clients must also be aware of possible effects of synchronization +between input method and library in the case of a remote input server. +.NH 4 +Client Conventions +.XS +\*(SN Client Conventions +.XE +.LP +A well-behaved client (or toolkit) should first query the input method style. +If the client cannot satisfy the requirements of the supported styles +(in terms of geometry management or callbacks), +it should negotiate with the user continuation of the program +or raise an exception or error of some sort. +.NH 4 +Synchronization Conventions +.XS +\*(SN Synchronization Conventions +.XE +.LP +A +.PN KeyPress +event with a KeyCode of zero is used exclusively as a +signal that an input method has composed input that can be returned by +.PN XmbLookupString +or +.PN XwcLookupString . +No other use is made of a +.PN KeyPress +event with KeyCode of zero. +.LP +Such an event may be generated by either a front-end +or a back-end input method in an implementation-dependent manner. +Some possible ways to generate this event include: +.IP \(bu 5 +A synthetic event sent by an input method server +.IP \(bu 5 +An artificial event created by a input method filter and pushed +onto a client's event queue +.IP \(bu 5 +A +.PN KeyPress +event whose KeyCode value is modified by an input method filter +.LP +When callback support is specified by the client, +input methods will not take action unless they explicitly +called back the client and obtained no response +(the callback is not specified or returned invalid data). +.NH 2 +String Constants +.XS +\*(SN String Constants +.XE +.LP +The following symbols for string constants are defined in +.hN X11/Xlib.h . +Although they are shown here with particular macro definitions, +they may be implemented as macros, as global symbols, or as a +mixture of the two. The string pointer value itself +is not significant; clients must not assume that inequality of two +values implies inequality of the actual string data. +.IN "XNVaNestedList" "" "@DEF@" +.IN "XNSeparatorofNestedList "" "@DEF@" +.IN "XNQueryInputStyle" "" "@DEF@" +.IN "XNClientWindow" "" "@DEF@" +.IN "XNInputStyle" "" "@DEF@" +.IN "XNFocusWindow" "" "@DEF@" +.IN "XNResourceName" "" "@DEF@" +.IN "XNResourceClass" "" "@DEF@" +.IN "XNGeometryCallback" "" "@DEF@" +.IN "XNDestroyCallback" "" "@DEF@" +.IN "XNFilterEvents" "" "@DEF@" +.IN "XNPreeditStartCallback" "" "@DEF@" +.IN "XNPreeditDoneCallback" "" "@DEF@" +.IN "XNPreeditDrawCallback" "" "@DEF@" +.IN "XNPreeditCaretCallback" "" "@DEF@" +.IN "XNPreeditStateNotifyCallback" "" "@DEF@" +.IN "XNPreeditAttributes" "" "@DEF@" +.IN "XNStatusStartCallback" "" "@DEF@" +.IN "XNStatusDoneCallback" "" "@DEF@" +.IN "XNStatusDrawCallback" "" "@DEF@" +.IN "XNStatusAttributes" "" "@DEF@" +.IN "XNArea" "" "@DEF@" +.IN "XNAreaNeeded" "" "@DEF@" +.IN "XNSpotLocation" "" "@DEF@" +.IN "XNColormap" "" "@DEF@" +.IN "XNStdColormap" "" "@DEF@" +.IN "XNForeground" "" "@DEF@" +.IN "XNBackground" "" "@DEF@" +.IN "XNBackgroundPixmap" "" "@DEF@" +.IN "XNFontSet" "" "@DEF@" +.IN "XNLineSpace" "" "@DEF@" +.IN "XNCursor" "" "@DEF@" +.TS +lw(.5i) lw(2.75i) lw(2.5i). +T{ +#define +T} T{ +.PN XNVaNestedList +T} T{ +"XNVaNestedList" +T} +T{ +#define +T} T{ +.PN XNSeparatorofNestedList +T} T{ +"separatorofNestedList" +T} +T{ +#define +T} T{ +.PN XNQueryInputStyle +T} T{ +"queryInputStyle" +T} +T{ +#define +T} T{ +.PN XNClientWindow +T} T{ +"clientWindow" +T} +T{ +#define +T} T{ +.PN XNInputStyle +T} T{ +"inputStyle" +T} +T{ +#define +T} T{ +.PN XNFocusWindow +T} T{ +"focusWindow" +T} +T{ +#define +T} T{ +.PN XNResourceName +T} T{ +"resourceName" +T} +T{ +#define +T} T{ +.PN XNResourceClass +T} T{ +"resourceClass" +T} +T{ +#define +T} T{ +.PN XNGeometryCallback +T} T{ +"geometryCallback" +T} +T{ +#define +T} T{ +.PN XNDestroyCallback +T} T{ +"destroyCallback" +T} +T{ +#define +T} T{ +.PN XNFilterEvents +T} T{ +"filterEvents" +T} +T{ +#define +T} T{ +.PN XNPreeditStartCallback +T} T{ +"preeditStartCallback" +T} +T{ +#define +T} T{ +.PN XNPreeditDoneCallback +T} T{ +"preeditDoneCallback" +T} +T{ +#define +T} T{ +.PN XNPreeditDrawCallback +T} T{ +"preeditDrawCallback" +T} +T{ +#define +T} T{ +.PN XNPreeditCaretCallback +T} T{ +"preeditCaretCallback" +T} +T{ +#define +T} T{ +.PN XNPreeditStateNotifyCallback +T} T{ +"preeditStateNotifyCallback" +T} +T{ +#define +T} T{ +.PN XNPreeditAttributes +T} T{ +"preeditAttributes" +T} +.TE +.sp -1 +.TS +lw(.5i) lw(2.75i) lw(2.5i). +T{ +#define +T} T{ +.PN XNStatusStartCallback +T} T{ +"statusStartCallback" +T} +T{ +#define +T} T{ +.PN XNStatusDoneCallback +T} T{ +"statusDoneCallback" +T} +T{ +#define +T} T{ +.PN XNStatusDrawCallback +T} T{ +"statusDrawCallback" +T} +T{ +#define +T} T{ +.PN XNStatusAttributes +T} T{ +"statusAttributes" +T} +T{ +#define +T} T{ +.PN XNArea +T} T{ +"area" +T} +T{ +#define +T} T{ +.PN XNAreaNeeded +T} T{ +"areaNeeded" +T} +T{ +#define +T} T{ +.PN XNSpotLocation +T} T{ +"spotLocation" +T} +T{ +#define +T} T{ +.PN XNColormap +T} T{ +"colorMap" +T} +T{ +#define +T} T{ +.PN XNStdColormap +T} T{ +"stdColorMap" +T} +T{ +#define +T} T{ +.PN XNForeground +T} T{ +"foreground" +T} +T{ +#define +T} T{ +.PN XNBackground +T} T{ +"background" +T} +T{ +#define +T} T{ +.PN XNBackgroundPixmap +T} T{ +"backgroundPixmap" +T} +T{ +#define +T} T{ +.PN XNFontSet +T} T{ +"fontSet" +T} +T{ +#define +T} T{ +.PN XNLineSpace +T} T{ +"lineSpace" +T} +T{ +#define +T} T{ +.PN XNCursor +T} T{ +"cursor" +T} +.TE +.sp -1 +.TS +lw(.5i) lw(2.75i) lw(2.5i). +T{ +#define +T} T{ +.PN XNQueryIMValuesList +T} T{ +"queryIMValuesList" +T} +T{ +#define +T} T{ +.PN XNQueryICValuesList +T} T{ +"queryICValuesList" +T} +T{ +#define +T} T{ +.PN XNStringConversionCallback +T} T{ +"stringConversionCallback" +T} +T{ +#define +T} T{ +.PN XNStringConversion +T} T{ +"stringConversion" +T} +T{ +#define +T} T{ +.PN XNResetState +T} T{ +"resetState" +T} +T{ +#define +T} T{ +.PN XNHotKey +T} T{ +"hotkey" +T} +T{ +#define +T} T{ +.PN XNHotKeyState +T} T{ +"hotkeyState" +T} +T{ +#define +T} T{ +.PN XNPreeditState +T} T{ +"preeditState" +T} +T{ +#define +T} T{ +.PN XNVisiblePosition +T} T{ +"visiblePosition" +T} +T{ +#define +T} T{ +.PN XNR6PreeditCallbackBehavior +T} T{ +"r6PreeditCallback" +T} +.TE +.sp -1 +.IN "XNQueryIMValuesList" "" "@DEF@" +.IN "XNQueryICValuesList" "" "@DEF@" +.IN "XNStringConversionCallback" "" "@DEF@" +.IN "XNStringConversion" "" "@DEF@" +.IN "XNResetState" "" "@DEF@" +.IN "XNHotKey" "" "@DEF@" +.IN "XNHotKeyState" "" "@DEF@" +.IN "XNPreeditState" "" "@DEF@" +.IN "XNVisiblePosition" "" "@DEF@" +.IN "XNR6PreeditCallbackBehavior" "" "@DEF@" +.TS +lw(.5i) lw(2.75i) lw(2.5i). +T{ +#define +T} T{ +.PN XNRequiredCharSet +T} T{ +"requiredCharSet" +T} +T{ +#define +T} T{ +.PN XNQueryOrientation +T} T{ +"queryOrientation" +T} +T{ +#define +T} T{ +.PN XNDirectionalDependentDrawing +T} T{ +"directionalDependentDrawing" +T} +T{ +#define +T} T{ +.PN XNContextualDrawing +T} T{ +"contextualDrawing" +T} +T{ +#define +T} T{ +.PN XNBaseFontName +T} T{ +"baseFontName" +T} +T{ +#define +T} T{ +.PN XNMissingCharSet +T} T{ +"missingCharSet" +T} +T{ +#define +T} T{ +.PN XNDefaultString +T} T{ +"defaultString" +T} +T{ +#define +T} T{ +.PN XNOrientation +T} T{ +"orientation" +T} +T{ +#define +T} T{ +.PN XNFontInfo +T} T{ +"fontInfo" +T} +T{ +#define +T} T{ +.PN XNOMAutomatic +T} T{ +"omAutomatic" +T} +.TE +.IN "XNRequiredCharSet" "" "@DEF@" +.IN "XNQueryOrientation" "" "@DEF@" +.IN "XNDirectionalDependentDrawing" "" "@DEF@" +.IN "XNContextualDrawing" "" "@DEF@" +.IN "XNBaseFontName" "" "@DEF@" +.IN "XNMissingCharSet" "" "@DEF@" +.IN "XNDefaultString" "" "@DEF@" +.IN "XNOrientation" "" "@DEF@" +.IN "XNFontInfo" "" "@DEF@" +.IN "XNOMAutomatic" "" "@DEF@" +.bp diff --git a/libX11/specs/libX11/CH14 b/libX11/specs/libX11/CH14 new file mode 100644 index 000000000..34c09da8b --- /dev/null +++ b/libX11/specs/libX11/CH14 @@ -0,0 +1,3590 @@ +.\" Copyright \(co 1985, 1986, 1987, 1988, 1989, 1990, 1991, 1994, 1996 X Consortium +.\" +.\" 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 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 X CONSORTIUM 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 X Consortium 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 X Consortium. +.\" +.\" Copyright \(co 1985, 1986, 1987, 1988, 1989, 1990, 1991 by +.\" Digital Equipment Corporation +.\" +.\" Portions Copyright \(co 1990, 1991 by +.\" Tektronix, Inc. +.\" +.\" Permission to use, copy, modify and distribute this documentation for +.\" any purpose and without fee is hereby granted, provided that the above +.\" copyright notice appears in all copies and that both that copyright notice +.\" and this permission notice appear in all copies, and that the names of +.\" Digital and Tektronix not be used in in advertising or publicity pertaining +.\" to this documentation without specific, written prior permission. +.\" Digital and Tektronix makes no representations about the suitability +.\" of this documentation for any purpose. +.\" It is provided ``as is'' without express or implied warranty. +.\" +\& +.sp 1 +.ce 3 +\s+1\fBChapter 14\fP\s-1 + +\s+1\fBInter-Client Communication Functions\fP\s-1 +.sp 2 +.nr H1 14 +.nr H2 0 +.nr H3 0 +.nr H4 0 +.nr H5 0 +.na +.LP +.XS +Chapter 14: Inter-Client Communication Functions +.XE +The \fIInter-Client Communication Conventions Manual\fP, +hereafter referred to as the ICCCM, details the +X Consortium approved conventions that govern inter-client communications. +These conventions ensure peer-to-peer client cooperation in the use +of selections, cut buffers, and shared resources as well as client cooperation +with window and session managers. +For further information, +see the \fIInter-Client Communication Conventions Manual\fP. +.LP +Xlib provides a number of standard properties and programming interfaces +that are ICCCM compliant. +The predefined atoms for some of these properties are defined in the +.hN X11/Xatom.h +header file, where +to avoid name conflicts with user symbols their +.PN #define +name has an XA_ prefix. +For further information about atoms and properties, +see section 4.3. +.LP +Xlib's selection and cut buffer mechanisms provide the primary programming +interfaces by which peer client applications communicate with each other +(see sections 4.5 and 16.6). +The functions discussed in this chapter provide +the primary programming interfaces by which client applications communicate +with their window and session managers as well as share standard colormaps. +.LP +The standard properties that are of special interest for communicating +with window and session managers are: +.IN "Atom" "predefined" +.TS H +lw(2i) lw(1.1i) lw(.4i) lw(2.25i) +lw(2i) lw(1.1i) cw(.4i) lw(2.25i). +_ +.sp 6p +.B +Name Type Format Description +.sp 6p +_ +.TH +.R +T{ +\s-1WM_CLASS\s+1 +T} T{ +\s-1STRING\s+1 +T} T{ +8 +T} T{ +Set by application programs to allow window and session +managers to obtain the application's resources from the resource database. +T} +.sp 6p +T{ +\s-1WM_CLIENT_MACHINE\s+1 +T} T{ +\s-1TEXT\s+1 +T} T{ +T} T{ +The string name of the machine on which the client application is running. +T} +.sp 6p +T{ +\s-1WM_COLORMAP_WINDOWS\s+1 +T} T{ +\s-1WINDOW\s+1 +T} T{ +32 +T} T{ +The list of window IDs that may need a different colormap +from that of their top-level window. +T} +.sp 6p +T{ +\s-1WM_COMMAND\s+1 +T} T{ +\s-1TEXT\s+1 +T} T{ +T} T{ +The command and arguments, null-separated, used to invoke the +application. +T} +.sp 6p +T{ +\s-1WM_HINTS\s+1 +T} T{ +\s-1WM_HINTS\s+1 +T} T{ +32 +T} T{ +Additional hints set by the client for use by the window manager. +The C type of this property is +.PN XWMHints . +T} +.sp 6p +T{ +\s-1WM_ICON_NAME\s+1 +T} T{ +\s-1TEXT\s+1 +T} T{ +T} T{ +The name to be used in an icon. +T} +.sp 6p +T{ +\s-1WM_ICON_SIZE\s+1 +T} T{ +\s-1WM_ICON_SIZE\s+1 +T} T{ +32 +T} T{ +The window manager may set this property on the root window to +specify the icon sizes it supports. +The C type of this property is +.PN XIconSize . +T} +.sp 6p +T{ +\s-1WM_NAME\s+1 +T} T{ +\s-1TEXT\s+1 +T} T{ +T} T{ +The name of the application. +T} +.sp 6p +T{ +\s-1WM_NORMAL_HINTS\s+1 +T} T{ +\s-1WM_SIZE_HINTS\s+1 +T} T{ +32 +T} T{ +Size hints for a window in its normal state. +The C type of this property is +.PN XSizeHints . +T} +.sp 6p +T{ +\s-1WM_PROTOCOLS\s+1 +T} T{ +\s-1ATOM\s+1 +T} T{ +32 +T} T{ +List of atoms that identify the communications protocols between the +client and window manager in which the client is willing to participate. +T} +.sp 6p +T{ +\s-1WM_STATE\s+1 +T} T{ +\s-1WM_STATE\s+1 +T} T{ +32 +T} T{ +Intended for communication between window and session managers only. +T} +.sp 6p +T{ +\s-1WM_TRANSIENT_FOR\s+1 +T} T{ +\s-1WINDOW\s+1 +T} T{ +32 +T} T{ +Set by application programs to indicate to the window manager that a transient +top-level window, such as a dialog box. +T} +.sp 6p +_ +.TE +.LP +The remainder of this chapter discusses: +.IP \(bu 5 +Client to window manager communication +.IP \(bu 5 +Client to session manager communication +.IP \(bu 5 +Standard colormaps +.NH 2 +Client to Window Manager Communication +.XS +\*(SN Client to Window Manager Communication +.XE +.LP +This section discusses how to: +.IP \(bu 5 +Manipulate top-level windows +.IP \(bu 5 +Convert string lists +.IP \(bu 5 +Set and read text properties +.IP \(bu 5 +Set and read the WM_NAME property +.IP \(bu 5 +Set and read the WM_ICON_NAME property +.IP \(bu 5 +Set and read the WM_HINTS property +.IP \(bu 5 +Set and read the WM_NORMAL_HINTS property +.IP \(bu 5 +Set and read the WM_CLASS property +.IP \(bu 5 +Set and read the WM_TRANSIENT_FOR property +.IP \(bu 5 +Set and read the WM_PROTOCOLS property +.IP \(bu 5 +Set and read the WM_COLORMAP_WINDOWS property +.IP \(bu 5 +Set and read the WM_ICON_SIZE property +.IP \(bu 5 +Use window manager convenience functions +.NH 3 +Manipulating Top-Level Windows +.XS +\*(SN Manipulating Top-Level Windows +.XE +.LP +Xlib provides functions that you can use to change the visibility or size +of top-level windows (that is, those that were created as children +of the root window). +Note that the subwindows that you create are ignored by window managers. +Therefore, +you should use the basic window functions described in chapter 3 +to manipulate your application's subwindows. +.LP +To request that a top-level window be iconified, use +.PN XIconifyWindow . +.IN "XIconifyWindow" "" "@DEF@" +.sM +.FD 0 +Status XIconifyWindow\^(\^\fIdisplay\fP, \fIw\fP, \fIscreen_number\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP; +.br + int \fIscreen_number\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fIscreen_number\fP 1i +Specifies the appropriate screen number on the host server. +.LP +.eM +The +.PN XIconifyWindow +function sends a WM_CHANGE_STATE +.PN ClientMessage +event with a format of 32 and a first data element of +.PN IconicState +(as described in section 4.1.4 of the +\fIInter-Client Communication Conventions Manual\fP) +and a window of w +to the root window of the specified screen +with an event mask set to +.PN SubstructureNotifyMask | +.PN SubstructureRedirectMask . +Window managers may elect to receive this message and +if the window is in its normal state, +may treat it as a request to change the window's state from normal to iconic. +If the WM_CHANGE_STATE property cannot be interned, +.PN XIconifyWindow +does not send a message and returns a zero status. +It returns a nonzero status if the client message is sent successfully; +otherwise, it returns a zero status. +.sp +.LP +To request that a top-level window be withdrawn, use +.PN XWithdrawWindow . +.IN "XWithdrawWindow" "" "@DEF@" +.sM +.FD 0 +Status XWithdrawWindow\^(\^\fIdisplay\fP, \fIw\fP, \fIscreen_number\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + int \fIscreen_number\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fIscreen_number\fP 1i +Specifies the appropriate screen number on the host server. +.LP +.eM +The +.PN XWithdrawWindow +function unmaps the specified window +and sends a synthetic +.PN UnmapNotify +event to the root window of the specified screen. +Window managers may elect to receive this message +and may treat it as a request to change the window's state to withdrawn. +When a window is in the withdrawn state, +neither its normal nor its iconic representations is visible. +It returns a nonzero status if the +.PN UnmapNotify +event is successfully sent; +otherwise, it returns a zero status. +.LP +.PN XWithdrawWindow +can generate a +.PN BadWindow +error. +.sp +.LP +To request that a top-level window be reconfigured, use +.PN XReconfigureWMWindow . +.IN "XReconfigureWMWindow" "" "@DEF@" +.sM +.FD 0 +Status XReconfigureWMWindow\^(\^\fIdisplay\fP, \fIw\fP, \fIscreen_number\fP, \ +\fIvalue_mask\fP, \fIvalues\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + int \fIscreen_number\fP\^; +.br + unsigned int \fIvalue_mask\fP\^; +.br + XWindowChanges *\fIvalues\fP; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fIscreen_number\fP 1i +Specifies the appropriate screen number on the host server. +.IP \fIvalue_mask\fP 1i +Specifies which values are to be set using information in +the values structure. +This mask is the bitwise inclusive OR of the valid configure window values bits. +.IP \fIvalues\fP 1i +Specifies the +.PN XWindowChanges +structure. +.LP +.eM +The +.PN XReconfigureWMWindow +function issues a +.PN ConfigureWindow +request on the specified top-level window. +If the stacking mode is changed and the request fails with a +.PN BadMatch +error, +the error is trapped by Xlib and a synthetic +.PN ConfigureRequestEvent +containing the same configuration parameters is sent to the root +of the specified window. +Window managers may elect to receive this event +and treat it as a request to reconfigure the indicated window. +It returns a nonzero status if the request or event is successfully sent; +otherwise, it returns a zero status. +.LP +.PN XReconfigureWMWindow +can generate +.PN BadValue +and +.PN BadWindow +errors. +.NH 3 +Converting String Lists +.XS +\*(SN Converting String Lists +.XE +.LP +Many of the text properties allow a variety of types and formats. +Because the data stored in these properties are not +simple null-terminated strings, an +.PN XTextProperty +structure is used to describe the encoding, type, and length of the text +as well as its value. +The +.PN XTextProperty +structure contains: +.IN "XTextProperty" "" "@DEF@" +.sM +.Ds 0 +.TA .5i 2.5i +.ta .5i 2.5i +typedef struct { + unsigned char *value; /* property data */ + Atom encoding; /* type of property */ + int format; /* 8, 16, or 32 */ + unsigned long nitems; /* number of items in value */ +} XTextProperty; +.De +.LP +.eM +Xlib provides functions to convert localized text to or from encodings +that support the inter-client communication conventions for text. +In addition, functions are provided for converting between lists of pointers +to character strings and text properties in the STRING encoding. +.LP +The functions for localized text return a signed integer error status +that encodes +.PN Success +as zero, specific error conditions as negative numbers, and partial conversion +as a count of unconvertible characters. +.LP +.IN "XICCEncodingStyle" "" "@DEF@" +.sM +.TS +lw(.5i) lw(2i) lw(2.5i). +T{ +#define +T} T{ +.PN XNoMemory +T} T{ +\-1 +T} +T{ +#define +T} T{ +.PN XLocaleNotSupported +T} T{ +\-2 +T} +T{ +#define +T} T{ +.PN XConverterNotFound +T} T{ +\-3 +T} +.TE +.Ds 0 +.TA .5i 2.5i +.ta .5i 2.5i +typedef enum { + XStringStyle, /* STRING */ + XCompoundTextStyle, /* COMPOUND_TEXT */ + XTextStyle, /* text in owner's encoding (current locale) */ + XStdICCTextStyle /* STRING, else COMPOUND_TEXT */ +} XICCEncodingStyle; +.De +.LP +.eM +.sp +.LP +To convert a list of text strings to an +.PN XTextProperty +structure, use +.PN XmbTextListToTextProperty +or +.PN XwcTextListToTextProperty . +.IN "XmbTextListToTextProperty" "" "@DEF@" +.IN "XwcTextListToTextProperty" "" "@DEF@" +.sM +.FD 0 +int XmbTextListToTextProperty\^(\^\fIdisplay\fP\^, \fIlist\fP\^, \fIcount\fP\^, \fIstyle\fP\^, \fItext_prop_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + char **\fIlist\fP\^; +.br + int \fIcount\fP\^; +.br + XICCEncodingStyle \fIstyle\fP\^; +.br + XTextProperty *\fItext_prop_return\fP\^; +.FN +.FD 0 +int XwcTextListToTextProperty\^(\^\fIdisplay\fP\^, \fIlist\fP\^, \fIcount\fP\^, \fIstyle\fP\^, \fItext_prop_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + wchar_t **\fIlist\fP\^; +.br + int \fIcount\fP\^; +.br + XICCEncodingStyle \fIstyle\fP\^; +.br + XTextProperty *\fItext_prop_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIlist\fP 1i +Specifies a list of null-terminated character strings. +.IP \fIcount\fP 1i +Specifies the number of strings specified. +.IP \fIstyle\fP 1i +Specifies the manner in which the property is encoded. +.IP \fItext_prop_return\fP 1i +Returns the +.PN XTextProperty +structure. +.LP +.eM +The +.PN XmbTextListToTextProperty +and +.PN XwcTextListToTextProperty +functions set the specified +.PN XTextProperty +value to a set of null-separated elements representing the concatenation +of the specified list of null-terminated text strings. +A final terminating null is stored at the end of the value field +of text_prop_return but is not included in the nitems member. +.LP +The functions set the encoding field of text_prop_return to an +.PN Atom +for the specified display +naming the encoding determined by the specified style +and convert the specified text list to this encoding for storage in +the text_prop_return value field. +If the style +.PN XStringStyle +or +.PN XCompoundTextStyle +is specified, +this encoding is ``STRING'' or ``COMPOUND_TEXT'', respectively. +If the style +.PN XTextStyle +is specified, +this encoding is the encoding of the current locale. +If the style +.PN XStdICCTextStyle +is specified, +this encoding is ``STRING'' if the text is fully convertible to STRING, +else ``COMPOUND_TEXT''. +.LP +If insufficient memory is available for the new value string, +the functions return +.PN XNoMemory . +If the current locale is not supported, +the functions return +.PN XLocaleNotSupported . +In both of these error cases, +the functions do not set text_prop_return. +.LP +To determine if the functions are guaranteed not to return +.PN XLocaleNotSupported , +use +.PN XSupportsLocale . +.LP +If the supplied text is not fully convertible to the specified encoding, +the functions return the number of unconvertible characters. +Each unconvertible character is converted to an implementation-defined and +encoding-specific default string. +Otherwise, the functions return +.PN Success . +Note that full convertibility to all styles except +.PN XStringStyle +is guaranteed. +.LP +To free the storage for the value field, use +.PN XFree . +.sp +.LP +To obtain a list of text strings from an +.PN XTextProperty +structure, use +.PN XmbTextPropertyToTextList +or +.PN XwcTextPropertyToTextList . +.IN "XmbTextPropertyToTextList" "" "@DEF@" +.IN "XwcTextPropertyToTextList" "" "@DEF@" +.sM +.FD 0 +int XmbTextPropertyToTextList\^(\^\fIdisplay\fP\^, \fItext_prop\fP\^, \fIlist_return\fP\^, \fIcount_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + XTextProperty *\fItext_prop\fP\^; +.br + char ***\fIlist_return\fP\^; +.br + int *\fIcount_return\fP\^; +.FN +.FD 0 +int XwcTextPropertyToTextList\^(\^\fIdisplay\fP\^, \fItext_prop\fP\^, \fIlist_return\fP\^, \fIcount_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + XTextProperty *\fItext_prop\fP\^; +.br + wchar_t ***\fIlist_return\fP\^; +.br + int *\fIcount_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fItext_prop\fP 1i +Specifies the +.PN XTextProperty +structure to be used. +.IP \fIlist_return\fP 1i +Returns a list of null-terminated character strings. +.ds Cn strings +.IP \fIcount_return\fP 1i +Returns the number of \*(Cn. +.LP +.eM +The +.PN XmbTextPropertyToTextList +and +.PN XwcTextPropertyToTextList +functions return a list of text strings in the current locale representing the +null-separated elements of the specified +.PN XTextProperty +structure. +The data in text_prop must be format 8. +.LP +Multiple elements of the property (for example, the strings in a disjoint +text selection) are separated by a null byte. +The contents of the property are not required to be null-terminated; +any terminating null should not be included in text_prop.nitems. +.LP +If insufficient memory is available for the list and its elements, +.PN XmbTextPropertyToTextList +and +.PN XwcTextPropertyToTextList +return +.PN XNoMemory . +If the current locale is not supported, +the functions return +.PN XLocaleNotSupported . +Otherwise, if the encoding field of text_prop is not convertible +to the encoding of the current locale, +the functions return +.PN XConverterNotFound . +For supported locales, +existence of a converter from COMPOUND_TEXT, STRING +or the encoding of the current locale is guaranteed if +.PN XSupportsLocale +returns +.PN True +for the current locale (but the actual text +may contain unconvertible characters). +Conversion of other encodings is implementation-dependent. +In all of these error cases, +the functions do not set any return values. +.LP +Otherwise, +.PN XmbTextPropertyToTextList +and +.PN XwcTextPropertyToTextList +return the list of null-terminated text strings to list_return +and the number of text strings to count_return. +.LP +If the value field of text_prop is not fully convertible to the encoding of +the current locale, +the functions return the number of unconvertible characters. +Each unconvertible character is converted to a string in the +current locale that is specific to the current locale. +To obtain the value of this string, +use +.PN XDefaultString . +Otherwise, +.PN XmbTextPropertyToTextList +and +.PN XwcTextPropertyToTextList +return +.PN Success . +.LP +To free the storage for the list and its contents returned by +.PN XmbTextPropertyToTextList , +use +.PN XFreeStringList . +To free the storage for the list and its contents returned by +.PN XwcTextPropertyToTextList , +use +.PN XwcFreeStringList . +.sp +.LP +To free the in-memory data associated with the specified +wide character string list, use +.PN XwcFreeStringList . +.IN "XwcFreeStringList" "" "@DEF@" +.sM +.FD 0 +void XwcFreeStringList\^(\^\fIlist\fP\^) +.br + wchar_t **\fIlist\fP\^; +.FN +.IP \fIlist\fP 1i +Specifies the list of strings to be freed. +.LP +.eM +The +.PN XwcFreeStringList +function frees memory allocated by +.PN XwcTextPropertyToTextList . +.sp +.LP +To obtain the default string for text conversion in the current locale, +use +.PN XDefaultString . +.IN "XDefaultString" "" "@DEF@" +.sM +.FD 0 +char *XDefaultString\^(\|) +.FN +.LP +.eM +The +.PN XDefaultString +function returns the default string used by Xlib for text conversion +(for example, in +.PN XmbTextPropertyToTextList ). +The default string is the string in the current locale that is output +when an unconvertible character is found during text conversion. +If the string returned by +.PN XDefaultString +is the empty string ("\^"), +no character is output in the converted text. +.PN XDefaultString +does not return NULL. +.LP +The string returned by +.PN XDefaultString +is independent of the default string for text drawing; +see +.PN XCreateFontSet +to obtain the default string for an +.PN XFontSet . +.LP +The behavior when an invalid codepoint is supplied to any Xlib function is +undefined. +.LP +The returned string is null-terminated. +It is owned by Xlib and should not be modified or freed by the client. +It may be freed after the current locale is changed. +Until freed, it will not be modified by Xlib. +.sp +.LP +To set the specified list of strings in the STRING encoding to a +.PN XTextProperty +structure, use +.PN XStringListToTextProperty . +.IN "XStringListToTextProperty" "" "@DEF@" +.sM +.FD 0 +Status XStringListToTextProperty\^(\^\fIlist\fP, \fIcount\fP, \ +\fItext_prop_return\fP\^) +.br + char **\fIlist\fP\^; +.br + int \fIcount\fP\^; +.br + XTextProperty *\fItext_prop_return\fP\^; +.FN +.IP \fIlist\fP 1i +Specifies a list of null-terminated character strings. +.ds Cn strings +.IP \fIcount\fP 1i +Specifies the number of \*(Cn. +.IP \fItext_prop_return\fP 1i +Returns the +.PN XTextProperty +structure. +.LP +.eM +The +.PN XStringListToTextProperty +function sets the specified +.PN XTextProperty +to be of type STRING (format 8) with a value representing the +concatenation of the specified list of null-separated character strings. +An extra null byte (which is not included in the nitems member) +is stored at the end of the value field of text_prop_return. +The strings are assumed (without verification) to be in the STRING encoding. +If insufficient memory is available for the new value string, +.PN XStringListToTextProperty +does not set any fields in the +.PN XTextProperty +structure and returns a zero status. +Otherwise, it returns a nonzero status. +To free the storage for the value field, use +.PN XFree . +.sp +.LP +To obtain a list of strings from a specified +.PN XTextProperty +structure in the STRING encoding, use +.PN XTextPropertyToStringList . +.IN "XTextPropertyToStringList" "" "@DEF@" +.sM +.FD 0 +Status XTextPropertyToStringList\^(\^\fItext_prop\fP, \fIlist_return\fP, \ +\fIcount_return\fP\^) +.br + XTextProperty *\fItext_prop\fP\^; +.br + char ***\fIlist_return\fP\^; +.br + int *\fIcount_return\fP\^; +.FN +.IP \fItext_prop\fP 1i +Specifies the +.PN XTextProperty +structure to be used. +.IP \fIlist_return\fP 1i +Returns a list of null-terminated character strings. +.ds Cn strings +.IP \fIcount_return\fP 1i +Returns the number of \*(Cn. +.LP +.eM +The +.PN XTextPropertyToStringList +function returns a list of strings representing the null-separated elements +of the specified +.PN XTextProperty +structure. +The data in text_prop must be of type STRING and format 8. +Multiple elements of the property +(for example, the strings in a disjoint text selection) +are separated by NULL (encoding 0). +The contents of the property are not null-terminated. +If insufficient memory is available for the list and its elements, +.PN XTextPropertyToStringList +sets no return values and returns a zero status. +Otherwise, it returns a nonzero status. +To free the storage for the list and its contents, use +.PN XFreeStringList . +.sp +.LP +To free the in-memory data associated with the specified string list, use +.PN XFreeStringList . +.IN "XFreeStringList" "" "@DEF@" +.sM +.FD 0 +void XFreeStringList\^(\^\fIlist\fP\^) +.br + char **\fIlist\fP\^; +.FN +.IP \fIlist\fP 1i +Specifies the list of strings to be freed. +.LP +.eM +The +.PN XFreeStringList +function releases memory allocated by +.PN XmbTextPropertyToTextList +and +.PN XTextPropertyToStringList +and the missing charset list allocated by +.PN XCreateFontSet . +.NH 3 +Setting and Reading Text Properties +.XS +\*(SN Setting and Reading Text Properties +.XE +.LP +Xlib provides two functions that you can use to set and read +the text properties for a given window. +You can use these functions to set and read those properties of type TEXT +(WM_NAME, WM_ICON_NAME, WM_COMMAND, and WM_CLIENT_MACHINE). +In addition, +Xlib provides separate convenience functions that you can use to set each +of these properties. +For further information about these convenience functions, +see sections 14.1.4, 14.1.5, 14.2.1, and 14.2.2, respectively. +.sp +.LP +To set one of a window's text properties, use +.PN XSetTextProperty . +.IN "XSetTextProperty" "" "@DEF@" +.sM +.FD 0 +void XSetTextProperty\^(\^\fIdisplay\fP, \fIw\fP, \fItext_prop\fP, \ +\fIproperty\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + XTextProperty *\fItext_prop\fP\^; +.br + Atom \fIproperty\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fItext_prop\fP 1i +Specifies the +.PN XTextProperty +structure to be used. +.IP \fIproperty\fP 1i +Specifies the property name. +.LP +.eM +The +.PN XSetTextProperty +function replaces the existing specified property for the named window +with the data, type, format, and number of items determined +by the value field, the encoding field, the format field, +and the nitems field, respectively, of the specified +.PN XTextProperty +structure. +If the property does not already exist, +.PN XSetTextProperty +sets it for the specified window. +.LP +.PN XSetTextProperty +can generate +.PN BadAlloc , +.PN BadAtom , +.PN BadValue , +and +.PN BadWindow +errors. +.sp +.LP +To read one of a window's text properties, use +.PN XGetTextProperty . +.IN "XGetTextProperty" "" "@DEF@" +.sM +.FD 0 +Status XGetTextProperty\^(\^\fIdisplay\fP, \fIw\fP, \fItext_prop_return\fP, \ +\fIproperty\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + XTextProperty *\fItext_prop_return\fP\^; +.br + Atom \fIproperty\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fItext_prop_return\fP 1i +Returns the +.PN XTextProperty +structure. +.IP \fIproperty\fP 1i +Specifies the property name. +.LP +.eM +The +.PN XGetTextProperty +function reads the specified property from the window +and stores the data in the returned +.PN XTextProperty +structure. +It stores the data in the value field, +the type of the data in the encoding field, +the format of the data in the format field, +and the number of items of data in the nitems field. +An extra byte containing null (which is not included in the nitems member) +is stored at the end of the value field of text_prop_return. +The particular interpretation of the property's encoding +and data as text is left to the calling application. +If the specified property does not exist on the window, +.PN XGetTextProperty +sets the value field to NULL, +the encoding field to +.PN None , +the format field to zero, +and the nitems field to zero. +.LP +If it was able to read and store the data in the +.PN XTextProperty +structure, +.PN XGetTextProperty +returns a nonzero status; +otherwise, it returns a zero status. +.LP +.PN XGetTextProperty +can generate +.PN BadAtom +and +.PN BadWindow +errors. +.NH 3 +Setting and Reading the WM_NAME Property +.XS +\*(SN Setting and Reading the WM_NAME Property +.XE +.LP +Xlib provides convenience functions that you can use to set and read +the WM_NAME property for a given window. +.sp +.LP +To set a window's WM_NAME property with the supplied convenience function, use +.PN XSetWMName . +.IN "XSetWMName" "" "@DEF@" +.sM +.FD 0 +void XSetWMName\^(\^\fIdisplay\fP, \fIw\fP, \fItext_prop\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + XTextProperty *\fItext_prop\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fItext_prop\fP 1i +Specifies the +.PN XTextProperty +structure to be used. +.LP +.eM +The +.PN XSetWMName +convenience function calls +.PN XSetTextProperty +to set the WM_NAME property. +.sp +.LP +To read a window's WM_NAME property with the supplied convenience function, use +.PN XGetWMName . +.IN "XGetWMName" "" "@DEF@" +.sM +.FD 0 +Status XGetWMName\^(\^\fIdisplay\fP, \fIw\fP, \fItext_prop_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + XTextProperty *\fItext_prop_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fItext_prop_return\fP 1i +Returns the +.PN XTextProperty +structure. +.LP +.eM +The +.PN XGetWMName +convenience function calls +.PN XGetTextProperty +to obtain the WM_NAME property. +It returns a nonzero status on success; +otherwise, it returns a zero status. +.LP +The following two functions have been superseded by +.PN XSetWMName +and +.PN XGetWMName , +respectively. +You can use these additional convenience functions +for window names that are encoded as STRING properties. +.sp +.LP +To assign a name to a window, use +.PN XStoreName . +.IN "Window" "name" +.IN "XStoreName" "" "@DEF@" +.sM +.FD 0 +XStoreName\^(\^\fIdisplay\fP, \fIw\fP\^, \fIwindow_name\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + char *\fIwindow_name\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fIwindow_name\fP 1i +Specifies the window name, +which should be a null-terminated string. +.LP +.eM +The +.PN XStoreName +function assigns the name passed to window_name to the specified window. +A window manager can display the window name in some prominent +place, such as the title bar, to allow users to identify windows easily. +Some window managers may display a window's name in the window's icon, +although they are encouraged to use the window's icon name +if one is provided by the application. +If the string is not in the Host Portable Character Encoding, +the result is implementation-dependent. +.LP +.PN XStoreName +can generate +.PN BadAlloc +and +.PN BadWindow +errors. +.LP +.sp +To get the name of a window, use +.PN XFetchName . +.IN "XFetchName" "" "@DEF@" +.sM +.FD 0 +Status XFetchName\^(\^\fIdisplay\fP, \fIw\fP\^, \fIwindow_name_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + char **\fIwindow_name_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fIwindow_name_return\fP 1i +Returns the window name, which is a null-terminated string. +.LP +.eM +The +.PN XFetchName +function returns the name of the specified window. +If it succeeds, +it returns a nonzero status; +otherwise, no name has been set for the window, +and it returns zero. +If the WM_NAME property has not been set for this window, +.PN XFetchName +sets window_name_return to NULL. +If the data returned by the server is in the Latin Portable Character Encoding, +then the returned string is in the Host Portable Character Encoding. +Otherwise, the result is implementation-dependent. +When finished with it, a client must free +the window name string using +.PN XFree . +.LP +.PN XFetchName +can generate a +.PN BadWindow +error. +.NH 3 +Setting and Reading the WM_ICON_NAME Property +.XS +\*(SN Setting and Reading the WM_ICON_NAME Property +.XE +.LP +Xlib provides convenience functions that you can use to set and read +the WM_ICON_NAME property for a given window. +.LP +.sp +To set a window's WM_ICON_NAME property, +use +.PN XSetWMIconName . +.IN "XSetWMIconName" "" "@DEF@" +.sM +.FD 0 +void XSetWMIconName\^(\^\fIdisplay\fP, \fIw\fP, \fItext_prop\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + XTextProperty *\fItext_prop\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fItext_prop\fP 1i +Specifies the +.PN XTextProperty +structure to be used. +.LP +.eM +The +.PN XSetWMIconName +convenience function calls +.PN XSetTextProperty +to set the WM_ICON_NAME property. +.sp +.LP +To read a window's WM_ICON_NAME property, +use +.PN XGetWMIconName . +.IN "XGetWMIconName" "" "@DEF@" +.sM +.FD 0 +Status XGetWMIconName\^(\^\fIdisplay\fP, \fIw\fP, \fItext_prop_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + XTextProperty *\fItext_prop_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fItext_prop_return\fP 1i +Returns the +.PN XTextProperty +structure. +.LP +.eM +The +.PN XGetWMIconName +convenience function calls +.PN XGetTextProperty +to obtain the WM_ICON_NAME property. +It returns a nonzero status on success; +otherwise, it returns a zero status. +.LP +The next two functions have been superseded by +.PN XSetWMIconName +and +.PN XGetWMIconName , +respectively. +You can use these additional convenience functions +for window names that are encoded as STRING properties. +.sp +.LP +.sp +To set the name to be displayed in a window's icon, use +.PN XSetIconName . +.IN "Window" "icon name" +.IN "XSetIconName" "" "@DEF@" +.sM +.FD 0 +XSetIconName\^(\^\fIdisplay\fP, \fIw\fP\^, \fIicon_name\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + char *\fIicon_name\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fIicon_name\fP 1i +Specifies the icon name, +which should be a null-terminated string. +.LP +.eM +If the string is not in the Host Portable Character Encoding, +the result is implementation-dependent. +.PN XSetIconName +can generate +.PN BadAlloc +and +.PN BadWindow +errors. +.LP +.sp +To get the name a window wants displayed in its icon, use +.PN XGetIconName . +.IN "XGetIconName" "" "@DEF@" +.sM +.FD 0 +Status XGetIconName\^(\^\fIdisplay\fP, \fIw\fP\^, \fIicon_name_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + char **\fIicon_name_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fIicon_name_return\fP 1i +Returns the window's icon name, +which is a null-terminated string. +.LP +.eM +The +.PN XGetIconName +function returns the name to be displayed in the specified window's icon. +If it succeeds, it returns a nonzero status; otherwise, +if no icon name has been set for the window, +it returns zero. +If you never assigned a name to the window, +.PN XGetIconName +sets icon_name_return to NULL. +If the data returned by the server is in the Latin Portable Character Encoding, +then the returned string is in the Host Portable Character Encoding. +Otherwise, the result is implementation-dependent. +When finished with it, a client must free +the icon name string using +.PN XFree . +.LP +.PN XGetIconName +can generate a +.PN BadWindow +error. +.NH 3 +Setting and Reading the WM_HINTS Property +.XS +\*(SN Setting and Reading the WM_HINTS Property +.XE +.LP +Xlib provides functions that you can use to set and read +the WM_HINTS property for a given window. +These functions use the flags and the +.PN XWMHints +structure, as defined in the +.hN X11/Xutil.h +header file. +.sp +.LP +To allocate an +.PN XWMHints +structure, use +.PN XAllocWMHints . +.IN "XAllocWMHints" "" "@DEF@" +.sM +.FD 0 +XWMHints *XAllocWMHints\^(\|) +.FN +.LP +.eM +The +.PN XAllocWMHints +function allocates and returns a pointer to an +.PN XWMHints +structure. +Note that all fields in the +.PN XWMHints +structure are initially set to zero. +If insufficient memory is available, +.PN XAllocWMHints +returns NULL. +To free the memory allocated to this structure, +use +.PN XFree . +.LP +The +.PN XWMHints +structure contains: +.LP +.sM +/* Window manager hints mask bits */ +.TS +lw(.5i) lw(2.5i) lw(2.5i). +T{ +#define +T} T{ +.PN InputHint +T} T{ +(1L << 0) +T} +T{ +#define +T} T{ +.PN StateHint +T} T{ +(1L << 1) +T} +T{ +#define +T} T{ +.PN IconPixmapHint +T} T{ +(1L << 2) +T} +T{ +#define +T} T{ +.PN IconWindowHint +T} T{ +(1L << 3) +T} +T{ +#define +T} T{ +.PN IconPositionHint +T} T{ +(1L << 4) +T} +T{ +#define +T} T{ +.PN IconMaskHint +T} T{ +(1L << 5) +T} +T{ +#define +T} T{ +.PN WindowGroupHint +T} T{ +(1L << 6) +T} +T{ +#define +T} T{ +.PN UrgencyHint +T} T{ +(1L << 8) +T} +T{ +#define +T} T{ +.PN AllHints +T} T{ +(InputHint|StateHint|IconPixmapHint| +.br +IconWindowHint|IconPositionHint| +.br +IconMaskHint|WindowGroupHint) +T} +.TE +.IN "XWMHints" "" "@DEF@" +.Ds 0 +.TA .5i 2.5i +.ta .5i 2.5i +/* Values */ + +typedef struct { + long flags; /* marks which fields in this structure are defined */ + Bool input; /* does this application rely on the window manager to + get keyboard input? */ + int initial_state; /* see below */ + Pixmap icon_pixmap; /* pixmap to be used as icon */ + Window icon_window; /* window to be used as icon */ + int icon_x, icon_y; /* initial position of icon */ + Pixmap icon_mask; /* pixmap to be used as mask for icon_pixmap */ + XID window_group; /* id of related window group */ + /* this structure may be extended in the future */ +} XWMHints; +.De +.LP +.eM +The input member is used to communicate to the window manager the input focus +model used by the application. +Applications that expect input but never explicitly set focus to any +of their subwindows (that is, use the push model of focus management), +such as X Version 10 style applications that use real-estate +driven focus, should set this member to +.PN True . +Similarly, applications +that set input focus to their subwindows only when it is given to their +top-level window by a window manager should also set this member to +.PN True . +Applications that manage their own input focus by explicitly setting +focus to one of their subwindows whenever they want keyboard input +(that is, use the pull model of focus management) should set this member to +.PN False . +Applications that never expect any keyboard input also should set this member +to +.PN False . +.LP +Pull model window managers should make it possible for push model +applications to get input by setting input focus to the top-level windows of +applications whose input member is +.PN True . +Push model window managers should +make sure that pull model applications do not break them +by resetting input focus to +.PN PointerRoot +when it is appropriate (for example, whenever an application whose +input member is +.PN False +sets input focus to one of its subwindows). +.LP +The definitions for the initial_state flag are: +.TS +lw(.5i) lw(2i) lw(.2i) lw(2.8i). +T{ +#define +T} T{ +.PN WithdrawnState +T} T{ +0 +T} T{ +T} +T{ +#define +T} T{ +.PN NormalState +T} T{ +1 +T} T{ +/* most applications start this way */ +T} +T{ +#define +T} T{ +.PN IconicState +T} T{ +3 +T} T{ +/* application wants to start as an icon */ +T} +.TE +The icon_mask specifies which pixels of the icon_pixmap should be used as the +icon. +This allows for nonrectangular icons. +Both icon_pixmap and icon_mask must be bitmaps. +The icon_window lets an application provide a window for use as an icon +for window managers that support such use. +The window_group lets you specify that this window belongs to a group +of other windows. +For example, if a single application manipulates multiple +top-level windows, this allows you to provide enough +information that a window manager can iconify all of the windows +rather than just the one window. +.LP +The +.PN UrgencyHint +flag, if set in the flags field, indicates that the client deems the window +contents to be urgent, requiring the timely response of the user. The +window manager will make some effort to draw the user's attention to this +window while this flag is set. The client must provide some means by which the +user can cause the urgency flag to be cleared (either mitigating +the condition that made the window urgent or merely shutting off the alarm) +or the window to be withdrawn. +.LP +.sp +To set a window's WM_HINTS property, use +.PN XSetWMHints . +.IN "XSetWMHints" "" "@DEF@" +.sM +.FD 0 +XSetWMHints\^(\^\fIdisplay\fP, \fIw\fP, \fIwmhints\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + XWMHints *\fIwmhints\fP\^; + +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fIwmhints\fP 1i +Specifies the +.PN XWMHints +structure to be used. +.LP +.eM +The +.PN XSetWMHints +function sets the window manager hints that include icon information and location, +the initial state of the window, and whether the application relies on the +window manager to get keyboard input. +.LP +.PN XSetWMHints +can generate +.PN BadAlloc +and +.PN BadWindow +errors. +.LP +.sp +To read a window's WM_HINTS property, use +.PN XGetWMHints . +.IN "XGetWMHints" "" "@DEF@" +.sM +.FD 0 +XWMHints *XGetWMHints\^(\^\fIdisplay\fP, \fIw\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.LP +.eM +The +.PN XGetWMHints +function reads the window manager hints and +returns NULL if no WM_HINTS property was set on the window +or returns a pointer to an +.PN XWMHints +structure if it succeeds. +When finished with the data, +free the space used for it by calling +.PN XFree . +.LP +.PN XGetWMHints +can generate a +.PN BadWindow +error. +.NH 3 +Setting and Reading the WM_NORMAL_HINTS Property +.XS +\*(SN Setting and Reading the WM_NORMAL_HINTS Property +.XE +.LP +Xlib provides functions that you can use to set or read +the WM_NORMAL_HINTS property for a given window. +The functions use the flags and the +.PN XSizeHints +structure, as defined in the +.hN X11/Xutil.h +header file. +.LP +The size of the +.PN XSizeHints +structure may grow in future releases, as new components are +added to support new ICCCM features. +Passing statically allocated instances of this structure into +Xlib may result in memory corruption when running against a +future release of the library. +As such, it is recommended that only dynamically allocated +instances of the structure be used. +.sp +.LP +To allocate an +.PN XSizeHints +structure, use +.PN XAllocSizeHints . +.IN "XAllocSizeHints" "" "@DEF@" +.sM +.FD 0 +XSizeHints *XAllocSizeHints\^(\|) +.FN +.LP +.eM +The +.PN XAllocSizeHints +function allocates and returns a pointer to an +.PN XSizeHints +structure. +Note that all fields in the +.PN XSizeHints +structure are initially set to zero. +If insufficient memory is available, +.PN XAllocSizeHints +returns NULL. +To free the memory allocated to this structure, +use +.PN XFree . +.LP +The +.PN XSizeHints +structure contains: +.LP +.sM +/* Size hints mask bits */ +.TS +lw(.5i) lw(1.1i) lw(1.5i) lw(3.1i). +T{ +#define +T} T{ +.PN USPosition +T} T{ +(1L << 0) +T} T{ +/* user specified x, y */ +T} +T{ +#define +T} T{ +.PN USSize +T} T{ +(1L << 1) +T} T{ +/* user specified width, height */ +T} +T{ +#define +T} T{ +.PN PPosition +T} T{ +(1L << 2) +T} T{ +/* program specified position */ +T} +T{ +#define +T} T{ +.PN PSize +T} T{ +(1L << 3) +T} T{ +/* program specified size */ +T} +T{ +#define +T} T{ +.PN PMinSize +T} T{ +(1L << 4) +T} T{ +/* program specified minimum size */ +T} +T{ +#define +T} T{ +.PN PMaxSize +T} T{ +(1L << 5) +T} T{ +/* program specified maximum size */ +T} +T{ +#define +T} T{ +.PN PResizeInc +T} T{ +(1L << 6) +T} T{ +/* program specified resize increments */ +T} +T{ +#define +T} T{ +.PN PAspect +T} T{ +(1L << 7) +T} T{ +/* program specified min and max aspect ratios */ +T} +T{ +#define +T} T{ +.PN PBaseSize +T} T{ +(1L << 8) +T} +T{ +#define +T} T{ +.PN PWinGravity +T} T{ +(1L << 9) +T} +T{ +#define +T} T{ +.PN PAllHints +T} T{ +(PPosition|PSize| +.br +PMinSize|PMaxSize| +.br +PResizeInc|PAspect) +T} T{ +T} +.TE +.IN "XSizeHints" "" "@DEF@" +.Ds 0 +.TA .5i 2.5i +.ta .5i 2.5i +/* Values */ + +typedef struct { + long flags; /* marks which fields in this structure are defined */ + int x, y; /* Obsolete */ + int width, height; /* Obsolete */ + int min_width, min_height; + int max_width, max_height; + int width_inc, height_inc; + struct { + int x; /* numerator */ + int y; /* denominator */ + } min_aspect, max_aspect; + int base_width, base_height; + int win_gravity; + /* this structure may be extended in the future */ +} XSizeHints; +.De +.LP +.eM +The x, y, width, and height members are now obsolete +and are left solely for compatibility reasons. +The min_width and min_height members specify the +minimum window size that still allows the application to be useful. +The max_width and max_height members specify the maximum window size. +The width_inc and height_inc members define an arithmetic progression of +sizes (minimum to maximum) into which the window prefers to be resized. +The min_aspect and max_aspect members are expressed +as ratios of x and y, +and they allow an application to specify the range of aspect +ratios it prefers. +The base_width and base_height members define the desired size of the window. +The window manager will interpret the position of the window +and its border width to position the point of the outer rectangle +of the overall window specified by the win_gravity member. +The outer rectangle of the window includes any borders or decorations +supplied by the window manager. +In other words, +if the window manager decides to place the window where the client asked, +the position on the parent window's border named by the win_gravity +will be placed where the client window would have been placed +in the absence of a window manager. +.LP +Note that use of the +.PN PAllHints +macro is highly discouraged. +.sp +.LP +To set a window's WM_NORMAL_HINTS property, use +.PN XSetWMNormalHints . +.IN "XSetWMNormalHints" "" "@DEF@" +.sM +.FD 0 +void XSetWMNormalHints\^(\^\fIdisplay\fP, \fIw\fP, \fIhints\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + XSizeHints *\fIhints\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fIhints\fP 1i +Specifies the size hints for the window in its normal state. +.LP +.eM +The +.PN XSetWMNormalHints +function replaces the size hints for the WM_NORMAL_HINTS property +on the specified window. +If the property does not already exist, +.PN XSetWMNormalHints +sets the size hints for the WM_NORMAL_HINTS property on the specified window. +The property is stored with a type of WM_SIZE_HINTS and a format of 32. +.LP +.PN XSetWMNormalHints +can generate +.PN BadAlloc +and +.PN BadWindow +errors. +.sp +.LP +To read a window's WM_NORMAL_HINTS property, use +.PN XGetWMNormalHints . +.IN "XGetWMNormalHints" "" "@DEF@" +.sM +.FD 0 +Status XGetWMNormalHints\^(\^\fIdisplay\fP, \fIw\fP, \fIhints_return\fP, \ +\fIsupplied_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + XSizeHints *\fIhints_return\fP\^; +.br + long *\fIsupplied_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fIhints_return\fP 1i +Returns the size hints for the window in its normal state. +.IP \fIsupplied_return\fP 1i +Returns the hints that were supplied by the user. +.LP +.eM +The +.PN XGetWMNormalHints +function returns the size hints stored in the WM_NORMAL_HINTS property +on the specified window. +If the property is of type WM_SIZE_HINTS, is of format 32, +and is long enough to contain either an old (pre-ICCCM) +or new size hints structure, +.PN XGetWMNormalHints +sets the various fields of the +.PN XSizeHints +structure, sets the supplied_return argument to the list of fields +that were supplied by the user (whether or not they contained defined values), +and returns a nonzero status. +Otherwise, it returns a zero status. +.LP +If +.PN XGetWMNormalHints +returns successfully and a pre-ICCCM size hints property is read, +the supplied_return argument will contain the following bits: +.LP +.Ds +(USPosition|USSize|PPosition|PSize|PMinSize| + PMaxSize|PResizeInc|PAspect) +.De +.LP +If the property is large enough to contain the base size +and window gravity fields as well, +the supplied_return argument will also contain the following bits: +.LP +.Ds +PBaseSize|PWinGravity +.De +.LP +.PN XGetWMNormalHints +can generate a +.PN BadWindow +error. +.sp +.LP +To set a window's WM_SIZE_HINTS property, use +.PN XSetWMSizeHints . +.IN "XSetWMSizeHints" "" "@DEF@" +.sM +.FD 0 +void XSetWMSizeHints\^(\^\fIdisplay\fP, \fIw\fP, \fIhints\fP, \fIproperty\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + XSizeHints *\fIhints\fP\^; +.br + Atom \fIproperty\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fIhints\fP 1i +Specifies the +.PN XSizeHints +structure to be used. +.IP \fIproperty\fP 1i +Specifies the property name. +.LP +.eM +The +.PN XSetWMSizeHints +function replaces the size hints for the specified property +on the named window. +If the specified property does not already exist, +.PN XSetWMSizeHints +sets the size hints for the specified property +on the named window. +The property is stored with a type of WM_SIZE_HINTS and a format of 32. +To set a window's normal size hints, +you can use the +.PN XSetWMNormalHints +function. +.LP +.PN XSetWMSizeHints +can generate +.PN BadAlloc , +.PN BadAtom , +and +.PN BadWindow +errors. +.sp +.LP +To read a window's WM_SIZE_HINTS property, use +.PN XGetWMSizeHints . +.IN "XGetWMSizeHints" "" "@DEF@" +.sM +.FD 0 +Status XGetWMSizeHints\^(\^\fIdisplay\fP, \fIw\fP, \fIhints_return\fP, \ +\fIsupplied_return\fP, \fIproperty\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + XSizeHints *\fIhints_return\fP\^; +.br + long *\fIsupplied_return\fP\^; +.br + Atom \fIproperty\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fIhints_return\fP 1i +Returns the +.PN XSizeHints +structure. +.IP \fIsupplied_return\fP 1i +Returns the hints that were supplied by the user. +.IP \fIproperty\fP 1i +Specifies the property name. +.LP +.eM +The +.PN XGetWMSizeHints +function returns the size hints stored in the specified property +on the named window. +If the property is of type WM_SIZE_HINTS, is of format 32, +and is long enough to contain either an old (pre-ICCCM) +or new size hints structure, +.PN XGetWMSizeHints +sets the various fields of the +.PN XSizeHints +structure, sets the supplied_return argument to the +list of fields that were supplied by the user +(whether or not they contained defined values), +and returns a nonzero status. +Otherwise, it returns a zero status. +To get a window's normal size hints, +you can use the +.PN XGetWMNormalHints +function. +.LP +If +.PN XGetWMSizeHints +returns successfully and a pre-ICCCM size hints property is read, +the supplied_return argument will contain the following bits: +.LP +.Ds +(USPosition|USSize|PPosition|PSize|PMinSize| + PMaxSize|PResizeInc|PAspect) +.De +.LP +If the property is large enough to contain the base size +and window gravity fields as well, +the supplied_return argument will also contain the following bits: +.LP +.Ds +PBaseSize|PWinGravity +.De +.LP +.PN XGetWMSizeHints +can generate +.PN BadAtom +and +.PN BadWindow +errors. +.NH 3 +Setting and Reading the WM_CLASS Property +.XS +\*(SN Setting and Reading the WM_CLASS Property +.XE +.LP +Xlib provides functions that you can use to set and get +the WM_CLASS property for a given window. +These functions use the +.PN XClassHint +structure, which is defined in the +.hN X11/Xutil.h +header file. +.sp +.LP +To allocate an +.PN XClassHint +structure, use +.PN XAllocClassHint . +.IN "XAllocClassHint" "" "@DEF@" +.sM +.FD 0 +XClassHint *XAllocClassHint\^(\|) +.FN +.LP +.eM +The +.PN XAllocClassHint +function allocates and returns a pointer to an +.PN XClassHint +structure. +Note that the pointer fields in the +.PN XClassHint +structure are initially set to NULL. +If insufficient memory is available, +.PN XAllocClassHint +returns NULL. +To free the memory allocated to this structure, +use +.PN XFree . +.LP +The +.PN XClassHint +contains: +.LP +.sM +.IN "XClassHint" "" "@DEF@" +.Ds 0 +.TA .5i +.ta .5i +typedef struct { + char *res_name; + char *res_class; +} XClassHint; +.De +.LP +.eM +The res_name member contains the application name, +and the res_class member contains the application class. +Note that the name set in this property may differ from the name set as WM_NAME. +That is, WM_NAME specifies what should be displayed in the title bar and, +therefore, can contain temporal information (for example, the name of +a file currently in an editor's buffer). +On the other hand, +the name specified as part of WM_CLASS is the formal name of the application +that should be used when retrieving the application's resources from the +resource database. +.LP +.sp +To set a window's WM_CLASS property, use +.PN XSetClassHint . +.IN "XSetClassHint" "" "@DEF@" +.sM +.FD 0 +XSetClassHint\^(\^\fIdisplay\fP, \fIw\fP, \fIclass_hints\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + XClassHint *\fIclass_hints\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fIclass_hints\fP 1i +Specifies the +.PN XClassHint +structure that is to be used. +.LP +.eM +The +.PN XSetClassHint +function sets the class hint for the specified window. +If the strings are not in the Host Portable Character Encoding, +the result is implementation-dependent. +.LP +.PN XSetClassHint +can generate +.PN BadAlloc +and +.PN BadWindow +errors. +.LP +.sp +To read a window's WM_CLASS property, use +.PN XGetClassHint . +.IN "XGetClassHint" "" "@DEF@" +.sM +.FD 0 +Status XGetClassHint\^(\^\fIdisplay\fP, \fIw\fP, \fIclass_hints_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP; +.br + XClassHint *\fIclass_hints_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fIclass_hints_return\fP 1i +Returns the +.PN XClassHint +structure. +.LP +.eM +The +.PN XGetClassHint +function returns the class hint of the specified window to the members +of the supplied structure. +If the data returned by the server is in the Latin Portable Character Encoding, +then the returned strings are in the Host Portable Character Encoding. +Otherwise, the result is implementation-dependent. +It returns a nonzero status on success; +otherwise, it returns a zero status. +To free res_name and res_class when finished with the strings, +use +.PN XFree +on each individually. +.LP +.PN XGetClassHint +can generate a +.PN BadWindow +error. +.NH 3 +Setting and Reading the WM_TRANSIENT_FOR Property +.XS +\*(SN Setting and Reading the WM_TRANSIENT_FOR Property +.XE +.LP +Xlib provides functions that you can use to set and read +the WM_TRANSIENT_FOR property for a given window. +.LP +.sp +To set a window's WM_TRANSIENT_FOR property, use +.PN XSetTransientForHint . +.IN "XSetTransientForHint" "" "@DEF@" +.sM +.FD 0 +XSetTransientForHint\^(\^\fIdisplay\fP, \fIw\fP, \fIprop_window\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + Window \fIprop_window\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fIprop_window\fP 1i +Specifies the window that the WM_TRANSIENT_FOR property is to be set to. +.LP +.eM +The +.PN XSetTransientForHint +function sets the WM_TRANSIENT_FOR property of the specified window to the +specified prop_window. +.LP +.PN XSetTransientForHint +can generate +.PN BadAlloc +and +.PN BadWindow +errors. +.LP +.sp +To read a window's WM_TRANSIENT_FOR property, use +.PN XGetTransientForHint . +.IN "XGetTransientForHint" "" "@DEF@" +.sM +.FD 0 +Status XGetTransientForHint\^(\^\fIdisplay\fP, \fIw\fP, \fIprop_window_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + Window *\fIprop_window_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fIprop_window_return\fP 1i +Returns the WM_TRANSIENT_FOR property of the specified window. +.LP +.eM +The +.PN XGetTransientForHint +function returns the WM_TRANSIENT_FOR property for the specified window. +It returns a nonzero status on success; +otherwise, it returns a zero status. +.LP +.PN XGetTransientForHint +can generate a +.PN BadWindow +error. +.NH 3 +Setting and Reading the WM_PROTOCOLS Property +.XS +\*(SN Setting and Reading the WM_PROTOCOLS Property +.XE +.LP +Xlib provides functions that you can use to set and read +the WM_PROTOCOLS property for a given window. +.LP +.sp +To set a window's WM_PROTOCOLS property, use +.PN XSetWMProtocols . +.IN "XSetWMProtocols" "" "@DEF@" +.sM +.FD 0 +Status XSetWMProtocols\^(\^\fIdisplay\fP, \fIw\fP, \fIprotocols\fP, \ +\fIcount\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + Atom *\fIprotocols\fP\^; +.br + int \fIcount\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fIprotocols\fP 1i +Specifies the list of protocols. +.ds Cn protocols in the list +.IP \fIcount\fP 1i +Specifies the number of \*(Cn. +.LP +.eM +The +.PN XSetWMProtocols +function replaces the WM_PROTOCOLS property on the specified window +with the list of atoms specified by the protocols argument. +If the property does not already exist, +.PN XSetWMProtocols +sets the WM_PROTOCOLS property on the specified window +to the list of atoms specified by the protocols argument. +The property is stored with a type of ATOM and a format of 32. +If it cannot intern the WM_PROTOCOLS atom, +.PN XSetWMProtocols +returns a zero status. +Otherwise, it returns a nonzero status. +.LP +.PN XSetWMProtocols +can generate +.PN BadAlloc +and +.PN BadWindow +errors. +.sp +.LP +To read a window's WM_PROTOCOLS property, use +.PN XGetWMProtocols . +.IN "XGetWMProtocols" "" "@DEF@" +.sM +.FD 0 +Status XGetWMProtocols\^(\^\fIdisplay\fP, \fIw\fP, \fIprotocols_return\fP, \ +\fIcount_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + Atom **\fIprotocols_return\fP\^; +.br + int *\fIcount_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fIprotocols_return\fP 1i +Returns the list of protocols. +.ds Cn protocols in the list +.IP \fIcount_return\fP 1i +Returns the number of \*(Cn. +.LP +.eM +The +.PN XGetWMProtocols +function returns the list of atoms stored in the WM_PROTOCOLS property +on the specified window. +These atoms describe window manager protocols in which the owner +of this window is willing to participate. +If the property exists, is of type ATOM, is of format 32, +and the atom WM_PROTOCOLS can be interned, +.PN XGetWMProtocols +sets the protocols_return argument to a list of atoms, +sets the count_return argument to the number of elements in the list, +and returns a nonzero status. +Otherwise, it sets neither of the return arguments +and returns a zero status. +To release the list of atoms, use +.PN XFree . +.LP +.PN XGetWMProtocols +can generate a +.PN BadWindow +error. +.NH 3 +Setting and Reading the WM_COLORMAP_WINDOWS Property +.XS +\*(SN Setting and Reading the WM_COLORMAP_WINDOWS Property +.XE +.LP +Xlib provides functions that you can use to set and read +the WM_COLORMAP_WINDOWS property for a given window. +.sp +.LP +To set a window's WM_COLORMAP_WINDOWS property, use +.PN XSetWMColormapWindows . +.IN "XSetWMColormapWindows" "" "@DEF@" +.sM +.FD 0 +Status XSetWMColormapWindows\^(\^\fIdisplay\fP, \fIw\fP, \ +\fIcolormap_windows\fP, \fIcount\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + Window *\fIcolormap_windows\fP\^; +.br + int \fIcount\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fIcolormap_windows\fP 1i +Specifies the list of windows. +.ds Cn windows in the list +.IP \fIcount\fP 1i +Specifies the number of \*(Cn. +.LP +.eM +The +.PN XSetWMColormapWindows +function replaces the WM_COLORMAP_WINDOWS property on the specified +window with the list of windows specified by the colormap_windows argument. +If the property does not already exist, +.PN XSetWMColormapWindows +sets the WM_COLORMAP_WINDOWS property on the specified +window to the list of windows specified by the colormap_windows argument. +The property is stored with a type of WINDOW and a format of 32. +If it cannot intern the WM_COLORMAP_WINDOWS atom, +.PN XSetWMColormapWindows +returns a zero status. +Otherwise, it returns a nonzero status. +.LP +.PN XSetWMColormapWindows +can generate +.PN BadAlloc +and +.PN BadWindow +errors. +.sp +.LP +To read a window's WM_COLORMAP_WINDOWS property, use +.PN XGetWMColormapWindows . +.IN "XGetWMColormapWindows" "" "@DEF@" +.sM +.FD 0 +Status XGetWMColormapWindows\^(\^\fIdisplay\fP, \fIw\fP, \ +\fIcolormap_windows_return\fP, \fIcount_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + Window **\fIcolormap_windows_return\fP\^; +.br + int *\fIcount_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fIcolormap_windows_return\fP 1i +Returns the list of windows. +.ds Cn windows in the list +.IP \fIcount_return\fP 1i +Returns the number of \*(Cn. +.LP +.eM +The +.PN XGetWMColormapWindows +function returns the list of window identifiers stored +in the WM_COLORMAP_WINDOWS property on the specified window. +These identifiers indicate the colormaps that the window manager +may need to install for this window. +If the property exists, is of type WINDOW, is of format 32, +and the atom WM_COLORMAP_WINDOWS can be interned, +.PN XGetWMColormapWindows +sets the windows_return argument to a list of window identifiers, +sets the count_return argument to the number of elements in the list, +and returns a nonzero status. +Otherwise, it sets neither of the return arguments +and returns a zero status. +To release the list of window identifiers, use +.PN XFree . +.LP +.PN XGetWMColormapWindows +can generate a +.PN BadWindow +error. +.NH 3 +Setting and Reading the WM_ICON_SIZE Property +.XS +\*(SN Setting and Reading the WM_ICON_SIZE Property +.XE +.LP +Xlib provides functions that you can use to set and read +the WM_ICON_SIZE property for a given window. +These functions use the +.PN XIconSize +.IN "XIconSize" +structure, which is defined in the +.hN X11/Xutil.h +header file. +.sp +.LP +To allocate an +.PN XIconSize +structure, use +.PN XAllocIconSize . +.IN "XAllocIconSize" "" "@DEF@" +.sM +.FD 0 +XIconSize *XAllocIconSize\^(\|) +.FN +.LP +.eM +The +.PN XAllocIconSize +function allocates and returns a pointer to an +.PN XIconSize +structure. +Note that all fields in the +.PN XIconSize +structure are initially set to zero. +If insufficient memory is available, +.PN XAllocIconSize +returns NULL. +To free the memory allocated to this structure, +use +.PN XFree . +.LP +The +.PN XIconSize +structure contains: +.LP +.sM +.IN "XIconSize" "" "@DEF@" +.Ds 0 +.TA .5i 2.5i +.ta .5i 2.5i +typedef struct { + int min_width, min_height; + int max_width, max_height; + int width_inc, height_inc; +} XIconSize; +.De +.LP +.eM +The width_inc and height_inc members define an arithmetic progression of +sizes (minimum to maximum) that represent the supported icon sizes. +.LP +.sp +To set a window's WM_ICON_SIZE property, use +.PN XSetIconSizes . +.IN "XSetIconSizes" "" "@DEF@" +.sM +.FD 0 +XSetIconSizes\^(\^\fIdisplay\fP, \fIw\fP, \fIsize_list\fP, \fIcount\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + XIconSize *\fIsize_list\fP\^; +.br + int \fIcount\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fIsize_list\fP 1i +Specifies the size list. +.IP \fIcount\fP 1i +Specifies the number of items in the size list. +.LP +.eM +The +.PN XSetIconSizes +function is used only by window managers to set the supported icon sizes. +.LP +.PN XSetIconSizes +can generate +.PN BadAlloc +and +.PN BadWindow +errors. +.LP +.sp +To read a window's WM_ICON_SIZE property, use +.PN XGetIconSizes . +.IN "XGetIconSizes" "" "@DEF@" +.sM +.FD 0 +Status XGetIconSizes\^(\^\fIdisplay\fP, \fIw\fP, \fIsize_list_return\fP, \fIcount_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + XIconSize **\fIsize_list_return\fP\^; +.br + int *\fIcount_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fIsize_list_return\fP 1i +Returns the size list. +.IP \fIcount_return\fP 1i +Returns the number of items in the size list. +.LP +.eM +The +.PN XGetIconSizes +function returns zero if a window manager has not set icon sizes; +otherwise, it returns nonzero. +.PN XGetIconSizes +should be called by an application that +wants to find out what icon sizes would be most appreciated by the +window manager under which the application is running. +The application +should then use +.PN XSetWMHints +to supply the window manager with an icon pixmap or window in one of the +supported sizes. +To free the data allocated in size_list_return, use +.PN XFree . +.LP +.PN XGetIconSizes +can generate a +.PN BadWindow +error. +.NH 3 +Using Window Manager Convenience Functions +.XS +\*(SN Using Window Manager Convenience Functions +.XE +.LP +The +.PN XmbSetWMProperties +function stores the standard set of window manager properties, +with text properties in standard encodings +for internationalized text communication. +The standard window manager properties for a given window are +WM_NAME, WM_ICON_NAME, WM_HINTS, WM_NORMAL_HINTS, WM_CLASS, +WM_COMMAND, WM_CLIENT_MACHINE, and WM_LOCALE_NAME. +.IN "XmbSetWMProperties" "" "@DEF@" +.sM +.FD 0 +void XmbSetWMProperties\^(\^\fIdisplay\fP\^, \fIw\fP\^, \fIwindow_name\fP\^, \fIicon_name\fP\^, \fIargv\fP\^, \fIargc\fP\^, +.br + \fInormal_hints\fP\^, \fIwm_hints\fP\^, \fIclass_hints\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + char *\fIwindow_name\fP\^; +.br + char *\fIicon_name\fP\^; +.br + char *\fIargv\fP\^[]; +.br + int \fIargc\fP\^; +.br + XSizeHints *\fInormal_hints\fP\^; +.br + XWMHints *\fIwm_hints\fP\^; +.br + XClassHint *\fIclass_hints\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fIwindow_name\fP 1i +Specifies the window name, +which should be a null-terminated string. +.IP \fIicon_name\fP 1i +Specifies the icon name, +which should be a null-terminated string. +.IP \fIargv\fP 1i +Specifies the application's argument list. +.IP \fIargc\fP 1i +Specifies the number of arguments. +.IP \fIhints\fP 1i +Specifies the size hints for the window in its normal state. +.IP \fIwm_hints\fP 1i +Specifies the +.PN XWMHints +structure to be used. +.IP \fIclass_hints\fP 1i +Specifies the +.PN XClassHint +structure to be used. +.LP +.eM +The +.PN XmbSetWMProperties +convenience function provides a simple programming interface +for setting those essential window properties that are used +for communicating with other clients +(particularly window and session managers). +.LP +If the window_name argument is non-NULL, +.PN XmbSetWMProperties +sets the WM_NAME property. +If the icon_name argument is non-NULL, +.PN XmbSetWMProperties +sets the WM_ICON_NAME property. +The window_name and icon_name arguments are null-terminated strings +in the encoding of the current locale. +If the arguments can be fully converted to the STRING encoding, +the properties are created with type ``STRING''; +otherwise, the arguments are converted to Compound Text, +and the properties are created with type ``COMPOUND_TEXT''. +.LP +If the normal_hints argument is non-NULL, +.PN XmbSetWMProperties +calls +.PN XSetWMNormalHints , +which sets the WM_NORMAL_HINTS property (see section 14.1.7). +If the wm_hints argument is non-NULL, +.PN XmbSetWMProperties +calls +.PN XSetWMHints , +which sets the WM_HINTS property (see section 14.1.6). +.LP +If the argv argument is non-NULL, +.PN XmbSetWMProperties +sets the WM_COMMAND property from argv and argc. +An argc of zero indicates a zero-length command. +.LP +The hostname of the machine is stored using +.PN XSetWMClientMachine +(see section 14.2.2). +.LP +If the class_hints argument is non-NULL, +.PN XmbSetWMProperties +sets the WM_CLASS property. +If the res_name member in the +.PN XClassHint +structure is set to the NULL pointer and the RESOURCE_NAME +environment variable is set, +the value of the environment variable is substituted for res_name. +If the res_name member is NULL, +the environment variable is not set, and argv and argv[0] are set, +then the value of argv[0], stripped of any directory prefixes, +is substituted for res_name. +.LP +It is assumed that the supplied class_hints.res_name and argv, +the RESOURCE_NAME environment variable, and the hostname of the machine +are in the encoding of the locale announced for the LC_CTYPE category +(on POSIX-compliant systems, the LC_CTYPE, else LANG environment variable). +The corresponding WM_CLASS, WM_COMMAND, and WM_CLIENT_MACHINE properties +are typed according to the local host locale announcer. +No encoding conversion is performed prior to storage in the properties. +.LP +For clients that need to process the property text in a locale, +.PN XmbSetWMProperties +sets the WM_LOCALE_NAME property to be the name of the current locale. +The name is assumed to be in the Host Portable Character Encoding +and is converted to STRING for storage in the property. +.LP +.PN XmbSetWMProperties +can generate +.PN BadAlloc +and +.PN BadWindow +errors. +.sp +.LP +To set a window's standard window manager properties +with strings in client-specified encodings, use +.PN XSetWMProperties . +The standard window manager properties for a given window are +WM_NAME, WM_ICON_NAME, WM_HINTS, WM_NORMAL_HINTS, WM_CLASS, +WM_COMMAND, and WM_CLIENT_MACHINE. +.IN "XSetWMProperties" "" "@DEF@" +.sM +.FD 0 +void XSetWMProperties\^(\^\fIdisplay\fP, \fIw\fP, \fIwindow_name\fP, \ +\fIicon_name\fP, \fIargv\fP, \fIargc\fP, \fInormal_hints\fP, \fIwm_hints\fP, \ +\fIclass_hints\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + XTextProperty *\fIwindow_name\fP\^; +.br + XTextProperty *\fIicon_name\fP\^; +.br + char **\fIargv\fP\^; +.br + int \fIargc\fP\^; +.br + XSizeHints *\fInormal_hints\fP\^; +.br + XWMHints *\fIwm_hints\fP\^; +.br + XClassHint *\fIclass_hints\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fIwindow_name\fP 1i +Specifies the window name, +which should be a null-terminated string. +.IP \fIicon_name\fP 1i +Specifies the icon name, +which should be a null-terminated string. +.IP \fIargv\fP 1i +Specifies the application's argument list. +.IP \fIargc\fP 1i +Specifies the number of arguments. +.IP \fInormal_hints\fP 1i +Specifies the size hints for the window in its normal state. +.IP \fIwm_hints\fP 1i +Specifies the +.PN XWMHints +structure to be used. +.IP \fIclass_hints\fP 1i +Specifies the +.PN XClassHint +structure to be used. +.LP +.eM +The +.PN XSetWMProperties +convenience function provides a single programming interface +for setting those essential window properties that are used +for communicating with other clients (particularly window and session +managers). +.LP +If the window_name argument is non-NULL, +.PN XSetWMProperties +calls +.PN XSetWMName , +which, in turn, sets the WM_NAME property (see section 14.1.4). +If the icon_name argument is non-NULL, +.PN XSetWMProperties +calls +.PN XSetWMIconName , +which sets the WM_ICON_NAME property (see section 14.1.5). +If the argv argument is non-NULL, +.PN XSetWMProperties +calls +.PN XSetCommand , +which sets the WM_COMMAND property (see section 14.2.1). +Note that an argc of zero is allowed to indicate a zero-length command. +Note also that the hostname of this machine is stored using +.PN XSetWMClientMachine +(see section 14.2.2). +.LP +If the normal_hints argument is non-NULL, +.PN XSetWMProperties +calls +.PN XSetWMNormalHints , +which sets the WM_NORMAL_HINTS property (see section 14.1.7). +If the wm_hints argument is non-NULL, +.PN XSetWMProperties +calls +.PN XSetWMHints , +which sets the WM_HINTS property (see section 14.1.6). +.LP +If the class_hints argument is non-NULL, +.PN XSetWMProperties +calls +.PN XSetClassHint , +which sets the WM_CLASS property (see section 14.1.8). +If the res_name member in the +.PN XClassHint +structure is set to the NULL pointer and the RESOURCE_NAME environment +variable is set, +then the value of the environment variable is substituted for res_name. +If the res_name member is NULL, +the environment variable is not set, +and argv and argv[0] are set, +then the value of argv[0], stripped of +any directory prefixes, is substituted for res_name. +.LP +.PN XSetWMProperties +can generate +.PN BadAlloc +and +.PN BadWindow +errors. +.NH 2 +Client to Session Manager Communication +.XS +\*(SN Client to Session Manager Communication +.XE +.LP +This section discusses how to: +.IP \(bu 5 +Set and read the WM_COMMAND property +.IP \(bu 5 +Set and read the WM_CLIENT_MACHINE property +.NH 3 +Setting and Reading the WM_COMMAND Property +.XS +\*(SN Setting and Reading the WM_COMMAND Property +.XE +.LP +Xlib provides functions that you can use to set and read +the WM_COMMAND property for a given window. +.sp +.LP +To set a window's WM_COMMAND property, use +.PN XSetCommand . +.IN "XSetCommand" "" "@DEF@" +.sM +.FD 0 +XSetCommand\^(\^\fIdisplay\fP, \fIw\fP, \fIargv\fP, \fIargc\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + char **\fIargv\fP\^; +.br + int \fIargc\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fIargv\fP 1i +Specifies the application's argument list. +.IP \fIargc\fP 1i +Specifies the number of arguments. +.LP +.eM +The +.PN XSetCommand +function sets the command and arguments used to invoke the +application. +(Typically, argv is the argv array of your main program.) +If the strings are not in the Host Portable Character Encoding, +the result is implementation-dependent. +.LP +.PN XSetCommand +can generate +.PN BadAlloc +and +.PN BadWindow +errors. +.sp +.LP +To read a window's WM_COMMAND property, use +.PN XGetCommand . +.IN "XGetCommand" "" "@DEF@" +.sM +.FD 0 +Status XGetCommand\^(\^\fIdisplay\fP, \fIw\fP, \fIargv_return\fP, \ +\fIargc_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + char ***\fIargv_return\fP\^; +.br + int *\fIargc_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fIargv_return\fP 1i +Returns the application's argument list. +.IP \fIargc_return\fP 1i +Returns the number of arguments returned. +.LP +.eM +The +.PN XGetCommand +function reads the WM_COMMAND property from the specified window +and returns a string list. +If the WM_COMMAND property exists, +it is of type STRING and format 8. +If sufficient memory can be allocated to contain the string list, +.PN XGetCommand +fills in the argv_return and argc_return arguments +and returns a nonzero status. +Otherwise, it returns a zero status. +If the data returned by the server is in the Latin Portable Character Encoding, +then the returned strings are in the Host Portable Character Encoding. +Otherwise, the result is implementation-dependent. +To free the memory allocated to the string list, use +.PN XFreeStringList . +.NH 3 +Setting and Reading the WM_CLIENT_MACHINE Property +.XS +\*(SN Setting and Reading the WM_CLIENT_MACHINE Property +.XE +.LP +Xlib provides functions that you can use to set and read +the WM_CLIENT_MACHINE property for a given window. +.sp +.LP +To set a window's WM_CLIENT_MACHINE property, use +.PN XSetWMClientMachine . +.IN "XSetWMClientMachine" "" "@DEF@" +.sM +.FD 0 +void XSetWMClientMachine\^(\^\fIdisplay\fP, \fIw\fP, \fItext_prop\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + XTextProperty *\fItext_prop\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fItext_prop\fP 1i +Specifies the +.PN XTextProperty +structure to be used. +.LP +.eM +The +.PN XSetWMClientMachine +convenience function calls +.PN XSetTextProperty +to set the WM_CLIENT_MACHINE property. +.sp +.LP +To read a window's WM_CLIENT_MACHINE property, use +.PN XGetWMClientMachine . +.IN "XGetWMClientMachine" "" "@DEF@" +.sM +.FD 0 +Status XGetWMClientMachine\^(\^\fIdisplay\fP, \fIw\fP, \fItext_prop_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + XTextProperty *\fItext_prop_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fItext_prop_return\fP 1i +Returns the +.PN XTextProperty +structure. +.LP +.eM +The +.PN XGetWMClientMachine +convenience function performs an +.PN XGetTextProperty +on the WM_CLIENT_MACHINE property. +It returns a nonzero status on success; +otherwise, it returns a zero status. +.NH 2 +Standard Colormaps +.XS +\*(SN Standard Colormaps +.XE +.LP +Applications with color palettes, smooth-shaded drawings, or digitized +images demand large numbers of colors. +In addition, these applications often require an efficient mapping +from color triples to pixel values that display the appropriate colors. +.LP +As an example, consider a three-dimensional display program that wants +to draw a smoothly shaded sphere. +At each pixel in the image of the sphere, +the program computes the intensity and color of light +reflected back to the viewer. +The result of each computation is a triple of red, green, and blue (RGB) +coefficients in the range 0.0 to 1.0. +To draw the sphere, the program needs a colormap that provides a +large range of uniformly distributed colors. +The colormap should be arranged so that the program can +convert its RGB triples into pixel values very quickly, +because drawing the entire sphere requires many such +conversions. +.LP +On many current workstations, +the display is limited to 256 or fewer colors. +Applications must allocate colors carefully, +not only to make sure they cover the entire range they need +but also to make use of as many of the available colors as possible. +On a typical X display, +many applications are active at once. +Most workstations have only one hardware look-up table for colors, +so only one application colormap can be installed at a given time. +The application using the installed colormap is displayed correctly, +and the other applications go technicolor and are +displayed with false colors. +.LP +As another example, consider a user who is running an +image processing program to display earth-resources data. +The image processing program needs a colormap set up with 8 reds, +8 greens, and 4 blues, for a total of 256 colors. +Because some colors are already in use in the default colormap, +the image processing program allocates and installs a new colormap. +.LP +The user decides to alter some of the colors in the image +by invoking a color palette program to mix and choose colors. +The color palette program also needs a +colormap with eight reds, eight greens, and four blues, so just like +the image processing program, it must allocate and +install a new colormap. +.LP +Because only one colormap can be installed at a time, +the color palette may be displayed incorrectly +whenever the image processing program is active. +Conversely, whenever the palette program is active, +the image may be displayed incorrectly. +The user can never match or compare colors in the palette and image. +Contention for colormap resources can be reduced if applications +with similar color needs share colormaps. +.LP +The image processing program and the color palette program +could share the same colormap if there existed a convention that described +how the colormap was set up. +Whenever either program was active, +both would be displayed correctly. +.LP +The standard colormap properties define a set of commonly used +colormaps. +Applications that share these colormaps and conventions display +true colors more often and provide a better interface to the user. +.LP +Standard colormaps allow applications to share commonly used color +resources. +This allows many applications to be displayed in true colors +simultaneously, even when each application needs an entirely filled +colormap. +.LP +Several standard colormaps are described in this section. +Usually, a window manager creates these colormaps. +Applications should use the standard colormaps if they already exist. +.sp +.LP +To allocate an +.PN XStandardColormap +structure, use +.PN XAllocStandardColormap . +.IN "XAllocStandardColormap" "" "@DEF@" +.sM +.FD 0 +XStandardColormap *XAllocStandardColormap\^(\|) +.FN +.LP +.eM +The +.PN XAllocStandardColormap +function allocates and returns a pointer to an +.PN XStandardColormap +structure. +Note that all fields in the +.PN XStandardColormap +structure are initially set to zero. +If insufficient memory is available, +.PN XAllocStandardColormap +returns NULL. +To free the memory allocated to this structure, +use +.PN XFree . +.LP +The +.PN XStandardColormap +structure contains: +.LP +.sM +/* Hints */ +.TS +lw(.5i) lw(2i) lw(1i). +T{ +#define +T} T{ +.PN ReleaseByFreeingColormap +T} T{ +( (XID) 1L) +T} +.TE +/* Values */ +.IN "XStandardColormap" "" "@DEF@" +.Ds 0 +.TA .5i 2.5i +.ta .5i 2.5i +typedef struct { + Colormap colormap; + unsigned long red_max; + unsigned long red_mult; + unsigned long green_max; + unsigned long green_mult; + unsigned long blue_max; + unsigned long blue_mult; + unsigned long base_pixel; + VisualID visualid; + XID killid; +} XStandardColormap; +.De +.LP +.eM +The colormap member is the colormap created by the +.PN XCreateColormap +function. +The red_max, green_max, and blue_max members give the maximum +red, green, and blue values, respectively. +Each color coefficient ranges from zero to its max, inclusive. +For example, +a common colormap allocation is 3/3/2 (3 planes for red, 3 +planes for green, and 2 planes for blue). +This colormap would have red_max = 7, green_max = 7, +and blue_max = 3. +An alternate allocation that uses only 216 colors is red_max = 5, +green_max = 5, and blue_max = 5. +.LP +The red_mult, green_mult, and blue_mult members give the +scale factors used to compose a full pixel value. +(See the discussion of the base_pixel members for further information.) +For a 3/3/2 allocation, red_mult might be 32, +green_mult might be 4, and blue_mult might be 1. +For a 6-colors-each allocation, red_mult might be 36, +green_mult might be 6, and blue_mult might be 1. +.LP +The base_pixel member gives the base pixel value used to +compose a full pixel value. +Usually, the base_pixel is obtained from a call to the +.PN XAllocColorPlanes +function. +Given integer red, green, and blue coefficients in their appropriate +ranges, one then can compute a corresponding pixel value by +using the following expression: +.LP +.Ds +.TA .5i 1.5i +.ta .5i 1.5i +(r * red_mult + g * green_mult + b * blue_mult + base_pixel) & 0xFFFFFFFF +.De +.LP +For +.PN GrayScale +colormaps, +only the colormap, red_max, red_mult, +and base_pixel members are defined. +The other members are ignored. +To compute a +.PN GrayScale +pixel value, use the following expression: +.LP +.Ds +.TA .5i 1.5i +.ta .5i 1.5i +(gray * red_mult + base_pixel) & 0xFFFFFFFF +.De +.LP +Negative multipliers can be represented by converting the 2's +complement representation of the multiplier into an unsigned long and +storing the result in the appropriate _mult field. +The step of masking by 0xFFFFFFFF effectively converts the resulting +positive multiplier into a negative one. +The masking step will take place automatically on many machine architectures, +depending on the size of the integer type used to do the computation. +.LP +The visualid member gives the ID number of the visual from which the +colormap was created. +The killid member gives a resource ID that indicates whether +the cells held by this standard colormap are to be released +by freeing the colormap ID or by calling the +.PN XKillClient +function on the indicated resource. +(Note that this method is necessary for allocating out of an existing colormap.) +.LP +The properties containing the +.PN XStandardColormap +information have +the type RGB_COLOR_MAP. +.LP +The remainder of this section discusses standard colormap properties and atoms +as well as how to manipulate standard colormaps. +.NH 3 +Standard Colormap Properties and Atoms +.XS +\*(SN Standard Colormap Properties and Atoms +.XE +.LP +.IN "Standard Colormaps" +.IN "Colormaps" "standard" +Several standard colormaps are available. +Each standard colormap is defined by a property, +and each such property is identified by an atom. +The following list names the atoms and describes the colormap +associated with each one. +The +.hN X11/Xatom.h +header file contains the definitions for each of the following atoms, +which are prefixed with XA_. +.IP RGB_DEFAULT_MAP 5 +This atom names a property. +The value of the property is an array of +.PN XStandardColormap +structures. +Each entry in the array describes an RGB subset of the default color +map for the Visual specified by visual_id. +.IP +Some applications only need a few RGB colors and +may be able to allocate them from the system default colormap. +This is the ideal situation because the fewer colormaps that are +active in the system the more applications are displayed +with correct colors at all times. +.IP +A typical allocation for the RGB_DEFAULT_MAP on 8-plane displays +is 6 reds, 6 greens, and 6 blues. +This gives 216 uniformly distributed colors +(6 intensities of 36 different hues) and still leaves 40 elements +of a 256-element colormap available for special-purpose colors +for text, borders, and so on. +.IP RGB_BEST_MAP 5 +.br +This atom names a property. +The value of the property is an +.PN XStandardColormap . +.IP +The property defines the best RGB colormap available on +the screen. +(Of course, this is a subjective evaluation.) +Many image processing and three-dimensional applications need to +use all available colormap cells and to distribute as many +perceptually distinct colors as possible over those cells. +This implies that there may be more green values available than +red, as well as more green or red than blue. +.IP +For an 8-plane +.PN PseudoColor +visual, +RGB_BEST_MAP is likely to be a 3/3/2 allocation. +For a 24-plane +.PN DirectColor +visual, +RGB_BEST_MAP is normally an 8/8/8 allocation. +.IP RGB_RED_MAP 5 +.br +.ns +.IP RGB_GREEN_MAP 5 +.br +.ns +.IP RGB_BLUE_MAP 5 +These atoms name properties. +The value of each property is an +.PN XStandardColormap . +.IP +The properties define all-red, all-green, and all-blue +colormaps, respectively. +These maps are used by applications that want to make color-separated +images. +For example, a user might generate a full-color image +on an 8-plane display both by rendering an image three times +(once with high color resolution in red, once with green, +and once with blue) and by multiply exposing a single frame in a camera. +.IP RGB_GRAY_MAP 5 +This atom names a property. +The value of the property is an +.PN XStandardColormap . +.IP +The property describes the best +.PN GrayScale +colormap available on the screen. +As previously mentioned, +only the colormap, red_max, red_mult, and base_pixel members of the +.PN XStandardColormap +structure are used for +.PN GrayScale +colormaps. +.NH 3 +Setting and Obtaining Standard Colormaps +.XS +\*(SN Setting and Obtaining Standard Colormaps +.XE +.LP +Xlib provides functions that you can use to set and obtain an +.PN XStandardColormap +structure. +.sp +.LP +To set an +.PN XStandardColormap +structure, use +.PN XSetRGBColormaps . +.IN "XSetRGBColormaps" "" "@DEF@" +.sM +.FD 0 +void XSetRGBColormaps\^(\^\fIdisplay\fP, \fIw\fP, \fIstd_colormap\fP, \ +\fIcount\fP, \fIproperty\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + XStandardColormap *\fIstd_colormap\fP\^; +.br + int \fIcount\fP\^; +.br + Atom \fIproperty\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fIstd_colormap\fP 1i +Specifies the +.PN XStandardColormap +structure to be used. +.ds Cn colormaps +.IP \fIcount\fP 1i +Specifies the number of \*(Cn. +.IP \fIproperty\fP 1i +Specifies the property name. +.LP +.eM +The +.PN XSetRGBColormaps +function replaces the RGB colormap definition in the specified property +on the named window. +If the property does not already exist, +.PN XSetRGBColormaps +sets the RGB colormap definition in the specified property +on the named window. +The property is stored with a type of RGB_COLOR_MAP and a format of 32. +Note that it is the caller's responsibility to honor the ICCCM +restriction that only RGB_DEFAULT_MAP contain more than one definition. +.LP +The +.PN XSetRGBColormaps +function usually is only used by window or session managers. +To create a standard colormap, +follow this procedure: +.IP 1. 5 +Open a new connection to the same server. +.IP 2. 5 +Grab the server. +.IP 3. 5 +See if the property is on the property list of the root window for the screen. +.IP 4. 5 +If the desired property is not present: +.RS +.IP \(bu 5 +Create a colormap (unless you are using the default colormap of the screen). +.IP \(bu 5 +Determine the color characteristics of the visual. +.IP \(bu 5 +Allocate cells in the colormap (or create it with +.PN AllocAll ). +.IP \(bu 5 +Call +.PN XStoreColors +to store appropriate color values in the colormap. +.IP \(bu 5 +Fill in the descriptive members in the +.PN XStandardColormap +structure. +.IP \(bu 5 +Attach the property to the root window. +.IP \(bu 5 +Use +.PN XSetCloseDownMode +to make the resource permanent. +.RE +.IP 5. 5 +Ungrab the server. +.LP +.PN XSetRGBColormaps +can generate +.PN BadAlloc , +.PN BadAtom , +and +.PN BadWindow +errors. +.sp +.LP +To obtain the +.PN XStandardColormap +structure associated with the specified property, use +.PN XGetRGBColormaps . +.IN "XGetRGBColormaps" "" "@DEF@" +.sM +.FD 0 +Status XGetRGBColormaps\^(\^\fIdisplay\fP, \fIw\fP, \fIstd_colormap_return\fP, \ +\fIcount_return\fP, \fIproperty\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Window \fIw\fP\^; +.br + XStandardColormap **\fIstd_colormap_return\fP\^; +.br + int *\fIcount_return\fP\^; +.br + Atom \fIproperty\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIw\fP 1i +Specifies the window. +.IP \fIstd_colormap_return\fP 1i +Returns the +.PN XStandardColormap +structure. +.ds Cn colormaps +.IP \fIcount_return\fP 1i +Returns the number of \*(Cn. +.IP \fIproperty\fP 1i +Specifies the property name. +.LP +.eM +The +.PN XGetRGBColormaps +function returns the RGB colormap definitions stored +in the specified property on the named window. +If the property exists, is of type RGB_COLOR_MAP, is of format 32, +and is long enough to contain a colormap definition, +.PN XGetRGBColormaps +allocates and fills in space for the returned colormaps +and returns a nonzero status. +If the visualid is not present, +.PN XGetRGBColormaps +assumes the default visual for the screen on which the window is located; +if the killid is not present, +.PN None +is assumed, which indicates that the resources cannot be released. +Otherwise, +none of the fields are set, and +.PN XGetRGBColormaps +returns a zero status. +Note that it is the caller's responsibility to honor the ICCCM +restriction that only RGB_DEFAULT_MAP contain more than one definition. +.LP +.PN XGetRGBColormaps +can generate +.PN BadAtom +and +.PN BadWindow +errors. +.bp diff --git a/libX11/specs/libX11/CH15 b/libX11/specs/libX11/CH15 new file mode 100644 index 000000000..a10df0a53 --- /dev/null +++ b/libX11/specs/libX11/CH15 @@ -0,0 +1,1628 @@ +.\" Copyright \(co 1985, 1986, 1987, 1988, 1989, 1990, 1991, 1994, 1996 X Consortium +.\" +.\" 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 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 X CONSORTIUM 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 X Consortium 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 X Consortium. +.\" +.\" Copyright \(co 1985, 1986, 1987, 1988, 1989, 1990, 1991 by +.\" Digital Equipment Corporation +.\" +.\" Portions Copyright \(co 1990, 1991 by +.\" Tektronix, Inc. +.\" +.\" Permission to use, copy, modify and distribute this documentation for +.\" any purpose and without fee is hereby granted, provided that the above +.\" copyright notice appears in all copies and that both that copyright notice +.\" and this permission notice appear in all copies, and that the names of +.\" Digital and Tektronix not be used in in advertising or publicity pertaining +.\" to this documentation without specific, written prior permission. +.\" Digital and Tektronix makes no representations about the suitability +.\" of this documentation for any purpose. +.\" It is provided ``as is'' without express or implied warranty. +.\" +\& +.sp 1 +.ce 3 +\s+1\fBChapter 15\fP\s-1 + +\s+1\fBResource Manager Functions\fP\s-1 +.sp 2 +.nr H1 15 +.nr H2 0 +.nr H3 0 +.nr H4 0 +.nr H5 0 +.na +.LP +.XS +Chapter 15: Resource Manager Functions +.XE +A program often needs a variety of options in the X environment +(for example, fonts, colors, icons, and cursors). +Specifying all of these options on the command line is awkward +because users may want to customize many aspects of the program +and need a convenient way to establish these customizations as +the default settings. +The resource manager is provided for this purpose. +Resource specifications are usually stored in human-readable files +and in server properties. +.LP +The resource manager is a database manager with a twist. +In most database systems, +you perform a query using an imprecise specification, +and you get back a set of records. +The resource manager, however, allows you to specify a large +set of values with an imprecise specification, to query the database +with a precise specification, and to get back only a single value. +This should be used by applications that need to know what the +user prefers for colors, fonts, and other resources. +It is this use as a database for dealing with X resources that +inspired the name ``Resource Manager,'' +although the resource manager can be and is used in other ways. +.LP +For example, +a user of your application may want to specify +that all windows should have a blue background +but that all mail-reading windows should have a red background. +With well-engineered and coordinated applications, +a user can define this information using only two lines of specifications. +.LP +As an example of how the resource manager works, +consider a mail-reading application called xmh. +Assume that it is designed so that it uses a +complex window hierarchy all the way down to individual command buttons, +which may be actual small subwindows in some toolkits. +These are often called objects or widgets. +In such toolkit systems, +each user interface object can be composed of other objects +and can be assigned a name and a class. +Fully qualified names or classes can have arbitrary numbers of component names, +but a fully qualified name always has the same number of component names as a +fully qualified class. +This generally reflects the structure of the application as composed +of these objects, starting with the application itself. +.LP +For example, the xmh mail program has a name ``xmh'' and is one +of a class of ``Mail'' programs. +By convention, the first character of class components is capitalized, +and the first letter of name components is in lowercase. +Each name and class finally has an attribute +(for example, ``foreground'' or ``font''). +If each window is properly assigned a name and class, +it is easy for the user to specify attributes of any portion +of the application. +.LP +At the top level, +the application might consist of a paned window (that is, a window divided +into several sections) named ``toc''. +One pane of the paned window is a button box window named ``buttons'' +and is filled with command buttons. +One of these command buttons is used to incorporate +new mail and has the name ``incorporate''. +This window has a fully qualified name, ``xmh.toc.buttons.incorporate'', +and a fully qualified class, ``Xmh.Paned.Box.Command''. +Its fully qualified name is the name of its parent, ``xmh.toc.buttons'', +followed by its name, ``incorporate''. +Its class is the class of its parent, ``Xmh.Paned.Box'', +followed by its particular class, ``Command''. +The fully qualified name of a resource is +the attribute's name appended to the object's fully qualified +name, and the fully qualified class is its class appended to the object's +class. +.LP +The incorporate button might need the following resources: +Title string, +Font, +Foreground color for its inactive state, +Background color for its inactive state, +Foreground color for its active state, and +Background color for its active state. +Each resource is considered +to be an attribute of the button and, as such, has a name and a class. +For example, the foreground color for the button in +its active state might be named ``activeForeground'', +and its class might be ``Foreground''. +.LP +When an application looks up a resource (for example, a color), +it passes the complete name and complete class of the resource +to a look-up routine. +The resource manager compares this complete specification +against the incomplete specifications of entries in the resource +database, finds the best match, and returns the corresponding +value for that entry. +.LP +The definitions for the resource manager are contained in +.hN X11/Xresource.h . +.NH 2 +Resource File Syntax +.XS +\*(SN Resource File Syntax +.XE +.LP +The syntax of a resource file is a sequence of resource lines +terminated by newline characters or the end of the file. +The syntax of an individual resource line is: +.LP +.\" Start marker code here +.Ds 0 +.TA 1.5i 1.75i +.ta 1.5i 1.75i +ResourceLine = Comment | IncludeFile | ResourceSpec | +Comment = "!" {} +IncludeFile = "#" WhiteSpace "include" WhiteSpace FileName WhiteSpace +FileName = +ResourceSpec = WhiteSpace ResourceName WhiteSpace ":" WhiteSpace Value +ResourceName = [Binding] {Component Binding} ComponentName +Binding = "\&." | "*" +WhiteSpace = { | } +Component = "?" | ComponentName +ComponentName = NameChar {NameChar} +NameChar = "a"\-"z" | "A"\-"Z" | "0"\-"9" | "_" | "-" +Value = {} +.De +.\" End marker code here +.LP +Elements separated by vertical bar (|) are alternatives. +Curly braces ({\&.\&.\&.}) indicate zero or more repetitions +of the enclosed elements. +Square brackets ([\&.\&.\&.]) indicate that the enclosed element is optional. +Quotes ("\&.\&.\&.") are used around literal characters. +.LP +IncludeFile lines are interpreted by replacing the line with the +contents of the specified file. +The word ``include'' must be in lowercase. +The file name is interpreted relative to the directory of the file in +which the line occurs (for example, if the file name contains no +directory or contains a relative directory specification). +.LP +If a ResourceName contains a contiguous sequence of two or more Binding +characters, the sequence will be replaced with a single ``\&.'' character +if the sequence contains only ``\&.'' characters; +otherwise, the sequence will be replaced with a single ``*'' character. +.LP +A resource database never contains more than one entry for a given +ResourceName. If a resource file contains multiple lines with the +same ResourceName, the last line in the file is used. +.LP +Any white space characters before or after the name or colon in a ResourceSpec +are ignored. +To allow a Value to begin with white space, +the two-character sequence ``\^\\\^\fIspace\fP'' (backslash followed by space) +is recognized and replaced by a space character, +and the two-character sequence ``\^\\\^\fItab\fP'' +(backslash followed by horizontal tab) +is recognized and replaced by a horizontal tab character. +To allow a Value to contain embedded newline characters, +the two-character sequence ``\^\\\^n'' is recognized and replaced by a +newline character. +To allow a Value to be broken across multiple lines in a text file, +the two-character sequence ``\^\\\^\fInewline\fP'' +(backslash followed by newline) is +recognized and removed from the value. +To allow a Value to contain arbitrary character codes, +the four-character sequence ``\^\\\^\fInnn\fP'', +where each \fIn\fP is a digit character in the range of ``0''\^\-``7'', +is recognized and replaced with a single byte that contains +the octal value specified by the sequence. +Finally, the two-character sequence ``\^\\\\'' is recognized +and replaced with a single backslash. +.LP +As an example of these sequences, +the following resource line contains a value consisting of four +characters: a backslash, a null, a ``z'', and a newline: +.Ds +magic.values: \\\\\\\^000\^\\ +z\\\^n +.De +.NH 2 +Resource Manager Matching Rules +.XS +\*(SN Resource Manager Matching Rules +.XE +.LP +The algorithm for determining which resource database entry +matches a given query is the heart of the resource manager. +All queries must fully specify the name and class of the desired resource +(use of the characters ``*'' and ``?'' is not permitted). +The library supports up to 100 components in a full name or class. +Resources are stored in the database with only partially specified +names and classes, using pattern matching constructs. +An asterisk (*) is a loose binding and is used to represent any number +of intervening components, including none. +A period (.) is a tight binding and is used to separate immediately +adjacent components. +A question mark (?) is used to match any single component name or class. +A database entry cannot end in a loose binding; +the final component (which cannot be the character ``?'') must be specified. +The lookup algorithm searches the database for the entry that most +closely matches (is most specific for) the full name and class being queried. +When more than one database entry matches the full name and class, +precedence rules are used to select just one. +.LP +The full name and class are scanned from left to right (from highest +level in the hierarchy to lowest), one component at a time. +At each level, the corresponding component and/or binding of each +matching entry is determined, and these matching components and +bindings are compared according to precedence rules. +Each of the rules is applied at each level before moving to the next level, +until a rule selects a single entry over all others. +The rules, in order of precedence, are: +.IP 1. 5 +An entry that contains a matching component (whether name, class, +or the character ``?'') +takes precedence over entries that elide the level (that is, entries +that match the level in a loose binding). +.IP 2. 5 +An entry with a matching name takes precedence over both +entries with a matching class and entries that match using the character ``?''. +An entry with a matching class takes precedence over +entries that match using the character ``?''. +.IP 3. 5 +An entry preceded by a tight binding takes precedence over entries +preceded by a loose binding. +.LP +To illustrate these rules, +consider the following resource database entries: +.Ds +.TA 2.5i 3.5i +.ta 2.5i 3.5i +xmh*Paned*activeForeground: red \fI(entry A)\fP +*incorporate.Foreground: blue \fI(entry B)\fP +xmh.toc*Command*activeForeground: green \fI(entry C)\fP +xmh.toc*?.Foreground: white \fI(entry D)\fP +xmh.toc*Command.activeForeground: black \fI(entry E)\fP +.De +.LP +Consider a query for the resource: +.LP +.Ds +.TA 3.5i +.ta 3.5i +xmh.toc.messagefunctions.incorporate.activeForeground \fI(name)\fP +Xmh.Paned.Box.Command.Foreground \fI(class)\fP +.De +.LP +At the first level (xmh, Xmh), rule 1 eliminates entry B. +At the second level (toc, Paned), rule 2 eliminates entry A. +At the third level (messagefunctions, Box), no entries are eliminated. +At the fourth level (incorporate, Command), rule 2 eliminates entry D. +At the fifth level (activeForeground, Foreground), rule 3 eliminates entry C. +.NH 2 +Quarks +.XS +\*(SN Quarks +.XE +.LP +Most uses of the resource manager involve defining names, +classes, and representation types as string constants. +However, always referring to strings in the resource manager can be slow, +because it is so heavily used in some toolkits. +To solve this problem, +a shorthand for a string is used in place of the string +in many of the resource manager functions. +Simple comparisons can be performed rather than string comparisons. +The shorthand name for a string is called a quark and is the +type +.PN XrmQuark . +On some occasions, +you may want to allocate a quark that has no string equivalent. +.LP +A quark is to a string what an atom is to a string in the server, +but its use is entirely local to your application. +.LP +.sp +To allocate a new quark, use +.PN XrmUniqueQuark . +.IN "XrmUniqueQuark" "" "@DEF@" +.sM +.FD 0 +XrmQuark XrmUniqueQuark\^(\|) +.FN +.LP +.eM +The +.PN XrmUniqueQuark +function allocates a quark that is guaranteed not to represent any string that +is known to the resource manager. +.LP +.sp +Each name, class, and representation type is typedef'd as an +.PN XrmQuark . +.LP +.sM +.Ds 0 +typedef int XrmQuark, *XrmQuarkList; +typedef XrmQuark XrmName; +typedef XrmQuark XrmClass; +typedef XrmQuark XrmRepresentation; +#define NULLQUARK ((XrmQuark) 0) +.De +.LP +.eM +Lists are represented as null-terminated arrays of quarks. +The size of the array must be large enough for the number of components used. +.LP +.sM +.Ds 0 +typedef XrmQuarkList XrmNameList; +typedef XrmQuarkList XrmClassList; +.De +.LP +.eM +.sp +To convert a string to a quark, use +.PN XrmStringToQuark +or +.PN XrmPermStringToQuark . +.IN "XrmStringToQuark" "" "@DEF@" +.IN "XrmPermStringToQuark" "" "@DEF@" +.sM +.FD 0 +#define XrmStringToName(string) XrmStringToQuark(string) +#define XrmStringToClass(string) XrmStringToQuark(string) +#define XrmStringToRepresentation(string) XrmStringToQuark(string) +.sp +XrmQuark XrmStringToQuark\^(\^\fIstring\fP\^) +.br + char *\fIstring\fP\^; +.sp +XrmQuark XrmPermStringToQuark\^(\^\fIstring\fP\^) +.br + char *\fIstring\fP\^; +.FN +.ds Ql +.IP \fIstring\fP 1i +Specifies the string for which a quark\*(Ql is to be allocated. +.LP +.eM +These functions can be used to convert from string to quark representation. +If the string is not in the Host Portable Character Encoding, +the conversion is implementation-dependent. +The string argument to +.PN XrmStringToQuark +need not be permanently allocated storage. +.PN XrmPermStringToQuark +is just like +.PN XrmStringToQuark , +except that Xlib is permitted to assume the string argument is permanently +allocated, +and, hence, that it can be used as the value to be returned by +.PN XrmQuarkToString . +.LP +For any given quark, if +.PN XrmStringToQuark +returns a non-NULL value, +all future calls will return the same value (identical address). +.LP +.sp +To convert a quark to a string, use +.PN XrmQuarkToString . +.IN "XrmQuarkToString" "" "@DEF@" +.sM +.FD 0 +#define XrmNameToString(name) XrmQuarkToString(name) +#define XrmClassToString(class) XrmQuarkToString(class) +#define XrmRepresentationToString(type) XrmQuarkToString(type) +.sp +char *XrmQuarkToString\^(\^\fIquark\fP\^) +.br + XrmQuark \fIquark\fP\^; +.FN +.IP \fIquark\fP 1i +Specifies the quark for which the equivalent string is desired. +.LP +.eM +These functions can be used to convert from quark representation to string. +The string pointed to by the return value must not be modified or freed. +The returned string is byte-for-byte equal to the original +string passed to one of the string-to-quark routines. +If no string exists for that quark, +.PN XrmQuarkToString +returns NULL. +For any given quark, if +.PN XrmQuarkToString +returns a non-NULL value, +all future calls will return the same value (identical address). +.LP +.sp +To convert a string with one or more components to a quark list, use +.PN XrmStringToQuarkList . +.IN "XrmStringToQuarkList" "" "@DEF@" +.sM +.FD 0 +#define XrmStringToNameList(str, name) XrmStringToQuarkList((str), (name)) +#define XrmStringToClassList(str, class) XrmStringToQuarkList((str), (class)) +.sp +void XrmStringToQuarkList\^(\^\fIstring\fP, \fIquarks_return\fP\^) +.br + char *\fIstring\fP\^; +.br + XrmQuarkList \fIquarks_return\fP\^; +.FN +.ds Ql \ list +.IP \fIstring\fP 1i +Specifies the string for which a quark\*(Ql is to be allocated. +.IP \fIquarks_return\fP 1i +Returns the list of quarks. +The caller must allocate sufficient space for the quarks list before calling +.PN XrmStringToQuarkList . +.LP +.eM +The +.PN XrmStringToQuarkList +function converts the null-terminated string (generally a fully qualified name) +to a list of quarks. +Note that the string must be in the valid ResourceName format +(see section 15.1). +If the string is not in the Host Portable Character Encoding, +the conversion is implementation-dependent. +.LP +A binding list is a list of type +.PN XrmBindingList +and indicates if components of name or class lists are bound tightly or loosely +(that is, if wildcarding of intermediate components is specified). +.LP +.Ds 0 +typedef enum {XrmBindTightly, XrmBindLoosely} XrmBinding, *XrmBindingList; +.De +.LP +.PN XrmBindTightly +indicates that a period separates the components, and +.PN XrmBindLoosely +indicates that an asterisk separates the components. +.LP +.sp +To convert a string with one or more components to a binding list +and a quark list, use +.PN XrmStringToBindingQuarkList . +.IN "XrmStringToBindingQuarkList" "" "@DEF@" +.sM +.FD 0 +XrmStringToBindingQuarkList\^(\^\fIstring\fP, \fIbindings_return\fP, \ +\fIquarks_return\fP\^) +.br + char *\fIstring\fP\^; +.br + XrmBindingList \fIbindings_return\fP\^; +.br + XrmQuarkList \fIquarks_return\fP\^; +.FN +.ds Ql \ list +.IP \fIstring\fP 1i +Specifies the string for which a quark\*(Ql is to be allocated. +.IP \fIbindings_return\fP 1i +Returns the binding list. +The caller must allocate sufficient space for the binding list before calling +.PN XrmStringToBindingQuarkList . +.IP \fIquarks_return\fP 1i +Returns the list of quarks. +The caller must allocate sufficient space for the quarks list before calling +.PN XrmStringToBindingQuarkList . +.LP +.eM +Component names in the list are separated by a period or +an asterisk character. +The string must be in the format of a valid ResourceName (see section 15.1). +If the string does not start with a period or an asterisk, +a tight binding is assumed. +For example, the string ``*a.b*c'' becomes: +.LP +.Ds 0 +.TA .75i 1.5i 2.25i +.ta .75i 1.5i 2.25i +quarks: a b c +bindings: loose tight loose +.De +.NH 2 +Creating and Storing Databases +.XS +\*(SN Creating and Storing Databases +.XE +.LP +.IN "XrmDatabase" "" "@DEF@" +A resource database is an opaque type, +.PN XrmDatabase . +Each database value is stored in an +.PN XrmValue +structure. +This structure consists of a size, an address, and a representation type. +The size is specified in bytes. +The representation type is a way for you to store data tagged by some +application-defined type (for example, the strings ``font'' or ``color''). +It has nothing to do with the C data type or with its class. +The +.PN XrmValue +structure is defined as: +.LP +.IN "XrmValue" "" "@DEF@" +.sM +.Ds 0 +.TA .5i 3i +.ta .5i 3i +typedef struct { + unsigned int size; + XPointer addr; +} XrmValue, *XrmValuePtr; +.De +.LP +.eM +.sp +To initialize the resource manager, use +.PN XrmInitialize . +.IN "XrmInitialize" "" "@DEF@" +.sM +.FD 0 +void XrmInitialize\^(\|); +.FN +.LP +.eM +To retrieve a database from disk, use +.PN XrmGetFileDatabase . +.IN "XrmGetFileDatabase" "" "@DEF@" +.sM +.FD 0 +XrmDatabase XrmGetFileDatabase\^(\^\fIfilename\fP\^) +.br + char *\fIfilename\fP\^; +.FN +.IP \fIfilename\fP 1i +Specifies the resource database file name. +.LP +.eM +The +.PN XrmGetFileDatabase +function opens the specified file, +creates a new resource database, and loads it with the specifications +read in from the specified file. +The specified file should contain a sequence of entries in valid ResourceLine +format (see section 15.1); the database that results from reading a file +with incorrect syntax is implementation-dependent. +The file is parsed in the current locale, +and the database is created in the current locale. +If it cannot open the specified file, +.PN XrmGetFileDatabase +returns NULL. +.LP +.sp +To store a copy of a database to disk, use +.PN XrmPutFileDatabase . +.IN "XrmPutFileDatabase" "" "@DEF@" +.sM +.FD 0 +void XrmPutFileDatabase\^(\^\fIdatabase\fP, \fIstored_db\fP\^) +.br + XrmDatabase \fIdatabase\fP\^; +.br + char *\fIstored_db\fP\^; +.FN +.IP \fIdatabase\fP 1i +Specifies the database that is to be used. +.IP \fIstored_db\fP 1i +Specifies the file name for the stored database. +.LP +.eM +The +.PN XrmPutFileDatabase +function stores a copy of the specified database in the specified file. +Text is written to the file as a sequence of entries in valid +ResourceLine format (see section 15.1). +The file is written in the locale of the database. +Entries containing resource names that are not in the Host Portable Character +Encoding or containing values that are not in the encoding of the database +locale, are written in an implementation-dependent manner. +The order in which entries are written is implementation-dependent. +Entries with representation types other than ``String'' are ignored. +.LP +.sp +To obtain a pointer to the screen-independent resources of a display, use +.PN XResourceManagerString . +.IN "XResourceManagerString" "" "@DEF@" +.sM +.FD 0 +char *XResourceManagerString\^(\^\fIdisplay\fP\^) +.br + Display *\fIdisplay\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.LP +.eM +The +.PN XResourceManagerString +function returns the RESOURCE_MANAGER property from the server's root +window of screen zero, which was returned when the connection was opened using +.PN XOpenDisplay . +The property is converted from type STRING to the current locale. +The conversion is identical to that produced by +.PN XmbTextPropertyToTextList +for a single element STRING property. +The returned string is owned by Xlib and should not be freed by the client. +The property value must be in a format that is acceptable to +.PN XrmGetStringDatabase . +If no property exists, NULL is returned. +.LP +.sp +To obtain a pointer to the screen-specific resources of a screen, use +.PN XScreenResourceString . +.IN "XScreenResourceString" "" "@DEF@" +.sM +.FD 0 +char *XScreenResourceString\^(\^\fIscreen\fP\^) +.br + Screen *\fIscreen\fP\^; +.FN +.IP \fIscreen\fP 1i +Specifies the screen. +.LP +.eM +The +.PN XScreenResourceString +function returns the SCREEN_RESOURCES property from the root window of the +specified screen. +The property is converted from type STRING to the current locale. +The conversion is identical to that produced by +.PN XmbTextPropertyToTextList +for a single element STRING property. +The property value must be in a format that is acceptable to +.PN XrmGetStringDatabase . +If no property exists, NULL is returned. +The caller is responsible for freeing the returned string by using +.PN XFree . +.LP +.sp +To create a database from a string, use +.PN XrmGetStringDatabase . +.IN "XrmGetStringDatabase" "" "@DEF@" +.sM +.FD 0 +XrmDatabase XrmGetStringDatabase\^(\^\fIdata\fP\^) +.br + char *\fIdata\fP\^; +.FN +.IP \fIdata\fP 1i +Specifies the database contents using a string. +.LP +.eM +The +.PN XrmGetStringDatabase +function creates a new database and stores the resources specified +in the specified null-terminated string. +.PN XrmGetStringDatabase +is similar to +.PN XrmGetFileDatabase +except that it reads the information out of a string instead of out of a file. +The string should contain a sequence of entries in valid ResourceLine +format (see section 15.1) terminated by a null character; +the database that results from using a string +with incorrect syntax is implementation-dependent. +The string is parsed in the current locale, +and the database is created in the current locale. +.LP +.sp +To obtain the locale name of a database, use +.PN XrmLocaleOfDatabase . +.IN "XrmLocaleOfDatabase" "" "@DEF@" +.sM +.FD 0 +char *XrmLocaleOfDatabase\^(\^\fIdatabase\fP\^) +.br + XrmDatabase \fIdatabase\fP\^; +.FN +.IP \fIdatabase\fP 1i +Specifies the resource database. +.LP +.eM +The +.PN XrmLocaleOfDatabase +function returns the name of the locale bound to the specified +database, as a null-terminated string. +The returned locale name string is owned by Xlib and should not be +modified or freed by the client. +Xlib is not permitted to free the string until the database is destroyed. +Until the string is freed, +it will not be modified by Xlib. +.LP +.sp +To destroy a resource database and free its allocated memory, use +.PN XrmDestroyDatabase . +.IN "XrmDestroyDatabase" "" "@DEF@" +.sM +.FD 0 +void XrmDestroyDatabase\^(\^\fIdatabase\fP\^) +.br + XrmDatabase \fIdatabase\fP\^; +.FN +.IP \fIdatabase\fP 1i +Specifies the resource database. +.LP +.eM +If database is NULL, +.PN XrmDestroyDatabase +returns immediately. +.LP +.sp +To associate a resource database with a display, use +.PN XrmSetDatabase . +.IN "XrmSetDatabase" "" "@DEF@" +.sM +.FD 0 +void XrmSetDatabase\^(\^\fIdisplay\fP\^, \fIdatabase\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + XrmDatabase \fIdatabase\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIdatabase\fP 1i +Specifies the resource database. +.LP +.eM +The +.PN XrmSetDatabase +function associates the specified resource database (or NULL) +with the specified display. +The database previously associated with the display (if any) is not destroyed. +A client or toolkit may find this function convenient for retaining a database +once it is constructed. +.LP +.sp +To get the resource database associated with a display, use +.PN XrmGetDatabase . +.IN "XrmGetDatabase" "" "@DEF@" +.sM +.FD 0 +XrmDatabase XrmGetDatabase\^(\^\fIdisplay\fP\^) +.br + Display *\fIdisplay\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.LP +.eM +The +.PN XrmGetDatabase +function returns the database associated with the specified display. +It returns NULL if a database has not yet been set. +.NH 2 +Merging Resource Databases +.XS +\*(SN Merging Resource Databases +.XE +.LP +To merge the contents of a resource file into a database, use +.PN XrmCombineFileDatabase . +.IN "XrmCombineFileDatabase" "" "@DEF@" +.sM +.FD 0 +Status XrmCombineFileDatabase(\^\fIfilename\fP, \fItarget_db\fP, \fIoverride\fP\^) +.br + char *\fIfilename\fP; +.br + XrmDatabase *\fItarget_db\fP\^; +.br + Bool \fIoverride\fP; +.FN +.IP \fIfilename\fP 1i +Specifies the resource database file name. +.IP \fItarget_db\fP 1i +Specifies the resource database into which the source +database is to be merged. +.IP \fIoverride\fP 1i +Specifies whether source entries override target ones. +.LP +.eM +The +.PN XrmCombineFileDatabase +function merges the contents of a resource file into a database. +If the same specifier is used for an entry in both the file and +the database, +the entry in the file will replace the entry in the database +if override is +.PN True ; +otherwise, the entry in the file is discarded. +The file is parsed in the current locale. +If the file cannot be read, +a zero status is returned; +otherwise, a nonzero status is returned. +If target_db contains NULL, +.PN XrmCombineFileDatabase +creates and returns a new database to it. +Otherwise, the database pointed to by target_db is not destroyed by the merge. +The database entries are merged without changing values or types, +regardless of the locale of the database. +The locale of the target database is not modified. +.LP +.sp +To merge the contents of one database into another database, use +.PN XrmCombineDatabase . +.IN "XrmCombineDatabase" "" "@DEF@" +.sM +.FD 0 +void XrmCombineDatabase(\^\fIsource_db\fP, \fItarget_db\fP, \fIoverride\fP\^) +.br + XrmDatabase \fIsource_db\fP, *\fItarget_db\fP\^; +.br + Bool \fIoverride\fP; +.FN +.IP \fIsource_db\fP 1i +Specifies the resource database that is to be merged into the target database. +.IP \fItarget_db\fP 1i +Specifies the resource database into which the source +database is to be merged. +.IP \fIoverride\fP 1i +Specifies whether source entries override target ones. +.LP +.eM +The +.PN XrmCombineDatabase +function merges the contents of one database into another. +If the same specifier is used for an entry in both databases, +the entry in the source_db will replace the entry in the target_db +if override is +.PN True ; +otherwise, the entry in source_db is discarded. +If target_db contains NULL, +.PN XrmCombineDatabase +simply stores source_db in it. +Otherwise, source_db is destroyed by the merge, but the database pointed +to by target_db is not destroyed. +The database entries are merged without changing values or types, +regardless of the locales of the databases. +The locale of the target database is not modified. +.LP +.sp +To merge the contents of one database into another database with override +semantics, use +.PN XrmMergeDatabases . +.IN "XrmMergeDatabases" "" "@DEF@" +.sM +.FD 0 +void XrmMergeDatabases(\^\fIsource_db\fP, \fItarget_db\fP\^) +.br + XrmDatabase \fIsource_db\fP, *\fItarget_db\fP\^; +.FN +.IP \fIsource_db\fP 1i +Specifies the resource database that is to be merged into the target database. +.IP \fItarget_db\fP 1i +Specifies the resource database into which the source +database is to be merged. +.LP +.eM +Calling the +.PN XrmMergeDatabases +function is equivalent to calling the +.PN XrmCombineDatabase +function with an override argument of +.PN True . +.NH 2 +Looking Up Resources +.XS +\*(SN Looking Up Resources +.XE +.LP +To retrieve a resource from a resource database, use +.PN XrmGetResource , +.PN XrmQGetResource , +or +.PN XrmQGetSearchResource . +.LP +.sp +.IN "XrmGetResource" "" "@DEF@" +.sM +.FD 0 +Bool XrmGetResource\^(\^\fIdatabase\fP, \fIstr_name\fP, \fIstr_class\fP, \ +\fIstr_type_return\fP, \fIvalue_return\fP\^) +.br + XrmDatabase \fIdatabase\fP\^; +.br + char *\fIstr_name\fP\^; +.br + char *\fIstr_class\fP\^; +.br + char **\fIstr_type_return\fP\^; +.br + XrmValue *\fIvalue_return\fP\^; +.FN +.IP \fIdatabase\fP 1i +Specifies the database that is to be used. +.IP \fIstr_name\fP 1i +Specifies the fully qualified name of the value being retrieved (as a string). +.IP \fIstr_class\fP 1i +Specifies the fully qualified class of the value being retrieved (as a string). +.IP \fIstr_type_return\fP 1i +Returns the representation type of the destination (as a string). +.IP \fIvalue_return\fP 1i +Returns the value in the database. +.LP +.eM +.sp +.IN "XrmQGetResource" "" "@DEF@" +.sM +.FD 0 +Bool XrmQGetResource\^(\^\fIdatabase\fP, \fIquark_name\fP, \fIquark_class\fP, \ +\fIquark_type_return\fP, \fIvalue_return\fP\^) +.br + XrmDatabase \fIdatabase\fP\^; +.br + XrmNameList \fIquark_name\fP\^; +.br + XrmClassList \fIquark_class\fP\^; +.br + XrmRepresentation *\fIquark_type_return\fP\^; +.br + XrmValue *\fIvalue_return\fP\^; +.FN +.IP \fIdatabase\fP 1i +Specifies the database that is to be used. +.IP \fIquark_name\fP 1i +Specifies the fully qualified name of the value being retrieved (as a quark). +.IP \fIquark_class\fP 1i +Specifies the fully qualified class of the value being retrieved (as a quark). +.IP \fIquark_type_return\fP 1i +Returns the representation type of the destination (as a quark). +.IP \fIvalue_return\fP 1i +Returns the value in the database. +.LP +.eM +The +.PN XrmGetResource +and +.PN XrmQGetResource +functions retrieve a resource from the specified database. +Both take a fully qualified name/class pair, a destination +resource representation, and the address of a value +(size/address pair). +The value and returned type point into database memory; +therefore, you must not modify the data. +.LP +The database only frees or overwrites entries on +.PN XrmPutResource , +.PN XrmQPutResource , +or +.PN XrmMergeDatabases . +A client that is not storing new values into the database or +is not merging the database should be safe using the address passed +back at any time until it exits. +If a resource was found, both +.PN XrmGetResource +and +.PN XrmQGetResource +return +.PN True ; +otherwise, they return +.PN False . +.LP +.sp +.EQ +delim %% +.EN +Most applications and toolkits do not make random probes +into a resource database to fetch resources. +The X toolkit access pattern for a resource database is quite stylized. +A series of from 1 to 20 probes is made with only the +last name/class differing in each probe. +The +.PN XrmGetResource +function is at worst a %2 sup n% algorithm, +where \fIn\fP is the length of the name/class list. +This can be improved upon by the application programmer by prefetching a list +of database levels that might match the first part of a name/class list. +.LP +.sp +To obtain a list of database levels, use +.PN XrmQGetSearchList . +.IN "XrmQGetSearchList" "" "@DEF@" +.sM +.FD 0 +typedef XrmHashTable *XrmSearchList; +.sp +Bool XrmQGetSearchList\^(\^\fIdatabase\fP, \fInames\fP, \fIclasses\fP, \ +\fIlist_return\fP, \fIlist_length\fP\^) +.br + XrmDatabase \fIdatabase\fP\^; +.br + XrmNameList \fInames\fP\^; +.br + XrmClassList \fIclasses\fP\^; +.br + XrmSearchList \fIlist_return\fP\^; +.br + int \fIlist_length\fP\^; +.FN +.IP \fIdatabase\fP 1i +Specifies the database that is to be used. +.IP \fInames\fP 1i +Specifies a list of resource names. +.IP \fIclasses\fP 1i +Specifies a list of resource classes. +.IP \fIlist_return\fP 1i +Returns a search list for further use. +The caller must allocate sufficient space for the list before calling +.PN XrmQGetSearchList . +.IP \fIlist_length\fP 1i +Specifies the number of entries (not the byte size) allocated for list_return. +.LP +.eM +The +.PN XrmQGetSearchList +function takes a list of names and classes +and returns a list of database levels where a match might occur. +The returned list is in best-to-worst order and +uses the same algorithm as +.PN XrmGetResource +for determining precedence. +If list_return was large enough for the search list, +.PN XrmQGetSearchList +returns +.PN True ; +otherwise, it returns +.PN False . +.LP +The size of the search list that the caller must allocate is +dependent upon the number of levels and wildcards in the resource specifiers +that are stored in the database. +The worst case length is %3 sup n%, +where \fIn\fP is the number of name or class components in names or classes. +.LP +When using +.PN XrmQGetSearchList +followed by multiple probes for resources with a common name and class prefix, +only the common prefix should be specified in the name and class list to +.PN XrmQGetSearchList . +.LP +.sp +To search resource database levels for a given resource, use +.PN XrmQGetSearchResource . +.IN "XrmQGetSearchResource" "" "@DEF@" +.sM +.FD 0 +Bool XrmQGetSearchResource\^(\^\fIlist\fP, \fIname\fP, \fIclass\fP, \ +\fItype_return\fP, \fIvalue_return\fP\^) +.br + XrmSearchList \fIlist\fP\^; +.br + XrmName \fIname\fP\^; +.br + XrmClass \fIclass\fP\^; +.br + XrmRepresentation *\fItype_return\fP\^; +.br + XrmValue *\fIvalue_return\fP\^; +.FN +.IP \fIlist\fP 1i +Specifies the search list returned by +.PN XrmQGetSearchList . +.IP \fIname\fP 1i +Specifies the resource name. +.IP \fIclass\fP 1i +Specifies the resource class. +.IP \fItype_return\fP 1i +Returns data representation type. +.IP \fIvalue_return\fP 1i +Returns the value in the database. +.LP +.eM +The +.PN XrmQGetSearchResource +function searches the specified database levels for the resource +that is fully identified by the specified name and class. +The search stops with the first match. +.PN XrmQGetSearchResource +returns +.PN True +if the resource was found; +otherwise, it returns +.PN False . +.LP +A call to +.PN XrmQGetSearchList +with a name and class list containing all but the last component +of a resource name followed by a call to +.PN XrmQGetSearchResource +with the last component name and class returns the same database entry as +.PN XrmGetResource +and +.PN XrmQGetResource +with the fully qualified name and class. +.NH 2 +Storing into a Resource Database +.XS +\*(SN Storing into a Resource Database +.XE +.LP +To store resources into the database, use +.PN XrmPutResource +or +.PN XrmQPutResource . +Both functions take a partial resource specification, a +representation type, and a value. +This value is copied into the specified database. +.LP +.sp +.IN "XrmPutResource" "" "@DEF@" +.sM +.FD 0 +void XrmPutResource\^(\^\fIdatabase\fP, \fIspecifier\fP, \fItype\fP, \fIvalue\fP\^) +.br + XrmDatabase *\fIdatabase\fP\^; +.br + char *\fIspecifier\fP\^; +.br + char *\fItype\fP\^; +.br + XrmValue *\fIvalue\fP\^; +.FN +.IP \fIdatabase\fP 1i +Specifies the resource database. +.IP \fIspecifier\fP 1i +Specifies a complete or partial specification of the resource. +.IP \fItype\fP 1i +Specifies the type of the resource. +.IP \fIvalue\fP 1i +Specifies the value of the resource, which is specified as a string. +.LP +.eM +If database contains NULL, +.PN XrmPutResource +creates a new database and returns a pointer to it. +.PN XrmPutResource +is a convenience function that calls +.PN XrmStringToBindingQuarkList +followed by: +.LP +.Ds +XrmQPutResource(database, bindings, quarks, XrmStringToQuark(type), value) +.De +If the specifier and type are not in the Host Portable Character Encoding, +the result is implementation-dependent. +The value is stored in the database without modification. +.LP +.sp +.IN "XrmQPutResource" "" "@DEF@" +.sM +.FD 0 +void XrmQPutResource\^(\^\fIdatabase\fP, \fIbindings\fP, \fIquarks\fP, \ +\fItype\fP, \fIvalue\fP\^) +.br + XrmDatabase *\fIdatabase\fP\^; +.br + XrmBindingList \fIbindings\fP\^; +.br + XrmQuarkList \fIquarks\fP\^; +.br + XrmRepresentation \fItype\fP\^; +.br + XrmValue *\fIvalue\fP\^; +.FN +.IP \fIdatabase\fP 1i +Specifies the resource database. +.IP \fIbindings\fP 1i +Specifies a list of bindings. +.IP \fIquarks\fP 1i +Specifies the complete or partial name or the class list of the resource. +.IP \fItype\fP 1i +Specifies the type of the resource. +.IP \fIvalue\fP 1i +Specifies the value of the resource, which is specified as a string. +.LP +.eM +If database contains NULL, +.PN XrmQPutResource +creates a new database and returns a pointer to it. +If a resource entry with the identical bindings and quarks already +exists in the database, the previous type and value are replaced by the new +specified type and value. +The value is stored in the database without modification. +.LP +.sp +To add a resource that is specified as a string, use +.PN XrmPutStringResource . +.IN "XrmPutStringResource" "" "@DEF@" +.sM +.FD 0 +void XrmPutStringResource\^(\^\fIdatabase\fP, \fIspecifier\fP, \fIvalue\fP\^) +.br + XrmDatabase *\fIdatabase\fP\^; +.br + char *\fIspecifier\fP\^; +.br + char *\fIvalue\fP\^; +.FN +.IP \fIdatabase\fP 1i +Specifies the resource database. +.IP \fIspecifier\fP 1i +Specifies a complete or partial specification of the resource. +.IP \fIvalue\fP 1i +Specifies the value of the resource, which is specified as a string. +.LP +.eM +If database contains NULL, +.PN XrmPutStringResource +creates a new database and returns a pointer to it. +.PN XrmPutStringResource +adds a resource with the specified value to the specified database. +.PN XrmPutStringResource +is a convenience function that first calls +.PN XrmStringToBindingQuarkList +on the specifier and then calls +.PN XrmQPutResource , +using a ``String'' representation type. +If the specifier is not in the Host Portable Character Encoding, +the result is implementation-dependent. +The value is stored in the database without modification. +.LP +.sp +To add a string resource using quarks as a specification, use +.PN XrmQPutStringResource . +.IN "XrmQPutStringResource" "" "@DEF@" +.sM +.FD 0 +void XrmQPutStringResource\^(\^\fIdatabase\fP, \fIbindings\fP, \fIquarks\fP, \ +\fIvalue\fP\^) +.br + XrmDatabase *\fIdatabase\fP\^; +.br + XrmBindingList \fIbindings\fP\^; +.br + XrmQuarkList \fIquarks\fP\^; +.br + char *\fIvalue\fP\^; +.FN +.IP \fIdatabase\fP 1i +Specifies the resource database. +.IP \fIbindings\fP 1i +Specifies a list of bindings. +.IP \fIquarks\fP 1i +Specifies the complete or partial name or the class list of the resource. +.IP \fIvalue\fP 1i +Specifies the value of the resource, which is specified as a string. +.LP +.eM +If database contains NULL, +.PN XrmQPutStringResource +creates a new database and returns a pointer to it. +.PN XrmQPutStringResource +is a convenience routine that constructs an +.PN XrmValue +for the value string (by calling +.PN strlen +to compute the size) and +then calls +.PN XrmQPutResource , +using a ``String'' representation type. +The value is stored in the database without modification. +.LP +.sp +To add a single resource entry that is specified as a string that contains +both a name and a value, use +.PN XrmPutLineResource . +.IN "XrmPutLineResource" "" "@DEF@" +.sM +.FD 0 +void XrmPutLineResource\^(\^\fIdatabase\fP, \fIline\fP\^) +.br + XrmDatabase *\fIdatabase\fP\^; +.br + char *\fIline\fP\^; +.FN +.IP \fIdatabase\fP 1i +Specifies the resource database. +.IP \fIline\fP 1i +Specifies the resource name and value pair as a single string. +.LP +.eM +If database contains NULL, +.PN XrmPutLineResource +creates a new database and returns a pointer to it. +.PN XrmPutLineResource +adds a single resource entry to the specified database. +The line should be in valid ResourceLine format (see section 15.1) +terminated by a newline or null character; +the database that results from using a string +with incorrect syntax is implementation-dependent. +The string is parsed in the locale of the database. +If the +.PN ResourceName +is not in the Host Portable Character Encoding, +the result is implementation-dependent. +Note that comment lines are not stored. +.NH 2 +Enumerating Database Entries +.XS +\*(SN Enumerating Database Entries +.XE +.LP +To enumerate the entries of a database, use +.PN XrmEnumerateDatabase . +.IN "XrmEnumerateDatabase" "" "@DEF@" +.sM +.TS +lw(.5i) lw(2i) lw(2.5i). +T{ +#define +T} T{ +.PN XrmEnumAllLevels +T} T{ +0 +T} +T{ +#define +T} T{ +.PN XrmEnumOneLevel +T} T{ +1 +T} +.TE +.FD 0 +Bool XrmEnumerateDatabase\^(\^\fIdatabase\fP, \fIname_prefix\fP, \fIclass_prefix\fP, \fImode\fP, \fIproc\fP, \fIarg\fP\^) +.br + XrmDatabase \fIdatabase\fP\^; +.br + XrmNameList \fIname_prefix\fP\^; +.br + XrmClassList \fIclass_prefix\fP\^; +.br + int \fImode\fP\^; +.br + Bool (\^*\fIproc\fP\^)\^(\^)\^; +.br + XPointer \fIarg\fP\^; +.FN +.IP \fIdatabase\fP 1i +Specifies the resource database. +.IP \fIname_prefix\fP 1i +Specifies the resource name prefix. +.IP \fIclass_prefix\fP 1i +Specifies the resource class prefix. +.IP \fImode\fP 1i +Specifies the number of levels to enumerate. +.IP \fIproc\fP 1i +Specifies the procedure that is to be called for each matching entry. +.IP \fIarg\fP 1i +Specifies the user-supplied argument that will be passed to the procedure. +.LP +.eM +The +.PN XrmEnumerateDatabase +function calls the specified procedure for each resource in the database +that would match some completion of the given name/class resource prefix. +The order in which resources are found is implementation-dependent. +If mode is +.PN XrmEnumOneLevel , +a resource must match the given name/class prefix with +just a single name and class appended. If mode is +.PN XrmEnumAllLevels , +the resource must match the given name/class prefix with one or more names and +classes appended. +If the procedure returns +.PN True , +the enumeration terminates and the function returns +.PN True . +If the procedure always returns +.PN False , +all matching resources are enumerated and the function returns +.PN False . +.LP +The procedure is called with the following arguments: +.LP +.\" Start marker code here +.Ds 0 +.TA .5i 3i +.ta .5i 3i +(*\fIproc\fP\^)(\^\fIdatabase\fP, \fIbindings\fP, \fIquarks\fP, \fItype\fP, \fIvalue\fP, \fIarg\fP\^) + XrmDatabase *\fIdatabase\fP\^; + XrmBindingList \fIbindings\fP\^; + XrmQuarkList \fIquarks\fP\^; + XrmRepresentation *\fItype\fP\^; + XrmValue *\fIvalue\fP\^; + XPointer \fIarg\fP\^; +.De +.\" End marker code here +.LP +The bindings and quarks lists are terminated by +.PN NULLQUARK . +Note that pointers +to the database and type are passed, but these values should not be modified. +.LP +The procedure must not modify the database. +If Xlib has been initialized for threads, the procedure is called with +the database locked and the result of a call by the procedure to any +Xlib function using the same database is not defined. +.NH 2 +Parsing Command Line Options +.XS +\*(SN Parsing Command Line Options +.XE +.LP +The +.PN XrmParseCommand +function can be used to parse the command line arguments to a program +and modify a resource database with selected entries from the command line. +.LP +.IN "XrmOptionKind" "" "@DEF@" +.sM +.Ds 0 +.TA .5i 2.5i +.ta .5i 2.5i +typedef enum { + XrmoptionNoArg, /* Value is specified in XrmOptionDescRec.value */ + XrmoptionIsArg, /* Value is the option string itself */ + XrmoptionStickyArg, /* Value is characters immediately following option */ + XrmoptionSepArg, /* Value is next argument in argv */ + XrmoptionResArg, /* Resource and value in next argument in argv */ + XrmoptionSkipArg, /* Ignore this option and the next argument in argv */ + XrmoptionSkipLine, /* Ignore this option and the rest of argv */ + XrmoptionSkipNArgs /* Ignore this option and the next + \ \ \ XrmOptionDescRec.value arguments in argv */ +} XrmOptionKind; +.De +.LP +.eM +Note that +.PN XrmoptionSkipArg +is equivalent to +.PN XrmoptionSkipNArgs +with the +.PN XrmOptionDescRec.value +field containing the value one. +Note also that the value zero for +.PN XrmoptionSkipNArgs +indicates that only the option itself is to be skipped. +.LP +.IN "XrmOptionDescRec" "" "@DEF@" +.sM +.Ds 0 +.TA .5i 2.5i +.ta .5i 2.5i +typedef struct { + char *option; /* Option specification string in argv */ + char *specifier; /* Binding and resource name (sans application name) */ + XrmOptionKind argKind; /* Which style of option it is */ + XPointer value; /* Value to provide if XrmoptionNoArg or + \ \ \ XrmoptionSkipNArgs */ +} XrmOptionDescRec, *XrmOptionDescList; +.De +.LP +.eM +.sp +To load a resource database from a C command line, use +.PN XrmParseCommand . +.IN "XrmParseCommand" "" "@DEF@" +.sM +.FD 0 +void XrmParseCommand\^(\^\fIdatabase\fP\^, \^\fItable\fP\^, \^\fItable_count\fP\^, \ +\^\fIname\fP\^, \^\fIargc_in_out\fP\^, \^\fIargv_in_out\fP\^) +.br + XrmDatabase *\fIdatabase\fP\^; +.br + XrmOptionDescList \fItable\fP\^; +.br + int \fItable_count\fP\^; +.br + char *\fIname\fP\^; +.br + int *\fIargc_in_out\fP\^; +.br + char **\fIargv_in_out\fP\^; +.FN +.IP \fIdatabase\fP 1i +Specifies the resource database. +.IP \fItable\fP 1i +Specifies the table of command line arguments to be parsed. +.IP \fItable_count\fP 1i +Specifies the number of entries in the table. +.IP \fIname\fP 1i +Specifies the application name. +.IP \fIargc_in_out\fP 1i +Specifies the number of arguments and returns the number of remaining arguments. +.IP \fIargv_in_out\fP 1i +Specifies the command line arguments +and returns the remaining arguments. +.LP +.eM +The +.PN XrmParseCommand +function parses an (argc, argv) pair according to the specified option table, +loads recognized options into the specified database with type ``String,'' +and modifies the (argc, argv) pair to remove all recognized options. +If database contains NULL, +.PN XrmParseCommand +creates a new database and returns a pointer to it. +Otherwise, entries are added to the database specified. +If a database is created, it is created in the current locale. +.LP +The specified table is used to parse the command line. +Recognized options in the table are removed from argv, +and entries are added to the specified resource database +in the order they occur in argv. +The table entries contain information on the option string, +the option name, the style of option, +and a value to provide if the option kind is +.PN XrmoptionNoArg . +The option names are compared byte-for-byte to arguments in argv, +independent of any locale. +The resource values given in the table are stored in the resource database +without modification. +All resource database entries are created +using a ``String'' representation type. +The argc argument specifies the number of arguments in argv +and is set on return to the remaining number of arguments that were not parsed. +The name argument should be the name of your application +for use in building the database entry. +The name argument is prefixed to the resourceName in the option table +before storing a database entry. +The name argument is treated as a single component, even if it +has embedded periods. +No separating (binding) character is inserted, +so the table must contain either a period (.) or an asterisk (*) +as the first character in each resourceName entry. +To specify a more completely qualified resource name, +the resourceName entry can contain multiple components. +If the name argument and the resourceNames are not in the +Host Portable Character Encoding, +the result is implementation-dependent. +.LP +The following provides a sample option table: +.LP +.Ds 0 +.TA 1.25i 3.25i 4.75i +.ta 1.25i 3.25i 4.75i +static XrmOptionDescRec opTable[] = { +{"\-background", "*background", XrmoptionSepArg, (XPointer) NULL}, +{"\-bd", "*borderColor", XrmoptionSepArg, (XPointer) NULL}, +{"\-bg", "*background", XrmoptionSepArg, (XPointer) NULL}, +{"\-borderwidth", "*TopLevelShell.borderWidth", XrmoptionSepArg, (XPointer) NULL}, +{"\-bordercolor", "*borderColor", XrmoptionSepArg, (XPointer) NULL}, +{"\-bw", "*TopLevelShell.borderWidth", XrmoptionSepArg, (XPointer) NULL}, +{"\-display", ".display", XrmoptionSepArg, (XPointer) NULL}, +{"\-fg", "*foreground", XrmoptionSepArg, (XPointer) NULL}, +{"\-fn", "*font", XrmoptionSepArg, (XPointer) NULL}, +{"\-font", "*font", XrmoptionSepArg, (XPointer) NULL}, +{"\-foreground", "*foreground", XrmoptionSepArg, (XPointer) NULL}, +{"\-geometry", ".TopLevelShell.geometry", XrmoptionSepArg, (XPointer) NULL}, +{"\-iconic", ".TopLevelShell.iconic", XrmoptionNoArg, (XPointer) "on"}, +{"\-name", ".name", XrmoptionSepArg, (XPointer) NULL}, +{"\-reverse", "*reverseVideo", XrmoptionNoArg, (XPointer) "on"}, +{"\-rv", "*reverseVideo", XrmoptionNoArg, (XPointer) "on"}, +{"\-synchronous", "*synchronous", XrmoptionNoArg, (XPointer) "on"}, +{"\-title", ".TopLevelShell.title", XrmoptionSepArg, (XPointer) NULL}, +{"\-xrm", NULL, XrmoptionResArg, (XPointer) NULL}, +}; +.De +.LP +In this table, if the \-background (or \-bg) option is used to set +background colors, the stored resource specifier matches all +resources of attribute background. +If the \-borderwidth option is used, +the stored resource specifier applies only to border width +attributes of class TopLevelShell (that is, outer-most windows, including +pop-up windows). +If the \-title option is used to set a window name, +only the topmost application windows receive the resource. +.LP +When parsing the command line, +any unique unambiguous abbreviation for an option name in the table is +considered a match for the option. +Note that uppercase and lowercase matter. +.bp diff --git a/libX11/specs/libX11/CH16 b/libX11/specs/libX11/CH16 new file mode 100644 index 000000000..3a21a2290 --- /dev/null +++ b/libX11/specs/libX11/CH16 @@ -0,0 +1,2364 @@ +.\" Copyright \(co 1985, 1986, 1987, 1988, 1989, 1990, 1991, 1994, 1996 X Consortium +.\" +.\" 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 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 X CONSORTIUM 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 X Consortium 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 X Consortium. +.\" +.\" Copyright \(co 1985, 1986, 1987, 1988, 1989, 1990, 1991 by +.\" Digital Equipment Corporation +.\" +.\" Portions Copyright \(co 1990, 1991 by +.\" Tektronix, Inc. +.\" +.\" Permission to use, copy, modify and distribute this documentation for +.\" any purpose and without fee is hereby granted, provided that the above +.\" copyright notice appears in all copies and that both that copyright notice +.\" and this permission notice appear in all copies, and that the names of +.\" Digital and Tektronix not be used in in advertising or publicity pertaining +.\" to this documentation without specific, written prior permission. +.\" Digital and Tektronix makes no representations about the suitability +.\" of this documentation for any purpose. +.\" It is provided ``as is'' without express or implied warranty. +.\" +\& +.sp 1 +.ce 3 +\s+1\fBChapter 16\fP\s-1 + +\s+1\fBApplication Utility Functions\fP\s-1 +.sp 2 +.nr H1 16 +.nr H2 0 +.nr H3 0 +.nr H4 0 +.nr H5 0 +.na +.LP +.XS +Chapter 16: Application Utility Functions +.XE +Once you have initialized the X system, +you can use the Xlib utility functions to: +.IP \(bu 5 +Use keyboard utility functions +.IP \(bu 5 +Use Latin-1 keyboard event functions +.IP \(bu 5 +Allocate permanent storage +.IP \(bu 5 +Parse the window geometry +.IP \(bu 5 +Manipulate regions +.IP \(bu 5 +Use cut buffers +.IP \(bu 5 +Determine the appropriate visual type +.IP \(bu 5 +Manipulate images +.IP \(bu 5 +Manipulate bitmaps +.IP \(bu 5 +Use the context manager +.LP +As a group, +the functions discussed in this chapter provide the functionality that +is frequently needed and that spans toolkits. +Many of these functions do not generate actual protocol requests to the server. +.NH 2 +Using Keyboard Utility Functions +.XS +\*(SN Using Keyboard Utility Functions +.XE +.LP +This section discusses mapping between KeyCodes and KeySyms, +classifying KeySyms, and mapping between KeySyms and string names. +The first three functions in this section operate on a cached copy of the +server keyboard mapping. +The first four KeySyms for each KeyCode +are modified according to the rules given in section 12.7. +To obtain the untransformed KeySyms defined for a key, +use the functions described in section 12.7. +.LP +.sp +To obtain a KeySym for the KeyCode of an event, use +.PN XLookupKeysym . +.IN "XLookupKeysym" "" "@DEF@" +.sM +.FD 0 +KeySym XLookupKeysym(\^\fIkey_event\fP, \fIindex\fP\^) +.br + XKeyEvent *\fIkey_event\fP\^; +.br + int \fIindex\fP\^; +.FN +.IP \fIkey_event\fP 1i +Specifies the +.PN KeyPress +or +.PN KeyRelease +event. +.IP \fIindex\fP 1i +Specifies the index into the KeySyms list for the event's KeyCode. +.LP +.eM +The +.PN XLookupKeysym +function uses a given keyboard event and the index you specified to return +the KeySym from the list that corresponds to the KeyCode member in the +.PN XKeyPressedEvent +or +.PN XKeyReleasedEvent +structure. +If no KeySym is defined for the KeyCode of the event, +.PN XLookupKeysym +returns +.PN NoSymbol . +.LP +.sp +To obtain a KeySym for a specific KeyCode, use +.PN XKeycodeToKeysym . +.IN "XKeycodeToKeysym" "" "@DEF@" +.sM +.FD 0 +KeySym XKeycodeToKeysym\^(\^\fIdisplay\fP, \fIkeycode\fP, \fIindex\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + KeyCode \fIkeycode\fP\^; +.br + int \fIindex\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIkeycode\fP 1i +Specifies the KeyCode. +.IP \fIindex\fP 1i +Specifies the element of KeyCode vector. +.LP +.eM +The +.PN XKeycodeToKeysym +function uses internal Xlib tables +and returns the KeySym defined for the specified KeyCode and +the element of the KeyCode vector. +If no symbol is defined, +.PN XKeycodeToKeysym +returns +.PN NoSymbol . +.LP +.sp +To obtain a KeyCode for a key having a specific KeySym, use +.PN XKeysymToKeycode . +.IN "XKeysymToKeycode" "" "@DEF@" +.sM +.FD 0 +KeyCode XKeysymToKeycode\^(\^\fIdisplay\fP, \fIkeysym\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + KeySym \fIkeysym\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIkeysym\fP 1i +Specifies the KeySym that is to be searched for. +.LP +.eM +If the specified KeySym is not defined for any KeyCode, +.PN XKeysymToKeycode +returns zero. +.LP +.sp +The mapping between KeyCodes and KeySyms is cached internal to Xlib. +When this information is changed at the server, an Xlib function must +be called to refresh the cache. +To refresh the stored modifier and keymap information, use +.PN XRefreshKeyboardMapping . +.IN "XRefreshKeyboardMapping" "" "@DEF@" +.sM +.FD 0 +XRefreshKeyboardMapping(\^\fIevent_map\fP\^) +.br + XMappingEvent *\fIevent_map\fP\^; +.FN +.IP \fIevent_map\fP 1i +Specifies the mapping event that is to be used. +.LP +.eM +The +.PN XRefreshKeyboardMapping +function refreshes the stored modifier and keymap information. +You usually call this function when a +.PN MappingNotify +event with a request member of +.PN MappingKeyboard +or +.PN MappingModifier +occurs. +The result is to update Xlib's knowledge of the keyboard. +.LP +.sp +To obtain the uppercase and lowercase forms of a KeySym, use +.PN XConvertCase . +.IN "XConvertCase" "" "@DEF@" +.sM +.FD 0 +void XConvertCase(\^\fIkeysym\fP, \fIlower_return\fP, \fIupper_return\fP\^) +.br + KeySym \fIkeysym\fP\^; +.br + KeySym *\fIlower_return\fP\^; +.br + KeySym *\fIupper_return\fP\^; +.FN +.ds Fn converted +.IP \fIkeysym\fP 1i +Specifies the KeySym that is to be \*(Fn. +.IP \fIlower_return\fP 1i +Returns the lowercase form of keysym, or keysym. +.IP \fIupper_return\fP 1i +Returns the uppercase form of keysym, or keysym. +.LP +.eM +The +.PN XConvertCase +function returns the uppercase and lowercase forms of the specified Keysym, +if the KeySym is subject to case conversion; +otherwise, the specified KeySym is returned to both lower_return and +upper_return. +Support for conversion of other than Latin and Cyrillic KeySyms is +implementation-dependent. +.LP +.sp +KeySyms have string names as well as numeric codes. +To convert the name of the KeySym to the KeySym code, use +.PN XStringToKeysym . +.IN "XStringToKeysym" "" "@DEF@" +.sM +.FD 0 +KeySym XStringToKeysym\^(\^\fIstring\fP\^) +.br + char *\fIstring\fP\^; +.FN +.IP \fIstring\fP 1i +Specifies the name of the KeySym that is to be converted. +.LP +.eM +Standard KeySym names are obtained from +.hN X11/keysymdef.h +by removing the XK_ prefix from each name. +KeySyms that are not part of the Xlib standard also may be obtained +with this function. +The set of KeySyms that are available in this manner +and the mechanisms by which Xlib obtains them is implementation-dependent. +.LP +If the KeySym name is not in the Host Portable Character Encoding, +the result is implementation-dependent. +If the specified string does not match a valid KeySym, +.PN XStringToKeysym +returns +.PN NoSymbol . +.LP +.sp +To convert a KeySym code to the name of the KeySym, use +.PN XKeysymToString . +.IN "XKeysymToString" "" "@DEF@" +.sM +.FD 0 +char *XKeysymToString\^(\^\fIkeysym\fP\^) +.br + KeySym \fIkeysym\fP\^; +.FN +.ds Fn converted +.IP \fIkeysym\fP 1i +Specifies the KeySym that is to be \*(Fn. +.LP +.eM +The returned string is in a static area and must not be modified. +The returned string is in the Host Portable Character Encoding. +If the specified KeySym is not defined, +.PN XKeysymToString +returns a NULL. +.NH 3 +KeySym Classification Macros +.XS +\*(SN KeySym Classification Macros +.XE +.LP +You may want to test if a KeySym is, for example, +on the keypad or on one of the function keys. +You can use KeySym macros to perform the following tests. +.LP +.sp +.sM +.FD 0 +IsCursorKey\^(\^\fIkeysym\fP\^) +.FN +.ds Fn tested +.IP \fIkeysym\fP 1i +Specifies the KeySym that is to be \*(Fn. +.LP +.eM +.IN "IsCursorKey" "" "@DEF@" +Returns +.PN True +if the specified KeySym is a cursor key. +.LP +.sp +.sM +.FD 0 +IsFunctionKey\^(\^\fIkeysym\fP\^) +.FN +.ds Fn tested +.IP \fIkeysym\fP 1i +Specifies the KeySym that is to be \*(Fn. +.LP +.eM +.IN "IsFunctionKey" "" "@DEF@" +Returns +.PN True +if the specified KeySym is a function key. +.LP +.sp +.sM +.FD 0 +IsKeypadKey\^(\^\fIkeysym\fP\^) +.FN +.ds Fn tested +.IP \fIkeysym\fP 1i +Specifies the KeySym that is to be \*(Fn. +.LP +.eM +.IN "IsKeypadKey" "" "@DEF@" +Returns +.PN True +if the specified KeySym is a standard keypad key. +.LP +.sp +.sM +.FD 0 +IsPrivateKeypadKey\^(\^\fIkeysym\fP\^) +.FN +.ds Fn tested +.IP \fIkeysym\fP 1i +Specifies the KeySym that is to be \*(Fn. +.LP +.eM +.IN "IsPrivateKeypadKey" "" "@DEF@" +Returns +.PN True +if the specified KeySym is a vendor-private keypad key. +.LP +.sp +.sM +.FD 0 +IsMiscFunctionKey\^(\^\fIkeysym\fP\^) +.FN +.ds Fn tested +.IP \fIkeysym\fP 1i +Specifies the KeySym that is to be \*(Fn. +.LP +.eM +.IN "IsMiscFunctionKey" "" "@DEF@" +Returns +.PN True +if the specified KeySym is a miscellaneous function key. +.LP +.sp +.sM +.FD 0 +IsModifierKey\^(\^\fIkeysym\fP\^) +.FN +.ds Fn tested +.IP \fIkeysym\fP 1i +Specifies the KeySym that is to be \*(Fn. +.LP +.eM +.IN "IsModifierKey" "" "@DEF@" +Returns +.PN True +if the specified KeySym is a modifier key. +.LP +.sp +.sM +.FD 0 +IsPFKey\^(\^\fIkeysym\fP\^) +.FN +.ds Fn tested +.IP \fIkeysym\fP 1i +Specifies the KeySym that is to be \*(Fn. +.LP +.eM +.IN "IsPFKey" "" "@DEF@" +Returns +.PN True +if the specified KeySym is a PF key. +.NH 2 +Using Latin-1 Keyboard Event Functions +.XS +\*(SN Using Latin-1 Keyboard Event Functions +.XE +.LP +Chapter 13 describes internationalized text input facilities, +but sometimes it is expedient to write an application that +only deals with Latin-1 characters and ASCII controls, +so Xlib provides a simple function for that purpose. +.PN XLookupString +handles the standard modifier semantics described in section 12.7. +This function does not use any of the input method facilities +described in chapter 13 and does not depend on the current locale. +.LP +.sp +To map a key event to an ISO Latin-1 string, use +.PN XLookupString . +.IN "XLookupString" "" "@DEF@" +.sM +.FD 0 +int XLookupString(\^\fIevent_struct\fP, \fIbuffer_return\fP,\ + \fIbytes_buffer\fP, \fIkeysym_return\fP, \fIstatus_in_out\fP\^) +.br + XKeyEvent *\fIevent_struct\fP\^; +.br + char *\fIbuffer_return\fP\^; +.br + int \fIbytes_buffer\fP\^; +.br + KeySym *\fIkeysym_return\fP\^; +.br + XComposeStatus *\fIstatus_in_out\fP\^; +.FN +.IP \fIevent_struct\fP 1i +Specifies the key event structure to be used. +You can pass +.PN XKeyPressedEvent +or +.PN XKeyReleasedEvent . +.IP \fIbuffer_return\fP 1i +Returns the translated characters. +.IP \fIbytes_buffer\fP 1i +Specifies the length of the buffer. +No more than bytes_buffer of translation are returned. +.IP \fIkeysym_return\fP 1i +Returns the KeySym computed from the event if this argument is not NULL. +.IP \fIstatus_in_out\fP 1i +Specifies or returns the +.PN XComposeStatus +structure or NULL. +.LP +.eM +The +.PN XLookupString +function translates a key event to a KeySym and a string. +The KeySym is obtained by using the standard interpretation of the +.PN Shift , +.PN Lock , +group, and numlock modifiers as defined in the X Protocol specification. +If the KeySym has been rebound (see +.PN XRebindKeysym ), +the bound string will be stored in the buffer. +Otherwise, the KeySym is mapped, if possible, to an ISO Latin-1 character +or (if the Control modifier is on) to an ASCII control character, +and that character is stored in the buffer. +.PN XLookupString +returns the number of characters that are stored in the buffer. +.LP +If present (non-NULL), +the +.PN XComposeStatus +structure records the state, +which is private to Xlib, +that needs preservation across calls to +.PN XLookupString +to implement compose processing. +The creation of +.PN XComposeStatus +structures is implementation-dependent; +a portable program must pass NULL for this argument. +.LP +.PN XLookupString +depends on the cached keyboard information mentioned in the +previous section, so it is necessary to use +.PN XRefreshKeyboardMapping +to keep this information up-to-date. +.LP +.sp +To rebind the meaning of a KeySym for +.PN XLookupString , +use +.PN XRebindKeysym . +.IN "XRebindKeysym" "" "@DEF@" +.sM +.FD 0 +XRebindKeysym(\^\fIdisplay\fP, \fIkeysym\fP, \fIlist\fP, \fImod_count\fP, \fIstring\fP, \fInum_bytes\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + KeySym \fIkeysym\fP\^; +.br + KeySym \fIlist\fP\^[\^]\^; +.br + int \fImod_count\fP\^; +.br + unsigned char *\fIstring\fP\^; +.br + int \fInum_bytes\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.ds Fn rebound +.IP \fIkeysym\fP 1i +Specifies the KeySym that is to be \*(Fn. +.IP \fIlist\fP 1i +Specifies the KeySyms to be used as modifiers. +.IP \fImod_count\fP 1i +Specifies the number of modifiers in the modifier list. +.IP \fIstring\fP 1i +Specifies the string that is copied and will be returned by +.PN XLookupString . +.IP \fInum_bytes\fP 1i +Specifies the number of bytes in the string argument. +.LP +.eM +The +.PN XRebindKeysym +function can be used to rebind the meaning of a KeySym for the client. +It does not redefine any key in the X server but merely +provides an easy way for long strings to be attached to keys. +.PN XLookupString +returns this string when the appropriate set of +modifier keys are pressed and when the KeySym would have been used for +the translation. +No text conversions are performed; +the client is responsible for supplying appropriately encoded strings. +Note that you can rebind a KeySym that may not exist. +.NH 2 +Allocating Permanent Storage +.XS +\*(SN Allocating Permanent Storage +.XE +.LP +To allocate some memory you will never give back, use +.PN Xpermalloc . +.IN "Xpermalloc" "" "@DEF@" +.sM +.FD 0 +char *Xpermalloc\^(\^\fIsize\fP\^) +.br + unsigned int \fIsize\fP\^; +.FN +.LP +.eM +The +.PN Xpermalloc +function allocates storage that can never be freed for the life of the +program. The memory is allocated with alignment for the C type double. +This function may provide some performance and space savings over +the standard operating system memory allocator. +.NH 2 +Parsing the Window Geometry +.XS +\*(SN Parsing the Window Geometry +.XE +.LP +To parse standard window geometry strings, use +.PN XParseGeometry . +.IN "Window" "determining location" +.IN "XParseGeometry" "" "@DEF@" +.LP +.sM +.FD 0 +int XParseGeometry\^(\^\fIparsestring\fP\^, \fIx_return\fP\^, \fIy_return\fP\^, \fIwidth_return\fP\^, \fIheight_return\fP\^) +.br + char *\fIparsestring\fP\^; +.br + int *\fIx_return\fP\^, *\fIy_return\fP\^; +.br + unsigned int *\fIwidth_return\fP\^, *\fIheight_return\fP\^; +.FN +.IP \fIparsestring\fP 1i +Specifies the string you want to parse. +.IP \fIx_return\fP 1i +.br +.ns +.IP \fIy_return\fP 1i +Return the x and y offsets. +.IP \fIwidth_return\fP 1i +.br +.ns +.IP \fIheight_return\fP 1i +Return the width and height determined. +.LP +.eM +By convention, +X applications use a standard string to indicate window size and placement. +.PN XParseGeometry +makes it easier to conform to this standard because it allows you +to parse the standard window geometry. +Specifically, this function lets you parse strings of the form: +.LP +.\" Start marker code here +.Ds +[=][<\fIwidth\fP>{xX}<\fIheight\fP>][{+-}<\fIxoffset\fP>{+-}<\fIyoffset\fP>] +.De +.\" End marker code here +.LP +The fields map into the arguments associated with this function. +(Items enclosed in <\^> are integers, items in [\^] are optional, and +items enclosed in {\^} indicate ``choose one of.'' +Note that the brackets should not appear in the actual string.) +If the string is not in the Host Portable Character Encoding, +the result is implementation-dependent. +.LP +The +.PN XParseGeometry +function returns a bitmask that indicates which of the four values (width, +height, xoffset, and yoffset) were actually found in the string +and whether the x and y values are negative. +By convention, \-0 is not equal to +0, because the user needs to +be able to say ``position the window relative to the right or bottom edge.'' +For each value found, the corresponding argument is updated. +For each value not found, the argument is left unchanged. +The bits are represented by +.PN XValue , +.PN YValue , +.PN WidthValue , +.PN HeightValue , +.PN XNegative , +or +.PN YNegative +and are defined in +.hN X11/Xutil.h . +They will be set whenever one of the values is defined +or one of the signs is set. +.LP +If the function returns either the +.PN XValue +or +.PN YValue +flag, +you should place the window at the requested position. +.sp +.LP +To construct a window's geometry information, use +.PN XWMGeometry . +.IN "XWMGeometry" "" "@DEF@" +.sM +.FD 0 +int XWMGeometry\^(\^\fIdisplay\fP, \fIscreen\fP, \fIuser_geom\fP, \ +\fIdef_geom\fP, \fIbwidth\fP, \fIhints\fP, \fIx_return\fP, \fIy_return\fP, +.br + \fIwidth_return\fP, \fIheight_return\fP, \fIgravity_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + int \fIscreen\fP\^; +.br + char *\fIuser_geom\fP\^; +.br + char *\fIdef_geom\fP\^; +.br + unsigned int \fIbwidth\fP\^; +.br + XSizeHints *\fIhints\fP\^; +.br + int *\fIx_return\fP, *\fIy_return\fP\^; +.br + int *\fIwidth_return\fP\^; +.br + int *\fIheight_return\fP\^; +.br + int *\fIgravity_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIscreen\fP 1i +Specifies the screen. +.IP \fIuser_geom\fP 1i +Specifies the user-specified geometry or NULL. +.IP \fIdef_geom\fP 1i +Specifies the application's default geometry or NULL. +.IP \fIbwidth\fP 1i +Specifies the border width. +.IP \fIhints\fP 1i +Specifies the size hints for the window in its normal state. +.IP \fIx_return\fP 1i +.br +.ns +.IP \fIy_return\fP 1i +Return the x and y offsets. +.IP \fIwidth_return\fP 1i +.br +.ns +.IP \fIheight_return\fP 1i +Return the width and height determined. +.IP \fIgravity_return\fP 1i +Returns the window gravity. +.LP +.eM +The +.PN XWMGeometry +function combines any geometry information (given in the format used by +.PN XParseGeometry ) +specified by the user and by the calling program with size hints +(usually the ones to be stored in WM_NORMAL_HINTS) and returns the position, +size, and gravity +.Pn ( NorthWestGravity , +.PN NorthEastGravity , +.PN SouthEastGravity , +or +.PN SouthWestGravity ) +that describe the window. +If the base size is not set in the +.PN XSizeHints +structure, +the minimum size is used if set. +Otherwise, a base size of zero is assumed. +If no minimum size is set in the hints structure, +the base size is used. +A mask (in the form returned by +.PN XParseGeometry ) +that describes which values came from the user specification +and whether or not the position coordinates are relative +to the right and bottom edges is returned. +Note that these coordinates will have already been accounted for +in the x_return and y_return values. +.LP +Note that invalid geometry specifications can cause a width or height +of zero to be returned. +The caller may pass the address of the hints win_gravity field +as gravity_return to update the hints directly. +.NH 2 +Manipulating Regions +.XS +\*(SN Manipulating Regions +.XE +.LP +Regions are arbitrary sets of pixel locations. +Xlib provides functions for manipulating regions. +The opaque type +.PN Region +is defined in +.hN X11/Xutil.h . +Xlib provides functions that you can use to manipulate regions. +This section discusses how to: +.IP \(bu 5 +Create, copy, or destroy regions +.IP \(bu 5 +Move or shrink regions +.IP \(bu 5 +Compute with regions +.IP \(bu 5 +Determine if regions are empty or equal +.IP \(bu 5 +Locate a point or rectangle in a region +.NH 3 +Creating, Copying, or Destroying Regions +.XS +\*(SN Creating, Copying, or Destroying Regions +.XE +.LP +To create a new empty region, use +.PN XCreateRegion . +.IN "XCreateRegion" "" "@DEF@" +.sM +.FD 0 +Region XCreateRegion\^() +.FN +.LP +.eM +.sp +To generate a region from a polygon, use +.PN XPolygonRegion . +.IN "XPolygonRegion" "" "@DEF@" +.sM +.FD 0 +Region XPolygonRegion\^(\^\fIpoints\fP\^, \fIn\fP\^, \fIfill_rule\fP\^) +.br + XPoint \fIpoints[]\fP\^; +.br + int \fIn\fP\^; +.br + int \fIfill_rule\fP\^; +.FN +.IP \fIpoints\fP 1i +Specifies an array of points. +.IP \fIn\fP 1i +Specifies the number of points in the polygon. +.IP \fIfill_rule\fP 1i +Specifies the fill-rule you want to set for the specified GC. +You can pass +.PN EvenOddRule +or +.PN WindingRule . +.LP +.eM +The +.PN XPolygonRegion +function returns a region for the polygon defined by the points array. +For an explanation of fill_rule, +see +.PN XCreateGC . +.LP +.sp +To set the clip-mask of a GC to a region, use +.PN XSetRegion . +.IN "XSetRegion" "" "@DEF@" +.sM +.FD 0 +XSetRegion\^(\^\fIdisplay\fP, \fIgc\fP\^, \fIr\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + GC \fIgc\fP\^; +.br + Region \fIr\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIgc\fP 1i +Specifies the GC. +.IP \fIr\fP 1i +Specifies the region. +.LP +.eM +The +.PN XSetRegion +function sets the clip-mask in the GC to the specified region. +The region is specified relative to the drawable's origin. +The resulting GC clip origin is implementation-dependent. +Once it is set in the GC, +the region can be destroyed. +.LP +.sp +To deallocate the storage associated with a specified region, use +.PN XDestroyRegion . +.IN "XDestroyRegion" "" "@DEF@" +.sM +.FD 0 +XDestroyRegion\^(\^\fIr\fP\^) +.br + Region \fIr\fP\^; +.FN +.IP \fIr\fP 1i +Specifies the region. +.LP +.eM +.NH 3 +Moving or Shrinking Regions +.XS +\*(SN Moving or Shrinking Regions +.XE +.LP +To move a region by a specified amount, use +.PN XOffsetRegion . +.IN "XOffsetRegion" "" "@DEF@" +.sM +.FD 0 +XOffsetRegion\^(\^\fIr\fP\^, \fIdx\fP\^, \fIdy\fP\^) +.br + Region \fIr\fP\^; +.br + int \fIdx\fP\^, \fIdy\fP\^; +.FN +.IP \fIr\fP 1i +Specifies the region. +.ds Dy move +.IP \fIdx\fP 1i +.br +.ns +.IP \fIdy\fP 1i +Specify the x and y coordinates, +which define the amount you want to \*(Dy the specified region. +.LP +.eM +.sp +To reduce a region by a specified amount, use +.PN XShrinkRegion . +.IN "XShrinkRegion" "" "@DEF@" +.sM +.FD 0 +XShrinkRegion\^(\^\fIr\fP\^, \fIdx\fP\^, \fIdy\fP\^) +.br + Region \fIr\fP\^; +.br + int \fIdx\fP\^, \fIdy\fP\^; +.FN +.IP \fIr\fP 1i +Specifies the region. +.ds Dy shrink +.IP \fIdx\fP 1i +.br +.ns +.IP \fIdy\fP 1i +Specify the x and y coordinates, +which define the amount you want to \*(Dy the specified region. +.LP +.eM +Positive values shrink the size of the region, +and negative values expand the region. +.NH 3 +Computing with Regions +.XS +\*(SN Computing with Regions +.XE +.LP +.sp +To generate the smallest rectangle enclosing a region, use +.PN XClipBox . +.IN "XClipBox" "" "@DEF@" +.sM +.FD 0 +XClipBox\^(\^\fIr\fP\^, \fIrect_return\fP\^) +.br + Region \fIr\fP\^; +.br + XRectangle *\fIrect_return\fP\^; +.FN +.IP \fIr\fP 1i +Specifies the region. +.IP \fIrect_return\fP 1i +Returns the smallest enclosing rectangle. +.LP +.eM +The +.PN XClipBox +function returns the smallest rectangle enclosing the specified region. +.sp +.LP +To compute the intersection of two regions, use +.PN XIntersectRegion . +.IN "XIntersectRegion" "" "@DEF@" +.sM +.FD 0 +XIntersectRegion\^(\^\fIsra\fP\^, \fIsrb\fP\^, \fIdr_return\fP\^) +.br + Region \fIsra\fP\^, \fIsrb\fP\^, \fIdr_return\fP\^; +.FN +.IP \fIsra\fP 1i +.br +.ns +.IP \fIsrb\fP 1i +Specify the two regions with which you want to perform the computation. +.IP \fIdr_return\fP 1i +Returns the result of the computation. +.LP +.eM +.sp +To compute the union of two regions, use +.PN XUnionRegion . +.IN "XUnionRegion" "" "@DEF@" +.sM +.FD 0 +XUnionRegion\^(\^\fIsra\fP\^, \fIsrb\fP\^, \fIdr_return\fP\^) +.br + Region \fIsra\fP\^, \fIsrb\fP\^, \fIdr_return\fP\^; +.FN +.IP \fIsra\fP 1i +.br +.ns +.IP \fIsrb\fP 1i +Specify the two regions with which you want to perform the computation. +.IP \fIdr_return\fP 1i +Returns the result of the computation. +.LP +.eM +.sp +To create a union of a source region and a rectangle, use +.PN XUnionRectWithRegion . +.IN "XUnionRectWithRegion" "" "@DEF@" +.sM +.FD 0 +XUnionRectWithRegion\^(\^\fIrectangle\fP, \fIsrc_region\fP, \ +\fIdest_region_return\fP\^) +.br + XRectangle *\fIrectangle\fP\^; +.br + Region \fIsrc_region\fP\^; +.br + Region \fIdest_region_return\fP\^; +.FN +.IP \fIrectangle\fP 1i +Specifies the rectangle. +.IP \fIsrc_region\fP 1i +Specifies the source region to be used. +.IP \fIdest_region_return\fP 1i +Returns the destination region. +.LP +.eM +The +.PN XUnionRectWithRegion +function updates the destination region from a union of the specified rectangle +and the specified source region. +.LP +.sp +To subtract two regions, use +.PN XSubtractRegion . +.IN "XSubtractRegion" "" "@DEF@" +.sM +.FD 0 +XSubtractRegion\^(\^\fIsra\fP\^, \fIsrb\fP\^, \fIdr_return\fP\^) +.br + Region \fIsra\fP\^, \fIsrb\fP\^, \fIdr_return\fP\^; +.FN +.IP \fIsra\fP 1i +.br +.ns +.IP \fIsrb\fP 1i +Specify the two regions with which you want to perform the computation. +.IP \fIdr_return\fP 1i +Returns the result of the computation. +.LP +.eM +The +.PN XSubtractRegion +function subtracts srb from sra and stores the results in dr_return. +.LP +.sp +To calculate the difference between the union and intersection +of two regions, use +.PN XXorRegion . +.IN "XXorRegion" "" "@DEF@" +.sM +.FD 0 +XXorRegion\^(\^\fIsra\fP\^, \fIsrb\fP\^, \fIdr_return\fP\^) +.br + Region \fIsra\fP\^, \fIsrb\fP\^, \fIdr_return\fP\^; +.FN +.IP \fIsra\fP 1i +.br +.ns +.IP \fIsrb\fP 1i +Specify the two regions with which you want to perform the computation. +.IP \fIdr_return\fP 1i +Returns the result of the computation. +.LP +.eM +.NH 3 +Determining if Regions Are Empty or Equal +.XS +\*(SN Determining if Regions Are Empty or Equal +.XE +.LP +To determine if the specified region is empty, use +.PN XEmptyRegion . +.IN "XEmptyRegion" "" "@DEF@" +.sM +.FD 0 +Bool XEmptyRegion\^(\^\fIr\fP\^) +.br + Region \fIr\fP\^; +.FN +.IP \fIr\fP 1i +Specifies the region. +.LP +.eM +The +.PN XEmptyRegion +function returns +.PN True +if the region is empty. +.LP +.sp +To determine if two regions have the same offset, size, and shape, use +.PN XEqualRegion . +.IN "XEqualRegion" "" "@DEF@" +.sM +.FD 0 +Bool XEqualRegion\^(\^\fIr1\fP\^, \fIr2\fP\^) +.br + Region \fIr1\fP\^, \fIr2\fP\^; +.FN +.IP \fIr1\fP 1i +.br +.ns +.IP \fIr2\fP 1i +Specify the two regions. +.LP +.eM +The +.PN XEqualRegion +function returns +.PN True +if the two regions have the same offset, size, and shape. +.NH 3 +Locating a Point or a Rectangle in a Region +.XS +\*(SN Locating a Point or a Rectangle in a Region +.XE +.LP +To determine if a specified point resides in a specified region, use +.PN XPointInRegion . +.IN "XPointInRegion" "" "@DEF@" +.sM +.FD 0 +Bool XPointInRegion\^(\^\fIr\fP\^, \fIx\fP\^, \fIy\fP\^) +.br + Region \fIr\fP\^; +.br + int \fIx\fP\^, \fIy\fP\^; +.FN +.IP \fIr\fP 1i +Specifies the region. +.ds Xy , which define the point +.IP \fIx\fP 1i +.br +.ns +.IP \fIy\fP 1i +Specify the x and y coordinates\*(Xy. +.LP +.eM +The +.PN XPointInRegion +function returns +.PN True +if the point (x, y) is contained in the region r. +.LP +.sp +To determine if a specified rectangle is inside a region, use +.PN XRectInRegion . +.IN "XRectInRegion" "" "@DEF@" +.sM +.FD 0 +int XRectInRegion\^(\^\fIr\fP\^, \fIx\fP\^, \fIy\fP\^, \fIwidth\fP\^, \fIheight\fP\^) +.br + Region \fIr\fP\^; +.br + int \fIx\fP\^, \fIy\fP\^; +.br + unsigned int \fIwidth\fP\^, \fIheight\fP\^; +.FN +.IP \fIr\fP 1i +Specifies the region. +.ds Xy , which define the coordinates of the upper-left corner of the rectangle +.IP \fIx\fP 1i +.br +.ns +.IP \fIy\fP 1i +Specify the x and y coordinates\*(Xy. +.ds Wh , which define the rectangle +.IP \fIwidth\fP 1i +.br +.ns +.IP \fIheight\fP 1i +Specify the width and height\*(Wh. +.LP +.eM +The +.PN XRectInRegion +function returns +.PN RectangleIn +if the rectangle is entirely in the specified region, +.PN RectangleOut +if the rectangle is entirely out of the specified region, +and +.PN RectanglePart +if the rectangle is partially in the specified region. +.NH 2 +Using Cut Buffers +.XS +\*(SN Using Cut Buffers +.XE +.LP +.IN "Cut Buffers" +Xlib provides functions to manipulate cut buffers, +a very simple form of cut-and-paste inter-client communication. +Selections are a much more powerful and useful mechanism for +interchanging data between clients (see section 4.5) +and generally should be used instead of cut buffers. +.LP +Cut buffers are implemented as properties on the first root window +of the display. +The buffers can only contain text, in the STRING encoding. +The text encoding is not changed by Xlib when fetching or storing. +Eight buffers are provided +and can be accessed as a ring or as explicit buffers (numbered 0 through 7). +.LP +.sp +To store data in cut buffer 0, use +.PN XStoreBytes . +.IN "XStoreBytes" "" "@DEF@" +.sM +.FD 0 +XStoreBytes\^(\^\fIdisplay\fP, \fIbytes\fP\^, \fInbytes\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + char *\fIbytes\fP\^; +.br + int \^\fInbytes\fP\^; +.br +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIbytes\fP 1i +Specifies the bytes, which are not necessarily ASCII or null-terminated. +.IP \fInbytes\fP 1i +Specifies the number of bytes to be stored. +.LP +.eM +The data can have embedded null characters +and need not be null-terminated. +The cut buffer's contents can be retrieved later by +any client calling +.PN XFetchBytes . +.LP +.PN XStoreBytes +can generate a +.PN BadAlloc +error. +.LP +.sp +To store data in a specified cut buffer, use +.PN XStoreBuffer . +.IN "XStoreBuffer" "" "@DEF@" +.sM +.FD 0 +XStoreBuffer\^(\^\fIdisplay\fP, \fIbytes\fP\^, \fInbytes\fP\^, \fIbuffer\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + char *\fIbytes\fP\^; +.br + int \^\fInbytes\fP\^; +.br + int \fIbuffer\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIbytes\fP 1i +Specifies the bytes, which are not necessarily ASCII or null-terminated. +.IP \fInbytes\fP 1i +Specifies the number of bytes to be stored. +.ds Fn in which you want to store the bytes +.IP \fIbuffer\fP 1i +Specifies the buffer \*(Fn. +.LP +.eM +If an invalid buffer is specified, the call has no effect. +The data can have embedded null characters +and need not be null-terminated. +.LP +.PN XStoreBuffer +can generate a +.PN BadAlloc +error. +.LP +.sp +To return data from cut buffer 0, use +.PN XFetchBytes . +.IN "XFetchBytes" "" "@DEF@" +.sM +.FD 0 +char *XFetchBytes\^(\^\fIdisplay\fP, \fInbytes_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + int *\fInbytes_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fInbytes_return\fP 1i +Returns the number of bytes in the buffer. +.LP +.eM +The +.PN XFetchBytes +function +returns the number of bytes in the nbytes_return argument, +if the buffer contains data. +Otherwise, the function +returns NULL and sets nbytes to 0. +The appropriate amount of storage is allocated and the pointer returned. +The client must free this storage when finished with it by calling +.PN XFree . +.LP +.sp +To return data from a specified cut buffer, use +.PN XFetchBuffer . +.IN "XFetchBuffer" "" "@DEF@" +.sM +.FD 0 +char *XFetchBuffer\^(\^\fIdisplay\fP, \fInbytes_return\fP\^, \fIbuffer\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + int *\fInbytes_return\fP\^; +.br + int \fIbuffer\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fInbytes_return\fP 1i +Returns the number of bytes in the buffer. +.ds Fn from which you want the stored data returned +.IP \fIbuffer\fP 1i +Specifies the buffer \*(Fn. +.LP +.eM +The +.PN XFetchBuffer +function returns zero to the nbytes_return argument +if there is no data in the buffer or if an invalid +buffer is specified. +.LP +.sp +To rotate the cut buffers, use +.PN XRotateBuffers . +.IN "XRotateBuffers" "" "@DEF@" +.sM +.FD 0 +XRotateBuffers\^(\^\fIdisplay\fP, \fIrotate\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + int \fIrotate\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIrotate\fP 1i +Specifies how much to rotate the cut buffers. +.LP +.eM +The +.PN XRotateBuffers +function rotates the cut +buffers, such that buffer 0 becomes buffer n, +buffer 1 becomes n + 1 mod 8, and so on. +This cut buffer numbering is global to the display. +Note that +.PN XRotateBuffers +generates +.PN BadMatch +errors if any of the eight buffers have not been created. +.NH 2 +Determining the Appropriate Visual Type +.XS +\*(SN Determining the Appropriate Visual Type +.XE +.LP +A single display can support multiple screens. +Each screen can have several different visual types supported +at different depths. +You can use the functions described in this section to determine +which visual to use for your application. +.LP +The functions in this section use the visual information masks and the +.PN XVisualInfo +structure, +which is defined in +.hN X11/Xutil.h +and contains: +.sM +.LP +/* Visual information mask bits */ +.TS +lw(.5i) lw(2.5i) lw(.8i). +T{ +#define +T} T{ +.PN VisualNoMask +T} T{ +0x0 +T} +T{ +#define +T} T{ +.PN VisualIDMask +T} T{ +0x1 +T} +T{ +#define +T} T{ +.PN VisualScreenMask +T} T{ +0x2 +T} +T{ +#define +T} T{ +.PN VisualDepthMask +T} T{ +0x4 +T} +T{ +#define +T} T{ +.PN VisualClassMask +T} T{ +0x8 +T} +T{ +#define +T} T{ +.PN VisualRedMaskMask +T} T{ +0x10 +T} +T{ +#define +T} T{ +.PN VisualGreenMaskMask +T} T{ +0x20 +T} +T{ +#define +T} T{ +.PN VisualBlueMaskMask +T} T{ +0x40 +T} +T{ +#define +T} T{ +.PN VisualColormapSizeMask +T} T{ +0x80 +T} +T{ +#define +T} T{ +.PN VisualBitsPerRGBMask +T} T{ +0x100 +T} +T{ +#define +T} T{ +.PN VisualAllMask +T} T{ +0x1FF +T} +.TE +.IN "XVisualInfo" "" "@DEF@" +.Ds 0 +.TA .5i 3i +.ta .5i 3i +/* Values */ + +typedef struct { + Visual *visual; + VisualID visualid; + int screen; + unsigned int depth; + int class; + unsigned long red_mask; + unsigned long green_mask; + unsigned long blue_mask; + int colormap_size; + int bits_per_rgb; +} XVisualInfo; +.De +.LP +.eM +To obtain a list of visual information structures that match a specified +template, use +.PN XGetVisualInfo . +.IN "XGetVisualInfo" "" "@DEF@" +.sM +.FD 0 +XVisualInfo *XGetVisualInfo\^(\^\fIdisplay\fP, \fIvinfo_mask\fP, \fIvinfo_template\fP, \fInitems_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + long \fIvinfo_mask\fP\^; +.br + XVisualInfo *\fIvinfo_template\fP\^; +.br + int *\fInitems_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIvinfo_mask\fP 1i +Specifies the visual mask value. +.IP \fIvinfo_template\fP 1i +Specifies the visual attributes that are to be used in matching the visual +structures. +.IP \fInitems_return\fP 1i +Returns the number of matching visual structures. +.LP +.eM +The +.PN XGetVisualInfo +function returns a list of visual structures that have attributes +equal to the attributes specified by vinfo_template. +If no visual structures match the template using the specified vinfo_mask, +.PN XGetVisualInfo +returns a NULL. +To free the data returned by this function, use +.PN XFree . +.LP +.sp +To obtain the visual information that matches the specified depth and +class of the screen, use +.PN XMatchVisualInfo . +.IN "XMatchVisualInfo" "" "@DEF@" +.sM +.FD 0 +Status XMatchVisualInfo\^(\^\fIdisplay\fP, \fIscreen\fP, \fIdepth\fP, \fIclass\fP, \fIvinfo_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + int \fIscreen\fP\^; +.br + int \fIdepth\fP\^; +.br + int \fIclass\fP\^; +.br + XVisualInfo *\fIvinfo_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIscreen\fP 1i +Specifies the screen. +.IP \fIdepth\fP 1i +Specifies the depth of the screen. +.IP \fIclass\fP 1i +Specifies the class of the screen. +.IP \fIvinfo_return\fP 1i +Returns the matched visual information. +.LP +.eM +The +.PN XMatchVisualInfo +function returns the visual information for a visual that matches the specified +depth and class for a screen. +Because multiple visuals that match the specified depth and class can exist, +the exact visual chosen is undefined. +If a visual is found, +.PN XMatchVisualInfo +returns nonzero and the information on the visual to vinfo_return. +Otherwise, when a visual is not found, +.PN XMatchVisualInfo +returns zero. +.NH 2 +Manipulating Images +.XS +\*(SN Manipulating Images +.XE +.LP +Xlib provides several functions that perform basic operations on images. +All operations on images are defined using an +.PN XImage +structure, +as defined in +.hN X11/Xlib.h . +Because the number of different types of image formats can be very large, +this hides details of image storage properly from applications. +.LP +This section describes the functions for generic operations on images. +Manufacturers can provide very fast implementations of these for the +formats frequently encountered on their hardware. +These functions are neither sufficient nor desirable to use for general image +processing. +Rather, they are here to provide minimal functions on screen format +images. +The basic operations for getting and putting images are +.PN XGetImage +and +.PN XPutImage . +.LP +Note that no functions have been defined, as yet, to read and write images +to and from disk files. +.LP +The +.PN XImage +structure describes an image as it exists in the client's memory. +The user can request that some of the members such as height, width, +and xoffset be changed when the image is sent to the server. +Note that bytes_per_line in concert with offset can be used to +extract a subset of the image. +Other members (for example, byte order, bitmap_unit, and so forth) +are characteristics of both the image and the server. +If these members +differ between the image and the server, +.PN XPutImage +makes the appropriate conversions. +The first byte of the first line of +plane n must be located at the address (data + (n * height * bytes_per_line)). +For a description of the +.PN XImage +structure, +see section 8.7. +.LP +.sp +To allocate an +.PN XImage +structure and initialize it with image format values from a display, use +.PN XCreateImage . +.IN "XCreateImage" "" "@DEF@" +.sM +.FD 0 +XImage *XCreateImage\^(\^\fIdisplay\fP, \fIvisual\fP, \fIdepth\fP, \fIformat\fP, \fIoffset\fP, \fIdata\fP, \fIwidth\fP, \fIheight\fP\^, \fIbitmap_pad\fP, +.br + \fIbytes_per_line\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Visual *\fIvisual\fP\^; +.br + unsigned int \fIdepth\fP\^; +.br + int \fIformat\fP\^; +.br + int \fIoffset\fP\^; +.br + char *\fIdata\fP\^; +.br + unsigned int \fIwidth\fP\^; +.br + unsigned int \fIheight\fP\^; +.br + int \fIbitmap_pad\fP\^; +.br + int \fIbytes_per_line\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIvisual\fP 1i +Specifies the +.PN Visual +structure. +.IP \fIdepth\fP 1i +Specifies the depth of the image. +.IP \fIformat\fP 1i +Specifies the format for the image. +You can pass +.PN XYBitmap , +.PN XYPixmap , +or +.PN ZPixmap . +.IP \fIoffset\fP 1i +Specifies the number of pixels to ignore at the beginning of the scanline. +.IP \fIdata\fP 1i +Specifies the image data. +.IP \fIwidth\fP 1i +Specifies the width of the image, in pixels. +.IP \fIheight\fP 1i +Specifies the height of the image, in pixels. +.IP \fIbitmap_pad\fP 1i +Specifies the quantum of a scanline (8, 16, or 32). +In other words, the start of one scanline is separated in client memory from +the start of the next scanline by an integer multiple of this many bits. +.IP \fIbytes_per_line\fP 1i +Specifies the number of bytes in the client image between +the start of one scanline and the start of the next. +.LP +.eM +The +.PN XCreateImage +function allocates the memory needed for an +.PN XImage +structure for the +specified display but does not allocate space for the image itself. +Rather, it initializes the structure byte-order, bit-order, and bitmap-unit +values from the display and returns a pointer to the +.PN XImage +structure. +The red, green, and blue mask values are defined for Z format images only +and are derived from the +.PN Visual +structure passed in. +Other values also are passed in. +The offset permits the rapid displaying of the image without requiring each +scanline to be shifted into position. +If you pass a zero value in bytes_per_line, +Xlib assumes that the scanlines are contiguous +in memory and calculates the value of bytes_per_line itself. +.LP +Note that when the image is created using +.PN XCreateImage , +.PN XGetImage , +or +.PN XSubImage , +the destroy procedure that the +.PN XDestroyImage +function calls frees both the image structure +and the data pointed to by the image structure. +.LP +The basic functions used to get a pixel, set a pixel, create a subimage, +and add a constant value to an image are defined in the image object. +The functions in this section are really macro invocations of the functions +in the image object and are defined in +.hN X11/Xutil.h . +.LP +.sp +To obtain a pixel value in an image, use +.PN XGetPixel . +.IN "XGetPixel" "" "@DEF@" +.sM +.FD 0 +unsigned long XGetPixel\^(\^\fIximage\fP, \fIx\fP, \fIy\fP\^) +.br + XImage *\fIximage\fP\^; +.br + int \fIx\fP\^; +.br + int \fIy\fP\^; +.FN +.IP \fIximage\fP 1i +Specifies the image. +.IP \fIx\fP 1i +.br +.ns +.IP \fIy\fP 1i +Specify the x and y coordinates. +.LP +.eM +The +.PN XGetPixel +function returns the specified pixel from the named image. +The pixel value is returned in normalized format (that is, +the least significant byte of the long is the least significant byte +of the pixel). +The image must contain the x and y coordinates. +.LP +.sp +To set a pixel value in an image, use +.PN XPutPixel . +.IN "XPutPixel" "" "@DEF@" +.sM +.FD 0 +XPutPixel\^(\^\fIximage\fP, \fIx\fP, \fIy\fP, \fIpixel\fP\^) +.br + XImage *\fIximage\fP\^; +.br + int \fIx\fP\^; +.br + int \fIy\fP\^; +.br + unsigned long \fIpixel\fP\^; +.FN +.IP \fIximage\fP 1i +Specifies the image. +.IP \fIx\fP 1i +.br +.ns +.IP \fIy\fP 1i +Specify the x and y coordinates. +.IP \fIpixel\fP 1i +Specifies the new pixel value. +.LP +.eM +The +.PN XPutPixel +function overwrites the pixel in the named image with the specified pixel value. +The input pixel value must be in normalized format +(that is, the least significant byte of the long is the least significant +byte of the pixel). +The image must contain the x and y coordinates. +.LP +.sp +To create a subimage, use +.PN XSubImage . +.IN "XSubImage" "" "@DEF@" +.sM +.FD 0 +XImage *XSubImage\^(\^\fIximage\fP, \fIx\fP, \fIy\fP, \fIsubimage_width\fP, \fIsubimage_height\fP\^) +.br + XImage *\fIximage\fP\^; +.br + int \fIx\fP\^; +.br + int \fIy\fP\^; +.br + unsigned int \fIsubimage_width\fP\^; +.br + unsigned int \fIsubimage_height\fP\^; +.FN +.IP \fIximage\fP 1i +Specifies the image. +.IP \fIx\fP 1i +.br +.ns +.IP \fIy\fP 1i +Specify the x and y coordinates. +.IP \fIsubimage_width\fP 1i +Specifies the width of the new subimage, in pixels. +.IP \fIsubimage_height\fP 1i +Specifies the height of the new subimage, in pixels. +.LP +.eM +The +.PN XSubImage +function creates a new image that is a subsection of an existing one. +It allocates the memory necessary for the new +.PN XImage +structure +and returns a pointer to the new image. +The data is copied from the source image, +and the image must contain the rectangle defined by x, y, subimage_width, +and subimage_height. +.LP +.sp +To increment each pixel in an image by a constant value, use +.PN XAddPixel . +.IN "XAddPixel" "" "@DEF@" +.sM +.FD 0 +XAddPixel\^(\^\fIximage\fP, \fIvalue\fP\^) +.br + XImage *\fIximage\fP\^; +.br + long \fIvalue\fP\^; +.FN +.IP \fIximage\fP 1i +Specifies the image. +.IP \fIvalue\fP 1i +Specifies the constant value that is to be added. +.LP +.eM +The +.PN XAddPixel +function adds a constant value to every pixel in an image. +It is useful when you have a base pixel value from allocating +color resources and need to manipulate the image to that form. +.LP +.sp +To deallocate the memory allocated in a previous call to +.PN XCreateImage , +use +.PN XDestroyImage . +.IN "XDestroyImage" "" "@DEF@" +.sM +.FD 0 +XDestroyImage\^(\^\fIximage\fP\^) +.br + XImage *\^\fIximage\fP\^; +.FN +.IP \fIximage\fP 1i +Specifies the image. +.LP +.eM +The +.PN XDestroyImage +function deallocates the memory associated with the +.PN XImage +structure. +.LP +Note that when the image is created using +.PN XCreateImage , +.PN XGetImage , +or +.PN XSubImage , +the destroy procedure that this macro calls +frees both the image structure and the data pointed to by the image structure. +.NH 2 +Manipulating Bitmaps +.XS +\*(SN Manipulating Bitmaps +.XE +.LP +Xlib provides functions that you can use to read a bitmap from a file, +save a bitmap to a file, or create a bitmap. +This section describes those functions that transfer bitmaps to and +from the client's file system, thus allowing their reuse in a later +connection (for example, from an entirely different client or to a +different display or server). +.LP +The X version 11 bitmap file format is: +.LP +.sM +.Ds 0 +#define \fIname\fP_width \fIwidth\fP +#define \fIname\fP_height \fIheight\fP +#define \fIname\fP_x_hot \fIx\fP +#define \fIname\fP_y_hot \fIy\fP +static unsigned char \fIname\fP_bits[] = { 0x\fINN\fP,... } +.De +.LP +.eM +The lines for the variables ending with _x_hot and _y_hot suffixes are optional +because they are present only if a hotspot has been defined for this bitmap. +The lines for the other variables are required. +The word ``unsigned'' is optional; +that is, the type of the _bits array can be ``char'' or ``unsigned char''. +The _bits array must be large enough to contain the size bitmap. +The bitmap unit is 8. +.LP +.sp +To read a bitmap from a file and store it in a pixmap, use +.PN XReadBitmapFile . +.IN "XReadBitmapFile" "" "@DEF@" +.sM +.FD 0 +int XReadBitmapFile(\^\fIdisplay\fP, \fId\fP, \fIfilename\fP, \fIwidth_return\fP, \fIheight_return\fP, \fIbitmap_return\fP, \fIx_hot_return\fP, +.br + \fIy_hot_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Drawable \fId\fP\^; +.br + char *\fIfilename\fP\^; +.br + unsigned int *\fIwidth_return\fP, *\fIheight_return\fP\^; +.br + Pixmap *\fIbitmap_return\fP\^; +.br + int *\fIx_hot_return\fP, *\fIy_hot_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.ds Dr \ that indicates the screen +.IP \fId\fP 1i +Specifies the drawable\*(Dr. +.IP \fIfilename\fP 1i +Specifies the file name to use. +The format of the file name is operating-system dependent. +.IP \fIwidth_return\fP 1i +.br +.ns +.IP \fIheight_return\fP 1i +Return the width and height values of the read in bitmap file. +.IP \fIbitmap_return\fP 1i +Returns the bitmap that is created. +.IP \fIx_hot_return\fP 1i +.br +.ns +.IP \fIy_hot_return\fP 1i +Return the hotspot coordinates. +.LP +.eM +The +.PN XReadBitmapFile +function reads in a file containing a bitmap. +The file is parsed in the encoding of the current locale. +The ability to read other than the standard format +is implementation-dependent. +If the file cannot be opened, +.PN XReadBitmapFile +returns +.PN BitmapOpenFailed . +If the file can be opened but does not contain valid bitmap data, +it returns +.PN BitmapFileInvalid . +If insufficient working storage is allocated, +it returns +.PN BitmapNoMemory . +If the file is readable and valid, +it returns +.PN BitmapSuccess . +.LP +.PN XReadBitmapFile +returns the bitmap's height and width, as read +from the file, to width_return and height_return. +It then creates a pixmap of the appropriate size, +reads the bitmap data from the file into the pixmap, +and assigns the pixmap to the caller's variable bitmap. +The caller must free the bitmap using +.PN XFreePixmap +when finished. +If \fIname\fP_x_hot and \fIname\fP_y_hot exist, +.PN XReadBitmapFile +returns them to x_hot_return and y_hot_return; +otherwise, it returns \-1,\-1. +.LP +.PN XReadBitmapFile +can generate +.PN BadAlloc , +.PN BadDrawable , +and +.PN BadGC +errors. +.LP +.sp +To read a bitmap from a file and return it as data, use +.PN XReadBitmapFileData . +.IN "XReadBitmapFileData" "" "@DEF@" +.sM +.FD 0 +int XReadBitmapFileData(\^\fIfilename\fP, \fIwidth_return\fP, \fIheight_return\fP, \fIdata_return\fP, \fIx_hot_return\fP, \fIy_hot_return\fP\^) +.br + char *\fIfilename\fP\^; +.br + unsigned int *\fIwidth_return\fP, *\fIheight_return\fP\^; +.br + unsigned char *\fIdata_return\fP\^; +.br + int *\fIx_hot_return\fP, *\fIy_hot_return\fP\^; +.FN +.IP \fIfilename\fP 1i +Specifies the file name to use. +The format of the file name is operating-system dependent. +.IP \fIwidth_return\fP 1i +.br +.ns +.IP \fIheight_return\fP 1i +Return the width and height values of the read in bitmap file. +.IP \fIdata_return\fP 1i +Returns the bitmap data. +.IP \fIx_hot_return\fP 1i +.br +.ns +.IP \fIy_hot_return\fP 1i +Return the hotspot coordinates. +.LP +.eM +The +.PN XReadBitmapFileData +function reads in a file containing a bitmap, in the same manner as +.PN XReadBitmapFile , +but returns the data directly rather than creating a pixmap in the server. +The bitmap data is returned in data_return; the client must free this +storage when finished with it by calling +.PN XFree . +The status and other return values are the same as for +.PN XReadBitmapFile . +.LP +.sp +To write out a bitmap from a pixmap to a file, use +.PN XWriteBitmapFile . +.IN "XWriteBitmapFile" "" "@DEF@" +.sM +.FD 0 +int XWriteBitmapFile(\^\fIdisplay\fP, \fIfilename\fP, \fIbitmap\fP, \fIwidth\fP, \fIheight\fP, \fIx_hot\fP, \fIy_hot\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + char *\fIfilename\fP\^; +.br + Pixmap \fIbitmap\fP\^; +.br + unsigned int \fIwidth\fP, \fIheight\fP\^; +.br + int \fIx_hot\fP, \fIy_hot\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIfilename\fP 1i +Specifies the file name to use. +The format of the file name is operating-system dependent. +.IP \fIbitmap\fP 1i +Specifies the bitmap. +.IP \fIwidth\fP 1i +.br +.ns +.IP \fIheight\fP 1i +Specify the width and height. +.IP \fIx_hot\fP 1i +.br +.ns +.IP \fIy_hot\fP 1i +Specify where to place the hotspot coordinates (or \-1,\-1 if none are present) +in the file. +.LP +.eM +The +.PN XWriteBitmapFile +function writes a bitmap out to a file in the X Version 11 format. +The name used in the output file is derived from the file name +by deleting the directory prefix. +The file is written in the encoding of the current locale. +If the file cannot be opened for writing, +it returns +.PN BitmapOpenFailed . +If insufficient memory is allocated, +.PN XWriteBitmapFile +returns +.PN BitmapNoMemory ; +otherwise, on no error, +it returns +.PN BitmapSuccess . +If x_hot and y_hot are not \-1, \-1, +.PN XWriteBitmapFile +writes them out as the hotspot coordinates for the bitmap. +.LP +.PN XWriteBitmapFile +can generate +.PN BadDrawable +and +.PN BadMatch +errors. +.LP +.sp +To create a pixmap and then store bitmap-format data into it, use +.PN XCreatePixmapFromBitmapData . +.IN "XCreatePixmapFromBitmapData" "" "@DEF@" +.sM +.FD 0 +Pixmap XCreatePixmapFromBitmapData\^(\^\fIdisplay\fP, \fId\fP, \fIdata\fP, \fIwidth\fP, \fIheight\fP, \fIfg\fP, \fIbg\fP, \fIdepth\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Drawable \fId\fP\^; +.br + char *\fIdata\fP\^; +.br + unsigned int \fIwidth\fP, \fIheight\fP\^; +.br + unsigned long \fIfg\fP, \fIbg\fP\^; +.br + unsigned int \fIdepth\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.ds Dr \ that indicates the screen +.IP \fId\fP 1i +Specifies the drawable\*(Dr. +.IP \fIdata\fP 1i +Specifies the data in bitmap format. +.IP \fIwidth\fP 1i +.br +.ns +.IP \fIheight\fP 1i +Specify the width and height. +.IP \fIfg\fP 1i +.br +.ns +.IP \fIbg\fP 1i +Specify the foreground and background pixel values to use. +.IP \fIdepth\fP 1i +Specifies the depth of the pixmap. +.LP +.eM +The +.PN XCreatePixmapFromBitmapData +function creates a pixmap of the given depth and then does a bitmap-format +.PN XPutImage +of the data into it. +The depth must be supported by the screen of the specified drawable, +or a +.PN BadMatch +error results. +.LP +.PN XCreatePixmapFromBitmapData +can generate +.PN BadAlloc , +.PN BadDrawable , +.PN BadGC , +and +.PN BadValue +errors. +.LP +.sp +To include a bitmap written out by +.PN XWriteBitmapFile +.IN "XWriteBitmapFile" +in a program directly, as opposed to reading it in every time at run time, use +.PN XCreateBitmapFromData . +.IN "XCreateBitmapFromData" "" "@DEF@" +.sM +.FD 0 +Pixmap XCreateBitmapFromData(\^\fIdisplay\fP, \fId\fP, \fIdata\fP, \fIwidth\fP, \fIheight\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + Drawable \fId\fP\^; +.br + char *\fIdata\fP\^; +.br + unsigned int \fIwidth\fP, \fIheight\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.ds Dr \ that indicates the screen +.IP \fId\fP 1i +Specifies the drawable\*(Dr. +.IP \fIdata\fP 1i +Specifies the location of the bitmap data. +.IP \fIwidth\fP 1i +.br +.ns +.IP \fIheight\fP 1i +Specify the width and height. +.LP +.eM +The +.PN XCreateBitmapFromData +function allows you to include in your C program (using +.PN #include ) +a bitmap file that was written out by +.PN XWriteBitmapFile +(X version 11 format only) without reading in the bitmap file. +The following example creates a gray bitmap: +.LP +.Ds 0 +#include "gray.bitmap" +.sp 6p +Pixmap bitmap; +bitmap = XCreateBitmapFromData(display, window, gray_bits, gray_width, gray_height); +.De +.LP +If insufficient working storage was allocated, +.PN XCreateBitmapFromData +returns +.PN None . +It is your responsibility to free the +bitmap using +.PN XFreePixmap +when finished. +.LP +.PN XCreateBitmapFromData +can generate +.PN BadAlloc +and +.PN BadGC +errors. +.NH 2 +Using the Context Manager +.XS +\*(SN Using the Context Manager +.XE +.LP +The context manager provides a way of associating data with an X resource ID +(mostly typically a window) in your program. +Note that this is local to your program; +the data is not stored in the server on a property list. +Any amount of data in any number of pieces can be associated with a +resource ID, +and each piece of data has a type associated with it. +The context manager requires knowledge of the resource ID +and type to store or retrieve data. +.LP +Essentially, the context manager can be viewed as a two-dimensional, +sparse array: one dimension is subscripted by the X resource ID +and the other by a context type field. +Each entry in the array contains a pointer to the data. +Xlib provides context management functions with which you can +save data values, get data values, delete entries, and create a unique +context type. +The symbols used are in +.hN X11/Xutil.h . +.LP +.sp +To save a data value that corresponds to a resource ID and context type, use +.PN XSaveContext . +.IN "XSaveContext" "" "@DEF@" +.sM +.FD 0 +int XSaveContext(\^\fIdisplay\fP, \fIrid\fP, \fIcontext\fP, \fIdata\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + XID \fIrid\fP\^; +.br + XContext \fIcontext\fP\^; +.br + XPointer \fIdata\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIrid\fP 1i +Specifies the resource ID with which the data is associated. +.IP \fIcontext\fP 1i +Specifies the context type to which the data belongs. +.IP \fIdata\fP 1i +Specifies the data to be associated with the window and type. +.LP +.eM +If an entry with the specified resource ID and type already exists, +.PN XSaveContext +overrides it with the specified context. +The +.PN XSaveContext +function returns a nonzero error code if an error has occurred +and zero otherwise. +Possible errors are +.PN XCNOMEM +(out of memory). +.LP +.sp +To get the data associated with a resource ID and type, use +.PN XFindContext . +.IN "XFindContext" "" "@DEF@" +.sM +.FD 0 +int XFindContext(\^\fIdisplay\fP, \fIrid\fP, \fIcontext\fP, \fIdata_return\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + XID \fIrid\fP\^; +.br + XContext \fIcontext\fP\^; +.br + XPointer *\fIdata_return\fP\^; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIrid\fP 1i +Specifies the resource ID with which the data is associated. +.IP \fIcontext\fP 1i +Specifies the context type to which the data belongs. +.IP \fIdata_return\fP 1i +Returns the data. +.LP +.eM +Because it is a return value, +the data is a pointer. +The +.PN XFindContext +function returns a nonzero error code if an error has occurred +and zero otherwise. +Possible errors are +.PN XCNOENT +(context-not-found). +.LP +.sp +To delete an entry for a given resource ID and type, use +.PN XDeleteContext . +.IN "XDeleteContext" "" "@DEF@" +.sM +.FD 0 +int XDeleteContext(\^\fIdisplay\fP, \fIrid\fP, \fIcontext\fP\^) +.br + Display *\fIdisplay\fP\^; +.br + XID \fIrid\fP; +.br + XContext \fIcontext\fP; +.FN +.IP \fIdisplay\fP 1i +Specifies the connection to the X server. +.IP \fIrid\fP 1i +Specifies the resource ID with which the data is associated. +.IP \fIcontext\fP 1i +Specifies the context type to which the data belongs. +.LP +.eM +The +.PN XDeleteContext +function deletes the entry for the given resource ID +and type from the data structure. +This function returns the same error codes that +.PN XFindContext +returns if called with the same arguments. +.PN XDeleteContext +does not free the data whose address was saved. +.LP +.sp +To create a unique context type that may be used in subsequent calls to +.PN XSaveContext +and +.PN XFindContext , +use +.PN XUniqueContext . +.IN "XUniqueContext" "" "@DEF@" +.sM +.FD 0 +XContext XUniqueContext(\^) +.FN +.LP +.eM +.bp diff --git a/libX11/specs/libX11/Makefile.am b/libX11/specs/libX11/Makefile.am new file mode 100644 index 000000000..99b838f4f --- /dev/null +++ b/libX11/specs/libX11/Makefile.am @@ -0,0 +1,62 @@ +# +# Copyright 2009 Sun Microsystems, Inc. All rights reserved. +# +# 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 copyright holders 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 copyright holders. +# + +# Based on xc/doc/specs/X11/Makefile from X11R6.9 + +doc_sources = libX11.ms + +doc_includes = \ + abstract.t \ + credits.t \ + CH01 \ + CH02 \ + CH03 \ + CH04 \ + CH05 \ + CH06 \ + CH07 \ + CH08 \ + CH09 \ + CH10 \ + CH11 \ + CH12 \ + CH13 \ + CH14 \ + CH15 \ + CH16 \ + AppA \ + AppB \ + AppC \ + AppD \ + glossary \ + postproc + +include $(top_srcdir)/specs/troffrules.in + +EXTRA_DIST += $(doc_includes) + + + diff --git a/libX11/specs/libX11/Makefile.in b/libX11/specs/libX11/Makefile.in new file mode 100644 index 000000000..d014f41e9 --- /dev/null +++ b/libX11/specs/libX11/Makefile.in @@ -0,0 +1,580 @@ +# Makefile.in generated by automake 1.11 from Makefile.am. +# @configure_input@ + +# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, +# 2003, 2004, 2005, 2006, 2007, 2008, 2009 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 2009 Sun Microsystems, Inc. All rights reserved. +# +# 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 copyright holders 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 copyright holders. +# + +# Based on xc/doc/specs/X11/Makefile from X11R6.9 + +# +# Copyright 2009 Sun Microsystems, Inc. All rights reserved. +# +# 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 copyright holders 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 copyright holders. +# + +# Based on xc/doc/specs/*/Makefile from X11R6.9 + +VPATH = @srcdir@ +pkgdatadir = $(datadir)/@PACKAGE@ +pkgincludedir = $(includedir)/@PACKAGE@ +pkglibdir = $(libdir)/@PACKAGE@ +pkglibexecdir = $(libexecdir)/@PACKAGE@ +am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd +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@ +DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in \ + $(top_srcdir)/specs/troffrules.in +subdir = specs/libX11 +ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 +am__aclocal_m4_deps = $(top_srcdir)/acinclude.m4 \ + $(top_srcdir)/configure.ac +am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ + $(ACLOCAL_M4) +mkinstalldirs = $(install_sh) -d +CONFIG_HEADER = $(top_builddir)/src/config.h \ + $(top_builddir)/include/X11/XlibConf.h +CONFIG_CLEAN_FILES = +CONFIG_CLEAN_VPATH_FILES = +AM_V_GEN = $(am__v_GEN_$(V)) +am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY)) +am__v_GEN_0 = @echo " GEN " $@; +AM_V_at = $(am__v_at_$(V)) +am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY)) +am__v_at_0 = @ +SOURCES = +DIST_SOURCES = +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 = f=`echo $$p | sed -e 's|^.*/||'`; +am__install_max = 40 +am__nobase_strip_setup = \ + srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'` +am__nobase_strip = \ + for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||" +am__nobase_list = $(am__nobase_strip_setup); \ + for p in $$list; do echo "$$p $$p"; done | \ + sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \ + $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \ + if (++n[$$2] == $(am__install_max)) \ + { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \ + END { for (dir in files) print dir, files[dir] }' +am__base_list = \ + sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ + sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' +am__installdirs = "$(DESTDIR)$(docdir)" +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@ +AMTAR = @AMTAR@ +AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ +APP_MAN_DIR = @APP_MAN_DIR@ +APP_MAN_SUFFIX = @APP_MAN_SUFFIX@ +AR = @AR@ +AUTOCONF = @AUTOCONF@ +AUTOHEADER = @AUTOHEADER@ +AUTOMAKE = @AUTOMAKE@ +AWK = @AWK@ +BIGFONT_CFLAGS = @BIGFONT_CFLAGS@ +BIGFONT_LIBS = @BIGFONT_LIBS@ +CC = @CC@ +CCDEPMODE = @CCDEPMODE@ +CC_FOR_BUILD = @CC_FOR_BUILD@ +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@ +DOLT_BASH = @DOLT_BASH@ +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@ +EXEEXT = @EXEEXT@ +F77 = @F77@ +FFLAGS = @FFLAGS@ +FILE_MAN_DIR = @FILE_MAN_DIR@ +FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ +GREP = @GREP@ +GROFF = @GROFF@ +I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ +INSTALL = @INSTALL@ +INSTALL_DATA = @INSTALL_DATA@ +INSTALL_PROGRAM = @INSTALL_PROGRAM@ +INSTALL_SCRIPT = @INSTALL_SCRIPT@ +INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ +KEYSYMDEF = @KEYSYMDEF@ +LAUNCHD = @LAUNCHD@ +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_FLAGS = @LINT_FLAGS@ +LN_S = @LN_S@ +LTCOMPILE = @LTCOMPILE@ +LTCXXCOMPILE = @LTCXXCOMPILE@ +LTLIBOBJS = @LTLIBOBJS@ +MAINT = @MAINT@ +MAKEINFO = @MAKEINFO@ +MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ +MISC_MAN_DIR = @MISC_MAN_DIR@ +MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ +MKDIR_P = @MKDIR_P@ +NMEDIT = @NMEDIT@ +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@ +PERL = @PERL@ +PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ +RANLIB = @RANLIB@ +RAWCPP = @RAWCPP@ +RAWCPPFLAGS = @RAWCPPFLAGS@ +SED = @SED@ +SET_MAKE = @SET_MAKE@ +SHELL = @SHELL@ +STRIP = @STRIP@ +VERSION = @VERSION@ +WCHAR32 = @WCHAR32@ +X11_CFLAGS = @X11_CFLAGS@ +X11_DATADIR = @X11_DATADIR@ +X11_EXTRA_DEPS = @X11_EXTRA_DEPS@ +X11_LIBDIR = @X11_LIBDIR@ +X11_LIBS = @X11_LIBS@ +X11_LOCALEDATADIR = @X11_LOCALEDATADIR@ +X11_LOCALEDIR = @X11_LOCALEDIR@ +X11_LOCALELIBDIR = @X11_LOCALELIBDIR@ +XDMCP_CFLAGS = @XDMCP_CFLAGS@ +XDMCP_LIBS = @XDMCP_LIBS@ +XERRORDB = @XERRORDB@ +XKBPROTO_CFLAGS = @XKBPROTO_CFLAGS@ +XKBPROTO_LIBS = @XKBPROTO_LIBS@ +XKBPROTO_REQUIRES = @XKBPROTO_REQUIRES@ +XKEYSYMDB = @XKEYSYMDB@ +XLOCALEDATADIR = @XLOCALEDATADIR@ +XLOCALEDIR = @XLOCALEDIR@ +XLOCALELIBDIR = @XLOCALELIBDIR@ +XMALLOC_ZERO_CFLAGS = @XMALLOC_ZERO_CFLAGS@ +XPROTO_CFLAGS = @XPROTO_CFLAGS@ +XPROTO_LIBS = @XPROTO_LIBS@ +XTHREADLIB = @XTHREADLIB@ +XTHREAD_CFLAGS = @XTHREAD_CFLAGS@ +XTMALLOC_ZERO_CFLAGS = @XTMALLOC_ZERO_CFLAGS@ +abs_builddir = @abs_builddir@ +abs_srcdir = @abs_srcdir@ +abs_top_builddir = @abs_top_builddir@ +abs_top_srcdir = @abs_top_srcdir@ +ac_ct_CC = @ac_ct_CC@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ +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@ +builddir = @builddir@ +datadir = @datadir@ +datarootdir = @datarootdir@ +distcleancheck_listfiles = @distcleancheck_listfiles@ +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@ +srcdir = @srcdir@ +sysconfdir = @sysconfdir@ +target_alias = @target_alias@ +top_build_prefix = @top_build_prefix@ +top_builddir = @top_builddir@ +top_srcdir = @top_srcdir@ +doc_sources = libX11.ms +doc_includes = \ + abstract.t \ + credits.t \ + CH01 \ + CH02 \ + CH03 \ + CH04 \ + CH05 \ + CH06 \ + CH07 \ + CH08 \ + CH09 \ + CH10 \ + CH11 \ + CH12 \ + CH13 \ + CH14 \ + CH15 \ + CH16 \ + AppA \ + AppB \ + AppC \ + AppD \ + glossary \ + postproc + +EXTRA_DIST = $(doc_sources) $(doc_includes) +@HAVE_PS2PDF_FALSE@printable_format = .ps +@HAVE_PS2PDF_TRUE@printable_format = .pdf +@BUILD_SPECS_TRUE@doc_DATA = $(doc_sources:.ms=.txt) \ +@BUILD_SPECS_TRUE@ $(doc_sources:.ms=$(printable_format)) \ +@BUILD_SPECS_TRUE@ $(doc_sources:.ms=.html) + +@BUILD_SPECS_TRUE@CLEANFILES = $(doc_DATA) +@BUILD_SPECS_TRUE@MOSTLYCLEANFILES = index.* + +# Pass version string as a troff string for substitution +@BUILD_SPECS_TRUE@GROFF_DEFS = -dxV="$(PACKAGE_STRING)" + +# -e to run through eqn, -t to run through tbl +@BUILD_SPECS_TRUE@GROFF_FLAGS = -e -t -ms $(GROFF_DEFS) $(top_srcdir)/specs/macros.t +@BUILD_SPECS_TRUE@SUFFIXES = .ms .ps .txt .html .pdf +all: all-am + +.SUFFIXES: +.SUFFIXES: .ms .ps .txt .html .pdf +$(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(top_srcdir)/specs/troffrules.in $(am__configure_deps) + @for dep in $?; do \ + case '$(am__configure_deps)' in \ + *$$dep*) \ + ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ + && { if test -f $@; then exit 0; else break; fi; }; \ + exit 1;; \ + esac; \ + done; \ + echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign specs/libX11/Makefile'; \ + $(am__cd) $(top_srcdir) && \ + $(AUTOMAKE) --foreign specs/libX11/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 +$(am__aclocal_m4_deps): + +mostlyclean-libtool: + -rm -f *.lo + +clean-libtool: + -rm -rf .libs _libs +install-docDATA: $(doc_DATA) + @$(NORMAL_INSTALL) + test -z "$(docdir)" || $(MKDIR_P) "$(DESTDIR)$(docdir)" + @list='$(doc_DATA)'; test -n "$(docdir)" || list=; \ + for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + echo "$$d$$p"; \ + done | $(am__base_list) | \ + while read files; do \ + echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(docdir)'"; \ + $(INSTALL_DATA) $$files "$(DESTDIR)$(docdir)" || exit $$?; \ + done + +uninstall-docDATA: + @$(NORMAL_UNINSTALL) + @list='$(doc_DATA)'; test -n "$(docdir)" || list=; \ + files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ + test -n "$$files" || exit 0; \ + echo " ( cd '$(DESTDIR)$(docdir)' && rm -f" $$files ")"; \ + cd "$(DESTDIR)$(docdir)" && rm -f $$files +tags: TAGS +TAGS: + +ctags: CTAGS +CTAGS: + + +distdir: $(DISTFILES) + @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + list='$(DISTFILES)'; \ + dist_files=`for file in $$list; do echo $$file; done | \ + sed -e "s|^$$srcdirstrip/||;t" \ + -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ + case $$dist_files in \ + */*) $(MKDIR_P) `echo "$$dist_files" | \ + sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ + sort -u` ;; \ + esac; \ + for file in $$dist_files; do \ + if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ + if test -d $$d/$$file; then \ + dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ + if test -d "$(distdir)/$$file"; then \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ + cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + cp -fpR $$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)"; 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: + -test -z "$(MOSTLYCLEANFILES)" || rm -f $(MOSTLYCLEANFILES) + +clean-generic: + -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES) + +distclean-generic: + -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) + -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_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 + +dvi: dvi-am + +dvi-am: + +html: html-am + +html-am: + +info: info-am + +info-am: + +install-data-am: install-docDATA + +install-dvi: install-dvi-am + +install-dvi-am: + +install-exec-am: + +install-html: install-html-am + +install-html-am: + +install-info: install-info-am + +install-info-am: + +install-man: + +install-pdf: install-pdf-am + +install-pdf-am: + +install-ps: install-ps-am + +install-ps-am: + +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-docDATA + +.MAKE: install-am install-strip + +.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-docDATA install-dvi \ + install-dvi-am install-exec install-exec-am install-html \ + install-html-am install-info install-info-am install-man \ + install-pdf install-pdf-am install-ps install-ps-am \ + 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-docDATA + + +@BUILD_SPECS_TRUE@.ms.ps: +@BUILD_SPECS_TRUE@ -$(AM_V_GEN) $(GROFF) -Tps $(GROFF_FLAGS) $< 2> index.$@.raw > $@ +@BUILD_SPECS_TRUE@ @if grep '^[^1-9.]' index.$@.raw | grep -v warning; then exit 1; \ +@BUILD_SPECS_TRUE@ else test $$? -le 1; fi + +@BUILD_SPECS_TRUE@.ms.txt: +@BUILD_SPECS_TRUE@ $(AM_V_GEN) env GROFF_NO_SGR=TRUE $(GROFF) -Tutf8 $(GROFF_FLAGS) \ +@BUILD_SPECS_TRUE@ $< 2> index.$@.raw > $@ + +@BUILD_SPECS_TRUE@.ms.html: +@BUILD_SPECS_TRUE@ $(AM_V_GEN) $(GROFF) -Thtml $(GROFF_FLAGS) $< 2> index.$@.raw > $@ + +@BUILD_SPECS_TRUE@.ps.pdf: +@BUILD_SPECS_TRUE@ $(AM_V_GEN) $(PS2PDF) $< $@ + +# 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/libX11/specs/libX11/abstract.t b/libX11/specs/libX11/abstract.t new file mode 100644 index 000000000..fe15d1fb0 --- /dev/null +++ b/libX11/specs/libX11/abstract.t @@ -0,0 +1,106 @@ +.\" $XFree86: xc/doc/specs/X11/abstract.t,v 1.2 2003/07/09 15:27:26 tsi Exp $ +.EH '''' +.OH '''' +.EF '''' +.OF '''' +.ps 11 +.nr PS 11 +\& +.sp 5 +.ce 6 +\s+2\fBXlib \- C Language X Interface\fP\s-2 + +\s+1\fBX Window System Standard\fP\s-1 + +\s+1\fBX Version 11, Release 7\fP\s-1 + +\s+1\fB\*(xV\fP\s-1 +.sp 6 +.ce 4 +\s-1James Gettys +.sp 6p +Cambridge Research Laboratory +Digital Equipment Corporation +.sp 2 +.ce 4 +Robert W. Scheifler +.sp 6p +Laboratory for Computer Science +Massachusetts Institute of Technology +.sp 3 +.ce 1 +\fIwith contributions from\fP +.sp 3 +.ce 11 +Chuck Adams, Tektronix, Inc. +.sp 1 +Vania Joloboff, Open Software Foundation +.sp 1 +Hideki Hiura, Sun Microsystems, Inc. +.sp 1 +Bill McMahon, Hewlett-Packard Company +.sp 1 +Ron Newman, Massachusetts Institute of Technology +.sp 1 +Al Tabayoyon, Tektronix, Inc. +.sp 1 +Glenn Widener, Tektronix, Inc. +.sp 1 +Shigeru Yamada, Fujitsu OSSI +.bp +\& +.ps 9 +.nr PS 9 +.sp 8 +.LP +The X Window System is a trademark of The Open Group. +.LP +TekHVC is a trademark of Tektronix, Inc. +.sp 2 +.LP +Copyright \(co 1985, 1986, 1987, 1988, 1989, 1990, 1991, 1994, 1996, 2002 +The Open Group +.LP +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: +.LP +The above copyright notice and this permission notice shall be included +in all copies or substantial portions of the Software. +.LP +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 X CONSORTIUM 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. +.LP +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 3 +.LP +Copyright \(co 1985, 1986, 1987, 1988, 1989, 1990, 1991 by +Digital Equipment Corporation +.LP +Portions Copyright \(co 1990, 1991 by +Tektronix, Inc. +.LP +Permission to use, copy, modify and distribute this documentation for +any purpose and without fee is hereby granted, provided that the above +copyright notice appears in all copies and that both that copyright notice and +this permission notice appear in all copies, and that the names of +Digital and Tektronix not be used in in advertising or publicity +pertaining to this documentation without specific, written prior permission. +Digital and Tektronix makes no representations about the suitability +of this documentation for any purpose. +It is provided ``as is'' without express or implied warranty. +.ps 11 +.nr PS 11 +.bp diff --git a/libX11/specs/libX11/credits.t b/libX11/specs/libX11/credits.t new file mode 100644 index 000000000..5d9909d7c --- /dev/null +++ b/libX11/specs/libX11/credits.t @@ -0,0 +1,216 @@ +.EH '''' +.OH '''' +.EF '''' +.OF '''' +.XS ii +Table of Contents +.XE +.XS iii +Acknowledgments +.XE +\& +.sp 1 +.ce 3 +\s+1\fBAcknowledgments\fP\s-1 +.sp 2 +.na +.LP +The design and implementation of the first 10 versions of X +were primarily the work of three individuals: Robert Scheifler of the +MIT Laboratory for Computer Science and Jim Gettys of Digital +Equipment Corporation and Ron Newman of MIT, both at MIT +Project Athena. +X version 11, however, is the result of the efforts of +dozens of individuals at almost as many locations and organizations. +At the risk of offending some of the players by exclusion, +we would like to acknowledge some of the people who deserve special credit +and recognition for their work on Xlib. +Our apologies to anyone inadvertently overlooked. +.SH +Release 1 +.LP +Our thanks does to Ron Newman (MIT Project Athena), +who contributed substantially to the +design and implementation of the Version 11 Xlib interface. +.LP +Our thanks also goes to Ralph Swick (Project Athena and Digital) who kept +it all together for us during the early releases. +He handled literally thousands of requests from people everywhere +and saved the sanity of at least one of us. +His calm good cheer was a foundation on which we could build. +.LP +Our thanks also goes to Todd Brunhoff (Tektronix) who was ``loaned'' +to Project Athena at exactly the right moment to provide very capable +and much-needed assistance during the alpha and beta releases. +He was responsible for the successful integration of sources +from multiple sites; +we would not have had a release without him. +.LP +Our thanks also goes to Al Mento and Al Wojtas of Digital's ULTRIX +Documentation Group. +With good humor and cheer, +they took a rough draft and made it an infinitely better and more useful +document. +The work they have done will help many everywhere. +We also would like to thank Hal Murray (Digital SRC) and +Peter George (Digital VMS) who contributed much +by proofreading the early drafts of this document. +.LP +Our thanks also goes to Jeff Dike (Digital UEG), Tom Benson, +Jackie Granfield, and Vince Orgovan (Digital VMS) who helped with the +library utilities implementation; +to Hania Gajewska (Digital UEG-WSL) who, +along with Ellis Cohen (CMU and Siemens), +was instrumental in the semantic design of the window manager properties; +and to Dave Rosenthal (Sun Microsystems) who also contributed to the protocol +and provided the sample generic color frame buffer device-dependent code. +.LP +The alpha and beta test participants deserve special recognition and thanks +as well. +It is significant +that the bug reports (and many fixes) during alpha and beta test came almost +exclusively from just a few of the alpha testers, mostly hardware vendors +working on product implementations of X. +The continued public +contribution of vendors and universities is certainly to the benefit +of the entire X community. +.LP +Our special thanks must go to Sam Fuller, Vice-President of Corporate +Research at Digital, who has remained committed to the widest public +availability of X and who made it possible to greatly supplement MIT's +resources with the Digital staff in order to make version 11 a reality. +Many of the people mentioned here are part of the Western +Software Laboratory (Digital UEG-WSL) of the ULTRIX Engineering group +and work for Smokey Wallace, who has been vital to the project's success. +Others not mentioned here worked on the toolkit and are acknowledged +in the X Toolkit documentation. +.LP +Of course, +we must particularly thank Paul Asente, formerly of Stanford University +and now of Digital UEG-WSL, who wrote W, the predecessor to X, +and Brian Reid, formerly of Stanford University and now of Digital WRL, +who had much to do with W's design. +.LP +Finally, our thanks goes to MIT, Digital Equipment Corporation, +and IBM for providing the environment where it could happen. +.SH +Release 4 +.LP +Our thanks go to Jim Fulton (MIT X Consortium) for designing and +specifying the new Xlib functions for Inter-Client Communication +Conventions (ICCCM) support. +.LP +We also thank Al Mento of Digital for his continued effort in +maintaining this document and Jim Fulton and Donna Converse (MIT X Consortium) +for their much-appreciated efforts in reviewing the changes. +.SH +Release 5 +.LP +The principal authors of the Input Method facilities are +Vania Joloboff (Open Software Foundation) and Bill McMahon (Hewlett-Packard). +The principal author of the rest of the internationalization facilities +is Glenn Widener (Tektronix). Our thanks to them for keeping their +sense of humor through a long and sometimes difficult design process. +Although the words and much of the design are due to them, many others +have contributed substantially to the design and implementation. +Tom McFarland (HP) and Frank Rojas (IBM) deserve particular recognition +for their contributions. Other contributors were: +Tim Anderson (Motorola), Alka Badshah (OSF), Gabe Beged-Dov (HP), +Chih-Chung Ko (III), Vera Cheng (III), Michael Collins (Digital), +Walt Daniels (IBM), Noritoshi Demizu (OMRON), Keisuke Fukui (Fujitsu), +Hitoshoi Fukumoto (Nihon Sun), Tim Greenwood (Digital), John Harvey (IBM), +Hideki Hiura (Sun), Fred Horman (AT&T), Norikazu Kaiya (Fujitsu), +Yuji Kamata (IBM), +Yutaka Kataoka (Waseda University), Ranee Khubchandani (Sun), Akira Kon (NEC), +Hiroshi Kuribayashi (OMRON), Teruhiko Kurosaka (Sun), Seiji Kuwari (OMRON), +Sandra Martin (OSF), Narita Masahiko (Fujitsu), Masato Morisaki (NTT), +Nelson Ng (Sun), +Takashi Nishimura (NTT America), Makato Nishino (IBM), +Akira Ohsone (Nihon Sun), Chris Peterson (MIT), Sam Shteingart (AT&T), +Manish Sheth (AT&T), Muneiyoshi Suzuki (NTT), Cori Mehring (Digital), +Shoji Sugiyama (IBM), and Eiji Tosa (IBM). +.LP +We are deeply indebted to Tatsuya Kato (NTT), +Hiroshi Kuribayashi (OMRON), Seiji Kuwari (OMRON), Muneiyoshi Suzuki (NTT), +and Li Yuhong (OMRON) for producing one of the first complete +sample implementation of the internationalization facilities, and +Hiromu Inukai (Nihon Sun), Takashi Fujiwara (Fujitsu), Hideki Hiura (Sun), +Yasuhiro Kawai (Oki Technosystems Laboratory), Kazunori Nishihara (Fuji Xerox), +Masaki Takeuchi (Sony), Katsuhisa Yano (Toshiba), +Makoto Wakamatsu (Sony Corporation) for producing the another complete +sample implementation of the internationalization facilities. +.LP +The principal authors (design and implementation) of the Xcms color +management facilities are Al Tabayoyon (Tektronix) +and Chuck Adams (Tektronix). +Joann Taylor (Tektronix), Bob Toole (Tektronix), +and Keith Packard (MIT X Consortium) also +contributed significantly to the design. Others who contributed are: +Harold Boll (Kodak), Ken Bronstein (HP), Nancy Cam (SGI), +Donna Converse (MIT X Consortium), Elias Israel (ISC), Deron Johnson (Sun), +Jim King (Adobe), Ricardo Motta (HP), Chuck Peek (IBM), +Wil Plouffe (IBM), Dave Sternlicht (MIT X Consortium), Kumar Talluri (AT&T), +and Richard Verberg (IBM). +.LP +We also once again thank Al Mento of Digital for his work in formatting +and reformatting text for this manual, and for producing man pages. +Thanks also to Clive Feather (IXI) for proof-reading and finding a +number of small errors. +.SH +Release 6 +.LP +Stephen Gildea (X Consortium) authored the threads support. +Ovais Ashraf (Sun) and Greg Olsen (Sun) contributed substantially +by testing the facilities and reporting bugs in a timely fashion. +.LP +The principal authors of the internationalization facilities, including +Input and Output Methods, are Hideki Hiura (SunSoft) and +Shigeru Yamada (Fujitsu OSSI). +Although the words and much of the design are due to them, many others +have contributed substantially to the design and implementation. +They are: Takashi Fujiwara (Fujitsu), Yoshio Horiuchi (IBM), +Makoto Inada (Digital), Hiromu Inukai (Nihon SunSoft), +Song JaeKyung (KAIST), Franky Ling (Digital), Tom McFarland (HP), +Hiroyuki Miyamoto (Digital), Masahiko Narita (Fujitsu), +Frank Rojas (IBM), Hidetoshi Tajima (HP), Masaki Takeuchi (Sony), +Makoto Wakamatsu (Sony), Masaki Wakao (IBM), Katsuhisa Yano(Toshiba) and +Jinsoo Yoon (KAIST). +.LP +The principal producers of the sample implementation of the +internationalization facilities are: +Jeffrey Bloomfield (Fujitsu OSSI), Takashi Fujiwara (Fujitsu), +Hideki Hiura (SunSoft), Yoshio Horiuchi (IBM), +Makoto Inada (Digital), Hiromu Inukai (Nihon SunSoft), +Song JaeKyung (KAIST), Riki Kawaguchi (Fujitsu), +Franky Ling (Digital), Hiroyuki Miyamoto (Digital), +Hidetoshi Tajima (HP), Toshimitsu Terazono (Fujitsu), +Makoto Wakamatsu (Sony), Masaki Wakao (IBM), +Shigeru Yamada (Fujitsu OSSI) and Katsuhisa Yano (Toshiba). +.LP +The coordinators of the integration, testing, and release of this +implementation of the internationalization facilities are +Nobuyuki Tanaka (Sony) and Makoto Wakamatsu (Sony). +.LP +Others who have contributed to the architectural design or +testing of the sample implementation of the +internationalization facilities are: +Hector Chan (Digital), Michael Kung (IBM), Joseph Kwok (Digital), +Hiroyuki Machida (Sony), Nelson Ng (SunSoft), Frank Rojas (IBM), +Yoshiyuki Segawa (Fujitsu OSSI), Makiko Shimamura (Fujitsu), +Shoji Sugiyama (IBM), Lining Sun (SGI), Masaki Takeuchi (Sony), +Jinsoo Yoon (KAIST) and Akiyasu Zen (HP). +.sp 2 +.LP +.Ds 0 +.TA 1.5i 3i +.ta 1.5i 3i +.R +Jim Gettys +Cambridge Research Laboratory +Digital Equipment Corporation + +Robert W. Scheifler +Laboratory for Computer Science +Massachusetts Institute of Technology +.DE +.bp 1 diff --git a/libX11/specs/libX11/glossary b/libX11/specs/libX11/glossary new file mode 100644 index 000000000..a130928a6 --- /dev/null +++ b/libX11/specs/libX11/glossary @@ -0,0 +1,1484 @@ +\& +.sp 1 +.ce 1 +\s+1\fBGlossary\fP\s-1 +.sp 2 +.na +.LP +.XS +Glossary +.XE +.KS +\fBAccess control list\fP +.IN "Access control list" "" "@DEF@" +.IP +X maintains a list of hosts from which client programs can be run. +By default, +only programs on the local host and hosts specified in an initial list read +by the server can use the display. +This access control list can be changed by clients on the local host. +Some server implementations can also implement other authorization mechanisms +in addition to or in place of this mechanism. +The action of this mechanism can be conditional based on the authorization +protocol name and data received by the server at connection setup. +.KE +.LP +.KS +\fBActive grab\fP +.IN "Active grab" "" "@DEF@" +.IP +A grab is active when the pointer or keyboard is actually owned by the +single grabbing client. +.KE +.LP +.KS +\fBAncestors\fP +.IN "Ancestors" "" "@DEF@" +.IP +If W is an inferior of A, then A is an ancestor of W. +.KE +.LP +.KS +\fBAtom\fP +.IN "Atom" "" "@DEF@" +.IP +An atom is a unique ID corresponding to a string name. +Atoms are used to identify properties, types, and selections. +.KE +.LP +.KS +\fBBackground\fP +.IN "Background" "" "@DEF@" +.IP +An +.PN InputOutput +window can have a background, which is defined as a pixmap. +When regions of the window have their contents lost +or invalidated, +the server automatically tiles those regions with the background. +.KE +.LP +.KS +\fBBacking store\fP +.IN "Backing store" "" "@DEF@" +.IP +When a server maintains the contents of a window, +the pixels saved off-screen are known as a backing store. +.KE +.LP +.KS +\fBBase font name\fP +.IN "Base font name" "" "@DEF@" +.IP +A font name used to select a family of fonts whose members may be encoded +in various charsets. +The +.PN CharSetRegistry +and +.PN CharSetEncoding +fields of an XLFD name identify the charset of the font. +A base font name may be a full XLFD name, with all fourteen '-' delimiters, +or an abbreviated XLFD name containing only the first 12 fields of an XLFD name, +up to but not including +.PN CharSetRegistry , +with or without the thirteenth '-', or a non-XLFD name. +Any XLFD fields may contain wild cards. +.IP +When creating an +.PN XFontSet , +Xlib accepts from the client a list of one or more base font names +which select one or more font families. +They are combined with charset names obtained from the encoding of the locale +to load the fonts required to render text. +.KE +.LP +.KS +\fBBit gravity\fP +.IN "Bit" "gravity" "@DEF@" +.IP +When a window is resized, +the contents of the window are not necessarily discarded. +It is possible to request that the server relocate the previous contents +to some region of the window (though no guarantees are made). +This attraction of window contents for some location of +a window is known as bit gravity. +.KE +.LP +.KS +\fBBit plane\fP +.IN "Bit" "plane" "@DEF@" +.IP +When a pixmap or window is thought of as a stack of bitmaps, +each bitmap is called a bit plane or plane. +.KE +.LP +.KS +\fBBitmap\fP +.IN "Bitmap" "" "@DEF@" +.IP +A bitmap is a pixmap of depth one. +.KE +.LP +.KS +\fBBorder\fP +.IN "Border" "" "@DEF@" +.IP +An +.PN InputOutput +window can have a border of equal thickness on all four sides of the window. +The contents of the border are defined by a pixmap, +and the server automatically maintains the contents of the border. +Exposure events are never generated for border regions. +.KE +.LP +.KS +\fBButton grabbing\fP +.IN "Button" "grabbing" "@DEF@" +.IP +Buttons on the pointer can be passively grabbed by a client. +When the button is pressed, +the pointer is then actively grabbed by the client. +.KE +.LP +.KS +\fBByte order\fP +.IN "Byte" "order" "@DEF@" +.IP +For image (pixmap/bitmap) data, +the server defines the byte order, +and clients with different native byte ordering must swap bytes as +necessary. +For all other parts of the protocol, +the client defines the byte order, +and the server swaps bytes as necessary. +.KE +.LP +.KS +\fBCharacter\fP +.IN "Character" "" "@DEF@" +.IP +A member of a set of elements used for the organization, +control, or representation of text (ISO2022, as adapted by XPG3). +Note that in ISO2022 terms, a character is not bound to a coded value +until it is identified as part of a coded character set. +.KE +.LP +.KS +\fBCharacter glyph\fP +.IN "Character glyph" "" "@DEF@" +.IP +The abstract graphical symbol for a character. +Character glyphs may or may not map one-to-one to font glyphs, +and may be context-dependent, varying with the adjacent characters. +Multiple characters may map to a single character glyph. +.KE +.LP +.KS +\fBCharacter set\fP +.IN "Character set" "" "@DEF@" +.IP +A collection of characters. +.KE +.LP +.KS +\fBCharset\fP +.IN "Charset" "" "@DEF@" +.IP +An encoding with a uniform, state-independent mapping from characters +to codepoints. +A coded character set. +.IP +For display in X, +there can be a direct mapping from a charset to one font, +if the width of all characters in the charset is either one or two bytes. +A text string encoded in an encoding such as Shift-JIS cannot be passed +directly to the X server, because the text imaging requests accept only +single-width charsets (either 8 or 16 bits). +Charsets which meet these restrictions can serve as ``font charsets''. +Font charsets strictly speaking map font indices to font glyphs, +not characters to character glyphs. +.IP +Note that a single font charset is sometimes used as the encoding of a locale, +for example, ISO8859-1. +.KE +.LP +.KS +\fBChildren\fP +.IN "Children" "" "@DEF@" +.IP +The children of a window are its first-level subwindows. +.KE +.LP +.KS +\fBClass\fP +.IN "Class" "" "@DEF@" +.IP +Windows can be of different classes or types. +See the entries for +.PN InputOnly +and +.PN InputOutput +windows for further information about valid window types. +.KE +.LP +.KS +\fBClient\fP +.IN "Client" "" "@DEF@" +.IP +An application program connects to the window system server by some +interprocess communication (IPC) path, such as a TCP connection or a +shared memory buffer. +This program is referred to as a client of the window system server. +More precisely, +the client is the IPC path itself. +A program with multiple paths open to the server is viewed as +multiple clients by the protocol. +Resource lifetimes are controlled by +connection lifetimes, not by program lifetimes. +.KE +.LP +.KS +\fBClipping region\fP +.IN "Clipping region" "" "@DEF@" +.IP +In a graphics context, +a bitmap or list of rectangles can be specified +to restrict output to a particular region of the window. +The image defined by the bitmap or rectangles is called a clipping region. +.KE +.LP +.KS +\fBCoded character\fP +.IN "Coded character" "" "@DEF@" +.IP +A character bound to a codepoint. +.KE +.LP +.KS +\fBCoded character set\fP +.IN "Coded character set" "" "@DEF@" +.IP +A set of unambiguous rules that establishes a character set +and the one-to-one relationship between each character of the set +and its bit representation. +(ISO2022, as adapted by XPG3) +A definition of a one-to-one mapping of a set of characters to a set of +codepoints. +.KE +.LP +.KS +\fBCodepoint\fP +.IN "Codepoint" "" "@DEF@" +.IP +The coded representation of a single character in a coded character set. +.KE +.LP +.KS +\fBColormap\fP +.IN "Colormap" "" "@DEF@" +.IP +A colormap consists of a set of entries defining color values. +The colormap associated with a window is used to display the contents of +the window; each pixel value indexes the colormap to produce an RGB value +that drives the guns of a monitor. +Depending on hardware limitations, +one or more colormaps can be installed at one time so +that windows associated with those maps display with true colors. +.KE +.LP +.KS +\fBConnection\fP +.IN "Connection" "" "@DEF@" +.IP +The IPC path between the server and client program is known as a connection. +A client program typically (but not necessarily) has one +connection to the server over which requests and events are sent. +.KE +.LP +.KS +\fBContainment\fP +.IN "Containment" "" "@DEF@" +.IP +A window contains the pointer if the window is viewable and the +hotspot of the cursor is within a visible region of the window or a +visible region of one of its inferiors. +The border of the window is included as part of the window for containment. +The pointer is in a window if the window contains the pointer +but no inferior contains the pointer. +.KE +.LP +.KS +\fBCoordinate system\fP +.IN "Coordinate system" "" "@DEF@" +.IP +The coordinate system has X horizontal and Y vertical, +with the origin [0, 0] at the upper left. +Coordinates are integral and coincide with pixel centers. +Each window and pixmap has its own coordinate system. +For a window, +the origin is inside the border at the inside upper-left corner. +.KE +.LP +.KS +\fBCursor\fP +.IN "Cursor" "" "@DEF@" +.IP +A cursor is the visible shape of the pointer on a screen. +It consists of a hotspot, a source bitmap, a shape bitmap, +and a pair of colors. +The cursor defined for a window controls the visible +appearance when the pointer is in that window. +.KE +.LP +.KS +\fBDepth\fP +.IN "Depth" "" "@DEF@" +.IP +The depth of a window or pixmap is the number of bits per pixel it has. +The depth of a graphics context is the depth of the drawables it can be +used in conjunction with graphics output. +.KE +.LP +.KS +\fBDevice\fP +.IN "Device" "" "@DEF@" +.IP +Keyboards, mice, tablets, track-balls, button boxes, and so on are all +collectively known as input devices. +Pointers can have one or more buttons +(the most common number is three). +The core protocol only deals with two devices: the keyboard +and the pointer. +.KE +.LP +.KS +\fBDirectColor\fP +.IN "DirectColor" "" "@DEF@" +.IP +.PN DirectColor +is a class of colormap in which a pixel value is decomposed into three +separate subfields for indexing. +The first subfield indexes an array to produce red intensity values. +The second subfield indexes a second array to produce blue intensity values. +The third subfield indexes a third array to produce green intensity values. +The RGB (red, green, and blue) values in the colormap entry can be +changed dynamically. +.KE +.LP +.KS +\fBDisplay\fP +.IN "Display" "" "@DEF@" +.IP +A server, together with its screens and input devices, is called a display. +The Xlib +.PN Display +.IN "Display" "structure" +structure contains all information about the particular display and its screens +as well as the state that Xlib needs to communicate with the display over a +particular connection. +.KE +.LP +.KS +\fBDrawable\fP +.IN "Drawable" "" "@DEF@" +.IP +Both windows and pixmaps can be used as sources and destinations +in graphics operations. +These windows and pixmaps are collectively known as drawables. +However, an +.PN InputOnly +window cannot be used as a source or destination in a +graphics operation. +.KE +.LP +.KS +\fBEncoding\fP +.IN "Encoding" "" "@DEF@" +.IP +A set of unambiguous rules that establishes a character set +and a relationship between the characters and their representations. +The character set does not have to be fixed to a finite pre-defined set of +characters. +The representations do not have to be of uniform length. +Examples are an ISO2022 graphic set, a state-independent +or state-dependent combination of graphic sets, possibly including control +sets, and the X Compound Text encoding. +.IP +In X, encodings are identified by a string +which appears as: the +.PN CharSetRegistry +and +.PN CharSetEncoding +components of an XLFD +name; the name of a charset of the locale for which a font could not be +found; or an atom which identifies the encoding of a text property or +which names an encoding for a text selection target type. +Encoding names should be composed of characters from the X Portable +Character Set. +.KE +.LP +.KS +\fBEscapement\fP +.IN "Escapement" "" "@DEF@" +.IP +The escapement of a string is the distance in pixels in the +primary draw direction from the drawing origin to the origin of the next +character (that is, the one following the given string) to be drawn. +.KE +.LP +.KS +\fBEvent\fP +.IN "Event" "" "@DEF@" +.IP +Clients are informed of information asynchronously by means of events. +These events can be either asynchronously generated from devices or +generated as side effects of client requests. +Events are grouped into types. +The server never sends an event to a client unless the +client has specifically asked to be informed of that type of event. +However, clients can force events to be sent to other clients. +Events are typically reported relative to a window. +.KE +.LP +.KS +\fBEvent mask\fP +.IN "Event" "mask" "@DEF@" +.IP +Events are requested relative to a window. +The set of event types a client requests relative to a window is described +by using an event mask. +.KE +.LP +.KS +\fBEvent propagation\fP +.IN "Event" "propagation" "@DEF@" +.IP +Device-related events propagate from the source window to ancestor +windows until some client has expressed interest in handling that type +of event or until the event is discarded explicitly. +.KE +.LP +.KS +\fBEvent source\fP +.IN "Event" "source" "@DEF@" +.IP +The deepest viewable window that the pointer is in is called +the source of a device-related event. +.KE +.LP +.KS +\fBEvent synchronization\fP +.IN "Event" "synchronization" "@DEF@" +.IP +There are certain race conditions possible when demultiplexing device +events to clients (in particular, deciding where pointer and keyboard +events should be sent when in the middle of window management +operations). +The event synchronization mechanism allows synchronous processing of +device events. +.KE +.LP +.KS +\fBExposure event\fP +.IN "Event" "Exposure" "@DEF@" +.IP +Servers do not guarantee to preserve the contents of windows when +windows are obscured or reconfigured. +Exposure events are sent to clients to inform them when contents of regions +of windows have been lost. +.KE +.LP +.KS +\fBExtension\fP +.IN "Extension" "" "@DEF@" +.IP +Named extensions to the core protocol can be defined to extend the system. +Extensions to output requests, resources, and event types are all possible +and expected. +.KE +.LP +.KS +\fBFont\fP +.IN "Font" "" "@DEF@" +.IP +A font is an array of glyphs (typically characters). +The protocol does no translation or interpretation of character sets. +The client simply indicates values used to index the glyph array. +A font contains additional metric information to determine interglyph +and interline spacing. +.KE +.LP +.KS +\fBFont glyph\fP +.IN "Font glyph" "" "@DEF@" +.IP +The abstract graphical symbol for an index into a font. +.KE +.LP +.KS +\fBFrozen events\fP +.IN "Frozen events" "" "@DEF@" +.IP +Clients can freeze event processing during keyboard and pointer grabs. +.KE +.LP +.KS +\fBGC\fP +.IN "GC" "" "@DEF@" +.IP +GC is an abbreviation for graphics context. +See \fBGraphics context\fP. +.KE +.LP +.KS +\fBGlyph\fP +.IN "Glyph" "" "@DEF@" +.IP +An identified abstract graphical symbol independent of any actual image. +(ISO/IEC/DIS 9541-1) +An abstract visual representation of a graphic character, +not bound to a codepoint. +.KE +.LP +.KS +\fBGlyph image\fP +.IN "Glyph image" "" "@DEF@" +.IP +An image of a glyph, as obtained from a glyph representation displayed +on a presentation surface. +(ISO/IEC/DIS 9541-1) +.KE +.LP +.KS +\fBGrab\fP +.IN "Grab" "" "@DEF@" +.IP +Keyboard keys, the keyboard, pointer buttons, the pointer, +and the server can be grabbed for exclusive use by a client. +In general, +these facilities are not intended to be used by normal applications +but are intended for various input and window managers to implement various +styles of user interfaces. +.KE +.LP +.KS +\fBGraphics context\fP +.IN "Graphics context" "" "@DEF@" +.IP +Various information for graphics output is stored in a graphics +context (GC), such as foreground pixel, background +pixel, line width, clipping region, and so on. +A graphics context can only +be used with drawables that have the same root and the same depth as +the graphics context. +.KE +.LP +.KS +\fBGravity\fP +.IN "Gravity" "" "@DEF@" +.IP +The contents of windows and windows themselves have a gravity, +which determines how the contents move when a window is resized. +See \fBBit gravity\fP and \fBWindow gravity\fP. +.KE +.LP +.KS +\fBGrayScale\fP +.IN "GrayScale" "" "@DEF@" +.IP +.PN GrayScale +can be viewed as a degenerate case of +.PN PseudoColor , +in which the red, green, and blue values in any given colormap entry +are equal and thus, produce shades of gray. +The gray values can be changed dynamically. +.KE +.LP +.KS +\fBHost Portable Character Encoding\fP +.IN "Host Portable Character Encoding" "" "@DEF@" +.IP +The encoding of the X Portable Character Set on the host. +The encoding itself is not defined by this standard, +but the encoding must be the same in all locales supported by Xlib on the host. +If a string is said to be in the Host Portable Character Encoding, +then it only contains characters from the X Portable Character Set, +in the host encoding. +.KE +.LP +.KS +\fBHotspot\fP +.IN "Hotspot" "" "@DEF@" +.IP +A cursor has an associated hotspot, which defines the point in the +cursor corresponding to the coordinates reported for the pointer. +.KE +.LP +.KS +\fBIdentifier\fP +.IN "Identifier" "" "@DEF@" +.IP +An identifier is a unique value associated with a resource +that clients use to name that resource. +The identifier can be used over any connection to name the resource. +.KE +.LP +.KS +\fBInferiors\fP +.IN "Inferiors" "" "@DEF@" +.IP +The inferiors of a window are all of the subwindows nested below it: +the children, the children's children, and so on. +.KE +.LP +.KS +\fBInput focus\fP +.IN "Input" "focus" "@DEF@" +.IP +The input focus is usually a window defining the scope for processing +of keyboard input. +If a generated keyboard event usually would be reported to this window +or one of its inferiors, +the event is reported as usual. +Otherwise, the event is reported with respect to the focus window. +The input focus also can be set such that all keyboard events are discarded +and such that the focus window is dynamically taken to be the root window +of whatever screen the pointer is on at each keyboard event. +.KE +.LP +.KS +\fBInput manager\fP +.IN "Input" "manager" "@DEF@" +.IP +Control over keyboard input is typically provided by an input manager +client, which usually is part of a window manager. +.KE +.LP +.KS +\fBInputOnly window\fP +.IN "Window" "InputOnly" "@DEF@" +.IP +An +.PN InputOnly +window is a window that cannot be used for graphics requests. +.PN InputOnly +windows are invisible and are used to control such things as cursors, +input event generation, and grabbing. +.PN InputOnly +windows cannot have +.PN InputOutput +windows as inferiors. +.KE +.LP +.KS +\fBInputOutput window\fP +.IN "Window" "InputOutput" "@DEF@" +.IP +An +.PN InputOutput +window is the normal kind of window that is used for both input and output. +.PN InputOutput +windows can have both +.PN InputOutput +and +.PN InputOnly +windows as inferiors. +.KE +.LP +.KS +\fBInternationalization\fP +.IN "Internationalization" "" "@DEF@" +.IP +The process of making software adaptable to the requirements +of different native languages, local customs, and character string encodings. +Making a computer program adaptable to different locales +without program source modifications or recompilation. +.KE +.LP +.KS +\fBISO2022\fP +.IN "ISO2022" "" "@DEF@" +.IP +ISO standard for code extension techniques for 7-bit and 8-bit coded +character sets. +.KE +.LP +.KS +\fBKey grabbing\fP +.IN "Key" "grabbing" "@DEF@" +.IP +Keys on the keyboard can be passively grabbed by a client. +When the key is pressed, +the keyboard is then actively grabbed by the client. +.KE +.LP +.KS +\fBKeyboard grabbing\fP +.IN "Keyboard" "grabbing" "@DEF@" +.IP +A client can actively grab control of the keyboard, and key events +will be sent to that client rather than the client the events would +normally have been sent to. +.KE +.LP +.KS +\fBKeysym\fP +.IN "Keysym" "" "@DEF@" +.IP +An encoding of a symbol on a keycap on a keyboard. +.KE +.LP +.KS +\fBLatin-1\fP +.IN "Latin-1" "" "@DEF@" +.IP +The coded character set defined by the ISO8859-1 standard. +.KE +.LP +.KS +\fBLatin Portable Character Encoding\fP +.IN "Latin Portable Character Encoding" "" "@DEF@" +.IP +The encoding of the X Portable Character Set using the Latin-1 codepoints +plus ASCII control characters. +If a string is said to be in the Latin Portable Character Encoding, +then it only contains characters from the X Portable Character Set, +not all of Latin-1. +.KE +.LP +.KS +\fBLocale\fP +.IN "Locale" "" "@DEF@" +.IP +The international environment of a computer program defining the ``localized'' +behavior of that program at run-time. +This information can be established from one or more sets of localization data. +ANSI C defines locale-specific processing by C system library calls. +See ANSI C and the X/Open Portability Guide specifications for more details. +In this specification, on implementations that conform to the ANSI C library, +the ``current locale'' is the current setting of the LC_CTYPE +.PN setlocale +category. +Associated with each locale is a text encoding. When text is processed +in the context of a locale, the text must be in the encoding of the locale. +The current locale affects Xlib in its: +.RS +.IP \(bu 5 +Encoding and processing of input method text +.IP \(bu 5 +Encoding of resource files and values +.IP \(bu 5 +Encoding and imaging of text strings +.IP \(bu 5 +Encoding and decoding for inter-client text communication +.RE +.KE +.LP +.KS +\fBLocale name\fP +.IN "Locale name" "" "@DEF@" +.IP +The identifier used to select the desired locale for the host C library +and X library functions. +On ANSI C library compliant systems, +the locale argument to the +.PN setlocale +function. +.KE +.LP +.KS +\fBLocalization\fP +.IN "Localization" "" "@DEF@" +.IP +The process of establishing information within a computer system specific +to the operation of particular native languages, local customs +and coded character sets. +(XPG3) +.KE +.LP +.KS +\fBMapped\fP +.IN "Mapped window" "" "@DEF@" +.IP +A window is said to be mapped if a map call has been performed on it. +Unmapped windows and their inferiors are never viewable or visible. +.KE +.LP +.KS +\fBModifier keys\fP +.IN "Modifier keys" "" "@DEF@" +.IP +Shift, Control, Meta, Super, Hyper, Alt, Compose, Apple, CapsLock, +ShiftLock, and similar keys are called modifier keys. +.KE +.LP +.KS +\fBMonochrome\fP +.IN "Monochrome" "" "@DEF@" +.IP +Monochrome is a special case of +.PN StaticGray +in which there are only two colormap entries. +.KE +.LP +.KS +\fBMultibyte\fP +.IN "Multibyte" "" "@DEF@" +.IP +A character whose codepoint is stored in more than one byte; +any encoding which can contain multibyte characters; +text in a multibyte encoding. +The ``char *'' null-terminated string datatype in ANSI C. +Note that references in this document to multibyte strings +imply only that the strings \fImay\fP contain multibyte characters. +.KE +.LP +.KS +\fBObscure\fP +.IN "Obscure" "" "@DEF@" +.IP +A window is obscured if some other window obscures it. +A window can be partially obscured and so still have visible regions. +Window A obscures window B if both are viewable +.PN InputOutput +windows, if A is higher in the global stacking order, +and if the rectangle defined by the outside +edges of A intersects the rectangle defined by the outside edges of B. +Note the distinction between obscures and occludes. +Also note that window borders are included in the calculation. +.KE +.LP +.KS +\fBOcclude\fP +.IN "Occlude" "" "@DEF@" +.IP +A window is occluded if some other window occludes it. +Window A occludes window B if both are mapped, +if A is higher in the global stacking order, +and if the rectangle defined by the outside edges of A intersects the rectangle defined +by the outside edges of B. +Note the distinction between occludes and obscures. +Also note that window borders are included in the calculation +and that +.PN InputOnly +windows never obscure other windows but can occlude other windows. +.KE +.LP +.KS +\fBPadding\fP +.IN "Padding" "" "@DEF@" +.IP +Some padding bytes are inserted in the data stream to maintain +alignment of the protocol requests on natural boundaries. +This increases ease of portability to some machine architectures. +.KE +.LP +.KS +\fBParent window\fP +.IN "Window" "parent" "@DEF@" +.IP +If C is a child of P, then P is the parent of C. +.KE +.LP +.KS +\fBPassive grab\fP +.IN "Passive grab" "" "@DEF@" +.IP +Grabbing a key or button is a passive grab. +The grab activates when the key or button is actually pressed. +.KE +.LP +.KS +\fBPixel value\fP +.IN "Pixel value" "" "@DEF@" +.IP +A pixel is an N-bit value, +where N is the number of bit planes used in a particular window or pixmap +(that is, is the depth of the window or pixmap). +A pixel in a window indexes a colormap to derive an actual color to be +displayed. +.KE +.LP +.KS +\fBPixmap\fP +.IN "Pixmap" "" "@DEF@" +.EQ +delim %% +.EN +.IP +A pixmap is a three-dimensional array of bits. +A pixmap is normally thought of as a two-dimensional array of pixels, +where each pixel can be a value from 0 to %2 sup N %\-1, +and where N is the depth (z axis) of the pixmap. +A pixmap can also be thought of as a stack of N bitmaps. +A pixmap can only be used on the screen that it was created in. +.KE +.LP +.KS +\fBPlane\fP +.IN "Plane" "" "@DEF@" +.IP +When a pixmap or window is thought of as a stack of bitmaps, each +bitmap is called a plane or bit plane. +.KE +.LP +.KS +\fBPlane mask\fP +.IN "Plane" "mask" "@DEF@" +.IP +Graphics operations can be restricted to only affect a subset of bit +planes of a destination. +A plane mask is a bit mask describing which planes are to be modified. +The plane mask is stored in a graphics context. +.KE +.LP +.KS +\fBPointer\fP +.IN "Pointer" "" "@DEF@" +.IP +The pointer is the pointing device currently attached to the cursor +and tracked on the screens. +.KE +.LP +.KS +\fBPointer grabbing\fP +.IN "Pointer" "grabbing" "@DEF@" +.IP +A client can actively grab control of the pointer. +Then button and motion events will be sent to that client +rather than the client the events would normally have been sent to. +.KE +.LP +.KS +\fBPointing device\fP +.IN "Pointing device" "" "@DEF@" +.IP +A pointing device is typically a mouse, tablet, or some other +device with effective dimensional motion. +The core protocol defines only one visible cursor, +which tracks whatever pointing device is attached as the pointer. +.KE +.LP +.KS +\fBPOSIX\fP +.IN "POSIX" "" "@DEF@" +.IP +Portable Operating System Interface, ISO/IEC 9945-1 (IEEE Std 1003.1). +.KE +.LP +.KS +\fBPOSIX Portable Filename Character Set\fP +.IN "POSIX Portable Filename Character Set" "" "@DEF@" +.IP +The set of 65 characters which can be used in naming files on a POSIX-compliant +host that are correctly processed in all locales. +The set is: +.IP +.Ds 0 +a..z A..Z 0..9 ._- +.De +.KE +.LP +.KS +\fBProperty\fP +.IN "Property" "" "@DEF@" +.IP +Windows can have associated properties that consist of a name, a type, +a data format, and some data. +The protocol places no interpretation on properties. +They are intended as a general-purpose naming mechanism for clients. +For example, clients might use properties to share information such as resize +hints, program names, and icon formats with a window manager. +.KE +.LP +.KS +\fBProperty list\fP +.IN "Property list" "" "@DEF@" +.IP +The property list of a window is the list of properties that have +been defined for the window. +.KE +.LP +.KS +\fBPseudoColor\fP +.IN "PseudoColor" "" "@DEF@" +.IP +.PN PseudoColor +is a class of colormap in which a pixel value indexes the colormap entry to +produce an independent RGB value; +that is, the colormap is viewed as an array of triples (RGB values). +The RGB values can be changed dynamically. +.KE +.LP +.KS +\fBRectangle\fP +.IN "Rectangle" "" "@DEF@" +.IP +A rectangle specified by [x,y,w,h] has an infinitely thin +outline path with corners at [x,y], [x+w,y], [x+w,y+h], and [x, y+h]. +When a rectangle is filled, +the lower-right edges are not drawn. +For example, +if w=h=0, +nothing would be drawn. +For w=h=1, +a single pixel would be drawn. +.KE +.LP +.KS +\fBRedirecting control\fP +.IN "Redirecting control" "" "@DEF@" +.IP +Window managers (or client programs) may enforce window layout +policy in various ways. +When a client attempts to change the size or position of a window, +the operation may be redirected to a specified client +rather than the operation actually being performed. +.KE +.LP +.KS +\fBReply\fP +.IN "Reply" "" "@DEF@" +.IP +Information requested by a client program using the X protocol +is sent back to the client with a reply. +Both events and replies are multiplexed on the same connection. +Most requests do not generate replies, +but some requests generate multiple replies. +.KE +.LP +.KS +\fBRequest\fP +.IN "Request" "" "@DEF@" +.IP +A command to the server is called a request. +It is a single block of data sent over a connection. +.KE +.LP +.KS +\fBResource\fP +.IN "Resource" "" "@DEF@" +.IP +Windows, pixmaps, cursors, fonts, graphics contexts, and colormaps are +known as resources. +They all have unique identifiers associated with them for naming purposes. +The lifetime of a resource usually is bounded by the lifetime of the +connection over which the resource was created. +.KE +.LP +.KS +\fBRGB values\fP +.IN "RGB values" "" "@DEF@" +.IP +RGB values are the red, green, and blue intensity values that are used +to define a color. +These values are always represented as 16-bit, unsigned numbers, with 0 +the minimum intensity and 65535 the maximum intensity. +The X server scales these values to match the display hardware. +.KE +.LP +.KS +\fBRoot\fP +.IN "Root" "" "@DEF@" +.IP +The root of a pixmap or graphics context is the same as the root +of whatever drawable was used when the pixmap or GC was created. +The root of a window is the root window under which the window was created. +.KE +.LP +.KS +\fBRoot window\fP +.IN "Window" "root" "@DEF@" +.IP +Each screen has a root window covering it. +The root window cannot be reconfigured or unmapped, +but otherwise it acts as a full-fledged window. +A root window has no parent. +.KE +.LP +.KS +\fBSave set\fP +.IN "Save set" "" "@DEF@" +.IP +The save set of a client is a list of other clients' windows that, +if they are inferiors of one of the client's windows at connection +close, should not be destroyed and that should be remapped +if currently unmapped. +Save sets are typically used by window managers to avoid +lost windows if the manager should terminate abnormally. +.KE +.LP +.KS +\fBScanline\fP +.IN "Scanline" "" "@DEF@" +.IP +A scanline is a list of pixel or bit values viewed as a horizontal +row (all values having the same y coordinate) of an image, with the +values ordered by increasing the x coordinate. +.KE +.LP +.KS +\fBScanline order\fP +.IN "Scanline" "order" "@DEF@" +.IP +An image represented in scanline order contains scanlines ordered by +increasing the y coordinate. +.KE +.LP +.KS +\fBScreen\fP +.IN "Screen" "" "@DEF@" +.IP +A server can provide several independent screens, +which typically have physically independent monitors. +This would be the expected configuration when there is only a single keyboard +and pointer shared among the screens. +A +.PN Screen +.IN "Screen" "structure" +structure contains the information about that screen +and is linked to the +.PN Display +.IN "Display" "structure" +structure. +.KE +.LP +.KS +\fBSelection\fP +.IN "Selection" "" "@DEF@" +.IP +A selection can be thought of as an indirect property with dynamic +type. +That is, rather than having the property stored in the X server, +it is maintained by some client (the owner). +A selection is global and is thought of as belonging to the user +and being maintained by clients, +rather than being private to a particular window subhierarchy +or a particular set of clients. +When a client asks for the contents of +a selection, it specifies a selection target type, +which can be used to control the transmitted representation of the contents. +For example, if the selection is ``the last thing the user clicked on,'' +and that is currently an image, then the target type might specify +whether the contents of the image should be sent in XY format or +Z format. +.IP +The target type can also be used to control the class of +contents transmitted; for example, +asking for the ``looks'' (fonts, line +spacing, indentation, and so forth) of a paragraph selection, rather than the +text of the paragraph. +The target type can also be used for other +purposes. +The protocol does not constrain the semantics. +.KE +.LP +.KS +\fBServer\fP +.IN "Server" "" "@DEF@" +.IP +The server, which is also referred to as the X server, +provides the basic windowing mechanism. +It handles IPC connections from clients, +multiplexes graphics requests onto the screens, +and demultiplexes input back to the appropriate clients. +.KE +.LP +.KS +\fBServer grabbing\fP +.IN "Server" "grabbing" "@DEF@" +.IP +The server can be grabbed by a single client for exclusive use. +This prevents processing of any requests from other client connections until +the grab is completed. +This is typically only a transient state for such things as rubber-banding, +pop-up menus, or executing requests indivisibly. +.KE +.LP +.KS +\fBShift sequence\fP +.IN "Shift sequence" "" "@DEF@" +.IP +ISO2022 defines control characters and escape sequences +which temporarily (single shift) or permanently (locking shift) cause a +different character set to be in effect (``invoking'' a character set). +.KE +.LP +.KS +\fBSibling\fP +.IN "Sibling" "" "@DEF@" +.IP +Children of the same parent window are known as sibling windows. +.KE +.LP +.KS +\fBStacking order\fP +.IN "Stacking order" "" "@DEF@" +.IP +Sibling windows, similar to sheets of paper on a desk, +can stack on top of each other. +Windows above both obscure and occlude lower windows. +The relationship between sibling windows is known as the stacking order. +.KE +.LP +.KS +\fBState-dependent encoding\fP +.IN "State-dependent encoding" "" "@DEF@" +.IP +An encoding in which an invocation of a charset can apply to multiple +characters in sequence. +A state-dependent encoding begins in an ``initial state'' +and enters other ``shift states'' when specific ``shift sequences'' +are encountered in the byte sequence. +In ISO2022 terms, +this means use of locking shifts, not single shifts. +.KE +.LP +.KS +\fBState-independent encoding\fP +.IN "State-independent encoding" "" "@DEF@" +.IP +Any encoding in which the invocations of the charsets are fixed, +or span only a single character. +In ISO2022 terms, +this means use of at most single shifts, not locking shifts. +.KE +.LP +.KS +\fBStaticColor\fP +.IN "StaticColor" "" "@DEF@" +.IP +.PN StaticColor +can be viewed as a degenerate case of +.PN PseudoColor +in which the RGB values are predefined and read-only. +.KE +.LP +.KS +\fBStaticGray\fP +.IN "StaticGray" "" "@DEF@" +.IP +.PN StaticGray +can be viewed as a degenerate case of +.PN GrayScale +in which the gray values are predefined and read-only. +The values are typically linear or near-linear increasing ramps. +.KE +.LP +.KS +\fBStatus\fP +.IN "Status" "" "@DEF@" +.IP +Many Xlib functions return a success status. +If the function does not succeed, +however, its arguments are not disturbed. +.KE +.LP +.KS +\fBStipple\fP +.IN "Stipple" "" "@DEF@" +.IP +A stipple pattern is a bitmap that is used to tile a region to serve +as an additional clip mask for a fill operation with the foreground +color. +.KE +.KS +.LP +.KS +\fBSTRING encoding\fP +.IN "STRING encoding" "" "@DEF@" +.IP +Latin-1, plus tab and newline. +.KE +.LP +\fBString Equivalence\fP +.IN "String Equivalence" "" "@DEF@" +.IP +Two ISO Latin-1 STRING8 values are considered equal if they are the same +length and if corresponding bytes are either equal or are equivalent as +follows: decimal values 65 to 90 inclusive (characters ``A'' to ``Z'') are +pairwise equivalent to decimal values 97 to 122 inclusive +(characters ``a'' to ``z''), decimal values 192 to 214 inclusive +(characters ``A grave'' to ``O diaeresis'') are pairwise equivalent to decimal +values 224 to 246 inclusive (characters ``a grave'' to ``o diaeresis''), +and decimal values 216 to 222 inclusive (characters ``O oblique'' to ``THORN'') +are pairwise equivalent to decimal values 246 to 254 inclusive +(characters ``o oblique'' to ``thorn''). +.KE +.LP +.KS +\fBTile\fP +.IN "Tile" "" "@DEF@" +.IP +A pixmap can be replicated in two dimensions to tile a region. +The pixmap itself is also known as a tile. +.KE +.LP +.KS +\fBTimestamp\fP +.IN "Timestamp" "" "@DEF@" +.IP +A timestamp is a time value expressed in milliseconds. +It is typically the time since the last server reset. +Timestamp values wrap around (after about 49.7 days). +The server, given its current time is represented by timestamp T, +always interprets timestamps from clients by treating half +of the timestamp space as being earlier in time than T +and half of the timestamp space as being later in time than T. +One timestamp value, represented by the constant +.PN CurrentTime , +is never generated by the server. +This value is reserved for use in requests to represent the current server time. +.KE +.LP +.KS +\fBTrueColor\fP +.IN "TrueColor" "" "@DEF@" +.IP +.PN TrueColor +can be viewed as a degenerate case of +.PN DirectColor +in which the subfields in the pixel value directly encode the corresponding RGB +values. +That is, the colormap has predefined read-only RGB values. +The values are typically linear or near-linear increasing ramps. +.KE +.LP +.KS +\fBType\fP +.IN "Type" "" "@DEF@" +.IP +A type is an arbitrary atom used to identify the interpretation of property +data. +Types are completely uninterpreted by the server. +They are solely for the benefit of clients. +X predefines type atoms for many frequently used types, +and clients also can define new types. +.KE +.LP +.KS +\fBViewable\fP +.IN "Viewable" "" "@DEF@" +.IP +A window is viewable if it and all of its ancestors are mapped. +This does not imply that any portion of the window is actually visible. +Graphics requests can be performed on a window when it is not +viewable, but output will not be retained unless the server is maintaining +backing store. +.KE +.LP +.KS +\fBVisible\fP +.IN "Visible" "" "@DEF@" +.IP +A region of a window is visible if someone looking at the screen can +actually see it; that is, the window is viewable and the region is not occluded +by any other window. +.KE +.LP +.KS +\fBWhitespace\fP +.IN "Whitespace" "" "@DEF@" +.IP +Any spacing character. +On implementations that conform to the ANSI C library, +whitespace is any character for which +.PN isspace +returns true. +.KE +.LP +.KS +\fBWindow gravity\fP +.IN "Window" "gravity" "@DEF@" +.IP +When windows are resized, +subwindows may be repositioned automatically relative to some position in the +window. +This attraction of a subwindow to some part of its parent is known +as window gravity. +.KE +.LP +.KS +\fBWindow manager\fP +.IN "Window" "manager" "@DEF@" +.IP +Manipulation of windows on the screen and much of the user interface +(policy) is typically provided by a window manager client. +.KE +.LP +.KS +\fBX Portable Character Set\fP +.IN "X Portable Character Set" "" "@DEF@" +.IP +A basic set of 97 characters which are assumed to exist in all +locales supported by Xlib. This set contains the following characters: +.IP +.Ds 0 +.EQ +delim DD +.EN +a..z A..Z 0..9 +!"#$%&'()*+,-./:;<=>?@[\\]^_`{|}~ +, , and +.EQ +delim %% +.EN +.De +.IP +This is the left/lower half (also called the G0 set) +of the graphic character set of ISO8859-1 plus , , and . +It is also the set of graphic characters in 7-bit ASCII plus the same +three control characters. +The actual encoding of these characters on the host is system dependent; +see the Host Portable Character Encoding. +.KE +.LP +.KS +\fBXLFD\fP +.IN "XLFD" "" "@DEF@" +.IP +The X Logical Font Description Conventions that define a standard syntax +for structured font names. +.KE +.LP +.KS +\fBXY format\fP +.IN "XY format" "" "@DEF@" +.IP +The data for a pixmap is said to be in XY format if it is organized as +a set of bitmaps representing individual bit planes with the planes +appearing from most-significant to least-significant bit order. +.KE +.LP +.KS +\fBZ format\fP +.IN "Z format" "" "@DEF@" +.IP +The data for a pixmap is said to be in Z format if it is organized as +a set of pixel values in scanline order. +.KE +.LP +\fBReferences\fP +.LP +ANSI Programming Language - C: ANSI X3.159-1989, December 14, 1989. +.LP +Draft Proposed Multibyte Extension of ANSI C, Draft 1.1, November 30, +1989, SC22/C WG/SWG IPSJ/ITSCJ Japan. +.LP +ISO2022: Information processing - ISO 7-bit and 8-bit coded character +sets - Code extension techniques. +.LP +ISO8859-1: Information processing - 8-bit single-byte coded graphic +character sets - Part 1: Latin alphabet No. 1. +.LP +POSIX: Information Technology - Portable Operating System Interface (POSIX) - +Part 1: System Application Program Interface (API) [C Language], +ISO/IEC 9945-1. +.LP +Text of ISO/IEC/DIS 9541-1, Information Processing - Font Information +Interchange - Part 1: Architecture. +.LP +X/Open Portability Guide, Issue 3, December 1988 (XPG3), X/Open Company, +Ltd, Prentice-Hall, Inc. 1989. ISBN 0-13-685835-8. +(See especially Volume 3: XSI Supplementary Definitions.) +.bp diff --git a/libX11/specs/libX11/libX11.ms b/libX11/specs/libX11/libX11.ms new file mode 100644 index 000000000..b44425623 --- /dev/null +++ b/libX11/specs/libX11/libX11.ms @@ -0,0 +1,24 @@ +.so abstract.t +.so credits.t +.so CH01 +.so CH02 +.so CH03 +.so CH04 +.so CH05 +.so CH06 +.so CH07 +.so CH08 +.so CH09 +.so CH10 +.so CH11 +.so CH12 +.so CH13 +.so CH14 +.so CH15 +.so CH16 +.so AppA +.so AppB +.so AppC +.so AppD +.so glossary +.so postproc diff --git a/libX11/specs/libX11/postproc b/libX11/specs/libX11/postproc new file mode 100644 index 000000000..0f45a5a00 --- /dev/null +++ b/libX11/specs/libX11/postproc @@ -0,0 +1,17 @@ +.\" +.\" print Table of Contents +.if e \& \" Force blank page to begin TOC on an odd (right-hand) page. +.EH '''' +.OH '''' +.bp +\& \" Want old footings if blank page was forced. +.EF '''' +.OF '''' +.XS +Index +.XE +.EQ +delim $$ +.EN +.tm .pn \n% +.PX diff --git a/libX11/specs/macros.t b/libX11/specs/macros.t new file mode 100644 index 000000000..cbc599b3f --- /dev/null +++ b/libX11/specs/macros.t @@ -0,0 +1,226 @@ +.\" $Xorg: macros.t,v 1.3 2000/08/17 19:42:51 cpqbld Exp $ +.\" macros.t -- macros for X Consortium documents +.\" Revised and commented by smarks 93.12.20. +.\" +.\" global setup: set ragged right, assign string variables +.\" +.na +.ie n \{\ +.ds Q \&" +.ds U \&" +.ds - \%-- +.\} +.el \{\ +.ds Q `\h'-\w'\^'u'` +.ds U '\h'-\w'\^'u'' +.ds - \(em +.\} +.\" +.\" --- Ds --- displayed text (like .DS) with no keep +.\" .Ds is obsolete. Change to something from this table: +.\" for this use instead +.\" .Ds .ID +.\" .Ds n .LD (where "n" is a number) +.\" (Numbers don't work in these macros, so ".Ds 5" +.\" comes out the same as ".Ds 0".) +.\" +.de Ds +.nf +.\\$1D \\$2 \\$1 +.ft 1 +.ps \\n(PS +.if \\n(VS>=40 .vs \\n(VSu +.if \\n(VS<=39 .vs \\n(VSp +.. +.de D +.ID \\$1 +.. +.de 0D +.LD +.. +.\" backward compatibility for the Xt spec +.de 5D +.LD +.. +.\" +.\" --- De --- obsolete: use .DE instead +.\" +.de De +.DE +.. +.\" +.\" --- FD --- +.\" +.de FD +.LP +.KS +.TA .5i 3i +.ta .5i 3i +.nf +.. +.\" +.\" --- FN --- +.\" +.de FN +.fi +.KE +.LP +.. +.\" +.\" --- IN --- send an index entry to the stderr +.\" +.de IN +.tm \\n%:\\$1:\\$2:\\$3 +.. +.\" +.\" --- C{ --- +.\" +.de C{ +.KS +.nf +.D +.\" +.\" choose appropriate monospace font +.\" the imagen conditional, 480, +.\" may be changed to L if LB is too +.\" heavy for your eyes... +.\" +.ie "\\*(.T"480" .ft L +.el .ie "\\*(.T"300" .ft L +.el .ie "\\*(.T"202" .ft PO +.el .ie "\\*(.T"aps" .ft CW +.el .ft R +.ps \\n(PS +.ie \\n(VS>40 .vs \\n(VSu +.el .vs \\n(VSp +.. +.\" +.\" --- C} --- +.\" +.de C} +.DE +.R +.. +.\" +.\" --- Pn --- like PN, but use $2; $1 and $3 abut +.\" +.de Pn +.IN \\$2 +.ie t \\$1\fB\^\\$2\^\fR\\$3 +.el \\$1\fI\^\\$2\^\fP\\$3 +.. +.\" +.\" --- PN --- put $1 in boldface and add index entry; $2 abuts +.\" +.de PN +.IN \\$1 +.ie t \fB\^\\$1\^\fR\\$2 +.el \fI\^\\$1\^\fP\\$2 +.. +.\" +.\" --- hI --- add index entry for $1 as header file +.\" +.de hI +.IN <\\$1> +.IN Files <\\$1> +.IN Headers <\\$1> +.. +.\" +.\" --- hN --- put $1 in boldface as header and add index entry; $2 abuts +.\" +.de hN +.hI \\$1 +.ie t <\fB\\$1\fR>\\$2 +.el <\fI\\$1\fP>\\$2 +.. +.\" +.\" --- NT --- +.\" +.de NT +.br +.ne 7 +.ds NO Note +.if \\n(.$ .ds NO \\$1 +.ie n .sp +.el .sp 10p +.ce +\\*(NO +.ie n .sp +.el .sp 5p +.if '\\$1'C' .ce 99 +.if '\\$2'C' .ce 99 +.\" .QS/.QE macros don't exist in older versions of -ms +.ie \\n(GS .QS +.el \{\ +. in +5n +. ll -5n +.\} +.R +.. +.\" +.\" --- NE --- Note End (doug kraft 3/85) +.\" +.de NE +.ce 0 +.ie \\n(GS .QE +.el \{\ +. in -5n +. ll +5n +.\} +.ie n .sp +.el .sp 10p +.. +.\" +.\" --- nH --- numbered header (like NH) but with automatic TOC entry +.\" usage: .nH level "section title, preferable in quotes" +.\" +.de nH +.NH \\$1 +\\$2 +.XS +\\*(SN \\$2 +.XE +.. +.\" +.\" --- sM --- put start-marker in margin +.\" +.de sM +.KS +.sp 1 +\\h'-0.5i'\\L'-1v'\\v'1p'\\l'1v'\\v'1v-1p' +.sp -1 +.. +.\" +.\" --- eM --- put end-marker in margin +.\" +.de eM +.sp -1 +\\h'-0.5i'\\L'-1v'\\v'1v+1p'\\l'1v'\\v'-1p' +.sp 1 +.KE +.. +.\" +.\" --- YZ --- finish up; $1 is the starting page number of the TOC +.\" +.de YZ +. \" Force there to be an even number of pages, so the table of +. \" contents doesn't end up on the back of the last page in +. \" the case of duplex printing. +.if o .bp +. \" Emit a .pn directive with one plus the last page number. + \" This will be the number of the first page of the index. +.nr YZ \\n%+1 +.tm .pn \\n(YZ +. \" Issue the table of contents, setting roman numerals, +. \" and redefining the footer to use them. +.bp \\$1 +.af PN i +.EF ''\\\\\\\\n(PN'' +.OF ''\\\\\\\\n(PN'' +. \" Why all the backslashes? This string is evaluated +. \" three times: 1) during the definition of this macro, +. \" 2) when the .EF and .OF macros are expanded, and 3) +. \" when the bottom-of-page trap is invoked. Thus, +. \" eight backslashes are reduced to one in the final output. +.PX +.. diff --git a/libX11/specs/troffrules.in b/libX11/specs/troffrules.in new file mode 100644 index 000000000..03d8463e8 --- /dev/null +++ b/libX11/specs/troffrules.in @@ -0,0 +1,68 @@ +# +# Copyright 2009 Sun Microsystems, Inc. All rights reserved. +# +# 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 copyright holders 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 copyright holders. +# + +# Based on xc/doc/specs/*/Makefile from X11R6.9 + +EXTRA_DIST = $(doc_sources) + +if HAVE_PS2PDF +printable_format = .pdf +else +printable_format = .ps +endif + +if BUILD_SPECS +doc_DATA = $(doc_sources:.ms=.txt) \ + $(doc_sources:.ms=$(printable_format)) \ + $(doc_sources:.ms=.html) + +CLEANFILES = $(doc_DATA) +MOSTLYCLEANFILES = index.* + +# Pass version string as a troff string for substitution +GROFF_DEFS = -dxV="$(PACKAGE_STRING)" + +# -e to run through eqn, -t to run through tbl +GROFF_FLAGS = -e -t -ms $(GROFF_DEFS) $(top_srcdir)/specs/macros.t + +SUFFIXES = .ms .ps .txt .html .pdf + +.ms.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 + +.ms.txt: + $(AM_V_GEN) env GROFF_NO_SGR=TRUE $(GROFF) -Tutf8 $(GROFF_FLAGS) \ + $< 2> index.$@.raw > $@ + +.ms.html: + $(AM_V_GEN) $(GROFF) -Thtml $(GROFF_FLAGS) $< 2> index.$@.raw > $@ + +.ps.pdf: + $(AM_V_GEN) $(PS2PDF) $< $@ + +endif BUILD_SPECS diff --git a/libX11/src/Makefile.am b/libX11/src/Makefile.am index 26d8e277f..51e1e0660 100644 --- a/libX11/src/Makefile.am +++ b/libX11/src/Makefile.am @@ -8,7 +8,7 @@ lib_LTLIBRARIES=libX11.la BUILT_SOURCES=ks_tables.h CLEANFILES=ks_tables.h ks_tables_h -AM_CFLAGS= \ +AM_CPPFLAGS= \ -I$(top_srcdir)/include \ -I$(top_srcdir)/include/X11 \ -I$(top_builddir)/include \ @@ -16,10 +16,12 @@ AM_CFLAGS= \ -I$(top_srcdir)/src/xcms \ -I$(top_srcdir)/src/xkb \ -I$(top_srcdir)/src/xlibi18n \ + -D_BSD_SOURCE -DX11_t -DTRANS_CLIENT + +AM_CFLAGS= \ $(X11_CFLAGS) \ $(BIGFONT_CFLAGS) \ $(XDMCP_CFLAGS) \ - -D_BSD_SOURCE -DX11_t -DTRANS_CLIENT \ $(XMALLOC_ZERO_CFLAGS) # diff --git a/libX11/src/Makefile.in b/libX11/src/Makefile.in index a79daa847..f1b62ffdc 100644 --- a/libX11/src/Makefile.in +++ b/libX11/src/Makefile.in @@ -307,6 +307,10 @@ 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@ @@ -314,16 +318,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -336,7 +342,6 @@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ # KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -346,7 +351,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -357,12 +361,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -372,6 +372,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -410,7 +411,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -442,7 +444,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -463,7 +464,7 @@ SUBDIRS = util xcms xlibi18n $(XKB_SUBDIRS) lib_LTLIBRARIES = libX11.la $(am__append_5) BUILT_SOURCES = ks_tables.h CLEANFILES = ks_tables.h ks_tables_h $(am__append_7) -AM_CFLAGS = \ +AM_CPPFLAGS = \ -I$(top_srcdir)/include \ -I$(top_srcdir)/include/X11 \ -I$(top_builddir)/include \ @@ -471,10 +472,12 @@ AM_CFLAGS = \ -I$(top_srcdir)/src/xcms \ -I$(top_srcdir)/src/xkb \ -I$(top_srcdir)/src/xlibi18n \ + -D_BSD_SOURCE -DX11_t -DTRANS_CLIENT + +AM_CFLAGS = \ $(X11_CFLAGS) \ $(BIGFONT_CFLAGS) \ $(XDMCP_CFLAGS) \ - -D_BSD_SOURCE -DX11_t -DTRANS_CLIENT \ $(XMALLOC_ZERO_CFLAGS) diff --git a/libX11/src/OpenDis.c b/libX11/src/OpenDis.c index 230ae561f..d6c7b80d5 100644 --- a/libX11/src/OpenDis.c +++ b/libX11/src/OpenDis.c @@ -273,21 +273,28 @@ XOpenDisplay ( #ifndef XLIBMINBUFSIZE #define XLIBMINBUFSIZE BUFSIZE /* old default buffer size */ #endif - if ((xlib_buffer_size = getenv("XLIBBUFFERSIZE")) == NULL) - conn_buf_size = XLIBDEFAULTBUFSIZE; - else - conn_buf_size = 1024 * strtol(xlib_buffer_size, NULL, 10); - if (conn_buf_size < XLIBMINBUFSIZE) - conn_buf_size = XLIBMINBUFSIZE; - - if ((dpy->bufptr = dpy->buffer = Xcalloc(1, conn_buf_size)) == NULL) { - OutOfMemory (dpy, setup); - return(NULL); - } - dpy->bufmax = dpy->buffer + conn_buf_size; + xlib_buffer_size = getenv("XLIBBUFFERSIZE"); + +#ifdef __sun /* Backwards compatibility for old Solaris libX11 name */ + if (xlib_buffer_size == NULL) + xlib_buffer_size = getenv("XSUNBUFFERSIZE"); +#endif + + if (xlib_buffer_size == NULL) + conn_buf_size = XLIBDEFAULTBUFSIZE; + else + conn_buf_size = 1024 * strtol(xlib_buffer_size, NULL, 10); + if (conn_buf_size < XLIBMINBUFSIZE) + conn_buf_size = XLIBMINBUFSIZE; + + if ((dpy->bufptr = dpy->buffer = Xcalloc(1, conn_buf_size)) == NULL) { + OutOfMemory (dpy, setup); + return(NULL); + } + dpy->bufmax = dpy->buffer + conn_buf_size; #if USE_XCB - dpy->xcb->real_bufmax = dpy->bufmax; - dpy->bufmax = dpy->buffer; + dpy->xcb->real_bufmax = dpy->bufmax; + dpy->bufmax = dpy->buffer; #endif /* Set up the input event queue and input event queue parameters. */ diff --git a/libX11/src/SetLocale.c b/libX11/src/SetLocale.c index 015577726..a19baa927 100644 --- a/libX11/src/SetLocale.c +++ b/libX11/src/SetLocale.c @@ -121,7 +121,7 @@ _Xsetlocale( #else /* X_LOCALE */ -#ifdef __APPLE__ +#if defined(__APPLE__) || defined(__CYGWIN__) char * _Xsetlocale( int category, @@ -130,7 +130,7 @@ _Xsetlocale( { return setlocale(category, name); } -#endif /* __APPLE__ */ +#endif /* __APPLE__ || __CYGWIN__ */ /* * _XlcMapOSLocaleName is an implementation dependent routine that derives diff --git a/libX11/src/config.h.in b/libX11/src/config.h.in index 355b2b766..dad2901a0 100644 --- a/libX11/src/config.h.in +++ b/libX11/src/config.h.in @@ -69,6 +69,9 @@ /* Define to 1 if you have the `strtol' function. */ #undef HAVE_STRTOL +/* Define to 1 if you have the header file. */ +#undef HAVE_SYS_SELECT_H + /* Define to 1 if you have the header file. */ #undef HAVE_SYS_STAT_H @@ -87,10 +90,6 @@ /* preference sorted list of transport types to try for local connections */ #undef LOCAL_TRANSPORT_LIST -/* Define to the sub-directory in which libtool stores uninstalled libraries. - */ -#undef LT_OBJDIR - /* Disable XLOCALEDIR environment variable */ #undef NO_XLOCALEDIR diff --git a/libX11/src/util/Makefile.in b/libX11/src/util/Makefile.in index bf855c110..88e217bf1 100644 --- a/libX11/src/util/Makefile.in +++ b/libX11/src/util/Makefile.in @@ -108,6 +108,10 @@ 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@ @@ -115,16 +119,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -133,7 +139,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -143,7 +148,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -154,12 +158,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -169,6 +169,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -207,7 +208,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -239,7 +241,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ diff --git a/libX11/src/xcb_io.c b/libX11/src/xcb_io.c index 4f0159c98..4bddbf419 100644 --- a/libX11/src/xcb_io.c +++ b/libX11/src/xcb_io.c @@ -1,6 +1,10 @@ /* Copyright (C) 2003-2006 Jamey Sharp, Josh Triplett * This file is licensed under the MIT license. See the file COPYING. */ +#ifdef HAVE_CONFIG_H +#include +#endif + #include "Xlibint.h" #include "locking.h" #include "Xprivate.h" @@ -12,6 +16,9 @@ #include #include #include +#ifdef HAVE_SYS_SELECT_H +#include +#endif static void return_socket(void *closure) { diff --git a/libX11/src/xcms/Makefile.am b/libX11/src/xcms/Makefile.am index dac620e5d..1f1b51d5b 100644 --- a/libX11/src/xcms/Makefile.am +++ b/libX11/src/xcms/Makefile.am @@ -1,6 +1,6 @@ noinst_LTLIBRARIES = libxcms.la -AM_CFLAGS= \ +AM_CPPFLAGS= \ -I$(top_srcdir)/include \ -I$(top_srcdir)/include/X11 \ -I$(top_builddir)/include \ @@ -9,10 +9,12 @@ AM_CFLAGS= \ -I$(top_srcdir)/src/xkb \ -I$(top_srcdir)/src/xlibi18n \ -I$(top_srcdir)/src \ + -D_BSD_SOURCE + +AM_CFLAGS= \ $(X11_CFLAGS) \ $(BIGFONT_CFLAGS) \ $(XDMCP_CFLAGS) \ - -D_BSD_SOURCE \ $(XMALLOC_ZERO_CFLAGS) libxcms_la_SOURCES = \ diff --git a/libX11/src/xcms/Makefile.in b/libX11/src/xcms/Makefile.in index 6573196fd..43b7954ad 100644 --- a/libX11/src/xcms/Makefile.in +++ b/libX11/src/xcms/Makefile.in @@ -137,6 +137,10 @@ 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@ @@ -144,16 +148,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -162,7 +168,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -172,7 +177,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -183,12 +187,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -198,6 +198,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -236,7 +237,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -268,7 +270,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -285,7 +286,7 @@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ noinst_LTLIBRARIES = libxcms.la -AM_CFLAGS = \ +AM_CPPFLAGS = \ -I$(top_srcdir)/include \ -I$(top_srcdir)/include/X11 \ -I$(top_builddir)/include \ @@ -294,10 +295,12 @@ AM_CFLAGS = \ -I$(top_srcdir)/src/xkb \ -I$(top_srcdir)/src/xlibi18n \ -I$(top_srcdir)/src \ + -D_BSD_SOURCE + +AM_CFLAGS = \ $(X11_CFLAGS) \ $(BIGFONT_CFLAGS) \ $(XDMCP_CFLAGS) \ - -D_BSD_SOURCE \ $(XMALLOC_ZERO_CFLAGS) libxcms_la_SOURCES = \ diff --git a/libX11/src/xkb/Makefile.am b/libX11/src/xkb/Makefile.am index d54315464..0141836c8 100644 --- a/libX11/src/xkb/Makefile.am +++ b/libX11/src/xkb/Makefile.am @@ -1,4 +1,4 @@ -AM_CFLAGS= \ +AM_CPPFLAGS= \ -I$(top_srcdir)/include \ -I$(top_srcdir)/include/X11 \ -I$(top_builddir)/include \ @@ -6,10 +6,12 @@ AM_CFLAGS= \ -I$(top_srcdir)/src/xcms \ -I$(top_srcdir)/src/xkb \ -I$(top_srcdir)/src/xlibi18n \ + -D_BSD_SOURCE + +AM_CFLAGS= \ $(X11_CFLAGS) \ $(BIGFONT_CFLAGS) \ $(XDMCP_CFLAGS) \ - -D_BSD_SOURCE \ $(XMALLOC_ZERO_CFLAGS) noinst_LTLIBRARIES = libxkb.la diff --git a/libX11/src/xkb/Makefile.in b/libX11/src/xkb/Makefile.in index 0e526929d..70523a74d 100644 --- a/libX11/src/xkb/Makefile.in +++ b/libX11/src/xkb/Makefile.in @@ -106,6 +106,10 @@ 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@ @@ -113,16 +117,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -131,7 +137,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -141,7 +146,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -152,12 +156,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -167,6 +167,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -205,7 +206,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -237,7 +239,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -253,7 +254,7 @@ target_alias = @target_alias@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ -AM_CFLAGS = \ +AM_CPPFLAGS = \ -I$(top_srcdir)/include \ -I$(top_srcdir)/include/X11 \ -I$(top_builddir)/include \ @@ -261,10 +262,12 @@ AM_CFLAGS = \ -I$(top_srcdir)/src/xcms \ -I$(top_srcdir)/src/xkb \ -I$(top_srcdir)/src/xlibi18n \ + -D_BSD_SOURCE + +AM_CFLAGS = \ $(X11_CFLAGS) \ $(BIGFONT_CFLAGS) \ $(XDMCP_CFLAGS) \ - -D_BSD_SOURCE \ $(XMALLOC_ZERO_CFLAGS) noinst_LTLIBRARIES = libxkb.la diff --git a/libX11/src/xlibi18n/Makefile.am b/libX11/src/xlibi18n/Makefile.am index 9582a6561..fa5a1c071 100644 --- a/libX11/src/xlibi18n/Makefile.am +++ b/libX11/src/xlibi18n/Makefile.am @@ -1,4 +1,4 @@ -AM_CFLAGS= \ +AM_CPPFLAGS= \ -I$(top_srcdir)/include \ -I$(top_srcdir)/include/X11 \ -I$(top_builddir)/include \ @@ -7,10 +7,12 @@ AM_CFLAGS= \ -I$(top_srcdir)/src/xkb \ -I$(top_srcdir)/src/xlibi18n \ -I$(top_srcdir)/src \ + -D_BSD_SOURCE + +AM_CFLAGS= \ $(X11_CFLAGS) \ $(BIGFONT_CFLAGS) \ $(XDMCP_CFLAGS) \ - -D_BSD_SOURCE \ $(XMALLOC_ZERO_CFLAGS) noinst_LTLIBRARIES = libi18n.la diff --git a/libX11/src/xlibi18n/Makefile.in b/libX11/src/xlibi18n/Makefile.in index 50ac253b1..380a00b3a 100644 --- a/libX11/src/xlibi18n/Makefile.in +++ b/libX11/src/xlibi18n/Makefile.in @@ -134,6 +134,10 @@ 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@ @@ -141,16 +145,18 @@ DOLT_BASH = @DOLT_BASH@ DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ +ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ -FGREP = @FGREP@ +F77 = @F77@ +FFLAGS = @FFLAGS@ FILE_MAN_DIR = @FILE_MAN_DIR@ FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ GREP = @GREP@ +GROFF = @GROFF@ I18N_MODULE_LIBS = @I18N_MODULE_LIBS@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -159,7 +165,6 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ KEYSYMDEF = @KEYSYMDEF@ LAUNCHD = @LAUNCHD@ -LD = @LD@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ @@ -169,7 +174,6 @@ LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ LINT = @LINT@ LINTLIB = @LINTLIB@ LINT_FLAGS = @LINT_FLAGS@ -LIPO = @LIPO@ LN_S = @LN_S@ LTCOMPILE = @LTCOMPILE@ LTCXXCOMPILE = @LTCXXCOMPILE@ @@ -180,12 +184,8 @@ MALLOC_ZERO_CFLAGS = @MALLOC_ZERO_CFLAGS@ MISC_MAN_DIR = @MISC_MAN_DIR@ MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ MKDIR_P = @MKDIR_P@ -NM = @NM@ NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ @@ -195,6 +195,7 @@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ PKG_CONFIG = @PKG_CONFIG@ +PS2PDF = @PS2PDF@ RANLIB = @RANLIB@ RAWCPP = @RAWCPP@ RAWCPPFLAGS = @RAWCPPFLAGS@ @@ -233,7 +234,8 @@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_F77 = @ac_ct_F77@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ @@ -265,7 +267,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -281,7 +282,7 @@ target_alias = @target_alias@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ -AM_CFLAGS = \ +AM_CPPFLAGS = \ -I$(top_srcdir)/include \ -I$(top_srcdir)/include/X11 \ -I$(top_builddir)/include \ @@ -290,10 +291,12 @@ AM_CFLAGS = \ -I$(top_srcdir)/src/xkb \ -I$(top_srcdir)/src/xlibi18n \ -I$(top_srcdir)/src \ + -D_BSD_SOURCE + +AM_CFLAGS = \ $(X11_CFLAGS) \ $(BIGFONT_CFLAGS) \ $(XDMCP_CFLAGS) \ - -D_BSD_SOURCE \ $(XMALLOC_ZERO_CFLAGS) noinst_LTLIBRARIES = libi18n.la -- cgit v1.2.3