rapache-1.2.8/0000755000175100017510000000000012706745114012462 5ustar ondrejondrejrapache-1.2.8/ChangeLog0000644000175100017510000002350612706745114014242 0ustar ondrejondrej2013-12-15 jeffreyhorner * Release 1.2.5 * Bugfix for receiveBin 'length' argument * Disable some superfluous warnings to apache error log * Add SERVER$internals function to read apreq status 2013-10-15 jeffreyhorner * Release 1.2.4 * Bug fixes for receiveBin * Fix debian package to work with Apache 2.4 series 2013-01-14 jeffreyhorner * Release 1.2.3 * New setStatus() function for setting the HTTP status. 2013-01-10 jeffreyhorner * Release 1.2.2 * Set r->status if handler will return something other than OK 2012-10-01 jeffreyhorner * Release 1.2.1 * Don't parse POST paylod if apreq2 doesn't have a parser for the given content type. * More R protections. * Allow RFileHandlers to share environments if the handlers are defined in the same file. 2012-07-27 jeffreyhorner * Release 1.2.0 2012-07-26 jeffreyhorner * Fix compilation on apache 2.4.x: struct conn_rec member remote_ip was changed to client_ip. 2012-07-24 jeffreyhorner * Set working directory for r-script, RFileEval, and RFileHandler. 2012-06-01 jeffreyhorner * RSourceOnStartup bug fixed by donkang75. * Release 1.1.21 2012-05-04 jeffreyhorner * Release 1.1.20 2012-04-09 jeffreyhorner * Call apr_table_add for Set-Cookie headers; really fixes cookie bug. * Release 1.1.19 2012-04-05 jeffreyhorner * Fix single cookie bug * Release 1.1.18 2012-02-24 jeffreyhorner * Release 1.1.17 2012-02-21 jeffreyhorner * Refactor bug fix for r-script handlers 2012-01-16 jeffreyhorner * Logic bug for r-info * Release 1.1.16 2012-01-11 jeffreyhorner * Release 1.1.15 2011-12-30 jeffreyhorner * Some refactoring plus adding cmd_path to SERVER 2011-12-29 jeffreyhorner * Deprecated undocumented RPreserveEnv directive 2011-12-27 jeffreyhorner * Parse PUT requests through libapreq2 2011-12-22 jeffreyhorner * Deperecating ROutputErrors, some code formatting as well 2011-12-20 jeffreyhorner * Bare bones Rook support 2011-12-19 jeffreyhorner * Refactoring reading from request 2011-12-13 jeffreyhorner * Two new directives: RFileEval and REval. 2011-11-29 jeffreyhorner * Really fix protection issues 2011-08-03 jeffreyhorner * Making all output buffered 2011-03-21 Jeffrey Horner * Adding RApache_recBin 2011-01-12 Jeffrey Horner * Release 1.1.14 2011-01-11 Jeffrey Horner * Ensure .Call functions can work outside the context of a web request. 2010-12-08 Jeffrey Horner * Release 1.1.13 * All R and CGI related functions are attached to the search path in the named environment 'rapache' placed just before the base environment. 2010-10-23 Jeffrey Horner * Release 1.1.12 * Replaced calls to apr_file_printf with apr_file_write 2010-10-22 Jeffrey Horner * Release 1.1.11 * The server error log file descriptor is used instead of stderr for printing to the error log. Changed the calls to use apr_file_printf and apr_file_flush. 2010-10-04 Jeffrey Horner * Release 1.1.10 * Added printing of apache conf filename and line number on rApache startup error. * Eliminated -Wall warnings * Cleaned up error and warning reporting. Involved reworking dispatch code. 2010-03-26 Jeffrey Horner * Noted an issue in test/http.conf.in when using a file in more than one way * Fixed a bug in undocumented directive RPreserveEnv. * Fixed compile warning on bad first argument to fprintf 2009-04-05 Jeffrey Horner * Release 1.1.8 2009-03-18 Jeffrey Horner * Fixing a typo in test.R * Preparing mod_R.c for R 2.9.0 and strict type checking. 2009-01-22 Jeffrey Horner * Release 1.1.7 * Added HTML manual in distribution, plus documentation for VM. 2009-01-15 Jeffrey Horner * Release 1.1.6 * Function handlers now have their closure environments point to the RApache environment for the duration of the requst. * Fixed accidental pointer dereference in EvalExprs(). 2009-01-09 Jeffrey Horner * Fixed RSourceOnStartup; missing PROTECT(). * Removed non API code from EvalExprs(). 2008-12-05 Jeffrey Horner * Release 1.1.5 * Fixed off-by-one bug in RApache_getServer(). 2008-10-22 Jeffrey Horner * Release 1.1.4 * Fixed ROutputErrors reset * Fixed RApacheInfo 2008-10-09 Jeffrey Horner * Release 1.1.3 * Fudged release process. Hopefully fixed now. 2008-10-09 Jeffrey Horner * Release 1.1.2 2008-10-08 Jeffrey Horner * RApacheOutputErrors had no effect on functions that were smart enough to trap errors with try, e.g. brew. The fix is to test if those functions return an object of 'try-error'. * If a request uses R's read functions to read the incoming POST data, then we clear the pushback with .Internal(clearPushBack(stdin())) 2008-10-07 Jeffrey Horner * Release 1.1.1 * Updated .Call methods to use R_getEmbeddingDllInfo(void) which was added in R 2.6.0. * Updated RApacheOutputErrors by making the change per request. added two new arguments... prefix and suffix to override module versions. 2008-10-06 Jeffrey Horner * Thanks to Robert Kofler for finding a bug in test/test.R. * Thanks for Jeroen Ooms for all his great feedback. Really the first user to share his successes/complaints about rapache with me. * Added RApacheOutputErrors(status=TRUE) to allow users to change at will; the side-effect of which alters the HTTP response status code. status=TRUE will return 200, status=FALSE will return 500. 2008-07-24 Jeffrey Horner * Release 1.1.0 * Support for threaded mpm's. * Set the response content type to html when R*Handler directive is missing to force proper rendering of error message. 2008-07-23 Jeffrey Horner * Release 1.0.8 * SetHandler r-* without an R*Handler directive would cause apache to seg fault. Thanks to David Konerding. 2008-06-10 Jeffrey Horner * Release 1.0.7 * apr_pstrcat was missing final argument of NULL. Thanks to Aleksander Wawer. 2008-06-01 Jeffrey Horner * configure now properly detects if apache was installed with prefork mpm. * HAVE_UINTPTR_T is defined to satisfy Rinterface.h to properly export C stack variables. * add sendBin(object) function for sending binary data. 2008-05-28 Jeffrey Horner * Release 1.0.6 * Add output of Cstack_info() to r-info handler 2008-05-28 Jeffrey Horner * Release 1.0.5 * Turn off C stack checking after R has initialized. 2008-04-23 Jeffrey Horner * Release 1.0.4 * Updated embedding interface with const char * 2008-04-02 Jeffrey Horner * Release 1.0.3 * Added ChangeLog file * Added maintainer mode flag to configure. * test/test.R: Fixed form url; points to 'test/R'. * tools/config_http.R: added to dist to find HTTP for testing. 2008-02-20 Jeffrey Horner * Release 1.0.2 (skipped 1.0.1) * Don't cache the request handler call as we always need to find the correct function from the environment. * Added filename to SERVER variable. * Fixed a bug where the class wasn't being set correctly for the SERVER variables mtime and request_time 2007-08-08 Jeffrey Horner * Pre-release 1.0.0-useR2007: Major architectural changes * Getting rid of RApache R package * Exposing .Call() functions from mod_R.so * Copying request record to R objects and placing in environment on the search path. 2006-10-12 Jeffrey Horner * Release 0.1.5 (actually never released) * Big change! removing apache.write in favor of writing to stdout(). 2006-07-23 Jeffrey Horner * Release 0.1.4 * Added apache.encode() and apache.decode() for en(de)coding html entities * R now uses Apache's tmp dir 2006-03-24 Jeffrey Horner * Release 0.1.3 * Now plays nicely with mod_cgi (thanks to Jeremy Stephens). Apache runs cleanup code per-child after a fork and before executing cgi scripts. This was not handled properly, and R/Apache caused the child to segfault. 2006-02-17 Jeffrey Horner * Release 0.1.2 * Libraries and source files (specified with Rlibrary and Rsource in the apache config) are now loaded only once (thanks to Jeremy Stephens). * Added mod_R version component to Apache response headers 2005-09-30 Jeffrey Horner * Release 0.1.1 * Fixed spelling of R_module (thanks to Kevin E. Thorpe) in README and RApache/man/directives.Rd. * Fixed compile error on Mac OS X (thanks to Jan de Leeuw). * Fixed bug in as.list.apr_table (thanks to Gregoire Thomas) and subsequently in as.list.ra_request_rec rapache-1.2.8/INSTALL0000644000175100017510000001722712706745114013524 0ustar ondrejondrejBasic Installation ================== These are generic installation instructions. The `configure' shell script attempts to guess correct values for various system-dependent variables used during compilation. It uses those values to create a `Makefile' in each directory of the package. It may also create one or more `.h' files containing system-dependent definitions. Finally, it creates a shell script `config.status' that you can run in the future to recreate the current configuration, a file `config.cache' that saves the results of its tests to speed up reconfiguring, and a file `config.log' containing compiler output (useful mainly for debugging `configure'). If you need to do unusual things to compile the package, please try to figure out how `configure' could check whether to do them, and mail diffs or instructions to the address given in the `README' so they can be considered for the next release. If at some point `config.cache' contains results you don't want to keep, you may remove or edit it. The file `configure.in' is used to create `configure' by a program called `autoconf'. You only need `configure.in' if you want to change it or regenerate `configure' using a newer version of `autoconf'. The simplest way to compile this package is: 1. `cd' to the directory containing the package's source code and type `./configure' to configure the package for your system. If you're using `csh' on an old version of System V, you might need to type `sh ./configure' instead to prevent `csh' from trying to execute `configure' itself. Running `configure' takes awhile. While running, it prints some messages telling which features it is checking for. 2. Type `make' to compile the package. 3. Optionally, type `make check' to run any self-tests that come with the package. 4. Type `make install' to install the programs and any data files and documentation. 5. You can remove the program binaries and object files from the source code directory by typing `make clean'. To also remove the files that `configure' created (so you can compile the package for a different kind of computer), type `make distclean'. There is also a `make maintainer-clean' target, but that is intended mainly for the package's developers. If you use it, you may have to get all sorts of other programs in order to regenerate files that came with the distribution. Compilers and Options ===================== Some systems require unusual options for compilation or linking that the `configure' script does not know about. You can give `configure' initial values for variables by setting them in the environment. Using a Bourne-compatible shell, you can do that on the command line like this: CC=c89 CFLAGS=-O2 LIBS=-lposix ./configure Or on systems that have the `env' program, you can do it like this: env CPPFLAGS=-I/usr/local/include LDFLAGS=-s ./configure Compiling For Multiple Architectures ==================================== You can compile the package for more than one kind of computer at the same time, by placing the object files for each architecture in their own directory. To do this, you must use a version of `make' that supports the `VPATH' variable, such as GNU `make'. `cd' to the directory where you want the object files and executables to go and run the `configure' script. `configure' automatically checks for the source code in the directory that `configure' is in and in `..'. If you have to use a `make' that does not supports the `VPATH' variable, you have to compile the package for one architecture at a time in the source code directory. After you have installed the package for one architecture, use `make distclean' before reconfiguring for another architecture. Installation Names ================== By default, `make install' will install the package's files in `/usr/local/bin', `/usr/local/man', etc. You can specify an installation prefix other than `/usr/local' by giving `configure' the option `--prefix=PATH'. You can specify separate installation prefixes for architecture-specific files and architecture-independent files. If you give `configure' the option `--exec-prefix=PATH', the package will use PATH as the prefix for installing programs and libraries. Documentation and other data files will still use the regular prefix. In addition, if you use an unusual directory layout you can give options like `--bindir=PATH' to specify different values for particular kinds of files. Run `configure --help' for a list of the directories you can set and what kinds of files go in them. If the package supports it, you can cause programs to be installed with an extra prefix or suffix on their names by giving `configure' the option `--program-prefix=PREFIX' or `--program-suffix=SUFFIX'. Optional Features ================= Some packages pay attention to `--enable-FEATURE' options to `configure', where FEATURE indicates an optional part of the package. They may also pay attention to `--with-PACKAGE' options, where PACKAGE is something like `gnu-as' or `x' (for the X Window System). The `README' should mention any `--enable-' and `--with-' options that the package recognizes. For packages that use the X Window System, `configure' can usually find the X include and library files automatically, but if it doesn't, you can use the `configure' options `--x-includes=DIR' and `--x-libraries=DIR' to specify their locations. Specifying the System Type ========================== There may be some features `configure' can not figure out automatically, but needs to determine by the type of host the package will run on. Usually `configure' can figure that out, but if it prints a message saying it can not guess the host type, give it the `--host=TYPE' option. TYPE can either be a short name for the system type, such as `sun4', or a canonical name with three fields: CPU-COMPANY-SYSTEM See the file `config.sub' for the possible values of each field. If `config.sub' isn't included in this package, then this package doesn't need to know the host type. If you are building compiler tools for cross-compiling, you can also use the `--target=TYPE' option to select the type of system they will produce code for and the `--build=TYPE' option to select the type of system on which you are compiling the package. Sharing Defaults ================ If you want to set default values for `configure' scripts to share, you can create a site shell script called `config.site' that gives default values for variables like `CC', `cache_file', and `prefix'. `configure' looks for `PREFIX/share/config.site' if it exists, then `PREFIX/etc/config.site' if it exists. Or, you can set the `CONFIG_SITE' environment variable to the location of the site script. A warning: not all `configure' scripts look for a site script. Operation Controls ================== `configure' recognizes the following options to control how it operates. `--cache-file=FILE' Use and save the results of the tests in FILE instead of `./config.cache'. Set FILE to `/dev/null' to disable caching, for debugging `configure'. `--help' Print a summary of the options to `configure', and exit. `--quiet' `--silent' `-q' Do not print messages saying which checks are being made. To suppress all normal output, redirect it to `/dev/null' (any error messages will still be shown). `--srcdir=DIR' Look for the package's source code in directory DIR. Usually `configure' can determine that directory automatically. `--version' Print the version of Autoconf used to generate the `configure' script, and exit. `configure' also accepts some other, not widely useful, options. rapache-1.2.8/LICENSE0000644000175100017510000002613612706745114013477 0ustar ondrejondrej Apache License Version 2.0, January 2004 http://www.apache.org/licenses/ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION 1. Definitions. "License" shall mean the terms and conditions for use, reproduction, and distribution as defined by Sections 1 through 9 of this document. "Licensor" shall mean the copyright owner or entity authorized by the copyright owner that is granting the License. "Legal Entity" shall mean the union of the acting entity and all other entities that control, are controlled by, or are under common control with that entity. For the purposes of this definition, "control" means (i) the power, direct or indirect, to cause the direction or management of such entity, whether by contract or otherwise, or (ii) ownership of fifty percent (50%) or more of the outstanding shares, or (iii) beneficial ownership of such entity. "You" (or "Your") shall mean an individual or Legal Entity exercising permissions granted by this License. "Source" form shall mean the preferred form for making modifications, including but not limited to software source code, documentation source, and configuration files. "Object" form shall mean any form resulting from mechanical transformation or translation of a Source form, including but not limited to compiled object code, generated documentation, and conversions to other media types. "Work" shall mean the work of authorship, whether in Source or Object form, made available under the License, as indicated by a copyright notice that is included in or attached to the work (an example is provided in the Appendix below). "Derivative Works" shall mean any work, whether in Source or Object form, that is based on (or derived from) the Work and for which the editorial revisions, annotations, elaborations, or other modifications represent, as a whole, an original work of authorship. For the purposes of this License, Derivative Works shall not include works that remain separable from, or merely link (or bind by name) to the interfaces of, the Work and Derivative Works thereof. "Contribution" shall mean any work of authorship, including the original version of the Work and any modifications or additions to that Work or Derivative Works thereof, that is intentionally submitted to Licensor for inclusion in the Work by the copyright owner or by an individual or Legal Entity authorized to submit on behalf of the copyright owner. For the purposes of this definition, "submitted" means any form of electronic, verbal, or written communication sent to the Licensor or its representatives, including but not limited to communication on electronic mailing lists, source code control systems, and issue tracking systems that are managed by, or on behalf of, the Licensor for the purpose of discussing and improving the Work, but excluding communication that is conspicuously marked or otherwise designated in writing by the copyright owner as "Not a Contribution." "Contributor" shall mean Licensor and any individual or Legal Entity on behalf of whom a Contribution has been received by Licensor and subsequently incorporated within the Work. 2. Grant of Copyright License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable copyright license to reproduce, prepare Derivative Works of, publicly display, publicly perform, sublicense, and distribute the Work and such Derivative Works in Source or Object form. 3. Grant of Patent License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable (except as stated in this section) patent license to make, have made, use, offer to sell, sell, import, and otherwise transfer the Work, where such license applies only to those patent claims licensable by such Contributor that are necessarily infringed by their Contribution(s) alone or by combination of their Contribution(s) with the Work to which such Contribution(s) was submitted. If You institute patent litigation against any entity (including a cross-claim or counterclaim in a lawsuit) alleging that the Work or a Contribution incorporated within the Work constitutes direct or contributory patent infringement, then any patent licenses granted to You under this License for that Work shall terminate as of the date such litigation is filed. 4. Redistribution. You may reproduce and distribute copies of the Work or Derivative Works thereof in any medium, with or without modifications, and in Source or Object form, provided that You meet the following conditions: (a) You must give any other recipients of the Work or Derivative Works a copy of this License; and (b) You must cause any modified files to carry prominent notices stating that You changed the files; and (c) You must retain, in the Source form of any Derivative Works that You distribute, all copyright, patent, trademark, and attribution notices from the Source form of the Work, excluding those notices that do not pertain to any part of the Derivative Works; and (d) If the Work includes a "NOTICE" text file as part of its distribution, then any Derivative Works that You distribute must include a readable copy of the attribution notices contained within such NOTICE file, excluding those notices that do not pertain to any part of the Derivative Works, in at least one of the following places: within a NOTICE text file distributed as part of the Derivative Works; within the Source form or documentation, if provided along with the Derivative Works; or, within a display generated by the Derivative Works, if and wherever such third-party notices normally appear. The contents of the NOTICE file are for informational purposes only and do not modify the License. You may add Your own attribution notices within Derivative Works that You distribute, alongside or as an addendum to the NOTICE text from the Work, provided that such additional attribution notices cannot be construed as modifying the License. You may add Your own copyright statement to Your modifications and may provide additional or different license terms and conditions for use, reproduction, or distribution of Your modifications, or for any such Derivative Works as a whole, provided Your use, reproduction, and distribution of the Work otherwise complies with the conditions stated in this License. 5. Submission of Contributions. Unless You explicitly state otherwise, any Contribution intentionally submitted for inclusion in the Work by You to the Licensor shall be under the terms and conditions of this License, without any additional terms or conditions. Notwithstanding the above, nothing herein shall supersede or modify the terms of any separate license agreement you may have executed with Licensor regarding such Contributions. 6. Trademarks. This License does not grant permission to use the trade names, trademarks, service marks, or product names of the Licensor, except as required for reasonable and customary use in describing the origin of the Work and reproducing the content of the NOTICE file. 7. Disclaimer of Warranty. Unless required by applicable law or agreed to in writing, Licensor provides the Work (and each Contributor provides its Contributions) on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied, including, without limitation, any warranties or conditions of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A PARTICULAR PURPOSE. You are solely responsible for determining the appropriateness of using or redistributing the Work and assume any risks associated with Your exercise of permissions under this License. 8. Limitation of Liability. In no event and under no legal theory, whether in tort (including negligence), contract, or otherwise, unless required by applicable law (such as deliberate and grossly negligent acts) or agreed to in writing, shall any Contributor be liable to You for damages, including any direct, indirect, special, incidental, or consequential damages of any character arising as a result of this License or out of the use or inability to use the Work (including but not limited to damages for loss of goodwill, work stoppage, computer failure or malfunction, or any and all other commercial damages or losses), even if such Contributor has been advised of the possibility of such damages. 9. Accepting Warranty or Additional Liability. While redistributing the Work or Derivative Works thereof, You may choose to offer, and charge a fee for, acceptance of support, warranty, indemnity, or other liability obligations and/or rights consistent with this License. However, in accepting such obligations, You may act only on Your own behalf and on Your sole responsibility, not on behalf of any other Contributor, and only if You agree to indemnify, defend, and hold each Contributor harmless for any liability incurred by, or claims asserted against, such Contributor by reason of your accepting any such warranty or additional liability. END OF TERMS AND CONDITIONS APPENDIX: How to apply the Apache License to your work. To apply the Apache License to your work, attach the following boilerplate notice, with the fields enclosed by brackets "[]" replaced with your own identifying information. (Don't include the brackets!) The text should be enclosed in the appropriate comment syntax for the file format. We also recommend that a file or class name and description of purpose be included on the same "printed page" as the copyright notice for easier identification within third-party archives. Copyright [yyyy] [name of copyright owner] Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. rapache-1.2.8/Makefile.am0000644000175100017510000000423312706745114014520 0ustar ondrejondrej# DARWIN has to be different than everyone else # and define their autoconf $shlibpath_var to be DYLD_LIBRARY_PATH SHLIBPATH_VAR=@SHLIBPATH_VAR@ ACLOCAL_AMFLAGS = -I m4 APXS=@APXS@ HTTPD=@HTTPD@ DOCROOT=@DOCROOT@ APREQ=@APREQ@ APREQ_COMPILE=@APREQ_COMPILE@ APREQ_INSTALL=@APREQ_INSTALL@ APREQ_CLEAN=@APREQ_CLEAN@ APREQ_LIB_DIR=@APREQ_LIB_DIR@ APREQ_INCLUDES=@APREQ_INCLUDES@ APREQ_LINKLD=@APREQ_LINKLD@ RPROG=@RPROG@ RPROGBATCH=R_DEFAULT_PACKAGES=NULL @RPROG@ --vanilla --no-readline --slave -f R_HOME = `$(RPROG) RHOME` R_LD_LIBRARY_PATH = $(R_HOME)/lib RINCLUDES=@RINCLUDES@ RLINKLD=@RLINKLD@ INCLUDES = $(RINCLUDES) $(APREQ_INCLUDES) LDFLAGS = $(RLINKLD) $(APREQ_LINKLD) LD_LIBRARY_PATH=$(R_LD_LIBRARY_PATH):$(APREQ_LIB_DIR) RPATH=@RPATH@ all: mod_R.so $(DOCROOT)/httpd.conf mod_R.so: .apreq-config mod_R.c mod_R.h @echo @echo Compiling mod_R @echo $(APXS) $(INCLUDES) -c mod_R.c $(RPATH) $(LDFLAGS) .apreq-config: @echo @echo Configuring libapreq2 @echo $(APREQ_COMPILE) touch .apreq-config install: all $(APXS) -i -n R mod_R.la $(APREQ_INSTALL) $(DOCROOT)/httpd.conf: $(DOCROOT)/httpd.conf.in $(RPROGBATCH) tools/config_http.R --args $(APXS) $(HTTPD) itest: all @echo @echo Point your browser to http://localhost:8181/index.html @echo $(SHLIBPATH_VAR)=$(LD_LIBRARY_PATH) R_HOME=$(R_HOME) $(HTTPD) -X -f $(DOCROOT)/httpd.conf test: all $(DOCROOT)/httpd.conf stop: all $(SHLIBPATH_VAR)=$(LD_LIBRARY_PATH) R_HOME=$(R_HOME) $(HTTPD) -X -f $(DOCROOT)/httpd.conf -k stop valgrind: all $(SHLIBPATH_VAR)=$(LD_LIBRARY_PATH) R_HOME=$(R_HOME) valgrind $(HTTPD) -X -f $(DOCROOT)/httpd.conf debug: all @echo @echo Copy/paste the following line to gdb @echo @echo run -X -f $(DOCROOT)/httpd.conf @echo $(SHLIBPATH_VAR)=$(LD_LIBRARY_PATH) R_HOME=$(R_HOME) gdb $(HTTPD) clean: rm -rf $(OBJS) core mod_R.o mod_R.so *~ .libs *.o *.slo *.lo *.la .apreq-config $(APREQ_CLEAN) distclean: clean rm -rf mod_R.h Makefile .depend .install libtool config.log config.status test/httpd.conf test/access_log test/error_log test/httpd.pid test/accept.lock* aclocal.m4 autom4te.cache libapreq2/library/t/Makefile libapreq2/config.nice libapreq2/module/apache/Makefile $(APREQ_CLEAN) rapache-1.2.8/Makefile.in0000644000175100017510000002503312706745114014532 0ustar ondrejondrej# Makefile.in generated by automake 1.11.1 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 = . DIST_COMMON = INSTALL README ChangeLog $(srcdir)/Makefile.in \ $(srcdir)/Makefile.am $(top_srcdir)/configure \ $(am__configure_deps) $(srcdir)/mod_R.h.in ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/m4/ax_with_apxs.m4 \ $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \ $(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \ $(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/configure.in am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) am__CONFIG_DISTCLEAN_FILES = config.status config.cache config.log \ configure.lineno config.status.lineno mkinstalldirs = $(install_sh) -d CONFIG_CLEAN_FILES = mod_R.h CONFIG_CLEAN_VPATH_FILES = depcomp = am__depfiles_maybe = SOURCES = ACLOCAL = @ACLOCAL@ AMTAR = @AMTAR@ APREQ = @APREQ@ APREQCONFIG = @APREQCONFIG@ APREQ_CLEAN = @APREQ_CLEAN@ APREQ_COMPILE = @APREQ_COMPILE@ APREQ_INCLUDES = @APREQ_INCLUDES@ APREQ_INSTALL = @APREQ_INSTALL@ APREQ_LIB_DIR = @APREQ_LIB_DIR@ APREQ_LINKLD = @APREQ_LINKLD@ APXS = @APXS@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ AWK = @AWK@ CC = @CC@ CFLAGS = @CFLAGS@ CPP = @CPP@ CPPFLAGS = @CPPFLAGS@ CYGPATH_W = @CYGPATH_W@ DEFS = @DEFS@ DOCROOT = @DOCROOT@ DSYMUTIL = @DSYMUTIL@ DUMPBIN = @DUMPBIN@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ FGREP = @FGREP@ GREP = @GREP@ HTTPD = @HTTPD@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ LD = @LD@ LDFLAGS = $(RLINKLD) $(APREQ_LINKLD) LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ LIBTOOL = @LIBTOOL@ LIPO = @LIPO@ LN_S = @LN_S@ LTLIBOBJS = @LTLIBOBJS@ MAINT = @MAINT@ MAKEINFO = @MAKEINFO@ 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@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ RANLIB = @RANLIB@ RHOME = @RHOME@ RINCLUDES = @RINCLUDES@ RLINKLD = @RLINKLD@ RPATH = @RPATH@ RPROG = @RPROG@ RPROGRAM = @RPROGRAM@ SED = @SED@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ # DARWIN has to be different than everyone else # and define their autoconf $shlibpath_var to be DYLD_LIBRARY_PATH SHLIBPATH_VAR = @SHLIBPATH_VAR@ STRIP = @STRIP@ UNAME = @UNAME@ VERSION = @VERSION@ 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_DUMPBIN = @ac_ct_DUMPBIN@ am__leading_dot = @am__leading_dot@ 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@ 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@ lt_ECHO = @lt_ECHO@ 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@ ACLOCAL_AMFLAGS = -I m4 RPROGBATCH = R_DEFAULT_PACKAGES=NULL @RPROG@ --vanilla --no-readline --slave -f R_HOME = `$(RPROG) RHOME` R_LD_LIBRARY_PATH = $(R_HOME)/lib INCLUDES = $(RINCLUDES) $(APREQ_INCLUDES) LD_LIBRARY_PATH = $(R_LD_LIBRARY_PATH):$(APREQ_LIB_DIR) all: all-am .SUFFIXES: am--refresh: @: $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ echo ' cd $(srcdir) && $(AUTOMAKE) --foreign --ignore-deps'; \ $(am__cd) $(srcdir) && $(AUTOMAKE) --foreign --ignore-deps \ && exit 0; \ exit 1;; \ esac; \ done; \ echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign --ignore-deps Makefile'; \ $(am__cd) $(top_srcdir) && \ $(AUTOMAKE) --foreign --ignore-deps Makefile .PRECIOUS: Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @case '$?' in \ *config.status*) \ echo ' $(SHELL) ./config.status'; \ $(SHELL) ./config.status;; \ *) \ echo ' cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe)'; \ cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe);; \ esac; $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) $(SHELL) ./config.status --recheck $(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps) $(am__cd) $(srcdir) && $(AUTOCONF) $(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps) $(am__cd) $(srcdir) && $(ACLOCAL) $(ACLOCAL_AMFLAGS) $(am__aclocal_m4_deps): mod_R.h: $(top_builddir)/config.status $(srcdir)/mod_R.h.in cd $(top_builddir) && $(SHELL) ./config.status $@ mostlyclean-libtool: -rm -f *.lo clean-libtool: -rm -rf .libs _libs distclean-libtool: -rm -f libtool config.lt tags: TAGS TAGS: ctags: CTAGS CTAGS: check-am: all-am check: check-am all-am: Makefile installdirs: install-exec: install-exec-am install-data: install-data-am uninstall: uninstall-am install-am: all-am @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am installcheck: installcheck-am install-strip: $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ `test -z '$(STRIP)' || \ echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install mostlyclean-generic: clean-generic: 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-am: clean-generic clean-libtool mostlyclean-am distclean-am: clean-am distclean-generic distclean-libtool dvi: dvi-am dvi-am: html: html-am html-am: info: info-am info-am: install-data-am: 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 $(am__CONFIG_DISTCLEAN_FILES) -rm -rf $(top_srcdir)/autom4te.cache -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: .MAKE: install-am install-strip .PHONY: all all-am am--refresh check check-am clean clean-generic \ clean-libtool distclean distclean-generic distclean-libtool \ 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 maintainer-clean \ maintainer-clean-generic mostlyclean mostlyclean-generic \ mostlyclean-libtool pdf pdf-am ps ps-am uninstall uninstall-am all: mod_R.so $(DOCROOT)/httpd.conf mod_R.so: .apreq-config mod_R.c mod_R.h @echo @echo Compiling mod_R @echo $(APXS) $(INCLUDES) -c mod_R.c $(RPATH) $(LDFLAGS) .apreq-config: @echo @echo Configuring libapreq2 @echo $(APREQ_COMPILE) touch .apreq-config install: all $(APXS) -i -n R mod_R.la $(APREQ_INSTALL) $(DOCROOT)/httpd.conf: $(DOCROOT)/httpd.conf.in $(RPROGBATCH) tools/config_http.R --args $(APXS) $(HTTPD) itest: all @echo @echo Point your browser to http://localhost:8181/index.html @echo $(SHLIBPATH_VAR)=$(LD_LIBRARY_PATH) R_HOME=$(R_HOME) $(HTTPD) -X -f $(DOCROOT)/httpd.conf test: all $(DOCROOT)/httpd.conf stop: all $(SHLIBPATH_VAR)=$(LD_LIBRARY_PATH) R_HOME=$(R_HOME) $(HTTPD) -X -f $(DOCROOT)/httpd.conf -k stop valgrind: all $(SHLIBPATH_VAR)=$(LD_LIBRARY_PATH) R_HOME=$(R_HOME) valgrind $(HTTPD) -X -f $(DOCROOT)/httpd.conf debug: all @echo @echo Copy/paste the following line to gdb @echo @echo run -X -f $(DOCROOT)/httpd.conf @echo $(SHLIBPATH_VAR)=$(LD_LIBRARY_PATH) R_HOME=$(R_HOME) gdb $(HTTPD) clean: rm -rf $(OBJS) core mod_R.o mod_R.so *~ .libs *.o *.slo *.lo *.la .apreq-config $(APREQ_CLEAN) distclean: clean rm -rf mod_R.h Makefile .depend .install libtool config.log config.status test/httpd.conf test/access_log test/error_log test/httpd.pid test/accept.lock* aclocal.m4 autom4te.cache libapreq2/library/t/Makefile libapreq2/config.nice libapreq2/module/apache/Makefile $(APREQ_CLEAN) # 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: rapache-1.2.8/NOTICE0000644000175100017510000000014512706745114013366 0ustar ondrejondrejThis product includes software developed by The Apache Software Foundation (http://www.apache.org/). rapache-1.2.8/README.md0000644000175100017510000000602412706745114013743 0ustar ondrejondrej The Rapache Project What is it? ----------- Rapache is a project dedicated to embedding the R interpreter inside the Apache 2.0 (and beyond) web server. It's composed of two parts: mod_R: the Apache 2.0 module that implements the glue to load the R interpreter. libapreq 2.0.4: an Apache sponsored project for parsing request input. If you don't want to compile and install this version, then you can specify which libapreq2 library to use during configuration. The Latest Version ------------------ Details of the latest version can be found at the R/Apache project page: http://rapache.net/ Prerequisites ------------- This release has been tested under Debian Linux with Apache 2.2.4, R 2.5.1, and libapreq 2.0.4. Apache2 _MUST_ be compiled with the prefork MPM to compile mod_R. Also, R must have been compiled with the --enable-R-shlib configure flag. Installation ------------ The following is the preferred way to compile and install rapache: $ ./configure $ make $ make install configure will try to find the needed programs to compile rapache, but if it fails to locate them or if you have installed the prerequisites in non-standard places, then you can specify their locations with the following flags: --with-apache2-apxs=/path/to/apxs --with-R=/path/to/R --with-apreq2-config=/path/to/apreq2-config Configuration ------------- Add something similar to this to the apache config file: LoadModule R_module /path/to/mod_R.so # Output R errors and warnings to the browser ROutputErrors # Displays information about rapache and R SetHandler r-info # Process all files under /path/to/brew/scripts with # package brew and function brew SetHandler r-script RHandler brew::brew # This url will run the file /path/to/r/script.R SetHandler r-handler RFileHandler /path/to/r/script.R Also, libR.so _MUST_ be found in the shared library path as it is linked to by mod_R, RApache and the rest of the packages containing shared libraries. You can either set LD_LIBRARY_PATH like this: $ export LD_LIBRARY_PATH=`/path/to/R RHOME`/lib or add that path to /etc/ld.so.conf and then run ldconfig. NOTE: the latest apache2 debian packages cause the web server to run in a very reduced environment, thus one is unable to set LD_LIBRARY_PATH before calling /etc/init.d/apache2. One option is to actually edit that file and add the LD_LIBRARY_PATH explicitly. Another is to use the apache2ctl scripts which are also bundled with the debian packages. Or you can add it to /etc/ld.so.conf. Documentation ------------- Forthcoming. See http://rapache.net/manual.html for ongoing updates. Licensing --------- The R/Apache source code is licensed under the Apache License Version 2.0. Please see the file called LICENSE. rapache-1.2.8/configure0000755000175100017510000137134012706745114014402 0ustar ondrejondrej#! /bin/sh # Guess values for system-dependent variables and create Makefiles. # Generated by GNU Autoconf 2.63 for mod_R 1.0. # # Report bugs to . # # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, # 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. # This configure script is free software; the Free Software Foundation # gives unlimited permission to copy, distribute and modify it. ## --------------------- ## ## M4sh Initialization. ## ## --------------------- ## # 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 fi # 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 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 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 # Support unset when possible. if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then as_unset=unset else as_unset=false fi # 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" # 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 ;; 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 # 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='+ ' # NLS nuisances. LC_ALL=C export LC_ALL LANGUAGE=C export LANGUAGE # 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 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then as_basename=basename else as_basename=false fi # 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'` # CDPATH. $as_unset CDPATH if test "x$CONFIG_SHELL" = x; then if (eval ":") 2>/dev/null; then as_have_required=yes else as_have_required=no fi if test $as_have_required = yes && (eval ": (as_func_return () { (exit \$1) } as_func_success () { as_func_return 0 } as_func_failure () { as_func_return 1 } as_func_ret_success () { return 0 } as_func_ret_failure () { return 1 } exitcode=0 if as_func_success; then : else exitcode=1 echo as_func_success failed. fi if as_func_failure; then exitcode=1 echo as_func_failure succeeded. fi if as_func_ret_success; then : else exitcode=1 echo as_func_ret_success failed. fi if as_func_ret_failure; then exitcode=1 echo as_func_ret_failure succeeded. fi if ( set x; as_func_ret_success y && test x = \"\$1\" ); then : else exitcode=1 echo positional parameters were not saved. fi test \$exitcode = 0) || { (exit 1); exit 1; } ( 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\") || { (exit 1); exit 1; } ") 2> /dev/null; then : else as_candidate_shells= as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. case $as_dir in /*) for as_base in sh bash ksh sh5; do as_candidate_shells="$as_candidate_shells $as_dir/$as_base" done;; esac done IFS=$as_save_IFS for as_shell in $as_candidate_shells $SHELL; do # Try only shells that exist, to save several forks. if { test -f "$as_shell" || test -f "$as_shell.exe"; } && { ("$as_shell") 2> /dev/null <<\_ASEOF 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 fi : _ASEOF }; then CONFIG_SHELL=$as_shell as_have_required=yes if { "$as_shell" 2> /dev/null <<\_ASEOF 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 fi : (as_func_return () { (exit $1) } as_func_success () { as_func_return 0 } as_func_failure () { as_func_return 1 } as_func_ret_success () { return 0 } as_func_ret_failure () { return 1 } exitcode=0 if as_func_success; then : else exitcode=1 echo as_func_success failed. fi if as_func_failure; then exitcode=1 echo as_func_failure succeeded. fi if as_func_ret_success; then : else exitcode=1 echo as_func_ret_success failed. fi if as_func_ret_failure; then exitcode=1 echo as_func_ret_failure succeeded. fi if ( set x; as_func_ret_success y && test x = "$1" ); then : else exitcode=1 echo positional parameters were not saved. fi test $exitcode = 0) || { (exit 1); exit 1; } ( 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") || { (exit 1); exit 1; } _ASEOF }; then break fi fi done if test "x$CONFIG_SHELL" != x; then for as_var in BASH_ENV ENV do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var done export CONFIG_SHELL exec "$CONFIG_SHELL" "$as_myself" ${1+"$@"} fi if test $as_have_required = no; then echo This script requires a shell more modern than all the echo shells that I found on your system. Please install a echo modern shell, or manually run the script under such a echo shell if you do have one. { (exit 1); exit 1; } fi fi fi (eval "as_func_return () { (exit \$1) } as_func_success () { as_func_return 0 } as_func_failure () { as_func_return 1 } as_func_ret_success () { return 0 } as_func_ret_failure () { return 1 } exitcode=0 if as_func_success; then : else exitcode=1 echo as_func_success failed. fi if as_func_failure; then exitcode=1 echo as_func_failure succeeded. fi if as_func_ret_success; then : else exitcode=1 echo as_func_ret_success failed. fi if as_func_ret_failure; then exitcode=1 echo as_func_ret_failure succeeded. fi if ( set x; as_func_ret_success y && test x = \"\$1\" ); then : else exitcode=1 echo positional parameters were not saved. fi test \$exitcode = 0") || { echo No shell found that supports shell functions. echo Please tell bug-autoconf@gnu.org about your system, echo including any error possibly output before this message. echo This can help us improve future autoconf versions. echo Configuration will now proceed without shell functions. } 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" || { # 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; }; } # 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 } if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then as_dirname=dirname else as_dirname=false fi 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 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 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= 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'" # Check that we are running under the correct shell. SHELL=${CONFIG_SHELL-/bin/sh} 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 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 if test "X$1" = X--fallback-echo; then # used as fallback echo shift cat <<_LT_EOF $* _LT_EOF exit 0 fi # 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 "$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 "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 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` && 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 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" fi exec 7<&0 &1 # Name of the host. # hostname on some systems (SVR3.2, Linux) returns a bogus exit status, # so uname gets run too. ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q` # # Initializations. # ac_default_prefix=/usr/local ac_clean_files= ac_config_libobj_dir=. LIBOBJS= cross_compiling=no subdirs= MFLAGS= MAKEFLAGS= SHELL=${CONFIG_SHELL-/bin/sh} # Identity of this package. PACKAGE_NAME='mod_R' PACKAGE_TARNAME='mod_r' PACKAGE_VERSION='1.0' PACKAGE_STRING='mod_R 1.0' PACKAGE_BUGREPORT='jeff.horner@vanderbilt.edu' # Factoring default headers for most tests. ac_includes_default="\ #include #ifdef HAVE_SYS_TYPES_H # include #endif #ifdef HAVE_SYS_STAT_H # include #endif #ifdef STDC_HEADERS # include # include #else # ifdef HAVE_STDLIB_H # include # endif #endif #ifdef HAVE_STRING_H # if !defined STDC_HEADERS && defined HAVE_MEMORY_H # include # endif # include #endif #ifdef HAVE_STRINGS_H # include #endif #ifdef HAVE_INTTYPES_H # include #endif #ifdef HAVE_STDINT_H # include #endif #ifdef HAVE_UNISTD_H # include #endif" ac_subst_vars='am__EXEEXT_FALSE am__EXEEXT_TRUE LTLIBOBJS LIBOBJS SHLIBPATH_VAR RPATH DOCROOT APREQ_LINKLD APREQ_INCLUDES APREQ_LIB_DIR APREQ_CLEAN APREQ_INSTALL APREQ_COMPILE APREQ APREQCONFIG RLINKLD RINCLUDES RHOME RPROG RPROGRAM HTTPD APXS UNAME CPP OTOOL64 OTOOL LIPO NMEDIT DSYMUTIL lt_ECHO RANLIB AR OBJDUMP LN_S NM ac_ct_DUMPBIN DUMPBIN LD FGREP EGREP GREP SED OBJEXT EXEEXT ac_ct_CC CPPFLAGS LDFLAGS CFLAGS CC host_os host_vendor host_cpu host build_os build_vendor build_cpu build LIBTOOL MAINT MAINTAINER_MODE_FALSE MAINTAINER_MODE_TRUE am__untar am__tar AMTAR am__leading_dot SET_MAKE AWK mkdir_p MKDIR_P INSTALL_STRIP_PROGRAM STRIP install_sh MAKEINFO AUTOHEADER AUTOMAKE AUTOCONF ACLOCAL VERSION PACKAGE CYGPATH_W am__isrc INSTALL_DATA INSTALL_SCRIPT INSTALL_PROGRAM target_alias host_alias build_alias LIBS ECHO_T ECHO_N ECHO_C DEFS mandir localedir libdir psdir pdfdir dvidir htmldir infodir docdir oldincludedir includedir localstatedir sharedstatedir sysconfdir datadir datarootdir libexecdir sbindir bindir program_transform_name prefix exec_prefix PACKAGE_BUGREPORT PACKAGE_STRING PACKAGE_VERSION PACKAGE_TARNAME PACKAGE_NAME PATH_SEPARATOR SHELL' ac_subst_files='' ac_user_opts=' enable_option_checking enable_maintainer_mode enable_shared enable_static with_pic enable_fast_install with_gnu_ld enable_libtool_lock with_apxs with_R with_apreq2_config ' ac_precious_vars='build_alias host_alias target_alias CC CFLAGS LDFLAGS LIBS CPPFLAGS CPP APXS' # Initialize some variables set by options. ac_init_help= ac_init_version=false ac_unrecognized_opts= ac_unrecognized_sep= # The variables have the same names as the options, with # dashes changed to underlines. cache_file=/dev/null exec_prefix=NONE no_create= no_recursion= prefix=NONE program_prefix=NONE program_suffix=NONE program_transform_name=s,x,x, silent= site= srcdir= verbose= x_includes=NONE x_libraries=NONE # Installation directory options. # These are left unexpanded so users can "make install exec_prefix=/foo" # and all the variables that are supposed to be based on exec_prefix # by default will actually change. # Use braces instead of parens because sh, perl, etc. also accept them. # (The list follows the same order as the GNU Coding Standards.) bindir='${exec_prefix}/bin' sbindir='${exec_prefix}/sbin' libexecdir='${exec_prefix}/libexec' datarootdir='${prefix}/share' datadir='${datarootdir}' sysconfdir='${prefix}/etc' sharedstatedir='${prefix}/com' localstatedir='${prefix}/var' includedir='${prefix}/include' oldincludedir='/usr/include' docdir='${datarootdir}/doc/${PACKAGE_TARNAME}' infodir='${datarootdir}/info' htmldir='${docdir}' dvidir='${docdir}' pdfdir='${docdir}' psdir='${docdir}' libdir='${exec_prefix}/lib' localedir='${datarootdir}/locale' mandir='${datarootdir}/man' ac_prev= ac_dashdash= for ac_option do # If the previous option needs an argument, assign it. if test -n "$ac_prev"; then eval $ac_prev=\$ac_option ac_prev= continue fi case $ac_option in *=*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; *) ac_optarg=yes ;; esac # Accept the important Cygnus configure options, so we can diagnose typos. case $ac_dashdash$ac_option in --) ac_dashdash=yes ;; -bindir | --bindir | --bindi | --bind | --bin | --bi) ac_prev=bindir ;; -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) bindir=$ac_optarg ;; -build | --build | --buil | --bui | --bu) ac_prev=build_alias ;; -build=* | --build=* | --buil=* | --bui=* | --bu=*) build_alias=$ac_optarg ;; -cache-file | --cache-file | --cache-fil | --cache-fi \ | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) ac_prev=cache_file ;; -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) cache_file=$ac_optarg ;; --config-cache | -C) cache_file=config.cache ;; -datadir | --datadir | --datadi | --datad) ac_prev=datadir ;; -datadir=* | --datadir=* | --datadi=* | --datad=*) datadir=$ac_optarg ;; -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \ | --dataroo | --dataro | --datar) ac_prev=datarootdir ;; -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \ | --dataroot=* | --dataroo=* | --dataro=* | --datar=*) datarootdir=$ac_optarg ;; -disable-* | --disable-*) ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'` # Reject names that are not valid shell variable names. expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && { $as_echo "$as_me: error: invalid feature name: $ac_useropt" >&2 { (exit 1); exit 1; }; } ac_useropt_orig=$ac_useropt ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` case $ac_user_opts in *" "enable_$ac_useropt" "*) ;; *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig" ac_unrecognized_sep=', ';; esac eval enable_$ac_useropt=no ;; -docdir | --docdir | --docdi | --doc | --do) ac_prev=docdir ;; -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*) docdir=$ac_optarg ;; -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv) ac_prev=dvidir ;; -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*) dvidir=$ac_optarg ;; -enable-* | --enable-*) ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` # Reject names that are not valid shell variable names. expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && { $as_echo "$as_me: error: invalid feature name: $ac_useropt" >&2 { (exit 1); exit 1; }; } ac_useropt_orig=$ac_useropt ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` case $ac_user_opts in *" "enable_$ac_useropt" "*) ;; *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig" ac_unrecognized_sep=', ';; esac eval enable_$ac_useropt=\$ac_optarg ;; -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ | --exec | --exe | --ex) ac_prev=exec_prefix ;; -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ | --exec=* | --exe=* | --ex=*) exec_prefix=$ac_optarg ;; -gas | --gas | --ga | --g) # Obsolete; use --with-gas. with_gas=yes ;; -help | --help | --hel | --he | -h) ac_init_help=long ;; -help=r* | --help=r* | --hel=r* | --he=r* | -hr*) ac_init_help=recursive ;; -help=s* | --help=s* | --hel=s* | --he=s* | -hs*) ac_init_help=short ;; -host | --host | --hos | --ho) ac_prev=host_alias ;; -host=* | --host=* | --hos=* | --ho=*) host_alias=$ac_optarg ;; -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht) ac_prev=htmldir ;; -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \ | --ht=*) htmldir=$ac_optarg ;; -includedir | --includedir | --includedi | --included | --include \ | --includ | --inclu | --incl | --inc) ac_prev=includedir ;; -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ | --includ=* | --inclu=* | --incl=* | --inc=*) includedir=$ac_optarg ;; -infodir | --infodir | --infodi | --infod | --info | --inf) ac_prev=infodir ;; -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) infodir=$ac_optarg ;; -libdir | --libdir | --libdi | --libd) ac_prev=libdir ;; -libdir=* | --libdir=* | --libdi=* | --libd=*) libdir=$ac_optarg ;; -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ | --libexe | --libex | --libe) ac_prev=libexecdir ;; -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ | --libexe=* | --libex=* | --libe=*) libexecdir=$ac_optarg ;; -localedir | --localedir | --localedi | --localed | --locale) ac_prev=localedir ;; -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*) localedir=$ac_optarg ;; -localstatedir | --localstatedir | --localstatedi | --localstated \ | --localstate | --localstat | --localsta | --localst | --locals) ac_prev=localstatedir ;; -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*) localstatedir=$ac_optarg ;; -mandir | --mandir | --mandi | --mand | --man | --ma | --m) ac_prev=mandir ;; -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) mandir=$ac_optarg ;; -nfp | --nfp | --nf) # Obsolete; use --without-fp. with_fp=no ;; -no-create | --no-create | --no-creat | --no-crea | --no-cre \ | --no-cr | --no-c | -n) no_create=yes ;; -no-recursion | --no-recursion | --no-recursio | --no-recursi \ | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) no_recursion=yes ;; -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ | --oldin | --oldi | --old | --ol | --o) ac_prev=oldincludedir ;; -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) oldincludedir=$ac_optarg ;; -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) ac_prev=prefix ;; -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) prefix=$ac_optarg ;; -program-prefix | --program-prefix | --program-prefi | --program-pref \ | --program-pre | --program-pr | --program-p) ac_prev=program_prefix ;; -program-prefix=* | --program-prefix=* | --program-prefi=* \ | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) program_prefix=$ac_optarg ;; -program-suffix | --program-suffix | --program-suffi | --program-suff \ | --program-suf | --program-su | --program-s) ac_prev=program_suffix ;; -program-suffix=* | --program-suffix=* | --program-suffi=* \ | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) program_suffix=$ac_optarg ;; -program-transform-name | --program-transform-name \ | --program-transform-nam | --program-transform-na \ | --program-transform-n | --program-transform- \ | --program-transform | --program-transfor \ | --program-transfo | --program-transf \ | --program-trans | --program-tran \ | --progr-tra | --program-tr | --program-t) ac_prev=program_transform_name ;; -program-transform-name=* | --program-transform-name=* \ | --program-transform-nam=* | --program-transform-na=* \ | --program-transform-n=* | --program-transform-=* \ | --program-transform=* | --program-transfor=* \ | --program-transfo=* | --program-transf=* \ | --program-trans=* | --program-tran=* \ | --progr-tra=* | --program-tr=* | --program-t=*) program_transform_name=$ac_optarg ;; -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd) ac_prev=pdfdir ;; -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*) pdfdir=$ac_optarg ;; -psdir | --psdir | --psdi | --psd | --ps) ac_prev=psdir ;; -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*) psdir=$ac_optarg ;; -q | -quiet | --quiet | --quie | --qui | --qu | --q \ | -silent | --silent | --silen | --sile | --sil) silent=yes ;; -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) ac_prev=sbindir ;; -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ | --sbi=* | --sb=*) sbindir=$ac_optarg ;; -sharedstatedir | --sharedstatedir | --sharedstatedi \ | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ | --sharedst | --shareds | --shared | --share | --shar \ | --sha | --sh) ac_prev=sharedstatedir ;; -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ | --sha=* | --sh=*) sharedstatedir=$ac_optarg ;; -site | --site | --sit) ac_prev=site ;; -site=* | --site=* | --sit=*) site=$ac_optarg ;; -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) ac_prev=srcdir ;; -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) srcdir=$ac_optarg ;; -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ | --syscon | --sysco | --sysc | --sys | --sy) ac_prev=sysconfdir ;; -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) sysconfdir=$ac_optarg ;; -target | --target | --targe | --targ | --tar | --ta | --t) ac_prev=target_alias ;; -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) target_alias=$ac_optarg ;; -v | -verbose | --verbose | --verbos | --verbo | --verb) verbose=yes ;; -version | --version | --versio | --versi | --vers | -V) ac_init_version=: ;; -with-* | --with-*) ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` # Reject names that are not valid shell variable names. expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && { $as_echo "$as_me: error: invalid package name: $ac_useropt" >&2 { (exit 1); exit 1; }; } ac_useropt_orig=$ac_useropt ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` case $ac_user_opts in *" "with_$ac_useropt" "*) ;; *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig" ac_unrecognized_sep=', ';; esac eval with_$ac_useropt=\$ac_optarg ;; -without-* | --without-*) ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'` # Reject names that are not valid shell variable names. expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && { $as_echo "$as_me: error: invalid package name: $ac_useropt" >&2 { (exit 1); exit 1; }; } ac_useropt_orig=$ac_useropt ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` case $ac_user_opts in *" "with_$ac_useropt" "*) ;; *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig" ac_unrecognized_sep=', ';; esac eval with_$ac_useropt=no ;; --x) # Obsolete; use --with-x. with_x=yes ;; -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ | --x-incl | --x-inc | --x-in | --x-i) ac_prev=x_includes ;; -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) x_includes=$ac_optarg ;; -x-libraries | --x-libraries | --x-librarie | --x-librari \ | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) ac_prev=x_libraries ;; -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) x_libraries=$ac_optarg ;; -*) { $as_echo "$as_me: error: unrecognized option: $ac_option Try \`$0 --help' for more information." >&2 { (exit 1); exit 1; }; } ;; *=*) ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='` # Reject names that are not valid shell variable names. expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null && { $as_echo "$as_me: error: invalid variable name: $ac_envvar" >&2 { (exit 1); exit 1; }; } eval $ac_envvar=\$ac_optarg export $ac_envvar ;; *) # FIXME: should be removed in autoconf 3.0. $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2 : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option} ;; esac done if test -n "$ac_prev"; then ac_option=--`echo $ac_prev | sed 's/_/-/g'` { $as_echo "$as_me: error: missing argument to $ac_option" >&2 { (exit 1); exit 1; }; } fi if test -n "$ac_unrecognized_opts"; then case $enable_option_checking in no) ;; fatal) { $as_echo "$as_me: error: unrecognized options: $ac_unrecognized_opts" >&2 { (exit 1); exit 1; }; } ;; *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;; esac fi # Check all directory arguments for consistency. for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ datadir sysconfdir sharedstatedir localstatedir includedir \ oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ libdir localedir mandir do eval ac_val=\$$ac_var # Remove trailing slashes. case $ac_val in */ ) ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'` eval $ac_var=\$ac_val;; esac # Be sure to have absolute directory names. case $ac_val in [\\/$]* | ?:[\\/]* ) continue;; NONE | '' ) case $ac_var in *prefix ) continue;; esac;; esac { $as_echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2 { (exit 1); exit 1; }; } done # There might be people who depend on the old broken behavior: `$host' # used to hold the argument of --host etc. # FIXME: To remove some day. build=$build_alias host=$host_alias target=$target_alias # FIXME: To remove some day. if test "x$host_alias" != x; then if test "x$build_alias" = x; then cross_compiling=maybe $as_echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host. If a cross compiler is detected then cross compile mode will be used." >&2 elif test "x$build_alias" != "x$host_alias"; then cross_compiling=yes fi fi ac_tool_prefix= test -n "$host_alias" && ac_tool_prefix=$host_alias- test "$silent" = yes && exec 6>/dev/null ac_pwd=`pwd` && test -n "$ac_pwd" && ac_ls_di=`ls -di .` && ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` || { $as_echo "$as_me: error: working directory cannot be determined" >&2 { (exit 1); exit 1; }; } test "X$ac_ls_di" = "X$ac_pwd_ls_di" || { $as_echo "$as_me: error: pwd does not report name of working directory" >&2 { (exit 1); exit 1; }; } # Find the source files, if location was not specified. if test -z "$srcdir"; then ac_srcdir_defaulted=yes # Try the directory containing this script, then the parent directory. ac_confdir=`$as_dirname -- "$as_myself" || $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$as_myself" : 'X\(//\)[^/]' \| \ X"$as_myself" : 'X\(//\)$' \| \ X"$as_myself" : 'X\(/\)' \| . 2>/dev/null || $as_echo X"$as_myself" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` srcdir=$ac_confdir if test ! -r "$srcdir/$ac_unique_file"; then srcdir=.. fi else ac_srcdir_defaulted=no fi if test ! -r "$srcdir/$ac_unique_file"; then test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .." { $as_echo "$as_me: error: cannot find sources ($ac_unique_file) in $srcdir" >&2 { (exit 1); exit 1; }; } fi ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work" ac_abs_confdir=`( cd "$srcdir" && test -r "./$ac_unique_file" || { $as_echo "$as_me: error: $ac_msg" >&2 { (exit 1); exit 1; }; } pwd)` # When building in place, set srcdir=. if test "$ac_abs_confdir" = "$ac_pwd"; then srcdir=. fi # Remove unnecessary trailing slashes from srcdir. # Double slashes in file names in object file debugging info # mess up M-x gdb in Emacs. case $srcdir in */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;; esac for ac_var in $ac_precious_vars; do eval ac_env_${ac_var}_set=\${${ac_var}+set} eval ac_env_${ac_var}_value=\$${ac_var} eval ac_cv_env_${ac_var}_set=\${${ac_var}+set} eval ac_cv_env_${ac_var}_value=\$${ac_var} done # # Report the --help message. # 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 mod_R 1.0 to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... To assign environment variables (e.g., CC, CFLAGS...), specify them as VAR=VALUE. See below for descriptions of some of the useful variables. Defaults for the options are specified in brackets. Configuration: -h, --help display this help and exit --help=short display options specific to this package --help=recursive display the short help of all the included packages -V, --version display version information and exit -q, --quiet, --silent do not print \`checking...' messages --cache-file=FILE cache test results in FILE [disabled] -C, --config-cache alias for \`--cache-file=config.cache' -n, --no-create do not create output files --srcdir=DIR find the sources in DIR [configure dir or \`..'] Installation directories: --prefix=PREFIX install architecture-independent files in PREFIX [$ac_default_prefix] --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX [PREFIX] By default, \`make install' will install all the files in \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify an installation prefix other than \`$ac_default_prefix' using \`--prefix', for instance \`--prefix=\$HOME'. For better control, use the options below. Fine tuning of the installation directories: --bindir=DIR user executables [EPREFIX/bin] --sbindir=DIR system admin executables [EPREFIX/sbin] --libexecdir=DIR program executables [EPREFIX/libexec] --sysconfdir=DIR read-only single-machine data [PREFIX/etc] --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] --localstatedir=DIR modifiable single-machine data [PREFIX/var] --libdir=DIR object code libraries [EPREFIX/lib] --includedir=DIR C header files [PREFIX/include] --oldincludedir=DIR C header files for non-gcc [/usr/include] --datarootdir=DIR read-only arch.-independent data root [PREFIX/share] --datadir=DIR read-only architecture-independent data [DATAROOTDIR] --infodir=DIR info documentation [DATAROOTDIR/info] --localedir=DIR locale-dependent data [DATAROOTDIR/locale] --mandir=DIR man documentation [DATAROOTDIR/man] --docdir=DIR documentation root [DATAROOTDIR/doc/mod_r] --htmldir=DIR html documentation [DOCDIR] --dvidir=DIR dvi documentation [DOCDIR] --pdfdir=DIR pdf documentation [DOCDIR] --psdir=DIR ps documentation [DOCDIR] _ACEOF cat <<\_ACEOF Program names: --program-prefix=PREFIX prepend PREFIX to installed program names --program-suffix=SUFFIX append SUFFIX to installed program names --program-transform-name=PROGRAM run sed PROGRAM on installed program names System types: --build=BUILD configure for building on BUILD [guessed] --host=HOST cross-compile to build programs to run on HOST [BUILD] _ACEOF fi if test -n "$ac_init_help"; then case $ac_init_help in short | recursive ) echo "Configuration of mod_R 1.0:";; esac cat <<\_ACEOF Optional Features: --disable-option-checking ignore unrecognized --enable/--with options --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) --enable-FEATURE[=ARG] include FEATURE [ARG=yes] --enable-maintainer-mode enable make rules and dependencies not useful (and sometimes confusing) to the casual installer --enable-shared[=PKGS] build shared libraries [default=yes] --enable-static[=PKGS] build static libraries [default=yes] --enable-fast-install[=PKGS] optimize for fast installation [default=yes] --disable-libtool-lock avoid locking (might break parallel builds) Optional Packages: --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=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-apxs=APXS absolute path name of apxs executable --with-R=PATH Path to R (usually /usr/local/bin/R) --with-apreq2-config=PATH Path to apreq2-config Some influential environment variables: CC C compiler command CFLAGS C compiler flags LDFLAGS linker flags, e.g. -L if you have libraries in a nonstandard directory LIBS libraries to pass to the linker, e.g. -l CPPFLAGS C/C++/Objective C preprocessor flags, e.g. -I if you have headers in a nonstandard directory CPP C preprocessor APXS Use these variables to override the choices made by `configure' or to help it to find libraries and programs with nonstandard names/locations. Report bugs to . _ACEOF ac_status=$? fi if test "$ac_init_help" = "recursive"; then # If there are subdirs, report their specific --help. for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue test -d "$ac_dir" || { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } || continue ac_builddir=. 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 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 cd "$ac_dir" || { ac_status=$?; continue; } # Check for guested configure. if test -f "$ac_srcdir/configure.gnu"; then echo && $SHELL "$ac_srcdir/configure.gnu" --help=recursive elif test -f "$ac_srcdir/configure"; then echo && $SHELL "$ac_srcdir/configure" --help=recursive else $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2 fi || ac_status=$? cd "$ac_pwd" || { ac_status=$?; break; } done fi test -n "$ac_init_help" && exit $ac_status if $ac_init_version; then cat <<\_ACEOF mod_R configure 1.0 generated by GNU Autoconf 2.63 Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. This configure script is free software; the Free Software Foundation gives unlimited permission to copy, distribute and modify it. _ACEOF exit fi 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 mod_R $as_me 1.0, which was generated by GNU Autoconf 2.63. Invocation command line was $ $0 $@ _ACEOF exec 5>>config.log { cat <<_ASUNAME ## --------- ## ## Platform. ## ## --------- ## hostname = `(hostname || uname -n) 2>/dev/null | sed 1q` uname -m = `(uname -m) 2>/dev/null || echo unknown` uname -r = `(uname -r) 2>/dev/null || echo unknown` uname -s = `(uname -s) 2>/dev/null || echo unknown` uname -v = `(uname -v) 2>/dev/null || echo unknown` /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown` /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown` /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown` /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown` /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown` /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown` /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown` /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown` /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown` _ASUNAME as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. $as_echo "PATH: $as_dir" done IFS=$as_save_IFS } >&5 cat >&5 <<_ACEOF ## ----------- ## ## Core tests. ## ## ----------- ## _ACEOF # Keep a trace of the command line. # Strip out --no-create and --no-recursion so they do not pile up. # Strip out --silent because we don't want to record it for future runs. # Also quote any args containing shell meta-characters. # Make two passes to allow for proper duplicate-argument suppression. ac_configure_args= ac_configure_args0= ac_configure_args1= ac_must_keep_next=false for ac_pass in 1 2 do for ac_arg do case $ac_arg in -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;; -q | -quiet | --quiet | --quie | --qui | --qu | --q \ | -silent | --silent | --silen | --sile | --sil) continue ;; *\'*) ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; esac case $ac_pass in 1) ac_configure_args0="$ac_configure_args0 '$ac_arg'" ;; 2) ac_configure_args1="$ac_configure_args1 '$ac_arg'" if test $ac_must_keep_next = true; then ac_must_keep_next=false # Got value, back to normal. else case $ac_arg in *=* | --config-cache | -C | -disable-* | --disable-* \ | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \ | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \ | -with-* | --with-* | -without-* | --without-* | --x) case "$ac_configure_args0 " in "$ac_configure_args1"*" '$ac_arg' "* ) continue ;; esac ;; -* ) ac_must_keep_next=true ;; esac fi ac_configure_args="$ac_configure_args '$ac_arg'" ;; esac done done $as_unset ac_configure_args0 || test "${ac_configure_args0+set}" != set || { ac_configure_args0=; export ac_configure_args0; } $as_unset ac_configure_args1 || test "${ac_configure_args1+set}" != set || { ac_configure_args1=; export ac_configure_args1; } # When interrupted or exit'd, cleanup temporary files, and complete # config.log. We remove comments because anyway the quotes in there # would cause problems or look ugly. # WARNING: Use '\'' to represent an apostrophe within the trap. # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug. trap 'exit_status=$? # Save into config.log some information that might help in debugging. { echo cat <<\_ASBOX ## ---------------- ## ## Cache variables. ## ## ---------------- ## _ASBOX echo # The following way of writing the cache mishandles newlines in values, ( 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 (set) 2>&1 | case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #( *${as_nl}ac_space=\ *) sed -n \ "s/'\''/'\''\\\\'\'''\''/g; s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p" ;; #( *) sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" ;; esac | sort ) echo cat <<\_ASBOX ## ----------------- ## ## Output variables. ## ## ----------------- ## _ASBOX echo for ac_var in $ac_subst_vars do eval ac_val=\$$ac_var case $ac_val in *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; esac $as_echo "$ac_var='\''$ac_val'\''" done | sort echo if test -n "$ac_subst_files"; then cat <<\_ASBOX ## ------------------- ## ## File substitutions. ## ## ------------------- ## _ASBOX echo for ac_var in $ac_subst_files do eval ac_val=\$$ac_var case $ac_val in *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; esac $as_echo "$ac_var='\''$ac_val'\''" done | sort echo fi if test -s confdefs.h; then cat <<\_ASBOX ## ----------- ## ## confdefs.h. ## ## ----------- ## _ASBOX echo cat confdefs.h echo fi test "$ac_signal" != 0 && $as_echo "$as_me: caught signal $ac_signal" $as_echo "$as_me: exit $exit_status" } >&5 rm -f core *.core core.conftest.* && rm -f -r conftest* confdefs* conf$$* $ac_clean_files && exit $exit_status ' 0 for ac_signal in 1 2 13 15; do trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal done ac_signal=0 # confdefs.h avoids OS command line length limits that DEFS can exceed. rm -f -r conftest* confdefs.h # Predefined preprocessor variables. cat >>confdefs.h <<_ACEOF #define PACKAGE_NAME "$PACKAGE_NAME" _ACEOF cat >>confdefs.h <<_ACEOF #define PACKAGE_TARNAME "$PACKAGE_TARNAME" _ACEOF cat >>confdefs.h <<_ACEOF #define PACKAGE_VERSION "$PACKAGE_VERSION" _ACEOF cat >>confdefs.h <<_ACEOF #define PACKAGE_STRING "$PACKAGE_STRING" _ACEOF cat >>confdefs.h <<_ACEOF #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT" _ACEOF # Let the site file select an alternate cache file if it wants to. # Prefer an explicitly selected file to automatically selected ones. ac_site_file1=NONE ac_site_file2=NONE if test -n "$CONFIG_SITE"; then ac_site_file1=$CONFIG_SITE elif test "x$prefix" != xNONE; then ac_site_file1=$prefix/share/config.site ac_site_file2=$prefix/etc/config.site else ac_site_file1=$ac_default_prefix/share/config.site ac_site_file2=$ac_default_prefix/etc/config.site fi for ac_site_file in "$ac_site_file1" "$ac_site_file2" do test "x$ac_site_file" = xNONE && continue if test -r "$ac_site_file"; then { $as_echo "$as_me:$LINENO: loading site script $ac_site_file" >&5 $as_echo "$as_me: loading site script $ac_site_file" >&6;} sed 's/^/| /' "$ac_site_file" >&5 . "$ac_site_file" fi done if test -r "$cache_file"; then # Some versions of bash will fail to source /dev/null (special # files actually), so we avoid doing that. if test -f "$cache_file"; then { $as_echo "$as_me:$LINENO: loading cache $cache_file" >&5 $as_echo "$as_me: loading cache $cache_file" >&6;} case $cache_file in [\\/]* | ?:[\\/]* ) . "$cache_file";; *) . "./$cache_file";; esac fi else { $as_echo "$as_me:$LINENO: creating cache $cache_file" >&5 $as_echo "$as_me: creating cache $cache_file" >&6;} >$cache_file fi # Check that the precious variables saved in the cache have kept the same # value. ac_cache_corrupted=false for ac_var in $ac_precious_vars; do eval ac_old_set=\$ac_cv_env_${ac_var}_set eval ac_new_set=\$ac_env_${ac_var}_set eval ac_old_val=\$ac_cv_env_${ac_var}_value eval ac_new_val=\$ac_env_${ac_var}_value case $ac_old_set,$ac_new_set in set,) { $as_echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;} ac_cache_corrupted=: ;; ,set) { $as_echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;} ac_cache_corrupted=: ;; ,);; *) if test "x$ac_old_val" != "x$ac_new_val"; then # differences in whitespace do not lead to failure. ac_old_val_w=`echo x $ac_old_val` ac_new_val_w=`echo x $ac_new_val` if test "$ac_old_val_w" != "$ac_new_val_w"; then { $as_echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} ac_cache_corrupted=: else { $as_echo "$as_me:$LINENO: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;} eval $ac_var=\$ac_old_val fi { $as_echo "$as_me:$LINENO: former value: \`$ac_old_val'" >&5 $as_echo "$as_me: former value: \`$ac_old_val'" >&2;} { $as_echo "$as_me:$LINENO: current value: \`$ac_new_val'" >&5 $as_echo "$as_me: current value: \`$ac_new_val'" >&2;} fi;; esac # Pass precious variables to config.status. if test "$ac_new_set" = set; then case $ac_new_val in *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;; *) ac_arg=$ac_var=$ac_new_val ;; esac case " $ac_configure_args " in *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy. *) ac_configure_args="$ac_configure_args '$ac_arg'" ;; esac fi done if $ac_cache_corrupted; 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: changes in the environment can compromise the build" >&5 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;} { { $as_echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5 $as_echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;} { (exit 1); exit 1; }; } fi ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu ac_aux_dir= for ac_dir in tools "$srcdir"/tools; do if test -f "$ac_dir/install-sh"; then ac_aux_dir=$ac_dir ac_install_sh="$ac_aux_dir/install-sh -c" break elif test -f "$ac_dir/install.sh"; then ac_aux_dir=$ac_dir ac_install_sh="$ac_aux_dir/install.sh -c" break elif test -f "$ac_dir/shtool"; then ac_aux_dir=$ac_dir ac_install_sh="$ac_aux_dir/shtool install -c" break fi done if test -z "$ac_aux_dir"; then { { $as_echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in tools \"$srcdir\"/tools" >&5 $as_echo "$as_me: error: cannot find install-sh or install.sh in tools \"$srcdir\"/tools" >&2;} { (exit 1); exit 1; }; } fi # These three variables are undocumented and unsupported, # and are intended to be withdrawn in a future Autoconf release. # They can cause serious problems if a builder's source tree is in a directory # whose full name contains unusual characters. ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var. ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var. ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. # Automake initialization am__api_version='1.11' # Find a good install program. We prefer a C program (faster), # so one script is as good as another. But avoid the broken or # incompatible versions: # SysV /etc/install, /usr/sbin/install # SunOS /usr/etc/install # IRIX /sbin/install # AIX /bin/install # AmigaOS /C/install, which installs bootblocks on floppy discs # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag # AFS /usr/afsws/bin/install, which mishandles nonexistent args # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" # OS/2's system install, which has a completely different semantic # ./install, which can be erroneously created by make from ./install.sh. # Reject install programs that cannot install multiple files. { $as_echo "$as_me:$LINENO: checking for a BSD-compatible install" >&5 $as_echo_n "checking for a BSD-compatible install... " >&6; } if test -z "$INSTALL"; then if test "${ac_cv_path_install+set}" = set; then $as_echo_n "(cached) " >&6 else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. # Account for people who put trailing slashes in PATH elements. case $as_dir/ in ./ | .// | /cC/* | \ /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \ ?:\\/os2\\/install\\/* | ?:\\/OS2\\/INSTALL\\/* | \ /usr/ucb/* ) ;; *) # OSF1 and SCO ODT 3.0 have their own names for install. # Don't use installbsd from OSF since it installs stuff as root # by default. for ac_prog in ginstall scoinst install; do for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then if test $ac_prog = install && grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then # AIX install. It has an incompatible calling convention. : elif test $ac_prog = install && grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then # program-specific install script used by HP pwplus--don't use. : else rm -rf conftest.one conftest.two conftest.dir echo one > conftest.one echo two > conftest.two mkdir conftest.dir if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" && test -s conftest.one && test -s conftest.two && test -s conftest.dir/conftest.one && test -s conftest.dir/conftest.two then ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c" break 3 fi fi fi done done ;; esac done IFS=$as_save_IFS rm -rf conftest.one conftest.two conftest.dir fi if test "${ac_cv_path_install+set}" = set; then INSTALL=$ac_cv_path_install else # As a last resort, use the slow shell script. Don't cache a # value for INSTALL within a source directory, because that will # break other packages using the cache if that directory is # removed, or if the value is a relative name. INSTALL=$ac_install_sh fi fi { $as_echo "$as_me:$LINENO: result: $INSTALL" >&5 $as_echo "$INSTALL" >&6; } # Use test -z because SunOS4 sh mishandles braces in ${var-val}. # It thinks the first close brace ends the variable substitution. test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}' test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' { $as_echo "$as_me:$LINENO: checking whether build environment is sane" >&5 $as_echo_n "checking whether build environment is sane... " >&6; } # 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]*) { { $as_echo "$as_me:$LINENO: error: unsafe absolute working directory name" >&5 $as_echo "$as_me: error: unsafe absolute working directory name" >&2;} { (exit 1); exit 1; }; };; esac case $srcdir in *[\\\"\#\$\&\'\`$am_lf\ \ ]*) { { $as_echo "$as_me:$LINENO: error: unsafe srcdir value: \`$srcdir'" >&5 $as_echo "$as_me: error: unsafe srcdir value: \`$srcdir'" >&2;} { (exit 1); exit 1; }; };; esac # 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 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". { { $as_echo "$as_me:$LINENO: error: ls -t appears to fail. Make sure there is not a broken alias in your environment" >&5 $as_echo "$as_me: error: ls -t appears to fail. Make sure there is not a broken alias in your environment" >&2;} { (exit 1); exit 1; }; } fi test "$2" = conftest.file ) then # Ok. : else { { $as_echo "$as_me:$LINENO: error: newly created file is older than distributed files! Check your system clock" >&5 $as_echo "$as_me: error: newly created file is older than distributed files! Check your system clock" >&2;} { (exit 1); exit 1; }; } fi { $as_echo "$as_me:$LINENO: result: yes" >&5 $as_echo "yes" >&6; } test "$program_prefix" != NONE && program_transform_name="s&^&$program_prefix&;$program_transform_name" # Use a double $ so make ignores it. test "$program_suffix" != NONE && program_transform_name="s&\$&$program_suffix&;$program_transform_name" # Double any \ or $. # By default was `s,x,x', remove it if useless. ac_script='s/[\\$]/&&/g;s/;s,x,x,$//' program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"` # expand $ac_aux_dir to an absolute path am_aux_dir=`cd $ac_aux_dir && pwd` 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= { $as_echo "$as_me:$LINENO: WARNING: \`missing' script is too old or missing" >&5 $as_echo "$as_me: WARNING: \`missing' script is too old or missing" >&2;} fi 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 # 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. if test "$cross_compiling" != no; then 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_STRIP+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. 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_STRIP="${ac_tool_prefix}strip" $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 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; } fi 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 { $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 $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. 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_STRIP="strip" $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_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_STRIP" = x; then STRIP=":" 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 STRIP=$ac_ct_STRIP fi else STRIP="$ac_cv_prog_STRIP" fi fi INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s" { $as_echo "$as_me:$LINENO: checking for a thread-safe mkdir -p" >&5 $as_echo_n "checking for a thread-safe mkdir -p... " >&6; } if test -z "$MKDIR_P"; then if test "${ac_cv_path_mkdir+set}" = set; then $as_echo_n "(cached) " >&6 else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_prog in mkdir gmkdir; do for ac_exec_ext in '' $ac_executable_extensions; do { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; } || continue case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #( 'mkdir (GNU coreutils) '* | \ 'mkdir (coreutils) '* | \ 'mkdir (fileutils) '4.1*) ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext break 3;; esac done done done IFS=$as_save_IFS fi if test "${ac_cv_path_mkdir+set}" = set; then MKDIR_P="$ac_cv_path_mkdir -p" else # As a last resort, use the slow shell script. Don't cache a # value for MKDIR_P within a source directory, because that will # break other packages using the cache if that directory is # removed, or if the value is a relative name. test -d ./--version && rmdir ./--version MKDIR_P="$ac_install_sh -d" fi fi { $as_echo "$as_me:$LINENO: result: $MKDIR_P" >&5 $as_echo "$MKDIR_P" >&6; } mkdir_p="$MKDIR_P" case $mkdir_p in [\\/$]* | ?:[\\/]*) ;; */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;; esac for ac_prog in gawk mawk nawk awk 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_AWK+set}" = set; then $as_echo_n "(cached) " >&6 else if test -n "$AWK"; then ac_cv_prog_AWK="$AWK" # 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_AWK="$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 AWK=$ac_cv_prog_AWK if test -n "$AWK"; then { $as_echo "$as_me:$LINENO: result: $AWK" >&5 $as_echo "$AWK" >&6; } else { $as_echo "$as_me:$LINENO: result: no" >&5 $as_echo "no" >&6; } fi test -n "$AWK" && break done { $as_echo "$as_me:$LINENO: checking whether ${MAKE-make} sets \$(MAKE)" >&5 $as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; } set x ${MAKE-make} ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'` if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then $as_echo_n "(cached) " >&6 else cat >conftest.make <<\_ACEOF SHELL = /bin/sh all: @echo '@@@%%%=$(MAKE)=@@@%%%' _ACEOF # GNU make sometimes prints "make[1]: Entering...", which would confuse us. case `${MAKE-make} -f conftest.make 2>/dev/null` in *@@@%%%=?*=@@@%%%*) eval ac_cv_prog_make_${ac_make}_set=yes;; *) eval ac_cv_prog_make_${ac_make}_set=no;; esac rm -f conftest.make fi if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then { $as_echo "$as_me:$LINENO: result: yes" >&5 $as_echo "yes" >&6; } SET_MAKE= else { $as_echo "$as_me:$LINENO: result: no" >&5 $as_echo "no" >&6; } SET_MAKE="MAKE=${MAKE-make}" fi 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 if test "`cd $srcdir && pwd`" != "`pwd`"; then # Use -I$(srcdir) only when $(srcdir) != ., so that make's output # is not polluted with repeated "-I." am__isrc=' -I$(srcdir)' # test to see if srcdir already configured if test -f $srcdir/config.status; then { { $as_echo "$as_me:$LINENO: error: source directory already configured; run \"make distclean\" there first" >&5 $as_echo "$as_me: error: source directory already configured; run \"make distclean\" there first" >&2;} { (exit 1); exit 1; }; } fi fi # 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 # Define the identity of the package. PACKAGE='mod_r' VERSION='1.0' cat >>confdefs.h <<_ACEOF #define PACKAGE "$PACKAGE" _ACEOF cat >>confdefs.h <<_ACEOF #define VERSION "$VERSION" _ACEOF # Some tools Automake needs. ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"} AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"} AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"} AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"} MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"} # We need awk for the "check" target. The system "awk" is bad on # some platforms. # Always define AMTAR for backward compatibility. AMTAR=${AMTAR-"${am_missing_run}tar"} am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -' # This macro turns off maintainer mode by default. use "configure --enable-mainainer-mode" # to enable { $as_echo "$as_me:$LINENO: checking whether to enable maintainer-specific portions of Makefiles" >&5 $as_echo_n "checking whether to enable maintainer-specific portions of Makefiles... " >&6; } # Check whether --enable-maintainer-mode was given. if test "${enable_maintainer_mode+set}" = set; then enableval=$enable_maintainer_mode; USE_MAINTAINER_MODE=$enableval else USE_MAINTAINER_MODE=no fi { $as_echo "$as_me:$LINENO: result: $USE_MAINTAINER_MODE" >&5 $as_echo "$USE_MAINTAINER_MODE" >&6; } if test $USE_MAINTAINER_MODE = yes; then MAINTAINER_MODE_TRUE= MAINTAINER_MODE_FALSE='#' else MAINTAINER_MODE_TRUE='#' MAINTAINER_MODE_FALSE= fi MAINT=$MAINTAINER_MODE_TRUE # We'll get compiler and libtool info from apxs2 #AC_PROG_CC 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.6b' macro_revision='1.3017' ltmain="$ac_aux_dir/ltmain.sh" # Make sure we can run config.sub. $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 || { { $as_echo "$as_me:$LINENO: error: cannot run $SHELL $ac_aux_dir/config.sub" >&5 $as_echo "$as_me: error: cannot run $SHELL $ac_aux_dir/config.sub" >&2;} { (exit 1); exit 1; }; } { $as_echo "$as_me:$LINENO: checking build system type" >&5 $as_echo_n "checking build system type... " >&6; } if test "${ac_cv_build+set}" = set; then $as_echo_n "(cached) " >&6 else ac_build_alias=$build_alias test "x$ac_build_alias" = x && ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"` test "x$ac_build_alias" = x && { { $as_echo "$as_me:$LINENO: error: cannot guess build type; you must specify one" >&5 $as_echo "$as_me: error: cannot guess build type; you must specify one" >&2;} { (exit 1); exit 1; }; } ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` || { { $as_echo "$as_me:$LINENO: error: $SHELL $ac_aux_dir/config.sub $ac_build_alias failed" >&5 $as_echo "$as_me: error: $SHELL $ac_aux_dir/config.sub $ac_build_alias failed" >&2;} { (exit 1); exit 1; }; } fi { $as_echo "$as_me:$LINENO: result: $ac_cv_build" >&5 $as_echo "$ac_cv_build" >&6; } case $ac_cv_build in *-*-*) ;; *) { { $as_echo "$as_me:$LINENO: error: invalid value of canonical build" >&5 $as_echo "$as_me: error: invalid value of canonical build" >&2;} { (exit 1); exit 1; }; };; esac build=$ac_cv_build ac_save_IFS=$IFS; IFS='-' set x $ac_cv_build shift build_cpu=$1 build_vendor=$2 shift; shift # Remember, the first character of IFS is used to create $*, # except with old shells: build_os=$* IFS=$ac_save_IFS case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac { $as_echo "$as_me:$LINENO: checking host system type" >&5 $as_echo_n "checking host system type... " >&6; } if test "${ac_cv_host+set}" = set; then $as_echo_n "(cached) " >&6 else if test "x$host_alias" = x; then ac_cv_host=$ac_cv_build else ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` || { { $as_echo "$as_me:$LINENO: error: $SHELL $ac_aux_dir/config.sub $host_alias failed" >&5 $as_echo "$as_me: error: $SHELL $ac_aux_dir/config.sub $host_alias failed" >&2;} { (exit 1); exit 1; }; } fi fi { $as_echo "$as_me:$LINENO: result: $ac_cv_host" >&5 $as_echo "$ac_cv_host" >&6; } case $ac_cv_host in *-*-*) ;; *) { { $as_echo "$as_me:$LINENO: error: invalid value of canonical host" >&5 $as_echo "$as_me: error: invalid value of canonical host" >&2;} { (exit 1); exit 1; }; };; esac host=$ac_cv_host ac_save_IFS=$IFS; IFS='-' set x $ac_cv_host shift host_cpu=$1 host_vendor=$2 shift; shift # Remember, the first character of IFS is used to create $*, # except with old shells: host_os=$* IFS=$ac_save_IFS case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 CC=$ac_ct_CC fi fi fi 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); } 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 ac_clean_files_save=$ac_clean_files ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out" # Try to create an executable without -o first, disregard a.out. # It will help us diagnose broken compilers, and finding out an intuition # of exeext. { $as_echo "$as_me:$LINENO: checking for C compiler default output file name" >&5 $as_echo_n "checking for C compiler default output file name... " >&6; } ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'` # The possible output files: ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*" ac_rmfiles= for ac_file in $ac_files do case $ac_file in *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; * ) ac_rmfiles="$ac_rmfiles $ac_file";; esac done rm -f $ac_rmfiles if { (ac_try="$ac_link_default" 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_default") 2>&5 ac_status=$? $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; then # Autoconf-2.13 could set the ac_cv_exeext variable to `no'. # So ignore a value of `no', otherwise this would lead to `EXEEXT = no' # in a Makefile. We should not override ac_cv_exeext if it was cached, # so that the user can short-circuit this test for compilers unknown to # Autoconf. for ac_file in $ac_files '' do test -f "$ac_file" || continue case $ac_file in *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; [ab].out ) # We found the default executable, but exeext='' is most # certainly right. break;; *.* ) if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no; then :; else ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` fi # We set ac_cv_exeext here because the later test for it is not # safe: cross compilers may not add the suffix if given an `-o' # argument, so we may need to know it at that point already. # Even if this section looks crufty: it has the advantage of # actually working. break;; * ) break;; esac done test "$ac_cv_exeext" = no && ac_cv_exeext= else ac_file='' fi { $as_echo "$as_me:$LINENO: result: $ac_file" >&5 $as_echo "$ac_file" >&6; } if test -z "$ac_file"; then $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 { { $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 compiler cannot create executables See \`config.log' for more details." >&5 $as_echo "$as_me: error: C compiler cannot create executables See \`config.log' for more details." >&2;} { (exit 77); exit 77; }; }; } fi ac_exeext=$ac_cv_exeext # Check that the compiler produces executables we can run. If not, either # the compiler is broken, or we cross compile. { $as_echo "$as_me:$LINENO: checking whether the C compiler works" >&5 $as_echo_n "checking whether the C compiler works... " >&6; } # FIXME: These cross compiler hacks should be removed for Autoconf 3.0 # If not cross compiling, check that we can run a simple program. if test "$cross_compiling" != yes; then if { ac_try='./$ac_file' { (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 cross_compiling=no else if test "$cross_compiling" = maybe; then cross_compiling=yes 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: cannot run C compiled programs. If you meant to cross compile, use \`--host'. See \`config.log' for more details." >&5 $as_echo "$as_me: error: cannot run C compiled programs. If you meant to cross compile, use \`--host'. See \`config.log' for more details." >&2;} { (exit 1); exit 1; }; }; } fi fi fi { $as_echo "$as_me:$LINENO: result: yes" >&5 $as_echo "yes" >&6; } rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out ac_clean_files=$ac_clean_files_save # Check that the compiler produces executables we can run. If not, either # the compiler is broken, or we cross compile. { $as_echo "$as_me:$LINENO: checking whether we are cross compiling" >&5 $as_echo_n "checking whether we are cross compiling... " >&6; } { $as_echo "$as_me:$LINENO: result: $cross_compiling" >&5 $as_echo "$cross_compiling" >&6; } { $as_echo "$as_me:$LINENO: checking for suffix of executables" >&5 $as_echo_n "checking for suffix of executables... " >&6; } 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); }; then # If both `conftest.exe' and `conftest' are `present' (well, observable) # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will # work properly (i.e., refer to `conftest.exe'), while it won't with # `rm'. for ac_file in conftest.exe conftest conftest.*; do test -f "$ac_file" || continue case $ac_file in *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` break;; * ) break;; esac done 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: cannot compute suffix of executables: cannot compile and link See \`config.log' for more details." >&5 $as_echo "$as_me: error: cannot compute suffix of executables: cannot compile and link See \`config.log' for more details." >&2;} { (exit 1); exit 1; }; }; } fi rm -f conftest$ac_cv_exeext { $as_echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5 $as_echo "$ac_cv_exeext" >&6; } rm -f conftest.$ac_ext EXEEXT=$ac_cv_exeext ac_exeext=$EXEEXT { $as_echo "$as_me:$LINENO: checking for suffix of object files" >&5 $as_echo_n "checking for suffix of object files... " >&6; } if test "${ac_cv_objext+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. */ int main () { ; return 0; } _ACEOF rm -f conftest.o conftest.obj 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>&5 ac_status=$? $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; then for ac_file in conftest.o conftest.obj conftest.*; do test -f "$ac_file" || continue; case $ac_file in *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;; *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` break;; esac done else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 { { $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 compute suffix of object files: cannot compile See \`config.log' for more details." >&5 $as_echo "$as_me: error: cannot compute suffix of object files: cannot compile See \`config.log' for more details." >&2;} { (exit 1); exit 1; }; }; } fi rm -f conftest.$ac_cv_objext conftest.$ac_ext fi { $as_echo "$as_me:$LINENO: result: $ac_cv_objext" >&5 $as_echo "$ac_cv_objext" >&6; } OBJEXT=$ac_cv_objext ac_objext=$OBJEXT { $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. */ int main () { #ifndef __GNUC__ choke me #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_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. */ 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 CFLAGS="" 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 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. */ 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 { $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 $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 for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for 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 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; }; } 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 grep that handles long lines and -e" >&5 $as_echo_n "checking for grep that handles long lines and -e... " >&6; } if test "${ac_cv_path_GREP+set}" = set; then $as_echo_n "(cached) " >&6 else if test -z "$GREP"; then ac_path_GREP_found=false # Loop through the user's path and test for each of PROGNAME-LIST as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_prog in grep ggrep; do for ac_exec_ext in '' $ac_executable_extensions; do ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue # Check for GNU ac_path_GREP and select it if it is found. # Check for GNU $ac_path_GREP case `"$ac_path_GREP" --version 2>&1` in *GNU*) ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; *) ac_count=0 $as_echo_n 0123456789 >"conftest.in" while : do cat "conftest.in" "conftest.in" >"conftest.tmp" mv "conftest.tmp" "conftest.in" cp "conftest.in" "conftest.nl" $as_echo 'GREP' >> "conftest.nl" "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break ac_count=`expr $ac_count + 1` if test $ac_count -gt ${ac_path_GREP_max-0}; then # Best one so far, save it but keep looking for a better one ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_max=$ac_count fi # 10*(2^10) chars as input seems more than enough test $ac_count -gt 10 && break done rm -f conftest.in conftest.tmp conftest.nl conftest.out;; esac $ac_path_GREP_found && break 3 done done done IFS=$as_save_IFS if test -z "$ac_cv_path_GREP"; then { { $as_echo "$as_me:$LINENO: error: no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5 $as_echo "$as_me: error: no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;} { (exit 1); exit 1; }; } fi else ac_cv_path_GREP=$GREP fi fi { $as_echo "$as_me:$LINENO: result: $ac_cv_path_GREP" >&5 $as_echo "$ac_cv_path_GREP" >&6; } GREP="$ac_cv_path_GREP" { $as_echo "$as_me:$LINENO: checking for egrep" >&5 $as_echo_n "checking for egrep... " >&6; } if test "${ac_cv_path_EGREP+set}" = set; then $as_echo_n "(cached) " >&6 else if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 then ac_cv_path_EGREP="$GREP -E" else if test -z "$EGREP"; then ac_path_EGREP_found=false # Loop through the user's path and test for each of PROGNAME-LIST as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_prog in egrep; do for ac_exec_ext in '' $ac_executable_extensions; do ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue # Check for GNU ac_path_EGREP and select it if it is found. # Check for GNU $ac_path_EGREP case `"$ac_path_EGREP" --version 2>&1` in *GNU*) ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; *) ac_count=0 $as_echo_n 0123456789 >"conftest.in" while : do cat "conftest.in" "conftest.in" >"conftest.tmp" mv "conftest.tmp" "conftest.in" cp "conftest.in" "conftest.nl" $as_echo 'EGREP' >> "conftest.nl" "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break ac_count=`expr $ac_count + 1` if test $ac_count -gt ${ac_path_EGREP_max-0}; then # Best one so far, save it but keep looking for a better one ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_max=$ac_count fi # 10*(2^10) chars as input seems more than enough test $ac_count -gt 10 && break done rm -f conftest.in conftest.tmp conftest.nl conftest.out;; esac $ac_path_EGREP_found && break 3 done done done IFS=$as_save_IFS if test -z "$ac_cv_path_EGREP"; then { { $as_echo "$as_me:$LINENO: error: no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5 $as_echo "$as_me: error: no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;} { (exit 1); exit 1; }; } fi else ac_cv_path_EGREP=$EGREP fi fi fi { $as_echo "$as_me:$LINENO: result: $ac_cv_path_EGREP" >&5 $as_echo "$ac_cv_path_EGREP" >&6; } EGREP="$ac_cv_path_EGREP" { $as_echo "$as_me:$LINENO: checking for 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 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 # 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 # 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 &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 { $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_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'*) 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 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 fi fi DUMPBIN=$ac_cv_prog_DUMPBIN if test -n "$DUMPBIN"; then { $as_echo "$as_me:$LINENO: result: $DUMPBIN" >&5 $as_echo "$DUMPBIN" >&6; } else { $as_echo "$as_me:$LINENO: result: no" >&5 $as_echo "no" >&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_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 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 test -n "$ac_ct_DUMPBIN" && break done if test "x$ac_ct_DUMPBIN" = x; then DUMPBIN=":" 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 fi fi if test "$DUMPBIN" != ":"; then NM="$DUMPBIN" fi fi test -z "$NM" && NM=nm { $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:4227: $ac_compile\"" >&5) (eval "$ac_compile" 2>conftest.err) cat conftest.err >&5 (eval echo "\"\$as_me:4230: $NM \\\"conftest.$ac_objext\\\"\"" >&5) (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out) cat conftest.err >&5 (eval echo "\"\$as_me:4233: output\"" >&5) cat conftest.out >&5 if $GREP 'External.*some_variable' conftest.out > /dev/null; then lt_cv_nm_interface="MS dumpbin" 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" 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; ;; 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 # 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 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 max_cmd_len=$lt_cv_sys_max_cmd_len : ${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; } { $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 ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then lt_unset=unset else lt_unset=false fi # 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 { $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 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 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 { $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 $as_echo_n "(cached) " >&6 else if test -n "$OBJDUMP"; then ac_cv_prog_OBJDUMP="$OBJDUMP" # 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_OBJDUMP="${ac_tool_prefix}objdump" $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 OBJDUMP=$ac_cv_prog_OBJDUMP if test -n "$OBJDUMP"; then { $as_echo "$as_me:$LINENO: result: $OBJDUMP" >&5 $as_echo "$OBJDUMP" >&6; } else { $as_echo "$as_me:$LINENO: result: no" >&5 $as_echo "no" >&6; } fi 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 { $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 $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. 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_OBJDUMP="objdump" $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_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; } else { $as_echo "$as_me:$LINENO: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_OBJDUMP" = x; then OBJDUMP="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 OBJDUMP=$ac_ct_OBJDUMP 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 ;; beos*) lt_cv_deplibs_check_method=pass_all ;; 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' ;; 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 ;; 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' ;; 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 ;; 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 | kopensolaris*-gnu) lt_cv_deplibs_check_method=pass_all ;; netbsd* | netbsdelf*-gnu) 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 ;; tpf*) lt_cv_deplibs_check_method=pass_all ;; 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 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 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 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 test -z "$AR" && AR=ar test -z "$AR_FLAGS" && AR_FLAGS=cru 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_STRIP+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. 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_STRIP="${ac_tool_prefix}strip" $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 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; } fi 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 { $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 $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. 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_STRIP="strip" $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_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_STRIP" = x; then STRIP=":" 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 STRIP=$ac_ct_STRIP 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 $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 fi fi 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; } fi 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 $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 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; } else { $as_echo "$as_me:$LINENO: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_RANLIB" = x; then RANLIB=":" 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 fi else RANLIB="$ac_cv_prog_RANLIB" fi test -z "$RANLIB" && RANLIB=: # 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 # 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. { $as_echo "$as_me:$LINENO: checking command to parse $NM output from $compiler object" >&5 $as_echo_n "checking command to parse $NM output from $compiler object... " >&6; } if test "${lt_cv_sys_global_symbol_pipe+set}" = set; then $as_echo_n "(cached) " >&6 else # These are sane defaults that work on at least a few old systems. # [They come from Ultrix. What could be older than Ultrix?!! ;)] # 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]*\)' # 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]' 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'" # 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 # 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" # 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 # Check to see that the pipe works correctly. pipe_works=no 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 { (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 # Now try to grab the symbols. nlist=conftest.nm if { (eval echo "$as_me:$LINENO: \"$NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist\"") >&5 (eval $NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist) 2>&5 ac_status=$? $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && 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 # 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' cat <<_LT_EOF >> conftest.$ac_ext /* 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} }; /* 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 # 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_prog_compiler_no_builtin_flag" 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}; then pipe_works=yes fi LIBS="$lt_save_LIBS" CFLAGS="$lt_save_CFLAGS" else echo "cannot find nm_test_func in $nlist" >&5 fi else echo "cannot find nm_test_var in $nlist" >&5 fi else echo "cannot run $lt_cv_sys_global_symbol_pipe" >&5 fi else echo "$progname: failed program was:" >&5 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= fi done fi 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 { $as_echo "$as_me:$LINENO: result: failed" >&5 $as_echo "failed" >&6; } else { $as_echo "$as_me:$LINENO: result: ok" >&5 $as_echo "ok" >&6; } fi # 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 # 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 5439 "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 { $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 $as_echo_n "(cached) " >&6 else 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 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_DSYMUTIL="${ac_tool_prefix}dsymutil" $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 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; } 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 { $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 $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. 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_DSYMUTIL="dsymutil" $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_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_DSYMUTIL" = x; then DSYMUTIL=":" 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 DSYMUTIL=$ac_ct_DSYMUTIL fi else DSYMUTIL="$ac_cv_prog_DSYMUTIL" 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 { $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 $as_echo_n "(cached) " >&6 else 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 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_NMEDIT="${ac_tool_prefix}nmedit" $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 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; } 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 { $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 $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. 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_NMEDIT="nmedit" $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_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_NMEDIT" = x; then NMEDIT=":" 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 NMEDIT=$ac_ct_NMEDIT fi else NMEDIT="$ac_cv_prog_NMEDIT" fi 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 { $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 $as_echo_n "(cached) " >&6 else if test -n "$LIPO"; then ac_cv_prog_LIPO="$LIPO" # 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_LIPO="${ac_tool_prefix}lipo" $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 LIPO=$ac_cv_prog_LIPO if test -n "$LIPO"; then { $as_echo "$as_me:$LINENO: result: $LIPO" >&5 $as_echo "$LIPO" >&6; } else { $as_echo "$as_me:$LINENO: result: no" >&5 $as_echo "no" >&6; } 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 { $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 $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. 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_LIPO="lipo" $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_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; } else { $as_echo "$as_me:$LINENO: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_LIPO" = x; then LIPO=":" 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 LIPO=$ac_ct_LIPO fi else LIPO="$ac_cv_prog_LIPO" 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 { $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 $as_echo_n "(cached) " >&6 else if test -n "$OTOOL"; then ac_cv_prog_OTOOL="$OTOOL" # 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_OTOOL="${ac_tool_prefix}otool" $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 OTOOL=$ac_cv_prog_OTOOL if test -n "$OTOOL"; then { $as_echo "$as_me:$LINENO: result: $OTOOL" >&5 $as_echo "$OTOOL" >&6; } else { $as_echo "$as_me:$LINENO: result: no" >&5 $as_echo "no" >&6; } 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 { $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 $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. 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_OTOOL="otool" $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_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; } else { $as_echo "$as_me:$LINENO: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_OTOOL" = x; then OTOOL=":" 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 OTOOL=$ac_ct_OTOOL fi else OTOOL="$ac_cv_prog_OTOOL" 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_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.* fi fi { $as_echo "$as_me:$LINENO: result: $lt_cv_apple_cc_single_mod" >&5 $as_echo "$lt_cv_apple_cc_single_mod" >&6; } { $as_echo "$as_me:$LINENO: checking for -exported_symbols_list linker flag" >&5 $as_echo_n "checking for -exported_symbols_list linker flag... " >&6; } if test "${lt_cv_ld_exported_symbols_list+set}" = set; then $as_echo_n "(cached) " >&6 else lt_cv_ld_exported_symbols_list=no save_LDFLAGS=$LDFLAGS echo "_main" > conftest.sym LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym" 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_ld_exported_symbols_list=yes else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 lt_cv_ld_exported_symbols_list=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" 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]) _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 ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu { $as_echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5 $as_echo_n "checking how to run the C preprocessor... " >&6; } # On Suns, sometimes $CPP names a directory. if test -n "$CPP" && test -d "$CPP"; then CPP= fi if test -z "$CPP"; then if test "${ac_cv_prog_CPP+set}" = set; then $as_echo_n "(cached) " >&6 else # Double quotes because CPP needs to be expanded for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" do ac_preproc_ok=false for ac_c_preproc_warn_flag in '' yes do # Use a header file that comes with gcc, so configuring glibc # with a fresh cross-compiler works. # Prefer 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_c_preproc_warn_flag$ac_c_werror_flag" || test ! -s conftest.err }; then : else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 # Broken: fails on valid input. continue fi rm -f conftest.err conftest.$ac_ext # OK, works on sane cases. Now check whether nonexistent headers # can be detected and how. cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include _ACEOF if { (ac_try="$ac_cpp conftest.$ac_ext" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" $as_echo "$ac_try_echo") >&5 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null && { test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || test ! -s conftest.err }; then # Broken: success on invalid input. continue else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 # Passes both tests. ac_preproc_ok=: break fi rm -f conftest.err conftest.$ac_ext done # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. rm -f conftest.err conftest.$ac_ext if $ac_preproc_ok; then break fi done ac_cv_prog_CPP=$CPP fi CPP=$ac_cv_prog_CPP else ac_cv_prog_CPP=$CPP fi { $as_echo "$as_me:$LINENO: result: $CPP" >&5 $as_echo "$CPP" >&6; } ac_preproc_ok=false for ac_c_preproc_warn_flag in '' yes do # Use a header file that comes with gcc, so configuring glibc # with a fresh cross-compiler works. # Prefer 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_c_preproc_warn_flag$ac_c_werror_flag" || test ! -s conftest.err }; then : else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 # Broken: fails on valid input. continue fi rm -f conftest.err conftest.$ac_ext # OK, works on sane cases. Now check whether nonexistent headers # can be detected and how. cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include _ACEOF if { (ac_try="$ac_cpp conftest.$ac_ext" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" $as_echo "$ac_try_echo") >&5 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null && { test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || test ! -s conftest.err }; then # Broken: success on invalid input. continue else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 # Passes both tests. ac_preproc_ok=: break fi rm -f conftest.err conftest.$ac_ext done # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. rm -f conftest.err conftest.$ac_ext if $ac_preproc_ok; then : else { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} { { $as_echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check See \`config.log' for more details." >&5 $as_echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check See \`config.log' for more details." >&2;} { (exit 1); exit 1; }; }; } fi ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu { $as_echo "$as_me:$LINENO: checking for ANSI C header files" >&5 $as_echo_n "checking for ANSI C header files... " >&6; } if test "${ac_cv_header_stdc+set}" = set; then $as_echo_n "(cached) " >&6 else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include #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 # On IRIX 5.3, sys/types and inttypes.h are conflicting. for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \ inttypes.h stdint.h unistd.h do as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5 $as_echo_n "checking for $ac_header... " >&6; } if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then $as_echo_n "(cached) " >&6 else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ $ac_includes_default #include <$ac_header> _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" $as_echo "$ac_try_echo") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then eval "$as_ac_Header=yes" else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 eval "$as_ac_Header=no" fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi ac_res=`eval 'as_val=${'$as_ac_Header'} $as_echo "$as_val"'` { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } 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_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 fi done # Set options enable_dlopen=no enable_win32_dll=no # 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 --with-pic was given. if test "${with_pic+set}" = set; then withval=$with_pic; pic_mode="$withval" else pic_mode=default fi test -z "$pic_mode" && pic_mode=default # 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 # This can be used to rebuild libtool when needed LIBTOOL_DEPS="$ltmain" # Always use our own libtool. LIBTOOL='$(SHELL) $(top_builddir)/libtool' test -z "$LN_S" && LN_S="ln -s" if test -n "${ZSH_VERSION+set}" ; then setopt NO_GLOB_SUBST 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 cat >>confdefs.h <<_ACEOF #define LT_OBJDIR "$lt_cv_objdir/" _ACEOF 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. 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' # 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 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 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 *** 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 _LT_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 <<_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 _LT_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 # Use C for the default configuration in the libtool script 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);}' # 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* ## 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... 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:7296: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 echo "$as_me:7300: \$? = $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 ;; beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) # PIC is the default for these OSes. ;; 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*) # PIC is the default on this platform # Common symbols not allowed in MH_DYLIB files lt_prog_compiler_pic='-fno-common' ;; 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 ;; 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=no enable_shared=no ;; *nto* | *qnx*) # QNX uses GNU C++, but need to define -shared option too, otherwise # it will coredump. lt_prog_compiler_pic='-fPIC -shared' ;; sysv4*MP*) if test -d /usr/nec; then lt_prog_compiler_pic=-Kconform_pic fi ;; *) 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 ;; 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' ;; 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' ;; linux* | k*bsd*-gnu | kopensolaris*-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 ;; newsos6) lt_prog_compiler_pic='-KPIC' lt_prog_compiler_static='-Bstatic' ;; *nto* | *qnx*) # QNX uses GNU C++, but need to define -shared option too, otherwise # it will coredump. lt_prog_compiler_pic='-fPIC -shared' ;; 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 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; } # # 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:7635: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 echo "$as_me:7639: \$? = $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 # # 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:7740: $lt_compile\"" >&5) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&5 echo "$as_me:7744: \$? = $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; } { $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:7795: $lt_compile\"" >&5) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&5 echo "$as_me:7799: \$? = $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; } 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 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= 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 ;; linux* | k*bsd*-gnu) link_all_deplibs=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}' # 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>&1` in *GNU\ gold*) supports_anon_versioning=yes ;; *\ [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 *** 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. _LT_EOF 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 ;; 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* | 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' 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* | tpf* | k*bsd*-gnu | kopensolaris*-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' 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 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 ;; netbsd* | netbsdelf*-gnu) 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 <<_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. _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 ;; 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 *** 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 ;; *) # 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 ;; sunos4*) archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' wlarc= hardcode_direct=yes hardcode_shlibpath_var=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 ;; esac 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 ;; 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 # 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='' hardcode_direct=yes hardcode_direct_absolute=yes hardcode_libdir_separator=':' link_all_deplibs=yes file_list_spec='${wl}-f,' 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 link_all_deplibs=no 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 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 /* 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_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 "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 /* 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_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" # 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 ;; 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) {} _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 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' 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 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* | netbsdelf*-gnu) 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) 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 ;; *nto* | *qnx*) ;; 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 ;; 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*) 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=: ;; 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' # Both c and cxx compiler support -rpath directly hardcode_libdir_flag_spec='-rpath $libdir' fi archive_cmds_need_lc='no' hardcode_libdir_separator=: ;; 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 ;; 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 ;; 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 ;; 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' 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 ;; uts4*) archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_libdir_flag_spec='-L$libdir' hardcode_shlibpath_var=no ;; *) ld_shlibs=no ;; esac 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 { $as_echo "$as_me:$LINENO: result: $ld_shlibs" >&5 $as_echo "$ld_shlibs" >&6; } test "$ld_shlibs" = no && can_build_shared=no with_gnu_ld=$with_gnu_ld # # 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 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 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 { $as_echo "$as_me:$LINENO: checking dynamic linker characteristics" >&5 $as_echo_n "checking dynamic linker characteristics... " >&6; } 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 # 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*) 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 ;; 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* | cegcc*) version_type=windows shrext_cmds=".dll" need_version=no need_lib_prefix=no 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 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 ;; *) 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 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 ;; # This must be Linux ELF. linux* | k*bsd*-gnu | kopensolaris*-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 /* 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 if ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then shlibpath_overrides_runpath=yes 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 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 # 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' ;; netbsdelf*-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 shlibpath_overrides_runpath=no hardcode_into_libs=yes dynamic_linker='NetBSD ld.elf_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 ;; 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 ;; *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 ;; 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 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 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' ;; 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 { $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-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 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 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 { $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 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 /* 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; } _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_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 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. */ /* 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 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 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 /* 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. */ #ifdef __STDC__ # include #else # include #endif #undef dlopen /* 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 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 ac_cv_func_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 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 ;; 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" { $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 10612 "configure" #include "confdefs.h" #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); */ } 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 ;; esac else : # compilation failed lt_cv_dlopen_self=no fi 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 <<_LT_EOF #line 10708 "configure" #include "confdefs.h" #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); */ } 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 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 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 # 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; } 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" ac_config_commands="$ac_config_commands libtool" # Only expand once: for ac_header in sys/types.h unistd.h stdlib.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 jeff.horner@vanderbilt.edu ## ## ----------------------------------------- ## _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 # --with-R # --with-apreq2-config # Extract the first word of "uname", so it can be a program name with args. set dummy uname; 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_UNAME+set}" = set; then $as_echo_n "(cached) " >&6 else case $UNAME in [\\/]* | ?:[\\/]*) ac_cv_path_UNAME="$UNAME" # 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_UNAME="$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 UNAME=$ac_cv_path_UNAME if test -n "$UNAME"; then { $as_echo "$as_me:$LINENO: result: $UNAME" >&5 $as_echo "$UNAME" >&6; } else { $as_echo "$as_me:$LINENO: result: no" >&5 $as_echo "no" >&6; } fi if test -z "$APXS" then { $as_echo "$as_me:$LINENO: checking for --with-apxs" >&5 $as_echo_n "checking for --with-apxs... " >&6; } # Check whether --with-apxs was given. if test "${with_apxs+set}" = set; then withval=$with_apxs; if test "$withval" != "yes" then APXS="$withval" { $as_echo "$as_me:$LINENO: result: $withval" >&5 $as_echo "$withval" >&6; } else { $as_echo "$as_me:$LINENO: result: no" >&5 $as_echo "no" >&6; } fi else { $as_echo "$as_me:$LINENO: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$APXS" then # Extract the first word of "apxs", so it can be a program name with args. set dummy apxs; 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_APXS+set}" = set; then $as_echo_n "(cached) " >&6 else case $APXS in [\\/]* | ?:[\\/]*) ac_cv_path_APXS="$APXS" # 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_APXS="$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 test -z "$ac_cv_path_APXS" && ac_cv_path_APXS="apxs" ;; esac fi APXS=$ac_cv_path_APXS if test -n "$APXS"; then { $as_echo "$as_me:$LINENO: result: $APXS" >&5 $as_echo "$APXS" >&6; } else { $as_echo "$as_me:$LINENO: result: no" >&5 $as_echo "no" >&6; } fi fi HTTPD="`$APXS -q sbindir`/`$APXS -q progname`" # Check whether --with-R was given. if test "${with_R+set}" = set; then withval=$with_R; else with_R="no" fi if test "$with_R" = "no"; then # Extract the first word of "R", so it can be a program name with args. set dummy R; 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_RPROGRAM+set}" = set; then $as_echo_n "(cached) " >&6 else case $RPROGRAM in [\\/]* | ?:[\\/]*) ac_cv_path_RPROGRAM="$RPROGRAM" # 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_RPROGRAM="$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 test -z "$ac_cv_path_RPROGRAM" && ac_cv_path_RPROGRAM="no" ;; esac fi RPROGRAM=$ac_cv_path_RPROGRAM if test -n "$RPROGRAM"; then { $as_echo "$as_me:$LINENO: result: $RPROGRAM" >&5 $as_echo "$RPROGRAM" >&6; } else { $as_echo "$as_me:$LINENO: result: no" >&5 $as_echo "no" >&6; } fi if test "$RPROGRAM" = "no"; then echo echo echo "Specify the R program using --with-R (like /usr/local/bin/R)" echo { { $as_echo "$as_me:$LINENO: error: aborting! " >&5 $as_echo "$as_me: error: aborting! " >&2;} { (exit 1); exit 1; }; } else if $RPROGRAM CMD config --ldflags 2>/dev/null | grep -v 'R was not built as a shared library' >/dev/null; then RPROG=$RPROGRAM RHOME=`$RPROGRAM RHOME` RINCLUDES=`$RPROG CMD config --cppflags` RLINKLD=`$RPROG CMD config --ldflags` else echo echo echo "R was not built as a shared library" echo echo "Either build it with one, or use another install of R" echo { { $as_echo "$as_me:$LINENO: error: aborting! " >&5 $as_echo "$as_me: error: aborting! " >&2;} { (exit 1); exit 1; }; } fi fi else { $as_echo "$as_me:$LINENO: checking for R Program" >&5 $as_echo_n "checking for R Program... " >&6; } # make sure that a well known include file exists # and the libR.so if $with_R CMD config --ldflags 2>/dev/null | grep -v 'R was not built as a shared library' >/dev/null; then RPROG=$with_R RHOME=`$with_R RHOME` RINCLUDES=`$RPROG CMD config --cppflags` RLINKLD=`$RPROG CMD config --ldflags` { $as_echo "$as_me:$LINENO: result: $RPROG" >&5 $as_echo "$RPROG" >&6; } else echo echo echo "R was not built as a shared library" echo echo "Either build it with one, or use another install of R" echo { { $as_echo "$as_me:$LINENO: error: aborting! " >&5 $as_echo "$as_me: error: aborting! " >&2;} { (exit 1); exit 1; }; } fi fi # Check whether --with-apreq2-config was given. if test "${with_apreq2_config+set}" = set; then withval=$with_apreq2_config; else with_apreq2_config="no" fi if test "$with_apreq2_config" = "no"; then # Extract the first word of "apreq2-config", so it can be a program name with args. set dummy apreq2-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_APREQCONFIG+set}" = set; then $as_echo_n "(cached) " >&6 else case $APREQCONFIG in [\\/]* | ?:[\\/]*) ac_cv_path_APREQCONFIG="$APREQCONFIG" # 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_APREQCONFIG="$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 test -z "$ac_cv_path_APREQCONFIG" && ac_cv_path_APREQCONFIG="no" ;; esac fi APREQCONFIG=$ac_cv_path_APREQCONFIG if test -n "$APREQCONFIG"; then { $as_echo "$as_me:$LINENO: result: $APREQCONFIG" >&5 $as_echo "$APREQCONFIG" >&6; } else { $as_echo "$as_me:$LINENO: result: no" >&5 $as_echo "no" >&6; } fi if test "$APREQCONFIG" = "no"; then echo echo echo "Using libapreq2 that comes bundled with mod_R" echo APREQ=`pwd`/libapreq2/apreq2-config APREQ_COMPILE="(cd libapreq2; make apreq2-config; cd library; make)" APREQ_INSTALL="(cd libapreq2/library; make install)" APREQ_CLEAN="(cd libapreq2; make clean)" (cd libapreq2; ./configure --with-apache2-apxs=$APXS) APREQ_LIB_DIR=`$APREQ --link-ld | sed -e 's/-L//;s/-lapreq2//;s/ //g'` APREQ_INCLUDES=`$APREQ --includes` APREQ_LINKLD=`$APREQ --link-ld` else APREQ=$APREQCONFIG APREQ_COMPILE= APREQ_INSTALL= APREQ_CLEAN= APREQ_LIB_DIR=`$APREQ --link-ld | sed -e 's/-L//;s/-lapreq2//;s/ //g'` APREQ_INCLUDES=`$APREQ --includes` APREQ_LINKLD=`$APREQ --link-ld` fi else { $as_echo "$as_me:$LINENO: checking for apreq2-config" >&5 $as_echo_n "checking for apreq2-config... " >&6; } # make sure that a well known include file exists if test -f `$with_apreq2_config --includedir`/apreq.h ; then APREQ=$with_apreq2_config APREQ_COMPILE= APREQ_INSTALL= APREQ_CLEAN= APREQ_LIB_DIR=`$APREQ --link-ld | sed -e 's/-L//;s/-lapreq2//;s/ //g'` APREQ_INCLUDES=`$APREQ --includes` APREQ_LINKLD=`$APREQ --link-ld` else echo echo echo "Cannot find libapreq2 header files" echo echo "Check to make sure libapreq2 is already installed in your Apache install." echo "If not, then don't specifiy the --with-apreq2-config option as mod_R comes bundled" echo "with it." echo { { $as_echo "$as_me:$LINENO: error: aborting! " >&5 $as_echo "$as_me: error: aborting! " >&2;} { (exit 1); exit 1; }; } fi fi DOCROOT=`pwd`/test if test "${UNAME}" != ""; then if test "`${UNAME}`" = "Linux"; then RPATH=-Wl,-rpath,${RHOME}/lib fi fi SHLIBPATH_VAR=$shlibpath_var ac_config_files="$ac_config_files Makefile mod_R.h" 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 case $ac_var in #( _ | IFS | as_nl) ;; #( BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( *) $as_unset $ac_var ;; esac ;; esac done (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}' # Transform confdefs.h into DEFS. # Protect against shell expansion while executing Makefile rules. # Protect against Makefile macro expansion. # # If the first sed substitution is executed (which looks for macros that # take arguments), then branch to the quote section. Otherwise, # look for a macro that doesn't take arguments. ac_script=' :mline /\\$/{ N s,\\\n,, b mline } t clear :clear s/^[ ]*#[ ]*define[ ][ ]*\([^ (][^ (]*([^)]*)\)[ ]*\(.*\)/-D\1=\2/g t quote s/^[ ]*#[ ]*define[ ][ ]*\([^ ][^ ]*\)[ ]*\(.*\)/-D\1=\2/g t quote b any :quote s/[ `~#$^&*(){}\\|;'\''"<>?]/\\&/g s/\[/\\&/g s/\]/\\&/g s/\$/$$/g H :any ${ g s/^\n// s/\n/ /g p } ' DEFS=`sed -n "$ac_script" confdefs.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 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 : ${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. debug=false ac_cs_recheck=false ac_cs_silent=false SHELL=\${CONFIG_SHELL-$SHELL} _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 ## --------------------- ## ## M4sh Initialization. ## ## --------------------- ## # 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 fi # 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 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 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 # Support unset when possible. if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then as_unset=unset else as_unset=false fi # 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" # 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 ;; 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 # 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='+ ' # NLS nuisances. LC_ALL=C export LC_ALL LANGUAGE=C export LANGUAGE # 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 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then as_basename=basename else as_basename=false fi # 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'` # CDPATH. $as_unset CDPATH 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" || { # 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; }; } # 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 } if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then as_dirname=dirname else as_dirname=false fi 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 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 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= 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'" 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 mod_R $as_me 1.0, which was generated by GNU Autoconf 2.63. Invocation command line was 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` " _ACEOF case $ac_config_files in *" "*) set x $ac_config_files; shift; ac_config_files=$*;; esac cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 # Files that config.status was made for. config_files="$ac_config_files" config_commands="$ac_config_commands" _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 ac_cs_usage="\ \`$as_me' instantiates files from templates according to the current configuration. 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 Configuration files: $config_files Configuration commands: $config_commands Report bugs to ." _ACEOF cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 ac_cs_version="\\ mod_R config.status 1.0 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;; --he | --h | --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 # # 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 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 # 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 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 fi 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 "libtool") CONFIG_COMMANDS="$CONFIG_COMMANDS libtool" ;; "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;; "mod_R.h") CONFIG_FILES="$CONFIG_FILES mod_R.h" ;; *) { { $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 # 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_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands 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. { 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; } } # 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 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 echo 'BEGIN {' >"$tmp/subs1.awk" && _ACEOF { 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; }; } 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 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 = "" } { 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 } _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 # 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 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 fi # test -n "$CONFIG_FILES" eval set X " :F $CONFIG_FILES :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 # 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 $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=. 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 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 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 _ACEOF 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= 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 # 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; }; } 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;} 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; }; } ;; :C) { $as_echo "$as_me:$LINENO: executing $ac_file commands" >&5 $as_echo "$as_me: executing $ac_file commands" >&6;} ;; esac case $ac_file$ac_mode in "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 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) 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 # Executable file suffix (normally ""). exeext=$exeext # whether the shell understands "unset". lt_unset=$lt_unset # turn spaces into newlines. SP2NL=$lt_lt_SP2NL # 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 # Command to use when deplibs_check_method == "file_magic". file_magic_cmd=$lt_file_magic_cmd # The archiver. AR=$lt_AR AR_FLAGS=$lt_AR_FLAGS # A symbol stripping program. STRIP=$lt_STRIP # 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 # LTCC compiler flags. LTCFLAGS=$lt_CFLAGS # 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 # 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 # The name of the directory that contains temporary libtool files. objdir=$objdir # Shell to use when invoking shell scripts. SHELL=$lt_SHELL # An echo program that does not interpret backslashes. ECHO=$lt_ECHO # Used to examine libraries when file_magic_cmd begins with "file". MAGIC_CMD=$MAGIC_CMD # 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 # Tool to manipulate fat objects and archives on Mac OS X. LIPO=$lt_LIPO # ldd/readelf like tool for Mach-O binaries on Mac OS X. OTOOL=$lt_OTOOL # 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 # Shared library suffix (normally ".so"). shrext_cmds=$lt_shrext_cmds # The commands to extract the exported symbol list from a shared archive. extract_expsyms_cmds=$lt_extract_expsyms_cmds # Variables whose values should be saved in libtool wrapper scripts and # restored at link time. variables_saved_for_relink=$lt_variables_saved_for_relink # 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 # Library versioning type. version_type=$version_type # Shared library runtime path variable. runpath_var=$runpath_var # Shared library path variable. shlibpath_var=$shlibpath_var # Is shlibpath searched before the hard-coded library search path? shlibpath_overrides_runpath=$shlibpath_overrides_runpath # 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 # Command to use after installation of a shared archive. postinstall_cmds=$lt_postinstall_cmds # Command to use after uninstallation of a shared archive. postuninstall_cmds=$lt_postuninstall_cmds # 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 # Whether we should hardcode library paths into libraries. hardcode_into_libs=$hardcode_into_libs # 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 # 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 # Commands to strip libraries. old_striplib=$lt_old_striplib striplib=$lt_striplib # The linker used to build libraries. LD=$lt_LD # Commands used to build an old-style archive. old_archive_cmds=$lt_old_archive_cmds # A language specific compiler. CC=$lt_compiler # Is the compiler the GNU compiler? with_gcc=$GCC # Compiler flag to turn off builtin functions. no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag # How to pass a linker flag through the compiler. wl=$lt_lt_prog_compiler_wl # Additional compiler flags for building library objects. pic_flag=$lt_lt_prog_compiler_pic # Compiler flag to prevent dynamic linking. link_static_flag=$lt_lt_prog_compiler_static # Does compiler simultaneously support -c and -o options? compiler_c_o=$lt_lt_cv_prog_compiler_c_o # 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 # 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 # Whether the compiler copes with passing no objects directly. compiler_needs_object=$lt_compiler_needs_object # 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 a shared archive. archive_cmds=$lt_archive_cmds archive_expsym_cmds=$lt_archive_expsym_cmds # 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 # Flag that allows shared libraries with undefined symbols to be built. allow_undefined_flag=$lt_allow_undefined_flag # Flag that enforces no undefined symbols. no_undefined_flag=$lt_no_undefined_flag # 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 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 # 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 # Set to yes if linker adds runtime paths of dependent libraries # to runtime path list. inherit_rpath=$inherit_rpath # Whether libtool must link a program against all its dependency libraries. link_all_deplibs=$link_all_deplibs # 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 # 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 # Commands necessary for linking programs (against libraries) with templates. prelink_cmds=$lt_prelink_cmds # Specify filename containing input files. file_list_spec=$lt_file_list_spec # How to hardcode a shared library path into an executable. hardcode_action=$hardcode_action # ### END LIBTOOL CONFIG _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 ;; esac 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) 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"` } # 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 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" ;; esac done # for ac_tag { (exit 0); exit 0; } _ACEOF chmod +x $CONFIG_STATUS ac_clean_files=$ac_clean_files_save test $ac_write_fail = 0 || { { $as_echo "$as_me:$LINENO: error: write failure creating $CONFIG_STATUS" >&5 $as_echo "$as_me: error: write failure creating $CONFIG_STATUS" >&2;} { (exit 1); exit 1; }; } # configure is writing to config.log, and then calls config.status. # config.status does its own redirection, appending to config.log. # Unfortunately, on DOS this fails, as config.log is still kept open # by configure, so config.status won't be able to write to it; its # output is simply discarded. So we exec the FD to /dev/null, # effectively closing config.log, so it can be properly (re)opened and # appended to by config.status. When coming back to configure, we # need to make the FD available again. if test "$no_create" != yes; then ac_cs_success=: ac_config_status_args= test "$silent" = yes && ac_config_status_args="$ac_config_status_args --quiet" exec 5>/dev/null $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false exec 5>>config.log # Use ||, not &&, to avoid exiting from the if with $? = 1, which # would make configure fail if this is the last instruction. $ac_cs_success || { (exit 1); exit 1; } fi if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then { $as_echo "$as_me:$LINENO: WARNING: unrecognized options: $ac_unrecognized_opts" >&5 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;} fi rapache-1.2.8/configure.in0000644000175100017510000001126212706745114014775 0ustar ondrejondrejAC_INIT(mod_R,1.0,jeff.horner@vanderbilt.edu) AC_CONFIG_AUX_DIR([tools]) AC_CONFIG_MACRO_DIR([m4]) # Automake initialization AM_INIT_AUTOMAKE( foreign no-texinfo.tex no-dependencies no-dist no-installinfo no-installman no-exeext ) # This macro turns off maintainer mode by default. use "configure --enable-mainainer-mode" # to enable AM_MAINTAINER_MODE # We'll get compiler and libtool info from apxs2 #AC_PROG_CC AC_PROG_LIBTOOL AC_CHECK_HEADERS( sys/types.h unistd.h stdlib.h ) # --with-R AC_DEFUN([R_PROG],[ AC_ARG_WITH( R, [ --with-R=PATH Path to R (usually /usr/local/bin/R) ], , [with_R="no"] ) if test "$with_R" = "no"; then AC_PATH_PROG([RPROGRAM],[R],[no]) if test "$RPROGRAM" = "no"; then echo echo echo "Specify the R program using --with-R (like /usr/local/bin/R)" echo AC_MSG_ERROR( aborting! ) else if $RPROGRAM CMD config --ldflags 2>/dev/null | grep -v 'R was not built as a shared library' >/dev/null; then RPROG=$RPROGRAM RHOME=`$RPROGRAM RHOME` RINCLUDES=`$RPROG CMD config --cppflags` RLINKLD=`$RPROG CMD config --ldflags` else echo echo echo "R was not built as a shared library" echo echo "Either build it with one, or use another install of R" echo AC_MSG_ERROR( aborting! ) fi fi else AC_MSG_CHECKING(for R Program) # make sure that a well known include file exists # and the libR.so if $with_R CMD config --ldflags 2>/dev/null | grep -v 'R was not built as a shared library' >/dev/null; then RPROG=$with_R RHOME=`$with_R RHOME` RINCLUDES=`$RPROG CMD config --cppflags` RLINKLD=`$RPROG CMD config --ldflags` AC_MSG_RESULT([$RPROG]) else echo echo echo "R was not built as a shared library" echo echo "Either build it with one, or use another install of R" echo AC_MSG_ERROR( aborting! ) fi fi ]) # --with-apreq2-config AC_DEFUN([APREQ_CONFIG],[ AC_ARG_WITH( apreq2-config, [ --with-apreq2-config=PATH Path to apreq2-config ], , [with_apreq2_config="no"] ) if test "$with_apreq2_config" = "no"; then AC_PATH_PROG([APREQCONFIG],[apreq2-config],[no]) if test "$APREQCONFIG" = "no"; then echo echo echo "Using libapreq2 that comes bundled with mod_R" echo APREQ=`pwd`/libapreq2/apreq2-config APREQ_COMPILE="(cd libapreq2; make apreq2-config; cd library; make)" APREQ_INSTALL="(cd libapreq2/library; make install)" APREQ_CLEAN="(cd libapreq2; make clean)" (cd libapreq2; ./configure --with-apache2-apxs=$APXS) APREQ_LIB_DIR=`$APREQ --link-ld | sed -e 's/-L//;s/-lapreq2//;s/ //g'` APREQ_INCLUDES=`$APREQ --includes` APREQ_LINKLD=`$APREQ --link-ld` else APREQ=$APREQCONFIG APREQ_COMPILE= APREQ_INSTALL= APREQ_CLEAN= APREQ_LIB_DIR=`$APREQ --link-ld | sed -e 's/-L//;s/-lapreq2//;s/ //g'` APREQ_INCLUDES=`$APREQ --includes` APREQ_LINKLD=`$APREQ --link-ld` fi else AC_MSG_CHECKING(for apreq2-config) # make sure that a well known include file exists if test -f `$with_apreq2_config --includedir`/apreq.h ; then APREQ=$with_apreq2_config APREQ_COMPILE= APREQ_INSTALL= APREQ_CLEAN= APREQ_LIB_DIR=`$APREQ --link-ld | sed -e 's/-L//;s/-lapreq2//;s/ //g'` APREQ_INCLUDES=`$APREQ --includes` APREQ_LINKLD=`$APREQ --link-ld` else echo echo echo "Cannot find libapreq2 header files" echo echo "Check to make sure libapreq2 is already installed in your Apache install." echo "If not, then don't specifiy the --with-apreq2-config option as mod_R comes bundled" echo "with it." echo AC_MSG_ERROR( aborting! ) fi fi ]) AC_DEFUN([SET_DOCROOT],[ DOCROOT=`pwd`/test ]) AC_PATH_PROG(UNAME,uname) AC_DEFUN([WITH_RPATH],[ if test "${UNAME}" != ""; then if test "`${UNAME}`" = "Linux"; then RPATH=-Wl,-rpath,${RHOME}/lib fi fi ]) AX_WITH_APXS AC_SUBST(APXS) HTTPD="`$APXS -q sbindir`/`$APXS -q progname`" AC_SUBST(HTTPD) R_PROG AC_SUBST(RPROG) AC_SUBST(RHOME) AC_SUBST(RINCLUDES) AC_SUBST(RLINKLD) APREQ_CONFIG AC_SUBST(APREQ) AC_SUBST(APREQ_COMPILE) AC_SUBST(APREQ_INSTALL) AC_SUBST(APREQ_CLEAN) AC_SUBST(APREQ_LIB_DIR) AC_SUBST(APREQ_INCLUDES) AC_SUBST(APREQ_LINKLD) SET_DOCROOT AC_SUBST(DOCROOT) WITH_RPATH AC_SUBST(RPATH) SHLIBPATH_VAR=$shlibpath_var AC_SUBST(SHLIBPATH_VAR) AC_OUTPUT(Makefile mod_R.h) rapache-1.2.8/debian/0000755000175100017510000000000012706745114013704 5ustar ondrejondrejrapache-1.2.8/debian/changelog0000644000175100017510000000262012706745114015556 0ustar ondrejondrejlibapache2-mod-r-base (1.2.8-xenial0) xenial0; urgency=low * Remove apache2-mpm-prefork dependency (prefork is now included with apache2-dev / apache2-bin) -- Jeroen Ooms Sat, 23 Apr 2016 00:00:00 -0600 libapache2-mod-r-base (1.2.7-trusty0) trusty; urgency=low * Add support for rpm -- Jeroen Ooms Wed, 24 Jun 2015 00:00:00 -0600 libapache2-mod-r-base (1.2.6-trusty0) trusty; urgency=low * Add support for rpm -- Jeroen Ooms Sun, 17 Aug 2014 00:00:00 -0600 libapache2-mod-r-base (1.2.5-saucy0) saucy; urgency=low * Various small fixes -- Jeroen Ooms Mon, 23 Dec 2013 00:00:00 -0600 libapache2-mod-r-base (1.2.4-raring5) raring; urgency=low * Updates for compatibility with Apache 2.4 -- Jeroen Ooms Tue, 15 Oct 2013 11:08:00 -0600 libapache2-mod-r-base (1.1.14-ppa3) lucid; urgency=low * Binary package release for rApache 1.1.14 -- Jeffrey Horner Wed, 12 Jan 2011 11:08:00 -0600 libapache2-mod-r-base (1.1.13-ppa3) lucid; urgency=low * Binary package release for rApache 1.1.13 -- Jeffrey Horner Thu, 09 Dec 2010 07:46:44 -0600 libapache2-mod-r-base (1.1.10-ppa3) lucid; urgency=low * First binary package release with new name. -- Jeffrey Horner Fri, 01 Oct 2010 19:00:25 -0500 rapache-1.2.8/debian/compat0000644000175100017510000000000212706745114015102 0ustar ondrejondrej7 rapache-1.2.8/debian/control0000644000175100017510000000165612706745114015317 0ustar ondrejondrejSource: libapache2-mod-r-base Section: web Priority: optional Maintainer: Jeffrey Horner Build-Depends: debhelper (>= 4.2.20), lsb-release, apache2-dev, libapreq2-dev, r-base-core, r-base-dev Standards-Version: 3.7.2 Package: libapache2-mod-r-base Architecture: any Depends: apache2 | apache2.2-common, libapreq2-3 | libapreq2, r-base-core, ${shlibs:Depends} Description: Apache module for running server-side R programs This package provides the R module for the Apache 2 webserver. Note that it will work with either Apache's prefork or worker MPM. Prefork is preferred. . R is a language and environment for statistical computing and graphics. By embedding R inside Apache, developers can create dynamic web pages and graphics. Even more compelling is the ability for developers to provide web service style access to novel, cutting edge statistical techniques. . Homepage: http://www.rapache.net/ rapache-1.2.8/debian/dirs0000644000175100017510000000006312706745114014567 0ustar ondrejondrejusr/lib/apache2/modules etc/apache2/mods-available rapache-1.2.8/debian/install0000644000175100017510000000012412706745114015272 0ustar ondrejondrej.libs/mod_R.so usr/lib/apache2/modules debian/mod_R.load etc/apache2/mods-available rapache-1.2.8/debian/libapache2-mod-r-base.install0000644000175100017510000000012412706745114021207 0ustar ondrejondrej.libs/mod_R.so usr/lib/apache2/modules debian/mod_R.load etc/apache2/mods-available rapache-1.2.8/debian/libapache2-mod-r-base.postinst0000644000175100017510000000036312706745114021431 0ustar ondrejondrej#!/bin/sh set -e case "$1" in configure) : a2enmod mod_R ;; abort-upgrade | abort-remove | abort-deconfigure) : ;; *) echo "$0: didn't understand being called with \`$1'" 1>&2 exit 1;; esac #DEBHELPER# exit 0 rapache-1.2.8/debian/libapache2-mod-r-base.postrm0000644000175100017510000000045112706745114021070 0ustar ondrejondrej#! /bin/sh set -e case "$1" in remove) : a2dismod mod_R ;; purge | disappear | upgrade | failed-upgrade | abort-upgrade) : ;; abort-install) : a2dismod mod_R ;; *) echo "$0: didn't understand being called with \`$1'" 1>&2 exit 1;; esac #DEBHELPER# exit 0 rapache-1.2.8/debian/mod_R.load0000644000175100017510000000006612706745114015607 0ustar ondrejondrejLoadModule R_module /usr/lib/apache2/modules/mod_R.so rapache-1.2.8/debian/rules0000755000175100017510000000167612706745114014776 0ustar ondrejondrej#!/usr/bin/make -f # Uncomment this to turn on verbose mode. export DH_VERBOSE=1 PACKAGE=$(shell dh_listpackages) build: dh_testdir ./configure --with-R=/usr/bin/R --with-apache2-apxs=/usr/bin/apxs2 --with-apreq2-config=/usr/bin/apreq2-config if test -f /usr/bin/lsb_release -a `/usr/bin/lsb_release -cs` = "lucid"; then \ cp /usr/lib/libapreq2.la libapreq2.la~; \ sed -e "s/\/usr\/lib\/libuuid.la/-luuid/g;s/libdir='\/lib/libdir='\/usr\/lib/g" < libapreq2.la~ > libapreq2.la; \ fi; $(MAKE) clean: dh_testdir dh_testroot if [ -f Makefile ]; then $(MAKE) distclean; fi; dh_clean binary: binary-arch binary-indep binary-indep: binary-arch: build dh_testdir dh_testroot dh_clean -k dh_installdirs dh_install dh_installdocs dh_installchangelogs dh_link dh_strip dh_compress dh_fixperms dh_installdeb #dh_shlibdeps dh_gencontrol dh_md5sums dh_builddeb #dh_clean dh_prep .PHONY: build clean binary binary-arch binary-indep rapache-1.2.8/libapreq2/0000755000175100017510000000000012706745114014343 5ustar ondrejondrejrapache-1.2.8/libapreq2/CHANGES0000644000175100017510000005266012706745114015347 0ustar ondrejondrej/** @page apreq_changes CHANGES @brief List of major changes. @section v2_05_dev Changes with libapreq2-2.05-dev (released May 5, 2005) - Win32 build [Randy Kobes] Have top-level 'nmake', 'nmake test', and 'nmake install' targets, respectively, also include building, testing, and installing the corresponding perl glue targets. - C API [geoff] Minimum httpd version is now 2.0.48, which includes the official apr 0.9.4 release. - C API [Max Kellermann] Fix apreq_quote. - Perl API [joes] Remove Apache2::Request::args. WARNING: through inheritance, args() now maps to Apache2::RequestRec::args. Folks that want the pre-2.05-dev behavior need to invoke APR::Request::args by name. - C API [joes, Max Kellermann] Add apreq_initialize, apreq_pre_initialize and apreq_post_initialize. These are not thread-safe operations, so applications need to ensure they are invoked (in the correct sequence) prior to using any apreq2 modules. - C, Perl API [joes] Add pool, bucket_alloc to apreq_handle_t. - Perl API [joes] Drop $data argument from UPLOAD_HOOK, and also drop HOOK_DATA option. Perl folks should use a closure instead of passing in context data. - Perl API [joes] Move bake, bake2 to Apache2::Cookie, now requiring an extra $r argument. Also ""-operator is mapped to as_string() for Apache2::Cookie; but APR::Request::Cookie maps it to value(). - C API [joes] Remove header_in & header_out from apreq_module_t. Remove apreq_ua_cookie_version() and apreq_cookie_bake*(). Remove cookie2 argument to apreq_handle_custom(). - C API [joes] s/APREQ/APREQ2/g in webserver configuration directives. - C API [Igor Shevchenko, Philip Gollucci] Fix segfault in mfd parser caused by parts w/ empty param names. - C API [joes] Add apreq_cp1252_to_utf8(). - C, Perl API [joes] Add charset support for params and couple the SvUTF8 flag to the param's taint flag. - C API [joes] Replace v->size with v->nlen + v->dlen. Added supporting apreq_value_table_add(). - C API [joes] Remove apreq_cookie_attr(). - C API [joes] - Add apreq_error.h, apreq_module.h. - Rename apreq_run* and apreq_make* funcs to conform with apreq_$obj_$meth scheme. - Replace c->version & c->secure with flags. - Parsers are assumed to be working with external data, so the cookies & params they produce are marked tainted. - C API [joes] apreq_parse_cookie_header() failed to parse RFC Cookie headers which contained no space chars after the '$Version=1' preamble. - C API [joes] Reorganize around include/, library/, and module/ dirs. - C Tests [joes] Replace CuTest-based tests with custom TAP-compliant framework. - C API [Max Kellermann] Continue the API improvements: - Convert APREQ_RUN_PARSER and APREQ_RUN_HOOK to inline, and downcase them. - Remove apreq_memmem. - Convert apreq_(un)escape to inline. - apreq_escape does not create an apreq_value_t*. - Initialize default_parsers explicitly to NULL. - Convert APREQ_BRIGADE_COPY to inline, and downcase it. - Lowercase APREQ_BRIGADE_SETASIDE, APREQ_BRIGADE_COPY. - Convert apreq_cookie_name and apreq_cookie_value macros to inline. - Convert apreq_param_name, apreq_param_value, apreq_param_info, and apreq_param_brigade to inline. - C API [joes] Widespread API refactorization to remove apreq_jar_t and apreq_request_t: - Header includes reorganized; apreq_parsers.h added (back again). - Replaced apreq_jar_t and apreq_request_t with single apreq_env_handle_t. - Added const qualifier to "v" attribute of apreq_cookie_t and apreq_param_t. - Use union type-puns to drop const qualifiers inside the new apreq_value_to_cookie and apreq_value_to_param implementations (gcc generates same object code as the macro versions did). - Moved "flags" attribute from apreq_value_t to apreq_cookie_t and apreq_param_t. - Remove env argument from hooks and parsers. - Reduce apreq_env_module to minimal set of operations. - Replace apreq_log calls with apreq-specific error codes. - Hooks are called on each body param now, not just during file uploads. - Tie the cgi handle to its creator pool. Detailed changes by header file: [apreq.h] - Remove flags from apreq_value_t. - Remove const qualifier from apreq_value_t's "name" attribute. - Remove apreq_value_merge* and apreq_value_copy*. - Remove apreq_char_to_value, apreq_strtoval, and apreq_strlen. - Move apreq_enctype to apreq_env.h. - Move apreq_env_handle_t struct definition to apreq_env.h - Change signature of apreq_decode. - Move apreq_brigade_concat here, changed its signature and improved it alot. - Remove apreq_brigade_spoolfile. - Dropped APREQ_*_ENCTYPE, renamed some APREQ_$foo defaults APREQ_DEFAULT_$foo. - Added APREQ_ERROR_*. [apreq_cookie.h] - Remove apreq_env.h include. - Remove apreq_jar_t. - Add "flags" to apreq_cookie_t, add const qualifier to its "v" attr. - Remove apreq_jar* functions. - Add apreq_parse_cookie_header. - Move apreq_cookie, apreq_cookie_bake(2), and apreq_ua_cookie_version to apreq_env.h. [apreq_params.h] - Remove apreq_env.h include. - Remove apreq_request_t. - Add "flags" to apreq_param_t, and const qualifier to its "v" attr. - Rename "bb" attribute "upload" in apreq_param_t. - Remove apreq_request* functions. - Remove apreq_parse_request. - Changed apreq_decode_param signature. - Replace env argument with apr_table_t in apreq_params_as_array, apreq_params_as_string, - Move remaining apreq_param* to apreq_env.h. - Move parser and hook sections to apreq_parsers.h. - Change apreq_upload(s) old apreq_request_t arg to apr_table_t. [apreq_parsers.h] - Acquire the hook and parser sections of original apreq_params.h. - Remove env argument from APREQ_PARSER_ARGS and APREQ_HOOK_ARGS - Augment apreq_hook_t and apreq_parser_t to replace missing env features. - Change apreq_make_parser and apreq_make_hook signatures. - Rename apreq_add_hook to apreq_parser_add_hook, returning apr_status_t. - Change apreq_parser signature. [apreq_env.h] - Remove read, log, pool, bucket_alloc, request, jar, and query_string methods. - Include apreq_parsers.h. - Reorganize apreq_env_module_t to provide hook, parser, jar, args, & body table ops. - Rename max_brigade to "brigade_limit", max_body to "read_limit". - Change related module sigs, including temp_dir, to get/set methods. - Add parser and read_limit args to apreq_env_make_custom_handle. - Drop "name" arg and APREQ_ENV_MODULE =~ s/_ENV//. - s/apreq_env_make/apreq_handle/ in the handle constructor names. [mod_apreq.c, apreq_env_apache2.h] - Changed APREQ_Max* configs to APREQ_BrigadeLimit and APREQ_ReadLimit. - Handle constructor renamed apreq_handle_apache2. - C API [joes] Make our "libtool current interface" number depend on apr's major number. This allows libapreq2 to be installed into a system-wide location while avoiding ABI conflicts arising from our apr-based interfaces. - C API [Max Kellermann] Introduce apreq_env_handle_t to replace the void *env usage. Also added apreq_env_custom for making private handles, and new apreq_env_apache2.h to let mod_apreq export apreq_env_make_apache2. - C API [Max Kellermann] Rename apreq_env_t to apreq_env_module_t, to prepare for a new thread-safe apreq_env API. - C API [Max Kellermann] mod_apreq must check the return value of apreq_brigade_concat to avoid a RAM-consuming infinite loop. A bad APREQ_TempDir setting can cause this situation. - C API [joes] Provide workaround for chunked trailers bug in ap_http_filter. - C, Perl API [joes] Several upload-related bugfixes: 1) apreq_upload and apreq_uploads did not search the full body table, 2) $upload->slurp and $io->read did not autovivify the resultant string. - C API [joes] Add "flags" attribute to apreq_value_t, planning for charset support. This is an ABI change, starting with libapreq2.so.2.0.24. - C API [joes] Add apreq_env_bucket_alloc() to get an allocator directly from the environment instead of creating them from a pool. This is an ABI change, starting with libapreq2.so.2.0.23. - Build system [joes] Add --with-apache2-httpd option so users can override apxs's notion of where the httpd executable is. XSBuilder's header parser runs from buildconf now instead of configure, so we will include those tables in the release tarball. buildconf gets an additional --with-perl option for running the xsbuilder.pl parsing script. The XS generation code in xsbuilder.pl has moved to glue/perl/Makefile.PL. - Perl API [joes] Allow ctors for Apache::Cookie, Apache::Cookie::Jar and Apache:::Request to accept Apache::Request objects (instead of requiring an Apache::RequestRec object). This thread details the bug http://thread.gmane.org/gmane.comp.apache.mod-perl/15727 - C API [Bojan Smojver] Bake cookies with err_headers_out so they are sent on non-2xx server responses (ie. a 304 redirect). Also ensure that headers are copied with apr_table_add instead of apr_table_addn. Since apreq_cookie_bake() allocates from the stack, the Set-Cookie headers would occasionally get mangled without this patch. - C API [joes] Add apreq_register_parser(), which allows users to add their own parsers to apreq_parser()'s recognized MIME types. - C API [joes] Support "multipart/mixed" file uploads. Support XForms' "multipart/related" enctype. - C API [joes] Add apreq_hook_apr_xml_parser(), which is a simple wrapper hook around APR's expat-based apr_xml_parser. Add a generic parser apreq_parse_generic() to parse arbitrary enctypes using the hook API. @section v2_04_dev Changes with libapreq2-2.04-dev (released August 30, 2004) - Perl API [joes] Add TAINT checks, marking all parsed data as tainted. - C API [joes] Add body_status attribute to apreq_request_t, to allow the both environment and the parser to report any errors encountered. - C API [randyk, joes] Cookie parser was locking up on non-alphanumeric chars in cookie names. Also RFC Cookie attributes are always checked for quotes during bake(2), and the quotes are now stripped from incoming RFC cookies during parsing (but they are never stripped from the actual cookie value). - Perl API [joes] Apache::Cookie::Jar->new accepts a VALUE_CLASS argument, which effectively blesses all the jar's cookies into that class, which simplifies subclassing Apache::Cookie. Accordingly Apache::Cookie->freeze($value) no longer accepts a freeze()-able object in $value. - C API [Markus Wichitill, randyk, joes] Drop APR_DELONCLOSE from apreq_file_mktemp implementation and install apreq_file_cleanup. When passed to apr_file_open on Win32, APR_DELONCLOSE sets the FILE_SHARED_DELETE flag, which is, unfortunately, a property that is preserved across NTFS "hard" links. This breaks apps that link() the temp file to a permanent location, and subsequently expect to open it without FILE_SHARED_DELETE before the original tempfile is closed+deleted. In fact, even Apache::Upload does this, so it is a common enough event that the apreq_file_cleanup workaround is necessary. - C API [Ken Burcham, joes] Fix bug in url parser that occurs when a %XX-encoded sequence is split across multiple buckets. Added apreq_decode_decodev to make this problem less inconvenient. - Perl API [joes] Exception objects inherit from the object which raised it, which allows $@ to invoke its methods with impunity (exceptions are disabled for objects which derive from an exception class). - Perl API [joes] Implement HOOK_DATA and UPLOAD_HOOK. - Perl API [joes] Add safe XS wrappers for $table->add, $table->set, $table->STORE, and $table_class->new. - Perl API [joes] Add exceptions to $upload->link, $upload->tempname, $upload->slurp, and $cookie->set_attr. Return value of $upload->slurp is now the upload length. Also document new $upload->io. - C API [joes] Restrict all apr_status_t codes to APR_SUCCESS, APR_INCOMPLETE, APR_EGENERAL, APR_EINIT, APR_ENOTIMPL, since any others will generate confusing error messages from apr_strerror. - Perl API [joes] Added $upload->io with a TIEHANDLE API layered over APR::Brigade. $upload->fh remains implemented as an APR::PerlIO object, which is seekable but less efficient and currently suffers some portability issues associated with largefile support in perl and apr. - Perl API [joes] Added apreq_xs_croak for throwing APR::Error exceptions and included error-checking on $req->param, $req->args, $req->body, $req->upload, and $jar->get. - Perl API [joes] Added $jar->status, $req->args_status and $req->body_status to report parsing errors. Also add $upload->tempname per user request. - C API [joes] Dropped status attribute of apreq_value_t. Added status field to apreq_jar_t and added args_status field to apreq_request_t. Parsers also must return their public status code when a NULL brigade is passed. apreq_hook_disable_uploads() is also added. . This is an ABI change affecting all versions of libapreq2 prior to 2.0.12. - Perl API [joes] $upload->info returns a proper APR::Table object now. Also implemented $upload->size, $upload->fh, and $upload->type. - C API [Jean-François Meesse] mfd parser fails to parse CRLF-terminated files when the terminating boundary string is at the start of a new bucket. This is reportedly a common event for PDF files uploaded with Netscape 7. - Perl API [joes] Add back-compat support for Apache::Cookie->fetch() via Apache->request. - C API [joes] Add MaxBody, MaxBrigade, and TempDir per-dir directives to mod_apreq filter. - C API [joes] Replace free/tempnam dependency in apreq_file_mktemp() with apr_temp_dir_get(). Add additional gcc warning flags when --enable-maintainer-mode is set. - C API [joes, Scott Hutton] Replace apreq_brigade_copy with more effective APREQ_BRIGADE_COPY macro. Also introduce APREQ_BRIGADE_SETASIDE to deal with buckets that need to be set aside for use in future function calls. mod_ssl generates transient buckets which tickled this bug. - Perl API [joes] Separate Apache::Upload module from Apache::Request for better organization. @section v2_03_dev Changes with libapreq2-2.03-dev (released June 12, 2004) - C API [joes] "Objectify" cookie/jar API: s/apreq_(make|serialize)_cookie/apreq_cookie_$1/ and reordering args so the cookie/jar object is always the first argument. Macros added to provide source-compatibility with the old names. - Perl API [joes] Added $upload->slurp($data), which reads the contents of the file upload "$upload" into the scalar "$data". - C API [joes, randyk] apreq_run_(hook|parser) are macros, so they are capitalized now. Fixed apreq_params_as_string() and added apreq_params_as_array(). Reworked definitions of APREQ_DECLARE_HOOK, APREQ_DECLARE_PARSER and apreq_(parser|hook)_t, hopefully to be more Win32 friendly. Also updated the documentation. - C API [joes] Compensate for a missing CRLF in empty file upload block, which actually complies with RFC 2046 Section 5.1.1. Konqueror (version unknown) and Mozilla 0.9.7 are known to emit such blocks. - Perl API [joes] $req->upload() in list context failed to filter out non-uploads. Also $req->upload("nonexistent-key-name") segfaults. - Perl test suite t/TEST.PL must run parent class' pre_configure to get the configuration right - C API [joes] apreq_brigade_concat() wasn't supplying the final EOS bucket to large brigades (>256K), which somtimes caused the prefetch loop in mod_apreq.c's apreq_filter() to hang. - Documentation [joes] CHANGES file reformatted, removing dates & other clutter as Stas suggests. - C API [joes] Rewrote cgi_read() in apreq_env.c and reworked mod_apreq.c to enforce apreq_env_max_body() settings. - C API [joes] Fixed bug in url_parser code- missing context brigade was needed to track key-value pairs which span multiple buckets. - C API [joes] API modifications: removed struct apreq_cfg_t, adding new apreq_env hooks max_body, max_brigade_len, and temp_dir. Folded apreq_parsers.h into apreq_params.h and modified the arguments to apreq_run_parser() and apreq_run_hook(). Renamed apreq_parser_t's content_type as enctype and apreq_copy_brigade() as apreq_brigade_copy(). These changes make libapreq2.so.2.0.5 incompatible with earlier versions. - Perl API [stas] Include ppport.h from blead-perl to support older perls. Add a proper support for ithreads. - C API [Swen Schillig, joes] Fixed bug in calculation of Netscape cookie expiration dates. apr_time_t is measured in microseconds, not seconds, which threw off the arithmetic; apr_time_from_sec was needed for the conversion. - C API [Max Kellermann] Fix segfault caused by invalid %-escape sequence in query string. @section v2_02_dev Changes with libapreq2-2.02-dev (released Nov 15, 2003) - Perl API [joes] Fix bogus pool/cookie initializers in Apache::Cookie::set_attr(), which caused Apache::Cookie::new to segfault. Bug first reported to modperl list by Wolfgang Kubens. @section v2_01_dev Changes with libapreq2-2.01-dev (released Nov 10, 2003) - build system [joes] Skip Apache::Test tests in env/ when Apache::Test is unavailable. This allows the C API to be build and installed without requiring Apache::Test (it is still a requirement for compiling the perl glue). - C API mod_apreq.c [joes] Parser errors were creeping into the return value of apreq_filter, which breaks the "transparent tee" paradigm. This caused bogus "400 Bad Request" responses (first reported by Vladimir Dudo) to occur when libapreq2 was used by an output filter during a GET request (handled by apache2's default handler). The test suite has been updated accordingly. - C API [joes] Incorporate libapreq_cgi into libapreq2 as the default environment, and add apreq_env_t and initializer apreq_env_module() to manage the environment at runtime (determining the environment at load-time was problematic on non-ELF systems). @section v2_0_0 Changes with libapreq2-2.00-dev (Oct 25, 2003) - C API: libapreq_cgi.c [randyk, joes] CGI environment defined by env/libapreq_cgi.c is functional (with tests added to env/t). This library may soon be incorporated directly into libapreq2 as a default enviroment. - C API: mod_apreq.c [joes] Added ctx->saw_eos to ensure we don't read from upstream filters after receiving an eos bucket. Otherwise it was possible for two eos buckets to appear when a prefetch read is involved, which breaks other modules like mod_proxy. This bug was uncovered by Philippe Chiasson. mod_apreq's apreq_env_majic_number bumped to reflect the added fixes. - configure: --enable-perl-glue [joes] The --enable-perl-glue option integrates the perl glue into the normal Unix build cycle. It is disabled by default, but is silently reenabled if the user configures the source tree via Makefile.PL. - C API [joes] Added apreq_header_attribute() and fixed mfd parser to allow "charset" attribute to appear in the Content-Type header. Sven Geisler points out that Opera 7.20 does generate such headers. - C API [joes] Added versioning API following http://apr.apache.org/versioning.html apreq_env renamed apreq_env_name, and apreq_env_magic_number added to provide versioning for environments (modules). The header files are now installed to "include/apreq2", and the library is renamed "libapreq2". Also added an apreq2-config script based on apu-config. - configure: static mod_apreq.c [Bojan Smojver, joes] Add --with-apache2-src configure option, along with --with-apr-config and --with-apu-config, and provide support for compiling mod_apreq into httpd as a static apache module. - C API: mod_apreq.c [joes] Support for internal redirects added to the mod_apreq filter. This ensures any POST data prefetched in the main request gets passed along to the subrequest handler(s). - C bugfix: apreq_decode [Graham Clark] If the source and destination strings are represented by the same pointer - e.g. if called as apreq_unescape(s) - string s is modified incorrectly in general. Patch includes new unit test. - Perl API [joes] Added $req->parse, $req->status, & "preparse" logic to $req->param & $req->upload. - C API [joes] Added "preparse" logic to apreq_params & apreq_uploads to bring behavior in line with libapreq-1.x. - C API [joes] Dropped param->charset. Make apreq_brigade_concat public, so mod_apreq can use it for its ctx->spool brigade. - Documentation [joes] Updated Cookie_pod to reflect API changes over v1.X. - Documentation [joes] Added doxygen links to Apache::Request and Apache::Cookie perl docs. - C API [joes] Added apreq_copy_brigade(bb) to apreq.h. - C API [joes] The new filter-based design required a complete departure from libapreq-1.X codebase. libapreq-2 is based solely on APR, and to be fully functional, requires a supporting environment similar to Apache-2. A person wishing to port libapreq-2 to a new environment needs to provide definitions for the declarations in apreq_env.h. - Perl API [joes] Aggregates are always collected into an APR::Table-based package. New table packages: Apache::Cookie::Table, Apache::Request::Table, and Apache::Upload::Table. - Perl API [joes] Apache::Cookie->fetch now requires an "environment" argument ($r). Its return value is blessed into the Apache::Cookie::Jar class. - Perl API [joes] Two new request lookup functions: -# $req->args - param lookup using only the query string -# $req->body - param lookup using only the POST data **/ rapache-1.2.8/libapreq2/FAQ.pod0000644000175100017510000000207112706745114015456 0ustar ondrejondrej=head1 Issues during installation. [...] =head1 Using libapreq2 with Apache 2 and mod_perl 2. =head2 When I use Apache::Request in my output filter, it seems to lose the incoming POST variables. The problem is likely that the mod_apreq filter has not been added to the input filter chain in time to read the POST data. There are two solutions to this problem: 1) Write a filter init handler for you filter that instantiates an Apache::Request object. http://perl.apache.org/docs/2.0/api/Apache/Filter.html#C_FilterInitHandler_ 2) Use .htaccess or your server config to ensure the apreq input filter is active for this request with "AddInputFilter APREQ" or somesuch. We recommend using (1), and falling back to (2) until you get (1) working. =head2 When I try to upload a file, why do I get this error "[error] Can't locate .../Apache/Request/upload.al in @INC"? I is now a separate module in apreq2, so you need to C to load the C function. =head1 Using libapreq2 outside of Apache. [...] rapache-1.2.8/libapreq2/INSTALL0000644000175100017510000000454412706745114015403 0ustar ondrejondrejPREREQUISITES: Please see the PREREQUISITES file. If you are building httpd-apreq-2 directly from svn, you can generate the list of prerequisites: % perl build/version_check.pl INSTRUCTIONS: FreeBSD users must substitute "gmake" for "make" below. Unix build, where libtool/automake/autoconf works: % ./configure --with-apache2-apxs=/path/to/apache2/bin/apxs % make (optional)% make test % make install Or using the CPAN/perlish way (which includes the Apache::Request and Apache::Cookie modules): % perl Makefile.PL --with-apache2-apxs=/path/to/apache2/bin/apxs % make (optional)% make test % make install Developers and other folks using httpd-apreq-2 directly from svn need to execute "./buildconf" prior to running "./configure". Alternately, here's a recipe to install mod_apreq.c as a static apache module: 1) configure httpd to add mod_apreq.c to its filter modules: % cd /path/to/httpd-2.0 % CPPFLAGS=-I/path/to/httpd-apreq-2/src \ HTTPD_LDFLAGS=/path/to/httpd-apreq-2/src/libapreq2.la \ ./configure --with-module=filters:/path/to/httpd-apreq-2/env/mod_apreq.c \ ...(add usual httpd+apr options here)... 2) compile and install everything using httpd-apreq-2's build system: % cd /path/to/httpd-apreq-2 % ./configure --with-apache2-src=/path/to/httpd-2.0 % make (optional)% make test % make install Win32 build: C:\httpd-apreq-2> perl Makefile.PL C:\httpd-apreq-2> nmake C:\httpd-apreq-2> nmake test C:\httpd-apreq-2> nmake mod_apreq C:\httpd-apreq-2> nmake perl_glue C:\httpd-apreq-2> nmake perl_test SVN (Subversion) ACCESS Development of httpd-apreq-2 can be followed through the svn repository: $ svn checkout http://svn.apache.org/repos/asf/httpd/apreq/trunk/ httpd-apreq-2 Developers with commit access must use the https protocol instead; note that, if you are compiling svn from sources, you must supply the configure script with the appropriate switch to enable ssl. Subversion sources, and binaries for some platforms, may be obtained through the home page: http://subversion.tigris.org/ Documentation on using svn is available at http://svnbook.red-bean.com/ In particular, http://svnbook.red-bean.com/en/1.0/apa.html contains a guide for users familiar with cvs. rapache-1.2.8/libapreq2/LICENSE0000644000175100017510000002613612706745114015360 0ustar ondrejondrej Apache License Version 2.0, January 2004 http://www.apache.org/licenses/ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION 1. Definitions. "License" shall mean the terms and conditions for use, reproduction, and distribution as defined by Sections 1 through 9 of this document. "Licensor" shall mean the copyright owner or entity authorized by the copyright owner that is granting the License. "Legal Entity" shall mean the union of the acting entity and all other entities that control, are controlled by, or are under common control with that entity. For the purposes of this definition, "control" means (i) the power, direct or indirect, to cause the direction or management of such entity, whether by contract or otherwise, or (ii) ownership of fifty percent (50%) or more of the outstanding shares, or (iii) beneficial ownership of such entity. "You" (or "Your") shall mean an individual or Legal Entity exercising permissions granted by this License. "Source" form shall mean the preferred form for making modifications, including but not limited to software source code, documentation source, and configuration files. "Object" form shall mean any form resulting from mechanical transformation or translation of a Source form, including but not limited to compiled object code, generated documentation, and conversions to other media types. "Work" shall mean the work of authorship, whether in Source or Object form, made available under the License, as indicated by a copyright notice that is included in or attached to the work (an example is provided in the Appendix below). "Derivative Works" shall mean any work, whether in Source or Object form, that is based on (or derived from) the Work and for which the editorial revisions, annotations, elaborations, or other modifications represent, as a whole, an original work of authorship. For the purposes of this License, Derivative Works shall not include works that remain separable from, or merely link (or bind by name) to the interfaces of, the Work and Derivative Works thereof. "Contribution" shall mean any work of authorship, including the original version of the Work and any modifications or additions to that Work or Derivative Works thereof, that is intentionally submitted to Licensor for inclusion in the Work by the copyright owner or by an individual or Legal Entity authorized to submit on behalf of the copyright owner. For the purposes of this definition, "submitted" means any form of electronic, verbal, or written communication sent to the Licensor or its representatives, including but not limited to communication on electronic mailing lists, source code control systems, and issue tracking systems that are managed by, or on behalf of, the Licensor for the purpose of discussing and improving the Work, but excluding communication that is conspicuously marked or otherwise designated in writing by the copyright owner as "Not a Contribution." "Contributor" shall mean Licensor and any individual or Legal Entity on behalf of whom a Contribution has been received by Licensor and subsequently incorporated within the Work. 2. Grant of Copyright License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable copyright license to reproduce, prepare Derivative Works of, publicly display, publicly perform, sublicense, and distribute the Work and such Derivative Works in Source or Object form. 3. Grant of Patent License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable (except as stated in this section) patent license to make, have made, use, offer to sell, sell, import, and otherwise transfer the Work, where such license applies only to those patent claims licensable by such Contributor that are necessarily infringed by their Contribution(s) alone or by combination of their Contribution(s) with the Work to which such Contribution(s) was submitted. If You institute patent litigation against any entity (including a cross-claim or counterclaim in a lawsuit) alleging that the Work or a Contribution incorporated within the Work constitutes direct or contributory patent infringement, then any patent licenses granted to You under this License for that Work shall terminate as of the date such litigation is filed. 4. Redistribution. You may reproduce and distribute copies of the Work or Derivative Works thereof in any medium, with or without modifications, and in Source or Object form, provided that You meet the following conditions: (a) You must give any other recipients of the Work or Derivative Works a copy of this License; and (b) You must cause any modified files to carry prominent notices stating that You changed the files; and (c) You must retain, in the Source form of any Derivative Works that You distribute, all copyright, patent, trademark, and attribution notices from the Source form of the Work, excluding those notices that do not pertain to any part of the Derivative Works; and (d) If the Work includes a "NOTICE" text file as part of its distribution, then any Derivative Works that You distribute must include a readable copy of the attribution notices contained within such NOTICE file, excluding those notices that do not pertain to any part of the Derivative Works, in at least one of the following places: within a NOTICE text file distributed as part of the Derivative Works; within the Source form or documentation, if provided along with the Derivative Works; or, within a display generated by the Derivative Works, if and wherever such third-party notices normally appear. The contents of the NOTICE file are for informational purposes only and do not modify the License. You may add Your own attribution notices within Derivative Works that You distribute, alongside or as an addendum to the NOTICE text from the Work, provided that such additional attribution notices cannot be construed as modifying the License. You may add Your own copyright statement to Your modifications and may provide additional or different license terms and conditions for use, reproduction, or distribution of Your modifications, or for any such Derivative Works as a whole, provided Your use, reproduction, and distribution of the Work otherwise complies with the conditions stated in this License. 5. Submission of Contributions. Unless You explicitly state otherwise, any Contribution intentionally submitted for inclusion in the Work by You to the Licensor shall be under the terms and conditions of this License, without any additional terms or conditions. Notwithstanding the above, nothing herein shall supersede or modify the terms of any separate license agreement you may have executed with Licensor regarding such Contributions. 6. Trademarks. This License does not grant permission to use the trade names, trademarks, service marks, or product names of the Licensor, except as required for reasonable and customary use in describing the origin of the Work and reproducing the content of the NOTICE file. 7. Disclaimer of Warranty. Unless required by applicable law or agreed to in writing, Licensor provides the Work (and each Contributor provides its Contributions) on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied, including, without limitation, any warranties or conditions of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A PARTICULAR PURPOSE. You are solely responsible for determining the appropriateness of using or redistributing the Work and assume any risks associated with Your exercise of permissions under this License. 8. Limitation of Liability. In no event and under no legal theory, whether in tort (including negligence), contract, or otherwise, unless required by applicable law (such as deliberate and grossly negligent acts) or agreed to in writing, shall any Contributor be liable to You for damages, including any direct, indirect, special, incidental, or consequential damages of any character arising as a result of this License or out of the use or inability to use the Work (including but not limited to damages for loss of goodwill, work stoppage, computer failure or malfunction, or any and all other commercial damages or losses), even if such Contributor has been advised of the possibility of such damages. 9. Accepting Warranty or Additional Liability. While redistributing the Work or Derivative Works thereof, You may choose to offer, and charge a fee for, acceptance of support, warranty, indemnity, or other liability obligations and/or rights consistent with this License. However, in accepting such obligations, You may act only on Your own behalf and on Your sole responsibility, not on behalf of any other Contributor, and only if You agree to indemnify, defend, and hold each Contributor harmless for any liability incurred by, or claims asserted against, such Contributor by reason of your accepting any such warranty or additional liability. END OF TERMS AND CONDITIONS APPENDIX: How to apply the Apache License to your work. To apply the Apache License to your work, attach the following boilerplate notice, with the fields enclosed by brackets "[]" replaced with your own identifying information. (Don't include the brackets!) The text should be enclosed in the appropriate comment syntax for the file format. We also recommend that a file or class name and description of purpose be included on the same "printed page" as the copyright notice for easier identification within third-party archives. Copyright [yyyy] [name of copyright owner] Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. rapache-1.2.8/libapreq2/MANIFEST0000644000175100017510000002152012706745114015474 0ustar ondrejondrejacinclude.m4 aclocal.m4 apreq2-config.in build/announcement.pl build/dox.css build/dox.foot build/dox.head build/doxygen.conf build/doxygen.conf.in build/get-version.sh build/RELEASE build/version_check.pl build/WEBSITE build/xsbuilder.pl buildconf CHANGES config.guess config.sub configure configure.ac depcomp docs/apr.tag docs/apreq2.tag docs/apu.tag docs/html/annotated.html docs/html/apreq_8h-source.html docs/html/apreq_8h.html docs/html/apreq__cookie_8h-source.html docs/html/apreq__cookie_8h.html docs/html/apreq__error_8h-source.html docs/html/apreq__error_8h.html docs/html/apreq__module_8h-source.html docs/html/apreq__module_8h.html docs/html/apreq__module__apache2_8h-source.html docs/html/apreq__module__apache_8h-source.html docs/html/apreq__param_8h-source.html docs/html/apreq__param_8h.html docs/html/apreq__parser_8h-source.html docs/html/apreq__parser_8h.html docs/html/apreq__util_8h-source.html docs/html/apreq__util_8h.html docs/html/apreq__version_8h-source.html docs/html/apreq__version_8h.html docs/html/apreq_changes.html docs/html/apreq_faq.html docs/html/apreq_install.html docs/html/apreq_license.html docs/html/apreq_notice.html docs/html/apreq_status.html docs/html/dir_000000.html docs/html/dir_000001.html docs/html/dir_000002.html docs/html/dir_000003.html docs/html/dirs.html docs/html/dox.css docs/html/doxygen.png docs/html/feather.gif docs/html/files.html docs/html/functions.html docs/html/functions_rela.html docs/html/functions_vars.html docs/html/globals.html docs/html/globals_defs.html docs/html/globals_enum.html docs/html/globals_eval.html docs/html/globals_func.html docs/html/globals_type.html docs/html/group__apreq__lang.html docs/html/group__apreq__module.html docs/html/group__apreq__xs.html docs/html/group__apreq__xs__cookie.html docs/html/group__apreq__xs__request.html docs/html/group__apreq__xs__upload.html docs/html/group__libapreq2.html docs/html/group__mod__apreq2.html docs/html/index.html docs/html/installdox docs/html/modules.html docs/html/pages.html docs/html/structapreq__cookie__t.html docs/html/structapreq__handle__t.html docs/html/structapreq__hook__t.html docs/html/structapreq__module__t.html docs/html/structapreq__param__t.html docs/html/structapreq__parser__t.html docs/html/structapreq__value__t.html docs/html/todo.html docs/man/man3/_home_joe_src_apache_httpd_apreq_trunk_include_.3 docs/man/man3/_home_joe_src_apache_httpd_apreq_trunk_module_.3 docs/man/man3/_home_joe_src_apache_httpd_apreq_trunk_module_apache2_.3 docs/man/man3/_home_joe_src_apache_httpd_apreq_trunk_module_apache_.3 docs/man/man3/apreq.h.3 docs/man/man3/apreq_changes.3 docs/man/man3/apreq_cookie.h.3 docs/man/man3/apreq_cookie_t.3 docs/man/man3/apreq_error.h.3 docs/man/man3/apreq_faq.3 docs/man/man3/apreq_handle_t.3 docs/man/man3/apreq_hook_t.3 docs/man/man3/apreq_install.3 docs/man/man3/apreq_lang.3 docs/man/man3/apreq_license.3 docs/man/man3/apreq_module.3 docs/man/man3/apreq_module.h.3 docs/man/man3/apreq_module_t.3 docs/man/man3/apreq_notice.3 docs/man/man3/apreq_param.h.3 docs/man/man3/apreq_param_t.3 docs/man/man3/apreq_parser.h.3 docs/man/man3/apreq_parser_t.3 docs/man/man3/apreq_status.3 docs/man/man3/apreq_util.h.3 docs/man/man3/apreq_value_t.3 docs/man/man3/apreq_version.h.3 docs/man/man3/apreq_xs.3 docs/man/man3/apreq_xs_cookie.3 docs/man/man3/apreq_xs_request.3 docs/man/man3/apreq_xs_upload.3 docs/man/man3/libapreq2.3 docs/man/man3/mod_apreq2.3 docs/man/man3/todo.3 FAQ.pod glue/Makefile.am glue/Makefile.in glue/perl/docs/Cookie.pod glue/perl/docs/Error.pod glue/perl/docs/Request.pod glue/perl/docs/Table.pod glue/perl/docs/Upload.pod glue/perl/lib/Apache2/Cookie.pm glue/perl/lib/Apache2/Request.pm glue/perl/lib/Apache2/Upload.pm glue/perl/Makefile.PL glue/perl/README glue/perl/t/apreq/big_input.t glue/perl/t/apreq/cgi.t glue/perl/t/apreq/cookie.t glue/perl/t/apreq/inherit.t glue/perl/t/apreq/request.t glue/perl/t/apreq/upload.t glue/perl/t/conf/extra.conf.in glue/perl/t/REPORT glue/perl/t/response/TestAPI/cookie.pm glue/perl/t/response/TestAPI/error.pm glue/perl/t/response/TestAPI/module.pm glue/perl/t/response/TestAPI/param.pm glue/perl/t/response/TestApReq/big_input.pm glue/perl/t/response/TestApReq/cookie.pm glue/perl/t/response/TestApReq/inherit.pm glue/perl/t/response/TestApReq/request.pm glue/perl/t/response/TestApReq/upload.pm glue/perl/t/SMOKE glue/perl/t/TEST.PL glue/perl/t/TEST.PL.rej glue/perl/xsbuilder/APR/Request/Apache2/Apache2.pm glue/perl/xsbuilder/APR/Request/Apache2/Apache2.pod glue/perl/xsbuilder/APR/Request/Apache2/Apache2.xs glue/perl/xsbuilder/APR/Request/Apache2/APR__Request__Apache2.h glue/perl/xsbuilder/APR/Request/APR__Request.h glue/perl/xsbuilder/APR/Request/CGI/CGI.pm glue/perl/xsbuilder/APR/Request/CGI/CGI.pod glue/perl/xsbuilder/APR/Request/CGI/CGI.xs glue/perl/xsbuilder/APR/Request/Cookie/APR__Request__Cookie.h glue/perl/xsbuilder/APR/Request/Cookie/Cookie.pm glue/perl/xsbuilder/APR/Request/Cookie/Cookie.pod glue/perl/xsbuilder/APR/Request/Cookie/Cookie.xs glue/perl/xsbuilder/APR/Request/Error/APR__Request__Error.h glue/perl/xsbuilder/APR/Request/Error/Error.pm glue/perl/xsbuilder/APR/Request/Error/Error.pod glue/perl/xsbuilder/APR/Request/Error/Error.xs glue/perl/xsbuilder/APR/Request/Param/APR__Request__Param.h glue/perl/xsbuilder/APR/Request/Param/Param.pm glue/perl/xsbuilder/APR/Request/Param/Param.pod glue/perl/xsbuilder/APR/Request/Param/Param.xs glue/perl/xsbuilder/APR/Request/Request.pm glue/perl/xsbuilder/APR/Request/Request.pod glue/perl/xsbuilder/APR/Request/Request.xs glue/perl/xsbuilder/apreq_xs_postperl.h glue/perl/xsbuilder/apreq_xs_preperl.h glue/perl/xsbuilder/apreq_xs_tables.h glue/perl/xsbuilder/maps/apreq_functions.map glue/perl/xsbuilder/maps/apreq_structures.map glue/perl/xsbuilder/maps/apreq_types.map glue/perl/xsbuilder/ppport.h glue/perl/xsbuilder/tables/APR/Request/CallbackTable.pm glue/perl/xsbuilder/tables/APR/Request/ConstantsTable.pm glue/perl/xsbuilder/tables/APR/Request/FunctionTable.pm glue/perl/xsbuilder/tables/APR/Request/StructureTable.pm glue/perl/xsbuilder/typemap glue/README include/apreq.h include/apreq_config.h.in include/apreq_cookie.h include/apreq_error.h include/apreq_module.h include/apreq_param.h include/apreq_parser.h include/apreq_util.h include/apreq_version.h include/groups.dox.in include/Makefile.am include/Makefile.in INSTALL install-sh library/cookie.c library/error.c library/Makefile.am library/Makefile.in library/module.c library/module_cgi.c library/module_custom.c library/param.c library/parser.c library/parser_header.c library/parser_multipart.c library/parser_urlencoded.c library/t/.deps/at.Po library/t/.deps/cookie.Po library/t/.deps/error.Po library/t/.deps/params.Po library/t/.deps/parsers.Po library/t/.deps/util.Po library/t/.deps/version.Po library/t/at.c library/t/at.h library/t/cookie library/t/cookie.c library/t/cookie.t library/t/error library/t/error.c library/t/error.t library/t/Makefile.am library/t/Makefile.in library/t/params library/t/params.c library/t/params.t library/t/parsers library/t/parsers.c library/t/parsers.t library/t/util library/t/util.c library/t/util.t library/t/version library/t/version.c library/t/version.t library/util.c library/version.c LICENSE ltmain.sh Makefile.am Makefile.in Makefile.PL MANIFEST META.yml missing mkinstalldirs module/apache/.deps/command.Plo module/apache/.deps/handle.Plo module/apache/apreq_module_apache.h module/apache/apreq_private_apache.h module/apache/command.c module/apache/handle.c module/apache/Makefile.am module/apache/Makefile.in module/apache/t/c-modules/apreq_access_test/mod_apreq_access_test.c module/apache/t/c-modules/apreq_big_request_test/mod_apreq_big_request_test.c module/apache/t/c-modules/apreq_cookie_test/mod_apreq_cookie_test.c module/apache/t/c-modules/apreq_redirect_test/mod_apreq_redirect_test.c module/apache/t/c-modules/apreq_request_test/mod_apreq_request_test.c module/apache/t/TEST.PL module/apache2/apreq_module_apache2.h module/apache2/apreq_private_apache2.h module/apache2/filter.c module/apache2/handle.c module/apache2/Makefile.am module/apache2/Makefile.in module/Makefile.am module/Makefile.in module/t/big_request.t module/t/c-modules/apreq_access_test/mod_apreq_access_test.c module/t/c-modules/apreq_big_request_test/mod_apreq_big_request_test.c module/t/c-modules/apreq_cookie_test/mod_apreq_cookie_test.c module/t/c-modules/apreq_output_filter_test/mod_apreq_output_filter_test.c module/t/c-modules/apreq_redirect_test/mod_apreq_redirect_test.c module/t/c-modules/apreq_request_test/mod_apreq_request_test.c module/t/cgi.t module/t/conf/extra.conf.in module/t/conf/ssl/ca-bundle-duplicates.crt module/t/conf/ssl/ca-bundle-sample.crt module/t/conf/ssl/httpd-passphrase.pl.PL module/t/conf/ssl/proxyssl.conf.in module/t/conf/ssl/ssl.conf.in module/t/cookie.t module/t/request.t module/t/TEST.PL module/test_cgi.c NOTICE PREREQUISITES README win32/apreq2_test.mak win32/apreq2_win32.pl win32/Configure.pl win32/libapreq2.mak win32/mod_apreq2.mak win32/README win32/test_cgi.mak win32/util.pl rapache-1.2.8/libapreq2/META.yml0000644000175100017510000000145712706745114015623 0ustar ondrejondrej--- #YAML:1.0 (see http://module-build.sourceforge.net/META-spec.html) name: libapreq2 version: 2.05-dev license: open_source installdirs: site distribution_type: module dynamic_config: 1 provides: Apache2::Request: version: 2.05-dev Apache2::Cookie: version: 2.05-dev Apache2::Upload: version: 2.05-dev APR::Request: version: 2.05-dev APR::Request::Apache2: version: 2.05-dev APR::Request::CGI: version: 2.05-dev APR::Request::Error: version: 2.05-dev APR::Request::Cookie: version: 2.05-dev APR::Request::Param: version: 2.05-dev generated_by: build/version_check.pl requires: mod_perl: 1.999022 perl: 5.6.1 build_requires: Apache::Test: 1.04 ExtUtils::MakeMaker: 6.15 ExtUtils::XSBuilder: 0.23 Test::More: 0.47 mod_perl: 1.999022 perl: 5.6.1 rapache-1.2.8/libapreq2/Makefile.PL0000644000175100017510000000415312706745114016320 0ustar ondrejondrejrequire 5.006; use strict; use warnings; use Getopt::Long qw(GetOptions); use Config; use constant PERL_PATH => $Config{perlpath}; # XXX use constant WIN32 => ($^O =~ /Win32/); sub test_prereq { system (PERL_PATH, "build/version_check.pl", @_) == 0 or warn "Please upgrade $_[0] first.\n"; } test_prereq perl => PERL_PATH; my %opts; undef @opts{qw(with-apache2-apxs with-apache1-apxs with-apache2-src with-perl with-apache2-httpd with-apr-config with-apu-config apxs)}; undef $opts{'with-apache2'} if (WIN32); my @flags = qw/enable-maintainer-mode enable-perl-glue disable-perl-glue/; my %args; # grab from @ARGV only the options that we expect GetOptions(\%args, (map "$_=s", keys %opts), @flags); $args{"with-perl"} = PERL_PATH; my $opts = ""; $opts .= "--enable-maintainer-mode " if $args{"enable-maintainer-mode"}; unless (exists $args{"disable-perl-glue"}) { $opts .= "--enable-perl-glue "; test_prereq "mod_perl"; test_prereq "Apache::Test"; test_prereq "ExtUtils::MakeMaker"; test_prereq "ExtUtils::XSBuilder"; test_prereq "Test::More"; } delete @args{@flags}; $args{"with-apache2-apxs"} = delete $args{apxs} if exists $args{apxs} and not exists $args{"with-apache2-apxs"}; $args{"with-perl-opts"} = "@ARGV" if @ARGV; if (WIN32) { require File::Basename; unless ($args{'with-apache2'}) { my @candidates = qw(with-apache2-apxs with-apache2-httpd with-apr-config with-apu-config); foreach my $opt(@candidates) { next unless $args{$opt}; (my $d = File::Basename::dirname($args{$opt})) =~ s{(\\|/)bin}{}; if (-d $d) { delete $args{$opt}; $args{'with-apache2'} = $d; last; } } } my @opts = map{qq/--$_="$args{$_}"/} keys %args; my @args = (PERL_PATH, 'win32/Configure.pl', @opts); print "@args\n"; system(@args) == 0 or die "system @args failed: $?"; } else { $opts .= join " ", map {qq/--$_="$args{$_}"/} keys %args; my $cmd = "./configure $opts"; print "$cmd\n"; exec $cmd; } rapache-1.2.8/libapreq2/Makefile.am0000644000175100017510000000607112706745114016403 0ustar ondrejondrej# The following is a trick to get CPAN clients to follow prerequisites: # # PREREQ_PM # # --- MakeMaker post_initialize section: AUTOMAKE_OPTIONS = foreign SUBDIRS = . include library module glue EXTRA_DIST = LICENSE NOTICE README INSTALL CHANGES FAQ.pod MANIFEST.SKIP Makefile.PL buildconf build win32 docs APU_SRCDIR=`@APU_CONFIG@ --srcdir` APR_SRCDIR=`@APR_CONFIG@ --srcdir` APU_DOX = (cd $(APU_SRCDIR); cat docs/doxygen.conf - | doxygen -) APR_DOX = (cd $(APR_SRCDIR); cat docs/doxygen.conf - | doxygen -) SED_BODY_TAG= s(^[\S\s]+[\S\s]+$$)()gi, s(href="/Apache(?:/\w+)*/([^/]+).html")(href="group__apreq__xs__\L$$1.html")g EUM=ExtUtils::Manifest POD_DIR=glue/perl/lib/Apache2 bin_SCRIPTS = apreq2-config CLEANFILES = $(bin_SCRIPTS) if BUILD_PERL_GLUE PERL_TEST = perl_test else PERL_TEST = endif release: reconfig docs_clean docs distdir @PERL@ build/version_check.pl > $(distdir)/PREREQUISITES @PERL@ build/version_check.pl -version=@PACKAGE_VERSION@ > $(distdir)/META.yml echo MANIFEST > $(distdir)/MANIFEST @cd $(distdir); @PERL@ -M$(EUM) -e "$(EUM)::mkmanifest" @PERL@ -ple '$$_="$(distdir)/$$_"' $(distdir)/MANIFEST | tar -czf $(distdir).tar.gz -T - rm -rf $(distdir) @echo "Made $(distdir).tar.gz" release_test: -rm -rf $(distdir) tar xzvf $(distdir).tar.gz @cd $(distdir); @PERL@ -M$(EUM) -e "die 'Bogus MANIFEST' if $(EUM)::manicheck" @cd $(distdir); @PERL@ Makefile.PL -apxs @APACHE2_APXS@ && $(MAKE) test rm -rf $(distdir) @echo "$(distdir).tar.gz is kosher." reconfig: ./buildconf --with-automake=automake-1.6 --with-aclocal=aclocal-1.6 ./config.nice docs_clean: -rm -rf docs docs: pod2html build/doxygen.conf apr_tags docs/html/feather.gif @PERL@ build/version_check.pl doxygen doxygen build/doxygen.conf docs_install: docs @$(NORMAL_INSTALL) $(mkinstalldirs) $(DESTDIR)$(pkgdatadir) cp -a docs $(DESTDIR)$(pkgdatadir) %.html: $(POD_DIR)/%.pm Makefile.am pod2html < $< | perl -0777 -pe '$(SED_BODY_TAG)' > $@ pod2html :: Request.html Cookie.html Upload.html FAQ.html FAQ.html: Makefile.am FAQ.pod pod2html < FAQ.pod | perl -0777 -pe '$(SED_BODY_TAG)' > FAQ.html $(POD_DIR)/%.t: $(POD_DIR)/%.pod (cd glue/perl ; pod2test docs/$*.pod docs/$*.t) pod2test :: $(POD_DIR)/Request.t $(POD_DIR)/Cookie.t $(POD_DIR)/Upload.t $(POD_DIR)/Error.t $(POD_DIR)/Table.t apr_tags: docs/apr.tag docs/apu.tag docs/html/feather.gif: -mkdir docs -mkdir docs/html (cd docs/html; wget http://httpd.apache.org/docs-2.0/images/feather.gif) docs/apu.tag: -mkdir docs echo GENERATE_TAGFILE=`pwd`/docs/apu.tag | $(APU_DOX) docs/apr.tag: -mkdir docs echo GENERATE_TAGFILE=`pwd`/docs/apr.tag | $(APR_DOX) test: all library_test module_test $(PERL_TEST) module_test: cd module; $(MAKE) test library_test: cd library; $(MAKE) test perl_install: cd glue/perl; $(MAKE) install perl_test: cd glue/perl; $(MAKE) test perl_glue: cd glue/perl; @PERL@ ../../build/xsbuilder.pl run cd glue/perl; @PERL@ Makefile.PL -apxs @APACHE2_APXS@ cd glue/perl; $(MAKE) if BUILD_HTTPD install-exec-local: httpd_install httpd_install: cd @APACHE2_SRC@; $(MAKE) install endif rapache-1.2.8/libapreq2/Makefile.in0000644000175100017510000004367212706745114016424 0ustar ondrejondrej# Makefile.in generated by automake 1.6.3 from Makefile.am. # @configure_input@ # Copyright 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002 # 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@ # The following is a trick to get CPAN clients to follow prerequisites: # # PREREQ_PM => { Test::More=>q[0.47], ExtUtils::XSBuilder=>q[0.23], ExtUtils::MakeMaker=>q[6.15], Apache::Test=>q[1.04] } # # --- MakeMaker post_initialize section: SHELL = @SHELL@ srcdir = @srcdir@ top_srcdir = @top_srcdir@ VPATH = @srcdir@ prefix = @prefix@ exec_prefix = @exec_prefix@ bindir = @bindir@ sbindir = @sbindir@ libexecdir = @libexecdir@ datadir = @datadir@ sysconfdir = @sysconfdir@ sharedstatedir = @sharedstatedir@ localstatedir = @localstatedir@ libdir = @libdir@ infodir = @infodir@ mandir = @mandir@ includedir = @includedir@ oldincludedir = /usr/include pkgdatadir = $(datadir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ top_builddir = . ACLOCAL = @ACLOCAL@ AUTOCONF = @AUTOCONF@ AUTOMAKE = @AUTOMAKE@ AUTOHEADER = @AUTOHEADER@ am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd INSTALL = @INSTALL@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_DATA = @INSTALL_DATA@ install_sh_DATA = $(install_sh) -c -m 644 install_sh_PROGRAM = $(install_sh) -c install_sh_SCRIPT = $(install_sh) -c INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_HEADER = $(INSTALL_DATA) transform = @program_transform_name@ NORMAL_INSTALL = : PRE_INSTALL = : POST_INSTALL = : NORMAL_UNINSTALL = : PRE_UNINSTALL = : POST_UNINSTALL = : host_alias = @host_alias@ host_triplet = @host@ EXEEXT = @EXEEXT@ OBJEXT = @OBJEXT@ PATH_SEPARATOR = @PATH_SEPARATOR@ AMTAR = @AMTAR@ APACHE1_APXS = @APACHE1_APXS@ APACHE2_APXS = @APACHE2_APXS@ APACHE2_HTTPD = @APACHE2_HTTPD@ APACHE2_INCLUDES = @APACHE2_INCLUDES@ APACHE2_SRC = @APACHE2_SRC@ APREQ_CONFIG = @APREQ_CONFIG@ APREQ_DOTTED_VERSION = @APREQ_DOTTED_VERSION@ APREQ_LIBNAME = @APREQ_LIBNAME@ APREQ_LIBTOOL_VERSION = @APREQ_LIBTOOL_VERSION@ APREQ_MAJOR_VERSION = @APREQ_MAJOR_VERSION@ APR_CONFIG = @APR_CONFIG@ APR_INCLUDES = @APR_INCLUDES@ APR_LA = @APR_LA@ APR_LDFLAGS = @APR_LDFLAGS@ APR_LIBS = @APR_LIBS@ APR_LTFLAGS = @APR_LTFLAGS@ APU_CONFIG = @APU_CONFIG@ APU_LA = @APU_LA@ AR = @AR@ AS = @AS@ AWK = @AWK@ CC = @CC@ CXX = @CXX@ CXXCPP = @CXXCPP@ DEPDIR = @DEPDIR@ DLLTOOL = @DLLTOOL@ ECHO = @ECHO@ EGREP = @EGREP@ F77 = @F77@ GCJ = @GCJ@ GCJFLAGS = @GCJFLAGS@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ LIBTOOL = @LIBTOOL@ LN_S = @LN_S@ MAINT = @MAINT@ OBJDUMP = @OBJDUMP@ PACKAGE = @PACKAGE@ PERL = @PERL@ PERL_OPTS = @PERL_OPTS@ RANLIB = @RANLIB@ RC = @RC@ STRIP = @STRIP@ VERSION = @VERSION@ am__include = @am__include@ am__quote = @am__quote@ install_sh = @install_sh@ AUTOMAKE_OPTIONS = foreign SUBDIRS = . include library module glue EXTRA_DIST = LICENSE NOTICE README INSTALL CHANGES FAQ.pod MANIFEST.SKIP Makefile.PL buildconf build win32 docs APU_SRCDIR = `@APU_CONFIG@ --srcdir` APR_SRCDIR = `@APR_CONFIG@ --srcdir` APU_DOX = (cd $(APU_SRCDIR); cat docs/doxygen.conf - | doxygen -) APR_DOX = (cd $(APR_SRCDIR); cat docs/doxygen.conf - | doxygen -) SED_BODY_TAG = s(^[\S\s]+[\S\s]+$$)()gi, s(href="/Apache(?:/\w+)*/([^/]+).html")(href="group__apreq__xs__\L$$1.html")g EUM = ExtUtils::Manifest POD_DIR = glue/perl/lib/Apache2 bin_SCRIPTS = apreq2-config CLEANFILES = $(bin_SCRIPTS) @BUILD_PERL_GLUE_TRUE@PERL_TEST = perl_test @BUILD_PERL_GLUE_FALSE@PERL_TEST = subdir = . ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs CONFIG_HEADER = $(top_builddir)/include/apreq_config.h CONFIG_CLEAN_FILES = build/doxygen.conf apreq2-config SCRIPTS = $(bin_SCRIPTS) DIST_SOURCES = RECURSIVE_TARGETS = info-recursive dvi-recursive install-info-recursive \ uninstall-info-recursive all-recursive install-data-recursive \ install-exec-recursive installdirs-recursive install-recursive \ uninstall-recursive check-recursive installcheck-recursive DIST_COMMON = README INSTALL Makefile.am Makefile.in acinclude.m4 \ aclocal.m4 apreq2-config.in config.guess config.sub configure \ configure.ac depcomp install-sh ltmain.sh missing mkinstalldirs DIST_SUBDIRS = $(SUBDIRS) all: all-recursive .SUFFIXES: am__CONFIG_DISTCLEAN_FILES = config.status config.cache config.log \ configure.lineno $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ Makefile.am $(top_srcdir)/configure.ac $(ACLOCAL_M4) cd $(top_srcdir) && \ $(AUTOMAKE) --foreign Makefile Makefile: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.in $(top_builddir)/config.status cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe) $(top_builddir)/config.status: $(srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) $(SHELL) ./config.status --recheck $(srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(srcdir)/configure.ac $(ACLOCAL_M4) $(CONFIGURE_DEPENDENCIES) cd $(srcdir) && $(AUTOCONF) $(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ configure.ac acinclude.m4 cd $(srcdir) && $(ACLOCAL) $(ACLOCAL_AMFLAGS) build/doxygen.conf: $(top_builddir)/config.status $(top_srcdir)/build/doxygen.conf.in cd $(top_builddir) && $(SHELL) ./config.status $@ apreq2-config: $(top_builddir)/config.status apreq2-config.in cd $(top_builddir) && $(SHELL) ./config.status $@ binSCRIPT_INSTALL = $(INSTALL_SCRIPT) install-binSCRIPTS: $(bin_SCRIPTS) @$(NORMAL_INSTALL) $(mkinstalldirs) $(DESTDIR)$(bindir) @list='$(bin_SCRIPTS)'; for p in $$list; do \ if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ if test -f $$d$$p; then \ f=`echo "$$p" | sed 's|^.*/||;$(transform)'`; \ echo " $(binSCRIPT_INSTALL) $$d$$p $(DESTDIR)$(bindir)/$$f"; \ $(binSCRIPT_INSTALL) $$d$$p $(DESTDIR)$(bindir)/$$f; \ else :; fi; \ done uninstall-binSCRIPTS: @$(NORMAL_UNINSTALL) @list='$(bin_SCRIPTS)'; for p in $$list; do \ f=`echo "$$p" | sed 's|^.*/||;$(transform)'`; \ echo " rm -f $(DESTDIR)$(bindir)/$$f"; \ rm -f $(DESTDIR)$(bindir)/$$f; \ done mostlyclean-libtool: -rm -f *.lo clean-libtool: -rm -rf .libs _libs distclean-libtool: -rm -f libtool uninstall-info-am: # 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): @set fnord $$MAKEFLAGS; amf=$$2; \ dot_seen=no; \ target=`echo $@ | sed s/-recursive//`; \ list='$(SUBDIRS)'; for subdir in $$list; do \ echo "Making $$target in $$subdir"; \ if test "$$subdir" = "."; then \ dot_seen=yes; \ local_target="$$target-am"; \ else \ local_target="$$target"; \ fi; \ (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \ || case "$$amf" in *=*) exit 1;; *k*) fail=yes;; *) exit 1;; esac; \ done; \ if test "$$dot_seen" = "no"; then \ $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \ fi; test -z "$$fail" mostlyclean-recursive clean-recursive distclean-recursive \ maintainer-clean-recursive: @set fnord $$MAKEFLAGS; amf=$$2; \ dot_seen=no; \ case "$@" in \ distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \ *) list='$(SUBDIRS)' ;; \ esac; \ rev=''; for subdir in $$list; do \ if test "$$subdir" = "."; then :; else \ rev="$$subdir $$rev"; \ fi; \ done; \ rev="$$rev ."; \ target=`echo $@ | sed s/-recursive//`; \ for subdir in $$rev; do \ echo "Making $$target in $$subdir"; \ if test "$$subdir" = "."; then \ local_target="$$target-am"; \ else \ local_target="$$target"; \ fi; \ (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \ || case "$$amf" in *=*) exit 1;; *k*) fail=yes;; *) exit 1;; esac; \ done && test -z "$$fail" tags-recursive: list='$(SUBDIRS)'; for subdir in $$list; do \ test "$$subdir" = . || (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) tags); \ done ETAGS = etags ETAGSFLAGS = tags: TAGS 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; } \ END { for (i in files) print i; }'`; \ mkid -fID $$unique TAGS: tags-recursive $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ $(TAGS_FILES) $(LISP) tags=; \ here=`pwd`; \ list='$(SUBDIRS)'; for subdir in $$list; do \ if test "$$subdir" = .; then :; else \ test -f $$subdir/TAGS && tags="$$tags -i $$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; } \ END { for (i in files) print i; }'`; \ test -z "$(ETAGS_ARGS)$$tags$$unique" \ || $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ $$tags $$unique GTAGS: here=`$(am__cd) $(top_builddir) && pwd` \ && cd $(top_srcdir) \ && gtags -i $(GTAGS_ARGS) $$here distclean-tags: -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) top_distdir = . distdir = $(PACKAGE)-$(VERSION) am__remove_distdir = \ { test ! -d $(distdir) \ || { find $(distdir) -type d ! -perm -200 -exec chmod u+w {} ';' \ && rm -fr $(distdir); }; } GZIP_ENV = --best distcleancheck_listfiles = find . -type f -print distdir: $(DISTFILES) $(am__remove_distdir) mkdir $(distdir) $(mkinstalldirs) $(distdir)/. $(distdir)/build $(distdir)/include @list='$(DISTFILES)'; for file in $$list; do \ if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ dir=`echo "$$file" | sed -e 's,/[^/]*$$,,'`; \ if test "$$dir" != "$$file" && test "$$dir" != "."; then \ dir="/$$dir"; \ $(mkinstalldirs) "$(distdir)$$dir"; \ else \ dir=''; \ fi; \ if test -d $$d/$$file; then \ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \ fi; \ cp -pR $$d/$$file $(distdir)$$dir || exit 1; \ else \ test -f $(distdir)/$$file \ || cp -p $$d/$$file $(distdir)/$$file \ || exit 1; \ fi; \ done list='$(SUBDIRS)'; for subdir in $$list; do \ if test "$$subdir" = .; then :; else \ test -d $(distdir)/$$subdir \ || mkdir $(distdir)/$$subdir \ || exit 1; \ (cd $$subdir && \ $(MAKE) $(AM_MAKEFLAGS) \ top_distdir="$(top_distdir)" \ distdir=../$(distdir)/$$subdir \ distdir) \ || exit 1; \ fi; \ done -find $(distdir) -type d ! -perm -777 -exec chmod a+rwx {} \; -o \ ! -type d ! -perm -444 -links 1 -exec chmod a+r {} \; -o \ ! -type d ! -perm -400 -exec chmod a+r {} \; -o \ ! -type d ! -perm -444 -exec $(SHELL) $(install_sh) -c -m a+r {} {} \; \ || chmod -R a+r $(distdir) dist-gzip: distdir $(AMTAR) chof - $(distdir) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz $(am__remove_distdir) dist dist-all: distdir $(AMTAR) chof - $(distdir) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz $(am__remove_distdir) # This target untars the dist file and tries a VPATH configuration. Then # it guarantees that the distribution is self-contained by making another # tarfile. distcheck: dist $(am__remove_distdir) GZIP=$(GZIP_ENV) gunzip -c $(distdir).tar.gz | $(AMTAR) xf - chmod -R a-w $(distdir); chmod a+w $(distdir) mkdir $(distdir)/=build mkdir $(distdir)/=inst chmod a-w $(distdir) dc_install_base=`$(am__cd) $(distdir)/=inst && pwd` \ && cd $(distdir)/=build \ && ../configure --srcdir=.. --prefix=$$dc_install_base \ $(DISTCHECK_CONFIGURE_FLAGS) \ && $(MAKE) $(AM_MAKEFLAGS) \ && $(MAKE) $(AM_MAKEFLAGS) dvi \ && $(MAKE) $(AM_MAKEFLAGS) check \ && $(MAKE) $(AM_MAKEFLAGS) install \ && $(MAKE) $(AM_MAKEFLAGS) installcheck \ && $(MAKE) $(AM_MAKEFLAGS) uninstall \ && (test `find $$dc_install_base -type f -print | wc -l` -le 1 \ || { echo "ERROR: files left after uninstall:" ; \ find $$dc_install_base -type f -print ; \ exit 1; } >&2 ) \ && $(MAKE) $(AM_MAKEFLAGS) dist-gzip \ && rm -f $(distdir).tar.gz \ && $(MAKE) $(AM_MAKEFLAGS) distcleancheck $(am__remove_distdir) @echo "$(distdir).tar.gz is ready for distribution" | \ sed 'h;s/./=/g;p;x;p;x' distcleancheck: distclean if test '$(srcdir)' = . ; then \ echo "ERROR: distcleancheck can only run from a VPATH build" ; \ exit 1 ; \ fi test `$(distcleancheck_listfiles) | wc -l` -eq 0 \ || { echo "ERROR: files left after distclean:" ; \ $(distcleancheck_listfiles) ; \ exit 1; } >&2 check-am: all-am check: check-recursive all-am: Makefile $(SCRIPTS) installdirs: installdirs-recursive installdirs-am: $(mkinstalldirs) $(DESTDIR)$(bindir) 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_STRIP_FLAG=-s \ `test -z '$(STRIP)' || \ echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install mostlyclean-generic: clean-generic: -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES) distclean-generic: -rm -f Makefile $(CONFIG_CLEAN_FILES) maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." clean: clean-recursive clean-am: clean-generic clean-libtool mostlyclean-am distclean: distclean-recursive -rm -f $(am__CONFIG_DISTCLEAN_FILES) distclean-am: clean-am distclean-generic distclean-libtool \ distclean-tags dvi: dvi-recursive dvi-am: info: info-recursive info-am: install-data-am: install-exec-am: install-binSCRIPTS install-exec-local install-info: install-info-recursive install-man: installcheck-am: maintainer-clean: maintainer-clean-recursive -rm -f $(am__CONFIG_DISTCLEAN_FILES) -rm -rf autom4te.cache maintainer-clean-am: distclean-am maintainer-clean-generic mostlyclean: mostlyclean-recursive mostlyclean-am: mostlyclean-generic mostlyclean-libtool uninstall-am: uninstall-binSCRIPTS uninstall-info-am uninstall-info: uninstall-info-recursive .PHONY: $(RECURSIVE_TARGETS) GTAGS all all-am check check-am clean \ clean-generic clean-libtool clean-recursive dist dist-all \ dist-gzip distcheck distclean distclean-generic \ distclean-libtool distclean-recursive distclean-tags \ distcleancheck distdir dvi dvi-am dvi-recursive info info-am \ info-recursive install install-am install-binSCRIPTS \ install-data install-data-am install-data-recursive \ install-exec install-exec-am install-exec-local \ install-exec-recursive install-info install-info-am \ install-info-recursive install-man install-recursive \ install-strip installcheck installcheck-am installdirs \ installdirs-am installdirs-recursive maintainer-clean \ maintainer-clean-generic maintainer-clean-recursive mostlyclean \ mostlyclean-generic mostlyclean-libtool mostlyclean-recursive \ tags tags-recursive uninstall uninstall-am uninstall-binSCRIPTS \ uninstall-info-am uninstall-info-recursive uninstall-recursive release: reconfig docs_clean docs distdir @PERL@ build/version_check.pl > $(distdir)/PREREQUISITES @PERL@ build/version_check.pl -version=@PACKAGE_VERSION@ > $(distdir)/META.yml echo MANIFEST > $(distdir)/MANIFEST @cd $(distdir); @PERL@ -M$(EUM) -e "$(EUM)::mkmanifest" @PERL@ -ple '$$_="$(distdir)/$$_"' $(distdir)/MANIFEST | tar -czf $(distdir).tar.gz -T - rm -rf $(distdir) @echo "Made $(distdir).tar.gz" release_test: -rm -rf $(distdir) tar xzvf $(distdir).tar.gz @cd $(distdir); @PERL@ -M$(EUM) -e "die 'Bogus MANIFEST' if $(EUM)::manicheck" @cd $(distdir); @PERL@ Makefile.PL -apxs @APACHE2_APXS@ && $(MAKE) test rm -rf $(distdir) @echo "$(distdir).tar.gz is kosher." reconfig: ./buildconf --with-automake=automake-1.6 --with-aclocal=aclocal-1.6 ./config.nice docs_clean: -rm -rf docs docs: pod2html build/doxygen.conf apr_tags docs/html/feather.gif @PERL@ build/version_check.pl doxygen doxygen build/doxygen.conf docs_install: docs @$(NORMAL_INSTALL) $(mkinstalldirs) $(DESTDIR)$(pkgdatadir) cp -a docs $(DESTDIR)$(pkgdatadir) %.html: $(POD_DIR)/%.pm Makefile.am pod2html < $< | perl -0777 -pe '$(SED_BODY_TAG)' > $@ pod2html :: Request.html Cookie.html Upload.html FAQ.html FAQ.html: Makefile.am FAQ.pod pod2html < FAQ.pod | perl -0777 -pe '$(SED_BODY_TAG)' > FAQ.html $(POD_DIR)/%.t: $(POD_DIR)/%.pod (cd glue/perl ; pod2test docs/$*.pod docs/$*.t) pod2test :: $(POD_DIR)/Request.t $(POD_DIR)/Cookie.t $(POD_DIR)/Upload.t $(POD_DIR)/Error.t $(POD_DIR)/Table.t apr_tags: docs/apr.tag docs/apu.tag docs/html/feather.gif: -mkdir docs -mkdir docs/html (cd docs/html; wget http://httpd.apache.org/docs-2.0/images/feather.gif) docs/apu.tag: -mkdir docs echo GENERATE_TAGFILE=`pwd`/docs/apu.tag | $(APU_DOX) docs/apr.tag: -mkdir docs echo GENERATE_TAGFILE=`pwd`/docs/apr.tag | $(APR_DOX) test: all library_test module_test $(PERL_TEST) module_test: cd module; $(MAKE) test library_test: cd library; $(MAKE) test perl_install: cd glue/perl; $(MAKE) install perl_test: cd glue/perl; $(MAKE) test perl_glue: cd glue/perl; @PERL@ ../../build/xsbuilder.pl run cd glue/perl; @PERL@ Makefile.PL -apxs @APACHE2_APXS@ cd glue/perl; $(MAKE) @BUILD_HTTPD_TRUE@install-exec-local: httpd_install @BUILD_HTTPD_TRUE@httpd_install: @BUILD_HTTPD_TRUE@ cd @APACHE2_SRC@; $(MAKE) install # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. .NOEXPORT: rapache-1.2.8/libapreq2/NOTICE0000644000175100017510000000014512706745114015247 0ustar ondrejondrejThis product includes software developed by The Apache Software Foundation (http://www.apache.org/). rapache-1.2.8/libapreq2/PREREQUISITES0000644000175100017510000000175612706745114016343 0ustar ondrejondrej================================================== Build system (core C API) prerequisites apache2: 2.0.48 apr: 0.9.4 (bundled with apache2 2.0.48) apu: 0.9.4 (bundled with apache2 2.0.48) perl: 5.6.1 ================================================== Perl glue (Apache::Request) prerequisites Apache::Test: 1.04 (Win32 requires version 1.06) ExtUtils::MakeMaker: 6.15 ExtUtils::XSBuilder: 0.23 Test::More: 0.47 mod_perl: 1.999022 perl: 5.6.1 ================================================== Additional prerequisites for apreq subversion builds ExtUtils::XSBuilder: 0.23 autoconf: 2.53 automake: 1.6.0 doxygen: 1.2 libtool: 1.4.3 perl: 5.6.1 rapache-1.2.8/libapreq2/README0000644000175100017510000000637012706745114015231 0ustar ondrejondrej Apache HTTP Server Request Library What is it? ----------- httpd-apreq is subproject of the Apache HTTP Server Project whose committers develop and maintain the libapreq C library and its language bindings for Perl (contributions for additional language bindings are most welcome). libapreq is a safe, standards-compliant, high-performance library used for parsing HTTP cookies, query-strings and POST data. The original version (libapreq-1.X) was designed by Lincoln Stein and Doug MacEachern. The perl APIs Apache::Request and Apache::Cookie are the lightweight mod_perl analogs of the CGI and CGI::Cookie perl modules. Version 2 of libapreq is an improved codebase designed around APR and Apache-2's input filter API. The C codebase is separated into two independent components: 1) libapreq2, a shared library which is based on libapr and libaprutil. 2) A collection of modules: - mod_apreq2, a filter module for the Apache 2.X webserver, - a CGI module included in libapreq2 itself, - a custom module for general applications. Version 2 also includes the perl APIs for libapreq2- Apache2::Request, Apache2::Upload and Apache2::Cookie. The corresponding XS modules are generated by ExtUtils::XSBuilder, which is based on the new build system created specifically for mod_perl2. The Latest Version ------------------ Details of the latest version can be found on the libapreq project page at http://httpd.apache.org/apreq Documentation ------------- The documentation is in the docs/ directory. It is based on Doxygen, and can be regenerated by typing % make docs in the main directory. Installation ------------ For full details please consult the INSTALL file. Briefly, to install just the C API (libapreq2 + environment modules) on a Unix-like system: % ./configure --with-apache2-apxs=/path/to/apache2/bin/apxs % make % make test % make install To build and install the perl API as well, either add the "--enable-perl-glue" configure option, or let Makefile.PL enable it for you: % perl Makefile.PL --with-apache2-apxs=/path/to/apache2/bin/apxs % make % make test % make install Licensing --------- Please see the file called LICENSE. Contacts -------- o Project homepage: http://httpd.apache.org/apreq/ o Mailing Lists: user lists: C/C++ API - modules@apache.org Perl API - modperl@perl.apache.org Tcl API - XXX Java API - XXX Python API - XXX developer list (bugs, patches, code contributions, etc.): apreq-dev@httpd.apache.org Acknowledgments ---------------- We wish to acknowledge the following copyrighted works that make up portions of the Apache software: libapreq2 relies heavily on the use of the GNU auto-tools to provide a build environment. The tests are based on the Apache::Test, Test::Harness and Test::Inline. Doxygen generates the documentation for libapreq2. The perl glue and pods are generated by ExtUtils::XSBuilder. rapache-1.2.8/libapreq2/acinclude.m40000644000175100017510000002636312706745114016546 0ustar ondrejondrejAC_DEFUN([AC_APREQ], [ AC_ARG_ENABLE(profile, AC_HELP_STRING([--enable-profile],[compile libapreq2 with "-pg -fprofile-arcs -ftest-coverage" for gcov/gprof]), [PROFILE=$enableval],[PROFILE="no"]) AC_ARG_ENABLE(perl_glue, AC_HELP_STRING([--enable-perl-glue],[build perl modules Apache::Request and Apache::Cookie]), [PERL_GLUE=$enableval],[PERL_GLUE="no"]) AC_ARG_WITH(perl, AC_HELP_STRING([--with-perl],[path to perl executable]), [PERL=$withval],[PERL="perl"]) AC_ARG_WITH(apache2-apxs, AC_HELP_STRING([--with-apache2-apxs],[path to apache2's apxs]), [APACHE2_APXS=$withval],[APACHE2_APXS="apxs"]) AC_ARG_WITH(apache2-src, AC_HELP_STRING([--with-apache2-src],[path to httpd source]), [APACHE2_SRC=$withval],[APACHE2_SRC=""]) AC_ARG_WITH(apache2-httpd, AC_HELP_STRING([--with-apache2-httpd],[path to httpd binary]), [APACHE2_HTTPD=$withval],[APACHE2_HTTPD=""]) AC_ARG_WITH(apr-config, AC_HELP_STRING([ --with-apr-config],[path to apr-*-config script]), [APR_CONFIG=$withval],[APR_CONFIG=""]) AC_ARG_WITH(apu-config, AC_HELP_STRING([ --with-apu-config],[path to apu-*-config script]), [APU_CONFIG=$withval],[APU_CONFIG=""]) AC_ARG_WITH(apache1-apxs, AC_HELP_STRING([--with-apache1-apxs],[path to apache1's apxs]), [APACHE1_APXS=$withval],[APACHE1_APXS=""]) AC_ARG_WITH(perl-opts, AC_HELP_STRING([--with-perl-opts],[extra MakeMaker options]), [PERL_OPTS=$withval],[PERL_OPTS=""]) AC_ARG_WITH(expat, AC_HELP_STRING([--with-expat],[specify expat location]), [EXPAT_DIR=$withval],[EXPAT_DIR=""]) prereq_check="$PERL build/version_check.pl" if test -n "$APACHE2_SRC"; then # no apxs: must compile httpd from source APACHE2_SRC=`cd $APACHE2_SRC;pwd` AC_CHECK_FILE([$APACHE2_SRC/include/httpd.h],, AC_MSG_ERROR([invalid Apache2 source directory])) APACHE2_INCLUDES=-I$APACHE2_SRC/include if test -z "$APR_CONFIG"; then APR_CONFIG="$APACHE2_SRC/srclib/apr/apr-config" fi if test -z "$APU_CONFIG"; then APU_CONFIG="$APACHE2_SRC/srclib/apr-util/apu-config" fi APACHE2_HTTPD=$APACHE2_SRC/httpd else # have apxs: use it APACHE2_INCLUDES=-I`$APACHE2_APXS -q INCLUDEDIR` APR_MAJOR_VERSION=`$APACHE2_APXS -q APR_VERSION 2>/dev/null | cut -d. -f 1` if test ${APR_MAJOR_VERSION:="0"} -eq 0; then apr_config=apr-config apu_config=apu-config apreq_libs="-lapr -laprutil" else apr_config=apr-$APR_MAJOR_VERSION-config apu_config=apu-$APR_MAJOR_VERSION-config apreq_libs="-lapr-$APR_MAJOR_VERSION -laprutil-$APR_MAJOR_VERSION" fi if test -z "$APR_CONFIG"; then APR_CONFIG=`$APACHE2_APXS -q APR_BINDIR`/$apr_config fi if test -z "$APU_CONFIG"; then APU_CONFIG=`$APACHE2_APXS -q APU_BINDIR`/$apu_config fi if test -z "$APACHE2_HTTPD"; then APACHE2_HTTPD=`$APACHE2_APXS -q SBINDIR`/`$APACHE2_APXS -q progname` fi if test -z "`$prereq_check apache2 $APACHE2_HTTPD`"; then AC_MSG_ERROR([Bad apache2 binary ($APACHE2_HTTPD)]) fi fi AC_CHECK_FILE([$APR_CONFIG],, AC_MSG_ERROR([invalid apr-config location ($APR_CONFIG)- did you forget to configure apr?])) if test -z "`$prereq_check apr $APR_CONFIG`"; then AC_MSG_ERROR([Bad libapr version]) fi AC_CHECK_FILE([$APU_CONFIG],, AC_MSG_ERROR([invalid apu-config location ($APU_CONFIG)- did you forget to configure apr-util?])) if test -z "`$prereq_check apu $APU_CONFIG`"; then AC_MSG_ERROR([Bad libaprutil version]) fi if test "x$PERL_GLUE" != "xno"; then AC_MSG_CHECKING(for perl) if test -z "`$prereq_check perl $PERL`"; then AC_MSG_ERROR([Bad perl version]) fi AC_MSG_RESULT($PERL) AC_MSG_CHECKING(for ExtUtils::XSBuilder) if test -z "`$prereq_check ExtUtils::XSBuilder`"; then AC_MSG_WARN([Bad ExtUtils::XSBuilder version]) fi AC_MSG_RESULT(yes) AC_MSG_CHECKING(for mod_perl) if test -z "`$prereq_check mod_perl`"; then AC_MSG_WARN([Bad mod_perl version]) fi AC_MSG_RESULT(yes) AC_MSG_CHECKING(for Apache::Test) if test -z "`$prereq_check Apache::Test`"; then AC_MSG_WARN([Bad Apache::Test version]) fi AC_MSG_RESULT(yes) AC_MSG_CHECKING(for ExtUtils::MakeMaker) if test -z "`$prereq_check ExtUtils::MakeMaker`"; then AC_MSG_WARN([Bad ExtUtils::MakeMaker version]) fi AC_MSG_RESULT(yes) fi AM_CONDITIONAL(ENABLE_PROFILE, test "x$PROFILE" != "xno") AM_CONDITIONAL(BUILD_PERL_GLUE, test "x$PERL_GLUE" != "xno") AM_CONDITIONAL(HAVE_APACHE_TEST, test -n "`$prereq_check Apache::Test`") AM_CONDITIONAL(BUILD_HTTPD, test -n "$APACHE2_SRC") AM_CONDITIONAL(BUILD_APR, test "x$APR_CONFIG" = x`$APR_CONFIG --srcdir`/apr-config) AM_CONDITIONAL(BUILD_APU, test "x$APU_CONFIG" = x`$APU_CONFIG --srcdir`/apu-config) AM_CONDITIONAL(HAVE_APACHE1, test -n "$APACHE1_APXS") dnl Reset the default installation prefix to be the same as apu's ac_default_prefix="`$APU_CONFIG --prefix`" APR_ADDTO([APR_INCLUDES], "`$APR_CONFIG --includes`") APR_ADDTO([APR_INCLUDES], "`$APU_CONFIG --includes`") APR_LA="`$APR_CONFIG --apr-la-file`" APU_LA="`$APU_CONFIG --apu-la-file`" APR_ADDTO([APR_LTFLAGS], "`$APR_CONFIG --link-libtool`") APR_ADDTO([APR_LTFLAGS], "`$APU_CONFIG --link-libtool`") dnl perl glue/tests do not use libtool: need ld linker flags APR_ADDTO([APR_LIBS], "`$APU_CONFIG --libs`") APR_ADDTO([APR_LIBS], "`$APR_CONFIG --libs`") APR_ADDTO([APR_LDFLAGS], "`$APU_CONFIG --link-ld --ldflags`") APR_ADDTO([APR_LDFLAGS], "`$APR_CONFIG --link-ld --ldflags`") if test -n "$EXPAT_DIR"; then APR_ADDTO([APR_INCLUDES], "-I$EXPAT_DIR/include") APR_ADDTO([APR_LTFLAGS], "-L$EXPAT_DIR/lib") fi dnl Absolute source/build directory abs_srcdir=`(cd $srcdir && pwd)` abs_builddir=`pwd` top_builddir="$abs_srcdir" if test "$abs_builddir" != "$abs_srcdir"; then USE_VPATH=1 fi if test "x$USE_MAINTAINER_MODE" != "xno"; then APR_ADDTO([CFLAGS],[ -Werror -Wall -Wmissing-prototypes -Wstrict-prototypes -Wmissing-declarations -Wwrite-strings -Wcast-qual -Wfloat-equal -Wshadow -Wpointer-arith -Wbad-function-cast -Wsign-compare -Waggregate-return -Wmissing-noreturn -Wmissing-format-attribute -Wpacked -Wredundant-decls -Wnested-externs -Wdisabled-optimization -Wno-long-long -Wendif-labels -Wcast-align -Wpacked ]) # -Wdeclaration-after-statement is only supported on gcc 3.4+ fi APR_ADDTO([CPPFLAGS], "`$APR_CONFIG --cppflags`") get_version="$SHELL $abs_srcdir/build/get-version.sh" version_hdr="$abs_srcdir/include/apreq_version.h" # set version data APREQ_CONFIG="$top_builddir/apreq2-config" APREQ_MAJOR_VERSION=`$get_version major $version_hdr APREQ` APREQ_MINOR_VERSION=`$get_version minor $version_hdr APREQ` APREQ_PATCH_VERSION=`$get_version patch $version_hdr APREQ` APREQ_DOTTED_VERSION=`$get_version all $version_hdr APREQ` # XXX: APR_MAJOR_VERSION doesn't yet work for static builds APREQ_LIBTOOL_CURRENT=`expr $APREQ_MAJOR_VERSION + $APREQ_MINOR_VERSION + $APR_MAJOR_VERSION` APREQ_LIBTOOL_REVISION=$APREQ_PATCH_VERSION APREQ_LIBTOOL_AGE=$APREQ_MINOR_VERSION APREQ_LIBTOOL_VERSION="$APREQ_LIBTOOL_CURRENT:$APREQ_LIBTOOL_REVISION:$APREQ_LIBTOOL_AGE" APREQ_LIBNAME="apreq$APREQ_MAJOR_VERSION" echo "lib$APREQ_LIBNAME Version: $APREQ_DOTTED_VERSION" AC_SUBST(APREQ_CONFIG) AC_SUBST(APREQ_LIBNAME) AC_SUBST(APREQ_LIBTOOL_VERSION) AC_SUBST(APREQ_MAJOR_VERSION) AC_SUBST(APREQ_DOTTED_VERSION) AC_SUBST(APACHE2_APXS) AC_SUBST(APACHE2_SRC) AC_SUBST(APACHE2_INCLUDES) AC_SUBST(APACHE2_HTTPD) AC_SUBST(APACHE1_APXS) AC_SUBST(APU_CONFIG) AC_SUBST(APR_CONFIG) AC_SUBST(APR_INCLUDES) AC_SUBST(APR_LDFLAGS) AC_SUBST(APR_LTFLAGS) AC_SUBST(APR_LIBS) AC_SUBST(APR_LA) AC_SUBST(APU_LA) AC_SUBST(PERL) AC_SUBST(PERL_OPTS) ]) dnl APR_CONFIG_NICE(filename) dnl dnl Saves a snapshot of the configure command-line for later reuse dnl AC_DEFUN([APR_CONFIG_NICE],[ rm -f $1 cat >$1<> $1 fi if test -n "$CFLAGS"; then echo "CFLAGS=\"$CFLAGS\"; export CFLAGS" >> $1 fi if test -n "$CPPFLAGS"; then echo "CPPFLAGS=\"$CPPFLAGS\"; export CPPFLAGS" >> $1 fi if test -n "$LDFLAGS"; then echo "LDFLAGS=\"$LDFLAGS\"; export LDFLAGS" >> $1 fi if test -n "$LTFLAGS"; then echo "LTFLAGS=\"$LTFLAGS\"; export LTFLAGS" >> $1 fi if test -n "$LIBS"; then echo "LIBS=\"$LIBS\"; export LIBS" >> $1 fi if test -n "$INCLUDES"; then echo "INCLUDES=\"$INCLUDES\"; export INCLUDES" >> $1 fi if test -n "$NOTEST_CFLAGS"; then echo "NOTEST_CFLAGS=\"$NOTEST_CFLAGS\"; export NOTEST_CFLAGS" >> $1 fi if test -n "$NOTEST_CPPFLAGS"; then echo "NOTEST_CPPFLAGS=\"$NOTEST_CPPFLAGS\"; export NOTEST_CPPFLAGS" >> $1 fi if test -n "$NOTEST_LDFLAGS"; then echo "NOTEST_LDFLAGS=\"$NOTEST_LDFLAGS\"; export NOTEST_LDFLAGS" >> $1 fi if test -n "$NOTEST_LIBS"; then echo "NOTEST_LIBS=\"$NOTEST_LIBS\"; export NOTEST_LIBS" >> $1 fi echo [$]0 [$]ac_configure_args '"[$]@"' >> $1 chmod +x $1 ])dnl dnl dnl APR_ADDTO(variable, value) dnl dnl Add value to variable dnl AC_DEFUN([APR_ADDTO],[ if test "x$$1" = "x"; then echo " setting $1 to \"$2\"" $1="$2" else apr_addto_bugger="$2" for i in $apr_addto_bugger; do apr_addto_duplicate="0" for j in $$1; do if test "x$i" = "x$j"; then apr_addto_duplicate="1" break fi done if test $apr_addto_duplicate = "0"; then echo " adding \"$i\" to $1" $1="$$1 $i" fi done fi ])dnl rapache-1.2.8/libapreq2/aclocal.m40000644000175100017510000075414312706745114016221 0ustar ondrejondrej# aclocal.m4 generated automatically by aclocal 1.6.3 -*- Autoconf -*- # Copyright 1996, 1997, 1998, 1999, 2000, 2001, 2002 # 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. # 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. AC_DEFUN([AC_APREQ], [ AC_ARG_ENABLE(profile, AC_HELP_STRING([--enable-profile],[compile libapreq2 with "-pg -fprofile-arcs -ftest-coverage" for gcov/gprof]), [PROFILE=$enableval],[PROFILE="no"]) AC_ARG_ENABLE(perl_glue, AC_HELP_STRING([--enable-perl-glue],[build perl modules Apache::Request and Apache::Cookie]), [PERL_GLUE=$enableval],[PERL_GLUE="no"]) AC_ARG_WITH(perl, AC_HELP_STRING([--with-perl],[path to perl executable]), [PERL=$withval],[PERL="perl"]) AC_ARG_WITH(apache2-apxs, AC_HELP_STRING([--with-apache2-apxs],[path to apache2's apxs]), [APACHE2_APXS=$withval],[APACHE2_APXS="apxs"]) AC_ARG_WITH(apache2-src, AC_HELP_STRING([--with-apache2-src],[path to httpd source]), [APACHE2_SRC=$withval],[APACHE2_SRC=""]) AC_ARG_WITH(apache2-httpd, AC_HELP_STRING([--with-apache2-httpd],[path to httpd binary]), [APACHE2_HTTPD=$withval],[APACHE2_HTTPD=""]) AC_ARG_WITH(apr-config, AC_HELP_STRING([ --with-apr-config],[path to apr-*-config script]), [APR_CONFIG=$withval],[APR_CONFIG=""]) AC_ARG_WITH(apu-config, AC_HELP_STRING([ --with-apu-config],[path to apu-*-config script]), [APU_CONFIG=$withval],[APU_CONFIG=""]) AC_ARG_WITH(apache1-apxs, AC_HELP_STRING([--with-apache1-apxs],[path to apache1's apxs]), [APACHE1_APXS=$withval],[APACHE1_APXS=""]) AC_ARG_WITH(perl-opts, AC_HELP_STRING([--with-perl-opts],[extra MakeMaker options]), [PERL_OPTS=$withval],[PERL_OPTS=""]) AC_ARG_WITH(expat, AC_HELP_STRING([--with-expat],[specify expat location]), [EXPAT_DIR=$withval],[EXPAT_DIR=""]) prereq_check="$PERL build/version_check.pl" if test -n "$APACHE2_SRC"; then # no apxs: must compile httpd from source APACHE2_SRC=`cd $APACHE2_SRC;pwd` AC_CHECK_FILE([$APACHE2_SRC/include/httpd.h],, AC_MSG_ERROR([invalid Apache2 source directory])) APACHE2_INCLUDES=-I$APACHE2_SRC/include if test -z "$APR_CONFIG"; then APR_CONFIG="$APACHE2_SRC/srclib/apr/apr-config" fi if test -z "$APU_CONFIG"; then APU_CONFIG="$APACHE2_SRC/srclib/apr-util/apu-config" fi APACHE2_HTTPD=$APACHE2_SRC/httpd else # have apxs: use it APACHE2_INCLUDES=-I`$APACHE2_APXS -q INCLUDEDIR` APR_MAJOR_VERSION=`$APACHE2_APXS -q APR_VERSION 2>/dev/null | cut -d. -f 1` if test ${APR_MAJOR_VERSION:="0"} -eq 0; then apr_config=apr-config apu_config=apu-config apreq_libs="-lapr -laprutil" else apr_config=apr-$APR_MAJOR_VERSION-config apu_config=apu-$APR_MAJOR_VERSION-config apreq_libs="-lapr-$APR_MAJOR_VERSION -laprutil-$APR_MAJOR_VERSION" fi if test -z "$APR_CONFIG"; then APR_CONFIG=`$APACHE2_APXS -q APR_BINDIR`/$apr_config fi if test -z "$APU_CONFIG"; then APU_CONFIG=`$APACHE2_APXS -q APU_BINDIR`/$apu_config fi if test -z "$APACHE2_HTTPD"; then APACHE2_HTTPD=`$APACHE2_APXS -q SBINDIR`/`$APACHE2_APXS -q progname` fi if test -z "`$prereq_check apache2 $APACHE2_HTTPD`"; then AC_MSG_ERROR([Bad apache2 binary ($APACHE2_HTTPD)]) fi fi AC_CHECK_FILE([$APR_CONFIG],, AC_MSG_ERROR([invalid apr-config location ($APR_CONFIG)- did you forget to configure apr?])) if test -z "`$prereq_check apr $APR_CONFIG`"; then AC_MSG_ERROR([Bad libapr version]) fi AC_CHECK_FILE([$APU_CONFIG],, AC_MSG_ERROR([invalid apu-config location ($APU_CONFIG)- did you forget to configure apr-util?])) if test -z "`$prereq_check apu $APU_CONFIG`"; then AC_MSG_ERROR([Bad libaprutil version]) fi if test "x$PERL_GLUE" != "xno"; then AC_MSG_CHECKING(for perl) if test -z "`$prereq_check perl $PERL`"; then AC_MSG_ERROR([Bad perl version]) fi AC_MSG_RESULT($PERL) AC_MSG_CHECKING(for ExtUtils::XSBuilder) if test -z "`$prereq_check ExtUtils::XSBuilder`"; then AC_MSG_WARN([Bad ExtUtils::XSBuilder version]) fi AC_MSG_RESULT(yes) AC_MSG_CHECKING(for mod_perl) if test -z "`$prereq_check mod_perl`"; then AC_MSG_WARN([Bad mod_perl version]) fi AC_MSG_RESULT(yes) AC_MSG_CHECKING(for Apache::Test) if test -z "`$prereq_check Apache::Test`"; then AC_MSG_WARN([Bad Apache::Test version]) fi AC_MSG_RESULT(yes) AC_MSG_CHECKING(for ExtUtils::MakeMaker) if test -z "`$prereq_check ExtUtils::MakeMaker`"; then AC_MSG_WARN([Bad ExtUtils::MakeMaker version]) fi AC_MSG_RESULT(yes) fi AM_CONDITIONAL(ENABLE_PROFILE, test "x$PROFILE" != "xno") AM_CONDITIONAL(BUILD_PERL_GLUE, test "x$PERL_GLUE" != "xno") AM_CONDITIONAL(HAVE_APACHE_TEST, test -n "`$prereq_check Apache::Test`") AM_CONDITIONAL(BUILD_HTTPD, test -n "$APACHE2_SRC") AM_CONDITIONAL(BUILD_APR, test "x$APR_CONFIG" = x`$APR_CONFIG --srcdir`/apr-config) AM_CONDITIONAL(BUILD_APU, test "x$APU_CONFIG" = x`$APU_CONFIG --srcdir`/apu-config) AM_CONDITIONAL(HAVE_APACHE1, test -n "$APACHE1_APXS") dnl Reset the default installation prefix to be the same as apu's ac_default_prefix="`$APU_CONFIG --prefix`" APR_ADDTO([APR_INCLUDES], "`$APR_CONFIG --includes`") APR_ADDTO([APR_INCLUDES], "`$APU_CONFIG --includes`") APR_LA="`$APR_CONFIG --apr-la-file`" APU_LA="`$APU_CONFIG --apu-la-file`" APR_ADDTO([APR_LTFLAGS], "`$APR_CONFIG --link-libtool`") APR_ADDTO([APR_LTFLAGS], "`$APU_CONFIG --link-libtool`") dnl perl glue/tests do not use libtool: need ld linker flags APR_ADDTO([APR_LIBS], "`$APU_CONFIG --libs`") APR_ADDTO([APR_LIBS], "`$APR_CONFIG --libs`") APR_ADDTO([APR_LDFLAGS], "`$APU_CONFIG --link-ld --ldflags`") APR_ADDTO([APR_LDFLAGS], "`$APR_CONFIG --link-ld --ldflags`") if test -n "$EXPAT_DIR"; then APR_ADDTO([APR_INCLUDES], "-I$EXPAT_DIR/include") APR_ADDTO([APR_LTFLAGS], "-L$EXPAT_DIR/lib") fi dnl Absolute source/build directory abs_srcdir=`(cd $srcdir && pwd)` abs_builddir=`pwd` top_builddir="$abs_srcdir" if test "$abs_builddir" != "$abs_srcdir"; then USE_VPATH=1 fi if test "x$USE_MAINTAINER_MODE" != "xno"; then APR_ADDTO([CFLAGS],[ -Werror -Wall -Wmissing-prototypes -Wstrict-prototypes -Wmissing-declarations -Wwrite-strings -Wcast-qual -Wfloat-equal -Wshadow -Wpointer-arith -Wbad-function-cast -Wsign-compare -Waggregate-return -Wmissing-noreturn -Wmissing-format-attribute -Wpacked -Wredundant-decls -Wnested-externs -Wdisabled-optimization -Wno-long-long -Wendif-labels -Wcast-align -Wpacked ]) # -Wdeclaration-after-statement is only supported on gcc 3.4+ fi APR_ADDTO([CPPFLAGS], "`$APR_CONFIG --cppflags`") get_version="$SHELL $abs_srcdir/build/get-version.sh" version_hdr="$abs_srcdir/include/apreq_version.h" # set version data APREQ_CONFIG="$top_builddir/apreq2-config" APREQ_MAJOR_VERSION=`$get_version major $version_hdr APREQ` APREQ_MINOR_VERSION=`$get_version minor $version_hdr APREQ` APREQ_PATCH_VERSION=`$get_version patch $version_hdr APREQ` APREQ_DOTTED_VERSION=`$get_version all $version_hdr APREQ` # XXX: APR_MAJOR_VERSION doesn't yet work for static builds APREQ_LIBTOOL_CURRENT=`expr $APREQ_MAJOR_VERSION + $APREQ_MINOR_VERSION + $APR_MAJOR_VERSION` APREQ_LIBTOOL_REVISION=$APREQ_PATCH_VERSION APREQ_LIBTOOL_AGE=$APREQ_MINOR_VERSION APREQ_LIBTOOL_VERSION="$APREQ_LIBTOOL_CURRENT:$APREQ_LIBTOOL_REVISION:$APREQ_LIBTOOL_AGE" APREQ_LIBNAME="apreq$APREQ_MAJOR_VERSION" echo "lib$APREQ_LIBNAME Version: $APREQ_DOTTED_VERSION" AC_SUBST(APREQ_CONFIG) AC_SUBST(APREQ_LIBNAME) AC_SUBST(APREQ_LIBTOOL_VERSION) AC_SUBST(APREQ_MAJOR_VERSION) AC_SUBST(APREQ_DOTTED_VERSION) AC_SUBST(APACHE2_APXS) AC_SUBST(APACHE2_SRC) AC_SUBST(APACHE2_INCLUDES) AC_SUBST(APACHE2_HTTPD) AC_SUBST(APACHE1_APXS) AC_SUBST(APU_CONFIG) AC_SUBST(APR_CONFIG) AC_SUBST(APR_INCLUDES) AC_SUBST(APR_LDFLAGS) AC_SUBST(APR_LTFLAGS) AC_SUBST(APR_LIBS) AC_SUBST(APR_LA) AC_SUBST(APU_LA) AC_SUBST(PERL) AC_SUBST(PERL_OPTS) ]) dnl APR_CONFIG_NICE(filename) dnl dnl Saves a snapshot of the configure command-line for later reuse dnl AC_DEFUN([APR_CONFIG_NICE],[ rm -f $1 cat >$1<> $1 fi if test -n "$CFLAGS"; then echo "CFLAGS=\"$CFLAGS\"; export CFLAGS" >> $1 fi if test -n "$CPPFLAGS"; then echo "CPPFLAGS=\"$CPPFLAGS\"; export CPPFLAGS" >> $1 fi if test -n "$LDFLAGS"; then echo "LDFLAGS=\"$LDFLAGS\"; export LDFLAGS" >> $1 fi if test -n "$LTFLAGS"; then echo "LTFLAGS=\"$LTFLAGS\"; export LTFLAGS" >> $1 fi if test -n "$LIBS"; then echo "LIBS=\"$LIBS\"; export LIBS" >> $1 fi if test -n "$INCLUDES"; then echo "INCLUDES=\"$INCLUDES\"; export INCLUDES" >> $1 fi if test -n "$NOTEST_CFLAGS"; then echo "NOTEST_CFLAGS=\"$NOTEST_CFLAGS\"; export NOTEST_CFLAGS" >> $1 fi if test -n "$NOTEST_CPPFLAGS"; then echo "NOTEST_CPPFLAGS=\"$NOTEST_CPPFLAGS\"; export NOTEST_CPPFLAGS" >> $1 fi if test -n "$NOTEST_LDFLAGS"; then echo "NOTEST_LDFLAGS=\"$NOTEST_LDFLAGS\"; export NOTEST_LDFLAGS" >> $1 fi if test -n "$NOTEST_LIBS"; then echo "NOTEST_LIBS=\"$NOTEST_LIBS\"; export NOTEST_LIBS" >> $1 fi echo [$]0 [$]ac_configure_args '"[$]@"' >> $1 chmod +x $1 ])dnl dnl dnl APR_ADDTO(variable, value) dnl dnl Add value to variable dnl AC_DEFUN([APR_ADDTO],[ if test "x$$1" = "x"; then echo " setting $1 to \"$2\"" $1="$2" else apr_addto_bugger="$2" for i in $apr_addto_bugger; do apr_addto_duplicate="0" for j in $$1; do if test "x$i" = "x$j"; then apr_addto_duplicate="1" break fi done if test $apr_addto_duplicate = "0"; then echo " adding \"$i\" to $1" $1="$$1 $i" fi done fi ])dnl # AM_CONDITIONAL -*- Autoconf -*- # Copyright 1997, 2000, 2001 Free Software Foundation, Inc. # 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, 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. # serial 5 AC_PREREQ(2.52) # AM_CONDITIONAL(NAME, SHELL-CONDITION) # ------------------------------------- # Define a conditional. AC_DEFUN([AM_CONDITIONAL], [ifelse([$1], [TRUE], [AC_FATAL([$0: invalid condition: $1])], [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl AC_SUBST([$1_TRUE]) AC_SUBST([$1_FALSE]) 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])]) # Do all the work for Automake. -*- Autoconf -*- # 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. # Copyright 1996, 1997, 1998, 1999, 2000, 2001, 2002 # Free Software Foundation, Inc. # 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, 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. # serial 8 # 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... AC_PREREQ([2.52]) # Autoconf 2.50 wants to disallow AM_ names. We explicitly allow # the ones we care about. m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl # 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_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl AC_REQUIRE([AC_PROG_INSTALL])dnl # test to see if srcdir already configured if test "`cd $srcdir && pwd`" != "`pwd`" && test -f $srcdir/config.status; then AC_MSG_ERROR([source directory already configured; run "make distclean" there first]) fi # 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 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 # 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) AM_MISSING_PROG(AMTAR, tar) AM_PROG_INSTALL_SH AM_PROG_INSTALL_STRIP # 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 _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 ]) ]) # Copyright 2002 Free Software Foundation, Inc. # 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, 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 # 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. AC_DEFUN([AM_AUTOMAKE_VERSION],[am__api_version="1.6"]) # AM_SET_CURRENT_AUTOMAKE_VERSION # ------------------------------- # Call AM_AUTOMAKE_VERSION so it can be traced. # This function is AC_REQUIREd by AC_INIT_AUTOMAKE. AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION], [AM_AUTOMAKE_VERSION([1.6.3])]) # Helper functions for option handling. -*- Autoconf -*- # Copyright 2001, 2002 Free Software Foundation, Inc. # 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, 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. # serial 2 # _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], [AC_FOREACH([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])]) # _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. # # Copyright 1996, 1997, 2000, 2001 Free Software Foundation, Inc. # 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, 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. # serial 3 # 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 # 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 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 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)]) # -*- Autoconf -*- # Copyright 1997, 1999, 2000, 2001 Free Software Foundation, Inc. # 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, 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. # serial 3 # 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)]) # 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 test x"${MISSING+set}" = xset || MISSING="\${SHELL} $am_aux_dir/missing" # 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 ]) # AM_AUX_DIR_EXPAND # Copyright 2001 Free Software Foundation, Inc. # 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, 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. # 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. # Rely on autoconf to set up CDPATH properly. AC_PREREQ([2.50]) AC_DEFUN([AM_AUX_DIR_EXPAND], [ # expand $ac_aux_dir to an absolute path am_aux_dir=`cd $ac_aux_dir && pwd` ]) # AM_PROG_INSTALL_SH # ------------------ # Define $install_sh. # Copyright 2001 Free Software Foundation, Inc. # 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, 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. AC_DEFUN([AM_PROG_INSTALL_SH], [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl install_sh=${install_sh-"$am_aux_dir/install-sh"} AC_SUBST(install_sh)]) # AM_PROG_INSTALL_STRIP # Copyright 2001 Free Software Foundation, Inc. # 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, 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. # 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="\${SHELL} \$(install_sh) -c -s" AC_SUBST([INSTALL_STRIP_PROGRAM])]) # serial 4 -*- Autoconf -*- # Copyright 1999, 2000, 2001 Free Software Foundation, Inc. # 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, 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. # 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... # _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 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], GCJ, [depcc="$GCJ" am_compiler_list='gcc3 gcc'], [depcc="$$1" am_compiler_list=]) 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 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 for depmode in $am_compiler_list; do # 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. echo '#include "conftest.h"' > conftest.c echo 'int i;' > conftest.h echo "${am__include} ${am__quote}conftest.Po${am__quote}" > confmf case $depmode in 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 ;; none) break ;; 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. if depmode=$depmode \ source=conftest.c object=conftest.o \ depfile=conftest.Po tmpdepfile=conftest.TPo \ $SHELL ./depcomp $depcc -c conftest.c -o conftest.o >/dev/null 2>&1 && grep conftest.h conftest.Po > /dev/null 2>&1 && ${MAKE-make} -s -f confmf > /dev/null 2>&1; then am_cv_$1_dependencies_compiler_type=$depmode break fi done cd .. rm -rf conftest.dir else am_cv_$1_dependencies_compiler_type=none fi ]) AC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type]) ]) # AM_SET_DEPDIR # ------------- # Choose a directory name for dependency files. # This macro is AC_REQUIREd in _AM_DEPENDENCIES AC_DEFUN([AM_SET_DEPDIR], [rm -f .deps 2>/dev/null mkdir .deps 2>/dev/null if test -d .deps; then DEPDIR=.deps else # MS-DOS does not allow filenames that begin with a dot. DEPDIR=_deps fi rmdir .deps 2>/dev/null AC_SUBST([DEPDIR]) ]) # AM_DEP_TRACK # ------------ AC_DEFUN([AM_DEP_TRACK], [AC_ARG_ENABLE(dependency-tracking, [ --disable-dependency-tracking Speeds up one-time builds --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]) ]) # Generate code to set up dependency tracking. -*- Autoconf -*- # Copyright 1999, 2000, 2001, 2002 Free Software Foundation, Inc. # 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, 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. #serial 2 # _AM_OUTPUT_DEPENDENCY_COMMANDS # ------------------------------ AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS], [for mf in $CONFIG_FILES; 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. # So let's grep whole file. if grep '^#.*generated by automake' $mf > /dev/null 2>&1; then dirpart=`AS_DIRNAME("$mf")` else continue fi grep '^DEP_FILES *= *[[^ @%:@]]' < "$mf" > /dev/null || continue # Extract the definition of DEP_FILES from the Makefile without # running `make'. DEPDIR=`sed -n -e '/^DEPDIR = / s///p' < "$mf"` test -z "$DEPDIR" && continue # When using ansi2knr, U may be empty or an underscore; expand it U=`sed -n -e '/^U = / s///p' < "$mf"` test -d "$dirpart/$DEPDIR" || mkdir "$dirpart/$DEPDIR" # 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 -e ' /^DEP_FILES = .*\\\\$/ { s/^DEP_FILES = // :loop s/\\\\$// p n /\\\\$/ b loop p } /^DEP_FILES = / s/^DEP_FILES = //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 # 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"]) ]) # Copyright 2001 Free Software Foundation, Inc. -*- Autoconf -*- # 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, 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. # serial 2 # AM_MAKE_INCLUDE() # ----------------- # Check to see how make treats includes. AC_DEFUN([AM_MAKE_INCLUDE], [am_make=${MAKE-make} cat > confinc << 'END' doit: @echo done 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 # We grep out `Entering directory' and `Leaving directory' # messages which can occur if `w' ends up in MAKEFLAGS. # In particular we don't look at `^make:' because GNU make might # be invoked under some other name (usually "gmake"), in which # case it prints its new name instead of `make'. if test "`$am_make -s -f confmf 2> /dev/null | fgrep -v 'ing directory'`" = "done"; then am__include=include am__quote= _am_result=GNU fi # Now try BSD make style include. if test "$am__include" = "#"; then echo '.include "confinc"' > confmf if test "`$am_make -s -f confmf 2> /dev/null`" = "done"; then am__include=.include am__quote="\"" _am_result=BSD fi fi AC_SUBST(am__include) AC_SUBST(am__quote) AC_MSG_RESULT($_am_result) rm -f confinc confmf ]) # libtool.m4 - Configure libtool for the host system. -*-Autoconf-*- # serial 47 AC_PROG_LIBTOOL # Debian $Rev: 214 $ # 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 # Sed substitution that helps us do robust quoting. It backslashifies # metacharacters that are still active within double-quoted strings. Xsed='sed -e s/^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 M$VC, # which needs '.lib'). libext=a ltmain="$ac_aux_dir/ltmain.sh" ofile="$default_ofile" with_gnu_ld="$lt_cv_prog_gnu_ld" AC_CHECK_TOOL(AR, ar, false) AC_CHECK_TOOL(RANLIB, ranlib, :) AC_CHECK_TOOL(STRIP, strip, :) 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 "$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_deplibs' old_postinstall_cmds='chmod 644 $oldlib' old_postuninstall_cmds= if test -n "$RANLIB"; then case $host_os in openbsd*) old_postinstall_cmds="\$RANLIB -t \$oldlib~$old_postinstall_cmds" ;; *) old_postinstall_cmds="\$RANLIB \$oldlib~$old_postinstall_cmds" ;; esac old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib" fi # 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 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) 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 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 # Use C for the default configuration in the libtool script tagname= AC_LIBTOOL_LANG_C_CONFIG _LT_AC_TAGCONFIG ])# AC_LIBTOOL_SETUP # _LT_AC_SYS_COMPILER # ------------------- AC_DEFUN([_LT_AC_SYS_COMPILER], [AC_REQUIRE([AC_PROG_CC])dnl # If no C compiler was specified, use CC. LTCC=${LTCC-"$CC"} # Allow CC to be a program name with arguments. compiler=$CC ])# _LT_AC_SYS_COMPILER # _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_LINK_IFELSE(AC_LANG_PROGRAM,[ aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } }'` # 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 '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } }'`; fi],[]) if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi ])# _LT_AC_SYS_LIBPATH_AIX # _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 # _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} 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 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 "X[$]1" = X--fallback-echo; then # used as fallback echo shift cat </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. 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` && 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 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. ECHO=$echo if test "X$ECHO" = "X$CONFIG_SHELL [$]0 --fallback-echo"; then ECHO="$CONFIG_SHELL \\\$\[$]0 --fallback-echo" fi AC_SUBST(ECHO) ])])# _LT_AC_PROG_ECHO_BACKSLASH # _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* ;; *-*-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* ;; 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-*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-*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* ;; *-*-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 ;; 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]) printf "$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}? :&$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 if test ! -s conftest.err; 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_CACHE_CHECK([$1], [$2], [$2=no save_LDFLAGS="$LDFLAGS" LDFLAGS="$LDFLAGS $3" printf "$lt_simple_link_test_code" > conftest.$ac_ext if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then # The compiler 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 else $2=yes fi fi $rm 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; ;; 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 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"`$CONFIG_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` ;; 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 # _LT_AC_CHECK_DLFCN # -------------------- AC_DEFUN([_LT_AC_CHECK_DLFCN], [AC_CHECK_HEADERS(dlfcn.h)dnl ])# _LT_AC_CHECK_DLFCN # _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 #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); */ } exit (status); }] EOF if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext} 2>/dev/null; then (./conftest; exit; ) 2>/dev/null lt_status=$? case x$lt_status in x$lt_dlno_uscore) $1 ;; x$lt_dlneed_uscore) $2 ;; x$lt_unknown|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 ;; 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 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="-dld"], [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="-dld"]) ]) ]) ]) ]) ]) ;; 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" eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" 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) ]) if test "x$lt_cv_dlopen_self" = xyes; then LDFLAGS="$LDFLAGS $link_static_flag" 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 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 ])# AC_LIBTOOL_DLOPEN_SELF # 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_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 printf "$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}? :&$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 if test ! -s out/conftest.err; then _LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes fi fi chmod u+w . $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 # 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 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 else need_locks=no fi ])# AC_LIBTOOL_SYS_HARD_LINK_LOCKS # 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 # 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 # 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 # 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)]) 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 # 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" AC_MSG_RESULT([yes]) else AC_MSG_RESULT([no]) fi ;; *) AC_MSG_RESULT([no]) ;; esac fi ])# AC_LIBTOOL_SYS_LIB_STRIP # AC_LIBTOOL_SYS_DYNAMIC_LINKER # ----------------------------- # PORTME Fill in your ld.so characteristics AC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER], [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" if test "$GCC" = yes; then 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 ';' >/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. 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 else 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' ;; aix4* | aix5*) 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 ;; bsdi4*) 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' postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ dlpath=$dir/\$dldll~ $rm \$dlpath' shlibpath_overrides_runpath=yes 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 ;; 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)' # Apple's gcc prints 'gcc -print-search-dirs' doesn't operate the same. if test "$GCC" = yes; then sys_lib_search_path_spec=`$CC -print-search-dirs | tr "\n" "$PATH_SEPARATOR" | sed -e 's/libraries:/@libraries:/' | tr "@" "\n" | grep "^libraries:" | sed -e "s/^libraries://" -e "s,=/,/,g" -e "s,$PATH_SEPARATOR, ,g" -e "s,.*,& /lib /usr/lib /usr/local/lib,g"` else sys_lib_search_path_spec='/lib /usr/lib /usr/local/lib' 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 ;; kfreebsd*-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 shlibpath_overrides_runpath=no hardcode_into_libs=yes dynamic_linker='GNU ld.so' ;; freebsd*) objformat=`test -x /usr/bin/objformat && /usr/bin/objformat || echo aout` 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 ;; *) # from 3.2 on shlibpath_overrides_runpath=no 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' ;; 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 ;; # No shared lib support for Linux oldld, aout, or coff. linux*oldld* | linux*aout* | linux*coff*) dynamic_linker=no ;; # This must be Linux ELF. 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}' 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=`$SED -e 's/[:,\t]/ /g;s/=[^=]*$//;s/=[^= ]* / /g' /etc/ld.so.conf | 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' ;; netbsdelf*-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 shlibpath_overrides_runpath=no hardcode_into_libs=yes dynamic_linker='NetBSD ld.elf_so' ;; knetbsd*-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 shlibpath_overrides_runpath=no hardcode_into_libs=yes dynamic_linker='GNU 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 ;; 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 ;; 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 need_lib_prefix=no need_version=yes 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" ;; sco3.2v5*) version_type=osf 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 ;; 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.2uw2* | sysv4.3* | sysv5*) 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 ;; 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 AC_MSG_RESULT([$dynamic_linker]) test "$dynamic_linker" = no && can_build_shared=no ])# AC_LIBTOOL_SYS_DYNAMIC_LINKER # _LT_AC_TAGCONFIG # ---------------- AC_DEFUN([_LT_AC_TAGCONFIG], [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 AC_MSG_WARN([using `LTCC=$LTCC', extracted from `$ofile']) fi 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 if grep "^# ### BEGIN LIBTOOL TAG CONFIG: $tagname$" < "${ofile}" > /dev/null then AC_MSG_ERROR([tag name \"$tagname\" already exists]) 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"; then AC_LIBTOOL_LANG_CXX_CONFIG else tagname="" fi ;; 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 # 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" # 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 # AC_LIBTOOL_DLOPEN # ----------------- # enable checks for dlopen support AC_DEFUN([AC_LIBTOOL_DLOPEN], [AC_BEFORE([$0],[AC_LIBTOOL_SETUP]) ])# AC_LIBTOOL_DLOPEN # AC_LIBTOOL_WIN32_DLL # -------------------- # declare package support for building win32 dll's 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 # 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 # 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 # 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 # 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 # 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 recognise 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 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]) 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 # AC_PATH_MAGIC # ------------- # find a file program which can recognise 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 # 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 GNU ld's only accept -v. # Break only if it was the GNU/non-GNU ld that we prefer. case `"$lt_cv_path_LD" -v 2>&1 &1 /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)/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 ;; 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 ;; 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*) lt_cv_deplibs_check_method=pass_all ;; netbsd* | netbsdelf*-gnu | knetbsd*-gnu) 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=unknown ;; openbsd*) lt_cv_file_magic_cmd=/usr/bin/file lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB shared object' else lt_cv_deplibs_check_method='file_magic OpenBSD.* shared library' fi ;; osf3* | osf4* | osf5*) lt_cv_deplibs_check_method=pass_all ;; sco3.2v5*) lt_cv_deplibs_check_method=pass_all ;; solaris*) lt_cv_deplibs_check_method=pass_all ;; sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) 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 ;; esac ;; sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[[78]]* | unixware7* | 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 # 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_save_ifs="$IFS"; IFS=$PATH_SEPARATOR for ac_dir in $PATH /usr/ccs/bin /usr/ucb /bin; do IFS="$lt_save_ifs" test -z "$ac_dir" && ac_dir=. tmp_nm="$ac_dir/${ac_tool_prefix}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" test -z "$lt_cv_path_NM" && lt_cv_path_NM=nm fi]) NM="$lt_cv_path_NM" ])# AC_PROG_NM # 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 # 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 LIBLTDL # and LTDLINCL are not AC_SUBSTed, nor is AC_CONFIG_SUBDIRS called. 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 # 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 LIBLTDL # and LTDLINCL are not AC_SUBSTed, nor is AC_CONFIG_SUBDIRS called. 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 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. # 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 # AC_LIBTOOL_CXX # -------------- # enable support for C++ libraries AC_DEFUN([AC_LIBTOOL_CXX], [AC_REQUIRE([_LT_AC_LANG_CXX]) ])# AC_LIBTOOL_CXX # _LT_AC_LANG_CXX # --------------- AC_DEFUN([_LT_AC_LANG_CXX], [AC_REQUIRE([AC_PROG_CXX]) AC_REQUIRE([AC_PROG_CXXCPP]) _LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}CXX]) ])# _LT_AC_LANG_CXX # AC_LIBTOOL_F77 # -------------- # enable support for Fortran 77 libraries AC_DEFUN([AC_LIBTOOL_F77], [AC_REQUIRE([_LT_AC_LANG_F77]) ])# AC_LIBTOOL_F77 # _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 # 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 # AC_LIBTOOL_LANG_C_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_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. ac_ext=c # 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;\n" # Code to be used in simple link tests lt_simple_link_test_code='int main(){return(0);}\n' _LT_AC_SYS_COMPILER # # Check for any special shared library compilation flags. # _LT_AC_TAGVAR(lt_prog_cc_shlib, $1)= if test "$GCC" = no; then case $host_os in sco3.2v5*) _LT_AC_TAGVAR(lt_prog_cc_shlib, $1)='-belf' ;; esac fi if test -n "$_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)"; then AC_MSG_WARN([`$CC' requires `$_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)' to build shared libraries]) if echo "$old_CC $old_CFLAGS " | grep "[[ ]]$_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)[[ ]]" >/dev/null; then : else AC_MSG_WARN([add `$_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)' to the CC or CFLAGS env variable and reconfigure]) _LT_AC_TAGVAR(lt_cv_prog_cc_can_build_shared, $1)=no fi fi # # Check to make sure the static flag actually works. # AC_LIBTOOL_LINKER_OPTION([if $compiler static flag $_LT_AC_TAGVAR(lt_prog_compiler_static, $1) works], _LT_AC_TAGVAR(lt_prog_compiler_static_works, $1), $_LT_AC_TAGVAR(lt_prog_compiler_static, $1), [], [_LT_AC_TAGVAR(lt_prog_compiler_static, $1)=]) 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($1) # Report which librarie types wil 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 ;; aix4* | aix5*) if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then test "$enable_shared" = yes && enable_static=no fi ;; darwin* | rhapsody*) if test "$GCC" = yes; then _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no case "$host_os" in rhapsody* | darwin1.[[012]]) _LT_AC_TAGVAR(allow_undefined_flag, $1)='-undefined suppress' ;; *) # Darwin 1.3 on if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then _LT_AC_TAGVAR(allow_undefined_flag, $1)='-flat_namespace -undefined suppress' else case ${MACOSX_DEPLOYMENT_TARGET} in 10.[[012]]) _LT_AC_TAGVAR(allow_undefined_flag, $1)='-flat_namespace -undefined suppress' ;; 10.*) _LT_AC_TAGVAR(allow_undefined_flag, $1)='-undefined dynamic_lookup' ;; esac fi ;; esac 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_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 ld's _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs$compiler_flags -install_name $rpath/$soname $verstring~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(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)='-all_load $convenience' _LT_AC_TAGVAR(link_all_deplibs, $1)=yes else _LT_AC_TAGVAR(ld_shlibs, $1)=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([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_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)= # Source file extension for C++ test sources. ac_ext=cc # 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;\n" # Code to be used in simple link tests lt_simple_link_test_code='int main(int, char *[]) { return(0); }\n' # ltmain only uses $CC for tagged configurations so make sure $CC is set. _LT_AC_SYS_COMPILER # 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 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 unset lt_cv_path_LD fi test -z "${LDCXX+set}" || LD=$LDCXX CC=${CXX-"c++"} compiler=$CC _LT_AC_TAGVAR(compiler, $1)=$CC cc_basename=`$echo X"$compiler" | $Xsed -e 's%^.*/%%'` # 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_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= fi if test "$GXX" = yes; then # Set up default GNU C++ configuration AC_PROG_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_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' _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir' _LT_AC_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_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 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 # 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 ;; aix4* | aix5*) 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]].*|aix5*) for ld_flag in $LDFLAGS; do case $ld_flag in *-brtl*) aix_use_runtimelinking=yes break ;; esac 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. _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 "$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 _LT_AC_TAGVAR(hardcode_direct, $1)=yes 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' 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. _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 $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$no_entry_flag \${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 $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$no_entry_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' # -bexpall does not export symbols beginning with underscore (_) _LT_AC_TAGVAR(always_export_symbols, $1)=yes # Exported symbols can be pulled into shared objects from archives _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=' ' _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes # This is similar to how AIX traditionally builds it's shared libraries. _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}-bE:$export_symbols ${wl}-bnoentry${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' fi fi ;; chorus*) case $cc_basename in *) # FIXME: insert proper C++ library support _LT_AC_TAGVAR(ld_shlibs, $1)=no ;; esac ;; 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}--image-base=0x10000000 ${wl}--out-implib,$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}--image-base=0x10000000 ${wl}--out-implib,$lib' else _LT_AC_TAGVAR(ld_shlibs, $1)=no fi ;; darwin* | rhapsody*) if test "$GXX" = yes; then _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no case "$host_os" in rhapsody* | darwin1.[[012]]) _LT_AC_TAGVAR(allow_undefined_flag, $1)='-undefined suppress' ;; *) # Darwin 1.3 on if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then _LT_AC_TAGVAR(allow_undefined_flag, $1)='-flat_namespace -undefined suppress' else case ${MACOSX_DEPLOYMENT_TARGET} in 10.[[012]]) _LT_AC_TAGVAR(allow_undefined_flag, $1)='-flat_namespace -undefined suppress' ;; 10.*) _LT_AC_TAGVAR(allow_undefined_flag, $1)='-undefined dynamic_lookup' ;; esac fi ;; esac lt_int_apple_cc_single_mod=no output_verbose_link_cmd='echo' if $CC -dumpspecs 2>&1 | grep 'single_module' >/dev/null ; then lt_int_apple_cc_single_mod=yes fi if test "X$lt_int_apple_cc_single_mod" = Xyes ; then _LT_AC_TAGVAR(archive_cmds, $1)='$CC -dynamiclib -single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring' else _LT_AC_TAGVAR(archive_cmds, $1)='$CC -r ${wl}-bind_at_load -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' fi _LT_AC_TAGVAR(module_cmds, $1)='$CC ${wl}-bind_at_load $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 ld's if test "X$lt_int_apple_cc_single_mod" = Xyes ; then _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -dynamiclib -single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' else _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -r ${wl}-bind_at_load -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~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' fi _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(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)='-all_load $convenience' _LT_AC_TAGVAR(link_all_deplibs, $1)=yes else _LT_AC_TAGVAR(ld_shlibs, $1)=no fi ;; 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* | kfreebsd*-gnu) # 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 case "$host_cpu" in hppa*64*) _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='+b $libdir' _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: ;; ia64*) _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' ;; *) _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' ;; esac fi case "$host_cpu" in hppa*64*) _LT_AC_TAGVAR(hardcode_direct, $1)=no _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no ;; ia64*) _LT_AC_TAGVAR(hardcode_direct, $1)=no _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, # but as the default # location of the library. ;; *) _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 case $cc_basename in CC) # FIXME: insert proper C++ library support _LT_AC_TAGVAR(ld_shlibs, $1)=no ;; aCC) case "$host_cpu" in hppa*64*|ia64*) _LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname -o $lib $linker_flags $libobjs $deplibs' ;; *) _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 ia64*|hppa*64*) _LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname -o $lib $linker_flags $libobjs $deplibs' ;; *) _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 fi else # FIXME: insert proper C++ library support _LT_AC_TAGVAR(ld_shlibs, $1)=no fi ;; esac ;; 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 ${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}${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*) 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 _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no _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' _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' ;; 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' 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' ;; 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 ;; *) # FIXME: insert proper C++ library support _LT_AC_TAGVAR(ld_shlibs, $1)=no ;; esac ;; netbsd* | netbsdelf*-gnu | knetbsd*-gnu) 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::"' ;; 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)=: # 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 ${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}${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"' else # 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 ${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 $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}${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"' 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 ;; sco*) _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no case $cc_basename in CC) # 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 ;; 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(no_undefined_flag, $1)=' -zdefs' _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -nolib -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} -nolib ${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].*) ;; *) # The C++ compiler is used as linker so we must use $wl # flag to pass the commands to the underlying system # linker. # Supported since Solaris 2.6 (maybe 2.5.1?) _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' ;; esac _LT_AC_TAGVAR(link_all_deplibs, $1)=yes # 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 -G $CFLAGS -v conftest.$objext 2>&1 | grep "\-[[LR]]"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' # 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' # 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' # 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' # 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_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $wl$libdir' fi ;; esac ;; sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[[78]]* | unixware7*) _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no ;; 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 _LT_AC_TAGVAR(GCC, $1)="$GXX" _LT_AC_TAGVAR(LD, $1)="$LD" 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_SYS_LIB_STRIP AC_LIBTOOL_DLOPEN_SELF($1) AC_LIBTOOL_CONFIG($1) 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. AC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP],[ 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... ifelse([$1],[],[cat > conftest.$ac_ext < conftest.$ac_ext < conftest.$ac_ext < conftest.$ac_ext <> "$cfgfile" ifelse([$1], [], [#! $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 # 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., 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. # 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 s/^X//" # The HP-UX ksh and POSIX shell print the target directory to stdout # if CDPATH is set. if test "X\${CDPATH+set}" = Xset; then CDPATH=:; export CDPATH; fi # The names of the tagged configurations supported by this script. available_tags= # ### BEGIN LIBTOOL CONFIG], [# ### 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=$_LT_AC_TAGVAR(archive_cmds_need_lc, $1) # 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 # 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 # 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) # An ERE matcher. EGREP=$lt_EGREP # The linker used to build libraries. LD=$lt_[]_LT_AC_TAGVAR(LD, $1) # 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_AC_TAGVAR(lt_prog_compiler_wl, $1) # 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_AC_TAGVAR(lt_prog_compiler_pic, $1) 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_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1) # 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_AC_TAGVAR(lt_prog_compiler_static, $1) # Compiler flag to turn off builtin functions. no_builtin_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) # Compiler flag to allow reflexive dlopens. export_dynamic_flag_spec=$lt_[]_LT_AC_TAGVAR(export_dynamic_flag_spec, $1) # Compiler flag to generate shared objects directly from archives. whole_archive_flag_spec=$lt_[]_LT_AC_TAGVAR(whole_archive_flag_spec, $1) # Compiler flag to generate thread-safe objects. thread_safe_flag_spec=$lt_[]_LT_AC_TAGVAR(thread_safe_flag_spec, $1) # 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_[]_LT_AC_TAGVAR(old_archive_cmds, $1) 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_[]_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) # 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 # 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) # 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_[]_LT_AC_TAGVAR(predep_objects, $1) # Dependencies to place after the objects being linked to create a # shared library. postdep_objects=$lt_[]_LT_AC_TAGVAR(postdep_objects, $1) # Dependencies to place before the objects being linked to create a # shared library. predeps=$lt_[]_LT_AC_TAGVAR(predeps, $1) # Dependencies to place after the objects being linked to create a # shared library. postdeps=$lt_[]_LT_AC_TAGVAR(postdeps, $1) # 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) # 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_[]_LT_AC_TAGVAR(allow_undefined_flag, $1) # Flag that forces no undefined symbols. no_undefined_flag=$lt_[]_LT_AC_TAGVAR(no_undefined_flag, $1) # 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=$_LT_AC_TAGVAR(hardcode_action, $1) # 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_[]_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $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. hardcode_libdir_flag_spec_ld=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1) # 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) # 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) # 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) # 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) # 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=$_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_AC_TAGVAR(fix_srcfile_path, $1)" # 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 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_LIBTOOL_CONFIG # 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)= 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 ])# AC_LIBTOOL_PROG_COMPILER_NO_RTTI # AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE # --------------------------------- AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE], [AC_REQUIRE([AC_CANONICAL_HOST]) 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?!! ;)] # 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]]*\)' # Transform the above into a raw symbol and a C symbol. symxfrm='\1 \2\3 \3' # 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*) 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'" ;; irix* | nonstopux*) symcode='[[BCDEGRST]]' ;; osf*) symcode='[[BCDEGQRST]]' ;; solaris* | sysv5*) symcode='[[BDRT]]' ;; 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 # 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 # 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 EOF # Now generate the symbol file. eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | grep -v main >> 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. */ 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} }; #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 -f 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= 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 # 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* | cygwin* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) # PIC is the default for these OSes. ;; mingw* | 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). _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)= ;; 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 case $host_os in aix4* | aix5*) # 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 ;; 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* | kfreebsd*-gnu) # 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)="${ac_cv_prog_cc_wl}-a ${ac_cv_prog_cc_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)="${ac_cv_prog_cc_wl}-a ${ac_cv_prog_cc_wl}archive" case "$host_cpu" in hppa*64*|ia64*) # +Z the default ;; *) _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z' ;; esac ;; *) ;; esac ;; 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*) 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) # 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' ;; 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' ;; *) ;; esac ;; lynxos*) ;; m88k*) ;; mvs*) case $cc_basename in cxx) _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall' ;; *) ;; esac ;; netbsd* | netbsdelf*-gnu | knetbsd*-gnu) ;; 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*) ;; sco*) case $cc_basename in CC) _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' ;; *) ;; esac ;; 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 ;; unixware*) ;; vxworks*) ;; *) _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no ;; esac fi ], [ if test "$GCC" = 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* | cygwin* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) # PIC is the default for these OSes. ;; mingw* | 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_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' ;; 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 ;; 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*) # +Z the default ;; *) _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' ;; esac ;; *) _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 ;; mingw* | 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_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT' ;; 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' ;; 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' ;; newsos6) _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; linux*) case $CC 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' ;; 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' ;; esac ;; 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' ;; sco3.2v5*) _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-Kpic' _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-dn' ;; solaris*) _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' ;; 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' ;; sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) _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' ;; 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 ;; uts4*) _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic' _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; *) _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no ;; esac fi ]) AC_MSG_RESULT([$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)]) # # 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_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 ]) # AC_LIBTOOL_PROG_LD_SHLIBS([TAGNAME]) # ------------------------------------ # See if the linker supports building shared libraries. AC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS], [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 aix4* | aix5*) # 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 '\''/^[[BCDGS]] /s/.* \([[^ ]]*\)/\1 DATA/'\'' | $SED -e '\''/^[[AITW]] /s/.* //'\'' | sort | uniq > $export_symbols' ;; linux*) _LT_AC_TAGVAR(link_all_deplibs, $1)=no ;; *) _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' ;; esac ],[ 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_" # 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. extract_expsyms_cmds= 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 ;; openbsd*) with_gnu_ld=no ;; esac _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}' # See if GNU ld supports shared libraries. case $host_os in aix3* | aix4* | aix5*) # On AIX/PPC, the GNU linker is very broken if test "$host_cpu" != ia64; then _LT_AC_TAGVAR(ld_shlibs, $1)=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*) _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 ;; 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 ;; 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 '\''/^[[BCDGS]] /s/.* \([[^ ]]*\)/\1 DATA/'\'' | $SED -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}--image-base=0x10000000 ${wl}--out-implib,$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}--image-base=0x10000000 ${wl}--out-implib,$lib' else ld_shlibs=no fi ;; netbsd* | netbsdelf*-gnu | knetbsd*-gnu) 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 ;; solaris* | sysv5*) if $LD -v 2>&1 | grep 'BFD 2\.8' > /dev/null; then _LT_AC_TAGVAR(ld_shlibs, $1)=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 _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 ;; 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 ;; linux*) if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then tmp_archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' _LT_AC_TAGVAR(archive_cmds, $1)="$tmp_archive_cmds" 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 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 -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' else _LT_AC_TAGVAR(archive_expsym_cmds, $1)="$tmp_archive_cmds" fi _LT_AC_TAGVAR(link_all_deplibs, $1)=no else _LT_AC_TAGVAR(ld_shlibs, $1)=no fi ;; *) 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 if test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = yes; then 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 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 "$link_static_flag"; then # Neither direct hardcoding nor static linking is supported with a # broken collect2. _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported fi ;; aix4* | aix5*) 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 # 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]].*|aix5*) 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. _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 _LT_AC_TAGVAR(hardcode_direct, $1)=yes 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' 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. _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 $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$no_entry_flag \${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 $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$no_entry_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' # -bexpall does not export symbols beginning with underscore (_) _LT_AC_TAGVAR(always_export_symbols, $1)=yes # Exported symbols can be pulled into shared objects from archives _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=' ' _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes # This is similar to how AIX traditionally builds it's shared libraries. _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}-bE:$export_symbols ${wl}-bnoentry${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' fi fi ;; 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 ;; bsdi4*) _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic ;; 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' fix_srcfile_path='`cygpath -w "$srcfile"`' _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes ;; darwin* | rhapsody*) if test "$GXX" = yes ; then _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no case "$host_os" in rhapsody* | darwin1.[[012]]) _LT_AC_TAGVAR(allow_undefined_flag, $1)='-undefined suppress' ;; *) # Darwin 1.3 on if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then _LT_AC_TAGVAR(allow_undefined_flag, $1)='-flat_namespace -undefined suppress' else case ${MACOSX_DEPLOYMENT_TARGET} in 10.[[012]]) _LT_AC_TAGVAR(allow_undefined_flag, $1)='-flat_namespace -undefined suppress' ;; 10.*) _LT_AC_TAGVAR(allow_undefined_flag, $1)='-undefined dynamic_lookup' ;; esac fi ;; esac lt_int_apple_cc_single_mod=no output_verbose_link_cmd='echo' if $CC -dumpspecs 2>&1 | grep 'single_module' >/dev/null ; then lt_int_apple_cc_single_mod=yes fi if test "X$lt_int_apple_cc_single_mod" = Xyes ; then _LT_AC_TAGVAR(archive_cmds, $1)='$CC -dynamiclib -single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring' else _LT_AC_TAGVAR(archive_cmds, $1)='$CC -r ${wl}-bind_at_load -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' fi _LT_AC_TAGVAR(module_cmds, $1)='$CC ${wl}-bind_at_load $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 ld's if test "X$lt_int_apple_cc_single_mod" = Xyes ; then _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -dynamiclib -single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' else _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -r ${wl}-bind_at_load -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~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' fi _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(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)='-all_load $convenience' _LT_AC_TAGVAR(link_all_deplibs, $1)=yes else _LT_AC_TAGVAR(ld_shlibs, $1)=no 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 ;; freebsd1*) _LT_AC_TAGVAR(ld_shlibs, $1)=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*) _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 ;; # 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* | kfreebsd*-gnu) _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 ;; 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 # 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' ;; hpux10* | hpux11*) if test "$GCC" = yes -a "$with_gnu_ld" = no; then case "$host_cpu" in hppa*64*|ia64*) _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname -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*|ia64*) _LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname -o $lib $libobjs $deplibs $linker_flags' ;; *) _LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' ;; esac fi if test "$with_gnu_ld" = no; then case "$host_cpu" in hppa*64*) _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='+b $libdir' _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: _LT_AC_TAGVAR(hardcode_direct, $1)=no _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no ;; ia64*) _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_AC_TAGVAR(hardcode_direct, $1)=no _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no # 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(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: _LT_AC_TAGVAR(hardcode_direct, $1)=yes _LT_AC_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_AC_TAGVAR(hardcode_minus_L, $1)=yes ;; esac fi ;; 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 ;; netbsd* | netbsdelf*-gnu | knetbsd*-gnu) 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 ;; 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 ;; openbsd*) _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(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 ;; 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' ;; 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)=: ;; 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 ${objdir}/so_locations -o $lib~$rm $lib.exp' # 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)=: ;; sco3.2v5*) _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)='${wl}-Bexport' runpath_var=LD_RUN_PATH hardcode_runpath_var=yes ;; solaris*) _LT_AC_TAGVAR(no_undefined_flag, $1)=' -z text' if test "$GCC" = yes; then _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 _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]].*) ;; *) # Supported since Solaris 2.6 (maybe 2.5.1?) _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' ;; esac _LT_AC_TAGVAR(link_all_deplibs, $1)=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. _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 ;; 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 ;; 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' ;; 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 ;; sysv4.2uw2*) _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags' _LT_AC_TAGVAR(hardcode_direct, $1)=yes _LT_AC_TAGVAR(hardcode_minus_L, $1)=no _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no hardcode_runpath_var=yes runpath_var=LD_RUN_PATH ;; sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[[78]]* | unixware7*) _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z ${wl}text' if test "$GCC" = yes; then _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' else _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' fi runpath_var='LD_RUN_PATH' _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no ;; sysv5*) _LT_AC_TAGVAR(no_undefined_flag, $1)=' -z text' # $CC -shared without GNU ld will not create a library from C++ # object files and a static libstdc++, better avoid it by now _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' _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)= _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no runpath_var='LD_RUN_PATH' ;; 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 ;; *) _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 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 # # Do we need to explicitly link libc? # 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 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* printf "$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) 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 ;; esac ])# AC_LIBTOOL_PROG_LD_SHLIBS # _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 # # #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 # _LT_AC_TAGVAR(VARNAME, [TAGNAME]) # --------------------------------- AC_DEFUN([_LT_AC_TAGVAR], [ifelse([$2], [], [$1], [$1_$2])]) # 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) ]) # 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 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 && break 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_MSG_RESULT([$SED]) ]) # Add --enable-maintainer-mode option to configure. # From Jim Meyering # Copyright 1996, 1998, 2000, 2001 Free Software Foundation, Inc. # 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, 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. # serial 1 AC_DEFUN([AM_MAINTAINER_MODE], [AC_MSG_CHECKING([whether to enable maintainer-specific portions of Makefiles]) dnl maintainer-mode is disabled by default AC_ARG_ENABLE(maintainer-mode, [ --enable-maintainer-mode enable make rules and dependencies not useful (and sometimes confusing) to the casual installer], USE_MAINTAINER_MODE=$enableval, USE_MAINTAINER_MODE=no) AC_MSG_RESULT([$USE_MAINTAINER_MODE]) AM_CONDITIONAL(MAINTAINER_MODE, [test $USE_MAINTAINER_MODE = yes]) MAINT=$MAINTAINER_MODE_TRUE AC_SUBST(MAINT)dnl ] ) # Like AC_CONFIG_HEADER, but automatically create stamp file. -*- Autoconf -*- # Copyright 1996, 1997, 2000, 2001 Free Software Foundation, Inc. # 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, 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. AC_PREREQ([2.52]) # serial 6 # 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. We must strip everything past the first ":", # and everything past the last "/". # _AM_DIRNAME(PATH) # ----------------- # Like AS_DIRNAME, only do it during macro expansion AC_DEFUN([_AM_DIRNAME], [m4_if(regexp([$1], [^.*[^/]//*[^/][^/]*/*$]), -1, m4_if(regexp([$1], [^//\([^/]\|$\)]), -1, m4_if(regexp([$1], [^/.*]), -1, [.], patsubst([$1], [^\(/\).*], [\1])), patsubst([$1], [^\(//\)\([^/].*\|$\)], [\1])), patsubst([$1], [^\(.*[^/]\)//*[^/][^/]*/*$], [\1]))[]dnl ])# _AM_DIRNAME # The stamp files are numbered to have different names. # We could number them on a directory basis, but that's additional # complications, let's have a unique counter. m4_define([_AM_STAMP_Count], [0]) # _AM_STAMP(HEADER) # ----------------- # The name of the stamp file for HEADER. AC_DEFUN([_AM_STAMP], [m4_define([_AM_STAMP_Count], m4_incr(_AM_STAMP_Count))dnl AS_ESCAPE(_AM_DIRNAME(patsubst([$1], [:.*])))/stamp-h[]_AM_STAMP_Count]) # _AM_CONFIG_HEADER(HEADER[:SOURCES], COMMANDS, INIT-COMMANDS) # ------------------------------------------------------------ # We used to try to get a real timestamp in stamp-h. But the fear is that # that will cause unnecessary cvs conflicts. AC_DEFUN([_AM_CONFIG_HEADER], [# Add the stamp file to the list of files AC keeps track of, # along with our hook. AC_CONFIG_HEADERS([$1], [# update the timestamp echo 'timestamp for $1' >"_AM_STAMP([$1])" $2], [$3]) ])# _AM_CONFIG_HEADER # AM_CONFIG_HEADER(HEADER[:SOURCES]..., COMMANDS, INIT-COMMANDS) # -------------------------------------------------------------- AC_DEFUN([AM_CONFIG_HEADER], [AC_FOREACH([_AM_File], [$1], [_AM_CONFIG_HEADER(_AM_File, [$2], [$3])]) ])# AM_CONFIG_HEADER rapache-1.2.8/libapreq2/apreq2-config.in0000644000175100017510000001321112706745114017326 0ustar ondrejondrej#!/bin/sh ## ## Copyright 2003-2005 The Apache Software Foundation ## ## Licensed under the Apache License, Version 2.0 (the "License"); ## you may not use this file except in compliance with the License. ## You may obtain a copy of the License at ## ## http://www.apache.org/licenses/LICENSE-2.0 ## ## Unless required by applicable law or agreed to in writing, software ## distributed under the License is distributed on an "AS IS" BASIS, ## WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ## See the License for the specific language governing permissions and ## limitations under the License. ## # apreq2-config- based on apu-config: # APR-util script designed to allow easy command line access to APR-util # configuration parameters. prefix="@prefix@" exec_prefix="@exec_prefix@" bindir="@bindir@" libdir="@libdir@" includedir="@includedir@/@APREQ_LIBNAME@" LIBS="@APR_LIBS@" LDFLAGS="@APR_LDFLAGS@" INCLUDES="@APR_INCLUDES@" LDFLAGS="@APR_LDFLAGS@" APREQ_LIBNAME="@APREQ_LIBNAME@" APREQ_SOURCE_DIR="@abs_srcdir@" APREQ_BUILD_DIR="@abs_builddir@" show_usage() { cat << EOF Usage: apreq2-config [OPTION] Known values for OPTION are: --prefix[=DIR] change prefix to DIR --bindir print location where binaries are installed --includes print include information --includedir print location where headers are installed --ldflags print linker flags --libs print library information --srcdir print apreq2 source directory --link-ld print link switch(es) for linking to libapreq2 --link-libtool print the libtool inputs for linking to libapreq2 --la-file print the path to the library's .la file, if available --library-version print the API version as a dotted triple --libtool-version print the ABI version in a libtool-compatible format --package-version print the version number of the distribution --help print this help When linking with libtool, an application should do something like: APREQ_LIBS="\`apreq2-config --link-libtool --libs\`" or when linking directly: APREQ_LIBS="\`apreq2-config --link-ld --ldflags --libs\`" An application should use the results of --includes, and --ldflags in their build process. EOF } if test $# -eq 0; then show_usage exit 1 fi thisdir="`dirname $0`" thisdir="`cd $thisdir && pwd`" if test -d $bindir; then tmpbindir="`cd $bindir && pwd`" else tmpbindir="" fi # If we have the realpath program, use it to resolve symlinks. # Otherwise, being in a symlinked dir may result in incorrect output. if test -x "`which realpath 2>/dev/null`"; then thisdir="`realpath $thisdir`" if test -d "$APREQ_SOURCE_DIR"; then APREQ_SOURCE_DIR="`realpath $APREQ_SOURCE_DIR`" fi if test -n "$tmpbindir"; then tmpbindir="`realpath $tmpbindir`" fi fi if test "$tmpbindir" = "$thisdir"; then location=installed elif test "$APREQ_SOURCE_DIR" = "$thisdir"; then location=source else location=build fi if test "$location" = "installed"; then LA_FILE="$libdir/lib${APREQ_LIBNAME}.la" else LA_FILE="$thisdir/library/lib${APREQ_LIBNAME}.la" fi flags="" while test $# -gt 0; do # Normalize the prefix. case "$1" in -*=*) optarg=`echo "$1" | sed 's/[-_a-zA-Z0-9]*=//'` ;; *) optarg= ;; esac case "$1" in # It is possible for the user to override our prefix. --prefix=*) prefix=$optarg ;; --prefix) echo $prefix exit 0 ;; --bindir) echo $bindir exit 0 ;; --libs) flags="$flags $LIBS" ;; --includedir) if test "$location" = "installed"; then flags="$includedir" elif test "$location" = "source"; then flags="$APREQ_SOURCE_DIR/include" else # this is for VPATH builds flags="$thisdir/include $APREQ_SOURCE_DIR/include" fi echo $flags exit 0 ;; --includes) if test "$location" = "installed"; then flags="$flags -I$includedir $INCLUDES" elif test "$location" = "source"; then flags="$flags -I$APREQ_SOURCE_DIR/include $INCLUDES" else # this is for VPATH builds flags="$flags -I$thisdir/include -I$APREQ_SOURCE_DIR/include $INCLUDES" fi ;; --ldflags) flags="$flags $LDFLAGS" ;; --srcdir) echo $APREQ_SOURCE_DIR exit 0 ;; --library-version) echo @APREQ_DOTTED_VERSION@ exit 0 ;; --libtool-version) echo @APREQ_LIBTOOL_VERSION@ exit 0 ;; --package-version) echo "@VERSION@" exit 0 ;; --link-ld) if test "$location" = "installed"; then ### avoid using -L if libdir is a "standard" location like /usr/lib flags="$flags -L$libdir -l$APREQ_LIBNAME" else flags="$flags -L$thisdir/library/.libs -l$APREQ_LIBNAME" fi ;; --link-libtool) # If the LA_FILE exists where we think it should be, use it. If we're # installed and the LA_FILE does not exist, assume to use -L/-l # (the LA_FILE may not have been installed). If we're building ourselves, # we'll assume that at some point the .la file be created. if test -f "$LA_FILE"; then flags="$flags $LA_FILE" elif test "$location" = "installed"; then ### avoid using -L if libdir is a "standard" location like /usr/lib flags="$flags -L$libdir -l$APREQ_LIBNAME $apreq_libs" else flags="$flags $LA_FILE" fi ;; --la-file) if test -f "$LA_FILE"; then flags="$flags $LA_FILE" fi ;; --help) show_usage exit 0 ;; *) show_usage exit 1 ;; esac # Next please. shift done if test -n "$flags"; then echo "$flags" fi exit 0 rapache-1.2.8/libapreq2/build/0000755000175100017510000000000012706745114015442 5ustar ondrejondrejrapache-1.2.8/libapreq2/build/RELEASE0000644000175100017510000000601012706745114016442 0ustar ondrejondrejInstructions for the apreq Release Manager (RM) 1. Prep the package for CPAN by running: % make release This will generate a libapreq2-2.XX-dev.tar.gz candidate in the current directory. You should keep this source tree intact to tag the final release. 2. Test the generated file with % make release_test Make sure all perl tests pass. 3. Upload the release candidate to people.apache.org/~username and post a candidate announcement to apreq-dev@. Also, it is strongly recommended that the RM crosspost the candidate announcement to the modperl@ list, to solicit feedback from a much larger audience. 4. Give the mailing list participants 48-72 hours to comment and vote on the candidate. If there is a "majority consensus" (three +1 and more +1s than -1s) among the committers, the RM may proceed with the release. 5. Edit STATUS, marking the release date /** @page STATUS 2.XX-dev released on . Also add the release date to the top @section in CHANGES: /** @page CHANGES @section v2_XX_dev Changes with libapreq2-2.XX-dev (released ...). Commit the changes and tag the tree (tr/0-9a-zA-Z/_/c in the version number) % svn commit -m "2.XX-dev released." STATUS CHANGES % svn cp https://svn.apache.org/repos/asf/httpd/apreq/trunk \ https://svn.apache.org/repos/asf/httpd/apreq/tags/v2_XX_dev 6. Regenerate the release % make release && make release_test Then test and sign it via gpg: % gpg --detach-sign --armor libapreq2-2.XX-dev.tar.gz or pgp: % pgp -sba libapreq2-2.XX-dev.tar.gz 7. Upload (scp) the package and signature to www.apache.org for distribution: % scp libapreq2-2.XX-dev.tar.gz* \ @people.apache.org:/www/www.apache.org/dist/httpd/libapreq/ Ask another developer to confirm the uploaded signature is ok. % gpg --verify libapreq2-2.XX-dev.tar.gz.asc % pgp libapreq2-2.XX-dev.tar.gz.asc Check that your public key is among those listed in the /www/www.apache.org/dist/httpd/KEYS file. If not, you need to commit the necessary change to KEYS the httpd-dist repos. Then update the website's copy using "cvs co KEYS" in the /www/www.apache.org/dist/httpd/ directory. 8. Upload the package to CPAN. Doublecheck that the md5 checksum received from PAUSE is correct. 9. Wait ~12-24 hours for the ASF mirrors to pick up the new package, then update the apreq homepage to list the new release in the News section Be sure to update the libapreq2 documentation. For instructions on updating the httpd website, see build/WEBSITE. IMPORTANT: YOU MUST UPDATE download.html TO POINT AT THE NEW RELEASE PACKAGE! 10. Mail the announcement from your cvs.apache.org account by piping the "CPAN Upload" email acknowledgement (from PAUSE) through build/announcement.pl: % build/announcement.pl $user@apache.org < CPAN_ack | ssh user@people.apache.org "sendmail -oi -t -odq" rapache-1.2.8/libapreq2/build/WEBSITE0000644000175100017510000000245212706745114016472 0ustar ondrejondrejbuild/ General Info on the apreq community. Utility scripts for building & packaging httpd-apreq-2. UPDATING THE WEBSITE: (cf: http://jakarta.apache.org/site/jakarta-site2.html ) RedHat Linux Instructions: 1) Download and install j2re and j2sdk rpms from Sun's website: http://java.sun.com/j2se/1.3/download.html 2) Download the latest binary release of Apache Ant: http://ant.apache.org/bindownload.cgi (I just expanded the tar.gz file in /usr/java/ant, which is alongside the jre and jdk directory trees.) 3) Prep the (bash) environment: $ export ANT_HOME=/usr/java/ant/apache-ant-1.5.3-1 $ export PATH=$PATH:$ANT_HOME/bin $ export JAVA_HOME=/usr/java/jdk1.3.1_07 4) Check out httpd-site from cvs.apache.org and run $ cd httpd-site $ emacs xdocs/apreq $ ant $ cvs commit -m "..." xdocs/apreq/ docs/apreq/ 5) Login (via ssh) to httpd.apache.org and do $ cd /www/httpd.apache.org $ cvs update index.html apreq/ BUILDING THE DOXYGEN DOCUMENTATION: Be sure doxygen is installed on your machine. Then cd to the base directory (httpd-apreq-2) and run % make docs This will generate the C documentation in the docs/ directory using build/doxygen.conf as the config file for doxygen. rapache-1.2.8/libapreq2/build/announcement.pl0000755000175100017510000000424312706745114020477 0ustar ondrejondrej#! /usr/bin/perl use warnings; use strict; our($PACKAGE_NAME, $PACKAGE_TITLE, $PACKAGE_VERSION, $LIBRARY_VERSION); foreach (qw/PACKAGE_TITLE PACKAGE_NAME PACKAGE_VERSION LIBRARY_VERSION/) { no strict 'refs'; my $opt = lc; $opt =~ tr/_/-/; chomp ($$_ = `./apreq2-config --$opt`); } sub slurp { my $file_name = shift; open my $fh, "<", $file_name or die "Can't open $file_name: $!"; read $fh, my $buf, -s $fh; return wantarray ? split /\n/, $buf : $buf; } my $MAIL_FROM = shift; my $RCPT_TO = join ",\n ", map "<$_>" , qw( announce@httpd.apache.org apreq-dev@httpd.apache.org announce@perl.apache.org modperl@perl.apache.org ); my ($LICENSE_VERSION) = grep s/^\s+Version (\d\.\d),.*$/$1/, slurp "LICENSE"; my $CPAN_DATA = join "", <>; $CPAN_DATA =~ /^has entered CPAN as(.+?)\nNo action is required/ms or die "Bad CPAN message:\n$CPAN_DATA"; $CPAN_DATA = $1; my $TITLE = "$PACKAGE_TITLE Released"; my $mail_header = <s inside */ h2 a, h2 a:hover, h2 a:active { color: inherit; background-color: inherit; text-decoration: none; } /* h3, h4 */ /* ====================== */ h3 { background-color: inherit; color: #036; text-decoration: none; font-weight: bold; font-size: 16px; margin: 1.3em 0 0.4em 0; padding: 0; } h4 { background-color: inherit; color: #036; text-decoration: none; font-weight: bold; font-size: 14px; margin: 1.3em 0 0.2em 0; padding: 0; } /* margin adjustment */ h3 + *, h4 + * { margin-top: 0; } /* IE confuses the + * :-( * so reset some things */ ul, .section table, .directive-section table { margin-bottom: 1em; } /* take care of s inside */ h3 a, h3 a:hover, h3 a:active, h4 a, h4 a:hover, h4 a:active { color: inherit; background-color: inherit; text-decoration: none; } /* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * Tables * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ */ /* general */ /* ====================== */ /* table { border: 1px solid #aaa; border-collapse: collapse; padding: 2px; margin-top: 0.5em; margin-bottom: 0; } td, th { empty-cells: show; /* show border around empty cells */ padding: 0.1em 0.2em; vertical-align: top; text-align: left; line-height: 1.3em; } */ th { font-weight: bold; } td.centered { text-align: center; } tr.odd { /* for large tables alternating colors */ background-color: #f2f2f2; } tr.header, tr.header th { background-color: #e2e2e2; border-top: 1px solid #aaa; border-bottom: 1px solid #aaa; } /* bordered table cells */ /* ====================== */ /* turn off borders in tables nested in * bordered tables per default */ table.bordered table td, table.bordered table th { border-style: none; } table.bordered td, table.bordered th, table table.bordered td, table table.bordered th { border: 1px solid #aaa; } /* index page layout table */ /* ======================= */ body#index-page div#page-content { width: 100%; /* IE fun */ } body[id]#index-page div#page-content { width: auto; /* reasonable browsers. */ } table#indextable { width: 100%; border-collapse: collapse; border: 0 none; } table#indextable td { width: 33.3%; border-left: 1px solid #aaa; padding-top: 0; padding-bottom: 0; } table#indextable td.col1 { border-left: 0 none; padding-left: 0; } table#indextable td.col3 { padding-right: 0; } /* mod/dir. overview table and quick reference */ /* ============================================ */ table.module th, table.directive th { white-space: nowrap; } table.qref { border-collapse: collapse; width: 100%; } table.qref td { border-style: none solid; border-color: #aaa; border-width: 1px; } table.qref td.descr { padding-left: 1em; font-size: 13px; } table#legend { width: 100%; border-style: none; border-width: 0; vertical-align: bottom; padding: 0; margin: 0; } table#legend td { vertical-align: bottom; margin: 0; padding: 0; } table#legend td.letters { width: 100%; padding-bottom: 0.5em; } table#legend table { vertical-align: bottom; margin: 0 0 0 0.4em; padding: 0; height: 7.5em; } table#legend table td, table#legend table th { vertical-align: middle; padding: 0.1ex 0.2em; line-height: 1em; white-space: nowrap; } /* related modules & dir. */ /* ====================== */ /* assuming, all links are enclosed by * or * */ table.related { border-collapse: separate; } table.related th { padding: 0.2ex 0.3em; background-color: #e5ecf3; color: #405871; vertical-align: middle; } table.related td { padding: 0.2ex 0.3em; } /* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * Lists * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ */ /* list default values */ /* ====================== */ ul { list-style-type: disc; } ul ul { list-style-type: square; } ul ul ul { list-style-type: circle; } li, dt, dd { line-height: 1.3em; } dt { margin-top: 0.5em; font-weight: bold; } ol li { margin-top: 0.5em; } /* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * main page sections * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ */ div#page-header img { padding: 0; display: block; margin: -70px 0 1px 2em; width: 248px; height: 70px; } div#page-header p.apache { background-color: #405871; color: #fff; padding: 0 0 0 248px; margin: 0; text-align: center; vertical-align: middle; font-size: 16px; font-weight: bold; line-height: 29px; } div#page-header p.menu { text-align: right; font-size: 13px; margin: 30px 0 0.5em 0; padding: 0; } /* breadcrumb navigation */ div.qindex, div#path { text-align:center; margin: 0.2em 0 1.2em 30px; padding: 0; font-size: 13px; } p { line-height: 1.3em; } /* page footer */ /* ====================== */ div#footer { /* margin-left: 30px; */ font-size: 13px; border-top: 1px solid #405871; padding-top: 0.2em; } div#footer p.apache { float: left; text-align: left; padding: 0 0 1em 0; margin-top: 0; } div#footer p.menu { float: right; text-align: right; margin-top: 0; padding: 0 0 1em 0; } /* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * -> The End (modified doxygen-generated stylesheet below) <- * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ */ CAPTION { font-weight: bold } A.qindex { font-weight: bold; } A.qindexHL { font-weight: bold; background-color: #405871; color: #ffffff; padding: 2px 6px; } A.qindexHL:hover { background-color: #405871; color: #ffffff; } A.qindexHL:visited { background-color: #405871; color: #ffffff } A.el { font-weight: bold } A.elRef { font-weight: bold } DL.el { margin-left: -1cm } PRE.fragment { border: 1px solid #CCCCCC; background-color: #f5f5f5; margin-top: 4px; margin-bottom: 4px; margin-left: 2px; margin-right: 8px; padding-left: 6px; padding-right: 6px; padding-top: 4px; padding-bottom: 4px; } DIV.fragment { border: 1px solid #CCCCCC; background-color: #f5f5f5; padding: 6px; } DIV.ah { background-color: black; font-weight: bold; color: #ffffff; margin-bottom: 3px; margin-top: 3px } TD.md { background-color: #F4F4FB; font-weight: bold; } TD.mdname1 { background-color: #F4F4FB; font-weight: bold; color: #602020; } TD.mdname { background-color: #F4F4FB; font-weight: bold; color: #602020; width: 600px; } DIV.groupHeader { margin-left: 16px; margin-top: 12px; margin-bottom: 6px; font-weight: bold; } DIV.groupText { margin-left: 16px; font-style: italic; font-size: smaller } BODY { background: white; color: black; margin-right: 20px; margin-left: 30px; } TD.indexkey { background-color: #eeeeff; font-weight: bold; padding-right : 10px; padding-top : 2px; padding-left : 10px; padding-bottom : 2px; margin-left : 0px; margin-right : 0px; margin-top : 2px; margin-bottom : 2px; border: 1px solid #CCCCCC; } TD.indexvalue { background-color: #eeeeff; font-style: italic; padding-right : 10px; padding-top : 2px; padding-left : 10px; padding-bottom : 2px; margin-left : 0px; margin-right : 0px; margin-top : 2px; margin-bottom : 2px; border: 1px solid #CCCCCC; } TR.memlist { background-color: #f0f0f0; } P.formulaDsp { text-align: center; } IMG.formulaDsp { } IMG.formulaInl { vertical-align: middle; } SPAN.keyword { color: #008000 } SPAN.keywordtype { color: #604020 } SPAN.keywordflow { color: #e08000 } SPAN.comment { color: #800000 } SPAN.preprocessor { color: #806020 } SPAN.stringliteral { color: #002080 } SPAN.charliteral { color: #008080 } .mdTable { border: 1px solid #868686; background-color: #F4F4FB; } .mdRow { padding: 8px 10px; } .mdescLeft { font-size: smaller; font-style: italic; background-color: #FAFAFA; padding-left: 8px; border-top: 1px none #E0E0E0; border-right: 1px none #E0E0E0; border-bottom: 1px none #E0E0E0; border-left: 1px none #E0E0E0; margin: 0px; } .mdescRight { font-size: smaller; font-style: italic; background-color: #FAFAFA; padding-left: 4px; border-top: 1px none #E0E0E0; border-right: 1px none #E0E0E0; border-bottom: 1px none #E0E0E0; border-left: 1px none #E0E0E0; margin: 0px; padding-bottom: 0px; padding-right: 8px; } .memItemLeft { padding: 1px 0px 0px 8px; margin: 4px; border-top-width: 1px; border-right-width: 1px; border-bottom-width: 1px; border-left-width: 1px; border-top-style: solid; border-top-color: #E0E0E0; border-right-color: #E0E0E0; border-bottom-color: #E0E0E0; border-left-color: #E0E0E0; border-right-style: none; border-bottom-style: none; border-left-style: none; background-color: #FAFAFA; font-size: 12px; } .memItemRight { padding: 1px 0px 0px 8px; margin: 4px; border-top-width: 1px; border-right-width: 1px; border-bottom-width: 1px; border-left-width: 1px; border-top-style: solid; border-top-color: #E0E0E0; border-right-color: #E0E0E0; border-bottom-color: #E0E0E0; border-left-color: #E0E0E0; border-right-style: none; border-bottom-style: none; border-left-style: none; background-color: #FAFAFA; font-size: 13px; } td.tiny { font-size: 75%; } /* a { color: #252E78; } a:visited { color: #3D2185; } */ rapache-1.2.8/libapreq2/build/dox.foot0000644000175100017510000000056612706745114017134 0ustar ondrejondrej rapache-1.2.8/libapreq2/build/dox.head0000644000175100017510000000075112706745114017062 0ustar ondrejondrej $projectname-$projectnumber: $title rapache-1.2.8/libapreq2/build/doxygen.conf.in0000644000175100017510000000404212706745114020373 0ustar ondrejondrejPROJECT_NAME = "@PACKAGE@" PROJECT_NUMBER = "@VERSION@" OUTPUT_DIRECTORY = docs OUTPUT_LANGUAGE = English BRIEF_MEMBER_DESC = YES REPEAT_BRIEF = YES TAB_SIZE = 8 ALIASES = "req=@arg The request handle" OPTIMIZE_OUTPUT_FOR_C = YES INTERNAL_DOCS = NO GENERATE_TODOLIST = YES GENERATE_TESTLIST = YES GENERATE_BUGLIST = YES GENERATE_DEPRECATEDLIST= YES MAX_INITIALIZER_LINES = 30 SHOW_USED_FILES = YES QUIET = NO WARNINGS = YES WARN_IF_UNDOCUMENTED = YES WARN_IF_DOC_ERROR = YES WARN_FORMAT = "$file:$line: $text" INPUT = . include module/apache module/apache2 FILE_PATTERNS = *.h *.dox CHANGES STATUS RECURSIVE = NO EXTRACT_STATIC = YES EXCLUDE = EXCLUDE_SYMLINKS = NO EXCLUDE_PATTERNS = apreq_config* apreq_private* EXAMPLE_PATH = . EXAMPLE_PATTERNS = README INSTALL LICENSE NOTICE *.html *.man IMAGE_PATH = SOURCE_BROWSER = NO ALPHABETICAL_INDEX = NO COLS_IN_ALPHA_INDEX = 5 IGNORE_PREFIX = GENERATE_HTML = YES HTML_HEADER = build/dox.head HTML_FOOTER = build/dox.foot HTML_STYLESHEET = build/dox.css HTML_ALIGN_MEMBERS = YES GENERATE_LATEX = NO GENERATE_RTF = NO GENERATE_MAN = YES MAN_LINKS = NO GENERATE_XML = NO GENERATE_AUTOGEN_DEF = NO GENERATE_PERLMOD = NO ENABLE_PREPROCESSING = YES MACRO_EXPANSION = YES EXPAND_ONLY_PREDEF = YES PREDEFINED = APREQ_DECLARE(x)=x \ APREQ_DECLARE_NONSTD(x)=x TAGFILES = docs/apr.tag=http://apr.apache.org/docs/apr \ docs/apu.tag=http://apr.apache.org/docs/apr-util GENERATE_TAGFILE = docs/apreq2.tag ALLEXTERNALS = NO EXTERNAL_GROUPS = NO PERL_PATH = @PERL@ HIDE_UNDOC_RELATIONS = YES SEARCHENGINE = NO rapache-1.2.8/libapreq2/build/get-version.sh0000755000175100017510000000221412706745114020242 0ustar ondrejondrej#!/bin/sh # # extract version numbers from a header file # # USAGE: get-version.sh CMD VERSION_HEADER PREFIX # where CMD is one of: all, major, libtool # where PREFIX is the prefix to {MAJOR|MINOR|PATCH}_VERSION defines # # get-version.sh all returns a dotted version number # get-version.sh major returns just the major version number # get-version.sh minor returns just the minor version number # get-version.sh patch returns just the match version number # if test $# != 3; then echo "USAGE: $0 CMD INCLUDEDIR PREFIX" echo " where CMD is one of: all, major, minor, patch" exit 1 fi major_sed="/#define.*$3_MAJOR_VERSION/s/^[^0-9]*\([0-9]*\).*$/\1/p" minor_sed="/#define.*$3_MINOR_VERSION/s/^[^0-9]*\([0-9]*\).*$/\1/p" patch_sed="/#define.*$3_PATCH_VERSION/s/^[^0-9]*\([0-9]*\).*$/\1/p" major="`sed -n $major_sed $2`" minor="`sed -n $minor_sed $2`" patch="`sed -n $patch_sed $2`" if test "$1" = "all"; then echo ${major}.${minor}.${patch} elif test "$1" = "major"; then echo ${major} elif test "$1" = "minor"; then echo ${minor} elif test "$1" = "patch"; then echo ${patch} else echo "ERROR: unknown version CMD ($1)" exit 1 fi rapache-1.2.8/libapreq2/build/version_check.pl0000644000175100017510000001257112706745114020627 0ustar ondrejondrej# version_check.pl tool version use strict; use warnings 'FATAL'; use Getopt::Long qw/GetOptions/; GetOptions(\my %opts, "version=s"); my ($tool, $path) = @ARGV; $path = $tool unless defined $path; sub exe_version { scalar qx/$path -v/ } sub gnu_version { scalar qx/$path --version/ } sub xsb_version { eval { require ExtUtils::XSBuilder; }; $@ ? return '' : return $ExtUtils::XSBuilder::VERSION; } sub ti_version { eval { require Test::Inline; }; @$ ? return '' : return $Test::Inline::VERSION; } sub a_t_version { require Apache::Test; $Apache::Test::VERSION; } sub tm_version { require Test::More; $Test::More::VERSION; } sub mm_version { require ExtUtils::MakeMaker; $ExtUtils::MakeMaker::VERSION; } sub mp2_version { eval { require mod_perl2; $mod_perl::VERSION; }; } my %svn = ( libtool => { version => "1.4.3", test => \&gnu_version }, autoconf => { version => "2.53", test => \&gnu_version }, automake => { version => "1.6.0", test => \&gnu_version }, doxygen => { version => "1.2", test => \&gnu_version }, perl => { version => "5.6.1", test => \&gnu_version }, "ExtUtils::XSBuilder" => { version => "0.23", test => \&xsb_version }, ); my %build = ( apache2 => { version => "2.0.48", test => \&exe_version }, apr => { version => "0.9.4", test => \&gnu_version, comment => "bundled with apache2 2.0.48" }, apu => { version => "0.9.4", test => \&gnu_version, comment => "bundled with apache2 2.0.48" }, perl => $svn{perl}, ); my %perl_glue = ( perl => $svn{perl}, "ExtUtils::XSBuilder" => $svn{"ExtUtils::XSBuilder"}, "Apache::Test" => { version => "1.04", test => \&a_t_version, comment => "Win32 requires version 1.06" }, # mp2 does not contain "_" in its reported version number mod_perl => { version => "1.999022",test => \&mp2_version }, "ExtUtils::MakeMaker" => { version => "6.15", test => \&mm_version }, "Test::More" => { version => "0.47", test => \&tm_version }, ); my %test = ( "Test::Inline" => { version => "0.16", test => \&ti_version }, ); sub print_prereqs ($$) { my ($preamble, $prereq) = @_; print $preamble, "\n"; for (sort keys %$prereq) { my ($version, $comment) = @{$prereq->{$_}}{qw/version comment/}; if ($opts{version}) { print " $_: $version\n"; } else { $comment = defined $comment ? " ($comment)" : ""; printf "%30s: %s%s\n", $_, $version, $comment; } } } sub perl_prereqs { my @prereqs = map {"$_=>q[$perl_glue{$_}->{version}]"} grep {!m{perl}} keys %perl_glue; my $prereq_string = ''; if (@prereqs) { $prereq_string = 'PREREQ_PM => { ' . (join ', ', @prereqs) . ' }'; } return $prereq_string; } if ($path eq 'perl_prereqs') { print perl_prereqs(); exit; } if (@ARGV == 0) { if ($opts{version}) { # generate META.yml file content print < $perl_glue{mod_perl}, perl => $perl_glue{perl}, ); print_prereqs "requires:", \%runtime_prereqs; print_prereqs "build_requires:", \%perl_glue; } else { # generate PREREQUISITES file content print "=" x 50, "\n"; print_prereqs "Build system (core C API) prerequisites\n", \%build; print "\n", "=" x 50, "\n"; print_prereqs "Perl glue (Apache::Request) prerequisites\n", \%perl_glue; print "\n", "=" x 50, "\n"; print_prereqs "Additional prerequisites for apreq subversion builds\n", \%svn; } exit 0; } # test prerequisites from the command-line arguments my %prereq = (%svn, %build, %perl_glue, %test); die "$0 failed: unknown tool '$tool'.\n" unless $prereq{$tool}; my $version = $prereq{$tool}->{version}; my @version = split /\./, $version; $_ = $prereq{$tool}->{test}->(); die "$0 failed: no version_string found in '$_' for '$tool'.\n" unless /(\d[.\d]+)/; my $saw = $1; my @saw = split /\./, $saw; $_ = 0 for @saw[@saw .. $#version]; # ensure @saw has enough entries for (0.. $#version) { last if $version[$_] < $saw[$_]; die < $saw[$_]; $0 failed: $tool version $saw unsupported ($version or greater is required). EOM } print "$tool: $saw ok\n"; rapache-1.2.8/libapreq2/build/xsbuilder.pl0000644000175100017510000000705312706745114020005 0ustar ondrejondrej#!/usr/bin/perl # # Usage: cd glue/perl; ../../build/xsbuilder.pl # # # This script is responsible for building the # # glue/perl/xsbuilder/tables # # directory by parsing the header files in src/. use strict; use warnings FATAL => 'all'; use File::Basename; use constant WIN32 => ($^O =~ /Win32/i); use Cwd; my $cwd = WIN32 ? Win32::GetLongPathName(cwd) : cwd; $cwd =~ m{^(.+)/glue/perl$} or die "Can't find base directory"; my $base_dir = $1; my $inc_dir = "$base_dir/include"; my $mod_dir = "$base_dir/module"; my $xs_dir = "$base_dir/glue/perl/xsbuilder"; sub slurp($$) { open my $file, $_[1] or die "Can't open $_[1]: $!"; read $file, $_[0], -s $file; } my %c_macro_cache = ( XS => sub {s/XS\s*\(([^)]+)\)/void $1()/g}, ); sub c_macro { return $c_macro_cache{"@_"} if exists $c_macro_cache{"@_"}; my ($name, $header) = @_; my $src; if (defined $header) { slurp local $_ => "$inc_dir/$header"; /^#define $name\s*\(([^)]+)\)\s+(.+?[^\\])$/ms or die "Can't find definition for '$name': $_"; my $def = $2; my @args = split /\s*,\s*/, $1; for (1..@args) { $def =~ s/\b$args[$_-1]\b/ \$$_ /g; } my $args = join ',' => ('([^,)]+)') x @args; $src = "sub { /^#define $name.+?[^\\\\]\$/gms + s{$name\\s*\\($args\\)}{$def}g}"; } else { $src = "sub { /^#define $name.+?[^\\\\]\$/gms + s{$name\\s*\\(([^)]+)\\)}{\$1}g}"; } return $c_macro_cache{"@_"} = eval $src; } package My::ParseSource; use constant WIN32 => ($^O =~ /Win32/i); my @dirs = ("$inc_dir", "$mod_dir/apache2/", "$base_dir/glue/perl/xsbuilder"); use base qw/ExtUtils::XSBuilder::ParseSource/; __PACKAGE__->run; system("touch $base_dir/glue/perl/xsbuilder") == 0 or die "touch $base_dir/glue/perl/xsbuilder failed: $!" unless WIN32; sub package {'APR::Request'} sub unwanted_includes {[qw/apreq_config.h apreq_private_apache2.h/]} # ParseSource.pm v 0.23 bug: line 214 should read # my @dirs = @{$self->include_dirs}; # for now, we override it here just to work around the bug sub find_includes { my $self = shift; return $self->{includes} if $self->{includes}; require File::Find; my(@dirs) = @{$self->include_dirs}; unless (-d $dirs[0]) { die "could not find include directory"; } # print "Will search @dirs for include files...\n" if ($verbose) ; my @includes; my $unwanted = join '|', @{$self -> unwanted_includes} ; for my $dir (@dirs) { File::Find::finddepth({ wanted => sub { return unless /\.h$/; return if ($unwanted && (/^($unwanted)/o)); my $dir = $File::Find::dir; push @includes, "$dir/$_"; }, follow => not WIN32, }, $dir); } return $self->{includes} = $self -> sort_includes (\@includes) ; } sub include_dirs {\@dirs} sub preprocess { # need to macro-expand APREQ_DECLARE et.al. so P::RD can DTRT with # ExtUtils::XSBuilder::C::grammar for ($_[1]) { ::c_macro("APREQ_DECLARE", "apreq.h")->(); ::c_macro("APREQ_DECLARE_HOOK", "apreq_parser.h")->(); ::c_macro("APREQ_DECLARE_PARSER", "apreq_parser.h")->(); ::c_macro("APR_DECLARE")->(); ::c_macro("XS")-> (); s/APR_INLINE//g; s/static//g; } } 1; rapache-1.2.8/libapreq2/buildconf0000755000175100017510000000432612706745114016243 0ustar ondrejondrej#!/bin/sh # # Copyright 2004-2005 The Apache Software Foundation # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. # # # buildconf: Build the support scripts needed to compile from a # checked-out version of the source code. perl="perl" libtool="libtool" aclocal="aclocal" automake="automake" autoconf="autoconf" autoheader="autoheader" while test $# -gt 0 do # Normalize case "$1" in -*=*) optarg=`echo "$1" | sed 's/[-_a-zA-Z0-9]*=//'` ;; *) optarg= ;; esac case "$1" in --with-perl=*) perl=$optarg ;; --with-libtool=*) libtool=$optarg ;; --with-aclocal=*) aclocal=$optarg ;; --with-automake=*) automake=$optarg ;; --with-autoconf=*) autoconf=$optarg ;; --with-autoheader=*) autoheader=$optarg ;; esac shift done libtoolize="${libtool}ize --automake --copy --force" echo "removing stale config files" touch .deps rm -f aclocal.m4 rm -f generated_lists rm -rf autom4te*.cache echo "checking buildconf prereqs"; $perl build/version_check.pl libtool $libtool || exit 1 $perl build/version_check.pl autoconf $autoconf || exit 1 $perl build/version_check.pl automake $automake || exit 1 $perl build/version_check.pl ExtUtils::XSBuilder || exit 1 #$perl build/version_check.pl Test::Inline || exit 1 PREREQ_PM=`$perl build/version_check.pl perl_prereqs` echo "running $libtoolize" && $libtoolize && \ echo "running $aclocal" && $aclocal && \ echo "running $autoconf" && $autoconf && \ echo "running $autoheader" && $autoheader && \ echo "running $automake -a -c" && $automake -a -c && \ echo "running xsbuilder" && (cd glue/perl && $perl ../../build/xsbuilder.pl) && \ echo "running cpan prereq fixups" && $perl -i -wpe "s/PREREQ_PM/$PREREQ_PM/" Makefile.in && \ echo "buildconf successful." rapache-1.2.8/libapreq2/config.guess0000755000175100017510000012532612706745114016674 0ustar ondrejondrej#! /bin/sh # Attempt to guess a canonical system name. # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, # 2000, 2001, 2002, 2003, 2004, 2005 Free Software Foundation, Inc. timestamp='2005-03-24' # 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 # 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. # Originally written by Per Bothner . # Please send patches to . Submit a context # diff and a properly formatted ChangeLog entry. # # This script attempts to guess a canonical system name similar to # config.sub. If it succeeds, it prints the system name on stdout, and # exits with 0. Otherwise, it exits with 1. # # The plan is that this can be called by configure scripts if you # don't specify an explicit build system type. me=`echo "$0" | sed -e 's,.*/,,'` usage="\ Usage: $0 [OPTION] Output the configuration name of the system \`$me' is run on. Operation modes: -h, --help print this help, then exit -t, --time-stamp print date of last modification, then exit -v, --version print version number, then exit Report bugs and patches to ." version="\ GNU config.guess ($timestamp) Originally written by Per Bothner. Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005 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." help=" Try \`$me --help' for more information." # Parse command line while test $# -gt 0 ; do case $1 in --time-stamp | --time* | -t ) echo "$timestamp" ; exit 0 ;; --version | -v ) echo "$version" ; exit 0 ;; --help | --h* | -h ) echo "$usage"; exit 0 ;; -- ) # Stop option processing shift; break ;; - ) # Use stdin as input. break ;; -* ) echo "$me: invalid option $1$help" >&2 exit 1 ;; * ) break ;; esac done if test $# != 0; then echo "$me: too many arguments$help" >&2 exit 1 fi trap 'exit 1' 1 2 15 # CC_FOR_BUILD -- compiler used by this script. Note that the use of a # compiler to aid in system detection is discouraged as it requires # temporary files to be created and, as you can see below, it is a # headache to deal with in a portable fashion. # Historically, `CC_FOR_BUILD' used to be named `HOST_CC'. We still # use `HOST_CC' if defined, but it is deprecated. # Portable tmp directory creation inspired by the Autoconf team. set_cc_for_build=' trap "exitcode=\$?; (rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null) && exit \$exitcode" 0 ; trap "rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null; exit 1" 1 2 13 15 ; : ${TMPDIR=/tmp} ; { tmp=`(umask 077 && mktemp -d -q "$TMPDIR/cgXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" ; } || { test -n "$RANDOM" && tmp=$TMPDIR/cg$$-$RANDOM && (umask 077 && mkdir $tmp) ; } || { tmp=$TMPDIR/cg-$$ && (umask 077 && mkdir $tmp) && echo "Warning: creating insecure temp directory" >&2 ; } || { echo "$me: cannot create a temporary directory in $TMPDIR" >&2 ; exit 1 ; } ; dummy=$tmp/dummy ; tmpfiles="$dummy.c $dummy.o $dummy.rel $dummy" ; case $CC_FOR_BUILD,$HOST_CC,$CC in ,,) echo "int x;" > $dummy.c ; for c in cc gcc c89 c99 ; do if ($c -c -o $dummy.o $dummy.c) >/dev/null 2>&1 ; then CC_FOR_BUILD="$c"; break ; fi ; done ; if test x"$CC_FOR_BUILD" = x ; then CC_FOR_BUILD=no_compiler_found ; fi ;; ,,*) CC_FOR_BUILD=$CC ;; ,*,*) CC_FOR_BUILD=$HOST_CC ;; esac ;' # This is needed to find uname on a Pyramid OSx when run in the BSD universe. # (ghazi@noc.rutgers.edu 1994-08-24) if (test -f /.attbin/uname) >/dev/null 2>&1 ; then PATH=$PATH:/.attbin ; export PATH fi UNAME_MACHINE=`(uname -m) 2>/dev/null` || UNAME_MACHINE=unknown UNAME_RELEASE=`(uname -r) 2>/dev/null` || UNAME_RELEASE=unknown UNAME_SYSTEM=`(uname -s) 2>/dev/null` || UNAME_SYSTEM=unknown UNAME_VERSION=`(uname -v) 2>/dev/null` || UNAME_VERSION=unknown # Note: order is significant - the case branches are not exclusive. case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in *:NetBSD:*:*) # NetBSD (nbsd) targets should (where applicable) match one or # more of the tupples: *-*-netbsdelf*, *-*-netbsdaout*, # *-*-netbsdecoff* and *-*-netbsd*. For targets that recently # switched to ELF, *-*-netbsd* would select the old # object file format. This provides both forward # compatibility and a consistent mechanism for selecting the # object file format. # # Note: NetBSD doesn't particularly care about the vendor # portion of the name. We always set it to "unknown". sysctl="sysctl -n hw.machine_arch" UNAME_MACHINE_ARCH=`(/sbin/$sysctl 2>/dev/null || \ /usr/sbin/$sysctl 2>/dev/null || echo unknown)` case "${UNAME_MACHINE_ARCH}" in armeb) machine=armeb-unknown ;; arm*) machine=arm-unknown ;; sh3el) machine=shl-unknown ;; sh3eb) machine=sh-unknown ;; *) machine=${UNAME_MACHINE_ARCH}-unknown ;; esac # The Operating System including object format, if it has switched # to ELF recently, or will in the future. case "${UNAME_MACHINE_ARCH}" in arm*|i386|m68k|ns32k|sh3*|sparc|vax) eval $set_cc_for_build if echo __ELF__ | $CC_FOR_BUILD -E - 2>/dev/null \ | grep __ELF__ >/dev/null then # Once all utilities can be ECOFF (netbsdecoff) or a.out (netbsdaout). # Return netbsd for either. FIX? os=netbsd else os=netbsdelf fi ;; *) os=netbsd ;; esac # The OS release # Debian GNU/NetBSD machines have a different userland, and # thus, need a distinct triplet. However, they do not need # kernel version information, so it can be replaced with a # suitable tag, in the style of linux-gnu. case "${UNAME_VERSION}" in Debian*) release='-gnu' ;; *) release=`echo ${UNAME_RELEASE}|sed -e 's/[-_].*/\./'` ;; esac # Since CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM: # contains redundant information, the shorter form: # CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM is used. echo "${machine}-${os}${release}" exit 0 ;; amd64:OpenBSD:*:*) echo x86_64-unknown-openbsd${UNAME_RELEASE} exit 0 ;; amiga:OpenBSD:*:*) echo m68k-unknown-openbsd${UNAME_RELEASE} exit 0 ;; cats:OpenBSD:*:*) echo arm-unknown-openbsd${UNAME_RELEASE} exit 0 ;; hp300:OpenBSD:*:*) echo m68k-unknown-openbsd${UNAME_RELEASE} exit 0 ;; luna88k:OpenBSD:*:*) echo m88k-unknown-openbsd${UNAME_RELEASE} exit 0 ;; mac68k:OpenBSD:*:*) echo m68k-unknown-openbsd${UNAME_RELEASE} exit 0 ;; macppc:OpenBSD:*:*) echo powerpc-unknown-openbsd${UNAME_RELEASE} exit 0 ;; mvme68k:OpenBSD:*:*) echo m68k-unknown-openbsd${UNAME_RELEASE} exit 0 ;; mvme88k:OpenBSD:*:*) echo m88k-unknown-openbsd${UNAME_RELEASE} exit 0 ;; mvmeppc:OpenBSD:*:*) echo powerpc-unknown-openbsd${UNAME_RELEASE} exit 0 ;; sgi:OpenBSD:*:*) echo mips64-unknown-openbsd${UNAME_RELEASE} exit 0 ;; sun3:OpenBSD:*:*) echo m68k-unknown-openbsd${UNAME_RELEASE} exit 0 ;; *:OpenBSD:*:*) echo ${UNAME_MACHINE}-unknown-openbsd${UNAME_RELEASE} exit 0 ;; *:ekkoBSD:*:*) echo ${UNAME_MACHINE}-unknown-ekkobsd${UNAME_RELEASE} exit 0 ;; macppc:MirBSD:*:*) echo powerppc-unknown-mirbsd${UNAME_RELEASE} exit 0 ;; *:MirBSD:*:*) echo ${UNAME_MACHINE}-unknown-mirbsd${UNAME_RELEASE} exit 0 ;; alpha:OSF1:*:*) case $UNAME_RELEASE in *4.0) UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $3}'` ;; *5.*) UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $4}'` ;; esac # According to Compaq, /usr/sbin/psrinfo has been available on # OSF/1 and Tru64 systems produced since 1995. I hope that # covers most systems running today. This code pipes the CPU # types through head -n 1, so we only detect the type of CPU 0. ALPHA_CPU_TYPE=`/usr/sbin/psrinfo -v | sed -n -e 's/^ The alpha \(.*\) processor.*$/\1/p' | head -n 1` case "$ALPHA_CPU_TYPE" in "EV4 (21064)") UNAME_MACHINE="alpha" ;; "EV4.5 (21064)") UNAME_MACHINE="alpha" ;; "LCA4 (21066/21068)") UNAME_MACHINE="alpha" ;; "EV5 (21164)") UNAME_MACHINE="alphaev5" ;; "EV5.6 (21164A)") UNAME_MACHINE="alphaev56" ;; "EV5.6 (21164PC)") UNAME_MACHINE="alphapca56" ;; "EV5.7 (21164PC)") UNAME_MACHINE="alphapca57" ;; "EV6 (21264)") UNAME_MACHINE="alphaev6" ;; "EV6.7 (21264A)") UNAME_MACHINE="alphaev67" ;; "EV6.8CB (21264C)") UNAME_MACHINE="alphaev68" ;; "EV6.8AL (21264B)") UNAME_MACHINE="alphaev68" ;; "EV6.8CX (21264D)") UNAME_MACHINE="alphaev68" ;; "EV6.9A (21264/EV69A)") UNAME_MACHINE="alphaev69" ;; "EV7 (21364)") UNAME_MACHINE="alphaev7" ;; "EV7.9 (21364A)") UNAME_MACHINE="alphaev79" ;; esac # A Pn.n version is a patched version. # A Vn.n version is a released version. # A Tn.n version is a released field test version. # A Xn.n version is an unreleased experimental baselevel. # 1.2 uses "1.2" for uname -r. echo ${UNAME_MACHINE}-dec-osf`echo ${UNAME_RELEASE} | sed -e 's/^[PVTX]//' | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` exit 0 ;; Alpha\ *:Windows_NT*:*) # How do we know it's Interix rather than the generic POSIX subsystem? # Should we change UNAME_MACHINE based on the output of uname instead # of the specific Alpha model? echo alpha-pc-interix exit 0 ;; 21064:Windows_NT:50:3) echo alpha-dec-winnt3.5 exit 0 ;; Amiga*:UNIX_System_V:4.0:*) echo m68k-unknown-sysv4 exit 0;; *:[Aa]miga[Oo][Ss]:*:*) echo ${UNAME_MACHINE}-unknown-amigaos exit 0 ;; *:[Mm]orph[Oo][Ss]:*:*) echo ${UNAME_MACHINE}-unknown-morphos exit 0 ;; *:OS/390:*:*) echo i370-ibm-openedition exit 0 ;; *:z/VM:*:*) echo s390-ibm-zvmoe exit 0 ;; *:OS400:*:*) echo powerpc-ibm-os400 exit 0 ;; arm:RISC*:1.[012]*:*|arm:riscix:1.[012]*:*) echo arm-acorn-riscix${UNAME_RELEASE} exit 0;; SR2?01:HI-UX/MPP:*:* | SR8000:HI-UX/MPP:*:*) echo hppa1.1-hitachi-hiuxmpp exit 0;; Pyramid*:OSx*:*:* | MIS*:OSx*:*:* | MIS*:SMP_DC-OSx*:*:*) # akee@wpdis03.wpafb.af.mil (Earle F. Ake) contributed MIS and NILE. if test "`(/bin/universe) 2>/dev/null`" = att ; then echo pyramid-pyramid-sysv3 else echo pyramid-pyramid-bsd fi exit 0 ;; NILE*:*:*:dcosx) echo pyramid-pyramid-svr4 exit 0 ;; DRS?6000:unix:4.0:6*) echo sparc-icl-nx6 exit 0 ;; DRS?6000:UNIX_SV:4.2*:7* | DRS?6000:isis:4.2*:7*) case `/usr/bin/uname -p` in sparc) echo sparc-icl-nx7 && exit 0 ;; esac ;; sun4H:SunOS:5.*:*) echo sparc-hal-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` exit 0 ;; sun4*:SunOS:5.*:* | tadpole*:SunOS:5.*:*) echo sparc-sun-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` exit 0 ;; i86pc:SunOS:5.*:*) echo i386-pc-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` exit 0 ;; sun4*:SunOS:6*:*) # According to config.sub, this is the proper way to canonicalize # SunOS6. Hard to guess exactly what SunOS6 will be like, but # it's likely to be more like Solaris than SunOS4. echo sparc-sun-solaris3`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` exit 0 ;; sun4*:SunOS:*:*) case "`/usr/bin/arch -k`" in Series*|S4*) UNAME_RELEASE=`uname -v` ;; esac # Japanese Language versions have a version number like `4.1.3-JL'. echo sparc-sun-sunos`echo ${UNAME_RELEASE}|sed -e 's/-/_/'` exit 0 ;; sun3*:SunOS:*:*) echo m68k-sun-sunos${UNAME_RELEASE} exit 0 ;; sun*:*:4.2BSD:*) UNAME_RELEASE=`(sed 1q /etc/motd | awk '{print substr($5,1,3)}') 2>/dev/null` test "x${UNAME_RELEASE}" = "x" && UNAME_RELEASE=3 case "`/bin/arch`" in sun3) echo m68k-sun-sunos${UNAME_RELEASE} ;; sun4) echo sparc-sun-sunos${UNAME_RELEASE} ;; esac exit 0 ;; aushp:SunOS:*:*) echo sparc-auspex-sunos${UNAME_RELEASE} exit 0 ;; # The situation for MiNT is a little confusing. The machine name # can be virtually everything (everything which is not # "atarist" or "atariste" at least should have a processor # > m68000). The system name ranges from "MiNT" over "FreeMiNT" # to the lowercase version "mint" (or "freemint"). Finally # the system name "TOS" denotes a system which is actually not # MiNT. But MiNT is downward compatible to TOS, so this should # be no problem. atarist[e]:*MiNT:*:* | atarist[e]:*mint:*:* | atarist[e]:*TOS:*:*) echo m68k-atari-mint${UNAME_RELEASE} exit 0 ;; atari*:*MiNT:*:* | atari*:*mint:*:* | atarist[e]:*TOS:*:*) echo m68k-atari-mint${UNAME_RELEASE} exit 0 ;; *falcon*:*MiNT:*:* | *falcon*:*mint:*:* | *falcon*:*TOS:*:*) echo m68k-atari-mint${UNAME_RELEASE} exit 0 ;; milan*:*MiNT:*:* | milan*:*mint:*:* | *milan*:*TOS:*:*) echo m68k-milan-mint${UNAME_RELEASE} exit 0 ;; hades*:*MiNT:*:* | hades*:*mint:*:* | *hades*:*TOS:*:*) echo m68k-hades-mint${UNAME_RELEASE} exit 0 ;; *:*MiNT:*:* | *:*mint:*:* | *:*TOS:*:*) echo m68k-unknown-mint${UNAME_RELEASE} exit 0 ;; m68k:machten:*:*) echo m68k-apple-machten${UNAME_RELEASE} exit 0 ;; powerpc:machten:*:*) echo powerpc-apple-machten${UNAME_RELEASE} exit 0 ;; RISC*:Mach:*:*) echo mips-dec-mach_bsd4.3 exit 0 ;; RISC*:ULTRIX:*:*) echo mips-dec-ultrix${UNAME_RELEASE} exit 0 ;; VAX*:ULTRIX*:*:*) echo vax-dec-ultrix${UNAME_RELEASE} exit 0 ;; 2020:CLIX:*:* | 2430:CLIX:*:*) echo clipper-intergraph-clix${UNAME_RELEASE} exit 0 ;; mips:*:*:UMIPS | mips:*:*:RISCos) eval $set_cc_for_build sed 's/^ //' << EOF >$dummy.c #ifdef __cplusplus #include /* for printf() prototype */ int main (int argc, char *argv[]) { #else int main (argc, argv) int argc; char *argv[]; { #endif #if defined (host_mips) && defined (MIPSEB) #if defined (SYSTYPE_SYSV) printf ("mips-mips-riscos%ssysv\n", argv[1]); exit (0); #endif #if defined (SYSTYPE_SVR4) printf ("mips-mips-riscos%ssvr4\n", argv[1]); exit (0); #endif #if defined (SYSTYPE_BSD43) || defined(SYSTYPE_BSD) printf ("mips-mips-riscos%sbsd\n", argv[1]); exit (0); #endif #endif exit (-1); } EOF $CC_FOR_BUILD -o $dummy $dummy.c \ && $dummy `echo "${UNAME_RELEASE}" | sed -n 's/\([0-9]*\).*/\1/p'` \ && exit 0 echo mips-mips-riscos${UNAME_RELEASE} exit 0 ;; Motorola:PowerMAX_OS:*:*) echo powerpc-motorola-powermax exit 0 ;; Motorola:*:4.3:PL8-*) echo powerpc-harris-powermax exit 0 ;; Night_Hawk:*:*:PowerMAX_OS | Synergy:PowerMAX_OS:*:*) echo powerpc-harris-powermax exit 0 ;; Night_Hawk:Power_UNIX:*:*) echo powerpc-harris-powerunix exit 0 ;; m88k:CX/UX:7*:*) echo m88k-harris-cxux7 exit 0 ;; m88k:*:4*:R4*) echo m88k-motorola-sysv4 exit 0 ;; m88k:*:3*:R3*) echo m88k-motorola-sysv3 exit 0 ;; AViiON:dgux:*:*) # DG/UX returns AViiON for all architectures UNAME_PROCESSOR=`/usr/bin/uname -p` if [ $UNAME_PROCESSOR = mc88100 ] || [ $UNAME_PROCESSOR = mc88110 ] then if [ ${TARGET_BINARY_INTERFACE}x = m88kdguxelfx ] || \ [ ${TARGET_BINARY_INTERFACE}x = x ] then echo m88k-dg-dgux${UNAME_RELEASE} else echo m88k-dg-dguxbcs${UNAME_RELEASE} fi else echo i586-dg-dgux${UNAME_RELEASE} fi exit 0 ;; M88*:DolphinOS:*:*) # DolphinOS (SVR3) echo m88k-dolphin-sysv3 exit 0 ;; M88*:*:R3*:*) # Delta 88k system running SVR3 echo m88k-motorola-sysv3 exit 0 ;; XD88*:*:*:*) # Tektronix XD88 system running UTekV (SVR3) echo m88k-tektronix-sysv3 exit 0 ;; Tek43[0-9][0-9]:UTek:*:*) # Tektronix 4300 system running UTek (BSD) echo m68k-tektronix-bsd exit 0 ;; *:IRIX*:*:*) echo mips-sgi-irix`echo ${UNAME_RELEASE}|sed -e 's/-/_/g'` exit 0 ;; ????????:AIX?:[12].1:2) # AIX 2.2.1 or AIX 2.1.1 is RT/PC AIX. echo romp-ibm-aix # uname -m gives an 8 hex-code CPU id exit 0 ;; # Note that: echo "'`uname -s`'" gives 'AIX ' i*86:AIX:*:*) echo i386-ibm-aix exit 0 ;; ia64:AIX:*:*) if [ -x /usr/bin/oslevel ] ; then IBM_REV=`/usr/bin/oslevel` else IBM_REV=${UNAME_VERSION}.${UNAME_RELEASE} fi echo ${UNAME_MACHINE}-ibm-aix${IBM_REV} exit 0 ;; *:AIX:2:3) if grep bos325 /usr/include/stdio.h >/dev/null 2>&1; then eval $set_cc_for_build sed 's/^ //' << EOF >$dummy.c #include main() { if (!__power_pc()) exit(1); puts("powerpc-ibm-aix3.2.5"); exit(0); } EOF $CC_FOR_BUILD -o $dummy $dummy.c && $dummy && exit 0 echo rs6000-ibm-aix3.2.5 elif grep bos324 /usr/include/stdio.h >/dev/null 2>&1; then echo rs6000-ibm-aix3.2.4 else echo rs6000-ibm-aix3.2 fi exit 0 ;; *:AIX:*:[45]) IBM_CPU_ID=`/usr/sbin/lsdev -C -c processor -S available | sed 1q | awk '{ print $1 }'` if /usr/sbin/lsattr -El ${IBM_CPU_ID} | grep ' POWER' >/dev/null 2>&1; then IBM_ARCH=rs6000 else IBM_ARCH=powerpc fi if [ -x /usr/bin/oslevel ] ; then IBM_REV=`/usr/bin/oslevel` else IBM_REV=${UNAME_VERSION}.${UNAME_RELEASE} fi echo ${IBM_ARCH}-ibm-aix${IBM_REV} exit 0 ;; *:AIX:*:*) echo rs6000-ibm-aix exit 0 ;; ibmrt:4.4BSD:*|romp-ibm:BSD:*) echo romp-ibm-bsd4.4 exit 0 ;; ibmrt:*BSD:*|romp-ibm:BSD:*) # covers RT/PC BSD and echo romp-ibm-bsd${UNAME_RELEASE} # 4.3 with uname added to exit 0 ;; # report: romp-ibm BSD 4.3 *:BOSX:*:*) echo rs6000-bull-bosx exit 0 ;; DPX/2?00:B.O.S.:*:*) echo m68k-bull-sysv3 exit 0 ;; 9000/[34]??:4.3bsd:1.*:*) echo m68k-hp-bsd exit 0 ;; hp300:4.4BSD:*:* | 9000/[34]??:4.3bsd:2.*:*) echo m68k-hp-bsd4.4 exit 0 ;; 9000/[34678]??:HP-UX:*:*) HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'` case "${UNAME_MACHINE}" in 9000/31? ) HP_ARCH=m68000 ;; 9000/[34]?? ) HP_ARCH=m68k ;; 9000/[678][0-9][0-9]) if [ -x /usr/bin/getconf ]; then sc_cpu_version=`/usr/bin/getconf SC_CPU_VERSION 2>/dev/null` sc_kernel_bits=`/usr/bin/getconf SC_KERNEL_BITS 2>/dev/null` case "${sc_cpu_version}" in 523) HP_ARCH="hppa1.0" ;; # CPU_PA_RISC1_0 528) HP_ARCH="hppa1.1" ;; # CPU_PA_RISC1_1 532) # CPU_PA_RISC2_0 case "${sc_kernel_bits}" in 32) HP_ARCH="hppa2.0n" ;; 64) HP_ARCH="hppa2.0w" ;; '') HP_ARCH="hppa2.0" ;; # HP-UX 10.20 esac ;; esac fi if [ "${HP_ARCH}" = "" ]; then eval $set_cc_for_build sed 's/^ //' << EOF >$dummy.c #define _HPUX_SOURCE #include #include int main () { #if defined(_SC_KERNEL_BITS) long bits = sysconf(_SC_KERNEL_BITS); #endif long cpu = sysconf (_SC_CPU_VERSION); switch (cpu) { case CPU_PA_RISC1_0: puts ("hppa1.0"); break; case CPU_PA_RISC1_1: puts ("hppa1.1"); break; case CPU_PA_RISC2_0: #if defined(_SC_KERNEL_BITS) switch (bits) { case 64: puts ("hppa2.0w"); break; case 32: puts ("hppa2.0n"); break; default: puts ("hppa2.0"); break; } break; #else /* !defined(_SC_KERNEL_BITS) */ puts ("hppa2.0"); break; #endif default: puts ("hppa1.0"); break; } exit (0); } EOF (CCOPTS= $CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null) && HP_ARCH=`$dummy` test -z "$HP_ARCH" && HP_ARCH=hppa fi ;; esac if [ ${HP_ARCH} = "hppa2.0w" ] then # avoid double evaluation of $set_cc_for_build test -n "$CC_FOR_BUILD" || eval $set_cc_for_build if echo __LP64__ | (CCOPTS= $CC_FOR_BUILD -E -) | grep __LP64__ >/dev/null then HP_ARCH="hppa2.0w" else HP_ARCH="hppa64" fi fi echo ${HP_ARCH}-hp-hpux${HPUX_REV} exit 0 ;; ia64:HP-UX:*:*) HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'` echo ia64-hp-hpux${HPUX_REV} exit 0 ;; 3050*:HI-UX:*:*) eval $set_cc_for_build sed 's/^ //' << EOF >$dummy.c #include int main () { long cpu = sysconf (_SC_CPU_VERSION); /* The order matters, because CPU_IS_HP_MC68K erroneously returns true for CPU_PA_RISC1_0. CPU_IS_PA_RISC returns correct results, however. */ if (CPU_IS_PA_RISC (cpu)) { switch (cpu) { case CPU_PA_RISC1_0: puts ("hppa1.0-hitachi-hiuxwe2"); break; case CPU_PA_RISC1_1: puts ("hppa1.1-hitachi-hiuxwe2"); break; case CPU_PA_RISC2_0: puts ("hppa2.0-hitachi-hiuxwe2"); break; default: puts ("hppa-hitachi-hiuxwe2"); break; } } else if (CPU_IS_HP_MC68K (cpu)) puts ("m68k-hitachi-hiuxwe2"); else puts ("unknown-hitachi-hiuxwe2"); exit (0); } EOF $CC_FOR_BUILD -o $dummy $dummy.c && $dummy && exit 0 echo unknown-hitachi-hiuxwe2 exit 0 ;; 9000/7??:4.3bsd:*:* | 9000/8?[79]:4.3bsd:*:* ) echo hppa1.1-hp-bsd exit 0 ;; 9000/8??:4.3bsd:*:*) echo hppa1.0-hp-bsd exit 0 ;; *9??*:MPE/iX:*:* | *3000*:MPE/iX:*:*) echo hppa1.0-hp-mpeix exit 0 ;; hp7??:OSF1:*:* | hp8?[79]:OSF1:*:* ) echo hppa1.1-hp-osf exit 0 ;; hp8??:OSF1:*:*) echo hppa1.0-hp-osf exit 0 ;; i*86:OSF1:*:*) if [ -x /usr/sbin/sysversion ] ; then echo ${UNAME_MACHINE}-unknown-osf1mk else echo ${UNAME_MACHINE}-unknown-osf1 fi exit 0 ;; parisc*:Lites*:*:*) echo hppa1.1-hp-lites exit 0 ;; C1*:ConvexOS:*:* | convex:ConvexOS:C1*:*) echo c1-convex-bsd exit 0 ;; C2*:ConvexOS:*:* | convex:ConvexOS:C2*:*) if getsysinfo -f scalar_acc then echo c32-convex-bsd else echo c2-convex-bsd fi exit 0 ;; C34*:ConvexOS:*:* | convex:ConvexOS:C34*:*) echo c34-convex-bsd exit 0 ;; C38*:ConvexOS:*:* | convex:ConvexOS:C38*:*) echo c38-convex-bsd exit 0 ;; C4*:ConvexOS:*:* | convex:ConvexOS:C4*:*) echo c4-convex-bsd exit 0 ;; CRAY*Y-MP:*:*:*) echo ymp-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' exit 0 ;; CRAY*[A-Z]90:*:*:*) echo ${UNAME_MACHINE}-cray-unicos${UNAME_RELEASE} \ | sed -e 's/CRAY.*\([A-Z]90\)/\1/' \ -e y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/ \ -e 's/\.[^.]*$/.X/' exit 0 ;; CRAY*TS:*:*:*) echo t90-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' exit 0 ;; CRAY*T3E:*:*:*) echo alphaev5-cray-unicosmk${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' exit 0 ;; CRAY*SV1:*:*:*) echo sv1-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' exit 0 ;; *:UNICOS/mp:*:*) echo craynv-cray-unicosmp${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' exit 0 ;; F30[01]:UNIX_System_V:*:* | F700:UNIX_System_V:*:*) FUJITSU_PROC=`uname -m | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'` FUJITSU_REL=`echo ${UNAME_RELEASE} | sed -e 's/ /_/'` echo "${FUJITSU_PROC}-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" exit 0 ;; 5000:UNIX_System_V:4.*:*) FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'` FUJITSU_REL=`echo ${UNAME_RELEASE} | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/ /_/'` echo "sparc-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" exit 0 ;; i*86:BSD/386:*:* | i*86:BSD/OS:*:* | *:Ascend\ Embedded/OS:*:*) echo ${UNAME_MACHINE}-pc-bsdi${UNAME_RELEASE} exit 0 ;; sparc*:BSD/OS:*:*) echo sparc-unknown-bsdi${UNAME_RELEASE} exit 0 ;; *:BSD/OS:*:*) echo ${UNAME_MACHINE}-unknown-bsdi${UNAME_RELEASE} exit 0 ;; *:FreeBSD:*:*) echo ${UNAME_MACHINE}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` exit 0 ;; i*:CYGWIN*:*) echo ${UNAME_MACHINE}-pc-cygwin exit 0 ;; i*:MINGW*:*) echo ${UNAME_MACHINE}-pc-mingw32 exit 0 ;; i*:PW*:*) echo ${UNAME_MACHINE}-pc-pw32 exit 0 ;; x86:Interix*:[34]*) echo i586-pc-interix${UNAME_RELEASE}|sed -e 's/\..*//' exit 0 ;; [345]86:Windows_95:* | [345]86:Windows_98:* | [345]86:Windows_NT:*) echo i${UNAME_MACHINE}-pc-mks exit 0 ;; i*:Windows_NT*:* | Pentium*:Windows_NT*:*) # How do we know it's Interix rather than the generic POSIX subsystem? # It also conflicts with pre-2.0 versions of AT&T UWIN. Should we # UNAME_MACHINE based on the output of uname instead of i386? echo i586-pc-interix exit 0 ;; i*:UWIN*:*) echo ${UNAME_MACHINE}-pc-uwin exit 0 ;; amd64:CYGWIN*:*:*) echo x86_64-unknown-cygwin exit 0 ;; p*:CYGWIN*:*) echo powerpcle-unknown-cygwin exit 0 ;; prep*:SunOS:5.*:*) echo powerpcle-unknown-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` exit 0 ;; *:GNU:*:*) # the GNU system echo `echo ${UNAME_MACHINE}|sed -e 's,[-/].*$,,'`-unknown-gnu`echo ${UNAME_RELEASE}|sed -e 's,/.*$,,'` exit 0 ;; *:GNU/*:*:*) # other systems with GNU libc and userland echo ${UNAME_MACHINE}-unknown-`echo ${UNAME_SYSTEM} | sed 's,^[^/]*/,,' | tr '[A-Z]' '[a-z]'``echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`-gnu exit 0 ;; i*86:Minix:*:*) echo ${UNAME_MACHINE}-pc-minix exit 0 ;; arm*:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu exit 0 ;; cris:Linux:*:*) echo cris-axis-linux-gnu exit 0 ;; crisv32:Linux:*:*) echo crisv32-axis-linux-gnu exit 0 ;; frv:Linux:*:*) echo frv-unknown-linux-gnu exit 0 ;; ia64:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu exit 0 ;; m32r*:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu exit 0 ;; m68*:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu exit 0 ;; mips:Linux:*:*) eval $set_cc_for_build sed 's/^ //' << EOF >$dummy.c #undef CPU #undef mips #undef mipsel #if defined(__MIPSEL__) || defined(__MIPSEL) || defined(_MIPSEL) || defined(MIPSEL) CPU=mipsel #else #if defined(__MIPSEB__) || defined(__MIPSEB) || defined(_MIPSEB) || defined(MIPSEB) CPU=mips #else CPU= #endif #endif EOF eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep ^CPU=` test x"${CPU}" != x && echo "${CPU}-unknown-linux-gnu" && exit 0 ;; mips64:Linux:*:*) eval $set_cc_for_build sed 's/^ //' << EOF >$dummy.c #undef CPU #undef mips64 #undef mips64el #if defined(__MIPSEL__) || defined(__MIPSEL) || defined(_MIPSEL) || defined(MIPSEL) CPU=mips64el #else #if defined(__MIPSEB__) || defined(__MIPSEB) || defined(_MIPSEB) || defined(MIPSEB) CPU=mips64 #else CPU= #endif #endif EOF eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep ^CPU=` test x"${CPU}" != x && echo "${CPU}-unknown-linux-gnu" && exit 0 ;; ppc:Linux:*:*) echo powerpc-unknown-linux-gnu exit 0 ;; ppc64:Linux:*:*) echo powerpc64-unknown-linux-gnu exit 0 ;; alpha:Linux:*:*) case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' < /proc/cpuinfo` in EV5) UNAME_MACHINE=alphaev5 ;; EV56) UNAME_MACHINE=alphaev56 ;; PCA56) UNAME_MACHINE=alphapca56 ;; PCA57) UNAME_MACHINE=alphapca56 ;; EV6) UNAME_MACHINE=alphaev6 ;; EV67) UNAME_MACHINE=alphaev67 ;; EV68*) UNAME_MACHINE=alphaev68 ;; esac objdump --private-headers /bin/sh | grep ld.so.1 >/dev/null if test "$?" = 0 ; then LIBC="libc1" ; else LIBC="" ; fi echo ${UNAME_MACHINE}-unknown-linux-gnu${LIBC} exit 0 ;; parisc:Linux:*:* | hppa:Linux:*:*) # Look for CPU level case `grep '^cpu[^a-z]*:' /proc/cpuinfo 2>/dev/null | cut -d' ' -f2` in PA7*) echo hppa1.1-unknown-linux-gnu ;; PA8*) echo hppa2.0-unknown-linux-gnu ;; *) echo hppa-unknown-linux-gnu ;; esac exit 0 ;; parisc64:Linux:*:* | hppa64:Linux:*:*) echo hppa64-unknown-linux-gnu exit 0 ;; s390:Linux:*:* | s390x:Linux:*:*) echo ${UNAME_MACHINE}-ibm-linux exit 0 ;; sh64*:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu exit 0 ;; sh*:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu exit 0 ;; sparc:Linux:*:* | sparc64:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu exit 0 ;; x86_64:Linux:*:*) echo x86_64-unknown-linux-gnu exit 0 ;; i*86:Linux:*:*) # The BFD linker knows what the default object file format is, so # first see if it will tell us. cd to the root directory to prevent # problems with other programs or directories called `ld' in the path. # Set LC_ALL=C to ensure ld outputs messages in English. ld_supported_targets=`cd /; LC_ALL=C ld --help 2>&1 \ | sed -ne '/supported targets:/!d s/[ ][ ]*/ /g s/.*supported targets: *// s/ .*// p'` case "$ld_supported_targets" in elf32-i386) TENTATIVE="${UNAME_MACHINE}-pc-linux-gnu" ;; a.out-i386-linux) echo "${UNAME_MACHINE}-pc-linux-gnuaout" exit 0 ;; coff-i386) echo "${UNAME_MACHINE}-pc-linux-gnucoff" exit 0 ;; "") # Either a pre-BFD a.out linker (linux-gnuoldld) or # one that does not give us useful --help. echo "${UNAME_MACHINE}-pc-linux-gnuoldld" exit 0 ;; esac # Determine whether the default compiler is a.out or elf eval $set_cc_for_build sed 's/^ //' << EOF >$dummy.c #include #ifdef __ELF__ # ifdef __GLIBC__ # if __GLIBC__ >= 2 LIBC=gnu # else LIBC=gnulibc1 # endif # else LIBC=gnulibc1 # endif #else #ifdef __INTEL_COMPILER LIBC=gnu #else LIBC=gnuaout #endif #endif #ifdef __dietlibc__ LIBC=dietlibc #endif EOF eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep ^LIBC=` test x"${LIBC}" != x && echo "${UNAME_MACHINE}-pc-linux-${LIBC}" && exit 0 test x"${TENTATIVE}" != x && echo "${TENTATIVE}" && exit 0 ;; i*86:DYNIX/ptx:4*:*) # ptx 4.0 does uname -s correctly, with DYNIX/ptx in there. # earlier versions are messed up and put the nodename in both # sysname and nodename. echo i386-sequent-sysv4 exit 0 ;; i*86:UNIX_SV:4.2MP:2.*) # Unixware is an offshoot of SVR4, but it has its own version # number series starting with 2... # I am not positive that other SVR4 systems won't match this, # I just have to hope. -- rms. # Use sysv4.2uw... so that sysv4* matches it. echo ${UNAME_MACHINE}-pc-sysv4.2uw${UNAME_VERSION} exit 0 ;; i*86:OS/2:*:*) # If we were able to find `uname', then EMX Unix compatibility # is probably installed. echo ${UNAME_MACHINE}-pc-os2-emx exit 0 ;; i*86:XTS-300:*:STOP) echo ${UNAME_MACHINE}-unknown-stop exit 0 ;; i*86:atheos:*:*) echo ${UNAME_MACHINE}-unknown-atheos exit 0 ;; i*86:syllable:*:*) echo ${UNAME_MACHINE}-pc-syllable exit 0 ;; i*86:LynxOS:2.*:* | i*86:LynxOS:3.[01]*:* | i*86:LynxOS:4.0*:*) echo i386-unknown-lynxos${UNAME_RELEASE} exit 0 ;; i*86:*DOS:*:*) echo ${UNAME_MACHINE}-pc-msdosdjgpp exit 0 ;; i*86:*:4.*:* | i*86:SYSTEM_V:4.*:*) UNAME_REL=`echo ${UNAME_RELEASE} | sed 's/\/MP$//'` if grep Novell /usr/include/link.h >/dev/null 2>/dev/null; then echo ${UNAME_MACHINE}-univel-sysv${UNAME_REL} else echo ${UNAME_MACHINE}-pc-sysv${UNAME_REL} fi exit 0 ;; i*86:*:5:[78]*) case `/bin/uname -X | grep "^Machine"` in *486*) UNAME_MACHINE=i486 ;; *Pentium) UNAME_MACHINE=i586 ;; *Pent*|*Celeron) UNAME_MACHINE=i686 ;; esac echo ${UNAME_MACHINE}-unknown-sysv${UNAME_RELEASE}${UNAME_SYSTEM}${UNAME_VERSION} exit 0 ;; i*86:*:3.2:*) if test -f /usr/options/cb.name; then UNAME_REL=`sed -n 's/.*Version //p' /dev/null >/dev/null ; then UNAME_REL=`(/bin/uname -X|grep Release|sed -e 's/.*= //')` (/bin/uname -X|grep i80486 >/dev/null) && UNAME_MACHINE=i486 (/bin/uname -X|grep '^Machine.*Pentium' >/dev/null) \ && UNAME_MACHINE=i586 (/bin/uname -X|grep '^Machine.*Pent *II' >/dev/null) \ && UNAME_MACHINE=i686 (/bin/uname -X|grep '^Machine.*Pentium Pro' >/dev/null) \ && UNAME_MACHINE=i686 echo ${UNAME_MACHINE}-pc-sco$UNAME_REL else echo ${UNAME_MACHINE}-pc-sysv32 fi exit 0 ;; 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 i386. echo i386-pc-msdosdjgpp exit 0 ;; Intel:Mach:3*:*) echo i386-pc-mach3 exit 0 ;; paragon:*:*:*) echo i860-intel-osf1 exit 0 ;; i860:*:4.*:*) # i860-SVR4 if grep Stardent /usr/include/sys/uadmin.h >/dev/null 2>&1 ; then echo i860-stardent-sysv${UNAME_RELEASE} # Stardent Vistra i860-SVR4 else # Add other i860-SVR4 vendors below as they are discovered. echo i860-unknown-sysv${UNAME_RELEASE} # Unknown i860-SVR4 fi exit 0 ;; mini*:CTIX:SYS*5:*) # "miniframe" echo m68010-convergent-sysv exit 0 ;; mc68k:UNIX:SYSTEM5:3.51m) echo m68k-convergent-sysv exit 0 ;; M680?0:D-NIX:5.3:*) echo m68k-diab-dnix exit 0 ;; M68*:*:R3V[5678]*:*) test -r /sysV68 && echo 'm68k-motorola-sysv' && exit 0 ;; 3[345]??:*:4.0:3.0 | 3[34]??A:*:4.0:3.0 | 3[34]??,*:*:4.0:3.0 | 3[34]??/*:*:4.0:3.0 | 4400:*:4.0:3.0 | 4850:*:4.0:3.0 | SKA40:*:4.0:3.0 | SDS2:*:4.0:3.0 | SHG2:*:4.0:3.0 | S7501*:*:4.0:3.0) OS_REL='' 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 0 /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \ && echo i586-ncr-sysv4.3${OS_REL} && exit 0 ;; 3[34]??:*:4.0:* | 3[34]??,*:*:4.0:*) /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ && echo i486-ncr-sysv4 && exit 0 ;; m68*:LynxOS:2.*:* | m68*:LynxOS:3.0*:*) echo m68k-unknown-lynxos${UNAME_RELEASE} exit 0 ;; mc68030:UNIX_System_V:4.*:*) echo m68k-atari-sysv4 exit 0 ;; TSUNAMI:LynxOS:2.*:*) echo sparc-unknown-lynxos${UNAME_RELEASE} exit 0 ;; rs6000:LynxOS:2.*:*) echo rs6000-unknown-lynxos${UNAME_RELEASE} exit 0 ;; PowerPC:LynxOS:2.*:* | PowerPC:LynxOS:3.[01]*:* | PowerPC:LynxOS:4.0*:*) echo powerpc-unknown-lynxos${UNAME_RELEASE} exit 0 ;; SM[BE]S:UNIX_SV:*:*) echo mips-dde-sysv${UNAME_RELEASE} exit 0 ;; RM*:ReliantUNIX-*:*:*) echo mips-sni-sysv4 exit 0 ;; RM*:SINIX-*:*:*) echo mips-sni-sysv4 exit 0 ;; *:SINIX-*:*:*) if uname -p 2>/dev/null >/dev/null ; then UNAME_MACHINE=`(uname -p) 2>/dev/null` echo ${UNAME_MACHINE}-sni-sysv4 else echo ns32k-sni-sysv fi exit 0 ;; PENTIUM:*:4.0*:*) # Unisys `ClearPath HMP IX 4000' SVR4/MP effort # says echo i586-unisys-sysv4 exit 0 ;; *:UNIX_System_V:4*:FTX*) # From Gerald Hewes . # How about differentiating between stratus architectures? -djm echo hppa1.1-stratus-sysv4 exit 0 ;; *:*:*:FTX*) # From seanf@swdc.stratus.com. echo i860-stratus-sysv4 exit 0 ;; *:VOS:*:*) # From Paul.Green@stratus.com. echo hppa1.1-stratus-vos exit 0 ;; mc68*:A/UX:*:*) echo m68k-apple-aux${UNAME_RELEASE} exit 0 ;; news*:NEWS-OS:6*:*) echo mips-sony-newsos6 exit 0 ;; R[34]000:*System_V*:*:* | R4000:UNIX_SYSV:*:* | R*000:UNIX_SV:*:*) if [ -d /usr/nec ]; then echo mips-nec-sysv${UNAME_RELEASE} else echo mips-unknown-sysv${UNAME_RELEASE} fi exit 0 ;; BeBox:BeOS:*:*) # BeOS running on hardware made by Be, PPC only. echo powerpc-be-beos exit 0 ;; BeMac:BeOS:*:*) # BeOS running on Mac or Mac clone, PPC only. echo powerpc-apple-beos exit 0 ;; BePC:BeOS:*:*) # BeOS running on Intel PC compatible. echo i586-pc-beos exit 0 ;; SX-4:SUPER-UX:*:*) echo sx4-nec-superux${UNAME_RELEASE} exit 0 ;; SX-5:SUPER-UX:*:*) echo sx5-nec-superux${UNAME_RELEASE} exit 0 ;; SX-6:SUPER-UX:*:*) echo sx6-nec-superux${UNAME_RELEASE} exit 0 ;; Power*:Rhapsody:*:*) echo powerpc-apple-rhapsody${UNAME_RELEASE} exit 0 ;; *:Rhapsody:*:*) echo ${UNAME_MACHINE}-apple-rhapsody${UNAME_RELEASE} exit 0 ;; *:Darwin:*:*) UNAME_PROCESSOR=`uname -p` || UNAME_PROCESSOR=unknown case $UNAME_PROCESSOR in *86) UNAME_PROCESSOR=i686 ;; unknown) UNAME_PROCESSOR=powerpc ;; esac echo ${UNAME_PROCESSOR}-apple-darwin${UNAME_RELEASE} exit 0 ;; *:procnto*:*:* | *:QNX:[0123456789]*:*) UNAME_PROCESSOR=`uname -p` if test "$UNAME_PROCESSOR" = "x86"; then UNAME_PROCESSOR=i386 UNAME_MACHINE=pc fi echo ${UNAME_PROCESSOR}-${UNAME_MACHINE}-nto-qnx${UNAME_RELEASE} exit 0 ;; *:QNX:*:4*) echo i386-pc-qnx exit 0 ;; NSE-?:NONSTOP_KERNEL:*:*) echo nse-tandem-nsk${UNAME_RELEASE} exit 0 ;; NSR-?:NONSTOP_KERNEL:*:*) echo nsr-tandem-nsk${UNAME_RELEASE} exit 0 ;; *:NonStop-UX:*:*) echo mips-compaq-nonstopux exit 0 ;; BS2000:POSIX*:*:*) echo bs2000-siemens-sysv exit 0 ;; DS/*:UNIX_System_V:*:*) echo ${UNAME_MACHINE}-${UNAME_SYSTEM}-${UNAME_RELEASE} exit 0 ;; *:Plan9:*:*) # "uname -m" is not consistent, so use $cputype instead. 386 # is converted to i386 for consistency with other x86 # operating systems. if test "$cputype" = "386"; then UNAME_MACHINE=i386 else UNAME_MACHINE="$cputype" fi echo ${UNAME_MACHINE}-unknown-plan9 exit 0 ;; *:TOPS-10:*:*) echo pdp10-unknown-tops10 exit 0 ;; *:TENEX:*:*) echo pdp10-unknown-tenex exit 0 ;; KS10:TOPS-20:*:* | KL10:TOPS-20:*:* | TYPE4:TOPS-20:*:*) echo pdp10-dec-tops20 exit 0 ;; XKL-1:TOPS-20:*:* | TYPE5:TOPS-20:*:*) echo pdp10-xkl-tops20 exit 0 ;; *:TOPS-20:*:*) echo pdp10-unknown-tops20 exit 0 ;; *:ITS:*:*) echo pdp10-unknown-its exit 0 ;; SEI:*:*:SEIUX) echo mips-sei-seiux${UNAME_RELEASE} exit 0 ;; *:DragonFly:*:*) echo ${UNAME_MACHINE}-unknown-dragonfly`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` exit 0 ;; *:*VMS:*:*) UNAME_MACHINE=`(uname -p) 2>/dev/null` case "${UNAME_MACHINE}" in A*) echo alpha-dec-vms && exit 0 ;; I*) echo ia64-dec-vms && exit 0 ;; V*) echo vax-dec-vms && exit 0 ;; esac ;; *:XENIX:*:SysV) echo i386-pc-xenix exit 0 ;; esac #echo '(No uname command or uname output not recognized.)' 1>&2 #echo "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" 1>&2 eval $set_cc_for_build cat >$dummy.c < # include #endif main () { #if defined (sony) #if defined (MIPSEB) /* BFD wants "bsd" instead of "newsos". Perhaps BFD should be changed, I don't know.... */ printf ("mips-sony-bsd\n"); exit (0); #else #include printf ("m68k-sony-newsos%s\n", #ifdef NEWSOS4 "4" #else "" #endif ); exit (0); #endif #endif #if defined (__arm) && defined (__acorn) && defined (__unix) printf ("arm-acorn-riscix"); exit (0); #endif #if defined (hp300) && !defined (hpux) printf ("m68k-hp-bsd\n"); exit (0); #endif #if defined (NeXT) #if !defined (__ARCHITECTURE__) #define __ARCHITECTURE__ "m68k" #endif int version; version=`(hostinfo | sed -n 's/.*NeXT Mach \([0-9]*\).*/\1/p') 2>/dev/null`; if (version < 4) printf ("%s-next-nextstep%d\n", __ARCHITECTURE__, version); else printf ("%s-next-openstep%d\n", __ARCHITECTURE__, version); exit (0); #endif #if defined (MULTIMAX) || defined (n16) #if defined (UMAXV) printf ("ns32k-encore-sysv\n"); exit (0); #else #if defined (CMU) printf ("ns32k-encore-mach\n"); exit (0); #else printf ("ns32k-encore-bsd\n"); exit (0); #endif #endif #endif #if defined (__386BSD__) printf ("i386-pc-bsd\n"); exit (0); #endif #if defined (sequent) #if defined (i386) printf ("i386-sequent-dynix\n"); exit (0); #endif #if defined (ns32000) printf ("ns32k-sequent-dynix\n"); exit (0); #endif #endif #if defined (_SEQUENT_) struct utsname un; uname(&un); if (strncmp(un.version, "V2", 2) == 0) { printf ("i386-sequent-ptx2\n"); exit (0); } if (strncmp(un.version, "V1", 2) == 0) { /* XXX is V1 correct? */ printf ("i386-sequent-ptx1\n"); exit (0); } printf ("i386-sequent-ptx\n"); exit (0); #endif #if defined (vax) # if !defined (ultrix) # include # if defined (BSD) # if BSD == 43 printf ("vax-dec-bsd4.3\n"); exit (0); # else # if BSD == 199006 printf ("vax-dec-bsd4.3reno\n"); exit (0); # else printf ("vax-dec-bsd\n"); exit (0); # endif # endif # else printf ("vax-dec-bsd\n"); exit (0); # endif # else printf ("vax-dec-ultrix\n"); exit (0); # endif #endif #if defined (alliant) && defined (i860) printf ("i860-alliant-bsd\n"); exit (0); #endif exit (1); } EOF $CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null && $dummy && exit 0 # Apollos put the system type in the environment. test -d /usr/apollo && { echo ${ISP}-apollo-${SYSTYPE}; exit 0; } # Convex versions that predate uname can use getsysinfo(1) if [ -x /usr/convex/getsysinfo ] then case `getsysinfo -f cpu_type` in c1*) echo c1-convex-bsd exit 0 ;; c2*) if getsysinfo -f scalar_acc then echo c32-convex-bsd else echo c2-convex-bsd fi exit 0 ;; c34*) echo c34-convex-bsd exit 0 ;; c38*) echo c38-convex-bsd exit 0 ;; c4*) echo c4-convex-bsd exit 0 ;; esac fi cat >&2 < in order to provide the needed information to handle your system. config.guess timestamp = $timestamp uname -m = `(uname -m) 2>/dev/null || echo unknown` uname -r = `(uname -r) 2>/dev/null || echo unknown` uname -s = `(uname -s) 2>/dev/null || echo unknown` uname -v = `(uname -v) 2>/dev/null || echo unknown` /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null` /bin/uname -X = `(/bin/uname -X) 2>/dev/null` hostinfo = `(hostinfo) 2>/dev/null` /bin/universe = `(/bin/universe) 2>/dev/null` /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null` /bin/arch = `(/bin/arch) 2>/dev/null` /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null` /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null` UNAME_MACHINE = ${UNAME_MACHINE} UNAME_RELEASE = ${UNAME_RELEASE} UNAME_SYSTEM = ${UNAME_SYSTEM} UNAME_VERSION = ${UNAME_VERSION} EOF exit 1 # Local variables: # eval: (add-hook 'write-file-hooks 'time-stamp) # time-stamp-start: "timestamp='" # time-stamp-format: "%:y-%02m-%02d" # time-stamp-end: "'" # End: rapache-1.2.8/libapreq2/config.sub0000755000175100017510000007540712706745114016343 0ustar ondrejondrej#! /bin/sh # Configuration validation subroutine script. # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, # 2000, 2001, 2002, 2003, 2004, 2005 Free Software Foundation, Inc. timestamp='2005-02-10' # This file is (in principle) common to ALL GNU software. # The presence of a machine in this file suggests that SOME GNU software # can handle that machine. It does not imply ALL GNU software can. # # 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 # 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. # Please send patches to . Submit a context # diff and a properly formatted ChangeLog entry. # # Configuration subroutine to validate and canonicalize a configuration type. # Supply the specified configuration type as an argument. # If it is invalid, we print an error message on stderr and exit with code 1. # Otherwise, we print the canonical config type on stdout and succeed. # This file is supposed to be the same for all GNU packages # and recognize all the CPU types, system types and aliases # that are meaningful with *any* GNU software. # Each package is responsible for reporting which valid configurations # it does not support. The user should be able to distinguish # a failure to support a valid configuration from a meaningless # configuration. # The goal of this file is to map all the various variations of a given # machine specification into a single specification in the form: # CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM # or in some cases, the newer four-part form: # CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM # It is wrong to echo any other type of specification. me=`echo "$0" | sed -e 's,.*/,,'` usage="\ Usage: $0 [OPTION] CPU-MFR-OPSYS $0 [OPTION] ALIAS Canonicalize a configuration name. Operation modes: -h, --help print this help, then exit -t, --time-stamp print date of last modification, then exit -v, --version print version number, then exit Report bugs and patches to ." version="\ GNU config.sub ($timestamp) Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005 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." help=" Try \`$me --help' for more information." # Parse command line while test $# -gt 0 ; do case $1 in --time-stamp | --time* | -t ) echo "$timestamp" ; exit 0 ;; --version | -v ) echo "$version" ; exit 0 ;; --help | --h* | -h ) echo "$usage"; exit 0 ;; -- ) # Stop option processing shift; break ;; - ) # Use stdin as input. break ;; -* ) echo "$me: invalid option $1$help" exit 1 ;; *local*) # First pass through any local machine types. echo $1 exit 0;; * ) break ;; esac done case $# in 0) echo "$me: missing argument$help" >&2 exit 1;; 1) ;; *) echo "$me: too many arguments$help" >&2 exit 1;; esac # Separate what the user gave into CPU-COMPANY and OS or KERNEL-OS (if any). # Here we must recognize all the valid KERNEL-OS combinations. maybe_os=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\2/'` case $maybe_os in nto-qnx* | linux-gnu* | linux-dietlibc | linux-uclibc* | uclinux-uclibc* | uclinux-gnu* | \ kfreebsd*-gnu* | knetbsd*-gnu* | netbsd*-gnu* | storm-chaos* | os2-emx* | rtmk-nova*) os=-$maybe_os basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'` ;; *) basic_machine=`echo $1 | sed 's/-[^-]*$//'` if [ $basic_machine != $1 ] then os=`echo $1 | sed 's/.*-/-/'` else os=; fi ;; esac ### Let's recognize common machines as not being operating systems so ### that things like config.sub decstation-3100 work. We also ### recognize some manufacturers as not being operating systems, so we ### can provide default operating systems below. case $os in -sun*os*) # Prevent following clause from handling this invalid input. ;; -dec* | -mips* | -sequent* | -encore* | -pc532* | -sgi* | -sony* | \ -att* | -7300* | -3300* | -delta* | -motorola* | -sun[234]* | \ -unicom* | -ibm* | -next | -hp | -isi* | -apollo | -altos* | \ -convergent* | -ncr* | -news | -32* | -3600* | -3100* | -hitachi* |\ -c[123]* | -convex* | -sun | -crds | -omron* | -dg | -ultra | -tti* | \ -harris | -dolphin | -highlevel | -gould | -cbm | -ns | -masscomp | \ -apple | -axis | -knuth | -cray) os= basic_machine=$1 ;; -sim | -cisco | -oki | -wec | -winbond) os= basic_machine=$1 ;; -scout) ;; -wrs) os=-vxworks basic_machine=$1 ;; -chorusos*) os=-chorusos basic_machine=$1 ;; -chorusrdb) os=-chorusrdb basic_machine=$1 ;; -hiux*) os=-hiuxwe2 ;; -sco5) os=-sco3.2v5 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; -sco4) os=-sco3.2v4 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; -sco3.2.[4-9]*) os=`echo $os | sed -e 's/sco3.2./sco3.2v/'` basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; -sco3.2v[4-9]*) # Don't forget version if it is 3.2v4 or newer. basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; -sco*) os=-sco3.2v2 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; -udk*) basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; -isc) os=-isc2.2 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; -clix*) basic_machine=clipper-intergraph ;; -isc*) basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; -lynx*) os=-lynxos ;; -ptx*) basic_machine=`echo $1 | sed -e 's/86-.*/86-sequent/'` ;; -windowsnt*) os=`echo $os | sed -e 's/windowsnt/winnt/'` ;; -psos*) os=-psos ;; -mint | -mint[0-9]*) basic_machine=m68k-atari os=-mint ;; esac # Decode aliases for certain CPU-COMPANY combinations. case $basic_machine in # Recognize the basic CPU types without company name. # Some are omitted here because they have special meanings below. 1750a | 580 \ | a29k \ | alpha | alphaev[4-8] | alphaev56 | alphaev6[78] | alphapca5[67] \ | alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] | alpha64pca5[67] \ | am33_2.0 \ | arc | arm | arm[bl]e | arme[lb] | armv[2345] | armv[345][lb] | avr \ | c4x | clipper \ | d10v | d30v | dlx | dsp16xx \ | fr30 | frv \ | h8300 | h8500 | hppa | hppa1.[01] | hppa2.0 | hppa2.0[nw] | hppa64 \ | i370 | i860 | i960 | ia64 \ | ip2k | iq2000 \ | m32r | m32rle | m68000 | m68k | m88k | maxq | mcore \ | mips | mipsbe | mipseb | mipsel | mipsle \ | mips16 \ | mips64 | mips64el \ | mips64vr | mips64vrel \ | mips64orion | mips64orionel \ | mips64vr4100 | mips64vr4100el \ | mips64vr4300 | mips64vr4300el \ | mips64vr5000 | mips64vr5000el \ | mipsisa32 | mipsisa32el \ | mipsisa32r2 | mipsisa32r2el \ | mipsisa64 | mipsisa64el \ | mipsisa64r2 | mipsisa64r2el \ | mipsisa64sb1 | mipsisa64sb1el \ | mipsisa64sr71k | mipsisa64sr71kel \ | mipstx39 | mipstx39el \ | mn10200 | mn10300 \ | msp430 \ | ns16k | ns32k \ | openrisc | or32 \ | pdp10 | pdp11 | pj | pjl \ | powerpc | powerpc64 | powerpc64le | powerpcle | ppcbe \ | pyramid \ | sh | sh[1234] | sh[23]e | sh[34]eb | shbe | shle | sh[1234]le | sh3ele \ | sh64 | sh64le \ | sparc | sparc64 | sparc86x | sparclet | sparclite | sparcv8 | sparcv9 | sparcv9b \ | strongarm \ | tahoe | thumb | tic4x | tic80 | tron \ | v850 | v850e \ | we32k \ | x86 | xscale | xscalee[bl] | xstormy16 | xtensa \ | z8k) basic_machine=$basic_machine-unknown ;; m6811 | m68hc11 | m6812 | m68hc12) # Motorola 68HC11/12. basic_machine=$basic_machine-unknown os=-none ;; m88110 | m680[12346]0 | m683?2 | m68360 | m5200 | v70 | w65 | z8k) ;; # We use `pc' rather than `unknown' # because (1) that's what they normally are, and # (2) the word "unknown" tends to confuse beginning users. i*86 | x86_64) basic_machine=$basic_machine-pc ;; # Object if more than one company name word. *-*-*) echo Invalid configuration \`$1\': machine \`$basic_machine\' not recognized 1>&2 exit 1 ;; # Recognize the basic CPU types with company name. 580-* \ | a29k-* \ | alpha-* | alphaev[4-8]-* | alphaev56-* | alphaev6[78]-* \ | alpha64-* | alpha64ev[4-8]-* | alpha64ev56-* | alpha64ev6[78]-* \ | alphapca5[67]-* | alpha64pca5[67]-* | arc-* \ | arm-* | armbe-* | armle-* | armeb-* | armv*-* \ | avr-* \ | bs2000-* \ | c[123]* | c30-* | [cjt]90-* | c4x-* | c54x-* | c55x-* | c6x-* \ | clipper-* | craynv-* | cydra-* \ | d10v-* | d30v-* | dlx-* \ | elxsi-* \ | f30[01]-* | f700-* | fr30-* | frv-* | fx80-* \ | h8300-* | h8500-* \ | hppa-* | hppa1.[01]-* | hppa2.0-* | hppa2.0[nw]-* | hppa64-* \ | i*86-* | i860-* | i960-* | ia64-* \ | ip2k-* | iq2000-* \ | m32r-* | m32rle-* \ | m68000-* | m680[012346]0-* | m68360-* | m683?2-* | m68k-* \ | m88110-* | m88k-* | maxq-* | mcore-* \ | mips-* | mipsbe-* | mipseb-* | mipsel-* | mipsle-* \ | mips16-* \ | mips64-* | mips64el-* \ | mips64vr-* | mips64vrel-* \ | mips64orion-* | mips64orionel-* \ | mips64vr4100-* | mips64vr4100el-* \ | mips64vr4300-* | mips64vr4300el-* \ | mips64vr5000-* | mips64vr5000el-* \ | mipsisa32-* | mipsisa32el-* \ | mipsisa32r2-* | mipsisa32r2el-* \ | mipsisa64-* | mipsisa64el-* \ | mipsisa64r2-* | mipsisa64r2el-* \ | mipsisa64sb1-* | mipsisa64sb1el-* \ | mipsisa64sr71k-* | mipsisa64sr71kel-* \ | mipstx39-* | mipstx39el-* \ | mmix-* \ | msp430-* \ | none-* | np1-* | ns16k-* | ns32k-* \ | orion-* \ | pdp10-* | pdp11-* | pj-* | pjl-* | pn-* | power-* \ | powerpc-* | powerpc64-* | powerpc64le-* | powerpcle-* | ppcbe-* \ | pyramid-* \ | romp-* | rs6000-* \ | sh-* | sh[1234]-* | sh[23]e-* | sh[34]eb-* | shbe-* \ | shle-* | sh[1234]le-* | sh3ele-* | sh64-* | sh64le-* \ | sparc-* | sparc64-* | sparc86x-* | sparclet-* | sparclite-* \ | sparcv8-* | sparcv9-* | sparcv9b-* | strongarm-* | sv1-* | sx?-* \ | tahoe-* | thumb-* \ | tic30-* | tic4x-* | tic54x-* | tic55x-* | tic6x-* | tic80-* \ | tron-* \ | v850-* | v850e-* | vax-* \ | we32k-* \ | x86-* | x86_64-* | xps100-* | xscale-* | xscalee[bl]-* \ | xstormy16-* | xtensa-* \ | ymp-* \ | z8k-*) ;; # Recognize the various machine names and aliases which stand # for a CPU type and a company and sometimes even an OS. 386bsd) basic_machine=i386-unknown os=-bsd ;; 3b1 | 7300 | 7300-att | att-7300 | pc7300 | safari | unixpc) basic_machine=m68000-att ;; 3b*) basic_machine=we32k-att ;; a29khif) basic_machine=a29k-amd os=-udi ;; abacus) basic_machine=abacus-unknown ;; adobe68k) basic_machine=m68010-adobe os=-scout ;; alliant | fx80) basic_machine=fx80-alliant ;; altos | altos3068) basic_machine=m68k-altos ;; am29k) basic_machine=a29k-none os=-bsd ;; amd64) basic_machine=x86_64-pc ;; amd64-*) basic_machine=x86_64-`echo $basic_machine | sed 's/^[^-]*-//'` ;; amdahl) basic_machine=580-amdahl os=-sysv ;; amiga | amiga-*) basic_machine=m68k-unknown ;; amigaos | amigados) basic_machine=m68k-unknown os=-amigaos ;; amigaunix | amix) basic_machine=m68k-unknown os=-sysv4 ;; apollo68) basic_machine=m68k-apollo os=-sysv ;; apollo68bsd) basic_machine=m68k-apollo os=-bsd ;; aux) basic_machine=m68k-apple os=-aux ;; balance) basic_machine=ns32k-sequent os=-dynix ;; c90) basic_machine=c90-cray os=-unicos ;; convex-c1) basic_machine=c1-convex os=-bsd ;; convex-c2) basic_machine=c2-convex os=-bsd ;; convex-c32) basic_machine=c32-convex os=-bsd ;; convex-c34) basic_machine=c34-convex os=-bsd ;; convex-c38) basic_machine=c38-convex os=-bsd ;; cray | j90) basic_machine=j90-cray os=-unicos ;; craynv) basic_machine=craynv-cray os=-unicosmp ;; cr16c) basic_machine=cr16c-unknown os=-elf ;; crds | unos) basic_machine=m68k-crds ;; crisv32 | crisv32-* | etraxfs*) basic_machine=crisv32-axis ;; cris | cris-* | etrax*) basic_machine=cris-axis ;; crx) basic_machine=crx-unknown os=-elf ;; da30 | da30-*) basic_machine=m68k-da30 ;; decstation | decstation-3100 | pmax | pmax-* | pmin | dec3100 | decstatn) basic_machine=mips-dec ;; decsystem10* | dec10*) basic_machine=pdp10-dec os=-tops10 ;; decsystem20* | dec20*) basic_machine=pdp10-dec os=-tops20 ;; delta | 3300 | motorola-3300 | motorola-delta \ | 3300-motorola | delta-motorola) basic_machine=m68k-motorola ;; delta88) basic_machine=m88k-motorola os=-sysv3 ;; djgpp) basic_machine=i586-pc os=-msdosdjgpp ;; dpx20 | dpx20-*) basic_machine=rs6000-bull os=-bosx ;; dpx2* | dpx2*-bull) basic_machine=m68k-bull os=-sysv3 ;; ebmon29k) basic_machine=a29k-amd os=-ebmon ;; elxsi) basic_machine=elxsi-elxsi os=-bsd ;; encore | umax | mmax) basic_machine=ns32k-encore ;; es1800 | OSE68k | ose68k | ose | OSE) basic_machine=m68k-ericsson os=-ose ;; fx2800) basic_machine=i860-alliant ;; genix) basic_machine=ns32k-ns ;; gmicro) basic_machine=tron-gmicro os=-sysv ;; go32) basic_machine=i386-pc os=-go32 ;; h3050r* | hiux*) basic_machine=hppa1.1-hitachi os=-hiuxwe2 ;; h8300hms) basic_machine=h8300-hitachi os=-hms ;; h8300xray) basic_machine=h8300-hitachi os=-xray ;; h8500hms) basic_machine=h8500-hitachi os=-hms ;; harris) basic_machine=m88k-harris os=-sysv3 ;; hp300-*) basic_machine=m68k-hp ;; hp300bsd) basic_machine=m68k-hp os=-bsd ;; hp300hpux) basic_machine=m68k-hp os=-hpux ;; hp3k9[0-9][0-9] | hp9[0-9][0-9]) basic_machine=hppa1.0-hp ;; hp9k2[0-9][0-9] | hp9k31[0-9]) basic_machine=m68000-hp ;; hp9k3[2-9][0-9]) basic_machine=m68k-hp ;; hp9k6[0-9][0-9] | hp6[0-9][0-9]) basic_machine=hppa1.0-hp ;; hp9k7[0-79][0-9] | hp7[0-79][0-9]) basic_machine=hppa1.1-hp ;; hp9k78[0-9] | hp78[0-9]) # FIXME: really hppa2.0-hp basic_machine=hppa1.1-hp ;; hp9k8[67]1 | hp8[67]1 | hp9k80[24] | hp80[24] | hp9k8[78]9 | hp8[78]9 | hp9k893 | hp893) # FIXME: really hppa2.0-hp basic_machine=hppa1.1-hp ;; hp9k8[0-9][13679] | hp8[0-9][13679]) basic_machine=hppa1.1-hp ;; hp9k8[0-9][0-9] | hp8[0-9][0-9]) basic_machine=hppa1.0-hp ;; hppa-next) os=-nextstep3 ;; hppaosf) basic_machine=hppa1.1-hp os=-osf ;; hppro) basic_machine=hppa1.1-hp os=-proelf ;; i370-ibm* | ibm*) basic_machine=i370-ibm ;; # I'm not sure what "Sysv32" means. Should this be sysv3.2? i*86v32) basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` os=-sysv32 ;; i*86v4*) basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` os=-sysv4 ;; i*86v) basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` os=-sysv ;; i*86sol2) basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` os=-solaris2 ;; i386mach) basic_machine=i386-mach os=-mach ;; i386-vsta | vsta) basic_machine=i386-unknown os=-vsta ;; iris | iris4d) basic_machine=mips-sgi case $os in -irix*) ;; *) os=-irix4 ;; esac ;; isi68 | isi) basic_machine=m68k-isi os=-sysv ;; m88k-omron*) basic_machine=m88k-omron ;; magnum | m3230) basic_machine=mips-mips os=-sysv ;; merlin) basic_machine=ns32k-utek os=-sysv ;; mingw32) basic_machine=i386-pc os=-mingw32 ;; miniframe) basic_machine=m68000-convergent ;; *mint | -mint[0-9]* | *MiNT | *MiNT[0-9]*) basic_machine=m68k-atari os=-mint ;; mips3*-*) basic_machine=`echo $basic_machine | sed -e 's/mips3/mips64/'` ;; mips3*) basic_machine=`echo $basic_machine | sed -e 's/mips3/mips64/'`-unknown ;; monitor) basic_machine=m68k-rom68k os=-coff ;; morphos) basic_machine=powerpc-unknown os=-morphos ;; msdos) basic_machine=i386-pc os=-msdos ;; mvs) basic_machine=i370-ibm os=-mvs ;; ncr3000) basic_machine=i486-ncr os=-sysv4 ;; netbsd386) basic_machine=i386-unknown os=-netbsd ;; netwinder) basic_machine=armv4l-rebel os=-linux ;; news | news700 | news800 | news900) basic_machine=m68k-sony os=-newsos ;; news1000) basic_machine=m68030-sony os=-newsos ;; news-3600 | risc-news) basic_machine=mips-sony os=-newsos ;; necv70) basic_machine=v70-nec os=-sysv ;; next | m*-next ) basic_machine=m68k-next case $os in -nextstep* ) ;; -ns2*) os=-nextstep2 ;; *) os=-nextstep3 ;; esac ;; nh3000) basic_machine=m68k-harris os=-cxux ;; nh[45]000) basic_machine=m88k-harris os=-cxux ;; nindy960) basic_machine=i960-intel os=-nindy ;; mon960) basic_machine=i960-intel os=-mon960 ;; nonstopux) basic_machine=mips-compaq os=-nonstopux ;; np1) basic_machine=np1-gould ;; nsr-tandem) basic_machine=nsr-tandem ;; op50n-* | op60c-*) basic_machine=hppa1.1-oki os=-proelf ;; or32 | or32-*) basic_machine=or32-unknown os=-coff ;; os400) basic_machine=powerpc-ibm os=-os400 ;; OSE68000 | ose68000) basic_machine=m68000-ericsson os=-ose ;; os68k) basic_machine=m68k-none os=-os68k ;; pa-hitachi) basic_machine=hppa1.1-hitachi os=-hiuxwe2 ;; paragon) basic_machine=i860-intel os=-osf ;; pbd) basic_machine=sparc-tti ;; pbb) basic_machine=m68k-tti ;; pc532 | pc532-*) basic_machine=ns32k-pc532 ;; pentium | p5 | k5 | k6 | nexgen | viac3) basic_machine=i586-pc ;; pentiumpro | p6 | 6x86 | athlon | athlon_*) basic_machine=i686-pc ;; pentiumii | pentium2 | pentiumiii | pentium3) basic_machine=i686-pc ;; pentium4) basic_machine=i786-pc ;; pentium-* | p5-* | k5-* | k6-* | nexgen-* | viac3-*) basic_machine=i586-`echo $basic_machine | sed 's/^[^-]*-//'` ;; pentiumpro-* | p6-* | 6x86-* | athlon-*) basic_machine=i686-`echo $basic_machine | sed 's/^[^-]*-//'` ;; pentiumii-* | pentium2-* | pentiumiii-* | pentium3-*) basic_machine=i686-`echo $basic_machine | sed 's/^[^-]*-//'` ;; pentium4-*) basic_machine=i786-`echo $basic_machine | sed 's/^[^-]*-//'` ;; pn) basic_machine=pn-gould ;; power) basic_machine=power-ibm ;; ppc) basic_machine=powerpc-unknown ;; ppc-*) basic_machine=powerpc-`echo $basic_machine | sed 's/^[^-]*-//'` ;; ppcle | powerpclittle | ppc-le | powerpc-little) basic_machine=powerpcle-unknown ;; ppcle-* | powerpclittle-*) basic_machine=powerpcle-`echo $basic_machine | sed 's/^[^-]*-//'` ;; ppc64) basic_machine=powerpc64-unknown ;; ppc64-*) basic_machine=powerpc64-`echo $basic_machine | sed 's/^[^-]*-//'` ;; ppc64le | powerpc64little | ppc64-le | powerpc64-little) basic_machine=powerpc64le-unknown ;; ppc64le-* | powerpc64little-*) basic_machine=powerpc64le-`echo $basic_machine | sed 's/^[^-]*-//'` ;; ps2) basic_machine=i386-ibm ;; pw32) basic_machine=i586-unknown os=-pw32 ;; rom68k) basic_machine=m68k-rom68k os=-coff ;; rm[46]00) basic_machine=mips-siemens ;; rtpc | rtpc-*) basic_machine=romp-ibm ;; s390 | s390-*) basic_machine=s390-ibm ;; s390x | s390x-*) basic_machine=s390x-ibm ;; sa29200) basic_machine=a29k-amd os=-udi ;; sb1) basic_machine=mipsisa64sb1-unknown ;; sb1el) basic_machine=mipsisa64sb1el-unknown ;; sei) basic_machine=mips-sei os=-seiux ;; sequent) basic_machine=i386-sequent ;; sh) basic_machine=sh-hitachi os=-hms ;; sh64) basic_machine=sh64-unknown ;; sparclite-wrs | simso-wrs) basic_machine=sparclite-wrs os=-vxworks ;; sps7) basic_machine=m68k-bull os=-sysv2 ;; spur) basic_machine=spur-unknown ;; st2000) basic_machine=m68k-tandem ;; stratus) basic_machine=i860-stratus os=-sysv4 ;; sun2) basic_machine=m68000-sun ;; sun2os3) basic_machine=m68000-sun os=-sunos3 ;; sun2os4) basic_machine=m68000-sun os=-sunos4 ;; sun3os3) basic_machine=m68k-sun os=-sunos3 ;; sun3os4) basic_machine=m68k-sun os=-sunos4 ;; sun4os3) basic_machine=sparc-sun os=-sunos3 ;; sun4os4) basic_machine=sparc-sun os=-sunos4 ;; sun4sol2) basic_machine=sparc-sun os=-solaris2 ;; sun3 | sun3-*) basic_machine=m68k-sun ;; sun4) basic_machine=sparc-sun ;; sun386 | sun386i | roadrunner) basic_machine=i386-sun ;; sv1) basic_machine=sv1-cray os=-unicos ;; symmetry) basic_machine=i386-sequent os=-dynix ;; t3e) basic_machine=alphaev5-cray os=-unicos ;; t90) basic_machine=t90-cray os=-unicos ;; tic54x | c54x*) basic_machine=tic54x-unknown os=-coff ;; tic55x | c55x*) basic_machine=tic55x-unknown os=-coff ;; tic6x | c6x*) basic_machine=tic6x-unknown os=-coff ;; tx39) basic_machine=mipstx39-unknown ;; tx39el) basic_machine=mipstx39el-unknown ;; toad1) basic_machine=pdp10-xkl os=-tops20 ;; tower | tower-32) basic_machine=m68k-ncr ;; tpf) basic_machine=s390x-ibm os=-tpf ;; udi29k) basic_machine=a29k-amd os=-udi ;; ultra3) basic_machine=a29k-nyu os=-sym1 ;; v810 | necv810) basic_machine=v810-nec os=-none ;; vaxv) basic_machine=vax-dec os=-sysv ;; vms) basic_machine=vax-dec os=-vms ;; vpp*|vx|vx-*) basic_machine=f301-fujitsu ;; vxworks960) basic_machine=i960-wrs os=-vxworks ;; vxworks68) basic_machine=m68k-wrs os=-vxworks ;; vxworks29k) basic_machine=a29k-wrs os=-vxworks ;; w65*) basic_machine=w65-wdc os=-none ;; w89k-*) basic_machine=hppa1.1-winbond os=-proelf ;; xbox) basic_machine=i686-pc os=-mingw32 ;; xps | xps100) basic_machine=xps100-honeywell ;; ymp) basic_machine=ymp-cray os=-unicos ;; z8k-*-coff) basic_machine=z8k-unknown os=-sim ;; none) basic_machine=none-none os=-none ;; # Here we handle the default manufacturer of certain CPU types. It is in # some cases the only manufacturer, in others, it is the most popular. w89k) basic_machine=hppa1.1-winbond ;; op50n) basic_machine=hppa1.1-oki ;; op60c) basic_machine=hppa1.1-oki ;; romp) basic_machine=romp-ibm ;; mmix) basic_machine=mmix-knuth ;; rs6000) basic_machine=rs6000-ibm ;; vax) basic_machine=vax-dec ;; pdp10) # there are many clones, so DEC is not a safe bet basic_machine=pdp10-unknown ;; pdp11) basic_machine=pdp11-dec ;; we32k) basic_machine=we32k-att ;; sh3 | sh4 | sh[34]eb | sh[1234]le | sh[23]ele) basic_machine=sh-unknown ;; sh64) basic_machine=sh64-unknown ;; sparc | sparcv8 | sparcv9 | sparcv9b) basic_machine=sparc-sun ;; cydra) basic_machine=cydra-cydrome ;; orion) basic_machine=orion-highlevel ;; orion105) basic_machine=clipper-highlevel ;; mac | mpw | mac-mpw) basic_machine=m68k-apple ;; pmac | pmac-mpw) basic_machine=powerpc-apple ;; *-unknown) # Make sure to match an already-canonicalized machine name. ;; *) echo Invalid configuration \`$1\': machine \`$basic_machine\' not recognized 1>&2 exit 1 ;; esac # Here we canonicalize certain aliases for manufacturers. case $basic_machine in *-digital*) basic_machine=`echo $basic_machine | sed 's/digital.*/dec/'` ;; *-commodore*) basic_machine=`echo $basic_machine | sed 's/commodore.*/cbm/'` ;; *) ;; esac # Decode manufacturer-specific aliases for certain operating systems. if [ x"$os" != x"" ] then case $os in # First match some system type aliases # that might get confused with valid system types. # -solaris* is a basic system type, with this one exception. -solaris1 | -solaris1.*) os=`echo $os | sed -e 's|solaris1|sunos4|'` ;; -solaris) os=-solaris2 ;; -svr4*) os=-sysv4 ;; -unixware*) os=-sysv4.2uw ;; -gnu/linux*) os=`echo $os | sed -e 's|gnu/linux|linux-gnu|'` ;; # First accept the basic system types. # The portable systems comes first. # Each alternative MUST END IN A *, to match a version number. # -sysv* is not here because it comes later, after sysvr4. -gnu* | -bsd* | -mach* | -minix* | -genix* | -ultrix* | -irix* \ | -*vms* | -sco* | -esix* | -isc* | -aix* | -sunos | -sunos[34]*\ | -hpux* | -unos* | -osf* | -luna* | -dgux* | -solaris* | -sym* \ | -amigaos* | -amigados* | -msdos* | -newsos* | -unicos* | -aof* \ | -aos* \ | -nindy* | -vxsim* | -vxworks* | -ebmon* | -hms* | -mvs* \ | -clix* | -riscos* | -uniplus* | -iris* | -rtu* | -xenix* \ | -hiux* | -386bsd* | -knetbsd* | -mirbsd* | -netbsd* | -openbsd* \ | -ekkobsd* | -kfreebsd* | -freebsd* | -riscix* | -lynxos* \ | -bosx* | -nextstep* | -cxux* | -aout* | -elf* | -oabi* \ | -ptx* | -coff* | -ecoff* | -winnt* | -domain* | -vsta* \ | -udi* | -eabi* | -lites* | -ieee* | -go32* | -aux* \ | -chorusos* | -chorusrdb* \ | -cygwin* | -pe* | -psos* | -moss* | -proelf* | -rtems* \ | -mingw32* | -linux-gnu* | -linux-uclibc* | -uxpv* | -beos* | -mpeix* | -udk* \ | -interix* | -uwin* | -mks* | -rhapsody* | -darwin* | -opened* \ | -openstep* | -oskit* | -conix* | -pw32* | -nonstopux* \ | -storm-chaos* | -tops10* | -tenex* | -tops20* | -its* \ | -os2* | -vos* | -palmos* | -uclinux* | -nucleus* \ | -morphos* | -superux* | -rtmk* | -rtmk-nova* | -windiss* \ | -powermax* | -dnix* | -nx6 | -nx7 | -sei* | -dragonfly*) # Remember, each alternative MUST END IN *, to match a version number. ;; -qnx*) case $basic_machine in x86-* | i*86-*) ;; *) os=-nto$os ;; esac ;; -nto-qnx*) ;; -nto*) os=`echo $os | sed -e 's|nto|nto-qnx|'` ;; -sim | -es1800* | -hms* | -xray | -os68k* | -none* | -v88r* \ | -windows* | -osx | -abug | -netware* | -os9* | -beos* \ | -macos* | -mpw* | -magic* | -mmixware* | -mon960* | -lnews*) ;; -mac*) os=`echo $os | sed -e 's|mac|macos|'` ;; -linux-dietlibc) os=-linux-dietlibc ;; -linux*) os=`echo $os | sed -e 's|linux|linux-gnu|'` ;; -sunos5*) os=`echo $os | sed -e 's|sunos5|solaris2|'` ;; -sunos6*) os=`echo $os | sed -e 's|sunos6|solaris3|'` ;; -opened*) os=-openedition ;; -os400*) os=-os400 ;; -wince*) os=-wince ;; -osfrose*) os=-osfrose ;; -osf*) os=-osf ;; -utek*) os=-bsd ;; -dynix*) os=-bsd ;; -acis*) os=-aos ;; -atheos*) os=-atheos ;; -syllable*) os=-syllable ;; -386bsd) os=-bsd ;; -ctix* | -uts*) os=-sysv ;; -nova*) os=-rtmk-nova ;; -ns2 ) os=-nextstep2 ;; -nsk*) os=-nsk ;; # Preserve the version number of sinix5. -sinix5.*) os=`echo $os | sed -e 's|sinix|sysv|'` ;; -sinix*) os=-sysv4 ;; -tpf*) os=-tpf ;; -triton*) os=-sysv3 ;; -oss*) os=-sysv3 ;; -svr4) os=-sysv4 ;; -svr3) os=-sysv3 ;; -sysvr4) os=-sysv4 ;; # This must come after -sysvr4. -sysv*) ;; -ose*) os=-ose ;; -es1800*) os=-ose ;; -xenix) os=-xenix ;; -*mint | -mint[0-9]* | -*MiNT | -MiNT[0-9]*) os=-mint ;; -aros*) os=-aros ;; -kaos*) os=-kaos ;; -zvmoe) os=-zvmoe ;; -none) ;; *) # Get rid of the `-' at the beginning of $os. os=`echo $os | sed 's/[^-]*-//'` echo Invalid configuration \`$1\': system \`$os\' not recognized 1>&2 exit 1 ;; esac else # Here we handle the default operating systems that come with various machines. # The value should be what the vendor currently ships out the door with their # machine or put another way, the most popular os provided with the machine. # Note that if you're going to try to match "-MANUFACTURER" here (say, # "-sun"), then you have to tell the case statement up towards the top # that MANUFACTURER isn't an operating system. Otherwise, code above # will signal an error saying that MANUFACTURER isn't an operating # system, and we'll never get to this point. case $basic_machine in *-acorn) os=-riscix1.2 ;; arm*-rebel) os=-linux ;; arm*-semi) os=-aout ;; c4x-* | tic4x-*) os=-coff ;; # This must come before the *-dec entry. pdp10-*) os=-tops20 ;; pdp11-*) os=-none ;; *-dec | vax-*) os=-ultrix4.2 ;; m68*-apollo) os=-domain ;; i386-sun) os=-sunos4.0.2 ;; m68000-sun) os=-sunos3 # This also exists in the configure program, but was not the # default. # os=-sunos4 ;; m68*-cisco) os=-aout ;; mips*-cisco) os=-elf ;; mips*-*) os=-elf ;; or32-*) os=-coff ;; *-tti) # must be before sparc entry or we get the wrong os. os=-sysv3 ;; sparc-* | *-sun) os=-sunos4.1.1 ;; *-be) os=-beos ;; *-ibm) os=-aix ;; *-knuth) os=-mmixware ;; *-wec) os=-proelf ;; *-winbond) os=-proelf ;; *-oki) os=-proelf ;; *-hp) os=-hpux ;; *-hitachi) os=-hiux ;; i860-* | *-att | *-ncr | *-altos | *-motorola | *-convergent) os=-sysv ;; *-cbm) os=-amigaos ;; *-dg) os=-dgux ;; *-dolphin) os=-sysv3 ;; m68k-ccur) os=-rtu ;; m88k-omron*) os=-luna ;; *-next ) os=-nextstep ;; *-sequent) os=-ptx ;; *-crds) os=-unos ;; *-ns) os=-genix ;; i370-*) os=-mvs ;; *-next) os=-nextstep3 ;; *-gould) os=-sysv ;; *-highlevel) os=-bsd ;; *-encore) os=-bsd ;; *-sgi) os=-irix ;; *-siemens) os=-sysv4 ;; *-masscomp) os=-rtu ;; f30[01]-fujitsu | f700-fujitsu) os=-uxpv ;; *-rom68k) os=-coff ;; *-*bug) os=-coff ;; *-apple) os=-macos ;; *-atari*) os=-mint ;; *) os=-none ;; esac fi # Here we handle the case where we know the os, and the CPU type, but not the # manufacturer. We pick the logical manufacturer. vendor=unknown case $basic_machine in *-unknown) case $os in -riscix*) vendor=acorn ;; -sunos*) vendor=sun ;; -aix*) vendor=ibm ;; -beos*) vendor=be ;; -hpux*) vendor=hp ;; -mpeix*) vendor=hp ;; -hiux*) vendor=hitachi ;; -unos*) vendor=crds ;; -dgux*) vendor=dg ;; -luna*) vendor=omron ;; -genix*) vendor=ns ;; -mvs* | -opened*) vendor=ibm ;; -os400*) vendor=ibm ;; -ptx*) vendor=sequent ;; -tpf*) vendor=ibm ;; -vxsim* | -vxworks* | -windiss*) vendor=wrs ;; -aux*) vendor=apple ;; -hms*) vendor=hitachi ;; -mpw* | -macos*) vendor=apple ;; -*mint | -mint[0-9]* | -*MiNT | -MiNT[0-9]*) vendor=atari ;; -vos*) vendor=stratus ;; esac basic_machine=`echo $basic_machine | sed "s/unknown/$vendor/"` ;; esac echo $basic_machine$os exit 0 # Local variables: # eval: (add-hook 'write-file-hooks 'time-stamp) # time-stamp-start: "timestamp='" # time-stamp-format: "%:y-%02m-%02d" # time-stamp-end: "'" # End: rapache-1.2.8/libapreq2/configure0000755000175100017510000250617712706745114016274 0ustar ondrejondrej#! /bin/sh # Guess values for system-dependent variables and create Makefiles. # Generated by GNU Autoconf 2.59 for Apache HTTP Server Request Library 2.05-dev. # # Report bugs to . # # Copyright (C) 2003 Free Software Foundation, Inc. # This configure script is free software; the Free Software Foundation # gives unlimited permission to copy, distribute and modify it. ## --------------------- ## ## M4sh Initialization. ## ## --------------------- ## # 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+"$@"}'='"$@"' elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then set -o posix fi DUALCASE=1; export DUALCASE # for MKS sh # Support unset when possible. if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then as_unset=unset else as_unset=false fi # Work around bugs in pre-3.0 UWIN ksh. $as_unset ENV MAIL MAILPATH PS1='$ ' PS2='> ' PS4='+ ' # NLS nuisances. for as_var in \ LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \ LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \ LC_TELEPHONE LC_TIME do if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then eval $as_var=C; export $as_var else $as_unset $as_var fi done # Required to use basename. if expr a : '\(a\)' >/dev/null 2>&1; then as_expr=expr else as_expr=false fi if (basename /) >/dev/null 2>&1 && test "X`basename / 2>&1`" = "X/"; then as_basename=basename else as_basename=false fi # Name of the executable. as_me=`$as_basename "$0" || $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ X"$0" : 'X\(//\)$' \| \ X"$0" : 'X\(/\)$' \| \ . : '\(.\)' 2>/dev/null || echo X/"$0" | sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; } /^X\/\(\/\/\)$/{ s//\1/; q; } /^X\/\(\/\).*/{ s//\1/; q; } s/.*/./; q'` # PATH needs CR, and LINENO needs CR and PATH. # 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 # The user is always right. if test "${PATH_SEPARATOR+set}" != set; then echo "#! /bin/sh" >conf$$.sh echo "exit 0" >>conf$$.sh chmod +x conf$$.sh if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then PATH_SEPARATOR=';' else PATH_SEPARATOR=: fi rm -f conf$$.sh fi as_lineno_1=$LINENO as_lineno_2=$LINENO as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null` test "x$as_lineno_1" != "x$as_lineno_2" && test "x$as_lineno_3" = "x$as_lineno_2" || { # Find who we are. Look in the path if we contain no path at all # relative or not. 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 ;; 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 { echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2 { (exit 1); exit 1; }; } fi case $CONFIG_SHELL in '') as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for as_base in sh bash ksh sh5; do case $as_dir in /*) if ("$as_dir/$as_base" -c ' as_lineno_1=$LINENO as_lineno_2=$LINENO as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null` test "x$as_lineno_1" != "x$as_lineno_2" && test "x$as_lineno_3" = "x$as_lineno_2" ') 2>/dev/null; then $as_unset BASH_ENV || test "${BASH_ENV+set}" != set || { BASH_ENV=; export BASH_ENV; } $as_unset ENV || test "${ENV+set}" != set || { ENV=; export ENV; } CONFIG_SHELL=$as_dir/$as_base export CONFIG_SHELL exec "$CONFIG_SHELL" "$0" ${1+"$@"} fi;; esac done done ;; esac # 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 before each line; the second 'sed' does the real # work. The second script uses 'N' to pair each line-number line # with the numbered line, 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 # second 'sed' script. Blame Lee E. McMahon for sed's syntax. :-) sed '=' <$as_myself | sed ' N s,$,-, : loop s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3, t loop s,-$,, s,^['$as_cr_digits']*\n,, ' >$as_me.lineno && chmod +x $as_me.lineno || { echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2 { (exit 1); exit 1; }; } # 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 sensible to this). . ./$as_me.lineno # Exit status is that of the last command. exit } case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in *c*,-n*) ECHO_N= ECHO_C=' ' ECHO_T=' ' ;; *c*,* ) ECHO_N=-n ECHO_C= ECHO_T= ;; *) ECHO_N= ECHO_C='\c' ECHO_T= ;; esac if expr a : '\(a\)' >/dev/null 2>&1; then as_expr=expr else as_expr=false fi rm -f conf$$ conf$$.exe conf$$.file echo >conf$$.file if ln -s conf$$.file conf$$ 2>/dev/null; then # We could just check for DJGPP; but this test a) works b) is more generic # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04). if test -f conf$$.exe; then # Don't use ln at all; we don't have any links as_ln_s='cp -p' else as_ln_s='ln -s' fi elif ln conf$$.file conf$$ 2>/dev/null; then as_ln_s=ln else as_ln_s='cp -p' fi rm -f conf$$ conf$$.exe conf$$.file if mkdir -p . 2>/dev/null; then as_mkdir_p=: else test -d ./-p && rmdir ./-p as_mkdir_p=false fi as_executable_p="test -f" # 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'" # IFS # We need space, tab and new line, in precisely that order. as_nl=' ' IFS=" $as_nl" # CDPATH. $as_unset CDPATH # Check that we are running under the correct shell. SHELL=${CONFIG_SHELL-/bin/sh} 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 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 "X$1" = X--fallback-echo; then # used as fallback echo shift cat </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. 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` && 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 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. 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 # Name of the host. # hostname on some systems (SVR3.2, Linux) returns a bogus exit status, # so uname gets run too. ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q` exec 6>&1 # # Initializations. # ac_default_prefix=/usr/local ac_config_libobj_dir=. cross_compiling=no subdirs= MFLAGS= MAKEFLAGS= SHELL=${CONFIG_SHELL-/bin/sh} # Maximum number of lines to put in a shell here document. # This variable seems obsolete. It should probably be removed, and # only ac_max_sed_lines should be used. : ${ac_max_here_lines=38} # Identity of this package. PACKAGE_NAME='Apache HTTP Server Request Library' PACKAGE_TARNAME='libapreq2' PACKAGE_VERSION='2.05-dev' PACKAGE_STRING='Apache HTTP Server Request Library 2.05-dev' PACKAGE_BUGREPORT='apreq-dev@httpd.apache.org' # Factoring default headers for most tests. ac_includes_default="\ #include #if HAVE_SYS_TYPES_H # include #endif #if HAVE_SYS_STAT_H # include #endif #if STDC_HEADERS # include # include #else # if HAVE_STDLIB_H # include # endif #endif #if HAVE_STRING_H # if !STDC_HEADERS && HAVE_MEMORY_H # include # endif # include #endif #if HAVE_STRINGS_H # include #endif #if HAVE_INTTYPES_H # include #else # if HAVE_STDINT_H # include # endif #endif #if HAVE_UNISTD_H # include #endif" ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA PACKAGE VERSION ACLOCAL AUTOCONF AUTOMAKE AUTOHEADER MAKEINFO AMTAR install_sh STRIP ac_ct_STRIP INSTALL_STRIP_PROGRAM AWK SET_MAKE CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT DEPDIR am__include am__quote AMDEP_TRUE AMDEP_FALSE AMDEPBACKSLASH CCDEPMODE build build_cpu build_vendor build_os host host_cpu host_vendor host_os EGREP LN_S ECHO AR ac_ct_AR RANLIB ac_ct_RANLIB CPP CXX CXXFLAGS ac_ct_CXX CXXDEPMODE CXXCPP F77 FFLAGS ac_ct_F77 LIBTOOL MAINTAINER_MODE_TRUE MAINTAINER_MODE_FALSE MAINT ENABLE_PROFILE_TRUE ENABLE_PROFILE_FALSE BUILD_PERL_GLUE_TRUE BUILD_PERL_GLUE_FALSE HAVE_APACHE_TEST_TRUE HAVE_APACHE_TEST_FALSE BUILD_HTTPD_TRUE BUILD_HTTPD_FALSE BUILD_APR_TRUE BUILD_APR_FALSE BUILD_APU_TRUE BUILD_APU_FALSE HAVE_APACHE1_TRUE HAVE_APACHE1_FALSE APREQ_CONFIG APREQ_LIBNAME APREQ_LIBTOOL_VERSION APREQ_MAJOR_VERSION APREQ_DOTTED_VERSION APACHE2_APXS APACHE2_SRC APACHE2_INCLUDES APACHE2_HTTPD APACHE1_APXS APU_CONFIG APR_CONFIG APR_INCLUDES APR_LDFLAGS APR_LTFLAGS APR_LIBS APR_LA APU_LA PERL PERL_OPTS LIBOBJS LTLIBOBJS' ac_subst_files='' # Initialize some variables set by options. ac_init_help= ac_init_version=false # The variables have the same names as the options, with # dashes changed to underlines. cache_file=/dev/null exec_prefix=NONE no_create= no_recursion= prefix=NONE program_prefix=NONE program_suffix=NONE program_transform_name=s,x,x, silent= site= srcdir= verbose= x_includes=NONE x_libraries=NONE # Installation directory options. # These are left unexpanded so users can "make install exec_prefix=/foo" # and all the variables that are supposed to be based on exec_prefix # by default will actually change. # Use braces instead of parens because sh, perl, etc. also accept them. bindir='${exec_prefix}/bin' sbindir='${exec_prefix}/sbin' libexecdir='${exec_prefix}/libexec' datadir='${prefix}/share' sysconfdir='${prefix}/etc' sharedstatedir='${prefix}/com' localstatedir='${prefix}/var' libdir='${exec_prefix}/lib' includedir='${prefix}/include' oldincludedir='/usr/include' infodir='${prefix}/info' mandir='${prefix}/man' ac_prev= for ac_option do # If the previous option needs an argument, assign it. if test -n "$ac_prev"; then eval "$ac_prev=\$ac_option" ac_prev= continue fi ac_optarg=`expr "x$ac_option" : 'x[^=]*=\(.*\)'` # Accept the important Cygnus configure options, so we can diagnose typos. case $ac_option in -bindir | --bindir | --bindi | --bind | --bin | --bi) ac_prev=bindir ;; -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) bindir=$ac_optarg ;; -build | --build | --buil | --bui | --bu) ac_prev=build_alias ;; -build=* | --build=* | --buil=* | --bui=* | --bu=*) build_alias=$ac_optarg ;; -cache-file | --cache-file | --cache-fil | --cache-fi \ | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) ac_prev=cache_file ;; -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) cache_file=$ac_optarg ;; --config-cache | -C) cache_file=config.cache ;; -datadir | --datadir | --datadi | --datad | --data | --dat | --da) ac_prev=datadir ;; -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \ | --da=*) datadir=$ac_optarg ;; -disable-* | --disable-*) ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'` # Reject names that are not valid shell variable names. expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null && { echo "$as_me: error: invalid feature name: $ac_feature" >&2 { (exit 1); exit 1; }; } ac_feature=`echo $ac_feature | sed 's/-/_/g'` eval "enable_$ac_feature=no" ;; -enable-* | --enable-*) ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` # Reject names that are not valid shell variable names. expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null && { echo "$as_me: error: invalid feature name: $ac_feature" >&2 { (exit 1); exit 1; }; } ac_feature=`echo $ac_feature | sed 's/-/_/g'` case $ac_option in *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;; *) ac_optarg=yes ;; esac eval "enable_$ac_feature='$ac_optarg'" ;; -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ | --exec | --exe | --ex) ac_prev=exec_prefix ;; -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ | --exec=* | --exe=* | --ex=*) exec_prefix=$ac_optarg ;; -gas | --gas | --ga | --g) # Obsolete; use --with-gas. with_gas=yes ;; -help | --help | --hel | --he | -h) ac_init_help=long ;; -help=r* | --help=r* | --hel=r* | --he=r* | -hr*) ac_init_help=recursive ;; -help=s* | --help=s* | --hel=s* | --he=s* | -hs*) ac_init_help=short ;; -host | --host | --hos | --ho) ac_prev=host_alias ;; -host=* | --host=* | --hos=* | --ho=*) host_alias=$ac_optarg ;; -includedir | --includedir | --includedi | --included | --include \ | --includ | --inclu | --incl | --inc) ac_prev=includedir ;; -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ | --includ=* | --inclu=* | --incl=* | --inc=*) includedir=$ac_optarg ;; -infodir | --infodir | --infodi | --infod | --info | --inf) ac_prev=infodir ;; -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) infodir=$ac_optarg ;; -libdir | --libdir | --libdi | --libd) ac_prev=libdir ;; -libdir=* | --libdir=* | --libdi=* | --libd=*) libdir=$ac_optarg ;; -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ | --libexe | --libex | --libe) ac_prev=libexecdir ;; -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ | --libexe=* | --libex=* | --libe=*) libexecdir=$ac_optarg ;; -localstatedir | --localstatedir | --localstatedi | --localstated \ | --localstate | --localstat | --localsta | --localst \ | --locals | --local | --loca | --loc | --lo) ac_prev=localstatedir ;; -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ | --localstate=* | --localstat=* | --localsta=* | --localst=* \ | --locals=* | --local=* | --loca=* | --loc=* | --lo=*) localstatedir=$ac_optarg ;; -mandir | --mandir | --mandi | --mand | --man | --ma | --m) ac_prev=mandir ;; -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) mandir=$ac_optarg ;; -nfp | --nfp | --nf) # Obsolete; use --without-fp. with_fp=no ;; -no-create | --no-create | --no-creat | --no-crea | --no-cre \ | --no-cr | --no-c | -n) no_create=yes ;; -no-recursion | --no-recursion | --no-recursio | --no-recursi \ | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) no_recursion=yes ;; -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ | --oldin | --oldi | --old | --ol | --o) ac_prev=oldincludedir ;; -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) oldincludedir=$ac_optarg ;; -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) ac_prev=prefix ;; -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) prefix=$ac_optarg ;; -program-prefix | --program-prefix | --program-prefi | --program-pref \ | --program-pre | --program-pr | --program-p) ac_prev=program_prefix ;; -program-prefix=* | --program-prefix=* | --program-prefi=* \ | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) program_prefix=$ac_optarg ;; -program-suffix | --program-suffix | --program-suffi | --program-suff \ | --program-suf | --program-su | --program-s) ac_prev=program_suffix ;; -program-suffix=* | --program-suffix=* | --program-suffi=* \ | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) program_suffix=$ac_optarg ;; -program-transform-name | --program-transform-name \ | --program-transform-nam | --program-transform-na \ | --program-transform-n | --program-transform- \ | --program-transform | --program-transfor \ | --program-transfo | --program-transf \ | --program-trans | --program-tran \ | --progr-tra | --program-tr | --program-t) ac_prev=program_transform_name ;; -program-transform-name=* | --program-transform-name=* \ | --program-transform-nam=* | --program-transform-na=* \ | --program-transform-n=* | --program-transform-=* \ | --program-transform=* | --program-transfor=* \ | --program-transfo=* | --program-transf=* \ | --program-trans=* | --program-tran=* \ | --progr-tra=* | --program-tr=* | --program-t=*) program_transform_name=$ac_optarg ;; -q | -quiet | --quiet | --quie | --qui | --qu | --q \ | -silent | --silent | --silen | --sile | --sil) silent=yes ;; -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) ac_prev=sbindir ;; -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ | --sbi=* | --sb=*) sbindir=$ac_optarg ;; -sharedstatedir | --sharedstatedir | --sharedstatedi \ | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ | --sharedst | --shareds | --shared | --share | --shar \ | --sha | --sh) ac_prev=sharedstatedir ;; -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ | --sha=* | --sh=*) sharedstatedir=$ac_optarg ;; -site | --site | --sit) ac_prev=site ;; -site=* | --site=* | --sit=*) site=$ac_optarg ;; -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) ac_prev=srcdir ;; -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) srcdir=$ac_optarg ;; -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ | --syscon | --sysco | --sysc | --sys | --sy) ac_prev=sysconfdir ;; -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) sysconfdir=$ac_optarg ;; -target | --target | --targe | --targ | --tar | --ta | --t) ac_prev=target_alias ;; -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) target_alias=$ac_optarg ;; -v | -verbose | --verbose | --verbos | --verbo | --verb) verbose=yes ;; -version | --version | --versio | --versi | --vers | -V) ac_init_version=: ;; -with-* | --with-*) ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` # Reject names that are not valid shell variable names. expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null && { echo "$as_me: error: invalid package name: $ac_package" >&2 { (exit 1); exit 1; }; } ac_package=`echo $ac_package| sed 's/-/_/g'` case $ac_option in *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;; *) ac_optarg=yes ;; esac eval "with_$ac_package='$ac_optarg'" ;; -without-* | --without-*) ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'` # Reject names that are not valid shell variable names. expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null && { echo "$as_me: error: invalid package name: $ac_package" >&2 { (exit 1); exit 1; }; } ac_package=`echo $ac_package | sed 's/-/_/g'` eval "with_$ac_package=no" ;; --x) # Obsolete; use --with-x. with_x=yes ;; -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ | --x-incl | --x-inc | --x-in | --x-i) ac_prev=x_includes ;; -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) x_includes=$ac_optarg ;; -x-libraries | --x-libraries | --x-librarie | --x-librari \ | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) ac_prev=x_libraries ;; -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) x_libraries=$ac_optarg ;; -*) { echo "$as_me: error: unrecognized option: $ac_option Try \`$0 --help' for more information." >&2 { (exit 1); exit 1; }; } ;; *=*) ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='` # Reject names that are not valid shell variable names. expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null && { echo "$as_me: error: invalid variable name: $ac_envvar" >&2 { (exit 1); exit 1; }; } ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` eval "$ac_envvar='$ac_optarg'" export $ac_envvar ;; *) # FIXME: should be removed in autoconf 3.0. echo "$as_me: WARNING: you should use --build, --host, --target" >&2 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && echo "$as_me: WARNING: invalid host type: $ac_option" >&2 : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option} ;; esac done if test -n "$ac_prev"; then ac_option=--`echo $ac_prev | sed 's/_/-/g'` { echo "$as_me: error: missing argument to $ac_option" >&2 { (exit 1); exit 1; }; } fi # Be sure to have absolute paths. for ac_var in exec_prefix prefix do eval ac_val=$`echo $ac_var` case $ac_val in [\\/$]* | ?:[\\/]* | NONE | '' ) ;; *) { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2 { (exit 1); exit 1; }; };; esac done # Be sure to have absolute paths. for ac_var in bindir sbindir libexecdir datadir sysconfdir sharedstatedir \ localstatedir libdir includedir oldincludedir infodir mandir do eval ac_val=$`echo $ac_var` case $ac_val in [\\/$]* | ?:[\\/]* ) ;; *) { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2 { (exit 1); exit 1; }; };; esac done # There might be people who depend on the old broken behavior: `$host' # used to hold the argument of --host etc. # FIXME: To remove some day. build=$build_alias host=$host_alias target=$target_alias # FIXME: To remove some day. if test "x$host_alias" != x; then if test "x$build_alias" = x; then cross_compiling=maybe echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host. If a cross compiler is detected then cross compile mode will be used." >&2 elif test "x$build_alias" != "x$host_alias"; then cross_compiling=yes fi fi ac_tool_prefix= test -n "$host_alias" && ac_tool_prefix=$host_alias- test "$silent" = yes && exec 6>/dev/null # Find the source files, if location was not specified. if test -z "$srcdir"; then ac_srcdir_defaulted=yes # Try the directory containing this script, then its parent. ac_confdir=`(dirname "$0") 2>/dev/null || $as_expr X"$0" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$0" : 'X\(//\)[^/]' \| \ X"$0" : 'X\(//\)$' \| \ X"$0" : 'X\(/\)' \| \ . : '\(.\)' 2>/dev/null || echo X"$0" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; } /^X\(\/\/\)[^/].*/{ s//\1/; q; } /^X\(\/\/\)$/{ s//\1/; q; } /^X\(\/\).*/{ s//\1/; q; } s/.*/./; q'` srcdir=$ac_confdir if test ! -r $srcdir/$ac_unique_file; then srcdir=.. fi else ac_srcdir_defaulted=no fi if test ! -r $srcdir/$ac_unique_file; then if test "$ac_srcdir_defaulted" = yes; then { echo "$as_me: error: cannot find sources ($ac_unique_file) in $ac_confdir or .." >&2 { (exit 1); exit 1; }; } else { echo "$as_me: error: cannot find sources ($ac_unique_file) in $srcdir" >&2 { (exit 1); exit 1; }; } fi fi (cd $srcdir && test -r ./$ac_unique_file) 2>/dev/null || { echo "$as_me: error: sources are in $srcdir, but \`cd $srcdir' does not work" >&2 { (exit 1); exit 1; }; } srcdir=`echo "$srcdir" | sed 's%\([^\\/]\)[\\/]*$%\1%'` ac_env_build_alias_set=${build_alias+set} ac_env_build_alias_value=$build_alias ac_cv_env_build_alias_set=${build_alias+set} ac_cv_env_build_alias_value=$build_alias ac_env_host_alias_set=${host_alias+set} ac_env_host_alias_value=$host_alias ac_cv_env_host_alias_set=${host_alias+set} ac_cv_env_host_alias_value=$host_alias ac_env_target_alias_set=${target_alias+set} ac_env_target_alias_value=$target_alias ac_cv_env_target_alias_set=${target_alias+set} ac_cv_env_target_alias_value=$target_alias ac_env_CC_set=${CC+set} ac_env_CC_value=$CC ac_cv_env_CC_set=${CC+set} ac_cv_env_CC_value=$CC ac_env_CFLAGS_set=${CFLAGS+set} ac_env_CFLAGS_value=$CFLAGS ac_cv_env_CFLAGS_set=${CFLAGS+set} ac_cv_env_CFLAGS_value=$CFLAGS ac_env_LDFLAGS_set=${LDFLAGS+set} ac_env_LDFLAGS_value=$LDFLAGS ac_cv_env_LDFLAGS_set=${LDFLAGS+set} ac_cv_env_LDFLAGS_value=$LDFLAGS ac_env_CPPFLAGS_set=${CPPFLAGS+set} ac_env_CPPFLAGS_value=$CPPFLAGS ac_cv_env_CPPFLAGS_set=${CPPFLAGS+set} ac_cv_env_CPPFLAGS_value=$CPPFLAGS ac_env_CPP_set=${CPP+set} ac_env_CPP_value=$CPP ac_cv_env_CPP_set=${CPP+set} ac_cv_env_CPP_value=$CPP ac_env_CXX_set=${CXX+set} ac_env_CXX_value=$CXX ac_cv_env_CXX_set=${CXX+set} ac_cv_env_CXX_value=$CXX ac_env_CXXFLAGS_set=${CXXFLAGS+set} ac_env_CXXFLAGS_value=$CXXFLAGS ac_cv_env_CXXFLAGS_set=${CXXFLAGS+set} ac_cv_env_CXXFLAGS_value=$CXXFLAGS ac_env_CXXCPP_set=${CXXCPP+set} ac_env_CXXCPP_value=$CXXCPP ac_cv_env_CXXCPP_set=${CXXCPP+set} ac_cv_env_CXXCPP_value=$CXXCPP ac_env_F77_set=${F77+set} ac_env_F77_value=$F77 ac_cv_env_F77_set=${F77+set} ac_cv_env_F77_value=$F77 ac_env_FFLAGS_set=${FFLAGS+set} ac_env_FFLAGS_value=$FFLAGS ac_cv_env_FFLAGS_set=${FFLAGS+set} ac_cv_env_FFLAGS_value=$FFLAGS # # Report the --help message. # 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 Apache HTTP Server Request Library 2.05-dev to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... To assign environment variables (e.g., CC, CFLAGS...), specify them as VAR=VALUE. See below for descriptions of some of the useful variables. Defaults for the options are specified in brackets. Configuration: -h, --help display this help and exit --help=short display options specific to this package --help=recursive display the short help of all the included packages -V, --version display version information and exit -q, --quiet, --silent do not print \`checking...' messages --cache-file=FILE cache test results in FILE [disabled] -C, --config-cache alias for \`--cache-file=config.cache' -n, --no-create do not create output files --srcdir=DIR find the sources in DIR [configure dir or \`..'] _ACEOF cat <<_ACEOF Installation directories: --prefix=PREFIX install architecture-independent files in PREFIX [$ac_default_prefix] --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX [PREFIX] By default, \`make install' will install all the files in \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify an installation prefix other than \`$ac_default_prefix' using \`--prefix', for instance \`--prefix=\$HOME'. For better control, use the options below. Fine tuning of the installation directories: --bindir=DIR user executables [EPREFIX/bin] --sbindir=DIR system admin executables [EPREFIX/sbin] --libexecdir=DIR program executables [EPREFIX/libexec] --datadir=DIR read-only architecture-independent data [PREFIX/share] --sysconfdir=DIR read-only single-machine data [PREFIX/etc] --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] --localstatedir=DIR modifiable single-machine data [PREFIX/var] --libdir=DIR object code libraries [EPREFIX/lib] --includedir=DIR C header files [PREFIX/include] --oldincludedir=DIR C header files for non-gcc [/usr/include] --infodir=DIR info documentation [PREFIX/info] --mandir=DIR man documentation [PREFIX/man] _ACEOF cat <<\_ACEOF Program names: --program-prefix=PREFIX prepend PREFIX to installed program names --program-suffix=SUFFIX append SUFFIX to installed program names --program-transform-name=PROGRAM run sed PROGRAM on installed program names System types: --build=BUILD configure for building on BUILD [guessed] --host=HOST cross-compile to build programs to run on HOST [BUILD] _ACEOF fi if test -n "$ac_init_help"; then case $ac_init_help in short | recursive ) echo "Configuration of Apache HTTP Server Request Library 2.05-dev:";; esac cat <<\_ACEOF Optional Features: --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) --enable-FEATURE[=ARG] include FEATURE [ARG=yes] --disable-dependency-tracking Speeds up one-time builds --enable-dependency-tracking Do not reject slow dependency extractors --enable-shared[=PKGS] build shared libraries [default=yes] --enable-static[=PKGS] build static libraries [default=yes] --enable-fast-install[=PKGS] optimize for fast installation [default=yes] --disable-libtool-lock avoid locking (might break parallel builds) --enable-maintainer-mode enable make rules and dependencies not useful (and sometimes confusing) to the casual installer --enable-profile compile libapreq2 with "-pg -fprofile-arcs -ftest-coverage" for gcov/gprof --enable-perl-glue build perl modules Apache::Request and Apache::Cookie 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-tags[=TAGS] include additional configurations [automatic] --with-perl path to perl executable --with-apache2-apxs path to apache2's apxs --with-apache2-src path to httpd source --with-apache2-httpd path to httpd binary --with-apr-config path to apr-*-config script --with-apu-config path to apu-*-config script --with-apache1-apxs path to apache1's apxs --with-perl-opts extra MakeMaker options --with-expat specify expat location Some influential environment variables: CC C compiler command CFLAGS C compiler flags LDFLAGS linker flags, e.g. -L if you have libraries in a nonstandard directory CPPFLAGS C/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 Use these variables to override the choices made by `configure' or to help it to find libraries and programs with nonstandard names/locations. Report bugs to . _ACEOF fi if test "$ac_init_help" = "recursive"; then # If there are subdirs, report their specific --help. ac_popdir=`pwd` for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue test -d $ac_dir || continue ac_builddir=. if test "$ac_dir" != .; then ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'` # A "../" for each directory in $ac_dir_suffix. ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'` else ac_dir_suffix= ac_top_builddir= fi case $srcdir in .) # No --srcdir option. We are building in place. ac_srcdir=. if test -z "$ac_top_builddir"; then ac_top_srcdir=. else ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'` fi ;; [\\/]* | ?:[\\/]* ) # Absolute path. ac_srcdir=$srcdir$ac_dir_suffix; ac_top_srcdir=$srcdir ;; *) # Relative path. ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix ac_top_srcdir=$ac_top_builddir$srcdir ;; esac # Do not use `cd foo && pwd` to compute absolute paths, because # the directories may not exist. case `pwd` in .) ac_abs_builddir="$ac_dir";; *) case "$ac_dir" in .) ac_abs_builddir=`pwd`;; [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";; *) ac_abs_builddir=`pwd`/"$ac_dir";; esac;; esac case $ac_abs_builddir in .) ac_abs_top_builddir=${ac_top_builddir}.;; *) case ${ac_top_builddir}. in .) ac_abs_top_builddir=$ac_abs_builddir;; [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;; *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;; esac;; esac case $ac_abs_builddir in .) ac_abs_srcdir=$ac_srcdir;; *) case $ac_srcdir in .) ac_abs_srcdir=$ac_abs_builddir;; [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;; *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;; esac;; esac case $ac_abs_builddir in .) ac_abs_top_srcdir=$ac_top_srcdir;; *) case $ac_top_srcdir in .) ac_abs_top_srcdir=$ac_abs_builddir;; [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;; *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;; esac;; esac cd $ac_dir # Check for guested configure; otherwise get Cygnus style configure. if test -f $ac_srcdir/configure.gnu; then echo $SHELL $ac_srcdir/configure.gnu --help=recursive elif test -f $ac_srcdir/configure; then echo $SHELL $ac_srcdir/configure --help=recursive elif test -f $ac_srcdir/configure.ac || test -f $ac_srcdir/configure.in; then echo $ac_configure --help else echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2 fi cd "$ac_popdir" done fi test -n "$ac_init_help" && exit 0 if $ac_init_version; then cat <<\_ACEOF Apache HTTP Server Request Library configure 2.05-dev generated by GNU Autoconf 2.59 Copyright (C) 2003 Free Software Foundation, Inc. This configure script is free software; the Free Software Foundation gives unlimited permission to copy, distribute and modify it. _ACEOF exit 0 fi exec 5>config.log cat >&5 <<_ACEOF This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. It was created by Apache HTTP Server Request Library $as_me 2.05-dev, which was generated by GNU Autoconf 2.59. Invocation command line was $ $0 $@ _ACEOF { cat <<_ASUNAME ## --------- ## ## Platform. ## ## --------- ## hostname = `(hostname || uname -n) 2>/dev/null | sed 1q` uname -m = `(uname -m) 2>/dev/null || echo unknown` uname -r = `(uname -r) 2>/dev/null || echo unknown` uname -s = `(uname -s) 2>/dev/null || echo unknown` uname -v = `(uname -v) 2>/dev/null || echo unknown` /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown` /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown` /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown` /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown` /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown` hostinfo = `(hostinfo) 2>/dev/null || echo unknown` /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown` /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown` /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown` _ASUNAME as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. echo "PATH: $as_dir" done } >&5 cat >&5 <<_ACEOF ## ----------- ## ## Core tests. ## ## ----------- ## _ACEOF # Keep a trace of the command line. # Strip out --no-create and --no-recursion so they do not pile up. # Strip out --silent because we don't want to record it for future runs. # Also quote any args containing shell meta-characters. # Make two passes to allow for proper duplicate-argument suppression. ac_configure_args= ac_configure_args0= ac_configure_args1= ac_sep= ac_must_keep_next=false for ac_pass in 1 2 do for ac_arg do case $ac_arg in -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;; -q | -quiet | --quiet | --quie | --qui | --qu | --q \ | -silent | --silent | --silen | --sile | --sil) continue ;; *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*) ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; esac case $ac_pass in 1) ac_configure_args0="$ac_configure_args0 '$ac_arg'" ;; 2) ac_configure_args1="$ac_configure_args1 '$ac_arg'" if test $ac_must_keep_next = true; then ac_must_keep_next=false # Got value, back to normal. else case $ac_arg in *=* | --config-cache | -C | -disable-* | --disable-* \ | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \ | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \ | -with-* | --with-* | -without-* | --without-* | --x) case "$ac_configure_args0 " in "$ac_configure_args1"*" '$ac_arg' "* ) continue ;; esac ;; -* ) ac_must_keep_next=true ;; esac fi ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'" # Get rid of the leading space. ac_sep=" " ;; esac done done $as_unset ac_configure_args0 || test "${ac_configure_args0+set}" != set || { ac_configure_args0=; export ac_configure_args0; } $as_unset ac_configure_args1 || test "${ac_configure_args1+set}" != set || { ac_configure_args1=; export ac_configure_args1; } # When interrupted or exit'd, cleanup temporary files, and complete # config.log. We remove comments because anyway the quotes in there # would cause problems or look ugly. # WARNING: Be sure not to use single quotes in there, as some shells, # such as our DU 5.0 friend, will then `close' the trap. trap 'exit_status=$? # Save into config.log some information that might help in debugging. { echo cat <<\_ASBOX ## ---------------- ## ## Cache variables. ## ## ---------------- ## _ASBOX echo # The following way of writing the cache mishandles newlines in values, { (set) 2>&1 | case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in *ac_space=\ *) sed -n \ "s/'"'"'/'"'"'\\\\'"'"''"'"'/g; s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p" ;; *) sed -n \ "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p" ;; esac; } echo cat <<\_ASBOX ## ----------------- ## ## Output variables. ## ## ----------------- ## _ASBOX echo for ac_var in $ac_subst_vars do eval ac_val=$`echo $ac_var` echo "$ac_var='"'"'$ac_val'"'"'" done | sort echo if test -n "$ac_subst_files"; then cat <<\_ASBOX ## ------------- ## ## Output files. ## ## ------------- ## _ASBOX echo for ac_var in $ac_subst_files do eval ac_val=$`echo $ac_var` echo "$ac_var='"'"'$ac_val'"'"'" done | sort echo fi if test -s confdefs.h; then cat <<\_ASBOX ## ----------- ## ## confdefs.h. ## ## ----------- ## _ASBOX echo sed "/^$/d" confdefs.h | sort echo fi test "$ac_signal" != 0 && echo "$as_me: caught signal $ac_signal" echo "$as_me: exit $exit_status" } >&5 rm -f core *.core && rm -rf conftest* confdefs* conf$$* $ac_clean_files && exit $exit_status ' 0 for ac_signal in 1 2 13 15; do trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal done ac_signal=0 # confdefs.h avoids OS command line length limits that DEFS can exceed. rm -rf conftest* confdefs.h # AIX cpp loses on an empty file, so make sure it contains at least a newline. echo >confdefs.h # Predefined preprocessor variables. cat >>confdefs.h <<_ACEOF #define PACKAGE_NAME "$PACKAGE_NAME" _ACEOF cat >>confdefs.h <<_ACEOF #define PACKAGE_TARNAME "$PACKAGE_TARNAME" _ACEOF cat >>confdefs.h <<_ACEOF #define PACKAGE_VERSION "$PACKAGE_VERSION" _ACEOF cat >>confdefs.h <<_ACEOF #define PACKAGE_STRING "$PACKAGE_STRING" _ACEOF cat >>confdefs.h <<_ACEOF #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT" _ACEOF # Let the site file select an alternate cache file if it wants to. # Prefer explicitly selected file to automatically selected ones. if test -z "$CONFIG_SITE"; then if test "x$prefix" != xNONE; then CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site" else CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site" fi fi for ac_site_file in $CONFIG_SITE; do if test -r "$ac_site_file"; then { echo "$as_me:$LINENO: loading site script $ac_site_file" >&5 echo "$as_me: loading site script $ac_site_file" >&6;} sed 's/^/| /' "$ac_site_file" >&5 . "$ac_site_file" fi done if test -r "$cache_file"; then # Some versions of bash will fail to source /dev/null (special # files actually), so we avoid doing that. if test -f "$cache_file"; then { echo "$as_me:$LINENO: loading cache $cache_file" >&5 echo "$as_me: loading cache $cache_file" >&6;} case $cache_file in [\\/]* | ?:[\\/]* ) . $cache_file;; *) . ./$cache_file;; esac fi else { echo "$as_me:$LINENO: creating cache $cache_file" >&5 echo "$as_me: creating cache $cache_file" >&6;} >$cache_file fi # Check that the precious variables saved in the cache have kept the same # value. ac_cache_corrupted=false for ac_var in `(set) 2>&1 | sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do eval ac_old_set=\$ac_cv_env_${ac_var}_set eval ac_new_set=\$ac_env_${ac_var}_set eval ac_old_val="\$ac_cv_env_${ac_var}_value" eval ac_new_val="\$ac_env_${ac_var}_value" case $ac_old_set,$ac_new_set in set,) { echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;} ac_cache_corrupted=: ;; ,set) { echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5 echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;} ac_cache_corrupted=: ;; ,);; *) if test "x$ac_old_val" != "x$ac_new_val"; then { echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5 echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} { echo "$as_me:$LINENO: former value: $ac_old_val" >&5 echo "$as_me: former value: $ac_old_val" >&2;} { echo "$as_me:$LINENO: current value: $ac_new_val" >&5 echo "$as_me: current value: $ac_new_val" >&2;} ac_cache_corrupted=: fi;; esac # Pass precious variables to config.status. if test "$ac_new_set" = set; then case $ac_new_val in *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*) ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;; *) ac_arg=$ac_var=$ac_new_val ;; esac case " $ac_configure_args " in *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy. *) ac_configure_args="$ac_configure_args '$ac_arg'" ;; esac fi done if $ac_cache_corrupted; then { echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5 echo "$as_me: error: changes in the environment can compromise the build" >&2;} { { echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5 echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;} { (exit 1); exit 1; }; } fi ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu rm -f config.nice cat >config.nice<> config.nice fi if test -n "$CFLAGS"; then echo "CFLAGS=\"$CFLAGS\"; export CFLAGS" >> config.nice fi if test -n "$CPPFLAGS"; then echo "CPPFLAGS=\"$CPPFLAGS\"; export CPPFLAGS" >> config.nice fi if test -n "$LDFLAGS"; then echo "LDFLAGS=\"$LDFLAGS\"; export LDFLAGS" >> config.nice fi if test -n "$LTFLAGS"; then echo "LTFLAGS=\"$LTFLAGS\"; export LTFLAGS" >> config.nice fi if test -n "$LIBS"; then echo "LIBS=\"$LIBS\"; export LIBS" >> config.nice fi if test -n "$INCLUDES"; then echo "INCLUDES=\"$INCLUDES\"; export INCLUDES" >> config.nice fi if test -n "$NOTEST_CFLAGS"; then echo "NOTEST_CFLAGS=\"$NOTEST_CFLAGS\"; export NOTEST_CFLAGS" >> config.nice fi if test -n "$NOTEST_CPPFLAGS"; then echo "NOTEST_CPPFLAGS=\"$NOTEST_CPPFLAGS\"; export NOTEST_CPPFLAGS" >> config.nice fi if test -n "$NOTEST_LDFLAGS"; then echo "NOTEST_LDFLAGS=\"$NOTEST_LDFLAGS\"; export NOTEST_LDFLAGS" >> config.nice fi if test -n "$NOTEST_LIBS"; then echo "NOTEST_LIBS=\"$NOTEST_LIBS\"; export NOTEST_LIBS" >> config.nice fi echo $0 $ac_configure_args '"$@"' >> config.nice chmod +x config.nice am__api_version="1.6" ac_aux_dir= for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do if test -f $ac_dir/install-sh; then ac_aux_dir=$ac_dir ac_install_sh="$ac_aux_dir/install-sh -c" break elif test -f $ac_dir/install.sh; then ac_aux_dir=$ac_dir ac_install_sh="$ac_aux_dir/install.sh -c" break elif test -f $ac_dir/shtool; then ac_aux_dir=$ac_dir ac_install_sh="$ac_aux_dir/shtool install -c" break fi done if test -z "$ac_aux_dir"; then { { echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&5 echo "$as_me: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&2;} { (exit 1); exit 1; }; } fi ac_config_guess="$SHELL $ac_aux_dir/config.guess" ac_config_sub="$SHELL $ac_aux_dir/config.sub" ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure. # Find a good install program. We prefer a C program (faster), # so one script is as good as another. But avoid the broken or # incompatible versions: # SysV /etc/install, /usr/sbin/install # SunOS /usr/etc/install # IRIX /sbin/install # AIX /bin/install # AmigaOS /C/install, which installs bootblocks on floppy discs # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag # AFS /usr/afsws/bin/install, which mishandles nonexistent args # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" # OS/2's system install, which has a completely different semantic # ./install, which can be erroneously created by make from ./install.sh. echo "$as_me:$LINENO: checking for a BSD-compatible install" >&5 echo $ECHO_N "checking for a BSD-compatible install... $ECHO_C" >&6 if test -z "$INSTALL"; then if test "${ac_cv_path_install+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. # Account for people who put trailing slashes in PATH elements. case $as_dir/ in ./ | .// | /cC/* | \ /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \ ?:\\/os2\\/install\\/* | ?:\\/OS2\\/INSTALL\\/* | \ /usr/ucb/* ) ;; *) # OSF1 and SCO ODT 3.0 have their own names for install. # Don't use installbsd from OSF since it installs stuff as root # by default. for ac_prog in ginstall scoinst install; do for ac_exec_ext in '' $ac_executable_extensions; do if $as_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then if test $ac_prog = install && grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then # AIX install. It has an incompatible calling convention. : elif test $ac_prog = install && grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then # program-specific install script used by HP pwplus--don't use. : else ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c" break 3 fi fi done done ;; esac done fi if test "${ac_cv_path_install+set}" = set; then INSTALL=$ac_cv_path_install else # As a last resort, use the slow shell script. We don't cache a # path for INSTALL within a source directory, because that will # break other packages using the cache if that directory is # removed, or if the path is relative. INSTALL=$ac_install_sh fi fi echo "$as_me:$LINENO: result: $INSTALL" >&5 echo "${ECHO_T}$INSTALL" >&6 # Use test -z because SunOS4 sh mishandles braces in ${var-val}. # It thinks the first close brace ends the variable substitution. test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}' test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' echo "$as_me:$LINENO: checking whether build environment is sane" >&5 echo $ECHO_N "checking whether build environment is sane... $ECHO_C" >&6 # Just in case sleep 1 echo timestamp > conftest.file # 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 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". { { echo "$as_me:$LINENO: error: ls -t appears to fail. Make sure there is not a broken alias in your environment" >&5 echo "$as_me: error: ls -t appears to fail. Make sure there is not a broken alias in your environment" >&2;} { (exit 1); exit 1; }; } fi test "$2" = conftest.file ) then # Ok. : else { { echo "$as_me:$LINENO: error: newly created file is older than distributed files! Check your system clock" >&5 echo "$as_me: error: newly created file is older than distributed files! Check your system clock" >&2;} { (exit 1); exit 1; }; } fi echo "$as_me:$LINENO: result: yes" >&5 echo "${ECHO_T}yes" >&6 test "$program_prefix" != NONE && program_transform_name="s,^,$program_prefix,;$program_transform_name" # Use a double $ so make ignores it. test "$program_suffix" != NONE && program_transform_name="s,\$,$program_suffix,;$program_transform_name" # Double any \ or $. echo might interpret backslashes. # By default was `s,x,x', remove it if useless. cat <<\_ACEOF >conftest.sed s/[\\$]/&&/g;s/;s,x,x,$// _ACEOF program_transform_name=`echo $program_transform_name | sed -f conftest.sed` rm conftest.sed # expand $ac_aux_dir to an absolute path am_aux_dir=`cd $ac_aux_dir && pwd` test x"${MISSING+set}" = xset || MISSING="\${SHELL} $am_aux_dir/missing" # Use eval to expand $SHELL if eval "$MISSING --run true"; then am_missing_run="$MISSING --run " else am_missing_run= { echo "$as_me:$LINENO: WARNING: \`missing' script is too old or missing" >&5 echo "$as_me: WARNING: \`missing' script is too old or missing" >&2;} fi for ac_prog in gawk mawk nawk awk do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 if test "${ac_cv_prog_AWK+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$AWK"; then ac_cv_prog_AWK="$AWK" # 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 $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_AWK="$ac_prog" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done fi fi AWK=$ac_cv_prog_AWK if test -n "$AWK"; then echo "$as_me:$LINENO: result: $AWK" >&5 echo "${ECHO_T}$AWK" >&6 else echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6 fi test -n "$AWK" && break done echo "$as_me:$LINENO: checking whether ${MAKE-make} sets \$(MAKE)" >&5 echo $ECHO_N "checking whether ${MAKE-make} sets \$(MAKE)... $ECHO_C" >&6 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y,:./+-,___p_,'` if eval "test \"\${ac_cv_prog_make_${ac_make}_set+set}\" = set"; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.make <<\_ACEOF all: @echo 'ac_maketemp="$(MAKE)"' _ACEOF # GNU make sometimes prints "make[1]: Entering...", which would confuse us. eval `${MAKE-make} -f conftest.make 2>/dev/null | grep temp=` if test -n "$ac_maketemp"; then eval ac_cv_prog_make_${ac_make}_set=yes else eval ac_cv_prog_make_${ac_make}_set=no fi rm -f conftest.make fi if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then echo "$as_me:$LINENO: result: yes" >&5 echo "${ECHO_T}yes" >&6 SET_MAKE= else echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6 SET_MAKE="MAKE=${MAKE-make}" fi # test to see if srcdir already configured if test "`cd $srcdir && pwd`" != "`pwd`" && test -f $srcdir/config.status; then { { echo "$as_me:$LINENO: error: source directory already configured; run \"make distclean\" there first" >&5 echo "$as_me: error: source directory already configured; run \"make distclean\" there first" >&2;} { (exit 1); exit 1; }; } fi # Define the identity of the package. PACKAGE=libapreq2 VERSION=2.05-dev cat >>confdefs.h <<_ACEOF #define PACKAGE "$PACKAGE" _ACEOF cat >>confdefs.h <<_ACEOF #define VERSION "$VERSION" _ACEOF # Some tools Automake needs. ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"} AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"} AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"} AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"} MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"} AMTAR=${AMTAR-"${am_missing_run}tar"} install_sh=${install_sh-"$am_aux_dir/install-sh"} # 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. if test "$cross_compiling" != no; then 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 echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 if test "${ac_cv_prog_STRIP+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else 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 do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_STRIP="${ac_tool_prefix}strip" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done fi fi STRIP=$ac_cv_prog_STRIP if test -n "$STRIP"; then echo "$as_me:$LINENO: result: $STRIP" >&5 echo "${ECHO_T}$STRIP" >&6 else echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6 fi 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 echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else 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 do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_STRIP="strip" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done test -z "$ac_cv_prog_ac_ct_STRIP" && ac_cv_prog_ac_ct_STRIP=":" fi fi ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP if test -n "$ac_ct_STRIP"; then echo "$as_me:$LINENO: result: $ac_ct_STRIP" >&5 echo "${ECHO_T}$ac_ct_STRIP" >&6 else echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6 fi STRIP=$ac_ct_STRIP else STRIP="$ac_cv_prog_STRIP" fi fi INSTALL_STRIP_PROGRAM="\${SHELL} \$(install_sh) -c -s" # We need awk for the "check" target. The system "awk" is bad on # some platforms. echo "$as_me:$LINENO: checking whether ${MAKE-make} sets \$(MAKE)" >&5 echo $ECHO_N "checking whether ${MAKE-make} sets \$(MAKE)... $ECHO_C" >&6 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y,:./+-,___p_,'` if eval "test \"\${ac_cv_prog_make_${ac_make}_set+set}\" = set"; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.make <<\_ACEOF all: @echo 'ac_maketemp="$(MAKE)"' _ACEOF # GNU make sometimes prints "make[1]: Entering...", which would confuse us. eval `${MAKE-make} -f conftest.make 2>/dev/null | grep temp=` if test -n "$ac_maketemp"; then eval ac_cv_prog_make_${ac_make}_set=yes else eval ac_cv_prog_make_${ac_make}_set=no fi rm -f conftest.make fi if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then echo "$as_me:$LINENO: result: yes" >&5 echo "${ECHO_T}yes" >&6 SET_MAKE= else echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6 SET_MAKE="MAKE=${MAKE-make}" 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 -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 echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 if test "${ac_cv_prog_CC+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&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 $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_CC="${ac_tool_prefix}gcc" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done fi fi CC=$ac_cv_prog_CC if test -n "$CC"; then echo "$as_me:$LINENO: result: $CC" >&5 echo "${ECHO_T}$CC" >&6 else echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6 fi 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 echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&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 $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_CC="gcc" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done fi fi ac_ct_CC=$ac_cv_prog_ac_ct_CC if test -n "$ac_ct_CC"; then echo "$as_me:$LINENO: result: $ac_ct_CC" >&5 echo "${ECHO_T}$ac_ct_CC" >&6 else echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6 fi CC=$ac_ct_CC else CC="$ac_cv_prog_CC" fi 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 echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 if test "${ac_cv_prog_CC+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&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 $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_CC="${ac_tool_prefix}cc" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done fi fi CC=$ac_cv_prog_CC if test -n "$CC"; then echo "$as_me:$LINENO: result: $CC" >&5 echo "${ECHO_T}$CC" >&6 else echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6 fi fi if test -z "$ac_cv_prog_CC"; then ac_ct_CC=$CC # Extract the first word of "cc", so it can be a program name with args. set dummy cc; ac_word=$2 echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&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 $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_CC="cc" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done fi fi ac_ct_CC=$ac_cv_prog_ac_ct_CC if test -n "$ac_ct_CC"; then echo "$as_me:$LINENO: result: $ac_ct_CC" >&5 echo "${ECHO_T}$ac_ct_CC" >&6 else echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6 fi CC=$ac_ct_CC else CC="$ac_cv_prog_CC" 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 echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 if test "${ac_cv_prog_CC+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&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 $as_executable_p "$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" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done 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 echo "$as_me:$LINENO: result: $CC" >&5 echo "${ECHO_T}$CC" >&6 else echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6 fi fi if test -z "$CC"; then if test -n "$ac_tool_prefix"; then for ac_prog in cl 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 echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 if test "${ac_cv_prog_CC+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&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 $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_CC="$ac_tool_prefix$ac_prog" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done fi fi CC=$ac_cv_prog_CC if test -n "$CC"; then echo "$as_me:$LINENO: result: $CC" >&5 echo "${ECHO_T}$CC" >&6 else echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6 fi test -n "$CC" && break done fi if test -z "$CC"; then ac_ct_CC=$CC for ac_prog in cl do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&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 $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_CC="$ac_prog" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done fi fi ac_ct_CC=$ac_cv_prog_ac_ct_CC if test -n "$ac_ct_CC"; then echo "$as_me:$LINENO: result: $ac_ct_CC" >&5 echo "${ECHO_T}$ac_ct_CC" >&6 else echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6 fi test -n "$ac_ct_CC" && break done CC=$ac_ct_CC fi fi test -z "$CC" && { { echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH See \`config.log' for more details." >&5 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. echo "$as_me:$LINENO:" \ "checking for C compiler version" >&5 ac_compiler=`set X $ac_compile; echo $2` { (eval echo "$as_me:$LINENO: \"$ac_compiler --version &5\"") >&5 (eval $ac_compiler --version &5) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } { (eval echo "$as_me:$LINENO: \"$ac_compiler -v &5\"") >&5 (eval $ac_compiler -v &5) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } { (eval echo "$as_me:$LINENO: \"$ac_compiler -V &5\"") >&5 (eval $ac_compiler -V &5) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } 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 ac_clean_files_save=$ac_clean_files ac_clean_files="$ac_clean_files a.out a.exe b.out" # Try to create an executable without -o first, disregard a.out. # It will help us diagnose broken compilers, and finding out an intuition # of exeext. echo "$as_me:$LINENO: checking for C compiler default output file name" >&5 echo $ECHO_N "checking for C compiler default output file name... $ECHO_C" >&6 ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'` if { (eval echo "$as_me:$LINENO: \"$ac_link_default\"") >&5 (eval $ac_link_default) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; then # Find the output, starting from the most likely. This scheme is # not robust to junk in `.', hence go to wildcards (a.*) only as a last # resort. # Be careful to initialize this variable, since it used to be cached. # Otherwise an old cache value of `no' led to `EXEEXT = no' in a Makefile. ac_cv_exeext= # b.out is created by i960 compilers. for ac_file in a_out.exe a.exe conftest.exe a.out conftest a.* conftest.* b.out do test -f "$ac_file" || continue case $ac_file in *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.o | *.obj ) ;; conftest.$ac_ext ) # This is the source file. ;; [ab].out ) # We found the default executable, but exeext='' is most # certainly right. break;; *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` # FIXME: I believe we export ac_cv_exeext for Libtool, # but it would be cool to find out if it's true. Does anybody # maintain Libtool? --akim. export ac_cv_exeext break;; * ) break;; esac done else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 { { echo "$as_me:$LINENO: error: C compiler cannot create executables See \`config.log' for more details." >&5 echo "$as_me: error: C compiler cannot create executables See \`config.log' for more details." >&2;} { (exit 77); exit 77; }; } fi ac_exeext=$ac_cv_exeext echo "$as_me:$LINENO: result: $ac_file" >&5 echo "${ECHO_T}$ac_file" >&6 # Check the compiler produces executables we can run. If not, either # the compiler is broken, or we cross compile. echo "$as_me:$LINENO: checking whether the C compiler works" >&5 echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6 # FIXME: These cross compiler hacks should be removed for Autoconf 3.0 # If not cross compiling, check that we can run a simple program. if test "$cross_compiling" != yes; then if { ac_try='./$ac_file' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then cross_compiling=no else if test "$cross_compiling" = maybe; then cross_compiling=yes else { { echo "$as_me:$LINENO: error: cannot run C compiled programs. If you meant to cross compile, use \`--host'. See \`config.log' for more details." >&5 echo "$as_me: error: cannot run C compiled programs. If you meant to cross compile, use \`--host'. See \`config.log' for more details." >&2;} { (exit 1); exit 1; }; } fi fi fi echo "$as_me:$LINENO: result: yes" >&5 echo "${ECHO_T}yes" >&6 rm -f a.out a.exe conftest$ac_cv_exeext b.out ac_clean_files=$ac_clean_files_save # Check the compiler produces executables we can run. If not, either # the compiler is broken, or we cross compile. echo "$as_me:$LINENO: checking whether we are cross compiling" >&5 echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6 echo "$as_me:$LINENO: result: $cross_compiling" >&5 echo "${ECHO_T}$cross_compiling" >&6 echo "$as_me:$LINENO: checking for suffix of executables" >&5 echo $ECHO_N "checking for suffix of executables... $ECHO_C" >&6 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; then # If both `conftest.exe' and `conftest' are `present' (well, observable) # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will # work properly (i.e., refer to `conftest.exe'), while it won't with # `rm'. for ac_file in conftest.exe conftest conftest.*; do test -f "$ac_file" || continue case $ac_file in *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.o | *.obj ) ;; *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` export ac_cv_exeext break;; * ) break;; esac done else { { echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link See \`config.log' for more details." >&5 echo "$as_me: error: cannot compute suffix of executables: cannot compile and link See \`config.log' for more details." >&2;} { (exit 1); exit 1; }; } fi rm -f conftest$ac_cv_exeext echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5 echo "${ECHO_T}$ac_cv_exeext" >&6 rm -f conftest.$ac_ext EXEEXT=$ac_cv_exeext ac_exeext=$EXEEXT echo "$as_me:$LINENO: checking for suffix of object files" >&5 echo $ECHO_N "checking for suffix of object files... $ECHO_C" >&6 if test "${ac_cv_objext+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else 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.o conftest.obj if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; then for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do case $ac_file in *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg ) ;; *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` break;; esac done else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 { { echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile See \`config.log' for more details." >&5 echo "$as_me: error: cannot compute suffix of object files: cannot compile See \`config.log' for more details." >&2;} { (exit 1); exit 1; }; } fi rm -f conftest.$ac_cv_objext conftest.$ac_ext fi echo "$as_me:$LINENO: result: $ac_cv_objext" >&5 echo "${ECHO_T}$ac_cv_objext" >&6 OBJEXT=$ac_cv_objext ac_objext=$OBJEXT echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5 echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6 if test "${ac_cv_c_compiler_gnu+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ int main () { #ifndef __GNUC__ choke me #endif ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 (eval $ac_compile) 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; } && { ac_try='test -s conftest.$ac_objext' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_compiler_gnu=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_compiler_gnu=no fi rm -f conftest.err conftest.$ac_objext conftest.$ac_ext ac_cv_c_compiler_gnu=$ac_compiler_gnu fi echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5 echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6 GCC=`test $ac_compiler_gnu = yes && echo yes` ac_test_CFLAGS=${CFLAGS+set} ac_save_CFLAGS=$CFLAGS CFLAGS="-g" echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5 echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6 if test "${ac_cv_prog_cc_g+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else 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 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 (eval $ac_compile) 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; } && { ac_try='test -s conftest.$ac_objext' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_prog_cc_g=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_prog_cc_g=no fi rm -f conftest.err conftest.$ac_objext conftest.$ac_ext fi echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5 echo "${ECHO_T}$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 echo "$as_me:$LINENO: checking for $CC option to accept ANSI C" >&5 echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6 if test "${ac_cv_prog_cc_stdc+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_cv_prog_cc_stdc=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 -std1 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 -std1. */ int osf4_cc_array ['\x00' == 0 ? 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 # Don't try gcc -ansi; that turns off useful extensions and # breaks some systems' header files. # AIX -qlanglvl=ansi # Ultrix and OSF/1 -std1 # HP-UX 10.20 and later -Ae # HP-UX older versions -Aa -D_HPUX_SOURCE # SVR4 -Xc -D__EXTENSIONS__ for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" do CC="$ac_save_CC $ac_arg" rm -f conftest.$ac_objext if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 (eval $ac_compile) 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; } && { ac_try='test -s conftest.$ac_objext' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_prog_cc_stdc=$ac_arg break else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi rm -f conftest.err conftest.$ac_objext done rm -f conftest.$ac_ext conftest.$ac_objext CC=$ac_save_CC fi case "x$ac_cv_prog_cc_stdc" in x|xno) echo "$as_me:$LINENO: result: none needed" >&5 echo "${ECHO_T}none needed" >&6 ;; *) echo "$as_me:$LINENO: result: $ac_cv_prog_cc_stdc" >&5 echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6 CC="$CC $ac_cv_prog_cc_stdc" ;; esac # Some people use a C++ compiler to compile C. Since we use `exit', # in C++ we need to declare it. In case someone uses the same compiler # for both compiling C and C++ we need to have the C++ compiler decide # the declaration of exit, since it's the most demanding environment. cat >conftest.$ac_ext <<_ACEOF #ifndef __cplusplus choke me #endif _ACEOF rm -f conftest.$ac_objext if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 (eval $ac_compile) 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; } && { ac_try='test -s conftest.$ac_objext' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then for ac_declaration in \ '' \ 'extern "C" void std::exit (int) throw (); using std::exit;' \ 'extern "C" void std::exit (int); using std::exit;' \ 'extern "C" void exit (int) throw ();' \ 'extern "C" void exit (int);' \ 'void exit (int);' do cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ $ac_declaration #include int main () { exit (42); ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 (eval $ac_compile) 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; } && { ac_try='test -s conftest.$ac_objext' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then : else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 continue fi rm -f conftest.err conftest.$ac_objext conftest.$ac_ext cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ $ac_declaration int main () { exit (42); ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 (eval $ac_compile) 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; } && { ac_try='test -s conftest.$ac_objext' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then break else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi rm -f conftest.err conftest.$ac_objext conftest.$ac_ext done rm -f conftest* if test -n "$ac_declaration"; then echo '#ifdef __cplusplus' >>confdefs.h echo $ac_declaration >>confdefs.h echo '#endif' >>confdefs.h fi else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi rm -f conftest.err conftest.$ac_objext 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 rm -f .deps 2>/dev/null mkdir .deps 2>/dev/null if test -d .deps; then DEPDIR=.deps else # MS-DOS does not allow filenames that begin with a dot. DEPDIR=_deps fi rmdir .deps 2>/dev/null ac_config_commands="$ac_config_commands depfiles" am_make=${MAKE-make} cat > confinc << 'END' doit: @echo done END # If we don't find an include directive, just comment out the code. echo "$as_me:$LINENO: checking for style of include used by $am_make" >&5 echo $ECHO_N "checking for style of include used by $am_make... $ECHO_C" >&6 am__include="#" am__quote= _am_result=none # First try GNU make style include. echo "include confinc" > confmf # We grep out `Entering directory' and `Leaving directory' # messages which can occur if `w' ends up in MAKEFLAGS. # In particular we don't look at `^make:' because GNU make might # be invoked under some other name (usually "gmake"), in which # case it prints its new name instead of `make'. if test "`$am_make -s -f confmf 2> /dev/null | fgrep -v 'ing directory'`" = "done"; then am__include=include am__quote= _am_result=GNU fi # Now try BSD make style include. if test "$am__include" = "#"; then echo '.include "confinc"' > confmf if test "`$am_make -s -f confmf 2> /dev/null`" = "done"; then am__include=.include am__quote="\"" _am_result=BSD fi fi echo "$as_me:$LINENO: result: $_am_result" >&5 echo "${ECHO_T}$_am_result" >&6 rm -f confinc confmf # Check whether --enable-dependency-tracking or --disable-dependency-tracking was given. if test "${enable_dependency_tracking+set}" = set; then enableval="$enable_dependency_tracking" fi; if test "x$enable_dependency_tracking" != xno; then am_depcomp="$ac_aux_dir/depcomp" AMDEPBACKSLASH='\' fi if test "x$enable_dependency_tracking" != xno; then AMDEP_TRUE= AMDEP_FALSE='#' else AMDEP_TRUE='#' AMDEP_FALSE= fi depcc="$CC" am_compiler_list= echo "$as_me:$LINENO: checking dependency style of $depcc" >&5 echo $ECHO_N "checking dependency style of $depcc... $ECHO_C" >&6 if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&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 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 for depmode in $am_compiler_list; do # 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. echo '#include "conftest.h"' > conftest.c echo 'int i;' > conftest.h echo "${am__include} ${am__quote}conftest.Po${am__quote}" > confmf case $depmode in 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 ;; none) break ;; 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. if depmode=$depmode \ source=conftest.c object=conftest.o \ depfile=conftest.Po tmpdepfile=conftest.TPo \ $SHELL ./depcomp $depcc -c conftest.c -o conftest.o >/dev/null 2>&1 && grep conftest.h conftest.Po > /dev/null 2>&1 && ${MAKE-make} -s -f confmf > /dev/null 2>&1; then am_cv_CC_dependencies_compiler_type=$depmode break fi done cd .. rm -rf conftest.dir else am_cv_CC_dependencies_compiler_type=none fi fi echo "$as_me:$LINENO: result: $am_cv_CC_dependencies_compiler_type" >&5 echo "${ECHO_T}$am_cv_CC_dependencies_compiler_type" >&6 CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type # Check whether --enable-shared or --disable-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 or --disable-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 or --disable-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; # Make sure we can run config.sub. $ac_config_sub sun4 >/dev/null 2>&1 || { { echo "$as_me:$LINENO: error: cannot run $ac_config_sub" >&5 echo "$as_me: error: cannot run $ac_config_sub" >&2;} { (exit 1); exit 1; }; } echo "$as_me:$LINENO: checking build system type" >&5 echo $ECHO_N "checking build system type... $ECHO_C" >&6 if test "${ac_cv_build+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_cv_build_alias=$build_alias test -z "$ac_cv_build_alias" && ac_cv_build_alias=`$ac_config_guess` test -z "$ac_cv_build_alias" && { { echo "$as_me:$LINENO: error: cannot guess build type; you must specify one" >&5 echo "$as_me: error: cannot guess build type; you must specify one" >&2;} { (exit 1); exit 1; }; } ac_cv_build=`$ac_config_sub $ac_cv_build_alias` || { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_build_alias failed" >&5 echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed" >&2;} { (exit 1); exit 1; }; } fi echo "$as_me:$LINENO: result: $ac_cv_build" >&5 echo "${ECHO_T}$ac_cv_build" >&6 build=$ac_cv_build build_cpu=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'` build_vendor=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'` build_os=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'` echo "$as_me:$LINENO: checking host system type" >&5 echo $ECHO_N "checking host system type... $ECHO_C" >&6 if test "${ac_cv_host+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_cv_host_alias=$host_alias test -z "$ac_cv_host_alias" && ac_cv_host_alias=$ac_cv_build_alias ac_cv_host=`$ac_config_sub $ac_cv_host_alias` || { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_host_alias failed" >&5 echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;} { (exit 1); exit 1; }; } fi echo "$as_me:$LINENO: result: $ac_cv_host" >&5 echo "${ECHO_T}$ac_cv_host" >&6 host=$ac_cv_host host_cpu=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'` host_vendor=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'` host_os=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'` echo "$as_me:$LINENO: checking for a sed that does not truncate output" >&5 echo $ECHO_N "checking for a sed that does not truncate output... $ECHO_C" >&6 if test "${lt_cv_path_SED+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else # Loop through the user's path and test for sed and gsed. # Then use that list of sed's as ones to test for truncation. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for lt_ac_prog in sed gsed; do for ac_exec_ext in '' $ac_executable_extensions; do if $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 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 && break 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 fi echo "$as_me:$LINENO: result: $SED" >&5 echo "${ECHO_T}$SED" >&6 echo "$as_me:$LINENO: checking for egrep" >&5 echo $ECHO_N "checking for egrep... $ECHO_C" >&6 if test "${ac_cv_prog_egrep+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else 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 fi echo "$as_me:$LINENO: result: $ac_cv_prog_egrep" >&5 echo "${ECHO_T}$ac_cv_prog_egrep" >&6 EGREP=$ac_cv_prog_egrep # Check whether --with-gnu-ld or --without-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 # Check if gcc -print-prog-name=ld gives a path. echo "$as_me:$LINENO: checking for ld used by $CC" >&5 echo $ECHO_N "checking for ld used by $CC... $ECHO_C" >&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 echo "$as_me:$LINENO: checking for GNU ld" >&5 echo $ECHO_N "checking for GNU ld... $ECHO_C" >&6 else echo "$as_me:$LINENO: checking for non-GNU ld" >&5 echo $ECHO_N "checking for non-GNU ld... $ECHO_C" >&6 fi if test "${lt_cv_path_LD+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&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 GNU ld's only accept -v. # Break only if it was the GNU/non-GNU ld that we prefer. case `"$lt_cv_path_LD" -v 2>&1 &5 echo "${ECHO_T}$LD" >&6 else echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6 fi test -z "$LD" && { { echo "$as_me:$LINENO: error: no acceptable ld found in \$PATH" >&5 echo "$as_me: error: no acceptable ld found in \$PATH" >&2;} { (exit 1); exit 1; }; } echo "$as_me:$LINENO: checking if the linker ($LD) is GNU ld" >&5 echo $ECHO_N "checking if the linker ($LD) is GNU ld... $ECHO_C" >&6 if test "${lt_cv_prog_gnu_ld+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else # I'd rather use --version here, but apparently some GNU ld's only accept -v. case `$LD -v 2>&1 &5 echo "${ECHO_T}$lt_cv_prog_gnu_ld" >&6 with_gnu_ld=$lt_cv_prog_gnu_ld echo "$as_me:$LINENO: checking for $LD option to reload object files" >&5 echo $ECHO_N "checking for $LD option to reload object files... $ECHO_C" >&6 if test "${lt_cv_ld_reload_flag+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_ld_reload_flag='-r' fi echo "$as_me:$LINENO: result: $lt_cv_ld_reload_flag" >&5 echo "${ECHO_T}$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' echo "$as_me:$LINENO: checking for BSD-compatible nm" >&5 echo $ECHO_N "checking for BSD-compatible nm... $ECHO_C" >&6 if test "${lt_cv_path_NM+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$NM"; then # Let the user override the test. lt_cv_path_NM="$NM" else lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR for ac_dir in $PATH /usr/ccs/bin /usr/ucb /bin; do IFS="$lt_save_ifs" test -z "$ac_dir" && ac_dir=. tmp_nm="$ac_dir/${ac_tool_prefix}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" test -z "$lt_cv_path_NM" && lt_cv_path_NM=nm fi fi echo "$as_me:$LINENO: result: $lt_cv_path_NM" >&5 echo "${ECHO_T}$lt_cv_path_NM" >&6 NM="$lt_cv_path_NM" echo "$as_me:$LINENO: checking whether ln -s works" >&5 echo $ECHO_N "checking whether ln -s works... $ECHO_C" >&6 LN_S=$as_ln_s if test "$LN_S" = "ln -s"; then echo "$as_me:$LINENO: result: yes" >&5 echo "${ECHO_T}yes" >&6 else echo "$as_me:$LINENO: result: no, using $LN_S" >&5 echo "${ECHO_T}no, using $LN_S" >&6 fi echo "$as_me:$LINENO: checking how to recognise dependent libraries" >&5 echo $ECHO_N "checking how to recognise dependent libraries... $ECHO_C" >&6 if test "${lt_cv_deplibs_check_method+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&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 aix4* | aix5*) lt_cv_deplibs_check_method=pass_all ;; beos*) lt_cv_deplibs_check_method=pass_all ;; bsdi4*) 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' ;; 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'. lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?' lt_cv_file_magic_cmd='$OBJDUMP -f' ;; darwin* | rhapsody*) lt_cv_deplibs_check_method=pass_all ;; freebsd* | kfreebsd*-gnu) 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)/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 ;; 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 ;; 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*) lt_cv_deplibs_check_method=pass_all ;; netbsd* | netbsdelf*-gnu | knetbsd*-gnu) 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=unknown ;; openbsd*) lt_cv_file_magic_cmd=/usr/bin/file lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB shared object' else lt_cv_deplibs_check_method='file_magic OpenBSD.* shared library' fi ;; osf3* | osf4* | osf5*) lt_cv_deplibs_check_method=pass_all ;; sco3.2v5*) lt_cv_deplibs_check_method=pass_all ;; solaris*) lt_cv_deplibs_check_method=pass_all ;; sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) 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 ;; esac ;; sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[78]* | unixware7* | sysv4*uw2*) lt_cv_deplibs_check_method=pass_all ;; esac fi echo "$as_me:$LINENO: result: $lt_cv_deplibs_check_method" >&5 echo "${ECHO_T}$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 # If no C compiler was specified, use CC. LTCC=${LTCC-"$CC"} # Allow CC to be a program name with arguments. compiler=$CC # Check whether --enable-libtool-lock or --disable-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 # 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=$? 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 3651 "configure"' > conftest.$ac_ext if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? 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-*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=$? 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-*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-*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* ;; *-*-sco3.2v5*) # On SCO OpenServer 5, we need -belf to get full-featured binaries. SAVE_CFLAGS="$CFLAGS" CFLAGS="$CFLAGS -belf" echo "$as_me:$LINENO: checking whether the C compiler needs -belf" >&5 echo $ECHO_N "checking whether the C compiler needs -belf... $ECHO_C" >&6 if test "${lt_cv_cc_needs_belf+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&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 { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 (eval $ac_link) 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; } && { ac_try='test -s conftest$ac_exeext' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then lt_cv_cc_needs_belf=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 lt_cv_cc_needs_belf=no fi rm -f conftest.err conftest.$ac_objext \ 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 echo "$as_me:$LINENO: result: $lt_cv_cc_needs_belf" >&5 echo "${ECHO_T}$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 ;; esac need_locks="$enable_libtool_lock" ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5 echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6 # On Suns, sometimes $CPP names a directory. if test -n "$CPP" && test -d "$CPP"; then CPP= fi if test -z "$CPP"; then if test "${ac_cv_prog_CPP+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else # Double quotes because CPP needs to be expanded for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" do ac_preproc_ok=false for ac_c_preproc_warn_flag in '' yes do # Use a header file that comes with gcc, so configuring glibc # with a fresh cross-compiler works. # Prefer 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 { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&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 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null; then if test -s conftest.err; then ac_cpp_err=$ac_c_preproc_warn_flag ac_cpp_err=$ac_cpp_err$ac_c_werror_flag else ac_cpp_err= fi else ac_cpp_err=yes fi if test -z "$ac_cpp_err"; then : else 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 non-existent 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 { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&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 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null; then if test -s conftest.err; then ac_cpp_err=$ac_c_preproc_warn_flag ac_cpp_err=$ac_cpp_err$ac_c_werror_flag else ac_cpp_err= fi else ac_cpp_err=yes fi if test -z "$ac_cpp_err"; then # Broken: success on invalid input. continue else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 # Passes both tests. ac_preproc_ok=: break fi rm -f conftest.err conftest.$ac_ext done # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. rm -f conftest.err conftest.$ac_ext if $ac_preproc_ok; then break fi done ac_cv_prog_CPP=$CPP fi CPP=$ac_cv_prog_CPP else ac_cv_prog_CPP=$CPP fi echo "$as_me:$LINENO: result: $CPP" >&5 echo "${ECHO_T}$CPP" >&6 ac_preproc_ok=false for ac_c_preproc_warn_flag in '' yes do # Use a header file that comes with gcc, so configuring glibc # with a fresh cross-compiler works. # Prefer 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 { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&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 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null; then if test -s conftest.err; then ac_cpp_err=$ac_c_preproc_warn_flag ac_cpp_err=$ac_cpp_err$ac_c_werror_flag else ac_cpp_err= fi else ac_cpp_err=yes fi if test -z "$ac_cpp_err"; then : else 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 non-existent 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 { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&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 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null; then if test -s conftest.err; then ac_cpp_err=$ac_c_preproc_warn_flag ac_cpp_err=$ac_cpp_err$ac_c_werror_flag else ac_cpp_err= fi else ac_cpp_err=yes fi if test -z "$ac_cpp_err"; then # Broken: success on invalid input. continue else 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 { { echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check See \`config.log' for more details." >&5 echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check See \`config.log' for more details." >&2;} { (exit 1); exit 1; }; } fi ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu echo "$as_me:$LINENO: checking for ANSI C header files" >&5 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6 if test "${ac_cv_header_stdc+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&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 { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 (eval $ac_compile) 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; } && { ac_try='test -s conftest.$ac_objext' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_header_stdc=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_header_stdc=no fi rm -f 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 #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)) exit(2); exit (0); } _ACEOF rm -f conftest$ac_exeext if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='./conftest$ac_exeext' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then : else echo "$as_me: program exited with status $ac_status" >&5 echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ( exit $ac_status ) ac_cv_header_stdc=no fi rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext fi fi fi echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5 echo "${ECHO_T}$ac_cv_header_stdc" >&6 if test $ac_cv_header_stdc = yes; then cat >>confdefs.h <<\_ACEOF #define STDC_HEADERS 1 _ACEOF fi # On IRIX 5.3, sys/types and inttypes.h are conflicting. for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \ inttypes.h stdint.h unistd.h do as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` echo "$as_me:$LINENO: checking for $ac_header" >&5 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6 if eval "test \"\${$as_ac_Header+set}\" = set"; then echo $ECHO_N "(cached) $ECHO_C" >&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 { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 (eval $ac_compile) 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; } && { ac_try='test -s conftest.$ac_objext' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then eval "$as_ac_Header=yes" else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 eval "$as_ac_Header=no" fi rm -f conftest.err conftest.$ac_objext conftest.$ac_ext fi echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6 if test `eval echo '${'$as_ac_Header'}'` = yes; then cat >>confdefs.h <<_ACEOF #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF fi done for ac_header in dlfcn.h do as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` if eval "test \"\${$as_ac_Header+set}\" = set"; then echo "$as_me:$LINENO: checking for $ac_header" >&5 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6 if eval "test \"\${$as_ac_Header+set}\" = set"; then echo $ECHO_N "(cached) $ECHO_C" >&6 fi echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6 else # Is the header compilable? echo "$as_me:$LINENO: checking $ac_header usability" >&5 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&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 { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 (eval $ac_compile) 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; } && { ac_try='test -s conftest.$ac_objext' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_header_compiler=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_header_compiler=no fi rm -f conftest.err conftest.$ac_objext conftest.$ac_ext echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 echo "${ECHO_T}$ac_header_compiler" >&6 # Is the header present? echo "$as_me:$LINENO: checking $ac_header presence" >&5 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&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 { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&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 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null; then if test -s conftest.err; then ac_cpp_err=$ac_c_preproc_warn_flag ac_cpp_err=$ac_cpp_err$ac_c_werror_flag else ac_cpp_err= fi else ac_cpp_err=yes fi if test -z "$ac_cpp_err"; then ac_header_preproc=yes else 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 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 echo "${ECHO_T}$ac_header_preproc" >&6 # So? What about this header? case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in yes:no: ) { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;} ac_header_preproc=yes ;; no:yes:* ) { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5 echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;} ( cat <<\_ASBOX ## ----------------------------------------- ## ## Report this to apreq-dev@httpd.apache.org ## ## ----------------------------------------- ## _ASBOX ) | sed "s/^/$as_me: WARNING: /" >&2 ;; esac echo "$as_me:$LINENO: checking for $ac_header" >&5 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6 if eval "test \"\${$as_ac_Header+set}\" = set"; then echo $ECHO_N "(cached) $ECHO_C" >&6 else eval "$as_ac_Header=\$ac_header_preproc" fi echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6 fi if test `eval echo '${'$as_ac_Header'}'` = yes; then cat >>confdefs.h <<_ACEOF #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF fi done ac_ext=cc 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 -n "$ac_tool_prefix"; then for ac_prog in $CCC g++ c++ gpp aCC CC cxx cc++ cl 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 echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 if test "${ac_cv_prog_CXX+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else 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 do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_CXX="$ac_tool_prefix$ac_prog" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done fi fi CXX=$ac_cv_prog_CXX if test -n "$CXX"; then echo "$as_me:$LINENO: result: $CXX" >&5 echo "${ECHO_T}$CXX" >&6 else echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6 fi test -n "$CXX" && break done fi if test -z "$CXX"; then ac_ct_CXX=$CXX for ac_prog in $CCC g++ c++ gpp aCC CC cxx cc++ cl 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 echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 if test "${ac_cv_prog_ac_ct_CXX+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else 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 do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_CXX="$ac_prog" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done fi fi ac_ct_CXX=$ac_cv_prog_ac_ct_CXX if test -n "$ac_ct_CXX"; then echo "$as_me:$LINENO: result: $ac_ct_CXX" >&5 echo "${ECHO_T}$ac_ct_CXX" >&6 else echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6 fi test -n "$ac_ct_CXX" && break done test -n "$ac_ct_CXX" || ac_ct_CXX="g++" CXX=$ac_ct_CXX fi # Provide some information about the compiler. echo "$as_me:$LINENO:" \ "checking for C++ compiler version" >&5 ac_compiler=`set X $ac_compile; echo $2` { (eval echo "$as_me:$LINENO: \"$ac_compiler --version &5\"") >&5 (eval $ac_compiler --version &5) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } { (eval echo "$as_me:$LINENO: \"$ac_compiler -v &5\"") >&5 (eval $ac_compiler -v &5) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } { (eval echo "$as_me:$LINENO: \"$ac_compiler -V &5\"") >&5 (eval $ac_compiler -V &5) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } echo "$as_me:$LINENO: checking whether we are using the GNU C++ compiler" >&5 echo $ECHO_N "checking whether we are using the GNU C++ compiler... $ECHO_C" >&6 if test "${ac_cv_cxx_compiler_gnu+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ int main () { #ifndef __GNUC__ choke me #endif ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 (eval $ac_compile) 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -z "$ac_cxx_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; } && { ac_try='test -s conftest.$ac_objext' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_compiler_gnu=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_compiler_gnu=no fi rm -f conftest.err conftest.$ac_objext conftest.$ac_ext ac_cv_cxx_compiler_gnu=$ac_compiler_gnu fi echo "$as_me:$LINENO: result: $ac_cv_cxx_compiler_gnu" >&5 echo "${ECHO_T}$ac_cv_cxx_compiler_gnu" >&6 GXX=`test $ac_compiler_gnu = yes && echo yes` ac_test_CXXFLAGS=${CXXFLAGS+set} ac_save_CXXFLAGS=$CXXFLAGS CXXFLAGS="-g" echo "$as_me:$LINENO: checking whether $CXX accepts -g" >&5 echo $ECHO_N "checking whether $CXX accepts -g... $ECHO_C" >&6 if test "${ac_cv_prog_cxx_g+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else 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 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 (eval $ac_compile) 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -z "$ac_cxx_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; } && { ac_try='test -s conftest.$ac_objext' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_prog_cxx_g=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_prog_cxx_g=no fi rm -f conftest.err conftest.$ac_objext conftest.$ac_ext fi echo "$as_me:$LINENO: result: $ac_cv_prog_cxx_g" >&5 echo "${ECHO_T}$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 for ac_declaration in \ '' \ 'extern "C" void std::exit (int) throw (); using std::exit;' \ 'extern "C" void std::exit (int); using std::exit;' \ 'extern "C" void exit (int) throw ();' \ 'extern "C" void exit (int);' \ 'void exit (int);' do cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ $ac_declaration #include int main () { exit (42); ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 (eval $ac_compile) 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -z "$ac_cxx_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; } && { ac_try='test -s conftest.$ac_objext' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then : else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 continue fi rm -f conftest.err conftest.$ac_objext conftest.$ac_ext cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ $ac_declaration int main () { exit (42); ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 (eval $ac_compile) 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -z "$ac_cxx_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; } && { ac_try='test -s conftest.$ac_objext' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then break else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi rm -f conftest.err conftest.$ac_objext conftest.$ac_ext done rm -f conftest* if test -n "$ac_declaration"; then echo '#ifdef __cplusplus' >>confdefs.h echo $ac_declaration >>confdefs.h echo '#endif' >>confdefs.h fi ac_ext=cc 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= echo "$as_me:$LINENO: checking dependency style of $depcc" >&5 echo $ECHO_N "checking dependency style of $depcc... $ECHO_C" >&6 if test "${am_cv_CXX_dependencies_compiler_type+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&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 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 for depmode in $am_compiler_list; do # 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. echo '#include "conftest.h"' > conftest.c echo 'int i;' > conftest.h echo "${am__include} ${am__quote}conftest.Po${am__quote}" > confmf case $depmode in 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 ;; none) break ;; 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. if depmode=$depmode \ source=conftest.c object=conftest.o \ depfile=conftest.Po tmpdepfile=conftest.TPo \ $SHELL ./depcomp $depcc -c conftest.c -o conftest.o >/dev/null 2>&1 && grep conftest.h conftest.Po > /dev/null 2>&1 && ${MAKE-make} -s -f confmf > /dev/null 2>&1; then am_cv_CXX_dependencies_compiler_type=$depmode break fi done cd .. rm -rf conftest.dir else am_cv_CXX_dependencies_compiler_type=none fi fi echo "$as_me:$LINENO: result: $am_cv_CXX_dependencies_compiler_type" >&5 echo "${ECHO_T}$am_cv_CXX_dependencies_compiler_type" >&6 CXXDEPMODE=depmode=$am_cv_CXX_dependencies_compiler_type ac_ext=cc 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 echo "$as_me:$LINENO: checking how to run the C++ preprocessor" >&5 echo $ECHO_N "checking how to run the C++ preprocessor... $ECHO_C" >&6 if test -z "$CXXCPP"; then if test "${ac_cv_prog_CXXCPP+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else # 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 # 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 { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&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 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null; then if test -s conftest.err; then ac_cpp_err=$ac_cxx_preproc_warn_flag ac_cpp_err=$ac_cpp_err$ac_cxx_werror_flag else ac_cpp_err= fi else ac_cpp_err=yes fi if test -z "$ac_cpp_err"; then : else 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 non-existent 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 { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&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 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null; then if test -s conftest.err; then ac_cpp_err=$ac_cxx_preproc_warn_flag ac_cpp_err=$ac_cpp_err$ac_cxx_werror_flag else ac_cpp_err= fi else ac_cpp_err=yes fi if test -z "$ac_cpp_err"; then # Broken: success on invalid input. continue else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 # Passes both tests. ac_preproc_ok=: break fi rm -f conftest.err conftest.$ac_ext done # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. rm -f conftest.err conftest.$ac_ext if $ac_preproc_ok; then break fi done ac_cv_prog_CXXCPP=$CXXCPP fi CXXCPP=$ac_cv_prog_CXXCPP else ac_cv_prog_CXXCPP=$CXXCPP fi echo "$as_me:$LINENO: result: $CXXCPP" >&5 echo "${ECHO_T}$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 { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&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 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null; then if test -s conftest.err; then ac_cpp_err=$ac_cxx_preproc_warn_flag ac_cpp_err=$ac_cpp_err$ac_cxx_werror_flag else ac_cpp_err= fi else ac_cpp_err=yes fi if test -z "$ac_cpp_err"; then : else 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 non-existent 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 { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&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 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null; then if test -s conftest.err; then ac_cpp_err=$ac_cxx_preproc_warn_flag ac_cpp_err=$ac_cpp_err$ac_cxx_werror_flag else ac_cpp_err= fi else ac_cpp_err=yes fi if test -z "$ac_cpp_err"; then # Broken: success on invalid input. continue else 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 { { echo "$as_me:$LINENO: error: C++ preprocessor \"$CXXCPP\" fails sanity check See \`config.log' for more details." >&5 echo "$as_me: error: C++ preprocessor \"$CXXCPP\" fails sanity check See \`config.log' for more details." >&2;} { (exit 1); exit 1; }; } fi ac_ext=cc 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 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 for ac_prog in g77 f77 xlf frt pgf77 fort77 fl32 af77 f90 xlf90 pgf90 epcf90 f95 fort xlf95 ifc efc pgf95 lf95 gfortran 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 echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 if test "${ac_cv_prog_F77+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else 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 do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_F77="$ac_tool_prefix$ac_prog" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done fi fi F77=$ac_cv_prog_F77 if test -n "$F77"; then echo "$as_me:$LINENO: result: $F77" >&5 echo "${ECHO_T}$F77" >&6 else echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6 fi test -n "$F77" && break done fi if test -z "$F77"; then ac_ct_F77=$F77 for ac_prog in g77 f77 xlf frt pgf77 fort77 fl32 af77 f90 xlf90 pgf90 epcf90 f95 fort xlf95 ifc efc pgf95 lf95 gfortran do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 if test "${ac_cv_prog_ac_ct_F77+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else 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 do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_F77="$ac_prog" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done fi fi ac_ct_F77=$ac_cv_prog_ac_ct_F77 if test -n "$ac_ct_F77"; then echo "$as_me:$LINENO: result: $ac_ct_F77" >&5 echo "${ECHO_T}$ac_ct_F77" >&6 else echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6 fi test -n "$ac_ct_F77" && break done F77=$ac_ct_F77 fi # Provide some information about the compiler. echo "$as_me:5175:" \ "checking for Fortran 77 compiler version" >&5 ac_compiler=`set X $ac_compile; echo $2` { (eval echo "$as_me:$LINENO: \"$ac_compiler --version &5\"") >&5 (eval $ac_compiler --version &5) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } { (eval echo "$as_me:$LINENO: \"$ac_compiler -v &5\"") >&5 (eval $ac_compiler -v &5) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } { (eval echo "$as_me:$LINENO: \"$ac_compiler -V &5\"") >&5 (eval $ac_compiler -V &5) 2>&5 ac_status=$? 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 echo "$as_me:$LINENO: checking whether we are using the GNU Fortran 77 compiler" >&5 echo $ECHO_N "checking whether we are using the GNU Fortran 77 compiler... $ECHO_C" >&6 if test "${ac_cv_f77_compiler_gnu+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF program main #ifndef __GNUC__ choke me #endif end _ACEOF rm -f conftest.$ac_objext if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 (eval $ac_compile) 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -z "$ac_f77_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; } && { ac_try='test -s conftest.$ac_objext' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_compiler_gnu=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_compiler_gnu=no fi rm -f conftest.err conftest.$ac_objext conftest.$ac_ext ac_cv_f77_compiler_gnu=$ac_compiler_gnu fi echo "$as_me:$LINENO: result: $ac_cv_f77_compiler_gnu" >&5 echo "${ECHO_T}$ac_cv_f77_compiler_gnu" >&6 ac_ext=$ac_save_ext ac_test_FFLAGS=${FFLAGS+set} ac_save_FFLAGS=$FFLAGS FFLAGS= echo "$as_me:$LINENO: checking whether $F77 accepts -g" >&5 echo $ECHO_N "checking whether $F77 accepts -g... $ECHO_C" >&6 if test "${ac_cv_prog_f77_g+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else FFLAGS=-g cat >conftest.$ac_ext <<_ACEOF program main end _ACEOF rm -f conftest.$ac_objext if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 (eval $ac_compile) 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -z "$ac_f77_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; } && { ac_try='test -s conftest.$ac_objext' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_prog_f77_g=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_prog_f77_g=no fi rm -f conftest.err conftest.$ac_objext conftest.$ac_ext fi echo "$as_me:$LINENO: result: $ac_cv_prog_f77_g" >&5 echo "${ECHO_T}$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 FFLAGS="-g" fi else if test "x$ac_cv_f77_compiler_gnu" = xyes; then FFLAGS="-O2" else FFLAGS= fi fi G77=`test $ac_compiler_gnu = yes && echo yes` 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 # Autoconf 2.13's AC_OBJEXT and AC_EXEEXT macros only works for C compilers! # find the maximum length of command line arguments echo "$as_me:$LINENO: checking the maximum length of command line arguments" >&5 echo $ECHO_N "checking the maximum length of command line arguments... $ECHO_C" >&6 if test "${lt_cv_sys_max_cmd_len+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else 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; ;; 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 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"`$CONFIG_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` ;; esac fi if test -n $lt_cv_sys_max_cmd_len ; then echo "$as_me:$LINENO: result: $lt_cv_sys_max_cmd_len" >&5 echo "${ECHO_T}$lt_cv_sys_max_cmd_len" >&6 else echo "$as_me:$LINENO: result: none" >&5 echo "${ECHO_T}none" >&6 fi # Check for command to grab the raw symbol name followed by C symbol from nm. echo "$as_me:$LINENO: checking command to parse $NM output from $compiler object" >&5 echo $ECHO_N "checking command to parse $NM output from $compiler object... $ECHO_C" >&6 if test "${lt_cv_sys_global_symbol_pipe+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else # These are sane defaults that work on at least a few old systems. # [They come from Ultrix. What could be older than Ultrix?!! ;)] # 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]*\)' # Transform the above into a raw symbol and a C symbol. symxfrm='\1 \2\3 \3' # 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*) 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'" ;; irix* | nonstopux*) symcode='[BCDEGRST]' ;; osf*) symcode='[BCDEGQRST]' ;; solaris* | sysv5*) symcode='[BDRT]' ;; 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 # 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 <&5 (eval $ac_compile) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; then # Now try to grab the symbols. nlist=conftest.nm if { (eval echo "$as_me:$LINENO: \"$NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist\"") >&5 (eval $NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && 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 # 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 EOF # Now generate the symbol file. eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | grep -v main >> 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. */ 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} }; #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_prog_compiler_no_builtin_flag" if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && 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" >&5 fi else echo "cannot find nm_test_var in $nlist" >&5 fi else echo "cannot run $lt_cv_sys_global_symbol_pipe" >&5 fi else echo "$progname: failed program was:" >&5 cat conftest.$ac_ext >&5 fi rm -f 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= fi done fi 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 echo "$as_me:$LINENO: result: failed" >&5 echo "${ECHO_T}failed" >&6 else echo "$as_me:$LINENO: result: ok" >&5 echo "${ECHO_T}ok" >&6 fi echo "$as_me:$LINENO: checking for objdir" >&5 echo $ECHO_N "checking for objdir... $ECHO_C" >&6 if test "${lt_cv_objdir+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&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 echo "$as_me:$LINENO: result: $lt_cv_objdir" >&5 echo "${ECHO_T}$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 s/^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 M$VC, # 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 echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 if test "${ac_cv_prog_AR+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&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 $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_AR="${ac_tool_prefix}ar" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done fi fi AR=$ac_cv_prog_AR if test -n "$AR"; then echo "$as_me:$LINENO: result: $AR" >&5 echo "${ECHO_T}$AR" >&6 else echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}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 echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 if test "${ac_cv_prog_ac_ct_AR+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&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 $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_AR="ar" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done test -z "$ac_cv_prog_ac_ct_AR" && ac_cv_prog_ac_ct_AR="false" fi fi ac_ct_AR=$ac_cv_prog_ac_ct_AR if test -n "$ac_ct_AR"; then echo "$as_me:$LINENO: result: $ac_ct_AR" >&5 echo "${ECHO_T}$ac_ct_AR" >&6 else echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6 fi AR=$ac_ct_AR else AR="$ac_cv_prog_AR" fi 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 echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 if test "${ac_cv_prog_RANLIB+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&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 $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done fi fi RANLIB=$ac_cv_prog_RANLIB if test -n "$RANLIB"; then echo "$as_me:$LINENO: result: $RANLIB" >&5 echo "${ECHO_T}$RANLIB" >&6 else echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6 fi 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 echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&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 $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_RANLIB="ranlib" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done test -z "$ac_cv_prog_ac_ct_RANLIB" && ac_cv_prog_ac_ct_RANLIB=":" fi fi ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB if test -n "$ac_ct_RANLIB"; then echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5 echo "${ECHO_T}$ac_ct_RANLIB" >&6 else echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6 fi RANLIB=$ac_ct_RANLIB else RANLIB="$ac_cv_prog_RANLIB" fi 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 echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 if test "${ac_cv_prog_STRIP+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else 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 do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_STRIP="${ac_tool_prefix}strip" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done fi fi STRIP=$ac_cv_prog_STRIP if test -n "$STRIP"; then echo "$as_me:$LINENO: result: $STRIP" >&5 echo "${ECHO_T}$STRIP" >&6 else echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6 fi 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 echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else 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 do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_STRIP="strip" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done test -z "$ac_cv_prog_ac_ct_STRIP" && ac_cv_prog_ac_ct_STRIP=":" fi fi ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP if test -n "$ac_ct_STRIP"; then echo "$as_me:$LINENO: result: $ac_ct_STRIP" >&5 echo "${ECHO_T}$ac_ct_STRIP" >&6 else echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6 fi STRIP=$ac_ct_STRIP else 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 "$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_deplibs' old_postinstall_cmds='chmod 644 $oldlib' old_postuninstall_cmds= if test -n "$RANLIB"; then case $host_os in openbsd*) old_postinstall_cmds="\$RANLIB -t \$oldlib~$old_postinstall_cmds" ;; *) old_postinstall_cmds="\$RANLIB \$oldlib~$old_postinstall_cmds" ;; esac old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib" fi # 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 echo "$as_me:$LINENO: checking for ${ac_tool_prefix}file" >&5 echo $ECHO_N "checking for ${ac_tool_prefix}file... $ECHO_C" >&6 if test "${lt_cv_path_MAGIC_CMD+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&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 echo "$as_me:$LINENO: result: $MAGIC_CMD" >&5 echo "${ECHO_T}$MAGIC_CMD" >&6 else echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6 fi if test -z "$lt_cv_path_MAGIC_CMD"; then if test -n "$ac_tool_prefix"; then echo "$as_me:$LINENO: checking for file" >&5 echo $ECHO_N "checking for file... $ECHO_C" >&6 if test "${lt_cv_path_MAGIC_CMD+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&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 echo "$as_me:$LINENO: result: $MAGIC_CMD" >&5 echo "${ECHO_T}$MAGIC_CMD" >&6 else echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6 fi else MAGIC_CMD=: fi fi fi ;; esac enable_dlopen=no enable_win32_dll=no # Check whether --enable-libtool-lock or --disable-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 # Check whether --with-pic or --without-pic was given. if test "${with_pic+set}" = set; then withval="$with_pic" pic_mode="$withval" else 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;\n" # Code to be used in simple link tests lt_simple_link_test_code='int main(){return(0);}\n' # If no C compiler was specified, use CC. LTCC=${LTCC-"$CC"} # Allow CC to be a program name with arguments. compiler=$CC # # Check for any special shared library compilation flags. # lt_prog_cc_shlib= if test "$GCC" = no; then case $host_os in sco3.2v5*) lt_prog_cc_shlib='-belf' ;; esac fi if test -n "$lt_prog_cc_shlib"; then { echo "$as_me:$LINENO: WARNING: \`$CC' requires \`$lt_prog_cc_shlib' to build shared libraries" >&5 echo "$as_me: WARNING: \`$CC' requires \`$lt_prog_cc_shlib' to build shared libraries" >&2;} if echo "$old_CC $old_CFLAGS " | grep "[ ]$lt_prog_cc_shlib[ ]" >/dev/null; then : else { echo "$as_me:$LINENO: WARNING: add \`$lt_prog_cc_shlib' to the CC or CFLAGS env variable and reconfigure" >&5 echo "$as_me: WARNING: add \`$lt_prog_cc_shlib' to the CC or CFLAGS env variable and reconfigure" >&2;} lt_cv_prog_cc_can_build_shared=no fi fi # # Check to make sure the static flag actually works. # echo "$as_me:$LINENO: checking if $compiler static flag $lt_prog_compiler_static works" >&5 echo $ECHO_N "checking if $compiler static flag $lt_prog_compiler_static works... $ECHO_C" >&6 if test "${lt_prog_compiler_static_works+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_prog_compiler_static_works=no save_LDFLAGS="$LDFLAGS" LDFLAGS="$LDFLAGS $lt_prog_compiler_static" printf "$lt_simple_link_test_code" > conftest.$ac_ext if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then # The compiler 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 else lt_prog_compiler_static_works=yes fi fi $rm conftest* LDFLAGS="$save_LDFLAGS" fi echo "$as_me:$LINENO: result: $lt_prog_compiler_static_works" >&5 echo "${ECHO_T}$lt_prog_compiler_static_works" >&6 if test x"$lt_prog_compiler_static_works" = xyes; then : else lt_prog_compiler_static= fi lt_prog_compiler_no_builtin_flag= if test "$GCC" = yes; then lt_prog_compiler_no_builtin_flag=' -fno-builtin' echo "$as_me:$LINENO: checking if $compiler supports -fno-rtti -fno-exceptions" >&5 echo $ECHO_N "checking if $compiler supports -fno-rtti -fno-exceptions... $ECHO_C" >&6 if test "${lt_cv_prog_compiler_rtti_exceptions+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_prog_compiler_rtti_exceptions=no ac_outfile=conftest.$ac_objext printf "$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}? :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:6207: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 echo "$as_me:6211: \$? = $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 if test ! -s conftest.err; then lt_cv_prog_compiler_rtti_exceptions=yes fi fi $rm conftest* fi echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_rtti_exceptions" >&5 echo "${ECHO_T}$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= echo "$as_me:$LINENO: checking for $compiler option to produce PIC" >&5 echo $ECHO_N "checking for $compiler option to produce PIC... $ECHO_C" >&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* | cygwin* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) # PIC is the default for these OSes. ;; mingw* | 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' ;; darwin* | rhapsody*) # PIC is the default on this platform # Common symbols not allowed in MH_DYLIB files lt_prog_compiler_pic='-fno-common' ;; 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 ;; mingw* | 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*) case $CC in icc* | ecc*) lt_prog_compiler_wl='-Wl,' lt_prog_compiler_pic='-KPIC' lt_prog_compiler_static='-static' ;; ccc*) lt_prog_compiler_wl='-Wl,' # All Alpha code is PIC. lt_prog_compiler_static='-non_shared' ;; esac ;; osf3* | osf4* | osf5*) lt_prog_compiler_wl='-Wl,' # All OSF/1 code is PIC. lt_prog_compiler_static='-non_shared' ;; sco3.2v5*) lt_prog_compiler_pic='-Kpic' lt_prog_compiler_static='-dn' ;; solaris*) lt_prog_compiler_wl='-Wl,' lt_prog_compiler_pic='-KPIC' lt_prog_compiler_static='-Bstatic' ;; sunos4*) lt_prog_compiler_wl='-Qoption ld ' lt_prog_compiler_pic='-PIC' lt_prog_compiler_static='-Bstatic' ;; sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) 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 ;; uts4*) lt_prog_compiler_pic='-pic' lt_prog_compiler_static='-Bstatic' ;; *) lt_prog_compiler_can_build_shared=no ;; esac fi echo "$as_me:$LINENO: result: $lt_prog_compiler_pic" >&5 echo "${ECHO_T}$lt_prog_compiler_pic" >&6 # # Check to make sure the PIC flag actually works. # if test -n "$lt_prog_compiler_pic"; then echo "$as_me:$LINENO: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5 echo $ECHO_N "checking if $compiler PIC flag $lt_prog_compiler_pic works... $ECHO_C" >&6 if test "${lt_prog_compiler_pic_works+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_prog_compiler_pic_works=no ac_outfile=conftest.$ac_objext printf "$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}? :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:6440: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 echo "$as_me:6444: \$? = $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 if test ! -s conftest.err; then lt_prog_compiler_pic_works=yes fi fi $rm conftest* fi echo "$as_me:$LINENO: result: $lt_prog_compiler_pic_works" >&5 echo "${ECHO_T}$lt_prog_compiler_pic_works" >&6 if test x"$lt_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 echo "$as_me:$LINENO: checking if $compiler supports -c -o file.$ac_objext" >&5 echo $ECHO_N "checking if $compiler supports -c -o file.$ac_objext... $ECHO_C" >&6 if test "${lt_cv_prog_compiler_c_o+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_prog_compiler_c_o=no $rm -r conftest 2>/dev/null mkdir conftest cd conftest mkdir out printf "$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}? :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:6500: $lt_compile\"" >&5) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&5 echo "$as_me:6504: \$? = $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 if test ! -s out/conftest.err; then lt_cv_prog_compiler_c_o=yes fi fi chmod u+w . $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 echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_c_o" >&5 echo "${ECHO_T}$lt_cv_prog_compiler_c_o" >&6 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 echo "$as_me:$LINENO: checking if we can lock with hard links" >&5 echo $ECHO_N "checking if we can lock with hard links... $ECHO_C" >&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 echo "$as_me:$LINENO: result: $hard_links" >&5 echo "${ECHO_T}$hard_links" >&6 if test "$hard_links" = no; then { echo "$as_me:$LINENO: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5 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 echo "$as_me:$LINENO: checking whether the $compiler linker ($LD) supports shared libraries" >&5 echo $ECHO_N "checking whether the $compiler linker ($LD) supports shared libraries... $ECHO_C" >&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_" # 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. extract_expsyms_cmds= 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 ;; 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}' # See if GNU ld supports shared libraries. case $host_os in aix3* | aix4* | aix5*) # 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 '\''/^[BCDGS] /s/.* \([^ ]*\)/\1 DATA/'\'' | $SED -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}--image-base=0x10000000 ${wl}--out-implib,$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}--image-base=0x10000000 ${wl}--out-implib,$lib' else ld_shlibs=no fi ;; netbsd* | netbsdelf*-gnu | knetbsd*-gnu) 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* | sysv5*) 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. 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 ;; sunos4*) archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' wlarc= hardcode_direct=yes hardcode_shlibpath_var=no ;; linux*) if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then tmp_archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' archive_cmds="$tmp_archive_cmds" 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 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 -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' else archive_expsym_cmds="$tmp_archive_cmds" fi link_all_deplibs=no else ld_shlibs=no fi ;; *) 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 if test "$ld_shlibs" = yes; then 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 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 "$link_static_flag"; then # Neither direct hardcoding nor static linking is supported with a # broken collect2. hardcode_direct=unsupported fi ;; aix4* | aix5*) 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 # 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].*|aix5*) 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='' 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 hardcode_direct=yes 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' 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=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. */ int main () { ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 (eval $ac_link) 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; } && { ac_try='test -s conftest$ac_exeext' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } }'` # 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 '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } }'`; fi else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi rm -f conftest.err conftest.$ac_objext \ 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 $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$no_entry_flag \${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 $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$no_entry_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. */ int main () { ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 (eval $ac_link) 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; } && { ac_try='test -s conftest$ac_exeext' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } }'` # 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 '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } }'`; fi else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi rm -f conftest.err conftest.$ac_objext \ 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' # -bexpall does not export symbols beginning with underscore (_) always_export_symbols=yes # Exported symbols can be pulled into shared objects from archives whole_archive_flag_spec=' ' archive_cmds_need_lc=yes # This is similar to how AIX traditionally builds it's shared libraries. archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}-bE:$export_symbols ${wl}-bnoentry${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 ;; bsdi4*) export_dynamic_flag_spec=-rdynamic ;; 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 ;; darwin* | rhapsody*) if test "$GXX" = yes ; then archive_cmds_need_lc=no case "$host_os" in rhapsody* | darwin1.[012]) allow_undefined_flag='-undefined suppress' ;; *) # Darwin 1.3 on if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then allow_undefined_flag='-flat_namespace -undefined suppress' else case ${MACOSX_DEPLOYMENT_TARGET} in 10.[012]) allow_undefined_flag='-flat_namespace -undefined suppress' ;; 10.*) allow_undefined_flag='-undefined dynamic_lookup' ;; esac fi ;; esac lt_int_apple_cc_single_mod=no output_verbose_link_cmd='echo' if $CC -dumpspecs 2>&1 | grep 'single_module' >/dev/null ; then lt_int_apple_cc_single_mod=yes fi if test "X$lt_int_apple_cc_single_mod" = Xyes ; then archive_cmds='$CC -dynamiclib -single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring' else archive_cmds='$CC -r ${wl}-bind_at_load -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' fi module_cmds='$CC ${wl}-bind_at_load $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 ld's if test "X$lt_int_apple_cc_single_mod" = Xyes ; then archive_expsym_cmds='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -dynamiclib -single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' else archive_expsym_cmds='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -r ${wl}-bind_at_load -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~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' fi 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}' hardcode_direct=no hardcode_automatic=yes hardcode_shlibpath_var=unsupported whole_archive_flag_spec='-all_load $convenience' link_all_deplibs=yes 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* | kfreebsd*-gnu) 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* | hpux11*) if test "$GCC" = yes -a "$with_gnu_ld" = no; then case "$host_cpu" in hppa*64*|ia64*) archive_cmds='$CC -shared ${wl}+h ${wl}$soname -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*|ia64*) archive_cmds='$LD -b +h $soname -o $lib $libobjs $deplibs $linker_flags' ;; *) archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' ;; esac fi if test "$with_gnu_ld" = no; then case "$host_cpu" in hppa*64*) hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' hardcode_libdir_flag_spec_ld='+b $libdir' hardcode_libdir_separator=: hardcode_direct=no hardcode_shlibpath_var=no ;; ia64*) hardcode_libdir_flag_spec='-L$libdir' hardcode_direct=no hardcode_shlibpath_var=no # hardcode_minus_L: Not really in the search PATH, # but as the default location of the library. hardcode_minus_L=yes ;; *) hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' hardcode_libdir_separator=: 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*) 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 ;; netbsd* | netbsdelf*-gnu | knetbsd*-gnu) 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) 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*) 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' 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 ;; 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*) 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=: ;; 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 ${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=: ;; sco3.2v5*) archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_shlibpath_var=no export_dynamic_flag_spec='${wl}-Bexport' runpath_var=LD_RUN_PATH hardcode_runpath_var=yes ;; solaris*) no_undefined_flag=' -z text' if test "$GCC" = yes; then 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 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].*) ;; *) # Supported since Solaris 2.6 (maybe 2.5.1?) whole_archive_flag_spec='-z allextract$convenience -z defaultextract' ;; esac link_all_deplibs=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='$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) 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.2uw2*) archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags' hardcode_direct=yes hardcode_minus_L=no hardcode_shlibpath_var=no hardcode_runpath_var=yes runpath_var=LD_RUN_PATH ;; sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[78]* | unixware7*) no_undefined_flag='${wl}-z ${wl}text' if test "$GCC" = yes; then archive_cmds='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' else archive_cmds='$CC -G ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' fi runpath_var='LD_RUN_PATH' hardcode_shlibpath_var=no ;; sysv5*) no_undefined_flag=' -z text' # $CC -shared without GNU ld will not create a library from C++ # object files and a static libstdc++, better avoid it by now 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' hardcode_libdir_flag_spec= hardcode_shlibpath_var=no runpath_var='LD_RUN_PATH' ;; uts4*) archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_libdir_flag_spec='-L$libdir' hardcode_shlibpath_var=no ;; *) ld_shlibs=no ;; esac fi echo "$as_me:$LINENO: result: $ld_shlibs" >&5 echo "${ECHO_T}$ld_shlibs" >&6 test "$ld_shlibs" = 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 # # 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 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. echo "$as_me:$LINENO: checking whether -lc should be explicitly linked in" >&5 echo $ECHO_N "checking whether -lc should be explicitly linked in... $ECHO_C" >&6 $rm conftest* printf "$lt_simple_compile_test_code" > conftest.$ac_ext if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? 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 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=$? 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* echo "$as_me:$LINENO: result: $archive_cmds_need_lc" >&5 echo "${ECHO_T}$archive_cmds_need_lc" >&6 ;; esac fi ;; esac echo "$as_me:$LINENO: checking dynamic linker characteristics" >&5 echo $ECHO_N "checking dynamic linker characteristics... $ECHO_C" >&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 "$GCC" = yes; then 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 ';' >/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. 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 else 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' ;; aix4* | aix5*) 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 ;; bsdi4*) 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' postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ dlpath=$dir/\$dldll~ $rm \$dlpath' shlibpath_overrides_runpath=yes 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 ;; 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)' # Apple's gcc prints 'gcc -print-search-dirs' doesn't operate the same. if test "$GCC" = yes; then sys_lib_search_path_spec=`$CC -print-search-dirs | tr "\n" "$PATH_SEPARATOR" | sed -e 's/libraries:/@libraries:/' | tr "@" "\n" | grep "^libraries:" | sed -e "s/^libraries://" -e "s,=/,/,g" -e "s,$PATH_SEPARATOR, ,g" -e "s,.*,& /lib /usr/lib /usr/local/lib,g"` else sys_lib_search_path_spec='/lib /usr/lib /usr/local/lib' 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 ;; kfreebsd*-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 shlibpath_overrides_runpath=no hardcode_into_libs=yes dynamic_linker='GNU ld.so' ;; freebsd*) objformat=`test -x /usr/bin/objformat && /usr/bin/objformat || echo aout` 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 ;; *) # from 3.2 on shlibpath_overrides_runpath=no 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' ;; 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 ;; # No shared lib support for Linux oldld, aout, or coff. linux*oldld* | linux*aout* | linux*coff*) dynamic_linker=no ;; # This must be Linux ELF. 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}' 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=`$SED -e 's/:,\t/ /g;s/=^=*$//;s/=^= * / /g' /etc/ld.so.conf | 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' ;; netbsdelf*-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 shlibpath_overrides_runpath=no hardcode_into_libs=yes dynamic_linker='NetBSD ld.elf_so' ;; knetbsd*-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 shlibpath_overrides_runpath=no hardcode_into_libs=yes dynamic_linker='GNU 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 ;; 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 ;; 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 need_lib_prefix=no need_version=yes 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" ;; sco3.2v5*) version_type=osf 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 ;; 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.2uw2* | sysv4.3* | sysv5*) 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 ;; 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 echo "$as_me:$LINENO: result: $dynamic_linker" >&5 echo "${ECHO_T}$dynamic_linker" >&6 test "$dynamic_linker" = no && can_build_shared=no echo "$as_me:$LINENO: checking how to hardcode library paths into programs" >&5 echo $ECHO_N "checking how to hardcode library paths into programs... $ECHO_C" >&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 echo "$as_me:$LINENO: result: $hardcode_action" >&5 echo "${ECHO_T}$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= echo "$as_me:$LINENO: checking whether stripping libraries is possible" >&5 echo $ECHO_N "checking whether stripping libraries is possible... $ECHO_C" >&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" echo "$as_me:$LINENO: result: yes" >&5 echo "${ECHO_T}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" echo "$as_me:$LINENO: result: yes" >&5 echo "${ECHO_T}yes" >&6 else echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6 fi ;; *) echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}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 echo "$as_me:$LINENO: checking for dlopen in -ldl" >&5 echo $ECHO_N "checking for dlopen in -ldl... $ECHO_C" >&6 if test "${ac_cv_lib_dl_dlopen+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&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 gcc2 internal prototype to avoid an error. */ #ifdef __cplusplus extern "C" #endif /* We use char because int might match the return type of a gcc2 builtin and then its argument prototype would still apply. */ char dlopen (); int main () { dlopen (); ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 (eval $ac_link) 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; } && { ac_try='test -s conftest$ac_exeext' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_lib_dl_dlopen=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_lib_dl_dlopen=no fi rm -f conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi echo "$as_me:$LINENO: result: $ac_cv_lib_dl_dlopen" >&5 echo "${ECHO_T}$ac_cv_lib_dl_dlopen" >&6 if test $ac_cv_lib_dl_dlopen = yes; then lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl" else lt_cv_dlopen="dyld" lt_cv_dlopen_libs= lt_cv_dlopen_self=yes fi ;; *) echo "$as_me:$LINENO: checking for shl_load" >&5 echo $ECHO_N "checking for shl_load... $ECHO_C" >&6 if test "${ac_cv_func_shl_load+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&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. */ #ifdef __STDC__ # include #else # include #endif #undef shl_load /* Override any gcc2 internal prototype to avoid an error. */ #ifdef __cplusplus extern "C" { #endif /* We use char because int might match the return type of a gcc2 builtin and then its argument prototype would still apply. */ 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 #else char (*f) () = shl_load; #endif #ifdef __cplusplus } #endif int main () { return f != shl_load; ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 (eval $ac_link) 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; } && { ac_try='test -s conftest$ac_exeext' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_func_shl_load=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_func_shl_load=no fi rm -f conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext fi echo "$as_me:$LINENO: result: $ac_cv_func_shl_load" >&5 echo "${ECHO_T}$ac_cv_func_shl_load" >&6 if test $ac_cv_func_shl_load = yes; then lt_cv_dlopen="shl_load" else echo "$as_me:$LINENO: checking for shl_load in -ldld" >&5 echo $ECHO_N "checking for shl_load in -ldld... $ECHO_C" >&6 if test "${ac_cv_lib_dld_shl_load+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&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 gcc2 internal prototype to avoid an error. */ #ifdef __cplusplus extern "C" #endif /* We use char because int might match the return type of a gcc2 builtin and then its argument prototype would still apply. */ char shl_load (); int main () { shl_load (); ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 (eval $ac_link) 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; } && { ac_try='test -s conftest$ac_exeext' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_lib_dld_shl_load=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_lib_dld_shl_load=no fi rm -f conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi echo "$as_me:$LINENO: result: $ac_cv_lib_dld_shl_load" >&5 echo "${ECHO_T}$ac_cv_lib_dld_shl_load" >&6 if test $ac_cv_lib_dld_shl_load = yes; then lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-dld" else echo "$as_me:$LINENO: checking for dlopen" >&5 echo $ECHO_N "checking for dlopen... $ECHO_C" >&6 if test "${ac_cv_func_dlopen+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&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 /* 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. */ #ifdef __STDC__ # include #else # include #endif #undef dlopen /* Override any gcc2 internal prototype to avoid an error. */ #ifdef __cplusplus extern "C" { #endif /* We use char because int might match the return type of a gcc2 builtin and then its argument prototype would still apply. */ 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 #else char (*f) () = dlopen; #endif #ifdef __cplusplus } #endif int main () { return f != dlopen; ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 (eval $ac_link) 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; } && { ac_try='test -s conftest$ac_exeext' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_func_dlopen=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_func_dlopen=no fi rm -f conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext fi echo "$as_me:$LINENO: result: $ac_cv_func_dlopen" >&5 echo "${ECHO_T}$ac_cv_func_dlopen" >&6 if test $ac_cv_func_dlopen = yes; then lt_cv_dlopen="dlopen" else echo "$as_me:$LINENO: checking for dlopen in -ldl" >&5 echo $ECHO_N "checking for dlopen in -ldl... $ECHO_C" >&6 if test "${ac_cv_lib_dl_dlopen+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&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 gcc2 internal prototype to avoid an error. */ #ifdef __cplusplus extern "C" #endif /* We use char because int might match the return type of a gcc2 builtin and then its argument prototype would still apply. */ char dlopen (); int main () { dlopen (); ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 (eval $ac_link) 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; } && { ac_try='test -s conftest$ac_exeext' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_lib_dl_dlopen=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_lib_dl_dlopen=no fi rm -f conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi echo "$as_me:$LINENO: result: $ac_cv_lib_dl_dlopen" >&5 echo "${ECHO_T}$ac_cv_lib_dl_dlopen" >&6 if test $ac_cv_lib_dl_dlopen = yes; then lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl" else echo "$as_me:$LINENO: checking for dlopen in -lsvld" >&5 echo $ECHO_N "checking for dlopen in -lsvld... $ECHO_C" >&6 if test "${ac_cv_lib_svld_dlopen+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&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 gcc2 internal prototype to avoid an error. */ #ifdef __cplusplus extern "C" #endif /* We use char because int might match the return type of a gcc2 builtin and then its argument prototype would still apply. */ char dlopen (); int main () { dlopen (); ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 (eval $ac_link) 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; } && { ac_try='test -s conftest$ac_exeext' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_lib_svld_dlopen=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_lib_svld_dlopen=no fi rm -f conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi echo "$as_me:$LINENO: result: $ac_cv_lib_svld_dlopen" >&5 echo "${ECHO_T}$ac_cv_lib_svld_dlopen" >&6 if test $ac_cv_lib_svld_dlopen = yes; then lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld" else echo "$as_me:$LINENO: checking for dld_link in -ldld" >&5 echo $ECHO_N "checking for dld_link in -ldld... $ECHO_C" >&6 if test "${ac_cv_lib_dld_dld_link+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&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 gcc2 internal prototype to avoid an error. */ #ifdef __cplusplus extern "C" #endif /* We use char because int might match the return type of a gcc2 builtin and then its argument prototype would still apply. */ char dld_link (); int main () { dld_link (); ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 (eval $ac_link) 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; } && { ac_try='test -s conftest$ac_exeext' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_lib_dld_dld_link=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_lib_dld_dld_link=no fi rm -f conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi echo "$as_me:$LINENO: result: $ac_cv_lib_dld_dld_link" >&5 echo "${ECHO_T}$ac_cv_lib_dld_dld_link" >&6 if test $ac_cv_lib_dld_dld_link = yes; then lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-dld" fi 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" eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" save_LIBS="$LIBS" LIBS="$lt_cv_dlopen_libs $LIBS" echo "$as_me:$LINENO: checking whether a program can dlopen itself" >&5 echo $ECHO_N "checking whether a program can dlopen itself... $ECHO_C" >&6 if test "${lt_cv_dlopen_self+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&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 < #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); */ } exit (status); } EOF if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && test -s conftest${ac_exeext} 2>/dev/null; then (./conftest; exit; ) 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_unknown|x*) lt_cv_dlopen_self=no ;; esac else : # compilation failed lt_cv_dlopen_self=no fi fi rm -fr conftest* fi echo "$as_me:$LINENO: result: $lt_cv_dlopen_self" >&5 echo "${ECHO_T}$lt_cv_dlopen_self" >&6 if test "x$lt_cv_dlopen_self" = xyes; then LDFLAGS="$LDFLAGS $link_static_flag" echo "$as_me:$LINENO: checking whether a statically linked program can dlopen itself" >&5 echo $ECHO_N "checking whether a statically linked program can dlopen itself... $ECHO_C" >&6 if test "${lt_cv_dlopen_self_static+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&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); */ } exit (status); } EOF if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && test -s conftest${ac_exeext} 2>/dev/null; then (./conftest; exit; ) 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_unknown|x*) lt_cv_dlopen_self_static=no ;; esac else : # compilation failed lt_cv_dlopen_self_static=no fi fi rm -fr conftest* fi echo "$as_me:$LINENO: result: $lt_cv_dlopen_self_static" >&5 echo "${ECHO_T}$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 librarie types wil actually be built echo "$as_me:$LINENO: checking if libtool supports shared libraries" >&5 echo $ECHO_N "checking if libtool supports shared libraries... $ECHO_C" >&6 echo "$as_me:$LINENO: result: $can_build_shared" >&5 echo "${ECHO_T}$can_build_shared" >&6 echo "$as_me:$LINENO: checking whether to build shared libraries" >&5 echo $ECHO_N "checking whether to build shared libraries... $ECHO_C" >&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 ;; aix4* | aix5*) if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then test "$enable_shared" = yes && enable_static=no fi ;; darwin* | rhapsody*) if test "$GCC" = yes; then archive_cmds_need_lc=no case "$host_os" in rhapsody* | darwin1.[012]) allow_undefined_flag='-undefined suppress' ;; *) # Darwin 1.3 on if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then allow_undefined_flag='-flat_namespace -undefined suppress' else case ${MACOSX_DEPLOYMENT_TARGET} in 10.[012]) allow_undefined_flag='-flat_namespace -undefined suppress' ;; 10.*) allow_undefined_flag='-undefined dynamic_lookup' ;; esac fi ;; esac output_verbose_link_cmd='echo' archive_cmds='$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs$compiler_flags -install_name $rpath/$soname $verstring' 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 ld's archive_expsym_cmds='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs$compiler_flags -install_name $rpath/$soname $verstring~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}' hardcode_direct=no hardcode_automatic=yes hardcode_shlibpath_var=unsupported whole_archive_flag_spec='-all_load $convenience' link_all_deplibs=yes else ld_shlibs=no fi ;; esac echo "$as_me:$LINENO: result: $enable_shared" >&5 echo "${ECHO_T}$enable_shared" >&6 echo "$as_me:$LINENO: checking whether to build static libraries" >&5 echo $ECHO_N "checking whether to build static libraries... $ECHO_C" >&6 # Make sure either enable_shared or enable_static is yes. test "$enable_shared" = yes || enable_static=yes echo "$as_me:$LINENO: result: $enable_static" >&5 echo "${ECHO_T}$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 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 \ 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 \ 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" { echo "$as_me:$LINENO: creating $ofile" >&5 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 # 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., 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. # 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 s/^X//" # The HP-UX ksh and POSIX shell print the target directory to stdout # if CDPATH is set. if test "X\${CDPATH+set}" = Xset; then CDPATH=:; export CDPATH; fi # 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 # 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 # 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 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="$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 or --without-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 { echo "$as_me:$LINENO: WARNING: output file \`$ofile' does not exist" >&5 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 { echo "$as_me:$LINENO: WARNING: output file \`$ofile' does not look like a libtool script" >&5 echo "$as_me: WARNING: output file \`$ofile' does not look like a libtool script" >&2;} else { echo "$as_me:$LINENO: WARNING: using \`LTCC=$LTCC', extracted from \`$ofile'" >&5 echo "$as_me: WARNING: using \`LTCC=$LTCC', extracted from \`$ofile'" >&2;} fi 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 "") ;; *) { { echo "$as_me:$LINENO: error: invalid tag name: $tagname" >&5 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 { { echo "$as_me:$LINENO: error: tag name \"$tagname\" already exists" >&5 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"; then ac_ext=cc 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_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= # Source file extension for C++ test sources. ac_ext=cc # 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;\n" # Code to be used in simple link tests lt_simple_link_test_code='int main(int, char *) { return(0); }\n' # ltmain only uses $CC for tagged configurations so make sure $CC is set. # If no C compiler was specified, use CC. LTCC=${LTCC-"$CC"} # Allow CC to be a program name with arguments. compiler=$CC # 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 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 unset lt_cv_path_LD fi test -z "${LDCXX+set}" || LD=$LDCXX CC=${CXX-"c++"} compiler=$CC compiler_CXX=$CC cc_basename=`$echo X"$compiler" | $Xsed -e 's%^.*/%%'` # 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 # Check whether --with-gnu-ld or --without-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 # Check if gcc -print-prog-name=ld gives a path. echo "$as_me:$LINENO: checking for ld used by $CC" >&5 echo $ECHO_N "checking for ld used by $CC... $ECHO_C" >&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 echo "$as_me:$LINENO: checking for GNU ld" >&5 echo $ECHO_N "checking for GNU ld... $ECHO_C" >&6 else echo "$as_me:$LINENO: checking for non-GNU ld" >&5 echo $ECHO_N "checking for non-GNU ld... $ECHO_C" >&6 fi if test "${lt_cv_path_LD+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&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 GNU ld's only accept -v. # Break only if it was the GNU/non-GNU ld that we prefer. case `"$lt_cv_path_LD" -v 2>&1 &5 echo "${ECHO_T}$LD" >&6 else echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6 fi test -z "$LD" && { { echo "$as_me:$LINENO: error: no acceptable ld found in \$PATH" >&5 echo "$as_me: error: no acceptable ld found in \$PATH" >&2;} { (exit 1); exit 1; }; } echo "$as_me:$LINENO: checking if the linker ($LD) is GNU ld" >&5 echo $ECHO_N "checking if the linker ($LD) is GNU ld... $ECHO_C" >&6 if test "${lt_cv_prog_gnu_ld+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else # I'd rather use --version here, but apparently some GNU ld's only accept -v. case `$LD -v 2>&1 &5 echo "${ECHO_T}$lt_cv_prog_gnu_ld" >&6 with_gnu_ld=$lt_cv_prog_gnu_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 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 whole_archive_flag_spec_CXX= 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. archive_cmds_CXX='$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"' else GXX=no with_gnu_ld=no wlarc= fi # PORTME: fill in a description of your system's C++ link characteristics echo "$as_me:$LINENO: checking whether the $compiler linker ($LD) supports shared libraries" >&5 echo $ECHO_N "checking whether the $compiler linker ($LD) supports shared libraries... $ECHO_C" >&6 ld_shlibs_CXX=yes case $host_os in aix3*) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; aix4* | aix5*) 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].*|aix5*) for ld_flag in $LDFLAGS; do case $ld_flag in *-brtl*) aix_use_runtimelinking=yes break ;; esac 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_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 hardcode_direct_CXX=yes 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' 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_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 cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ int main () { ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 (eval $ac_link) 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -z "$ac_cxx_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; } && { ac_try='test -s conftest$ac_exeext' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } }'` # 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 '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } }'`; fi else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi rm -f conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi hardcode_libdir_flag_spec_CXX='${wl}-blibpath:$libdir:'"$aix_libpath" archive_expsym_cmds_CXX="\$CC"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$no_entry_flag \${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 $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$no_entry_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. */ int main () { ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 (eval $ac_link) 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -z "$ac_cxx_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; } && { ac_try='test -s conftest$ac_exeext' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } }'` # 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 '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } }'`; fi else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi rm -f conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi 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' # -bexpall does not export symbols beginning with underscore (_) always_export_symbols_CXX=yes # Exported symbols can be pulled into shared objects from archives whole_archive_flag_spec_CXX=' ' archive_cmds_need_lc_CXX=yes # This is similar to how AIX traditionally builds it's shared libraries. archive_expsym_cmds_CXX="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}-bE:$export_symbols ${wl}-bnoentry${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' fi fi ;; chorus*) case $cc_basename in *) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; esac ;; 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}--image-base=0x10000000 ${wl}--out-implib,$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}--image-base=0x10000000 ${wl}--out-implib,$lib' else ld_shlibs_CXX=no fi ;; darwin* | rhapsody*) if test "$GXX" = yes; then archive_cmds_need_lc_CXX=no case "$host_os" in rhapsody* | darwin1.[012]) allow_undefined_flag_CXX='-undefined suppress' ;; *) # Darwin 1.3 on if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then allow_undefined_flag_CXX='-flat_namespace -undefined suppress' else case ${MACOSX_DEPLOYMENT_TARGET} in 10.[012]) allow_undefined_flag_CXX='-flat_namespace -undefined suppress' ;; 10.*) allow_undefined_flag_CXX='-undefined dynamic_lookup' ;; esac fi ;; esac lt_int_apple_cc_single_mod=no output_verbose_link_cmd='echo' if $CC -dumpspecs 2>&1 | grep 'single_module' >/dev/null ; then lt_int_apple_cc_single_mod=yes fi if test "X$lt_int_apple_cc_single_mod" = Xyes ; then archive_cmds_CXX='$CC -dynamiclib -single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring' else archive_cmds_CXX='$CC -r ${wl}-bind_at_load -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' fi module_cmds_CXX='$CC ${wl}-bind_at_load $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 ld's if test "X$lt_int_apple_cc_single_mod" = Xyes ; then archive_expsym_cmds_CXX='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -dynamiclib -single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' else archive_expsym_cmds_CXX='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -r ${wl}-bind_at_load -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~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' fi 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}' hardcode_direct_CXX=no hardcode_automatic_CXX=yes hardcode_shlibpath_var_CXX=unsupported whole_archive_flag_spec_CXX='-all_load $convenience' link_all_deplibs_CXX=yes else ld_shlibs_CXX=no fi ;; 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 ;; freebsd12*) # 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* | kfreebsd*-gnu) # 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 ;; 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' ;; *) 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 ;; hpux10*|hpux11*) if test $with_gnu_ld = no; then case "$host_cpu" in hppa*64*) hardcode_libdir_flag_spec_CXX='${wl}+b ${wl}$libdir' hardcode_libdir_flag_spec_ld_CXX='+b $libdir' hardcode_libdir_separator_CXX=: ;; ia64*) hardcode_libdir_flag_spec_CXX='-L$libdir' ;; *) hardcode_libdir_flag_spec_CXX='${wl}+b ${wl}$libdir' hardcode_libdir_separator_CXX=: export_dynamic_flag_spec_CXX='${wl}-E' ;; esac fi case "$host_cpu" in hppa*64*) hardcode_direct_CXX=no hardcode_shlibpath_var_CXX=no ;; ia64*) hardcode_direct_CXX=no hardcode_shlibpath_var_CXX=no hardcode_minus_L_CXX=yes # Not in the search PATH, # but as the default # location of the library. ;; *) hardcode_direct_CXX=yes hardcode_minus_L_CXX=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 ld_shlibs_CXX=no ;; aCC) case "$host_cpu" in hppa*64*|ia64*) archive_cmds_CXX='$LD -b +h $soname -o $lib $linker_flags $libobjs $deplibs' ;; *) 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 ia64*|hppa*64*) archive_cmds_CXX='$LD -b +h $soname -o $lib $linker_flags $libobjs $deplibs' ;; *) 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 ;; 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 ${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}${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*) 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 archive_cmds_need_lc_CXX=no 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' 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' ;; 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' ;; 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* | netbsdelf*-gnu | knetbsd*-gnu) 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::"' ;; 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 ${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}${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 ${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 $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}${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 ;; sco*) archive_cmds_need_lc_CXX=no case $cc_basename in CC) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; *) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; esac ;; 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++ no_undefined_flag_CXX=' -zdefs' archive_cmds_CXX='$CC -G${allow_undefined_flag} -nolib -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} -nolib ${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 C++ compiler is used as linker so we must use $wl # flag to pass the commands to the underlying system # linker. # Supported since Solaris 2.6 (maybe 2.5.1?) whole_archive_flag_spec_CXX='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' ;; esac link_all_deplibs_CXX=yes # 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 -G $CFLAGS -v conftest.$objext 2>&1 | grep "\-[LR]"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' # 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' fi ;; esac ;; sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[78]* | unixware7*) archive_cmds_need_lc_CXX=no ;; 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 echo "$as_me:$LINENO: result: $ld_shlibs_CXX" >&5 echo "${ECHO_T}$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=$? 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 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= echo "$as_me:$LINENO: checking for $compiler option to produce PIC" >&5 echo $ECHO_N "checking for $compiler option to produce PIC... $ECHO_C" >&6 # 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' 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* | cygwin* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) # PIC is the default for these OSes. ;; mingw* | 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). 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= ;; 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 aix4* | aix5*) # 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 ;; 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* | kfreebsd*-gnu) # FreeBSD uses GNU C++ ;; hpux9* | hpux10* | hpux11*) case $cc_basename in CC) lt_prog_compiler_wl_CXX='-Wl,' lt_prog_compiler_static_CXX="${ac_cv_prog_cc_wl}-a ${ac_cv_prog_cc_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="${ac_cv_prog_cc_wl}-a ${ac_cv_prog_cc_wl}archive" case "$host_cpu" in hppa*64*|ia64*) # +Z the default ;; *) lt_prog_compiler_pic_CXX='+Z' ;; esac ;; *) ;; esac ;; 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*) case $cc_basename in KCC) # KAI C++ Compiler lt_prog_compiler_wl_CXX='--backend -Wl,' lt_prog_compiler_pic_CXX='-fPIC' ;; icpc) # Intel C++ lt_prog_compiler_wl_CXX='-Wl,' lt_prog_compiler_pic_CXX='-KPIC' lt_prog_compiler_static_CXX='-static' ;; 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' ;; *) ;; esac ;; lynxos*) ;; m88k*) ;; mvs*) case $cc_basename in cxx) lt_prog_compiler_pic_CXX='-W c,exportall' ;; *) ;; esac ;; netbsd* | netbsdelf*-gnu | knetbsd*-gnu) ;; 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*) ;; sco*) case $cc_basename in CC) lt_prog_compiler_pic_CXX='-fPIC' ;; *) ;; esac ;; 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 ;; unixware*) ;; vxworks*) ;; *) lt_prog_compiler_can_build_shared_CXX=no ;; esac fi echo "$as_me:$LINENO: result: $lt_prog_compiler_pic_CXX" >&5 echo "${ECHO_T}$lt_prog_compiler_pic_CXX" >&6 # # Check to make sure the PIC flag actually works. # if test -n "$lt_prog_compiler_pic_CXX"; then echo "$as_me:$LINENO: checking if $compiler PIC flag $lt_prog_compiler_pic_CXX works" >&5 echo $ECHO_N "checking if $compiler PIC flag $lt_prog_compiler_pic_CXX works... $ECHO_C" >&6 if test "${lt_prog_compiler_pic_works_CXX+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_prog_compiler_pic_works_CXX=no ac_outfile=conftest.$ac_objext printf "$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}? :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:10963: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 echo "$as_me:10967: \$? = $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 if test ! -s conftest.err; then lt_prog_compiler_pic_works_CXX=yes fi fi $rm conftest* fi echo "$as_me:$LINENO: result: $lt_prog_compiler_pic_works_CXX" >&5 echo "${ECHO_T}$lt_prog_compiler_pic_works_CXX" >&6 if test x"$lt_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 echo "$as_me:$LINENO: checking if $compiler supports -c -o file.$ac_objext" >&5 echo $ECHO_N "checking if $compiler supports -c -o file.$ac_objext... $ECHO_C" >&6 if test "${lt_cv_prog_compiler_c_o_CXX+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_prog_compiler_c_o_CXX=no $rm -r conftest 2>/dev/null mkdir conftest cd conftest mkdir out printf "$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}? :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:11023: $lt_compile\"" >&5) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&5 echo "$as_me:11027: \$? = $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 if test ! -s out/conftest.err; then lt_cv_prog_compiler_c_o_CXX=yes fi fi chmod u+w . $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 echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_c_o_CXX" >&5 echo "${ECHO_T}$lt_cv_prog_compiler_c_o_CXX" >&6 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 echo "$as_me:$LINENO: checking if we can lock with hard links" >&5 echo $ECHO_N "checking if we can lock with hard links... $ECHO_C" >&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 echo "$as_me:$LINENO: result: $hard_links" >&5 echo "${ECHO_T}$hard_links" >&6 if test "$hard_links" = no; then { echo "$as_me:$LINENO: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5 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 echo "$as_me:$LINENO: checking whether the $compiler linker ($LD) supports shared libraries" >&5 echo $ECHO_N "checking whether the $compiler linker ($LD) supports shared libraries... $ECHO_C" >&6 export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' case $host_os in aix4* | aix5*) # 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 '\''/^[BCDGS] /s/.* \([^ ]*\)/\1 DATA/'\'' | $SED -e '\''/^[AITW] /s/.* //'\'' | sort | uniq > $export_symbols' ;; linux*) link_all_deplibs_CXX=no ;; *) export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' ;; esac echo "$as_me:$LINENO: result: $ld_shlibs_CXX" >&5 echo "${ECHO_T}$ld_shlibs_CXX" >&6 test "$ld_shlibs_CXX" = 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 # # 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 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. echo "$as_me:$LINENO: checking whether -lc should be explicitly linked in" >&5 echo $ECHO_N "checking whether -lc should be explicitly linked in... $ECHO_C" >&6 $rm conftest* printf "$lt_simple_compile_test_code" > conftest.$ac_ext if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? 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_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=$? 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* echo "$as_me:$LINENO: result: $archive_cmds_need_lc_CXX" >&5 echo "${ECHO_T}$archive_cmds_need_lc_CXX" >&6 ;; esac fi ;; esac echo "$as_me:$LINENO: checking dynamic linker characteristics" >&5 echo $ECHO_N "checking dynamic linker characteristics... $ECHO_C" >&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 "$GCC" = yes; then 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 ';' >/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. 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 else 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' ;; aix4* | aix5*) 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 ;; bsdi4*) 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' postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ dlpath=$dir/\$dldll~ $rm \$dlpath' shlibpath_overrides_runpath=yes 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 ;; 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)' # Apple's gcc prints 'gcc -print-search-dirs' doesn't operate the same. if test "$GCC" = yes; then sys_lib_search_path_spec=`$CC -print-search-dirs | tr "\n" "$PATH_SEPARATOR" | sed -e 's/libraries:/@libraries:/' | tr "@" "\n" | grep "^libraries:" | sed -e "s/^libraries://" -e "s,=/,/,g" -e "s,$PATH_SEPARATOR, ,g" -e "s,.*,& /lib /usr/lib /usr/local/lib,g"` else sys_lib_search_path_spec='/lib /usr/lib /usr/local/lib' 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 ;; kfreebsd*-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 shlibpath_overrides_runpath=no hardcode_into_libs=yes dynamic_linker='GNU ld.so' ;; freebsd*) objformat=`test -x /usr/bin/objformat && /usr/bin/objformat || echo aout` 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 ;; *) # from 3.2 on shlibpath_overrides_runpath=no 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' ;; 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 ;; # No shared lib support for Linux oldld, aout, or coff. linux*oldld* | linux*aout* | linux*coff*) dynamic_linker=no ;; # This must be Linux ELF. 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}' 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=`$SED -e 's/:,\t/ /g;s/=^=*$//;s/=^= * / /g' /etc/ld.so.conf | 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' ;; netbsdelf*-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 shlibpath_overrides_runpath=no hardcode_into_libs=yes dynamic_linker='NetBSD ld.elf_so' ;; knetbsd*-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 shlibpath_overrides_runpath=no hardcode_into_libs=yes dynamic_linker='GNU 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 ;; 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 ;; 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 need_lib_prefix=no need_version=yes 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" ;; sco3.2v5*) version_type=osf 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 ;; 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.2uw2* | sysv4.3* | sysv5*) 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 ;; 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 echo "$as_me:$LINENO: result: $dynamic_linker" >&5 echo "${ECHO_T}$dynamic_linker" >&6 test "$dynamic_linker" = no && can_build_shared=no echo "$as_me:$LINENO: checking how to hardcode library paths into programs" >&5 echo $ECHO_N "checking how to hardcode library paths into programs... $ECHO_C" >&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 echo "$as_me:$LINENO: result: $hardcode_action_CXX" >&5 echo "${ECHO_T}$hardcode_action_CXX" >&6 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 striplib= old_striplib= echo "$as_me:$LINENO: checking whether stripping libraries is possible" >&5 echo $ECHO_N "checking whether stripping libraries is possible... $ECHO_C" >&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" echo "$as_me:$LINENO: result: yes" >&5 echo "${ECHO_T}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" echo "$as_me:$LINENO: result: yes" >&5 echo "${ECHO_T}yes" >&6 else echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6 fi ;; *) echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}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 echo "$as_me:$LINENO: checking for dlopen in -ldl" >&5 echo $ECHO_N "checking for dlopen in -ldl... $ECHO_C" >&6 if test "${ac_cv_lib_dl_dlopen+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&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 gcc2 internal prototype to avoid an error. */ #ifdef __cplusplus extern "C" #endif /* We use char because int might match the return type of a gcc2 builtin and then its argument prototype would still apply. */ char dlopen (); int main () { dlopen (); ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 (eval $ac_link) 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -z "$ac_cxx_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; } && { ac_try='test -s conftest$ac_exeext' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_lib_dl_dlopen=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_lib_dl_dlopen=no fi rm -f conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi echo "$as_me:$LINENO: result: $ac_cv_lib_dl_dlopen" >&5 echo "${ECHO_T}$ac_cv_lib_dl_dlopen" >&6 if test $ac_cv_lib_dl_dlopen = yes; then lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl" else lt_cv_dlopen="dyld" lt_cv_dlopen_libs= lt_cv_dlopen_self=yes fi ;; *) echo "$as_me:$LINENO: checking for shl_load" >&5 echo $ECHO_N "checking for shl_load... $ECHO_C" >&6 if test "${ac_cv_func_shl_load+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&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. */ #ifdef __STDC__ # include #else # include #endif #undef shl_load /* Override any gcc2 internal prototype to avoid an error. */ #ifdef __cplusplus extern "C" { #endif /* We use char because int might match the return type of a gcc2 builtin and then its argument prototype would still apply. */ 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 #else char (*f) () = shl_load; #endif #ifdef __cplusplus } #endif int main () { return f != shl_load; ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 (eval $ac_link) 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -z "$ac_cxx_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; } && { ac_try='test -s conftest$ac_exeext' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_func_shl_load=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_func_shl_load=no fi rm -f conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext fi echo "$as_me:$LINENO: result: $ac_cv_func_shl_load" >&5 echo "${ECHO_T}$ac_cv_func_shl_load" >&6 if test $ac_cv_func_shl_load = yes; then lt_cv_dlopen="shl_load" else echo "$as_me:$LINENO: checking for shl_load in -ldld" >&5 echo $ECHO_N "checking for shl_load in -ldld... $ECHO_C" >&6 if test "${ac_cv_lib_dld_shl_load+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&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 gcc2 internal prototype to avoid an error. */ #ifdef __cplusplus extern "C" #endif /* We use char because int might match the return type of a gcc2 builtin and then its argument prototype would still apply. */ char shl_load (); int main () { shl_load (); ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 (eval $ac_link) 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -z "$ac_cxx_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; } && { ac_try='test -s conftest$ac_exeext' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_lib_dld_shl_load=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_lib_dld_shl_load=no fi rm -f conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi echo "$as_me:$LINENO: result: $ac_cv_lib_dld_shl_load" >&5 echo "${ECHO_T}$ac_cv_lib_dld_shl_load" >&6 if test $ac_cv_lib_dld_shl_load = yes; then lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-dld" else echo "$as_me:$LINENO: checking for dlopen" >&5 echo $ECHO_N "checking for dlopen... $ECHO_C" >&6 if test "${ac_cv_func_dlopen+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&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 /* 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. */ #ifdef __STDC__ # include #else # include #endif #undef dlopen /* Override any gcc2 internal prototype to avoid an error. */ #ifdef __cplusplus extern "C" { #endif /* We use char because int might match the return type of a gcc2 builtin and then its argument prototype would still apply. */ 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 #else char (*f) () = dlopen; #endif #ifdef __cplusplus } #endif int main () { return f != dlopen; ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 (eval $ac_link) 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -z "$ac_cxx_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; } && { ac_try='test -s conftest$ac_exeext' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_func_dlopen=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_func_dlopen=no fi rm -f conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext fi echo "$as_me:$LINENO: result: $ac_cv_func_dlopen" >&5 echo "${ECHO_T}$ac_cv_func_dlopen" >&6 if test $ac_cv_func_dlopen = yes; then lt_cv_dlopen="dlopen" else echo "$as_me:$LINENO: checking for dlopen in -ldl" >&5 echo $ECHO_N "checking for dlopen in -ldl... $ECHO_C" >&6 if test "${ac_cv_lib_dl_dlopen+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&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 gcc2 internal prototype to avoid an error. */ #ifdef __cplusplus extern "C" #endif /* We use char because int might match the return type of a gcc2 builtin and then its argument prototype would still apply. */ char dlopen (); int main () { dlopen (); ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 (eval $ac_link) 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -z "$ac_cxx_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; } && { ac_try='test -s conftest$ac_exeext' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_lib_dl_dlopen=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_lib_dl_dlopen=no fi rm -f conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi echo "$as_me:$LINENO: result: $ac_cv_lib_dl_dlopen" >&5 echo "${ECHO_T}$ac_cv_lib_dl_dlopen" >&6 if test $ac_cv_lib_dl_dlopen = yes; then lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl" else echo "$as_me:$LINENO: checking for dlopen in -lsvld" >&5 echo $ECHO_N "checking for dlopen in -lsvld... $ECHO_C" >&6 if test "${ac_cv_lib_svld_dlopen+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&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 gcc2 internal prototype to avoid an error. */ #ifdef __cplusplus extern "C" #endif /* We use char because int might match the return type of a gcc2 builtin and then its argument prototype would still apply. */ char dlopen (); int main () { dlopen (); ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 (eval $ac_link) 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -z "$ac_cxx_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; } && { ac_try='test -s conftest$ac_exeext' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_lib_svld_dlopen=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_lib_svld_dlopen=no fi rm -f conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi echo "$as_me:$LINENO: result: $ac_cv_lib_svld_dlopen" >&5 echo "${ECHO_T}$ac_cv_lib_svld_dlopen" >&6 if test $ac_cv_lib_svld_dlopen = yes; then lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld" else echo "$as_me:$LINENO: checking for dld_link in -ldld" >&5 echo $ECHO_N "checking for dld_link in -ldld... $ECHO_C" >&6 if test "${ac_cv_lib_dld_dld_link+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&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 gcc2 internal prototype to avoid an error. */ #ifdef __cplusplus extern "C" #endif /* We use char because int might match the return type of a gcc2 builtin and then its argument prototype would still apply. */ char dld_link (); int main () { dld_link (); ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 (eval $ac_link) 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -z "$ac_cxx_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; } && { ac_try='test -s conftest$ac_exeext' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_lib_dld_dld_link=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_lib_dld_dld_link=no fi rm -f conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi echo "$as_me:$LINENO: result: $ac_cv_lib_dld_dld_link" >&5 echo "${ECHO_T}$ac_cv_lib_dld_dld_link" >&6 if test $ac_cv_lib_dld_dld_link = yes; then lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-dld" fi 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" eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" save_LIBS="$LIBS" LIBS="$lt_cv_dlopen_libs $LIBS" echo "$as_me:$LINENO: checking whether a program can dlopen itself" >&5 echo $ECHO_N "checking whether a program can dlopen itself... $ECHO_C" >&6 if test "${lt_cv_dlopen_self+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&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 < #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); */ } exit (status); } EOF if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && test -s conftest${ac_exeext} 2>/dev/null; then (./conftest; exit; ) 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_unknown|x*) lt_cv_dlopen_self=no ;; esac else : # compilation failed lt_cv_dlopen_self=no fi fi rm -fr conftest* fi echo "$as_me:$LINENO: result: $lt_cv_dlopen_self" >&5 echo "${ECHO_T}$lt_cv_dlopen_self" >&6 if test "x$lt_cv_dlopen_self" = xyes; then LDFLAGS="$LDFLAGS $link_static_flag" echo "$as_me:$LINENO: checking whether a statically linked program can dlopen itself" >&5 echo $ECHO_N "checking whether a statically linked program can dlopen itself... $ECHO_C" >&6 if test "${lt_cv_dlopen_self_static+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&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); */ } exit (status); } EOF if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && test -s conftest${ac_exeext} 2>/dev/null; then (./conftest; exit; ) 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_unknown|x*) lt_cv_dlopen_self_static=no ;; esac else : # compilation failed lt_cv_dlopen_self_static=no fi fi rm -fr conftest* fi echo "$as_me:$LINENO: result: $lt_cv_dlopen_self_static" >&5 echo "${ECHO_T}$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 # 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 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 \ 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 \ 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 # Whether or not to optimize for fast installation. fast_install=$enable_fast_install # The host system. host_alias=$host_alias host=$host # 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 # A language-specific compiler. CC=$lt_compiler_CXX # Is the compiler the GNU C compiler? with_gcc=$GCC_CXX # 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" # 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 # 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 # 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_CXX # Compiler flag to turn off builtin functions. no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag_CXX # Compiler flag to allow reflexive dlopens. export_dynamic_flag_spec=$lt_export_dynamic_flag_spec_CXX # Compiler flag to generate shared objects directly from archives. whole_archive_flag_spec=$lt_whole_archive_flag_spec_CXX # Compiler flag to generate thread-safe objects. thread_safe_flag_spec=$lt_thread_safe_flag_spec_CXX # 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_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 # 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 # 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 # 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 # Dependencies to place before the objects being linked to create a # shared library. predep_objects=$lt_predep_objects_CXX # Dependencies to place after the objects being linked to create a # shared library. postdep_objects=$lt_postdep_objects_CXX # Dependencies to place before the objects being linked to create a # shared library. predeps=$lt_predeps_CXX # Dependencies to place after the objects being linked to create a # shared library. postdeps=$lt_postdeps_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 # 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_CXX # Flag that forces no undefined symbols. no_undefined_flag=$lt_no_undefined_flag_CXX # 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_CXX # 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_CXX # 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 # Whether we need a single -rpath flag with a separated argument. hardcode_libdir_separator=$lt_hardcode_libdir_separator_CXX # Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the # resulting binary. hardcode_direct=$hardcode_direct_CXX # Set to yes if using the -LDIR flag during linking hardcodes DIR into the # resulting binary. hardcode_minus_L=$hardcode_minus_L_CXX # Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into # the resulting binary. hardcode_shlibpath_var=$hardcode_shlibpath_var_CXX # 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 # 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_CXX # 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="$fix_srcfile_path_CXX" # Set to yes if exported symbols are required. always_export_symbols=$always_export_symbols_CXX # The commands to list exported symbols. export_symbols_cmds=$lt_export_symbols_cmds_CXX # 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 # Symbols that must always be exported. include_expsyms=$lt_include_expsyms_CXX # ### 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 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 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 ;; 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 # Code to be used in simple compile tests lt_simple_compile_test_code=" subroutine t\n return\n end\n" # Code to be used in simple link tests lt_simple_link_test_code=" program t\n end\n" # ltmain only uses $CC for tagged configurations so make sure $CC is set. # If no C compiler was specified, use CC. LTCC=${LTCC-"$CC"} # Allow CC to be a program name with arguments. compiler=$CC # Allow CC to be a program name with arguments. lt_save_CC="$CC" CC=${F77-"f77"} compiler=$CC compiler_F77=$CC cc_basename=`$echo X"$compiler" | $Xsed -e 's%^.*/%%'` echo "$as_me:$LINENO: checking if libtool supports shared libraries" >&5 echo $ECHO_N "checking if libtool supports shared libraries... $ECHO_C" >&6 echo "$as_me:$LINENO: result: $can_build_shared" >&5 echo "${ECHO_T}$can_build_shared" >&6 echo "$as_me:$LINENO: checking whether to build shared libraries" >&5 echo $ECHO_N "checking whether to build shared libraries... $ECHO_C" >&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 ;; aix4* | aix5*) test "$enable_shared" = yes && enable_static=no ;; esac echo "$as_me:$LINENO: result: $enable_shared" >&5 echo "${ECHO_T}$enable_shared" >&6 echo "$as_me:$LINENO: checking whether to build static libraries" >&5 echo $ECHO_N "checking whether to build static libraries... $ECHO_C" >&6 # Make sure either enable_shared or enable_static is yes. test "$enable_shared" = yes || enable_static=yes echo "$as_me:$LINENO: result: $enable_static" >&5 echo "${ECHO_T}$enable_static" >&6 test "$ld_shlibs_F77" = no && can_build_shared=no GCC_F77="$G77" LD_F77="$LD" lt_prog_compiler_wl_F77= lt_prog_compiler_pic_F77= lt_prog_compiler_static_F77= echo "$as_me:$LINENO: checking for $compiler option to produce PIC" >&5 echo $ECHO_N "checking for $compiler option to produce PIC... $ECHO_C" >&6 if test "$GCC" = yes; then lt_prog_compiler_wl_F77='-Wl,' lt_prog_compiler_static_F77='-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_F77='-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_F77='-m68020 -resident32 -malways-restore-a4' ;; beos* | cygwin* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) # PIC is the default for these OSes. ;; mingw* | 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' ;; darwin* | rhapsody*) # PIC is the default on this platform # Common symbols not allowed in MH_DYLIB files lt_prog_compiler_pic_F77='-fno-common' ;; 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 ;; sysv4*MP*) if test -d /usr/nec; then lt_prog_compiler_pic_F77=-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_F77='-fPIC' ;; esac ;; *) 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 ;; mingw* | 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' ;; 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' ;; 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' ;; linux*) case $CC in icc* | ecc*) lt_prog_compiler_wl_F77='-Wl,' lt_prog_compiler_pic_F77='-KPIC' lt_prog_compiler_static_F77='-static' ;; ccc*) lt_prog_compiler_wl_F77='-Wl,' # All Alpha code is PIC. lt_prog_compiler_static_F77='-non_shared' ;; esac ;; osf3* | osf4* | osf5*) lt_prog_compiler_wl_F77='-Wl,' # All OSF/1 code is PIC. lt_prog_compiler_static_F77='-non_shared' ;; sco3.2v5*) lt_prog_compiler_pic_F77='-Kpic' lt_prog_compiler_static_F77='-dn' ;; solaris*) lt_prog_compiler_wl_F77='-Wl,' lt_prog_compiler_pic_F77='-KPIC' lt_prog_compiler_static_F77='-Bstatic' ;; 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* | sysv5*) 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 ;; uts4*) lt_prog_compiler_pic_F77='-pic' lt_prog_compiler_static_F77='-Bstatic' ;; *) lt_prog_compiler_can_build_shared_F77=no ;; esac fi echo "$as_me:$LINENO: result: $lt_prog_compiler_pic_F77" >&5 echo "${ECHO_T}$lt_prog_compiler_pic_F77" >&6 # # Check to make sure the PIC flag actually works. # if test -n "$lt_prog_compiler_pic_F77"; then echo "$as_me:$LINENO: checking if $compiler PIC flag $lt_prog_compiler_pic_F77 works" >&5 echo $ECHO_N "checking if $compiler PIC flag $lt_prog_compiler_pic_F77 works... $ECHO_C" >&6 if test "${lt_prog_compiler_pic_works_F77+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_prog_compiler_pic_works_F77=no ac_outfile=conftest.$ac_objext printf "$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}? :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:13317: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 echo "$as_me:13321: \$? = $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 if test ! -s conftest.err; then lt_prog_compiler_pic_works_F77=yes fi fi $rm conftest* fi echo "$as_me:$LINENO: result: $lt_prog_compiler_pic_works_F77" >&5 echo "${ECHO_T}$lt_prog_compiler_pic_works_F77" >&6 if test x"$lt_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 fi 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 echo "$as_me:$LINENO: checking if $compiler supports -c -o file.$ac_objext" >&5 echo $ECHO_N "checking if $compiler supports -c -o file.$ac_objext... $ECHO_C" >&6 if test "${lt_cv_prog_compiler_c_o_F77+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_prog_compiler_c_o_F77=no $rm -r conftest 2>/dev/null mkdir conftest cd conftest mkdir out printf "$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}? :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:13377: $lt_compile\"" >&5) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&5 echo "$as_me:13381: \$? = $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 if test ! -s out/conftest.err; then lt_cv_prog_compiler_c_o_F77=yes fi fi chmod u+w . $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 echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_c_o_F77" >&5 echo "${ECHO_T}$lt_cv_prog_compiler_c_o_F77" >&6 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 echo "$as_me:$LINENO: checking if we can lock with hard links" >&5 echo $ECHO_N "checking if we can lock with hard links... $ECHO_C" >&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 echo "$as_me:$LINENO: result: $hard_links" >&5 echo "${ECHO_T}$hard_links" >&6 if test "$hard_links" = no; then { echo "$as_me:$LINENO: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5 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 echo "$as_me:$LINENO: checking whether the $compiler linker ($LD) supports shared libraries" >&5 echo $ECHO_N "checking whether the $compiler linker ($LD) supports shared libraries... $ECHO_C" >&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_" # 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. extract_expsyms_cmds= 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 ;; openbsd*) with_gnu_ld=no ;; esac ld_shlibs_F77=yes if test "$with_gnu_ld" = yes; then # If archive_cmds runs LD, not CC, wlarc should be empty wlarc='${wl}' # See if GNU ld supports shared libraries. case $host_os in aix3* | aix4* | aix5*) # 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 ;; 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 ;; 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 '\''/^[BCDGS] /s/.* \([^ ]*\)/\1 DATA/'\'' | $SED -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}--image-base=0x10000000 ${wl}--out-implib,$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}--image-base=0x10000000 ${wl}--out-implib,$lib' else ld_shlibs=no fi ;; netbsd* | netbsdelf*-gnu | knetbsd*-gnu) 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* | sysv5*) 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 ;; 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 ;; linux*) if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then tmp_archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' archive_cmds_F77="$tmp_archive_cmds" 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 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 -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' else archive_expsym_cmds_F77="$tmp_archive_cmds" fi link_all_deplibs_F77=no else ld_shlibs_F77=no fi ;; *) 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" = yes; then 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 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 "$link_static_flag"; then # Neither direct hardcoding nor static linking is supported with a # broken collect2. hardcode_direct_F77=unsupported fi ;; aix4* | aix5*) 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].*|aix5*) 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 hardcode_direct_F77=yes 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' 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 end _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 (eval $ac_link) 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -z "$ac_f77_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; } && { ac_try='test -s conftest$ac_exeext' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } }'` # 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 '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } }'`; fi else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi rm -f conftest.err conftest.$ac_objext \ 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 $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$no_entry_flag \${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 $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$no_entry_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 end _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 (eval $ac_link) 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -z "$ac_f77_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; } && { ac_try='test -s conftest$ac_exeext' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } }'` # 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 '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } }'`; fi else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi rm -f conftest.err conftest.$ac_objext \ 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' # -bexpall does not export symbols beginning with underscore (_) always_export_symbols_F77=yes # Exported symbols can be pulled into shared objects from archives whole_archive_flag_spec_F77=' ' archive_cmds_need_lc_F77=yes # This is similar to how AIX traditionally builds it's shared libraries. archive_expsym_cmds_F77="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}-bE:$export_symbols ${wl}-bnoentry${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 ;; bsdi4*) export_dynamic_flag_spec_F77=-rdynamic ;; 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='`cygpath -w "$srcfile"`' enable_shared_with_static_runtimes_F77=yes ;; darwin* | rhapsody*) if test "$GXX" = yes ; then archive_cmds_need_lc_F77=no case "$host_os" in rhapsody* | darwin1.[012]) allow_undefined_flag_F77='-undefined suppress' ;; *) # Darwin 1.3 on if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then allow_undefined_flag_F77='-flat_namespace -undefined suppress' else case ${MACOSX_DEPLOYMENT_TARGET} in 10.[012]) allow_undefined_flag_F77='-flat_namespace -undefined suppress' ;; 10.*) allow_undefined_flag_F77='-undefined dynamic_lookup' ;; esac fi ;; esac lt_int_apple_cc_single_mod=no output_verbose_link_cmd='echo' if $CC -dumpspecs 2>&1 | grep 'single_module' >/dev/null ; then lt_int_apple_cc_single_mod=yes fi if test "X$lt_int_apple_cc_single_mod" = Xyes ; then archive_cmds_F77='$CC -dynamiclib -single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring' else archive_cmds_F77='$CC -r ${wl}-bind_at_load -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' fi module_cmds_F77='$CC ${wl}-bind_at_load $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 ld's if test "X$lt_int_apple_cc_single_mod" = Xyes ; then archive_expsym_cmds_F77='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -dynamiclib -single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' else archive_expsym_cmds_F77='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -r ${wl}-bind_at_load -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~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' fi 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}' hardcode_direct_F77=no hardcode_automatic_F77=yes hardcode_shlibpath_var_F77=unsupported whole_archive_flag_spec_F77='-all_load $convenience' link_all_deplibs_F77=yes else ld_shlibs_F77=no 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 ;; freebsd1*) ld_shlibs_F77=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_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 ;; # 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* | kfreebsd*-gnu) 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 ;; 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 # 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' ;; hpux10* | hpux11*) if test "$GCC" = yes -a "$with_gnu_ld" = no; then case "$host_cpu" in hppa*64*|ia64*) archive_cmds_F77='$CC -shared ${wl}+h ${wl}$soname -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*|ia64*) archive_cmds_F77='$LD -b +h $soname -o $lib $libobjs $deplibs $linker_flags' ;; *) archive_cmds_F77='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' ;; esac fi if test "$with_gnu_ld" = no; then case "$host_cpu" in hppa*64*) hardcode_libdir_flag_spec_F77='${wl}+b ${wl}$libdir' hardcode_libdir_flag_spec_ld_F77='+b $libdir' hardcode_libdir_separator_F77=: hardcode_direct_F77=no hardcode_shlibpath_var_F77=no ;; ia64*) hardcode_libdir_flag_spec_F77='-L$libdir' hardcode_direct_F77=no hardcode_shlibpath_var_F77=no # hardcode_minus_L: Not really in the search PATH, # but as the default location of the library. hardcode_minus_L_F77=yes ;; *) hardcode_libdir_flag_spec_F77='${wl}+b ${wl}$libdir' hardcode_libdir_separator_F77=: hardcode_direct_F77=yes export_dynamic_flag_spec_F77='${wl}-E' # 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 ;; netbsd* | netbsdelf*-gnu | knetbsd*-gnu) 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 ;; 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 ;; openbsd*) 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' hardcode_libdir_flag_spec_F77='${wl}-rpath,$libdir' export_dynamic_flag_spec_F77='${wl}-E' else 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 ;; 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=: ;; 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 ${objdir}/so_locations -o $lib~$rm $lib.exp' # Both c and cxx compiler support -rpath directly hardcode_libdir_flag_spec_F77='-rpath $libdir' fi hardcode_libdir_separator_F77=: ;; sco3.2v5*) archive_cmds_F77='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_shlibpath_var_F77=no export_dynamic_flag_spec_F77='${wl}-Bexport' runpath_var=LD_RUN_PATH hardcode_runpath_var=yes ;; solaris*) no_undefined_flag_F77=' -z text' if test "$GCC" = yes; then 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 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].*) ;; *) # Supported since Solaris 2.6 (maybe 2.5.1?) whole_archive_flag_spec_F77='-z allextract$convenience -z defaultextract' ;; esac link_all_deplibs_F77=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_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 ;; 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 ;; 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' ;; 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 ;; sysv4.2uw2*) archive_cmds_F77='$LD -G -o $lib $libobjs $deplibs $linker_flags' hardcode_direct_F77=yes hardcode_minus_L_F77=no hardcode_shlibpath_var_F77=no hardcode_runpath_var=yes runpath_var=LD_RUN_PATH ;; sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[78]* | unixware7*) no_undefined_flag_F77='${wl}-z ${wl}text' if test "$GCC" = yes; then archive_cmds_F77='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' else archive_cmds_F77='$CC -G ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' fi runpath_var='LD_RUN_PATH' hardcode_shlibpath_var_F77=no ;; sysv5*) no_undefined_flag_F77=' -z text' # $CC -shared without GNU ld will not create a library from C++ # object files and a static libstdc++, better avoid it by now 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' hardcode_libdir_flag_spec_F77= hardcode_shlibpath_var_F77=no runpath_var='LD_RUN_PATH' ;; 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 ;; *) ld_shlibs_F77=no ;; esac fi echo "$as_me:$LINENO: result: $ld_shlibs_F77" >&5 echo "${ECHO_T}$ld_shlibs_F77" >&6 test "$ld_shlibs_F77" = 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 # # 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 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. echo "$as_me:$LINENO: checking whether -lc should be explicitly linked in" >&5 echo $ECHO_N "checking whether -lc should be explicitly linked in... $ECHO_C" >&6 $rm conftest* printf "$lt_simple_compile_test_code" > conftest.$ac_ext if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? 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_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=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } then archive_cmds_need_lc_F77=no else archive_cmds_need_lc_F77=yes fi allow_undefined_flag_F77=$lt_save_allow_undefined_flag else cat conftest.err 1>&5 fi $rm conftest* echo "$as_me:$LINENO: result: $archive_cmds_need_lc_F77" >&5 echo "${ECHO_T}$archive_cmds_need_lc_F77" >&6 ;; esac fi ;; esac echo "$as_me:$LINENO: checking dynamic linker characteristics" >&5 echo $ECHO_N "checking dynamic linker characteristics... $ECHO_C" >&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 "$GCC" = yes; then 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 ';' >/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. 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 else 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' ;; aix4* | aix5*) 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 ;; bsdi4*) 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' postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ dlpath=$dir/\$dldll~ $rm \$dlpath' shlibpath_overrides_runpath=yes 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 ;; 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)' # Apple's gcc prints 'gcc -print-search-dirs' doesn't operate the same. if test "$GCC" = yes; then sys_lib_search_path_spec=`$CC -print-search-dirs | tr "\n" "$PATH_SEPARATOR" | sed -e 's/libraries:/@libraries:/' | tr "@" "\n" | grep "^libraries:" | sed -e "s/^libraries://" -e "s,=/,/,g" -e "s,$PATH_SEPARATOR, ,g" -e "s,.*,& /lib /usr/lib /usr/local/lib,g"` else sys_lib_search_path_spec='/lib /usr/lib /usr/local/lib' 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 ;; kfreebsd*-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 shlibpath_overrides_runpath=no hardcode_into_libs=yes dynamic_linker='GNU ld.so' ;; freebsd*) objformat=`test -x /usr/bin/objformat && /usr/bin/objformat || echo aout` 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 ;; *) # from 3.2 on shlibpath_overrides_runpath=no 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' ;; 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 ;; # No shared lib support for Linux oldld, aout, or coff. linux*oldld* | linux*aout* | linux*coff*) dynamic_linker=no ;; # This must be Linux ELF. 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}' 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=`$SED -e 's/:,\t/ /g;s/=^=*$//;s/=^= * / /g' /etc/ld.so.conf | 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' ;; netbsdelf*-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 shlibpath_overrides_runpath=no hardcode_into_libs=yes dynamic_linker='NetBSD ld.elf_so' ;; knetbsd*-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 shlibpath_overrides_runpath=no hardcode_into_libs=yes dynamic_linker='GNU 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 ;; 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 ;; 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 need_lib_prefix=no need_version=yes 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" ;; sco3.2v5*) version_type=osf 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 ;; 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.2uw2* | sysv4.3* | sysv5*) 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 ;; 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 echo "$as_me:$LINENO: result: $dynamic_linker" >&5 echo "${ECHO_T}$dynamic_linker" >&6 test "$dynamic_linker" = no && can_build_shared=no echo "$as_me:$LINENO: checking how to hardcode library paths into programs" >&5 echo $ECHO_N "checking how to hardcode library paths into programs... $ECHO_C" >&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 # We cannot hardcode anything, or else we can only hardcode existing # directories. hardcode_action_F77=unsupported fi echo "$as_me:$LINENO: result: $hardcode_action_F77" >&5 echo "${ECHO_T}$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 striplib= old_striplib= echo "$as_me:$LINENO: checking whether stripping libraries is possible" >&5 echo $ECHO_N "checking whether stripping libraries is possible... $ECHO_C" >&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" echo "$as_me:$LINENO: result: yes" >&5 echo "${ECHO_T}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" echo "$as_me:$LINENO: result: yes" >&5 echo "${ECHO_T}yes" >&6 else echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6 fi ;; *) echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6 ;; esac 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 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 \ 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 \ 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 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_F77 # Whether or not to disallow shared libs when runtime libs are static allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes_F77 # Whether or not to optimize for fast installation. fast_install=$enable_fast_install # The host system. host_alias=$host_alias host=$host # 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 # A language-specific compiler. CC=$lt_compiler_F77 # Is the compiler the GNU C compiler? with_gcc=$GCC_F77 # An ERE matcher. EGREP=$lt_EGREP # The linker used to build libraries. LD=$lt_LD_F77 # 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_F77 # 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_F77 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_F77 # 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_F77 # Compiler flag to turn off builtin functions. no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag_F77 # 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 # Compiler flag to generate thread-safe objects. thread_safe_flag_spec=$lt_thread_safe_flag_spec_F77 # 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_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 # 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 # 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 # 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 # 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 # Dependencies to place before the objects being linked to create a # shared library. predeps=$lt_predeps_F77 # Dependencies to place after the objects being linked to create a # shared library. postdeps=$lt_postdeps_F77 # 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 # 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_F77 # Flag that forces no undefined symbols. no_undefined_flag=$lt_no_undefined_flag_F77 # 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_F77 # 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_F77 # 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 # Whether we need a single -rpath flag with a separated argument. hardcode_libdir_separator=$lt_hardcode_libdir_separator_F77 # 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 # 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 # 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 # 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="$fix_srcfile_path_F77" # 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 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" else tagname="" fi ;; GCJ) if test -n "$GCJ" && test "X$GCJ" != "Xno"; then # 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 {}\n" # Code to be used in simple link tests lt_simple_link_test_code='public class conftest { public static void main(String argv) {}; }\n' # ltmain only uses $CC for tagged configurations so make sure $CC is set. # If no C compiler was specified, use CC. LTCC=${LTCC-"$CC"} # Allow CC to be a program name with arguments. compiler=$CC # Allow CC to be a program name with arguments. lt_save_CC="$CC" CC=${GCJ-"gcj"} compiler=$CC compiler_GCJ=$CC # GCJ did not exist at the time GCC didn't implicitly link libc in. archive_cmds_need_lc_GCJ=no lt_prog_compiler_no_builtin_flag_GCJ= if test "$GCC" = yes; then lt_prog_compiler_no_builtin_flag_GCJ=' -fno-builtin' echo "$as_me:$LINENO: checking if $compiler supports -fno-rtti -fno-exceptions" >&5 echo $ECHO_N "checking if $compiler supports -fno-rtti -fno-exceptions... $ECHO_C" >&6 if test "${lt_cv_prog_compiler_rtti_exceptions+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_prog_compiler_rtti_exceptions=no ac_outfile=conftest.$ac_objext printf "$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}? :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:15422: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 echo "$as_me:15426: \$? = $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 if test ! -s conftest.err; then lt_cv_prog_compiler_rtti_exceptions=yes fi fi $rm conftest* fi echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_rtti_exceptions" >&5 echo "${ECHO_T}$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 : fi fi lt_prog_compiler_wl_GCJ= lt_prog_compiler_pic_GCJ= lt_prog_compiler_static_GCJ= echo "$as_me:$LINENO: checking for $compiler option to produce PIC" >&5 echo $ECHO_N "checking for $compiler option to produce PIC... $ECHO_C" >&6 if test "$GCC" = yes; then lt_prog_compiler_wl_GCJ='-Wl,' lt_prog_compiler_static_GCJ='-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_GCJ='-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_GCJ='-m68020 -resident32 -malways-restore-a4' ;; beos* | cygwin* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) # PIC is the default for these OSes. ;; mingw* | 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_GCJ='-DDLL_EXPORT' ;; darwin* | rhapsody*) # PIC is the default on this platform # Common symbols not allowed in MH_DYLIB files lt_prog_compiler_pic_GCJ='-fno-common' ;; 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 ;; sysv4*MP*) if test -d /usr/nec; then lt_prog_compiler_pic_GCJ=-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_GCJ='-fPIC' ;; esac ;; *) 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 ;; mingw* | 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_GCJ='-DDLL_EXPORT' ;; 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' ;; irix5* | irix6* | nonstopux*) lt_prog_compiler_wl_GCJ='-Wl,' # PIC (with -KPIC) is the default. lt_prog_compiler_static_GCJ='-non_shared' ;; newsos6) lt_prog_compiler_pic_GCJ='-KPIC' lt_prog_compiler_static_GCJ='-Bstatic' ;; linux*) case $CC in icc* | ecc*) lt_prog_compiler_wl_GCJ='-Wl,' lt_prog_compiler_pic_GCJ='-KPIC' lt_prog_compiler_static_GCJ='-static' ;; ccc*) lt_prog_compiler_wl_GCJ='-Wl,' # All Alpha code is PIC. lt_prog_compiler_static_GCJ='-non_shared' ;; esac ;; osf3* | osf4* | osf5*) lt_prog_compiler_wl_GCJ='-Wl,' # All OSF/1 code is PIC. lt_prog_compiler_static_GCJ='-non_shared' ;; sco3.2v5*) lt_prog_compiler_pic_GCJ='-Kpic' lt_prog_compiler_static_GCJ='-dn' ;; solaris*) lt_prog_compiler_wl_GCJ='-Wl,' lt_prog_compiler_pic_GCJ='-KPIC' lt_prog_compiler_static_GCJ='-Bstatic' ;; sunos4*) lt_prog_compiler_wl_GCJ='-Qoption ld ' lt_prog_compiler_pic_GCJ='-PIC' lt_prog_compiler_static_GCJ='-Bstatic' ;; sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) lt_prog_compiler_wl_GCJ='-Wl,' lt_prog_compiler_pic_GCJ='-KPIC' lt_prog_compiler_static_GCJ='-Bstatic' ;; sysv4*MP*) if test -d /usr/nec ;then lt_prog_compiler_pic_GCJ='-Kconform_pic' lt_prog_compiler_static_GCJ='-Bstatic' fi ;; uts4*) lt_prog_compiler_pic_GCJ='-pic' lt_prog_compiler_static_GCJ='-Bstatic' ;; *) lt_prog_compiler_can_build_shared_GCJ=no ;; esac fi echo "$as_me:$LINENO: result: $lt_prog_compiler_pic_GCJ" >&5 echo "${ECHO_T}$lt_prog_compiler_pic_GCJ" >&6 # # Check to make sure the PIC flag actually works. # if test -n "$lt_prog_compiler_pic_GCJ"; then echo "$as_me:$LINENO: checking if $compiler PIC flag $lt_prog_compiler_pic_GCJ works" >&5 echo $ECHO_N "checking if $compiler PIC flag $lt_prog_compiler_pic_GCJ works... $ECHO_C" >&6 if test "${lt_prog_compiler_pic_works_GCJ+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_prog_compiler_pic_works_GCJ=no ac_outfile=conftest.$ac_objext printf "$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}? :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:15655: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 echo "$as_me:15659: \$? = $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 if test ! -s conftest.err; then lt_prog_compiler_pic_works_GCJ=yes fi fi $rm conftest* fi echo "$as_me:$LINENO: result: $lt_prog_compiler_pic_works_GCJ" >&5 echo "${ECHO_T}$lt_prog_compiler_pic_works_GCJ" >&6 if test x"$lt_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 echo "$as_me:$LINENO: checking if $compiler supports -c -o file.$ac_objext" >&5 echo $ECHO_N "checking if $compiler supports -c -o file.$ac_objext... $ECHO_C" >&6 if test "${lt_cv_prog_compiler_c_o_GCJ+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_prog_compiler_c_o_GCJ=no $rm -r conftest 2>/dev/null mkdir conftest cd conftest mkdir out printf "$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}? :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:15715: $lt_compile\"" >&5) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&5 echo "$as_me:15719: \$? = $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 if test ! -s out/conftest.err; then lt_cv_prog_compiler_c_o_GCJ=yes fi fi chmod u+w . $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 echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_c_o_GCJ" >&5 echo "${ECHO_T}$lt_cv_prog_compiler_c_o_GCJ" >&6 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 echo "$as_me:$LINENO: checking if we can lock with hard links" >&5 echo $ECHO_N "checking if we can lock with hard links... $ECHO_C" >&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 echo "$as_me:$LINENO: result: $hard_links" >&5 echo "${ECHO_T}$hard_links" >&6 if test "$hard_links" = no; then { echo "$as_me:$LINENO: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5 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 echo "$as_me:$LINENO: checking whether the $compiler linker ($LD) supports shared libraries" >&5 echo $ECHO_N "checking whether the $compiler linker ($LD) supports shared libraries... $ECHO_C" >&6 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_" # 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. extract_expsyms_cmds= 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 ;; 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}' # See if GNU ld supports shared libraries. case $host_os in aix3* | aix4* | aix5*) # On AIX/PPC, the GNU linker is very broken if test "$host_cpu" != ia64; then ld_shlibs_GCJ=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_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 ;; 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 ;; 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 '\''/^[BCDGS] /s/.* \([^ ]*\)/\1 DATA/'\'' | $SED -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}--image-base=0x10000000 ${wl}--out-implib,$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}--image-base=0x10000000 ${wl}--out-implib,$lib' else ld_shlibs=no fi ;; netbsd* | netbsdelf*-gnu | knetbsd*-gnu) 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* | sysv5*) 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 ;; 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 ;; linux*) if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then tmp_archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' archive_cmds_GCJ="$tmp_archive_cmds" 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 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 -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' else archive_expsym_cmds_GCJ="$tmp_archive_cmds" fi link_all_deplibs_GCJ=no else ld_shlibs_GCJ=no fi ;; *) 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" = yes; then 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 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 "$link_static_flag"; then # Neither direct hardcoding nor static linking is supported with a # broken collect2. hardcode_direct_GCJ=unsupported fi ;; aix4* | aix5*) 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].*|aix5*) 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 hardcode_direct_GCJ=yes 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' 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 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 (eval $ac_link) 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; } && { ac_try='test -s conftest$ac_exeext' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } }'` # 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 '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } }'`; fi else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi rm -f conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi hardcode_libdir_flag_spec_GCJ='${wl}-blibpath:$libdir:'"$aix_libpath" archive_expsym_cmds_GCJ="\$CC"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$no_entry_flag \${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 $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$no_entry_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. */ int main () { ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 (eval $ac_link) 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; } && { ac_try='test -s conftest$ac_exeext' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } }'` # 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 '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } }'`; fi else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi rm -f conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi 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' # -bexpall does not export symbols beginning with underscore (_) always_export_symbols_GCJ=yes # Exported symbols can be pulled into shared objects from archives whole_archive_flag_spec_GCJ=' ' archive_cmds_need_lc_GCJ=yes # This is similar to how AIX traditionally builds it's shared libraries. archive_expsym_cmds_GCJ="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}-bE:$export_symbols ${wl}-bnoentry${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' 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 ;; bsdi4*) export_dynamic_flag_spec_GCJ=-rdynamic ;; 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='`cygpath -w "$srcfile"`' enable_shared_with_static_runtimes_GCJ=yes ;; darwin* | rhapsody*) if test "$GXX" = yes ; then archive_cmds_need_lc_GCJ=no case "$host_os" in rhapsody* | darwin1.[012]) allow_undefined_flag_GCJ='-undefined suppress' ;; *) # Darwin 1.3 on if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then allow_undefined_flag_GCJ='-flat_namespace -undefined suppress' else case ${MACOSX_DEPLOYMENT_TARGET} in 10.[012]) allow_undefined_flag_GCJ='-flat_namespace -undefined suppress' ;; 10.*) allow_undefined_flag_GCJ='-undefined dynamic_lookup' ;; esac fi ;; esac lt_int_apple_cc_single_mod=no output_verbose_link_cmd='echo' if $CC -dumpspecs 2>&1 | grep 'single_module' >/dev/null ; then lt_int_apple_cc_single_mod=yes fi if test "X$lt_int_apple_cc_single_mod" = Xyes ; then archive_cmds_GCJ='$CC -dynamiclib -single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring' else archive_cmds_GCJ='$CC -r ${wl}-bind_at_load -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' fi module_cmds_GCJ='$CC ${wl}-bind_at_load $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 ld's if test "X$lt_int_apple_cc_single_mod" = Xyes ; then archive_expsym_cmds_GCJ='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -dynamiclib -single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' else archive_expsym_cmds_GCJ='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -r ${wl}-bind_at_load -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~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' fi 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}' hardcode_direct_GCJ=no hardcode_automatic_GCJ=yes hardcode_shlibpath_var_GCJ=unsupported whole_archive_flag_spec_GCJ='-all_load $convenience' link_all_deplibs_GCJ=yes else ld_shlibs_GCJ=no fi ;; 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 ;; freebsd1*) ld_shlibs_GCJ=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_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 ;; # 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 ;; # FreeBSD 3 and greater uses gcc -shared to do shared libraries. freebsd* | kfreebsd*-gnu) 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 ;; 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 # 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' ;; hpux10* | hpux11*) if test "$GCC" = yes -a "$with_gnu_ld" = no; then case "$host_cpu" in hppa*64*|ia64*) archive_cmds_GCJ='$CC -shared ${wl}+h ${wl}$soname -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*|ia64*) archive_cmds_GCJ='$LD -b +h $soname -o $lib $libobjs $deplibs $linker_flags' ;; *) archive_cmds_GCJ='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' ;; esac fi if test "$with_gnu_ld" = no; then case "$host_cpu" in hppa*64*) hardcode_libdir_flag_spec_GCJ='${wl}+b ${wl}$libdir' hardcode_libdir_flag_spec_ld_GCJ='+b $libdir' hardcode_libdir_separator_GCJ=: hardcode_direct_GCJ=no hardcode_shlibpath_var_GCJ=no ;; ia64*) hardcode_libdir_flag_spec_GCJ='-L$libdir' hardcode_direct_GCJ=no hardcode_shlibpath_var_GCJ=no # hardcode_minus_L: Not really in the search PATH, # but as the default location of the library. hardcode_minus_L_GCJ=yes ;; *) hardcode_libdir_flag_spec_GCJ='${wl}+b ${wl}$libdir' hardcode_libdir_separator_GCJ=: hardcode_direct_GCJ=yes export_dynamic_flag_spec_GCJ='${wl}-E' # hardcode_minus_L: Not really in the search PATH, # but as the default location of the library. hardcode_minus_L_GCJ=yes ;; esac fi ;; 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 ;; netbsd* | netbsdelf*-gnu | knetbsd*-gnu) 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 ;; 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*) 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' 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 ;; 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' ;; 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 ${objdir}/so_locations -o $lib~$rm $lib.exp' # Both c and cxx compiler support -rpath directly hardcode_libdir_flag_spec_GCJ='-rpath $libdir' fi hardcode_libdir_separator_GCJ=: ;; sco3.2v5*) archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_shlibpath_var_GCJ=no export_dynamic_flag_spec_GCJ='${wl}-Bexport' runpath_var=LD_RUN_PATH hardcode_runpath_var=yes ;; solaris*) no_undefined_flag_GCJ=' -z text' if test "$GCC" = yes; then 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 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].*) ;; *) # Supported since Solaris 2.6 (maybe 2.5.1?) whole_archive_flag_spec_GCJ='-z allextract$convenience -z defaultextract' ;; 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 ;; 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 ;; 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' ;; 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.2uw2*) archive_cmds_GCJ='$LD -G -o $lib $libobjs $deplibs $linker_flags' hardcode_direct_GCJ=yes hardcode_minus_L_GCJ=no hardcode_shlibpath_var_GCJ=no hardcode_runpath_var=yes runpath_var=LD_RUN_PATH ;; sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[78]* | unixware7*) no_undefined_flag_GCJ='${wl}-z ${wl}text' if test "$GCC" = yes; then archive_cmds_GCJ='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' else archive_cmds_GCJ='$CC -G ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' fi runpath_var='LD_RUN_PATH' hardcode_shlibpath_var_GCJ=no ;; sysv5*) no_undefined_flag_GCJ=' -z text' # $CC -shared without GNU ld will not create a library from C++ # object files and a static libstdc++, better avoid it by now 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' hardcode_libdir_flag_spec_GCJ= hardcode_shlibpath_var_GCJ=no runpath_var='LD_RUN_PATH' ;; 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 ;; *) ld_shlibs_GCJ=no ;; esac fi echo "$as_me:$LINENO: result: $ld_shlibs_GCJ" >&5 echo "${ECHO_T}$ld_shlibs_GCJ" >&6 test "$ld_shlibs_GCJ" = 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 # # 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. echo "$as_me:$LINENO: checking whether -lc should be explicitly linked in" >&5 echo $ECHO_N "checking whether -lc should be explicitly linked in... $ECHO_C" >&6 $rm conftest* printf "$lt_simple_compile_test_code" > conftest.$ac_ext if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? 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_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=$? 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* echo "$as_me:$LINENO: result: $archive_cmds_need_lc_GCJ" >&5 echo "${ECHO_T}$archive_cmds_need_lc_GCJ" >&6 ;; esac fi ;; esac echo "$as_me:$LINENO: checking dynamic linker characteristics" >&5 echo $ECHO_N "checking dynamic linker characteristics... $ECHO_C" >&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 "$GCC" = yes; then 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 ';' >/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. 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 else 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' ;; aix4* | aix5*) 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 ;; bsdi4*) 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' postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ dlpath=$dir/\$dldll~ $rm \$dlpath' shlibpath_overrides_runpath=yes 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 ;; 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)' # Apple's gcc prints 'gcc -print-search-dirs' doesn't operate the same. if test "$GCC" = yes; then sys_lib_search_path_spec=`$CC -print-search-dirs | tr "\n" "$PATH_SEPARATOR" | sed -e 's/libraries:/@libraries:/' | tr "@" "\n" | grep "^libraries:" | sed -e "s/^libraries://" -e "s,=/,/,g" -e "s,$PATH_SEPARATOR, ,g" -e "s,.*,& /lib /usr/lib /usr/local/lib,g"` else sys_lib_search_path_spec='/lib /usr/lib /usr/local/lib' 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 ;; kfreebsd*-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 shlibpath_overrides_runpath=no hardcode_into_libs=yes dynamic_linker='GNU ld.so' ;; freebsd*) objformat=`test -x /usr/bin/objformat && /usr/bin/objformat || echo aout` 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 ;; *) # from 3.2 on shlibpath_overrides_runpath=no 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' ;; 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 ;; # No shared lib support for Linux oldld, aout, or coff. linux*oldld* | linux*aout* | linux*coff*) dynamic_linker=no ;; # This must be Linux ELF. 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}' 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=`$SED -e 's/:,\t/ /g;s/=^=*$//;s/=^= * / /g' /etc/ld.so.conf | 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' ;; netbsdelf*-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 shlibpath_overrides_runpath=no hardcode_into_libs=yes dynamic_linker='NetBSD ld.elf_so' ;; knetbsd*-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 shlibpath_overrides_runpath=no hardcode_into_libs=yes dynamic_linker='GNU 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 ;; 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 ;; 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 need_lib_prefix=no need_version=yes 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" ;; sco3.2v5*) version_type=osf 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 ;; 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.2uw2* | sysv4.3* | sysv5*) 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 ;; 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 echo "$as_me:$LINENO: result: $dynamic_linker" >&5 echo "${ECHO_T}$dynamic_linker" >&6 test "$dynamic_linker" = no && can_build_shared=no echo "$as_me:$LINENO: checking how to hardcode library paths into programs" >&5 echo $ECHO_N "checking how to hardcode library paths into programs... $ECHO_C" >&6 hardcode_action_GCJ= if test -n "$hardcode_libdir_flag_spec_GCJ" || \ test -n "$runpath_var GCJ" || \ test "X$hardcode_automatic_GCJ"="Xyes" ; then # 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 # We cannot hardcode anything, or else we can only hardcode existing # directories. hardcode_action_GCJ=unsupported fi echo "$as_me:$LINENO: result: $hardcode_action_GCJ" >&5 echo "${ECHO_T}$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 striplib= old_striplib= echo "$as_me:$LINENO: checking whether stripping libraries is possible" >&5 echo $ECHO_N "checking whether stripping libraries is possible... $ECHO_C" >&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" echo "$as_me:$LINENO: result: yes" >&5 echo "${ECHO_T}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" echo "$as_me:$LINENO: result: yes" >&5 echo "${ECHO_T}yes" >&6 else echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6 fi ;; *) echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}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 echo "$as_me:$LINENO: checking for dlopen in -ldl" >&5 echo $ECHO_N "checking for dlopen in -ldl... $ECHO_C" >&6 if test "${ac_cv_lib_dl_dlopen+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&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 gcc2 internal prototype to avoid an error. */ #ifdef __cplusplus extern "C" #endif /* We use char because int might match the return type of a gcc2 builtin and then its argument prototype would still apply. */ char dlopen (); int main () { dlopen (); ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 (eval $ac_link) 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; } && { ac_try='test -s conftest$ac_exeext' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_lib_dl_dlopen=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_lib_dl_dlopen=no fi rm -f conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi echo "$as_me:$LINENO: result: $ac_cv_lib_dl_dlopen" >&5 echo "${ECHO_T}$ac_cv_lib_dl_dlopen" >&6 if test $ac_cv_lib_dl_dlopen = yes; then lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl" else lt_cv_dlopen="dyld" lt_cv_dlopen_libs= lt_cv_dlopen_self=yes fi ;; *) echo "$as_me:$LINENO: checking for shl_load" >&5 echo $ECHO_N "checking for shl_load... $ECHO_C" >&6 if test "${ac_cv_func_shl_load+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&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. */ #ifdef __STDC__ # include #else # include #endif #undef shl_load /* Override any gcc2 internal prototype to avoid an error. */ #ifdef __cplusplus extern "C" { #endif /* We use char because int might match the return type of a gcc2 builtin and then its argument prototype would still apply. */ 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 #else char (*f) () = shl_load; #endif #ifdef __cplusplus } #endif int main () { return f != shl_load; ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 (eval $ac_link) 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; } && { ac_try='test -s conftest$ac_exeext' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_func_shl_load=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_func_shl_load=no fi rm -f conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext fi echo "$as_me:$LINENO: result: $ac_cv_func_shl_load" >&5 echo "${ECHO_T}$ac_cv_func_shl_load" >&6 if test $ac_cv_func_shl_load = yes; then lt_cv_dlopen="shl_load" else echo "$as_me:$LINENO: checking for shl_load in -ldld" >&5 echo $ECHO_N "checking for shl_load in -ldld... $ECHO_C" >&6 if test "${ac_cv_lib_dld_shl_load+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&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 gcc2 internal prototype to avoid an error. */ #ifdef __cplusplus extern "C" #endif /* We use char because int might match the return type of a gcc2 builtin and then its argument prototype would still apply. */ char shl_load (); int main () { shl_load (); ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 (eval $ac_link) 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; } && { ac_try='test -s conftest$ac_exeext' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_lib_dld_shl_load=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_lib_dld_shl_load=no fi rm -f conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi echo "$as_me:$LINENO: result: $ac_cv_lib_dld_shl_load" >&5 echo "${ECHO_T}$ac_cv_lib_dld_shl_load" >&6 if test $ac_cv_lib_dld_shl_load = yes; then lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-dld" else echo "$as_me:$LINENO: checking for dlopen" >&5 echo $ECHO_N "checking for dlopen... $ECHO_C" >&6 if test "${ac_cv_func_dlopen+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&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 /* 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. */ #ifdef __STDC__ # include #else # include #endif #undef dlopen /* Override any gcc2 internal prototype to avoid an error. */ #ifdef __cplusplus extern "C" { #endif /* We use char because int might match the return type of a gcc2 builtin and then its argument prototype would still apply. */ 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 #else char (*f) () = dlopen; #endif #ifdef __cplusplus } #endif int main () { return f != dlopen; ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 (eval $ac_link) 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; } && { ac_try='test -s conftest$ac_exeext' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_func_dlopen=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_func_dlopen=no fi rm -f conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext fi echo "$as_me:$LINENO: result: $ac_cv_func_dlopen" >&5 echo "${ECHO_T}$ac_cv_func_dlopen" >&6 if test $ac_cv_func_dlopen = yes; then lt_cv_dlopen="dlopen" else echo "$as_me:$LINENO: checking for dlopen in -ldl" >&5 echo $ECHO_N "checking for dlopen in -ldl... $ECHO_C" >&6 if test "${ac_cv_lib_dl_dlopen+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&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 gcc2 internal prototype to avoid an error. */ #ifdef __cplusplus extern "C" #endif /* We use char because int might match the return type of a gcc2 builtin and then its argument prototype would still apply. */ char dlopen (); int main () { dlopen (); ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 (eval $ac_link) 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; } && { ac_try='test -s conftest$ac_exeext' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_lib_dl_dlopen=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_lib_dl_dlopen=no fi rm -f conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi echo "$as_me:$LINENO: result: $ac_cv_lib_dl_dlopen" >&5 echo "${ECHO_T}$ac_cv_lib_dl_dlopen" >&6 if test $ac_cv_lib_dl_dlopen = yes; then lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl" else echo "$as_me:$LINENO: checking for dlopen in -lsvld" >&5 echo $ECHO_N "checking for dlopen in -lsvld... $ECHO_C" >&6 if test "${ac_cv_lib_svld_dlopen+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&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 gcc2 internal prototype to avoid an error. */ #ifdef __cplusplus extern "C" #endif /* We use char because int might match the return type of a gcc2 builtin and then its argument prototype would still apply. */ char dlopen (); int main () { dlopen (); ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 (eval $ac_link) 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; } && { ac_try='test -s conftest$ac_exeext' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_lib_svld_dlopen=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_lib_svld_dlopen=no fi rm -f conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi echo "$as_me:$LINENO: result: $ac_cv_lib_svld_dlopen" >&5 echo "${ECHO_T}$ac_cv_lib_svld_dlopen" >&6 if test $ac_cv_lib_svld_dlopen = yes; then lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld" else echo "$as_me:$LINENO: checking for dld_link in -ldld" >&5 echo $ECHO_N "checking for dld_link in -ldld... $ECHO_C" >&6 if test "${ac_cv_lib_dld_dld_link+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&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 gcc2 internal prototype to avoid an error. */ #ifdef __cplusplus extern "C" #endif /* We use char because int might match the return type of a gcc2 builtin and then its argument prototype would still apply. */ char dld_link (); int main () { dld_link (); ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 (eval $ac_link) 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; } && { ac_try='test -s conftest$ac_exeext' { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 (eval $ac_try) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_lib_dld_dld_link=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_lib_dld_dld_link=no fi rm -f conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi echo "$as_me:$LINENO: result: $ac_cv_lib_dld_dld_link" >&5 echo "${ECHO_T}$ac_cv_lib_dld_dld_link" >&6 if test $ac_cv_lib_dld_dld_link = yes; then lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-dld" fi 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" eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" save_LIBS="$LIBS" LIBS="$lt_cv_dlopen_libs $LIBS" echo "$as_me:$LINENO: checking whether a program can dlopen itself" >&5 echo $ECHO_N "checking whether a program can dlopen itself... $ECHO_C" >&6 if test "${lt_cv_dlopen_self+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&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 < #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); */ } exit (status); } EOF if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && test -s conftest${ac_exeext} 2>/dev/null; then (./conftest; exit; ) 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_unknown|x*) lt_cv_dlopen_self=no ;; esac else : # compilation failed lt_cv_dlopen_self=no fi fi rm -fr conftest* fi echo "$as_me:$LINENO: result: $lt_cv_dlopen_self" >&5 echo "${ECHO_T}$lt_cv_dlopen_self" >&6 if test "x$lt_cv_dlopen_self" = xyes; then LDFLAGS="$LDFLAGS $link_static_flag" echo "$as_me:$LINENO: checking whether a statically linked program can dlopen itself" >&5 echo $ECHO_N "checking whether a statically linked program can dlopen itself... $ECHO_C" >&6 if test "${lt_cv_dlopen_self_static+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&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); */ } exit (status); } EOF if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && test -s conftest${ac_exeext} 2>/dev/null; then (./conftest; exit; ) 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_unknown|x*) lt_cv_dlopen_self_static=no ;; esac else : # compilation failed lt_cv_dlopen_self_static=no fi fi rm -fr conftest* fi echo "$as_me:$LINENO: result: $lt_cv_dlopen_self_static" >&5 echo "${ECHO_T}$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 # 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 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 \ 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 \ 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 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_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 # Whether or not to optimize for fast installation. fast_install=$enable_fast_install # The host system. host_alias=$host_alias host=$host # 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 # A language-specific compiler. CC=$lt_compiler_GCJ # 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 # 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_GCJ # 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_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 # 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_GCJ # Compiler flag to turn off builtin functions. no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag_GCJ # Compiler flag to allow reflexive dlopens. export_dynamic_flag_spec=$lt_export_dynamic_flag_spec_GCJ # Compiler flag to generate shared objects directly from archives. whole_archive_flag_spec=$lt_whole_archive_flag_spec_GCJ # Compiler flag to generate thread-safe objects. thread_safe_flag_spec=$lt_thread_safe_flag_spec_GCJ # 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_GCJ 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_GCJ # 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 # 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 # 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 # 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_GCJ # Dependencies to place after the objects being linked to create a # shared library. postdep_objects=$lt_postdep_objects_GCJ # Dependencies to place before the objects being linked to create a # shared library. predeps=$lt_predeps_GCJ # Dependencies to place after the objects being linked to create a # shared library. postdeps=$lt_postdeps_GCJ # The library search path used internally by the compiler when linking # a shared library. compiler_lib_search_path=$lt_compiler_lib_search_path_GCJ # 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_GCJ # Flag that forces no undefined symbols. no_undefined_flag=$lt_no_undefined_flag_GCJ # 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_GCJ # 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_GCJ # 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 # Whether we need a single -rpath flag with a separated argument. hardcode_libdir_separator=$lt_hardcode_libdir_separator_GCJ # Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the # resulting binary. hardcode_direct=$hardcode_direct_GCJ # Set to yes if using the -LDIR flag during linking hardcodes DIR into the # resulting binary. hardcode_minus_L=$hardcode_minus_L_GCJ # 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" # Whether libtool must link a program against all its dependency libraries. link_all_deplibs=$link_all_deplibs_GCJ # 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="$fix_srcfile_path_GCJ" # Set to yes if exported symbols are required. always_export_symbols=$always_export_symbols_GCJ # 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 __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 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" else tagname="" fi ;; RC) # Source file extension for RC test sources. ac_ext=rc # Object file extension for compiled RC test sources. objext=o objext_RC=$objext # Code to be used in simple compile tests lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }\n' # 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. # If no C compiler was specified, use CC. LTCC=${LTCC-"$CC"} # Allow CC to be a program name with arguments. compiler=$CC # Allow CC to be a program name with arguments. lt_save_CC="$CC" CC=${RC-"windres"} compiler=$CC compiler_RC=$CC 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 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 \ 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 \ 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 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_RC # 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 # The host system. host_alias=$host_alias host=$host # 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 # A language-specific compiler. CC=$lt_compiler_RC # Is the compiler the GNU C compiler? with_gcc=$GCC_RC # An ERE matcher. EGREP=$lt_EGREP # The linker used to build libraries. LD=$lt_LD_RC # 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_RC # 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_RC 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_RC # 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_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 # 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_RC 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_RC # 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 # 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 # 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 # 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_RC # 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 # Dependencies to place after the objects being linked to create a # shared library. postdeps=$lt_postdeps_RC # The library search path used internally by the compiler when linking # a shared library. compiler_lib_search_path=$lt_compiler_lib_search_path_RC # 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_RC # 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 # 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_RC # 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_RC # 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 # Whether we need a single -rpath flag with a separated argument. hardcode_libdir_separator=$lt_hardcode_libdir_separator_RC # Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the # resulting binary. hardcode_direct=$hardcode_direct_RC # 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 # 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 # 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 # 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="$fix_srcfile_path_RC" # 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 # 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_RC # Symbols that must always be exported. include_expsyms=$lt_include_expsyms_RC # ### 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 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" ;; *) { { echo "$as_me:$LINENO: error: Unsupported tag name: $tagname" >&5 echo "$as_me: error: Unsupported tag name: $tagname" >&2;} { (exit 1); exit 1; }; } ;; esac # 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" # 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" { { echo "$as_me:$LINENO: error: unable to update list of available tagged configurations." >&5 echo "$as_me: error: unable to update list of available tagged configurations." >&2;} { (exit 1); exit 1; }; } fi fi # 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' # Prevent multiple expansion 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 echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 if test "${ac_cv_prog_RANLIB+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&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 $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done fi fi RANLIB=$ac_cv_prog_RANLIB if test -n "$RANLIB"; then echo "$as_me:$LINENO: result: $RANLIB" >&5 echo "${ECHO_T}$RANLIB" >&6 else echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6 fi 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 echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&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 $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_RANLIB="ranlib" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done test -z "$ac_cv_prog_ac_ct_RANLIB" && ac_cv_prog_ac_ct_RANLIB=":" fi fi ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB if test -n "$ac_ct_RANLIB"; then echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5 echo "${ECHO_T}$ac_ct_RANLIB" >&6 else echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6 fi RANLIB=$ac_ct_RANLIB else RANLIB="$ac_cv_prog_RANLIB" fi # Find a good install program. We prefer a C program (faster), # so one script is as good as another. But avoid the broken or # incompatible versions: # SysV /etc/install, /usr/sbin/install # SunOS /usr/etc/install # IRIX /sbin/install # AIX /bin/install # AmigaOS /C/install, which installs bootblocks on floppy discs # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag # AFS /usr/afsws/bin/install, which mishandles nonexistent args # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" # OS/2's system install, which has a completely different semantic # ./install, which can be erroneously created by make from ./install.sh. echo "$as_me:$LINENO: checking for a BSD-compatible install" >&5 echo $ECHO_N "checking for a BSD-compatible install... $ECHO_C" >&6 if test -z "$INSTALL"; then if test "${ac_cv_path_install+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. # Account for people who put trailing slashes in PATH elements. case $as_dir/ in ./ | .// | /cC/* | \ /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \ ?:\\/os2\\/install\\/* | ?:\\/OS2\\/INSTALL\\/* | \ /usr/ucb/* ) ;; *) # OSF1 and SCO ODT 3.0 have their own names for install. # Don't use installbsd from OSF since it installs stuff as root # by default. for ac_prog in ginstall scoinst install; do for ac_exec_ext in '' $ac_executable_extensions; do if $as_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then if test $ac_prog = install && grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then # AIX install. It has an incompatible calling convention. : elif test $ac_prog = install && grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then # program-specific install script used by HP pwplus--don't use. : else ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c" break 3 fi fi done done ;; esac done fi if test "${ac_cv_path_install+set}" = set; then INSTALL=$ac_cv_path_install else # As a last resort, use the slow shell script. We don't cache a # path for INSTALL within a source directory, because that will # break other packages using the cache if that directory is # removed, or if the path is relative. INSTALL=$ac_install_sh fi fi echo "$as_me:$LINENO: result: $INSTALL" >&5 echo "${ECHO_T}$INSTALL" >&6 # Use test -z because SunOS4 sh mishandles braces in ${var-val}. # It thinks the first close brace ends the variable substitution. test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}' test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' echo "$as_me:$LINENO: checking whether ln -s works" >&5 echo $ECHO_N "checking whether ln -s works... $ECHO_C" >&6 LN_S=$as_ln_s if test "$LN_S" = "ln -s"; then echo "$as_me:$LINENO: result: yes" >&5 echo "${ECHO_T}yes" >&6 else echo "$as_me:$LINENO: result: no, using $LN_S" >&5 echo "${ECHO_T}no, using $LN_S" >&6 fi echo "$as_me:$LINENO: checking whether to enable maintainer-specific portions of Makefiles" >&5 echo $ECHO_N "checking whether to enable maintainer-specific portions of Makefiles... $ECHO_C" >&6 # Check whether --enable-maintainer-mode or --disable-maintainer-mode was given. if test "${enable_maintainer_mode+set}" = set; then enableval="$enable_maintainer_mode" USE_MAINTAINER_MODE=$enableval else USE_MAINTAINER_MODE=no fi; echo "$as_me:$LINENO: result: $USE_MAINTAINER_MODE" >&5 echo "${ECHO_T}$USE_MAINTAINER_MODE" >&6 if test $USE_MAINTAINER_MODE = yes; then MAINTAINER_MODE_TRUE= MAINTAINER_MODE_FALSE='#' else MAINTAINER_MODE_TRUE='#' MAINTAINER_MODE_FALSE= fi MAINT=$MAINTAINER_MODE_TRUE # Add the stamp file to the list of files AC keeps track of, # along with our hook. ac_config_headers="$ac_config_headers include/apreq_config.h" # Check whether --enable-profile or --disable-profile was given. if test "${enable_profile+set}" = set; then enableval="$enable_profile" PROFILE=$enableval else PROFILE="no" fi; # Check whether --enable-perl_glue or --disable-perl_glue was given. if test "${enable_perl_glue+set}" = set; then enableval="$enable_perl_glue" PERL_GLUE=$enableval else PERL_GLUE="no" fi; # Check whether --with-perl or --without-perl was given. if test "${with_perl+set}" = set; then withval="$with_perl" PERL=$withval else PERL="perl" fi; # Check whether --with-apache2-apxs or --without-apache2-apxs was given. if test "${with_apache2_apxs+set}" = set; then withval="$with_apache2_apxs" APACHE2_APXS=$withval else APACHE2_APXS="apxs" fi; # Check whether --with-apache2-src or --without-apache2-src was given. if test "${with_apache2_src+set}" = set; then withval="$with_apache2_src" APACHE2_SRC=$withval else APACHE2_SRC="" fi; # Check whether --with-apache2-httpd or --without-apache2-httpd was given. if test "${with_apache2_httpd+set}" = set; then withval="$with_apache2_httpd" APACHE2_HTTPD=$withval else APACHE2_HTTPD="" fi; # Check whether --with-apr-config or --without-apr-config was given. if test "${with_apr_config+set}" = set; then withval="$with_apr_config" APR_CONFIG=$withval else APR_CONFIG="" fi; # Check whether --with-apu-config or --without-apu-config was given. if test "${with_apu_config+set}" = set; then withval="$with_apu_config" APU_CONFIG=$withval else APU_CONFIG="" fi; # Check whether --with-apache1-apxs or --without-apache1-apxs was given. if test "${with_apache1_apxs+set}" = set; then withval="$with_apache1_apxs" APACHE1_APXS=$withval else APACHE1_APXS="" fi; # Check whether --with-perl-opts or --without-perl-opts was given. if test "${with_perl_opts+set}" = set; then withval="$with_perl_opts" PERL_OPTS=$withval else PERL_OPTS="" fi; # Check whether --with-expat or --without-expat was given. if test "${with_expat+set}" = set; then withval="$with_expat" EXPAT_DIR=$withval else EXPAT_DIR="" fi; prereq_check="$PERL build/version_check.pl" if test -n "$APACHE2_SRC"; then # no apxs: must compile httpd from source APACHE2_SRC=`cd $APACHE2_SRC;pwd` as_ac_File=`echo "ac_cv_file_$APACHE2_SRC/include/httpd.h" | $as_tr_sh` echo "$as_me:$LINENO: checking for $APACHE2_SRC/include/httpd.h" >&5 echo $ECHO_N "checking for $APACHE2_SRC/include/httpd.h... $ECHO_C" >&6 if eval "test \"\${$as_ac_File+set}\" = set"; then echo $ECHO_N "(cached) $ECHO_C" >&6 else test "$cross_compiling" = yes && { { echo "$as_me:$LINENO: error: cannot check for file existence when cross compiling" >&5 echo "$as_me: error: cannot check for file existence when cross compiling" >&2;} { (exit 1); exit 1; }; } if test -r "$APACHE2_SRC/include/httpd.h"; then eval "$as_ac_File=yes" else eval "$as_ac_File=no" fi fi echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_File'}'`" >&5 echo "${ECHO_T}`eval echo '${'$as_ac_File'}'`" >&6 if test `eval echo '${'$as_ac_File'}'` = yes; then : else { { echo "$as_me:$LINENO: error: invalid Apache2 source directory" >&5 echo "$as_me: error: invalid Apache2 source directory" >&2;} { (exit 1); exit 1; }; } fi APACHE2_INCLUDES=-I$APACHE2_SRC/include if test -z "$APR_CONFIG"; then APR_CONFIG="$APACHE2_SRC/srclib/apr/apr-config" fi if test -z "$APU_CONFIG"; then APU_CONFIG="$APACHE2_SRC/srclib/apr-util/apu-config" fi APACHE2_HTTPD=$APACHE2_SRC/httpd else # have apxs: use it APACHE2_INCLUDES=-I`$APACHE2_APXS -q INCLUDEDIR` APR_MAJOR_VERSION=`$APACHE2_APXS -q APR_VERSION 2>/dev/null | cut -d. -f 1` if test ${APR_MAJOR_VERSION:="0"} -eq 0; then apr_config=apr-config apu_config=apu-config apreq_libs="-lapr -laprutil" else apr_config=apr-$APR_MAJOR_VERSION-config apu_config=apu-$APR_MAJOR_VERSION-config apreq_libs="-lapr-$APR_MAJOR_VERSION -laprutil-$APR_MAJOR_VERSION" fi if test -z "$APR_CONFIG"; then APR_CONFIG=`$APACHE2_APXS -q APR_BINDIR`/$apr_config fi if test -z "$APU_CONFIG"; then APU_CONFIG=`$APACHE2_APXS -q APU_BINDIR`/$apu_config fi if test -z "$APACHE2_HTTPD"; then APACHE2_HTTPD=`$APACHE2_APXS -q SBINDIR`/`$APACHE2_APXS -q progname` fi if test -z "`$prereq_check apache2 $APACHE2_HTTPD`"; then { { echo "$as_me:$LINENO: error: Bad apache2 binary ($APACHE2_HTTPD)" >&5 echo "$as_me: error: Bad apache2 binary ($APACHE2_HTTPD)" >&2;} { (exit 1); exit 1; }; } fi fi as_ac_File=`echo "ac_cv_file_$APR_CONFIG" | $as_tr_sh` echo "$as_me:$LINENO: checking for $APR_CONFIG" >&5 echo $ECHO_N "checking for $APR_CONFIG... $ECHO_C" >&6 if eval "test \"\${$as_ac_File+set}\" = set"; then echo $ECHO_N "(cached) $ECHO_C" >&6 else test "$cross_compiling" = yes && { { echo "$as_me:$LINENO: error: cannot check for file existence when cross compiling" >&5 echo "$as_me: error: cannot check for file existence when cross compiling" >&2;} { (exit 1); exit 1; }; } if test -r "$APR_CONFIG"; then eval "$as_ac_File=yes" else eval "$as_ac_File=no" fi fi echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_File'}'`" >&5 echo "${ECHO_T}`eval echo '${'$as_ac_File'}'`" >&6 if test `eval echo '${'$as_ac_File'}'` = yes; then : else { { echo "$as_me:$LINENO: error: invalid apr-config location ($APR_CONFIG)- did you forget to configure apr?" >&5 echo "$as_me: error: invalid apr-config location ($APR_CONFIG)- did you forget to configure apr?" >&2;} { (exit 1); exit 1; }; } fi if test -z "`$prereq_check apr $APR_CONFIG`"; then { { echo "$as_me:$LINENO: error: Bad libapr version" >&5 echo "$as_me: error: Bad libapr version" >&2;} { (exit 1); exit 1; }; } fi as_ac_File=`echo "ac_cv_file_$APU_CONFIG" | $as_tr_sh` echo "$as_me:$LINENO: checking for $APU_CONFIG" >&5 echo $ECHO_N "checking for $APU_CONFIG... $ECHO_C" >&6 if eval "test \"\${$as_ac_File+set}\" = set"; then echo $ECHO_N "(cached) $ECHO_C" >&6 else test "$cross_compiling" = yes && { { echo "$as_me:$LINENO: error: cannot check for file existence when cross compiling" >&5 echo "$as_me: error: cannot check for file existence when cross compiling" >&2;} { (exit 1); exit 1; }; } if test -r "$APU_CONFIG"; then eval "$as_ac_File=yes" else eval "$as_ac_File=no" fi fi echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_File'}'`" >&5 echo "${ECHO_T}`eval echo '${'$as_ac_File'}'`" >&6 if test `eval echo '${'$as_ac_File'}'` = yes; then : else { { echo "$as_me:$LINENO: error: invalid apu-config location ($APU_CONFIG)- did you forget to configure apr-util?" >&5 echo "$as_me: error: invalid apu-config location ($APU_CONFIG)- did you forget to configure apr-util?" >&2;} { (exit 1); exit 1; }; } fi if test -z "`$prereq_check apu $APU_CONFIG`"; then { { echo "$as_me:$LINENO: error: Bad libaprutil version" >&5 echo "$as_me: error: Bad libaprutil version" >&2;} { (exit 1); exit 1; }; } fi if test "x$PERL_GLUE" != "xno"; then echo "$as_me:$LINENO: checking for perl" >&5 echo $ECHO_N "checking for perl... $ECHO_C" >&6 if test -z "`$prereq_check perl $PERL`"; then { { echo "$as_me:$LINENO: error: Bad perl version" >&5 echo "$as_me: error: Bad perl version" >&2;} { (exit 1); exit 1; }; } fi echo "$as_me:$LINENO: result: $PERL" >&5 echo "${ECHO_T}$PERL" >&6 echo "$as_me:$LINENO: checking for ExtUtils::XSBuilder" >&5 echo $ECHO_N "checking for ExtUtils::XSBuilder... $ECHO_C" >&6 if test -z "`$prereq_check ExtUtils::XSBuilder`"; then { echo "$as_me:$LINENO: WARNING: Bad ExtUtils::XSBuilder version" >&5 echo "$as_me: WARNING: Bad ExtUtils::XSBuilder version" >&2;} fi echo "$as_me:$LINENO: result: yes" >&5 echo "${ECHO_T}yes" >&6 echo "$as_me:$LINENO: checking for mod_perl" >&5 echo $ECHO_N "checking for mod_perl... $ECHO_C" >&6 if test -z "`$prereq_check mod_perl`"; then { echo "$as_me:$LINENO: WARNING: Bad mod_perl version" >&5 echo "$as_me: WARNING: Bad mod_perl version" >&2;} fi echo "$as_me:$LINENO: result: yes" >&5 echo "${ECHO_T}yes" >&6 echo "$as_me:$LINENO: checking for Apache::Test" >&5 echo $ECHO_N "checking for Apache::Test... $ECHO_C" >&6 if test -z "`$prereq_check Apache::Test`"; then { echo "$as_me:$LINENO: WARNING: Bad Apache::Test version" >&5 echo "$as_me: WARNING: Bad Apache::Test version" >&2;} fi echo "$as_me:$LINENO: result: yes" >&5 echo "${ECHO_T}yes" >&6 echo "$as_me:$LINENO: checking for ExtUtils::MakeMaker" >&5 echo $ECHO_N "checking for ExtUtils::MakeMaker... $ECHO_C" >&6 if test -z "`$prereq_check ExtUtils::MakeMaker`"; then { echo "$as_me:$LINENO: WARNING: Bad ExtUtils::MakeMaker version" >&5 echo "$as_me: WARNING: Bad ExtUtils::MakeMaker version" >&2;} fi echo "$as_me:$LINENO: result: yes" >&5 echo "${ECHO_T}yes" >&6 fi if test "x$PROFILE" != "xno"; then ENABLE_PROFILE_TRUE= ENABLE_PROFILE_FALSE='#' else ENABLE_PROFILE_TRUE='#' ENABLE_PROFILE_FALSE= fi if test "x$PERL_GLUE" != "xno"; then BUILD_PERL_GLUE_TRUE= BUILD_PERL_GLUE_FALSE='#' else BUILD_PERL_GLUE_TRUE='#' BUILD_PERL_GLUE_FALSE= fi if test -n "`$prereq_check Apache::Test`"; then HAVE_APACHE_TEST_TRUE= HAVE_APACHE_TEST_FALSE='#' else HAVE_APACHE_TEST_TRUE='#' HAVE_APACHE_TEST_FALSE= fi if test -n "$APACHE2_SRC"; then BUILD_HTTPD_TRUE= BUILD_HTTPD_FALSE='#' else BUILD_HTTPD_TRUE='#' BUILD_HTTPD_FALSE= fi if test "x$APR_CONFIG" = x`$APR_CONFIG --srcdir`/apr-config; then BUILD_APR_TRUE= BUILD_APR_FALSE='#' else BUILD_APR_TRUE='#' BUILD_APR_FALSE= fi if test "x$APU_CONFIG" = x`$APU_CONFIG --srcdir`/apu-config; then BUILD_APU_TRUE= BUILD_APU_FALSE='#' else BUILD_APU_TRUE='#' BUILD_APU_FALSE= fi if test -n "$APACHE1_APXS"; then HAVE_APACHE1_TRUE= HAVE_APACHE1_FALSE='#' else HAVE_APACHE1_TRUE='#' HAVE_APACHE1_FALSE= fi ac_default_prefix="`$APU_CONFIG --prefix`" if test "x$APR_INCLUDES" = "x"; then echo " setting APR_INCLUDES to \""`$APR_CONFIG --includes`"\"" APR_INCLUDES=""`$APR_CONFIG --includes`"" else apr_addto_bugger=""`$APR_CONFIG --includes`"" for i in $apr_addto_bugger; do apr_addto_duplicate="0" for j in $APR_INCLUDES; do if test "x$i" = "x$j"; then apr_addto_duplicate="1" break fi done if test $apr_addto_duplicate = "0"; then echo " adding \"$i\" to APR_INCLUDES" APR_INCLUDES="$APR_INCLUDES $i" fi done fi if test "x$APR_INCLUDES" = "x"; then echo " setting APR_INCLUDES to \""`$APU_CONFIG --includes`"\"" APR_INCLUDES=""`$APU_CONFIG --includes`"" else apr_addto_bugger=""`$APU_CONFIG --includes`"" for i in $apr_addto_bugger; do apr_addto_duplicate="0" for j in $APR_INCLUDES; do if test "x$i" = "x$j"; then apr_addto_duplicate="1" break fi done if test $apr_addto_duplicate = "0"; then echo " adding \"$i\" to APR_INCLUDES" APR_INCLUDES="$APR_INCLUDES $i" fi done fi APR_LA="`$APR_CONFIG --apr-la-file`" APU_LA="`$APU_CONFIG --apu-la-file`" if test "x$APR_LTFLAGS" = "x"; then echo " setting APR_LTFLAGS to \""`$APR_CONFIG --link-libtool`"\"" APR_LTFLAGS=""`$APR_CONFIG --link-libtool`"" else apr_addto_bugger=""`$APR_CONFIG --link-libtool`"" for i in $apr_addto_bugger; do apr_addto_duplicate="0" for j in $APR_LTFLAGS; do if test "x$i" = "x$j"; then apr_addto_duplicate="1" break fi done if test $apr_addto_duplicate = "0"; then echo " adding \"$i\" to APR_LTFLAGS" APR_LTFLAGS="$APR_LTFLAGS $i" fi done fi if test "x$APR_LTFLAGS" = "x"; then echo " setting APR_LTFLAGS to \""`$APU_CONFIG --link-libtool`"\"" APR_LTFLAGS=""`$APU_CONFIG --link-libtool`"" else apr_addto_bugger=""`$APU_CONFIG --link-libtool`"" for i in $apr_addto_bugger; do apr_addto_duplicate="0" for j in $APR_LTFLAGS; do if test "x$i" = "x$j"; then apr_addto_duplicate="1" break fi done if test $apr_addto_duplicate = "0"; then echo " adding \"$i\" to APR_LTFLAGS" APR_LTFLAGS="$APR_LTFLAGS $i" fi done fi if test "x$APR_LIBS" = "x"; then echo " setting APR_LIBS to \""`$APU_CONFIG --libs`"\"" APR_LIBS=""`$APU_CONFIG --libs`"" else apr_addto_bugger=""`$APU_CONFIG --libs`"" for i in $apr_addto_bugger; do apr_addto_duplicate="0" for j in $APR_LIBS; do if test "x$i" = "x$j"; then apr_addto_duplicate="1" break fi done if test $apr_addto_duplicate = "0"; then echo " adding \"$i\" to APR_LIBS" APR_LIBS="$APR_LIBS $i" fi done fi if test "x$APR_LIBS" = "x"; then echo " setting APR_LIBS to \""`$APR_CONFIG --libs`"\"" APR_LIBS=""`$APR_CONFIG --libs`"" else apr_addto_bugger=""`$APR_CONFIG --libs`"" for i in $apr_addto_bugger; do apr_addto_duplicate="0" for j in $APR_LIBS; do if test "x$i" = "x$j"; then apr_addto_duplicate="1" break fi done if test $apr_addto_duplicate = "0"; then echo " adding \"$i\" to APR_LIBS" APR_LIBS="$APR_LIBS $i" fi done fi if test "x$APR_LDFLAGS" = "x"; then echo " setting APR_LDFLAGS to \""`$APU_CONFIG --link-ld --ldflags`"\"" APR_LDFLAGS=""`$APU_CONFIG --link-ld --ldflags`"" else apr_addto_bugger=""`$APU_CONFIG --link-ld --ldflags`"" for i in $apr_addto_bugger; do apr_addto_duplicate="0" for j in $APR_LDFLAGS; do if test "x$i" = "x$j"; then apr_addto_duplicate="1" break fi done if test $apr_addto_duplicate = "0"; then echo " adding \"$i\" to APR_LDFLAGS" APR_LDFLAGS="$APR_LDFLAGS $i" fi done fi if test "x$APR_LDFLAGS" = "x"; then echo " setting APR_LDFLAGS to \""`$APR_CONFIG --link-ld --ldflags`"\"" APR_LDFLAGS=""`$APR_CONFIG --link-ld --ldflags`"" else apr_addto_bugger=""`$APR_CONFIG --link-ld --ldflags`"" for i in $apr_addto_bugger; do apr_addto_duplicate="0" for j in $APR_LDFLAGS; do if test "x$i" = "x$j"; then apr_addto_duplicate="1" break fi done if test $apr_addto_duplicate = "0"; then echo " adding \"$i\" to APR_LDFLAGS" APR_LDFLAGS="$APR_LDFLAGS $i" fi done fi if test -n "$EXPAT_DIR"; then if test "x$APR_INCLUDES" = "x"; then echo " setting APR_INCLUDES to \""-I$EXPAT_DIR/include"\"" APR_INCLUDES=""-I$EXPAT_DIR/include"" else apr_addto_bugger=""-I$EXPAT_DIR/include"" for i in $apr_addto_bugger; do apr_addto_duplicate="0" for j in $APR_INCLUDES; do if test "x$i" = "x$j"; then apr_addto_duplicate="1" break fi done if test $apr_addto_duplicate = "0"; then echo " adding \"$i\" to APR_INCLUDES" APR_INCLUDES="$APR_INCLUDES $i" fi done fi if test "x$APR_LTFLAGS" = "x"; then echo " setting APR_LTFLAGS to \""-L$EXPAT_DIR/lib"\"" APR_LTFLAGS=""-L$EXPAT_DIR/lib"" else apr_addto_bugger=""-L$EXPAT_DIR/lib"" for i in $apr_addto_bugger; do apr_addto_duplicate="0" for j in $APR_LTFLAGS; do if test "x$i" = "x$j"; then apr_addto_duplicate="1" break fi done if test $apr_addto_duplicate = "0"; then echo " adding \"$i\" to APR_LTFLAGS" APR_LTFLAGS="$APR_LTFLAGS $i" fi done fi fi abs_srcdir=`(cd $srcdir && pwd)` abs_builddir=`pwd` top_builddir="$abs_srcdir" if test "$abs_builddir" != "$abs_srcdir"; then USE_VPATH=1 fi if test "x$USE_MAINTAINER_MODE" != "xno"; then if test "x$CFLAGS" = "x"; then echo " setting CFLAGS to \" -Werror -Wall -Wmissing-prototypes -Wstrict-prototypes -Wmissing-declarations -Wwrite-strings -Wcast-qual -Wfloat-equal -Wshadow -Wpointer-arith -Wbad-function-cast -Wsign-compare -Waggregate-return -Wmissing-noreturn -Wmissing-format-attribute -Wpacked -Wredundant-decls -Wnested-externs -Wdisabled-optimization -Wno-long-long -Wendif-labels -Wcast-align -Wpacked \"" CFLAGS=" -Werror -Wall -Wmissing-prototypes -Wstrict-prototypes -Wmissing-declarations -Wwrite-strings -Wcast-qual -Wfloat-equal -Wshadow -Wpointer-arith -Wbad-function-cast -Wsign-compare -Waggregate-return -Wmissing-noreturn -Wmissing-format-attribute -Wpacked -Wredundant-decls -Wnested-externs -Wdisabled-optimization -Wno-long-long -Wendif-labels -Wcast-align -Wpacked " else apr_addto_bugger=" -Werror -Wall -Wmissing-prototypes -Wstrict-prototypes -Wmissing-declarations -Wwrite-strings -Wcast-qual -Wfloat-equal -Wshadow -Wpointer-arith -Wbad-function-cast -Wsign-compare -Waggregate-return -Wmissing-noreturn -Wmissing-format-attribute -Wpacked -Wredundant-decls -Wnested-externs -Wdisabled-optimization -Wno-long-long -Wendif-labels -Wcast-align -Wpacked " for i in $apr_addto_bugger; do apr_addto_duplicate="0" for j in $CFLAGS; do if test "x$i" = "x$j"; then apr_addto_duplicate="1" break fi done if test $apr_addto_duplicate = "0"; then echo " adding \"$i\" to CFLAGS" CFLAGS="$CFLAGS $i" fi done fi # -Wdeclaration-after-statement is only supported on gcc 3.4+ fi if test "x$CPPFLAGS" = "x"; then echo " setting CPPFLAGS to \""`$APR_CONFIG --cppflags`"\"" CPPFLAGS=""`$APR_CONFIG --cppflags`"" else apr_addto_bugger=""`$APR_CONFIG --cppflags`"" for i in $apr_addto_bugger; do apr_addto_duplicate="0" for j in $CPPFLAGS; do if test "x$i" = "x$j"; then apr_addto_duplicate="1" break fi done if test $apr_addto_duplicate = "0"; then echo " adding \"$i\" to CPPFLAGS" CPPFLAGS="$CPPFLAGS $i" fi done fi get_version="$SHELL $abs_srcdir/build/get-version.sh" version_hdr="$abs_srcdir/include/apreq_version.h" # set version data APREQ_CONFIG="$top_builddir/apreq2-config" APREQ_MAJOR_VERSION=`$get_version major $version_hdr APREQ` APREQ_MINOR_VERSION=`$get_version minor $version_hdr APREQ` APREQ_PATCH_VERSION=`$get_version patch $version_hdr APREQ` APREQ_DOTTED_VERSION=`$get_version all $version_hdr APREQ` # XXX: APR_MAJOR_VERSION doesn't yet work for static builds APREQ_LIBTOOL_CURRENT=`expr $APREQ_MAJOR_VERSION + $APREQ_MINOR_VERSION + $APR_MAJOR_VERSION` APREQ_LIBTOOL_REVISION=$APREQ_PATCH_VERSION APREQ_LIBTOOL_AGE=$APREQ_MINOR_VERSION APREQ_LIBTOOL_VERSION="$APREQ_LIBTOOL_CURRENT:$APREQ_LIBTOOL_REVISION:$APREQ_LIBTOOL_AGE" APREQ_LIBNAME="apreq$APREQ_MAJOR_VERSION" echo "lib$APREQ_LIBNAME Version: $APREQ_DOTTED_VERSION" ac_config_files="$ac_config_files Makefile include/Makefile library/Makefile library/t/Makefile module/Makefile module/apache2/Makefile module/apache/Makefile glue/Makefile" ac_config_files="$ac_config_files build/doxygen.conf include/groups.dox" ac_config_files="$ac_config_files apreq2-config" 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, don't put newlines in cache variables' values. # 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. { (set) 2>&1 | case `(ac_space=' '; set | grep ac_space) 2>&1` in *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 \ "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p" ;; esac; } | sed ' t clear : clear s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ t end /^ac_cv_env/!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" && echo "updating cache $cache_file" cat confcache >$cache_file else echo "not updating unwritable cache $cache_file" 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}' # 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 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_i=`echo "$ac_i" | sed 's/\$U\././;s/\.o$//;s/\.obj$//'` # 2. Add them. ac_libobjs="$ac_libobjs $ac_i\$U.$ac_objext" ac_ltlibobjs="$ac_ltlibobjs $ac_i"'$U.lo' done LIBOBJS=$ac_libobjs LTLIBOBJS=$ac_ltlibobjs if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then { { echo "$as_me:$LINENO: error: conditional \"AMDEP\" was never defined. Usually this means the macro was only invoked conditionally." >&5 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 "${MAINTAINER_MODE_TRUE}" && test -z "${MAINTAINER_MODE_FALSE}"; then { { echo "$as_me:$LINENO: error: conditional \"MAINTAINER_MODE\" was never defined. Usually this means the macro was only invoked conditionally." >&5 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 "${ENABLE_PROFILE_TRUE}" && test -z "${ENABLE_PROFILE_FALSE}"; then { { echo "$as_me:$LINENO: error: conditional \"ENABLE_PROFILE\" was never defined. Usually this means the macro was only invoked conditionally." >&5 echo "$as_me: error: conditional \"ENABLE_PROFILE\" was never defined. Usually this means the macro was only invoked conditionally." >&2;} { (exit 1); exit 1; }; } fi if test -z "${BUILD_PERL_GLUE_TRUE}" && test -z "${BUILD_PERL_GLUE_FALSE}"; then { { echo "$as_me:$LINENO: error: conditional \"BUILD_PERL_GLUE\" was never defined. Usually this means the macro was only invoked conditionally." >&5 echo "$as_me: error: conditional \"BUILD_PERL_GLUE\" was never defined. Usually this means the macro was only invoked conditionally." >&2;} { (exit 1); exit 1; }; } fi if test -z "${HAVE_APACHE_TEST_TRUE}" && test -z "${HAVE_APACHE_TEST_FALSE}"; then { { echo "$as_me:$LINENO: error: conditional \"HAVE_APACHE_TEST\" was never defined. Usually this means the macro was only invoked conditionally." >&5 echo "$as_me: error: conditional \"HAVE_APACHE_TEST\" was never defined. Usually this means the macro was only invoked conditionally." >&2;} { (exit 1); exit 1; }; } fi if test -z "${BUILD_HTTPD_TRUE}" && test -z "${BUILD_HTTPD_FALSE}"; then { { echo "$as_me:$LINENO: error: conditional \"BUILD_HTTPD\" was never defined. Usually this means the macro was only invoked conditionally." >&5 echo "$as_me: error: conditional \"BUILD_HTTPD\" was never defined. Usually this means the macro was only invoked conditionally." >&2;} { (exit 1); exit 1; }; } fi if test -z "${BUILD_APR_TRUE}" && test -z "${BUILD_APR_FALSE}"; then { { echo "$as_me:$LINENO: error: conditional \"BUILD_APR\" was never defined. Usually this means the macro was only invoked conditionally." >&5 echo "$as_me: error: conditional \"BUILD_APR\" was never defined. Usually this means the macro was only invoked conditionally." >&2;} { (exit 1); exit 1; }; } fi if test -z "${BUILD_APU_TRUE}" && test -z "${BUILD_APU_FALSE}"; then { { echo "$as_me:$LINENO: error: conditional \"BUILD_APU\" was never defined. Usually this means the macro was only invoked conditionally." >&5 echo "$as_me: error: conditional \"BUILD_APU\" was never defined. Usually this means the macro was only invoked conditionally." >&2;} { (exit 1); exit 1; }; } fi if test -z "${HAVE_APACHE1_TRUE}" && test -z "${HAVE_APACHE1_FALSE}"; then { { echo "$as_me:$LINENO: error: conditional \"HAVE_APACHE1\" was never defined. Usually this means the macro was only invoked conditionally." >&5 echo "$as_me: error: conditional \"HAVE_APACHE1\" was never defined. Usually this means the macro was only invoked conditionally." >&2;} { (exit 1); exit 1; }; } fi : ${CONFIG_STATUS=./config.status} ac_clean_files_save=$ac_clean_files ac_clean_files="$ac_clean_files $CONFIG_STATUS" { echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5 echo "$as_me: creating $CONFIG_STATUS" >&6;} cat >$CONFIG_STATUS <<_ACEOF #! $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. debug=false ac_cs_recheck=false ac_cs_silent=false SHELL=\${CONFIG_SHELL-$SHELL} _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF ## --------------------- ## ## M4sh Initialization. ## ## --------------------- ## # 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+"$@"}'='"$@"' elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then set -o posix fi DUALCASE=1; export DUALCASE # for MKS sh # Support unset when possible. if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then as_unset=unset else as_unset=false fi # Work around bugs in pre-3.0 UWIN ksh. $as_unset ENV MAIL MAILPATH PS1='$ ' PS2='> ' PS4='+ ' # NLS nuisances. for as_var in \ LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \ LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \ LC_TELEPHONE LC_TIME do if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then eval $as_var=C; export $as_var else $as_unset $as_var fi done # Required to use basename. if expr a : '\(a\)' >/dev/null 2>&1; then as_expr=expr else as_expr=false fi if (basename /) >/dev/null 2>&1 && test "X`basename / 2>&1`" = "X/"; then as_basename=basename else as_basename=false fi # Name of the executable. as_me=`$as_basename "$0" || $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ X"$0" : 'X\(//\)$' \| \ X"$0" : 'X\(/\)$' \| \ . : '\(.\)' 2>/dev/null || echo X/"$0" | sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; } /^X\/\(\/\/\)$/{ s//\1/; q; } /^X\/\(\/\).*/{ s//\1/; q; } s/.*/./; q'` # PATH needs CR, and LINENO needs CR and PATH. # 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 # The user is always right. if test "${PATH_SEPARATOR+set}" != set; then echo "#! /bin/sh" >conf$$.sh echo "exit 0" >>conf$$.sh chmod +x conf$$.sh if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then PATH_SEPARATOR=';' else PATH_SEPARATOR=: fi rm -f conf$$.sh fi as_lineno_1=$LINENO as_lineno_2=$LINENO as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null` test "x$as_lineno_1" != "x$as_lineno_2" && test "x$as_lineno_3" = "x$as_lineno_2" || { # Find who we are. Look in the path if we contain no path at all # relative or not. 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 ;; 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 { { echo "$as_me:$LINENO: error: cannot find myself; rerun with an absolute path" >&5 echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2;} { (exit 1); exit 1; }; } fi case $CONFIG_SHELL in '') as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for as_base in sh bash ksh sh5; do case $as_dir in /*) if ("$as_dir/$as_base" -c ' as_lineno_1=$LINENO as_lineno_2=$LINENO as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null` test "x$as_lineno_1" != "x$as_lineno_2" && test "x$as_lineno_3" = "x$as_lineno_2" ') 2>/dev/null; then $as_unset BASH_ENV || test "${BASH_ENV+set}" != set || { BASH_ENV=; export BASH_ENV; } $as_unset ENV || test "${ENV+set}" != set || { ENV=; export ENV; } CONFIG_SHELL=$as_dir/$as_base export CONFIG_SHELL exec "$CONFIG_SHELL" "$0" ${1+"$@"} fi;; esac done done ;; esac # 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 before each line; the second 'sed' does the real # work. The second script uses 'N' to pair each line-number line # with the numbered line, 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 # second 'sed' script. Blame Lee E. McMahon for sed's syntax. :-) sed '=' <$as_myself | sed ' N s,$,-, : loop s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3, t loop s,-$,, s,^['$as_cr_digits']*\n,, ' >$as_me.lineno && chmod +x $as_me.lineno || { { echo "$as_me:$LINENO: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&5 echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2;} { (exit 1); exit 1; }; } # 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 sensible to this). . ./$as_me.lineno # Exit status is that of the last command. exit } case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in *c*,-n*) ECHO_N= ECHO_C=' ' ECHO_T=' ' ;; *c*,* ) ECHO_N=-n ECHO_C= ECHO_T= ;; *) ECHO_N= ECHO_C='\c' ECHO_T= ;; esac if expr a : '\(a\)' >/dev/null 2>&1; then as_expr=expr else as_expr=false fi rm -f conf$$ conf$$.exe conf$$.file echo >conf$$.file if ln -s conf$$.file conf$$ 2>/dev/null; then # We could just check for DJGPP; but this test a) works b) is more generic # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04). if test -f conf$$.exe; then # Don't use ln at all; we don't have any links as_ln_s='cp -p' else as_ln_s='ln -s' fi elif ln conf$$.file conf$$ 2>/dev/null; then as_ln_s=ln else as_ln_s='cp -p' fi rm -f conf$$ conf$$.exe conf$$.file if mkdir -p . 2>/dev/null; then as_mkdir_p=: else test -d ./-p && rmdir ./-p as_mkdir_p=false fi as_executable_p="test -f" # 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'" # IFS # We need space, tab and new line, in precisely that order. as_nl=' ' IFS=" $as_nl" # CDPATH. $as_unset CDPATH exec 6>&1 # Open the log real soon, to keep \$[0] and so on meaningful, and to # report actual input values of CONFIG_FILES etc. instead of their # values after options handling. Logging --version etc. is OK. exec 5>>config.log { echo sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX ## Running $as_me. ## _ASBOX } >&5 cat >&5 <<_CSEOF This file was extended by Apache HTTP Server Request Library $as_me 2.05-dev, which was generated by GNU Autoconf 2.59. Invocation command line was CONFIG_FILES = $CONFIG_FILES CONFIG_HEADERS = $CONFIG_HEADERS CONFIG_LINKS = $CONFIG_LINKS CONFIG_COMMANDS = $CONFIG_COMMANDS $ $0 $@ _CSEOF echo "on `(hostname || uname -n) 2>/dev/null | sed 1q`" >&5 echo >&5 _ACEOF # Files that config.status was made for. if test -n "$ac_config_files"; then echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS fi if test -n "$ac_config_headers"; then echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS fi if test -n "$ac_config_links"; then echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS fi if test -n "$ac_config_commands"; then echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS fi cat >>$CONFIG_STATUS <<\_ACEOF ac_cs_usage="\ \`$as_me' instantiates files from templates according to the current configuration. Usage: $0 [OPTIONS] [FILE]... -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 --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_cs_version="\\ Apache HTTP Server Request Library config.status 2.05-dev configured by $0, generated by GNU Autoconf 2.59, with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\" Copyright (C) 2003 Free Software Foundation, Inc. This config.status script is free software; the Free Software Foundation gives unlimited permission to copy, distribute and modify it." srcdir=$srcdir INSTALL="$INSTALL" _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF # If no file are specified by the user, then we need to provide default # value. By we need to know if files were specified by the user. 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 ;; *) # This is not an option, so the user has probably given explicit # arguments. ac_option=$1 ac_need_defaults=false;; esac case $ac_option in # Handling of the options. _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) ac_cs_recheck=: ;; --version | --vers* | -V ) echo "$ac_cs_version"; exit 0 ;; --he | --h) # Conflict between --help and --header { { echo "$as_me:$LINENO: error: ambiguous option: $1 Try \`$0 --help' for more information." >&5 echo "$as_me: error: ambiguous option: $1 Try \`$0 --help' for more information." >&2;} { (exit 1); exit 1; }; };; --help | --hel | -h ) echo "$ac_cs_usage"; exit 0 ;; --debug | --d* | -d ) debug=: ;; --file | --fil | --fi | --f ) $ac_shift CONFIG_FILES="$CONFIG_FILES $ac_optarg" ac_need_defaults=false;; --header | --heade | --head | --hea ) $ac_shift CONFIG_HEADERS="$CONFIG_HEADERS $ac_optarg" ac_need_defaults=false;; -q | -quiet | --quiet | --quie | --qui | --qu | --q \ | -silent | --silent | --silen | --sile | --sil | --si | --s) ac_cs_silent=: ;; # This is an error. -*) { { echo "$as_me:$LINENO: error: unrecognized option: $1 Try \`$0 --help' for more information." >&5 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" ;; 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 if \$ac_cs_recheck; then echo "running $SHELL $0 " $ac_configure_args \$ac_configure_extra_args " --no-create --no-recursion" >&6 exec $SHELL $0 $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion fi _ACEOF cat >>$CONFIG_STATUS <<_ACEOF # # INIT-COMMANDS section. # AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir" _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF for ac_config_target in $ac_config_targets do case "$ac_config_target" in # Handling of arguments. "Makefile" ) CONFIG_FILES="$CONFIG_FILES Makefile" ;; "include/Makefile" ) CONFIG_FILES="$CONFIG_FILES include/Makefile" ;; "library/Makefile" ) CONFIG_FILES="$CONFIG_FILES library/Makefile" ;; "library/t/Makefile" ) CONFIG_FILES="$CONFIG_FILES library/t/Makefile" ;; "module/Makefile" ) CONFIG_FILES="$CONFIG_FILES module/Makefile" ;; "module/apache2/Makefile" ) CONFIG_FILES="$CONFIG_FILES module/apache2/Makefile" ;; "module/apache/Makefile" ) CONFIG_FILES="$CONFIG_FILES module/apache/Makefile" ;; "glue/Makefile" ) CONFIG_FILES="$CONFIG_FILES glue/Makefile" ;; "build/doxygen.conf" ) CONFIG_FILES="$CONFIG_FILES build/doxygen.conf" ;; "include/groups.dox" ) CONFIG_FILES="$CONFIG_FILES include/groups.dox" ;; "apreq2-config" ) CONFIG_FILES="$CONFIG_FILES apreq2-config" ;; "depfiles" ) CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;; "include/apreq_config.h" ) CONFIG_HEADERS="$CONFIG_HEADERS include/apreq_config.h" ;; *) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5 echo "$as_me: error: invalid argument: $ac_config_target" >&2;} { (exit 1); exit 1; }; };; esac done # 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 # Have a temporary directory for convenience. Make it in the build tree # simply because there is no reason to put it here, and in addition, # creating and moving files from /tmp can sometimes cause problems. # Create a temporary directory, and hook for its removal unless debugging. $debug || { trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0 trap '{ (exit 1); exit 1; }' 1 2 13 15 } # Create a (secure) tmp directory for tmp files. { tmp=`(umask 077 && mktemp -d -q "./confstatXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" } || { tmp=./confstat$$-$RANDOM (umask 077 && mkdir $tmp) } || { echo "$me: cannot create a temporary directory in ." >&2 { (exit 1); exit 1; } } _ACEOF cat >>$CONFIG_STATUS <<_ACEOF # # CONFIG_FILES section. # # No need to generate the scripts if there are no CONFIG_FILES. # This happens for instance when ./config.status config.h if test -n "\$CONFIG_FILES"; then # Protect against being on the right side of a sed subst in config.status. sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g; s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF s,@SHELL@,$SHELL,;t t s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t s,@exec_prefix@,$exec_prefix,;t t s,@prefix@,$prefix,;t t s,@program_transform_name@,$program_transform_name,;t t s,@bindir@,$bindir,;t t s,@sbindir@,$sbindir,;t t s,@libexecdir@,$libexecdir,;t t s,@datadir@,$datadir,;t t s,@sysconfdir@,$sysconfdir,;t t s,@sharedstatedir@,$sharedstatedir,;t t s,@localstatedir@,$localstatedir,;t t s,@libdir@,$libdir,;t t s,@includedir@,$includedir,;t t s,@oldincludedir@,$oldincludedir,;t t s,@infodir@,$infodir,;t t s,@mandir@,$mandir,;t t s,@build_alias@,$build_alias,;t t s,@host_alias@,$host_alias,;t t s,@target_alias@,$target_alias,;t t s,@DEFS@,$DEFS,;t t s,@ECHO_C@,$ECHO_C,;t t s,@ECHO_N@,$ECHO_N,;t t s,@ECHO_T@,$ECHO_T,;t t s,@LIBS@,$LIBS,;t t s,@INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t s,@INSTALL_SCRIPT@,$INSTALL_SCRIPT,;t t s,@INSTALL_DATA@,$INSTALL_DATA,;t t s,@PACKAGE@,$PACKAGE,;t t s,@VERSION@,$VERSION,;t t s,@ACLOCAL@,$ACLOCAL,;t t s,@AUTOCONF@,$AUTOCONF,;t t s,@AUTOMAKE@,$AUTOMAKE,;t t s,@AUTOHEADER@,$AUTOHEADER,;t t s,@MAKEINFO@,$MAKEINFO,;t t s,@AMTAR@,$AMTAR,;t t s,@install_sh@,$install_sh,;t t s,@STRIP@,$STRIP,;t t s,@ac_ct_STRIP@,$ac_ct_STRIP,;t t s,@INSTALL_STRIP_PROGRAM@,$INSTALL_STRIP_PROGRAM,;t t s,@AWK@,$AWK,;t t s,@SET_MAKE@,$SET_MAKE,;t t s,@CC@,$CC,;t t s,@CFLAGS@,$CFLAGS,;t t s,@LDFLAGS@,$LDFLAGS,;t t s,@CPPFLAGS@,$CPPFLAGS,;t t s,@ac_ct_CC@,$ac_ct_CC,;t t s,@EXEEXT@,$EXEEXT,;t t s,@OBJEXT@,$OBJEXT,;t t s,@DEPDIR@,$DEPDIR,;t t s,@am__include@,$am__include,;t t s,@am__quote@,$am__quote,;t t s,@AMDEP_TRUE@,$AMDEP_TRUE,;t t s,@AMDEP_FALSE@,$AMDEP_FALSE,;t t s,@AMDEPBACKSLASH@,$AMDEPBACKSLASH,;t t s,@CCDEPMODE@,$CCDEPMODE,;t t s,@build@,$build,;t t s,@build_cpu@,$build_cpu,;t t s,@build_vendor@,$build_vendor,;t t s,@build_os@,$build_os,;t t s,@host@,$host,;t t s,@host_cpu@,$host_cpu,;t t s,@host_vendor@,$host_vendor,;t t s,@host_os@,$host_os,;t t s,@EGREP@,$EGREP,;t t s,@LN_S@,$LN_S,;t t s,@ECHO@,$ECHO,;t t s,@AR@,$AR,;t t s,@ac_ct_AR@,$ac_ct_AR,;t t s,@RANLIB@,$RANLIB,;t t s,@ac_ct_RANLIB@,$ac_ct_RANLIB,;t t s,@CPP@,$CPP,;t t s,@CXX@,$CXX,;t t s,@CXXFLAGS@,$CXXFLAGS,;t t s,@ac_ct_CXX@,$ac_ct_CXX,;t t s,@CXXDEPMODE@,$CXXDEPMODE,;t t s,@CXXCPP@,$CXXCPP,;t t s,@F77@,$F77,;t t s,@FFLAGS@,$FFLAGS,;t t s,@ac_ct_F77@,$ac_ct_F77,;t t s,@LIBTOOL@,$LIBTOOL,;t t s,@MAINTAINER_MODE_TRUE@,$MAINTAINER_MODE_TRUE,;t t s,@MAINTAINER_MODE_FALSE@,$MAINTAINER_MODE_FALSE,;t t s,@MAINT@,$MAINT,;t t s,@ENABLE_PROFILE_TRUE@,$ENABLE_PROFILE_TRUE,;t t s,@ENABLE_PROFILE_FALSE@,$ENABLE_PROFILE_FALSE,;t t s,@BUILD_PERL_GLUE_TRUE@,$BUILD_PERL_GLUE_TRUE,;t t s,@BUILD_PERL_GLUE_FALSE@,$BUILD_PERL_GLUE_FALSE,;t t s,@HAVE_APACHE_TEST_TRUE@,$HAVE_APACHE_TEST_TRUE,;t t s,@HAVE_APACHE_TEST_FALSE@,$HAVE_APACHE_TEST_FALSE,;t t s,@BUILD_HTTPD_TRUE@,$BUILD_HTTPD_TRUE,;t t s,@BUILD_HTTPD_FALSE@,$BUILD_HTTPD_FALSE,;t t s,@BUILD_APR_TRUE@,$BUILD_APR_TRUE,;t t s,@BUILD_APR_FALSE@,$BUILD_APR_FALSE,;t t s,@BUILD_APU_TRUE@,$BUILD_APU_TRUE,;t t s,@BUILD_APU_FALSE@,$BUILD_APU_FALSE,;t t s,@HAVE_APACHE1_TRUE@,$HAVE_APACHE1_TRUE,;t t s,@HAVE_APACHE1_FALSE@,$HAVE_APACHE1_FALSE,;t t s,@APREQ_CONFIG@,$APREQ_CONFIG,;t t s,@APREQ_LIBNAME@,$APREQ_LIBNAME,;t t s,@APREQ_LIBTOOL_VERSION@,$APREQ_LIBTOOL_VERSION,;t t s,@APREQ_MAJOR_VERSION@,$APREQ_MAJOR_VERSION,;t t s,@APREQ_DOTTED_VERSION@,$APREQ_DOTTED_VERSION,;t t s,@APACHE2_APXS@,$APACHE2_APXS,;t t s,@APACHE2_SRC@,$APACHE2_SRC,;t t s,@APACHE2_INCLUDES@,$APACHE2_INCLUDES,;t t s,@APACHE2_HTTPD@,$APACHE2_HTTPD,;t t s,@APACHE1_APXS@,$APACHE1_APXS,;t t s,@APU_CONFIG@,$APU_CONFIG,;t t s,@APR_CONFIG@,$APR_CONFIG,;t t s,@APR_INCLUDES@,$APR_INCLUDES,;t t s,@APR_LDFLAGS@,$APR_LDFLAGS,;t t s,@APR_LTFLAGS@,$APR_LTFLAGS,;t t s,@APR_LIBS@,$APR_LIBS,;t t s,@APR_LA@,$APR_LA,;t t s,@APU_LA@,$APU_LA,;t t s,@PERL@,$PERL,;t t s,@PERL_OPTS@,$PERL_OPTS,;t t s,@LIBOBJS@,$LIBOBJS,;t t s,@LTLIBOBJS@,$LTLIBOBJS,;t t CEOF _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF # Split the substitutions into bite-sized pieces for seds with # small command number limits, like on Digital OSF/1 and HP-UX. ac_max_sed_lines=48 ac_sed_frag=1 # Number of current file. ac_beg=1 # First line for current file. ac_end=$ac_max_sed_lines # Line after last line for current file. ac_more_lines=: ac_sed_cmds= while $ac_more_lines; do if test $ac_beg -gt 1; then sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag else sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag fi if test ! -s $tmp/subs.frag; then ac_more_lines=false else # The purpose of the label and of the branching condition is to # speed up the sed processing (if there are no `@' at all, there # is no need to browse any of the substitutions). # These are the two extra sed commands mentioned above. (echo ':t /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed if test -z "$ac_sed_cmds"; then ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed" else ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed" fi ac_sed_frag=`expr $ac_sed_frag + 1` ac_beg=$ac_end ac_end=`expr $ac_end + $ac_max_sed_lines` fi done if test -z "$ac_sed_cmds"; then ac_sed_cmds=cat fi fi # test -n "$CONFIG_FILES" _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in". case $ac_file in - | *:- | *:-:* ) # input from stdin cat >$tmp/stdin ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'` ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;; *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'` ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;; * ) ac_file_in=$ac_file.in ;; esac # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories. ac_dir=`(dirname "$ac_file") 2>/dev/null || $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$ac_file" : 'X\(//\)[^/]' \| \ X"$ac_file" : 'X\(//\)$' \| \ X"$ac_file" : 'X\(/\)' \| \ . : '\(.\)' 2>/dev/null || echo X"$ac_file" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; } /^X\(\/\/\)[^/].*/{ s//\1/; q; } /^X\(\/\/\)$/{ s//\1/; q; } /^X\(\/\).*/{ s//\1/; q; } s/.*/./; q'` { if $as_mkdir_p; then mkdir -p "$ac_dir" else as_dir="$ac_dir" as_dirs= while test ! -d "$as_dir"; do as_dirs="$as_dir $as_dirs" as_dir=`(dirname "$as_dir") 2>/dev/null || $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$as_dir" : 'X\(//\)[^/]' \| \ X"$as_dir" : 'X\(//\)$' \| \ X"$as_dir" : 'X\(/\)' \| \ . : '\(.\)' 2>/dev/null || echo X"$as_dir" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; } /^X\(\/\/\)[^/].*/{ s//\1/; q; } /^X\(\/\/\)$/{ s//\1/; q; } /^X\(\/\).*/{ s//\1/; q; } s/.*/./; q'` done test ! -n "$as_dirs" || mkdir $as_dirs fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5 echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;} { (exit 1); exit 1; }; }; } ac_builddir=. if test "$ac_dir" != .; then ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'` # A "../" for each directory in $ac_dir_suffix. ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'` else ac_dir_suffix= ac_top_builddir= fi case $srcdir in .) # No --srcdir option. We are building in place. ac_srcdir=. if test -z "$ac_top_builddir"; then ac_top_srcdir=. else ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'` fi ;; [\\/]* | ?:[\\/]* ) # Absolute path. ac_srcdir=$srcdir$ac_dir_suffix; ac_top_srcdir=$srcdir ;; *) # Relative path. ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix ac_top_srcdir=$ac_top_builddir$srcdir ;; esac # Do not use `cd foo && pwd` to compute absolute paths, because # the directories may not exist. case `pwd` in .) ac_abs_builddir="$ac_dir";; *) case "$ac_dir" in .) ac_abs_builddir=`pwd`;; [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";; *) ac_abs_builddir=`pwd`/"$ac_dir";; esac;; esac case $ac_abs_builddir in .) ac_abs_top_builddir=${ac_top_builddir}.;; *) case ${ac_top_builddir}. in .) ac_abs_top_builddir=$ac_abs_builddir;; [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;; *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;; esac;; esac case $ac_abs_builddir in .) ac_abs_srcdir=$ac_srcdir;; *) case $ac_srcdir in .) ac_abs_srcdir=$ac_abs_builddir;; [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;; *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;; esac;; esac case $ac_abs_builddir in .) ac_abs_top_srcdir=$ac_top_srcdir;; *) case $ac_top_srcdir in .) ac_abs_top_srcdir=$ac_abs_builddir;; [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;; *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;; esac;; esac case $INSTALL in [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;; *) ac_INSTALL=$ac_top_builddir$INSTALL ;; esac # 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. */ if test x"$ac_file" = x-; then configure_input= else configure_input="$ac_file. " fi configure_input=$configure_input"Generated from `echo $ac_file_in | sed 's,.*/,,'` by configure." # First look for the input files in the build tree, otherwise in the # src tree. ac_file_inputs=`IFS=: for f in $ac_file_in; do case $f in -) echo $tmp/stdin ;; [\\/$]*) # Absolute (can't be DOS-style, as IFS=:) test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5 echo "$as_me: error: cannot find input file: $f" >&2;} { (exit 1); exit 1; }; } echo "$f";; *) # Relative if test -f "$f"; then # Build tree echo "$f" elif test -f "$srcdir/$f"; then # Source tree echo "$srcdir/$f" else # /dev/null tree { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5 echo "$as_me: error: cannot find input file: $f" >&2;} { (exit 1); exit 1; }; } fi;; esac done` || { (exit 1); exit 1; } if test x"$ac_file" != x-; then { echo "$as_me:$LINENO: creating $ac_file" >&5 echo "$as_me: creating $ac_file" >&6;} rm -f "$ac_file" fi _ACEOF cat >>$CONFIG_STATUS <<_ACEOF sed "$ac_vpsub $extrasub _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF :t /@[a-zA-Z_][a-zA-Z_0-9]*@/!b s,@configure_input@,$configure_input,;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,@top_builddir@,$ac_top_builddir,;t t s,@abs_top_builddir@,$ac_abs_top_builddir,;t t s,@INSTALL@,$ac_INSTALL,;t t " $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out rm -f $tmp/stdin if test x"$ac_file" != x-; then mv $tmp/out $ac_file else cat $tmp/out rm -f $tmp/out fi # Run the commands associated with the file. case $ac_file in apreq2-config ) chmod +x apreq2-config ;; esac done _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF # # CONFIG_HEADER section. # # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where # NAME is the cpp macro being defined and VALUE is the value it is being given. # # ac_d sets the value in "#define NAME VALUE" lines. ac_dA='s,^\([ ]*\)#\([ ]*define[ ][ ]*\)' ac_dB='[ ].*$,\1#\2' ac_dC=' ' ac_dD=',;t' # ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE". ac_uA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)' ac_uB='$,\1#\2define\3' ac_uC=' ' ac_uD=',;t' for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in". case $ac_file in - | *:- | *:-:* ) # input from stdin cat >$tmp/stdin ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'` ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;; *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'` ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;; * ) ac_file_in=$ac_file.in ;; esac test x"$ac_file" != x- && { echo "$as_me:$LINENO: creating $ac_file" >&5 echo "$as_me: creating $ac_file" >&6;} # First look for the input files in the build tree, otherwise in the # src tree. ac_file_inputs=`IFS=: for f in $ac_file_in; do case $f in -) echo $tmp/stdin ;; [\\/$]*) # Absolute (can't be DOS-style, as IFS=:) test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5 echo "$as_me: error: cannot find input file: $f" >&2;} { (exit 1); exit 1; }; } # Do quote $f, to prevent DOS paths from being IFS'd. echo "$f";; *) # Relative if test -f "$f"; then # Build tree echo "$f" elif test -f "$srcdir/$f"; then # Source tree echo "$srcdir/$f" else # /dev/null tree { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5 echo "$as_me: error: cannot find input file: $f" >&2;} { (exit 1); exit 1; }; } fi;; esac done` || { (exit 1); exit 1; } # Remove the trailing spaces. sed 's/[ ]*$//' $ac_file_inputs >$tmp/in _ACEOF # Transform confdefs.h into two sed scripts, `conftest.defines' and # `conftest.undefs', that substitutes the proper values into # config.h.in to produce config.h. The first handles `#define' # templates, and the second `#undef' templates. # And first: Protect against being on the right side of a sed subst in # config.status. Protect against being in an unquoted here document # in config.status. rm -f conftest.defines conftest.undefs # Using a here document instead of a string reduces the quoting nightmare. # Putting comments in sed scripts is not portable. # # `end' is used to avoid that the second main sed command (meant for # 0-ary CPP macros) applies to n-ary macro definitions. # See the Autoconf documentation for `clear'. cat >confdef2sed.sed <<\_ACEOF s/[\\&,]/\\&/g s,[\\$`],\\&,g t clear : clear s,^[ ]*#[ ]*define[ ][ ]*\([^ (][^ (]*\)\(([^)]*)\)[ ]*\(.*\)$,${ac_dA}\1${ac_dB}\1\2${ac_dC}\3${ac_dD},gp t end s,^[ ]*#[ ]*define[ ][ ]*\([^ ][^ ]*\)[ ]*\(.*\)$,${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD},gp : end _ACEOF # If some macros were called several times there might be several times # the same #defines, which is useless. Nevertheless, we may not want to # sort them, since we want the *last* AC-DEFINE to be honored. uniq confdefs.h | sed -n -f confdef2sed.sed >conftest.defines sed 's/ac_d/ac_u/g' conftest.defines >conftest.undefs rm -f confdef2sed.sed # This sed command replaces #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. cat >>conftest.undefs <<\_ACEOF s,^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*,/* & */, _ACEOF # Break up conftest.defines because some shells have a limit on the size # of here documents, and old seds have small limits too (100 cmds). echo ' # Handle all the #define templates only if necessary.' >>$CONFIG_STATUS echo ' if grep "^[ ]*#[ ]*define" $tmp/in >/dev/null; then' >>$CONFIG_STATUS echo ' # If there are no defines, we may have an empty if/fi' >>$CONFIG_STATUS echo ' :' >>$CONFIG_STATUS rm -f conftest.tail while grep . conftest.defines >/dev/null do # Write a limited-size here document to $tmp/defines.sed. echo ' cat >$tmp/defines.sed <>$CONFIG_STATUS # Speed up: don't consider the non `#define' lines. echo '/^[ ]*#[ ]*define/!b' >>$CONFIG_STATUS # Work around the forget-to-reset-the-flag bug. echo 't clr' >>$CONFIG_STATUS echo ': clr' >>$CONFIG_STATUS sed ${ac_max_here_lines}q conftest.defines >>$CONFIG_STATUS echo 'CEOF sed -f $tmp/defines.sed $tmp/in >$tmp/out rm -f $tmp/in mv $tmp/out $tmp/in ' >>$CONFIG_STATUS sed 1,${ac_max_here_lines}d conftest.defines >conftest.tail rm -f conftest.defines mv conftest.tail conftest.defines done rm -f conftest.defines echo ' fi # grep' >>$CONFIG_STATUS echo >>$CONFIG_STATUS # Break up conftest.undefs because some shells have a limit on the size # of here documents, and old seds have small limits too (100 cmds). echo ' # Handle all the #undef templates' >>$CONFIG_STATUS rm -f conftest.tail while grep . conftest.undefs >/dev/null do # Write a limited-size here document to $tmp/undefs.sed. echo ' cat >$tmp/undefs.sed <>$CONFIG_STATUS # Speed up: don't consider the non `#undef' echo '/^[ ]*#[ ]*undef/!b' >>$CONFIG_STATUS # Work around the forget-to-reset-the-flag bug. echo 't clr' >>$CONFIG_STATUS echo ': clr' >>$CONFIG_STATUS sed ${ac_max_here_lines}q conftest.undefs >>$CONFIG_STATUS echo 'CEOF sed -f $tmp/undefs.sed $tmp/in >$tmp/out rm -f $tmp/in mv $tmp/out $tmp/in ' >>$CONFIG_STATUS sed 1,${ac_max_here_lines}d conftest.undefs >conftest.tail rm -f conftest.undefs mv conftest.tail conftest.undefs done rm -f conftest.undefs cat >>$CONFIG_STATUS <<\_ACEOF # 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. */ if test x"$ac_file" = x-; then echo "/* Generated by configure. */" >$tmp/config.h else echo "/* $ac_file. Generated by configure. */" >$tmp/config.h fi cat $tmp/in >>$tmp/config.h rm -f $tmp/in if test x"$ac_file" != x-; then if diff $ac_file $tmp/config.h >/dev/null 2>&1; then { echo "$as_me:$LINENO: $ac_file is unchanged" >&5 echo "$as_me: $ac_file is unchanged" >&6;} else ac_dir=`(dirname "$ac_file") 2>/dev/null || $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$ac_file" : 'X\(//\)[^/]' \| \ X"$ac_file" : 'X\(//\)$' \| \ X"$ac_file" : 'X\(/\)' \| \ . : '\(.\)' 2>/dev/null || echo X"$ac_file" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; } /^X\(\/\/\)[^/].*/{ s//\1/; q; } /^X\(\/\/\)$/{ s//\1/; q; } /^X\(\/\).*/{ s//\1/; q; } s/.*/./; q'` { if $as_mkdir_p; then mkdir -p "$ac_dir" else as_dir="$ac_dir" as_dirs= while test ! -d "$as_dir"; do as_dirs="$as_dir $as_dirs" as_dir=`(dirname "$as_dir") 2>/dev/null || $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$as_dir" : 'X\(//\)[^/]' \| \ X"$as_dir" : 'X\(//\)$' \| \ X"$as_dir" : 'X\(/\)' \| \ . : '\(.\)' 2>/dev/null || echo X"$as_dir" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; } /^X\(\/\/\)[^/].*/{ s//\1/; q; } /^X\(\/\/\)$/{ s//\1/; q; } /^X\(\/\).*/{ s//\1/; q; } s/.*/./; q'` done test ! -n "$as_dirs" || mkdir $as_dirs fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5 echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;} { (exit 1); exit 1; }; }; } rm -f $ac_file mv $tmp/config.h $ac_file fi else cat $tmp/config.h rm -f $tmp/config.h fi # Run the commands associated with the file. case $ac_file in include/apreq_config.h ) # update the timestamp echo 'timestamp for include/apreq_config.h' >"include/stamp-h1" ;; esac done _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF # # CONFIG_COMMANDS section. # for ac_file in : $CONFIG_COMMANDS; do test "x$ac_file" = x: && continue ac_dest=`echo "$ac_file" | sed 's,:.*,,'` ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'` ac_dir=`(dirname "$ac_dest") 2>/dev/null || $as_expr X"$ac_dest" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$ac_dest" : 'X\(//\)[^/]' \| \ X"$ac_dest" : 'X\(//\)$' \| \ X"$ac_dest" : 'X\(/\)' \| \ . : '\(.\)' 2>/dev/null || echo X"$ac_dest" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; } /^X\(\/\/\)[^/].*/{ s//\1/; q; } /^X\(\/\/\)$/{ s//\1/; q; } /^X\(\/\).*/{ s//\1/; q; } s/.*/./; q'` { if $as_mkdir_p; then mkdir -p "$ac_dir" else as_dir="$ac_dir" as_dirs= while test ! -d "$as_dir"; do as_dirs="$as_dir $as_dirs" as_dir=`(dirname "$as_dir") 2>/dev/null || $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$as_dir" : 'X\(//\)[^/]' \| \ X"$as_dir" : 'X\(//\)$' \| \ X"$as_dir" : 'X\(/\)' \| \ . : '\(.\)' 2>/dev/null || echo X"$as_dir" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; } /^X\(\/\/\)[^/].*/{ s//\1/; q; } /^X\(\/\/\)$/{ s//\1/; q; } /^X\(\/\).*/{ s//\1/; q; } s/.*/./; q'` done test ! -n "$as_dirs" || mkdir $as_dirs fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5 echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;} { (exit 1); exit 1; }; }; } ac_builddir=. if test "$ac_dir" != .; then ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'` # A "../" for each directory in $ac_dir_suffix. ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'` else ac_dir_suffix= ac_top_builddir= fi case $srcdir in .) # No --srcdir option. We are building in place. ac_srcdir=. if test -z "$ac_top_builddir"; then ac_top_srcdir=. else ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'` fi ;; [\\/]* | ?:[\\/]* ) # Absolute path. ac_srcdir=$srcdir$ac_dir_suffix; ac_top_srcdir=$srcdir ;; *) # Relative path. ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix ac_top_srcdir=$ac_top_builddir$srcdir ;; esac # Do not use `cd foo && pwd` to compute absolute paths, because # the directories may not exist. case `pwd` in .) ac_abs_builddir="$ac_dir";; *) case "$ac_dir" in .) ac_abs_builddir=`pwd`;; [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";; *) ac_abs_builddir=`pwd`/"$ac_dir";; esac;; esac case $ac_abs_builddir in .) ac_abs_top_builddir=${ac_top_builddir}.;; *) case ${ac_top_builddir}. in .) ac_abs_top_builddir=$ac_abs_builddir;; [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;; *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;; esac;; esac case $ac_abs_builddir in .) ac_abs_srcdir=$ac_srcdir;; *) case $ac_srcdir in .) ac_abs_srcdir=$ac_abs_builddir;; [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;; *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;; esac;; esac case $ac_abs_builddir in .) ac_abs_top_srcdir=$ac_top_srcdir;; *) case $ac_top_srcdir in .) ac_abs_top_srcdir=$ac_abs_builddir;; [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;; *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;; esac;; esac { echo "$as_me:$LINENO: executing $ac_dest commands" >&5 echo "$as_me: executing $ac_dest commands" >&6;} case $ac_dest in depfiles ) test x"$AMDEP_TRUE" != x"" || for mf in $CONFIG_FILES; 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. # So let's grep whole file. if grep '^#.*generated by automake' $mf > /dev/null 2>&1; then dirpart=`(dirname "$mf") 2>/dev/null || $as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$mf" : 'X\(//\)[^/]' \| \ X"$mf" : 'X\(//\)$' \| \ X"$mf" : 'X\(/\)' \| \ . : '\(.\)' 2>/dev/null || 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 grep '^DEP_FILES *= *[^ #]' < "$mf" > /dev/null || continue # Extract the definition of DEP_FILES from the Makefile without # running `make'. DEPDIR=`sed -n -e '/^DEPDIR = / s///p' < "$mf"` test -z "$DEPDIR" && continue # When using ansi2knr, U may be empty or an underscore; expand it U=`sed -n -e '/^U = / s///p' < "$mf"` test -d "$dirpart/$DEPDIR" || mkdir "$dirpart/$DEPDIR" # 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 -e ' /^DEP_FILES = .*\\\\$/ { s/^DEP_FILES = // :loop s/\\\\$// p n /\\\\$/ b loop p } /^DEP_FILES = / s/^DEP_FILES = //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=`(dirname "$file") 2>/dev/null || $as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$file" : 'X\(//\)[^/]' \| \ X"$file" : 'X\(//\)$' \| \ X"$file" : 'X\(/\)' \| \ . : '\(.\)' 2>/dev/null || echo X"$file" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; } /^X\(\/\/\)[^/].*/{ s//\1/; q; } /^X\(\/\/\)$/{ s//\1/; q; } /^X\(\/\).*/{ s//\1/; q; } s/.*/./; q'` { if $as_mkdir_p; then mkdir -p $dirpart/$fdir else as_dir=$dirpart/$fdir as_dirs= while test ! -d "$as_dir"; do as_dirs="$as_dir $as_dirs" as_dir=`(dirname "$as_dir") 2>/dev/null || $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$as_dir" : 'X\(//\)[^/]' \| \ X"$as_dir" : 'X\(//\)$' \| \ X"$as_dir" : 'X\(/\)' \| \ . : '\(.\)' 2>/dev/null || echo X"$as_dir" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; } /^X\(\/\/\)[^/].*/{ s//\1/; q; } /^X\(\/\/\)$/{ s//\1/; q; } /^X\(\/\).*/{ s//\1/; q; } s/.*/./; q'` done test ! -n "$as_dirs" || mkdir $as_dirs fi || { { echo "$as_me:$LINENO: error: cannot create directory $dirpart/$fdir" >&5 echo "$as_me: error: cannot create directory $dirpart/$fdir" >&2;} { (exit 1); exit 1; }; }; } # echo "creating $dirpart/$file" echo '# dummy' > "$dirpart/$file" done done ;; esac done _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF { (exit 0); exit 0; } _ACEOF chmod +x $CONFIG_STATUS ac_clean_files=$ac_clean_files_save # configure is writing to config.log, and then calls config.status. # config.status does its own redirection, appending to config.log. # Unfortunately, on DOS this fails, as config.log is still kept open # by configure, so config.status won't be able to write to it; its # output is simply discarded. So we exec the FD to /dev/null, # effectively closing config.log, so it can be properly (re)opened and # appended to by config.status. When coming back to configure, we # need to make the FD available again. if test "$no_create" != yes; then ac_cs_success=: ac_config_status_args= test "$silent" = yes && ac_config_status_args="$ac_config_status_args --quiet" exec 5>/dev/null $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false exec 5>>config.log # Use ||, not &&, to avoid exiting from the if with $? = 1, which # would make configure fail if this is the last instruction. $ac_cs_success || { (exit 1); exit 1; } fi rapache-1.2.8/libapreq2/configure.ac0000644000175100017510000000227512706745114016637 0ustar ondrejondrejdnl Process this file with autoconf to produce a configure script. AC_PREREQ(2.53) AC_INIT(Apache HTTP Server Request Library, 2.05-dev, apreq-dev@httpd.apache.org, libapreq2) dnl Generate config.nice script- macro must be here at the top dnl to avoid corruption of $0 and $@. APR_CONFIG_NICE(config.nice) dnl this: dnl AC_CONFIG_AUX_DIR(build) dnl causes problems on certain platforms dnl aclocal.m4:817: required file `build/ltmain.sh' not found dnl debian woody's archaic auto* tools don't set PACKAGE/VERSION correctly via dnl AC_INIT above, so we do it again here. AM_INIT_AUTOMAKE(libapreq2, 2.05-dev) AC_PROG_MAKE_SET dnl Checks for programs. AC_PROG_CC AM_PROG_LIBTOOL AC_PROG_RANLIB AC_PROG_INSTALL AC_PROG_LN_S AM_MAINTAINER_MODE dnl Checks for header files. AM_CONFIG_HEADER(include/apreq_config.h) dnl Checks for typedefs, structures, and compiler characteristics. dnl Checks for library functions. AC_APREQ AC_CONFIG_FILES([Makefile include/Makefile library/Makefile library/t/Makefile module/Makefile module/apache2/Makefile module/apache/Makefile glue/Makefile]) AC_CONFIG_FILES([build/doxygen.conf include/groups.dox]) AC_CONFIG_FILES([apreq2-config], [chmod +x apreq2-config]) AC_OUTPUT rapache-1.2.8/libapreq2/depcomp0000755000175100017510000002753312706745114015732 0ustar ondrejondrej#! /bin/sh # depcomp - compile a program generating dependencies as side-effects # Copyright 1999, 2000 Free Software Foundation, Inc. # 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, 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. # Originally written by Alexandre Oliva . if test -z "$depmode" || test -z "$source" || test -z "$object"; then echo "depcomp: Variables source, object and depmode must be set" 1>&2 exit 1 fi # `libtool' can also be set to `yes' or `no'. if test -z "$depfile"; then base=`echo "$object" | sed -e 's,^.*/,,' -e 's,\.\([^.]*\)$,.P\1,'` dir=`echo "$object" | sed 's,/.*$,/,'` if test "$dir" = "$object"; then dir= fi # FIXME: should be _deps on DOS. depfile="$dir.deps/$base" fi tmpdepfile=${tmpdepfile-`echo "$depfile" | sed 's/\.\([^.]*\)$/.T\1/'`} rm -f "$tmpdepfile" # Some modes work just like other modes, but use different flags. We # parameterize here, but still list the modes in the big case below, # to make depend.m4 easier to write. Note that we *cannot* use a case # here, because this file can only contain one case statement. if test "$depmode" = hp; then # HP compiler uses -M and no extra arg. gccflag=-M depmode=gcc fi if test "$depmode" = dashXmstdout; then # This is just like dashmstdout with a different argument. dashmflag=-xM depmode=dashmstdout fi case "$depmode" in gcc3) ## gcc 3 implements dependency tracking that does exactly what ## we want. Yay! Note: for some reason libtool 1.4 doesn't like ## it if -MD -MP comes after the -MF stuff. Hmm. "$@" -MT "$object" -MD -MP -MF "$tmpdepfile" stat=$? if test $stat -eq 0; then : else rm -f "$tmpdepfile" exit $stat fi mv "$tmpdepfile" "$depfile" ;; gcc) ## There are various ways to get dependency output from gcc. Here's ## why we pick this rather obscure method: ## - Don't want to use -MD because we'd like the dependencies to end ## up in a subdir. Having to rename by hand is ugly. ## (We might end up doing this anyway to support other compilers.) ## - The DEPENDENCIES_OUTPUT environment variable makes gcc act like ## -MM, not -M (despite what the docs say). ## - Using -M directly means running the compiler twice (even worse ## than renaming). if test -z "$gccflag"; then gccflag=-MD, fi "$@" -Wp,"$gccflag$tmpdepfile" stat=$? if test $stat -eq 0; then : else rm -f "$tmpdepfile" exit $stat fi rm -f "$depfile" echo "$object : \\" > "$depfile" alpha=ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz ## The second -e expression handles DOS-style file names with drive letters. sed -e 's/^[^:]*: / /' \ -e 's/^['$alpha']:\/[^:]*: / /' < "$tmpdepfile" >> "$depfile" ## This next piece of magic avoids the `deleted header file' problem. ## The problem is that when a header file which appears in a .P file ## is deleted, the dependency causes make to die (because there is ## typically no way to rebuild the header). We avoid this by adding ## dummy dependencies for each header file. Too bad gcc doesn't do ## this for us directly. tr ' ' ' ' < "$tmpdepfile" | ## Some versions of gcc put a space before the `:'. On the theory ## that the space means something, we add a space to the output as ## well. ## Some versions of the HPUX 10.20 sed can't process this invocation ## correctly. Breaking it into two sed invocations is a workaround. sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' | sed -e 's/$/ :/' >> "$depfile" rm -f "$tmpdepfile" ;; hp) # This case exists only to let depend.m4 do its work. It works by # looking at the text of this script. This case will never be run, # since it is checked for above. exit 1 ;; sgi) if test "$libtool" = yes; then "$@" "-Wp,-MDupdate,$tmpdepfile" else "$@" -MDupdate "$tmpdepfile" fi stat=$? if test $stat -eq 0; then : else rm -f "$tmpdepfile" exit $stat fi rm -f "$depfile" if test -f "$tmpdepfile"; then # yes, the sourcefile depend on other files echo "$object : \\" > "$depfile" # Clip off the initial element (the dependent). Don't try to be # clever and replace this with sed code, as IRIX sed won't handle # lines with more than a fixed number of characters (4096 in # IRIX 6.2 sed, 8192 in IRIX 6.5). We also remove comment lines; # the IRIX cc adds comments like `#:fec' to the end of the # dependency line. tr ' ' ' ' < "$tmpdepfile" \ | sed -e 's/^.*\.o://' -e 's/#.*$//' -e '/^$/ d' | \ tr ' ' ' ' >> $depfile echo >> $depfile # The second pass generates a dummy entry for each header file. tr ' ' ' ' < "$tmpdepfile" \ | sed -e 's/^.*\.o://' -e 's/#.*$//' -e '/^$/ d' -e 's/$/:/' \ >> $depfile else # The sourcefile does not contain any dependencies, so just # store a dummy comment line, to avoid errors with the Makefile # "include basename.Plo" scheme. echo "#dummy" > "$depfile" fi rm -f "$tmpdepfile" ;; aix) # The C for AIX Compiler uses -M and outputs the dependencies # in a .u file. This file always lives in the current directory. # Also, the AIX compiler puts `$object:' at the start of each line; # $object doesn't have directory information. stripped=`echo "$object" | sed -e 's,^.*/,,' -e 's/\(.*\)\..*$/\1/'` tmpdepfile="$stripped.u" outname="$stripped.o" if test "$libtool" = yes; then "$@" -Wc,-M else "$@" -M fi stat=$? if test $stat -eq 0; then : else rm -f "$tmpdepfile" exit $stat fi if test -f "$tmpdepfile"; then # Each line is of the form `foo.o: dependent.h'. # Do two passes, one to just change these to # `$object: dependent.h' and one to simply `dependent.h:'. sed -e "s,^$outname:,$object :," < "$tmpdepfile" > "$depfile" sed -e "s,^$outname: \(.*\)$,\1:," < "$tmpdepfile" >> "$depfile" else # The sourcefile does not contain any dependencies, so just # store a dummy comment line, to avoid errors with the Makefile # "include basename.Plo" scheme. echo "#dummy" > "$depfile" fi rm -f "$tmpdepfile" ;; tru64) # The Tru64 compiler uses -MD to generate dependencies as a side # effect. `cc -MD -o foo.o ...' puts the dependencies into `foo.o.d'. # At least on Alpha/Redhat 6.1, Compaq CCC V6.2-504 seems to put # dependencies in `foo.d' instead, so we check for that too. # Subdirectories are respected. dir=`echo "$object" | sed -e 's|/[^/]*$|/|'` test "x$dir" = "x$object" && dir= base=`echo "$object" | sed -e 's|^.*/||' -e 's/\.o$//' -e 's/\.lo$//'` if test "$libtool" = yes; then tmpdepfile1="$dir.libs/$base.lo.d" tmpdepfile2="$dir.libs/$base.d" "$@" -Wc,-MD else tmpdepfile1="$dir$base.o.d" tmpdepfile2="$dir$base.d" "$@" -MD fi stat=$? if test $stat -eq 0; then : else rm -f "$tmpdepfile1" "$tmpdepfile2" exit $stat fi if test -f "$tmpdepfile1"; then tmpdepfile="$tmpdepfile1" else tmpdepfile="$tmpdepfile2" fi if test -f "$tmpdepfile"; then sed -e "s,^.*\.[a-z]*:,$object:," < "$tmpdepfile" > "$depfile" # That's a space and a tab in the []. sed -e 's,^.*\.[a-z]*:[ ]*,,' -e 's,$,:,' < "$tmpdepfile" >> "$depfile" else echo "#dummy" > "$depfile" fi rm -f "$tmpdepfile" ;; #nosideeffect) # This comment above is used by automake to tell side-effect # dependency tracking mechanisms from slower ones. dashmstdout) # Important note: in order to support this mode, a compiler *must* # always write the proprocessed file to stdout, regardless of -o. "$@" || exit $? # Remove the call to Libtool. if test "$libtool" = yes; then while test $1 != '--mode=compile'; do shift done shift fi # Remove `-o $object'. We will use -o /dev/null later, # however we can't do the remplacement now because # `-o $object' might simply not be used IFS=" " for arg do case $arg in -o) shift ;; $object) shift ;; *) set fnord "$@" "$arg" shift # fnord shift # $arg ;; esac done test -z "$dashmflag" && dashmflag=-M "$@" -o /dev/null $dashmflag | sed 's:^[^:]*\:[ ]*:'"$object"'\: :' > "$tmpdepfile" rm -f "$depfile" cat < "$tmpdepfile" > "$depfile" tr ' ' ' ' < "$tmpdepfile" | \ ## Some versions of the HPUX 10.20 sed can't process this invocation ## correctly. Breaking it into two sed invocations is a workaround. sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' | sed -e 's/$/ :/' >> "$depfile" rm -f "$tmpdepfile" ;; dashXmstdout) # This case only exists to satisfy depend.m4. It is never actually # run, as this mode is specially recognized in the preamble. exit 1 ;; makedepend) "$@" || exit $? # X makedepend shift cleared=no for arg in "$@"; do case $cleared in no) set ""; shift cleared=yes ;; esac case "$arg" in -D*|-I*) set fnord "$@" "$arg"; shift ;; -*) ;; *) set fnord "$@" "$arg"; shift ;; esac done obj_suffix="`echo $object | sed 's/^.*\././'`" touch "$tmpdepfile" ${MAKEDEPEND-makedepend} -o"$obj_suffix" -f"$tmpdepfile" "$@" rm -f "$depfile" cat < "$tmpdepfile" > "$depfile" sed '1,2d' "$tmpdepfile" | tr ' ' ' ' | \ ## Some versions of the HPUX 10.20 sed can't process this invocation ## correctly. Breaking it into two sed invocations is a workaround. sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' | sed -e 's/$/ :/' >> "$depfile" rm -f "$tmpdepfile" "$tmpdepfile".bak ;; cpp) # Important note: in order to support this mode, a compiler *must* # always write the proprocessed file to stdout. "$@" || exit $? # Remove the call to Libtool. if test "$libtool" = yes; then while test $1 != '--mode=compile'; do shift done shift fi # Remove `-o $object'. IFS=" " for arg do case $arg in -o) shift ;; $object) shift ;; *) set fnord "$@" "$arg" shift # fnord shift # $arg ;; esac done "$@" -E | sed -n '/^# [0-9][0-9]* "\([^"]*\)".*/ s:: \1 \\:p' | sed '$ s: \\$::' > "$tmpdepfile" rm -f "$depfile" echo "$object : \\" > "$depfile" cat < "$tmpdepfile" >> "$depfile" sed < "$tmpdepfile" '/^$/d;s/^ //;s/ \\$//;s/$/ :/' >> "$depfile" rm -f "$tmpdepfile" ;; msvisualcpp) # Important note: in order to support this mode, a compiler *must* # always write the proprocessed file to stdout, regardless of -o, # because we must use -o when running libtool. "$@" || exit $? IFS=" " for arg do case "$arg" in "-Gm"|"/Gm"|"-Gi"|"/Gi"|"-ZI"|"/ZI") set fnord "$@" shift shift ;; *) set fnord "$@" "$arg" shift shift ;; esac done "$@" -E | sed -n '/^#line [0-9][0-9]* "\([^"]*\)"/ s::echo "`cygpath -u \\"\1\\"`":p' | sort | uniq > "$tmpdepfile" rm -f "$depfile" echo "$object : \\" > "$depfile" . "$tmpdepfile" | sed 's% %\\ %g' | sed -n '/^\(.*\)$/ s:: \1 \\:p' >> "$depfile" echo " " >> "$depfile" . "$tmpdepfile" | sed 's% %\\ %g' | sed -n '/^\(.*\)$/ s::\1\::p' >> "$depfile" rm -f "$tmpdepfile" ;; none) exec "$@" ;; *) echo "Unknown depmode $depmode" 1>&2 exit 1 ;; esac exit 0 rapache-1.2.8/libapreq2/docs/0000755000175100017510000000000012706745114015273 5ustar ondrejondrejrapache-1.2.8/libapreq2/docs/apr.tag0000644000175100017510000207415312706745114016566 0ustar ondrejondrej apr.h /home/joe/src/apache/apr/apr/trunk/include/ apr_8h #define APR_INLINE group__apr__platform.html ga11 #define APR_HAS_INLINE group__apr__platform.html ga12 #define APR_HAVE_ARPA_INET_H group__apr__platform.html ga13 #define APR_HAVE_CONIO_H group__apr__platform.html ga14 #define APR_HAVE_CRYPT_H group__apr__platform.html ga15 #define APR_HAVE_CTYPE_H group__apr__platform.html ga16 #define APR_HAVE_DIRENT_H group__apr__platform.html ga17 #define APR_HAVE_ERRNO_H group__apr__platform.html ga18 #define APR_HAVE_FCNTL_H group__apr__platform.html ga19 #define APR_HAVE_IO_H group__apr__platform.html ga20 #define APR_HAVE_LIMITS_H group__apr__platform.html ga21 #define APR_HAVE_NETDB_H group__apr__platform.html ga22 #define APR_HAVE_NETINET_IN_H group__apr__platform.html ga23 #define APR_HAVE_NETINET_SCTP_H group__apr__platform.html ga24 #define APR_HAVE_NETINET_SCTP_UIO_H group__apr__platform.html ga25 #define APR_HAVE_NETINET_TCP_H group__apr__platform.html ga26 #define APR_HAVE_PTHREAD_H group__apr__platform.html ga27 #define APR_HAVE_SEMAPHORE_H group__apr__platform.html ga28 #define APR_HAVE_SIGNAL_H group__apr__platform.html ga29 #define APR_HAVE_STDARG_H group__apr__platform.html ga30 #define APR_HAVE_STDINT_H group__apr__platform.html ga31 #define APR_HAVE_STDIO_H group__apr__platform.html ga32 #define APR_HAVE_STDLIB_H group__apr__platform.html ga33 #define APR_HAVE_STRING_H group__apr__platform.html ga34 #define APR_HAVE_STRINGS_H group__apr__platform.html ga35 #define APR_HAVE_SYS_IOCTL_H group__apr__platform.html ga36 #define APR_HAVE_SYS_SENDFILE_H group__apr__platform.html ga37 #define APR_HAVE_SYS_SIGNAL_H group__apr__platform.html ga38 #define APR_HAVE_SYS_SOCKET_H group__apr__platform.html ga39 #define APR_HAVE_SYS_SOCKIO_H group__apr__platform.html ga40 #define APR_HAVE_SYS_SYSLIMITS_H group__apr__platform.html ga41 #define APR_HAVE_SYS_TIME_H group__apr__platform.html ga42 #define APR_HAVE_SYS_TYPES_H group__apr__platform.html ga43 #define APR_HAVE_SYS_UIO_H group__apr__platform.html ga44 #define APR_HAVE_SYS_UN_H group__apr__platform.html ga45 #define APR_HAVE_SYS_WAIT_H group__apr__platform.html ga46 #define APR_HAVE_TIME_H group__apr__platform.html ga47 #define APR_HAVE_UNISTD_H group__apr__platform.html ga48 #define APR_HAVE_SHMEM_MMAP_TMP group__apr__platform.html ga49 #define APR_HAVE_SHMEM_MMAP_SHM group__apr__platform.html ga50 #define APR_HAVE_SHMEM_MMAP_ZERO group__apr__platform.html ga51 #define APR_HAVE_SHMEM_SHMGET_ANON group__apr__platform.html ga52 #define APR_HAVE_SHMEM_SHMGET group__apr__platform.html ga53 #define APR_HAVE_SHMEM_MMAP_ANON group__apr__platform.html ga54 #define APR_HAVE_SHMEM_BEOS group__apr__platform.html ga55 #define APR_USE_SHMEM_MMAP_TMP group__apr__platform.html ga56 #define APR_USE_SHMEM_MMAP_SHM group__apr__platform.html ga57 #define APR_USE_SHMEM_MMAP_ZERO group__apr__platform.html ga58 #define APR_USE_SHMEM_SHMGET_ANON group__apr__platform.html ga59 #define APR_USE_SHMEM_SHMGET group__apr__platform.html ga60 #define APR_USE_SHMEM_MMAP_ANON group__apr__platform.html ga61 #define APR_USE_SHMEM_BEOS group__apr__platform.html ga62 #define APR_USE_FLOCK_SERIALIZE group__apr__platform.html ga63 #define APR_USE_SYSVSEM_SERIALIZE group__apr__platform.html ga64 #define APR_USE_POSIXSEM_SERIALIZE group__apr__platform.html ga65 #define APR_USE_FCNTL_SERIALIZE group__apr__platform.html ga66 #define APR_USE_PROC_PTHREAD_SERIALIZE group__apr__platform.html ga67 #define APR_USE_PTHREAD_SERIALIZE group__apr__platform.html ga68 #define APR_HAS_FLOCK_SERIALIZE group__apr__platform.html ga69 #define APR_HAS_SYSVSEM_SERIALIZE group__apr__platform.html ga70 #define APR_HAS_POSIXSEM_SERIALIZE group__apr__platform.html ga71 #define APR_HAS_FCNTL_SERIALIZE group__apr__platform.html ga72 #define APR_HAS_PROC_PTHREAD_SERIALIZE group__apr__platform.html ga73 #define APR_PROCESS_LOCK_IS_GLOBAL group__apr__platform.html ga74 #define APR_HAVE_CORKABLE_TCP group__apr__platform.html ga75 #define APR_HAVE_GETRLIMIT group__apr__platform.html ga76 #define APR_HAVE_IN_ADDR group__apr__platform.html ga77 #define APR_HAVE_INET_ADDR group__apr__platform.html ga78 #define APR_HAVE_INET_NETWORK group__apr__platform.html ga79 #define APR_HAVE_IPV6 group__apr__platform.html ga80 #define APR_HAVE_MEMMOVE group__apr__platform.html ga81 #define APR_HAVE_SETRLIMIT group__apr__platform.html ga82 #define APR_HAVE_SIGACTION group__apr__platform.html ga83 #define APR_HAVE_SIGSUSPEND group__apr__platform.html ga84 #define APR_HAVE_SIGWAIT group__apr__platform.html ga85 #define APR_HAVE_SA_STORAGE group__apr__platform.html ga86 #define APR_HAVE_STRCASECMP group__apr__platform.html ga87 #define APR_HAVE_STRDUP group__apr__platform.html ga88 #define APR_HAVE_STRICMP group__apr__platform.html ga89 #define APR_HAVE_STRNCASECMP group__apr__platform.html ga90 #define APR_HAVE_STRNICMP group__apr__platform.html ga91 #define APR_HAVE_STRSTR group__apr__platform.html ga92 #define APR_HAVE_MEMCHR group__apr__platform.html ga93 #define APR_HAVE_STRUCT_RLIMIT group__apr__platform.html ga94 #define APR_HAVE_UNION_SEMUN group__apr__platform.html ga95 #define APR_HAVE_SCTP group__apr__platform.html ga96 #define APR_HAS_SHARED_MEMORY group__apr__platform.html ga97 #define APR_HAS_THREADS group__apr__platform.html ga98 #define APR_HAS_SENDFILE group__apr__platform.html ga99 #define APR_HAS_MMAP group__apr__platform.html ga100 #define APR_HAS_FORK group__apr__platform.html ga101 #define APR_HAS_RANDOM group__apr__platform.html ga102 #define APR_HAS_OTHER_CHILD group__apr__platform.html ga103 #define APR_HAS_DSO group__apr__platform.html ga104 #define APR_HAS_SO_ACCEPTFILTER group__apr__platform.html ga105 #define APR_HAS_UNICODE_FS group__apr__platform.html ga106 #define APR_HAS_PROC_INVOKED group__apr__platform.html ga107 #define APR_HAS_USER group__apr__platform.html ga108 #define APR_HAS_LARGE_FILES group__apr__platform.html ga109 #define APR_HAS_XTHREAD_FILES group__apr__platform.html ga110 #define APR_HAS_OS_UUID group__apr__platform.html ga111 #define APR_FILES_AS_SOCKETS group__apr__platform.html ga112 #define APR_CHARSET_EBCDIC group__apr__platform.html ga113 #define APR_TCP_NOPUSH_FLAG group__apr__platform.html ga114 #define APR_TCP_NODELAY_INHERITED group__apr__platform.html ga115 #define APR_O_NONBLOCK_INHERITED group__apr__platform.html ga116 #define APR_SIZEOF_VOIDP group__apr__platform.html ga117 #define APR_IS_BIGENDIAN group__apr__platform.html ga118 #define APR_INT64_C group__apr__platform.html ga119 (val) #define APR_UINT64_C group__apr__platform.html ga120 (val) #define APR_THREAD_FUNC group__apr__platform.html ga121 #define APR_DECLARE group__apr__platform.html ga122 (type) #define APR_DECLARE_NONSTD group__apr__platform.html ga123 (type) #define APR_DECLARE_DATA group__apr__platform.html ga124 #define APR_SSIZE_T_FMT group__apr__platform.html ga125 #define APR_SIZE_T_FMT group__apr__platform.html ga126 #define APR_OFF_T_FMT group__apr__platform.html ga127 #define APR_PID_T_FMT group__apr__platform.html ga128 #define APR_INT64_T_FMT group__apr__platform.html ga129 #define APR_UINT64_T_FMT group__apr__platform.html ga130 #define APR_UINT64_T_HEX_FMT group__apr__platform.html ga131 #define APR_PROC_MUTEX_IS_GLOBAL group__apr__platform.html ga132 #define APR_EOL_STR group__apr__platform.html ga133 #define apr_wait_t group__apr__platform.html ga134 #define WEXITSTATUS group__apr__platform.html ga135 (status) #define WTERMSIG group__apr__platform.html ga136 (status) unsigned char apr_byte_t group__apr__platform.html ga0 short apr_int16_t group__apr__platform.html ga1 unsigned short apr_uint16_t group__apr__platform.html ga2 int apr_int32_t group__apr__platform.html ga3 unsigned int apr_uint32_t group__apr__platform.html ga4 long apr_int64_t group__apr__platform.html ga5 unsigned long apr_uint64_t group__apr__platform.html ga6 size_t apr_size_t group__apr__platform.html ga7 ssize_t apr_ssize_t group__apr__platform.html ga8 off_t apr_off_t group__apr__platform.html ga9 socklen_t apr_socklen_t group__apr__platform.html ga10 apr_allocator.h /home/joe/src/apache/apr/apr/trunk/include/ apr__allocator_8h apr.h apr_errno.h apr_want.h apr_pools.h apr_thread_mutex.h #define APR_WANT_MEMFUNC apr__allocator_8h.html a0 #define APR_MEMNODE_T_SIZE group__apr__allocator.html ga11 #define APR_ALLOCATOR_MAX_FREE_UNLIMITED group__apr__allocator.html ga12 apr_allocator_t apr_allocator_t group__apr__allocator.html ga0 apr_memnode_t apr_memnode_t group__apr__allocator.html ga1 apr_status_t apr_allocator_create group__apr__allocator.html ga2 (apr_allocator_t **allocator) void apr_allocator_destroy group__apr__allocator.html ga3 (apr_allocator_t *allocator) apr_memnode_t * apr_allocator_alloc group__apr__allocator.html ga4 (apr_allocator_t *allocator, apr_size_t size) void apr_allocator_free group__apr__allocator.html ga5 (apr_allocator_t *allocator, apr_memnode_t *memnode) void apr_allocator_owner_set group__apr__allocator.html ga6 (apr_allocator_t *allocator, apr_pool_t *pool) apr_pool_t * apr_allocator_owner_get group__apr__allocator.html ga7 (apr_allocator_t *allocator) void apr_allocator_max_free_set group__apr__allocator.html ga8 (apr_allocator_t *allocator, apr_size_t size) void apr_allocator_mutex_set group__apr__allocator.html ga9 (apr_allocator_t *allocator, apr_thread_mutex_t *mutex) apr_thread_mutex_t * apr_allocator_mutex_get group__apr__allocator.html ga10 (apr_allocator_t *allocator) apr_atomic.h /home/joe/src/apache/apr/apr/trunk/include/ apr__atomic_8h apr.h apr_pools.h apr_status_t apr_atomic_init group__apr__atomic.html ga0 (apr_pool_t *p) apr_uint32_t apr_atomic_read32 group__apr__atomic.html ga1 (volatile apr_uint32_t *mem) void apr_atomic_set32 group__apr__atomic.html ga2 (volatile apr_uint32_t *mem, apr_uint32_t val) apr_uint32_t apr_atomic_add32 group__apr__atomic.html ga3 (volatile apr_uint32_t *mem, apr_uint32_t val) void apr_atomic_sub32 group__apr__atomic.html ga4 (volatile apr_uint32_t *mem, apr_uint32_t val) apr_uint32_t apr_atomic_inc32 group__apr__atomic.html ga5 (volatile apr_uint32_t *mem) int apr_atomic_dec32 group__apr__atomic.html ga6 (volatile apr_uint32_t *mem) apr_uint32_t apr_atomic_cas32 group__apr__atomic.html ga7 (volatile apr_uint32_t *mem, apr_uint32_t with, apr_uint32_t cmp) apr_uint32_t apr_atomic_xchg32 group__apr__atomic.html ga8 (volatile apr_uint32_t *mem, apr_uint32_t val) void * apr_atomic_casptr group__apr__atomic.html ga9 (volatile void **mem, void *with, const void *cmp) apr_dso.h /home/joe/src/apache/apr/apr/trunk/include/ apr__dso_8h apr.h apr_pools.h apr_errno.h apr_dso_handle_t apr_dso_handle_t group__apr__dso.html ga0 void * apr_dso_handle_sym_t group__apr__dso.html ga1 apr_status_t apr_dso_load group__apr__dso.html ga2 (apr_dso_handle_t **res_handle, const char *path, apr_pool_t *ctx) apr_status_t apr_dso_unload group__apr__dso.html ga3 (apr_dso_handle_t *handle) apr_status_t apr_dso_sym group__apr__dso.html ga4 (apr_dso_handle_sym_t *ressym, apr_dso_handle_t *handle, const char *symname) const char * apr_dso_error group__apr__dso.html ga5 (apr_dso_handle_t *dso, char *buf, apr_size_t bufsize) apr_env.h /home/joe/src/apache/apr/apr/trunk/include/ apr__env_8h apr_errno.h apr_pools.h apr_status_t apr_env_get group__apr__env.html ga0 (char **value, const char *envvar, apr_pool_t *pool) apr_status_t apr_env_set group__apr__env.html ga1 (const char *envvar, const char *value, apr_pool_t *pool) apr_status_t apr_env_delete group__apr__env.html ga2 (const char *envvar, apr_pool_t *pool) apr_errno.h /home/joe/src/apache/apr/apr/trunk/include/ apr__errno_8h apr.h #define APR_FROM_OS_ERROR group__apr__errno.html ga2 (e) #define APR_TO_OS_ERROR group__apr__errno.html ga4 (e) #define APR_OS_START_ERROR group__apr__errno.html ga10 #define APR_OS_ERRSPACE_SIZE group__apr__errno.html ga11 #define APR_OS_START_STATUS group__apr__errno.html ga12 #define APR_OS_START_USERERR group__apr__errno.html ga13 #define APR_OS_START_USEERR group__apr__errno.html ga14 #define APR_OS_START_CANONERR group__apr__errno.html ga15 #define APR_OS_START_EAIERR group__apr__errno.html ga16 #define APR_OS_START_SYSERR group__apr__errno.html ga17 #define APR_SUCCESS group__apr__errno.html ga18 #define APR_ENOSTAT group___a_p_r___error.html ga0 #define APR_ENOPOOL group___a_p_r___error.html ga1 #define APR_EBADDATE group___a_p_r___error.html ga2 #define APR_EINVALSOCK group___a_p_r___error.html ga3 #define APR_ENOPROC group___a_p_r___error.html ga4 #define APR_ENOTIME group___a_p_r___error.html ga5 #define APR_ENODIR group___a_p_r___error.html ga6 #define APR_ENOLOCK group___a_p_r___error.html ga7 #define APR_ENOPOLL group___a_p_r___error.html ga8 #define APR_ENOSOCKET group___a_p_r___error.html ga9 #define APR_ENOTHREAD group___a_p_r___error.html ga10 #define APR_ENOTHDKEY group___a_p_r___error.html ga11 #define APR_EGENERAL group___a_p_r___error.html ga12 #define APR_ENOSHMAVAIL group___a_p_r___error.html ga13 #define APR_EBADIP group___a_p_r___error.html ga14 #define APR_EBADMASK group___a_p_r___error.html ga15 #define APR_EDSOOPEN group___a_p_r___error.html ga16 #define APR_EABSOLUTE group___a_p_r___error.html ga17 #define APR_ERELATIVE group___a_p_r___error.html ga18 #define APR_EINCOMPLETE group___a_p_r___error.html ga19 #define APR_EABOVEROOT group___a_p_r___error.html ga20 #define APR_EBADPATH group___a_p_r___error.html ga21 #define APR_EPATHWILD group___a_p_r___error.html ga22 #define APR_ESYMNOTFOUND group___a_p_r___error.html ga23 #define APR_EPROC_UNKNOWN group___a_p_r___error.html ga24 #define APR_ENOTENOUGHENTROPY group___a_p_r___error.html ga25 #define APR_STATUS_IS_ENOSTAT group___a_p_r___s_t_a_t_u_s___i_s.html ga0 (s) #define APR_STATUS_IS_ENOPOOL group___a_p_r___s_t_a_t_u_s___i_s.html ga1 (s) #define APR_STATUS_IS_EBADDATE group___a_p_r___s_t_a_t_u_s___i_s.html ga2 (s) #define APR_STATUS_IS_EINVALSOCK group___a_p_r___s_t_a_t_u_s___i_s.html ga3 (s) #define APR_STATUS_IS_ENOPROC group___a_p_r___s_t_a_t_u_s___i_s.html ga4 (s) #define APR_STATUS_IS_ENOTIME group___a_p_r___s_t_a_t_u_s___i_s.html ga5 (s) #define APR_STATUS_IS_ENODIR group___a_p_r___s_t_a_t_u_s___i_s.html ga6 (s) #define APR_STATUS_IS_ENOLOCK group___a_p_r___s_t_a_t_u_s___i_s.html ga7 (s) #define APR_STATUS_IS_ENOPOLL group___a_p_r___s_t_a_t_u_s___i_s.html ga8 (s) #define APR_STATUS_IS_ENOSOCKET group___a_p_r___s_t_a_t_u_s___i_s.html ga9 (s) #define APR_STATUS_IS_ENOTHREAD group___a_p_r___s_t_a_t_u_s___i_s.html ga10 (s) #define APR_STATUS_IS_ENOTHDKEY group___a_p_r___s_t_a_t_u_s___i_s.html ga11 (s) #define APR_STATUS_IS_EGENERAL group___a_p_r___s_t_a_t_u_s___i_s.html ga12 (s) #define APR_STATUS_IS_ENOSHMAVAIL group___a_p_r___s_t_a_t_u_s___i_s.html ga13 (s) #define APR_STATUS_IS_EBADIP group___a_p_r___s_t_a_t_u_s___i_s.html ga14 (s) #define APR_STATUS_IS_EBADMASK group___a_p_r___s_t_a_t_u_s___i_s.html ga15 (s) #define APR_STATUS_IS_EDSOOPEN group___a_p_r___s_t_a_t_u_s___i_s.html ga16 (s) #define APR_STATUS_IS_EABSOLUTE group___a_p_r___s_t_a_t_u_s___i_s.html ga17 (s) #define APR_STATUS_IS_ERELATIVE group___a_p_r___s_t_a_t_u_s___i_s.html ga18 (s) #define APR_STATUS_IS_EINCOMPLETE group___a_p_r___s_t_a_t_u_s___i_s.html ga19 (s) #define APR_STATUS_IS_EABOVEROOT group___a_p_r___s_t_a_t_u_s___i_s.html ga20 (s) #define APR_STATUS_IS_EBADPATH group___a_p_r___s_t_a_t_u_s___i_s.html ga21 (s) #define APR_STATUS_IS_EPATHWILD group___a_p_r___s_t_a_t_u_s___i_s.html ga22 (s) #define APR_STATUS_IS_ESYMNOTFOUND group___a_p_r___s_t_a_t_u_s___i_s.html ga23 (s) #define APR_STATUS_IS_EPROC_UNKNOWN group___a_p_r___s_t_a_t_u_s___i_s.html ga24 (s) #define APR_STATUS_IS_ENOTENOUGHENTROPY group___a_p_r___s_t_a_t_u_s___i_s.html ga25 (s) #define APR_INCHILD group___a_p_r___error.html ga26 #define APR_INPARENT group___a_p_r___error.html ga27 #define APR_DETACH group___a_p_r___error.html ga28 #define APR_NOTDETACH group___a_p_r___error.html ga29 #define APR_CHILD_DONE group___a_p_r___error.html ga30 #define APR_CHILD_NOTDONE group___a_p_r___error.html ga31 #define APR_TIMEUP group___a_p_r___error.html ga32 #define APR_INCOMPLETE group___a_p_r___error.html ga33 #define APR_BADCH group___a_p_r___error.html ga34 #define APR_BADARG group___a_p_r___error.html ga35 #define APR_EOF group___a_p_r___error.html ga36 #define APR_NOTFOUND group___a_p_r___error.html ga37 #define APR_ANONYMOUS group___a_p_r___error.html ga38 #define APR_FILEBASED group___a_p_r___error.html ga39 #define APR_KEYBASED group___a_p_r___error.html ga40 #define APR_EINIT group___a_p_r___error.html ga41 #define APR_ENOTIMPL group___a_p_r___error.html ga42 #define APR_EMISMATCH group___a_p_r___error.html ga43 #define APR_EBUSY group___a_p_r___error.html ga44 #define APR_STATUS_IS_INCHILD group___a_p_r___s_t_a_t_u_s___i_s.html ga26 (s) #define APR_STATUS_IS_INPARENT group___a_p_r___s_t_a_t_u_s___i_s.html ga27 (s) #define APR_STATUS_IS_DETACH group___a_p_r___s_t_a_t_u_s___i_s.html ga28 (s) #define APR_STATUS_IS_NOTDETACH group___a_p_r___s_t_a_t_u_s___i_s.html ga29 (s) #define APR_STATUS_IS_CHILD_DONE group___a_p_r___s_t_a_t_u_s___i_s.html ga30 (s) #define APR_STATUS_IS_CHILD_NOTDONE group___a_p_r___s_t_a_t_u_s___i_s.html ga31 (s) #define APR_STATUS_IS_TIMEUP group___a_p_r___s_t_a_t_u_s___i_s.html ga32 (s) #define APR_STATUS_IS_INCOMPLETE group___a_p_r___s_t_a_t_u_s___i_s.html ga33 (s) #define APR_STATUS_IS_BADCH group___a_p_r___s_t_a_t_u_s___i_s.html ga34 (s) #define APR_STATUS_IS_BADARG group___a_p_r___s_t_a_t_u_s___i_s.html ga35 (s) #define APR_STATUS_IS_EOF group___a_p_r___s_t_a_t_u_s___i_s.html ga36 (s) #define APR_STATUS_IS_NOTFOUND group___a_p_r___s_t_a_t_u_s___i_s.html ga37 (s) #define APR_STATUS_IS_ANONYMOUS group___a_p_r___s_t_a_t_u_s___i_s.html ga38 (s) #define APR_STATUS_IS_FILEBASED group___a_p_r___s_t_a_t_u_s___i_s.html ga39 (s) #define APR_STATUS_IS_KEYBASED group___a_p_r___s_t_a_t_u_s___i_s.html ga40 (s) #define APR_STATUS_IS_EINIT group___a_p_r___s_t_a_t_u_s___i_s.html ga41 (s) #define APR_STATUS_IS_ENOTIMPL group___a_p_r___s_t_a_t_u_s___i_s.html ga42 (s) #define APR_STATUS_IS_EMISMATCH group___a_p_r___s_t_a_t_u_s___i_s.html ga43 (s) #define APR_STATUS_IS_EBUSY group___a_p_r___s_t_a_t_u_s___i_s.html ga44 (s) #define APR_EACCES group___a_p_r___error.html ga45 #define APR_EEXIST group___a_p_r___error.html ga46 #define APR_ENAMETOOLONG group___a_p_r___error.html ga47 #define APR_ENOENT group___a_p_r___error.html ga48 #define APR_ENOTDIR group___a_p_r___error.html ga49 #define APR_ENOSPC group___a_p_r___error.html ga50 #define APR_ENOMEM group___a_p_r___error.html ga51 #define APR_EMFILE group___a_p_r___error.html ga52 #define APR_ENFILE group___a_p_r___error.html ga53 #define APR_EBADF group___a_p_r___error.html ga54 #define APR_EINVAL group___a_p_r___error.html ga55 #define APR_ESPIPE group___a_p_r___error.html ga56 #define APR_EAGAIN group___a_p_r___error.html ga57 #define APR_EINTR group___a_p_r___error.html ga58 #define APR_ENOTSOCK group___a_p_r___error.html ga59 #define APR_ECONNREFUSED group___a_p_r___error.html ga60 #define APR_EINPROGRESS group___a_p_r___error.html ga61 #define APR_ECONNABORTED group___a_p_r___error.html ga62 #define APR_ECONNRESET group___a_p_r___error.html ga63 #define APR_ETIMEDOUT group___a_p_r___error.html ga64 #define APR_EHOSTUNREACH group___a_p_r___error.html ga65 #define APR_ENETUNREACH group___a_p_r___error.html ga66 #define APR_EFTYPE group___a_p_r___error.html ga67 #define APR_EPIPE group___a_p_r___error.html ga68 #define APR_EXDEV group___a_p_r___error.html ga69 #define APR_ENOTEMPTY group___a_p_r___error.html ga70 #define APR_FROM_OS_ERROR group__apr__errno.html ga3 (e) #define APR_TO_OS_ERROR group__apr__errno.html ga5 (e) #define apr_get_os_error group__apr__errno.html ga6 () #define apr_set_os_error group__apr__errno.html ga7 (e) #define apr_get_netos_error group__apr__errno.html ga8 () #define apr_set_netos_error group__apr__errno.html ga9 (e) #define APR_STATUS_IS_EACCES group___a_p_r___s_t_a_t_u_s___i_s.html ga45 (s) #define APR_STATUS_IS_EEXIST group___a_p_r___s_t_a_t_u_s___i_s.html ga46 (s) #define APR_STATUS_IS_ENAMETOOLONG group___a_p_r___s_t_a_t_u_s___i_s.html ga47 (s) #define APR_STATUS_IS_ENOENT group___a_p_r___s_t_a_t_u_s___i_s.html ga48 (s) #define APR_STATUS_IS_ENOTDIR group___a_p_r___s_t_a_t_u_s___i_s.html ga49 (s) #define APR_STATUS_IS_ENOSPC group___a_p_r___s_t_a_t_u_s___i_s.html ga50 (s) #define APR_STATUS_IS_ENOMEM group___a_p_r___s_t_a_t_u_s___i_s.html ga51 (s) #define APR_STATUS_IS_EMFILE group___a_p_r___s_t_a_t_u_s___i_s.html ga52 (s) #define APR_STATUS_IS_ENFILE group___a_p_r___s_t_a_t_u_s___i_s.html ga53 (s) #define APR_STATUS_IS_EBADF group___a_p_r___s_t_a_t_u_s___i_s.html ga54 (s) #define APR_STATUS_IS_EINVAL group___a_p_r___s_t_a_t_u_s___i_s.html ga55 (s) #define APR_STATUS_IS_ESPIPE group___a_p_r___s_t_a_t_u_s___i_s.html ga56 (s) #define APR_STATUS_IS_EAGAIN group___a_p_r___s_t_a_t_u_s___i_s.html ga57 (s) #define APR_STATUS_IS_EINTR group___a_p_r___s_t_a_t_u_s___i_s.html ga58 (s) #define APR_STATUS_IS_ENOTSOCK group___a_p_r___s_t_a_t_u_s___i_s.html ga59 (s) #define APR_STATUS_IS_ECONNREFUSED group___a_p_r___s_t_a_t_u_s___i_s.html ga60 (s) #define APR_STATUS_IS_EINPROGRESS group___a_p_r___s_t_a_t_u_s___i_s.html ga61 (s) #define APR_STATUS_IS_ECONNABORTED group___a_p_r___s_t_a_t_u_s___i_s.html ga62 (s) #define APR_STATUS_IS_ECONNRESET group___a_p_r___s_t_a_t_u_s___i_s.html ga63 (s) #define APR_STATUS_IS_ETIMEDOUT group___a_p_r___s_t_a_t_u_s___i_s.html ga64 (s) #define APR_STATUS_IS_EHOSTUNREACH group___a_p_r___s_t_a_t_u_s___i_s.html ga65 (s) #define APR_STATUS_IS_ENETUNREACH group___a_p_r___s_t_a_t_u_s___i_s.html ga66 (s) #define APR_STATUS_IS_EFTYPE group___a_p_r___s_t_a_t_u_s___i_s.html ga67 (s) #define APR_STATUS_IS_EPIPE group___a_p_r___s_t_a_t_u_s___i_s.html ga68 (s) #define APR_STATUS_IS_EXDEV group___a_p_r___s_t_a_t_u_s___i_s.html ga69 (s) #define APR_STATUS_IS_ENOTEMPTY group___a_p_r___s_t_a_t_u_s___i_s.html ga70 (s) int apr_status_t group__apr__errno.html ga0 char * apr_strerror group__apr__errno.html ga1 (apr_status_t statcode, char *buf, apr_size_t bufsize) apr_file_info.h /home/joe/src/apache/apr/apr/trunk/include/ apr__file__info_8h apr.h apr_user.h apr_pools.h apr_tables.h apr_time.h apr_errno.h #define APR_FPROT_USETID group__apr__file__permissions.html ga0 #define APR_FPROT_UREAD group__apr__file__permissions.html ga1 #define APR_FPROT_UWRITE group__apr__file__permissions.html ga2 #define APR_FPROT_UEXECUTE group__apr__file__permissions.html ga3 #define APR_FPROT_GSETID group__apr__file__permissions.html ga4 #define APR_FPROT_GREAD group__apr__file__permissions.html ga5 #define APR_FPROT_GWRITE group__apr__file__permissions.html ga6 #define APR_FPROT_GEXECUTE group__apr__file__permissions.html ga7 #define APR_FPROT_WSTICKY group__apr__file__permissions.html ga8 #define APR_FPROT_WREAD group__apr__file__permissions.html ga9 #define APR_FPROT_WWRITE group__apr__file__permissions.html ga10 #define APR_FPROT_WEXECUTE group__apr__file__permissions.html ga11 #define APR_FPROT_OS_DEFAULT group__apr__file__permissions.html ga12 #define APR_FPROT_FILE_SOURCE_PERMS group__apr__file__permissions.html ga13 #define APR_USETID group__apr__file__permissions.html ga14 #define APR_UREAD group__apr__file__permissions.html ga15 #define APR_UWRITE group__apr__file__permissions.html ga16 #define APR_UEXECUTE group__apr__file__permissions.html ga17 #define APR_GSETID group__apr__file__permissions.html ga18 #define APR_GREAD group__apr__file__permissions.html ga19 #define APR_GWRITE group__apr__file__permissions.html ga20 #define APR_GEXECUTE group__apr__file__permissions.html ga21 #define APR_WSTICKY group__apr__file__permissions.html ga22 #define APR_WREAD group__apr__file__permissions.html ga23 #define APR_WWRITE group__apr__file__permissions.html ga24 #define APR_WEXECUTE group__apr__file__permissions.html ga25 #define APR_OS_DEFAULT group__apr__file__permissions.html ga26 #define APR_FILE_SOURCE_PERMS group__apr__file__permissions.html ga27 #define APR_FINFO_LINK group__apr__file__stat.html ga2 #define APR_FINFO_MTIME group__apr__file__stat.html ga3 #define APR_FINFO_CTIME group__apr__file__stat.html ga4 #define APR_FINFO_ATIME group__apr__file__stat.html ga5 #define APR_FINFO_SIZE group__apr__file__stat.html ga6 #define APR_FINFO_CSIZE group__apr__file__stat.html ga7 #define APR_FINFO_DEV group__apr__file__stat.html ga8 #define APR_FINFO_INODE group__apr__file__stat.html ga9 #define APR_FINFO_NLINK group__apr__file__stat.html ga10 #define APR_FINFO_TYPE group__apr__file__stat.html ga11 #define APR_FINFO_USER group__apr__file__stat.html ga12 #define APR_FINFO_GROUP group__apr__file__stat.html ga13 #define APR_FINFO_UPROT group__apr__file__stat.html ga14 #define APR_FINFO_GPROT group__apr__file__stat.html ga15 #define APR_FINFO_WPROT group__apr__file__stat.html ga16 #define APR_FINFO_ICASE group__apr__file__stat.html ga17 #define APR_FINFO_NAME group__apr__file__stat.html ga18 #define APR_FINFO_MIN group__apr__file__stat.html ga19 #define APR_FINFO_IDENT group__apr__file__stat.html ga20 #define APR_FINFO_OWNER group__apr__file__stat.html ga21 #define APR_FINFO_PROT group__apr__file__stat.html ga22 #define APR_FINFO_NORM group__apr__file__stat.html ga23 #define APR_FINFO_DIRENT group__apr__file__stat.html ga24 #define APR_FILEPATH_NOTABOVEROOT group__apr__filepath.html ga7 #define APR_FILEPATH_SECUREROOTTEST group__apr__filepath.html ga8 #define APR_FILEPATH_SECUREROOT group__apr__filepath.html ga9 #define APR_FILEPATH_NOTRELATIVE group__apr__filepath.html ga10 #define APR_FILEPATH_NOTABSOLUTE group__apr__filepath.html ga11 #define APR_FILEPATH_NATIVE group__apr__filepath.html ga12 #define APR_FILEPATH_TRUENAME group__apr__filepath.html ga13 #define APR_FILEPATH_ENCODING_UNKNOWN group__apr__filepath.html ga14 #define APR_FILEPATH_ENCODING_LOCALE group__apr__filepath.html ga15 #define APR_FILEPATH_ENCODING_UTF8 group__apr__filepath.html ga16 apr_dir_t apr_dir_t group__apr__file__info.html ga0 apr_int32_t apr_fileperms_t group__apr__file__info.html ga1 ino_t apr_ino_t group__apr__file__info.html ga2 dev_t apr_dev_t group__apr__file__info.html ga3 apr_finfo_t apr_finfo_t group__apr__file__stat.html ga0 apr_filetype_e ga4 APR_NOFILE gga4a66 APR_REG gga4a67 APR_DIR gga4a68 APR_CHR gga4a69 APR_BLK gga4a70 APR_PIPE gga4a71 APR_LNK gga4a72 APR_SOCK gga4a73 APR_UNKFILE gga4a74 apr_status_t apr_stat group__apr__file__stat.html ga1 (apr_finfo_t *finfo, const char *fname, apr_int32_t wanted, apr_pool_t *pool) apr_status_t apr_dir_open group__apr__dir.html ga0 (apr_dir_t **new_dir, const char *dirname, apr_pool_t *pool) apr_status_t apr_dir_close group__apr__dir.html ga1 (apr_dir_t *thedir) apr_status_t apr_dir_read group__apr__dir.html ga2 (apr_finfo_t *finfo, apr_int32_t wanted, apr_dir_t *thedir) apr_status_t apr_dir_rewind group__apr__dir.html ga3 (apr_dir_t *thedir) apr_status_t apr_filepath_root group__apr__filepath.html ga0 (const char **rootpath, const char **filepath, apr_int32_t flags, apr_pool_t *p) apr_status_t apr_filepath_merge group__apr__filepath.html ga1 (char **newpath, const char *rootpath, const char *addpath, apr_int32_t flags, apr_pool_t *p) apr_status_t apr_filepath_list_split group__apr__filepath.html ga2 (apr_array_header_t **pathelts, const char *liststr, apr_pool_t *p) apr_status_t apr_filepath_list_merge group__apr__filepath.html ga3 (char **liststr, apr_array_header_t *pathelts, apr_pool_t *p) apr_status_t apr_filepath_get group__apr__filepath.html ga4 (char **path, apr_int32_t flags, apr_pool_t *p) apr_status_t apr_filepath_set group__apr__filepath.html ga5 (const char *path, apr_pool_t *p) apr_status_t apr_filepath_encoding group__apr__filepath.html ga6 (int *style, apr_pool_t *p) apr_file_io.h /home/joe/src/apache/apr/apr/trunk/include/ apr__file__io_8h apr.h apr_pools.h apr_time.h apr_errno.h apr_file_info.h apr_inherit.h apr_want.h #define APR_WANT_STDIO apr__file__io_8h.html a0 #define APR_WANT_IOVEC apr__file__io_8h.html a1 #define APR_FOPEN_READ group__apr__file__open__flags.html ga0 #define APR_FOPEN_WRITE group__apr__file__open__flags.html ga1 #define APR_FOPEN_CREATE group__apr__file__open__flags.html ga2 #define APR_FOPEN_APPEND group__apr__file__open__flags.html ga3 #define APR_FOPEN_TRUNCATE group__apr__file__open__flags.html ga4 #define APR_FOPEN_BINARY group__apr__file__open__flags.html ga5 #define APR_FOPEN_EXCL group__apr__file__open__flags.html ga6 #define APR_FOPEN_BUFFERED group__apr__file__open__flags.html ga7 #define APR_FOPEN_DELONCLOSE group__apr__file__open__flags.html ga8 #define APR_FOPEN_XTHREAD group__apr__file__open__flags.html ga9 #define APR_FOPEN_SHARELOCK group__apr__file__open__flags.html ga10 #define APR_FOPEN_NOCLEANUP group__apr__file__open__flags.html ga11 #define APR_FOPEN_SENDFILE_ENABLED group__apr__file__open__flags.html ga12 #define APR_FOPEN_LARGEFILE group__apr__file__open__flags.html ga13 #define APR_READ group__apr__file__open__flags.html ga14 #define APR_WRITE group__apr__file__open__flags.html ga15 #define APR_CREATE group__apr__file__open__flags.html ga16 #define APR_APPEND group__apr__file__open__flags.html ga17 #define APR_TRUNCATE group__apr__file__open__flags.html ga18 #define APR_BINARY group__apr__file__open__flags.html ga19 #define APR_EXCL group__apr__file__open__flags.html ga20 #define APR_BUFFERED group__apr__file__open__flags.html ga21 #define APR_DELONCLOSE group__apr__file__open__flags.html ga22 #define APR_XTHREAD group__apr__file__open__flags.html ga23 #define APR_SHARELOCK group__apr__file__open__flags.html ga24 #define APR_FILE_NOCLEANUP group__apr__file__open__flags.html ga25 #define APR_SENDFILE_ENABLED group__apr__file__open__flags.html ga26 #define APR_LARGEFILE group__apr__file__open__flags.html ga27 #define APR_SET group__apr__file__seek__flags.html ga0 #define APR_CUR group__apr__file__seek__flags.html ga1 #define APR_END group__apr__file__seek__flags.html ga2 #define APR_FILE_ATTR_READONLY group__apr__file__attrs__set__flags.html ga0 #define APR_FILE_ATTR_EXECUTABLE group__apr__file__attrs__set__flags.html ga1 #define APR_FILE_ATTR_HIDDEN group__apr__file__attrs__set__flags.html ga2 #define APR_MAX_IOVEC_SIZE group__apr__file__writev.html ga0 #define APR_FLOCK_SHARED group__apr__file__lock__types.html ga0 #define APR_FLOCK_EXCLUSIVE group__apr__file__lock__types.html ga1 #define APR_FLOCK_TYPEMASK group__apr__file__lock__types.html ga2 #define APR_FLOCK_NONBLOCK group__apr__file__lock__types.html ga3 apr_uint32_t apr_fileattrs_t group__apr__file__io.html ga0 int apr_seek_where_t group__apr__file__io.html ga1 apr_file_t apr_file_t group__apr__file__io.html ga2 apr_status_t apr_file_open group__apr__file__io.html ga3 (apr_file_t **newf, const char *fname, apr_int32_t flag, apr_fileperms_t perm, apr_pool_t *pool) apr_status_t apr_file_close group__apr__file__io.html ga4 (apr_file_t *file) apr_status_t apr_file_remove group__apr__file__io.html ga5 (const char *path, apr_pool_t *pool) apr_status_t apr_file_rename group__apr__file__io.html ga6 (const char *from_path, const char *to_path, apr_pool_t *pool) apr_status_t apr_file_copy group__apr__file__io.html ga7 (const char *from_path, const char *to_path, apr_fileperms_t perms, apr_pool_t *pool) apr_status_t apr_file_append group__apr__file__io.html ga8 (const char *from_path, const char *to_path, apr_fileperms_t perms, apr_pool_t *pool) apr_status_t apr_file_eof group__apr__file__io.html ga9 (apr_file_t *fptr) apr_status_t apr_file_open_stderr group__apr__file__io.html ga10 (apr_file_t **thefile, apr_pool_t *pool) apr_status_t apr_file_open_stdout group__apr__file__io.html ga11 (apr_file_t **thefile, apr_pool_t *pool) apr_status_t apr_file_open_stdin group__apr__file__io.html ga12 (apr_file_t **thefile, apr_pool_t *pool) apr_status_t apr_file_read group__apr__file__io.html ga13 (apr_file_t *thefile, void *buf, apr_size_t *nbytes) apr_status_t apr_file_write group__apr__file__io.html ga14 (apr_file_t *thefile, const void *buf, apr_size_t *nbytes) apr_status_t apr_file_writev group__apr__file__io.html ga15 (apr_file_t *thefile, const struct iovec *vec, apr_size_t nvec, apr_size_t *nbytes) apr_status_t apr_file_read_full group__apr__file__io.html ga16 (apr_file_t *thefile, void *buf, apr_size_t nbytes, apr_size_t *bytes_read) apr_status_t apr_file_write_full group__apr__file__io.html ga17 (apr_file_t *thefile, const void *buf, apr_size_t nbytes, apr_size_t *bytes_written) apr_status_t apr_file_writev_full group__apr__file__io.html ga18 (apr_file_t *thefile, const struct iovec *vec, apr_size_t nvec, apr_size_t *nbytes) apr_status_t apr_file_putc group__apr__file__io.html ga19 (char ch, apr_file_t *thefile) apr_status_t apr_file_getc group__apr__file__io.html ga20 (char *ch, apr_file_t *thefile) apr_status_t apr_file_ungetc group__apr__file__io.html ga21 (char ch, apr_file_t *thefile) apr_status_t apr_file_gets group__apr__file__io.html ga22 (char *str, int len, apr_file_t *thefile) apr_status_t apr_file_puts group__apr__file__io.html ga23 (const char *str, apr_file_t *thefile) apr_status_t apr_file_flush group__apr__file__io.html ga24 (apr_file_t *thefile) apr_status_t apr_file_dup group__apr__file__io.html ga25 (apr_file_t **new_file, apr_file_t *old_file, apr_pool_t *p) apr_status_t apr_file_dup2 group__apr__file__io.html ga26 (apr_file_t *new_file, apr_file_t *old_file, apr_pool_t *p) apr_status_t apr_file_setaside group__apr__file__io.html ga27 (apr_file_t **new_file, apr_file_t *old_file, apr_pool_t *p) apr_status_t apr_file_seek group__apr__file__io.html ga28 (apr_file_t *thefile, apr_seek_where_t where, apr_off_t *offset) apr_status_t apr_file_pipe_create group__apr__file__io.html ga29 (apr_file_t **in, apr_file_t **out, apr_pool_t *pool) apr_status_t apr_file_namedpipe_create group__apr__file__io.html ga30 (const char *filename, apr_fileperms_t perm, apr_pool_t *pool) apr_status_t apr_file_pipe_timeout_get group__apr__file__io.html ga31 (apr_file_t *thepipe, apr_interval_time_t *timeout) apr_status_t apr_file_pipe_timeout_set group__apr__file__io.html ga32 (apr_file_t *thepipe, apr_interval_time_t timeout) apr_status_t apr_file_lock group__apr__file__io.html ga33 (apr_file_t *thefile, int type) apr_status_t apr_file_unlock group__apr__file__io.html ga34 (apr_file_t *thefile) apr_status_t apr_file_name_get group__apr__file__io.html ga35 (const char **new_path, apr_file_t *thefile) apr_status_t apr_file_data_get group__apr__file__io.html ga36 (void **data, const char *key, apr_file_t *file) apr_status_t apr_file_data_set group__apr__file__io.html ga37 (apr_file_t *file, void *data, const char *key, apr_status_t(*cleanup)(void *)) int apr_file_printf group__apr__file__io.html ga38 (apr_file_t *fptr, const char *format,...) apr_status_t apr_file_perms_set group__apr__file__io.html ga39 (const char *fname, apr_fileperms_t perms) apr_status_t apr_file_attrs_set group__apr__file__io.html ga40 (const char *fname, apr_fileattrs_t attributes, apr_fileattrs_t attr_mask, apr_pool_t *pool) apr_status_t apr_file_mtime_set group__apr__file__io.html ga41 (const char *fname, apr_time_t mtime, apr_pool_t *pool) apr_status_t apr_dir_make group__apr__file__io.html ga42 (const char *path, apr_fileperms_t perm, apr_pool_t *pool) apr_status_t apr_dir_make_recursive group__apr__file__io.html ga43 (const char *path, apr_fileperms_t perm, apr_pool_t *pool) apr_status_t apr_dir_remove group__apr__file__io.html ga44 (const char *path, apr_pool_t *pool) apr_status_t apr_file_info_get group__apr__file__io.html ga45 (apr_finfo_t *finfo, apr_int32_t wanted, apr_file_t *thefile) apr_status_t apr_file_trunc group__apr__file__io.html ga46 (apr_file_t *fp, apr_off_t offset) apr_int32_t apr_file_flags_get group__apr__file__io.html ga47 (apr_file_t *f) apr_pool_t * apr_file_pool_get group__apr__file__io.html ga48 (const apr_file_t *thefile) apr_status_t apr_file_inherit_set group__apr__file__io.html ga49 (apr_file_t *thefile) apr_status_t apr_file_inherit_unset group__apr__file__io.html ga50 (apr_file_t *thefile) apr_status_t apr_file_mktemp group__apr__file__io.html ga51 (apr_file_t **fp, char *templ, apr_int32_t flags, apr_pool_t *p) apr_status_t apr_temp_dir_get group__apr__file__io.html ga52 (const char **temp_dir, apr_pool_t *p) apr_fnmatch.h /home/joe/src/apache/apr/apr/trunk/include/ apr__fnmatch_8h apr_errno.h apr_tables.h #define APR_FNM_NOMATCH group__apr__fnmatch.html ga3 #define APR_FNM_NOESCAPE group__apr__fnmatch.html ga4 #define APR_FNM_PATHNAME group__apr__fnmatch.html ga5 #define APR_FNM_PERIOD group__apr__fnmatch.html ga6 #define APR_FNM_CASE_BLIND group__apr__fnmatch.html ga7 apr_status_t apr_fnmatch group__apr__fnmatch.html ga0 (const char *pattern, const char *strings, int flags) int apr_fnmatch_test group__apr__fnmatch.html ga1 (const char *pattern) apr_status_t apr_match_glob group__apr__fnmatch.html ga2 (const char *pattern, apr_array_header_t **result, apr_pool_t *p) apr_general.h /home/joe/src/apache/apr/apr/trunk/include/ apr__general_8h apr.h apr_pools.h apr_errno.h #define FALSE group__apr__general.html ga1 #define TRUE group__apr__general.html ga2 #define APR_ASCII_BLANK group__apr__general.html ga3 #define APR_ASCII_CR group__apr__general.html ga4 #define APR_ASCII_LF group__apr__general.html ga5 #define APR_ASCII_TAB group__apr__general.html ga6 #define APR_OFFSET group__apr__general.html ga7 (p_type, field) #define APR_OFFSETOF group__apr__general.html ga8 (s_type, field) #define APR_ALIGN group__apr__general.html ga9 (size, boundary) #define APR_ALIGN_DEFAULT group__apr__general.html ga10 (size) #define APR_STRINGIFY group__apr__general.html ga11 (n) #define APR_STRINGIFY_HELPER group__apr__general.html ga12 (n) int apr_signum_t group__apr__general.html ga0 apr_status_t apr_initialize group__apr__library.html ga0 (void) apr_status_t apr_app_initialize group__apr__library.html ga1 (int *argc, char const *const **argv, char const *const **env) void apr_terminate group__apr__library.html ga2 (void) void apr_terminate2 group__apr__library.html ga3 (void) apr_status_t apr_generate_random_bytes group__apr__random.html ga0 (unsigned char *buf, apr_size_t length) apr_getopt.h /home/joe/src/apache/apr/apr/trunk/include/ apr__getopt_8h apr_pools.h void( apr_getopt_err_fn_t group__apr__getopt.html ga0 )(void *arg, const char *err,...) apr_getopt_t apr_getopt_t group__apr__getopt.html ga1 apr_getopt_option_t apr_getopt_option_t group__apr__getopt.html ga2 apr_status_t apr_getopt_init group__apr__getopt.html ga3 (apr_getopt_t **os, apr_pool_t *cont, int argc, const char *const *argv) apr_status_t apr_getopt group__apr__getopt.html ga4 (apr_getopt_t *os, const char *opts, char *option_ch, const char **option_arg) apr_status_t apr_getopt_long group__apr__getopt.html ga5 (apr_getopt_t *os, const apr_getopt_option_t *opts, int *option_ch, const char **option_arg) apr_global_mutex.h /home/joe/src/apache/apr/apr/trunk/include/ apr__global__mutex_8h apr.h apr_proc_mutex.h apr_pools.h apr_errno.h apr_global_mutex_t apr_global_mutex_t group___a_p_r___global_mutex.html ga0 apr_status_t apr_global_mutex_create group___a_p_r___global_mutex.html ga1 (apr_global_mutex_t **mutex, const char *fname, apr_lockmech_e mech, apr_pool_t *pool) apr_status_t apr_global_mutex_child_init group___a_p_r___global_mutex.html ga2 (apr_global_mutex_t **mutex, const char *fname, apr_pool_t *pool) apr_status_t apr_global_mutex_lock group___a_p_r___global_mutex.html ga3 (apr_global_mutex_t *mutex) apr_status_t apr_global_mutex_trylock group___a_p_r___global_mutex.html ga4 (apr_global_mutex_t *mutex) apr_status_t apr_global_mutex_unlock group___a_p_r___global_mutex.html ga5 (apr_global_mutex_t *mutex) apr_status_t apr_global_mutex_destroy group___a_p_r___global_mutex.html ga6 (apr_global_mutex_t *mutex) apr_pool_t * apr_global_mutex_pool_get group___a_p_r___global_mutex.html ga7 (const apr_global_mutex_t *theglobal_mutex) apr_hash.h /home/joe/src/apache/apr/apr/trunk/include/ apr__hash_8h apr_pools.h #define APR_HASH_KEY_STRING group__apr__hash.html ga16 apr_hash_t apr_hash_t group__apr__hash.html ga0 apr_hash_index_t apr_hash_index_t group__apr__hash.html ga1 unsigned int(* apr_hashfunc_t group__apr__hash.html ga2 )(const char *key, apr_ssize_t *klen) unsigned int apr_hashfunc_default group__apr__hash.html ga3 (const char *key, apr_ssize_t *klen) apr_hash_t * apr_hash_make group__apr__hash.html ga4 (apr_pool_t *pool) apr_hash_t * apr_hash_make_custom group__apr__hash.html ga5 (apr_pool_t *pool, apr_hashfunc_t hash_func) apr_hash_t * apr_hash_copy group__apr__hash.html ga6 (apr_pool_t *pool, const apr_hash_t *h) void apr_hash_set group__apr__hash.html ga7 (apr_hash_t *ht, const void *key, apr_ssize_t klen, const void *val) void * apr_hash_get group__apr__hash.html ga8 (apr_hash_t *ht, const void *key, apr_ssize_t klen) apr_hash_index_t * apr_hash_first group__apr__hash.html ga9 (apr_pool_t *p, apr_hash_t *ht) apr_hash_index_t * apr_hash_next group__apr__hash.html ga10 (apr_hash_index_t *hi) void apr_hash_this group__apr__hash.html ga11 (apr_hash_index_t *hi, const void **key, apr_ssize_t *klen, void **val) unsigned int apr_hash_count group__apr__hash.html ga12 (apr_hash_t *ht) apr_hash_t * apr_hash_overlay group__apr__hash.html ga13 (apr_pool_t *p, const apr_hash_t *overlay, const apr_hash_t *base) apr_hash_t * apr_hash_merge group__apr__hash.html ga14 (apr_pool_t *p, const apr_hash_t *h1, const apr_hash_t *h2, void *(*merger)(apr_pool_t *p, const void *key, apr_ssize_t klen, const void *h1_val, const void *h2_val, const void *data), const void *data) apr_pool_t * apr_hash_pool_get group__apr__hash.html ga15 (const apr_hash_t *thehash) apr_inherit.h /home/joe/src/apache/apr/apr/trunk/include/ apr__inherit_8h #define APR_DECLARE_INHERIT_SET apr__inherit_8h.html a0 (type) #define APR_DECLARE_INHERIT_UNSET apr__inherit_8h.html a1 (type) apr_lib.h /home/joe/src/apache/apr/apr/trunk/include/ apr__lib_8h apr.h apr_errno.h #define HUGE_STRING_LEN group__apr__lib.html ga4 #define apr_killpg group__apr__lib.html ga5 (x, y) #define apr_isalnum group__apr__ctype.html ga0 (c) #define apr_isalpha group__apr__ctype.html ga1 (c) #define apr_iscntrl group__apr__ctype.html ga2 (c) #define apr_isdigit group__apr__ctype.html ga3 (c) #define apr_isgraph group__apr__ctype.html ga4 (c) #define apr_islower group__apr__ctype.html ga5 (c) #define apr_isascii group__apr__ctype.html ga6 (c) #define apr_isprint group__apr__ctype.html ga7 (c) #define apr_ispunct group__apr__ctype.html ga8 (c) #define apr_isspace group__apr__ctype.html ga9 (c) #define apr_isupper group__apr__ctype.html ga10 (c) #define apr_isxdigit group__apr__ctype.html ga11 (c) #define apr_tolower group__apr__ctype.html ga12 (c) #define apr_toupper group__apr__ctype.html ga13 (c) apr_vformatter_buff_t apr_vformatter_buff_t group__apr__lib.html ga0 const char * apr_filepath_name_get group__apr__lib.html ga1 (const char *pathname) int apr_vformatter group__apr__lib.html ga2 (int(*flush_func)(apr_vformatter_buff_t *b), apr_vformatter_buff_t *c, const char *fmt, va_list ap) apr_status_t apr_password_get group__apr__lib.html ga3 (const char *prompt, char *pwbuf, apr_size_t *bufsize) apr_mmap.h /home/joe/src/apache/apr/apr/trunk/include/ apr__mmap_8h apr.h apr_pools.h apr_errno.h apr_ring.h apr_file_io.h #define APR_MMAP_READ group__apr__mmap.html ga5 #define APR_MMAP_WRITE group__apr__mmap.html ga6 #define APR_MMAP_THRESHOLD group__apr__mmap.html ga7 #define APR_MMAP_LIMIT group__apr__mmap.html ga8 #define APR_MMAP_CANDIDATE group__apr__mmap.html ga9 (filelength) apr_mmap_t apr_mmap_t group__apr__mmap.html ga0 apr_status_t apr_mmap_create group__apr__mmap.html ga1 (apr_mmap_t **newmmap, apr_file_t *file, apr_off_t offset, apr_size_t size, apr_int32_t flag, apr_pool_t *cntxt) apr_status_t apr_mmap_dup group__apr__mmap.html ga2 (apr_mmap_t **new_mmap, apr_mmap_t *old_mmap, apr_pool_t *p) apr_status_t apr_mmap_delete group__apr__mmap.html ga3 (apr_mmap_t *mm) apr_status_t apr_mmap_offset group__apr__mmap.html ga4 (void **addr, apr_mmap_t *mm, apr_off_t offset) apr_network_io.h /home/joe/src/apache/apr/apr/trunk/include/ apr__network__io_8h apr.h apr_pools.h apr_file_io.h apr_errno.h apr_inherit.h #define APR_MAX_SECS_TO_LINGER group__apr__network__io.html ga41 #define APRMAXHOSTLEN group__apr__network__io.html ga42 #define APR_ANYADDR group__apr__network__io.html ga43 #define APR_SO_LINGER group__apr__sockopt.html ga0 #define APR_SO_KEEPALIVE group__apr__sockopt.html ga1 #define APR_SO_DEBUG group__apr__sockopt.html ga2 #define APR_SO_NONBLOCK group__apr__sockopt.html ga3 #define APR_SO_REUSEADDR group__apr__sockopt.html ga4 #define APR_SO_SNDBUF group__apr__sockopt.html ga5 #define APR_SO_RCVBUF group__apr__sockopt.html ga6 #define APR_SO_DISCONNECTED group__apr__sockopt.html ga7 #define APR_TCP_NODELAY group__apr__sockopt.html ga8 #define APR_TCP_NOPUSH group__apr__sockopt.html ga9 #define APR_RESET_NODELAY group__apr__sockopt.html ga10 #define APR_INCOMPLETE_READ group__apr__sockopt.html ga11 #define APR_INCOMPLETE_WRITE group__apr__sockopt.html ga12 #define APR_IPV6_V6ONLY group__apr__sockopt.html ga13 #define APR_TCP_DEFER_ACCEPT group__apr__sockopt.html ga14 #define APR_IPV4_ADDR_OK group__apr__network__io.html ga44 #define APR_IPV6_ADDR_OK group__apr__network__io.html ga45 #define APR_INADDR_NONE group__apr__network__io.html ga46 #define APR_INET group__apr__network__io.html ga47 #define APR_UNSPEC group__apr__network__io.html ga48 #define APR_INET6 group__apr__network__io.html ga49 #define APR_PROTO_TCP group___i_p___proto.html ga0 #define APR_PROTO_UDP group___i_p___proto.html ga1 #define APR_PROTO_SCTP group___i_p___proto.html ga2 #define apr_inet_addr group__apr__network__io.html ga50 #define APR_SENDFILE_DISCONNECT_SOCKET group__apr__network__io.html ga51 apr_socket_t apr_socket_t group__apr__network__io.html ga0 apr_hdtr_t apr_hdtr_t group__apr__network__io.html ga1 in_addr apr_in_addr_t group__apr__network__io.html ga2 apr_ipsubnet_t apr_ipsubnet_t group__apr__network__io.html ga3 apr_uint16_t apr_port_t group__apr__network__io.html ga4 apr_sockaddr_t apr_sockaddr_t group__apr__network__io.html ga5 apr_shutdown_how_e ga52 APR_SHUTDOWN_READ gga52a35 APR_SHUTDOWN_WRITE gga52a36 APR_SHUTDOWN_READWRITE gga52a37 apr_interface_e ga53 apr_status_t apr_socket_create group__apr__network__io.html ga6 (apr_socket_t **new_sock, int family, int type, int protocol, apr_pool_t *cont) apr_status_t apr_socket_shutdown group__apr__network__io.html ga7 (apr_socket_t *thesocket, apr_shutdown_how_e how) apr_status_t apr_socket_close group__apr__network__io.html ga8 (apr_socket_t *thesocket) apr_status_t apr_socket_bind group__apr__network__io.html ga9 (apr_socket_t *sock, apr_sockaddr_t *sa) apr_status_t apr_socket_listen group__apr__network__io.html ga10 (apr_socket_t *sock, apr_int32_t backlog) apr_status_t apr_socket_accept group__apr__network__io.html ga11 (apr_socket_t **new_sock, apr_socket_t *sock, apr_pool_t *connection_pool) apr_status_t apr_socket_connect group__apr__network__io.html ga12 (apr_socket_t *sock, apr_sockaddr_t *sa) apr_status_t apr_sockaddr_info_get group__apr__network__io.html ga13 (apr_sockaddr_t **sa, const char *hostname, apr_int32_t family, apr_port_t port, apr_int32_t flags, apr_pool_t *p) apr_status_t apr_getnameinfo group__apr__network__io.html ga14 (char **hostname, apr_sockaddr_t *sa, apr_int32_t flags) apr_status_t apr_parse_addr_port group__apr__network__io.html ga15 (char **addr, char **scope_id, apr_port_t *port, const char *str, apr_pool_t *p) apr_status_t apr_gethostname group__apr__network__io.html ga16 (char *buf, int len, apr_pool_t *cont) apr_status_t apr_socket_data_get group__apr__network__io.html ga17 (void **data, const char *key, apr_socket_t *sock) apr_status_t apr_socket_data_set group__apr__network__io.html ga18 (apr_socket_t *sock, void *data, const char *key, apr_status_t(*cleanup)(void *)) apr_status_t apr_socket_send group__apr__network__io.html ga19 (apr_socket_t *sock, const char *buf, apr_size_t *len) apr_status_t apr_socket_sendv group__apr__network__io.html ga20 (apr_socket_t *sock, const struct iovec *vec, apr_int32_t nvec, apr_size_t *len) apr_status_t apr_socket_sendto group__apr__network__io.html ga21 (apr_socket_t *sock, apr_sockaddr_t *where, apr_int32_t flags, const char *buf, apr_size_t *len) apr_status_t apr_socket_recvfrom group__apr__network__io.html ga22 (apr_sockaddr_t *from, apr_socket_t *sock, apr_int32_t flags, char *buf, apr_size_t *len) apr_status_t apr_socket_sendfile group__apr__network__io.html ga23 (apr_socket_t *sock, apr_file_t *file, apr_hdtr_t *hdtr, apr_off_t *offset, apr_size_t *len, apr_int32_t flags) apr_status_t apr_socket_recv group__apr__network__io.html ga24 (apr_socket_t *sock, char *buf, apr_size_t *len) apr_status_t apr_socket_opt_set group__apr__network__io.html ga25 (apr_socket_t *sock, apr_int32_t opt, apr_int32_t on) apr_status_t apr_socket_timeout_set group__apr__network__io.html ga26 (apr_socket_t *sock, apr_interval_time_t t) apr_status_t apr_socket_opt_get group__apr__network__io.html ga27 (apr_socket_t *sock, apr_int32_t opt, apr_int32_t *on) apr_status_t apr_socket_timeout_get group__apr__network__io.html ga28 (apr_socket_t *sock, apr_interval_time_t *t) apr_status_t apr_socket_atmark group__apr__network__io.html ga29 (apr_socket_t *sock, int *atmark) apr_status_t apr_socket_addr_get group__apr__network__io.html ga30 (apr_sockaddr_t **sa, apr_interface_e which, apr_socket_t *sock) apr_status_t apr_sockaddr_ip_get group__apr__network__io.html ga31 (char **addr, apr_sockaddr_t *sockaddr) int apr_sockaddr_equal group__apr__network__io.html ga32 (const apr_sockaddr_t *addr1, const apr_sockaddr_t *addr2) apr_status_t apr_socket_type_get group__apr__network__io.html ga33 (apr_socket_t *sock, int *type) apr_status_t apr_getservbyname group__apr__network__io.html ga34 (apr_sockaddr_t *sockaddr, const char *servname) apr_status_t apr_ipsubnet_create group__apr__network__io.html ga35 (apr_ipsubnet_t **ipsub, const char *ipstr, const char *mask_or_numbits, apr_pool_t *p) int apr_ipsubnet_test group__apr__network__io.html ga36 (apr_ipsubnet_t *ipsub, apr_sockaddr_t *sa) apr_status_t apr_socket_accept_filter group__apr__network__io.html ga37 (apr_socket_t *sock, char *name, char *args) apr_status_t apr_socket_protocol_get group__apr__network__io.html ga38 (apr_socket_t *sock, int *protocol) apr_status_t apr_socket_inherit_set group__apr__network__io.html ga39 (apr_socket_t *thesocket) apr_status_t apr_socket_inherit_unset group__apr__network__io.html ga40 (apr_socket_t *thesocket) apr_status_t apr_mcast_join group__apr__mcast.html ga0 (apr_socket_t *sock, apr_sockaddr_t *join, apr_sockaddr_t *iface, apr_sockaddr_t *source) apr_status_t apr_mcast_leave group__apr__mcast.html ga1 (apr_socket_t *sock, apr_sockaddr_t *addr, apr_sockaddr_t *iface, apr_sockaddr_t *source) apr_status_t apr_mcast_hops group__apr__mcast.html ga2 (apr_socket_t *sock, apr_byte_t ttl) apr_status_t apr_mcast_loopback group__apr__mcast.html ga3 (apr_socket_t *sock, apr_byte_t opt) apr_status_t apr_mcast_interface group__apr__mcast.html ga4 (apr_socket_t *sock, apr_sockaddr_t *iface) apr_poll.h /home/joe/src/apache/apr/apr/trunk/include/ apr__poll_8h apr.h apr_pools.h apr_errno.h apr_inherit.h apr_file_io.h apr_network_io.h #define APR_POLLIN group__apr__poll.html ga8 #define APR_POLLPRI group__apr__poll.html ga9 #define APR_POLLOUT group__apr__poll.html ga10 #define APR_POLLERR group__apr__poll.html ga11 #define APR_POLLHUP group__apr__poll.html ga12 #define APR_POLLNVAL group__apr__poll.html ga13 #define APR_POLLSET_THREADSAFE group__apr__poll.html ga14 apr_pollfd_t apr_pollfd_t group__apr__poll.html ga0 apr_pollset_t apr_pollset_t group__apr__poll.html ga1 apr_datatype_e ga15 APR_NO_DESC gga15a9 APR_POLL_SOCKET gga15a10 APR_POLL_FILE gga15a11 APR_POLL_LASTDESC gga15a12 apr_status_t apr_pollset_create group__apr__poll.html ga2 (apr_pollset_t **pollset, apr_uint32_t size, apr_pool_t *p, apr_uint32_t flags) apr_status_t apr_pollset_destroy group__apr__poll.html ga3 (apr_pollset_t *pollset) apr_status_t apr_pollset_add group__apr__poll.html ga4 (apr_pollset_t *pollset, const apr_pollfd_t *descriptor) apr_status_t apr_pollset_remove group__apr__poll.html ga5 (apr_pollset_t *pollset, const apr_pollfd_t *descriptor) apr_status_t apr_pollset_poll group__apr__poll.html ga6 (apr_pollset_t *pollset, apr_interval_time_t timeout, apr_int32_t *num, const apr_pollfd_t **descriptors) apr_status_t apr_poll group__apr__poll.html ga7 (apr_pollfd_t *aprset, apr_int32_t numsock, apr_int32_t *nsds, apr_interval_time_t timeout) apr_pools.h /home/joe/src/apache/apr/apr/trunk/include/ apr__pools_8h apr.h apr_errno.h apr_general.h apr_want.h apr_allocator.h #define APR_WANT_MEMFUNC apr__pools_8h.html a0 #define APR_POOL_DECLARE_ACCESSOR group__apr__pools.html ga30 (type) #define APR_POOL_IMPLEMENT_ACCESSOR group__apr__pools.html ga31 (type) #define APR_POOL_DEBUG group__apr__pools.html ga32 #define APR_POOL__FILE_LINE__ group__apr__pools.html ga33 apr_pool_t apr_pool_t group__apr__pools.html ga0 int(* apr_abortfunc_t group__apr__pools.html ga1 )(int retcode) apr_status_t apr_pool_initialize group__apr__pools.html ga2 (void) void apr_pool_terminate group__apr__pools.html ga3 (void) apr_status_t apr_pool_create_ex group__apr__pools.html ga4 (apr_pool_t **newpool, apr_pool_t *parent, apr_abortfunc_t abort_fn, apr_allocator_t *allocator) apr_status_t apr_pool_create_ex_debug group__apr__pools.html ga5 (apr_pool_t **newpool, apr_pool_t *parent, apr_abortfunc_t abort_fn, apr_allocator_t *allocator, const char *file_line) apr_status_t apr_pool_create group__apr__pools.html ga6 (apr_pool_t **newpool, apr_pool_t *parent) apr_allocator_t * apr_pool_allocator_get group__apr__pools.html ga7 (apr_pool_t *pool) void apr_pool_clear group__apr__pools.html ga8 (apr_pool_t *p) void apr_pool_clear_debug group__apr__pools.html ga9 (apr_pool_t *p, const char *file_line) void apr_pool_destroy group__apr__pools.html ga10 (apr_pool_t *p) void apr_pool_destroy_debug group__apr__pools.html ga11 (apr_pool_t *p, const char *file_line) void * apr_palloc group__apr__pools.html ga12 (apr_pool_t *p, apr_size_t size) void * apr_palloc_debug group__apr__pools.html ga13 (apr_pool_t *p, apr_size_t size, const char *file_line) void * apr_pcalloc group__apr__pools.html ga14 (apr_pool_t *p, apr_size_t size) void * apr_pcalloc_debug group__apr__pools.html ga15 (apr_pool_t *p, apr_size_t size, const char *file_line) void apr_pool_abort_set group__apr__pools.html ga16 (apr_abortfunc_t abortfunc, apr_pool_t *pool) apr_abortfunc_t apr_pool_abort_get group__apr__pools.html ga17 (apr_pool_t *pool) apr_pool_t * apr_pool_parent_get group__apr__pools.html ga18 (apr_pool_t *pool) int apr_pool_is_ancestor group__apr__pools.html ga19 (apr_pool_t *a, apr_pool_t *b) void apr_pool_tag group__apr__pools.html ga20 (apr_pool_t *pool, const char *tag) apr_status_t apr_pool_userdata_set group__apr__pools.html ga21 (const void *data, const char *key, apr_status_t(*cleanup)(void *), apr_pool_t *pool) apr_status_t apr_pool_userdata_setn group__apr__pools.html ga22 (const void *data, const char *key, apr_status_t(*cleanup)(void *), apr_pool_t *pool) apr_status_t apr_pool_userdata_get group__apr__pools.html ga23 (void **data, const char *key, apr_pool_t *pool) void apr_pool_cleanup_register group__apr__pools.html ga24 (apr_pool_t *p, const void *data, apr_status_t(*plain_cleanup)(void *), apr_status_t(*child_cleanup)(void *)) void apr_pool_cleanup_kill group__apr__pools.html ga25 (apr_pool_t *p, const void *data, apr_status_t(*cleanup)(void *)) void apr_pool_child_cleanup_set group__apr__pools.html ga26 (apr_pool_t *p, const void *data, apr_status_t(*plain_cleanup)(void *), apr_status_t(*child_cleanup)(void *)) apr_status_t apr_pool_cleanup_run group__apr__pools.html ga27 (apr_pool_t *p, void *data, apr_status_t(*cleanup)(void *)) apr_status_t apr_pool_cleanup_null group__apr__pools.html ga28 (void *data) void apr_pool_cleanup_for_exec group__apr__pools.html ga29 (void) void apr_pool_join group___pool_debug.html ga0 (apr_pool_t *p, apr_pool_t *sub) apr_pool_t * apr_pool_find group___pool_debug.html ga1 (const void *mem) apr_size_t apr_pool_num_bytes group___pool_debug.html ga2 (apr_pool_t *p, int recurse) void apr_pool_lock group___pool_debug.html ga3 (apr_pool_t *pool, int flag) apr_portable.h /home/joe/src/apache/apr/apr/trunk/include/ apr__portable_8h apr.h apr_pools.h apr_thread_proc.h apr_file_io.h apr_network_io.h apr_errno.h apr_global_mutex.h apr_proc_mutex.h apr_time.h apr_dso.h apr_shm.h #define apr_os_global_mutex_t group__apr__portabile.html ga31 #define apr_os_global_mutex_get group__apr__portabile.html ga32 int apr_os_file_t group__apr__portabile.html ga0 DIR apr_os_dir_t group__apr__portabile.html ga1 int apr_os_sock_t group__apr__portabile.html ga2 apr_os_proc_mutex_t apr_os_proc_mutex_t group__apr__portabile.html ga3 pthread_t apr_os_thread_t group__apr__portabile.html ga4 pthread_key_t apr_os_threadkey_t group__apr__portabile.html ga5 pid_t apr_os_proc_t group__apr__portabile.html ga6 timeval apr_os_imp_time_t group__apr__portabile.html ga7 tm apr_os_exp_time_t group__apr__portabile.html ga8 void * apr_os_dso_handle_t group__apr__portabile.html ga9 void * apr_os_shm_t group__apr__portabile.html ga10 apr_os_sock_info_t apr_os_sock_info_t group__apr__portabile.html ga11 apr_status_t apr_os_file_get group__apr__portabile.html ga12 (apr_os_file_t *thefile, apr_file_t *file) apr_status_t apr_os_dir_get group__apr__portabile.html ga13 (apr_os_dir_t **thedir, apr_dir_t *dir) apr_status_t apr_os_sock_get group__apr__portabile.html ga14 (apr_os_sock_t *thesock, apr_socket_t *sock) apr_status_t apr_os_proc_mutex_get group__apr__portabile.html ga15 (apr_os_proc_mutex_t *ospmutex, apr_proc_mutex_t *pmutex) apr_status_t apr_os_exp_time_get group__apr__portabile.html ga16 (apr_os_exp_time_t **ostime, apr_time_exp_t *aprtime) apr_status_t apr_os_imp_time_get group__apr__portabile.html ga17 (apr_os_imp_time_t **ostime, apr_time_t *aprtime) apr_status_t apr_os_shm_get group__apr__portabile.html ga18 (apr_os_shm_t *osshm, apr_shm_t *shm) apr_status_t apr_os_thread_get group__apr__os__thread.html ga0 (apr_os_thread_t **thethd, apr_thread_t *thd) apr_status_t apr_os_threadkey_get group__apr__os__thread.html ga1 (apr_os_threadkey_t *thekey, apr_threadkey_t *key) apr_status_t apr_os_thread_put group__apr__os__thread.html ga2 (apr_thread_t **thd, apr_os_thread_t *thethd, apr_pool_t *cont) apr_status_t apr_os_threadkey_put group__apr__os__thread.html ga3 (apr_threadkey_t **key, apr_os_threadkey_t *thekey, apr_pool_t *cont) apr_os_thread_t apr_os_thread_current group__apr__os__thread.html ga4 (void) int apr_os_thread_equal group__apr__os__thread.html ga5 (apr_os_thread_t tid1, apr_os_thread_t tid2) apr_status_t apr_os_file_put group__apr__portabile.html ga19 (apr_file_t **file, apr_os_file_t *thefile, apr_int32_t flags, apr_pool_t *cont) apr_status_t apr_os_pipe_put group__apr__portabile.html ga20 (apr_file_t **file, apr_os_file_t *thefile, apr_pool_t *cont) apr_status_t apr_os_pipe_put_ex group__apr__portabile.html ga21 (apr_file_t **file, apr_os_file_t *thefile, int register_cleanup, apr_pool_t *cont) apr_status_t apr_os_dir_put group__apr__portabile.html ga22 (apr_dir_t **dir, apr_os_dir_t *thedir, apr_pool_t *cont) apr_status_t apr_os_sock_put group__apr__portabile.html ga23 (apr_socket_t **sock, apr_os_sock_t *thesock, apr_pool_t *cont) apr_status_t apr_os_sock_make group__apr__portabile.html ga24 (apr_socket_t **apr_sock, apr_os_sock_info_t *os_sock_info, apr_pool_t *cont) apr_status_t apr_os_proc_mutex_put group__apr__portabile.html ga25 (apr_proc_mutex_t **pmutex, apr_os_proc_mutex_t *ospmutex, apr_pool_t *cont) apr_status_t apr_os_imp_time_put group__apr__portabile.html ga26 (apr_time_t *aprtime, apr_os_imp_time_t **ostime, apr_pool_t *cont) apr_status_t apr_os_exp_time_put group__apr__portabile.html ga27 (apr_time_exp_t *aprtime, apr_os_exp_time_t **ostime, apr_pool_t *cont) apr_status_t apr_os_shm_put group__apr__portabile.html ga28 (apr_shm_t **shm, apr_os_shm_t *osshm, apr_pool_t *cont) apr_status_t apr_os_dso_handle_put group__apr__os__dso.html ga0 (apr_dso_handle_t **dso, apr_os_dso_handle_t thedso, apr_pool_t *pool) apr_status_t apr_os_dso_handle_get group__apr__os__dso.html ga1 (apr_os_dso_handle_t *dso, apr_dso_handle_t *aprdso) const char * apr_os_default_encoding group__apr__portabile.html ga29 (apr_pool_t *pool) const char * apr_os_locale_encoding group__apr__portabile.html ga30 (apr_pool_t *pool) apr_proc_mutex.h /home/joe/src/apache/apr/apr/trunk/include/ apr__proc__mutex_8h apr.h apr_pools.h apr_errno.h apr_proc_mutex_t apr_proc_mutex_t group__apr__proc__mutex.html ga0 apr_lockmech_e ga12 APR_LOCK_FCNTL gga12a1 APR_LOCK_FLOCK gga12a2 APR_LOCK_SYSVSEM gga12a3 APR_LOCK_PROC_PTHREAD gga12a4 APR_LOCK_POSIXSEM gga12a5 APR_LOCK_DEFAULT gga12a6 apr_status_t apr_proc_mutex_create group__apr__proc__mutex.html ga1 (apr_proc_mutex_t **mutex, const char *fname, apr_lockmech_e mech, apr_pool_t *pool) apr_status_t apr_proc_mutex_child_init group__apr__proc__mutex.html ga2 (apr_proc_mutex_t **mutex, const char *fname, apr_pool_t *pool) apr_status_t apr_proc_mutex_lock group__apr__proc__mutex.html ga3 (apr_proc_mutex_t *mutex) apr_status_t apr_proc_mutex_trylock group__apr__proc__mutex.html ga4 (apr_proc_mutex_t *mutex) apr_status_t apr_proc_mutex_unlock group__apr__proc__mutex.html ga5 (apr_proc_mutex_t *mutex) apr_status_t apr_proc_mutex_destroy group__apr__proc__mutex.html ga6 (apr_proc_mutex_t *mutex) apr_status_t apr_proc_mutex_cleanup group__apr__proc__mutex.html ga7 (void *mutex) const char * apr_proc_mutex_lockfile group__apr__proc__mutex.html ga8 (apr_proc_mutex_t *mutex) const char * apr_proc_mutex_name group__apr__proc__mutex.html ga9 (apr_proc_mutex_t *mutex) const char * apr_proc_mutex_defname group__apr__proc__mutex.html ga10 (void) apr_pool_t * apr_proc_mutex_pool_get group__apr__proc__mutex.html ga11 (const apr_proc_mutex_t *theproc_mutex) apr_ring.h /home/joe/src/apache/apr/apr/trunk/include/ apr__ring_8h apr_general.h #define APR_RING_ENTRY group__apr__ring.html ga0 (elem) #define APR_RING_HEAD group__apr__ring.html ga1 (head, elem) #define APR_RING_SENTINEL group__apr__ring.html ga2 (hp, elem, link) #define APR_RING_FIRST group__apr__ring.html ga3 (hp) #define APR_RING_LAST group__apr__ring.html ga4 (hp) #define APR_RING_NEXT group__apr__ring.html ga5 (ep, link) #define APR_RING_PREV group__apr__ring.html ga6 (ep, link) #define APR_RING_INIT group__apr__ring.html ga7 (hp, elem, link) #define APR_RING_EMPTY group__apr__ring.html ga8 (hp, elem, link) #define APR_RING_ELEM_INIT group__apr__ring.html ga9 (ep, link) #define APR_RING_SPLICE_BEFORE group__apr__ring.html ga10 (lep, ep1, epN, link) #define APR_RING_SPLICE_AFTER group__apr__ring.html ga11 (lep, ep1, epN, link) #define APR_RING_INSERT_BEFORE group__apr__ring.html ga12 (lep, nep, link) #define APR_RING_INSERT_AFTER group__apr__ring.html ga13 (lep, nep, link) #define APR_RING_SPLICE_HEAD group__apr__ring.html ga14 (hp, ep1, epN, elem, link) #define APR_RING_SPLICE_TAIL group__apr__ring.html ga15 (hp, ep1, epN, elem, link) #define APR_RING_INSERT_HEAD group__apr__ring.html ga16 (hp, nep, elem, link) #define APR_RING_INSERT_TAIL group__apr__ring.html ga17 (hp, nep, elem, link) #define APR_RING_CONCAT group__apr__ring.html ga18 (h1, h2, elem, link) #define APR_RING_PREPEND group__apr__ring.html ga19 (h1, h2, elem, link) #define APR_RING_UNSPLICE group__apr__ring.html ga20 (ep1, epN, link) #define APR_RING_REMOVE group__apr__ring.html ga21 (ep, link) #define APR_RING_CHECK_ONE group__apr__ring.html ga22 (msg, ptr) #define APR_RING_CHECK group__apr__ring.html ga23 (hp, elem, link, msg) #define APR_RING_CHECK_CONSISTENCY group__apr__ring.html ga24 (hp, elem, link) #define APR_RING_CHECK_ELEM group__apr__ring.html ga25 (ep, elem, link, msg) #define APR_RING_CHECK_ELEM_CONSISTENCY group__apr__ring.html ga26 (ep, elem, link) apr_shm.h /home/joe/src/apache/apr/apr/trunk/include/ apr__shm_8h apr.h apr_pools.h apr_errno.h apr_shm_t apr_shm_t group__apr__shm.html ga0 apr_status_t apr_shm_create group__apr__shm.html ga1 (apr_shm_t **m, apr_size_t reqsize, const char *filename, apr_pool_t *pool) apr_status_t apr_shm_remove group__apr__shm.html ga2 (const char *filename, apr_pool_t *pool) apr_status_t apr_shm_destroy group__apr__shm.html ga3 (apr_shm_t *m) apr_status_t apr_shm_attach group__apr__shm.html ga4 (apr_shm_t **m, const char *filename, apr_pool_t *pool) apr_status_t apr_shm_detach group__apr__shm.html ga5 (apr_shm_t *m) void * apr_shm_baseaddr_get group__apr__shm.html ga6 (const apr_shm_t *m) apr_size_t apr_shm_size_get group__apr__shm.html ga7 (const apr_shm_t *m) apr_pool_t * apr_shm_pool_get group__apr__shm.html ga8 (const apr_shm_t *theshm) apr_signal.h /home/joe/src/apache/apr/apr/trunk/include/ apr__signal_8h apr.h apr_pools.h void apr_sigfunc_t group__apr__signal.html ga0 (int) apr_sigfunc_t * apr_signal group__apr__signal.html ga1 (int signo, apr_sigfunc_t *func) const char * apr_signal_description_get group__apr__signal.html ga2 (int signum) void apr_signal_init group__apr__signal.html ga3 (apr_pool_t *pglobal) apr_status_t apr_signal_block group__apr__signal.html ga4 (int signum) apr_status_t apr_signal_unblock group__apr__signal.html ga5 (int signum) apr_strings.h /home/joe/src/apache/apr/apr/trunk/include/ apr__strings_8h apr.h apr_errno.h apr_pools.h apr_want.h int apr_strnatcmp group__apr__strings.html ga0 (char const *a, char const *b) int apr_strnatcasecmp group__apr__strings.html ga1 (char const *a, char const *b) char * apr_pstrdup group__apr__strings.html ga2 (apr_pool_t *p, const char *s) char * apr_pstrmemdup group__apr__strings.html ga3 (apr_pool_t *p, const char *s, apr_size_t n) char * apr_pstrndup group__apr__strings.html ga4 (apr_pool_t *p, const char *s, apr_size_t n) void * apr_pmemdup group__apr__strings.html ga5 (apr_pool_t *p, const void *m, apr_size_t n) char * apr_pstrcat group__apr__strings.html ga6 (apr_pool_t *p,...) char * apr_pstrcatv group__apr__strings.html ga7 (apr_pool_t *p, const struct iovec *vec, apr_size_t nvec, apr_size_t *nbytes) char * apr_pvsprintf group__apr__strings.html ga8 (apr_pool_t *p, const char *fmt, va_list ap) char * apr_psprintf group__apr__strings.html ga9 (apr_pool_t *p, const char *fmt,...) char * apr_cpystrn group__apr__strings.html ga10 (char *dst, const char *src, apr_size_t dst_size) char * apr_collapse_spaces group__apr__strings.html ga11 (char *dest, const char *src) apr_status_t apr_tokenize_to_argv group__apr__strings.html ga12 (const char *arg_str, char ***argv_out, apr_pool_t *token_context) char * apr_strtok group__apr__strings.html ga13 (char *str, const char *sep, char **last) int apr_snprintf group___a_p_r___strings___snprintf.html ga0 (char *buf, apr_size_t len, const char *format,...) int apr_vsnprintf group___a_p_r___strings___snprintf.html ga1 (char *buf, apr_size_t len, const char *format, va_list ap) char * apr_itoa group__apr__strings.html ga14 (apr_pool_t *p, int n) char * apr_ltoa group__apr__strings.html ga15 (apr_pool_t *p, long n) char * apr_off_t_toa group__apr__strings.html ga16 (apr_pool_t *p, apr_off_t n) apr_status_t apr_strtoff group__apr__strings.html ga17 (apr_off_t *offset, const char *buf, char **end, int base) apr_int64_t apr_strtoi64 group__apr__strings.html ga18 (const char *buf, char **end, int base) apr_int64_t apr_atoi64 group__apr__strings.html ga19 (const char *buf) char * apr_strfsize group__apr__strings.html ga20 (apr_off_t size, char *buf) apr_support.h /home/joe/src/apache/apr/apr/trunk/include/ apr__support_8h apr.h apr_network_io.h apr_file_io.h apr_status_t apr_wait_for_io_or_timeout group__apr__support.html ga0 (apr_file_t *f, apr_socket_t *s, int for_read) apr_tables.h /home/joe/src/apache/apr/apr/trunk/include/ apr__tables_8h apr.h apr_pools.h #define APR_OVERLAP_TABLES_SET group__apr__tables.html ga31 #define APR_OVERLAP_TABLES_MERGE group__apr__tables.html ga32 apr_table_t apr_table_t group__apr__tables.html ga0 apr_array_header_t apr_array_header_t group__apr__tables.html ga1 apr_table_entry_t apr_table_entry_t group__apr__tables.html ga2 int( apr_table_do_callback_fn_t group__apr__tables.html ga3 )(void *rec, const char *key, const char *value) const apr_array_header_t * apr_table_elts group__apr__tables.html ga4 (const apr_table_t *t) int apr_is_empty_table group__apr__tables.html ga5 (const apr_table_t *t) int apr_is_empty_array group__apr__tables.html ga6 (const apr_array_header_t *a) apr_array_header_t * apr_array_make group__apr__tables.html ga7 (apr_pool_t *p, int nelts, int elt_size) void * apr_array_push group__apr__tables.html ga8 (apr_array_header_t *arr) void * apr_array_pop group__apr__tables.html ga9 (apr_array_header_t *arr) void apr_array_cat group__apr__tables.html ga10 (apr_array_header_t *dst, const apr_array_header_t *src) apr_array_header_t * apr_array_copy group__apr__tables.html ga11 (apr_pool_t *p, const apr_array_header_t *arr) apr_array_header_t * apr_array_copy_hdr group__apr__tables.html ga12 (apr_pool_t *p, const apr_array_header_t *arr) apr_array_header_t * apr_array_append group__apr__tables.html ga13 (apr_pool_t *p, const apr_array_header_t *first, const apr_array_header_t *second) char * apr_array_pstrcat group__apr__tables.html ga14 (apr_pool_t *p, const apr_array_header_t *arr, const char sep) apr_table_t * apr_table_make group__apr__tables.html ga15 (apr_pool_t *p, int nelts) apr_table_t * apr_table_copy group__apr__tables.html ga16 (apr_pool_t *p, const apr_table_t *t) void apr_table_clear group__apr__tables.html ga17 (apr_table_t *t) const char * apr_table_get group__apr__tables.html ga18 (const apr_table_t *t, const char *key) void apr_table_set group__apr__tables.html ga19 (apr_table_t *t, const char *key, const char *val) void apr_table_setn group__apr__tables.html ga20 (apr_table_t *t, const char *key, const char *val) void apr_table_unset group__apr__tables.html ga21 (apr_table_t *t, const char *key) void apr_table_merge group__apr__tables.html ga22 (apr_table_t *t, const char *key, const char *val) void apr_table_mergen group__apr__tables.html ga23 (apr_table_t *t, const char *key, const char *val) void apr_table_add group__apr__tables.html ga24 (apr_table_t *t, const char *key, const char *val) void apr_table_addn group__apr__tables.html ga25 (apr_table_t *t, const char *key, const char *val) apr_table_t * apr_table_overlay group__apr__tables.html ga26 (apr_pool_t *p, const apr_table_t *overlay, const apr_table_t *base) int apr_table_do group__apr__tables.html ga27 (apr_table_do_callback_fn_t *comp, void *rec, const apr_table_t *t,...) int apr_table_vdo group__apr__tables.html ga28 (apr_table_do_callback_fn_t *comp, void *rec, const apr_table_t *t, va_list vp) void apr_table_overlap group__apr__tables.html ga29 (apr_table_t *a, const apr_table_t *b, unsigned flags) void apr_table_compress group__apr__tables.html ga30 (apr_table_t *t, unsigned flags) apr_thread_cond.h /home/joe/src/apache/apr/apr/trunk/include/ apr__thread__cond_8h apr.h apr_pools.h apr_errno.h apr_time.h apr_thread_mutex.h apr_thread_cond_t apr_thread_cond_t group__apr__thread__cond.html ga0 apr_status_t apr_thread_cond_create group__apr__thread__cond.html ga1 (apr_thread_cond_t **cond, apr_pool_t *pool) apr_status_t apr_thread_cond_wait group__apr__thread__cond.html ga2 (apr_thread_cond_t *cond, apr_thread_mutex_t *mutex) apr_status_t apr_thread_cond_timedwait group__apr__thread__cond.html ga3 (apr_thread_cond_t *cond, apr_thread_mutex_t *mutex, apr_interval_time_t timeout) apr_status_t apr_thread_cond_signal group__apr__thread__cond.html ga4 (apr_thread_cond_t *cond) apr_status_t apr_thread_cond_broadcast group__apr__thread__cond.html ga5 (apr_thread_cond_t *cond) apr_status_t apr_thread_cond_destroy group__apr__thread__cond.html ga6 (apr_thread_cond_t *cond) apr_pool_t * apr_thread_cond_pool_get group__apr__thread__cond.html ga7 (const apr_thread_cond_t *thethread_cond) apr_thread_mutex.h /home/joe/src/apache/apr/apr/trunk/include/ apr__thread__mutex_8h apr.h apr_errno.h apr_pools.h #define APR_THREAD_MUTEX_DEFAULT group__apr__thread__mutex.html ga7 #define APR_THREAD_MUTEX_NESTED group__apr__thread__mutex.html ga8 #define APR_THREAD_MUTEX_UNNESTED group__apr__thread__mutex.html ga9 apr_thread_mutex_t apr_thread_mutex_t group__apr__thread__mutex.html ga0 apr_status_t apr_thread_mutex_create group__apr__thread__mutex.html ga1 (apr_thread_mutex_t **mutex, unsigned int flags, apr_pool_t *pool) apr_status_t apr_thread_mutex_lock group__apr__thread__mutex.html ga2 (apr_thread_mutex_t *mutex) apr_status_t apr_thread_mutex_trylock group__apr__thread__mutex.html ga3 (apr_thread_mutex_t *mutex) apr_status_t apr_thread_mutex_unlock group__apr__thread__mutex.html ga4 (apr_thread_mutex_t *mutex) apr_status_t apr_thread_mutex_destroy group__apr__thread__mutex.html ga5 (apr_thread_mutex_t *mutex) apr_pool_t * apr_thread_mutex_pool_get group__apr__thread__mutex.html ga6 (const apr_thread_mutex_t *thethread_mutex) apr_thread_proc.h /home/joe/src/apache/apr/apr/trunk/include/ apr__thread__proc_8h apr.h apr_file_io.h apr_pools.h apr_errno.h #define APR_PROC_CHECK_EXIT group__apr__thread__proc.html ga58 (x) #define APR_PROC_CHECK_SIGNALED group__apr__thread__proc.html ga59 (x) #define APR_PROC_CHECK_CORE_DUMP group__apr__thread__proc.html ga60 (x) #define APR_NO_PIPE group__apr__thread__proc.html ga61 #define APR_FULL_BLOCK group__apr__thread__proc.html ga62 #define APR_FULL_NONBLOCK group__apr__thread__proc.html ga63 #define APR_PARENT_BLOCK group__apr__thread__proc.html ga64 #define APR_CHILD_BLOCK group__apr__thread__proc.html ga65 #define APR_LIMIT_CPU group__apr__thread__proc.html ga66 #define APR_LIMIT_MEM group__apr__thread__proc.html ga67 #define APR_LIMIT_NPROC group__apr__thread__proc.html ga68 #define APR_LIMIT_NOFILE group__apr__thread__proc.html ga69 #define APR_OC_REASON_DEATH group___a_p_r___o_c.html ga0 #define APR_OC_REASON_UNWRITABLE group___a_p_r___o_c.html ga1 #define APR_OC_REASON_RESTART group___a_p_r___o_c.html ga2 #define APR_OC_REASON_UNREGISTER group___a_p_r___o_c.html ga3 #define APR_OC_REASON_LOST group___a_p_r___o_c.html ga4 #define APR_OC_REASON_RUNNING group___a_p_r___o_c.html ga5 #define APR_PROC_DETACH_FOREGROUND group__apr__thread__proc.html ga70 #define APR_PROC_DETACH_DAEMONIZE group__apr__thread__proc.html ga71 apr_proc_t apr_proc_t group__apr__thread__proc.html ga0 void( apr_child_errfn_t group__apr__thread__proc.html ga1 )(apr_pool_t *proc, apr_status_t err, const char *description) apr_thread_t apr_thread_t group__apr__thread__proc.html ga2 apr_threadattr_t apr_threadattr_t group__apr__thread__proc.html ga3 apr_procattr_t apr_procattr_t group__apr__thread__proc.html ga4 apr_thread_once_t apr_thread_once_t group__apr__thread__proc.html ga5 apr_threadkey_t apr_threadkey_t group__apr__thread__proc.html ga6 apr_other_child_rec_t apr_other_child_rec_t group__apr__thread__proc.html ga7 void *(APR_THREAD_FUNC * apr_thread_start_t group__apr__thread__proc.html ga8 )(apr_thread_t *, void *) apr_cmdtype_e ga72 APR_SHELLCMD gga72a29 APR_PROGRAM gga72a30 APR_PROGRAM_ENV gga72a31 APR_PROGRAM_PATH gga72a32 APR_SHELLCMD_ENV gga72a33 apr_wait_how_e ga73 APR_WAIT gga73a34 APR_NOWAIT gga73a35 apr_exit_why_e ga74 APR_PROC_EXIT gga74a36 APR_PROC_SIGNAL gga74a37 APR_PROC_SIGNAL_CORE gga74a38 apr_kill_conditions_e ga75 APR_KILL_NEVER gga75a39 APR_KILL_ALWAYS gga75a40 APR_KILL_AFTER_TIMEOUT gga75a41 APR_JUST_WAIT gga75a42 APR_KILL_ONLY_ONCE gga75a43 apr_status_t apr_threadattr_create group__apr__thread__proc.html ga9 (apr_threadattr_t **new_attr, apr_pool_t *cont) apr_status_t apr_threadattr_detach_set group__apr__thread__proc.html ga10 (apr_threadattr_t *attr, apr_int32_t on) apr_status_t apr_threadattr_detach_get group__apr__thread__proc.html ga11 (apr_threadattr_t *attr) apr_status_t apr_threadattr_stacksize_set group__apr__thread__proc.html ga12 (apr_threadattr_t *attr, apr_size_t stacksize) apr_status_t apr_threadattr_guardsize_set group__apr__thread__proc.html ga13 (apr_threadattr_t *attr, apr_size_t guardsize) apr_status_t apr_thread_create group__apr__thread__proc.html ga14 (apr_thread_t **new_thread, apr_threadattr_t *attr, apr_thread_start_t func, void *data, apr_pool_t *cont) apr_status_t apr_thread_exit group__apr__thread__proc.html ga15 (apr_thread_t *thd, apr_status_t retval) apr_status_t apr_thread_join group__apr__thread__proc.html ga16 (apr_status_t *retval, apr_thread_t *thd) void apr_thread_yield group__apr__thread__proc.html ga17 (void) apr_status_t apr_thread_once_init group__apr__thread__proc.html ga18 (apr_thread_once_t **control, apr_pool_t *p) apr_status_t apr_thread_once group__apr__thread__proc.html ga19 (apr_thread_once_t *control, void(*func)(void)) apr_status_t apr_thread_detach group__apr__thread__proc.html ga20 (apr_thread_t *thd) apr_status_t apr_thread_data_get group__apr__thread__proc.html ga21 (void **data, const char *key, apr_thread_t *thread) apr_status_t apr_thread_data_set group__apr__thread__proc.html ga22 (void *data, const char *key, apr_status_t(*cleanup)(void *), apr_thread_t *thread) apr_status_t apr_threadkey_private_create group__apr__thread__proc.html ga23 (apr_threadkey_t **key, void(*dest)(void *), apr_pool_t *cont) apr_status_t apr_threadkey_private_get group__apr__thread__proc.html ga24 (void **new_mem, apr_threadkey_t *key) apr_status_t apr_threadkey_private_set group__apr__thread__proc.html ga25 (void *priv, apr_threadkey_t *key) apr_status_t apr_threadkey_private_delete group__apr__thread__proc.html ga26 (apr_threadkey_t *key) apr_status_t apr_threadkey_data_get group__apr__thread__proc.html ga27 (void **data, const char *key, apr_threadkey_t *threadkey) apr_status_t apr_threadkey_data_set group__apr__thread__proc.html ga28 (void *data, const char *key, apr_status_t(*cleanup)(void *), apr_threadkey_t *threadkey) apr_status_t apr_procattr_create group__apr__thread__proc.html ga29 (apr_procattr_t **new_attr, apr_pool_t *cont) apr_status_t apr_procattr_io_set group__apr__thread__proc.html ga30 (apr_procattr_t *attr, apr_int32_t in, apr_int32_t out, apr_int32_t err) apr_status_t apr_procattr_child_in_set group__apr__thread__proc.html ga31 (struct apr_procattr_t *attr, apr_file_t *child_in, apr_file_t *parent_in) apr_status_t apr_procattr_child_out_set group__apr__thread__proc.html ga32 (struct apr_procattr_t *attr, apr_file_t *child_out, apr_file_t *parent_out) apr_status_t apr_procattr_child_err_set group__apr__thread__proc.html ga33 (struct apr_procattr_t *attr, apr_file_t *child_err, apr_file_t *parent_err) apr_status_t apr_procattr_dir_set group__apr__thread__proc.html ga34 (apr_procattr_t *attr, const char *dir) apr_status_t apr_procattr_cmdtype_set group__apr__thread__proc.html ga35 (apr_procattr_t *attr, apr_cmdtype_e cmd) apr_status_t apr_procattr_detach_set group__apr__thread__proc.html ga36 (apr_procattr_t *attr, apr_int32_t detach) apr_status_t apr_procattr_limit_set group__apr__thread__proc.html ga37 (apr_procattr_t *attr, apr_int32_t what, struct rlimit *limit) apr_status_t apr_procattr_child_errfn_set group__apr__thread__proc.html ga38 (apr_procattr_t *attr, apr_child_errfn_t *errfn) apr_status_t apr_procattr_error_check_set group__apr__thread__proc.html ga39 (apr_procattr_t *attr, apr_int32_t chk) apr_status_t apr_procattr_addrspace_set group__apr__thread__proc.html ga40 (apr_procattr_t *attr, apr_int32_t addrspace) apr_status_t apr_procattr_user_set group__apr__thread__proc.html ga41 (apr_procattr_t *attr, const char *username, const char *password) apr_status_t apr_procattr_group_set group__apr__thread__proc.html ga42 (apr_procattr_t *attr, const char *groupname) apr_status_t apr_proc_fork group__apr__thread__proc.html ga43 (apr_proc_t *proc, apr_pool_t *cont) apr_status_t apr_proc_create group__apr__thread__proc.html ga44 (apr_proc_t *new_proc, const char *progname, const char *const *args, const char *const *env, apr_procattr_t *attr, apr_pool_t *pool) apr_status_t apr_proc_wait group__apr__thread__proc.html ga45 (apr_proc_t *proc, int *exitcode, apr_exit_why_e *exitwhy, apr_wait_how_e waithow) apr_status_t apr_proc_wait_all_procs group__apr__thread__proc.html ga46 (apr_proc_t *proc, int *exitcode, apr_exit_why_e *exitwhy, apr_wait_how_e waithow, apr_pool_t *p) apr_status_t apr_proc_detach group__apr__thread__proc.html ga47 (int daemonize) void apr_proc_other_child_register group__apr__thread__proc.html ga48 (apr_proc_t *proc, void(*maintenance)(int reason, void *, int status), void *data, apr_file_t *write_fd, apr_pool_t *p) void apr_proc_other_child_unregister group__apr__thread__proc.html ga49 (void *data) apr_status_t apr_proc_other_child_alert group__apr__thread__proc.html ga50 (apr_proc_t *proc, int reason, int status) void apr_proc_other_child_refresh group__apr__thread__proc.html ga51 (apr_other_child_rec_t *ocr, int reason) void apr_proc_other_child_refresh_all group__apr__thread__proc.html ga52 (int reason) apr_status_t apr_proc_kill group__apr__thread__proc.html ga53 (apr_proc_t *proc, int sig) void apr_pool_note_subprocess group__apr__thread__proc.html ga54 (apr_pool_t *a, apr_proc_t *proc, apr_kill_conditions_e how) apr_status_t apr_setup_signal_thread group__apr__thread__proc.html ga55 (void) apr_status_t apr_signal_thread group__apr__thread__proc.html ga56 (int(*signal_handler)(int signum)) apr_pool_t * apr_thread_pool_get group__apr__thread__proc.html ga57 (const apr_thread_t *thethread) apr_thread_rwlock.h /home/joe/src/apache/apr/apr/trunk/include/ apr__thread__rwlock_8h apr.h apr_pools.h apr_errno.h apr_thread_rwlock_t apr_thread_rwlock_t group__apr__thread__rwlock.html ga0 apr_status_t apr_thread_rwlock_create group__apr__thread__rwlock.html ga1 (apr_thread_rwlock_t **rwlock, apr_pool_t *pool) apr_status_t apr_thread_rwlock_rdlock group__apr__thread__rwlock.html ga2 (apr_thread_rwlock_t *rwlock) apr_status_t apr_thread_rwlock_tryrdlock group__apr__thread__rwlock.html ga3 (apr_thread_rwlock_t *rwlock) apr_status_t apr_thread_rwlock_wrlock group__apr__thread__rwlock.html ga4 (apr_thread_rwlock_t *rwlock) apr_status_t apr_thread_rwlock_trywrlock group__apr__thread__rwlock.html ga5 (apr_thread_rwlock_t *rwlock) apr_status_t apr_thread_rwlock_unlock group__apr__thread__rwlock.html ga6 (apr_thread_rwlock_t *rwlock) apr_status_t apr_thread_rwlock_destroy group__apr__thread__rwlock.html ga7 (apr_thread_rwlock_t *rwlock) apr_pool_t * apr_thread_rwlock_pool_get group__apr__thread__rwlock.html ga8 (const apr_thread_rwlock_t *thethread_rwlock) apr_time.h /home/joe/src/apache/apr/apr/trunk/include/ apr__time_8h apr.h apr_pools.h apr_errno.h #define APR_TIME_C group__apr__time.html ga18 (val) #define APR_TIME_T_FMT group__apr__time.html ga19 #define APR_USEC_PER_SEC group__apr__time.html ga20 #define apr_time_sec group__apr__time.html ga21 (time) #define apr_time_usec group__apr__time.html ga22 (time) #define apr_time_msec group__apr__time.html ga23 (time) #define apr_time_as_msec group__apr__time.html ga24 (time) #define apr_time_from_sec group__apr__time.html ga25 (sec) #define apr_time_make group__apr__time.html ga26 (sec, usec) #define APR_RFC822_DATE_LEN group__apr__time.html ga27 #define APR_CTIME_LEN group__apr__time.html ga28 apr_int64_t apr_time_t group__apr__time.html ga2 apr_int64_t apr_interval_time_t group__apr__time.html ga3 apr_int32_t apr_short_interval_time_t group__apr__time.html ga4 apr_time_exp_t apr_time_exp_t group__apr__time.html ga5 apr_time_t apr_time_now group__apr__time.html ga6 (void) apr_status_t apr_time_ansi_put group__apr__time.html ga7 (apr_time_t *result, time_t input) apr_status_t apr_time_exp_tz group__apr__time.html ga8 (apr_time_exp_t *result, apr_time_t input, apr_int32_t offs) apr_status_t apr_time_exp_gmt group__apr__time.html ga9 (apr_time_exp_t *result, apr_time_t input) apr_status_t apr_time_exp_lt group__apr__time.html ga10 (apr_time_exp_t *result, apr_time_t input) apr_status_t apr_time_exp_get group__apr__time.html ga11 (apr_time_t *result, apr_time_exp_t *input) apr_status_t apr_time_exp_gmt_get group__apr__time.html ga12 (apr_time_t *result, apr_time_exp_t *input) void apr_sleep group__apr__time.html ga13 (apr_interval_time_t t) apr_status_t apr_rfc822_date group__apr__time.html ga14 (char *date_str, apr_time_t t) apr_status_t apr_ctime group__apr__time.html ga15 (char *date_str, apr_time_t t) apr_status_t apr_strftime group__apr__time.html ga16 (char *s, apr_size_t *retsize, apr_size_t max, const char *format, apr_time_exp_t *tm) void apr_time_clock_hires group__apr__time.html ga17 (apr_pool_t *p) const char apr_month_snames group__apr__time.html ga0 [12][4] const char apr_day_snames group__apr__time.html ga1 [7][4] apr_user.h /home/joe/src/apache/apr/apr/trunk/include/ apr__user_8h apr.h apr_errno.h apr_pools.h #define apr_uid_compare group__apr__user.html ga8 (left, right) #define apr_gid_compare group__apr__user.html ga9 (left, right) uid_t apr_uid_t group__apr__user.html ga0 gid_t apr_gid_t group__apr__user.html ga1 apr_status_t apr_uid_current group__apr__user.html ga2 (apr_uid_t *userid, apr_gid_t *groupid, apr_pool_t *p) apr_status_t apr_uid_name_get group__apr__user.html ga3 (char **username, apr_uid_t userid, apr_pool_t *p) apr_status_t apr_uid_get group__apr__user.html ga4 (apr_uid_t *userid, apr_gid_t *groupid, const char *username, apr_pool_t *p) apr_status_t apr_uid_homepath_get group__apr__user.html ga5 (char **dirname, const char *username, apr_pool_t *p) apr_status_t apr_gid_name_get group__apr__user.html ga6 (char **groupname, apr_gid_t groupid, apr_pool_t *p) apr_status_t apr_gid_get group__apr__user.html ga7 (apr_gid_t *groupid, const char *groupname, apr_pool_t *p) apr_version.h /home/joe/src/apache/apr/apr/trunk/include/ apr__version_8h apr.h #define APR_MAJOR_VERSION apr__version_8h.html a0 #define APR_MINOR_VERSION apr__version_8h.html a1 #define APR_PATCH_VERSION apr__version_8h.html a2 #define APR_IS_DEV_VERSION apr__version_8h.html a3 #define APR_IS_DEV_STRING apr__version_8h.html a4 #define APR_STRINGIFY apr__version_8h.html a5 (n) #define APR_STRINGIFY_HELPER apr__version_8h.html a6 (n) #define APR_VERSION_STRING apr__version_8h.html a7 #define APR_VERSION_STRING_CSV apr__version_8h.html a8 void apr_version apr__version_8h.html a9 (apr_version_t *pvsn) const char * apr_version_string apr__version_8h.html a10 (void) apr_want.h /home/joe/src/apache/apr/apr/trunk/include/ apr__want_8h apr.h apr_array_header_t structapr__array__header__t.html apr_pool_t * pool structapr__array__header__t.html o0 int elt_size structapr__array__header__t.html o1 int nelts structapr__array__header__t.html o2 int nalloc structapr__array__header__t.html o3 char * elts structapr__array__header__t.html o4 apr_descriptor unionapr__descriptor.html apr_file_t * f unionapr__descriptor.html o0 apr_socket_t * s unionapr__descriptor.html o1 apr_finfo_t structapr__finfo__t.html apr_pool_t * pool structapr__finfo__t.html o0 apr_int32_t valid structapr__finfo__t.html o1 apr_fileperms_t protection structapr__finfo__t.html o2 apr_filetype_e filetype structapr__finfo__t.html o3 apr_uid_t user structapr__finfo__t.html o4 apr_gid_t group structapr__finfo__t.html o5 apr_ino_t inode structapr__finfo__t.html o6 apr_dev_t device structapr__finfo__t.html o7 apr_int32_t nlink structapr__finfo__t.html o8 apr_off_t size structapr__finfo__t.html o9 apr_off_t csize structapr__finfo__t.html o10 apr_time_t atime structapr__finfo__t.html o11 apr_time_t mtime structapr__finfo__t.html o12 apr_time_t ctime structapr__finfo__t.html o13 const char * fname structapr__finfo__t.html o14 const char * name structapr__finfo__t.html o15 apr_file_t * filehand structapr__finfo__t.html o16 apr_getopt_option_t structapr__getopt__option__t.html const char * name structapr__getopt__option__t.html o0 int optch structapr__getopt__option__t.html o1 int has_arg structapr__getopt__option__t.html o2 const char * description structapr__getopt__option__t.html o3 apr_getopt_t structapr__getopt__t.html apr_pool_t * cont structapr__getopt__t.html o0 apr_getopt_err_fn_t * errfn structapr__getopt__t.html o1 void * errarg structapr__getopt__t.html o2 int ind structapr__getopt__t.html o3 int opt structapr__getopt__t.html o4 int reset structapr__getopt__t.html o5 int argc structapr__getopt__t.html o6 const char ** argv structapr__getopt__t.html o7 char const * place structapr__getopt__t.html o8 int interleave structapr__getopt__t.html o9 int skip_start structapr__getopt__t.html o10 int skip_end structapr__getopt__t.html o11 apr_hdtr_t structapr__hdtr__t.html iovec * headers structapr__hdtr__t.html o0 int numheaders structapr__hdtr__t.html o1 iovec * trailers structapr__hdtr__t.html o2 int numtrailers structapr__hdtr__t.html o3 apr_memnode_t structapr__memnode__t.html apr_memnode_t * next structapr__memnode__t.html o0 apr_memnode_t ** ref structapr__memnode__t.html o1 apr_uint32_t index structapr__memnode__t.html o2 apr_uint32_t free_index structapr__memnode__t.html o3 char * first_avail structapr__memnode__t.html o4 char * endp structapr__memnode__t.html o5 apr_mmap_t structapr__mmap__t.html APR_RING_ENTRY structapr__mmap__t.html a0 (apr_mmap_t) link apr_pool_t * cntxt structapr__mmap__t.html o0 void * mm structapr__mmap__t.html o1 apr_size_t size structapr__mmap__t.html o2 apr_os_proc_mutex_t structapr__os__proc__mutex__t.html int crossproc structapr__os__proc__mutex__t.html o0 pthread_mutex_t * pthread_interproc structapr__os__proc__mutex__t.html o1 pthread_mutex_t * intraproc structapr__os__proc__mutex__t.html o2 apr_os_sock_info_t structapr__os__sock__info__t.html apr_os_sock_t * os_sock structapr__os__sock__info__t.html o0 sockaddr * local structapr__os__sock__info__t.html o1 sockaddr * remote structapr__os__sock__info__t.html o2 int family structapr__os__sock__info__t.html o3 int type structapr__os__sock__info__t.html o4 int protocol structapr__os__sock__info__t.html o5 apr_pollfd_t structapr__pollfd__t.html apr_pool_t * p structapr__pollfd__t.html o0 apr_datatype_e desc_type structapr__pollfd__t.html o1 apr_int16_t reqevents structapr__pollfd__t.html o2 apr_int16_t rtnevents structapr__pollfd__t.html o3 apr_descriptor desc structapr__pollfd__t.html o4 void * client_data structapr__pollfd__t.html o5 apr_proc_t structapr__proc__t.html pid_t pid structapr__proc__t.html o0 apr_file_t * in structapr__proc__t.html o1 apr_file_t * out structapr__proc__t.html o2 apr_file_t * err structapr__proc__t.html o3 char * invoked structapr__proc__t.html o4 HANDLE hproc structapr__proc__t.html o5 apr_sockaddr_t structapr__sockaddr__t.html apr_pool_t * pool structapr__sockaddr__t.html o0 char * hostname structapr__sockaddr__t.html o1 char * servname structapr__sockaddr__t.html o2 apr_port_t port structapr__sockaddr__t.html o3 apr_int32_t family structapr__sockaddr__t.html o4 apr_socklen_t salen structapr__sockaddr__t.html o5 int ipaddr_len structapr__sockaddr__t.html o6 int addr_str_len structapr__sockaddr__t.html o7 void * ipaddr_ptr structapr__sockaddr__t.html o8 apr_sockaddr_t * next structapr__sockaddr__t.html o9 apr_sockaddr_t::@0 sa structapr__sockaddr__t.html o13 sockaddr_in sin unionapr__sockaddr__t_1_1@0.html o0 sockaddr_in6 sin6 unionapr__sockaddr__t_1_1@0.html o1 sockaddr_storage sas unionapr__sockaddr__t_1_1@0.html o2 apr_table_entry_t structapr__table__entry__t.html char * key structapr__table__entry__t.html o0 char * val structapr__table__entry__t.html o1 apr_uint32_t key_checksum structapr__table__entry__t.html o2 apr_time_exp_t structapr__time__exp__t.html apr_int32_t tm_usec structapr__time__exp__t.html o0 apr_int32_t tm_sec structapr__time__exp__t.html o1 apr_int32_t tm_min structapr__time__exp__t.html o2 apr_int32_t tm_hour structapr__time__exp__t.html o3 apr_int32_t tm_mday structapr__time__exp__t.html o4 apr_int32_t tm_mon structapr__time__exp__t.html o5 apr_int32_t tm_year structapr__time__exp__t.html o6 apr_int32_t tm_wday structapr__time__exp__t.html o7 apr_int32_t tm_yday structapr__time__exp__t.html o8 apr_int32_t tm_isdst structapr__time__exp__t.html o9 apr_int32_t tm_gmtoff structapr__time__exp__t.html o10 apr_version_t structapr__version__t.html int major structapr__version__t.html o0 int minor structapr__version__t.html o1 int patch structapr__version__t.html o2 int is_dev structapr__version__t.html o3 apr_vformatter_buff_t structapr__vformatter__buff__t.html char * curpos structapr__vformatter__buff__t.html o0 char * endpos structapr__vformatter__buff__t.html o1 APR Apache Portability Runtime library group___a_p_r.html apr_platform apr_allocator apr_atomic apr_dso apr_env apr_errno apr_file_info apr_file_io apr_fnmatch apr_general apr_getopt APR_GlobalMutex apr_hash apr_lib apr_mmap apr_network_io apr_poll apr_pools apr_portabile apr_proc_mutex apr_ring apr_shm apr_signal apr_strings apr_support apr_tables apr_thread_cond apr_thread_mutex apr_thread_proc apr_thread_rwlock apr_time apr_user apr_platform Platform Definitions group__apr__platform.html #define APR_INLINE group__apr__platform.html ga11 #define APR_HAS_INLINE group__apr__platform.html ga12 #define APR_HAVE_ARPA_INET_H group__apr__platform.html ga13 #define APR_HAVE_CONIO_H group__apr__platform.html ga14 #define APR_HAVE_CRYPT_H group__apr__platform.html ga15 #define APR_HAVE_CTYPE_H group__apr__platform.html ga16 #define APR_HAVE_DIRENT_H group__apr__platform.html ga17 #define APR_HAVE_ERRNO_H group__apr__platform.html ga18 #define APR_HAVE_FCNTL_H group__apr__platform.html ga19 #define APR_HAVE_IO_H group__apr__platform.html ga20 #define APR_HAVE_LIMITS_H group__apr__platform.html ga21 #define APR_HAVE_NETDB_H group__apr__platform.html ga22 #define APR_HAVE_NETINET_IN_H group__apr__platform.html ga23 #define APR_HAVE_NETINET_SCTP_H group__apr__platform.html ga24 #define APR_HAVE_NETINET_SCTP_UIO_H group__apr__platform.html ga25 #define APR_HAVE_NETINET_TCP_H group__apr__platform.html ga26 #define APR_HAVE_PTHREAD_H group__apr__platform.html ga27 #define APR_HAVE_SEMAPHORE_H group__apr__platform.html ga28 #define APR_HAVE_SIGNAL_H group__apr__platform.html ga29 #define APR_HAVE_STDARG_H group__apr__platform.html ga30 #define APR_HAVE_STDINT_H group__apr__platform.html ga31 #define APR_HAVE_STDIO_H group__apr__platform.html ga32 #define APR_HAVE_STDLIB_H group__apr__platform.html ga33 #define APR_HAVE_STRING_H group__apr__platform.html ga34 #define APR_HAVE_STRINGS_H group__apr__platform.html ga35 #define APR_HAVE_SYS_IOCTL_H group__apr__platform.html ga36 #define APR_HAVE_SYS_SENDFILE_H group__apr__platform.html ga37 #define APR_HAVE_SYS_SIGNAL_H group__apr__platform.html ga38 #define APR_HAVE_SYS_SOCKET_H group__apr__platform.html ga39 #define APR_HAVE_SYS_SOCKIO_H group__apr__platform.html ga40 #define APR_HAVE_SYS_SYSLIMITS_H group__apr__platform.html ga41 #define APR_HAVE_SYS_TIME_H group__apr__platform.html ga42 #define APR_HAVE_SYS_TYPES_H group__apr__platform.html ga43 #define APR_HAVE_SYS_UIO_H group__apr__platform.html ga44 #define APR_HAVE_SYS_UN_H group__apr__platform.html ga45 #define APR_HAVE_SYS_WAIT_H group__apr__platform.html ga46 #define APR_HAVE_TIME_H group__apr__platform.html ga47 #define APR_HAVE_UNISTD_H group__apr__platform.html ga48 #define APR_HAVE_SHMEM_MMAP_TMP group__apr__platform.html ga49 #define APR_HAVE_SHMEM_MMAP_SHM group__apr__platform.html ga50 #define APR_HAVE_SHMEM_MMAP_ZERO group__apr__platform.html ga51 #define APR_HAVE_SHMEM_SHMGET_ANON group__apr__platform.html ga52 #define APR_HAVE_SHMEM_SHMGET group__apr__platform.html ga53 #define APR_HAVE_SHMEM_MMAP_ANON group__apr__platform.html ga54 #define APR_HAVE_SHMEM_BEOS group__apr__platform.html ga55 #define APR_USE_SHMEM_MMAP_TMP group__apr__platform.html ga56 #define APR_USE_SHMEM_MMAP_SHM group__apr__platform.html ga57 #define APR_USE_SHMEM_MMAP_ZERO group__apr__platform.html ga58 #define APR_USE_SHMEM_SHMGET_ANON group__apr__platform.html ga59 #define APR_USE_SHMEM_SHMGET group__apr__platform.html ga60 #define APR_USE_SHMEM_MMAP_ANON group__apr__platform.html ga61 #define APR_USE_SHMEM_BEOS group__apr__platform.html ga62 #define APR_USE_FLOCK_SERIALIZE group__apr__platform.html ga63 #define APR_USE_SYSVSEM_SERIALIZE group__apr__platform.html ga64 #define APR_USE_POSIXSEM_SERIALIZE group__apr__platform.html ga65 #define APR_USE_FCNTL_SERIALIZE group__apr__platform.html ga66 #define APR_USE_PROC_PTHREAD_SERIALIZE group__apr__platform.html ga67 #define APR_USE_PTHREAD_SERIALIZE group__apr__platform.html ga68 #define APR_HAS_FLOCK_SERIALIZE group__apr__platform.html ga69 #define APR_HAS_SYSVSEM_SERIALIZE group__apr__platform.html ga70 #define APR_HAS_POSIXSEM_SERIALIZE group__apr__platform.html ga71 #define APR_HAS_FCNTL_SERIALIZE group__apr__platform.html ga72 #define APR_HAS_PROC_PTHREAD_SERIALIZE group__apr__platform.html ga73 #define APR_PROCESS_LOCK_IS_GLOBAL group__apr__platform.html ga74 #define APR_HAVE_CORKABLE_TCP group__apr__platform.html ga75 #define APR_HAVE_GETRLIMIT group__apr__platform.html ga76 #define APR_HAVE_IN_ADDR group__apr__platform.html ga77 #define APR_HAVE_INET_ADDR group__apr__platform.html ga78 #define APR_HAVE_INET_NETWORK group__apr__platform.html ga79 #define APR_HAVE_IPV6 group__apr__platform.html ga80 #define APR_HAVE_MEMMOVE group__apr__platform.html ga81 #define APR_HAVE_SETRLIMIT group__apr__platform.html ga82 #define APR_HAVE_SIGACTION group__apr__platform.html ga83 #define APR_HAVE_SIGSUSPEND group__apr__platform.html ga84 #define APR_HAVE_SIGWAIT group__apr__platform.html ga85 #define APR_HAVE_SA_STORAGE group__apr__platform.html ga86 #define APR_HAVE_STRCASECMP group__apr__platform.html ga87 #define APR_HAVE_STRDUP group__apr__platform.html ga88 #define APR_HAVE_STRICMP group__apr__platform.html ga89 #define APR_HAVE_STRNCASECMP group__apr__platform.html ga90 #define APR_HAVE_STRNICMP group__apr__platform.html ga91 #define APR_HAVE_STRSTR group__apr__platform.html ga92 #define APR_HAVE_MEMCHR group__apr__platform.html ga93 #define APR_HAVE_STRUCT_RLIMIT group__apr__platform.html ga94 #define APR_HAVE_UNION_SEMUN group__apr__platform.html ga95 #define APR_HAVE_SCTP group__apr__platform.html ga96 #define APR_HAS_SHARED_MEMORY group__apr__platform.html ga97 #define APR_HAS_THREADS group__apr__platform.html ga98 #define APR_HAS_SENDFILE group__apr__platform.html ga99 #define APR_HAS_MMAP group__apr__platform.html ga100 #define APR_HAS_FORK group__apr__platform.html ga101 #define APR_HAS_RANDOM group__apr__platform.html ga102 #define APR_HAS_OTHER_CHILD group__apr__platform.html ga103 #define APR_HAS_DSO group__apr__platform.html ga104 #define APR_HAS_SO_ACCEPTFILTER group__apr__platform.html ga105 #define APR_HAS_UNICODE_FS group__apr__platform.html ga106 #define APR_HAS_PROC_INVOKED group__apr__platform.html ga107 #define APR_HAS_USER group__apr__platform.html ga108 #define APR_HAS_LARGE_FILES group__apr__platform.html ga109 #define APR_HAS_XTHREAD_FILES group__apr__platform.html ga110 #define APR_HAS_OS_UUID group__apr__platform.html ga111 #define APR_FILES_AS_SOCKETS group__apr__platform.html ga112 #define APR_CHARSET_EBCDIC group__apr__platform.html ga113 #define APR_TCP_NOPUSH_FLAG group__apr__platform.html ga114 #define APR_TCP_NODELAY_INHERITED group__apr__platform.html ga115 #define APR_O_NONBLOCK_INHERITED group__apr__platform.html ga116 #define APR_SIZEOF_VOIDP group__apr__platform.html ga117 #define APR_IS_BIGENDIAN group__apr__platform.html ga118 #define APR_INT64_C group__apr__platform.html ga119 (val) #define APR_UINT64_C group__apr__platform.html ga120 (val) #define APR_THREAD_FUNC group__apr__platform.html ga121 #define APR_DECLARE group__apr__platform.html ga122 (type) #define APR_DECLARE_NONSTD group__apr__platform.html ga123 (type) #define APR_DECLARE_DATA group__apr__platform.html ga124 #define APR_SSIZE_T_FMT group__apr__platform.html ga125 #define APR_SIZE_T_FMT group__apr__platform.html ga126 #define APR_OFF_T_FMT group__apr__platform.html ga127 #define APR_PID_T_FMT group__apr__platform.html ga128 #define APR_INT64_T_FMT group__apr__platform.html ga129 #define APR_UINT64_T_FMT group__apr__platform.html ga130 #define APR_UINT64_T_HEX_FMT group__apr__platform.html ga131 #define APR_PROC_MUTEX_IS_GLOBAL group__apr__platform.html ga132 #define APR_EOL_STR group__apr__platform.html ga133 #define apr_wait_t group__apr__platform.html ga134 #define WEXITSTATUS group__apr__platform.html ga135 (status) #define WTERMSIG group__apr__platform.html ga136 (status) unsigned char apr_byte_t group__apr__platform.html ga0 short apr_int16_t group__apr__platform.html ga1 unsigned short apr_uint16_t group__apr__platform.html ga2 int apr_int32_t group__apr__platform.html ga3 unsigned int apr_uint32_t group__apr__platform.html ga4 long apr_int64_t group__apr__platform.html ga5 unsigned long apr_uint64_t group__apr__platform.html ga6 size_t apr_size_t group__apr__platform.html ga7 ssize_t apr_ssize_t group__apr__platform.html ga8 off_t apr_off_t group__apr__platform.html ga9 socklen_t apr_socklen_t group__apr__platform.html ga10 apr_allocator Internal Memory Allocation group__apr__allocator.html apr_memnode_t #define APR_MEMNODE_T_SIZE group__apr__allocator.html ga11 #define APR_ALLOCATOR_MAX_FREE_UNLIMITED group__apr__allocator.html ga12 apr_allocator_t apr_allocator_t group__apr__allocator.html ga0 apr_memnode_t apr_memnode_t group__apr__allocator.html ga1 apr_status_t apr_allocator_create group__apr__allocator.html ga2 (apr_allocator_t **allocator) void apr_allocator_destroy group__apr__allocator.html ga3 (apr_allocator_t *allocator) apr_memnode_t * apr_allocator_alloc group__apr__allocator.html ga4 (apr_allocator_t *allocator, apr_size_t size) void apr_allocator_free group__apr__allocator.html ga5 (apr_allocator_t *allocator, apr_memnode_t *memnode) void apr_allocator_owner_set group__apr__allocator.html ga6 (apr_allocator_t *allocator, apr_pool_t *pool) apr_pool_t * apr_allocator_owner_get group__apr__allocator.html ga7 (apr_allocator_t *allocator) void apr_allocator_max_free_set group__apr__allocator.html ga8 (apr_allocator_t *allocator, apr_size_t size) void apr_allocator_mutex_set group__apr__allocator.html ga9 (apr_allocator_t *allocator, apr_thread_mutex_t *mutex) apr_thread_mutex_t * apr_allocator_mutex_get group__apr__allocator.html ga10 (apr_allocator_t *allocator) apr_atomic Atomic Operations group__apr__atomic.html apr_status_t apr_atomic_init group__apr__atomic.html ga0 (apr_pool_t *p) apr_uint32_t apr_atomic_read32 group__apr__atomic.html ga1 (volatile apr_uint32_t *mem) void apr_atomic_set32 group__apr__atomic.html ga2 (volatile apr_uint32_t *mem, apr_uint32_t val) apr_uint32_t apr_atomic_add32 group__apr__atomic.html ga3 (volatile apr_uint32_t *mem, apr_uint32_t val) void apr_atomic_sub32 group__apr__atomic.html ga4 (volatile apr_uint32_t *mem, apr_uint32_t val) apr_uint32_t apr_atomic_inc32 group__apr__atomic.html ga5 (volatile apr_uint32_t *mem) int apr_atomic_dec32 group__apr__atomic.html ga6 (volatile apr_uint32_t *mem) apr_uint32_t apr_atomic_cas32 group__apr__atomic.html ga7 (volatile apr_uint32_t *mem, apr_uint32_t with, apr_uint32_t cmp) apr_uint32_t apr_atomic_xchg32 group__apr__atomic.html ga8 (volatile apr_uint32_t *mem, apr_uint32_t val) void * apr_atomic_casptr group__apr__atomic.html ga9 (volatile void **mem, void *with, const void *cmp) apr_dso Dynamic Object Handling group__apr__dso.html apr_dso_handle_t apr_dso_handle_t group__apr__dso.html ga0 void * apr_dso_handle_sym_t group__apr__dso.html ga1 apr_status_t apr_dso_load group__apr__dso.html ga2 (apr_dso_handle_t **res_handle, const char *path, apr_pool_t *ctx) apr_status_t apr_dso_unload group__apr__dso.html ga3 (apr_dso_handle_t *handle) apr_status_t apr_dso_sym group__apr__dso.html ga4 (apr_dso_handle_sym_t *ressym, apr_dso_handle_t *handle, const char *symname) const char * apr_dso_error group__apr__dso.html ga5 (apr_dso_handle_t *dso, char *buf, apr_size_t bufsize) apr_env Functions for manupulating the environment group__apr__env.html apr_status_t apr_env_get group__apr__env.html ga0 (char **value, const char *envvar, apr_pool_t *pool) apr_status_t apr_env_set group__apr__env.html ga1 (const char *envvar, const char *value, apr_pool_t *pool) apr_status_t apr_env_delete group__apr__env.html ga2 (const char *envvar, apr_pool_t *pool) apr_errno Error Codes group__apr__errno.html APR_Error APR_STATUS_IS #define APR_FROM_OS_ERROR group__apr__errno.html ga2 (e) #define APR_FROM_OS_ERROR group__apr__errno.html ga3 (e) #define APR_TO_OS_ERROR group__apr__errno.html ga4 (e) #define APR_TO_OS_ERROR group__apr__errno.html ga5 (e) #define apr_get_os_error group__apr__errno.html ga6 () #define apr_set_os_error group__apr__errno.html ga7 (e) #define apr_get_netos_error group__apr__errno.html ga8 () #define apr_set_netos_error group__apr__errno.html ga9 (e) #define APR_OS_START_ERROR group__apr__errno.html ga10 #define APR_OS_ERRSPACE_SIZE group__apr__errno.html ga11 #define APR_OS_START_STATUS group__apr__errno.html ga12 #define APR_OS_START_USERERR group__apr__errno.html ga13 #define APR_OS_START_USEERR group__apr__errno.html ga14 #define APR_OS_START_CANONERR group__apr__errno.html ga15 #define APR_OS_START_EAIERR group__apr__errno.html ga16 #define APR_OS_START_SYSERR group__apr__errno.html ga17 #define APR_SUCCESS group__apr__errno.html ga18 int apr_status_t group__apr__errno.html ga0 char * apr_strerror group__apr__errno.html ga1 (apr_status_t statcode, char *buf, apr_size_t bufsize) APR_Error APR Error Values group___a_p_r___error.html #define APR_ENOSTAT group___a_p_r___error.html ga0 #define APR_ENOPOOL group___a_p_r___error.html ga1 #define APR_EBADDATE group___a_p_r___error.html ga2 #define APR_EINVALSOCK group___a_p_r___error.html ga3 #define APR_ENOPROC group___a_p_r___error.html ga4 #define APR_ENOTIME group___a_p_r___error.html ga5 #define APR_ENODIR group___a_p_r___error.html ga6 #define APR_ENOLOCK group___a_p_r___error.html ga7 #define APR_ENOPOLL group___a_p_r___error.html ga8 #define APR_ENOSOCKET group___a_p_r___error.html ga9 #define APR_ENOTHREAD group___a_p_r___error.html ga10 #define APR_ENOTHDKEY group___a_p_r___error.html ga11 #define APR_EGENERAL group___a_p_r___error.html ga12 #define APR_ENOSHMAVAIL group___a_p_r___error.html ga13 #define APR_EBADIP group___a_p_r___error.html ga14 #define APR_EBADMASK group___a_p_r___error.html ga15 #define APR_EDSOOPEN group___a_p_r___error.html ga16 #define APR_EABSOLUTE group___a_p_r___error.html ga17 #define APR_ERELATIVE group___a_p_r___error.html ga18 #define APR_EINCOMPLETE group___a_p_r___error.html ga19 #define APR_EABOVEROOT group___a_p_r___error.html ga20 #define APR_EBADPATH group___a_p_r___error.html ga21 #define APR_EPATHWILD group___a_p_r___error.html ga22 #define APR_ESYMNOTFOUND group___a_p_r___error.html ga23 #define APR_EPROC_UNKNOWN group___a_p_r___error.html ga24 #define APR_ENOTENOUGHENTROPY group___a_p_r___error.html ga25 #define APR_INCHILD group___a_p_r___error.html ga26 #define APR_INPARENT group___a_p_r___error.html ga27 #define APR_DETACH group___a_p_r___error.html ga28 #define APR_NOTDETACH group___a_p_r___error.html ga29 #define APR_CHILD_DONE group___a_p_r___error.html ga30 #define APR_CHILD_NOTDONE group___a_p_r___error.html ga31 #define APR_TIMEUP group___a_p_r___error.html ga32 #define APR_INCOMPLETE group___a_p_r___error.html ga33 #define APR_BADCH group___a_p_r___error.html ga34 #define APR_BADARG group___a_p_r___error.html ga35 #define APR_EOF group___a_p_r___error.html ga36 #define APR_NOTFOUND group___a_p_r___error.html ga37 #define APR_ANONYMOUS group___a_p_r___error.html ga38 #define APR_FILEBASED group___a_p_r___error.html ga39 #define APR_KEYBASED group___a_p_r___error.html ga40 #define APR_EINIT group___a_p_r___error.html ga41 #define APR_ENOTIMPL group___a_p_r___error.html ga42 #define APR_EMISMATCH group___a_p_r___error.html ga43 #define APR_EBUSY group___a_p_r___error.html ga44 #define APR_EACCES group___a_p_r___error.html ga45 #define APR_EEXIST group___a_p_r___error.html ga46 #define APR_ENAMETOOLONG group___a_p_r___error.html ga47 #define APR_ENOENT group___a_p_r___error.html ga48 #define APR_ENOTDIR group___a_p_r___error.html ga49 #define APR_ENOSPC group___a_p_r___error.html ga50 #define APR_ENOMEM group___a_p_r___error.html ga51 #define APR_EMFILE group___a_p_r___error.html ga52 #define APR_ENFILE group___a_p_r___error.html ga53 #define APR_EBADF group___a_p_r___error.html ga54 #define APR_EINVAL group___a_p_r___error.html ga55 #define APR_ESPIPE group___a_p_r___error.html ga56 #define APR_EAGAIN group___a_p_r___error.html ga57 #define APR_EINTR group___a_p_r___error.html ga58 #define APR_ENOTSOCK group___a_p_r___error.html ga59 #define APR_ECONNREFUSED group___a_p_r___error.html ga60 #define APR_EINPROGRESS group___a_p_r___error.html ga61 #define APR_ECONNABORTED group___a_p_r___error.html ga62 #define APR_ECONNRESET group___a_p_r___error.html ga63 #define APR_ETIMEDOUT group___a_p_r___error.html ga64 #define APR_EHOSTUNREACH group___a_p_r___error.html ga65 #define APR_ENETUNREACH group___a_p_r___error.html ga66 #define APR_EFTYPE group___a_p_r___error.html ga67 #define APR_EPIPE group___a_p_r___error.html ga68 #define APR_EXDEV group___a_p_r___error.html ga69 #define APR_ENOTEMPTY group___a_p_r___error.html ga70 APR_STATUS_IS Status Value Tests group___a_p_r___s_t_a_t_u_s___i_s.html #define APR_STATUS_IS_ENOSTAT group___a_p_r___s_t_a_t_u_s___i_s.html ga0 (s) #define APR_STATUS_IS_ENOPOOL group___a_p_r___s_t_a_t_u_s___i_s.html ga1 (s) #define APR_STATUS_IS_EBADDATE group___a_p_r___s_t_a_t_u_s___i_s.html ga2 (s) #define APR_STATUS_IS_EINVALSOCK group___a_p_r___s_t_a_t_u_s___i_s.html ga3 (s) #define APR_STATUS_IS_ENOPROC group___a_p_r___s_t_a_t_u_s___i_s.html ga4 (s) #define APR_STATUS_IS_ENOTIME group___a_p_r___s_t_a_t_u_s___i_s.html ga5 (s) #define APR_STATUS_IS_ENODIR group___a_p_r___s_t_a_t_u_s___i_s.html ga6 (s) #define APR_STATUS_IS_ENOLOCK group___a_p_r___s_t_a_t_u_s___i_s.html ga7 (s) #define APR_STATUS_IS_ENOPOLL group___a_p_r___s_t_a_t_u_s___i_s.html ga8 (s) #define APR_STATUS_IS_ENOSOCKET group___a_p_r___s_t_a_t_u_s___i_s.html ga9 (s) #define APR_STATUS_IS_ENOTHREAD group___a_p_r___s_t_a_t_u_s___i_s.html ga10 (s) #define APR_STATUS_IS_ENOTHDKEY group___a_p_r___s_t_a_t_u_s___i_s.html ga11 (s) #define APR_STATUS_IS_EGENERAL group___a_p_r___s_t_a_t_u_s___i_s.html ga12 (s) #define APR_STATUS_IS_ENOSHMAVAIL group___a_p_r___s_t_a_t_u_s___i_s.html ga13 (s) #define APR_STATUS_IS_EBADIP group___a_p_r___s_t_a_t_u_s___i_s.html ga14 (s) #define APR_STATUS_IS_EBADMASK group___a_p_r___s_t_a_t_u_s___i_s.html ga15 (s) #define APR_STATUS_IS_EDSOOPEN group___a_p_r___s_t_a_t_u_s___i_s.html ga16 (s) #define APR_STATUS_IS_EABSOLUTE group___a_p_r___s_t_a_t_u_s___i_s.html ga17 (s) #define APR_STATUS_IS_ERELATIVE group___a_p_r___s_t_a_t_u_s___i_s.html ga18 (s) #define APR_STATUS_IS_EINCOMPLETE group___a_p_r___s_t_a_t_u_s___i_s.html ga19 (s) #define APR_STATUS_IS_EABOVEROOT group___a_p_r___s_t_a_t_u_s___i_s.html ga20 (s) #define APR_STATUS_IS_EBADPATH group___a_p_r___s_t_a_t_u_s___i_s.html ga21 (s) #define APR_STATUS_IS_EPATHWILD group___a_p_r___s_t_a_t_u_s___i_s.html ga22 (s) #define APR_STATUS_IS_ESYMNOTFOUND group___a_p_r___s_t_a_t_u_s___i_s.html ga23 (s) #define APR_STATUS_IS_EPROC_UNKNOWN group___a_p_r___s_t_a_t_u_s___i_s.html ga24 (s) #define APR_STATUS_IS_ENOTENOUGHENTROPY group___a_p_r___s_t_a_t_u_s___i_s.html ga25 (s) #define APR_STATUS_IS_INCHILD group___a_p_r___s_t_a_t_u_s___i_s.html ga26 (s) #define APR_STATUS_IS_INPARENT group___a_p_r___s_t_a_t_u_s___i_s.html ga27 (s) #define APR_STATUS_IS_DETACH group___a_p_r___s_t_a_t_u_s___i_s.html ga28 (s) #define APR_STATUS_IS_NOTDETACH group___a_p_r___s_t_a_t_u_s___i_s.html ga29 (s) #define APR_STATUS_IS_CHILD_DONE group___a_p_r___s_t_a_t_u_s___i_s.html ga30 (s) #define APR_STATUS_IS_CHILD_NOTDONE group___a_p_r___s_t_a_t_u_s___i_s.html ga31 (s) #define APR_STATUS_IS_TIMEUP group___a_p_r___s_t_a_t_u_s___i_s.html ga32 (s) #define APR_STATUS_IS_INCOMPLETE group___a_p_r___s_t_a_t_u_s___i_s.html ga33 (s) #define APR_STATUS_IS_BADCH group___a_p_r___s_t_a_t_u_s___i_s.html ga34 (s) #define APR_STATUS_IS_BADARG group___a_p_r___s_t_a_t_u_s___i_s.html ga35 (s) #define APR_STATUS_IS_EOF group___a_p_r___s_t_a_t_u_s___i_s.html ga36 (s) #define APR_STATUS_IS_NOTFOUND group___a_p_r___s_t_a_t_u_s___i_s.html ga37 (s) #define APR_STATUS_IS_ANONYMOUS group___a_p_r___s_t_a_t_u_s___i_s.html ga38 (s) #define APR_STATUS_IS_FILEBASED group___a_p_r___s_t_a_t_u_s___i_s.html ga39 (s) #define APR_STATUS_IS_KEYBASED group___a_p_r___s_t_a_t_u_s___i_s.html ga40 (s) #define APR_STATUS_IS_EINIT group___a_p_r___s_t_a_t_u_s___i_s.html ga41 (s) #define APR_STATUS_IS_ENOTIMPL group___a_p_r___s_t_a_t_u_s___i_s.html ga42 (s) #define APR_STATUS_IS_EMISMATCH group___a_p_r___s_t_a_t_u_s___i_s.html ga43 (s) #define APR_STATUS_IS_EBUSY group___a_p_r___s_t_a_t_u_s___i_s.html ga44 (s) #define APR_STATUS_IS_EACCES group___a_p_r___s_t_a_t_u_s___i_s.html ga45 (s) #define APR_STATUS_IS_EEXIST group___a_p_r___s_t_a_t_u_s___i_s.html ga46 (s) #define APR_STATUS_IS_ENAMETOOLONG group___a_p_r___s_t_a_t_u_s___i_s.html ga47 (s) #define APR_STATUS_IS_ENOENT group___a_p_r___s_t_a_t_u_s___i_s.html ga48 (s) #define APR_STATUS_IS_ENOTDIR group___a_p_r___s_t_a_t_u_s___i_s.html ga49 (s) #define APR_STATUS_IS_ENOSPC group___a_p_r___s_t_a_t_u_s___i_s.html ga50 (s) #define APR_STATUS_IS_ENOMEM group___a_p_r___s_t_a_t_u_s___i_s.html ga51 (s) #define APR_STATUS_IS_EMFILE group___a_p_r___s_t_a_t_u_s___i_s.html ga52 (s) #define APR_STATUS_IS_ENFILE group___a_p_r___s_t_a_t_u_s___i_s.html ga53 (s) #define APR_STATUS_IS_EBADF group___a_p_r___s_t_a_t_u_s___i_s.html ga54 (s) #define APR_STATUS_IS_EINVAL group___a_p_r___s_t_a_t_u_s___i_s.html ga55 (s) #define APR_STATUS_IS_ESPIPE group___a_p_r___s_t_a_t_u_s___i_s.html ga56 (s) #define APR_STATUS_IS_EAGAIN group___a_p_r___s_t_a_t_u_s___i_s.html ga57 (s) #define APR_STATUS_IS_EINTR group___a_p_r___s_t_a_t_u_s___i_s.html ga58 (s) #define APR_STATUS_IS_ENOTSOCK group___a_p_r___s_t_a_t_u_s___i_s.html ga59 (s) #define APR_STATUS_IS_ECONNREFUSED group___a_p_r___s_t_a_t_u_s___i_s.html ga60 (s) #define APR_STATUS_IS_EINPROGRESS group___a_p_r___s_t_a_t_u_s___i_s.html ga61 (s) #define APR_STATUS_IS_ECONNABORTED group___a_p_r___s_t_a_t_u_s___i_s.html ga62 (s) #define APR_STATUS_IS_ECONNRESET group___a_p_r___s_t_a_t_u_s___i_s.html ga63 (s) #define APR_STATUS_IS_ETIMEDOUT group___a_p_r___s_t_a_t_u_s___i_s.html ga64 (s) #define APR_STATUS_IS_EHOSTUNREACH group___a_p_r___s_t_a_t_u_s___i_s.html ga65 (s) #define APR_STATUS_IS_ENETUNREACH group___a_p_r___s_t_a_t_u_s___i_s.html ga66 (s) #define APR_STATUS_IS_EFTYPE group___a_p_r___s_t_a_t_u_s___i_s.html ga67 (s) #define APR_STATUS_IS_EPIPE group___a_p_r___s_t_a_t_u_s___i_s.html ga68 (s) #define APR_STATUS_IS_EXDEV group___a_p_r___s_t_a_t_u_s___i_s.html ga69 (s) #define APR_STATUS_IS_ENOTEMPTY group___a_p_r___s_t_a_t_u_s___i_s.html ga70 (s) apr_file_info File Information group__apr__file__info.html apr_file_permissions apr_file_stat apr_dir apr_filepath apr_dir_t apr_dir_t group__apr__file__info.html ga0 apr_int32_t apr_fileperms_t group__apr__file__info.html ga1 ino_t apr_ino_t group__apr__file__info.html ga2 dev_t apr_dev_t group__apr__file__info.html ga3 apr_filetype_e ga4 APR_NOFILE gga4a66 APR_REG gga4a67 APR_DIR gga4a68 APR_CHR gga4a69 APR_BLK gga4a70 APR_PIPE gga4a71 APR_LNK gga4a72 APR_SOCK gga4a73 APR_UNKFILE gga4a74 apr_file_permissions File Permissions flags group__apr__file__permissions.html #define APR_FPROT_USETID group__apr__file__permissions.html ga0 #define APR_FPROT_UREAD group__apr__file__permissions.html ga1 #define APR_FPROT_UWRITE group__apr__file__permissions.html ga2 #define APR_FPROT_UEXECUTE group__apr__file__permissions.html ga3 #define APR_FPROT_GSETID group__apr__file__permissions.html ga4 #define APR_FPROT_GREAD group__apr__file__permissions.html ga5 #define APR_FPROT_GWRITE group__apr__file__permissions.html ga6 #define APR_FPROT_GEXECUTE group__apr__file__permissions.html ga7 #define APR_FPROT_WSTICKY group__apr__file__permissions.html ga8 #define APR_FPROT_WREAD group__apr__file__permissions.html ga9 #define APR_FPROT_WWRITE group__apr__file__permissions.html ga10 #define APR_FPROT_WEXECUTE group__apr__file__permissions.html ga11 #define APR_FPROT_OS_DEFAULT group__apr__file__permissions.html ga12 #define APR_FPROT_FILE_SOURCE_PERMS group__apr__file__permissions.html ga13 #define APR_USETID group__apr__file__permissions.html ga14 #define APR_UREAD group__apr__file__permissions.html ga15 #define APR_UWRITE group__apr__file__permissions.html ga16 #define APR_UEXECUTE group__apr__file__permissions.html ga17 #define APR_GSETID group__apr__file__permissions.html ga18 #define APR_GREAD group__apr__file__permissions.html ga19 #define APR_GWRITE group__apr__file__permissions.html ga20 #define APR_GEXECUTE group__apr__file__permissions.html ga21 #define APR_WSTICKY group__apr__file__permissions.html ga22 #define APR_WREAD group__apr__file__permissions.html ga23 #define APR_WWRITE group__apr__file__permissions.html ga24 #define APR_WEXECUTE group__apr__file__permissions.html ga25 #define APR_OS_DEFAULT group__apr__file__permissions.html ga26 #define APR_FILE_SOURCE_PERMS group__apr__file__permissions.html ga27 apr_file_stat Stat Functions group__apr__file__stat.html apr_finfo_t #define APR_FINFO_LINK group__apr__file__stat.html ga2 #define APR_FINFO_MTIME group__apr__file__stat.html ga3 #define APR_FINFO_CTIME group__apr__file__stat.html ga4 #define APR_FINFO_ATIME group__apr__file__stat.html ga5 #define APR_FINFO_SIZE group__apr__file__stat.html ga6 #define APR_FINFO_CSIZE group__apr__file__stat.html ga7 #define APR_FINFO_DEV group__apr__file__stat.html ga8 #define APR_FINFO_INODE group__apr__file__stat.html ga9 #define APR_FINFO_NLINK group__apr__file__stat.html ga10 #define APR_FINFO_TYPE group__apr__file__stat.html ga11 #define APR_FINFO_USER group__apr__file__stat.html ga12 #define APR_FINFO_GROUP group__apr__file__stat.html ga13 #define APR_FINFO_UPROT group__apr__file__stat.html ga14 #define APR_FINFO_GPROT group__apr__file__stat.html ga15 #define APR_FINFO_WPROT group__apr__file__stat.html ga16 #define APR_FINFO_ICASE group__apr__file__stat.html ga17 #define APR_FINFO_NAME group__apr__file__stat.html ga18 #define APR_FINFO_MIN group__apr__file__stat.html ga19 #define APR_FINFO_IDENT group__apr__file__stat.html ga20 #define APR_FINFO_OWNER group__apr__file__stat.html ga21 #define APR_FINFO_PROT group__apr__file__stat.html ga22 #define APR_FINFO_NORM group__apr__file__stat.html ga23 #define APR_FINFO_DIRENT group__apr__file__stat.html ga24 apr_finfo_t apr_finfo_t group__apr__file__stat.html ga0 apr_status_t apr_stat group__apr__file__stat.html ga1 (apr_finfo_t *finfo, const char *fname, apr_int32_t wanted, apr_pool_t *pool) apr_dir Directory Manipulation Functions group__apr__dir.html apr_status_t apr_dir_open group__apr__dir.html ga0 (apr_dir_t **new_dir, const char *dirname, apr_pool_t *pool) apr_status_t apr_dir_close group__apr__dir.html ga1 (apr_dir_t *thedir) apr_status_t apr_dir_read group__apr__dir.html ga2 (apr_finfo_t *finfo, apr_int32_t wanted, apr_dir_t *thedir) apr_status_t apr_dir_rewind group__apr__dir.html ga3 (apr_dir_t *thedir) apr_filepath Filepath Manipulation Functions group__apr__filepath.html #define APR_FILEPATH_NOTABOVEROOT group__apr__filepath.html ga7 #define APR_FILEPATH_SECUREROOTTEST group__apr__filepath.html ga8 #define APR_FILEPATH_SECUREROOT group__apr__filepath.html ga9 #define APR_FILEPATH_NOTRELATIVE group__apr__filepath.html ga10 #define APR_FILEPATH_NOTABSOLUTE group__apr__filepath.html ga11 #define APR_FILEPATH_NATIVE group__apr__filepath.html ga12 #define APR_FILEPATH_TRUENAME group__apr__filepath.html ga13 #define APR_FILEPATH_ENCODING_UNKNOWN group__apr__filepath.html ga14 #define APR_FILEPATH_ENCODING_LOCALE group__apr__filepath.html ga15 #define APR_FILEPATH_ENCODING_UTF8 group__apr__filepath.html ga16 apr_status_t apr_filepath_root group__apr__filepath.html ga0 (const char **rootpath, const char **filepath, apr_int32_t flags, apr_pool_t *p) apr_status_t apr_filepath_merge group__apr__filepath.html ga1 (char **newpath, const char *rootpath, const char *addpath, apr_int32_t flags, apr_pool_t *p) apr_status_t apr_filepath_list_split group__apr__filepath.html ga2 (apr_array_header_t **pathelts, const char *liststr, apr_pool_t *p) apr_status_t apr_filepath_list_merge group__apr__filepath.html ga3 (char **liststr, apr_array_header_t *pathelts, apr_pool_t *p) apr_status_t apr_filepath_get group__apr__filepath.html ga4 (char **path, apr_int32_t flags, apr_pool_t *p) apr_status_t apr_filepath_set group__apr__filepath.html ga5 (const char *path, apr_pool_t *p) apr_status_t apr_filepath_encoding group__apr__filepath.html ga6 (int *style, apr_pool_t *p) apr_file_io File I/O Handling Functions group__apr__file__io.html apr_file_open_flags apr_file_seek_flags apr_file_attrs_set_flags apr_file_writev apr_file_lock_types apr_uint32_t apr_fileattrs_t group__apr__file__io.html ga0 int apr_seek_where_t group__apr__file__io.html ga1 apr_file_t apr_file_t group__apr__file__io.html ga2 apr_status_t apr_file_open group__apr__file__io.html ga3 (apr_file_t **newf, const char *fname, apr_int32_t flag, apr_fileperms_t perm, apr_pool_t *pool) apr_status_t apr_file_close group__apr__file__io.html ga4 (apr_file_t *file) apr_status_t apr_file_remove group__apr__file__io.html ga5 (const char *path, apr_pool_t *pool) apr_status_t apr_file_rename group__apr__file__io.html ga6 (const char *from_path, const char *to_path, apr_pool_t *pool) apr_status_t apr_file_copy group__apr__file__io.html ga7 (const char *from_path, const char *to_path, apr_fileperms_t perms, apr_pool_t *pool) apr_status_t apr_file_append group__apr__file__io.html ga8 (const char *from_path, const char *to_path, apr_fileperms_t perms, apr_pool_t *pool) apr_status_t apr_file_eof group__apr__file__io.html ga9 (apr_file_t *fptr) apr_status_t apr_file_open_stderr group__apr__file__io.html ga10 (apr_file_t **thefile, apr_pool_t *pool) apr_status_t apr_file_open_stdout group__apr__file__io.html ga11 (apr_file_t **thefile, apr_pool_t *pool) apr_status_t apr_file_open_stdin group__apr__file__io.html ga12 (apr_file_t **thefile, apr_pool_t *pool) apr_status_t apr_file_read group__apr__file__io.html ga13 (apr_file_t *thefile, void *buf, apr_size_t *nbytes) apr_status_t apr_file_write group__apr__file__io.html ga14 (apr_file_t *thefile, const void *buf, apr_size_t *nbytes) apr_status_t apr_file_writev group__apr__file__io.html ga15 (apr_file_t *thefile, const struct iovec *vec, apr_size_t nvec, apr_size_t *nbytes) apr_status_t apr_file_read_full group__apr__file__io.html ga16 (apr_file_t *thefile, void *buf, apr_size_t nbytes, apr_size_t *bytes_read) apr_status_t apr_file_write_full group__apr__file__io.html ga17 (apr_file_t *thefile, const void *buf, apr_size_t nbytes, apr_size_t *bytes_written) apr_status_t apr_file_writev_full group__apr__file__io.html ga18 (apr_file_t *thefile, const struct iovec *vec, apr_size_t nvec, apr_size_t *nbytes) apr_status_t apr_file_putc group__apr__file__io.html ga19 (char ch, apr_file_t *thefile) apr_status_t apr_file_getc group__apr__file__io.html ga20 (char *ch, apr_file_t *thefile) apr_status_t apr_file_ungetc group__apr__file__io.html ga21 (char ch, apr_file_t *thefile) apr_status_t apr_file_gets group__apr__file__io.html ga22 (char *str, int len, apr_file_t *thefile) apr_status_t apr_file_puts group__apr__file__io.html ga23 (const char *str, apr_file_t *thefile) apr_status_t apr_file_flush group__apr__file__io.html ga24 (apr_file_t *thefile) apr_status_t apr_file_dup group__apr__file__io.html ga25 (apr_file_t **new_file, apr_file_t *old_file, apr_pool_t *p) apr_status_t apr_file_dup2 group__apr__file__io.html ga26 (apr_file_t *new_file, apr_file_t *old_file, apr_pool_t *p) apr_status_t apr_file_setaside group__apr__file__io.html ga27 (apr_file_t **new_file, apr_file_t *old_file, apr_pool_t *p) apr_status_t apr_file_seek group__apr__file__io.html ga28 (apr_file_t *thefile, apr_seek_where_t where, apr_off_t *offset) apr_status_t apr_file_pipe_create group__apr__file__io.html ga29 (apr_file_t **in, apr_file_t **out, apr_pool_t *pool) apr_status_t apr_file_namedpipe_create group__apr__file__io.html ga30 (const char *filename, apr_fileperms_t perm, apr_pool_t *pool) apr_status_t apr_file_pipe_timeout_get group__apr__file__io.html ga31 (apr_file_t *thepipe, apr_interval_time_t *timeout) apr_status_t apr_file_pipe_timeout_set group__apr__file__io.html ga32 (apr_file_t *thepipe, apr_interval_time_t timeout) apr_status_t apr_file_lock group__apr__file__io.html ga33 (apr_file_t *thefile, int type) apr_status_t apr_file_unlock group__apr__file__io.html ga34 (apr_file_t *thefile) apr_status_t apr_file_name_get group__apr__file__io.html ga35 (const char **new_path, apr_file_t *thefile) apr_status_t apr_file_data_get group__apr__file__io.html ga36 (void **data, const char *key, apr_file_t *file) apr_status_t apr_file_data_set group__apr__file__io.html ga37 (apr_file_t *file, void *data, const char *key, apr_status_t(*cleanup)(void *)) int apr_file_printf group__apr__file__io.html ga38 (apr_file_t *fptr, const char *format,...) apr_status_t apr_file_perms_set group__apr__file__io.html ga39 (const char *fname, apr_fileperms_t perms) apr_status_t apr_file_attrs_set group__apr__file__io.html ga40 (const char *fname, apr_fileattrs_t attributes, apr_fileattrs_t attr_mask, apr_pool_t *pool) apr_status_t apr_file_mtime_set group__apr__file__io.html ga41 (const char *fname, apr_time_t mtime, apr_pool_t *pool) apr_status_t apr_dir_make group__apr__file__io.html ga42 (const char *path, apr_fileperms_t perm, apr_pool_t *pool) apr_status_t apr_dir_make_recursive group__apr__file__io.html ga43 (const char *path, apr_fileperms_t perm, apr_pool_t *pool) apr_status_t apr_dir_remove group__apr__file__io.html ga44 (const char *path, apr_pool_t *pool) apr_status_t apr_file_info_get group__apr__file__io.html ga45 (apr_finfo_t *finfo, apr_int32_t wanted, apr_file_t *thefile) apr_status_t apr_file_trunc group__apr__file__io.html ga46 (apr_file_t *fp, apr_off_t offset) apr_int32_t apr_file_flags_get group__apr__file__io.html ga47 (apr_file_t *f) apr_pool_t * apr_file_pool_get group__apr__file__io.html ga48 (const apr_file_t *thefile) apr_status_t apr_file_inherit_set group__apr__file__io.html ga49 (apr_file_t *thefile) apr_status_t apr_file_inherit_unset group__apr__file__io.html ga50 (apr_file_t *thefile) apr_status_t apr_file_mktemp group__apr__file__io.html ga51 (apr_file_t **fp, char *templ, apr_int32_t flags, apr_pool_t *p) apr_status_t apr_temp_dir_get group__apr__file__io.html ga52 (const char **temp_dir, apr_pool_t *p) apr_file_open_flags File Open Flags/Routines group__apr__file__open__flags.html #define APR_FOPEN_READ group__apr__file__open__flags.html ga0 #define APR_FOPEN_WRITE group__apr__file__open__flags.html ga1 #define APR_FOPEN_CREATE group__apr__file__open__flags.html ga2 #define APR_FOPEN_APPEND group__apr__file__open__flags.html ga3 #define APR_FOPEN_TRUNCATE group__apr__file__open__flags.html ga4 #define APR_FOPEN_BINARY group__apr__file__open__flags.html ga5 #define APR_FOPEN_EXCL group__apr__file__open__flags.html ga6 #define APR_FOPEN_BUFFERED group__apr__file__open__flags.html ga7 #define APR_FOPEN_DELONCLOSE group__apr__file__open__flags.html ga8 #define APR_FOPEN_XTHREAD group__apr__file__open__flags.html ga9 #define APR_FOPEN_SHARELOCK group__apr__file__open__flags.html ga10 #define APR_FOPEN_NOCLEANUP group__apr__file__open__flags.html ga11 #define APR_FOPEN_SENDFILE_ENABLED group__apr__file__open__flags.html ga12 #define APR_FOPEN_LARGEFILE group__apr__file__open__flags.html ga13 #define APR_READ group__apr__file__open__flags.html ga14 #define APR_WRITE group__apr__file__open__flags.html ga15 #define APR_CREATE group__apr__file__open__flags.html ga16 #define APR_APPEND group__apr__file__open__flags.html ga17 #define APR_TRUNCATE group__apr__file__open__flags.html ga18 #define APR_BINARY group__apr__file__open__flags.html ga19 #define APR_EXCL group__apr__file__open__flags.html ga20 #define APR_BUFFERED group__apr__file__open__flags.html ga21 #define APR_DELONCLOSE group__apr__file__open__flags.html ga22 #define APR_XTHREAD group__apr__file__open__flags.html ga23 #define APR_SHARELOCK group__apr__file__open__flags.html ga24 #define APR_FILE_NOCLEANUP group__apr__file__open__flags.html ga25 #define APR_SENDFILE_ENABLED group__apr__file__open__flags.html ga26 #define APR_LARGEFILE group__apr__file__open__flags.html ga27 apr_file_seek_flags File Seek Flags group__apr__file__seek__flags.html #define APR_SET group__apr__file__seek__flags.html ga0 #define APR_CUR group__apr__file__seek__flags.html ga1 #define APR_END group__apr__file__seek__flags.html ga2 apr_file_attrs_set_flags File Attribute Flags group__apr__file__attrs__set__flags.html #define APR_FILE_ATTR_READONLY group__apr__file__attrs__set__flags.html ga0 #define APR_FILE_ATTR_EXECUTABLE group__apr__file__attrs__set__flags.html ga1 #define APR_FILE_ATTR_HIDDEN group__apr__file__attrs__set__flags.html ga2 apr_file_writev {_full} max iovec size group__apr__file__writev.html #define APR_MAX_IOVEC_SIZE group__apr__file__writev.html ga0 apr_file_lock_types File Lock Types group__apr__file__lock__types.html #define APR_FLOCK_SHARED group__apr__file__lock__types.html ga0 #define APR_FLOCK_EXCLUSIVE group__apr__file__lock__types.html ga1 #define APR_FLOCK_TYPEMASK group__apr__file__lock__types.html ga2 #define APR_FLOCK_NONBLOCK group__apr__file__lock__types.html ga3 apr_fnmatch Filename Matching Functions group__apr__fnmatch.html #define APR_FNM_NOMATCH group__apr__fnmatch.html ga3 #define APR_FNM_NOESCAPE group__apr__fnmatch.html ga4 #define APR_FNM_PATHNAME group__apr__fnmatch.html ga5 #define APR_FNM_PERIOD group__apr__fnmatch.html ga6 #define APR_FNM_CASE_BLIND group__apr__fnmatch.html ga7 apr_status_t apr_fnmatch group__apr__fnmatch.html ga0 (const char *pattern, const char *strings, int flags) int apr_fnmatch_test group__apr__fnmatch.html ga1 (const char *pattern) apr_status_t apr_match_glob group__apr__fnmatch.html ga2 (const char *pattern, apr_array_header_t **result, apr_pool_t *p) apr_general Miscellaneous library routines group__apr__general.html #define FALSE group__apr__general.html ga1 #define TRUE group__apr__general.html ga2 #define APR_ASCII_BLANK group__apr__general.html ga3 #define APR_ASCII_CR group__apr__general.html ga4 #define APR_ASCII_LF group__apr__general.html ga5 #define APR_ASCII_TAB group__apr__general.html ga6 #define APR_OFFSET group__apr__general.html ga7 (p_type, field) #define APR_OFFSETOF group__apr__general.html ga8 (s_type, field) #define APR_ALIGN group__apr__general.html ga9 (size, boundary) #define APR_ALIGN_DEFAULT group__apr__general.html ga10 (size) #define APR_STRINGIFY group__apr__general.html ga11 (n) #define APR_STRINGIFY_HELPER group__apr__general.html ga12 (n) int apr_signum_t group__apr__general.html ga0 apr_library Library initialization and termination group__apr__library.html apr_status_t apr_initialize group__apr__library.html ga0 (void) apr_status_t apr_app_initialize group__apr__library.html ga1 (int *argc, char const *const **argv, char const *const **env) void apr_terminate group__apr__library.html ga2 (void) void apr_terminate2 group__apr__library.html ga3 (void) apr_random Random Functions group__apr__random.html apr_status_t apr_generate_random_bytes group__apr__random.html ga0 (unsigned char *buf, apr_size_t length) apr_getopt Command Argument Parsing group__apr__getopt.html apr_getopt_t apr_getopt_option_t void( apr_getopt_err_fn_t group__apr__getopt.html ga0 )(void *arg, const char *err,...) apr_getopt_t apr_getopt_t group__apr__getopt.html ga1 apr_getopt_option_t apr_getopt_option_t group__apr__getopt.html ga2 apr_status_t apr_getopt_init group__apr__getopt.html ga3 (apr_getopt_t **os, apr_pool_t *cont, int argc, const char *const *argv) apr_status_t apr_getopt group__apr__getopt.html ga4 (apr_getopt_t *os, const char *opts, char *option_ch, const char **option_arg) apr_status_t apr_getopt_long group__apr__getopt.html ga5 (apr_getopt_t *os, const apr_getopt_option_t *opts, int *option_ch, const char **option_arg) APR_GlobalMutex Global Locking Routines group___a_p_r___global_mutex.html apr_global_mutex_t apr_global_mutex_t group___a_p_r___global_mutex.html ga0 apr_status_t apr_global_mutex_create group___a_p_r___global_mutex.html ga1 (apr_global_mutex_t **mutex, const char *fname, apr_lockmech_e mech, apr_pool_t *pool) apr_status_t apr_global_mutex_child_init group___a_p_r___global_mutex.html ga2 (apr_global_mutex_t **mutex, const char *fname, apr_pool_t *pool) apr_status_t apr_global_mutex_lock group___a_p_r___global_mutex.html ga3 (apr_global_mutex_t *mutex) apr_status_t apr_global_mutex_trylock group___a_p_r___global_mutex.html ga4 (apr_global_mutex_t *mutex) apr_status_t apr_global_mutex_unlock group___a_p_r___global_mutex.html ga5 (apr_global_mutex_t *mutex) apr_status_t apr_global_mutex_destroy group___a_p_r___global_mutex.html ga6 (apr_global_mutex_t *mutex) apr_pool_t * apr_global_mutex_pool_get group___a_p_r___global_mutex.html ga7 (const apr_global_mutex_t *theglobal_mutex) apr_hash Hash Tables group__apr__hash.html #define APR_HASH_KEY_STRING group__apr__hash.html ga16 apr_hash_t apr_hash_t group__apr__hash.html ga0 apr_hash_index_t apr_hash_index_t group__apr__hash.html ga1 unsigned int(* apr_hashfunc_t group__apr__hash.html ga2 )(const char *key, apr_ssize_t *klen) unsigned int apr_hashfunc_default group__apr__hash.html ga3 (const char *key, apr_ssize_t *klen) apr_hash_t * apr_hash_make group__apr__hash.html ga4 (apr_pool_t *pool) apr_hash_t * apr_hash_make_custom group__apr__hash.html ga5 (apr_pool_t *pool, apr_hashfunc_t hash_func) apr_hash_t * apr_hash_copy group__apr__hash.html ga6 (apr_pool_t *pool, const apr_hash_t *h) void apr_hash_set group__apr__hash.html ga7 (apr_hash_t *ht, const void *key, apr_ssize_t klen, const void *val) void * apr_hash_get group__apr__hash.html ga8 (apr_hash_t *ht, const void *key, apr_ssize_t klen) apr_hash_index_t * apr_hash_first group__apr__hash.html ga9 (apr_pool_t *p, apr_hash_t *ht) apr_hash_index_t * apr_hash_next group__apr__hash.html ga10 (apr_hash_index_t *hi) void apr_hash_this group__apr__hash.html ga11 (apr_hash_index_t *hi, const void **key, apr_ssize_t *klen, void **val) unsigned int apr_hash_count group__apr__hash.html ga12 (apr_hash_t *ht) apr_hash_t * apr_hash_overlay group__apr__hash.html ga13 (apr_pool_t *p, const apr_hash_t *overlay, const apr_hash_t *base) apr_hash_t * apr_hash_merge group__apr__hash.html ga14 (apr_pool_t *p, const apr_hash_t *h1, const apr_hash_t *h2, void *(*merger)(apr_pool_t *p, const void *key, apr_ssize_t klen, const void *h1_val, const void *h2_val, const void *data), const void *data) apr_pool_t * apr_hash_pool_get group__apr__hash.html ga15 (const apr_hash_t *thehash) apr_lib General Purpose Library Routines group__apr__lib.html apr_vformatter_buff_t #define HUGE_STRING_LEN group__apr__lib.html ga4 #define apr_killpg group__apr__lib.html ga5 (x, y) apr_vformatter_buff_t apr_vformatter_buff_t group__apr__lib.html ga0 const char * apr_filepath_name_get group__apr__lib.html ga1 (const char *pathname) int apr_vformatter group__apr__lib.html ga2 (int(*flush_func)(apr_vformatter_buff_t *b), apr_vformatter_buff_t *c, const char *fmt, va_list ap) apr_status_t apr_password_get group__apr__lib.html ga3 (const char *prompt, char *pwbuf, apr_size_t *bufsize) apr_ctype ctype functions group__apr__ctype.html #define apr_isalnum group__apr__ctype.html ga0 (c) #define apr_isalpha group__apr__ctype.html ga1 (c) #define apr_iscntrl group__apr__ctype.html ga2 (c) #define apr_isdigit group__apr__ctype.html ga3 (c) #define apr_isgraph group__apr__ctype.html ga4 (c) #define apr_islower group__apr__ctype.html ga5 (c) #define apr_isascii group__apr__ctype.html ga6 (c) #define apr_isprint group__apr__ctype.html ga7 (c) #define apr_ispunct group__apr__ctype.html ga8 (c) #define apr_isspace group__apr__ctype.html ga9 (c) #define apr_isupper group__apr__ctype.html ga10 (c) #define apr_isxdigit group__apr__ctype.html ga11 (c) #define apr_tolower group__apr__ctype.html ga12 (c) #define apr_toupper group__apr__ctype.html ga13 (c) apr_mmap MMAP (Memory Map) Routines group__apr__mmap.html apr_mmap_t #define APR_MMAP_READ group__apr__mmap.html ga5 #define APR_MMAP_WRITE group__apr__mmap.html ga6 #define APR_MMAP_THRESHOLD group__apr__mmap.html ga7 #define APR_MMAP_LIMIT group__apr__mmap.html ga8 #define APR_MMAP_CANDIDATE group__apr__mmap.html ga9 (filelength) apr_mmap_t apr_mmap_t group__apr__mmap.html ga0 apr_status_t apr_mmap_create group__apr__mmap.html ga1 (apr_mmap_t **newmmap, apr_file_t *file, apr_off_t offset, apr_size_t size, apr_int32_t flag, apr_pool_t *cntxt) apr_status_t apr_mmap_dup group__apr__mmap.html ga2 (apr_mmap_t **new_mmap, apr_mmap_t *old_mmap, apr_pool_t *p) apr_status_t apr_mmap_delete group__apr__mmap.html ga3 (apr_mmap_t *mm) apr_status_t apr_mmap_offset group__apr__mmap.html ga4 (void **addr, apr_mmap_t *mm, apr_off_t offset) apr_network_io Network Routines group__apr__network__io.html apr_sockopt IP_Proto apr_mcast apr_sockaddr_t apr_hdtr_t #define APR_MAX_SECS_TO_LINGER group__apr__network__io.html ga41 #define APRMAXHOSTLEN group__apr__network__io.html ga42 #define APR_ANYADDR group__apr__network__io.html ga43 #define APR_IPV4_ADDR_OK group__apr__network__io.html ga44 #define APR_IPV6_ADDR_OK group__apr__network__io.html ga45 #define APR_INADDR_NONE group__apr__network__io.html ga46 #define APR_INET group__apr__network__io.html ga47 #define APR_UNSPEC group__apr__network__io.html ga48 #define APR_INET6 group__apr__network__io.html ga49 #define apr_inet_addr group__apr__network__io.html ga50 #define APR_SENDFILE_DISCONNECT_SOCKET group__apr__network__io.html ga51 apr_socket_t apr_socket_t group__apr__network__io.html ga0 apr_hdtr_t apr_hdtr_t group__apr__network__io.html ga1 in_addr apr_in_addr_t group__apr__network__io.html ga2 apr_ipsubnet_t apr_ipsubnet_t group__apr__network__io.html ga3 apr_uint16_t apr_port_t group__apr__network__io.html ga4 apr_sockaddr_t apr_sockaddr_t group__apr__network__io.html ga5 apr_shutdown_how_e ga52 APR_SHUTDOWN_READ gga52a35 APR_SHUTDOWN_WRITE gga52a36 APR_SHUTDOWN_READWRITE gga52a37 apr_interface_e ga53 apr_status_t apr_socket_create group__apr__network__io.html ga6 (apr_socket_t **new_sock, int family, int type, int protocol, apr_pool_t *cont) apr_status_t apr_socket_shutdown group__apr__network__io.html ga7 (apr_socket_t *thesocket, apr_shutdown_how_e how) apr_status_t apr_socket_close group__apr__network__io.html ga8 (apr_socket_t *thesocket) apr_status_t apr_socket_bind group__apr__network__io.html ga9 (apr_socket_t *sock, apr_sockaddr_t *sa) apr_status_t apr_socket_listen group__apr__network__io.html ga10 (apr_socket_t *sock, apr_int32_t backlog) apr_status_t apr_socket_accept group__apr__network__io.html ga11 (apr_socket_t **new_sock, apr_socket_t *sock, apr_pool_t *connection_pool) apr_status_t apr_socket_connect group__apr__network__io.html ga12 (apr_socket_t *sock, apr_sockaddr_t *sa) apr_status_t apr_sockaddr_info_get group__apr__network__io.html ga13 (apr_sockaddr_t **sa, const char *hostname, apr_int32_t family, apr_port_t port, apr_int32_t flags, apr_pool_t *p) apr_status_t apr_getnameinfo group__apr__network__io.html ga14 (char **hostname, apr_sockaddr_t *sa, apr_int32_t flags) apr_status_t apr_parse_addr_port group__apr__network__io.html ga15 (char **addr, char **scope_id, apr_port_t *port, const char *str, apr_pool_t *p) apr_status_t apr_gethostname group__apr__network__io.html ga16 (char *buf, int len, apr_pool_t *cont) apr_status_t apr_socket_data_get group__apr__network__io.html ga17 (void **data, const char *key, apr_socket_t *sock) apr_status_t apr_socket_data_set group__apr__network__io.html ga18 (apr_socket_t *sock, void *data, const char *key, apr_status_t(*cleanup)(void *)) apr_status_t apr_socket_send group__apr__network__io.html ga19 (apr_socket_t *sock, const char *buf, apr_size_t *len) apr_status_t apr_socket_sendv group__apr__network__io.html ga20 (apr_socket_t *sock, const struct iovec *vec, apr_int32_t nvec, apr_size_t *len) apr_status_t apr_socket_sendto group__apr__network__io.html ga21 (apr_socket_t *sock, apr_sockaddr_t *where, apr_int32_t flags, const char *buf, apr_size_t *len) apr_status_t apr_socket_recvfrom group__apr__network__io.html ga22 (apr_sockaddr_t *from, apr_socket_t *sock, apr_int32_t flags, char *buf, apr_size_t *len) apr_status_t apr_socket_sendfile group__apr__network__io.html ga23 (apr_socket_t *sock, apr_file_t *file, apr_hdtr_t *hdtr, apr_off_t *offset, apr_size_t *len, apr_int32_t flags) apr_status_t apr_socket_recv group__apr__network__io.html ga24 (apr_socket_t *sock, char *buf, apr_size_t *len) apr_status_t apr_socket_opt_set group__apr__network__io.html ga25 (apr_socket_t *sock, apr_int32_t opt, apr_int32_t on) apr_status_t apr_socket_timeout_set group__apr__network__io.html ga26 (apr_socket_t *sock, apr_interval_time_t t) apr_status_t apr_socket_opt_get group__apr__network__io.html ga27 (apr_socket_t *sock, apr_int32_t opt, apr_int32_t *on) apr_status_t apr_socket_timeout_get group__apr__network__io.html ga28 (apr_socket_t *sock, apr_interval_time_t *t) apr_status_t apr_socket_atmark group__apr__network__io.html ga29 (apr_socket_t *sock, int *atmark) apr_status_t apr_socket_addr_get group__apr__network__io.html ga30 (apr_sockaddr_t **sa, apr_interface_e which, apr_socket_t *sock) apr_status_t apr_sockaddr_ip_get group__apr__network__io.html ga31 (char **addr, apr_sockaddr_t *sockaddr) int apr_sockaddr_equal group__apr__network__io.html ga32 (const apr_sockaddr_t *addr1, const apr_sockaddr_t *addr2) apr_status_t apr_socket_type_get group__apr__network__io.html ga33 (apr_socket_t *sock, int *type) apr_status_t apr_getservbyname group__apr__network__io.html ga34 (apr_sockaddr_t *sockaddr, const char *servname) apr_status_t apr_ipsubnet_create group__apr__network__io.html ga35 (apr_ipsubnet_t **ipsub, const char *ipstr, const char *mask_or_numbits, apr_pool_t *p) int apr_ipsubnet_test group__apr__network__io.html ga36 (apr_ipsubnet_t *ipsub, apr_sockaddr_t *sa) apr_status_t apr_socket_accept_filter group__apr__network__io.html ga37 (apr_socket_t *sock, char *name, char *args) apr_status_t apr_socket_protocol_get group__apr__network__io.html ga38 (apr_socket_t *sock, int *protocol) apr_status_t apr_socket_inherit_set group__apr__network__io.html ga39 (apr_socket_t *thesocket) apr_status_t apr_socket_inherit_unset group__apr__network__io.html ga40 (apr_socket_t *thesocket) apr_sockopt Socket option definitions group__apr__sockopt.html #define APR_SO_LINGER group__apr__sockopt.html ga0 #define APR_SO_KEEPALIVE group__apr__sockopt.html ga1 #define APR_SO_DEBUG group__apr__sockopt.html ga2 #define APR_SO_NONBLOCK group__apr__sockopt.html ga3 #define APR_SO_REUSEADDR group__apr__sockopt.html ga4 #define APR_SO_SNDBUF group__apr__sockopt.html ga5 #define APR_SO_RCVBUF group__apr__sockopt.html ga6 #define APR_SO_DISCONNECTED group__apr__sockopt.html ga7 #define APR_TCP_NODELAY group__apr__sockopt.html ga8 #define APR_TCP_NOPUSH group__apr__sockopt.html ga9 #define APR_RESET_NODELAY group__apr__sockopt.html ga10 #define APR_INCOMPLETE_READ group__apr__sockopt.html ga11 #define APR_INCOMPLETE_WRITE group__apr__sockopt.html ga12 #define APR_IPV6_V6ONLY group__apr__sockopt.html ga13 #define APR_TCP_DEFER_ACCEPT group__apr__sockopt.html ga14 IP_Proto IP Protocol Definitions for use when creating sockets group___i_p___proto.html #define APR_PROTO_TCP group___i_p___proto.html ga0 #define APR_PROTO_UDP group___i_p___proto.html ga1 #define APR_PROTO_SCTP group___i_p___proto.html ga2 apr_mcast IP Multicast group__apr__mcast.html apr_status_t apr_mcast_join group__apr__mcast.html ga0 (apr_socket_t *sock, apr_sockaddr_t *join, apr_sockaddr_t *iface, apr_sockaddr_t *source) apr_status_t apr_mcast_leave group__apr__mcast.html ga1 (apr_socket_t *sock, apr_sockaddr_t *addr, apr_sockaddr_t *iface, apr_sockaddr_t *source) apr_status_t apr_mcast_hops group__apr__mcast.html ga2 (apr_socket_t *sock, apr_byte_t ttl) apr_status_t apr_mcast_loopback group__apr__mcast.html ga3 (apr_socket_t *sock, apr_byte_t opt) apr_status_t apr_mcast_interface group__apr__mcast.html ga4 (apr_socket_t *sock, apr_sockaddr_t *iface) apr_poll Poll Routines group__apr__poll.html apr_descriptor apr_pollfd_t #define APR_POLLIN group__apr__poll.html ga8 #define APR_POLLPRI group__apr__poll.html ga9 #define APR_POLLOUT group__apr__poll.html ga10 #define APR_POLLERR group__apr__poll.html ga11 #define APR_POLLHUP group__apr__poll.html ga12 #define APR_POLLNVAL group__apr__poll.html ga13 #define APR_POLLSET_THREADSAFE group__apr__poll.html ga14 apr_pollfd_t apr_pollfd_t group__apr__poll.html ga0 apr_pollset_t apr_pollset_t group__apr__poll.html ga1 apr_datatype_e ga15 APR_NO_DESC gga15a9 APR_POLL_SOCKET gga15a10 APR_POLL_FILE gga15a11 APR_POLL_LASTDESC gga15a12 apr_status_t apr_pollset_create group__apr__poll.html ga2 (apr_pollset_t **pollset, apr_uint32_t size, apr_pool_t *p, apr_uint32_t flags) apr_status_t apr_pollset_destroy group__apr__poll.html ga3 (apr_pollset_t *pollset) apr_status_t apr_pollset_add group__apr__poll.html ga4 (apr_pollset_t *pollset, const apr_pollfd_t *descriptor) apr_status_t apr_pollset_remove group__apr__poll.html ga5 (apr_pollset_t *pollset, const apr_pollfd_t *descriptor) apr_status_t apr_pollset_poll group__apr__poll.html ga6 (apr_pollset_t *pollset, apr_interval_time_t timeout, apr_int32_t *num, const apr_pollfd_t **descriptors) apr_status_t apr_poll group__apr__poll.html ga7 (apr_pollfd_t *aprset, apr_int32_t numsock, apr_int32_t *nsds, apr_interval_time_t timeout) apr_pools Memory Pool Functions group__apr__pools.html PoolDebug #define APR_POOL_DECLARE_ACCESSOR group__apr__pools.html ga30 (type) #define APR_POOL_IMPLEMENT_ACCESSOR group__apr__pools.html ga31 (type) #define APR_POOL_DEBUG group__apr__pools.html ga32 #define APR_POOL__FILE_LINE__ group__apr__pools.html ga33 apr_pool_t apr_pool_t group__apr__pools.html ga0 int(* apr_abortfunc_t group__apr__pools.html ga1 )(int retcode) apr_status_t apr_pool_initialize group__apr__pools.html ga2 (void) void apr_pool_terminate group__apr__pools.html ga3 (void) apr_status_t apr_pool_create_ex group__apr__pools.html ga4 (apr_pool_t **newpool, apr_pool_t *parent, apr_abortfunc_t abort_fn, apr_allocator_t *allocator) apr_status_t apr_pool_create_ex_debug group__apr__pools.html ga5 (apr_pool_t **newpool, apr_pool_t *parent, apr_abortfunc_t abort_fn, apr_allocator_t *allocator, const char *file_line) apr_status_t apr_pool_create group__apr__pools.html ga6 (apr_pool_t **newpool, apr_pool_t *parent) apr_allocator_t * apr_pool_allocator_get group__apr__pools.html ga7 (apr_pool_t *pool) void apr_pool_clear group__apr__pools.html ga8 (apr_pool_t *p) void apr_pool_clear_debug group__apr__pools.html ga9 (apr_pool_t *p, const char *file_line) void apr_pool_destroy group__apr__pools.html ga10 (apr_pool_t *p) void apr_pool_destroy_debug group__apr__pools.html ga11 (apr_pool_t *p, const char *file_line) void * apr_palloc group__apr__pools.html ga12 (apr_pool_t *p, apr_size_t size) void * apr_palloc_debug group__apr__pools.html ga13 (apr_pool_t *p, apr_size_t size, const char *file_line) void * apr_pcalloc group__apr__pools.html ga14 (apr_pool_t *p, apr_size_t size) void * apr_pcalloc_debug group__apr__pools.html ga15 (apr_pool_t *p, apr_size_t size, const char *file_line) void apr_pool_abort_set group__apr__pools.html ga16 (apr_abortfunc_t abortfunc, apr_pool_t *pool) apr_abortfunc_t apr_pool_abort_get group__apr__pools.html ga17 (apr_pool_t *pool) apr_pool_t * apr_pool_parent_get group__apr__pools.html ga18 (apr_pool_t *pool) int apr_pool_is_ancestor group__apr__pools.html ga19 (apr_pool_t *a, apr_pool_t *b) void apr_pool_tag group__apr__pools.html ga20 (apr_pool_t *pool, const char *tag) apr_status_t apr_pool_userdata_set group__apr__pools.html ga21 (const void *data, const char *key, apr_status_t(*cleanup)(void *), apr_pool_t *pool) apr_status_t apr_pool_userdata_setn group__apr__pools.html ga22 (const void *data, const char *key, apr_status_t(*cleanup)(void *), apr_pool_t *pool) apr_status_t apr_pool_userdata_get group__apr__pools.html ga23 (void **data, const char *key, apr_pool_t *pool) void apr_pool_cleanup_register group__apr__pools.html ga24 (apr_pool_t *p, const void *data, apr_status_t(*plain_cleanup)(void *), apr_status_t(*child_cleanup)(void *)) void apr_pool_cleanup_kill group__apr__pools.html ga25 (apr_pool_t *p, const void *data, apr_status_t(*cleanup)(void *)) void apr_pool_child_cleanup_set group__apr__pools.html ga26 (apr_pool_t *p, const void *data, apr_status_t(*plain_cleanup)(void *), apr_status_t(*child_cleanup)(void *)) apr_status_t apr_pool_cleanup_run group__apr__pools.html ga27 (apr_pool_t *p, void *data, apr_status_t(*cleanup)(void *)) apr_status_t apr_pool_cleanup_null group__apr__pools.html ga28 (void *data) void apr_pool_cleanup_for_exec group__apr__pools.html ga29 (void) PoolDebug Pool Debugging functions. group___pool_debug.html void apr_pool_join group___pool_debug.html ga0 (apr_pool_t *p, apr_pool_t *sub) apr_pool_t * apr_pool_find group___pool_debug.html ga1 (const void *mem) apr_size_t apr_pool_num_bytes group___pool_debug.html ga2 (apr_pool_t *p, int recurse) void apr_pool_lock group___pool_debug.html ga3 (apr_pool_t *pool, int flag) apr_portabile Portability Routines group__apr__portabile.html apr_os_thread apr_os_dso apr_os_proc_mutex_t apr_os_sock_info_t #define apr_os_global_mutex_t group__apr__portabile.html ga31 #define apr_os_global_mutex_get group__apr__portabile.html ga32 int apr_os_file_t group__apr__portabile.html ga0 DIR apr_os_dir_t group__apr__portabile.html ga1 int apr_os_sock_t group__apr__portabile.html ga2 apr_os_proc_mutex_t apr_os_proc_mutex_t group__apr__portabile.html ga3 pthread_t apr_os_thread_t group__apr__portabile.html ga4 pthread_key_t apr_os_threadkey_t group__apr__portabile.html ga5 pid_t apr_os_proc_t group__apr__portabile.html ga6 timeval apr_os_imp_time_t group__apr__portabile.html ga7 tm apr_os_exp_time_t group__apr__portabile.html ga8 void * apr_os_dso_handle_t group__apr__portabile.html ga9 void * apr_os_shm_t group__apr__portabile.html ga10 apr_os_sock_info_t apr_os_sock_info_t group__apr__portabile.html ga11 apr_status_t apr_os_file_get group__apr__portabile.html ga12 (apr_os_file_t *thefile, apr_file_t *file) apr_status_t apr_os_dir_get group__apr__portabile.html ga13 (apr_os_dir_t **thedir, apr_dir_t *dir) apr_status_t apr_os_sock_get group__apr__portabile.html ga14 (apr_os_sock_t *thesock, apr_socket_t *sock) apr_status_t apr_os_proc_mutex_get group__apr__portabile.html ga15 (apr_os_proc_mutex_t *ospmutex, apr_proc_mutex_t *pmutex) apr_status_t apr_os_exp_time_get group__apr__portabile.html ga16 (apr_os_exp_time_t **ostime, apr_time_exp_t *aprtime) apr_status_t apr_os_imp_time_get group__apr__portabile.html ga17 (apr_os_imp_time_t **ostime, apr_time_t *aprtime) apr_status_t apr_os_shm_get group__apr__portabile.html ga18 (apr_os_shm_t *osshm, apr_shm_t *shm) apr_status_t apr_os_file_put group__apr__portabile.html ga19 (apr_file_t **file, apr_os_file_t *thefile, apr_int32_t flags, apr_pool_t *cont) apr_status_t apr_os_pipe_put group__apr__portabile.html ga20 (apr_file_t **file, apr_os_file_t *thefile, apr_pool_t *cont) apr_status_t apr_os_pipe_put_ex group__apr__portabile.html ga21 (apr_file_t **file, apr_os_file_t *thefile, int register_cleanup, apr_pool_t *cont) apr_status_t apr_os_dir_put group__apr__portabile.html ga22 (apr_dir_t **dir, apr_os_dir_t *thedir, apr_pool_t *cont) apr_status_t apr_os_sock_put group__apr__portabile.html ga23 (apr_socket_t **sock, apr_os_sock_t *thesock, apr_pool_t *cont) apr_status_t apr_os_sock_make group__apr__portabile.html ga24 (apr_socket_t **apr_sock, apr_os_sock_info_t *os_sock_info, apr_pool_t *cont) apr_status_t apr_os_proc_mutex_put group__apr__portabile.html ga25 (apr_proc_mutex_t **pmutex, apr_os_proc_mutex_t *ospmutex, apr_pool_t *cont) apr_status_t apr_os_imp_time_put group__apr__portabile.html ga26 (apr_time_t *aprtime, apr_os_imp_time_t **ostime, apr_pool_t *cont) apr_status_t apr_os_exp_time_put group__apr__portabile.html ga27 (apr_time_exp_t *aprtime, apr_os_exp_time_t **ostime, apr_pool_t *cont) apr_status_t apr_os_shm_put group__apr__portabile.html ga28 (apr_shm_t **shm, apr_os_shm_t *osshm, apr_pool_t *cont) const char * apr_os_default_encoding group__apr__portabile.html ga29 (apr_pool_t *pool) const char * apr_os_locale_encoding group__apr__portabile.html ga30 (apr_pool_t *pool) apr_os_thread Thread portability Routines group__apr__os__thread.html apr_status_t apr_os_thread_get group__apr__os__thread.html ga0 (apr_os_thread_t **thethd, apr_thread_t *thd) apr_status_t apr_os_threadkey_get group__apr__os__thread.html ga1 (apr_os_threadkey_t *thekey, apr_threadkey_t *key) apr_status_t apr_os_thread_put group__apr__os__thread.html ga2 (apr_thread_t **thd, apr_os_thread_t *thethd, apr_pool_t *cont) apr_status_t apr_os_threadkey_put group__apr__os__thread.html ga3 (apr_threadkey_t **key, apr_os_threadkey_t *thekey, apr_pool_t *cont) apr_os_thread_t apr_os_thread_current group__apr__os__thread.html ga4 (void) int apr_os_thread_equal group__apr__os__thread.html ga5 (apr_os_thread_t tid1, apr_os_thread_t tid2) apr_os_dso DSO (Dynamic Loading) Portabiliity Routines group__apr__os__dso.html apr_status_t apr_os_dso_handle_put group__apr__os__dso.html ga0 (apr_dso_handle_t **dso, apr_os_dso_handle_t thedso, apr_pool_t *pool) apr_status_t apr_os_dso_handle_get group__apr__os__dso.html ga1 (apr_os_dso_handle_t *dso, apr_dso_handle_t *aprdso) apr_proc_mutex Process Locking Routines group__apr__proc__mutex.html apr_proc_mutex_t apr_proc_mutex_t group__apr__proc__mutex.html ga0 apr_lockmech_e ga12 APR_LOCK_FCNTL gga12a1 APR_LOCK_FLOCK gga12a2 APR_LOCK_SYSVSEM gga12a3 APR_LOCK_PROC_PTHREAD gga12a4 APR_LOCK_POSIXSEM gga12a5 APR_LOCK_DEFAULT gga12a6 apr_status_t apr_proc_mutex_create group__apr__proc__mutex.html ga1 (apr_proc_mutex_t **mutex, const char *fname, apr_lockmech_e mech, apr_pool_t *pool) apr_status_t apr_proc_mutex_child_init group__apr__proc__mutex.html ga2 (apr_proc_mutex_t **mutex, const char *fname, apr_pool_t *pool) apr_status_t apr_proc_mutex_lock group__apr__proc__mutex.html ga3 (apr_proc_mutex_t *mutex) apr_status_t apr_proc_mutex_trylock group__apr__proc__mutex.html ga4 (apr_proc_mutex_t *mutex) apr_status_t apr_proc_mutex_unlock group__apr__proc__mutex.html ga5 (apr_proc_mutex_t *mutex) apr_status_t apr_proc_mutex_destroy group__apr__proc__mutex.html ga6 (apr_proc_mutex_t *mutex) apr_status_t apr_proc_mutex_cleanup group__apr__proc__mutex.html ga7 (void *mutex) const char * apr_proc_mutex_lockfile group__apr__proc__mutex.html ga8 (apr_proc_mutex_t *mutex) const char * apr_proc_mutex_name group__apr__proc__mutex.html ga9 (apr_proc_mutex_t *mutex) const char * apr_proc_mutex_defname group__apr__proc__mutex.html ga10 (void) apr_pool_t * apr_proc_mutex_pool_get group__apr__proc__mutex.html ga11 (const apr_proc_mutex_t *theproc_mutex) apr_ring Ring Macro Implementations group__apr__ring.html #define APR_RING_ENTRY group__apr__ring.html ga0 (elem) #define APR_RING_HEAD group__apr__ring.html ga1 (head, elem) #define APR_RING_SENTINEL group__apr__ring.html ga2 (hp, elem, link) #define APR_RING_FIRST group__apr__ring.html ga3 (hp) #define APR_RING_LAST group__apr__ring.html ga4 (hp) #define APR_RING_NEXT group__apr__ring.html ga5 (ep, link) #define APR_RING_PREV group__apr__ring.html ga6 (ep, link) #define APR_RING_INIT group__apr__ring.html ga7 (hp, elem, link) #define APR_RING_EMPTY group__apr__ring.html ga8 (hp, elem, link) #define APR_RING_ELEM_INIT group__apr__ring.html ga9 (ep, link) #define APR_RING_SPLICE_BEFORE group__apr__ring.html ga10 (lep, ep1, epN, link) #define APR_RING_SPLICE_AFTER group__apr__ring.html ga11 (lep, ep1, epN, link) #define APR_RING_INSERT_BEFORE group__apr__ring.html ga12 (lep, nep, link) #define APR_RING_INSERT_AFTER group__apr__ring.html ga13 (lep, nep, link) #define APR_RING_SPLICE_HEAD group__apr__ring.html ga14 (hp, ep1, epN, elem, link) #define APR_RING_SPLICE_TAIL group__apr__ring.html ga15 (hp, ep1, epN, elem, link) #define APR_RING_INSERT_HEAD group__apr__ring.html ga16 (hp, nep, elem, link) #define APR_RING_INSERT_TAIL group__apr__ring.html ga17 (hp, nep, elem, link) #define APR_RING_CONCAT group__apr__ring.html ga18 (h1, h2, elem, link) #define APR_RING_PREPEND group__apr__ring.html ga19 (h1, h2, elem, link) #define APR_RING_UNSPLICE group__apr__ring.html ga20 (ep1, epN, link) #define APR_RING_REMOVE group__apr__ring.html ga21 (ep, link) #define APR_RING_CHECK_ONE group__apr__ring.html ga22 (msg, ptr) #define APR_RING_CHECK group__apr__ring.html ga23 (hp, elem, link, msg) #define APR_RING_CHECK_CONSISTENCY group__apr__ring.html ga24 (hp, elem, link) #define APR_RING_CHECK_ELEM group__apr__ring.html ga25 (ep, elem, link, msg) #define APR_RING_CHECK_ELEM_CONSISTENCY group__apr__ring.html ga26 (ep, elem, link) apr_shm Shared Memory Routines group__apr__shm.html apr_shm_t apr_shm_t group__apr__shm.html ga0 apr_status_t apr_shm_create group__apr__shm.html ga1 (apr_shm_t **m, apr_size_t reqsize, const char *filename, apr_pool_t *pool) apr_status_t apr_shm_remove group__apr__shm.html ga2 (const char *filename, apr_pool_t *pool) apr_status_t apr_shm_destroy group__apr__shm.html ga3 (apr_shm_t *m) apr_status_t apr_shm_attach group__apr__shm.html ga4 (apr_shm_t **m, const char *filename, apr_pool_t *pool) apr_status_t apr_shm_detach group__apr__shm.html ga5 (apr_shm_t *m) void * apr_shm_baseaddr_get group__apr__shm.html ga6 (const apr_shm_t *m) apr_size_t apr_shm_size_get group__apr__shm.html ga7 (const apr_shm_t *m) apr_pool_t * apr_shm_pool_get group__apr__shm.html ga8 (const apr_shm_t *theshm) apr_signal Handling group__apr__signal.html void apr_sigfunc_t group__apr__signal.html ga0 (int) apr_sigfunc_t * apr_signal group__apr__signal.html ga1 (int signo, apr_sigfunc_t *func) const char * apr_signal_description_get group__apr__signal.html ga2 (int signum) void apr_signal_init group__apr__signal.html ga3 (apr_pool_t *pglobal) apr_status_t apr_signal_block group__apr__signal.html ga4 (int signum) apr_status_t apr_signal_unblock group__apr__signal.html ga5 (int signum) apr_strings String routines group__apr__strings.html APR_Strings_Snprintf int apr_strnatcmp group__apr__strings.html ga0 (char const *a, char const *b) int apr_strnatcasecmp group__apr__strings.html ga1 (char const *a, char const *b) char * apr_pstrdup group__apr__strings.html ga2 (apr_pool_t *p, const char *s) char * apr_pstrmemdup group__apr__strings.html ga3 (apr_pool_t *p, const char *s, apr_size_t n) char * apr_pstrndup group__apr__strings.html ga4 (apr_pool_t *p, const char *s, apr_size_t n) void * apr_pmemdup group__apr__strings.html ga5 (apr_pool_t *p, const void *m, apr_size_t n) char * apr_pstrcat group__apr__strings.html ga6 (apr_pool_t *p,...) char * apr_pstrcatv group__apr__strings.html ga7 (apr_pool_t *p, const struct iovec *vec, apr_size_t nvec, apr_size_t *nbytes) char * apr_pvsprintf group__apr__strings.html ga8 (apr_pool_t *p, const char *fmt, va_list ap) char * apr_psprintf group__apr__strings.html ga9 (apr_pool_t *p, const char *fmt,...) char * apr_cpystrn group__apr__strings.html ga10 (char *dst, const char *src, apr_size_t dst_size) char * apr_collapse_spaces group__apr__strings.html ga11 (char *dest, const char *src) apr_status_t apr_tokenize_to_argv group__apr__strings.html ga12 (const char *arg_str, char ***argv_out, apr_pool_t *token_context) char * apr_strtok group__apr__strings.html ga13 (char *str, const char *sep, char **last) char * apr_itoa group__apr__strings.html ga14 (apr_pool_t *p, int n) char * apr_ltoa group__apr__strings.html ga15 (apr_pool_t *p, long n) char * apr_off_t_toa group__apr__strings.html ga16 (apr_pool_t *p, apr_off_t n) apr_status_t apr_strtoff group__apr__strings.html ga17 (apr_off_t *offset, const char *buf, char **end, int base) apr_int64_t apr_strtoi64 group__apr__strings.html ga18 (const char *buf, char **end, int base) apr_int64_t apr_atoi64 group__apr__strings.html ga19 (const char *buf) char * apr_strfsize group__apr__strings.html ga20 (apr_off_t size, char *buf) APR_Strings_Snprintf snprintf implementations group___a_p_r___strings___snprintf.html int apr_snprintf group___a_p_r___strings___snprintf.html ga0 (char *buf, apr_size_t len, const char *format,...) int apr_vsnprintf group___a_p_r___strings___snprintf.html ga1 (char *buf, apr_size_t len, const char *format, va_list ap) apr_support Internal APR support functions group__apr__support.html apr_status_t apr_wait_for_io_or_timeout group__apr__support.html ga0 (apr_file_t *f, apr_socket_t *s, int for_read) apr_tables Table and Array Functions group__apr__tables.html apr_array_header_t apr_table_entry_t #define APR_OVERLAP_TABLES_SET group__apr__tables.html ga31 #define APR_OVERLAP_TABLES_MERGE group__apr__tables.html ga32 apr_table_t apr_table_t group__apr__tables.html ga0 apr_array_header_t apr_array_header_t group__apr__tables.html ga1 apr_table_entry_t apr_table_entry_t group__apr__tables.html ga2 int( apr_table_do_callback_fn_t group__apr__tables.html ga3 )(void *rec, const char *key, const char *value) const apr_array_header_t * apr_table_elts group__apr__tables.html ga4 (const apr_table_t *t) int apr_is_empty_table group__apr__tables.html ga5 (const apr_table_t *t) int apr_is_empty_array group__apr__tables.html ga6 (const apr_array_header_t *a) apr_array_header_t * apr_array_make group__apr__tables.html ga7 (apr_pool_t *p, int nelts, int elt_size) void * apr_array_push group__apr__tables.html ga8 (apr_array_header_t *arr) void * apr_array_pop group__apr__tables.html ga9 (apr_array_header_t *arr) void apr_array_cat group__apr__tables.html ga10 (apr_array_header_t *dst, const apr_array_header_t *src) apr_array_header_t * apr_array_copy group__apr__tables.html ga11 (apr_pool_t *p, const apr_array_header_t *arr) apr_array_header_t * apr_array_copy_hdr group__apr__tables.html ga12 (apr_pool_t *p, const apr_array_header_t *arr) apr_array_header_t * apr_array_append group__apr__tables.html ga13 (apr_pool_t *p, const apr_array_header_t *first, const apr_array_header_t *second) char * apr_array_pstrcat group__apr__tables.html ga14 (apr_pool_t *p, const apr_array_header_t *arr, const char sep) apr_table_t * apr_table_make group__apr__tables.html ga15 (apr_pool_t *p, int nelts) apr_table_t * apr_table_copy group__apr__tables.html ga16 (apr_pool_t *p, const apr_table_t *t) void apr_table_clear group__apr__tables.html ga17 (apr_table_t *t) const char * apr_table_get group__apr__tables.html ga18 (const apr_table_t *t, const char *key) void apr_table_set group__apr__tables.html ga19 (apr_table_t *t, const char *key, const char *val) void apr_table_setn group__apr__tables.html ga20 (apr_table_t *t, const char *key, const char *val) void apr_table_unset group__apr__tables.html ga21 (apr_table_t *t, const char *key) void apr_table_merge group__apr__tables.html ga22 (apr_table_t *t, const char *key, const char *val) void apr_table_mergen group__apr__tables.html ga23 (apr_table_t *t, const char *key, const char *val) void apr_table_add group__apr__tables.html ga24 (apr_table_t *t, const char *key, const char *val) void apr_table_addn group__apr__tables.html ga25 (apr_table_t *t, const char *key, const char *val) apr_table_t * apr_table_overlay group__apr__tables.html ga26 (apr_pool_t *p, const apr_table_t *overlay, const apr_table_t *base) int apr_table_do group__apr__tables.html ga27 (apr_table_do_callback_fn_t *comp, void *rec, const apr_table_t *t,...) int apr_table_vdo group__apr__tables.html ga28 (apr_table_do_callback_fn_t *comp, void *rec, const apr_table_t *t, va_list vp) void apr_table_overlap group__apr__tables.html ga29 (apr_table_t *a, const apr_table_t *b, unsigned flags) void apr_table_compress group__apr__tables.html ga30 (apr_table_t *t, unsigned flags) apr_thread_cond Condition Variable Routines group__apr__thread__cond.html apr_thread_cond_t apr_thread_cond_t group__apr__thread__cond.html ga0 apr_status_t apr_thread_cond_create group__apr__thread__cond.html ga1 (apr_thread_cond_t **cond, apr_pool_t *pool) apr_status_t apr_thread_cond_wait group__apr__thread__cond.html ga2 (apr_thread_cond_t *cond, apr_thread_mutex_t *mutex) apr_status_t apr_thread_cond_timedwait group__apr__thread__cond.html ga3 (apr_thread_cond_t *cond, apr_thread_mutex_t *mutex, apr_interval_time_t timeout) apr_status_t apr_thread_cond_signal group__apr__thread__cond.html ga4 (apr_thread_cond_t *cond) apr_status_t apr_thread_cond_broadcast group__apr__thread__cond.html ga5 (apr_thread_cond_t *cond) apr_status_t apr_thread_cond_destroy group__apr__thread__cond.html ga6 (apr_thread_cond_t *cond) apr_pool_t * apr_thread_cond_pool_get group__apr__thread__cond.html ga7 (const apr_thread_cond_t *thethread_cond) apr_thread_mutex Thread Mutex Routines group__apr__thread__mutex.html #define APR_THREAD_MUTEX_DEFAULT group__apr__thread__mutex.html ga7 #define APR_THREAD_MUTEX_NESTED group__apr__thread__mutex.html ga8 #define APR_THREAD_MUTEX_UNNESTED group__apr__thread__mutex.html ga9 apr_thread_mutex_t apr_thread_mutex_t group__apr__thread__mutex.html ga0 apr_status_t apr_thread_mutex_create group__apr__thread__mutex.html ga1 (apr_thread_mutex_t **mutex, unsigned int flags, apr_pool_t *pool) apr_status_t apr_thread_mutex_lock group__apr__thread__mutex.html ga2 (apr_thread_mutex_t *mutex) apr_status_t apr_thread_mutex_trylock group__apr__thread__mutex.html ga3 (apr_thread_mutex_t *mutex) apr_status_t apr_thread_mutex_unlock group__apr__thread__mutex.html ga4 (apr_thread_mutex_t *mutex) apr_status_t apr_thread_mutex_destroy group__apr__thread__mutex.html ga5 (apr_thread_mutex_t *mutex) apr_pool_t * apr_thread_mutex_pool_get group__apr__thread__mutex.html ga6 (const apr_thread_mutex_t *thethread_mutex) apr_thread_proc Threads and Process Functions group__apr__thread__proc.html APR_OC apr_proc_t #define APR_PROC_CHECK_EXIT group__apr__thread__proc.html ga58 (x) #define APR_PROC_CHECK_SIGNALED group__apr__thread__proc.html ga59 (x) #define APR_PROC_CHECK_CORE_DUMP group__apr__thread__proc.html ga60 (x) #define APR_NO_PIPE group__apr__thread__proc.html ga61 #define APR_FULL_BLOCK group__apr__thread__proc.html ga62 #define APR_FULL_NONBLOCK group__apr__thread__proc.html ga63 #define APR_PARENT_BLOCK group__apr__thread__proc.html ga64 #define APR_CHILD_BLOCK group__apr__thread__proc.html ga65 #define APR_LIMIT_CPU group__apr__thread__proc.html ga66 #define APR_LIMIT_MEM group__apr__thread__proc.html ga67 #define APR_LIMIT_NPROC group__apr__thread__proc.html ga68 #define APR_LIMIT_NOFILE group__apr__thread__proc.html ga69 #define APR_PROC_DETACH_FOREGROUND group__apr__thread__proc.html ga70 #define APR_PROC_DETACH_DAEMONIZE group__apr__thread__proc.html ga71 apr_proc_t apr_proc_t group__apr__thread__proc.html ga0 void( apr_child_errfn_t group__apr__thread__proc.html ga1 )(apr_pool_t *proc, apr_status_t err, const char *description) apr_thread_t apr_thread_t group__apr__thread__proc.html ga2 apr_threadattr_t apr_threadattr_t group__apr__thread__proc.html ga3 apr_procattr_t apr_procattr_t group__apr__thread__proc.html ga4 apr_thread_once_t apr_thread_once_t group__apr__thread__proc.html ga5 apr_threadkey_t apr_threadkey_t group__apr__thread__proc.html ga6 apr_other_child_rec_t apr_other_child_rec_t group__apr__thread__proc.html ga7 void *(APR_THREAD_FUNC * apr_thread_start_t group__apr__thread__proc.html ga8 )(apr_thread_t *, void *) apr_cmdtype_e ga72 APR_SHELLCMD gga72a29 APR_PROGRAM gga72a30 APR_PROGRAM_ENV gga72a31 APR_PROGRAM_PATH gga72a32 APR_SHELLCMD_ENV gga72a33 apr_wait_how_e ga73 APR_WAIT gga73a34 APR_NOWAIT gga73a35 apr_exit_why_e ga74 APR_PROC_EXIT gga74a36 APR_PROC_SIGNAL gga74a37 APR_PROC_SIGNAL_CORE gga74a38 apr_kill_conditions_e ga75 APR_KILL_NEVER gga75a39 APR_KILL_ALWAYS gga75a40 APR_KILL_AFTER_TIMEOUT gga75a41 APR_JUST_WAIT gga75a42 APR_KILL_ONLY_ONCE gga75a43 apr_status_t apr_threadattr_create group__apr__thread__proc.html ga9 (apr_threadattr_t **new_attr, apr_pool_t *cont) apr_status_t apr_threadattr_detach_set group__apr__thread__proc.html ga10 (apr_threadattr_t *attr, apr_int32_t on) apr_status_t apr_threadattr_detach_get group__apr__thread__proc.html ga11 (apr_threadattr_t *attr) apr_status_t apr_threadattr_stacksize_set group__apr__thread__proc.html ga12 (apr_threadattr_t *attr, apr_size_t stacksize) apr_status_t apr_threadattr_guardsize_set group__apr__thread__proc.html ga13 (apr_threadattr_t *attr, apr_size_t guardsize) apr_status_t apr_thread_create group__apr__thread__proc.html ga14 (apr_thread_t **new_thread, apr_threadattr_t *attr, apr_thread_start_t func, void *data, apr_pool_t *cont) apr_status_t apr_thread_exit group__apr__thread__proc.html ga15 (apr_thread_t *thd, apr_status_t retval) apr_status_t apr_thread_join group__apr__thread__proc.html ga16 (apr_status_t *retval, apr_thread_t *thd) void apr_thread_yield group__apr__thread__proc.html ga17 (void) apr_status_t apr_thread_once_init group__apr__thread__proc.html ga18 (apr_thread_once_t **control, apr_pool_t *p) apr_status_t apr_thread_once group__apr__thread__proc.html ga19 (apr_thread_once_t *control, void(*func)(void)) apr_status_t apr_thread_detach group__apr__thread__proc.html ga20 (apr_thread_t *thd) apr_status_t apr_thread_data_get group__apr__thread__proc.html ga21 (void **data, const char *key, apr_thread_t *thread) apr_status_t apr_thread_data_set group__apr__thread__proc.html ga22 (void *data, const char *key, apr_status_t(*cleanup)(void *), apr_thread_t *thread) apr_status_t apr_threadkey_private_create group__apr__thread__proc.html ga23 (apr_threadkey_t **key, void(*dest)(void *), apr_pool_t *cont) apr_status_t apr_threadkey_private_get group__apr__thread__proc.html ga24 (void **new_mem, apr_threadkey_t *key) apr_status_t apr_threadkey_private_set group__apr__thread__proc.html ga25 (void *priv, apr_threadkey_t *key) apr_status_t apr_threadkey_private_delete group__apr__thread__proc.html ga26 (apr_threadkey_t *key) apr_status_t apr_threadkey_data_get group__apr__thread__proc.html ga27 (void **data, const char *key, apr_threadkey_t *threadkey) apr_status_t apr_threadkey_data_set group__apr__thread__proc.html ga28 (void *data, const char *key, apr_status_t(*cleanup)(void *), apr_threadkey_t *threadkey) apr_status_t apr_procattr_create group__apr__thread__proc.html ga29 (apr_procattr_t **new_attr, apr_pool_t *cont) apr_status_t apr_procattr_io_set group__apr__thread__proc.html ga30 (apr_procattr_t *attr, apr_int32_t in, apr_int32_t out, apr_int32_t err) apr_status_t apr_procattr_child_in_set group__apr__thread__proc.html ga31 (struct apr_procattr_t *attr, apr_file_t *child_in, apr_file_t *parent_in) apr_status_t apr_procattr_child_out_set group__apr__thread__proc.html ga32 (struct apr_procattr_t *attr, apr_file_t *child_out, apr_file_t *parent_out) apr_status_t apr_procattr_child_err_set group__apr__thread__proc.html ga33 (struct apr_procattr_t *attr, apr_file_t *child_err, apr_file_t *parent_err) apr_status_t apr_procattr_dir_set group__apr__thread__proc.html ga34 (apr_procattr_t *attr, const char *dir) apr_status_t apr_procattr_cmdtype_set group__apr__thread__proc.html ga35 (apr_procattr_t *attr, apr_cmdtype_e cmd) apr_status_t apr_procattr_detach_set group__apr__thread__proc.html ga36 (apr_procattr_t *attr, apr_int32_t detach) apr_status_t apr_procattr_limit_set group__apr__thread__proc.html ga37 (apr_procattr_t *attr, apr_int32_t what, struct rlimit *limit) apr_status_t apr_procattr_child_errfn_set group__apr__thread__proc.html ga38 (apr_procattr_t *attr, apr_child_errfn_t *errfn) apr_status_t apr_procattr_error_check_set group__apr__thread__proc.html ga39 (apr_procattr_t *attr, apr_int32_t chk) apr_status_t apr_procattr_addrspace_set group__apr__thread__proc.html ga40 (apr_procattr_t *attr, apr_int32_t addrspace) apr_status_t apr_procattr_user_set group__apr__thread__proc.html ga41 (apr_procattr_t *attr, const char *username, const char *password) apr_status_t apr_procattr_group_set group__apr__thread__proc.html ga42 (apr_procattr_t *attr, const char *groupname) apr_status_t apr_proc_fork group__apr__thread__proc.html ga43 (apr_proc_t *proc, apr_pool_t *cont) apr_status_t apr_proc_create group__apr__thread__proc.html ga44 (apr_proc_t *new_proc, const char *progname, const char *const *args, const char *const *env, apr_procattr_t *attr, apr_pool_t *pool) apr_status_t apr_proc_wait group__apr__thread__proc.html ga45 (apr_proc_t *proc, int *exitcode, apr_exit_why_e *exitwhy, apr_wait_how_e waithow) apr_status_t apr_proc_wait_all_procs group__apr__thread__proc.html ga46 (apr_proc_t *proc, int *exitcode, apr_exit_why_e *exitwhy, apr_wait_how_e waithow, apr_pool_t *p) apr_status_t apr_proc_detach group__apr__thread__proc.html ga47 (int daemonize) void apr_proc_other_child_register group__apr__thread__proc.html ga48 (apr_proc_t *proc, void(*maintenance)(int reason, void *, int status), void *data, apr_file_t *write_fd, apr_pool_t *p) void apr_proc_other_child_unregister group__apr__thread__proc.html ga49 (void *data) apr_status_t apr_proc_other_child_alert group__apr__thread__proc.html ga50 (apr_proc_t *proc, int reason, int status) void apr_proc_other_child_refresh group__apr__thread__proc.html ga51 (apr_other_child_rec_t *ocr, int reason) void apr_proc_other_child_refresh_all group__apr__thread__proc.html ga52 (int reason) apr_status_t apr_proc_kill group__apr__thread__proc.html ga53 (apr_proc_t *proc, int sig) void apr_pool_note_subprocess group__apr__thread__proc.html ga54 (apr_pool_t *a, apr_proc_t *proc, apr_kill_conditions_e how) apr_status_t apr_setup_signal_thread group__apr__thread__proc.html ga55 (void) apr_status_t apr_signal_thread group__apr__thread__proc.html ga56 (int(*signal_handler)(int signum)) apr_pool_t * apr_thread_pool_get group__apr__thread__proc.html ga57 (const apr_thread_t *thethread) APR_OC Other Child Flags group___a_p_r___o_c.html #define APR_OC_REASON_DEATH group___a_p_r___o_c.html ga0 #define APR_OC_REASON_UNWRITABLE group___a_p_r___o_c.html ga1 #define APR_OC_REASON_RESTART group___a_p_r___o_c.html ga2 #define APR_OC_REASON_UNREGISTER group___a_p_r___o_c.html ga3 #define APR_OC_REASON_LOST group___a_p_r___o_c.html ga4 #define APR_OC_REASON_RUNNING group___a_p_r___o_c.html ga5 apr_thread_rwlock Reader/Writer Lock Routines group__apr__thread__rwlock.html apr_thread_rwlock_t apr_thread_rwlock_t group__apr__thread__rwlock.html ga0 apr_status_t apr_thread_rwlock_create group__apr__thread__rwlock.html ga1 (apr_thread_rwlock_t **rwlock, apr_pool_t *pool) apr_status_t apr_thread_rwlock_rdlock group__apr__thread__rwlock.html ga2 (apr_thread_rwlock_t *rwlock) apr_status_t apr_thread_rwlock_tryrdlock group__apr__thread__rwlock.html ga3 (apr_thread_rwlock_t *rwlock) apr_status_t apr_thread_rwlock_wrlock group__apr__thread__rwlock.html ga4 (apr_thread_rwlock_t *rwlock) apr_status_t apr_thread_rwlock_trywrlock group__apr__thread__rwlock.html ga5 (apr_thread_rwlock_t *rwlock) apr_status_t apr_thread_rwlock_unlock group__apr__thread__rwlock.html ga6 (apr_thread_rwlock_t *rwlock) apr_status_t apr_thread_rwlock_destroy group__apr__thread__rwlock.html ga7 (apr_thread_rwlock_t *rwlock) apr_pool_t * apr_thread_rwlock_pool_get group__apr__thread__rwlock.html ga8 (const apr_thread_rwlock_t *thethread_rwlock) apr_time Time Routines group__apr__time.html apr_time_exp_t #define APR_TIME_C group__apr__time.html ga18 (val) #define APR_TIME_T_FMT group__apr__time.html ga19 #define APR_USEC_PER_SEC group__apr__time.html ga20 #define apr_time_sec group__apr__time.html ga21 (time) #define apr_time_usec group__apr__time.html ga22 (time) #define apr_time_msec group__apr__time.html ga23 (time) #define apr_time_as_msec group__apr__time.html ga24 (time) #define apr_time_from_sec group__apr__time.html ga25 (sec) #define apr_time_make group__apr__time.html ga26 (sec, usec) #define APR_RFC822_DATE_LEN group__apr__time.html ga27 #define APR_CTIME_LEN group__apr__time.html ga28 apr_int64_t apr_time_t group__apr__time.html ga2 apr_int64_t apr_interval_time_t group__apr__time.html ga3 apr_int32_t apr_short_interval_time_t group__apr__time.html ga4 apr_time_exp_t apr_time_exp_t group__apr__time.html ga5 apr_time_t apr_time_now group__apr__time.html ga6 (void) apr_status_t apr_time_ansi_put group__apr__time.html ga7 (apr_time_t *result, time_t input) apr_status_t apr_time_exp_tz group__apr__time.html ga8 (apr_time_exp_t *result, apr_time_t input, apr_int32_t offs) apr_status_t apr_time_exp_gmt group__apr__time.html ga9 (apr_time_exp_t *result, apr_time_t input) apr_status_t apr_time_exp_lt group__apr__time.html ga10 (apr_time_exp_t *result, apr_time_t input) apr_status_t apr_time_exp_get group__apr__time.html ga11 (apr_time_t *result, apr_time_exp_t *input) apr_status_t apr_time_exp_gmt_get group__apr__time.html ga12 (apr_time_t *result, apr_time_exp_t *input) void apr_sleep group__apr__time.html ga13 (apr_interval_time_t t) apr_status_t apr_rfc822_date group__apr__time.html ga14 (char *date_str, apr_time_t t) apr_status_t apr_ctime group__apr__time.html ga15 (char *date_str, apr_time_t t) apr_status_t apr_strftime group__apr__time.html ga16 (char *s, apr_size_t *retsize, apr_size_t max, const char *format, apr_time_exp_t *tm) void apr_time_clock_hires group__apr__time.html ga17 (apr_pool_t *p) const char apr_month_snames group__apr__time.html ga0 [12][4] const char apr_day_snames group__apr__time.html ga1 [7][4] apr_user User and Group ID Services group__apr__user.html #define apr_uid_compare group__apr__user.html ga8 (left, right) #define apr_gid_compare group__apr__user.html ga9 (left, right) uid_t apr_uid_t group__apr__user.html ga0 gid_t apr_gid_t group__apr__user.html ga1 apr_status_t apr_uid_current group__apr__user.html ga2 (apr_uid_t *userid, apr_gid_t *groupid, apr_pool_t *p) apr_status_t apr_uid_name_get group__apr__user.html ga3 (char **username, apr_uid_t userid, apr_pool_t *p) apr_status_t apr_uid_get group__apr__user.html ga4 (apr_uid_t *userid, apr_gid_t *groupid, const char *username, apr_pool_t *p) apr_status_t apr_uid_homepath_get group__apr__user.html ga5 (char **dirname, const char *username, apr_pool_t *p) apr_status_t apr_gid_name_get group__apr__user.html ga6 (char **groupname, apr_gid_t groupid, apr_pool_t *p) apr_status_t apr_gid_get group__apr__user.html ga7 (apr_gid_t *groupid, const char *groupname, apr_pool_t *p) include/ /home/joe/src/apache/apr/apr/trunk/include/ dir_000000.html apr.h apr_allocator.h apr_atomic.h apr_dso.h apr_env.h apr_errno.h apr_file_info.h apr_file_io.h apr_fnmatch.h apr_general.h apr_getopt.h apr_global_mutex.h apr_hash.h apr_inherit.h apr_lib.h apr_mmap.h apr_network_io.h apr_poll.h apr_pools.h apr_portable.h apr_proc_mutex.h apr_random.h apr_ring.h apr_shm.h apr_signal.h apr_strings.h apr_support.h apr_tables.h apr_thread_cond.h apr_thread_mutex.h apr_thread_proc.h apr_thread_rwlock.h apr_time.h apr_user.h apr_version.h apr_want.h random/ /home/joe/src/apache/apr/apr/trunk/random/ dir_000001.html random/unix/ random/unix/ /home/joe/src/apache/apr/apr/trunk/random/unix/ dir_000002.html sha2.h rapache-1.2.8/libapreq2/docs/apreq2.tag0000644000175100017510000016264312706745114017176 0ustar ondrejondrej index index apreq.h /home/joe/src/apache/httpd/apreq/trunk/include/ apreq_8h #define APREQ_DECLARE apreq_8h.html a0 (d) #define APREQ_DECLARE_NONSTD apreq_8h.html a1 (d) #define APREQ_DECLARE_DATA apreq_8h.html a2 #define APREQ_DEFAULT_READ_BLOCK_SIZE apreq_8h.html a3 #define APREQ_DEFAULT_READ_LIMIT apreq_8h.html a4 #define APREQ_DEFAULT_BRIGADE_LIMIT apreq_8h.html a5 #define APREQ_DEFAULT_NELTS apreq_8h.html a6 #define APREQ_FLAGS_OFF apreq_8h.html a7 (f, name) #define APREQ_FLAGS_ON apreq_8h.html a8 (f, name) #define APREQ_FLAGS_GET apreq_8h.html a9 (f, name) #define APREQ_FLAGS_SET apreq_8h.html a10 (f, name, value) #define APREQ_CHARSET_BIT apreq_8h.html a11 #define APREQ_CHARSET_MASK apreq_8h.html a12 #define APREQ_TAINTED_BIT apreq_8h.html a13 #define APREQ_TAINTED_MASK apreq_8h.html a14 #define APREQ_COOKIE_VERSION_BIT apreq_8h.html a15 #define APREQ_COOKIE_VERSION_MASK apreq_8h.html a16 #define APREQ_COOKIE_SECURE_BIT apreq_8h.html a17 #define APREQ_COOKIE_SECURE_MASK apreq_8h.html a18 #define apreq_attr_to_type apreq_8h.html a19 (T, A, P) apreq_value_t apreq_value_t apreq_8h.html a20 apreq_charset_t a37 apreq_join_t a38 APREQ_JOIN_AS_IS a38a25 APREQ_JOIN_ENCODE a38a26 APREQ_JOIN_DECODE a38a27 APREQ_JOIN_QUOTE a38a28 apreq_match_t a39 APREQ_MATCH_FULL a39a29 APREQ_MATCH_PARTIAL a39a30 apreq_expires_t a40 APREQ_EXPIRES_HTTP a40a31 APREQ_EXPIRES_NSCOOKIE a40a32 static APR_INLINE void apreq_value_table_add apreq_8h.html a33 (const apreq_value_t *v, apr_table_t *t) apr_status_t apreq_initialize apreq_8h.html a34 (apr_pool_t *pool) apr_status_t apreq_pre_initialize apreq_8h.html a35 (apr_pool_t *pool) apr_status_t apreq_post_initialize apreq_8h.html a36 (apr_pool_t *pool) apreq_cookie.h /home/joe/src/apache/httpd/apreq/trunk/include/ apreq__cookie_8h apreq.h #define APREQ_COOKIE_MAX_LENGTH apreq__cookie_8h.html a0 apreq_cookie_t apreq_cookie_t apreq__cookie_8h.html a1 static APR_INLINE apreq_cookie_t * apreq_value_to_cookie apreq__cookie_8h.html a2 (const char *val) static APR_INLINE unsigned apreq_cookie_version apreq__cookie_8h.html a3 (const apreq_cookie_t *c) static APR_INLINE void apreq_cookie_version_set apreq__cookie_8h.html a4 (apreq_cookie_t *c, unsigned v) static APR_INLINE unsigned apreq_cookie_is_secure apreq__cookie_8h.html a5 (const apreq_cookie_t *c) static APR_INLINE void apreq_cookie_secure_on apreq__cookie_8h.html a6 (apreq_cookie_t *c) static APR_INLINE void apreq_cookie_secure_off apreq__cookie_8h.html a7 (apreq_cookie_t *c) static APR_INLINE unsigned apreq_cookie_is_tainted apreq__cookie_8h.html a8 (const apreq_cookie_t *c) static APR_INLINE void apreq_cookie_tainted_on apreq__cookie_8h.html a9 (apreq_cookie_t *c) static APR_INLINE void apreq_cookie_tainted_off apreq__cookie_8h.html a10 (apreq_cookie_t *c) apr_status_t apreq_parse_cookie_header apreq__cookie_8h.html a11 (apr_pool_t *pool, apr_table_t *jar, const char *header) apreq_cookie_t * apreq_cookie_make apreq__cookie_8h.html a12 (apr_pool_t *pool, const char *name, const apr_size_t nlen, const char *value, const apr_size_t vlen) char * apreq_cookie_as_string apreq__cookie_8h.html a13 (const apreq_cookie_t *c, apr_pool_t *p) int apreq_cookie_serialize apreq__cookie_8h.html a14 (const apreq_cookie_t *c, char *buf, apr_size_t len) void apreq_cookie_expires apreq__cookie_8h.html a15 (apreq_cookie_t *c, const char *time_str) apreq_error.h /home/joe/src/apache/httpd/apreq/trunk/include/ apreq__error_8h apreq.h #define APR_EBADARG apreq__error_8h.html a0 #define APREQ_ERROR_GENERAL apreq__error_8h.html a1 #define APREQ_ERROR_TAINTED apreq__error_8h.html a2 #define APREQ_ERROR_INTERRUPT apreq__error_8h.html a3 #define APREQ_ERROR_BADDATA apreq__error_8h.html a4 #define APREQ_ERROR_BADCHAR apreq__error_8h.html a5 #define APREQ_ERROR_BADSEQ apreq__error_8h.html a6 #define APREQ_ERROR_BADATTR apreq__error_8h.html a7 #define APREQ_ERROR_BADHEADER apreq__error_8h.html a8 #define APREQ_ERROR_BADUTF8 apreq__error_8h.html a9 #define APREQ_ERROR_NODATA apreq__error_8h.html a10 #define APREQ_ERROR_NOTOKEN apreq__error_8h.html a11 #define APREQ_ERROR_NOATTR apreq__error_8h.html a12 #define APREQ_ERROR_NOHEADER apreq__error_8h.html a13 #define APREQ_ERROR_NOPARSER apreq__error_8h.html a14 #define APREQ_ERROR_MISMATCH apreq__error_8h.html a15 #define APREQ_ERROR_OVERLIMIT apreq__error_8h.html a16 #define APREQ_ERROR_UNDERLIMIT apreq__error_8h.html a17 #define APREQ_ERROR_NOTEMPTY apreq__error_8h.html a18 char * apreq_strerror apreq__error_8h.html a19 (apr_status_t s, char *buf, apr_size_t bufsize) apreq_module.h /home/joe/src/apache/httpd/apreq/trunk/include/ apreq__module_8h apreq_cookie.h apreq_parser.h apreq_error.h #define APREQ_MODULE apreq__module_8h.html a0 (pre, mmn) #define apreq_cookie apreq__module_8h.html a1 (req, name) apreq_handle_t apreq_handle_t apreq__module_8h.html a2 apreq_module_t apreq_module_t apreq__module_8h.html a3 static APR_INLINE unsigned apreq_module_status_is_error apreq__module_8h.html a4 (apr_status_t s) static APR_INLINE apr_status_t apreq_jar apreq__module_8h.html a5 (apreq_handle_t *req, const apr_table_t **t) static APR_INLINE apr_status_t apreq_args apreq__module_8h.html a6 (apreq_handle_t *req, const apr_table_t **t) static APR_INLINE apr_status_t apreq_body apreq__module_8h.html a7 (apreq_handle_t *req, const apr_table_t **t) static APR_INLINE apreq_cookie_t * apreq_jar_get apreq__module_8h.html a8 (apreq_handle_t *req, const char *name) static APR_INLINE apreq_param_t * apreq_args_get apreq__module_8h.html a9 (apreq_handle_t *req, const char *name) static APR_INLINE apreq_param_t * apreq_body_get apreq__module_8h.html a10 (apreq_handle_t *req, const char *name) static APR_INLINE apr_status_t apreq_parser_get apreq__module_8h.html a11 (apreq_handle_t *req, const apreq_parser_t **parser) static APR_INLINE apr_status_t apreq_parser_set apreq__module_8h.html a12 (apreq_handle_t *req, apreq_parser_t *parser) static APR_INLINE apr_status_t apreq_hook_add apreq__module_8h.html a13 (apreq_handle_t *req, apreq_hook_t *hook) static APR_INLINE apr_status_t apreq_brigade_limit_set apreq__module_8h.html a14 (apreq_handle_t *req, apr_size_t bytes) static APR_INLINE apr_status_t apreq_brigade_limit_get apreq__module_8h.html a15 (apreq_handle_t *req, apr_size_t *bytes) static APR_INLINE apr_status_t apreq_read_limit_set apreq__module_8h.html a16 (apreq_handle_t *req, apr_uint64_t bytes) static APR_INLINE apr_status_t apreq_read_limit_get apreq__module_8h.html a17 (apreq_handle_t *req, apr_uint64_t *bytes) static APR_INLINE apr_status_t apreq_temp_dir_set apreq__module_8h.html a18 (apreq_handle_t *req, const char *path) static APR_INLINE apr_status_t apreq_temp_dir_get apreq__module_8h.html a19 (apreq_handle_t *req, const char **path) apreq_handle_t * apreq_handle_cgi apreq__module_8h.html a20 (apr_pool_t *pool) apreq_handle_t * apreq_handle_custom apreq__module_8h.html a21 (apr_pool_t *pool, const char *query_string, const char *cookie, apreq_parser_t *parser, apr_uint64_t read_limit, apr_bucket_brigade *in) apr_status_t apreq_cookie_bake apreq__module_8h.html a22 (const apreq_cookie_t *c, apreq_handle_t *req) apr_status_t apreq_cookie_bake2 apreq__module_8h.html a23 (const apreq_cookie_t *c, apreq_handle_t *req) unsigned apreq_ua_cookie_version apreq__module_8h.html a24 (apreq_handle_t *req) apreq_param_t * apreq_param apreq__module_8h.html a25 (apreq_handle_t *req, const char *key) apr_table_t * apreq_params apreq__module_8h.html a26 (apreq_handle_t *req, apr_pool_t *p) apr_table_t * apreq_cookies apreq__module_8h.html a27 (apreq_handle_t *req, apr_pool_t *p) static APR_INLINE apr_status_t apreq_parse apreq__module_8h.html a28 (apreq_handle_t *req) apreq_param.h /home/joe/src/apache/httpd/apreq/trunk/include/ apreq__param_8h apreq.h apreq_param_t apreq_param_t apreq__param_8h.html a0 static APR_INLINE unsigned apreq_param_is_tainted apreq__param_8h.html a1 (const apreq_param_t *p) static APR_INLINE void apreq_param_tainted_on apreq__param_8h.html a2 (apreq_param_t *p) static APR_INLINE void apreq_param_tainted_off apreq__param_8h.html a3 (apreq_param_t *p) static APR_INLINE apreq_charset_t apreq_param_charset_set apreq__param_8h.html a4 (apreq_param_t *p, unsigned char c) static APR_INLINE apreq_charset_t apreq_param_charset_get apreq__param_8h.html a5 (apreq_param_t *p) static APR_INLINE apreq_param_t * apreq_value_to_param apreq__param_8h.html a6 (const char *val) apreq_param_t * apreq_param_make apreq__param_8h.html a7 (apr_pool_t *p, const char *name, const apr_size_t nlen, const char *val, const apr_size_t vlen) apr_status_t apreq_param_decode apreq__param_8h.html a8 (apreq_param_t **param, apr_pool_t *pool, const char *word, apr_size_t nlen, apr_size_t vlen) char * apreq_param_encode apreq__param_8h.html a9 (apr_pool_t *pool, const apreq_param_t *param) apr_status_t apreq_parse_query_string apreq__param_8h.html a10 (apr_pool_t *pool, apr_table_t *t, const char *qs) apr_array_header_t * apreq_params_as_array apreq__param_8h.html a11 (apr_pool_t *p, const apr_table_t *t, const char *key) const char * apreq_params_as_string apreq__param_8h.html a12 (apr_pool_t *p, const apr_table_t *t, const char *key, apreq_join_t mode) const apr_table_t * apreq_uploads apreq__param_8h.html a13 (const apr_table_t *body, apr_pool_t *pool) const apreq_param_t * apreq_upload apreq__param_8h.html a14 (const apr_table_t *body, const char *name) apreq_parser.h /home/joe/src/apache/httpd/apreq/trunk/include/ apreq__parser_8h apreq_param.h #define APREQ_PARSER_ARGS apreq__parser_8h.html a0 #define APREQ_HOOK_ARGS apreq__parser_8h.html a1 #define APREQ_DECLARE_PARSER apreq__parser_8h.html a2 (f) #define APREQ_DECLARE_HOOK apreq__parser_8h.html a3 (f) apreq_hook_t apreq_hook_t apreq__parser_8h.html a4 apreq_parser_t apreq_parser_t apreq__parser_8h.html a5 apr_status_t(* apreq_parser_function_t apreq__parser_8h.html a6 )(APREQ_PARSER_ARGS) apr_status_t(* apreq_hook_function_t apreq__parser_8h.html a7 )(APREQ_HOOK_ARGS) static APR_INLINE apr_status_t apreq_parser_run apreq__parser_8h.html a8 (struct apreq_parser_t *psr, apr_table_t *t, apr_bucket_brigade *bb) static APR_INLINE apr_status_t apreq_hook_run apreq__parser_8h.html a9 (struct apreq_hook_t *h, apreq_param_t *param, apr_bucket_brigade *bb) APREQ_DECLARE_PARSER apreq__parser_8h.html a10 (apreq_parse_headers) APREQ_DECLARE_PARSER apreq__parser_8h.html a11 (apreq_parse_urlencoded) APREQ_DECLARE_PARSER apreq__parser_8h.html a12 (apreq_parse_multipart) APREQ_DECLARE_PARSER apreq__parser_8h.html a13 (apreq_parse_generic) APREQ_DECLARE_HOOK apreq__parser_8h.html a14 (apreq_hook_apr_xml_parser) apreq_parser_t * apreq_parser_make apreq__parser_8h.html a15 (apr_pool_t *pool, apr_bucket_alloc_t *ba, const char *content_type, apreq_parser_function_t pfn, apr_size_t brigade_limit, const char *temp_dir, apreq_hook_t *hook, void *ctx) apreq_hook_t * apreq_hook_make apreq__parser_8h.html a16 (apr_pool_t *pool, apreq_hook_function_t hook, apreq_hook_t *next, void *ctx) apr_status_t apreq_parser_add_hook apreq__parser_8h.html a17 (apreq_parser_t *p, apreq_hook_t *h) apreq_parser_function_t apreq_parser apreq__parser_8h.html a18 (const char *enctype) apr_status_t apreq_register_parser apreq__parser_8h.html a19 (const char *enctype, apreq_parser_function_t pfn) APREQ_DECLARE_HOOK apreq__parser_8h.html a20 (apreq_hook_disable_uploads) APREQ_DECLARE_HOOK apreq__parser_8h.html a21 (apreq_hook_discard_brigade) APREQ_DECLARE_HOOK apreq__parser_8h.html a22 (apreq_hook_find_param) apreq_util.h /home/joe/src/apache/httpd/apreq/trunk/include/ apreq__util_8h apreq.h char * apreq_join apreq__util_8h.html a0 (apr_pool_t *p, const char *sep, const apr_array_header_t *arr, apreq_join_t mode) apr_ssize_t apreq_index apreq__util_8h.html a1 (const char *hay, apr_size_t hlen, const char *ndl, apr_size_t nlen, const apreq_match_t type) apr_size_t apreq_quote apreq__util_8h.html a2 (char *dest, const char *src, const apr_size_t slen) apr_size_t apreq_quote_once apreq__util_8h.html a3 (char *dest, const char *src, const apr_size_t slen) apr_size_t apreq_encode apreq__util_8h.html a4 (char *dest, const char *src, const apr_size_t slen) apr_size_t apreq_cp1252_to_utf8 apreq__util_8h.html a5 (char *dest, const char *src, apr_size_t slen) apr_status_t apreq_decode apreq__util_8h.html a6 (char *dest, apr_size_t *dlen, const char *src, apr_size_t slen) apr_status_t apreq_decodev apreq__util_8h.html a7 (char *dest, apr_size_t *dlen, struct iovec *v, int nelts) static APR_INLINE char * apreq_escape apreq__util_8h.html a8 (apr_pool_t *p, const char *src, const apr_size_t slen) static APR_INLINE apr_ssize_t apreq_unescape apreq__util_8h.html a9 (char *str) apr_int64_t apreq_atoi64f apreq__util_8h.html a10 (const char *s) apr_int64_t apreq_atoi64t apreq__util_8h.html a11 (const char *s) apr_status_t apreq_brigade_fwrite apreq__util_8h.html a12 (apr_file_t *f, apr_off_t *wlen, apr_bucket_brigade *bb) apr_status_t apreq_file_mktemp apreq__util_8h.html a13 (apr_file_t **fp, apr_pool_t *pool, const char *path) static APR_INLINE apr_status_t apreq_brigade_setaside apreq__util_8h.html a14 (apr_bucket_brigade *bb, apr_pool_t *p) static APR_INLINE apr_status_t apreq_brigade_copy apreq__util_8h.html a15 (apr_bucket_brigade *d, apr_bucket_brigade *s) static APR_INLINE void apreq_brigade_move apreq__util_8h.html a16 (apr_bucket_brigade *d, apr_bucket_brigade *s, apr_bucket *e) apr_status_t apreq_header_attribute apreq__util_8h.html a17 (const char *hdr, const char *name, const apr_size_t nlen, const char **val, apr_size_t *vlen) apr_status_t apreq_brigade_concat apreq__util_8h.html a18 (apr_pool_t *pool, const char *temp_dir, apr_size_t brigade_limit, apr_bucket_brigade *out, apr_bucket_brigade *in) apr_file_t * apreq_brigade_spoolfile apreq__util_8h.html a19 (apr_bucket_brigade *bb) apreq_version.h /home/joe/src/apache/httpd/apreq/trunk/include/ apreq__version_8h apreq.h #define APREQ_MAJOR_VERSION apreq__version_8h.html a0 #define APREQ_MINOR_VERSION apreq__version_8h.html a1 #define APREQ_PATCH_VERSION apreq__version_8h.html a2 #define APREQ_IS_DEV_VERSION apreq__version_8h.html a3 #define APREQ_VERSION_STRING apreq__version_8h.html a4 #define APREQ_IS_DEV_STRING apreq__version_8h.html a5 void apreq_version apreq__version_8h.html a6 (apr_version_t *pvsn) const char * apreq_version_string apreq__version_8h.html a7 (void) apreq_cookie_t structapreq__cookie__t.html char * path structapreq__cookie__t.html o0 char * domain structapreq__cookie__t.html o1 char * port structapreq__cookie__t.html o2 char * comment structapreq__cookie__t.html o3 char * commentURL structapreq__cookie__t.html o4 apr_time_t max_age structapreq__cookie__t.html o5 unsigned flags structapreq__cookie__t.html o6 const apreq_value_t v structapreq__cookie__t.html o7 apreq_handle_t structapreq__handle__t.html const struct apreq_module_t * module structapreq__handle__t.html o0 apr_pool_t * pool structapreq__handle__t.html o1 apr_bucket_alloc_t * bucket_alloc structapreq__handle__t.html o2 apreq_hook_t structapreq__hook__t.html apreq_hook_function_t hook structapreq__hook__t.html o0 apreq_hook_t * next structapreq__hook__t.html o1 apr_pool_t * pool structapreq__hook__t.html o2 void * ctx structapreq__hook__t.html o3 apreq_module_t structapreq__module__t.html const char * name structapreq__module__t.html o0 apr_uint32_t magic_number structapreq__module__t.html o1 apr_status_t(* jar structapreq__module__t.html o2 )(apreq_handle_t *, const apr_table_t **) apr_status_t(* args structapreq__module__t.html o3 )(apreq_handle_t *, const apr_table_t **) apr_status_t(* body structapreq__module__t.html o4 )(apreq_handle_t *, const apr_table_t **) apreq_cookie_t *(* jar_get structapreq__module__t.html o5 )(apreq_handle_t *, const char *) apreq_param_t *(* args_get structapreq__module__t.html o6 )(apreq_handle_t *, const char *) apreq_param_t *(* body_get structapreq__module__t.html o7 )(apreq_handle_t *, const char *) apr_status_t(* parser_get structapreq__module__t.html o8 )(apreq_handle_t *, const apreq_parser_t **) apr_status_t(* parser_set structapreq__module__t.html o9 )(apreq_handle_t *, apreq_parser_t *) apr_status_t(* hook_add structapreq__module__t.html o10 )(apreq_handle_t *, apreq_hook_t *) apr_status_t(* brigade_limit_get structapreq__module__t.html o11 )(apreq_handle_t *, apr_size_t *) apr_status_t(* brigade_limit_set structapreq__module__t.html o12 )(apreq_handle_t *, apr_size_t) apr_status_t(* read_limit_get structapreq__module__t.html o13 )(apreq_handle_t *, apr_uint64_t *) apr_status_t(* read_limit_set structapreq__module__t.html o14 )(apreq_handle_t *, apr_uint64_t) apr_status_t(* temp_dir_get structapreq__module__t.html o15 )(apreq_handle_t *, const char **) apr_status_t(* temp_dir_set structapreq__module__t.html o16 )(apreq_handle_t *, const char *) apreq_param_t structapreq__param__t.html apr_table_t * info structapreq__param__t.html o0 apr_bucket_brigade * upload structapreq__param__t.html o1 unsigned flags structapreq__param__t.html o2 const apreq_value_t v structapreq__param__t.html o3 apreq_parser_t structapreq__parser__t.html apreq_parser_function_t parser structapreq__parser__t.html o0 const char * content_type structapreq__parser__t.html o1 apr_pool_t * pool structapreq__parser__t.html o2 apr_bucket_alloc_t * bucket_alloc structapreq__parser__t.html o3 apr_size_t brigade_limit structapreq__parser__t.html o4 const char * temp_dir structapreq__parser__t.html o5 apreq_hook_t * hook structapreq__parser__t.html o6 void * ctx structapreq__parser__t.html o7 apreq_value_t structapreq__value__t.html char * name structapreq__value__t.html o0 apr_size_t nlen structapreq__value__t.html o1 apr_size_t dlen structapreq__value__t.html o2 char data structapreq__value__t.html o3 [1] apreq_changes CHANGES apreq_changes v2_0_0 v2_01_dev v2_02_dev v2_03_dev v2_04_dev v2_05_dev apreq_status STATUS apreq_status apreq_license LICENSE apreq_license apreq_notice NOTICE apreq_notice apreq_install INSTALL apreq_install apreq_faq FAQ apreq_faq libapreq2 Apache Request Library group__libapreq2.html apreq.h apreq_cookie.h apreq_error.h apreq_module.h apreq_param.h apreq_parser.h apreq_util.h apreq_version.h apreq2_config apreq_module Modules group__apreq__module.html mod_apreq2 apreq_lang Language Bindings group__apreq__lang.html apreq_xs apreq_xs Perl group__apreq__xs.html apreq_xs_request apreq_xs_upload apreq_xs_cookie apreq_xs_request Apache2::Request group__apreq__xs__request.html apreq_xs_upload Apache2::Upload group__apreq__xs__upload.html apreq_xs_cookie Apache2::Cookie group__apreq__xs__cookie.html mod_apreq2 Apache 2.X Filter Module group__mod__apreq2.html apreq_handle_t * apreq_handle_apache2 group__mod__apreq2.html ga0 (request_rec *r) module/apache/ /home/joe/src/apache/httpd/apreq/trunk/module/apache/ dir_000002.html apreq_module_apache.h module/apache2/ /home/joe/src/apache/httpd/apreq/trunk/module/apache2/ dir_000003.html apreq_module_apache2.h include/ /home/joe/src/apache/httpd/apreq/trunk/include/ dir_000000.html apreq.h apreq_cookie.h apreq_error.h apreq_module.h apreq_param.h apreq_parser.h apreq_util.h apreq_version.h module/ /home/joe/src/apache/httpd/apreq/trunk/module/ dir_000001.html module/apache/ module/apache2/ rapache-1.2.8/libapreq2/docs/apu.tag0000644000175100017510000064370012706745114016567 0ustar ondrejondrej apr_anylock.h /home/joe/src/apache/apr/apr-util/trunk/include/ apr__anylock_8h #define APR_ANYLOCK_LOCK apr__anylock_8h.html a0 (lck) #define APR_ANYLOCK_TRYLOCK apr__anylock_8h.html a1 (lck) #define APR_ANYLOCK_UNLOCK apr__anylock_8h.html a2 (lck) apr_anylock_t apr_anylock_t apr__anylock_8h.html a3 apr_base64.h /home/joe/src/apache/apr/apr-util/trunk/include/ apr__base64_8h int apr_base64_encode_len group___a_p_r___util___base64.html ga0 (int len) int apr_base64_encode group___a_p_r___util___base64.html ga1 (char *coded_dst, const char *plain_src, int len_plain_src) int apr_base64_encode_binary group___a_p_r___util___base64.html ga2 (char *coded_dst, const unsigned char *plain_src, int len_plain_src) int apr_base64_decode_len group___a_p_r___util___base64.html ga3 (const char *coded_src) int apr_base64_decode group___a_p_r___util___base64.html ga4 (char *plain_dst, const char *coded_src) int apr_base64_decode_binary group___a_p_r___util___base64.html ga5 (unsigned char *plain_dst, const char *coded_src) apr_buckets.h /home/joe/src/apache/apr/apr-util/trunk/include/ apr__buckets_8h #define APR_BUCKET_BUFF_SIZE group___a_p_r___util___bucket___brigades.html ga77 #define APR_BRIGADE_CHECK_CONSISTENCY group___a_p_r___util___bucket___brigades.html ga78 (b) #define APR_BUCKET_CHECK_CONSISTENCY group___a_p_r___util___bucket___brigades.html ga79 (e) #define APR_BRIGADE_SENTINEL group___a_p_r___util___bucket___brigades.html ga80 (b) #define APR_BRIGADE_EMPTY group___a_p_r___util___bucket___brigades.html ga81 (b) #define APR_BRIGADE_FIRST group___a_p_r___util___bucket___brigades.html ga82 (b) #define APR_BRIGADE_LAST group___a_p_r___util___bucket___brigades.html ga83 (b) #define APR_BRIGADE_INSERT_HEAD group___a_p_r___util___bucket___brigades.html ga84 (b, e) #define APR_BRIGADE_INSERT_TAIL group___a_p_r___util___bucket___brigades.html ga85 (b, e) #define APR_BRIGADE_CONCAT group___a_p_r___util___bucket___brigades.html ga86 (a, b) #define APR_BRIGADE_PREPEND group___a_p_r___util___bucket___brigades.html ga87 (a, b) #define APR_BUCKET_INSERT_BEFORE group___a_p_r___util___bucket___brigades.html ga88 (a, b) #define APR_BUCKET_INSERT_AFTER group___a_p_r___util___bucket___brigades.html ga89 (a, b) #define APR_BUCKET_NEXT group___a_p_r___util___bucket___brigades.html ga90 (e) #define APR_BUCKET_PREV group___a_p_r___util___bucket___brigades.html ga91 (e) #define APR_BUCKET_REMOVE group___a_p_r___util___bucket___brigades.html ga92 (e) #define APR_BUCKET_INIT group___a_p_r___util___bucket___brigades.html ga93 (e) #define APR_BUCKET_IS_METADATA group___a_p_r___util___bucket___brigades.html ga94 (e) #define APR_BUCKET_IS_FLUSH group___a_p_r___util___bucket___brigades.html ga95 (e) #define APR_BUCKET_IS_EOS group___a_p_r___util___bucket___brigades.html ga96 (e) #define APR_BUCKET_IS_FILE group___a_p_r___util___bucket___brigades.html ga97 (e) #define APR_BUCKET_IS_PIPE group___a_p_r___util___bucket___brigades.html ga98 (e) #define APR_BUCKET_IS_SOCKET group___a_p_r___util___bucket___brigades.html ga99 (e) #define APR_BUCKET_IS_HEAP group___a_p_r___util___bucket___brigades.html ga100 (e) #define APR_BUCKET_IS_TRANSIENT group___a_p_r___util___bucket___brigades.html ga101 (e) #define APR_BUCKET_IS_IMMORTAL group___a_p_r___util___bucket___brigades.html ga102 (e) #define APR_BUCKET_IS_MMAP group___a_p_r___util___bucket___brigades.html ga103 (e) #define APR_BUCKET_IS_POOL group___a_p_r___util___bucket___brigades.html ga104 (e) #define APR_BUCKET_ALLOC_SIZE group___a_p_r___util___bucket___brigades.html ga105 #define apr_bucket_destroy group___a_p_r___util___bucket___brigades.html ga106 (e) #define apr_bucket_delete group___a_p_r___util___bucket___brigades.html ga107 (e) #define apr_bucket_read group___a_p_r___util___bucket___brigades.html ga108 (e, str, len, block) #define apr_bucket_setaside group___a_p_r___util___bucket___brigades.html ga109 (e, p) #define apr_bucket_split group___a_p_r___util___bucket___brigades.html ga110 (e, point) #define apr_bucket_copy group___a_p_r___util___bucket___brigades.html ga111 (e, c) apr_bucket_brigade apr_bucket_brigade group___a_p_r___util___bucket___brigades.html ga0 apr_bucket apr_bucket group___a_p_r___util___bucket___brigades.html ga1 apr_bucket_alloc_t apr_bucket_alloc_t group___a_p_r___util___bucket___brigades.html ga2 apr_bucket_type_t apr_bucket_type_t group___a_p_r___util___bucket___brigades.html ga3 apr_status_t(* apr_brigade_flush group___a_p_r___util___bucket___brigades.html ga4 )(apr_bucket_brigade *bb, void *ctx) apr_bucket_refcount apr_bucket_refcount group___a_p_r___util___bucket___brigades.html ga5 apr_bucket_heap apr_bucket_heap group___a_p_r___util___bucket___brigades.html ga6 apr_bucket_pool apr_bucket_pool group___a_p_r___util___bucket___brigades.html ga7 apr_bucket_mmap apr_bucket_mmap group___a_p_r___util___bucket___brigades.html ga8 apr_bucket_file apr_bucket_file group___a_p_r___util___bucket___brigades.html ga9 apr_bucket_structs apr_bucket_structs group___a_p_r___util___bucket___brigades.html ga10 apr_read_type_e ga112 APR_BLOCK_READ gga112a56 APR_NONBLOCK_READ gga112a57 apr_bucket_brigade * apr_brigade_create group___a_p_r___util___bucket___brigades.html ga21 (apr_pool_t *p, apr_bucket_alloc_t *list) apr_status_t apr_brigade_destroy group___a_p_r___util___bucket___brigades.html ga22 (apr_bucket_brigade *b) apr_status_t apr_brigade_cleanup group___a_p_r___util___bucket___brigades.html ga23 (void *data) apr_bucket_brigade * apr_brigade_split group___a_p_r___util___bucket___brigades.html ga24 (apr_bucket_brigade *b, apr_bucket *e) apr_status_t apr_brigade_partition group___a_p_r___util___bucket___brigades.html ga25 (apr_bucket_brigade *b, apr_off_t point, apr_bucket **after_point) apr_status_t apr_brigade_length group___a_p_r___util___bucket___brigades.html ga26 (apr_bucket_brigade *bb, int read_all, apr_off_t *length) apr_status_t apr_brigade_flatten group___a_p_r___util___bucket___brigades.html ga27 (apr_bucket_brigade *bb, char *c, apr_size_t *len) apr_status_t apr_brigade_pflatten group___a_p_r___util___bucket___brigades.html ga28 (apr_bucket_brigade *bb, char **c, apr_size_t *len, apr_pool_t *pool) apr_status_t apr_brigade_split_line group___a_p_r___util___bucket___brigades.html ga29 (apr_bucket_brigade *bbOut, apr_bucket_brigade *bbIn, apr_read_type_e block, apr_off_t maxbytes) apr_status_t apr_brigade_to_iovec group___a_p_r___util___bucket___brigades.html ga30 (apr_bucket_brigade *b, struct iovec *vec, int *nvec) apr_status_t apr_brigade_vputstrs group___a_p_r___util___bucket___brigades.html ga31 (apr_bucket_brigade *b, apr_brigade_flush flush, void *ctx, va_list va) apr_status_t apr_brigade_write group___a_p_r___util___bucket___brigades.html ga32 (apr_bucket_brigade *b, apr_brigade_flush flush, void *ctx, const char *str, apr_size_t nbyte) apr_status_t apr_brigade_writev group___a_p_r___util___bucket___brigades.html ga33 (apr_bucket_brigade *b, apr_brigade_flush flush, void *ctx, const struct iovec *vec, apr_size_t nvec) apr_status_t apr_brigade_puts group___a_p_r___util___bucket___brigades.html ga34 (apr_bucket_brigade *bb, apr_brigade_flush flush, void *ctx, const char *str) apr_status_t apr_brigade_putc group___a_p_r___util___bucket___brigades.html ga35 (apr_bucket_brigade *b, apr_brigade_flush flush, void *ctx, const char c) apr_status_t apr_brigade_putstrs group___a_p_r___util___bucket___brigades.html ga36 (apr_bucket_brigade *b, apr_brigade_flush flush, void *ctx,...) apr_status_t apr_brigade_printf group___a_p_r___util___bucket___brigades.html ga37 (apr_bucket_brigade *b, apr_brigade_flush flush, void *ctx, const char *fmt,...) apr_status_t apr_brigade_vprintf group___a_p_r___util___bucket___brigades.html ga38 (apr_bucket_brigade *b, apr_brigade_flush flush, void *ctx, const char *fmt, va_list va) apr_bucket * apr_brigade_insert_file group___a_p_r___util___bucket___brigades.html ga39 (apr_bucket_brigade *bb, apr_file_t *f, apr_off_t start, apr_off_t len, apr_pool_t *p) apr_bucket_alloc_t * apr_bucket_alloc_create group___a_p_r___util___bucket___brigades.html ga40 (apr_pool_t *p) apr_bucket_alloc_t * apr_bucket_alloc_create_ex group___a_p_r___util___bucket___brigades.html ga41 (apr_allocator_t *allocator) void apr_bucket_alloc_destroy group___a_p_r___util___bucket___brigades.html ga42 (apr_bucket_alloc_t *list) void * apr_bucket_alloc group___a_p_r___util___bucket___brigades.html ga43 (apr_size_t size, apr_bucket_alloc_t *list) void apr_bucket_free group___a_p_r___util___bucket___brigades.html ga44 (void *block) apr_status_t apr_bucket_setaside_noop group___a_p_r___util___bucket___brigades.html ga45 (apr_bucket *data, apr_pool_t *pool) apr_status_t apr_bucket_setaside_notimpl group___a_p_r___util___bucket___brigades.html ga46 (apr_bucket *data, apr_pool_t *pool) apr_status_t apr_bucket_split_notimpl group___a_p_r___util___bucket___brigades.html ga47 (apr_bucket *data, apr_size_t point) apr_status_t apr_bucket_copy_notimpl group___a_p_r___util___bucket___brigades.html ga48 (apr_bucket *e, apr_bucket **c) void apr_bucket_destroy_noop group___a_p_r___util___bucket___brigades.html ga49 (void *data) apr_status_t apr_bucket_simple_split group___a_p_r___util___bucket___brigades.html ga50 (apr_bucket *b, apr_size_t point) apr_status_t apr_bucket_simple_copy group___a_p_r___util___bucket___brigades.html ga51 (apr_bucket *a, apr_bucket **b) apr_bucket * apr_bucket_shared_make group___a_p_r___util___bucket___brigades.html ga52 (apr_bucket *b, void *data, apr_off_t start, apr_size_t length) int apr_bucket_shared_destroy group___a_p_r___util___bucket___brigades.html ga53 (void *data) apr_status_t apr_bucket_shared_split group___a_p_r___util___bucket___brigades.html ga54 (apr_bucket *b, apr_size_t point) apr_status_t apr_bucket_shared_copy group___a_p_r___util___bucket___brigades.html ga55 (apr_bucket *a, apr_bucket **b) apr_bucket * apr_bucket_eos_create group___a_p_r___util___bucket___brigades.html ga56 (apr_bucket_alloc_t *list) apr_bucket * apr_bucket_eos_make group___a_p_r___util___bucket___brigades.html ga57 (apr_bucket *b) apr_bucket * apr_bucket_flush_create group___a_p_r___util___bucket___brigades.html ga58 (apr_bucket_alloc_t *list) apr_bucket * apr_bucket_flush_make group___a_p_r___util___bucket___brigades.html ga59 (apr_bucket *b) apr_bucket * apr_bucket_immortal_create group___a_p_r___util___bucket___brigades.html ga60 (const char *buf, apr_size_t nbyte, apr_bucket_alloc_t *list) apr_bucket * apr_bucket_immortal_make group___a_p_r___util___bucket___brigades.html ga61 (apr_bucket *b, const char *buf, apr_size_t nbyte) apr_bucket * apr_bucket_transient_create group___a_p_r___util___bucket___brigades.html ga62 (const char *buf, apr_size_t nbyte, apr_bucket_alloc_t *list) apr_bucket * apr_bucket_transient_make group___a_p_r___util___bucket___brigades.html ga63 (apr_bucket *b, const char *buf, apr_size_t nbyte) apr_bucket * apr_bucket_heap_create group___a_p_r___util___bucket___brigades.html ga64 (const char *buf, apr_size_t nbyte, void(*free_func)(void *data), apr_bucket_alloc_t *list) apr_bucket * apr_bucket_heap_make group___a_p_r___util___bucket___brigades.html ga65 (apr_bucket *b, const char *buf, apr_size_t nbyte, void(*free_func)(void *data)) apr_bucket * apr_bucket_pool_create group___a_p_r___util___bucket___brigades.html ga66 (const char *buf, apr_size_t length, apr_pool_t *pool, apr_bucket_alloc_t *list) apr_bucket * apr_bucket_pool_make group___a_p_r___util___bucket___brigades.html ga67 (apr_bucket *b, const char *buf, apr_size_t length, apr_pool_t *pool) apr_bucket * apr_bucket_mmap_create group___a_p_r___util___bucket___brigades.html ga68 (apr_mmap_t *mm, apr_off_t start, apr_size_t length, apr_bucket_alloc_t *list) apr_bucket * apr_bucket_mmap_make group___a_p_r___util___bucket___brigades.html ga69 (apr_bucket *b, apr_mmap_t *mm, apr_off_t start, apr_size_t length) apr_bucket * apr_bucket_socket_create group___a_p_r___util___bucket___brigades.html ga70 (apr_socket_t *thissock, apr_bucket_alloc_t *list) apr_bucket * apr_bucket_socket_make group___a_p_r___util___bucket___brigades.html ga71 (apr_bucket *b, apr_socket_t *thissock) apr_bucket * apr_bucket_pipe_create group___a_p_r___util___bucket___brigades.html ga72 (apr_file_t *thispipe, apr_bucket_alloc_t *list) apr_bucket * apr_bucket_pipe_make group___a_p_r___util___bucket___brigades.html ga73 (apr_bucket *b, apr_file_t *thispipe) apr_bucket * apr_bucket_file_create group___a_p_r___util___bucket___brigades.html ga74 (apr_file_t *fd, apr_off_t offset, apr_size_t len, apr_pool_t *p, apr_bucket_alloc_t *list) apr_bucket * apr_bucket_file_make group___a_p_r___util___bucket___brigades.html ga75 (apr_bucket *b, apr_file_t *fd, apr_off_t offset, apr_size_t len, apr_pool_t *p) apr_status_t apr_bucket_file_enable_mmap group___a_p_r___util___bucket___brigades.html ga76 (apr_bucket *b, int enabled) const apr_bucket_type_t apr_bucket_type_flush group___a_p_r___util___bucket___brigades.html ga11 const apr_bucket_type_t apr_bucket_type_eos group___a_p_r___util___bucket___brigades.html ga12 const apr_bucket_type_t apr_bucket_type_file group___a_p_r___util___bucket___brigades.html ga13 const apr_bucket_type_t apr_bucket_type_heap group___a_p_r___util___bucket___brigades.html ga14 const apr_bucket_type_t apr_bucket_type_mmap group___a_p_r___util___bucket___brigades.html ga15 const apr_bucket_type_t apr_bucket_type_pool group___a_p_r___util___bucket___brigades.html ga16 const apr_bucket_type_t apr_bucket_type_pipe group___a_p_r___util___bucket___brigades.html ga17 const apr_bucket_type_t apr_bucket_type_immortal group___a_p_r___util___bucket___brigades.html ga18 const apr_bucket_type_t apr_bucket_type_transient group___a_p_r___util___bucket___brigades.html ga19 const apr_bucket_type_t apr_bucket_type_socket group___a_p_r___util___bucket___brigades.html ga20 apr_date.h /home/joe/src/apache/apr/apr-util/trunk/include/ apr__date_8h #define APR_DATE_BAD group___a_p_r___util___date.html ga3 int apr_date_checkmask group___a_p_r___util___date.html ga0 (const char *data, const char *mask) apr_time_t apr_date_parse_http group___a_p_r___util___date.html ga1 (const char *date) apr_time_t apr_date_parse_rfc group___a_p_r___util___date.html ga2 (const char *date) apr_dbm.h /home/joe/src/apache/apr/apr-util/trunk/include/ apr__dbm_8h #define APR_DBM_READONLY group___a_p_r___util___d_b_m.html ga14 #define APR_DBM_READWRITE group___a_p_r___util___d_b_m.html ga15 #define APR_DBM_RWCREATE group___a_p_r___util___d_b_m.html ga16 #define APR_DBM_RWTRUNC group___a_p_r___util___d_b_m.html ga17 apr_dbm_t apr_dbm_t group___a_p_r___util___d_b_m.html ga0 apr_status_t apr_dbm_open_ex group___a_p_r___util___d_b_m.html ga1 (apr_dbm_t **dbm, const char *type, const char *name, apr_int32_t mode, apr_fileperms_t perm, apr_pool_t *cntxt) apr_status_t apr_dbm_open group___a_p_r___util___d_b_m.html ga2 (apr_dbm_t **dbm, const char *name, apr_int32_t mode, apr_fileperms_t perm, apr_pool_t *cntxt) void apr_dbm_close group___a_p_r___util___d_b_m.html ga3 (apr_dbm_t *dbm) apr_status_t apr_dbm_fetch group___a_p_r___util___d_b_m.html ga4 (apr_dbm_t *dbm, apr_datum_t key, apr_datum_t *pvalue) apr_status_t apr_dbm_store group___a_p_r___util___d_b_m.html ga5 (apr_dbm_t *dbm, apr_datum_t key, apr_datum_t value) apr_status_t apr_dbm_delete group___a_p_r___util___d_b_m.html ga6 (apr_dbm_t *dbm, apr_datum_t key) int apr_dbm_exists group___a_p_r___util___d_b_m.html ga7 (apr_dbm_t *dbm, apr_datum_t key) apr_status_t apr_dbm_firstkey group___a_p_r___util___d_b_m.html ga8 (apr_dbm_t *dbm, apr_datum_t *pkey) apr_status_t apr_dbm_nextkey group___a_p_r___util___d_b_m.html ga9 (apr_dbm_t *dbm, apr_datum_t *pkey) void apr_dbm_freedatum group___a_p_r___util___d_b_m.html ga10 (apr_dbm_t *dbm, apr_datum_t data) char * apr_dbm_geterror group___a_p_r___util___d_b_m.html ga11 (apr_dbm_t *dbm, int *errcode, char *errbuf, apr_size_t errbufsize) apr_status_t apr_dbm_get_usednames_ex group___a_p_r___util___d_b_m.html ga12 (apr_pool_t *pool, const char *type, const char *pathname, const char **used1, const char **used2) void apr_dbm_get_usednames group___a_p_r___util___d_b_m.html ga13 (apr_pool_t *pool, const char *pathname, const char **used1, const char **used2) apr_hooks.h /home/joe/src/apache/apr/apr-util/trunk/include/ apr__hooks_8h #define APR_IMPLEMENT_HOOK_GET_PROTO group___a_p_r___util___hook.html ga7 (ns, link, name) #define APR_DECLARE_EXTERNAL_HOOK group___a_p_r___util___hook.html ga8 (ns, link, ret, name, args) #define APR_HOOK_STRUCT group___a_p_r___util___hook.html ga9 (members) #define APR_HOOK_LINK group___a_p_r___util___hook.html ga10 (name) #define APR_IMPLEMENT_EXTERNAL_HOOK_BASE group___a_p_r___util___hook.html ga11 (ns, link, name) #define APR_IMPLEMENT_EXTERNAL_HOOK_VOID group___a_p_r___util___hook.html ga12 (ns, link, name, args_decl, args_use) #define APR_IMPLEMENT_EXTERNAL_HOOK_RUN_ALL group___a_p_r___util___hook.html ga13 (ns, link, ret, name, args_decl, args_use, ok, decline) #define APR_IMPLEMENT_EXTERNAL_HOOK_RUN_FIRST group___a_p_r___util___hook.html ga14 (ns, link, ret, name, args_decl, args_use, decline) #define APR_HOOK_REALLY_FIRST group___a_p_r___util___hook.html ga15 #define APR_HOOK_FIRST group___a_p_r___util___hook.html ga16 #define APR_HOOK_MIDDLE group___a_p_r___util___hook.html ga17 #define APR_HOOK_LAST group___a_p_r___util___hook.html ga18 #define APR_HOOK_REALLY_LAST group___a_p_r___util___hook.html ga19 void apr_hook_sort_register group___a_p_r___util___hook.html ga3 (const char *szHookName, apr_array_header_t **aHooks) void apr_hook_sort_all group___a_p_r___util___hook.html ga4 (void) void apr_hook_debug_show group___a_p_r___util___hook.html ga5 (const char *szName, const char *const *aszPre, const char *const *aszSucc) void apr_hook_deregister_all group___a_p_r___util___hook.html ga6 (void) apr_pool_t * apr_hook_global_pool group___a_p_r___util___hook.html ga0 int apr_hook_debug_enabled group___a_p_r___util___hook.html ga1 const char * apr_hook_debug_current group___a_p_r___util___hook.html ga2 apr_ldap.h /home/joe/src/apache/apr/apr-util/trunk/include/ apr__ldap_8h #define APR_HAS_LDAP group___a_p_r___util___l_d_a_p.html ga0 #define APR_HAS_NETSCAPE_LDAPSDK group___a_p_r___util___l_d_a_p.html ga1 #define APR_HAS_NOVELL_LDAPSDK group___a_p_r___util___l_d_a_p.html ga2 #define APR_HAS_OPENLDAP_LDAPSDK group___a_p_r___util___l_d_a_p.html ga3 #define APR_HAS_MICROSOFT_LDAPSDK group___a_p_r___util___l_d_a_p.html ga4 #define APR_HAS_OTHER_LDAPSDK group___a_p_r___util___l_d_a_p.html ga5 #define APR_HAS_LDAP_SSL group___a_p_r___util___l_d_a_p.html ga6 #define APR_HAS_LDAP_URL_PARSE group___a_p_r___util___l_d_a_p.html ga7 apr_ldap_init.h /home/joe/src/apache/apr/apr-util/trunk/include/ apr__ldap__init_8h apr_ldap.h apr_ldap_option.h /home/joe/src/apache/apr/apr-util/trunk/include/ apr__ldap__option_8h apr_ldap.h apr_ldap_url.h /home/joe/src/apache/apr/apr-util/trunk/include/ apr__ldap__url_8h apr_md4.h /home/joe/src/apache/apr/apr-util/trunk/include/ apr__md4_8h apr_xlate.h #define APR_MD4_DIGESTSIZE group___a_p_r___util___m_d4.html ga6 apr_md4_ctx_t apr_md4_ctx_t group___a_p_r___util___m_d4.html ga0 apr_status_t apr_md4_init group___a_p_r___util___m_d4.html ga1 (apr_md4_ctx_t *context) apr_status_t apr_md4_set_xlate group___a_p_r___util___m_d4.html ga2 (apr_md4_ctx_t *context, apr_xlate_t *xlate) apr_status_t apr_md4_update group___a_p_r___util___m_d4.html ga3 (apr_md4_ctx_t *context, const unsigned char *input, apr_size_t inputLen) apr_status_t apr_md4_final group___a_p_r___util___m_d4.html ga4 (unsigned char digest[APR_MD4_DIGESTSIZE], apr_md4_ctx_t *context) apr_status_t apr_md4 group___a_p_r___util___m_d4.html ga5 (unsigned char digest[APR_MD4_DIGESTSIZE], const unsigned char *input, apr_size_t inputLen) apr_md5.h /home/joe/src/apache/apr/apr-util/trunk/include/ apr__md5_8h apr_xlate.h #define APR_MD5_DIGESTSIZE group___a_p_r___m_d5.html ga8 apr_md5_ctx_t apr_md5_ctx_t group___a_p_r___m_d5.html ga0 apr_status_t apr_md5_init group___a_p_r___m_d5.html ga1 (apr_md5_ctx_t *context) apr_status_t apr_md5_set_xlate group___a_p_r___m_d5.html ga2 (apr_md5_ctx_t *context, apr_xlate_t *xlate) apr_status_t apr_md5_update group___a_p_r___m_d5.html ga3 (apr_md5_ctx_t *context, const void *input, apr_size_t inputLen) apr_status_t apr_md5_final group___a_p_r___m_d5.html ga4 (unsigned char digest[APR_MD5_DIGESTSIZE], apr_md5_ctx_t *context) apr_status_t apr_md5 group___a_p_r___m_d5.html ga5 (unsigned char digest[APR_MD5_DIGESTSIZE], const void *input, apr_size_t inputLen) apr_status_t apr_md5_encode group___a_p_r___m_d5.html ga6 (const char *password, const char *salt, char *result, apr_size_t nbytes) apr_status_t apr_password_validate group___a_p_r___m_d5.html ga7 (const char *passwd, const char *hash) apr_optional.h /home/joe/src/apache/apr/apr-util/trunk/include/ apr__optional_8h #define APR_OPTIONAL_FN_TYPE group___a_p_r___util___opt.html ga3 (name) #define APR_DECLARE_OPTIONAL_FN group___a_p_r___util___opt.html ga4 (ret, name, args) #define APR_REGISTER_OPTIONAL_FN group___a_p_r___util___opt.html ga5 (name) #define APR_RETRIEVE_OPTIONAL_FN group___a_p_r___util___opt.html ga6 (name) void( apr_opt_fn_t group___a_p_r___util___opt.html ga0 )(void) void apr_dynamic_fn_register group___a_p_r___util___opt.html ga1 (const char *szName, apr_opt_fn_t *pfn) apr_opt_fn_t * apr_dynamic_fn_retrieve group___a_p_r___util___opt.html ga2 (const char *szName) apr_optional_hooks.h /home/joe/src/apache/apr/apr-util/trunk/include/ apr__optional__hooks_8h #define APR_OPTIONAL_HOOK group___a_p_r___util___o_p_t___h_o_o_k.html ga2 (ns, name, pfn, aszPre, aszSucc, nOrder) #define APR_IMPLEMENT_OPTIONAL_HOOK_RUN_ALL group___a_p_r___util___o_p_t___h_o_o_k.html ga3 (ns, link, ret, name, args_decl, args_use, ok, decline) void apr_optional_hook_add group___a_p_r___util___o_p_t___h_o_o_k.html ga0 (const char *szName, void(*pfn)(void), const char *const *aszPre, const char *const *aszSucc, int nOrder) apr_array_header_t * apr_optional_hook_get group___a_p_r___util___o_p_t___h_o_o_k.html ga1 (const char *szName) apr_queue.h /home/joe/src/apache/apr/apr-util/trunk/include/ apr__queue_8h apr_queue_t apr_queue_t group___a_p_r___util___f_i_f_o.html ga0 apr_status_t apr_queue_create group___a_p_r___util___f_i_f_o.html ga1 (apr_queue_t **queue, unsigned int queue_capacity, apr_pool_t *a) apr_status_t apr_queue_push group___a_p_r___util___f_i_f_o.html ga2 (apr_queue_t *queue, void *data) apr_status_t apr_queue_pop group___a_p_r___util___f_i_f_o.html ga3 (apr_queue_t *queue, void **data) apr_status_t apr_queue_trypush group___a_p_r___util___f_i_f_o.html ga4 (apr_queue_t *queue, void *data) apr_status_t apr_queue_trypop group___a_p_r___util___f_i_f_o.html ga5 (apr_queue_t *queue, void **data) unsigned int apr_queue_size group___a_p_r___util___f_i_f_o.html ga6 (apr_queue_t *queue) apr_status_t apr_queue_interrupt_all group___a_p_r___util___f_i_f_o.html ga7 (apr_queue_t *queue) apr_status_t apr_queue_term group___a_p_r___util___f_i_f_o.html ga8 (apr_queue_t *queue) apr_reslist.h /home/joe/src/apache/apr/apr-util/trunk/include/ apr__reslist_8h apr_reslist_t apr_reslist_t group___a_p_r___util___r_l.html ga0 apr_status_t(* apr_reslist_constructor group___a_p_r___util___r_l.html ga1 )(void **resource, void *params, apr_pool_t *pool) apr_status_t(* apr_reslist_destructor group___a_p_r___util___r_l.html ga2 )(void *resource, void *params, apr_pool_t *pool) apr_status_t apr_reslist_create group___a_p_r___util___r_l.html ga3 (apr_reslist_t **reslist, int min, int smax, int hmax, apr_interval_time_t ttl, apr_reslist_constructor con, apr_reslist_destructor de, void *params, apr_pool_t *pool) apr_status_t apr_reslist_destroy group___a_p_r___util___r_l.html ga4 (apr_reslist_t *reslist) apr_status_t apr_reslist_acquire group___a_p_r___util___r_l.html ga5 (apr_reslist_t *reslist, void **resource) apr_status_t apr_reslist_release group___a_p_r___util___r_l.html ga6 (apr_reslist_t *reslist, void *resource) void apr_reslist_timeout_set group___a_p_r___util___r_l.html ga7 (apr_reslist_t *reslist, apr_interval_time_t timeout) apr_status_t apr_reslist_invalidate group___a_p_r___util___r_l.html ga8 (apr_reslist_t *reslist, void *resource) apr_rmm.h /home/joe/src/apache/apr/apr-util/trunk/include/ apr__rmm_8h apr_anylock.h apr_rmm_t apr_rmm_t group___a_p_r___util___r_m_m.html ga0 apr_size_t apr_rmm_off_t group___a_p_r___util___r_m_m.html ga1 apr_status_t apr_rmm_init group___a_p_r___util___r_m_m.html ga2 (apr_rmm_t **rmm, apr_anylock_t *lock, void *membuf, apr_size_t memsize, apr_pool_t *cont) apr_status_t apr_rmm_destroy group___a_p_r___util___r_m_m.html ga3 (apr_rmm_t *rmm) apr_status_t apr_rmm_attach group___a_p_r___util___r_m_m.html ga4 (apr_rmm_t **rmm, apr_anylock_t *lock, void *membuf, apr_pool_t *cont) apr_status_t apr_rmm_detach group___a_p_r___util___r_m_m.html ga5 (apr_rmm_t *rmm) apr_rmm_off_t apr_rmm_malloc group___a_p_r___util___r_m_m.html ga6 (apr_rmm_t *rmm, apr_size_t reqsize) apr_rmm_off_t apr_rmm_realloc group___a_p_r___util___r_m_m.html ga7 (apr_rmm_t *rmm, void *entity, apr_size_t reqsize) apr_rmm_off_t apr_rmm_calloc group___a_p_r___util___r_m_m.html ga8 (apr_rmm_t *rmm, apr_size_t reqsize) apr_status_t apr_rmm_free group___a_p_r___util___r_m_m.html ga9 (apr_rmm_t *rmm, apr_rmm_off_t entity) void * apr_rmm_addr_get group___a_p_r___util___r_m_m.html ga10 (apr_rmm_t *rmm, apr_rmm_off_t entity) apr_rmm_off_t apr_rmm_offset_get group___a_p_r___util___r_m_m.html ga11 (apr_rmm_t *rmm, void *entity) apr_size_t apr_rmm_overhead_get group___a_p_r___util___r_m_m.html ga12 (int n) apr_sdbm.h /home/joe/src/apache/apr/apr-util/trunk/include/ apr__sdbm_8h #define APR_SDBM_DIRFEXT group___a_p_r___util___d_b_m___s_d_b_m.html ga11 #define APR_SDBM_PAGFEXT group___a_p_r___util___d_b_m___s_d_b_m.html ga12 #define APR_SDBM_INSERT group___a_p_r___util___d_b_m___s_d_b_m.html ga13 #define APR_SDBM_REPLACE group___a_p_r___util___d_b_m___s_d_b_m.html ga14 #define APR_SDBM_INSERTDUP group___a_p_r___util___d_b_m___s_d_b_m.html ga15 apr_sdbm_t apr_sdbm_t group___a_p_r___util___d_b_m___s_d_b_m.html ga0 apr_status_t apr_sdbm_open group___a_p_r___util___d_b_m___s_d_b_m.html ga1 (apr_sdbm_t **db, const char *name, apr_int32_t mode, apr_fileperms_t perms, apr_pool_t *p) apr_status_t apr_sdbm_close group___a_p_r___util___d_b_m___s_d_b_m.html ga2 (apr_sdbm_t *db) apr_status_t apr_sdbm_lock group___a_p_r___util___d_b_m___s_d_b_m.html ga3 (apr_sdbm_t *db, int type) apr_status_t apr_sdbm_unlock group___a_p_r___util___d_b_m___s_d_b_m.html ga4 (apr_sdbm_t *db) apr_status_t apr_sdbm_fetch group___a_p_r___util___d_b_m___s_d_b_m.html ga5 (apr_sdbm_t *db, apr_sdbm_datum_t *value, apr_sdbm_datum_t key) apr_status_t apr_sdbm_store group___a_p_r___util___d_b_m___s_d_b_m.html ga6 (apr_sdbm_t *db, apr_sdbm_datum_t key, apr_sdbm_datum_t value, int opt) apr_status_t apr_sdbm_delete group___a_p_r___util___d_b_m___s_d_b_m.html ga7 (apr_sdbm_t *db, const apr_sdbm_datum_t key) apr_status_t apr_sdbm_firstkey group___a_p_r___util___d_b_m___s_d_b_m.html ga8 (apr_sdbm_t *db, apr_sdbm_datum_t *key) apr_status_t apr_sdbm_nextkey group___a_p_r___util___d_b_m___s_d_b_m.html ga9 (apr_sdbm_t *db, apr_sdbm_datum_t *key) int apr_sdbm_rdonly group___a_p_r___util___d_b_m___s_d_b_m.html ga10 (apr_sdbm_t *db) apr_sha1.h /home/joe/src/apache/apr/apr-util/trunk/include/ apr__sha1_8h #define APR_SHA1_DIGESTSIZE apr__sha1_8h.html a0 #define APR_SHA1PW_ID apr__sha1_8h.html a1 #define APR_SHA1PW_IDLEN apr__sha1_8h.html a2 apr_sha1_ctx_t apr_sha1_ctx_t apr__sha1_8h.html a3 void apr_sha1_base64 apr__sha1_8h.html a4 (const char *clear, int len, char *out) void apr_sha1_init apr__sha1_8h.html a5 (apr_sha1_ctx_t *context) void apr_sha1_update apr__sha1_8h.html a6 (apr_sha1_ctx_t *context, const char *input, unsigned int inputLen) void apr_sha1_update_binary apr__sha1_8h.html a7 (apr_sha1_ctx_t *context, const unsigned char *input, unsigned int inputLen) void apr_sha1_final apr__sha1_8h.html a8 (unsigned char digest[APR_SHA1_DIGESTSIZE], apr_sha1_ctx_t *context) apr_strmatch.h /home/joe/src/apache/apr/apr-util/trunk/include/ apr__strmatch_8h apr_strmatch_pattern apr_strmatch_pattern group___a_p_r___util___str_match.html ga0 const char * apr_strmatch group___a_p_r___util___str_match.html ga1 (const apr_strmatch_pattern *pattern, const char *s, apr_size_t slen) const apr_strmatch_pattern * apr_strmatch_precompile group___a_p_r___util___str_match.html ga2 (apr_pool_t *p, const char *s, int case_sensitive) apr_uri.h /home/joe/src/apache/apr/apr-util/trunk/include/ apr__uri_8h #define APR_URI_FTP_DEFAULT_PORT group___a_p_r___util___u_r_i.html ga5 #define APR_URI_SSH_DEFAULT_PORT group___a_p_r___util___u_r_i.html ga6 #define APR_URI_TELNET_DEFAULT_PORT group___a_p_r___util___u_r_i.html ga7 #define APR_URI_GOPHER_DEFAULT_PORT group___a_p_r___util___u_r_i.html ga8 #define APR_URI_HTTP_DEFAULT_PORT group___a_p_r___util___u_r_i.html ga9 #define APR_URI_POP_DEFAULT_PORT group___a_p_r___util___u_r_i.html ga10 #define APR_URI_NNTP_DEFAULT_PORT group___a_p_r___util___u_r_i.html ga11 #define APR_URI_IMAP_DEFAULT_PORT group___a_p_r___util___u_r_i.html ga12 #define APR_URI_PROSPERO_DEFAULT_PORT group___a_p_r___util___u_r_i.html ga13 #define APR_URI_WAIS_DEFAULT_PORT group___a_p_r___util___u_r_i.html ga14 #define APR_URI_LDAP_DEFAULT_PORT group___a_p_r___util___u_r_i.html ga15 #define APR_URI_HTTPS_DEFAULT_PORT group___a_p_r___util___u_r_i.html ga16 #define APR_URI_RTSP_DEFAULT_PORT group___a_p_r___util___u_r_i.html ga17 #define APR_URI_SNEWS_DEFAULT_PORT group___a_p_r___util___u_r_i.html ga18 #define APR_URI_ACAP_DEFAULT_PORT group___a_p_r___util___u_r_i.html ga19 #define APR_URI_NFS_DEFAULT_PORT group___a_p_r___util___u_r_i.html ga20 #define APR_URI_TIP_DEFAULT_PORT group___a_p_r___util___u_r_i.html ga21 #define APR_URI_SIP_DEFAULT_PORT group___a_p_r___util___u_r_i.html ga22 #define APR_URI_UNP_OMITSITEPART group___a_p_r___util___u_r_i.html ga23 #define APR_URI_UNP_OMITUSER group___a_p_r___util___u_r_i.html ga24 #define APR_URI_UNP_OMITPASSWORD group___a_p_r___util___u_r_i.html ga25 #define APR_URI_UNP_OMITUSERINFO group___a_p_r___util___u_r_i.html ga26 #define APR_URI_UNP_REVEALPASSWORD group___a_p_r___util___u_r_i.html ga27 #define APR_URI_UNP_OMITPATHINFO group___a_p_r___util___u_r_i.html ga28 #define APR_URI_UNP_OMITQUERY group___a_p_r___util___u_r_i.html ga29 apr_uri_t apr_uri_t group___a_p_r___util___u_r_i.html ga0 apr_port_t apr_uri_port_of_scheme group___a_p_r___util___u_r_i.html ga1 (const char *scheme_str) char * apr_uri_unparse group___a_p_r___util___u_r_i.html ga2 (apr_pool_t *p, const apr_uri_t *uptr, unsigned flags) int apr_uri_parse group___a_p_r___util___u_r_i.html ga3 (apr_pool_t *p, const char *uri, apr_uri_t *uptr) int apr_uri_parse_hostinfo group___a_p_r___util___u_r_i.html ga4 (apr_pool_t *p, const char *hostinfo, apr_uri_t *uptr) apr_uuid.h /home/joe/src/apache/apr/apr-util/trunk/include/ apr__uuid_8h #define APR_UUID_FORMATTED_LENGTH group___a_p_r___u_u_i_d.html ga3 void apr_uuid_get group___a_p_r___u_u_i_d.html ga0 (apr_uuid_t *uuid) void apr_uuid_format group___a_p_r___u_u_i_d.html ga1 (char *buffer, const apr_uuid_t *uuid) apr_status_t apr_uuid_parse group___a_p_r___u_u_i_d.html ga2 (apr_uuid_t *uuid, const char *uuid_str) apr_xlate.h /home/joe/src/apache/apr/apr-util/trunk/include/ apr__xlate_8h #define APR_DEFAULT_CHARSET group___a_p_r___x_l_a_t_e.html ga6 #define APR_LOCALE_CHARSET group___a_p_r___x_l_a_t_e.html ga7 apr_xlate_t apr_xlate_t group___a_p_r___x_l_a_t_e.html ga0 apr_status_t apr_xlate_open group___a_p_r___x_l_a_t_e.html ga1 (apr_xlate_t **convset, const char *topage, const char *frompage, apr_pool_t *pool) apr_status_t apr_xlate_sb_get group___a_p_r___x_l_a_t_e.html ga2 (apr_xlate_t *convset, int *onoff) apr_status_t apr_xlate_conv_buffer group___a_p_r___x_l_a_t_e.html ga3 (apr_xlate_t *convset, const char *inbuf, apr_size_t *inbytes_left, char *outbuf, apr_size_t *outbytes_left) apr_int32_t apr_xlate_conv_byte group___a_p_r___x_l_a_t_e.html ga4 (apr_xlate_t *convset, unsigned char inchar) apr_status_t apr_xlate_close group___a_p_r___x_l_a_t_e.html ga5 (apr_xlate_t *convset) apr_xml.h /home/joe/src/apache/apr/apr-util/trunk/include/ apr__xml_8h Apache #define APR_XML_NS_DAV_ID group___a_p_r___util___x_m_l.html ga17 #define APR_XML_NS_NONE group___a_p_r___util___x_m_l.html ga18 #define APR_XML_NS_ERROR_BASE group___a_p_r___util___x_m_l.html ga19 #define APR_XML_NS_IS_ERROR group___a_p_r___util___x_m_l.html ga20 (e) #define APR_XML_ELEM_IS_EMPTY group___a_p_r___util___x_m_l.html ga21 (e) #define APR_XML_X2T_FULL group___a_p_r___util___x_m_l.html ga22 #define APR_XML_X2T_INNER group___a_p_r___util___x_m_l.html ga23 #define APR_XML_X2T_LANG_INNER group___a_p_r___util___x_m_l.html ga24 #define APR_XML_X2T_FULL_NS_LANG group___a_p_r___util___x_m_l.html ga25 #define APR_XML_GET_URI_ITEM group___a_p_r___util___x_m_l.html ga26 (ary, i) apr_text apr_text group___a_p_r___util___x_m_l.html ga0 apr_text_header apr_text_header group___a_p_r___util___x_m_l.html ga1 apr_xml_attr apr_xml_attr group___a_p_r___util___x_m_l.html ga2 apr_xml_elem apr_xml_elem group___a_p_r___util___x_m_l.html ga3 apr_xml_doc apr_xml_doc group___a_p_r___util___x_m_l.html ga4 apr_xml_parser apr_xml_parser group___a_p_r___util___x_m_l.html ga5 void apr_text_append group___a_p_r___util___x_m_l.html ga6 (apr_pool_t *p, apr_text_header *hdr, const char *text) apr_xml_parser * apr_xml_parser_create group___a_p_r___util___x_m_l.html ga7 (apr_pool_t *pool) apr_status_t apr_xml_parse_file group___a_p_r___util___x_m_l.html ga8 (apr_pool_t *p, apr_xml_parser **parser, apr_xml_doc **ppdoc, apr_file_t *xmlfd, apr_size_t buffer_length) apr_status_t apr_xml_parser_feed group___a_p_r___util___x_m_l.html ga9 (apr_xml_parser *parser, const char *data, apr_size_t len) apr_status_t apr_xml_parser_done group___a_p_r___util___x_m_l.html ga10 (apr_xml_parser *parser, apr_xml_doc **pdoc) char * apr_xml_parser_geterror group___a_p_r___util___x_m_l.html ga11 (apr_xml_parser *parser, char *errbuf, apr_size_t errbufsize) void apr_xml_to_text group___a_p_r___util___x_m_l.html ga12 (apr_pool_t *p, const apr_xml_elem *elem, int style, apr_array_header_t *namespaces, int *ns_map, const char **pbuf, apr_size_t *psize) const char * apr_xml_empty_elem group___a_p_r___util___x_m_l.html ga13 (apr_pool_t *p, const apr_xml_elem *elem) const char * apr_xml_quote_string group___a_p_r___util___x_m_l.html ga14 (apr_pool_t *p, const char *s, int quotes) void apr_xml_quote_elem group___a_p_r___util___x_m_l.html ga15 (apr_pool_t *p, apr_xml_elem *elem) int apr_xml_insert_uri group___a_p_r___util___x_m_l.html ga16 (apr_array_header_t *uri_array, const char *uri) apu_version.h /home/joe/src/apache/apr/apr-util/trunk/include/ apu__version_8h #define APU_MAJOR_VERSION apu__version_8h.html a0 #define APU_MINOR_VERSION apu__version_8h.html a1 #define APU_PATCH_VERSION apu__version_8h.html a2 #define APU_IS_DEV_VERSION apu__version_8h.html a3 #define APU_VERSION_STRING apu__version_8h.html a4 #define APU_IS_DEV_STRING apu__version_8h.html a5 void apu_version apu__version_8h.html a6 (apr_version_t *pvsn) const char * apu_version_string apu__version_8h.html a7 (void) apu_want.h /home/joe/src/apache/apr/apr-util/trunk/include/ apu__want_8h apr_anylock_t structapr__anylock__t.html tm_lock w5 apr_anylock_none w5w0 apr_anylock_procmutex w5w1 apr_anylock_threadmutex w5w2 apr_anylock_readlock w5w3 apr_anylock_writelock w5w4 enum apr_anylock_t::tm_lock type structapr__anylock__t.html o0 apr_anylock_t::apr_anylock_u_t lock structapr__anylock__t.html o1 apr_anylock_t::apr_anylock_u_t apr_anylock_t::apr_anylock_u_t unionapr__anylock__t_1_1apr__anylock__u__t.html apr_proc_mutex_t * pm unionapr__anylock__t_1_1apr__anylock__u__t.html o0 apr_thread_mutex_t * tm unionapr__anylock__t_1_1apr__anylock__u__t.html o1 apr_thread_rwlock_t * rw unionapr__anylock__t_1_1apr__anylock__u__t.html o2 apr_bucket structapr__bucket.html APR_RING_ENTRY structapr__bucket.html a0 (apr_bucket) link const apr_bucket_type_t * type structapr__bucket.html o0 apr_size_t length structapr__bucket.html o1 apr_off_t start structapr__bucket.html o2 void * data structapr__bucket.html o3 void(* free structapr__bucket.html o4 )(void *e) apr_bucket_alloc_t * list structapr__bucket.html o5 apr_bucket_brigade structapr__bucket__brigade.html APR_RING_HEAD structapr__bucket__brigade.html a0 (apr_bucket_list, apr_bucket) list apr_pool_t * p structapr__bucket__brigade.html o0 apr_bucket_alloc_t * bucket_alloc structapr__bucket__brigade.html o1 apr_bucket_file structapr__bucket__file.html apr_bucket_refcount refcount structapr__bucket__file.html o0 apr_file_t * fd structapr__bucket__file.html o1 apr_pool_t * readpool structapr__bucket__file.html o2 int can_mmap structapr__bucket__file.html o3 apr_bucket_heap structapr__bucket__heap.html apr_bucket_refcount refcount structapr__bucket__heap.html o0 char * base structapr__bucket__heap.html o1 apr_size_t alloc_len structapr__bucket__heap.html o2 void(* free_func structapr__bucket__heap.html o3 )(void *data) apr_bucket_mmap structapr__bucket__mmap.html apr_bucket_refcount refcount structapr__bucket__mmap.html o0 apr_mmap_t * mmap structapr__bucket__mmap.html o1 apr_bucket_pool structapr__bucket__pool.html apr_bucket_heap heap structapr__bucket__pool.html o0 const char * base structapr__bucket__pool.html o1 apr_pool_t * pool structapr__bucket__pool.html o2 apr_bucket_alloc_t * list structapr__bucket__pool.html o3 apr_bucket_refcount structapr__bucket__refcount.html int refcount structapr__bucket__refcount.html o0 apr_bucket_structs unionapr__bucket__structs.html apr_bucket b unionapr__bucket__structs.html o0 apr_bucket_heap heap unionapr__bucket__structs.html o1 apr_bucket_pool pool unionapr__bucket__structs.html o2 apr_bucket_mmap mmap unionapr__bucket__structs.html o3 apr_bucket_file file unionapr__bucket__structs.html o4 apr_bucket_type_t structapr__bucket__type__t.html APR_BUCKET_DATA w2w0 APR_BUCKET_METADATA w2w1 const char * name structapr__bucket__type__t.html o0 int num_func structapr__bucket__type__t.html o1 enum apr_bucket_type_t::@2 is_metadata structapr__bucket__type__t.html o2 void(* destroy structapr__bucket__type__t.html o3 )(void *data) apr_status_t(* read structapr__bucket__type__t.html o4 )(apr_bucket *b, const char **str, apr_size_t *len, apr_read_type_e block) apr_status_t(* setaside structapr__bucket__type__t.html o5 )(apr_bucket *e, apr_pool_t *pool) apr_status_t(* split structapr__bucket__type__t.html o6 )(apr_bucket *e, apr_size_t point) apr_status_t(* copy structapr__bucket__type__t.html o7 )(apr_bucket *e, apr_bucket **c) apr_datum_t structapr__datum__t.html char * dptr structapr__datum__t.html o0 apr_size_t dsize structapr__datum__t.html o1 apr_dbm_t structapr__dbm__t.html apr_pool_t * pool structapr__dbm__t.html o0 void * file structapr__dbm__t.html o1 int errcode structapr__dbm__t.html o2 const char * errmsg structapr__dbm__t.html o3 const apr_dbm_type_t * type structapr__dbm__t.html o4 apr_dbm_type_t structapr__dbm__type__t.html const char * name structapr__dbm__type__t.html o0 apr_status_t(* open structapr__dbm__type__t.html o1 )(apr_dbm_t **pdb, const char *pathname, apr_int32_t mode, apr_fileperms_t perm, apr_pool_t *pool) void(* close structapr__dbm__type__t.html o2 )(apr_dbm_t *dbm) apr_status_t(* fetch structapr__dbm__type__t.html o3 )(apr_dbm_t *dbm, apr_datum_t key, apr_datum_t *pvalue) apr_status_t(* store structapr__dbm__type__t.html o4 )(apr_dbm_t *dbm, apr_datum_t key, apr_datum_t value) apr_status_t(* del structapr__dbm__type__t.html o5 )(apr_dbm_t *dbm, apr_datum_t key) int(* exists structapr__dbm__type__t.html o6 )(apr_dbm_t *dbm, apr_datum_t key) apr_status_t(* firstkey structapr__dbm__type__t.html o7 )(apr_dbm_t *dbm, apr_datum_t *pkey) apr_status_t(* nextkey structapr__dbm__type__t.html o8 )(apr_dbm_t *dbm, apr_datum_t *pkey) void(* freedatum structapr__dbm__type__t.html o9 )(apr_dbm_t *dbm, apr_datum_t data) void(* getusednames structapr__dbm__type__t.html o10 )(apr_pool_t *pool, const char *pathname, const char **used1, const char **used2) apr_md4_ctx_t structapr__md4__ctx__t.html apr_uint32_t state structapr__md4__ctx__t.html o0 [4] apr_uint32_t count structapr__md4__ctx__t.html o1 [2] unsigned char buffer structapr__md4__ctx__t.html o2 [64] apr_xlate_t * xlate structapr__md4__ctx__t.html o3 apr_md5_ctx_t structapr__md5__ctx__t.html apr_uint32_t state structapr__md5__ctx__t.html o0 [4] apr_uint32_t count structapr__md5__ctx__t.html o1 [2] unsigned char buffer structapr__md5__ctx__t.html o2 [64] apr_xlate_t * xlate structapr__md5__ctx__t.html o3 apr_sdbm_datum_t structapr__sdbm__datum__t.html char * dptr structapr__sdbm__datum__t.html o0 int dsize structapr__sdbm__datum__t.html o1 apr_sha1_ctx_t structapr__sha1__ctx__t.html apr_uint32_t digest structapr__sha1__ctx__t.html o0 [5] apr_uint32_t count_lo structapr__sha1__ctx__t.html o1 apr_uint32_t count_hi structapr__sha1__ctx__t.html o2 apr_uint32_t data structapr__sha1__ctx__t.html o3 [16] int local structapr__sha1__ctx__t.html o4 apr_strmatch_pattern structapr__strmatch__pattern.html const char *(* compare structapr__strmatch__pattern.html o0 )(const apr_strmatch_pattern *this_pattern, const char *s, apr_size_t slen) const char * pattern structapr__strmatch__pattern.html o1 apr_size_t length structapr__strmatch__pattern.html o2 void * context structapr__strmatch__pattern.html o3 apr_text structapr__text.html const char * text structapr__text.html o0 apr_text * next structapr__text.html o1 apr_text_header structapr__text__header.html apr_text * first structapr__text__header.html o0 apr_text * last structapr__text__header.html o1 apr_uri_t structapr__uri__t.html char * scheme structapr__uri__t.html o0 char * hostinfo structapr__uri__t.html o1 char * user structapr__uri__t.html o2 char * password structapr__uri__t.html o3 char * hostname structapr__uri__t.html o4 char * port_str structapr__uri__t.html o5 char * path structapr__uri__t.html o6 char * query structapr__uri__t.html o7 char * fragment structapr__uri__t.html o8 hostent * hostent structapr__uri__t.html o9 apr_port_t port structapr__uri__t.html o10 unsigned is_initialized structapr__uri__t.html o11 unsigned dns_looked_up structapr__uri__t.html o12 unsigned dns_resolved structapr__uri__t.html o13 apr_uuid_t structapr__uuid__t.html unsigned char data structapr__uuid__t.html o0 [16] apr_xml_attr structapr__xml__attr.html const char * name structapr__xml__attr.html o0 int ns structapr__xml__attr.html o1 const char * value structapr__xml__attr.html o2 apr_xml_attr * next structapr__xml__attr.html o3 apr_xml_doc structapr__xml__doc.html apr_xml_elem * root structapr__xml__doc.html o0 apr_array_header_t * namespaces structapr__xml__doc.html o1 apr_xml_elem structapr__xml__elem.html const char * name structapr__xml__elem.html o0 int ns structapr__xml__elem.html o1 const char * lang structapr__xml__elem.html o2 apr_text_header first_cdata structapr__xml__elem.html o3 apr_text_header following_cdata structapr__xml__elem.html o4 apr_xml_elem * parent structapr__xml__elem.html o5 apr_xml_elem * next structapr__xml__elem.html o6 apr_xml_elem * first_child structapr__xml__elem.html o7 apr_xml_attr * attr structapr__xml__elem.html o8 apr_xml_elem * last_child structapr__xml__elem.html o9 apr_xml_ns_scope * ns_scope structapr__xml__elem.html o10 void * priv structapr__xml__elem.html o11 APR_Util_Base64 Base64 Encoding group___a_p_r___util___base64.html int apr_base64_encode_len group___a_p_r___util___base64.html ga0 (int len) int apr_base64_encode group___a_p_r___util___base64.html ga1 (char *coded_dst, const char *plain_src, int len_plain_src) int apr_base64_encode_binary group___a_p_r___util___base64.html ga2 (char *coded_dst, const unsigned char *plain_src, int len_plain_src) int apr_base64_decode_len group___a_p_r___util___base64.html ga3 (const char *coded_src) int apr_base64_decode group___a_p_r___util___base64.html ga4 (char *plain_dst, const char *coded_src) int apr_base64_decode_binary group___a_p_r___util___base64.html ga5 (unsigned char *plain_dst, const char *coded_src) APR_Util_Bucket_Brigades Bucket Brigades group___a_p_r___util___bucket___brigades.html apr_bucket_type_t apr_bucket apr_bucket_brigade apr_bucket_refcount apr_bucket_heap apr_bucket_pool apr_bucket_mmap apr_bucket_file apr_bucket_structs #define APR_BUCKET_BUFF_SIZE group___a_p_r___util___bucket___brigades.html ga77 #define APR_BRIGADE_CHECK_CONSISTENCY group___a_p_r___util___bucket___brigades.html ga78 (b) #define APR_BUCKET_CHECK_CONSISTENCY group___a_p_r___util___bucket___brigades.html ga79 (e) #define APR_BRIGADE_SENTINEL group___a_p_r___util___bucket___brigades.html ga80 (b) #define APR_BRIGADE_EMPTY group___a_p_r___util___bucket___brigades.html ga81 (b) #define APR_BRIGADE_FIRST group___a_p_r___util___bucket___brigades.html ga82 (b) #define APR_BRIGADE_LAST group___a_p_r___util___bucket___brigades.html ga83 (b) #define APR_BRIGADE_INSERT_HEAD group___a_p_r___util___bucket___brigades.html ga84 (b, e) #define APR_BRIGADE_INSERT_TAIL group___a_p_r___util___bucket___brigades.html ga85 (b, e) #define APR_BRIGADE_CONCAT group___a_p_r___util___bucket___brigades.html ga86 (a, b) #define APR_BRIGADE_PREPEND group___a_p_r___util___bucket___brigades.html ga87 (a, b) #define APR_BUCKET_INSERT_BEFORE group___a_p_r___util___bucket___brigades.html ga88 (a, b) #define APR_BUCKET_INSERT_AFTER group___a_p_r___util___bucket___brigades.html ga89 (a, b) #define APR_BUCKET_NEXT group___a_p_r___util___bucket___brigades.html ga90 (e) #define APR_BUCKET_PREV group___a_p_r___util___bucket___brigades.html ga91 (e) #define APR_BUCKET_REMOVE group___a_p_r___util___bucket___brigades.html ga92 (e) #define APR_BUCKET_INIT group___a_p_r___util___bucket___brigades.html ga93 (e) #define APR_BUCKET_IS_METADATA group___a_p_r___util___bucket___brigades.html ga94 (e) #define APR_BUCKET_IS_FLUSH group___a_p_r___util___bucket___brigades.html ga95 (e) #define APR_BUCKET_IS_EOS group___a_p_r___util___bucket___brigades.html ga96 (e) #define APR_BUCKET_IS_FILE group___a_p_r___util___bucket___brigades.html ga97 (e) #define APR_BUCKET_IS_PIPE group___a_p_r___util___bucket___brigades.html ga98 (e) #define APR_BUCKET_IS_SOCKET group___a_p_r___util___bucket___brigades.html ga99 (e) #define APR_BUCKET_IS_HEAP group___a_p_r___util___bucket___brigades.html ga100 (e) #define APR_BUCKET_IS_TRANSIENT group___a_p_r___util___bucket___brigades.html ga101 (e) #define APR_BUCKET_IS_IMMORTAL group___a_p_r___util___bucket___brigades.html ga102 (e) #define APR_BUCKET_IS_MMAP group___a_p_r___util___bucket___brigades.html ga103 (e) #define APR_BUCKET_IS_POOL group___a_p_r___util___bucket___brigades.html ga104 (e) #define APR_BUCKET_ALLOC_SIZE group___a_p_r___util___bucket___brigades.html ga105 #define apr_bucket_destroy group___a_p_r___util___bucket___brigades.html ga106 (e) #define apr_bucket_delete group___a_p_r___util___bucket___brigades.html ga107 (e) #define apr_bucket_read group___a_p_r___util___bucket___brigades.html ga108 (e, str, len, block) #define apr_bucket_setaside group___a_p_r___util___bucket___brigades.html ga109 (e, p) #define apr_bucket_split group___a_p_r___util___bucket___brigades.html ga110 (e, point) #define apr_bucket_copy group___a_p_r___util___bucket___brigades.html ga111 (e, c) apr_bucket_brigade apr_bucket_brigade group___a_p_r___util___bucket___brigades.html ga0 apr_bucket apr_bucket group___a_p_r___util___bucket___brigades.html ga1 apr_bucket_alloc_t apr_bucket_alloc_t group___a_p_r___util___bucket___brigades.html ga2 apr_bucket_type_t apr_bucket_type_t group___a_p_r___util___bucket___brigades.html ga3 apr_status_t(* apr_brigade_flush group___a_p_r___util___bucket___brigades.html ga4 )(apr_bucket_brigade *bb, void *ctx) apr_bucket_refcount apr_bucket_refcount group___a_p_r___util___bucket___brigades.html ga5 apr_bucket_heap apr_bucket_heap group___a_p_r___util___bucket___brigades.html ga6 apr_bucket_pool apr_bucket_pool group___a_p_r___util___bucket___brigades.html ga7 apr_bucket_mmap apr_bucket_mmap group___a_p_r___util___bucket___brigades.html ga8 apr_bucket_file apr_bucket_file group___a_p_r___util___bucket___brigades.html ga9 apr_bucket_structs apr_bucket_structs group___a_p_r___util___bucket___brigades.html ga10 apr_read_type_e ga112 APR_BLOCK_READ gga112a56 APR_NONBLOCK_READ gga112a57 apr_bucket_brigade * apr_brigade_create group___a_p_r___util___bucket___brigades.html ga21 (apr_pool_t *p, apr_bucket_alloc_t *list) apr_status_t apr_brigade_destroy group___a_p_r___util___bucket___brigades.html ga22 (apr_bucket_brigade *b) apr_status_t apr_brigade_cleanup group___a_p_r___util___bucket___brigades.html ga23 (void *data) apr_bucket_brigade * apr_brigade_split group___a_p_r___util___bucket___brigades.html ga24 (apr_bucket_brigade *b, apr_bucket *e) apr_status_t apr_brigade_partition group___a_p_r___util___bucket___brigades.html ga25 (apr_bucket_brigade *b, apr_off_t point, apr_bucket **after_point) apr_status_t apr_brigade_length group___a_p_r___util___bucket___brigades.html ga26 (apr_bucket_brigade *bb, int read_all, apr_off_t *length) apr_status_t apr_brigade_flatten group___a_p_r___util___bucket___brigades.html ga27 (apr_bucket_brigade *bb, char *c, apr_size_t *len) apr_status_t apr_brigade_pflatten group___a_p_r___util___bucket___brigades.html ga28 (apr_bucket_brigade *bb, char **c, apr_size_t *len, apr_pool_t *pool) apr_status_t apr_brigade_split_line group___a_p_r___util___bucket___brigades.html ga29 (apr_bucket_brigade *bbOut, apr_bucket_brigade *bbIn, apr_read_type_e block, apr_off_t maxbytes) apr_status_t apr_brigade_to_iovec group___a_p_r___util___bucket___brigades.html ga30 (apr_bucket_brigade *b, struct iovec *vec, int *nvec) apr_status_t apr_brigade_vputstrs group___a_p_r___util___bucket___brigades.html ga31 (apr_bucket_brigade *b, apr_brigade_flush flush, void *ctx, va_list va) apr_status_t apr_brigade_write group___a_p_r___util___bucket___brigades.html ga32 (apr_bucket_brigade *b, apr_brigade_flush flush, void *ctx, const char *str, apr_size_t nbyte) apr_status_t apr_brigade_writev group___a_p_r___util___bucket___brigades.html ga33 (apr_bucket_brigade *b, apr_brigade_flush flush, void *ctx, const struct iovec *vec, apr_size_t nvec) apr_status_t apr_brigade_puts group___a_p_r___util___bucket___brigades.html ga34 (apr_bucket_brigade *bb, apr_brigade_flush flush, void *ctx, const char *str) apr_status_t apr_brigade_putc group___a_p_r___util___bucket___brigades.html ga35 (apr_bucket_brigade *b, apr_brigade_flush flush, void *ctx, const char c) apr_status_t apr_brigade_putstrs group___a_p_r___util___bucket___brigades.html ga36 (apr_bucket_brigade *b, apr_brigade_flush flush, void *ctx,...) apr_status_t apr_brigade_printf group___a_p_r___util___bucket___brigades.html ga37 (apr_bucket_brigade *b, apr_brigade_flush flush, void *ctx, const char *fmt,...) apr_status_t apr_brigade_vprintf group___a_p_r___util___bucket___brigades.html ga38 (apr_bucket_brigade *b, apr_brigade_flush flush, void *ctx, const char *fmt, va_list va) apr_bucket * apr_brigade_insert_file group___a_p_r___util___bucket___brigades.html ga39 (apr_bucket_brigade *bb, apr_file_t *f, apr_off_t start, apr_off_t len, apr_pool_t *p) apr_bucket_alloc_t * apr_bucket_alloc_create group___a_p_r___util___bucket___brigades.html ga40 (apr_pool_t *p) apr_bucket_alloc_t * apr_bucket_alloc_create_ex group___a_p_r___util___bucket___brigades.html ga41 (apr_allocator_t *allocator) void apr_bucket_alloc_destroy group___a_p_r___util___bucket___brigades.html ga42 (apr_bucket_alloc_t *list) void * apr_bucket_alloc group___a_p_r___util___bucket___brigades.html ga43 (apr_size_t size, apr_bucket_alloc_t *list) void apr_bucket_free group___a_p_r___util___bucket___brigades.html ga44 (void *block) apr_status_t apr_bucket_setaside_noop group___a_p_r___util___bucket___brigades.html ga45 (apr_bucket *data, apr_pool_t *pool) apr_status_t apr_bucket_setaside_notimpl group___a_p_r___util___bucket___brigades.html ga46 (apr_bucket *data, apr_pool_t *pool) apr_status_t apr_bucket_split_notimpl group___a_p_r___util___bucket___brigades.html ga47 (apr_bucket *data, apr_size_t point) apr_status_t apr_bucket_copy_notimpl group___a_p_r___util___bucket___brigades.html ga48 (apr_bucket *e, apr_bucket **c) void apr_bucket_destroy_noop group___a_p_r___util___bucket___brigades.html ga49 (void *data) apr_status_t apr_bucket_simple_split group___a_p_r___util___bucket___brigades.html ga50 (apr_bucket *b, apr_size_t point) apr_status_t apr_bucket_simple_copy group___a_p_r___util___bucket___brigades.html ga51 (apr_bucket *a, apr_bucket **b) apr_bucket * apr_bucket_shared_make group___a_p_r___util___bucket___brigades.html ga52 (apr_bucket *b, void *data, apr_off_t start, apr_size_t length) int apr_bucket_shared_destroy group___a_p_r___util___bucket___brigades.html ga53 (void *data) apr_status_t apr_bucket_shared_split group___a_p_r___util___bucket___brigades.html ga54 (apr_bucket *b, apr_size_t point) apr_status_t apr_bucket_shared_copy group___a_p_r___util___bucket___brigades.html ga55 (apr_bucket *a, apr_bucket **b) apr_bucket * apr_bucket_eos_create group___a_p_r___util___bucket___brigades.html ga56 (apr_bucket_alloc_t *list) apr_bucket * apr_bucket_eos_make group___a_p_r___util___bucket___brigades.html ga57 (apr_bucket *b) apr_bucket * apr_bucket_flush_create group___a_p_r___util___bucket___brigades.html ga58 (apr_bucket_alloc_t *list) apr_bucket * apr_bucket_flush_make group___a_p_r___util___bucket___brigades.html ga59 (apr_bucket *b) apr_bucket * apr_bucket_immortal_create group___a_p_r___util___bucket___brigades.html ga60 (const char *buf, apr_size_t nbyte, apr_bucket_alloc_t *list) apr_bucket * apr_bucket_immortal_make group___a_p_r___util___bucket___brigades.html ga61 (apr_bucket *b, const char *buf, apr_size_t nbyte) apr_bucket * apr_bucket_transient_create group___a_p_r___util___bucket___brigades.html ga62 (const char *buf, apr_size_t nbyte, apr_bucket_alloc_t *list) apr_bucket * apr_bucket_transient_make group___a_p_r___util___bucket___brigades.html ga63 (apr_bucket *b, const char *buf, apr_size_t nbyte) apr_bucket * apr_bucket_heap_create group___a_p_r___util___bucket___brigades.html ga64 (const char *buf, apr_size_t nbyte, void(*free_func)(void *data), apr_bucket_alloc_t *list) apr_bucket * apr_bucket_heap_make group___a_p_r___util___bucket___brigades.html ga65 (apr_bucket *b, const char *buf, apr_size_t nbyte, void(*free_func)(void *data)) apr_bucket * apr_bucket_pool_create group___a_p_r___util___bucket___brigades.html ga66 (const char *buf, apr_size_t length, apr_pool_t *pool, apr_bucket_alloc_t *list) apr_bucket * apr_bucket_pool_make group___a_p_r___util___bucket___brigades.html ga67 (apr_bucket *b, const char *buf, apr_size_t length, apr_pool_t *pool) apr_bucket * apr_bucket_mmap_create group___a_p_r___util___bucket___brigades.html ga68 (apr_mmap_t *mm, apr_off_t start, apr_size_t length, apr_bucket_alloc_t *list) apr_bucket * apr_bucket_mmap_make group___a_p_r___util___bucket___brigades.html ga69 (apr_bucket *b, apr_mmap_t *mm, apr_off_t start, apr_size_t length) apr_bucket * apr_bucket_socket_create group___a_p_r___util___bucket___brigades.html ga70 (apr_socket_t *thissock, apr_bucket_alloc_t *list) apr_bucket * apr_bucket_socket_make group___a_p_r___util___bucket___brigades.html ga71 (apr_bucket *b, apr_socket_t *thissock) apr_bucket * apr_bucket_pipe_create group___a_p_r___util___bucket___brigades.html ga72 (apr_file_t *thispipe, apr_bucket_alloc_t *list) apr_bucket * apr_bucket_pipe_make group___a_p_r___util___bucket___brigades.html ga73 (apr_bucket *b, apr_file_t *thispipe) apr_bucket * apr_bucket_file_create group___a_p_r___util___bucket___brigades.html ga74 (apr_file_t *fd, apr_off_t offset, apr_size_t len, apr_pool_t *p, apr_bucket_alloc_t *list) apr_bucket * apr_bucket_file_make group___a_p_r___util___bucket___brigades.html ga75 (apr_bucket *b, apr_file_t *fd, apr_off_t offset, apr_size_t len, apr_pool_t *p) apr_status_t apr_bucket_file_enable_mmap group___a_p_r___util___bucket___brigades.html ga76 (apr_bucket *b, int enabled) const apr_bucket_type_t apr_bucket_type_flush group___a_p_r___util___bucket___brigades.html ga11 const apr_bucket_type_t apr_bucket_type_eos group___a_p_r___util___bucket___brigades.html ga12 const apr_bucket_type_t apr_bucket_type_file group___a_p_r___util___bucket___brigades.html ga13 const apr_bucket_type_t apr_bucket_type_heap group___a_p_r___util___bucket___brigades.html ga14 const apr_bucket_type_t apr_bucket_type_mmap group___a_p_r___util___bucket___brigades.html ga15 const apr_bucket_type_t apr_bucket_type_pool group___a_p_r___util___bucket___brigades.html ga16 const apr_bucket_type_t apr_bucket_type_pipe group___a_p_r___util___bucket___brigades.html ga17 const apr_bucket_type_t apr_bucket_type_immortal group___a_p_r___util___bucket___brigades.html ga18 const apr_bucket_type_t apr_bucket_type_transient group___a_p_r___util___bucket___brigades.html ga19 const apr_bucket_type_t apr_bucket_type_socket group___a_p_r___util___bucket___brigades.html ga20 APR_Util_Date Date routines group___a_p_r___util___date.html #define APR_DATE_BAD group___a_p_r___util___date.html ga3 int apr_date_checkmask group___a_p_r___util___date.html ga0 (const char *data, const char *mask) apr_time_t apr_date_parse_http group___a_p_r___util___date.html ga1 (const char *date) apr_time_t apr_date_parse_rfc group___a_p_r___util___date.html ga2 (const char *date) APR_Util_DBM DBM routines group___a_p_r___util___d_b_m.html APR_Util_DBM_SDBM apr_datum_t #define APR_DBM_READONLY group___a_p_r___util___d_b_m.html ga14 #define APR_DBM_READWRITE group___a_p_r___util___d_b_m.html ga15 #define APR_DBM_RWCREATE group___a_p_r___util___d_b_m.html ga16 #define APR_DBM_RWTRUNC group___a_p_r___util___d_b_m.html ga17 apr_dbm_t apr_dbm_t group___a_p_r___util___d_b_m.html ga0 apr_status_t apr_dbm_open_ex group___a_p_r___util___d_b_m.html ga1 (apr_dbm_t **dbm, const char *type, const char *name, apr_int32_t mode, apr_fileperms_t perm, apr_pool_t *cntxt) apr_status_t apr_dbm_open group___a_p_r___util___d_b_m.html ga2 (apr_dbm_t **dbm, const char *name, apr_int32_t mode, apr_fileperms_t perm, apr_pool_t *cntxt) void apr_dbm_close group___a_p_r___util___d_b_m.html ga3 (apr_dbm_t *dbm) apr_status_t apr_dbm_fetch group___a_p_r___util___d_b_m.html ga4 (apr_dbm_t *dbm, apr_datum_t key, apr_datum_t *pvalue) apr_status_t apr_dbm_store group___a_p_r___util___d_b_m.html ga5 (apr_dbm_t *dbm, apr_datum_t key, apr_datum_t value) apr_status_t apr_dbm_delete group___a_p_r___util___d_b_m.html ga6 (apr_dbm_t *dbm, apr_datum_t key) int apr_dbm_exists group___a_p_r___util___d_b_m.html ga7 (apr_dbm_t *dbm, apr_datum_t key) apr_status_t apr_dbm_firstkey group___a_p_r___util___d_b_m.html ga8 (apr_dbm_t *dbm, apr_datum_t *pkey) apr_status_t apr_dbm_nextkey group___a_p_r___util___d_b_m.html ga9 (apr_dbm_t *dbm, apr_datum_t *pkey) void apr_dbm_freedatum group___a_p_r___util___d_b_m.html ga10 (apr_dbm_t *dbm, apr_datum_t data) char * apr_dbm_geterror group___a_p_r___util___d_b_m.html ga11 (apr_dbm_t *dbm, int *errcode, char *errbuf, apr_size_t errbufsize) apr_status_t apr_dbm_get_usednames_ex group___a_p_r___util___d_b_m.html ga12 (apr_pool_t *pool, const char *type, const char *pathname, const char **used1, const char **used2) void apr_dbm_get_usednames group___a_p_r___util___d_b_m.html ga13 (apr_pool_t *pool, const char *pathname, const char **used1, const char **used2) APR_Util_Hook Hook Functions group___a_p_r___util___hook.html APR_Util_OPT_HOOK #define APR_IMPLEMENT_HOOK_GET_PROTO group___a_p_r___util___hook.html ga7 (ns, link, name) #define APR_DECLARE_EXTERNAL_HOOK group___a_p_r___util___hook.html ga8 (ns, link, ret, name, args) #define APR_HOOK_STRUCT group___a_p_r___util___hook.html ga9 (members) #define APR_HOOK_LINK group___a_p_r___util___hook.html ga10 (name) #define APR_IMPLEMENT_EXTERNAL_HOOK_BASE group___a_p_r___util___hook.html ga11 (ns, link, name) #define APR_IMPLEMENT_EXTERNAL_HOOK_VOID group___a_p_r___util___hook.html ga12 (ns, link, name, args_decl, args_use) #define APR_IMPLEMENT_EXTERNAL_HOOK_RUN_ALL group___a_p_r___util___hook.html ga13 (ns, link, ret, name, args_decl, args_use, ok, decline) #define APR_IMPLEMENT_EXTERNAL_HOOK_RUN_FIRST group___a_p_r___util___hook.html ga14 (ns, link, ret, name, args_decl, args_use, decline) #define APR_HOOK_REALLY_FIRST group___a_p_r___util___hook.html ga15 #define APR_HOOK_FIRST group___a_p_r___util___hook.html ga16 #define APR_HOOK_MIDDLE group___a_p_r___util___hook.html ga17 #define APR_HOOK_LAST group___a_p_r___util___hook.html ga18 #define APR_HOOK_REALLY_LAST group___a_p_r___util___hook.html ga19 void apr_hook_sort_register group___a_p_r___util___hook.html ga3 (const char *szHookName, apr_array_header_t **aHooks) void apr_hook_sort_all group___a_p_r___util___hook.html ga4 (void) void apr_hook_debug_show group___a_p_r___util___hook.html ga5 (const char *szName, const char *const *aszPre, const char *const *aszSucc) void apr_hook_deregister_all group___a_p_r___util___hook.html ga6 (void) apr_pool_t * apr_hook_global_pool group___a_p_r___util___hook.html ga0 int apr_hook_debug_enabled group___a_p_r___util___hook.html ga1 const char * apr_hook_debug_current group___a_p_r___util___hook.html ga2 APR_Util_LDAP LDAP group___a_p_r___util___l_d_a_p.html #define APR_HAS_LDAP group___a_p_r___util___l_d_a_p.html ga0 #define APR_HAS_NETSCAPE_LDAPSDK group___a_p_r___util___l_d_a_p.html ga1 #define APR_HAS_NOVELL_LDAPSDK group___a_p_r___util___l_d_a_p.html ga2 #define APR_HAS_OPENLDAP_LDAPSDK group___a_p_r___util___l_d_a_p.html ga3 #define APR_HAS_MICROSOFT_LDAPSDK group___a_p_r___util___l_d_a_p.html ga4 #define APR_HAS_OTHER_LDAPSDK group___a_p_r___util___l_d_a_p.html ga5 #define APR_HAS_LDAP_SSL group___a_p_r___util___l_d_a_p.html ga6 #define APR_HAS_LDAP_URL_PARSE group___a_p_r___util___l_d_a_p.html ga7 APR_Util_MD4 MD4 Library group___a_p_r___util___m_d4.html apr_md4_ctx_t #define APR_MD4_DIGESTSIZE group___a_p_r___util___m_d4.html ga6 apr_md4_ctx_t apr_md4_ctx_t group___a_p_r___util___m_d4.html ga0 apr_status_t apr_md4_init group___a_p_r___util___m_d4.html ga1 (apr_md4_ctx_t *context) apr_status_t apr_md4_set_xlate group___a_p_r___util___m_d4.html ga2 (apr_md4_ctx_t *context, apr_xlate_t *xlate) apr_status_t apr_md4_update group___a_p_r___util___m_d4.html ga3 (apr_md4_ctx_t *context, const unsigned char *input, apr_size_t inputLen) apr_status_t apr_md4_final group___a_p_r___util___m_d4.html ga4 (unsigned char digest[APR_MD4_DIGESTSIZE], apr_md4_ctx_t *context) apr_status_t apr_md4 group___a_p_r___util___m_d4.html ga5 (unsigned char digest[APR_MD4_DIGESTSIZE], const unsigned char *input, apr_size_t inputLen) APR_MD5 MD5 Routines group___a_p_r___m_d5.html apr_md5_ctx_t #define APR_MD5_DIGESTSIZE group___a_p_r___m_d5.html ga8 apr_md5_ctx_t apr_md5_ctx_t group___a_p_r___m_d5.html ga0 apr_status_t apr_md5_init group___a_p_r___m_d5.html ga1 (apr_md5_ctx_t *context) apr_status_t apr_md5_set_xlate group___a_p_r___m_d5.html ga2 (apr_md5_ctx_t *context, apr_xlate_t *xlate) apr_status_t apr_md5_update group___a_p_r___m_d5.html ga3 (apr_md5_ctx_t *context, const void *input, apr_size_t inputLen) apr_status_t apr_md5_final group___a_p_r___m_d5.html ga4 (unsigned char digest[APR_MD5_DIGESTSIZE], apr_md5_ctx_t *context) apr_status_t apr_md5 group___a_p_r___m_d5.html ga5 (unsigned char digest[APR_MD5_DIGESTSIZE], const void *input, apr_size_t inputLen) apr_status_t apr_md5_encode group___a_p_r___m_d5.html ga6 (const char *password, const char *salt, char *result, apr_size_t nbytes) apr_status_t apr_password_validate group___a_p_r___m_d5.html ga7 (const char *passwd, const char *hash) APR_Util_Opt Optional Functions group___a_p_r___util___opt.html #define APR_OPTIONAL_FN_TYPE group___a_p_r___util___opt.html ga3 (name) #define APR_DECLARE_OPTIONAL_FN group___a_p_r___util___opt.html ga4 (ret, name, args) #define APR_REGISTER_OPTIONAL_FN group___a_p_r___util___opt.html ga5 (name) #define APR_RETRIEVE_OPTIONAL_FN group___a_p_r___util___opt.html ga6 (name) void( apr_opt_fn_t group___a_p_r___util___opt.html ga0 )(void) void apr_dynamic_fn_register group___a_p_r___util___opt.html ga1 (const char *szName, apr_opt_fn_t *pfn) apr_opt_fn_t * apr_dynamic_fn_retrieve group___a_p_r___util___opt.html ga2 (const char *szName) APR_Util_OPT_HOOK Optional Hook Functions group___a_p_r___util___o_p_t___h_o_o_k.html #define APR_OPTIONAL_HOOK group___a_p_r___util___o_p_t___h_o_o_k.html ga2 (ns, name, pfn, aszPre, aszSucc, nOrder) #define APR_IMPLEMENT_OPTIONAL_HOOK_RUN_ALL group___a_p_r___util___o_p_t___h_o_o_k.html ga3 (ns, link, ret, name, args_decl, args_use, ok, decline) void apr_optional_hook_add group___a_p_r___util___o_p_t___h_o_o_k.html ga0 (const char *szName, void(*pfn)(void), const char *const *aszPre, const char *const *aszSucc, int nOrder) apr_array_header_t * apr_optional_hook_get group___a_p_r___util___o_p_t___h_o_o_k.html ga1 (const char *szName) APR_Util_FIFO Thread Safe FIFO bounded queue group___a_p_r___util___f_i_f_o.html apr_queue_t apr_queue_t group___a_p_r___util___f_i_f_o.html ga0 apr_status_t apr_queue_create group___a_p_r___util___f_i_f_o.html ga1 (apr_queue_t **queue, unsigned int queue_capacity, apr_pool_t *a) apr_status_t apr_queue_push group___a_p_r___util___f_i_f_o.html ga2 (apr_queue_t *queue, void *data) apr_status_t apr_queue_pop group___a_p_r___util___f_i_f_o.html ga3 (apr_queue_t *queue, void **data) apr_status_t apr_queue_trypush group___a_p_r___util___f_i_f_o.html ga4 (apr_queue_t *queue, void *data) apr_status_t apr_queue_trypop group___a_p_r___util___f_i_f_o.html ga5 (apr_queue_t *queue, void **data) unsigned int apr_queue_size group___a_p_r___util___f_i_f_o.html ga6 (apr_queue_t *queue) apr_status_t apr_queue_interrupt_all group___a_p_r___util___f_i_f_o.html ga7 (apr_queue_t *queue) apr_status_t apr_queue_term group___a_p_r___util___f_i_f_o.html ga8 (apr_queue_t *queue) APR_Util_RL Resource List Routines group___a_p_r___util___r_l.html apr_reslist_t apr_reslist_t group___a_p_r___util___r_l.html ga0 apr_status_t(* apr_reslist_constructor group___a_p_r___util___r_l.html ga1 )(void **resource, void *params, apr_pool_t *pool) apr_status_t(* apr_reslist_destructor group___a_p_r___util___r_l.html ga2 )(void *resource, void *params, apr_pool_t *pool) apr_status_t apr_reslist_create group___a_p_r___util___r_l.html ga3 (apr_reslist_t **reslist, int min, int smax, int hmax, apr_interval_time_t ttl, apr_reslist_constructor con, apr_reslist_destructor de, void *params, apr_pool_t *pool) apr_status_t apr_reslist_destroy group___a_p_r___util___r_l.html ga4 (apr_reslist_t *reslist) apr_status_t apr_reslist_acquire group___a_p_r___util___r_l.html ga5 (apr_reslist_t *reslist, void **resource) apr_status_t apr_reslist_release group___a_p_r___util___r_l.html ga6 (apr_reslist_t *reslist, void *resource) void apr_reslist_timeout_set group___a_p_r___util___r_l.html ga7 (apr_reslist_t *reslist, apr_interval_time_t timeout) apr_status_t apr_reslist_invalidate group___a_p_r___util___r_l.html ga8 (apr_reslist_t *reslist, void *resource) APR_Util_RMM Relocatable Memory Management Routines group___a_p_r___util___r_m_m.html apr_rmm_t apr_rmm_t group___a_p_r___util___r_m_m.html ga0 apr_size_t apr_rmm_off_t group___a_p_r___util___r_m_m.html ga1 apr_status_t apr_rmm_init group___a_p_r___util___r_m_m.html ga2 (apr_rmm_t **rmm, apr_anylock_t *lock, void *membuf, apr_size_t memsize, apr_pool_t *cont) apr_status_t apr_rmm_destroy group___a_p_r___util___r_m_m.html ga3 (apr_rmm_t *rmm) apr_status_t apr_rmm_attach group___a_p_r___util___r_m_m.html ga4 (apr_rmm_t **rmm, apr_anylock_t *lock, void *membuf, apr_pool_t *cont) apr_status_t apr_rmm_detach group___a_p_r___util___r_m_m.html ga5 (apr_rmm_t *rmm) apr_rmm_off_t apr_rmm_malloc group___a_p_r___util___r_m_m.html ga6 (apr_rmm_t *rmm, apr_size_t reqsize) apr_rmm_off_t apr_rmm_realloc group___a_p_r___util___r_m_m.html ga7 (apr_rmm_t *rmm, void *entity, apr_size_t reqsize) apr_rmm_off_t apr_rmm_calloc group___a_p_r___util___r_m_m.html ga8 (apr_rmm_t *rmm, apr_size_t reqsize) apr_status_t apr_rmm_free group___a_p_r___util___r_m_m.html ga9 (apr_rmm_t *rmm, apr_rmm_off_t entity) void * apr_rmm_addr_get group___a_p_r___util___r_m_m.html ga10 (apr_rmm_t *rmm, apr_rmm_off_t entity) apr_rmm_off_t apr_rmm_offset_get group___a_p_r___util___r_m_m.html ga11 (apr_rmm_t *rmm, void *entity) apr_size_t apr_rmm_overhead_get group___a_p_r___util___r_m_m.html ga12 (int n) APR_Util_DBM_SDBM SDBM library group___a_p_r___util___d_b_m___s_d_b_m.html apr_sdbm_datum_t #define APR_SDBM_DIRFEXT group___a_p_r___util___d_b_m___s_d_b_m.html ga11 #define APR_SDBM_PAGFEXT group___a_p_r___util___d_b_m___s_d_b_m.html ga12 #define APR_SDBM_INSERT group___a_p_r___util___d_b_m___s_d_b_m.html ga13 #define APR_SDBM_REPLACE group___a_p_r___util___d_b_m___s_d_b_m.html ga14 #define APR_SDBM_INSERTDUP group___a_p_r___util___d_b_m___s_d_b_m.html ga15 apr_sdbm_t apr_sdbm_t group___a_p_r___util___d_b_m___s_d_b_m.html ga0 apr_status_t apr_sdbm_open group___a_p_r___util___d_b_m___s_d_b_m.html ga1 (apr_sdbm_t **db, const char *name, apr_int32_t mode, apr_fileperms_t perms, apr_pool_t *p) apr_status_t apr_sdbm_close group___a_p_r___util___d_b_m___s_d_b_m.html ga2 (apr_sdbm_t *db) apr_status_t apr_sdbm_lock group___a_p_r___util___d_b_m___s_d_b_m.html ga3 (apr_sdbm_t *db, int type) apr_status_t apr_sdbm_unlock group___a_p_r___util___d_b_m___s_d_b_m.html ga4 (apr_sdbm_t *db) apr_status_t apr_sdbm_fetch group___a_p_r___util___d_b_m___s_d_b_m.html ga5 (apr_sdbm_t *db, apr_sdbm_datum_t *value, apr_sdbm_datum_t key) apr_status_t apr_sdbm_store group___a_p_r___util___d_b_m___s_d_b_m.html ga6 (apr_sdbm_t *db, apr_sdbm_datum_t key, apr_sdbm_datum_t value, int opt) apr_status_t apr_sdbm_delete group___a_p_r___util___d_b_m___s_d_b_m.html ga7 (apr_sdbm_t *db, const apr_sdbm_datum_t key) apr_status_t apr_sdbm_firstkey group___a_p_r___util___d_b_m___s_d_b_m.html ga8 (apr_sdbm_t *db, apr_sdbm_datum_t *key) apr_status_t apr_sdbm_nextkey group___a_p_r___util___d_b_m___s_d_b_m.html ga9 (apr_sdbm_t *db, apr_sdbm_datum_t *key) int apr_sdbm_rdonly group___a_p_r___util___d_b_m___s_d_b_m.html ga10 (apr_sdbm_t *db) APR_Util_StrMatch String matching routines group___a_p_r___util___str_match.html apr_strmatch_pattern apr_strmatch_pattern apr_strmatch_pattern group___a_p_r___util___str_match.html ga0 const char * apr_strmatch group___a_p_r___util___str_match.html ga1 (const apr_strmatch_pattern *pattern, const char *s, apr_size_t slen) const apr_strmatch_pattern * apr_strmatch_precompile group___a_p_r___util___str_match.html ga2 (apr_pool_t *p, const char *s, int case_sensitive) APR_Util_URI URI group___a_p_r___util___u_r_i.html apr_uri_t #define APR_URI_FTP_DEFAULT_PORT group___a_p_r___util___u_r_i.html ga5 #define APR_URI_SSH_DEFAULT_PORT group___a_p_r___util___u_r_i.html ga6 #define APR_URI_TELNET_DEFAULT_PORT group___a_p_r___util___u_r_i.html ga7 #define APR_URI_GOPHER_DEFAULT_PORT group___a_p_r___util___u_r_i.html ga8 #define APR_URI_HTTP_DEFAULT_PORT group___a_p_r___util___u_r_i.html ga9 #define APR_URI_POP_DEFAULT_PORT group___a_p_r___util___u_r_i.html ga10 #define APR_URI_NNTP_DEFAULT_PORT group___a_p_r___util___u_r_i.html ga11 #define APR_URI_IMAP_DEFAULT_PORT group___a_p_r___util___u_r_i.html ga12 #define APR_URI_PROSPERO_DEFAULT_PORT group___a_p_r___util___u_r_i.html ga13 #define APR_URI_WAIS_DEFAULT_PORT group___a_p_r___util___u_r_i.html ga14 #define APR_URI_LDAP_DEFAULT_PORT group___a_p_r___util___u_r_i.html ga15 #define APR_URI_HTTPS_DEFAULT_PORT group___a_p_r___util___u_r_i.html ga16 #define APR_URI_RTSP_DEFAULT_PORT group___a_p_r___util___u_r_i.html ga17 #define APR_URI_SNEWS_DEFAULT_PORT group___a_p_r___util___u_r_i.html ga18 #define APR_URI_ACAP_DEFAULT_PORT group___a_p_r___util___u_r_i.html ga19 #define APR_URI_NFS_DEFAULT_PORT group___a_p_r___util___u_r_i.html ga20 #define APR_URI_TIP_DEFAULT_PORT group___a_p_r___util___u_r_i.html ga21 #define APR_URI_SIP_DEFAULT_PORT group___a_p_r___util___u_r_i.html ga22 #define APR_URI_UNP_OMITSITEPART group___a_p_r___util___u_r_i.html ga23 #define APR_URI_UNP_OMITUSER group___a_p_r___util___u_r_i.html ga24 #define APR_URI_UNP_OMITPASSWORD group___a_p_r___util___u_r_i.html ga25 #define APR_URI_UNP_OMITUSERINFO group___a_p_r___util___u_r_i.html ga26 #define APR_URI_UNP_REVEALPASSWORD group___a_p_r___util___u_r_i.html ga27 #define APR_URI_UNP_OMITPATHINFO group___a_p_r___util___u_r_i.html ga28 #define APR_URI_UNP_OMITQUERY group___a_p_r___util___u_r_i.html ga29 apr_uri_t apr_uri_t group___a_p_r___util___u_r_i.html ga0 apr_port_t apr_uri_port_of_scheme group___a_p_r___util___u_r_i.html ga1 (const char *scheme_str) char * apr_uri_unparse group___a_p_r___util___u_r_i.html ga2 (apr_pool_t *p, const apr_uri_t *uptr, unsigned flags) int apr_uri_parse group___a_p_r___util___u_r_i.html ga3 (apr_pool_t *p, const char *uri, apr_uri_t *uptr) int apr_uri_parse_hostinfo group___a_p_r___util___u_r_i.html ga4 (apr_pool_t *p, const char *hostinfo, apr_uri_t *uptr) APR_UUID UUID Handling group___a_p_r___u_u_i_d.html apr_uuid_t #define APR_UUID_FORMATTED_LENGTH group___a_p_r___u_u_i_d.html ga3 void apr_uuid_get group___a_p_r___u_u_i_d.html ga0 (apr_uuid_t *uuid) void apr_uuid_format group___a_p_r___u_u_i_d.html ga1 (char *buffer, const apr_uuid_t *uuid) apr_status_t apr_uuid_parse group___a_p_r___u_u_i_d.html ga2 (apr_uuid_t *uuid, const char *uuid_str) APR_XLATE I18N translation library group___a_p_r___x_l_a_t_e.html #define APR_DEFAULT_CHARSET group___a_p_r___x_l_a_t_e.html ga6 #define APR_LOCALE_CHARSET group___a_p_r___x_l_a_t_e.html ga7 apr_xlate_t apr_xlate_t group___a_p_r___x_l_a_t_e.html ga0 apr_status_t apr_xlate_open group___a_p_r___x_l_a_t_e.html ga1 (apr_xlate_t **convset, const char *topage, const char *frompage, apr_pool_t *pool) apr_status_t apr_xlate_sb_get group___a_p_r___x_l_a_t_e.html ga2 (apr_xlate_t *convset, int *onoff) apr_status_t apr_xlate_conv_buffer group___a_p_r___x_l_a_t_e.html ga3 (apr_xlate_t *convset, const char *inbuf, apr_size_t *inbytes_left, char *outbuf, apr_size_t *outbytes_left) apr_int32_t apr_xlate_conv_byte group___a_p_r___x_l_a_t_e.html ga4 (apr_xlate_t *convset, unsigned char inchar) apr_status_t apr_xlate_close group___a_p_r___x_l_a_t_e.html ga5 (apr_xlate_t *convset) APR_Util_XML XML group___a_p_r___util___x_m_l.html Apache apr_text apr_text_header apr_xml_attr apr_xml_elem apr_xml_doc #define APR_XML_NS_DAV_ID group___a_p_r___util___x_m_l.html ga17 #define APR_XML_NS_NONE group___a_p_r___util___x_m_l.html ga18 #define APR_XML_NS_ERROR_BASE group___a_p_r___util___x_m_l.html ga19 #define APR_XML_NS_IS_ERROR group___a_p_r___util___x_m_l.html ga20 (e) #define APR_XML_ELEM_IS_EMPTY group___a_p_r___util___x_m_l.html ga21 (e) #define APR_XML_X2T_FULL group___a_p_r___util___x_m_l.html ga22 #define APR_XML_X2T_INNER group___a_p_r___util___x_m_l.html ga23 #define APR_XML_X2T_LANG_INNER group___a_p_r___util___x_m_l.html ga24 #define APR_XML_X2T_FULL_NS_LANG group___a_p_r___util___x_m_l.html ga25 #define APR_XML_GET_URI_ITEM group___a_p_r___util___x_m_l.html ga26 (ary, i) apr_text apr_text group___a_p_r___util___x_m_l.html ga0 apr_text_header apr_text_header group___a_p_r___util___x_m_l.html ga1 apr_xml_attr apr_xml_attr group___a_p_r___util___x_m_l.html ga2 apr_xml_elem apr_xml_elem group___a_p_r___util___x_m_l.html ga3 apr_xml_doc apr_xml_doc group___a_p_r___util___x_m_l.html ga4 apr_xml_parser apr_xml_parser group___a_p_r___util___x_m_l.html ga5 void apr_text_append group___a_p_r___util___x_m_l.html ga6 (apr_pool_t *p, apr_text_header *hdr, const char *text) apr_xml_parser * apr_xml_parser_create group___a_p_r___util___x_m_l.html ga7 (apr_pool_t *pool) apr_status_t apr_xml_parse_file group___a_p_r___util___x_m_l.html ga8 (apr_pool_t *p, apr_xml_parser **parser, apr_xml_doc **ppdoc, apr_file_t *xmlfd, apr_size_t buffer_length) apr_status_t apr_xml_parser_feed group___a_p_r___util___x_m_l.html ga9 (apr_xml_parser *parser, const char *data, apr_size_t len) apr_status_t apr_xml_parser_done group___a_p_r___util___x_m_l.html ga10 (apr_xml_parser *parser, apr_xml_doc **pdoc) char * apr_xml_parser_geterror group___a_p_r___util___x_m_l.html ga11 (apr_xml_parser *parser, char *errbuf, apr_size_t errbufsize) void apr_xml_to_text group___a_p_r___util___x_m_l.html ga12 (apr_pool_t *p, const apr_xml_elem *elem, int style, apr_array_header_t *namespaces, int *ns_map, const char **pbuf, apr_size_t *psize) const char * apr_xml_empty_elem group___a_p_r___util___x_m_l.html ga13 (apr_pool_t *p, const apr_xml_elem *elem) const char * apr_xml_quote_string group___a_p_r___util___x_m_l.html ga14 (apr_pool_t *p, const char *s, int quotes) void apr_xml_quote_elem group___a_p_r___util___x_m_l.html ga15 (apr_pool_t *p, apr_xml_elem *elem) int apr_xml_insert_uri group___a_p_r___util___x_m_l.html ga16 (apr_array_header_t *uri_array, const char *uri) APR_Util APR Utility Functions group___a_p_r___util.html APR_Util_Base64 APR_Util_Bucket_Brigades APR_Util_Date APR_Util_DBM APR_Util_Hook APR_Util_LDAP APR_Util_MD4 APR_Util_Opt APR_Util_FIFO APR_Util_RL APR_Util_RMM APR_Util_StrMatch APR_Util_URI APR_Util_XML #define APU_DECLARE group___a_p_r___util.html ga0 (type) #define APU_DECLARE_NONSTD group___a_p_r___util.html ga1 (type) #define APU_DECLARE_DATA group___a_p_r___util.html ga2 #define APU_HAVE_SDBM group___a_p_r___util.html ga3 #define APU_HAVE_GDBM group___a_p_r___util.html ga4 #define APU_HAVE_NDBM group___a_p_r___util.html ga5 #define APU_HAVE_DB group___a_p_r___util.html ga6 #define APU_HAVE_DB_VERSION group___a_p_r___util.html ga7 #define APU_HAVE_APR_ICONV group___a_p_r___util.html ga8 #define APU_HAVE_ICONV group___a_p_r___util.html ga9 #define APR_HAS_XLATE group___a_p_r___util.html ga10 dbm/ /home/joe/src/apache/apr/apr-util/trunk/dbm/ dir_000000.html dbm/sdbm/ xml/expat/ /home/joe/src/apache/apr/apr-util/trunk/xml/expat/ dir_000006.html xml/expat/lib/ acconfig.h include/ /home/joe/src/apache/apr/apr-util/trunk/include/ dir_000002.html include/private/ apr_anylock.h apr_base64.h apr_buckets.h apr_date.h apr_dbd.h apr_dbm.h apr_hooks.h apr_ldap.h apr_ldap_init.h apr_ldap_option.h apr_ldap_url.h apr_md4.h apr_md5.h apr_optional.h apr_optional_hooks.h apr_queue.h apr_reslist.h apr_rmm.h apr_sdbm.h apr_sha1.h apr_strmatch.h apr_uri.h apr_uuid.h apr_xlate.h apr_xml.h apu.h apu_version.h apu_want.h xml/expat/lib/ /home/joe/src/apache/apr/apr-util/trunk/xml/expat/lib/ dir_000007.html ascii.h asciitab.h iasciitab.h latin1tab.h map_osd_ebcdic_df04_1.h nametab.h osd_ebcdic_df04_1.h utf8tab.h winconfig.h xmlrole.h xmltok.h xmltok_impl.h include/private/ /home/joe/src/apache/apr/apr-util/trunk/include/private/ dir_000003.html apr_dbm_private.h apu_config.h apu_select_dbm.h dbm/sdbm/ /home/joe/src/apache/apr/apr-util/trunk/dbm/sdbm/ dir_000001.html sdbm_pair.h sdbm_private.h sdbm_tune.h test/ /home/joe/src/apache/apr/apr-util/trunk/test/ dir_000004.html abts.h abts_tests.h test_apu.h testutil.h xml/ /home/joe/src/apache/apr/apr-util/trunk/xml/ dir_000005.html xml/expat/ Apache namespace_apache.html rapache-1.2.8/libapreq2/docs/html/0000755000175100017510000000000012706745114016237 5ustar ondrejondrejrapache-1.2.8/libapreq2/docs/html/annotated.html0000644000175100017510000000502412706745114021103 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: Data Structures

libapreq2 Data Structures

Here are the data structures with brief descriptions:
apreq_cookie_tCookie type, supporting both Netscape and RFC cookie specifications
apreq_handle_t
apreq_hook_t
apreq_module_tVtable describing the necessary environment functions
apreq_param_t
apreq_parser_t
apreq_value_tLibapreq's pre-extensible string type
rapache-1.2.8/libapreq2/docs/html/apreq_8h-source.html0000644000175100017510000003036312706745114022137 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: include/apreq.h Source File

apreq.h

Go to the documentation of this file.
00001 /*
00002 **  Copyright 2003-2005  The Apache Software Foundation
00003 **
00004 **  Licensed under the Apache License, Version 2.0 (the "License");
00005 **  you may not use this file except in compliance with the License.
00006 **  You may obtain a copy of the License at
00007 **
00008 **      http://www.apache.org/licenses/LICENSE-2.0
00009 **
00010 **  Unless required by applicable law or agreed to in writing, software
00011 **  distributed under the License is distributed on an "AS IS" BASIS,
00012 **  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
00013 **  See the License for the specific language governing permissions and
00014 **  limitations under the License.
00015 */
00016 
00017 #ifndef APREQ_H
00018 #define APREQ_H
00019 
00020 #ifdef APREQ_DEBUG
00021 #include <assert.h>
00022 #endif
00023 
00024 #include "apr_tables.h"
00025 #include <stddef.h>
00026 
00027 #ifdef  __cplusplus
00028  extern "C" {
00029 #endif 
00030 
00039 #ifndef WIN32
00040 #define APREQ_DECLARE(d)                APR_DECLARE(d)
00041 #define APREQ_DECLARE_NONSTD(d)         APR_DECLARE_NONSTD(d)
00042 #define APREQ_DECLARE_DATA
00043 #else
00044 #define APREQ_DECLARE(type)             __declspec(dllexport) type __stdcall
00045 #define APREQ_DECLARE_NONSTD(type)      __declspec(dllexport) type
00046 #define APREQ_DECLARE_DATA              __declspec(dllexport)
00047 #endif
00048 
00049 #define APREQ_DEFAULT_READ_BLOCK_SIZE   (64  * 1024)
00050 #define APREQ_DEFAULT_READ_LIMIT        (64 * 1024 * 1024)
00051 #define APREQ_DEFAULT_BRIGADE_LIMIT     (256 * 1024)
00052 #define APREQ_DEFAULT_NELTS              8
00053 
00054 
00055 
00056 #define APREQ_FLAGS_OFF(f, name) ((f) &= ~(name##_MASK << name##_BIT))
00057 #define APREQ_FLAGS_ON(f, name)  ((f) |=  (name##_MASK << name##_BIT))
00058 #define APREQ_FLAGS_GET(f, name) (((f) >> name##_BIT) & name##_MASK)
00059 #define APREQ_FLAGS_SET(f, name, value)                 \
00060     ((f) = (((f) & ~(name##_MASK << name##_BIT))        \
00061             | ((name##_MASK & (value)) << name##_BIT)))
00062 
00063 
00064 #define APREQ_CHARSET_BIT           0
00065 #define APREQ_CHARSET_MASK        255
00066 
00067 #define APREQ_TAINTED_BIT           8
00068 #define APREQ_TAINTED_MASK          1
00069 
00070 #define APREQ_COOKIE_VERSION_BIT   11
00071 #define APREQ_COOKIE_VERSION_MASK   3
00072 
00073 #define APREQ_COOKIE_SECURE_BIT    13
00074 #define APREQ_COOKIE_SECURE_MASK    1
00075 
00077 typedef enum {
00078     APREQ_CHARSET_ASCII  =0,
00079     APREQ_CHARSET_LATIN1 =1, /* ISO-8859-1   */
00080     APREQ_CHARSET_CP1252 =2, /* Windows-1252 */
00081     APREQ_CHARSET_UTF8   =8
00082 } apreq_charset_t;
00083 
00084 
00086 typedef enum { 
00087     APREQ_JOIN_AS_IS,      
00088     APREQ_JOIN_ENCODE,     
00089     APREQ_JOIN_DECODE,     
00090     APREQ_JOIN_QUOTE       
00091 } apreq_join_t;
00092 
00094 typedef enum {
00095     APREQ_MATCH_FULL,       
00096     APREQ_MATCH_PARTIAL     
00097 } apreq_match_t;
00098 
00100 typedef enum {
00101     APREQ_EXPIRES_HTTP,       
00102     APREQ_EXPIRES_NSCOOKIE    
00103 } apreq_expires_t;
00104 
00105 
00107 typedef struct apreq_value_t {
00108     char             *name;    
00109     apr_size_t        nlen;    
00110     apr_size_t        dlen;    
00111     char              data[1]; 
00112 } apreq_value_t;
00113 
00114 static APR_INLINE
00115 void apreq_value_table_add(const apreq_value_t *v, apr_table_t *t) {
00116     apr_table_addn(t, v->name, v->data);
00117 }
00118 
00119 #define apreq_attr_to_type(T,A,P) ( (T*) ((char*)(P)-offsetof(T,A)) )
00120 
00132 APREQ_DECLARE(apr_status_t) apreq_initialize(apr_pool_t *pool);
00133 
00134 
00146 APREQ_DECLARE(apr_status_t) apreq_pre_initialize(apr_pool_t *pool);
00147 
00155 APREQ_DECLARE(apr_status_t) apreq_post_initialize(apr_pool_t *pool);
00156 
00157 
00158 #ifdef __cplusplus
00159  }
00160 #endif
00161 
00162 #endif /* APREQ_H */
rapache-1.2.8/libapreq2/docs/html/apreq_8h.html0000644000175100017510000005361412706745114020645 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: include/apreq.h File Reference

apreq.h File Reference

Main header file... More...

#include "apr_tables.h"
#include <stddef.h>

Go to the source code of this file.

Defines

#define APREQ_DECLARE(d)   APR_DECLARE(d)
#define APREQ_DECLARE_NONSTD(d)   APR_DECLARE_NONSTD(d)
#define APREQ_DECLARE_DATA
#define APREQ_DEFAULT_READ_BLOCK_SIZE   (64 * 1024)
#define APREQ_DEFAULT_READ_LIMIT   (64 * 1024 * 1024)
#define APREQ_DEFAULT_BRIGADE_LIMIT   (256 * 1024)
#define APREQ_DEFAULT_NELTS   8
#define APREQ_FLAGS_OFF(f, name)   ((f) &= ~(name##_MASK << name##_BIT))
#define APREQ_FLAGS_ON(f, name)   ((f) |= (name##_MASK << name##_BIT))
#define APREQ_FLAGS_GET(f, name)   (((f) >> name##_BIT) & name##_MASK)
#define APREQ_FLAGS_SET(f, name, value)
#define APREQ_CHARSET_BIT   0
#define APREQ_CHARSET_MASK   255
#define APREQ_TAINTED_BIT   8
#define APREQ_TAINTED_MASK   1
#define APREQ_COOKIE_VERSION_BIT   11
#define APREQ_COOKIE_VERSION_MASK   3
#define APREQ_COOKIE_SECURE_BIT   13
#define APREQ_COOKIE_SECURE_MASK   1
#define apreq_attr_to_type(T, A, P)   ( (T*) ((char*)(P)-offsetof(T,A)) )

Typedefs

typedef apreq_value_t apreq_value_t
 libapreq's pre-extensible string type

Enumerations

enum  apreq_charset_t { APREQ_CHARSET_ASCII = 0, APREQ_CHARSET_LATIN1 = 1, APREQ_CHARSET_CP1252 = 2, APREQ_CHARSET_UTF8 = 8 }
enum  apreq_join_t { APREQ_JOIN_AS_IS, APREQ_JOIN_ENCODE, APREQ_JOIN_DECODE, APREQ_JOIN_QUOTE }
enum  apreq_match_t { APREQ_MATCH_FULL, APREQ_MATCH_PARTIAL }
enum  apreq_expires_t { APREQ_EXPIRES_HTTP, APREQ_EXPIRES_NSCOOKIE }

Functions

static APR_INLINE void apreq_value_table_add (const apreq_value_t *v, apr_table_t *t)
apr_status_t apreq_initialize (apr_pool_t *pool)
apr_status_t apreq_pre_initialize (apr_pool_t *pool)
apr_status_t apreq_post_initialize (apr_pool_t *pool)


Detailed Description

Main header file...

Define the generic APREQ_ macros and common data structures.


Define Documentation

#define APREQ_FLAGS_SET f,
name,
value   ) 
 

Value:

((f) = (((f) & ~(name##_MASK << name##_BIT))        \
            | ((name##_MASK & (value)) << name##_BIT)))


Enumeration Type Documentation

enum apreq_charset_t
 

Character encodings.

enum apreq_expires_t
 

Expiration date format

Enumeration values:
APREQ_EXPIRES_HTTP  Use date formatting consistent with RFC 2616
APREQ_EXPIRES_NSCOOKIE  Use format consistent with Netscape's Cookie Spec

enum apreq_join_t
 

Join type

Enumeration values:
APREQ_JOIN_AS_IS  Join the strings without modification
APREQ_JOIN_ENCODE  Url-encode the strings before joining them
APREQ_JOIN_DECODE  Url-decode the strings before joining them
APREQ_JOIN_QUOTE  Quote the strings, backslashing existing quote marks.

enum apreq_match_t
 

Match type

Enumeration values:
APREQ_MATCH_FULL  Full match only.
APREQ_MATCH_PARTIAL  Partial matches are ok.


Function Documentation

apr_status_t apreq_initialize apr_pool_t pool  ) 
 

Initialize libapreq2. Applications (except apache modules using mod_apreq) should call this exactly once before they use any libapreq2 modules. If you want to modify the list of default parsers with apreq_register_parser(), please use apreq_pre_initialize() and apreq_post_initialize() instead.

Parameters:
pool a base pool persisting while libapreq2 is used
Remarks:
after you detroy the pool, you have to call this function again with a new pool if you still plan to use libapreq2

apr_status_t apreq_post_initialize apr_pool_t pool  ) 
 

Post-initialize libapreq2. Applications (except apache modules using mod_apreq2) should this exactly once before they use any libapreq2 modules for parsing.

Parameters:
pool the same pool that was used in apreq_pre_initialize().

apr_status_t apreq_pre_initialize apr_pool_t pool  ) 
 

Pre-initialize libapreq2. Applications (except apache modules using mod_apreq2) should call this exactly once before they register custom parsers with libapreq2. mod_apreq2 does this automatically during the post-config phase, so modules that need call apreq_register_parser should create a post-config hook using APR_HOOK_MIDDLE.

Parameters:
pool a base pool persisting while libapreq2 is used
Remarks:
after you detroyed the pool, you have to call this function again with a new pool if you still plan to use libapreq2

rapache-1.2.8/libapreq2/docs/html/apreq__cookie_8h-source.html0000644000175100017510000003533412706745114023632 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: include/apreq_cookie.h Source File

apreq_cookie.h

Go to the documentation of this file.
00001 /*
00002 **  Copyright 2003-2005  The Apache Software Foundation
00003 **
00004 **  Licensed under the Apache License, Version 2.0 (the "License");
00005 **  you may not use this file except in compliance with the License.
00006 **  You may obtain a copy of the License at
00007 **
00008 **      http://www.apache.org/licenses/LICENSE-2.0
00009 **
00010 **  Unless required by applicable law or agreed to in writing, software
00011 **  distributed under the License is distributed on an "AS IS" BASIS,
00012 **  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
00013 **  See the License for the specific language governing permissions and
00014 **  limitations under the License.
00015 */
00016 
00017 #ifndef APREQ_COOKIE_H
00018 #define APREQ_COOKIE_H
00019 
00020 #include "apreq.h"
00021 #include "apr_time.h"
00022 
00023 #ifdef  __cplusplus
00024 extern "C" {
00025 #endif 
00026 
00047 #define APREQ_COOKIE_MAX_LENGTH            4096
00048 
00052 typedef struct apreq_cookie_t {
00053 
00054     char           *path;        
00055     char           *domain;      
00056     char           *port;        
00057     char           *comment;     
00058     char           *commentURL;  
00059     apr_time_t      max_age;     
00060     unsigned        flags;       
00061     const apreq_value_t   v;     
00063 } apreq_cookie_t;
00064 
00065 
00067 static APR_INLINE
00068 apreq_cookie_t *apreq_value_to_cookie(const char *val)
00069 {
00070     union { const char *in; char *out; } deconst;
00071 
00072     deconst.in = val;
00073     return apreq_attr_to_type(apreq_cookie_t, v,
00074            apreq_attr_to_type(apreq_value_t, data, deconst.out));
00075 }
00076 
00078 static APR_INLINE
00079 unsigned apreq_cookie_version(const apreq_cookie_t *c) {
00080     return APREQ_FLAGS_GET(c->flags, APREQ_COOKIE_VERSION);
00081 }
00082 
00084 static APR_INLINE
00085 void apreq_cookie_version_set(apreq_cookie_t *c, unsigned v) {
00086     APREQ_FLAGS_SET(c->flags, APREQ_COOKIE_VERSION, v);
00087 }
00088 
00090 static APR_INLINE
00091 unsigned apreq_cookie_is_secure(const apreq_cookie_t *c) {
00092     return APREQ_FLAGS_GET(c->flags, APREQ_COOKIE_SECURE);
00093 }
00094 
00098 static APR_INLINE
00099 void apreq_cookie_secure_on(apreq_cookie_t *c) {
00100     APREQ_FLAGS_ON(c->flags, APREQ_COOKIE_SECURE);
00101 }
00102 
00104 static APR_INLINE
00105 void apreq_cookie_secure_off(apreq_cookie_t *c) {
00106     APREQ_FLAGS_OFF(c->flags, APREQ_COOKIE_SECURE);
00107 }
00108 
00109 
00111 static APR_INLINE
00112 unsigned apreq_cookie_is_tainted(const apreq_cookie_t *c) {
00113     return APREQ_FLAGS_GET(c->flags, APREQ_TAINTED);
00114 }
00115 
00117 static APR_INLINE
00118 void apreq_cookie_tainted_on(apreq_cookie_t *c) {
00119     APREQ_FLAGS_ON(c->flags, APREQ_TAINTED);
00120 }
00121 
00123 static APR_INLINE
00124 void apreq_cookie_tainted_off(apreq_cookie_t *c) {
00125     APREQ_FLAGS_OFF(c->flags, APREQ_TAINTED);
00126 }
00127 
00143 APREQ_DECLARE(apr_status_t) apreq_parse_cookie_header(apr_pool_t *pool,
00144                                                       apr_table_t *jar,
00145                                                       const char *header);
00146 
00158 APREQ_DECLARE(apreq_cookie_t *) apreq_cookie_make(apr_pool_t *pool, 
00159                                                   const char *name,
00160                                                   const apr_size_t nlen, 
00161                                                   const char *value,
00162                                                   const apr_size_t vlen);
00163 
00173 APREQ_DECLARE(char*) apreq_cookie_as_string(const apreq_cookie_t *c,
00174                                             apr_pool_t *p);
00175 
00176 
00189 APREQ_DECLARE(int) apreq_cookie_serialize(const apreq_cookie_t *c,
00190                                           char *buf, apr_size_t len);
00191 
00206 APREQ_DECLARE(void) apreq_cookie_expires(apreq_cookie_t *c, 
00207                                          const char *time_str);
00208 
00209 #ifdef __cplusplus
00210  }
00211 #endif
00212 
00213 #endif /*APREQ_COOKIE_H*/
00214 
00215 
rapache-1.2.8/libapreq2/docs/html/apreq__cookie_8h.html0000644000175100017510000010136012706745114022325 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: include/apreq_cookie.h File Reference

apreq_cookie.h File Reference

Cookies and Jars. More...

#include "apreq.h"
#include "apr_time.h"

Go to the source code of this file.

Defines

#define APREQ_COOKIE_MAX_LENGTH   4096

Typedefs

typedef apreq_cookie_t apreq_cookie_t
 Cookie type, supporting both Netscape and RFC cookie specifications.

Functions

static APR_INLINE apreq_cookie_tapreq_value_to_cookie (const char *val)
static APR_INLINE unsigned apreq_cookie_version (const apreq_cookie_t *c)
static APR_INLINE void apreq_cookie_version_set (apreq_cookie_t *c, unsigned v)
static APR_INLINE unsigned apreq_cookie_is_secure (const apreq_cookie_t *c)
static APR_INLINE void apreq_cookie_secure_on (apreq_cookie_t *c)
static APR_INLINE void apreq_cookie_secure_off (apreq_cookie_t *c)
static APR_INLINE unsigned apreq_cookie_is_tainted (const apreq_cookie_t *c)
static APR_INLINE void apreq_cookie_tainted_on (apreq_cookie_t *c)
static APR_INLINE void apreq_cookie_tainted_off (apreq_cookie_t *c)
apr_status_t apreq_parse_cookie_header (apr_pool_t *pool, apr_table_t *jar, const char *header)
apreq_cookie_tapreq_cookie_make (apr_pool_t *pool, const char *name, const apr_size_t nlen, const char *value, const apr_size_t vlen)
char * apreq_cookie_as_string (const apreq_cookie_t *c, apr_pool_t *p)
int apreq_cookie_serialize (const apreq_cookie_t *c, char *buf, apr_size_t len)
void apreq_cookie_expires (apreq_cookie_t *c, const char *time_str)


Detailed Description

Cookies and Jars.

apreq_cookie.h describes a common server-side API for request (incoming) and response (outgoing) cookies. It aims towards compliance with the standard cookie specifications listed below.

See also:
http://wp.netscape.com/newsref/std/cookie_spec.html

http://www.ietf.org/rfc/rfc2109.txt

http://www.ietf.org/rfc/rfc2964.txt

http://www.ietf.org/rfc/rfc2965.txt


Define Documentation

#define APREQ_COOKIE_MAX_LENGTH   4096
 

Todo:
convert this macro to an apreq_module_t method.
Maximum length of a single Set-Cookie(2) header.


Function Documentation

char* apreq_cookie_as_string const apreq_cookie_t c,
apr_pool_t p
 

Returns a string that represents the cookie as it would appear in a valid "Set-Cookie*" header.

Parameters:
c cookie.
p pool which allocates the returned string.
Returns:
header string.

void apreq_cookie_expires apreq_cookie_t c,
const char *  time_str
 

Set the Cookie's expiration date.

Parameters:
c The cookie.
time_str If NULL, the Cookie's expiration date is unset, making it a session cookie. This means no "expires" or "max-age" attribute will appear in the cookie's serialized form. If time_str is not NULL, the expiration date will be reset to the offset (from now) represented by time_str. The time_str should be in a format that apreq_atoi64t() can understand, namely /[+-]?\d+\s*[YMDhms]/.
Remarks:
Now time_str may also be a fixed date; see apr_date_parse_rfc() for admissible formats.

static APR_INLINE unsigned apreq_cookie_is_secure const apreq_cookie_t c  )  [static]
 

Returns:
1 if the secure flag is set, 0 otherwise.

static APR_INLINE unsigned apreq_cookie_is_tainted const apreq_cookie_t c  )  [static]
 

Returns:
1 if the taint flag is set, 0 otherwise.

apreq_cookie_t* apreq_cookie_make apr_pool_t pool,
const char *  name,
const apr_size_t  nlen,
const char *  value,
const apr_size_t  vlen
 

Returns a new cookie, made from the argument list.

Parameters:
pool Pool which allocates the cookie.
name The cookie's name.
nlen Length of name.
value The cookie's value.
vlen Length of value.
Returns:
the new cookie

static APR_INLINE void apreq_cookie_secure_off apreq_cookie_t c  )  [static]
 

Turns off the cookie's secure flag.

static APR_INLINE void apreq_cookie_secure_on apreq_cookie_t c  )  [static]
 

Sets the cookie's secure flag, meaning it only comes back over an SSL-encrypted connction.

int apreq_cookie_serialize const apreq_cookie_t c,
char *  buf,
apr_size_t  len
 

Same functionality as apreq_cookie_as_string. Stores the string representation in buf, using up to len bytes in buf as storage. The return value has the same semantics as that of apr_snprintf, including the special behavior for a "len = 0" argument.

Parameters:
c cookie.
buf storage location for the result.
len size of buf's storage area.
Returns:
size of resulting header string.

static APR_INLINE void apreq_cookie_tainted_off apreq_cookie_t c  )  [static]
 

Turns off the cookie's tainted flag.

static APR_INLINE void apreq_cookie_tainted_on apreq_cookie_t c  )  [static]
 

Sets the cookie's tainted flag.

static APR_INLINE unsigned apreq_cookie_version const apreq_cookie_t c  )  [static]
 

Returns:
1 if this is an RFC cookie, 0 if its a Netscape cookie.

static APR_INLINE void apreq_cookie_version_set apreq_cookie_t c,
unsigned  v
[static]
 

Sets the cookie's protocol version.

apr_status_t apreq_parse_cookie_header apr_pool_t pool,
apr_table_t jar,
const char *  header
 

Parse a cookie header and store the cookies in an apr_table_t.

Parameters:
pool pool which allocates the cookies
jar table where parsed cookies are stored
header the header value
Returns:
APR_SUCCESS.

APREQ_ERROR_BADSEQ if an unparseable character sequence appears.

APREQ_ERROR_MISMATCH if an rfc-cookie attribute appears in a netscape cookie header.

APR_ENOTIMPL if an unrecognized rfc-cookie attribute appears.

APREQ_ERROR_NOTOKEN if a required token was not present.

APREQ_ERROR_BADCHAR if an unexpected token was present.

static APR_INLINE apreq_cookie_t* apreq_value_to_cookie const char *  val  )  [static]
 

Upgrades a jar's table values to apreq_cookie_t structs.

rapache-1.2.8/libapreq2/docs/html/apreq__error_8h-source.html0000644000175100017510000002144612706745114023511 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: include/apreq_error.h Source File

apreq_error.h

Go to the documentation of this file.
00001 /*
00002 **  Copyright 2003-2005  The Apache Software Foundation
00003 **
00004 **  Licensed under the Apache License, Version 2.0 (the "License");
00005 **  you may not use this file except in compliance with the License.
00006 **  You may obtain a copy of the License at
00007 **
00008 **      http://www.apache.org/licenses/LICENSE-2.0
00009 **
00010 **  Unless required by applicable law or agreed to in writing, software
00011 **  distributed under the License is distributed on an "AS IS" BASIS,
00012 **  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
00013 **  See the License for the specific language governing permissions and
00014 **  limitations under the License.
00015 */
00016 
00017 #ifndef APREQ_ERROR_H
00018 #define APREQ_ERROR_H
00019 
00020 #include "apr_errno.h"
00021 #include "apreq.h"
00022 
00023 #ifdef  __cplusplus
00024  extern "C" {
00025 #endif 
00026 
00031 APREQ_DECLARE(char *)
00032 apreq_strerror(apr_status_t s, char *buf, apr_size_t bufsize);
00033 
00042 #ifndef APR_EBADARG
00043 #define APR_EBADARG                APR_BADARG   /* XXX: don't use APR_BADARG */
00044 #endif
00045 
00047 #define APREQ_ERROR_GENERAL        APR_OS_START_USERERR
00049 #define APREQ_ERROR_TAINTED        (APREQ_ERROR_GENERAL + 1)
00051 #define APREQ_ERROR_INTERRUPT      (APREQ_ERROR_GENERAL + 2)
00052 
00054 #define APREQ_ERROR_BADDATA        (APREQ_ERROR_GENERAL  + 10)
00056 #define APREQ_ERROR_BADCHAR        (APREQ_ERROR_BADDATA  +  1)
00058 #define APREQ_ERROR_BADSEQ         (APREQ_ERROR_BADDATA  +  2)
00060 #define APREQ_ERROR_BADATTR        (APREQ_ERROR_BADDATA  +  3)
00062 #define APREQ_ERROR_BADHEADER      (APREQ_ERROR_BADDATA  +  4)
00064 #define APREQ_ERROR_BADUTF8        (APREQ_ERROR_BADDATA  +  5)
00065 
00067 #define APREQ_ERROR_NODATA         (APREQ_ERROR_GENERAL  + 20)
00069 #define APREQ_ERROR_NOTOKEN        (APREQ_ERROR_NODATA   +  1)
00071 #define APREQ_ERROR_NOATTR         (APREQ_ERROR_NODATA   +  2)
00073 #define APREQ_ERROR_NOHEADER       (APREQ_ERROR_NODATA   +  3)
00075 #define APREQ_ERROR_NOPARSER       (APREQ_ERROR_NODATA   +  4)
00076 
00077 
00079 #define APREQ_ERROR_MISMATCH       (APREQ_ERROR_GENERAL  + 30)
00081 #define APREQ_ERROR_OVERLIMIT      (APREQ_ERROR_MISMATCH +  1)
00083 #define APREQ_ERROR_UNDERLIMIT     (APREQ_ERROR_MISMATCH +  2)
00085 #define APREQ_ERROR_NOTEMPTY       (APREQ_ERROR_MISMATCH +  3)
00086 
00087 
00088 #ifdef __cplusplus
00089  }
00090 #endif
00091 
00092 #endif /* APREQ_ERROR_H */
rapache-1.2.8/libapreq2/docs/html/apreq__error_8h.html0000644000175100017510000004723012706745114022212 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: include/apreq_error.h File Reference

apreq_error.h File Reference

Error status codes. More...

#include "apr_errno.h"
#include "apreq.h"

Go to the source code of this file.

Defines

#define APR_EBADARG   APR_BADARG
#define APREQ_ERROR_GENERAL   APR_OS_START_USERERR
#define APREQ_ERROR_TAINTED   (APREQ_ERROR_GENERAL + 1)
#define APREQ_ERROR_INTERRUPT   (APREQ_ERROR_GENERAL + 2)
#define APREQ_ERROR_BADDATA   (APREQ_ERROR_GENERAL + 10)
#define APREQ_ERROR_BADCHAR   (APREQ_ERROR_BADDATA + 1)
#define APREQ_ERROR_BADSEQ   (APREQ_ERROR_BADDATA + 2)
#define APREQ_ERROR_BADATTR   (APREQ_ERROR_BADDATA + 3)
#define APREQ_ERROR_BADHEADER   (APREQ_ERROR_BADDATA + 4)
#define APREQ_ERROR_BADUTF8   (APREQ_ERROR_BADDATA + 5)
#define APREQ_ERROR_NODATA   (APREQ_ERROR_GENERAL + 20)
#define APREQ_ERROR_NOTOKEN   (APREQ_ERROR_NODATA + 1)
#define APREQ_ERROR_NOATTR   (APREQ_ERROR_NODATA + 2)
#define APREQ_ERROR_NOHEADER   (APREQ_ERROR_NODATA + 3)
#define APREQ_ERROR_NOPARSER   (APREQ_ERROR_NODATA + 4)
#define APREQ_ERROR_MISMATCH   (APREQ_ERROR_GENERAL + 30)
#define APREQ_ERROR_OVERLIMIT   (APREQ_ERROR_MISMATCH + 1)
#define APREQ_ERROR_UNDERLIMIT   (APREQ_ERROR_MISMATCH + 2)
#define APREQ_ERROR_NOTEMPTY   (APREQ_ERROR_MISMATCH + 3)

Functions

char * apreq_strerror (apr_status_t s, char *buf, apr_size_t bufsize)


Detailed Description

Error status codes.

Define the APREQ_ error codes.


Define Documentation

#define APREQ_ERROR_BADATTR   (APREQ_ERROR_BADDATA + 3)
 

Invalid attribute.

#define APREQ_ERROR_BADCHAR   (APREQ_ERROR_BADDATA + 1)
 

Invalid character.

#define APREQ_ERROR_BADDATA   (APREQ_ERROR_GENERAL + 10)
 

Invalid input data.

#define APREQ_ERROR_BADHEADER   (APREQ_ERROR_BADDATA + 4)
 

Invalid header.

#define APREQ_ERROR_BADSEQ   (APREQ_ERROR_BADDATA + 2)
 

Invalid byte sequence.

#define APREQ_ERROR_BADUTF8   (APREQ_ERROR_BADDATA + 5)
 

Invalid utf8 encoding.

#define APREQ_ERROR_GENERAL   APR_OS_START_USERERR
 

Internal apreq error.

#define APREQ_ERROR_INTERRUPT   (APREQ_ERROR_GENERAL + 2)
 

Parsing interrupted.

#define APREQ_ERROR_MISMATCH   (APREQ_ERROR_GENERAL + 30)
 

Conflicting information.

#define APREQ_ERROR_NOATTR   (APREQ_ERROR_NODATA + 2)
 

Missing attribute.

#define APREQ_ERROR_NODATA   (APREQ_ERROR_GENERAL + 20)
 

Missing input data.

#define APREQ_ERROR_NOHEADER   (APREQ_ERROR_NODATA + 3)
 

Missing header.

#define APREQ_ERROR_NOPARSER   (APREQ_ERROR_NODATA + 4)
 

Missing parser.

#define APREQ_ERROR_NOTEMPTY   (APREQ_ERROR_MISMATCH + 3)
 

Setting already configured.

#define APREQ_ERROR_NOTOKEN   (APREQ_ERROR_NODATA + 1)
 

Missing required token.

#define APREQ_ERROR_OVERLIMIT   (APREQ_ERROR_MISMATCH + 1)
 

Exceeds configured maximum limit.

#define APREQ_ERROR_TAINTED   (APREQ_ERROR_GENERAL + 1)
 

Attempted to perform unsafe action with tainted data.

#define APREQ_ERROR_UNDERLIMIT   (APREQ_ERROR_MISMATCH + 2)
 

Below configured minimum limit.


Function Documentation

char* apreq_strerror apr_status_t  s,
char *  buf,
apr_size_t  bufsize
 

apreq's wrapper around apr_strerror(); recognizes APREQ_ERROR_* status codes.

rapache-1.2.8/libapreq2/docs/html/apreq__module_8h-source.html0000644000175100017510000010057212706745114023643 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: include/apreq_module.h Source File

apreq_module.h

Go to the documentation of this file.
00001 /*
00002 **  Copyright 2003-2005  The Apache Software Foundation
00003 **
00004 **  Licensed under the Apache License, Version 2.0 (the "License");
00005 **  you may not use this file except in compliance with the License.
00006 **  You may obtain a copy of the License at
00007 **
00008 **      http://www.apache.org/licenses/LICENSE-2.0
00009 **
00010 **  Unless required by applicable law or agreed to in writing, software
00011 **  distributed under the License is distributed on an "AS IS" BASIS,
00012 **  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
00013 **  See the License for the specific language governing permissions and
00014 **  limitations under the License.
00015 */
00016 
00017 #ifndef APREQ_MODULE_H
00018 #define APREQ_MODULE_H
00019 
00020 #include "apreq_cookie.h"
00021 #include "apreq_parser.h"
00022 #include "apreq_error.h"
00023 
00024 #ifdef  __cplusplus
00025  extern "C" {
00026 #endif 
00027 
00040 typedef struct apreq_handle_t {
00042     const struct apreq_module_t *module;
00044     apr_pool_t *pool;
00046     apr_bucket_alloc_t *bucket_alloc;
00047 
00048 } apreq_handle_t;
00049 
00055 typedef struct apreq_module_t {
00057     const char *name;
00059     apr_uint32_t magic_number;
00060 
00062     apr_status_t (*jar)(apreq_handle_t *, const apr_table_t **);
00064     apr_status_t (*args)(apreq_handle_t *, const apr_table_t **);
00066     apr_status_t (*body)(apreq_handle_t *, const apr_table_t **);
00067 
00069     apreq_cookie_t *(*jar_get)(apreq_handle_t *, const char *);
00071     apreq_param_t *(*args_get)(apreq_handle_t *, const char *);
00073     apreq_param_t *(*body_get)(apreq_handle_t *, const char *);
00074 
00076     apr_status_t (*parser_get)(apreq_handle_t *, const apreq_parser_t **);
00078     apr_status_t (*parser_set)(apreq_handle_t *, apreq_parser_t *);
00080     apr_status_t (*hook_add)(apreq_handle_t *, apreq_hook_t *);
00081 
00083     apr_status_t (*brigade_limit_get)(apreq_handle_t *, apr_size_t *);
00085     apr_status_t (*brigade_limit_set)(apreq_handle_t *, apr_size_t);
00086 
00088     apr_status_t (*read_limit_get)(apreq_handle_t *, apr_uint64_t *);
00090     apr_status_t (*read_limit_set)(apreq_handle_t *, apr_uint64_t);
00091 
00093     apr_status_t (*temp_dir_get)(apreq_handle_t *, const char **);
00095     apr_status_t (*temp_dir_set)(apreq_handle_t *, const char *);
00096 
00097 } apreq_module_t;
00098 
00099 
00108 static APR_INLINE
00109 unsigned apreq_module_status_is_error(apr_status_t s) {
00110     switch (s) {
00111     case APR_SUCCESS:
00112     case APR_INCOMPLETE:
00113     case APR_EINIT:
00114     case APREQ_ERROR_NODATA:
00115     case APREQ_ERROR_NOPARSER:
00116     case APREQ_ERROR_NOHEADER:
00117         return 0;
00118     default:
00119         return 1;
00120     }
00121 }
00122 
00123 
00133 static APR_INLINE
00134 apr_status_t apreq_jar(apreq_handle_t *req, const apr_table_t **t)
00135 {
00136     return req->module->jar(req,t);
00137 }
00138 
00148 static APR_INLINE
00149 apr_status_t apreq_args(apreq_handle_t *req, const apr_table_t **t)
00150 {
00151     return req->module->args(req,t);
00152 }
00153 
00163 static APR_INLINE
00164 apr_status_t apreq_body(apreq_handle_t *req, const apr_table_t **t)
00165 {
00166     return req->module->body(req, t);
00167 }
00168 
00169 
00178 static APR_INLINE
00179 apreq_cookie_t *apreq_jar_get(apreq_handle_t *req, const char *name)
00180 {
00181     return req->module->jar_get(req, name);
00182 }
00183 
00192 static APR_INLINE
00193 apreq_param_t *apreq_args_get(apreq_handle_t *req, const char *name)
00194 {
00195     return req->module->args_get(req, name);
00196 }
00197 
00206 static APR_INLINE
00207 apreq_param_t *apreq_body_get(apreq_handle_t *req, const char *name)
00208 {
00209     return req->module->body_get(req, name);
00210 }
00211 
00221 static APR_INLINE
00222 apr_status_t apreq_parser_get(apreq_handle_t *req,
00223                               const apreq_parser_t **parser)
00224 {
00225     return req->module->parser_get(req, parser);
00226 }
00227 
00228 
00237 static APR_INLINE
00238 apr_status_t apreq_parser_set(apreq_handle_t *req,
00239                               apreq_parser_t *parser)
00240 {
00241     return req->module->parser_set(req, parser);
00242 }
00243 
00252 static APR_INLINE
00253 apr_status_t apreq_hook_add(apreq_handle_t *req, apreq_hook_t *hook)
00254 {
00255     return req->module->hook_add(req, hook);
00256 }
00257 
00258 
00268 static APR_INLINE
00269 apr_status_t apreq_brigade_limit_set(apreq_handle_t *req,
00270                                      apr_size_t bytes)
00271 {
00272     return req->module->brigade_limit_set(req, bytes);
00273 }
00274 
00284 static APR_INLINE
00285 apr_status_t apreq_brigade_limit_get(apreq_handle_t *req,
00286                                      apr_size_t *bytes)
00287 {
00288     return req->module->brigade_limit_get(req, bytes);
00289 }
00290 
00300 static APR_INLINE
00301 apr_status_t apreq_read_limit_set(apreq_handle_t *req,
00302                                   apr_uint64_t bytes)
00303 {
00304     return req->module->read_limit_set(req, bytes);
00305 }
00306 
00316 static APR_INLINE
00317 apr_status_t apreq_read_limit_get(apreq_handle_t *req,
00318                                   apr_uint64_t *bytes)
00319 {
00320     return req->module->read_limit_get(req, bytes);
00321 }
00322 
00331 static APR_INLINE
00332 apr_status_t apreq_temp_dir_set(apreq_handle_t *req, const char *path)
00333 {
00334     return req->module->temp_dir_set(req, path);
00335 }
00336 
00347 static APR_INLINE
00348 apr_status_t apreq_temp_dir_get(apreq_handle_t *req, const char **path)
00349 {
00350     return req->module->temp_dir_get(req, path);
00351 }
00352 
00353 
00354 
00365 #define APREQ_MODULE(pre, mmn) const apreq_module_t     \
00366   pre##_module = { #pre, mmn,                           \
00367   pre##_jar,        pre##_args,       pre##_body,       \
00368   pre##_jar_get,    pre##_args_get,   pre##_body_get,   \
00369   pre##_parser_get, pre##_parser_set, pre##_hook_add,   \
00370   pre##_brigade_limit_get, pre##_brigade_limit_set,     \
00371   pre##_read_limit_get,    pre##_read_limit_set,        \
00372   pre##_temp_dir_get,      pre##_temp_dir_set,          \
00373   }
00374 
00375 
00387 APREQ_DECLARE(apreq_handle_t*) apreq_handle_cgi(apr_pool_t *pool);
00388 
00403 APREQ_DECLARE(apreq_handle_t*) apreq_handle_custom(apr_pool_t *pool,
00404                                                    const char *query_string,
00405                                                    const char *cookie,
00406                                                    apreq_parser_t *parser,
00407                                                    apr_uint64_t read_limit,
00408                                                    apr_bucket_brigade *in);
00409 
00418 APREQ_DECLARE(apr_status_t) apreq_cookie_bake(const apreq_cookie_t *c,
00419                                               apreq_handle_t *req);
00420 
00429 APREQ_DECLARE(apr_status_t) apreq_cookie_bake2(const apreq_cookie_t *c,
00430                                                apreq_handle_t *req);
00431 
00442 APREQ_DECLARE(unsigned)apreq_ua_cookie_version(apreq_handle_t *req);
00443 
00453 APREQ_DECLARE(apreq_param_t *)apreq_param(apreq_handle_t *req, const char *key);
00454 
00464 #define apreq_cookie(req, name) apreq_jar_get(req, name)
00465 
00475 APREQ_DECLARE(apr_table_t *) apreq_params(apreq_handle_t *req, apr_pool_t *p);
00476 
00477 
00484 APREQ_DECLARE(apr_table_t *)apreq_cookies(apreq_handle_t *req, apr_pool_t *p);
00485 
00494 static APR_INLINE
00495 apr_status_t apreq_parse(apreq_handle_t *req)
00496 {
00497     const apr_table_t *dummy;
00498     apr_status_t jar_status, args_status, body_status;
00499 
00500     jar_status = apreq_jar(req, &dummy);
00501     args_status = apreq_args(req, &dummy);
00502     body_status = apreq_body(req, &dummy);
00503 
00504     /* XXX: punt to APREQ_ERROR_GENERAL; need to improve this
00505      * for valid requests where certain data/headers are 
00506      * unavailable.
00507      */
00508     if (jar_status || args_status || body_status)
00509         return APREQ_ERROR_GENERAL;
00510 
00511     return APR_SUCCESS;
00512 }
00513 
00514 #ifdef __cplusplus
00515  }
00516 #endif
00517 
00518 #endif /* APREQ_MODULE_H */
rapache-1.2.8/libapreq2/docs/html/apreq__module_8h.html0000644000175100017510000021345012706745114022345 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: include/apreq_module.h File Reference

apreq_module.h File Reference

Module API. More...

#include "apreq_cookie.h"
#include "apreq_parser.h"
#include "apreq_error.h"

Go to the source code of this file.

Defines

#define APREQ_MODULE(pre, mmn)
#define apreq_cookie(req, name)   apreq_jar_get(req, name)

Typedefs

typedef apreq_handle_t apreq_handle_t
typedef apreq_module_t apreq_module_t
 Vtable describing the necessary environment functions.

Functions

static APR_INLINE unsigned apreq_module_status_is_error (apr_status_t s)
static APR_INLINE apr_status_t apreq_jar (apreq_handle_t *req, const apr_table_t **t)
static APR_INLINE apr_status_t apreq_args (apreq_handle_t *req, const apr_table_t **t)
static APR_INLINE apr_status_t apreq_body (apreq_handle_t *req, const apr_table_t **t)
static APR_INLINE apreq_cookie_tapreq_jar_get (apreq_handle_t *req, const char *name)
static APR_INLINE apreq_param_tapreq_args_get (apreq_handle_t *req, const char *name)
static APR_INLINE apreq_param_tapreq_body_get (apreq_handle_t *req, const char *name)
static APR_INLINE apr_status_t apreq_parser_get (apreq_handle_t *req, const apreq_parser_t **parser)
static APR_INLINE apr_status_t apreq_parser_set (apreq_handle_t *req, apreq_parser_t *parser)
static APR_INLINE apr_status_t apreq_hook_add (apreq_handle_t *req, apreq_hook_t *hook)
static APR_INLINE apr_status_t apreq_brigade_limit_set (apreq_handle_t *req, apr_size_t bytes)
static APR_INLINE apr_status_t apreq_brigade_limit_get (apreq_handle_t *req, apr_size_t *bytes)
static APR_INLINE apr_status_t apreq_read_limit_set (apreq_handle_t *req, apr_uint64_t bytes)
static APR_INLINE apr_status_t apreq_read_limit_get (apreq_handle_t *req, apr_uint64_t *bytes)
static APR_INLINE apr_status_t apreq_temp_dir_set (apreq_handle_t *req, const char *path)
static APR_INLINE apr_status_t apreq_temp_dir_get (apreq_handle_t *req, const char **path)
apreq_handle_tapreq_handle_cgi (apr_pool_t *pool)
apreq_handle_tapreq_handle_custom (apr_pool_t *pool, const char *query_string, const char *cookie, apreq_parser_t *parser, apr_uint64_t read_limit, apr_bucket_brigade *in)
apr_status_t apreq_cookie_bake (const apreq_cookie_t *c, apreq_handle_t *req)
apr_status_t apreq_cookie_bake2 (const apreq_cookie_t *c, apreq_handle_t *req)
unsigned apreq_ua_cookie_version (apreq_handle_t *req)
apreq_param_tapreq_param (apreq_handle_t *req, const char *key)
apr_table_tapreq_params (apreq_handle_t *req, apr_pool_t *p)
apr_table_tapreq_cookies (apreq_handle_t *req, apr_pool_t *p)
static APR_INLINE apr_status_t apreq_parse (apreq_handle_t *req)


Detailed Description

Module API.


Define Documentation

#define apreq_cookie req,
name   )     apreq_jar_get(req, name)
 

Find the first cookie with the specified name. The match is case-insensitive.

Parameters:
req request handle.
key desired cookie name
Returns:
The first matching parameter (with args searched first) or NULL.

#define APREQ_MODULE pre,
mmn   ) 
 

Value:

const apreq_module_t     \
  pre##_module = { #pre, mmn,                           \
  pre##_jar,        pre##_args,       pre##_body,       \
  pre##_jar_get,    pre##_args_get,   pre##_body_get,   \
  pre##_parser_get, pre##_parser_set, pre##_hook_add,   \
  pre##_brigade_limit_get, pre##_brigade_limit_set,     \
  pre##_read_limit_get,    pre##_read_limit_set,        \
  pre##_temp_dir_get,      pre##_temp_dir_set,          \
  }
Convenience macro for defining a module by mapping a function prefix to an associated apreq_module_t structure.

Parameters:
pre Prefix to define new environment. All attributes of the apreq_env_module_t struct are defined with this as their prefix. The generated struct is named by appending "_module" to the prefix.
mmn Magic number (i.e. version number) of this environment.


Typedef Documentation

typedef struct apreq_handle_t apreq_handle_t
 

An apreq handle associated with a module. The structure may have variable size, because the module may append its own data structures after it.


Function Documentation

static APR_INLINE apr_status_t apreq_args apreq_handle_t req,
const apr_table_t **  t
[static]
 

Expose the parsed "query string" associated to this handle.

Parameters:
req The request handle
t The resulting table, which will either be NULL or a valid table object on return.
Returns:
APR_SUCCESS or a module-specific error status code.

static APR_INLINE apreq_param_t* apreq_args_get apreq_handle_t req,
const char *  name
[static]
 

Fetch the first query string param with the given name.

Parameters:
req The request handle
name Case-insensitive param name.
Returns:
First matching param, or NULL if none match.

static APR_INLINE apr_status_t apreq_body apreq_handle_t req,
const apr_table_t **  t
[static]
 

Expose the parsed "request body" associated to this handle.

Parameters:
req The request handle
t The resulting table, which will either be NULL or a valid table object on return.
Returns:
APR_SUCCESS or a module-specific error status code.

static APR_INLINE apreq_param_t* apreq_body_get apreq_handle_t req,
const char *  name
[static]
 

Fetch the first body param with the given name.

Parameters:
req The request handle
name Case-insensitive cookie name.
Returns:
First matching param, or NULL if none match.

static APR_INLINE apr_status_t apreq_brigade_limit_get apreq_handle_t req,
apr_size_t bytes
[static]
 

Get the active brigade limit.

Parameters:
req The handle.
bytes Pointer to resulting (current) limit.
Returns:
APR_SUCCESS or a module-specific error, which may leave bytes undefined.

static APR_INLINE apr_status_t apreq_brigade_limit_set apreq_handle_t req,
apr_size_t  bytes
[static]
 

Set the active brigade limit.

Parameters:
req The handle.
bytes New limit to use.
Returns:
APR_SUCCESS or module-specific error.

apr_status_t apreq_cookie_bake const apreq_cookie_t c,
apreq_handle_t req
 

Add the cookie to the outgoing "Set-Cookie" headers.

Parameters:
c The cookie.
req The request handle which set the outgoing header.
Returns:
APR_SUCCESS or error.

apr_status_t apreq_cookie_bake2 const apreq_cookie_t c,
apreq_handle_t req
 

Add the cookie to the outgoing "Set-Cookie2" headers.

Parameters:
c cookie
req request handle
Returns:
APR_SUCCESS or error.

apr_table_t* apreq_cookies apreq_handle_t req,
apr_pool_t p
 

Returns a table containing all request cookies.

Parameters:
req the apreq request handle
p Allocates the returned table.

apreq_handle_t* apreq_handle_cgi apr_pool_t pool  ) 
 

Create an apreq handle which is suitable for a CGI program. It reads input from stdin and writes output to stdout.

Parameters:
pool Pool associated to this handle.
Returns:
New handle; can only be NULL if the pool allocation failed.
Remarks:
The handle gets cached in the pool's userdata, so subsequent calls will retrieve the original cached handle.

apreq_handle_t* apreq_handle_custom apr_pool_t pool,
const char *  query_string,
const char *  cookie,
apreq_parser_t parser,
apr_uint64_t  read_limit,
apr_bucket_brigade in
 

Create a custom apreq handle which knows only some static values. Useful if you want to test the parser code or if you have got data from a custom source (neither Apache 2 nor CGI).

Parameters:
pool allocates the parse data,
query_string parsed into args table
cookie value of the request "Cookie" header
parser parses the request body
read_limit maximum bytes to read from the body
in brigade containing the request body
Returns:
new handle; can only be NULL if the pool allocation failed.

static APR_INLINE apr_status_t apreq_hook_add apreq_handle_t req,
apreq_hook_t hook
[static]
 

Add a parser hook for this request.

Parameters:
req The request handle
hook Hook to add.
Returns:
APR_SUCCESS or module-specific error.

static APR_INLINE apr_status_t apreq_jar apreq_handle_t req,
const apr_table_t **  t
[static]
 

Expose the parsed "cookie" header associated to this handle.

Parameters:
req The request handle
t The resulting table, which will either be NULL or a valid table object on return.
Returns:
APR_SUCCESS or a module-specific error status code.

static APR_INLINE apreq_cookie_t* apreq_jar_get apreq_handle_t req,
const char *  name
[static]
 

Fetch the first cookie with the given name.

Parameters:
req The request handle
name Case-insensitive cookie name.
Returns:
First matching cookie, or NULL if none match.

static APR_INLINE unsigned apreq_module_status_is_error apr_status_t  s  )  [static]
 

Defines the module-specific status codes which are commonly considered to be non-fatal.

Parameters:
s status code returned by an apreq_module_t method.
Returns:
1 if s is fatal, 0 otherwise.

apreq_param_t* apreq_param apreq_handle_t req,
const char *  key
 

Find the first query string parameter or body parameter with the specified name. The match is case-insensitive.

Parameters:
req request handle.
key desired parameter name
Returns:
The first matching parameter (with args searched first) or NULL.

apr_table_t* apreq_params apreq_handle_t req,
apr_pool_t p
 

Returns a table containing key-value pairs for the full request (args + body).

Parameters:
req request handle
p allocates the returned table.
Returns:
table representing all available params; is never NULL.

static APR_INLINE apr_status_t apreq_parse apreq_handle_t req  )  [static]
 

Force a complete parse of everything.

Parameters:
req The request handle
Returns:
APR_SUCCESS on an error-free parse of the request data. Any other status code indicates a potential problem somewhere.

static APR_INLINE apr_status_t apreq_parser_get apreq_handle_t req,
const apreq_parser_t **  parser
[static]
 

Fetch the active body parser.

Parameters:
req The request handle
parser Points to the active parser on return.
Returns:
APR_SUCCESS or module-specific error.

static APR_INLINE apr_status_t apreq_parser_set apreq_handle_t req,
apreq_parser_t parser
[static]
 

Set the body parser for this request.

Parameters:
req The request handle
parser New parser to use.
Returns:
APR_SUCCESS or module-specific error.

static APR_INLINE apr_status_t apreq_read_limit_get apreq_handle_t req,
apr_uint64_t bytes
[static]
 

Get the active read limit.

Parameters:
req The request handle.
bytes Pointer to resulting (current) limit.
Returns:
APR_SUCCESS or a module-specific error, which may leave bytes undefined.

static APR_INLINE apr_status_t apreq_read_limit_set apreq_handle_t req,
apr_uint64_t  bytes
[static]
 

Set the active read limit.

Parameters:
req The handle.
bytes New limit to use.
Returns:
APR_SUCCESS or a module-specific error.

static APR_INLINE apr_status_t apreq_temp_dir_get apreq_handle_t req,
const char **  path
[static]
 

Get the active temp directory.

Parameters:
req The handle.
path Resulting path to temp dir.
Returns:
APR_SUCCESS implies path is valid, but may also be NULL. Any other return value is module-specific, and may leave path undefined.

static APR_INLINE apr_status_t apreq_temp_dir_set apreq_handle_t req,
const char *  path
[static]
 

Set the active temp directory.

Parameters:
req The handle.
path New path to use; may be NULL.
Returns:
APR_SUCCESS or a module-specific error .

unsigned apreq_ua_cookie_version apreq_handle_t req  ) 
 

Looks for the presence of a "Cookie2" header to determine whether or not the current User-Agent responsible for this request supports rfc2965.

Parameters:
req the apreq request handle
Returns:
::APREQ_COOKIE_VERSION_RFC if rfc2965 is supported by the user-agent, ::APREQ_COOKIE_VERSION_NETSCAPE otherwise.

rapache-1.2.8/libapreq2/docs/html/apreq__module__apache2_8h-source.html0000644000175100017510000000722012706745114025361 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: module/apache2/apreq_module_apache2.h Source File

apreq_module_apache2.h

00001 /*
00002 **  Copyright 2003-2005  The Apache Software Foundation
00003 **
00004 **  Licensed under the Apache License, Version 2.0 (the "License");
00005 **  you may not use this file except in compliance with the License.
00006 **  You may obtain a copy of the License at
00007 **
00008 **      http://www.apache.org/licenses/LICENSE-2.0
00009 **
00010 **  Unless required by applicable law or agreed to in writing, software
00011 **  distributed under the License is distributed on an "AS IS" BASIS,
00012 **  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
00013 **  See the License for the specific language governing permissions and
00014 **  limitations under the License.
00015 */
00016 
00017 #ifndef APREQ_APACHE2_H
00018 #define APREQ_APACHE2_H
00019 
00020 #include "apreq_module.h"
00021 #include <httpd.h>
00022 
00023 #ifdef  __cplusplus
00024  extern "C" {
00025 #endif
00026 
00027 
00140 APREQ_DECLARE(apreq_handle_t*) apreq_handle_apache2(request_rec *r);
00141 
00144 #ifdef __cplusplus
00145  }
00146 #endif
00147 
00148 #endif
rapache-1.2.8/libapreq2/docs/html/apreq__module__apache_8h-source.html0000644000175100017510000001027712706745114025305 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: module/apache/apreq_module_apache.h Source File

apreq_module_apache.h

00001 /*
00002 **  Copyright 2003-2005  The Apache Software Foundation
00003 **
00004 **  Licensed under the Apache License, Version 2.0 (the "License");
00005 **  you may not use this file except in compliance with the License.
00006 **  You may obtain a copy of the License at
00007 **
00008 **      http://www.apache.org/licenses/LICENSE-2.0
00009 **
00010 **  Unless required by applicable law or agreed to in writing, software
00011 **  distributed under the License is distributed on an "AS IS" BASIS,
00012 **  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
00013 **  See the License for the specific language governing permissions and
00014 **  limitations under the License.
00015 */
00016 
00017 #ifndef APREQ_APACHE_H
00018 #define APREQ_APACHE_H
00019 
00020 #include "apreq_module.h"
00021 #include <httpd.h>
00022 
00023 #ifdef  __cplusplus
00024  extern "C" {
00025 #endif
00026 
00031 APREQ_DECLARE(apreq_handle_t*) apreq_handle_apache(request_rec *r);
00032 
00033 
00034 APREQ_DECLARE(apr_pool_t *) apreq_handle_apache_pool(apreq_handle_t *req);
00035 
00036 APREQ_DECLARE(apr_bucket_alloc_t *)
00037     apreq_handle_apache_bucket_alloc(apreq_handle_t *req);
00038 
00039 #ifdef __cplusplus
00040  }
00041 #endif
00042 
00043 #endif
rapache-1.2.8/libapreq2/docs/html/apreq__param_8h-source.html0000644000175100017510000003601212706745114023453 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: include/apreq_param.h Source File

apreq_param.h

Go to the documentation of this file.
00001 /*
00002 **  Copyright 2003-2005  The Apache Software Foundation
00003 **
00004 **  Licensed under the Apache License, Version 2.0 (the "License");
00005 **  you may not use this file except in compliance with the License.
00006 **  You may obtain a copy of the License at
00007 **
00008 **      http://www.apache.org/licenses/LICENSE-2.0
00009 **
00010 **  Unless required by applicable law or agreed to in writing, software
00011 **  distributed under the License is distributed on an "AS IS" BASIS,
00012 **  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
00013 **  See the License for the specific language governing permissions and
00014 **  limitations under the License.
00015 */
00016 
00017 #ifndef APREQ_PARAM_H
00018 #define APREQ_PARAM_H
00019 
00020 #include "apreq.h"
00021 #include "apr_buckets.h"
00022 
00023 #ifdef __cplusplus
00024 extern "C" {
00025 #endif
00026 
00027 
00036 typedef struct apreq_param_t {
00037     apr_table_t         *info;   
00038     apr_bucket_brigade  *upload; 
00039     unsigned             flags;  
00040     const apreq_value_t  v;      
00041 } apreq_param_t;
00042 
00043 
00045 static APR_INLINE
00046 unsigned apreq_param_is_tainted(const apreq_param_t *p) {
00047     return APREQ_FLAGS_GET(p->flags, APREQ_TAINTED);
00048 }
00049 
00051 static APR_INLINE
00052 void apreq_param_tainted_on(apreq_param_t *p) {
00053     APREQ_FLAGS_ON(p->flags, APREQ_TAINTED);
00054 }
00055 
00057 static APR_INLINE
00058 void apreq_param_tainted_off(apreq_param_t *p) {
00059     APREQ_FLAGS_OFF(p->flags, APREQ_TAINTED);
00060 }
00061 
00063 static APR_INLINE
00064 apreq_charset_t apreq_param_charset_set(apreq_param_t *p, unsigned char c) {
00065     unsigned char old = APREQ_FLAGS_GET(p->flags, APREQ_CHARSET);
00066     APREQ_FLAGS_SET(p->flags, APREQ_CHARSET, c);
00067     return old;
00068 }
00069 
00071 static APR_INLINE
00072 apreq_charset_t apreq_param_charset_get(apreq_param_t *p) {
00073     return APREQ_FLAGS_GET(p->flags, APREQ_CHARSET);
00074 }
00075 
00076 
00078 static APR_INLINE
00079 apreq_param_t *apreq_value_to_param(const char *val)
00080 {
00081     union { const char *in; char *out; } deconst;
00082 
00083     deconst.in = val;
00084     return apreq_attr_to_type(apreq_param_t, v,
00085            apreq_attr_to_type(apreq_value_t, data, deconst.out));
00086 }
00087 
00088 
00089 
00091 APREQ_DECLARE(apreq_param_t *) apreq_param_make(apr_pool_t *p,
00092                                                 const char *name,
00093                                                 const apr_size_t nlen,
00094                                                 const char *val,
00095                                                 const apr_size_t vlen);
00096 
00113 APREQ_DECLARE(apr_status_t) apreq_param_decode(apreq_param_t **param,
00114                                                apr_pool_t *pool,
00115                                                const char *word,
00116                                                apr_size_t nlen,
00117                                                apr_size_t vlen);
00118 
00125 APREQ_DECLARE(char *) apreq_param_encode(apr_pool_t *pool,
00126                                          const apreq_param_t *param);
00127 
00139 APREQ_DECLARE(apr_status_t) apreq_parse_query_string(apr_pool_t *pool,
00140                                                      apr_table_t *t,
00141                                                      const char *qs);
00142 
00143 
00155 APREQ_DECLARE(apr_array_header_t *) apreq_params_as_array(apr_pool_t *p,
00156                                                           const apr_table_t *t,
00157                                                           const char *key);
00158 
00173 APREQ_DECLARE(const char *) apreq_params_as_string(apr_pool_t *p,
00174                                                    const apr_table_t *t,
00175                                                    const char *key,
00176                                                    apreq_join_t mode);
00177 
00185 APREQ_DECLARE(const apr_table_t *) apreq_uploads(const apr_table_t *body,
00186                                                  apr_pool_t *pool);
00187 
00196 APREQ_DECLARE(const apreq_param_t *) apreq_upload(const apr_table_t *body,
00197                                                   const char *name);
00198 
00199 
00200 #ifdef __cplusplus
00201 }
00202 #endif
00203 
00204 #endif /* APREQ_PARAM_H */
00205 
00206 
00207 
rapache-1.2.8/libapreq2/docs/html/apreq__param_8h.html0000644000175100017510000011236612706745114022164 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: include/apreq_param.h File Reference

apreq_param.h File Reference

Request parsing and parameter API. More...

#include "apreq.h"
#include "apr_buckets.h"

Go to the source code of this file.

Typedefs

typedef apreq_param_t apreq_param_t

Functions

static APR_INLINE unsigned apreq_param_is_tainted (const apreq_param_t *p)
static APR_INLINE void apreq_param_tainted_on (apreq_param_t *p)
static APR_INLINE void apreq_param_tainted_off (apreq_param_t *p)
static APR_INLINE apreq_charset_t apreq_param_charset_set (apreq_param_t *p, unsigned char c)
static APR_INLINE apreq_charset_t apreq_param_charset_get (apreq_param_t *p)
static APR_INLINE apreq_param_tapreq_value_to_param (const char *val)
apreq_param_tapreq_param_make (apr_pool_t *p, const char *name, const apr_size_t nlen, const char *val, const apr_size_t vlen)
apr_status_t apreq_param_decode (apreq_param_t **param, apr_pool_t *pool, const char *word, apr_size_t nlen, apr_size_t vlen)
char * apreq_param_encode (apr_pool_t *pool, const apreq_param_t *param)
apr_status_t apreq_parse_query_string (apr_pool_t *pool, apr_table_t *t, const char *qs)
apr_array_header_tapreq_params_as_array (apr_pool_t *p, const apr_table_t *t, const char *key)
const char * apreq_params_as_string (apr_pool_t *p, const apr_table_t *t, const char *key, apreq_join_t mode)
const apr_table_tapreq_uploads (const apr_table_t *body, apr_pool_t *pool)
const apreq_param_tapreq_upload (const apr_table_t *body, const char *name)


Detailed Description

Request parsing and parameter API.


Typedef Documentation

typedef struct apreq_param_t apreq_param_t
 

Common data structure for params and file uploads


Function Documentation

static APR_INLINE apreq_charset_t apreq_param_charset_get apreq_param_t p  )  [static]
 

Gets the character encoding for this parameter.

static APR_INLINE apreq_charset_t apreq_param_charset_set apreq_param_t p,
unsigned char  c
[static]
 

Sets the character encoding for this parameter.

apr_status_t apreq_param_decode apreq_param_t **  param,
apr_pool_t pool,
const char *  word,
apr_size_t  nlen,
apr_size_t  vlen
 

Url-decodes a name=value pair into a param.

Parameters:
param points to the decoded parameter on success
pool Pool from which the param is allocated.
word Start of the name=value pair.
nlen Length of urlencoded name.
vlen Length of urlencoded value.
Returns:
APR_SUCCESS + apreq_charset_t (<=APREQ_CHARSET_UTF8) on success.

APREQ_ERROR_BADSEQ or APREQ_ERROR_BADCHAR on malformed input.

Remarks:
Unless vlen == 0, this function assumes there is exactly one character ('=') which separates the pair.

char* apreq_param_encode apr_pool_t pool,
const apreq_param_t param
 

Url-encodes the param into a name-value pair.

Parameters:
pool Pool which allocates the returned string.
param Param to encode.
Returns:
name-value pair representing the param.

static APR_INLINE unsigned apreq_param_is_tainted const apreq_param_t p  )  [static]
 

Returns:
1 if the taint flag is set, 0 otherwise.

apreq_param_t* apreq_param_make apr_pool_t p,
const char *  name,
const apr_size_t  nlen,
const char *  val,
const apr_size_t  vlen
 

creates a param from name/value information

static APR_INLINE void apreq_param_tainted_off apreq_param_t p  )  [static]
 

Turns off the taint flag.

static APR_INLINE void apreq_param_tainted_on apreq_param_t p  )  [static]
 

Sets the tainted flag.

apr_array_header_t* apreq_params_as_array apr_pool_t p,
const apr_table_t t,
const char *  key
 

Returns an array of parameters (apreq_param_t *) matching the given key. The key is case-insensitive.

Parameters:
p Allocates the returned array.
t the parameter table returned by apreq_args(), apreq_body() or apreq_params()
key Null-terminated search key, case insensitive. key==NULL fetches all parameters.
Returns:
an array of apreq_param_t* (pointers)
Remarks:
Also parses the request if necessary.

const char* apreq_params_as_string apr_pool_t p,
const apr_table_t t,
const char *  key,
apreq_join_t  mode
 

Returns a ", " -joined string containing all parameters for the requested key, an empty string if none are found. The key is case-insensitive.

Parameters:
p Allocates the return string.
t the parameter table returned by apreq_args(), apreq_body() or apreq_params()
key Null-terminated parameter name, case insensitive. key==NULL fetches all values.
mode Join type- see apreq_join().
Returns:
the joined string or NULL on error
Remarks:
Also parses the request if necessary.

apr_status_t apreq_parse_query_string apr_pool_t pool,
apr_table_t t,
const char *  qs
 

Parse a url-encoded string into a param table.

Parameters:
pool pool used to allocate the param data.
t table to which the params are added.
qs Query string to url-decode.
Returns:
APR_SUCCESS if successful, error otherwise.
Remarks:
This function uses [&;] as the set of tokens to delineate words, and will treat a word w/o '=' as a name-value pair with value-length = 0.

const apreq_param_t* apreq_upload const apr_table_t body,
const char *  name
 

Returns the first param in req->body which has both param->v.name matching key (case insensitive) and param->upload != NULL.

Parameters:
body parameter table returned by apreq_body() or apreq_params()
name Parameter name. key == NULL returns first upload.
Returns:
Corresponding upload, NULL if none found.
Remarks:
Will parse the request as necessary.

const apr_table_t* apreq_uploads const apr_table_t body,
apr_pool_t pool
 

Returns a table of all params in req->body with non-NULL upload brigades.

Parameters:
body parameter table returned by apreq_body() or apreq_params()
pool Pool which allocates the table struct.
Returns:
Upload table.
Remarks:
Will parse the request if necessary.

static APR_INLINE apreq_param_t* apreq_value_to_param const char *  val  )  [static]
 

Upgrades args and body table values to apreq_param_t structs.

rapache-1.2.8/libapreq2/docs/html/apreq__parser_8h-source.html0000644000175100017510000003614312706745114023654 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: include/apreq_parser.h Source File

apreq_parser.h

Go to the documentation of this file.
00001 /*
00002 **  Copyright 2003-2005  The Apache Software Foundation
00003 **
00004 **  Licensed under the Apache License, Version 2.0 (the "License");
00005 **  you may not use this file except in compliance with the License.
00006 **  You may obtain a copy of the License at
00007 **
00008 **      http://www.apache.org/licenses/LICENSE-2.0
00009 **
00010 **  Unless required by applicable law or agreed to in writing, software
00011 **  distributed under the License is distributed on an "AS IS" BASIS,
00012 **  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
00013 **  See the License for the specific language governing permissions and
00014 **  limitations under the License.
00015 */
00016 
00017 #ifndef APREQ_PARSERS_H
00018 #define APREQ_PARSERS_H
00019 /* These structs are defined below */
00020 
00021 #include "apreq_param.h"
00022 
00023 #ifdef __cplusplus
00024 extern "C" {
00025 #endif /* __cplusplus */
00026 
00038 typedef struct apreq_hook_t apreq_hook_t;
00039 
00043 typedef struct apreq_parser_t apreq_parser_t;
00044 
00046 #define APREQ_PARSER_ARGS  apreq_parser_t *parser,     \
00047                            apr_table_t *t,             \
00048                            apr_bucket_brigade *bb
00049 
00051 #define APREQ_HOOK_ARGS    apreq_hook_t *hook,         \
00052                            apreq_param_t *param,       \
00053                            apr_bucket_brigade *bb
00054 
00058 typedef apr_status_t (*apreq_parser_function_t)(APREQ_PARSER_ARGS);
00059 
00063 typedef apr_status_t (*apreq_hook_function_t)(APREQ_HOOK_ARGS);
00064 
00068 #define APREQ_DECLARE_PARSER(f) APREQ_DECLARE_NONSTD(apr_status_t) \
00069                                 (f) (APREQ_PARSER_ARGS)
00070 
00074 #define APREQ_DECLARE_HOOK(f)   APREQ_DECLARE_NONSTD(apr_status_t) \
00075                                 (f) (APREQ_HOOK_ARGS)
00076 
00082 struct apreq_hook_t {
00083     apreq_hook_function_t hook; 
00084     apreq_hook_t         *next; 
00085     apr_pool_t           *pool; 
00086     void *ctx; 
00087 };
00088 
00092 struct apreq_parser_t {
00094     apreq_parser_function_t parser;
00096     const char             *content_type;
00098     apr_pool_t             *pool;
00100     apr_bucket_alloc_t     *bucket_alloc;
00102     apr_size_t              brigade_limit;
00104     const char             *temp_dir;
00106     apreq_hook_t           *hook;
00108     void                   *ctx;
00109 };
00110 
00111 
00122 static APR_INLINE
00123 apr_status_t apreq_parser_run(struct apreq_parser_t *psr, apr_table_t *t,
00124                               apr_bucket_brigade *bb)
00125 {
00126     return psr->parser(psr, t, bb);
00127 }
00128 
00136 static APR_INLINE
00137 apr_status_t apreq_hook_run(struct apreq_hook_t *h, apreq_param_t *param,
00138                             apr_bucket_brigade *bb)
00139 {
00140     return h->hook(h, param, bb);
00141 }
00142 
00143 
00149 APREQ_DECLARE_PARSER(apreq_parse_headers);
00150 
00154 APREQ_DECLARE_PARSER(apreq_parse_urlencoded);
00155 
00162 APREQ_DECLARE_PARSER(apreq_parse_multipart);
00163 
00172 APREQ_DECLARE_PARSER(apreq_parse_generic);
00173 
00181 APREQ_DECLARE_HOOK(apreq_hook_apr_xml_parser);
00182 
00196 APREQ_DECLARE(apreq_parser_t *) apreq_parser_make(apr_pool_t *pool,
00197                                                   apr_bucket_alloc_t *ba,
00198                                                   const char *content_type,
00199                                                   apreq_parser_function_t pfn,
00200                                                   apr_size_t brigade_limit,
00201                                                   const char *temp_dir,
00202                                                   apreq_hook_t *hook,
00203                                                   void *ctx);
00204 
00214 APREQ_DECLARE(apreq_hook_t *) apreq_hook_make(apr_pool_t *pool,
00215                                               apreq_hook_function_t hook,
00216                                               apreq_hook_t *next,
00217                                               void *ctx);
00218 
00219 
00226 APREQ_DECLARE(apr_status_t) apreq_parser_add_hook(apreq_parser_t *p, 
00227                                                   apreq_hook_t *h);
00228 
00229 
00236 APREQ_DECLARE(apreq_parser_function_t)apreq_parser(const char *enctype);
00237 
00238 
00251 APREQ_DECLARE(apr_status_t) apreq_register_parser(const char *enctype,
00252                                                   apreq_parser_function_t pfn);
00253 
00254 
00260 APREQ_DECLARE_HOOK(apreq_hook_disable_uploads);
00261 
00266 APREQ_DECLARE_HOOK(apreq_hook_discard_brigade);
00267 
00279 APREQ_DECLARE_HOOK(apreq_hook_find_param);
00280 
00281 
00282 #ifdef __cplusplus
00283 }
00284 
00285 #endif
00286 #endif /* APREQ_PARSERS_H */
rapache-1.2.8/libapreq2/docs/html/apreq__parser_8h.html0000644000175100017510000012331712706745114022356 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: include/apreq_parser.h File Reference

apreq_parser.h File Reference

Request body parser API. More...

#include "apreq_param.h"

Go to the source code of this file.

Defines

#define APREQ_PARSER_ARGS
#define APREQ_HOOK_ARGS
#define APREQ_DECLARE_PARSER(f)
#define APREQ_DECLARE_HOOK(f)

Typedefs

typedef apreq_hook_t apreq_hook_t
typedef apreq_parser_t apreq_parser_t
typedef apr_status_t(* apreq_parser_function_t )(APREQ_PARSER_ARGS)
typedef apr_status_t(* apreq_hook_function_t )(APREQ_HOOK_ARGS)

Functions

static APR_INLINE apr_status_t apreq_parser_run (struct apreq_parser_t *psr, apr_table_t *t, apr_bucket_brigade *bb)
static APR_INLINE apr_status_t apreq_hook_run (struct apreq_hook_t *h, apreq_param_t *param, apr_bucket_brigade *bb)
 APREQ_DECLARE_PARSER (apreq_parse_headers)
 APREQ_DECLARE_PARSER (apreq_parse_urlencoded)
 APREQ_DECLARE_PARSER (apreq_parse_multipart)
 APREQ_DECLARE_PARSER (apreq_parse_generic)
 APREQ_DECLARE_HOOK (apreq_hook_apr_xml_parser)
apreq_parser_tapreq_parser_make (apr_pool_t *pool, apr_bucket_alloc_t *ba, const char *content_type, apreq_parser_function_t pfn, apr_size_t brigade_limit, const char *temp_dir, apreq_hook_t *hook, void *ctx)
apreq_hook_tapreq_hook_make (apr_pool_t *pool, apreq_hook_function_t hook, apreq_hook_t *next, void *ctx)
apr_status_t apreq_parser_add_hook (apreq_parser_t *p, apreq_hook_t *h)
apreq_parser_function_t apreq_parser (const char *enctype)
apr_status_t apreq_register_parser (const char *enctype, apreq_parser_function_t pfn)
 APREQ_DECLARE_HOOK (apreq_hook_disable_uploads)
 APREQ_DECLARE_HOOK (apreq_hook_discard_brigade)
 APREQ_DECLARE_HOOK (apreq_hook_find_param)


Detailed Description

Request body parser API.


Define Documentation

#define APREQ_DECLARE_HOOK  ) 
 

Value:

APREQ_DECLARE_NONSTD(apr_status_t) \
                                (f) (APREQ_HOOK_ARGS)
Declares an API hook.

#define APREQ_DECLARE_PARSER  ) 
 

Value:

APREQ_DECLARE_NONSTD(apr_status_t) \
                                (f) (APREQ_PARSER_ARGS)
Declares a API parser.

#define APREQ_HOOK_ARGS
 

Value:

Hook arguments

#define APREQ_PARSER_ARGS
 

Value:

Parser arguments.


Typedef Documentation

typedef apr_status_t(* apreq_hook_function_t)(APREQ_HOOK_ARGS)
 

The callback function of a hook. See apreq_hook_t.

typedef struct apreq_hook_t apreq_hook_t
 

A hook is called by the parser whenever data arrives in a file upload parameter of the request body. You may associate any number of hooks with a parser instance with apreq_parser_add_hook().

typedef apr_status_t(* apreq_parser_function_t)(APREQ_PARSER_ARGS)
 

The callback function implementing a request body parser.

typedef struct apreq_parser_t apreq_parser_t
 

A request body parser instance.


Function Documentation

APREQ_DECLARE_HOOK apreq_hook_find_param   ) 
 

Special purpose utility for locating a parameter during parsing. The hook's ctx shoud be initialized to a const char *, which is a pointer to the desired param name. The hook's ctx will be reassigned to the first param found.

Remarks:
When used, this should always be the first hook invoked, so add it manually as parser->hook instead of using apreq_parser_add_hook.

APREQ_DECLARE_HOOK apreq_hook_discard_brigade   ) 
 

Calls apr_brigade_cleanup on the incoming brigade after passing the brigade to any subsequent hooks.

APREQ_DECLARE_HOOK apreq_hook_disable_uploads   ) 
 

Returns APREQ_ERROR_GENERAL. Effectively disables mfd parser if a file-upload field is present.

APREQ_DECLARE_HOOK apreq_hook_apr_xml_parser   ) 
 

apr_xml_parser hook. It will parse until EOS appears. The parsed document isn't available until parsing has completed successfully. The hook's ctx pointer may be cast as (apr_xml_doc **) to retrieve the parsed document.

APREQ_DECLARE_PARSER apreq_parse_generic   ) 
 

Generic parser. No table entries will be added to the req->body table by this parser. The parser creates a dummy apreq_param_t to pass to any configured hooks. If no hooks are configured, the dummy param's bb slot will contain a copy of the request body. It can be retrieved by casting the parser's ctx pointer to (apreq_param_t **).

APREQ_DECLARE_PARSER apreq_parse_multipart   ) 
 

RFC 2388 multipart/form-data (and XForms 1.0 multipart/related) parser. It will reject any buckets representing preamble and postamble text (this is normal behavior, not an error condition). See apreq_parser_run() for more info on rejected data.

APREQ_DECLARE_PARSER apreq_parse_urlencoded   ) 
 

RFC 2396 application/x-www-form-urlencoded parser.

APREQ_DECLARE_PARSER apreq_parse_headers   ) 
 

RFC 822 Header parser. It will reject all data after the first CRLF CRLF sequence (an empty line). See apreq_parser_run() for more info on rejected data.

apreq_hook_t* apreq_hook_make apr_pool_t pool,
apreq_hook_function_t  hook,
apreq_hook_t next,
void *  ctx
 

Construct a hook.

Parameters:
pool used to allocate the hook.
hook The hook function.
next List of other hooks for this hook to call on.
ctx Hook's internal scratch pad.
Returns:
New hook.

static APR_INLINE apr_status_t apreq_hook_run struct apreq_hook_t h,
apreq_param_t param,
apr_bucket_brigade bb
[static]
 

Run the hook with the current parameter and the incoming bucket brigade. The hook may modify the brigade if necessary. Once all hooks have completed, the contents of the brigade will be added to the parameter's bb attribute.

Returns:
APR_SUCCESS on success. All other values represent errors.

apreq_parser_function_t apreq_parser const char *  enctype  ) 
 

Fetch the default parser function associated with the given MIME type.

Parameters:
enctype The desired enctype (can also be a full "Content-Type" header).
Returns:
The parser function, or NULL if the enctype is unrecognized.

apr_status_t apreq_parser_add_hook apreq_parser_t p,
apreq_hook_t h
 

Add a new hook to the end of the parser's hook list.

Parameters:
p Parser.
h Hook to append.

apreq_parser_t* apreq_parser_make apr_pool_t pool,
apr_bucket_alloc_t ba,
const char *  content_type,
apreq_parser_function_t  pfn,
apr_size_t  brigade_limit,
const char *  temp_dir,
apreq_hook_t hook,
void *  ctx
 

Construct a parser.

Parameters:
pool Pool used to allocate the parser.
ba bucket allocator used to create bucket brigades
content_type Content-type that this parser can deal with.
pfn The parser function.
brigade_limit the maximum in-memory bytes a brigade may use
temp_dir the directory used by the parser for temporary files
hook Hooks to asssociate this parser with.
ctx Parser's internal scratch pad.
Returns:
New parser.

static APR_INLINE apr_status_t apreq_parser_run struct apreq_parser_t psr,
apr_table_t t,
apr_bucket_brigade bb
[static]
 

Parse the incoming brigade into a table. Parsers normally consume all the buckets of the brigade during parsing. However parsers may leave "rejected" data in the brigade, even during a successful parse, so callers may need to clean up the brigade themselves (in particular, rejected buckets should not be passed back to the parser again).

Remarks:
bb == NULL is valid: the parser should return its public status: APR_INCOMPLETE, APR_SUCCESS, or an error code.

apr_status_t apreq_register_parser const char *  enctype,
apreq_parser_function_t  pfn
 

Register a new parsing function with a MIME enctype. Registered parsers are added to apreq_parser()'s internal lookup table.

Parameters:
enctype The MIME type.
pfn The function to use during parsing. Setting parser == NULL will remove an existing parser.
Returns:
APR_SUCCESS or error.

rapache-1.2.8/libapreq2/docs/html/apreq__util_8h-source.html0000644000175100017510000005734112706745114023340 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: include/apreq_util.h Source File

apreq_util.h

Go to the documentation of this file.
00001 /*
00002 **  Copyright 2003-2005  The Apache Software Foundation
00003 **
00004 **  Licensed under the Apache License, Version 2.0 (the "License");
00005 **  you may not use this file except in compliance with the License.
00006 **  You may obtain a copy of the License at
00007 **
00008 **      http://www.apache.org/licenses/LICENSE-2.0
00009 **
00010 **  Unless required by applicable law or agreed to in writing, software
00011 **  distributed under the License is distributed on an "AS IS" BASIS,
00012 **  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
00013 **  See the License for the specific language governing permissions and
00014 **  limitations under the License.
00015 */
00016 
00017 #ifndef APREQ_UTIL_H
00018 #define APREQ_UTIL_H
00019 
00020 #include "apr_file_io.h"
00021 #include "apr_buckets.h"
00022 #include "apreq.h"
00023 
00024 #ifdef  __cplusplus
00025  extern "C" {
00026 #endif 
00027 
00052 APREQ_DECLARE(char *) apreq_join(apr_pool_t *p, 
00053                                  const char *sep, 
00054                                  const apr_array_header_t *arr, 
00055                                  apreq_join_t mode);
00056 
00069 APREQ_DECLARE(apr_ssize_t) apreq_index(const char* hay, apr_size_t hlen, 
00070                                        const char* ndl, apr_size_t nlen, 
00071                                        const apreq_match_t type);
00072 
00085 APREQ_DECLARE(apr_size_t) apreq_quote(char *dest, const char *src, 
00086                                       const apr_size_t slen);
00087 
00101 APREQ_DECLARE(apr_size_t) apreq_quote_once(char *dest, const char *src, 
00102                                            const apr_size_t slen);
00103 
00114 APREQ_DECLARE(apr_size_t) apreq_encode(char *dest, const char *src, 
00115                                        const apr_size_t slen);
00116 
00128 APREQ_DECLARE(apr_size_t) apreq_cp1252_to_utf8(char *dest,
00129                                                const char *src, apr_size_t slen);
00130 
00151 APREQ_DECLARE(apr_status_t) apreq_decode(char *dest, apr_size_t *dlen,
00152                                          const char *src, apr_size_t slen);
00153 
00174 APREQ_DECLARE(apr_status_t) apreq_decodev(char *dest, apr_size_t *dlen,
00175                                           struct iovec *v, int nelts);
00176 
00189 static APR_INLINE
00190 char *apreq_escape(apr_pool_t *p, const char *src, const apr_size_t slen)
00191 {
00192     char *rv;
00193 
00194     if (src == NULL)
00195         return NULL;
00196 
00197     rv = apr_palloc(p, 3 * slen + 1);
00198     apreq_encode(rv, src, slen);
00199     return rv;
00200 }
00201 
00209 static APR_INLINE apr_ssize_t apreq_unescape(char *str)
00210 {
00211     apr_size_t len;
00212     apr_status_t rv = apreq_decode(str, &len, str, strlen(str));
00213     if (rv == APR_SUCCESS)
00214         return (apr_ssize_t)len;
00215     else
00216         return -1;
00217 }
00218 
00230 APREQ_DECLARE(apr_int64_t) apreq_atoi64f(const char *s);
00231 
00243 APREQ_DECLARE(apr_int64_t) apreq_atoi64t(const char *s);
00244 
00262 APREQ_DECLARE(apr_status_t) apreq_brigade_fwrite(apr_file_t *f,
00263                                                  apr_off_t *wlen,
00264                                                  apr_bucket_brigade *bb);
00281 APREQ_DECLARE(apr_status_t) apreq_file_mktemp(apr_file_t **fp, 
00282                                               apr_pool_t *pool,
00283                                               const char *path);
00284 
00294 static APR_INLINE
00295 apr_status_t apreq_brigade_setaside(apr_bucket_brigade *bb, apr_pool_t *p)
00296 {
00297     apr_bucket *e;
00298     for (e = APR_BRIGADE_FIRST(bb); e != APR_BRIGADE_SENTINEL(bb);
00299          e = APR_BUCKET_NEXT(e))
00300     {
00301         apr_status_t rv = apr_bucket_setaside(e, p);
00302         if (rv != APR_SUCCESS)
00303             return rv;
00304     }
00305     return APR_SUCCESS;
00306 }
00307 
00308 
00321 static APR_INLINE
00322 apr_status_t apreq_brigade_copy(apr_bucket_brigade *d, apr_bucket_brigade *s) {
00323     apr_bucket *e;
00324     for (e = APR_BRIGADE_FIRST(s); e != APR_BRIGADE_SENTINEL(s);
00325          e = APR_BUCKET_NEXT(e))
00326     {
00327         apr_bucket *c;
00328         apr_status_t rv = apr_bucket_copy(e, &c);
00329         if (rv != APR_SUCCESS)
00330             return rv;
00331 
00332         APR_BRIGADE_INSERT_TAIL(d, c);
00333     }
00334     return APR_SUCCESS;
00335 }
00336 
00348 static APR_INLINE
00349 void apreq_brigade_move(apr_bucket_brigade *d, apr_bucket_brigade *s,
00350                         apr_bucket *e)
00351 {
00352     apr_bucket *f;     
00353 
00354     if (e != APR_BRIGADE_SENTINEL(s)) {
00355         f = APR_RING_FIRST(&s->list);
00356         APR_RING_UNSPLICE(f, e, link);
00357         APR_RING_SPLICE_HEAD(&d->list, f, e, apr_bucket, link);
00358     }
00359     else {
00360         APR_BRIGADE_CONCAT(d, s);
00361     }
00362 }
00363 
00364 
00378 APREQ_DECLARE(apr_status_t) apreq_header_attribute(const char *hdr,
00379                                                    const char *name,
00380                                                    const apr_size_t nlen,
00381                                                    const char **val,
00382                                                    apr_size_t *vlen);
00383 
00384 
00402 APREQ_DECLARE(apr_status_t) apreq_brigade_concat(apr_pool_t *pool,
00403                                                  const char *temp_dir,
00404                                                  apr_size_t brigade_limit,
00405                                                  apr_bucket_brigade *out, 
00406                                                  apr_bucket_brigade *in);
00407 
00416 APREQ_DECLARE(apr_file_t *)apreq_brigade_spoolfile(apr_bucket_brigade *bb);
00417 
00418 #ifdef __cplusplus
00419  }
00420 #endif
00421 
00422 #endif /* APREQ_UTIL_H */
rapache-1.2.8/libapreq2/docs/html/apreq__util_8h.html0000644000175100017510000020064512706745114022037 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: include/apreq_util.h File Reference

apreq_util.h File Reference

Utility functions for apreq. More...

#include "apr_file_io.h"
#include "apr_buckets.h"
#include "apreq.h"

Go to the source code of this file.

Functions

char * apreq_join (apr_pool_t *p, const char *sep, const apr_array_header_t *arr, apreq_join_t mode)
apr_ssize_t apreq_index (const char *hay, apr_size_t hlen, const char *ndl, apr_size_t nlen, const apreq_match_t type)
apr_size_t apreq_quote (char *dest, const char *src, const apr_size_t slen)
apr_size_t apreq_quote_once (char *dest, const char *src, const apr_size_t slen)
apr_size_t apreq_encode (char *dest, const char *src, const apr_size_t slen)
apr_size_t apreq_cp1252_to_utf8 (char *dest, const char *src, apr_size_t slen)
apr_status_t apreq_decode (char *dest, apr_size_t *dlen, const char *src, apr_size_t slen)
apr_status_t apreq_decodev (char *dest, apr_size_t *dlen, struct iovec *v, int nelts)
static APR_INLINE char * apreq_escape (apr_pool_t *p, const char *src, const apr_size_t slen)
static APR_INLINE apr_ssize_t apreq_unescape (char *str)
apr_int64_t apreq_atoi64f (const char *s)
apr_int64_t apreq_atoi64t (const char *s)
apr_status_t apreq_brigade_fwrite (apr_file_t *f, apr_off_t *wlen, apr_bucket_brigade *bb)
apr_status_t apreq_file_mktemp (apr_file_t **fp, apr_pool_t *pool, const char *path)
static APR_INLINE apr_status_t apreq_brigade_setaside (apr_bucket_brigade *bb, apr_pool_t *p)
static APR_INLINE apr_status_t apreq_brigade_copy (apr_bucket_brigade *d, apr_bucket_brigade *s)
static APR_INLINE void apreq_brigade_move (apr_bucket_brigade *d, apr_bucket_brigade *s, apr_bucket *e)
apr_status_t apreq_header_attribute (const char *hdr, const char *name, const apr_size_t nlen, const char **val, apr_size_t *vlen)
apr_status_t apreq_brigade_concat (apr_pool_t *pool, const char *temp_dir, apr_size_t brigade_limit, apr_bucket_brigade *out, apr_bucket_brigade *in)
apr_file_tapreq_brigade_spoolfile (apr_bucket_brigade *bb)


Detailed Description

Utility functions for apreq.

This header contains useful functions for creating new parsers, hooks or modules. It includes

  • string <-> array converters
  • substring search functions
  • simple encoders & decoders for urlencoded strings
  • simple time, date, & file-size converters

Function Documentation

apr_int64_t apreq_atoi64f const char *  s  ) 
 

Converts file sizes (KMG) to bytes

Parameters:
s file size matching m/^\d+[KMG]b?$/i
Returns:
64-bit integer representation of s.
Todo:
What happens when s is malformed? Should this return an unsigned value instead?

apr_int64_t apreq_atoi64t const char *  s  ) 
 

Converts time strings (YMDhms) to seconds

Parameters:
s time string matching m/^\+?\d+[YMDhms]$/
Returns:
64-bit integer representation of s as seconds.
Todo:
What happens when s is malformed? Should this return an unsigned value instead?

apr_status_t apreq_brigade_concat apr_pool_t pool,
const char *  temp_dir,
apr_size_t  brigade_limit,
apr_bucket_brigade out,
apr_bucket_brigade in
 

Concatenates the brigades, spooling large brigades into a tempfile (APREQ_SPOOL) bucket.

Parameters:
pool Pool for creating a tempfile bucket.
temp_dir Directory for tempfile creation.
brigade_limit If out's length would exceed this value, the appended buckets get written to a tempfile.
out Resulting brigade.
in Brigade to append.
Returns:
APR_SUCCESS.

Error status code resulting from either apr_brigade_length(), apreq_file_mktemp(), apreq_brigade_fwrite(), or apr_file_seek().

Todo:
Flesh out these error codes, making them as explicit as possible.

static APR_INLINE apr_status_t apreq_brigade_copy apr_bucket_brigade d,
apr_bucket_brigade s
[static]
 

Copy a brigade.

Parameters:
d (destination) Copied buckets are appended to this brigade.
s (source) Brigade to copy from.
Returns:
APR_SUCCESS.

Error status code from an unsuccessful apr_bucket_copy().

Remarks:
s == d produces Undefined Behavior.

apr_status_t apreq_brigade_fwrite apr_file_t f,
apr_off_t wlen,
apr_bucket_brigade bb
 

Writes brigade to a file.

Parameters:
f File that gets the brigade.
wlen On a successful return, wlen holds the length of the brigade, which is the amount of data written to the file.
bb Bucket brigade.
Returns:
APR_SUCCESS.

Error status code from either an unsuccessful apr_bucket_read(), or a failed apr_file_writev().

Remarks:
In the future, this function may do something intelligent with file buckets.

static APR_INLINE void apreq_brigade_move apr_bucket_brigade d,
apr_bucket_brigade s,
apr_bucket e
[static]
 

Move the front of a brigade.

Parameters:
d (destination) Append buckets to this brigade.
s (source) Brigade to take buckets from.
e First bucket of s after the move. All buckets before e are appended to d.
Remarks:
This moves all buckets when e == APR_BRIGADE_SENTINEL(s).

static APR_INLINE apr_status_t apreq_brigade_setaside apr_bucket_brigade bb,
apr_pool_t p
[static]
 

Set aside all buckets in the brigade.

Parameters:
bb Brigade.
p Setaside buckets into this pool.
Returns:
APR_SUCCESS.

Error status code from an unsuccessful apr_bucket_setaside().

apr_file_t* apreq_brigade_spoolfile apr_bucket_brigade bb  ) 
 

Determines the spool file used by the brigade. Returns NULL if the brigade is not spooled in a file (does not use an APREQ_SPOOL bucket).

Parameters:
bb the bucket brigade
Returns:
the spool file, or NULL.

apr_size_t apreq_cp1252_to_utf8 char *  dest,
const char *  src,
apr_size_t  slen
 

Convert a string from cp1252 to utf8. Caller must ensure it is large enough to hold the encoded string and trailing '\0'.

Parameters:
dest Location of utf8-encoded result string. Caller must ensure it is large enough to hold the encoded string and trailing '\0'.
src Original string.
slen Length of original string.
Returns:
length of utf8-encoded string in dest; does not exceed 3 * slen.

apr_status_t apreq_decode char *  dest,
apr_size_t dlen,
const char *  src,
apr_size_t  slen
 

Url-decodes a string.

Parameters:
dest Location of url-encoded result string. Caller must ensure dest is large enough to hold the encoded string and trailing null character.
dlen points to resultant length of url-decoded string in dest
src Original string.
slen Length of original string.
Returns:
APR_SUCCESS + apreq_charset_t (<=APREQ_CHARSET_UTF8) on success.

APR_INCOMPLETE + apreq_charset_t (<=APREQ_CHARSET_UTF8) if the string ends in the middle of an escape sequence.

APREQ_ERROR_BADSEQ or APREQ_ERROR_BADCHAR on malformed input.

Remarks:
In the non-success case, dlen will be set to include the last succesfully decoded value. This function decodes %uXXXX into a utf8 (wide) character, following ECMA-262 (the Javascript spec) Section B.2.1.

apr_status_t apreq_decodev char *  dest,
apr_size_t dlen,
struct iovec *  v,
int  nelts
 

Url-decodes an iovec array.

Parameters:
dest Location of url-encoded result string. Caller must ensure dest is large enough to hold the encoded string and trailing null character.
dlen Resultant length of dest.
v Array of iovecs that represent the source string
nelts Number of iovecs in the array.
Returns:
APR_SUCCESS + apreq_charset_t (<=APREQ_CHARSET_UTF8) on success.

APR_INCOMPLETE + apreq_charset_t (<=APREQ_CHARSET_UTF8) if the iovec ends in the middle of an escape sequence.

APREQ_ERROR_BADSEQ or APREQ_ERROR_BADCHAR on malformed input.

Remarks:
In the non-APR_SUCCESS case, dlen will be set to include the last succesfully decoded value. This function decodes %uXXXX into a utf8 (wide) character, following ECMA-262 (the Javascript spec) Section B.2.1.

apr_size_t apreq_encode char *  dest,
const char *  src,
const apr_size_t  slen
 

Url-encodes a string.

Parameters:
dest Location of url-encoded result string. Caller must ensure it is large enough to hold the encoded string and trailing '\0'.
src Original string.
slen Length of original string.
Returns:
length of url-encoded string in dest; does not exceed 3 * slen.

static APR_INLINE char* apreq_escape apr_pool_t p,
const char *  src,
const apr_size_t  slen
[static]
 

Returns an url-encoded copy of a string.

Parameters:
p Pool used to allocate the return value.
src Original string.
slen Length of original string.
Returns:
The url-encoded string.
Remarks:
Use this function insead of apreq_encode if its caller might otherwise overflow dest.

apr_status_t apreq_file_mktemp apr_file_t **  fp,
apr_pool_t pool,
const char *  path
 

Makes a temporary file.

Parameters:
fp Points to the temporary apr_file_t on success.
pool Pool to associate with the temp file. When the pool is destroyed, the temp file will be closed and deleted.
path The base directory which will contain the temp file. If param == NULL, the directory will be selected via tempnam(). See the tempnam manpage for details.
Returns:
APR_SUCCESS.

Error status code from unsuccessful apr_filepath_merge(), or a failed apr_file_mktemp().

apr_status_t apreq_header_attribute const char *  hdr,
const char *  name,
const apr_size_t  nlen,
const char **  val,
apr_size_t vlen
 

Search a header string for the value of a particular named attribute.

Parameters:
hdr Header string to scan.
name Name of attribute to search for.
nlen Length of name.
val Location of (first) matching value.
vlen Length of matching value.
Returns:
APR_SUCCESS.

APREQ_ERROR_NOATTR if the attribute is not found.

APREQ_ERROR_BADSEQ if an unpaired quote mark was detected.

apr_ssize_t apreq_index const char *  hay,
apr_size_t  hlen,
const char *  ndl,
apr_size_t  nlen,
const apreq_match_t  type
 

Returns offset of match string's location, or -1 if no match is found.

Parameters:
hay Location of bytes to scan.
hlen Number of bytes available for scanning.
ndl Search string
nlen Length of search string.
type Match type.
Returns:
Offset of match string, or -1 if no match is found.

char* apreq_join apr_pool_t p,
const char *  sep,
const apr_array_header_t arr,
apreq_join_t  mode
 

Join an array of values. The result is an empty string if there are no values.

Parameters:
p Pool to allocate return value.
sep String that is inserted between the joined values.
arr Array of apreq_value_t entries.
mode Join type- see apreq_join_t.
Returns:
Joined string, or NULL on error

apr_size_t apreq_quote char *  dest,
const char *  src,
const apr_size_t  slen
 

Places a quoted copy of src into dest. Embedded quotes are escaped with a backslash ('\').

Parameters:
dest Location of quoted copy. Must be large enough to hold the copy and trailing null byte.
src Original string.
slen Length of original string.
dest Destination string.
Returns:
length of quoted copy in dest.

apr_size_t apreq_quote_once char *  dest,
const char *  src,
const apr_size_t  slen
 

Same as apreq_quote() except when src begins and ends in quote marks. In that case it assumes src is quoted correctly, and just copies src to dest.

Parameters:
dest Location of quoted copy. Must be large enough to hold the copy and trailing null byte.
src Original string.
slen Length of original string.
dest Destination string.
Returns:
length of quoted copy in dest.

static APR_INLINE apr_ssize_t apreq_unescape char *  str  )  [static]
 

An in-situ url-decoder.

Parameters:
str The string to decode
Returns:
Length of decoded string, or < 0 on error.

rapache-1.2.8/libapreq2/docs/html/apreq__version_8h-source.html0000644000175100017510000001365712706745114024052 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: include/apreq_version.h Source File

apreq_version.h

Go to the documentation of this file.
00001 /*
00002 **  Copyright 2003-2005  The Apache Software Foundation
00003 **
00004 **  Licensed under the Apache License, Version 2.0 (the "License");
00005 **  you may not use this file except in compliance with the License.
00006 **  You may obtain a copy of the License at
00007 **
00008 **      http://www.apache.org/licenses/LICENSE-2.0
00009 **
00010 **  Unless required by applicable law or agreed to in writing, software
00011 **  distributed under the License is distributed on an "AS IS" BASIS,
00012 **  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
00013 **  See the License for the specific language governing permissions and
00014 **  limitations under the License.
00015 */
00016 
00017 #ifndef APREQ_VERSION_H
00018 #define APREQ_VERSION_H
00019 
00020 #ifdef __cplusplus
00021 extern "C" {
00022 #endif
00023 
00024 #include "apr_version.h"
00025 #include "apreq.h"
00026 
00046 /* The numeric compile-time version constants. These constants are the
00047  * authoritative version numbers for libapreq. 
00048  */
00049 
00055 #define APREQ_MAJOR_VERSION       2
00056 
00061 #define APREQ_MINOR_VERSION       1
00062 
00064 #define APREQ_PATCH_VERSION       0
00065 
00070 #define APREQ_IS_DEV_VERSION
00071 
00072 
00074 #define APREQ_VERSION_STRING \
00075      APR_STRINGIFY(APREQ_MAJOR_VERSION) "." \
00076      APR_STRINGIFY(APREQ_MINOR_VERSION) "." \
00077      APR_STRINGIFY(APREQ_PATCH_VERSION) \
00078      APREQ_IS_DEV_STRING
00079 
00086 APREQ_DECLARE(void) apreq_version(apr_version_t *pvsn);
00087 
00089 APREQ_DECLARE(const char *) apreq_version_string(void);
00090 
00091 
00093 #ifdef APREQ_IS_DEV_VERSION
00094 #define APREQ_IS_DEV_STRING "-dev"
00095 #else
00096 #define APREQ_IS_DEV_STRING ""
00097 #endif
00098 
00099 
00100 #ifdef __cplusplus
00101 }
00102 #endif
00103 
00104 #endif /* APREQ_VERSION_H */
rapache-1.2.8/libapreq2/docs/html/apreq__version_8h.html0000644000175100017510000002636712706745114022556 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: include/apreq_version.h File Reference

apreq_version.h File Reference

Versioning API for libapreq. More...

#include "apr_version.h"
#include "apreq.h"

Go to the source code of this file.

Defines

#define APREQ_MAJOR_VERSION   2
#define APREQ_MINOR_VERSION   1
#define APREQ_PATCH_VERSION   0
#define APREQ_IS_DEV_VERSION
#define APREQ_VERSION_STRING
#define APREQ_IS_DEV_STRING   "-dev"

Functions

void apreq_version (apr_version_t *pvsn)
const char * apreq_version_string (void)


Detailed Description

Versioning API for libapreq.

There are several different mechanisms for accessing the version. There is a string form, and a set of numbers; in addition, there are constants which can be compiled into your application, and you can query the library being used for its actual version.

Note that it is possible for an application to detect that it has been compiled against a different version of libapreq by use of the compile-time constants and the use of the run-time query function.

libapreq version numbering follows the guidelines specified in:

http://apr.apache.org/versioning.html


Define Documentation

#define APREQ_IS_DEV_STRING   "-dev"
 

Internal: string form of the "is dev" flag

#define APREQ_IS_DEV_VERSION
 

This symbol is defined for internal, "development" copies of libapreq. This symbol will be #undef'd for releases.

#define APREQ_MAJOR_VERSION   2
 

major version Major API changes that could cause compatibility problems for older programs such as structure size changes. No binary compatibility is possible across a change in the major version.

#define APREQ_MINOR_VERSION   1
 

Minor API changes that do not cause binary compatibility problems. Should be reset to 0 when upgrading APREQ_MAJOR_VERSION

#define APREQ_PATCH_VERSION   0
 

patch level

#define APREQ_VERSION_STRING
 

Value:

The formatted string of libapreq's version


Function Documentation

void apreq_version apr_version_t pvsn  ) 
 

Return libapreq's version information information in a numeric form.

Parameters:
pvsn Pointer to a version structure for returning the version information.

const char* apreq_version_string void   ) 
 

Return libapreq's version information as a string.

rapache-1.2.8/libapreq2/docs/html/apreq_changes.html0000644000175100017510000006531112706745114021733 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: CHANGES

CHANGES

Changes with libapreq2-2.05-dev (released May 5, 2005)

  • Win32 build [Randy Kobes] Have top-level 'nmake', 'nmake test', and 'nmake install' targets, respectively, also include building, testing, and installing the corresponding perl glue targets.

  • C API [geoff] Minimum httpd version is now 2.0.48, which includes the official apr 0.9.4 release.

  • C API [Max Kellermann] Fix apreq_quote.

  • Perl API [joes] Remove Apache2::Request::args. WARNING: through inheritance, args() now maps to Apache2::RequestRec::args. Folks that want the pre-2.05-dev behavior need to invoke APR::Request::args by name.

  • C API [joes, Max Kellermann] Add apreq_initialize, apreq_pre_initialize and apreq_post_initialize. These are not thread-safe operations, so applications need to ensure they are invoked (in the correct sequence) prior to using any apreq2 modules.

  • Perl API [joes] Drop $data argument from UPLOAD_HOOK, and also drop HOOK_DATA option. Perl folks should use a closure instead of passing in context data.

  • Perl API [joes] Move bake, bake2 to Apache2::Cookie, now requiring an extra $r argument. Also ""-operator is mapped to as_string() for Apache2::Cookie; but APR::Request::Cookie maps it to value().

  • C API [joes] s/APREQ/APREQ2/g in webserver configuration directives.

  • C API [Igor Shevchenko, Philip Gollucci] Fix segfault in mfd parser caused by parts w/ empty param names.

  • C, Perl API [joes] Add charset support for params and couple the SvUTF8 flag to the param's taint flag.

  • C API [joes] Replace v->size with v->nlen + v->dlen. Added supporting apreq_value_table_add().

  • C API [joes] Remove apreq_cookie_attr().

  • C API [joes]
    • Add apreq_error.h, apreq_module.h.
    • Rename apreq_run* and apreq_make* funcs to conform with apreq_$obj_$meth scheme.
    • Replace c->version & c->secure with flags.
    • Parsers are assumed to be working with external data, so the cookies & params they produce are marked tainted.

  • C API [joes] apreq_parse_cookie_header() failed to parse RFC Cookie headers which contained no space chars after the '$Version=1' preamble.

  • C API [joes] Reorganize around include/, library/, and module/ dirs.

  • C Tests [joes] Replace CuTest-based tests with custom TAP-compliant framework.

  • C API [Max Kellermann] Continue the API improvements:

  • Convert APREQ_RUN_PARSER and APREQ_RUN_HOOK to inline, and downcase them.
  • Remove apreq_memmem.
  • Convert apreq_(un)escape to inline.
  • apreq_escape does not create an apreq_value_t*.
  • Initialize default_parsers explicitly to NULL.
  • Convert APREQ_BRIGADE_COPY to inline, and downcase it.
  • Lowercase APREQ_BRIGADE_SETASIDE, APREQ_BRIGADE_COPY.
  • Convert apreq_cookie_name and apreq_cookie_value macros to inline.
  • Convert apreq_param_name, apreq_param_value, apreq_param_info, and apreq_param_brigade to inline.

  • C API [joes] Widespread API refactorization to remove apreq_jar_t and apreq_request_t:

  • Header includes reorganized; apreq_parsers.h added (back again).
  • Replaced apreq_jar_t and apreq_request_t with single apreq_env_handle_t.
  • Added const qualifier to "v" attribute of apreq_cookie_t and apreq_param_t.
  • Use union type-puns to drop const qualifiers inside the new apreq_value_to_cookie and apreq_value_to_param implementations (gcc generates same object code as the macro versions did).
  • Moved "flags" attribute from apreq_value_t to apreq_cookie_t and apreq_param_t.
  • Remove env argument from hooks and parsers.
  • Reduce apreq_env_module to minimal set of operations.
  • Replace apreq_log calls with apreq-specific error codes.
  • Hooks are called on each body param now, not just during file uploads.
  • Tie the cgi handle to its creator pool.

Detailed changes by header file:

[apreq.h]

  • Remove flags from apreq_value_t.
  • Remove const qualifier from apreq_value_t's "name" attribute.
  • Remove apreq_value_merge* and apreq_value_copy*.
  • Remove apreq_char_to_value, apreq_strtoval, and apreq_strlen.
  • Move apreq_enctype to apreq_env.h.
  • Move apreq_env_handle_t struct definition to apreq_env.h
  • Change signature of apreq_decode.
  • Move apreq_brigade_concat here, changed its signature and improved it alot.
  • Remove apreq_brigade_spoolfile.
  • Dropped APREQ_*_ENCTYPE, renamed some APREQ_$foo defaults APREQ_DEFAULT_$foo.
  • Added APREQ_ERROR_*.

[apreq_cookie.h]

  • Remove apreq_env.h include.
  • Remove apreq_jar_t.
  • Add "flags" to apreq_cookie_t, add const qualifier to its "v" attr.
  • Remove apreq_jar* functions.
  • Add apreq_parse_cookie_header.
  • Move apreq_cookie, apreq_cookie_bake(2), and apreq_ua_cookie_version to apreq_env.h.

[apreq_params.h]

  • Remove apreq_env.h include.
  • Remove apreq_request_t.
  • Add "flags" to apreq_param_t, and const qualifier to its "v" attr.
  • Rename "bb" attribute "upload" in apreq_param_t.
  • Remove apreq_request* functions.
  • Remove apreq_parse_request.
  • Changed apreq_decode_param signature.
  • Replace env argument with apr_table_t in apreq_params_as_array, apreq_params_as_string,
  • Move remaining apreq_param* to apreq_env.h.
  • Move parser and hook sections to apreq_parsers.h.
  • Change apreq_upload(s) old apreq_request_t arg to apr_table_t.

[apreq_parsers.h]

  • Acquire the hook and parser sections of original apreq_params.h.
  • Remove env argument from APREQ_PARSER_ARGS and APREQ_HOOK_ARGS
  • Augment apreq_hook_t and apreq_parser_t to replace missing env features.
  • Change apreq_make_parser and apreq_make_hook signatures.
  • Rename apreq_add_hook to apreq_parser_add_hook, returning apr_status_t.
  • Change apreq_parser signature.

[apreq_env.h]

  • Remove read, log, pool, bucket_alloc, request, jar, and query_string methods.
  • Include apreq_parsers.h.
  • Reorganize apreq_env_module_t to provide hook, parser, jar, args, & body table ops.
  • Rename max_brigade to "brigade_limit", max_body to "read_limit".
  • Change related module sigs, including temp_dir, to get/set methods.
  • Add parser and read_limit args to apreq_env_make_custom_handle.
  • Drop "name" arg and APREQ_ENV_MODULE =~ s/_ENV//.
  • s/apreq_env_make/apreq_handle/ in the handle constructor names.

[mod_apreq.c, apreq_env_apache2.h]

  • Changed APREQ_Max* configs to APREQ_BrigadeLimit and APREQ_ReadLimit.
  • Handle constructor renamed apreq_handle_apache2.

  • C API [joes] Make our "libtool current interface" number depend on apr's major number. This allows libapreq2 to be installed into a system-wide location while avoiding ABI conflicts arising from our apr-based interfaces.

  • C API [Max Kellermann] Introduce apreq_env_handle_t to replace the void *env usage. Also added apreq_env_custom for making private handles, and new apreq_env_apache2.h to let mod_apreq export apreq_env_make_apache2.

  • C API [Max Kellermann] Rename apreq_env_t to apreq_env_module_t, to prepare for a new thread-safe apreq_env API.

  • C API [Max Kellermann] mod_apreq must check the return value of apreq_brigade_concat to avoid a RAM-consuming infinite loop. A bad APREQ_TempDir setting can cause this situation.

  • C API [joes] Provide workaround for chunked trailers bug in ap_http_filter.

  • C, Perl API [joes] Several upload-related bugfixes: 1) apreq_upload and apreq_uploads did not search the full body table, 2) $upload->slurp and $io->read did not autovivify the resultant string.

  • C API [joes] Add "flags" attribute to apreq_value_t, planning for charset support. This is an ABI change, starting with libapreq2.so.2.0.24.

  • C API [joes] Add apreq_env_bucket_alloc() to get an allocator directly from the environment instead of creating them from a pool. This is an ABI change, starting with libapreq2.so.2.0.23.

  • Build system [joes] Add --with-apache2-httpd option so users can override apxs's notion of where the httpd executable is. XSBuilder's header parser runs from buildconf now instead of configure, so we will include those tables in the release tarball. buildconf gets an additional --with-perl option for running the xsbuilder.pl parsing script. The XS generation code in xsbuilder.pl has moved to glue/perl/Makefile.PL.

  • C API [Bojan Smojver] Bake cookies with err_headers_out so they are sent on non-2xx server responses (ie. a 304 redirect). Also ensure that headers are copied with apr_table_add instead of apr_table_addn. Since apreq_cookie_bake() allocates from the stack, the Set-Cookie headers would occasionally get mangled without this patch.

  • C API [joes] Support "multipart/mixed" file uploads. Support XForms' "multipart/related" enctype.

  • C API [joes] Add apreq_hook_apr_xml_parser(), which is a simple wrapper hook around APR's expat-based apr_xml_parser. Add a generic parser apreq_parse_generic() to parse arbitrary enctypes using the hook API.

Changes with libapreq2-2.04-dev (released August 30, 2004)

  • Perl API [joes] Add TAINT checks, marking all parsed data as tainted.

  • C API [joes] Add body_status attribute to apreq_request_t, to allow the both environment and the parser to report any errors encountered.

  • C API [randyk, joes] Cookie parser was locking up on non-alphanumeric chars in cookie names. Also RFC Cookie attributes are always checked for quotes during bake(2), and the quotes are now stripped from incoming RFC cookies during parsing (but they are never stripped from the actual cookie value).

  • Perl API [joes] Apache::Cookie::Jar->new accepts a VALUE_CLASS argument, which effectively blesses all the jar's cookies into that class, which simplifies subclassing Apache::Cookie. Accordingly Apache::Cookie->freeze($value) no longer accepts a freeze()-able object in $value.

  • C API [Markus Wichitill, randyk, joes] Drop APR_DELONCLOSE from apreq_file_mktemp implementation and install apreq_file_cleanup. When passed to apr_file_open on Win32, APR_DELONCLOSE sets the FILE_SHARED_DELETE flag, which is, unfortunately, a property that is preserved across NTFS "hard" links. This breaks apps that link() the temp file to a permanent location, and subsequently expect to open it without FILE_SHARED_DELETE before the original tempfile is closed+deleted. In fact, even Apache::Upload does this, so it is a common enough event that the apreq_file_cleanup workaround is necessary.

  • C API [Ken Burcham, joes] Fix bug in url parser that occurs when a XX-encoded sequence is split across multiple buckets. Added apreq_decode_decodev to make this problem less inconvenient.

  • Perl API [joes] Exception objects inherit from the object which raised it, which allows $@ to invoke its methods with impunity (exceptions are disabled for objects which derive from an exception class).

  • Perl API [joes] Implement HOOK_DATA and UPLOAD_HOOK.

  • Perl API [joes] Add safe XS wrappers for $table->add, $table->set, $table->STORE, and $table_class->new.

  • Perl API [joes] Add exceptions to $upload->link, $upload->tempname, $upload->slurp, and $cookie->set_attr. Return value of $upload->slurp is now the upload length. Also document new $upload->io.

  • C API [joes] Restrict all apr_status_t codes to APR_SUCCESS, APR_INCOMPLETE, APR_EGENERAL, APR_EINIT, APR_ENOTIMPL, since any others will generate confusing error messages from apr_strerror.

  • Perl API [joes] Added $upload->io with a TIEHANDLE API layered over APR::Brigade. $upload->fh remains implemented as an APR::PerlIO object, which is seekable but less efficient and currently suffers some portability issues associated with largefile support in perl and apr.

  • Perl API [joes] Added apreq_xs_croak for throwing APR::Error exceptions and included error-checking on $req->param, $req->args, $req->body, $req->upload, and $jar->get.

  • Perl API [joes] Added $jar->status, $req->args_status and $req->body_status to report parsing errors. Also add $upload->tempname per user request.

  • C API [joes] Dropped status attribute of apreq_value_t. Added status field to apreq_jar_t and added args_status field to apreq_request_t. Parsers also must return their public status code when a NULL brigade is passed. apreq_hook_disable_uploads() is also added. This is an ABI change affecting all versions of libapreq2 prior to 2.0.12.

  • Perl API [joes] $upload->info returns a proper APR::Table object now. Also implemented $upload->size, $upload->fh, and $upload->type.

  • C API [Jean-François Meesse] mfd parser fails to parse CRLF-terminated files when the terminating boundary string is at the start of a new bucket. This is reportedly a common event for PDF files uploaded with Netscape 7.

  • Perl API [joes] Add back-compat support for Apache::Cookie->fetch() via Apache->request.

  • C API [joes] Add MaxBody, MaxBrigade, and TempDir per-dir directives to mod_apreq filter.

  • C API [joes, Scott Hutton] Replace apreq_brigade_copy with more effective APREQ_BRIGADE_COPY macro. Also introduce APREQ_BRIGADE_SETASIDE to deal with buckets that need to be set aside for use in future function calls. mod_ssl generates transient buckets which tickled this bug.

  • Perl API [joes] Separate Apache::Upload module from Apache::Request for better organization.

Changes with libapreq2-2.03-dev (released June 12, 2004)

  • C API [joes] "Objectify" cookie/jar API: s/apreq_(make|serialize)_cookie/apreq_cookie_$1/ and reordering args so the cookie/jar object is always the first argument. Macros added to provide source-compatibility with the old names.

  • Perl API [joes] Added $upload->slurp($data), which reads the contents of the file upload "$upload" into the scalar "$data".

  • C API [joes, randyk] apreq_run_(hook|parser) are macros, so they are capitalized now. Fixed apreq_params_as_string() and added apreq_params_as_array(). Reworked definitions of APREQ_DECLARE_HOOK, APREQ_DECLARE_PARSER and apreq_(parser|hook)_t, hopefully to be more Win32 friendly. Also updated the documentation.

  • C API [joes] Compensate for a missing CRLF in empty file upload block, which actually complies with RFC 2046 Section 5.1.1. Konqueror (version unknown) and Mozilla 0.9.7 are known to emit such blocks.

  • Perl API [joes] $req->upload() in list context failed to filter out non-uploads. Also $req->upload("nonexistent-key-name") segfaults.

  • Perl test suite t/TEST.PL must run parent class' pre_configure to get the configuration right

  • C API [joes] apreq_brigade_concat() wasn't supplying the final EOS bucket to large brigades (>256K), which somtimes caused the prefetch loop in mod_apreq.c's apreq_filter() to hang.

  • Documentation [joes] CHANGES file reformatted, removing dates & other clutter as Stas suggests.

  • C API [joes] Rewrote cgi_read() in apreq_env.c and reworked mod_apreq.c to enforce apreq_env_max_body() settings.

  • C API [joes] Fixed bug in url_parser code- missing context brigade was needed to track key-value pairs which span multiple buckets.

  • C API [joes] API modifications: removed struct apreq_cfg_t, adding new apreq_env hooks max_body, max_brigade_len, and temp_dir. Folded apreq_parsers.h into apreq_params.h and modified the arguments to apreq_run_parser() and apreq_run_hook(). Renamed apreq_parser_t's content_type as enctype and apreq_copy_brigade() as apreq_brigade_copy(). These changes make libapreq2.so.2.0.5 incompatible with earlier versions.

  • Perl API [stas] Include ppport.h from blead-perl to support older perls. Add a proper support for ithreads.

  • C API [Swen Schillig, joes] Fixed bug in calculation of Netscape cookie expiration dates. apr_time_t is measured in microseconds, not seconds, which threw off the arithmetic; apr_time_from_sec was needed for the conversion.

  • C API [Max Kellermann] Fix segfault caused by invalid -escape sequence in query string.

Changes with libapreq2-2.02-dev (released Nov 15, 2003)

  • Perl API [joes] Fix bogus pool/cookie initializers in Apache::Cookie::set_attr(), which caused Apache::Cookie::new to segfault. Bug first reported to modperl list by Wolfgang Kubens.

Changes with libapreq2-2.01-dev (released Nov 10, 2003)

  • build system [joes] Skip Apache::Test tests in env/ when Apache::Test is unavailable. This allows the C API to be build and installed without requiring Apache::Test (it is still a requirement for compiling the perl glue).

  • C API mod_apreq.c [joes] Parser errors were creeping into the return value of apreq_filter, which breaks the "transparent tee" paradigm. This caused bogus "400 Bad Request" responses (first reported by Vladimir Dudo) to occur when libapreq2 was used by an output filter during a GET request (handled by apache2's default handler). The test suite has been updated accordingly.

  • C API [joes] Incorporate libapreq_cgi into libapreq2 as the default environment, and add apreq_env_t and initializer apreq_env_module() to manage the environment at runtime (determining the environment at load-time was problematic on non-ELF systems).

Changes with libapreq2-2.00-dev (Oct 25, 2003)

  • C API: libapreq_cgi.c [randyk, joes] CGI environment defined by env/libapreq_cgi.c is functional (with tests added to env/t). This library may soon be incorporated directly into libapreq2 as a default enviroment.

  • C API: mod_apreq.c [joes] Added ctx->saw_eos to ensure we don't read from upstream filters after receiving an eos bucket. Otherwise it was possible for two eos buckets to appear when a prefetch read is involved, which breaks other modules like mod_proxy. This bug was uncovered by Philippe Chiasson. mod_apreq's apreq_env_majic_number bumped to reflect the added fixes.

  • configure: --enable-perl-glue [joes] The --enable-perl-glue option integrates the perl glue into the normal Unix build cycle. It is disabled by default, but is silently reenabled if the user configures the source tree via Makefile.PL.

  • C API [joes] Added apreq_header_attribute() and fixed mfd parser to allow "charset" attribute to appear in the Content-Type header. Sven Geisler points out that Opera 7.20 does generate such headers.

  • C API [joes] Added versioning API following http://apr.apache.org/versioning.html apreq_env renamed apreq_env_name, and apreq_env_magic_number added to provide versioning for environments (modules). The header files are now installed to "include/apreq2", and the library is renamed "libapreq2". Also added an apreq2-config script based on apu-config.

  • configure: static mod_apreq.c [Bojan Smojver, joes] Add --with-apache2-src configure option, along with --with-apr-config and --with-apu-config, and provide support for compiling mod_apreq into httpd as a static apache module.

  • C API: mod_apreq.c [joes] Support for internal redirects added to the mod_apreq filter. This ensures any POST data prefetched in the main request gets passed along to the subrequest handler(s).

  • C bugfix: apreq_decode [Graham Clark] If the source and destination strings are represented by the same pointer - e.g. if called as apreq_unescape(s) - string s is modified incorrectly in general. Patch includes new unit test.

  • Perl API [joes] Added $req->parse, $req->status, & "preparse" logic to $req->param & $req->upload.

  • C API [joes] Added "preparse" logic to apreq_params & apreq_uploads to bring behavior in line with libapreq-1.x.

  • C API [joes] Dropped param->charset. Make apreq_brigade_concat public, so mod_apreq can use it for its ctx->spool brigade.

  • Documentation [joes] Updated Cookie_pod to reflect API changes over v1.X.

  • Documentation [joes] Added doxygen links to Apache::Request and Apache::Cookie perl docs.

  • C API [joes] Added apreq_copy_brigade(bb) to apreq.h.

  • C API [joes] The new filter-based design required a complete departure from libapreq-1.X codebase. libapreq-2 is based solely on APR, and to be fully functional, requires a supporting environment similar to Apache-2. A person wishing to port libapreq-2 to a new environment needs to provide definitions for the declarations in apreq_env.h.

  • Perl API [joes] Aggregates are always collected into an APR::Table-based package. New table packages: Apache::Cookie::Table, Apache::Request::Table, and Apache::Upload::Table.

  • Perl API [joes] Apache::Cookie->fetch now requires an "environment" argument ($r). Its return value is blessed into the Apache::Cookie::Jar class.

  • Perl API [joes] Two new request lookup functions:
    1. $req->args - param lookup using only the query string
    2. $req->body - param lookup using only the POST data
rapache-1.2.8/libapreq2/docs/html/apreq_faq.html0000644000175100017510000000774212706745114021076 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: FAQ

FAQ


Issues during installation.

[...]


Using libapreq2 with Apache 2 and mod_perl 2.

When I use Apache::Request in my output filter, it seems to lose the incoming POST variables.

The problem is likely that the mod_apreq filter has not been added to the input filter chain in time to read the POST data.

There are two solutions to this problem:

 1) Write a filter init handler for you filter that instantiates an Apache::Request object.
    http://perl.apache.org/docs/2.0/api/Apache/Filter.html#C_FilterInitHandler_
 2) Use .htaccess or your server config to ensure the apreq input filter
    is active for this request with "AddInputFilter APREQ" or somesuch.

We recommend using (1), and falling back to (2) until you get (1) working.

When I try to upload a file, why do I get this error ``[error] Can't locate .../Apache/Request/upload.al in @INC''?

Apache::Upload is now a separate module in apreq2, so you need to use Apache::Upload to load the Apache::Request::upload function.


Using libapreq2 outside of Apache.

[...]

rapache-1.2.8/libapreq2/docs/html/apreq_install.html0000644000175100017510000000757312706745114021777 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: INSTALL

INSTALL

PREREQUISITES:

Please see the PREREQUISITES file.  If you are building httpd-apreq-2 
directly from svn, you can generate the list of prerequisites:

            % perl build/version_check.pl


INSTRUCTIONS:

FreeBSD users must substitute "gmake" for "make" below.

Unix build, where libtool/automake/autoconf works:

            % ./configure --with-apache2-apxs=/path/to/apache2/bin/apxs
            % make
  (optional)% make test
            % make install


Or using the CPAN/perlish way (which includes the Apache::Request and
Apache::Cookie modules):

            % perl Makefile.PL --with-apache2-apxs=/path/to/apache2/bin/apxs
            % make
  (optional)% make test
            % make install

Developers and other folks using httpd-apreq-2 directly from svn need to
execute "./buildconf" prior to running "./configure".


Alternately, here's a recipe to install mod_apreq.c as a static apache module:

  1) configure httpd to add mod_apreq.c to its filter modules:

  % cd /path/to/httpd-2.0
  % CPPFLAGS=-I/path/to/httpd-apreq-2/src \
    HTTPD_LDFLAGS=/path/to/httpd-apreq-2/src/libapreq2.la \
    ./configure --with-module=filters:/path/to/httpd-apreq-2/env/mod_apreq.c \
    ...(add usual httpd+apr options here)...

  2) compile and install everything using httpd-apreq-2's build system:

            % cd /path/to/httpd-apreq-2
            % ./configure --with-apache2-src=/path/to/httpd-2.0
            % make
  (optional)% make test
            % make install



Win32 build:
  C:\httpd-apreq-2> perl Makefile.PL
  C:\httpd-apreq-2> nmake
  C:\httpd-apreq-2> nmake test
  C:\httpd-apreq-2> nmake mod_apreq
  C:\httpd-apreq-2> nmake perl_glue
  C:\httpd-apreq-2> nmake perl_test

SVN (Subversion) ACCESS

Development of httpd-apreq-2 can be followed through the svn repository:

  $ svn checkout http://svn.apache.org/repos/asf/httpd/apreq/trunk/ httpd-apreq-2

Developers with commit access must use the https protocol instead;
note that, if you are compiling svn from sources, you must
supply the configure script with the appropriate switch to
enable ssl.

Subversion sources, and binaries for some platforms, may be obtained
through the home page:

     http://subversion.tigris.org/

Documentation on using svn is available at

     http://svnbook.red-bean.com/

In particular,

     http://svnbook.red-bean.com/en/1.0/apa.html

contains a guide for users familiar with cvs.



rapache-1.2.8/libapreq2/docs/html/apreq_license.html0000644000175100017510000003114312706745114021741 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: LICENSE

LICENSE

                                 Apache License
                           Version 2.0, January 2004
                        http://www.apache.org/licenses/

   TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION

   1. Definitions.

      "License" shall mean the terms and conditions for use, reproduction,
      and distribution as defined by Sections 1 through 9 of this document.

      "Licensor" shall mean the copyright owner or entity authorized by
      the copyright owner that is granting the License.

      "Legal Entity" shall mean the union of the acting entity and all
      other entities that control, are controlled by, or are under common
      control with that entity. For the purposes of this definition,
      "control" means (i) the power, direct or indirect, to cause the
      direction or management of such entity, whether by contract or
      otherwise, or (ii) ownership of fifty percent (50%) or more of the
      outstanding shares, or (iii) beneficial ownership of such entity.

      "You" (or "Your") shall mean an individual or Legal Entity
      exercising permissions granted by this License.

      "Source" form shall mean the preferred form for making modifications,
      including but not limited to software source code, documentation
      source, and configuration files.

      "Object" form shall mean any form resulting from mechanical
      transformation or translation of a Source form, including but
      not limited to compiled object code, generated documentation,
      and conversions to other media types.

      "Work" shall mean the work of authorship, whether in Source or
      Object form, made available under the License, as indicated by a
      copyright notice that is included in or attached to the work
      (an example is provided in the Appendix below).

      "Derivative Works" shall mean any work, whether in Source or Object
      form, that is based on (or derived from) the Work and for which the
      editorial revisions, annotations, elaborations, or other modifications
      represent, as a whole, an original work of authorship. For the purposes
      of this License, Derivative Works shall not include works that remain
      separable from, or merely link (or bind by name) to the interfaces of,
      the Work and Derivative Works thereof.

      "Contribution" shall mean any work of authorship, including
      the original version of the Work and any modifications or additions
      to that Work or Derivative Works thereof, that is intentionally
      submitted to Licensor for inclusion in the Work by the copyright owner
      or by an individual or Legal Entity authorized to submit on behalf of
      the copyright owner. For the purposes of this definition, "submitted"
      means any form of electronic, verbal, or written communication sent
      to the Licensor or its representatives, including but not limited to
      communication on electronic mailing lists, source code control systems,
      and issue tracking systems that are managed by, or on behalf of, the
      Licensor for the purpose of discussing and improving the Work, but
      excluding communication that is conspicuously marked or otherwise
      designated in writing by the copyright owner as "Not a Contribution."

      "Contributor" shall mean Licensor and any individual or Legal Entity
      on behalf of whom a Contribution has been received by Licensor and
      subsequently incorporated within the Work.

   2. Grant of Copyright License. Subject to the terms and conditions of
      this License, each Contributor hereby grants to You a perpetual,
      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
      copyright license to reproduce, prepare Derivative Works of,
      publicly display, publicly perform, sublicense, and distribute the
      Work and such Derivative Works in Source or Object form.

   3. Grant of Patent License. Subject to the terms and conditions of
      this License, each Contributor hereby grants to You a perpetual,
      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
      (except as stated in this section) patent license to make, have made,
      use, offer to sell, sell, import, and otherwise transfer the Work,
      where such license applies only to those patent claims licensable
      by such Contributor that are necessarily infringed by their
      Contribution(s) alone or by combination of their Contribution(s)
      with the Work to which such Contribution(s) was submitted. If You
      institute patent litigation against any entity (including a
      cross-claim or counterclaim in a lawsuit) alleging that the Work
      or a Contribution incorporated within the Work constitutes direct
      or contributory patent infringement, then any patent licenses
      granted to You under this License for that Work shall terminate
      as of the date such litigation is filed.

   4. Redistribution. You may reproduce and distribute copies of the
      Work or Derivative Works thereof in any medium, with or without
      modifications, and in Source or Object form, provided that You
      meet the following conditions:

      (a) You must give any other recipients of the Work or
          Derivative Works a copy of this License; and

      (b) You must cause any modified files to carry prominent notices
          stating that You changed the files; and

      (c) You must retain, in the Source form of any Derivative Works
          that You distribute, all copyright, patent, trademark, and
          attribution notices from the Source form of the Work,
          excluding those notices that do not pertain to any part of
          the Derivative Works; and

      (d) If the Work includes a "NOTICE" text file as part of its
          distribution, then any Derivative Works that You distribute must
          include a readable copy of the attribution notices contained
          within such NOTICE file, excluding those notices that do not
          pertain to any part of the Derivative Works, in at least one
          of the following places: within a NOTICE text file distributed
          as part of the Derivative Works; within the Source form or
          documentation, if provided along with the Derivative Works; or,
          within a display generated by the Derivative Works, if and
          wherever such third-party notices normally appear. The contents
          of the NOTICE file are for informational purposes only and
          do not modify the License. You may add Your own attribution
          notices within Derivative Works that You distribute, alongside
          or as an addendum to the NOTICE text from the Work, provided
          that such additional attribution notices cannot be construed
          as modifying the License.

      You may add Your own copyright statement to Your modifications and
      may provide additional or different license terms and conditions
      for use, reproduction, or distribution of Your modifications, or
      for any such Derivative Works as a whole, provided Your use,
      reproduction, and distribution of the Work otherwise complies with
      the conditions stated in this License.

   5. Submission of Contributions. Unless You explicitly state otherwise,
      any Contribution intentionally submitted for inclusion in the Work
      by You to the Licensor shall be under the terms and conditions of
      this License, without any additional terms or conditions.
      Notwithstanding the above, nothing herein shall supersede or modify
      the terms of any separate license agreement you may have executed
      with Licensor regarding such Contributions.

   6. Trademarks. This License does not grant permission to use the trade
      names, trademarks, service marks, or product names of the Licensor,
      except as required for reasonable and customary use in describing the
      origin of the Work and reproducing the content of the NOTICE file.

   7. Disclaimer of Warranty. Unless required by applicable law or
      agreed to in writing, Licensor provides the Work (and each
      Contributor provides its Contributions) on an "AS IS" BASIS,
      WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
      implied, including, without limitation, any warranties or conditions
      of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
      PARTICULAR PURPOSE. You are solely responsible for determining the
      appropriateness of using or redistributing the Work and assume any
      risks associated with Your exercise of permissions under this License.

   8. Limitation of Liability. In no event and under no legal theory,
      whether in tort (including negligence), contract, or otherwise,
      unless required by applicable law (such as deliberate and grossly
      negligent acts) or agreed to in writing, shall any Contributor be
      liable to You for damages, including any direct, indirect, special,
      incidental, or consequential damages of any character arising as a
      result of this License or out of the use or inability to use the
      Work (including but not limited to damages for loss of goodwill,
      work stoppage, computer failure or malfunction, or any and all
      other commercial damages or losses), even if such Contributor
      has been advised of the possibility of such damages.

   9. Accepting Warranty or Additional Liability. While redistributing
      the Work or Derivative Works thereof, You may choose to offer,
      and charge a fee for, acceptance of support, warranty, indemnity,
      or other liability obligations and/or rights consistent with this
      License. However, in accepting such obligations, You may act only
      on Your own behalf and on Your sole responsibility, not on behalf
      of any other Contributor, and only if You agree to indemnify,
      defend, and hold each Contributor harmless for any liability
      incurred by, or claims asserted against, such Contributor by reason
      of your accepting any such warranty or additional liability.

   END OF TERMS AND CONDITIONS

   APPENDIX: How to apply the Apache License to your work.

      To apply the Apache License to your work, attach the following
      boilerplate notice, with the fields enclosed by brackets "[]"
      replaced with your own identifying information. (Don't include
      the brackets!)  The text should be enclosed in the appropriate
      comment syntax for the file format. We also recommend that a
      file or class name and description of purpose be included on the
      same "printed page" as the copyright notice for easier
      identification within third-party archives.

   Copyright [yyyy] [name of copyright owner]

   Licensed under the Apache License, Version 2.0 (the "License");
   you may not use this file except in compliance with the License.
   You may obtain a copy of the License at

       http://www.apache.org/licenses/LICENSE-2.0

   Unless required by applicable law or agreed to in writing, software
   distributed under the License is distributed on an "AS IS" BASIS,
   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
   See the License for the specific language governing permissions and
   limitations under the License.
rapache-1.2.8/libapreq2/docs/html/apreq_notice.html0000644000175100017510000000314712706745114021603 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: NOTICE

NOTICE

This product includes software developed by
The Apache Software Foundation (http://www.apache.org/).
rapache-1.2.8/libapreq2/docs/html/apreq_status.html0000644000175100017510000001372612706745114021651 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: STATUS

STATUS

2.05-dev released on May 5, 2005.

Contributors looking for a mission:

  • just do an egrep on "TODO" or "XXX" and see what's there

CURRENT RELEASE NOTES:

  • This is a developer release, indicated by the "-dev" suffix on the version string. We believe the core interfaces to be stable, but some portions of the API may still need significant modification. Thus, binary/source compatibility may be broken from one developer release to the next. In particular the version numbering rules specified at

http://apr.apache.org/versioning.html

do not apply to developer releases.

RELEASE SHOWSTOPPERS:

  • The api docs are currently incorrect.

CURRENT VOTES:

  • Should we switch to EU::MM for determining the full path to perl? The problem is that some folks move their perl binary post-installation, but never adjust Config.pm. EU::MM is smart, by accepting a full path in $^X or by searching the user's $PATH for $^X, before resorting to Config.pm. However, if we change apreq2, we should also lobby test-dev to adopt the same solution for Apache::Test. Otherwise our test suite will likely fail, even though the rest of the perl build system will presumably still work.

+1: joes 0: -1:

TODO:

  • Dump automake, preferably replacing that with more stuff from httpd/apr's build system.

  • Introduce APR::Request::Parser and APR::Request::Hook. Implement Apache2::Request::new's UPLOAD_HOOK using them.

  • Move module/t to module/apache2/t.

  • Figure out how and where the apreq_xs_ headers, and typemap file, should be installed.

  • Write tests for the apache 1.3.x module.

  • Fix the broken make dependencies, especially in the module and glue subdirs. The libtool workaround (for OSX IIRC) that copies module/.libs to module/t is especially bogus.

  • Drop ExtUtils::XSBuilder as the C API is fairly stable now. The header parsing + xs generation stuff may be too difficult for the community to maintain over ordinary .xs files.

  • Round out the unit tests in library/t. Ideally each API function should have its own tests, and each possible error status should be both tested & documented. Also upgrade these tests to use the Apache::Test framework.

  • Add a "header_limit" setting to control outgoing header size (mainly for baking cookies) instead of using a compiled-in limit.

  • in glue/perl/t/apreq/cgi.t on Win32, printing to the error log hangs if the strings involved are about 10000 in size. This doesn't occur in the env/cgi tests - why?

  • Why must fprintf(stderr, ...), rather than apr_file_printf(err, ...), be used on Win32 in cgi_log() of src/apreq_env.c?

  • Get env/ (Apache::Test) tests to work for --with-apache2-src option. Also add a test to configure that prevents simultaneous use of --with-apache2-src and --with-apache2-apxs.

  • symbol exports files:
    1. aix needs .exp files

  • Install the html dox during "make install". Should we do this for the doxy manpages also?

  • Rework glue/perl build system to use apreq2-config instead of relying on paths like "../../src".

OPEN ISSUES:

  • Should we bundle an apr-based "application/xml" parser? If so, how should we parse the xml data into an apr_table?

  • Determine whether or not it's good for the perl glue to ever set the SvUTF8 flag on a param. The current code ties this action to the apreq_param_is_tainted flag.

  • Should we let hooks interrupt parsers via APREQ_ERROR_INTERRUPT? That'd need a delete_hook method to make interrupts a useful way of tuning parser behavior.

BUGS:

  • Fix build automake/libtool/autoconf build system so it works properly on OSX & AIX.

WISH LIST:

  • I [joes] wish folks would contribute some glue code for one of these:

  • php,
  • Rivet,
  • mod_dtcl,
  • mod_python,
  • mod_jk,
  • tomcat,
  • mod_ruby,
  • mod_parrot.
rapache-1.2.8/libapreq2/docs/html/dir_000000.html0000644000175100017510000001042512706745114020504 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: include/ Directory Reference

include Directory Reference


Files

file  apreq.h [code]
 Main header file...
file  apreq_cookie.h [code]
 Cookies and Jars.
file  apreq_error.h [code]
 Error status codes.
file  apreq_module.h [code]
 Module API.
file  apreq_param.h [code]
 Request parsing and parameter API.
file  apreq_parser.h [code]
 Request body parser API.
file  apreq_util.h [code]
 Utility functions for apreq.
file  apreq_version.h [code]
 Versioning API for libapreq.
rapache-1.2.8/libapreq2/docs/html/dir_000001.html0000644000175100017510000000373312706745114020511 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: module/ Directory Reference

module Directory Reference


Directories

directory  apache
directory  apache2
rapache-1.2.8/libapreq2/docs/html/dir_000002.html0000644000175100017510000000360212706745114020505 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: module/apache/ Directory Reference

apache Directory Reference


Files

file  apreq_module_apache.h [code]
rapache-1.2.8/libapreq2/docs/html/dir_000003.html0000644000175100017510000000360712706745114020513 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: module/apache2/ Directory Reference

apache2 Directory Reference


Files

file  apreq_module_apache2.h [code]
rapache-1.2.8/libapreq2/docs/html/dirs.html0000644000175100017510000000331212706745114020065 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: Directory Hierarchy

libapreq2 Directories

This directory hierarchy is sorted roughly, but not completely, alphabetically: rapache-1.2.8/libapreq2/docs/html/dox.css0000644000175100017510000003004312706745114017543 0ustar ondrejondrej/* Copyright 2002-2005 The Apache Software Foundation * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ /* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * mainframe ;-) * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ */ html { font-size: 14px; } body { background-color: #fff; color: #036; padding: 0 1em 0 0; margin: 0; font-family: Arial, Helvetica, sans-serif; font-weight: normal; } pre, code { font-family: "Courier New", Courier, monospace; } strong { font-weight: bold; } q, em, var { font-style: italic; } span.transnote { background-color: inherit; color: #888; } /* fixup IE & Opera * otherwise they forget to inherit * the computed font-size value */ table, code { font-size: 1em; } /* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * Links * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ */ /* normal links */ /* ====================== */ a:link { color: #0073c7; background-color: inherit; } a:visited { color: #5A88B5; background-color: inherit; } a:link:hover, a:link:active, a:visited:hover, a:visited:active { color: #0073c7; background-color: #f0f0f0; } /* hover on non-white backgrounds */ tr.odd a:hover, tr.odd a:active, tr.header a:hover, tr.header a:active, /* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * Headings * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ */ /* h1 */ /* ====================== */ h1 { padding: 0.2em; margin: 0; background-color: inherit; color: #036; text-decoration: none; font-size: 22px; font-weight: bold; text-align:center; } /* h2 */ /* ====================== */ h2 { padding: 0.2em 0 0.2em 0.7em; margin: 0 0 0.5em 0; text-decoration: none; font-size: 18px; font-weight: bold; text-align:left; } /* take care of s inside */ h2 a, h2 a:hover, h2 a:active { color: inherit; background-color: inherit; text-decoration: none; } /* h3, h4 */ /* ====================== */ h3 { background-color: inherit; color: #036; text-decoration: none; font-weight: bold; font-size: 16px; margin: 1.3em 0 0.4em 0; padding: 0; } h4 { background-color: inherit; color: #036; text-decoration: none; font-weight: bold; font-size: 14px; margin: 1.3em 0 0.2em 0; padding: 0; } /* margin adjustment */ h3 + *, h4 + * { margin-top: 0; } /* IE confuses the + * :-( * so reset some things */ ul, .section table, .directive-section table { margin-bottom: 1em; } /* take care of s inside */ h3 a, h3 a:hover, h3 a:active, h4 a, h4 a:hover, h4 a:active { color: inherit; background-color: inherit; text-decoration: none; } /* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * Tables * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ */ /* general */ /* ====================== */ /* table { border: 1px solid #aaa; border-collapse: collapse; padding: 2px; margin-top: 0.5em; margin-bottom: 0; } td, th { empty-cells: show; /* show border around empty cells */ padding: 0.1em 0.2em; vertical-align: top; text-align: left; line-height: 1.3em; } */ th { font-weight: bold; } td.centered { text-align: center; } tr.odd { /* for large tables alternating colors */ background-color: #f2f2f2; } tr.header, tr.header th { background-color: #e2e2e2; border-top: 1px solid #aaa; border-bottom: 1px solid #aaa; } /* bordered table cells */ /* ====================== */ /* turn off borders in tables nested in * bordered tables per default */ table.bordered table td, table.bordered table th { border-style: none; } table.bordered td, table.bordered th, table table.bordered td, table table.bordered th { border: 1px solid #aaa; } /* index page layout table */ /* ======================= */ body#index-page div#page-content { width: 100%; /* IE fun */ } body[id]#index-page div#page-content { width: auto; /* reasonable browsers. */ } table#indextable { width: 100%; border-collapse: collapse; border: 0 none; } table#indextable td { width: 33.3%; border-left: 1px solid #aaa; padding-top: 0; padding-bottom: 0; } table#indextable td.col1 { border-left: 0 none; padding-left: 0; } table#indextable td.col3 { padding-right: 0; } /* mod/dir. overview table and quick reference */ /* ============================================ */ table.module th, table.directive th { white-space: nowrap; } table.qref { border-collapse: collapse; width: 100%; } table.qref td { border-style: none solid; border-color: #aaa; border-width: 1px; } table.qref td.descr { padding-left: 1em; font-size: 13px; } table#legend { width: 100%; border-style: none; border-width: 0; vertical-align: bottom; padding: 0; margin: 0; } table#legend td { vertical-align: bottom; margin: 0; padding: 0; } table#legend td.letters { width: 100%; padding-bottom: 0.5em; } table#legend table { vertical-align: bottom; margin: 0 0 0 0.4em; padding: 0; height: 7.5em; } table#legend table td, table#legend table th { vertical-align: middle; padding: 0.1ex 0.2em; line-height: 1em; white-space: nowrap; } /* related modules & dir. */ /* ====================== */ /* assuming, all links are enclosed by * or * */ table.related { border-collapse: separate; } table.related th { padding: 0.2ex 0.3em; background-color: #e5ecf3; color: #405871; vertical-align: middle; } table.related td { padding: 0.2ex 0.3em; } /* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * Lists * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ */ /* list default values */ /* ====================== */ ul { list-style-type: disc; } ul ul { list-style-type: square; } ul ul ul { list-style-type: circle; } li, dt, dd { line-height: 1.3em; } dt { margin-top: 0.5em; font-weight: bold; } ol li { margin-top: 0.5em; } /* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * main page sections * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ */ div#page-header img { padding: 0; display: block; margin: -70px 0 1px 2em; width: 248px; height: 70px; } div#page-header p.apache { background-color: #405871; color: #fff; padding: 0 0 0 248px; margin: 0; text-align: center; vertical-align: middle; font-size: 16px; font-weight: bold; line-height: 29px; } div#page-header p.menu { text-align: right; font-size: 13px; margin: 30px 0 0.5em 0; padding: 0; } /* breadcrumb navigation */ div.qindex, div#path { text-align:center; margin: 0.2em 0 1.2em 30px; padding: 0; font-size: 13px; } p { line-height: 1.3em; } /* page footer */ /* ====================== */ div#footer { /* margin-left: 30px; */ font-size: 13px; border-top: 1px solid #405871; padding-top: 0.2em; } div#footer p.apache { float: left; text-align: left; padding: 0 0 1em 0; margin-top: 0; } div#footer p.menu { float: right; text-align: right; margin-top: 0; padding: 0 0 1em 0; } /* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * -> The End (modified doxygen-generated stylesheet below) <- * ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ */ CAPTION { font-weight: bold } A.qindex { font-weight: bold; } A.qindexHL { font-weight: bold; background-color: #405871; color: #ffffff; padding: 2px 6px; } A.qindexHL:hover { background-color: #405871; color: #ffffff; } A.qindexHL:visited { background-color: #405871; color: #ffffff } A.el { font-weight: bold } A.elRef { font-weight: bold } DL.el { margin-left: -1cm } PRE.fragment { border: 1px solid #CCCCCC; background-color: #f5f5f5; margin-top: 4px; margin-bottom: 4px; margin-left: 2px; margin-right: 8px; padding-left: 6px; padding-right: 6px; padding-top: 4px; padding-bottom: 4px; } DIV.fragment { border: 1px solid #CCCCCC; background-color: #f5f5f5; padding: 6px; } DIV.ah { background-color: black; font-weight: bold; color: #ffffff; margin-bottom: 3px; margin-top: 3px } TD.md { background-color: #F4F4FB; font-weight: bold; } TD.mdname1 { background-color: #F4F4FB; font-weight: bold; color: #602020; } TD.mdname { background-color: #F4F4FB; font-weight: bold; color: #602020; width: 600px; } DIV.groupHeader { margin-left: 16px; margin-top: 12px; margin-bottom: 6px; font-weight: bold; } DIV.groupText { margin-left: 16px; font-style: italic; font-size: smaller } BODY { background: white; color: black; margin-right: 20px; margin-left: 30px; } TD.indexkey { background-color: #eeeeff; font-weight: bold; padding-right : 10px; padding-top : 2px; padding-left : 10px; padding-bottom : 2px; margin-left : 0px; margin-right : 0px; margin-top : 2px; margin-bottom : 2px; border: 1px solid #CCCCCC; } TD.indexvalue { background-color: #eeeeff; font-style: italic; padding-right : 10px; padding-top : 2px; padding-left : 10px; padding-bottom : 2px; margin-left : 0px; margin-right : 0px; margin-top : 2px; margin-bottom : 2px; border: 1px solid #CCCCCC; } TR.memlist { background-color: #f0f0f0; } P.formulaDsp { text-align: center; } IMG.formulaDsp { } IMG.formulaInl { vertical-align: middle; } SPAN.keyword { color: #008000 } SPAN.keywordtype { color: #604020 } SPAN.keywordflow { color: #e08000 } SPAN.comment { color: #800000 } SPAN.preprocessor { color: #806020 } SPAN.stringliteral { color: #002080 } SPAN.charliteral { color: #008080 } .mdTable { border: 1px solid #868686; background-color: #F4F4FB; } .mdRow { padding: 8px 10px; } .mdescLeft { font-size: smaller; font-style: italic; background-color: #FAFAFA; padding-left: 8px; border-top: 1px none #E0E0E0; border-right: 1px none #E0E0E0; border-bottom: 1px none #E0E0E0; border-left: 1px none #E0E0E0; margin: 0px; } .mdescRight { font-size: smaller; font-style: italic; background-color: #FAFAFA; padding-left: 4px; border-top: 1px none #E0E0E0; border-right: 1px none #E0E0E0; border-bottom: 1px none #E0E0E0; border-left: 1px none #E0E0E0; margin: 0px; padding-bottom: 0px; padding-right: 8px; } .memItemLeft { padding: 1px 0px 0px 8px; margin: 4px; border-top-width: 1px; border-right-width: 1px; border-bottom-width: 1px; border-left-width: 1px; border-top-style: solid; border-top-color: #E0E0E0; border-right-color: #E0E0E0; border-bottom-color: #E0E0E0; border-left-color: #E0E0E0; border-right-style: none; border-bottom-style: none; border-left-style: none; background-color: #FAFAFA; font-size: 12px; } .memItemRight { padding: 1px 0px 0px 8px; margin: 4px; border-top-width: 1px; border-right-width: 1px; border-bottom-width: 1px; border-left-width: 1px; border-top-style: solid; border-top-color: #E0E0E0; border-right-color: #E0E0E0; border-bottom-color: #E0E0E0; border-left-color: #E0E0E0; border-right-style: none; border-bottom-style: none; border-left-style: none; background-color: #FAFAFA; font-size: 13px; } td.tiny { font-size: 75%; } /* a { color: #252E78; } a:visited { color: #3D2185; } */ rapache-1.2.8/libapreq2/docs/html/doxygen.png0000644000175100017510000000240112706745114020417 0ustar ondrejondrej‰PNG  IHDRd-ok>ÂgAMAÖØÔOX2tEXtSoftwareAdobe ImageReadyqÉe<]PLTEǾÏ"&©ÈÎï¶»ÖÓÚú“¢Þ ¬à¶Âõ‡§ÕÙêÉÊÎáâæ{ŽÔ¡ëˆ™× ²ø§¬¹ÀÀ±ÝÝÎùùéõõçëëåED9×ÖËhg]_X<@:#mhUÿÿÿÝÀ1tRNSÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÿÍvÿIDATxÚbC£: d#„„………h` @¡X",***LKˆ.–], ºX@t± €èb @ÑÅ€BµD„6–š%""´° € ˜% ˆ™B:H¢ˆ²Áf@• ˆRPy"K`\PbC(!II!h©…ëƒ(ñ„Ä!ꈬC„Ä…àl!0[X\J\$TMˆ(’>a$S„ Ù@ Ш@R.$‚¬LJBR¢‰AÌG1 ¬ Â(FȃÔPhhÁTÀ¢„%!`€&q°%u P ¹¢ ¬ € ¹CT$B¢à|‚ºW„¤Àl £!B`R$( …Ĉ‘’ž@AÅ%ĤÄ%@,(—ʂڱ%$ÁââRPmB U`1IˆYB  99€\1 yCCCÿf"[N 'Ü=TGÈ’øl8˜^Kû5<êSæRɤ”%î@@ à›Ê b1 qÅAXHˆ¸&ØB’R y n˜P„Ìã–4A €€j¹€€>Ü ˜ t!˜+(.ÈÅWQ±A2ÜÜMUÜ‚’’‚‚â `1 %`19€F< 3cZÄ`óe!\ˆ DÈ+. 83‹³Àä¸!lYYA -6‚EJŠ¢V €@©žXXX 4„å Ê@86Ð`RdB´€4I "Ý "–@xrÊŒ‚H€AÊ`—f ÉȰCŒ"XV0ɲ³C b@2…¬H ¬È“ p)!(ì‚ 0Ž4ˆ)(%RÁÎ ¶$€TÊ€¥Àþb‡b,säÐ@7À üѰ‚Òî?f¥Ö—\PIx!I´¦"”Ȉ’3¨ QY˜ÿt^^ÛØgv- }>WJOAV`$&#”¦8ùøø8€\FF ›SFJ$ÂÆ€ÐƊС䈉ÀÀ 4ª…Èäå -Á§‡ €H²…—ŸŸŸf ?ðâ5„ €k1Âd‰,ŒÃ ³ƒ“€.€"­F™ËË€àñ‚½ÁIÈ€"±Ù4ÉH gx|‚f©m)))9´. aMDƒ& ºX@t± €èb @ÑÅ€¢‹%DKˆ.–], ºX@t± €èb @€d`‚ɽSµOIEND®B`‚rapache-1.2.8/libapreq2/docs/html/feather.gif0000644000175100017510000001450712706745114020353 0ustar ondrejondrejGIF89aøF÷‚þŽþ®úúþoýOþ5­üËþýËþãþþäÿŽüpý¢`þXoý3ÿè«‹Püp•sú/ýîϤn6üK¬ûc®JŽ+ Š ¼3PÝnܪVÃF¤w@qU j §:¬ÃO+„8 ÉÚ2ä$r)ÇÐ7ÕRš úù÷Ê.ü‘8ÔѲfÍêèå–“†mi[|}eàãCCCX7¾º©QPKïïïä æ!!!¯¬•___..-ppoöf ŽsüÈ£þó㌆£—‘——•Ówô«š››ì¸›ÏÏÏÜ×ÈËÇÀ°¯®ç’fßàßüç¨ýåíýªV¿¿¿ôßЃ‚k-3û™"êgañÊ^Êr3ÍŠWÕ´@Ö’ó—ee_x’ay’)Rz?n7hDf‡8i6[ýþÿGt<`ƒ3fÿÿÿ!ù‚,øF@ÿ H° Áƒ*\Ȱ¡Ã‡#Jœ8Q‰Š3jÜȱ£Ç{Pù A‚"B„ø0ãÅ;¼ìADI$Y”“L•/{„‰2"Ñ'iz€\Ê´iS5+I–trÇŽ¨²ò¸ÐD‚` A€À€1RX À â ˆ B@ì4$Ê3E¦,A2D 0E0]¼Ã¥N#Kž|¥rå+@8° sŽ9¾‚¢@ÙÓÔ²U‘ë¸ ,¨x-W èÖm¡A'NT®AC’—P̸¹Q EÂ@؃ “!L¾0™Ìi4?~lÿAžŠ^¿ÆX‘2kI NP\ö´Žêëp¡¢mœÐŸk¸Àܵ›n,Dà›Ñ‚ÃU &h\%tœ xà܈xPB†QÂpFpÀ‹,X @tP…]D]taDP¬EvFLFwK©Ñz¢™F€ ¥…EL‚eÚ©ù×*¸ÀA^`ÊðÀ°å%à ,èæ[ Ôðbn ž „1!…¨¨á†%d`‚ %ˆHâ `Üœ-± ĸÛpÀ²%À宵եj¬–W<|@…Q’0Al0Á°RÿðB«Aþ6£ ð‡@™ŒyMú& rBXa -§ Î—ÁqÏ‚¢‚2Gè¶ÏaàÁ Dp§o0z,´Ð€”k®xÁ†+lp)€¬ÀY¸°/¿$(Ð<”D^V!Þ3 Ê ®¾J G,k«Ã0ƒ k;" «jh¸í‚+C G0 C¹ç2`—ƒ»E ¨nè2˜È0éÍ Ü&€ËÂÖ˜W ²! %.<ÐÖZMÿC¾ü^ Ãi1Äp €uié¶ä(4%ñ ‚Y‰€ƒJ0бÃܵDÁݲR0Ä/èÿ-1 ­ÂàôÓ`I`é^- Â.¨µõÔ[“e^ÝpYVÞ€Bäg¥0¥Àk}Ú” œ ÁI8QRÛV}@ pï@à ³Û È3Ѐ#Ðp;ÈtoüñÈ'üP§¦±†G‚±ÓaÔÃF<ÑEõÊwï=C=¸áFxT”/üî¥ÂÙKæPÚiƒY1ÐW 1EP@±DJƒ¤0½ídJXBQÇ'\ä{<žà¶Öå`l xœ“Êr–$Ü >fI¶ôšzå%HÙ›àÕ›M¨Ó^˜0…)ŒÀc#B ÁBä eàÂÂÿvà6l?¢ÛpÀö9NléÉAjØòLt)dd¬ÔLM¾9Áº|óuÅ‘VŸüTnåÁˆcj4,p0H  z¤…(Lá Üó¡F†0„+Ìa\ @|çÕq¦ î³ÚÅš&à>N#P—p} …{@mæò%0)hA_$£„†Ã4òiCÀ–pH(8š@E@¨pÒd^= R:›”€üó€”å !ƒ²°Aô  ü«‘7&.+„ Úã'ä€`(ØÌ’¼–$.£äU Â$J0ýLe`ÔnÈh;)«%8ðÔÿ!Xrè8l Qˆ¸E( t @°*´ì.G8a\T€Î¡å jW‹¬¤€ \°3+¸JÂ0ð½no{Û€¬`à·W½®ŠXúS°¡YJ# þÄSÌ[%(ð¾œoµ‹1‚YnÂå4¨;³Ë Zf̨gV‘ D™)ö .ª¢¾D—~é k§ñܧ¼‚*-‰W ·À1Ý ’ `f@X½ÀUA€)J7 ØZöU,uiVé…+¥²Š„Û——®  L4 )¥¾úÅÿ¬%™lËbð/´ ®-.ÈhYÀB‚|s X\ãP€Òÿ‘mª3À 𙳙ä¯ûh§ànD´+ñî A‘”¤‚Þ T5A¬`ºÑ­.ðCÛÇe33XȮ˱^à¼+À np÷Mw8ØXtApƒÎ4Á!ƒ.s÷Ëßþúw¿_˜BÈÿøÀ©ÌBˆ3`!'m„ÀPŒ fm(0‚7,™+XÁ ^ðBJT¢•²ó+hBgäÙ pKèIˆ`ê¤ B¤Ðœ'ˆAÃòDàÀ…" q<(yêšpó0©£¯=ÝEE;8Ìj*?"BÛÐ…%haš‚ Ã?öG ùÌQH¬•Ì´øÿÉ{3“@@~uVF­ `“¬ A/Š'¼ÒÔ€½Àx Kx–†"±³·ûH³¸`ŠŸlK¨í¤ð²â(WmñÆEóŒÀ=ñéq±ƒ;–€wPc¢ ÅÚžhAoàUÔ ”'ŒXÀl¯Å@Å Õ@Òð#‚„ ZйqàoäR¡Øç•Ÿ©¡ÍÈeþu&uÿT |wæÅ‹¸“Sjz5`E‚×+T€nÈClœå¸ ú­Žë²º×Tuo2)¶!)X/–RLk!Vü‚%«už†6>Pþez%+<@_•7pyô±A¡“5ÛGBOíÇ.‚öjº7OdÔwBÅ"KÖr"2P³7(†.pçv—~*L.Ãb’)þÁ§¢³Zôå+ÐgƒÃ6Ãe\w……R)•7ó7z£RlPz+¤&-pîBFRBPFô(ò'!Ò!²´ƒAå-EU4ir&ëò"9ó"”âPç)`",:ãEë|³ÿ¡4NH8Q³¦å5¨±QVÒ:¯c #áAWýÅW€•1}•R{#+cX}+°ò®ø30 ¤‡…R(ØrÞrP0ȆºAˆ wæ‚~„¸2Tulø&2W'84ug/mᄎi¡/oÑ"¤Y…Sg«%IŸByé¡9ðQgïá0`d/P]6A0²Â;cFQ^-ñR+ÅŠA0ïˆRw³73E„/cU°±UdB P3øg.s‚¿r/ÍèŒna°ñŒÓø2PÞG‰gA]c‰g…8¬u5`b¡áóQ’p³uAªsÿÆ6¶ó:0AW±4ÿ°MãÁŽ;Çx+‰†³ò7c81­òèÔU ø/ûÁI«UšÓYOYkqZc‰eWi‰1°‘hA’`‘¤E‰.@é!pçµ$g³gMôLÄ6•…°6à0½C3@RrÓ;Çi,%+}X3pQ¡3]Œ#9+€ã8ŽViL" •´åRäVm¹]a_(@U–ã:&Þ¨žóopÇU—ÂcP^QWú˜¸™›º)ZP`¶›À)dL0dÐe`Ò÷Õ!¿œÎ =àGL@X P€|!½–>!{€Éùœâÿyi^`àA^ePVp$ñ3VDÀwÌ =Y q=EÐÑ'žþih >n°H4ptìÃdÿv66€>&A=†!ŸJýƒF a i Qþ£-“öŸ¹lÊçZ;Ã%G'E¯eg•‰'yu?EY`GS`ò™`aàhÍK o :oëY¤"7YA<°MäD²•@gw&Bj…P8ù3ˤKÀwXðS ¤Ám€#"U ¦CdWàå×0rZ“ë3N(™a¡[y¥"ôˆ\b/_õÛ¡?Q€€¡Ha¦?ÿ–C6’*u@1©:©“8ðšAùqôl ZâIQ“’Œrn"††#Pƒ1?FP«ƒ"?©ÿö«ÅÆ©G'P*%ŒS¬bqQ™Ð¿buïT'° ‡k¯êhë¶-O€Ê«wås}ñ“ÇdÇ*t–p$:vÖ®˜ÂgÁ’B“2,êg-Pt‚O)ÒÅ¡LR0‹ÎñOP ®Ì5#ññ!6 Y[ÅŠ:ð®MCB\âþqE*`;h+ã~Û¦,d'-;5KÛrH jª°ÝbJà°sŠ}éÿZ:@±ð“5vJ¥ê„}ÆNA[,¾ç °–{@@!@àÒ’"û×À3RàGZ€mY`F°Rà­.û–AHC@…TF i胢ÞTBÇÓl¢mu{ªîDŒ¦)h¨~ €,2¨'G(;(zp¤=0ì†êÆnEP\ûn¶!©“Êrp°¹p0Uä¤îáKj“Æ™át8™ú±öbªèt4xk,(˜zn˜{ê²O¬„GiG"ØÂvøä @]pQPQ‰önSÐ4¶=–[@TcàØ{tã„/@³/qº<ÿÀÈ¥:0NæRz¥ú’RWE8³ˆoR3pÒúÄm³æmÆQ²{(¿;(ptPÅ‘'»Ç.rx—Qà#R ZÐEÀrk6ŸÒ»¦` ãZ>¶ƒ;¢‹½)yËÖ¤N¤šçU±Í†g[JÒgÝW§¤‚G ƒ÷¤¿bÇ»~’‡ü×-p¿‚{Så2HC&*€w $X`nfÚ¥4`àGáIiV€&aU¬ëN`§#u°’":I¿Ò3IðeŒ‘]Ô €¶Ttƒ9¥cWvkôOQ;"‚F‡+FÈj/" –Rw’ƒw‚ üƒ‚ÿ@c>‘Åü¥¿J}#§ßk;’Ž‰ã‘ ÷YIp8væ.@&}v»±%ä±;Ã{m\­n(!rX !eƒ„[¸ü.d×Ãw‚&/‚4„X¯‹Åy°^˜cÈ‚€sk@`3:ßdgðÚÛ˜!Žþ†©×¼®wÖ€ç´Â±‘ýÆ=ÓP€Æ.puØ6,×2ó¿Ñ­'Ç%;¸üK‹Þâ‰B¼MEqüÌ.hØ&3r_âŒÂç+ð”$°p~@RÐLÔQbPig°¢ ú€dÑIõã$rë%àœŠXmè"ÐË+½ñÆ-@h’{÷ëzM{‚‡¸ÿ<{p´ÃãB¿¼d.”Ò·”RÐv7~ƒóY©±5°$M@£rt`³‹±h¼séÃ>ž3ÆãLμâ§b‚±}&­½×Æ F·×†]篮4vhÓuˆÃ´X"ßb{%@F,Ô‹wÑ{`‚UîT/Jã}h:ea9°…¬)\N=nõd7³5ª©§(ðAðÓ®..c,誀)Ø'¿ØÒoÌÃiÔ!a§SqtÚ×RÓøü¿8!BÀ2 ·‡ˆ×åŒ:Èã—•óZ+Ù8L¦:T? €yW6`7Ap71E"ê[uÈI§æÝGÆ£„,,p»ÌRF¸«»ÿÂ,iÔ´áÖ'±§ƒw¼‡ÁË‹òÄvB31ƒ×ЈÁ"WT/KSÌÛ—¥šn帗"ªŠ}u7ø8†*ÅR®B8ðòm âà?³Bç&.Øvk½'ö§2=v²wÞ;h(³ºGq½h°1Ò2=Í(ò{.«VQ[Å„TÙ€J÷€€M˜:¾ZW"0›ÃÓ_p…I+|ÓRˆUŠfØBÜ]' zGËÍ’"<•ÚoM"в#ð>8r‡BàË-Ⱦ§ÊÁÂ0^UWÕ±@L‘ù„5?eU9` •ëE¡’—Å&Fôëh`OP˜cˆRõ…dÿø*5UXfx"å­ƒYÞ·èƒq(HÅé— €œ êíTQy=YG¯J3/Ô­±Sùn‘YO:g±§¥1`%PÉ8H}Ô¾¥6áÁ0`/p›X˜ žR®ØþØWÉ}7¾‹Ë-=.ßB2E#.üŒ,üìθUŠX€  ˆx×y=,¢2ðš$ ™’š•ŸôY£Æ/95ÿÂ5`ygùMcÓã¾%n“¤¶s70ðBfRþˆéвX‹Œ2Ã;…i˜¬HBˆ")`Ò±×ägˆ=mqÍg[äNqQ~}†E{–)À?BÚXÌ£&5yI ÿWëÑ9VCó³®’,é :&‘hS'‘—5)Ü8 ìB†0Àì#Ð7/€*õ`HX25”5å7ßègtÒ8…“jA,»³±4¾¢%__ꙥ/10|]bÂXÙZ±Nšû­mu–‘I:w’œé>A/( c;.Ûä6v5à¸i7¯¢ŠD9X¬rЇ5SzCÎg[å4c5ü¢ãðºÑæXI0–u›å¨Þ€{ @ªëžóŸâ9®e[‹“:dƒëk©‰ÀD¾å+ÀšCÏç±H\¸;²É«EN1ÅžRÉ]ð/1„UàlPöš~³¢‰8éñ8kÿoã”8s_¡ ª¤éWÚ‘f‰¾æ0¶n…Ÿ1ïqYxx™—; 6Å…;Ya;Û!DÌÀ hDAA .dØÐáCˆ%N¤X1â&l ÐQ#GØpÀä$n(  M,€ã )àY nÜTPt¦ME,ȱ"O:.ä  ÁЧ,‡æ€ A‚8||øâƒ4Ðâ "Ä8FDø°®E¼yõîåÛwáˆ3æŽxð FŒ ‚0¬¸ÐøÂŠ+HHqÁE –-‹‚X‘Ôå ]¿ò¸´‰'9PèÈœƒ gIƒÐü™†$GØà=×ïoàÁ…'þûnÃãŠ1,‡¸¸ñŠäÅ¥O§N< ;rapache-1.2.8/libapreq2/docs/html/files.html0000644000175100017510000000660312706745114020234 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: File Index

libapreq2 File List

Here is a list of all documented files with brief descriptions:
include/apreq.h [code]Main header file..
include/apreq_cookie.h [code]Cookies and Jars
include/apreq_error.h [code]Error status codes
include/apreq_module.h [code]Module API
include/apreq_param.h [code]Request parsing and parameter API
include/apreq_parser.h [code]Request body parser API
include/apreq_util.h [code]Utility functions for apreq
include/apreq_version.h [code]Versioning API for libapreq
module/apache/apreq_module_apache.h [code]
module/apache2/apreq_module_apache2.h [code]
rapache-1.2.8/libapreq2/docs/html/functions.html0000644000175100017510000001600212706745114021134 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: Data Fields
a | b | c | d | f | h | i | j | m | n | p | r | t | u | v

Here is a list of all documented struct and union fields with links to the struct/union documentation for each field:

- a -

- b -

- c -

- d -

- f -

- h -

- i -

- j -

- m -

- n -

- p -

- r -

- t -

- u -

- v -

rapache-1.2.8/libapreq2/docs/html/functions_rela.html0000644000175100017510000000313212706745114022137 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: Data Fields - Related Functions

rapache-1.2.8/libapreq2/docs/html/functions_vars.html0000644000175100017510000001563112706745114022176 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: Data Fields - Variables
a | b | c | d | f | h | i | j | m | n | p | r | t | u | v

- a -

- b -

- c -

- d -

- f -

- h -

- i -

- j -

- m -

- n -

- p -

- r -

- t -

- u -

- v -

rapache-1.2.8/libapreq2/docs/html/globals.html0000644000175100017510000003353012706745114020554 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: Data Fields

Here is a list of all documented functions, variables, defines, enums, and typedefs with links to the documentation:

- a -

rapache-1.2.8/libapreq2/docs/html/globals_defs.html0000644000175100017510000001111312706745114021546 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: Data Fields

- a -

rapache-1.2.8/libapreq2/docs/html/globals_enum.html0000644000175100017510000000402712706745114021577 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: Data Fields

rapache-1.2.8/libapreq2/docs/html/globals_eval.html0000644000175100017510000000455112706745114021564 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: Data Fields

rapache-1.2.8/libapreq2/docs/html/globals_func.html0000644000175100017510000002311012706745114021560 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: Data Fields

- a -

rapache-1.2.8/libapreq2/docs/html/globals_type.html0000644000175100017510000000476512706745114021625 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: Data Fields

rapache-1.2.8/libapreq2/docs/html/group__apreq__lang.html0000644000175100017510000000375112706745114022756 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: Language Bindings

Language Bindings

libapreq2 APIs for programming languages other than C More...


Modules

 Perl
 XS Modules.

Detailed Description

libapreq2 APIs for programming languages other than C

XXX

rapache-1.2.8/libapreq2/docs/html/group__apreq__module.html0000644000175100017510000000423012706745114023313 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: Modules

Modules

apreq2 modules included in libapreq2-2.05-dev. More...


Modules

 Apache 2.X Filter Module
 mod_apreq2 - DSO that ties libapreq2 to Apache HTTPD 2.X.

Detailed Description

apreq2 modules included in libapreq2-2.05-dev.

XXX

rapache-1.2.8/libapreq2/docs/html/group__apreq__xs.html0000644000175100017510000000442312706745114022464 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: Perl

Perl
[Language Bindings]

XS Modules. More...

Modules

 Apache2::Request
 Apache2::Upload
 Apache2::Cookie

Detailed Description

XS Modules.

rapache-1.2.8/libapreq2/docs/html/group__apreq__xs__cookie.html0000644000175100017510000003663512706745114024166 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: Apache2::Cookie

Apache2::Cookie
[Perl]


NAME

Apache2::Cookie, Apache2::Cookie::Jar - HTTP Cookies Class


SYNOPSIS

    use Apache2::Cookie;
    $j = Apache2::Cookie::Jar->new($r);
    $c_in = $j->cookies("foo");         # get cookie from request headers
    $c_out = Apache2::Cookie->new($r, 
                                  -name  => "mycookie",
                                  -value => $c_in->name );
    $c_out->path("/bar");               # set path to "/bar"
    $c_out->bake;                       # send cookie in response headers


DESCRIPTION

The Apache2::Cookie module is based on the original 1.X versions, which mimic the CGI::Cookie API. The current version of this module includes several packages and methods which are patterned after Apache2::Request, yet remain largely backwards-compatible with the original 1.X API (see the PORTING from 1.X section below for known issues).

This manpage documents the Apache2::Cookie and Apache2::Cookie::Jar packages.


Apache2::Cookie::Jar

This class collects Apache2::Cookie objects into a lookup table. It plays the same role for accessing the incoming cookies as Apache2::Request does for accessing the incoming params and file uploads.

new

    Apache2::Cookie::Jar->new($env, %args)

Class method that retrieves the parsed cookie jar from the current environment. An optional VALUE_CLASS => $class argument instructs the jar to bless any returned cookies into $class instead of Apache2::Cookie. This feature is meant to be useful in situations where Apache2::Cookie::thaw() is unable to correctly interpret an incoming cookie's serialization. Users can simply override thaw in an application-specific subclass and pass that subclass's name as the VALUE_CLASS argument:

    {
        package FOO;
        @ISA= 'Apache2::Cookie';
    }
    my $jar = Apache2::Cookie::Jar->new($r, VALUE_CLASS => "FOO");
    ok $jar->cookies("foo")->isa("FOO");
    ok $jar->cookies->{bar}->isa("FOO");

cookies

    $jar->cookies()
    $jar->cookies($key)

Retrieve cookies named $key with from the jar object. In scalar context the first such cookie is returned, and in list context the full list of such cookies are returned.

If the $key argument is omitted, scalar $jar->cookies() will return an APR::Request::Cookie::Table object containing all the cookies in the jar. Modifications to the this object will affect the jar's internal cookies table in apreq_jar_t, so their impact will be noticed by all libapreq2 applications during this request.

In list context $jar->cookies() returns the list of names for all the cookies in the jar. The order corresponds to the order in which the cookies appeared in the incoming ``Cookie'' header.

This method will throw an APR::Request::Error object into $@ if the returned value(s) could be unreliable. In particular, note that scalar $jar->cookies("foo") will not croak if it can locate the a ``foo'' cookie within the jar's parsed cookie table, even if the cookie parser has failed (the cookies are parsed in the same order as they appeared in the ``Cookie'' header). In all other circumstances cookies will croak if the parser failed to successfully parse the ``Cookie'' header.

    $c = Apache2::Cookie->new($r, name => "foo", value => 3);
    $j->cookies->add($c);
    $cookie = $j->cookies("foo");  # first foo cookie
    @cookies = $j->cookies("foo"); # all foo cookies
    @names = $j->cookies();        # all cookie names

status

    $jar->status()
    $jar->status($set)

Get or set the APR status code of the cookie parser: APR_SUCCESS on success, error otherwise.

    $j->status(-1);
    ok $j->status == -1;
    eval { @cookies = $j->cookies("foo") };   # croaks
    ok $@->isa("Apache2::Cookie::Jar::Error");
    $j->status(0);


Apache2::Cookie

new

    Apache2::Cookie->new($env, %args)

Just like CGI::Cookie::new, but requires an additional environment argument:

    $cookie = Apache2::Cookie->new($r,
                             -name    =>  'foo', 
                             -value   =>  'bar', 
                             -expires =>  '+3M', 
                             -domain  =>  '.capricorn.com', 
                             -path    =>  '/cgi-bin/database',
                             -secure  =>  1 
                            );

The -value argument may be either an arrayref, a hashref, or a string. Apache2::Cookie::freeze encodes this argument into the cookie's raw value.

freeze

    Apache2::Cookie->freeze($value)

Helper function (for new) that serializes a new cookie's value in a manner compatible with CGI::Cookie (and Apache2::Cookie 1.X). This class method accepts an arrayref, hashref, or normal perl string in $value.

    $value = Apache2::Cookie->freeze(["2+2", "=4"]);

thaw

    Apache2::Cookie->thaw($value)
    $cookie->thaw()

This is the helper method (for value) responsible for decoding the raw value of a cookie. An optional argument $value may be used in place of the cookie's raw value. This method can also decode cookie values created using CGI::Cookie or Apache2::Cookie 1.X.

    print $cookie->thaw;                    # prints "bar"
    @values = Apache2::Cookie->thaw($value); # ( "2+2", "=4" )

as_string

    $cookie->as_string()

Format the cookie object as a string. The quote-operator for Apache2::Cookie is overloaded to run this method whenever a cookie appears in quotes.

    ok "$cookie" eq $cookie->as_string;

name

    $cookie->name()

Get the name of the cookie.

value

    $cookie->value()

Get the (unswizzled) value of the cookie:

    my $value = $cookie->value;
    my @values = $cookie->value;

Note: if the cookie's value was created using a freeze method, one way to reconstitute the object is by subclassing Apache2::Cookie with a package that provides the associated thaw sub:

    {
        package My::COOKIE;
        @ISA = 'Apache2::Cookie'; 
        sub thaw { my $val = shift->raw_value; $val =~ tr/a-z/A-Z/; $val }
    }
    bless $cookie, "My::COOKIE";
    ok $cookie->value eq "BAR";

raw_value

    $cookie->raw_value()

Gets the raw (opaque) value string as it appears in the incoming ``Cookie'' header.

    ok $cookie->raw_value eq "bar";

bake

    $cookie->bake($r)

Adds a Set-Cookie header to the outgoing headers table.

bake2

    $cookie->bake2($r)

Adds a Set-Cookie2 header to the outgoing headers table.

domain

    $cookie->domain()
    $cookie->domain($set)

Get or set the domain for the cookie:

    $domain = $cookie->domain;
    $cookie->domain(".cp.net");

path

    $cookie->path()
    $cookie->path($set)

Get or set the path for the cookie:

    $path = $cookie->path;
    $cookie->path("/");

version

    $cookie->version()
    $cookie->version($set)

Get or set the cookie version for this cookie. Netscape spec cookies have version = 0; RFC-compliant cookies have version = 1.

    ok $cookie->version == 0;
    $cookie->version(1);
    ok $cookie->version == 1;

expires

    $cookie->expires()
    $cookie->expires($set)

Get or set the future expire time for the cookie. When assigning, the new value ($set) should match /^\+?(\d+)([YMDhms]?)$/ $2 qualifies the number in $1 as representing ``Y''ears, ``M''onths, ``D''ays, ``h''ours, ``m''inutes, or ``s''econds (if the qualifier is omitted, the number is interpreted as representing seconds). As a special case, $set = ``now'' is equivalent to $set = ``0''.

    my $expires = $cookie->expires;
    $cookie->expires("+3h"); # cookie is set to expire in 3 hours

secure

    $cookie->secure()
    $cookie->secure($set)

Get or set the secure flag for the cookie:

    $cookie->secure(1);
    $is_secure = $cookie->secure;
    $cookie->secure(0);

comment

    $cookie->comment()
    $cookie->comment($set)

Get or set the comment field of an RFC (Version > 0) cookie.

    $cookie->comment("Never eat yellow snow");
    print $cookie->comment;

commentURL

    $cookie->commentURL()
    $cookie->commentURL($set)

Get or set the commentURL field of an RFC (Version > 0) cookie.

    $cookie->commentURL("http://localhost/cookie.policy";);
    print $cookie->commentURL;

fetch

    Apache2::Cookie->fetch($r)

Fetch and parse the incoming Cookie header:

    my $cookies = Apache2::Cookie->fetch($r); # APR::Request::Cookie::Table ref
    my %cookies = Apache2::Cookie->fetch($r);


PORTING from 1.X

Changes to the 1.X API:


SEE ALSO

the Apache2::Request manpage, the APR::Request::Cookie manpage, the APR::Request::Error manpage, CGI::Cookie(3)


COPYRIGHT

  Copyright 2003-2005  The Apache Software Foundation
  Licensed under the Apache License, Version 2.0 (the "License");
  you may not use this file except in compliance with the License.
  You may obtain a copy of the License at
      http://www.apache.org/licenses/LICENSE-2.0
  Unless required by applicable law or agreed to in writing, software
  distributed under the License is distributed on an "AS IS" BASIS,
  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  See the License for the specific language governing permissions and
  limitations under the License.
rapache-1.2.8/libapreq2/docs/html/group__apreq__xs__request.html0000644000175100017510000004430312706745114024374 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: Apache2::Request

Apache2::Request
[Perl]


NAME

Apache2::Request - Methods for dealing with client request data


SYNOPSIS

    use Apache2::Request;
    $req = Apache2::Request->new($r);
    @foo = $req->param("foo");
    $bar = $req->args("bar");


DESCRIPTION

The Apache2::Request module provides methods for parsing GET and POST parameters encoded with either application/x-www-form-urlencoded or multipart/form-data. Although Apache2::Request provides a few new APIs for accessing the parsed data, it remains largely backwards-compatible with the original 1.X API. See the PORTING from 1.X section below for a list of known issues.

This manpage documents the Apache2::Request package.


Apache2::Request

The interface is designed to mimic the CGI.pm routines for parsing query parameters. The main differences are

new

    Apache2::Request->new($r, %args)

Creates a new Apache2::Request object.

    my $req = Apache2::Request->new($r, POST_MAX => "1M");

With mod_perl2, the environment object $r must be an Apache2::RequestRec object. In that case, all methods from Apache2::RequestRec are inherited. In the (default) CGI environment, $r must be an APR::Pool object.

The following args are optional:

  • POST_MAX, MAX_BODY
  • Limit the size of POST data (in bytes).

  • DISABLE_UPLOADS
  • Disable file uploads.

  • TEMP_DIR
  • Sets the directory where upload files are spooled. On a *nix-like that supports link(2), the TEMP_DIR should be located on the same file system as the final destination file:
     use Apache2::Upload;
     my $req = Apache2::Request->new($r, TEMP_DIR => "/home/httpd/tmp");
     my $upload = $req->upload('file');
     $upload->link("/home/user/myfile");

    For more details on link, see the Apache2::Upload manpage.

  • HOOK_DATA
  • Extra configuration info passed as the fourth argument to an upload hook. See the description for the next item, UPLOAD_HOOK.

  • UPLOAD_HOOK
  • Sets up a callback to run whenever file upload data is read. This can be used to provide an upload progress meter during file uploads. Apache will automatically continue writing the original data to $upload->fh after the hook exits.
      my $transparent_hook = sub {
        my ($upload, $data, $data_len, $hook_data) = @_;
        warn "$hook_data: got $data_len bytes for " . $upload->name;
      };
      my $req = Apache2::Request->new($r, 
                                      HOOK_DATA => "Note",
                                      UPLOAD_HOOK => $transparent_hook,
                                     );

instance

    Apache2::Request->instance($r)

The default (and only) behavior of Apache2::Request is to intelligently cache POST data for the duration of the request. Thus there is no longer the need for a separate instance() method as existed in Apache2::Request for Apache 1.3 - all POST data is always available from each and every Apache2::Request object created during the request's lifetime.

However an instance() method is aliased to new() in this release to ease the pain of porting from 1.X to 2.X.

param

    $req->param()
    $req->param($name)

Get the request parameters (using case-insensitive keys) by mimicing the OO interface of CGI::param.

    # similar to CGI.pm
    my $foo_value   = $req->param('foo');
    my @foo_values  = $req->param('foo');
    my @param_names = $req->param;
    # the following differ slightly from CGI.pm
    # returns ref to APR::Request::Param::Table object representing 
    # all (args + body) params
    my $table = $req->param;
    @table_keys = keys %$table;

In list context, or when invoked with no arguments as $req->param(), param induces libapreq2 to read and parse all remaining data in the request body. However, scalar $req->param("foo") is lazy: libapreq2 will only read and parse more data if

    1) no "foo" param appears in the query string arguments, AND
    2) no "foo" param appears in the previously parsed POST data.

In this circumstance libapreq2 will read and parse additional blocks of the incoming request body until either

    1) it has found the the "foo" param, or 
    2) parsing is completed.

Observe that scalar $req->param("foo") will not raise an exception if it can locate ``foo'' in the existing body or args tables, even if the query-string parser or the body parser has failed. In all other circumstances param will throw an Apache2::Request::Error object into $@ should either parser fail.

    $req->args_status(1); # set error state for query-string parser 
    ok $req->param_status == 1;
    $foo = $req->param("foo");
    ok $foo == 1;
    eval { @foo = $req->param("foo") };
    ok $@->isa("Apache2::Request::Error");
    undef $@;
    eval { my $not_found = $req->param("non-existent-param") };
    ok $@->isa("Apache2::Request::Error");
    $req->args_status(0); # reset query-string parser state to "success"

Note: modifications to the scalar $req->param() table only affect the returned table object (the underlying C apr_table_t is generated from the parse data by apreq_params()). Modifications do not affect the actual request data, and will not be seen by other libapreq2 applications.

parms, params

The functionality of these functions is assumed by param, so they are no longer necessary. Aliases to param are provided in this release for backwards compatibility, however they are deprecated and may be removed from a future release.

body

    $req->body()
    $req->body($name)

Returns an APR::Request::Param::Table object containing the POST data parameters of the Apache2::Request object.

    my $body = $req->body;

An optional name parameter can be passed to return the POST data parameter associated with the given name:

    my $foo_body = $req->body("foo");

More generally, body() follows the same pattern as param() with respect to its return values and argument list. The main difference is that modifications to the scalar $req->body() table affect the underlying apr_table_t attribute in apreq_request_t, so their impact will be noticed by all libapreq2 applications during this request.

upload

    $req->upload()
    $req->upload($name)

Requires Apache2::Upload. With no arguments, this method returns an APR::Request::Param::Table object in scalar context, or the names of all Apache2::Upload objects in list context.

An optional name parameter can be passed to return the Apache2::Upload object associated with the given name:

    my $upload = $req->upload($name);

More generally, upload() follows the same pattern as param() with respect to its return values and argument list. The main difference is that its returned values are Apache2::Upload object refs, not simple scalars.

Note: modifications to the scalar $req->upload() table only affect the returned table object (the underlying C apr_table_t is generated by apreq_uploads()). They do not affect the actual request data, and will not be seen by other libapreq2 applications.

args_status

    $req->args_status()
    $req->args_status($set)

Get/set the APR status code of the query-string parser. APR_SUCCESS on success, error otherwise.

body_status

    $req->body_status()
    $req->body_status($set)

Get/set the current APR status code of the parsed POST data. APR_SUCCESS when parser has completed, APR_INCOMPLETE if parser has more data to parse, APR_EINIT if no post data has been parsed, error otherwise.

param_status

    $req->param_status()

In scalar context, this returns args_status if there was an error during the query-string parse, otherwise this returns body_status, ie

    $req->args_status || $req->body_status

In list context param_status returns the list (args_status, body_status).

parse

    $req->parse()

Forces the request to be parsed immediately. In void context, this will throw an APR::Request::Error should the either the query-string or body parser fail. In all other contexts it will return the two parsers' combined APR status code

    $req->body_status || $req->args_status

However parse should be avoided in most normal situations. For example, in a mod_perl content handler it is more efficient to write

    sub handler {
        my $r = shift;
        my $req = Apache2::Request->new($r);
        $r->discard_request_body;   # efficiently parses the request body
        my $parser_status = $req->body_status;
        #...
    }

Calling $r->discard_request_body outside the content handler is generally a mistake, so use $req->parse there, but only as a last resort. The Apache2::Request API is designed around a lazy-parsing scheme, so calling parse should not affect the behavior of any other methods.


SUBCLASSING Apache2::Request

If the instances of your subclass are hash references then you can actually inherit from Apache2::Request as long as the Apache2::Request object is stored in an attribute called ``r'' or ``_r''. (The Apache2::Request class effectively does the delegation for you automagically, as long as it knows where to find the Apache2::Request object to delegate to.) For example:

        package MySubClass;
        use Apache2::Request;
        our @ISA = qw(Apache2::Request);
        sub new {
                my($class, @args) = @_;
                return bless { r => Apache2::Request->new(@args) }, $class;
        }


PORTING from 1.X

This is the complete list of changes to existing methods from Apache2::Request 1.X. These issues need to be addressed when porting 1.X apps to the new 2.X API.


SEE ALSO

the APR::Request::Param manpage, the APR::Request::Error manpage, the Apache2::Upload manpage, the Apache2::Cookie manpage, APR::Table(3).


COPYRIGHT

  Copyright 2003-2005  The Apache Software Foundation
  Licensed under the Apache License, Version 2.0 (the "License");
  you may not use this file except in compliance with the License.
  You may obtain a copy of the License at
      http://www.apache.org/licenses/LICENSE-2.0
  Unless required by applicable law or agreed to in writing, software
  distributed under the License is distributed on an "AS IS" BASIS,
  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  See the License for the specific language governing permissions and
  limitations under the License.
rapache-1.2.8/libapreq2/docs/html/group__apreq__xs__upload.html0000644000175100017510000002545112706745114024173 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: Apache2::Upload

Apache2::Upload
[Perl]


NAME

Apache2::Upload - Methods for dealing with file uploads.


SYNOPSIS

    use Apache2::Upload;
    $req = Apache2::Request->new($r);
    $upload = $req->upload("foo");
    $size = $upload->size;
    # three methods to get at the upload's contents ... slurp, fh, io
    $upload->slurp($slurp_data);
    read $upload->fh, $fh_data, $size;
    ok $slurp_data eq $fh_data;
    my $io = $upload->io;
    print while <$io>;


DESCRIPTION

Apache2::Upload is a new module based on the original package included in Apache2::Request 1.X. Users requiring the upload API must now use Apache2::Upload, which adds the upload method to Apache2::Request. Apache2::Upload is largely backwards-compatible with the original 1.X API. See the PORTING from 1.X section below for a list of known issues.

This manpage documents the Apache2::Upload package.


Apache2::Upload

name

    $upload->name()

The name of the HTML form element which generated the upload.

filename

    $upload->filename()

The (client-side) filename as submitted in the HTML form. Note: some agents will submit the file's full pathname, while others may submit just the basename.

fh

    $upload->fh()

Creates filehandle reference to the upload's spooled tempfile, which contains the full contents of the upload.

io

    $upload->io()

Creates a tied IO handle. This method is a more efficient version of fh, but with io the handle ref returned is not seekable. It is tied to an APR::Request::Brigade object, so you may use the brigade API on the tied object if you want to manipulate the IO stream (beyond simply reading from it).

The returned reference is actually an object which has read and readline methods available. However these methods are just syntactic sugar for the underlying READ and READLINE methods from APR::Request::Brigade.

    $io = $upload->io;
    print while $io->read($_); # equivalent to: tied(*$io)->READ($_)

See READ and READLINE below for additional notes on their usage.

bb

    $upload->bb()
    $upload->bb($set)

Get/set the APR::Brigade which represents the upload's contents.

size

    $upload->size()

Returns the size of the upload in bytes.

info

    $upload->info()
    $upload->info($set)

Get/set the additional header information table for the uploaded file. Returns a hash reference tied to the APR::Table class. An optional $table argument can be passed to reassign the upload's internal (apr_table_t) info table to the one $table represents.

    my $info = $upload->info;
    while (my($hdr_name, $hdr_value) = each %$info) {
        # ...
    }
    # fetch upload's Content-Type header
    my $type = $upload->info->{"Content-type"};

type

    $upload->type()

Returns the MIME type of the given Apache2::Upload object.

    my $type = $upload->type;
    #same as
    my $content_type = $upload->info->{"Content-Type"};
    $content_type =~ s/;.*$//ms;

link

    $upload->link()

To avoid recopying the upload's internal tempfile brigade on a *nix-like system, link will create a hard link to it:

  my $upload = $req->upload('foo');
  $upload->link("/path/to/newfile") or
      die sprintf "link from '%s' failed: $!", $upload->tempname;

Typically the new name must lie on the same device and partition as the brigade's tempfile. If this or any other reason prevents the OS from linking the files, link() will instead copy the temporary file to the specified location.

slurp

    $upload->slurp($contents)

Reads the full contents of a file upload into the scalar argument. The return value is the length of the file.

    my $size = $upload->slurp($contents);

tempname

    $upload->tempname()

Provides the name of the spool file.

    my $tempname = $upload->tempname;


APR::Request::Brigade

This class is derived from APR::Brigade, providing additional methods for TIEHANDLE, READ and READLINE. To be memory efficient, these methods delete buckets from the brigade as soon as their data is actually read, so you cannot seek on handles tied to this class. Such handles have semantics similar to that of a read-only socket.

TIEHANDLE

    APR::Request::Brigade->TIEHANDLE($bb)

Creates a copy of the bucket brigade represented by $bb, and blesses that copy into the APR::Request::Brigade class. This provides syntactic sugar for using perl's builtin read, readline, and <> operations on handles tied to this package:

    use Symbol;
    $fh = gensym;
    tie *$fh, "APR::Request:Brigade", $bb;
    print while <$fh>;

READ

    $bb->READ($contents)
    $bb->READ($contents, $length)
    $bb->READ($contents, $length, $offset)

Reads data from the brigade $bb into $contents. When omitted $length defaults to -1, which reads the first bucket into $contents. A positive $length will read in $length bytes, or the remainder of the brigade, whichever is greater. $offset represents the index in $context to read the new data.

READLINE

    $bb->READLINE()

Returns the first line of data from the bride. Lines are terminated by linefeeds (the '\012' character), but we may eventually use $/ instead.


PORTING from 1.X


SEE ALSO

the APR::Request::Param::Table manpage, the APR::Request::Error manpage, the Apache2::Request manpage, APR::Table(3)


COPYRIGHT

  Copyright 2003-2005  The Apache Software Foundation
  Licensed under the Apache License, Version 2.0 (the "License");
  you may not use this file except in compliance with the License.
  You may obtain a copy of the License at
      http://www.apache.org/licenses/LICENSE-2.0
  Unless required by applicable law or agreed to in writing, software
  distributed under the License is distributed on an "AS IS" BASIS,
  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  See the License for the specific language governing permissions and
  limitations under the License.
rapache-1.2.8/libapreq2/docs/html/group__libapreq2.html0000644000175100017510000001111612706745114022361 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: Apache Request Library

Apache Request Library

libapreq2 Version 2.1.0 More...


Files

file  apreq.h
 Main header file...
file  apreq_cookie.h
 Cookies and Jars.
file  apreq_error.h
 Error status codes.
file  apreq_module.h
 Module API.
file  apreq_param.h
 Request parsing and parameter API.
file  apreq_parser.h
 Request body parser API.
file  apreq_util.h
 Utility functions for apreq.
file  apreq_version.h
 Versioning API for libapreq.

Detailed Description

libapreq2 Version 2.1.0

libapreq2 is a shared library based on the Apache Portable Runtime libraries libapr and libaprutil.

See also:
http://apr.apache.org/

Configuring libapreq2 Applications

This package includes apreq2-config, a configuration script for building applications with libapreq2. Run apreq2-config --help to display its options. XXX add examples here XXX rapache-1.2.8/libapreq2/docs/html/group__mod__apreq2.html0000644000175100017510000001671512706745114022702 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: Apache 2.X Filter Module

Apache 2.X Filter Module
[Modules]

mod_apreq2 - DSO that ties libapreq2 to Apache HTTPD 2.X. More...

Functions

apreq_handle_tapreq_handle_apache2 (request_rec *r)

Detailed Description

mod_apreq2 - DSO that ties libapreq2 to Apache HTTPD 2.X.

mod_apreq2 provides the "APREQ2" input filter for using libapreq2 (and allow its parsed data structures to be shared) within the Apache 2.X webserver. Using it, libapreq2 works properly in every phase of the HTTP request, from translation handlers to output filters, and even for subrequests / internal redirects.


Activating mod_apreq2 in Apache 2.X

The installation process triggered by % make install will not modify your webserver's config file. Hence, be sure you activate it on startup by adding a LoadModule directive to your webserver config; e.g.

     LoadModule    modules/mod_apreq2.so

The mod_apreq2 filter is named "APREQ2", and may be used in Apache's input filter directives, e.g.

     AddInputFilter APREQ2         # or
     SetInputFilter APREQ2

However, this is not required because libapreq2 will add the filter (only) if it's necessary. You just need to ensure that your module invokes apreq_handle_apache2() before the content handler ultimately reads from the input filter chain. It is important to realize that no matter how the input filters are initially arranged, the APREQ2 filter will attempt to reposition itself to be the last input filter to read the data.

If you want to use other input filters to transform the incoming HTTP request data, is important to register those filters with Apache as having type AP_FTYPE_CONTENT_SET or AP_FTYPE_RESOURCE. Due to the limitations of Apache's current input filter design, types higher than AP_FTYPE_CONTENT_SET may not work properly whenever the apreq filter is active.

This is especially true when a content handler uses libapreq2 to parse some of the post data before doing an internal redirect. Any input filter subsequently added to the redirected request will bypass the original apreq filter (and therefore lose access to some of the original post data), unless its type is less than the type of the apreq filter (currently AP_FTYPE_PROTOCOL-1).

Server Configuration Directives

Per-directory commands for mod_apreq2
Directive Context DefaultDescription
APREQ2_ReadLimit directory #APREQ_DEFAULT_READ_LIMIT Maximum number of bytes mod_apreq2 will send off to libapreq2 for parsing. mod_apreq2 will log this event and subsequently remove itself from the filter chain.
APREQ2_BrigadeLimit directory #APREQ_DEFAULT_BRIGADE_LIMIT Maximum number of bytes mod_apreq2 will let accumulate within the heap-buckets in a brigade. Excess data will be spooled to an appended file bucket.
APREQ2_TempDir directory NULL Sets the location of the temporary directory apreq will use to spool overflow brigade data (based on the APREQ2_BrigadeLimit setting). If left unset, libapreq2 will select a platform-specific location via apr_temp_dir_get().

Implementation Details

   XXX apreq as a normal input filter
   XXX apreq as a "virtual" content handler.
   XXX apreq as a transparent "tee".
   XXX apreq parser registration in post_config
 

Function Documentation

apreq_handle_t* apreq_handle_apache2 request_rec *  r  ) 
 

Create an apreq handle which communicates with an Apache 2.X request_rec.

rapache-1.2.8/libapreq2/docs/html/index.html0000644000175100017510000001150212706745114020233 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: Main Page

libapreq2 Documentation

2.05-dev

Project Website: http://httpd.apache.org/apreq/

                    Apache HTTP Server Request Library

  What is it?
  -----------
  httpd-apreq is subproject of the Apache HTTP Server Project 
  whose committers develop and maintain the libapreq C library
  and its language bindings for Perl (contributions for additional 
  language bindings are most welcome).

  libapreq is a safe, standards-compliant, high-performance library 
  used for parsing HTTP cookies, query-strings and POST data.  The 
  original version (libapreq-1.X) was designed by Lincoln Stein and Doug 
  MacEachern.  The perl APIs Apache::Request and Apache::Cookie are the
  lightweight mod_perl analogs of the CGI and CGI::Cookie perl modules.

  Version 2 of libapreq is an improved codebase designed around APR
  and Apache-2's input filter API.  The C codebase is separated into
  two independent components:

      1) libapreq2, a shared library which is based on 
         libapr and libaprutil.

      2) A collection of modules:

          - mod_apreq2, a filter module for the Apache 2.X webserver,
          - a CGI module included in libapreq2 itself,
          - a custom module for general applications.

  Version 2 also includes the perl APIs for libapreq2- Apache2::Request,
  Apache2::Upload and Apache2::Cookie.  The corresponding XS modules 
  are generated by ExtUtils::XSBuilder, which is based on the new build
  system created specifically for mod_perl2.


  The Latest Version
  ------------------

  Details of the latest version can be found on the libapreq
  project page at 

                http://httpd.apache.org/apreq


  Documentation
  -------------

  The documentation is in the docs/ directory.  It is
  based on Doxygen, and can be regenerated by typing

        % make docs

  in the main directory.


  Installation
  ------------

  For full details please consult the INSTALL file.  Briefly,
  to install just the C API (libapreq2 + environment modules)
  on a Unix-like system:

            % ./configure --with-apache2-apxs=/path/to/apache2/bin/apxs
            % make
            % make test
            % make install

   To build and install the perl API as well, either add
   the "--enable-perl-glue" configure option, or let Makefile.PL
   enable it for you:

            % perl Makefile.PL --with-apache2-apxs=/path/to/apache2/bin/apxs
            % make
            % make test 
            % make install

  Licensing
  ---------

  Please see the file called LICENSE.


  Contacts
  --------

     o Project homepage:

        http://httpd.apache.org/apreq/

     o Mailing Lists:

        user lists:
               C/C++ API - modules@apache.org
                Perl API - modperl@perl.apache.org
                 Tcl API - XXX
                Java API - XXX
              Python API - XXX

        developer list (bugs, patches, code contributions, etc.):
                apreq-dev@httpd.apache.org


  Acknowledgments
  ----------------

  We wish to acknowledge the following copyrighted works that
  make up portions of the Apache software:

  libapreq2 relies heavily on the use of the GNU auto-tools 
  to provide a build environment.  The tests are based on 
  the Apache::Test, Test::Harness and Test::Inline.

  Doxygen generates the documentation for libapreq2. The perl glue
  and pods are generated by ExtUtils::XSBuilder.
rapache-1.2.8/libapreq2/docs/html/installdox0000755000175100017510000000510112706745114020343 0ustar ondrejondrej#!/home/joe/perl/5.8.x/bin/perl %subst = ( "apr.tag", "", "apu.tag", ""); $quiet = 0; if (open(F,"search.cfg")) { $_= ; s/[ \t\n]*$//g ; $subst{"_doc"} = $_; $_= ; s/[ \t\n]*$//g ; $subst{"_cgi"} = $_; } while ( @ARGV ) { $_ = shift @ARGV; if ( s/^-// ) { if ( /^l(.*)/ ) { $v = ($1 eq "") ? shift @ARGV : $1; ($v =~ /\/$/) || ($v .= "/"); $_ = $v; if ( /(.+)\@(.+)/ ) { if ( exists $subst{$1} ) { $subst{$1} = $2; } else { print STDERR "Unknown tag file $1 given with option -l\n"; &usage(); } } else { print STDERR "Argument $_ is invalid for option -l\n"; &usage(); } } elsif ( /^q/ ) { $quiet = 1; } elsif ( /^\?|^h/ ) { &usage(); } else { print STDERR "Illegal option -$_\n"; &usage(); } } else { push (@files, $_ ); } } foreach $sub (keys %subst) { if ( $subst{$sub} eq "" ) { print STDERR "No substitute given for tag file `$sub'\n"; &usage(); } elsif ( ! $quiet && $sub ne "_doc" && $sub ne "_cgi" ) { print "Substituting $subst{$sub} for each occurence of tag file $sub\n"; } } if ( ! @files ) { if (opendir(D,".")) { foreach $file ( readdir(D) ) { $match = ".html"; next if ( $file =~ /^\.\.?$/ ); ($file =~ /$match/) && (push @files, $file); ($file =~ "tree.js") && (push @files, $file); } closedir(D); } } if ( ! @files ) { print STDERR "Warning: No input files given and none found!\n"; } foreach $f (@files) { if ( ! $quiet ) { print "Editing: $f...\n"; } $oldf = $f; $f .= ".bak"; unless (rename $oldf,$f) { print STDERR "Error: cannot rename file $oldf\n"; exit 1; } if (open(F,"<$f")) { unless (open(G,">$oldf")) { print STDERR "Error: opening file $oldf for writing\n"; exit 1; } if ($oldf ne "tree.js") { while () { s/doxygen\=\"([^ \"\:\t\>\<]*)\:([^ \"\t\>\<]*)\" (href|src)=\"\2/doxygen\=\"$1:$subst{$1}\" \3=\"$subst{$1}/g; print G "$_"; } } else { while () { s/\"([^ \"\:\t\>\<]*)\:([^ \"\t\>\<]*)\", \"\2/\"$1:$subst{$1}\" ,\"$subst{$1}/g; print G "$_"; } } } else { print STDERR "Warning file $f does not exist\n"; } unlink $f; } sub usage { print STDERR "Usage: installdox [options] [html-file [html-file ...]]\n"; print STDERR "Options:\n"; print STDERR " -l tagfile\@linkName tag file + URL or directory \n"; print STDERR " -q Quiet mode\n\n"; exit 1; } rapache-1.2.8/libapreq2/docs/html/modules.html0000644000175100017510000000401312706745114020573 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: Module Index

libapreq2 Modules

Here is a list of all modules: rapache-1.2.8/libapreq2/docs/html/pages.html0000644000175100017510000000350512706745114020227 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: Page Index

libapreq2 Related Pages

Here is a list of all related documentation pages: rapache-1.2.8/libapreq2/docs/html/structapreq__cookie__t.html0000644000175100017510000002107512706745114023661 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: apreq_cookie_t Struct Reference

apreq_cookie_t Struct Reference

Cookie type, supporting both Netscape and RFC cookie specifications. More...

#include <apreq_cookie.h>


Data Fields

char * path
char * domain
char * port
char * comment
char * commentURL
apr_time_t max_age
unsigned flags
const apreq_value_t v


Detailed Description

Cookie type, supporting both Netscape and RFC cookie specifications.


Field Documentation

char* apreq_cookie_t::comment
 

RFC cookies may send a comment

char* apreq_cookie_t::commentURL
 

RFC cookies may place an URL here

char* apreq_cookie_t::domain
 

Restricts server domain

unsigned apreq_cookie_t::flags
 

charsets, taint marks, app-specific bits

apr_time_t apreq_cookie_t::max_age
 

total duration of cookie: -1 == session

char* apreq_cookie_t::path
 

Restricts url path

char* apreq_cookie_t::port
 

Restricts server port

const apreq_value_t apreq_cookie_t::v
 

"raw" cookie value


The documentation for this struct was generated from the following file: rapache-1.2.8/libapreq2/docs/html/structapreq__handle__t.html0000644000175100017510000001231112706745114023634 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: apreq_handle_t Struct Reference

apreq_handle_t Struct Reference

#include <apreq_module.h>


Data Fields

const struct apreq_module_tmodule
apr_pool_tpool
apr_bucket_alloc_tbucket_alloc


Detailed Description

An apreq handle associated with a module. The structure may have variable size, because the module may append its own data structures after it.


Field Documentation

apr_bucket_alloc_t* apreq_handle_t::bucket_alloc
 

the allocator, which persists at least as long as the pool

const struct apreq_module_t* apreq_handle_t::module
 

the apreq module which implements this handle

apr_pool_t* apreq_handle_t::pool
 

the pool which defines the lifetime of the parsed data


The documentation for this struct was generated from the following file: rapache-1.2.8/libapreq2/docs/html/structapreq__hook__t.html0000644000175100017510000001324212706745114023345 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: apreq_hook_t Struct Reference

apreq_hook_t Struct Reference

#include <apreq_parser.h>


Data Fields

apreq_hook_function_t hook
apreq_hook_tnext
apr_pool_tpool
void * ctx


Detailed Description

A hook is called by the parser whenever data arrives in a file upload parameter of the request body. You may associate any number of hooks with a parser instance with apreq_parser_add_hook().


Field Documentation

void* apreq_hook_t::ctx
 

a user defined pointer passed to the hook function

apreq_hook_function_t apreq_hook_t::hook
 

the hook function

apreq_hook_t* apreq_hook_t::next
 

next item in the linked list

apr_pool_t* apreq_hook_t::pool
 

pool which allocated this hook


The documentation for this struct was generated from the following file: rapache-1.2.8/libapreq2/docs/html/structapreq__module__t.html0000644000175100017510000006055412706745114023702 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: apreq_module_t Struct Reference

apreq_module_t Struct Reference

Vtable describing the necessary environment functions. More...

#include <apreq_module.h>


Data Fields

const char * name
apr_uint32_t magic_number
apr_status_t(* jar )(apreq_handle_t *, const apr_table_t **)
apr_status_t(* args )(apreq_handle_t *, const apr_table_t **)
apr_status_t(* body )(apreq_handle_t *, const apr_table_t **)
apreq_cookie_t *(* jar_get )(apreq_handle_t *, const char *)
apreq_param_t *(* args_get )(apreq_handle_t *, const char *)
apreq_param_t *(* body_get )(apreq_handle_t *, const char *)
apr_status_t(* parser_get )(apreq_handle_t *, const apreq_parser_t **)
apr_status_t(* parser_set )(apreq_handle_t *, apreq_parser_t *)
apr_status_t(* hook_add )(apreq_handle_t *, apreq_hook_t *)
apr_status_t(* brigade_limit_get )(apreq_handle_t *, apr_size_t *)
apr_status_t(* brigade_limit_set )(apreq_handle_t *, apr_size_t)
apr_status_t(* read_limit_get )(apreq_handle_t *, apr_uint64_t *)
apr_status_t(* read_limit_set )(apreq_handle_t *, apr_uint64_t)
apr_status_t(* temp_dir_get )(apreq_handle_t *, const char **)
apr_status_t(* temp_dir_set )(apreq_handle_t *, const char *)


Detailed Description

Vtable describing the necessary environment functions.


Field Documentation

apr_status_t(* apreq_module_t::args)(apreq_handle_t *, const apr_table_t **)
 

get a table with all query string parameters

apreq_param_t*(* apreq_module_t::args_get)(apreq_handle_t *, const char *)
 

get a query string parameter by its name

apr_status_t(* apreq_module_t::body)(apreq_handle_t *, const apr_table_t **)
 

get a table with all body parameters

apreq_param_t*(* apreq_module_t::body_get)(apreq_handle_t *, const char *)
 

get a body parameter by its name

apr_status_t(* apreq_module_t::brigade_limit_get)(apreq_handle_t *, apr_size_t *)
 

determine the maximum in-memory bytes a brigade may use

apr_status_t(* apreq_module_t::brigade_limit_set)(apreq_handle_t *, apr_size_t)
 

set the maximum in-memory bytes a brigade may use

apr_status_t(* apreq_module_t::hook_add)(apreq_handle_t *, apreq_hook_t *)
 

add a hook function

apr_status_t(* apreq_module_t::jar)(apreq_handle_t *, const apr_table_t **)
 

get a table with all cookies

apreq_cookie_t*(* apreq_module_t::jar_get)(apreq_handle_t *, const char *)
 

get a cookie by its name

apr_uint32_t apreq_module_t::magic_number
 

magic number identifying the module and version

const char* apreq_module_t::name
 

name of this apreq module

apr_status_t(* apreq_module_t::parser_get)(apreq_handle_t *, const apreq_parser_t **)
 

gets the parser associated with the request body

apr_status_t(* apreq_module_t::parser_set)(apreq_handle_t *, apreq_parser_t *)
 

manually set a parser for the request body

apr_status_t(* apreq_module_t::read_limit_get)(apreq_handle_t *, apr_uint64_t *)
 

determine the maximum amount of data that will be fed into a parser

apr_status_t(* apreq_module_t::read_limit_set)(apreq_handle_t *, apr_uint64_t)
 

set the maximum amount of data that will be fed into a parser

apr_status_t(* apreq_module_t::temp_dir_get)(apreq_handle_t *, const char **)
 

determine the directory used by the parser for temporary files

apr_status_t(* apreq_module_t::temp_dir_set)(apreq_handle_t *, const char *)
 

set the directory used by the parser for temporary files


The documentation for this struct was generated from the following file: rapache-1.2.8/libapreq2/docs/html/structapreq__param__t.html0000644000175100017510000001333412706745114023507 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: apreq_param_t Struct Reference

apreq_param_t Struct Reference

#include <apreq_param.h>


Data Fields

apr_table_tinfo
apr_bucket_brigadeupload
unsigned flags
const apreq_value_t v


Detailed Description

Common data structure for params and file uploads


Field Documentation

unsigned apreq_param_t::flags
 

charsets, taint marks, app-specific bits

apr_table_t* apreq_param_t::info
 

header table associated with the param

apr_bucket_brigade* apreq_param_t::upload
 

brigade used to spool upload files

const apreq_value_t apreq_param_t::v
 

underlying name/value info


The documentation for this struct was generated from the following file: rapache-1.2.8/libapreq2/docs/html/structapreq__parser__t.html0000644000175100017510000002254512706745114023707 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: apreq_parser_t Struct Reference

apreq_parser_t Struct Reference

#include <apreq_parser.h>


Data Fields

apreq_parser_function_t parser
const char * content_type
apr_pool_tpool
apr_bucket_alloc_tbucket_alloc
apr_size_t brigade_limit
const char * temp_dir
apreq_hook_thook
void * ctx


Detailed Description

A request body parser instance.


Field Documentation

apr_size_t apreq_parser_t::brigade_limit
 

the maximum in-memory bytes a brigade may use

apr_bucket_alloc_t* apreq_parser_t::bucket_alloc
 

bucket allocator used to create bucket brigades

const char* apreq_parser_t::content_type
 

the Content-Type request header

void* apreq_parser_t::ctx
 

internal context pointer used by the parser function

apreq_hook_t* apreq_parser_t::hook
 

linked list of hooks

apreq_parser_function_t apreq_parser_t::parser
 

the function which parses chunks of body data

apr_pool_t* apreq_parser_t::pool
 

a pool used by the parser

const char* apreq_parser_t::temp_dir
 

the directory used by the parser for temporary files


The documentation for this struct was generated from the following file: rapache-1.2.8/libapreq2/docs/html/structapreq__value__t.html0000644000175100017510000001277212706745114023530 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: apreq_value_t Struct Reference

apreq_value_t Struct Reference

libapreq's pre-extensible string type More...

#include <apreq.h>


Data Fields

char * name
apr_size_t nlen
apr_size_t dlen
char data [1]


Detailed Description

libapreq's pre-extensible string type


Field Documentation

char apreq_value_t::data[1]
 

value data

apr_size_t apreq_value_t::dlen
 

length of data

char* apreq_value_t::name
 

value name

apr_size_t apreq_value_t::nlen
 

length of name


The documentation for this struct was generated from the following file: rapache-1.2.8/libapreq2/docs/html/todo.html0000644000175100017510000000540012706745114020071 0ustar ondrejondrej libapreq2-2.05-dev: libapreq2: Todo List

Todo List

Global APREQ_COOKIE_MAX_LENGTH
convert this macro to an apreq_module_t method.

Global apreq_atoi64f (const char *s)
What happens when s is malformed? Should this return an unsigned value instead?

Global apreq_atoi64t (const char *s)
What happens when s is malformed? Should this return an unsigned value instead?

Global apreq_brigade_concat (apr_pool_t *pool, const char *temp_dir, apr_size_t brigade_limit, apr_bucket_brigade *out, apr_bucket_brigade *in)
Flesh out these error codes, making them as explicit as possible.
rapache-1.2.8/libapreq2/docs/man/0000755000175100017510000000000012706745114016046 5ustar ondrejondrejrapache-1.2.8/libapreq2/docs/man/man3/0000755000175100017510000000000012706745114016704 5ustar ondrejondrejrapache-1.2.8/libapreq2/docs/man/man3/_home_joe_src_apache_httpd_apreq_trunk_include_.30000644000175100017510000000161512706745114030547 0ustar ondrejondrej.TH "include/ Directory Reference" 3 "4 May 2005" "Version 2.05-dev" "libapreq2" \" -*- nroff -*- .ad l .nh .SH NAME include/ Directory Reference \- .SS "Files" .in +1c .ti -1c .RI "file \fBapreq.h\fP" .br .RI "\fIMain header file... \fP" .PP .in +1c .ti -1c .RI "file \fBapreq_cookie.h\fP" .br .RI "\fICookies and Jars. \fP" .PP .in +1c .ti -1c .RI "file \fBapreq_error.h\fP" .br .RI "\fIError status codes. \fP" .PP .in +1c .ti -1c .RI "file \fBapreq_module.h\fP" .br .RI "\fIModule API. \fP" .PP .in +1c .ti -1c .RI "file \fBapreq_param.h\fP" .br .RI "\fIRequest parsing and parameter API. \fP" .PP .in +1c .ti -1c .RI "file \fBapreq_parser.h\fP" .br .RI "\fIRequest body parser API. \fP" .PP .in +1c .ti -1c .RI "file \fBapreq_util.h\fP" .br .RI "\fIUtility functions for apreq. \fP" .PP .in +1c .ti -1c .RI "file \fBapreq_version.h\fP" .br .RI "\fIVersioning API for libapreq. \fP" .PP .in -1c rapache-1.2.8/libapreq2/docs/man/man3/_home_joe_src_apache_httpd_apreq_trunk_module_.30000644000175100017510000000041212706745114030403 0ustar ondrejondrej.TH "module/ Directory Reference" 3 "4 May 2005" "Version 2.05-dev" "libapreq2" \" -*- nroff -*- .ad l .nh .SH NAME module/ Directory Reference \- .SS "Directories" .in +1c .ti -1c .RI "directory \fBapache\fP" .br .ti -1c .RI "directory \fBapache2\fP" .br .in -1c rapache-1.2.8/libapreq2/docs/man/man3/_home_joe_src_apache_httpd_apreq_trunk_module_apache2_.30000644000175100017510000000036512706745114031775 0ustar ondrejondrej.TH "module/apache2/ Directory Reference" 3 "4 May 2005" "Version 2.05-dev" "libapreq2" \" -*- nroff -*- .ad l .nh .SH NAME module/apache2/ Directory Reference \- .SS "Files" .in +1c .ti -1c .RI "file \fBapreq_module_apache2.h\fP" .br .in -1c rapache-1.2.8/libapreq2/docs/man/man3/_home_joe_src_apache_httpd_apreq_trunk_module_apache_.30000644000175100017510000000036212706745114031710 0ustar ondrejondrej.TH "module/apache/ Directory Reference" 3 "4 May 2005" "Version 2.05-dev" "libapreq2" \" -*- nroff -*- .ad l .nh .SH NAME module/apache/ Directory Reference \- .SS "Files" .in +1c .ti -1c .RI "file \fBapreq_module_apache.h\fP" .br .in -1c rapache-1.2.8/libapreq2/docs/man/man3/apreq.h.30000644000175100017510000001333512706745114020333 0ustar ondrejondrej.TH "include/apreq.h" 3 "4 May 2005" "Version 2.05-dev" "libapreq2" \" -*- nroff -*- .ad l .nh .SH NAME include/apreq.h \- Main header file... .SH SYNOPSIS .br .PP \fC#include 'apr_tables.h'\fP .br \fC#include \fP .br .SS "Defines" .in +1c .ti -1c .RI "#define \fBAPREQ_DECLARE\fP(d) \fBAPR_DECLARE\fP(d)" .br .ti -1c .RI "#define \fBAPREQ_DECLARE_NONSTD\fP(d) \fBAPR_DECLARE_NONSTD\fP(d)" .br .ti -1c .RI "#define \fBAPREQ_DECLARE_DATA\fP" .br .ti -1c .RI "#define \fBAPREQ_DEFAULT_READ_BLOCK_SIZE\fP (64 * 1024)" .br .ti -1c .RI "#define \fBAPREQ_DEFAULT_READ_LIMIT\fP (64 * 1024 * 1024)" .br .ti -1c .RI "#define \fBAPREQ_DEFAULT_BRIGADE_LIMIT\fP (256 * 1024)" .br .ti -1c .RI "#define \fBAPREQ_DEFAULT_NELTS\fP 8" .br .ti -1c .RI "#define \fBAPREQ_FLAGS_OFF\fP(f, name) ((f) &= ~(name##_MASK << name##_BIT))" .br .ti -1c .RI "#define \fBAPREQ_FLAGS_ON\fP(f, name) ((f) |= (name##_MASK << name##_BIT))" .br .ti -1c .RI "#define \fBAPREQ_FLAGS_GET\fP(f, name) (((f) >> name##_BIT) & name##_MASK)" .br .ti -1c .RI "#define \fBAPREQ_FLAGS_SET\fP(f, name, value)" .br .ti -1c .RI "#define \fBAPREQ_CHARSET_BIT\fP 0" .br .ti -1c .RI "#define \fBAPREQ_CHARSET_MASK\fP 255" .br .ti -1c .RI "#define \fBAPREQ_TAINTED_BIT\fP 8" .br .ti -1c .RI "#define \fBAPREQ_TAINTED_MASK\fP 1" .br .ti -1c .RI "#define \fBAPREQ_COOKIE_VERSION_BIT\fP 11" .br .ti -1c .RI "#define \fBAPREQ_COOKIE_VERSION_MASK\fP 3" .br .ti -1c .RI "#define \fBAPREQ_COOKIE_SECURE_BIT\fP 13" .br .ti -1c .RI "#define \fBAPREQ_COOKIE_SECURE_MASK\fP 1" .br .ti -1c .RI "#define \fBapreq_attr_to_type\fP(T, A, P) ( (T*) ((char*)(P)-offsetof(T,A)) )" .br .in -1c .SS "Typedefs" .in +1c .ti -1c .RI "typedef \fBapreq_value_t\fP \fBapreq_value_t\fP" .br .RI "\fIlibapreq's pre-extensible string type \fP" .in -1c .SS "Enumerations" .in +1c .ti -1c .RI "enum \fBapreq_charset_t\fP { \fBAPREQ_CHARSET_ASCII\fP = 0, \fBAPREQ_CHARSET_LATIN1\fP = 1, \fBAPREQ_CHARSET_CP1252\fP = 2, \fBAPREQ_CHARSET_UTF8\fP = 8 }" .br .ti -1c .RI "enum \fBapreq_join_t\fP { \fBAPREQ_JOIN_AS_IS\fP, \fBAPREQ_JOIN_ENCODE\fP, \fBAPREQ_JOIN_DECODE\fP, \fBAPREQ_JOIN_QUOTE\fP }" .br .ti -1c .RI "enum \fBapreq_match_t\fP { \fBAPREQ_MATCH_FULL\fP, \fBAPREQ_MATCH_PARTIAL\fP }" .br .ti -1c .RI "enum \fBapreq_expires_t\fP { \fBAPREQ_EXPIRES_HTTP\fP, \fBAPREQ_EXPIRES_NSCOOKIE\fP }" .br .in -1c .SS "Functions" .in +1c .ti -1c .RI "static \fBAPR_INLINE\fP void \fBapreq_value_table_add\fP (const \fBapreq_value_t\fP *v, \fBapr_table_t\fP *t)" .br .ti -1c .RI "\fBapr_status_t\fP \fBapreq_initialize\fP (\fBapr_pool_t\fP *pool)" .br .ti -1c .RI "\fBapr_status_t\fP \fBapreq_pre_initialize\fP (\fBapr_pool_t\fP *pool)" .br .ti -1c .RI "\fBapr_status_t\fP \fBapreq_post_initialize\fP (\fBapr_pool_t\fP *pool)" .br .in -1c .SH "Detailed Description" .PP Main header file... Define the generic APREQ_ macros and common data structures. .SH "Define Documentation" .PP .SS "#define APREQ_FLAGS_SET(f, name, value)" .PP \fBValue:\fP .PP .nf ((f) = (((f) & ~(name##_MASK << name##_BIT)) \ | ((name##_MASK & (value)) << name##_BIT))) .fi .SH "Enumeration Type Documentation" .PP .SS "enum \fBapreq_charset_t\fP" .PP Character encodings. .SS "enum \fBapreq_expires_t\fP" .PP Expiration date format .PP \fBEnumeration values: \fP .in +1c .TP \fB\fIAPREQ_EXPIRES_HTTP \fP\fP Use date formatting consistent with RFC 2616 .TP \fB\fIAPREQ_EXPIRES_NSCOOKIE \fP\fP Use format consistent with Netscape's Cookie Spec .SS "enum \fBapreq_join_t\fP" .PP Join type .PP \fBEnumeration values: \fP .in +1c .TP \fB\fIAPREQ_JOIN_AS_IS \fP\fP Join the strings without modification .TP \fB\fIAPREQ_JOIN_ENCODE \fP\fP Url-encode the strings before joining them .TP \fB\fIAPREQ_JOIN_DECODE \fP\fP Url-decode the strings before joining them .TP \fB\fIAPREQ_JOIN_QUOTE \fP\fP Quote the strings, backslashing existing quote marks. .SS "enum \fBapreq_match_t\fP" .PP Match type .PP \fBEnumeration values: \fP .in +1c .TP \fB\fIAPREQ_MATCH_FULL \fP\fP Full match only. .TP \fB\fIAPREQ_MATCH_PARTIAL \fP\fP Partial matches are ok. .SH "Function Documentation" .PP .SS "\fBapr_status_t\fP apreq_initialize (\fBapr_pool_t\fP * pool)" .PP Initialize libapreq2. Applications (except apache modules using mod_apreq) should call this exactly once before they use any libapreq2 modules. If you want to modify the list of default parsers with \fBapreq_register_parser()\fP, please use \fBapreq_pre_initialize()\fP and \fBapreq_post_initialize()\fP instead. .PP \fBParameters:\fP .RS 4 \fIpool\fP a base pool persisting while libapreq2 is used .RE .PP \fBRemarks:\fP .RS 4 after you detroy the pool, you have to call this function again with a new pool if you still plan to use libapreq2 .RE .PP .SS "\fBapr_status_t\fP apreq_post_initialize (\fBapr_pool_t\fP * pool)" .PP Post-initialize libapreq2. Applications (except apache modules using mod_apreq2) should this exactly once before they use any libapreq2 modules for parsing. .PP \fBParameters:\fP .RS 4 \fIpool\fP the same pool that was used in \fBapreq_pre_initialize()\fP. .RE .PP .SS "\fBapr_status_t\fP apreq_pre_initialize (\fBapr_pool_t\fP * pool)" .PP Pre-initialize libapreq2. Applications (except apache modules using mod_apreq2) should call this exactly once before they register custom parsers with libapreq2. mod_apreq2 does this automatically during the post-config phase, so modules that need call apreq_register_parser should create a post-config hook using APR_HOOK_MIDDLE. .PP \fBParameters:\fP .RS 4 \fIpool\fP a base pool persisting while libapreq2 is used .RE .PP \fBRemarks:\fP .RS 4 after you detroyed the pool, you have to call this function again with a new pool if you still plan to use libapreq2 .RE .PP .SH "Author" .PP Generated automatically by Doxygen for libapreq2 from the source code. rapache-1.2.8/libapreq2/docs/man/man3/apreq_changes.30000644000175100017510000005641612706745114021604 0ustar ondrejondrej.TH "apreq_changes" 3 "4 May 2005" "Version 2.05-dev" "libapreq2" \" -*- nroff -*- .ad l .nh .SH NAME apreq_changes \- CHANGES .SH "Changes with libapreq2-2.05-dev (released May 5, 2005)" .PP .IP "\(bu" 2 Win32 build [Randy Kobes] Have top-level 'nmake', 'nmake test', and 'nmake install' targets, respectively, also include building, testing, and installing the corresponding perl glue targets. .PP .PP .IP "\(bu" 2 C API [geoff] Minimum httpd version is now 2.0.48, which includes the official apr 0.9.4 release. .PP .PP .IP "\(bu" 2 C API [Max Kellermann] Fix apreq_quote. .PP .PP .IP "\(bu" 2 Perl API [joes] Remove Apache2::Request::args. WARNING: through inheritance, args() now maps to Apache2::RequestRec::args. Folks that want the pre-2.05-dev behavior need to invoke APR::Request::args by name. .PP .PP .IP "\(bu" 2 C API [joes, Max Kellermann] Add apreq_initialize, apreq_pre_initialize and apreq_post_initialize. These are not thread-safe operations, so applications need to ensure they are invoked (in the correct sequence) prior to using any apreq2 modules. .PP .PP .IP "\(bu" 2 C, Perl API [joes] Add pool, bucket_alloc to \fBapreq_handle_t\fP. .PP .PP .IP "\(bu" 2 Perl API [joes] Drop $data argument from UPLOAD_HOOK, and also drop HOOK_DATA option. Perl folks should use a closure instead of passing in context data. .PP .PP .IP "\(bu" 2 Perl API [joes] Move bake, bake2 to Apache2::Cookie, now requiring an extra $r argument. Also ''-operator is mapped to as_string() for Apache2::Cookie; but APR::Request::Cookie maps it to value(). .PP .PP .IP "\(bu" 2 C API [joes] Remove header_in & header_out from \fBapreq_module_t\fP. Remove \fBapreq_ua_cookie_version()\fP and apreq_cookie_bake*(). Remove cookie2 argument to \fBapreq_handle_custom()\fP. .PP .PP .IP "\(bu" 2 C API [joes] s/APREQ/APREQ2/g in webserver configuration directives. .PP .PP .IP "\(bu" 2 C API [Igor Shevchenko, Philip Gollucci] Fix segfault in mfd parser caused by parts w/ empty param names. .PP .PP .IP "\(bu" 2 C API [joes] Add \fBapreq_cp1252_to_utf8()\fP. .PP .PP .IP "\(bu" 2 C, Perl API [joes] Add charset support for params and couple the SvUTF8 flag to the param's taint flag. .PP .PP .IP "\(bu" 2 C API [joes] Replace v->size with v->nlen + v->dlen. Added supporting apreq_value_table_add(). .PP .PP .IP "\(bu" 2 C API [joes] Remove apreq_cookie_attr(). .PP .PP .IP "\(bu" 2 C API [joes] .IP " \(bu" 4 Add \fBapreq_error.h\fP, \fBapreq_module.h\fP. .IP " \(bu" 4 Rename apreq_run* and apreq_make* funcs to conform with apreq_$obj_$meth scheme. .IP " \(bu" 4 Replace c->version & c->secure with flags. .IP " \(bu" 4 Parsers are assumed to be working with external data, so the cookies & params they produce are marked tainted. .PP .PP .PP .IP "\(bu" 2 C API [joes] \fBapreq_parse_cookie_header()\fP failed to parse RFC Cookie headers which contained no space chars after the '$Version=1' preamble. .PP .PP .IP "\(bu" 2 C API [joes] Reorganize around include/, library/, and module/ dirs. .PP .PP .IP "\(bu" 2 C Tests [joes] Replace CuTest-based tests with custom TAP-compliant framework. .PP .PP .IP "\(bu" 2 C API [Max Kellermann] Continue the API improvements: .PP .PP .IP "\(bu" 2 Convert APREQ_RUN_PARSER and APREQ_RUN_HOOK to inline, and downcase them. .IP "\(bu" 2 Remove apreq_memmem. .IP "\(bu" 2 Convert apreq_(un)escape to inline. .IP "\(bu" 2 apreq_escape does not create an apreq_value_t*. .IP "\(bu" 2 Initialize default_parsers explicitly to NULL. .IP "\(bu" 2 Convert APREQ_BRIGADE_COPY to inline, and downcase it. .IP "\(bu" 2 Lowercase APREQ_BRIGADE_SETASIDE, APREQ_BRIGADE_COPY. .IP "\(bu" 2 Convert apreq_cookie_name and apreq_cookie_value macros to inline. .IP "\(bu" 2 Convert apreq_param_name, apreq_param_value, apreq_param_info, and apreq_param_brigade to inline. .PP .PP .IP "\(bu" 2 C API [joes] Widespread API refactorization to remove apreq_jar_t and apreq_request_t: .PP .PP .IP "\(bu" 2 Header includes reorganized; apreq_parsers.h added (back again). .IP "\(bu" 2 Replaced apreq_jar_t and apreq_request_t with single apreq_env_handle_t. .IP "\(bu" 2 Added const qualifier to 'v' attribute of \fBapreq_cookie_t\fP and \fBapreq_param_t\fP. .IP "\(bu" 2 Use union type-puns to drop const qualifiers inside the new apreq_value_to_cookie and apreq_value_to_param implementations (gcc generates same object code as the macro versions did). .IP "\(bu" 2 Moved 'flags' attribute from \fBapreq_value_t\fP to \fBapreq_cookie_t\fP and \fBapreq_param_t\fP. .IP "\(bu" 2 Remove env argument from hooks and parsers. .IP "\(bu" 2 Reduce apreq_env_module to minimal set of operations. .IP "\(bu" 2 Replace apreq_log calls with apreq-specific error codes. .IP "\(bu" 2 Hooks are called on each body param now, not just during file uploads. .IP "\(bu" 2 Tie the cgi handle to its creator pool. .PP .PP Detailed changes by header file: .PP [\fBapreq.h\fP] .IP "\(bu" 2 Remove flags from \fBapreq_value_t\fP. .IP "\(bu" 2 Remove const qualifier from apreq_value_t's 'name' attribute. .IP "\(bu" 2 Remove apreq_value_merge* and apreq_value_copy*. .IP "\(bu" 2 Remove apreq_char_to_value, apreq_strtoval, and apreq_strlen. .IP "\(bu" 2 Move apreq_enctype to apreq_env.h. .IP "\(bu" 2 Move apreq_env_handle_t struct definition to apreq_env.h .IP "\(bu" 2 Change signature of apreq_decode. .IP "\(bu" 2 Move apreq_brigade_concat here, changed its signature and improved it alot. .IP "\(bu" 2 Remove apreq_brigade_spoolfile. .IP "\(bu" 2 Dropped APREQ_*_ENCTYPE, renamed some APREQ_$foo defaults APREQ_DEFAULT_$foo. .IP "\(bu" 2 Added APREQ_ERROR_*. .PP .PP [\fBapreq_cookie.h\fP] .IP "\(bu" 2 Remove apreq_env.h include. .IP "\(bu" 2 Remove apreq_jar_t. .IP "\(bu" 2 Add 'flags' to \fBapreq_cookie_t\fP, add const qualifier to its 'v' attr. .IP "\(bu" 2 Remove apreq_jar* functions. .IP "\(bu" 2 Add apreq_parse_cookie_header. .IP "\(bu" 2 Move apreq_cookie, apreq_cookie_bake(2), and apreq_ua_cookie_version to apreq_env.h. .PP .PP [apreq_params.h] .IP "\(bu" 2 Remove apreq_env.h include. .IP "\(bu" 2 Remove apreq_request_t. .IP "\(bu" 2 Add 'flags' to \fBapreq_param_t\fP, and const qualifier to its 'v' attr. .IP "\(bu" 2 Rename 'bb' attribute 'upload' in \fBapreq_param_t\fP. .IP "\(bu" 2 Remove apreq_request* functions. .IP "\(bu" 2 Remove apreq_parse_request. .IP "\(bu" 2 Changed apreq_decode_param signature. .IP "\(bu" 2 Replace env argument with apr_table_t in apreq_params_as_array, apreq_params_as_string, .IP "\(bu" 2 Move remaining apreq_param* to apreq_env.h. .IP "\(bu" 2 Move parser and hook sections to apreq_parsers.h. .IP "\(bu" 2 Change apreq_upload(s) old apreq_request_t arg to apr_table_t. .PP .PP [apreq_parsers.h] .IP "\(bu" 2 Acquire the hook and parser sections of original apreq_params.h. .IP "\(bu" 2 Remove env argument from APREQ_PARSER_ARGS and APREQ_HOOK_ARGS .IP "\(bu" 2 Augment \fBapreq_hook_t\fP and \fBapreq_parser_t\fP to replace missing env features. .IP "\(bu" 2 Change apreq_make_parser and apreq_make_hook signatures. .IP "\(bu" 2 Rename apreq_add_hook to apreq_parser_add_hook, returning apr_status_t. .IP "\(bu" 2 Change apreq_parser signature. .PP .PP [apreq_env.h] .IP "\(bu" 2 Remove read, log, pool, bucket_alloc, request, jar, and query_string methods. .IP "\(bu" 2 Include apreq_parsers.h. .IP "\(bu" 2 Reorganize apreq_env_module_t to provide hook, parser, jar, args, & body table ops. .IP "\(bu" 2 Rename max_brigade to 'brigade_limit', max_body to 'read_limit'. .IP "\(bu" 2 Change related module sigs, including temp_dir, to get/set methods. .IP "\(bu" 2 Add parser and read_limit args to apreq_env_make_custom_handle. .IP "\(bu" 2 Drop 'name' arg and APREQ_ENV_MODULE =~ s/_ENV//. .IP "\(bu" 2 s/apreq_env_make/apreq_handle/ in the handle constructor names. .PP .PP [mod_apreq.c, apreq_env_apache2.h] .IP "\(bu" 2 Changed APREQ_Max* configs to APREQ_BrigadeLimit and APREQ_ReadLimit. .IP "\(bu" 2 Handle constructor renamed apreq_handle_apache2. .PP .PP .IP "\(bu" 2 C API [joes] Make our 'libtool current interface' number depend on apr's major number. This allows libapreq2 to be installed into a system-wide location while avoiding ABI conflicts arising from our apr-based interfaces. .PP .PP .IP "\(bu" 2 C API [Max Kellermann] Introduce apreq_env_handle_t to replace the void *env usage. Also added apreq_env_custom for making private handles, and new apreq_env_apache2.h to let mod_apreq export apreq_env_make_apache2. .PP .PP .IP "\(bu" 2 C API [Max Kellermann] Rename apreq_env_t to apreq_env_module_t, to prepare for a new thread-safe apreq_env API. .PP .PP .IP "\(bu" 2 C API [Max Kellermann] mod_apreq must check the return value of apreq_brigade_concat to avoid a RAM-consuming infinite loop. A bad APREQ_TempDir setting can cause this situation. .PP .PP .IP "\(bu" 2 C API [joes] Provide workaround for chunked trailers bug in ap_http_filter. .PP .PP .IP "\(bu" 2 C, Perl API [joes] Several upload-related bugfixes: 1) apreq_upload and apreq_uploads did not search the full body table, 2) $upload->slurp and $io->read did not autovivify the resultant string. .PP .PP .IP "\(bu" 2 C API [joes] Add 'flags' attribute to \fBapreq_value_t\fP, planning for charset support. This is an ABI change, starting with libapreq2.so.2.0.24. .PP .PP .IP "\(bu" 2 C API [joes] Add apreq_env_bucket_alloc() to get an allocator directly from the environment instead of creating them from a pool. This is an ABI change, starting with libapreq2.so.2.0.23. .PP .PP .IP "\(bu" 2 Build system [joes] Add --with-apache2-httpd option so users can override apxs's notion of where the httpd executable is. XSBuilder's header parser runs from buildconf now instead of configure, so we will include those tables in the release tarball. buildconf gets an additional --with-perl option for running the xsbuilder.pl parsing script. The XS generation code in xsbuilder.pl has moved to glue/perl/Makefile.PL. .PP .PP .IP "\(bu" 2 Perl API [joes] Allow ctors for Apache::Cookie, Apache::Cookie::Jar and \fBApache\fP:::Request to accept Apache::Request objects (instead of requiring an Apache::RequestRec object). This thread details the bug http://thread.gmane.org/gmane.comp.apache.mod-perl/15727 .PP .PP .IP "\(bu" 2 C API [Bojan Smojver] Bake cookies with err_headers_out so they are sent on non-2xx server responses (ie. a 304 redirect). Also ensure that headers are copied with apr_table_add instead of apr_table_addn. Since \fBapreq_cookie_bake()\fP allocates from the stack, the Set-Cookie headers would occasionally get mangled without this patch. .PP .PP .IP "\(bu" 2 C API [joes] Add \fBapreq_register_parser()\fP, which allows users to add their own parsers to \fBapreq_parser()\fP's recognized MIME types. .PP .PP .IP "\(bu" 2 C API [joes] Support 'multipart/mixed' file uploads. Support XForms' 'multipart/related' enctype. .PP .PP .IP "\(bu" 2 C API [joes] Add apreq_hook_apr_xml_parser(), which is a simple wrapper hook around APR's expat-based apr_xml_parser. Add a generic parser apreq_parse_generic() to parse arbitrary enctypes using the hook API. .PP .SH "Changes with libapreq2-2.04-dev (released August 30, 2004)" .PP .IP "\(bu" 2 Perl API [joes] Add TAINT checks, marking all parsed data as tainted. .PP .PP .IP "\(bu" 2 C API [joes] Add body_status attribute to apreq_request_t, to allow the both environment and the parser to report any errors encountered. .PP .PP .IP "\(bu" 2 C API [randyk, joes] Cookie parser was locking up on non-alphanumeric chars in cookie names. Also RFC Cookie attributes are always checked for quotes during bake(2), and the quotes are now stripped from incoming RFC cookies during parsing (but they are never stripped from the actual cookie value). .PP .PP .IP "\(bu" 2 Perl API [joes] Apache::Cookie::Jar->new accepts a VALUE_CLASS argument, which effectively blesses all the jar's cookies into that class, which simplifies subclassing Apache::Cookie. Accordingly Apache::Cookie->freeze($value) no longer accepts a freeze()-able object in $value. .PP .PP .IP "\(bu" 2 C API [Markus Wichitill, randyk, joes] Drop APR_DELONCLOSE from apreq_file_mktemp implementation and install apreq_file_cleanup. When passed to apr_file_open on Win32, APR_DELONCLOSE sets the FILE_SHARED_DELETE flag, which is, unfortunately, a property that is preserved across NTFS 'hard' links. This breaks apps that link() the temp file to a permanent location, and subsequently expect to open it without FILE_SHARED_DELETE before the original tempfile is closed+deleted. In fact, even Apache::Upload does this, so it is a common enough event that the apreq_file_cleanup workaround is necessary. .PP .PP .IP "\(bu" 2 C API [Ken Burcham, joes] Fix bug in url parser that occurs when a XX-encoded sequence is split across multiple buckets. Added apreq_decode_decodev to make this problem less inconvenient. .PP .PP .IP "\(bu" 2 Perl API [joes] Exception objects inherit from the object which raised it, which allows $@ to invoke its methods with impunity (exceptions are disabled for objects which derive from an exception class). .PP .PP .IP "\(bu" 2 Perl API [joes] Implement HOOK_DATA and UPLOAD_HOOK. .PP .PP .IP "\(bu" 2 Perl API [joes] Add safe XS wrappers for $table->add, $table->set, $table->STORE, and $table_class->new. .PP .PP .IP "\(bu" 2 Perl API [joes] Add exceptions to $upload->link, $upload->tempname, $upload->slurp, and $cookie->set_attr. Return value of $upload->slurp is now the upload length. Also document new $upload->io. .PP .PP .IP "\(bu" 2 C API [joes] Restrict all apr_status_t codes to APR_SUCCESS, APR_INCOMPLETE, APR_EGENERAL, APR_EINIT, APR_ENOTIMPL, since any others will generate confusing error messages from apr_strerror. .PP .PP .IP "\(bu" 2 Perl API [joes] Added $upload->io with a TIEHANDLE API layered over APR::Brigade. $upload->fh remains implemented as an APR::PerlIO object, which is seekable but less efficient and currently suffers some portability issues associated with largefile support in perl and apr. .PP .PP .IP "\(bu" 2 Perl API [joes] Added apreq_xs_croak for throwing APR::Error exceptions and included error-checking on $req->param, $req->args, $req->body, $req->upload, and $jar->get. .PP .PP .IP "\(bu" 2 Perl API [joes] Added $jar->status, $req->args_status and $req->body_status to report parsing errors. Also add $upload->tempname per user request. .PP .PP .IP "\(bu" 2 C API [joes] Dropped status attribute of \fBapreq_value_t\fP. Added status field to apreq_jar_t and added args_status field to apreq_request_t. Parsers also must return their public status code when a NULL brigade is passed. apreq_hook_disable_uploads() is also added. This is an ABI change affecting all versions of libapreq2 prior to 2.0.12. .PP .PP .IP "\(bu" 2 Perl API [joes] $upload->info returns a proper APR::Table object now. Also implemented $upload->size, $upload->fh, and $upload->type. .PP .PP .IP "\(bu" 2 C API [Jean-François Meesse] mfd parser fails to parse CRLF-terminated files when the terminating boundary string is at the start of a new bucket. This is reportedly a common event for PDF files uploaded with Netscape 7. .PP .PP .IP "\(bu" 2 Perl API [joes] Add back-compat support for Apache::Cookie->fetch() via Apache->request. .PP .PP .IP "\(bu" 2 C API [joes] Add MaxBody, MaxBrigade, and TempDir per-dir directives to mod_apreq filter. .PP .PP .IP "\(bu" 2 C API [joes] Replace free/tempnam dependency in \fBapreq_file_mktemp()\fP with \fBapr_temp_dir_get()\fP. Add additional gcc warning flags when --enable-maintainer-mode is set. .PP .PP .IP "\(bu" 2 C API [joes, Scott Hutton] Replace apreq_brigade_copy with more effective APREQ_BRIGADE_COPY macro. Also introduce APREQ_BRIGADE_SETASIDE to deal with buckets that need to be set aside for use in future function calls. mod_ssl generates transient buckets which tickled this bug. .PP .PP .IP "\(bu" 2 Perl API [joes] Separate Apache::Upload module from Apache::Request for better organization. .PP .SH "Changes with libapreq2-2.03-dev (released June 12, 2004)" .PP .IP "\(bu" 2 C API [joes] 'Objectify' cookie/jar API: s/apreq_(make|serialize)_cookie/apreq_cookie_$1/ and reordering args so the cookie/jar object is always the first argument. Macros added to provide source-compatibility with the old names. .PP .PP .IP "\(bu" 2 Perl API [joes] Added $upload->slurp($data), which reads the contents of the file upload '$upload' into the scalar '$data'. .PP .PP .IP "\(bu" 2 C API [joes, randyk] apreq_run_(hook|parser) are macros, so they are capitalized now. Fixed \fBapreq_params_as_string()\fP and added \fBapreq_params_as_array()\fP. Reworked definitions of APREQ_DECLARE_HOOK, APREQ_DECLARE_PARSER and apreq_(parser|hook)_t, hopefully to be more Win32 friendly. Also updated the documentation. .PP .PP .IP "\(bu" 2 C API [joes] Compensate for a missing CRLF in empty file upload block, which actually complies with RFC 2046 Section 5.1.1. Konqueror (version unknown) and Mozilla 0.9.7 are known to emit such blocks. .PP .PP .IP "\(bu" 2 Perl API [joes] $req->upload() in list context failed to filter out non-uploads. Also $req->upload('nonexistent-key-name') segfaults. .PP .PP .IP "\(bu" 2 Perl test suite t/TEST.PL must run parent class' pre_configure to get the configuration right .PP .PP .IP "\(bu" 2 C API [joes] \fBapreq_brigade_concat()\fP wasn't supplying the final EOS bucket to large brigades (>256K), which somtimes caused the prefetch loop in mod_apreq.c's apreq_filter() to hang. .PP .PP .IP "\(bu" 2 Documentation [joes] CHANGES file reformatted, removing dates & other clutter as Stas suggests. .PP .PP .IP "\(bu" 2 C API [joes] Rewrote cgi_read() in apreq_env.c and reworked mod_apreq.c to enforce apreq_env_max_body() settings. .PP .PP .IP "\(bu" 2 C API [joes] Fixed bug in url_parser code- missing context brigade was needed to track key-value pairs which span multiple buckets. .PP .PP .IP "\(bu" 2 C API [joes] API modifications: removed struct apreq_cfg_t, adding new apreq_env hooks max_body, max_brigade_len, and temp_dir. Folded apreq_parsers.h into apreq_params.h and modified the arguments to apreq_run_parser() and apreq_run_hook(). Renamed apreq_parser_t's content_type as enctype and apreq_copy_brigade() as \fBapreq_brigade_copy()\fP. These changes make libapreq2.so.2.0.5 incompatible with earlier versions. .PP .PP .IP "\(bu" 2 Perl API [stas] Include ppport.h from blead-perl to support older perls. Add a proper support for ithreads. .PP .PP .IP "\(bu" 2 C API [Swen Schillig, joes] Fixed bug in calculation of Netscape cookie expiration dates. apr_time_t is measured in microseconds, not seconds, which threw off the arithmetic; apr_time_from_sec was needed for the conversion. .PP .PP .IP "\(bu" 2 C API [Max Kellermann] Fix segfault caused by invalid -escape sequence in query string. .PP .SH "Changes with libapreq2-2.02-dev (released Nov 15, 2003)" .PP .IP "\(bu" 2 Perl API [joes] Fix bogus pool/cookie initializers in Apache::Cookie::set_attr(), which caused Apache::Cookie::new to segfault. Bug first reported to modperl list by Wolfgang Kubens. .PP .SH "Changes with libapreq2-2.01-dev (released Nov 10, 2003)" .PP .IP "\(bu" 2 build system [joes] Skip Apache::Test tests in env/ when Apache::Test is unavailable. This allows the C API to be build and installed without requiring Apache::Test (it is still a requirement for compiling the perl glue). .PP .PP .IP "\(bu" 2 C API mod_apreq.c [joes] Parser errors were creeping into the return value of apreq_filter, which breaks the 'transparent tee' paradigm. This caused bogus '400 Bad Request' responses (first reported by Vladimir Dudo) to occur when libapreq2 was used by an output filter during a GET request (handled by apache2's default handler). The test suite has been updated accordingly. .PP .PP .IP "\(bu" 2 C API [joes] Incorporate libapreq_cgi into libapreq2 as the default environment, and add apreq_env_t and initializer apreq_env_module() to manage the environment at runtime (determining the environment at load-time was problematic on non-ELF systems). .PP .SH "Changes with libapreq2-2.00-dev (Oct 25, 2003)" .PP .IP "\(bu" 2 C API: libapreq_cgi.c [randyk, joes] CGI environment defined by env/libapreq_cgi.c is functional (with tests added to env/t). This library may soon be incorporated directly into libapreq2 as a default enviroment. .PP .PP .IP "\(bu" 2 C API: mod_apreq.c [joes] Added ctx->saw_eos to ensure we don't read from upstream filters after receiving an eos bucket. Otherwise it was possible for two eos buckets to appear when a prefetch read is involved, which breaks other modules like mod_proxy. This bug was uncovered by Philippe Chiasson. mod_apreq's apreq_env_majic_number bumped to reflect the added fixes. .PP .PP .IP "\(bu" 2 configure: --enable-perl-glue [joes] The --enable-perl-glue option integrates the perl glue into the normal Unix build cycle. It is disabled by default, but is silently reenabled if the user configures the source tree via Makefile.PL. .PP .PP .IP "\(bu" 2 C API [joes] Added \fBapreq_header_attribute()\fP and fixed mfd parser to allow 'charset' attribute to appear in the Content-Type header. Sven Geisler points out that Opera 7.20 does generate such headers. .PP .PP .IP "\(bu" 2 C API [joes] Added versioning API following http://apr.apache.org/versioning.html apreq_env renamed apreq_env_name, and apreq_env_magic_number added to provide versioning for environments (modules). The header files are now installed to 'include/apreq2', and the library is renamed 'libapreq2'. Also added an apreq2-config script based on apu-config. .PP .PP .IP "\(bu" 2 configure: static mod_apreq.c [Bojan Smojver, joes] Add --with-apache2-src configure option, along with --with-apr-config and --with-apu-config, and provide support for compiling mod_apreq into httpd as a static apache module. .PP .PP .IP "\(bu" 2 C API: mod_apreq.c [joes] Support for internal redirects added to the mod_apreq filter. This ensures any POST data prefetched in the main request gets passed along to the subrequest handler(s). .PP .PP .IP "\(bu" 2 C bugfix: apreq_decode [Graham Clark] If the source and destination strings are represented by the same pointer - e.g. if called as apreq_unescape(s) - string s is modified incorrectly in general. Patch includes new unit test. .PP .PP .IP "\(bu" 2 Perl API [joes] Added $req->parse, $req->status, & 'preparse' logic to $req->param & $req->upload. .PP .PP .IP "\(bu" 2 C API [joes] Added 'preparse' logic to apreq_params & apreq_uploads to bring behavior in line with libapreq-1.x. .PP .PP .IP "\(bu" 2 C API [joes] Dropped param->charset. Make apreq_brigade_concat public, so mod_apreq can use it for its ctx->spool brigade. .PP .PP .IP "\(bu" 2 Documentation [joes] Updated Cookie_pod to reflect API changes over v1.X. .PP .PP .IP "\(bu" 2 Documentation [joes] Added doxygen links to Apache::Request and Apache::Cookie perl docs. .PP .PP .IP "\(bu" 2 C API [joes] Added apreq_copy_brigade(bb) to \fBapreq.h\fP. .PP .PP .IP "\(bu" 2 C API [joes] The new filter-based design required a complete departure from libapreq-1.X codebase. libapreq-2 is based solely on APR, and to be fully functional, requires a supporting environment similar to Apache-2. A person wishing to port libapreq-2 to a new environment needs to provide definitions for the declarations in apreq_env.h. .PP .PP .IP "\(bu" 2 Perl API [joes] Aggregates are always collected into an APR::Table-based package. New table packages: Apache::Cookie::Table, Apache::Request::Table, and Apache::Upload::Table. .PP .PP .IP "\(bu" 2 Perl API [joes] Apache::Cookie->fetch now requires an 'environment' argument ($r). Its return value is blessed into the Apache::Cookie::Jar class. .PP .PP .IP "\(bu" 2 Perl API [joes] Two new request lookup functions: .IP " 1." 6 $req->args - param lookup using only the query string .IP " 2." 6 $req->body - param lookup using only the POST data .PP .PP rapache-1.2.8/libapreq2/docs/man/man3/apreq_cookie.h.30000644000175100017510000001630012706745114021657 0ustar ondrejondrej.TH "include/apreq_cookie.h" 3 "4 May 2005" "Version 2.05-dev" "libapreq2" \" -*- nroff -*- .ad l .nh .SH NAME include/apreq_cookie.h \- Cookies and Jars. .SH SYNOPSIS .br .PP \fC#include 'apreq.h'\fP .br \fC#include 'apr_time.h'\fP .br .SS "Defines" .in +1c .ti -1c .RI "#define \fBAPREQ_COOKIE_MAX_LENGTH\fP 4096" .br .in -1c .SS "Typedefs" .in +1c .ti -1c .RI "typedef \fBapreq_cookie_t\fP \fBapreq_cookie_t\fP" .br .RI "\fICookie type, supporting both Netscape and RFC cookie specifications. \fP" .in -1c .SS "Functions" .in +1c .ti -1c .RI "static \fBAPR_INLINE\fP \fBapreq_cookie_t\fP * \fBapreq_value_to_cookie\fP (const char *val)" .br .ti -1c .RI "static \fBAPR_INLINE\fP unsigned \fBapreq_cookie_version\fP (const \fBapreq_cookie_t\fP *c)" .br .ti -1c .RI "static \fBAPR_INLINE\fP void \fBapreq_cookie_version_set\fP (\fBapreq_cookie_t\fP *c, unsigned v)" .br .ti -1c .RI "static \fBAPR_INLINE\fP unsigned \fBapreq_cookie_is_secure\fP (const \fBapreq_cookie_t\fP *c)" .br .ti -1c .RI "static \fBAPR_INLINE\fP void \fBapreq_cookie_secure_on\fP (\fBapreq_cookie_t\fP *c)" .br .ti -1c .RI "static \fBAPR_INLINE\fP void \fBapreq_cookie_secure_off\fP (\fBapreq_cookie_t\fP *c)" .br .ti -1c .RI "static \fBAPR_INLINE\fP unsigned \fBapreq_cookie_is_tainted\fP (const \fBapreq_cookie_t\fP *c)" .br .ti -1c .RI "static \fBAPR_INLINE\fP void \fBapreq_cookie_tainted_on\fP (\fBapreq_cookie_t\fP *c)" .br .ti -1c .RI "static \fBAPR_INLINE\fP void \fBapreq_cookie_tainted_off\fP (\fBapreq_cookie_t\fP *c)" .br .ti -1c .RI "\fBapr_status_t\fP \fBapreq_parse_cookie_header\fP (\fBapr_pool_t\fP *pool, \fBapr_table_t\fP *jar, const char *header)" .br .ti -1c .RI "\fBapreq_cookie_t\fP * \fBapreq_cookie_make\fP (\fBapr_pool_t\fP *pool, const char *name, const \fBapr_size_t\fP nlen, const char *value, const \fBapr_size_t\fP vlen)" .br .ti -1c .RI "char * \fBapreq_cookie_as_string\fP (const \fBapreq_cookie_t\fP *c, \fBapr_pool_t\fP *p)" .br .ti -1c .RI "int \fBapreq_cookie_serialize\fP (const \fBapreq_cookie_t\fP *c, char *buf, \fBapr_size_t\fP len)" .br .ti -1c .RI "void \fBapreq_cookie_expires\fP (\fBapreq_cookie_t\fP *c, const char *time_str)" .br .in -1c .SH "Detailed Description" .PP Cookies and Jars. \fBapreq_cookie.h\fP describes a common server-side API for request (incoming) and response (outgoing) cookies. It aims towards compliance with the standard cookie specifications listed below. .PP \fBSee also:\fP .RS 4 http://wp.netscape.com/newsref/std/cookie_spec.html .PP http://www.ietf.org/rfc/rfc2109.txt .PP http://www.ietf.org/rfc/rfc2964.txt .PP http://www.ietf.org/rfc/rfc2965.txt .RE .PP .SH "Define Documentation" .PP .SS "#define APREQ_COOKIE_MAX_LENGTH 4096" .PP \fBTodo\fP .RS 4 convert this macro to an \fBapreq_module_t\fP method. .RE .PP Maximum length of a single Set-Cookie(2) header. .SH "Function Documentation" .PP .SS "char* apreq_cookie_as_string (const \fBapreq_cookie_t\fP * c, \fBapr_pool_t\fP * p)" .PP Returns a string that represents the cookie as it would appear in a valid 'Set-Cookie*' header. .PP \fBParameters:\fP .RS 4 \fIc\fP cookie. .br \fIp\fP pool which allocates the returned string. .RE .PP \fBReturns:\fP .RS 4 header string. .RE .PP .SS "void apreq_cookie_expires (\fBapreq_cookie_t\fP * c, const char * time_str)" .PP Set the Cookie's expiration date. .PP \fBParameters:\fP .RS 4 \fIc\fP The cookie. .br \fItime_str\fP If NULL, the Cookie's expiration date is unset, making it a session cookie. This means no 'expires' or 'max-age' attribute will appear in the cookie's serialized form. If time_str is not NULL, the expiration date will be reset to the offset (from now) represented by time_str. The time_str should be in a format that \fBapreq_atoi64t()\fP can understand, namely /[+-]?\\d+\\s*[YMDhms]/. .RE .PP \fBRemarks:\fP .RS 4 Now time_str may also be a fixed date; see \fBapr_date_parse_rfc()\fP for admissible formats. .RE .PP .SS "static \fBAPR_INLINE\fP unsigned apreq_cookie_is_secure (const \fBapreq_cookie_t\fP * c)\fC [static]\fP" .PP \fBReturns:\fP .RS 4 1 if the secure flag is set, 0 otherwise. .RE .PP .SS "static \fBAPR_INLINE\fP unsigned apreq_cookie_is_tainted (const \fBapreq_cookie_t\fP * c)\fC [static]\fP" .PP \fBReturns:\fP .RS 4 1 if the taint flag is set, 0 otherwise. .RE .PP .SS "\fBapreq_cookie_t\fP* apreq_cookie_make (\fBapr_pool_t\fP * pool, const char * name, const \fBapr_size_t\fP nlen, const char * value, const \fBapr_size_t\fP vlen)" .PP Returns a new cookie, made from the argument list. .PP \fBParameters:\fP .RS 4 \fIpool\fP Pool which allocates the cookie. .br \fIname\fP The cookie's name. .br \fInlen\fP Length of name. .br \fIvalue\fP The cookie's value. .br \fIvlen\fP Length of value. .RE .PP \fBReturns:\fP .RS 4 the new cookie .RE .PP .SS "static \fBAPR_INLINE\fP void apreq_cookie_secure_off (\fBapreq_cookie_t\fP * c)\fC [static]\fP" .PP Turns off the cookie's secure flag. .SS "static \fBAPR_INLINE\fP void apreq_cookie_secure_on (\fBapreq_cookie_t\fP * c)\fC [static]\fP" .PP Sets the cookie's secure flag, meaning it only comes back over an SSL-encrypted connction. .SS "int apreq_cookie_serialize (const \fBapreq_cookie_t\fP * c, char * buf, \fBapr_size_t\fP len)" .PP Same functionality as apreq_cookie_as_string. Stores the string representation in buf, using up to len bytes in buf as storage. The return value has the same semantics as that of apr_snprintf, including the special behavior for a 'len = 0' argument. .PP \fBParameters:\fP .RS 4 \fIc\fP cookie. .br \fIbuf\fP storage location for the result. .br \fIlen\fP size of buf's storage area. .RE .PP \fBReturns:\fP .RS 4 size of resulting header string. .RE .PP .SS "static \fBAPR_INLINE\fP void apreq_cookie_tainted_off (\fBapreq_cookie_t\fP * c)\fC [static]\fP" .PP Turns off the cookie's tainted flag. .SS "static \fBAPR_INLINE\fP void apreq_cookie_tainted_on (\fBapreq_cookie_t\fP * c)\fC [static]\fP" .PP Sets the cookie's tainted flag. .SS "static \fBAPR_INLINE\fP unsigned apreq_cookie_version (const \fBapreq_cookie_t\fP * c)\fC [static]\fP" .PP \fBReturns:\fP .RS 4 1 if this is an RFC cookie, 0 if its a Netscape cookie. .RE .PP .SS "static \fBAPR_INLINE\fP void apreq_cookie_version_set (\fBapreq_cookie_t\fP * c, unsigned v)\fC [static]\fP" .PP Sets the cookie's protocol version. .SS "\fBapr_status_t\fP apreq_parse_cookie_header (\fBapr_pool_t\fP * pool, \fBapr_table_t\fP * jar, const char * header)" .PP Parse a cookie header and store the cookies in an apr_table_t. .PP \fBParameters:\fP .RS 4 \fIpool\fP pool which allocates the cookies .br \fIjar\fP table where parsed cookies are stored .br \fIheader\fP the header value .RE .PP \fBReturns:\fP .RS 4 APR_SUCCESS. .PP \fBAPREQ_ERROR_BADSEQ\fP if an unparseable character sequence appears. .PP \fBAPREQ_ERROR_MISMATCH\fP if an rfc-cookie attribute appears in a netscape cookie header. .PP \fBAPR_ENOTIMPL\fP if an unrecognized rfc-cookie attribute appears. .PP \fBAPREQ_ERROR_NOTOKEN\fP if a required token was not present. .PP \fBAPREQ_ERROR_BADCHAR\fP if an unexpected token was present. .RE .PP .SS "static \fBAPR_INLINE\fP \fBapreq_cookie_t\fP* apreq_value_to_cookie (const char * val)\fC [static]\fP" .PP Upgrades a jar's table values to \fBapreq_cookie_t\fP structs. .SH "Author" .PP Generated automatically by Doxygen for libapreq2 from the source code. rapache-1.2.8/libapreq2/docs/man/man3/apreq_cookie_t.30000644000175100017510000000270312706745114021756 0ustar ondrejondrej.TH "apreq_cookie_t" 3 "4 May 2005" "Version 2.05-dev" "libapreq2" \" -*- nroff -*- .ad l .nh .SH NAME apreq_cookie_t \- Cookie type, supporting both Netscape and RFC cookie specifications. .PP .SH SYNOPSIS .br .PP \fC#include \fP .PP .SS "Data Fields" .in +1c .ti -1c .RI "char * \fBpath\fP" .br .ti -1c .RI "char * \fBdomain\fP" .br .ti -1c .RI "char * \fBport\fP" .br .ti -1c .RI "char * \fBcomment\fP" .br .ti -1c .RI "char * \fBcommentURL\fP" .br .ti -1c .RI "\fBapr_time_t\fP \fBmax_age\fP" .br .ti -1c .RI "unsigned \fBflags\fP" .br .ti -1c .RI "const \fBapreq_value_t\fP \fBv\fP" .br .in -1c .SH "Detailed Description" .PP Cookie type, supporting both Netscape and RFC cookie specifications. .PP .SH "Field Documentation" .PP .SS "char* \fBapreq_cookie_t::comment\fP" .PP RFC cookies may send a comment .SS "char* \fBapreq_cookie_t::commentURL\fP" .PP RFC cookies may place an URL here .SS "char* \fBapreq_cookie_t::domain\fP" .PP Restricts server domain .SS "unsigned \fBapreq_cookie_t::flags\fP" .PP charsets, taint marks, app-specific bits .SS "\fBapr_time_t\fP \fBapreq_cookie_t::max_age\fP" .PP total duration of cookie: -1 == session .SS "char* \fBapreq_cookie_t::path\fP" .PP Restricts url path .SS "char* \fBapreq_cookie_t::port\fP" .PP Restricts server port .SS "const \fBapreq_value_t\fP \fBapreq_cookie_t::v\fP" .PP 'raw' cookie value .SH "Author" .PP Generated automatically by Doxygen for libapreq2 from the source code. rapache-1.2.8/libapreq2/docs/man/man3/apreq_error.h.30000644000175100017510000000772212706745114021547 0ustar ondrejondrej.TH "include/apreq_error.h" 3 "4 May 2005" "Version 2.05-dev" "libapreq2" \" -*- nroff -*- .ad l .nh .SH NAME include/apreq_error.h \- Error status codes. .SH SYNOPSIS .br .PP \fC#include 'apr_errno.h'\fP .br \fC#include 'apreq.h'\fP .br .SS "Defines" .in +1c .ti -1c .RI "#define \fBAPR_EBADARG\fP \fBAPR_BADARG\fP" .br .ti -1c .RI "#define \fBAPREQ_ERROR_GENERAL\fP \fBAPR_OS_START_USERERR\fP" .br .ti -1c .RI "#define \fBAPREQ_ERROR_TAINTED\fP (APREQ_ERROR_GENERAL + 1)" .br .ti -1c .RI "#define \fBAPREQ_ERROR_INTERRUPT\fP (APREQ_ERROR_GENERAL + 2)" .br .ti -1c .RI "#define \fBAPREQ_ERROR_BADDATA\fP (APREQ_ERROR_GENERAL + 10)" .br .ti -1c .RI "#define \fBAPREQ_ERROR_BADCHAR\fP (APREQ_ERROR_BADDATA + 1)" .br .ti -1c .RI "#define \fBAPREQ_ERROR_BADSEQ\fP (APREQ_ERROR_BADDATA + 2)" .br .ti -1c .RI "#define \fBAPREQ_ERROR_BADATTR\fP (APREQ_ERROR_BADDATA + 3)" .br .ti -1c .RI "#define \fBAPREQ_ERROR_BADHEADER\fP (APREQ_ERROR_BADDATA + 4)" .br .ti -1c .RI "#define \fBAPREQ_ERROR_BADUTF8\fP (APREQ_ERROR_BADDATA + 5)" .br .ti -1c .RI "#define \fBAPREQ_ERROR_NODATA\fP (APREQ_ERROR_GENERAL + 20)" .br .ti -1c .RI "#define \fBAPREQ_ERROR_NOTOKEN\fP (APREQ_ERROR_NODATA + 1)" .br .ti -1c .RI "#define \fBAPREQ_ERROR_NOATTR\fP (APREQ_ERROR_NODATA + 2)" .br .ti -1c .RI "#define \fBAPREQ_ERROR_NOHEADER\fP (APREQ_ERROR_NODATA + 3)" .br .ti -1c .RI "#define \fBAPREQ_ERROR_NOPARSER\fP (APREQ_ERROR_NODATA + 4)" .br .ti -1c .RI "#define \fBAPREQ_ERROR_MISMATCH\fP (APREQ_ERROR_GENERAL + 30)" .br .ti -1c .RI "#define \fBAPREQ_ERROR_OVERLIMIT\fP (APREQ_ERROR_MISMATCH + 1)" .br .ti -1c .RI "#define \fBAPREQ_ERROR_UNDERLIMIT\fP (APREQ_ERROR_MISMATCH + 2)" .br .ti -1c .RI "#define \fBAPREQ_ERROR_NOTEMPTY\fP (APREQ_ERROR_MISMATCH + 3)" .br .in -1c .SS "Functions" .in +1c .ti -1c .RI "char * \fBapreq_strerror\fP (\fBapr_status_t\fP s, char *buf, \fBapr_size_t\fP bufsize)" .br .in -1c .SH "Detailed Description" .PP Error status codes. Define the APREQ_ error codes. .SH "Define Documentation" .PP .SS "#define APREQ_ERROR_BADATTR (APREQ_ERROR_BADDATA + 3)" .PP Invalid attribute. .SS "#define APREQ_ERROR_BADCHAR (APREQ_ERROR_BADDATA + 1)" .PP Invalid character. .SS "#define APREQ_ERROR_BADDATA (APREQ_ERROR_GENERAL + 10)" .PP Invalid input data. .SS "#define APREQ_ERROR_BADHEADER (APREQ_ERROR_BADDATA + 4)" .PP Invalid header. .SS "#define APREQ_ERROR_BADSEQ (APREQ_ERROR_BADDATA + 2)" .PP Invalid byte sequence. .SS "#define APREQ_ERROR_BADUTF8 (APREQ_ERROR_BADDATA + 5)" .PP Invalid utf8 encoding. .SS "#define APREQ_ERROR_GENERAL \fBAPR_OS_START_USERERR\fP" .PP Internal apreq error. .SS "#define APREQ_ERROR_INTERRUPT (APREQ_ERROR_GENERAL + 2)" .PP Parsing interrupted. .SS "#define APREQ_ERROR_MISMATCH (APREQ_ERROR_GENERAL + 30)" .PP Conflicting information. .SS "#define APREQ_ERROR_NOATTR (APREQ_ERROR_NODATA + 2)" .PP Missing attribute. .SS "#define APREQ_ERROR_NODATA (APREQ_ERROR_GENERAL + 20)" .PP Missing input data. .SS "#define APREQ_ERROR_NOHEADER (APREQ_ERROR_NODATA + 3)" .PP Missing header. .SS "#define APREQ_ERROR_NOPARSER (APREQ_ERROR_NODATA + 4)" .PP Missing parser. .SS "#define APREQ_ERROR_NOTEMPTY (APREQ_ERROR_MISMATCH + 3)" .PP Setting already configured. .SS "#define APREQ_ERROR_NOTOKEN (APREQ_ERROR_NODATA + 1)" .PP Missing required token. .SS "#define APREQ_ERROR_OVERLIMIT (APREQ_ERROR_MISMATCH + 1)" .PP Exceeds configured maximum limit. .SS "#define APREQ_ERROR_TAINTED (APREQ_ERROR_GENERAL + 1)" .PP Attempted to perform unsafe action with tainted data. .SS "#define APREQ_ERROR_UNDERLIMIT (APREQ_ERROR_MISMATCH + 2)" .PP Below configured minimum limit. .SH "Function Documentation" .PP .SS "char* apreq_strerror (\fBapr_status_t\fP s, char * buf, \fBapr_size_t\fP bufsize)" .PP apreq's wrapper around \fBapr_strerror()\fP; recognizes APREQ_ERROR_* status codes. .SH "Author" .PP Generated automatically by Doxygen for libapreq2 from the source code. rapache-1.2.8/libapreq2/docs/man/man3/apreq_faq.30000644000175100017510000000016512706745114020731 0ustar ondrejondrej.TH "apreq_faq" 3 "4 May 2005" "Version 2.05-dev" "libapreq2" \" -*- nroff -*- .ad l .nh .SH NAME apreq_faq \- FAQ rapache-1.2.8/libapreq2/docs/man/man3/apreq_handle_t.30000644000175100017510000000204212706745114021734 0ustar ondrejondrej.TH "apreq_handle_t" 3 "4 May 2005" "Version 2.05-dev" "libapreq2" \" -*- nroff -*- .ad l .nh .SH NAME apreq_handle_t \- .SH SYNOPSIS .br .PP \fC#include \fP .PP .SS "Data Fields" .in +1c .ti -1c .RI "const struct \fBapreq_module_t\fP * \fBmodule\fP" .br .ti -1c .RI "\fBapr_pool_t\fP * \fBpool\fP" .br .ti -1c .RI "\fBapr_bucket_alloc_t\fP * \fBbucket_alloc\fP" .br .in -1c .SH "Detailed Description" .PP An apreq handle associated with a module. The structure may have variable size, because the module may append its own data structures after it. .PP .SH "Field Documentation" .PP .SS "\fBapr_bucket_alloc_t\fP* \fBapreq_handle_t::bucket_alloc\fP" .PP the allocator, which persists at least as long as the pool .SS "const struct \fBapreq_module_t\fP* \fBapreq_handle_t::module\fP" .PP the apreq module which implements this handle .SS "\fBapr_pool_t\fP* \fBapreq_handle_t::pool\fP" .PP the pool which defines the lifetime of the parsed data .SH "Author" .PP Generated automatically by Doxygen for libapreq2 from the source code. rapache-1.2.8/libapreq2/docs/man/man3/apreq_hook_t.30000644000175100017510000000211412706745114021441 0ustar ondrejondrej.TH "apreq_hook_t" 3 "4 May 2005" "Version 2.05-dev" "libapreq2" \" -*- nroff -*- .ad l .nh .SH NAME apreq_hook_t \- .SH SYNOPSIS .br .PP \fC#include \fP .PP .SS "Data Fields" .in +1c .ti -1c .RI "\fBapreq_hook_function_t\fP \fBhook\fP" .br .ti -1c .RI "\fBapreq_hook_t\fP * \fBnext\fP" .br .ti -1c .RI "\fBapr_pool_t\fP * \fBpool\fP" .br .ti -1c .RI "void * \fBctx\fP" .br .in -1c .SH "Detailed Description" .PP A hook is called by the parser whenever data arrives in a file upload parameter of the request body. You may associate any number of hooks with a parser instance with \fBapreq_parser_add_hook()\fP. .PP .SH "Field Documentation" .PP .SS "void* \fBapreq_hook_t::ctx\fP" .PP a user defined pointer passed to the hook function .SS "\fBapreq_hook_function_t\fP \fBapreq_hook_t::hook\fP" .PP the hook function .SS "\fBapreq_hook_t\fP* \fBapreq_hook_t::next\fP" .PP next item in the linked list .SS "\fBapr_pool_t\fP* \fBapreq_hook_t::pool\fP" .PP pool which allocated this hook .SH "Author" .PP Generated automatically by Doxygen for libapreq2 from the source code. rapache-1.2.8/libapreq2/docs/man/man3/apreq_install.30000644000175100017510000000476512706745114021642 0ustar ondrejondrej.TH "apreq_install" 3 "4 May 2005" "Version 2.05-dev" "libapreq2" \" -*- nroff -*- .ad l .nh .SH NAME apreq_install \- INSTALL .PP .nf PREREQUISITES: Please see the PREREQUISITES file. If you are building httpd-apreq-2 directly from svn, you can generate the list of prerequisites: % perl build/version_check.pl INSTRUCTIONS: FreeBSD users must substitute "gmake" for "make" below. Unix build, where libtool/automake/autoconf works: % ./configure --with-apache2-apxs=/path/to/apache2/bin/apxs % make (optional)% make test % make install Or using the CPAN/perlish way (which includes the Apache::Request and Apache::Cookie modules): % perl Makefile.PL --with-apache2-apxs=/path/to/apache2/bin/apxs % make (optional)% make test % make install Developers and other folks using httpd-apreq-2 directly from svn need to execute "./buildconf" prior to running "./configure". Alternately, here's a recipe to install mod_apreq.c as a static apache module: 1) configure httpd to add mod_apreq.c to its filter modules: % cd /path/to/httpd-2.0 % CPPFLAGS=-I/path/to/httpd-apreq-2/src \ HTTPD_LDFLAGS=/path/to/httpd-apreq-2/src/libapreq2.la \ ./configure --with-module=filters:/path/to/httpd-apreq-2/env/mod_apreq.c \ ...(add usual httpd+apr options here)... 2) compile and install everything using httpd-apreq-2's build system: % cd /path/to/httpd-apreq-2 % ./configure --with-apache2-src=/path/to/httpd-2.0 % make (optional)% make test % make install Win32 build: C:\httpd-apreq-2> perl Makefile.PL C:\httpd-apreq-2> nmake C:\httpd-apreq-2> nmake test C:\httpd-apreq-2> nmake mod_apreq C:\httpd-apreq-2> nmake perl_glue C:\httpd-apreq-2> nmake perl_test SVN (Subversion) ACCESS Development of httpd-apreq-2 can be followed through the svn repository: $ svn checkout http://svn.apache.org/repos/asf/httpd/apreq/trunk/ httpd-apreq-2 Developers with commit access must use the https protocol instead; note that, if you are compiling svn from sources, you must supply the configure script with the appropriate switch to enable ssl. Subversion sources, and binaries for some platforms, may be obtained through the home page: http://subversion.tigris.org/ Documentation on using svn is available at http://svnbook.red-bean.com/ In particular, http://svnbook.red-bean.com/en/1.0/apa.html contains a guide for users familiar with cvs. .fi .PP rapache-1.2.8/libapreq2/docs/man/man3/apreq_lang.30000644000175100017510000000056612706745114021110 0ustar ondrejondrej.TH "Language Bindings" 3 "4 May 2005" "Version 2.05-dev" "libapreq2" \" -*- nroff -*- .ad l .nh .SH NAME Language Bindings \- libapreq2 APIs for programming languages other than C .PP .SS "Modules" .in +1c .ti -1c .RI "\fBPerl\fP" .br .RI "\fIXS Modules. \fP" .PP .in -1c .SH "Detailed Description" .PP libapreq2 APIs for programming languages other than C .PP XXX rapache-1.2.8/libapreq2/docs/man/man3/apreq_license.30000644000175100017510000002635712706745114021617 0ustar ondrejondrej.TH "apreq_license" 3 "4 May 2005" "Version 2.05-dev" "libapreq2" \" -*- nroff -*- .ad l .nh .SH NAME apreq_license \- LICENSE .PP .nf Apache License Version 2.0, January 2004 http://www.apache.org/licenses/ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION 1. Definitions. "License" shall mean the terms and conditions for use, reproduction, and distribution as defined by Sections 1 through 9 of this document. "Licensor" shall mean the copyright owner or entity authorized by the copyright owner that is granting the License. "Legal Entity" shall mean the union of the acting entity and all other entities that control, are controlled by, or are under common control with that entity. For the purposes of this definition, "control" means (i) the power, direct or indirect, to cause the direction or management of such entity, whether by contract or otherwise, or (ii) ownership of fifty percent (50%) or more of the outstanding shares, or (iii) beneficial ownership of such entity. "You" (or "Your") shall mean an individual or Legal Entity exercising permissions granted by this License. "Source" form shall mean the preferred form for making modifications, including but not limited to software source code, documentation source, and configuration files. "Object" form shall mean any form resulting from mechanical transformation or translation of a Source form, including but not limited to compiled object code, generated documentation, and conversions to other media types. "Work" shall mean the work of authorship, whether in Source or Object form, made available under the License, as indicated by a copyright notice that is included in or attached to the work (an example is provided in the Appendix below). "Derivative Works" shall mean any work, whether in Source or Object form, that is based on (or derived from) the Work and for which the editorial revisions, annotations, elaborations, or other modifications represent, as a whole, an original work of authorship. For the purposes of this License, Derivative Works shall not include works that remain separable from, or merely link (or bind by name) to the interfaces of, the Work and Derivative Works thereof. "Contribution" shall mean any work of authorship, including the original version of the Work and any modifications or additions to that Work or Derivative Works thereof, that is intentionally submitted to Licensor for inclusion in the Work by the copyright owner or by an individual or Legal Entity authorized to submit on behalf of the copyright owner. For the purposes of this definition, "submitted" means any form of electronic, verbal, or written communication sent to the Licensor or its representatives, including but not limited to communication on electronic mailing lists, source code control systems, and issue tracking systems that are managed by, or on behalf of, the Licensor for the purpose of discussing and improving the Work, but excluding communication that is conspicuously marked or otherwise designated in writing by the copyright owner as "Not a Contribution." "Contributor" shall mean Licensor and any individual or Legal Entity on behalf of whom a Contribution has been received by Licensor and subsequently incorporated within the Work. 2. Grant of Copyright License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable copyright license to reproduce, prepare Derivative Works of, publicly display, publicly perform, sublicense, and distribute the Work and such Derivative Works in Source or Object form. 3. Grant of Patent License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable (except as stated in this section) patent license to make, have made, use, offer to sell, sell, import, and otherwise transfer the Work, where such license applies only to those patent claims licensable by such Contributor that are necessarily infringed by their Contribution(s) alone or by combination of their Contribution(s) with the Work to which such Contribution(s) was submitted. If You institute patent litigation against any entity (including a cross-claim or counterclaim in a lawsuit) alleging that the Work or a Contribution incorporated within the Work constitutes direct or contributory patent infringement, then any patent licenses granted to You under this License for that Work shall terminate as of the date such litigation is filed. 4. Redistribution. You may reproduce and distribute copies of the Work or Derivative Works thereof in any medium, with or without modifications, and in Source or Object form, provided that You meet the following conditions: (a) You must give any other recipients of the Work or Derivative Works a copy of this License; and (b) You must cause any modified files to carry prominent notices stating that You changed the files; and (c) You must retain, in the Source form of any Derivative Works that You distribute, all copyright, patent, trademark, and attribution notices from the Source form of the Work, excluding those notices that do not pertain to any part of the Derivative Works; and (d) If the Work includes a "NOTICE" text file as part of its distribution, then any Derivative Works that You distribute must include a readable copy of the attribution notices contained within such NOTICE file, excluding those notices that do not pertain to any part of the Derivative Works, in at least one of the following places: within a NOTICE text file distributed as part of the Derivative Works; within the Source form or documentation, if provided along with the Derivative Works; or, within a display generated by the Derivative Works, if and wherever such third-party notices normally appear. The contents of the NOTICE file are for informational purposes only and do not modify the License. You may add Your own attribution notices within Derivative Works that You distribute, alongside or as an addendum to the NOTICE text from the Work, provided that such additional attribution notices cannot be construed as modifying the License. You may add Your own copyright statement to Your modifications and may provide additional or different license terms and conditions for use, reproduction, or distribution of Your modifications, or for any such Derivative Works as a whole, provided Your use, reproduction, and distribution of the Work otherwise complies with the conditions stated in this License. 5. Submission of Contributions. Unless You explicitly state otherwise, any Contribution intentionally submitted for inclusion in the Work by You to the Licensor shall be under the terms and conditions of this License, without any additional terms or conditions. Notwithstanding the above, nothing herein shall supersede or modify the terms of any separate license agreement you may have executed with Licensor regarding such Contributions. 6. Trademarks. This License does not grant permission to use the trade names, trademarks, service marks, or product names of the Licensor, except as required for reasonable and customary use in describing the origin of the Work and reproducing the content of the NOTICE file. 7. Disclaimer of Warranty. Unless required by applicable law or agreed to in writing, Licensor provides the Work (and each Contributor provides its Contributions) on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied, including, without limitation, any warranties or conditions of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A PARTICULAR PURPOSE. You are solely responsible for determining the appropriateness of using or redistributing the Work and assume any risks associated with Your exercise of permissions under this License. 8. Limitation of Liability. In no event and under no legal theory, whether in tort (including negligence), contract, or otherwise, unless required by applicable law (such as deliberate and grossly negligent acts) or agreed to in writing, shall any Contributor be liable to You for damages, including any direct, indirect, special, incidental, or consequential damages of any character arising as a result of this License or out of the use or inability to use the Work (including but not limited to damages for loss of goodwill, work stoppage, computer failure or malfunction, or any and all other commercial damages or losses), even if such Contributor has been advised of the possibility of such damages. 9. Accepting Warranty or Additional Liability. While redistributing the Work or Derivative Works thereof, You may choose to offer, and charge a fee for, acceptance of support, warranty, indemnity, or other liability obligations and/or rights consistent with this License. However, in accepting such obligations, You may act only on Your own behalf and on Your sole responsibility, not on behalf of any other Contributor, and only if You agree to indemnify, defend, and hold each Contributor harmless for any liability incurred by, or claims asserted against, such Contributor by reason of your accepting any such warranty or additional liability. END OF TERMS AND CONDITIONS APPENDIX: How to apply the Apache License to your work. To apply the Apache License to your work, attach the following boilerplate notice, with the fields enclosed by brackets "[]" replaced with your own identifying information. (Don't include the brackets!) The text should be enclosed in the appropriate comment syntax for the file format. We also recommend that a file or class name and description of purpose be included on the same "printed page" as the copyright notice for easier identification within third-party archives. Copyright [yyyy] [name of copyright owner] Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. .fi .PP rapache-1.2.8/libapreq2/docs/man/man3/apreq_module.30000644000175100017510000000063412706745114021450 0ustar ondrejondrej.TH "Modules" 3 "4 May 2005" "Version 2.05-dev" "libapreq2" \" -*- nroff -*- .ad l .nh .SH NAME Modules \- apreq2 modules included in libapreq2-2.05-dev. .PP .SS "Modules" .in +1c .ti -1c .RI "\fBApache 2.X Filter Module\fP" .br .RI "\fImod_apreq2 - DSO that ties libapreq2 to \fBApache\fP HTTPD 2.X. \fP" .PP .in -1c .SH "Detailed Description" .PP apreq2 modules included in libapreq2-2.05-dev. .PP XXX rapache-1.2.8/libapreq2/docs/man/man3/apreq_module.h.30000644000175100017510000003624612706745114021706 0ustar ondrejondrej.TH "include/apreq_module.h" 3 "4 May 2005" "Version 2.05-dev" "libapreq2" \" -*- nroff -*- .ad l .nh .SH NAME include/apreq_module.h \- Module API. .SH SYNOPSIS .br .PP \fC#include 'apreq_cookie.h'\fP .br \fC#include 'apreq_parser.h'\fP .br \fC#include 'apreq_error.h'\fP .br .SS "Defines" .in +1c .ti -1c .RI "#define \fBAPREQ_MODULE\fP(pre, mmn)" .br .ti -1c .RI "#define \fBapreq_cookie\fP(req, name) apreq_jar_get(req, name)" .br .in -1c .SS "Typedefs" .in +1c .ti -1c .RI "typedef \fBapreq_handle_t\fP \fBapreq_handle_t\fP" .br .ti -1c .RI "typedef \fBapreq_module_t\fP \fBapreq_module_t\fP" .br .RI "\fIVtable describing the necessary environment functions. \fP" .in -1c .SS "Functions" .in +1c .ti -1c .RI "static \fBAPR_INLINE\fP unsigned \fBapreq_module_status_is_error\fP (\fBapr_status_t\fP s)" .br .ti -1c .RI "static \fBAPR_INLINE\fP \fBapr_status_t\fP \fBapreq_jar\fP (\fBapreq_handle_t\fP *req, const \fBapr_table_t\fP **t)" .br .ti -1c .RI "static \fBAPR_INLINE\fP \fBapr_status_t\fP \fBapreq_args\fP (\fBapreq_handle_t\fP *req, const \fBapr_table_t\fP **t)" .br .ti -1c .RI "static \fBAPR_INLINE\fP \fBapr_status_t\fP \fBapreq_body\fP (\fBapreq_handle_t\fP *req, const \fBapr_table_t\fP **t)" .br .ti -1c .RI "static \fBAPR_INLINE\fP \fBapreq_cookie_t\fP * \fBapreq_jar_get\fP (\fBapreq_handle_t\fP *req, const char *name)" .br .ti -1c .RI "static \fBAPR_INLINE\fP \fBapreq_param_t\fP * \fBapreq_args_get\fP (\fBapreq_handle_t\fP *req, const char *name)" .br .ti -1c .RI "static \fBAPR_INLINE\fP \fBapreq_param_t\fP * \fBapreq_body_get\fP (\fBapreq_handle_t\fP *req, const char *name)" .br .ti -1c .RI "static \fBAPR_INLINE\fP \fBapr_status_t\fP \fBapreq_parser_get\fP (\fBapreq_handle_t\fP *req, const \fBapreq_parser_t\fP **parser)" .br .ti -1c .RI "static \fBAPR_INLINE\fP \fBapr_status_t\fP \fBapreq_parser_set\fP (\fBapreq_handle_t\fP *req, \fBapreq_parser_t\fP *parser)" .br .ti -1c .RI "static \fBAPR_INLINE\fP \fBapr_status_t\fP \fBapreq_hook_add\fP (\fBapreq_handle_t\fP *req, \fBapreq_hook_t\fP *hook)" .br .ti -1c .RI "static \fBAPR_INLINE\fP \fBapr_status_t\fP \fBapreq_brigade_limit_set\fP (\fBapreq_handle_t\fP *req, \fBapr_size_t\fP bytes)" .br .ti -1c .RI "static \fBAPR_INLINE\fP \fBapr_status_t\fP \fBapreq_brigade_limit_get\fP (\fBapreq_handle_t\fP *req, \fBapr_size_t\fP *bytes)" .br .ti -1c .RI "static \fBAPR_INLINE\fP \fBapr_status_t\fP \fBapreq_read_limit_set\fP (\fBapreq_handle_t\fP *req, \fBapr_uint64_t\fP bytes)" .br .ti -1c .RI "static \fBAPR_INLINE\fP \fBapr_status_t\fP \fBapreq_read_limit_get\fP (\fBapreq_handle_t\fP *req, \fBapr_uint64_t\fP *bytes)" .br .ti -1c .RI "static \fBAPR_INLINE\fP \fBapr_status_t\fP \fBapreq_temp_dir_set\fP (\fBapreq_handle_t\fP *req, const char *path)" .br .ti -1c .RI "static \fBAPR_INLINE\fP \fBapr_status_t\fP \fBapreq_temp_dir_get\fP (\fBapreq_handle_t\fP *req, const char **path)" .br .ti -1c .RI "\fBapreq_handle_t\fP * \fBapreq_handle_cgi\fP (\fBapr_pool_t\fP *pool)" .br .ti -1c .RI "\fBapreq_handle_t\fP * \fBapreq_handle_custom\fP (\fBapr_pool_t\fP *pool, const char *query_string, const char *cookie, \fBapreq_parser_t\fP *parser, \fBapr_uint64_t\fP read_limit, \fBapr_bucket_brigade\fP *in)" .br .ti -1c .RI "\fBapr_status_t\fP \fBapreq_cookie_bake\fP (const \fBapreq_cookie_t\fP *c, \fBapreq_handle_t\fP *req)" .br .ti -1c .RI "\fBapr_status_t\fP \fBapreq_cookie_bake2\fP (const \fBapreq_cookie_t\fP *c, \fBapreq_handle_t\fP *req)" .br .ti -1c .RI "unsigned \fBapreq_ua_cookie_version\fP (\fBapreq_handle_t\fP *req)" .br .ti -1c .RI "\fBapreq_param_t\fP * \fBapreq_param\fP (\fBapreq_handle_t\fP *req, const char *key)" .br .ti -1c .RI "\fBapr_table_t\fP * \fBapreq_params\fP (\fBapreq_handle_t\fP *req, \fBapr_pool_t\fP *p)" .br .ti -1c .RI "\fBapr_table_t\fP * \fBapreq_cookies\fP (\fBapreq_handle_t\fP *req, \fBapr_pool_t\fP *p)" .br .ti -1c .RI "static \fBAPR_INLINE\fP \fBapr_status_t\fP \fBapreq_parse\fP (\fBapreq_handle_t\fP *req)" .br .in -1c .SH "Detailed Description" .PP Module API. .SH "Define Documentation" .PP .SS "#define apreq_cookie(req, name) apreq_jar_get(req, name)" .PP Find the first cookie with the specified name. The match is case-insensitive. .PP \fBParameters:\fP .RS 4 \fIreq\fP request handle. .br \fIkey\fP desired cookie name .RE .PP \fBReturns:\fP .RS 4 The first matching parameter (with args searched first) or NULL. .RE .PP .SS "#define APREQ_MODULE(pre, mmn)" .PP \fBValue:\fP .PP .nf const apreq_module_t \ pre##_module = { #pre, mmn, \ pre##_jar, pre##_args, pre##_body, \ pre##_jar_get, pre##_args_get, pre##_body_get, \ pre##_parser_get, pre##_parser_set, pre##_hook_add, \ pre##_brigade_limit_get, pre##_brigade_limit_set, \ pre##_read_limit_get, pre##_read_limit_set, \ pre##_temp_dir_get, pre##_temp_dir_set, \ } .fi Convenience macro for defining a module by mapping a function prefix to an associated \fBapreq_module_t\fP structure. .PP \fBParameters:\fP .RS 4 \fIpre\fP Prefix to define new environment. All attributes of the apreq_env_module_t struct are defined with this as their prefix. The generated struct is named by appending '_module' to the prefix. .br \fImmn\fP Magic number (i.e. version number) of this environment. .RE .PP .SH "Typedef Documentation" .PP .SS "typedef struct \fBapreq_handle_t\fP \fBapreq_handle_t\fP" .PP An apreq handle associated with a module. The structure may have variable size, because the module may append its own data structures after it. .SH "Function Documentation" .PP .SS "static \fBAPR_INLINE\fP \fBapr_status_t\fP apreq_args (\fBapreq_handle_t\fP * req, const \fBapr_table_t\fP ** t)\fC [static]\fP" .PP Expose the parsed 'query string' associated to this handle. .PP \fBParameters:\fP .RS 4 \fIreq\fP The request handle .br \fIt\fP The resulting table, which will either be NULL or a valid table object on return. .RE .PP \fBReturns:\fP .RS 4 APR_SUCCESS or a module-specific error status code. .RE .PP .SS "static \fBAPR_INLINE\fP \fBapreq_param_t\fP* apreq_args_get (\fBapreq_handle_t\fP * req, const char * name)\fC [static]\fP" .PP Fetch the first query string param with the given name. .PP \fBParameters:\fP .RS 4 \fIreq\fP The request handle .br \fIname\fP Case-insensitive param name. .RE .PP \fBReturns:\fP .RS 4 First matching param, or NULL if none match. .RE .PP .SS "static \fBAPR_INLINE\fP \fBapr_status_t\fP apreq_body (\fBapreq_handle_t\fP * req, const \fBapr_table_t\fP ** t)\fC [static]\fP" .PP Expose the parsed 'request body' associated to this handle. .PP \fBParameters:\fP .RS 4 \fIreq\fP The request handle .br \fIt\fP The resulting table, which will either be NULL or a valid table object on return. .RE .PP \fBReturns:\fP .RS 4 APR_SUCCESS or a module-specific error status code. .RE .PP .SS "static \fBAPR_INLINE\fP \fBapreq_param_t\fP* apreq_body_get (\fBapreq_handle_t\fP * req, const char * name)\fC [static]\fP" .PP Fetch the first body param with the given name. .PP \fBParameters:\fP .RS 4 \fIreq\fP The request handle .br \fIname\fP Case-insensitive cookie name. .RE .PP \fBReturns:\fP .RS 4 First matching param, or NULL if none match. .RE .PP .SS "static \fBAPR_INLINE\fP \fBapr_status_t\fP apreq_brigade_limit_get (\fBapreq_handle_t\fP * req, \fBapr_size_t\fP * bytes)\fC [static]\fP" .PP Get the active brigade limit. .PP \fBParameters:\fP .RS 4 \fIreq\fP The handle. .br \fIbytes\fP Pointer to resulting (current) limit. .RE .PP \fBReturns:\fP .RS 4 APR_SUCCESS or a module-specific error, which may leave bytes undefined. .RE .PP .SS "static \fBAPR_INLINE\fP \fBapr_status_t\fP apreq_brigade_limit_set (\fBapreq_handle_t\fP * req, \fBapr_size_t\fP bytes)\fC [static]\fP" .PP Set the active brigade limit. .PP \fBParameters:\fP .RS 4 \fIreq\fP The handle. .br \fIbytes\fP New limit to use. .RE .PP \fBReturns:\fP .RS 4 APR_SUCCESS or module-specific error. .RE .PP .SS "\fBapr_status_t\fP apreq_cookie_bake (const \fBapreq_cookie_t\fP * c, \fBapreq_handle_t\fP * req)" .PP Add the cookie to the outgoing 'Set-Cookie' headers. .PP \fBParameters:\fP .RS 4 \fIc\fP The cookie. .br \fIreq\fP The request handle which set the outgoing header. .RE .PP \fBReturns:\fP .RS 4 APR_SUCCESS or error. .RE .PP .SS "\fBapr_status_t\fP apreq_cookie_bake2 (const \fBapreq_cookie_t\fP * c, \fBapreq_handle_t\fP * req)" .PP Add the cookie to the outgoing 'Set-Cookie2' headers. .PP \fBParameters:\fP .RS 4 \fIc\fP cookie .br \fIreq\fP request handle .RE .PP \fBReturns:\fP .RS 4 APR_SUCCESS or error. .RE .PP .SS "\fBapr_table_t\fP* apreq_cookies (\fBapreq_handle_t\fP * req, \fBapr_pool_t\fP * p)" .PP Returns a table containing all request cookies. .PP \fBParameters:\fP .RS 4 \fIreq\fP the apreq request handle .br \fIp\fP Allocates the returned table. .RE .PP .SS "\fBapreq_handle_t\fP* apreq_handle_cgi (\fBapr_pool_t\fP * pool)" .PP Create an apreq handle which is suitable for a CGI program. It reads input from stdin and writes output to stdout. .PP \fBParameters:\fP .RS 4 \fIpool\fP Pool associated to this handle. .RE .PP \fBReturns:\fP .RS 4 New handle; can only be NULL if the pool allocation failed. .RE .PP \fBRemarks:\fP .RS 4 The handle gets cached in the pool's userdata, so subsequent calls will retrieve the original cached handle. .RE .PP .SS "\fBapreq_handle_t\fP* apreq_handle_custom (\fBapr_pool_t\fP * pool, const char * query_string, const char * cookie, \fBapreq_parser_t\fP * parser, \fBapr_uint64_t\fP read_limit, \fBapr_bucket_brigade\fP * in)" .PP Create a custom apreq handle which knows only some static values. Useful if you want to test the parser code or if you have got data from a custom source (neither \fBApache\fP 2 nor CGI). .PP \fBParameters:\fP .RS 4 \fIpool\fP allocates the parse data, .br \fIquery_string\fP parsed into args table .br \fIcookie\fP value of the request 'Cookie' header .br \fIparser\fP parses the request body .br \fIread_limit\fP maximum bytes to read from the body .br \fIin\fP brigade containing the request body .RE .PP \fBReturns:\fP .RS 4 new handle; can only be NULL if the pool allocation failed. .RE .PP .SS "static \fBAPR_INLINE\fP \fBapr_status_t\fP apreq_hook_add (\fBapreq_handle_t\fP * req, \fBapreq_hook_t\fP * hook)\fC [static]\fP" .PP Add a parser hook for this request. .PP \fBParameters:\fP .RS 4 \fIreq\fP The request handle .br \fIhook\fP Hook to add. .RE .PP \fBReturns:\fP .RS 4 APR_SUCCESS or module-specific error. .RE .PP .SS "static \fBAPR_INLINE\fP \fBapr_status_t\fP apreq_jar (\fBapreq_handle_t\fP * req, const \fBapr_table_t\fP ** t)\fC [static]\fP" .PP Expose the parsed 'cookie' header associated to this handle. .PP \fBParameters:\fP .RS 4 \fIreq\fP The request handle .br \fIt\fP The resulting table, which will either be NULL or a valid table object on return. .RE .PP \fBReturns:\fP .RS 4 APR_SUCCESS or a module-specific error status code. .RE .PP .SS "static \fBAPR_INLINE\fP \fBapreq_cookie_t\fP* apreq_jar_get (\fBapreq_handle_t\fP * req, const char * name)\fC [static]\fP" .PP Fetch the first cookie with the given name. .PP \fBParameters:\fP .RS 4 \fIreq\fP The request handle .br \fIname\fP Case-insensitive cookie name. .RE .PP \fBReturns:\fP .RS 4 First matching cookie, or NULL if none match. .RE .PP .SS "static \fBAPR_INLINE\fP unsigned apreq_module_status_is_error (\fBapr_status_t\fP s)\fC [static]\fP" .PP Defines the module-specific status codes which are commonly considered to be non-fatal. .PP \fBParameters:\fP .RS 4 \fIs\fP status code returned by an \fBapreq_module_t\fP method. .RE .PP \fBReturns:\fP .RS 4 1 if s is fatal, 0 otherwise. .RE .PP .SS "\fBapreq_param_t\fP* apreq_param (\fBapreq_handle_t\fP * req, const char * key)" .PP Find the first query string parameter or body parameter with the specified name. The match is case-insensitive. .PP \fBParameters:\fP .RS 4 \fIreq\fP request handle. .br \fIkey\fP desired parameter name .RE .PP \fBReturns:\fP .RS 4 The first matching parameter (with args searched first) or NULL. .RE .PP .SS "\fBapr_table_t\fP* apreq_params (\fBapreq_handle_t\fP * req, \fBapr_pool_t\fP * p)" .PP Returns a table containing key-value pairs for the full request (args + body). .PP \fBParameters:\fP .RS 4 \fIreq\fP request handle .br \fIp\fP allocates the returned table. .RE .PP \fBReturns:\fP .RS 4 table representing all available params; is never NULL. .RE .PP .SS "static \fBAPR_INLINE\fP \fBapr_status_t\fP apreq_parse (\fBapreq_handle_t\fP * req)\fC [static]\fP" .PP Force a complete parse of everything. .PP \fBParameters:\fP .RS 4 \fIreq\fP The request handle .RE .PP \fBReturns:\fP .RS 4 APR_SUCCESS on an error-free parse of the request data. Any other status code indicates a potential problem somewhere. .RE .PP .SS "static \fBAPR_INLINE\fP \fBapr_status_t\fP apreq_parser_get (\fBapreq_handle_t\fP * req, const \fBapreq_parser_t\fP ** parser)\fC [static]\fP" .PP Fetch the active body parser. .PP \fBParameters:\fP .RS 4 \fIreq\fP The request handle .br \fIparser\fP Points to the active parser on return. .RE .PP \fBReturns:\fP .RS 4 APR_SUCCESS or module-specific error. .RE .PP .SS "static \fBAPR_INLINE\fP \fBapr_status_t\fP apreq_parser_set (\fBapreq_handle_t\fP * req, \fBapreq_parser_t\fP * parser)\fC [static]\fP" .PP Set the body parser for this request. .PP \fBParameters:\fP .RS 4 \fIreq\fP The request handle .br \fIparser\fP New parser to use. .RE .PP \fBReturns:\fP .RS 4 APR_SUCCESS or module-specific error. .RE .PP .SS "static \fBAPR_INLINE\fP \fBapr_status_t\fP apreq_read_limit_get (\fBapreq_handle_t\fP * req, \fBapr_uint64_t\fP * bytes)\fC [static]\fP" .PP Get the active read limit. .PP \fBParameters:\fP .RS 4 \fIreq\fP The request handle. .br \fIbytes\fP Pointer to resulting (current) limit. .RE .PP \fBReturns:\fP .RS 4 APR_SUCCESS or a module-specific error, which may leave bytes undefined. .RE .PP .SS "static \fBAPR_INLINE\fP \fBapr_status_t\fP apreq_read_limit_set (\fBapreq_handle_t\fP * req, \fBapr_uint64_t\fP bytes)\fC [static]\fP" .PP Set the active read limit. .PP \fBParameters:\fP .RS 4 \fIreq\fP The handle. .br \fIbytes\fP New limit to use. .RE .PP \fBReturns:\fP .RS 4 APR_SUCCESS or a module-specific error. .RE .PP .SS "static \fBAPR_INLINE\fP \fBapr_status_t\fP apreq_temp_dir_get (\fBapreq_handle_t\fP * req, const char ** path)\fC [static]\fP" .PP Get the active temp directory. .PP \fBParameters:\fP .RS 4 \fIreq\fP The handle. .br \fIpath\fP Resulting path to temp dir. .RE .PP \fBReturns:\fP .RS 4 APR_SUCCESS implies path is valid, but may also be NULL. Any other return value is module-specific, and may leave path undefined. .RE .PP .SS "static \fBAPR_INLINE\fP \fBapr_status_t\fP apreq_temp_dir_set (\fBapreq_handle_t\fP * req, const char * path)\fC [static]\fP" .PP Set the active temp directory. .PP \fBParameters:\fP .RS 4 \fIreq\fP The handle. .br \fIpath\fP New path to use; may be NULL. .RE .PP \fBReturns:\fP .RS 4 APR_SUCCESS or a module-specific error . .RE .PP .SS "unsigned apreq_ua_cookie_version (\fBapreq_handle_t\fP * req)" .PP Looks for the presence of a 'Cookie2' header to determine whether or not the current User-Agent responsible for this request supports rfc2965. .PP \fBParameters:\fP .RS 4 \fIreq\fP the apreq request handle .RE .PP \fBReturns:\fP .RS 4 ::APREQ_COOKIE_VERSION_RFC if rfc2965 is supported by the user-agent, ::APREQ_COOKIE_VERSION_NETSCAPE otherwise. .RE .PP .SH "Author" .PP Generated automatically by Doxygen for libapreq2 from the source code. rapache-1.2.8/libapreq2/docs/man/man3/apreq_module_t.30000644000175100017510000001107612706745114021775 0ustar ondrejondrej.TH "apreq_module_t" 3 "4 May 2005" "Version 2.05-dev" "libapreq2" \" -*- nroff -*- .ad l .nh .SH NAME apreq_module_t \- Vtable describing the necessary environment functions. .PP .SH SYNOPSIS .br .PP \fC#include \fP .PP .SS "Data Fields" .in +1c .ti -1c .RI "const char * \fBname\fP" .br .ti -1c .RI "\fBapr_uint32_t\fP \fBmagic_number\fP" .br .ti -1c .RI "\fBapr_status_t\fP(* \fBjar\fP )(\fBapreq_handle_t\fP *, const \fBapr_table_t\fP **)" .br .ti -1c .RI "\fBapr_status_t\fP(* \fBargs\fP )(\fBapreq_handle_t\fP *, const \fBapr_table_t\fP **)" .br .ti -1c .RI "\fBapr_status_t\fP(* \fBbody\fP )(\fBapreq_handle_t\fP *, const \fBapr_table_t\fP **)" .br .ti -1c .RI "\fBapreq_cookie_t\fP *(* \fBjar_get\fP )(\fBapreq_handle_t\fP *, const char *)" .br .ti -1c .RI "\fBapreq_param_t\fP *(* \fBargs_get\fP )(\fBapreq_handle_t\fP *, const char *)" .br .ti -1c .RI "\fBapreq_param_t\fP *(* \fBbody_get\fP )(\fBapreq_handle_t\fP *, const char *)" .br .ti -1c .RI "\fBapr_status_t\fP(* \fBparser_get\fP )(\fBapreq_handle_t\fP *, const \fBapreq_parser_t\fP **)" .br .ti -1c .RI "\fBapr_status_t\fP(* \fBparser_set\fP )(\fBapreq_handle_t\fP *, \fBapreq_parser_t\fP *)" .br .ti -1c .RI "\fBapr_status_t\fP(* \fBhook_add\fP )(\fBapreq_handle_t\fP *, \fBapreq_hook_t\fP *)" .br .ti -1c .RI "\fBapr_status_t\fP(* \fBbrigade_limit_get\fP )(\fBapreq_handle_t\fP *, \fBapr_size_t\fP *)" .br .ti -1c .RI "\fBapr_status_t\fP(* \fBbrigade_limit_set\fP )(\fBapreq_handle_t\fP *, \fBapr_size_t\fP)" .br .ti -1c .RI "\fBapr_status_t\fP(* \fBread_limit_get\fP )(\fBapreq_handle_t\fP *, \fBapr_uint64_t\fP *)" .br .ti -1c .RI "\fBapr_status_t\fP(* \fBread_limit_set\fP )(\fBapreq_handle_t\fP *, \fBapr_uint64_t\fP)" .br .ti -1c .RI "\fBapr_status_t\fP(* \fBtemp_dir_get\fP )(\fBapreq_handle_t\fP *, const char **)" .br .ti -1c .RI "\fBapr_status_t\fP(* \fBtemp_dir_set\fP )(\fBapreq_handle_t\fP *, const char *)" .br .in -1c .SH "Detailed Description" .PP Vtable describing the necessary environment functions. .PP .SH "Field Documentation" .PP .SS "\fBapr_status_t\fP(* \fBapreq_module_t::args\fP)(\fBapreq_handle_t\fP *, const \fBapr_table_t\fP **)" .PP get a table with all query string parameters .SS "\fBapreq_param_t\fP*(* \fBapreq_module_t::args_get\fP)(\fBapreq_handle_t\fP *, const char *)" .PP get a query string parameter by its name .SS "\fBapr_status_t\fP(* \fBapreq_module_t::body\fP)(\fBapreq_handle_t\fP *, const \fBapr_table_t\fP **)" .PP get a table with all body parameters .SS "\fBapreq_param_t\fP*(* \fBapreq_module_t::body_get\fP)(\fBapreq_handle_t\fP *, const char *)" .PP get a body parameter by its name .SS "\fBapr_status_t\fP(* \fBapreq_module_t::brigade_limit_get\fP)(\fBapreq_handle_t\fP *, \fBapr_size_t\fP *)" .PP determine the maximum in-memory bytes a brigade may use .SS "\fBapr_status_t\fP(* \fBapreq_module_t::brigade_limit_set\fP)(\fBapreq_handle_t\fP *, \fBapr_size_t\fP)" .PP set the maximum in-memory bytes a brigade may use .SS "\fBapr_status_t\fP(* \fBapreq_module_t::hook_add\fP)(\fBapreq_handle_t\fP *, \fBapreq_hook_t\fP *)" .PP add a hook function .SS "\fBapr_status_t\fP(* \fBapreq_module_t::jar\fP)(\fBapreq_handle_t\fP *, const \fBapr_table_t\fP **)" .PP get a table with all cookies .SS "\fBapreq_cookie_t\fP*(* \fBapreq_module_t::jar_get\fP)(\fBapreq_handle_t\fP *, const char *)" .PP get a cookie by its name .SS "\fBapr_uint32_t\fP \fBapreq_module_t::magic_number\fP" .PP magic number identifying the module and version .SS "const char* \fBapreq_module_t::name\fP" .PP name of this apreq module .SS "\fBapr_status_t\fP(* \fBapreq_module_t::parser_get\fP)(\fBapreq_handle_t\fP *, const \fBapreq_parser_t\fP **)" .PP gets the parser associated with the request body .SS "\fBapr_status_t\fP(* \fBapreq_module_t::parser_set\fP)(\fBapreq_handle_t\fP *, \fBapreq_parser_t\fP *)" .PP manually set a parser for the request body .SS "\fBapr_status_t\fP(* \fBapreq_module_t::read_limit_get\fP)(\fBapreq_handle_t\fP *, \fBapr_uint64_t\fP *)" .PP determine the maximum amount of data that will be fed into a parser .SS "\fBapr_status_t\fP(* \fBapreq_module_t::read_limit_set\fP)(\fBapreq_handle_t\fP *, \fBapr_uint64_t\fP)" .PP set the maximum amount of data that will be fed into a parser .SS "\fBapr_status_t\fP(* \fBapreq_module_t::temp_dir_get\fP)(\fBapreq_handle_t\fP *, const char **)" .PP determine the directory used by the parser for temporary files .SS "\fBapr_status_t\fP(* \fBapreq_module_t::temp_dir_set\fP)(\fBapreq_handle_t\fP *, const char *)" .PP set the directory used by the parser for temporary files .SH "Author" .PP Generated automatically by Doxygen for libapreq2 from the source code. rapache-1.2.8/libapreq2/docs/man/man3/apreq_notice.30000644000175100017510000000036312706745114021443 0ustar ondrejondrej.TH "apreq_notice" 3 "4 May 2005" "Version 2.05-dev" "libapreq2" \" -*- nroff -*- .ad l .nh .SH NAME apreq_notice \- NOTICE .PP .nf This product includes software developed by The Apache Software Foundation (http://www.apache.org/). .fi .PP rapache-1.2.8/libapreq2/docs/man/man3/apreq_param.h.30000644000175100017510000001727612706745114021523 0ustar ondrejondrej.TH "include/apreq_param.h" 3 "4 May 2005" "Version 2.05-dev" "libapreq2" \" -*- nroff -*- .ad l .nh .SH NAME include/apreq_param.h \- Request parsing and parameter API. .SH SYNOPSIS .br .PP \fC#include 'apreq.h'\fP .br \fC#include 'apr_buckets.h'\fP .br .SS "Typedefs" .in +1c .ti -1c .RI "typedef \fBapreq_param_t\fP \fBapreq_param_t\fP" .br .in -1c .SS "Functions" .in +1c .ti -1c .RI "static \fBAPR_INLINE\fP unsigned \fBapreq_param_is_tainted\fP (const \fBapreq_param_t\fP *p)" .br .ti -1c .RI "static \fBAPR_INLINE\fP void \fBapreq_param_tainted_on\fP (\fBapreq_param_t\fP *p)" .br .ti -1c .RI "static \fBAPR_INLINE\fP void \fBapreq_param_tainted_off\fP (\fBapreq_param_t\fP *p)" .br .ti -1c .RI "static \fBAPR_INLINE\fP \fBapreq_charset_t\fP \fBapreq_param_charset_set\fP (\fBapreq_param_t\fP *p, unsigned char c)" .br .ti -1c .RI "static \fBAPR_INLINE\fP \fBapreq_charset_t\fP \fBapreq_param_charset_get\fP (\fBapreq_param_t\fP *p)" .br .ti -1c .RI "static \fBAPR_INLINE\fP \fBapreq_param_t\fP * \fBapreq_value_to_param\fP (const char *val)" .br .ti -1c .RI "\fBapreq_param_t\fP * \fBapreq_param_make\fP (\fBapr_pool_t\fP *p, const char *name, const \fBapr_size_t\fP nlen, const char *val, const \fBapr_size_t\fP vlen)" .br .ti -1c .RI "\fBapr_status_t\fP \fBapreq_param_decode\fP (\fBapreq_param_t\fP **param, \fBapr_pool_t\fP *pool, const char *word, \fBapr_size_t\fP nlen, \fBapr_size_t\fP vlen)" .br .ti -1c .RI "char * \fBapreq_param_encode\fP (\fBapr_pool_t\fP *pool, const \fBapreq_param_t\fP *param)" .br .ti -1c .RI "\fBapr_status_t\fP \fBapreq_parse_query_string\fP (\fBapr_pool_t\fP *pool, \fBapr_table_t\fP *t, const char *qs)" .br .ti -1c .RI "\fBapr_array_header_t\fP * \fBapreq_params_as_array\fP (\fBapr_pool_t\fP *p, const \fBapr_table_t\fP *t, const char *key)" .br .ti -1c .RI "const char * \fBapreq_params_as_string\fP (\fBapr_pool_t\fP *p, const \fBapr_table_t\fP *t, const char *key, \fBapreq_join_t\fP mode)" .br .ti -1c .RI "const \fBapr_table_t\fP * \fBapreq_uploads\fP (const \fBapr_table_t\fP *body, \fBapr_pool_t\fP *pool)" .br .ti -1c .RI "const \fBapreq_param_t\fP * \fBapreq_upload\fP (const \fBapr_table_t\fP *body, const char *name)" .br .in -1c .SH "Detailed Description" .PP Request parsing and parameter API. .SH "Typedef Documentation" .PP .SS "typedef struct \fBapreq_param_t\fP \fBapreq_param_t\fP" .PP Common data structure for params and file uploads .SH "Function Documentation" .PP .SS "static \fBAPR_INLINE\fP \fBapreq_charset_t\fP apreq_param_charset_get (\fBapreq_param_t\fP * p)\fC [static]\fP" .PP Gets the character encoding for this parameter. .SS "static \fBAPR_INLINE\fP \fBapreq_charset_t\fP apreq_param_charset_set (\fBapreq_param_t\fP * p, unsigned char c)\fC [static]\fP" .PP Sets the character encoding for this parameter. .SS "\fBapr_status_t\fP apreq_param_decode (\fBapreq_param_t\fP ** param, \fBapr_pool_t\fP * pool, const char * word, \fBapr_size_t\fP nlen, \fBapr_size_t\fP vlen)" .PP Url-decodes a name=value pair into a param. .PP \fBParameters:\fP .RS 4 \fIparam\fP points to the decoded parameter on success .br \fIpool\fP Pool from which the param is allocated. .br \fIword\fP Start of the name=value pair. .br \fInlen\fP Length of urlencoded name. .br \fIvlen\fP Length of urlencoded value. .RE .PP \fBReturns:\fP .RS 4 APR_SUCCESS + apreq_charset_t (<=APREQ_CHARSET_UTF8) on success. .PP \fBAPREQ_ERROR_BADSEQ\fP or \fBAPREQ_ERROR_BADCHAR\fP on malformed input. .RE .PP \fBRemarks:\fP .RS 4 Unless vlen == 0, this function assumes there is exactly one character ('=') which separates the pair. .RE .PP .SS "char* apreq_param_encode (\fBapr_pool_t\fP * pool, const \fBapreq_param_t\fP * param)" .PP Url-encodes the param into a name-value pair. .PP \fBParameters:\fP .RS 4 \fIpool\fP Pool which allocates the returned string. .br \fIparam\fP Param to encode. .RE .PP \fBReturns:\fP .RS 4 name-value pair representing the param. .RE .PP .SS "static \fBAPR_INLINE\fP unsigned apreq_param_is_tainted (const \fBapreq_param_t\fP * p)\fC [static]\fP" .PP \fBReturns:\fP .RS 4 1 if the taint flag is set, 0 otherwise. .RE .PP .SS "\fBapreq_param_t\fP* apreq_param_make (\fBapr_pool_t\fP * p, const char * name, const \fBapr_size_t\fP nlen, const char * val, const \fBapr_size_t\fP vlen)" .PP creates a param from name/value information .SS "static \fBAPR_INLINE\fP void apreq_param_tainted_off (\fBapreq_param_t\fP * p)\fC [static]\fP" .PP Turns off the taint flag. .SS "static \fBAPR_INLINE\fP void apreq_param_tainted_on (\fBapreq_param_t\fP * p)\fC [static]\fP" .PP Sets the tainted flag. .SS "\fBapr_array_header_t\fP* apreq_params_as_array (\fBapr_pool_t\fP * p, const \fBapr_table_t\fP * t, const char * key)" .PP Returns an array of parameters (\fBapreq_param_t\fP *) matching the given key. The key is case-insensitive. .PP \fBParameters:\fP .RS 4 \fIp\fP Allocates the returned array. .br \fIt\fP the parameter table returned by \fBapreq_args()\fP, \fBapreq_body()\fP or \fBapreq_params()\fP .br \fIkey\fP Null-terminated search key, case insensitive. key==NULL fetches all parameters. .RE .PP \fBReturns:\fP .RS 4 an array of apreq_param_t* (pointers) .RE .PP \fBRemarks:\fP .RS 4 Also parses the request if necessary. .RE .PP .SS "const char* apreq_params_as_string (\fBapr_pool_t\fP * p, const \fBapr_table_t\fP * t, const char * key, \fBapreq_join_t\fP mode)" .PP Returns a ', ' -joined string containing all parameters for the requested key, an empty string if none are found. The key is case-insensitive. .PP \fBParameters:\fP .RS 4 \fIp\fP Allocates the return string. .br \fIt\fP the parameter table returned by \fBapreq_args()\fP, \fBapreq_body()\fP or \fBapreq_params()\fP .br \fIkey\fP Null-terminated parameter name, case insensitive. key==NULL fetches all values. .br \fImode\fP Join type- see \fBapreq_join()\fP. .RE .PP \fBReturns:\fP .RS 4 the joined string or NULL on error .RE .PP \fBRemarks:\fP .RS 4 Also parses the request if necessary. .RE .PP .SS "\fBapr_status_t\fP apreq_parse_query_string (\fBapr_pool_t\fP * pool, \fBapr_table_t\fP * t, const char * qs)" .PP Parse a url-encoded string into a param table. .PP \fBParameters:\fP .RS 4 \fIpool\fP pool used to allocate the param data. .br \fIt\fP table to which the params are added. .br \fIqs\fP Query string to url-decode. .RE .PP \fBReturns:\fP .RS 4 APR_SUCCESS if successful, error otherwise. .RE .PP \fBRemarks:\fP .RS 4 This function uses [&;] as the set of tokens to delineate words, and will treat a word w/o '=' as a name-value pair with value-length = 0. .RE .PP .SS "const \fBapreq_param_t\fP* apreq_upload (const \fBapr_table_t\fP * body, const char * name)" .PP Returns the first param in req->body which has both param->v.name matching key (case insensitive) and param->upload != NULL. .PP \fBParameters:\fP .RS 4 \fIbody\fP parameter table returned by \fBapreq_body()\fP or \fBapreq_params()\fP .br \fIname\fP Parameter name. key == NULL returns first upload. .RE .PP \fBReturns:\fP .RS 4 Corresponding upload, NULL if none found. .RE .PP \fBRemarks:\fP .RS 4 Will parse the request as necessary. .RE .PP .SS "const \fBapr_table_t\fP* apreq_uploads (const \fBapr_table_t\fP * body, \fBapr_pool_t\fP * pool)" .PP Returns a table of all params in req->body with non-NULL upload brigades. .PP \fBParameters:\fP .RS 4 \fIbody\fP parameter table returned by \fBapreq_body()\fP or \fBapreq_params()\fP .br \fIpool\fP Pool which allocates the table struct. .RE .PP \fBReturns:\fP .RS 4 Upload table. .RE .PP \fBRemarks:\fP .RS 4 Will parse the request if necessary. .RE .PP .SS "static \fBAPR_INLINE\fP \fBapreq_param_t\fP* apreq_value_to_param (const char * val)\fC [static]\fP" .PP Upgrades args and body table values to \fBapreq_param_t\fP structs. .SH "Author" .PP Generated automatically by Doxygen for libapreq2 from the source code. rapache-1.2.8/libapreq2/docs/man/man3/apreq_param_t.30000644000175100017510000000173312706745114021607 0ustar ondrejondrej.TH "apreq_param_t" 3 "4 May 2005" "Version 2.05-dev" "libapreq2" \" -*- nroff -*- .ad l .nh .SH NAME apreq_param_t \- .SH SYNOPSIS .br .PP \fC#include \fP .PP .SS "Data Fields" .in +1c .ti -1c .RI "\fBapr_table_t\fP * \fBinfo\fP" .br .ti -1c .RI "\fBapr_bucket_brigade\fP * \fBupload\fP" .br .ti -1c .RI "unsigned \fBflags\fP" .br .ti -1c .RI "const \fBapreq_value_t\fP \fBv\fP" .br .in -1c .SH "Detailed Description" .PP Common data structure for params and file uploads .PP .SH "Field Documentation" .PP .SS "unsigned \fBapreq_param_t::flags\fP" .PP charsets, taint marks, app-specific bits .SS "\fBapr_table_t\fP* \fBapreq_param_t::info\fP" .PP header table associated with the param .SS "\fBapr_bucket_brigade\fP* \fBapreq_param_t::upload\fP" .PP brigade used to spool upload files .SS "const \fBapreq_value_t\fP \fBapreq_param_t::v\fP" .PP underlying name/value info .SH "Author" .PP Generated automatically by Doxygen for libapreq2 from the source code. rapache-1.2.8/libapreq2/docs/man/man3/apreq_parser.h.30000644000175100017510000002277012706745114021712 0ustar ondrejondrej.TH "include/apreq_parser.h" 3 "4 May 2005" "Version 2.05-dev" "libapreq2" \" -*- nroff -*- .ad l .nh .SH NAME include/apreq_parser.h \- Request body parser API. .SH SYNOPSIS .br .PP \fC#include 'apreq_param.h'\fP .br .SS "Defines" .in +1c .ti -1c .RI "#define \fBAPREQ_PARSER_ARGS\fP" .br .ti -1c .RI "#define \fBAPREQ_HOOK_ARGS\fP" .br .ti -1c .RI "#define \fBAPREQ_DECLARE_PARSER\fP(f)" .br .ti -1c .RI "#define \fBAPREQ_DECLARE_HOOK\fP(f)" .br .in -1c .SS "Typedefs" .in +1c .ti -1c .RI "typedef \fBapreq_hook_t\fP \fBapreq_hook_t\fP" .br .ti -1c .RI "typedef \fBapreq_parser_t\fP \fBapreq_parser_t\fP" .br .ti -1c .RI "typedef \fBapr_status_t\fP(* \fBapreq_parser_function_t\fP )(APREQ_PARSER_ARGS)" .br .ti -1c .RI "typedef \fBapr_status_t\fP(* \fBapreq_hook_function_t\fP )(APREQ_HOOK_ARGS)" .br .in -1c .SS "Functions" .in +1c .ti -1c .RI "static \fBAPR_INLINE\fP \fBapr_status_t\fP \fBapreq_parser_run\fP (struct \fBapreq_parser_t\fP *psr, \fBapr_table_t\fP *t, \fBapr_bucket_brigade\fP *bb)" .br .ti -1c .RI "static \fBAPR_INLINE\fP \fBapr_status_t\fP \fBapreq_hook_run\fP (struct \fBapreq_hook_t\fP *h, \fBapreq_param_t\fP *param, \fBapr_bucket_brigade\fP *bb)" .br .ti -1c .RI "\fBAPREQ_DECLARE_PARSER\fP (apreq_parse_headers)" .br .ti -1c .RI "\fBAPREQ_DECLARE_PARSER\fP (apreq_parse_urlencoded)" .br .ti -1c .RI "\fBAPREQ_DECLARE_PARSER\fP (apreq_parse_multipart)" .br .ti -1c .RI "\fBAPREQ_DECLARE_PARSER\fP (apreq_parse_generic)" .br .ti -1c .RI "\fBAPREQ_DECLARE_HOOK\fP (apreq_hook_apr_xml_parser)" .br .ti -1c .RI "\fBapreq_parser_t\fP * \fBapreq_parser_make\fP (\fBapr_pool_t\fP *pool, \fBapr_bucket_alloc_t\fP *ba, const char *content_type, \fBapreq_parser_function_t\fP pfn, \fBapr_size_t\fP brigade_limit, const char *temp_dir, \fBapreq_hook_t\fP *hook, void *ctx)" .br .ti -1c .RI "\fBapreq_hook_t\fP * \fBapreq_hook_make\fP (\fBapr_pool_t\fP *pool, \fBapreq_hook_function_t\fP hook, \fBapreq_hook_t\fP *next, void *ctx)" .br .ti -1c .RI "\fBapr_status_t\fP \fBapreq_parser_add_hook\fP (\fBapreq_parser_t\fP *p, \fBapreq_hook_t\fP *h)" .br .ti -1c .RI "\fBapreq_parser_function_t\fP \fBapreq_parser\fP (const char *enctype)" .br .ti -1c .RI "\fBapr_status_t\fP \fBapreq_register_parser\fP (const char *enctype, \fBapreq_parser_function_t\fP pfn)" .br .ti -1c .RI "\fBAPREQ_DECLARE_HOOK\fP (apreq_hook_disable_uploads)" .br .ti -1c .RI "\fBAPREQ_DECLARE_HOOK\fP (apreq_hook_discard_brigade)" .br .ti -1c .RI "\fBAPREQ_DECLARE_HOOK\fP (apreq_hook_find_param)" .br .in -1c .SH "Detailed Description" .PP Request body parser API. .SH "Define Documentation" .PP .SS "#define APREQ_DECLARE_HOOK(f)" .PP \fBValue:\fP .PP .nf APREQ_DECLARE_NONSTD(apr_status_t) \ (f) (APREQ_HOOK_ARGS) .fi Declares an API hook. .SS "#define APREQ_DECLARE_PARSER(f)" .PP \fBValue:\fP .PP .nf APREQ_DECLARE_NONSTD(apr_status_t) \ (f) (APREQ_PARSER_ARGS) .fi Declares a API parser. .SS "#define APREQ_HOOK_ARGS" .PP \fBValue:\fP .PP .nf apreq_hook_t *hook, \ apreq_param_t *param, \ apr_bucket_brigade *bb .fi Hook arguments .SS "#define APREQ_PARSER_ARGS" .PP \fBValue:\fP .PP .nf apreq_parser_t *parser, \ apr_table_t *t, \ apr_bucket_brigade *bb .fi Parser arguments. .SH "Typedef Documentation" .PP .SS "typedef \fBapr_status_t\fP(* \fBapreq_hook_function_t\fP)(APREQ_HOOK_ARGS)" .PP The callback function of a hook. See \fBapreq_hook_t\fP. .SS "typedef struct \fBapreq_hook_t\fP \fBapreq_hook_t\fP" .PP A hook is called by the parser whenever data arrives in a file upload parameter of the request body. You may associate any number of hooks with a parser instance with \fBapreq_parser_add_hook()\fP. .SS "typedef \fBapr_status_t\fP(* \fBapreq_parser_function_t\fP)(APREQ_PARSER_ARGS)" .PP The callback function implementing a request body parser. .SS "typedef struct \fBapreq_parser_t\fP \fBapreq_parser_t\fP" .PP A request body parser instance. .SH "Function Documentation" .PP .SS "APREQ_DECLARE_HOOK (apreq_hook_find_param)" .PP Special purpose utility for locating a parameter during parsing. The hook's ctx shoud be initialized to a const char *, which is a pointer to the desired param name. The hook's ctx will be reassigned to the first param found. .PP \fBRemarks:\fP .RS 4 When used, this should always be the first hook invoked, so add it manually as parser->hook instead of using apreq_parser_add_hook. .RE .PP .SS "APREQ_DECLARE_HOOK (apreq_hook_discard_brigade)" .PP Calls apr_brigade_cleanup on the incoming brigade after passing the brigade to any subsequent hooks. .SS "APREQ_DECLARE_HOOK (apreq_hook_disable_uploads)" .PP Returns APREQ_ERROR_GENERAL. Effectively disables mfd parser if a file-upload field is present. .SS "APREQ_DECLARE_HOOK (apreq_hook_apr_xml_parser)" .PP apr_xml_parser hook. It will parse until EOS appears. The parsed document isn't available until parsing has completed successfully. The hook's ctx pointer may be cast as (\fBapr_xml_doc\fP **) to retrieve the parsed document. .SS "APREQ_DECLARE_PARSER (apreq_parse_generic)" .PP Generic parser. No table entries will be added to the req->body table by this parser. The parser creates a dummy \fBapreq_param_t\fP to pass to any configured hooks. If no hooks are configured, the dummy param's bb slot will contain a copy of the request body. It can be retrieved by casting the parser's ctx pointer to (\fBapreq_param_t\fP **). .SS "APREQ_DECLARE_PARSER (apreq_parse_multipart)" .PP RFC 2388 multipart/form-data (and XForms 1.0 multipart/related) parser. It will reject any buckets representing preamble and postamble text (this is normal behavior, not an error condition). See \fBapreq_parser_run()\fP for more info on rejected data. .SS "APREQ_DECLARE_PARSER (apreq_parse_urlencoded)" .PP RFC 2396 application/x-www-form-urlencoded parser. .SS "APREQ_DECLARE_PARSER (apreq_parse_headers)" .PP RFC 822 Header parser. It will reject all data after the first CRLF CRLF sequence (an empty line). See \fBapreq_parser_run()\fP for more info on rejected data. .SS "\fBapreq_hook_t\fP* apreq_hook_make (\fBapr_pool_t\fP * pool, \fBapreq_hook_function_t\fP hook, \fBapreq_hook_t\fP * next, void * ctx)" .PP Construct a hook. .PP \fBParameters:\fP .RS 4 \fIpool\fP used to allocate the hook. .br \fIhook\fP The hook function. .br \fInext\fP List of other hooks for this hook to call on. .br \fIctx\fP Hook's internal scratch pad. .RE .PP \fBReturns:\fP .RS 4 New hook. .RE .PP .SS "static \fBAPR_INLINE\fP \fBapr_status_t\fP apreq_hook_run (struct \fBapreq_hook_t\fP * h, \fBapreq_param_t\fP * param, \fBapr_bucket_brigade\fP * bb)\fC [static]\fP" .PP Run the hook with the current parameter and the incoming bucket brigade. The hook may modify the brigade if necessary. Once all hooks have completed, the contents of the brigade will be added to the parameter's bb attribute. .PP \fBReturns:\fP .RS 4 APR_SUCCESS on success. All other values represent errors. .RE .PP .SS "\fBapreq_parser_function_t\fP apreq_parser (const char * enctype)" .PP Fetch the default parser function associated with the given MIME type. .PP \fBParameters:\fP .RS 4 \fIenctype\fP The desired enctype (can also be a full 'Content-Type' header). .RE .PP \fBReturns:\fP .RS 4 The parser function, or NULL if the enctype is unrecognized. .RE .PP .SS "\fBapr_status_t\fP apreq_parser_add_hook (\fBapreq_parser_t\fP * p, \fBapreq_hook_t\fP * h)" .PP Add a new hook to the end of the parser's hook list. .PP \fBParameters:\fP .RS 4 \fIp\fP Parser. .br \fIh\fP Hook to append. .RE .PP .SS "\fBapreq_parser_t\fP* apreq_parser_make (\fBapr_pool_t\fP * pool, \fBapr_bucket_alloc_t\fP * ba, const char * content_type, \fBapreq_parser_function_t\fP pfn, \fBapr_size_t\fP brigade_limit, const char * temp_dir, \fBapreq_hook_t\fP * hook, void * ctx)" .PP Construct a parser. .PP \fBParameters:\fP .RS 4 \fIpool\fP Pool used to allocate the parser. .br \fIba\fP bucket allocator used to create bucket brigades .br \fIcontent_type\fP Content-type that this parser can deal with. .br \fIpfn\fP The parser function. .br \fIbrigade_limit\fP the maximum in-memory bytes a brigade may use .br \fItemp_dir\fP the directory used by the parser for temporary files .br \fIhook\fP Hooks to asssociate this parser with. .br \fIctx\fP Parser's internal scratch pad. .RE .PP \fBReturns:\fP .RS 4 New parser. .RE .PP .SS "static \fBAPR_INLINE\fP \fBapr_status_t\fP apreq_parser_run (struct \fBapreq_parser_t\fP * psr, \fBapr_table_t\fP * t, \fBapr_bucket_brigade\fP * bb)\fC [static]\fP" .PP Parse the incoming brigade into a table. Parsers normally consume all the buckets of the brigade during parsing. However parsers may leave 'rejected' data in the brigade, even during a successful parse, so callers may need to clean up the brigade themselves (in particular, rejected buckets should not be passed back to the parser again). .PP \fBRemarks:\fP .RS 4 bb == NULL is valid: the parser should return its public status: APR_INCOMPLETE, APR_SUCCESS, or an error code. .RE .PP .SS "\fBapr_status_t\fP apreq_register_parser (const char * enctype, \fBapreq_parser_function_t\fP pfn)" .PP Register a new parsing function with a MIME enctype. Registered parsers are added to \fBapreq_parser()\fP's internal lookup table. .PP \fBParameters:\fP .RS 4 \fIenctype\fP The MIME type. .br \fIpfn\fP The function to use during parsing. Setting parser == NULL will remove an existing parser. .RE .PP \fBReturns:\fP .RS 4 APR_SUCCESS or error. .RE .PP .SH "Author" .PP Generated automatically by Doxygen for libapreq2 from the source code. rapache-1.2.8/libapreq2/docs/man/man3/apreq_parser_t.30000644000175100017510000000311512706745114021777 0ustar ondrejondrej.TH "apreq_parser_t" 3 "4 May 2005" "Version 2.05-dev" "libapreq2" \" -*- nroff -*- .ad l .nh .SH NAME apreq_parser_t \- .SH SYNOPSIS .br .PP \fC#include \fP .PP .SS "Data Fields" .in +1c .ti -1c .RI "\fBapreq_parser_function_t\fP \fBparser\fP" .br .ti -1c .RI "const char * \fBcontent_type\fP" .br .ti -1c .RI "\fBapr_pool_t\fP * \fBpool\fP" .br .ti -1c .RI "\fBapr_bucket_alloc_t\fP * \fBbucket_alloc\fP" .br .ti -1c .RI "\fBapr_size_t\fP \fBbrigade_limit\fP" .br .ti -1c .RI "const char * \fBtemp_dir\fP" .br .ti -1c .RI "\fBapreq_hook_t\fP * \fBhook\fP" .br .ti -1c .RI "void * \fBctx\fP" .br .in -1c .SH "Detailed Description" .PP A request body parser instance. .PP .SH "Field Documentation" .PP .SS "\fBapr_size_t\fP \fBapreq_parser_t::brigade_limit\fP" .PP the maximum in-memory bytes a brigade may use .SS "\fBapr_bucket_alloc_t\fP* \fBapreq_parser_t::bucket_alloc\fP" .PP bucket allocator used to create bucket brigades .SS "const char* \fBapreq_parser_t::content_type\fP" .PP the Content-Type request header .SS "void* \fBapreq_parser_t::ctx\fP" .PP internal context pointer used by the parser function .SS "\fBapreq_hook_t\fP* \fBapreq_parser_t::hook\fP" .PP linked list of hooks .SS "\fBapreq_parser_function_t\fP \fBapreq_parser_t::parser\fP" .PP the function which parses chunks of body data .SS "\fBapr_pool_t\fP* \fBapreq_parser_t::pool\fP" .PP a pool used by the parser .SS "const char* \fBapreq_parser_t::temp_dir\fP" .PP the directory used by the parser for temporary files .SH "Author" .PP Generated automatically by Doxygen for libapreq2 from the source code. rapache-1.2.8/libapreq2/docs/man/man3/apreq_status.30000644000175100017510000001074712706745114021514 0ustar ondrejondrej.TH "apreq_status" 3 "4 May 2005" "Version 2.05-dev" "libapreq2" \" -*- nroff -*- .ad l .nh .SH NAME apreq_status \- STATUS 2.05-dev released on May 5, 2005. .PP Contributors looking for a mission: .PP .IP "\(bu" 2 just do an egrep on 'TODO' or 'XXX' and see what's there .PP .PP CURRENT RELEASE NOTES: .PP .IP "\(bu" 2 This is a developer release, indicated by the '-dev' suffix on the version string. We believe the core interfaces to be stable, but some portions of the API may still need significant modification. Thus, binary/source compatibility may be broken from one developer release to the next. In particular the version numbering rules specified at .PP .PP http://apr.apache.org/versioning.html .PP do not apply to developer releases. .PP RELEASE SHOWSTOPPERS: .PP .IP "\(bu" 2 The api docs are currently incorrect. .PP .PP CURRENT VOTES: .PP .IP "\(bu" 2 Should we switch to EU::MM for determining the full path to perl? The problem is that some folks move their perl binary post-installation, but never adjust Config.pm. EU::MM is smart, by accepting a full path in $^X or by searching the user's $PATH for $^X, before resorting to Config.pm. However, if we change apreq2, we should also lobby test-dev to adopt the same solution for Apache::Test. Otherwise our test suite will likely fail, even though the rest of the perl build system will presumably still work. .PP .PP +1: joes 0: -1: .PP TODO: .PP .IP "\(bu" 2 Dump automake, preferably replacing that with more stuff from httpd/apr's build system. .PP .PP .IP "\(bu" 2 Introduce APR::Request::Parser and APR::Request::Hook. Implement Apache2::Request::new's UPLOAD_HOOK using them. .PP .PP .IP "\(bu" 2 Move module/t to module/apache2/t. .PP .PP .IP "\(bu" 2 Figure out how and where the apreq_xs_ headers, and typemap file, should be installed. .PP .PP .IP "\(bu" 2 Write tests for the apache 1.3.x module. .PP .PP .IP "\(bu" 2 Fix the broken make dependencies, especially in the module and glue subdirs. The libtool workaround (for OSX IIRC) that copies module/.libs to module/t is especially bogus. .PP .PP .IP "\(bu" 2 Drop ExtUtils::XSBuilder as the C API is fairly stable now. The header parsing + xs generation stuff may be too difficult for the community to maintain over ordinary .xs files. .PP .PP .IP "\(bu" 2 Round out the unit tests in library/t. Ideally each API function should have its own tests, and each possible error status should be both tested & documented. Also upgrade these tests to use the Apache::Test framework. .PP .PP .IP "\(bu" 2 Add a 'memory_limit' setting to \fBapreq_parser_t\fP and \fBapreq_module_t\fP, which will control how much pool allocation the parser may use. .PP .PP .IP "\(bu" 2 Add a 'header_limit' setting to control outgoing header size (mainly for baking cookies) instead of using a compiled-in limit. .PP .PP .IP "\(bu" 2 in glue/perl/t/apreq/cgi.t on Win32, printing to the error log hangs if the strings involved are about 10000 in size. This doesn't occur in the env/cgi tests - why? .PP .PP .IP "\(bu" 2 Why must fprintf(stderr, ...), rather than apr_file_printf(err, ...), be used on Win32 in cgi_log() of src/apreq_env.c? .PP .PP .IP "\(bu" 2 Get env/ (Apache::Test) tests to work for --with-apache2-src option. Also add a test to configure that prevents simultaneous use of --with-apache2-src and --with-apache2-apxs. .PP .PP .IP "\(bu" 2 symbol exports files: .IP " 1." 6 aix needs .exp files .PP .PP .PP .IP "\(bu" 2 Install the html dox during 'make install'. Should we do this for the doxy manpages also? .PP .PP .IP "\(bu" 2 Rework glue/perl build system to use apreq2-config instead of relying on paths like '../../src'. .PP .PP OPEN ISSUES: .PP .IP "\(bu" 2 Should we bundle an apr-based 'application/xml' parser? If so, how should we parse the xml data into an apr_table? .PP .PP .IP "\(bu" 2 Determine whether or not it's good for the perl glue to ever set the SvUTF8 flag on a param. The current code ties this action to the apreq_param_is_tainted flag. .PP .PP .IP "\(bu" 2 Should we let hooks interrupt parsers via APREQ_ERROR_INTERRUPT? That'd need a delete_hook method to make interrupts a useful way of tuning parser behavior. .PP .PP BUGS: .PP .IP "\(bu" 2 Fix build automake/libtool/autoconf build system so it works properly on OSX & AIX. .PP .PP WISH LIST: .PP .IP "\(bu" 2 I [joes] wish folks would contribute some glue code for one of these: .PP .PP .IP "\(bu" 2 php, .IP "\(bu" 2 Rivet, .IP "\(bu" 2 mod_dtcl, .IP "\(bu" 2 mod_python, .IP "\(bu" 2 mod_jk, .IP "\(bu" 2 tomcat, .IP "\(bu" 2 mod_ruby, .IP "\(bu" 2 mod_parrot. .PP rapache-1.2.8/libapreq2/docs/man/man3/apreq_util.h.30000644000175100017510000003444212706745114021372 0ustar ondrejondrej.TH "include/apreq_util.h" 3 "4 May 2005" "Version 2.05-dev" "libapreq2" \" -*- nroff -*- .ad l .nh .SH NAME include/apreq_util.h \- Utility functions for apreq. .SH SYNOPSIS .br .PP \fC#include 'apr_file_io.h'\fP .br \fC#include 'apr_buckets.h'\fP .br \fC#include 'apreq.h'\fP .br .SS "Functions" .in +1c .ti -1c .RI "char * \fBapreq_join\fP (\fBapr_pool_t\fP *p, const char *sep, const \fBapr_array_header_t\fP *arr, \fBapreq_join_t\fP mode)" .br .ti -1c .RI "\fBapr_ssize_t\fP \fBapreq_index\fP (const char *hay, \fBapr_size_t\fP hlen, const char *ndl, \fBapr_size_t\fP nlen, const \fBapreq_match_t\fP type)" .br .ti -1c .RI "\fBapr_size_t\fP \fBapreq_quote\fP (char *dest, const char *src, const \fBapr_size_t\fP slen)" .br .ti -1c .RI "\fBapr_size_t\fP \fBapreq_quote_once\fP (char *dest, const char *src, const \fBapr_size_t\fP slen)" .br .ti -1c .RI "\fBapr_size_t\fP \fBapreq_encode\fP (char *dest, const char *src, const \fBapr_size_t\fP slen)" .br .ti -1c .RI "\fBapr_size_t\fP \fBapreq_cp1252_to_utf8\fP (char *dest, const char *src, \fBapr_size_t\fP slen)" .br .ti -1c .RI "\fBapr_status_t\fP \fBapreq_decode\fP (char *dest, \fBapr_size_t\fP *dlen, const char *src, \fBapr_size_t\fP slen)" .br .ti -1c .RI "\fBapr_status_t\fP \fBapreq_decodev\fP (char *dest, \fBapr_size_t\fP *dlen, struct iovec *v, int nelts)" .br .ti -1c .RI "static \fBAPR_INLINE\fP char * \fBapreq_escape\fP (\fBapr_pool_t\fP *p, const char *src, const \fBapr_size_t\fP slen)" .br .ti -1c .RI "static \fBAPR_INLINE\fP \fBapr_ssize_t\fP \fBapreq_unescape\fP (char *str)" .br .ti -1c .RI "\fBapr_int64_t\fP \fBapreq_atoi64f\fP (const char *s)" .br .ti -1c .RI "\fBapr_int64_t\fP \fBapreq_atoi64t\fP (const char *s)" .br .ti -1c .RI "\fBapr_status_t\fP \fBapreq_brigade_fwrite\fP (\fBapr_file_t\fP *f, \fBapr_off_t\fP *wlen, \fBapr_bucket_brigade\fP *bb)" .br .ti -1c .RI "\fBapr_status_t\fP \fBapreq_file_mktemp\fP (\fBapr_file_t\fP **fp, \fBapr_pool_t\fP *pool, const char *path)" .br .ti -1c .RI "static \fBAPR_INLINE\fP \fBapr_status_t\fP \fBapreq_brigade_setaside\fP (\fBapr_bucket_brigade\fP *bb, \fBapr_pool_t\fP *p)" .br .ti -1c .RI "static \fBAPR_INLINE\fP \fBapr_status_t\fP \fBapreq_brigade_copy\fP (\fBapr_bucket_brigade\fP *d, \fBapr_bucket_brigade\fP *s)" .br .ti -1c .RI "static \fBAPR_INLINE\fP void \fBapreq_brigade_move\fP (\fBapr_bucket_brigade\fP *d, \fBapr_bucket_brigade\fP *s, \fBapr_bucket\fP *e)" .br .ti -1c .RI "\fBapr_status_t\fP \fBapreq_header_attribute\fP (const char *hdr, const char *name, const \fBapr_size_t\fP nlen, const char **val, \fBapr_size_t\fP *vlen)" .br .ti -1c .RI "\fBapr_status_t\fP \fBapreq_brigade_concat\fP (\fBapr_pool_t\fP *pool, const char *temp_dir, \fBapr_size_t\fP brigade_limit, \fBapr_bucket_brigade\fP *out, \fBapr_bucket_brigade\fP *in)" .br .ti -1c .RI "\fBapr_file_t\fP * \fBapreq_brigade_spoolfile\fP (\fBapr_bucket_brigade\fP *bb)" .br .in -1c .SH "Detailed Description" .PP Utility functions for apreq. This header contains useful functions for creating new parsers, hooks or modules. It includes .PP .IP "\(bu" 2 string <-> array converters .IP "\(bu" 2 substring search functions .IP "\(bu" 2 simple encoders & decoders for urlencoded strings .IP "\(bu" 2 simple time, date, & file-size converters .PP .SH "Function Documentation" .PP .SS "\fBapr_int64_t\fP apreq_atoi64f (const char * s)" .PP Converts file sizes (KMG) to bytes .PP \fBParameters:\fP .RS 4 \fIs\fP file size matching m/^\\d+[KMG]b?$/i .RE .PP \fBReturns:\fP .RS 4 64-bit integer representation of s. .RE .PP \fBTodo\fP .RS 4 What happens when s is malformed? Should this return an unsigned value instead? .RE .PP .SS "\fBapr_int64_t\fP apreq_atoi64t (const char * s)" .PP Converts time strings (YMDhms) to seconds .PP \fBParameters:\fP .RS 4 \fIs\fP time string matching m/^\\+?\\d+[YMDhms]$/ .RE .PP \fBReturns:\fP .RS 4 64-bit integer representation of s as seconds. .RE .PP \fBTodo\fP .RS 4 What happens when s is malformed? Should this return an unsigned value instead? .RE .PP .SS "\fBapr_status_t\fP apreq_brigade_concat (\fBapr_pool_t\fP * pool, const char * temp_dir, \fBapr_size_t\fP brigade_limit, \fBapr_bucket_brigade\fP * out, \fBapr_bucket_brigade\fP * in)" .PP Concatenates the brigades, spooling large brigades into a tempfile (APREQ_SPOOL) bucket. .PP \fBParameters:\fP .RS 4 \fIpool\fP Pool for creating a tempfile bucket. .br \fItemp_dir\fP Directory for tempfile creation. .br \fIbrigade_limit\fP If out's length would exceed this value, the appended buckets get written to a tempfile. .br \fIout\fP Resulting brigade. .br \fIin\fP Brigade to append. .RE .PP \fBReturns:\fP .RS 4 APR_SUCCESS. .PP Error status code resulting from either \fBapr_brigade_length()\fP, \fBapreq_file_mktemp()\fP, \fBapreq_brigade_fwrite()\fP, or \fBapr_file_seek()\fP. .RE .PP \fBTodo\fP .RS 4 Flesh out these error codes, making them as explicit as possible. .RE .PP .SS "static \fBAPR_INLINE\fP \fBapr_status_t\fP apreq_brigade_copy (\fBapr_bucket_brigade\fP * d, \fBapr_bucket_brigade\fP * s)\fC [static]\fP" .PP Copy a brigade. .PP \fBParameters:\fP .RS 4 \fId\fP (destination) Copied buckets are appended to this brigade. .br \fIs\fP (source) Brigade to copy from. .RE .PP \fBReturns:\fP .RS 4 APR_SUCCESS. .PP Error status code from an unsuccessful \fBapr_bucket_copy()\fP. .RE .PP \fBRemarks:\fP .RS 4 s == d produces Undefined Behavior. .RE .PP .SS "\fBapr_status_t\fP apreq_brigade_fwrite (\fBapr_file_t\fP * f, \fBapr_off_t\fP * wlen, \fBapr_bucket_brigade\fP * bb)" .PP Writes brigade to a file. .PP \fBParameters:\fP .RS 4 \fIf\fP File that gets the brigade. .br \fIwlen\fP On a successful return, wlen holds the length of the brigade, which is the amount of data written to the file. .br \fIbb\fP Bucket brigade. .RE .PP \fBReturns:\fP .RS 4 APR_SUCCESS. .PP Error status code from either an unsuccessful \fBapr_bucket_read()\fP, or a failed \fBapr_file_writev()\fP. .RE .PP \fBRemarks:\fP .RS 4 In the future, this function may do something intelligent with file buckets. .RE .PP .SS "static \fBAPR_INLINE\fP void apreq_brigade_move (\fBapr_bucket_brigade\fP * d, \fBapr_bucket_brigade\fP * s, \fBapr_bucket\fP * e)\fC [static]\fP" .PP Move the front of a brigade. .PP \fBParameters:\fP .RS 4 \fId\fP (destination) Append buckets to this brigade. .br \fIs\fP (source) Brigade to take buckets from. .br \fIe\fP First bucket of s after the move. All buckets before e are appended to d. .RE .PP \fBRemarks:\fP .RS 4 This moves all buckets when e == \fBAPR_BRIGADE_SENTINEL(s)\fP. .RE .PP .SS "static \fBAPR_INLINE\fP \fBapr_status_t\fP apreq_brigade_setaside (\fBapr_bucket_brigade\fP * bb, \fBapr_pool_t\fP * p)\fC [static]\fP" .PP Set aside all buckets in the brigade. .PP \fBParameters:\fP .RS 4 \fIbb\fP Brigade. .br \fIp\fP Setaside buckets into this pool. .RE .PP \fBReturns:\fP .RS 4 APR_SUCCESS. .PP Error status code from an unsuccessful \fBapr_bucket_setaside()\fP. .RE .PP .SS "\fBapr_file_t\fP* apreq_brigade_spoolfile (\fBapr_bucket_brigade\fP * bb)" .PP Determines the spool file used by the brigade. Returns NULL if the brigade is not spooled in a file (does not use an APREQ_SPOOL bucket). .PP \fBParameters:\fP .RS 4 \fIbb\fP the bucket brigade .RE .PP \fBReturns:\fP .RS 4 the spool file, or NULL. .RE .PP .SS "\fBapr_size_t\fP apreq_cp1252_to_utf8 (char * dest, const char * src, \fBapr_size_t\fP slen)" .PP Convert a string from cp1252 to utf8. Caller must ensure it is large enough to hold the encoded string and trailing '\\0'. .PP \fBParameters:\fP .RS 4 \fIdest\fP Location of utf8-encoded result string. Caller must ensure it is large enough to hold the encoded string and trailing '\\0'. .br \fIsrc\fP Original string. .br \fIslen\fP Length of original string. .RE .PP \fBReturns:\fP .RS 4 length of utf8-encoded string in dest; does not exceed 3 * slen. .RE .PP .SS "\fBapr_status_t\fP apreq_decode (char * dest, \fBapr_size_t\fP * dlen, const char * src, \fBapr_size_t\fP slen)" .PP Url-decodes a string. .PP \fBParameters:\fP .RS 4 \fIdest\fP Location of url-encoded result string. Caller must ensure dest is large enough to hold the encoded string and trailing null character. .br \fIdlen\fP points to resultant length of url-decoded string in dest .br \fIsrc\fP Original string. .br \fIslen\fP Length of original string. .RE .PP \fBReturns:\fP .RS 4 APR_SUCCESS + apreq_charset_t (<=APREQ_CHARSET_UTF8) on success. .PP APR_INCOMPLETE + apreq_charset_t (<=APREQ_CHARSET_UTF8) if the string ends in the middle of an escape sequence. .PP \fBAPREQ_ERROR_BADSEQ\fP or \fBAPREQ_ERROR_BADCHAR\fP on malformed input. .RE .PP \fBRemarks:\fP .RS 4 In the non-success case, dlen will be set to include the last succesfully decoded value. This function decodes %uXXXX into a utf8 (wide) character, following ECMA-262 (the Javascript spec) Section B.2.1. .RE .PP .SS "\fBapr_status_t\fP apreq_decodev (char * dest, \fBapr_size_t\fP * dlen, struct iovec * v, int nelts)" .PP Url-decodes an iovec array. .PP \fBParameters:\fP .RS 4 \fIdest\fP Location of url-encoded result string. Caller must ensure dest is large enough to hold the encoded string and trailing null character. .br \fIdlen\fP Resultant length of dest. .br \fIv\fP Array of iovecs that represent the source string .br \fInelts\fP Number of iovecs in the array. .RE .PP \fBReturns:\fP .RS 4 APR_SUCCESS + apreq_charset_t (<=APREQ_CHARSET_UTF8) on success. .PP APR_INCOMPLETE + apreq_charset_t (<=APREQ_CHARSET_UTF8) if the iovec ends in the middle of an escape sequence. .PP \fBAPREQ_ERROR_BADSEQ\fP or \fBAPREQ_ERROR_BADCHAR\fP on malformed input. .RE .PP \fBRemarks:\fP .RS 4 In the non-APR_SUCCESS case, dlen will be set to include the last succesfully decoded value. This function decodes %uXXXX into a utf8 (wide) character, following ECMA-262 (the Javascript spec) Section B.2.1. .RE .PP .SS "\fBapr_size_t\fP apreq_encode (char * dest, const char * src, const \fBapr_size_t\fP slen)" .PP Url-encodes a string. .PP \fBParameters:\fP .RS 4 \fIdest\fP Location of url-encoded result string. Caller must ensure it is large enough to hold the encoded string and trailing '\\0'. .br \fIsrc\fP Original string. .br \fIslen\fP Length of original string. .RE .PP \fBReturns:\fP .RS 4 length of url-encoded string in dest; does not exceed 3 * slen. .RE .PP .SS "static \fBAPR_INLINE\fP char* apreq_escape (\fBapr_pool_t\fP * p, const char * src, const \fBapr_size_t\fP slen)\fC [static]\fP" .PP Returns an url-encoded copy of a string. .PP \fBParameters:\fP .RS 4 \fIp\fP Pool used to allocate the return value. .br \fIsrc\fP Original string. .br \fIslen\fP Length of original string. .RE .PP \fBReturns:\fP .RS 4 The url-encoded string. .RE .PP \fBRemarks:\fP .RS 4 Use this function insead of apreq_encode if its caller might otherwise overflow dest. .RE .PP .SS "\fBapr_status_t\fP apreq_file_mktemp (\fBapr_file_t\fP ** fp, \fBapr_pool_t\fP * pool, const char * path)" .PP Makes a temporary file. .PP \fBParameters:\fP .RS 4 \fIfp\fP Points to the temporary apr_file_t on success. .br \fIpool\fP Pool to associate with the temp file. When the pool is destroyed, the temp file will be closed and deleted. .br \fIpath\fP The base directory which will contain the temp file. If param == NULL, the directory will be selected via tempnam(). See the tempnam manpage for details. .RE .PP \fBReturns:\fP .RS 4 APR_SUCCESS. .PP Error status code from unsuccessful \fBapr_filepath_merge()\fP, or a failed \fBapr_file_mktemp()\fP. .RE .PP .SS "\fBapr_status_t\fP apreq_header_attribute (const char * hdr, const char * name, const \fBapr_size_t\fP nlen, const char ** val, \fBapr_size_t\fP * vlen)" .PP Search a header string for the value of a particular named attribute. .PP \fBParameters:\fP .RS 4 \fIhdr\fP Header string to scan. .br \fIname\fP Name of attribute to search for. .br \fInlen\fP Length of name. .br \fIval\fP Location of (first) matching value. .br \fIvlen\fP Length of matching value. .RE .PP \fBReturns:\fP .RS 4 APR_SUCCESS. .PP \fBAPREQ_ERROR_NOATTR\fP if the attribute is not found. .PP \fBAPREQ_ERROR_BADSEQ\fP if an unpaired quote mark was detected. .RE .PP .SS "\fBapr_ssize_t\fP apreq_index (const char * hay, \fBapr_size_t\fP hlen, const char * ndl, \fBapr_size_t\fP nlen, const \fBapreq_match_t\fP type)" .PP Returns offset of match string's location, or -1 if no match is found. .PP \fBParameters:\fP .RS 4 \fIhay\fP Location of bytes to scan. .br \fIhlen\fP Number of bytes available for scanning. .br \fIndl\fP Search string .br \fInlen\fP Length of search string. .br \fItype\fP Match type. .RE .PP \fBReturns:\fP .RS 4 Offset of match string, or -1 if no match is found. .RE .PP .SS "char* apreq_join (\fBapr_pool_t\fP * p, const char * sep, const \fBapr_array_header_t\fP * arr, \fBapreq_join_t\fP mode)" .PP Join an array of values. The result is an empty string if there are no values. .PP \fBParameters:\fP .RS 4 \fIp\fP Pool to allocate return value. .br \fIsep\fP String that is inserted between the joined values. .br \fIarr\fP Array of \fBapreq_value_t\fP entries. .br \fImode\fP Join type- see apreq_join_t. .RE .PP \fBReturns:\fP .RS 4 Joined string, or NULL on error .RE .PP .SS "\fBapr_size_t\fP apreq_quote (char * dest, const char * src, const \fBapr_size_t\fP slen)" .PP Places a quoted copy of src into dest. Embedded quotes are escaped with a backslash ('\\'). .PP \fBParameters:\fP .RS 4 \fIdest\fP Location of quoted copy. Must be large enough to hold the copy and trailing null byte. .br \fIsrc\fP Original string. .br \fIslen\fP Length of original string. .br \fIdest\fP Destination string. .RE .PP \fBReturns:\fP .RS 4 length of quoted copy in dest. .RE .PP .SS "\fBapr_size_t\fP apreq_quote_once (char * dest, const char * src, const \fBapr_size_t\fP slen)" .PP Same as \fBapreq_quote()\fP except when src begins and ends in quote marks. In that case it assumes src is quoted correctly, and just copies src to dest. .PP \fBParameters:\fP .RS 4 \fIdest\fP Location of quoted copy. Must be large enough to hold the copy and trailing null byte. .br \fIsrc\fP Original string. .br \fIslen\fP Length of original string. .br \fIdest\fP Destination string. .RE .PP \fBReturns:\fP .RS 4 length of quoted copy in dest. .RE .PP .SS "static \fBAPR_INLINE\fP \fBapr_ssize_t\fP apreq_unescape (char * str)\fC [static]\fP" .PP An \fIin-situ\fP url-decoder. .PP \fBParameters:\fP .RS 4 \fIstr\fP The string to decode .RE .PP \fBReturns:\fP .RS 4 Length of decoded string, or < 0 on error. .RE .PP .SH "Author" .PP Generated automatically by Doxygen for libapreq2 from the source code. rapache-1.2.8/libapreq2/docs/man/man3/apreq_value_t.30000644000175100017510000000153312706745114021621 0ustar ondrejondrej.TH "apreq_value_t" 3 "4 May 2005" "Version 2.05-dev" "libapreq2" \" -*- nroff -*- .ad l .nh .SH NAME apreq_value_t \- libapreq's pre-extensible string type .PP .SH SYNOPSIS .br .PP \fC#include \fP .PP .SS "Data Fields" .in +1c .ti -1c .RI "char * \fBname\fP" .br .ti -1c .RI "\fBapr_size_t\fP \fBnlen\fP" .br .ti -1c .RI "\fBapr_size_t\fP \fBdlen\fP" .br .ti -1c .RI "char \fBdata\fP [1]" .br .in -1c .SH "Detailed Description" .PP libapreq's pre-extensible string type .PP .SH "Field Documentation" .PP .SS "char \fBapreq_value_t::data\fP[1]" .PP value data .SS "\fBapr_size_t\fP \fBapreq_value_t::dlen\fP" .PP length of data .SS "char* \fBapreq_value_t::name\fP" .PP value name .SS "\fBapr_size_t\fP \fBapreq_value_t::nlen\fP" .PP length of name .SH "Author" .PP Generated automatically by Doxygen for libapreq2 from the source code. rapache-1.2.8/libapreq2/docs/man/man3/apreq_version.h.30000644000175100017510000000551712706745114022103 0ustar ondrejondrej.TH "include/apreq_version.h" 3 "4 May 2005" "Version 2.05-dev" "libapreq2" \" -*- nroff -*- .ad l .nh .SH NAME include/apreq_version.h \- Versioning API for libapreq. .SH SYNOPSIS .br .PP \fC#include 'apr_version.h'\fP .br \fC#include 'apreq.h'\fP .br .SS "Defines" .in +1c .ti -1c .RI "#define \fBAPREQ_MAJOR_VERSION\fP 2" .br .ti -1c .RI "#define \fBAPREQ_MINOR_VERSION\fP 1" .br .ti -1c .RI "#define \fBAPREQ_PATCH_VERSION\fP 0" .br .ti -1c .RI "#define \fBAPREQ_IS_DEV_VERSION\fP" .br .ti -1c .RI "#define \fBAPREQ_VERSION_STRING\fP" .br .ti -1c .RI "#define \fBAPREQ_IS_DEV_STRING\fP '-dev'" .br .in -1c .SS "Functions" .in +1c .ti -1c .RI "void \fBapreq_version\fP (\fBapr_version_t\fP *pvsn)" .br .ti -1c .RI "const char * \fBapreq_version_string\fP (void)" .br .in -1c .SH "Detailed Description" .PP Versioning API for libapreq. There are several different mechanisms for accessing the version. There is a string form, and a set of numbers; in addition, there are constants which can be compiled into your application, and you can query the library being used for its actual version. .PP Note that it is possible for an application to detect that it has been compiled against a different version of libapreq by use of the compile-time constants and the use of the run-time query function. .PP libapreq version numbering follows the guidelines specified in: .PP http://apr.apache.org/versioning.html .SH "Define Documentation" .PP .SS "#define APREQ_IS_DEV_STRING '-dev'" .PP Internal: string form of the 'is dev' flag .SS "#define APREQ_IS_DEV_VERSION" .PP This symbol is defined for internal, 'development' copies of libapreq. This symbol will be #undef'd for releases. .SS "#define APREQ_MAJOR_VERSION 2" .PP major version Major API changes that could cause compatibility problems for older programs such as structure size changes. No binary compatibility is possible across a change in the major version. .SS "#define APREQ_MINOR_VERSION 1" .PP Minor API changes that do not cause binary compatibility problems. Should be reset to 0 when upgrading APREQ_MAJOR_VERSION .SS "#define APREQ_PATCH_VERSION 0" .PP patch level .SS "#define APREQ_VERSION_STRING" .PP \fBValue:\fP .PP .nf APR_STRINGIFY(APREQ_MAJOR_VERSION) '.' \ APR_STRINGIFY(APREQ_MINOR_VERSION) '.' \ APR_STRINGIFY(APREQ_PATCH_VERSION) \ APREQ_IS_DEV_STRING .fi The formatted string of libapreq's version .SH "Function Documentation" .PP .SS "void apreq_version (\fBapr_version_t\fP * pvsn)" .PP Return libapreq's version information information in a numeric form. .PP \fBParameters:\fP .RS 4 \fIpvsn\fP Pointer to a version structure for returning the version information. .RE .PP .SS "const char* apreq_version_string (void)" .PP Return libapreq's version information as a string. .SH "Author" .PP Generated automatically by Doxygen for libapreq2 from the source code. rapache-1.2.8/libapreq2/docs/man/man3/apreq_xs.30000644000175100017510000000070012706745114020607 0ustar ondrejondrej.TH "Perl" 3 "4 May 2005" "Version 2.05-dev" "libapreq2" \" -*- nroff -*- .ad l .nh .SH NAME Perl \- XS Modules. .PP .SS "Modules" .in +1c .ti -1c .RI "\fBApache2::Request\fP" .br .ti -1c .RI "\fBApache2::Upload\fP" .br .ti -1c .RI "\fBApache2::Cookie\fP" .br .in -1c .SH "Detailed Description" .PP XS Modules. .PP .SH "SEE ALSO" .IX Header "SEE ALSO" \&\fIapreq_xs_request\fR\|(3), \fIapreq_xs_upload\fR\|(3), \fIapreq_xs_cookie\fR\|(3) rapache-1.2.8/libapreq2/docs/man/man3/apreq_xs_cookie.30000644000175100017510000000017512706745114022146 0ustar ondrejondrej.TH "Apache2::Cookie" 3 "4 May 2005" "Version 2.05-dev" "libapreq2" \" -*- nroff -*- .ad l .nh .SH NAME Apache2::Cookie \- rapache-1.2.8/libapreq2/docs/man/man3/apreq_xs_request.30000644000175100017510000000017712706745114022367 0ustar ondrejondrej.TH "Apache2::Request" 3 "4 May 2005" "Version 2.05-dev" "libapreq2" \" -*- nroff -*- .ad l .nh .SH NAME Apache2::Request \- rapache-1.2.8/libapreq2/docs/man/man3/apreq_xs_upload.30000644000175100017510000000017512706745114022161 0ustar ondrejondrej.TH "Apache2::Upload" 3 "4 May 2005" "Version 2.05-dev" "libapreq2" \" -*- nroff -*- .ad l .nh .SH NAME Apache2::Upload \- rapache-1.2.8/libapreq2/docs/man/man3/libapreq2.30000644000175100017510000000255312706745114020656 0ustar ondrejondrej.TH "Apache Request Library" 3 "4 May 2005" "Version 2.05-dev" "libapreq2" \" -*- nroff -*- .ad l .nh .SH NAME Apache Request Library \- libapreq2 Version 2.1.0 .PP .SS "Files" .in +1c .ti -1c .RI "file \fBapreq.h\fP" .br .RI "\fIMain header file... \fP" .PP .in +1c .ti -1c .RI "file \fBapreq_cookie.h\fP" .br .RI "\fICookies and Jars. \fP" .PP .in +1c .ti -1c .RI "file \fBapreq_error.h\fP" .br .RI "\fIError status codes. \fP" .PP .in +1c .ti -1c .RI "file \fBapreq_module.h\fP" .br .RI "\fIModule API. \fP" .PP .in +1c .ti -1c .RI "file \fBapreq_param.h\fP" .br .RI "\fIRequest parsing and parameter API. \fP" .PP .in +1c .ti -1c .RI "file \fBapreq_parser.h\fP" .br .RI "\fIRequest body parser API. \fP" .PP .in +1c .ti -1c .RI "file \fBapreq_util.h\fP" .br .RI "\fIUtility functions for apreq. \fP" .PP .in +1c .ti -1c .RI "file \fBapreq_version.h\fP" .br .RI "\fIVersioning API for libapreq. \fP" .PP .in -1c .SH "Detailed Description" .PP libapreq2 Version 2.1.0 .PP libapreq2 is a shared library based on the \fBApache\fP Portable Runtime libraries libapr and libaprutil. .PP \fBSee also:\fP .RS 4 http://apr.apache.org/ .RE .PP .SH "Configuring libapreq2 Applications" .PP This package includes \fCapreq2-config\fP, a configuration script for building applications with libapreq2. Run \fCapreq2-config --help\fP to display its options. XXX add examples here XXX rapache-1.2.8/libapreq2/docs/man/man3/mod_apreq2.30000644000175100017510000000716012706745114021025 0ustar ondrejondrej.TH "Apache 2.X Filter Module" 3 "4 May 2005" "Version 2.05-dev" "libapreq2" \" -*- nroff -*- .ad l .nh .SH NAME Apache 2.X Filter Module \- mod_apreq2 - DSO that ties libapreq2 to \fBApache\fP HTTPD 2.X. .PP .SS "Functions" .in +1c .ti -1c .RI "\fBapreq_handle_t\fP * \fBapreq_handle_apache2\fP (request_rec *r)" .br .in -1c .SH "Detailed Description" .PP mod_apreq2 - DSO that ties libapreq2 to \fBApache\fP HTTPD 2.X. .PP mod_apreq2 provides the 'APREQ2' input filter for using libapreq2 (and allow its parsed data structures to be shared) within the \fBApache\fP 2.X webserver. Using it, libapreq2 works properly in every phase of the HTTP request, from translation handlers to output filters, and even for subrequests / internal redirects. .PP .PP .PP .SS "Activating mod_apreq2 in \fBApache\fP 2.X" .PP The installation process triggered by \fC% make install\fP \fIwill not modify your webserver's config file\fP. Hence, be sure you activate it on startup by adding a LoadModule directive to your webserver config; e.g. .PP .PP .nf LoadModule modules/mod_apreq2.so .fi .PP .PP The mod_apreq2 filter is named 'APREQ2', and may be used in Apache's input filter directives, e.g. .PP .nf AddInputFilter APREQ2 # or SetInputFilter APREQ2 .fi .PP .PP However, this is not required because libapreq2 will add the filter (only) if it's necessary. You just need to ensure that your module invokes \fBapreq_handle_apache2()\fP \fIbefore the content handler ultimately reads from the input filter chain\fP. It is important to realize that no matter how the input filters are initially arranged, the APREQ2 filter will attempt to reposition itself to be the last input filter to read the data. .PP If you want to use other input filters to transform the incoming HTTP request data, is important to register those filters with \fBApache\fP as having type AP_FTYPE_CONTENT_SET or AP_FTYPE_RESOURCE. Due to the limitations of Apache's current input filter design, types higher than AP_FTYPE_CONTENT_SET may not work properly whenever the apreq filter is active. .PP This is especially true when a content handler uses libapreq2 to parse some of the post data before doing an internal redirect. Any input filter subsequently added to the redirected request will bypass the original apreq filter (and therefore lose access to some of the original post data), unless its type is less than the type of the apreq filter (currently AP_FTYPE_PROTOCOL-1). .PP .SS "Server Configuration Directives" .PP Directive Context DefaultDescription APREQ2_ReadLimit directory #APREQ_DEFAULT_READ_LIMIT Maximum number of bytes mod_apreq2 will send off to libapreq2 for parsing. mod_apreq2 will log this event and subsequently remove itself from the filter chain. APREQ2_BrigadeLimit directory #APREQ_DEFAULT_BRIGADE_LIMIT Maximum number of bytes mod_apreq2 will let accumulate within the heap-buckets in a brigade. Excess data will be spooled to an appended file bucket. APREQ2_TempDir directory NULL Sets the location of the temporary directory apreq will use to spool overflow brigade data (based on the APREQ2_BrigadeLimit setting). If left unset, libapreq2 will select a platform-specific location via \fBapr_temp_dir_get()\fP. Per-directory commands for mod_apreq2 .PP .SS "Implementation Details" .PP .PP .nf XXX apreq as a normal input filter XXX apreq as a 'virtual' content handler. XXX apreq as a transparent 'tee'. XXX apreq parser registration in post_config .fi .PP .SH "Function Documentation" .PP .SS "\fBapreq_handle_t\fP* apreq_handle_apache2 (request_rec * r)" .PP Create an apreq handle which communicates with an \fBApache\fP 2.X request_rec. rapache-1.2.8/libapreq2/docs/man/man3/todo.30000644000175100017510000000141112706745114017732 0ustar ondrejondrej.TH "todo" 3 "4 May 2005" "Version 2.05-dev" "libapreq2" \" -*- nroff -*- .ad l .nh .SH NAME todo \- Todo List .IP "\fBGlobal \fBAPREQ_COOKIE_MAX_LENGTH\fP \fP" 1c convert this macro to an \fBapreq_module_t\fP method. .PP .PP .IP "\fBGlobal \fBapreq_atoi64f\fP(const char *s) \fP" 1c What happens when s is malformed? Should this return an unsigned value instead? .PP .PP .IP "\fBGlobal \fBapreq_atoi64t\fP(const char *s) \fP" 1c What happens when s is malformed? Should this return an unsigned value instead? .PP .PP .IP "\fBGlobal \fBapreq_brigade_concat\fP(apr_pool_t *pool, const char *temp_dir, apr_size_t brigade_limit, \fBapr_bucket_brigade\fP *out, \fBapr_bucket_brigade\fP *in) \fP" 1c Flesh out these error codes, making them as explicit as possible. .PP rapache-1.2.8/libapreq2/glue/0000755000175100017510000000000012706745114015277 5ustar ondrejondrejrapache-1.2.8/libapreq2/glue/Makefile.am0000644000175100017510000000105512706745114017334 0ustar ondrejondrejEXTRA_DIST = perl dist-hook: perl_config: cd perl; @PERL@ ../../build/xsbuilder.pl run perl/Makefile: perl/xsbuilder perl/Makefile.PL cd perl; @PERL@ Makefile.PL -apxs @APACHE2_APXS@ @PERL_OPTS@ perl_glue: perl/Makefile cd perl; $(MAKE) perl_test: perl/Makefile cd perl; $(MAKE) test perl_install: cd perl; $(MAKE) install perl_clean: -cd perl; $(MAKE) clean if BUILD_PERL_GLUE all-local: perl_glue install-exec-local: perl_install clean-local: perl_clean test: perl_test else all-local: install-exec-local: clean-local: test: endif rapache-1.2.8/libapreq2/glue/Makefile.in0000644000175100017510000001602512706745114017350 0ustar ondrejondrej# Makefile.in generated by automake 1.6.3 from Makefile.am. # @configure_input@ # Copyright 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002 # 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@ SHELL = @SHELL@ srcdir = @srcdir@ top_srcdir = @top_srcdir@ VPATH = @srcdir@ prefix = @prefix@ exec_prefix = @exec_prefix@ bindir = @bindir@ sbindir = @sbindir@ libexecdir = @libexecdir@ datadir = @datadir@ sysconfdir = @sysconfdir@ sharedstatedir = @sharedstatedir@ localstatedir = @localstatedir@ libdir = @libdir@ infodir = @infodir@ mandir = @mandir@ includedir = @includedir@ oldincludedir = /usr/include pkgdatadir = $(datadir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ top_builddir = .. ACLOCAL = @ACLOCAL@ AUTOCONF = @AUTOCONF@ AUTOMAKE = @AUTOMAKE@ AUTOHEADER = @AUTOHEADER@ am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd INSTALL = @INSTALL@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_DATA = @INSTALL_DATA@ install_sh_DATA = $(install_sh) -c -m 644 install_sh_PROGRAM = $(install_sh) -c install_sh_SCRIPT = $(install_sh) -c INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_HEADER = $(INSTALL_DATA) transform = @program_transform_name@ NORMAL_INSTALL = : PRE_INSTALL = : POST_INSTALL = : NORMAL_UNINSTALL = : PRE_UNINSTALL = : POST_UNINSTALL = : host_alias = @host_alias@ host_triplet = @host@ EXEEXT = @EXEEXT@ OBJEXT = @OBJEXT@ PATH_SEPARATOR = @PATH_SEPARATOR@ AMTAR = @AMTAR@ APACHE1_APXS = @APACHE1_APXS@ APACHE2_APXS = @APACHE2_APXS@ APACHE2_HTTPD = @APACHE2_HTTPD@ APACHE2_INCLUDES = @APACHE2_INCLUDES@ APACHE2_SRC = @APACHE2_SRC@ APREQ_CONFIG = @APREQ_CONFIG@ APREQ_DOTTED_VERSION = @APREQ_DOTTED_VERSION@ APREQ_LIBNAME = @APREQ_LIBNAME@ APREQ_LIBTOOL_VERSION = @APREQ_LIBTOOL_VERSION@ APREQ_MAJOR_VERSION = @APREQ_MAJOR_VERSION@ APR_CONFIG = @APR_CONFIG@ APR_INCLUDES = @APR_INCLUDES@ APR_LA = @APR_LA@ APR_LDFLAGS = @APR_LDFLAGS@ APR_LIBS = @APR_LIBS@ APR_LTFLAGS = @APR_LTFLAGS@ APU_CONFIG = @APU_CONFIG@ APU_LA = @APU_LA@ AR = @AR@ AS = @AS@ AWK = @AWK@ CC = @CC@ CXX = @CXX@ CXXCPP = @CXXCPP@ DEPDIR = @DEPDIR@ DLLTOOL = @DLLTOOL@ ECHO = @ECHO@ EGREP = @EGREP@ F77 = @F77@ GCJ = @GCJ@ GCJFLAGS = @GCJFLAGS@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ LIBTOOL = @LIBTOOL@ LN_S = @LN_S@ MAINT = @MAINT@ OBJDUMP = @OBJDUMP@ PACKAGE = @PACKAGE@ PERL = @PERL@ PERL_OPTS = @PERL_OPTS@ RANLIB = @RANLIB@ RC = @RC@ STRIP = @STRIP@ VERSION = @VERSION@ am__include = @am__include@ am__quote = @am__quote@ install_sh = @install_sh@ EXTRA_DIST = perl subdir = glue mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs CONFIG_HEADER = $(top_builddir)/include/apreq_config.h CONFIG_CLEAN_FILES = DIST_SOURCES = DIST_COMMON = README Makefile.am Makefile.in all: all-am .SUFFIXES: $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ Makefile.am $(top_srcdir)/configure.ac $(ACLOCAL_M4) cd $(top_srcdir) && \ $(AUTOMAKE) --gnu glue/Makefile Makefile: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.in $(top_builddir)/config.status cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe) mostlyclean-libtool: -rm -f *.lo clean-libtool: -rm -rf .libs _libs distclean-libtool: -rm -f libtool uninstall-info-am: tags: TAGS TAGS: DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) top_distdir = .. distdir = $(top_distdir)/$(PACKAGE)-$(VERSION) distdir: $(DISTFILES) @list='$(DISTFILES)'; for file in $$list; do \ if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ dir=`echo "$$file" | sed -e 's,/[^/]*$$,,'`; \ if test "$$dir" != "$$file" && test "$$dir" != "."; then \ dir="/$$dir"; \ $(mkinstalldirs) "$(distdir)$$dir"; \ else \ dir=''; \ fi; \ if test -d $$d/$$file; then \ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \ fi; \ cp -pR $$d/$$file $(distdir)$$dir || exit 1; \ else \ test -f $(distdir)/$$file \ || cp -p $$d/$$file $(distdir)/$$file \ || exit 1; \ fi; \ done $(MAKE) $(AM_MAKEFLAGS) \ top_distdir="${top_distdir}" distdir="$(distdir)" \ dist-hook check-am: all-am check: check-am all-am: Makefile all-local installdirs: 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_STRIP_FLAG=-s \ `test -z '$(STRIP)' || \ echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install mostlyclean-generic: clean-generic: distclean-generic: -rm -f Makefile $(CONFIG_CLEAN_FILES) maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." clean: clean-am clean-am: clean-generic clean-libtool clean-local mostlyclean-am distclean: distclean-am distclean-am: clean-am distclean-generic distclean-libtool dvi: dvi-am dvi-am: info: info-am info-am: install-data-am: install-exec-am: install-exec-local install-info: install-info-am install-man: installcheck-am: maintainer-clean: maintainer-clean-am maintainer-clean-am: distclean-am maintainer-clean-generic mostlyclean: mostlyclean-am mostlyclean-am: mostlyclean-generic mostlyclean-libtool uninstall-am: uninstall-info-am .PHONY: all all-am all-local check check-am clean clean-generic \ clean-libtool clean-local distclean distclean-generic \ distclean-libtool distdir dvi dvi-am info info-am install \ install-am install-data install-data-am install-exec \ install-exec-am install-exec-local install-info install-info-am \ install-man install-strip installcheck installcheck-am \ installdirs maintainer-clean maintainer-clean-generic \ mostlyclean mostlyclean-generic mostlyclean-libtool uninstall \ uninstall-am uninstall-info-am dist-hook: perl_config: cd perl; @PERL@ ../../build/xsbuilder.pl run perl/Makefile: perl/xsbuilder perl/Makefile.PL cd perl; @PERL@ Makefile.PL -apxs @APACHE2_APXS@ @PERL_OPTS@ perl_glue: perl/Makefile cd perl; $(MAKE) perl_test: perl/Makefile cd perl; $(MAKE) test perl_install: cd perl; $(MAKE) install perl_clean: -cd perl; $(MAKE) clean @BUILD_PERL_GLUE_TRUE@all-local: perl_glue @BUILD_PERL_GLUE_TRUE@install-exec-local: perl_install @BUILD_PERL_GLUE_TRUE@clean-local: perl_clean @BUILD_PERL_GLUE_TRUE@test: perl_test @BUILD_PERL_GLUE_FALSE@all-local: @BUILD_PERL_GLUE_FALSE@install-exec-local: @BUILD_PERL_GLUE_FALSE@clean-local: @BUILD_PERL_GLUE_FALSE@test: # 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: rapache-1.2.8/libapreq2/glue/README0000644000175100017510000000004612706745114016157 0ustar ondrejondrejLanguage bindings go in glue//. rapache-1.2.8/libapreq2/glue/perl/0000755000175100017510000000000012706745114016241 5ustar ondrejondrejrapache-1.2.8/libapreq2/glue/perl/Makefile.PL0000644000175100017510000003747712706745114020235 0ustar ondrejondrejuse strict; use ModPerl::MM; use 5.005; use Apache::Test5005compat; use Apache::TestMM qw(test clean); use Apache::TestReport (); use Apache::TestSmoke (); use Apache::TestRun (); use Apache::TestConfigPerl (); use Apache::TestSmokePerl (); use Apache::TestReportPerl (); use Config; use File::Find qw(finddepth); use File::Basename; use Apache2::Build; use constant WIN32 => Apache2::Build::WIN32; use Cwd; use ExtUtils::XSBuilder::ParseSource; my $version = "2.XX-dev"; # DUMMY VALUE my $cwd = WIN32 ? Win32::GetLongPathName(cwd) : cwd; $cwd =~ m{^(.+)/glue/perl$} or die "Can't find base directory"; my $base_dir = $1; my $inc_dir = "$base_dir/include"; my $lib_dir = "$base_dir/library"; my $xs_dir = "$base_dir/glue/perl/xsbuilder"; sub slurp($$) { open my $file, $_[1] or die "Can't open $_[1]: $!"; read $file, $_[0], -s $file; } my ($apache_includes, $apache_dir, $apr_libs, $apreq_libname, $perl_lib); if (WIN32) { # XXX May need fixing, Randy! slurp my $config => "$base_dir/configure.ac"; $config =~ /^AC_INIT[^,]+,\s*([^,\s]+)/m or die "Can't find version string"; $version = $1; slurp my $make => "$base_dir/Makefile"; $make =~ /^APACHE=(\S+)/m or die "Cannot find top-level Apache directory"; ($apache_dir = $1) =~ s!\\!/!g; ($apache_includes = "-I$apache_dir" . '/include') =~ s!\\!/!g; ($apr_libs = "-L$apache_dir" . '/lib') =~ s!\\!/!g; $make =~ /^APR_LIB=(\S+)/m or die "Cannot find apr lib"; $apr_libs .= ' -l' . basename($1, '.lib'); $make =~ /^APU_LIB=(\S+)/m or die "Cannot find aprutil lib"; $apr_libs .= ' -l' . basename($1, '.lib'); $apreq_libname = 'apreq2'; $perl_lib = $Config{installsitelib} . '\auto\libaprext'; $perl_lib =~ s{\\}{\\\\}g; } else { slurp my $config => "$base_dir/config.status"; $config =~ /^s,\@APACHE2_INCLUDES\@,([^,]+)/m or die "Can't find apache include directory"; $apache_includes = $1; $config =~ /^s,\@APR_INCLUDES\@,([^,]+)/m or die "Can't find apache include directory"; $apache_includes .= " $1"; # $config =~ m/^s,\@APR_LDFLAGS\@,([^,]+)/m or # die "Can't find apr ldflags"; # $apr_libs = $1; # $config =~ m/^s,\@APR_LIBS\@,([^,]+)/m or # die "Can't find apr libraries"; # $apr_libs .= " $1"; $apr_libs =""; $config =~ m/^s,\@APREQ_LIBNAME\@,([^,]+)/m or die "Can't find apreq libname"; $apreq_libname = $1; $config =~ m/^s,\@PACKAGE_VERSION\@,([^,]+)/m or die "Can't find package version"; $version = $1; } my $apreq_libs = WIN32 ? qq{-L$base_dir/win32/libs -llib$apreq_libname -lmod_apreq2 -L$perl_lib -llibaprext -L$apache_dir/lib -lmod_perl} : qx{$base_dir/apreq2-config --link-ld --ldflags --libs}; my $mp2_typemaps = Apache2::Build->new->typemaps; package My::ParseSource; use base qw/ExtUtils::XSBuilder::ParseSource/; use constant WIN32 => ($^O =~ /Win32/i); my @dirs = ("$base_dir/include", "$base_dir/module/apache2"); sub package {'APR::Request'} sub unwanted_includes {[qw/apreq_config.h apreq_private_apache2.h/]} # ParseSource.pm v 0.23 bug: line 214 should read # my @dirs = @{$self->include_dirs}; # for now, we override it here just to work around the bug sub find_includes { my $self = shift; return $self->{includes} if $self->{includes}; require File::Find; my(@dirs) = @{$self->include_dirs}; unless (-d $dirs[0]) { die "could not find include directory"; } # print "Will search @dirs for include files...\n" if ($verbose) ; my @includes; my $unwanted = join '|', @{$self -> unwanted_includes} ; for my $dir (@dirs) { File::Find::finddepth({ wanted => sub { return unless /\.h$/; return if ($unwanted && (/^($unwanted)/o)); my $dir = $File::Find::dir; push @includes, "$dir/$_"; }, follow => not WIN32, }, $dir); } return $self->{includes} = $self -> sort_includes (\@includes) ; } sub include_dirs {\@dirs} package My::WrapXS; use base qw/ExtUtils::XSBuilder::WrapXS/; our $VERSION = $version; use constant WIN32 => ($^O =~ /Win32/i); ################################################## # Finally, we get to the actual script... __PACKAGE__ -> run; my @scripts = (); use File::Spec::Functions qw(catfile); File::Find::finddepth(sub { return unless /(.*?\.pl)\.PL$/; push @scripts, "$File::Find::dir/$1"; }, '.'); Apache::TestMM::filter_args(); Apache::TestMM::generate_script("t/TEST"); Apache::TestSmokePerl->generate_script; Apache::TestReportPerl->generate_script; my %opts = ( NAME => 'libapreq2', DIR => [qw(xs)], clean => { FILES => "xs t/logs t/TEST @scripts" }, realclean => { FILES => "xsbuilder/tables" }, ); ModPerl::MM::WriteMakefile(%opts); # That's the whole script - below is just a bunch of local overrides ################################################## sub get_functions { my $self = shift; $self->{XS}->{"APR::Request::Error"} ||= []; $self->SUPER::get_functions; } sub copy_docs { my @lines; my $dfs = '$(DIRFILESEP)'; return; # XXX FIXME when APR::Request gets documentation foreach my $file (@_) { my @dirs; $file =~ /(\w+\.pod)$/ or next; if ($1 eq "Error.pod" or $1 eq "Table.pod") { push @dirs, "Apache$dfs$_" for qw/Request Cookie Upload/; push @dirs, join $dfs, qw/Apache Cookie Jar/ if $1 eq "Error.pod"; } else { push @dirs, "Apache"; } push @lines, map <; my @tests = @docs; s/pod$/t/ for @tests; my $string = copy_docs(@docs); my $test_docs = test_docs(\@docs, \@tests); if ($test_docs) { $string .= $test_docs; $string .= <new]} sub new_typemap {My::TypeMap->new(shift)} sub h_filename_prefix {'apreq_xs_'} sub my_xs_prefix {'apreq_xs_'} sub xs_include_dir { $xs_dir } sub mod_xs { my($self, $module, $complete) = @_; my $dirname = $self->class_dirname($module); my @parts = split '::', $module; my $mod_xs = "$dirname/$parts[-1].xs"; for ($self -> xs_include_dir, @{ $self->{glue_dirs} }) { my $file = "$_/$mod_xs"; $mod_xs = $file if $complete; return $mod_xs if -e $file; } undef; } sub mod_pm { my($self, $module, $complete) = @_; my $dirname = $self->class_dirname($module); my @parts = split '::', $module; my $mod_pm = "$dirname/$parts[-1].pm"; for ($self -> xs_include_dir, @{ $self->{glue_dirs} }) { my $file = "$_/$mod_pm"; $mod_pm = $file if $complete; return $mod_pm if -e $file; } undef; } #inline mod_xs directly, so we can put XS directives there sub write_xs { my($self, $module, $functions) = @_; my $fh = $self->open_class_file($module, '.xs'); print $fh "$self->{noedit_warning_c}\n"; my @includes = @{ $self->includes }; if (my $mod_h = $self->mod_h($module)) { push @includes, $mod_h; } for (@includes) { print $fh qq{\#include "$_"\n\n}; } if (my $mod_xs = $self->mod_xs($module, 1)) { open my $file, $mod_xs or die "can't open $mod_xs: $!"; print $fh $_ while <$file>; print $fh "\n\n"; } my $last_prefix = ""; my $fmap = $self -> typemap -> {function_map} ; my $myprefix = $self -> my_xs_prefix ; for my $func (@$functions) { my $class = $func->{class}; if ($class) { my $prefix = $func->{prefix}; $last_prefix = $prefix if $prefix; if ($func->{name} =~ /^$myprefix/o) { #e.g. mpxs_Apache__RequestRec_ my $class_prefix = $fmap -> class_c_prefix($class); if ($func->{name} =~ /$class_prefix/) { $prefix = $fmap -> class_xs_prefix($class); } } $prefix = $prefix ? " PREFIX = $prefix" : ""; print $fh "MODULE = $module PACKAGE = $class $prefix\n\n"; } print $fh $func->{code}; } if (my $destructor = $self->typemap->destructor($last_prefix)) { my $arg = $destructor->{argspec}[0]; print $fh <{name}($arg) $destructor->{class} $arg EOF } print $fh "PROTOTYPES: disabled\n\n"; print $fh "BOOT:\n"; print $fh $self->boot($module); print $fh " items = items; /* -Wall */\n\n"; if (my $newxs = $self->{newXS}->{$module}) { for my $xs (@$newxs) { print $fh qq{ cv = newXS("$xs->[0]", $xs->[1], __FILE__);\n}; print $fh qq{ GvSHARED_on(CvGV(cv));\n} if ExtUtils::XSBuilder::WrapXS::GvSHARED(); } } close $fh; } sub mod_pod { my($self, $module, $complete) = @_; my $dirname = $self->class_dirname($module); my @parts = split '::', $module; my $mod_pod = "$dirname/$parts[-1].pod"; for ($self -> xs_incsrc_dir, @{ $self->{glue_dirs} }) { my $file = "$_/$mod_pod"; $mod_pod = $file if $complete; print "mod_pod $mod_pod $file $complete\n" ; return $mod_pod if -e $file; } undef; } sub write_docs { my ($self, $module, $functions) = @_; my $podfile = $self->mod_pod($module, 1) or return; my $fh = $self->open_class_file($module, '.pod'); open my $pod, "<", $podfile or die $!; while (<$pod>) { print $fh $_; } } sub pm_text { my($self, $module, $isa, $code) = @_; my $text = <<"EOF"; $self->{noedit_warning_hash} package $module; require DynaLoader ; use strict; use warnings FATAL => 'all'; use vars qw{\$VERSION \@ISA} ; $isa push \@ISA, 'DynaLoader' ; \$VERSION = '$version'; bootstrap $module \$VERSION ; $code 1; __END__ EOF return $text; } sub makefilepl_text { my($self, $class, $deps,$typemap) = @_; my @parts = split (/::/, $class) ; my $mmargspath = '../' x @parts ; $mmargspath .= 'mmargs.pl' ; my $txt = qq{ $self->{noedit_warning_hash} use ModPerl::MM; local \$MMARGS ; if (-f '$mmargspath') { do '$mmargspath' ; die \$\@ if (\$\@) ; } \$MMARGS ||= {} ; ModPerl::MM::WriteMakefile( 'NAME' => '$class', 'VERSION' => '$version', 'TYPEMAPS' => [qw(@$mp2_typemaps $typemap)], 'INC' => "-I$base_dir/glue/perl/xs -I$inc_dir -I$xs_dir $apache_includes", 'LIBS' => "$apreq_libs $apr_libs", } ; $txt .= "'depend' => $deps,\n" if ($deps) ; $txt .= qq{ \%\$MMARGS, ); } ; } # For now, just copy the typemap file in xsbuilder til we # can remove ExtUtils::XSBuilder. sub write_typemap { my $self = shift; my $typemap = $self->typemap; my $map = $typemap->get; my %seen; my $fh = $self->open_class_file('', 'typemap'); print $fh "$self->{noedit_warning_hash}\n"; open my $tfh, "$xs_dir/typemap" or die $!; print $fh $_ while <$tfh>; } package My::TypeMap; use base 'ExtUtils::XSBuilder::TypeMap'; sub null_type { my($self, $type) = @_; my $t = $self->get->{$type}; my $class = $t -> {class} ; if ($class =~ /APREQ_COOKIE_VERSION/) { return 'APREQ_COOKIE_VERSION_DEFAULT'; } else { return $self->SUPER::null_type($type); } } # XXX this needs serious work sub typemap_code { { T_SUBCLASS => { INPUT => <<'EOT', if (SvROK($arg) || !sv_derived_from($arg, \"$Package\")) Perl_croak(aTHX_ \"Usage: argument is not a subclass of $Package\"); $var = SvPV_nolen($arg) EOT }, T_APREQ_COOKIE => { INPUT => '$var = apreq_xs_sv2cookie(aTHX_ $arg)', perl2c => 'apreq_xs_sv2cookie(aTHX_ sv)', OUTPUT => '$arg = apreq_xs_cookie2sv(aTHX_ $var, class, parent);', c2perl => 'apreq_xs_cookie2sv(aTHX_ ptr, class, parent)', }, T_APREQ_PARAM => { INPUT => '$var = apreq_xs_sv2param(aTHX_ $arg)', perl2c => 'apreq_xs_sv2param(aTHX_ sv)', OUTPUT => '$arg = apreq_xs_param2sv(aTHX_ $var, class, parent);', c2perl => 'apreq_xs_param2sv(aTHX_ ptr, class, parent)', }, T_APREQ_HANDLE => { INPUT => '$var = apreq_xs_sv2handle(aTHX_ $arg)', perl2c => 'apreq_xs_sv2handle(aTHX_ sv)', c2perl => 'apreq_xs_handle2sv(aTHX_ ptr, class, parent)', OUTPUT => '$arg = apreq_xs_handle2sv(aTHX_ $var, class, parent);', }, T_APREQ_HANDLE_CGI => { INPUT => '$var = apreq_xs_sv2handle(aTHX_ $arg)', OUTPUT => '$arg = apreq_xs_handle2sv(aTHX_ $var, class, SvRV(ST(1)));' }, T_APREQ_HANDLE_APACHE2 => { INPUT => '$var = apreq_xs_sv2handle(aTHX_ $arg)', OUTPUT => <<'EOT', $arg = apreq_xs_handle2sv(aTHX_ $var, class, SvRV(ST(1))); SvMAGIC(SvRV($arg))->mg_ptr = (void *)r; EOT }, T_APREQ_ERROR => { INPUT => '$var = (HV *)SvRV($arg)', OUTPUT => '$arg = sv_bless(newRV_noinc((SV*)$var), gv_stashpvn(\"${ntype}\", sizeof(\"${ntype}\") - 1, FALSE);' }, T_HASHOBJ => { INPUT => <<'EOT', # '$var = modperl_hash_tied_object(aTHX_ \"${ntype}\", $arg)' if (sv_derived_from($arg, \"${ntype}\")) { if (SVt_PVHV == SvTYPE(SvRV($arg))) { SV *hv = SvRV($arg); MAGIC *mg; if (SvMAGICAL(hv)) { if ((mg = mg_find(hv, PERL_MAGIC_tied))) { $var = (void *)MgObjIV(mg); } else { Perl_warn(aTHX_ \"Not a tied hash: (magic=%c)\", mg); $var = NULL; } } else { Perl_warn(aTHX_ \"SV is not tied\"); $var = NULL; } } else { $var = (void *)SvObjIV($arg); } } else { Perl_croak(aTHX_ \"argument is not a blessed reference \" \"(expecting an %s derived object)\", \"${ntype}\"); } EOT OUTPUT => <<'EOT', # '$arg = modperl_hash_tie(aTHX_ \"${ntype}\", $arg, $var);' { SV *hv = (SV*)newHV(); SV *rsv = $arg; sv_setref_pv(rsv, \"${ntype}\", $var); sv_magic(hv, rsv, PERL_MAGIC_tied, Nullch, 0); $arg = SvREFCNT_inc(sv_bless(sv_2mortal(newRV_noinc(hv)), gv_stashpv(\"${ntype}\", TRUE))); } EOT }, } } rapache-1.2.8/libapreq2/glue/perl/README0000644000175100017510000000765212706745114017133 0ustar ondrejondrejTo parse the libapreq headers into xsbuilder/tables: % perl ../../build/xsbuilder.pl run To build the xs/ directory and configure the tests: % perl Makefile.PL -apxs /path/to/apache2/bin/apxs To run the test suite: % make test DEVELOPER NOTES APR::Request::* should be a simple translation of the apreq C API: apreq_handle_t -> APR::Request-derived instance. apreq_module_t -> APR::Request-derived class. apreq_param_t -> APR::Request::Param apreq_cookie_t -> APR::Request::Cookie apreq_parser_t -> APR::Request::Parser (todo) apreq_hook_t -> APR::Request::Hook (todo) -------------------------------------------------- Current APR:: module breakdown -------------------------------------------------- APR::Request subs: encode decode methods: parse read_limit brigade_limit temp_dir header_in header_out jar_status args_status body_status param_status disable_uploads missing: add_hook (requires APR::Request::Hook) parser (requires APR::Request::Parser) ================================================== APR::Request::CGI @ISA=(APR::Request) method: param ctor: new ================================================== APR::Request::Apache2 @ISA=(APR::Request) method: param ctor: new ================================================== APR::Request::Error @ISA=(APR::Error, APR::Request) subs: strerror ================================================== APR::Request::Cookie provides: APR::Request::jar() APR::Request::Cookie::Table methods: get, FETCH FIRSTKEY, NEXTKEY cookie_class missing: rest of const apr_table_t * API (do, etc) methods: name value secure version is_tainted as_string bake bake2 expires path domain port comment commentURL freeze thaw bind_handle ctor: new ================================================== APR::Request::Param provides: APR::Request::args() APR::Request::body() APR::Request::param() APR::Request::params() APR::Request::Param::Table methods: get, FETCH FIRSTKEY, NEXTKEY param_class uploads do missing: rest of const apr_table_t * API APR::Request::Brigade methods: TIEHANDLE, new READ READLINE APR::Request::Brigade::IO read readline methods: name value info upload upload_link upload_slurp upload_size upload_type upload_tempname upload_io upload_fh -------------------------------------------------- Current (pure-perl) Apache2:: module breakdown -------------------------------------------------- Apache2::Request @ISA=(Apache2::RequestRec, APR::Request::Apache2) ctor: new methods: instance (deprecated, ok to remove this) disable_uploads missing: hook_data upload_hook 2.04-deltas: env() removed params() method inherited from APR::Request; not deprecated anymore. parms() removed status() removed. args() needs to become Apache2::RequestRec::args!!! The args() change probably deserves a runtime warning in 2.05-dev. ================================================== Apache2::Cookie @ISA=(APR::Request::Cookie) provides: Apache2::Cookie::Jar @ISA=(APR::Request::Apache2) methods: cookies status subs: encode decode methods: new fetch set_attr freeze thaw value 2.04-deltas: env() removed ================================================== Apache2::Upload @ISA=(APR::Request::Param) provides: Apache2::Request::upload methods: slurp type size link tempname fh io filename bb (need to deprecate this) 2.04-deltas: Apache::Upload::Brigade is now APR::Request::Brigade. rapache-1.2.8/libapreq2/glue/perl/docs/0000755000175100017510000000000012706745114017171 5ustar ondrejondrejrapache-1.2.8/libapreq2/glue/perl/docs/Cookie.pod0000644000175100017510000003401412706745114021110 0ustar ondrejondrej=head1 NAME Apache::Cookie, Apache::Cookie::Jar - HTTP Cookies Class =for testing use Apache::Cookie; use APR::Pool; # use $r instead of $p here, so doc examples reflect mp2 env, not CGI/test env $r = APR::Pool->new; $j = Apache::Cookie::Jar->new($r); $j->cookies->{foo} = Apache::Cookie->new($r, name => "foo", value => "1"); $j->cookies->add( Apache::Cookie->new($r, name => "bar", value => "2") ); # We must disable bake and bake2 in the api tests, # since they write directly to fd 1 via apr_file_write(). *Apache::Cookie::bake = *Apache::Cookie::bake2 = *Apache::Cookie::as_string; =head1 SYNOPSIS =for example begin use Apache::Cookie; $j = Apache::Cookie::Jar->new($r); $c_in = $j->cookies("foo"); # get cookie from request headers $c_out = Apache::Cookie->new($r, -name => "mycookie", -value => $c_in->name ); $c_out->path("/bar"); # set path to "/bar" $c_out->bake; # send cookie in response headers =for example end =for example_testing ok "foo bar" eq join " ", keys %{$j->cookies}; ok $c_out->as_string eq "mycookie=foo; path=/bar"; ok $c_in->value == 1; =head1 DESCRIPTION The 2.X Apache::Cookie module is based on the original 1.X versions, which mimic the CGI::Cookie API. The current version of this module includes several packages and methods which are patterned after Apache::Request, yet remain largely backwards-compatible with the original 1.X API (see the L section below for known issues). This manpage documents the Apache::Cookie and Apache::Cookie::Jar packages. Apache::Cookie::Error, Apache::Cookie::Jar::Error and Apache::Cookie::Table are also provided by this module but documented elsewhere (related manpages listed in L). =head1 Apache::Cookie::Jar This class collects Apache::Cookie objects into a lookup table. It plays the same role for accessing the incoming cookies as Apache::Request does for accessing the incoming params and file uploads. =head2 new Apache::Cookie::Jar->new($env, %args) Class method that retrieves the parsed cookie jar from the current environment. An optional VALUE_CLASS => $class argument instructs the jar to bless any returned cookies into $class instead of Apache::Cookie. This feature is meant to be useful in situations where C is unable to correctly interpret an incoming cookie's serialization. Users can simply override C in an application-specific subclass and pass that subclass's name as the VALUE_CLASS argument: =for example begin { package FOO; @ISA= 'Apache::Cookie'; } my $jar = Apache::Cookie::Jar->new($r, VALUE_CLASS => "FOO"); ok $jar->cookies("foo")->isa("FOO"); ok $jar->cookies->{bar}->isa("FOO"); =for example end =for example_testing ok $jar->isa("Apache::Cookie::Jar"); $jar->cookies->do(sub { ok $_[1]->isa("FOO"); }); map { ok $_->isa("FOO") } values %{$jar->cookies}; =head2 cookies $jar->cookies() $jar->cookies($key) Retrieve cookies named $key with from the jar object. In scalar context the first such cookie is returned, and in list context the full list of such cookies are returned. If the $key argument is omitted, C<< scalar $jar->cookies() >> will return an Apache::Cookie::Table object containing all the cookies in the jar. Modifications to the this object will affect the jar's internal I table in C, so their impact will be noticed by all libapreq2 applications during this request. In list context C<< $jar->cookies() >> returns the list of names for all the cookies in the jar. The order corresponds to the order in which the cookies appeared in the incoming "Cookie" header. This method will throw an Apache::Cookie::Jar::Error object into $@ if the returned value(s) may be unreliable. In particular, note that C<< scalar $jar->cookies("foo") >> will not croak if it can locate the a "foo" cookie within the jar's parsed cookie table, even if the cookie parser has failed (the cookies are parsed in the same order as they appeared in the "Cookie" header). In all other circumstances C will croak if the parser failed to successfully parse the "Cookie" header. =for example begin $c = Apache::Cookie->new($r, name => "foo", value => 3); $j->cookies->add($c); $cookie = $j->cookies("foo"); # first foo cookie @cookies = $j->cookies("foo"); # all foo cookies @names = $j->cookies(); # all cookie names =for example end =for example_testing ok @cookies == 2; is $_ -> name, "foo" for $cookie, @cookies; ok $cookies[0]->value eq $cookie->value; ok $cookies[0]->value == 1; ok $cookies[1]->value == 3; is "@names", "foo bar"; =head2 status $jar->status() $jar->status($set) Get or set the I status code of the cookie parser: APR_SUCCESS on success, error otherwise. =for example begin $j->status(-1); ok $j->status == -1; eval { @cookies = $j->cookies("foo") }; # croaks ok $@->isa("Apache::Cookie::Jar::Error"); $j->status(0); =for example end =for example_testing ok $j->status == 0, '$j->status == 0'; @cookies = $j->cookies("foo"); ok @cookies == 2, '@cookies == 2'; =head2 env Apache::Cookie::Jar->env() $jar->env() As a class method C<< Apache::Cookie::Jar->env >> returns the environment class associated with Apache::Cookie::Jar. As an object method, C<< $jar->env >> returns the environment object which first created the $jar (via C). =for example begin ok $j->env->isa(Apache::Cookie::Jar->env); =for example end =for example_testing ok (Apache::Cookie::Jar->env eq "APR::Pool", 'env() isa APR::Pool'); =head1 Apache::Cookie =head2 new Apache::Cookie->new($env, %args) Just like CGI::Cookie::new, but requires an additional environment argument: =for example begin $cookie = Apache::Cookie->new($r, -name => 'foo', -value => 'bar', -expires => '+3M', -domain => '.capricorn.com', -path => '/cgi-bin/database', -secure => 1 ); =for example end =for example_testing ok $cookie->name eq "foo", 'name eq "foo"'; ok $cookie->value eq "bar", 'value eq "bar"'; ok $cookie->domain eq ".capricorn.com", 'domain eq ".capricorn.com"'; ok $cookie->path eq "/cgi-bin/database",'path eq "/cgi-bin/database"'; ok $cookie->secure == 1, '$cookie->secure == 1'; The C<-value> argument may be either an arrayref, a hashref, or a string. C encodes this argument into the cookie's raw value. =head2 freeze Apache::Cookie->freeze($value) Helper function (for C) that serializes a new cookie's value in a manner compatible with CGI::Cookie (and Apache::Cookie 1.X). This class method accepts an arrayref, hashref, or normal perl string in $value. =for example begin $value = Apache::Cookie->freeze(["2+2", "=4"]); =for example end =for example_testing ok $value eq "2%2b2&%3d4", '$value eq "2%2b2&%3d4"'; =head2 thaw Apache::Cookie->thaw($value) $cookie->thaw() This is the helper method (for C) responsible for decoding the raw value of a cookie. An optional argument $value may be used in place of the cookie's raw value. This method can also decode cookie values created using CGI::Cookie or Apache::Cookie 1.X. =for example begin print $cookie->thaw; # prints "bar" @values = Apache::Cookie->thaw($value); # ( "2+2", "=4" ) =for example end =for example_testing ok $_STDOUT_ eq "bar", '$_STDOUT_ eq "bar"'; ok @values == 2, '@values == 2'; ok $values[0] eq "2+2", '$values[0] eq "2+2"'; ok $values[1] eq "=4", '$values[1] eq "=4"'; =head2 as_string $cookie->as_string() Format the cookie object as a string. The quote-operator for Apache::Cookie is overloaded to run this method whenever a cookie appears in quotes. =for example begin ok "$cookie" eq $cookie->as_string; =for example end =for example_testing ok substr("$cookie", 0, 8) eq "foo=bar;"; =head2 name $cookie->name() Get the name of the cookie. =for example_testing ok $cookie->name eq "foo"; =head2 value $cookie->value() Get the (unswizzled) value of the cookie: =for example begin my $value = $cookie->value; my @values = $cookie->value; =for example end =for example_testing ok @values == 1, '@values == 1'; ok $value eq "bar", '$value eq "bar"'; ok $values[0] eq "bar", '$values[0] eq "bar"'; Note: if the cookie's value was created using a C method, one way to reconstitute the object is by subclassing Apache::Cookie with a package that provides the associated C sub: =for example begin { package My::COOKIE; @ISA = 'Apache::Cookie'; sub thaw { my $val = shift->raw_value; $val =~ tr/a-z/A-Z/; $val } } bless $cookie, "My::COOKIE"; ok $cookie->value eq "BAR"; =for example end =head2 raw_value $cookie->raw_value() Gets the raw (opaque) value string as it appears in the incoming "Cookie" header. =for example begin ok $cookie->raw_value eq "bar"; =for example end =for example_testing # run the example, don't just compile it =head2 bake $cookie->bake() Adds a I header to the outgoing headers table. =head2 bake2 $cookie->bake2() Adds a I header to the outgoing headers table. =head2 domain $cookie->domain() $cookie->domain($set) Get or set the domain for the cookie: =for example begin $domain = $cookie->domain; $cookie->domain(".cp.net"); =for example end =for example_testing ok $domain eq ".capricorn.com"; ok $cookie->domain eq ".cp.net"; =head2 path $cookie->path() $cookie->path($set) Get or set the path for the cookie: =for example begin $path = $cookie->path; $cookie->path("/"); =for example end =for example_testing ok $path eq "/cgi-bin/database"; ok $cookie->path eq "/"; =head2 version $cookie->version() $cookie->version($set) Get or set the cookie version for this cookie. Netscape spec cookies have version = 0; RFC-compliant cookies have version = 1. =for example begin ok $cookie->version == 0; $cookie->version(1); ok $cookie->version == 1; =for example end =for example_testing # run the example tests =head2 expires $cookie->expires() $cookie->expires($set) Get or set the future expire time for the cookie. When assigning, the new value ($set) should match /^\+?(\d+)([YMDhms]?)$/ $2 qualifies the number in $1 as representing "Y"ears, "M"onths, "D"ays, "h"ours, "m"inutes, or "s"econds (if the qualifier is omitted, the number is interpreted as representing seconds). As a special case, $set = "now" is equivalent to $set = "0". =for example begin my $expires = $cookie->expires; $cookie->expires("+3h"); # cookie is set to expire in 3 hours =for example end =for example_testing ok $expires == 3 * 30 * 24 * 3600; # 3 months ok $cookie->expires == 3 * 3600; =head2 secure $cookie->secure() $cookie->secure($set) Get or set the secure flag for the cookie: =for example begin $cookie->secure(1); $is_secure = $cookie->secure; $cookie->secure(0); =for example end =for example_testing ok $is_secure; ok (not $cookie->secure); =head2 comment $cookie->comment() $cookie->comment($set) Get or set the comment field of an RFC (Version > 0) cookie. =for example begin $cookie->comment("Never eat yellow snow"); print $cookie->comment; =for example end =for example_testing ok $_STDOUT_ eq "Never eat yellow snow"; =head2 commentURL $cookie->commentURL() $cookie->commentURL($set) Get or set the commentURL field of an RFC (Version > 0) cookie. =for example begin $cookie->commentURL("http://localhost/cookie.policy"); print $cookie->commentURL; =for example end =for example_testing ok $_STDOUT_ eq "http://localhost/cookie.policy"; =head2 fetch Apache::Cookie->fetch($r) Fetch and parse the incoming I header: =for example begin my $cookies = Apache::Cookie->fetch($r); # Apache::Cookie::Table ref my %cookies = Apache::Cookie->fetch($r); =for example end =for example_testing ok "foobarfoo" eq join "", keys %$cookies; ok 123 == join "", map $_->value, values %$cookies; ok "barfoo" eq join "", sort keys %cookies; # %cookies lost original foo cookie ok 23 == join "", sort map $_->value, values %cookies; =head1 PORTING from 1.X Changes to the 1.X API: =over 4 =item * C now expects an C<$r> object as (second) argument, although this isn't necessary in mod_perl 2 if C is loaded. =item * C is gone. =item * C no longer encodes the supplied cookie name. =item * C and C no longer accept a "set" argument. In other words, neither a cookie's name, nor its value, may be modified. A new cookie should be made instead. =back =head1 SEE ALSO L, L, L, L, CGI::Cookie(3) =head1 COPYRIGHT Copyright 2003-2005 The Apache Software Foundation Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. rapache-1.2.8/libapreq2/glue/perl/docs/Error.pod0000644000175100017510000000645112706745114020774 0ustar ondrejondrej=head1 NAME Apache::*::Error - Exception classes for Apache::Request, Apache::Upload, Apache::Cookie::Jar and Apache::Cookie =for testing use Apache::Upload; use Apache::Cookie; use APR::Error; use APR::Pool; $r = APR::Pool->new; $req = Apache::Request->new($r); $req->body_status(0); $req->parse; # XXX sets up body table $u = Apache::Upload->new($r, name => "foo", file => __FILE__); $req->body->add($u); $jar = Apache::Cookie::Jar->new($r); $c = Apache::Cookie->new($r, name => "foo", value => "1"); $jar->cookies->add($c); =head1 SYNOPSIS =for example begin $req = Apache::Request->new($r); $jar = Apache::Cookie::Jar->new($r); $req->args_status(1); # artificial error status = 1 for I parser $jar->status(2); # artificial error status = 2 for I header parser eval { $req->parse }; ok $@->isa("Apache::Request::Error"); ok $@ == 1; eval { @cookies = $jar->cookies }; ok $@->isa("Apache::Cookie::Jar::Error"); ok $@ == 2; @cookies = $@->cookies; # same method does not fail on Error object =for example end =for example_testing ok @cookies == 1; =head1 DESCRIPTION This manpage documents the Apache::*::Error classes provided by the Apache::Request, Apache::Upload, and Apache::Cookie modules. Error classes are all derived from APR::Error and the class which first produced the error. Unlike the object that created it, an Error object will not itself throw an error by calling its methods. =head1 Apache::Request::Error These exceptions are derived from APR::Error and Apache::Request, and indicate that an error occurred during param parsing. =for example begin =for example end =for example_testing =head1 Apache::Upload::Error These exceptions are derived from APR::Error and Apache::Upload, and indicate that some Apache::Upload method failed (often caused by a filesystem error). =for example begin =for example end =for example_testing =head1 Apache::Cookie::Jar::Error These exceptions are derived from APR::Error and Apache::Cookie::Jar, and indicate that the cookie parser failed to successfully parse the incoming Cookie header. =for example begin =for example end =for example_testing =head1 Apache::Cookie::Error These exceptions are derived from APR::Error and Apache::Cookie. Their presence indicates that an Apache::Cookie method failed. Typically they are caused by 1) attempting to bake(2) a non-compliant cookie, 2) attempting to set an unsupported cookie attribute. =for example begin =for example end =for example_testing =head1 SEE ALSO L, L, L APR::Error(3) =head1 COPYRIGHT Copyright 2003-2005 The Apache Software Foundation Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. rapache-1.2.8/libapreq2/glue/perl/docs/Request.pod0000644000175100017510000003560412706745114021335 0ustar ondrejondrej=head1 NAME Apache::Request - Methods for dealing with client request data =for testing use Apache::Request; use Apache::Upload; use APR::Pool; $r = APR::Pool->new; $req = Apache::Request->new($r); $u = Apache::Upload->new($r, name => "foo", file => __FILE__); $req->body_status(0); $req->parse; $req->body->add($u); $req->args->add(foo => 1); $req->args->add(bar => 2); $req->args->add(foo => 3); =head1 SYNOPSIS =for example begin use Apache::Request; $req = Apache::Request->new($r); @foo = $req->param("foo"); $bar = $req->args("bar"); =for example end =for example_testing ok $req->isa("Apache::Request"); is "@foo", join " ", 1, 3, __FILE__; is $bar, 2; =head1 DESCRIPTION The Apache::Request module provides methods for parsing GET and POST parameters encoded with either I or I. Although Apache::Request provides a few new APIs for accessing the parsed data, it remains largely backwards-compatible with the original 1.X API. See the L section below for a list of known issues. This manpage documents the Apache::Request package. Apache::Request::Table and Apache::Request::Error are also provided by this module, but are documented elsewhere. Please read the L section below for a list of related manpages. =head1 Apache::Request The interface is designed to mimic the CGI.pm routines for parsing query parameters. The main differences are =over 4 =item * C takes an environment-specific object C<$r> as (second) argument. Newer versions of CGI.pm also accept this syntax within modperl. =item * The query parameters are stored in APR::Table derived objects, and are therefore retrieved from the table by using case-insensitive keys. =item * The query string is always parsed immediately, even for POST requests. =back =head2 new Apache::Request->new($r, %args) Creates a new Apache::Request object. =for example begin my $req = Apache::Request->new($r, POST_MAX => "1M"); =for example end =for example_testing ok ref $req; ok $req->isa("Apache::Request"); With mod_perl2, the environment object $r must be an Apache::RequestRec object. In that case, all methods from Apache::RequestRec are inherited. In the (default) CGI environment, $r must be an APR::Pool object. The following args are optional: =over 4 =item * C, C Limit the size of POST data (in bytes). =item * C Disable file uploads. =item * C Sets the directory where upload files are spooled. On a *nix-like that supports I, the TEMP_DIR should be located on the same file system as the final destination file: =for example begin use Apache::Upload; my $req = Apache::Request->new($r, TEMP_DIR => "/home/httpd/tmp"); my $upload = $req->upload('file'); $upload->link("/home/user/myfile"); =for example end For more details on C, see L. =item * C Extra configuration info passed as the fourth argument to an upload hook. See the description for the next item, C. =item * C Sets up a callback to run whenever file upload data is read. This can be used to provide an upload progress meter during file uploads. Apache will automatically continue writing the original data to $upload->fh after the hook exits. =for example begin my $transparent_hook = sub { my ($upload, $data, $data_len, $hook_data) = @_; warn "$hook_data: got $data_len bytes for " . $upload->name; }; my $req = Apache::Request->new($r, HOOK_DATA => "Note", UPLOAD_HOOK => $transparent_hook, ); =for example end =back =head2 instance Apache::Request->instance($r) The default (and only) behavior of I is to intelligently cache B data for the duration of the request. Thus there is no longer the need for a separate C method as existed in I for Apache 1.3 - all B data is always available from each and every I object created during the request's lifetime. However an C method is aliased to C in this release to ease the pain of porting from 1.X to 2.X. =head2 param $req->param() $req->param($name) Get the request parameters (using case-insensitive keys) by mimicing the OO interface of C. =for example begin # similar to CGI.pm my $foo_value = $req->param('foo'); my @foo_values = $req->param('foo'); my @param_names = $req->param; # the following differ slightly from CGI.pm # returns ref to Apache::Request::Table object representing # all (args + body) params my $table = $req->param; @table_keys = keys %$table; =for example end =for example_testing is $foo_value, 1; is "@foo_values", join " ", 1, 3, __FILE__; is "@param_names", "foo bar"; is "@table_keys", "foo bar foo foo"; In list context, or when invoked with no arguments as C<< $req->param() >>, C induces libapreq2 to read and parse all remaining data in the request body. However, C<< scalar $req->param("foo") >> is lazy: libapreq2 will only read and parse more data if 1) no "foo" param appears in the query string arguments, AND 2) no "foo" param appears in the previously parsed POST data. In this circumstance libapreq2 will read and parse additional blocks of the incoming request body until either 1) it has found the the "foo" param, or 2) parsing is completed. Observe that C<< scalar $req->param("foo") >> will not raise an exception if it can locate "foo" in the existing body or args tables, even if the query-string parser or the body parser has failed. In all other circumstances C will throw an Apache::Request::Error object into $@ should either parser fail. =for example begin $req->args_status(1); # set error state for query-string parser ok $req->param_status == 1; $foo = $req->param("foo"); ok $foo == 1; eval { @foo = $req->param("foo") }; ok $@->isa("Apache::Request::Error"); undef $@; eval { my $not_found = $req->param("non-existent-param") }; ok $@->isa("Apache::Request::Error"); $req->args_status(0); # reset query-string parser state to "success" =for example end =for example_testing # run example Note: modifications to the C<< scalar $req->param() >> table only affect the returned table object (the underlying C apr_table_t is I from the parse data by apreq_params()). Modifications do not affect the actual request data, and will not be seen by other libapreq2 applications. =head2 parms, params The functionality of these functions is assumed by C, so they are no longer necessary. Aliases to C are provided in this release for backwards compatibility, however they are deprecated and may be removed from a future release. =head2 args $req->args() $req->args($name) Returns an I object containing the query-string parameters of the I object. =for example begin my $args = $req->args; =for example end =for example_testing my $n = 0; while (($a, $b) = each %$args) { is $a, (qw/foo bar foo/)[$n]; is $b, ++$n; } An optional name parameter can be passed to return the query string parameter associated with the given name: =for example begin my $foo_arg = $req->args("foo"); =for example end =for example_testing is $foo_arg, 1; More generally, C follows the same pattern as C with respect to its return values and argument list. The main difference is that modifications to the C<< scalar $req->args() >> table affect the underlying apr_table_t attribute in apreq_request_t, so their impact will be noticed by all libapreq2 applications during this request. =head2 body $req->body() $req->body($name) Returns an I object containing the POST data parameters of the I object. =for example begin my $body = $req->body; =for example end =for example_testing is join(" ", keys %$body), "foo"; is join(" ", values %$body), __FILE__; An optional name parameter can be passed to return the POST data parameter associated with the given name: =for example begin my $foo_body = $req->body("foo"); =for example end =for example_testing is $foo_body, __FILE__; More generally, C follows the same pattern as C with respect to its return values and argument list. The main difference is that modifications to the C<< scalar $req->body() >> table affect the underlying apr_table_t attribute in apreq_request_t, so their impact will be noticed by all libapreq2 applications during this request. =head2 upload $req->upload() $req->upload($name) Requires C. With no arguments, this method returns an I object in scalar context, or the names of all I objects in list context. An optional name parameter can be passed to return the I object associated with the given name: my $upload = $req->upload($name); More generally, C follows the same pattern as C with respect to its return values and argument list. The main difference is that its returned values are Apache::Upload object refs, not simple scalars. Note: modifications to the C<< scalar $req->upload() >> table only affect the returned table object (the underlying C apr_table_t is I by apreq_uploads()). They do not affect the actual request data, and will not be seen by other libapreq2 applications. =head2 args_status $req->args_status() $req->args_status($set) Get/set the I status code of the query-string parser. APR_SUCCESS on success, error otherwise. =for testing is $req->args_status, 0; # APR_SUCCESS =head2 body_status $req->body_status() $req->body_status($set) Get/set the current I status code of the parsed POST data. APR_SUCCESS when parser has completed, APR_INCOMPLETE if parser has more data to parse, APR_EINIT if no post data has been parsed, error otherwise. =for testing is $req->body_status, 0; # APR_SUCCESS =head2 param_status $req->param_status() In scalar context, this returns C if there was an error during the query-string parse, otherwise this returns C, ie $req->args_status || $req->body_status In list context C returns the list C<(args_status, body_status)>. =for testing is scalar($req->param_status), $req->args_status || $req->body_status; is join(" ", $req->param_status), join(" ", $req->args_status, $req->body_status); =head2 parse $req->parse() Forces the request to be parsed immediately. In void context, this will throw an Apache::Request::Error should the either the query-string or body parser fail. In all other contexts it will return the two parsers' combined I status code $req->body_status || $req->args_status =for testing is $req->parse, $req->body_status || $req->args_status; However C should be avoided in most normal situations. For example, in a mod_perl content handler it is more efficient to write sub handler { my $r = shift; my $req = Apache::Request->new($r); $r->discard_request_body; # efficiently parses the request body my $parser_status = $req->body_status; #... } Calling C<< $r->discard_request_body >> outside the content handler is generally a mistake, so use C<< $req->parse >> there, but B. The Apache::Request API is B around a lazy-parsing scheme, so calling C should not affect the behavior of any other methods. =head1 SUBCLASSING Apache::Request If the instances of your subclass are hash references then you can actually inherit from Apache::Request as long as the Apache::Request object is stored in an attribute called "r" or "_r". (The Apache::Request class effectively does the delegation for you automagically, as long as it knows where to find the Apache::Request object to delegate to.) For example: package MySubClass; use Apache::Request; our @ISA = qw(Apache::Request); sub new { my($class, @args) = @_; return bless { r => Apache::Request->new(@args) }, $class; } =head1 PORTING from 1.X This is the complete list of changes to existing methods from Apache::Request 1.X. These issues need to be addressed when porting 1.X apps to the new 2.X API. =over 4 =item * Apache::Upload is now a separate module. Applications requiring the upload API must C in 2.X. This is easily addressed by preloading the modules during server startup. =item * You must use the C API via C<< scalar $req->args >> or C<< scalar $req->body >> to assign new parameters to the request. You may no longer use the two-argument method calls; e.g. $req->param("foo" => "bar"); # NO: usage error in 2.X $req->args->{foo} = "bar"; # OK: assign to args table $req->body->add(foo => "bar"); # OK: add to body table $req->param->add(foo => "bar"); # NO: this is an expensive noop, # because the param table is # generated by overlaying $req->args # and $req->body. my $params = $req->param; $params->set(foo => "bar"); # OK: sets "foo" entry in $params, which # is a local (args + body) table. Neither # $req->args, $req->body, nor future calls # to $req->param, are affected by mods to # $params. =item * C is now identical to C, and is now deprecated. It may be removed from a future 2.X release. =item * C includes the functionality of C and C, so they are now deprecated and may be removed from a future 2.X release. =back =head1 SEE ALSO L, L, L, L, APR::Table(3). =head1 COPYRIGHT Copyright 2003-2005 The Apache Software Foundation Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. rapache-1.2.8/libapreq2/glue/perl/docs/Table.pod0000644000175100017510000000622712706745114020733 0ustar ondrejondrej=head1 NAME Apache::*::Table - Table classes for Apache::Request, Apache::Upload, and Apache::Cookie. =for testing use Apache::Upload; use Apache::Cookie; use APR::Pool; use APR::Table; $r = APR::Pool->new; # environment object =head1 SYNOPSIS =for example begin my $table = Apache::Request::Table->new($r); $table->{test} = 1; $table->{foo} = "bar1"; $table->add(foo => "bar2"); { my $do_data = ""; $table->do( sub { $do_data .= "@_,"; 1 } ); ok $do_data eq "test 1,foo bar1,foo bar2,"; } =for example end =for example_testing #run the above tests, don't just compile them =head1 DESCRIPTION This manpage documents the Apache::*::Table classes provided by the Apache::Request, Apache::Upload, and Apache::Cookie modules. Table classes are all derived from APR::Table, however since the underlying values they contain are not simple character arrays, the C, C, and C methods from APR::Table are not implemented. =head1 Apache::Request::Table These tables arise as parameter tables generated by the C, C, and C methods of Apache::Request. Their values are representable by orinary perl scalars, but unlike APR::Table, the '\0' character may be safely embedded in a value without truncating it. =for example begin my $table = Apache::Request::Table->new($r); my $value = "bar\0quux"; $table->{foo} = $value; =for example end =for example_testing is $table->{foo}, $value; =head1 Apache::Upload::Table These tables arise from the C method (which is provided by Apache::Upload). Their values are Apache::Upload objects. =for example begin my $upload = Apache::Upload->new($r, name => "foo", file => __FILE__); my $table = Apache::Upload::Table->new($r); $table->add($upload); $upload = $table->{foo}; =for example end =for example_testing ok $upload->isa("Apache::Upload"); =head1 Apache::Cookie::Table These tables arise from the C method of Apache::Cookie::Jar, and their values are Apache::Cookie objects (or Apache::Cookie derived objects- see the discussion of C in L). =for example begin my $cookie = Apache::Cookie->new($r, name =>"foo", value => "bar"); my $table = Apache::Cookie::Table->new($r); $table->{foo} = $cookie; $cookie = $table->{foo}; =for example end ok $cookie->isa("Apache::Cookie"); =for example_testing =head1 SEE ALSO L, L, L APR::Table(3) =head1 COPYRIGHT Copyright 2003-2005 The Apache Software Foundation Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. rapache-1.2.8/libapreq2/glue/perl/docs/Upload.pod0000644000175100017510000002005212706745114021120 0ustar ondrejondrej=head1 NAME Apache::Upload - Methods for dealing with file uploads. =for testing use APR::Pool; use Apache::Upload; $r = APR::Pool->new; $req = Apache::Request->new($r); $u = Apache::Upload->new($r, name => "foo", file => __FILE__); $req->body_status(0); $req->parse; $req->body->add(foo => "bar"); # dummy param with same name as upload $req->body->add($u); open(my $fh, __FILE__) or die $!; binmode $fh; { local $/; $data = <$fh>; } close $fh; ok length $data == -s __FILE__; $data =~ s{\r}{}g; =head1 SYNOPSIS =for example begin use Apache::Upload; $req = Apache::Request->new($r); $upload = $req->upload("foo"); $size = $upload->size; # three methods to get at the upload's contents ... slurp, fh, io $upload->slurp($slurp_data); read $upload->fh, $fh_data, $size; ok $slurp_data eq $fh_data; my $io = $upload->io; print while <$io>; =for example end =for example_testing ok $upload->bb->length == $size; $uploads = $req->upload(); is (scalar keys %{$uploads}, 1, "found upload"); is $_STDOUT_, $data; is $fh_data, $data; is $slurp_data, $data; =head1 DESCRIPTION Apache::Upload is a new module based on the original package included in Apache::Request 1.X. Users requiring the upload API must now C, which adds the C method to Apache::Request. Apache::Upload is largely backwards-compatible with the original 1.X API. See the L section below for a list of known issues. This manpage documents the Apache::Upload and Apache::Upload::Brigade packages. Apache::Upload::Table and Apache::Upload::Error are also provided by this module, but are documented elsewhere. For a list of related manpages, read the L section below. =head1 Apache::Upload =head2 name $upload->name() The name of the HTML form element which generated the upload. =for testing is $u->name, "foo"; =head2 filename $upload->filename() The (client-side) filename as submitted in the HTML form. Note: some agents will submit the file's full pathname, while others may submit just the basename. =for testing is $u->filename, __FILE__; =head2 fh $upload->fh() Creates filehandle reference to the upload's spooled tempfile, which contains the full contents of the upload. =head2 io $upload->io() Creates a tied IO handle. This method is a more efficient version of C, but with C the handle ref returned is not seekable. It is tied to an Apache::Upload::Brigade object, so you may use the brigade API on the tied object if you want to manipulate the IO stream (beyond simply reading from it). The returned reference is actually an object which has C and C methods available. However these methods are just syntactic sugar for the underlying C and C methods from Apache::Upload::Brigade. =for example begin $io = $upload->io; print while $io->read($_); # equivalent to: tied(*$io)->READ($_) =for example end =for example_testing is $_STDOUT_, $data; $io = $upload->io; $io->read($h{io}, $upload->size); is $h{io}, $data, "autovivifying read"; See L and L below for additional notes on their usage. =head2 bb $upload->bb() $upload->bb($set) Get/set the APR::Brigade which represents the upload's contents. =head2 size $upload->size() Returns the size of the upload in bytes. =for testing is $u->size, -s __FILE__; =head2 info $upload->info() $upload->info($set) Get/set the additional header information table for the uploaded file. Returns a hash reference tied to the I class. An optional C<$table> argument can be passed to reassign the upload's internal (apr_table_t) info table to the one C<$table> represents. =for example begin my $info = $upload->info; while (my($hdr_name, $hdr_value) = each %$info) { # ... } # fetch upload's Content-Type header my $type = $upload->info->{"Content-type"}; =for example end =for example_testing is $type, "application/octet-stream"; =head2 type $upload->type() Returns the MIME type of the given I object. =for example begin my $type = $upload->type; #same as my $content_type = $upload->info->{"Content-Type"}; $content_type =~ s/;.*$//ms; =for example end =for example_testing is $type, $content_type; =head2 link $upload->link() To avoid recopying the upload's internal tempfile brigade on a *nix-like system, I will create a hard link to it: =for example begin my $upload = $req->upload('foo'); $upload->link("/path/to/newfile") or die sprintf "link from '%s' failed: $!", $upload->tempname; =for example end Typically the new name must lie on the same device and partition as the brigade's tempfile. If this or any other reason prevents the OS from linking the files, C will instead copy the temporary file to the specified location. =head2 slurp $upload->slurp($contents) Reads the full contents of a file upload into the scalar argument. The return value is the length of the file. =for example begin my $size = $upload->slurp($contents); =for example end =for example_testing is $size, length $contents; $upload->slurp($h{slurp}); is $h{slurp}, $contents, "autovivifying slurp"; $contents =~ s{\r}{}g; is $contents, $data; =head2 tempname $upload->tempname() Provides the name of the spool file. =for example begin my $tempname = $upload->tempname; =for example end =for example_testing like $tempname, qr/apreq.{6}$/; =head1 Apache::Upload::Brigade This class is derived from APR::Brigade, providing additional methods for TIEHANDLE, READ and READLINE. To be memory efficient, these methods delete buckets from the brigade as soon as their data is actually read, so you cannot C on handles tied to this class. Such handles have semantics similar to that of a read-only socket. =head2 TIEHANDLE Apache::Upload::Brigade->TIEHANDLE($bb) Creates a copy of the bucket brigade represented by $bb, and blesses that copy into the Apache::Upload::Brigade class. This provides syntactic sugar for using perl's builtin C, C, and C<< <> >> operations on handles tied to this package: use Symbol; $fh = gensym; tie *$fh, "Apache::Upload:Brigade", $bb; print while <$fh>; =head2 READ $bb->READ($contents) $bb->READ($contents, $length) $bb->READ($contents, $length, $offset) Reads data from the brigade $bb into $contents. When omitted $length defaults to C<-1>, which reads the first bucket into $contents. A positive $length will read in $length bytes, or the remainder of the brigade, whichever is greater. $offset represents the index in $context to read the new data. =head2 READLINE $bb->READLINE() Returns the first line of data from the bride. Lines are terminated by linefeeds (the '\012' character), but we may eventually use C<$/> instead. =head1 PORTING from 1.X =over 4 =item * C<< $upload->next() >> is no longer available; please use the C<< Apache::Upload::Table >> API when iterating over upload entries. =item * C is replaced by C. =item * C returns only the MIME-type portion of the Content-Type header. =back =head1 SEE ALSO L, L, L, APR::Table(3) =head1 COPYRIGHT Copyright 2003-2005 The Apache Software Foundation Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. rapache-1.2.8/libapreq2/glue/perl/lib/0000755000175100017510000000000012706745114017007 5ustar ondrejondrejrapache-1.2.8/libapreq2/glue/perl/lib/Apache2/0000755000175100017510000000000012706745114020252 5ustar ondrejondrejrapache-1.2.8/libapreq2/glue/perl/lib/Apache2/Cookie.pm0000644000175100017510000003775512706745114022042 0ustar ondrejondrejpackage Apache2::Cookie; use APR::Table; use APR::Pool; use APR::Request::Cookie; use APR::Request::Apache2; use APR::Request qw/encode decode/; use Apache2::RequestRec; use overload '""' => sub { shift->as_string() }, fallback => 1; push our @ISA, "APR::Request::Cookie"; our $VERSION = "2.05-dev"; sub new { my ($class, $r, %attrs) = @_; my $name = delete $attrs{name}; my $value = delete $attrs{value}; $name = delete $attrs{-name} unless defined $name; $value = delete $attrs{-value} unless defined $value; return unless defined $name and defined $value; my $cookie = $class->make($r->pool, $name, $class->freeze($value)); while(my ($k, $v) = each %attrs) { $k =~ s/^-//; $cookie->$k($v); } return $cookie; } sub fetch { my $class = shift; my $req = shift; unless (defined $req) { my $usage = 'Usage: Apache2::Cookie->fetch($r): missing argument $r'; $req = eval {Apache2->request} or die <request failed: $@. EOD } $req = APR::Request::Apache2->handle($req) unless $req->isa("APR::Request"); my $jar = $req->jar or return; $jar->cookie_class(__PACKAGE__); return wantarray ? %$jar : $jar; } sub set_attr { my ($cookie, %attrs) = @_; while (my ($k, $v) = each %attrs) { $k =~ s/^-//; $cookie->$k($v); } } sub freeze { my ($class, $value) = @_; die 'Usage: Apache2::Cookie->freeze($value)' unless @_ == 2; if (not ref $value) { return encode($value); } elsif (UNIVERSAL::isa($value, "ARRAY")) { return join '&', map encode($_), @$value; } elsif (UNIVERSAL::isa($value, "HASH")) { return join '&', map encode($_), %$value; } die "Can't freeze reference: $value"; } sub thaw { my $c = shift; my @rv = split /&/, @_ ? shift : $c->SUPER::value; return wantarray ? map decode($_), @rv : decode($rv[0]); } sub value { return shift->thaw; } sub bake { my ($c, $r) = @_; $r->err_headers_out->add("Set-Cookie", $c->as_string); } sub bake2 { my ($c, $r) = @_; die "Can't bake2 a Netscape cookie: $c" unless $c->version > 0; $r->err_headers_out->add("Set-Cookie2", $c->as_string); } package Apache2::Cookie::Jar; use APR::Request::Apache2; push our @ISA, qw/APR::Request::Apache2/; sub cookies { Apache2::Cookie->fetch(shift) } *Apache2::Cookie::Jar::status = *APR::Request::jar_status; my %old_args = ( value_class => "cookie_class", ); sub new { my $class = shift; my $jar = $class->APR::Request::Apache2::handle(shift); my %attrs = @_; while (my ($k, $v) = each %attrs) { $k =~ s/^-//; my $method = $old_args{lc($k)} || lc $k; $jar->$method($v); } return $jar; } 1; __END__ =head1 NAME Apache2::Cookie, Apache2::Cookie::Jar - HTTP Cookies Class =for testing use Apache2::Cookie; use APR::Pool; # use $r instead of $p here, so doc examples reflect mp2 env, not CGI/test env $r = APR::Pool->new; $j = Apache2::Cookie::Jar->new($r); $j->cookies->{foo} = Apache2::Cookie->new($r, name => "foo", value => "1"); $j->cookies->add( Apache2::Cookie->new($r, name => "bar", value => "2") ); =head1 SYNOPSIS =for example begin use Apache2::Cookie; $j = Apache2::Cookie::Jar->new($r); $c_in = $j->cookies("foo"); # get cookie from request headers $c_out = Apache2::Cookie->new($r, -name => "mycookie", -value => $c_in->name ); $c_out->path("/bar"); # set path to "/bar" $c_out->bake; # send cookie in response headers =for example end =for example_testing ok "foo bar" eq join " ", keys %{$j->cookies}; ok $c_out->as_string eq "mycookie=foo; path=/bar"; ok $c_in->value == 1; =head1 DESCRIPTION The Apache2::Cookie module is based on the original 1.X versions, which mimic the CGI::Cookie API. The current version of this module includes several packages and methods which are patterned after Apache2::Request, yet remain largely backwards-compatible with the original 1.X API (see the L section below for known issues). This manpage documents the Apache2::Cookie and Apache2::Cookie::Jar packages. =head1 Apache2::Cookie::Jar This class collects Apache2::Cookie objects into a lookup table. It plays the same role for accessing the incoming cookies as Apache2::Request does for accessing the incoming params and file uploads. =head2 new Apache2::Cookie::Jar->new($env, %args) Class method that retrieves the parsed cookie jar from the current environment. An optional VALUE_CLASS => $class argument instructs the jar to bless any returned cookies into $class instead of Apache2::Cookie. This feature is meant to be useful in situations where C is unable to correctly interpret an incoming cookie's serialization. Users can simply override C in an application-specific subclass and pass that subclass's name as the VALUE_CLASS argument: =for example begin { package FOO; @ISA= 'Apache2::Cookie'; } my $jar = Apache2::Cookie::Jar->new($r, VALUE_CLASS => "FOO"); ok $jar->cookies("foo")->isa("FOO"); ok $jar->cookies->{bar}->isa("FOO"); =for example end =for example_testing ok $jar->isa("Apache2::Cookie::Jar"); $jar->cookies->do(sub { ok $_[1]->isa("FOO"); }); map { ok $_->isa("FOO") } values %{$jar->cookies}; =head2 cookies $jar->cookies() $jar->cookies($key) Retrieve cookies named $key with from the jar object. In scalar context the first such cookie is returned, and in list context the full list of such cookies are returned. If the $key argument is omitted, C<< scalar $jar->cookies() >> will return an APR::Request::Cookie::Table object containing all the cookies in the jar. Modifications to the this object will affect the jar's internal I table in C, so their impact will be noticed by all libapreq2 applications during this request. In list context C<< $jar->cookies() >> returns the list of names for all the cookies in the jar. The order corresponds to the order in which the cookies appeared in the incoming "Cookie" header. This method will throw an C<< APR::Request::Error >> object into $@ if the returned value(s) could be unreliable. In particular, note that C<< scalar $jar->cookies("foo") >> will not croak if it can locate the a "foo" cookie within the jar's parsed cookie table, even if the cookie parser has failed (the cookies are parsed in the same order as they appeared in the "Cookie" header). In all other circumstances C will croak if the parser failed to successfully parse the "Cookie" header. =for example begin $c = Apache2::Cookie->new($r, name => "foo", value => 3); $j->cookies->add($c); $cookie = $j->cookies("foo"); # first foo cookie @cookies = $j->cookies("foo"); # all foo cookies @names = $j->cookies(); # all cookie names =for example end =for example_testing ok @cookies == 2; is $_ -> name, "foo" for $cookie, @cookies; ok $cookies[0]->value eq $cookie->value; ok $cookies[0]->value == 1; ok $cookies[1]->value == 3; is "@names", "foo bar"; =head2 status $jar->status() $jar->status($set) Get or set the I status code of the cookie parser: APR_SUCCESS on success, error otherwise. =for example begin $j->status(-1); ok $j->status == -1; eval { @cookies = $j->cookies("foo") }; # croaks ok $@->isa("Apache2::Cookie::Jar::Error"); $j->status(0); =for example end =for example_testing ok $j->status == 0, '$j->status == 0'; @cookies = $j->cookies("foo"); ok @cookies == 2, '@cookies == 2'; =head1 Apache2::Cookie =head2 new Apache2::Cookie->new($env, %args) Just like CGI::Cookie::new, but requires an additional environment argument: =for example begin $cookie = Apache2::Cookie->new($r, -name => 'foo', -value => 'bar', -expires => '+3M', -domain => '.capricorn.com', -path => '/cgi-bin/database', -secure => 1 ); =for example end =for example_testing ok $cookie->name eq "foo", 'name eq "foo"'; ok $cookie->value eq "bar", 'value eq "bar"'; ok $cookie->domain eq ".capricorn.com", 'domain eq ".capricorn.com"'; ok $cookie->path eq "/cgi-bin/database",'path eq "/cgi-bin/database"'; ok $cookie->secure == 1, '$cookie->secure == 1'; The C<-value> argument may be either an arrayref, a hashref, or a string. C encodes this argument into the cookie's raw value. =head2 freeze Apache2::Cookie->freeze($value) Helper function (for C) that serializes a new cookie's value in a manner compatible with CGI::Cookie (and Apache2::Cookie 1.X). This class method accepts an arrayref, hashref, or normal perl string in $value. =for example begin $value = Apache2::Cookie->freeze(["2+2", "=4"]); =for example end =for example_testing ok $value eq "2%2b2&%3d4", '$value eq "2%2b2&%3d4"'; =head2 thaw Apache2::Cookie->thaw($value) $cookie->thaw() This is the helper method (for C) responsible for decoding the raw value of a cookie. An optional argument $value may be used in place of the cookie's raw value. This method can also decode cookie values created using CGI::Cookie or Apache2::Cookie 1.X. =for example begin print $cookie->thaw; # prints "bar" @values = Apache2::Cookie->thaw($value); # ( "2+2", "=4" ) =for example end =for example_testing ok $_STDOUT_ eq "bar", '$_STDOUT_ eq "bar"'; ok @values == 2, '@values == 2'; ok $values[0] eq "2+2", '$values[0] eq "2+2"'; ok $values[1] eq "=4", '$values[1] eq "=4"'; =head2 as_string $cookie->as_string() Format the cookie object as a string. The quote-operator for Apache2::Cookie is overloaded to run this method whenever a cookie appears in quotes. =for example begin ok "$cookie" eq $cookie->as_string; =for example end =for example_testing ok substr("$cookie", 0, 8) eq "foo=bar;"; =head2 name $cookie->name() Get the name of the cookie. =for example_testing ok $cookie->name eq "foo"; =head2 value $cookie->value() Get the (unswizzled) value of the cookie: =for example begin my $value = $cookie->value; my @values = $cookie->value; =for example end =for example_testing ok @values == 1, '@values == 1'; ok $value eq "bar", '$value eq "bar"'; ok $values[0] eq "bar", '$values[0] eq "bar"'; Note: if the cookie's value was created using a C method, one way to reconstitute the object is by subclassing Apache2::Cookie with a package that provides the associated C sub: =for example begin { package My::COOKIE; @ISA = 'Apache2::Cookie'; sub thaw { my $val = shift->raw_value; $val =~ tr/a-z/A-Z/; $val } } bless $cookie, "My::COOKIE"; ok $cookie->value eq "BAR"; =for example end =head2 raw_value $cookie->raw_value() Gets the raw (opaque) value string as it appears in the incoming "Cookie" header. =for example begin ok $cookie->raw_value eq "bar"; =for example end =for example_testing # run the example, don't just compile it =head2 bake $cookie->bake($r) Adds a I header to the outgoing headers table. =head2 bake2 $cookie->bake2($r) Adds a I header to the outgoing headers table. =head2 domain $cookie->domain() $cookie->domain($set) Get or set the domain for the cookie: =for example begin $domain = $cookie->domain; $cookie->domain(".cp.net"); =for example end =for example_testing ok $domain eq ".capricorn.com"; ok $cookie->domain eq ".cp.net"; =head2 path $cookie->path() $cookie->path($set) Get or set the path for the cookie: =for example begin $path = $cookie->path; $cookie->path("/"); =for example end =for example_testing ok $path eq "/cgi-bin/database"; ok $cookie->path eq "/"; =head2 version $cookie->version() $cookie->version($set) Get or set the cookie version for this cookie. Netscape spec cookies have version = 0; RFC-compliant cookies have version = 1. =for example begin ok $cookie->version == 0; $cookie->version(1); ok $cookie->version == 1; =for example end =for example_testing # run the example tests =head2 expires $cookie->expires() $cookie->expires($set) Get or set the future expire time for the cookie. When assigning, the new value ($set) should match /^\+?(\d+)([YMDhms]?)$/ $2 qualifies the number in $1 as representing "Y"ears, "M"onths, "D"ays, "h"ours, "m"inutes, or "s"econds (if the qualifier is omitted, the number is interpreted as representing seconds). As a special case, $set = "now" is equivalent to $set = "0". =for example begin my $expires = $cookie->expires; $cookie->expires("+3h"); # cookie is set to expire in 3 hours =for example end =for example_testing ok $expires == 3 * 30 * 24 * 3600; # 3 months ok $cookie->expires == 3 * 3600; =head2 secure $cookie->secure() $cookie->secure($set) Get or set the secure flag for the cookie: =for example begin $cookie->secure(1); $is_secure = $cookie->secure; $cookie->secure(0); =for example end =for example_testing ok $is_secure; ok (not $cookie->secure); =head2 comment $cookie->comment() $cookie->comment($set) Get or set the comment field of an RFC (Version > 0) cookie. =for example begin $cookie->comment("Never eat yellow snow"); print $cookie->comment; =for example end =for example_testing ok $_STDOUT_ eq "Never eat yellow snow"; =head2 commentURL $cookie->commentURL() $cookie->commentURL($set) Get or set the commentURL field of an RFC (Version > 0) cookie. =for example begin $cookie->commentURL("http://localhost/cookie.policy"); print $cookie->commentURL; =for example end =for example_testing ok $_STDOUT_ eq "http://localhost/cookie.policy"; =head2 fetch Apache2::Cookie->fetch($r) Fetch and parse the incoming I header: =for example begin my $cookies = Apache2::Cookie->fetch($r); # APR::Request::Cookie::Table ref my %cookies = Apache2::Cookie->fetch($r); =for example end =for example_testing ok "foobarfoo" eq join "", keys %$cookies; ok 123 == join "", map $_->value, values %$cookies; ok "barfoo" eq join "", sort keys %cookies; # %cookies lost original foo cookie ok 23 == join "", sort map $_->value, values %cookies; =head1 PORTING from 1.X Changes to the 1.X API: =over 4 =item * C now expects an C<$r> object as (second) argument, although this isn't necessary in mod_perl 2 if C is loaded. =item * C is gone. =item * C no longer encodes the supplied cookie name. =item * C and C no longer accept a "set" argument. In other words, neither a cookie's name, nor its value, may be modified. A new cookie should be made instead. =back =head1 SEE ALSO L, L, L, CGI::Cookie(3) =head1 COPYRIGHT Copyright 2003-2005 The Apache Software Foundation Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. rapache-1.2.8/libapreq2/glue/perl/lib/Apache2/Request.pm0000644000175100017510000003501412706745114022243 0ustar ondrejondrejpackage Apache2::Request; use APR::Request::Param; use APR::Request::Apache2; use Apache2::RequestRec; push our @ISA, qw/Apache2::RequestRec APR::Request::Apache2/; our $VERSION = "2.05-dev"; my %old_limits = ( post_max => "read_limit", max_body => "read_limit", ); sub new { my $class = shift; my $req = $class->APR::Request::Apache2::handle(shift); my %attrs = @_; while (my ($k, $v) = each %attrs) { $k =~ s/^-//; my $method = $old_limits{lc($k)} || lc $k; $req->$method($v); } return $req; } sub hook_data {die "hook_data not implemented"} sub disable_uploads { my ($req, $toggle) = @_; $req->SUPER::disable_uploads if $toggle; } 1; __END__ =head1 NAME Apache2::Request - Methods for dealing with client request data =for testing use Apache2::Request; use Apache2::Upload; use APR::Pool; $r = APR::Pool->new; $req = Apache2::Request->new($r); $u = Apache2::Upload->new($r, name => "foo", file => __FILE__); $req->body_status(0); $req->parse; $req->body->add($u); $req->args->add(foo => 1); $req->args->add(bar => 2); $req->args->add(foo => 3); =head1 SYNOPSIS =for example begin use Apache2::Request; $req = Apache2::Request->new($r); @foo = $req->param("foo"); $bar = $req->args("bar"); =for example end =for example_testing ok $req->isa("Apache2::Request"); is "@foo", join " ", 1, 3, __FILE__; is $bar, 2; =head1 DESCRIPTION The Apache2::Request module provides methods for parsing GET and POST parameters encoded with either I or I. Although Apache2::Request provides a few new APIs for accessing the parsed data, it remains largely backwards-compatible with the original 1.X API. See the L section below for a list of known issues. This manpage documents the Apache2::Request package. =head1 Apache2::Request The interface is designed to mimic the CGI.pm routines for parsing query parameters. The main differences are =over 4 =item * C takes an environment-specific object C<$r> as (second) argument. Newer versions of CGI.pm also accept this syntax within modperl. =item * The query parameters are stored in APR::Table derived objects, and are therefore retrieved from the table by using case-insensitive keys. =item * The query string is always parsed immediately, even for POST requests. =back =head2 new Apache2::Request->new($r, %args) Creates a new Apache2::Request object. =for example begin my $req = Apache2::Request->new($r, POST_MAX => "1M"); =for example end =for example_testing ok ref $req; ok $req->isa("Apache2::Request"); With mod_perl2, the environment object $r must be an Apache2::RequestRec object. In that case, all methods from Apache2::RequestRec are inherited. In the (default) CGI environment, $r must be an APR::Pool object. The following args are optional: =over 4 =item * C, C Limit the size of POST data (in bytes). =item * C Disable file uploads. =item * C Sets the directory where upload files are spooled. On a *nix-like that supports I, the TEMP_DIR should be located on the same file system as the final destination file: =for example begin use Apache2::Upload; my $req = Apache2::Request->new($r, TEMP_DIR => "/home/httpd/tmp"); my $upload = $req->upload('file'); $upload->link("/home/user/myfile"); =for example end For more details on C, see L. =item * C Extra configuration info passed as the fourth argument to an upload hook. See the description for the next item, C. =item * C Sets up a callback to run whenever file upload data is read. This can be used to provide an upload progress meter during file uploads. Apache will automatically continue writing the original data to $upload->fh after the hook exits. =for example begin my $transparent_hook = sub { my ($upload, $data, $data_len, $hook_data) = @_; warn "$hook_data: got $data_len bytes for " . $upload->name; }; my $req = Apache2::Request->new($r, HOOK_DATA => "Note", UPLOAD_HOOK => $transparent_hook, ); =for example end =back =head2 instance Apache2::Request->instance($r) The default (and only) behavior of I is to intelligently cache B data for the duration of the request. Thus there is no longer the need for a separate C method as existed in I for Apache 1.3 - all B data is always available from each and every I object created during the request's lifetime. However an C method is aliased to C in this release to ease the pain of porting from 1.X to 2.X. =head2 param $req->param() $req->param($name) Get the request parameters (using case-insensitive keys) by mimicing the OO interface of C. =for example begin # similar to CGI.pm my $foo_value = $req->param('foo'); my @foo_values = $req->param('foo'); my @param_names = $req->param; # the following differ slightly from CGI.pm # returns ref to APR::Request::Param::Table object representing # all (args + body) params my $table = $req->param; @table_keys = keys %$table; =for example end =for example_testing is $foo_value, 1; is "@foo_values", join " ", 1, 3, __FILE__; is "@param_names", "foo bar"; is "@table_keys", "foo bar foo foo"; In list context, or when invoked with no arguments as C<< $req->param() >>, C induces libapreq2 to read and parse all remaining data in the request body. However, C<< scalar $req->param("foo") >> is lazy: libapreq2 will only read and parse more data if 1) no "foo" param appears in the query string arguments, AND 2) no "foo" param appears in the previously parsed POST data. In this circumstance libapreq2 will read and parse additional blocks of the incoming request body until either 1) it has found the the "foo" param, or 2) parsing is completed. Observe that C<< scalar $req->param("foo") >> will not raise an exception if it can locate "foo" in the existing body or args tables, even if the query-string parser or the body parser has failed. In all other circumstances C will throw an Apache2::Request::Error object into $@ should either parser fail. =for example begin $req->args_status(1); # set error state for query-string parser ok $req->param_status == 1; $foo = $req->param("foo"); ok $foo == 1; eval { @foo = $req->param("foo") }; ok $@->isa("Apache2::Request::Error"); undef $@; eval { my $not_found = $req->param("non-existent-param") }; ok $@->isa("Apache2::Request::Error"); $req->args_status(0); # reset query-string parser state to "success" =for example end =for example_testing # run example Note: modifications to the C<< scalar $req->param() >> table only affect the returned table object (the underlying C apr_table_t is I from the parse data by apreq_params()). Modifications do not affect the actual request data, and will not be seen by other libapreq2 applications. =head2 parms, params The functionality of these functions is assumed by C, so they are no longer necessary. Aliases to C are provided in this release for backwards compatibility, however they are deprecated and may be removed from a future release. =head2 body $req->body() $req->body($name) Returns an I object containing the POST data parameters of the I object. =for example begin my $body = $req->body; =for example end =for example_testing is join(" ", keys %$body), "foo"; is join(" ", values %$body), __FILE__; An optional name parameter can be passed to return the POST data parameter associated with the given name: =for example begin my $foo_body = $req->body("foo"); =for example end =for example_testing is $foo_body, __FILE__; More generally, C follows the same pattern as C with respect to its return values and argument list. The main difference is that modifications to the C<< scalar $req->body() >> table affect the underlying apr_table_t attribute in apreq_request_t, so their impact will be noticed by all libapreq2 applications during this request. =head2 upload $req->upload() $req->upload($name) Requires C. With no arguments, this method returns an I object in scalar context, or the names of all I objects in list context. An optional name parameter can be passed to return the I object associated with the given name: my $upload = $req->upload($name); More generally, C follows the same pattern as C with respect to its return values and argument list. The main difference is that its returned values are Apache2::Upload object refs, not simple scalars. Note: modifications to the C<< scalar $req->upload() >> table only affect the returned table object (the underlying C apr_table_t is I by apreq_uploads()). They do not affect the actual request data, and will not be seen by other libapreq2 applications. =head2 args_status $req->args_status() $req->args_status($set) Get/set the I status code of the query-string parser. APR_SUCCESS on success, error otherwise. =for testing is $req->args_status, 0; # APR_SUCCESS =head2 body_status $req->body_status() $req->body_status($set) Get/set the current I status code of the parsed POST data. APR_SUCCESS when parser has completed, APR_INCOMPLETE if parser has more data to parse, APR_EINIT if no post data has been parsed, error otherwise. =for testing is $req->body_status, 0; # APR_SUCCESS =head2 param_status $req->param_status() In scalar context, this returns C if there was an error during the query-string parse, otherwise this returns C, ie $req->args_status || $req->body_status In list context C returns the list C<(args_status, body_status)>. =for testing is scalar($req->param_status), $req->args_status || $req->body_status; is join(" ", $req->param_status), join(" ", $req->args_status, $req->body_status); =head2 parse $req->parse() Forces the request to be parsed immediately. In void context, this will throw an APR::Request::Error should the either the query-string or body parser fail. In all other contexts it will return the two parsers' combined I status code $req->body_status || $req->args_status =for testing is $req->parse, $req->body_status || $req->args_status; However C should be avoided in most normal situations. For example, in a mod_perl content handler it is more efficient to write sub handler { my $r = shift; my $req = Apache2::Request->new($r); $r->discard_request_body; # efficiently parses the request body my $parser_status = $req->body_status; #... } Calling C<< $r->discard_request_body >> outside the content handler is generally a mistake, so use C<< $req->parse >> there, but B. The Apache2::Request API is B around a lazy-parsing scheme, so calling C should not affect the behavior of any other methods. =head1 SUBCLASSING Apache2::Request If the instances of your subclass are hash references then you can actually inherit from Apache2::Request as long as the Apache2::Request object is stored in an attribute called "r" or "_r". (The Apache2::Request class effectively does the delegation for you automagically, as long as it knows where to find the Apache2::Request object to delegate to.) For example: package MySubClass; use Apache2::Request; our @ISA = qw(Apache2::Request); sub new { my($class, @args) = @_; return bless { r => Apache2::Request->new(@args) }, $class; } =head1 PORTING from 1.X This is the complete list of changes to existing methods from Apache2::Request 1.X. These issues need to be addressed when porting 1.X apps to the new 2.X API. =over 4 =item * Apache2::Upload is now a separate module. Applications requiring the upload API must C in 2.X. This is easily addressed by preloading the modules during server startup. =item * You must use the C API via C<< scalar $req->args >> or C<< scalar $req->body >> to assign new parameters to the request. You may no longer use the two-argument method calls; e.g. $req->param("foo" => "bar"); # NO: usage error in 2.X $req->args->{foo} = "bar"; # OK: assign to args table $req->body->add(foo => "bar"); # OK: add to body table $req->param->add(foo => "bar"); # NO: this is an expensive noop, # because the param table is # generated by overlaying $req->args # and $req->body. my $params = $req->param; $params->set(foo => "bar"); # OK: sets "foo" entry in $params, which # is a local (args + body) table. Neither # $req->args, $req->body, nor future calls # to $req->param, are affected by mods to # $params. =item * C is now identical to C, and is now deprecated. It may be removed from a future 2.X release. =item * C includes the functionality of C and C, so they are now deprecated and may be removed from a future 2.X release. =back =head1 SEE ALSO L, L, L, L, APR::Table(3). =head1 COPYRIGHT Copyright 2003-2005 The Apache Software Foundation Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. rapache-1.2.8/libapreq2/glue/perl/lib/Apache2/Upload.pm0000644000175100017510000002100012706745114022025 0ustar ondrejondrejpackage Apache2::Upload; use Apache2::Request; push our @ISA, qw/APR::Request::Param/; our $VERSION = "2.05-dev"; no strict 'refs'; for (qw/slurp type size link tempname fh io filename/) { *{$_} = *{"APR::Request::Param::upload_$_"}{CODE}; } sub Apache2::Request::upload { my $req = shift; my $body = $req->body or return; $body->param_class(__PACKAGE__); if (@_) { my @uploads = grep $_->upload, $body->get(@_); return wantarray ? @uploads : $uploads[0]; } return map { $_->upload ? $_->name : () } values %$body if wantarray; return $body->uploads($req->pool); } *bb = *APR::Request::Param::upload; 1; __END__ =head1 NAME Apache2::Upload - Methods for dealing with file uploads. =for testing use APR::Pool; use Apache2::Upload; $r = APR::Pool->new; $req = Apache2::Request->new($r); $u = Apache2::Upload->new($r, name => "foo", file => __FILE__); $req->body_status(0); $req->parse; $req->body->add(foo => "bar"); # dummy param with same name as upload $req->body->add($u); open(my $fh, __FILE__) or die $!; binmode $fh; { local $/; $data = <$fh>; } close $fh; ok length $data == -s __FILE__; $data =~ s{\r}{}g; =head1 SYNOPSIS =for example begin use Apache2::Upload; $req = Apache2::Request->new($r); $upload = $req->upload("foo"); $size = $upload->size; # three methods to get at the upload's contents ... slurp, fh, io $upload->slurp($slurp_data); read $upload->fh, $fh_data, $size; ok $slurp_data eq $fh_data; my $io = $upload->io; print while <$io>; =for example end =for example_testing ok $upload->bb->length == $size; $uploads = $req->upload(); is (scalar keys %{$uploads}, 1, "found upload"); is $_STDOUT_, $data; is $fh_data, $data; is $slurp_data, $data; =head1 DESCRIPTION Apache2::Upload is a new module based on the original package included in Apache2::Request 1.X. Users requiring the upload API must now C, which adds the C method to Apache2::Request. Apache2::Upload is largely backwards-compatible with the original 1.X API. See the L section below for a list of known issues. This manpage documents the Apache2::Upload package. =head1 Apache2::Upload =head2 name $upload->name() The name of the HTML form element which generated the upload. =for testing is $u->name, "foo"; =head2 filename $upload->filename() The (client-side) filename as submitted in the HTML form. Note: some agents will submit the file's full pathname, while others may submit just the basename. =for testing is $u->filename, __FILE__; =head2 fh $upload->fh() Creates filehandle reference to the upload's spooled tempfile, which contains the full contents of the upload. =head2 io $upload->io() Creates a tied IO handle. This method is a more efficient version of C, but with C the handle ref returned is not seekable. It is tied to an APR::Request::Brigade object, so you may use the brigade API on the tied object if you want to manipulate the IO stream (beyond simply reading from it). The returned reference is actually an object which has C and C methods available. However these methods are just syntactic sugar for the underlying C and C methods from APR::Request::Brigade. =for example begin $io = $upload->io; print while $io->read($_); # equivalent to: tied(*$io)->READ($_) =for example end =for example_testing is $_STDOUT_, $data; $io = $upload->io; $io->read($h{io}, $upload->size); is $h{io}, $data, "autovivifying read"; See L and L below for additional notes on their usage. =head2 bb $upload->bb() $upload->bb($set) Get/set the APR::Brigade which represents the upload's contents. =head2 size $upload->size() Returns the size of the upload in bytes. =for testing is $u->size, -s __FILE__; =head2 info $upload->info() $upload->info($set) Get/set the additional header information table for the uploaded file. Returns a hash reference tied to the I class. An optional C<$table> argument can be passed to reassign the upload's internal (apr_table_t) info table to the one C<$table> represents. =for example begin my $info = $upload->info; while (my($hdr_name, $hdr_value) = each %$info) { # ... } # fetch upload's Content-Type header my $type = $upload->info->{"Content-type"}; =for example end =for example_testing is $type, "application/octet-stream"; =head2 type $upload->type() Returns the MIME type of the given I object. =for example begin my $type = $upload->type; #same as my $content_type = $upload->info->{"Content-Type"}; $content_type =~ s/;.*$//ms; =for example end =for example_testing is $type, $content_type; =head2 link $upload->link() To avoid recopying the upload's internal tempfile brigade on a *nix-like system, I will create a hard link to it: =for example begin my $upload = $req->upload('foo'); $upload->link("/path/to/newfile") or die sprintf "link from '%s' failed: $!", $upload->tempname; =for example end Typically the new name must lie on the same device and partition as the brigade's tempfile. If this or any other reason prevents the OS from linking the files, C will instead copy the temporary file to the specified location. =head2 slurp $upload->slurp($contents) Reads the full contents of a file upload into the scalar argument. The return value is the length of the file. =for example begin my $size = $upload->slurp($contents); =for example end =for example_testing is $size, length $contents; $upload->slurp($h{slurp}); is $h{slurp}, $contents, "autovivifying slurp"; $contents =~ s{\r}{}g; is $contents, $data; =head2 tempname $upload->tempname() Provides the name of the spool file. =for example begin my $tempname = $upload->tempname; =for example end =for example_testing like $tempname, qr/apreq.{6}$/; =head1 APR::Request::Brigade This class is derived from APR::Brigade, providing additional methods for TIEHANDLE, READ and READLINE. To be memory efficient, these methods delete buckets from the brigade as soon as their data is actually read, so you cannot C on handles tied to this class. Such handles have semantics similar to that of a read-only socket. =head2 TIEHANDLE APR::Request::Brigade->TIEHANDLE($bb) Creates a copy of the bucket brigade represented by $bb, and blesses that copy into the APR::Request::Brigade class. This provides syntactic sugar for using perl's builtin C, C, and C<< <> >> operations on handles tied to this package: use Symbol; $fh = gensym; tie *$fh, "APR::Request:Brigade", $bb; print while <$fh>; =head2 READ $bb->READ($contents) $bb->READ($contents, $length) $bb->READ($contents, $length, $offset) Reads data from the brigade $bb into $contents. When omitted $length defaults to C<-1>, which reads the first bucket into $contents. A positive $length will read in $length bytes, or the remainder of the brigade, whichever is greater. $offset represents the index in $context to read the new data. =head2 READLINE $bb->READLINE() Returns the first line of data from the bride. Lines are terminated by linefeeds (the '\012' character), but we may eventually use C<$/> instead. =head1 PORTING from 1.X =over 4 =item * C<< $upload->next() >> is no longer available; please use the C<< APR::Request::Param::Table >> API when iterating over upload entries. =item * C is replaced by C. =item * C returns only the MIME-type portion of the Content-Type header. =back =head1 SEE ALSO L, L, L, APR::Table(3) =head1 COPYRIGHT Copyright 2003-2005 The Apache Software Foundation Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. rapache-1.2.8/libapreq2/glue/perl/t/0000755000175100017510000000000012706745114016504 5ustar ondrejondrejrapache-1.2.8/libapreq2/glue/perl/t/REPORT0000755000175100017510000000107512706745114017450 0ustar ondrejondrej#!/home/joe/perl/5.8.x/bin/perl # WARNING: this file is generated, do not edit # 01: /home/joe/perl/5.8.x/lib/site_perl/5.8.6/x86_64-linux-thread-multi/Apache/TestConfig.pm:923 # 02: /home/joe/perl/5.8.x/lib/site_perl/5.8.6/x86_64-linux-thread-multi/Apache/TestConfig.pm:1013 # 03: /home/joe/perl/5.8.x/lib/site_perl/5.8.6/x86_64-linux-thread-multi/Apache/TestReport.pm:44 # 04: Makefile.PL:160 BEGIN { eval { require blib && blib->import; } } use strict; use warnings FATAL => 'all'; use lib qw( ); use Apache::TestReportPerl; Apache::TestReportPerl->new(@ARGV)->run;rapache-1.2.8/libapreq2/glue/perl/t/SMOKE0000755000175100017510000000107312706745114017311 0ustar ondrejondrej#!/home/joe/perl/5.8.x/bin/perl # WARNING: this file is generated, do not edit # 01: /home/joe/perl/5.8.x/lib/site_perl/5.8.6/x86_64-linux-thread-multi/Apache/TestConfig.pm:923 # 02: /home/joe/perl/5.8.x/lib/site_perl/5.8.6/x86_64-linux-thread-multi/Apache/TestConfig.pm:1013 # 03: /home/joe/perl/5.8.x/lib/site_perl/5.8.6/x86_64-linux-thread-multi/Apache/TestSmoke.pm:778 # 04: Makefile.PL:159 BEGIN { eval { require blib && blib->import; } } use strict; use warnings FATAL => 'all'; use lib qw( ); use Apache::TestSmokePerl; Apache::TestSmokePerl->new(@ARGV)->run;rapache-1.2.8/libapreq2/glue/perl/t/TEST.PL0000644000175100017510000000221512706745114017520 0ustar ondrejondrej#!perl use strict; use warnings FATAL => 'all'; use Apache2::Build; use constant WIN32 => Apache2::Build::WIN32; use Cwd; my $cwd = WIN32 ? Win32::GetLongPathName(cwd) : cwd; $cwd =~ m{^(.+)/glue/perl$} or die "Can't find base cvs directory"; my $base_dir = $1; my $module_dir = "$base_dir/module"; my $mod_apreq2_dir = Apache2::Build::WIN32 ? "$base_dir/win32/libs" : "$module_dir/apache2/.libs"; use base 'Apache::TestRunPerl'; main::->new->run(@ARGV); sub pre_configure { my $self = shift; # Don't load an installed mod_apreq Apache::TestConfig::autoconfig_skip_module_add('mod_apreq.c'); Apache::TestConfig::autoconfig_skip_module_add('mod_apreq2.c'); $self->SUPER::pre_configure(); } sub configure_modperl { my $self = shift; my $cfg = $self->{test_config}; # make sure Win32 uses the just-built libapreq2.dll if (WIN32) { my $library_dir = $mod_apreq2_dir; $cfg->preamble(qq{LoadFile "$library_dir/libapreq2.dll"\n}); } $cfg->preamble(IfModule => '!mod_apreq2.c', qq(LoadModule apreq_module "$mod_apreq2_dir/mod_apreq2.so"\n)); $self->SUPER::configure_modperl(); } rapache-1.2.8/libapreq2/glue/perl/t/apreq/0000755000175100017510000000000012706745114017614 5ustar ondrejondrejrapache-1.2.8/libapreq2/glue/perl/t/apreq/big_input.t0000644000175100017510000000342012706745114021760 0ustar ondrejondrejuse strict; use warnings FATAL => 'all'; # test the processing of variations of the key lengths and the keys # numbers use Apache::Test; use Apache::TestUtil; use Apache::TestRequest qw(GET_BODY POST_BODY); my $location = "/TestApReq__big_input"; my @key_len = (5, 100, 305); my @key_num = (5, 15, 26); my @keys = ('a'..'z'); my @big_key_len = (100, 500, 5000, 10000); my @big_key_num = (5, 15, 25); my @big_keys = ('a'..'z'); plan tests => @key_len * @key_num + @big_key_len * @big_key_num, have_lwp; # GET my $len = 0; for my $key_len (@key_len) { for my $key_num (@key_num) { my @query = (); for my $key (@keys[0..($key_num-1)]) { my $pair = "$key=" . 'd' x $key_len; $len += length $pair; push @query, $pair; } my $query = join "&", @query; $len += @query - 1; # the stick with two ends one '&' char off my $body = GET_BODY "$location?$query"; t_debug "# of keys : $key_num, key_len $key_len"; ok t_cmp($body, ( ($key_len + 3) * $key_num - 1), "GET long query"); } } # POST $len = 0; for my $big_key_len (@big_key_len) { for my $big_key_num (@big_key_num) { my @query = (); for my $big_key (@big_keys[0..($big_key_num-1)]) { my $pair = "$big_key=" . 'd' x $big_key_len; $len += length $pair; push @query, $pair; } my $query = join "&", @query; $len += @query - 1; # the stick with two ends one '&' char off my $body = POST_BODY $location, content => $query; t_debug "# of keys : $big_key_num, key_len $big_key_len"; ok t_cmp($body, ( ($big_key_len + 3) * $big_key_num - 1), "POST big data"); } } rapache-1.2.8/libapreq2/glue/perl/t/apreq/cgi.t0000644000175100017510000002300612706745114020544 0ustar ondrejondrejuse strict; use warnings FATAL => 'all'; use Apache::Test; use Apache::TestUtil qw(t_cmp t_debug t_write_perl_script); use Apache::TestConfig; use Apache::TestRequest qw(GET_BODY UPLOAD_BODY GET_BODY_ASSERT POST_BODY GET_RC GET_HEAD); use constant WIN32 => Apache::TestConfig::WIN32; use HTTP::Cookies; use Cwd; require File::Basename; my @key_len = (5, 100, 305); my @key_num = (5, 15, 26); my @keys = ('a'..'z'); my $cwd = getcwd(); my %types = (perl => 'application/octet-stream', 'perltoc.pod' => 'text/x-pod'); my @names = sort keys %types; my @methods = sort qw/slurp fh tempname link io/; my $cgi = File::Spec->catfile(Apache::Test::vars('serverroot'), qw(cgi-bin test_cgi.pl)); t_write_perl_script($cgi, ); ######################################################### # uncomment the following to test larger keys my @big_key_len = (100, 500, 5000, 10000); # if the above is uncommented, comment out the following #my @big_key_len = (100, 500, 1000, 2500); ######################################################### my @big_key_num = (5, 15, 25); my @big_keys = ('a'..'z'); plan tests => 10 + @key_len * @key_num + @big_key_len * @big_key_num + @names * @methods, have_lwp && have_cgi; my $location = '/cgi-bin'; my $script = $location . '/test_cgi.pl'; my $line_end = WIN32 ? "\r\n" : "\n"; my $filler = "0123456789" x 6400; # < 64K # GET for my $key_len (@key_len) { for my $key_num (@key_num) { my @query = (); my $len = 0; for my $key (@keys[0..($key_num-1)]) { my $pair = "$key=" . 'd' x $key_len; $len += length($pair) - 1; push @query, $pair; } my $query = join ";", @query; t_debug "# of keys : $key_num, key_len $key_len"; my $body = GET_BODY "$script?$query"; ok t_cmp($body, $len, "GET long query"); } } # POST for my $big_key_len (@big_key_len) { for my $big_key_num (@big_key_num) { my @query = (); my $len = 0; for my $big_key (@big_keys[0..($big_key_num-1)]) { my $pair = "$big_key=" . 'd' x $big_key_len; $len += length($pair) - 1; push @query, $pair; } my $query = join ";", @query; t_debug "# of keys : $big_key_num, big_key_len $big_key_len"; my $body = POST_BODY($script, content => $query); ok t_cmp($body, $len, "POST big data"); } } ok t_cmp(POST_BODY("$script?foo=1", Content => $filler), "\tfoo => 1$line_end", "simple post"); ok t_cmp(GET_BODY("$script?foo=%3F&bar=hello+world"), "\tfoo => ?$line_end\tbar => hello world$line_end", "simple get"); my $body = POST_BODY($script, content => "aaa=$filler;foo=1;bar=2;filler=$filler"); ok t_cmp($body, "\tfoo => 1$line_end\tbar => 2$line_end", "simple post"); $body = POST_BODY("$script?foo=1", content => "intro=$filler&bar=2&conclusion=$filler"); ok t_cmp($body, "\tfoo => 1$line_end\tbar => 2$line_end", "simple post"); $body = UPLOAD_BODY("$script?foo=1", content => $filler); ok t_cmp($body, "\tfoo => 1$line_end", "simple upload"); { my $test = 'netscape'; my $key = 'apache'; my $value = 'ok'; my $cookie = qq{$key=$value}; ok t_cmp(GET_BODY("$script?test=$test&key=$key", Cookie => $cookie), $value, $test); } { my $test = 'rfc'; my $key = 'apache'; my $value = 'ok'; my $cookie = qq{\$Version="1"; $key="$value"; \$Path="$location"}; ok t_cmp(GET_BODY("$script?test=$test&key=$key", Cookie => $cookie), qq{"$value"}, $test); } { my $test = 'encoded value with space'; my $key = 'apache'; my $value = 'okie dokie'; my $cookie = "$key=" . join '', map {/ / ? '+' : sprintf '%%%.2X', ord} split //, $value; ok t_cmp(GET_BODY("$script?test=$test&key=$key", Cookie => $cookie), $value, $test); } { my $test = 'bake'; my $key = 'apache'; my $value = 'ok'; my $cookie = "$key=$value"; my ($header) = GET_HEAD("$script?test=$test&key=$key", Cookie => $cookie) =~ /^#Set-Cookie:\s+(.+)/m; ok t_cmp($header, $cookie, $test); } { my $test = 'bake2'; my $key = 'apache'; my $value = 'ok'; my $cookie = qq{\$Version="1"; $key="$value"; \$Path="$location"}; my ($header) = GET_HEAD("$script?test=$test&key=$key", Cookie => $cookie) =~ /^#Set-Cookie2:\s+(.+)/m; ok t_cmp($header, qq{$key="$value"; Version=1; path="$location"}, $test); } # file upload tests foreach my $name (@names) { my $url = ( ($name =~ /\.pod$/) ? "getfiles-perl-pod/" : "/getfiles-binary-" ) . $name; my $content = GET_BODY_ASSERT($url); my $path = File::Spec->catfile($cwd, 't', $name); open my $fh, ">", $path or die "Cannot open $path: $!"; binmode $fh; print $fh $content; close $fh; } eval {require Digest::MD5;}; my $has_md5 = $@ ? 0 : 1; foreach my $file( map {File::Spec->catfile($cwd, 't', $_)} @names) { my $size = -s $file; my $cs = $has_md5 ? cs($file) : 0; my $basename = File::Basename::basename($file); for my $method ( @methods) { my $result = UPLOAD_BODY("$script?method=$method;has_md5=$has_md5", filename => $file); $result =~ s{\r}{}g; my $expected = <new->addfile($fh)->hexdigest; close $fh; return $md5; } __DATA__ use strict; use File::Basename; use warnings FATAL => 'all'; use blib; use APR; use APR::Pool; use APR::Request::Param; use APR::Request::Cookie; use APR::Request::CGI; use File::Spec; require File::Basename; my $p = APR::Pool->new(); apreq_log("Creating APR::Request::CGI object"); my $req = APR::Request::CGI->handle($p); my $foo = $req->param("foo"); my $bar = $req->param("bar"); my $test = $req->param("test"); my $key = $req->param("key"); my $method = $req->param("method"); if ($foo || $bar) { print "Content-Type: text/plain\n\n"; if ($foo) { apreq_log("foo => $foo"); print "\tfoo => $foo\n"; } if ($bar) { apreq_log("bar => $bar"); print "\tbar => $bar\n"; } } elsif ($test && $key) { my $jar = $req->jar; $jar->cookie_class("APR::Request::Cookie"); my %cookies = %$jar; apreq_log("Fetching cookie $key"); if ($cookies{$key}) { if ($test eq "bake") { printf "Set-Cookie: %s\n", $cookies{$key}->as_string; } elsif ($test eq "bake2") { printf "Set-Cookie2: %s\n", $cookies{$key}->as_string; } print "Content-Type: text/plain\n\n"; print APR::Request::decode($cookies{$key}->value); } } elsif ($method) { my $temp_dir = File::Spec->tmpdir; my $has_md5 = $req->args('has_md5'); require Digest::MD5 if $has_md5; my $body = $req->body; $body->param_class("APR::Request::Param"); my ($param) = values %{$body->uploads($p)}; my $type = $param->upload_type; my $basename = File::Basename::basename($param->upload_filename); my ($data, $fh); if ($method eq 'slurp') { $param->upload_slurp($data); } elsif ($method eq 'fh') { read $param->upload_fh, $data, $param->upload_size; } elsif ($method eq 'tempname') { my $name = $param->upload_tempname; open $fh, "<", $name or die "Can't open $name: $!"; binmode $fh; read $fh, $data, $param->upload_size; close $fh; } elsif ($method eq 'link') { my $link_file = File::Spec->catfile($temp_dir, "linkfile"); unlink $link_file if -f $link_file; $param->upload_link($link_file) or die "Can't link to $link_file: $!"; open $fh, "<", $link_file or die "Can't open $link_file: $!"; binmode $fh; read $fh, $data, $param->upload_size; close $fh; unlink $link_file if -f $link_file; } elsif ($method eq 'io') { read $param->upload_io, $data, $param->upload_size; } else { die "unknown method: $method"; } my $temp_file = File::Spec->catfile($temp_dir, $basename); unlink $temp_file if -f $temp_file; open my $wfh, ">", $temp_file or die "Can't open $temp_file: $!"; binmode $wfh; print $wfh $data; close $wfh; my $cs = $has_md5 ? cs($temp_file) : 0; my $size = -s $temp_file; print <<"END"; type: $type size: $size filename: $basename md5: $cs END unlink $temp_file if -f $temp_file; } else { my $len = 0; print "Content-Type: text/plain\n\n"; apreq_log("Fetching all parameters"); for ($req->param) { my $param = $req->param($_); next unless $param; my $length = length($param); apreq_log("$_ has a value of length $length"); $len += length($_) + $length; } print $len; } sub apreq_log { my $msg = shift; my ($pkg, $file, $line) = caller; $file = basename($file); print STDERR "$file($line): $msg\n"; } sub cs { my $file = shift; open my $fh, '<', $file or die qq{Cannot open "$file": $!}; binmode $fh; my $md5 = Digest::MD5->new->addfile($fh)->hexdigest; close $fh; return $md5; } rapache-1.2.8/libapreq2/glue/perl/t/apreq/cookie.t0000644000175100017510000000373412706745114021261 0ustar ondrejondrejuse strict; use warnings FATAL => 'all'; use Apache::Test; use Apache::TestUtil; use Apache::TestRequest qw(GET_BODY GET_HEAD); plan tests => 7, have_lwp;#under_construction; # have_lwp require HTTP::Cookies; my $location = "/TestApReq__cookie"; { my $test = 'new'; my $value = 'bar'; ok t_cmp(GET_BODY("$location?test=new"), $value, $test); } { my $test = 'new'; my $value = 'bar'; ok t_cmp(GET_BODY("$location?test=new;expires=%2B3M"), $value, $test); } { my $test = 'netscape'; my $key = 'apache'; my $value = 'ok'; my $cookie = qq{$key=$value}; ok t_cmp(GET_BODY("$location?test=$test&key=$key", Cookie => $cookie), $value, $test); } { my $test = 'rfc'; my $key = 'apache'; my $value = 'ok'; my $cookie = qq{\$Version="1"; $key="$value"; \$Path="$location"}; ok t_cmp(GET_BODY("$location?test=$test&key=$key", Cookie => $cookie), qq{"$value"}, $test); } { my $test = 'encoded value with space'; my $key = 'apache'; my $value = 'okie dokie'; my $cookie = "$key=" . join '', map {/ / ? '+' : sprintf '%%%.2X', ord} split //, $value; ok t_cmp(GET_BODY("$location?test=$test&key=$key", Cookie => $cookie), $value, $test); } { my $test = 'bake'; my $key = 'apache'; my $value = 'ok'; my $cookie = "$key=$value"; my ($header) = GET_HEAD("$location?test=$test&key=$key", Cookie => $cookie) =~ /^#Set-Cookie:\s+(.+)/m; ok t_cmp($header, $cookie, $test); } { my $test = 'bake2'; my $key = 'apache'; my $value = 'ok'; my $cookie = qq{\$Version="1"; $key="$value"; \$Path="$location"}; my ($header) = GET_HEAD("$location?test=$test&key=$key", Cookie => $cookie) =~ /^#Set-Cookie2:\s+(.+)/m; ok t_cmp($header, qq{$key="$value"; Version=1; path="$location"}, $test); } rapache-1.2.8/libapreq2/glue/perl/t/apreq/inherit.t0000644000175100017510000000111312706745114021437 0ustar ondrejondrejuse strict; use warnings FATAL => 'all'; use Apache::Test; use Apache::TestUtil; use Apache::TestRequest qw(GET_BODY UPLOAD_BODY); plan tests => 4, have_lwp; my $location = "/TestApReq__inherit"; my @response = split/\r?\n/, GET_BODY($location, Cookie=>"apache=2"); ok t_cmp($response[0], "method => GET", "inherit method"); ok t_cmp($response[1], "cookie => apache=2", "inherit cookie"); ok t_cmp($response[2], "DESTROYING TestApReq::inherit object", "first object cleanup"); ok t_cmp($response[3], "DESTROYING TestApReq::inherit object", "second object cleanup"); rapache-1.2.8/libapreq2/glue/perl/t/apreq/request.t0000644000175100017510000000256212706745114021476 0ustar ondrejondrejuse strict; use warnings FATAL => 'all'; use Apache::Test; use Apache::TestUtil; use Apache::TestRequest qw(GET_BODY UPLOAD_BODY); plan tests => 18, have_lwp; my $location = "/TestApReq__request"; #print GET_BODY $location; { # basic param() test my $test = 'param'; my $value = '42.5'; ok t_cmp(GET_BODY("$location?test=$test&value=$value"), $value, "basic param"); } for my $test (qw/slurp bb tempname link fh io bad;query=string%%/) { # upload a string as a file my $value = ('DataUpload' x 10 . "\n") x 1_000; my $result = UPLOAD_BODY("$location?test=$test", content => $value); ok t_cmp($result, $value, "basic upload"); my $i; for ($i = 0; $i < length $value; ++$i) { last if substr($value,$i,1) ne substr($result,$i,1); } ok t_cmp($i, length($value), "basic upload length"); } { my $value = 'DataUpload' x 100; my $result = UPLOAD_BODY("$location?test=type", content => $value); ok t_cmp($result, "text/plain", "type"); } { my $value = 'DataUpload' x 100; my $result = UPLOAD_BODY("$location?test=hook", content => $value); ok t_cmp($result, $value, "type"); } { my $value = 'DataUpload' x 100; my $result = UPLOAD_BODY("$location?test=disable_uploads;foo=bar1;foo=bar2", content => $value); ok t_cmp($result, "ok", "disabled uploads"); } rapache-1.2.8/libapreq2/glue/perl/t/apreq/upload.t0000644000175100017510000000325012706745114021265 0ustar ondrejondrejuse strict; use warnings FATAL => 'all'; use Apache::Test; use Apache::TestUtil; use Apache::TestRequest qw(UPLOAD_BODY GET_BODY_ASSERT); use Cwd; require File::Basename; my $cwd = getcwd(); my $location = "/TestApReq__upload"; my %types = (perl => 'application/octet-stream', httpd => 'application/octet-stream', 'perltoc.pod' => 'text/x-pod', 'perlport.pod' => 'text/x-pod'); my @names = sort keys %types; my @methods = sort qw/slurp fh tempname link io/; plan tests => @names * @methods, have_lwp; foreach my $name (@names) { my $url = ( ($name =~ /\.pod$/) ? "getfiles-perl-pod/" : "/getfiles-binary-" ) . $name; my $content = GET_BODY_ASSERT($url); my $path = File::Spec->catfile($cwd, 't', $name); open my $fh, ">", $path or die "Cannot open $path: $!"; binmode $fh; print $fh $content; close $fh; } eval {require Digest::MD5;}; my $has_md5 = $@ ? 0 : 1; foreach my $file( map {File::Spec->catfile($cwd, 't', $_)} @names) { my $size = -s $file; my $cs = $has_md5 ? cs($file) : 0; my $basename = File::Basename::basename($file); for my $method ( @methods) { my $result = UPLOAD_BODY("$location?method=$method;has_md5=$has_md5", filename => $file); my $expected = <new->addfile($fh)->hexdigest; close $fh; return $md5; } rapache-1.2.8/libapreq2/glue/perl/t/conf/0000755000175100017510000000000012706745114017431 5ustar ondrejondrejrapache-1.2.8/libapreq2/glue/perl/t/conf/extra.conf.in0000644000175100017510000000032412706745114022027 0ustar ondrejondrejScriptAlias /cgi-bin/ "@ServerRoot@/cgi-bin/" LockFile @ServerRoot@/logs/accept.lock AllowOverride None Options None rapache-1.2.8/libapreq2/glue/perl/t/response/0000755000175100017510000000000012706745114020342 5ustar ondrejondrejrapache-1.2.8/libapreq2/glue/perl/t/response/TestAPI/0000755000175100017510000000000012706745114021613 5ustar ondrejondrejrapache-1.2.8/libapreq2/glue/perl/t/response/TestAPI/cookie.pm0000644000175100017510000000350412706745114023424 0ustar ondrejondrejpackage TestAPI::cookie; push our @ISA, "APR::Request::Cookie"; use strict; use warnings FATAL => 'all'; use Apache::Test; use Apache::TestUtil; use APR::Request::Cookie; use APR::Request::Apache2; use APR::Table; sub handler { my $r = shift; plan $r, tests => 30; $r->headers_in->{Cookie} = "foo=1;bar=2;foo=3;quux=4"; my $req = APR::Request::Apache2->handle($r); ok defined $req->jar; ok t_cmp $req->jar("foo"), 1, "scalar jar(foo)"; ok t_cmp $req->jar("bar"), 2, "scalar jar(bar)"; ok t_cmp $req->jar("quux"), 4, "scalar jar(quux)"; my @rv = $req->jar("foo"); ok t_cmp "@rv", "1 3", "list jar(foo)"; @rv = $req->jar("bar"); ok t_cmp "@rv", "2", "list jar(bar)"; @rv = $req->jar("quux"); ok t_cmp "@rv", "4", "list jar(quux)"; my $jar = $req->jar(); ok $jar->isa("APR::Request::Cookie::Table"); ok t_cmp $jar->{foo}, 1, '$jar->{foo} == 1'; ok t_cmp $jar->{bar}, 2, '$jar->{bar} == 2'; ok t_cmp $jar->{quux}, 4, '$jar->{quux} == 4'; my @k = qw/foo bar foo quux/; my @v = 1..4; ok t_cmp join(" ", keys %$jar), "foo bar foo quux", 'keys %$jar'; ok t_cmp join(" ", values %$jar), "1 2 3 4", 'values %$jar'; ok t_cmp join (" ", each %$jar), "$k[$_] $v[$_]", 'each %$jar: ' . $_ for 0..3; ok t_cmp join(" ", $jar->get("foo")), "1 3", '$jar->get("foo")'; ok not defined $jar->cookie_class("APR::Request::Cookie"); ok t_cmp $_->is_tainted, 1, "is tainted: $_" for values %$jar; $_->is_tainted(0) for values %$jar; ok t_cmp $_->is_tainted, 0, "not tainted: $_" for values %$jar; eval { $jar->cookie_class("APR::Request::Param") }; ok t_cmp qr/^Usage/, $@, "Bad class name"; ok t_cmp $jar->cookie_class(__PACKAGE__), "APR::Request::Cookie", "class upgrade"; ok $jar->{foo}->isa(__PACKAGE__); return 0; } 1; rapache-1.2.8/libapreq2/glue/perl/t/response/TestAPI/error.pm0000644000175100017510000000073112706745114023303 0ustar ondrejondrejpackage TestAPI::error; use strict; use warnings FATAL => 'all'; use Apache::Test; use Apache::TestUtil; use APR::Request::Apache2; use APR::Request::Error qw/GENERAL TAINTED/; sub handler { my $r = shift; plan $r, tests => 3; my $req = APR::Request::Apache2->handle($r); ok $req->isa("APR::Request"); # XXX export some constants, and test apreq_xs_strerror ok TAINTED > GENERAL; ok GENERAL eq "Internal apreq error"; return 0; } 1; rapache-1.2.8/libapreq2/glue/perl/t/response/TestAPI/module.pm0000644000175100017510000000141312706745114023435 0ustar ondrejondrejpackage TestAPI::module; use strict; use warnings FATAL => 'all'; use Apache::Test; use Apache::TestUtil; use APR::Request::Apache2; sub handler { my $r = shift; plan $r, tests => 9; my $req = APR::Request::Apache2->handle($r); ok $req->isa("APR::Request::Apache2"); ok t_cmp $req->brigade_limit, 256 * 1024, "default brigade limit is 256K"; ok $req->brigade_limit(1024); ok t_cmp $req->brigade_limit, 1024, "brigade_limit reset to 1K"; ok $req->read_limit(1024 * 1024); ok t_cmp $req->read_limit, 1024 * 1024, "read_limit reset to 1M"; ok not defined $req->temp_dir; ok $req->temp_dir("/tmp"); ok t_cmp $req->temp_dir, "/tmp", "temp dir reset to /tmp"; # XXX parse, header_in & header_out tests return 0; } 1; rapache-1.2.8/libapreq2/glue/perl/t/response/TestAPI/param.pm0000644000175100017510000000350212706745114023251 0ustar ondrejondrejpackage TestAPI::param; push our @ISA, "APR::Request::Param"; use strict; use warnings FATAL => 'all'; use Apache::Test; use Apache::TestUtil; use APR::Request::Param; use APR::Request::Apache2; sub handler { my $r = shift; plan $r, tests => 30; $r->args("foo=1;bar=2;foo=3;quux=4"); my $req = APR::Request::Apache2->handle($r); ok defined $req->args; ok t_cmp $req->args("foo"), 1, "scalar args(foo)"; ok t_cmp $req->args("bar"), 2, "scalar args(bar)"; ok t_cmp $req->args("quux"), 4, "scalar args(quux)"; my @rv = $req->args("foo"); ok t_cmp "@rv", "1 3", "list args(foo)"; @rv = $req->args("bar"); ok t_cmp "@rv", "2", "list args(bar)"; @rv = $req->args("quux"); ok t_cmp "@rv", "4", "list args(quux)"; my $args = $req->args(); ok $args->isa("APR::Request::Param::Table"); ok t_cmp $args->{foo}, 1, '$args->{foo} == 1'; ok t_cmp $args->{bar}, 2, '$args->{bar} == 2'; ok t_cmp $args->{quux}, 4, '$args->{quux} == 4'; my @k = qw/foo bar foo quux/; my @v = 1..4; ok t_cmp join(" ", keys %$args), "foo bar foo quux", 'keys %$args'; ok t_cmp join(" ", values %$args), "1 2 3 4", 'values %$args'; ok t_cmp join (" ", each %$args), "$k[$_] $v[$_]", 'each %$args: ' . $_ for 0..3; ok t_cmp join(" ", $args->get("foo")), "1 3", '$args->get("foo")'; ok not defined $args->param_class("APR::Request::Param"); ok t_cmp $_->is_tainted, 1, "is tainted: $_" for values %$args; $_->is_tainted(0) for values %$args; ok t_cmp $_->is_tainted, 0, "not tainted: $_" for values %$args; eval { $args->param_class("APR::Request::Cookie") }; ok t_cmp qr/^Usage/, $@, "Bad class name"; ok t_cmp $args->param_class(__PACKAGE__), "APR::Request::Param", "class upgrade"; ok $args->{foo}->isa(__PACKAGE__); return 0; } 1; rapache-1.2.8/libapreq2/glue/perl/t/response/TestApReq/0000755000175100017510000000000012706745114022212 5ustar ondrejondrejrapache-1.2.8/libapreq2/glue/perl/t/response/TestApReq/big_input.pm0000644000175100017510000000101312706745114024523 0ustar ondrejondrejpackage TestApReq::big_input; use strict; use warnings FATAL => 'all'; use Apache2::Request (); use Apache2::RequestIO; use Apache2::RequestRec; sub handler { my $r = shift; my $req = Apache2::Request->new($r); my $len = 0; for ($req->param) { my $val = $req->param($_) || ''; $len += length($_) + length($val) + 2; # +2 ('=' and '&') } $len--; # the stick with two ends one '&' char off $req->content_type('text/plain'); $req->print($len); return 0; } 1; __END__ rapache-1.2.8/libapreq2/glue/perl/t/response/TestApReq/cookie.pm0000644000175100017510000000233512706745114024024 0ustar ondrejondrejpackage TestApReq::cookie; use strict; use warnings FATAL => 'all'; use Apache2::RequestIO; use Apache2::RequestRec; use Apache2::Connection; use Apache2::Cookie (); use Apache2::Request (); sub handler { my $r = shift; my $req = Apache2::Request->new($r); my %cookies = Apache2::Cookie->fetch($r); $r->content_type('text/plain'); my $test = $req->APR::Request::args('test'); my $key = $req->APR::Request::args('key'); if ($key and $cookies{$key}) { if ($test eq "bake") { $cookies{$key}->bake($r); } elsif ($test eq "bake2") { $cookies{$key}->bake2($r); } $r->print($cookies{$key}->value); } else { my @expires; @expires = ("expires", $req->APR::Request::args('expires')) if $req->APR::Request::args('expires'); my $cookie = Apache2::Cookie->new($r, name => "foo", value => "bar", @expires); if ($test eq "bake") { $cookie->bake($req); } elsif ($test eq "bake2") { $cookie->set_attr(version => 1); $cookie->bake2; } $r->print($cookie->value); } return 0; } 1; __END__ rapache-1.2.8/libapreq2/glue/perl/t/response/TestApReq/inherit.pm0000644000175100017510000000130712706745114024213 0ustar ondrejondrejpackage TestApReq::inherit; use Apache2::Cookie; use base qw/Apache2::Request Apache2::Cookie::Jar/; use strict; use warnings FATAL => 'all'; use APR; use Apache2::RequestRec; use Apache2::RequestIO; sub handler { my $r = shift; $r = __PACKAGE__->new($r); # tickles refcnt bug in apreq-1 die "Wrong package: ", ref $r unless $r->isa('TestApReq::inherit'); $r->content_type('text/plain'); # look for segfault when $r->isa("Apache2::Request") my $req = bless { r => $r }; $req->printf("method => %s\n", $req->method); $req->printf("cookie => %s\n", $req->cookies->{"apache"}->as_string); return 0; } sub DESTROY { $_[0]->print("DESTROYING ", __PACKAGE__, " object\n") } 1; rapache-1.2.8/libapreq2/glue/perl/t/response/TestApReq/request.pm0000644000175100017510000001360312706745114024243 0ustar ondrejondrejpackage TestApReq::request; use strict; use warnings FATAL => 'all'; use Apache2::RequestRec; use Apache2::RequestIO; use Apache2::Request (); use Apache2::Connection; use Apache2::Upload; use APR::Pool; use APR::Bucket; use APR::PerlIO; use Apache2::ServerUtil; use File::Spec; my $data; sub hook { my ($upload, $buffer, $len) = @_; warn "$upload saw EOS" and return unless defined $buffer; die "BAD UPLOAD ARGS" unless length $buffer == $len; warn "$upload saw $buffer"; $data .= $buffer; } sub handler { my $r = shift; my $temp_dir = File::Spec->catfile(Apache2::ServerUtil::server_root, 'logs'); my $req = Apache2::Request->new($r);#, POST_MAX => 1_000_000, #TEMP_DIR => $temp_dir); $req->temp_dir($temp_dir); $req->read_limit(1_000_000); $req->content_type('text/plain'); my $test = $req->APR::Request::args('test'); my $method = $r->method; if ($test eq 'param') { my $table = $req->APR::Request::args(); my $value = $req->param('value'); $req->print($value); } elsif ($test eq 'slurp') { my ($upload) = values %{$req->upload}; $upload->slurp(my $data); if ($upload->size != length $data) { $req->print("Size mismatch: size() reports ", $upload->size, " but slurp() length is ", length $data, "\n"); } $req->print($data); } elsif ($test eq 'bb') { my ($upload) = $req->upload("HTTPUPLOAD"); my $bb = $upload->bb; my $e = $bb->first; while ($e) { $e->read(my $buf); $req->print($buf); $e = $bb->next($e); } } elsif ($test eq 'tempname') { my $upload = $req->upload("HTTPUPLOAD"); my $name = $upload->tempname; my ($dir) = $name =~ /^(.+)apreq\w{6}$/; chop $dir; die "Tempfile in wrong temp_dir (expected $temp_dir, saw $dir)" unless $dir eq $temp_dir; open my $fh, "<", $name or die "Can't open $name: $!"; $r->print(<$fh>); } elsif ($test eq 'link') { my $upload = $req->upload("HTTPUPLOAD"); my $link_file = File::Spec->catfile("$temp_dir", "linktest"); unlink $link_file if -f $link_file; $upload->link($link_file) or die "Can't link to $link_file: $!"; open my $fh, "<", $link_file or die "Can't open $link_file: $!"; $r->print(<$fh>); } elsif ($test eq 'fh') { my $upload = $req->upload(($req->upload)[0]); my $fh = $upload->fh; read $upload->fh, my $fh_contents, $upload->size; $upload->slurp(my $slurp_data); die 'fh contents != slurp data' unless $fh_contents eq $slurp_data; read $fh, $fh_contents, $upload->size; die '$fh contents != slurp data' unless $fh_contents eq $slurp_data; seek $fh, 0, 0; $r->print(<$fh>); } elsif ($test eq 'io') { my $upload = $req->upload(($req->upload)[0]); my $io = $upload->io; read $upload->io, my $io_contents, $upload->size; $upload->slurp(my $slurp_data); die "io contents != slurp data" unless $io_contents eq $slurp_data; undef $io_contents; $upload->io->read($io_contents, $upload->size); die "io contents != slurp data" unless $io_contents eq $slurp_data; my $bb = $upload->bb; my $e = $bb->first; my $bb_contents = ""; while ($e) { $e->read(my $buf); $bb_contents .= $buf; $e = $bb->next($e); } die "io contents != brigade contents" unless $io_contents eq $bb_contents; $r->print(<$io>); } elsif ($test eq 'bad') { require APR::Request::Error; eval {my $q = $req->APR::Request::args('query')}; if (ref $@ && $@->isa("APR::Request::Error")) { $req->upload("HTTPUPLOAD")->slurp(my $data); $req->print($data); } } elsif ($test eq 'hook') { $data = ""; $req->upload_hook(\&hook); $req->parse; $r->print($data); } elsif ($test eq 'type') { my $upload = $req->upload("HTTPUPLOAD"); die "content-type mismatch" unless $upload->info->{"Content-Type"} eq $upload->type; $r->print($upload->type); } elsif ($test eq 'disable_uploads') { require APR::Request::Error; $req->disable_uploads(1); eval {my $upload = $req->upload('HTTPUPLOAD')}; if (ref $@ eq "APR::Request::Error") { my $args = $@->{_r}->APR::Request::args('test'); # checks _r is an object ref my $upload = $@->body('HTTPUPLOAD'); # no exception this time! die "args test failed" unless $args eq $test; $args = $@->APR::Request::args; my $test_string = ""; # MAGIC ITERATOR TESTS if ($^V ge v5.8.0) { warn "Running MAGIC ITERATOR tests"; $test_string .= "$a=$b;" while ($a, $b) = each %$args; die "each test failed: '$test_string'" unless $test_string eq "test=disable_uploads;foo=bar1;foo=bar2;"; $test_string = join ":", values %$args; die "values test failed: '$test_string'" unless $test_string eq "disable_uploads:bar1:bar2"; $test_string = join ":", %$args; die "list deref test failed: '$test_string'" unless $test_string eq "test:disable_uploads:foo:bar1:foo:bar2"; } # TABLE DO TESTS { my $do_data = ""; $args->do( sub { $do_data .= "@_"; 1 } ); die "do() test failed: '$do_data'" unless $do_data eq "test disable_uploadsfoo bar1foo bar2"; } $req->print("ok"); } } return 0; } 1; __END__ rapache-1.2.8/libapreq2/glue/perl/t/response/TestApReq/upload.pm0000644000175100017510000000432212706745114024035 0ustar ondrejondrejpackage TestApReq::upload; use strict; use warnings FATAL => 'all'; use Apache2::RequestRec; use Apache2::RequestIO; use Apache2::Request (); use Apache2::Upload; use File::Spec; require File::Basename; sub handler { my $r = shift; my $req = Apache2::Request->new($r); my $temp_dir = File::Spec->tmpdir; my $method = $req->APR::Request::args('method'); my $has_md5 = $req->APR::Request::args('has_md5'); require Digest::MD5 if $has_md5; my $upload = $req->upload(($req->upload)[0]); my $type = $upload->type; my $basename = File::Basename::basename($upload->filename); my ($data, $fh); if ($method eq 'slurp') { $upload->slurp($data); } elsif ($method eq 'fh') { read $upload->fh, $data, $upload->size; } elsif ($method eq 'tempname') { my $name = $upload->tempname; open $fh, "<", $name or die "Can't open $name: $!"; binmode $fh; read $fh, $data, $upload->size; close $fh; } elsif ($method eq 'link') { my $link_file = File::Spec->catfile($temp_dir, "linkfile"); unlink $link_file if -f $link_file; $upload->link($link_file) or die "Can't link to $link_file: $!"; open $fh, "<", $link_file or die "Can't open $link_file: $!"; binmode $fh; read $fh, $data, $upload->size; close $fh; unlink $link_file if -f $link_file; } elsif ($method eq 'io') { read $upload->io, $data, $upload->size; } else { die "unknown method: $method"; } my $temp_file = File::Spec->catfile($temp_dir, $basename); unlink $temp_file if -f $temp_file; open my $wfh, ">", $temp_file or die "Can't open $temp_file: $!"; binmode $wfh; print $wfh $data; close $wfh; my $cs = $has_md5 ? cs($temp_file) : 0; $req->content_type('text/plain'); my $size = -s $temp_file; $r->print(<new->addfile($fh)->hexdigest; close $fh; return $md5; } 1; __END__ rapache-1.2.8/libapreq2/glue/perl/xsbuilder/0000755000175100017510000000000012706745114020242 5ustar ondrejondrejrapache-1.2.8/libapreq2/glue/perl/xsbuilder/APR/0000755000175100017510000000000012706745114020664 5ustar ondrejondrejrapache-1.2.8/libapreq2/glue/perl/xsbuilder/APR/Request/0000755000175100017510000000000012706745114022314 5ustar ondrejondrejrapache-1.2.8/libapreq2/glue/perl/xsbuilder/APR/Request/APR__Request.h0000644000175100017510000002556612706745114024774 0ustar ondrejondrej#include "apreq_xs_tables.h" static XS(apreq_xs_jar) { dXSARGS; apreq_handle_t *req; SV *sv, *obj; IV iv; if (items == 0 || items > 2 || !SvROK(ST(0)) || !sv_derived_from(ST(0), "APR::Request")) Perl_croak(aTHX_ "Usage: APR::Request::jar($req [,$name])"); sv = ST(0); obj = apreq_xs_sv2object(aTHX_ sv, HANDLE_CLASS, 'r'); iv = SvIVX(obj); req = INT2PTR(apreq_handle_t *, iv); if (items == 2 && GIMME_V == G_SCALAR) { apreq_cookie_t *c = apreq_jar_get(req, SvPV_nolen(ST(1))); if (c != NULL) { ST(0) = apreq_xs_cookie2sv(aTHX_ c, NULL, obj); sv_2mortal(ST(0)); XSRETURN(1); } else { const apr_table_t *t; apr_status_t s; s = apreq_jar(req, &t); if (apreq_module_status_is_error(s)) APREQ_XS_THROW_ERROR(r, s, "APR::Request::jar", ERROR_CLASS); XSRETURN_UNDEF; } } else { struct apreq_xs_do_arg d = {NULL, NULL, NULL, aTHX}; const apr_table_t *t; apr_status_t s; s = apreq_jar(req, &t); if (apreq_module_status_is_error(s)) APREQ_XS_THROW_ERROR(r, s, "APR::Request::jar", ERROR_CLASS); if (t == NULL) XSRETURN_EMPTY; d.pkg = NULL; d.parent = obj; switch (GIMME_V) { case G_ARRAY: XSprePUSH; PUTBACK; if (items == 1) apr_table_do(apreq_xs_cookie_table_keys, &d, t, NULL); else apr_table_do(apreq_xs_cookie_table_values, &d, t, SvPV_nolen(ST(1)), NULL); return; case G_SCALAR: ST(0) = apreq_xs_cookie_table2sv(aTHX_ t, COOKIE_TABLE_CLASS, obj, NULL, 0); sv_2mortal(ST(0)); XSRETURN(1); default: XSRETURN(0); } } } static XS(apreq_xs_args) { dXSARGS; apreq_handle_t *req; SV *sv, *obj; IV iv; if (items == 0 || items > 2 || !SvROK(ST(0)) || !sv_derived_from(ST(0), HANDLE_CLASS)) Perl_croak(aTHX_ "Usage: APR::Request::args($req [,$name])"); sv = ST(0); obj = apreq_xs_sv2object(aTHX_ sv, HANDLE_CLASS, 'r'); iv = SvIVX(obj); req = INT2PTR(apreq_handle_t *, iv); if (items == 2 && GIMME_V == G_SCALAR) { apreq_param_t *p = apreq_args_get(req, SvPV_nolen(ST(1))); if (p != NULL) { ST(0) = apreq_xs_param2sv(aTHX_ p, NULL, obj); sv_2mortal(ST(0)); XSRETURN(1); } else { const apr_table_t *t; apr_status_t s; s = apreq_args(req, &t); if (apreq_module_status_is_error(s)) APREQ_XS_THROW_ERROR(r, s, "APR::Request::args", ERROR_CLASS); XSRETURN_UNDEF; } } else { struct apreq_xs_do_arg d = {NULL, NULL, NULL, aTHX}; const apr_table_t *t; apr_status_t s; s = apreq_args(req, &t); if (apreq_module_status_is_error(s)) APREQ_XS_THROW_ERROR(r, s, "APR::Request::args", ERROR_CLASS); if (t == NULL) XSRETURN_EMPTY; d.pkg = NULL; d.parent = obj; switch (GIMME_V) { case G_ARRAY: XSprePUSH; PUTBACK; if (items == 1) apr_table_do(apreq_xs_param_table_keys, &d, t, NULL); else apr_table_do(apreq_xs_param_table_values, &d, t, SvPV_nolen(ST(1)), NULL); return; case G_SCALAR: ST(0) = apreq_xs_param_table2sv(aTHX_ t, PARAM_TABLE_CLASS, obj, NULL, 0); sv_2mortal(ST(0)); XSRETURN(1); default: XSRETURN(0); } } } static XS(apreq_xs_body) { dXSARGS; apreq_handle_t *req; SV *sv, *obj; IV iv; if (items == 0 || items > 2 || !SvROK(ST(0)) || !sv_derived_from(ST(0),HANDLE_CLASS)) Perl_croak(aTHX_ "Usage: APR::Request::body($req [,$name])"); sv = ST(0); obj = apreq_xs_sv2object(aTHX_ sv, HANDLE_CLASS, 'r'); iv = SvIVX(obj); req = INT2PTR(apreq_handle_t *, iv); if (items == 2 && GIMME_V == G_SCALAR) { apreq_param_t *p = apreq_body_get(req, SvPV_nolen(ST(1))); if (p != NULL) { ST(0) = apreq_xs_param2sv(aTHX_ p, NULL, obj); sv_2mortal(ST(0)); XSRETURN(1); } else { const apr_table_t *t; apr_status_t s; s = apreq_body(req, &t); if (apreq_module_status_is_error(s)) APREQ_XS_THROW_ERROR(r, s, "APR::Request::body", ERROR_CLASS); XSRETURN_UNDEF; } } else { struct apreq_xs_do_arg d = {NULL, NULL, NULL, aTHX}; const apr_table_t *t; apr_status_t s; s = apreq_body(req, &t); if (apreq_module_status_is_error(s)) APREQ_XS_THROW_ERROR(r, s, "APR::Request::body", ERROR_CLASS); if (t == NULL) XSRETURN_EMPTY; d.pkg = NULL; d.parent = obj; switch (GIMME_V) { case G_ARRAY: XSprePUSH; PUTBACK; if (items == 1) apr_table_do(apreq_xs_param_table_keys, &d, t, NULL); else apr_table_do(apreq_xs_param_table_values, &d, t, SvPV_nolen(ST(1)), NULL); return; case G_SCALAR: ST(0) = apreq_xs_param_table2sv(aTHX_ t, PARAM_TABLE_CLASS, obj, NULL, 0); sv_2mortal(ST(0)); XSRETURN(1); default: XSRETURN(0); } } } static XS(apreq_xs_param) { dXSARGS; apreq_handle_t *req; SV *sv, *obj; IV iv; if (items == 0 || items > 2 || !SvROK(ST(0)) || !sv_derived_from(ST(0), "APR::Request")) Perl_croak(aTHX_ "Usage: APR::Request::param($req [,$name])"); sv = ST(0); obj = apreq_xs_sv2object(aTHX_ sv, HANDLE_CLASS, 'r'); iv = SvIVX(obj); req = INT2PTR(apreq_handle_t *, iv); if (items == 2 && GIMME_V == G_SCALAR) { apreq_param_t *p = apreq_param(req, SvPV_nolen(ST(1))); if (p != NULL) { ST(0) = apreq_xs_param2sv(aTHX_ p, NULL, obj); sv_2mortal(ST(0)); XSRETURN(1); } else { XSRETURN_UNDEF; } } else { struct apreq_xs_do_arg d = {NULL, NULL, NULL, aTHX}; const apr_table_t *t; d.pkg = NULL; d.parent = obj; switch (GIMME_V) { case G_ARRAY: XSprePUSH; PUTBACK; if (items == 1) { apreq_args(req, &t); if (t != NULL) apr_table_do(apreq_xs_param_table_keys, &d, t, NULL); apreq_body(req, &t); if (t != NULL) apr_table_do(apreq_xs_param_table_keys, &d, t, NULL); } else { char *val = SvPV_nolen(ST(1)); apreq_args(req, &t); if (t != NULL) apr_table_do(apreq_xs_param_table_values, &d, t, val, NULL); apreq_body(req, &t); if (t != NULL) apr_table_do(apreq_xs_param_table_values, &d, t, val, NULL); } return; case G_SCALAR: t = apreq_params(req, req->pool); if (t == NULL) XSRETURN_UNDEF; ST(0) = apreq_xs_param_table2sv(aTHX_ t, PARAM_TABLE_CLASS, obj, NULL, 0); sv_2mortal(ST(0)); XSRETURN(1); default: XSRETURN(0); } } } static XS(apreq_xs_parse) { dXSARGS; apreq_handle_t *req; apr_status_t s; const apr_table_t *t; if (items != 1 || !SvROK(ST(0))) Perl_croak(aTHX_ "Usage: APR::Request::parse($req)"); req = apreq_xs_sv2handle(aTHX_ ST(0)); XSprePUSH; EXTEND(SP, 3); s = apreq_jar(req, &t); PUSHs(sv_2mortal(apreq_xs_error2sv(aTHX_ s))); s = apreq_args(req, &t); PUSHs(sv_2mortal(apreq_xs_error2sv(aTHX_ s))); s = apreq_body(req, &t); PUSHs(sv_2mortal(apreq_xs_error2sv(aTHX_ s))); PUTBACK; } struct hook_ctx { SV *hook; SV *bucket_data; SV *parent; PerlInterpreter *perl; }; #define DEREF(slot) if (ctx->slot) SvREFCNT_dec(ctx->slot) static apr_status_t upload_hook_cleanup(void *ctx_) { struct hook_ctx *ctx = ctx_; #ifdef USE_ITHREADS dTHXa(ctx->perl); #endif DEREF(hook); DEREF(bucket_data); DEREF(parent); return APR_SUCCESS; } APR_INLINE static apr_status_t eval_upload_hook(pTHX_ apreq_param_t *upload, struct hook_ctx *ctx) { dSP; SV *sv = ctx->bucket_data; STRLEN len = SvPOK(sv) ? SvCUR(sv) : 0; PUSHMARK(SP); EXTEND(SP, 3); ENTER; SAVETMPS; sv = apreq_xs_param2sv(aTHX_ upload, PARAM_CLASS, ctx->parent); PUSHs(sv_2mortal(sv)); PUSHs(ctx->bucket_data); PUSHs(sv_2mortal(newSViv(len))); PUTBACK; perl_call_sv(ctx->hook, G_EVAL|G_DISCARD); FREETMPS; LEAVE; if (SvTRUE(ERRSV)) { Perl_warn(aTHX_ "Upload hook failed: %s", SvPV_nolen(ERRSV)); return APREQ_ERROR_GENERAL; } return APR_SUCCESS; } static apr_status_t apreq_xs_upload_hook(APREQ_HOOK_ARGS) { struct hook_ctx *ctx = hook->ctx; /* ctx set during $req->config */ apr_bucket *e; apr_status_t s = APR_SUCCESS; #ifdef USE_ITHREADS dTHXa(ctx->perl); #endif if (bb == NULL) { if (hook->next) return apreq_hook_run(hook->next, param, bb); return APR_SUCCESS; } for (e = APR_BRIGADE_FIRST(bb); e!= APR_BRIGADE_SENTINEL(bb); e = APR_BUCKET_NEXT(e)) { apr_size_t len; const char *data; if (APR_BUCKET_IS_EOS(e)) { /*last call on this upload */ SV *sv = ctx->bucket_data; ctx->bucket_data = &PL_sv_undef; s = eval_upload_hook(aTHX_ param, ctx); ctx->bucket_data = sv; if (s != APR_SUCCESS) return s; break; } s = apr_bucket_read(e, &data, &len, APR_BLOCK_READ); if (s != APR_SUCCESS) { s = APR_SUCCESS; continue; } sv_setpvn(ctx->bucket_data, data, (STRLEN)len); s = eval_upload_hook(aTHX_ param, ctx); if (s != APR_SUCCESS) return s; } if (hook->next) s = apreq_hook_run(hook->next, param, bb); return s; } rapache-1.2.8/libapreq2/glue/perl/xsbuilder/APR/Request/Apache2/0000755000175100017510000000000012706745114023557 5ustar ondrejondrejrapache-1.2.8/libapreq2/glue/perl/xsbuilder/APR/Request/Apache2/APR__Request__Apache2.h0000644000175100017510000000002612706745114027701 0ustar ondrejondrej#include "mod_perl.h" rapache-1.2.8/libapreq2/glue/perl/xsbuilder/APR/Request/Apache2/Apache2.pm0000644000175100017510000000006112706745114025355 0ustar ondrejondrejrequire APR::Request; push @ISA, "APR::Request"; rapache-1.2.8/libapreq2/glue/perl/xsbuilder/APR/Request/Apache2/Apache2.pod0000644000175100017510000000242312706745114025527 0ustar ondrejondrej=head1 NAME APR::Request::Apache2 - wrapper for a mod_apreq2 handle. =head1 SYNOPSIS use APR::Request::Apache2; my $req = APR::Request::Apache2->handle($r); =head1 DESCRIPTION The APR::Request::Apache2 module provides a constructor for interfacing with the mod_apreq2 Apache module. This manpage documents the APR::Request::Apache2 package. =head1 METHODS APR::Request::Apache2 - derived from C<< APR::Request >>. =head2 handle APR::Request::Apache2->handle($r) Creates an APR::Request::Apache2 object. The argument C<< $r >> is an Apache2::RequestRec object (from mod_perl2). =head1 SEE ALSO L<< APR::Request >>, L<< Apache2::RequestRec >>. =head1 COPYRIGHT Copyright 2003-2005 The Apache Software Foundation Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. rapache-1.2.8/libapreq2/glue/perl/xsbuilder/APR/Request/Apache2/Apache2.xs0000644000175100017510000000067712706745114025410 0ustar ondrejondrejMODULE = APR::Request::Apache2 PACKAGE = APR::Request::Apache2 BOOT: { apr_version_t version; apr_version(&version); if (version.major != APR_MAJOR_VERSION) Perl_croak(aTHX_ "Can't load module APR::Request::Apache2 : " "wrong libapr major version " "(expected %d, saw %d)", APR_MAJOR_VERSION, version.major); } rapache-1.2.8/libapreq2/glue/perl/xsbuilder/APR/Request/CGI/0000755000175100017510000000000012706745114022716 5ustar ondrejondrejrapache-1.2.8/libapreq2/glue/perl/xsbuilder/APR/Request/CGI/CGI.pm0000644000175100017510000000112512706745114023655 0ustar ondrejondrejrequire APR::Request; use APR::Pool; push @ISA, "APR::Request"; sub upload { my $req = shift; my $body = $req->body; $body->param_class("APR::Request::CGI::Upload"); if (@_) { return grep {$_->upload} $body->get(shift) if wantarray; for ($body->get(shift)) { return $_ if $_->upload; } } return map {$_->upload ? $_->name : () } values %$body; } package APR::Request::CGI::Upload; use APR::Request::Param; push our @ISA, "APR::Request::Param"; sub type {} sub filename {} sub link {} sub fh {} sub tempname {} sub io {} sub slurp {} rapache-1.2.8/libapreq2/glue/perl/xsbuilder/APR/Request/CGI/CGI.pod0000644000175100017510000000235312706745114024027 0ustar ondrejondrej=head1 NAME APR::Request::CGI - wrapper for libapreq2's CGI handle. =head1 SYNOPSIS use APR::Request::CGI; my $req = APR::Request::CGI->handle($pool); =head1 DESCRIPTION The APR::Request::CGI module provides a constructor for accessing CGI request data associated to a pool via libapreq2. This manpage documents the APR::Request::CGI package. =head1 METHODS APR::Request::CGI - derived from C<< APR::Request >>. =head2 handle APR::Request::CGI->handle($pool) Creates an APR::Request::CGI object. The argument C<< $pool >> is an APR::Pool object. =head1 SEE ALSO L<< APR::Request >>, L<< APR::Pool >>. =head1 COPYRIGHT Copyright 2003-2005 The Apache Software Foundation Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. rapache-1.2.8/libapreq2/glue/perl/xsbuilder/APR/Request/CGI/CGI.xs0000644000175100017510000000110612706745114023672 0ustar ondrejondrejstatic apr_pool_t *apreq_xs_cgi_global_pool; MODULE = APR::Request::CGI PACKAGE = APR::Request::CGI BOOT: { apr_version_t version; apr_version(&version); if (version.major != APR_MAJOR_VERSION) Perl_croak(aTHX_ "Can't load module APR::Request::CGI : " "wrong libapr major version " "(expected %d, saw %d)", APR_MAJOR_VERSION, version.major); } apr_pool_create(&apreq_xs_cgi_global_pool, NULL); apreq_initialize(apreq_xs_cgi_global_pool); rapache-1.2.8/libapreq2/glue/perl/xsbuilder/APR/Request/Cookie/0000755000175100017510000000000012706745114023525 5ustar ondrejondrejrapache-1.2.8/libapreq2/glue/perl/xsbuilder/APR/Request/Cookie/APR__Request__Cookie.h0000644000175100017510000001045312706745114027622 0ustar ondrejondrejstatic int apreq_xs_cookie_table_values(void *data, const char *key, const char *val) { struct apreq_xs_do_arg *d = (struct apreq_xs_do_arg *)data; dTHXa(d->perl); dSP; apreq_cookie_t *c = apreq_value_to_cookie(val); SV *sv = apreq_xs_cookie2sv(aTHX_ c, d->pkg, d->parent); XPUSHs(sv_2mortal(sv)); PUTBACK; return 1; } static int apreq_xs_cookie_table_do_sub(void *data, const char *key, const char *val) { struct apreq_xs_do_arg *d = data; apreq_cookie_t *c = apreq_value_to_cookie(val); dTHXa(d->perl); dSP; SV *sv = apreq_xs_cookie2sv(aTHX_ c, d->pkg, d->parent); int rv; ENTER; SAVETMPS; PUSHMARK(SP); EXTEND(SP,2); PUSHs(sv_2mortal(newSVpvn(c->v.name, c->v.nlen))); PUSHs(sv_2mortal(sv)); PUTBACK; rv = call_sv(d->sub, G_SCALAR); SPAGAIN; rv = (1 == rv) ? POPi : 1; PUTBACK; FREETMPS; LEAVE; return rv; } static XS(apreq_xs_cookie_table_do) { dXSARGS; struct apreq_xs_do_arg d = { NULL, NULL, NULL, aTHX }; const apr_table_t *t; int i, rv = 1; SV *sv, *t_obj; IV iv; MAGIC *mg; if (items < 2 || !SvROK(ST(0)) || !SvROK(ST(1))) Perl_croak(aTHX_ "Usage: $object->do(\\&callback, @keys)"); sv = ST(0); t_obj = apreq_xs_sv2object(aTHX_ sv, COOKIE_TABLE_CLASS, 't'); iv = SvIVX(t_obj); t = INT2PTR(const apr_table_t *, iv); mg = mg_find(t_obj, PERL_MAGIC_ext); d.parent = mg->mg_obj; d.pkg = mg->mg_ptr; d.sub = ST(1); if (items == 2) { rv = apr_table_do(apreq_xs_cookie_table_do_sub, &d, t, NULL); XSRETURN_IV(rv); } for (i = 2; i < items; ++i) { const char *key = SvPV_nolen(ST(i)); rv = apr_table_do(apreq_xs_cookie_table_do_sub, &d, t, key, NULL); if (rv == 0) break; } XSRETURN_IV(rv); } static XS(apreq_xs_cookie_table_FETCH) { dXSARGS; const apr_table_t *t; const char *cookie_class; SV *sv, *obj, *parent; IV iv; MAGIC *mg; if (items != 2 || !SvROK(ST(0)) || !sv_derived_from(ST(0), COOKIE_TABLE_CLASS)) Perl_croak(aTHX_ "Usage: " COOKIE_TABLE_CLASS "::FETCH($table, $key)"); sv = ST(0); obj = apreq_xs_sv2object(aTHX_ sv, COOKIE_TABLE_CLASS, 't'); iv = SvIVX(obj); t = INT2PTR(const apr_table_t *, iv); mg = mg_find(obj, PERL_MAGIC_ext); cookie_class = mg->mg_ptr; parent = mg->mg_obj; if (GIMME_V == G_SCALAR) { IV idx; const char *key, *val; const apr_array_header_t *arr; apr_table_entry_t *te; key = SvPV_nolen(ST(1)); idx = SvCUR(obj); arr = apr_table_elts(t); te = (apr_table_entry_t *)arr->elts; if (idx > 0 && idx <= arr->nelts && !strcasecmp(key, te[idx-1].key)) val = te[idx-1].val; else val = apr_table_get(t, key); if (val != NULL) { apreq_cookie_t *c = apreq_value_to_cookie(val); ST(0) = apreq_xs_cookie2sv(aTHX_ c, cookie_class, parent); sv_2mortal(ST(0)); XSRETURN(1); } else { XSRETURN_UNDEF; } } else if (GIMME_V == G_ARRAY) { struct apreq_xs_do_arg d = {NULL, NULL, NULL, aTHX}; d.pkg = cookie_class; d.parent = parent; XSprePUSH; PUTBACK; apr_table_do(apreq_xs_cookie_table_values, &d, t, SvPV_nolen(ST(1)), NULL); } else XSRETURN(0); } static XS(apreq_xs_cookie_table_NEXTKEY) { dXSARGS; SV *sv, *obj; IV iv, idx; const apr_table_t *t; const apr_array_header_t *arr; apr_table_entry_t *te; if (!SvROK(ST(0))) Perl_croak(aTHX_ "Usage: $table->NEXTKEY($prev)"); sv = ST(0); obj = apreq_xs_sv2object(aTHX_ sv, COOKIE_TABLE_CLASS, 't'); iv = SvIVX(obj); t = INT2PTR(const apr_table_t *, iv); arr = apr_table_elts(t); te = (apr_table_entry_t *)arr->elts; if (items == 1) SvCUR(obj) = 0; if (SvCUR(obj) >= arr->nelts) { SvCUR(obj) = 0; XSRETURN_UNDEF; } idx = SvCUR(obj)++; sv = newSVpv(te[idx].key, 0); ST(0) = sv_2mortal(sv); XSRETURN(1); } static XS(XS_APR__Request__Cookie_nil) { dXSARGS; (void)items; XSRETURN_EMPTY; } rapache-1.2.8/libapreq2/glue/perl/xsbuilder/APR/Request/Cookie/Cookie.pm0000644000175100017510000000106012706745114025271 0ustar ondrejondrejuse APR::Request; sub new { my ($class, $pool, %attrs) = @_; my $name = delete $attrs{name}; my $value = delete $attrs{value}; $name = delete $attrs{-name} unless defined $name; $value = delete $attrs{-value} unless defined $value; return unless defined $name and defined $value; my $cookie = $class->make($pool, $name, $class->freeze($value)); while(my ($k, $v) = each %attrs) { $k =~ s/^-//; $cookie->$k($v); } return $cookie; } sub freeze { return $_[1] } sub thaw { return shift->value } rapache-1.2.8/libapreq2/glue/perl/xsbuilder/APR/Request/Cookie/Cookie.pod0000644000175100017510000001157012706745114025446 0ustar ondrejondrej=head1 NAME APR::Request::Cookie - wrapper for libapreq2's cookie API. =head1 SYNOPSIS use APR::Request::Cookie; my $cookie = APR::Request::Cookie->new($req, name => "foo", value => "bar", domain => "capricorn.com"); print "$cookie"; # prints "bar" $cookie->domain("example.com"); # change domains $cookie->version(1); # upgrade it to conform with RFC 2109/2965. # print a response header printf "Set-Cookie: %s\n", $cookie->as_string; =head1 DESCRIPTION The APR::Request::Cookie module provides base methods for interfacing with libapreq2's cookie API. It also provides a few utility functions and constants. This manpage documents the APR::Request::Cookie and APR::Request::Cookie::Table packages. =head1 OVERLOADS APR::Request::Cookie =head2 "" "$cookie" The double-quote interpolation operator maps to C<< APR::Request::Cookie::value() >>. =head1 METHODS APR::Request::Cookie =head2 new APR::Request::Cookie->new($pool, name => $name, value => $value, %args) Creates a new cookie. Here C<< $pool >> is an APR::Pool object, and C<< $name >> is the cookie's name. The C<< $value >> is transformed into the cookie's raw value through the class' C<< freeze() >> method. The remaining arguments are optional: =over 4 =item -secure =item -version =item -path =item -domain =item -port =item -expires =item -comment =item -commentURL =back For details on these arguments, please consult the corresponding method's documentation. =head2 freeze APR::Request::Cookie->freeze($value) Default serializer- returns $value unmodified. =head2 thaw APR::Request::Cookie->thaw($value) Reverses C<< freeze() >>; here it's a noop. =head2 name $cookie->name() Fetch the cookie's name. This attribute cannot be modified. =head2 value $cookie->value() Fetch the cookie's value. This attribute cannot be modified. =head2 secure $cookie->secure() $cookie->secure($set) Get/set the cookie's secure flag. =head2 version $cookie->version() $cookie->version($set) Get/set the cookie's version number. Version 0 cookies conform to the Netscape spec; Version 1 cookies conform to either RFC 2109 or RFC 2965. =head2 path $cookie->path() $cookie->path($set) Get/set the cookie's path string. =head2 domain $cookie->domain() $cookie->domain($set) Get/set the cookie's domain string. =head2 port $cookie->port() $cookie->port($set) Get/set the cookie's port string. Only valid for Version 1 cookies. =head2 comment $cookie->comment() $cookie->comment($set) Get/set the cookie's comment string. Only valid for Version 1 cookies. =head2 commentURL $cookie->commentURL() $cookie->commentURL($set) Get/set the cookie's commentURL string. Only valid for Version 1 cookies. =head2 is_tainted $cookie->is_tainted() $cookie->is_tainted($set) Get/set the cookie's internal tainted flag. =head2 make APR::Request::Cookie->make($pool, $name, $value) Fast XS cookie constructor invoked by C<< new() >>. The cookie's raw name & value are taken directly from the passed in arguments; no freezing/encoding is done on the $value. =head2 as_string $cookie->as_string() String representation of the cookie, suitable for inclusion in a "Set-Cookie" header. =head1 SUBROUTINES APR::Request::Cookie =head2 expires expires($date_string) =head1 METHODS APR::Request::Cookie::Table - read-only version of APR::Table. Tables in this class normally arise from calls to C<< APR::Request::jar() >>. =head2 cookie_class $table->cookie_class() $table->cookie_class($set) Get/set the class each table element is blessed into during a L or L call. If defined, the class must be derived from APR::Request::Cookie. =head2 get $table->get($name) $table->get() =head2 FETCH $table->FETCH($name) =head2 FIRSTKEY $table->FIRSTKEY() =head2 NEXTKEY $table->NEXTKEY() =head2 do $table->do($callback, @keys) =head1 SEE ALSO L<< Apache2::Cookie >>, L<< APR::Request >> =head1 COPYRIGHT Copyright 2003-2005 The Apache Software Foundation Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. rapache-1.2.8/libapreq2/glue/perl/xsbuilder/APR/Request/Cookie/Cookie.xs0000644000175100017510000001017212706745114025313 0ustar ondrejondrejMODULE = APR::Request::Cookie PACKAGE = APR::Request::Cookie SV * value(obj, p1=NULL, p2=NULL) APR::Request::Cookie obj SV *p1 SV *p2 PREINIT: /*nada*/ CODE: RETVAL = newSVpvn(obj->v.data, obj->v.dlen); if (apreq_cookie_is_tainted(obj)) SvTAINTED_on(RETVAL); OUTPUT: RETVAL BOOT: { apr_version_t version; apr_version(&version); if (version.major != APR_MAJOR_VERSION) Perl_croak(aTHX_ "Can't load module APR::Request::Cookie : " "wrong libapr major version " "(expected %d, saw %d)", APR_MAJOR_VERSION, version.major); } /* register the overloading (type 'A') magic */ PL_amagic_generation++; /* The magic for overload gets a GV* via gv_fetchmeth as */ /* mentioned above, and looks in the SV* slot of it for */ /* the "fallback" status. */ sv_setsv( get_sv( "APR::Request::Cookie::()", TRUE ), &PL_sv_yes ); newXS("APR::Request::Cookie::()", XS_APR__Request__Cookie_nil, file); newXS("APR::Request::Cookie::(\"\"", XS_APR__Request__Cookie_value, file); MODULE = APR::Request::Cookie PACKAGE = APR::Request::Cookie SV * name(obj) APR::Request::Cookie obj CODE: RETVAL = newSVpvn(obj->v.name, obj->v.nlen); if (apreq_cookie_is_tainted(obj)) SvTAINTED_on(RETVAL); OUTPUT: RETVAL UV secure(obj, val=NULL) APR::Request::Cookie obj SV *val CODE: RETVAL = apreq_cookie_is_secure(obj); if (items == 2) { if (SvTRUE(val)) apreq_cookie_secure_on(obj); else apreq_cookie_secure_off(obj); } OUTPUT: RETVAL UV version(obj, val=0) APR::Request::Cookie obj UV val CODE: RETVAL = apreq_cookie_version(obj); if (items == 2) apreq_cookie_version_set(obj, val); OUTPUT: RETVAL IV is_tainted(obj, val=NULL) APR::Request::Cookie obj SV *val PREINIT: /*nada*/ CODE: RETVAL = apreq_cookie_is_tainted(obj); if (items == 2) { if (SvTRUE(val)) apreq_cookie_tainted_on(obj); else apreq_cookie_tainted_off(obj); } OUTPUT: RETVAL SV* bind_handle(cookie, req) SV *cookie SV *req PREINIT: MAGIC *mg; SV *obj; CODE: obj = apreq_xs_sv2object(aTHX_ cookie, COOKIE_CLASS, 'c'); mg = mg_find(obj, PERL_MAGIC_ext); req = apreq_xs_sv2object(aTHX_ req, HANDLE_CLASS, 'r'); RETVAL = newRV_noinc(mg->mg_obj); SvREFCNT_inc(req); mg->mg_obj = req; OUTPUT: RETVAL APR::Request::Cookie make(class, pool, name, val) apreq_xs_subclass_t class APR::Pool pool SV *name SV *val PREINIT: STRLEN nlen, vlen; const char *n, *v; SV *parent = SvRV(ST(1)); CODE: n = SvPV(name, nlen); v = SvPV(val, vlen); RETVAL = apreq_cookie_make(pool, n, nlen, v, vlen); if (SvTAINTED(name) || SvTAINTED(val)) apreq_cookie_tainted_on(RETVAL); OUTPUT: RETVAL SV * as_string(c) APR::Request::Cookie c PREINIT: char rv[APREQ_COOKIE_MAX_LENGTH]; STRLEN len; CODE: len = apreq_cookie_serialize(c, rv, sizeof rv); RETVAL = newSVpvn(rv, len); if (apreq_cookie_is_tainted(c)) SvTAINTED_on(RETVAL); OUTPUT: RETVAL MODULE = APR::Request::Cookie PACKAGE = APR::Request::Cookie::Table SV * cookie_class(t, newclass=NULL) APR::Request::Cookie::Table t char *newclass PREINIT: SV *obj = apreq_xs_sv2object(aTHX_ ST(0), COOKIE_TABLE_CLASS, 't'); MAGIC *mg = mg_find(obj, PERL_MAGIC_ext); char *curclass = mg->mg_ptr; CODE: RETVAL = (curclass == NULL) ? &PL_sv_undef : newSVpv(curclass, 0); if (newclass != NULL) { if (!sv_derived_from(ST(1), COOKIE_CLASS)) Perl_croak(aTHX_ "Usage: " COOKIE_TABLE_CLASS "::cookie_class($table, $class): " "class %s is not derived from " COOKIE_CLASS, newclass); mg->mg_ptr = savepv(newclass); mg->mg_len = strlen(newclass); if (curclass != NULL) Safefree(curclass); } OUTPUT: RETVAL rapache-1.2.8/libapreq2/glue/perl/xsbuilder/APR/Request/Error/0000755000175100017510000000000012706745114023405 5ustar ondrejondrejrapache-1.2.8/libapreq2/glue/perl/xsbuilder/APR/Request/Error/APR__Request__Error.h0000644000175100017510000000013412706745114027355 0ustar ondrejondrejstatic XS(XS_APR__Request__Error_nil) { dXSARGS; (void)items; XSRETURN_EMPTY; } rapache-1.2.8/libapreq2/glue/perl/xsbuilder/APR/Request/Error/Error.pm0000644000175100017510000000007112706745114025032 0ustar ondrejondrejuse APR::Error; our @ISA = qw/APR::Error APR::Request/; rapache-1.2.8/libapreq2/glue/perl/xsbuilder/APR/Request/Error/Error.pod0000644000175100017510000000210012706745114025173 0ustar ondrejondrej=head1 NAME APR::Request::Error - wrapper for libapreq2's error API. =head1 SYNOPSIS use APR::Request::Error; =head1 DESCRIPTION This manpage documents the APR::Request::Error package. =head1 SUBROUTINES APR::Request::Error - derived from C<< APR::Request >> and C<< APR::Error >>. =head2 strerror strerror($status) Returns the apreq error string associated with a numeric C<$status> code. =head1 SEE ALSO L, L =head1 COPYRIGHT Copyright 2003-2005 The Apache Software Foundation Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. rapache-1.2.8/libapreq2/glue/perl/xsbuilder/APR/Request/Error/Error.xs0000644000175100017510000000305712706745114025057 0ustar ondrejondrejMODULE = APR::Request::Error PACKAGE = APR::Request::Error SV *strerror(s) apr_status_t s CODE: RETVAL = apreq_xs_error2sv(aTHX_ s); OUTPUT: RETVAL SV *as_string(hv, p1=NULL, p2=NULL) APR::Request::Error hv SV *p1 SV *p2 PREINIT: SV **svp; CODE: svp = hv_fetch(hv, "rc", 2, FALSE); if (svp == NULL) RETVAL = &PL_sv_undef; else RETVAL = apreq_xs_error2sv(aTHX_ SvIVX(*svp)); OUTPUT: RETVAL BOOT: { apr_version_t version; apr_version(&version); if (version.major != APR_MAJOR_VERSION) Perl_croak(aTHX_ "Can't load module APR::Request::Error : " "wrong libapr major version " "(expected %d, saw %d)", APR_MAJOR_VERSION, version.major); } /* register the overloading (type 'A') magic */ PL_amagic_generation++; /* The magic for overload gets a GV* via gv_fetchmeth as */ /* mentioned above, and looks in the SV* slot of it for */ /* the "fallback" status. */ sv_setsv( get_sv( "APR::Request::Error::()", TRUE ), &PL_sv_undef ); newXS("APR::Request::Error::()", XS_APR__Request__Error_nil, file); newXS("APR::Request::Error::(\"\"", XS_APR__Request__Error_as_string, file); newCONSTSUB(PL_defstash, "APR::Request::Error::GENERAL", apreq_xs_error2sv(aTHX_ APREQ_ERROR_GENERAL)); newCONSTSUB(PL_defstash, "APR::Request::Error::TAINTED", apreq_xs_error2sv(aTHX_ APREQ_ERROR_TAINTED)); rapache-1.2.8/libapreq2/glue/perl/xsbuilder/APR/Request/Param/0000755000175100017510000000000012706745114023354 5ustar ondrejondrejrapache-1.2.8/libapreq2/glue/perl/xsbuilder/APR/Request/Param/APR__Request__Param.h0000644000175100017510000002332312706745114027300 0ustar ondrejondrejstatic int apreq_xs_param_table_values(void *data, const char *key, const char *val) { struct apreq_xs_do_arg *d = (struct apreq_xs_do_arg *)data; dTHXa(d->perl); dSP; apreq_param_t *p = apreq_value_to_param(val); SV *sv = apreq_xs_param2sv(aTHX_ p, d->pkg, d->parent); XPUSHs(sv_2mortal(sv)); PUTBACK; return 1; } static int apreq_xs_param_table_do_sub(void *data, const char *key, const char *val) { struct apreq_xs_do_arg *d = data; apreq_param_t *p = apreq_value_to_param(val); dTHXa(d->perl); dSP; SV *sv = apreq_xs_param2sv(aTHX_ p, d->pkg, d->parent); int rv; ENTER; SAVETMPS; PUSHMARK(SP); EXTEND(SP,2); PUSHs(sv_2mortal(newSVpvn(p->v.name, p->v.nlen))); PUSHs(sv_2mortal(sv)); PUTBACK; rv = call_sv(d->sub, G_SCALAR); SPAGAIN; rv = (1 == rv) ? POPi : 1; PUTBACK; FREETMPS; LEAVE; return rv; } static XS(apreq_xs_param_table_do) { dXSARGS; struct apreq_xs_do_arg d = { NULL, NULL, NULL, aTHX }; const apr_table_t *t; int i, rv = 1; SV *sv, *t_obj; IV iv; MAGIC *mg; if (items < 2 || !SvROK(ST(0)) || !SvROK(ST(1))) Perl_croak(aTHX_ "Usage: $object->do(\\&callback, @keys)"); sv = ST(0); t_obj = apreq_xs_sv2object(aTHX_ sv, PARAM_TABLE_CLASS, 't'); iv = SvIVX(t_obj); t = INT2PTR(const apr_table_t *, iv); mg = mg_find(t_obj, PERL_MAGIC_ext); d.parent = mg->mg_obj; d.pkg = mg->mg_ptr; d.sub = ST(1); if (items == 2) { rv = apr_table_do(apreq_xs_param_table_do_sub, &d, t, NULL); XSRETURN_IV(rv); } for (i = 2; i < items; ++i) { const char *key = SvPV_nolen(ST(i)); rv = apr_table_do(apreq_xs_param_table_do_sub, &d, t, key, NULL); if (rv == 0) break; } XSRETURN_IV(rv); } static XS(apreq_xs_param_table_FETCH) { dXSARGS; const apr_table_t *t; const char *param_class; SV *sv, *t_obj, *parent; IV iv; MAGIC *mg; if (items != 2 || !SvROK(ST(0)) || !sv_derived_from(ST(0), PARAM_TABLE_CLASS)) Perl_croak(aTHX_ "Usage: " PARAM_TABLE_CLASS "::FETCH($table, $key)"); sv = ST(0); t_obj = apreq_xs_sv2object(aTHX_ sv, PARAM_TABLE_CLASS, 't'); iv = SvIVX(t_obj); t = INT2PTR(const apr_table_t *, iv); mg = mg_find(t_obj, PERL_MAGIC_ext); param_class = mg->mg_ptr; parent = mg->mg_obj; if (GIMME_V == G_SCALAR) { IV idx; const char *key, *val; const apr_array_header_t *arr; apr_table_entry_t *te; key = SvPV_nolen(ST(1)); idx = SvCUR(t_obj); arr = apr_table_elts(t); te = (apr_table_entry_t *)arr->elts; if (idx > 0 && idx <= arr->nelts && !strcasecmp(key, te[idx-1].key)) val = te[idx-1].val; else val = apr_table_get(t, key); if (val != NULL) { apreq_param_t *p = apreq_value_to_param(val); ST(0) = apreq_xs_param2sv(aTHX_ p, param_class, parent); sv_2mortal(ST(0)); XSRETURN(1); } else { XSRETURN_UNDEF; } } else if (GIMME_V == G_ARRAY) { struct apreq_xs_do_arg d = {NULL, NULL, NULL, aTHX}; d.pkg = param_class; d.parent = parent; XSprePUSH; PUTBACK; apr_table_do(apreq_xs_param_table_values, &d, t, SvPV_nolen(ST(1)), NULL); } else XSRETURN(0); } static XS(apreq_xs_param_table_NEXTKEY) { dXSARGS; SV *sv, *obj; IV iv, idx; const apr_table_t *t; const apr_array_header_t *arr; apr_table_entry_t *te; if (!SvROK(ST(0)) || !sv_derived_from(ST(0), PARAM_TABLE_CLASS)) Perl_croak(aTHX_ "Usage: " PARAM_TABLE_CLASS "::NEXTKEY($table, $key)"); sv = ST(0); obj = apreq_xs_sv2object(aTHX_ sv, PARAM_TABLE_CLASS,'t'); iv = SvIVX(obj); t = INT2PTR(const apr_table_t *, iv); arr = apr_table_elts(t); te = (apr_table_entry_t *)arr->elts; if (items == 1) SvCUR(obj) = 0; if (SvCUR(obj) >= arr->nelts) { SvCUR(obj) = 0; XSRETURN_UNDEF; } idx = SvCUR(obj)++; sv = newSVpv(te[idx].key, 0); ST(0) = sv_2mortal(sv); XSRETURN(1); } static XS(XS_APR__Request__Param_nil) { dXSARGS; (void)items; XSRETURN_EMPTY; } APR_INLINE static SV *apreq_xs_find_bb_obj(pTHX_ SV *in) { while (in && SvROK(in)) { SV *sv = SvRV(in); switch (SvTYPE(sv)) { MAGIC *mg; case SVt_PVIO: if (SvMAGICAL(sv) && (mg = mg_find(sv, PERL_MAGIC_tiedscalar))) { in = mg->mg_obj; break; } Perl_croak(aTHX_ "panic: cannot find tied scalar in pvio magic"); case SVt_PVMG: if (SvOBJECT(sv) && SvIOKp(sv)) return sv; default: Perl_croak(aTHX_ "panic: unsupported SV type: %d", SvTYPE(sv)); } } return in; } /* XXX these Apache::Upload::Brigade funcs need a makeover as vanilla XS. */ static XS(apreq_xs_brigade_copy) { dXSARGS; apr_bucket_brigade *bb, *bb_copy; char *class; SV *sv, *obj; IV iv; if (items != 2 || !SvPOK(ST(0)) || !SvROK(ST(1))) Perl_croak(aTHX_ "Usage: APR::Request::Brigade->new($bb)"); class = SvPV_nolen(ST(0)); obj = apreq_xs_find_bb_obj(aTHX_ ST(1)); iv = SvIVX(obj); bb = INT2PTR(apr_bucket_brigade *, iv); bb_copy = apr_brigade_create(bb->p, bb->bucket_alloc); apreq_brigade_copy(bb_copy, bb); sv = sv_setref_pv(newSV(0), class, bb_copy); if (SvTAINTED(obj)) SvTAINTED_on(SvRV(sv)); ST(0) = sv_2mortal(sv); XSRETURN(1); } static XS(apreq_xs_brigade_read) { dXSARGS; apr_bucket_brigade *bb; apr_bucket *e, *end; IV want = -1, offset = 0; SV *sv, *obj; apr_status_t s; char *buf; switch (items) { case 4: offset = SvIV(ST(3)); case 3: want = SvIV(ST(2)); case 2: sv = ST(1); SvUPGRADE(sv, SVt_PV); if (SvROK(ST(0))) { IV iv; obj = apreq_xs_find_bb_obj(aTHX_ ST(0)); iv = SvIVX(obj); bb = INT2PTR(apr_bucket_brigade *, iv); break; } default: Perl_croak(aTHX_ "Usage: $bb->READ($buf,$len,$off)"); } if (want == 0) { SvCUR_set(sv, offset); XSRETURN_IV(0); } if (APR_BRIGADE_EMPTY(bb)) { SvCUR_set(sv, offset); XSRETURN_UNDEF; } if (want == -1) { const char *data; apr_size_t dlen; e = APR_BRIGADE_FIRST(bb); s = apr_bucket_read(e, &data, &dlen, APR_BLOCK_READ); if (s != APR_SUCCESS) apreq_xs_croak(aTHX_ newHV(), s, "APR::Request::Brigade::READ", "APR::Error"); want = dlen; end = APR_BUCKET_NEXT(e); } else { switch (s = apr_brigade_partition(bb, (apr_off_t)want, &end)) { apr_off_t len; case APR_INCOMPLETE: s = apr_brigade_length(bb, 1, &len); if (s != APR_SUCCESS) apreq_xs_croak(aTHX_ newHV(), s, "APR::Request::Brigade::READ", "APR::Error"); want = len; case APR_SUCCESS: break; default: apreq_xs_croak(aTHX_ newHV(), s, "APR::Request::Brigade::READ", "APR::Error"); } } SvGROW(sv, want + offset + 1); buf = SvPVX(sv) + offset; SvCUR_set(sv, want + offset); if (SvTAINTED(obj)) SvTAINTED_on(sv); while ((e = APR_BRIGADE_FIRST(bb)) != end) { const char *data; apr_size_t dlen; s = apr_bucket_read(e, &data, &dlen, APR_BLOCK_READ); if (s != APR_SUCCESS) apreq_xs_croak(aTHX_ newHV(), s, "APR::Request::Brigade::READ", "APR::Error"); memcpy(buf, data, dlen); buf += dlen; apr_bucket_delete(e); } *buf = 0; SvPOK_only(sv); SvSETMAGIC(sv); XSRETURN_IV(want); } static XS(apreq_xs_brigade_readline) { dXSARGS; apr_bucket_brigade *bb; apr_bucket *e; SV *sv, *obj; IV iv; apr_status_t s; unsigned tainted; if (items != 1 || !SvROK(ST(0))) Perl_croak(aTHX_ "Usage: $bb->READLINE"); obj = apreq_xs_find_bb_obj(aTHX_ ST(0)); iv = SvIVX(obj); bb = INT2PTR(apr_bucket_brigade *, iv); if (APR_BRIGADE_EMPTY(bb)) XSRETURN(0); tainted = SvTAINTED(obj); XSprePUSH; sv = sv_2mortal(newSVpvn("",0)); if (tainted) SvTAINTED_on(sv); XPUSHs(sv); while (!APR_BRIGADE_EMPTY(bb)) { const char *data; apr_size_t dlen; const char *eol; e = APR_BRIGADE_FIRST(bb); s = apr_bucket_read(e, &data, &dlen, APR_BLOCK_READ); if (s != APR_SUCCESS) apreq_xs_croak(aTHX_ newHV(), s, "APR::Request::Brigade::READLINE", "APR::Error"); eol = memchr(data, '\012', dlen); /* look for LF (linefeed) */ if (eol != NULL) { if (eol < data + dlen - 1) { dlen = eol - data + 1; apr_bucket_split(e, dlen); } sv_catpvn(sv, data, dlen); apr_bucket_delete(e); if (GIMME_V != G_ARRAY || APR_BRIGADE_EMPTY(bb)) break; sv = sv_2mortal(newSVpvn("",0)); if (tainted) SvTAINTED_on(sv); XPUSHs(sv); } else { sv_catpvn(sv, data, dlen); apr_bucket_delete(e); } } PUTBACK; } rapache-1.2.8/libapreq2/glue/perl/xsbuilder/APR/Request/Param/Param.pm0000644000175100017510000000152612706745114024756 0ustar ondrejondrejuse APR::Request; use APR::Table; use APR::Brigade; sub upload_io { tie local (*FH), "APR::Request::Brigade", shift->upload; return bless *FH{IO}, "APR::Request::Brigade::IO"; } sub upload_fh { my $fname = shift->upload_tempname(@_); open my $fh, "<", $fname or die "Can't open ", $fname, ": ", $!; binmode $fh; return $fh; } sub APR::Request::upload { my $req = shift; my $body = $req->body or return; $body->param_class(__PACKAGE__); if (@_) { my @uploads = grep $_->upload, $body->get(@_); return wantarray ? @uploads : $uploads[0]; } return map { $_->upload ? $_->name : () } values %$body if wantarray; return $body->uploads($req->pool); } package APR::Request::Brigade; push our(@ISA), "APR::Brigade"; package APR::Request::Brigade::IO; push our(@ISA), (); rapache-1.2.8/libapreq2/glue/perl/xsbuilder/APR/Request/Param/Param.pod0000644000175100017510000001016612706745114025124 0ustar ondrejondrej=head1 NAME APR::Request::Param - wrapper for libapreq2's param API. =head1 SYNOPSIS use APR::Request::Param; =head1 DESCRIPTION The C<< APR::Request::Param >> module provides base methods for interfacing with libapreq2's param API. It also provides a few utility functions and constants. =head1 OVERLOADS APR::Request::Param =head2 "" "$param" The double-quote interpolation operator maps to C<< APR::Request::Param::value() >>. =head1 METHODS APR::Request::Param =head2 name $param->name() Returns the param's name. This attribute cannot be modified. =head2 value $param->value() Returns the param's value. This attribute cannot be modified. =head2 is_tainted $param->is_tainted() $param->is_tainted($set) Get/set the param's internal tainted flag. Note: if the param's charset is APREQ_CHARSET_UTF8 (8), this also activates the SvUTF8_on flag during calls to name() and/or value(). =head2 charset $param->charset() $param->charset($set) Get/set the param's internal charset. The charset is a number between 0 and 255; the current recognized values are =over 4 =item 0 APREQ_CHARSET_ASCII (7-bit us-ascii) =item 1 APREQ_CHARSET_LATIN1 (8-bit iso 8859-1) =item 2 APREQ_CHARSET_CP1252 (8-bit Windows-1252) =item 8 APREQ_CHARSET_UTF8 (utf8 encoded Unicode) =back See L above for info about how APREQ_CHARSET_UTF8 relates to perl's UTF-8 flag. =head2 make APR::Request::Param->make($pool, $name, $value) Fast XS param constructor. =head2 info $param->info() $param->info($set) Get/set the APR::Table headers for this param. =head2 upload $param->upload() $param->upload($set) Get/set the APR::Brigade file-upload content for this param. =head2 upload_filename $param->upload_filename() Returns the client-side filename associated with this param. =head2 upload_link $param->upload_link($path) Links the file-upload content with the local file named C<< $path >>. Creates a hard-link if the spoolfile's (see L) temporary directory is on the same device as C<< $path >>; otherwise this writes a copy. =head2 upload_slurp $param->upload_slurp($data) Reads the entire file-upload content into C<< $data >>. =head2 upload_size $param->upload_size() Returns the size of the param's file-upload content. =head2 upload_type $param->upload_type() Returns the MIME-type of the param's file-upload content. =head2 upload_tempname $param->upload_tempname() Returns the name of the local spoolfile for this param. =head2 upload_io $param->upload_io() Returns an L object, which can be treated as a non-seekable IO stream. =head2 upload_fh $param->upload_fh Returns a seekable filehandle representing the file-upload content. =head1 METHODS APR::Request::Param::Table =head2 param_class $table->param_class() $table->param_class($set) Get/set the class each table element is blessed into during a L or L call. If defined, the class must be derived from APR::Request::Param. =head2 get $table->get() $table->get($name) =head2 FETCH $table->FETCH($name) =head2 NEXTKEY $table->NEXTKEY() =head2 FIRSTKEY $table->FIRSTKEY() =head2 do $table->do($callback, @keys) =head1 METHODS APR::Request::Brigade =head2 new, TIEHANDLE =head2 READ =head2 READLINE =head1 METHODS APR::Request::Brigade::IO =head2 read =head2 readline =head1 SEE ALSO =head1 COPYRIGHT Copyright 2003-2005 The Apache Software Foundation Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. rapache-1.2.8/libapreq2/glue/perl/xsbuilder/APR/Request/Param/Param.xs0000644000175100017510000001676412706745114025006 0ustar ondrejondrejMODULE = APR::Request::Param PACKAGE = APR::Request::Param SV * value(obj, p1=NULL, p2=NULL) APR::Request::Param obj SV *p1 SV *p2 PREINIT: /*nada*/ CODE: RETVAL = apreq_xs_param2sv(aTHX_ obj, NULL, NULL); OUTPUT: RETVAL SV * upload_filename(obj) APR::Request::Param obj PREINIT: CODE: if (obj->upload != NULL) RETVAL = apreq_xs_param2sv(aTHX_ obj, NULL, NULL); else RETVAL = &PL_sv_undef; OUTPUT: RETVAL BOOT: { apr_version_t version; apr_version(&version); if (version.major != APR_MAJOR_VERSION) Perl_croak(aTHX_ "Can't load module APR::Request::Param : " "wrong libapr major version " "(expected %d, saw %d)", APR_MAJOR_VERSION, version.major); } /* register the overloading (type 'A') magic */ PL_amagic_generation++; /* The magic for overload gets a GV* via gv_fetchmeth as */ /* mentioned above, and looks in the SV* slot of it for */ /* the "fallback" status. */ sv_setsv( get_sv( "APR::Request::Param::()", TRUE ), &PL_sv_yes ); newXS("APR::Request::Param::()", XS_APR__Request__Param_nil, file); newXS("APR::Request::Param::(\"\"", XS_APR__Request__Param_value, file); MODULE = APR::Request::Param PACKAGE = APR::Request::Param SV * name(obj) APR::Request::Param obj CODE: RETVAL = newSVpvn(obj->v.name, obj->v.nlen); if (apreq_param_is_tainted(obj)) SvTAINTED_on(RETVAL); OUTPUT: RETVAL IV is_tainted(obj, val=NULL) APR::Request::Param obj SV *val PREINIT: /*nada*/ CODE: RETVAL = apreq_param_is_tainted(obj); if (items == 2) { if (SvTRUE(val)) apreq_param_tainted_on(obj); else apreq_param_tainted_off(obj); } OUTPUT: RETVAL IV charset(obj, val=NULL) APR::Request::Param obj SV *val PREINIT: /*nada*/ CODE: if (items == 2) RETVAL = apreq_param_charset_set(obj, SvIV(val)); else RETVAL = apreq_param_charset_get(obj); OUTPUT: RETVAL APR::Request::Param make(class, pool, name, val) apreq_xs_subclass_t class APR::Pool pool SV *name SV *val PREINIT: STRLEN nlen, vlen; const char *n, *v; SV *parent = SvRV(ST(1)); CODE: n = SvPV(name, nlen); v = SvPV(val, vlen); RETVAL = apreq_param_make(pool, n, nlen, v, vlen); if (SvTAINTED(name) || SvTAINTED(val)) apreq_param_tainted_on(RETVAL); OUTPUT: RETVAL MODULE = APR::Request::Param PACKAGE = APR::Request::Param::Table SV * param_class(t, newclass=NULL) APR::Request::Param::Table t char *newclass PREINIT: SV *obj = apreq_xs_sv2object(aTHX_ ST(0), PARAM_TABLE_CLASS, 't'); MAGIC *mg = mg_find(obj, PERL_MAGIC_ext); char *curclass = mg->mg_ptr; CODE: RETVAL = (curclass == NULL) ? &PL_sv_undef : newSVpv(curclass, 0); if (newclass != NULL) { if (!sv_derived_from(ST(1), PARAM_CLASS)) Perl_croak(aTHX_ "Usage: " PARAM_TABLE_CLASS "::param_class($table, $class): " "class %s is not derived from " PARAM_CLASS, newclass); mg->mg_ptr = savepv(newclass); mg->mg_len = strlen(newclass); if (curclass != NULL) Safefree(curclass); } OUTPUT: RETVAL MODULE = APR::Request::Param PACKAGE = APR::Request::Param SV * upload_link(param, path) APR::Request::Param param const char *path PREINIT: apr_file_t *f; const char *fname; apr_status_t s; CODE: if (param->upload == NULL) Perl_croak(aTHX_ "$param->upload_link($file): param has no upload brigade"); f = apreq_brigade_spoolfile(param->upload); if (f == NULL) { apr_off_t len; s = apr_file_open(&f, path, APR_CREATE | APR_EXCL | APR_WRITE | APR_READ | APR_BINARY, APR_OS_DEFAULT, param->upload->p); if (s == APR_SUCCESS) { s = apreq_brigade_fwrite(f, &len, param->upload); if (s == APR_SUCCESS) XSRETURN_YES; } } else { s = apr_file_name_get(&fname, f); if (s != APR_SUCCESS) Perl_croak(aTHX_ "$param->upload_link($file): can't get spoolfile name"); if (PerlLIO_link(fname, path) >= 0) XSRETURN_YES; else { s = apr_file_copy(fname, path, APR_OS_DEFAULT, param->upload->p); if (s == APR_SUCCESS) XSRETURN_YES; } } RETVAL = &PL_sv_undef; OUTPUT: RETVAL apr_size_t upload_slurp(param, buffer) APR::Request::Param param SV *buffer PREINIT: apr_off_t len; apr_status_t s; char *data; CODE: if (param->upload == NULL) Perl_croak(aTHX_ "$param->upload_slurp($data): param has no upload brigade"); s = apr_brigade_length(param->upload, 0, &len); if (s != APR_SUCCESS) Perl_croak(aTHX_ "$param->upload_slurp($data): can't get upload length"); RETVAL = len; SvUPGRADE(buffer, SVt_PV); data = SvGROW(buffer, RETVAL + 1); data[RETVAL] = 0; SvCUR_set(buffer, RETVAL); SvPOK_only(buffer); s = apr_brigade_flatten(param->upload, data, &RETVAL); if (s != APR_SUCCESS) Perl_croak(aTHX_ "$param->upload_slurp($data): can't flatten upload"); if (apreq_param_is_tainted(param)) SvTAINTED_on(buffer); SvSETMAGIC(buffer); OUTPUT: RETVAL UV upload_size(param) APR::Request::Param param PREINIT: apr_off_t len; apr_status_t s; CODE: if (param->upload == NULL) Perl_croak(aTHX_ "$param->upload_size(): param has no upload brigade"); s = apr_brigade_length(param->upload, 0, &len); if (s != APR_SUCCESS) Perl_croak(aTHX_ "$param->upload_size(): can't get upload length"); RETVAL = len; OUTPUT: RETVAL SV * upload_type(param) APR::Request::Param param PREINIT: const char *ct, *sc; STRLEN len; CODE: if (param->info == NULL) Perl_croak(aTHX_ "$param->upload_type(): param has no info table"); ct = apr_table_get(param->info, "Content-Type"); if (ct == NULL) Perl_croak(aTHX_ "$param->upload_type: can't find Content-Type header"); if ((sc = strchr(ct, ';'))) len = sc - ct; else len = strlen(ct); RETVAL = newSVpvn(ct, len); if (apreq_param_is_tainted(param)) SvTAINTED_on(RETVAL); OUTPUT: RETVAL const char * upload_tempname(param, req=apreq_xs_sv2handle(aTHX_ ST(0))) APR::Request::Param param APR::Request req PREINIT: apr_file_t *f; apr_status_t s; CODE: if (param->upload == NULL) Perl_croak(aTHX_ "$param->upload_tempname($req): param has no upload brigade"); f = apreq_brigade_spoolfile(param->upload); if (f == NULL) { const char *path; s = apreq_temp_dir_get(req, &path); if (s != APR_SUCCESS) Perl_croak(aTHX_ "$param->upload_tempname($req): can't get temp_dir"); s = apreq_brigade_concat(param->upload->p, path, 0, param->upload, param->upload); if (s != APR_SUCCESS) Perl_croak(aTHX_ "$param->upload_tempname($req): can't make spool bucket"); f = apreq_brigade_spoolfile(param->upload); } s = apr_file_name_get(&RETVAL, f); if (s != APR_SUCCESS) Perl_croak(aTHX_ "$param->upload_link($file): can't get spool file name"); OUTPUT: RETVAL rapache-1.2.8/libapreq2/glue/perl/xsbuilder/APR/Request/Request.pm0000644000175100017510000000063212706745114024303 0ustar ondrejondrejuse APR::Request::Error; sub import { my $class = shift; return unless @_; my $pkg = caller; no strict 'refs'; for (@_) { *{"$pkg\::$_"} = $class->can($_) or die "Can't find method $_ in class $class"; } } sub param_status { my $req = shift; return $req->args_status || $req->body_status if wantarray; return ($req->args_status, $req->body_status); } rapache-1.2.8/libapreq2/glue/perl/xsbuilder/APR/Request/Request.pod0000644000175100017510000000314512706745114024453 0ustar ondrejondrej=head1 NAME APR::Request - wrapper for libapreq2's module/handle API. =head1 SYNOPSIS use APR::Request; my $req = $derived_class->handle( ... ); $param = $req->param("foo"); $cookie = $req->jar("bar"); =head1 DESCRIPTION The C<< APR::Request >> module provides the base methods for interfacing with libapreq2's module API. It also provides a few utility functions and constants. =head1 METHODS APR::Request =head2 jar_status =head2 args_status =head2 body_status =head2 param_status =head2 parse =head2 jar =head2 args =head2 body =head2 param =head2 uploads (APR::Request::Param::Table???) =head2 pool =head2 bucket_alloc =head2 read_limit =head2 brigade_limit =head2 temp_dir =head2 disable_uploads Engage the disable_uploads hook for this request. =head2 upload_hook =head2 import =head1 SUBROUTINES APR::Request =head2 encode =head2 decode =head1 SEE ALSO L<< APR::Request::Error >>, L<< APR::Request::Param >>, L<< APR::Request::Cookie >> =head1 COPYRIGHT Copyright 2003-2005 The Apache Software Foundation Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. rapache-1.2.8/libapreq2/glue/perl/xsbuilder/APR/Request/Request.xs0000644000175100017510000001371012706745114024322 0ustar ondrejondrejMODULE = APR::Request PACKAGE = APR::Request SV* encode(in) SV *in PREINIT: STRLEN len; char *src; CODE: src = SvPV(in, len); RETVAL = newSV(3 * len); SvCUR_set(RETVAL, apreq_encode(SvPVX(RETVAL), src, len)); SvPOK_on(RETVAL); OUTPUT: RETVAL SV* decode(in) SV *in PREINIT: STRLEN len; apr_size_t dlen; char *src; CODE: src = SvPV(in, len); RETVAL = newSV(len); apreq_decode(SvPVX(RETVAL), &dlen, src, len); /*XXX needs error-handling */ SvCUR_set(RETVAL, dlen); SvPOK_on(RETVAL); OUTPUT: RETVAL SV* read_limit(req, val=NULL) APR::Request req SV *val PREINIT: /* nada */ CODE: if (items == 1) { apr_status_t s; apr_uint64_t bytes; s = apreq_read_limit_get(req, &bytes); if (s != APR_SUCCESS) { SV *sv = ST(0), *obj = ST(0); APREQ_XS_THROW_ERROR(r, s, "APR::Request::read_limit", "APR::Request::Error"); RETVAL = &PL_sv_undef; } else { RETVAL = newSVuv(bytes); } } else { apr_status_t s = apreq_read_limit_set(req, SvUV(val)); if (s != APR_SUCCESS) { if (GIMME_V == G_VOID) { SV *sv = ST(0), *obj = ST(0); APREQ_XS_THROW_ERROR(r, s, "APR::Request::read_limit", "APR::Request::Error"); } RETVAL = &PL_sv_no; } else { RETVAL = &PL_sv_yes; } } OUTPUT: RETVAL SV* brigade_limit(req, val=NULL) APR::Request req SV *val PREINIT: /* nada */ CODE: if (items == 1) { apr_status_t s; apr_size_t bytes; s = apreq_brigade_limit_get(req, &bytes); if (s != APR_SUCCESS) { SV *sv = ST(0), *obj = ST(0); APREQ_XS_THROW_ERROR(r, s, "APR::Request::brigade_limit", "APR::Request::Error"); RETVAL = &PL_sv_undef; } else { RETVAL = newSVuv(bytes); } } else { apr_status_t s = apreq_brigade_limit_set(req, SvUV(val)); if (s != APR_SUCCESS) { if (GIMME_V == G_VOID) { SV *sv = ST(0), *obj = ST(0); APREQ_XS_THROW_ERROR(r, s, "APR::Request::brigade_limit", "APR::Request::Error"); } RETVAL = &PL_sv_no; } else { RETVAL = &PL_sv_yes; } } OUTPUT: RETVAL SV* temp_dir(req, val=NULL) APR::Request req SV *val PREINIT: /* nada */ CODE: if (items == 1) { apr_status_t s; const char *path; s = apreq_temp_dir_get(req, &path); if (s != APR_SUCCESS) { SV *sv = ST(0), *obj = ST(0); APREQ_XS_THROW_ERROR(r, s, "APR::Request::temp_dir", "APR::Request::Error"); RETVAL = &PL_sv_undef; } else { RETVAL = (path == NULL) ? &PL_sv_undef : newSVpv(path, 0); } } else { apr_status_t s = apreq_temp_dir_set(req, SvPV_nolen(val)); if (s != APR_SUCCESS) { if (GIMME_V == G_VOID) { SV *sv = ST(0), *obj = ST(0); APREQ_XS_THROW_ERROR(r, s, "APR::Request::temp_dir", "APR::Request::Error"); } RETVAL = &PL_sv_no; } else { RETVAL = &PL_sv_yes; } } OUTPUT: RETVAL SV* jar_status(req) APR::Request req PREINIT: const apr_table_t *t; CODE: RETVAL = apreq_xs_error2sv(aTHX_ apreq_jar(req, &t)); OUTPUT: RETVAL SV* args_status(req) APR::Request req PREINIT: const apr_table_t *t; CODE: RETVAL = apreq_xs_error2sv(aTHX_ apreq_args(req, &t)); OUTPUT: RETVAL SV* body_status(req) APR::Request req PREINIT: const apr_table_t *t; CODE: RETVAL = apreq_xs_error2sv(aTHX_ apreq_body(req, &t)); OUTPUT: RETVAL SV* disable_uploads(req) APR::Request req PREINIT: apreq_hook_t *h; apr_status_t s; CODE: h = apreq_hook_make(req->pool, apreq_hook_disable_uploads, NULL, NULL); s = apreq_hook_add(req, h); RETVAL = apreq_xs_error2sv(aTHX_ s); OUTPUT: RETVAL void upload_hook(obj, sub) SV *obj SV *sub PREINIT: struct hook_ctx *ctx; IV iv; apreq_handle_t *req; CODE: obj = apreq_xs_sv2object(aTHX_ obj, "APR::Request", 'r'); iv = SvIVX(obj); req = INT2PTR(apreq_handle_t *, iv); ctx = apr_palloc(req->pool, sizeof *ctx); ctx->hook = newSVsv(sub); ctx->bucket_data = newSV(8000); ctx->parent = SvREFCNT_inc(obj); SvTAINTED_on(ctx->bucket_data); #ifdef USE_ITHREADS ctx->perl = aTHX; #endif apreq_hook_add(req, apreq_hook_make(req->pool, apreq_xs_upload_hook, NULL, ctx)); apr_pool_cleanup_register(req->pool, ctx, upload_hook_cleanup, NULL); APR::Pool pool(req) APR::Request req CODE: RETVAL = req->pool; APR::BucketAlloc bucket_alloc(req) APR::Request req CODE: RETVAL = req->bucket_alloc; MODULE = APR::Request::Param PACKAGE = APR::Request::Param::Table SV * uploads(t, pool) APR::Request::Param::Table t APR::Pool pool PREINIT: SV *obj = apreq_xs_sv2object(aTHX_ ST(0), PARAM_TABLE_CLASS, 't'); SV *parent = apreq_xs_sv2object(aTHX_ ST(0), HANDLE_CLASS, 'r'); MAGIC *mg = mg_find(obj, PERL_MAGIC_ext); CODE: RETVAL = apreq_xs_param_table2sv(aTHX_ apreq_uploads(t, pool), HvNAME(SvSTASH(obj)), parent, mg->mg_ptr, mg->mg_len); OUTPUT: RETVAL BOOT: { apr_version_t version; apr_version(&version); if (version.major != APR_MAJOR_VERSION) Perl_croak(aTHX_ "Can't load module APR::Request : " "wrong libapr major version " "(expected %d, saw %d)", APR_MAJOR_VERSION, version.major); } rapache-1.2.8/libapreq2/glue/perl/xsbuilder/apreq_xs_postperl.h0000644000175100017510000001751212706745114024173 0ustar ondrejondrej/* ** Copyright 2003-2005 The Apache Software Foundation ** ** Licensed under the Apache License, Version 2.0 (the "License"); ** you may not use this file except in compliance with the License. ** You may obtain a copy of the License at ** ** http://www.apache.org/licenses/LICENSE-2.0 ** ** Unless required by applicable law or agreed to in writing, software ** distributed under the License is distributed on an "AS IS" BASIS, ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ** See the License for the specific language governing permissions and ** limitations under the License. */ #ifndef APREQ_XS_POSTPERL_H #define APREQ_XS_POSTPERL_H /* avoid namespace collisions from perl's XSUB.h */ #include "modperl_perl_unembed.h" /* required for modperl's T_HASHOBJ (typemap) */ #include "modperl_common_util.h" /* backward compatibility macros support */ #include "ppport.h" /* apr version info for modules */ #include "apr_version.h" /* ExtUtils::XSBuilder::ParseSoure trickery... */ typedef apreq_handle_t apreq_xs_handle_cgi_t; typedef apreq_handle_t apreq_xs_handle_apache2_t; typedef apr_table_t apreq_xs_param_table_t; typedef apr_table_t apreq_xs_cookie_table_t; typedef HV apreq_xs_error_t; typedef char* apreq_xs_subclass_t; #define APR__Request__Param__Table const apr_table_t * #define APR__BucketAlloc apr_bucket_alloc_t * #define HANDLE_CLASS "APR::Request" #define COOKIE_CLASS "APR::Request::Cookie" #define PARAM_CLASS "APR::Request::Param" #define ERROR_CLASS "APR::Request::Error" #define COOKIE_TABLE_CLASS "APR::Request::Cookie::Table" #define PARAM_TABLE_CLASS "APR::Request::Param::Table" struct apreq_xs_do_arg { const char *pkg; SV *parent, *sub; PerlInterpreter *perl; }; /** * @file apreq_xs_postperl.h * @brief XS include file for making Cookie.so and Request.so * */ /** * @defgroup XS Perl * @ingroup GLUE * @{ */ /** * Trace through magic objects & hashrefs looking for original object. * @param in The starting SV *. * @param key The first letter of key is used to search a hashref for * the desired object. * @return Reference to the object. */ APR_INLINE static SV *apreq_xs_find_obj(pTHX_ SV *in, const char key) { const char altkey[] = { '_', key }; while (in && SvROK(in)) { SV *sv = SvRV(in); switch (SvTYPE(sv)) { MAGIC *mg; SV **svp; case SVt_PVHV: if (SvMAGICAL(sv) && (mg = mg_find(sv,PERL_MAGIC_tied))) { in = mg->mg_obj; break; } else if ((svp = hv_fetch((HV *)sv, altkey+1, 1, FALSE)) || (svp = hv_fetch((HV *)sv, altkey, 2, FALSE))) { in = *svp; break; } Perl_croak(aTHX_ "attribute hash has no '%s' key!", key); case SVt_PVMG: if (SvOBJECT(sv) && SvIOKp(sv)) return in; default: Perl_croak(aTHX_ "panic: unsupported SV type: %d", SvTYPE(sv)); } } Perl_croak(aTHX_ "apreq_xs_find_obj: object attr `%c' not found", key); return NULL; } /* conversion function templates based on modperl-2's sv2request_rec */ static APR_INLINE SV *apreq_xs_object2sv(pTHX_ void *ptr, const char *class, SV *parent, const char *base) { SV *rv = sv_setref_pv(newSV(0), class, (void *)ptr); sv_magic(SvRV(rv), parent, PERL_MAGIC_ext, Nullch, 0); if (!sv_derived_from(rv, base)) croak("apreq_xs_object2sv failed: target class %s isn't derived from %s", class, base); return rv; } APR_INLINE static SV *apreq_xs_handle2sv(pTHX_ apreq_handle_t *req, const char *class, SV *parent) { return apreq_xs_object2sv(aTHX_ req, class, parent, HANDLE_CLASS); } APR_INLINE static SV *apreq_xs_param2sv(pTHX_ apreq_param_t *p, const char *class, SV *parent) { if (class == NULL) { SV *rv = newSVpvn(p->v.data, p->v.dlen); if (apreq_param_is_tainted(p)) SvTAINTED_on(rv); else if (apreq_param_charset_get(p) == APREQ_CHARSET_UTF8) /* Setting the UTF8 flag on non-utf8 data is a security hole. * Let's see if coupling that decision with taintedness helps * resolve this issue. */ SvUTF8_on(rv); return rv; } return apreq_xs_object2sv(aTHX_ p, class, parent, PARAM_CLASS); } APR_INLINE static SV *apreq_xs_cookie2sv(pTHX_ apreq_cookie_t *c, const char *class, SV *parent) { if (class == NULL) { SV *rv = newSVpvn(c->v.data, c->v.dlen); if (apreq_cookie_is_tainted(c)) SvTAINTED_on(rv); /*XXX add charset fixups? */ return rv; } return apreq_xs_object2sv(aTHX_ c, class, parent, COOKIE_CLASS); } APR_INLINE static SV* apreq_xs_error2sv(pTHX_ apr_status_t s) { char buf[256]; SV *sv = newSV(0); sv_upgrade(sv, SVt_PVIV); apreq_strerror(s, buf, sizeof buf); sv_setpvn(sv, buf, strlen(buf)); SvPOK_on(sv); SvIVX(sv) = s; SvIOK_on(sv); SvREADONLY_on(sv); return sv; } APR_INLINE static SV *apreq_xs_sv2object(pTHX_ SV *sv, const char *class, const char attr) { SV *obj; MAGIC *mg; sv = apreq_xs_find_obj(aTHX_ sv, attr); /* XXX sv_derived_from is expensive; how to optimize it? */ if (sv_derived_from(sv, class)) { return SvRV(sv); } /* else check if parent (mg->mg_obj) is the right object type */ if ((mg = mg_find(SvRV(sv), PERL_MAGIC_ext)) != NULL && (obj = mg->mg_obj) != NULL && SvOBJECT(obj)) { sv = sv_2mortal(newRV_inc(obj)); if (sv_derived_from(sv, class)) return obj; } Perl_croak(aTHX_ "apreq_xs_sv2object: %s object not found", class); return NULL; } APR_INLINE static apreq_handle_t *apreq_xs_sv2handle(pTHX_ SV *sv) { SV *obj = apreq_xs_sv2object(aTHX_ sv, HANDLE_CLASS, 'r'); IV iv = SvIVX(obj); return INT2PTR(apreq_handle_t *, iv); } static APR_INLINE apreq_param_t *apreq_xs_sv2param(pTHX_ SV *sv) { SV *obj = apreq_xs_sv2object(aTHX_ sv, PARAM_CLASS, 'p'); IV iv = SvIVX(obj); return INT2PTR(apreq_param_t *, iv); } static APR_INLINE apreq_cookie_t *apreq_xs_sv2cookie(pTHX_ SV *sv) { SV *obj = apreq_xs_sv2object(aTHX_ sv, COOKIE_CLASS, 'c'); IV iv = SvIVX(obj); return INT2PTR(apreq_cookie_t *, iv); } static APR_INLINE void apreq_xs_croak(pTHX_ HV *data, apr_status_t rc, const char *func, const char *class) { HV *stash = gv_stashpvn(class, strlen(class), FALSE); sv_setsv(ERRSV, sv_2mortal(sv_bless(newRV_noinc((SV*)data), stash))); sv_setiv(*hv_fetch(data, "rc", 2, 1), rc); sv_setpv(*hv_fetch(data, "file", 4, 1), CopFILE(PL_curcop)); sv_setiv(*hv_fetch(data, "line", 4, 1), CopLINE(PL_curcop)); sv_setpv(*hv_fetch(data, "func", 4, 1), func); Perl_croak(aTHX_ Nullch); } #define APREQ_XS_THROW_ERROR(attr, status, func, errpkg) do { \ if (!sv_derived_from(sv, errpkg)) { \ HV *hv = newHV(); \ SV *rv = newRV_inc(obj); \ sv_setsv(*hv_fetch(hv, "_" #attr, 2, 1), sv_2mortal(rv)); \ apreq_xs_croak(aTHX_ hv, status, func, errpkg); \ } \ } while (0) static APR_INLINE const char *apreq_xs_helper_class(pTHX_ SV **SP, SV *sv, const char *method) { PUSHMARK(SP); XPUSHs(sv); PUTBACK; call_method(method, G_SCALAR); SPAGAIN; sv = POPs; PUTBACK; return SvPV_nolen(sv); } /** @} */ #endif /* APREQ_XS_POSTPERL_H */ rapache-1.2.8/libapreq2/glue/perl/xsbuilder/apreq_xs_preperl.h0000644000175100017510000000242612706745114023772 0ustar ondrejondrej/* ** Copyright 2004-2005 The Apache Software Foundation ** ** Licensed under the Apache License, Version 2.0 (the "License"); ** you may not use this file except in compliance with the License. ** You may obtain a copy of the License at ** ** http://www.apache.org/licenses/LICENSE-2.0 ** ** Unless required by applicable law or agreed to in writing, software ** distributed under the License is distributed on an "AS IS" BASIS, ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ** See the License for the specific language governing permissions and ** limitations under the License. */ #ifndef APREQ_XS_PREPERL_H #define APREQ_XS_PREPERL_H #define PERL_NO_GET_CONTEXT /* we want efficiency under ithreads */ /* some redefines needed for Win32 */ #ifdef WIN32 # define uid_t perl_uid_t # define gid_t perl_gid_t # ifdef exit # define perl_exit exit # undef exit # endif #endif /* Undo httpd.h's strchr override. */ #ifdef AP_DEBUG # undef strchr #endif /** * @file apreq_xs_preperl.h * @brief XS include file for making Cookie.so and Request.so, for things * that has to be included before EXTERN.h/perl.h/XSUB.h headers * */ /** * @defgroup XS Perl * @ingroup GLUE * @{ */ /** @} */ #endif /* APREQ_XS_PREPERL_H */ rapache-1.2.8/libapreq2/glue/perl/xsbuilder/apreq_xs_tables.h0000644000175100017510000001705112706745114023573 0ustar ondrejondrej/* ** Copyright 2003-2005 The Apache Software Foundation ** ** Licensed under the Apache License, Version 2.0 (the "License"); ** you may not use this file except in compliance with the License. ** You may obtain a copy of the License at ** ** http://www.apache.org/licenses/LICENSE-2.0 ** ** Unless required by applicable law or agreed to in writing, software ** distributed under the License is distributed on an "AS IS" BASIS, ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ** See the License for the specific language governing permissions and ** limitations under the License. */ #ifndef APREQ_XS_TABLES_H #define APREQ_XS_TABLES_H /* backward compatibility macros support */ #include "ppport.h" /**************************************************/ #if (PERL_VERSION >= 8) /* MAGIC ITERATOR REQUIRES 5.8 */ /* Requires perl 5.8 or better. * A custom MGVTBL with its "copy" slot filled allows * us to FETCH a table entry immediately during iteration. * For multivalued keys this is essential in order to get * the value corresponding to the current key, otherwise * values() will always report the first value repeatedly. * With this MGVTBL the keys() list always matches up with * the values() list, even in the multivalued case. * We only prefetch the value during iteration, because the * prefetch adds overhead to EXISTS and STORE operations. * They are only "penalized" when the perl program is iterating * via each(), which seems to be a reasonable tradeoff. */ static int apreq_xs_cookie_table_magic_copy(pTHX_ SV *sv, MAGIC *mg, SV *nsv, const char *name, int namelen) { /* Prefetch the value whenever the table iterator is > 0 */ MAGIC *tie_magic = mg_find(nsv, PERL_MAGIC_tiedelem); SV *obj = SvRV(tie_magic->mg_obj); IV idx = SvIVX(obj); const apr_table_t *t = INT2PTR(apr_table_t *, idx); const apr_array_header_t *arr = apr_table_elts(t); idx = SvCUR(obj); if (idx > 0 && idx <= arr->nelts) { const apr_table_entry_t *te = (const apr_table_entry_t *)arr->elts; apreq_cookie_t *c = apreq_value_to_cookie(te[idx-1].val); MAGIC *my_magic = mg_find(obj, PERL_MAGIC_ext); SvMAGICAL_off(nsv); sv_setsv(nsv, sv_2mortal(apreq_xs_cookie2sv(aTHX_ c, my_magic->mg_ptr, my_magic->mg_obj))); } return 0; } static const MGVTBL apreq_xs_cookie_table_magic = {0, 0, 0, 0, 0, apreq_xs_cookie_table_magic_copy}; #endif static APR_INLINE SV *apreq_xs_cookie_table2sv(pTHX_ const apr_table_t *t, const char *class, SV *parent, const char *value_class, I32 vclen) { SV *sv = (SV *)newHV(); SV *rv = sv_setref_pv(newSV(0), class, (void *)t); sv_magic(SvRV(rv), parent, PERL_MAGIC_ext, value_class, vclen); #if (PERL_VERSION >= 8) /* MAGIC ITERATOR requires 5.8 */ sv_magic(sv, NULL, PERL_MAGIC_ext, Nullch, -1); SvMAGIC(sv)->mg_virtual = (MGVTBL *)&apreq_xs_cookie_table_magic; SvMAGIC(sv)->mg_flags |= MGf_COPY; #endif sv_magic(sv, rv, PERL_MAGIC_tied, Nullch, 0); SvREFCNT_dec(rv); /* corrects SvREFCNT_inc(rv) implicit in sv_magic */ return sv_bless(newRV_noinc(sv), SvSTASH(SvRV(rv))); } static int apreq_xs_cookie_table_keys(void *data, const char *key, const char *val) { #ifdef USE_ITHREADS struct apreq_xs_do_arg *d = (struct apreq_xs_do_arg *)data; dTHXa(d->perl); #endif dSP; apreq_cookie_t *c = apreq_value_to_cookie(val); SV *sv = newSVpvn(key, c->v.nlen); if (apreq_cookie_is_tainted(c)) SvTAINTED_on(sv); #ifndef USE_ITHREADS (void)data; #endif XPUSHs(sv_2mortal(sv)); PUTBACK; return 1; } static int apreq_xs_cookie_table_values(void *data, const char *key, const char *val) { struct apreq_xs_do_arg *d = (struct apreq_xs_do_arg *)data; dTHXa(d->perl); dSP; apreq_cookie_t *c = apreq_value_to_cookie(val); SV *sv = apreq_xs_cookie2sv(aTHX_ c, d->pkg, d->parent); XPUSHs(sv_2mortal(sv)); PUTBACK; return 1; } /**************************************************/ #if (PERL_VERSION >= 8) /* MAGIC ITERATOR REQUIRES 5.8 */ /* Requires perl 5.8 or better. * A custom MGVTBL with its "copy" slot filled allows * us to FETCH a table entry immediately during iteration. * For multivalued keys this is essential in order to get * the value corresponding to the current key, otherwise * values() will always report the first value repeatedly. * With this MGVTBL the keys() list always matches up with * the values() list, even in the multivalued case. * We only prefetch the value during iteration, because the * prefetch adds overhead to EXISTS and STORE operations. * They are only "penalized" when the perl program is iterating * via each(), which seems to be a reasonable tradeoff. */ static int apreq_xs_param_table_magic_copy(pTHX_ SV *sv, MAGIC *mg, SV *nsv, const char *name, int namelen) { /* Prefetch the value whenever the table iterator is > 0 */ MAGIC *tie_magic = mg_find(nsv, PERL_MAGIC_tiedelem); SV *obj = SvRV(tie_magic->mg_obj); IV idx = SvIVX(obj); const apr_table_t *t = INT2PTR(apr_table_t *, idx); const apr_array_header_t *arr = apr_table_elts(t); idx = SvCUR(obj); if (idx > 0 && idx <= arr->nelts) { const apr_table_entry_t *te = (const apr_table_entry_t *)arr->elts; apreq_param_t *p = apreq_value_to_param(te[idx-1].val); MAGIC *my_magic = mg_find(obj, PERL_MAGIC_ext); SvMAGICAL_off(nsv); sv_setsv(nsv, sv_2mortal(apreq_xs_param2sv(aTHX_ p, my_magic->mg_ptr, my_magic->mg_obj))); } return 0; } static const MGVTBL apreq_xs_param_table_magic = {0, 0, 0, 0, 0, apreq_xs_param_table_magic_copy}; #endif static APR_INLINE SV *apreq_xs_param_table2sv(pTHX_ const apr_table_t *t, const char *class, SV *parent, const char *value_class, I32 vclen) { SV *sv = (SV *)newHV(); SV *rv = sv_setref_pv(newSV(0), class, (void *)t); sv_magic(SvRV(rv), parent, PERL_MAGIC_ext, value_class, vclen); #if (PERL_VERSION >= 8) /* MAGIC ITERATOR requires 5.8 */ sv_magic(sv, NULL, PERL_MAGIC_ext, Nullch, -1); SvMAGIC(sv)->mg_virtual = (MGVTBL *)&apreq_xs_param_table_magic; SvMAGIC(sv)->mg_flags |= MGf_COPY; #endif sv_magic(sv, rv, PERL_MAGIC_tied, Nullch, 0); SvREFCNT_dec(rv); /* corrects SvREFCNT_inc(rv) implicit in sv_magic */ return sv_bless(newRV_noinc(sv), SvSTASH(SvRV(rv))); } static int apreq_xs_param_table_keys(void *data, const char *key, const char *val) { #ifdef USE_ITHREADS struct apreq_xs_do_arg *d = (struct apreq_xs_do_arg *)data; dTHXa(d->perl); #endif dSP; apreq_param_t *p = apreq_value_to_param(val); SV *sv = newSVpvn(key, p->v.nlen); #ifndef USE_ITHREADS (void)data; #endif if (apreq_param_is_tainted(p)) SvTAINTED_on(sv); XPUSHs(sv_2mortal(sv)); PUTBACK; return 1; } static int apreq_xs_param_table_values(void *data, const char *key, const char *val) { struct apreq_xs_do_arg *d = (struct apreq_xs_do_arg *)data; dTHXa(d->perl); dSP; apreq_param_t *p = apreq_value_to_param(val); SV *sv = apreq_xs_param2sv(aTHX_ p, d->pkg, d->parent); XPUSHs(sv_2mortal(sv)); PUTBACK; return 1; } #endif /* APREQ_XS_TABLES_H */ rapache-1.2.8/libapreq2/glue/perl/xsbuilder/maps/0000755000175100017510000000000012706745114021202 5ustar ondrejondrejrapache-1.2.8/libapreq2/glue/perl/xsbuilder/maps/apreq_functions.map0000644000175100017510000000415312706745114025104 0ustar ondrejondrej########## Apache::Request:: Functions ########## #################### APR::Request stuff #################### MODULE=APR::Request PACKAGE=APR::Request PREFIX=apreq_ apreq_cp1252_to_utf8 #apreq_hook_add MODULE=APR::Request::Apache2 PACKAGE=APR::Request::Apache2 PREFIX=APR__Request__Apache2_ apreq_xs_handle_apache2_t *:DEFINE_handle | apreq_handle_apache2 (r) | const char *:class, request_rec *:r MODULE=APR::Request::CGI PACKAGE=APR::Request::CGI PREFIX=APR__Request__CGI_ apreq_xs_handle_cgi_t *:DEFINE_handle | apreq_handle_cgi (p) | const char *:class, apr_pool_t *:p #################### APR::Request::Cookie stuff #################### MODULE=APR::Request::Cookie PACKAGE=APR::Request::Cookie PREFIX=apreq_cookie_ apreq_cookie_expires MODULE=APR::Request::Cookie PACKAGE=APR::Request::Cookie::Table PREFIX=APR__Request__Cookie__Table_ DEFINE_get | apreq_xs_cookie_table_FETCH | DEFINE_FETCH | apreq_xs_cookie_table_FETCH | DEFINE_NEXTKEY | apreq_xs_cookie_table_NEXTKEY | DEFINE_FIRSTKEY | apreq_xs_cookie_table_NEXTKEY | DEFINE_do | apreq_xs_cookie_table_do | #################### APR::Request::Param stuff #################### MODULE=APR::Request PACKAGE=APR::Request PREFIX=APR__Request_ DEFINE_parse | apreq_xs_parse | DEFINE_jar | apreq_xs_jar | DEFINE_args | apreq_xs_args | DEFINE_body | apreq_xs_body | DEFINE_param | apreq_xs_param | MODULE=APR::Request::Param PACKAGE=APR::Request::Param::Table PREFIX=APR__Request__Param__Table_ DEFINE_get | apreq_xs_param_table_FETCH | DEFINE_FETCH | apreq_xs_param_table_FETCH | DEFINE_NEXTKEY | apreq_xs_param_table_NEXTKEY | DEFINE_FIRSTKEY | apreq_xs_param_table_NEXTKEY | DEFINE_do | apreq_xs_param_table_do | MODULE=APR::Request::Param PACKAGE=APR::Request::Brigade PREFIX=APR__Request__Brigade_ DEFINE_new | apreq_xs_brigade_copy | DEFINE_TIEHANDLE | apreq_xs_brigade_copy | DEFINE_READ | apreq_xs_brigade_read | DEFINE_READLINE | apreq_xs_brigade_readline | MODULE=APR::Request::Param PACKAGE=APR::Request::Brigade::IO PREFIX=APR__Request__Brigade__IO_ DEFINE_read | apreq_xs_brigade_read | DEFINE_readline | apreq_xs_brigade_readline | rapache-1.2.8/libapreq2/glue/perl/xsbuilder/maps/apreq_structures.map0000644000175100017510000000124512706745114025316 0ustar ondrejondrej########## APREQ structures ########## # # name # status # size # data[1] # info upload ! v ! module path domain port comment commentURL ! max_age ! flags ! v ! hook ! next ! ctx ! parser ! content_type ! hook > ctx rapache-1.2.8/libapreq2/glue/perl/xsbuilder/maps/apreq_types.map0000644000175100017510000000215212706745114024235 0ustar ondrejondrej########## APREQ types ########## const apr_size_t | UV apr_size_t | UV struct SV | SV apr_status_t | IV const char * | PV char * | PV void | VOID void * | PTR const void * | PTR unsigned | UV unsigned char | UV #data structure stuff struct request_rec | Apache2::RequestRec | T_APACHEOBJ | r struct apr_pool_t | APR::Pool | T_POOLOBJ struct apr_array_header_t | APR::ArrayHeader struct apr_table_t | APR::Table | T_HASHOBJ struct apr_bucket_brigade | APR::Brigade struct apreq_param_t | APR::Request::Param | T_APREQ_PARAM | param struct apreq_cookie_t | APR::Request::Cookie | T_APREQ_COOKIE | cookie struct apreq_handle_t | APR::Request | T_APREQ_HANDLE | req struct apreq_xs_handle_apache2_t | APR::Request::Apache2 | T_APREQ_HANDLE_APACHE2 struct apreq_xs_handle_cgi_t | APR::Request::CGI | T_APREQ_HANDLE_CGI struct apreq_xs_error_t | APR::Request::Error | T_APREQ_ERROR struct apreq_xs_cookie_table_t | APR::Request::Cookie::Table | T_HASHOBJ const apreq_xs_param_table_t * | APR::Request::Param::Table | T_HASHOBJ apreq_xs_subclass_t | SUBCLASS rapache-1.2.8/libapreq2/glue/perl/xsbuilder/ppport.h0000644000175100017510000007211412706745114021744 0ustar ondrejondrej /* ppport.h -- Perl/Pollution/Portability Version 2.011 * * Automatically Created by Devel::PPPort on Mon Feb 16 12:41:20 2004 * * Do NOT edit this file directly! -- Edit PPPort.pm instead. * * Version 2.x, Copyright (C) 2001, Paul Marquess. * Version 1.x, Copyright (C) 1999, Kenneth Albanowski. * This code may be used and distributed under the same license as any * version of Perl. * * This version of ppport.h is designed to support operation with Perl * installations back to 5.004, and has been tested up to 5.8.1. * * If this version of ppport.h is failing during the compilation of this * module, please check if a newer version of Devel::PPPort is available * on CPAN before sending a bug report. * * If you are using the latest version of Devel::PPPort and it is failing * during compilation of this module, please send a report to perlbug@perl.com * * Include all following information: * * 1. The complete output from running "perl -V" * * 2. This file. * * 3. The name & version of the module you were trying to build. * * 4. A full log of the build that failed. * * 5. Any other information that you think could be relevant. * * * For the latest version of this code, please retreive the Devel::PPPort * module from CPAN. * */ /* * In order for a Perl extension module to be as portable as possible * across differing versions of Perl itself, certain steps need to be taken. * Including this header is the first major one, then using dTHR is all the * appropriate places and using a PL_ prefix to refer to global Perl * variables is the second. * */ /* If you use one of a few functions that were not present in earlier * versions of Perl, please add a define before the inclusion of ppport.h * for a static include, or use the GLOBAL request in a single module to * produce a global definition that can be referenced from the other * modules. * * Function: Static define: Extern define: * newCONSTSUB() NEED_newCONSTSUB NEED_newCONSTSUB_GLOBAL * */ /* To verify whether ppport.h is needed for your module, and whether any * special defines should be used, ppport.h can be run through Perl to check * your source code. Simply say: * * perl -x ppport.h *.c *.h *.xs foo/bar*.c [etc] * * The result will be a list of patches suggesting changes that should at * least be acceptable, if not necessarily the most efficient solution, or a * fix for all possible problems. It won't catch where dTHR is needed, and * doesn't attempt to account for global macro or function definitions, * nested includes, typemaps, etc. * * In order to test for the need of dTHR, please try your module under a * recent version of Perl that has threading compiled-in. * */ /* #!/usr/bin/perl @ARGV = ("*.xs") if !@ARGV; %badmacros = %funcs = %macros = (); $replace = 0; foreach () { $funcs{$1} = 1 if /Provide:\s+(\S+)/; $macros{$1} = 1 if /^#\s*define\s+([a-zA-Z0-9_]+)/; $replace = $1 if /Replace:\s+(\d+)/; $badmacros{$2}=$1 if $replace and /^#\s*define\s+([a-zA-Z0-9_]+).*?\s+([a-zA-Z0-9_]+)/; $badmacros{$1}=$2 if /Replace (\S+) with (\S+)/; } foreach $filename (map(glob($_),@ARGV)) { unless (open(IN, "<$filename")) { warn "Unable to read from $file: $!\n"; next; } print "Scanning $filename...\n"; $c = ""; while () { $c .= $_; } close(IN); $need_include = 0; %add_func = (); $changes = 0; $has_include = ($c =~ /#.*include.*ppport/m); foreach $func (keys %funcs) { if ($c =~ /#.*define.*\bNEED_$func(_GLOBAL)?\b/m) { if ($c !~ /\b$func\b/m) { print "If $func isn't needed, you don't need to request it.\n" if $changes += ($c =~ s/^.*#.*define.*\bNEED_$func\b.*\n//m); } else { print "Uses $func\n"; $need_include = 1; } } else { if ($c =~ /\b$func\b/m) { $add_func{$func} =1 ; print "Uses $func\n"; $need_include = 1; } } } if (not $need_include) { foreach $macro (keys %macros) { if ($c =~ /\b$macro\b/m) { print "Uses $macro\n"; $need_include = 1; } } } foreach $badmacro (keys %badmacros) { if ($c =~ /\b$badmacro\b/m) { $changes += ($c =~ s/\b$badmacro\b/$badmacros{$badmacro}/gm); print "Uses $badmacros{$badmacro} (instead of $badmacro)\n"; $need_include = 1; } } if (scalar(keys %add_func) or $need_include != $has_include) { if (!$has_include) { $inc = join('',map("#define NEED_$_\n", sort keys %add_func)). "#include \"ppport.h\"\n"; $c = "$inc$c" unless $c =~ s/#.*include.*XSUB.*\n/$&$inc/m; } elsif (keys %add_func) { $inc = join('',map("#define NEED_$_\n", sort keys %add_func)); $c = "$inc$c" unless $c =~ s/^.*#.*include.*ppport.*$/$inc$&/m; } if (!$need_include) { print "Doesn't seem to need ppport.h.\n"; $c =~ s/^.*#.*include.*ppport.*\n//m; } $changes++; } if ($changes) { open(OUT,"ppport.h.$$"); print OUT $c; close(OUT); open(DIFF, "diff -u $filename ppport.h.$$|"); while () { s!ppport\.h\.$$!$filename.patched!; print STDOUT; } close(DIFF); unlink("ppport.h.$$"); } else { print "Looks OK\n"; } } __DATA__ */ #ifndef _P_P_PORTABILITY_H_ #define _P_P_PORTABILITY_H_ #ifndef PERL_REVISION # ifndef __PATCHLEVEL_H_INCLUDED__ # define PERL_PATCHLEVEL_H_IMPLICIT # include # endif # if !(defined(PERL_VERSION) || (defined(SUBVERSION) && defined(PATCHLEVEL))) # include # endif # ifndef PERL_REVISION # define PERL_REVISION (5) /* Replace: 1 */ # define PERL_VERSION PATCHLEVEL # define PERL_SUBVERSION SUBVERSION /* Replace PERL_PATCHLEVEL with PERL_VERSION */ /* Replace: 0 */ # endif #endif #define PERL_BCDVERSION ((PERL_REVISION * 0x1000000L) + (PERL_VERSION * 0x1000L) + PERL_SUBVERSION) /* It is very unlikely that anyone will try to use this with Perl 6 (or greater), but who knows. */ #if PERL_REVISION != 5 # error ppport.h only works with Perl version 5 #endif /* PERL_REVISION != 5 */ #ifndef ERRSV # define ERRSV perl_get_sv("@",FALSE) #endif #if (PERL_VERSION < 4) || ((PERL_VERSION == 4) && (PERL_SUBVERSION <= 5)) /* Replace: 1 */ # define PL_Sv Sv # define PL_compiling compiling # define PL_copline copline # define PL_curcop curcop # define PL_curstash curstash # define PL_defgv defgv # define PL_dirty dirty # define PL_dowarn dowarn # define PL_hints hints # define PL_na na # define PL_perldb perldb # define PL_rsfp_filters rsfp_filters # define PL_rsfpv rsfp # define PL_stdingv stdingv # define PL_sv_no sv_no # define PL_sv_undef sv_undef # define PL_sv_yes sv_yes /* Replace: 0 */ #endif #ifdef HASATTRIBUTE # if (defined(__GNUC__) && defined(__cplusplus)) || defined(__INTEL_COMPILER) # define PERL_UNUSED_DECL # else # define PERL_UNUSED_DECL __attribute__((unused)) # endif #else # define PERL_UNUSED_DECL #endif #ifndef dNOOP # define NOOP (void)0 # define dNOOP extern int Perl___notused PERL_UNUSED_DECL #endif #ifndef dTHR # define dTHR dNOOP #endif #ifndef dTHX # define dTHX dNOOP # define dTHXa(x) dNOOP # define dTHXoa(x) dNOOP #endif #ifndef pTHX # define pTHX void # define pTHX_ # define aTHX # define aTHX_ #endif #ifndef dAX # define dAX I32 ax = MARK - PL_stack_base + 1 #endif #ifndef dITEMS # define dITEMS I32 items = SP - MARK #endif /* IV could also be a quad (say, a long long), but Perls * capable of those should have IVSIZE already. */ #if !defined(IVSIZE) && defined(LONGSIZE) # define IVSIZE LONGSIZE #endif #ifndef IVSIZE # define IVSIZE 4 /* A bold guess, but the best we can make. */ #endif #ifndef UVSIZE # define UVSIZE IVSIZE #endif #ifndef NVTYPE # if defined(USE_LONG_DOUBLE) && defined(HAS_LONG_DOUBLE) # define NVTYPE long double # else # define NVTYPE double # endif typedef NVTYPE NV; #endif #ifndef INT2PTR #if (IVSIZE == PTRSIZE) && (UVSIZE == PTRSIZE) # define PTRV UV # define INT2PTR(any,d) (any)(d) #else # if PTRSIZE == LONGSIZE # define PTRV unsigned long # else # define PTRV unsigned # endif # define INT2PTR(any,d) (any)(PTRV)(d) #endif #define NUM2PTR(any,d) (any)(PTRV)(d) #define PTR2IV(p) INT2PTR(IV,p) #define PTR2UV(p) INT2PTR(UV,p) #define PTR2NV(p) NUM2PTR(NV,p) #if PTRSIZE == LONGSIZE # define PTR2ul(p) (unsigned long)(p) #else # define PTR2ul(p) INT2PTR(unsigned long,p) #endif #endif /* !INT2PTR */ #ifndef boolSV # define boolSV(b) ((b) ? &PL_sv_yes : &PL_sv_no) #endif #ifndef gv_stashpvn # define gv_stashpvn(str,len,flags) gv_stashpv(str,flags) #endif #ifndef newSVpvn # define newSVpvn(data,len) ((len) ? newSVpv ((data), (len)) : newSVpv ("", 0)) #endif #ifndef newRV_inc /* Replace: 1 */ # define newRV_inc(sv) newRV(sv) /* Replace: 0 */ #endif /* DEFSV appears first in 5.004_56 */ #ifndef DEFSV # define DEFSV GvSV(PL_defgv) #endif #ifndef SAVE_DEFSV # define SAVE_DEFSV SAVESPTR(GvSV(PL_defgv)) #endif #ifndef newRV_noinc # ifdef __GNUC__ # define newRV_noinc(sv) \ ({ \ SV *nsv = (SV*)newRV(sv); \ SvREFCNT_dec(sv); \ nsv; \ }) # else # if defined(USE_THREADS) static SV * newRV_noinc (SV * sv) { SV *nsv = (SV*)newRV(sv); SvREFCNT_dec(sv); return nsv; } # else # define newRV_noinc(sv) \ (PL_Sv=(SV*)newRV(sv), SvREFCNT_dec(sv), (SV*)PL_Sv) # endif # endif #endif /* Provide: newCONSTSUB */ /* newCONSTSUB from IO.xs is in the core starting with 5.004_63 */ #if (PERL_VERSION < 4) || ((PERL_VERSION == 4) && (PERL_SUBVERSION < 63)) #if defined(NEED_newCONSTSUB) static #else extern void newCONSTSUB(HV * stash, char * name, SV *sv); #endif #if defined(NEED_newCONSTSUB) || defined(NEED_newCONSTSUB_GLOBAL) void newCONSTSUB(stash,name,sv) HV *stash; char *name; SV *sv; { U32 oldhints = PL_hints; HV *old_cop_stash = PL_curcop->cop_stash; HV *old_curstash = PL_curstash; line_t oldline = PL_curcop->cop_line; PL_curcop->cop_line = PL_copline; PL_hints &= ~HINT_BLOCK_SCOPE; if (stash) PL_curstash = PL_curcop->cop_stash = stash; newSUB( #if (PERL_VERSION < 3) || ((PERL_VERSION == 3) && (PERL_SUBVERSION < 22)) /* before 5.003_22 */ start_subparse(), #else # if (PERL_VERSION == 3) && (PERL_SUBVERSION == 22) /* 5.003_22 */ start_subparse(0), # else /* 5.003_23 onwards */ start_subparse(FALSE, 0), # endif #endif newSVOP(OP_CONST, 0, newSVpv(name,0)), newSVOP(OP_CONST, 0, &PL_sv_no), /* SvPV(&PL_sv_no) == "" -- GMB */ newSTATEOP(0, Nullch, newSVOP(OP_CONST, 0, sv)) ); PL_hints = oldhints; PL_curcop->cop_stash = old_cop_stash; PL_curstash = old_curstash; PL_curcop->cop_line = oldline; } #endif #endif /* newCONSTSUB */ #ifndef START_MY_CXT /* * Boilerplate macros for initializing and accessing interpreter-local * data from C. All statics in extensions should be reworked to use * this, if you want to make the extension thread-safe. See ext/re/re.xs * for an example of the use of these macros. * * Code that uses these macros is responsible for the following: * 1. #define MY_CXT_KEY to a unique string, e.g. "DynaLoader_guts" * 2. Declare a typedef named my_cxt_t that is a structure that contains * all the data that needs to be interpreter-local. * 3. Use the START_MY_CXT macro after the declaration of my_cxt_t. * 4. Use the MY_CXT_INIT macro such that it is called exactly once * (typically put in the BOOT: section). * 5. Use the members of the my_cxt_t structure everywhere as * MY_CXT.member. * 6. Use the dMY_CXT macro (a declaration) in all the functions that * access MY_CXT. */ #if defined(MULTIPLICITY) || defined(PERL_OBJECT) || \ defined(PERL_CAPI) || defined(PERL_IMPLICIT_CONTEXT) /* This must appear in all extensions that define a my_cxt_t structure, * right after the definition (i.e. at file scope). The non-threads * case below uses it to declare the data as static. */ #define START_MY_CXT #if (PERL_VERSION < 4 || (PERL_VERSION == 4 && PERL_SUBVERSION < 68 )) /* Fetches the SV that keeps the per-interpreter data. */ #define dMY_CXT_SV \ SV *my_cxt_sv = perl_get_sv(MY_CXT_KEY, FALSE) #else /* >= perl5.004_68 */ #define dMY_CXT_SV \ SV *my_cxt_sv = *hv_fetch(PL_modglobal, MY_CXT_KEY, \ sizeof(MY_CXT_KEY)-1, TRUE) #endif /* < perl5.004_68 */ /* This declaration should be used within all functions that use the * interpreter-local data. */ #define dMY_CXT \ dMY_CXT_SV; \ my_cxt_t *my_cxtp = INT2PTR(my_cxt_t*,SvUV(my_cxt_sv)) /* Creates and zeroes the per-interpreter data. * (We allocate my_cxtp in a Perl SV so that it will be released when * the interpreter goes away.) */ #define MY_CXT_INIT \ dMY_CXT_SV; \ /* newSV() allocates one more than needed */ \ my_cxt_t *my_cxtp = (my_cxt_t*)SvPVX(newSV(sizeof(my_cxt_t)-1));\ Zero(my_cxtp, 1, my_cxt_t); \ sv_setuv(my_cxt_sv, PTR2UV(my_cxtp)) /* This macro must be used to access members of the my_cxt_t structure. * e.g. MYCXT.some_data */ #define MY_CXT (*my_cxtp) /* Judicious use of these macros can reduce the number of times dMY_CXT * is used. Use is similar to pTHX, aTHX etc. */ #define pMY_CXT my_cxt_t *my_cxtp #define pMY_CXT_ pMY_CXT, #define _pMY_CXT ,pMY_CXT #define aMY_CXT my_cxtp #define aMY_CXT_ aMY_CXT, #define _aMY_CXT ,aMY_CXT #else /* single interpreter */ #define START_MY_CXT static my_cxt_t my_cxt; #define dMY_CXT_SV dNOOP #define dMY_CXT dNOOP #define MY_CXT_INIT NOOP #define MY_CXT my_cxt #define pMY_CXT void #define pMY_CXT_ #define _pMY_CXT #define aMY_CXT #define aMY_CXT_ #define _aMY_CXT #endif #endif /* START_MY_CXT */ #ifndef IVdf # if IVSIZE == LONGSIZE # define IVdf "ld" # define UVuf "lu" # define UVof "lo" # define UVxf "lx" # define UVXf "lX" # else # if IVSIZE == INTSIZE # define IVdf "d" # define UVuf "u" # define UVof "o" # define UVxf "x" # define UVXf "X" # endif # endif #endif #ifndef NVef # if defined(USE_LONG_DOUBLE) && defined(HAS_LONG_DOUBLE) && \ defined(PERL_PRIfldbl) /* Not very likely, but let's try anyway. */ # define NVef PERL_PRIeldbl # define NVff PERL_PRIfldbl # define NVgf PERL_PRIgldbl # else # define NVef "e" # define NVff "f" # define NVgf "g" # endif #endif #ifndef AvFILLp /* Older perls (<=5.003) lack AvFILLp */ # define AvFILLp AvFILL #endif #ifdef SvPVbyte # if PERL_REVISION == 5 && PERL_VERSION < 7 /* SvPVbyte does not work in perl-5.6.1, borrowed version for 5.7.3 */ # undef SvPVbyte # define SvPVbyte(sv, lp) \ ((SvFLAGS(sv) & (SVf_POK|SVf_UTF8)) == (SVf_POK) \ ? ((lp = SvCUR(sv)), SvPVX(sv)) : my_sv_2pvbyte(aTHX_ sv, &lp)) static char * my_sv_2pvbyte(pTHX_ register SV *sv, STRLEN *lp) { sv_utf8_downgrade(sv,0); return SvPV(sv,*lp); } # endif #else # define SvPVbyte SvPV #endif #ifndef SvPV_nolen # define SvPV_nolen(sv) \ ((SvFLAGS(sv) & (SVf_POK)) == SVf_POK \ ? SvPVX(sv) : sv_2pv_nolen(sv)) static char * sv_2pv_nolen(pTHX_ register SV *sv) { STRLEN n_a; return sv_2pv(sv, &n_a); } #endif #ifndef get_cv # define get_cv(name,create) perl_get_cv(name,create) #endif #ifndef get_sv # define get_sv(name,create) perl_get_sv(name,create) #endif #ifndef get_av # define get_av(name,create) perl_get_av(name,create) #endif #ifndef get_hv # define get_hv(name,create) perl_get_hv(name,create) #endif #ifndef call_argv # define call_argv perl_call_argv #endif #ifndef call_method # define call_method perl_call_method #endif #ifndef call_pv # define call_pv perl_call_pv #endif #ifndef call_sv # define call_sv perl_call_sv #endif #ifndef eval_pv # define eval_pv perl_eval_pv #endif #ifndef eval_sv # define eval_sv perl_eval_sv #endif #ifndef PERL_SCAN_GREATER_THAN_UV_MAX # define PERL_SCAN_GREATER_THAN_UV_MAX 0x02 #endif #ifndef PERL_SCAN_SILENT_ILLDIGIT # define PERL_SCAN_SILENT_ILLDIGIT 0x04 #endif #ifndef PERL_SCAN_ALLOW_UNDERSCORES # define PERL_SCAN_ALLOW_UNDERSCORES 0x01 #endif #ifndef PERL_SCAN_DISALLOW_PREFIX # define PERL_SCAN_DISALLOW_PREFIX 0x02 #endif #if (PERL_VERSION > 6) || ((PERL_VERSION == 6) && (PERL_SUBVERSION >= 1)) #define I32_CAST #else #define I32_CAST (I32*) #endif #ifndef grok_hex static UV _grok_hex (char *string, STRLEN *len, I32 *flags, NV *result) { NV r = scan_hex(string, *len, I32_CAST len); if (r > UV_MAX) { *flags |= PERL_SCAN_GREATER_THAN_UV_MAX; if (result) *result = r; return UV_MAX; } return (UV)r; } # define grok_hex(string, len, flags, result) \ _grok_hex((string), (len), (flags), (result)) #endif #ifndef grok_oct static UV _grok_oct (char *string, STRLEN *len, I32 *flags, NV *result) { NV r = scan_oct(string, *len, I32_CAST len); if (r > UV_MAX) { *flags |= PERL_SCAN_GREATER_THAN_UV_MAX; if (result) *result = r; return UV_MAX; } return (UV)r; } # define grok_oct(string, len, flags, result) \ _grok_oct((string), (len), (flags), (result)) #endif #if !defined(grok_bin) && defined(scan_bin) static UV _grok_bin (char *string, STRLEN *len, I32 *flags, NV *result) { NV r = scan_bin(string, *len, I32_CAST len); if (r > UV_MAX) { *flags |= PERL_SCAN_GREATER_THAN_UV_MAX; if (result) *result = r; return UV_MAX; } return (UV)r; } # define grok_bin(string, len, flags, result) \ _grok_bin((string), (len), (flags), (result)) #endif #ifndef IN_LOCALE # define IN_LOCALE \ (PL_curcop == &PL_compiling ? IN_LOCALE_COMPILETIME : IN_LOCALE_RUNTIME) #endif #ifndef IN_LOCALE_RUNTIME # define IN_LOCALE_RUNTIME (PL_curcop->op_private & HINT_LOCALE) #endif #ifndef IN_LOCALE_COMPILETIME # define IN_LOCALE_COMPILETIME (PL_hints & HINT_LOCALE) #endif #ifndef IS_NUMBER_IN_UV # define IS_NUMBER_IN_UV 0x01 # define IS_NUMBER_GREATER_THAN_UV_MAX 0x02 # define IS_NUMBER_NOT_INT 0x04 # define IS_NUMBER_NEG 0x08 # define IS_NUMBER_INFINITY 0x10 # define IS_NUMBER_NAN 0x20 #endif #ifndef grok_numeric_radix # define GROK_NUMERIC_RADIX(sp, send) grok_numeric_radix(aTHX_ sp, send) #define grok_numeric_radix Perl_grok_numeric_radix bool Perl_grok_numeric_radix(pTHX_ const char **sp, const char *send) { #ifdef USE_LOCALE_NUMERIC #if (PERL_VERSION > 6) || ((PERL_VERSION == 6) && (PERL_SUBVERSION >= 1)) if (PL_numeric_radix_sv && IN_LOCALE) { STRLEN len; char* radix = SvPV(PL_numeric_radix_sv, len); if (*sp + len <= send && memEQ(*sp, radix, len)) { *sp += len; return TRUE; } } #else /* pre5.6.0 perls don't have PL_numeric_radix_sv so the radix * must manually be requested from locale.h */ #include struct lconv *lc = localeconv(); char *radix = lc->decimal_point; if (radix && IN_LOCALE) { STRLEN len = strlen(radix); if (*sp + len <= send && memEQ(*sp, radix, len)) { *sp += len; return TRUE; } } #endif /* PERL_VERSION */ #endif /* USE_LOCALE_NUMERIC */ /* always try "." if numeric radix didn't match because * we may have data from different locales mixed */ if (*sp < send && **sp == '.') { ++*sp; return TRUE; } return FALSE; } #endif /* grok_numeric_radix */ #ifndef grok_number #define grok_number Perl_grok_number int Perl_grok_number(pTHX_ const char *pv, STRLEN len, UV *valuep) { const char *s = pv; const char *send = pv + len; const UV max_div_10 = UV_MAX / 10; const char max_mod_10 = UV_MAX % 10; int numtype = 0; int sawinf = 0; int sawnan = 0; while (s < send && isSPACE(*s)) s++; if (s == send) { return 0; } else if (*s == '-') { s++; numtype = IS_NUMBER_NEG; } else if (*s == '+') s++; if (s == send) return 0; /* next must be digit or the radix separator or beginning of infinity */ if (isDIGIT(*s)) { /* UVs are at least 32 bits, so the first 9 decimal digits cannot overflow. */ UV value = *s - '0'; /* This construction seems to be more optimiser friendly. (without it gcc does the isDIGIT test and the *s - '0' separately) With it gcc on arm is managing 6 instructions (6 cycles) per digit. In theory the optimiser could deduce how far to unroll the loop before checking for overflow. */ if (++s < send) { int digit = *s - '0'; if (digit >= 0 && digit <= 9) { value = value * 10 + digit; if (++s < send) { digit = *s - '0'; if (digit >= 0 && digit <= 9) { value = value * 10 + digit; if (++s < send) { digit = *s - '0'; if (digit >= 0 && digit <= 9) { value = value * 10 + digit; if (++s < send) { digit = *s - '0'; if (digit >= 0 && digit <= 9) { value = value * 10 + digit; if (++s < send) { digit = *s - '0'; if (digit >= 0 && digit <= 9) { value = value * 10 + digit; if (++s < send) { digit = *s - '0'; if (digit >= 0 && digit <= 9) { value = value * 10 + digit; if (++s < send) { digit = *s - '0'; if (digit >= 0 && digit <= 9) { value = value * 10 + digit; if (++s < send) { digit = *s - '0'; if (digit >= 0 && digit <= 9) { value = value * 10 + digit; if (++s < send) { /* Now got 9 digits, so need to check each time for overflow. */ digit = *s - '0'; while (digit >= 0 && digit <= 9 && (value < max_div_10 || (value == max_div_10 && digit <= max_mod_10))) { value = value * 10 + digit; if (++s < send) digit = *s - '0'; else break; } if (digit >= 0 && digit <= 9 && (s < send)) { /* value overflowed. skip the remaining digits, don't worry about setting *valuep. */ do { s++; } while (s < send && isDIGIT(*s)); numtype |= IS_NUMBER_GREATER_THAN_UV_MAX; goto skip_value; } } } } } } } } } } } } } } } } } } numtype |= IS_NUMBER_IN_UV; if (valuep) *valuep = value; skip_value: if (GROK_NUMERIC_RADIX(&s, send)) { numtype |= IS_NUMBER_NOT_INT; while (s < send && isDIGIT(*s)) /* optional digits after the radix */ s++; } } else if (GROK_NUMERIC_RADIX(&s, send)) { numtype |= IS_NUMBER_NOT_INT | IS_NUMBER_IN_UV; /* valuep assigned below */ /* no digits before the radix means we need digits after it */ if (s < send && isDIGIT(*s)) { do { s++; } while (s < send && isDIGIT(*s)); if (valuep) { /* integer approximation is valid - it's 0. */ *valuep = 0; } } else return 0; } else if (*s == 'I' || *s == 'i') { s++; if (s == send || (*s != 'N' && *s != 'n')) return 0; s++; if (s == send || (*s != 'F' && *s != 'f')) return 0; s++; if (s < send && (*s == 'I' || *s == 'i')) { s++; if (s == send || (*s != 'N' && *s != 'n')) return 0; s++; if (s == send || (*s != 'I' && *s != 'i')) return 0; s++; if (s == send || (*s != 'T' && *s != 't')) return 0; s++; if (s == send || (*s != 'Y' && *s != 'y')) return 0; s++; } sawinf = 1; } else if (*s == 'N' || *s == 'n') { /* XXX TODO: There are signaling NaNs and quiet NaNs. */ s++; if (s == send || (*s != 'A' && *s != 'a')) return 0; s++; if (s == send || (*s != 'N' && *s != 'n')) return 0; s++; sawnan = 1; } else return 0; if (sawinf) { numtype &= IS_NUMBER_NEG; /* Keep track of sign */ numtype |= IS_NUMBER_INFINITY | IS_NUMBER_NOT_INT; } else if (sawnan) { numtype &= IS_NUMBER_NEG; /* Keep track of sign */ numtype |= IS_NUMBER_NAN | IS_NUMBER_NOT_INT; } else if (s < send) { /* we can have an optional exponent part */ if (*s == 'e' || *s == 'E') { /* The only flag we keep is sign. Blow away any "it's UV" */ numtype &= IS_NUMBER_NEG; numtype |= IS_NUMBER_NOT_INT; s++; if (s < send && (*s == '-' || *s == '+')) s++; if (s < send && isDIGIT(*s)) { do { s++; } while (s < send && isDIGIT(*s)); } else return 0; } } while (s < send && isSPACE(*s)) s++; if (s >= send) return numtype; if (len == 10 && memEQ(pv, "0 but true", 10)) { if (valuep) *valuep = 0; return IS_NUMBER_IN_UV; } return 0; } #endif /* grok_number */ #ifndef PERL_MAGIC_sv # define PERL_MAGIC_sv '\0' #endif #ifndef PERL_MAGIC_overload # define PERL_MAGIC_overload 'A' #endif #ifndef PERL_MAGIC_overload_elem # define PERL_MAGIC_overload_elem 'a' #endif #ifndef PERL_MAGIC_overload_table # define PERL_MAGIC_overload_table 'c' #endif #ifndef PERL_MAGIC_bm # define PERL_MAGIC_bm 'B' #endif #ifndef PERL_MAGIC_regdata # define PERL_MAGIC_regdata 'D' #endif #ifndef PERL_MAGIC_regdatum # define PERL_MAGIC_regdatum 'd' #endif #ifndef PERL_MAGIC_env # define PERL_MAGIC_env 'E' #endif #ifndef PERL_MAGIC_envelem # define PERL_MAGIC_envelem 'e' #endif #ifndef PERL_MAGIC_fm # define PERL_MAGIC_fm 'f' #endif #ifndef PERL_MAGIC_regex_global # define PERL_MAGIC_regex_global 'g' #endif #ifndef PERL_MAGIC_isa # define PERL_MAGIC_isa 'I' #endif #ifndef PERL_MAGIC_isaelem # define PERL_MAGIC_isaelem 'i' #endif #ifndef PERL_MAGIC_nkeys # define PERL_MAGIC_nkeys 'k' #endif #ifndef PERL_MAGIC_dbfile # define PERL_MAGIC_dbfile 'L' #endif #ifndef PERL_MAGIC_dbline # define PERL_MAGIC_dbline 'l' #endif #ifndef PERL_MAGIC_mutex # define PERL_MAGIC_mutex 'm' #endif #ifndef PERL_MAGIC_shared # define PERL_MAGIC_shared 'N' #endif #ifndef PERL_MAGIC_shared_scalar # define PERL_MAGIC_shared_scalar 'n' #endif #ifndef PERL_MAGIC_collxfrm # define PERL_MAGIC_collxfrm 'o' #endif #ifndef PERL_MAGIC_tied # define PERL_MAGIC_tied 'P' #endif #ifndef PERL_MAGIC_tiedelem # define PERL_MAGIC_tiedelem 'p' #endif #ifndef PERL_MAGIC_tiedscalar # define PERL_MAGIC_tiedscalar 'q' #endif #ifndef PERL_MAGIC_qr # define PERL_MAGIC_qr 'r' #endif #ifndef PERL_MAGIC_sig # define PERL_MAGIC_sig 'S' #endif #ifndef PERL_MAGIC_sigelem # define PERL_MAGIC_sigelem 's' #endif #ifndef PERL_MAGIC_taint # define PERL_MAGIC_taint 't' #endif #ifndef PERL_MAGIC_uvar # define PERL_MAGIC_uvar 'U' #endif #ifndef PERL_MAGIC_uvar_elem # define PERL_MAGIC_uvar_elem 'u' #endif #ifndef PERL_MAGIC_vstring # define PERL_MAGIC_vstring 'V' #endif #ifndef PERL_MAGIC_vec # define PERL_MAGIC_vec 'v' #endif #ifndef PERL_MAGIC_utf8 # define PERL_MAGIC_utf8 'w' #endif #ifndef PERL_MAGIC_substr # define PERL_MAGIC_substr 'x' #endif #ifndef PERL_MAGIC_defelem # define PERL_MAGIC_defelem 'y' #endif #ifndef PERL_MAGIC_glob # define PERL_MAGIC_glob '*' #endif #ifndef PERL_MAGIC_arylen # define PERL_MAGIC_arylen '#' #endif #ifndef PERL_MAGIC_pos # define PERL_MAGIC_pos '.' #endif #ifndef PERL_MAGIC_backref # define PERL_MAGIC_backref '<' #endif #ifndef PERL_MAGIC_ext # define PERL_MAGIC_ext '~' #endif #endif /* _P_P_PORTABILITY_H_ */ /* End of File ppport.h */ rapache-1.2.8/libapreq2/glue/perl/xsbuilder/tables/0000755000175100017510000000000012706745114021514 5ustar ondrejondrejrapache-1.2.8/libapreq2/glue/perl/xsbuilder/tables/APR/0000755000175100017510000000000012706745114022136 5ustar ondrejondrejrapache-1.2.8/libapreq2/glue/perl/xsbuilder/tables/APR/Request/0000755000175100017510000000000012706745114023566 5ustar ondrejondrejrapache-1.2.8/libapreq2/glue/perl/xsbuilder/tables/APR/Request/CallbackTable.pm0000644000175100017510000001120212706745114026564 0ustar ondrejondrejpackage APR::Request::CallbackTable; # !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! # ! WARNING: generated by My::ParseSource/ # ! Sat Apr 23 16:26:21 2005 # ! do NOT edit, any changes will be lost ! # !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! $APR::Request::CallbackTable = [ { 'return_type' => 'apr_status_t', 'name' => 'apr_status_t(*)(apreq_handle_t * ,const apr_table_t * * )', 'args' => [ { 'type' => 'apreq_handle_t *', 'name' => undef }, { 'type' => 'const apr_table_t * *', 'name' => undef } ] }, { 'return_type' => 'apr_status_t', 'name' => 'apr_status_t(*)(apreq_handle_t * ,const apr_table_t * * )', 'args' => [ { 'type' => 'apreq_handle_t *', 'name' => undef }, { 'type' => 'const apr_table_t * *', 'name' => undef } ] }, { 'return_type' => 'apr_status_t', 'name' => 'apr_status_t(*)(apreq_handle_t * ,const apr_table_t * * )', 'args' => [ { 'type' => 'apreq_handle_t *', 'name' => undef }, { 'type' => 'const apr_table_t * *', 'name' => undef } ] }, { 'return_type' => 'apreq_cookie_t *', 'name' => 'apreq_cookie_t *(*)(apreq_handle_t * ,const char * )', 'args' => [ { 'type' => 'apreq_handle_t *', 'name' => undef }, { 'type' => 'const char *', 'name' => undef } ] }, { 'return_type' => 'apreq_param_t *', 'name' => 'apreq_param_t *(*)(apreq_handle_t * ,const char * )', 'args' => [ { 'type' => 'apreq_handle_t *', 'name' => undef }, { 'type' => 'const char *', 'name' => undef } ] }, { 'return_type' => 'apreq_param_t *', 'name' => 'apreq_param_t *(*)(apreq_handle_t * ,const char * )', 'args' => [ { 'type' => 'apreq_handle_t *', 'name' => undef }, { 'type' => 'const char *', 'name' => undef } ] }, { 'return_type' => 'apr_status_t', 'name' => 'apr_status_t(*)(apreq_handle_t * ,const apreq_parser_t * * )', 'args' => [ { 'type' => 'apreq_handle_t *', 'name' => undef }, { 'type' => 'const apreq_parser_t * *', 'name' => undef } ] }, { 'return_type' => 'apr_status_t', 'name' => 'apr_status_t(*)(apreq_handle_t * ,apreq_parser_t * )', 'args' => [ { 'type' => 'apreq_handle_t *', 'name' => undef }, { 'type' => 'apreq_parser_t *', 'name' => undef } ] }, { 'return_type' => 'apr_status_t', 'name' => 'apr_status_t(*)(apreq_handle_t * ,apreq_hook_t * )', 'args' => [ { 'type' => 'apreq_handle_t *', 'name' => undef }, { 'type' => 'apreq_hook_t *', 'name' => undef } ] }, { 'return_type' => 'apr_status_t', 'name' => 'apr_status_t(*)(apreq_handle_t * ,apr_size_t * )', 'args' => [ { 'type' => 'apreq_handle_t *', 'name' => undef }, { 'type' => 'apr_size_t *', 'name' => undef } ] }, { 'return_type' => 'apr_status_t', 'name' => 'apr_status_t(*)(apreq_handle_t * ,apr_size_t )', 'args' => [ { 'type' => 'apreq_handle_t *', 'name' => undef }, { 'type' => 'apr_size_t', 'name' => undef } ] }, { 'return_type' => 'apr_status_t', 'name' => 'apr_status_t(*)(apreq_handle_t * ,apr_uint64_t * )', 'args' => [ { 'type' => 'apreq_handle_t *', 'name' => undef }, { 'type' => 'apr_uint64_t *', 'name' => undef } ] }, { 'return_type' => 'apr_status_t', 'name' => 'apr_status_t(*)(apreq_handle_t * ,apr_uint64_t )', 'args' => [ { 'type' => 'apreq_handle_t *', 'name' => undef }, { 'type' => 'apr_uint64_t', 'name' => undef } ] }, { 'return_type' => 'apr_status_t', 'name' => 'apr_status_t(*)(apreq_handle_t * ,const char * * )', 'args' => [ { 'type' => 'apreq_handle_t *', 'name' => undef }, { 'type' => 'const char * *', 'name' => undef } ] }, { 'return_type' => 'apr_status_t', 'name' => 'apr_status_t(*)(apreq_handle_t * ,const char * )', 'args' => [ { 'type' => 'apreq_handle_t *', 'name' => undef }, { 'type' => 'const char *', 'name' => undef } ] } ]; 1; rapache-1.2.8/libapreq2/glue/perl/xsbuilder/tables/APR/Request/ConstantsTable.pm0000644000175100017510000001354512706745114027060 0ustar ondrejondrejpackage APR::Request::ConstantsTable; # !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! # ! WARNING: generated by My::ParseSource/ # ! Wed Apr 27 10:57:18 2005 # ! do NOT edit, any changes will be lost ! # !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! $APR::Request::ConstantsTable = [ { 'name' => 'APREQ_APACHE2_H' }, { 'name' => 'APREQ_CHARSET_BIT' }, { 'name' => 'APREQ_CHARSET_MASK' }, { 'name' => 'APREQ_COOKIE_H' }, { 'name' => 'APREQ_COOKIE_MAX_LENGTH' }, { 'name' => 'APREQ_COOKIE_SECURE_BIT' }, { 'name' => 'APREQ_COOKIE_SECURE_MASK' }, { 'name' => 'APREQ_COOKIE_VERSION_BIT' }, { 'name' => 'APREQ_COOKIE_VERSION_MASK' }, { 'name' => 'APREQ_DECLARE_DATA' }, { 'name' => 'APREQ_DECLARE_DATA' }, { 'name' => 'APREQ_DECLARE_NONSTD' }, { 'name' => 'APREQ_DECLARE_NONSTD' }, { 'name' => 'APREQ_DECLARE_NONSTD' }, { 'name' => 'APREQ_DECLARE_NONSTD' }, { 'name' => 'APREQ_DEFAULT_BRIGADE_LIMIT' }, { 'name' => 'APREQ_DEFAULT_NELTS' }, { 'name' => 'APREQ_DEFAULT_READ_BLOCK_SIZE' }, { 'name' => 'APREQ_DEFAULT_READ_LIMIT' }, { 'name' => 'APREQ_ERROR_BADATTR' }, { 'name' => 'APREQ_ERROR_BADCHAR' }, { 'name' => 'APREQ_ERROR_BADDATA' }, { 'name' => 'APREQ_ERROR_BADHEADER' }, { 'name' => 'APREQ_ERROR_BADSEQ' }, { 'name' => 'APREQ_ERROR_BADUTF8' }, { 'name' => 'APREQ_ERROR_GENERAL' }, { 'name' => 'APREQ_ERROR_H' }, { 'name' => 'APREQ_ERROR_INTERRUPT' }, { 'name' => 'APREQ_ERROR_MISMATCH' }, { 'name' => 'APREQ_ERROR_NOATTR' }, { 'name' => 'APREQ_ERROR_NODATA' }, { 'name' => 'APREQ_ERROR_NOHEADER' }, { 'name' => 'APREQ_ERROR_NOPARSER' }, { 'name' => 'APREQ_ERROR_NOTEMPTY' }, { 'name' => 'APREQ_ERROR_NOTOKEN' }, { 'name' => 'APREQ_ERROR_OVERLIMIT' }, { 'name' => 'APREQ_ERROR_TAINTED' }, { 'name' => 'APREQ_ERROR_UNDERLIMIT' }, { 'name' => 'APREQ_EXPIRES_HTTP', 'comment' => '*< Use date formatting consistent with RFC 2616' }, { 'name' => 'APREQ_EXPIRES_NSCOOKIE', 'comment' => '*< Use format consistent with Netscape\'s Cookie Spec' }, { 'name' => 'APREQ_FLAGS_GET' }, { 'name' => 'APREQ_FLAGS_OFF' }, { 'name' => 'APREQ_FLAGS_ON' }, { 'name' => 'APREQ_FLAGS_SET' }, { 'name' => 'APREQ_H' }, { 'name' => 'APREQ_HOOK_ARGS' }, { 'name' => 'APREQ_IS_DEV_STRING' }, { 'name' => 'APREQ_IS_DEV_STRING' }, { 'name' => 'APREQ_IS_DEV_VERSION', 'comment' => '* The formatted string of libapreq\'s version' }, { 'name' => 'APREQ_JOIN_AS_IS', 'comment' => '*< Join the strings without modification' }, { 'name' => 'APREQ_JOIN_DECODE', 'comment' => '*< Url-decode the strings before joining them' }, { 'name' => 'APREQ_JOIN_ENCODE', 'comment' => '*< Url-encode the strings before joining them' }, { 'name' => 'APREQ_JOIN_QUOTE', 'comment' => '*< Quote the strings, backslashing existing quote marks.' }, { 'name' => 'APREQ_MAJOR_VERSION' }, { 'name' => 'APREQ_MATCH_FULL', 'comment' => '*< Full match only.' }, { 'name' => 'APREQ_MATCH_PARTIAL', 'comment' => '*< Partial matches are ok.' }, { 'name' => 'APREQ_MINOR_VERSION' }, { 'name' => 'APREQ_MODULE' }, { 'name' => 'APREQ_MODULE_H' }, { 'name' => 'APREQ_PARAM_H' }, { 'name' => 'APREQ_PARSERS_H', 'comment' => 'These structs are defined below' }, { 'name' => 'APREQ_PARSER_ARGS' }, { 'name' => 'APREQ_PATCH_VERSION' }, { 'name' => 'APREQ_TAINTED_BIT' }, { 'name' => 'APREQ_TAINTED_MASK' }, { 'name' => 'APREQ_UTIL_H' }, { 'name' => 'APREQ_VERSION_H' }, { 'name' => 'APREQ_VERSION_STRING' }, { 'name' => 'APREQ_XS_POSTPERL_H', 'comment' => 'avoid namespace collisions from perl\'s XSUB.h' }, { 'name' => 'APREQ_XS_PREPERL_H', 'comment' => 'we want efficiency under ithreads' }, { 'name' => 'APREQ_XS_TABLES_H', 'comment' => 'backward compatibility macros support' }, { 'name' => 'APREQ_XS_THROW_ERROR' }, { 'name' => 'APR_EBADARG', 'comment' => 'XXX: don\'t use APR_BADARG' }, { 'name' => 'APR__BucketAlloc' }, { 'name' => 'APR__Request__Param__Table' }, { 'name' => 'COOKIE_CLASS' }, { 'name' => 'COOKIE_TABLE_CLASS' }, { 'name' => 'DEREF' }, { 'name' => 'ERROR_CLASS' }, { 'name' => 'HANDLE_CLASS' }, { 'name' => 'I32_CAST' }, { 'name' => 'I32_CAST' }, { 'name' => 'MY_CXT' }, { 'name' => 'MY_CXT' }, { 'name' => 'MY_CXT_INIT' }, { 'name' => 'MY_CXT_INIT' }, { 'name' => 'NUM2PTR' }, { 'name' => 'PARAM_CLASS' }, { 'name' => 'PARAM_TABLE_CLASS' }, { 'name' => 'PERL_BCDVERSION' }, { 'name' => 'PTR2IV' }, { 'name' => 'PTR2NV' }, { 'name' => 'PTR2UV' }, { 'name' => 'START_MY_CXT' }, { 'name' => 'START_MY_CXT' }, { 'name' => '_P_P_PORTABILITY_H_' }, { 'name' => '_aMY_CXT' }, { 'name' => '_aMY_CXT' }, { 'name' => '_pMY_CXT' }, { 'name' => 'aMY_CXT' }, { 'name' => 'aMY_CXT' }, { 'name' => 'aMY_CXT_' }, { 'name' => 'apreq_attr_to_type' }, { 'name' => 'apreq_cookie' }, { 'name' => 'd' }, { 'name' => 'dMY_CXT' }, { 'name' => 'dMY_CXT' }, { 'name' => 'dMY_CXT_SV' }, { 'name' => 'dMY_CXT_SV' }, { 'name' => 'dMY_CXT_SV' }, { 'name' => 'grok_number' }, { 'name' => 'grok_numeric_radix' }, { 'name' => 'pMY_CXT' }, { 'name' => 'pMY_CXT' }, { 'name' => 'pMY_CXT_' }, { 'name' => 'pMY_CXT_' }, { 'name' => 'type' } ]; 1; rapache-1.2.8/libapreq2/glue/perl/xsbuilder/tables/APR/Request/FunctionTable.pm0000644000175100017510000021242512706745114026667 0ustar ondrejondrejpackage APR::Request::FunctionTable; # !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! # ! WARNING: generated by My::ParseSource/ # ! Wed Apr 27 10:57:18 2005 # ! do NOT edit, any changes will be lost ! # !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! $APR::Request::FunctionTable = [ { 'return_type' => 'return', 'name' => 'INT2PTR', 'args' => [ { 'type' => 'apreq_handle_t *', 'name' => 'arg0' }, { 'type' => 'iv', 'name' => 'arg1' } ] }, { 'return_type' => 'int', 'name' => 'Perl_grok_number', 'args' => [ { 'type' => 'pTHX', 'name' => 'aTHX' }, { 'type' => 'const char *', 'name' => 'pv' }, { 'type' => 'STRLEN', 'name' => 'len' }, { 'type' => 'UV *', 'name' => 'valuep' } ] }, { 'return_type' => 'bool', 'name' => 'Perl_grok_numeric_radix', 'args' => [ { 'type' => 'pTHX', 'name' => 'aTHX' }, { 'type' => 'const char * *', 'name' => 'sp' }, { 'type' => 'const char *', 'name' => 'send' } ] }, { 'return_type' => 'return', 'name' => 'SvPV_nolen', 'args' => [ { 'type' => 'sv', 'name' => 'arg0' } ] }, { 'return_type' => 'return', 'name' => 'SvRV', 'args' => [ { 'type' => 'sv', 'name' => 'arg0' } ] }, { 'return_type' => 'else', 'name' => 'XSRETURN', 'args' => [ { 'type' => '0', 'name' => 'arg0' } ] }, { 'return_type' => 'void', 'name' => 'XS_APR__Request__Cookie_nil', 'args' => [] }, { 'return_type' => 'void', 'name' => 'XS_APR__Request__Error_nil', 'args' => [] }, { 'return_type' => 'void', 'name' => 'XS_APR__Request__Param_nil', 'args' => [] }, { 'return_type' => 'UV', 'name' => '_grok_bin', 'args' => [ { 'type' => 'char *', 'name' => 'string' }, { 'type' => 'STRLEN *', 'name' => 'len' }, { 'type' => 'I32 *', 'name' => 'flags' }, { 'type' => 'NV *', 'name' => 'result' } ] }, { 'return_type' => 'UV', 'name' => '_grok_hex', 'args' => [ { 'type' => 'char *', 'name' => 'string' }, { 'type' => 'STRLEN *', 'name' => 'len' }, { 'type' => 'I32 *', 'name' => 'flags' }, { 'type' => 'NV *', 'name' => 'result' } ] }, { 'return_type' => 'UV', 'name' => '_grok_oct', 'args' => [ { 'type' => 'char *', 'name' => 'string' }, { 'type' => 'STRLEN *', 'name' => 'len' }, { 'type' => 'I32 *', 'name' => 'flags' }, { 'type' => 'NV *', 'name' => 'result' } ] }, { 'return_type' => 'apr_status_t', 'name' => 'apreq_args', 'comment' => '* * Expose the parsed "query string" associated to this handle. * * @param req The request handle * @param t The resulting table, which will either be NULL or a * valid table object on return. * * @return APR_SUCCESS or a module-specific error status code.', 'args' => [ { 'type' => 'apreq_handle_t *', 'name' => 'req' }, { 'type' => 'const apr_table_t * *', 'name' => 't' } ] }, { 'return_type' => 'apreq_param_t *', 'name' => 'apreq_args_get', 'comment' => '* * Fetch the first query string param with the given name. * * @param req The request handle * @param name Case-insensitive param name. * * @return First matching param, or NULL if none match.', 'args' => [ { 'type' => 'apreq_handle_t *', 'name' => 'req' }, { 'type' => 'const char *', 'name' => 'name' } ] }, { 'return_type' => 'apr_int64_t', 'name' => 'apreq_atoi64f', 'comment' => '* * Converts file sizes (KMG) to bytes * * @param s file size matching m/^\\\\d+[KMG]b?$/i * * @return 64-bit integer representation of s. * * @todo What happens when s is malformed? Should this return * an unsigned value instead?', 'args' => [ { 'type' => 'const char *', 'name' => 's' } ] }, { 'return_type' => 'apr_int64_t', 'name' => 'apreq_atoi64t', 'comment' => '* * Converts time strings (YMDhms) to seconds * * @param s time string matching m/^\\\\+?\\\\d+[YMDhms]$/ * * @return 64-bit integer representation of s as seconds. * * @todo What happens when s is malformed? Should this return * an unsigned value instead?', 'args' => [ { 'type' => 'const char *', 'name' => 's' } ] }, { 'return_type' => 'apr_status_t', 'name' => 'apreq_body', 'comment' => '* * Expose the parsed "request body" associated to this handle. * * @param req The request handle * @param t The resulting table, which will either be NULL or a * valid table object on return. * * @return APR_SUCCESS or a module-specific error status code.', 'args' => [ { 'type' => 'apreq_handle_t *', 'name' => 'req' }, { 'type' => 'const apr_table_t * *', 'name' => 't' } ] }, { 'return_type' => 'apreq_param_t *', 'name' => 'apreq_body_get', 'comment' => '* * Fetch the first body param with the given name. * * @param req The request handle * @param name Case-insensitive cookie name. * * @return First matching param, or NULL if none match.', 'args' => [ { 'type' => 'apreq_handle_t *', 'name' => 'req' }, { 'type' => 'const char *', 'name' => 'name' } ] }, { 'return_type' => 'apr_status_t', 'name' => 'apreq_brigade_concat', 'comment' => '* * Concatenates the brigades, spooling large brigades into * a tempfile (APREQ_SPOOL) bucket. * * @param pool Pool for creating a tempfile bucket. * @param temp_dir Directory for tempfile creation. * @param brigade_limit If out\'s length would exceed this value, * the appended buckets get written to a tempfile. * @param out Resulting brigade. * @param in Brigade to append. * * @return APR_SUCCESS. * @return Error status code resulting from either apr_brigade_length(), * apreq_file_mktemp(), apreq_brigade_fwrite(), or apr_file_seek(). * * @todo Flesh out these error codes, making them as explicit as possible.', 'args' => [ { 'type' => 'apr_pool_t *', 'name' => 'pool' }, { 'type' => 'const char *', 'name' => 'temp_dir' }, { 'type' => 'apr_size_t', 'name' => 'brigade_limit' }, { 'type' => 'apr_bucket_brigade *', 'name' => 'out' }, { 'type' => 'apr_bucket_brigade *', 'name' => 'in' } ] }, { 'return_type' => 'apr_status_t', 'name' => 'apreq_brigade_copy', 'comment' => '* * Copy a brigade. * * @param d (destination) Copied buckets are appended to this brigade. * @param s (source) Brigade to copy from. * * @return APR_SUCCESS. * @return Error status code from an unsuccessful apr_bucket_copy(). * * @remarks s == d produces Undefined Behavior.', 'args' => [ { 'type' => 'apr_bucket_brigade *', 'name' => 'd' }, { 'type' => 'apr_bucket_brigade *', 'name' => 's' } ] }, { 'return_type' => 'apr_status_t', 'name' => 'apreq_brigade_fwrite', 'comment' => '* * Writes brigade to a file. * * @param f File that gets the brigade. * @param wlen On a successful return, wlen holds the length of * the brigade, which is the amount of data written to * the file. * @param bb Bucket brigade. * * @return APR_SUCCESS. * @return Error status code from either an unsuccessful apr_bucket_read(), * or a failed apr_file_writev(). * * @remarks In the future, this function may do something * intelligent with file buckets.', 'args' => [ { 'type' => 'apr_file_t *', 'name' => 'f' }, { 'type' => 'apr_off_t *', 'name' => 'wlen' }, { 'type' => 'apr_bucket_brigade *', 'name' => 'bb' } ] }, { 'return_type' => 'apr_status_t', 'name' => 'apreq_brigade_limit_get', 'comment' => '* * Get the active brigade limit. * * @param req The handle. * @param bytes Pointer to resulting (current) limit. * * @return APR_SUCCESS or a module-specific error, * which may leave bytes undefined.', 'args' => [ { 'type' => 'apreq_handle_t *', 'name' => 'req' }, { 'type' => 'apr_size_t *', 'name' => 'bytes' } ] }, { 'return_type' => 'apr_status_t', 'name' => 'apreq_brigade_limit_set', 'comment' => '* * Set the active brigade limit. * * @param req The handle. * @param bytes New limit to use. * * @return APR_SUCCESS or module-specific error. *', 'args' => [ { 'type' => 'apreq_handle_t *', 'name' => 'req' }, { 'type' => 'apr_size_t', 'name' => 'bytes' } ] }, { 'return_type' => 'void', 'name' => 'apreq_brigade_move', 'comment' => '* * Move the front of a brigade. * * @param d (destination) Append buckets to this brigade. * @param s (source) Brigade to take buckets from. * @param e First bucket of s after the move. All buckets * before e are appended to d. * * @remarks This moves all buckets when e == APR_BRIGADE_SENTINEL(s).', 'args' => [ { 'type' => 'apr_bucket_brigade *', 'name' => 'd' }, { 'type' => 'apr_bucket_brigade *', 'name' => 's' }, { 'type' => 'apr_bucket *', 'name' => 'e' } ] }, { 'return_type' => 'apr_status_t', 'name' => 'apreq_brigade_setaside', 'comment' => '* * Set aside all buckets in the brigade. * * @param bb Brigade. * @param p Setaside buckets into this pool. * @return APR_SUCCESS. * @return Error status code from an unsuccessful apr_bucket_setaside().', 'args' => [ { 'type' => 'apr_bucket_brigade *', 'name' => 'bb' }, { 'type' => 'apr_pool_t *', 'name' => 'p' } ] }, { 'return_type' => 'apr_file_t *', 'name' => 'apreq_brigade_spoolfile', 'comment' => '* * Determines the spool file used by the brigade. Returns NULL if the * brigade is not spooled in a file (does not use an APREQ_SPOOL * bucket). * * @param bb the bucket brigade * @return the spool file, or NULL.', 'args' => [ { 'type' => 'apr_bucket_brigade *', 'name' => 'bb' } ] }, { 'return_type' => 'char *', 'name' => 'apreq_cookie_as_string', 'comment' => '* * Returns a string that represents the cookie as it would appear * in a valid "Set-Cookie*" header. * * @param c cookie. * @param p pool which allocates the returned string. * * @return header string.', 'args' => [ { 'type' => 'const apreq_cookie_t *', 'name' => 'c' }, { 'type' => 'apr_pool_t *', 'name' => 'p' } ] }, { 'return_type' => 'apr_status_t', 'name' => 'apreq_cookie_bake', 'comment' => '* * Add the cookie to the outgoing "Set-Cookie" headers. * * @param c The cookie. * @param req The request handle which set the outgoing header. * * @return APR_SUCCESS or error.', 'args' => [ { 'type' => 'const apreq_cookie_t *', 'name' => 'c' }, { 'type' => 'apreq_handle_t *', 'name' => 'req' } ] }, { 'return_type' => 'apr_status_t', 'name' => 'apreq_cookie_bake2', 'comment' => '* * Add the cookie to the outgoing "Set-Cookie2" headers. * * @param c cookie * @param req request handle * * @return APR_SUCCESS or error.', 'args' => [ { 'type' => 'const apreq_cookie_t *', 'name' => 'c' }, { 'type' => 'apreq_handle_t *', 'name' => 'req' } ] }, { 'return_type' => 'void', 'name' => 'apreq_cookie_expires', 'comment' => '* * Set the Cookie\'s expiration date. * * @param c The cookie. * @param time_str If NULL, the Cookie\'s expiration date is unset, * making it a session cookie. This means no "expires" or "max-age" * attribute will appear in the cookie\'s serialized form. If time_str * is not NULL, the expiration date will be reset to the offset (from now) * represented by time_str. The time_str should be in a format that * apreq_atoi64t() can understand, namely /[+-]?\\\\d+\\\\s*[YMDhms]/. * * @remarks Now time_str may also be a fixed date; see apr_date_parse_rfc() * for admissible formats.', 'args' => [ { 'type' => 'apreq_cookie_t *', 'name' => 'c' }, { 'type' => 'const char *', 'name' => 'time_str' } ] }, { 'return_type' => 'unsigned', 'name' => 'apreq_cookie_is_secure', 'comment' => '* @return 1 if the secure flag is set, 0 otherwise.', 'args' => [ { 'type' => 'const apreq_cookie_t *', 'name' => 'c' } ] }, { 'return_type' => 'unsigned', 'name' => 'apreq_cookie_is_tainted', 'comment' => '* @return 1 if the taint flag is set, 0 otherwise.', 'args' => [ { 'type' => 'const apreq_cookie_t *', 'name' => 'c' } ] }, { 'return_type' => 'apreq_cookie_t *', 'name' => 'apreq_cookie_make', 'comment' => '* * Returns a new cookie, made from the argument list. * * @param pool Pool which allocates the cookie. * @param name The cookie\'s name. * @param nlen Length of name. * @param value The cookie\'s value. * @param vlen Length of value. * * @return the new cookie', 'args' => [ { 'type' => 'apr_pool_t *', 'name' => 'pool' }, { 'type' => 'const char *', 'name' => 'name' }, { 'type' => 'const apr_size_t', 'name' => 'nlen' }, { 'type' => 'const char *', 'name' => 'value' }, { 'type' => 'const apr_size_t', 'name' => 'vlen' } ] }, { 'return_type' => 'void', 'name' => 'apreq_cookie_secure_off', 'comment' => '* Turns off the cookie\'s secure flag.', 'args' => [ { 'type' => 'apreq_cookie_t *', 'name' => 'c' } ] }, { 'return_type' => 'void', 'name' => 'apreq_cookie_secure_on', 'comment' => '* Sets the cookie\'s secure flag, meaning it only * comes back over an SSL-encrypted connction.', 'args' => [ { 'type' => 'apreq_cookie_t *', 'name' => 'c' } ] }, { 'return_type' => 'int', 'name' => 'apreq_cookie_serialize', 'comment' => '* * Same functionality as apreq_cookie_as_string. Stores the string * representation in buf, using up to len bytes in buf as storage. * The return value has the same semantics as that of apr_snprintf, * including the special behavior for a "len = 0" argument. * * @param c cookie. * @param buf storage location for the result. * @param len size of buf\'s storage area. * * @return size of resulting header string.', 'args' => [ { 'type' => 'const apreq_cookie_t *', 'name' => 'c' }, { 'type' => 'char *', 'name' => 'buf' }, { 'type' => 'apr_size_t', 'name' => 'len' } ] }, { 'return_type' => 'void', 'name' => 'apreq_cookie_tainted_off', 'comment' => '* Turns off the cookie\'s tainted flag.', 'args' => [ { 'type' => 'apreq_cookie_t *', 'name' => 'c' } ] }, { 'return_type' => 'void', 'name' => 'apreq_cookie_tainted_on', 'comment' => '* Sets the cookie\'s tainted flag.', 'args' => [ { 'type' => 'apreq_cookie_t *', 'name' => 'c' } ] }, { 'return_type' => 'unsigned', 'name' => 'apreq_cookie_version', 'comment' => '*@return 1 if this is an RFC cookie, 0 if its a Netscape cookie.', 'args' => [ { 'type' => 'const apreq_cookie_t *', 'name' => 'c' } ] }, { 'return_type' => 'void', 'name' => 'apreq_cookie_version_set', 'comment' => '* Sets the cookie\'s protocol version.', 'args' => [ { 'type' => 'apreq_cookie_t *', 'name' => 'c' }, { 'type' => 'unsigned', 'name' => 'v' } ] }, { 'return_type' => 'apr_table_t *', 'name' => 'apreq_cookies', 'comment' => '* * Returns a table containing all request cookies. * * @param req the apreq request handle * @param p Allocates the returned table.', 'args' => [ { 'type' => 'apreq_handle_t *', 'name' => 'req' }, { 'type' => 'apr_pool_t *', 'name' => 'p' } ] }, { 'return_type' => 'apr_size_t', 'name' => 'apreq_cp1252_to_utf8', 'comment' => '* * Convert a string from cp1252 to utf8. Caller must ensure it is large enough * to hold the encoded string and trailing \'\\\\0\'. * * @param dest Location of utf8-encoded result string. Caller must ensure it * is large enough to hold the encoded string and trailing \'\\\\0\'. * @param src Original string. * @param slen Length of original string. * * @return length of utf8-encoded string in dest; does not exceed 3 * slen.', 'args' => [ { 'type' => 'char *', 'name' => 'dest' }, { 'type' => 'const char *', 'name' => 'src' }, { 'type' => 'apr_size_t', 'name' => 'slen' } ] }, { 'return_type' => 'apr_status_t', 'name' => 'apreq_decode', 'comment' => '* * Url-decodes a string. * * @param dest Location of url-encoded result string. Caller must ensure dest is * large enough to hold the encoded string and trailing null character. * @param dlen points to resultant length of url-decoded string in dest * @param src Original string. * @param slen Length of original string. * * @return APR_SUCCESS + apreq_charset_t (<=APREQ_CHARSET_UTF8) on success. * @return APR_INCOMPLETE + apreq_charset_t (<=APREQ_CHARSET_UTF8) if the string * ends in the middle of an escape sequence. * @return ::APREQ_ERROR_BADSEQ or ::APREQ_ERROR_BADCHAR on malformed input. * * @remarks In the non-success case, dlen will be set to include * the last succesfully decoded value. This function decodes * \\%uXXXX into a utf8 (wide) character, following ECMA-262 * (the Javascript spec) Section B.2.1.', 'args' => [ { 'type' => 'char *', 'name' => 'dest' }, { 'type' => 'apr_size_t *', 'name' => 'dlen' }, { 'type' => 'const char *', 'name' => 'src' }, { 'type' => 'apr_size_t', 'name' => 'slen' } ] }, { 'return_type' => 'apr_status_t', 'name' => 'apreq_decodev', 'comment' => '* * Url-decodes an iovec array. * * @param dest Location of url-encoded result string. Caller must ensure dest is * large enough to hold the encoded string and trailing null character. * @param dlen Resultant length of dest. * @param v Array of iovecs that represent the source string * @param nelts Number of iovecs in the array. * * @return APR_SUCCESS + apreq_charset_t (<=APREQ_CHARSET_UTF8) on success. * @return APR_INCOMPLETE + apreq_charset_t (<=APREQ_CHARSET_UTF8) if the iovec * ends in the middle of an escape sequence. * @return ::APREQ_ERROR_BADSEQ or ::APREQ_ERROR_BADCHAR on malformed input. * * @remarks In the non-APR_SUCCESS case, dlen will be set to include * the last succesfully decoded value. This function decodes * \\%uXXXX into a utf8 (wide) character, following ECMA-262 * (the Javascript spec) Section B.2.1.', 'args' => [ { 'type' => 'char *', 'name' => 'dest' }, { 'type' => 'apr_size_t *', 'name' => 'dlen' }, { 'type' => 'struct iovec *', 'name' => 'v' }, { 'type' => 'int', 'name' => 'nelts' } ] }, { 'return_type' => 'apr_size_t', 'name' => 'apreq_encode', 'comment' => '* * Url-encodes a string. * * @param dest Location of url-encoded result string. Caller must ensure it * is large enough to hold the encoded string and trailing \'\\\\0\'. * @param src Original string. * @param slen Length of original string. * * @return length of url-encoded string in dest; does not exceed 3 * slen.', 'args' => [ { 'type' => 'char *', 'name' => 'dest' }, { 'type' => 'const char *', 'name' => 'src' }, { 'type' => 'const apr_size_t', 'name' => 'slen' } ] }, { 'return_type' => 'char *', 'name' => 'apreq_escape', 'comment' => '* * Returns an url-encoded copy of a string. * * @param p Pool used to allocate the return value. * @param src Original string. * @param slen Length of original string. * * @return The url-encoded string. * * @remarks Use this function insead of apreq_encode if its * caller might otherwise overflow dest.', 'args' => [ { 'type' => 'apr_pool_t *', 'name' => 'p' }, { 'type' => 'const char *', 'name' => 'src' }, { 'type' => 'const apr_size_t', 'name' => 'slen' } ] }, { 'return_type' => 'apr_status_t', 'name' => 'apreq_file_mktemp', 'comment' => '* * Makes a temporary file. * * @param fp Points to the temporary apr_file_t on success. * @param pool Pool to associate with the temp file. When the * pool is destroyed, the temp file will be closed * and deleted. * @param path The base directory which will contain the temp file. * If param == NULL, the directory will be selected via * tempnam(). See the tempnam manpage for details. * * @return APR_SUCCESS. * @return Error status code from unsuccessful apr_filepath_merge(), * or a failed apr_file_mktemp().', 'args' => [ { 'type' => 'apr_file_t * *', 'name' => 'fp' }, { 'type' => 'apr_pool_t *', 'name' => 'pool' }, { 'type' => 'const char *', 'name' => 'path' } ] }, { 'return_type' => 'apreq_handle_t *', 'name' => 'apreq_handle_apache2', 'comment' => '* * @defgroup mod_apreq2 Apache 2.X Filter Module * @ingroup apreq_module * @brief mod_apreq2 - DSO that ties libapreq2 to Apache HTTPD 2.X. * * mod_apreq2 provides the "APREQ2" input filter for using libapreq2 * (and allow its parsed data structures to be shared) within * the Apache 2.X webserver. Using it, libapreq2 works properly * in every phase of the HTTP request, from translation handlers * to output filters, and even for subrequests / internal redirects. * *
* *

Activating mod_apreq2 in Apache 2.X

* * The installation process triggered by * % make install * will not modify your webserver\'s config file. Hence, * be sure you activate it on startup by adding a LoadModule directive * to your webserver config; e.g. * * @code * * LoadModule modules/mod_apreq2.so * * @endcode * * The mod_apreq2 filter is named "APREQ2", and may be used in Apache\'s * input filter directives, e.g. * @code * * AddInputFilter APREQ2 # or * SetInputFilter APREQ2 * * @endcode * * However, this is not required because libapreq2 will add the filter (only) * if it\'s necessary. You just need to ensure that your module invokes * apreq_handle_apache2() before the content handler ultimately reads * from the input filter chain. It is important to realize that no * matter how the input filters are initially arranged, the APREQ2 filter * will attempt to reposition itself to be the last input filter to read the * data. * * If you want to use other input filters to transform the incoming HTTP * request data, is important to register those filters with Apache * as having type AP_FTYPE_CONTENT_SET or AP_FTYPE_RESOURCE. Due to the * limitations of Apache\'s current input filter design, types higher than * AP_FTYPE_CONTENT_SET may not work properly whenever the apreq filter is * active. * * This is especially true when a content handler uses libapreq2 to parse * some of the post data before doing an internal redirect. Any input * filter subsequently added to the redirected request will bypass the * original apreq filter (and therefore lose access to some of the original * post data), unless its type is less than the type of the apreq filter * (currently AP_FTYPE_PROTOCOL-1). * * *

Server Configuration Directives

* * * * * * * * * * * * * * * * * * * * * * * * * * *
Per-directory commands for mod_apreq2
DirectiveContextDefaultDescription
APREQ2_ReadLimitdirectory #APREQ_DEFAULT_READ_LIMIT Maximum number of bytes mod_apreq2 will send off to libapreq2 * for parsing. mod_apreq2 will log this event and subsequently * remove itself from the filter chain. *
APREQ2_BrigadeLimitdirectory#APREQ_DEFAULT_BRIGADE_LIMIT Maximum number of bytes mod_apreq2 will let accumulate * within the heap-buckets in a brigade. Excess data will be * spooled to an appended file bucket. *
APREQ2_TempDirdirectoryNULL Sets the location of the temporary directory apreq will use to spool * overflow brigade data (based on the APREQ2_BrigadeLimit setting). * If left unset, libapreq2 will select a platform-specific location * via apr_temp_dir_get(). *
* *

Implementation Details

*
 *   XXX apreq as a normal input filter
 *   XXX apreq as a "virtual" content handler.
 *   XXX apreq as a transparent "tee".
 *   XXX apreq parser registration in post_config
 * 
* * @{ * * Create an apreq handle which communicates with an Apache 2.X * request_rec.', 'args' => [ { 'type' => 'request_rec *', 'name' => 'r' } ] }, { 'return_type' => 'apreq_handle_t *', 'name' => 'apreq_handle_cgi', 'comment' => '* * Create an apreq handle which is suitable for a CGI program. It * reads input from stdin and writes output to stdout. * * @param pool Pool associated to this handle. * * @return New handle; can only be NULL if the pool allocation failed. * * @remarks The handle gets cached in the pool\'s userdata, so subsequent * calls will retrieve the original cached handle.', 'args' => [ { 'type' => 'apr_pool_t *', 'name' => 'pool' } ] }, { 'return_type' => 'apreq_handle_t *', 'name' => 'apreq_handle_custom', 'comment' => '* * Create a custom apreq handle which knows only some * values. Useful if you want to test the parser code or if you have * got data from a custom source (neither Apache 2 nor CGI). * * @param pool allocates the parse data, * @param query_string parsed into args table * @param cookie value of the request "Cookie" header * @param parser parses the request body * @param read_limit maximum bytes to read from the body * @param in brigade containing the request body * * @return new handle; can only be NULL if the pool allocation failed.', 'args' => [ { 'type' => 'apr_pool_t *', 'name' => 'pool' }, { 'type' => 'const char *', 'name' => 'query_string' }, { 'type' => 'const char *', 'name' => 'cookie' }, { 'type' => 'apreq_parser_t *', 'name' => 'parser' }, { 'type' => 'apr_uint64_t', 'name' => 'read_limit' }, { 'type' => 'apr_bucket_brigade *', 'name' => 'in' } ] }, { 'return_type' => 'apr_status_t', 'name' => 'apreq_header_attribute', 'comment' => '* * Search a header string for the value of a particular named attribute. * * @param hdr Header string to scan. * @param name Name of attribute to search for. * @param nlen Length of name. * @param val Location of (first) matching value. * @param vlen Length of matching value. * * @return APR_SUCCESS. * @return ::APREQ_ERROR_NOATTR if the attribute is not found. * @return ::APREQ_ERROR_BADSEQ if an unpaired quote mark was detected.', 'args' => [ { 'type' => 'const char *', 'name' => 'hdr' }, { 'type' => 'const char *', 'name' => 'name' }, { 'type' => 'const apr_size_t', 'name' => 'nlen' }, { 'type' => 'const char * *', 'name' => 'val' }, { 'type' => 'apr_size_t *', 'name' => 'vlen' } ] }, { 'return_type' => 'apr_status_t', 'name' => 'apreq_hook_add', 'comment' => '* * Add a parser hook for this request. * * @param req The request handle * @param hook Hook to add. * * @return APR_SUCCESS or module-specific error.', 'args' => [ { 'type' => 'apreq_handle_t *', 'name' => 'req' }, { 'type' => 'apreq_hook_t *', 'name' => 'hook' } ] }, { 'return_type' => 'apreq_hook_t *', 'name' => 'apreq_hook_make', 'comment' => '* * Construct a hook. * * @param pool used to allocate the hook. * @param hook The hook function. * @param next List of other hooks for this hook to call on. * @param ctx Hook\'s internal scratch pad. * @return New hook.', 'args' => [ { 'type' => 'apr_pool_t *', 'name' => 'pool' }, { 'type' => 'apreq_hook_function_t', 'name' => 'hook' }, { 'type' => 'apreq_hook_t *', 'name' => 'next' }, { 'type' => 'void *', 'name' => 'ctx' } ] }, { 'return_type' => 'apr_status_t', 'name' => 'apreq_hook_run', 'comment' => '* * Run the hook with the current parameter and the incoming * bucket brigade. The hook may modify the brigade if necessary. * Once all hooks have completed, the contents of the brigade will * be added to the parameter\'s bb attribute. * @return APR_SUCCESS on success. All other values represent errors.', 'args' => [ { 'type' => 'struct apreq_hook_t *', 'name' => 'h' }, { 'type' => 'apreq_param_t *', 'name' => 'param' }, { 'type' => 'apr_bucket_brigade *', 'name' => 'bb' } ] }, { 'return_type' => 'apr_ssize_t', 'name' => 'apreq_index', 'comment' => '* * Returns offset of match string\'s location, or -1 if no match is found. * * @param hay Location of bytes to scan. * @param hlen Number of bytes available for scanning. * @param ndl Search string * @param nlen Length of search string. * @param type Match type. * * @return Offset of match string, or -1 if no match is found. *', 'args' => [ { 'type' => 'const char *', 'name' => 'hay' }, { 'type' => 'apr_size_t', 'name' => 'hlen' }, { 'type' => 'const char *', 'name' => 'ndl' }, { 'type' => 'apr_size_t', 'name' => 'nlen' }, { 'type' => 'const apreq_match_t', 'name' => 'type' } ] }, { 'return_type' => 'apr_status_t', 'name' => 'apreq_initialize', 'comment' => '* * Initialize libapreq2. Applications (except apache modules using * mod_apreq) should call this exactly once before they use any * libapreq2 modules. If you want to modify the list of default parsers * with apreq_register_parser(), please use apreq_pre_initialize() * and apreq_post_initialize() instead. * * @param pool a base pool persisting while libapreq2 is used * @remarks after you detroy the pool, you have to call this function again * with a new pool if you still plan to use libapreq2', 'args' => [ { 'type' => 'apr_pool_t *', 'name' => 'pool' } ] }, { 'return_type' => 'apr_status_t', 'name' => 'apreq_jar', 'comment' => '* * Expose the parsed "cookie" header associated to this handle. * * @param req The request handle * @param t The resulting table, which will either be NULL or a * valid table object on return. * * @return APR_SUCCESS or a module-specific error status code.', 'args' => [ { 'type' => 'apreq_handle_t *', 'name' => 'req' }, { 'type' => 'const apr_table_t * *', 'name' => 't' } ] }, { 'return_type' => 'apreq_cookie_t *', 'name' => 'apreq_jar_get', 'comment' => '* * Fetch the first cookie with the given name. * * @param req The request handle * @param name Case-insensitive cookie name. * * @return First matching cookie, or NULL if none match.', 'args' => [ { 'type' => 'apreq_handle_t *', 'name' => 'req' }, { 'type' => 'const char *', 'name' => 'name' } ] }, { 'return_type' => 'char *', 'name' => 'apreq_join', 'comment' => '* * This header contains useful functions for creating new * parsers, hooks or modules. It includes * * - string <-> array converters * - substring search functions * - simple encoders & decoders for urlencoded strings * - simple time, date, & file-size converters * @file apreq_util.h * @brief Utility functions for apreq. * @ingroup libapreq2 * * Join an array of values. The result is an empty string if there are * no values. * * @param p Pool to allocate return value. * @param sep String that is inserted between the joined values. * @param arr Array of apreq_value_t entries. * @param mode Join type- see apreq_join_t. * * @return Joined string, or NULL on error', 'args' => [ { 'type' => 'apr_pool_t *', 'name' => 'p' }, { 'type' => 'const char *', 'name' => 'sep' }, { 'type' => 'const apr_array_header_t *', 'name' => 'arr' }, { 'type' => 'apreq_join_t', 'name' => 'mode' } ] }, { 'return_type' => 'unsigned', 'name' => 'apreq_module_status_is_error', 'comment' => '* * Defines the module-specific status codes which * are commonly considered to be non-fatal. * * @param s status code returned by an apreq_module_t method. * * @return 1 if s is fatal, 0 otherwise.', 'args' => [ { 'type' => 'apr_status_t', 'name' => 's' } ] }, { 'return_type' => 'apreq_param_t *', 'name' => 'apreq_param', 'comment' => '* * Find the first query string parameter or body parameter with the * specified name. The match is case-insensitive. * * @param req request handle. * @param key desired parameter name * * @return The first matching parameter (with args searched first) or NULL.', 'args' => [ { 'type' => 'apreq_handle_t *', 'name' => 'req' }, { 'type' => 'const char *', 'name' => 'key' } ] }, { 'return_type' => 'apreq_charset_t', 'name' => 'apreq_param_charset_get', 'comment' => '* Gets the character encoding for this parameter.', 'args' => [ { 'type' => 'apreq_param_t *', 'name' => 'p' } ] }, { 'return_type' => 'apreq_charset_t', 'name' => 'apreq_param_charset_set', 'comment' => '* Sets the character encoding for this parameter.', 'args' => [ { 'type' => 'apreq_param_t *', 'name' => 'p' }, { 'type' => 'unsigned char', 'name' => 'c' } ] }, { 'return_type' => 'apr_status_t', 'name' => 'apreq_param_decode', 'comment' => '* * Url-decodes a name=value pair into a param. * * @param param points to the decoded parameter on success * @param pool Pool from which the param is allocated. * @param word Start of the name=value pair. * @param nlen Length of urlencoded name. * @param vlen Length of urlencoded value. * * @return APR_SUCCESS + apreq_charset_t (<=APREQ_CHARSET_UTF8) on success. * @return ::APREQ_ERROR_BADSEQ or ::APREQ_ERROR_BADCHAR on malformed input. * * @remarks Unless vlen == 0, this function assumes there is * exactly one character (\'=\') which separates the pair. *', 'args' => [ { 'type' => 'apreq_param_t * *', 'name' => 'param' }, { 'type' => 'apr_pool_t *', 'name' => 'pool' }, { 'type' => 'const char *', 'name' => 'word' }, { 'type' => 'apr_size_t', 'name' => 'nlen' }, { 'type' => 'apr_size_t', 'name' => 'vlen' } ] }, { 'return_type' => 'char *', 'name' => 'apreq_param_encode', 'comment' => '* * Url-encodes the param into a name-value pair. * @param pool Pool which allocates the returned string. * @param param Param to encode. * @return name-value pair representing the param.', 'args' => [ { 'type' => 'apr_pool_t *', 'name' => 'pool' }, { 'type' => 'const apreq_param_t *', 'name' => 'param' } ] }, { 'return_type' => 'unsigned', 'name' => 'apreq_param_is_tainted', 'comment' => '* @return 1 if the taint flag is set, 0 otherwise.', 'args' => [ { 'type' => 'const apreq_param_t *', 'name' => 'p' } ] }, { 'return_type' => 'apreq_param_t *', 'name' => 'apreq_param_make', 'comment' => '* creates a param from name/value information', 'args' => [ { 'type' => 'apr_pool_t *', 'name' => 'p' }, { 'type' => 'const char *', 'name' => 'name' }, { 'type' => 'const apr_size_t', 'name' => 'nlen' }, { 'type' => 'const char *', 'name' => 'val' }, { 'type' => 'const apr_size_t', 'name' => 'vlen' } ] }, { 'return_type' => 'void', 'name' => 'apreq_param_tainted_off', 'comment' => '* Turns off the taint flag.', 'args' => [ { 'type' => 'apreq_param_t *', 'name' => 'p' } ] }, { 'return_type' => 'void', 'name' => 'apreq_param_tainted_on', 'comment' => '* Sets the tainted flag.', 'args' => [ { 'type' => 'apreq_param_t *', 'name' => 'p' } ] }, { 'return_type' => 'apr_table_t *', 'name' => 'apreq_params', 'comment' => '* * Returns a table containing key-value pairs for the full request * (args + body). * * @param req request handle * @param p allocates the returned table. * * @return table representing all available params; is never NULL.', 'args' => [ { 'type' => 'apreq_handle_t *', 'name' => 'req' }, { 'type' => 'apr_pool_t *', 'name' => 'p' } ] }, { 'return_type' => 'apr_array_header_t *', 'name' => 'apreq_params_as_array', 'comment' => '* * Returns an array of parameters (apreq_param_t *) matching the given key. * The key is case-insensitive. * @param p Allocates the returned array. * @param t the parameter table returned by apreq_args(), apreq_body() * or apreq_params() * @param key Null-terminated search key, case insensitive. * key==NULL fetches all parameters. * @return an array of apreq_param_t* (pointers) * @remark Also parses the request if necessary.', 'args' => [ { 'type' => 'apr_pool_t *', 'name' => 'p' }, { 'type' => 'const apr_table_t *', 'name' => 't' }, { 'type' => 'const char *', 'name' => 'key' } ] }, { 'return_type' => 'const char *', 'name' => 'apreq_params_as_string', 'comment' => '* * Returns a ", " -joined string containing all parameters * for the requested key, an empty string if none are found. * The key is case-insensitive. * * @param p Allocates the return string. * @param t the parameter table returned by apreq_args(), apreq_body() * or apreq_params() * @param key Null-terminated parameter name, case insensitive. * key==NULL fetches all values. * @param mode Join type- see apreq_join(). * @return the joined string or NULL on error * @remark Also parses the request if necessary.', 'args' => [ { 'type' => 'apr_pool_t *', 'name' => 'p' }, { 'type' => 'const apr_table_t *', 'name' => 't' }, { 'type' => 'const char *', 'name' => 'key' }, { 'type' => 'apreq_join_t', 'name' => 'mode' } ] }, { 'return_type' => 'apr_status_t', 'name' => 'apreq_parse', 'comment' => '* * Force a complete parse of everything. * * @param req The request handle * * @return APR_SUCCESS on an error-free parse of the request data. * Any other status code indicates a potential problem somewhere.', 'args' => [ { 'type' => 'apreq_handle_t *', 'name' => 'req' } ] }, { 'return_type' => 'apr_status_t', 'name' => 'apreq_parse_cookie_header', 'comment' => '* * Parse a cookie header and store the cookies in an apr_table_t. * * @param pool pool which allocates the cookies * @param jar table where parsed cookies are stored * @param header the header value * * @return APR_SUCCESS. * @return ::APREQ_ERROR_BADSEQ if an unparseable character sequence appears. * @return ::APREQ_ERROR_MISMATCH if an rfc-cookie attribute appears in a * netscape cookie header. * @return ::APR_ENOTIMPL if an unrecognized rfc-cookie attribute appears. * @return ::APREQ_ERROR_NOTOKEN if a required token was not present. * @return ::APREQ_ERROR_BADCHAR if an unexpected token was present.', 'args' => [ { 'type' => 'apr_pool_t *', 'name' => 'pool' }, { 'type' => 'apr_table_t *', 'name' => 'jar' }, { 'type' => 'const char *', 'name' => 'header' } ] }, { 'return_type' => 'apr_status_t', 'name' => 'apreq_parse_query_string', 'comment' => '* * Parse a url-encoded string into a param table. * @param pool pool used to allocate the param data. * @param t table to which the params are added. * @param qs Query string to url-decode. * @return APR_SUCCESS if successful, error otherwise. * @remark This function uses [&;] as the set of tokens * to delineate words, and will treat a word w/o \'=\' * as a name-value pair with value-length = 0. *', 'args' => [ { 'type' => 'apr_pool_t *', 'name' => 'pool' }, { 'type' => 'apr_table_t *', 'name' => 't' }, { 'type' => 'const char *', 'name' => 'qs' } ] }, { 'return_type' => 'apreq_parser_function_t', 'name' => 'apreq_parser', 'comment' => '* * Fetch the default parser function associated with the given MIME type. * @param enctype The desired enctype (can also be a full "Content-Type" * header). * @return The parser function, or NULL if the enctype is unrecognized.', 'args' => [ { 'type' => 'const char *', 'name' => 'enctype' } ] }, { 'return_type' => 'apr_status_t', 'name' => 'apreq_parser_add_hook', 'comment' => '* * Add a new hook to the end of the parser\'s hook list. * * @param p Parser. * @param h Hook to append.', 'args' => [ { 'type' => 'apreq_parser_t *', 'name' => 'p' }, { 'type' => 'apreq_hook_t *', 'name' => 'h' } ] }, { 'return_type' => 'apr_status_t', 'name' => 'apreq_parser_get', 'comment' => '* * Fetch the active body parser. * * @param req The request handle * @param parser Points to the active parser on return. * * @return APR_SUCCESS or module-specific error. *', 'args' => [ { 'type' => 'apreq_handle_t *', 'name' => 'req' }, { 'type' => 'const apreq_parser_t * *', 'name' => 'parser' } ] }, { 'return_type' => 'apreq_parser_t *', 'name' => 'apreq_parser_make', 'comment' => '* * Construct a parser. * * @param pool Pool used to allocate the parser. * @param ba bucket allocator used to create bucket brigades * @param content_type Content-type that this parser can deal with. * @param pfn The parser function. * @param brigade_limit the maximum in-memory bytes a brigade may use * @param temp_dir the directory used by the parser for temporary files * @param hook Hooks to asssociate this parser with. * @param ctx Parser\'s internal scratch pad. * @return New parser.', 'args' => [ { 'type' => 'apr_pool_t *', 'name' => 'pool' }, { 'type' => 'apr_bucket_alloc_t *', 'name' => 'ba' }, { 'type' => 'const char *', 'name' => 'content_type' }, { 'type' => 'apreq_parser_function_t', 'name' => 'pfn' }, { 'type' => 'apr_size_t', 'name' => 'brigade_limit' }, { 'type' => 'const char *', 'name' => 'temp_dir' }, { 'type' => 'apreq_hook_t *', 'name' => 'hook' }, { 'type' => 'void *', 'name' => 'ctx' } ] }, { 'return_type' => 'apr_status_t', 'name' => 'apreq_parser_run', 'comment' => '* * Parse the incoming brigade into a table. Parsers normally * consume all the buckets of the brigade during parsing. However * parsers may leave "rejected" data in the brigade, even during a * successful parse, so callers may need to clean up the brigade * themselves (in particular, rejected buckets should not be * passed back to the parser again). * @remark bb == NULL is valid: the parser should return its * public status: APR_INCOMPLETE, APR_SUCCESS, or an error code.', 'args' => [ { 'type' => 'struct apreq_parser_t *', 'name' => 'psr' }, { 'type' => 'apr_table_t *', 'name' => 't' }, { 'type' => 'apr_bucket_brigade *', 'name' => 'bb' } ] }, { 'return_type' => 'apr_status_t', 'name' => 'apreq_parser_set', 'comment' => '* * Set the body parser for this request. * * @param req The request handle * @param parser New parser to use. * * @return APR_SUCCESS or module-specific error.', 'args' => [ { 'type' => 'apreq_handle_t *', 'name' => 'req' }, { 'type' => 'apreq_parser_t *', 'name' => 'parser' } ] }, { 'return_type' => 'apr_status_t', 'name' => 'apreq_post_initialize', 'comment' => '* * Post-initialize libapreq2. Applications (except apache modules using * mod_apreq2) should this exactly once before they use any * libapreq2 modules for parsing. * * @param pool the same pool that was used in apreq_pre_initialize().', 'args' => [ { 'type' => 'apr_pool_t *', 'name' => 'pool' } ] }, { 'return_type' => 'apr_status_t', 'name' => 'apreq_pre_initialize', 'comment' => '* * Pre-initialize libapreq2. Applications (except apache modules using * mod_apreq2) should call this exactly once before they register custom * parsers with libapreq2. mod_apreq2 does this automatically during the * post-config phase, so modules that need call apreq_register_parser should * create a post-config hook using APR_HOOK_MIDDLE. * * @param pool a base pool persisting while libapreq2 is used * @remarks after you detroyed the pool, you have to call this function again * with a new pool if you still plan to use libapreq2', 'args' => [ { 'type' => 'apr_pool_t *', 'name' => 'pool' } ] }, { 'return_type' => 'apr_size_t', 'name' => 'apreq_quote', 'comment' => '* * Places a quoted copy of src into dest. Embedded quotes are escaped with a * backslash (\'\\\'). * * @param dest Location of quoted copy. Must be large enough to hold the copy * and trailing null byte. * @param src Original string. * @param slen Length of original string. * @param dest Destination string. * * @return length of quoted copy in dest.', 'args' => [ { 'type' => 'char *', 'name' => 'dest' }, { 'type' => 'const char *', 'name' => 'src' }, { 'type' => 'const apr_size_t', 'name' => 'slen' } ] }, { 'return_type' => 'apr_size_t', 'name' => 'apreq_quote_once', 'comment' => '* * * Same as apreq_quote() except when src begins and ends in quote marks. In * that case it assumes src is quoted correctly, and just copies src to dest. * * @param dest Location of quoted copy. Must be large enough to hold the copy * and trailing null byte. * @param src Original string. * @param slen Length of original string. * @param dest Destination string. * * @return length of quoted copy in dest.', 'args' => [ { 'type' => 'char *', 'name' => 'dest' }, { 'type' => 'const char *', 'name' => 'src' }, { 'type' => 'const apr_size_t', 'name' => 'slen' } ] }, { 'return_type' => 'apr_status_t', 'name' => 'apreq_read_limit_get', 'comment' => '* * Get the active read limit. * * @param req The request handle. * @param bytes Pointer to resulting (current) limit. * * @return APR_SUCCESS or a module-specific error, * which may leave bytes undefined.', 'args' => [ { 'type' => 'apreq_handle_t *', 'name' => 'req' }, { 'type' => 'apr_uint64_t *', 'name' => 'bytes' } ] }, { 'return_type' => 'apr_status_t', 'name' => 'apreq_read_limit_set', 'comment' => '* * Set the active read limit. * * @param req The handle. * @param bytes New limit to use. * * @return APR_SUCCESS or a module-specific error. *', 'args' => [ { 'type' => 'apreq_handle_t *', 'name' => 'req' }, { 'type' => 'apr_uint64_t', 'name' => 'bytes' } ] }, { 'return_type' => 'apr_status_t', 'name' => 'apreq_register_parser', 'comment' => '* * Register a new parsing function with a MIME enctype. * Registered parsers are added to apreq_parser()\'s * internal lookup table. * * @param enctype The MIME type. * @param pfn The function to use during parsing. Setting * parser == NULL will remove an existing parser. * * @return APR_SUCCESS or error.', 'args' => [ { 'type' => 'const char *', 'name' => 'enctype' }, { 'type' => 'apreq_parser_function_t', 'name' => 'pfn' } ] }, { 'return_type' => 'char *', 'name' => 'apreq_strerror', 'comment' => '* * apreq\'s wrapper around apr_strerror(); * recognizes APREQ_ERROR_* status codes.', 'args' => [ { 'type' => 'apr_status_t', 'name' => 's' }, { 'type' => 'char *', 'name' => 'buf' }, { 'type' => 'apr_size_t', 'name' => 'bufsize' } ] }, { 'return_type' => 'apr_status_t', 'name' => 'apreq_temp_dir_get', 'comment' => '* * Get the active temp directory. * * @param req The handle. * @param path Resulting path to temp dir. * * @return APR_SUCCESS implies path is valid, but may also be NULL. * Any other return value is module-specific, and may leave * path undefined.', 'args' => [ { 'type' => 'apreq_handle_t *', 'name' => 'req' }, { 'type' => 'const char * *', 'name' => 'path' } ] }, { 'return_type' => 'apr_status_t', 'name' => 'apreq_temp_dir_set', 'comment' => '* * Set the active temp directory. * * @param req The handle. * @param path New path to use; may be NULL. * * @return APR_SUCCESS or a module-specific error .', 'args' => [ { 'type' => 'apreq_handle_t *', 'name' => 'req' }, { 'type' => 'const char *', 'name' => 'path' } ] }, { 'return_type' => 'unsigned', 'name' => 'apreq_ua_cookie_version', 'comment' => '* * Looks for the presence of a "Cookie2" header to determine whether * or not the current User-Agent responsible for this request supports * rfc2965. * * @param req the apreq request handle * * @return ::APREQ_COOKIE_VERSION_RFC if rfc2965 is supported * by the user-agent, ::APREQ_COOKIE_VERSION_NETSCAPE otherwise.', 'args' => [ { 'type' => 'apreq_handle_t *', 'name' => 'req' } ] }, { 'return_type' => 'apr_ssize_t', 'name' => 'apreq_unescape', 'comment' => '* * An \\e in-situ url-decoder. * * @param str The string to decode * * @return Length of decoded string, or < 0 on error.', 'args' => [ { 'type' => 'char *', 'name' => 'str' } ] }, { 'return_type' => 'const apreq_param_t *', 'name' => 'apreq_upload', 'comment' => '* * Returns the first param in req->body which has both param->v.name * matching key (case insensitive) and param->upload != NULL. * @param body parameter table returned by apreq_body() or apreq_params() * @param name Parameter name. key == NULL returns first upload. * @return Corresponding upload, NULL if none found. * @remark Will parse the request as necessary.', 'args' => [ { 'type' => 'const apr_table_t *', 'name' => 'body' }, { 'type' => 'const char *', 'name' => 'name' } ] }, { 'return_type' => 'const apr_table_t *', 'name' => 'apreq_uploads', 'comment' => '* * Returns a table of all params in req->body with non-NULL upload brigades. * @param body parameter table returned by apreq_body() or apreq_params() * @param pool Pool which allocates the table struct. * @return Upload table. * @remark Will parse the request if necessary.', 'args' => [ { 'type' => 'const apr_table_t *', 'name' => 'body' }, { 'type' => 'apr_pool_t *', 'name' => 'pool' } ] }, { 'return_type' => 'void', 'name' => 'apreq_value_table_add', 'args' => [ { 'type' => 'const apreq_value_t *', 'name' => 'v' }, { 'type' => 'apr_table_t *', 'name' => 't' } ] }, { 'return_type' => 'apreq_cookie_t *', 'name' => 'apreq_value_to_cookie', 'comment' => '* Upgrades a jar\'s table values to apreq_cookie_t structs.', 'args' => [ { 'type' => 'const char *', 'name' => 'val' } ] }, { 'return_type' => 'apreq_param_t *', 'name' => 'apreq_value_to_param', 'comment' => '* Upgrades args and body table values to apreq_param_t structs.', 'args' => [ { 'type' => 'const char *', 'name' => 'val' } ] }, { 'return_type' => 'void', 'name' => 'apreq_version', 'comment' => '* * Return libapreq\'s version information information in a numeric form. * * @param pvsn Pointer to a version structure for returning the version * information.', 'args' => [ { 'type' => 'apr_version_t *', 'name' => 'pvsn' } ] }, { 'return_type' => 'const char *', 'name' => 'apreq_version_string', 'comment' => '* Return libapreq\'s version information as a string.', 'args' => [] }, { 'return_type' => 'void', 'name' => 'apreq_xs_args', 'args' => [] }, { 'return_type' => 'void', 'name' => 'apreq_xs_body', 'args' => [] }, { 'return_type' => 'void', 'name' => 'apreq_xs_brigade_copy', 'comment' => ' XXX these Apache::Upload::Brigade funcs need a makeover as vanilla XS.', 'args' => [] }, { 'return_type' => 'void', 'name' => 'apreq_xs_brigade_read', 'args' => [] }, { 'return_type' => 'void', 'name' => 'apreq_xs_brigade_readline', 'args' => [] }, { 'return_type' => 'SV *', 'name' => 'apreq_xs_cookie2sv', 'args' => [ { 'type' => 'pTHX', 'name' => 'aTHX' }, { 'type' => 'apreq_cookie_t *', 'name' => 'c' }, { 'type' => 'const char *', 'name' => 'class' }, { 'type' => 'SV *', 'name' => 'parent' } ] }, { 'return_type' => 'SV *', 'name' => 'apreq_xs_cookie_table2sv', 'args' => [ { 'type' => 'pTHX', 'name' => 'aTHX' }, { 'type' => 'const apr_table_t *', 'name' => 't' }, { 'type' => 'const char *', 'name' => 'class' }, { 'type' => 'SV *', 'name' => 'parent' }, { 'type' => 'const char *', 'name' => 'value_class' }, { 'type' => 'I32', 'name' => 'vclen' } ] }, { 'return_type' => 'void', 'name' => 'apreq_xs_cookie_table_FETCH', 'args' => [] }, { 'return_type' => 'void', 'name' => 'apreq_xs_cookie_table_NEXTKEY', 'args' => [] }, { 'return_type' => 'void', 'name' => 'apreq_xs_cookie_table_do', 'args' => [] }, { 'return_type' => 'int', 'name' => 'apreq_xs_cookie_table_do_sub', 'args' => [ { 'type' => 'void *', 'name' => 'data' }, { 'type' => 'const char *', 'name' => 'key' }, { 'type' => 'const char *', 'name' => 'val' } ] }, { 'return_type' => 'int', 'name' => 'apreq_xs_cookie_table_keys', 'args' => [ { 'type' => 'void *', 'name' => 'data' }, { 'type' => 'const char *', 'name' => 'key' }, { 'type' => 'const char *', 'name' => 'val' } ] }, { 'return_type' => 'int', 'name' => 'apreq_xs_cookie_table_magic_copy', 'comment' => ' Requires perl 5.8 or better. * A custom MGVTBL with its "copy" slot filled allows * us to FETCH a table entry immediately during iteration. * For multivalued keys this is essential in order to get * the value corresponding to the current key, otherwise * values() will always report the first value repeatedly. * With this MGVTBL the keys() list always matches up with * the values() list, even in the multivalued case. * We only prefetch the value during iteration, because the * prefetch adds overhead to EXISTS and STORE operations. * They are only "penalized" when the perl program is iterating * via each(), which seems to be a reasonable tradeoff.', 'args' => [ { 'type' => 'pTHX', 'name' => 'aTHX' }, { 'type' => 'SV *', 'name' => 'sv' }, { 'type' => 'MAGIC *', 'name' => 'mg' }, { 'type' => 'SV *', 'name' => 'nsv' }, { 'type' => 'const char *', 'name' => 'name' }, { 'type' => 'int', 'name' => 'namelen' } ] }, { 'return_type' => 'int', 'name' => 'apreq_xs_cookie_table_values', 'args' => [ { 'type' => 'void *', 'name' => 'data' }, { 'type' => 'const char *', 'name' => 'key' }, { 'type' => 'const char *', 'name' => 'val' } ] }, { 'return_type' => 'void', 'name' => 'apreq_xs_croak', 'args' => [ { 'type' => 'pTHX', 'name' => 'aTHX' }, { 'type' => 'HV *', 'name' => 'data' }, { 'type' => 'apr_status_t', 'name' => 'rc' }, { 'type' => 'const char *', 'name' => 'func' }, { 'type' => 'const char *', 'name' => 'class' } ] }, { 'return_type' => 'SV *', 'name' => 'apreq_xs_error2sv', 'args' => [ { 'type' => 'pTHX', 'name' => 'aTHX' }, { 'type' => 'apr_status_t', 'name' => 's' } ] }, { 'return_type' => 'SV *', 'name' => 'apreq_xs_find_bb_obj', 'args' => [ { 'type' => 'pTHX', 'name' => 'aTHX' }, { 'type' => 'SV *', 'name' => 'in' } ] }, { 'return_type' => 'SV *', 'name' => 'apreq_xs_find_obj', 'comment' => '* * @file apreq_xs_postperl.h * @brief XS include file for making Cookie.so and Request.so * * * @defgroup XS Perl * @ingroup GLUE * @{ * * Trace through magic objects & hashrefs looking for original object. * @param in The starting SV *. * @param key The first letter of key is used to search a hashref for * the desired object. * @return Reference to the object.', 'args' => [ { 'type' => 'pTHX', 'name' => 'aTHX' }, { 'type' => 'SV *', 'name' => 'in' }, { 'type' => 'const char', 'name' => 'key' } ] }, { 'return_type' => 'SV *', 'name' => 'apreq_xs_handle2sv', 'args' => [ { 'type' => 'pTHX', 'name' => 'aTHX' }, { 'type' => 'apreq_handle_t *', 'name' => 'req' }, { 'type' => 'const char *', 'name' => 'class' }, { 'type' => 'SV *', 'name' => 'parent' } ] }, { 'return_type' => 'const char *', 'name' => 'apreq_xs_helper_class', 'args' => [ { 'type' => 'pTHX', 'name' => 'aTHX' }, { 'type' => 'SV * *', 'name' => 'SP' }, { 'type' => 'SV *', 'name' => 'sv' }, { 'type' => 'const char *', 'name' => 'method' } ] }, { 'return_type' => 'void', 'name' => 'apreq_xs_jar', 'args' => [] }, { 'return_type' => 'SV *', 'name' => 'apreq_xs_object2sv', 'comment' => ' conversion function templates based on modperl-2\'s sv2request_rec', 'args' => [ { 'type' => 'pTHX', 'name' => 'aTHX' }, { 'type' => 'void *', 'name' => 'ptr' }, { 'type' => 'const char *', 'name' => 'class' }, { 'type' => 'SV *', 'name' => 'parent' }, { 'type' => 'const char *', 'name' => 'base' } ] }, { 'return_type' => 'void', 'name' => 'apreq_xs_param', 'args' => [] }, { 'return_type' => 'SV *', 'name' => 'apreq_xs_param2sv', 'args' => [ { 'type' => 'pTHX', 'name' => 'aTHX' }, { 'type' => 'apreq_param_t *', 'name' => 'p' }, { 'type' => 'const char *', 'name' => 'class' }, { 'type' => 'SV *', 'name' => 'parent' } ] }, { 'return_type' => 'SV *', 'name' => 'apreq_xs_param_table2sv', 'args' => [ { 'type' => 'pTHX', 'name' => 'aTHX' }, { 'type' => 'const apr_table_t *', 'name' => 't' }, { 'type' => 'const char *', 'name' => 'class' }, { 'type' => 'SV *', 'name' => 'parent' }, { 'type' => 'const char *', 'name' => 'value_class' }, { 'type' => 'I32', 'name' => 'vclen' } ] }, { 'return_type' => 'void', 'name' => 'apreq_xs_param_table_FETCH', 'args' => [] }, { 'return_type' => 'void', 'name' => 'apreq_xs_param_table_NEXTKEY', 'args' => [] }, { 'return_type' => 'void', 'name' => 'apreq_xs_param_table_do', 'args' => [] }, { 'return_type' => 'int', 'name' => 'apreq_xs_param_table_do_sub', 'args' => [ { 'type' => 'void *', 'name' => 'data' }, { 'type' => 'const char *', 'name' => 'key' }, { 'type' => 'const char *', 'name' => 'val' } ] }, { 'return_type' => 'int', 'name' => 'apreq_xs_param_table_keys', 'args' => [ { 'type' => 'void *', 'name' => 'data' }, { 'type' => 'const char *', 'name' => 'key' }, { 'type' => 'const char *', 'name' => 'val' } ] }, { 'return_type' => 'int', 'name' => 'apreq_xs_param_table_magic_copy', 'comment' => ' Requires perl 5.8 or better. * A custom MGVTBL with its "copy" slot filled allows * us to FETCH a table entry immediately during iteration. * For multivalued keys this is essential in order to get * the value corresponding to the current key, otherwise * values() will always report the first value repeatedly. * With this MGVTBL the keys() list always matches up with * the values() list, even in the multivalued case. * We only prefetch the value during iteration, because the * prefetch adds overhead to EXISTS and STORE operations. * They are only "penalized" when the perl program is iterating * via each(), which seems to be a reasonable tradeoff.', 'args' => [ { 'type' => 'pTHX', 'name' => 'aTHX' }, { 'type' => 'SV *', 'name' => 'sv' }, { 'type' => 'MAGIC *', 'name' => 'mg' }, { 'type' => 'SV *', 'name' => 'nsv' }, { 'type' => 'const char *', 'name' => 'name' }, { 'type' => 'int', 'name' => 'namelen' } ] }, { 'return_type' => 'int', 'name' => 'apreq_xs_param_table_values', 'args' => [ { 'type' => 'void *', 'name' => 'data' }, { 'type' => 'const char *', 'name' => 'key' }, { 'type' => 'const char *', 'name' => 'val' } ] }, { 'return_type' => 'void', 'name' => 'apreq_xs_parse', 'args' => [] }, { 'return_type' => 'apreq_cookie_t *', 'name' => 'apreq_xs_sv2cookie', 'args' => [ { 'type' => 'pTHX', 'name' => 'aTHX' }, { 'type' => 'SV *', 'name' => 'sv' } ] }, { 'return_type' => 'apreq_handle_t *', 'name' => 'apreq_xs_sv2handle', 'args' => [ { 'type' => 'pTHX', 'name' => 'aTHX' }, { 'type' => 'SV *', 'name' => 'sv' } ] }, { 'return_type' => 'SV *', 'name' => 'apreq_xs_sv2object', 'args' => [ { 'type' => 'pTHX', 'name' => 'aTHX' }, { 'type' => 'SV *', 'name' => 'sv' }, { 'type' => 'const char *', 'name' => 'class' }, { 'type' => 'const char', 'name' => 'attr' } ] }, { 'return_type' => 'apreq_param_t *', 'name' => 'apreq_xs_sv2param', 'args' => [ { 'type' => 'pTHX', 'name' => 'aTHX' }, { 'type' => 'SV *', 'name' => 'sv' } ] }, { 'return_type' => 'apr_status_t', 'name' => 'apreq_xs_upload_hook', 'args' => [ { 'type' => 'APREQ_HOOK_ARGS', 'name' => 'arg0' } ] }, { 'return_type' => 'apr_status_t', 'name' => 'eval_upload_hook', 'args' => [ { 'type' => 'pTHX', 'name' => 'aTHX' }, { 'type' => 'apreq_param_t *', 'name' => 'upload' }, { 'type' => 'struct hook_ctx *', 'name' => 'ctx' } ] }, { 'return_type' => 'char *', 'name' => 'my_sv_2pvbyte', 'args' => [ { 'type' => 'pTHX', 'name' => 'aTHX' }, { 'type' => 'register SV *', 'name' => 'sv' }, { 'type' => 'STRLEN *', 'name' => 'lp' } ] }, { 'return_type' => 'void', 'name' => 'newCONSTSUB', 'args' => [ { 'type' => 'HV *', 'name' => 'stash' }, { 'type' => 'char *', 'name' => 'name' }, { 'type' => 'SV *', 'name' => 'sv' } ] }, { 'return_type' => 'SV *', 'name' => 'newRV_noinc', 'args' => [ { 'type' => 'SV *', 'name' => 'sv' } ] }, { 'return_type' => 'char *', 'name' => 'sv_2pv_nolen', 'args' => [ { 'type' => 'pTHX', 'name' => 'aTHX' }, { 'type' => 'register SV *', 'name' => 'sv' } ] }, { 'return_type' => 'apr_status_t', 'name' => 'upload_hook_cleanup', 'args' => [ { 'type' => 'void *', 'name' => 'ctx_' } ] } ]; 1; rapache-1.2.8/libapreq2/glue/perl/xsbuilder/tables/APR/Request/StructureTable.pm0000644000175100017510000002313312706745114027076 0ustar ondrejondrejpackage APR::Request::StructureTable; # !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! # ! WARNING: generated by My::ParseSource/ # ! Mon Apr 25 19:35:55 2005 # ! do NOT edit, any changes will be lost ! # !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! $APR::Request::StructureTable = [ { 'type' => 'apreq_cookie_t', 'stype' => 'struct apreq_cookie_t', 'elts' => [ { 'type' => 'char *', 'name' => 'path', 'comment' => '*< Restricts url path' }, { 'type' => 'char *', 'name' => 'domain', 'comment' => '*< Restricts server domain' }, { 'type' => 'char *', 'name' => 'port', 'comment' => '*< Restricts server port' }, { 'type' => 'char *', 'name' => 'comment', 'comment' => '*< RFC cookies may send a comment' }, { 'type' => 'char *', 'name' => 'commentURL', 'comment' => '*< RFC cookies may place an URL here' }, { 'type' => 'apr_time_t', 'name' => 'max_age', 'comment' => '*< total duration of cookie: -1 == session' }, { 'type' => 'unsigned', 'name' => 'flags', 'comment' => '*< charsets, taint marks, app-specific bits' }, { 'type' => 'const apreq_value_t', 'name' => 'v', 'comment' => '*< "raw" cookie value' } ], 'comment' => '* @brief Cookie type, supporting both Netscape and RFC cookie specifications.' }, { 'type' => 'apreq_handle_t', 'stype' => 'struct apreq_handle_t', 'elts' => [ { 'type' => 'const struct apreq_module_t *', 'name' => 'module', 'comment' => '* the apreq module which implements this handle' }, { 'type' => 'apr_pool_t *', 'name' => 'pool', 'comment' => '* the pool which defines the lifetime of the parsed data' }, { 'type' => 'apr_bucket_alloc_t *', 'name' => 'bucket_alloc', 'comment' => '* the allocator, which persists at least as long as the pool' } ], 'comment' => '* * @file apreq_module.h * @brief Module API * @ingroup libapreq2 * * An apreq handle associated with a module. The structure * may have variable size, because the module may append its own data * structures after it.' }, { 'type' => 'apreq_hook_t', 'stype' => 'struct apreq_hook_t', 'elts' => [ { 'type' => 'apreq_hook_function_t', 'name' => 'hook', 'comment' => '*< the hook function' }, { 'type' => 'apreq_hook_t *', 'name' => 'next', 'comment' => '*< next item in the linked list' }, { 'type' => 'apr_pool_t *', 'name' => 'pool', 'comment' => '*< pool which allocated this hook' }, { 'type' => 'void *', 'name' => 'ctx', 'comment' => '*< a user defined pointer passed to the hook function' } ], 'comment' => '* * A hook is called by the parser whenever data arrives in a file * upload parameter of the request body. You may associate any number * of hooks with a parser instance with apreq_parser_add_hook().' }, { 'type' => 'apreq_module_t', 'stype' => 'struct apreq_module_t', 'elts' => [ { 'type' => 'const char *', 'name' => 'name', 'comment' => '* name of this apreq module' }, { 'type' => 'apr_uint32_t', 'name' => 'magic_number', 'comment' => '* magic number identifying the module and version' }, { 'type' => 'apr_status_t(*)(apreq_handle_t * ,const apr_table_t * * )', 'name' => 'jar', 'comment' => '* get a table with all cookies' }, { 'type' => 'apr_status_t(*)(apreq_handle_t * ,const apr_table_t * * )', 'name' => 'args', 'comment' => '* get a table with all query string parameters' }, { 'type' => 'apr_status_t(*)(apreq_handle_t * ,const apr_table_t * * )', 'name' => 'body', 'comment' => '* get a table with all body parameters' }, { 'type' => 'apreq_cookie_t *(*)(apreq_handle_t * ,const char * )', 'name' => 'jar_get', 'comment' => '* get a cookie by its name' }, { 'type' => 'apreq_param_t *(*)(apreq_handle_t * ,const char * )', 'name' => 'args_get', 'comment' => '* get a query string parameter by its name' }, { 'type' => 'apreq_param_t *(*)(apreq_handle_t * ,const char * )', 'name' => 'body_get', 'comment' => '* get a body parameter by its name' }, { 'type' => 'apr_status_t(*)(apreq_handle_t * ,const apreq_parser_t * * )', 'name' => 'parser_get', 'comment' => '* gets the parser associated with the request body' }, { 'type' => 'apr_status_t(*)(apreq_handle_t * ,apreq_parser_t * )', 'name' => 'parser_set', 'comment' => '* manually set a parser for the request body' }, { 'type' => 'apr_status_t(*)(apreq_handle_t * ,apreq_hook_t * )', 'name' => 'hook_add', 'comment' => '* add a hook function' }, { 'type' => 'apr_status_t(*)(apreq_handle_t * ,apr_size_t * )', 'name' => 'brigade_limit_get', 'comment' => '* determine the maximum in-memory bytes a brigade may use' }, { 'type' => 'apr_status_t(*)(apreq_handle_t * ,apr_size_t )', 'name' => 'brigade_limit_set', 'comment' => '* set the maximum in-memory bytes a brigade may use' }, { 'type' => 'apr_status_t(*)(apreq_handle_t * ,apr_uint64_t * )', 'name' => 'read_limit_get', 'comment' => '* determine the maximum amount of data that will be fed into a parser' }, { 'type' => 'apr_status_t(*)(apreq_handle_t * ,apr_uint64_t )', 'name' => 'read_limit_set', 'comment' => '* set the maximum amount of data that will be fed into a parser' }, { 'type' => 'apr_status_t(*)(apreq_handle_t * ,const char * * )', 'name' => 'temp_dir_get', 'comment' => '* determine the directory used by the parser for temporary files' }, { 'type' => 'apr_status_t(*)(apreq_handle_t * ,const char * )', 'name' => 'temp_dir_set', 'comment' => '* set the directory used by the parser for temporary files' } ], 'comment' => '* * @brief Vtable describing the necessary environment functions.' }, { 'type' => 'apreq_param_t', 'stype' => 'struct apreq_param_t', 'elts' => [ { 'type' => 'apr_table_t *', 'name' => 'info', 'comment' => '*< header table associated with the param' }, { 'type' => 'apr_bucket_brigade *', 'name' => 'upload', 'comment' => '*< brigade used to spool upload files' }, { 'type' => 'unsigned', 'name' => 'flags', 'comment' => '*< charsets, taint marks, app-specific bits' }, { 'type' => 'const apreq_value_t', 'name' => 'v', 'comment' => '*< underlying name/value info' } ], 'comment' => '* * @file apreq_param.h * @brief Request parsing and parameter API * @ingroup libapreq2 * Common data structure for params and file uploads' }, { 'type' => 'apreq_parser_t', 'stype' => 'struct apreq_parser_t', 'elts' => [ { 'type' => 'apreq_parser_function_t', 'name' => 'parser', 'comment' => '* the function which parses chunks of body data' }, { 'type' => 'const char *', 'name' => 'content_type', 'comment' => '* the Content-Type request header' }, { 'type' => 'apr_pool_t *', 'name' => 'pool', 'comment' => '* a pool used by the parser' }, { 'type' => 'apr_bucket_alloc_t *', 'name' => 'bucket_alloc', 'comment' => '* bucket allocator used to create bucket brigades' }, { 'type' => 'apr_size_t', 'name' => 'brigade_limit', 'comment' => '* the maximum in-memory bytes a brigade may use' }, { 'type' => 'const char *', 'name' => 'temp_dir', 'comment' => '* the directory used by the parser for temporary files' }, { 'type' => 'apreq_hook_t *', 'name' => 'hook', 'comment' => '* linked list of hooks' }, { 'type' => 'void *', 'name' => 'ctx', 'comment' => '* internal context pointer used by the parser function' } ], 'comment' => '* * A request body parser instance.' }, { 'type' => 'apreq_value_t', 'stype' => 'struct apreq_value_t', 'elts' => [ { 'type' => 'char *', 'name' => 'name', 'comment' => '*< value name' }, { 'type' => 'apr_size_t', 'name' => 'nlen', 'comment' => '*< length of name' }, { 'type' => 'apr_size_t', 'name' => 'dlen', 'comment' => '*< length of data' }, { 'type' => 'char', 'name' => 'data[1]', 'comment' => '*< value data' } ], 'comment' => '* @brief libapreq\'s pre-extensible string type' }, { 'type' => 'struct hook_ctx', 'stype' => 'struct hook_ctx', 'elts' => [ { 'type' => 'SV *', 'name' => 'hook' }, { 'type' => 'SV *', 'name' => 'bucket_data' }, { 'type' => 'SV *', 'name' => 'parent' }, { 'type' => 'PerlInterpreter *', 'name' => 'perl' } ] } ]; 1; rapache-1.2.8/libapreq2/glue/perl/xsbuilder/typemap0000644000175100017510000000736512706745114021657 0ustar ondrejondrejAPR::Pool T_POOLOBJ APR::BucketAlloc T_PTROBJ APR::Request::Apache2 T_APREQ_HANDLE_APACHE2 APR::Request::Cookie T_APREQ_COOKIE APR::Request::Param::Table T_APREQ_TABLE APR::Brigade T_PTROBJ APR::Table T_HASHOBJ APR::Request::CGI T_APREQ_HANDLE_CGI APR::Request::Param T_APREQ_PARAM APR::Request::Error T_APREQ_ERROR Apache2::RequestRec T_APACHEOBJ APR::Request::Cookie::Table T_HASHOBJ APR::Request T_APREQ_HANDLE apr_status_t T_IV const void * T_PTR const char * T_PV apreq_xs_subclass_t T_SUBCLASS const apreq_xs_subclass_t * T_SUBCLASS const apr_size_t T_UV apreq_xs_subclass_t * T_SUBCLASS apr_size_t T_UV unsigned char T_UV INPUT T_APREQ_HANDLE $var = apreq_xs_sv2handle(aTHX_ $arg) T_HASHOBJ if (sv_derived_from($arg, \"${ntype}\")) { if (SVt_PVHV == SvTYPE(SvRV($arg))) { SV *hv = SvRV($arg); MAGIC *mg; if (SvMAGICAL(hv)) { if ((mg = mg_find(hv, PERL_MAGIC_tied))) { $var = INT2PTR(void *, MgObjIV(mg)); } else { Perl_warn(aTHX_ \"Not a tied hash: (magic=%c)\", mg); $var = NULL; } } else { Perl_warn(aTHX_ \"SV is not tied\"); $var = NULL; } } else { $var = INT2PTR(void *, SvObjIV($arg)); } } else { Perl_croak(aTHX_ \"argument is not a blessed reference \" \"(expecting an %s derived object)\", \"${ntype}\"); } T_APREQ_ERROR $var = (HV *)SvRV($arg) T_APREQ_HANDLE_APACHE2 $var = apreq_xs_sv2handle(aTHX_ $arg) T_APREQ_COOKIE $var = apreq_xs_sv2cookie(aTHX_ $arg) T_SUBCLASS if (SvROK($arg) || !sv_derived_from($arg, \"$Package\")) Perl_croak(aTHX_ \"Usage: argument is not a subclass of $Package\"); $var = SvPV_nolen($arg) T_APREQ_HANDLE_CGI $var = apreq_xs_sv2handle(aTHX_ $arg) T_APREQ_PARAM $var = apreq_xs_sv2param(aTHX_ $arg) T_APREQ_TABLE if (sv_derived_from($arg, \"${ntype}\")) { if (SVt_PVHV == SvTYPE(SvRV($arg))) { SV *hv = SvRV($arg); MAGIC *mg; if (SvMAGICAL(hv)) { if ((mg = mg_find(hv, PERL_MAGIC_tied))) { $var = INT2PTR(void *,MgObjIV(mg)); } else { Perl_warn(aTHX_ \"Not a tied hash: (magic=%c)\", mg); $var = NULL; } } else { Perl_warn(aTHX_ \"SV is not tied\"); $var = NULL; } } else { $var = INT2PTR(void *, SvObjIV($arg)); } } else { Perl_croak(aTHX_ \"argument is not a blessed reference \" \"(expecting an %s derived object)\", \"${ntype}\"); } OUTPUT T_APREQ_HANDLE $arg = apreq_xs_handle2sv(aTHX_ $var, class, parent); T_APREQ_TABLE $arg = apreq_xs_table2sv(aTHX_ $var, \"${ntype}\", parent, PARAM_CLASS, sizeof(PARAM_CLASS)-1); T_HASHOBJ { SV *hv = (SV*)newHV(); SV *rsv = $arg; sv_setref_pv(rsv, \"${ntype}\", $var); sv_magic(hv, rsv, PERL_MAGIC_tied, Nullch, 0); $arg = SvREFCNT_inc(sv_bless(sv_2mortal(newRV_noinc(hv)), gv_stashpv(\"${ntype}\", TRUE))); } T_APREQ_ERROR $arg = sv_bless(newRV_noinc((SV*)$var), gv_stashpvn(\"${ntype}\", sizeof(\"${ntype}\") - 1, FALSE); T_APREQ_HANDLE_APACHE2 $arg = apreq_xs_handle2sv(aTHX_ $var, class, SvRV(ST(1))); SvMAGIC(SvRV($arg))->mg_ptr = (void *)r; T_APREQ_COOKIE $arg = apreq_xs_cookie2sv(aTHX_ $var, class, parent); T_APREQ_HANDLE_CGI $arg = apreq_xs_handle2sv(aTHX_ $var, class, SvRV(ST(1))); T_APREQ_PARAM $arg = apreq_xs_param2sv(aTHX_ $var, class, parent); rapache-1.2.8/libapreq2/include/0000755000175100017510000000000012706745114015766 5ustar ondrejondrejrapache-1.2.8/libapreq2/include/Makefile.am0000644000175100017510000000033012706745114020016 0ustar ondrejondrejpkgincludedir = $(includedir)/@APREQ_LIBNAME@ pkginclude_HEADERS = apreq.h apreq_cookie.h apreq_error.h \ apreq_module.h apreq_param.h apreq_parser.h \ apreq_util.h apreq_version.h rapache-1.2.8/libapreq2/include/Makefile.in0000644000175100017510000002175312706745114020043 0ustar ondrejondrej# Makefile.in generated by automake 1.6.3 from Makefile.am. # @configure_input@ # Copyright 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002 # 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@ SHELL = @SHELL@ srcdir = @srcdir@ top_srcdir = @top_srcdir@ VPATH = @srcdir@ prefix = @prefix@ exec_prefix = @exec_prefix@ bindir = @bindir@ sbindir = @sbindir@ libexecdir = @libexecdir@ datadir = @datadir@ sysconfdir = @sysconfdir@ sharedstatedir = @sharedstatedir@ localstatedir = @localstatedir@ libdir = @libdir@ infodir = @infodir@ mandir = @mandir@ includedir = @includedir@ oldincludedir = /usr/include pkgdatadir = $(datadir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ top_builddir = .. ACLOCAL = @ACLOCAL@ AUTOCONF = @AUTOCONF@ AUTOMAKE = @AUTOMAKE@ AUTOHEADER = @AUTOHEADER@ am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd INSTALL = @INSTALL@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_DATA = @INSTALL_DATA@ install_sh_DATA = $(install_sh) -c -m 644 install_sh_PROGRAM = $(install_sh) -c install_sh_SCRIPT = $(install_sh) -c INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_HEADER = $(INSTALL_DATA) transform = @program_transform_name@ NORMAL_INSTALL = : PRE_INSTALL = : POST_INSTALL = : NORMAL_UNINSTALL = : PRE_UNINSTALL = : POST_UNINSTALL = : host_alias = @host_alias@ host_triplet = @host@ EXEEXT = @EXEEXT@ OBJEXT = @OBJEXT@ PATH_SEPARATOR = @PATH_SEPARATOR@ pkgincludedir = $(includedir)/@APREQ_LIBNAME@ AMTAR = @AMTAR@ APACHE1_APXS = @APACHE1_APXS@ APACHE2_APXS = @APACHE2_APXS@ APACHE2_HTTPD = @APACHE2_HTTPD@ APACHE2_INCLUDES = @APACHE2_INCLUDES@ APACHE2_SRC = @APACHE2_SRC@ APREQ_CONFIG = @APREQ_CONFIG@ APREQ_DOTTED_VERSION = @APREQ_DOTTED_VERSION@ APREQ_LIBNAME = @APREQ_LIBNAME@ APREQ_LIBTOOL_VERSION = @APREQ_LIBTOOL_VERSION@ APREQ_MAJOR_VERSION = @APREQ_MAJOR_VERSION@ APR_CONFIG = @APR_CONFIG@ APR_INCLUDES = @APR_INCLUDES@ APR_LA = @APR_LA@ APR_LDFLAGS = @APR_LDFLAGS@ APR_LIBS = @APR_LIBS@ APR_LTFLAGS = @APR_LTFLAGS@ APU_CONFIG = @APU_CONFIG@ APU_LA = @APU_LA@ AR = @AR@ AS = @AS@ AWK = @AWK@ CC = @CC@ CXX = @CXX@ CXXCPP = @CXXCPP@ DEPDIR = @DEPDIR@ DLLTOOL = @DLLTOOL@ ECHO = @ECHO@ EGREP = @EGREP@ F77 = @F77@ GCJ = @GCJ@ GCJFLAGS = @GCJFLAGS@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ LIBTOOL = @LIBTOOL@ LN_S = @LN_S@ MAINT = @MAINT@ OBJDUMP = @OBJDUMP@ PACKAGE = @PACKAGE@ PERL = @PERL@ PERL_OPTS = @PERL_OPTS@ RANLIB = @RANLIB@ RC = @RC@ STRIP = @STRIP@ VERSION = @VERSION@ am__include = @am__include@ am__quote = @am__quote@ install_sh = @install_sh@ pkginclude_HEADERS = apreq.h apreq_cookie.h apreq_error.h \ apreq_module.h apreq_param.h apreq_parser.h \ apreq_util.h apreq_version.h subdir = include mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs CONFIG_HEADER = apreq_config.h CONFIG_CLEAN_FILES = groups.dox DIST_SOURCES = HEADERS = $(pkginclude_HEADERS) DIST_COMMON = $(pkginclude_HEADERS) Makefile.am Makefile.in \ apreq_config.h.in groups.dox.in all: apreq_config.h $(MAKE) $(AM_MAKEFLAGS) all-am .SUFFIXES: $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ Makefile.am $(top_srcdir)/configure.ac $(ACLOCAL_M4) cd $(top_srcdir) && \ $(AUTOMAKE) --gnu include/Makefile Makefile: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.in $(top_builddir)/config.status cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe) apreq_config.h: stamp-h1 @if test ! -f $@; then \ rm -f stamp-h1; \ $(MAKE) stamp-h1; \ else :; fi stamp-h1: $(srcdir)/apreq_config.h.in $(top_builddir)/config.status @rm -f stamp-h1 cd $(top_builddir) && $(SHELL) ./config.status include/apreq_config.h $(srcdir)/apreq_config.h.in: @MAINTAINER_MODE_TRUE@ $(top_srcdir)/configure.ac $(ACLOCAL_M4) cd $(top_srcdir) && $(AUTOHEADER) touch $(srcdir)/apreq_config.h.in distclean-hdr: -rm -f apreq_config.h stamp-h1 groups.dox: $(top_builddir)/config.status groups.dox.in cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ mostlyclean-libtool: -rm -f *.lo clean-libtool: -rm -rf .libs _libs distclean-libtool: -rm -f libtool uninstall-info-am: pkgincludeHEADERS_INSTALL = $(INSTALL_HEADER) install-pkgincludeHEADERS: $(pkginclude_HEADERS) @$(NORMAL_INSTALL) $(mkinstalldirs) $(DESTDIR)$(pkgincludedir) @list='$(pkginclude_HEADERS)'; for p in $$list; do \ if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ f="`echo $$p | sed -e 's|^.*/||'`"; \ echo " $(pkgincludeHEADERS_INSTALL) $$d$$p $(DESTDIR)$(pkgincludedir)/$$f"; \ $(pkgincludeHEADERS_INSTALL) $$d$$p $(DESTDIR)$(pkgincludedir)/$$f; \ done uninstall-pkgincludeHEADERS: @$(NORMAL_UNINSTALL) @list='$(pkginclude_HEADERS)'; for p in $$list; do \ f="`echo $$p | sed -e 's|^.*/||'`"; \ echo " rm -f $(DESTDIR)$(pkgincludedir)/$$f"; \ rm -f $(DESTDIR)$(pkgincludedir)/$$f; \ done ETAGS = etags ETAGSFLAGS = tags: TAGS 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; } \ END { for (i in files) print i; }'`; \ mkid -fID $$unique TAGS: $(HEADERS) $(SOURCES) apreq_config.h.in $(TAGS_DEPENDENCIES) \ $(TAGS_FILES) $(LISP) tags=; \ here=`pwd`; \ list='$(SOURCES) $(HEADERS) apreq_config.h.in $(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; } \ END { for (i in files) print i; }'`; \ test -z "$(ETAGS_ARGS)$$tags$$unique" \ || $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ $$tags $$unique GTAGS: here=`$(am__cd) $(top_builddir) && pwd` \ && cd $(top_srcdir) \ && gtags -i $(GTAGS_ARGS) $$here distclean-tags: -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) top_distdir = .. distdir = $(top_distdir)/$(PACKAGE)-$(VERSION) distdir: $(DISTFILES) @list='$(DISTFILES)'; for file in $$list; do \ if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ dir=`echo "$$file" | sed -e 's,/[^/]*$$,,'`; \ if test "$$dir" != "$$file" && test "$$dir" != "."; then \ dir="/$$dir"; \ $(mkinstalldirs) "$(distdir)$$dir"; \ else \ dir=''; \ fi; \ if test -d $$d/$$file; then \ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \ fi; \ cp -pR $$d/$$file $(distdir)$$dir || exit 1; \ else \ test -f $(distdir)/$$file \ || cp -p $$d/$$file $(distdir)/$$file \ || exit 1; \ fi; \ done check-am: all-am check: check-am all-am: Makefile $(HEADERS) apreq_config.h installdirs: $(mkinstalldirs) $(DESTDIR)$(pkgincludedir) 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_STRIP_FLAG=-s \ `test -z '$(STRIP)' || \ echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install mostlyclean-generic: clean-generic: distclean-generic: -rm -f Makefile $(CONFIG_CLEAN_FILES) maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." clean: clean-am clean-am: clean-generic clean-libtool mostlyclean-am distclean: distclean-am distclean-am: clean-am distclean-generic distclean-hdr distclean-libtool \ distclean-tags dvi: dvi-am dvi-am: info: info-am info-am: install-data-am: install-pkgincludeHEADERS install-exec-am: install-info: install-info-am install-man: installcheck-am: maintainer-clean: maintainer-clean-am maintainer-clean-am: distclean-am maintainer-clean-generic mostlyclean: mostlyclean-am mostlyclean-am: mostlyclean-generic mostlyclean-libtool uninstall-am: uninstall-info-am uninstall-pkgincludeHEADERS .PHONY: GTAGS all all-am check check-am clean clean-generic \ clean-libtool distclean distclean-generic distclean-hdr \ distclean-libtool distclean-tags distdir dvi dvi-am info \ info-am install install-am install-data install-data-am \ install-exec install-exec-am install-info install-info-am \ install-man install-pkgincludeHEADERS install-strip \ installcheck installcheck-am installdirs maintainer-clean \ maintainer-clean-generic mostlyclean mostlyclean-generic \ mostlyclean-libtool tags uninstall uninstall-am \ uninstall-info-am uninstall-pkgincludeHEADERS # 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: rapache-1.2.8/libapreq2/include/apreq.h0000644000175100017510000001235712706745114017257 0ustar ondrejondrej/* ** Copyright 2003-2005 The Apache Software Foundation ** ** Licensed under the Apache License, Version 2.0 (the "License"); ** you may not use this file except in compliance with the License. ** You may obtain a copy of the License at ** ** http://www.apache.org/licenses/LICENSE-2.0 ** ** Unless required by applicable law or agreed to in writing, software ** distributed under the License is distributed on an "AS IS" BASIS, ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ** See the License for the specific language governing permissions and ** limitations under the License. */ #ifndef APREQ_H #define APREQ_H #ifdef APREQ_DEBUG #include #endif #include "apr_tables.h" #include #ifdef __cplusplus extern "C" { #endif /** * @file apreq.h * @brief Main header file... * @ingroup libapreq2 * * Define the generic APREQ_ macros and common data structures. */ #ifndef WIN32 #define APREQ_DECLARE(d) APR_DECLARE(d) #define APREQ_DECLARE_NONSTD(d) APR_DECLARE_NONSTD(d) #define APREQ_DECLARE_DATA #else #define APREQ_DECLARE(type) __declspec(dllexport) type __stdcall #define APREQ_DECLARE_NONSTD(type) __declspec(dllexport) type #define APREQ_DECLARE_DATA __declspec(dllexport) #endif #define APREQ_DEFAULT_READ_BLOCK_SIZE (64 * 1024) #define APREQ_DEFAULT_READ_LIMIT (64 * 1024 * 1024) #define APREQ_DEFAULT_BRIGADE_LIMIT (256 * 1024) #define APREQ_DEFAULT_NELTS 8 #define APREQ_FLAGS_OFF(f, name) ((f) &= ~(name##_MASK << name##_BIT)) #define APREQ_FLAGS_ON(f, name) ((f) |= (name##_MASK << name##_BIT)) #define APREQ_FLAGS_GET(f, name) (((f) >> name##_BIT) & name##_MASK) #define APREQ_FLAGS_SET(f, name, value) \ ((f) = (((f) & ~(name##_MASK << name##_BIT)) \ | ((name##_MASK & (value)) << name##_BIT))) #define APREQ_CHARSET_BIT 0 #define APREQ_CHARSET_MASK 255 #define APREQ_TAINTED_BIT 8 #define APREQ_TAINTED_MASK 1 #define APREQ_COOKIE_VERSION_BIT 11 #define APREQ_COOKIE_VERSION_MASK 3 #define APREQ_COOKIE_SECURE_BIT 13 #define APREQ_COOKIE_SECURE_MASK 1 /** Character encodings. */ typedef enum { APREQ_CHARSET_ASCII =0, APREQ_CHARSET_LATIN1 =1, /* ISO-8859-1 */ APREQ_CHARSET_CP1252 =2, /* Windows-1252 */ APREQ_CHARSET_UTF8 =8 } apreq_charset_t; /** @enum apreq_join_t Join type */ typedef enum { APREQ_JOIN_AS_IS, /**< Join the strings without modification */ APREQ_JOIN_ENCODE, /**< Url-encode the strings before joining them */ APREQ_JOIN_DECODE, /**< Url-decode the strings before joining them */ APREQ_JOIN_QUOTE /**< Quote the strings, backslashing existing quote marks. */ } apreq_join_t; /** @enum apreq_match_t Match type */ typedef enum { APREQ_MATCH_FULL, /**< Full match only. */ APREQ_MATCH_PARTIAL /**< Partial matches are ok. */ } apreq_match_t; /** @enum apreq_expires_t Expiration date format */ typedef enum { APREQ_EXPIRES_HTTP, /**< Use date formatting consistent with RFC 2616 */ APREQ_EXPIRES_NSCOOKIE /**< Use format consistent with Netscape's Cookie Spec */ } apreq_expires_t; /** @brief libapreq's pre-extensible string type */ typedef struct apreq_value_t { char *name; /**< value name */ apr_size_t nlen; /**< length of name */ apr_size_t dlen; /**< length of data */ char data[1]; /**< value data */ } apreq_value_t; static APR_INLINE void apreq_value_table_add(const apreq_value_t *v, apr_table_t *t) { apr_table_addn(t, v->name, v->data); } #define apreq_attr_to_type(T,A,P) ( (T*) ((char*)(P)-offsetof(T,A)) ) /** * Initialize libapreq2. Applications (except apache modules using * mod_apreq) should call this exactly once before they use any * libapreq2 modules. If you want to modify the list of default parsers * with apreq_register_parser(), please use apreq_pre_initialize() * and apreq_post_initialize() instead. * * @param pool a base pool persisting while libapreq2 is used * @remarks after you detroy the pool, you have to call this function again * with a new pool if you still plan to use libapreq2 */ APREQ_DECLARE(apr_status_t) apreq_initialize(apr_pool_t *pool); /** * Pre-initialize libapreq2. Applications (except apache modules using * mod_apreq2) should call this exactly once before they register custom * parsers with libapreq2. mod_apreq2 does this automatically during the * post-config phase, so modules that need call apreq_register_parser should * create a post-config hook using APR_HOOK_MIDDLE. * * @param pool a base pool persisting while libapreq2 is used * @remarks after you detroyed the pool, you have to call this function again * with a new pool if you still plan to use libapreq2 */ APREQ_DECLARE(apr_status_t) apreq_pre_initialize(apr_pool_t *pool); /** * Post-initialize libapreq2. Applications (except apache modules using * mod_apreq2) should this exactly once before they use any * libapreq2 modules for parsing. * * @param pool the same pool that was used in apreq_pre_initialize(). */ APREQ_DECLARE(apr_status_t) apreq_post_initialize(apr_pool_t *pool); #ifdef __cplusplus } #endif #endif /* APREQ_H */ rapache-1.2.8/libapreq2/include/apreq_config.h.in0000644000175100017510000000266512706745114021212 0ustar ondrejondrej/* include/apreq_config.h.in. Generated from configure.ac by autoheader. */ /* Define to 1 if you have the header file. */ #undef HAVE_DLFCN_H /* Define to 1 if you have the header file. */ #undef HAVE_INTTYPES_H /* Define to 1 if you have the header file. */ #undef HAVE_MEMORY_H /* Define to 1 if you have the header file. */ #undef HAVE_STDINT_H /* Define to 1 if you have the header file. */ #undef HAVE_STDLIB_H /* Define to 1 if you have the header file. */ #undef HAVE_STRINGS_H /* Define to 1 if you have the header file. */ #undef HAVE_STRING_H /* Define to 1 if you have the header file. */ #undef HAVE_SYS_STAT_H /* Define to 1 if you have the header file. */ #undef HAVE_SYS_TYPES_H /* Define to 1 if you have the header file. */ #undef HAVE_UNISTD_H /* Name of package */ #undef PACKAGE /* Define to the address where bug reports for this package should be sent. */ #undef PACKAGE_BUGREPORT /* Define to the full name of this package. */ #undef PACKAGE_NAME /* Define to the full name and version of this package. */ #undef PACKAGE_STRING /* Define to the one symbol short name of this package. */ #undef PACKAGE_TARNAME /* Define to the version of this package. */ #undef PACKAGE_VERSION /* Define to 1 if you have the ANSI C header files. */ #undef STDC_HEADERS /* Version number of package */ #undef VERSION rapache-1.2.8/libapreq2/include/apreq_cookie.h0000644000175100017510000001571312706745114020607 0ustar ondrejondrej/* ** Copyright 2003-2005 The Apache Software Foundation ** ** Licensed under the Apache License, Version 2.0 (the "License"); ** you may not use this file except in compliance with the License. ** You may obtain a copy of the License at ** ** http://www.apache.org/licenses/LICENSE-2.0 ** ** Unless required by applicable law or agreed to in writing, software ** distributed under the License is distributed on an "AS IS" BASIS, ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ** See the License for the specific language governing permissions and ** limitations under the License. */ #ifndef APREQ_COOKIE_H #define APREQ_COOKIE_H #include "apreq.h" #include "apr_time.h" #ifdef __cplusplus extern "C" { #endif /** * @file apreq_cookie.h * @brief Cookies and Jars. * @ingroup libapreq2 * * apreq_cookie.h describes a common server-side API for request (incoming) * and response (outgoing) cookies. It aims towards compliance with the * standard cookie specifications listed below. * * @see http://wp.netscape.com/newsref/std/cookie_spec.html * @see http://www.ietf.org/rfc/rfc2109.txt * @see http://www.ietf.org/rfc/rfc2964.txt * @see http://www.ietf.org/rfc/rfc2965.txt * */ /** @todo convert this macro to an apreq_module_t method. * * Maximum length of a single Set-Cookie(2) header. */ #define APREQ_COOKIE_MAX_LENGTH 4096 /** @brief Cookie type, supporting both Netscape and RFC cookie specifications. */ typedef struct apreq_cookie_t { char *path; /**< Restricts url path */ char *domain; /**< Restricts server domain */ char *port; /**< Restricts server port */ char *comment; /**< RFC cookies may send a comment */ char *commentURL; /**< RFC cookies may place an URL here */ apr_time_t max_age; /**< total duration of cookie: -1 == session */ unsigned flags; /**< charsets, taint marks, app-specific bits */ const apreq_value_t v; /**< "raw" cookie value */ } apreq_cookie_t; /** Upgrades a jar's table values to apreq_cookie_t structs. */ static APR_INLINE apreq_cookie_t *apreq_value_to_cookie(const char *val) { union { const char *in; char *out; } deconst; deconst.in = val; return apreq_attr_to_type(apreq_cookie_t, v, apreq_attr_to_type(apreq_value_t, data, deconst.out)); } /**@return 1 if this is an RFC cookie, 0 if its a Netscape cookie. */ static APR_INLINE unsigned apreq_cookie_version(const apreq_cookie_t *c) { return APREQ_FLAGS_GET(c->flags, APREQ_COOKIE_VERSION); } /** Sets the cookie's protocol version. */ static APR_INLINE void apreq_cookie_version_set(apreq_cookie_t *c, unsigned v) { APREQ_FLAGS_SET(c->flags, APREQ_COOKIE_VERSION, v); } /** @return 1 if the secure flag is set, 0 otherwise. */ static APR_INLINE unsigned apreq_cookie_is_secure(const apreq_cookie_t *c) { return APREQ_FLAGS_GET(c->flags, APREQ_COOKIE_SECURE); } /** Sets the cookie's secure flag, meaning it only * comes back over an SSL-encrypted connction. */ static APR_INLINE void apreq_cookie_secure_on(apreq_cookie_t *c) { APREQ_FLAGS_ON(c->flags, APREQ_COOKIE_SECURE); } /** Turns off the cookie's secure flag. */ static APR_INLINE void apreq_cookie_secure_off(apreq_cookie_t *c) { APREQ_FLAGS_OFF(c->flags, APREQ_COOKIE_SECURE); } /** @return 1 if the taint flag is set, 0 otherwise. */ static APR_INLINE unsigned apreq_cookie_is_tainted(const apreq_cookie_t *c) { return APREQ_FLAGS_GET(c->flags, APREQ_TAINTED); } /** Sets the cookie's tainted flag. */ static APR_INLINE void apreq_cookie_tainted_on(apreq_cookie_t *c) { APREQ_FLAGS_ON(c->flags, APREQ_TAINTED); } /** Turns off the cookie's tainted flag. */ static APR_INLINE void apreq_cookie_tainted_off(apreq_cookie_t *c) { APREQ_FLAGS_OFF(c->flags, APREQ_TAINTED); } /** * Parse a cookie header and store the cookies in an apr_table_t. * * @param pool pool which allocates the cookies * @param jar table where parsed cookies are stored * @param header the header value * * @return APR_SUCCESS. * @return ::APREQ_ERROR_BADSEQ if an unparseable character sequence appears. * @return ::APREQ_ERROR_MISMATCH if an rfc-cookie attribute appears in a * netscape cookie header. * @return ::APR_ENOTIMPL if an unrecognized rfc-cookie attribute appears. * @return ::APREQ_ERROR_NOTOKEN if a required token was not present. * @return ::APREQ_ERROR_BADCHAR if an unexpected token was present. */ APREQ_DECLARE(apr_status_t) apreq_parse_cookie_header(apr_pool_t *pool, apr_table_t *jar, const char *header); /** * Returns a new cookie, made from the argument list. * * @param pool Pool which allocates the cookie. * @param name The cookie's name. * @param nlen Length of name. * @param value The cookie's value. * @param vlen Length of value. * * @return the new cookie */ APREQ_DECLARE(apreq_cookie_t *) apreq_cookie_make(apr_pool_t *pool, const char *name, const apr_size_t nlen, const char *value, const apr_size_t vlen); /** * Returns a string that represents the cookie as it would appear * in a valid "Set-Cookie*" header. * * @param c cookie. * @param p pool which allocates the returned string. * * @return header string. */ APREQ_DECLARE(char*) apreq_cookie_as_string(const apreq_cookie_t *c, apr_pool_t *p); /** * Same functionality as apreq_cookie_as_string. Stores the string * representation in buf, using up to len bytes in buf as storage. * The return value has the same semantics as that of apr_snprintf, * including the special behavior for a "len = 0" argument. * * @param c cookie. * @param buf storage location for the result. * @param len size of buf's storage area. * * @return size of resulting header string. */ APREQ_DECLARE(int) apreq_cookie_serialize(const apreq_cookie_t *c, char *buf, apr_size_t len); /** * Set the Cookie's expiration date. * * @param c The cookie. * @param time_str If NULL, the Cookie's expiration date is unset, * making it a session cookie. This means no "expires" or "max-age" * attribute will appear in the cookie's serialized form. If time_str * is not NULL, the expiration date will be reset to the offset (from now) * represented by time_str. The time_str should be in a format that * apreq_atoi64t() can understand, namely /[+-]?\\d+\\s*[YMDhms]/. * * @remarks Now time_str may also be a fixed date; see apr_date_parse_rfc() * for admissible formats. */ APREQ_DECLARE(void) apreq_cookie_expires(apreq_cookie_t *c, const char *time_str); #ifdef __cplusplus } #endif #endif /*APREQ_COOKIE_H*/ rapache-1.2.8/libapreq2/include/apreq_error.h0000644000175100017510000000554012706745114020464 0ustar ondrejondrej/* ** Copyright 2003-2005 The Apache Software Foundation ** ** Licensed under the Apache License, Version 2.0 (the "License"); ** you may not use this file except in compliance with the License. ** You may obtain a copy of the License at ** ** http://www.apache.org/licenses/LICENSE-2.0 ** ** Unless required by applicable law or agreed to in writing, software ** distributed under the License is distributed on an "AS IS" BASIS, ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ** See the License for the specific language governing permissions and ** limitations under the License. */ #ifndef APREQ_ERROR_H #define APREQ_ERROR_H #include "apr_errno.h" #include "apreq.h" #ifdef __cplusplus extern "C" { #endif /** * apreq's wrapper around apr_strerror(); * recognizes APREQ_ERROR_* status codes. */ APREQ_DECLARE(char *) apreq_strerror(apr_status_t s, char *buf, apr_size_t bufsize); /** * @file apreq_error.h * @brief Error status codes. * @ingroup libapreq2 * * Define the APREQ_ error codes. */ #ifndef APR_EBADARG #define APR_EBADARG APR_BADARG /* XXX: don't use APR_BADARG */ #endif /** Internal apreq error. */ #define APREQ_ERROR_GENERAL APR_OS_START_USERERR /** Attempted to perform unsafe action with tainted data. */ #define APREQ_ERROR_TAINTED (APREQ_ERROR_GENERAL + 1) /** Parsing interrupted. */ #define APREQ_ERROR_INTERRUPT (APREQ_ERROR_GENERAL + 2) /** Invalid input data. */ #define APREQ_ERROR_BADDATA (APREQ_ERROR_GENERAL + 10) /** Invalid character. */ #define APREQ_ERROR_BADCHAR (APREQ_ERROR_BADDATA + 1) /** Invalid byte sequence. */ #define APREQ_ERROR_BADSEQ (APREQ_ERROR_BADDATA + 2) /** Invalid attribute. */ #define APREQ_ERROR_BADATTR (APREQ_ERROR_BADDATA + 3) /** Invalid header. */ #define APREQ_ERROR_BADHEADER (APREQ_ERROR_BADDATA + 4) /** Invalid utf8 encoding. */ #define APREQ_ERROR_BADUTF8 (APREQ_ERROR_BADDATA + 5) /** Missing input data. */ #define APREQ_ERROR_NODATA (APREQ_ERROR_GENERAL + 20) /** Missing required token. */ #define APREQ_ERROR_NOTOKEN (APREQ_ERROR_NODATA + 1) /** Missing attribute. */ #define APREQ_ERROR_NOATTR (APREQ_ERROR_NODATA + 2) /** Missing header. */ #define APREQ_ERROR_NOHEADER (APREQ_ERROR_NODATA + 3) /** Missing parser. */ #define APREQ_ERROR_NOPARSER (APREQ_ERROR_NODATA + 4) /** Conflicting information. */ #define APREQ_ERROR_MISMATCH (APREQ_ERROR_GENERAL + 30) /** Exceeds configured maximum limit. */ #define APREQ_ERROR_OVERLIMIT (APREQ_ERROR_MISMATCH + 1) /** Below configured minimum limit. */ #define APREQ_ERROR_UNDERLIMIT (APREQ_ERROR_MISMATCH + 2) /** Setting already configured. */ #define APREQ_ERROR_NOTEMPTY (APREQ_ERROR_MISMATCH + 3) #ifdef __cplusplus } #endif #endif /* APREQ_ERROR_H */ rapache-1.2.8/libapreq2/include/apreq_module.h0000644000175100017510000003540512706745114020623 0ustar ondrejondrej/* ** Copyright 2003-2005 The Apache Software Foundation ** ** Licensed under the Apache License, Version 2.0 (the "License"); ** you may not use this file except in compliance with the License. ** You may obtain a copy of the License at ** ** http://www.apache.org/licenses/LICENSE-2.0 ** ** Unless required by applicable law or agreed to in writing, software ** distributed under the License is distributed on an "AS IS" BASIS, ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ** See the License for the specific language governing permissions and ** limitations under the License. */ #ifndef APREQ_MODULE_H #define APREQ_MODULE_H #include "apreq_cookie.h" #include "apreq_parser.h" #include "apreq_error.h" #ifdef __cplusplus extern "C" { #endif /** * @file apreq_module.h * @brief Module API * @ingroup libapreq2 */ /** * An apreq handle associated with a module. The structure * may have variable size, because the module may append its own data * structures after it. */ typedef struct apreq_handle_t { /** the apreq module which implements this handle */ const struct apreq_module_t *module; /** the pool which defines the lifetime of the parsed data */ apr_pool_t *pool; /** the allocator, which persists at least as long as the pool */ apr_bucket_alloc_t *bucket_alloc; } apreq_handle_t; /** * @brief Vtable describing the necessary environment functions. */ typedef struct apreq_module_t { /** name of this apreq module */ const char *name; /** magic number identifying the module and version */ apr_uint32_t magic_number; /** get a table with all cookies */ apr_status_t (*jar)(apreq_handle_t *, const apr_table_t **); /** get a table with all query string parameters */ apr_status_t (*args)(apreq_handle_t *, const apr_table_t **); /** get a table with all body parameters */ apr_status_t (*body)(apreq_handle_t *, const apr_table_t **); /** get a cookie by its name */ apreq_cookie_t *(*jar_get)(apreq_handle_t *, const char *); /** get a query string parameter by its name */ apreq_param_t *(*args_get)(apreq_handle_t *, const char *); /** get a body parameter by its name */ apreq_param_t *(*body_get)(apreq_handle_t *, const char *); /** gets the parser associated with the request body */ apr_status_t (*parser_get)(apreq_handle_t *, const apreq_parser_t **); /** manually set a parser for the request body */ apr_status_t (*parser_set)(apreq_handle_t *, apreq_parser_t *); /** add a hook function */ apr_status_t (*hook_add)(apreq_handle_t *, apreq_hook_t *); /** determine the maximum in-memory bytes a brigade may use */ apr_status_t (*brigade_limit_get)(apreq_handle_t *, apr_size_t *); /** set the maximum in-memory bytes a brigade may use */ apr_status_t (*brigade_limit_set)(apreq_handle_t *, apr_size_t); /** determine the maximum amount of data that will be fed into a parser */ apr_status_t (*read_limit_get)(apreq_handle_t *, apr_uint64_t *); /** set the maximum amount of data that will be fed into a parser */ apr_status_t (*read_limit_set)(apreq_handle_t *, apr_uint64_t); /** determine the directory used by the parser for temporary files */ apr_status_t (*temp_dir_get)(apreq_handle_t *, const char **); /** set the directory used by the parser for temporary files */ apr_status_t (*temp_dir_set)(apreq_handle_t *, const char *); } apreq_module_t; /** * Defines the module-specific status codes which * are commonly considered to be non-fatal. * * @param s status code returned by an apreq_module_t method. * * @return 1 if s is fatal, 0 otherwise. */ static APR_INLINE unsigned apreq_module_status_is_error(apr_status_t s) { switch (s) { case APR_SUCCESS: case APR_INCOMPLETE: case APR_EINIT: case APREQ_ERROR_NODATA: case APREQ_ERROR_NOPARSER: case APREQ_ERROR_NOHEADER: return 0; default: return 1; } } /** * Expose the parsed "cookie" header associated to this handle. * * @param req The request handle * @param t The resulting table, which will either be NULL or a * valid table object on return. * * @return APR_SUCCESS or a module-specific error status code. */ static APR_INLINE apr_status_t apreq_jar(apreq_handle_t *req, const apr_table_t **t) { return req->module->jar(req,t); } /** * Expose the parsed "query string" associated to this handle. * * @param req The request handle * @param t The resulting table, which will either be NULL or a * valid table object on return. * * @return APR_SUCCESS or a module-specific error status code. */ static APR_INLINE apr_status_t apreq_args(apreq_handle_t *req, const apr_table_t **t) { return req->module->args(req,t); } /** * Expose the parsed "request body" associated to this handle. * * @param req The request handle * @param t The resulting table, which will either be NULL or a * valid table object on return. * * @return APR_SUCCESS or a module-specific error status code. */ static APR_INLINE apr_status_t apreq_body(apreq_handle_t *req, const apr_table_t **t) { return req->module->body(req, t); } /** * Fetch the first cookie with the given name. * * @param req The request handle * @param name Case-insensitive cookie name. * * @return First matching cookie, or NULL if none match. */ static APR_INLINE apreq_cookie_t *apreq_jar_get(apreq_handle_t *req, const char *name) { return req->module->jar_get(req, name); } /** * Fetch the first query string param with the given name. * * @param req The request handle * @param name Case-insensitive param name. * * @return First matching param, or NULL if none match. */ static APR_INLINE apreq_param_t *apreq_args_get(apreq_handle_t *req, const char *name) { return req->module->args_get(req, name); } /** * Fetch the first body param with the given name. * * @param req The request handle * @param name Case-insensitive cookie name. * * @return First matching param, or NULL if none match. */ static APR_INLINE apreq_param_t *apreq_body_get(apreq_handle_t *req, const char *name) { return req->module->body_get(req, name); } /** * Fetch the active body parser. * * @param req The request handle * @param parser Points to the active parser on return. * * @return APR_SUCCESS or module-specific error. * */ static APR_INLINE apr_status_t apreq_parser_get(apreq_handle_t *req, const apreq_parser_t **parser) { return req->module->parser_get(req, parser); } /** * Set the body parser for this request. * * @param req The request handle * @param parser New parser to use. * * @return APR_SUCCESS or module-specific error. */ static APR_INLINE apr_status_t apreq_parser_set(apreq_handle_t *req, apreq_parser_t *parser) { return req->module->parser_set(req, parser); } /** * Add a parser hook for this request. * * @param req The request handle * @param hook Hook to add. * * @return APR_SUCCESS or module-specific error. */ static APR_INLINE apr_status_t apreq_hook_add(apreq_handle_t *req, apreq_hook_t *hook) { return req->module->hook_add(req, hook); } /** * Set the active brigade limit. * * @param req The handle. * @param bytes New limit to use. * * @return APR_SUCCESS or module-specific error. * */ static APR_INLINE apr_status_t apreq_brigade_limit_set(apreq_handle_t *req, apr_size_t bytes) { return req->module->brigade_limit_set(req, bytes); } /** * Get the active brigade limit. * * @param req The handle. * @param bytes Pointer to resulting (current) limit. * * @return APR_SUCCESS or a module-specific error, * which may leave bytes undefined. */ static APR_INLINE apr_status_t apreq_brigade_limit_get(apreq_handle_t *req, apr_size_t *bytes) { return req->module->brigade_limit_get(req, bytes); } /** * Set the active read limit. * * @param req The handle. * @param bytes New limit to use. * * @return APR_SUCCESS or a module-specific error. * */ static APR_INLINE apr_status_t apreq_read_limit_set(apreq_handle_t *req, apr_uint64_t bytes) { return req->module->read_limit_set(req, bytes); } /** * Get the active read limit. * * @param req The request handle. * @param bytes Pointer to resulting (current) limit. * * @return APR_SUCCESS or a module-specific error, * which may leave bytes undefined. */ static APR_INLINE apr_status_t apreq_read_limit_get(apreq_handle_t *req, apr_uint64_t *bytes) { return req->module->read_limit_get(req, bytes); } /** * Set the active temp directory. * * @param req The handle. * @param path New path to use; may be NULL. * * @return APR_SUCCESS or a module-specific error . */ static APR_INLINE apr_status_t apreq_temp_dir_set(apreq_handle_t *req, const char *path) { return req->module->temp_dir_set(req, path); } /** * Get the active temp directory. * * @param req The handle. * @param path Resulting path to temp dir. * * @return APR_SUCCESS implies path is valid, but may also be NULL. * Any other return value is module-specific, and may leave * path undefined. */ static APR_INLINE apr_status_t apreq_temp_dir_get(apreq_handle_t *req, const char **path) { return req->module->temp_dir_get(req, path); } /** * Convenience macro for defining a module by mapping * a function prefix to an associated apreq_module_t structure. * * @param pre Prefix to define new environment. All attributes of * the apreq_env_module_t struct are defined with this as their * prefix. The generated struct is named by appending "_module" to * the prefix. * @param mmn Magic number (i.e. version number) of this environment. */ #define APREQ_MODULE(pre, mmn) const apreq_module_t \ pre##_module = { #pre, mmn, \ pre##_jar, pre##_args, pre##_body, \ pre##_jar_get, pre##_args_get, pre##_body_get, \ pre##_parser_get, pre##_parser_set, pre##_hook_add, \ pre##_brigade_limit_get, pre##_brigade_limit_set, \ pre##_read_limit_get, pre##_read_limit_set, \ pre##_temp_dir_get, pre##_temp_dir_set, \ } /** * Create an apreq handle which is suitable for a CGI program. It * reads input from stdin and writes output to stdout. * * @param pool Pool associated to this handle. * * @return New handle; can only be NULL if the pool allocation failed. * * @remarks The handle gets cached in the pool's userdata, so subsequent * calls will retrieve the original cached handle. */ APREQ_DECLARE(apreq_handle_t*) apreq_handle_cgi(apr_pool_t *pool); /** * Create a custom apreq handle which knows only some static * values. Useful if you want to test the parser code or if you have * got data from a custom source (neither Apache 2 nor CGI). * * @param pool allocates the parse data, * @param query_string parsed into args table * @param cookie value of the request "Cookie" header * @param parser parses the request body * @param read_limit maximum bytes to read from the body * @param in brigade containing the request body * * @return new handle; can only be NULL if the pool allocation failed. */ APREQ_DECLARE(apreq_handle_t*) apreq_handle_custom(apr_pool_t *pool, const char *query_string, const char *cookie, apreq_parser_t *parser, apr_uint64_t read_limit, apr_bucket_brigade *in); /** * Add the cookie to the outgoing "Set-Cookie" headers. * * @param c The cookie. * @param req The request handle which set the outgoing header. * * @return APR_SUCCESS or error. */ APREQ_DECLARE(apr_status_t) apreq_cookie_bake(const apreq_cookie_t *c, apreq_handle_t *req); /** * Add the cookie to the outgoing "Set-Cookie2" headers. * * @param c cookie * @param req request handle * * @return APR_SUCCESS or error. */ APREQ_DECLARE(apr_status_t) apreq_cookie_bake2(const apreq_cookie_t *c, apreq_handle_t *req); /** * Looks for the presence of a "Cookie2" header to determine whether * or not the current User-Agent responsible for this request supports * rfc2965. * * @param req the apreq request handle * * @return ::APREQ_COOKIE_VERSION_RFC if rfc2965 is supported * by the user-agent, ::APREQ_COOKIE_VERSION_NETSCAPE otherwise. */ APREQ_DECLARE(unsigned)apreq_ua_cookie_version(apreq_handle_t *req); /** * Find the first query string parameter or body parameter with the * specified name. The match is case-insensitive. * * @param req request handle. * @param key desired parameter name * * @return The first matching parameter (with args searched first) or NULL. */ APREQ_DECLARE(apreq_param_t *)apreq_param(apreq_handle_t *req, const char *key); /** * Find the first cookie with the specified name. * The match is case-insensitive. * * @param req request handle. * @param key desired cookie name * * @return The first matching parameter (with args searched first) or NULL. */ #define apreq_cookie(req, name) apreq_jar_get(req, name) /** * Returns a table containing key-value pairs for the full request * (args + body). * * @param req request handle * @param p allocates the returned table. * * @return table representing all available params; is never NULL. */ APREQ_DECLARE(apr_table_t *) apreq_params(apreq_handle_t *req, apr_pool_t *p); /** * Returns a table containing all request cookies. * * @param req the apreq request handle * @param p Allocates the returned table. */ APREQ_DECLARE(apr_table_t *)apreq_cookies(apreq_handle_t *req, apr_pool_t *p); /** * Force a complete parse of everything. * * @param req The request handle * * @return APR_SUCCESS on an error-free parse of the request data. * Any other status code indicates a potential problem somewhere. */ static APR_INLINE apr_status_t apreq_parse(apreq_handle_t *req) { const apr_table_t *dummy; apr_status_t jar_status, args_status, body_status; jar_status = apreq_jar(req, &dummy); args_status = apreq_args(req, &dummy); body_status = apreq_body(req, &dummy); /* XXX: punt to APREQ_ERROR_GENERAL; need to improve this * for valid requests where certain data/headers are * unavailable. */ if (jar_status || args_status || body_status) return APREQ_ERROR_GENERAL; return APR_SUCCESS; } #ifdef __cplusplus } #endif #endif /* APREQ_MODULE_H */ rapache-1.2.8/libapreq2/include/apreq_param.h0000644000175100017510000001637512706745114020443 0ustar ondrejondrej/* ** Copyright 2003-2005 The Apache Software Foundation ** ** Licensed under the Apache License, Version 2.0 (the "License"); ** you may not use this file except in compliance with the License. ** You may obtain a copy of the License at ** ** http://www.apache.org/licenses/LICENSE-2.0 ** ** Unless required by applicable law or agreed to in writing, software ** distributed under the License is distributed on an "AS IS" BASIS, ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ** See the License for the specific language governing permissions and ** limitations under the License. */ #ifndef APREQ_PARAM_H #define APREQ_PARAM_H #include "apreq.h" #include "apr_buckets.h" #ifdef __cplusplus extern "C" { #endif /** * @file apreq_param.h * @brief Request parsing and parameter API * @ingroup libapreq2 */ /** Common data structure for params and file uploads */ typedef struct apreq_param_t { apr_table_t *info; /**< header table associated with the param */ apr_bucket_brigade *upload; /**< brigade used to spool upload files */ unsigned flags; /**< charsets, taint marks, app-specific bits */ const apreq_value_t v; /**< underlying name/value info */ } apreq_param_t; /** @return 1 if the taint flag is set, 0 otherwise. */ static APR_INLINE unsigned apreq_param_is_tainted(const apreq_param_t *p) { return APREQ_FLAGS_GET(p->flags, APREQ_TAINTED); } /** Sets the tainted flag. */ static APR_INLINE void apreq_param_tainted_on(apreq_param_t *p) { APREQ_FLAGS_ON(p->flags, APREQ_TAINTED); } /** Turns off the taint flag. */ static APR_INLINE void apreq_param_tainted_off(apreq_param_t *p) { APREQ_FLAGS_OFF(p->flags, APREQ_TAINTED); } /** Sets the character encoding for this parameter. */ static APR_INLINE apreq_charset_t apreq_param_charset_set(apreq_param_t *p, unsigned char c) { unsigned char old = APREQ_FLAGS_GET(p->flags, APREQ_CHARSET); APREQ_FLAGS_SET(p->flags, APREQ_CHARSET, c); return old; } /** Gets the character encoding for this parameter. */ static APR_INLINE apreq_charset_t apreq_param_charset_get(apreq_param_t *p) { return APREQ_FLAGS_GET(p->flags, APREQ_CHARSET); } /** Upgrades args and body table values to apreq_param_t structs. */ static APR_INLINE apreq_param_t *apreq_value_to_param(const char *val) { union { const char *in; char *out; } deconst; deconst.in = val; return apreq_attr_to_type(apreq_param_t, v, apreq_attr_to_type(apreq_value_t, data, deconst.out)); } /** creates a param from name/value information */ APREQ_DECLARE(apreq_param_t *) apreq_param_make(apr_pool_t *p, const char *name, const apr_size_t nlen, const char *val, const apr_size_t vlen); /** * Url-decodes a name=value pair into a param. * * @param param points to the decoded parameter on success * @param pool Pool from which the param is allocated. * @param word Start of the name=value pair. * @param nlen Length of urlencoded name. * @param vlen Length of urlencoded value. * * @return APR_SUCCESS + apreq_charset_t (<=APREQ_CHARSET_UTF8) on success. * @return ::APREQ_ERROR_BADSEQ or ::APREQ_ERROR_BADCHAR on malformed input. * * @remarks Unless vlen == 0, this function assumes there is * exactly one character ('=') which separates the pair. * */ APREQ_DECLARE(apr_status_t) apreq_param_decode(apreq_param_t **param, apr_pool_t *pool, const char *word, apr_size_t nlen, apr_size_t vlen); /** * Url-encodes the param into a name-value pair. * @param pool Pool which allocates the returned string. * @param param Param to encode. * @return name-value pair representing the param. */ APREQ_DECLARE(char *) apreq_param_encode(apr_pool_t *pool, const apreq_param_t *param); /** * Parse a url-encoded string into a param table. * @param pool pool used to allocate the param data. * @param t table to which the params are added. * @param qs Query string to url-decode. * @return APR_SUCCESS if successful, error otherwise. * @remark This function uses [&;] as the set of tokens * to delineate words, and will treat a word w/o '=' * as a name-value pair with value-length = 0. * */ APREQ_DECLARE(apr_status_t) apreq_parse_query_string(apr_pool_t *pool, apr_table_t *t, const char *qs); /** * Returns an array of parameters (apreq_param_t *) matching the given key. * The key is case-insensitive. * @param p Allocates the returned array. * @param t the parameter table returned by apreq_args(), apreq_body() * or apreq_params() * @param key Null-terminated search key, case insensitive. * key==NULL fetches all parameters. * @return an array of apreq_param_t* (pointers) * @remark Also parses the request if necessary. */ APREQ_DECLARE(apr_array_header_t *) apreq_params_as_array(apr_pool_t *p, const apr_table_t *t, const char *key); /** * Returns a ", " -joined string containing all parameters * for the requested key, an empty string if none are found. * The key is case-insensitive. * * @param p Allocates the return string. * @param t the parameter table returned by apreq_args(), apreq_body() * or apreq_params() * @param key Null-terminated parameter name, case insensitive. * key==NULL fetches all values. * @param mode Join type- see apreq_join(). * @return the joined string or NULL on error * @remark Also parses the request if necessary. */ APREQ_DECLARE(const char *) apreq_params_as_string(apr_pool_t *p, const apr_table_t *t, const char *key, apreq_join_t mode); /** * Returns a table of all params in req->body with non-NULL upload brigades. * @param body parameter table returned by apreq_body() or apreq_params() * @param pool Pool which allocates the table struct. * @return Upload table. * @remark Will parse the request if necessary. */ APREQ_DECLARE(const apr_table_t *) apreq_uploads(const apr_table_t *body, apr_pool_t *pool); /** * Returns the first param in req->body which has both param->v.name * matching key (case insensitive) and param->upload != NULL. * @param body parameter table returned by apreq_body() or apreq_params() * @param name Parameter name. key == NULL returns first upload. * @return Corresponding upload, NULL if none found. * @remark Will parse the request as necessary. */ APREQ_DECLARE(const apreq_param_t *) apreq_upload(const apr_table_t *body, const char *name); #ifdef __cplusplus } #endif #endif /* APREQ_PARAM_H */ rapache-1.2.8/libapreq2/include/apreq_parser.h0000644000175100017510000002243512706745114020631 0ustar ondrejondrej/* ** Copyright 2003-2005 The Apache Software Foundation ** ** Licensed under the Apache License, Version 2.0 (the "License"); ** you may not use this file except in compliance with the License. ** You may obtain a copy of the License at ** ** http://www.apache.org/licenses/LICENSE-2.0 ** ** Unless required by applicable law or agreed to in writing, software ** distributed under the License is distributed on an "AS IS" BASIS, ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ** See the License for the specific language governing permissions and ** limitations under the License. */ #ifndef APREQ_PARSERS_H #define APREQ_PARSERS_H /* These structs are defined below */ #include "apreq_param.h" #ifdef __cplusplus extern "C" { #endif /* __cplusplus */ /** * @file apreq_parser.h * @brief Request body parser API * @ingroup libapreq2 */ /** * A hook is called by the parser whenever data arrives in a file * upload parameter of the request body. You may associate any number * of hooks with a parser instance with apreq_parser_add_hook(). */ typedef struct apreq_hook_t apreq_hook_t; /** * A request body parser instance. */ typedef struct apreq_parser_t apreq_parser_t; /** Parser arguments. */ #define APREQ_PARSER_ARGS apreq_parser_t *parser, \ apr_table_t *t, \ apr_bucket_brigade *bb /** Hook arguments */ #define APREQ_HOOK_ARGS apreq_hook_t *hook, \ apreq_param_t *param, \ apr_bucket_brigade *bb /** * The callback function implementing a request body parser. */ typedef apr_status_t (*apreq_parser_function_t)(APREQ_PARSER_ARGS); /** * The callback function of a hook. See apreq_hook_t. */ typedef apr_status_t (*apreq_hook_function_t)(APREQ_HOOK_ARGS); /** * Declares a API parser. */ #define APREQ_DECLARE_PARSER(f) APREQ_DECLARE_NONSTD(apr_status_t) \ (f) (APREQ_PARSER_ARGS) /** * Declares an API hook. */ #define APREQ_DECLARE_HOOK(f) APREQ_DECLARE_NONSTD(apr_status_t) \ (f) (APREQ_HOOK_ARGS) /** * A hook is called by the parser whenever data arrives in a file * upload parameter of the request body. You may associate any number * of hooks with a parser instance with apreq_parser_add_hook(). */ struct apreq_hook_t { apreq_hook_function_t hook; /**< the hook function */ apreq_hook_t *next; /**< next item in the linked list */ apr_pool_t *pool; /**< pool which allocated this hook */ void *ctx; /**< a user defined pointer passed to the hook function */ }; /** * A request body parser instance. */ struct apreq_parser_t { /** the function which parses chunks of body data */ apreq_parser_function_t parser; /** the Content-Type request header */ const char *content_type; /** a pool used by the parser */ apr_pool_t *pool; /** bucket allocator used to create bucket brigades */ apr_bucket_alloc_t *bucket_alloc; /** the maximum in-memory bytes a brigade may use */ apr_size_t brigade_limit; /** the directory used by the parser for temporary files */ const char *temp_dir; /** linked list of hooks */ apreq_hook_t *hook; /** internal context pointer used by the parser function */ void *ctx; }; /** * Parse the incoming brigade into a table. Parsers normally * consume all the buckets of the brigade during parsing. However * parsers may leave "rejected" data in the brigade, even during a * successful parse, so callers may need to clean up the brigade * themselves (in particular, rejected buckets should not be * passed back to the parser again). * @remark bb == NULL is valid: the parser should return its * public status: APR_INCOMPLETE, APR_SUCCESS, or an error code. */ static APR_INLINE apr_status_t apreq_parser_run(struct apreq_parser_t *psr, apr_table_t *t, apr_bucket_brigade *bb) { return psr->parser(psr, t, bb); } /** * Run the hook with the current parameter and the incoming * bucket brigade. The hook may modify the brigade if necessary. * Once all hooks have completed, the contents of the brigade will * be added to the parameter's bb attribute. * @return APR_SUCCESS on success. All other values represent errors. */ static APR_INLINE apr_status_t apreq_hook_run(struct apreq_hook_t *h, apreq_param_t *param, apr_bucket_brigade *bb) { return h->hook(h, param, bb); } /** * RFC 822 Header parser. It will reject all data * after the first CRLF CRLF sequence (an empty line). * See apreq_parser_run() for more info on rejected data. */ APREQ_DECLARE_PARSER(apreq_parse_headers); /** * RFC 2396 application/x-www-form-urlencoded parser. */ APREQ_DECLARE_PARSER(apreq_parse_urlencoded); /** * RFC 2388 multipart/form-data (and XForms 1.0 multipart/related) * parser. It will reject any buckets representing preamble and * postamble text (this is normal behavior, not an error condition). * See apreq_parser_run() for more info on rejected data. */ APREQ_DECLARE_PARSER(apreq_parse_multipart); /** * Generic parser. No table entries will be added to * the req->body table by this parser. The parser creates * a dummy apreq_param_t to pass to any configured hooks. If * no hooks are configured, the dummy param's bb slot will * contain a copy of the request body. It can be retrieved * by casting the parser's ctx pointer to (apreq_param_t **). */ APREQ_DECLARE_PARSER(apreq_parse_generic); /** * apr_xml_parser hook. It will parse until EOS appears. * The parsed document isn't available until parsing has * completed successfully. The hook's ctx pointer may * be cast as (apr_xml_doc **) to retrieve the * parsed document. */ APREQ_DECLARE_HOOK(apreq_hook_apr_xml_parser); /** * Construct a parser. * * @param pool Pool used to allocate the parser. * @param ba bucket allocator used to create bucket brigades * @param content_type Content-type that this parser can deal with. * @param pfn The parser function. * @param brigade_limit the maximum in-memory bytes a brigade may use * @param temp_dir the directory used by the parser for temporary files * @param hook Hooks to asssociate this parser with. * @param ctx Parser's internal scratch pad. * @return New parser. */ APREQ_DECLARE(apreq_parser_t *) apreq_parser_make(apr_pool_t *pool, apr_bucket_alloc_t *ba, const char *content_type, apreq_parser_function_t pfn, apr_size_t brigade_limit, const char *temp_dir, apreq_hook_t *hook, void *ctx); /** * Construct a hook. * * @param pool used to allocate the hook. * @param hook The hook function. * @param next List of other hooks for this hook to call on. * @param ctx Hook's internal scratch pad. * @return New hook. */ APREQ_DECLARE(apreq_hook_t *) apreq_hook_make(apr_pool_t *pool, apreq_hook_function_t hook, apreq_hook_t *next, void *ctx); /** * Add a new hook to the end of the parser's hook list. * * @param p Parser. * @param h Hook to append. */ APREQ_DECLARE(apr_status_t) apreq_parser_add_hook(apreq_parser_t *p, apreq_hook_t *h); /** * Fetch the default parser function associated with the given MIME type. * @param enctype The desired enctype (can also be a full "Content-Type" * header). * @return The parser function, or NULL if the enctype is unrecognized. */ APREQ_DECLARE(apreq_parser_function_t)apreq_parser(const char *enctype); /** * Register a new parsing function with a MIME enctype. * Registered parsers are added to apreq_parser()'s * internal lookup table. * * @param enctype The MIME type. * @param pfn The function to use during parsing. Setting * parser == NULL will remove an existing parser. * * @return APR_SUCCESS or error. */ APREQ_DECLARE(apr_status_t) apreq_register_parser(const char *enctype, apreq_parser_function_t pfn); /** * Returns APREQ_ERROR_GENERAL. Effectively disables mfd parser * if a file-upload field is present. * */ APREQ_DECLARE_HOOK(apreq_hook_disable_uploads); /** * Calls apr_brigade_cleanup on the incoming brigade * after passing the brigade to any subsequent hooks. */ APREQ_DECLARE_HOOK(apreq_hook_discard_brigade); /** * Special purpose utility for locating a parameter * during parsing. The hook's ctx shoud be initialized * to a const char *, which is a pointer to the desired * param name. The hook's ctx will be reassigned to the * first param found. * * @remarks When used, this should always be the first hook * invoked, so add it manually as parser->hook instead of * using apreq_parser_add_hook. */ APREQ_DECLARE_HOOK(apreq_hook_find_param); #ifdef __cplusplus } #endif #endif /* APREQ_PARSERS_H */ rapache-1.2.8/libapreq2/include/apreq_util.h0000644000175100017510000003316012706745114020307 0ustar ondrejondrej/* ** Copyright 2003-2005 The Apache Software Foundation ** ** Licensed under the Apache License, Version 2.0 (the "License"); ** you may not use this file except in compliance with the License. ** You may obtain a copy of the License at ** ** http://www.apache.org/licenses/LICENSE-2.0 ** ** Unless required by applicable law or agreed to in writing, software ** distributed under the License is distributed on an "AS IS" BASIS, ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ** See the License for the specific language governing permissions and ** limitations under the License. */ #ifndef APREQ_UTIL_H #define APREQ_UTIL_H #include "apr_file_io.h" #include "apr_buckets.h" #include "apreq.h" #ifdef __cplusplus extern "C" { #endif /** * This header contains useful functions for creating new * parsers, hooks or modules. It includes * * - string <-> array converters * - substring search functions * - simple encoders & decoders for urlencoded strings * - simple time, date, & file-size converters * @file apreq_util.h * @brief Utility functions for apreq. * @ingroup libapreq2 */ /** * Join an array of values. The result is an empty string if there are * no values. * * @param p Pool to allocate return value. * @param sep String that is inserted between the joined values. * @param arr Array of apreq_value_t entries. * @param mode Join type- see apreq_join_t. * * @return Joined string, or NULL on error */ APREQ_DECLARE(char *) apreq_join(apr_pool_t *p, const char *sep, const apr_array_header_t *arr, apreq_join_t mode); /** * Returns offset of match string's location, or -1 if no match is found. * * @param hay Location of bytes to scan. * @param hlen Number of bytes available for scanning. * @param ndl Search string * @param nlen Length of search string. * @param type Match type. * * @return Offset of match string, or -1 if no match is found. * */ APREQ_DECLARE(apr_ssize_t) apreq_index(const char* hay, apr_size_t hlen, const char* ndl, apr_size_t nlen, const apreq_match_t type); /** * Places a quoted copy of src into dest. Embedded quotes are escaped with a * backslash ('\'). * * @param dest Location of quoted copy. Must be large enough to hold the copy * and trailing null byte. * @param src Original string. * @param slen Length of original string. * @param dest Destination string. * * @return length of quoted copy in dest. */ APREQ_DECLARE(apr_size_t) apreq_quote(char *dest, const char *src, const apr_size_t slen); /** * * Same as apreq_quote() except when src begins and ends in quote marks. In * that case it assumes src is quoted correctly, and just copies src to dest. * * @param dest Location of quoted copy. Must be large enough to hold the copy * and trailing null byte. * @param src Original string. * @param slen Length of original string. * @param dest Destination string. * * @return length of quoted copy in dest. */ APREQ_DECLARE(apr_size_t) apreq_quote_once(char *dest, const char *src, const apr_size_t slen); /** * Url-encodes a string. * * @param dest Location of url-encoded result string. Caller must ensure it * is large enough to hold the encoded string and trailing '\\0'. * @param src Original string. * @param slen Length of original string. * * @return length of url-encoded string in dest; does not exceed 3 * slen. */ APREQ_DECLARE(apr_size_t) apreq_encode(char *dest, const char *src, const apr_size_t slen); /** * Convert a string from cp1252 to utf8. Caller must ensure it is large enough * to hold the encoded string and trailing '\\0'. * * @param dest Location of utf8-encoded result string. Caller must ensure it * is large enough to hold the encoded string and trailing '\\0'. * @param src Original string. * @param slen Length of original string. * * @return length of utf8-encoded string in dest; does not exceed 3 * slen. */ APREQ_DECLARE(apr_size_t) apreq_cp1252_to_utf8(char *dest, const char *src, apr_size_t slen); /** * Url-decodes a string. * * @param dest Location of url-encoded result string. Caller must ensure dest is * large enough to hold the encoded string and trailing null character. * @param dlen points to resultant length of url-decoded string in dest * @param src Original string. * @param slen Length of original string. * * @return APR_SUCCESS + apreq_charset_t (<=APREQ_CHARSET_UTF8) on success. * @return APR_INCOMPLETE + apreq_charset_t (<=APREQ_CHARSET_UTF8) if the string * ends in the middle of an escape sequence. * @return ::APREQ_ERROR_BADSEQ or ::APREQ_ERROR_BADCHAR on malformed input. * * @remarks In the non-success case, dlen will be set to include * the last succesfully decoded value. This function decodes * \%uXXXX into a utf8 (wide) character, following ECMA-262 * (the Javascript spec) Section B.2.1. */ APREQ_DECLARE(apr_status_t) apreq_decode(char *dest, apr_size_t *dlen, const char *src, apr_size_t slen); /** * Url-decodes an iovec array. * * @param dest Location of url-encoded result string. Caller must ensure dest is * large enough to hold the encoded string and trailing null character. * @param dlen Resultant length of dest. * @param v Array of iovecs that represent the source string * @param nelts Number of iovecs in the array. * * @return APR_SUCCESS + apreq_charset_t (<=APREQ_CHARSET_UTF8) on success. * @return APR_INCOMPLETE + apreq_charset_t (<=APREQ_CHARSET_UTF8) if the iovec * ends in the middle of an escape sequence. * @return ::APREQ_ERROR_BADSEQ or ::APREQ_ERROR_BADCHAR on malformed input. * * @remarks In the non-APR_SUCCESS case, dlen will be set to include * the last succesfully decoded value. This function decodes * \%uXXXX into a utf8 (wide) character, following ECMA-262 * (the Javascript spec) Section B.2.1. */ APREQ_DECLARE(apr_status_t) apreq_decodev(char *dest, apr_size_t *dlen, struct iovec *v, int nelts); /** * Returns an url-encoded copy of a string. * * @param p Pool used to allocate the return value. * @param src Original string. * @param slen Length of original string. * * @return The url-encoded string. * * @remarks Use this function insead of apreq_encode if its * caller might otherwise overflow dest. */ static APR_INLINE char *apreq_escape(apr_pool_t *p, const char *src, const apr_size_t slen) { char *rv; if (src == NULL) return NULL; rv = apr_palloc(p, 3 * slen + 1); apreq_encode(rv, src, slen); return rv; } /** * An \e in-situ url-decoder. * * @param str The string to decode * * @return Length of decoded string, or < 0 on error. */ static APR_INLINE apr_ssize_t apreq_unescape(char *str) { apr_size_t len; apr_status_t rv = apreq_decode(str, &len, str, strlen(str)); if (rv == APR_SUCCESS) return (apr_ssize_t)len; else return -1; } /** * Converts file sizes (KMG) to bytes * * @param s file size matching m/^\\d+[KMG]b?$/i * * @return 64-bit integer representation of s. * * @todo What happens when s is malformed? Should this return * an unsigned value instead? */ APREQ_DECLARE(apr_int64_t) apreq_atoi64f(const char *s); /** * Converts time strings (YMDhms) to seconds * * @param s time string matching m/^\\+?\\d+[YMDhms]$/ * * @return 64-bit integer representation of s as seconds. * * @todo What happens when s is malformed? Should this return * an unsigned value instead? */ APREQ_DECLARE(apr_int64_t) apreq_atoi64t(const char *s); /** * Writes brigade to a file. * * @param f File that gets the brigade. * @param wlen On a successful return, wlen holds the length of * the brigade, which is the amount of data written to * the file. * @param bb Bucket brigade. * * @return APR_SUCCESS. * @return Error status code from either an unsuccessful apr_bucket_read(), * or a failed apr_file_writev(). * * @remarks In the future, this function may do something * intelligent with file buckets. */ APREQ_DECLARE(apr_status_t) apreq_brigade_fwrite(apr_file_t *f, apr_off_t *wlen, apr_bucket_brigade *bb); /** * Makes a temporary file. * * @param fp Points to the temporary apr_file_t on success. * @param pool Pool to associate with the temp file. When the * pool is destroyed, the temp file will be closed * and deleted. * @param path The base directory which will contain the temp file. * If param == NULL, the directory will be selected via * tempnam(). See the tempnam manpage for details. * * @return APR_SUCCESS. * @return Error status code from unsuccessful apr_filepath_merge(), * or a failed apr_file_mktemp(). */ APREQ_DECLARE(apr_status_t) apreq_file_mktemp(apr_file_t **fp, apr_pool_t *pool, const char *path); /** * Set aside all buckets in the brigade. * * @param bb Brigade. * @param p Setaside buckets into this pool. * @return APR_SUCCESS. * @return Error status code from an unsuccessful apr_bucket_setaside(). */ static APR_INLINE apr_status_t apreq_brigade_setaside(apr_bucket_brigade *bb, apr_pool_t *p) { apr_bucket *e; for (e = APR_BRIGADE_FIRST(bb); e != APR_BRIGADE_SENTINEL(bb); e = APR_BUCKET_NEXT(e)) { apr_status_t rv = apr_bucket_setaside(e, p); if (rv != APR_SUCCESS) return rv; } return APR_SUCCESS; } /** * Copy a brigade. * * @param d (destination) Copied buckets are appended to this brigade. * @param s (source) Brigade to copy from. * * @return APR_SUCCESS. * @return Error status code from an unsuccessful apr_bucket_copy(). * * @remarks s == d produces Undefined Behavior. */ static APR_INLINE apr_status_t apreq_brigade_copy(apr_bucket_brigade *d, apr_bucket_brigade *s) { apr_bucket *e; for (e = APR_BRIGADE_FIRST(s); e != APR_BRIGADE_SENTINEL(s); e = APR_BUCKET_NEXT(e)) { apr_bucket *c; apr_status_t rv = apr_bucket_copy(e, &c); if (rv != APR_SUCCESS) return rv; APR_BRIGADE_INSERT_TAIL(d, c); } return APR_SUCCESS; } /** * Move the front of a brigade. * * @param d (destination) Append buckets to this brigade. * @param s (source) Brigade to take buckets from. * @param e First bucket of s after the move. All buckets * before e are appended to d. * * @remarks This moves all buckets when e == APR_BRIGADE_SENTINEL(s). */ static APR_INLINE void apreq_brigade_move(apr_bucket_brigade *d, apr_bucket_brigade *s, apr_bucket *e) { apr_bucket *f; if (e != APR_BRIGADE_SENTINEL(s)) { f = APR_RING_FIRST(&s->list); APR_RING_UNSPLICE(f, e, link); APR_RING_SPLICE_HEAD(&d->list, f, e, apr_bucket, link); } else { APR_BRIGADE_CONCAT(d, s); } } /** * Search a header string for the value of a particular named attribute. * * @param hdr Header string to scan. * @param name Name of attribute to search for. * @param nlen Length of name. * @param val Location of (first) matching value. * @param vlen Length of matching value. * * @return APR_SUCCESS. * @return ::APREQ_ERROR_NOATTR if the attribute is not found. * @return ::APREQ_ERROR_BADSEQ if an unpaired quote mark was detected. */ APREQ_DECLARE(apr_status_t) apreq_header_attribute(const char *hdr, const char *name, const apr_size_t nlen, const char **val, apr_size_t *vlen); /** * Concatenates the brigades, spooling large brigades into * a tempfile (APREQ_SPOOL) bucket. * * @param pool Pool for creating a tempfile bucket. * @param temp_dir Directory for tempfile creation. * @param brigade_limit If out's length would exceed this value, * the appended buckets get written to a tempfile. * @param out Resulting brigade. * @param in Brigade to append. * * @return APR_SUCCESS. * @return Error status code resulting from either apr_brigade_length(), * apreq_file_mktemp(), apreq_brigade_fwrite(), or apr_file_seek(). * * @todo Flesh out these error codes, making them as explicit as possible. */ APREQ_DECLARE(apr_status_t) apreq_brigade_concat(apr_pool_t *pool, const char *temp_dir, apr_size_t brigade_limit, apr_bucket_brigade *out, apr_bucket_brigade *in); /** * Determines the spool file used by the brigade. Returns NULL if the * brigade is not spooled in a file (does not use an APREQ_SPOOL * bucket). * * @param bb the bucket brigade * @return the spool file, or NULL. */ APREQ_DECLARE(apr_file_t *)apreq_brigade_spoolfile(apr_bucket_brigade *bb); #ifdef __cplusplus } #endif #endif /* APREQ_UTIL_H */ rapache-1.2.8/libapreq2/include/apreq_version.h0000644000175100017510000000574612706745114021030 0ustar ondrejondrej/* ** Copyright 2003-2005 The Apache Software Foundation ** ** Licensed under the Apache License, Version 2.0 (the "License"); ** you may not use this file except in compliance with the License. ** You may obtain a copy of the License at ** ** http://www.apache.org/licenses/LICENSE-2.0 ** ** Unless required by applicable law or agreed to in writing, software ** distributed under the License is distributed on an "AS IS" BASIS, ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ** See the License for the specific language governing permissions and ** limitations under the License. */ #ifndef APREQ_VERSION_H #define APREQ_VERSION_H #ifdef __cplusplus extern "C" { #endif #include "apr_version.h" #include "apreq.h" /** * @file apreq_version.h * @brief Versioning API for libapreq * @ingroup libapreq2 * * There are several different mechanisms for accessing the version. There * is a string form, and a set of numbers; in addition, there are constants * which can be compiled into your application, and you can query the library * being used for its actual version. * * Note that it is possible for an application to detect that it has been * compiled against a different version of libapreq by use of the compile-time * constants and the use of the run-time query function. * * libapreq version numbering follows the guidelines specified in: * * http://apr.apache.org/versioning.html */ /* The numeric compile-time version constants. These constants are the * authoritative version numbers for libapreq. */ /** major version * Major API changes that could cause compatibility problems for older * programs such as structure size changes. No binary compatibility is * possible across a change in the major version. */ #define APREQ_MAJOR_VERSION 2 /** * Minor API changes that do not cause binary compatibility problems. * Should be reset to 0 when upgrading APREQ_MAJOR_VERSION */ #define APREQ_MINOR_VERSION 1 /** patch level */ #define APREQ_PATCH_VERSION 0 /** * This symbol is defined for internal, "development" copies of libapreq. * This symbol will be #undef'd for releases. */ #define APREQ_IS_DEV_VERSION /** The formatted string of libapreq's version */ #define APREQ_VERSION_STRING \ APR_STRINGIFY(APREQ_MAJOR_VERSION) "." \ APR_STRINGIFY(APREQ_MINOR_VERSION) "." \ APR_STRINGIFY(APREQ_PATCH_VERSION) \ APREQ_IS_DEV_STRING /** * Return libapreq's version information information in a numeric form. * * @param pvsn Pointer to a version structure for returning the version * information. */ APREQ_DECLARE(void) apreq_version(apr_version_t *pvsn); /** Return libapreq's version information as a string. */ APREQ_DECLARE(const char *) apreq_version_string(void); /** Internal: string form of the "is dev" flag */ #ifdef APREQ_IS_DEV_VERSION #define APREQ_IS_DEV_STRING "-dev" #else #define APREQ_IS_DEV_STRING "" #endif #ifdef __cplusplus } #endif #endif /* APREQ_VERSION_H */ rapache-1.2.8/libapreq2/include/groups.dox.in0000644000175100017510000000316212706745114020430 0ustar ondrejondrej/** * @mainpage * Project Website: http://httpd.apache.org/apreq/ * * @verbinclude README */ /** * @defgroup libapreq2 Apache Request Library * @brief libapreq2 Version @APREQ_DOTTED_VERSION@ * * libapreq2 is a shared library based on the Apache * Portable Runtime libraries libapr and libaprutil. * @see http://apr.apache.org/ * * @section apreq2_config Configuring libapreq2 Applications * This package includes apreq2-config, * a configuration script for building applications * with libapreq2. Run apreq2-config --help * to display its options. XXX add examples here XXX */ /** * @defgroup apreq_module Modules * @brief apreq2 modules included in @PACKAGE@-@VERSION@. * * XXX */ /** * @defgroup apreq_lang Language Bindings * @brief libapreq2 APIs for programming languages other than C * * XXX */ /** * @page apreq_license LICENSE * @verbinclude LICENSE */ /** * @page apreq_notice NOTICE * @verbinclude NOTICE */ /** * @page apreq_install INSTALL * @verbinclude INSTALL */ /** * @defgroup apreq_xs Perl * @brief XS Modules * @ingroup apreq_lang @manonly .SH "SEE ALSO" .IX Header "SEE ALSO" \&\fIapreq_xs_request\fR\|(3), \fIapreq_xs_upload\fR\|(3), \fIapreq_xs_cookie\fR\|(3) @endmanonly */ /** * @defgroup apreq_xs_request Apache2::Request * @ingroup apreq_xs * @htmlinclude Request.html */ /** * @defgroup apreq_xs_upload Apache2::Upload * @ingroup apreq_xs * @htmlinclude Upload.html */ /** * @defgroup apreq_xs_cookie Apache2::Cookie * @ingroup apreq_xs * @htmlinclude Cookie.html */ /** * @page apreq_faq FAQ * @htmlinclude FAQ.html */ rapache-1.2.8/libapreq2/install-sh0000755000175100017510000001435012706745114016352 0ustar ondrejondrej#!/bin/sh # # install - install a program, script, or datafile # # This originates from X11R5 (mit/util/scripts/install.sh), which was # later released in X11R6 (xc/config/util/install.sh) with the # following copyright and license. # # Copyright (C) 1994 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 CONNEC- # TION 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 deal- # ings in this Software without prior written authorization from the X Consor- # tium. # # # FSF changes to this file are in the public domain. # # Calling this script install-sh is preferred over install.sh, to prevent # `make' implicit rules from creating a file called install from it # when there is no Makefile. # # This script is compatible with the BSD install script, but was written # from scratch. It can only install one file at a time, a restriction # shared with many OS's install programs. # set DOITPROG to echo to test this script # Don't use :- since 4.3BSD and earlier shells don't like it. doit="${DOITPROG-}" # put in absolute paths if you don't have them in your path; or use env. vars. mvprog="${MVPROG-mv}" cpprog="${CPPROG-cp}" chmodprog="${CHMODPROG-chmod}" chownprog="${CHOWNPROG-chown}" chgrpprog="${CHGRPPROG-chgrp}" stripprog="${STRIPPROG-strip}" rmprog="${RMPROG-rm}" mkdirprog="${MKDIRPROG-mkdir}" transformbasename="" transform_arg="" instcmd="$mvprog" chmodcmd="$chmodprog 0755" chowncmd="" chgrpcmd="" stripcmd="" rmcmd="$rmprog -f" mvcmd="$mvprog" src="" dst="" dir_arg="" while [ x"$1" != x ]; do case $1 in -c) instcmd="$cpprog" shift continue;; -d) dir_arg=true shift continue;; -m) chmodcmd="$chmodprog $2" shift shift continue;; -o) chowncmd="$chownprog $2" shift shift continue;; -g) chgrpcmd="$chgrpprog $2" shift shift continue;; -s) stripcmd="$stripprog" shift continue;; -t=*) transformarg=`echo $1 | sed 's/-t=//'` shift continue;; -b=*) transformbasename=`echo $1 | sed 's/-b=//'` shift continue;; *) if [ x"$src" = x ] then src=$1 else # this colon is to work around a 386BSD /bin/sh bug : dst=$1 fi shift continue;; esac done if [ x"$src" = x ] then echo "install: no input file specified" exit 1 else : fi if [ x"$dir_arg" != x ]; then dst=$src src="" if [ -d $dst ]; then instcmd=: chmodcmd="" else instcmd=$mkdirprog fi else # Waiting for this to be detected by the "$instcmd $src $dsttmp" command # might cause directories to be created, which would be especially bad # if $src (and thus $dsttmp) contains '*'. if [ -f "$src" ] || [ -d "$src" ] then : else echo "install: $src does not exist" exit 1 fi if [ x"$dst" = x ] then echo "install: no destination specified" exit 1 else : fi # If destination is a directory, append the input filename; if your system # does not like double slashes in filenames, you may need to add some logic if [ -d $dst ] then dst="$dst"/`basename $src` else : fi fi ## this sed command emulates the dirname command dstdir=`echo $dst | sed -e 's,[^/]*$,,;s,/$,,;s,^$,.,'` # Make sure that the destination directory exists. # this part is taken from Noah Friedman's mkinstalldirs script # Skip lots of stat calls in the usual case. if [ ! -d "$dstdir" ]; then defaultIFS=' ' IFS="${IFS-${defaultIFS}}" oIFS="${IFS}" # Some sh's can't handle IFS=/ for some reason. IFS='%' set - `echo ${dstdir} | sed -e 's@/@%@g' -e 's@^%@/@'` IFS="${oIFS}" pathcomp='' while [ $# -ne 0 ] ; do pathcomp="${pathcomp}${1}" shift if [ ! -d "${pathcomp}" ] ; then $mkdirprog "${pathcomp}" else : fi pathcomp="${pathcomp}/" done fi if [ x"$dir_arg" != x ] then $doit $instcmd $dst && if [ x"$chowncmd" != x ]; then $doit $chowncmd $dst; else : ; fi && if [ x"$chgrpcmd" != x ]; then $doit $chgrpcmd $dst; else : ; fi && if [ x"$stripcmd" != x ]; then $doit $stripcmd $dst; else : ; fi && if [ x"$chmodcmd" != x ]; then $doit $chmodcmd $dst; else : ; fi else # If we're going to rename the final executable, determine the name now. if [ x"$transformarg" = x ] then dstfile=`basename $dst` else dstfile=`basename $dst $transformbasename | sed $transformarg`$transformbasename fi # don't allow the sed command to completely eliminate the filename if [ x"$dstfile" = x ] then dstfile=`basename $dst` else : fi # Make a temp file name in the proper directory. dsttmp=$dstdir/#inst.$$# # Move or copy the file name to the temp name $doit $instcmd $src $dsttmp && trap "rm -f ${dsttmp}" 0 && # and set any options; do chmod last to preserve setuid bits # If any of these fail, we abort the whole thing. If we want to # ignore errors from any of these, just make sure not to ignore # errors from the above "$doit $instcmd $src $dsttmp" command. if [ x"$chowncmd" != x ]; then $doit $chowncmd $dsttmp; else :;fi && if [ x"$chgrpcmd" != x ]; then $doit $chgrpcmd $dsttmp; else :;fi && if [ x"$stripcmd" != x ]; then $doit $stripcmd $dsttmp; else :;fi && if [ x"$chmodcmd" != x ]; then $doit $chmodcmd $dsttmp; else :;fi && # Now rename the file to the real destination. $doit $rmcmd -f $dstdir/$dstfile && $doit $mvcmd $dsttmp $dstdir/$dstfile fi && exit 0 rapache-1.2.8/libapreq2/library/0000755000175100017510000000000012706745114016007 5ustar ondrejondrejrapache-1.2.8/libapreq2/library/Makefile.am0000644000175100017510000000132412706745114020043 0ustar ondrejondrejEXTRA_DIST = t AM_CPPFLAGS = @APR_INCLUDES@ BUILT_SOURCES = @APR_LA@ @APU_LA@ lib_LTLIBRARIES = libapreq2.la libapreq2_la_SOURCES = util.c version.c cookie.c param.c parser.c \ parser_urlencoded.c parser_header.c parser_multipart.c \ module.c module_custom.c module_cgi.c error.c libapreq2_la_LDFLAGS = -version-info @APREQ_LIBTOOL_VERSION@ @APR_LTFLAGS@ @APR_LIBS@ test: all cd t; $(MAKE) test if ENABLE_PROFILE AM_CFLAGS= -pg -fprofile-arcs -ftest-coverage clean-local: -rm *.bb *.bbg *.da *.gcov else clean-local: endif if BUILD_APR @APR_LA@: cd `@APR_CONFIG@ --srcdir` && $(MAKE) endif if BUILD_APU @APU_LA@: @APR_LA@ cd `@APU_CONFIG@ --srcdir` && $(MAKE) endif rapache-1.2.8/libapreq2/library/Makefile.in0000644000175100017510000003141212706745114020055 0ustar ondrejondrej# Makefile.in generated by automake 1.6.3 from Makefile.am. # @configure_input@ # Copyright 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002 # 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@ SHELL = @SHELL@ srcdir = @srcdir@ top_srcdir = @top_srcdir@ VPATH = @srcdir@ prefix = @prefix@ exec_prefix = @exec_prefix@ bindir = @bindir@ sbindir = @sbindir@ libexecdir = @libexecdir@ datadir = @datadir@ sysconfdir = @sysconfdir@ sharedstatedir = @sharedstatedir@ localstatedir = @localstatedir@ libdir = @libdir@ infodir = @infodir@ mandir = @mandir@ includedir = @includedir@ oldincludedir = /usr/include pkgdatadir = $(datadir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ top_builddir = .. ACLOCAL = @ACLOCAL@ AUTOCONF = @AUTOCONF@ AUTOMAKE = @AUTOMAKE@ AUTOHEADER = @AUTOHEADER@ am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd INSTALL = @INSTALL@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_DATA = @INSTALL_DATA@ install_sh_DATA = $(install_sh) -c -m 644 install_sh_PROGRAM = $(install_sh) -c install_sh_SCRIPT = $(install_sh) -c INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_HEADER = $(INSTALL_DATA) transform = @program_transform_name@ NORMAL_INSTALL = : PRE_INSTALL = : POST_INSTALL = : NORMAL_UNINSTALL = : PRE_UNINSTALL = : POST_UNINSTALL = : host_alias = @host_alias@ host_triplet = @host@ EXEEXT = @EXEEXT@ OBJEXT = @OBJEXT@ PATH_SEPARATOR = @PATH_SEPARATOR@ AMTAR = @AMTAR@ APACHE1_APXS = @APACHE1_APXS@ APACHE2_APXS = @APACHE2_APXS@ APACHE2_HTTPD = @APACHE2_HTTPD@ APACHE2_INCLUDES = @APACHE2_INCLUDES@ APACHE2_SRC = @APACHE2_SRC@ APREQ_CONFIG = @APREQ_CONFIG@ APREQ_DOTTED_VERSION = @APREQ_DOTTED_VERSION@ APREQ_LIBNAME = @APREQ_LIBNAME@ APREQ_LIBTOOL_VERSION = @APREQ_LIBTOOL_VERSION@ APREQ_MAJOR_VERSION = @APREQ_MAJOR_VERSION@ APR_CONFIG = @APR_CONFIG@ APR_INCLUDES = @APR_INCLUDES@ APR_LA = @APR_LA@ APR_LDFLAGS = @APR_LDFLAGS@ APR_LIBS = @APR_LIBS@ APR_LTFLAGS = @APR_LTFLAGS@ APU_CONFIG = @APU_CONFIG@ APU_LA = @APU_LA@ AR = @AR@ AS = @AS@ AWK = @AWK@ CC = @CC@ CXX = @CXX@ CXXCPP = @CXXCPP@ DEPDIR = @DEPDIR@ DLLTOOL = @DLLTOOL@ ECHO = @ECHO@ EGREP = @EGREP@ F77 = @F77@ GCJ = @GCJ@ GCJFLAGS = @GCJFLAGS@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ LIBTOOL = @LIBTOOL@ LN_S = @LN_S@ MAINT = @MAINT@ OBJDUMP = @OBJDUMP@ PACKAGE = @PACKAGE@ PERL = @PERL@ PERL_OPTS = @PERL_OPTS@ RANLIB = @RANLIB@ RC = @RC@ STRIP = @STRIP@ VERSION = @VERSION@ am__include = @am__include@ am__quote = @am__quote@ install_sh = @install_sh@ EXTRA_DIST = t AM_CPPFLAGS = @APR_INCLUDES@ BUILT_SOURCES = @APR_LA@ @APU_LA@ lib_LTLIBRARIES = libapreq2.la libapreq2_la_SOURCES = util.c version.c cookie.c param.c parser.c \ parser_urlencoded.c parser_header.c parser_multipart.c \ module.c module_custom.c module_cgi.c error.c libapreq2_la_LDFLAGS = -version-info @APREQ_LIBTOOL_VERSION@ @APR_LTFLAGS@ @APR_LIBS@ @ENABLE_PROFILE_TRUE@AM_CFLAGS = -pg -fprofile-arcs -ftest-coverage subdir = library mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs CONFIG_HEADER = $(top_builddir)/include/apreq_config.h CONFIG_CLEAN_FILES = LTLIBRARIES = $(lib_LTLIBRARIES) libapreq2_la_LIBADD = am_libapreq2_la_OBJECTS = util.lo version.lo cookie.lo param.lo \ parser.lo parser_urlencoded.lo parser_header.lo \ parser_multipart.lo module.lo module_custom.lo module_cgi.lo \ error.lo libapreq2_la_OBJECTS = $(am_libapreq2_la_OBJECTS) DEFS = @DEFS@ DEFAULT_INCLUDES = -I. -I$(srcdir) -I$(top_builddir)/include CPPFLAGS = @CPPFLAGS@ LDFLAGS = @LDFLAGS@ LIBS = @LIBS@ depcomp = $(SHELL) $(top_srcdir)/depcomp am__depfiles_maybe = depfiles @AMDEP_TRUE@DEP_FILES = ./$(DEPDIR)/cookie.Plo ./$(DEPDIR)/error.Plo \ @AMDEP_TRUE@ ./$(DEPDIR)/module.Plo ./$(DEPDIR)/module_cgi.Plo \ @AMDEP_TRUE@ ./$(DEPDIR)/module_custom.Plo ./$(DEPDIR)/param.Plo \ @AMDEP_TRUE@ ./$(DEPDIR)/parser.Plo \ @AMDEP_TRUE@ ./$(DEPDIR)/parser_header.Plo \ @AMDEP_TRUE@ ./$(DEPDIR)/parser_multipart.Plo \ @AMDEP_TRUE@ ./$(DEPDIR)/parser_urlencoded.Plo \ @AMDEP_TRUE@ ./$(DEPDIR)/util.Plo ./$(DEPDIR)/version.Plo COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) LTCOMPILE = $(LIBTOOL) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) \ $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) CCLD = $(CC) LINK = $(LIBTOOL) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ $(AM_LDFLAGS) $(LDFLAGS) -o $@ CFLAGS = @CFLAGS@ DIST_SOURCES = $(libapreq2_la_SOURCES) DIST_COMMON = Makefile.am Makefile.in SOURCES = $(libapreq2_la_SOURCES) all: $(BUILT_SOURCES) $(MAKE) $(AM_MAKEFLAGS) all-am .SUFFIXES: .SUFFIXES: .c .lo .o .obj $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ Makefile.am $(top_srcdir)/configure.ac $(ACLOCAL_M4) cd $(top_srcdir) && \ $(AUTOMAKE) --gnu library/Makefile Makefile: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.in $(top_builddir)/config.status cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe) libLTLIBRARIES_INSTALL = $(INSTALL) install-libLTLIBRARIES: $(lib_LTLIBRARIES) @$(NORMAL_INSTALL) $(mkinstalldirs) $(DESTDIR)$(libdir) @list='$(lib_LTLIBRARIES)'; for p in $$list; do \ if test -f $$p; then \ f="`echo $$p | sed -e 's|^.*/||'`"; \ echo " $(LIBTOOL) --mode=install $(libLTLIBRARIES_INSTALL) $(INSTALL_STRIP_FLAG) $$p $(DESTDIR)$(libdir)/$$f"; \ $(LIBTOOL) --mode=install $(libLTLIBRARIES_INSTALL) $(INSTALL_STRIP_FLAG) $$p $(DESTDIR)$(libdir)/$$f; \ else :; fi; \ done uninstall-libLTLIBRARIES: @$(NORMAL_UNINSTALL) @list='$(lib_LTLIBRARIES)'; for p in $$list; do \ p="`echo $$p | sed -e 's|^.*/||'`"; \ echo " $(LIBTOOL) --mode=uninstall rm -f $(DESTDIR)$(libdir)/$$p"; \ $(LIBTOOL) --mode=uninstall rm -f $(DESTDIR)$(libdir)/$$p; \ done clean-libLTLIBRARIES: -test -z "$(lib_LTLIBRARIES)" || rm -f $(lib_LTLIBRARIES) @list='$(lib_LTLIBRARIES)'; for p in $$list; do \ dir="`echo $$p | sed -e 's|/[^/]*$$||'`"; \ test -z "$dir" && dir=.; \ echo "rm -f \"$${dir}/so_locations\""; \ rm -f "$${dir}/so_locations"; \ done libapreq2.la: $(libapreq2_la_OBJECTS) $(libapreq2_la_DEPENDENCIES) $(LINK) -rpath $(libdir) $(libapreq2_la_LDFLAGS) $(libapreq2_la_OBJECTS) $(libapreq2_la_LIBADD) $(LIBS) mostlyclean-compile: -rm -f *.$(OBJEXT) core *.core distclean-compile: -rm -f *.tab.c @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cookie.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/error.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/module.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/module_cgi.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/module_custom.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/param.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/parser.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/parser_header.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/parser_multipart.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/parser_urlencoded.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/util.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/version.Plo@am__quote@ distclean-depend: -rm -rf ./$(DEPDIR) .c.o: @AMDEP_TRUE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@ depfile='$(DEPDIR)/$*.Po' tmpdepfile='$(DEPDIR)/$*.TPo' @AMDEPBACKSLASH@ @AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ $(COMPILE) -c `test -f '$<' || echo '$(srcdir)/'`$< .c.obj: @AMDEP_TRUE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@ depfile='$(DEPDIR)/$*.Po' tmpdepfile='$(DEPDIR)/$*.TPo' @AMDEPBACKSLASH@ @AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ $(COMPILE) -c `cygpath -w $<` .c.lo: @AMDEP_TRUE@ source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@ depfile='$(DEPDIR)/$*.Plo' tmpdepfile='$(DEPDIR)/$*.TPlo' @AMDEPBACKSLASH@ @AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ $(LTCOMPILE) -c -o $@ `test -f '$<' || echo '$(srcdir)/'`$< CCDEPMODE = @CCDEPMODE@ mostlyclean-libtool: -rm -f *.lo clean-libtool: -rm -rf .libs _libs distclean-libtool: -rm -f libtool uninstall-info-am: ETAGS = etags ETAGSFLAGS = tags: TAGS 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; } \ END { for (i in files) print i; }'`; \ mkid -fID $$unique TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ $(TAGS_FILES) $(LISP) tags=; \ here=`pwd`; \ 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; } \ END { for (i in files) print i; }'`; \ test -z "$(ETAGS_ARGS)$$tags$$unique" \ || $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ $$tags $$unique GTAGS: here=`$(am__cd) $(top_builddir) && pwd` \ && cd $(top_srcdir) \ && gtags -i $(GTAGS_ARGS) $$here distclean-tags: -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) top_distdir = .. distdir = $(top_distdir)/$(PACKAGE)-$(VERSION) distdir: $(DISTFILES) @list='$(DISTFILES)'; for file in $$list; do \ if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ dir=`echo "$$file" | sed -e 's,/[^/]*$$,,'`; \ if test "$$dir" != "$$file" && test "$$dir" != "."; then \ dir="/$$dir"; \ $(mkinstalldirs) "$(distdir)$$dir"; \ else \ dir=''; \ fi; \ if test -d $$d/$$file; then \ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \ fi; \ cp -pR $$d/$$file $(distdir)$$dir || exit 1; \ else \ test -f $(distdir)/$$file \ || cp -p $$d/$$file $(distdir)/$$file \ || exit 1; \ fi; \ done check-am: all-am check: check-am all-am: Makefile $(LTLIBRARIES) installdirs: $(mkinstalldirs) $(DESTDIR)$(libdir) 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_STRIP_FLAG=-s \ `test -z '$(STRIP)' || \ echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install mostlyclean-generic: clean-generic: distclean-generic: -rm -f Makefile $(CONFIG_CLEAN_FILES) maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." -test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES) clean: clean-am clean-am: clean-generic clean-libLTLIBRARIES clean-libtool clean-local \ mostlyclean-am distclean: distclean-am distclean-am: clean-am distclean-compile distclean-depend \ distclean-generic distclean-libtool distclean-tags dvi: dvi-am dvi-am: info: info-am info-am: install-data-am: install-exec-am: install-libLTLIBRARIES install-info: install-info-am install-man: installcheck-am: maintainer-clean: maintainer-clean-am maintainer-clean-am: distclean-am maintainer-clean-generic mostlyclean: mostlyclean-am mostlyclean-am: mostlyclean-compile mostlyclean-generic \ mostlyclean-libtool uninstall-am: uninstall-info-am uninstall-libLTLIBRARIES .PHONY: GTAGS all all-am check check-am clean clean-generic \ clean-libLTLIBRARIES clean-libtool clean-local distclean \ distclean-compile distclean-depend distclean-generic \ distclean-libtool distclean-tags distdir dvi dvi-am info \ info-am install install-am install-data install-data-am \ install-exec install-exec-am install-info install-info-am \ install-libLTLIBRARIES install-man install-strip installcheck \ installcheck-am installdirs maintainer-clean \ maintainer-clean-generic mostlyclean mostlyclean-compile \ mostlyclean-generic mostlyclean-libtool tags uninstall \ uninstall-am uninstall-info-am uninstall-libLTLIBRARIES test: all cd t; $(MAKE) test @ENABLE_PROFILE_TRUE@clean-local: @ENABLE_PROFILE_TRUE@ -rm *.bb *.bbg *.da *.gcov @ENABLE_PROFILE_FALSE@clean-local: @BUILD_APR_TRUE@@APR_LA@: @BUILD_APR_TRUE@ cd `@APR_CONFIG@ --srcdir` && $(MAKE) @BUILD_APU_TRUE@@APU_LA@: @APR_LA@ @BUILD_APU_TRUE@ cd `@APU_CONFIG@ --srcdir` && $(MAKE) # 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: rapache-1.2.8/libapreq2/library/cookie.c0000644000175100017510000003003712706745114017427 0ustar ondrejondrej/* ** Copyright 2003-2005 The Apache Software Foundation ** ** Licensed under the Apache License, Version 2.0 (the "License"); ** you may not use this file except in compliance with the License. ** You may obtain a copy of the License at ** ** http://www.apache.org/licenses/LICENSE-2.0 ** ** Unless required by applicable law or agreed to in writing, software ** distributed under the License is distributed on an "AS IS" BASIS, ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ** See the License for the specific language governing permissions and ** limitations under the License. */ #include "apreq_cookie.h" #include "apreq_error.h" #include "apreq_util.h" #include "apr_strings.h" #include "apr_lib.h" #include "apr_date.h" #define RFC 1 #define NETSCAPE 0 #define ADD_COOKIE(j,c) apreq_value_table_add(&c->v, j) APREQ_DECLARE(void) apreq_cookie_expires(apreq_cookie_t *c, const char *time_str) { if (time_str == NULL) { c->max_age = -1; return; } if (!strcasecmp(time_str, "now")) c->max_age = 0; else { c->max_age = apr_date_parse_rfc(time_str); if (c->max_age == APR_DATE_BAD) c->max_age = apr_time_from_sec(apreq_atoi64t(time_str)); else c->max_age -= apr_time_now(); } } static apr_status_t apreq_cookie_attr(apr_pool_t *p, apreq_cookie_t *c, const char *attr, apr_size_t alen, const char *val, apr_size_t vlen) { if (alen < 2) return APR_EBADARG; if ( attr[0] == '-' || attr[0] == '$' ) { ++attr; --alen; } switch (apr_tolower(*attr)) { case 'n': /* name is not an attr */ return APR_ENOTIMPL; case 'v': /* version; value is not an attr */ if (alen == 5 && strncasecmp(attr,"value", 5) == 0) return APR_ENOTIMPL; while (!apr_isdigit(*val)) { if (vlen == 0) return APREQ_ERROR_BADSEQ; ++val; --vlen; } apreq_cookie_version_set(c, *val - '0'); return APR_SUCCESS; case 'e': case 'm': /* expires, max-age */ apreq_cookie_expires(c, val); return APR_SUCCESS; case 'd': c->domain = apr_pstrmemdup(p,val,vlen); return APR_SUCCESS; case 'p': if (alen != 4) break; if (!strncasecmp("port", attr, 4)) { c->port = apr_pstrmemdup(p,val,vlen); return APR_SUCCESS; } else if (!strncasecmp("path", attr, 4)) { c->path = apr_pstrmemdup(p,val,vlen); return APR_SUCCESS; } break; case 'c': if (!strncasecmp("commentURL", attr, 10)) { c->commentURL = apr_pstrmemdup(p,val,vlen); return APR_SUCCESS; } else if (!strncasecmp("comment", attr, 7)) { c->comment = apr_pstrmemdup(p,val,vlen); return APR_SUCCESS; } break; case 's': if (vlen > 0 && *val != '0' && strncasecmp("off",val,vlen)) apreq_cookie_secure_on(c); else apreq_cookie_secure_off(c); return APR_SUCCESS; }; return APR_ENOTIMPL; } APREQ_DECLARE(apreq_cookie_t *) apreq_cookie_make(apr_pool_t *p, const char *name, const apr_size_t nlen, const char *value, const apr_size_t vlen) { apreq_cookie_t *c; apreq_value_t *v; c = apr_palloc(p, nlen + vlen + 1 + sizeof *c); if (c == NULL) return NULL; *(const apreq_value_t **)&v = &c->v; if (vlen > 0 && value != NULL) memcpy(v->data, value, vlen); v->data[vlen] = 0; v->dlen = vlen; v->name = v->data + vlen + 1; if (nlen && name != NULL) memcpy(v->name, name, nlen); v->name[nlen] = 0; v->nlen = nlen; /* session cookie is the default */ c->max_age = -1; c->path = NULL; c->domain = NULL; c->port = NULL; c->flags = 0; c->comment = NULL; c->commentURL = NULL; return c; } static APR_INLINE apr_status_t get_pair(apr_pool_t *p, const char **data, const char **n, apr_size_t *nlen, const char **v, apr_size_t *vlen, unsigned unquote) { const char *hdr, *key, *val; hdr = *data; while (apr_isspace(*hdr) || *hdr == '=') ++hdr; key = strchr(hdr, '='); if (key == NULL) return APREQ_ERROR_NOTOKEN; val = key + 1; do --key; while (key > hdr && apr_isspace(*key)); *n = key; while (key >= hdr && !apr_isspace(*key)) --key; *nlen = *n - key; *n = key + 1; while (apr_isspace(*val)) ++val; if (*val == '"') { unsigned saw_backslash = 0; for (*v = (unquote) ? ++val : val++; *val; ++val) { switch (*val) { case '"': *data = val + 1; if (!unquote) { *vlen = (val - *v) + 1; } else if (!saw_backslash) { *vlen = val - *v; } else { char *dest = apr_palloc(p, val - *v), *d = dest; const char *s = *v; while (s < val) { if (*s == '\\') ++s; *d++ = *s++; } *vlen = d - dest; *v = dest; } return APR_SUCCESS; case '\\': saw_backslash = 1; if (val[1] != 0) ++val; default: break; } } /* bad sequence: no terminating quote found */ return APREQ_ERROR_BADSEQ; } else { /* value is not wrapped in quotes */ for (*v = val; *val; ++val) { switch (*val) { case ';': case ',': case ' ': case '\t': case '\r': case '\n': *data = val; *vlen = val - *v; return APR_SUCCESS; default: break; } } } *data = val; *vlen = val - *v; return APR_SUCCESS; } APREQ_DECLARE(apr_status_t)apreq_parse_cookie_header(apr_pool_t *p, apr_table_t *j, const char *hdr) { apreq_cookie_t *c; unsigned version; parse_cookie_header: c = NULL; version = NETSCAPE; while (apr_isspace(*hdr)) ++hdr; if (*hdr == '$') { /* XXX cheat: assume "$..." => "$Version" => RFC Cookie header */ version = RFC; skip_version_string: switch (*hdr++) { case 0: return APR_SUCCESS; case ',': goto parse_cookie_header; case ';': break; default: goto skip_version_string; } } for (;;) { apr_status_t status; const char *name, *value; apr_size_t nlen, vlen; while (*hdr == ';' || apr_isspace(*hdr)) ++hdr; switch (*hdr) { case 0: /* this is the normal exit point */ if (c != NULL) { ADD_COOKIE(j, c); } return APR_SUCCESS; case ',': ++hdr; if (c != NULL) { ADD_COOKIE(j, c); } goto parse_cookie_header; case '$': if (c == NULL) { return APREQ_ERROR_BADCHAR; } else if (version == NETSCAPE) { return APREQ_ERROR_MISMATCH; } ++hdr; status = get_pair(p, &hdr, &name, &nlen, &value, &vlen, 1); if (status != APR_SUCCESS) return status; status = apreq_cookie_attr(p, c, name, nlen, value, vlen); switch (status) { case APR_ENOTIMPL: /* XXX: skip unrecognized attr? Not really correct, but for now, just fall through */ case APR_SUCCESS: break; default: return status; } break; default: if (c != NULL) { ADD_COOKIE(j, c); } status = get_pair(p, &hdr, &name, &nlen, &value, &vlen, 0); if (status != APR_SUCCESS) return status; c = apreq_cookie_make(p, name, nlen, value, vlen); apreq_cookie_tainted_on(c); if (version != NETSCAPE) apreq_cookie_version_set(c, version); } } /* NOT REACHED */ return APREQ_ERROR_GENERAL; } APREQ_DECLARE(int) apreq_cookie_serialize(const apreq_cookie_t *c, char *buf, apr_size_t len) { /* The format string must be large enough to accomodate all * of the cookie attributes. The current attributes sum to * ~90 characters (w/ 6-8 padding chars per attr), so anything * over 100 should be fine. */ unsigned version = apreq_cookie_version(c); char format[128] = "%s=%s"; char *f = format + strlen(format); /* XXX protocol enforcement (for debugging, anyway) ??? */ if (c->v.name == NULL) return -1; #define NULL2EMPTY(attr) (attr ? attr : "") if (version == NETSCAPE) { char expires[APR_RFC822_DATE_LEN] = {0}; #define ADD_NS_ATTR(name) do { \ if (c->name != NULL) \ strcpy(f, "; " #name "=%s"); \ else \ strcpy(f, "%0.s"); \ f += strlen(f); \ } while (0) ADD_NS_ATTR(path); ADD_NS_ATTR(domain); if (c->max_age != -1) { strcpy(f, "; expires=%s"); apr_rfc822_date(expires, c->max_age + apr_time_now()); expires[7] = '-'; expires[11] = '-'; } else strcpy(f, ""); f += strlen(f); if (apreq_cookie_is_secure(c)) strcpy(f, "; secure"); return apr_snprintf(buf, len, format, c->v.name, c->v.data, NULL2EMPTY(c->path), NULL2EMPTY(c->domain), expires); } /* c->version == RFC */ strcpy(f,"; Version=%u"); f += strlen(f); /* ensure RFC attributes are always quoted */ #define ADD_RFC_ATTR(name) do { \ if (c->name != NULL) \ if (*c->name == '"') \ strcpy(f, "; " #name "=%s"); \ else \ strcpy(f, "; " #name "=\"%s\""); \ else \ strcpy(f, "%0.s"); \ f += strlen (f); \ } while (0) ADD_RFC_ATTR(path); ADD_RFC_ATTR(domain); ADD_RFC_ATTR(port); ADD_RFC_ATTR(comment); ADD_RFC_ATTR(commentURL); strcpy(f, c->max_age != -1 ? "; max-age=%" APR_TIME_T_FMT : ""); f += strlen(f); if (apreq_cookie_is_secure(c)) strcpy(f, "; secure"); return apr_snprintf(buf, len, format, c->v.name, c->v.data, version, NULL2EMPTY(c->path), NULL2EMPTY(c->domain), NULL2EMPTY(c->port), NULL2EMPTY(c->comment), NULL2EMPTY(c->commentURL), apr_time_sec(c->max_age)); } APREQ_DECLARE(char*) apreq_cookie_as_string(const apreq_cookie_t *c, apr_pool_t *p) { int n = apreq_cookie_serialize(c, NULL, 0); char *s = apr_palloc(p, n + 1); apreq_cookie_serialize(c, s, n + 1); return s; } rapache-1.2.8/libapreq2/library/error.c0000644000175100017510000000514212706745114017306 0ustar ondrejondrej/* Copyright 2000-2005 The Apache Software Foundation * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ #include "apreq_error.h" #include "apr_strings.h" /* * stuffbuffer - like apr_cpystrn() but returns the address of the * dest buffer instead of the address of the terminating '\0' */ static char *stuffbuffer(char *buf, apr_size_t bufsize, const char *s) { apr_cpystrn(buf,s,bufsize); return buf; } static const char *apreq_error_string(apr_status_t statcode) { switch (statcode) { /* 0's: generic error status codes */ case APREQ_ERROR_GENERAL: return "Internal apreq error"; case APREQ_ERROR_TAINTED: return "Attempt to perform unsafe action with tainted data"; /* 10's: malformed input */ case APREQ_ERROR_BADDATA: return "Malformed input data"; case APREQ_ERROR_BADCHAR: return "Invalid character"; case APREQ_ERROR_BADSEQ: return "Invalid byte sequence"; case APREQ_ERROR_BADATTR: return "Unrecognized attribute"; case APREQ_ERROR_BADHEADER: return "Malformed header string"; /* 20's: missing input */ case APREQ_ERROR_NODATA: return "Missing input data"; case APREQ_ERROR_NOTOKEN: return "Expected token not present"; case APREQ_ERROR_NOATTR: return "Missing attribute"; case APREQ_ERROR_NOHEADER: return "Missing header"; case APREQ_ERROR_NOPARSER: return "Missing parser"; /* 30's: configuration conflicts */ case APREQ_ERROR_MISMATCH: return "Conflicting information"; case APREQ_ERROR_OVERLIMIT: return "Exceeds configured maximum limit"; case APREQ_ERROR_NOTEMPTY: return "Setting already configured"; default: return "Error string not yet specified by apreq"; } } APREQ_DECLARE(char *) apreq_strerror(apr_status_t statcode, char *buf, apr_size_t bufsize) { if (statcode < APR_OS_START_USERERR || statcode >= APR_OS_START_EAIERR) return apr_strerror(statcode, buf, bufsize); return stuffbuffer(buf, bufsize, apreq_error_string(statcode)); } rapache-1.2.8/libapreq2/library/module.c0000644000175100017510000000265012706745114017443 0ustar ondrejondrej/* ** Copyright 2003-2005 The Apache Software Foundation ** ** Licensed under the Apache License, Version 2.0 (the "License"); ** you may not use this file except in compliance with the License. ** You may obtain a copy of the License at ** ** http://www.apache.org/licenses/LICENSE-2.0 ** ** Unless required by applicable law or agreed to in writing, software ** distributed under the License is distributed on an "AS IS" BASIS, ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ** See the License for the specific language governing permissions and ** limitations under the License. */ #include "apreq_module.h" #include "apreq_error.h" #include "apr_strings.h" #include "apr_lib.h" #include "apr_file_io.h" APREQ_DECLARE(apreq_param_t *)apreq_param(apreq_handle_t *req, const char *key) { apreq_param_t *param = apreq_args_get(req, key); if (param == NULL) return apreq_body_get(req, key); else return param; } APREQ_DECLARE(apr_table_t *)apreq_params(apreq_handle_t *req, apr_pool_t *p) { const apr_table_t *args, *body; apreq_args(req, &args); apreq_body(req, &body); if (args != NULL) if (body != NULL) return apr_table_overlay(p, args, body); else return apr_table_copy(p, args); else if (body != NULL) return apr_table_copy(p, body); else return NULL; } /** @} */ rapache-1.2.8/libapreq2/library/module_cgi.c0000644000175100017510000004443612706745114020275 0ustar ondrejondrej/* ** Copyright 2003-2005 The Apache Software Foundation ** ** Licensed under the Apache License, Version 2.0 (the "License"); ** you may not use this file except in compliance with the License. ** You may obtain a copy of the License at ** ** http://www.apache.org/licenses/LICENSE-2.0 ** ** Unless required by applicable law or agreed to in writing, software ** distributed under the License is distributed on an "AS IS" BASIS, ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ** See the License for the specific language governing permissions and ** limitations under the License. */ #include #include "apreq_module.h" #include "apreq_error.h" #include "apr_strings.h" #include "apr_lib.h" #include "apr_env.h" #include "apreq_util.h" #define USER_DATA_KEY "apreq" /* Parroting APLOG_* ... */ #define CGILOG_EMERG 0 /* system is unusable */ #define CGILOG_ALERT 1 /* action must be taken immediately */ #define CGILOG_CRIT 2 /* critical conditions */ #define CGILOG_ERR 3 /* error conditions */ #define CGILOG_WARNING 4 /* warning conditions */ #define CGILOG_NOTICE 5 /* normal but significant condition */ #define CGILOG_INFO 6 /* informational */ #define CGILOG_DEBUG 7 /* debug-level messages */ #define CGILOG_LEVELMASK 7 #define CGILOG_MARK __FILE__, __LINE__ struct cgi_handle { struct apreq_handle_t handle; apr_table_t *jar, *args, *body; apr_status_t jar_status, args_status, body_status; apreq_parser_t *parser; apreq_hook_t *hook_queue; apreq_hook_t *find_param; const char *temp_dir; apr_size_t brigade_limit; apr_uint64_t read_limit; apr_uint64_t bytes_read; apr_bucket_brigade *in; apr_bucket_brigade *tmpbb; }; #define CRLF "\015\012" typedef struct { const char *t_name; int t_val; } TRANS; static const TRANS priorities[] = { {"emerg", CGILOG_EMERG}, {"alert", CGILOG_ALERT}, {"crit", CGILOG_CRIT}, {"error", CGILOG_ERR}, {"warn", CGILOG_WARNING}, {"notice", CGILOG_NOTICE}, {"info", CGILOG_INFO}, {"debug", CGILOG_DEBUG}, {NULL, -1}, }; static const char *cgi_header_in(apreq_handle_t *handle, const char *name) { apr_pool_t *p = handle->pool; char *key = apr_pstrcat(p, "HTTP_", name, NULL); char *k, *value = NULL; for (k = key; *k; ++k) { if (*k == '-') *k = '_'; else *k = apr_toupper(*k); } if (!strcmp(key, "HTTP_CONTENT_TYPE") || !strcmp(key, "HTTP_CONTENT_LENGTH")) { key += 5; /* strlen("HTTP_") */ } apr_env_get(&value, key, p); return value; } static void cgi_log_error(const char *file, int line, int level, apr_status_t status, apreq_handle_t *handle, const char *fmt, ...) { apr_pool_t *p = handle->pool; char buf[256]; char *log_level_string, *ra; const char *remote_addr; unsigned log_level = CGILOG_WARNING; char date[APR_CTIME_LEN]; va_list vp; #ifndef WIN32 apr_file_t *err; #endif va_start(vp, fmt); if (apr_env_get(&log_level_string, "LOG_LEVEL", p) == APR_SUCCESS) log_level = (log_level_string[0] - '0'); level &= CGILOG_LEVELMASK; if (level < (int)log_level) { if (apr_env_get(&ra, "REMOTE_ADDR", p) == APR_SUCCESS) remote_addr = ra; else remote_addr = "address unavailable"; apr_ctime(date, apr_time_now()); #ifndef WIN32 apr_file_open_stderr(&err, p); apr_file_printf(err, "[%s] [%s] [%s] %s(%d): %s: %s\n", date, priorities[level].t_name, remote_addr, file, line, apr_strerror(status,buf,255),apr_pvsprintf(p,fmt,vp)); apr_file_flush(err); #else fprintf(stderr, "[%s] [%s] [%s] %s(%d): %s: %s\n", date, priorities[level].t_name, remote_addr, file, line, apr_strerror(status,buf,255),apr_pvsprintf(p,fmt,vp)); #endif } va_end(vp); } APR_INLINE static const char *cgi_query_string(apreq_handle_t *handle) { char *value = NULL, qs[] = "QUERY_STRING"; apr_env_get(&value, qs, handle->pool); return value; } static void init_body(apreq_handle_t *handle) { struct cgi_handle *req = (struct cgi_handle *)handle; const char *cl_header = cgi_header_in(handle, "Content-Length"); apr_bucket_alloc_t *ba = handle->bucket_alloc; apr_pool_t *pool = handle->pool; apr_file_t *file; apr_bucket *eos, *pipe; req->body = apr_table_make(pool, APREQ_DEFAULT_NELTS); if (cl_header != NULL) { char *dummy; apr_int64_t content_length = apr_strtoi64(cl_header, &dummy, 0); if (dummy == NULL || *dummy != 0) { req->body_status = APREQ_ERROR_BADHEADER; cgi_log_error(CGILOG_MARK, CGILOG_ERR, req->body_status, handle, "Invalid Content-Length header (%s)", cl_header); return; } else if ((apr_uint64_t)content_length > req->read_limit) { req->body_status = APREQ_ERROR_OVERLIMIT; cgi_log_error(CGILOG_MARK, CGILOG_ERR, req->body_status, handle, "Content-Length header (%s) exceeds configured " "max_body limit (%" APR_UINT64_T_FMT ")", cl_header, req->read_limit); return; } } if (req->parser == NULL) { const char *ct_header = cgi_header_in(handle, "Content-Type"); if (ct_header != NULL) { apreq_parser_function_t pf = apreq_parser(ct_header); if (pf != NULL) { req->parser = apreq_parser_make(pool, ba, ct_header, pf, req->brigade_limit, req->temp_dir, req->hook_queue, NULL); } else { req->body_status = APREQ_ERROR_NOPARSER; return; } } else { req->body_status = APREQ_ERROR_NOHEADER; return; } } else { if (req->parser->brigade_limit > req->brigade_limit) req->parser->brigade_limit = req->brigade_limit; if (req->temp_dir != NULL) req->parser->temp_dir = req->temp_dir; if (req->hook_queue != NULL) apreq_parser_add_hook(req->parser, req->hook_queue); } req->hook_queue = NULL; req->in = apr_brigade_create(pool, ba); req->tmpbb = apr_brigade_create(pool, ba); apr_file_open_stdin(&file, pool); // error status? pipe = apr_bucket_pipe_create(file, ba); eos = apr_bucket_eos_create(ba); APR_BRIGADE_INSERT_HEAD(req->in, pipe); APR_BRIGADE_INSERT_TAIL(req->in, eos); req->body_status = APR_INCOMPLETE; } static apr_status_t cgi_read(apreq_handle_t *handle, apr_off_t bytes) { struct cgi_handle *req = (struct cgi_handle *)handle; apr_bucket *e; apr_status_t s; if (req->body_status == APR_EINIT) init_body(handle); if (req->body_status != APR_INCOMPLETE) return req->body_status; switch (s = apr_brigade_partition(req->in, bytes, &e)) { apr_off_t len; case APR_SUCCESS: apreq_brigade_move(req->tmpbb, req->in, e); req->bytes_read += bytes; if (req->bytes_read > req->read_limit) { req->body_status = APREQ_ERROR_OVERLIMIT; cgi_log_error(CGILOG_MARK, CGILOG_ERR, req->body_status, handle, "Bytes read (%" APR_UINT64_T_FMT ") exceeds configured limit (%" APR_UINT64_T_FMT ")", req->bytes_read, req->read_limit); break; } req->body_status = apreq_parser_run(req->parser, req->body, req->tmpbb); apr_brigade_cleanup(req->tmpbb); break; case APR_INCOMPLETE: apreq_brigade_move(req->tmpbb, req->in, e); s = apr_brigade_length(req->tmpbb, 1, &len); if (s != APR_SUCCESS) { req->body_status = s; break; } req->bytes_read += len; if (req->bytes_read > req->read_limit) { req->body_status = APREQ_ERROR_OVERLIMIT; cgi_log_error(CGILOG_MARK, CGILOG_ERR, req->body_status, handle, "Bytes read (%" APR_UINT64_T_FMT ") exceeds configured limit (%" APR_UINT64_T_FMT ")", req->bytes_read, req->read_limit); break; } req->body_status = apreq_parser_run(req->parser, req->body, req->tmpbb); apr_brigade_cleanup(req->tmpbb); break; default: req->body_status = s; } return req->body_status; } static apr_status_t cgi_jar(apreq_handle_t *handle, const apr_table_t **t) { struct cgi_handle *req = (struct cgi_handle *)handle; if (req->jar_status == APR_EINIT) { const char *cookies = cgi_header_in(handle, "Cookie"); if (cookies != NULL) { req->jar = apr_table_make(handle->pool, APREQ_DEFAULT_NELTS); req->jar_status = apreq_parse_cookie_header(handle->pool, req->jar, cookies); } else req->jar_status = APREQ_ERROR_NODATA; } *t = req->jar; return req->jar_status; } static apr_status_t cgi_args(apreq_handle_t *handle, const apr_table_t **t) { struct cgi_handle *req = (struct cgi_handle *)handle; if (req->args_status == APR_EINIT) { const char *qs = cgi_query_string(handle); if (qs != NULL) { req->args = apr_table_make(handle->pool, APREQ_DEFAULT_NELTS); req->args_status = apreq_parse_query_string(handle->pool, req->args, qs); } else req->args_status = APREQ_ERROR_NODATA; } *t = req->args; return req->args_status; } static apreq_cookie_t *cgi_jar_get(apreq_handle_t *handle, const char *name) { struct cgi_handle *req = (struct cgi_handle *)handle; const apr_table_t *t; const char *val; if (req->jar_status == APR_EINIT) cgi_jar(handle, &t); else t = req->jar; if (t == NULL) return NULL; val = apr_table_get(t, name); if (val == NULL) return NULL; return apreq_value_to_cookie(val); } static apreq_param_t *cgi_args_get(apreq_handle_t *handle, const char *name) { struct cgi_handle *req = (struct cgi_handle *)handle; const apr_table_t *t; const char *val; if (req->args_status == APR_EINIT) cgi_args(handle, &t); else t = req->args; if (t == NULL) return NULL; val = apr_table_get(t, name); if (val == NULL) return NULL; return apreq_value_to_param(val); } static apr_status_t cgi_body(apreq_handle_t *handle, const apr_table_t **t) { struct cgi_handle *req = (struct cgi_handle *)handle; switch (req->body_status) { case APR_EINIT: init_body(handle); if (req->body_status != APR_INCOMPLETE) break; case APR_INCOMPLETE: while (cgi_read(handle, APREQ_DEFAULT_READ_BLOCK_SIZE) == APR_INCOMPLETE) ; /*loop*/ } *t = req->body; return req->body_status; } static apreq_param_t *cgi_body_get(apreq_handle_t *handle, const char *name) { struct cgi_handle *req = (struct cgi_handle *)handle; const char *val; apreq_hook_t *h; switch (req->body_status) { case APR_SUCCESS: val = apr_table_get(req->body, name); if (val != NULL) return apreq_value_to_param(val); return NULL; case APR_EINIT: init_body(handle); if (req->body_status != APR_INCOMPLETE) return NULL; cgi_read(handle, APREQ_DEFAULT_READ_BLOCK_SIZE); case APR_INCOMPLETE: val = apr_table_get(req->body, name); if (val != NULL) return apreq_value_to_param(val); /* Not seen yet, so we need to scan for param while prefetching the body */ if (req->find_param == NULL) req->find_param = apreq_hook_make(handle->pool, apreq_hook_find_param, NULL, NULL); h = req->find_param; h->next = req->parser->hook; req->parser->hook = h; *(const char **)&h->ctx = name; do { cgi_read(handle, APREQ_DEFAULT_READ_BLOCK_SIZE); if (h->ctx != name) { req->parser->hook = h->next; return h->ctx; } } while (req->body_status == APR_INCOMPLETE); req->parser->hook = h->next; return NULL; default: if (req->body == NULL) return NULL; val = apr_table_get(req->body, name); if (val != NULL) return apreq_value_to_param(val); return NULL; } /* not reached */ return NULL; } static apr_status_t cgi_parser_get(apreq_handle_t *handle, const apreq_parser_t **parser) { struct cgi_handle *req = (struct cgi_handle *)handle; *parser = req->parser; return APR_SUCCESS; } static apr_status_t cgi_parser_set(apreq_handle_t *handle, apreq_parser_t *parser) { struct cgi_handle *req = (struct cgi_handle *)handle; if (req->parser == NULL) { if (req->hook_queue != NULL) { apr_status_t s = apreq_parser_add_hook(parser, req->hook_queue); if (s != APR_SUCCESS) return s; } if (req->temp_dir != NULL) { parser->temp_dir = req->temp_dir; } if (req->brigade_limit < parser->brigade_limit) { parser->brigade_limit = req->brigade_limit; } req->hook_queue = NULL; req->parser = parser; return APR_SUCCESS; } else return APREQ_ERROR_MISMATCH; } static apr_status_t cgi_hook_add(apreq_handle_t *handle, apreq_hook_t *hook) { struct cgi_handle *req = (struct cgi_handle *)handle; if (req->parser != NULL) { return apreq_parser_add_hook(req->parser, hook); } else if (req->hook_queue != NULL) { apreq_hook_t *h = req->hook_queue; while (h->next != NULL) h = h->next; h->next = hook; } else { req->hook_queue = hook; } return APR_SUCCESS; } static apr_status_t cgi_brigade_limit_set(apreq_handle_t *handle, apr_size_t bytes) { struct cgi_handle *req = (struct cgi_handle *)handle; apr_size_t *limit = (req->parser == NULL) ? &req->brigade_limit : &req->parser->brigade_limit; if (*limit > bytes) { *limit = bytes; return APR_SUCCESS; } return APREQ_ERROR_MISMATCH; } static apr_status_t cgi_brigade_limit_get(apreq_handle_t *handle, apr_size_t *bytes) { struct cgi_handle *req = (struct cgi_handle *)handle; *bytes = (req->parser == NULL) ? req->brigade_limit : req->parser->brigade_limit; return APR_SUCCESS; } static apr_status_t cgi_read_limit_set(apreq_handle_t *handle, apr_uint64_t bytes) { struct cgi_handle *req = (struct cgi_handle *)handle; if (req->read_limit > bytes && req->bytes_read < bytes) { req->read_limit = bytes; return APR_SUCCESS; } return APREQ_ERROR_MISMATCH; } static apr_status_t cgi_read_limit_get(apreq_handle_t *handle, apr_uint64_t *bytes) { struct cgi_handle *req = (struct cgi_handle *)handle; *bytes = req->read_limit; return APR_SUCCESS; } static apr_status_t cgi_temp_dir_set(apreq_handle_t *handle, const char *path) { struct cgi_handle *req = (struct cgi_handle *)handle; const char **temp_dir = (req->parser == NULL) ? &req->temp_dir : &req->parser->temp_dir; if (*temp_dir == NULL && req->bytes_read == 0) { if (path != NULL) *temp_dir = apr_pstrdup(handle->pool, path); return APR_SUCCESS; } return APREQ_ERROR_MISMATCH; } static apr_status_t cgi_temp_dir_get(apreq_handle_t *handle, const char **path) { struct cgi_handle *req = (struct cgi_handle *)handle; *path = (req->parser == NULL) ? req->temp_dir : req->parser->temp_dir; return APR_SUCCESS; } #ifdef APR_POOL_DEBUG static apr_status_t ba_cleanup(void *data) { apr_bucket_alloc_t *ba = data; apr_bucket_alloc_destroy(ba); return APR_SUCCESS; } #endif static APREQ_MODULE(cgi, 20050425); APREQ_DECLARE(apreq_handle_t *)apreq_handle_cgi(apr_pool_t *pool) { apr_bucket_alloc_t *ba; struct cgi_handle *req; void *data; apr_pool_userdata_get(&data, USER_DATA_KEY, pool); if (data != NULL) return data; req = apr_pcalloc(pool, sizeof *req); ba = apr_bucket_alloc_create(pool); /* check pool's userdata first. */ req->handle.module = &cgi_module; req->handle.pool = pool; req->handle.bucket_alloc = ba; req->read_limit = (apr_uint64_t) -1; req->brigade_limit = APREQ_DEFAULT_BRIGADE_LIMIT; req->args_status = req->jar_status = req->body_status = APR_EINIT; apr_pool_userdata_setn(&req->handle, USER_DATA_KEY, NULL, pool); #ifdef APR_POOL_DEBUG apr_pool_cleanup_register(pool, ba, ba_cleanup, ba_cleanup); #endif return &req->handle; } rapache-1.2.8/libapreq2/library/module_custom.c0000644000175100017510000002022312706745114021031 0ustar ondrejondrej/* ** Copyright 2003-2005 The Apache Software Foundation ** ** Licensed under the Apache License, Version 2.0 (the "License"); ** you may not use this file except in compliance with the License. ** You may obtain a copy of the License at ** ** http://www.apache.org/licenses/LICENSE-2.0 ** ** Unless required by applicable law or agreed to in writing, software ** distributed under the License is distributed on an "AS IS" BASIS, ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ** See the License for the specific language governing permissions and ** limitations under the License. */ #include "apr_strings.h" #include "apreq_module.h" #include "apreq_error.h" #include "apreq_util.h" #define READ_BYTES (64 * 1024) struct custom_handle { struct apreq_handle_t handle; const char *cookie_header; apr_table_t *jar, *args, *body; apr_status_t jar_status, args_status, body_status; apreq_parser_t *parser; apr_uint64_t read_limit; apr_uint64_t bytes_read; apr_bucket_brigade *in; apr_bucket_brigade *tmpbb; }; static apr_status_t custom_parse_brigade(apreq_handle_t *handle, apr_uint64_t bytes) { struct custom_handle *req = (struct custom_handle *)handle; apr_status_t s; apr_bucket *e; if (req->body_status != APR_INCOMPLETE) return req->body_status; switch (s = apr_brigade_partition(req->in, bytes, &e)) { apr_off_t len; case APR_SUCCESS: apreq_brigade_move(req->tmpbb, req->in, e); req->bytes_read += bytes; if (req->bytes_read > req->read_limit) { req->body_status = APREQ_ERROR_OVERLIMIT; break; } req->body_status = apreq_parser_run(req->parser, req->body, req->tmpbb); apr_brigade_cleanup(req->tmpbb); break; case APR_INCOMPLETE: apreq_brigade_move(req->tmpbb, req->in, e); s = apr_brigade_length(req->tmpbb, 1, &len); if (s != APR_SUCCESS) { req->body_status = s; break; } req->bytes_read += len; if (req->bytes_read > req->read_limit) { req->body_status = APREQ_ERROR_OVERLIMIT; break; } req->body_status = apreq_parser_run(req->parser, req->body, req->tmpbb); apr_brigade_cleanup(req->tmpbb); break; default: req->body_status = s; } return req->body_status; } static apr_status_t custom_jar(apreq_handle_t *handle, const apr_table_t **t) { struct custom_handle *req = (struct custom_handle *)handle; *t = req->jar; return req->jar_status; } static apr_status_t custom_args(apreq_handle_t *handle, const apr_table_t **t) { struct custom_handle *req = (struct custom_handle*)handle; *t = req->args; return req->args_status; } static apr_status_t custom_body(apreq_handle_t *handle, const apr_table_t **t) { struct custom_handle *req = (struct custom_handle*)handle; while (req->body_status == APR_INCOMPLETE) custom_parse_brigade(handle, READ_BYTES); *t = req->body; return req->body_status; } static apreq_cookie_t *custom_jar_get(apreq_handle_t *handle, const char *name) { struct custom_handle *req = (struct custom_handle*)handle; const char *val; if (req->jar == NULL || name == NULL) return NULL; val = apr_table_get(req->jar, name); if (val == NULL) return NULL; return apreq_value_to_cookie(val); } static apreq_param_t *custom_args_get(apreq_handle_t *handle, const char *name) { struct custom_handle *req = (struct custom_handle*)handle; const char *val; if (req->args == NULL || name == NULL) return NULL; val = apr_table_get(req->args, name); if (val == NULL) return NULL; return apreq_value_to_param(val); } static apreq_param_t *custom_body_get(apreq_handle_t *handle, const char *name) { struct custom_handle *req = (struct custom_handle*)handle; const char *val; if (req->body == NULL || name == NULL) return NULL; while (1) { *(const char **)&val = apr_table_get(req->body, name); if (val != NULL) break; if (req->body_status == APR_INCOMPLETE) custom_parse_brigade(handle, READ_BYTES); else return NULL; } return apreq_value_to_param(val); } static apr_status_t custom_parser_get(apreq_handle_t *handle, const apreq_parser_t **parser) { struct custom_handle *req = (struct custom_handle*)handle; *parser = req->parser; return APR_SUCCESS; } static apr_status_t custom_parser_set(apreq_handle_t *handle, apreq_parser_t *parser) { (void)handle; (void)parser; return APR_ENOTIMPL; } static apr_status_t custom_hook_add(apreq_handle_t *handle, apreq_hook_t *hook) { struct custom_handle *req = (struct custom_handle*)handle; apreq_parser_add_hook(req->parser, hook); return APR_SUCCESS; } static apr_status_t custom_brigade_limit_get(apreq_handle_t *handle, apr_size_t *bytes) { struct custom_handle *req = (struct custom_handle*)handle; *bytes = req->parser->brigade_limit; return APR_SUCCESS; } static apr_status_t custom_brigade_limit_set(apreq_handle_t *handle, apr_size_t bytes) { (void)handle; (void)bytes; return APR_ENOTIMPL; } static apr_status_t custom_read_limit_get(apreq_handle_t *handle, apr_uint64_t *bytes) { struct custom_handle *req = (struct custom_handle*)handle; *bytes = req->read_limit; return APR_SUCCESS; } static apr_status_t custom_read_limit_set(apreq_handle_t *handle, apr_uint64_t bytes) { (void)handle; (void)bytes; return APR_ENOTIMPL; } static apr_status_t custom_temp_dir_get(apreq_handle_t *handle, const char **path) { struct custom_handle *req = (struct custom_handle*)handle; *path = req->parser->temp_dir; return APR_SUCCESS; } static apr_status_t custom_temp_dir_set(apreq_handle_t *handle, const char *path) { (void)handle; (void)path; return APR_ENOTIMPL; } static APREQ_MODULE(custom, 20050425); APREQ_DECLARE(apreq_handle_t*) apreq_handle_custom(apr_pool_t *pool, const char *query_string, const char *cookie, apreq_parser_t *parser, apr_uint64_t read_limit, apr_bucket_brigade *in) { struct custom_handle *req; req = apr_palloc(pool, sizeof(*req)); req->handle.module = &custom_module; req->handle.pool = pool; req->handle.bucket_alloc = in->bucket_alloc; req->cookie_header = cookie; req->read_limit = read_limit; req->parser = parser; req->in = in; if (cookie != NULL) { req->jar = apr_table_make(pool, APREQ_DEFAULT_NELTS); req->jar_status = apreq_parse_cookie_header(pool, req->jar, cookie); } else { req->jar = NULL; req->jar_status = APREQ_ERROR_NODATA; } if (query_string != NULL) { req->args = apr_table_make(pool, APREQ_DEFAULT_NELTS); req->args_status = apreq_parse_query_string(pool, req->args, query_string); } else { req->args = NULL; req->args_status = APREQ_ERROR_NODATA; } if (in != NULL) { req->tmpbb = apr_brigade_create(pool, in->bucket_alloc); req->body = apr_table_make(pool, APREQ_DEFAULT_NELTS); req->body_status = APR_INCOMPLETE; } else { req->body = NULL; req->body_status = APREQ_ERROR_NODATA; } return &req->handle; } rapache-1.2.8/libapreq2/library/param.c0000644000175100017510000001643012706745114017257 0ustar ondrejondrej/* ** Copyright 2003-2005 The Apache Software Foundation ** ** Licensed under the Apache License, Version 2.0 (the "License"); ** you may not use this file except in compliance with the License. ** You may obtain a copy of the License at ** ** http://www.apache.org/licenses/LICENSE-2.0 ** ** Unless required by applicable law or agreed to in writing, software ** distributed under the License is distributed on an "AS IS" BASIS, ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ** See the License for the specific language governing permissions and ** limitations under the License. */ #include "apreq_param.h" #include "apreq_error.h" #include "apreq_util.h" #include "apr_strings.h" #include "apr_lib.h" #define MAX_LEN (1024 * 1024) #define MAX_BRIGADE_LEN (1024 * 256) #define MAX_READ_AHEAD (1024 * 64) APREQ_DECLARE(apreq_param_t *) apreq_param_make(apr_pool_t *p, const char *name, const apr_size_t nlen, const char *val, const apr_size_t vlen) { apreq_param_t *param; apreq_value_t *v; param = apr_palloc(p, nlen + vlen + 1 + sizeof *param); if (param == NULL) return NULL; param->info = NULL; param->upload = NULL; param->flags = 0; *(const apreq_value_t **)&v = ¶m->v; if (vlen && val != NULL) memcpy(v->data, val, vlen); v->data[vlen] = 0; v->dlen = vlen; v->name = v->data + vlen + 1; if (nlen && name != NULL) memcpy(v->name, name, nlen); v->name[nlen] = 0; v->nlen = nlen; return param; } APREQ_DECLARE(apr_status_t) apreq_param_decode(apreq_param_t **param, apr_pool_t *pool, const char *word, apr_size_t nlen, apr_size_t vlen) { apr_status_t status; apreq_value_t *v; apreq_param_t *p; apreq_charset_t charset; if (nlen == 0) { *param = NULL; return APR_EBADARG; } p = apr_palloc(pool, nlen + vlen + 1 + sizeof *p); p->info = NULL; p->upload = NULL; p->flags = 0; *(const apreq_value_t **)&v = &p->v; if (vlen > 0) { status = apreq_decode(v->data, &v->dlen, word + nlen + 1, vlen); if (status > APR_SUCCESS + APREQ_CHARSET_UTF8) { *param = NULL; return status; } charset = status; } else { v->data[0] = 0; v->dlen = 0; charset = APREQ_CHARSET_ASCII; } v->name = v->data + vlen + 1; status = apreq_decode(v->name, &v->nlen, word, nlen); if (status > APR_SUCCESS + APREQ_CHARSET_UTF8) { *param = NULL; return status; } switch (status) { case APREQ_CHARSET_UTF8: if (charset == APREQ_CHARSET_ASCII) charset = APREQ_CHARSET_UTF8; case APREQ_CHARSET_ASCII: break; case APREQ_CHARSET_LATIN1: if (charset != APREQ_CHARSET_CP1252) charset = APREQ_CHARSET_LATIN1; break; case APREQ_CHARSET_CP1252: charset = APREQ_CHARSET_CP1252; } apreq_param_charset_set(p, charset); *param = p; return APR_SUCCESS; } APREQ_DECLARE(char *) apreq_param_encode(apr_pool_t *pool, const apreq_param_t *param) { apr_size_t dlen; char *data; data = apr_palloc(pool, 3 * (param->v.nlen + param->v.dlen) + 2); dlen = apreq_encode(data, param->v.name, param->v.nlen); data[dlen++] = '='; dlen += apreq_encode(data + dlen, param->v.data, param->v.dlen); return data; } APREQ_DECLARE(apr_status_t) apreq_parse_query_string(apr_pool_t *pool, apr_table_t *t, const char *qs) { const char *start = qs; apr_size_t nlen = 0; for (;;++qs) { switch (*qs) { case '=': if (nlen == 0) { nlen = qs - start; } break; case '&': case ';': case 0: if (qs > start) { apr_size_t vlen = 0; apreq_param_t *param; apr_status_t s; if (nlen == 0) nlen = qs - start; else vlen = qs - start - nlen - 1; s = apreq_param_decode(¶m, pool, start, nlen, vlen); if (s != APR_SUCCESS) return s; apreq_param_tainted_on(param); apreq_value_table_add(¶m->v, t); } if (*qs == 0) return APR_SUCCESS; nlen = 0; start = qs + 1; } } /* not reached */ return APR_INCOMPLETE; } static int param_push(void *data, const char *key, const char *val) { apr_array_header_t *arr = data; *(apreq_param_t **)apr_array_push(arr) = apreq_value_to_param(val); return 1; /* keep going */ } APREQ_DECLARE(apr_array_header_t *) apreq_params_as_array(apr_pool_t *p, const apr_table_t *t, const char *key) { apr_array_header_t *arr; arr = apr_array_make(p, apr_table_elts(t)->nelts, sizeof(apreq_param_t *)); apr_table_do(param_push, arr, t, key, NULL); return arr; } APREQ_DECLARE(const char *) apreq_params_as_string(apr_pool_t *p, const apr_table_t *t, const char *key, apreq_join_t mode) { apr_array_header_t *arr = apreq_params_as_array(p, t, key); apreq_param_t **elt = (apreq_param_t **)arr->elts; apreq_param_t **const end = elt + arr->nelts; if (arr->nelts == 0) return apr_pstrdup(p, ""); while (elt < end) { *(const apreq_value_t **)elt = &(**elt).v; ++elt; } return apreq_join(p, ", ", arr, mode); } static int upload_push(void *data, const char *key, const char *val) { apr_table_t *t = data; apreq_param_t *p = apreq_value_to_param(val); if (p->upload != NULL) apreq_value_table_add(&p->v, t); return 1; /* keep going */ } APREQ_DECLARE(const apr_table_t *) apreq_uploads(const apr_table_t *body, apr_pool_t *pool) { apr_table_t *t = apr_table_make(pool, APREQ_DEFAULT_NELTS); apr_table_do(upload_push, t, body, NULL); return t; } static int upload_set(void *data, const char *key, const char *val) { const apreq_param_t **q = data; apreq_param_t *p = apreq_value_to_param(val); if (p->upload != NULL) { *q = p; return 0; /* upload found, stop */ } else return 1; /* keep searching */ } APREQ_DECLARE(const apreq_param_t *) apreq_upload(const apr_table_t *body, const char *name) { apreq_param_t *param = NULL; apr_table_do(upload_set, ¶m, body, name, NULL); return param; } rapache-1.2.8/libapreq2/library/parser.c0000644000175100017510000002227112706745114017453 0ustar ondrejondrej/* ** Copyright 2003-2005 The Apache Software Foundation ** ** Licensed under the Apache License, Version 2.0 (the "License"); ** you may not use this file except in compliance with the License. ** You may obtain a copy of the License at ** ** http://www.apache.org/licenses/LICENSE-2.0 ** ** Unless required by applicable law or agreed to in writing, software ** distributed under the License is distributed on an "AS IS" BASIS, ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ** See the License for the specific language governing permissions and ** limitations under the License. */ #include "apreq_error.h" #include "apreq_parser.h" #include "apreq_util.h" #include "apr_strings.h" #include "apr_xml.h" #include "apr_hash.h" #define PARSER_STATUS_CHECK(PREFIX) do { \ if (ctx->status == PREFIX##_ERROR) \ return APREQ_ERROR_GENERAL; \ else if (ctx->status == PREFIX##_COMPLETE) \ return APR_SUCCESS; \ else if (bb == NULL) \ return APR_INCOMPLETE; \ } while (0); APREQ_DECLARE(apreq_parser_t *) apreq_parser_make(apr_pool_t *pool, apr_bucket_alloc_t *ba, const char *content_type, apreq_parser_function_t pfn, apr_size_t brigade_limit, const char *temp_dir, apreq_hook_t *hook, void *ctx) { apreq_parser_t *p = apr_palloc(pool, sizeof *p); p->content_type = content_type; p->parser = pfn; p->hook = hook; p->pool = pool; p->bucket_alloc = ba; p->brigade_limit = brigade_limit; p->temp_dir = temp_dir; p->ctx = ctx; return p; } APREQ_DECLARE(apreq_hook_t *) apreq_hook_make(apr_pool_t *pool, apreq_hook_function_t hook, apreq_hook_t *next, void *ctx) { apreq_hook_t *h = apr_palloc(pool, sizeof *h); h->hook = hook; h->next = next; h->pool = pool; h->ctx = ctx; return h; } /*XXX this may need to check the parser's state before modifying the hook list */ APREQ_DECLARE(apr_status_t) apreq_parser_add_hook(apreq_parser_t *p, apreq_hook_t *h) { apreq_hook_t *last = h; while (last->next) last = last->next; last->next = p->hook; p->hook = h; return APR_SUCCESS; } static int default_parsers_lock = 0; static apr_hash_t *default_parsers = NULL; static apr_pool_t *default_parser_pool = NULL; static apr_status_t apreq_parsers_cleanup(void *data) { default_parsers_lock = 0; default_parsers = NULL; default_parser_pool = NULL; return APR_SUCCESS; } APREQ_DECLARE(apr_status_t) apreq_pre_initialize(apr_pool_t *pool) { apr_status_t status; if (default_parser_pool != NULL) return APR_SUCCESS; if (default_parsers_lock) return APREQ_ERROR_GENERAL; status = apr_pool_create(&default_parser_pool, pool); if (status != APR_SUCCESS) return status; apr_pool_cleanup_register(default_parser_pool, NULL, apreq_parsers_cleanup, apr_pool_cleanup_null); default_parsers = apr_hash_make(default_parser_pool); apreq_register_parser("application/x-www-form-urlencoded", apreq_parse_urlencoded); apreq_register_parser("multipart/form-data", apreq_parse_multipart); apreq_register_parser("multipart/related", apreq_parse_multipart); return APR_SUCCESS; } APREQ_DECLARE(apr_status_t) apreq_post_initialize(apr_pool_t *pool) { (void)pool; if (default_parser_pool == NULL) return APREQ_ERROR_GENERAL; default_parsers_lock = 1; return APR_SUCCESS; } APREQ_DECLARE(apr_status_t) apreq_initialize(apr_pool_t *pool) { apr_status_t s = apreq_pre_initialize(pool); if (s != APR_SUCCESS) return s; return apreq_post_initialize(pool); } APREQ_DECLARE(apr_status_t) apreq_register_parser(const char *enctype, apreq_parser_function_t pfn) { apreq_parser_function_t *f = NULL; if (default_parsers == NULL) return APR_EINIT; if (enctype == NULL) return APR_EINVAL; if (default_parsers_lock) return APREQ_ERROR_GENERAL; if (pfn != NULL) { f = apr_palloc(default_parser_pool, sizeof *f); *f = pfn; } apr_hash_set(default_parsers, apr_pstrdup(default_parser_pool, enctype), APR_HASH_KEY_STRING, f); return APR_SUCCESS; } APREQ_DECLARE(apreq_parser_function_t)apreq_parser(const char *enctype) { apreq_parser_function_t *f; apr_size_t tlen = 0; if (enctype == NULL || default_parsers_lock == 0) return NULL; while(enctype[tlen] && enctype[tlen] != ';') ++tlen; f = apr_hash_get(default_parsers, enctype, tlen); if (f != NULL) return *f; else return NULL; } APREQ_DECLARE_HOOK(apreq_hook_disable_uploads) { return (bb == NULL) ? APR_SUCCESS : APREQ_ERROR_GENERAL; } APREQ_DECLARE_HOOK(apreq_hook_discard_brigade) { apr_status_t s = APR_SUCCESS; if (hook->next) s = apreq_hook_run(hook->next, param, bb); if (bb != NULL) apr_brigade_cleanup(bb); return s; } /* generic parser */ struct gen_ctx { apreq_param_t *param; enum { GEN_INCOMPLETE, GEN_COMPLETE, GEN_ERROR } status; }; APREQ_DECLARE_PARSER(apreq_parse_generic) { struct gen_ctx *ctx = parser->ctx; apr_pool_t *pool = parser->pool; apr_status_t s = APR_SUCCESS; apr_bucket *e = APR_BRIGADE_LAST(bb); unsigned saw_eos = 0; if (ctx == NULL) { parser->ctx = ctx = apr_palloc(pool, sizeof *ctx); ctx->status = GEN_INCOMPLETE; ctx->param = apreq_param_make(pool, "_dummy_", strlen("_dummy_"), "", 0); ctx->param->upload = apr_brigade_create(pool, parser->bucket_alloc); ctx->param->info = apr_table_make(pool, APREQ_DEFAULT_NELTS); } PARSER_STATUS_CHECK(GEN); while (e != APR_BRIGADE_SENTINEL(bb)) { if (APR_BUCKET_IS_EOS(e)) { saw_eos = 1; break; } e = APR_BUCKET_PREV(e); } if (parser->hook != NULL) { s = apreq_hook_run(parser->hook, ctx->param, bb); if (s != APR_SUCCESS) { ctx->status = GEN_ERROR; return s; } } apreq_brigade_setaside(bb, pool); s = apreq_brigade_concat(pool, parser->temp_dir, parser->brigade_limit, ctx->param->upload, bb); if (s != APR_SUCCESS) { ctx->status = GEN_ERROR; return s; } if (saw_eos) { ctx->status = GEN_COMPLETE; return APR_SUCCESS; } else return APR_INCOMPLETE; } struct xml_ctx { apr_xml_doc *doc; apr_xml_parser *xml_parser; enum { XML_INCOMPLETE, XML_COMPLETE, XML_ERROR } status; }; APREQ_DECLARE_HOOK(apreq_hook_apr_xml_parser) { apr_pool_t *pool = hook->pool; struct xml_ctx *ctx = hook->ctx; apr_status_t s = APR_SUCCESS; apr_bucket *e; if (ctx == NULL) { hook->ctx = ctx = apr_palloc(pool, sizeof *ctx); ctx->doc = NULL; ctx->xml_parser = apr_xml_parser_create(pool); ctx->status = XML_INCOMPLETE; } PARSER_STATUS_CHECK(XML); for (e = APR_BRIGADE_FIRST(bb); e != APR_BRIGADE_SENTINEL(bb); e = APR_BUCKET_NEXT(e)) { const char *data; apr_size_t dlen; if (APR_BUCKET_IS_EOS(e)) { s = apr_xml_parser_done(ctx->xml_parser, &ctx->doc); if (s == APR_SUCCESS) { ctx->status = XML_COMPLETE; if (hook->next) s = apreq_hook_run(hook->next, param, bb); } else { ctx->status = XML_ERROR; } return s; } else if (APR_BUCKET_IS_METADATA(e)) { continue; } s = apr_bucket_read(e, &data, &dlen, APR_BLOCK_READ); if (s != APR_SUCCESS) { ctx->status = XML_ERROR; return s; } s = apr_xml_parser_feed(ctx->xml_parser, data, dlen); if (s != APR_SUCCESS) { ctx->status = XML_ERROR; return s; } } if (hook->next) return apreq_hook_run(hook->next, param, bb); return APR_SUCCESS; } APREQ_DECLARE_HOOK(apreq_hook_find_param) { const char *key = hook->ctx; int is_final = (bb == NULL) || APR_BUCKET_IS_EOS(APR_BRIGADE_LAST(bb)); apr_status_t s = (hook->next == NULL) ? APR_SUCCESS : apreq_hook_run(hook->next, param, bb); if (is_final && strcasecmp(key, param->v.name) == 0) hook->ctx = param; return s; } rapache-1.2.8/libapreq2/library/parser_header.c0000644000175100017510000002216212706745114020762 0ustar ondrejondrej/* ** Copyright 2003-2005 The Apache Software Foundation ** ** Licensed under the Apache License, Version 2.0 (the "License"); ** you may not use this file except in compliance with the License. ** You may obtain a copy of the License at ** ** http://www.apache.org/licenses/LICENSE-2.0 ** ** Unless required by applicable law or agreed to in writing, software ** distributed under the License is distributed on an "AS IS" BASIS, ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ** See the License for the specific language governing permissions and ** limitations under the License. */ #include #include "apreq_parser.h" #include "apreq_error.h" #include "apreq_util.h" #define PARSER_STATUS_CHECK(PREFIX) do { \ if (ctx->status == PREFIX##_ERROR) \ return APREQ_ERROR_GENERAL; \ else if (ctx->status == PREFIX##_COMPLETE) \ return APR_SUCCESS; \ else if (bb == NULL) \ return APR_INCOMPLETE; \ } while (0); struct hdr_ctx { apr_bucket_brigade *bb; enum { HDR_NAME, HDR_GAP, HDR_VALUE, HDR_NEWLINE, HDR_CONTINUE, HDR_COMPLETE, HDR_ERROR } status; }; /********************* header parsing utils ********************/ static apr_status_t split_header_line(apreq_param_t **p, apr_pool_t *pool, apr_bucket_brigade *bb, apr_size_t nlen, apr_size_t glen, apr_size_t vlen) { apreq_param_t *param; apreq_value_t *v; apr_bucket *e, *f; apr_status_t s; struct iovec vec[APREQ_DEFAULT_NELTS], *iov, *end; apr_array_header_t arr; char *dest; const char *data; apr_size_t dlen; if (nlen == 0) return APR_EBADARG; param = apreq_param_make(pool, NULL, nlen, NULL, vlen - 1); /*drop (CR)LF */ *(const apreq_value_t **)&v = ¶m->v; arr.pool = pool; arr.elt_size = sizeof(struct iovec); arr.nelts = 0; arr.nalloc = APREQ_DEFAULT_NELTS; arr.elts = (char *)vec; e = APR_BRIGADE_FIRST(bb); /* store name in a temporary iovec array */ while (nlen > 0) { apr_size_t len; end = apr_array_push(&arr); s = apr_bucket_read(e, (const char **)&end->iov_base, &len, APR_BLOCK_READ); if (s != APR_SUCCESS) return s; assert(nlen >= len); end->iov_len = len; nlen -= len; e = APR_BUCKET_NEXT(e); } /* skip gap */ while (glen > 0) { s = apr_bucket_read(e, &data, &dlen, APR_BLOCK_READ); if (s != APR_SUCCESS) return s; assert(glen >= dlen); glen -= dlen; e = APR_BUCKET_NEXT(e); } /* copy value */ assert(vlen > 0); dest = v->data; while (vlen > 0) { s = apr_bucket_read(e, &data, &dlen, APR_BLOCK_READ); if (s != APR_SUCCESS) return s; memcpy(dest, data, dlen); dest += dlen; assert(vlen >= dlen); vlen -= dlen; e = APR_BUCKET_NEXT(e); } assert(dest[-1] == '\n'); if (dest[-2] == '\r') --dest; dest[-1] = 0; v->dlen = (dest - v->data) - 1; /* write name */ v->name = dest; iov = (struct iovec *)arr.elts; while (iov <= end) { memcpy(dest, iov->iov_base, iov->iov_len); dest += iov->iov_len; ++iov; } *dest = 0; nlen = dest - v->name; while ((f = APR_BRIGADE_FIRST(bb)) != e) apr_bucket_delete(f); apreq_param_tainted_on(param); *p = param; return APR_SUCCESS; } APREQ_DECLARE_PARSER(apreq_parse_headers) { apr_pool_t *pool = parser->pool; apr_ssize_t nlen, glen, vlen; apr_bucket *e; struct hdr_ctx *ctx; if (parser->ctx == NULL) { ctx = apr_pcalloc(pool, sizeof *ctx); ctx->bb = apr_brigade_create(pool, parser->bucket_alloc); parser->ctx = ctx; } else ctx = parser->ctx; PARSER_STATUS_CHECK(HDR); APR_BRIGADE_CONCAT(ctx->bb, bb); parse_hdr_brigade: ctx->status = HDR_NAME; /* parse the brigade for CRLF_CRLF-terminated header block, * each time starting from the front of the brigade. */ for (e = APR_BRIGADE_FIRST(ctx->bb), nlen = glen = vlen = 0; e != APR_BRIGADE_SENTINEL(ctx->bb); e = APR_BUCKET_NEXT(e)) { apr_size_t off = 0, dlen; const char *data; apr_status_t s; apreq_param_t *param; if (APR_BUCKET_IS_EOS(e)) { ctx->status = HDR_COMPLETE; APR_BRIGADE_CONCAT(bb, ctx->bb); return APR_SUCCESS; } s = apr_bucket_read(e, &data, &dlen, APR_BLOCK_READ); if ( s != APR_SUCCESS ) { ctx->status = HDR_ERROR; return s; } if (dlen == 0) continue; parse_hdr_bucket: /* gap nlen = 13 * vvv glen = 3 * Sample-Header: grape vlen = 5 * ^^^^^^^^^^^^^ ^^^^^ * name value */ switch (ctx->status) { case HDR_NAME: while (off < dlen) { switch (data[off++]) { case '\n': if (off < dlen) apr_bucket_split(e, off); e = APR_BUCKET_NEXT(e); do { apr_bucket *f = APR_BRIGADE_FIRST(ctx->bb); apr_bucket_delete(f); } while (e != APR_BRIGADE_FIRST(ctx->bb)); APR_BRIGADE_CONCAT(bb, ctx->bb); ctx->status = HDR_COMPLETE; return APR_SUCCESS; case ':': if (off > 1) { apr_bucket_split(e, off - 1); dlen -= off - 1; data += off - 1; off = 1; e = APR_BUCKET_NEXT(e); } ++glen; ctx->status = HDR_GAP; goto parse_hdr_bucket; default: ++nlen; } } break; case HDR_GAP: while (off < dlen) { switch (data[off++]) { case ' ': case '\t': ++glen; break; case '\n': ctx->status = HDR_NEWLINE; goto parse_hdr_bucket; default: ctx->status = HDR_VALUE; if (off > 1) { apr_bucket_split(e, off - 1); dlen -= off - 1; data += off - 1; off = 1; e = APR_BUCKET_NEXT(e); } ++vlen; goto parse_hdr_bucket; } } break; case HDR_VALUE: while (off < dlen) { ++vlen; if (data[off++] == '\n') { ctx->status = HDR_NEWLINE; goto parse_hdr_bucket; } } break; case HDR_NEWLINE: if (off == dlen) break; else { switch (data[off]) { case ' ': case '\t': ctx->status = HDR_CONTINUE; ++off; vlen += 2; break; default: /* can parse brigade now */ if (off > 0) apr_bucket_split(e, off); s = split_header_line(¶m, pool, ctx->bb, nlen, glen, vlen); if (parser->hook != NULL && s == APR_SUCCESS) s = apreq_hook_run(parser->hook, param, NULL); if (s != APR_SUCCESS) { ctx->status = HDR_ERROR; return s; } apreq_value_table_add(¶m->v, t); goto parse_hdr_brigade; } /* cases ' ', '\t' fall through to HDR_CONTINUE */ } case HDR_CONTINUE: while (off < dlen) { switch (data[off++]) { case ' ': case '\t': ++vlen; break; case '\n': ctx->status = HDR_NEWLINE; goto parse_hdr_bucket; default: ctx->status = HDR_VALUE; ++vlen; goto parse_hdr_bucket; } } break; default: ; /* not reached */ } } apreq_brigade_setaside(ctx->bb,pool); return APR_INCOMPLETE; } rapache-1.2.8/libapreq2/library/parser_multipart.c0000644000175100017510000004743112706745114021561 0ustar ondrejondrej/* ** Copyright 2003-2005 The Apache Software Foundation ** ** Licensed under the Apache License, Version 2.0 (the "License"); ** you may not use this file except in compliance with the License. ** You may obtain a copy of the License at ** ** http://www.apache.org/licenses/LICENSE-2.0 ** ** Unless required by applicable law or agreed to in writing, software ** distributed under the License is distributed on an "AS IS" BASIS, ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ** See the License for the specific language governing permissions and ** limitations under the License. */ #include "apreq_parser.h" #include "apreq_error.h" #include "apreq_util.h" #include "apr_strings.h" #include "apr_strmatch.h" #ifndef CRLF #define CRLF "\015\012" #endif #define MIN(a, b) (((a) < (b)) ? (a) : (b)) #define PARSER_STATUS_CHECK(PREFIX) do { \ if (ctx->status == PREFIX##_ERROR) \ return APREQ_ERROR_GENERAL; \ else if (ctx->status == PREFIX##_COMPLETE) \ return APR_SUCCESS; \ else if (bb == NULL) \ return APR_INCOMPLETE; \ } while (0); struct mfd_ctx { apr_table_t *info; apr_bucket_brigade *in; apr_bucket_brigade *bb; apreq_parser_t *hdr_parser; apreq_parser_t *mix_parser; const apr_strmatch_pattern *pattern; char *bdry; enum { MFD_INIT, MFD_NEXTLINE, MFD_HEADER, MFD_POST_HEADER, MFD_PARAM, MFD_UPLOAD, MFD_MIXED, MFD_COMPLETE, MFD_ERROR } status; apr_bucket *eos; char *param_name; apreq_param_t *upload; }; /********************* multipart/form-data *********************/ APR_INLINE static apr_status_t brigade_start_string(apr_bucket_brigade *bb, const char *start_string) { apr_bucket *e; apr_size_t slen = strlen(start_string); for (e = APR_BRIGADE_FIRST(bb); e != APR_BRIGADE_SENTINEL(bb); e = APR_BUCKET_NEXT(e)) { const char *buf; apr_status_t s, bytes_to_check; apr_size_t blen; if (slen == 0) return APR_SUCCESS; if (APR_BUCKET_IS_EOS(e)) return APR_EOF; s = apr_bucket_read(e, &buf, &blen, APR_BLOCK_READ); if (s != APR_SUCCESS) return s; if (blen == 0) continue; bytes_to_check = MIN(slen,blen); if (strncmp(buf,start_string,bytes_to_check) != 0) return APREQ_ERROR_GENERAL; slen -= bytes_to_check; start_string += bytes_to_check; } /* slen > 0, so brigade isn't large enough yet */ return APR_INCOMPLETE; } static apr_status_t split_on_bdry(apr_bucket_brigade *out, apr_bucket_brigade *in, const apr_strmatch_pattern *pattern, const char *bdry) { apr_bucket *e = APR_BRIGADE_FIRST(in); apr_size_t blen = strlen(bdry), off = 0; while ( e != APR_BRIGADE_SENTINEL(in) ) { apr_ssize_t idx; apr_size_t len; const char *buf; apr_status_t s; if (APR_BUCKET_IS_EOS(e)) return APR_EOF; s = apr_bucket_read(e, &buf, &len, APR_BLOCK_READ); if (s != APR_SUCCESS) return s; if (len == 0) { apr_bucket *f = e; e = APR_BUCKET_NEXT(e); apr_bucket_delete(f); continue; } look_for_boundary_up_front: if (strncmp(bdry + off, buf, MIN(len, blen - off)) == 0) { if ( len >= blen - off ) { /* complete match */ if (len > blen - off) apr_bucket_split(e, blen - off); e = APR_BUCKET_NEXT(e); do { apr_bucket *f = APR_BRIGADE_FIRST(in); apr_bucket_delete(f); } while (APR_BRIGADE_FIRST(in) != e); return APR_SUCCESS; } /* partial match */ off += len; e = APR_BUCKET_NEXT(e); continue; } else if (off > 0) { /* prior (partial) strncmp failed, * so we can move previous buckets across * and retest buf against the full bdry. */ do { apr_bucket *f = APR_BRIGADE_FIRST(in); APR_BUCKET_REMOVE(f); APR_BRIGADE_INSERT_TAIL(out, f); } while (e != APR_BRIGADE_FIRST(in)); off = 0; goto look_for_boundary_up_front; } if (pattern != NULL && len >= blen) { const char *match = apr_strmatch(pattern, buf, len); if (match != NULL) idx = match - buf; else { idx = apreq_index(buf + len-blen, blen, bdry, blen, APREQ_MATCH_PARTIAL); if (idx >= 0) idx += len-blen; } } else idx = apreq_index(buf, len, bdry, blen, APREQ_MATCH_PARTIAL); /* Theoretically idx should never be 0 here, because we * already tested the front of the brigade for a potential match. * However, it doesn't hurt to allow for the possibility, * since this will just start the whole loop over again. */ if (idx >= 0) apr_bucket_split(e, idx); APR_BUCKET_REMOVE(e); APR_BRIGADE_INSERT_TAIL(out, e); e = APR_BRIGADE_FIRST(in); } return APR_INCOMPLETE; } static struct mfd_ctx * create_multipart_context(const char *content_type, apr_pool_t *pool, apr_bucket_alloc_t *ba, apr_size_t brigade_limit, const char *temp_dir) { apr_status_t s; apr_size_t blen; struct mfd_ctx *ctx = apr_palloc(pool, sizeof *ctx); char *ct = apr_pstrdup(pool, content_type); ct = strchr(ct, ';'); if (ct == NULL) return NULL; /* missing semicolon */ *ct++ = 0; s = apreq_header_attribute(ct, "boundary", 8, (const char **)&ctx->bdry, &blen); if (s != APR_SUCCESS) return NULL; /* missing boundary */ ctx->bdry[blen] = 0; *--ctx->bdry = '-'; *--ctx->bdry = '-'; *--ctx->bdry = '\n'; *--ctx->bdry = '\r'; ctx->status = MFD_INIT; ctx->pattern = apr_strmatch_precompile(pool, ctx->bdry, 1); ctx->hdr_parser = apreq_parser_make(pool, ba, "", apreq_parse_headers, brigade_limit, temp_dir, NULL, NULL); ctx->info = NULL; ctx->bb = apr_brigade_create(pool, ba); ctx->in = apr_brigade_create(pool, ba); ctx->eos = apr_bucket_eos_create(ba); ctx->mix_parser = NULL; ctx->param_name = NULL; ctx->upload = NULL; return ctx; } APREQ_DECLARE_PARSER(apreq_parse_multipart) { apr_pool_t *pool = parser->pool; apr_bucket_alloc_t *ba = parser->bucket_alloc; struct mfd_ctx *ctx = parser->ctx; apr_status_t s; if (ctx == NULL) { ctx = create_multipart_context(parser->content_type, pool, ba, parser->brigade_limit, parser->temp_dir); if (ctx == NULL) return APREQ_ERROR_GENERAL; ctx->mix_parser = apreq_parser_make(pool, ba, "", apreq_parse_multipart, parser->brigade_limit, parser->temp_dir, parser->hook, NULL); parser->ctx = ctx; } PARSER_STATUS_CHECK(MFD); APR_BRIGADE_CONCAT(ctx->in, bb); mfd_parse_brigade: switch (ctx->status) { case MFD_INIT: { s = split_on_bdry(ctx->bb, ctx->in, NULL, ctx->bdry + 2); if (s != APR_SUCCESS) { apreq_brigade_setaside(ctx->in, pool); apreq_brigade_setaside(ctx->bb, pool); return s; } ctx->status = MFD_NEXTLINE; /* Be polite and return any preamble text to the caller. */ APR_BRIGADE_CONCAT(bb, ctx->bb); } /* fall through */ case MFD_NEXTLINE: { s = split_on_bdry(ctx->bb, ctx->in, NULL, CRLF); if (s != APR_SUCCESS) { apreq_brigade_setaside(ctx->in, pool); apreq_brigade_setaside(ctx->bb, pool); return s; } if (!APR_BRIGADE_EMPTY(ctx->bb)) { /* ctx->bb probably contains "--", but we'll stop here * without bothering to check, and just * return any postamble text to caller. */ APR_BRIGADE_CONCAT(bb, ctx->in); ctx->status = MFD_COMPLETE; return APR_SUCCESS; } ctx->status = MFD_HEADER; ctx->info = NULL; } /* fall through */ case MFD_HEADER: { if (ctx->info == NULL) { ctx->info = apr_table_make(pool, APREQ_DEFAULT_NELTS); /* flush out old header parser internal structs for reuse */ ctx->hdr_parser->ctx = NULL; } s = apreq_parser_run(ctx->hdr_parser, ctx->info, ctx->in); switch (s) { case APR_SUCCESS: ctx->status = MFD_POST_HEADER; break; case APR_INCOMPLETE: apreq_brigade_setaside(ctx->in, pool); return APR_INCOMPLETE; default: ctx->status = MFD_ERROR; return s; } } /* fall through */ case MFD_POST_HEADER: { /* Must handle special case of missing CRLF (mainly coming from empty file uploads). See RFC2065 S5.1.1: body-part = MIME-part-header [CRLF *OCTET] So the CRLF we already matched in MFD_HEADER may have been part of the boundary string! Both Konqueror (v??) and Mozilla-0.97 are known to emit such blocks. Here we first check for this condition with brigade_start_string, and prefix the brigade with an additional CRLF bucket if necessary. */ const char *cd, *name, *filename; apr_size_t nlen, flen; apr_bucket *e; switch (brigade_start_string(ctx->in, ctx->bdry + 2)) { case APR_INCOMPLETE: apreq_brigade_setaside(ctx->in, pool); return APR_INCOMPLETE; case APR_SUCCESS: /* part has no body- return CRLF to front */ e = apr_bucket_immortal_create(CRLF, 2, ctx->bb->bucket_alloc); APR_BRIGADE_INSERT_HEAD(ctx->in,e); break; default: ; /* has body, ok */ } cd = apr_table_get(ctx->info, "Content-Disposition"); if (cd != NULL) { if (ctx->mix_parser != NULL) { /* multipart/form-data */ s = apreq_header_attribute(cd, "name", 4, &name, &nlen); if (s != APR_SUCCESS) { ctx->status = MFD_ERROR; return APREQ_ERROR_GENERAL; } s = apreq_header_attribute(cd, "filename", 8, &filename, &flen); if (s != APR_SUCCESS) { const char *ct = apr_table_get(ctx->info, "Content-Type"); if (ct != NULL && strncmp(ct, "multipart/mixed", 15) == 0) { struct mfd_ctx *mix_ctx; mix_ctx = create_multipart_context(ct, pool, ba, parser->brigade_limit, parser->temp_dir); if (mix_ctx == NULL) { ctx->status = MFD_ERROR; return APREQ_ERROR_GENERAL; } mix_ctx->param_name = apr_pstrmemdup(pool, name, nlen); ctx->mix_parser->ctx = mix_ctx; ctx->status = MFD_MIXED; goto mfd_parse_brigade; } ctx->param_name = apr_pstrmemdup(pool, name, nlen); ctx->status = MFD_PARAM; } else { apreq_param_t *param; param = apreq_param_make(pool, name, nlen, filename, flen); apreq_param_tainted_on(param); param->info = ctx->info; param->upload = apr_brigade_create(pool, ctx->bb->bucket_alloc); ctx->upload = param; ctx->status = MFD_UPLOAD; goto mfd_parse_brigade; } } else { /* multipart/mixed */ s = apreq_header_attribute(cd, "filename", 8, &filename, &flen); if (s != APR_SUCCESS) { ctx->status = MFD_PARAM; } else { apreq_param_t *param; name = ctx->param_name; nlen = strlen(name); param = apreq_param_make(pool, name, nlen, filename, flen); apreq_param_tainted_on(param); param->info = ctx->info; param->upload = apr_brigade_create(pool, ctx->bb->bucket_alloc); ctx->upload = param; ctx->status = MFD_UPLOAD; goto mfd_parse_brigade; } } } else { /* multipart/related */ apreq_param_t *param; cd = apr_table_get(ctx->info, "Content-ID"); if (cd == NULL) { ctx->status = MFD_ERROR; return APREQ_ERROR_GENERAL; } name = cd; nlen = strlen(name); filename = ""; flen = 0; param = apreq_param_make(pool, name, nlen, filename, flen); apreq_param_tainted_on(param); param->info = ctx->info; param->upload = apr_brigade_create(pool, ctx->bb->bucket_alloc); ctx->upload = param; ctx->status = MFD_UPLOAD; goto mfd_parse_brigade; } } /* fall through */ case MFD_PARAM: { apreq_param_t *param; apreq_value_t *v; apr_size_t len; apr_off_t off; s = split_on_bdry(ctx->bb, ctx->in, ctx->pattern, ctx->bdry); switch (s) { case APR_INCOMPLETE: apreq_brigade_setaside(ctx->in, pool); apreq_brigade_setaside(ctx->bb, pool); return s; case APR_SUCCESS: s = apr_brigade_length(ctx->bb, 1, &off); if (s != APR_SUCCESS) { ctx->status = MFD_ERROR; return s; } len = off; param = apreq_param_make(pool, ctx->param_name, strlen(ctx->param_name), NULL, len); apreq_param_tainted_on(param); param->info = ctx->info; *(const apreq_value_t **)&v = ¶m->v; apr_brigade_flatten(ctx->bb, v->data, &len); v->data[len] = 0; if (parser->hook != NULL) { s = apreq_hook_run(parser->hook, param, NULL); if (s != APR_SUCCESS) { ctx->status = MFD_ERROR; return s; } } apreq_value_table_add(v, t); ctx->status = MFD_NEXTLINE; ctx->param_name = NULL; apr_brigade_cleanup(ctx->bb); goto mfd_parse_brigade; default: ctx->status = MFD_ERROR; return s; } } break; /* not reached */ case MFD_UPLOAD: { apreq_param_t *param = ctx->upload; s = split_on_bdry(ctx->bb, ctx->in, ctx->pattern, ctx->bdry); switch (s) { case APR_INCOMPLETE: if (parser->hook != NULL) { s = apreq_hook_run(parser->hook, param, ctx->bb); if (s != APR_SUCCESS) { ctx->status = MFD_ERROR; return s; } } apreq_brigade_setaside(ctx->bb, pool); apreq_brigade_setaside(ctx->in, pool); s = apreq_brigade_concat(pool, parser->temp_dir, parser->brigade_limit, param->upload, ctx->bb); return (s == APR_SUCCESS) ? APR_INCOMPLETE : s; case APR_SUCCESS: if (parser->hook != NULL) { APR_BRIGADE_INSERT_TAIL(ctx->bb, ctx->eos); s = apreq_hook_run(parser->hook, param, ctx->bb); APR_BUCKET_REMOVE(ctx->eos); if (s != APR_SUCCESS) { ctx->status = MFD_ERROR; return s; } } apreq_value_table_add(¶m->v, t); apreq_brigade_setaside(ctx->bb, pool); s = apreq_brigade_concat(pool, parser->temp_dir, parser->brigade_limit, param->upload, ctx->bb); if (s != APR_SUCCESS) return s; ctx->status = MFD_NEXTLINE; goto mfd_parse_brigade; default: ctx->status = MFD_ERROR; return s; } } break; /* not reached */ case MFD_MIXED: { s = apreq_parser_run(ctx->mix_parser, t, ctx->in); switch (s) { case APR_SUCCESS: ctx->status = MFD_INIT; goto mfd_parse_brigade; case APR_INCOMPLETE: apr_brigade_cleanup(ctx->in); return APR_INCOMPLETE; default: ctx->status = MFD_ERROR; return s; } } break; /* not reached */ default: return APREQ_ERROR_GENERAL; } return APR_INCOMPLETE; } rapache-1.2.8/libapreq2/library/parser_urlencoded.c0000644000175100017510000001577312706745114021670 0ustar ondrejondrej/* ** Copyright 2003-2005 The Apache Software Foundation ** ** Licensed under the Apache License, Version 2.0 (the "License"); ** you may not use this file except in compliance with the License. ** You may obtain a copy of the License at ** ** http://www.apache.org/licenses/LICENSE-2.0 ** ** Unless required by applicable law or agreed to in writing, software ** distributed under the License is distributed on an "AS IS" BASIS, ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ** See the License for the specific language governing permissions and ** limitations under the License. */ #include "apreq_parser.h" #include "apreq_util.h" #include "apreq_error.h" #define PARSER_STATUS_CHECK(PREFIX) do { \ if (ctx->status == PREFIX##_ERROR) \ return APREQ_ERROR_GENERAL; \ else if (ctx->status == PREFIX##_COMPLETE) \ return APR_SUCCESS; \ else if (bb == NULL) \ return APR_INCOMPLETE; \ } while (0); struct url_ctx { apr_bucket_brigade *bb; enum { URL_NAME, URL_VALUE, URL_COMPLETE, URL_ERROR } status; }; /******************** application/x-www-form-urlencoded ********************/ static apr_status_t split_urlword(apreq_param_t **p, apr_pool_t *pool, apr_bucket_brigade *bb, apr_size_t nlen, apr_size_t vlen) { apreq_param_t *param; apreq_value_t *v; apr_bucket *e, *f; apr_status_t s; struct iovec vec[APREQ_DEFAULT_NELTS]; apr_array_header_t arr; apr_size_t mark; apreq_charset_t charset; if (nlen == 0) return APR_EBADARG; param = apreq_param_make(pool, NULL, nlen, NULL, vlen); *(const apreq_value_t **)&v = ¶m->v; arr.pool = pool; arr.elt_size = sizeof(struct iovec); arr.nelts = 0; arr.nalloc = APREQ_DEFAULT_NELTS; arr.elts = (char *)vec; ++nlen, ++vlen; e = APR_BRIGADE_FIRST(bb); while (!APR_BUCKET_IS_EOS(e)) { struct iovec *iov = apr_array_push(&arr); apr_size_t len; s = apr_bucket_read(e, (const char **)&iov->iov_base, &len, APR_BLOCK_READ); if (s != APR_SUCCESS) return s; iov->iov_len = len; nlen -= len; e = APR_BUCKET_NEXT(e); if (nlen == 0) { iov->iov_len--; break; } } mark = arr.nelts; while (!APR_BUCKET_IS_EOS(e)) { struct iovec *iov = apr_array_push(&arr); apr_size_t len; s = apr_bucket_read(e, (const char **)&iov->iov_base, &len, APR_BLOCK_READ); if (s != APR_SUCCESS) return s; iov->iov_len = len; vlen -= len; e = APR_BUCKET_NEXT(e); if (vlen == 0) { iov->iov_len--; break; } } s = apreq_decodev(v->data, &vlen, (struct iovec *)arr.elts + mark, arr.nelts - mark); if (s > APR_SUCCESS + APREQ_CHARSET_UTF8) return s; charset = s; v->name = v->data + vlen + 1; v->dlen = vlen; s = apreq_decodev(v->name, &nlen, (struct iovec *)arr.elts, mark); if (s > APR_SUCCESS + APREQ_CHARSET_UTF8) return s; switch (s) { case APREQ_CHARSET_UTF8: if (charset == APREQ_CHARSET_ASCII) charset = APREQ_CHARSET_UTF8; case APREQ_CHARSET_ASCII: break; case APREQ_CHARSET_LATIN1: if (charset != APREQ_CHARSET_CP1252) charset = APREQ_CHARSET_LATIN1; break; case APREQ_CHARSET_CP1252: charset = APREQ_CHARSET_CP1252; } v->nlen = nlen; while ((f = APR_BRIGADE_FIRST(bb)) != e) apr_bucket_delete(f); apreq_param_tainted_on(param); apreq_param_charset_set(param, charset); *p = param; return APR_SUCCESS; } APREQ_DECLARE_PARSER(apreq_parse_urlencoded) { apr_pool_t *pool = parser->pool; apr_ssize_t nlen, vlen; apr_bucket *e; struct url_ctx *ctx; if (parser->ctx == NULL) { ctx = apr_palloc(pool, sizeof *ctx); ctx->bb = apr_brigade_create(pool, parser->bucket_alloc); parser->ctx = ctx; ctx->status = URL_NAME; } else ctx = parser->ctx; PARSER_STATUS_CHECK(URL); APR_BRIGADE_CONCAT(ctx->bb, bb); parse_url_brigade: ctx->status = URL_NAME; for (e = APR_BRIGADE_FIRST(ctx->bb), nlen = vlen = 0; e != APR_BRIGADE_SENTINEL(ctx->bb); e = APR_BUCKET_NEXT(e)) { apreq_param_t *param; apr_size_t off = 0, dlen; const char *data; apr_status_t s; if (APR_BUCKET_IS_EOS(e)) { if (ctx->status == URL_NAME) { s = APR_SUCCESS; } else { s = split_urlword(¶m, pool, ctx->bb, nlen, vlen); if (parser->hook != NULL && s == APR_SUCCESS) s = apreq_hook_run(parser->hook, param, NULL); if (s == APR_SUCCESS) { apreq_value_table_add(¶m->v, t); ctx->status = URL_COMPLETE; } else { ctx->status = URL_ERROR; } } APR_BRIGADE_CONCAT(bb, ctx->bb); return s; } s = apr_bucket_read(e, &data, &dlen, APR_BLOCK_READ); if ( s != APR_SUCCESS ) { ctx->status = URL_ERROR; return s; } parse_url_bucket: switch (ctx->status) { case URL_NAME: while (off < dlen) { switch (data[off++]) { case '=': apr_bucket_split(e, off); dlen -= off; data += off; off = 0; e = APR_BUCKET_NEXT(e); ctx->status = URL_VALUE; goto parse_url_bucket; default: ++nlen; } } break; case URL_VALUE: while (off < dlen) { switch (data[off++]) { case '&': case ';': apr_bucket_split(e, off); s = split_urlword(¶m, pool, ctx->bb, nlen, vlen); if (parser->hook != NULL && s == APR_SUCCESS) s = apreq_hook_run(parser->hook, param, NULL); if (s != APR_SUCCESS) { ctx->status = URL_ERROR; return s; } apreq_value_table_add(¶m->v, t); goto parse_url_brigade; default: ++vlen; } } break; default: ; /* not reached */ } } apreq_brigade_setaside(ctx->bb, pool); return APR_INCOMPLETE; } rapache-1.2.8/libapreq2/library/t/0000755000175100017510000000000012706745114016252 5ustar ondrejondrejrapache-1.2.8/libapreq2/library/t/.deps/0000755000175100017510000000000012706745114017263 5ustar ondrejondrejrapache-1.2.8/libapreq2/library/t/.deps/at.Po0000644000175100017510000001407312706745114020174 0ustar ondrejondrejat.o: at.c /home/joe/httpd/trunk/worker/include/apr-1/apr_file_io.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr.h \ /usr/include/sys/types.h /usr/include/features.h \ /usr/include/sys/cdefs.h /usr/include/gnu/stubs.h \ /usr/include/bits/types.h /usr/include/bits/wordsize.h \ /usr/lib/gcc-lib/x86_64-linux/3.3.5/include/stddef.h \ /usr/include/bits/typesizes.h /usr/include/time.h /usr/include/endian.h \ /usr/include/bits/endian.h /usr/include/sys/select.h \ /usr/include/bits/select.h /usr/include/bits/sigset.h \ /usr/include/bits/time.h /usr/include/sys/sysmacros.h \ /usr/include/bits/pthreadtypes.h /usr/include/sys/socket.h \ /usr/include/sys/uio.h /usr/include/bits/uio.h \ /usr/include/bits/socket.h \ /usr/lib/gcc-lib/x86_64-linux/3.3.5/include/limits.h \ /usr/lib/gcc-lib/x86_64-linux/3.3.5/include/syslimits.h \ /usr/include/limits.h /usr/include/bits/posix1_lim.h \ /usr/include/bits/local_lim.h /usr/include/linux/limits.h \ /usr/include/bits/posix2_lim.h /usr/include/bits/xopen_lim.h \ /usr/include/bits/stdio_lim.h /usr/include/bits/sockaddr.h \ /usr/include/asm/socket.h /usr/include/asm/sockios.h \ /usr/include/stdint.h /usr/include/bits/wchar.h /usr/include/sys/wait.h \ /usr/include/signal.h /usr/include/bits/signum.h \ /usr/include/bits/siginfo.h /usr/include/bits/sigaction.h \ /usr/include/bits/sigcontext.h /usr/include/bits/sigstack.h \ /usr/include/sys/ucontext.h /usr/include/bits/sigthread.h \ /usr/include/sys/resource.h /usr/include/bits/resource.h \ /usr/include/bits/waitflags.h /usr/include/bits/waitstatus.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_pools.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_errno.h \ /usr/include/errno.h /usr/include/bits/errno.h \ /usr/include/linux/errno.h /usr/include/asm/errno.h \ /usr/include/asm-generic/errno.h /usr/include/asm-generic/errno-base.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_general.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_want.h \ /usr/include/string.h /usr/include/xlocale.h /usr/include/bits/string.h \ /usr/include/bits/string2.h /usr/include/stdlib.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_allocator.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_thread_mutex.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_time.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_file_info.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_user.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_tables.h \ /usr/lib/gcc-lib/x86_64-linux/3.3.5/include/stdarg.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_inherit.h \ /usr/include/stdio.h /usr/include/libio.h /usr/include/_G_config.h \ /usr/include/wchar.h /usr/include/gconv.h \ /usr/include/bits/sys_errlist.h /usr/include/bits/stdio.h at.h \ /usr/include/alloca.h /usr/include/setjmp.h /usr/include/bits/setjmp.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_strings.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_lib.h \ /usr/include/ctype.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_env.h \ /usr/include/assert.h /home/joe/httpd/trunk/worker/include/apr-1/apr_file_io.h: /home/joe/httpd/trunk/worker/include/apr-1/apr.h: /usr/include/sys/types.h: /usr/include/features.h: /usr/include/sys/cdefs.h: /usr/include/gnu/stubs.h: /usr/include/bits/types.h: /usr/include/bits/wordsize.h: /usr/lib/gcc-lib/x86_64-linux/3.3.5/include/stddef.h: /usr/include/bits/typesizes.h: /usr/include/time.h: /usr/include/endian.h: /usr/include/bits/endian.h: /usr/include/sys/select.h: /usr/include/bits/select.h: /usr/include/bits/sigset.h: /usr/include/bits/time.h: /usr/include/sys/sysmacros.h: /usr/include/bits/pthreadtypes.h: /usr/include/sys/socket.h: /usr/include/sys/uio.h: /usr/include/bits/uio.h: /usr/include/bits/socket.h: /usr/lib/gcc-lib/x86_64-linux/3.3.5/include/limits.h: /usr/lib/gcc-lib/x86_64-linux/3.3.5/include/syslimits.h: /usr/include/limits.h: /usr/include/bits/posix1_lim.h: /usr/include/bits/local_lim.h: /usr/include/linux/limits.h: /usr/include/bits/posix2_lim.h: /usr/include/bits/xopen_lim.h: /usr/include/bits/stdio_lim.h: /usr/include/bits/sockaddr.h: /usr/include/asm/socket.h: /usr/include/asm/sockios.h: /usr/include/stdint.h: /usr/include/bits/wchar.h: /usr/include/sys/wait.h: /usr/include/signal.h: /usr/include/bits/signum.h: /usr/include/bits/siginfo.h: /usr/include/bits/sigaction.h: /usr/include/bits/sigcontext.h: /usr/include/bits/sigstack.h: /usr/include/sys/ucontext.h: /usr/include/bits/sigthread.h: /usr/include/sys/resource.h: /usr/include/bits/resource.h: /usr/include/bits/waitflags.h: /usr/include/bits/waitstatus.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_pools.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_errno.h: /usr/include/errno.h: /usr/include/bits/errno.h: /usr/include/linux/errno.h: /usr/include/asm/errno.h: /usr/include/asm-generic/errno.h: /usr/include/asm-generic/errno-base.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_general.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_want.h: /usr/include/string.h: /usr/include/xlocale.h: /usr/include/bits/string.h: /usr/include/bits/string2.h: /usr/include/stdlib.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_allocator.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_thread_mutex.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_time.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_file_info.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_user.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_tables.h: /usr/lib/gcc-lib/x86_64-linux/3.3.5/include/stdarg.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_inherit.h: /usr/include/stdio.h: /usr/include/libio.h: /usr/include/_G_config.h: /usr/include/wchar.h: /usr/include/gconv.h: /usr/include/bits/sys_errlist.h: /usr/include/bits/stdio.h: at.h: /usr/include/alloca.h: /usr/include/setjmp.h: /usr/include/bits/setjmp.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_strings.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_lib.h: /usr/include/ctype.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_env.h: /usr/include/assert.h: rapache-1.2.8/libapreq2/library/t/.deps/cookie.Po0000644000175100017510000001561712706745114021046 0ustar ondrejondrejcookie.o: cookie.c \ /home/joe/httpd/trunk/worker/include/apr-1/apr_strings.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr.h \ /usr/include/sys/types.h /usr/include/features.h \ /usr/include/sys/cdefs.h /usr/include/gnu/stubs.h \ /usr/include/bits/types.h /usr/include/bits/wordsize.h \ /usr/lib/gcc-lib/x86_64-linux/3.3.5/include/stddef.h \ /usr/include/bits/typesizes.h /usr/include/time.h /usr/include/endian.h \ /usr/include/bits/endian.h /usr/include/sys/select.h \ /usr/include/bits/select.h /usr/include/bits/sigset.h \ /usr/include/bits/time.h /usr/include/sys/sysmacros.h \ /usr/include/bits/pthreadtypes.h /usr/include/sys/socket.h \ /usr/include/sys/uio.h /usr/include/bits/uio.h \ /usr/include/bits/socket.h \ /usr/lib/gcc-lib/x86_64-linux/3.3.5/include/limits.h \ /usr/lib/gcc-lib/x86_64-linux/3.3.5/include/syslimits.h \ /usr/include/limits.h /usr/include/bits/posix1_lim.h \ /usr/include/bits/local_lim.h /usr/include/linux/limits.h \ /usr/include/bits/posix2_lim.h /usr/include/bits/xopen_lim.h \ /usr/include/bits/stdio_lim.h /usr/include/bits/sockaddr.h \ /usr/include/asm/socket.h /usr/include/asm/sockios.h \ /usr/include/stdint.h /usr/include/bits/wchar.h /usr/include/sys/wait.h \ /usr/include/signal.h /usr/include/bits/signum.h \ /usr/include/bits/siginfo.h /usr/include/bits/sigaction.h \ /usr/include/bits/sigcontext.h /usr/include/bits/sigstack.h \ /usr/include/sys/ucontext.h /usr/include/bits/sigthread.h \ /usr/include/sys/resource.h /usr/include/bits/resource.h \ /usr/include/bits/waitflags.h /usr/include/bits/waitstatus.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_errno.h \ /usr/include/errno.h /usr/include/bits/errno.h \ /usr/include/linux/errno.h /usr/include/asm/errno.h \ /usr/include/asm-generic/errno.h /usr/include/asm-generic/errno-base.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_pools.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_general.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_want.h \ /usr/include/string.h /usr/include/xlocale.h /usr/include/bits/string.h \ /usr/include/bits/string2.h /usr/include/stdlib.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_allocator.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_thread_mutex.h \ /usr/lib/gcc-lib/x86_64-linux/3.3.5/include/stdarg.h \ ../../include/apreq_cookie.h ../../include/apreq.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_tables.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_time.h \ ../../include/apreq_error.h ../../include/apreq_module.h \ ../../include/apreq_parser.h ../../include/apreq_param.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_buckets.h \ /home/joe/httpd/trunk/worker/include/apr-1/apu.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_network_io.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_file_io.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_file_info.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_user.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_inherit.h \ /usr/include/stdio.h /usr/include/libio.h /usr/include/_G_config.h \ /usr/include/wchar.h /usr/include/gconv.h \ /usr/include/bits/sys_errlist.h /usr/include/bits/stdio.h \ /usr/include/netinet/in.h /usr/include/bits/in.h \ /usr/include/bits/byteswap.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_mmap.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_ring.h \ ../../include/apreq_util.h at.h /usr/include/alloca.h \ /usr/include/setjmp.h /usr/include/bits/setjmp.h /home/joe/httpd/trunk/worker/include/apr-1/apr_strings.h: /home/joe/httpd/trunk/worker/include/apr-1/apr.h: /usr/include/sys/types.h: /usr/include/features.h: /usr/include/sys/cdefs.h: /usr/include/gnu/stubs.h: /usr/include/bits/types.h: /usr/include/bits/wordsize.h: /usr/lib/gcc-lib/x86_64-linux/3.3.5/include/stddef.h: /usr/include/bits/typesizes.h: /usr/include/time.h: /usr/include/endian.h: /usr/include/bits/endian.h: /usr/include/sys/select.h: /usr/include/bits/select.h: /usr/include/bits/sigset.h: /usr/include/bits/time.h: /usr/include/sys/sysmacros.h: /usr/include/bits/pthreadtypes.h: /usr/include/sys/socket.h: /usr/include/sys/uio.h: /usr/include/bits/uio.h: /usr/include/bits/socket.h: /usr/lib/gcc-lib/x86_64-linux/3.3.5/include/limits.h: /usr/lib/gcc-lib/x86_64-linux/3.3.5/include/syslimits.h: /usr/include/limits.h: /usr/include/bits/posix1_lim.h: /usr/include/bits/local_lim.h: /usr/include/linux/limits.h: /usr/include/bits/posix2_lim.h: /usr/include/bits/xopen_lim.h: /usr/include/bits/stdio_lim.h: /usr/include/bits/sockaddr.h: /usr/include/asm/socket.h: /usr/include/asm/sockios.h: /usr/include/stdint.h: /usr/include/bits/wchar.h: /usr/include/sys/wait.h: /usr/include/signal.h: /usr/include/bits/signum.h: /usr/include/bits/siginfo.h: /usr/include/bits/sigaction.h: /usr/include/bits/sigcontext.h: /usr/include/bits/sigstack.h: /usr/include/sys/ucontext.h: /usr/include/bits/sigthread.h: /usr/include/sys/resource.h: /usr/include/bits/resource.h: /usr/include/bits/waitflags.h: /usr/include/bits/waitstatus.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_errno.h: /usr/include/errno.h: /usr/include/bits/errno.h: /usr/include/linux/errno.h: /usr/include/asm/errno.h: /usr/include/asm-generic/errno.h: /usr/include/asm-generic/errno-base.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_pools.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_general.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_want.h: /usr/include/string.h: /usr/include/xlocale.h: /usr/include/bits/string.h: /usr/include/bits/string2.h: /usr/include/stdlib.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_allocator.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_thread_mutex.h: /usr/lib/gcc-lib/x86_64-linux/3.3.5/include/stdarg.h: ../../include/apreq_cookie.h: ../../include/apreq.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_tables.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_time.h: ../../include/apreq_error.h: ../../include/apreq_module.h: ../../include/apreq_parser.h: ../../include/apreq_param.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_buckets.h: /home/joe/httpd/trunk/worker/include/apr-1/apu.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_network_io.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_file_io.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_file_info.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_user.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_inherit.h: /usr/include/stdio.h: /usr/include/libio.h: /usr/include/_G_config.h: /usr/include/wchar.h: /usr/include/gconv.h: /usr/include/bits/sys_errlist.h: /usr/include/bits/stdio.h: /usr/include/netinet/in.h: /usr/include/bits/in.h: /usr/include/bits/byteswap.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_mmap.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_ring.h: ../../include/apreq_util.h: at.h: /usr/include/alloca.h: /usr/include/setjmp.h: /usr/include/bits/setjmp.h: rapache-1.2.8/libapreq2/library/t/.deps/error.Po0000644000175100017510000001355312706745114020723 0ustar ondrejondrejerror.o: error.c /home/joe/httpd/trunk/worker/include/apr-1/apr_strings.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr.h \ /usr/include/sys/types.h /usr/include/features.h \ /usr/include/sys/cdefs.h /usr/include/gnu/stubs.h \ /usr/include/bits/types.h /usr/include/bits/wordsize.h \ /usr/lib/gcc-lib/x86_64-linux/3.3.5/include/stddef.h \ /usr/include/bits/typesizes.h /usr/include/time.h /usr/include/endian.h \ /usr/include/bits/endian.h /usr/include/sys/select.h \ /usr/include/bits/select.h /usr/include/bits/sigset.h \ /usr/include/bits/time.h /usr/include/sys/sysmacros.h \ /usr/include/bits/pthreadtypes.h /usr/include/sys/socket.h \ /usr/include/sys/uio.h /usr/include/bits/uio.h \ /usr/include/bits/socket.h \ /usr/lib/gcc-lib/x86_64-linux/3.3.5/include/limits.h \ /usr/lib/gcc-lib/x86_64-linux/3.3.5/include/syslimits.h \ /usr/include/limits.h /usr/include/bits/posix1_lim.h \ /usr/include/bits/local_lim.h /usr/include/linux/limits.h \ /usr/include/bits/posix2_lim.h /usr/include/bits/xopen_lim.h \ /usr/include/bits/stdio_lim.h /usr/include/bits/sockaddr.h \ /usr/include/asm/socket.h /usr/include/asm/sockios.h \ /usr/include/stdint.h /usr/include/bits/wchar.h /usr/include/sys/wait.h \ /usr/include/signal.h /usr/include/bits/signum.h \ /usr/include/bits/siginfo.h /usr/include/bits/sigaction.h \ /usr/include/bits/sigcontext.h /usr/include/bits/sigstack.h \ /usr/include/sys/ucontext.h /usr/include/bits/sigthread.h \ /usr/include/sys/resource.h /usr/include/bits/resource.h \ /usr/include/bits/waitflags.h /usr/include/bits/waitstatus.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_errno.h \ /usr/include/errno.h /usr/include/bits/errno.h \ /usr/include/linux/errno.h /usr/include/asm/errno.h \ /usr/include/asm-generic/errno.h /usr/include/asm-generic/errno-base.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_pools.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_general.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_want.h \ /usr/include/string.h /usr/include/xlocale.h /usr/include/bits/string.h \ /usr/include/bits/string2.h /usr/include/stdlib.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_allocator.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_thread_mutex.h \ /usr/lib/gcc-lib/x86_64-linux/3.3.5/include/stdarg.h \ ../../include/apreq_error.h ../../include/apreq.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_tables.h at.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_file_io.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_time.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_file_info.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_user.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_inherit.h \ /usr/include/stdio.h /usr/include/libio.h /usr/include/_G_config.h \ /usr/include/wchar.h /usr/include/gconv.h \ /usr/include/bits/sys_errlist.h /usr/include/bits/stdio.h \ /usr/include/alloca.h /usr/include/setjmp.h /usr/include/bits/setjmp.h /home/joe/httpd/trunk/worker/include/apr-1/apr_strings.h: /home/joe/httpd/trunk/worker/include/apr-1/apr.h: /usr/include/sys/types.h: /usr/include/features.h: /usr/include/sys/cdefs.h: /usr/include/gnu/stubs.h: /usr/include/bits/types.h: /usr/include/bits/wordsize.h: /usr/lib/gcc-lib/x86_64-linux/3.3.5/include/stddef.h: /usr/include/bits/typesizes.h: /usr/include/time.h: /usr/include/endian.h: /usr/include/bits/endian.h: /usr/include/sys/select.h: /usr/include/bits/select.h: /usr/include/bits/sigset.h: /usr/include/bits/time.h: /usr/include/sys/sysmacros.h: /usr/include/bits/pthreadtypes.h: /usr/include/sys/socket.h: /usr/include/sys/uio.h: /usr/include/bits/uio.h: /usr/include/bits/socket.h: /usr/lib/gcc-lib/x86_64-linux/3.3.5/include/limits.h: /usr/lib/gcc-lib/x86_64-linux/3.3.5/include/syslimits.h: /usr/include/limits.h: /usr/include/bits/posix1_lim.h: /usr/include/bits/local_lim.h: /usr/include/linux/limits.h: /usr/include/bits/posix2_lim.h: /usr/include/bits/xopen_lim.h: /usr/include/bits/stdio_lim.h: /usr/include/bits/sockaddr.h: /usr/include/asm/socket.h: /usr/include/asm/sockios.h: /usr/include/stdint.h: /usr/include/bits/wchar.h: /usr/include/sys/wait.h: /usr/include/signal.h: /usr/include/bits/signum.h: /usr/include/bits/siginfo.h: /usr/include/bits/sigaction.h: /usr/include/bits/sigcontext.h: /usr/include/bits/sigstack.h: /usr/include/sys/ucontext.h: /usr/include/bits/sigthread.h: /usr/include/sys/resource.h: /usr/include/bits/resource.h: /usr/include/bits/waitflags.h: /usr/include/bits/waitstatus.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_errno.h: /usr/include/errno.h: /usr/include/bits/errno.h: /usr/include/linux/errno.h: /usr/include/asm/errno.h: /usr/include/asm-generic/errno.h: /usr/include/asm-generic/errno-base.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_pools.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_general.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_want.h: /usr/include/string.h: /usr/include/xlocale.h: /usr/include/bits/string.h: /usr/include/bits/string2.h: /usr/include/stdlib.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_allocator.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_thread_mutex.h: /usr/lib/gcc-lib/x86_64-linux/3.3.5/include/stdarg.h: ../../include/apreq_error.h: ../../include/apreq.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_tables.h: at.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_file_io.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_time.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_file_info.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_user.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_inherit.h: /usr/include/stdio.h: /usr/include/libio.h: /usr/include/_G_config.h: /usr/include/wchar.h: /usr/include/gconv.h: /usr/include/bits/sys_errlist.h: /usr/include/bits/stdio.h: /usr/include/alloca.h: /usr/include/setjmp.h: /usr/include/bits/setjmp.h: rapache-1.2.8/libapreq2/library/t/.deps/params.Po0000644000175100017510000001531712706745114021055 0ustar ondrejondrejparams.o: params.c ../../include/apreq_param.h ../../include/apreq.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_tables.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr.h \ /usr/include/sys/types.h /usr/include/features.h \ /usr/include/sys/cdefs.h /usr/include/gnu/stubs.h \ /usr/include/bits/types.h /usr/include/bits/wordsize.h \ /usr/lib/gcc-lib/x86_64-linux/3.3.5/include/stddef.h \ /usr/include/bits/typesizes.h /usr/include/time.h /usr/include/endian.h \ /usr/include/bits/endian.h /usr/include/sys/select.h \ /usr/include/bits/select.h /usr/include/bits/sigset.h \ /usr/include/bits/time.h /usr/include/sys/sysmacros.h \ /usr/include/bits/pthreadtypes.h /usr/include/sys/socket.h \ /usr/include/sys/uio.h /usr/include/bits/uio.h \ /usr/include/bits/socket.h \ /usr/lib/gcc-lib/x86_64-linux/3.3.5/include/limits.h \ /usr/lib/gcc-lib/x86_64-linux/3.3.5/include/syslimits.h \ /usr/include/limits.h /usr/include/bits/posix1_lim.h \ /usr/include/bits/local_lim.h /usr/include/linux/limits.h \ /usr/include/bits/posix2_lim.h /usr/include/bits/xopen_lim.h \ /usr/include/bits/stdio_lim.h /usr/include/bits/sockaddr.h \ /usr/include/asm/socket.h /usr/include/asm/sockios.h \ /usr/include/stdint.h /usr/include/bits/wchar.h /usr/include/sys/wait.h \ /usr/include/signal.h /usr/include/bits/signum.h \ /usr/include/bits/siginfo.h /usr/include/bits/sigaction.h \ /usr/include/bits/sigcontext.h /usr/include/bits/sigstack.h \ /usr/include/sys/ucontext.h /usr/include/bits/sigthread.h \ /usr/include/sys/resource.h /usr/include/bits/resource.h \ /usr/include/bits/waitflags.h /usr/include/bits/waitstatus.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_pools.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_errno.h \ /usr/include/errno.h /usr/include/bits/errno.h \ /usr/include/linux/errno.h /usr/include/asm/errno.h \ /usr/include/asm-generic/errno.h /usr/include/asm-generic/errno-base.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_general.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_want.h \ /usr/include/string.h /usr/include/xlocale.h /usr/include/bits/string.h \ /usr/include/bits/string2.h /usr/include/stdlib.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_allocator.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_thread_mutex.h \ /usr/lib/gcc-lib/x86_64-linux/3.3.5/include/stdarg.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_buckets.h \ /home/joe/httpd/trunk/worker/include/apr-1/apu.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_network_io.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_file_io.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_time.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_file_info.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_user.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_inherit.h \ /usr/include/stdio.h /usr/include/libio.h /usr/include/_G_config.h \ /usr/include/wchar.h /usr/include/gconv.h \ /usr/include/bits/sys_errlist.h /usr/include/bits/stdio.h \ /usr/include/netinet/in.h /usr/include/bits/in.h \ /usr/include/bits/byteswap.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_mmap.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_ring.h \ ../../include/apreq_util.h ../../include/apreq_error.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_strings.h at.h \ /usr/include/alloca.h /usr/include/setjmp.h /usr/include/bits/setjmp.h ../../include/apreq_param.h: ../../include/apreq.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_tables.h: /home/joe/httpd/trunk/worker/include/apr-1/apr.h: /usr/include/sys/types.h: /usr/include/features.h: /usr/include/sys/cdefs.h: /usr/include/gnu/stubs.h: /usr/include/bits/types.h: /usr/include/bits/wordsize.h: /usr/lib/gcc-lib/x86_64-linux/3.3.5/include/stddef.h: /usr/include/bits/typesizes.h: /usr/include/time.h: /usr/include/endian.h: /usr/include/bits/endian.h: /usr/include/sys/select.h: /usr/include/bits/select.h: /usr/include/bits/sigset.h: /usr/include/bits/time.h: /usr/include/sys/sysmacros.h: /usr/include/bits/pthreadtypes.h: /usr/include/sys/socket.h: /usr/include/sys/uio.h: /usr/include/bits/uio.h: /usr/include/bits/socket.h: /usr/lib/gcc-lib/x86_64-linux/3.3.5/include/limits.h: /usr/lib/gcc-lib/x86_64-linux/3.3.5/include/syslimits.h: /usr/include/limits.h: /usr/include/bits/posix1_lim.h: /usr/include/bits/local_lim.h: /usr/include/linux/limits.h: /usr/include/bits/posix2_lim.h: /usr/include/bits/xopen_lim.h: /usr/include/bits/stdio_lim.h: /usr/include/bits/sockaddr.h: /usr/include/asm/socket.h: /usr/include/asm/sockios.h: /usr/include/stdint.h: /usr/include/bits/wchar.h: /usr/include/sys/wait.h: /usr/include/signal.h: /usr/include/bits/signum.h: /usr/include/bits/siginfo.h: /usr/include/bits/sigaction.h: /usr/include/bits/sigcontext.h: /usr/include/bits/sigstack.h: /usr/include/sys/ucontext.h: /usr/include/bits/sigthread.h: /usr/include/sys/resource.h: /usr/include/bits/resource.h: /usr/include/bits/waitflags.h: /usr/include/bits/waitstatus.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_pools.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_errno.h: /usr/include/errno.h: /usr/include/bits/errno.h: /usr/include/linux/errno.h: /usr/include/asm/errno.h: /usr/include/asm-generic/errno.h: /usr/include/asm-generic/errno-base.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_general.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_want.h: /usr/include/string.h: /usr/include/xlocale.h: /usr/include/bits/string.h: /usr/include/bits/string2.h: /usr/include/stdlib.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_allocator.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_thread_mutex.h: /usr/lib/gcc-lib/x86_64-linux/3.3.5/include/stdarg.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_buckets.h: /home/joe/httpd/trunk/worker/include/apr-1/apu.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_network_io.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_file_io.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_time.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_file_info.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_user.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_inherit.h: /usr/include/stdio.h: /usr/include/libio.h: /usr/include/_G_config.h: /usr/include/wchar.h: /usr/include/gconv.h: /usr/include/bits/sys_errlist.h: /usr/include/bits/stdio.h: /usr/include/netinet/in.h: /usr/include/bits/in.h: /usr/include/bits/byteswap.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_mmap.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_ring.h: ../../include/apreq_util.h: ../../include/apreq_error.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_strings.h: at.h: /usr/include/alloca.h: /usr/include/setjmp.h: /usr/include/bits/setjmp.h: rapache-1.2.8/libapreq2/library/t/.deps/parsers.Po0000644000175100017510000001551112706745114021245 0ustar ondrejondrejparsers.o: parsers.c ../../include/apreq_parser.h \ ../../include/apreq_param.h ../../include/apreq.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_tables.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr.h \ /usr/include/sys/types.h /usr/include/features.h \ /usr/include/sys/cdefs.h /usr/include/gnu/stubs.h \ /usr/include/bits/types.h /usr/include/bits/wordsize.h \ /usr/lib/gcc-lib/x86_64-linux/3.3.5/include/stddef.h \ /usr/include/bits/typesizes.h /usr/include/time.h /usr/include/endian.h \ /usr/include/bits/endian.h /usr/include/sys/select.h \ /usr/include/bits/select.h /usr/include/bits/sigset.h \ /usr/include/bits/time.h /usr/include/sys/sysmacros.h \ /usr/include/bits/pthreadtypes.h /usr/include/sys/socket.h \ /usr/include/sys/uio.h /usr/include/bits/uio.h \ /usr/include/bits/socket.h \ /usr/lib/gcc-lib/x86_64-linux/3.3.5/include/limits.h \ /usr/lib/gcc-lib/x86_64-linux/3.3.5/include/syslimits.h \ /usr/include/limits.h /usr/include/bits/posix1_lim.h \ /usr/include/bits/local_lim.h /usr/include/linux/limits.h \ /usr/include/bits/posix2_lim.h /usr/include/bits/xopen_lim.h \ /usr/include/bits/stdio_lim.h /usr/include/bits/sockaddr.h \ /usr/include/asm/socket.h /usr/include/asm/sockios.h \ /usr/include/stdint.h /usr/include/bits/wchar.h /usr/include/sys/wait.h \ /usr/include/signal.h /usr/include/bits/signum.h \ /usr/include/bits/siginfo.h /usr/include/bits/sigaction.h \ /usr/include/bits/sigcontext.h /usr/include/bits/sigstack.h \ /usr/include/sys/ucontext.h /usr/include/bits/sigthread.h \ /usr/include/sys/resource.h /usr/include/bits/resource.h \ /usr/include/bits/waitflags.h /usr/include/bits/waitstatus.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_pools.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_errno.h \ /usr/include/errno.h /usr/include/bits/errno.h \ /usr/include/linux/errno.h /usr/include/asm/errno.h \ /usr/include/asm-generic/errno.h /usr/include/asm-generic/errno-base.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_general.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_want.h \ /usr/include/string.h /usr/include/xlocale.h /usr/include/bits/string.h \ /usr/include/bits/string2.h /usr/include/stdlib.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_allocator.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_thread_mutex.h \ /usr/lib/gcc-lib/x86_64-linux/3.3.5/include/stdarg.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_buckets.h \ /home/joe/httpd/trunk/worker/include/apr-1/apu.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_network_io.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_file_io.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_time.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_file_info.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_user.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_inherit.h \ /usr/include/stdio.h /usr/include/libio.h /usr/include/_G_config.h \ /usr/include/wchar.h /usr/include/gconv.h \ /usr/include/bits/sys_errlist.h /usr/include/bits/stdio.h \ /usr/include/netinet/in.h /usr/include/bits/in.h \ /usr/include/bits/byteswap.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_mmap.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_ring.h \ ../../include/apreq_error.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_strings.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_xml.h at.h \ /usr/include/alloca.h /usr/include/setjmp.h /usr/include/bits/setjmp.h ../../include/apreq_parser.h: ../../include/apreq_param.h: ../../include/apreq.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_tables.h: /home/joe/httpd/trunk/worker/include/apr-1/apr.h: /usr/include/sys/types.h: /usr/include/features.h: /usr/include/sys/cdefs.h: /usr/include/gnu/stubs.h: /usr/include/bits/types.h: /usr/include/bits/wordsize.h: /usr/lib/gcc-lib/x86_64-linux/3.3.5/include/stddef.h: /usr/include/bits/typesizes.h: /usr/include/time.h: /usr/include/endian.h: /usr/include/bits/endian.h: /usr/include/sys/select.h: /usr/include/bits/select.h: /usr/include/bits/sigset.h: /usr/include/bits/time.h: /usr/include/sys/sysmacros.h: /usr/include/bits/pthreadtypes.h: /usr/include/sys/socket.h: /usr/include/sys/uio.h: /usr/include/bits/uio.h: /usr/include/bits/socket.h: /usr/lib/gcc-lib/x86_64-linux/3.3.5/include/limits.h: /usr/lib/gcc-lib/x86_64-linux/3.3.5/include/syslimits.h: /usr/include/limits.h: /usr/include/bits/posix1_lim.h: /usr/include/bits/local_lim.h: /usr/include/linux/limits.h: /usr/include/bits/posix2_lim.h: /usr/include/bits/xopen_lim.h: /usr/include/bits/stdio_lim.h: /usr/include/bits/sockaddr.h: /usr/include/asm/socket.h: /usr/include/asm/sockios.h: /usr/include/stdint.h: /usr/include/bits/wchar.h: /usr/include/sys/wait.h: /usr/include/signal.h: /usr/include/bits/signum.h: /usr/include/bits/siginfo.h: /usr/include/bits/sigaction.h: /usr/include/bits/sigcontext.h: /usr/include/bits/sigstack.h: /usr/include/sys/ucontext.h: /usr/include/bits/sigthread.h: /usr/include/sys/resource.h: /usr/include/bits/resource.h: /usr/include/bits/waitflags.h: /usr/include/bits/waitstatus.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_pools.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_errno.h: /usr/include/errno.h: /usr/include/bits/errno.h: /usr/include/linux/errno.h: /usr/include/asm/errno.h: /usr/include/asm-generic/errno.h: /usr/include/asm-generic/errno-base.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_general.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_want.h: /usr/include/string.h: /usr/include/xlocale.h: /usr/include/bits/string.h: /usr/include/bits/string2.h: /usr/include/stdlib.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_allocator.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_thread_mutex.h: /usr/lib/gcc-lib/x86_64-linux/3.3.5/include/stdarg.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_buckets.h: /home/joe/httpd/trunk/worker/include/apr-1/apu.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_network_io.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_file_io.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_time.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_file_info.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_user.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_inherit.h: /usr/include/stdio.h: /usr/include/libio.h: /usr/include/_G_config.h: /usr/include/wchar.h: /usr/include/gconv.h: /usr/include/bits/sys_errlist.h: /usr/include/bits/stdio.h: /usr/include/netinet/in.h: /usr/include/bits/in.h: /usr/include/bits/byteswap.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_mmap.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_ring.h: ../../include/apreq_error.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_strings.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_xml.h: at.h: /usr/include/alloca.h: /usr/include/setjmp.h: /usr/include/bits/setjmp.h: rapache-1.2.8/libapreq2/library/t/.deps/util.Po0000644000175100017510000001522112706745114020541 0ustar ondrejondrejutil.o: util.c /home/joe/httpd/trunk/worker/include/apr-1/apr_strings.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr.h \ /usr/include/sys/types.h /usr/include/features.h \ /usr/include/sys/cdefs.h /usr/include/gnu/stubs.h \ /usr/include/bits/types.h /usr/include/bits/wordsize.h \ /usr/lib/gcc-lib/x86_64-linux/3.3.5/include/stddef.h \ /usr/include/bits/typesizes.h /usr/include/time.h /usr/include/endian.h \ /usr/include/bits/endian.h /usr/include/sys/select.h \ /usr/include/bits/select.h /usr/include/bits/sigset.h \ /usr/include/bits/time.h /usr/include/sys/sysmacros.h \ /usr/include/bits/pthreadtypes.h /usr/include/sys/socket.h \ /usr/include/sys/uio.h /usr/include/bits/uio.h \ /usr/include/bits/socket.h \ /usr/lib/gcc-lib/x86_64-linux/3.3.5/include/limits.h \ /usr/lib/gcc-lib/x86_64-linux/3.3.5/include/syslimits.h \ /usr/include/limits.h /usr/include/bits/posix1_lim.h \ /usr/include/bits/local_lim.h /usr/include/linux/limits.h \ /usr/include/bits/posix2_lim.h /usr/include/bits/xopen_lim.h \ /usr/include/bits/stdio_lim.h /usr/include/bits/sockaddr.h \ /usr/include/asm/socket.h /usr/include/asm/sockios.h \ /usr/include/stdint.h /usr/include/bits/wchar.h /usr/include/sys/wait.h \ /usr/include/signal.h /usr/include/bits/signum.h \ /usr/include/bits/siginfo.h /usr/include/bits/sigaction.h \ /usr/include/bits/sigcontext.h /usr/include/bits/sigstack.h \ /usr/include/sys/ucontext.h /usr/include/bits/sigthread.h \ /usr/include/sys/resource.h /usr/include/bits/resource.h \ /usr/include/bits/waitflags.h /usr/include/bits/waitstatus.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_errno.h \ /usr/include/errno.h /usr/include/bits/errno.h \ /usr/include/linux/errno.h /usr/include/asm/errno.h \ /usr/include/asm-generic/errno.h /usr/include/asm-generic/errno-base.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_pools.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_general.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_want.h \ /usr/include/string.h /usr/include/xlocale.h /usr/include/bits/string.h \ /usr/include/bits/string2.h /usr/include/stdlib.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_allocator.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_thread_mutex.h \ /usr/lib/gcc-lib/x86_64-linux/3.3.5/include/stdarg.h \ ../../include/apreq_error.h ../../include/apreq.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_tables.h \ ../../include/apreq_util.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_file_io.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_time.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_file_info.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_user.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_inherit.h \ /usr/include/stdio.h /usr/include/libio.h /usr/include/_G_config.h \ /usr/include/wchar.h /usr/include/gconv.h \ /usr/include/bits/sys_errlist.h /usr/include/bits/stdio.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_buckets.h \ /home/joe/httpd/trunk/worker/include/apr-1/apu.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_network_io.h \ /usr/include/netinet/in.h /usr/include/bits/in.h \ /usr/include/bits/byteswap.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_mmap.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_ring.h at.h \ /usr/include/alloca.h /usr/include/setjmp.h /usr/include/bits/setjmp.h /home/joe/httpd/trunk/worker/include/apr-1/apr_strings.h: /home/joe/httpd/trunk/worker/include/apr-1/apr.h: /usr/include/sys/types.h: /usr/include/features.h: /usr/include/sys/cdefs.h: /usr/include/gnu/stubs.h: /usr/include/bits/types.h: /usr/include/bits/wordsize.h: /usr/lib/gcc-lib/x86_64-linux/3.3.5/include/stddef.h: /usr/include/bits/typesizes.h: /usr/include/time.h: /usr/include/endian.h: /usr/include/bits/endian.h: /usr/include/sys/select.h: /usr/include/bits/select.h: /usr/include/bits/sigset.h: /usr/include/bits/time.h: /usr/include/sys/sysmacros.h: /usr/include/bits/pthreadtypes.h: /usr/include/sys/socket.h: /usr/include/sys/uio.h: /usr/include/bits/uio.h: /usr/include/bits/socket.h: /usr/lib/gcc-lib/x86_64-linux/3.3.5/include/limits.h: /usr/lib/gcc-lib/x86_64-linux/3.3.5/include/syslimits.h: /usr/include/limits.h: /usr/include/bits/posix1_lim.h: /usr/include/bits/local_lim.h: /usr/include/linux/limits.h: /usr/include/bits/posix2_lim.h: /usr/include/bits/xopen_lim.h: /usr/include/bits/stdio_lim.h: /usr/include/bits/sockaddr.h: /usr/include/asm/socket.h: /usr/include/asm/sockios.h: /usr/include/stdint.h: /usr/include/bits/wchar.h: /usr/include/sys/wait.h: /usr/include/signal.h: /usr/include/bits/signum.h: /usr/include/bits/siginfo.h: /usr/include/bits/sigaction.h: /usr/include/bits/sigcontext.h: /usr/include/bits/sigstack.h: /usr/include/sys/ucontext.h: /usr/include/bits/sigthread.h: /usr/include/sys/resource.h: /usr/include/bits/resource.h: /usr/include/bits/waitflags.h: /usr/include/bits/waitstatus.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_errno.h: /usr/include/errno.h: /usr/include/bits/errno.h: /usr/include/linux/errno.h: /usr/include/asm/errno.h: /usr/include/asm-generic/errno.h: /usr/include/asm-generic/errno-base.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_pools.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_general.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_want.h: /usr/include/string.h: /usr/include/xlocale.h: /usr/include/bits/string.h: /usr/include/bits/string2.h: /usr/include/stdlib.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_allocator.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_thread_mutex.h: /usr/lib/gcc-lib/x86_64-linux/3.3.5/include/stdarg.h: ../../include/apreq_error.h: ../../include/apreq.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_tables.h: ../../include/apreq_util.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_file_io.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_time.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_file_info.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_user.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_inherit.h: /usr/include/stdio.h: /usr/include/libio.h: /usr/include/_G_config.h: /usr/include/wchar.h: /usr/include/gconv.h: /usr/include/bits/sys_errlist.h: /usr/include/bits/stdio.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_buckets.h: /home/joe/httpd/trunk/worker/include/apr-1/apu.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_network_io.h: /usr/include/netinet/in.h: /usr/include/bits/in.h: /usr/include/bits/byteswap.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_mmap.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_ring.h: at.h: /usr/include/alloca.h: /usr/include/setjmp.h: /usr/include/bits/setjmp.h: rapache-1.2.8/libapreq2/library/t/.deps/version.Po0000644000175100017510000001375712706745114021265 0ustar ondrejondrejversion.o: version.c ../../include/apreq_version.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_version.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr.h \ /usr/include/sys/types.h /usr/include/features.h \ /usr/include/sys/cdefs.h /usr/include/gnu/stubs.h \ /usr/include/bits/types.h /usr/include/bits/wordsize.h \ /usr/lib/gcc-lib/x86_64-linux/3.3.5/include/stddef.h \ /usr/include/bits/typesizes.h /usr/include/time.h /usr/include/endian.h \ /usr/include/bits/endian.h /usr/include/sys/select.h \ /usr/include/bits/select.h /usr/include/bits/sigset.h \ /usr/include/bits/time.h /usr/include/sys/sysmacros.h \ /usr/include/bits/pthreadtypes.h /usr/include/sys/socket.h \ /usr/include/sys/uio.h /usr/include/bits/uio.h \ /usr/include/bits/socket.h \ /usr/lib/gcc-lib/x86_64-linux/3.3.5/include/limits.h \ /usr/lib/gcc-lib/x86_64-linux/3.3.5/include/syslimits.h \ /usr/include/limits.h /usr/include/bits/posix1_lim.h \ /usr/include/bits/local_lim.h /usr/include/linux/limits.h \ /usr/include/bits/posix2_lim.h /usr/include/bits/xopen_lim.h \ /usr/include/bits/stdio_lim.h /usr/include/bits/sockaddr.h \ /usr/include/asm/socket.h /usr/include/asm/sockios.h \ /usr/include/stdint.h /usr/include/bits/wchar.h /usr/include/sys/wait.h \ /usr/include/signal.h /usr/include/bits/signum.h \ /usr/include/bits/siginfo.h /usr/include/bits/sigaction.h \ /usr/include/bits/sigcontext.h /usr/include/bits/sigstack.h \ /usr/include/sys/ucontext.h /usr/include/bits/sigthread.h \ /usr/include/sys/resource.h /usr/include/bits/resource.h \ /usr/include/bits/waitflags.h /usr/include/bits/waitstatus.h \ ../../include/apreq.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_tables.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_pools.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_errno.h \ /usr/include/errno.h /usr/include/bits/errno.h \ /usr/include/linux/errno.h /usr/include/asm/errno.h \ /usr/include/asm-generic/errno.h /usr/include/asm-generic/errno-base.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_general.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_want.h \ /usr/include/string.h /usr/include/xlocale.h /usr/include/bits/string.h \ /usr/include/bits/string2.h /usr/include/stdlib.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_allocator.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_thread_mutex.h \ /usr/lib/gcc-lib/x86_64-linux/3.3.5/include/stdarg.h at.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_file_io.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_time.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_file_info.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_user.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_inherit.h \ /usr/include/stdio.h /usr/include/libio.h /usr/include/_G_config.h \ /usr/include/wchar.h /usr/include/gconv.h \ /usr/include/bits/sys_errlist.h /usr/include/bits/stdio.h \ /usr/include/alloca.h /usr/include/setjmp.h /usr/include/bits/setjmp.h \ /home/joe/httpd/trunk/worker/include/apr-1/apr_strings.h ../../include/apreq_version.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_version.h: /home/joe/httpd/trunk/worker/include/apr-1/apr.h: /usr/include/sys/types.h: /usr/include/features.h: /usr/include/sys/cdefs.h: /usr/include/gnu/stubs.h: /usr/include/bits/types.h: /usr/include/bits/wordsize.h: /usr/lib/gcc-lib/x86_64-linux/3.3.5/include/stddef.h: /usr/include/bits/typesizes.h: /usr/include/time.h: /usr/include/endian.h: /usr/include/bits/endian.h: /usr/include/sys/select.h: /usr/include/bits/select.h: /usr/include/bits/sigset.h: /usr/include/bits/time.h: /usr/include/sys/sysmacros.h: /usr/include/bits/pthreadtypes.h: /usr/include/sys/socket.h: /usr/include/sys/uio.h: /usr/include/bits/uio.h: /usr/include/bits/socket.h: /usr/lib/gcc-lib/x86_64-linux/3.3.5/include/limits.h: /usr/lib/gcc-lib/x86_64-linux/3.3.5/include/syslimits.h: /usr/include/limits.h: /usr/include/bits/posix1_lim.h: /usr/include/bits/local_lim.h: /usr/include/linux/limits.h: /usr/include/bits/posix2_lim.h: /usr/include/bits/xopen_lim.h: /usr/include/bits/stdio_lim.h: /usr/include/bits/sockaddr.h: /usr/include/asm/socket.h: /usr/include/asm/sockios.h: /usr/include/stdint.h: /usr/include/bits/wchar.h: /usr/include/sys/wait.h: /usr/include/signal.h: /usr/include/bits/signum.h: /usr/include/bits/siginfo.h: /usr/include/bits/sigaction.h: /usr/include/bits/sigcontext.h: /usr/include/bits/sigstack.h: /usr/include/sys/ucontext.h: /usr/include/bits/sigthread.h: /usr/include/sys/resource.h: /usr/include/bits/resource.h: /usr/include/bits/waitflags.h: /usr/include/bits/waitstatus.h: ../../include/apreq.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_tables.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_pools.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_errno.h: /usr/include/errno.h: /usr/include/bits/errno.h: /usr/include/linux/errno.h: /usr/include/asm/errno.h: /usr/include/asm-generic/errno.h: /usr/include/asm-generic/errno-base.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_general.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_want.h: /usr/include/string.h: /usr/include/xlocale.h: /usr/include/bits/string.h: /usr/include/bits/string2.h: /usr/include/stdlib.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_allocator.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_thread_mutex.h: /usr/lib/gcc-lib/x86_64-linux/3.3.5/include/stdarg.h: at.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_file_io.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_time.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_file_info.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_user.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_inherit.h: /usr/include/stdio.h: /usr/include/libio.h: /usr/include/_G_config.h: /usr/include/wchar.h: /usr/include/gconv.h: /usr/include/bits/sys_errlist.h: /usr/include/bits/stdio.h: /usr/include/alloca.h: /usr/include/setjmp.h: /usr/include/bits/setjmp.h: /home/joe/httpd/trunk/worker/include/apr-1/apr_strings.h: rapache-1.2.8/libapreq2/library/t/Makefile.am0000644000175100017510000000110112706745114020277 0ustar ondrejondrejAM_CPPFLAGS = @APR_INCLUDES@ AM_LDFLAGS = `@APREQ_CONFIG@ --link-libtool --libs` @APR_LTFLAGS@ noinst_LIBRARIES = libapache_test.a libapache_test_a_SOURCES = at.h at.c check_PROGRAMS = version cookie params parsers error util LDADD = libapache_test.a check_SCRIPTS = version.t cookie.t params.t parsers.t error.t util.t TESTS = $(check_SCRIPTS) TESTS_ENVIRONMENT = @PERL@ -MTest::Harness -e 'runtests(@ARGV)' CLEANFILES = $(check_PROGRAMS) $(check_SCRIPTS) %.t: % echo "#!perl" > $@ echo "exec './$*'" >> $@ test: $(check_SCRIPTS) $(TESTS_ENVIRONMENT) $(check_SCRIPTS) rapache-1.2.8/libapreq2/library/t/Makefile.in0000644000175100017510000003472512706745114020332 0ustar ondrejondrej# Makefile.in generated by automake 1.6.3 from Makefile.am. # @configure_input@ # Copyright 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002 # 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@ SHELL = @SHELL@ srcdir = @srcdir@ top_srcdir = @top_srcdir@ VPATH = @srcdir@ prefix = @prefix@ exec_prefix = @exec_prefix@ bindir = @bindir@ sbindir = @sbindir@ libexecdir = @libexecdir@ datadir = @datadir@ sysconfdir = @sysconfdir@ sharedstatedir = @sharedstatedir@ localstatedir = @localstatedir@ libdir = @libdir@ infodir = @infodir@ mandir = @mandir@ includedir = @includedir@ oldincludedir = /usr/include pkgdatadir = $(datadir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ top_builddir = ../.. ACLOCAL = @ACLOCAL@ AUTOCONF = @AUTOCONF@ AUTOMAKE = @AUTOMAKE@ AUTOHEADER = @AUTOHEADER@ am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd INSTALL = @INSTALL@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_DATA = @INSTALL_DATA@ install_sh_DATA = $(install_sh) -c -m 644 install_sh_PROGRAM = $(install_sh) -c install_sh_SCRIPT = $(install_sh) -c INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_HEADER = $(INSTALL_DATA) transform = @program_transform_name@ NORMAL_INSTALL = : PRE_INSTALL = : POST_INSTALL = : NORMAL_UNINSTALL = : PRE_UNINSTALL = : POST_UNINSTALL = : host_alias = @host_alias@ host_triplet = @host@ EXEEXT = @EXEEXT@ OBJEXT = @OBJEXT@ PATH_SEPARATOR = @PATH_SEPARATOR@ AMTAR = @AMTAR@ APACHE1_APXS = @APACHE1_APXS@ APACHE2_APXS = @APACHE2_APXS@ APACHE2_HTTPD = @APACHE2_HTTPD@ APACHE2_INCLUDES = @APACHE2_INCLUDES@ APACHE2_SRC = @APACHE2_SRC@ APREQ_CONFIG = @APREQ_CONFIG@ APREQ_DOTTED_VERSION = @APREQ_DOTTED_VERSION@ APREQ_LIBNAME = @APREQ_LIBNAME@ APREQ_LIBTOOL_VERSION = @APREQ_LIBTOOL_VERSION@ APREQ_MAJOR_VERSION = @APREQ_MAJOR_VERSION@ APR_CONFIG = @APR_CONFIG@ APR_INCLUDES = @APR_INCLUDES@ APR_LA = @APR_LA@ APR_LDFLAGS = @APR_LDFLAGS@ APR_LIBS = @APR_LIBS@ APR_LTFLAGS = @APR_LTFLAGS@ APU_CONFIG = @APU_CONFIG@ APU_LA = @APU_LA@ AR = @AR@ AS = @AS@ AWK = @AWK@ CC = @CC@ CXX = @CXX@ CXXCPP = @CXXCPP@ DEPDIR = @DEPDIR@ DLLTOOL = @DLLTOOL@ ECHO = @ECHO@ EGREP = @EGREP@ F77 = @F77@ GCJ = @GCJ@ GCJFLAGS = @GCJFLAGS@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ LIBTOOL = @LIBTOOL@ LN_S = @LN_S@ MAINT = @MAINT@ OBJDUMP = @OBJDUMP@ PACKAGE = @PACKAGE@ PERL = @PERL@ PERL_OPTS = @PERL_OPTS@ RANLIB = @RANLIB@ RC = @RC@ STRIP = @STRIP@ VERSION = @VERSION@ am__include = @am__include@ am__quote = @am__quote@ install_sh = @install_sh@ AM_CPPFLAGS = @APR_INCLUDES@ AM_LDFLAGS = `@APREQ_CONFIG@ --link-libtool --libs` @APR_LTFLAGS@ noinst_LIBRARIES = libapache_test.a libapache_test_a_SOURCES = at.h at.c check_PROGRAMS = version cookie params parsers error util LDADD = libapache_test.a check_SCRIPTS = version.t cookie.t params.t parsers.t error.t util.t TESTS = $(check_SCRIPTS) TESTS_ENVIRONMENT = @PERL@ -MTest::Harness -e 'runtests(@ARGV)' CLEANFILES = $(check_PROGRAMS) $(check_SCRIPTS) subdir = library/t mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs CONFIG_HEADER = $(top_builddir)/include/apreq_config.h CONFIG_CLEAN_FILES = LIBRARIES = $(noinst_LIBRARIES) libapache_test_a_AR = $(AR) cru libapache_test_a_LIBADD = am_libapache_test_a_OBJECTS = at.$(OBJEXT) libapache_test_a_OBJECTS = $(am_libapache_test_a_OBJECTS) check_PROGRAMS = version$(EXEEXT) cookie$(EXEEXT) params$(EXEEXT) \ parsers$(EXEEXT) error$(EXEEXT) util$(EXEEXT) cookie_SOURCES = cookie.c cookie_OBJECTS = cookie.$(OBJEXT) cookie_LDADD = $(LDADD) cookie_DEPENDENCIES = libapache_test.a cookie_LDFLAGS = error_SOURCES = error.c error_OBJECTS = error.$(OBJEXT) error_LDADD = $(LDADD) error_DEPENDENCIES = libapache_test.a error_LDFLAGS = params_SOURCES = params.c params_OBJECTS = params.$(OBJEXT) params_LDADD = $(LDADD) params_DEPENDENCIES = libapache_test.a params_LDFLAGS = parsers_SOURCES = parsers.c parsers_OBJECTS = parsers.$(OBJEXT) parsers_LDADD = $(LDADD) parsers_DEPENDENCIES = libapache_test.a parsers_LDFLAGS = util_SOURCES = util.c util_OBJECTS = util.$(OBJEXT) util_LDADD = $(LDADD) util_DEPENDENCIES = libapache_test.a util_LDFLAGS = version_SOURCES = version.c version_OBJECTS = version.$(OBJEXT) version_LDADD = $(LDADD) version_DEPENDENCIES = libapache_test.a version_LDFLAGS = DEFS = @DEFS@ DEFAULT_INCLUDES = -I. -I$(srcdir) -I$(top_builddir)/include CPPFLAGS = @CPPFLAGS@ LDFLAGS = @LDFLAGS@ LIBS = @LIBS@ depcomp = $(SHELL) $(top_srcdir)/depcomp am__depfiles_maybe = depfiles @AMDEP_TRUE@DEP_FILES = ./$(DEPDIR)/at.Po ./$(DEPDIR)/cookie.Po \ @AMDEP_TRUE@ ./$(DEPDIR)/error.Po ./$(DEPDIR)/params.Po \ @AMDEP_TRUE@ ./$(DEPDIR)/parsers.Po ./$(DEPDIR)/util.Po \ @AMDEP_TRUE@ ./$(DEPDIR)/version.Po COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) LTCOMPILE = $(LIBTOOL) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) \ $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) CCLD = $(CC) LINK = $(LIBTOOL) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ $(AM_LDFLAGS) $(LDFLAGS) -o $@ CFLAGS = @CFLAGS@ DIST_SOURCES = $(libapache_test_a_SOURCES) cookie.c error.c params.c \ parsers.c util.c version.c DIST_COMMON = Makefile.am Makefile.in SOURCES = $(libapache_test_a_SOURCES) cookie.c error.c params.c parsers.c util.c version.c all: all-am .SUFFIXES: .SUFFIXES: .c .lo .o .obj $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ Makefile.am $(top_srcdir)/configure.ac $(ACLOCAL_M4) cd $(top_srcdir) && \ $(AUTOMAKE) --gnu library/t/Makefile Makefile: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.in $(top_builddir)/config.status cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe) clean-noinstLIBRARIES: -test -z "$(noinst_LIBRARIES)" || rm -f $(noinst_LIBRARIES) libapache_test.a: $(libapache_test_a_OBJECTS) $(libapache_test_a_DEPENDENCIES) -rm -f libapache_test.a $(libapache_test_a_AR) libapache_test.a $(libapache_test_a_OBJECTS) $(libapache_test_a_LIBADD) $(RANLIB) libapache_test.a clean-checkPROGRAMS: @list='$(check_PROGRAMS)'; for p in $$list; do \ f=`echo $$p|sed 's/$(EXEEXT)$$//'`; \ echo " rm -f $$p $$f"; \ rm -f $$p $$f ; \ done cookie$(EXEEXT): $(cookie_OBJECTS) $(cookie_DEPENDENCIES) @rm -f cookie$(EXEEXT) $(LINK) $(cookie_LDFLAGS) $(cookie_OBJECTS) $(cookie_LDADD) $(LIBS) error$(EXEEXT): $(error_OBJECTS) $(error_DEPENDENCIES) @rm -f error$(EXEEXT) $(LINK) $(error_LDFLAGS) $(error_OBJECTS) $(error_LDADD) $(LIBS) params$(EXEEXT): $(params_OBJECTS) $(params_DEPENDENCIES) @rm -f params$(EXEEXT) $(LINK) $(params_LDFLAGS) $(params_OBJECTS) $(params_LDADD) $(LIBS) parsers$(EXEEXT): $(parsers_OBJECTS) $(parsers_DEPENDENCIES) @rm -f parsers$(EXEEXT) $(LINK) $(parsers_LDFLAGS) $(parsers_OBJECTS) $(parsers_LDADD) $(LIBS) util$(EXEEXT): $(util_OBJECTS) $(util_DEPENDENCIES) @rm -f util$(EXEEXT) $(LINK) $(util_LDFLAGS) $(util_OBJECTS) $(util_LDADD) $(LIBS) version$(EXEEXT): $(version_OBJECTS) $(version_DEPENDENCIES) @rm -f version$(EXEEXT) $(LINK) $(version_LDFLAGS) $(version_OBJECTS) $(version_LDADD) $(LIBS) mostlyclean-compile: -rm -f *.$(OBJEXT) core *.core distclean-compile: -rm -f *.tab.c @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/at.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cookie.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/error.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/params.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/parsers.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/util.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/version.Po@am__quote@ distclean-depend: -rm -rf ./$(DEPDIR) .c.o: @AMDEP_TRUE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@ depfile='$(DEPDIR)/$*.Po' tmpdepfile='$(DEPDIR)/$*.TPo' @AMDEPBACKSLASH@ @AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ $(COMPILE) -c `test -f '$<' || echo '$(srcdir)/'`$< .c.obj: @AMDEP_TRUE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@ depfile='$(DEPDIR)/$*.Po' tmpdepfile='$(DEPDIR)/$*.TPo' @AMDEPBACKSLASH@ @AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ $(COMPILE) -c `cygpath -w $<` .c.lo: @AMDEP_TRUE@ source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@ depfile='$(DEPDIR)/$*.Plo' tmpdepfile='$(DEPDIR)/$*.TPlo' @AMDEPBACKSLASH@ @AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ $(LTCOMPILE) -c -o $@ `test -f '$<' || echo '$(srcdir)/'`$< CCDEPMODE = @CCDEPMODE@ mostlyclean-libtool: -rm -f *.lo clean-libtool: -rm -rf .libs _libs distclean-libtool: -rm -f libtool uninstall-info-am: ETAGS = etags ETAGSFLAGS = tags: TAGS 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; } \ END { for (i in files) print i; }'`; \ mkid -fID $$unique TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ $(TAGS_FILES) $(LISP) tags=; \ here=`pwd`; \ 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; } \ END { for (i in files) print i; }'`; \ test -z "$(ETAGS_ARGS)$$tags$$unique" \ || $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ $$tags $$unique GTAGS: here=`$(am__cd) $(top_builddir) && pwd` \ && cd $(top_srcdir) \ && gtags -i $(GTAGS_ARGS) $$here distclean-tags: -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH check-TESTS: $(TESTS) @failed=0; all=0; xfail=0; xpass=0; \ srcdir=$(srcdir); export srcdir; \ list='$(TESTS)'; \ if test -n "$$list"; then \ for tst in $$list; do \ if test -f ./$$tst; then dir=./; \ elif test -f $$tst; then dir=; \ else dir="$(srcdir)/"; fi; \ if $(TESTS_ENVIRONMENT) $${dir}$$tst; then \ all=`expr $$all + 1`; \ case " $(XFAIL_TESTS) " in \ *" $$tst "*) \ xpass=`expr $$xpass + 1`; \ failed=`expr $$failed + 1`; \ echo "XPASS: $$tst"; \ ;; \ *) \ echo "PASS: $$tst"; \ ;; \ esac; \ elif test $$? -ne 77; then \ all=`expr $$all + 1`; \ case " $(XFAIL_TESTS) " in \ *" $$tst "*) \ xfail=`expr $$xfail + 1`; \ echo "XFAIL: $$tst"; \ ;; \ *) \ failed=`expr $$failed + 1`; \ echo "FAIL: $$tst"; \ ;; \ esac; \ fi; \ done; \ if test "$$failed" -eq 0; then \ if test "$$xfail" -eq 0; then \ banner="All $$all tests passed"; \ else \ banner="All $$all tests behaved as expected ($$xfail expected failures)"; \ fi; \ else \ if test "$$xpass" -eq 0; then \ banner="$$failed of $$all tests failed"; \ else \ banner="$$failed of $$all tests did not behave as expected ($$xpass unexpected passes)"; \ fi; \ fi; \ dashes=`echo "$$banner" | sed s/./=/g`; \ echo "$$dashes"; \ echo "$$banner"; \ echo "$$dashes"; \ test "$$failed" -eq 0; \ else :; fi DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) top_distdir = ../.. distdir = $(top_distdir)/$(PACKAGE)-$(VERSION) distdir: $(DISTFILES) @list='$(DISTFILES)'; for file in $$list; do \ if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ dir=`echo "$$file" | sed -e 's,/[^/]*$$,,'`; \ if test "$$dir" != "$$file" && test "$$dir" != "."; then \ dir="/$$dir"; \ $(mkinstalldirs) "$(distdir)$$dir"; \ else \ dir=''; \ fi; \ if test -d $$d/$$file; then \ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \ fi; \ cp -pR $$d/$$file $(distdir)$$dir || exit 1; \ else \ test -f $(distdir)/$$file \ || cp -p $$d/$$file $(distdir)/$$file \ || exit 1; \ fi; \ done check-am: all-am $(MAKE) $(AM_MAKEFLAGS) $(check_PROGRAMS) $(check_SCRIPTS) $(MAKE) $(AM_MAKEFLAGS) check-TESTS check: check-am all-am: Makefile $(LIBRARIES) installdirs: 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_STRIP_FLAG=-s \ `test -z '$(STRIP)' || \ echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install mostlyclean-generic: clean-generic: -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES) distclean-generic: -rm -f Makefile $(CONFIG_CLEAN_FILES) maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." clean: clean-am clean-am: clean-checkPROGRAMS clean-generic clean-libtool \ clean-noinstLIBRARIES mostlyclean-am distclean: distclean-am distclean-am: clean-am distclean-compile distclean-depend \ distclean-generic distclean-libtool distclean-tags dvi: dvi-am dvi-am: info: info-am info-am: install-data-am: install-exec-am: install-info: install-info-am install-man: installcheck-am: maintainer-clean: maintainer-clean-am maintainer-clean-am: distclean-am maintainer-clean-generic mostlyclean: mostlyclean-am mostlyclean-am: mostlyclean-compile mostlyclean-generic \ mostlyclean-libtool uninstall-am: uninstall-info-am .PHONY: GTAGS all all-am check check-TESTS check-am clean \ clean-checkPROGRAMS clean-generic clean-libtool \ clean-noinstLIBRARIES distclean distclean-compile \ distclean-depend distclean-generic distclean-libtool \ distclean-tags distdir dvi dvi-am info info-am install \ install-am install-data install-data-am install-exec \ install-exec-am install-info install-info-am install-man \ install-strip installcheck installcheck-am installdirs \ maintainer-clean maintainer-clean-generic mostlyclean \ mostlyclean-compile mostlyclean-generic mostlyclean-libtool \ tags uninstall uninstall-am uninstall-info-am %.t: % echo "#!perl" > $@ echo "exec './$*'" >> $@ test: $(check_SCRIPTS) $(TESTS_ENVIRONMENT) $(check_SCRIPTS) # 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: rapache-1.2.8/libapreq2/library/t/at.c0000644000175100017510000001727512706745114017036 0ustar ondrejondrej/* ** Copyright 2004-2005 The Apache Software Foundation ** ** Licensed under the Apache License, Version 2.0 (the "License"); ** you may not use this file except in compliance with the License. ** You may obtain a copy of the License at ** ** http://www.apache.org/licenses/LICENSE-2.0 ** ** Unless required by applicable law or agreed to in writing, software ** distributed under the License is distributed on an "AS IS" BASIS, ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ** See the License for the specific language governing permissions and ** limitations under the License. */ #include "apr_file_io.h" #include "at.h" #include "apr_lib.h" #include "apr_strings.h" #include "apr_tables.h" #include "apr_env.h" #include apr_status_t at_begin(at_t *t, int total) { char buf[32]; apr_snprintf(buf, 32, "1..%d", total); return at_report(t, buf); } static apr_status_t test_cleanup(void *data) { at_t *t = data; if (t->current < t->plan) return at_report(t, "Bail out!"); else return at_report(t, "END"); } void at_end(at_t *t) { apr_pool_cleanup_kill(t->pool, t, test_cleanup); test_cleanup(t); } apr_status_t at_comment(at_t *t, const char *fmt, va_list vp) { apr_status_t s; char buf[256], *b = buf + 2; char *end; int rv; rv = apr_vsnprintf(b, 250, fmt, vp); if (rv <= 0) return APR_EINVAL; end = b + rv; buf[0] = '#'; buf[1] = ' '; if (rv == 250) { end[-1] = '.'; *end++ = '.'; *end++ = '.'; *end++ = '\n'; *end = 0; } else if (end[-1] != '\n') { *end++ = '\n'; *end = 0; } b = buf; while (1) { char *eol; eol = strchr(b + 2, '\n'); *eol = 0; s = at_report(t, b); if (s != APR_SUCCESS || eol == end - 1) break; b = eol - 1; b[0] = '#'; b[1] = ' '; } return s; } void at_ok(at_t *t, int is_ok, const char *label, const char *file, int line) { char format[] = "not ok %d - %s # %s (%s:%d) test %d in %s"; char *end = format + 10; char *fmt = is_ok ? format + 4 : format; char buf[256]; const char *comment = NULL; int rv, is_fatal = 0, is_skip = 0, is_todo = 0; t->current++; if (*t->fatal == t->current) { t->fatal++; is_fatal = 1; } if (*t->skip == t->current) { t->skip++; is_skip = 1; } if (*t->todo == t->current) { t->todo++; is_todo = 1; } if (AT_FLAG_CONCISE(t->flags)) format[9] = '\0'; else if (is_ok && !AT_FLAG_TRACE(t->flags)) format[14] = '\0'; else if (is_fatal && ! is_ok) comment = "fatal"; else comment = is_todo ? "todo" : is_skip ? "skip" : "at"; rv = apr_snprintf(buf, 256, fmt, t->current + t->prior, label, comment, file, line, t->current, t->name); if (rv <= 0) exit(-1); end = buf + rv; if (rv == 250) { *end++ = '.'; *end++ = '.'; *end++ = '.'; *end = '\0'; } if (memchr(buf, '\n', rv) != NULL || at_report(t, buf) != APR_SUCCESS) exit(-1); if (!is_ok && is_fatal) { while (t->current++ < t->plan) { apr_snprintf(buf, 256, "not ok %d # skipped: aborting test %s", t->prior + t->current, t->name); at_report(t, buf); } longjmp(*t->abort, 0); } } struct at_report_file { at_report_t module; apr_file_t *file; }; static apr_status_t at_report_file_write(at_report_t *ctx, const char *msg) { struct at_report_file *r = (struct at_report_file *)ctx; apr_file_t *f = r->file; apr_size_t len = strlen(msg); apr_status_t s; s = apr_file_write_full(f, msg, len, &len); if (s != APR_SUCCESS) return s; s = apr_file_putc('\n', f); if (s != APR_SUCCESS) return s; return apr_file_flush(f); } at_report_t *at_report_file_make(apr_pool_t *p, apr_file_t *f) { struct at_report_file *r = apr_palloc(p, sizeof *r); r->module.func = at_report_file_write; r->file = f; return &r->module; } struct at_report_local { at_report_t module; at_t *t; at_report_t *saved_report; const int *saved_fatal; int dummy_fatal; const char *file; int line; int passed; apr_pool_t *pool; }; static apr_status_t report_local_cleanup(void *data) { struct at_report_local *q = data; dAT = q->t; char label[32]; apr_snprintf(label, 32, "collected %d passing tests", q->passed); AT->report = q->saved_report; AT->fatal = q->saved_fatal; at_ok(q->t, 1, label, q->file, q->line); return APR_SUCCESS; } static apr_status_t at_report_local_write(at_report_t *ctx, const char *msg) { char buf[256]; struct at_report_local *q = (struct at_report_local *)ctx; dAT = q->t; if (strncmp(msg, "not ok", 6) == 0) { q->saved_report->func(q->saved_report, msg); AT->report = q->saved_report; AT->fatal = q->saved_fatal; apr_pool_cleanup_kill(q->pool, q, report_local_cleanup); while (AT->current++ < AT->plan) { apr_snprintf(buf, 256, "not ok %d # skipped: aborting test %s", AT->prior + AT->current, AT->name); at_report(AT, buf); } longjmp(*AT->abort, 0); } else if (strncmp(msg, "ok", 2) == 0) { AT->current--; q->passed++; } return APR_SUCCESS; } void at_report_local(at_t *AT, apr_pool_t *p, const char *file, int line) { struct at_report_local *q = apr_palloc(p, sizeof *q); q->module.func = at_report_local_write; q->t = AT; q->saved_report = AT->report; q->saved_fatal = AT->fatal; q->dummy_fatal = 0; q->file = apr_pstrdup(p, file); q->line = line; q->passed = 0; q->pool = p; AT->fatal = &q->dummy_fatal; AT->report = &q->module; if (*q->saved_fatal == AT->current + 1) q->saved_fatal++; apr_pool_cleanup_register(p, q, report_local_cleanup, report_local_cleanup); } at_t *at_create(apr_pool_t *pool, unsigned char flags, at_report_t *report) { at_t *t = apr_pcalloc(pool, sizeof *t); t->flags = flags; t->report = report; t->pool = pool; apr_pool_cleanup_register(pool, t, test_cleanup, test_cleanup); return t; } #define AT_NELTS 4 static int* at_list(apr_pool_t *pool, const char *spec, int *list) { apr_array_header_t arr; int prev, current = 0; arr.pool = pool; arr.elt_size = sizeof *list; arr.nelts = 0; arr.nalloc = AT_NELTS; arr.elts = (char *)list; do { while (*spec && !apr_isdigit(*spec)) ++spec; prev = current; current = (int)apr_strtoi64(spec, (char **)(void *)&spec, 10); *(int *)apr_array_push(&arr) = current; } while (prev >= current); return (int *)arr.elts; } apr_status_t at_run(at_t *AT, const at_test_t *test) { int dummy = 0, fbuf[AT_NELTS], sbuf[AT_NELTS], tbuf[AT_NELTS]; jmp_buf j; AT->current = 0; AT->prior += AT->plan; AT->name = test->name; AT->plan = test->plan; if (test->fatals) AT->fatal = at_list(AT->pool, test->fatals, fbuf); else AT->fatal = &dummy; if (test->skips) AT->skip = at_list(AT->pool, test->skips, sbuf); else AT->skip = &dummy; if (test->todos) AT->todo = at_list(AT->pool, test->todos, tbuf); else AT->todo = &dummy; AT->abort = &j; if (setjmp(j) == 0) { test->func(AT); return APR_SUCCESS; } AT->abort = NULL; return APR_EGENERAL; } rapache-1.2.8/libapreq2/library/t/at.h0000644000175100017510000002304512706745114017033 0ustar ondrejondrej/* ** Copyright 2004-2005 The Apache Software Foundation ** ** Licensed under the Apache License, Version 2.0 (the "License"); ** you may not use this file except in compliance with the License. ** You may obtain a copy of the License at ** ** http://www.apache.org/licenses/LICENSE-2.0 ** ** Unless required by applicable law or agreed to in writing, software ** distributed under the License is distributed on an "AS IS" BASIS, ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ** See the License for the specific language governing permissions and ** limitations under the License. */ /* at.h: TAP-compliant C utilities for the Apache::Test framework. */ #ifndef AT_H #define AT_H #include "apr.h" #include "apr_file_io.h" #include #include #include #include "apr_strings.h" typedef struct at_t at_t; typedef struct at_report_t at_report_t; typedef apr_status_t (*at_report_function_t)(at_report_t *r, const char *msg); typedef void(*at_test_function_t)(at_t *t); typedef struct at_test_t at_test_t; struct at_test_t { const char *name; at_test_function_t func; int plan; const char *fatals; const char *skips; const char *todos; }; struct at_report_t { at_report_function_t func; }; /* We only need one at_t struct per test suite, so lets call it *AT. * The mnemonic we follow is that (for lowercase foo) "AT_foo(bar)" * should be syntactically equivalent to "at_foo(AT, bar)". * * Terminology: test == an at_test_t, * check == an assertion which produces TAP. */ #define dAT at_t *AT struct at_t { int current; /* current check for this test */ int prior; /* total # of checks prior to this test */ const char *name; /* name of current test */ int plan; /* total # of checks in this test */ const int *fatal; /* list of unrecoverables */ const int *skip; /* list of ignorabe assertions */ const int *todo; /* list of expected failures */ at_report_t *report ;/* handles the results of each check */ unsigned char flags; /* verbosity: concise, trace, debug, etc. */ apr_pool_t *pool; /* creator pool with end-of-test cleanup */ jmp_buf *abort; /* where fatals go to die */ }; static APR_INLINE apr_status_t at_report(at_t *t, const char *msg) { at_report_t *r = t->report; return r->func(r, msg); } #define AT_report(msg) at_report(AT, msg) /* The core assertion checker; the rest just wind up invoking this one. */ void at_ok(at_t *t, int is_ok, const char *label, const char *file, int line); #define AT_ok(is_ok, label) at_ok(AT, is_ok, label, __FILE__, __LINE__) at_t *at_create(apr_pool_t *pool, unsigned char flags, at_report_t *report); apr_status_t at_begin(at_t *t, int total); #define AT_begin(total) at_begin(AT, total) apr_status_t at_run(at_t *AT, const at_test_t *test); #define AT_run(test) at_run(AT, test) void at_end(at_t *t); #define AT_end() at_end(AT) #define AT_FLAG_DEBUG(f) ((f) & 4) #define AT_FLAG_DEBUG_ON(f) ((f) |= 4) #define AT_FLAG_DEBUG_OFF(f) ((f) &= ~4) #define AT_FLAG_TRACE(f) ((f) & 2) #define AT_FLAG_TRACE_ON(f) ((f) |= 2) #define AT_FLAG_TRACE_OFF(f) ((f) &= ~2) #define AT_FLAG_CONCISE(f) ((f) & 1) #define AT_FLAG_CONCISE_ON(f) ((f) |= 1) #define AT_FLAG_CONCISE_OFF(f) ((f) &= ~1) #define AT_debug_on() AT_FLAG_DEBUG_ON(AT->flags) #define AT_debug_off() AT_FLAG_DEBUG_OFF(AT->flags) #define AT_trace_on() AT_FLAG_TRACE_ON(AT->flags) #define AT_trace_off() AT_FLAG_TRACE_OFF(AT->flags) #define AT_concise_on() AT_FLAG_CONCISE_ON(AT->flags) #define AT_concise_off() AT_FLAG_CONCISE_OFF(AT->flags) /* Additional reporting utils. These emit TAP comments, and are not "checks". */ apr_status_t at_comment(at_t *t, const char *fmt, va_list vp); static APR_INLINE void at_debug(at_t *t, const char *fmt, ...) { va_list vp; va_start(vp, fmt); if (AT_FLAG_DEBUG(t->flags)) at_comment(t, fmt, vp); va_end(vp); } static APR_INLINE void at_trace(at_t *t, const char *fmt, ...) { va_list vp; va_start(vp, fmt); if (AT_FLAG_TRACE(t->flags)) at_comment(t, fmt, vp); va_end(vp); } /* These are "checks". */ static APR_INLINE void at_check(at_t *t, int is_ok, const char *label, const char *file, int line, const char *fmt, ...) { va_list vp; va_start(vp, fmt); if (AT_FLAG_TRACE(t->flags)) { char format[32] = "testing: %s (%s:%d)"; at_trace(t, format, label, file, line); if (fmt != NULL) { apr_snprintf(format, sizeof format, " format: %s", fmt); at_trace(t, "%s", format); memcpy(format, " left:", 8); at_comment(t, format, vp); memcpy(format, " right:", 8); at_comment(t, format, vp); } } va_end(vp); at_ok(t, is_ok, label, file, line); } #define AT_mem_ne(a, b, n) do { \ unsigned sz = n; \ const void *left = a, *right = b; \ char fmt[] = ", as %u-byte struct pointers"; \ char buf[256] = #a " != " #b; \ const unsigned blen = sizeof(#a " != " #b); \ apr_snprintf(buf + blen - 1, 256 - blen, fmt, sz); \ apr_snprintf(fmt, sizeof(fmt), "%%.%us", sz); \ at_check(AT, memcmp(left, right, sz), buf, __FILE__, __LINE__, \ fmt, left, right); \ } while (0) \ #define AT_mem_eq(a, b, n) do { \ unsigned sz = n; \ const void *left = a, *right = b; \ char fmt[] = ", as %u-byte struct pointers"; \ char buf[256] = #a " == " #b; \ const unsigned blen = sizeof(#a " == " #b); \ apr_snprintf(buf + blen - 1, 256 - blen , fmt, sz); \ apr_snprintf(fmt, sizeof(fmt), "%%.%us", sz); \ at_check(AT, !memcmp(left, right, sz), buf, __FILE__, __LINE__, \ fmt, left, right); \ } while (0) #define AT_str_eq(a, b) do { \ const char *left = a, *right = b; \ at_check(AT,!strcmp(left, right), #a " == " #b ", as strings", \ __FILE__, __LINE__, "%s", left, right); \ } while (0) #define AT_str_ne(a, b) do { \ const char *left = a, *right = b; \ at_check(AT, strcmp(left, right), #a " != " #b ", as strings", \ __FILE__, __LINE__, "%s", left, right); \ } while (0) #define AT_ptr_eq(a, b) do { \ const void *left = a, *right = b; \ at_check(AT, left == right, #a " == " #b ", as pointers", \ __FILE__, __LINE__, "%pp", left, right); \ } while (0) #define AT_ptr_ne(a, b) do { \ const void *left = a, *right = b; \ at_check(AT, left != right, #a " != " #b ", as pointers", \ __FILE__, __LINE__, "%pp", left, right); \ } while (0) #define AT_int_eq(a, b) do { \ const int left = a, right = b; \ at_check(AT, left == right, #a " == " #b ", as integers", \ __FILE__, __LINE__, "%d", left, right); \ } while (0) #define AT_int_ne(a, b) do { \ const int left = a, right = b; \ at_check(AT, left != right, #a " != " #b ", as integers", \ __FILE__, __LINE__, "%d", left, right); \ } while (0) #define AT_is_null(a) AT_ptr_eq(a, NULL) #define AT_not_null(a) AT_ptr_ne(a, NULL) /* XXX these two macro checks evaluate a & b more than once, but the * upshot is that they don't care too much about their types. */ #define AT_EQ(a, b, fmt) at_check(AT, ((a) == (b)), #a " == " #b,\ __FILE__, __LINE__, fmt, a, b) #define AT_NE(a, b, fmt) at_check(AT, ((a) != (b)), #a " != " #b,\ __FILE__, __LINE__, fmt, a, b) static APR_INLINE void at_skip(at_t *t, int n, const char *reason, const char *file, int line) { char buf[256]; while (n-- > 0) { ++t->current; apr_snprintf(buf, 256, "not ok %d - %s (%d) #skipped: %s (%s:%d)", t->current + t->prior, t->name, t->current, reason, file, line); at_report(t, buf); } } #define AT_skip(n, reason) at_skip(AT, n, reason, __FILE__, __LINE__) /* Report utilities. */ at_report_t *at_report_file_make(apr_pool_t *p, apr_file_t *f); APR_INLINE static at_report_t *at_report_stdout_make(apr_pool_t *p) { apr_file_t *out; apr_file_open_stdout(&out, p); return at_report_file_make(p, out); } void at_report_local(at_t *AT, apr_pool_t *p, const char *file, int line); #define AT_localize(p) at_report_local(AT, p, __FILE__, __LINE__) #endif /* AT_H */ rapache-1.2.8/libapreq2/library/t/cookie0000755000175100017510000001174012706745114017454 0ustar ondrejondrej#! /bin/sh # cookie - temporary wrapper script for .libs/cookie # Generated by ltmain.sh - GNU libtool 1.5.6 (1.1220.2.95 2004/04/11 05:50:42) Debian: 224 $ # # The cookie 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='/bin/sed -e 1s/^X//' sed_quote_subst='s/\([\\`\\"$\\\\]\)/\\\1/g' # The HP-UX ksh and POSIX shell print the target directory to stdout # if CDPATH is set. if test "${CDPATH+set}" = set; then CDPATH=:; export CDPATH; fi relink_command="(cd /home/joe/src/apache/httpd/apreq/trunk/library/t; { test -z \"\${LIBRARY_PATH+set}\" || unset LIBRARY_PATH || { LIBRARY_PATH=; export LIBRARY_PATH; }; }; { test -z \"\${COMPILER_PATH+set}\" || unset COMPILER_PATH || { COMPILER_PATH=; export COMPILER_PATH; }; }; { test -z \"\${GCC_EXEC_PREFIX+set}\" || unset GCC_EXEC_PREFIX || { GCC_EXEC_PREFIX=; export GCC_EXEC_PREFIX; }; }; { test -z \"\${LD_RUN_PATH+set}\" || unset LD_RUN_PATH || { LD_RUN_PATH=; export LD_RUN_PATH; }; }; PATH=\"/usr/local/bin:/usr/bin:/bin:/usr/X11R6/bin:/usr/games\"; export PATH; gcc -g -O2 -Werror -Wall -Wmissing-prototypes -Wstrict-prototypes -Wmissing-declarations -Wwrite-strings -Wcast-qual -Wfloat-equal -Wshadow -Wpointer-arith -Wbad-function-cast -Wsign-compare -Waggregate-return -Wmissing-noreturn -Wmissing-format-attribute -Wpacked -Wredundant-decls -Wnested-externs -Wdisabled-optimization -Wno-long-long -Wendif-labels -Wcast-align -o \$progdir/\$file cookie.o /home/joe/src/apache/httpd/apreq/trunk/library/.libs/libapreq2.so /usr/lib/libgdbm.so /usr/lib/libdb-4.2.so /usr/lib/libexpat.so -lrt -lcrypt -lpthread -ldl /home/joe/httpd/trunk/worker/lib/libapr-1.so /home/joe/httpd/trunk/worker/lib/libaprutil-1.so libapache_test.a -Wl,--rpath -Wl,/home/joe/src/apache/httpd/apreq/trunk/library/.libs -Wl,--rpath -Wl,/home/joe/httpd/trunk/worker/lib -Wl,--rpath -Wl,/home/joe/httpd/trunk/worker/lib)" # This environment variable determines our operation mode. if test "$libtool_install_magic" = "%%%MAGIC variable%%%"; then # install mode needs the following variable: notinst_deplibs=' /home/joe/src/apache/httpd/apreq/trunk/library/libapreq2.la' else # When we are sourced in execute mode, $file and $echo are already set. if test "$libtool_execute_magic" != "%%%MAGIC variable%%%"; then echo="echo" 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 /bin/sh "$0" --no-reexec ${1+"$@"} fi fi # Find the directory that this script lives in. thisdir=`$echo "X$file" | $Xsed -e 's%/[^/]*$%%'` test "x$thisdir" = "x$file" && thisdir=. # Follow symbolic links until we get to the real thisdir. file=`ls -ld "$file" | /bin/sed -n 's/.*-> //p'` while test -n "$file"; do destdir=`$echo "X$file" | $Xsed -e 's%/[^/]*$%%'` # 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 file=`$echo "X$file" | $Xsed -e 's%^.*/%%'` file=`ls -ld "$thisdir/$file" | /bin/sed -n 's/.*-> //p'` done # Try to get the absolute directory name. absdir=`cd "$thisdir" && pwd` test -n "$absdir" && thisdir="$absdir" program=lt-'cookie' progdir="$thisdir/.libs" if test ! -f "$progdir/$program" || \ { file=`ls -1dt "$progdir/$program" "$progdir/../$program" 2>/dev/null | /bin/sed 1q`; \ test "X$file" != "X$progdir/$program"; }; then file="$$-$program" if test ! -d "$progdir"; then mkdir "$progdir" else rm -f "$progdir/$file" 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 -f "$progdir/$file" exit 1 fi fi mv -f "$progdir/$file" "$progdir/$program" 2>/dev/null || { rm -f "$progdir/$program"; mv -f "$progdir/$file" "$progdir/$program"; } rm -f "$progdir/$file" fi if test -f "$progdir/$program"; then if test "$libtool_execute_magic" != "%%%MAGIC variable%%%"; then # Run the actual program with our arguments. exec $progdir/$program ${1+"$@"} $echo "$0: cannot exec $program ${1+"$@"}" exit 1 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 libtool documentation for more information." 1>&2 exit 1 fi fi rapache-1.2.8/libapreq2/library/t/cookie.c0000644000175100017510000001316012706745114017670 0ustar ondrejondrej/* ** Copyright 2003-2005 The Apache Software Foundation ** ** Licensed under the Apache License, Version 2.0 (the "License"); ** you may not use this file except in compliance with the License. ** You may obtain a copy of the License at ** ** http://www.apache.org/licenses/LICENSE-2.0 ** ** Unless required by applicable law or agreed to in writing, software ** distributed under the License is distributed on an "AS IS" BASIS, ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ** See the License for the specific language governing permissions and ** limitations under the License. */ #include "apr_strings.h" #include "apreq_cookie.h" #include "apreq_error.h" #include "apreq_module.h" #include "apreq_util.h" #include "at.h" static const char nscookies[] = "a=1; foo=bar; fl=left; fr=right;bad; " "ns=foo=1&bar=2,frl=right-left; " "flr=left-right; fll=left-left; " "good_one=1;=;bad"; static const char rfccookies[] = "$Version=1; first=a;$domain=quux;second=be," "$Version=1;third=cie"; static apr_table_t *jar, *jar2; static apr_pool_t *p; static void jar_make(dAT) { jar = apr_table_make(p, APREQ_DEFAULT_NELTS); AT_not_null(jar); AT_int_eq(apreq_parse_cookie_header(p, jar, nscookies), APREQ_ERROR_NOTOKEN); jar2 = apr_table_make(p, APREQ_DEFAULT_NELTS); AT_not_null(jar2); AT_int_eq(apreq_parse_cookie_header(p, jar2, rfccookies), APR_SUCCESS); } static void jar_get_rfc(dAT) { const char *val; AT_not_null(val = apr_table_get(jar2, "first")); AT_str_eq(val, "a"); AT_not_null(val = apr_table_get(jar2, "second")); AT_str_eq(val, "be"); AT_not_null(val = apr_table_get(jar2, "third")); AT_str_eq(val, "cie"); } static void jar_get_ns(dAT) { AT_str_eq(apr_table_get(jar, "a"), "1"); /* ignore wacky cookies that don't have an '=' sign */ AT_is_null(apr_table_get(jar, "bad")); /* accept wacky cookies that contain multiple '=' */ AT_str_eq(apr_table_get(jar, "ns"), "foo=1&bar=2"); AT_str_eq(apr_table_get(jar,"foo"), "bar"); AT_str_eq(apr_table_get(jar,"fl"), "left"); AT_str_eq(apr_table_get(jar,"fr"), "right"); AT_str_eq(apr_table_get(jar,"frl"), "right-left"); AT_str_eq(apr_table_get(jar,"flr"), "left-right"); AT_str_eq(apr_table_get(jar,"fll"), "left-left"); AT_is_null(apr_table_get(jar,"")); } static void netscape_cookie(dAT) { char expires[APR_RFC822_DATE_LEN]; char *val; apreq_cookie_t *c; *(const char **)&val = apr_table_get(jar, "foo"); AT_not_null(val); c = apreq_value_to_cookie(val); AT_str_eq(c->v.data, "bar"); AT_int_eq(apreq_cookie_version(c), 0); AT_str_eq(apreq_cookie_as_string(c, p), "foo=bar"); c->domain = apr_pstrdup(p, "example.com"); AT_str_eq(apreq_cookie_as_string(c, p), "foo=bar; domain=example.com"); c->path = apr_pstrdup(p, "/quux"); AT_str_eq(apreq_cookie_as_string(c, p), "foo=bar; path=/quux; domain=example.com"); apreq_cookie_expires(c, "+1y"); apr_rfc822_date(expires, apr_time_now() + apr_time_from_sec(apreq_atoi64t("+1y"))); expires[7] = '-'; expires[11] = '-'; val = apr_pstrcat(p, "foo=bar; path=/quux; domain=example.com; expires=", expires, NULL); AT_str_eq(apreq_cookie_as_string(c, p), val); } static void rfc_cookie(dAT) { apreq_cookie_t *c = apreq_cookie_make(p,"rfc",3,"out",3); const char *expected; long expires; AT_str_eq(c->v.data, "out"); apreq_cookie_version_set(c, 1); AT_int_eq(apreq_cookie_version(c), 1); AT_str_eq(apreq_cookie_as_string(c,p),"rfc=out; Version=1"); c->domain = apr_pstrdup(p, "example.com"); #ifndef WIN32 AT_str_eq(apreq_cookie_as_string(c,p), "rfc=out; Version=1; domain=\"example.com\""); c->path = apr_pstrdup(p, "/quux"); AT_str_eq(apreq_cookie_as_string(c,p), "rfc=out; Version=1; path=\"/quux\"; domain=\"example.com\""); apreq_cookie_expires(c, "+3m"); expires = apreq_atoi64t("+3m"); expected = apr_psprintf(p, "rfc=out; Version=1; path=\"/quux\"; " "domain=\"example.com\"; max-age=%ld", expires); AT_str_eq(apreq_cookie_as_string(c,p), expected); #else expected = "rfc=out; Version=1; domain=\"example.com\""; AT_str_eq(apreq_cookie_as_string(c,p), expected); c->path = apr_pstrdup(p, "/quux"); expected = "rfc=out; Version=1; path=\"/quux\"; domain=\"example.com\""; AT_str_eq(apreq_cookie_as_string(c,p), expected); apreq_cookie_expires(c, "+3m"); expires = apreq_atoi64t("+3m"); expected = apr_psprintf(p, "rfc=out; Version=1; path=\"/quux\"; " "domain=\"example.com\"; max-age=%ld", expires); AT_str_eq(apreq_cookie_as_string(c,p), expected); #endif } #define dT(func, plan) #func, func, plan int main(int argc, char *argv[]) { unsigned i, plan = 0; dAT; at_test_t test_list [] = { { dT(jar_make, 4) }, { dT(jar_get_rfc, 6), "1 3 5" }, { dT(jar_get_ns, 10) }, { dT(netscape_cookie, 7) }, { dT(rfc_cookie, 6) }, }; apr_initialize(); atexit(apr_terminate); apr_pool_create(&p, NULL); AT = at_create(p, 0, at_report_stdout_make(p)); for (i = 0; i < sizeof(test_list) / sizeof(at_test_t); ++i) plan += test_list[i].plan; AT_begin(plan); for (i = 0; i < sizeof(test_list) / sizeof(at_test_t); ++i) AT_run(&test_list[i]); AT_end(); return 0; } rapache-1.2.8/libapreq2/library/t/cookie.t0000644000175100017510000000002712706745114017707 0ustar ondrejondrej#!perl exec './cookie' rapache-1.2.8/libapreq2/library/t/error0000755000175100017510000001173312706745114017336 0ustar ondrejondrej#! /bin/sh # error - temporary wrapper script for .libs/error # Generated by ltmain.sh - GNU libtool 1.5.6 (1.1220.2.95 2004/04/11 05:50:42) Debian: 224 $ # # The error 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='/bin/sed -e 1s/^X//' sed_quote_subst='s/\([\\`\\"$\\\\]\)/\\\1/g' # The HP-UX ksh and POSIX shell print the target directory to stdout # if CDPATH is set. if test "${CDPATH+set}" = set; then CDPATH=:; export CDPATH; fi relink_command="(cd /home/joe/src/apache/httpd/apreq/trunk/library/t; { test -z \"\${LIBRARY_PATH+set}\" || unset LIBRARY_PATH || { LIBRARY_PATH=; export LIBRARY_PATH; }; }; { test -z \"\${COMPILER_PATH+set}\" || unset COMPILER_PATH || { COMPILER_PATH=; export COMPILER_PATH; }; }; { test -z \"\${GCC_EXEC_PREFIX+set}\" || unset GCC_EXEC_PREFIX || { GCC_EXEC_PREFIX=; export GCC_EXEC_PREFIX; }; }; { test -z \"\${LD_RUN_PATH+set}\" || unset LD_RUN_PATH || { LD_RUN_PATH=; export LD_RUN_PATH; }; }; PATH=\"/usr/local/bin:/usr/bin:/bin:/usr/X11R6/bin:/usr/games\"; export PATH; gcc -g -O2 -Werror -Wall -Wmissing-prototypes -Wstrict-prototypes -Wmissing-declarations -Wwrite-strings -Wcast-qual -Wfloat-equal -Wshadow -Wpointer-arith -Wbad-function-cast -Wsign-compare -Waggregate-return -Wmissing-noreturn -Wmissing-format-attribute -Wpacked -Wredundant-decls -Wnested-externs -Wdisabled-optimization -Wno-long-long -Wendif-labels -Wcast-align -o \$progdir/\$file error.o /home/joe/src/apache/httpd/apreq/trunk/library/.libs/libapreq2.so /usr/lib/libgdbm.so /usr/lib/libdb-4.2.so /usr/lib/libexpat.so -lrt -lcrypt -lpthread -ldl /home/joe/httpd/trunk/worker/lib/libapr-1.so /home/joe/httpd/trunk/worker/lib/libaprutil-1.so libapache_test.a -Wl,--rpath -Wl,/home/joe/src/apache/httpd/apreq/trunk/library/.libs -Wl,--rpath -Wl,/home/joe/httpd/trunk/worker/lib -Wl,--rpath -Wl,/home/joe/httpd/trunk/worker/lib)" # This environment variable determines our operation mode. if test "$libtool_install_magic" = "%%%MAGIC variable%%%"; then # install mode needs the following variable: notinst_deplibs=' /home/joe/src/apache/httpd/apreq/trunk/library/libapreq2.la' else # When we are sourced in execute mode, $file and $echo are already set. if test "$libtool_execute_magic" != "%%%MAGIC variable%%%"; then echo="echo" 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 /bin/sh "$0" --no-reexec ${1+"$@"} fi fi # Find the directory that this script lives in. thisdir=`$echo "X$file" | $Xsed -e 's%/[^/]*$%%'` test "x$thisdir" = "x$file" && thisdir=. # Follow symbolic links until we get to the real thisdir. file=`ls -ld "$file" | /bin/sed -n 's/.*-> //p'` while test -n "$file"; do destdir=`$echo "X$file" | $Xsed -e 's%/[^/]*$%%'` # 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 file=`$echo "X$file" | $Xsed -e 's%^.*/%%'` file=`ls -ld "$thisdir/$file" | /bin/sed -n 's/.*-> //p'` done # Try to get the absolute directory name. absdir=`cd "$thisdir" && pwd` test -n "$absdir" && thisdir="$absdir" program=lt-'error' progdir="$thisdir/.libs" if test ! -f "$progdir/$program" || \ { file=`ls -1dt "$progdir/$program" "$progdir/../$program" 2>/dev/null | /bin/sed 1q`; \ test "X$file" != "X$progdir/$program"; }; then file="$$-$program" if test ! -d "$progdir"; then mkdir "$progdir" else rm -f "$progdir/$file" 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 -f "$progdir/$file" exit 1 fi fi mv -f "$progdir/$file" "$progdir/$program" 2>/dev/null || { rm -f "$progdir/$program"; mv -f "$progdir/$file" "$progdir/$program"; } rm -f "$progdir/$file" fi if test -f "$progdir/$program"; then if test "$libtool_execute_magic" != "%%%MAGIC variable%%%"; then # Run the actual program with our arguments. exec $progdir/$program ${1+"$@"} $echo "$0: cannot exec $program ${1+"$@"}" exit 1 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 libtool documentation for more information." 1>&2 exit 1 fi fi rapache-1.2.8/libapreq2/library/t/error.c0000644000175100017510000000500412706745114017546 0ustar ondrejondrej/* ** Copyright 2003-2005 The Apache Software Foundation ** ** Licensed under the Apache License, Version 2.0 (the "License"); ** you may not use this file except in compliance with the License. ** You may obtain a copy of the License at ** ** http://www.apache.org/licenses/LICENSE-2.0 ** ** Unless required by applicable law or agreed to in writing, software ** distributed under the License is distributed on an "AS IS" BASIS, ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ** See the License for the specific language governing permissions and ** limitations under the License. */ #include "apr_strings.h" #include "apreq_error.h" #include "at.h" static void test_strerror(dAT) { char buf[256], *str; str = apreq_strerror(APREQ_ERROR_GENERAL, buf, sizeof buf); AT_ptr_eq(str, buf); AT_str_eq(str, "Internal apreq error"); str = apreq_strerror(APREQ_ERROR_TAINTED, buf, sizeof buf); AT_str_eq(str, "Attempt to perform unsafe action with tainted data"); str = apreq_strerror(APREQ_ERROR_BADSEQ, buf, sizeof buf); AT_str_eq(str, "Invalid byte sequence"); str = apreq_strerror(APREQ_ERROR_NODATA, buf, sizeof buf); AT_str_eq(str, "Missing input data"); str = apreq_strerror(APREQ_ERROR_GENERAL+99, buf, sizeof buf); AT_str_eq(str, "Error string not yet specified by apreq"); /* Test some common APR status codes also */ str = apreq_strerror(APR_EINIT, buf, sizeof buf); AT_str_eq(str, "There is no error, this value signifies an initialized " "error code"); str = apreq_strerror(APR_INCOMPLETE, buf, sizeof buf); AT_str_eq(str, "Partial results are valid but processing is incomplete"); str = apreq_strerror(APR_EOF, buf, sizeof buf); AT_str_eq(str, "End of file found"); str = apreq_strerror(APR_ENOTIMPL, buf, sizeof buf); AT_str_eq(str, "This function has not been implemented on this platform"); } #define dT(func, plan) #func, func, plan int main(int argc, char *argv[]) { unsigned i, plan = 0; apr_pool_t *p; dAT; at_test_t test_list [] = { { dT(test_strerror, 10), "1" } }; apr_initialize(); atexit(apr_terminate); apr_pool_create(&p, NULL); AT = at_create(p, 0, at_report_stdout_make(p)); for (i = 0; i < sizeof(test_list) / sizeof(at_test_t); ++i) plan += test_list[i].plan; AT_begin(plan); for (i = 0; i < sizeof(test_list) / sizeof(at_test_t); ++i) AT_run(&test_list[i]); AT_end(); return 0; } rapache-1.2.8/libapreq2/library/t/error.t0000644000175100017510000000002612706745114017566 0ustar ondrejondrej#!perl exec './error' rapache-1.2.8/libapreq2/library/t/params0000755000175100017510000001174012706745114017466 0ustar ondrejondrej#! /bin/sh # params - temporary wrapper script for .libs/params # Generated by ltmain.sh - GNU libtool 1.5.6 (1.1220.2.95 2004/04/11 05:50:42) Debian: 224 $ # # The params 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='/bin/sed -e 1s/^X//' sed_quote_subst='s/\([\\`\\"$\\\\]\)/\\\1/g' # The HP-UX ksh and POSIX shell print the target directory to stdout # if CDPATH is set. if test "${CDPATH+set}" = set; then CDPATH=:; export CDPATH; fi relink_command="(cd /home/joe/src/apache/httpd/apreq/trunk/library/t; { test -z \"\${LIBRARY_PATH+set}\" || unset LIBRARY_PATH || { LIBRARY_PATH=; export LIBRARY_PATH; }; }; { test -z \"\${COMPILER_PATH+set}\" || unset COMPILER_PATH || { COMPILER_PATH=; export COMPILER_PATH; }; }; { test -z \"\${GCC_EXEC_PREFIX+set}\" || unset GCC_EXEC_PREFIX || { GCC_EXEC_PREFIX=; export GCC_EXEC_PREFIX; }; }; { test -z \"\${LD_RUN_PATH+set}\" || unset LD_RUN_PATH || { LD_RUN_PATH=; export LD_RUN_PATH; }; }; PATH=\"/usr/local/bin:/usr/bin:/bin:/usr/X11R6/bin:/usr/games\"; export PATH; gcc -g -O2 -Werror -Wall -Wmissing-prototypes -Wstrict-prototypes -Wmissing-declarations -Wwrite-strings -Wcast-qual -Wfloat-equal -Wshadow -Wpointer-arith -Wbad-function-cast -Wsign-compare -Waggregate-return -Wmissing-noreturn -Wmissing-format-attribute -Wpacked -Wredundant-decls -Wnested-externs -Wdisabled-optimization -Wno-long-long -Wendif-labels -Wcast-align -o \$progdir/\$file params.o /home/joe/src/apache/httpd/apreq/trunk/library/.libs/libapreq2.so /usr/lib/libgdbm.so /usr/lib/libdb-4.2.so /usr/lib/libexpat.so -lrt -lcrypt -lpthread -ldl /home/joe/httpd/trunk/worker/lib/libapr-1.so /home/joe/httpd/trunk/worker/lib/libaprutil-1.so libapache_test.a -Wl,--rpath -Wl,/home/joe/src/apache/httpd/apreq/trunk/library/.libs -Wl,--rpath -Wl,/home/joe/httpd/trunk/worker/lib -Wl,--rpath -Wl,/home/joe/httpd/trunk/worker/lib)" # This environment variable determines our operation mode. if test "$libtool_install_magic" = "%%%MAGIC variable%%%"; then # install mode needs the following variable: notinst_deplibs=' /home/joe/src/apache/httpd/apreq/trunk/library/libapreq2.la' else # When we are sourced in execute mode, $file and $echo are already set. if test "$libtool_execute_magic" != "%%%MAGIC variable%%%"; then echo="echo" 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 /bin/sh "$0" --no-reexec ${1+"$@"} fi fi # Find the directory that this script lives in. thisdir=`$echo "X$file" | $Xsed -e 's%/[^/]*$%%'` test "x$thisdir" = "x$file" && thisdir=. # Follow symbolic links until we get to the real thisdir. file=`ls -ld "$file" | /bin/sed -n 's/.*-> //p'` while test -n "$file"; do destdir=`$echo "X$file" | $Xsed -e 's%/[^/]*$%%'` # 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 file=`$echo "X$file" | $Xsed -e 's%^.*/%%'` file=`ls -ld "$thisdir/$file" | /bin/sed -n 's/.*-> //p'` done # Try to get the absolute directory name. absdir=`cd "$thisdir" && pwd` test -n "$absdir" && thisdir="$absdir" program=lt-'params' progdir="$thisdir/.libs" if test ! -f "$progdir/$program" || \ { file=`ls -1dt "$progdir/$program" "$progdir/../$program" 2>/dev/null | /bin/sed 1q`; \ test "X$file" != "X$progdir/$program"; }; then file="$$-$program" if test ! -d "$progdir"; then mkdir "$progdir" else rm -f "$progdir/$file" 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 -f "$progdir/$file" exit 1 fi fi mv -f "$progdir/$file" "$progdir/$program" 2>/dev/null || { rm -f "$progdir/$program"; mv -f "$progdir/$file" "$progdir/$program"; } rm -f "$progdir/$file" fi if test -f "$progdir/$program"; then if test "$libtool_execute_magic" != "%%%MAGIC variable%%%"; then # Run the actual program with our arguments. exec $progdir/$program ${1+"$@"} $echo "$0: cannot exec $program ${1+"$@"}" exit 1 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 libtool documentation for more information." 1>&2 exit 1 fi fi rapache-1.2.8/libapreq2/library/t/params.c0000644000175100017510000001447712706745114017716 0ustar ondrejondrej/* ** Copyright 2003-2005 The Apache Software Foundation ** ** Licensed under the Apache License, Version 2.0 (the "License"); ** you may not use this file except in compliance with the License. ** You may obtain a copy of the License at ** ** http://www.apache.org/licenses/LICENSE-2.0 ** ** Unless required by applicable law or agreed to in writing, software ** distributed under the License is distributed on an "AS IS" BASIS, ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ** See the License for the specific language governing permissions and ** limitations under the License. */ #include "apreq_param.h" #include "apreq_util.h" #include "apreq_error.h" #include "apr_strings.h" #include "at.h" static const char query_string[] = "a=1;quux=foo+bar&a=2&plus=%2B;" "uplus=%U002b;okie=dokie;" "novalue1;novalue2="; static apr_table_t *args; static apr_pool_t *p; static void request_make(dAT) { apr_status_t s; args = apr_table_make(p, APREQ_DEFAULT_NELTS); AT_not_null(args); s = apreq_parse_query_string(p, args, query_string); AT_int_eq(s, APR_SUCCESS); AT_int_eq(apr_table_elts(args)->nelts, 8); } static void request_args_get(dAT) { const char *val; const apreq_param_t *param; AT_str_eq(apr_table_get(args,"a"), "1"); val = apr_table_get(args,"quux"); AT_str_eq(val, "foo bar"); param = apreq_value_to_param(val); AT_int_eq(param->v.dlen, 7); AT_str_eq(apr_table_get(args,"plus"), "+"); AT_str_eq(apr_table_get(args,"uplus"), "+"); AT_str_eq(apr_table_get(args,"okie"), "dokie"); AT_str_eq(apr_table_get(args,"novalue1"), ""); AT_str_eq(apr_table_get(args,"novalue2"),""); } static void params_as(dAT) { const char *val; apr_array_header_t *arr; arr = apreq_params_as_array(p,args,"a"); AT_int_eq(arr->nelts, 2); val = apreq_params_as_string(p,args,"a",APREQ_JOIN_AS_IS); AT_str_eq(val, "1, 2"); val = apreq_params_as_string(p,args,"does_not_exist",APREQ_JOIN_AS_IS); AT_str_eq(val, ""); } static void string_decoding_in_place(dAT) { char *s1 = apr_palloc(p,4096); char *s2 = apr_palloc(p,4096); char *s3; strcpy(s1, "bend it like beckham"); strcpy(s2, "dandy %3Edons"); AT_str_eq(s1,"bend it like beckham"); apreq_unescape(s1); AT_str_eq(s1, "bend it like beckham"); s3 = apreq_escape(p, s1, 20); AT_str_eq(s3, "bend+it+like+beckham"); apreq_unescape(s3); AT_str_eq(s3,"bend it like beckham"); AT_str_eq(s2,"dandy %3Edons"); apreq_unescape(s2); AT_str_eq(s2,"dandy >dons"); s3 = apreq_escape(p, s2, 11); AT_str_eq(s3,"dandy+%3Edons"); apreq_unescape(s3); AT_str_eq(s3,"dandy >dons"); } static void header_attributes(dAT) { const char *hdr = "text/plain; boundary=\"-foo-\", charset=ISO-8859-1"; const char *val; apr_size_t vlen; apr_status_t s; s = apreq_header_attribute(hdr, "none", 4, &val, &vlen); AT_int_eq(s, APREQ_ERROR_NOATTR); s = apreq_header_attribute(hdr, "set", 3, &val, &vlen); AT_int_eq(s, APREQ_ERROR_NOATTR); s = apreq_header_attribute(hdr, "boundary", 8, &val, &vlen); AT_int_eq(s, APR_SUCCESS); AT_int_eq(vlen, 5); AT_mem_eq(val, "-foo-", 5); s = apreq_header_attribute(hdr, "charset", 7, &val, &vlen); AT_int_eq(s, APR_SUCCESS); AT_int_eq(vlen, 10); AT_mem_eq(val, "ISO-8859-1", 10); hdr = "max-age=20; no-quote=\"..."; s = apreq_header_attribute(hdr, "max-age", 7, &val, &vlen); AT_int_eq(s, APR_SUCCESS); AT_int_eq(vlen, 2); AT_mem_eq(val, "20", 2); s = apreq_header_attribute(hdr, "age", 3, &val, &vlen); AT_int_eq(s, APREQ_ERROR_BADSEQ); s = apreq_header_attribute(hdr, "no-quote", 8, &val, &vlen); AT_int_eq(s, APREQ_ERROR_BADSEQ); } static void make_param(dAT) { apreq_param_t *param, *decode; apr_status_t s; apr_size_t nlen = 3, vlen = 11; char *name = apr_palloc(p,nlen+1); char *val = apr_palloc(p,vlen+1); char *encode; strcpy(name, "foo"); strcpy(val, "bar > alpha"); param = apreq_param_make(p, name, nlen, val, vlen); AT_str_eq(param->v.name, name); AT_int_eq(param->v.dlen, vlen); AT_str_eq(param->v.data, val); encode = apreq_param_encode(p, param); AT_str_eq(encode, "foo=bar+%3E+alpha"); s = apreq_param_decode(&decode, p, encode, nlen, vlen+2); AT_int_eq(s, APR_SUCCESS); AT_str_eq(decode->v.name, name); AT_int_eq(decode->v.dlen, vlen); AT_str_eq(decode->v.data, val); } static void quote_strings(dAT) { apr_size_t exp_len, res_len, res_quote_len; char *res = apr_palloc(p,24); char *res_quote = apr_palloc(p,24); const char *expr; int i; const char * arr[] = {"cest", "\"cest", "ce\"st", "\"cest\""}; const char * arr_quote[] = {"\"cest\"", "\"\\\"cest\"", "\"ce\\\"st\"", "\"\\\"cest\\\"\""}; apr_size_t arr_len[] = {4, 5, 5, 6}; apr_size_t arr_quote_len[] = {6, 8, 8, 10}; for (i=0; i<4; i++) { res_len = apreq_quote(res, arr[i], arr_len[i]); AT_int_eq(res_len, arr_quote_len[i]); AT_mem_eq(res, arr_quote[i], res_len); res_quote_len = apreq_quote_once(res_quote, res, res_len); AT_int_eq(res_quote_len, res_len); AT_mem_eq(res_quote, res, res_len); res_len = apreq_quote_once(res, arr[i], arr_len[i]); exp_len = (i == 3) ? arr_len[i] : arr_quote_len[i]; expr = (i == 3) ? arr[i] : arr_quote[i]; AT_int_eq(res_len, exp_len); AT_mem_eq(res, expr, exp_len); } } #define dT(func, plan) {#func, func, plan} int main(int argc, char *argv[]) { unsigned i, plan = 0; dAT; at_test_t test_list [] = { dT(request_make, 3), dT(request_args_get, 8), dT(params_as, 3), dT(string_decoding_in_place, 8), dT(header_attributes, 13), dT(make_param, 8), dT(quote_strings, 24), }; apr_initialize(); atexit(apr_terminate); apr_pool_create(&p, NULL); apreq_initialize(p); AT = at_create(p, 0, at_report_stdout_make(p)); AT_trace_on(); for (i = 0; i < sizeof(test_list) / sizeof(at_test_t); ++i) plan += test_list[i].plan; AT_begin(plan); for (i = 0; i < sizeof(test_list) / sizeof(at_test_t); ++i) AT_run(&test_list[i]); AT_end(); return 0; } rapache-1.2.8/libapreq2/library/t/params.t0000644000175100017510000000002712706745114017721 0ustar ondrejondrej#!perl exec './params' rapache-1.2.8/libapreq2/library/t/parsers0000755000175100017510000001174512706745114017667 0ustar ondrejondrej#! /bin/sh # parsers - temporary wrapper script for .libs/parsers # Generated by ltmain.sh - GNU libtool 1.5.6 (1.1220.2.95 2004/04/11 05:50:42) Debian: 224 $ # # The parsers 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='/bin/sed -e 1s/^X//' sed_quote_subst='s/\([\\`\\"$\\\\]\)/\\\1/g' # The HP-UX ksh and POSIX shell print the target directory to stdout # if CDPATH is set. if test "${CDPATH+set}" = set; then CDPATH=:; export CDPATH; fi relink_command="(cd /home/joe/src/apache/httpd/apreq/trunk/library/t; { test -z \"\${LIBRARY_PATH+set}\" || unset LIBRARY_PATH || { LIBRARY_PATH=; export LIBRARY_PATH; }; }; { test -z \"\${COMPILER_PATH+set}\" || unset COMPILER_PATH || { COMPILER_PATH=; export COMPILER_PATH; }; }; { test -z \"\${GCC_EXEC_PREFIX+set}\" || unset GCC_EXEC_PREFIX || { GCC_EXEC_PREFIX=; export GCC_EXEC_PREFIX; }; }; { test -z \"\${LD_RUN_PATH+set}\" || unset LD_RUN_PATH || { LD_RUN_PATH=; export LD_RUN_PATH; }; }; PATH=\"/usr/local/bin:/usr/bin:/bin:/usr/X11R6/bin:/usr/games\"; export PATH; gcc -g -O2 -Werror -Wall -Wmissing-prototypes -Wstrict-prototypes -Wmissing-declarations -Wwrite-strings -Wcast-qual -Wfloat-equal -Wshadow -Wpointer-arith -Wbad-function-cast -Wsign-compare -Waggregate-return -Wmissing-noreturn -Wmissing-format-attribute -Wpacked -Wredundant-decls -Wnested-externs -Wdisabled-optimization -Wno-long-long -Wendif-labels -Wcast-align -o \$progdir/\$file parsers.o /home/joe/src/apache/httpd/apreq/trunk/library/.libs/libapreq2.so /usr/lib/libgdbm.so /usr/lib/libdb-4.2.so /usr/lib/libexpat.so -lrt -lcrypt -lpthread -ldl /home/joe/httpd/trunk/worker/lib/libapr-1.so /home/joe/httpd/trunk/worker/lib/libaprutil-1.so libapache_test.a -Wl,--rpath -Wl,/home/joe/src/apache/httpd/apreq/trunk/library/.libs -Wl,--rpath -Wl,/home/joe/httpd/trunk/worker/lib -Wl,--rpath -Wl,/home/joe/httpd/trunk/worker/lib)" # This environment variable determines our operation mode. if test "$libtool_install_magic" = "%%%MAGIC variable%%%"; then # install mode needs the following variable: notinst_deplibs=' /home/joe/src/apache/httpd/apreq/trunk/library/libapreq2.la' else # When we are sourced in execute mode, $file and $echo are already set. if test "$libtool_execute_magic" != "%%%MAGIC variable%%%"; then echo="echo" 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 /bin/sh "$0" --no-reexec ${1+"$@"} fi fi # Find the directory that this script lives in. thisdir=`$echo "X$file" | $Xsed -e 's%/[^/]*$%%'` test "x$thisdir" = "x$file" && thisdir=. # Follow symbolic links until we get to the real thisdir. file=`ls -ld "$file" | /bin/sed -n 's/.*-> //p'` while test -n "$file"; do destdir=`$echo "X$file" | $Xsed -e 's%/[^/]*$%%'` # 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 file=`$echo "X$file" | $Xsed -e 's%^.*/%%'` file=`ls -ld "$thisdir/$file" | /bin/sed -n 's/.*-> //p'` done # Try to get the absolute directory name. absdir=`cd "$thisdir" && pwd` test -n "$absdir" && thisdir="$absdir" program=lt-'parsers' progdir="$thisdir/.libs" if test ! -f "$progdir/$program" || \ { file=`ls -1dt "$progdir/$program" "$progdir/../$program" 2>/dev/null | /bin/sed 1q`; \ test "X$file" != "X$progdir/$program"; }; then file="$$-$program" if test ! -d "$progdir"; then mkdir "$progdir" else rm -f "$progdir/$file" 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 -f "$progdir/$file" exit 1 fi fi mv -f "$progdir/$file" "$progdir/$program" 2>/dev/null || { rm -f "$progdir/$program"; mv -f "$progdir/$file" "$progdir/$program"; } rm -f "$progdir/$file" fi if test -f "$progdir/$program"; then if test "$libtool_execute_magic" != "%%%MAGIC variable%%%"; then # Run the actual program with our arguments. exec $progdir/$program ${1+"$@"} $echo "$0: cannot exec $program ${1+"$@"}" exit 1 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 libtool documentation for more information." 1>&2 exit 1 fi fi rapache-1.2.8/libapreq2/library/t/parsers.c0000644000175100017510000004163212706745114020103 0ustar ondrejondrej/* ** Copyright 2003-2005 The Apache Software Foundation ** ** Licensed under the Apache License, Version 2.0 (the "License"); ** you may not use this file except in compliance with the License. ** You may obtain a copy of the License at ** ** http://www.apache.org/licenses/LICENSE-2.0 ** ** Unless required by applicable law or agreed to in writing, software ** distributed under the License is distributed on an "AS IS" BASIS, ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ** See the License for the specific language governing permissions and ** limitations under the License. */ #include "apreq_parser.h" #include "apreq_error.h" #include "apr_strings.h" #include "apr_xml.h" #include "at.h" #define CRLF "\015\012" static apr_pool_t *p; static char url_data[] = "alpha=one&beta=two;omega=last%2"; static char form_data[] = "--AaB03x" CRLF /* 10 chars 012345678901234567890123456789012345678901234567890123456789 */ "content-disposition: form-data; name=\"field1\"" CRLF /* 47 chars */ "content-type: text/plain;charset=windows-1250" CRLF "content-transfer-encoding: quoted-printable" CRLF CRLF "Joe owes =80100." CRLF "--AaB03x" CRLF "content-disposition: form-data; name=\"pics\"; filename=\"file1.txt\"" CRLF "Content-Type: text/plain" CRLF CRLF "... contents of file1.txt ..." CRLF CRLF "--AaB03x" CRLF "content-disposition: form-data; name=\"\"" CRLF "content-type: text/plain;charset=windows-1250" CRLF "content-transfer-encoding: quoted-printable" CRLF CRLF "Joe owes =80100." CRLF "--AaB03x--" CRLF; static char xml_data[] = "" "" " foo.bar" " " " 1" " " ""; static char rel_data[] = /*offsets: 122, 522, */ "--f93dcbA3" CRLF "Content-Type: application/xml; charset=UTF-8" CRLF "Content-Length: 400" CRLF "Content-ID: <980119.X53GGT@example.com>" CRLF CRLF /*122*/ "" CRLF "" " My Proposal" " E. X. Ample" " A proposal for a new project." " (see handwritten region)" " project proposal funding" " false" " image.png" " cid:980119.X25MNC@example.com" "" /*400*/ CRLF "--f93dcbA3" CRLF /*14*/ "Content-Type: image/png" CRLF "Content-Transfer-Encoding: binary" CRLF "Content-ID: <980119.X25MNC@example.com>" CRLF CRLF /*103*/ "...Binary data here..." /*22*/ CRLF "--f93dcbA3" CRLF /*14*/ "Content-Type: image/png" CRLF "Content-Transfer-Encoding: binary" CRLF "Content-ID: <980119.X17AXM@example.com>" CRLF CRLF "...Binary data here..." CRLF "--f93dcbA3--" CRLF; static char mix_data[] = "--AaB03x" CRLF "Content-Disposition: form-data; name=\"submit-name\"" CRLF CRLF "Larry" CRLF "--AaB03x" CRLF "Content-Disposition: form-data; name=\"files\"" CRLF "Content-Type: multipart/mixed; boundary=BbC04y" CRLF CRLF "--BbC04y" CRLF "Content-Disposition: file; filename=\"file1.txt\"" CRLF "Content-Type: text/plain" CRLF CRLF "... contents of file1.txt ..." CRLF "--BbC04y" CRLF "Content-Disposition: file; filename=\"file2.gif\"" CRLF "Content-Type: image/gif" CRLF "Content-Transfer-Encoding: binary" CRLF CRLF "...contents of file2.gif..." CRLF "--BbC04y--" CRLF "--AaB03x" CRLF "content-disposition: form-data; name=\"field1\"" CRLF "content-type: text/plain;charset=windows-1250" CRLF "content-transfer-encoding: quoted-printable" CRLF CRLF "Joe owes =80100." CRLF "--AaB03x--" CRLF; #define URL_ENCTYPE "application/x-www-form-urlencoded" #define MFD_ENCTYPE "multipart/form-data" #define MR_ENCTYPE "multipart/related" #define XML_ENCTYPE "application/xml" static void locate_default_parsers(dAT) { #ifdef __ELF__ apreq_parser_function_t f; AT_trace_on(); f = apreq_parser(URL_ENCTYPE); AT_EQ(f, (apreq_parser_function_t)apreq_parse_urlencoded, "%pp"); f = apreq_parser(MFD_ENCTYPE); AT_EQ(f, (apreq_parser_function_t)apreq_parse_multipart, "%pp"); f = apreq_parser(MR_ENCTYPE); AT_EQ(f, (apreq_parser_function_t)apreq_parse_multipart, "%pp"); AT_trace_off(); #else AT_skip(3, "skipping ELF-dependent tests"); #endif } static void parse_urlencoded(dAT) { apr_status_t rv; apr_bucket_alloc_t *ba; apr_bucket_brigade *bb; apreq_parser_t *parser; apr_table_t *body; body = apr_table_make(p, APREQ_DEFAULT_NELTS); ba = apr_bucket_alloc_create(p); bb = apr_brigade_create(p, ba); parser = apreq_parser_make(p, ba, URL_ENCTYPE, apreq_parse_urlencoded, 100, NULL, NULL, NULL); APR_BRIGADE_INSERT_HEAD(bb, apr_bucket_immortal_create(url_data,strlen(url_data), bb->bucket_alloc)); rv = apreq_parser_run(parser, body, bb); AT_int_eq(rv, APR_INCOMPLETE); APR_BRIGADE_INSERT_HEAD(bb, apr_bucket_immortal_create("blast",5, bb->bucket_alloc)); APR_BRIGADE_INSERT_TAIL(bb, apr_bucket_eos_create(bb->bucket_alloc)); rv = apreq_parser_run(parser, body, bb); AT_int_eq(rv, APR_SUCCESS); AT_str_eq(apr_table_get(body,"alpha"), "one"); AT_str_eq(apr_table_get(body,"beta"), "two"); AT_str_eq(apr_table_get(body,"omega"),"last+last"); } static void parse_multipart(dAT) { apr_size_t i, j; apr_bucket_alloc_t *ba; for (j = 0; j <= strlen(form_data); ++j) { ba = apr_bucket_alloc_create(p); /* AT_localize checks the inner loop tests itself * (and interprets any such failures as being fatal), * because doing IO to Test::Harness is just too slow * when this many (~1M) tests are involved. */ AT_localize(p); for (i = 0; i <= strlen(form_data); ++i) { const char *val; char *val2; apr_size_t len; apr_table_t *t, *body; apreq_parser_t *parser; apr_bucket_brigade *bb, *vb, *tail; apr_status_t rv; apr_bucket *e, *f; bb = apr_brigade_create(p, ba); body = apr_table_make(p, APREQ_DEFAULT_NELTS); parser = apreq_parser_make(p, ba, MFD_ENCTYPE "; charset=\"iso-8859-1\"" "; boundary=\"AaB03x\"", apreq_parse_multipart, 1000, NULL, NULL, NULL); e = apr_bucket_immortal_create(form_data, strlen(form_data), bb->bucket_alloc); APR_BRIGADE_INSERT_HEAD(bb, e); APR_BRIGADE_INSERT_TAIL(bb, apr_bucket_eos_create(bb->bucket_alloc)); /* Split e into three buckets */ apr_bucket_split(e, j); f = APR_BUCKET_NEXT(e); if (i < j) apr_bucket_split(e, i); else apr_bucket_split(f, i - j); tail = apr_brigade_split(bb, f); rv = apreq_parser_run(parser, body, bb); AT_int_eq(rv, (j < strlen(form_data)) ? APR_INCOMPLETE : APR_SUCCESS); rv = apreq_parser_run(parser, body, tail); AT_int_eq(rv, APR_SUCCESS); AT_int_eq(apr_table_elts(body)->nelts, 3); val = apr_table_get(body,"field1"); AT_str_eq(val, "Joe owes =80100."); t = apreq_value_to_param(val)->info; val = apr_table_get(t, "content-transfer-encoding"); AT_str_eq(val, "quoted-printable"); val = apr_table_get(body, "pics"); AT_str_eq(val, "file1.txt"); t = apreq_value_to_param(val)->info; vb = apreq_value_to_param(val)->upload; apr_brigade_pflatten(vb, &val2, &len, p); AT_int_eq(len, strlen("... contents of file1.txt ..." CRLF)); AT_mem_eq(val2 ,"... contents of file1.txt ..." CRLF, len); val = apr_table_get(t, "content-type"); AT_str_eq(val, "text/plain"); apr_brigade_cleanup(vb); apr_brigade_cleanup(bb); } #ifdef APR_POOL_DEBUG apr_bucket_alloc_destroy(ba); #endif apr_pool_clear(p); } } static void parse_disable_uploads(dAT) { const char *val; apr_table_t *t, *body; apr_status_t rv; apr_bucket_alloc_t *ba; apr_bucket_brigade *bb; apr_bucket *e; apreq_parser_t *parser; apreq_hook_t *hook; ba = apr_bucket_alloc_create(p); bb = apr_brigade_create(p, ba); e = apr_bucket_immortal_create(form_data, strlen(form_data), ba); APR_BRIGADE_INSERT_HEAD(bb, e); APR_BRIGADE_INSERT_TAIL(bb, apr_bucket_eos_create(bb->bucket_alloc)); body = apr_table_make(p, APREQ_DEFAULT_NELTS); hook = apreq_hook_make(p, apreq_hook_disable_uploads, NULL, NULL); parser = apreq_parser_make(p, ba, MFD_ENCTYPE "; charset=\"iso-8859-1\"" "; boundary=\"AaB03x\"", apreq_parse_multipart, 1000, NULL, hook, NULL); rv = apreq_parser_run(parser, body, bb); AT_int_eq(rv, APREQ_ERROR_GENERAL); AT_int_eq(apr_table_elts(body)->nelts, 1); val = apr_table_get(body,"field1"); AT_str_eq(val, "Joe owes =80100."); t = apreq_value_to_param(val)->info; val = apr_table_get(t, "content-transfer-encoding"); AT_str_eq(val, "quoted-printable"); val = apr_table_get(body, "pics"); AT_is_null(val); } static void parse_generic(dAT) { char *val; apr_size_t vlen; apr_status_t rv; apreq_param_t *dummy; apreq_parser_t *parser; apr_table_t *body; apr_bucket_alloc_t *ba = apr_bucket_alloc_create(p); apr_bucket_brigade *bb = apr_brigade_create(p, ba); apr_bucket *e = apr_bucket_immortal_create(xml_data, strlen(xml_data), ba); APR_BRIGADE_INSERT_HEAD(bb, e); APR_BRIGADE_INSERT_TAIL(bb, apr_bucket_eos_create(ba)); body = apr_table_make(p, APREQ_DEFAULT_NELTS); parser = apreq_parser_make(p, ba, "application/xml", apreq_parse_generic, 1000, NULL, NULL, NULL); rv = apreq_parser_run(parser, body, bb); AT_int_eq(rv, APR_SUCCESS); dummy = *(apreq_param_t **)parser->ctx; AT_not_null(dummy); apr_brigade_pflatten(dummy->upload, &val, &vlen, p); AT_int_eq(vlen, strlen(xml_data)); AT_mem_eq(val, xml_data, vlen); } static void hook_discard(dAT) { apr_status_t rv; apreq_param_t *dummy; apreq_parser_t *parser; apreq_hook_t *hook; apr_table_t *body; apr_bucket_alloc_t *ba = apr_bucket_alloc_create(p); apr_bucket_brigade *bb = apr_brigade_create(p, ba); apr_bucket *e = apr_bucket_immortal_create(xml_data, strlen(xml_data), ba); APR_BRIGADE_INSERT_HEAD(bb, e); APR_BRIGADE_INSERT_TAIL(bb, apr_bucket_eos_create(ba)); body = apr_table_make(p, APREQ_DEFAULT_NELTS); hook = apreq_hook_make(p, apreq_hook_discard_brigade, NULL, NULL); parser = apreq_parser_make(p, ba, "application/xml", apreq_parse_generic, 1000, NULL, hook, NULL); rv = apreq_parser_run(parser, body, bb); AT_int_eq(rv, APR_SUCCESS); dummy = *(apreq_param_t **)parser->ctx; AT_not_null(dummy); AT_not_null(dummy->upload); AT_ok(APR_BRIGADE_EMPTY(dummy->upload), "brigade has no contents"); } static void parse_related(dAT) { char ct[] = "multipart/related; boundary=f93dcbA3; " "type=application/xml; start=\"<980119.X53GGT@example.com>\""; char data[] = "...Binary data here..."; int dlen = strlen(data); const char *val; char *val2; apr_size_t vlen; apr_status_t rv; int ns_map = 0; apr_xml_doc *doc; apr_table_t *body; apreq_parser_t *parser; apreq_hook_t *xml_hook; apreq_param_t *param; apr_bucket_alloc_t *ba = apr_bucket_alloc_create(p); apr_bucket_brigade *bb = apr_brigade_create(p, ba); apr_bucket *e = apr_bucket_immortal_create(rel_data, strlen(rel_data), bb->bucket_alloc); APR_BRIGADE_INSERT_HEAD(bb, e); APR_BRIGADE_INSERT_TAIL(bb, apr_bucket_eos_create(bb->bucket_alloc)); xml_hook = apreq_hook_make(p, apreq_hook_apr_xml_parser, NULL, NULL); body = apr_table_make(p, APREQ_DEFAULT_NELTS); parser = apreq_parser_make(p, ba, ct, apreq_parse_multipart, 1000, NULL, xml_hook, NULL); rv = apreq_parser_run(parser, body, bb); AT_int_eq(rv, APR_SUCCESS); val = apr_table_get(body, "<980119.X53GGT@example.com>"); AT_not_null(val); param = apreq_value_to_param(val); AT_not_null(param); AT_not_null(param->info); val = apr_table_get(param->info, "Content-Length"); AT_str_eq(val, "400"); AT_not_null(param->upload); apr_brigade_pflatten(param->upload, &val2, &vlen, p); AT_int_eq(vlen, 400); AT_mem_eq(val2, rel_data + 122, 400); doc = *(apr_xml_doc **)xml_hook->ctx; apr_xml_to_text(p, doc->root, APR_XML_X2T_FULL, doc->namespaces, &ns_map, &val, &vlen); AT_int_eq(vlen, 400 - 22); AT_mem_eq(val, rel_data + 122 + 23, 400 - 23); val = apr_table_get(body, "<980119.X25MNC@example.com>"); AT_not_null(val); param = apreq_value_to_param(val); AT_not_null(param); AT_not_null(param->upload); apr_brigade_pflatten(param->upload, &val2, &vlen, p); AT_int_eq(vlen, dlen); AT_mem_eq(val2, data, vlen); val = apr_table_get(body, "<980119.X17AXM@example.com>"); AT_not_null(val); param = apreq_value_to_param(val); AT_not_null(param); AT_not_null(param->upload); apr_brigade_pflatten(param->upload, &val2, &vlen, p); AT_int_eq(vlen, dlen); AT_mem_eq(val2, data, vlen); } typedef struct { const char *key; const char *val; } array_elt; static void parse_mixed(dAT) { const char *val; char *val2; apr_size_t vlen; apr_status_t rv; apreq_param_t *param; const apr_array_header_t *arr; array_elt *elt; char ct[] = MFD_ENCTYPE "; charset=\"iso-8859-1\"; boundary=\"AaB03x\""; apreq_parser_t *parser; apr_table_t *body = apr_table_make(p, APREQ_DEFAULT_NELTS); apr_bucket_alloc_t *ba = apr_bucket_alloc_create(p); apr_bucket_brigade *bb = apr_brigade_create(p, ba); apr_bucket *e = apr_bucket_immortal_create(mix_data, strlen(mix_data), bb->bucket_alloc); APR_BRIGADE_INSERT_HEAD(bb, e); APR_BRIGADE_INSERT_TAIL(bb, apr_bucket_eos_create(bb->bucket_alloc)); parser = apreq_parser_make(p, ba, ct, apreq_parse_multipart, 1000, NULL, NULL, NULL); rv = apreq_parser_run(parser, body, bb); AT_int_eq(rv, APR_SUCCESS); val = apr_table_get(body, "submit-name"); AT_not_null(val); AT_str_eq(val, "Larry"); val = apr_table_get(body,"field1"); AT_str_eq(val, "Joe owes =80100."); val = apr_table_get(body, "files"); AT_not_null(val); AT_str_eq(val, "file1.txt"); param = apreq_value_to_param(val); AT_not_null(param->upload); apr_brigade_pflatten(param->upload, &val2, &vlen, p); AT_int_eq(vlen, strlen("... contents of file1.txt ...")); AT_mem_eq(val2, "... contents of file1.txt ...", vlen); arr = apr_table_elts(body); AT_int_eq(arr->nelts, 4); elt = (array_elt *)&arr->elts[2 * arr->elt_size]; AT_str_eq(elt->key, "files"); AT_str_eq(elt->val, "file2.gif"); param = apreq_value_to_param(elt->val); AT_not_null(param->upload); apr_brigade_pflatten(param->upload, &val2, &vlen, p); AT_int_eq(vlen, strlen("...contents of file2.gif...")); AT_mem_eq(val2, "...contents of file2.gif...", vlen); } #define dT(func, plan) {#func, func, plan} int main(int argc, char *argv[]) { apr_pool_t *test_pool; unsigned i, plan = 0; dAT; at_test_t test_list [] = { dT(locate_default_parsers, 3), dT(parse_urlencoded, 5), dT(parse_multipart, sizeof form_data), dT(parse_disable_uploads, 5), dT(parse_generic, 4), dT(hook_discard, 4), dT(parse_related, 20), dT(parse_mixed, 15) }; apr_initialize(); atexit(apr_terminate); apr_pool_create(&p, NULL); apr_pool_create(&test_pool, NULL); apreq_initialize(p); AT = at_create(test_pool, 0, at_report_stdout_make(test_pool)); for (i = 0; i < sizeof(test_list) / sizeof(at_test_t); ++i) plan += test_list[i].plan; AT_begin(plan); for (i = 0; i < sizeof(test_list) / sizeof(at_test_t); ++i) AT_run(&test_list[i]); AT_end(); return 0; } rapache-1.2.8/libapreq2/library/t/parsers.t0000644000175100017510000000003012706745114020107 0ustar ondrejondrej#!perl exec './parsers' rapache-1.2.8/libapreq2/library/t/util0000755000175100017510000001172612706745114017164 0ustar ondrejondrej#! /bin/sh # util - temporary wrapper script for .libs/util # Generated by ltmain.sh - GNU libtool 1.5.6 (1.1220.2.95 2004/04/11 05:50:42) Debian: 224 $ # # The util 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='/bin/sed -e 1s/^X//' sed_quote_subst='s/\([\\`\\"$\\\\]\)/\\\1/g' # The HP-UX ksh and POSIX shell print the target directory to stdout # if CDPATH is set. if test "${CDPATH+set}" = set; then CDPATH=:; export CDPATH; fi relink_command="(cd /home/joe/src/apache/httpd/apreq/trunk/library/t; { test -z \"\${LIBRARY_PATH+set}\" || unset LIBRARY_PATH || { LIBRARY_PATH=; export LIBRARY_PATH; }; }; { test -z \"\${COMPILER_PATH+set}\" || unset COMPILER_PATH || { COMPILER_PATH=; export COMPILER_PATH; }; }; { test -z \"\${GCC_EXEC_PREFIX+set}\" || unset GCC_EXEC_PREFIX || { GCC_EXEC_PREFIX=; export GCC_EXEC_PREFIX; }; }; { test -z \"\${LD_RUN_PATH+set}\" || unset LD_RUN_PATH || { LD_RUN_PATH=; export LD_RUN_PATH; }; }; PATH=\"/usr/local/bin:/usr/bin:/bin:/usr/X11R6/bin:/usr/games\"; export PATH; gcc -g -O2 -Werror -Wall -Wmissing-prototypes -Wstrict-prototypes -Wmissing-declarations -Wwrite-strings -Wcast-qual -Wfloat-equal -Wshadow -Wpointer-arith -Wbad-function-cast -Wsign-compare -Waggregate-return -Wmissing-noreturn -Wmissing-format-attribute -Wpacked -Wredundant-decls -Wnested-externs -Wdisabled-optimization -Wno-long-long -Wendif-labels -Wcast-align -o \$progdir/\$file util.o /home/joe/src/apache/httpd/apreq/trunk/library/.libs/libapreq2.so /usr/lib/libgdbm.so /usr/lib/libdb-4.2.so /usr/lib/libexpat.so -lrt -lcrypt -lpthread -ldl /home/joe/httpd/trunk/worker/lib/libapr-1.so /home/joe/httpd/trunk/worker/lib/libaprutil-1.so libapache_test.a -Wl,--rpath -Wl,/home/joe/src/apache/httpd/apreq/trunk/library/.libs -Wl,--rpath -Wl,/home/joe/httpd/trunk/worker/lib -Wl,--rpath -Wl,/home/joe/httpd/trunk/worker/lib)" # This environment variable determines our operation mode. if test "$libtool_install_magic" = "%%%MAGIC variable%%%"; then # install mode needs the following variable: notinst_deplibs=' /home/joe/src/apache/httpd/apreq/trunk/library/libapreq2.la' else # When we are sourced in execute mode, $file and $echo are already set. if test "$libtool_execute_magic" != "%%%MAGIC variable%%%"; then echo="echo" 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 /bin/sh "$0" --no-reexec ${1+"$@"} fi fi # Find the directory that this script lives in. thisdir=`$echo "X$file" | $Xsed -e 's%/[^/]*$%%'` test "x$thisdir" = "x$file" && thisdir=. # Follow symbolic links until we get to the real thisdir. file=`ls -ld "$file" | /bin/sed -n 's/.*-> //p'` while test -n "$file"; do destdir=`$echo "X$file" | $Xsed -e 's%/[^/]*$%%'` # 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 file=`$echo "X$file" | $Xsed -e 's%^.*/%%'` file=`ls -ld "$thisdir/$file" | /bin/sed -n 's/.*-> //p'` done # Try to get the absolute directory name. absdir=`cd "$thisdir" && pwd` test -n "$absdir" && thisdir="$absdir" program=lt-'util' progdir="$thisdir/.libs" if test ! -f "$progdir/$program" || \ { file=`ls -1dt "$progdir/$program" "$progdir/../$program" 2>/dev/null | /bin/sed 1q`; \ test "X$file" != "X$progdir/$program"; }; then file="$$-$program" if test ! -d "$progdir"; then mkdir "$progdir" else rm -f "$progdir/$file" 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 -f "$progdir/$file" exit 1 fi fi mv -f "$progdir/$file" "$progdir/$program" 2>/dev/null || { rm -f "$progdir/$program"; mv -f "$progdir/$file" "$progdir/$program"; } rm -f "$progdir/$file" fi if test -f "$progdir/$program"; then if test "$libtool_execute_magic" != "%%%MAGIC variable%%%"; then # Run the actual program with our arguments. exec $progdir/$program ${1+"$@"} $echo "$0: cannot exec $program ${1+"$@"}" exit 1 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 libtool documentation for more information." 1>&2 exit 1 fi fi rapache-1.2.8/libapreq2/library/t/util.c0000644000175100017510000001722012706745114017375 0ustar ondrejondrej/* ** Copyright 2004-2005 The Apache Software Foundation ** ** Licensed under the Apache License, Version 2.0 (the "License"); ** you may not use this file except in compliance with the License. ** You may obtain a copy of the License at ** ** http://www.apache.org/licenses/LICENSE-2.0 ** ** Unless required by applicable law or agreed to in writing, software ** distributed under the License is distributed on an "AS IS" BASIS, ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ** See the License for the specific language governing permissions and ** limitations under the License. */ #include "apr_strings.h" #include "apreq_error.h" #include "apreq_util.h" #include "at.h" static void test_atoi64f(dAT) { AT_int_eq(apreq_atoi64f("0"), 0); AT_int_eq(apreq_atoi64f("-1"), -1); AT_int_eq(apreq_atoi64f("-"), 0); AT_int_eq(apreq_atoi64f("5"), 5); AT_int_eq(apreq_atoi64f("3.333"), 3); AT_int_eq(apreq_atoi64f("33k"), 33 * 1024); AT_int_eq(apreq_atoi64f(" +8M "), 8 * 1024 * 1024); AT_ok(apreq_atoi64f("44GB") == (apr_int64_t)44 * 1024 * 1024 * 1024, "44GB test"); AT_ok(apreq_atoi64f("0xaBcDefg") == (apr_int64_t)11259375 * 1024 * 1024 * 1024, "hex test"); } static void test_atoi64t(dAT) { AT_int_eq(apreq_atoi64t("0"), 0); AT_int_eq(apreq_atoi64t("-1"), -1); AT_int_eq(apreq_atoi64t("-g088l3dyg00k"), 0); AT_int_eq(apreq_atoi64t("5s"), 5); AT_int_eq(apreq_atoi64t("3.333"), 3); AT_int_eq(apreq_atoi64t("33d"), 33 * 60 * 60 * 24); AT_int_eq(apreq_atoi64t(" +8M "), 8 * 60 * 60 * 24 * 30); AT_int_eq(apreq_atoi64t("+9m"), 9 * 60); AT_int_eq(apreq_atoi64t("6h"), 6 * 60 * 60); } static void test_index(dAT) { const char haystack[] = "Four score and seven years ago"; apr_size_t hlen = sizeof haystack - 1; AT_int_eq(apreq_index(haystack, hlen, "Four", 4, APREQ_MATCH_FULL), 0); AT_int_eq(apreq_index(haystack, hlen, "Four", 4, APREQ_MATCH_PARTIAL), 0); AT_int_eq(apreq_index(haystack, hlen, "Fourteen", 8, APREQ_MATCH_FULL), -1); AT_int_eq(apreq_index(haystack, hlen, "Fourteen", 8, APREQ_MATCH_PARTIAL), -1); AT_int_eq(apreq_index(haystack, hlen, "agoraphobia", 11, APREQ_MATCH_FULL), -1); AT_int_eq(apreq_index(haystack, hlen, "agoraphobia", 11, APREQ_MATCH_PARTIAL), hlen - 3); } #define A_GRAVE 0xE5 #define KATAKANA_A 0xFF71 static void test_decode(dAT) { apr_size_t elen; char src1[] = "%C3%80%E3%82%a2"; /* A_GRAVE KATAKANA_A as utf8 */ unsigned char expect[6]; AT_int_eq(apreq_decode((char *)expect, &elen, src1, sizeof(src1) -1), APR_SUCCESS + APREQ_CHARSET_UTF8); AT_int_eq(elen, 5); AT_int_eq(expect[0], 0xC3); AT_int_eq(expect[1], 0x80); AT_int_eq(expect[2], 0xE3); AT_int_eq(expect[3], 0x82); AT_int_eq(expect[4], 0xA2); } static void test_decodev(dAT) { char src1[] = "%2540%2"; char src2[] = "0%u0"; char src3[] = "041"; struct iovec iovec1[] = { { src1, sizeof(src1) - 1 }, { src2, sizeof(src2) - 1 }, { src3, sizeof(src3) - 1 }, }; struct iovec iovec2[] = { { src1, sizeof(src1) - 1 }, { src2, sizeof(src2) - 1 }, }; const char expect1[] = "%40 A"; const char expect2[] = "%40 "; char dest[sizeof(src1) + sizeof(src2) + sizeof(src3)]; apr_size_t dest_len; apr_status_t status; status = apreq_decodev(dest, &dest_len, iovec1, 3); AT_int_eq(status, APR_SUCCESS + APREQ_CHARSET_UTF8); AT_int_eq(dest_len, sizeof(expect1) - 1); AT_mem_eq(dest, expect1, sizeof(expect1) - 1); status = apreq_decodev(dest, &dest_len, iovec2, 2); AT_int_eq(status, APR_INCOMPLETE); AT_int_eq(dest_len, sizeof(expect2) - 1); AT_mem_eq(dest, expect2, sizeof(expect2) - 1); } static void test_encode(dAT) { } static void test_cp1252_to_utf8(dAT) { char src1[] = "%C3%80%E3%82%a2"; /* A_GRAVE KATAKANA_A as utf8 */ char src2[5]; unsigned char expect[16]; apr_size_t slen; AT_int_eq(apreq_decode((char *)src2, &slen, src1, sizeof(src1) -1), APR_SUCCESS + APREQ_CHARSET_UTF8); AT_int_eq(apreq_cp1252_to_utf8((char *)expect, src2, 5), 12); /* 0xC3 */ AT_int_eq(expect[0], 0xC0 | (0xC3 >> 6)); AT_int_eq(expect[1], 0xC3 - 0x40); /* 0x20AC */ AT_int_eq(expect[2], 0xE0 | (0x20AC >> 12)); AT_int_eq(expect[3], 0x80 | ((0x20AC >> 6) & 0x3F)); AT_int_eq(expect[4], 0x80 | (0x20AC & 0x3F)); /* 0xE3 */ AT_int_eq(expect[5], 0xC3); AT_int_eq(expect[6], 0xE3 - 0x40); /* 0x201A */ AT_int_eq(expect[7], 0xE0 | (0x201A >> 12)); AT_int_eq(expect[8], 0x80 | ((0x201A >> 6) & 0x3F)); AT_int_eq(expect[9], 0x80 | (0x201A & 0x3F)); /* 0xA2 */ AT_int_eq(expect[10], 0xC0 | (0xA2 >> 6)); AT_int_eq(expect[11], 0xA2); } static void test_quote(dAT) { size_t len; char dst[64]; len = apreq_quote(dst, "foo", 3); AT_int_eq(len, 5); AT_str_eq(dst, "\"foo\""); len = apreq_quote(dst, "\"foo", 4); AT_int_eq(len, 7); AT_str_eq(dst, "\"\\\"foo\""); len = apreq_quote(dst, "foo\\bar", 7); AT_int_eq(len, 10); AT_str_eq(dst, "\"foo\\\\bar\""); len = apreq_quote(dst, "foo\0bar", 7); AT_int_eq(len, 10); AT_str_eq(dst, "\"foo\\0bar\""); } static void test_quote_once(dAT) { size_t len; char dst[64]; len = apreq_quote_once(dst, "foo", 3); AT_int_eq(len, 5); AT_str_eq(dst, "\"foo\""); len = apreq_quote_once(dst, "\"foo", 4); AT_int_eq(len, 7); AT_str_eq(dst, "\"\\\"foo\""); len = apreq_quote_once(dst, "foo\"", 4); AT_int_eq(len, 7); AT_str_eq(dst, "\"foo\\\"\""); len = apreq_quote_once(dst, "foo\0bar", 7); AT_int_eq(len, 10); AT_str_eq(dst, "\"foo\\0bar\""); /* null byte must be escaped, even when there are already double quotes */ len = apreq_quote_once(dst, "\"foo\0bar\"", 9); AT_int_eq(len, 14); AT_str_eq(dst, "\"\\\"foo\\0bar\\\"\""); len = apreq_quote_once(dst, "\"foo\"", 5); AT_int_eq(len, 5); AT_str_eq(dst, "\"foo\""); len = apreq_quote_once(dst, "'foo'", 5); AT_int_eq(len, 7); AT_str_eq(dst, "\"'foo'\""); len = apreq_quote_once(dst, "\"fo\\o\"", 6); AT_int_eq(len, 6); AT_str_eq(dst, "\"fo\\o\""); len = apreq_quote_once(dst, "\"foo\"bar\"", 9); AT_int_eq(len, 14); AT_str_eq(dst, "\"\\\"foo\\\"bar\\\"\""); } static void test_join(dAT) { } static void test_brigade_fwrite(dAT) { } static void test_file_mktemp(dAT) { } static void test_header_attribute(dAT) { } static void test_brigade_concat(dAT) { } #define dT(func, plan) #func, func, plan int main(int argc, char *argv[]) { unsigned i, plan = 0; apr_pool_t *p; dAT; at_test_t test_list [] = { { dT(test_atoi64f, 9) }, { dT(test_atoi64t, 9) }, { dT(test_index, 6) }, { dT(test_decode, 7) }, { dT(test_decodev, 6) }, { dT(test_encode, 0) }, { dT(test_cp1252_to_utf8, 14) }, { dT(test_quote, 8) }, { dT(test_quote_once, 18), }, { dT(test_join, 0) }, { dT(test_brigade_fwrite, 0) }, { dT(test_file_mktemp, 0) }, { dT(test_header_attribute, 0) }, { dT(test_brigade_concat, 0) }, }; apr_initialize(); atexit(apr_terminate); apr_pool_create(&p, NULL); AT = at_create(p, 0, at_report_stdout_make(p)); for (i = 0; i < sizeof(test_list) / sizeof(at_test_t); ++i) plan += test_list[i].plan; AT_begin(plan); for (i = 0; i < sizeof(test_list) / sizeof(at_test_t); ++i) AT_run(&test_list[i]); AT_end(); return 0; } rapache-1.2.8/libapreq2/library/t/util.t0000644000175100017510000000002512706745114017411 0ustar ondrejondrej#!perl exec './util' rapache-1.2.8/libapreq2/library/t/version0000755000175100017510000001174512706745114017675 0ustar ondrejondrej#! /bin/sh # version - temporary wrapper script for .libs/version # Generated by ltmain.sh - GNU libtool 1.5.6 (1.1220.2.95 2004/04/11 05:50:42) Debian: 224 $ # # The version 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='/bin/sed -e 1s/^X//' sed_quote_subst='s/\([\\`\\"$\\\\]\)/\\\1/g' # The HP-UX ksh and POSIX shell print the target directory to stdout # if CDPATH is set. if test "${CDPATH+set}" = set; then CDPATH=:; export CDPATH; fi relink_command="(cd /home/joe/src/apache/httpd/apreq/trunk/library/t; { test -z \"\${LIBRARY_PATH+set}\" || unset LIBRARY_PATH || { LIBRARY_PATH=; export LIBRARY_PATH; }; }; { test -z \"\${COMPILER_PATH+set}\" || unset COMPILER_PATH || { COMPILER_PATH=; export COMPILER_PATH; }; }; { test -z \"\${GCC_EXEC_PREFIX+set}\" || unset GCC_EXEC_PREFIX || { GCC_EXEC_PREFIX=; export GCC_EXEC_PREFIX; }; }; { test -z \"\${LD_RUN_PATH+set}\" || unset LD_RUN_PATH || { LD_RUN_PATH=; export LD_RUN_PATH; }; }; PATH=\"/usr/local/bin:/usr/bin:/bin:/usr/X11R6/bin:/usr/games\"; export PATH; gcc -g -O2 -Werror -Wall -Wmissing-prototypes -Wstrict-prototypes -Wmissing-declarations -Wwrite-strings -Wcast-qual -Wfloat-equal -Wshadow -Wpointer-arith -Wbad-function-cast -Wsign-compare -Waggregate-return -Wmissing-noreturn -Wmissing-format-attribute -Wpacked -Wredundant-decls -Wnested-externs -Wdisabled-optimization -Wno-long-long -Wendif-labels -Wcast-align -o \$progdir/\$file version.o /home/joe/src/apache/httpd/apreq/trunk/library/.libs/libapreq2.so /usr/lib/libgdbm.so /usr/lib/libdb-4.2.so /usr/lib/libexpat.so -lrt -lcrypt -lpthread -ldl /home/joe/httpd/trunk/worker/lib/libapr-1.so /home/joe/httpd/trunk/worker/lib/libaprutil-1.so libapache_test.a -Wl,--rpath -Wl,/home/joe/src/apache/httpd/apreq/trunk/library/.libs -Wl,--rpath -Wl,/home/joe/httpd/trunk/worker/lib -Wl,--rpath -Wl,/home/joe/httpd/trunk/worker/lib)" # This environment variable determines our operation mode. if test "$libtool_install_magic" = "%%%MAGIC variable%%%"; then # install mode needs the following variable: notinst_deplibs=' /home/joe/src/apache/httpd/apreq/trunk/library/libapreq2.la' else # When we are sourced in execute mode, $file and $echo are already set. if test "$libtool_execute_magic" != "%%%MAGIC variable%%%"; then echo="echo" 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 /bin/sh "$0" --no-reexec ${1+"$@"} fi fi # Find the directory that this script lives in. thisdir=`$echo "X$file" | $Xsed -e 's%/[^/]*$%%'` test "x$thisdir" = "x$file" && thisdir=. # Follow symbolic links until we get to the real thisdir. file=`ls -ld "$file" | /bin/sed -n 's/.*-> //p'` while test -n "$file"; do destdir=`$echo "X$file" | $Xsed -e 's%/[^/]*$%%'` # 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 file=`$echo "X$file" | $Xsed -e 's%^.*/%%'` file=`ls -ld "$thisdir/$file" | /bin/sed -n 's/.*-> //p'` done # Try to get the absolute directory name. absdir=`cd "$thisdir" && pwd` test -n "$absdir" && thisdir="$absdir" program=lt-'version' progdir="$thisdir/.libs" if test ! -f "$progdir/$program" || \ { file=`ls -1dt "$progdir/$program" "$progdir/../$program" 2>/dev/null | /bin/sed 1q`; \ test "X$file" != "X$progdir/$program"; }; then file="$$-$program" if test ! -d "$progdir"; then mkdir "$progdir" else rm -f "$progdir/$file" 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 -f "$progdir/$file" exit 1 fi fi mv -f "$progdir/$file" "$progdir/$program" 2>/dev/null || { rm -f "$progdir/$program"; mv -f "$progdir/$file" "$progdir/$program"; } rm -f "$progdir/$file" fi if test -f "$progdir/$program"; then if test "$libtool_execute_magic" != "%%%MAGIC variable%%%"; then # Run the actual program with our arguments. exec $progdir/$program ${1+"$@"} $echo "$0: cannot exec $program ${1+"$@"}" exit 1 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 libtool documentation for more information." 1>&2 exit 1 fi fi rapache-1.2.8/libapreq2/library/t/version.c0000644000175100017510000000332712706745114020110 0ustar ondrejondrej/* ** Copyright 2003-2005 The Apache Software Foundation ** ** Licensed under the Apache License, Version 2.0 (the "License"); ** you may not use this file except in compliance with the License. ** You may obtain a copy of the License at ** ** http://www.apache.org/licenses/LICENSE-2.0 ** ** Unless required by applicable law or agreed to in writing, software ** distributed under the License is distributed on an "AS IS" BASIS, ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ** See the License for the specific language governing permissions and ** limitations under the License. */ #include "apreq_version.h" #include "at.h" static void version_string(dAT) { const char *vstring = apreq_version_string(); AT_not_null(vstring); AT_str_eq(vstring, APREQ_VERSION_STRING); } static void version_type(dAT) { apr_version_t v; apreq_version(&v); AT_int_eq(v.major, APREQ_MAJOR_VERSION); AT_int_eq(v.minor, APREQ_MINOR_VERSION); AT_int_eq(v.patch, APREQ_PATCH_VERSION); #ifdef APREQ_IS_DEV_VERSION AT_int_eq(v.is_dev, 1); #else AT_int_eq(v.is_dev, 0); #endif } int main(int argc, char *argv[]) { apr_pool_t *p; unsigned i, plan = 0; dAT; at_test_t test_list [] = { {"version_string", version_string, 2, "1"}, {"version_type", version_type, 4} }; apr_initialize(); atexit(apr_terminate); apr_pool_create(&p, NULL); AT = at_create(p, 0, at_report_stdout_make(p)); for (i = 0; i < sizeof(test_list) / sizeof(at_test_t); ++i) plan += test_list[i].plan; AT_begin(plan); for (i = 0; i < sizeof(test_list) / sizeof(at_test_t); ++i) AT_run(&test_list[i]); AT_end(); return 0; } rapache-1.2.8/libapreq2/library/t/version.t0000644000175100017510000000003012706745114020115 0ustar ondrejondrej#!perl exec './version' rapache-1.2.8/libapreq2/library/util.c0000644000175100017510000010271512706745114017136 0ustar ondrejondrej/* ** Copyright 2003-2005 The Apache Software Foundation ** ** Licensed under the Apache License, Version 2.0 (the "License"); ** you may not use this file except in compliance with the License. ** You may obtain a copy of the License at ** ** http://www.apache.org/licenses/LICENSE-2.0 ** ** Unless required by applicable law or agreed to in writing, software ** distributed under the License is distributed on an "AS IS" BASIS, ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ** See the License for the specific language governing permissions and ** limitations under the License. */ #include "apreq_util.h" #include "apreq_error.h" #include "apr_time.h" #include "apr_strings.h" #include "apr_lib.h" #include #define MIN(a,b) ( (a) < (b) ? (a) : (b) ) #define MAX(a,b) ( (a) > (b) ? (a) : (b) ) /* used for specifying file sizes */ APREQ_DECLARE(apr_int64_t) apreq_atoi64f(const char *s) { apr_int64_t n = 0; char *p; if (s == NULL) return 0; n = apr_strtoi64(s, &p, 0); if (p == NULL) return n; while (apr_isspace(*p)) ++p; switch (*p) { case 'G': /* fall thru */ case 'g': return n * 1024*1024*1024; case 'M': /* fall thru */ case 'm': return n * 1024*1024; case 'K': /* fall thru */ case 'k': return n * 1024; } return n; } /* converts date offsets (e.g. "+3M") to seconds */ APREQ_DECLARE(apr_int64_t) apreq_atoi64t(const char *s) { apr_int64_t n = 0; char *p; if (s == NULL) return 0; n = apr_strtoi64(s, &p, 0); /* XXX: what about overflow? */ if (p == NULL) return n; while (apr_isspace(*p)) ++p; switch (*p) { case 'Y': /* fall thru */ case 'y': return n * 60*60*24*365; case 'M': return n * 60*60*24*30; case 'D': /* fall thru */ case 'd': return n * 60*60*24; case 'H': /* fall thru */ case 'h': return n * 60*60; case 'm': return n * 60; case 's': /* fall thru */ default: return n; } /* should never get here */ return -1; } APREQ_DECLARE(apr_ssize_t ) apreq_index(const char* hay, apr_size_t hlen, const char* ndl, apr_size_t nlen, const apreq_match_t type) { apr_size_t len = hlen; const char *end = hay + hlen; const char *begin = hay; while ( (hay = memchr(hay, ndl[0], len)) ) { len = end - hay; /* done if matches up to capacity of buffer */ if ( memcmp(hay, ndl, MIN(nlen, len)) == 0 ) { if (type == APREQ_MATCH_FULL && len < nlen) hay = NULL; /* insufficient room for match */ break; } --len; ++hay; } return hay ? hay - begin : -1; } static const char c2x_table[] = "0123456789ABCDEF"; static APR_INLINE unsigned char hex2_to_char(const char *what) { register unsigned char digit; #if !APR_CHARSET_EBCDIC digit = (what[0] >= 'A' ? ((what[0] & 0xdf) - 'A') + 10 : (what[0] - '0')); digit *= 16; digit += (what[1] >= 'A' ? ((what[1] & 0xdf) - 'A') + 10 : (what[1] - '0')); #else /*APR_CHARSET_EBCDIC*/ char xstr[5]; xstr[0]='0'; xstr[1]='x'; xstr[2]=what[0]; xstr[3]=what[1]; xstr[4]='\0'; digit = apr_xlate_conv_byte(ap_hdrs_from_ascii, 0xFF & strtol(xstr, NULL, 16)); #endif /*APR_CHARSET_EBCDIC*/ return (digit); } /* Unicode notes: "bmp" refers to the 16-bit * Unicode Basic Multilingual Plane. Here we're * restricting our unicode internals to 16-bit * codepoints, to keep the code as simple as possible. * This should be sufficient for apreq itself, since * we really only need to validate RFC3986-encoded utf8. */ /* Converts Windows cp1252 to Unicode. */ static APR_INLINE apr_uint16_t cp1252_to_bmp(unsigned char c) { /* We only need to deal with iso-8859-1 control chars * in the 0x80 - 0x9F range. */ if ((c & 0xE0) != 0x80) return c; switch (c) { case 0x80: return 0x20AC; case 0x82: return 0x201A; case 0x83: return 0x192; case 0x84: return 0x201E; case 0x85: return 0x2026; case 0x86: return 0x2020; case 0x87: return 0x2021; case 0x88: return 0x2C6; case 0x89: return 0x2030; case 0x8A: return 0x160; case 0x8B: return 0x2039; case 0x8C: return 0x152; case 0x8E: return 0x17D; case 0x91: return 0x2018; case 0x92: return 0x2019; case 0x93: return 0x201C; case 0x94: return 0x201D; case 0x95: return 0x2022; case 0x96: return 0x2013; case 0x97: return 0x2014; case 0x98: return 0x2DC; case 0x99: return 0x2122; case 0x9A: return 0x161; case 0x9B: return 0x203A; case 0x9C: return 0x153; case 0x9E: return 0x17E; case 0x9F: return 0x178; } return c; } /* converts cp1252 to utf8 */ APREQ_DECLARE(apr_size_t) apreq_cp1252_to_utf8(char *dest, const char *src, apr_size_t slen) { const unsigned char *s = (unsigned const char *)src; const unsigned char *end = s + slen; unsigned char *d = (unsigned char *)dest; apr_uint16_t c; while (s < end) { c = cp1252_to_bmp(*s++); if (c < 0x80) { *d++ = c; } else if (c < 0x800) { *d++ = 0xC0 | (c >> 6); *d++ = 0x80 | (c & 0x3F); } else { *d++ = 0xE0 | (c >> 12); *d++ = 0x80 | ((c >> 6) & 0x3F); *d++ = 0x80 | (c & 0x3F); } } *d = 0; return d - (unsigned char *)dest; } /** * Valid utf8 bit patterns: * * 0xxxxxxx * 110xxxxx 10xxxxxx * 1110xxxx 10xxxxxx 10xxxxxx * 11110xxx 10xxxxxx 10xxxxxx 10xxxxxx * 111110xx 10xxxxxx 10xxxxxx 10xxxxxx 10xxxxxx * 1111110x 10xxxxxx 10xxxxxx 10xxxxxx 10xxxxxx 10xxxxxx */ static APR_INLINE unsigned is_89AB(const char c) { switch(c) { case '8': case '9': case 'A': case 'B': case 'a': case 'b': return 1; } return 0; } static APR_INLINE unsigned is_enc8(const char *word, unsigned char wlen) { while (wlen-- > 0) { if (word[0] == '%' && is_89AB(word[1]) && apr_isxdigit(word[2])) word += 3; else return 0; } return 1; } static APR_INLINE apreq_charset_t fragment_charset(const char *word, const char *end) { unsigned char flen = end - word; unsigned char wlen = flen / 3; if (!is_enc8(word, wlen)) return APREQ_CHARSET_LATIN1; switch (flen % 3) { case 2: if (!is_89AB(*--end)) return APREQ_CHARSET_LATIN1; case 1: if (*--end != '%') return APREQ_CHARSET_LATIN1; } return APREQ_CHARSET_UTF8; } static APR_INLINE apr_uint16_t hex4_to_bmp(const char *what) { register apr_uint16_t digit = 0; #if !APR_CHARSET_EBCDIC digit = (what[0] >= 'A' ? ((what[0] & 0xDF)-'A') + 10 : (what[0]-'0')); digit *= 16; digit += (what[1] >= 'A' ? ((what[1] & 0xDF)-'A') + 10 : (what[1]-'0')); digit *= 16; digit += (what[2] >= 'A' ? ((what[2] & 0xDF)-'A') + 10 : (what[2]-'0')); digit *= 16; digit += (what[3] >= 'A' ? ((what[3] & 0xDF)-'A') + 10 : (what[3]-'0')); #else /*APR_CHARSET_EBCDIC*/ char xstr[7]; xstr[0]='0'; xstr[1]='x'; xstr[2]=what[0]; xstr[3]=what[1]; xstr[4]=what[2]; xstr[5]=what[3]; xstr[6]='\0'; digit = apr_xlate_conv_byte(ap_hdrs_from_ascii, 0xFFFF & strtol(xstr, NULL, 16)); #endif /*APR_CHARSET_EBCDIC*/ return (digit); } /* * Charset divination heuristics: * 1) presume ascii; if not, then * 2) presume utf8; if not, then * 3) presume latin1; unless there are control chars, in which case * 4) punt to cp1252. * * Note: in downgrading from 2 to 3, we should to be careful * about earlier control characters presumed to be valid utf8. * However, we aren't being that careful with the current implementation. */ static apr_status_t url_decode(char *dest, apr_size_t *dlen, apreq_charset_t *charset, const char *src, apr_size_t *slen) { register const char *s = src; unsigned char *start = (unsigned char *)dest; register unsigned char *d = (unsigned char *)dest; const char *end = src + *slen; for (; s < end; ++d, ++s) { switch (*s) { case '+': *d = ' '; break; case '%': if (s + 2 < end && apr_isxdigit(s[1]) && apr_isxdigit(s[2])) { unsigned char c; c = hex2_to_char(s + 1); s += 2; if (c < 0x80 || *charset == APREQ_CHARSET_CP1252) { *d = c; } else if (c < 0xA0) { /* these are ctrl chars in latin1 */ *charset = APREQ_CHARSET_CP1252; *d = c; } else if (c < 0xC0) { *charset = APREQ_CHARSET_LATIN1; *d = c; } else if (*charset == APREQ_CHARSET_LATIN1) { *d = c; } /* utf8 cases */ else if (c < 0xE0) { /* 2-byte utf8 */ if (s + 3 >= end) { *charset = fragment_charset(s+1, end); if (*charset == APREQ_CHARSET_UTF8) { s -= 2; *dlen = d - start; *slen = s - src; memmove(d, s, end - s); d[end - s] = 0; return APR_INCOMPLETE; } *d = c; } else if (is_enc8(s+1, 1)) { *charset = APREQ_CHARSET_UTF8; *d++ = c; *d = hex2_to_char(s+2); s += 3; } else { *charset = APREQ_CHARSET_LATIN1; *d = c; } } else if (c < 0xF0) { /* 3-byte utf8 */ if (s + 6 >= end) { *charset = fragment_charset(s+1, end); if (*charset == APREQ_CHARSET_UTF8) { s -= 2; *dlen = d - start; *slen = s - src; memmove(d, s, end - s); d[end - s] = 0; return APR_INCOMPLETE; } *d = c; } else if (is_enc8(s+1, 2)) { *charset = APREQ_CHARSET_UTF8; *d++ = c; *d++ = hex2_to_char(s+2); *d = hex2_to_char(s+5); s += 6; } else { *charset = APREQ_CHARSET_LATIN1; *d = c; } } else if (c < 0xF8) { /* 4-byte utf8 */ if (s + 9 >= end) { *charset = fragment_charset(s+1, end); if (*charset == APREQ_CHARSET_UTF8) { s -= 2; *dlen = d - start; *slen = s - src; memmove(d, s, end - s); d[end - s] = 0; return APR_INCOMPLETE; } *d = c; } else if (is_enc8(s+1, 3)) { *charset = APREQ_CHARSET_UTF8; *d++ = c; *d++ = hex2_to_char(s+2); *d++ = hex2_to_char(s+5); *d = hex2_to_char(s+8); s += 9; } else { *charset = APREQ_CHARSET_LATIN1; *d = c; } } else if (c < 0xFC) { /* 5-byte utf8 */ if (s + 12 >= end) { *charset = fragment_charset(s+1, end); if (*charset == APREQ_CHARSET_UTF8) { s -= 2; *dlen = d - start; *slen = s - src; memmove(d, s, end - s); d[end - s] = 0; return APR_INCOMPLETE; } *d = c; } else if (is_enc8(s+1, 4)) { *charset = APREQ_CHARSET_UTF8; *d++ = c; *d++ = hex2_to_char(s+2); *d++ = hex2_to_char(s+5); *d++ = hex2_to_char(s+8); *d = hex2_to_char(s+11); s += 12; } else { *charset = APREQ_CHARSET_LATIN1; *d = c; } } else if (c < 0xFE) { /* 6-byte utf8 */ if (s + 15 >= end) { *charset = fragment_charset(s+1, end); if (*charset == APREQ_CHARSET_UTF8) { s -= 2; *dlen = d - start; *slen = s - src; memmove(d, s, end - s); d[end - s] = 0; return APR_INCOMPLETE; } *d = c; } else if (is_enc8(s+1, 5)) { *charset = APREQ_CHARSET_UTF8; *d++ = c; *d++ = hex2_to_char(s+2); *d++ = hex2_to_char(s+5); *d++ = hex2_to_char(s+8); *d++ = hex2_to_char(s+11); *d = hex2_to_char(s+14); s += 15; } else { *charset = APREQ_CHARSET_LATIN1; *d = c; } } else { /* (skipped) utf8 byte-order mark */ *charset = APREQ_CHARSET_UTF8; } } else if (s + 5 < end && (s[1] == 'u' || s[1] == 'U') && apr_isxdigit(s[2]) && apr_isxdigit(s[3]) && apr_isxdigit(s[4]) && apr_isxdigit(s[5])) { apr_uint16_t c = hex4_to_bmp(s+2); switch (*charset) { case APREQ_CHARSET_ASCII: *charset = APREQ_CHARSET_UTF8; case APREQ_CHARSET_UTF8: break; default: *dlen = d - start; *slen = s - src; *d = 0; return APREQ_ERROR_BADSEQ; } if (c < 0x80) { *d = c; } else if (c < 0x800) { *d++ = 0xC0 | (c >> 6); *d = 0x80 | (c & 0x3F); } else { *d++ = 0xE0 | (c >> 12); *d++ = 0x80 | ((c >> 6) & 0x3F); *d = 0x80 | (c & 0x3F); } s += 5; } else { *dlen = d - start; *slen = s - src; if (s + 5 < end || (s + 2 < end && !apr_isxdigit(s[2])) || (s + 1 < end && !apr_isxdigit(s[1]) && s[1] != 'u' && s[1] != 'U')) { *d = 0; return APREQ_ERROR_BADSEQ; } memmove(d, s, end - s); d[end - s] = 0; return APR_INCOMPLETE; } break; default: if (s > 0) { *d = *s; } else { *d = 0; *dlen = d - start; *slen = s - src; return APREQ_ERROR_BADCHAR; } } } *d = 0; *dlen = d - start; *slen = s - src; return APR_SUCCESS; } APREQ_DECLARE(apr_status_t) apreq_decode(char *d, apr_size_t *dlen, const char *s, apr_size_t slen) { apr_size_t len = 0; const char *end = s + slen; apr_status_t rv; apreq_charset_t c = APREQ_CHARSET_ASCII; if (s == (const char *)d) { /* optimize for src = dest case */ for ( ; d < end; ++d) { if (*d == '%' || *d == '+') break; else if (*d == 0) { *dlen = (const char *)d - s; return APREQ_ERROR_BADCHAR; } } len = (const char *)d - s; s = (const char *)d; slen -= len; } rv = url_decode(d, dlen, &c, s, &slen); *dlen += len; return rv + c; } APREQ_DECLARE(apr_status_t) apreq_decodev(char *d, apr_size_t *dlen, struct iovec *v, int nelts) { apr_status_t status = APR_SUCCESS; apreq_charset_t c = APREQ_CHARSET_ASCII; int n = 0; *dlen = 0; while (n < nelts) { apr_size_t slen, len; slen = v[n].iov_len; switch (status = url_decode(d,&len, &c, v[n].iov_base, &slen)) { case APR_SUCCESS: d += len; *dlen += len; ++n; continue; case APR_INCOMPLETE: d += len; *dlen += len; if (++n == nelts) return APR_INCOMPLETE + c; len = v[n-1].iov_len - slen; memcpy(d + len, v[n].iov_base, v[n].iov_len); v[n].iov_len += len; v[n].iov_base = d; continue; default: *dlen += len; return status; } } return APR_SUCCESS + c; } APREQ_DECLARE(apr_size_t) apreq_encode(char *dest, const char *src, const apr_size_t slen) { char *d = dest; const unsigned char *s = (const unsigned char *)src; unsigned c; for ( ; s < (const unsigned char *)src + slen; ++s) { c = *s; if ( apr_isalnum(c) || c == '-' || c == '.' || c == '_' || c == '~' ) *d++ = c; else if ( c == ' ' ) *d++ = '+'; else { #if APR_CHARSET_EBCDIC c = apr_xlate_conv_byte(ap_hdrs_to_ascii, (unsigned char)c); #endif *d++ = '%'; *d++ = c2x_table[c >> 4]; *d++ = c2x_table[c & 0xf]; } } *d = 0; return d - dest; } static int is_quoted(const char *p, const apr_size_t len) { if (len > 1 && p[0] == '"' && p[len-1] == '"') { apr_size_t i; int backslash = 0; for (i = 1; i < len - 1; i++) { if (p[i] == '\\') backslash = !backslash; else if (p[i] == 0 || (p[i] == '"' && !backslash)) return 0; else backslash = 0; } return !backslash; } return 0; } APREQ_DECLARE(apr_size_t) apreq_quote_once(char *dest, const char *src, const apr_size_t slen) { if (is_quoted(src, slen)) { /* looks like src is already quoted */ memcpy(dest, src, slen); dest[slen] = 0; return slen; } else return apreq_quote(dest, src, slen); } APREQ_DECLARE(apr_size_t) apreq_quote(char *dest, const char *src, const apr_size_t slen) { char *d = dest; const char *s = src; const char *const last = src + slen - 1; if (slen == 0) { *d = 0; return 0; } *d++ = '"'; while (s <= last) { switch (*s) { case 0: *d++ = '\\'; *d++ = '0'; s++; break; case '\\': case '"': *d++ = '\\'; default: *d++ = *s++; } } *d++ = '"'; *d = 0; return d - dest; } APREQ_DECLARE(char *) apreq_join(apr_pool_t *p, const char *sep, const apr_array_header_t *arr, apreq_join_t mode) { apr_ssize_t len, slen; char *rv; const apreq_value_t **a = (const apreq_value_t **)arr->elts; char *d; const int n = arr->nelts; int j; slen = sep ? strlen(sep) : 0; if (n == 0) return apr_pstrdup(p, ""); for (j=0, len=0; j < n; ++j) len += a[j]->dlen + slen + 1; /* Allocated the required space */ switch (mode) { case APREQ_JOIN_ENCODE: len += 2 * len; break; case APREQ_JOIN_QUOTE: len = 2 * (len + n); break; case APREQ_JOIN_AS_IS: case APREQ_JOIN_DECODE: /* nothing special required, just here to keep noisy compilers happy */ break; } rv = apr_palloc(p, len); /* Pass two --- copy the argument strings into the result space */ d = rv; switch (mode) { case APREQ_JOIN_ENCODE: d += apreq_encode(d, a[0]->data, a[0]->dlen); for (j = 1; j < n; ++j) { memcpy(d, sep, slen); d += slen; d += apreq_encode(d, a[j]->data, a[j]->dlen); } break; case APREQ_JOIN_DECODE: if (apreq_decode(d, &len, a[0]->data, a[0]->dlen)) return NULL; else d += len; for (j = 1; j < n; ++j) { memcpy(d, sep, slen); d += slen; if (apreq_decode(d, &len, a[j]->data, a[j]->dlen)) return NULL; else d += len; } break; case APREQ_JOIN_QUOTE: d += apreq_quote_once(d, a[0]->data, a[0]->dlen); for (j = 1; j < n; ++j) { memcpy(d, sep, slen); d += slen; d += apreq_quote_once(d, a[j]->data, a[j]->dlen); } break; case APREQ_JOIN_AS_IS: memcpy(d,a[0]->data, a[0]->dlen); d += a[0]->dlen; for (j = 1; j < n ; ++j) { memcpy(d, sep, slen); d += slen; memcpy(d, a[j]->data, a[j]->dlen); d += a[j]->dlen; } break; } *d = 0; return rv; } APR_INLINE static apr_status_t apreq_fwritev(apr_file_t *f, struct iovec *v, int *nelts, apr_size_t *bytes_written) { apr_size_t len; int n; apr_status_t s; *bytes_written = 0; while (1) { /* try to write */ s = apr_file_writev(f, v, *nelts, &len); *bytes_written += len; if (s != APR_SUCCESS) return s; /* see how far we've come */ n = 0; while (n < *nelts && len >= v[n].iov_len) len -= v[n++].iov_len; if (n == *nelts) { /* nothing left to write, report success */ *nelts = 0; return APR_SUCCESS; } /* incomplete write: must shift v */ v[n].iov_len -= len; v[n].iov_base = (char *)(v[n].iov_base) + len; if (n > 0) { /* we're satisfied for now if we can remove one iovec from the "v" array */ (*nelts) -= n; memmove(v, v + n, sizeof(*v) * *nelts); return APR_SUCCESS; } /* we're still in the first iovec - check for endless loop, and then try again */ if (len == 0) return APREQ_ERROR_GENERAL; } } APREQ_DECLARE(apr_status_t) apreq_brigade_fwrite(apr_file_t *f, apr_off_t *wlen, apr_bucket_brigade *bb) { struct iovec v[APREQ_DEFAULT_NELTS]; apr_status_t s; apr_bucket *e; int n = 0; *wlen = 0; for (e = APR_BRIGADE_FIRST(bb); e != APR_BRIGADE_SENTINEL(bb); e = APR_BUCKET_NEXT(e)) { apr_size_t len; if (n == APREQ_DEFAULT_NELTS) { s = apreq_fwritev(f, v, &n, &len); if (s != APR_SUCCESS) return s; *wlen += len; } s = apr_bucket_read(e, (const char **)&(v[n].iov_base), &len, APR_BLOCK_READ); if (s != APR_SUCCESS) return s; v[n++].iov_len = len; } while (n > 0) { apr_size_t len; s = apreq_fwritev(f, v, &n, &len); if (s != APR_SUCCESS) return s; *wlen += len; } return APR_SUCCESS; } struct cleanup_data { const char *fname; apr_pool_t *pool; }; static apr_status_t apreq_file_cleanup(void *d) { struct cleanup_data *data = d; return apr_file_remove(data->fname, data->pool); } /* * The reason we need the above cleanup is because on Windows, APR_DELONCLOSE * forces applications to open the file with FILE_SHARED_DELETE * set, which is, unfortunately, a property that is preserved * across NTFS "hard" links. This breaks apps that link() the temp * file to a permanent location, and subsequently expect to open it * before the original tempfile is closed+deleted. In fact, even * Apache::Upload does this, so it is a common enough event that the * apreq_file_cleanup workaround is necessary. */ APREQ_DECLARE(apr_status_t) apreq_file_mktemp(apr_file_t **fp, apr_pool_t *pool, const char *path) { apr_status_t rc; char *tmpl; struct cleanup_data *data; if (path == NULL) { rc = apr_temp_dir_get(&path, pool); if (rc != APR_SUCCESS) return rc; } rc = apr_filepath_merge(&tmpl, path, "apreqXXXXXX", APR_FILEPATH_NOTRELATIVE, pool); if (rc != APR_SUCCESS) return rc; data = apr_palloc(pool, sizeof *data); /* cleanups are LIFO, so this one will run just after the cleanup set by mktemp */ apr_pool_cleanup_register(pool, data, apreq_file_cleanup, apreq_file_cleanup); rc = apr_file_mktemp(fp, tmpl, /* NO APR_DELONCLOSE! see comment above */ APR_CREATE | APR_READ | APR_WRITE | APR_EXCL | APR_BINARY, pool); if (rc == APR_SUCCESS) { apr_file_name_get(&data->fname, *fp); data->pool = pool; } else { apr_pool_cleanup_kill(pool, data, apreq_file_cleanup); } return rc; } /* * is_2616_token() is the verbatim definition from section 2.2 * in the rfc itself. We try to optimize it around the * expectation that the argument is not a token, which * should be the typical usage. */ static APR_INLINE unsigned is_2616_token(const char c) { switch (c) { case ' ': case ';': case ',': case '"': case '\t': /* The chars we are expecting are listed above; the chars below are just for completeness. */ case '?': case '=': case '@': case ':': case '\\': case '/': case '(': case ')': case '<': case '>': case '{': case '}': case '[': case ']': return 0; default: if (apr_iscntrl(c)) return 0; } return 1; } APREQ_DECLARE(apr_status_t) apreq_header_attribute(const char *hdr, const char *name, const apr_size_t nlen, const char **val, apr_size_t *vlen) { const char *key, *v; /* Must ensure first char isn't '=', so we can safely backstep. */ while (*hdr == '=') ++hdr; while ((key = strchr(hdr, '=')) != NULL) { v = key + 1; --key; while (apr_isspace(*key) && key > hdr + nlen) --key; key -= nlen - 1; while (apr_isspace(*v)) ++v; if (*v == '"') { ++v; *val = v; look_for_end_quote: switch (*v) { case '"': break; case 0: return APREQ_ERROR_BADSEQ; case '\\': if (v[1] != 0) ++v; default: ++v; goto look_for_end_quote; } } else { *val = v; look_for_terminator: switch (*v) { case 0: case ' ': case ';': case ',': case '\t': case '\r': case '\n': break; default: ++v; goto look_for_terminator; } } if (strncasecmp(key, name, nlen) == 0) { *vlen = v - *val; if (key == hdr || ! is_2616_token(key[-1])) return APR_SUCCESS; } hdr = v; } return APREQ_ERROR_NOATTR; } #define BUCKET_IS_SPOOL(e) ((e)->type == &spool_bucket_type) #define FILE_BUCKET_LIMIT ((apr_size_t)-1 - 1) static void spool_bucket_destroy(void *data) { apr_bucket_type_file.destroy(data); } static apr_status_t spool_bucket_read(apr_bucket *e, const char **str, apr_size_t *len, apr_read_type_e block) { return apr_bucket_type_file.read(e, str, len, block); } static apr_status_t spool_bucket_setaside(apr_bucket *data, apr_pool_t *reqpool) { return apr_bucket_type_file.setaside(data, reqpool); } static apr_status_t spool_bucket_split(apr_bucket *a, apr_size_t point) { apr_status_t rv = apr_bucket_shared_split(a, point); a->type = &apr_bucket_type_file; return rv; } static apr_status_t spool_bucket_copy(apr_bucket *e, apr_bucket **c) { apr_status_t rv = apr_bucket_shared_copy(e, c); (*c)->type = &apr_bucket_type_file; return rv; } static const apr_bucket_type_t spool_bucket_type = { "APREQ_SPOOL", 5, APR_BUCKET_DATA, spool_bucket_destroy, spool_bucket_read, spool_bucket_setaside, spool_bucket_split, spool_bucket_copy, }; APREQ_DECLARE(apr_file_t *)apreq_brigade_spoolfile(apr_bucket_brigade *bb) { apr_bucket *last; last = APR_BRIGADE_LAST(bb); if (BUCKET_IS_SPOOL(last)) return ((apr_bucket_file *)last->data)->fd; return NULL; } APREQ_DECLARE(apr_status_t) apreq_brigade_concat(apr_pool_t *pool, const char *temp_dir, apr_size_t heap_limit, apr_bucket_brigade *out, apr_bucket_brigade *in) { apr_status_t s; apr_bucket_file *f; apr_off_t wlen; apr_file_t *file; apr_off_t in_len, out_len; apr_bucket *last_in, *last_out; last_out = APR_BRIGADE_LAST(out); if (APR_BUCKET_IS_EOS(last_out)) return APR_EOF; s = apr_brigade_length(out, 0, &out_len); if (s != APR_SUCCESS) return s; /* This cast, when out_len = -1, is intentional */ if ((apr_uint64_t)out_len < heap_limit) { s = apr_brigade_length(in, 0, &in_len); if (s != APR_SUCCESS) return s; /* This cast, when in_len = -1, is intentional */ if ((apr_uint64_t)in_len < heap_limit - (apr_uint64_t)out_len) { APR_BRIGADE_CONCAT(out, in); return APR_SUCCESS; } } if (!BUCKET_IS_SPOOL(last_out)) { s = apreq_file_mktemp(&file, pool, temp_dir); if (s != APR_SUCCESS) return s; s = apreq_brigade_fwrite(file, &wlen, out); if (s != APR_SUCCESS) return s; last_out = apr_bucket_file_create(file, wlen, 0, out->p, out->bucket_alloc); last_out->type = &spool_bucket_type; APR_BRIGADE_INSERT_TAIL(out, last_out); f = last_out->data; } else { f = last_out->data; /* Need to seek here, just in case our spool bucket * was read from between apreq_brigade_concat calls. */ wlen = last_out->start + last_out->length; s = apr_file_seek(f->fd, APR_SET, &wlen); if (s != APR_SUCCESS) return s; } if (in == out) return APR_SUCCESS; last_in = APR_BRIGADE_LAST(in); if (APR_BUCKET_IS_EOS(last_in)) APR_BUCKET_REMOVE(last_in); s = apreq_brigade_fwrite(f->fd, &wlen, in); if (s == APR_SUCCESS) { /* We have to deal with the possibility that the new * data may be too large to be represented by a single * temp_file bucket. */ while ((apr_uint64_t)wlen > FILE_BUCKET_LIMIT - last_out->length) { apr_bucket *e; apr_bucket_copy(last_out, &e); e->length = 0; e->start = last_out->start + FILE_BUCKET_LIMIT; wlen -= FILE_BUCKET_LIMIT - last_out->length; last_out->length = FILE_BUCKET_LIMIT; last_out->type = &apr_bucket_type_file; APR_BRIGADE_INSERT_TAIL(out, e); last_out = e; } last_out->length += wlen; if (APR_BUCKET_IS_EOS(last_in)) APR_BRIGADE_INSERT_TAIL(out, last_in); } else if (APR_BUCKET_IS_EOS(last_in)) APR_BRIGADE_INSERT_TAIL(in, last_in); apr_brigade_cleanup(in); return s; } rapache-1.2.8/libapreq2/library/version.c0000644000175100017510000000204512706745114017641 0ustar ondrejondrej/* ** Copyright 2003-2005 The Apache Software Foundation ** ** Licensed under the Apache License, Version 2.0 (the "License"); ** you may not use this file except in compliance with the License. ** You may obtain a copy of the License at ** ** http://www.apache.org/licenses/LICENSE-2.0 ** ** Unless required by applicable law or agreed to in writing, software ** distributed under the License is distributed on an "AS IS" BASIS, ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ** See the License for the specific language governing permissions and ** limitations under the License. */ #include "apreq_version.h" #include "apr_general.h" /* for APR_STRINGIFY */ APREQ_DECLARE(void) apreq_version(apr_version_t *pvsn) { pvsn->major = APREQ_MAJOR_VERSION; pvsn->minor = APREQ_MINOR_VERSION; pvsn->patch = APREQ_PATCH_VERSION; #ifdef APREQ_IS_DEV_VERSION pvsn->is_dev = 1; #else pvsn->is_dev = 0; #endif } APREQ_DECLARE(const char *) apreq_version_string(void) { return APREQ_VERSION_STRING; } rapache-1.2.8/libapreq2/ltmain.sh0000644000175100017510000054737212706745114016205 0ustar ondrejondrej# 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 # 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. # # 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. 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=1.5.6 TIMESTAMP=" (1.1220.2.95 2004/04/11 05:50:42) Debian$Rev: 224 $" # 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 $echo "Fatal configuration error. See the $PACKAGE docs for more information." 1>&2 exit $EXIT_FAILURE fi # Global variables. mode=$default_mode nonopt= prev= prevopt= run= show="$echo" show_help= execute_dlfiles= lo2o="s/\\.lo\$/.${objext}/" o2lo="s/\\.${objext}\$/.lo/" ##################################### # Shell function definitions: # This seems to be the best place for them # 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 () { 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 /{x;/import/!{s/^/import/;h;p;};x;};}'` if test "X$win32_nmres" = "Ximport" ; then win32_libid_type="x86 archive import" else win32_libid_type="x86 archive static" fi 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_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 () { 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. *) 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 } # End of Shell function definitions ##################################### # Darwin sucks eval std_shrext=\"$shrext_cmds\" # Parse our command line options once, thoroughly. while test "$#" -gt 0 do arg="$1" shift case $arg in -*=*) optarg=`$echo "X$arg" | $Xsed -e 's/[-_a-zA-Z0-9]*=//'` ;; *) optarg= ;; esac # If the previous option needs an argument, assign it. if test -n "$prev"; then case $prev in execute_dlfiles) execute_dlfiles="$execute_dlfiles $arg" ;; tag) tagname="$arg" preserve_args="${preserve_args}=$arg" # Check whether tagname contains only valid characters case $tagname in *[!-_A-Za-z0-9,/]*) $echo "$progname: invalid tag name: $tagname" 1>&2 exit $EXIT_FAILURE ;; esac 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 prev= prevopt= continue fi # Have we seen a non-optional argument yet? case $arg in --help) show_help=yes ;; --version) $echo "$PROGRAM (GNU $PACKAGE) $VERSION$TIMESTAMP" $echo $echo "Copyright (C) 2003 Free Software Foundation, Inc." $echo "This is free software; see the source for copying conditions. There is NO" $echo "warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." exit $EXIT_SUCCESS ;; --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 -e "/^# ### BEGIN LIBTOOL TAG CONFIG: $tagname$/,/^# ### END LIBTOOL TAG CONFIG: $tagname$/p" < "$progpath" done exit $EXIT_SUCCESS ;; --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" else $echo "disable shared libraries" fi if test "$build_old_libs" = yes; then $echo "enable static libraries" else $echo "disable static libraries" fi exit $EXIT_SUCCESS ;; --finish) mode="finish" ;; --mode) prevopt="--mode" prev=mode ;; --mode=*) mode="$optarg" ;; --preserve-dup-deps) duplicate_deps="yes" ;; --quiet | --silent) show=: preserve_args="$preserve_args $arg" ;; --tag) prevopt="--tag" prev=tag ;; --tag=*) set tag "$optarg" ${1+"$@"} shift prev=tag preserve_args="$preserve_args --tag" ;; -dlopen) prevopt="-dlopen" prev=execute_dlfiles ;; -*) $echo "$modename: unrecognized option \`$arg'" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE ;; *) nonopt="$arg" break ;; esac done if test -n "$prevopt"; then $echo "$modename: option \`$prevopt' requires an argument" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE fi # 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 # 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 ;; *db | *dbx | *strace | *truss) mode=execute ;; *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 # 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 ;; esac fi # Only execute mode is allowed to have -dlopen flags. if test -n "$execute_dlfiles" && test "$mode" != execute; then $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 \`$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= for arg do case "$arg_mode" in arg ) # do not "continue". Instead, add this to base_compile lastarg="$arg" arg_mode=normal ;; target ) libobj="$arg" arg_mode=normal continue ;; 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 ;; -static | -prefer-pic | -prefer-non-pic) later="$later $arg" continue ;; -no-suppress) suppress_opt=no continue ;; -Xcompiler) arg_mode=arg # the next one goes into the "base_compile" arg list continue # The current "srcfile" will either be retained or ;; # replaced later. I would guess that would be a bug. -Wc,*) args=`$echo "X$arg" | $Xsed -e "s/^-Wc,//"` lastarg= save_ifs="$IFS"; IFS=',' for arg in $args; do IFS="$save_ifs" # Double-quote args containing other shell metacharacters. # Many Bourne shells cannot handle close brackets correctly # in scan sets, so we specify it separately. case $arg in *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") arg="\"$arg\"" ;; esac lastarg="$lastarg $arg" done IFS="$save_ifs" 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. # lastarg="$srcfile" srcfile="$arg" ;; esac # case $arg ;; esac # case $arg_mode # Aesthetically quote the previous argument. 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, so we specify it separately. *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") lastarg="\"$lastarg\"" ;; esac base_compile="$base_compile $lastarg" done # for arg case $arg_mode in arg) $echo "$modename: you must specify an argument for -Xcompile" exit $EXIT_FAILURE ;; target) $echo "$modename: you must specify a target with \`-o'" 1>&2 exit $EXIT_FAILURE ;; *) # Get the name of the library object. [ -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 *.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 ;; *.f90) xform=f90 ;; *.for) xform=for ;; *.java) xform=java ;; esac libobj=`$echo "X$libobj" | $Xsed -e "s/\.$xform$/.lo/"` case $libobj in *.lo) obj=`$echo "X$libobj" | $Xsed -e "$lo2o"` ;; *) $echo "$modename: cannot determine name of library object from \`$libobj'" 1>&2 exit $EXIT_FAILURE ;; esac func_infer_tag $base_compile for arg in $later; do case $arg in -static) build_old_libs=yes continue ;; -prefer-pic) pic_mode=yes continue ;; -prefer-non-pic) pic_mode=no continue ;; esac done 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 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 removelist="$obj $lobj $libobj ${libobj}T" else 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*) pic_mode=default ;; esac if test "$pic_mode" = no && test "$deplibs_check_method" != pass_all; then # non-PIC code in shared libraries is not supported pic_mode=default fi # 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} 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 lockfile= fi # 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 $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 "\ *** ERROR, $lockfile exists and contains: `cat $lockfile 2>/dev/null` This indicates that another process is trying to use the same temporary object file, and libtool could not work around it because your compiler does not support \`-c' and \`-o' together. If you 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." $run $rm $removelist exit $EXIT_FAILURE fi $echo $srcfile > "$lockfile" fi if test -n "$fix_srcfile_path"; then eval srcfile=\"$fix_srcfile_path\" fi $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 "\ *** ERROR, $lockfile contains: `cat $lockfile 2>/dev/null` but it should contain: $srcfile This indicates that another process is trying to use the same temporary object file, and libtool could not work around it because your compiler does not support \`-c' and \`-o' together. If you 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." $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 $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 "\ *** ERROR, $lockfile contains: `cat $lockfile 2>/dev/null` but it should contain: $srcfile This indicates that another process is trying to use the same temporary object file, and libtool could not work around it because your compiler does not support \`-c' and \`-o' together. If you 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." $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 $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 else if test -z "$pic_flag" && test -n "$link_static_flag"; then dlopen_self=$dlopen_self_static fi fi build_libtool_libs=no build_old_libs=yes prefer_static_libs=yes break ;; esac done # See if our shared archives depend on static archives. test -n "$old_archive_from_new_cmds" && build_old_libs=yes # 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" # 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 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. # 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= # Read the .lo file # If there is no directory component, then add one. case $arg in */* | *\\*) . $arg ;; *) . ./$arg ;; esac 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 # Extract subdirectory from the argument. xdir=`$echo "X$arg" | $Xsed -e 's%/[^/]*$%%'` if test "X$xdir" = "X$arg"; then xdir= else xdir="$xdir/" fi 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 # CHECK ME: I think I busted this. -Ossama if test "$prev" = dlprefiles; then # Preload the old-style object. dlprefiles="$dlprefiles $pic_object" prev= fi # A PIC object. libobjs="$libobjs $pic_object" arg="$pic_object" 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" # 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 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. # Extract subdirectory from the argument. xdir=`$echo "X$arg" | $Xsed -e 's%/[^/]*$%%'` if test "X$xdir" = "X$arg"; then xdir= else xdir="$xdir/" fi 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 ;; *) eval "$prev=\"\$arg\"" prev= continue ;; esac fi # test -n "$prev" prevarg="$arg" 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 ;; -allow-undefined) # FIXME: remove this flag sometime in the future. $echo "$modename: \`-allow-undefined' is deprecated because it is the default" 1>&2 continue ;; -avoid-version) avoid_version=yes continue ;; -dlopen) prev=dlfiles continue ;; -dlpreopen) prev=dlprefiles continue ;; -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 ;; -inst-prefix-dir) prev=inst_prefix continue ;; # 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 ;; -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 exit $EXIT_FAILURE 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*) case :$dllsearchpath: in *":$dir:"*) ;; *) dllsearchpath="$dllsearchpath:$dir";; esac ;; esac continue ;; -l*) if test "X$arg" = "X-lc" || test "X$arg" = "X-lm"; then case $host in *-*-cygwin* | *-*-pw32* | *-*-beos*) # These systems don't actually have a C or math library (as such) continue ;; *-*-mingw* | *-*-os2*) # These systems don't actually have a C library (as such) test "X$arg" = "X-lc" && continue ;; *-*-openbsd* | *-*-freebsd*) # 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 esac elif test "X$arg" = "X-lc_r"; then case $host in *-*-openbsd* | *-*-freebsd*) # Do not include libc_r directly, use -pthread flag. continue ;; esac fi deplibs="$deplibs $arg" continue ;; -mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe) deplibs="$deplibs $arg" continue ;; -module) module=yes continue ;; # gcc -m* arguments should be passed to the linker via $compiler_flags # in order to pass architecture information to the linker # (e.g. 32 vs 64-bit). This may also be accomplished via -Wl,-mfoo # but this is not reliable with gcc because gcc may use -mfoo to # select a different linker, different libraries, etc, while # -Wl,-mfoo simply passes -mfoo to the linker. -m*) # 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" if test "$with_gcc" = "yes" ; then compiler_flags="$compiler_flags $arg" fi continue ;; -shrext) prev=shrext continue ;; -no-fast-install) fast_install=no continue ;; -no-install) case $host in *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2*) # The PATH hackery in wrapper scripts is required on Windows # 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 ;; -no-undefined) allow_undefined=no continue ;; -objectlist) prev=objectlist continue ;; -o) prev=output ;; -precious-files-regex) prev=precious_regex continue ;; -release) prev=release continue ;; -rpath) prev=rpath continue ;; -R) prev=xrpath continue ;; -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 ;; -static) # 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 ;; -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/^ //"` ;; -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/^ //"` ;; -Xcompiler) prev=xcompiler continue ;; -Xlinker) prev=xlinker continue ;; -XCClinker) prev=xcclinker continue ;; # 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 ;; *.$objext) # A standard object. objs="$objs $arg" ;; *.lo) # A libtool-controlled object. # 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= # Read the .lo file # If there is no directory component, then add one. case $arg in */* | *\\*) . $arg ;; *) . ./$arg ;; esac 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 # Extract subdirectory from the argument. xdir=`$echo "X$arg" | $Xsed -e 's%/[^/]*$%%'` if test "X$xdir" = "X$arg"; then xdir= else xdir="$xdir/" fi 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 # CHECK ME: I think I busted this. -Ossama if test "$prev" = dlprefiles; then # Preload the old-style object. dlprefiles="$dlprefiles $pic_object" prev= fi # A PIC object. libobjs="$libobjs $pic_object" arg="$pic_object" 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" # 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 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. # Extract subdirectory from the argument. xdir=`$echo "X$arg" | $Xsed -e 's%/[^/]*$%%'` if test "X$xdir" = "X$arg"; then xdir= else xdir="$xdir/" fi 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 ;; *.$libext) # An archive. deplibs="$deplibs $arg" old_deplibs="$old_deplibs $arg" continue ;; *.la) # A libtool-controlled library. 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" 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. arg=`$echo "X$arg" | $Xsed -e "$sed_quote_subst"` case $arg in *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") arg="\"$arg\"" ;; esac ;; esac # arg # 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 test -n "$prev"; then $echo "$modename: the \`$prevarg' option requires an argument" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE fi 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 oldlibs= # calculate the name of the file, without its directory outputname=`$echo "X$output" | $Xsed -e 's%^.*/%%'` libobjs_save="$libobjs" 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\" output_objdir=`$echo "X$output" | $Xsed -e 's%/[^/]*$%%'` if test "X$output_objdir" = "X$output"; then output_objdir="$objdir" else output_objdir="$output_objdir/$objdir" fi # Create the object directory. if test ! -d "$output_objdir"; then $show "$mkdir $output_objdir" $run $mkdir $output_objdir status=$? if test "$status" -ne 0 && test ! -d "$output_objdir"; then exit $status fi 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 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= 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 if test "$linkmode" = lib; then libs="$predeps $libs $compiler_lib_search_path $postdeps" # 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 pre_post_deps="$pre_post_deps $pre_post_dep" done fi pre_post_deps= fi 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 case $linkmode in lib) passes="conv link" for file in $dlfiles $dlprefiles; do case $file in *.la) ;; *) $echo "$modename: libraries can \`-dlopen' only libtool libraries: $file" 1>&2 exit $EXIT_FAILURE ;; esac done ;; prog) compile_deplibs= finalize_deplibs= alldeplibs=no newdlfiles= newdlprefiles= passes="conv scan dlopen dlpreopen link" ;; *) passes="conv" ;; esac 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%" test "X$link_all_deplibs" != Xno && libs="$libs $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) if test "$linkmode,$pass" = "prog,link"; then compile_deplibs="$deplib $compile_deplibs" finalize_deplibs="$deplib $finalize_deplibs" else deplibs="$deplib $deplibs" 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//'` for searchdir in $newlib_search_path $lib_search_path $sys_lib_search_path $shlib_search_path; 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) if test "$deplibs_check_method" != pass_all; 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'" 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 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 # Read the .la file case $lib in */* | *\\*) . $lib ;; *) . ./$lib ;; esac 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 # 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 # 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 # 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%^.*/%%'` # 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 else dir="$ladir/$objdir" absdir="$abs_ladir/$objdir" # Remove this search path later notinst_path="$notinst_path $abs_ladir" fi # $installed = yes name=`$echo "X$laname" | $Xsed -e 's/\.la$//' -e 's/^lib//'` # 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 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 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*) 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 test "$linkmode,$pass" = "prog,link"; then if test -n "$library_names" && { test "$prefer_static_libs" = no || test -z "$old_library"; }; then # We need to hardcode the library path if test -n "$shlibpath_var"; then # Make sure the rpath contains only unique directories. case "$temp_rpath " in *" $dir "*) ;; *" $absdir "*) ;; *) temp_rpath="$temp_rpath $dir" ;; 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... 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 link_static=no # Whether the deplib will be linked statically if test -n "$library_names" && { test "$prefer_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 # 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 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 # 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" # 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 # 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" 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* ) 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 if test "$lib_linked" != yes; then $echo "$modename: configuration error: unsupported hardcode properties" exit $EXIT_FAILURE fi 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 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 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 convenience="$convenience $dir/$old_library" old_convenience="$old_convenience $dir/$old_library" 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*) 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 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 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` if test -n "$deplibrary_names" ; then for tmp in $deplibrary_names ; do depdepl=$tmp done if test -f "$path/$depdepl" ; then depdepl="$path/$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 *" $depdepl "*) ;; *) deplibs="$depdepl $deplibs" ;; esac case " $deplibs " in *" $path "*) ;; *) deplibs="$deplibs $path" ;; 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 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 case $linkmode in oldlib) if test -n "$deplibs"; then $echo "$modename: warning: \`-l' and \`-L' are ignored for archives" 1>&2 fi if test -n "$dlfiles$dlprefiles" || test "$dlself" != no; then $echo "$modename: warning: \`-dlopen' is ignored for archives" 1>&2 fi 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 if test -n "$vinfo"; then $echo "$modename: warning: \`-version-info/-version-number' is ignored for archives" 1>&2 fi if test -n "$release"; then $echo "$modename: warning: \`-release' is ignored for archives" 1>&2 fi if test -n "$export_symbols" || test -n "$export_symbols_regex"; then $echo "$modename: warning: \`-export-symbols' is ignored for archives" 1>&2 fi # 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*) 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 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 test "$dlself" != no; then $echo "$modename: warning: \`-dlopen self' is ignored for libtool libraries" 1>&2 fi 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" 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 if test -n "$vinfo"; then $echo "$modename: warning: \`-version-info/-version-number' is ignored for convenience libraries" 1>&2 fi if test -n "$release"; then $echo "$modename: warning: \`-release' is ignored for convenience libraries" 1>&2 fi else # Parse the version information argument. save_ifs="$IFS"; IFS=':' set dummy $vinfo 0 0 0 IFS="$save_ifs" if test -n "$8"; then $echo "$modename: too many parameters to \`-version-info'" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE fi # 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="$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) 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 - 1` age="$number_minor" revision="$number_minor" ;; *) $echo "$modename: unknown library version type \`$version_type'" 1>&2 $echo "Fatal configuration error. See the $PACKAGE docs for more information." 1>&2 exit $EXIT_FAILURE ;; esac ;; no) current="$2" revision="$3" age="$4" ;; 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]) ;; *) $echo "$modename: CURRENT \`$current' is not a nonnegative integer" 1>&2 $echo "$modename: \`$vinfo' is not valid version information" 1>&2 exit $EXIT_FAILURE ;; 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]) ;; *) $echo "$modename: REVISION \`$revision' is not a nonnegative integer" 1>&2 $echo "$modename: \`$vinfo' is not valid version information" 1>&2 exit $EXIT_FAILURE ;; 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]) ;; *) $echo "$modename: AGE \`$age' is not a nonnegative integer" 1>&2 $echo "$modename: \`$vinfo' is not valid version information" 1>&2 exit $EXIT_FAILURE ;; esac 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 # 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 major=.`expr $current - $age` versuffix="$major.$age.$revision" # Darwin ld doesn't like 0 for these options... minor_current=`expr $current + 1` 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) major=`expr $current - $age + 1` 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 iface=`expr $revision - $loop` loop=`expr $loop - 1` verstring="$verstring_prefix$major.$iface:$verstring" done # Before this point, $major must not contain `.'. major=.$major versuffix="$major.$revision" ;; linux) major=.`expr $current - $age` versuffix="$major.$age.$revision" ;; osf) major=.`expr $current - $age` 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 iface=`expr $current - $loop` loop=`expr $loop - 1` verstring="$verstring:${iface}.0" done # Make executables depend on our current version. verstring="$verstring:${current}.0" ;; sunos) major=".$current" versuffix=".$current.$revision" ;; windows) # Use '-' rather than '.', since we only want one # extension on DOS 8.3 filesystems. major=`expr $current - $age` versuffix="-$major" ;; *) $echo "$modename: unknown library version type \`$version_type'" 1>&2 $echo "Fatal configuration error. See the $PACKAGE docs for more information." 1>&2 exit $EXIT_FAILURE ;; 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 $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 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 # 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 "$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 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*) # 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*) # Do not include libc due to us having libc/libc_r. test "X$arg" = "X-lc" && continue ;; *) # 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. $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 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 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 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 # All the library-specific variables (install_libdir is set above). library_names= old_library= dlname= # 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 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 # 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 test -n "$soname_spec"; then eval soname=\"$soname_spec\" else soname="$realname" fi if test -z "$dlname"; then dlname=$soname fi lib="$output_objdir/$realname" for link do linknames="$linknames $link" done # Use standard objects if they are pic test -z "$pic_flag" && libobjs=`$echo "X$libobjs" | $SP2NL | $Xsed -e "$lo2o" | $NL2SP` # 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=: 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 if test -n "$export_symbols" && test -n "$include_expsyms"; then $run eval '$echo "X$include_expsyms" | $SP2NL >> "$export_symbols"' 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" 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" $show "${rm}r $gentop" $run ${rm}r "$gentop" $show "$mkdir $gentop" $run $mkdir "$gentop" status=$? if test "$status" -ne 0 && test ! -d "$gentop"; then exit $status fi generated="$generated $gentop" for xlib in $convenience; do # Extract the objects. case $xlib in [\\/]* | [A-Za-z]:[\\/]*) xabs="$xlib" ;; *) xabs=`pwd`"/$xlib" ;; esac xlib=`$echo "X$xlib" | $Xsed -e 's%^.*/%%'` xdir="$gentop/$xlib" $show "${rm}r $xdir" $run ${rm}r "$xdir" $show "$mkdir $xdir" $run $mkdir "$xdir" status=$? if test "$status" -ne 0 && test ! -d "$xdir"; then exit $status fi # We will extract separately just the conflicting names and we will no # longer touch any unique names. It is faster to leave these extract # automatically by $AR in one run. $show "(cd $xdir && $AR x $xabs)" $run eval "(cd \$xdir && $AR x \$xabs)" || exit $? if ($AR t "$xabs" | sort | sort -uc >/dev/null 2>&1); then : else $echo "$modename: warning: object name conflicts; renaming object files" 1>&2 $echo "$modename: warning: to ensure that they will not overwrite" 1>&2 $AR t "$xabs" | sort | uniq -cd | while read -r count name do i=1 while test "$i" -le "$count" do # Put our $i before any first dot (extension) # Never overwrite any file name_to="$name" while test "X$name_to" = "X$name" || test -f "$xdir/$name_to" do name_to=`$echo "X$name_to" | $Xsed -e "s/\([^.]*\)/\1-$i/"` done $show "(cd $xdir && $AR xN $i $xabs '$name' && $mv '$name' '$name_to')" $run eval "(cd \$xdir && $AR xN $i \$xabs '$name' && $mv '$name' '$name_to')" || exit $? i=`expr $i + 1` done done fi libobjs="$libobjs "`find $xdir -name \*.$objext -print -o -name \*.lo -print | $NL2SP` done 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 # 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 # 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 if test "X$skipped_export" != "X:" && len=`expr "X$test_cmds" : ".*"` && 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..." # 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 # 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/$save_output-${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" : ".*"` && 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/$save_output-${k}.$objext k=`expr $k + 1` output=$output_objdir/$save_output-${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 reloadale object files # after they are used. i=0 while test "$i" -lt "$k" do i=`expr $i + 1` delfiles="$delfiles $output_objdir/$save_output-${i}.$objext" done $echo "creating a temporary reloadable object file: $output" # 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" libobjs=$output # Restore the value of output. output=$save_output 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 # 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" || 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 $? 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 ;; obj) if test -n "$deplibs"; then $echo "$modename: warning: \`-l' and \`-L' are ignored for objects" 1>&2 fi if test -n "$dlfiles$dlprefiles" || test "$dlself" != no; then $echo "$modename: warning: \`-dlopen' is ignored for objects" 1>&2 fi 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"` ;; *) libobj= obj="$output" ;; esac # Delete the old objects. $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 wl= if test -n "$convenience"; then if test -n "$whole_archive_flag_spec"; then eval reload_conv_objs=\"\$reload_objs $whole_archive_flag_spec\" else gentop="$output_objdir/${obj}x" $show "${rm}r $gentop" $run ${rm}r "$gentop" $show "$mkdir $gentop" $run $mkdir "$gentop" status=$? if test "$status" -ne 0 && test ! -d "$gentop"; then exit $status fi generated="$generated $gentop" for xlib in $convenience; do # Extract the objects. case $xlib in [\\/]* | [A-Za-z]:[\\/]*) xabs="$xlib" ;; *) xabs=`pwd`"/$xlib" ;; esac xlib=`$echo "X$xlib" | $Xsed -e 's%^.*/%%'` xdir="$gentop/$xlib" $show "${rm}r $xdir" $run ${rm}r "$xdir" $show "$mkdir $xdir" $run $mkdir "$xdir" status=$? if test "$status" -ne 0 && test ! -d "$xdir"; then exit $status fi # We will extract separately just the conflicting names and we will no # longer touch any unique names. It is faster to leave these extract # automatically by $AR in one run. $show "(cd $xdir && $AR x $xabs)" $run eval "(cd \$xdir && $AR x \$xabs)" || exit $? if ($AR t "$xabs" | sort | sort -uc >/dev/null 2>&1); then : else $echo "$modename: warning: object name conflicts; renaming object files" 1>&2 $echo "$modename: warning: to ensure that they will not overwrite" 1>&2 $AR t "$xabs" | sort | uniq -cd | while read -r count name do i=1 while test "$i" -le "$count" do # Put our $i before any first dot (extension) # Never overwrite any file name_to="$name" while test "X$name_to" = "X$name" || test -f "$xdir/$name_to" do name_to=`$echo "X$name_to" | $Xsed -e "s/\([^.]*\)/\1-$i/"` done $show "(cd $xdir && $AR xN $i $xabs '$name' && $mv '$name' '$name_to')" $run eval "(cd \$xdir && $AR xN $i \$xabs '$name' && $mv '$name' '$name_to')" || exit $? i=`expr $i + 1` done done fi reload_conv_objs="$reload_objs "`find $xdir -name \*.$objext -print -o -name \*.lo -print | $NL2SP` done fi fi # 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 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" # 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 exit $EXIT_SUCCESS fi if test "$build_libtool_libs" != yes; then if test -n "$gentop"; then $show "${rm}r $gentop" $run ${rm}r $gentop 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 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 if test -n "$gentop"; then $show "${rm}r $gentop" $run ${rm}r $gentop fi exit $EXIT_SUCCESS ;; 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 if test -n "$release"; then $echo "$modename: warning: \`-release' is ignored for programs" 1>&2 fi 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 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 / -framework System /'` finalize_deplibs=`$echo "X $finalize_deplibs" | $Xsed -e 's/ -lc / -framework System /'` ;; esac 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 compile_command="$compile_command $compile_deplibs" finalize_command="$finalize_command $finalize_deplibs" 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 # 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 *" $libdir "*) ;; *) perm_rpath="$perm_rpath $libdir" ;; esac fi case $host in *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2*) case :$dllsearchpath: in *":$libdir:"*) ;; *) dllsearchpath="$dllsearchpath:$libdir";; 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 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 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 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 if test -n "$dlsyms"; then case $dlsyms in "") ;; *.c) # Discover the nlist of each of the dlfiles. nlist="$output_objdir/${outputname}.nm" $show "$rm $nlist ${nlist}S ${nlist}T" $run $rm "$nlist" "${nlist}S" "${nlist}T" # Parse the name list into a source file. $show "creating $output_objdir/$dlsyms" test -z "$run" && $echo > "$output_objdir/$dlsyms" "\ /* $dlsyms - symbol resolution table for \`$outputname' dlsym emulation. */ /* Generated by $PROGRAM - GNU $PACKAGE $VERSION$TIMESTAMP */ #ifdef __cplusplus extern \"C\" { #endif /* Prevent the only kind of declaration conflicts we can make. */ #define lt_preloaded_symbols some_other_symbol /* External symbol declarations for the compiler. */\ " if test "$dlself" = yes; then $show "generating symbol list for \`$output'" test -z "$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 arg in $progfiles; do $show "extracting global C symbols from \`$arg'" $run eval "$NM $arg | $global_symbol_pipe >> '$nlist'" done if test -n "$exclude_expsyms"; then $run eval '$EGREP -v " ($exclude_expsyms)$" "$nlist" > "$nlist"T' $run eval '$mv "$nlist"T "$nlist"' fi if test -n "$export_symbols_regex"; then $run eval '$EGREP -e "$export_symbols_regex" "$nlist" > "$nlist"T' $run eval '$mv "$nlist"T "$nlist"' fi # Prepare the list of exported symbols if test -z "$export_symbols"; then export_symbols="$output_objdir/$output.exp" $run $rm $export_symbols $run eval "${SED} -n -e '/^: @PROGRAM@$/d' -e 's/^.* \(.*\)$/\1/p' "'< "$nlist" > "$export_symbols"' else $run eval "${SED} -e 's/\([][.*^$]\)/\\\1/g' -e 's/^/ /' -e 's/$/$/'"' < "$export_symbols" > "$output_objdir/$output.exp"' $run eval 'grep -f "$output_objdir/$output.exp" < "$nlist" > "$nlist"T' $run eval 'mv "$nlist"T "$nlist"' fi fi 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 if test -z "$run"; then # 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/$dlsyms"' else $echo '/* NONE */' >> "$output_objdir/$dlsyms" fi $echo >> "$output_objdir/$dlsyms" "\ #undef lt_preloaded_symbols #if defined (__STDC__) && __STDC__ # define lt_ptr void * #else # define lt_ptr char * # define const #endif /* The mapping between symbol names and symbols. */ const struct { const char *name; lt_ptr address; } lt_preloaded_symbols[] = {\ " eval "$global_symbol_to_c_name_address" < "$nlist" >> "$output_objdir/$dlsyms" $echo >> "$output_objdir/$dlsyms" "\ {0, (lt_ptr) 0} }; /* This works around a problem in FreeBSD linker */ #ifdef FREEBSD_WORKAROUND static const void *lt_preloaded_setup() { return lt_preloaded_symbols; } #endif #ifdef __cplusplus } #endif\ " 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 # Now compile the dynamic symbol file. $show "(cd $output_objdir && $LTCC -c$no_builtin_flag$pic_flag_for_symtable \"$dlsyms\")" $run eval '(cd $output_objdir && $LTCC -c$no_builtin_flag$pic_flag_for_symtable "$dlsyms")' || exit $? # 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" # Transform the symbol file into the correct name. compile_command=`$echo "X$compile_command" | $Xsed -e "s%@SYMFILE@%$output_objdir/${outputname}S.${objext}%"` finalize_command=`$echo "X$finalize_command" | $Xsed -e "s%@SYMFILE@%$output_objdir/${outputname}S.${objext}%"` ;; *) $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. # 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 if test "$need_relink" = no || test "$build_libtool_libs" != yes; then # Replace the output file specification. compile_command=`$echo "X$compile_command" | $Xsed -e 's%@OUTPUT@%'"$output"'%g'` link_command="$compile_command$compile_rpath" # We have no uninstalled library dependencies, so finalize right now. $show "$link_command" $run eval "$link_command" status=$? # Delete the generated files. if test -n "$dlsyms"; then $show "$rm $output_objdir/${outputname}S.${objext}" $run $rm "$output_objdir/${outputname}S.${objext}" fi exit $status fi 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 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 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 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 "$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" $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" | $Xsed -e 's%@OUTPUT@%\$progdir/\$file%g'` 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 # Replace the output file specification. link_command=`$echo "X$link_command" | $Xsed -e 's%@OUTPUT@%'"$output_objdir/$outputname"'%g'` # Delete the old output files. $run $rm $output $output_objdir/$outputname $output_objdir/lt-$outputname $show "$link_command" $run eval "$link_command" || exit $? # Now create the wrapper script. $show "creating $output" # 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 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 # 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* ) cwrappersource=`$echo ${objdir}/lt-${output}.c` cwrapper=`$echo ${output}.exe` $rm $cwrappersource $cwrapper trap "$rm $cwrappersource $cwrapper; exit $EXIT_FAILURE" 1 2 15 cat > $cwrappersource <> $cwrappersource<<"EOF" #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 #ifndef DIR_SEPARATOR #define DIR_SEPARATOR '/' #endif #if defined (_WIN32) || defined (__MSDOS__) || defined (__DJGPP__) || \ defined (__OS2__) #define HAVE_DOS_BASED_FILE_SYSTEM #ifndef DIR_SEPARATOR_2 #define DIR_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 */ #define XMALLOC(type, num) ((type *) xmalloc ((num) * sizeof(type))) #define XFREE(stale) do { \ if (stale) { free ((void *) stale); stale = 0; } \ } while (0) const char *program_name = NULL; void * xmalloc (size_t num); char * xstrdup (const char *string); char * basename (const char *name); char * fnqualify(const char *path); char * strendzap(char *str, const char *pat); void lt_fatal (const char *message, ...); int main (int argc, char *argv[]) { char **newargz; int i; program_name = (char *) xstrdup ((char *) basename (argv[0])); newargz = XMALLOC(char *, argc+2); EOF cat >> $cwrappersource <> $cwrappersource <<"EOF" newargz[1] = fnqualify(argv[0]); /* 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; EOF cat >> $cwrappersource <> $cwrappersource <<"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 ; } char * basename (const char *name) { const char *base; #if defined (HAVE_DOS_BASED_FILE_SYSTEM) /* Skip over the disk name in MSDOS pathnames. */ if (isalpha (name[0]) && name[1] == ':') name += 2; #endif for (base = name; *name; name++) if (IS_DIR_SEPARATOR (*name)) base = name + 1; return (char *) base; } char * fnqualify(const char *path) { size_t size; char *p; char tmp[LT_PATHMAX + 1]; assert(path != NULL); /* Is it qualified already? */ #if defined (HAVE_DOS_BASED_FILE_SYSTEM) if (isalpha (path[0]) && path[1] == ':') return xstrdup (path); #endif if (IS_DIR_SEPARATOR (path[0])) return xstrdup (path); /* prepend the current directory */ /* doesn't handle '~' */ if (getcwd (tmp, LT_PATHMAX) == NULL) lt_fatal ("getcwd failed"); size = strlen(tmp) + 1 + strlen(path) + 1; /* +2 for '/' and '\0' */ p = XMALLOC(char, size); sprintf(p, "%s%c%s", tmp, DIR_SEPARATOR, path); return p; } 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 -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' # The HP-UX ksh and POSIX shell print the target directory to stdout # if CDPATH is set. if test \"\${CDPATH+set}\" = set; then CDPATH=:; export CDPATH; fi 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 "\ # Find the directory that this script lives in. thisdir=\`\$echo \"X\$file\" | \$Xsed -e 's%/[^/]*$%%'\` test \"x\$thisdir\" = \"x\$file\" && thisdir=. # 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%/[^/]*\$%%'\` # 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 file=\`\$echo \"X\$file\" | \$Xsed -e 's%^.*/%%'\` file=\`ls -ld \"\$thisdir/\$file\" | ${SED} -n 's/.*-> //p'\` done # Try to get the absolute directory name. absdir=\`cd \"\$thisdir\" && pwd\` test -n \"\$absdir\" && thisdir=\"\$absdir\" " if test "$fast_install" = yes; then $echo >> $output "\ 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 file=\"\$\$-\$program\" if test ! -d \"\$progdir\"; then $mkdir \"\$progdir\" else $rm \"\$progdir/\$file\" fi" $echo >> $output "\ # 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 $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 $echo >> $output "\ if test -f \"\$progdir/\$program\"; then" # 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\" # 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/::*\$//'\` export $shlibpath_var " fi # 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 $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+\"\$@\"} " ;; *) $echo >> $output "\ exec \$progdir/\$program \${1+\"\$@\"} " ;; esac $echo >> $output "\ \$echo \"\$0: cannot exec \$program \${1+\"\$@\"}\" 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 # See if we need to build an old-fashioned archive. for oldlib in $oldlibs; do 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 if test -n "$addlibs"; then gentop="$output_objdir/${outputname}x" $show "${rm}r $gentop" $run ${rm}r "$gentop" $show "$mkdir $gentop" $run $mkdir "$gentop" status=$? if test "$status" -ne 0 && test ! -d "$gentop"; then exit $status fi generated="$generated $gentop" # Add in members from convenience archives. for xlib in $addlibs; do # Extract the objects. case $xlib in [\\/]* | [A-Za-z]:[\\/]*) xabs="$xlib" ;; *) xabs=`pwd`"/$xlib" ;; esac xlib=`$echo "X$xlib" | $Xsed -e 's%^.*/%%'` xdir="$gentop/$xlib" $show "${rm}r $xdir" $run ${rm}r "$xdir" $show "$mkdir $xdir" $run $mkdir "$xdir" status=$? if test "$status" -ne 0 && test ! -d "$xdir"; then exit $status fi # We will extract separately just the conflicting names and we will no # longer touch any unique names. It is faster to leave these extract # automatically by $AR in one run. $show "(cd $xdir && $AR x $xabs)" $run eval "(cd \$xdir && $AR x \$xabs)" || exit $? if ($AR t "$xabs" | sort | sort -uc >/dev/null 2>&1); then : else $echo "$modename: warning: object name conflicts; renaming object files" 1>&2 $echo "$modename: warning: to ensure that they will not overwrite" 1>&2 $AR t "$xabs" | sort | uniq -cd | while read -r count name do i=1 while test "$i" -le "$count" do # Put our $i before any first dot (extension) # Never overwrite any file name_to="$name" while test "X$name_to" = "X$name" || test -f "$xdir/$name_to" do name_to=`$echo "X$name_to" | $Xsed -e "s/\([^.]*\)/\1-$i/"` done $show "(cd $xdir && $AR xN $i $xabs '$name' && $mv '$name' '$name_to')" $run eval "(cd \$xdir && $AR xN $i \$xabs '$name' && $mv '$name' '$name_to')" || exit $? i=`expr $i + 1` done done fi oldobjs="$oldobjs "`find $xdir -name \*.${objext} -print -o -name \*.lo -print | $NL2SP` done 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 eval cmds=\"$old_archive_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 # GNU ar 2.10+ was changed to match POSIX; thus no paths are # encoded into archives. This makes 'ar r' malfunction in # this piecewise linking case whenever conflicting object # names appear in distinct ar calls; check, warn and compensate. if (for obj in $save_oldobjs do $echo "X$obj" | $Xsed -e 's%^.*/%%' done | sort | sort -uc >/dev/null 2>&1); then : else $echo "$modename: warning: object name conflicts; overriding AR_FLAGS to 'cq'" 1>&2 $echo "$modename: warning: to ensure that POSIX-compatible ar will work" 1>&2 AR_FLAGS=cq fi # 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" : ".*"` && test "$len" -le "$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= 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 fi 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 if test -n "$generated"; then $show "${rm}r$generated" $run ${rm}r$generated fi # Now create the libtool archive. case $output in *.la) old_library= test "$build_old_libs" = yes && old_library="$libname.$libext" $show "creating $output" # 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" | $Xsed -e "$sed_quote_subst"` if test "$hardcode_automatic" = yes ; then relink_command= fi # 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. # The name that we can dlopen(3). dlname='$tdlname' # Names of this library. library_names='$library_names' # The name of the static archive. old_library='$old_library' # Libraries that this one depends upon. dependency_libs='$dependency_libs' # Version information for $libname. current=$current age=$age revision=$revision # Is this an already installed library? installed=$installed # Should we warn about portability when linking against -modules? shouldnotlink=$module # Files to dlopen/dlpreopen dlopen='$dlfiles' dlpreopen='$dlprefiles' # 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 # 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 ;; # 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" | $Xsed | grep shtool > /dev/null; then # Aesthetically quote it. arg=`$echo "X$nonopt" | $Xsed -e "$sed_quote_subst"` case $arg in *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*) arg="\"$arg\"" ;; esac install_prog="$arg " arg="$1" shift else install_prog= arg="$nonopt" fi # 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" # 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 $arg in -d) isdir=yes ;; -f) prev="-f" ;; -g) prev="-g" ;; -m) prev="-m" ;; -o) prev="-o" ;; -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 # 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 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) ;; *) $echo "$modename: \`$destdir' must be an absolute directory name" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE ;; 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" ;; *.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 "*) ;; *) current_libdirs="$current_libdirs $libdir" ;; esac else # Note the libdir as a future libdir. case "$future_libdirs " in *" $libdir "*) ;; *) future_libdirs="$future_libdirs $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" | $SED "s%@inst_prefix_dir@%-inst-prefix-dir $inst_prefix_dir%"` else relink_command=`$echo "$relink_command" | $SED "s%@inst_prefix_dir@%%"` fi $echo "$modename: warning: relinking \`$file'" 1>&2 $show "$relink_command" if $run eval "$relink_command"; then : else $echo "$modename: error: relink \`$file' with the above command before installing it" 1>&2 exit $EXIT_FAILURE fi fi # See the names of the shared library. set dummy $library_names if test -n "$2"; then realname="$2" shift shift srcname="$realname" test -n "$relink_command" && srcname="$realname"T # 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 if test "$#" -gt 0; then # Delete the old symlinks, and create new ones. for linkname do if test "$linkname" != "$realname"; then $show "(cd $destdir && $rm $linkname && $LN_S $realname $linkname)" $run eval "(cd $destdir && $rm $linkname && $LN_S $realname $linkname)" fi done fi # 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" || exit $? done IFS="$save_ifs" 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 $? # Maybe install the static library, too. test -n "$old_library" && staticlibs="$staticlibs $dir/$old_library" ;; *.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 # 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 # 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"` $show "$install_prog $staticobj $staticdest" $run eval "$install_prog \$staticobj \$staticdest" || exit $? fi exit $EXIT_SUCCESS ;; *) # 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 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 # 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= # To insure that "foo" is sourced, and not "foo.exe", # finese the cygwin/MSYS system by explicitly sourcing "foo." # which disallows the automatic-append-.exe behavior. case $build in *cygwin* | *mingw*) wrapperdot=${wrapper}. ;; *) wrapperdot=${wrapper} ;; esac # If there is no directory component, then add one. case $file in */* | *\\*) . ${wrapperdot} ;; *) . ./${wrapperdot} ;; esac # 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 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= # To insure that "foo" is sourced, and not "foo.exe", # finese the cygwin/MSYS system by explicitly sourcing "foo." # which disallows the automatic-append-.exe behavior. case $build in *cygwin* | *mingw*) wrapperdot=${wrapper}. ;; *) wrapperdot=${wrapper} ;; esac # If there is no directory component, then add one. case $file in */* | *\\*) . ${wrapperdot} ;; *) . ./${wrapperdot} ;; esac outputname= if test "$fast_install" = no && test -n "$relink_command"; then if test "$finalize" = yes && test -z "$run"; then tmpdir="/tmp" test -n "$TMPDIR" && tmpdir="$TMPDIR" tmpdir="$tmpdir/libtool-$$" save_umask=`umask` umask 0077 if $mkdir "$tmpdir"; then umask $save_umask else umask $save_umask $echo "$modename: error: cannot create temporary directory \`$tmpdir'" 1>&2 continue fi file=`$echo "X$file$stripped_ext" | $Xsed -e 's%^.*/%%'` outputname="$tmpdir/$file" # Replace the output file specification. relink_command=`$echo "X$relink_command" | $Xsed -e 's%@OUTPUT@%'"$outputname"'%g'` $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 # 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 anyways 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 $show "$install_prog$stripme $file $destfile" $run eval "$install_prog\$stripme \$file \$destfile" || exit $? test -n "$outputname" && ${rm}r "$tmpdir" ;; esac done for file in $staticlibs; do name=`$echo "X$file" | $Xsed -e 's%^.*/%%'` # Set up the ranlib parameters. oldlib="$destdir/$name" $show "$install_prog $file $oldlib" $run eval "$install_prog \$file \$oldlib" || exit $? if test -n "$stripme" && test -n "$old_striplib"; then $show "$old_striplib $oldlib" $run eval "$old_striplib $oldlib" || exit $? fi # 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 if test -n "$future_libdirs"; then $echo "$modename: warning: remember to run \`$progname --finish$future_libdirs'" 1>&2 fi 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 ;; # libtool finish mode finish) modename="$modename: finish" 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. 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 if test -n "$finish_eval"; then # Do the single finish_eval. eval cmds=\"$finish_eval\" $run eval "$cmds" || admincmds="$admincmds $cmds" fi done fi # Exit here if they wanted silent mode. test "$show" = : && exit $EXIT_SUCCESS $echo "----------------------------------------------------------------------" $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\" $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 "----------------------------------------------------------------------" exit $EXIT_SUCCESS ;; # libtool execute mode execute) modename="$modename: execute" # 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 # 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 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 # Read the libtool library. dlname= library_names= # If there is no directory component, then add one. case $file in */* | *\\*) . $file ;; *) . ./$file ;; esac # 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 dir=`$echo "X$file" | $Xsed -e 's%/[^/]*$%%'` test "X$dir" = "X$file" && dir=. if test -f "$dir/$objdir/$dlname"; then dir="$dir/$objdir" else $echo "$modename: cannot find \`$dlname' in \`$dir' or \`$dir/$objdir'" 1>&2 exit $EXIT_FAILURE fi ;; *.lo) # Just add the directory containing the .lo file. dir=`$echo "X$file" | $Xsed -e 's%/[^/]*$%%'` test "X$dir" = "X$file" && dir=. ;; *) $echo "$modename: warning \`-dlopen' is ignored for non-libtool libraries and objects" 1>&2 continue ;; esac # Get the absolute pathname. absdir=`cd "$dir" && pwd` test -n "$absdir" && dir="$absdir" # 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 # This variable tells wrapper scripts just to set shlibpath_var # rather than running their programs. libtool_execute_magic="$magic" # 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 # 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 if test -z "$run"; then if test -n "$shlibpath_var"; then # Export the shlibpath_var. eval "export $shlibpath_var" fi # Restore saved environment variables if test "${save_LC_ALL+set}" = set; then LC_ALL="$save_LC_ALL"; export LC_ALL fi if test "${save_LANG+set}" = set; then LANG="$save_LANG"; export LANG fi # 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 ;; # libtool clean and uninstall mode clean | uninstall) modename="$modename: $mode" rm="$nonopt" files= rmforce= exit_status=0 # This variable tells wrapper scripts just to set variables rather # than running their programs. libtool_install_magic="$magic" for arg do case $arg in -f) rm="$rm $arg"; rmforce=yes ;; -*) rm="$rm $arg" ;; *) files="$files $arg" ;; esac done 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 dir=`$echo "X$file" | $Xsed -e 's%/[^/]*$%%'` if test "X$dir" = "X$file"; then dir=. objdir="$origobjdir" else objdir="$dir/$origobjdir" fi name=`$echo "X$file" | $Xsed -e 's%^.*/%%'` test "$mode" = uninstall && objdir="$dir" # Remember objdir for removal later, being careful to avoid duplicates if test "$mode" = clean; then case " $rmdirs " in *" $objdir "*) ;; *) rmdirs="$rmdirs $objdir" ;; esac 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 : elif test -d "$file"; then exit_status=1 continue elif test "$rmforce" = yes; then continue fi rmfiles="$file" case $name in *.la) # Possibly a libtool archive, so verify it. 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 rmfiles="$rmfiles $objdir/$n" done test -n "$old_library" && rmfiles="$rmfiles $objdir/$old_library" test "$mode" = clean && rmfiles="$rmfiles $objdir/$name $objdir/${name}i" if test "$mode" = uninstall; then if test -n "$library_names"; then # Do each command in the postuninstall commands. 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. 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. fi fi ;; *.lo) # Possibly a libtool object, so verify it. if (${SED} -e '2q' $file | grep "^# Generated by .*$PACKAGE") >/dev/null 2>&1; then # Read the .lo file . $dir/$name # Add PIC object to the list of files to remove. 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 rmfiles="$rmfiles $dir/$non_pic_object" fi fi ;; *) if test "$mode" = clean ; then noexename=$name case $file in *.exe) 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 (${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 rmfiles="$rmfiles $objdir/$name $objdir/${name}S.${objext}" if test "$fast_install" = yes && test -n "$relink_command"; then rmfiles="$rmfiles $objdir/lt-$name" fi if test "X$noexename" != "X$name" ; then rmfiles="$rmfiles $objdir/lt-${noexename}.c" fi fi fi ;; esac $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 $show "rmdir $dir" $run rmdir $dir >/dev/null 2>&1 fi done exit $exit_status ;; "") $echo "$modename: you must specify a MODE" 1>&2 $echo "$generic_help" 1>&2 exit $EXIT_FAILURE ;; esac 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 exit $EXIT_FAILURE fi # 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 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 $EXIT_SUCCESS # The TAGs below are defined such that we never get into a situation # in which we disable both kinds of libraries. Given conflicting # choices, we go for a static library, that is the most portable, # since we can't tell whether shared libraries were disabled because # the user asked for that or because the platform doesn't support # them. This is particularly important on AIX, because we don't # support having both static and shared libraries enabled at the same # time on that platform, so we default to a shared-only configuration. # If a disable-shared tag is given, we'll fallback to a static-only # 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 # ### 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` # ### END LIBTOOL TAG CONFIG: disable-static # Local Variables: # mode:shell-script # sh-indentation:2 # End: rapache-1.2.8/libapreq2/missing0000755000175100017510000002403612706745114015747 0ustar ondrejondrej#! /bin/sh # Common stub for a few missing GNU programs while installing. # Copyright (C) 1996, 1997, 1999, 2000, 2002 Free Software Foundation, Inc. # Originally by Fran,cois Pinard , 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, 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. if test $# -eq 0; then echo 1>&2 "Try \`$0 --help' for more information" exit 1 fi run=: # In the cases where this matters, `missing' is being run in the # srcdir already. if test -f configure.ac; then configure_ac=configure.ac else configure_ac=configure.in fi case "$1" in --run) # Try to run requested program, and just exit if it succeeds. run= shift "$@" && exit 0 ;; esac # If it does not exist, or fails to run (possibly an outdated version), # try to emulate it. case "$1" in -h|--h|--he|--hel|--help) echo "\ $0 [OPTION]... PROGRAM [ARGUMENT]... Handle \`PROGRAM [ARGUMENT]...' for when PROGRAM is missing, or return an error status if there is no known handling for PROGRAM. Options: -h, --help display this help and exit -v, --version output version information and exit --run try to run the given command, and emulate it if it fails Supported PROGRAM values: aclocal touch file \`aclocal.m4' autoconf touch file \`configure' autoheader touch file \`config.h.in' automake touch all \`Makefile.in' files bison create \`y.tab.[ch]', if possible, from existing .[ch] flex create \`lex.yy.c', if possible, from existing .c help2man touch the output file lex create \`lex.yy.c', if possible, from existing .c makeinfo touch the output file tar try tar, gnutar, gtar, then tar without non-portable flags yacc create \`y.tab.[ch]', if possible, from existing .[ch]" ;; -v|--v|--ve|--ver|--vers|--versi|--versio|--version) echo "missing 0.4 - GNU automake" ;; -*) echo 1>&2 "$0: Unknown \`$1' option" echo 1>&2 "Try \`$0 --help' for more information" exit 1 ;; aclocal*) if test -z "$run" && ($1 --version) > /dev/null 2>&1; then # We have it, but it failed. exit 1 fi echo 1>&2 "\ WARNING: \`$1' is missing on your system. You should only need it if you modified \`acinclude.m4' or \`${configure_ac}'. You might want to install the \`Automake' and \`Perl' packages. Grab them from any GNU archive site." touch aclocal.m4 ;; autoconf) if test -z "$run" && ($1 --version) > /dev/null 2>&1; then # We have it, but it failed. exit 1 fi echo 1>&2 "\ WARNING: \`$1' is missing on your system. You should only need it if you modified \`${configure_ac}'. You might want to install the \`Autoconf' and \`GNU m4' packages. Grab them from any GNU archive site." touch configure ;; autoheader) if test -z "$run" && ($1 --version) > /dev/null 2>&1; then # We have it, but it failed. exit 1 fi echo 1>&2 "\ WARNING: \`$1' is missing on your system. You should only need it if you modified \`acconfig.h' or \`${configure_ac}'. You might want to install the \`Autoconf' and \`GNU m4' packages. Grab them from any GNU archive site." files=`sed -n 's/^[ ]*A[CM]_CONFIG_HEADER(\([^)]*\)).*/\1/p' ${configure_ac}` test -z "$files" && files="config.h" touch_files= for f in $files; do case "$f" in *:*) touch_files="$touch_files "`echo "$f" | sed -e 's/^[^:]*://' -e 's/:.*//'`;; *) touch_files="$touch_files $f.in";; esac done touch $touch_files ;; automake*) if test -z "$run" && ($1 --version) > /dev/null 2>&1; then # We have it, but it failed. exit 1 fi echo 1>&2 "\ WARNING: \`$1' is missing on your system. You should only need it if you modified \`Makefile.am', \`acinclude.m4' or \`${configure_ac}'. You might want to install the \`Automake' and \`Perl' packages. Grab them from any GNU archive site." find . -type f -name Makefile.am -print | sed 's/\.am$/.in/' | while read f; do touch "$f"; done ;; autom4te) if test -z "$run" && ($1 --version) > /dev/null 2>&1; then # We have it, but it failed. exit 1 fi echo 1>&2 "\ WARNING: \`$1' is needed, and you do not seem to have it handy on your system. You might have modified some files without having the proper tools for further handling them. You can get \`$1Help2man' as part of \`Autoconf' from any GNU archive site." file=`echo "$*" | sed -n 's/.*--output[ =]*\([^ ]*\).*/\1/p'` test -z "$file" && file=`echo "$*" | sed -n 's/.*-o[ ]*\([^ ]*\).*/\1/p'` if test -f "$file"; then touch $file else test -z "$file" || exec >$file echo "#! /bin/sh" echo "# Created by GNU Automake missing as a replacement of" echo "# $ $@" echo "exit 0" chmod +x $file exit 1 fi ;; bison|yacc) echo 1>&2 "\ WARNING: \`$1' is missing on your system. You should only need it if you modified a \`.y' file. You may need the \`Bison' package in order for those modifications to take effect. You can get \`Bison' from any GNU archive site." rm -f y.tab.c y.tab.h if [ $# -ne 1 ]; then eval LASTARG="\${$#}" case "$LASTARG" in *.y) SRCFILE=`echo "$LASTARG" | sed 's/y$/c/'` if [ -f "$SRCFILE" ]; then cp "$SRCFILE" y.tab.c fi SRCFILE=`echo "$LASTARG" | sed 's/y$/h/'` if [ -f "$SRCFILE" ]; then cp "$SRCFILE" y.tab.h fi ;; esac fi if [ ! -f y.tab.h ]; then echo >y.tab.h fi if [ ! -f y.tab.c ]; then echo 'main() { return 0; }' >y.tab.c fi ;; lex|flex) echo 1>&2 "\ WARNING: \`$1' is missing on your system. You should only need it if you modified a \`.l' file. You may need the \`Flex' package in order for those modifications to take effect. You can get \`Flex' from any GNU archive site." rm -f lex.yy.c if [ $# -ne 1 ]; then eval LASTARG="\${$#}" case "$LASTARG" in *.l) SRCFILE=`echo "$LASTARG" | sed 's/l$/c/'` if [ -f "$SRCFILE" ]; then cp "$SRCFILE" lex.yy.c fi ;; esac fi if [ ! -f lex.yy.c ]; then echo 'main() { return 0; }' >lex.yy.c fi ;; help2man) if test -z "$run" && ($1 --version) > /dev/null 2>&1; then # We have it, but it failed. exit 1 fi echo 1>&2 "\ WARNING: \`$1' is missing on your system. You should only need it if you modified a dependency of a manual page. You may need the \`Help2man' package in order for those modifications to take effect. You can get \`Help2man' from any GNU archive site." file=`echo "$*" | sed -n 's/.*-o \([^ ]*\).*/\1/p'` if test -z "$file"; then file=`echo "$*" | sed -n 's/.*--output=\([^ ]*\).*/\1/p'` fi if [ -f "$file" ]; then touch $file else test -z "$file" || exec >$file echo ".ab help2man is required to generate this page" exit 1 fi ;; makeinfo) if test -z "$run" && (makeinfo --version) > /dev/null 2>&1; then # We have makeinfo, but it failed. exit 1 fi echo 1>&2 "\ WARNING: \`$1' is missing on your system. You should only need it if you modified a \`.texi' or \`.texinfo' file, or any other file indirectly affecting the aspect of the manual. The spurious call might also be the consequence of using a buggy \`make' (AIX, DU, IRIX). You might want to install the \`Texinfo' package or the \`GNU make' package. Grab either from any GNU archive site." file=`echo "$*" | sed -n 's/.*-o \([^ ]*\).*/\1/p'` if test -z "$file"; then file=`echo "$*" | sed 's/.* \([^ ]*\) *$/\1/'` file=`sed -n '/^@setfilename/ { s/.* \([^ ]*\) *$/\1/; p; q; }' $file` fi touch $file ;; tar) shift if test -n "$run"; then echo 1>&2 "ERROR: \`tar' requires --run" exit 1 fi # We have already tried tar in the generic part. # Look for gnutar/gtar before invocation to avoid ugly error # messages. if (gnutar --version > /dev/null 2>&1); then gnutar "$@" && exit 0 fi if (gtar --version > /dev/null 2>&1); then gtar "$@" && exit 0 fi firstarg="$1" if shift; then case "$firstarg" in *o*) firstarg=`echo "$firstarg" | sed s/o//` tar "$firstarg" "$@" && exit 0 ;; esac case "$firstarg" in *h*) firstarg=`echo "$firstarg" | sed s/h//` tar "$firstarg" "$@" && exit 0 ;; esac fi echo 1>&2 "\ WARNING: I can't seem to be able to run \`tar' with the given arguments. You may want to install GNU tar or Free paxutils, or check the command line arguments." exit 1 ;; *) echo 1>&2 "\ WARNING: \`$1' is needed, and you do not seem to have it handy on your system. You might have modified some files without having the proper tools for further handling them. Check the \`README' file, it often tells you about the needed prerequirements for installing this package. You may also peek at any GNU archive site, in case some other package would contain this missing \`$1' program." exit 1 ;; esac exit 0 rapache-1.2.8/libapreq2/mkinstalldirs0000755000175100017510000000341112706745114017150 0ustar ondrejondrej#! /bin/sh # mkinstalldirs --- make directory hierarchy # Author: Noah Friedman # Created: 1993-05-16 # Public domain errstatus=0 dirmode="" usage="\ Usage: mkinstalldirs [-h] [--help] [-m mode] dir ..." # process command line arguments while test $# -gt 0 ; do case "${1}" in -h | --help | --h* ) # -h for help echo "${usage}" 1>&2; exit 0 ;; -m ) # -m PERM arg shift test $# -eq 0 && { echo "${usage}" 1>&2; exit 1; } dirmode="${1}" shift ;; -- ) shift; break ;; # stop option processing -* ) echo "${usage}" 1>&2; exit 1 ;; # unknown option * ) break ;; # first non-opt arg esac done for file do if test -d "$file"; then shift else break fi done case $# in 0) exit 0 ;; esac case $dirmode in '') if mkdir -p -- . 2>/dev/null; then echo "mkdir -p -- $*" exec mkdir -p -- "$@" fi ;; *) if mkdir -m "$dirmode" -p -- . 2>/dev/null; then echo "mkdir -m $dirmode -p -- $*" exec mkdir -m "$dirmode" -p -- "$@" fi ;; esac for file do set fnord `echo ":$file" | sed -ne 's/^:\//#/;s/^://;s/\// /g;s/^#/\//;p'` shift pathcomp= for d do pathcomp="$pathcomp$d" case "$pathcomp" in -* ) pathcomp=./$pathcomp ;; esac if test ! -d "$pathcomp"; then echo "mkdir $pathcomp" mkdir "$pathcomp" || lasterr=$? if test ! -d "$pathcomp"; then errstatus=$lasterr else if test ! -z "$dirmode"; then echo "chmod $dirmode $pathcomp" lasterr="" chmod "$dirmode" "$pathcomp" || lasterr=$? if test ! -z "$lasterr"; then errstatus=$lasterr fi fi fi fi pathcomp="$pathcomp/" done done exit $errstatus # Local Variables: # mode: shell-script # sh-indentation: 3 # End: # mkinstalldirs ends here rapache-1.2.8/libapreq2/module/0000755000175100017510000000000012706745114015630 5ustar ondrejondrejrapache-1.2.8/libapreq2/module/Makefile.am0000644000175100017510000000153712706745114017672 0ustar ondrejondrejAM_CPPFLAGS = @APR_INCLUDES@ SUBDIRS = apache2 TEST_CONFIG_SCRIPT = package Apache::TestMM; filter_args(); generate_script("t/TEST") EXTRA_DIST = t apache noinst_PROGRAMS = test_cgi test_cgi_LDFLAGS = `@APREQ_CONFIG@ --link-libtool --libs` @APR_LTFLAGS@ run_tests : t/TEST -cp -f test_cgi t/cgi-bin -cp -Rp .libs t MAKE=$(MAKE) @PERL@ t/TEST t/TEST : Makefile.am t/TEST.PL @PERL@ -MApache::TestMM -e '$(TEST_CONFIG_SCRIPT)' -- -apxs @APACHE2_APXS@ test :: all check run_tests test_clean : cmodules_clean -MAKE=$(MAKE) @PERL@ t/TEST -clean -rm -rf t/htdocs t/logs t/modules t/TEST t/core t/core.* t/cgi-bin/test_cgi t/cgi-bin/.libs t/.libs t/conf/extra.conf t/conf/ssl/ca t/conf/ssl/httpd-passphrase.pl cmodules_clean: -cd c-modules && $(MAKE) clean -rm c-modules/Makefile c-modules/*/Makefile c-modules/apache_httpd_test.h clean-local: test_clean rapache-1.2.8/libapreq2/module/Makefile.in0000644000175100017510000003320412706745114017677 0ustar ondrejondrej# Makefile.in generated by automake 1.6.3 from Makefile.am. # @configure_input@ # Copyright 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002 # 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@ SHELL = @SHELL@ srcdir = @srcdir@ top_srcdir = @top_srcdir@ VPATH = @srcdir@ prefix = @prefix@ exec_prefix = @exec_prefix@ bindir = @bindir@ sbindir = @sbindir@ libexecdir = @libexecdir@ datadir = @datadir@ sysconfdir = @sysconfdir@ sharedstatedir = @sharedstatedir@ localstatedir = @localstatedir@ libdir = @libdir@ infodir = @infodir@ mandir = @mandir@ includedir = @includedir@ oldincludedir = /usr/include pkgdatadir = $(datadir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ top_builddir = .. ACLOCAL = @ACLOCAL@ AUTOCONF = @AUTOCONF@ AUTOMAKE = @AUTOMAKE@ AUTOHEADER = @AUTOHEADER@ am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd INSTALL = @INSTALL@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_DATA = @INSTALL_DATA@ install_sh_DATA = $(install_sh) -c -m 644 install_sh_PROGRAM = $(install_sh) -c install_sh_SCRIPT = $(install_sh) -c INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_HEADER = $(INSTALL_DATA) transform = @program_transform_name@ NORMAL_INSTALL = : PRE_INSTALL = : POST_INSTALL = : NORMAL_UNINSTALL = : PRE_UNINSTALL = : POST_UNINSTALL = : host_alias = @host_alias@ host_triplet = @host@ EXEEXT = @EXEEXT@ OBJEXT = @OBJEXT@ PATH_SEPARATOR = @PATH_SEPARATOR@ AMTAR = @AMTAR@ APACHE1_APXS = @APACHE1_APXS@ APACHE2_APXS = @APACHE2_APXS@ APACHE2_HTTPD = @APACHE2_HTTPD@ APACHE2_INCLUDES = @APACHE2_INCLUDES@ APACHE2_SRC = @APACHE2_SRC@ APREQ_CONFIG = @APREQ_CONFIG@ APREQ_DOTTED_VERSION = @APREQ_DOTTED_VERSION@ APREQ_LIBNAME = @APREQ_LIBNAME@ APREQ_LIBTOOL_VERSION = @APREQ_LIBTOOL_VERSION@ APREQ_MAJOR_VERSION = @APREQ_MAJOR_VERSION@ APR_CONFIG = @APR_CONFIG@ APR_INCLUDES = @APR_INCLUDES@ APR_LA = @APR_LA@ APR_LDFLAGS = @APR_LDFLAGS@ APR_LIBS = @APR_LIBS@ APR_LTFLAGS = @APR_LTFLAGS@ APU_CONFIG = @APU_CONFIG@ APU_LA = @APU_LA@ AR = @AR@ AS = @AS@ AWK = @AWK@ CC = @CC@ CXX = @CXX@ CXXCPP = @CXXCPP@ DEPDIR = @DEPDIR@ DLLTOOL = @DLLTOOL@ ECHO = @ECHO@ EGREP = @EGREP@ F77 = @F77@ GCJ = @GCJ@ GCJFLAGS = @GCJFLAGS@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ LIBTOOL = @LIBTOOL@ LN_S = @LN_S@ MAINT = @MAINT@ OBJDUMP = @OBJDUMP@ PACKAGE = @PACKAGE@ PERL = @PERL@ PERL_OPTS = @PERL_OPTS@ RANLIB = @RANLIB@ RC = @RC@ STRIP = @STRIP@ VERSION = @VERSION@ am__include = @am__include@ am__quote = @am__quote@ install_sh = @install_sh@ AM_CPPFLAGS = @APR_INCLUDES@ SUBDIRS = apache2 TEST_CONFIG_SCRIPT = package Apache::TestMM; filter_args(); generate_script("t/TEST") EXTRA_DIST = t apache noinst_PROGRAMS = test_cgi test_cgi_LDFLAGS = `@APREQ_CONFIG@ --link-libtool --libs` @APR_LTFLAGS@ subdir = module mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs CONFIG_HEADER = $(top_builddir)/include/apreq_config.h CONFIG_CLEAN_FILES = noinst_PROGRAMS = test_cgi$(EXEEXT) PROGRAMS = $(noinst_PROGRAMS) test_cgi_SOURCES = test_cgi.c test_cgi_OBJECTS = test_cgi.$(OBJEXT) test_cgi_LDADD = $(LDADD) test_cgi_DEPENDENCIES = DEFS = @DEFS@ DEFAULT_INCLUDES = -I. -I$(srcdir) -I$(top_builddir)/include CPPFLAGS = @CPPFLAGS@ LDFLAGS = @LDFLAGS@ LIBS = @LIBS@ depcomp = $(SHELL) $(top_srcdir)/depcomp am__depfiles_maybe = depfiles @AMDEP_TRUE@DEP_FILES = ./$(DEPDIR)/test_cgi.Po COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) LTCOMPILE = $(LIBTOOL) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) \ $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) CCLD = $(CC) LINK = $(LIBTOOL) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ $(AM_LDFLAGS) $(LDFLAGS) -o $@ CFLAGS = @CFLAGS@ DIST_SOURCES = test_cgi.c RECURSIVE_TARGETS = info-recursive dvi-recursive install-info-recursive \ uninstall-info-recursive all-recursive install-data-recursive \ install-exec-recursive installdirs-recursive install-recursive \ uninstall-recursive check-recursive installcheck-recursive DIST_COMMON = Makefile.am Makefile.in DIST_SUBDIRS = $(SUBDIRS) SOURCES = test_cgi.c all: all-recursive .SUFFIXES: .SUFFIXES: .c .lo .o .obj $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ Makefile.am $(top_srcdir)/configure.ac $(ACLOCAL_M4) cd $(top_srcdir) && \ $(AUTOMAKE) --gnu module/Makefile Makefile: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.in $(top_builddir)/config.status cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe) clean-noinstPROGRAMS: @list='$(noinst_PROGRAMS)'; for p in $$list; do \ f=`echo $$p|sed 's/$(EXEEXT)$$//'`; \ echo " rm -f $$p $$f"; \ rm -f $$p $$f ; \ done test_cgi$(EXEEXT): $(test_cgi_OBJECTS) $(test_cgi_DEPENDENCIES) @rm -f test_cgi$(EXEEXT) $(LINK) $(test_cgi_LDFLAGS) $(test_cgi_OBJECTS) $(test_cgi_LDADD) $(LIBS) mostlyclean-compile: -rm -f *.$(OBJEXT) core *.core distclean-compile: -rm -f *.tab.c @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/test_cgi.Po@am__quote@ distclean-depend: -rm -rf ./$(DEPDIR) .c.o: @AMDEP_TRUE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@ depfile='$(DEPDIR)/$*.Po' tmpdepfile='$(DEPDIR)/$*.TPo' @AMDEPBACKSLASH@ @AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ $(COMPILE) -c `test -f '$<' || echo '$(srcdir)/'`$< .c.obj: @AMDEP_TRUE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@ depfile='$(DEPDIR)/$*.Po' tmpdepfile='$(DEPDIR)/$*.TPo' @AMDEPBACKSLASH@ @AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ $(COMPILE) -c `cygpath -w $<` .c.lo: @AMDEP_TRUE@ source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@ depfile='$(DEPDIR)/$*.Plo' tmpdepfile='$(DEPDIR)/$*.TPlo' @AMDEPBACKSLASH@ @AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ $(LTCOMPILE) -c -o $@ `test -f '$<' || echo '$(srcdir)/'`$< CCDEPMODE = @CCDEPMODE@ mostlyclean-libtool: -rm -f *.lo clean-libtool: -rm -rf .libs _libs distclean-libtool: -rm -f libtool uninstall-info-am: # 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): @set fnord $$MAKEFLAGS; amf=$$2; \ dot_seen=no; \ target=`echo $@ | sed s/-recursive//`; \ list='$(SUBDIRS)'; for subdir in $$list; do \ echo "Making $$target in $$subdir"; \ if test "$$subdir" = "."; then \ dot_seen=yes; \ local_target="$$target-am"; \ else \ local_target="$$target"; \ fi; \ (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \ || case "$$amf" in *=*) exit 1;; *k*) fail=yes;; *) exit 1;; esac; \ done; \ if test "$$dot_seen" = "no"; then \ $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \ fi; test -z "$$fail" mostlyclean-recursive clean-recursive distclean-recursive \ maintainer-clean-recursive: @set fnord $$MAKEFLAGS; amf=$$2; \ dot_seen=no; \ case "$@" in \ distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \ *) list='$(SUBDIRS)' ;; \ esac; \ rev=''; for subdir in $$list; do \ if test "$$subdir" = "."; then :; else \ rev="$$subdir $$rev"; \ fi; \ done; \ rev="$$rev ."; \ target=`echo $@ | sed s/-recursive//`; \ for subdir in $$rev; do \ echo "Making $$target in $$subdir"; \ if test "$$subdir" = "."; then \ local_target="$$target-am"; \ else \ local_target="$$target"; \ fi; \ (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \ || case "$$amf" in *=*) exit 1;; *k*) fail=yes;; *) exit 1;; esac; \ done && test -z "$$fail" tags-recursive: list='$(SUBDIRS)'; for subdir in $$list; do \ test "$$subdir" = . || (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) tags); \ done ETAGS = etags ETAGSFLAGS = tags: TAGS 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; } \ END { for (i in files) print i; }'`; \ mkid -fID $$unique TAGS: tags-recursive $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ $(TAGS_FILES) $(LISP) tags=; \ here=`pwd`; \ list='$(SUBDIRS)'; for subdir in $$list; do \ if test "$$subdir" = .; then :; else \ test -f $$subdir/TAGS && tags="$$tags -i $$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; } \ END { for (i in files) print i; }'`; \ test -z "$(ETAGS_ARGS)$$tags$$unique" \ || $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ $$tags $$unique GTAGS: here=`$(am__cd) $(top_builddir) && pwd` \ && cd $(top_srcdir) \ && gtags -i $(GTAGS_ARGS) $$here distclean-tags: -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) top_distdir = .. distdir = $(top_distdir)/$(PACKAGE)-$(VERSION) distdir: $(DISTFILES) @list='$(DISTFILES)'; for file in $$list; do \ if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ dir=`echo "$$file" | sed -e 's,/[^/]*$$,,'`; \ if test "$$dir" != "$$file" && test "$$dir" != "."; then \ dir="/$$dir"; \ $(mkinstalldirs) "$(distdir)$$dir"; \ else \ dir=''; \ fi; \ if test -d $$d/$$file; then \ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \ fi; \ cp -pR $$d/$$file $(distdir)$$dir || exit 1; \ else \ test -f $(distdir)/$$file \ || cp -p $$d/$$file $(distdir)/$$file \ || exit 1; \ fi; \ done list='$(SUBDIRS)'; for subdir in $$list; do \ if test "$$subdir" = .; then :; else \ test -d $(distdir)/$$subdir \ || mkdir $(distdir)/$$subdir \ || exit 1; \ (cd $$subdir && \ $(MAKE) $(AM_MAKEFLAGS) \ top_distdir="$(top_distdir)" \ distdir=../$(distdir)/$$subdir \ distdir) \ || exit 1; \ fi; \ done check-am: all-am check: check-recursive all-am: Makefile $(PROGRAMS) 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_STRIP_FLAG=-s \ `test -z '$(STRIP)' || \ echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install mostlyclean-generic: clean-generic: distclean-generic: -rm -f Makefile $(CONFIG_CLEAN_FILES) maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." clean: clean-recursive clean-am: clean-generic clean-libtool clean-local clean-noinstPROGRAMS \ mostlyclean-am distclean: distclean-recursive distclean-am: clean-am distclean-compile distclean-depend \ distclean-generic distclean-libtool distclean-tags dvi: dvi-recursive dvi-am: info: info-recursive info-am: install-data-am: install-exec-am: install-info: install-info-recursive install-man: installcheck-am: maintainer-clean: maintainer-clean-recursive maintainer-clean-am: distclean-am maintainer-clean-generic mostlyclean: mostlyclean-recursive mostlyclean-am: mostlyclean-compile mostlyclean-generic \ mostlyclean-libtool uninstall-am: uninstall-info-am uninstall-info: uninstall-info-recursive .PHONY: $(RECURSIVE_TARGETS) GTAGS all all-am check check-am clean \ clean-generic clean-libtool clean-local clean-noinstPROGRAMS \ clean-recursive distclean distclean-compile distclean-depend \ distclean-generic distclean-libtool distclean-recursive \ distclean-tags distdir dvi dvi-am dvi-recursive info info-am \ info-recursive install install-am install-data install-data-am \ install-data-recursive install-exec install-exec-am \ install-exec-recursive install-info install-info-am \ install-info-recursive install-man install-recursive \ install-strip installcheck installcheck-am installdirs \ installdirs-am installdirs-recursive maintainer-clean \ maintainer-clean-generic maintainer-clean-recursive mostlyclean \ mostlyclean-compile mostlyclean-generic mostlyclean-libtool \ mostlyclean-recursive tags tags-recursive uninstall \ uninstall-am uninstall-info-am uninstall-info-recursive \ uninstall-recursive run_tests : t/TEST -cp -f test_cgi t/cgi-bin -cp -Rp .libs t MAKE=$(MAKE) @PERL@ t/TEST t/TEST : Makefile.am t/TEST.PL @PERL@ -MApache::TestMM -e '$(TEST_CONFIG_SCRIPT)' -- -apxs @APACHE2_APXS@ test :: all check run_tests test_clean : cmodules_clean -MAKE=$(MAKE) @PERL@ t/TEST -clean -rm -rf t/htdocs t/logs t/modules t/TEST t/core t/core.* t/cgi-bin/test_cgi t/cgi-bin/.libs t/.libs t/conf/extra.conf t/conf/ssl/ca t/conf/ssl/httpd-passphrase.pl cmodules_clean: -cd c-modules && $(MAKE) clean -rm c-modules/Makefile c-modules/*/Makefile c-modules/apache_httpd_test.h clean-local: test_clean # 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: rapache-1.2.8/libapreq2/module/apache/0000755000175100017510000000000012706745114017051 5ustar ondrejondrejrapache-1.2.8/libapreq2/module/apache/.deps/0000755000175100017510000000000012706745114020062 5ustar ondrejondrejrapache-1.2.8/libapreq2/module/apache/.deps/command.Plo0000644000175100017510000000001012706745114022143 0ustar ondrejondrej# dummy rapache-1.2.8/libapreq2/module/apache/.deps/handle.Plo0000644000175100017510000000001012706745114021760 0ustar ondrejondrej# dummy rapache-1.2.8/libapreq2/module/apache/Makefile.am0000644000175100017510000000333612706745114021112 0ustar ondrejondrejAM_CPPFLAGS = $(APACHE1_INCLUDES) @APR_INCLUDES@ TEST_CONFIG_SCRIPT = package Apache::TestMM; filter_args(); generate_script("t/TEST") pkgcfgdir = `@APACHE1_APXS@ -q SYSCONFDIR` pkglibdir = `@APACHE1_APXS@ -q LIBEXECDIR` pkgincludedir = `@APACHE1_APXS@ -q INCLUDEDIR`/@APREQ_LIBNAME@ if MAINTAINER_MODE APACHE1_INCLUDES = -isystem `@APACHE1_APXS@ -q INCLUDEDIR` else APACHE1_INCLUDES = -I`@APACHE1_APXS@ -q INCLUDEDIR` endif mod_apreq2_la_LDFLAGS = -export-dynamic -module -avoid-version \ `@APREQ_CONFIG@ --link-libtool --libs` @APR_LTFLAGS@ mod_apreq2_la_SOURCES = apreq_private_apache.h handle.c command.c if HAVE_APACHE1 pkginclude_HEADERS = apreq_module_apache.h pkglib_LTLIBRARIES = mod_apreq2.la run_tests : t/TEST -cp -Rp .libs t MAKE=$(MAKE) @PERL@ t/TEST t/TEST : Makefile.am t/TEST.PL @PERL@ -MApache::TestMM -e '$(TEST_CONFIG_SCRIPT)' -- -apxs @APACHE1_APXS@ test :: all check run_tests test_clean : cmodules_clean -MAKE=$(MAKE) @PERL@ t/TEST -clean -rm -rf t/htdocs t/logs t/modules t/TEST t/core t/core.* t/cgi-bin/test_cgi t/cgi-bin/.libs t/.libs t/conf/extra.conf t/conf/ssl/ca t/conf/ssl/httpd-passphrase.pl cmodules_clean: -cd c-modules && $(MAKE) clean -rm c-modules/Makefile c-modules/*/Makefile c-modules/apache_httpd_test.h clean-local: test_clean install-exec-local : @echo "----------------------------------------------------------------------" @echo "Before you can use mod_apreq2, you must ensure that an appropriate" @echo "\"LoadModule\" line appears in your webserver's config file:" @echo "$(pkgcfgdir)/httpd.conf" @echo @echo "LoadModule apreq_module $(pkglibdir)/mod_apreq2.so" @echo "----------------------------------------------------------------------" endif rapache-1.2.8/libapreq2/module/apache/Makefile.in0000644000175100017510000003341612706745114021125 0ustar ondrejondrej# Makefile.in generated by automake 1.6.3 from Makefile.am. # @configure_input@ # Copyright 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002 # 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@ SHELL = @SHELL@ srcdir = @srcdir@ top_srcdir = @top_srcdir@ VPATH = @srcdir@ prefix = @prefix@ exec_prefix = @exec_prefix@ bindir = @bindir@ sbindir = @sbindir@ libexecdir = @libexecdir@ datadir = @datadir@ sysconfdir = @sysconfdir@ sharedstatedir = @sharedstatedir@ localstatedir = @localstatedir@ libdir = @libdir@ infodir = @infodir@ mandir = @mandir@ includedir = @includedir@ oldincludedir = /usr/include pkgdatadir = $(datadir)/@PACKAGE@ top_builddir = ../.. ACLOCAL = @ACLOCAL@ AUTOCONF = @AUTOCONF@ AUTOMAKE = @AUTOMAKE@ AUTOHEADER = @AUTOHEADER@ am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd INSTALL = @INSTALL@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_DATA = @INSTALL_DATA@ install_sh_DATA = $(install_sh) -c -m 644 install_sh_PROGRAM = $(install_sh) -c install_sh_SCRIPT = $(install_sh) -c INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_HEADER = $(INSTALL_DATA) transform = @program_transform_name@ NORMAL_INSTALL = : PRE_INSTALL = : POST_INSTALL = : NORMAL_UNINSTALL = : PRE_UNINSTALL = : POST_UNINSTALL = : host_alias = @host_alias@ host_triplet = @host@ EXEEXT = @EXEEXT@ OBJEXT = @OBJEXT@ PATH_SEPARATOR = @PATH_SEPARATOR@ pkglibdir = `@APACHE1_APXS@ -q LIBEXECDIR` pkgincludedir = `@APACHE1_APXS@ -q INCLUDEDIR`/@APREQ_LIBNAME@ AMTAR = @AMTAR@ APACHE1_APXS = @APACHE1_APXS@ APACHE2_APXS = @APACHE2_APXS@ APACHE2_HTTPD = @APACHE2_HTTPD@ APACHE2_INCLUDES = @APACHE2_INCLUDES@ APACHE2_SRC = @APACHE2_SRC@ APREQ_CONFIG = @APREQ_CONFIG@ APREQ_DOTTED_VERSION = @APREQ_DOTTED_VERSION@ APREQ_LIBNAME = @APREQ_LIBNAME@ APREQ_LIBTOOL_VERSION = @APREQ_LIBTOOL_VERSION@ APREQ_MAJOR_VERSION = @APREQ_MAJOR_VERSION@ APR_CONFIG = @APR_CONFIG@ APR_INCLUDES = @APR_INCLUDES@ APR_LA = @APR_LA@ APR_LDFLAGS = @APR_LDFLAGS@ APR_LIBS = @APR_LIBS@ APR_LTFLAGS = @APR_LTFLAGS@ APU_CONFIG = @APU_CONFIG@ APU_LA = @APU_LA@ AR = @AR@ AS = @AS@ AWK = @AWK@ CC = @CC@ CXX = @CXX@ CXXCPP = @CXXCPP@ DEPDIR = @DEPDIR@ DLLTOOL = @DLLTOOL@ ECHO = @ECHO@ EGREP = @EGREP@ F77 = @F77@ GCJ = @GCJ@ GCJFLAGS = @GCJFLAGS@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ LIBTOOL = @LIBTOOL@ LN_S = @LN_S@ MAINT = @MAINT@ OBJDUMP = @OBJDUMP@ PACKAGE = @PACKAGE@ PERL = @PERL@ PERL_OPTS = @PERL_OPTS@ RANLIB = @RANLIB@ RC = @RC@ STRIP = @STRIP@ VERSION = @VERSION@ am__include = @am__include@ am__quote = @am__quote@ install_sh = @install_sh@ AM_CPPFLAGS = $(APACHE1_INCLUDES) @APR_INCLUDES@ TEST_CONFIG_SCRIPT = package Apache::TestMM; filter_args(); generate_script("t/TEST") pkgcfgdir = `@APACHE1_APXS@ -q SYSCONFDIR` @MAINTAINER_MODE_TRUE@APACHE1_INCLUDES = -isystem `@APACHE1_APXS@ -q INCLUDEDIR` @MAINTAINER_MODE_FALSE@APACHE1_INCLUDES = -I`@APACHE1_APXS@ -q INCLUDEDIR` mod_apreq2_la_LDFLAGS = -export-dynamic -module -avoid-version \ `@APREQ_CONFIG@ --link-libtool --libs` @APR_LTFLAGS@ mod_apreq2_la_SOURCES = apreq_private_apache.h handle.c command.c @HAVE_APACHE1_TRUE@pkginclude_HEADERS = apreq_module_apache.h @HAVE_APACHE1_TRUE@pkglib_LTLIBRARIES = mod_apreq2.la subdir = module/apache mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs CONFIG_HEADER = $(top_builddir)/include/apreq_config.h CONFIG_CLEAN_FILES = LTLIBRARIES = $(pkglib_LTLIBRARIES) mod_apreq2_la_LIBADD = am_mod_apreq2_la_OBJECTS = handle.lo command.lo mod_apreq2_la_OBJECTS = $(am_mod_apreq2_la_OBJECTS) DEFS = @DEFS@ DEFAULT_INCLUDES = -I. -I$(srcdir) -I$(top_builddir)/include CPPFLAGS = @CPPFLAGS@ LDFLAGS = @LDFLAGS@ LIBS = @LIBS@ depcomp = $(SHELL) $(top_srcdir)/depcomp am__depfiles_maybe = depfiles @AMDEP_TRUE@DEP_FILES = ./$(DEPDIR)/command.Plo ./$(DEPDIR)/handle.Plo COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) LTCOMPILE = $(LIBTOOL) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) \ $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) CCLD = $(CC) LINK = $(LIBTOOL) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ $(AM_LDFLAGS) $(LDFLAGS) -o $@ CFLAGS = @CFLAGS@ DIST_SOURCES = $(mod_apreq2_la_SOURCES) HEADERS = $(pkginclude_HEADERS) DIST_COMMON = $(pkginclude_HEADERS) Makefile.am Makefile.in SOURCES = $(mod_apreq2_la_SOURCES) all: all-am .SUFFIXES: .SUFFIXES: .c .lo .o .obj $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ Makefile.am $(top_srcdir)/configure.ac $(ACLOCAL_M4) cd $(top_srcdir) && \ $(AUTOMAKE) --gnu module/apache/Makefile Makefile: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.in $(top_builddir)/config.status cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe) pkglibLTLIBRARIES_INSTALL = $(INSTALL) install-pkglibLTLIBRARIES: $(pkglib_LTLIBRARIES) @$(NORMAL_INSTALL) $(mkinstalldirs) $(DESTDIR)$(pkglibdir) @list='$(pkglib_LTLIBRARIES)'; for p in $$list; do \ if test -f $$p; then \ f="`echo $$p | sed -e 's|^.*/||'`"; \ echo " $(LIBTOOL) --mode=install $(pkglibLTLIBRARIES_INSTALL) $(INSTALL_STRIP_FLAG) $$p $(DESTDIR)$(pkglibdir)/$$f"; \ $(LIBTOOL) --mode=install $(pkglibLTLIBRARIES_INSTALL) $(INSTALL_STRIP_FLAG) $$p $(DESTDIR)$(pkglibdir)/$$f; \ else :; fi; \ done uninstall-pkglibLTLIBRARIES: @$(NORMAL_UNINSTALL) @list='$(pkglib_LTLIBRARIES)'; for p in $$list; do \ p="`echo $$p | sed -e 's|^.*/||'`"; \ echo " $(LIBTOOL) --mode=uninstall rm -f $(DESTDIR)$(pkglibdir)/$$p"; \ $(LIBTOOL) --mode=uninstall rm -f $(DESTDIR)$(pkglibdir)/$$p; \ done clean-pkglibLTLIBRARIES: -test -z "$(pkglib_LTLIBRARIES)" || rm -f $(pkglib_LTLIBRARIES) @list='$(pkglib_LTLIBRARIES)'; for p in $$list; do \ dir="`echo $$p | sed -e 's|/[^/]*$$||'`"; \ test -z "$dir" && dir=.; \ echo "rm -f \"$${dir}/so_locations\""; \ rm -f "$${dir}/so_locations"; \ done mod_apreq2.la: $(mod_apreq2_la_OBJECTS) $(mod_apreq2_la_DEPENDENCIES) $(LINK) -rpath $(pkglibdir) $(mod_apreq2_la_LDFLAGS) $(mod_apreq2_la_OBJECTS) $(mod_apreq2_la_LIBADD) $(LIBS) mostlyclean-compile: -rm -f *.$(OBJEXT) core *.core distclean-compile: -rm -f *.tab.c @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/command.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/handle.Plo@am__quote@ distclean-depend: -rm -rf ./$(DEPDIR) .c.o: @AMDEP_TRUE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@ depfile='$(DEPDIR)/$*.Po' tmpdepfile='$(DEPDIR)/$*.TPo' @AMDEPBACKSLASH@ @AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ $(COMPILE) -c `test -f '$<' || echo '$(srcdir)/'`$< .c.obj: @AMDEP_TRUE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@ depfile='$(DEPDIR)/$*.Po' tmpdepfile='$(DEPDIR)/$*.TPo' @AMDEPBACKSLASH@ @AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ $(COMPILE) -c `cygpath -w $<` .c.lo: @AMDEP_TRUE@ source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@ depfile='$(DEPDIR)/$*.Plo' tmpdepfile='$(DEPDIR)/$*.TPlo' @AMDEPBACKSLASH@ @AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ $(LTCOMPILE) -c -o $@ `test -f '$<' || echo '$(srcdir)/'`$< CCDEPMODE = @CCDEPMODE@ mostlyclean-libtool: -rm -f *.lo clean-libtool: -rm -rf .libs _libs distclean-libtool: -rm -f libtool uninstall-info-am: pkgincludeHEADERS_INSTALL = $(INSTALL_HEADER) install-pkgincludeHEADERS: $(pkginclude_HEADERS) @$(NORMAL_INSTALL) $(mkinstalldirs) $(DESTDIR)$(pkgincludedir) @list='$(pkginclude_HEADERS)'; for p in $$list; do \ if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ f="`echo $$p | sed -e 's|^.*/||'`"; \ echo " $(pkgincludeHEADERS_INSTALL) $$d$$p $(DESTDIR)$(pkgincludedir)/$$f"; \ $(pkgincludeHEADERS_INSTALL) $$d$$p $(DESTDIR)$(pkgincludedir)/$$f; \ done uninstall-pkgincludeHEADERS: @$(NORMAL_UNINSTALL) @list='$(pkginclude_HEADERS)'; for p in $$list; do \ f="`echo $$p | sed -e 's|^.*/||'`"; \ echo " rm -f $(DESTDIR)$(pkgincludedir)/$$f"; \ rm -f $(DESTDIR)$(pkgincludedir)/$$f; \ done ETAGS = etags ETAGSFLAGS = tags: TAGS 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; } \ END { for (i in files) print i; }'`; \ mkid -fID $$unique TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ $(TAGS_FILES) $(LISP) tags=; \ here=`pwd`; \ 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; } \ END { for (i in files) print i; }'`; \ test -z "$(ETAGS_ARGS)$$tags$$unique" \ || $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ $$tags $$unique GTAGS: here=`$(am__cd) $(top_builddir) && pwd` \ && cd $(top_srcdir) \ && gtags -i $(GTAGS_ARGS) $$here distclean-tags: -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) top_distdir = ../.. distdir = $(top_distdir)/$(PACKAGE)-$(VERSION) distdir: $(DISTFILES) @list='$(DISTFILES)'; for file in $$list; do \ if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ dir=`echo "$$file" | sed -e 's,/[^/]*$$,,'`; \ if test "$$dir" != "$$file" && test "$$dir" != "."; then \ dir="/$$dir"; \ $(mkinstalldirs) "$(distdir)$$dir"; \ else \ dir=''; \ fi; \ if test -d $$d/$$file; then \ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \ fi; \ cp -pR $$d/$$file $(distdir)$$dir || exit 1; \ else \ test -f $(distdir)/$$file \ || cp -p $$d/$$file $(distdir)/$$file \ || exit 1; \ fi; \ done check-am: all-am check: check-am all-am: Makefile $(LTLIBRARIES) $(HEADERS) installdirs: $(mkinstalldirs) $(DESTDIR)$(pkglibdir) $(DESTDIR)$(pkgincludedir) 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_STRIP_FLAG=-s \ `test -z '$(STRIP)' || \ echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install mostlyclean-generic: clean-generic: distclean-generic: -rm -f Makefile $(CONFIG_CLEAN_FILES) maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." clean: clean-am clean-am: clean-generic clean-libtool clean-local \ clean-pkglibLTLIBRARIES mostlyclean-am distclean: distclean-am distclean-am: clean-am distclean-compile distclean-depend \ distclean-generic distclean-libtool distclean-tags dvi: dvi-am dvi-am: info: info-am info-am: install-data-am: install-pkgincludeHEADERS install-exec-am: install-exec-local install-pkglibLTLIBRARIES install-info: install-info-am install-man: installcheck-am: maintainer-clean: maintainer-clean-am maintainer-clean-am: distclean-am maintainer-clean-generic mostlyclean: mostlyclean-am mostlyclean-am: mostlyclean-compile mostlyclean-generic \ mostlyclean-libtool uninstall-am: uninstall-info-am uninstall-pkgincludeHEADERS \ uninstall-pkglibLTLIBRARIES .PHONY: GTAGS all all-am check check-am clean clean-generic \ clean-libtool clean-local clean-pkglibLTLIBRARIES distclean \ distclean-compile distclean-depend distclean-generic \ distclean-libtool distclean-tags distdir dvi dvi-am info \ info-am install install-am install-data install-data-am \ install-exec install-exec-am install-exec-local install-info \ install-info-am install-man install-pkgincludeHEADERS \ install-pkglibLTLIBRARIES install-strip installcheck \ installcheck-am installdirs maintainer-clean \ maintainer-clean-generic mostlyclean mostlyclean-compile \ mostlyclean-generic mostlyclean-libtool tags uninstall \ uninstall-am uninstall-info-am uninstall-pkgincludeHEADERS \ uninstall-pkglibLTLIBRARIES @HAVE_APACHE1_TRUE@run_tests : t/TEST @HAVE_APACHE1_TRUE@ -cp -Rp .libs t @HAVE_APACHE1_TRUE@ MAKE=$(MAKE) @PERL@ t/TEST @HAVE_APACHE1_TRUE@t/TEST : Makefile.am t/TEST.PL @HAVE_APACHE1_TRUE@ @PERL@ -MApache::TestMM -e '$(TEST_CONFIG_SCRIPT)' -- -apxs @APACHE1_APXS@ @HAVE_APACHE1_TRUE@test :: all check run_tests @HAVE_APACHE1_TRUE@test_clean : cmodules_clean @HAVE_APACHE1_TRUE@ -MAKE=$(MAKE) @PERL@ t/TEST -clean @HAVE_APACHE1_TRUE@ -rm -rf t/htdocs t/logs t/modules t/TEST t/core t/core.* t/cgi-bin/test_cgi t/cgi-bin/.libs t/.libs t/conf/extra.conf t/conf/ssl/ca t/conf/ssl/httpd-passphrase.pl @HAVE_APACHE1_TRUE@cmodules_clean: @HAVE_APACHE1_TRUE@ -cd c-modules && $(MAKE) clean @HAVE_APACHE1_TRUE@ -rm c-modules/Makefile c-modules/*/Makefile c-modules/apache_httpd_test.h @HAVE_APACHE1_TRUE@clean-local: test_clean @HAVE_APACHE1_TRUE@install-exec-local : @HAVE_APACHE1_TRUE@ @echo "----------------------------------------------------------------------" @HAVE_APACHE1_TRUE@ @echo "Before you can use mod_apreq2, you must ensure that an appropriate" @HAVE_APACHE1_TRUE@ @echo "\"LoadModule\" line appears in your webserver's config file:" @HAVE_APACHE1_TRUE@ @echo "$(pkgcfgdir)/httpd.conf" @HAVE_APACHE1_TRUE@ @echo @HAVE_APACHE1_TRUE@ @echo "LoadModule apreq_module $(pkglibdir)/mod_apreq2.so" @HAVE_APACHE1_TRUE@ @echo "----------------------------------------------------------------------" # 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: rapache-1.2.8/libapreq2/module/apache/apreq_module_apache.h0000644000175100017510000000215612706745114023204 0ustar ondrejondrej/* ** Copyright 2003-2005 The Apache Software Foundation ** ** Licensed under the Apache License, Version 2.0 (the "License"); ** you may not use this file except in compliance with the License. ** You may obtain a copy of the License at ** ** http://www.apache.org/licenses/LICENSE-2.0 ** ** Unless required by applicable law or agreed to in writing, software ** distributed under the License is distributed on an "AS IS" BASIS, ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ** See the License for the specific language governing permissions and ** limitations under the License. */ #ifndef APREQ_APACHE_H #define APREQ_APACHE_H #include "apreq_module.h" #include #ifdef __cplusplus extern "C" { #endif /** * Create an apreq handle which communicates with an Apache 1.3.x * request_rec. */ APREQ_DECLARE(apreq_handle_t*) apreq_handle_apache(request_rec *r); APREQ_DECLARE(apr_pool_t *) apreq_handle_apache_pool(apreq_handle_t *req); APREQ_DECLARE(apr_bucket_alloc_t *) apreq_handle_apache_bucket_alloc(apreq_handle_t *req); #ifdef __cplusplus } #endif #endif rapache-1.2.8/libapreq2/module/apache/apreq_private_apache.h0000644000175100017510000000036612706745114023372 0ustar ondrejondrej#define CORE_PRIVATE #include "http_config.h" #undef CORE_PRIVATE extern module MODULE_VAR_EXPORT apreq_module; struct dir_config { const char *temp_dir; apr_uint64_t read_limit; apr_size_t brigade_limit; }; rapache-1.2.8/libapreq2/module/apache/command.c0000644000175100017510000001424412706745114020640 0ustar ondrejondrej/* ** Copyright 2003-2005 The Apache Software Foundation ** ** Licensed under the Apache License, Version 2.0 (the "License"); ** you may not use this file except in compliance with the License. ** You may obtain a copy of the License at ** ** http://www.apache.org/licenses/LICENSE-2.0 ** ** Unless required by applicable law or agreed to in writing, software ** distributed under the License is distributed on an "AS IS" BASIS, ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ** See the License for the specific language governing permissions and ** limitations under the License. */ #include "apr_strings.h" #include "apreq_util.h" #include "apreq_module_apache.h" #include "httpd.h" #include "http_log.h" #include "http_request.h" #include "apreq_private_apache.h" /** *

Server Configuration Directives

* * * * * * *
Per-directory commands for mod_apreq
DirectiveContextDefaultDescription
APREQ_ReadLimitdirectory-1 (Unlimited) * Maximum number of bytes mod_apreq will send off to libapreq for parsing. * mod_apreq will log this event and remove itself from the filter chain. * The APREQ_ERROR_GENERAL error will be reported to libapreq2 users via the return * value of apreq_env_read(). *
APREQ_BrigadeLimitdirectory #APREQ_MAX_BRIGADE_LEN * Maximum number of bytes apreq will allow to accumulate * within a brigade. Excess data will be spooled to a * file bucket appended to the brigade. *
APREQ_TempDirdirectoryNULL * Sets the location of the temporary directory apreq will use to spool * overflow brigade data (based on the APREQ_BrigadeLimit setting). * If left unset, libapreq2 will select a platform-specific location via apr_temp_dir_get(). *
* *

Implementation Details

*
 * XXX apreq as a normal input filter
 * XXX apreq as a "virtual" content handler.
 * XXX apreq as a transparent "tee".
 * XXX apreq parser registration in post_config
 * 
* @{ */ static void *apreq_create_dir_config(pool *p, char *d) { /* d == OR_ALL */ struct dir_config *dc = ap_palloc(p, sizeof *dc); dc->temp_dir = NULL; dc->read_limit = (apr_uint64_t)-1; dc->brigade_limit = APREQ_DEFAULT_BRIGADE_LIMIT; return dc; } static void *apreq_merge_dir_config(pool *p, void *a_, void *b_) { struct dir_config *a = a_, *b = b_, *c = ap_palloc(p, sizeof *c); c->temp_dir = (b->temp_dir != NULL) /* overrides ok */ ? b->temp_dir : a->temp_dir; c->brigade_limit = (b->brigade_limit == (apr_size_t)-1) /* overrides ok */ ? a->brigade_limit : b->brigade_limit; c->read_limit = (b->read_limit < a->read_limit) /* why min? */ ? b->read_limit : a->read_limit; return c; } static const char *apreq_set_temp_dir(cmd_parms *cmd, void *data, const char *arg) { struct dir_config *conf = data; const char *err = ap_check_cmd_context(cmd, NOT_IN_LIMIT); if (err != NULL) return err; conf->temp_dir = arg; return NULL; } static const char *apreq_set_read_limit(cmd_parms *cmd, void *data, const char *arg) { struct dir_config *conf = data; const char *err = ap_check_cmd_context(cmd, NOT_IN_LIMIT); if (err != NULL) return err; conf->read_limit = apreq_atoi64f(arg); return NULL; } static const char *apreq_set_brigade_limit(cmd_parms *cmd, void *data, const char *arg) { struct dir_config *conf = data; const char *err = ap_check_cmd_context(cmd, NOT_IN_LIMIT); if (err != NULL) return err; conf->brigade_limit = apreq_atoi64f(arg); return NULL; } static const command_rec apreq_cmds[] = { { "APREQ_TempDir", apreq_set_temp_dir, NULL, OR_ALL, TAKE1, "Default location of temporary directory" }, { "APREQ_ReadLimit", apreq_set_read_limit, NULL, OR_ALL, TAKE1, "Maximum amount of data that will be fed into a parser." }, { "APREQ_BrigadeLimit", apreq_set_brigade_limit, NULL, OR_ALL, TAKE1, "Maximum in-memory bytes a brigade may use." }, { NULL } }; static void apreq_cleanup(void *data) { apr_pool_t *p = data; apr_pool_destroy(p); apr_terminate(); } static void apreq_init (server_rec *s, pool *sp) { /* APR_HOOK_FIRST because we want other modules to be able to register parsers in their post_config hook */ apr_pool_t *p; apr_initialize(); apr_pool_create(&p, NULL); apreq_initialize(p); ap_register_cleanup(sp, p, apreq_cleanup, apreq_cleanup); } /** @} */ module MODULE_VAR_EXPORT apreq_module = { STANDARD_MODULE_STUFF, apreq_init, /* module initializer */ apreq_create_dir_config, /* per-directory config creator */ apreq_merge_dir_config, /* dir config merger */ NULL, /* server config creator */ NULL, /* server config merger */ apreq_cmds, /* command table */ NULL, /* [9] content handlers */ NULL, /* [2] URI-to-filename translation */ NULL, /* [5] check/validate user_id */ NULL, /* [6] check user_id is valid *here* */ NULL, /* [4] check access by host address */ NULL, /* [7] MIME type checker/setter */ NULL, /* [8] fixups */ NULL, /* [10] logger */ NULL, /* [3] header parser */ NULL, /* process initialization */ NULL, /* process exit/cleanup */ NULL /* [1] post read_request handling */ }; rapache-1.2.8/libapreq2/module/apache/handle.c0000644000175100017510000003423512706745114020457 0ustar ondrejondrej/* ** Copyright 2003-2005 The Apache Software Foundation ** ** Licensed under the Apache License, Version 2.0 (the "License"); ** you may not use this file except in compliance with the License. ** You may obtain a copy of the License at ** ** http://www.apache.org/licenses/LICENSE-2.0 ** ** Unless required by applicable law or agreed to in writing, software ** distributed under the License is distributed on an "AS IS" BASIS, ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ** See the License for the specific language governing permissions and ** limitations under the License. */ #include "apr_strings.h" #include "apreq_module_apache.h" #include "http_main.h" #include "http_log.h" #include "http_protocol.h" #include "http_request.h" #include "apreq_private_apache.h" /* This is basically the cgi_handle struct with a request_rec */ struct apache_handle { struct apreq_handle_t handle; request_rec *r; apr_pool_t *pool; apr_bucket_alloc_t *bucket_alloc; apr_table_t *jar, *args, *body; apr_status_t jar_status, args_status, body_status; apreq_parser_t *parser; apreq_hook_t *hook_queue; const char *temp_dir; apr_size_t brigade_limit; apr_uint64_t read_limit; apr_uint64_t bytes_read; apr_bucket_brigade *in; }; static const char *apache_header_in(apreq_handle_t *env, const char *name) { struct apache_handle *req = (struct apache_handle *)env; return ap_table_get(req->r->headers_in, name); } static apr_status_t apache_header_out(apreq_handle_t *env, const char *name, char *value) { struct apache_handle *req = (struct apache_handle *)env; ap_table_add(req->r->err_headers_out, name, value); return APR_SUCCESS; } #ifdef APR_POOL_DEBUG static apr_status_t ba_cleanup(void *data) { apr_bucket_alloc_t *ba = data; apr_bucket_alloc_destroy(ba); return APR_SUCCESS; } #endif static void init_body(apreq_handle_t *env) { struct apache_handle *req = (struct apache_handle *)env; const char *cl_header = apache_header_in(env, "Content-Length"); apr_bucket_alloc_t *ba = req->bucket_alloc; request_rec *r = req->r; req->body = apr_table_make(req->pool, APREQ_DEFAULT_NELTS); #ifdef APR_POOL_DEBUG apr_pool_cleanup_register(req->pool, ba, ba_cleanup, ba_cleanup); #endif if (cl_header != NULL) { char *dummy; apr_int64_t content_length = apr_strtoi64(cl_header, &dummy, 0); if (dummy == NULL || *dummy != 0) { req->body_status = APREQ_ERROR_BADHEADER; ap_log_rerror(APLOG_MARK, APLOG_ERR, r, "Invalid Content-Length header (%s)", cl_header); return; } else if ((apr_uint64_t)content_length > req->read_limit) { req->body_status = APREQ_ERROR_OVERLIMIT; ap_log_rerror(APLOG_MARK, APLOG_ERR, r, "Content-Length header (%s) exceeds configured " "max_body limit (%" APR_UINT64_T_FMT ")", cl_header, req->read_limit); return; } } if (req->parser == NULL) { const char *ct_header = apache_header_in(env, "Content-Type"); if (ct_header != NULL) { apreq_parser_function_t pf = apreq_parser(ct_header); if (pf != NULL) { req->parser = apreq_parser_make(req->pool, ba, ct_header, pf, req->brigade_limit, req->temp_dir, req->hook_queue, NULL); } else { req->body_status = APREQ_ERROR_NOPARSER; return; } } else { req->body_status = APREQ_ERROR_NOHEADER; return; } } else { if (req->parser->brigade_limit > req->brigade_limit) req->parser->brigade_limit = req->brigade_limit; if (req->temp_dir != NULL) req->parser->temp_dir = req->temp_dir; if (req->hook_queue != NULL) apreq_parser_add_hook(req->parser, req->hook_queue); } req->hook_queue = NULL; req->in = apr_brigade_create(req->pool, ba); req->body_status = APR_INCOMPLETE; } static apr_status_t apache_read(apreq_handle_t *env, apr_off_t bytes) { struct apache_handle *req = (struct apache_handle *)env; request_rec *r = req->r; apr_bucket *e; long got = 0; char buf[HUGE_STRING_LEN]; char tc[] = "[apreq] apache_read"; int want = sizeof buf; if (req->body_status == APR_EINIT) init_body(env); if (req->body_status != APR_INCOMPLETE) return req->body_status; /* XXX want a loop here, instead of reducing bytes */ if (bytes > HUGE_STRING_LEN) want = HUGE_STRING_LEN; else want = bytes; ap_hard_timeout(tc, r); got = ap_get_client_block(r, buf, want); ap_kill_timeout(r); if (got > 0) { e = apr_bucket_transient_create(buf, got, req->bucket_alloc); req->bytes_read += got; } else e = apr_bucket_eos_create(req->bucket_alloc); APR_BRIGADE_INSERT_TAIL(req->in, e); if (req->bytes_read <= req->read_limit) { req->body_status = apreq_parser_run(req->parser, req->body, req->in); apr_brigade_cleanup(req->in); } else { req->body_status = APREQ_ERROR_OVERLIMIT; ap_log_rerror(APLOG_MARK, APLOG_ERR, req->r, "Bytes read (%" APR_UINT64_T_FMT ") exceeds configured limit (%" APR_UINT64_T_FMT ")", req->bytes_read, req->read_limit); } return req->body_status; } static apr_status_t apache_jar(apreq_handle_t *env, const apr_table_t **t) { struct apache_handle *req = (struct apache_handle *)env; request_rec *r = req->r; if (req->jar_status == APR_EINIT) { const char *cookies = ap_table_get(r->headers_in, "Cookie"); if (cookies != NULL) { req->jar = apr_table_make(req->pool, APREQ_DEFAULT_NELTS); req->jar_status = apreq_parse_cookie_header(req->pool, req->jar, cookies); } else req->jar_status = APREQ_ERROR_NODATA; } *t = req->jar; return req->jar_status; } static apr_status_t apache_args(apreq_handle_t *env, const apr_table_t **t) { struct apache_handle *req = (struct apache_handle *)env; request_rec *r = req->r; if (req->args_status == APR_EINIT) { if (r->args != NULL) { req->args = apr_table_make(req->pool, APREQ_DEFAULT_NELTS); req->args_status = apreq_parse_query_string(req->pool, req->args, r->args); } else req->args_status = APREQ_ERROR_NODATA; } *t = req->args; return req->args_status; } static apreq_cookie_t *apache_jar_get(apreq_handle_t *env, const char *name) { struct apache_handle *req = (struct apache_handle *)env; const apr_table_t *t; const char *val; if (req->jar_status == APR_EINIT) apache_jar(env, &t); else t = req->jar; if (t == NULL) return NULL; val = apr_table_get(t, name); if (val == NULL) return NULL; return apreq_value_to_cookie(val); } static apreq_param_t *apache_args_get(apreq_handle_t *env, const char *name) { struct apache_handle *req = (struct apache_handle *)env; const apr_table_t *t; const char *val; if (req->args_status == APR_EINIT) apache_args(env, &t); else t = req->args; if (t == NULL) return NULL; val = apr_table_get(t, name); if (val == NULL) return NULL; return apreq_value_to_param(val); } static apr_status_t apache_body(apreq_handle_t *env, const apr_table_t **t) { struct apache_handle *req = (struct apache_handle *)env; switch (req->body_status) { case APR_EINIT: init_body(env); if (req->body_status != APR_INCOMPLETE) break; case APR_INCOMPLETE: while (apache_read(env, APREQ_DEFAULT_READ_BLOCK_SIZE) == APR_INCOMPLETE) ; /*loop*/ } *t = req->body; return req->body_status; } static apreq_param_t *apache_body_get(apreq_handle_t *env, const char *name) { struct apache_handle *req = (struct apache_handle *)env; const char *val; switch (req->body_status) { case APR_EINIT: init_body(env); if (req->body_status != APR_INCOMPLETE) return NULL; apache_read(env, APREQ_DEFAULT_READ_BLOCK_SIZE); case APR_INCOMPLETE: val = apr_table_get(req->body, name); if (val != NULL) return apreq_value_to_param(val); do { /* riff on Duff's device */ apache_read(env, APREQ_DEFAULT_READ_BLOCK_SIZE); default: val = apr_table_get(req->body, name); if (val != NULL) return apreq_value_to_param(val); } while (req->body_status == APR_INCOMPLETE); } return NULL; } static apr_status_t apache_parser_get(apreq_handle_t *env, const apreq_parser_t **parser) { struct apache_handle *req = (struct apache_handle *)env; *parser = req->parser; return APR_SUCCESS; } static apr_status_t apache_parser_set(apreq_handle_t *env, apreq_parser_t *parser) { struct apache_handle *req = (struct apache_handle *)env; if (req->parser == NULL) { if (req->hook_queue != NULL) { apr_status_t s = apreq_parser_add_hook(parser, req->hook_queue); if (s != APR_SUCCESS) return s; } if (req->temp_dir != NULL) { req->temp_dir = req->temp_dir; } if (req->brigade_limit < req->brigade_limit) { req->brigade_limit = req->brigade_limit; } req->hook_queue = NULL; req->parser = parser; return APR_SUCCESS; } else return APREQ_ERROR_MISMATCH; } static apr_status_t apache_hook_add(apreq_handle_t *env, apreq_hook_t *hook) { struct apache_handle *req = (struct apache_handle *)env; if (req->parser != NULL) { return apreq_parser_add_hook(req->parser, hook); } else if (req->hook_queue != NULL) { apreq_hook_t *h = req->hook_queue; while (h->next != NULL) h = h->next; h->next = hook; } else { req->hook_queue = hook; } return APR_SUCCESS; } static apr_status_t apache_brigade_limit_set(apreq_handle_t *env, apr_size_t bytes) { struct apache_handle *req = (struct apache_handle *)env; apr_size_t *limit = (req->parser == NULL) ? &req->brigade_limit : &req->parser->brigade_limit; if (*limit > bytes) { *limit = bytes; return APR_SUCCESS; } return APREQ_ERROR_MISMATCH; } static apr_status_t apache_brigade_limit_get(apreq_handle_t *env, apr_size_t *bytes) { struct apache_handle *req = (struct apache_handle *)env; *bytes = (req->parser == NULL) ? req->brigade_limit : req->parser->brigade_limit; return APR_SUCCESS; } static apr_status_t apache_read_limit_set(apreq_handle_t *env, apr_uint64_t bytes) { struct apache_handle *req = (struct apache_handle *)env; if (req->read_limit > bytes && req->bytes_read < bytes) { req->read_limit = bytes; return APR_SUCCESS; } return APREQ_ERROR_MISMATCH; } static apr_status_t apache_read_limit_get(apreq_handle_t *env, apr_uint64_t *bytes) { struct apache_handle *req = (struct apache_handle *)env; *bytes = req->read_limit; return APR_SUCCESS; } static apr_status_t apache_temp_dir_set(apreq_handle_t *env, const char *path) { struct apache_handle *req = (struct apache_handle *)env; const char **curpath = (req->parser == NULL) ? &req->temp_dir : &req->parser->temp_dir; if (*curpath == NULL) { *curpath = apr_pstrdup(req->pool, path); return APR_SUCCESS; } return APREQ_ERROR_NOTEMPTY; } static apr_status_t apache_temp_dir_get(apreq_handle_t *env, const char **path) { struct apache_handle *req = (struct apache_handle *)env; *path = req->parser ? req->parser->temp_dir : req->temp_dir; return APR_SUCCESS; } static APREQ_MODULE(apache, 20050227); static void apreq_cleanup(void *data) { struct apache_handle *req = data; apr_pool_destroy(req->pool); } APREQ_DECLARE(apreq_handle_t *) apreq_handle_apache(request_rec *r) { struct apache_handle *req = ap_get_module_config(r->request_config, &apreq_module); struct dir_config *d = ap_get_module_config(r->per_dir_config, &apreq_module); if (req != NULL) return &req->handle; apr_pool_create(&req->pool, NULL); req = apr_pcalloc(req->pool, sizeof *req); req->bucket_alloc = apr_bucket_alloc_create(req->pool); req->handle.module = &apache_module; req->r = r; req->args_status = req->jar_status = req->body_status = APR_EINIT; ap_register_cleanup(r->pool, req, apreq_cleanup, apreq_cleanup); if (d == NULL) { req->read_limit = (apr_uint64_t)-1; req->brigade_limit = APREQ_DEFAULT_BRIGADE_LIMIT; } else { req->temp_dir = d->temp_dir; req->read_limit = d->read_limit; req->brigade_limit = d->brigade_limit; } ap_set_module_config(r->request_config, &apreq_module, req); return &req->handle; } rapache-1.2.8/libapreq2/module/apache/t/0000755000175100017510000000000012706745114017314 5ustar ondrejondrejrapache-1.2.8/libapreq2/module/apache/t/TEST.PL0000644000175100017510000000623312706745114020334 0ustar ondrejondrejuse strict; use warnings FATAL => 'all'; use constant WIN32 => $^O eq 'MSWin32'; use Cwd; my $cwd = WIN32 ? Win32::GetLongPathName(cwd) : cwd; $cwd =~ m{^(.+)/module/apache$} or die "Can't find base directory"; my $base_dir = $1; my $module_dir = "$base_dir/module"; my $mod_apreq2_dir = WIN32 ? "$base_dir/win32/libs" : "$module_dir/apache/.libs"; use base 'Apache::TestRun'; $Apache::TestTrace::Level = 'debug'; main::->new->run(@ARGV); sub pre_configure { my $self = shift; # Don't load an installed mod_apreq* Apache::TestConfig::autoconfig_skip_module_add('mod_apreq.c'); Apache::TestConfig::autoconfig_skip_module_add('mod_apreq2.c'); } sub configure { my $self = shift; my $cfg = $self->{test_config}; # make sure Win32 uses the just-built libapreq2.dll if (WIN32) { $cfg->preamble(qq{LoadFile "$mod_apreq2_dir/libapreq2.dll"\n}); } $cfg->preamble(IfModule => '!mod_apreq2.c', qq(LoadModule apreq_module "$mod_apreq2_dir/mod_apreq2.so"\n)); bless $cfg, "My::TestConfig"; $self->SUPER::configure(); } package My::TestConfig; use Apache::TestTrace; use Apache::TestConfigC; use Config; use File::Spec; use constant WIN32 => $^O eq 'MSWin32'; use base 'Apache::TestConfig'; sub cmodules_configure { my $self = shift; my $dir = File::Spec->catdir($module_dir, 'apache', 't', 'c-modules'); $self->SUPER::cmodules_configure($dir); } sub cmodules_httpd_conf { my $self = shift; debug "WRITING httpd.conf with " . join", ",map $_->{name}, @{$self->{cmodules}}; $self->SUPER::cmodules_httpd_conf(@_); } sub cmodules_write_makefile { my($self, $mod) = @_; my $dversion = $self->server->dversion; my $name = $mod->{name}; my $makefile = "$mod->{dir}/Makefile"; debug "WRITING $makefile for $name"; my $lib = $self->cmodules_build_so($name); my $fh = Symbol::gensym(); open $fh, ">$makefile" or die "open $makefile: $!"; if (WIN32) { require File::Spec; my @goners = map {$name . '.' . $_} qw(exp ilk lib pdb so lo); my $libs = join ' ', (map {'-l' . File::Spec->catfile($mod_apreq2_dir, $_)} qw(libapreq2.lib mod_apreq.lib)); print $fh <{APXS} all: $lib $lib: $name.c \$(APXS) -I../../.. -I../../../../include $libs -llibhttpd $dversion -p -I$self->{cmodules_dir} -c $name.c clean: -erase @goners vc60.pdb EOF } else { print $fh <{APXS} all: $lib $lib: $name.c \$(APXS) -L../../../../library -I../../.. -I../../../../../include -lapreq2 $dversion -I$self->{cmodules_dir} -c $name.c clean: -rm -rf $name.o $name.lo $name.slo $name.la .libs EOF } close $fh or die "close $makefile: $!"; } sub cmodules_makefile_vars { my $make = $ENV{MAKE} || $Config{make}; return < TestAccess test SetHandler apreq_request_test #endif #endif #define APACHE_HTTPD_TEST_ACCESS_CHECKER apreq_access_checker #define APACHE_HTTPD_TEST_COMMANDS access_cmds #define APACHE_HTTPD_TEST_PER_DIR_CREATE create_access_config #include "apache_httpd_test.h" #include "apreq_module_apache2.h" #include "httpd.h" #include "apr_strings.h" extern module AP_MODULE_DECLARE_DATA apreq_access_test_module; struct access_test_cfg { apr_pool_t *pool; const char *param; }; static const char *access_config(cmd_parms *cmd, void *dv, const char *arg) { struct access_test_cfg *cfg = (struct access_test_cfg *)dv; cfg->param = apr_pstrdup(cfg->pool, arg); return NULL; } static const command_rec access_cmds[] = { AP_INIT_TAKE1("TestAccess", access_config, NULL, OR_LIMIT, "'param'"), { NULL } }; static void *create_access_config(apr_pool_t *p, char *dummy) { struct access_test_cfg *cfg = apr_palloc(p, sizeof *cfg); cfg->pool = p; cfg->param = dummy; return cfg; } static int apreq_access_checker(request_rec *r) { apreq_handle_t *handle; apreq_param_t *param; struct access_test_cfg *cfg = (struct access_test_cfg *) ap_get_module_config(r->per_dir_config, &apreq_access_test_module); if (!cfg || !cfg->param) return DECLINED; handle = apreq_handle_apache2(r); param = apreq_param(handle, cfg->param); if (param != NULL) { ap_log_rerror(APLOG_MARK, APLOG_DEBUG, APR_SUCCESS, r, "ACCESS GRANTED: %s => %s", cfg->param, param->v.data); return OK; } else { const apr_table_t *t = apreq_params(handle, r->pool); if (t != NULL) { ap_log_rerror(APLOG_MARK, APLOG_DEBUG, APR_EGENERAL, r, "%s not found: parsing error detected (%d params)", cfg->param, apr_table_elts(t)->nelts); } else { ap_log_rerror(APLOG_MARK, APLOG_DEBUG, APR_EGENERAL, r, "%s not found: paring error detected (no param table)", cfg->param); } return HTTP_FORBIDDEN; } } APACHE_HTTPD_TEST_MODULE(apreq_access_test); rapache-1.2.8/libapreq2/module/apache/t/c-modules/apreq_big_request_test/0000755000175100017510000000000012706745114025744 5ustar ondrejondrej././@LongLink0000644000000000000000000000014600000000000011604 Lustar rootrootrapache-1.2.8/libapreq2/module/apache/t/c-modules/apreq_big_request_test/mod_apreq_big_request_test.crapache-1.2.8/libapreq2/module/apache/t/c-modules/apreq_big_request_test/mod_apreq_big_request_test.0000644000175100017510000000306012706745114033343 0ustar ondrejondrej/* ** Copyright 2003-2005 The Apache Software Foundation ** ** Licensed under the Apache License, Version 2.0 (the "License"); ** you may not use this file except in compliance with the License. ** You may obtain a copy of the License at ** ** http://www.apache.org/licenses/LICENSE-2.0 ** ** Unless required by applicable law or agreed to in writing, software ** distributed under the License is distributed on an "AS IS" BASIS, ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ** See the License for the specific language governing permissions and ** limitations under the License. */ #ifdef CONFIG_FOR_HTTPD_TEST #if CONFIG_FOR_HTTPD_TEST SetHandler apreq_big_request_test #endif #endif #define APACHE_HTTPD_TEST_HANDLER apreq_big_request_test_handler #include "apache_httpd_test.h" #include "apreq_module_apache2.h" #include "httpd.h" static int dump_table(void *count, const char *key, const char *value) { int *c = (int *) count; *c = *c + strlen(key) + strlen(value); return 1; } static int apreq_big_request_test_handler(request_rec *r) { apreq_handle_t *req; apr_table_t *params; int count = 0; if (strcmp(r->handler, "apreq_big_request_test") != 0) return DECLINED; req = apreq_handle_apache2(r); params = apreq_params(req, r->pool); apr_table_do(dump_table, &count, params, NULL); ap_set_content_type(r, "text/plain"); ap_rprintf(r, "%d", count); return OK; } APACHE_HTTPD_TEST_MODULE(apreq_big_request_test); rapache-1.2.8/libapreq2/module/apache/t/c-modules/apreq_cookie_test/0000755000175100017510000000000012706745114024704 5ustar ondrejondrejrapache-1.2.8/libapreq2/module/apache/t/c-modules/apreq_cookie_test/mod_apreq_cookie_test.c0000644000175100017510000000473312706745114031416 0ustar ondrejondrej/* ** Copyright 2003-2005 The Apache Software Foundation ** ** Licensed under the Apache License, Version 2.0 (the "License"); ** you may not use this file except in compliance with the License. ** You may obtain a copy of the License at ** ** http://www.apache.org/licenses/LICENSE-2.0 ** ** Unless required by applicable law or agreed to in writing, software ** distributed under the License is distributed on an "AS IS" BASIS, ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ** See the License for the specific language governing permissions and ** limitations under the License. */ #ifdef CONFIG_FOR_HTTPD_TEST #if CONFIG_FOR_HTTPD_TEST SetHandler apreq_cookie_test #endif #endif #define APACHE_HTTPD_TEST_HANDLER apreq_cookie_test_handler #include "apache_httpd_test.h" #include "apreq_module_apache2.h" #include "apreq_util.h" #include "httpd.h" #include static int dump_table(void *ctx, const char *key, const char *value) { request_rec *r = ctx; ap_log_rerror(APLOG_MARK, APLOG_DEBUG, APR_SUCCESS, r, "[%s] => [%s]", key, value); return 1; } static int apreq_cookie_test_handler(request_rec *r) { apreq_handle_t *req; apr_status_t s; const char *test, *key; apreq_cookie_t *cookie; apr_size_t size; char *dest; const apr_table_t *args; if (strcmp(r->handler, "apreq_cookie_test") != 0) return DECLINED; req = apreq_handle_apache2(r); ap_log_rerror(APLOG_MARK, APLOG_DEBUG, APR_SUCCESS, r, "starting cookie tests"); apreq_args(req, &args); apr_table_do(dump_table, r, args, NULL); test = apr_table_get(args, "test"); key = apr_table_get(args, "key"); cookie = apreq_cookie(req, key); ap_set_content_type(r, "text/plain"); if (strcmp(test, "bake") == 0) { apreq_cookie_tainted_off(cookie); s = apreq_cookie_bake(cookie, req); } else if (strcmp(test, "bake2") == 0) { apreq_cookie_tainted_off(cookie); s = apreq_cookie_bake2(cookie, req); } else { size = strlen(cookie->v.data); dest = apr_palloc(r->pool, size + 1); s = apreq_decode(dest, &size, cookie->v.data, size); if (s == APR_SUCCESS) ap_rprintf(r, "%s", dest); } ap_log_rerror(APLOG_MARK, APLOG_DEBUG, s, r, "finished cookie tests"); return OK; } APACHE_HTTPD_TEST_MODULE(apreq_cookie_test); rapache-1.2.8/libapreq2/module/apache/t/c-modules/apreq_redirect_test/0000755000175100017510000000000012706745114025234 5ustar ondrejondrejrapache-1.2.8/libapreq2/module/apache/t/c-modules/apreq_redirect_test/mod_apreq_redirect_test.c0000644000175100017510000000305612706745114032273 0ustar ondrejondrej/* ** Copyright 2003-2005 The Apache Software Foundation ** ** Licensed under the Apache License, Version 2.0 (the "License"); ** you may not use this file except in compliance with the License. ** You may obtain a copy of the License at ** ** http://www.apache.org/licenses/LICENSE-2.0 ** ** Unless required by applicable law or agreed to in writing, software ** distributed under the License is distributed on an "AS IS" BASIS, ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ** See the License for the specific language governing permissions and ** limitations under the License. */ #ifdef CONFIG_FOR_HTTPD_TEST #if CONFIG_FOR_HTTPD_TEST TestAccess test SetHandler apreq_redirect_test #endif #endif #define APACHE_HTTPD_TEST_HANDLER apreq_redirect_test_handler #include "apache_httpd_test.h" #include "apreq_module_apache2.h" #include "httpd.h" static int apreq_redirect_test_handler(request_rec *r) { apreq_handle_t *req; const apreq_param_t *loc; if (strcmp(r->handler, "apreq_redirect_test") != 0) return DECLINED; req = apreq_handle_apache2(r); ap_log_rerror(APLOG_MARK, APLOG_DEBUG, APR_SUCCESS, r, "looking for new location"); loc = apreq_param(req, "location"); if (!loc) return DECLINED; ap_log_rerror(APLOG_MARK, APLOG_DEBUG, APR_SUCCESS, r, "redirecting to %s", loc->v.data); ap_internal_redirect(loc->v.data, r); return OK; } APACHE_HTTPD_TEST_MODULE(apreq_redirect_test); rapache-1.2.8/libapreq2/module/apache/t/c-modules/apreq_request_test/0000755000175100017510000000000012706745114025123 5ustar ondrejondrejrapache-1.2.8/libapreq2/module/apache/t/c-modules/apreq_request_test/mod_apreq_request_test.c0000644000175100017510000000416012706745114032046 0ustar ondrejondrej/* ** Copyright 2003-2005 The Apache Software Foundation ** ** Licensed under the Apache License, Version 2.0 (the "License"); ** you may not use this file except in compliance with the License. ** You may obtain a copy of the License at ** ** http://www.apache.org/licenses/LICENSE-2.0 ** ** Unless required by applicable law or agreed to in writing, software ** distributed under the License is distributed on an "AS IS" BASIS, ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ** See the License for the specific language governing permissions and ** limitations under the License. */ #ifdef CONFIG_FOR_HTTPD_TEST #if CONFIG_FOR_HTTPD_TEST APREQ_ReadLimit 500K SetHandler apreq_request_test #endif #endif #define APACHE_HTTPD_TEST_HANDLER apreq_request_test_handler #include "apache_httpd_test.h" #include "apreq_module_apache.h" #include "httpd.h" static int dump_table(void *ctx, const char *key, const char *value) { request_rec *r = ctx; ap_log_rerror(APLOG_MARK, APLOG_DEBUG, APR_SUCCESS, r, "%s => %s", key, value); ap_rprintf(r, "\t%s => %s\n", key, value); return 1; } static int apreq_request_test_handler(request_rec *r) { apreq_handle_t *req; const apr_table_t *t; apr_status_t s; if (strcmp(r->handler, "apreq_request_test") != 0) return DECLINED; req = apreq_handle_apache2(r); ap_log_rerror(APLOG_MARK, APLOG_DEBUG, APR_SUCCESS, r, "starting apreq_request_test"); s = ap_discard_request_body(r); ap_log_rerror(APLOG_MARK, APLOG_DEBUG, s, r, "discard request body"); ap_set_content_type(r, "text/plain"); ap_rputs("ARGS:\n",r); if (apreq_args(req, &t) == APR_SUCCESS) apr_table_do(dump_table, r, t, NULL); if (apreq_body(req, &t) == APR_SUCCESS) { ap_rputs("BODY:\n",r); apr_table_do(dump_table, r, t, NULL); } ap_log_rerror(APLOG_MARK, APLOG_DEBUG, APR_SUCCESS, r, "finished apreq_request_test"); return OK; } APACHE_HTTPD_TEST_MODULE(apreq_request_test); rapache-1.2.8/libapreq2/module/apache2/0000755000175100017510000000000012706745114017133 5ustar ondrejondrejrapache-1.2.8/libapreq2/module/apache2/Makefile.am0000644000175100017510000000270012706745114021166 0ustar ondrejondrejTEST_CONFIG_SCRIPT = package Apache::TestMM; filter_args(); generate_script("t/TEST") mod_apreq2_la_LDFLAGS = -export-dynamic -module -avoid-version \ `@APREQ_CONFIG@ --link-libtool --libs` @APR_LTFLAGS@ mod_apreq2_la_SOURCES = apreq_private_apache2.h handle.c filter.c pkgcfgdir = `@APACHE2_APXS@ -q SYSCONFDIR` pkgincludedir = `@APACHE2_APXS@ -q INCLUDEDIR`/@APREQ_LIBNAME@ pkglibdir = `@APACHE2_APXS@ -q LIBEXECDIR` if MAINTAINER_MODE AM_CPPFLAGS = -DAP_HAVE_DESIGNATED_INITIALIZER @APACHE2_INCLUDES@ @APR_INCLUDES@ else AM_CPPFLAGS = @APACHE2_INCLUDES@ @APR_INCLUDES@ endif if BUILD_HTTPD # XXX FIXME: static builds don't work anymore # mod_apreq2 needs to be built from httpd-2.X, e.g. # # % cd ../httpd-2.X; # % ./configure --with-module=filters:../httpd-apreq-2/module/apache2/mod_apreq2.c ... # # See the INSTALL file for details. @APACHE2_HTTPD@: cd @APACHE2_SRC@ && $(MAKE) all-local: @APACHE2_HTTPD@ else pkginclude_HEADERS = apreq_module_apache2.h pkglib_LTLIBRARIES = mod_apreq2.la install-exec-local : @echo "----------------------------------------------------------------------" @echo "Before you can use mod_apreq2, you must ensure that an appropriate" @echo "\"LoadModule\" line appears in your webserver's config file:" @echo "$(pkgcfgdir)/httpd.conf" @echo @echo "LoadModule apreq_module $(pkglibdir)/mod_apreq2.so" @echo "----------------------------------------------------------------------" endif rapache-1.2.8/libapreq2/module/apache2/Makefile.in0000644000175100017510000003244712706745114021212 0ustar ondrejondrej# Makefile.in generated by automake 1.6.3 from Makefile.am. # @configure_input@ # Copyright 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002 # 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@ SHELL = @SHELL@ srcdir = @srcdir@ top_srcdir = @top_srcdir@ VPATH = @srcdir@ prefix = @prefix@ exec_prefix = @exec_prefix@ bindir = @bindir@ sbindir = @sbindir@ libexecdir = @libexecdir@ datadir = @datadir@ sysconfdir = @sysconfdir@ sharedstatedir = @sharedstatedir@ localstatedir = @localstatedir@ libdir = @libdir@ infodir = @infodir@ mandir = @mandir@ includedir = @includedir@ oldincludedir = /usr/include pkgdatadir = $(datadir)/@PACKAGE@ top_builddir = ../.. ACLOCAL = @ACLOCAL@ AUTOCONF = @AUTOCONF@ AUTOMAKE = @AUTOMAKE@ AUTOHEADER = @AUTOHEADER@ am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd INSTALL = @INSTALL@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_DATA = @INSTALL_DATA@ install_sh_DATA = $(install_sh) -c -m 644 install_sh_PROGRAM = $(install_sh) -c install_sh_SCRIPT = $(install_sh) -c INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_HEADER = $(INSTALL_DATA) transform = @program_transform_name@ NORMAL_INSTALL = : PRE_INSTALL = : POST_INSTALL = : NORMAL_UNINSTALL = : PRE_UNINSTALL = : POST_UNINSTALL = : host_alias = @host_alias@ host_triplet = @host@ EXEEXT = @EXEEXT@ OBJEXT = @OBJEXT@ PATH_SEPARATOR = @PATH_SEPARATOR@ pkglibdir = `@APACHE2_APXS@ -q LIBEXECDIR` pkgincludedir = `@APACHE2_APXS@ -q INCLUDEDIR`/@APREQ_LIBNAME@ AMTAR = @AMTAR@ APACHE1_APXS = @APACHE1_APXS@ APACHE2_APXS = @APACHE2_APXS@ APACHE2_HTTPD = @APACHE2_HTTPD@ APACHE2_INCLUDES = @APACHE2_INCLUDES@ APACHE2_SRC = @APACHE2_SRC@ APREQ_CONFIG = @APREQ_CONFIG@ APREQ_DOTTED_VERSION = @APREQ_DOTTED_VERSION@ APREQ_LIBNAME = @APREQ_LIBNAME@ APREQ_LIBTOOL_VERSION = @APREQ_LIBTOOL_VERSION@ APREQ_MAJOR_VERSION = @APREQ_MAJOR_VERSION@ APR_CONFIG = @APR_CONFIG@ APR_INCLUDES = @APR_INCLUDES@ APR_LA = @APR_LA@ APR_LDFLAGS = @APR_LDFLAGS@ APR_LIBS = @APR_LIBS@ APR_LTFLAGS = @APR_LTFLAGS@ APU_CONFIG = @APU_CONFIG@ APU_LA = @APU_LA@ AR = @AR@ AS = @AS@ AWK = @AWK@ CC = @CC@ CXX = @CXX@ CXXCPP = @CXXCPP@ DEPDIR = @DEPDIR@ DLLTOOL = @DLLTOOL@ ECHO = @ECHO@ EGREP = @EGREP@ F77 = @F77@ GCJ = @GCJ@ GCJFLAGS = @GCJFLAGS@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ LIBTOOL = @LIBTOOL@ LN_S = @LN_S@ MAINT = @MAINT@ OBJDUMP = @OBJDUMP@ PACKAGE = @PACKAGE@ PERL = @PERL@ PERL_OPTS = @PERL_OPTS@ RANLIB = @RANLIB@ RC = @RC@ STRIP = @STRIP@ VERSION = @VERSION@ am__include = @am__include@ am__quote = @am__quote@ install_sh = @install_sh@ TEST_CONFIG_SCRIPT = package Apache::TestMM; filter_args(); generate_script("t/TEST") mod_apreq2_la_LDFLAGS = -export-dynamic -module -avoid-version \ `@APREQ_CONFIG@ --link-libtool --libs` @APR_LTFLAGS@ mod_apreq2_la_SOURCES = apreq_private_apache2.h handle.c filter.c pkgcfgdir = `@APACHE2_APXS@ -q SYSCONFDIR` @MAINTAINER_MODE_TRUE@AM_CPPFLAGS = -DAP_HAVE_DESIGNATED_INITIALIZER @APACHE2_INCLUDES@ @APR_INCLUDES@ @MAINTAINER_MODE_FALSE@AM_CPPFLAGS = @APACHE2_INCLUDES@ @APR_INCLUDES@ @BUILD_HTTPD_FALSE@pkginclude_HEADERS = apreq_module_apache2.h @BUILD_HTTPD_FALSE@pkglib_LTLIBRARIES = mod_apreq2.la subdir = module/apache2 mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs CONFIG_HEADER = $(top_builddir)/include/apreq_config.h CONFIG_CLEAN_FILES = LTLIBRARIES = $(pkglib_LTLIBRARIES) mod_apreq2_la_LIBADD = am_mod_apreq2_la_OBJECTS = handle.lo filter.lo mod_apreq2_la_OBJECTS = $(am_mod_apreq2_la_OBJECTS) DEFS = @DEFS@ DEFAULT_INCLUDES = -I. -I$(srcdir) -I$(top_builddir)/include CPPFLAGS = @CPPFLAGS@ LDFLAGS = @LDFLAGS@ LIBS = @LIBS@ depcomp = $(SHELL) $(top_srcdir)/depcomp am__depfiles_maybe = depfiles @AMDEP_TRUE@DEP_FILES = ./$(DEPDIR)/filter.Plo ./$(DEPDIR)/handle.Plo COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) LTCOMPILE = $(LIBTOOL) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) \ $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) CCLD = $(CC) LINK = $(LIBTOOL) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ $(AM_LDFLAGS) $(LDFLAGS) -o $@ CFLAGS = @CFLAGS@ DIST_SOURCES = $(mod_apreq2_la_SOURCES) HEADERS = $(pkginclude_HEADERS) DIST_COMMON = $(pkginclude_HEADERS) Makefile.am Makefile.in SOURCES = $(mod_apreq2_la_SOURCES) all: all-am .SUFFIXES: .SUFFIXES: .c .lo .o .obj $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ Makefile.am $(top_srcdir)/configure.ac $(ACLOCAL_M4) cd $(top_srcdir) && \ $(AUTOMAKE) --gnu module/apache2/Makefile Makefile: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.in $(top_builddir)/config.status cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe) pkglibLTLIBRARIES_INSTALL = $(INSTALL) install-pkglibLTLIBRARIES: $(pkglib_LTLIBRARIES) @$(NORMAL_INSTALL) $(mkinstalldirs) $(DESTDIR)$(pkglibdir) @list='$(pkglib_LTLIBRARIES)'; for p in $$list; do \ if test -f $$p; then \ f="`echo $$p | sed -e 's|^.*/||'`"; \ echo " $(LIBTOOL) --mode=install $(pkglibLTLIBRARIES_INSTALL) $(INSTALL_STRIP_FLAG) $$p $(DESTDIR)$(pkglibdir)/$$f"; \ $(LIBTOOL) --mode=install $(pkglibLTLIBRARIES_INSTALL) $(INSTALL_STRIP_FLAG) $$p $(DESTDIR)$(pkglibdir)/$$f; \ else :; fi; \ done uninstall-pkglibLTLIBRARIES: @$(NORMAL_UNINSTALL) @list='$(pkglib_LTLIBRARIES)'; for p in $$list; do \ p="`echo $$p | sed -e 's|^.*/||'`"; \ echo " $(LIBTOOL) --mode=uninstall rm -f $(DESTDIR)$(pkglibdir)/$$p"; \ $(LIBTOOL) --mode=uninstall rm -f $(DESTDIR)$(pkglibdir)/$$p; \ done clean-pkglibLTLIBRARIES: -test -z "$(pkglib_LTLIBRARIES)" || rm -f $(pkglib_LTLIBRARIES) @list='$(pkglib_LTLIBRARIES)'; for p in $$list; do \ dir="`echo $$p | sed -e 's|/[^/]*$$||'`"; \ test -z "$dir" && dir=.; \ echo "rm -f \"$${dir}/so_locations\""; \ rm -f "$${dir}/so_locations"; \ done mod_apreq2.la: $(mod_apreq2_la_OBJECTS) $(mod_apreq2_la_DEPENDENCIES) $(LINK) -rpath $(pkglibdir) $(mod_apreq2_la_LDFLAGS) $(mod_apreq2_la_OBJECTS) $(mod_apreq2_la_LIBADD) $(LIBS) mostlyclean-compile: -rm -f *.$(OBJEXT) core *.core distclean-compile: -rm -f *.tab.c @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/filter.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/handle.Plo@am__quote@ distclean-depend: -rm -rf ./$(DEPDIR) .c.o: @AMDEP_TRUE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@ depfile='$(DEPDIR)/$*.Po' tmpdepfile='$(DEPDIR)/$*.TPo' @AMDEPBACKSLASH@ @AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ $(COMPILE) -c `test -f '$<' || echo '$(srcdir)/'`$< .c.obj: @AMDEP_TRUE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@ depfile='$(DEPDIR)/$*.Po' tmpdepfile='$(DEPDIR)/$*.TPo' @AMDEPBACKSLASH@ @AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ $(COMPILE) -c `cygpath -w $<` .c.lo: @AMDEP_TRUE@ source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@ depfile='$(DEPDIR)/$*.Plo' tmpdepfile='$(DEPDIR)/$*.TPlo' @AMDEPBACKSLASH@ @AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ $(LTCOMPILE) -c -o $@ `test -f '$<' || echo '$(srcdir)/'`$< CCDEPMODE = @CCDEPMODE@ mostlyclean-libtool: -rm -f *.lo clean-libtool: -rm -rf .libs _libs distclean-libtool: -rm -f libtool uninstall-info-am: pkgincludeHEADERS_INSTALL = $(INSTALL_HEADER) install-pkgincludeHEADERS: $(pkginclude_HEADERS) @$(NORMAL_INSTALL) $(mkinstalldirs) $(DESTDIR)$(pkgincludedir) @list='$(pkginclude_HEADERS)'; for p in $$list; do \ if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ f="`echo $$p | sed -e 's|^.*/||'`"; \ echo " $(pkgincludeHEADERS_INSTALL) $$d$$p $(DESTDIR)$(pkgincludedir)/$$f"; \ $(pkgincludeHEADERS_INSTALL) $$d$$p $(DESTDIR)$(pkgincludedir)/$$f; \ done uninstall-pkgincludeHEADERS: @$(NORMAL_UNINSTALL) @list='$(pkginclude_HEADERS)'; for p in $$list; do \ f="`echo $$p | sed -e 's|^.*/||'`"; \ echo " rm -f $(DESTDIR)$(pkgincludedir)/$$f"; \ rm -f $(DESTDIR)$(pkgincludedir)/$$f; \ done ETAGS = etags ETAGSFLAGS = tags: TAGS 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; } \ END { for (i in files) print i; }'`; \ mkid -fID $$unique TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ $(TAGS_FILES) $(LISP) tags=; \ here=`pwd`; \ 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; } \ END { for (i in files) print i; }'`; \ test -z "$(ETAGS_ARGS)$$tags$$unique" \ || $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ $$tags $$unique GTAGS: here=`$(am__cd) $(top_builddir) && pwd` \ && cd $(top_srcdir) \ && gtags -i $(GTAGS_ARGS) $$here distclean-tags: -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) top_distdir = ../.. distdir = $(top_distdir)/$(PACKAGE)-$(VERSION) distdir: $(DISTFILES) @list='$(DISTFILES)'; for file in $$list; do \ if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ dir=`echo "$$file" | sed -e 's,/[^/]*$$,,'`; \ if test "$$dir" != "$$file" && test "$$dir" != "."; then \ dir="/$$dir"; \ $(mkinstalldirs) "$(distdir)$$dir"; \ else \ dir=''; \ fi; \ if test -d $$d/$$file; then \ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \ fi; \ cp -pR $$d/$$file $(distdir)$$dir || exit 1; \ else \ test -f $(distdir)/$$file \ || cp -p $$d/$$file $(distdir)/$$file \ || exit 1; \ fi; \ done check-am: all-am check: check-am all-am: Makefile $(LTLIBRARIES) $(HEADERS) all-local installdirs: $(mkinstalldirs) $(DESTDIR)$(pkglibdir) $(DESTDIR)$(pkgincludedir) 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_STRIP_FLAG=-s \ `test -z '$(STRIP)' || \ echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install mostlyclean-generic: clean-generic: distclean-generic: -rm -f Makefile $(CONFIG_CLEAN_FILES) maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." clean: clean-am clean-am: clean-generic clean-libtool clean-pkglibLTLIBRARIES \ mostlyclean-am distclean: distclean-am distclean-am: clean-am distclean-compile distclean-depend \ distclean-generic distclean-libtool distclean-tags dvi: dvi-am dvi-am: info: info-am info-am: install-data-am: install-pkgincludeHEADERS install-exec-am: install-exec-local install-pkglibLTLIBRARIES install-info: install-info-am install-man: installcheck-am: maintainer-clean: maintainer-clean-am maintainer-clean-am: distclean-am maintainer-clean-generic mostlyclean: mostlyclean-am mostlyclean-am: mostlyclean-compile mostlyclean-generic \ mostlyclean-libtool uninstall-am: uninstall-info-am uninstall-pkgincludeHEADERS \ uninstall-pkglibLTLIBRARIES .PHONY: GTAGS all all-am all-local check check-am clean clean-generic \ clean-libtool clean-pkglibLTLIBRARIES distclean \ distclean-compile distclean-depend distclean-generic \ distclean-libtool distclean-tags distdir dvi dvi-am info \ info-am install install-am install-data install-data-am \ install-exec install-exec-am install-exec-local install-info \ install-info-am install-man install-pkgincludeHEADERS \ install-pkglibLTLIBRARIES install-strip installcheck \ installcheck-am installdirs maintainer-clean \ maintainer-clean-generic mostlyclean mostlyclean-compile \ mostlyclean-generic mostlyclean-libtool tags uninstall \ uninstall-am uninstall-info-am uninstall-pkgincludeHEADERS \ uninstall-pkglibLTLIBRARIES # XXX FIXME: static builds don't work anymore # mod_apreq2 needs to be built from httpd-2.X, e.g. # # % cd ../httpd-2.X; # % ./configure --with-module=filters:../httpd-apreq-2/module/apache2/mod_apreq2.c ... # # See the INSTALL file for details. @BUILD_HTTPD_TRUE@@APACHE2_HTTPD@: @BUILD_HTTPD_TRUE@ cd @APACHE2_SRC@ && $(MAKE) @BUILD_HTTPD_TRUE@all-local: @APACHE2_HTTPD@ @BUILD_HTTPD_FALSE@install-exec-local : @BUILD_HTTPD_FALSE@ @echo "----------------------------------------------------------------------" @BUILD_HTTPD_FALSE@ @echo "Before you can use mod_apreq2, you must ensure that an appropriate" @BUILD_HTTPD_FALSE@ @echo "\"LoadModule\" line appears in your webserver's config file:" @BUILD_HTTPD_FALSE@ @echo "$(pkgcfgdir)/httpd.conf" @BUILD_HTTPD_FALSE@ @echo @BUILD_HTTPD_FALSE@ @echo "LoadModule apreq_module $(pkglibdir)/mod_apreq2.so" @BUILD_HTTPD_FALSE@ @echo "----------------------------------------------------------------------" # 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: rapache-1.2.8/libapreq2/module/apache2/apreq_module_apache2.h0000644000175100017510000001140612706745114023346 0ustar ondrejondrej/* ** Copyright 2003-2005 The Apache Software Foundation ** ** Licensed under the Apache License, Version 2.0 (the "License"); ** you may not use this file except in compliance with the License. ** You may obtain a copy of the License at ** ** http://www.apache.org/licenses/LICENSE-2.0 ** ** Unless required by applicable law or agreed to in writing, software ** distributed under the License is distributed on an "AS IS" BASIS, ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ** See the License for the specific language governing permissions and ** limitations under the License. */ #ifndef APREQ_APACHE2_H #define APREQ_APACHE2_H #include "apreq_module.h" #include #ifdef __cplusplus extern "C" { #endif /** * @defgroup mod_apreq2 Apache 2.X Filter Module * @ingroup apreq_module * @brief mod_apreq2 - DSO that ties libapreq2 to Apache HTTPD 2.X. * * mod_apreq2 provides the "APREQ2" input filter for using libapreq2 * (and allow its parsed data structures to be shared) within * the Apache 2.X webserver. Using it, libapreq2 works properly * in every phase of the HTTP request, from translation handlers * to output filters, and even for subrequests / internal redirects. * *
* *

Activating mod_apreq2 in Apache 2.X

* * The installation process triggered by * % make install * will not modify your webserver's config file. Hence, * be sure you activate it on startup by adding a LoadModule directive * to your webserver config; e.g. * * @code * * LoadModule modules/mod_apreq2.so * * @endcode * * The mod_apreq2 filter is named "APREQ2", and may be used in Apache's * input filter directives, e.g. * @code * * AddInputFilter APREQ2 # or * SetInputFilter APREQ2 * * @endcode * * However, this is not required because libapreq2 will add the filter (only) * if it's necessary. You just need to ensure that your module invokes * apreq_handle_apache2() before the content handler ultimately reads * from the input filter chain. It is important to realize that no * matter how the input filters are initially arranged, the APREQ2 filter * will attempt to reposition itself to be the last input filter to read the * data. * * If you want to use other input filters to transform the incoming HTTP * request data, is important to register those filters with Apache * as having type AP_FTYPE_CONTENT_SET or AP_FTYPE_RESOURCE. Due to the * limitations of Apache's current input filter design, types higher than * AP_FTYPE_CONTENT_SET may not work properly whenever the apreq filter is * active. * * This is especially true when a content handler uses libapreq2 to parse * some of the post data before doing an internal redirect. Any input * filter subsequently added to the redirected request will bypass the * original apreq filter (and therefore lose access to some of the original * post data), unless its type is less than the type of the apreq filter * (currently AP_FTYPE_PROTOCOL-1). * * *

Server Configuration Directives

* * * * * * * * * * * * * * * * * * * * * * * * * * *
Per-directory commands for mod_apreq2
DirectiveContextDefaultDescription
APREQ2_ReadLimitdirectory #APREQ_DEFAULT_READ_LIMIT Maximum number of bytes mod_apreq2 will send off to libapreq2 * for parsing. mod_apreq2 will log this event and subsequently * remove itself from the filter chain. *
APREQ2_BrigadeLimitdirectory#APREQ_DEFAULT_BRIGADE_LIMIT Maximum number of bytes mod_apreq2 will let accumulate * within the heap-buckets in a brigade. Excess data will be * spooled to an appended file bucket. *
APREQ2_TempDirdirectoryNULL Sets the location of the temporary directory apreq will use to spool * overflow brigade data (based on the APREQ2_BrigadeLimit setting). * If left unset, libapreq2 will select a platform-specific location * via apr_temp_dir_get(). *
* *

Implementation Details

*
 *   XXX apreq as a normal input filter
 *   XXX apreq as a "virtual" content handler.
 *   XXX apreq as a transparent "tee".
 *   XXX apreq parser registration in post_config
 * 
* * @{ */ /** * Create an apreq handle which communicates with an Apache 2.X * request_rec. */ APREQ_DECLARE(apreq_handle_t*) apreq_handle_apache2(request_rec *r); /** @} */ #ifdef __cplusplus } #endif #endif rapache-1.2.8/libapreq2/module/apache2/apreq_private_apache2.h0000644000175100017510000000354612706745114023541 0ustar ondrejondrejextern module AP_MODULE_DECLARE_DATA apreq_module; #define APREQ_FILTER_NAME "apreq2" struct dir_config { const char *temp_dir; apr_uint64_t read_limit; apr_size_t brigade_limit; }; /* The "warehouse", stored in r->request_config */ struct apache2_handle { apreq_handle_t handle; request_rec *r; apr_table_t *jar, *args; apr_status_t jar_status, args_status; ap_filter_t *f; }; /* Tracks the apreq filter state */ struct filter_ctx { apr_bucket_brigade *bb; /* input brigade that's passed to the parser */ apr_bucket_brigade *bbtmp; /* temporary copy of bb, destined for the spool */ apr_bucket_brigade *spool; /* copied prefetch data for downstream filters */ apreq_parser_t *parser; apreq_hook_t *hook_queue; apreq_hook_t *find_param; apr_table_t *body; apr_status_t body_status; apr_status_t filter_error; apr_uint64_t bytes_read; /* Total bytes read into this filter. */ apr_uint64_t read_limit; /* Max bytes the filter may show to parser */ apr_size_t brigade_limit; const char *temp_dir; }; apr_status_t apreq_filter_prefetch(ap_filter_t *f, apr_off_t readbytes); apr_status_t apreq_filter(ap_filter_t *f, apr_bucket_brigade *bb, ap_input_mode_t mode, apr_read_type_e block, apr_off_t readbytes); void apreq_filter_make_context(ap_filter_t *f); void apreq_filter_init_context(ap_filter_t *f); APR_INLINE static void apreq_filter_relocate(ap_filter_t *f) { request_rec *r = f->r; if (f != r->input_filters) { ap_filter_t *top = r->input_filters; ap_remove_input_filter(f); r->input_filters = f; f->next = top; } } rapache-1.2.8/libapreq2/module/apache2/filter.c0000644000175100017510000004010512706745114020564 0ustar ondrejondrej/* ** Copyright 2003-2005 The Apache Software Foundation ** ** Licensed under the Apache License, Version 2.0 (the "License"); ** you may not use this file except in compliance with the License. ** You may obtain a copy of the License at ** ** http://www.apache.org/licenses/LICENSE-2.0 ** ** Unless required by applicable law or agreed to in writing, software ** distributed under the License is distributed on an "AS IS" BASIS, ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ** See the License for the specific language governing permissions and ** limitations under the License. */ #include "assert.h" #include "httpd.h" #include "http_config.h" #include "http_log.h" #include "util_filter.h" #include "apr_tables.h" #include "apr_buckets.h" #include "http_request.h" #include "apr_strings.h" #include "apreq_module_apache2.h" #include "apreq_private_apache2.h" #include "apreq_error.h" #include "apreq_util.h" static void *apreq_create_dir_config(apr_pool_t *p, char *d) { /* d == OR_ALL */ struct dir_config *dc = apr_palloc(p, sizeof *dc); dc->temp_dir = NULL; dc->read_limit = (apr_uint64_t)-1; dc->brigade_limit = APREQ_DEFAULT_BRIGADE_LIMIT; return dc; } static void *apreq_merge_dir_config(apr_pool_t *p, void *a_, void *b_) { struct dir_config *a = a_, *b = b_, *c = apr_palloc(p, sizeof *c); c->temp_dir = (b->temp_dir != NULL) /* overrides ok */ ? b->temp_dir : a->temp_dir; c->brigade_limit = (b->brigade_limit == (apr_size_t)-1) /* overrides ok */ ? a->brigade_limit : b->brigade_limit; c->read_limit = (b->read_limit < a->read_limit) /* why min? */ ? b->read_limit : a->read_limit; return c; } static const char *apreq_set_temp_dir(cmd_parms *cmd, void *data, const char *arg) { struct dir_config *conf = data; const char *err = ap_check_cmd_context(cmd, NOT_IN_LIMIT); if (err != NULL) return err; conf->temp_dir = arg; return NULL; } static const char *apreq_set_read_limit(cmd_parms *cmd, void *data, const char *arg) { struct dir_config *conf = data; const char *err = ap_check_cmd_context(cmd, NOT_IN_LIMIT); if (err != NULL) return err; conf->read_limit = apreq_atoi64f(arg); return NULL; } static const char *apreq_set_brigade_limit(cmd_parms *cmd, void *data, const char *arg) { struct dir_config *conf = data; const char *err = ap_check_cmd_context(cmd, NOT_IN_LIMIT); if (err != NULL) return err; conf->brigade_limit = apreq_atoi64f(arg); return NULL; } static const command_rec apreq_cmds[] = { AP_INIT_TAKE1("APREQ2_TempDir", apreq_set_temp_dir, NULL, OR_ALL, "Default location of temporary directory"), AP_INIT_TAKE1("APREQ2_ReadLimit", apreq_set_read_limit, NULL, OR_ALL, "Maximum amount of data that will be fed into a parser."), AP_INIT_TAKE1("APREQ2_BrigadeLimit", apreq_set_brigade_limit, NULL, OR_ALL, "Maximum in-memory bytes a brigade may use."), { NULL } }; void apreq_filter_init_context(ap_filter_t *f) { request_rec *r = f->r; struct filter_ctx *ctx = f->ctx; apr_bucket_alloc_t *ba = r->connection->bucket_alloc; const char *cl_header; if (r->method_number == M_GET) { /* Don't parse GET (this protects against subrequest body parsing). */ ctx->body_status = APREQ_ERROR_NODATA; return; } cl_header = apr_table_get(r->headers_in, "Content-Length"); if (cl_header != NULL) { char *dummy; apr_uint64_t content_length = apr_strtoi64(cl_header,&dummy,0); if (dummy == NULL || *dummy != 0) { ap_log_rerror(APLOG_MARK, APLOG_ERR, APR_EGENERAL, r, "Invalid Content-Length header (%s)", cl_header); ctx->body_status = APREQ_ERROR_BADHEADER; return; } else if (content_length > ctx->read_limit) { ap_log_rerror(APLOG_MARK, APLOG_ERR, APR_EGENERAL, r, "Content-Length header (%s) exceeds configured " "max_body limit (%" APR_UINT64_T_FMT ")", cl_header, ctx->read_limit); ctx->body_status = APREQ_ERROR_OVERLIMIT; return; } } if (ctx->parser == NULL) { const char *ct_header = apr_table_get(r->headers_in, "Content-Type"); if (ct_header != NULL) { apreq_parser_function_t pf = apreq_parser(ct_header); if (pf != NULL) { ctx->parser = apreq_parser_make(r->pool, ba, ct_header, pf, ctx->brigade_limit, ctx->temp_dir, ctx->hook_queue, NULL); } else { ctx->body_status = APREQ_ERROR_NOPARSER; return; } } else { ctx->body_status = APREQ_ERROR_NOHEADER; return; } } else { if (ctx->parser->brigade_limit > ctx->brigade_limit) ctx->parser->brigade_limit = ctx->brigade_limit; if (ctx->temp_dir != NULL) ctx->parser->temp_dir = ctx->temp_dir; if (ctx->hook_queue != NULL) apreq_parser_add_hook(ctx->parser, ctx->hook_queue); } ctx->hook_queue = NULL; ctx->bb = apr_brigade_create(r->pool, ba); ctx->bbtmp = apr_brigade_create(r->pool, ba); ctx->spool = apr_brigade_create(r->pool, ba); ctx->body = apr_table_make(r->pool, APREQ_DEFAULT_NELTS); ctx->body_status = APR_INCOMPLETE; } /* * Situations to contend with: * * 1) Often the filter will be added by the content handler itself, * so the apreq_filter_init hook will not be run. * 2) If an auth handler uses apreq, the apreq_filter will ensure * it's part of the protocol filters. apreq_filter_init does NOT need * to notify the protocol filter that it must not continue parsing, * the apreq filter can perform this check itself. apreq_filter_init * just needs to ensure cfg->f does not point at it. * 3) If req->proto_input_filters and req->input_filters are apreq * filters, and req->input_filters->next == req->proto_input_filters, * it is safe for apreq_filter to "steal" the proto filter's context * and subsequently drop it from the chain. */ /* Examines the input_filter chain and moves the apreq filter(s) around * before the filter chain is stacked by ap_get_brigade. */ static apr_status_t apreq_filter_init(ap_filter_t *f) { request_rec *r = f->r; struct filter_ctx *ctx = f->ctx; struct apache2_handle *handle = (struct apache2_handle *)apreq_handle_apache2(r); /* Don't parse GET (this protects against subrequest body parsing). */ if (f->r->method_number == M_GET) return APR_SUCCESS; if (ctx == NULL || ctx->body_status == APR_EINIT) { if (f == r->input_filters) { handle->f = f; } else if (r->input_filters->frec->filter_func.in_func == apreq_filter) { ap_log_rerror(APLOG_MARK, APLOG_DEBUG, APR_SUCCESS, r, "removing intermediate apreq filter"); if (handle->f == f) handle->f = r->input_filters; ap_remove_input_filter(f); } else { ap_log_rerror(APLOG_MARK, APLOG_DEBUG, APR_SUCCESS, r, "relocating intermediate apreq filter"); apreq_filter_relocate(f); handle->f = f; } return APR_SUCCESS; } /* else this is a protocol filter which may still be active. * if it is, we must deregister it now. */ if (handle->f == f) { ap_log_rerror(APLOG_MARK, APLOG_DEBUG, APR_SUCCESS, r, "disabling stale protocol filter"); if (ctx->body_status == APR_INCOMPLETE) ctx->body_status = APREQ_ERROR_INTERRUPT; handle->f = NULL; } return APR_SUCCESS; } apr_status_t apreq_filter_prefetch(ap_filter_t *f, apr_off_t readbytes) { struct filter_ctx *ctx = f->ctx; request_rec *r = f->r; apr_status_t rv; apr_off_t len; if (ctx->body_status == APR_EINIT) apreq_filter_init_context(f); if (ctx->body_status != APR_INCOMPLETE || readbytes == 0) return ctx->body_status; ap_log_rerror(APLOG_MARK, APLOG_DEBUG, APR_SUCCESS, r, "prefetching %" APR_OFF_T_FMT " bytes", readbytes); rv = ap_get_brigade(f->next, ctx->bb, AP_MODE_READBYTES, APR_BLOCK_READ, readbytes); if (rv != APR_SUCCESS) { ap_log_rerror(APLOG_MARK, APLOG_ERR, rv, r, "ap_get_brigade failed during prefetch"); ctx->filter_error = rv; return ctx->body_status = APREQ_ERROR_GENERAL; } apreq_brigade_setaside(ctx->bb, r->pool); apreq_brigade_copy(ctx->bbtmp, ctx->bb); rv = apreq_brigade_concat(r->pool, ctx->temp_dir, ctx->brigade_limit, ctx->spool, ctx->bbtmp); if (rv != APR_SUCCESS && rv != APR_EOF) { ap_log_rerror(APLOG_MARK, APLOG_ERR, rv, r, "apreq_brigade_concat failed; TempDir problem?"); ctx->filter_error = APR_EGENERAL; return ctx->body_status = rv; } /* Adding "f" to the protocol filter chain ensures the * spooled data is preserved across internal redirects. */ if (f != r->proto_input_filters) { ap_filter_t *in; for (in = r->input_filters; in != r->proto_input_filters; in = in->next) { if (f == in) { r->proto_input_filters = f; break; } } } apr_brigade_length(ctx->bb, 1, &len); ctx->bytes_read += len; if (ctx->bytes_read > ctx->read_limit) { ctx->body_status = APREQ_ERROR_OVERLIMIT; ap_log_rerror(APLOG_MARK, APLOG_ERR, ctx->body_status, r, "Bytes read (%" APR_UINT64_T_FMT ") exceeds configured read limit (%" APR_UINT64_T_FMT ")", ctx->bytes_read, ctx->read_limit); return ctx->body_status; } ctx->body_status = apreq_parser_run(ctx->parser, ctx->body, ctx->bb); apr_brigade_cleanup(ctx->bb); return ctx->body_status; } apr_status_t apreq_filter(ap_filter_t *f, apr_bucket_brigade *bb, ap_input_mode_t mode, apr_read_type_e block, apr_off_t readbytes) { request_rec *r = f->r; struct filter_ctx *ctx; apr_status_t rv; apr_off_t len; switch (mode) { case AP_MODE_READBYTES: /* only the modes above are supported */ break; case AP_MODE_EXHAUSTIVE: /* not worth supporting at this level */ case AP_MODE_GETLINE: /* chunked trailers are b0rked in ap_http_filter */ return ap_get_brigade(f->next, bb, mode, block, readbytes); default: return APR_ENOTIMPL; } if (f->ctx == NULL) apreq_filter_make_context(f); ctx = f->ctx; if (ctx->body_status == APR_EINIT) apreq_filter_init_context(f); if (ctx->spool && !APR_BRIGADE_EMPTY(ctx->spool)) { apr_bucket *e; rv = apr_brigade_partition(ctx->spool, readbytes, &e); if (rv != APR_SUCCESS && rv != APR_INCOMPLETE) return rv; if (APR_BUCKET_IS_EOS(e)) e = APR_BUCKET_NEXT(e); apreq_brigade_move(bb, ctx->spool, e); return APR_SUCCESS; } else if (ctx->body_status != APR_INCOMPLETE) { if (ctx->filter_error) return ctx->filter_error; rv = ap_get_brigade(f->next, bb, mode, block, readbytes); ap_remove_input_filter(f); return rv; } rv = ap_get_brigade(f->next, bb, mode, block, readbytes); if (rv != APR_SUCCESS) return rv; apreq_brigade_copy(ctx->bb, bb); apr_brigade_length(bb, 1, &len); ctx->bytes_read += len; if (ctx->bytes_read > ctx->read_limit) { ctx->body_status = APREQ_ERROR_OVERLIMIT; ap_log_rerror(APLOG_MARK, APLOG_ERR, ctx->body_status, r, "Bytes read (%" APR_UINT64_T_FMT ") exceeds configured max_body limit (%" APR_UINT64_T_FMT ")", ctx->bytes_read, ctx->read_limit); } else { ctx->body_status = apreq_parser_run(ctx->parser, ctx->body, ctx->bb); apr_brigade_cleanup(ctx->bb); } return APR_SUCCESS; } static int apreq_pre_init(apr_pool_t *p, apr_pool_t *plog, apr_pool_t *ptemp, server_rec *base_server) { apr_status_t status; status = apreq_pre_initialize(p); if (status != APR_SUCCESS) { ap_log_error(APLOG_MARK, APLOG_STARTUP|APLOG_ERR, status, base_server, "Failed to pre-initialize libapreq2"); return HTTP_INTERNAL_SERVER_ERROR; } return OK; } static int apreq_post_init(apr_pool_t *p, apr_pool_t *plog, apr_pool_t *ptemp, server_rec *base_server) { apr_status_t status; status = apreq_post_initialize(p); if (status != APR_SUCCESS) { ap_log_error(APLOG_MARK, APLOG_STARTUP|APLOG_ERR, status, base_server, "Failed to post-initialize libapreq2"); return HTTP_INTERNAL_SERVER_ERROR; } return OK; } static void register_hooks (apr_pool_t *p) { /* APR_HOOK_FIRST because we want other modules to be able to * register parsers in their post_config hook via APR_HOOK_MIDDLE. */ ap_hook_post_config(apreq_pre_init, NULL, NULL, APR_HOOK_FIRST); /* APR_HOOK_LAST because we need to lock the default_parsers hash * (to prevent further modifications) before the server forks. */ ap_hook_post_config(apreq_post_init, NULL, NULL, APR_HOOK_LAST); ap_register_input_filter(APREQ_FILTER_NAME, apreq_filter, apreq_filter_init, AP_FTYPE_PROTOCOL-1); } /** @} */ module AP_MODULE_DECLARE_DATA apreq_module = { #line __LINE__ "mod_apreq2.c" STANDARD20_MODULE_STUFF, apreq_create_dir_config, apreq_merge_dir_config, NULL, NULL, apreq_cmds, register_hooks, }; void apreq_filter_make_context(ap_filter_t *f) { request_rec *r; struct filter_ctx *ctx; struct dir_config *d; r = f->r; d = ap_get_module_config(r->per_dir_config, &apreq_module); if (f == r->input_filters && r->proto_input_filters == f->next && f->next->frec->filter_func.in_func == apreq_filter && f->r->method_number != M_GET) { ctx = f->next->ctx; switch (ctx->body_status) { case APREQ_ERROR_INTERRUPT: ctx->body_status = APR_INCOMPLETE; /* fall thru */ case APR_SUCCESS: if (d != NULL) { ctx->temp_dir = d->temp_dir; ctx->read_limit = d->read_limit; ctx->brigade_limit = d->brigade_limit; if (ctx->parser != NULL) { ctx->parser->temp_dir = d->temp_dir; ctx->parser->brigade_limit = d->brigade_limit; } } ap_log_rerror(APLOG_MARK, APLOG_DEBUG, APR_SUCCESS, r, "stealing filter context"); f->ctx = ctx; r->proto_input_filters = f; ap_remove_input_filter(f->next); return; default: ap_log_rerror(APLOG_MARK, APLOG_DEBUG, ctx->body_status, r, "cannot steal context: bad filter status"); } } ctx = apr_pcalloc(r->pool, sizeof *ctx); ctx->body_status = APR_EINIT; if (d == NULL) { ctx->read_limit = (apr_uint64_t)-1; ctx->brigade_limit = APREQ_DEFAULT_BRIGADE_LIMIT; } else { ctx->temp_dir = d->temp_dir; ctx->read_limit = d->read_limit; ctx->brigade_limit = d->brigade_limit; } f->ctx = ctx; } rapache-1.2.8/libapreq2/module/apache2/handle.c0000644000175100017510000002471212706745114020540 0ustar ondrejondrej/* ** Copyright 2003-2005 The Apache Software Foundation ** ** Licensed under the Apache License, Version 2.0 (the "License"); ** you may not use this file except in compliance with the License. ** You may obtain a copy of the License at ** ** http://www.apache.org/licenses/LICENSE-2.0 ** ** Unless required by applicable law or agreed to in writing, software ** distributed under the License is distributed on an "AS IS" BASIS, ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ** See the License for the specific language governing permissions and ** limitations under the License. */ #include "assert.h" #include "httpd.h" #include "http_config.h" #include "http_log.h" #include "util_filter.h" #include "apr_tables.h" #include "apr_buckets.h" #include "http_request.h" #include "apr_strings.h" #include "apreq_module_apache2.h" #include "apreq_private_apache2.h" #include "apreq_error.h" APR_INLINE static ap_filter_t *get_apreq_filter(apreq_handle_t *handle) { struct apache2_handle *req = (struct apache2_handle *)handle; if (req->f == NULL) { req->f = ap_add_input_filter(APREQ_FILTER_NAME, NULL, req->r, req->r->connection); /* ap_add_input_filter does not guarantee cfg->f == r->input_filters, * so we reposition the new filter there as necessary. */ apreq_filter_relocate(req->f); } return req->f; } static apr_status_t apache2_jar(apreq_handle_t *handle, const apr_table_t **t) { struct apache2_handle *req = (struct apache2_handle*)handle; request_rec *r = req->r; if (req->jar_status == APR_EINIT) { const char *cookies = apr_table_get(r->headers_in, "Cookie"); if (cookies != NULL) { req->jar = apr_table_make(handle->pool, APREQ_DEFAULT_NELTS); req->jar_status = apreq_parse_cookie_header(handle->pool, req->jar, cookies); } else req->jar_status = APREQ_ERROR_NODATA; } *t = req->jar; return req->jar_status; } static apr_status_t apache2_args(apreq_handle_t *handle, const apr_table_t **t) { struct apache2_handle *req = (struct apache2_handle*)handle; request_rec *r = req->r; if (req->args_status == APR_EINIT) { if (r->args != NULL) { req->args = apr_table_make(handle->pool, APREQ_DEFAULT_NELTS); req->args_status = apreq_parse_query_string(handle->pool, req->args, r->args); } else req->args_status = APREQ_ERROR_NODATA; } *t = req->args; return req->args_status; } static apreq_cookie_t *apache2_jar_get(apreq_handle_t *handle, const char *name) { struct apache2_handle *req = (struct apache2_handle *)handle; const apr_table_t *t; const char *val; if (req->jar_status == APR_EINIT) apache2_jar(handle, &t); else t = req->jar; if (t == NULL) return NULL; val = apr_table_get(t, name); if (val == NULL) return NULL; return apreq_value_to_cookie(val); } static apreq_param_t *apache2_args_get(apreq_handle_t *handle, const char *name) { struct apache2_handle *req = (struct apache2_handle *)handle; const apr_table_t *t; const char *val; if (req->args_status == APR_EINIT) apache2_args(handle, &t); else t = req->args; if (t == NULL) return NULL; val = apr_table_get(t, name); if (val == NULL) return NULL; return apreq_value_to_param(val); } static apr_status_t apache2_body(apreq_handle_t *handle, const apr_table_t **t) { ap_filter_t *f = get_apreq_filter(handle); struct filter_ctx *ctx; if (f->ctx == NULL) apreq_filter_make_context(f); ctx = f->ctx; switch (ctx->body_status) { case APR_EINIT: apreq_filter_init_context(f); if (ctx->body_status != APR_INCOMPLETE) break; case APR_INCOMPLETE: while (apreq_filter_prefetch(f, APREQ_DEFAULT_READ_BLOCK_SIZE) == APR_INCOMPLETE) ; /*loop*/ } *t = ctx->body; return ctx->body_status; } static apreq_param_t *apache2_body_get(apreq_handle_t *handle, const char *name) { ap_filter_t *f = get_apreq_filter(handle); struct filter_ctx *ctx; const char *val; apreq_hook_t *h; if (f->ctx == NULL) apreq_filter_make_context(f); ctx = f->ctx; switch (ctx->body_status) { case APR_SUCCESS: val = apr_table_get(ctx->body, name); if (val != NULL) return apreq_value_to_param(val); return NULL; case APR_EINIT: apreq_filter_init_context(f); if (ctx->body_status != APR_INCOMPLETE) return NULL; apreq_filter_prefetch(f, APREQ_DEFAULT_READ_BLOCK_SIZE); case APR_INCOMPLETE: val = apr_table_get(ctx->body, name); if (val != NULL) return apreq_value_to_param(val); /* Not seen yet, so we need to scan for param while prefetching the body */ if (ctx->find_param == NULL) ctx->find_param = apreq_hook_make(handle->pool, apreq_hook_find_param, NULL, NULL); h = ctx->find_param; h->next = ctx->parser->hook; ctx->parser->hook = h; *(const char **)&h->ctx = name; do { apreq_filter_prefetch(f, APREQ_DEFAULT_READ_BLOCK_SIZE); if (h->ctx != name) { ctx->parser->hook = h->next; return h->ctx; } } while (ctx->body_status == APR_INCOMPLETE); ctx->parser->hook = h->next; return NULL; default: if (ctx->body == NULL) return NULL; val = apr_table_get(ctx->body, name); if (val != NULL) return apreq_value_to_param(val); return NULL; } /* not reached */ return NULL; } static apr_status_t apache2_parser_get(apreq_handle_t *handle, const apreq_parser_t **parser) { ap_filter_t *f = get_apreq_filter(handle); struct filter_ctx *ctx = f->ctx; if (ctx == NULL) { *parser = NULL; return APR_EINIT; } *parser = ctx->parser; return APR_SUCCESS; } static apr_status_t apache2_parser_set(apreq_handle_t *handle, apreq_parser_t *parser) { ap_filter_t *f = get_apreq_filter(handle); struct filter_ctx *ctx; if (f->ctx == NULL) apreq_filter_make_context(f); ctx = f->ctx; if (ctx->parser == NULL) { ctx->parser = parser; return APR_SUCCESS; } else return APREQ_ERROR_NOTEMPTY; } static apr_status_t apache2_hook_add(apreq_handle_t *handle, apreq_hook_t *hook) { ap_filter_t *f = get_apreq_filter(handle); struct filter_ctx *ctx; if (f->ctx == NULL) apreq_filter_make_context(f); ctx = f->ctx; if (ctx->parser != NULL) { return apreq_parser_add_hook(ctx->parser, hook); } else if (ctx->hook_queue != NULL) { apreq_hook_t *h = ctx->hook_queue; while (h->next != NULL) h = h->next; h->next = hook; } else { ctx->hook_queue = hook; } return APR_SUCCESS; } static apr_status_t apache2_brigade_limit_set(apreq_handle_t *handle, apr_size_t bytes) { ap_filter_t *f = get_apreq_filter(handle); struct filter_ctx *ctx; if (f->ctx == NULL) apreq_filter_make_context(f); ctx = f->ctx; if (ctx->body_status == APR_EINIT || ctx->brigade_limit > bytes) { ctx->brigade_limit = bytes; return APR_SUCCESS; } return APREQ_ERROR_MISMATCH; } static apr_status_t apache2_brigade_limit_get(apreq_handle_t *handle, apr_size_t *bytes) { ap_filter_t *f = get_apreq_filter(handle); struct filter_ctx *ctx; if (f->ctx == NULL) apreq_filter_make_context(f); ctx = f->ctx; *bytes = ctx->brigade_limit; return APR_SUCCESS; } static apr_status_t apache2_read_limit_set(apreq_handle_t *handle, apr_uint64_t bytes) { ap_filter_t *f = get_apreq_filter(handle); struct filter_ctx *ctx; if (f->ctx == NULL) apreq_filter_make_context(f); ctx = f->ctx; if (ctx->read_limit > bytes && ctx->bytes_read < bytes) { ctx->read_limit = bytes; return APR_SUCCESS; } return APREQ_ERROR_MISMATCH; } static apr_status_t apache2_read_limit_get(apreq_handle_t *handle, apr_uint64_t *bytes) { ap_filter_t *f = get_apreq_filter(handle); struct filter_ctx *ctx; if (f->ctx == NULL) apreq_filter_make_context(f); ctx = f->ctx; *bytes = ctx->read_limit; return APR_SUCCESS; } static apr_status_t apache2_temp_dir_set(apreq_handle_t *handle, const char *path) { ap_filter_t *f = get_apreq_filter(handle); struct filter_ctx *ctx; if (f->ctx == NULL) apreq_filter_make_context(f); ctx = f->ctx; // init vs incomplete state? if (ctx->temp_dir == NULL && ctx->bytes_read == 0) { if (path != NULL) ctx->temp_dir = apr_pstrdup(handle->pool, path); return APR_SUCCESS; } return APREQ_ERROR_NOTEMPTY; } static apr_status_t apache2_temp_dir_get(apreq_handle_t *handle, const char **path) { ap_filter_t *f = get_apreq_filter(handle); struct filter_ctx *ctx; if (f->ctx == NULL) apreq_filter_make_context(f); ctx = f->ctx; *path = ctx->parser ? ctx->parser->temp_dir : ctx->temp_dir; return APR_SUCCESS; } static APREQ_MODULE(apache2, 20050427); APREQ_DECLARE(apreq_handle_t *) apreq_handle_apache2(request_rec *r) { struct apache2_handle *req = ap_get_module_config(r->request_config, &apreq_module); if (req != NULL) { get_apreq_filter(&req->handle); return &req->handle; } req = apr_palloc(r->pool, sizeof *req); ap_set_module_config(r->request_config, &apreq_module, req); req->handle.module = &apache2_module; req->handle.pool = r->pool; req->handle.bucket_alloc = r->connection->bucket_alloc; req->r = r; req->args_status = req->jar_status = APR_EINIT; req->args = req->jar = NULL; req->f = NULL; get_apreq_filter(&req->handle); return &req->handle; } rapache-1.2.8/libapreq2/module/t/0000755000175100017510000000000012706745114016073 5ustar ondrejondrejrapache-1.2.8/libapreq2/module/t/TEST.PL0000644000175100017510000000623112706745114017111 0ustar ondrejondrejuse strict; use warnings FATAL => 'all'; use constant WIN32 => $^O eq 'MSWin32'; use Cwd; my $cwd = WIN32 ? Win32::GetLongPathName(cwd) : cwd; $cwd =~ m{^(.+)/module$} or die "Can't find base directory"; my $base_dir = $1; my $module_dir = "$base_dir/module"; my $mod_apreq2_dir = WIN32 ? "$base_dir/win32/libs" : "$module_dir/apache2/.libs"; use base 'Apache::TestRun'; $Apache::TestTrace::Level = 'debug'; main::->new->run(@ARGV); sub pre_configure { my $self = shift; # Don't load an installed mod_apreq* Apache::TestConfig::autoconfig_skip_module_add('mod_apreq.c'); Apache::TestConfig::autoconfig_skip_module_add('mod_apreq2.c'); } sub configure { my $self = shift; my $cfg = $self->{test_config}; # make sure Win32 uses the just-built libapreq2.dll if (WIN32) { $cfg->preamble(qq{LoadFile "$mod_apreq2_dir/libapreq2.dll"\n}); } $cfg->preamble(IfModule => '!mod_apreq2.c', qq(LoadModule apreq_module "$mod_apreq2_dir/mod_apreq2.so"\n)); bless $cfg, "My::TestConfig"; $self->SUPER::configure(); } package My::TestConfig; use Apache::TestTrace; use Apache::TestConfigC; use Config; use File::Spec; use constant WIN32 => $^O eq 'MSWin32'; use base 'Apache::TestConfig'; sub cmodules_configure { my $self = shift; my $dir = File::Spec->catdir($module_dir, 't', 'c-modules'); $self->SUPER::cmodules_configure($dir); } sub cmodules_httpd_conf { my $self = shift; debug "WRITING httpd.conf with " . join", ",map $_->{name}, @{$self->{cmodules}}; $self->SUPER::cmodules_httpd_conf(@_); } sub cmodules_write_makefile { my($self, $mod) = @_; my $dversion = $self->server->dversion; my $name = $mod->{name}; my $makefile = "$mod->{dir}/Makefile"; debug "WRITING $makefile for $name"; my $lib = $self->cmodules_build_so($name); my $fh = Symbol::gensym(); open $fh, ">$makefile" or die "open $makefile: $!"; if (WIN32) { require File::Spec; my @goners = map {$name . '.' . $_} qw(exp ilk lib pdb so lo); my $libs = join ' ', (map {'-l' . File::Spec->catfile($mod_apreq2_dir, $_)} qw(libapreq2.lib mod_apreq2.lib)); print $fh <{APXS} all: $lib $lib: $name.c \$(APXS) -I../../../apache2 -I../../../../include $libs -llibhttpd $dversion -p -I$self->{cmodules_dir} -c $name.c clean: -erase @goners vc60.pdb EOF } else { print $fh <{APXS} all: $lib $lib: $name.c \$(APXS) -L../../../../library -I../../../apache2 -I../../../../include -lapreq2 $dversion -I$self->{cmodules_dir} -c $name.c clean: -rm -rf $name.o $name.lo $name.slo $name.la .libs EOF } close $fh or die "close $makefile: $!"; } sub cmodules_makefile_vars { my $make = $ENV{MAKE} || $Config{make}; return < 'all'; use Apache::Test; use Apache::TestUtil; use Apache::TestConfig; use Apache::TestRequest qw(GET_BODY POST_BODY); my @key_len = (5, 100, 305); my @key_num = (5, 15, 26); my @keys = ('a'..'z'); my @big_key_len = (100, 500, 5000, 10000); my @big_key_num = (5, 15, 25); my @big_keys = ('a'..'z'); my $num_tests = @key_len * @key_num + @big_key_len * @big_key_num; $num_tests *= 2 if Apache::Test::have_ssl(); plan tests => $num_tests, have_lwp; my $location = "/apreq_big_request_test"; my $scheme = 'http'; START_TESTS: Apache::TestRequest::scheme($scheme); # GET for my $key_len (@key_len) { for my $key_num (@key_num) { my @query = (); my $len = 0; for my $key (@keys[0..($key_num-1)]) { my $pair = "$key=" . 'd' x $key_len; $len += length($pair) - 1; push @query, $pair; } my $query = join ";", @query; t_debug "# of keys : $key_num, key_len $key_len"; my $body = GET_BODY "$location?$query"; ok t_cmp($body, $len, "GET long query"); } } # POST for my $big_key_len (@big_key_len) { for my $big_key_num (@big_key_num) { my @query = (); my $len = 0; for my $big_key (@big_keys[0..($big_key_num-1)]) { my $pair = "$big_key=" . 'd' x $big_key_len; $len += length($pair) - 1; push @query, $pair; } my $query = join ";", @query; t_debug "# of keys : $big_key_num, big_key_len $big_key_len"; my $body = POST_BODY($location, content => $query); ok t_cmp($body, $len, "POST big data"); } } if (Apache::Test::have_ssl() and $scheme ne 'https') { $scheme = 'https'; goto START_TESTS; } rapache-1.2.8/libapreq2/module/t/c-modules/0000755000175100017510000000000012706745114017763 5ustar ondrejondrejrapache-1.2.8/libapreq2/module/t/c-modules/apreq_access_test/0000755000175100017510000000000012706745114023453 5ustar ondrejondrejrapache-1.2.8/libapreq2/module/t/c-modules/apreq_access_test/mod_apreq_access_test.c0000644000175100017510000000560112706745114030150 0ustar ondrejondrej/* ** Copyright 2003-2005 The Apache Software Foundation ** ** Licensed under the Apache License, Version 2.0 (the "License"); ** you may not use this file except in compliance with the License. ** You may obtain a copy of the License at ** ** http://www.apache.org/licenses/LICENSE-2.0 ** ** Unless required by applicable law or agreed to in writing, software ** distributed under the License is distributed on an "AS IS" BASIS, ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ** See the License for the specific language governing permissions and ** limitations under the License. */ #ifdef CONFIG_FOR_HTTPD_TEST #if CONFIG_FOR_HTTPD_TEST TestAccess test SetHandler apreq_request_test #endif #endif #define APACHE_HTTPD_TEST_ACCESS_CHECKER apreq_access_checker #define APACHE_HTTPD_TEST_COMMANDS access_cmds #define APACHE_HTTPD_TEST_PER_DIR_CREATE create_access_config #include "apache_httpd_test.h" #include "apreq_module_apache2.h" #include "httpd.h" #include "apr_strings.h" extern module AP_MODULE_DECLARE_DATA apreq_access_test_module; struct access_test_cfg { apr_pool_t *pool; const char *param; }; static const char *access_config(cmd_parms *cmd, void *dv, const char *arg) { struct access_test_cfg *cfg = (struct access_test_cfg *)dv; cfg->param = apr_pstrdup(cfg->pool, arg); return NULL; } static const command_rec access_cmds[] = { AP_INIT_TAKE1("TestAccess", access_config, NULL, OR_LIMIT, "'param'"), { NULL } }; static void *create_access_config(apr_pool_t *p, char *dummy) { struct access_test_cfg *cfg = apr_palloc(p, sizeof *cfg); cfg->pool = p; cfg->param = dummy; return cfg; } static int apreq_access_checker(request_rec *r) { apreq_handle_t *handle; apreq_param_t *param; struct access_test_cfg *cfg = (struct access_test_cfg *) ap_get_module_config(r->per_dir_config, &apreq_access_test_module); if (!cfg || !cfg->param) return DECLINED; handle = apreq_handle_apache2(r); param = apreq_param(handle, cfg->param); if (param != NULL) { ap_log_rerror(APLOG_MARK, APLOG_DEBUG, APR_SUCCESS, r, "ACCESS GRANTED: %s => %s", cfg->param, param->v.data); return OK; } else { const apr_table_t *t = apreq_params(handle, r->pool); if (t != NULL) { ap_log_rerror(APLOG_MARK, APLOG_DEBUG, APR_EGENERAL, r, "%s not found: parsing error detected (%d params)", cfg->param, apr_table_elts(t)->nelts); } else { ap_log_rerror(APLOG_MARK, APLOG_DEBUG, APR_EGENERAL, r, "%s not found: paring error detected (no param table)", cfg->param); } return HTTP_FORBIDDEN; } } APACHE_HTTPD_TEST_MODULE(apreq_access_test); rapache-1.2.8/libapreq2/module/t/c-modules/apreq_big_request_test/0000755000175100017510000000000012706745114024523 5ustar ondrejondrejrapache-1.2.8/libapreq2/module/t/c-modules/apreq_big_request_test/mod_apreq_big_request_test.c0000644000175100017510000000306012706745114032265 0ustar ondrejondrej/* ** Copyright 2003-2005 The Apache Software Foundation ** ** Licensed under the Apache License, Version 2.0 (the "License"); ** you may not use this file except in compliance with the License. ** You may obtain a copy of the License at ** ** http://www.apache.org/licenses/LICENSE-2.0 ** ** Unless required by applicable law or agreed to in writing, software ** distributed under the License is distributed on an "AS IS" BASIS, ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ** See the License for the specific language governing permissions and ** limitations under the License. */ #ifdef CONFIG_FOR_HTTPD_TEST #if CONFIG_FOR_HTTPD_TEST SetHandler apreq_big_request_test #endif #endif #define APACHE_HTTPD_TEST_HANDLER apreq_big_request_test_handler #include "apache_httpd_test.h" #include "apreq_module_apache2.h" #include "httpd.h" static int dump_table(void *count, const char *key, const char *value) { int *c = (int *) count; *c = *c + strlen(key) + strlen(value); return 1; } static int apreq_big_request_test_handler(request_rec *r) { apreq_handle_t *req; apr_table_t *params; int count = 0; if (strcmp(r->handler, "apreq_big_request_test") != 0) return DECLINED; req = apreq_handle_apache2(r); params = apreq_params(req, r->pool); apr_table_do(dump_table, &count, params, NULL); ap_set_content_type(r, "text/plain"); ap_rprintf(r, "%d", count); return OK; } APACHE_HTTPD_TEST_MODULE(apreq_big_request_test); rapache-1.2.8/libapreq2/module/t/c-modules/apreq_cookie_test/0000755000175100017510000000000012706745114023463 5ustar ondrejondrejrapache-1.2.8/libapreq2/module/t/c-modules/apreq_cookie_test/mod_apreq_cookie_test.c0000644000175100017510000000467012706745114030175 0ustar ondrejondrej/* ** Copyright 2003-2005 The Apache Software Foundation ** ** Licensed under the Apache License, Version 2.0 (the "License"); ** you may not use this file except in compliance with the License. ** You may obtain a copy of the License at ** ** http://www.apache.org/licenses/LICENSE-2.0 ** ** Unless required by applicable law or agreed to in writing, software ** distributed under the License is distributed on an "AS IS" BASIS, ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ** See the License for the specific language governing permissions and ** limitations under the License. */ #ifdef CONFIG_FOR_HTTPD_TEST #if CONFIG_FOR_HTTPD_TEST SetHandler apreq_cookie_test #endif #endif #define APACHE_HTTPD_TEST_HANDLER apreq_cookie_test_handler #include "apache_httpd_test.h" #include "apreq_module_apache2.h" #include "apreq_util.h" #include "httpd.h" #include static int dump_table(void *ctx, const char *key, const char *value) { request_rec *r = ctx; ap_log_rerror(APLOG_MARK, APLOG_DEBUG, APR_SUCCESS, r, "[%s] => [%s]", key, value); return 1; } static int apreq_cookie_test_handler(request_rec *r) { apreq_handle_t *req; apr_status_t s; const char *test, *key; apreq_cookie_t *cookie; apr_size_t size; char *dest; const apr_table_t *args; if (strcmp(r->handler, "apreq_cookie_test") != 0) return DECLINED; req = apreq_handle_apache2(r); ap_log_rerror(APLOG_MARK, APLOG_DEBUG, APR_SUCCESS, r, "starting cookie tests"); apreq_args(req, &args); apr_table_do(dump_table, r, args, NULL); test = apr_table_get(args, "test"); key = apr_table_get(args, "key"); cookie = apreq_cookie(req, key); ap_set_content_type(r, "text/plain"); if (strcmp(test, "bake") == 0) { apr_table_add(r->headers_out, "Set-Cookie", apreq_cookie_as_string(cookie, r->pool)); } else if (strcmp(test, "bake2") == 0) { apr_table_add(r->headers_out, "Set-Cookie2", apreq_cookie_as_string(cookie, r->pool)); } else { size = strlen(cookie->v.data); dest = apr_palloc(r->pool, size + 1); s = apreq_decode(dest, &size, cookie->v.data, size); if (s == APR_SUCCESS) ap_rprintf(r, "%s", dest); } return OK; } APACHE_HTTPD_TEST_MODULE(apreq_cookie_test); rapache-1.2.8/libapreq2/module/t/c-modules/apreq_output_filter_test/0000755000175100017510000000000012706745114025117 5ustar ondrejondrejrapache-1.2.8/libapreq2/module/t/c-modules/apreq_output_filter_test/mod_apreq_output_filter_test.c0000644000175100017510000000554012706745114033262 0ustar ondrejondrej/* ** Copyright 2003-2005 The Apache Software Foundation ** ** Licensed under the Apache License, Version 2.0 (the "License"); ** you may not use this file except in compliance with the License. ** You may obtain a copy of the License at ** ** http://www.apache.org/licenses/LICENSE-2.0 ** ** Unless required by applicable law or agreed to in writing, software ** distributed under the License is distributed on an "AS IS" BASIS, ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ** See the License for the specific language governing permissions and ** limitations under the License. */ #ifdef CONFIG_FOR_HTTPD_TEST #if CONFIG_FOR_HTTPD_TEST AddOutputFilter APREQ_OUTPUT_FILTER html #endif #endif #include "apache_httpd_test.h" #include "apreq_module_apache2.h" #include "httpd.h" #include "util_filter.h" static const char filter_name[] = "APREQ_OUTPUT_FILTER"; extern module AP_MODULE_DECLARE_DATA apreq_output_filter_test_module; static apr_status_t apreq_output_filter_test_init(ap_filter_t *f) { apreq_handle_t *handle; handle = apreq_handle_apache2(f->r); return APR_SUCCESS; } struct ctx_t { request_rec *r; apr_bucket_brigade *bb; }; static int dump_table(void *data, const char *key, const char *value) { struct ctx_t *ctx = (struct ctx_t *)data; ap_log_rerror(APLOG_MARK, APLOG_DEBUG, APR_SUCCESS, ctx->r, "%s => %s", key, value); apr_brigade_printf(ctx->bb,NULL,NULL,"\t%s => %s\n", key, value); return 1; } static apr_status_t apreq_output_filter_test(ap_filter_t *f, apr_bucket_brigade *bb) { request_rec *r = f->r; apreq_handle_t *handle; apr_bucket_brigade *eos; struct ctx_t ctx = {r, bb}; const apr_table_t *t; if (!APR_BUCKET_IS_EOS(APR_BRIGADE_LAST(bb))) return ap_pass_brigade(f->next,bb); eos = apr_brigade_split(bb, APR_BRIGADE_LAST(bb)); handle = apreq_handle_apache2(r); ap_log_rerror(APLOG_MARK, APLOG_DEBUG, APR_SUCCESS, r, "appending parsed data"); apr_brigade_puts(bb, NULL, NULL, "\n--APREQ OUTPUT FILTER--\nARGS:\n"); apreq_args(handle, &t); if (t != NULL) apr_table_do(dump_table, &ctx, t, NULL); apreq_body(handle, &t); if (t != NULL) { apr_brigade_puts(bb,NULL,NULL,"BODY:\n"); apr_table_do(dump_table, &ctx, t, NULL); } APR_BRIGADE_CONCAT(bb,eos); return ap_pass_brigade(f->next,bb); } static void register_hooks (apr_pool_t *p) { (void)p; ap_register_output_filter(filter_name, apreq_output_filter_test, apreq_output_filter_test_init, AP_FTYPE_CONTENT_SET); } module AP_MODULE_DECLARE_DATA apreq_output_filter_test_module = { STANDARD20_MODULE_STUFF, NULL, NULL, NULL, NULL, NULL, register_hooks, /* callback for registering hooks */ }; rapache-1.2.8/libapreq2/module/t/c-modules/apreq_redirect_test/0000755000175100017510000000000012706745114024013 5ustar ondrejondrejrapache-1.2.8/libapreq2/module/t/c-modules/apreq_redirect_test/mod_apreq_redirect_test.c0000644000175100017510000000305612706745114031052 0ustar ondrejondrej/* ** Copyright 2003-2005 The Apache Software Foundation ** ** Licensed under the Apache License, Version 2.0 (the "License"); ** you may not use this file except in compliance with the License. ** You may obtain a copy of the License at ** ** http://www.apache.org/licenses/LICENSE-2.0 ** ** Unless required by applicable law or agreed to in writing, software ** distributed under the License is distributed on an "AS IS" BASIS, ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ** See the License for the specific language governing permissions and ** limitations under the License. */ #ifdef CONFIG_FOR_HTTPD_TEST #if CONFIG_FOR_HTTPD_TEST TestAccess test SetHandler apreq_redirect_test #endif #endif #define APACHE_HTTPD_TEST_HANDLER apreq_redirect_test_handler #include "apache_httpd_test.h" #include "apreq_module_apache2.h" #include "httpd.h" static int apreq_redirect_test_handler(request_rec *r) { apreq_handle_t *req; const apreq_param_t *loc; if (strcmp(r->handler, "apreq_redirect_test") != 0) return DECLINED; req = apreq_handle_apache2(r); ap_log_rerror(APLOG_MARK, APLOG_DEBUG, APR_SUCCESS, r, "looking for new location"); loc = apreq_param(req, "location"); if (!loc) return DECLINED; ap_log_rerror(APLOG_MARK, APLOG_DEBUG, APR_SUCCESS, r, "redirecting to %s", loc->v.data); ap_internal_redirect(loc->v.data, r); return OK; } APACHE_HTTPD_TEST_MODULE(apreq_redirect_test); rapache-1.2.8/libapreq2/module/t/c-modules/apreq_request_test/0000755000175100017510000000000012706745114023702 5ustar ondrejondrejrapache-1.2.8/libapreq2/module/t/c-modules/apreq_request_test/mod_apreq_request_test.c0000644000175100017510000000416212706745114030627 0ustar ondrejondrej/* ** Copyright 2003-2005 The Apache Software Foundation ** ** Licensed under the Apache License, Version 2.0 (the "License"); ** you may not use this file except in compliance with the License. ** You may obtain a copy of the License at ** ** http://www.apache.org/licenses/LICENSE-2.0 ** ** Unless required by applicable law or agreed to in writing, software ** distributed under the License is distributed on an "AS IS" BASIS, ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ** See the License for the specific language governing permissions and ** limitations under the License. */ #ifdef CONFIG_FOR_HTTPD_TEST #if CONFIG_FOR_HTTPD_TEST APREQ2_ReadLimit 500K SetHandler apreq_request_test #endif #endif #define APACHE_HTTPD_TEST_HANDLER apreq_request_test_handler #include "apache_httpd_test.h" #include "apreq_module_apache2.h" #include "httpd.h" static int dump_table(void *ctx, const char *key, const char *value) { request_rec *r = ctx; ap_log_rerror(APLOG_MARK, APLOG_DEBUG, APR_SUCCESS, r, "%s => %s", key, value); ap_rprintf(r, "\t%s => %s\n", key, value); return 1; } static int apreq_request_test_handler(request_rec *r) { apreq_handle_t *req; const apr_table_t *t; apr_status_t s; if (strcmp(r->handler, "apreq_request_test") != 0) return DECLINED; req = apreq_handle_apache2(r); ap_log_rerror(APLOG_MARK, APLOG_DEBUG, APR_SUCCESS, r, "starting apreq_request_test"); s = ap_discard_request_body(r); ap_log_rerror(APLOG_MARK, APLOG_DEBUG, s, r, "discard request body"); ap_set_content_type(r, "text/plain"); ap_rputs("ARGS:\n",r); if (apreq_args(req, &t) == APR_SUCCESS) apr_table_do(dump_table, r, t, NULL); if (apreq_body(req, &t) == APR_SUCCESS) { ap_rputs("BODY:\n",r); apr_table_do(dump_table, r, t, NULL); } ap_log_rerror(APLOG_MARK, APLOG_DEBUG, APR_SUCCESS, r, "finished apreq_request_test"); return OK; } APACHE_HTTPD_TEST_MODULE(apreq_request_test); rapache-1.2.8/libapreq2/module/t/cgi.t0000644000175100017510000000766212706745114017035 0ustar ondrejondrejuse strict; use warnings FATAL => 'all'; use Apache::Test; use Apache::TestUtil; use Apache::TestConfig; use Apache::TestRequest qw(GET_BODY UPLOAD_BODY POST_BODY GET_RC GET_HEAD); use constant WIN32 => Apache::TestConfig::WIN32; my @key_len = (5, 100, 305); my @key_num = (5, 15, 26); my @keys = ('a'..'z'); my @big_key_len = (100, 500, 5000, 10000); my @big_key_num = (5, 15, 25); my @big_keys = ('a'..'z'); plan tests => 10 + @key_len * @key_num + @big_key_len * @big_key_num, have_lwp && have_cgi; require HTTP::Cookies; my $location = '/cgi-bin'; my $script = $location . (WIN32 ? '/test_cgi.exe' : '/test_cgi'); my $line_end = "\n"; my $filler = "0123456789" x 20; # < 64K # GET for my $key_len (@key_len) { for my $key_num (@key_num) { my @query = (); my $len = 0; for my $key (@keys[0..($key_num-1)]) { my $pair = "$key=" . 'd' x $key_len; $len += length($pair) - 1; push @query, $pair; } my $query = join ";", @query; t_debug "# of keys : $key_num, key_len $key_len"; my $body = GET_BODY "$script?$query"; ok t_cmp($body, $len, "GET long query"); } } # POST for my $big_key_len (@big_key_len) { for my $big_key_num (@big_key_num) { my @query = (); my $len = 0; for my $big_key (@big_keys[0..($big_key_num-1)]) { my $pair = "$big_key=" . 'd' x $big_key_len; $len += length($pair) - 1; push @query, $pair; } my $query = join ";", @query; t_debug "# of keys : $big_key_num, big_key_len $big_key_len"; my $body = POST_BODY($script, content => $query); ok t_cmp($body, $len, "POST big data"); } } ok t_cmp(POST_BODY("$script?foo=1", Content => $filler), "\tfoo => 1$line_end", "simple post"); ok t_cmp(GET_BODY("$script?foo=%3F&bar=hello+world"), "\tfoo => ?$line_end\tbar => hello world$line_end", "simple get"); my $body = POST_BODY($script, content => "aaa=$filler;foo=1;bar=2;filler=$filler"); ok t_cmp($body, "\tfoo => 1$line_end\tbar => 2$line_end", "simple post"); $body = POST_BODY("$script?foo=1", content => "intro=$filler&bar=2&conclusion=$filler"); ok t_cmp($body, "\tfoo => 1$line_end\tbar => 2$line_end", "simple post"); $body = UPLOAD_BODY("$script?foo=0", content => $filler); ok t_cmp($body, "\tfoo => 0$line_end", "simple upload"); { my $test = 'netscape'; my $key = 'apache'; my $value = 'ok'; my $cookie = qq{$key=$value}; ok t_cmp($value, GET_BODY("$script?test=$test&key=$key", Cookie => $cookie), $test); } { my $test = 'rfc'; my $key = 'apache'; my $value = 'ok'; my $cookie = qq{\$Version="1"; $key="$value"; \$Path="$location"}; ok t_cmp(qq{"$value"}, GET_BODY("$script?test=$test&key=$key", Cookie => $cookie), $test); } { my $test = 'encoded value with space'; my $key = 'apache'; my $value = 'okie dokie'; my $cookie = "$key=" . join '', map {/ / ? '+' : sprintf '%%%.2X', ord} split //, $value; ok t_cmp($value, GET_BODY("$script?test=$test&key=$key", Cookie => $cookie), $test); } { my $test = 'bake'; my $key = 'apache'; my $value = 'ok'; my $cookie = "$key=$value"; my ($header) = GET_HEAD("$script?test=$test&key=$key", Cookie => $cookie) =~ /^#Set-Cookie:\s+(.+)/m; ok t_cmp($cookie, $header, $test); } { my $test = 'bake2'; my $key = 'apache'; my $value = 'ok'; my $cookie = qq{\$Version="1"; $key="$value"; \$Path="$location"}; my ($header) = GET_HEAD("$script?test=$test&key=$key", Cookie => $cookie) =~ /^#Set-Cookie2:\s+(.+)/m; ok t_cmp(qq{$key="$value"; Version=1; path="$location"}, $header, $test); } rapache-1.2.8/libapreq2/module/t/conf/0000755000175100017510000000000012706745114017020 5ustar ondrejondrejrapache-1.2.8/libapreq2/module/t/conf/extra.conf.in0000644000175100017510000000032412706745114021416 0ustar ondrejondrejScriptAlias /cgi-bin/ "@ServerRoot@/cgi-bin/" LockFile @ServerRoot@/logs/accept.lock AllowOverride None Options None rapache-1.2.8/libapreq2/module/t/conf/ssl/0000755000175100017510000000000012706745114017621 5ustar ondrejondrejrapache-1.2.8/libapreq2/module/t/conf/ssl/ca-bundle-duplicates.crt0000644000175100017510000001411512706745114024322 0ustar ondrejondrej#some duplicates of certs found in mod_ssl-2.x.x-1.3.xx/pkg.sslcfg/ca-bundle.crt #to make sure mod_ssl can handle duplicates ABAecom (sub., Am. Bankers Assn.) Root CA ========================================= MD5 Fingerprint: 82:12:F7:89:E1:0B:91:60:A4:B6:22:9F:94:68:11:92 PEM Data: -----BEGIN CERTIFICATE----- MIID+DCCAuCgAwIBAgIRANAeQJAAACdLAAAAAQAAAAQwDQYJKoZIhvcNAQEFBQAw gYwxCzAJBgNVBAYTAlVTMQ0wCwYDVQQIEwRVdGFoMRcwFQYDVQQHEw5TYWx0IExh a2UgQ2l0eTEYMBYGA1UEChMPWGNlcnQgRVogYnkgRFNUMRgwFgYDVQQDEw9YY2Vy dCBFWiBieSBEU1QxITAfBgkqhkiG9w0BCQEWEmNhQGRpZ3NpZ3RydXN0LmNvbTAe Fw05OTA3MTQxNjE0MThaFw0wOTA3MTExNjE0MThaMIGMMQswCQYDVQQGEwJVUzEN MAsGA1UECBMEVXRhaDEXMBUGA1UEBxMOU2FsdCBMYWtlIENpdHkxGDAWBgNVBAoT D1hjZXJ0IEVaIGJ5IERTVDEYMBYGA1UEAxMPWGNlcnQgRVogYnkgRFNUMSEwHwYJ KoZIhvcNAQkBFhJjYUBkaWdzaWd0cnVzdC5jb20wggEiMA0GCSqGSIb3DQEBAQUA A4IBDwAwggEKAoIBAQCtVBjetL/3reh0qu2LfI/C1HUa1YS5tmL8ie/kl2GS+x24 4VpHNJ6eBiL70+o4y7iLB/caoBd3B1owHNQpOCDXJ0DYUJNDv9IYoil2BXKqa7Zp mKt5Hhxl9WqL/MUWqqJy2mDtTm4ZJXoKHTDjUJtCPETrobAgHtsCfv49H7/QAIrb QHamGKUVp1e2UsIBF5h3j4qBxhq0airmr6nWAKzP2BVJfNsbof6B+of505DBAsD5 0ELpkWglX8a/hznplQBgKL+DLMDnXrbXNhbnYId26OcnsiUNi3rlqh3lWc3OCw5v xsic4xDZhTnTt5v6xrp8dNJddVardKSiUb9SfO5xAgMBAAGjUzBRMA8GA1UdEwEB /wQFMAMBAf8wHwYDVR0jBBgwFoAUCCBsZuuBCmxc1bWmPEHdHJaRJ3cwHQYDVR0O BBYEFAggbGbrgQpsXNW1pjxB3RyWkSd3MA0GCSqGSIb3DQEBBQUAA4IBAQBah1iP Lat2IWtUDNnxQfZOzSue4x+boy1/2St9WMhnpCn16ezVvZY/o3P4xFs2fNBjLDQ5 m0i4PW/2FMWeY+anNG7T6DOzxzwYbiOuQ5KZP5jFaTDxNjutuTCC1rZZFpYCCykS YbQRifcML5SQhZgonFNsfmPdc/QZ/0qB0bJSI/08SjTOWhvgUIrtT4GV2GDn5MQN u1g+WPdOaG8+Z8nLepcWJ+xCYRR2uwDF6wg9FX9LtiJdhzuQ9PPA/jez6dliDMDD Wa9gvR8N26E0HzDEPYutsB0Ek+1f1eS/IDAE9EjpMwHRLpAnUrOb3jocq6mXf5vr wo3CbezcE9NGxXl8 -----END CERTIFICATE----- Certificate Ingredients: Data: Version: 3 (0x2) Serial Number: d0:1e:40:90:00:00:27:4b:00:00:00:01:00:00:00:04 Signature Algorithm: sha1WithRSAEncryption Issuer: C=US, ST=Utah, L=Salt Lake City, O=Xcert EZ by DST, CN=Xcert EZ by DST/Email=ca@digsigtrust.com Validity Not Before: Jul 14 16:14:18 1999 GMT Not After : Jul 11 16:14:18 2009 GMT Subject: C=US, ST=Utah, L=Salt Lake City, O=Xcert EZ by DST, CN=Xcert EZ by DST/Email=ca@digsigtrust.com Subject Public Key Info: Public Key Algorithm: rsaEncryption RSA Public Key: (2048 bit) Modulus (2048 bit): 00:ad:54:18:de:b4:bf:f7:ad:e8:74:aa:ed:8b:7c: 8f:c2:d4:75:1a:d5:84:b9:b6:62:fc:89:ef:e4:97: 61:92:fb:1d:b8:e1:5a:47:34:9e:9e:06:22:fb:d3: ea:38:cb:b8:8b:07:f7:1a:a0:17:77:07:5a:30:1c: d4:29:38:20:d7:27:40:d8:50:93:43:bf:d2:18:a2: 29:76:05:72:aa:6b:b6:69:98:ab:79:1e:1c:65:f5: 6a:8b:fc:c5:16:aa:a2:72:da:60:ed:4e:6e:19:25: 7a:0a:1d:30:e3:50:9b:42:3c:44:eb:a1:b0:20:1e: db:02:7e:fe:3d:1f:bf:d0:00:8a:db:40:76:a6:18: a5:15:a7:57:b6:52:c2:01:17:98:77:8f:8a:81:c6: 1a:b4:6a:2a:e6:af:a9:d6:00:ac:cf:d8:15:49:7c: db:1b:a1:fe:81:fa:87:f9:d3:90:c1:02:c0:f9:d0: 42:e9:91:68:25:5f:c6:bf:87:39:e9:95:00:60:28: bf:83:2c:c0:e7:5e:b6:d7:36:16:e7:60:87:76:e8: e7:27:b2:25:0d:8b:7a:e5:aa:1d:e5:59:cd:ce:0b: 0e:6f:c6:c8:9c:e3:10:d9:85:39:d3:b7:9b:fa:c6: ba:7c:74:d2:5d:75:56:ab:74:a4:a2:51:bf:52:7c: ee:71 Exponent: 65537 (0x10001) X509v3 extensions: X509v3 Basic Constraints: critical CA:TRUE X509v3 Authority Key Identifier: keyid:08:20:6C:66:EB:81:0A:6C:5C:D5:B5:A6:3C:41:DD:1C:96:91:27:77 X509v3 Subject Key Identifier: 08:20:6C:66:EB:81:0A:6C:5C:D5:B5:A6:3C:41:DD:1C:96:91:27:77 Signature Algorithm: sha1WithRSAEncryption 5a:87:58:8f:2d:ab:76:21:6b:54:0c:d9:f1:41:f6:4e:cd:2b: 9e:e3:1f:9b:a3:2d:7f:d9:2b:7d:58:c8:67:a4:29:f5:e9:ec: d5:bd:96:3f:a3:73:f8:c4:5b:36:7c:d0:63:2c:34:39:9b:48: b8:3d:6f:f6:14:c5:9e:63:e6:a7:34:6e:d3:e8:33:b3:c7:3c: 18:6e:23:ae:43:92:99:3f:98:c5:69:30:f1:36:3b:ad:b9:30: 82:d6:b6:59:16:96:02:0b:29:12:61:b4:11:89:f7:0c:2f:94: 90:85:98:28:9c:53:6c:7e:63:dd:73:f4:19:ff:4a:81:d1:b2: 52:23:fd:3c:4a:34:ce:5a:1b:e0:50:8a:ed:4f:81:95:d8:60: e7:e4:c4:0d:bb:58:3e:58:f7:4e:68:6f:3e:67:c9:cb:7a:97: 16:27:ec:42:61:14:76:bb:00:c5:eb:08:3d:15:7f:4b:b6:22: 5d:87:3b:90:f4:f3:c0:fe:37:b3:e9:d9:62:0c:c0:c3:59:af: 60:bd:1f:0d:db:a1:34:1f:30:c4:3d:8b:ad:b0:1d:04:93:ed: 5f:d5:e4:bf:20:30:04:f4:48:e9:33:01:d1:2e:90:27:52:b3: 9b:de:3a:1c:ab:a9:97:7f:9b:eb:c2:8d:c2:6d:ec:dc:13:d3: 46:c5:79:7c ANX Network CA by DST ===================== MD5 Fingerprint: A8:ED:DE:EB:93:88:66:D8:2F:C3:BD:1D:BE:45:BE:4D PEM Data: -----BEGIN CERTIFICATE----- MIIDTTCCAragAwIBAgIENm6ibzANBgkqhkiG9w0BAQUFADBSMQswCQYDVQQGEwJV UzEkMCIGA1UEChMbRGlnaXRhbCBTaWduYXR1cmUgVHJ1c3QgQ28uMR0wGwYDVQQL ExREU1QgKEFOWCBOZXR3b3JrKSBDQTAeFw05ODEyMDkxNTQ2NDhaFw0xODEyMDkx NjE2NDhaMFIxCzAJBgNVBAYTAlVTMSQwIgYDVQQKExtEaWdpdGFsIFNpZ25hdHVy ZSBUcnVzdCBDby4xHTAbBgNVBAsTFERTVCAoQU5YIE5ldHdvcmspIENBMIGdMA0G CSqGSIb3DQEBAQUAA4GLADCBhwKBgQC0SBGAWKDVpZkP9jcsRLZu0XzzKmueEbaI IwRccSWeahJ3EW6/aDllqPay9qIYsokVoGe3eowiSGv2hDQftsr3G3LL8ltI04ce InYTBLSsbJZ/5w4IyTJRMC3VgOghZ7rzXggkLAdZnZAa7kbJtaQelrRBkdR/0o04 JrBvQ24JfQIBA6OCATAwggEsMBEGCWCGSAGG+EIBAQQEAwIABzB0BgNVHR8EbTBr MGmgZ6BlpGMwYTELMAkGA1UEBhMCVVMxJDAiBgNVBAoTG0RpZ2l0YWwgU2lnbmF0 dXJlIFRydXN0IENvLjEdMBsGA1UECxMURFNUIChBTlggTmV0d29yaykgQ0ExDTAL BgNVBAMTBENSTDEwKwYDVR0QBCQwIoAPMTk5ODEyMDkxNTQ2NDhagQ8yMDE4MTIw OTE1NDY0OFowCwYDVR0PBAQDAgEGMB8GA1UdIwQYMBaAFIwWVXDMFgpTZMKlhKqz ZBdDP4I2MB0GA1UdDgQWBBSMFlVwzBYKU2TCpYSqs2QXQz+CNjAMBgNVHRMEBTAD AQH/MBkGCSqGSIb2fQdBAAQMMAobBFY0LjADAgSQMA0GCSqGSIb3DQEBBQUAA4GB AEklyWCxDF+pORDTxTRVfc95wynr3vnCQPnoVsXwL+z02exIUbhjOF6TbhiWhbnK UJykuOpmJmiThW9vTHHQvnoLPDG5975pnhDX0UDorBZxq66rOOFwscqSFuBdhaYY gAYAnOGmGEJRp2hoWe8mlF+tMQz+KR4XAYQ3W+gSMqNd -----END CERTIFICATE----- rapache-1.2.8/libapreq2/module/t/conf/ssl/ca-bundle-sample.crt0000644000175100017510000005057712706745114023462 0ustar ondrejondrej#pkg.sslcfg/ca-bundle.crt is ~250k, so it is not checked into cvs #for better test results, copy that file into this directory #and leave this one in place ABAecom (sub., Am. Bankers Assn.) Root CA ========================================= MD5 Fingerprint: 82:12:F7:89:E1:0B:91:60:A4:B6:22:9F:94:68:11:92 PEM Data: -----BEGIN CERTIFICATE----- MIID+DCCAuCgAwIBAgIRANAeQJAAACdLAAAAAQAAAAQwDQYJKoZIhvcNAQEFBQAw gYwxCzAJBgNVBAYTAlVTMQ0wCwYDVQQIEwRVdGFoMRcwFQYDVQQHEw5TYWx0IExh a2UgQ2l0eTEYMBYGA1UEChMPWGNlcnQgRVogYnkgRFNUMRgwFgYDVQQDEw9YY2Vy dCBFWiBieSBEU1QxITAfBgkqhkiG9w0BCQEWEmNhQGRpZ3NpZ3RydXN0LmNvbTAe Fw05OTA3MTQxNjE0MThaFw0wOTA3MTExNjE0MThaMIGMMQswCQYDVQQGEwJVUzEN MAsGA1UECBMEVXRhaDEXMBUGA1UEBxMOU2FsdCBMYWtlIENpdHkxGDAWBgNVBAoT D1hjZXJ0IEVaIGJ5IERTVDEYMBYGA1UEAxMPWGNlcnQgRVogYnkgRFNUMSEwHwYJ KoZIhvcNAQkBFhJjYUBkaWdzaWd0cnVzdC5jb20wggEiMA0GCSqGSIb3DQEBAQUA A4IBDwAwggEKAoIBAQCtVBjetL/3reh0qu2LfI/C1HUa1YS5tmL8ie/kl2GS+x24 4VpHNJ6eBiL70+o4y7iLB/caoBd3B1owHNQpOCDXJ0DYUJNDv9IYoil2BXKqa7Zp mKt5Hhxl9WqL/MUWqqJy2mDtTm4ZJXoKHTDjUJtCPETrobAgHtsCfv49H7/QAIrb QHamGKUVp1e2UsIBF5h3j4qBxhq0airmr6nWAKzP2BVJfNsbof6B+of505DBAsD5 0ELpkWglX8a/hznplQBgKL+DLMDnXrbXNhbnYId26OcnsiUNi3rlqh3lWc3OCw5v xsic4xDZhTnTt5v6xrp8dNJddVardKSiUb9SfO5xAgMBAAGjUzBRMA8GA1UdEwEB /wQFMAMBAf8wHwYDVR0jBBgwFoAUCCBsZuuBCmxc1bWmPEHdHJaRJ3cwHQYDVR0O BBYEFAggbGbrgQpsXNW1pjxB3RyWkSd3MA0GCSqGSIb3DQEBBQUAA4IBAQBah1iP Lat2IWtUDNnxQfZOzSue4x+boy1/2St9WMhnpCn16ezVvZY/o3P4xFs2fNBjLDQ5 m0i4PW/2FMWeY+anNG7T6DOzxzwYbiOuQ5KZP5jFaTDxNjutuTCC1rZZFpYCCykS YbQRifcML5SQhZgonFNsfmPdc/QZ/0qB0bJSI/08SjTOWhvgUIrtT4GV2GDn5MQN u1g+WPdOaG8+Z8nLepcWJ+xCYRR2uwDF6wg9FX9LtiJdhzuQ9PPA/jez6dliDMDD Wa9gvR8N26E0HzDEPYutsB0Ek+1f1eS/IDAE9EjpMwHRLpAnUrOb3jocq6mXf5vr wo3CbezcE9NGxXl8 -----END CERTIFICATE----- Certificate Ingredients: Data: Version: 3 (0x2) Serial Number: d0:1e:40:90:00:00:27:4b:00:00:00:01:00:00:00:04 Signature Algorithm: sha1WithRSAEncryption Issuer: C=US, ST=Utah, L=Salt Lake City, O=Xcert EZ by DST, CN=Xcert EZ by DST/Email=ca@digsigtrust.com Validity Not Before: Jul 14 16:14:18 1999 GMT Not After : Jul 11 16:14:18 2009 GMT Subject: C=US, ST=Utah, L=Salt Lake City, O=Xcert EZ by DST, CN=Xcert EZ by DST/Email=ca@digsigtrust.com Subject Public Key Info: Public Key Algorithm: rsaEncryption RSA Public Key: (2048 bit) Modulus (2048 bit): 00:ad:54:18:de:b4:bf:f7:ad:e8:74:aa:ed:8b:7c: 8f:c2:d4:75:1a:d5:84:b9:b6:62:fc:89:ef:e4:97: 61:92:fb:1d:b8:e1:5a:47:34:9e:9e:06:22:fb:d3: ea:38:cb:b8:8b:07:f7:1a:a0:17:77:07:5a:30:1c: d4:29:38:20:d7:27:40:d8:50:93:43:bf:d2:18:a2: 29:76:05:72:aa:6b:b6:69:98:ab:79:1e:1c:65:f5: 6a:8b:fc:c5:16:aa:a2:72:da:60:ed:4e:6e:19:25: 7a:0a:1d:30:e3:50:9b:42:3c:44:eb:a1:b0:20:1e: db:02:7e:fe:3d:1f:bf:d0:00:8a:db:40:76:a6:18: a5:15:a7:57:b6:52:c2:01:17:98:77:8f:8a:81:c6: 1a:b4:6a:2a:e6:af:a9:d6:00:ac:cf:d8:15:49:7c: db:1b:a1:fe:81:fa:87:f9:d3:90:c1:02:c0:f9:d0: 42:e9:91:68:25:5f:c6:bf:87:39:e9:95:00:60:28: bf:83:2c:c0:e7:5e:b6:d7:36:16:e7:60:87:76:e8: e7:27:b2:25:0d:8b:7a:e5:aa:1d:e5:59:cd:ce:0b: 0e:6f:c6:c8:9c:e3:10:d9:85:39:d3:b7:9b:fa:c6: ba:7c:74:d2:5d:75:56:ab:74:a4:a2:51:bf:52:7c: ee:71 Exponent: 65537 (0x10001) X509v3 extensions: X509v3 Basic Constraints: critical CA:TRUE X509v3 Authority Key Identifier: keyid:08:20:6C:66:EB:81:0A:6C:5C:D5:B5:A6:3C:41:DD:1C:96:91:27:77 X509v3 Subject Key Identifier: 08:20:6C:66:EB:81:0A:6C:5C:D5:B5:A6:3C:41:DD:1C:96:91:27:77 Signature Algorithm: sha1WithRSAEncryption 5a:87:58:8f:2d:ab:76:21:6b:54:0c:d9:f1:41:f6:4e:cd:2b: 9e:e3:1f:9b:a3:2d:7f:d9:2b:7d:58:c8:67:a4:29:f5:e9:ec: d5:bd:96:3f:a3:73:f8:c4:5b:36:7c:d0:63:2c:34:39:9b:48: b8:3d:6f:f6:14:c5:9e:63:e6:a7:34:6e:d3:e8:33:b3:c7:3c: 18:6e:23:ae:43:92:99:3f:98:c5:69:30:f1:36:3b:ad:b9:30: 82:d6:b6:59:16:96:02:0b:29:12:61:b4:11:89:f7:0c:2f:94: 90:85:98:28:9c:53:6c:7e:63:dd:73:f4:19:ff:4a:81:d1:b2: 52:23:fd:3c:4a:34:ce:5a:1b:e0:50:8a:ed:4f:81:95:d8:60: e7:e4:c4:0d:bb:58:3e:58:f7:4e:68:6f:3e:67:c9:cb:7a:97: 16:27:ec:42:61:14:76:bb:00:c5:eb:08:3d:15:7f:4b:b6:22: 5d:87:3b:90:f4:f3:c0:fe:37:b3:e9:d9:62:0c:c0:c3:59:af: 60:bd:1f:0d:db:a1:34:1f:30:c4:3d:8b:ad:b0:1d:04:93:ed: 5f:d5:e4:bf:20:30:04:f4:48:e9:33:01:d1:2e:90:27:52:b3: 9b:de:3a:1c:ab:a9:97:7f:9b:eb:c2:8d:c2:6d:ec:dc:13:d3: 46:c5:79:7c ANX Network CA by DST ===================== MD5 Fingerprint: A8:ED:DE:EB:93:88:66:D8:2F:C3:BD:1D:BE:45:BE:4D PEM Data: -----BEGIN CERTIFICATE----- MIIDTTCCAragAwIBAgIENm6ibzANBgkqhkiG9w0BAQUFADBSMQswCQYDVQQGEwJV UzEkMCIGA1UEChMbRGlnaXRhbCBTaWduYXR1cmUgVHJ1c3QgQ28uMR0wGwYDVQQL ExREU1QgKEFOWCBOZXR3b3JrKSBDQTAeFw05ODEyMDkxNTQ2NDhaFw0xODEyMDkx NjE2NDhaMFIxCzAJBgNVBAYTAlVTMSQwIgYDVQQKExtEaWdpdGFsIFNpZ25hdHVy ZSBUcnVzdCBDby4xHTAbBgNVBAsTFERTVCAoQU5YIE5ldHdvcmspIENBMIGdMA0G CSqGSIb3DQEBAQUAA4GLADCBhwKBgQC0SBGAWKDVpZkP9jcsRLZu0XzzKmueEbaI IwRccSWeahJ3EW6/aDllqPay9qIYsokVoGe3eowiSGv2hDQftsr3G3LL8ltI04ce InYTBLSsbJZ/5w4IyTJRMC3VgOghZ7rzXggkLAdZnZAa7kbJtaQelrRBkdR/0o04 JrBvQ24JfQIBA6OCATAwggEsMBEGCWCGSAGG+EIBAQQEAwIABzB0BgNVHR8EbTBr MGmgZ6BlpGMwYTELMAkGA1UEBhMCVVMxJDAiBgNVBAoTG0RpZ2l0YWwgU2lnbmF0 dXJlIFRydXN0IENvLjEdMBsGA1UECxMURFNUIChBTlggTmV0d29yaykgQ0ExDTAL BgNVBAMTBENSTDEwKwYDVR0QBCQwIoAPMTk5ODEyMDkxNTQ2NDhagQ8yMDE4MTIw OTE1NDY0OFowCwYDVR0PBAQDAgEGMB8GA1UdIwQYMBaAFIwWVXDMFgpTZMKlhKqz ZBdDP4I2MB0GA1UdDgQWBBSMFlVwzBYKU2TCpYSqs2QXQz+CNjAMBgNVHRMEBTAD AQH/MBkGCSqGSIb2fQdBAAQMMAobBFY0LjADAgSQMA0GCSqGSIb3DQEBBQUAA4GB AEklyWCxDF+pORDTxTRVfc95wynr3vnCQPnoVsXwL+z02exIUbhjOF6TbhiWhbnK UJykuOpmJmiThW9vTHHQvnoLPDG5975pnhDX0UDorBZxq66rOOFwscqSFuBdhaYY gAYAnOGmGEJRp2hoWe8mlF+tMQz+KR4XAYQ3W+gSMqNd -----END CERTIFICATE----- Certificate Ingredients: Data: Version: 3 (0x2) Serial Number: 913220207 (0x366ea26f) Signature Algorithm: sha1WithRSAEncryption Issuer: C=US, O=Digital Signature Trust Co., OU=DST (ANX Network) CA Validity Not Before: Dec 9 15:46:48 1998 GMT Not After : Dec 9 16:16:48 2018 GMT Subject: C=US, O=Digital Signature Trust Co., OU=DST (ANX Network) CA Subject Public Key Info: Public Key Algorithm: rsaEncryption RSA Public Key: (1024 bit) Modulus (1024 bit): 00:b4:48:11:80:58:a0:d5:a5:99:0f:f6:37:2c:44: b6:6e:d1:7c:f3:2a:6b:9e:11:b6:88:23:04:5c:71: 25:9e:6a:12:77:11:6e:bf:68:39:65:a8:f6:b2:f6: a2:18:b2:89:15:a0:67:b7:7a:8c:22:48:6b:f6:84: 34:1f:b6:ca:f7:1b:72:cb:f2:5b:48:d3:87:1e:22: 76:13:04:b4:ac:6c:96:7f:e7:0e:08:c9:32:51:30: 2d:d5:80:e8:21:67:ba:f3:5e:08:24:2c:07:59:9d: 90:1a:ee:46:c9:b5:a4:1e:96:b4:41:91:d4:7f:d2: 8d:38:26:b0:6f:43:6e:09:7d Exponent: 3 (0x3) X509v3 extensions: Netscape Cert Type: SSL CA, S/MIME CA, Object Signing CA X509v3 CRL Distribution Points: DirName:/C=US/O=Digital Signature Trust Co./OU=DST (ANX Network) CA/CN=CRL1 X509v3 Private Key Usage Period: Not Before: Dec 9 15:46:48 1998 GMT, Not After: Dec 9 15:46:48 2018 GMT X509v3 Key Usage: Certificate Sign, CRL Sign X509v3 Authority Key Identifier: keyid:8C:16:55:70:CC:16:0A:53:64:C2:A5:84:AA:B3:64:17:43:3F:82:36 X509v3 Subject Key Identifier: 8C:16:55:70:CC:16:0A:53:64:C2:A5:84:AA:B3:64:17:43:3F:82:36 X509v3 Basic Constraints: CA:TRUE 1.2.840.113533.7.65.0: 0 ..V4.0.... Signature Algorithm: sha1WithRSAEncryption 49:25:c9:60:b1:0c:5f:a9:39:10:d3:c5:34:55:7d:cf:79:c3: 29:eb:de:f9:c2:40:f9:e8:56:c5:f0:2f:ec:f4:d9:ec:48:51: b8:63:38:5e:93:6e:18:96:85:b9:ca:50:9c:a4:b8:ea:66:26: 68:93:85:6f:6f:4c:71:d0:be:7a:0b:3c:31:b9:f7:be:69:9e: 10:d7:d1:40:e8:ac:16:71:ab:ae:ab:38:e1:70:b1:ca:92:16: e0:5d:85:a6:18:80:06:00:9c:e1:a6:18:42:51:a7:68:68:59: ef:26:94:5f:ad:31:0c:fe:29:1e:17:01:84:37:5b:e8:12:32: a3:5d American Express CA =================== MD5 Fingerprint: 1C:D5:8E:82:BE:70:55:8E:39:61:DF:AD:51:DB:6B:A0 PEM Data: -----BEGIN CERTIFICATE----- MIICkDCCAfkCAgCNMA0GCSqGSIb3DQEBBAUAMIGPMQswCQYDVQQGEwJVUzEnMCUG A1UEChMeQW1lcmljYW4gRXhwcmVzcyBDb21wYW55LCBJbmMuMSYwJAYDVQQLEx1B bWVyaWNhbiBFeHByZXNzIFRlY2hub2xvZ2llczEvMC0GA1UEAxMmQW1lcmljYW4g RXhwcmVzcyBDZXJ0aWZpY2F0ZSBBdXRob3JpdHkwHhcNOTgwODE0MjIwMTAwWhcN MDYwODE0MjM1OTAwWjCBjzELMAkGA1UEBhMCVVMxJzAlBgNVBAoTHkFtZXJpY2Fu IEV4cHJlc3MgQ29tcGFueSwgSW5jLjEmMCQGA1UECxMdQW1lcmljYW4gRXhwcmVz cyBUZWNobm9sb2dpZXMxLzAtBgNVBAMTJkFtZXJpY2FuIEV4cHJlc3MgQ2VydGlm aWNhdGUgQXV0aG9yaXR5MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQDJ8kmS hcr9FSm1BrZE7PyIo/KGzv8UTyQckvnCI8HOQ99dNMi4FOzVKnCRSZXXVs2U8amT 0Ggi3E19oApyKkfqJfCFAF82VGHPC/k3Wmed6R/pZD9wlWGn0DAC3iYopGYDBOkw +48zB/lvYYeictvzaHhjZlmpybdm4RWySDYs+QIDAQABMA0GCSqGSIb3DQEBBAUA A4GBAGgXYrhzi0xs60qlPqvlnS7SzYoHV/PGWZd2Fxf4Uo4nk9hY2Chs9KIEeorC diSxArTfKPL386infiNIYYj0EWiuJl32oUtTJWrYKhQCDuCHIG6eGVxzkAsj4jGX Iz/VIqLTBnvaN/XXtUFEF3pFAtmFRWbWjsfwegyZYiJpW+3S -----END CERTIFICATE----- Certificate Ingredients: Data: Version: 1 (0x0) Serial Number: 141 (0x8d) Signature Algorithm: md5WithRSAEncryption Issuer: C=US, O=American Express Company, Inc., OU=American Express Technologies, CN=American Express Certificate Authority Validity Not Before: Aug 14 22:01:00 1998 GMT Not After : Aug 14 23:59:00 2006 GMT Subject: C=US, O=American Express Company, Inc., OU=American Express Technologies, CN=American Express Certificate Authority Subject Public Key Info: Public Key Algorithm: rsaEncryption RSA Public Key: (1024 bit) Modulus (1024 bit): 00:c9:f2:49:92:85:ca:fd:15:29:b5:06:b6:44:ec: fc:88:a3:f2:86:ce:ff:14:4f:24:1c:92:f9:c2:23: c1:ce:43:df:5d:34:c8:b8:14:ec:d5:2a:70:91:49: 95:d7:56:cd:94:f1:a9:93:d0:68:22:dc:4d:7d:a0: 0a:72:2a:47:ea:25:f0:85:00:5f:36:54:61:cf:0b: f9:37:5a:67:9d:e9:1f:e9:64:3f:70:95:61:a7:d0: 30:02:de:26:28:a4:66:03:04:e9:30:fb:8f:33:07: f9:6f:61:87:a2:72:db:f3:68:78:63:66:59:a9:c9: b7:66:e1:15:b2:48:36:2c:f9 Exponent: 65537 (0x10001) Signature Algorithm: md5WithRSAEncryption 68:17:62:b8:73:8b:4c:6c:eb:4a:a5:3e:ab:e5:9d:2e:d2:cd: 8a:07:57:f3:c6:59:97:76:17:17:f8:52:8e:27:93:d8:58:d8: 28:6c:f4:a2:04:7a:8a:c2:76:24:b1:02:b4:df:28:f2:f7:f3: a8:a7:7e:23:48:61:88:f4:11:68:ae:26:5d:f6:a1:4b:53:25: 6a:d8:2a:14:02:0e:e0:87:20:6e:9e:19:5c:73:90:0b:23:e2: 31:97:23:3f:d5:22:a2:d3:06:7b:da:37:f5:d7:b5:41:44:17: 7a:45:02:d9:85:45:66:d6:8e:c7:f0:7a:0c:99:62:22:69:5b: ed:d2 American Express Global CA ========================== MD5 Fingerprint: 63:1B:66:93:8C:F3:66:CB:3C:79:57:DC:05:49:EA:DB PEM Data: -----BEGIN CERTIFICATE----- MIIEBDCCAuygAwIBAgICAIUwDQYJKoZIhvcNAQEFBQAwgZYxCzAJBgNVBAYTAlVT MScwJQYDVQQKEx5BbWVyaWNhbiBFeHByZXNzIENvbXBhbnksIEluYy4xJjAkBgNV BAsTHUFtZXJpY2FuIEV4cHJlc3MgVGVjaG5vbG9naWVzMTYwNAYDVQQDEy1BbWVy aWNhbiBFeHByZXNzIEdsb2JhbCBDZXJ0aWZpY2F0ZSBBdXRob3JpdHkwHhcNOTgw ODE0MTkwNjAwWhcNMTMwODE0MjM1OTAwWjCBljELMAkGA1UEBhMCVVMxJzAlBgNV BAoTHkFtZXJpY2FuIEV4cHJlc3MgQ29tcGFueSwgSW5jLjEmMCQGA1UECxMdQW1l cmljYW4gRXhwcmVzcyBUZWNobm9sb2dpZXMxNjA0BgNVBAMTLUFtZXJpY2FuIEV4 cHJlc3MgR2xvYmFsIENlcnRpZmljYXRlIEF1dGhvcml0eTCCASIwDQYJKoZIhvcN AQEBBQADggEPADCCAQoCggEBAPAkJmYu++tKc3FTiUfLJjxTkpRMysKFtQ34w1e9 Lyofahi3V68MABb6oLaQpvcaoS5mJsdoo4qTaWa1RlYtHYLqkAwKIsKJUI0F89Sr c0HwzxKsKLRvFJSWWUuekHWG3+JH6+HpT0N+h8onGGaetcFAZX38YW+tm3LPqV7Y 8/nabpEQ+ky16n4g3qk5L/WI5IpvNcYgnCuGRjMK/DFVpWusFkDpzTVZbzIEw3u1 D3t3cPNIuypSgs6vKW3xEW9t5gcAAe+a8yYNpnkTZ6/4qxx1rJG1a75AsN6cDLFp hRlxkRNFyt/R/eayypaDedvFuKpbepALeFY+xteflEgR9a0CAwEAAaNaMFgwEgYD VR0TAQH/BAgwBgEB/wIBBTAOBgNVHQ8BAf8EBAMCAQYwFwYDVR0gBBAwDjAMBgoq hkiG+Q8KAQUBMBkGA1UdDgQSBBBXRzV7NicRqAj8L0Yl6yRpMA0GCSqGSIb3DQEB BQUAA4IBAQDHYUWoinG5vjTpIXshzVYTmNUwY+kYqkuSFb8LHbvskmnFLsNhi+gw RcsQRsFzOFyLGdIr80DrfHKzLh4n43WVihybLsSVBYZy0FX0oZJSeVzb9Pjc5dcS sUDHPIbkMWVKyjfG3nZXGWlMRmn8Kq0WN3qTrPchSy3766lQy8HRQAjaA2mHpzde VcHF7cTjjgwml5tcV0ty4/IDBdACOyYDQJCevgtbSQx48dVMVSng9v1MA6lUAjLR V1qFrEPtWzsWX6C/NdtLnnvo/+cNPDuom0lBRvVzTv+SZSGDE1Vx60k8f4gawhIo JaFGS0E3l3/sjvHUoZbCILZerakcHhGg -----END CERTIFICATE----- Certificate Ingredients: Data: Version: 3 (0x2) Serial Number: 133 (0x85) Signature Algorithm: sha1WithRSAEncryption Issuer: C=US, O=American Express Company, Inc., OU=American Express Technologies, CN=American Express Global Certificate Authority Validity Not Before: Aug 14 19:06:00 1998 GMT Not After : Aug 14 23:59:00 2013 GMT Subject: C=US, O=American Express Company, Inc., OU=American Express Technologies, CN=American Express Global Certificate Authority Subject Public Key Info: Public Key Algorithm: rsaEncryption RSA Public Key: (2048 bit) Modulus (2048 bit): 00:f0:24:26:66:2e:fb:eb:4a:73:71:53:89:47:cb: 26:3c:53:92:94:4c:ca:c2:85:b5:0d:f8:c3:57:bd: 2f:2a:1f:6a:18:b7:57:af:0c:00:16:fa:a0:b6:90: a6:f7:1a:a1:2e:66:26:c7:68:a3:8a:93:69:66:b5: 46:56:2d:1d:82:ea:90:0c:0a:22:c2:89:50:8d:05: f3:d4:ab:73:41:f0:cf:12:ac:28:b4:6f:14:94:96: 59:4b:9e:90:75:86:df:e2:47:eb:e1:e9:4f:43:7e: 87:ca:27:18:66:9e:b5:c1:40:65:7d:fc:61:6f:ad: 9b:72:cf:a9:5e:d8:f3:f9:da:6e:91:10:fa:4c:b5: ea:7e:20:de:a9:39:2f:f5:88:e4:8a:6f:35:c6:20: 9c:2b:86:46:33:0a:fc:31:55:a5:6b:ac:16:40:e9: cd:35:59:6f:32:04:c3:7b:b5:0f:7b:77:70:f3:48: bb:2a:52:82:ce:af:29:6d:f1:11:6f:6d:e6:07:00: 01:ef:9a:f3:26:0d:a6:79:13:67:af:f8:ab:1c:75: ac:91:b5:6b:be:40:b0:de:9c:0c:b1:69:85:19:71: 91:13:45:ca:df:d1:fd:e6:b2:ca:96:83:79:db:c5: b8:aa:5b:7a:90:0b:78:56:3e:c6:d7:9f:94:48:11: f5:ad Exponent: 65537 (0x10001) X509v3 extensions: X509v3 Basic Constraints: critical CA:TRUE, pathlen:5 X509v3 Key Usage: critical Certificate Sign, CRL Sign X509v3 Certificate Policies: Policy: 1.2.840.113807.10.1.5.1 X509v3 Subject Key Identifier: 57:47:35:7B:36:27:11:A8:08:FC:2F:46:25:EB:24:69 Signature Algorithm: sha1WithRSAEncryption c7:61:45:a8:8a:71:b9:be:34:e9:21:7b:21:cd:56:13:98:d5: 30:63:e9:18:aa:4b:92:15:bf:0b:1d:bb:ec:92:69:c5:2e:c3: 61:8b:e8:30:45:cb:10:46:c1:73:38:5c:8b:19:d2:2b:f3:40: eb:7c:72:b3:2e:1e:27:e3:75:95:8a:1c:9b:2e:c4:95:05:86: 72:d0:55:f4:a1:92:52:79:5c:db:f4:f8:dc:e5:d7:12:b1:40: c7:3c:86:e4:31:65:4a:ca:37:c6:de:76:57:19:69:4c:46:69: fc:2a:ad:16:37:7a:93:ac:f7:21:4b:2d:fb:eb:a9:50:cb:c1: d1:40:08:da:03:69:87:a7:37:5e:55:c1:c5:ed:c4:e3:8e:0c: 26:97:9b:5c:57:4b:72:e3:f2:03:05:d0:02:3b:26:03:40:90: 9e:be:0b:5b:49:0c:78:f1:d5:4c:55:29:e0:f6:fd:4c:03:a9: 54:02:32:d1:57:5a:85:ac:43:ed:5b:3b:16:5f:a0:bf:35:db: 4b:9e:7b:e8:ff:e7:0d:3c:3b:a8:9b:49:41:46:f5:73:4e:ff: 92:65:21:83:13:55:71:eb:49:3c:7f:88:1a:c2:12:28:25:a1: 46:4b:41:37:97:7f:ec:8e:f1:d4:a1:96:c2:20:b6:5e:ad:a9: 1c:1e:11:a0 BelSign Object Publishing CA ============================ MD5 Fingerprint: 8A:02:F8:DF:B8:E1:84:9F:5A:C2:60:24:65:D1:73:FB PEM Data: -----BEGIN CERTIFICATE----- MIIDAzCCAmygAwIBAgIBATANBgkqhkiG9w0BAQQFADCBuzELMAkGA1UEBhMCQkUx ETAPBgNVBAcTCEJydXNzZWxzMRMwEQYDVQQKEwpCZWxTaWduIE5WMTgwNgYDVQQL Ey9CZWxTaWduIE9iamVjdCBQdWJsaXNoaW5nIENlcnRpZmljYXRlIEF1dGhvcml0 eTElMCMGA1UEAxMcQmVsU2lnbiBPYmplY3QgUHVibGlzaGluZyBDQTEjMCEGCSqG SIb3DQEJARYUd2VibWFzdGVyQGJlbHNpZ24uYmUwHhcNOTcwOTE5MjIwMzAwWhcN MDcwOTE5MjIwMzAwWjCBuzELMAkGA1UEBhMCQkUxETAPBgNVBAcTCEJydXNzZWxz MRMwEQYDVQQKEwpCZWxTaWduIE5WMTgwNgYDVQQLEy9CZWxTaWduIE9iamVjdCBQ dWJsaXNoaW5nIENlcnRpZmljYXRlIEF1dGhvcml0eTElMCMGA1UEAxMcQmVsU2ln biBPYmplY3QgUHVibGlzaGluZyBDQTEjMCEGCSqGSIb3DQEJARYUd2VibWFzdGVy QGJlbHNpZ24uYmUwgZ8wDQYJKoZIhvcNAQEBBQADgY0AMIGJAoGBAMQuH7a/7oJA 3fm3LkHVngWxWtAmfGJVA5v8y2HeS+/+6Jn+h7mIz5DaDwk8dt8Xl7bLPyVF/bS8 WAC+sFq2FIeP7mdkrR2Ig7tnn2VhAFgIgFCfgMkx9iqQHC33SmwQ9iNDXTgJYIhX As0WbBj8zfuSKnfQnpOjXYhk0Mj4XVRRAgMBAAGjFTATMBEGCWCGSAGG+EIBAQQE AwIABzANBgkqhkiG9w0BAQQFAAOBgQBjdhd8lvBTpV0BHFPOKcJ+daxMDaIIc7Rq Mf0CBhSZ3FQEpL/IloafMUMyJVf2hfYluze+oXkjyVcGJXFrRU/49AJAFoIir1Tq Mij2De6ZuksIUQ9uhiMhTC0liIHELg7xEyw4ipUCJMM6lWPkk45IuwhHcl+u5jpa R9Zxxp6aUg== -----END CERTIFICATE----- Certificate Ingredients: Data: Version: 3 (0x2) Serial Number: 1 (0x1) Signature Algorithm: md5WithRSAEncryption Issuer: C=BE, L=Brussels, O=BelSign NV, OU=BelSign Object Publishing Certificate Authority, CN=BelSign Object Publishing CA/Email=webmaster@belsign.be Validity Not Before: Sep 19 22:03:00 1997 GMT Not After : Sep 19 22:03:00 2007 GMT Subject: C=BE, L=Brussels, O=BelSign NV, OU=BelSign Object Publishing Certificate Authority, CN=BelSign Object Publishing CA/Email=webmaster@belsign.be Subject Public Key Info: Public Key Algorithm: rsaEncryption RSA Public Key: (1024 bit) Modulus (1024 bit): 00:c4:2e:1f:b6:bf:ee:82:40:dd:f9:b7:2e:41:d5: 9e:05:b1:5a:d0:26:7c:62:55:03:9b:fc:cb:61:de: 4b:ef:fe:e8:99:fe:87:b9:88:cf:90:da:0f:09:3c: 76:df:17:97:b6:cb:3f:25:45:fd:b4:bc:58:00:be: b0:5a:b6:14:87:8f:ee:67:64:ad:1d:88:83:bb:67: 9f:65:61:00:58:08:80:50:9f:80:c9:31:f6:2a:90: 1c:2d:f7:4a:6c:10:f6:23:43:5d:38:09:60:88:57: 02:cd:16:6c:18:fc:cd:fb:92:2a:77:d0:9e:93:a3: 5d:88:64:d0:c8:f8:5d:54:51 Exponent: 65537 (0x10001) X509v3 extensions: Netscape Cert Type: SSL CA, S/MIME CA, Object Signing CA Signature Algorithm: md5WithRSAEncryption 63:76:17:7c:96:f0:53:a5:5d:01:1c:53:ce:29:c2:7e:75:ac: 4c:0d:a2:08:73:b4:6a:31:fd:02:06:14:99:dc:54:04:a4:bf: c8:96:86:9f:31:43:32:25:57:f6:85:f6:25:bb:37:be:a1:79: 23:c9:57:06:25:71:6b:45:4f:f8:f4:02:40:16:82:22:af:54: ea:32:28:f6:0d:ee:99:ba:4b:08:51:0f:6e:86:23:21:4c:2d: 25:88:81:c4:2e:0e:f1:13:2c:38:8a:95:02:24:c3:3a:95:63: e4:93:8e:48:bb:08:47:72:5f:ae:e6:3a:5a:47:d6:71:c6:9e: 9a:52 BelSign Secure Server CA ======================== MD5 Fingerprint: 3D:5E:82:C6:D9:AD:D9:8B:93:6B:0C:10:B9:49:0A:B1 PEM Data: -----BEGIN CERTIFICATE----- MIIC8zCCAlygAwIBAgIBATANBgkqhkiG9w0BAQQFADCBszELMAkGA1UEBhMCQkUx ETAPBgNVBAcTCEJydXNzZWxzMRMwEQYDVQQKEwpCZWxTaWduIE5WMTQwMgYDVQQL EytCZWxTaWduIFNlY3VyZSBTZXJ2ZXIgQ2VydGlmaWNhdGUgQXV0aG9yaXR5MSEw HwYDVQQDExhCZWxTaWduIFNlY3VyZSBTZXJ2ZXIgQ0ExIzAhBgkqhkiG9w0BCQEW FHdlYm1hc3RlckBiZWxzaWduLmJlMB4XDTk3MDcxNjIyMDA1NFoXDTA3MDcxNjIy MDA1NFowgbMxCzAJBgNVBAYTAkJFMREwDwYDVQQHEwhCcnVzc2VsczETMBEGA1UE ChMKQmVsU2lnbiBOVjE0MDIGA1UECxMrQmVsU2lnbiBTZWN1cmUgU2VydmVyIENl cnRpZmljYXRlIEF1dGhvcml0eTEhMB8GA1UEAxMYQmVsU2lnbiBTZWN1cmUgU2Vy dmVyIENBMSMwIQYJKoZIhvcNAQkBFhR3ZWJtYXN0ZXJAYmVsc2lnbi5iZTCBnzAN BgkqhkiG9w0BAQEFAAOBjQAwgYkCgYEA1gESeJL4BEJ/yccig/x8R3AwK0kLPjZA kCjaIXODU/LE0RZAwFP/rqbGJLMnbaWzPTl3XagG9ubpvGMRTgZlcAqdk/miQIt/ SoQOjRax1swIZBIM4ChLyKWEkBf7EUYu1qeFGMsYrmOasFgG9ADP+MQJGjUMofnu Sv1t3v4mpTsCAwEAAaMVMBMwEQYJYIZIAYb4QgEBBAQDAgCgMA0GCSqGSIb3DQEB BAUAA4GBAGw9mcMF4h3K5S2qaIWLQDEgZhNo5lg6idCNdbLFYth9go/32TKBd/Y1 W4UpzmeyubwrGXjP84f9RvGVdbIJVwMwwXrNckdxgMp9ncllPEcRIn36BwsoeKGT 6AVFSOIyMko96FMcELfHc4wHUOH5yStTQfWDjeUJOUqOA2KqQGOL -----END CERTIFICATE----- rapache-1.2.8/libapreq2/module/t/conf/ssl/httpd-passphrase.pl.PL0000644000175100017510000000014212706745114023757 0ustar ondrejondrej#for testing SSLPassPhraseDialog exec:@ServerRoot@/conf/ssl/httpd-passphrase.pl print "httpd\n"; rapache-1.2.8/libapreq2/module/t/conf/ssl/proxyssl.conf.in0000644000175100017510000000351012706745114022777 0ustar ondrejondrej #here we can test http <-> https #these are not on by default in the 1.x based mod_ssl SSLProxyEngine On SSLProxyProtocol +SSLv2 +SSLv3 +TLSv1 SSLProxyCipherSuite ALL:!ADH:RC4+RSA:+HIGH:+MEDIUM:+LOW:+SSLv2:+EXP:+eNULL SSLProxyMachineCertificateFile @SSLCA@/asf/proxy/client_ok.pem #SSLProxyMachineCertificatePath @SSLCA@/asf/proxy SSLProxyCACertificateFile @SSLCA@/asf/certs/ca.crt SSLProxyCACertificatePath @ServerRoot@/conf/ssl SSLProxyCARevocationFile @SSLCA@/asf/crl/ca-bundle.crl SSLProxyVerify on SSLProxyVerifyDepth 10 ProxyPass / https://@proxyssl_url@/ ProxyPassReverse / https://@proxyssl_url@/ #here we can test https <-> https SSLEngine on #these are not on by default in the 1.x based mod_ssl SSLProxyEngine On # ensure that client_ok.pem is picked first: SSLProxyMachineCertificateFile @SSLCA@/asf/proxy/client_ok.pem SSLProxyMachineCertificatePath @SSLCA@/asf/proxy SSLProxyCACertificateFile @SSLCA@/asf/certs/ca.crt SSLProxyVerify on SSLProxyCARevocationPath @SSLCA@/asf/crl ProxyPass / https://@proxyssl_url@/ ProxyPassReverse / https://@proxyssl_url@/ #here we can test https <-> http SSLEngine on ProxyPass / http://@servername@:@port@/ ProxyPassReverse / http://@servername@:@port@/ rapache-1.2.8/libapreq2/module/t/conf/ssl/ssl.conf.in0000644000175100017510000001006312706745114021676 0ustar ondrejondrej#test config derived from httpd-2.0/docs/conf/ssl-std.conf #base config that can be used by any SSL enabled VirtualHosts AddType application/x-x509-ca-cert .crt AddType application/x-pkcs7-crl .crl SSLSessionCache none #XXX: would be nice to test these #SSLSessionCache shm:@ServerRoot@/logs/ssl_scache(512000) #SSLSessionCache dbm:@ServerRoot@/logs/ssl_scache #SSLSessionCacheTimeout 300 #SSLMutex file:@ServerRoot@/logs/ssl_mutex SSLRandomSeed startup builtin SSLRandomSeed connect builtin #SSLRandomSeed startup file:/dev/random 512 #SSLRandomSeed startup file:/dev/urandom 512 #SSLRandomSeed connect file:/dev/random 512 #SSLRandomSeed connect file:/dev/urandom 512 LogFormat "%t %h %{SSL_PROTOCOL}x %{SSL_CIPHER}x \"%r\" %>s %b" ssl CustomLog logs/ssl_request_log ssl SSLCipherSuite ALL:!ADH:RC4+RSA:+HIGH:+MEDIUM:+LOW:+SSLv2:+EXP:+eNULL SSLPassPhraseDialog exec:@ServerRoot@/conf/ssl/httpd-passphrase.pl #else the default is builtin SSLPassPhraseDialog builtin SSLCertificateFile @SSLCA@/asf/certs/server_des3.crt SSLCertificateKeyFile @SSLCA@/asf/keys/server_des3.pem # SSLCertificateFile @SSLCA@/asf/certs/server_des3_dsa.crt # SSLCertificateKeyFile @SSLCA@/asf/keys/server_des3_dsa.pem #else the default is an unencrypted key SSLCertificateFile @SSLCA@/asf/certs/server.crt SSLCertificateKeyFile @SSLCA@/asf/keys/server.pem # SSLCertificateFile @SSLCA@/asf/certs/server_dsa.crt # SSLCertificateKeyFile @SSLCA@/asf/keys/server_dsa.pem #SSLCertificateChainFile @SSLCA@/asf/certs/cachain.crt SSLCACertificateFile @SSLCA@/asf/certs/ca.crt SSLCACertificatePath @ServerRoot@/conf/ssl SSLCARevocationFile @SSLCA@/asf/crl/ca-bundle.crl SSLEngine on #t/ssl/verify.t Alias /verify @DocumentRoot@ SSLVerifyClient require SSLVerifyDepth 10 #t/ssl/require.t Alias /require/asf @DocumentRoot@ Alias /require/snakeoil @DocumentRoot@ Alias /ssl-fakebasicauth @DocumentRoot@ Alias /ssl-cgi @DocumentRoot@/modules/cgi Alias /require-ssl-cgi @DocumentRoot@/modules/cgi SSLVerifyClient require SSLVerifyDepth 10 SSLRequire (%{SSL_CIPHER} !~ m/^(EXP|NULL)-/ \ and %{SSL_CLIENT_S_DN_O} eq "ASF" \ and %{SSL_CLIENT_S_DN_OU} in \ {"httpd-test", "httpd", "modperl"} ) SSLVerifyClient require SSLVerifyDepth 10 SSLRequire (%{SSL_CIPHER} !~ m/^(EXP|NULL)-/ \ and %{SSL_CLIENT_S_DN_O} eq "Snake Oil, Ltd." \ and %{SSL_CLIENT_S_DN_OU} in \ {"Staff", "CA", "Dev"} ) SSLOptions +StdEnvVars SSLOptions +StdEnvVars SSLVerifyClient require SSLVerifyDepth 10 SSLVerifyClient require SSLVerifyDepth 5 SSLOptions +FakeBasicAuth AuthName "Snake Oil Authentication" AuthType Basic AuthUserFile @SSLCA@/asf/ssl.htpasswd require valid-user rapache-1.2.8/libapreq2/module/t/cookie.t0000644000175100017510000000323512706745114017534 0ustar ondrejondrejuse strict; use warnings FATAL => 'all'; use Apache::Test; use Apache::TestUtil; use Apache::TestRequest qw(GET_BODY GET_HEAD); plan tests => 5, have_lwp; require HTTP::Cookies; my $location = "/apreq_cookie_test"; { my $test = 'netscape'; my $key = 'apache'; my $value = 'ok'; my $cookie = qq{$key=$value}; ok t_cmp(GET_BODY("$location?test=$test&key=$key", Cookie => $cookie), $value, $test); } { my $test = 'rfc'; my $key = 'apache'; my $value = 'ok'; my $cookie = qq{\$Version="1"; $key="$value"; \$Path="$location"}; ok t_cmp(GET_BODY("$location?test=$test&key=$key", Cookie => $cookie), qq{"$value"}, $test); } { my $test = 'encoded value with space'; my $key = 'apache'; my $value = 'okie dokie'; my $cookie = "$key=" . join '', map {/ / ? '+' : sprintf '%%%.2X', ord} split //, $value; ok t_cmp(GET_BODY("$location?test=$test&key=$key", Cookie => $cookie), $value, $test); } { my $test = 'bake'; my $key = 'apache'; my $value = 'ok'; my $cookie = "$key=$value"; my ($header) = GET_HEAD("$location?test=$test&key=$key", Cookie => $cookie) =~ /^#Set-Cookie:\s+(.+)/m; ok t_cmp($header, $cookie, $test); } { my $test = 'bake2'; my $key = 'apache'; my $value = 'ok'; my $cookie = qq{\$Version="1"; $key="$value"; \$Path="$location"}; my ($header) = GET_HEAD("$location?test=$test&key=$key", Cookie => $cookie) =~ /^#Set-Cookie2:\s+(.+)/m; ok t_cmp($header, qq{$key="$value"; Version=1; path="$location"}, $test); } rapache-1.2.8/libapreq2/module/t/request.t0000644000175100017510000000723712706745114017761 0ustar ondrejondrejuse strict; use warnings FATAL => 'all'; use Apache::Test; use Apache::TestUtil; use Apache::TestRequest qw(GET_BODY UPLOAD_BODY POST_BODY GET_RC); require File::Copy; my $num_tests = 18; $num_tests *= 2 if Apache::Test::have_ssl(); plan tests => $num_tests, have_lwp; my $scheme = "http"; START_TESTS: Apache::TestRequest::scheme($scheme); foreach my $location ('/apreq_request_test', '/apreq_access_test') { ok t_cmp(GET_BODY("$location?test=1"), "ARGS:\n\ttest => 1\n", "simple get"); ok t_cmp(UPLOAD_BODY("$location?test=2", content => "unused"), "ARGS:\n\ttest => 2\nBODY:\n\tHTTPUPLOAD => b\n", "simple upload"); } ok t_cmp(GET_RC("/apreq_access_test"), 403, "access denied"); my $filler = "0123456789" x 6400; # < 64K my $body = POST_BODY("/apreq_access_test?foo=1;", content => "bar=2&quux=$filler;test=6&more=$filler"); ok t_cmp($body, < 1 BODY: \tbar => 2 \tquux => $filler \ttest => 6 \tmore => $filler EOT ok t_cmp(GET_RC("/apreq_redirect_test"), 403, "missing 'test' authorization"); foreach my $location ('/apreq_request_test', '/apreq_access_test') { ok t_cmp(GET_BODY("/apreq_redirect_test?test=ok&location=$location%3Ftest=redirect"), "ARGS:\n\ttest => redirect\n", "redirect GET"); $body = POST_BODY("/apreq_redirect_test?location=$location%3Ffoo=bar", content => "quux=$filler;test=redirect+with+prefetch;more=$filler"); ok t_cmp($body, < bar BODY: \tquux => $filler \ttest => redirect with prefetch \tmore => $filler EOT } # internal redirect to plain text files (which are non-apreq requests) my $index_html = do {local (@ARGV,$/) = "t/htdocs/index.html"; <> }; my $orig = 't/htdocs/index.html'; my $copy = 't/htdocs/index.txt'; unlink $copy if -f $copy; File::Copy::copy($orig, $copy) or die "Cannot copy $orig to $copy: $!"; $body = GET_BODY("/apreq_redirect_test?test=redirect_index_txt_GET&location=/index.txt"); $body =~ s{\r}{}g; ok t_cmp($body, $index_html, "redirect /index.txt (GET)"); $body = POST_BODY("/apreq_redirect_test?test=redirect_index_txt_POST", content => "quux=$filler;location=/index.txt;foo=$filler"); $body =~ s{\r}{}g; ok t_cmp($body, $index_html, "redirect /index.txt (POST)"); # output filter tests sub filter_content ($) { my $body = shift; $body =~ s/^.*--APREQ OUTPUT FILTER--\s+//s; return $body; } ok t_cmp(GET_RC("/index.html"), 200, "/index.html"); ok t_cmp(filter_content GET_BODY("/index.html?test=13"), "ARGS:\n\ttest => 13\n", "output filter GET"); ok t_cmp(filter_content POST_BODY("/index.html?test=14", content => "post+data=foo;more=$filler;test=output+filter+POST"), < 14 BODY: \tpost data => foo \tmore => $filler \ttest => output filter POST EOT "output filter POST"); # internal redirect to html files which are filtered as above $body = GET_BODY("/apreq_redirect_test?test=redirect_index_html_GET&location=/index.html?foo=bar"); $body =~ s{\r}{}g; ok t_cmp($body, $index_html . < bar EOT $body = POST_BODY("/apreq_redirect_test?test=redirect_index_html_POST", content => "quux=$filler;location=/index.html?foo=quux;foo=$filler"); $body =~ s{\r}{}g; ok t_cmp($body, $index_html . < quux BODY: \tquux => $filler \tlocation => /index.html?foo=quux \tfoo => $filler EOT if (Apache::Test::have_ssl() and $scheme ne 'https') { $scheme = 'https'; goto START_TESTS; } rapache-1.2.8/libapreq2/module/test_cgi.c0000644000175100017510000000670412706745114017604 0ustar ondrejondrej/* ** Copyright 2003-2005 The Apache Software Foundation ** ** Licensed under the Apache License, Version 2.0 (the "License"); ** you may not use this file except in compliance with the License. ** You may obtain a copy of the License at ** ** http://www.apache.org/licenses/LICENSE-2.0 ** ** Unless required by applicable law or agreed to in writing, software ** distributed under the License is distributed on an "AS IS" BASIS, ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ** See the License for the specific language governing permissions and ** limitations under the License. */ #include "apreq_module.h" #include "apreq_util.h" #include "apr_strings.h" #include "apr_lib.h" #include "apr_tables.h" #include static int dump_table(void *count, const char *key, const char *value) { int *c = (int *) count; int value_len = key - value - 1; /* == strlen(value) by construction */ if (value_len) *c += strlen(key) + value_len; return 1; } #define cookie_bake(c) apr_file_printf(out, "Set-Cookie: %s\n", \ apreq_cookie_as_string(c, pool)) #define cookie_bake2(c) apr_file_printf(out, "Set-Cookie2: %s\n", \ apreq_cookie_as_string(c, pool)) int main(int argc, char const * const * argv) { apr_pool_t *pool; apreq_handle_t *req; const apreq_param_t *foo, *bar, *test, *key; apr_file_t *out; atexit(apr_terminate); if (apr_app_initialize(&argc, &argv, NULL) != APR_SUCCESS) { fprintf(stderr, "apr_app_initialize failed\n"); exit(-1); } if (apr_pool_create(&pool, NULL) != APR_SUCCESS) { fprintf(stderr, "apr_pool_create failed\n"); exit(-1); } if (apreq_initialize(pool) != APR_SUCCESS) { fprintf(stderr, "apreq_initialize failed\n"); exit(-1); } req = apreq_handle_cgi(pool); apr_file_open_stdout(&out, pool); foo = apreq_param(req, "foo"); bar = apreq_param(req, "bar"); test = apreq_param(req, "test"); key = apreq_param(req, "key"); if (foo || bar) { apr_file_printf(out, "%s", "Content-Type: text/plain\n\n"); if (foo) { apr_file_printf(out, "\t%s => %s\n", "foo", foo->v.data); } if (bar) { apr_file_printf(out, "\t%s => %s\n", "bar", bar->v.data); } } else if (test && key) { apreq_cookie_t *cookie; char *dest; apr_size_t dlen; cookie = apreq_cookie(req, key->v.data); if (cookie == NULL) { exit(-1); } if (strcmp(test->v.data, "bake") == 0) { cookie_bake(cookie); } else if (strcmp(test->v.data, "bake2") == 0) { cookie_bake2(cookie); } apr_file_printf(out, "%s", "Content-Type: text/plain\n\n"); dest = apr_pcalloc(pool, cookie->v.dlen + 1); if (apreq_decode(dest, &dlen, cookie->v.data, cookie->v.dlen) == APR_SUCCESS) apr_file_printf(out, "%s", dest); else { exit(-1); } } else { const apr_table_t *params = apreq_params(req, pool); int count = 0; apr_file_printf(out, "%s", "Content-Type: text/plain\n\n"); if (params == NULL) { exit(-1); } apr_table_do(dump_table, &count, params, NULL); apr_file_printf(out, "%d", count); } return 0; } rapache-1.2.8/libapreq2/win32/0000755000175100017510000000000012706745114015305 5ustar ondrejondrejrapache-1.2.8/libapreq2/win32/Configure.pl0000644000175100017510000003222712706745114017571 0ustar ondrejondrej#!C:/Perl/bin/perl use strict; use warnings; use FindBin; use Getopt::Long; use File::Spec::Functions qw(devnull catfile catdir path); use Cwd; require Win32; use ExtUtils::MakeMaker; use File::Basename; use Archive::Tar; use File::Path; use LWP::Simple; my ($apache, $debug, $help, $no_perl, $perl); my $VERSION = '2.03-dev'; my $result = GetOptions( 'with-apache2=s' => \$apache, 'debug' => \$debug, 'help' => \$help, 'with-perl=s' => \$perl, 'disable-perl-glue' => \$no_perl, ); usage() if $help; my @path_ext; path_ext(); $apache ||= search(); my $apreq_home = Win32::GetShortPathName($FindBin::Bin); $apreq_home =~ s!/?win32$!!; $apreq_home =~ s!/!\\!g; my $doxygen = which('doxygen'); my $doxysearch = which('doxysearch'); my $cfg = $debug ? 'Debug' : 'Release'; my @tests = qw(cookie parsers params version); my @test_files = map {catfile('library', 't', "$_.t")} @tests; generate_tests($apreq_home, \@tests); my %apr_libs; my %map = (apr => 'libapr.lib', apu => 'libaprutil.lib'); my $devnull = devnull(); foreach (qw(apr apu)) { my $cfg = catfile $apache, 'bin', "$_.bat"; $cfg =~ s!\\!/!g; my $lib; eval {$lib = qx{"$cfg" --$_-lib-file 2>$devnull;}}; if ($@ or not $lib or $lib =~ /usage/i) { $apr_libs{$_} = catfile $apache, 'lib', $map{$_}; } else { $apr_libs{$_} = chomp $lib; } } my $version_check = catfile $apreq_home, 'build', 'version_check.pl'; my $cmd = join ' ', ($^X, $version_check, 'perl_prereqs'); chomp(my $prereq_string = qx{$cmd}); open(my $make, '>Makefile') or die qq{Cannot open Makefile: $!}; print $make <<"END"; # Microsoft Developer Studio Generated NMAKE File. # The following is a trick to get CPAN clients to follow prerequisites: # # $prereq_string # # --- MakeMaker post_initialize section: APREQ_HOME=$apreq_home APR_LIB=$apr_libs{apr} APU_LIB=$apr_libs{apu} CFG=$cfg APACHE=$apache PERL=$^X RM_F=\$(PERL) -MExtUtils::Command -e rm_f DOXYGEN_CONF=\$(APREQ_HOME)\\build\\doxygen.conf.win32 TEST_FILES = @test_files END print $make $_ while (); my $apxs_trial = catfile $apache, 'bin', 'apxs.bat'; my $apxs = (-e $apxs_trial) ? $apxs_trial : which('apxs'); unless ($apxs) { $apxs = fetch_apxs() ? which('apxs') : ''; } my $test = << 'END'; TEST : TEST_APREQ2 PERL_TEST TEST_APREQ2: $(LIBAPREQ) $(MOD) $(MAKE) /nologo /f $(CFG_HOME)\$(APREQ2_TEST).mak CFG="$(APREQ2_TEST) - Win32 $(CFG)" APACHE="$(APACHE)" APREQ_HOME="$(APREQ_HOME)" APR_LIB="$(APR_LIB)" APU_LIB="$(APU_LIB)" set PATH=$(APREQ_HOME)\win32\libs;$(APACHE)\bin;$(PATH) $(PERL) "-MExtUtils::Command::MM" "-e" "test_harness()" $(TEST_FILES) cd $(APREQ_HOME) $(MAKE) /nologo /f $(CFG_HOME)\$(CGITEST).mak CFG="$(CGITEST) - Win32 $(CFG)" APACHE="$(APACHE)" APREQ_HOME="$(APREQ_HOME)" APR_LIB="$(APR_LIB)" APU_LIB="$(APU_LIB)" cd $(APREQ_HOME) END my $clean = << 'END'; CLEAN: cd $(LIBDIR) $(RM_F) *.pch *.exe *.exp *.lib *.pdb *.ilk *.idb *.so *.dll *.obj cd $(TDIR) $(RM_F) *.pch *.exe *.exp *.lib *.pdb *.ilk *.idb *.so *.dll *.obj cd $(APREQ_HOME) !IF EXIST("$(PERLGLUE)\Makefile") cd $(PERLGLUE) $(MAKE) /nologo clean cd $(APREQ_HOME) !ENDIF END if ($apxs) { $test .= << "END"; cd \$(APREQ_MODULE) \$(PERL) t\\TEST.PL -apxs $apxs cd \$(APREQ_HOME) END $clean .= << 'END'; cd $(APREQ_MODULE) $(PERL) t\TEST.PL -clean cd $(APREQ_HOME) END } print $make "\n", $test, "\n"; print $make "\n", $clean, "\n"; if ($doxygen and $doxysearch) { print $make <<"END"; docs: \$(DOXYGEN_CONF) cd \$(APREQ_HOME) "$doxygen" \$(DOXYGEN_CONF) cd \$(APREQ_HOME) END my $bin_abspath = Win32::GetShortPathName(dirname($doxysearch)); open(my $conf, "$apreq_home/build/doxygen.conf.in") or die "Cannot read $apreq_home/build/doxygen.conf.in: $!"; open(my $win32_conf, ">$apreq_home/build/doxygen.conf.win32") or die "Cannot write to $apreq_home/build/doxygen.conf.win32: $!"; while (<$conf>) { s/\@PERL\@/"$^X"/; s/\@PACKAGE\@/libapreq2/; s/\@VERSION\@/$VERSION/; print $win32_conf $_; } close $conf; close $win32_conf; } close $make; # generate_defs(); if (not $no_perl and $] >= 5.008) { my @args = ($^X, "$apreq_home/build/xsbuilder.pl", 'run', 'run'); chdir "$apreq_home/glue/perl"; system(@args) == 0 or die "system @args failed: $?"; chdir $apreq_home; } print << "END"; A Makefile has been generated in $apreq_home. You can now run nmake - builds the libapreq2 library and perl glue nmake test - runs the supplied tests nmake install - install the C libraries and perl glue modules nmake clean - remove intermediate files nmake help - list the nmake targets END if ($doxygen) { print << 'END'; nmake docs - builds documents END } my @args = ($^X, "$apreq_home/win32/apreq2_win32.pl", "--with-apache2=$apache"); system(@args) == 0 or warn "system @args failed: $?"; sub usage { print <<'END'; Usage: perl Configure.pl [--with-apache2=C:\Path\to\Apache2] [--debug] perl Configure.pl --help Options: --with-apache2=C:\Path\to\Apache2 : specify the top-level Apache2 directory --debug : build a debug version --disable-perl-glue : skip building the perl glue --help : print this help message With no options specified, an attempt will be made to find a suitable Apache2 directory, and if found, a non-debug version will be built. END exit; } sub search { my $apache; if (my $bin = which('Apache')) { (my $candidate = dirname($bin)) =~ s!bin$!!; if (-d $candidate and check($candidate)) { $apache = $candidate; } } unless ($apache and -d $apache) { $apache = prompt("Please give the path to your Apache2 installation:", $apache); } die "Can't find a suitable Apache2 installation!" unless ($apache and -d $apache and check($apache)); $apache = Win32::GetShortPathName($apache); $apache =~ s!\\!/!g; $apache =~ s!/$!!; my $ans = prompt(qq{\nUse "$apache" for your Apache2 directory?}, 'yes'); unless ($ans =~ /^y/i) { die <<'END'; Please run this configuration script again, and give the --with-apache2=C:\Path\to\Apache2 option to specify the desired top-level Apache2 directory. END } return $apache; } sub drives { my @drives = (); eval{require Win32API::File;}; return map {"$_:\\"} ('C' .. 'Z') if $@; my @r = Win32API::File::getLogicalDrives(); return unless @r > 0; for (@r) { my $t = Win32API::File::GetDriveType($_); push @drives, $_ if ($t == 3 or $t == 4); } return @drives > 0 ? @drives : undef; } sub check { my $apache = shift; die qq{No libhttpd library found under $apache/lib} unless -e qq{$apache/lib/libhttpd.lib}; die qq{No httpd header found under $apache/include} unless -e qq{$apache/include/httpd.h}; my $vers = qx{"$apache/bin/Apache.exe" -v}; die qq{"$apache" does not appear to be version 2.x} unless $vers =~ m!Apache/2.\d!; return 1; } sub path_ext { if ($ENV{PATHEXT}) { push @path_ext, split ';', $ENV{PATHEXT}; for my $ext (@path_ext) { $ext =~ s/^\.*(.+)$/$1/; } } else { #Win9X: doesn't have PATHEXT push @path_ext, qw(com exe bat); } } sub which { my $program = shift; return unless $program; my @extras = (); my @drives = drives(); (my $program_files = $ENV{ProgramFiles}) =~ s!^\w+:\\!!; if (@drives > 0) { for my $drive (@drives) { for ('Apache2', "$program_files/Apache2", "$program_files/Apache Group/Apache2") { my $bin = catdir $drive, $_, 'bin'; push @extras, $bin if (-d $bin); } } } my @a = map {catfile $_, $program} (path(), @extras); for my $base(@a) { return $base if -x $base; for my $ext (@path_ext) { return "$base.$ext" if -x "$base.$ext"; } } return; } sub generate_defs { my $preamble =<<'END'; LIBRARY EXPORTS END chdir "$apreq_home/env"; my $match = qr{^apreq_env}; my %fns = (); open my $fh, ") { next unless /^APREQ_DECLARE\([^\)]+\)\s*(\w+)/; my $fn = $1; $fns{$fn}++ if $fn =~ /$match/; } close $fh; open my $def, ">../win32/mod_apreq.def" or die "Cannot open win32/mod_apreq.def: $!"; print $def $preamble; print $def $_, "\n" for (sort keys %fns); close $def; } sub generate_tests { my ($top, $test_files) = @_; my $t = catdir $top, 'library', 't'; foreach my $test(@$test_files) { my $file = catfile $t, $test; open my $fh, '>', "$file.t" || die "Cannot open $file.t: $!"; print $fh <<"EOT"; #!$^X exec '$file'; EOT close $fh; } } sub fetch_apxs { print << 'END'; I could not find an apxs utility on your system, which is needed to run tests in the env/ subdirectory. The apxs utiltity (and apr-config and apu-config utilties) have not yet been ported to Apache2 on Win32, but a development port is available, which I can install for you, if you like. END my $ans = prompt('Install apxs?', 'yes'); return unless $ans =~ /^y/i; my $file = 'apxs_win32.tar.gz'; my $remote = 'http://perl.apache.org/dist/win32-bin/' . $file; print "Fetching $remote ... "; unless (is_success(getstore($remote, $file))) { warn "Download of $remote failed"; return; } print " done!\n"; my $arc = Archive::Tar->new($file, 1); $arc->extract($arc->list_files()); my $dir = 'apxs'; unless (-d $dir) { warn "Unpacking $file failed"; return; } print "chdir $dir\n"; chdir $dir or do { warn "chdir to $dir failed: $!"; return; }; my @args = ($^X, 'Configure.pl', "-with-apache2=$apache"); print "@args\n\n"; system(@args) == 0 or do { warn "system @args failed: $?"; return; }; chdir '..'; rmtree($dir, 1, 1) or warn "rmtree of $dir failed: $!"; print "unlink $file\n"; unlink $file or warn "unlink of $file failed: $!"; return 1; } __DATA__ LIBAPREQ=libapreq2 APREQ2_TEST=apreq2_test CGITEST=test_cgi MOD=mod_apreq2 !IF "$(CFG)" != "Release" && "$(CFG)" != "Debug" !MESSAGE Invalid configuration "$(CFG)" specified. !MESSAGE You can specify a configuration when running NMAKE !MESSAGE by defining the macro CFG on the command line. For example: !MESSAGE !MESSAGE NMAKE CFG="Release" !MESSAGE !MESSAGE Possible choices for configuration are: !MESSAGE !MESSAGE "Release" (based on "Win32 (x86) Console Application") !MESSAGE "Debug" (based on "Win32 (x86) Console Application") !MESSAGE !ERROR An invalid configuration is specified. !ENDIF !IF "$(APACHE)" == "" !MESSAGE No Apache directory was specified. !MESSAGE Please run Configure.bat to specify a valid Apache directory. !ERROR !ENDIF !IF "$(OS)" == "Windows_NT" NULL= !ELSE NULL=nul !ENDIF CFG_HOME=$(APREQ_HOME)\win32 LIBDIR=$(CFG_HOME)\libs PERLGLUE=$(APREQ_HOME)\glue\perl APACHE_LIB=$(APACHE)\lib TDIR=$(APREQ_HOME)\library\t APREQ_MODULE=$(APREQ_HOME)\module ALL : MAKE_ALL MAKE_ALL : $(LIBAPREQ) $(MOD) PERL_GLUE $(LIBAPREQ): $(MAKE) /nologo /f $(CFG_HOME)\$(LIBAPREQ).mak CFG="$(LIBAPREQ) - Win32 $(CFG)" APACHE="$(APACHE)" APREQ_HOME="$(APREQ_HOME)" APR_LIB="$(APR_LIB)" APU_LIB="$(APU_LIB)" $(MOD): $(LIBAPREQ) $(MAKE) /nologo /f $(CFG_HOME)\$(MOD).mak CFG="$(MOD) - Win32 $(CFG)" APACHE="$(APACHE)" APREQ_HOME="$(APREQ_HOME)" APR_LIB="$(APR_LIB)" APU_LIB="$(APU_LIB)" PERL_GLUE: $(MOD) cd $(PERLGLUE) $(PERL) Makefile.PL $(MAKE) /nologo cd $(APREQ_HOME) PERL_TEST: $(MOD) cd $(PERLGLUE) !IF !EXIST("$(PERLGLUE)\Makefile") $(PERL) Makefile.PL !ENDIF set PATH=$(APREQ_HOME)\win32\libs;$(APACHE)\bin;$(PATH) $(MAKE) /nologo test cd $(APREQ_HOME) INSTALL : INSTALL_LIBAPREQ2 PERL_INSTALL INSTALL_LIBAPREQ2: $(LIBAPREQ) cd $(LIBDIR) !IF EXIST("$(LIBDIR)\$(MOD).so") copy "$(MOD).so" "$(APACHE)\modules\$(MOD).so" copy "$(MOD).lib" "$(APACHE_LIB)\$(MOD).lib" !ENDIF !IF EXIST("$(LIBDIR)\$(LIBAPREQ).lib") copy "$(LIBAPREQ).lib" "$(APACHE_LIB)\$(LIBAPREQ).lib" !ENDIF !IF EXIST("$(LIBDIR)\$(LIBAPREQ).dll") copy "$(LIBAPREQ).dll" "$(APACHE)\bin\$(LIBAPREQ).dll" !ENDIF cd $(APREQ_HOME) PERL_INSTALL: $(MOD) cd $(PERLGLUE) !IF !EXIST("$(PERLGLUE)\Makefile") $(PERL) Makefile.PL !ENDIF $(MAKE) /nologo install cd $(APREQ_HOME) HELP: @echo nmake - builds the libapreq2 library @echo nmake test - runs the supplied tests @echo nmake mod_apreq - builds mod_apreq @echo nmake clean - clean @echo nmake install - install the C libraries @echo nmake perl_glue - build the perl glue @echo nmake perl_test - test the perl glue @echo nmake perl_install - install the perl glue @echo nmake docs - builds documents (requires doxygen) rapache-1.2.8/libapreq2/win32/README0000644000175100017510000000317312706745114016171 0ustar ondrejondrejThis directory contains the necessary makefiles to build libapreq and related things on Win32 using VC++ 6. Run, from the httpd-apreq-2 top-level directory, perl Makefile.PL to generate the top-level Makefile. Available options are: --with-apache2=C:\Path\to\Apache2 : specify the top-level Apache2 directory --debug : build a debug version --without-perl : skip initialization of perl glue --help : print a help message With no options specified, an attempt will be made to find a suitable Apache2 directory, and if found, a non-debug version will be built. Assuming the configuration is successful, a Makefile will be generated. This can be used as: nmake - builds the libapreq2 library nmake test - runs the supplied tests nmake mod_apreq - builds mod_apreq nmake install - install the C libraries nmake clean - clean nmake perl_glue - build the perl glue nmake perl_test - test the perl glue nmake perl_install - install the perl glue nmake docs - build documentation nmake help - print a usage message The 'docs' target is only available if a doxygen binary is detected. An experimental apxs tool for Win32 is available at http://perl.apache.org/dist/win32-bin/apxs_win32.tar.gz which will be needed to build the env/c-modules tests. If the apxs bat file isn't found on your system, the configuration script should offer to fetch and install it for you. If this is not done, grab the above archive, unpack it, and run the Configure.pl script within the archive to install. rapache-1.2.8/libapreq2/win32/apreq2_test.mak0000644000175100017510000001551012706745114020232 0ustar ondrejondrej# Microsoft Developer Studio Generated NMAKE File, Based on apreq2_test.dsp !IF "$(APACHE)" == "" !MESSAGE No Apache directory was specified. !MESSAGE This makefile is not to be run directly. !MESSAGE Please use Perl Makefile.PL, and then $(MAKE) on Makefile. !ERROR !ENDIF !IF "$(APR_LIB)" == "" !MESSAGE No apr lib was specified. !MESSAGE This makefile is not to be run directly. !MESSAGE Please use Perl Makefile.PL, and then $(MAKE) on Makefile. !ERROR !ENDIF !IF "$(APU_LIB)" == "" !MESSAGE No aprutil lib was specified. !MESSAGE This makefile is not to be run directly. !MESSAGE Please use Perl Makefile.PL, and then $(MAKE) on Makefile. !ERROR !ENDIF !IF "$(CFG)" == "" CFG=apreq2_test - Win32 Release !MESSAGE No configuration specified. Defaulting to apreq2_test - Win32 Debug. !ENDIF !IF "$(CFG)" != "apreq2_test - Win32 Release" && "$(CFG)" != "apreq2_test - Win32 Debug" !MESSAGE Invalid configuration "$(CFG)" specified. !MESSAGE You can specify a configuration when running NMAKE !MESSAGE by defining the macro CFG on the command line. For example: !MESSAGE !MESSAGE NMAKE /f "apreq2_test.mak" CFG="apreq2_test - Win32 Release" !MESSAGE !MESSAGE Possible choices for configuration are: !MESSAGE !MESSAGE "apreq2_test - Win32 Release" (based on "Win32 (x86) Static Library") !MESSAGE "apreq2_test - Win32 Debug" (based on "Win32 (x86) Static Library") !MESSAGE !ERROR An invalid configuration is specified. !ENDIF !IF "$(OS)" == "Windows_NT" NULL= !ELSE NULL=nul !ENDIF CPP=cl.exe RSC=rc.exe CFG_HOME=$(APREQ_HOME)\win32 LIBTDIR=$(APREQ_HOME)\library\t OUTDIR=$(LIBTDIR) INTDIR=$(LIBTDIR) LIBDIR=$(CFG_HOME)\libs PROGRAMS="$(LIBTDIR)\params.exe" "$(LIBTDIR)\version.exe" \ "$(LIBTDIR)\parsers.exe" "$(LIBTDIR)\cookie.exe" !IF "$(CFG)" == "apreq2_test - Win32 Release" ALL : "$(LIBDIR)\apreq2_test.lib" $(PROGRAMS) CLEAN : -@erase "$(INTDIR)\at.obj" -@erase "$(INTDIR)\vc60.idb" -@erase "$(OUTDIR)\apreq2_test.lib" "$(OUTDIR)" : if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)" CPP_PROJ=/nologo /MD /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_MBCS" /D "_LIB" /I"$(APACHE)\include" /I"$(APREQ_HOME)\include" /YX /FD /c BSC32=bscmake.exe BSC32_FLAGS=/nologo /o"$(LIBDIR)\apreq2_test.bsc" LIB32=link.exe -lib LIB32_FLAGS=/nologo /out:"$(LIBDIR)\apreq2_test.lib" LIB32_OBJS= \ "$(LIBDIR)\at.obj" \ "$(APR_LIB)" \ "$(APU_LIB)" "$(LIBDIR)\apreq2_test.lib" : "$(OUTDIR)" $(DEF_FILE) $(LIB32_OBJS) $(LIB32) @<< $(LIB32_FLAGS) $(DEF_FLAGS) $(LIB32_OBJS) << LINK32=link.exe LINK32_FLAGS=kernel32.lib wsock32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /incremental:yes /debug /machine:I386 /pdbtype:sept LINK32_OBJS= \ "$(LIBDIR)\libapreq2.lib" \ "$(LIBDIR)\apreq2_test.lib" \ "$(APR_LIB)" \ "$(APU_LIB)" \ "$(APACHE)\lib\libhttpd.lib" "$(LIBTDIR)\cookie.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS) "$(OUTDIR)\cookie.obj" $(LINK32) /pdb:"$(LIBTDIR)\cookie.pdb" /out:"$(LIBTDIR)\cookie.exe" @<< $(LINK32_FLAGS) $(LINK32_OBJS) "$(OUTDIR)\cookie.obj" << "$(LIBTDIR)\params.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS) "$(OUTDIR)\params.obj" $(LINK32) /pdb:"$(LIBTDIR)\params.pdb" /out:"$(LIBTDIR)\params.exe" @<< $(LINK32_FLAGS) $(LINK32_OBJS) "$(OUTDIR)\params.obj" << "$(LIBTDIR)\parsers.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS) "$(OUTDIR)\parsers.obj" $(LINK32) /pdb:"$(LIBTDIR)\parsers.pdb" /out:"$(LIBTDIR)\parsers.exe" @<< $(LINK32_FLAGS) $(LINK32_OBJS) "$(OUTDIR)\parsers.obj" << "$(LIBTDIR)\version.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS) "$(OUTDIR)\version.obj" $(LINK32) /pdb:"$(LIBTDIR)\version.pdb" /out:"$(LIBTDIR)\version.exe" @<< $(LINK32_FLAGS) $(LINK32_OBJS) "$(OUTDIR)\version.obj" << !ELSEIF "$(CFG)" == "apreq2_test - Win32 Debug" ALL : "$(OUTDIR)\apreq2_test.lib" $(PROGRAMS) CLEAN : -@erase "$(INTDIR)\at.obj" -@erase "$(INTDIR)\vc60.idb" -@erase "$(INTDIR)\vc60.pdb" -@erase "$(OUTDIR)\apreq2_test.lib" "$(OUTDIR)" : if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)" CPP_PROJ=/nologo /MDd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_MBCS" /D "_LIB"/YX /I"$(APACHE)\include" /I"$(APREQ_HOME)\include" /FD /GZ /c BSC32=bscmake.exe BSC32_FLAGS=/nologo /o"$(LIBDIR)\apreq2_test.bsc" LIB32=link.exe -lib LIB32_FLAGS=/nologo /out:"$(LIBDIR)\apreq2_test.lib" LIB32_OBJS= \ "$(LIBDIR)\at.obj" \ "$(APR_LIB)" \ "$(APU_LIB)" "$(LIBDIR)\apreq2_test.lib" : "$(OUTDIR)" $(DEF_FILE) $(LIB32_OBJS) $(LIB32) @<< $(LIB32_FLAGS) $(DEF_FLAGS) $(LIB32_OBJS) << "$(LIBTDIR)\cookie.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS) "$(OUTDIR)\cookie.obj" $(LINK32) /pdb:"$(LIBTDIR)\cookie.pdb" /out:"$(LIBTDIR)\cookie.exe" @<< $(LINK32_FLAGS) $(LINK32_OBJS) "$(OUTDIR)\cookie.obj" << "$(LIBTDIR)\params.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS) "$(OUTDIR)\params.obj" $(LINK32) /pdb:"$(LIBTDIR)\params.pdb" /out:"$(LIBTDIR)\params.exe" @<< $(LINK32_FLAGS) $(LINK32_OBJS) "$(OUTDIR)\params.obj" << "$(LIBTDIR)\parser.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS) "$(OUTDIR)\parser.obj" $(LINK32) /pdb:"$(TESTFILE)\parser.pdb" /out:"$(LIBTDIR)\parser.exe" @<< $(LINK32_FLAGS) $(LINK32_OBJS) "$(OUTDIR)\parser.obj" << "$(LIBTDIR)\version.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS) "$(OUTDIR)\version.obj" $(LINK32) /pdb:"$(LIBTDIR)\version.pdb" /out:"$(LIBTDIR)\version.exe" @<< $(LINK32_FLAGS) $(LINK32_OBJS) "$(OUTDIR)\version.obj" << !ENDIF .c{$(INTDIR)}.obj:: $(CPP) @<< $(CPP_PROJ) $< << .cpp{$(INTDIR)}.obj:: $(CPP) @<< $(CPP_PROJ) $< << .cxx{$(INTDIR)}.obj:: $(CPP) @<< $(CPP_PROJ) $< << .c{$(INTDIR)}.sbr:: $(CPP) @<< $(CPP_PROJ) $< << .cpp{$(INTDIR)}.sbr:: $(CPP) @<< $(CPP_PROJ) $< << .cxx{$(INTDIR)}.sbr:: $(CPP) @<< $(CPP_PROJ) $< << !IF "$(CFG)" == "apreq2_test - Win32 Release" || "$(CFG)" == "apreq2_test - Win32 Debug" SOURCE=$(LIBTDIR)\at.c "$(LIBDIR)\at.obj" : $(SOURCE) "$(INTDIR)" $(CPP) /Fo"$(LIBDIR)\at.obj" $(CPP_PROJ) $(SOURCE) SOURCE=$(LIBTDIR)\cookie.c "$(OUTDIR)\cookie.obj" : $(SOURCE) "$(INTDIR)" $(CPP) /Fo"$(OUTDIR)\cookie.obj" $(CPP_PROJ) $(SOURCE) SOURCE=$(LIBTDIR)\params.c "$(OUTDIR)\params.obj" : $(SOURCE) "$(INTDIR)" $(CPP) /Fo"$(OUTDIR)\params.obj" $(CPP_PROJ) $(SOURCE) SOURCE=$(LIBTDIR)\parsers.c "$(OUTDIR)\parsers.obj" : $(SOURCE) "$(INTDIR)" $(CPP) /Fo"$(OUTDIR)\parsers.obj" $(CPP_PROJ) $(SOURCE) SOURCE=$(LIBTDIR)\version.c "$(OUTDIR)\version.obj" : $(SOURCE) "$(INTDIR)" $(CPP) /Fo"$(OUTDIR)\version.obj" $(CPP_PROJ) $(SOURCE) !ENDIF rapache-1.2.8/libapreq2/win32/apreq2_win32.pl0000755000175100017510000001722712706745114020072 0ustar ondrejondrej#!perl use strict; use Config; use Getopt::Long; require Win32; use ExtUtils::MakeMaker; use File::Spec::Functions qw(catfile catdir); use warnings; use FindBin; BEGIN { die 'This script is intended for Win32' unless $^O =~ /Win32/i; } my $license = <<'END'; # ==================================================================== # # Copyright 2003-2005 The Apache Software Foundation # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. # apreq2 script designed to allow easy command line access to apreq2 # configuration parameters. END my $file = 'apreq2-config.pl'; my $apreq_home = Win32::GetShortPathName($FindBin::Bin); $apreq_home =~ s!/?win32$!!; $apreq_home =~ s!/!\\!g; require "$apreq_home/win32/util.pl"; my ($prefix, $help); GetOptions('with-apache2=s' => \$prefix, 'help' => \$help) or usage($0); usage($0) if $help; unless (defined $prefix and -d $prefix) { $prefix = prompt("Please give the path to your Apache2 installation:", $prefix); } die "Can't find a suitable Apache2 installation!" unless (-d $prefix and check($prefix)); $prefix = Win32::GetShortPathName($prefix); my %ap_dir; foreach (qw(bin lib include build)) { $ap_dir{$_} = catdir $prefix, $_; } my $src_version = catfile $apreq_home, 'include', 'apreq_version.h'; my $apache_version = catfile $ap_dir{include}, 'apreq_version.h'; my $apreq_version = -e $src_version ? $src_version : $apache_version; open(my $inc, $apreq_version) or die "Cannot open $apreq_version: $!"; my %vers; while (<$inc>) { if (/define\s+APREQ_(MAJOR|MINOR|PATCH)_VERSION\s+(\d+)/) { $vers{$1} = $2; } } close $inc; my $dotted = "$vers{MAJOR}.$vers{MINOR}.$vers{PATCH}"; my $src_dir = -d $apreq_home ? $apreq_home : ''; my %apreq_args = (APREQ_MAJOR_VERSION => $vers{MAJOR}, APREQ_DOTTED_VERSION => $dotted, APREQ_LIBNAME => 'libapreq2.lib', prefix => $prefix, exec_prefix => $prefix, bindir => $ap_dir{bin}, libdir => $ap_dir{lib}, datadir => $prefix, installbuilddir => $ap_dir{build}, includedir => $ap_dir{include}, CC => $Config{cc}, CPP => $Config{cpp}, LD => $Config{ld}, SHELL => $ENV{comspec}, CPPFLAGS => '', CFLAGS => q{ /nologo /MD /W3 /O2 /D "WIN32" /D "_WINDOWS" /D "NDEBUG" }, LDFLAGS => q{ kernel32.lib /nologo /subsystem:windows /dll /machine:I386 }, LIBS => '', EXTRA_INCLUDES => '', APREQ_SOURCE_DIR => $src_dir, APREQ_SO_EXT => $Config{dlext}, APREQ_LIB_TARGET => '', ); my $apreq_usage = << 'EOF'; Usage: apreq2-config [OPTION] Known values for OPTION are: --prefix[=DIR] change prefix to DIR --bindir print location where binaries are installed --includedir print location where headers are installed --libdir print location where libraries are installed --cc print C compiler name --cpp print C preprocessor name and any required options --ld print C linker name --cflags print C compiler flags --cppflags print cpp flags --includes print include information --ldflags print linker flags --libs print additional libraries to link against --srcdir print APR-util source directory --installbuilddir print APR-util build helper directory --link-ld print link switch(es) for linking to APREQ --apreq-so-ext print the extensions of shared objects on this platform --apreq-lib-file print the name of the apreq lib file --version print the APR-util version as a dotted triple --help print this help When linking, an application should do something like: APREQ_LIBS="\`apreq2-config --link-ld --libs\`" An application should use the results of --cflags, --cppflags, --includes, and --ldflags in their build process. EOF my $full = catfile $ap_dir{bin}, $file; open(my $fh, '>', $full) or die "Cannot open $full: $!"; print $fh <<"END"; #!$^X use strict; use warnings; use Getopt::Long; use File::Spec::Functions qw(catfile catdir); $license sub usage { print << 'EOU'; $apreq_usage EOU exit(1); } END foreach my $var (keys %apreq_args) { print $fh qq{my \${$var} = q[$apreq_args{$var}];\n}; } print $fh $_ while ; close $fh; my @args = ('pl2bat', $full); system(@args) == 0 or die "system @args failed: $?"; print qq{apreq2-config.bat has been created under $prefix/bin.\n\n}; __DATA__ my %opts = (); GetOptions(\%opts, 'prefix:s', 'bindir', 'includedir', 'libdir', 'cc', 'cpp', 'ld', 'cflags', 'cppflags', 'includes', 'ldflags', 'libs', 'srcdir', 'installbuilddir', 'link-ld', 'apreq-so-ext', 'apreq-lib-file', 'version', 'help' ) or usage(); usage() if ($opts{help} or not %opts); if (exists $opts{prefix} and $opts{prefix} eq "") { print qq{$prefix\n}; exit(0); } my $user_prefix = defined $opts{prefix} ? $opts{prefix} : ''; my %user_dir; if ($user_prefix) { foreach (qw(lib bin include build)) { $user_dir{$_} = catdir $user_prefix, $_; } } my $flags = ''; SWITCH : { local $\ = "\n"; $opts{bindir} and do { print $user_prefix ? $user_dir{bin} : $bindir; last SWITCH; }; $opts{includedir} and do { print $user_prefix ? $user_dir{include} : $includedir; last SWITCH; }; $opts{libdir} and do { print $user_prefix ? $user_dir{lib} : $libdir; last SWITCH; }; $opts{installbuilddir} and do { print $user_prefix ? $user_dir{build} : $installbuilddir; last SWITCH; }; $opts{srcdir} and do { print $APREQ_SOURCE_DIR; last SWITCH; }; $opts{cc} and do { print $CC; last SWITCH; }; $opts{cpp} and do { print $CPP; last SWITCH; }; $opts{ld} and do { print $LD; last SWITCH; }; $opts{cflags} and $flags .= " $CFLAGS "; $opts{cppflags} and $flags .= " $CPPFLAGS "; $opts{includes} and do { my $inc = $user_prefix ? $user_dir{include} : $includedir; $flags .= qq{ /I"$inc" $EXTRA_INCLUDES }; }; $opts{ldflags} and $flags .= " $LDFLAGS "; $opts{libs} and $flags .= " $LIBS "; $opts{'link-ld'} and do { my $libpath = $user_prefix ? $user_dir{lib} : $libdir; $flags .= qq{ /libpath:"$libpath" $APREQ_LIBNAME }; }; $opts{'apreq-so-ext'} and do { print $APREQ_SO_EXT; last SWITCH; }; $opts{'apreq-lib-file'} and do { my $full_apreqlib = $user_prefix ? (catfile $user_dir{lib}, $APREQ_LIBNAME) : (catfile $libdir, $APREQ_LIBNAME); print $full_apreqlib; last SWITCH; }; $opts{version} and do { print $APREQ_DOTTED_VERSION; last SWITCH; }; print $flags if $flags; } exit(0); rapache-1.2.8/libapreq2/win32/libapreq2.mak0000644000175100017510000001344112706745114017663 0ustar ondrejondrej# Microsoft Developer Studio Generated NMAKE File, Based on libapreq.dsp !IF "$(APACHE)" == "" !MESSAGE No Apache directory was specified. !MESSAGE This makefile is not to be run directly. !MESSAGE Please use Perl Makefile.PL, and then $(MAKE) on Makefile. !ERROR !ENDIF !IF "$(APR_LIB)" == "" !MESSAGE No apr lib was specified. !MESSAGE This makefile is not to be run directly. !MESSAGE Please use Perl Makefile.PL, and then $(MAKE) on Makefile. !ERROR !ENDIF !IF "$(APU_LIB)" == "" !MESSAGE No aprutil lib was specified. !MESSAGE This makefile is not to be run directly. !MESSAGE Please use Perl Makefile.PL, and then $(MAKE) on Makefile. !ERROR !ENDIF !IF "$(CFG)" == "" CFG=libapreq2 - Win32 Release !MESSAGE No configuration specified. Defaulting to libapreq2 - Win32 Release. !ENDIF !IF "$(CFG)" != "libapreq2 - Win32 Release" && "$(CFG)" != "libapreq2 - Win32 Debug" !MESSAGE Invalid configuration "$(CFG)" specified. !MESSAGE You can specify a configuration when running NMAKE !MESSAGE by defining the macro CFG on the command line. For example: !MESSAGE !MESSAGE NMAKE /f "libapreq2.mak" CFG="libapreq2 - Win32 Debug" !MESSAGE !MESSAGE Possible choices for configuration are: !MESSAGE !MESSAGE "libapreq2 - Win32 Release" (based on "Win32 (x86) Static Library") !MESSAGE "libapreq2 - Win32 Debug" (based on "Win32 (x86) Static Library") !MESSAGE !ERROR An invalid configuration is specified. !ENDIF !IF "$(OS)" == "Windows_NT" NULL= !ELSE NULL=nul !ENDIF CPP=cl.exe RSC=rc.exe CFG_HOME=$(APREQ_HOME)\win32 OUTDIR=$(CFG_HOME)\libs INTDIR=$(CFG_HOME)\libs LIBDIR=$(APREQ_HOME)\library LINK32_OBJS= \ "$(INTDIR)\cookie.obj" \ "$(INTDIR)\param.obj" \ "$(INTDIR)\parser.obj" \ "$(INTDIR)\parser_header.obj" \ "$(INTDIR)\parser_multipart.obj" \ "$(INTDIR)\parser_urlencoded.obj" \ "$(INTDIR)\util.obj" \ "$(INTDIR)\version.obj" \ "$(INTDIR)\module.obj" \ "$(INTDIR)\module_custom.obj" \ "$(INTDIR)\module_cgi.obj" \ "$(INTDIR)\error.obj" \ "$(APR_LIB)" \ "$(APU_LIB)" !IF "$(CFG)" == "libapreq2 - Win32 Release" ALL : "$(OUTDIR)\libapreq2.dll" "$(OUTDIR)" : if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)" CPP_PROJ=/nologo /MD /W3 /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /I"$(APACHE)\include" /I"$(APREQ_HOME)\include" /YX /FD /c MTL_PROJ=/nologo /D "NDEBUG" /mktyplib203 /win32 BSC32=bscmake.exe BSC32_FLAGS=/nologo /o"$(OUTDIR)\libapreq2.bsc" LINK32=link.exe LINK32_FLAGS=kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /incremental:no /machine:I386 /out:"$(OUTDIR)\libapreq2.dll" /implib:"$(OUTDIR)\libapreq2.lib" "$(OUTDIR)\libapreq2.dll" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS) $(LINK32) @<< $(LINK32_FLAGS) $(DEF_FLAGS) $(LINK32_OBJS) << !ELSEIF "$(CFG)" == "libapreq2 - Win32 Debug" ALL : "$(OUTDIR)\libapreq2.dll" "$(OUTDIR)" : if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)" CPP_PROJ=/nologo /MDd /W3 /Gm /GX /Zi /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /I"$(APACHE)\include" /I"$(APREQ_HOME)\include" /YX /FD /GZ /c MTL_PROJ=/nologo /D "_DEBUG" /mktyplib203 /win32 BSC32=bscmake.exe BSC32_FLAGS=/nologo /o"$(OUTDIR)\libapreq2.bsc" LINK32=link.exe LINK32_FLAGS=kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /incremental:yes /pdb:"$(OUTDIR)\libapreq2.pdb" /debug /machine:I386 /out:"$(OUTDIR)\libapreq2.dll" /implib:"$(OUTDIR)\libapreq2.lib" /pdbtype:sept "$(OUTDIR)\libapreq2.dll" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS) $(LINK32) @<< $(LINK32_FLAGS) $(DEF_FLAGS) $(LINK32_OBJS) << !ENDIF .c{$(INTDIR)}.obj:: $(CPP) @<< $(CPP_PROJ) $< << .cpp{$(INTDIR)}.obj:: $(CPP) @<< $(CPP_PROJ) $< << .cxx{$(INTDIR)}.obj:: $(CPP) @<< $(CPP_PROJ) $< << .c{$(INTDIR)}.sbr:: $(CPP) @<< $(CPP_PROJ) $< << .cpp{$(INTDIR)}.sbr:: $(CPP) @<< $(CPP_PROJ) $< << .cxx{$(INTDIR)}.sbr:: $(CPP) @<< $(CPP_PROJ) $< << !IF "$(CFG)" == "libapreq2 - Win32 Release" || "$(CFG)" == "libapreq2 - Win32 Debug" SOURCE=$(LIBDIR)\cookie.c "$(INTDIR)\cookie.obj" : $(SOURCE) "$(INTDIR)" $(CPP) /Fo"$(INTDIR)\cookie.obj" $(CPP_PROJ) $(SOURCE) SOURCE=$(LIBDIR)\param.c "$(INTDIR)\param.obj" : $(SOURCE) "$(INTDIR)" $(CPP) /Fo"$(INTDIR)\param.obj" $(CPP_PROJ) $(SOURCE) SOURCE=$(LIBDIR)\parser.c "$(INTDIR)\parser.obj" : $(SOURCE) "$(INTDIR)" $(CPP) /Fo"$(INTDIR)\parser.obj" $(CPP_PROJ) $(SOURCE) SOURCE=$(LIBDIR)\parser_header.c "$(INTDIR)\parser_header.obj" : $(SOURCE) "$(INTDIR)" $(CPP) /Fo"$(INTDIR)\parser_header.obj" $(CPP_PROJ) $(SOURCE) SOURCE=$(LIBDIR)\parser_multipart.c "$(INTDIR)\parser_multipart.obj" : $(SOURCE) "$(INTDIR)" $(CPP) /Fo"$(INTDIR)\parser_multipart.obj" $(CPP_PROJ) $(SOURCE) SOURCE=$(LIBDIR)\parser_urlencoded.c "$(INTDIR)\parser_urlencoded.obj" : $(SOURCE) "$(INTDIR)" $(CPP) /Fo"$(INTDIR)\parser_urlencoded.obj" $(CPP_PROJ) $(SOURCE) SOURCE=$(LIBDIR)\version.c "$(INTDIR)\version.obj" : $(SOURCE) "$(INTDIR)" $(CPP) /Fo"$(INTDIR)\version.obj" $(CPP_PROJ) $(SOURCE) SOURCE=$(LIBDIR)\module.c "$(INTDIR)\module.obj" : $(SOURCE) "$(INTDIR)" $(CPP) /Fo"$(INTDIR)\module.obj" $(CPP_PROJ) $(SOURCE) SOURCE=$(LIBDIR)\module_custom.c "$(INTDIR)\module_custom.obj" : $(SOURCE) "$(INTDIR)" $(CPP) /Fo"$(INTDIR)\module_custom.obj" $(CPP_PROJ) $(SOURCE) SOURCE=$(LIBDIR)\module_cgi.c "$(INTDIR)\module_cgi.obj" : $(SOURCE) "$(INTDIR)" $(CPP) /Fo"$(INTDIR)\module_cgi.obj" $(CPP_PROJ) $(SOURCE) SOURCE=$(LIBDIR)\util.c "$(INTDIR)\util.obj" : $(SOURCE) "$(INTDIR)" $(CPP) /Fo"$(INTDIR)\util.obj" $(CPP_PROJ) $(SOURCE) SOURCE=$(LIBDIR)\error.c "$(INTDIR)\error.obj" : $(SOURCE) "$(INTDIR)" $(CPP) /Fo"$(INTDIR)\error.obj" $(CPP_PROJ) $(SOURCE) !ENDIF rapache-1.2.8/libapreq2/win32/mod_apreq2.mak0000644000175100017510000001056712706745114020041 0ustar ondrejondrej# Microsoft Developer Studio Generated NMAKE File, Based on mod_apreq.dsp !IF "$(APACHE)" == "" !MESSAGE No Apache directory was specified. !MESSAGE This makefile is not to be run directly. !MESSAGE Please use Perl Makefile.PL, and then $(MAKE) on Makefile. !ERROR !ENDIF !IF "$(APR_LIB)" == "" !MESSAGE No apr lib was specified. !MESSAGE This makefile is not to be run directly. !MESSAGE Please use Perl Makefile.PL, and then $(MAKE) on Makefile. !ERROR !ENDIF !IF "$(APU_LIB)" == "" !MESSAGE No aprutil lib was specified. !MESSAGE This makefile is not to be run directly. !MESSAGE Please use Perl Makefile.PL, and then $(MAKE) on Makefile. !ERROR !ENDIF !IF "$(CFG)" == "" CFG=mod_apreq2 - Win32 Release !MESSAGE No configuration specified. Defaulting to mod_apreq2 - Win32 Release. !ENDIF !IF "$(CFG)" != "mod_apreq2 - Win32 Release" && "$(CFG)" != "mod_apreq2 - Win32 Debug" !MESSAGE Invalid configuration "$(CFG)" specified. !MESSAGE You can specify a configuration when running NMAKE !MESSAGE by defining the macro CFG on the command line. For example: !MESSAGE !MESSAGE NMAKE /f "mod_apreq2.mak" CFG="mod_apreq2 - Win32 Debug" !MESSAGE !MESSAGE Possible choices for configuration are: !MESSAGE !MESSAGE "mod_apreq2 - Win32 Release" (based on "Win32 (x86) Dynamic-Link Library") !MESSAGE "mod_apreq2 - Win32 Debug" (based on "Win32 (x86) Dynamic-Link Library") !MESSAGE !ERROR An invalid configuration is specified. !ENDIF !IF "$(OS)" == "Windows_NT" NULL= !ELSE NULL=nul !ENDIF CPP=cl.exe MTL=midl.exe RSC=rc.exe CFG_HOME=$(APREQ_HOME)\win32 OUTDIR=$(CFG_HOME)\libs INTDIR=$(CFG_HOME)\libs MODDIR=$(APREQ_HOME)\module\apache2 LINK32_OBJS= \ "$(INTDIR)\handle.obj" \ "$(INTDIR)\filter.obj" \ "$(APR_LIB)" \ "$(APU_LIB)" \ "$(APACHE)\lib\libhttpd.lib" \ "$(OUTDIR)\libapreq2.lib" !IF "$(CFG)" == "mod_apreq2 - Win32 Release" ALL : "$(OUTDIR)\mod_apreq2.dll" "$(OUTDIR)" : if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)" CPP_PROJ=/nologo /MD /W3 /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "MOD_APREQ_EXPORTS" /I"$(APACHE)\include" /I"$(APREQ_HOME)\include" /I"$(MODDIR)" /YX /FD /c MTL_PROJ=/nologo /D "NDEBUG" /mktyplib203 /win32 BSC32=bscmake.exe BSC32_FLAGS=/nologo /o"$(OUTDIR)\mod_apreq2.bsc" LINK32=link.exe LINK32_FLAGS=kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /incremental:no /machine:I386 /out:"$(OUTDIR)\mod_apreq2.so" /implib:"$(OUTDIR)\mod_apreq2.lib" "$(OUTDIR)\mod_apreq2.dll" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS) $(LINK32) @<< $(LINK32_FLAGS) $(LINK32_OBJS) << !ELSEIF "$(CFG)" == "mod_apreq2 - Win32 Debug" ALL : "$(OUTDIR)\mod_apreq2.dll" "$(OUTDIR)" : if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)" CPP_PROJ=/nologo /MDd /W3 /Gm /GX /Zi /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "MOD_APREQ_EXPORTS" /I"$(APACHE)\include" /I"$(APREQ_HOME)\include" /I"$(MODDIR)" /YX /FD /GZ /c MTL_PROJ=/nologo /D "_DEBUG" /mktyplib203 /win32 BSC32=bscmake.exe BSC32_FLAGS=/nologo /o"$(OUTDIR)\mod_apreq2.bsc" LINK32=link.exe LINK32_FLAGS=kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /incremental:yes /pdb:"$(OUTDIR)\mod_apreq2.pdb" /debug /machine:I386 /out:"$(OUTDIR)\mod_apreq2.so" /implib:"$(OUTDIR)\mod_apreq2.lib" /pdbtype:sept "$(OUTDIR)\mod_apreq2.dll" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS) $(LINK32) @<< $(LINK32_FLAGS) $(LINK32_OBJS) << !ENDIF .c{$(INTDIR)}.obj:: $(CPP) @<< $(CPP_PROJ) $< << .cpp{$(INTDIR)}.obj:: $(CPP) @<< $(CPP_PROJ) $< << .cxx{$(INTDIR)}.obj:: $(CPP) @<< $(CPP_PROJ) $< << .c{$(INTDIR)}.sbr:: $(CPP) @<< $(CPP_PROJ) $< << .cpp{$(INTDIR)}.sbr:: $(CPP) @<< $(CPP_PROJ) $< << .cxx{$(INTDIR)}.sbr:: $(CPP) @<< $(CPP_PROJ) $< << !IF "$(CFG)" == "mod_apreq2 - Win32 Release" || "$(CFG)" == "mod_apreq2 - Win32 Debug" SOURCE=$(MODDIR)\filter.c "$(INTDIR)\filter.obj" : $(SOURCE) "$(INTDIR)" $(CPP) /Fo"$(INTDIR)\filter.obj" $(CPP_PROJ) $(SOURCE) SOURCE=$(MODDIR)\handle.c "$(INTDIR)\handle.obj" : $(SOURCE) "$(INTDIR)" $(CPP) /Fo"$(INTDIR)\handle.obj" $(CPP_PROJ) $(SOURCE) !ENDIF rapache-1.2.8/libapreq2/win32/test_cgi.mak0000644000175100017510000001003312706745114017575 0ustar ondrejondrej# Microsoft Developer Studio Generated NMAKE File, Based on testall.dsp !IF "$(APACHE)" == "" !MESSAGE No Apache directory was specified. !MESSAGE This makefile is not to be run directly. !MESSAGE Please use Perl Makefile.PL, and then $(MAKE) on Makefile. !ERROR !ENDIF !IF "$(APR_LIB)" == "" !MESSAGE No apr lib was specified. !MESSAGE This makefile is not to be run directly. !MESSAGE Please use Perl Makefile.PL, and then $(MAKE) on Makefile. !ERROR !ENDIF !IF "$(APU_LIB)" == "" !MESSAGE No aprutil lib was specified. !MESSAGE This makefile is not to be run directly. !MESSAGE Please use Perl Makefile.PL, and then $(MAKE) on Makefile. !ERROR !ENDIF !IF "$(CFG)" == "" CFG=test_cgi - Win32 Release !MESSAGE No configuration specified. Defaulting to test_cgi - Win32 Release. !ENDIF !IF "$(CFG)" != "test_cgi - Win32 Release" && "$(CFG)" != "test_cgi - Win32 Debug" !MESSAGE Invalid configuration "$(CFG)" specified. !MESSAGE You can specify a configuration when running NMAKE !MESSAGE by defining the macro CFG on the command line. For example: !MESSAGE !MESSAGE NMAKE /f "test_cgi.mak" CFG="test_cgi - Win32 Debug" !MESSAGE !MESSAGE Possible choices for configuration are: !MESSAGE !MESSAGE "test_cgi - Win32 Release" (based on "Win32 (x86) Console Application") !MESSAGE "test_cgi - Win32 Debug" (based on "Win32 (x86) Console Application") !MESSAGE !ERROR An invalid configuration is specified. !ENDIF !IF "$(OS)" == "Windows_NT" NULL= !ELSE NULL=nul !ENDIF CFG_HOME=$(APREQ_HOME)\win32 MODULE=$(APREQ_HOME)\module OUTDIR=$(CFG_HOME)\libs INTDIR=$(CFG_HOME)\libs LINK32_OBJS= \ "$(INTDIR)\test_cgi.obj" \ "$(OUTDIR)\libapreq2.lib" \ "$(APR_LIB)" \ "$(APU_LIB)" !IF "$(CFG)" == "test_cgi - Win32 Release" ALL : "$(OUTDIR)\test_cgi.exe" "$(OUTDIR)" : if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)" CPP=cl.exe CPP_PROJ=/nologo /MD /W3 /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /I"$(APACHE)\include" /I"$(APREQ_HOME)\include" /Fp"$(INTDIR)\test_cgi.pch" /YX /FD /c RSC=rc.exe BSC32=bscmake.exe BSC32_FLAGS=/nologo /o"$(OUTDIR)\test_cgi.bsc" LINK32=link.exe LINK32_FLAGS=kernel32.lib wsock32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /incremental:no /pdb:"$(OUTDIR)\test_cgi.pdb" /machine:I386 /out:"$(MODULE)\t\cgi-bin\test_cgi.exe" !ELSEIF "$(CFG)" == "test_cgi - Win32 Debug" ALL : "$(OUTDIR)\test_cgi.exe" "$(OUTDIR)" : if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)" CPP=cl.exe CPP_PROJ=/nologo /MDd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /I"$(APACHE)\include" /I"$(APREQ_HOME)\include" /YX /FD /GZ /c RSC=rc.exe BSC32=bscmake.exe BSC32_FLAGS=/nologo /o"$(OUTDIR)\test_cgi.bsc" LINK32=link.exe LINK32_FLAGS=kernel32.lib wsock32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /incremental:yes /pdb:"$(OUTDIR)\test_cgi.pdb" /debug /machine:I386 /out:"$(MODULE)\t\cgi-bin\test_cgi.exe" /pdbtype:sept !ENDIF !IF "$(CFG)" == "test_cgi - Win32 Release" || "$(CFG)" == "test_cgi - Win32 Debug" .c{$(INTDIR)}.obj:: $(CPP) @<< $(CPP_PROJ) $< << .cpp{$(INTDIR)}.obj:: $(CPP) @<< $(CPP_PROJ) $< << .cxx{$(INTDIR)}.obj:: $(CPP) @<< $(CPP_PROJ) $< << .c{$(INTDIR)}.sbr:: $(CPP) @<< $(CPP_PROJ) $< << .cpp{$(INTDIR)}.sbr:: $(CPP) @<< $(CPP_PROJ) $< << .cxx{$(INTDIR)}.sbr:: $(CPP) @<< $(CPP_PROJ) $< << "$(OUTDIR)\test_cgi.exe" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS) $(LINK32) @<< $(LINK32_FLAGS) $(LINK32_OBJS) << SOURCE=$(MODULE)\test_cgi.c "$(INTDIR)\test_cgi.obj" : $(SOURCE) "$(INTDIR)" $(CPP) /Fo"$(INTDIR)\test_cgi.obj" $(CPP_PROJ) $(SOURCE) !ENDIF rapache-1.2.8/libapreq2/win32/util.pl0000644000175100017510000000144712706745114016625 0ustar ondrejondrejsub usage { my $script = shift; print <<"END"; Usage: perl $script [--with-apache2=C:\Path\to\Apache2] perl $script --help Options: --with-apache2=C:\Path\to\Apache2 : specify the top-level Apache2 directory --help : print this help message With no options specified, an attempt will be made to find a suitable Apache2 directory. END exit; } sub check { my $apache = shift; die qq{No libhttpd library found under $apache/lib} unless -e qq{$apache/lib/libhttpd.lib}; die qq{No httpd header found under $apache/include} unless -e qq{$apache/include/httpd.h}; my $vers = qx{"$apache/bin/Apache.exe" -v}; die qq{"$apache" does not appear to be version 2.0} unless $vers =~ m!Apache/2.0!; return 1; } 1; rapache-1.2.8/m4/0000755000175100017510000000000012706745114013002 5ustar ondrejondrejrapache-1.2.8/m4/ax_with_apxs.m40000644000175100017510000000347712706745114015755 0ustar ondrejondrej# =========================================================================== # http://www.gnu.org/software/autoconf-archive/ax_with_apxs.html # =========================================================================== # # SYNOPSIS # # AX_WITH_APXS([value-if-not-found], [path]) # # DESCRIPTION # # Locates an installed apxs binary, placing the result in the precious # variable $APXS. Accepts a preset $APXS, then --with-apxs, and failing # that searches for apxs in the given path (which defaults to the system # path). If apxs is found, $APXS is set to the full path of the binary; # otherwise it is set to VALUE-IF-NOT-FOUND, which defaults to apxs. # # Example: # # AX_WITH_APXS(missing) # # LICENSE # # Copyright (c) 2008 Dustin J. Mitchell # # Copying and distribution of this file, with or without modification, are # permitted in any medium without royalty provided the copyright notice # and this notice are preserved. This file is offered as-is, without any # warranty. #serial 10 AC_DEFUN([AX_WITH_APXS], [ AC_ARG_VAR([APXS]) dnl unless APXS was supplied to us (as a precious variable) if test -z "$APXS" then AC_MSG_CHECKING(for --with-apxs) AC_ARG_WITH(apxs, AS_HELP_STRING([--with-apxs=APXS], [absolute path name of apxs executable]), [ if test "$withval" != "yes" then APXS="$withval" AC_MSG_RESULT($withval) else AC_MSG_RESULT(no) fi ], [ AC_MSG_RESULT(no) ]) fi dnl if it's still not found, check the paths, or use the fallback if test -z "$APXS" then AC_PATH_PROG([APXS], apxs, m4_ifval([$1],[$1],[apxs]), $2) fi ]) rapache-1.2.8/m4/libtool.m40000644000175100017510000077464712706745114014741 0ustar ondrejondrej# libtool.m4 - Configure libtool for the host system. -*-Autoconf-*- # # 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. 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 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. ]) # 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])]) # _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 ]) # 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 _LT_SETUP # Only expand once: m4_define([LT_INIT]) ])# LT_INIT # 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], []) # _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-%%"` ]) # _LT_FILEUTILS_DEFAULTS # ---------------------- # 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 _LT_CHECK_OBJDIR m4_require([_LT_TAG_COMPILER])dnl _LT_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 # 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' # 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 ## ------------------------------------- ## ## Accumulate code for creating libtool. ## ## ------------------------------------- ## # 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]) # _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]) ]) # _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], [[!?.]$], [], [.]) )]) ## ------------------------ ## ## FIXME: Eliminate VARNAME ## ## ------------------------ ## # _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])])]) ]) # _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 ]) # 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 ]) # _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: # # ='`$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)])])]) # _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 ]) # _LT_LIBTOOL_DECLARE(VARNAME, [TAG]) # ----------------------------------- # Extract the dictionary values for VARNAME (optionally with TAG) and # expand to a commented shell variable setting: # # # 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 ]) # _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])])])]) # _LT_TAGVAR(VARNAME, [TAGNAME]) # ------------------------------ m4_define([_LT_TAGVAR], [m4_ifval([$2], [$1_$2], [$1])]) # _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], [ # 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' _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 ]) # 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 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. Usage: $[0] [[OPTIONS]] -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 Report bugs to ." 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." 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.]) ;; esac shift done 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. # _LT_COPYING _LT_LIBTOOL_TAGS # ### BEGIN LIBTOOL CONFIG _LT_LIBTOOL_CONFIG_VARS _LT_LIBTOOL_TAG_VARS # ### END LIBTOOL CONFIG _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 ;; esac _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], []) # C support is built-in for now m4_define([_LT_LANG_C_enabled], []) m4_define([_LT_TAGS], []) # 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 # _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 _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 # 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 ])# _LT_TAG_COMPILER # _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 # _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 # _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]) 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 ]) # _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 ;; 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 ]) # _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 # _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 # _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} 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 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 if test "X[$]1" = X--fallback-echo; then # used as fallback echo shift cat <<_LT_EOF [$]* _LT_EOF exit 0 fi # 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 "$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 "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 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` && 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 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" fi 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 # _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 # 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* ;; 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* ;; *-*-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 need_locks="$enable_libtool_lock" ])# _LT_ENABLE_LOCK # _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]) AC_CHECK_TOOL(STRIP, strip, :) test -z "$STRIP" && STRIP=: _LT_DECL([], [STRIP], [1], [A symbol stripping program]) AC_CHECK_TOOL(RANLIB, ranlib, :) test -z "$RANLIB" && RANLIB=: _LT_DECL([], [RANLIB], [1], [Commands used to install an old-style archive]) # 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 _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 # _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* ]) if test x"[$]$2" = xyes; then m4_if([$5], , :, [$5]) else m4_if([$6], , :, [$6]) fi ])# _LT_COMPILER_OPTION # Old name: AU_ALIAS([AC_LIBTOOL_COMPILER_OPTION], [_LT_COMPILER_OPTION]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION], []) # _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" ]) if test x"[$]$2" = xyes; then m4_if([$4], , :, [$4]) else m4_if([$5], , :, [$5]) fi ])# _LT_LINKER_OPTION # Old name: AU_ALIAS([AC_LIBTOOL_LINKER_OPTION], [_LT_LINKER_OPTION]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AC_LIBTOOL_LINKER_OPTION], []) # 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" 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; ;; 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 # 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) 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], []) # _LT_HEADER_DLFCN # ---------------- m4_defun([_LT_HEADER_DLFCN], [AC_CHECK_HEADERS([dlfcn.h], [], [], [AC_INCLUDES_DEFAULT])dnl ])# _LT_HEADER_DLFCN # _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] 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" #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); */ } else puts (dlerror ()); 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 fi rm -fr conftest* ])# _LT_TRY_DLOPEN_SELF # 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" save_LDFLAGS="$LDFLAGS" wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" save_LIBS="$LIBS" LIBS="$lt_cv_dlopen_libs $LIBS" 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) ]) 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 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 _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 # 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], []) # _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 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 # _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]) 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 else need_locks=no fi _LT_DECL([], [need_locks], [1], [Must we lock files when doing compilation?]) ])# _LT_COMPILER_FILE_LOCKS # _LT_CHECK_OBJDIR # ---------------- 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 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 _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 # _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 # 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)]) 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 fi _LT_TAGDECL([], [hardcode_action], [0], [How to hardcode a shared library path into an executable]) ])# _LT_LINKER_HARDCODE_LIBPATH # _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]) 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 _LT_DECL([], [old_striplib], [1], [Commands to strip libraries]) _LT_DECL([], [striplib], [1]) ])# _LT_CMD_STRIPLIB # _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 # 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*) 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 ;; 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* | cegcc*) version_type=windows shrext_cmds=".dll" need_version=no need_lib_prefix=no 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 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 ;; *) 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`' 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' ;; 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 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 ;; # This must be Linux ELF. linux* | k*bsd*-gnu | kopensolaris*-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 # 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' ;; netbsdelf*-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 shlibpath_overrides_runpath=no hardcode_into_libs=yes dynamic_linker='NetBSD ld.elf_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 ;; 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 ;; *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 ;; 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 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 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' ;; 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 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" 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 _LT_DECL([], [variables_saved_for_relink], [1], [Variables whose values should be saved in libtool wrapper scripts and restored at link time]) _LT_DECL([], [need_lib_prefix], [0], [Do we need the "lib" prefix for modules?]) _LT_DECL([], [need_version], [0], [Do we need a version for libraries?]) _LT_DECL([], [version_type], [0], [Library versioning type]) _LT_DECL([], [runpath_var], [0], [Shared library runtime path variable]) _LT_DECL([], [shlibpath_var], [0],[Shared library path variable]) _LT_DECL([], [shlibpath_overrides_runpath], [0], [Is shlibpath searched before the hard-coded library search path?]) _LT_DECL([], [libname_spec], [1], [Format of library name prefix]) _LT_DECL([], [library_names_spec], [1], [[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]]) _LT_DECL([], [soname_spec], [1], [[The coded name of the library, if different from the real name]]) _LT_DECL([], [postinstall_cmds], [2], [Command to use after installation of a shared archive]) _LT_DECL([], [postuninstall_cmds], [2], [Command to use after uninstallation of a shared archive]) _LT_DECL([], [finish_cmds], [2], [Commands used to finish a libtool library installation in a directory]) _LT_DECL([], [finish_eval], [1], [[As "finish_cmds", except a single script fragment to be evaled but not shown]]) _LT_DECL([], [hardcode_into_libs], [0], [Whether we should hardcode library paths into libraries]) _LT_DECL([], [sys_lib_search_path_spec], [2], [Compile-time system search path for libraries]) _LT_DECL([], [sys_lib_dlsearch_path_spec], [2], [Run-time system search path for libraries]) ])# _LT_SYS_DYNAMIC_LINKER # _LT_PATH_TOOL_PREFIX(TOOL) # -------------------------- # find a file program which can recognize shared library AC_DEFUN([_LT_PATH_TOOL_PREFIX], [m4_require([_LT_DECL_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="m4_if([$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 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 _LT_EOF fi ;; esac fi 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]) 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 &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 ;; 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' ;; 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 ;; 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 | kopensolaris*-gnu) lt_cv_deplibs_check_method=pass_all ;; netbsd* | netbsdelf*-gnu) 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 ;; 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 _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 # 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" 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], []) # 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 # Old name: AU_ALIAS([AC_CHECK_LIBM], [LT_LIB_M]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AC_CHECK_LIBM], []) # _LT_COMPILER_NO_RTTI([TAGNAME]) # ------------------------------- m4_defun([_LT_COMPILER_NO_RTTI], [m4_require([_LT_TAG_COMPILER])dnl _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= if test "$GCC" = yes; then _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' _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"]) fi _LT_TAGDECL([no_builtin_flag], [lt_prog_compiler_no_builtin_flag], [1], [Compiler flag to turn off builtin functions]) ])# _LT_COMPILER_NO_RTTI # _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 # 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?!! ;)] # 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]]*\)' # 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]]' 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'" # 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 # 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" # 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 # Check to see that the pipe works correctly. pipe_works=no 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 # 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' cat <<_LT_EOF >> conftest.$ac_ext /* 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} }; /* 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 # 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 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* # 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 _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 # _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)= 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' 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 ;; 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. ;; sysv4*MP*) if test -d /usr/nec; then _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic 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' ;; 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 | kopensolaris*-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* | netbsdelf*-gnu) ;; *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 ;; beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) # PIC is the default for these OSes. ;; 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']) ;; 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' ;; 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 ;; 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_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no enable_shared=no ;; *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' ;; sysv4*MP*) if test -d /usr/nec; then _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic fi ;; *) _LT_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_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 ;; 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']) ;; 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' ;; 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' ;; linux* | k*bsd*-gnu | kopensolaris*-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' ;; *) 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 ;; 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' ;; 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' ;; rdos*) _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' ;; 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 ;; 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' ;; 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' ;; 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 ;; 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' ;; unicos*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no ;; uts4*) _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; *) _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no ;; 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' ;; linux* | k*bsd*-gnu) _LT_TAGVAR(link_all_deplibs, $1)=no ;; *) _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' ;; 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 ;; linux* | k*bsd*-gnu) _LT_TAGVAR(link_all_deplibs, $1)=no ;; esac _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}' # 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' else _LT_TAGVAR(whole_archive_flag_spec, $1)= fi supports_anon_versioning=no case `$LD -v 2>&1` in *GNU\ gold*) supports_anon_versioning=yes ;; *\ [[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 _LT_TAGVAR(ld_shlibs, $1)=no cat <<_LT_EOF 1>&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. _LT_EOF 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 ;; 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 ;; 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 ;; 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 | kopensolaris*-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' 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 ;; netbsd* | netbsdelf*-gnu) 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 ;; 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. _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 ;; 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. _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' else _LT_TAGVAR(ld_shlibs, $1)=no fi ;; esac ;; 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 ;; *) 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 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)= 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 ;; 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 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 "$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_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 _LT_TAGVAR(link_all_deplibs, $1)=no 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 _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 ;; 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 ;; esac ;; bsdi[[45]]*) _LT_TAGVAR(export_dynamic_flag_spec, $1)=-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. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' _LT_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_TAGVAR(archive_cmds, $1)='$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. _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' # FIXME: Should let the user specify the lib program. _LT_TAGVAR(old_archive_cmds, $1)='lib -OUT:$oldlib$oldobjs$old_deplibs' _LT_TAGVAR(fix_srcfile_path, $1)='`cygpath -w "$srcfile"`' _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes ;; darwin* | rhapsody*) _LT_DARWIN_LINKER_FEATURES($1) ;; dgux*) _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 ;; freebsd1*) _LT_TAGVAR(ld_shlibs, $1)=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*) _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no ;; # Unfortunately, older versions of FreeBSD 2 do not have this feature. freebsd2*) _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_minus_L, $1)=yes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no ;; # 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 ;; 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 # 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*) 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 ;; 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)=: 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' # 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 ;; 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 ;; netbsd* | netbsdelf*-gnu) 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 ;; 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 ;; *nto* | *qnx*) ;; 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 ;; 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' ;; 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)=: ;; 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' # 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' ;; *) 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' ;; 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 ;; 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 ;; 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 ;; 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 ;; 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 ;; 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 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_TAGVAR(with_gnu_ld, $1)=$with_gnu_ld _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 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 _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]) # ------------------------ # 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" AC_LANG_PUSH(C) # Source file extension for C test sources. ac_ext=c # Object file extension for compiled C test sources. objext=o _LT_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(){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 # save warnings/boilerplate of simple test code _LT_COMPILER_BOILERPLATE _LT_LINKER_BOILERPLATE ## 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... 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*) 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_CONFIG($1) fi AC_LANG_POP CC="$lt_save_CC" ])# _LT_LANG_C_CONFIG # _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 else _lt_caught_CXX_error=yes fi popdef([AC_MSG_ERROR]) ])# _LT_PROG_CXX dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([_LT_PROG_CXX], []) # _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 # Source file extension for C++ test sources. ac_ext=cpp # 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 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' else _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= 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"' 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 ;; 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. _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 _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 ;; 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 ;; 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 ;; freebsd-elf*) _LT_TAGVAR(archive_cmds_need_lc, $1)=no ;; freebsd* | dragonfly*) # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF # conventions _LT_TAGVAR(ld_shlibs, $1)=yes ;; gnu*) ;; 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 ;; 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 ;; 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' ;; 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 | kopensolaris*-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' ;; *) # 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' ;; 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' ;; esac ;; esac ;; lynxos*) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; m88k*) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; 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 ;; 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::"' ;; *nto* | *qnx*) _LT_TAGVAR(ld_shlibs, $1)=yes ;; openbsd2*) # C++ shared libraries are fairly broken _LT_TAGVAR(ld_shlibs, $1)=no ;; 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 fi ;; 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_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 "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' ;; *) 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 ;; 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' # 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' # 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 ;; 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' 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 ;; 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' 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 ;; tandem*) case $cc_basename in NCC*) # NonStop-UX NCC 3.20 # 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 ;; vxworks*) # 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 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 AC_LANG_POP ])# _LT_LANG_CXX_CONFIG # _LT_SYS_HIDDEN_LIBDEPS([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)= 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 int a; void foo (void) { a = 0; } _LT_EOF ], [$1], [CXX], [cat > conftest.$ac_ext <<_LT_EOF class Foo { public: Foo (void) { a = 0; } private: int a; }; _LT_EOF ], [$1], [F77], [cat > conftest.$ac_ext <<_LT_EOF subroutine foo implicit none integer*4 a a=0 return end _LT_EOF ], [$1], [FC], [cat > 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 public class foo { private int a; public void bar (void) { a = 0; } }; _LT_EOF ]) dnl Parse the compiler output and extract the necessary dnl objects, libraries and library flags. if AC_TRY_EVAL(ac_compile); 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 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 "$_LT_TAGVAR(compiler_lib_search_path, $1)"; then _LT_TAGVAR(compiler_lib_search_path, $1)="${prev}${p}" else _LT_TAGVAR(compiler_lib_search_path, $1)="${_LT_TAGVAR(compiler_lib_search_path, $1)} ${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 "$_LT_TAGVAR(postdeps, $1)"; then _LT_TAGVAR(postdeps, $1)="${prev}${p}" else _LT_TAGVAR(postdeps, $1)="${_LT_TAGVAR(postdeps, $1)} ${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 "$_LT_TAGVAR(predep_objects, $1)"; then _LT_TAGVAR(predep_objects, $1)="$p" else _LT_TAGVAR(predep_objects, $1)="$_LT_TAGVAR(predep_objects, $1) $p" fi else if test -z "$_LT_TAGVAR(postdep_objects, $1)"; then _LT_TAGVAR(postdep_objects, $1)="$p" else _LT_TAGVAR(postdep_objects, $1)="$_LT_TAGVAR(postdep_objects, $1) $p" fi fi ;; *) ;; # Ignore the rest. esac done # Clean up. rm -f a.out a.exe else echo "libtool.m4: error: problem compiling $1 test program" fi $RM -f confest.$objext # PORTME: override above test on systems where it is broken m4_if([$1], [CXX], [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. _LT_TAGVAR(predep_objects,$1)= _LT_TAGVAR(postdep_objects,$1)= _LT_TAGVAR(postdeps,$1)= ;; 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 _LT_TAGVAR(postdeps,$1)='-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 _LT_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 ;; 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], []) # _LT_LANG_F77_CONFIG([TAG]) # -------------------------- # 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 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 # Source file extension for Java test sources. ac_ext=java # Object file extension for compiled Java test sources. objext=o _LT_TAGVAR(objext, $1)=$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. _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 GCC=yes CC=${GCJ-"gcj"} compiler=$CC _LT_TAGVAR(compiler, $1)=$CC _LT_TAGVAR(LD, $1)="$LD" _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 _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds ## 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... 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_CONFIG($1) fi AC_LANG_RESTORE GCC=$lt_save_GCC CC="$lt_save_CC" ])# _LT_LANG_GCJ_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 # Source file extension for RC test sources. ac_ext=rc # Object file extension for compiled RC test sources. objext=o _LT_TAGVAR(objext, $1)=$objext # Code to be used in simple compile tests lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }' # 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. _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 GCC= CC=${RC-"windres"} compiler=$CC _LT_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 ]) rapache-1.2.8/m4/ltoptions.m40000644000175100017510000002724212706745114015306 0ustar ondrejondrej# 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 ## --------------------------------- ## ## Macros to handle LT_INIT options. ## ## --------------------------------- ## # _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_OPTION_DEFINE(MACRO-NAME, OPTION-NAME, CODE) # ----------------------------------------------- m4_define([LT_OPTION_DEFINE], [m4_define(_LT_MANGLE_DEFUN([$1], [$2]), [$3])[]dnl ])# LT_OPTION_DEFINE # 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.]) ]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AC_LIBTOOL_DLOPEN], []) # win32-dll # --------- # Declare package support for building win32 dll's. LT_OPTION_DEFINE([LT_INIT], [win32-dll], [enable_win32_dll=yes 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 test -z "$AS" && AS=as _LT_DECL([], [AS], [0], [Assembler program])dnl test -z "$DLLTOOL" && DLLTOOL=dlltool _LT_DECL([], [DLLTOOL], [0], [DLL creation program])dnl test -z "$OBJDUMP" && OBJDUMP=objdump _LT_DECL([], [OBJDUMP], [0], [Object dumper program])dnl ])# win32-dll 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.]) ]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AC_LIBTOOL_WIN32_DLL], []) # _LT_ENABLE_SHARED([DEFAULT]) # ---------------------------- # 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 ;; *) 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=]_LT_ENABLE_SHARED_DEFAULT) _LT_DECL([build_libtool_libs], [enable_shared], [0], [Whether or not to build shared libraries]) ])# _LT_ENABLE_SHARED LT_OPTION_DEFINE([LT_INIT], [shared], [_LT_ENABLE_SHARED([yes])]) LT_OPTION_DEFINE([LT_INIT], [disable-shared], [_LT_ENABLE_SHARED([no])]) # Old names: AC_DEFUN([AC_ENABLE_SHARED], [_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[shared]) ]) AC_DEFUN([AC_DISABLE_SHARED], [_LT_SET_OPTION([LT_INIT], [disable-shared]) ]) AU_DEFUN([AM_ENABLE_SHARED], [AC_ENABLE_SHARED($@)]) AU_DEFUN([AM_DISABLE_SHARED], [AC_DISABLE_SHARED($@)]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AM_ENABLE_SHARED], []) dnl AC_DEFUN([AM_DISABLE_SHARED], []) # _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) _LT_DECL([build_old_libs], [enable_static], [0], [Whether or not to build static libraries]) ])# _LT_ENABLE_STATIC LT_OPTION_DEFINE([LT_INIT], [static], [_LT_ENABLE_STATIC([yes])]) LT_OPTION_DEFINE([LT_INIT], [disable-static], [_LT_ENABLE_STATIC([no])]) # Old names: AC_DEFUN([AC_ENABLE_STATIC], [_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[static]) ]) AC_DEFUN([AC_DISABLE_STATIC], [_LT_SET_OPTION([LT_INIT], [disable-static]) ]) AU_DEFUN([AM_ENABLE_STATIC], [AC_ENABLE_STATIC($@)]) AU_DEFUN([AM_DISABLE_STATIC], [AC_DISABLE_STATIC($@)]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AM_ENABLE_STATIC], []) dnl AC_DEFUN([AM_DISABLE_STATIC], []) # _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) _LT_DECL([fast_install], [enable_fast_install], [0], [Whether or not to optimize for fast installation])dnl ])# _LT_ENABLE_FAST_INSTALL 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])]) # 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.]) ]) 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.]) ]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AC_ENABLE_FAST_INSTALL], []) dnl AC_DEFUN([AM_DISABLE_FAST_INSTALL], []) # _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]) test -z "$pic_mode" && pic_mode=m4_default([$1], [default]) _LT_DECL([], [pic_mode], [0], [What type of objects to build])dnl ])# _LT_WITH_PIC LT_OPTION_DEFINE([LT_INIT], [pic-only], [_LT_WITH_PIC([yes])]) LT_OPTION_DEFINE([LT_INIT], [no-pic], [_LT_WITH_PIC([no])]) # 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.]) ]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AC_LIBTOOL_PICMODE], []) ## ----------------- ## ## LTDL_INIT Options ## ## ----------------- ## 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])]) 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])]) rapache-1.2.8/m4/ltsugar.m40000644000175100017510000001042412706745114014726 0ustar ondrejondrej# 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. # serial 6 ltsugar.m4 # This is to help aclocal find these macros, as it can't see m4_define. AC_DEFUN([LTSUGAR_VERSION], [m4_if([0.1])]) # 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])]) # lt_dict_add_subkey(DICT, KEY, SUBKEY, VALUE) # -------------------------------------------- m4_define([lt_dict_add_subkey], [m4_define([$1($2:$3)], [$4])]) # 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)])]))]) # 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])]) # 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 ]) rapache-1.2.8/m4/ltversion.m40000644000175100017510000000127712706745114015300 0ustar ondrejondrej# 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. # Generated from ltversion.in. # serial 3017 ltversion.m4 # This file is part of GNU Libtool m4_define([LT_PACKAGE_VERSION], [2.2.6b]) m4_define([LT_PACKAGE_REVISION], [1.3017]) AC_DEFUN([LTVERSION_VERSION], [macro_version='2.2.6b' macro_revision='1.3017' _LT_DECL(, macro_version, 0, [Which release of libtool.m4 was used?]) _LT_DECL(, macro_revision, 0) ]) rapache-1.2.8/m4/lt~obsolete.m40000644000175100017510000001311312706745114015615 0ustar ondrejondrej# 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. # serial 4 lt~obsolete.m4 # 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])]) rapache-1.2.8/mod_R.c0000644000175100017510000024336012706745114013676 0ustar ondrejondrej/* ** Copyright 2012 Vanderbilt University ** ** Licensed under the Apache License, Version 2.0 (the "License"); ** you may not use this file except in compliance with the License. ** You may obtain a copy of the License at ** ** http://www.apache.org/licenses/LICENSE-2.0 ** ** Unless required by applicable law or agreed to in writing, software ** distributed under the License is distributed on an "AS IS" BASIS, ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ** See the License for the specific language governing permissions and ** limitations under the License. */ /************************************************************************* * * Headers and macros * *************************************************************************/ #define MOD_R_VERSION "1.2.8" #include "mod_R.h" #include #include /* * DARWIN's dyld.h defines an enum { FALSE TRUE} which conflicts with R */ #ifdef DARWIN #define ENUM_DYLD_BOOL enum DYLD_BOOL{ DYLD_FALSE, DYLD_TRUE}; #endif /* * Apache Server headers */ #include "httpd.h" #include "http_log.h" #include "http_config.h" #include "http_protocol.h" #include "util_filter.h" #include "util_script.h" #include "ap_mpm.h" /* * Apache Portable Runtime */ #include "apr.h" #include "apr_errno.h" #include "apr_strings.h" #include "apr_env.h" #include "apr_pools.h" #include "apr_hash.h" #include "apr_thread_mutex.h" /* * libapreq headers */ #include "apreq.h" #include "apreq_cookie.h" #include "apreq_parser.h" #include "apreq_param.h" #include "apreq_util.h" /* * R headers */ #include #include #include #include /* Waiting for confirmation if this is exposed in R API.*/ /* void Rf_PrintWarnings(void); */ /*#define PrintWarnings Rf_PrintWarnings*/ /* * sprintf and friends */ #include #include #define R_INTERFACE_PTRS #define CSTACK_DEFNS /* * APR pulls in stdint.h which defines uintptr_t, so we need to tell R * headers that. R defines uintptr_t slightly differently than * stdint.h, although they *should* be the same size */ #define HAVE_UINTPTR_T #include #include #include #include #include #include /************************************************************************* * * RApache types * *************************************************************************/ typedef enum { R_HANDLER = 1, R_SCRIPT, R_INFO } RApacheHandlerType; typedef struct { char *file; char *dirname; char *function; char *evalcode; char *package; char *handlerKey; char *cmdpath; } RApacheDirective; typedef struct { SEXP exprs; SEXP envir; apr_time_t mtime; } RApacheParsedFile; typedef struct { SEXP expr; SEXP envir; RApacheParsedFile *parsedFile; RApacheDirective *directive; } RApacheHandler; typedef struct { request_rec *r; int postParsed; int readStarted; apr_table_t *argsTable; apr_table_t *postTable; apr_table_t *cookiesTable; SEXP filesVar; SEXP serverVar; int outputErrors; char *errorPrefix; char *errorSuffix; RApacheHandler *handler; char *oldwd; } RApacheRequest; /************************************************************************* * * Globals; prefixed with MR_ (if R ever becomes threaded, or can at least * run multiple interpreters at once, we'll bundle these up into contexts). * *************************************************************************/ /* Current request_rec */ static RApacheRequest MR_Request = { NULL, 0, 0, NULL, NULL, NULL, NULL , NULL, -1, NULL, NULL, NULL,NULL}; /* Number of times apache has parsed config files; we'll do stuff on second pass */ static int MR_ConfigPass = 1; /* Don't start R more than once, if the flag is 1 it's already started */ static int MR_InitStatus = 0; /* * Child pid. If we fork() we don't want to do certain * cleanup steps, especially on cgi fork, so we cache the original * pid. */ static unsigned long MR_pid; /* Per-child memory for configuration */ static apr_pool_t *MR_Pool = NULL; static apr_bucket_alloc_t *MR_Bucket_Alloc = NULL; static apr_hash_t *MR_HandlerCache = NULL; static apr_hash_t *MR_ParsedFileCache = NULL; static apr_table_t *MR_OnStartup = NULL; /* * Bucket brigades for reading and writing to client * TODO: stuff these into MR_Request */ static apr_bucket_brigade *MR_BBin; static apr_bucket_brigade *MR_BBout; static apr_bucket_brigade *MR_BBerr; /* * RApache environment */ static SEXP MR_RApacheEnv; /* * RApache code; evaluated in the above environment. */ static const char MR_RApacheSource[] = "\ setStatus <- function(status) .Call('RApache_setStatus',as.integer(status))\n\ setContentType <- function(type) .Call('RApache_setContentType',type)\n\ setHeader <- function(header,value) .Call('RApache_setHeader',header,value)\n\ setCookie <- function(name=NULL,value='',expires=NULL,path=NULL,domain=NULL,...){\n\ args <- list(...)\n\ therest <- ifelse(length(args)>0,paste(paste(names(args),args,sep='='),collapse=';'),'')\n\ .Call('RApache_setCookie',name,value,expires,path,domain,therest)}\n\ urlEncode <- function(str) .Call('RApache_urlEnDecode',str,TRUE)\n\ urlDecode <- function(str) .Call('RApache_urlEnDecode',str,FALSE)\n\ RApacheInfo <- function() .Call('RApache_RApacheInfo')\n\ sendBin <- function(object, con=stdout(), size=NA_integer_, endian=.Platform$endian){\n\ swap <- endian != .Platform$endian\n\ if (!is.vector(object) || mode(object) == 'list') stop('can only write vector objects')\n\ .Call('RApache_sendBin',object,size,swap)}\n\ receiveBin <- function(length=-1L) .Call('RApache_receiveBin',length)\n\ RApacheOutputErrors <- function(status=TRUE,prefix=NULL,suffix=NULL) warning('RApacheOutputErrors has been deprecated!')\n\ .ResetCGIVars <- function(){\n\ re <- as.environment('rapache')\n\ delayedAssign('GET', .Call('RApache_parseGet'),re,re)\n\ delayedAssign('COOKIES', .Call('RApache_parseCookies'),re,re)\n\ delayedAssign('POST', .Call('RApache_parsePost'),re,re)\n\ delayedAssign('FILES', .Call('RApache_parseFiles'),re,re)\n\ delayedAssign('SERVER', .Call('RApache_getServer'),re,re)\n\ }"; /* * Global Thread Mutex */ static apr_thread_mutex_t *MR_mutex = NULL; /************************************************************************* * * Function declarations * * AP_* functions are called by apache code base * *************************************************************************/ /* * Module functions */ static void *AP_create_dir_cfg(apr_pool_t *p, char *dir); static void *AP_merge_dir_cfg(apr_pool_t *p, void *parent, void *new); static void *AP_create_srv_cfg(apr_pool_t *p, server_rec *s); static void *AP_merge_srv_cfg(apr_pool_t *p, void *parent, void *new); static void AP_register_hooks (apr_pool_t *p); /* * Command functions */ static const char *AP_cmd_RHandler(cmd_parms *cmd, void *conf, const char *handler); static const char *AP_cmd_RFileHandler(cmd_parms *cmd, void *conf, const char *handler); static const char *AP_cmd_REval(cmd_parms *cmd, void *conf, const char *tmpcode); static const char *AP_cmd_RFileEval(cmd_parms *cmd, void *conf, const char *tmpcode); static const char *AP_cmd_REvalOnStartup(cmd_parms *cmd, void *conf, const char *evalstr); static const char *AP_cmd_RSourceOnStartup(cmd_parms *cmd, void *conf, const char *evalstr); static const char *AP_cmd_ROutputErrors(cmd_parms *cmd, void *mconfig); static const char *AP_cmd_RPreserveEnv(cmd_parms *cmd, void *mconfig); /* * Module Hook functions */ static int AP_hook_post_config(apr_pool_t *pconf, apr_pool_t *plog, apr_pool_t *ptemp, server_rec *s); static void AP_hook_child_init(apr_pool_t *p, server_rec *s); static int AP_hook_request_handler (request_rec *r); /* * Exit callback */ static apr_status_t AP_child_exit(void *data); /* * R interface callbacks */ static void Suicide(const char *s){ }; static void ShowMessage(const char *s); static int ReadConsole(const char *, unsigned char *, int, int); static void WriteConsoleEx(const char *, int, int); static void WriteConsoleStderr(const char *, int, int); static void WriteConsoleErrorOnly(const char *, int, int); static void NoOpConsole(){ }; static void NoOpBusy(int i) { }; static void NoOpCleanUp(SA_TYPE s, int i, int j){ }; static int NoOpShowFiles(int i, const char **j, const char **k, const char *l, Rboolean b, const char *c){ return 1;}; static int NoOpChooseFile(int i, char *b,int s){ return 0;}; static int NoOpEditFile(const char *f){ return 0;}; static void NoOpHistoryFun(SEXP a, SEXP b, SEXP c, SEXP d){ }; /* * The Rest. */ static void init_config_pass(apr_pool_t *p); static void init_R(apr_pool_t *); static int SetUpRequest(const request_rec *,RApacheHandlerType); static void TearDownRequest(int flush); static RApacheHandler *GetHandlerFromRequest(const request_rec *r); static int RApacheResponseError(char *msg); static void RApacheError(char *msg); static void InitTempDir(apr_pool_t *p); static void RegisterCallSymbols(); static SEXP NewLogical(int tf); static SEXP NewInteger(int tf); static SEXP NewEnv(SEXP enclos); static SEXP ParseText(const char *text, int *parseError); static SEXP EvalExprs(SEXP exprs, SEXP env, int *evalError); /* more than one expression evaluator*/ static SEXP ParseEval(const char *code,SEXP env, int *evalError); static SEXP CallFun1str(const char *fun, const char *arg, SEXP env, int *evalError); static SEXP CallFun1expr(const char *fun, SEXP arg, SEXP env, int *evalError); static int PrepareFileExprs(RApacheHandler *h, const request_rec *r, int *fileParsed); static int PrepareHandlerExpr(RApacheHandler *h, const request_rec *r, int handlerType); static void InitRApacheEnv(); static void RefreshRApacheEnv(); static void InitRApachePool(); static int OnStartupCallback(void *rec, const char *key, const char *value); static SEXP MyfindFun(SEXP fun, SEXP envir); static int RApacheInfo(); static SEXP AprTableToList(apr_table_t *, apr_table_do_callback_fn_t *); static void PrintTraceback(void); static int ReadRequestBody(unsigned char *buf, int size); static char *dirname(const char *path, apr_pool_t *p); /************************************************************************* * * Command array * *************************************************************************/ static const command_rec MR_cmds[] = { AP_INIT_TAKE1("RHandler", AP_cmd_RHandler, NULL, OR_OPTIONS, "R function to handle request. "), AP_INIT_TAKE1("RFileHandler", AP_cmd_RFileHandler, NULL, OR_OPTIONS, "File containing R code or function to handle request."), AP_INIT_TAKE1("REval", AP_cmd_REval, NULL, OR_OPTIONS, "R code to evaluate on each request. "), AP_INIT_TAKE1("RFileEval", AP_cmd_RFileEval, NULL, OR_OPTIONS, "File and code to evalueate on each request."), AP_INIT_TAKE1("REvalOnStartup", AP_cmd_REvalOnStartup, NULL, OR_OPTIONS,"R expressions to evaluate on start."), AP_INIT_TAKE1("RSourceOnStartup", AP_cmd_RSourceOnStartup, NULL, OR_OPTIONS,"File containing R expressions to evaluate on start."), AP_INIT_NO_ARGS("ROutputErrors", AP_cmd_ROutputErrors, NULL, OR_OPTIONS, "Deprecated. Option to print error messages to output."), AP_INIT_NO_ARGS("RPreserveEnv", AP_cmd_RPreserveEnv, NULL, OR_OPTIONS, "Deprecated. Option to preserve handler environment across requests."), { NULL}, }; /************************************************************************* * * Module definition * *************************************************************************/ module AP_MODULE_DECLARE_DATA R_module = { STANDARD20_MODULE_STUFF, AP_create_dir_cfg, /* dir config creater */ AP_merge_dir_cfg, /* dir merger --- default is to override */ AP_create_srv_cfg, /* server config */ AP_merge_srv_cfg, /* merge server config */ MR_cmds, /* table of config file commands */ AP_register_hooks, /* register hooks */ }; /************************************************************************* * * Module functions: called by apache code base * *************************************************************************/ static void *AP_create_dir_cfg(apr_pool_t *p, char *dir){ RApacheDirective *cfg; cfg = (RApacheDirective *)apr_pcalloc(p,sizeof(RApacheDirective)); return (void *)cfg; } void *AP_merge_dir_cfg(apr_pool_t *pool, void *parent, void *new){ RApacheDirective *c; RApacheDirective *n = (RApacheDirective *)new; /* print_cfg("AP_merge_dir_cfg","Parent",p,"New",n); */ c = (RApacheDirective *)apr_pcalloc(pool,sizeof(RApacheDirective)); /* add new config stuff, overriding parent */ memcpy(c,n,sizeof(RApacheDirective)); return (void *)c; } /* first mod_R.c function called when apache starts */ void *AP_create_srv_cfg(apr_pool_t *p, server_rec *s){ RApacheDirective *c; init_config_pass(s->process->pool); c = (RApacheDirective *)apr_pcalloc(p,sizeof(RApacheDirective)); return (void *)c; } void *AP_merge_srv_cfg(apr_pool_t *pool, void *parent, void *new){ RApacheDirective *c; RApacheDirective *n = (RApacheDirective *)new; /* print_cfg("AP_merge_srv_cfg","Parent",p,"New",n); */ c = (RApacheDirective *)apr_pcalloc(pool,sizeof(RApacheDirective)); /* add new config stuff, overriding parent */ memcpy(c,n,sizeof(RApacheDirective)); return (void *)c; } static void AP_register_hooks (apr_pool_t *p) { ap_hook_post_config(AP_hook_post_config, NULL, NULL, APR_HOOK_MIDDLE); ap_hook_child_init(AP_hook_child_init, NULL, NULL, APR_HOOK_MIDDLE); ap_hook_handler(AP_hook_request_handler, NULL, NULL, APR_HOOK_MIDDLE); } /************************************************************************* * * Command functions: called by apache code base * *************************************************************************/ static const char *AP_cmd_RHandler(cmd_parms *cmd, void *conf, const char *handler){ const char *part, *function; RApacheDirective *c = (RApacheDirective *)conf; ap_directive_t *d = cmd->directive; InitRApachePool(); if (ap_strchr(handler,'/')){ fprintf(stderr,"\n\tWARNING! %s seems to contain a file. If this is true, then use the RFileHandler directive instead.\n",handler); fflush(stderr); } c->handlerKey = apr_pstrdup(cmd->pool,handler); part = ap_strstr(handler,"::"); if (part) { c->package = apr_pstrmemdup(cmd->pool,handler,part - handler); apr_table_add( MR_OnStartup, apr_psprintf( cmd->pool, "e:%s on line %u of %s", d->directive,d->line_num,d->filename), apr_psprintf(cmd->pool,"library(%s)",c->package)); function = part + 2; } else { function = handler; } c->function = apr_pstrdup(cmd->pool,function); c->cmdpath = apr_pstrdup(cmd->pool,cmd->path); return NULL; } static const char *AP_cmd_RFileHandler(cmd_parms *cmd, void *conf, const char *handler){ const char *part; RApacheDirective *c = (RApacheDirective *)conf; apr_finfo_t finfo; InitRApachePool(); c->handlerKey = apr_pstrdup(cmd->pool,handler); part = ap_strstr(handler,"::"); if (part) { c->file = apr_pstrmemdup(cmd->pool,handler,part - handler); c->function = apr_pstrdup(cmd->pool,part + 2); } else { c->file = apr_pstrdup(cmd->pool,handler); } if (apr_stat(&finfo,c->file,APR_FINFO_TYPE,cmd->pool) != APR_SUCCESS){ return apr_psprintf(cmd->pool,"RFileHandler: %s file not found!",c->file); } c->cmdpath = apr_pstrdup(cmd->pool,cmd->path); /* Cache directory of file */ c->dirname = dirname(c->file,cmd->pool); return NULL; } static const char *AP_cmd_REval(cmd_parms *cmd, void *conf, const char *tmpcode){ const char *part; RApacheDirective *c = (RApacheDirective *)conf; ap_directive_t *d = cmd->directive; InitRApachePool(); if (ap_strchr(tmpcode,'/')){ fprintf(stderr,"\n\tWARNING! %s seems to contain a file. If this is true, then use the RFileEval directive instead.\n",tmpcode); fflush(stderr); } c->handlerKey = apr_pstrdup(cmd->pool,tmpcode); part = ap_strstr(tmpcode,"::"); if (part) { c->package = apr_pstrmemdup(cmd->pool,tmpcode,part - tmpcode); apr_table_add( MR_OnStartup, apr_psprintf( cmd->pool, "e:%s on line %u of %s", d->directive,d->line_num,d->filename), apr_psprintf(cmd->pool,"library(%s)",c->package)); } c->evalcode = c->handlerKey; apr_table_add( MR_OnStartup, apr_psprintf( cmd->pool, "p:%s on line %u of %s", d->directive,d->line_num,d->filename), c->evalcode); c->cmdpath = apr_pstrdup(cmd->pool,cmd->path); return NULL; } static const char *AP_cmd_RFileEval(cmd_parms *cmd, void *conf, const char *filecode){ const char *part; RApacheDirective *c = (RApacheDirective *)conf; apr_finfo_t finfo; ap_directive_t *d = cmd->directive; InitRApachePool(); c->handlerKey = apr_pstrdup(cmd->pool,filecode); part = ap_strstr(filecode,":"); if (part) { c->file = apr_pstrmemdup(cmd->pool,filecode,part - filecode); c->evalcode = apr_pstrdup(cmd->pool,part+1); apr_table_add( MR_OnStartup, apr_psprintf( cmd->pool, "p:%s on line %u of %s", d->directive,d->line_num,d->filename), c->evalcode); part = ap_strstr(c->evalcode,"::"); if (part) { c->package = apr_pstrmemdup(cmd->pool,c->evalcode,part - c->evalcode); apr_table_add( MR_OnStartup, apr_psprintf( cmd->pool, "e:%s on line %u of %s", d->directive,d->line_num,d->filename), apr_psprintf(cmd->pool,"library(%s)",c->package)); } } else { return apr_pstrdup(cmd->pool,"RFileEval: Takes a filename and an expression!"); } if (apr_stat(&finfo,c->file,APR_FINFO_TYPE,cmd->pool) != APR_SUCCESS){ return apr_psprintf(cmd->pool,"RFileEval: %s file not found!",c->file); } c->cmdpath = apr_pstrdup(cmd->pool,cmd->path); /* Cache directory of file */ c->dirname = dirname(c->file,cmd->pool); return NULL; } static const char *AP_cmd_REvalOnStartup(cmd_parms *cmd, void *conf, const char *evalstr){ ap_directive_t *d = cmd->directive; InitRApachePool(); apr_table_add( MR_OnStartup, apr_psprintf( cmd->pool, "e:%s on line %u of %s", d->directive,d->line_num,d->filename), evalstr ); return NULL; } static const char *AP_cmd_RSourceOnStartup(cmd_parms *cmd, void *conf, const char *file){ ap_directive_t *d = cmd->directive; InitRApachePool(); if (MR_ConfigPass == 1){ apr_finfo_t finfo; if (apr_stat(&finfo,file,APR_FINFO_TYPE,cmd->pool) != APR_SUCCESS){ return apr_psprintf(cmd->pool,"RSourceFile: %s file not found!",file); } return NULL; } apr_table_add( MR_OnStartup, apr_psprintf( cmd->pool, "e:%s on line %u of %s", d->directive,d->line_num,d->filename), apr_psprintf(cmd->pool,"source('%s')",file) ); return NULL; } static const char *AP_cmd_ROutputErrors(cmd_parms *cmd, void *conf){ fprintf(stderr,"Warning: ROutputErrors has been deprecated!"); return NULL; } static const char *AP_cmd_RPreserveEnv(cmd_parms *cmd, void *conf){ fprintf(stderr,"Warning: RPreserveEnv has been deprecated!"); return NULL; } /************************************************************************* * * Hook functions: called by apache code base * *************************************************************************/ static int AP_hook_post_config(apr_pool_t *pconf, apr_pool_t *plog, apr_pool_t *ptemp, server_rec *s){ ap_add_version_component(pconf,apr_psprintf(pconf,"mod_R/%s",MOD_R_VERSION)); ap_add_version_component(pconf,apr_psprintf(pconf,"R/%s.%s",R_MAJOR,R_MINOR)); return OK; } static void AP_hook_child_init(apr_pool_t *p, server_rec *s){ MR_pid=(unsigned long)getpid(); init_R(p); apr_pool_cleanup_register(p, p, AP_child_exit, AP_child_exit); } static int AP_hook_request_handler (request_rec *r) { RApacheHandlerType handlerType = 0; RApacheHandler *h; SEXP ret=R_NilValue; int evalError=1,fileParsed=1; if (apr_filepath_get(&MR_Request.oldwd,APR_FILEPATH_NATIVE,r->pool) != APR_SUCCESS) return HTTP_INTERNAL_SERVER_ERROR; /* Only handle our handlers */ if (strcmp(r->handler,"r-handler")==0) handlerType = R_HANDLER; else if (strcmp(r->handler,"r-script")==0) handlerType = R_SCRIPT; else if (strcmp(r->handler,"r-info")==0) handlerType = R_INFO; else return DECLINED; if (!SetUpRequest(r,handlerType)) return HTTP_INTERNAL_SERVER_ERROR; h = MR_Request.handler; if (handlerType == R_INFO){ int val = RApacheInfo(); TearDownRequest(1); return val; } RefreshRApacheEnv(); /* ensures we're on search path, updates CGI vars, etc. */ /* Prepare file if needed */ if (h->directive->file){ /* Set working directory to dirname of file */ if (apr_filepath_set(h->directive->dirname,MR_Pool) != APR_SUCCESS) return RApacheResponseError(NULL); fileParsed = 1; if (!PrepareFileExprs(h,r,&fileParsed)) return RApacheResponseError(NULL); if (fileParsed || (!h->directive->function && !h->directive->evalcode)){ if (h->parsedFile->envir) R_ReleaseObject(h->parsedFile->envir); h->parsedFile->envir = NewEnv(R_GlobalEnv); R_PreserveObject(h->parsedFile->envir); evalError = 1; ret = EvalExprs(h->parsedFile->exprs,h->parsedFile->envir,&evalError); if (evalError) { /*PrintWarnings();*/ PrintTraceback(); return RApacheResponseError(NULL); } } h->envir = h->parsedFile->envir; } else { if (h->envir) R_ReleaseObject(h->envir); h->envir = NewEnv(R_GlobalEnv); R_PreserveObject(h->envir); } /* Eval handler expression if set */ if (h->directive->function || h->directive->evalcode){ if (!PrepareHandlerExpr(h,r,handlerType)) { return RApacheResponseError(NULL); } ret = EvalExprs(h->expr,h->envir,&evalError); if (evalError) { /*PrintWarnings();*/ PrintTraceback(); return RApacheResponseError(NULL); } } /*PrintWarnings();*/ if (IS_INTEGER(ret) && LENGTH(ret) == 1){ int result = asInteger(ret); TearDownRequest(1); /* Set status to HTTP_mumble */ if (result != OK) r->status = result; return result; } else if (inherits(ret,"try-error")){ return RApacheResponseError(apr_psprintf(r->pool,"Function %s returned an object of 'try-error'.\n",h->directive->function)); } else { TearDownRequest(1); return DONE; /* user didn't specify return code, so presume done.*/ } } static apr_status_t AP_child_exit(void *data){ /* R_dot_Last(); */ unsigned long pid; pid = (unsigned long)getpid(); /* Only run if we've actually initialized AND * we haven't forked (for mod_cgi). */ if (MR_InitStatus && MR_pid == pid){ MR_InitStatus = 0; } /*if (MR_Pool) { apr_bucket_alloc_destroy(MR_Bucket_Alloc); apr_pool_destroy(MR_Pool); MR_Pool = NULL; } */ return APR_SUCCESS; } /************************************************************************* * * R interface callbacks * *************************************************************************/ static void ShowMessage(const char *s){ (ptr_R_WriteConsoleEx)(s,strlen(s),1); } static void WriteConsoleEx(const char *buf, int size, int errorFlag){ if (MR_Request.r){ if (!errorFlag) { /* ap_fwrite(MR_Request.r->output_filters,MR_BBout,buf,size); */ apr_brigade_write(MR_BBout,NULL,NULL,buf,size); } else RApacheError(apr_pstrmemdup(MR_Request.r->pool,buf,size)); } else { WriteConsoleStderr(buf,size,errorFlag); } } static void WriteConsoleErrorOnly(const char *buf, int size, int errorFlag){ if (MR_Request.r) RApacheError(apr_pstrmemdup(MR_Request.r->pool,buf,size)); else WriteConsoleStderr(buf,size,errorFlag); } static void WriteConsoleStderr(const char *buf, int size, int errorFlag){ fprintf(stderr,"%*s",size,buf); fflush(stderr); } /* according to R 2.7.2 the true size of buf is size+1 */ static int ReadConsole(const char *prompt, unsigned char *buf, int size, int addHist){ int len = ReadRequestBody(buf,size); buf[len] = '\0'; return len; } static int ReadRequestBody(unsigned char *buf, int size){ apr_size_t len, bpos=0; apr_status_t rv; const char *data; if (!MR_Request.r){ ap_log_rerror(APLOG_MARK,APLOG_ERR,0,MR_Request.r,"Can't read with R since MR_Request.r is NULL!"); return 0; } if (MR_Request.postParsed){ //the user should be able to avoid this now. Warning seems appropriate. RApacheError("Can't read with R since libapreq already started!"); return 0; } MR_Request.readStarted = 1; if (MR_BBin == NULL){ MR_BBin = apr_brigade_create(MR_Request.r->pool, MR_Request.r->connection->bucket_alloc); } while (bpos < size) { len = size - bpos; if (len > HUGE_STRING_LEN) { len = HUGE_STRING_LEN; } rv = ap_get_brigade(MR_Request.r->input_filters,MR_BBin,AP_MODE_READBYTES,APR_BLOCK_READ,len); if (rv != APR_SUCCESS) { break; } rv = apr_brigade_flatten(MR_BBin, buf+bpos, &len); if (rv != APR_SUCCESS) { break; } apr_brigade_cleanup(MR_BBin); if (len == 0) { break; } bpos += len; } return (int)bpos; } /************************************************************************* * * Helper functions * *************************************************************************/ static RApacheHandler *GetHandlerFromRequest(const request_rec *r){ RApacheDirective *d = ap_get_module_config(r->per_dir_config,&R_module); RApacheHandler *h; if (d == NULL || d->handlerKey == NULL){ ap_set_content_type((request_rec *)r,"text/html"); RApacheError(apr_psprintf(r->pool,"No RApache Directive specified for 'SetHandler %s'",r->handler)); return NULL; } h = (RApacheHandler *)apr_hash_get( MR_HandlerCache,d->handlerKey,APR_HASH_KEY_STRING); if (!h){ h = (RApacheHandler *)apr_pcalloc(MR_Pool,sizeof(RApacheHandler)); apr_hash_set(MR_HandlerCache,d->handlerKey,APR_HASH_KEY_STRING,h); } if (h == NULL || (d->file == NULL && d->function == NULL && d->evalcode == NULL)){ ap_set_content_type((request_rec *)r,"text/html"); RApacheError(apr_psprintf(r->pool,"Invalid RApache Directive: %s",d->handlerKey)); return NULL; } h->directive = d; return(h); } static int SetUpRequest(const request_rec *r,RApacheHandlerType handlerType){ /* Acquire R mutex */ if (MR_mutex != NULL && apr_thread_mutex_lock(MR_mutex) != APR_SUCCESS) { ap_log_rerror(APLOG_MARK,APLOG_ERR,0,r,"RApache Mutex error!"); return 0; } /* Set current request_rec */ MR_Request.r = (request_rec *)r; /* Init reading */ MR_BBin = NULL; /* Set output brigade */ if ((MR_BBout = apr_brigade_create(r->pool, r->connection->bucket_alloc)) == NULL){ RApacheError("RApache MR_BBout error!"); TearDownRequest(0); return 0; } if (handlerType != R_INFO){ MR_Request.handler = GetHandlerFromRequest(r); if (!MR_Request.handler){ TearDownRequest(0); return 0; } } return 1; } /* No need to free any memory here since it was allocated out of the request pool */ static void TearDownRequest(int flush){ int evalError; apr_bucket *bucket; apr_size_t len; const char *data; apr_status_t status; /* Change to oldwd */ if (MR_Request.oldwd != NULL) apr_filepath_set(MR_Request.oldwd,MR_Pool); /* Clean up reading */ if (MR_BBin){ if (MR_Request.readStarted) { /* TODO: check if this succeeds */ ParseEval(".Internal(clearPushBack(stdin()))",R_GlobalEnv,&evalError); } apr_brigade_cleanup(MR_BBin); apr_brigade_destroy(MR_BBin); } MR_BBin = NULL; /* Clean up writing, e.g. flush output */ if (MR_BBout){ /* A reason not to flush when the brigade is not empty is to * preserve error conditons */ if(!APR_BRIGADE_EMPTY(MR_BBout) && flush){ ap_filter_flush(MR_BBout,MR_Request.r->output_filters); } apr_brigade_cleanup(MR_BBout); apr_brigade_destroy(MR_BBout); } MR_BBout = NULL; /* Output errors */ if (MR_BBerr){ /* Write contents of MR_BBerr to log */ for (bucket = APR_BRIGADE_FIRST(MR_BBerr); bucket != APR_BRIGADE_SENTINEL(MR_BBerr); bucket = APR_BUCKET_NEXT(bucket)) { if (APR_BUCKET_IS_EOS(bucket)) { break; } /* We can't do much with this. */ if (APR_BUCKET_IS_FLUSH(bucket)) { continue; } /* read */ status = apr_bucket_read(bucket, &data, &len, APR_BLOCK_READ); if (status != APR_SUCCESS){ fprintf(stderr,"WARNING! apr_bucket_read returned %d\n",status); } status = apr_file_write(MR_Request.r->server->error_log,data,&len); if (status != APR_SUCCESS){ fprintf(stderr,"WARNING! apr_file_write returned %d\n",status); } } apr_file_flush(MR_Request.r->server->error_log); apr_brigade_cleanup(MR_BBerr); apr_brigade_destroy(MR_BBerr); } MR_BBerr = NULL; bzero(&MR_Request,sizeof(RApacheRequest)); if (MR_mutex != NULL) apr_thread_mutex_unlock(MR_mutex); } /* Can be called with NULL msg to force proper request handler return * value. */ static int RApacheResponseError(char *msg){ if (msg) RApacheError(msg); TearDownRequest(0); /* delete all buffered output */ return HTTP_INTERNAL_SERVER_ERROR; } static void RApacheError(char *msg){ if (!msg) return; if (MR_BBerr == NULL){ /* Allocated out of Global rApache pool */ if ((MR_BBerr = apr_brigade_create(MR_Pool, MR_Bucket_Alloc)) == NULL){ fprintf(stderr,"FATAL ERROR! RApacheError cannot create MR_BBerr brigade\n"); exit(-1); } ap_log_rerror(APLOG_MARK,APLOG_ERR,0,MR_Request.r,"rApache Notice!"); } if (apr_brigade_puts(MR_BBerr,NULL,NULL,msg) != APR_SUCCESS){ fprintf(stderr,"FATAL ERROR! RApacheError cannot write to MR_BBerr brigade\n"); exit(-1); } } static void init_R(apr_pool_t *p){ char *argv[] = {"mod_R", "--gui=none", "--slave", "--silent", "--vanilla","--no-readline"}; int argc = sizeof(argv)/sizeof(argv[0]); int threaded; apr_status_t rv; if (MR_InitStatus != 0) return; MR_InitStatus = 1; InitRApachePool(); /* possibly done already if REvalOnStartup or RSourceOnStartup set */ /* Setup thread mutex if we're running in a threaded server.*/ rv = ap_mpm_query(AP_MPMQ_IS_THREADED,&threaded); if (rv != APR_SUCCESS){ fprintf(stderr,"Fatal Error: Can't query the server to dermine if it's threaded!\n"); exit(-1); } if (threaded){ rv = apr_thread_mutex_create(&MR_mutex,APR_THREAD_MUTEX_DEFAULT,MR_Pool); if (rv != APR_SUCCESS){ fprintf(stderr,"Fatal Error: unable to create R mutex!\n"); exit(-1); } } if (apr_env_set("R_HOME",R_HOME,p) != APR_SUCCESS){ fprintf(stderr,"Fatal Error: could not set R_HOME from init!\n"); exit(-1); } /* Don't let R set up its own signal handlers */ R_SignalHandlers = 0; InitTempDir(p); Rf_initEmbeddedR(argc, argv); /* redirect R's inputs and outputs. Print to stderr during startup. */ R_Consolefile = NULL; R_Outputfile = NULL; ptr_R_Suicide = Suicide; ptr_R_ShowMessage = ShowMessage; ptr_R_WriteConsole = NULL; ptr_R_WriteConsoleEx = WriteConsoleStderr; ptr_R_ReadConsole = ReadConsole; ptr_R_ResetConsole = ptr_R_FlushConsole = ptr_R_ClearerrConsole = NoOpConsole; ptr_R_Busy = NoOpBusy; ptr_R_CleanUp = NoOpCleanUp; ptr_R_ShowFiles = NoOpShowFiles; ptr_R_ChooseFile = NoOpChooseFile; ptr_R_EditFile = NoOpEditFile; ptr_R_loadhistory = ptr_R_savehistory = ptr_R_addhistory = NoOpHistoryFun; #ifdef CSTACK_DEFNS /* Don't do any stack checking */ R_CStackLimit = -1; #endif RegisterCallSymbols(); InitRApacheEnv(); /* Execute all *OnStartup code */ apr_table_do(OnStartupCallback,NULL,MR_OnStartup,NULL); apr_table_clear(MR_OnStartup); /* For the RFile directive */ if (!(MR_ParsedFileCache = apr_hash_make(MR_Pool))){ fprintf(stderr,"Fatal Error: could not apr_hash_make() from MR_Pool!\n"); exit(-1); } /* Handler Cache */ if (!(MR_HandlerCache = apr_hash_make(MR_Pool))){ fprintf(stderr,"Fatal Error: could not apr_hash_make() from MR_Pool!\n"); exit(-1); } /* Initialize libapreq2 */ apreq_initialize(MR_Pool); /* Lastly, now redirect R's output */ ptr_R_WriteConsoleEx = WriteConsoleEx; ptr_R_WriteConsole = NULL; } void InitRApachePool(void){ if (MR_Pool) return; if (apr_pool_create(&MR_Pool,NULL) != APR_SUCCESS){ fprintf(stderr,"Fatal Error: could not apr_pool_create(MR_Pool)!\n"); exit(-1); } MR_Bucket_Alloc = apr_bucket_alloc_create(MR_Pool); /* Table to hold *OnStartup code. Allocate 8 entries. */ if (!(MR_OnStartup = apr_table_make(MR_Pool,8))){ fprintf(stderr,"Fatal Error: could not apr_table_make(MR_Pool)!\n"); exit(-1); } } /* * This is a bit of magic. Upon startup, Apache parses its config file twice, and * we really only want to do useful stuff on the second pass, so we use an apr pool * feature called apr_pool_userdata_[set|get]() to store state from 1 config pass * to the next. */ void init_config_pass(apr_pool_t *p){ void *cfg_pass = NULL; const char *userdata_key = "R_language"; apr_pool_userdata_get(&cfg_pass, userdata_key, p); if (!cfg_pass) { cfg_pass = apr_pcalloc(p, sizeof(int)); *((int *)cfg_pass) = 1; apr_pool_userdata_set(cfg_pass, userdata_key, apr_pool_cleanup_null, p); } else { *((int *)cfg_pass) = 2; } MR_ConfigPass = *((int *)cfg_pass); } static char *dirname(const char *path, apr_pool_t *p){ int i=0, j; while(path[i] != '\0'){ if (path[i] == '/') j = i; i++; } return (j > 0)? apr_pstrndup(p,path,j) : NULL; } /************************************************************************* * * R specific functions * *************************************************************************/ static void PrintTraceback(void){ int evalError; ptr_R_WriteConsoleEx = WriteConsoleErrorOnly; ParseEval("cat('Traceback:\\n');traceback()",R_GlobalEnv,&evalError); ptr_R_WriteConsoleEx = WriteConsoleEx; } void InitTempDir(apr_pool_t *p) { const char *tmp; if (apr_temp_dir_get(&tmp,p) != APR_SUCCESS){ fprintf(stderr,"Fatal Error: apr_temp_dir_get() failed!\n"); exit(-1); } R_TempDir=(char *)tmp; if (apr_env_set("R_SESSION_TMPDIR",R_TempDir,p) != APR_SUCCESS){ fprintf(stderr,"Fatal Error: could not set up R_SESSION_TMPDIR!\n"); exit(-1); } } static SEXP NewLogical(int tf) { SEXP stf; PROTECT(stf = NEW_LOGICAL(1)); LOGICAL_DATA(stf)[0] = tf; UNPROTECT(1); return stf; } static SEXP NewInteger(int i){ SEXP val; PROTECT(val = NEW_INTEGER(1)); INTEGER_DATA(val)[0] = i; UNPROTECT(1); return val; } static SEXP NewEnv(SEXP enclos){ SEXP cmd, env, tf; int evalError; PROTECT(tf = NewLogical(1)); PROTECT(cmd = lang3(findFun(install("new.env"),R_BaseEnv),tf,enclos)); env = R_tryEval(cmd,R_GlobalEnv,&evalError); UNPROTECT(2); return env; } static SEXP ParseText(const char *text, int *parseError){ SEXP cmd, val; if (!parseError){ fprintf(stderr,"Internal Error! ParseText called with invalid argument.\n"); exit(-1); } PROTECT(cmd = lang4(findFun(install("parse"),R_BaseEnv),mkString(""),R_NilValue,mkString(text))); val = R_tryEval(cmd,R_GlobalEnv,parseError); UNPROTECT(1); return val; } SEXP ParseEval(const char *code, SEXP env, int *evalError){ SEXP exprs, val; if (!evalError){ fprintf(stderr,"Internal Error! ParseEval called with invalid argument.\n"); exit(-1); } PROTECT(env); exprs = ParseText(code,evalError); PROTECT(exprs); if (*evalError) return R_NilValue; val = EvalExprs(exprs,env,evalError); UNPROTECT(2); return val; } static SEXP EvalExprs(SEXP exprs, SEXP env, int *evalError){ SEXP lastval = R_NilValue; int i, len; if (!evalError){ fprintf(stderr,"Internal Error! EvalExprs called with invalid argument.\n"); exit(-1); } PROTECT(exprs); PROTECT(env); if (isLanguage(exprs)){ lastval = R_tryEval(exprs,env,evalError); } else if (isExpression(exprs) && length(exprs)){ len = length(exprs); for(i = 0; i < len; i++){ lastval = R_tryEval(VECTOR_ELT(exprs, i),env,evalError); if (*evalError) break; } } else { fprintf(stderr,"Internal Error! EvalExprs() called with bad exprs\n"); fflush(stderr); } UNPROTECT(2); return(lastval); } static SEXP CallFun1expr(const char *fun, SEXP arg, SEXP env, int *evalError){ SEXP cmd, val; PROTECT(cmd = lang2(MyfindFun(install(fun),R_GlobalEnv),arg)); val = EvalExprs(cmd,env,evalError); UNPROTECT(1); return val; } static SEXP CallFun1str(const char *fun, const char *arg, SEXP env, int *evalError){ SEXP val; char *text; text = Calloc(strlen(fun)+strlen(arg)+5,char); sprintf(text,"%s('%s')",fun,arg); val = ParseEval(text,env,evalError); Free(text); return val; } static int PrepareFileExprs(RApacheHandler *h, const request_rec *r, int *fileParsed){ RApacheParsedFile *parsedFile; int evalError=1; apr_finfo_t finfo; if (apr_stat(&finfo,h->directive->file,APR_FINFO_MTIME|APR_FINFO_SIZE,r->pool) != APR_SUCCESS){ RApacheError(apr_psprintf(r->pool, "From RApache Directive: %s\n\tInvalid file (apr_stat): %s\n", h->directive->handlerKey,h->directive->file)); return 0; } if (h->parsedFile) parsedFile = h->parsedFile; else { /* Grab file cache element */ parsedFile = (RApacheParsedFile *)apr_hash_get(MR_ParsedFileCache,h->directive->file,APR_HASH_KEY_STRING); /* File not cached yet */ if (!parsedFile){ parsedFile = (RApacheParsedFile *)apr_pcalloc(MR_Pool,sizeof(RApacheParsedFile)); apr_hash_set(MR_ParsedFileCache,h->directive->file,APR_HASH_KEY_STRING,parsedFile); } h->parsedFile = parsedFile; } /* Parse file */ if (parsedFile->mtime < finfo.mtime){ if (*fileParsed) *fileParsed = 1; /* Release old parse file expressions for gc */ if (parsedFile->exprs) R_ReleaseObject(parsedFile->exprs); parsedFile->exprs = CallFun1str("parse",h->directive->file,R_GlobalEnv,&evalError); if (evalError){ return 0; } else { R_PreserveObject(parsedFile->exprs); parsedFile->mtime = finfo.mtime; } } else { if (*fileParsed) *fileParsed = 0; } return 1; } /* * This version is better suited to printing warnings,errors, and traceback. */ static int PrepareHandlerExpr(RApacheHandler *h, const request_rec *r, int handlerType){ static char const fmt1[]="%s()"; static char const fmt2[]="%s::%s()"; static char const fmt3[]="%s(file='%s',envir=.rAenv)"; static char const fmt4[]="%s::%s(file='%s',envir=.rAenv)"; char *text; int parseError=1; if (handlerType == R_SCRIPT){ if (h->directive->package){ text = Calloc(strlen(fmt4)+strlen(h->directive->package)+ strlen(h->directive->function)+ strlen(r->filename),char); sprintf(text,fmt4,h->directive->package,h->directive->function, r->filename); } else{ text = Calloc(strlen(fmt3)+strlen(h->directive->function)+ strlen(r->filename),char); sprintf(text,fmt3,h->directive->function,r->filename); } if (h->expr) R_ReleaseObject(h->expr); h->expr = ParseText(text,&parseError); Free(text); /* Monkey with expression and place the environment in there */ defineVar(install(".rAfile"),mkString(r->filename),h->envir); defineVar(install(".rAenv"),h->envir,h->envir); apr_filepath_set(dirname(r->filename,r->pool),r->pool); } if (!h->expr){ if (h->directive->function){ if (h->directive->package){ text = Calloc(strlen(fmt2)+strlen(h->directive->package)+strlen(h->directive->function),char); sprintf(text,fmt2,h->directive->package,h->directive->function); } else{ if (h->directive->file && MyfindFun(install(h->directive->function),h->envir) == R_UnboundValue){ RApacheError(apr_psprintf(MR_Request.r->pool,"Cannot find function '%s' in file '%s'\n",h->directive->function,h->directive->file)); return 0; } text = Calloc(strlen(fmt1)+strlen(h->directive->function),char); sprintf(text,fmt1,h->directive->function); } h->expr = ParseText(text,&parseError); Free(text); } else if (h->directive->evalcode){ h->expr = ParseText(h->directive->evalcode,&parseError); } if (!parseError) R_PreserveObject(h->expr); else return 0; } return 1; } static void RefreshRApacheEnv(){ SEXP t; int evalError=1, envFound=0; for (t = ENCLOS(R_GlobalEnv); t != R_BaseEnv; t = ENCLOS(t)){ if (t == MR_RApacheEnv) { envFound=1; break; } } /* Not found. Place on search path right before base */ if (!envFound){ /* Search for envir right before BaseEnv */ for (t = R_GlobalEnv; ENCLOS(t) != R_BaseEnv; t = ENCLOS(t))/* noop */; /* ENCLOS(t) beter be R_BaseEnv */ if (ENCLOS(t) == R_BaseEnv){ SET_ENCLOS(t,MR_RApacheEnv); } else { fprintf(stderr,"Internal Error! Error reattaching rapache environment!\n\n"); exit(-1); } } ParseEval(".ResetCGIVars()",MR_RApacheEnv,&evalError); if (evalError){ fprintf(stderr,"Internal Error! Error resetting CGI vars!\n\n"); exit(-1); } } static void InitRApacheEnv(){ int evalError=1; /* Attach apache env right before base */ R_PreserveObject(MR_RApacheEnv = ParseEval("attach(NULL,pos=length(search()),'rapache')",R_GlobalEnv,&evalError)); if (evalError){ fprintf(stderr,"Internal Error! Error attaching rapache environment!\n\n"); exit(-1); } evalError=1; ParseEval(MR_RApacheSource,MR_RApacheEnv,&evalError); if (evalError){ fprintf(stderr,"Internal Error! Error eval'ing MR_RApacheSource!\n\n"); exit(-1); } defineVar(install("DONE"),NewInteger(-2),MR_RApacheEnv); defineVar(install("DECLINED"),NewInteger(-1),MR_RApacheEnv); defineVar(install("OK"),NewInteger(0),MR_RApacheEnv); defineVar(install("HTTP_CONTINUE"),NewInteger(100),MR_RApacheEnv); defineVar(install("HTTP_SWITCHING_PROTOCOLS"),NewInteger(101),MR_RApacheEnv); defineVar(install("HTTP_PROCESSING"),NewInteger(102),MR_RApacheEnv); defineVar(install("HTTP_OK"),NewInteger(200),MR_RApacheEnv); defineVar(install("HTTP_CREATED"),NewInteger(201),MR_RApacheEnv); defineVar(install("HTTP_ACCEPTED"),NewInteger(202),MR_RApacheEnv); defineVar(install("HTTP_NON_AUTHORITATIVE"),NewInteger(203),MR_RApacheEnv); defineVar(install("HTTP_NO_CONTENT"),NewInteger(204),MR_RApacheEnv); defineVar(install("HTTP_RESET_CONTENT"),NewInteger(205),MR_RApacheEnv); defineVar(install("HTTP_PARTIAL_CONTENT"),NewInteger(206),MR_RApacheEnv); defineVar(install("HTTP_MULTI_STATUS"),NewInteger(207),MR_RApacheEnv); defineVar(install("HTTP_MULTIPLE_CHOICES"),NewInteger(300),MR_RApacheEnv); defineVar(install("HTTP_MOVED_PERMANENTLY"),NewInteger(301),MR_RApacheEnv); defineVar(install("HTTP_MOVED_TEMPORARILY"),NewInteger(302),MR_RApacheEnv); defineVar(install("HTTP_SEE_OTHER"),NewInteger(303),MR_RApacheEnv); defineVar(install("HTTP_NOT_MODIFIED"),NewInteger(304),MR_RApacheEnv); defineVar(install("HTTP_USE_PROXY"),NewInteger(305),MR_RApacheEnv); defineVar(install("HTTP_TEMPORARY_REDIRECT"),NewInteger(307),MR_RApacheEnv); defineVar(install("HTTP_BAD_REQUEST"),NewInteger(400),MR_RApacheEnv); defineVar(install("HTTP_UNAUTHORIZED"),NewInteger(401),MR_RApacheEnv); defineVar(install("HTTP_PAYMENT_REQUIRED"),NewInteger(402),MR_RApacheEnv); defineVar(install("HTTP_FORBIDDEN"),NewInteger(403),MR_RApacheEnv); defineVar(install("HTTP_NOT_FOUND"),NewInteger(404),MR_RApacheEnv); defineVar(install("HTTP_METHOD_NOT_ALLOWED"),NewInteger(405),MR_RApacheEnv); defineVar(install("HTTP_NOT_ACCEPTABLE"),NewInteger(406),MR_RApacheEnv); defineVar(install("HTTP_PROXY_AUTHENTICATION_REQUIRED"),NewInteger(407),MR_RApacheEnv); defineVar(install("HTTP_REQUEST_TIME_OUT"),NewInteger(408),MR_RApacheEnv); defineVar(install("HTTP_CONFLICT"),NewInteger(409),MR_RApacheEnv); defineVar(install("HTTP_GONE"),NewInteger(410),MR_RApacheEnv); defineVar(install("HTTP_LENGTH_REQUIRED"),NewInteger(411),MR_RApacheEnv); defineVar(install("HTTP_PRECONDITION_FAILED"),NewInteger(412),MR_RApacheEnv); defineVar(install("HTTP_REQUEST_ENTITY_TOO_LARGE"),NewInteger(413),MR_RApacheEnv); defineVar(install("HTTP_REQUEST_URI_TOO_LARGE"),NewInteger(414),MR_RApacheEnv); defineVar(install("HTTP_UNSUPPORTED_MEDIA_TYPE"),NewInteger(415),MR_RApacheEnv); defineVar(install("HTTP_RANGE_NOT_SATISFIABLE"),NewInteger(416),MR_RApacheEnv); defineVar(install("HTTP_EXPECTATION_FAILED"),NewInteger(417),MR_RApacheEnv); defineVar(install("HTTP_UNPROCESSABLE_ENTITY"),NewInteger(422),MR_RApacheEnv); defineVar(install("HTTP_LOCKED"),NewInteger(423),MR_RApacheEnv); defineVar(install("HTTP_FAILED_DEPENDENCY"),NewInteger(424),MR_RApacheEnv); defineVar(install("HTTP_UPGRADE_REQUIRED"),NewInteger(426),MR_RApacheEnv); defineVar(install("HTTP_INTERNAL_SERVER_ERROR"),NewInteger(500),MR_RApacheEnv); defineVar(install("HTTP_NOT_IMPLEMENTED"),NewInteger(501),MR_RApacheEnv); defineVar(install("HTTP_BAD_GATEWAY"),NewInteger(502),MR_RApacheEnv); defineVar(install("HTTP_SERVICE_UNAVAILABLE"),NewInteger(503),MR_RApacheEnv); defineVar(install("HTTP_GATEWAY_TIME_OUT"),NewInteger(504),MR_RApacheEnv); defineVar(install("HTTP_VERSION_NOT_SUPPORTED"),NewInteger(505),MR_RApacheEnv); defineVar(install("HTTP_VARIANT_ALSO_VARIES"),NewInteger(506),MR_RApacheEnv); defineVar(install("HTTP_INSUFFICIENT_STORAGE"),NewInteger(507),MR_RApacheEnv); defineVar(install("HTTP_NOT_EXTENDED"),NewInteger(510),MR_RApacheEnv); /* CGI VARS */ defineVar(install("GET"),R_NilValue,MR_RApacheEnv); defineVar(install("POST"),R_NilValue,MR_RApacheEnv); defineVar(install("COOKIES"),R_NilValue,MR_RApacheEnv); defineVar(install("FILES"),R_NilValue,MR_RApacheEnv); defineVar(install("SERVER"),R_NilValue,MR_RApacheEnv); /* Lock environment and bindings except for CGI vars.*/ R_LockEnvironment(MR_RApacheEnv, TRUE); R_unLockBinding(install("GET"),MR_RApacheEnv); R_unLockBinding(install("POST"),MR_RApacheEnv); R_unLockBinding(install("COOKIES"),MR_RApacheEnv); R_unLockBinding(install("FILES"),MR_RApacheEnv); R_unLockBinding(install("SERVER"),MR_RApacheEnv); } /* Every key must be prefixed with either "e:" or "p:" to indicate if the * value should be evaluated or parsed. */ static int OnStartupCallback(void *rec, const char *key, const char *value){ SEXP val; int evalError=1; if (key[0] == 'e' && key[1] == ':'){ val = ParseEval(value,R_GlobalEnv,&evalError); if (evalError){ fprintf(stderr," From directive %s.\n",key+2); exit(-1); } } else if (key[0] == 'p' && key[1] == ':'){ val = ParseText(value,&evalError); if (evalError){ fprintf(stderr,"Parse error in '%s' from directive %s.\n",value,key+2); exit(-1); } } return 1; } /* This one doesn't longjmp when function not found */ static SEXP MyfindFun(SEXP symb, SEXP envir){ SEXP fun; SEXPTYPE t; if (symb == NULL || envir == NULL) return R_UnboundValue; if (symb == R_NilValue || envir == R_NilValue) return R_UnboundValue; PROTECT(symb); PROTECT(envir); fun = findVar(symb,envir); UNPROTECT(2); t = TYPEOF(fun); /* eval promise if need be */ if (t == PROMSXP){ int evalError=1; fun = R_tryEval(fun,envir,&evalError); if (evalError) return R_UnboundValue; t = TYPEOF(fun); } if (t == CLOSXP || t == BUILTINSXP || t == SPECIALSXP) return fun; return R_UnboundValue; } #define PUTS(s) apr_brigade_puts(MR_BBout,NULL,NULL,s) #define EXEC(s) ParseEval(s,envir,&errorOccurred); if (errorOccurred) return RApacheResponseError(NULL) static int RApacheInfo() { SEXP envir = NewEnv(R_GlobalEnv); int errorOccurred=1; ap_set_content_type( MR_Request.r, "text/html"); EXEC("hrefify <- function(title) gsub('[\\\\.()]','_',title,perl=TRUE)"); EXEC("cl<-'e'"); EXEC("scrub <- function(st){ if (is.null(st)) return('null'); if (is.na(st)) return('NA'); if (length(st) == 0) return ('length 0 sting'); if (typeof(st) == 'closure') { sink(textConnection('stt','w')); str(st); sink(); st <- stt; } else {st <- as.character(st) } ; st <- gsub('&','&',st); st <- gsub('@','_at_',st); st <- gsub('<','<',st); st <- gsub('>','>',st); if (length(st) == 0 || is.null(st) || st == '') st <- ' '; st }"); EXEC("zebelem <- function(n,v) { cl <<- ifelse(cl=='e','o','e'); cat(''); if(!is.na(n)) cat('',n,''); cat(''); if (length(v)>1) zebra(NULL,v) else cat(scrub(v)); cat('\n'); }"); EXEC("zebra <- function(title,l){ if (!is.null(title)) cat('

',title,'

',sep=''); cat('',sep=''); n <- names(l); mapply(zebelem,if(is.null(n)) rep(NA,length(l)) else n, l); cat('
\n') }"); EXEC(" zebrifyPackage <-function(package){ zebra(package,unclass(packageDescription(package))); cat('

\\n') }"); /* Header */ PUTS(DOCTYPE_XHTML_1_0T); PUTS(""); PUTS(""); PUTS(""); PUTS("RApacheInfo()"); PUTS(""); PUTS(""); PUTS(""); PUTS(" "); PUTS("\"R"); /* RApache version info */ PUTS("
RApache version "); PUTS(MOD_R_VERSION); PUTS("
"); PUTS("
"); PUTS("

jump to:

"); PUTS("Top

"); PUTS("R.version
"); PUTS("search()
"); PUTS(".libPaths()
"); PUTS("options()
"); PUTS("Sys.getenv()
"); PUTS("Sys.info()
"); PUTS(".Machine
"); PUTS(".Platform
"); PUTS("Cstack_info()

"); PUTS("Attached Packages

"); PUTS("Installed Packages

"); PUTS("License

"); PUTS("People"); PUTS("
"); EXEC("zebra('R.version',R.version)"); PUTS("

"); EXEC("zebra('search()',search())"); PUTS("

"); EXEC("zebra('.libPaths()',.libPaths())"); PUTS("

"); EXEC("zebra('options()',options())"); PUTS("

"); EXEC("zebra('Sys.getenv()',as.list(Sys.getenv()))"); PUTS("

"); EXEC("zebra('Sys.info()',as.list(Sys.info()))"); PUTS("

"); EXEC("zebra('.Machine',.Machine)"); PUTS("

"); EXEC("zebra('.Platform',.Platform)"); PUTS("

"); EXEC("zebra('Cstack_info()',as.list(Cstack_info()))"); PUTS("

"); PUTS("

Attached Packages

"); EXEC("lapply(sub('package:','',search()[grep('package:',search())]),zebrifyPackage)"); PUTS("

Installed Packages

"); EXEC("lapply(attr(installed.packages(),'dimnames')[[1]],zebrifyPackage)"); /* Footer */ PUTS("

License

"); PUTS("
");
   PUTS("Copyright 2011-2012 Vanderbilt University\n");
   PUTS("\n");
   PUTS("Licensed under the Apache License, Version 2.0 (the \"License\");\n");
   PUTS("you may not use this file except in compliance with the License.\n");
   PUTS("You may obtain a copy of the License at\n");
   PUTS("\n");
   PUTS("  http://www.apache.org/licenses/LICENSE-2.0\"\n");
   PUTS("\n");
   PUTS("Unless required by applicable law or agreed to in writing, software\n");
   PUTS("distributed under the License is distributed on an \"AS IS\" BASIS,\n");
   PUTS("WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n");
   PUTS("See the License for the specific language governing permissions and\n");
   PUTS("limitations under the License.\n");
   PUTS("

\n"); PUTS("

People

\n"); PUTS("

Thanks to the following people for their contributions, giving advice, noticing when things were broken and such. If I've forgotten to mention you, please email me.

\n"); PUTS("
\n");
   PUTS("	Gregoire Thomas\n");
   PUTS("	Jan de Leeuw\n");
   PUTS("	Keven E. Thorpe\n");
   PUTS("	Jeremy Stephens\n");
   PUTS("	Aleksander Wawer\n");
   PUTS("	David Konerding\n");
   PUTS("	Robert Kofler\n");
   PUTS("	Jeroen Ooms\n");
   PUTS("
"); PUTS(""); return DONE; } #undef PUTS #undef EXEC struct TableCtx { SEXP list; SEXP names; int size; }; static int TableCallback(void *datum,const char *n, const char *v){ struct TableCtx *ctx = (struct TableCtx *)datum; SEXP value; if (!v || !strcmp(v,"")){ value = R_NilValue; } else { value = NEW_CHARACTER(1); STRING_PTR(value)[0] = mkChar(v); } STRING_PTR(ctx->names)[ctx->size]=mkChar(n); SET_ELEMENT(ctx->list,ctx->size,value); ctx->size += 1; return 1; } static int ParamsCallback(void *datum,const char *n, const char *v){ struct TableCtx *ctx = (struct TableCtx *)datum; SEXP key, value, oldValue; int nlen, vlen, nameIndex, valueIndex, valueSet; const char *s; /* Handle array parameters */ valueSet = 0; nlen = strlen(n); if (nlen > 2 && n[nlen-2] == '[' && n[nlen-1] == ']') { /* Look to see if this key already exists */ for (nameIndex = 0; nameIndex < ctx->size; nameIndex++) { s = CHAR(STRING_ELT(ctx->names, nameIndex)); if (strlen(s) == (nlen-2) && strncmp(s, n, nlen-2) == 0) { /* Key exists, so append this value on */ oldValue = VECTOR_ELT(ctx->list, nameIndex); vlen = length(oldValue); PROTECT(value = NEW_STRING(vlen + 1)); for (valueIndex = 0; valueIndex < vlen; valueIndex++) { SET_STRING_ELT(value, valueIndex, STRING_ELT(oldValue, valueIndex)); } SET_STRING_ELT(value, valueIndex, mkChar(v)); UNPROTECT(1); SET_VECTOR_ELT(ctx->list, nameIndex, value); valueSet = 1; break; } } if (!valueSet) { key = mkCharLen(n, nlen-2); } } else { key = mkChar(n); } if (!valueSet) { STRING_PTR(ctx->names)[ctx->size]=key; if (!v || !strcmp(v,"")){ value = R_NilValue; } else { value = NEW_CHARACTER(1); STRING_PTR(value)[0] = mkChar(v); } SET_ELEMENT(ctx->list,ctx->size,value); ctx->size += 1; } return 1; } static SEXP AprTableToList(apr_table_t *t, apr_table_do_callback_fn_t *callback){ int len, i; struct TableCtx ctx; SEXP list, names; if (!t) return R_NilValue; len = apr_table_elts(t)->nelts; if (!len) return R_NilValue; PROTECT(ctx.list = NEW_LIST(len)); PROTECT(ctx.names = NEW_STRING(len)); ctx.size = 0; apr_table_do(callback,(void *)&ctx,t,NULL); /* if actual size differs (because of array parameters), shorten the list */ if (ctx.size < len) { PROTECT(list = NEW_LIST(ctx.size)); PROTECT(names = NEW_STRING(ctx.size)); for (i = 0; i < ctx.size; i++) { SET_VECTOR_ELT(list, i, VECTOR_ELT(ctx.list, i)); SET_STRING_ELT(names, i, STRING_ELT(ctx.names, i)); } SET_NAMES(list, names); UNPROTECT(4); return list; } SET_NAMES(ctx.list,ctx.names); UNPROTECT(2); return ctx.list; } /************************************************************************* * * .Call functions: used from R code. * *************************************************************************/ SEXP RApache_setHeader(SEXP header, SEXP value){ const char *key = CHAR(STRING_PTR(header)[0]); const char *val; if (!MR_Request.r) return NewLogical(FALSE); if (!key) return NewLogical(FALSE); if (value == R_NilValue){ apr_table_unset(MR_Request.r->headers_out,key); } else { if (!isString(value)){ value = coerceVector(value,STRSXP); } val = CHAR(STRING_PTR(value)[0]); if (!val) return NewLogical(FALSE); apr_table_set(MR_Request.r->headers_out,key,val); } return NewLogical(TRUE); } SEXP RApache_setStatus(SEXP status){ if (!MR_Request.r) return NewLogical(FALSE); MR_Request.r->status = asInteger(status); return NewLogical(TRUE); } SEXP RApache_setContentType(SEXP stype){ const char *ctype; if (!MR_Request.r) return NewLogical(FALSE); if (stype == R_NilValue) return NewLogical(FALSE); ctype = CHAR(STRING_PTR(stype)[0]); if (!ctype) return NewLogical(FALSE); ap_set_content_type( MR_Request.r, apr_pstrdup(MR_Request.r->pool,ctype)); return NewLogical(TRUE); } SEXP RApache_setCookie(SEXP sname, SEXP svalue, SEXP sexpires, SEXP spath, SEXP sdomain, SEXP therest){ const char *name, *value, *cookie, *cookies; char strExpires[APR_RFC822_DATE_LEN]; apr_time_t texpires; if (!MR_Request.r) return NewLogical(FALSE); /* name */ if (sname == R_NilValue) return NewLogical(FALSE); else name = CHAR(STRING_PTR(sname)[0]); /* value */ if (svalue == R_NilValue || LENGTH(svalue) != 1) value = ""; else { svalue = coerceVector(svalue,STRSXP); value = (svalue != NA_STRING)? CHAR(STRING_PTR(svalue)[0]): ""; } cookie = apr_pstrcat(MR_Request.r->pool,name,"=",value,NULL); /* expires */ if (sexpires != R_NilValue && inherits(sexpires,"POSIXt") ){ SEXP tmpExpires; if (inherits(sexpires,"POSIXct")){ tmpExpires = sexpires; } else if (inherits(sexpires,"POSIXlt")){ tmpExpires = CallFun1expr("as.POSIXct",sexpires,R_GlobalEnv,NULL); } apr_time_ansi_put(&texpires,(time_t)(REAL(tmpExpires)[0])); apr_rfc822_date(strExpires, texpires); cookie = apr_pstrcat(MR_Request.r->pool,cookie,";expires=",strExpires,NULL); } /* path */ if (spath != R_NilValue && isString(spath)) cookie = apr_pstrcat(MR_Request.r->pool,cookie,";path=",CHAR(STRING_PTR(spath)[0]),NULL); /* domain */ if (sdomain != R_NilValue && isString(sdomain)) cookie = apr_pstrcat(MR_Request.r->pool,cookie,";domain=",CHAR(STRING_PTR(sdomain)[0]),NULL); /* therest */ if (therest != R_NilValue && isString(therest) && CHAR(STRING_PTR(therest)[0])[0] != '\0'){ cookie = apr_pstrcat(MR_Request.r->pool,cookie,";",CHAR(STRING_PTR(therest)[0]),NULL); } if (!apr_table_get(MR_Request.r->headers_out,"Cache-Control")) apr_table_set(MR_Request.r->headers_out,"Cache-Control","nocache=\"set-cookie\""); apr_table_add(MR_Request.r->headers_out,"Set-Cookie",cookie); return NewLogical(TRUE); } /* HTML Entity en/decoding */ static SEXP encode(const char *str){ SEXP retstr; char *buf; int len; len = strlen(str); buf = R_alloc(3*len+1,sizeof(char)); if (!buf) return R_NilValue; if (apreq_encode(buf,str,len)){ retstr = mkChar(buf); } else { retstr = R_NilValue; } /* free(buf); */ return retstr; } static SEXP decode(const char *str){ SEXP retstr; char *buf; apr_size_t len, blen; len = strlen(str); buf = R_alloc(len,sizeof(char)); if (!buf) return R_NilValue; if (apreq_decode(buf,&blen,str,len) == APR_SUCCESS){ retstr = mkChar(buf); } else { retstr = R_NilValue; } /* free(buf); */ return retstr; } SEXP RApache_urlEnDecode(SEXP str,SEXP enc){ int vlen, i; SEXP new_str; SEXP (*endecode)(const char *str); if (IS_LOGICAL(enc) && LOGICAL(enc)[0] == TRUE){ endecode = encode; } else { endecode = decode; } if (!IS_CHARACTER(str)){ warning("RApache_urlEnDecode called with a non-character object!"); return R_NilValue; } vlen = LENGTH(str); PROTECT(new_str = NEW_STRING(vlen)); for (i = 0; i < vlen; i++) CHARACTER_DATA(new_str)[i] = endecode(CHAR(STRING_PTR(str)[i])); UNPROTECT(1); return new_str; } SEXP RApache_RApacheInfo(){ if (!MR_Request.r) return R_NilValue; RApacheInfo(); return R_NilValue; } SEXP RApache_parseGet() { if (!MR_Request.r) return R_NilValue; /* If we've already made the table, just hand it out again */ if (MR_Request.argsTable) return AprTableToList(MR_Request.argsTable, ParamsCallback); /* Don't parse if there aren't an GET variables to parse */ if(!MR_Request.r->args) return R_NilValue; /* First call: parse and return */ MR_Request.argsTable = apr_table_make(MR_Request.r->pool,APREQ_DEFAULT_NELTS); apreq_parse_query_string(MR_Request.r->pool,MR_Request.argsTable,MR_Request.r->args); /* TODO: error checking of argsTable here */ return AprTableToList(MR_Request.argsTable, ParamsCallback); } typedef struct { SEXP files; SEXP names; int i; } RApacheFileUploads; static int FileUploadsCallback(void *ft,const char *key, const char *val){ RApacheFileUploads *pf = (RApacheFileUploads *)ft; apreq_param_t *p = apreq_value_to_param(val); apr_file_t *f; apr_finfo_t finfo; const char *filename; SEXP file_elem, name_elem, str1, str2; f = apreq_brigade_spoolfile(p->upload); /* No file upload */ if (f == NULL || (apr_file_info_get(&finfo,APR_FINFO_SIZE,f) != APR_SUCCESS) || finfo.size <= 0 ){ SET_ELEMENT(pf->files,pf->i,R_NilValue); STRING_PTR(pf->names)[pf->i]=mkChar(key); } else { filename = finfo.fname; PROTECT(file_elem = NEW_LIST(2)); PROTECT(name_elem = NEW_STRING(2)); PROTECT(str1 = NEW_STRING(1)); PROTECT(str2 = NEW_STRING(1)); STRING_PTR(str1)[0]=mkChar(val); STRING_PTR(str2)[0]=mkChar(filename); SET_ELEMENT(file_elem,0,str1); SET_ELEMENT(file_elem,1,str2); STRING_PTR(name_elem)[0]=mkChar("name"); STRING_PTR(name_elem)[1]=mkChar("tmp_name"); SET_NAMES(file_elem,name_elem); SET_ELEMENT(pf->files,pf->i,file_elem); STRING_PTR(pf->names)[pf->i]=mkChar(key); UNPROTECT(4); } pf->i += 1; return 1; } static SEXP parsePost(int returnPost) { apreq_parser_t *psr; apreq_parser_function_t pfn; apr_bucket_brigade *bb; const char *tmpdir, *content_type; apr_status_t s; const apr_table_t *uploads; SEXP filenames; int nfiles; if (!MR_Request.r) return R_NilValue; if (MR_Request.readStarted) { /* If we've already started reading with R then don't try to parse at all. */ RApacheError("Oops! Your R code has already started reading the request."); return R_NilValue; } else if (MR_Request.postParsed){ /* We've already parsed the input, just hand out the result */ return (returnPost)?AprTableToList(MR_Request.postTable, ParamsCallback):MR_Request.filesVar; } /* Don't parse if not a POST or PUT */ if (strcmp(MR_Request.r->method,"POST") != 0 && strcmp(MR_Request.r->method,"PUT") != 0) { MR_Request.postTable = NULL; MR_Request.filesVar = R_NilValue; return R_NilValue; } /* Don't try to parse if no parser function for content type */ content_type = apr_table_get(MR_Request.r->headers_in,"Content-Type"); pfn = apreq_parser(content_type); if (!pfn){ MR_Request.postTable = NULL; MR_Request.filesVar = R_NilValue; /* RApacheError(apr_psprintf(MR_Request.r->pool,"No apreq2 parser for '%s'\n",content_type)); */ return R_NilValue; } /* Start parse */ MR_Request.postParsed=1; MR_Request.postTable = apr_table_make(MR_Request.r->pool, APREQ_DEFAULT_NELTS); apr_temp_dir_get(&tmpdir,MR_Request.r->pool); psr = apreq_parser_make( MR_Request.r->pool, MR_Request.r->connection->bucket_alloc, content_type, pfn, 0, /* brigade_limit */ tmpdir, NULL, NULL); bb = apr_brigade_create(MR_Request.r->pool,MR_Request.r->connection->bucket_alloc); while((s = ap_get_brigade(MR_Request.r->input_filters,bb,AP_MODE_READBYTES,APR_BLOCK_READ,HUGE_STRING_LEN)) == APR_SUCCESS){ apreq_parser_run(psr,MR_Request.postTable,bb); if (APR_BUCKET_IS_EOS(APR_BRIGADE_LAST(bb))) break; apr_brigade_cleanup(bb); } apr_brigade_cleanup(bb); /* Now go ahead and set MR_Request.filesVar*/ uploads = apreq_uploads(MR_Request.postTable,MR_Request.r->pool); nfiles = apr_table_elts(uploads)->nelts; if (nfiles){ RApacheFileUploads fu; PROTECT(MR_Request.filesVar = NEW_LIST(nfiles)); PROTECT(filenames = NEW_STRING(nfiles)); fu.files = MR_Request.filesVar; fu.names = filenames; fu.i = 0; apr_table_do(FileUploadsCallback,(void *)&fu,uploads,NULL); SET_NAMES(MR_Request.filesVar,filenames); UNPROTECT(2); } else { MR_Request.filesVar = R_NilValue; } return (returnPost)?AprTableToList(MR_Request.postTable, ParamsCallback):MR_Request.filesVar; } SEXP RApache_parsePost(){ return parsePost(1); } SEXP RApache_parseFiles(){ return parsePost(0); } SEXP RApache_parseCookies(){ const char *cookies; if (!MR_Request.r) return R_NilValue; if (MR_Request.cookiesTable) return AprTableToList(MR_Request.cookiesTable, TableCallback); cookies = apr_table_get(MR_Request.r->headers_in, "Cookie"); if (cookies == NULL) return R_NilValue; MR_Request.cookiesTable = apr_table_make(MR_Request.r->pool,APREQ_DEFAULT_NELTS); apreq_parse_cookie_header(MR_Request.r->pool,MR_Request.cookiesTable,cookies); return AprTableToList(MR_Request.cookiesTable, TableCallback); } #define TABMBR(n,v) STRING_PTR(names)[i]=mkChar(n); SET_ELEMENT(MR_Request.serverVar,i++,AprTableToList(v, TableCallback)) #define INTMBR(n,v) STRING_PTR(names)[i]=mkChar(n); val = NEW_INTEGER(1); INTEGER_DATA(val)[0] = v; SET_ELEMENT(MR_Request.serverVar,i++,val) #define STRMBR(n,v) STRING_PTR(names)[i]=mkChar(n); if (v){ val = NEW_STRING(1); STRING_PTR(val)[0] = mkChar(v);} else { val = R_NilValue;}; SET_ELEMENT(MR_Request.serverVar,i++,val) #define LGLMBR(n,v) STRING_PTR(names)[i]=mkChar(n); SET_ELEMENT(MR_Request.serverVar,i++,NewLogical(v)); #define OFFMBR(n,v) STRING_PTR(names)[i]=mkChar(n); val = NEW_NUMERIC(1); NUMERIC_DATA(val)[0] = (double)v; SET_ELEMENT(MR_Request.serverVar,i++,val) #define TIMMBR(n,v) STRING_PTR(names)[i]=mkChar(n); val = NEW_NUMERIC(1); NUMERIC_DATA(val)[0] = (double)apr_time_sec(v); class = NEW_STRING(2); STRING_PTR(class)[0] = mkChar("POSIXt"); STRING_PTR(class)[1] = mkChar("POSIXct"); SET_CLASS(val,class); SET_ELEMENT(MR_Request.serverVar,i++,val) #define FUNMBR(n,v) STRING_PTR(names)[i]=mkChar(n); val = ParseEval(v,MR_RApacheEnv,&evalError); SET_ELEMENT(MR_Request.serverVar,i++,val) SEXP RApache_getServer(){ int len = 39, i = 0, evalError=1; SEXP names, val, class; if (!MR_Request.r) return R_NilValue; if (MR_Request.serverVar) return MR_Request.serverVar; PROTECT(MR_Request.serverVar = NEW_LIST(len)); PROTECT(names = NEW_STRING(len)); TABMBR("headers_in",MR_Request.r->headers_in); INTMBR("proto_num",MR_Request.r->proto_num); STRMBR("protocol",MR_Request.r->protocol); STRMBR("unparsed_uri",MR_Request.r->unparsed_uri); STRMBR("uri",MR_Request.r->uri); STRMBR("filename",MR_Request.r->filename); STRMBR("canonical_filename",MR_Request.r->canonical_filename); STRMBR("path_info",MR_Request.r->path_info); STRMBR("args",MR_Request.r->args); STRMBR("content_type",MR_Request.r->content_type); STRMBR("handler",MR_Request.r->handler); STRMBR("content_encoding",MR_Request.r->content_encoding); STRMBR("range",MR_Request.r->range); STRMBR("hostname",MR_Request.r->hostname); STRMBR("address",MR_Request.r->connection->local_ip); INTMBR("port",ap_get_server_port(MR_Request.r)); STRMBR("user",MR_Request.r->user); LGLMBR("header_only",MR_Request.r->header_only); LGLMBR("no_cache",MR_Request.r->no_cache); LGLMBR("no_local_copy",MR_Request.r->no_local_copy); LGLMBR("assbackwards",MR_Request.r->assbackwards); INTMBR("status",MR_Request.r->status); INTMBR("method_number",MR_Request.r->method_number); LGLMBR("eos_sent",MR_Request.r->eos_sent); STRMBR("the_request",MR_Request.r->the_request); STRMBR("method",MR_Request.r->method); STRMBR("status_line",MR_Request.r->status_line); OFFMBR("bytes_sent",MR_Request.r->bytes_sent); OFFMBR("clength",MR_Request.r->clength); OFFMBR("remaining",MR_Request.r->remaining); OFFMBR("read_length",MR_Request.r->read_length); TIMMBR("request_time",MR_Request.r->request_time); TIMMBR("mtime",MR_Request.r->mtime); #if (AP_SERVER_MAJORVERSION_NUMBER == 2 && AP_SERVER_MINORVERSION_NUMBER == 4) STRMBR("remote_ip",MR_Request.r->connection->client_ip); #elif (AP_SERVER_MAJORVERSION_NUMBER == 2 && AP_SERVER_MINORVERSION_NUMBER == 2) STRMBR("remote_ip",MR_Request.r->connection->remote_ip); #endif STRMBR("remote_host",MR_Request.r->connection->remote_host); STRMBR("cmd_path",MR_Request.handler->directive->cmdpath); LGLMBR("HTTPS",(apr_table_get(MR_Request.r->subprocess_env,"HTTPS")!=NULL)? 1 : 0); STRMBR("rapache_version",MOD_R_VERSION); FUNMBR("internals","function(x) .Call('RApache_internals',x)"); SET_NAMES(MR_Request.serverVar,names); UNPROTECT(2); return MR_Request.serverVar; } static void swapb(void *result, int size) { int i; char *p = result, tmp; if (size == 1) return; for (i = 0; i < size/2; i++) { tmp = p[i]; p[i] = p[size - i - 1]; p[size - i - 1] = tmp; } } SEXP RApache_sendBin(SEXP object, SEXP ssize, SEXP sswap){ SEXP ans = R_NilValue; int i, j, size, swap, len; const char *s; char *buf; /* Rboolean wasopen = TRUE, isRaw = FALSE; Rconnection con = NULL; */ if (!MR_Request.r) return R_NilValue; /* checkArity(op, args); */ /* object = CAR(args); */ if(!isVectorAtomic(object)) error("'x' is not an atomic vector type"); /* if(TYPEOF(CADR(args)) == RAWSXP) { isRaw = TRUE; } else { con = getConnection(asInteger(CADR(args))); if(con->text) error(_("can only write to a binary connection")); wasopen = con->isopen; if(!con->canwrite) error(_("cannot write to this connection")); } */ size = asInteger(ssize); swap = asLogical(sswap); if(swap == NA_LOGICAL) error("invalid 'swap' argument"); len = LENGTH(object); /* if(len == 0) { if(isRaw) return allocVector(RAWSXP, 0); else return R_NilValue; } */ if (len == 0) return R_NilValue; /* if(!wasopen) if(!con->open(con)) error(_("cannot open the connection")); */ if(TYPEOF(object) == STRSXP) { /* if(isRaw) { Rbyte *bytes; int np, outlen; for(i = 0, outlen = 0; i < len; i++) outlen += strlen(translateChar(STRING_ELT(object, i))) + 1; PROTECT(ans = allocVector(RAWSXP, outlen)); bytes = RAW(ans); for(i = 0, np = 0; i < len; i++) { s = translateChar(STRING_ELT(object, i)); memcpy(bytes+np, s, strlen(s) + 1); np += strlen(s) + 1; } } else { */ for(i = 0; i < len; i++) { s = translateChar(STRING_ELT(object, i)); /* n = con->write(s, sizeof(char), strlen(s) + 1, con); */ /* n = ap_fwrite(MR_Request.r->output_filters,MR_BBout,s,strlen(s)+1); */ if (apr_brigade_write(MR_BBout,NULL,NULL,s,strlen(s)) != APR_SUCCESS) { warning("problem writing to connection"); break; } } /* } */ } else { switch(TYPEOF(object)) { case LGLSXP: case INTSXP: if(size == NA_INTEGER) size = sizeof(int); switch (size) { case sizeof(signed char): case sizeof(short): case sizeof(int): #if SIZEOF_LONG == 8 case sizeof(long): #elif SIZEOF_LONG_LONG == 8 case sizeof(_lli_t): #endif break; default: error("size %d is unknown on this machine", size); } break; case REALSXP: if(size == NA_INTEGER) size = sizeof(double); switch (size) { case sizeof(double): case sizeof(float): #if SIZEOF_LONG_DOUBLE > SIZEOF_DOUBLE case sizeof(long double): #endif break; default: error("size %d is unknown on this machine", size); } break; case CPLXSXP: if(size == NA_INTEGER) size = sizeof(Rcomplex); if(size != sizeof(Rcomplex)) error("size changing is not supported for complex vectors"); break; case RAWSXP: if(size == NA_INTEGER) size = 1; if(size != 1) error("size changing is not supported for raw vectors"); break; default: error("unimplemented type in sendBin"); } buf = R_chk_calloc(len, size); /* R_alloc(len, size); */ switch(TYPEOF(object)) { case LGLSXP: case INTSXP: switch (size) { case sizeof(int): memcpy(buf, INTEGER(object), size * len); break; #if SIZEOF_LONG == 8 case sizeof(long): { long l1; for (i = 0, j = 0; i < len; i++, j += size) { l1 = (long) INTEGER(object)[i]; memcpy(buf + j, &l1, size); } break; } #elif SIZEOF_LONG_LONG == 8 case sizeof(_lli_t): { _lli_t ll1; for (i = 0, j = 0; i < len; i++, j += size) { ll1 = (_lli_t) INTEGER(object)[i]; memcpy(buf + j, &ll1, size); } break; } #endif case 2: { short s1; for (i = 0, j = 0; i < len; i++, j += size) { s1 = (short) INTEGER(object)[i]; memcpy(buf + j, &s1, size); } break; } case 1: for (i = 0; i < len; i++) buf[i] = (signed char) INTEGER(object)[i]; break; default: error("size %d is unknown on this machine", size); } break; case REALSXP: switch (size) { case sizeof(double): memcpy(buf, REAL(object), size * len); break; case sizeof(float): { float f1; for (i = 0, j = 0; i < len; i++, j += size) { f1 = (float) REAL(object)[i]; memcpy(buf+j, &f1, size); } break; } #if SIZEOF_LONG_DOUBLE > SIZEOF_DOUBLE case sizeof(long double): { /* some systems have problems with memcpy from the address of an automatic long double, e.g. ix86/x86_64 Linux with gcc4 */ static long double ld1; for (i = 0, j = 0; i < len; i++, j += size) { ld1 = (long double) REAL(object)[i]; memcpy(buf+j, &ld1, size); } break; } #endif default: error("size %d is unknown on this machine", size); } break; case CPLXSXP: memcpy(buf, COMPLEX(object), size * len); break; case RAWSXP: memcpy(buf, RAW(object), len); /* size = 1 */ break; } if(swap && size > 1) { if (TYPEOF(object) == CPLXSXP) for(i = 0; i < len; i++) { int sz = size/2; swapb(buf+sz*2*i, sz); swapb(buf+sz*(2*i+1), sz); } else for(i = 0; i < len; i++) swapb(buf+size*i, size); } /* write it now */ /* if(isRaw) { PROTECT(ans = allocVector(RAWSXP, size*len)); memcpy(RAW(ans), buf, size*len); } else { */ /* n = con->write(buf, size, len, con); */ /* n = ap_fwrite(MR_Request.r->output_filters,MR_BBout,buf,size*len); */ if (apr_brigade_write(MR_BBout,NULL,NULL,buf,size*len) != APR_SUCCESS) { warning("problem writing to connection"); } /* } */ Free(buf); } /* if(!wasopen) con->close(con); if(isRaw) { R_Visible = TRUE; UNPROTECT(1); } else R_Visible = FALSE; */ return ans; } SEXP RApache_receiveBin(SEXP llen){ int len=0, size, blen; unsigned char *buf; SEXP ans; size = asInteger(llen); /* We manage allocation ourselves since it's possible that either * apache or R would keep it around for longer than necessary. We * certainly don't want to use up twice as much memory for the * raw message body. */ if (size > 0){ buf = Calloc(size,unsigned char); if (buf == NULL){ ap_log_rerror(APLOG_MARK,APLOG_ERR,0,MR_Request.r,"memory error"); return allocVector(RAWSXP,0); } len = ReadRequestBody(buf,size); } else if (size < 0){ /* read whole request payload */ size = 8192; buf = Calloc(size,unsigned char); blen = 0; if (buf == NULL){ ap_log_rerror(APLOG_MARK,APLOG_ERR,0,MR_Request.r,"memory error"); return allocVector(RAWSXP,0); } while (1){ len = ReadRequestBody(buf+blen,size-blen); blen += len; if (len > 0){ size = (int)((double)size * 1.5); /* 50% over-allocation */ buf = Realloc(buf,size,unsigned char); if (buf == NULL){ ap_log_rerror(APLOG_MARK,APLOG_ERR,0,MR_Request.r,"memory error"); return allocVector(RAWSXP,0); } } else { len = blen; break; } } } PROTECT(ans = allocVector(RAWSXP,len)); if (len > 0) memcpy(RAW(ans),buf,len); if (buf) Free(buf); UNPROTECT(1); return ans; } SEXP RApache_internals(SEXP sstr){ const char *str; if (!IS_CHARACTER(sstr)) return R_NilValue; str = CHAR(STRING_ELT(sstr,0)); if (strcmp(str,"postParsed")==0) { return NewLogical(MR_Request.postParsed); } else if (strcmp(str,"readStarted")==0) { return NewLogical(MR_Request.readStarted); } return R_NilValue; } static void RegisterCallSymbols() { R_CallMethodDef callMethods[] = { {"RApache_setHeader", (DL_FUNC) &RApache_setHeader, 2}, {"RApache_setStatus", (DL_FUNC) &RApache_setStatus, 1}, {"RApache_setContentType", (DL_FUNC) &RApache_setContentType, 1}, {"RApache_setCookie",(DL_FUNC) &RApache_setCookie,6}, {"RApache_urlEnDecode",(DL_FUNC) &RApache_urlEnDecode,2}, {"RApache_RApacheInfo",(DL_FUNC) &RApache_RApacheInfo,0}, {"RApache_parseGet",(DL_FUNC) &RApache_parseGet,0}, {"RApache_parsePost",(DL_FUNC) &RApache_parsePost,0}, {"RApache_parseFiles",(DL_FUNC) &RApache_parseFiles,0}, {"RApache_parseCookies",(DL_FUNC) &RApache_parseCookies,0}, {"RApache_getServer",(DL_FUNC) &RApache_getServer,0}, {"RApache_sendBin",(DL_FUNC) &RApache_sendBin,3}, {"RApache_receiveBin",(DL_FUNC) &RApache_receiveBin,1}, {"RApache_internals",(DL_FUNC) &RApache_internals,1}, {NULL, NULL, 0} }; R_registerRoutines(R_getEmbeddingDllInfo(),NULL,callMethods,NULL,NULL); } rapache-1.2.8/mod_R.h.in0000644000175100017510000000003112706745114014272 0ustar ondrejondrej#define R_HOME "@RHOME@" rapache-1.2.8/rpm/0000755000175100017510000000000012706745114013260 5ustar ondrejondrejrapache-1.2.8/rpm/00-rapache.conf0000644000175100017510000000040412706745114015745 0ustar ondrejondrej# EL < 7 does not load ./conf.modules.d/ LoadModule R_module modules/mod_R.so # Sites SetHandler r-info SetHandler r-script RHandler sys.source rapache-1.2.8/rpm/99-rapache.conf0000644000175100017510000000012512706745114015767 0ustar ondrejondrej# LoadModule R_module modules/mod_R.so # rapache-1.2.8/rpm/rapache-openSUSE_13.2.spec0000644000175100017510000000301312706745114017636 0ustar ondrejondrejName: rapache Version: 1.2.7 Release: rpm0 Source: %{name}-%{version}.tar.gz License: Apache2 Summary: RApache module for apache2 web server (mod_R) Group: Applications/Internet Buildroot: %{_tmppath}/%{name}-buildroot URL: http://www.rapache.net BuildRequires: apache2-devel BuildRequires: R-base-devel BuildRequires: libicu-devel BuildRequires: make Requires: libicu Requires: apache2 Requires: apache2-prefork Requires: R-base %description First presented at DSC2005, rApache is a project supporting web application development using the R statistical language and environment and the Apache web server. The current release runs on UNIX/Linux and Mac OS X operating systems. %prep %setup %build ./configure make %install mkdir -p $RPM_BUILD_ROOT%{_libdir}/apache2/ sed -i.bak s\,modules/mod_R.so,%{_libdir}/apache2/mod_R.so,g ./rpm/00-rapache.conf sed -i.bak s\,/var/www/html,/srv/www/htdocs,g ./rpm/00-rapache.conf cp .libs/mod_R.so $RPM_BUILD_ROOT%{_libdir}/apache2/ cp libapreq2/library/.libs/libapreq2.so.3 $RPM_BUILD_ROOT%{_libdir}/ mkdir -p %{buildroot}/etc/apache2/conf.d cp ./rpm/00-rapache.conf %{buildroot}/etc/apache2/conf.d/ mkdir -p %{buildroot}/srv/www/htdocs/R cp ./rpm/test %{buildroot}/srv/www/htdocs/R/ export NO_BRP_CHECK_RPATH=true %pre %post systemctl restart apache2.service || true %preun %postun systemctl restart apache2.service || true %files %defattr(644,wwwrun,www,755) /etc/apache2/conf.d/00-rapache.conf %{_libdir}/apache2/mod_R.so %{_libdir}/libapreq2.so.3 %dir /srv/www/htdocs/R /srv/www/htdocs/R/test rapache-1.2.8/rpm/rapache.spec0000644000175100017510000000346412706745114015546 0ustar ondrejondrejName: rapache Version: 1.2.7 Release: rpm0 Source: %{name}-%{version}.tar.gz License: Apache2 Summary: RApache module for apache2 web server (mod_R) Group: Applications/Internet Buildroot: %{_tmppath}/%{name}-buildroot URL: http://www.rapache.net BuildRequires: httpd-devel BuildRequires: libapreq2-devel BuildRequires: R-devel BuildRequires: make Requires: /usr/sbin/sestatus Requires: httpd Requires: libapreq2 Requires: R-core %description First presented at DSC2005, rApache is a project supporting web application development using the R statistical language and environment and the Apache web server. The current release runs on UNIX/Linux and Mac OS X operating systems. %prep %setup %build ./configure --with-apache2-apxs=/usr/bin/apxs make %install #make prefix=$RPM_BUILD_ROOT install mkdir -p %{buildroot}/etc/httpd/modules cp .libs/mod_R.so %{buildroot}/etc/httpd/modules/ mkdir -p %{buildroot}/etc/httpd/conf.modules.d cp ./rpm/99-rapache.conf %{buildroot}/etc/httpd/conf.modules.d/ mkdir -p %{buildroot}/etc/httpd/conf.d cp ./rpm/00-rapache.conf %{buildroot}/etc/httpd/conf.d/ mkdir -p %{buildroot}/var/www/html/R cp ./rpm/test %{buildroot}/var/www/html/R/ %pre %post # SELinux settings SELINUX_ENABLED=$(sestatus | grep "SELinux.status.*enabled") if [ "$1" = 1 ] && [ "$SELINUX_ENABLED" ]; then chcon -t httpd_modules_t /etc/httpd/modules/mod_R.so || true fi # echo "Configuring SELinux. This takes a while..." # Perhaps leave this to the sysadmin: # setsebool -P httpd_setrlimit=1 httpd_can_network_connect_db=1 httpd_can_network_connect=1 httpd_can_connect_ftp=1 httpd_can_sendmail=1 || true # Restart to load module apachectl restart || true %preun %postun apachectl restart || true %files /etc/httpd/conf.modules.d/99-rapache.conf /etc/httpd/conf.d/00-rapache.conf /etc/httpd/modules/mod_R.so /var/www/html/R/test rapache-1.2.8/rpm/readme.md0000644000175100017510000000622112706745114015040 0ustar ondrejondrej# rApache rpm package Instructions for building rApache as an rpm package. This has been tested on Fedora 20 and CentOS 6. ## Prepare The standard Redhat repositories do not include R, but backports from Fedora are available through EPEL. If you are running RHEL or CentOS, you need to enable the EPEL repository. On Fedora you can skip this step. On RHEL/CentOS 6: sudo su -c 'rpm -Uvh https://dl.fedoraproject.org/pub/epel/6/i386/epel-release-6-8.noarch.rpm' On RHEL/CentOS 7: sudo su -c 'rpm -Uvh https://dl.fedoraproject.org/pub/epel/beta/7/x86_64/epel-release-7-0.2.noarch.rpm' The `epel-release` rpm version changes from time to time. Find the current version on the website EPEL if you get an error. See also [this FAQ](https://fedoraproject.org/wiki/EPEL/FAQ#How_can_I_install_the_packages_from_the_EPEL_software_repository.3F). ## Building on Fedora / RHEL / CentOS Important: make sure to run the lines in this section **not as root**. Except for the `sudo` lines of course. First setup a build environment: # rpm build dependencies sudo yum install rpm-build # rApache build dependencies sudo yum install make wget httpd-devel libapreq2-devel R-devel # Build directories mkdir -p ~/rpmbuild/SOURCES mkdir -p ~/rpmbuild/SPECS Download sources: # Get the rapache source code wget https://github.com/jeffreyhorner/rapache/archive/v1.2.6.tar.gz -O rapache-1.2.6.tar.gz tar xzvf rapache-1.2.6.tar.gz rapache-1.2.6/rpm/rapache.spec --strip-components 2 # Move to build dirs mv -f rapache-1.2.6.tar.gz ~/rpmbuild/SOURCES/ mv -f rapache.spec ~/rpmbuild/SPECS/ Build: cd ~ rpmbuild -ba ~/rpmbuild/SPECS/rapache.spec ## Installing rApache If all is OK, packages are created in `~/rpmbuild/RPMS` and `~/rpmbuild/SRPMS`. To install them on your build machine: cd ~/rpmbuild/RPMS/x86_64/ sudo rpm -i rapache-1.2.6-rpm0.x86_64.rpm The package includes a test script in `/var/www/html/R/test` which prints some random numers. Try if it works: curl http://localhost/R/test Also try to open http://localhost/RApacheInfo in your browser. ## Debugging SELinux If you get permission denied error when (re)starting httpd or accessing your web server, the problem is most likely SELinux. SELinux can be disabled by editing `/etc/selinux/config` and then rebooting. If you don't want to disable SELinux, you will have to customize the security profiles for your needs. Have a look at `/var/log/messages` and `/var/log/audit/audit.log`. Installing the `setroubleshoot` and `setroubleshoot-server` packages results in better logging. The [selinux_httpd man page](http://linux.die.net/man/8/httpd_selinux) lists important booleans that you might want to turn on. See also [this help page](https://docs.fedoraproject.org/en-US/Fedora/19/html/Security_Guide/sect-Managing_Confined_Services-The_Apache_HTTP_Server.html). ## Firewall On most standard installations of RHEL and CentOS, the default firewall configuration is to block HTTP/HTTPS traffic from external hosts. To open port 80 (HTTP) use something like: sudo iptables -I INPUT -p tcp --dport 80 -j ACCEPT sudo service iptables save Google is your friend. rapache-1.2.8/rpm/test0000644000175100017510000000006612706745114014164 0ustar ondrejondrejcat("Todays lucky numers are:\n\n") print(rnorm(100)) rapache-1.2.8/test/0000755000175100017510000000000012706745114013441 5ustar ondrejondrejrapache-1.2.8/test/AppServer.R0000644000175100017510000000416012706745114015474 0ustar ondrejondrej# # A simple system for supporting many web applications # installed under BASEDIR. # # The apache config might look something like this: # # RFileHandler /var/www/rApache/AppServer.R::AppServer # # BASEDIR <- '/var/www/rApache' # The Appserver function searches the URI for a segment that matches # a directory under BASEDIR. If it exists, and a file handler.R is present, it # is sourced in a new environment and a function called handler is expected to exist. # If so, it is called and the return value is returned from AppServer(). AppServer <- function(){ setContentType('text/html') setwd(BASEDIR) #cat(SERVER$uri,file=stderr()) # First split the uri by "/", first element will always be "". uri <- strsplit(SERVER$uri,"/")[[1]][-1] # bad uri if (length(uri) == 0){ cat(paste("Empty URI",SERVER$uri),file=stderr()) return(OK) } # Find the list of dirs; we call them apps. apps <- rownames(subset(file.info(dir()), isdir==TRUE)) # No apps to consider if (length(apps) == 0){ cat(paste("Empty List of Applications for URI:",SERVER$uri),file=stderr()) return(OK) } # returns a vector of uri index positions where apps are found in uri. i <- match(apps,uri,nomatch=0) # First non-zero index position of i is our first app found appIndex <- which(i > 0)[1] # No app exists in uri if (is.na(appIndex)){ cat(paste("No Applications for URI:",SERVER$uri,"Apps:",apps),file=stderr()) return(OK) } app <- apps[appIndex] # Now we have our app, but does a "handler.R" exist? if (!file.exists(paste(app,"handler.R",sep='/'))){ cat(paste("Missing handler.R for Application:",app,'(',dir(app),')'),file=stderr()) return(OK) } uriIndex <- i[appIndex] # Yes, now set up an environment from which to operate and go for it! appURI <- paste("/",paste(uri[1:uriIndex],collapse='/'),sep='') appPathInfo <- sub(appURI,'',SERVER$uri) setwd(app) # Source the handler sys.source("handler.R",envir=environment(AppServer)) # Was a handler function created? if (exists("handler",mode="function",envir=environment(AppServer))){ return(handler(appURI,appPathInfo)) } OK } rapache-1.2.8/test/PreserveEnv.R0000644000175100017510000000036312706745114016032 0ustar ondrejondrejfoo <- 'bar' main <- function(){ setContentType('text/html') cat('

Hello',foo,'!

\n') foo <<- 'touched by main' } handler <- function(){ setContentType('text/html') cat('

Hello',foo,'!

\n') foo <<- 'touched by handler' } rapache-1.2.8/test/RookTest.R0000644000175100017510000000317712706745114015346 0ustar ondrejondrejapp <- function(env){ req <- Request$new(env) res <- Response$new() cat('hello',file=stderr()) envstr <- paste(capture.output(str(as.list(env)),file=NULL),collapse='\n') poststr <- paste(capture.output(str(req$POST()),file=NULL),collapse='\n') getstr <- paste(capture.output(str(req$GET()),file=NULL),collapse='\n') randomString <- function() paste(letters[floor(runif(10,0,26))],collapse='') randomNumber <- function() runif(1,0,26) res$write( c( '', 'rook logo', '

Welcome to Rook

\n', sprintf('
',env$SCRIPT_NAME,randomString(),randomNumber()), 'Enter a string:
\n', 'Enter another string:
\n', 'Upload a file:
\n', 'Upload another file:
\n', '

', 'Environment:
',envstr,'

', 'Get:
',getstr,'

', 'Post:
',poststr, '


' )) res$finish() } rapache-1.2.8/test/brew/0000755000175100017510000000000012706745114014400 5ustar ondrejondrejrapache-1.2.8/test/brew/RApacheInfo.rhtml0000644000175100017510000000755012706745114017576 0ustar ondrejondrej<% hrefify <- function(title) gsub('[\\.()]','_',title,perl=TRUE) scrub <- function(str){ if (is.null(str)) return('NULL') if (length(str) == 0) return ('length 0 string') if (is.na(str)) return('NA') str <- as.character(str) str <- gsub('&','&',str); str <- gsub('@','_at_',str); str <- gsub('<','<',str); str <- gsub('>','>',str); if (length(str) == 0 || is.null(str) || str == '') str <- ' ' str } cl<-'e' zebelem <- function(n,v) { cl <<- ifelse(cl=='e','o','e') cat('') if(!is.na(n)) cat('',n,'') cat(''); if (length(v)>1) zebra(NULL,v) else cat(scrub(v)) cat('\n'); } zebra <- function(title,l){ if (!is.null(title)) cat('

',title,'

',sep='') cat('',sep='') n <- names(l) mapply(zebelem,if(is.null(n)) rep(NA,length(l)) else n, l) cat('
\n') } zebrifyPackage <-function(package){ zebra(package,unclass(packageDescription(package))) cat('

\n') } -%> Everything You Wanted To Know About Your R Session R Language Home Page
Everything You Wanted To Know About Your R Session
<% zebra('R.version',R.version) %>

<% zebra('search()',search()) %>

<% zebra('.libPaths()',.libPaths()) %>

<% zebra('options()',options()) %>

<% zebra('Sys.getenv()',as.list(Sys.getenv())) %>

<% zebra('Sys.info()',as.list(Sys.info())) %>

<% zebra('.Machine',.Machine) %>

<% zebra('.Platform',.Platform) %>

Attached Packages

<% lapply(sub('package:','',search()[grep('package:',search())]),zebrifyPackage) %>

Installed Packages

<% lapply(attr(installed.packages(),'dimnames')[[1]],zebrifyPackage) %> rapache-1.2.8/test/brew/dllinfo.rhtml0000644000175100017510000000021412706745114017074 0ustar ondrejondrej
<% print(getLoadedDLLs()) %>
Symbols for "(embedding)"
<% print(getDLLRegisteredRoutines(getLoadedDLLs()[['(embedding)']])) %>
rapache-1.2.8/test/brew/dynlex.rhtml0000644000175100017510000000157212706745114016760 0ustar ondrejondrej<% listEnclosures <- function(){ empty <- environmentName(emptyenv()) e <- parent.env(parent.frame(1)); n <- environmentName(e); i <- 1 while (n != empty){ if (n == '') n <- attributes(e)$name[1] cat('ENV:',i,n,'------------------------------\n'); vars <- ls(envir=e) if (length(vars) > 10) cat('\t',vars[1:10],'....\n') else cat('\t',vars,'\n') e <- parent.env(e) n <- environmentName(e) i <- i + 1 } } listFrames <- function(){ f <- sys.frames(); len <- length(f) - 1 ; if (len < 1) return(invisible()); cat("in listFrames\n") for ( i in len:1 ){ cat('FRAME:',len-i,'----------------\n') vars <- ls(envir=f[[i]]) if (length(vars) > 10) cat('\t',vars[1:10],'....\n') else cat('\t',vars,'\n') } } -%>

Call Stack

<% listFrames() %>

Enclosures

<% listEnclosures() %>
rapache-1.2.8/test/brew/foo.rhtml0000644000175100017510000000020412706745114016227 0ustar ondrejondrej

Brew Templating Test 2

<% 
	RApacheOutputErrors(TRUE)
	stem(rnorm(100)) 
	OK
%>
rapache-1.2.8/test/brew/info.rhtml0000644000175100017510000000002412706745114016377 0ustar ondrejondrej<% RApacheInfo() %> rapache-1.2.8/test/brew/search.rhtml0000644000175100017510000000025012706745114016712 0ustar ondrejondrej

Brew Templating

<% for (i in search()){ %>

Contents of <%=i%>

<% print(ls(i)) %>
<% } %> <% stop("foo") %> rapache-1.2.8/test/brew/simple.rhtml0000644000175100017510000000070412706745114016742 0ustar ondrejondrej<% setContentType("text/html") myname <- ifelse(is.null(GET$name),'World',GET$name) %> A Simple Example

Hello <%=myname%>!

<% if (myname=='World'){ %> What is your name?
<% } else { %> Today is: <%=format(Sys.time())%>
Click me! <% } %> rapache-1.2.8/test/brew/useR2007.css0000644000175100017510000000353212706745114016344 0ustar ondrejondrej<% setContentType('text/css') %> body { font: .7em verdana, arial, sans-serif; margin-top: 10px; margin-left:10px; margin-right:10px; /* border: 1px solid black; */ } /* img { border: 1px; position: absolute; } */ * {margin:0; padding:0;} div#mainwrapper { /* min-width:760px; */ /* max-width:880px; */ margin-left:auto; margin-right:auto;} /* centers layout when > max width */ div#header { width:auto; } #threecolwrap { float:left; width:100%; } #twocolwrap { float:left; width:100%; display:inline; /* stops IE doubling margin on float*/ margin-right:-170px; /* CWS - neg margin move */ } #leftcol { float:left; width:175px; display:inline; /* stops IE doubling margin on float*/ border: 1px solid black; } #content { width:600px; margin-left:175px; margin-top: 0px; /* margin-right:170px; */ /* border: 1px solid black; */ } #rightcol { position: absolute; width:175px; margin-left: 775px; /* width:170px; */ /* width: auto;*/ /* border: 1px solid black; */ } #footer { width:100%; clear:both; float:left; text-align: right; font-size: .6em; /* border: 1px solid black; */ } div#yldiv { float:left; width:250px; display: none; } select { /* float: right; */ width: 100%; font-size: .9em; border: 1px solid grey; } div#formcontent { /*border: 1px solid black; */ } div#rightcol div.clearfix { /* border: 1px solid #CCC; */ margin-bottom: 10px; } div#rightcol form label { float: left; font-size: .9em; font-weight: bold; width:100% } div#content h1,h2,h3 { text-align: center } div#content p,ul { margin: 2% 20% 2% 20%; font-size: 1.2em; } div#content li { margin-bottom: 3%; } div#showpdf { margin-left: 20px; } div#copyright { color: grey; text-align: center; font-size: .8em; margin: 10% 20% 0px 20%; } div#bibliography { margin-top: 10px; font: .8em verdana, arial, sans-serif; font-weight: bold; } rapache-1.2.8/test/brew/useR2007.rhtml0000644000175100017510000000524712706745114016707 0ustar ondrejondrej<% setContentType('text/html') %> Brewing with Rapache: useR2007 example with Hmisc

Power and Sample Size Calculations with spower from Hmisc

The following example[1] demonstrates the flexibility of spower and related functions from Hmisc. We simulate a 2-arm (350 subjects/arm) 5-year follow-up study for wich the control group's survival distribution is Weibull with 1-year survival of .95 and 3-year survival of .7. All subjects are followed at least one year, and patients enter the study with linearly increasing probability starting with zero. Assume (1) there is no chance of dropin for the first 6 months, then the probability increases linearly up to .15 at 5 years; (2) there is a linearly increasing chance of dropout up to .3 at 5 years; and (3) the treatment has no effect for the first 9 months, then it has a constant effect (hazard ratio of .75).

[1] Alzola CF, Harrell FE: An Introduction to S and the Hmisc and Design Libraries . Freely available electronic book.
<% brew('test/brew/useR2007plot.rhtml') %>
Characteristics of control and intervention groups with a lag in the treatment effect and with non-compliance in two directions.
rapache-1.2.8/test/brew/useR2007ajax.rhtml0000644000175100017510000000140412706745114017542 0ustar ondrejondrej<% p1 <- ifelse(is.null(GET$p1),.95,as.numeric(GET$p1)) p2 <- ifelse(is.null(GET$p2),.7,as.numeric(GET$p2)) options(hverbose=FALSE,verbose=FALSE) library(Hmisc) library(Cairo) PLOTDIR='test/images' plotname <- paste('plot.',sprintf('%.4f.%.4f',p1,p2),'.png',sep='') filename <- file.path(PLOTDIR,plotname) if (!file.exists(filename)){ CairoPNG(filename=filename,width=600,height=600) sink('/dev/null') sc <- Weibull2(c(1,3),c(p1,p2)) rcens <- function(n) 1 + (5-1) * (runif(n) ^ .5) f <- Quantile2(sc, hratio=function(x) ifelse(x <= .75, 1, .75), dropin=function(x) ifelse(x <= .5, 0, .15 * (x-.5)/(5-.5)), dropout=function(x) .3*x/5 ) par(mfrow=c(2,2)) plot(f,'all',label.curves=list(keys='lines')) dev.off() sink() } %> rapache-1.2.8/test/brew/useR2007plot.rhtml0000644000175100017510000000147012706745114017600 0ustar ondrejondrej<% p1 <- ifelse(is.null(GET$p1),.95,as.numeric(GET$p1)) p2 <- ifelse(is.null(GET$p2),.7,as.numeric(GET$p2)) mo <- ifelse(is.null(GET$mo),9,as.numeric(GET$mo)) options(hverbose=FALSE,verbose=FALSE) library(Hmisc) PLOTDIR='test/images' plotname <- paste('plot.',sprintf('%.4f.%.4f.%d',p1,p2,mo),'.png',sep='') filename <- file.path(PLOTDIR,plotname) if (!file.exists(filename)){ png(type='cairo',filename=filename,width=600,height=600) sink('/dev/null') sc <- Weibull2(c(1,3),c(p1,p2)) rcens <- function(n) 1 + (5-1) * (runif(n) ^ .5) f <- Quantile2(sc, hratio=function(x) ifelse(x <= mo/12, 1, .75), dropin=function(x) ifelse(x <= .5, 0, .15 * (x-.5)/(5-.5)), dropout=function(x) .3*x/5 ) par(mfrow=c(2,2)) plot(f,'all',label.curves=list(keys='lines')) dev.off() sink() } %> rapache-1.2.8/test/brew/useR2007sim.rhtml0000644000175100017510000000124312706745114017410 0ustar ondrejondrej<% p1 <- ifelse(is.null(GET$p1),.95,as.numeric(GET$p1)) p2 <- ifelse(is.null(GET$p2),.7,as.numeric(GET$p2)) mo <- ifelse(is.null(GET$mo),9,as.numeric(GET$mo)) options(hverbose=FALSE,verbose=FALSE) library(Hmisc) sink('/dev/null') sc <- Weibull2(c(1,3),c(p1,p2)) f <- Quantile2(sc, hratio=function(x) ifelse(x <= mo/12, 1, .75), dropin=function(x) ifelse(x <= .5, 0, .15 * (x-.5)/(5-.5)), dropout=function(x) .3*x/5 ) rcens <- function(n) 1 + (5-1) * (runif(n) ^ .5) rcontrol <- function(n) f(n,'control') rinterv <- function(n) f(n,'intervention') set.seed(211) x <- spower(rcontrol,rinterv,rcens, nc=350, ni=350, test=logrank, nsim=300) sink() %> <%=format(x,digits=5)%> rapache-1.2.8/test/callwarning.R0000644000175100017510000000022012706745114016057 0ustar ondrejondrejcat('options()$warn is',getOption('warn'),'\n') for (i in 1:100) warning("warning! you have been warned!") cat('warnings:\n') print(warnings()) rapache-1.2.8/test/confs/0000755000175100017510000000000012706745114014551 5ustar ondrejondrejrapache-1.2.8/test/confs/local0000644000175100017510000000004112706745114015561 0ustar ondrejondrej# Place local conf snippets here rapache-1.2.8/test/dynlex.r0000644000175100017510000000205312706745114015127 0ustar ondrejondrejdynlex <- function() { setContentType("text/html") listEnclosures <- function(env=NULL){ empty <- environmentName(emptyenv()) if (!is.null(env)) e <- env else e <- parent.frame(); n <- environmentName(e); i <- 0 while (n != empty){ if (n == '') n <- attributes(e)$name[1] cat('ENV:',i,n,'------------------------------\n'); vars <- ls(envir=e) if (length(vars) > 10) cat('\t',vars[1:10],'....\n') else cat('\t',vars,'\n') e <- parent.env(e) n <- environmentName(e) i <- i + 1 } } listFrames <- function(){ f <- sys.frames(); len <- length(f) - 1 ; if (len < 1) return(invisible()); cat("in listFrames\n") for ( i in len:1 ){ cat('FRAME:',len-i,'----------------\n') vars <- ls(envir=f[[i]]) if (length(vars) > 10) cat('\t',vars[1:10],'....\n') else cat('\t',vars,'\n') } } cat("

Call Stack

")
	listFrames()
	cat("

Enclosures

")
	listEnclosures(sys.frame(sys.nframe()))
	cat("
") cat("returning",OK," ") OK } rapache-1.2.8/test/dynlex2.r0000644000175100017510000000177012706745114015216 0ustar ondrejondrejsetContentType("text/html") listEnclosures <- function(env=NULL){ empty <- environmentName(emptyenv()) if (!is.null(env)) e <- env else e <- parent.frame(); n <- environmentName(e); i <- 0 while (n != empty){ if (n == '') n <- attributes(e)$name[1] cat('ENV:',i,n,'------------------------------\n'); vars <- ls(envir=e) if (length(vars) > 10) cat('\t',vars[1:10],'....\n') else cat('\t',vars,'\n') e <- parent.env(e) n <- environmentName(e) i <- i + 1 } } listFrames <- function(){ f <- sys.frames(); len <- length(f) - 1 ; if (len < 1) return(invisible()); cat("in listFrames\n") for ( i in len:1 ){ cat('FRAME:',len-i,'----------------\n') vars <- ls(envir=f[[i]]) if (length(vars) > 10) cat('\t',vars[1:10],'....\n') else cat('\t',vars,'\n') } } cat("

Call Stack

")
listFrames()
cat("

Enclosures

")
listEnclosures()
cat("
") cat("did we change it?",DONE,"
") cat("returning",OK," ") OK rapache-1.2.8/test/failale.R0000644000175100017510000000015412706745114015161 0ustar ondrejondrejhandler <- function() { setContentType("text/plain") setStatus(400L) cat("Hi, I'm Ale!\n") OK } rapache-1.2.8/test/favicon.ico0000644000175100017510000000217612706745114015570 0ustar ondrejondrej h(   %g³³µµµµµµµ´ÿo+ÿÿÿÿÿÿÿÿÿäÿ̇ ÉõÿùÞÝÝÝà?½óûÿp™ÿ¦küÿé?ÿÿ "tosL†ýÿ{]ìÿ§Vßÿÿ>Ùÿä6ëÿÁ &ÿƒrÿÿs ÿÿO^" úÿâóÿÚ¨ÿÿ@aÿÿ„Çÿ¯ ÊÿùŒ\Þâ3Vüÿÿÿÿß Æÿó¸Ä­)EÿÿJAÿÿ€€€!ñŸãŒcÆgÇÇãñðŸøøüÿýÿrapache-1.2.8/test/helloworld.r0000644000175100017510000000112012706745114015771 0ustar ondrejondrejsetContentType("text/html") setHeader("foo","bar") setCookie("foo","bar",Sys.time()+1000) cat("

Hello World!

") cat("
")
print(warnings())
cat("search:\n")
print(search())

cat("\n.GlobalEnv:\n")
print(ls(globalenv()))

assign("gfoo","gbar",.GlobalEnv)
if (exists("foo")){
	foo <- foo + 1
} else {
	foo <- 1
}
cat("foo is",foo,"\n
"); cat("\nls():\n") print(ls()) if (!is.null(GET)){ for (i in 1:length(GET) ){ cat("\t",names(GET)[i],":",GET[[i]],"\n") # cat("\t",GET[[i]],"\n") } } else { cat("\nGET is NULL.\n") } cat("
") cat("") DONE rapache-1.2.8/test/httpd.conf.in0000644000175100017510000001460512706745114016046 0ustar ondrejondrej# this file is used to created httpd.conf via tools/config_http.R, not via autotools ServerRoot "@DOCROOT@" PidFile httpd.pid # # Timeout: The number of seconds before receives and sends time out. # Timeout 300 # # KeepAlive: Whether or not to allow persistent connections (more than # one request per connection). Set to "Off" to deactivate. # KeepAlive On # # MaxKeepAliveRequests: The maximum number of requests to allow # during a persistent connection. Set to 0 to allow an unlimited amount. # We recommend you leave this number high, for maximum performance. # MaxKeepAliveRequests 100 # # KeepAliveTimeout: Number of seconds to wait for the next request from the # same client on the same connection. # KeepAliveTimeout 15 ## ## Server-Pool Size Regulation (MPM specific) ## # prefork MPM # StartServers: number of server processes to start # MinSpareServers: minimum number of server processes which are kept spare # MaxSpareServers: maximum number of server processes which are kept spare # MaxClients: maximum number of server processes allowed to start # MaxRequestsPerChild: maximum number of requests a server process serves StartServers 5 MinSpareServers 5 MaxSpareServers 10 MaxClients 2 MaxRequestsPerChild 0 AcceptMutex flock LockFile accept.lock # worker MPM # StartServers: initial number of server processes to start # MaxClients: maximum number of simultaneous client connections # MinSpareThreads: minimum number of worker threads which are kept spare # MaxSpareThreads: maximum number of worker threads which are kept spare # ThreadsPerChild: constant number of worker threads in each server process # MaxRequestsPerChild: maximum number of requests a server process serves StartServers 2 MaxClients 10 MinSpareThreads 2 MaxSpareThreads 2 ThreadsPerChild 2 MaxRequestsPerChild 0 # # Listen: Allows you to bind Apache to specific IP addresses and/or # ports, instead of the default. See also the # directive. # # Change this to Listen on specific IP addresses as shown below to # prevent Apache from glomming onto all bound IP addresses (0.0.0.0) # #Listen 12.34.56.78:80 Listen @PORT@ LoadModule R_module ../.libs/mod_R.so Include confs/* DocumentRoot "@DOCROOT@" DirectoryIndex index.html Options FollowSymLinks AllowOverride None # Order allow,deny # Allow from all SetHandler r-info SetHandler r-handler RFileHandler @DOCROOT@/helloworld.r SetHandler r-handler RFileHandler @DOCROOT@/sendBin.r SetHandler r-handler RFileHandler @DOCROOT@/recBin.r SetHandler r-handler RFileHandler @DOCROOT@/relocation.R::handler SetHandler r-handler RFileHandler @DOCROOT@/failale.R::handler # # SetHandler r-script # RHandler brew::brew # REvalOnStartup "my.source <- function(file,env) with(data=env,source(file))" SetHandler r-script RHandler my.source # # SetHandler r-handler # RFileEval "@DOCROOT@/RookTest.R:Rook::Server$call(app)" # SetHandler r-handler RFileHandler @DOCROOT@/test.R # # # SetHandler r-handler # RHandler handler @DOCROOT@/plot.R TRUE # #DirectoryIndex index.html #DefaultType text/html HostnameLookups Off ErrorLog error_log LogLevel debug # # The following directives define some format nicknames for use with # a CustomLog directive (see below). # LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\"" combined LogFormat "%h %l %u %t \"%r\" %>s %b" common LogFormat "%{Referer}i -> %U" referer LogFormat "%{User-agent}i" agent CustomLog access_log common ServerTokens Full ServerSignature On TypesConfig mime.types AddLanguage ca .ca AddLanguage cs .cz .cs AddLanguage da .dk AddLanguage de .de AddLanguage el .el AddLanguage en .en AddLanguage eo .eo AddLanguage es .es AddLanguage et .et AddLanguage fr .fr AddLanguage he .he AddLanguage hr .hr AddLanguage it .it AddLanguage ja .ja AddLanguage ko .ko AddLanguage ltz .ltz AddLanguage nl .nl AddLanguage nn .nn AddLanguage no .no AddLanguage pl .po AddLanguage pt .pt AddLanguage pt-BR .pt-br AddLanguage ru .ru AddLanguage sv .sv AddLanguage zh-CN .zh-cn AddLanguage zh-TW .zh-tw LanguagePriority en ca cs da de el eo es et fr he hr it ja ko ltz nl nn no pl pt pt-BR ru sv zh-CN zh-TW # ForceLanguagePriority Prefer Fallback AddDefaultCharset ISO-8859-1 AddCharset ISO-8859-1 .iso8859-1 .latin1 AddCharset ISO-8859-2 .iso8859-2 .latin2 .cen AddCharset ISO-8859-3 .iso8859-3 .latin3 AddCharset ISO-8859-4 .iso8859-4 .latin4 AddCharset ISO-8859-5 .iso8859-5 .latin5 .cyr .iso-ru AddCharset ISO-8859-6 .iso8859-6 .latin6 .arb AddCharset ISO-8859-7 .iso8859-7 .latin7 .grk AddCharset ISO-8859-8 .iso8859-8 .latin8 .heb AddCharset ISO-8859-9 .iso8859-9 .latin9 .trk AddCharset ISO-2022-JP .iso2022-jp .jis AddCharset ISO-2022-KR .iso2022-kr .kis AddCharset ISO-2022-CN .iso2022-cn .cis AddCharset Big5 .Big5 .big5 # For russian, more than one charset is used (depends on client, mostly): AddCharset WINDOWS-1251 .cp-1251 .win-1251 AddCharset CP866 .cp866 AddCharset KOI8-r .koi8-r .koi8-ru AddCharset KOI8-ru .koi8-uk .ua AddCharset ISO-10646-UCS-2 .ucs2 AddCharset ISO-10646-UCS-4 .ucs4 AddCharset UTF-8 .utf8 # The set below does not map to a specific (iso) standard # but works on a fairly wide range of browsers. Note that # capitalization actually matters (it should not, but it # does for some browsers). # # See http://www.iana.org/assignments/character-sets # for a list of sorts. But browsers support few. # AddCharset GB2312 .gb2312 .gb AddCharset utf-7 .utf7 AddCharset utf-8 .utf8 AddCharset big5 .big5 .b5 AddCharset EUC-TW .euc-tw AddCharset EUC-JP .euc-jp AddCharset EUC-KR .euc-kr AddCharset shift_jis .sjis rapache-1.2.8/test/index.html0000644000175100017510000000105112706745114015433 0ustar ondrejondrej

RApache Test page

Click on the following to test things out. rapache-1.2.8/test/mime.types0000644000175100017510000000004612706745114015456 0ustar ondrejondrejtext/html html htm shtml text/css css rapache-1.2.8/test/prototype.js0000644000175100017510000027406712706745114016064 0ustar ondrejondrej/* Prototype JavaScript framework, version 1.5.1.1 * (c) 2005-2007 Sam Stephenson * * Prototype is freely distributable under the terms of an MIT-style license. * For details, see the Prototype web site: http://www.prototypejs.org/ * /*--------------------------------------------------------------------------*/ var Prototype = { Version: '1.5.1.1', Browser: { IE: !!(window.attachEvent && !window.opera), Opera: !!window.opera, WebKit: navigator.userAgent.indexOf('AppleWebKit/') > -1, Gecko: navigator.userAgent.indexOf('Gecko') > -1 && navigator.userAgent.indexOf('KHTML') == -1 }, BrowserFeatures: { XPath: !!document.evaluate, ElementExtensions: !!window.HTMLElement, SpecificElementExtensions: (document.createElement('div').__proto__ !== document.createElement('form').__proto__) }, ScriptFragment: ']*>([\\S\\s]*?)<\/script>', JSONFilter: /^\/\*-secure-([\s\S]*)\*\/\s*$/, emptyFunction: function() { }, K: function(x) { return x } } var Class = { create: function() { return function() { this.initialize.apply(this, arguments); } } } var Abstract = new Object(); Object.extend = function(destination, source) { for (var property in source) { destination[property] = source[property]; } return destination; } Object.extend(Object, { inspect: function(object) { try { if (object === undefined) return 'undefined'; if (object === null) return 'null'; return object.inspect ? object.inspect() : object.toString(); } catch (e) { if (e instanceof RangeError) return '...'; throw e; } }, toJSON: function(object) { var type = typeof object; switch(type) { case 'undefined': case 'function': case 'unknown': return; case 'boolean': return object.toString(); } if (object === null) return 'null'; if (object.toJSON) return object.toJSON(); if (object.ownerDocument === document) return; var results = []; for (var property in object) { var value = Object.toJSON(object[property]); if (value !== undefined) results.push(property.toJSON() + ': ' + value); } return '{' + results.join(', ') + '}'; }, keys: function(object) { var keys = []; for (var property in object) keys.push(property); return keys; }, values: function(object) { var values = []; for (var property in object) values.push(object[property]); return values; }, clone: function(object) { return Object.extend({}, object); } }); Function.prototype.bind = function() { var __method = this, args = $A(arguments), object = args.shift(); return function() { return __method.apply(object, args.concat($A(arguments))); } } Function.prototype.bindAsEventListener = function(object) { var __method = this, args = $A(arguments), object = args.shift(); return function(event) { return __method.apply(object, [event || window.event].concat(args)); } } Object.extend(Number.prototype, { toColorPart: function() { return this.toPaddedString(2, 16); }, succ: function() { return this + 1; }, times: function(iterator) { $R(0, this, true).each(iterator); return this; }, toPaddedString: function(length, radix) { var string = this.toString(radix || 10); return '0'.times(length - string.length) + string; }, toJSON: function() { return isFinite(this) ? this.toString() : 'null'; } }); Date.prototype.toJSON = function() { return '"' + this.getFullYear() + '-' + (this.getMonth() + 1).toPaddedString(2) + '-' + this.getDate().toPaddedString(2) + 'T' + this.getHours().toPaddedString(2) + ':' + this.getMinutes().toPaddedString(2) + ':' + this.getSeconds().toPaddedString(2) + '"'; }; var Try = { these: function() { var returnValue; for (var i = 0, length = arguments.length; i < length; i++) { var lambda = arguments[i]; try { returnValue = lambda(); break; } catch (e) {} } return returnValue; } } /*--------------------------------------------------------------------------*/ var PeriodicalExecuter = Class.create(); PeriodicalExecuter.prototype = { initialize: function(callback, frequency) { this.callback = callback; this.frequency = frequency; this.currentlyExecuting = false; this.registerCallback(); }, registerCallback: function() { this.timer = setInterval(this.onTimerEvent.bind(this), this.frequency * 1000); }, stop: function() { if (!this.timer) return; clearInterval(this.timer); this.timer = null; }, onTimerEvent: function() { if (!this.currentlyExecuting) { try { this.currentlyExecuting = true; this.callback(this); } finally { this.currentlyExecuting = false; } } } } Object.extend(String, { interpret: function(value) { return value == null ? '' : String(value); }, specialChar: { '\b': '\\b', '\t': '\\t', '\n': '\\n', '\f': '\\f', '\r': '\\r', '\\': '\\\\' } }); Object.extend(String.prototype, { gsub: function(pattern, replacement) { var result = '', source = this, match; replacement = arguments.callee.prepareReplacement(replacement); while (source.length > 0) { if (match = source.match(pattern)) { result += source.slice(0, match.index); result += String.interpret(replacement(match)); source = source.slice(match.index + match[0].length); } else { result += source, source = ''; } } return result; }, sub: function(pattern, replacement, count) { replacement = this.gsub.prepareReplacement(replacement); count = count === undefined ? 1 : count; return this.gsub(pattern, function(match) { if (--count < 0) return match[0]; return replacement(match); }); }, scan: function(pattern, iterator) { this.gsub(pattern, iterator); return this; }, truncate: function(length, truncation) { length = length || 30; truncation = truncation === undefined ? '...' : truncation; return this.length > length ? this.slice(0, length - truncation.length) + truncation : this; }, strip: function() { return this.replace(/^\s+/, '').replace(/\s+$/, ''); }, stripTags: function() { return this.replace(/<\/?[^>]+>/gi, ''); }, stripScripts: function() { return this.replace(new RegExp(Prototype.ScriptFragment, 'img'), ''); }, extractScripts: function() { var matchAll = new RegExp(Prototype.ScriptFragment, 'img'); var matchOne = new RegExp(Prototype.ScriptFragment, 'im'); return (this.match(matchAll) || []).map(function(scriptTag) { return (scriptTag.match(matchOne) || ['', ''])[1]; }); }, evalScripts: function() { return this.extractScripts().map(function(script) { return eval(script) }); }, escapeHTML: function() { var self = arguments.callee; self.text.data = this; return self.div.innerHTML; }, unescapeHTML: function() { var div = document.createElement('div'); div.innerHTML = this.stripTags(); return div.childNodes[0] ? (div.childNodes.length > 1 ? $A(div.childNodes).inject('', function(memo, node) { return memo+node.nodeValue }) : div.childNodes[0].nodeValue) : ''; }, toQueryParams: function(separator) { var match = this.strip().match(/([^?#]*)(#.*)?$/); if (!match) return {}; return match[1].split(separator || '&').inject({}, function(hash, pair) { if ((pair = pair.split('='))[0]) { var key = decodeURIComponent(pair.shift()); var value = pair.length > 1 ? pair.join('=') : pair[0]; if (value != undefined) value = decodeURIComponent(value); if (key in hash) { if (hash[key].constructor != Array) hash[key] = [hash[key]]; hash[key].push(value); } else hash[key] = value; } return hash; }); }, toArray: function() { return this.split(''); }, succ: function() { return this.slice(0, this.length - 1) + String.fromCharCode(this.charCodeAt(this.length - 1) + 1); }, times: function(count) { var result = ''; for (var i = 0; i < count; i++) result += this; return result; }, camelize: function() { var parts = this.split('-'), len = parts.length; if (len == 1) return parts[0]; var camelized = this.charAt(0) == '-' ? parts[0].charAt(0).toUpperCase() + parts[0].substring(1) : parts[0]; for (var i = 1; i < len; i++) camelized += parts[i].charAt(0).toUpperCase() + parts[i].substring(1); return camelized; }, capitalize: function() { return this.charAt(0).toUpperCase() + this.substring(1).toLowerCase(); }, underscore: function() { return this.gsub(/::/, '/').gsub(/([A-Z]+)([A-Z][a-z])/,'#{1}_#{2}').gsub(/([a-z\d])([A-Z])/,'#{1}_#{2}').gsub(/-/,'_').toLowerCase(); }, dasherize: function() { return this.gsub(/_/,'-'); }, inspect: function(useDoubleQuotes) { var escapedString = this.gsub(/[\x00-\x1f\\]/, function(match) { var character = String.specialChar[match[0]]; return character ? character : '\\u00' + match[0].charCodeAt().toPaddedString(2, 16); }); if (useDoubleQuotes) return '"' + escapedString.replace(/"/g, '\\"') + '"'; return "'" + escapedString.replace(/'/g, '\\\'') + "'"; }, toJSON: function() { return this.inspect(true); }, unfilterJSON: function(filter) { return this.sub(filter || Prototype.JSONFilter, '#{1}'); }, isJSON: function() { var str = this.replace(/\\./g, '@').replace(/"[^"\\\n\r]*"/g, ''); return (/^[,:{}\[\]0-9.\-+Eaeflnr-u \n\r\t]*$/).test(str); }, evalJSON: function(sanitize) { var json = this.unfilterJSON(); try { if (!sanitize || json.isJSON()) return eval('(' + json + ')'); } catch (e) { } throw new SyntaxError('Badly formed JSON string: ' + this.inspect()); }, include: function(pattern) { return this.indexOf(pattern) > -1; }, startsWith: function(pattern) { return this.indexOf(pattern) === 0; }, endsWith: function(pattern) { var d = this.length - pattern.length; return d >= 0 && this.lastIndexOf(pattern) === d; }, empty: function() { return this == ''; }, blank: function() { return /^\s*$/.test(this); } }); if (Prototype.Browser.WebKit || Prototype.Browser.IE) Object.extend(String.prototype, { escapeHTML: function() { return this.replace(/&/g,'&').replace(//g,'>'); }, unescapeHTML: function() { return this.replace(/&/g,'&').replace(/</g,'<').replace(/>/g,'>'); } }); String.prototype.gsub.prepareReplacement = function(replacement) { if (typeof replacement == 'function') return replacement; var template = new Template(replacement); return function(match) { return template.evaluate(match) }; } String.prototype.parseQuery = String.prototype.toQueryParams; Object.extend(String.prototype.escapeHTML, { div: document.createElement('div'), text: document.createTextNode('') }); with (String.prototype.escapeHTML) div.appendChild(text); var Template = Class.create(); Template.Pattern = /(^|.|\r|\n)(#\{(.*?)\})/; Template.prototype = { initialize: function(template, pattern) { this.template = template.toString(); this.pattern = pattern || Template.Pattern; }, evaluate: function(object) { return this.template.gsub(this.pattern, function(match) { var before = match[1]; if (before == '\\') return match[2]; return before + String.interpret(object[match[3]]); }); } } var $break = {}, $continue = new Error('"throw $continue" is deprecated, use "return" instead'); var Enumerable = { each: function(iterator) { var index = 0; try { this._each(function(value) { iterator(value, index++); }); } catch (e) { if (e != $break) throw e; } return this; }, eachSlice: function(number, iterator) { var index = -number, slices = [], array = this.toArray(); while ((index += number) < array.length) slices.push(array.slice(index, index+number)); return slices.map(iterator); }, all: function(iterator) { var result = true; this.each(function(value, index) { result = result && !!(iterator || Prototype.K)(value, index); if (!result) throw $break; }); return result; }, any: function(iterator) { var result = false; this.each(function(value, index) { if (result = !!(iterator || Prototype.K)(value, index)) throw $break; }); return result; }, collect: function(iterator) { var results = []; this.each(function(value, index) { results.push((iterator || Prototype.K)(value, index)); }); return results; }, detect: function(iterator) { var result; this.each(function(value, index) { if (iterator(value, index)) { result = value; throw $break; } }); return result; }, findAll: function(iterator) { var results = []; this.each(function(value, index) { if (iterator(value, index)) results.push(value); }); return results; }, grep: function(pattern, iterator) { var results = []; this.each(function(value, index) { var stringValue = value.toString(); if (stringValue.match(pattern)) results.push((iterator || Prototype.K)(value, index)); }) return results; }, include: function(object) { var found = false; this.each(function(value) { if (value == object) { found = true; throw $break; } }); return found; }, inGroupsOf: function(number, fillWith) { fillWith = fillWith === undefined ? null : fillWith; return this.eachSlice(number, function(slice) { while(slice.length < number) slice.push(fillWith); return slice; }); }, inject: function(memo, iterator) { this.each(function(value, index) { memo = iterator(memo, value, index); }); return memo; }, invoke: function(method) { var args = $A(arguments).slice(1); return this.map(function(value) { return value[method].apply(value, args); }); }, max: function(iterator) { var result; this.each(function(value, index) { value = (iterator || Prototype.K)(value, index); if (result == undefined || value >= result) result = value; }); return result; }, min: function(iterator) { var result; this.each(function(value, index) { value = (iterator || Prototype.K)(value, index); if (result == undefined || value < result) result = value; }); return result; }, partition: function(iterator) { var trues = [], falses = []; this.each(function(value, index) { ((iterator || Prototype.K)(value, index) ? trues : falses).push(value); }); return [trues, falses]; }, pluck: function(property) { var results = []; this.each(function(value, index) { results.push(value[property]); }); return results; }, reject: function(iterator) { var results = []; this.each(function(value, index) { if (!iterator(value, index)) results.push(value); }); return results; }, sortBy: function(iterator) { return this.map(function(value, index) { return {value: value, criteria: iterator(value, index)}; }).sort(function(left, right) { var a = left.criteria, b = right.criteria; return a < b ? -1 : a > b ? 1 : 0; }).pluck('value'); }, toArray: function() { return this.map(); }, zip: function() { var iterator = Prototype.K, args = $A(arguments); if (typeof args.last() == 'function') iterator = args.pop(); var collections = [this].concat(args).map($A); return this.map(function(value, index) { return iterator(collections.pluck(index)); }); }, size: function() { return this.toArray().length; }, inspect: function() { return '#'; } } Object.extend(Enumerable, { map: Enumerable.collect, find: Enumerable.detect, select: Enumerable.findAll, member: Enumerable.include, entries: Enumerable.toArray }); var $A = Array.from = function(iterable) { if (!iterable) return []; if (iterable.toArray) { return iterable.toArray(); } else { var results = []; for (var i = 0, length = iterable.length; i < length; i++) results.push(iterable[i]); return results; } } if (Prototype.Browser.WebKit) { $A = Array.from = function(iterable) { if (!iterable) return []; if (!(typeof iterable == 'function' && iterable == '[object NodeList]') && iterable.toArray) { return iterable.toArray(); } else { var results = []; for (var i = 0, length = iterable.length; i < length; i++) results.push(iterable[i]); return results; } } } Object.extend(Array.prototype, Enumerable); if (!Array.prototype._reverse) Array.prototype._reverse = Array.prototype.reverse; Object.extend(Array.prototype, { _each: function(iterator) { for (var i = 0, length = this.length; i < length; i++) iterator(this[i]); }, clear: function() { this.length = 0; return this; }, first: function() { return this[0]; }, last: function() { return this[this.length - 1]; }, compact: function() { return this.select(function(value) { return value != null; }); }, flatten: function() { return this.inject([], function(array, value) { return array.concat(value && value.constructor == Array ? value.flatten() : [value]); }); }, without: function() { var values = $A(arguments); return this.select(function(value) { return !values.include(value); }); }, indexOf: function(object) { for (var i = 0, length = this.length; i < length; i++) if (this[i] == object) return i; return -1; }, reverse: function(inline) { return (inline !== false ? this : this.toArray())._reverse(); }, reduce: function() { return this.length > 1 ? this : this[0]; }, uniq: function(sorted) { return this.inject([], function(array, value, index) { if (0 == index || (sorted ? array.last() != value : !array.include(value))) array.push(value); return array; }); }, clone: function() { return [].concat(this); }, size: function() { return this.length; }, inspect: function() { return '[' + this.map(Object.inspect).join(', ') + ']'; }, toJSON: function() { var results = []; this.each(function(object) { var value = Object.toJSON(object); if (value !== undefined) results.push(value); }); return '[' + results.join(', ') + ']'; } }); Array.prototype.toArray = Array.prototype.clone; function $w(string) { string = string.strip(); return string ? string.split(/\s+/) : []; } if (Prototype.Browser.Opera){ Array.prototype.concat = function() { var array = []; for (var i = 0, length = this.length; i < length; i++) array.push(this[i]); for (var i = 0, length = arguments.length; i < length; i++) { if (arguments[i].constructor == Array) { for (var j = 0, arrayLength = arguments[i].length; j < arrayLength; j++) array.push(arguments[i][j]); } else { array.push(arguments[i]); } } return array; } } var Hash = function(object) { if (object instanceof Hash) this.merge(object); else Object.extend(this, object || {}); }; Object.extend(Hash, { toQueryString: function(obj) { var parts = []; parts.add = arguments.callee.addPair; this.prototype._each.call(obj, function(pair) { if (!pair.key) return; var value = pair.value; if (value && typeof value == 'object') { if (value.constructor == Array) value.each(function(value) { parts.add(pair.key, value); }); return; } parts.add(pair.key, value); }); return parts.join('&'); }, toJSON: function(object) { var results = []; this.prototype._each.call(object, function(pair) { var value = Object.toJSON(pair.value); if (value !== undefined) results.push(pair.key.toJSON() + ': ' + value); }); return '{' + results.join(', ') + '}'; } }); Hash.toQueryString.addPair = function(key, value, prefix) { key = encodeURIComponent(key); if (value === undefined) this.push(key); else this.push(key + '=' + (value == null ? '' : encodeURIComponent(value))); } Object.extend(Hash.prototype, Enumerable); Object.extend(Hash.prototype, { _each: function(iterator) { for (var key in this) { var value = this[key]; if (value && value == Hash.prototype[key]) continue; var pair = [key, value]; pair.key = key; pair.value = value; iterator(pair); } }, keys: function() { return this.pluck('key'); }, values: function() { return this.pluck('value'); }, merge: function(hash) { return $H(hash).inject(this, function(mergedHash, pair) { mergedHash[pair.key] = pair.value; return mergedHash; }); }, remove: function() { var result; for(var i = 0, length = arguments.length; i < length; i++) { var value = this[arguments[i]]; if (value !== undefined){ if (result === undefined) result = value; else { if (result.constructor != Array) result = [result]; result.push(value) } } delete this[arguments[i]]; } return result; }, toQueryString: function() { return Hash.toQueryString(this); }, inspect: function() { return '#'; }, toJSON: function() { return Hash.toJSON(this); } }); function $H(object) { if (object instanceof Hash) return object; return new Hash(object); }; // Safari iterates over shadowed properties if (function() { var i = 0, Test = function(value) { this.key = value }; Test.prototype.key = 'foo'; for (var property in new Test('bar')) i++; return i > 1; }()) Hash.prototype._each = function(iterator) { var cache = []; for (var key in this) { var value = this[key]; if ((value && value == Hash.prototype[key]) || cache.include(key)) continue; cache.push(key); var pair = [key, value]; pair.key = key; pair.value = value; iterator(pair); } }; ObjectRange = Class.create(); Object.extend(ObjectRange.prototype, Enumerable); Object.extend(ObjectRange.prototype, { initialize: function(start, end, exclusive) { this.start = start; this.end = end; this.exclusive = exclusive; }, _each: function(iterator) { var value = this.start; while (this.include(value)) { iterator(value); value = value.succ(); } }, include: function(value) { if (value < this.start) return false; if (this.exclusive) return value < this.end; return value <= this.end; } }); var $R = function(start, end, exclusive) { return new ObjectRange(start, end, exclusive); } var Ajax = { getTransport: function() { return Try.these( function() {return new XMLHttpRequest()}, function() {return new ActiveXObject('Msxml2.XMLHTTP')}, function() {return new ActiveXObject('Microsoft.XMLHTTP')} ) || false; }, activeRequestCount: 0 } Ajax.Responders = { responders: [], _each: function(iterator) { this.responders._each(iterator); }, register: function(responder) { if (!this.include(responder)) this.responders.push(responder); }, unregister: function(responder) { this.responders = this.responders.without(responder); }, dispatch: function(callback, request, transport, json) { this.each(function(responder) { if (typeof responder[callback] == 'function') { try { responder[callback].apply(responder, [request, transport, json]); } catch (e) {} } }); } }; Object.extend(Ajax.Responders, Enumerable); Ajax.Responders.register({ onCreate: function() { Ajax.activeRequestCount++; }, onComplete: function() { Ajax.activeRequestCount--; } }); Ajax.Base = function() {}; Ajax.Base.prototype = { setOptions: function(options) { this.options = { method: 'post', asynchronous: true, contentType: 'application/x-www-form-urlencoded', encoding: 'UTF-8', parameters: '' } Object.extend(this.options, options || {}); this.options.method = this.options.method.toLowerCase(); if (typeof this.options.parameters == 'string') this.options.parameters = this.options.parameters.toQueryParams(); } } Ajax.Request = Class.create(); Ajax.Request.Events = ['Uninitialized', 'Loading', 'Loaded', 'Interactive', 'Complete']; Ajax.Request.prototype = Object.extend(new Ajax.Base(), { _complete: false, initialize: function(url, options) { this.transport = Ajax.getTransport(); this.setOptions(options); this.request(url); }, request: function(url) { this.url = url; this.method = this.options.method; var params = Object.clone(this.options.parameters); if (!['get', 'post'].include(this.method)) { // simulate other verbs over post params['_method'] = this.method; this.method = 'post'; } this.parameters = params; if (params = Hash.toQueryString(params)) { // when GET, append parameters to URL if (this.method == 'get') this.url += (this.url.include('?') ? '&' : '?') + params; else if (/Konqueror|Safari|KHTML/.test(navigator.userAgent)) params += '&_='; } try { if (this.options.onCreate) this.options.onCreate(this.transport); Ajax.Responders.dispatch('onCreate', this, this.transport); this.transport.open(this.method.toUpperCase(), this.url, this.options.asynchronous); if (this.options.asynchronous) setTimeout(function() { this.respondToReadyState(1) }.bind(this), 10); this.transport.onreadystatechange = this.onStateChange.bind(this); this.setRequestHeaders(); this.body = this.method == 'post' ? (this.options.postBody || params) : null; this.transport.send(this.body); /* Force Firefox to handle ready state 4 for synchronous requests */ if (!this.options.asynchronous && this.transport.overrideMimeType) this.onStateChange(); } catch (e) { this.dispatchException(e); } }, onStateChange: function() { var readyState = this.transport.readyState; if (readyState > 1 && !((readyState == 4) && this._complete)) this.respondToReadyState(this.transport.readyState); }, setRequestHeaders: function() { var headers = { 'X-Requested-With': 'XMLHttpRequest', 'X-Prototype-Version': Prototype.Version, 'Accept': 'text/javascript, text/html, application/xml, text/xml, */*' }; if (this.method == 'post') { headers['Content-type'] = this.options.contentType + (this.options.encoding ? '; charset=' + this.options.encoding : ''); /* Force "Connection: close" for older Mozilla browsers to work * around a bug where XMLHttpRequest sends an incorrect * Content-length header. See Mozilla Bugzilla #246651. */ if (this.transport.overrideMimeType && (navigator.userAgent.match(/Gecko\/(\d{4})/) || [0,2005])[1] < 2005) headers['Connection'] = 'close'; } // user-defined headers if (typeof this.options.requestHeaders == 'object') { var extras = this.options.requestHeaders; if (typeof extras.push == 'function') for (var i = 0, length = extras.length; i < length; i += 2) headers[extras[i]] = extras[i+1]; else $H(extras).each(function(pair) { headers[pair.key] = pair.value }); } for (var name in headers) this.transport.setRequestHeader(name, headers[name]); }, success: function() { return !this.transport.status || (this.transport.status >= 200 && this.transport.status < 300); }, respondToReadyState: function(readyState) { var state = Ajax.Request.Events[readyState]; var transport = this.transport, json = this.evalJSON(); if (state == 'Complete') { try { this._complete = true; (this.options['on' + this.transport.status] || this.options['on' + (this.success() ? 'Success' : 'Failure')] || Prototype.emptyFunction)(transport, json); } catch (e) { this.dispatchException(e); } var contentType = this.getHeader('Content-type'); if (contentType && contentType.strip(). match(/^(text|application)\/(x-)?(java|ecma)script(;.*)?$/i)) this.evalResponse(); } try { (this.options['on' + state] || Prototype.emptyFunction)(transport, json); Ajax.Responders.dispatch('on' + state, this, transport, json); } catch (e) { this.dispatchException(e); } if (state == 'Complete') { // avoid memory leak in MSIE: clean up this.transport.onreadystatechange = Prototype.emptyFunction; } }, getHeader: function(name) { try { return this.transport.getResponseHeader(name); } catch (e) { return null } }, evalJSON: function() { try { var json = this.getHeader('X-JSON'); return json ? json.evalJSON() : null; } catch (e) { return null } }, evalResponse: function() { try { return eval((this.transport.responseText || '').unfilterJSON()); } catch (e) { this.dispatchException(e); } }, dispatchException: function(exception) { (this.options.onException || Prototype.emptyFunction)(this, exception); Ajax.Responders.dispatch('onException', this, exception); } }); Ajax.Updater = Class.create(); Object.extend(Object.extend(Ajax.Updater.prototype, Ajax.Request.prototype), { initialize: function(container, url, options) { this.container = { success: (container.success || container), failure: (container.failure || (container.success ? null : container)) } this.transport = Ajax.getTransport(); this.setOptions(options); var onComplete = this.options.onComplete || Prototype.emptyFunction; this.options.onComplete = (function(transport, param) { this.updateContent(); onComplete(transport, param); }).bind(this); this.request(url); }, updateContent: function() { var receiver = this.container[this.success() ? 'success' : 'failure']; var response = this.transport.responseText; if (!this.options.evalScripts) response = response.stripScripts(); if (receiver = $(receiver)) { if (this.options.insertion) new this.options.insertion(receiver, response); else receiver.update(response); } if (this.success()) { if (this.onComplete) setTimeout(this.onComplete.bind(this), 10); } } }); Ajax.PeriodicalUpdater = Class.create(); Ajax.PeriodicalUpdater.prototype = Object.extend(new Ajax.Base(), { initialize: function(container, url, options) { this.setOptions(options); this.onComplete = this.options.onComplete; this.frequency = (this.options.frequency || 2); this.decay = (this.options.decay || 1); this.updater = {}; this.container = container; this.url = url; this.start(); }, start: function() { this.options.onComplete = this.updateComplete.bind(this); this.onTimerEvent(); }, stop: function() { this.updater.options.onComplete = undefined; clearTimeout(this.timer); (this.onComplete || Prototype.emptyFunction).apply(this, arguments); }, updateComplete: function(request) { if (this.options.decay) { this.decay = (request.responseText == this.lastText ? this.decay * this.options.decay : 1); this.lastText = request.responseText; } this.timer = setTimeout(this.onTimerEvent.bind(this), this.decay * this.frequency * 1000); }, onTimerEvent: function() { this.updater = new Ajax.Updater(this.container, this.url, this.options); } }); function $(element) { if (arguments.length > 1) { for (var i = 0, elements = [], length = arguments.length; i < length; i++) elements.push($(arguments[i])); return elements; } if (typeof element == 'string') element = document.getElementById(element); return Element.extend(element); } if (Prototype.BrowserFeatures.XPath) { document._getElementsByXPath = function(expression, parentElement) { var results = []; var query = document.evaluate(expression, $(parentElement) || document, null, XPathResult.ORDERED_NODE_SNAPSHOT_TYPE, null); for (var i = 0, length = query.snapshotLength; i < length; i++) results.push(query.snapshotItem(i)); return results; }; document.getElementsByClassName = function(className, parentElement) { var q = ".//*[contains(concat(' ', @class, ' '), ' " + className + " ')]"; return document._getElementsByXPath(q, parentElement); } } else document.getElementsByClassName = function(className, parentElement) { var children = ($(parentElement) || document.body).getElementsByTagName('*'); var elements = [], child, pattern = new RegExp("(^|\\s)" + className + "(\\s|$)"); for (var i = 0, length = children.length; i < length; i++) { child = children[i]; var elementClassName = child.className; if (elementClassName.length == 0) continue; if (elementClassName == className || elementClassName.match(pattern)) elements.push(Element.extend(child)); } return elements; }; /*--------------------------------------------------------------------------*/ if (!window.Element) var Element = {}; Element.extend = function(element) { var F = Prototype.BrowserFeatures; if (!element || !element.tagName || element.nodeType == 3 || element._extended || F.SpecificElementExtensions || element == window) return element; var methods = {}, tagName = element.tagName, cache = Element.extend.cache, T = Element.Methods.ByTag; // extend methods for all tags (Safari doesn't need this) if (!F.ElementExtensions) { Object.extend(methods, Element.Methods), Object.extend(methods, Element.Methods.Simulated); } // extend methods for specific tags if (T[tagName]) Object.extend(methods, T[tagName]); for (var property in methods) { var value = methods[property]; if (typeof value == 'function' && !(property in element)) element[property] = cache.findOrStore(value); } element._extended = Prototype.emptyFunction; return element; }; Element.extend.cache = { findOrStore: function(value) { return this[value] = this[value] || function() { return value.apply(null, [this].concat($A(arguments))); } } }; Element.Methods = { visible: function(element) { return $(element).style.display != 'none'; }, toggle: function(element) { element = $(element); Element[Element.visible(element) ? 'hide' : 'show'](element); return element; }, hide: function(element) { $(element).style.display = 'none'; return element; }, show: function(element) { $(element).style.display = ''; return element; }, remove: function(element) { element = $(element); element.parentNode.removeChild(element); return element; }, update: function(element, html) { html = typeof html == 'undefined' ? '' : html.toString(); $(element).innerHTML = html.stripScripts(); setTimeout(function() {html.evalScripts()}, 10); return element; }, replace: function(element, html) { element = $(element); html = typeof html == 'undefined' ? '' : html.toString(); if (element.outerHTML) { element.outerHTML = html.stripScripts(); } else { var range = element.ownerDocument.createRange(); range.selectNodeContents(element); element.parentNode.replaceChild( range.createContextualFragment(html.stripScripts()), element); } setTimeout(function() {html.evalScripts()}, 10); return element; }, inspect: function(element) { element = $(element); var result = '<' + element.tagName.toLowerCase(); $H({'id': 'id', 'className': 'class'}).each(function(pair) { var property = pair.first(), attribute = pair.last(); var value = (element[property] || '').toString(); if (value) result += ' ' + attribute + '=' + value.inspect(true); }); return result + '>'; }, recursivelyCollect: function(element, property) { element = $(element); var elements = []; while (element = element[property]) if (element.nodeType == 1) elements.push(Element.extend(element)); return elements; }, ancestors: function(element) { return $(element).recursivelyCollect('parentNode'); }, descendants: function(element) { return $A($(element).getElementsByTagName('*')).each(Element.extend); }, firstDescendant: function(element) { element = $(element).firstChild; while (element && element.nodeType != 1) element = element.nextSibling; return $(element); }, immediateDescendants: function(element) { if (!(element = $(element).firstChild)) return []; while (element && element.nodeType != 1) element = element.nextSibling; if (element) return [element].concat($(element).nextSiblings()); return []; }, previousSiblings: function(element) { return $(element).recursivelyCollect('previousSibling'); }, nextSiblings: function(element) { return $(element).recursivelyCollect('nextSibling'); }, siblings: function(element) { element = $(element); return element.previousSiblings().reverse().concat(element.nextSiblings()); }, match: function(element, selector) { if (typeof selector == 'string') selector = new Selector(selector); return selector.match($(element)); }, up: function(element, expression, index) { element = $(element); if (arguments.length == 1) return $(element.parentNode); var ancestors = element.ancestors(); return expression ? Selector.findElement(ancestors, expression, index) : ancestors[index || 0]; }, down: function(element, expression, index) { element = $(element); if (arguments.length == 1) return element.firstDescendant(); var descendants = element.descendants(); return expression ? Selector.findElement(descendants, expression, index) : descendants[index || 0]; }, previous: function(element, expression, index) { element = $(element); if (arguments.length == 1) return $(Selector.handlers.previousElementSibling(element)); var previousSiblings = element.previousSiblings(); return expression ? Selector.findElement(previousSiblings, expression, index) : previousSiblings[index || 0]; }, next: function(element, expression, index) { element = $(element); if (arguments.length == 1) return $(Selector.handlers.nextElementSibling(element)); var nextSiblings = element.nextSiblings(); return expression ? Selector.findElement(nextSiblings, expression, index) : nextSiblings[index || 0]; }, getElementsBySelector: function() { var args = $A(arguments), element = $(args.shift()); return Selector.findChildElements(element, args); }, getElementsByClassName: function(element, className) { return document.getElementsByClassName(className, element); }, readAttribute: function(element, name) { element = $(element); if (Prototype.Browser.IE) { if (!element.attributes) return null; var t = Element._attributeTranslations; if (t.values[name]) return t.values[name](element, name); if (t.names[name]) name = t.names[name]; var attribute = element.attributes[name]; return attribute ? attribute.nodeValue : null; } return element.getAttribute(name); }, getHeight: function(element) { return $(element).getDimensions().height; }, getWidth: function(element) { return $(element).getDimensions().width; }, classNames: function(element) { return new Element.ClassNames(element); }, hasClassName: function(element, className) { if (!(element = $(element))) return; var elementClassName = element.className; if (elementClassName.length == 0) return false; if (elementClassName == className || elementClassName.match(new RegExp("(^|\\s)" + className + "(\\s|$)"))) return true; return false; }, addClassName: function(element, className) { if (!(element = $(element))) return; Element.classNames(element).add(className); return element; }, removeClassName: function(element, className) { if (!(element = $(element))) return; Element.classNames(element).remove(className); return element; }, toggleClassName: function(element, className) { if (!(element = $(element))) return; Element.classNames(element)[element.hasClassName(className) ? 'remove' : 'add'](className); return element; }, observe: function() { Event.observe.apply(Event, arguments); return $A(arguments).first(); }, stopObserving: function() { Event.stopObserving.apply(Event, arguments); return $A(arguments).first(); }, // removes whitespace-only text node children cleanWhitespace: function(element) { element = $(element); var node = element.firstChild; while (node) { var nextNode = node.nextSibling; if (node.nodeType == 3 && !/\S/.test(node.nodeValue)) element.removeChild(node); node = nextNode; } return element; }, empty: function(element) { return $(element).innerHTML.blank(); }, descendantOf: function(element, ancestor) { element = $(element), ancestor = $(ancestor); while (element = element.parentNode) if (element == ancestor) return true; return false; }, scrollTo: function(element) { element = $(element); var pos = Position.cumulativeOffset(element); window.scrollTo(pos[0], pos[1]); return element; }, getStyle: function(element, style) { element = $(element); style = style == 'float' ? 'cssFloat' : style.camelize(); var value = element.style[style]; if (!value) { var css = document.defaultView.getComputedStyle(element, null); value = css ? css[style] : null; } if (style == 'opacity') return value ? parseFloat(value) : 1.0; return value == 'auto' ? null : value; }, getOpacity: function(element) { return $(element).getStyle('opacity'); }, setStyle: function(element, styles, camelized) { element = $(element); var elementStyle = element.style; for (var property in styles) if (property == 'opacity') element.setOpacity(styles[property]) else elementStyle[(property == 'float' || property == 'cssFloat') ? (elementStyle.styleFloat === undefined ? 'cssFloat' : 'styleFloat') : (camelized ? property : property.camelize())] = styles[property]; return element; }, setOpacity: function(element, value) { element = $(element); element.style.opacity = (value == 1 || value === '') ? '' : (value < 0.00001) ? 0 : value; return element; }, getDimensions: function(element) { element = $(element); var display = $(element).getStyle('display'); if (display != 'none' && display != null) // Safari bug return {width: element.offsetWidth, height: element.offsetHeight}; // All *Width and *Height properties give 0 on elements with display none, // so enable the element temporarily var els = element.style; var originalVisibility = els.visibility; var originalPosition = els.position; var originalDisplay = els.display; els.visibility = 'hidden'; els.position = 'absolute'; els.display = 'block'; var originalWidth = element.clientWidth; var originalHeight = element.clientHeight; els.display = originalDisplay; els.position = originalPosition; els.visibility = originalVisibility; return {width: originalWidth, height: originalHeight}; }, makePositioned: function(element) { element = $(element); var pos = Element.getStyle(element, 'position'); if (pos == 'static' || !pos) { element._madePositioned = true; element.style.position = 'relative'; // Opera returns the offset relative to the positioning context, when an // element is position relative but top and left have not been defined if (window.opera) { element.style.top = 0; element.style.left = 0; } } return element; }, undoPositioned: function(element) { element = $(element); if (element._madePositioned) { element._madePositioned = undefined; element.style.position = element.style.top = element.style.left = element.style.bottom = element.style.right = ''; } return element; }, makeClipping: function(element) { element = $(element); if (element._overflow) return element; element._overflow = element.style.overflow || 'auto'; if ((Element.getStyle(element, 'overflow') || 'visible') != 'hidden') element.style.overflow = 'hidden'; return element; }, undoClipping: function(element) { element = $(element); if (!element._overflow) return element; element.style.overflow = element._overflow == 'auto' ? '' : element._overflow; element._overflow = null; return element; } }; Object.extend(Element.Methods, { childOf: Element.Methods.descendantOf, childElements: Element.Methods.immediateDescendants }); if (Prototype.Browser.Opera) { Element.Methods._getStyle = Element.Methods.getStyle; Element.Methods.getStyle = function(element, style) { switch(style) { case 'left': case 'top': case 'right': case 'bottom': if (Element._getStyle(element, 'position') == 'static') return null; default: return Element._getStyle(element, style); } }; } else if (Prototype.Browser.IE) { Element.Methods.getStyle = function(element, style) { element = $(element); style = (style == 'float' || style == 'cssFloat') ? 'styleFloat' : style.camelize(); var value = element.style[style]; if (!value && element.currentStyle) value = element.currentStyle[style]; if (style == 'opacity') { if (value = (element.getStyle('filter') || '').match(/alpha\(opacity=(.*)\)/)) if (value[1]) return parseFloat(value[1]) / 100; return 1.0; } if (value == 'auto') { if ((style == 'width' || style == 'height') && (element.getStyle('display') != 'none')) return element['offset'+style.capitalize()] + 'px'; return null; } return value; }; Element.Methods.setOpacity = function(element, value) { element = $(element); var filter = element.getStyle('filter'), style = element.style; if (value == 1 || value === '') { style.filter = filter.replace(/alpha\([^\)]*\)/gi,''); return element; } else if (value < 0.00001) value = 0; style.filter = filter.replace(/alpha\([^\)]*\)/gi, '') + 'alpha(opacity=' + (value * 100) + ')'; return element; }; // IE is missing .innerHTML support for TABLE-related elements Element.Methods.update = function(element, html) { element = $(element); html = typeof html == 'undefined' ? '' : html.toString(); var tagName = element.tagName.toUpperCase(); if (['THEAD','TBODY','TR','TD'].include(tagName)) { var div = document.createElement('div'); switch (tagName) { case 'THEAD': case 'TBODY': div.innerHTML = '' + html.stripScripts() + '
'; depth = 2; break; case 'TR': div.innerHTML = '' + html.stripScripts() + '
'; depth = 3; break; case 'TD': div.innerHTML = '
' + html.stripScripts() + '
'; depth = 4; } $A(element.childNodes).each(function(node) { element.removeChild(node) }); depth.times(function() { div = div.firstChild }); $A(div.childNodes).each(function(node) { element.appendChild(node) }); } else { element.innerHTML = html.stripScripts(); } setTimeout(function() { html.evalScripts() }, 10); return element; } } else if (Prototype.Browser.Gecko) { Element.Methods.setOpacity = function(element, value) { element = $(element); element.style.opacity = (value == 1) ? 0.999999 : (value === '') ? '' : (value < 0.00001) ? 0 : value; return element; }; } Element._attributeTranslations = { names: { colspan: "colSpan", rowspan: "rowSpan", valign: "vAlign", datetime: "dateTime", accesskey: "accessKey", tabindex: "tabIndex", enctype: "encType", maxlength: "maxLength", readonly: "readOnly", longdesc: "longDesc" }, values: { _getAttr: function(element, attribute) { return element.getAttribute(attribute, 2); }, _flag: function(element, attribute) { return $(element).hasAttribute(attribute) ? attribute : null; }, style: function(element) { return element.style.cssText.toLowerCase(); }, title: function(element) { var node = element.getAttributeNode('title'); return node.specified ? node.nodeValue : null; } } }; (function() { Object.extend(this, { href: this._getAttr, src: this._getAttr, type: this._getAttr, disabled: this._flag, checked: this._flag, readonly: this._flag, multiple: this._flag }); }).call(Element._attributeTranslations.values); Element.Methods.Simulated = { hasAttribute: function(element, attribute) { var t = Element._attributeTranslations, node; attribute = t.names[attribute] || attribute; node = $(element).getAttributeNode(attribute); return node && node.specified; } }; Element.Methods.ByTag = {}; Object.extend(Element, Element.Methods); if (!Prototype.BrowserFeatures.ElementExtensions && document.createElement('div').__proto__) { window.HTMLElement = {}; window.HTMLElement.prototype = document.createElement('div').__proto__; Prototype.BrowserFeatures.ElementExtensions = true; } Element.hasAttribute = function(element, attribute) { if (element.hasAttribute) return element.hasAttribute(attribute); return Element.Methods.Simulated.hasAttribute(element, attribute); }; Element.addMethods = function(methods) { var F = Prototype.BrowserFeatures, T = Element.Methods.ByTag; if (!methods) { Object.extend(Form, Form.Methods); Object.extend(Form.Element, Form.Element.Methods); Object.extend(Element.Methods.ByTag, { "FORM": Object.clone(Form.Methods), "INPUT": Object.clone(Form.Element.Methods), "SELECT": Object.clone(Form.Element.Methods), "TEXTAREA": Object.clone(Form.Element.Methods) }); } if (arguments.length == 2) { var tagName = methods; methods = arguments[1]; } if (!tagName) Object.extend(Element.Methods, methods || {}); else { if (tagName.constructor == Array) tagName.each(extend); else extend(tagName); } function extend(tagName) { tagName = tagName.toUpperCase(); if (!Element.Methods.ByTag[tagName]) Element.Methods.ByTag[tagName] = {}; Object.extend(Element.Methods.ByTag[tagName], methods); } function copy(methods, destination, onlyIfAbsent) { onlyIfAbsent = onlyIfAbsent || false; var cache = Element.extend.cache; for (var property in methods) { var value = methods[property]; if (!onlyIfAbsent || !(property in destination)) destination[property] = cache.findOrStore(value); } } function findDOMClass(tagName) { var klass; var trans = { "OPTGROUP": "OptGroup", "TEXTAREA": "TextArea", "P": "Paragraph", "FIELDSET": "FieldSet", "UL": "UList", "OL": "OList", "DL": "DList", "DIR": "Directory", "H1": "Heading", "H2": "Heading", "H3": "Heading", "H4": "Heading", "H5": "Heading", "H6": "Heading", "Q": "Quote", "INS": "Mod", "DEL": "Mod", "A": "Anchor", "IMG": "Image", "CAPTION": "TableCaption", "COL": "TableCol", "COLGROUP": "TableCol", "THEAD": "TableSection", "TFOOT": "TableSection", "TBODY": "TableSection", "TR": "TableRow", "TH": "TableCell", "TD": "TableCell", "FRAMESET": "FrameSet", "IFRAME": "IFrame" }; if (trans[tagName]) klass = 'HTML' + trans[tagName] + 'Element'; if (window[klass]) return window[klass]; klass = 'HTML' + tagName + 'Element'; if (window[klass]) return window[klass]; klass = 'HTML' + tagName.capitalize() + 'Element'; if (window[klass]) return window[klass]; window[klass] = {}; window[klass].prototype = document.createElement(tagName).__proto__; return window[klass]; } if (F.ElementExtensions) { copy(Element.Methods, HTMLElement.prototype); copy(Element.Methods.Simulated, HTMLElement.prototype, true); } if (F.SpecificElementExtensions) { for (var tag in Element.Methods.ByTag) { var klass = findDOMClass(tag); if (typeof klass == "undefined") continue; copy(T[tag], klass.prototype); } } Object.extend(Element, Element.Methods); delete Element.ByTag; }; var Toggle = { display: Element.toggle }; /*--------------------------------------------------------------------------*/ Abstract.Insertion = function(adjacency) { this.adjacency = adjacency; } Abstract.Insertion.prototype = { initialize: function(element, content) { this.element = $(element); this.content = content.stripScripts(); if (this.adjacency && this.element.insertAdjacentHTML) { try { this.element.insertAdjacentHTML(this.adjacency, this.content); } catch (e) { var tagName = this.element.tagName.toUpperCase(); if (['TBODY', 'TR'].include(tagName)) { this.insertContent(this.contentFromAnonymousTable()); } else { throw e; } } } else { this.range = this.element.ownerDocument.createRange(); if (this.initializeRange) this.initializeRange(); this.insertContent([this.range.createContextualFragment(this.content)]); } setTimeout(function() {content.evalScripts()}, 10); }, contentFromAnonymousTable: function() { var div = document.createElement('div'); div.innerHTML = '' + this.content + '
'; return $A(div.childNodes[0].childNodes[0].childNodes); } } var Insertion = new Object(); Insertion.Before = Class.create(); Insertion.Before.prototype = Object.extend(new Abstract.Insertion('beforeBegin'), { initializeRange: function() { this.range.setStartBefore(this.element); }, insertContent: function(fragments) { fragments.each((function(fragment) { this.element.parentNode.insertBefore(fragment, this.element); }).bind(this)); } }); Insertion.Top = Class.create(); Insertion.Top.prototype = Object.extend(new Abstract.Insertion('afterBegin'), { initializeRange: function() { this.range.selectNodeContents(this.element); this.range.collapse(true); }, insertContent: function(fragments) { fragments.reverse(false).each((function(fragment) { this.element.insertBefore(fragment, this.element.firstChild); }).bind(this)); } }); Insertion.Bottom = Class.create(); Insertion.Bottom.prototype = Object.extend(new Abstract.Insertion('beforeEnd'), { initializeRange: function() { this.range.selectNodeContents(this.element); this.range.collapse(this.element); }, insertContent: function(fragments) { fragments.each((function(fragment) { this.element.appendChild(fragment); }).bind(this)); } }); Insertion.After = Class.create(); Insertion.After.prototype = Object.extend(new Abstract.Insertion('afterEnd'), { initializeRange: function() { this.range.setStartAfter(this.element); }, insertContent: function(fragments) { fragments.each((function(fragment) { this.element.parentNode.insertBefore(fragment, this.element.nextSibling); }).bind(this)); } }); /*--------------------------------------------------------------------------*/ Element.ClassNames = Class.create(); Element.ClassNames.prototype = { initialize: function(element) { this.element = $(element); }, _each: function(iterator) { this.element.className.split(/\s+/).select(function(name) { return name.length > 0; })._each(iterator); }, set: function(className) { this.element.className = className; }, add: function(classNameToAdd) { if (this.include(classNameToAdd)) return; this.set($A(this).concat(classNameToAdd).join(' ')); }, remove: function(classNameToRemove) { if (!this.include(classNameToRemove)) return; this.set($A(this).without(classNameToRemove).join(' ')); }, toString: function() { return $A(this).join(' '); } }; Object.extend(Element.ClassNames.prototype, Enumerable); /* Portions of the Selector class are derived from Jack Slocum’s DomQuery, * part of YUI-Ext version 0.40, distributed under the terms of an MIT-style * license. Please see http://www.yui-ext.com/ for more information. */ var Selector = Class.create(); Selector.prototype = { initialize: function(expression) { this.expression = expression.strip(); this.compileMatcher(); }, compileMatcher: function() { // Selectors with namespaced attributes can't use the XPath version if (Prototype.BrowserFeatures.XPath && !(/\[[\w-]*?:/).test(this.expression)) return this.compileXPathMatcher(); var e = this.expression, ps = Selector.patterns, h = Selector.handlers, c = Selector.criteria, le, p, m; if (Selector._cache[e]) { this.matcher = Selector._cache[e]; return; } this.matcher = ["this.matcher = function(root) {", "var r = root, h = Selector.handlers, c = false, n;"]; while (e && le != e && (/\S/).test(e)) { le = e; for (var i in ps) { p = ps[i]; if (m = e.match(p)) { this.matcher.push(typeof c[i] == 'function' ? c[i](m) : new Template(c[i]).evaluate(m)); e = e.replace(m[0], ''); break; } } } this.matcher.push("return h.unique(n);\n}"); eval(this.matcher.join('\n')); Selector._cache[this.expression] = this.matcher; }, compileXPathMatcher: function() { var e = this.expression, ps = Selector.patterns, x = Selector.xpath, le, m; if (Selector._cache[e]) { this.xpath = Selector._cache[e]; return; } this.matcher = ['.//*']; while (e && le != e && (/\S/).test(e)) { le = e; for (var i in ps) { if (m = e.match(ps[i])) { this.matcher.push(typeof x[i] == 'function' ? x[i](m) : new Template(x[i]).evaluate(m)); e = e.replace(m[0], ''); break; } } } this.xpath = this.matcher.join(''); Selector._cache[this.expression] = this.xpath; }, findElements: function(root) { root = root || document; if (this.xpath) return document._getElementsByXPath(this.xpath, root); return this.matcher(root); }, match: function(element) { return this.findElements(document).include(element); }, toString: function() { return this.expression; }, inspect: function() { return "#"; } }; Object.extend(Selector, { _cache: {}, xpath: { descendant: "//*", child: "/*", adjacent: "/following-sibling::*[1]", laterSibling: '/following-sibling::*', tagName: function(m) { if (m[1] == '*') return ''; return "[local-name()='" + m[1].toLowerCase() + "' or local-name()='" + m[1].toUpperCase() + "']"; }, className: "[contains(concat(' ', @class, ' '), ' #{1} ')]", id: "[@id='#{1}']", attrPresence: "[@#{1}]", attr: function(m) { m[3] = m[5] || m[6]; return new Template(Selector.xpath.operators[m[2]]).evaluate(m); }, pseudo: function(m) { var h = Selector.xpath.pseudos[m[1]]; if (!h) return ''; if (typeof h === 'function') return h(m); return new Template(Selector.xpath.pseudos[m[1]]).evaluate(m); }, operators: { '=': "[@#{1}='#{3}']", '!=': "[@#{1}!='#{3}']", '^=': "[starts-with(@#{1}, '#{3}')]", '$=': "[substring(@#{1}, (string-length(@#{1}) - string-length('#{3}') + 1))='#{3}']", '*=': "[contains(@#{1}, '#{3}')]", '~=': "[contains(concat(' ', @#{1}, ' '), ' #{3} ')]", '|=': "[contains(concat('-', @#{1}, '-'), '-#{3}-')]" }, pseudos: { 'first-child': '[not(preceding-sibling::*)]', 'last-child': '[not(following-sibling::*)]', 'only-child': '[not(preceding-sibling::* or following-sibling::*)]', 'empty': "[count(*) = 0 and (count(text()) = 0 or translate(text(), ' \t\r\n', '') = '')]", 'checked': "[@checked]", 'disabled': "[@disabled]", 'enabled': "[not(@disabled)]", 'not': function(m) { var e = m[6], p = Selector.patterns, x = Selector.xpath, le, m, v; var exclusion = []; while (e && le != e && (/\S/).test(e)) { le = e; for (var i in p) { if (m = e.match(p[i])) { v = typeof x[i] == 'function' ? x[i](m) : new Template(x[i]).evaluate(m); exclusion.push("(" + v.substring(1, v.length - 1) + ")"); e = e.replace(m[0], ''); break; } } } return "[not(" + exclusion.join(" and ") + ")]"; }, 'nth-child': function(m) { return Selector.xpath.pseudos.nth("(count(./preceding-sibling::*) + 1) ", m); }, 'nth-last-child': function(m) { return Selector.xpath.pseudos.nth("(count(./following-sibling::*) + 1) ", m); }, 'nth-of-type': function(m) { return Selector.xpath.pseudos.nth("position() ", m); }, 'nth-last-of-type': function(m) { return Selector.xpath.pseudos.nth("(last() + 1 - position()) ", m); }, 'first-of-type': function(m) { m[6] = "1"; return Selector.xpath.pseudos['nth-of-type'](m); }, 'last-of-type': function(m) { m[6] = "1"; return Selector.xpath.pseudos['nth-last-of-type'](m); }, 'only-of-type': function(m) { var p = Selector.xpath.pseudos; return p['first-of-type'](m) + p['last-of-type'](m); }, nth: function(fragment, m) { var mm, formula = m[6], predicate; if (formula == 'even') formula = '2n+0'; if (formula == 'odd') formula = '2n+1'; if (mm = formula.match(/^(\d+)$/)) // digit only return '[' + fragment + "= " + mm[1] + ']'; if (mm = formula.match(/^(-?\d*)?n(([+-])(\d+))?/)) { // an+b if (mm[1] == "-") mm[1] = -1; var a = mm[1] ? Number(mm[1]) : 1; var b = mm[2] ? Number(mm[2]) : 0; predicate = "[((#{fragment} - #{b}) mod #{a} = 0) and " + "((#{fragment} - #{b}) div #{a} >= 0)]"; return new Template(predicate).evaluate({ fragment: fragment, a: a, b: b }); } } } }, criteria: { tagName: 'n = h.tagName(n, r, "#{1}", c); c = false;', className: 'n = h.className(n, r, "#{1}", c); c = false;', id: 'n = h.id(n, r, "#{1}", c); c = false;', attrPresence: 'n = h.attrPresence(n, r, "#{1}"); c = false;', attr: function(m) { m[3] = (m[5] || m[6]); return new Template('n = h.attr(n, r, "#{1}", "#{3}", "#{2}"); c = false;').evaluate(m); }, pseudo: function(m) { if (m[6]) m[6] = m[6].replace(/"/g, '\\"'); return new Template('n = h.pseudo(n, "#{1}", "#{6}", r, c); c = false;').evaluate(m); }, descendant: 'c = "descendant";', child: 'c = "child";', adjacent: 'c = "adjacent";', laterSibling: 'c = "laterSibling";' }, patterns: { // combinators must be listed first // (and descendant needs to be last combinator) laterSibling: /^\s*~\s*/, child: /^\s*>\s*/, adjacent: /^\s*\+\s*/, descendant: /^\s/, // selectors follow tagName: /^\s*(\*|[\w\-]+)(\b|$)?/, id: /^#([\w\-\*]+)(\b|$)/, className: /^\.([\w\-\*]+)(\b|$)/, pseudo: /^:((first|last|nth|nth-last|only)(-child|-of-type)|empty|checked|(en|dis)abled|not)(\((.*?)\))?(\b|$|\s|(?=:))/, attrPresence: /^\[([\w]+)\]/, attr: /\[((?:[\w-]*:)?[\w-]+)\s*(?:([!^$*~|]?=)\s*((['"])([^\]]*?)\4|([^'"][^\]]*?)))?\]/ }, handlers: { // UTILITY FUNCTIONS // joins two collections concat: function(a, b) { for (var i = 0, node; node = b[i]; i++) a.push(node); return a; }, // marks an array of nodes for counting mark: function(nodes) { for (var i = 0, node; node = nodes[i]; i++) node._counted = true; return nodes; }, unmark: function(nodes) { for (var i = 0, node; node = nodes[i]; i++) node._counted = undefined; return nodes; }, // mark each child node with its position (for nth calls) // "ofType" flag indicates whether we're indexing for nth-of-type // rather than nth-child index: function(parentNode, reverse, ofType) { parentNode._counted = true; if (reverse) { for (var nodes = parentNode.childNodes, i = nodes.length - 1, j = 1; i >= 0; i--) { node = nodes[i]; if (node.nodeType == 1 && (!ofType || node._counted)) node.nodeIndex = j++; } } else { for (var i = 0, j = 1, nodes = parentNode.childNodes; node = nodes[i]; i++) if (node.nodeType == 1 && (!ofType || node._counted)) node.nodeIndex = j++; } }, // filters out duplicates and extends all nodes unique: function(nodes) { if (nodes.length == 0) return nodes; var results = [], n; for (var i = 0, l = nodes.length; i < l; i++) if (!(n = nodes[i])._counted) { n._counted = true; results.push(Element.extend(n)); } return Selector.handlers.unmark(results); }, // COMBINATOR FUNCTIONS descendant: function(nodes) { var h = Selector.handlers; for (var i = 0, results = [], node; node = nodes[i]; i++) h.concat(results, node.getElementsByTagName('*')); return results; }, child: function(nodes) { var h = Selector.handlers; for (var i = 0, results = [], node; node = nodes[i]; i++) { for (var j = 0, children = [], child; child = node.childNodes[j]; j++) if (child.nodeType == 1 && child.tagName != '!') results.push(child); } return results; }, adjacent: function(nodes) { for (var i = 0, results = [], node; node = nodes[i]; i++) { var next = this.nextElementSibling(node); if (next) results.push(next); } return results; }, laterSibling: function(nodes) { var h = Selector.handlers; for (var i = 0, results = [], node; node = nodes[i]; i++) h.concat(results, Element.nextSiblings(node)); return results; }, nextElementSibling: function(node) { while (node = node.nextSibling) if (node.nodeType == 1) return node; return null; }, previousElementSibling: function(node) { while (node = node.previousSibling) if (node.nodeType == 1) return node; return null; }, // TOKEN FUNCTIONS tagName: function(nodes, root, tagName, combinator) { tagName = tagName.toUpperCase(); var results = [], h = Selector.handlers; if (nodes) { if (combinator) { // fastlane for ordinary descendant combinators if (combinator == "descendant") { for (var i = 0, node; node = nodes[i]; i++) h.concat(results, node.getElementsByTagName(tagName)); return results; } else nodes = this[combinator](nodes); if (tagName == "*") return nodes; } for (var i = 0, node; node = nodes[i]; i++) if (node.tagName.toUpperCase() == tagName) results.push(node); return results; } else return root.getElementsByTagName(tagName); }, id: function(nodes, root, id, combinator) { var targetNode = $(id), h = Selector.handlers; if (!nodes && root == document) return targetNode ? [targetNode] : []; if (nodes) { if (combinator) { if (combinator == 'child') { for (var i = 0, node; node = nodes[i]; i++) if (targetNode.parentNode == node) return [targetNode]; } else if (combinator == 'descendant') { for (var i = 0, node; node = nodes[i]; i++) if (Element.descendantOf(targetNode, node)) return [targetNode]; } else if (combinator == 'adjacent') { for (var i = 0, node; node = nodes[i]; i++) if (Selector.handlers.previousElementSibling(targetNode) == node) return [targetNode]; } else nodes = h[combinator](nodes); } for (var i = 0, node; node = nodes[i]; i++) if (node == targetNode) return [targetNode]; return []; } return (targetNode && Element.descendantOf(targetNode, root)) ? [targetNode] : []; }, className: function(nodes, root, className, combinator) { if (nodes && combinator) nodes = this[combinator](nodes); return Selector.handlers.byClassName(nodes, root, className); }, byClassName: function(nodes, root, className) { if (!nodes) nodes = Selector.handlers.descendant([root]); var needle = ' ' + className + ' '; for (var i = 0, results = [], node, nodeClassName; node = nodes[i]; i++) { nodeClassName = node.className; if (nodeClassName.length == 0) continue; if (nodeClassName == className || (' ' + nodeClassName + ' ').include(needle)) results.push(node); } return results; }, attrPresence: function(nodes, root, attr) { var results = []; for (var i = 0, node; node = nodes[i]; i++) if (Element.hasAttribute(node, attr)) results.push(node); return results; }, attr: function(nodes, root, attr, value, operator) { if (!nodes) nodes = root.getElementsByTagName("*"); var handler = Selector.operators[operator], results = []; for (var i = 0, node; node = nodes[i]; i++) { var nodeValue = Element.readAttribute(node, attr); if (nodeValue === null) continue; if (handler(nodeValue, value)) results.push(node); } return results; }, pseudo: function(nodes, name, value, root, combinator) { if (nodes && combinator) nodes = this[combinator](nodes); if (!nodes) nodes = root.getElementsByTagName("*"); return Selector.pseudos[name](nodes, value, root); } }, pseudos: { 'first-child': function(nodes, value, root) { for (var i = 0, results = [], node; node = nodes[i]; i++) { if (Selector.handlers.previousElementSibling(node)) continue; results.push(node); } return results; }, 'last-child': function(nodes, value, root) { for (var i = 0, results = [], node; node = nodes[i]; i++) { if (Selector.handlers.nextElementSibling(node)) continue; results.push(node); } return results; }, 'only-child': function(nodes, value, root) { var h = Selector.handlers; for (var i = 0, results = [], node; node = nodes[i]; i++) if (!h.previousElementSibling(node) && !h.nextElementSibling(node)) results.push(node); return results; }, 'nth-child': function(nodes, formula, root) { return Selector.pseudos.nth(nodes, formula, root); }, 'nth-last-child': function(nodes, formula, root) { return Selector.pseudos.nth(nodes, formula, root, true); }, 'nth-of-type': function(nodes, formula, root) { return Selector.pseudos.nth(nodes, formula, root, false, true); }, 'nth-last-of-type': function(nodes, formula, root) { return Selector.pseudos.nth(nodes, formula, root, true, true); }, 'first-of-type': function(nodes, formula, root) { return Selector.pseudos.nth(nodes, "1", root, false, true); }, 'last-of-type': function(nodes, formula, root) { return Selector.pseudos.nth(nodes, "1", root, true, true); }, 'only-of-type': function(nodes, formula, root) { var p = Selector.pseudos; return p['last-of-type'](p['first-of-type'](nodes, formula, root), formula, root); }, // handles the an+b logic getIndices: function(a, b, total) { if (a == 0) return b > 0 ? [b] : []; return $R(1, total).inject([], function(memo, i) { if (0 == (i - b) % a && (i - b) / a >= 0) memo.push(i); return memo; }); }, // handles nth(-last)-child, nth(-last)-of-type, and (first|last)-of-type nth: function(nodes, formula, root, reverse, ofType) { if (nodes.length == 0) return []; if (formula == 'even') formula = '2n+0'; if (formula == 'odd') formula = '2n+1'; var h = Selector.handlers, results = [], indexed = [], m; h.mark(nodes); for (var i = 0, node; node = nodes[i]; i++) { if (!node.parentNode._counted) { h.index(node.parentNode, reverse, ofType); indexed.push(node.parentNode); } } if (formula.match(/^\d+$/)) { // just a number formula = Number(formula); for (var i = 0, node; node = nodes[i]; i++) if (node.nodeIndex == formula) results.push(node); } else if (m = formula.match(/^(-?\d*)?n(([+-])(\d+))?/)) { // an+b if (m[1] == "-") m[1] = -1; var a = m[1] ? Number(m[1]) : 1; var b = m[2] ? Number(m[2]) : 0; var indices = Selector.pseudos.getIndices(a, b, nodes.length); for (var i = 0, node, l = indices.length; node = nodes[i]; i++) { for (var j = 0; j < l; j++) if (node.nodeIndex == indices[j]) results.push(node); } } h.unmark(nodes); h.unmark(indexed); return results; }, 'empty': function(nodes, value, root) { for (var i = 0, results = [], node; node = nodes[i]; i++) { // IE treats comments as element nodes if (node.tagName == '!' || (node.firstChild && !node.innerHTML.match(/^\s*$/))) continue; results.push(node); } return results; }, 'not': function(nodes, selector, root) { var h = Selector.handlers, selectorType, m; var exclusions = new Selector(selector).findElements(root); h.mark(exclusions); for (var i = 0, results = [], node; node = nodes[i]; i++) if (!node._counted) results.push(node); h.unmark(exclusions); return results; }, 'enabled': function(nodes, value, root) { for (var i = 0, results = [], node; node = nodes[i]; i++) if (!node.disabled) results.push(node); return results; }, 'disabled': function(nodes, value, root) { for (var i = 0, results = [], node; node = nodes[i]; i++) if (node.disabled) results.push(node); return results; }, 'checked': function(nodes, value, root) { for (var i = 0, results = [], node; node = nodes[i]; i++) if (node.checked) results.push(node); return results; } }, operators: { '=': function(nv, v) { return nv == v; }, '!=': function(nv, v) { return nv != v; }, '^=': function(nv, v) { return nv.startsWith(v); }, '$=': function(nv, v) { return nv.endsWith(v); }, '*=': function(nv, v) { return nv.include(v); }, '~=': function(nv, v) { return (' ' + nv + ' ').include(' ' + v + ' '); }, '|=': function(nv, v) { return ('-' + nv.toUpperCase() + '-').include('-' + v.toUpperCase() + '-'); } }, matchElements: function(elements, expression) { var matches = new Selector(expression).findElements(), h = Selector.handlers; h.mark(matches); for (var i = 0, results = [], element; element = elements[i]; i++) if (element._counted) results.push(element); h.unmark(matches); return results; }, findElement: function(elements, expression, index) { if (typeof expression == 'number') { index = expression; expression = false; } return Selector.matchElements(elements, expression || '*')[index || 0]; }, findChildElements: function(element, expressions) { var exprs = expressions.join(','), expressions = []; exprs.scan(/(([\w#:.~>+()\s-]+|\*|\[.*?\])+)\s*(,|$)/, function(m) { expressions.push(m[1].strip()); }); var results = [], h = Selector.handlers; for (var i = 0, l = expressions.length, selector; i < l; i++) { selector = new Selector(expressions[i].strip()); h.concat(results, selector.findElements(element)); } return (l > 1) ? h.unique(results) : results; } }); function $$() { return Selector.findChildElements(document, $A(arguments)); } var Form = { reset: function(form) { $(form).reset(); return form; }, serializeElements: function(elements, getHash) { var data = elements.inject({}, function(result, element) { if (!element.disabled && element.name) { var key = element.name, value = $(element).getValue(); if (value != null) { if (key in result) { if (result[key].constructor != Array) result[key] = [result[key]]; result[key].push(value); } else result[key] = value; } } return result; }); return getHash ? data : Hash.toQueryString(data); } }; Form.Methods = { serialize: function(form, getHash) { return Form.serializeElements(Form.getElements(form), getHash); }, getElements: function(form) { return $A($(form).getElementsByTagName('*')).inject([], function(elements, child) { if (Form.Element.Serializers[child.tagName.toLowerCase()]) elements.push(Element.extend(child)); return elements; } ); }, getInputs: function(form, typeName, name) { form = $(form); var inputs = form.getElementsByTagName('input'); if (!typeName && !name) return $A(inputs).map(Element.extend); for (var i = 0, matchingInputs = [], length = inputs.length; i < length; i++) { var input = inputs[i]; if ((typeName && input.type != typeName) || (name && input.name != name)) continue; matchingInputs.push(Element.extend(input)); } return matchingInputs; }, disable: function(form) { form = $(form); Form.getElements(form).invoke('disable'); return form; }, enable: function(form) { form = $(form); Form.getElements(form).invoke('enable'); return form; }, findFirstElement: function(form) { return $(form).getElements().find(function(element) { return element.type != 'hidden' && !element.disabled && ['input', 'select', 'textarea'].include(element.tagName.toLowerCase()); }); }, focusFirstElement: function(form) { form = $(form); form.findFirstElement().activate(); return form; }, request: function(form, options) { form = $(form), options = Object.clone(options || {}); var params = options.parameters; options.parameters = form.serialize(true); if (params) { if (typeof params == 'string') params = params.toQueryParams(); Object.extend(options.parameters, params); } if (form.hasAttribute('method') && !options.method) options.method = form.method; return new Ajax.Request(form.readAttribute('action'), options); } } /*--------------------------------------------------------------------------*/ Form.Element = { focus: function(element) { $(element).focus(); return element; }, select: function(element) { $(element).select(); return element; } } Form.Element.Methods = { serialize: function(element) { element = $(element); if (!element.disabled && element.name) { var value = element.getValue(); if (value != undefined) { var pair = {}; pair[element.name] = value; return Hash.toQueryString(pair); } } return ''; }, getValue: function(element) { element = $(element); var method = element.tagName.toLowerCase(); return Form.Element.Serializers[method](element); }, clear: function(element) { $(element).value = ''; return element; }, present: function(element) { return $(element).value != ''; }, activate: function(element) { element = $(element); try { element.focus(); if (element.select && (element.tagName.toLowerCase() != 'input' || !['button', 'reset', 'submit'].include(element.type))) element.select(); } catch (e) {} return element; }, disable: function(element) { element = $(element); element.blur(); element.disabled = true; return element; }, enable: function(element) { element = $(element); element.disabled = false; return element; } } /*--------------------------------------------------------------------------*/ var Field = Form.Element; var $F = Form.Element.Methods.getValue; /*--------------------------------------------------------------------------*/ Form.Element.Serializers = { input: function(element) { switch (element.type.toLowerCase()) { case 'checkbox': case 'radio': return Form.Element.Serializers.inputSelector(element); default: return Form.Element.Serializers.textarea(element); } }, inputSelector: function(element) { return element.checked ? element.value : null; }, textarea: function(element) { return element.value; }, select: function(element) { return this[element.type == 'select-one' ? 'selectOne' : 'selectMany'](element); }, selectOne: function(element) { var index = element.selectedIndex; return index >= 0 ? this.optionValue(element.options[index]) : null; }, selectMany: function(element) { var values, length = element.length; if (!length) return null; for (var i = 0, values = []; i < length; i++) { var opt = element.options[i]; if (opt.selected) values.push(this.optionValue(opt)); } return values; }, optionValue: function(opt) { // extend element because hasAttribute may not be native return Element.extend(opt).hasAttribute('value') ? opt.value : opt.text; } } /*--------------------------------------------------------------------------*/ Abstract.TimedObserver = function() {} Abstract.TimedObserver.prototype = { initialize: function(element, frequency, callback) { this.frequency = frequency; this.element = $(element); this.callback = callback; this.lastValue = this.getValue(); this.registerCallback(); }, registerCallback: function() { setInterval(this.onTimerEvent.bind(this), this.frequency * 1000); }, onTimerEvent: function() { var value = this.getValue(); var changed = ('string' == typeof this.lastValue && 'string' == typeof value ? this.lastValue != value : String(this.lastValue) != String(value)); if (changed) { this.callback(this.element, value); this.lastValue = value; } } } Form.Element.Observer = Class.create(); Form.Element.Observer.prototype = Object.extend(new Abstract.TimedObserver(), { getValue: function() { return Form.Element.getValue(this.element); } }); Form.Observer = Class.create(); Form.Observer.prototype = Object.extend(new Abstract.TimedObserver(), { getValue: function() { return Form.serialize(this.element); } }); /*--------------------------------------------------------------------------*/ Abstract.EventObserver = function() {} Abstract.EventObserver.prototype = { initialize: function(element, callback) { this.element = $(element); this.callback = callback; this.lastValue = this.getValue(); if (this.element.tagName.toLowerCase() == 'form') this.registerFormCallbacks(); else this.registerCallback(this.element); }, onElementEvent: function() { var value = this.getValue(); if (this.lastValue != value) { this.callback(this.element, value); this.lastValue = value; } }, registerFormCallbacks: function() { Form.getElements(this.element).each(this.registerCallback.bind(this)); }, registerCallback: function(element) { if (element.type) { switch (element.type.toLowerCase()) { case 'checkbox': case 'radio': Event.observe(element, 'click', this.onElementEvent.bind(this)); break; default: Event.observe(element, 'change', this.onElementEvent.bind(this)); break; } } } } Form.Element.EventObserver = Class.create(); Form.Element.EventObserver.prototype = Object.extend(new Abstract.EventObserver(), { getValue: function() { return Form.Element.getValue(this.element); } }); Form.EventObserver = Class.create(); Form.EventObserver.prototype = Object.extend(new Abstract.EventObserver(), { getValue: function() { return Form.serialize(this.element); } }); if (!window.Event) { var Event = new Object(); } Object.extend(Event, { KEY_BACKSPACE: 8, KEY_TAB: 9, KEY_RETURN: 13, KEY_ESC: 27, KEY_LEFT: 37, KEY_UP: 38, KEY_RIGHT: 39, KEY_DOWN: 40, KEY_DELETE: 46, KEY_HOME: 36, KEY_END: 35, KEY_PAGEUP: 33, KEY_PAGEDOWN: 34, element: function(event) { return $(event.target || event.srcElement); }, isLeftClick: function(event) { return (((event.which) && (event.which == 1)) || ((event.button) && (event.button == 1))); }, pointerX: function(event) { return event.pageX || (event.clientX + (document.documentElement.scrollLeft || document.body.scrollLeft)); }, pointerY: function(event) { return event.pageY || (event.clientY + (document.documentElement.scrollTop || document.body.scrollTop)); }, stop: function(event) { if (event.preventDefault) { event.preventDefault(); event.stopPropagation(); } else { event.returnValue = false; event.cancelBubble = true; } }, // find the first node with the given tagName, starting from the // node the event was triggered on; traverses the DOM upwards findElement: function(event, tagName) { var element = Event.element(event); while (element.parentNode && (!element.tagName || (element.tagName.toUpperCase() != tagName.toUpperCase()))) element = element.parentNode; return element; }, observers: false, _observeAndCache: function(element, name, observer, useCapture) { if (!this.observers) this.observers = []; if (element.addEventListener) { this.observers.push([element, name, observer, useCapture]); element.addEventListener(name, observer, useCapture); } else if (element.attachEvent) { this.observers.push([element, name, observer, useCapture]); element.attachEvent('on' + name, observer); } }, unloadCache: function() { if (!Event.observers) return; for (var i = 0, length = Event.observers.length; i < length; i++) { Event.stopObserving.apply(this, Event.observers[i]); Event.observers[i][0] = null; } Event.observers = false; }, observe: function(element, name, observer, useCapture) { element = $(element); useCapture = useCapture || false; if (name == 'keypress' && (Prototype.Browser.WebKit || element.attachEvent)) name = 'keydown'; Event._observeAndCache(element, name, observer, useCapture); }, stopObserving: function(element, name, observer, useCapture) { element = $(element); useCapture = useCapture || false; if (name == 'keypress' && (Prototype.Browser.WebKit || element.attachEvent)) name = 'keydown'; if (element.removeEventListener) { element.removeEventListener(name, observer, useCapture); } else if (element.detachEvent) { try { element.detachEvent('on' + name, observer); } catch (e) {} } } }); /* prevent memory leaks in IE */ if (Prototype.Browser.IE) Event.observe(window, 'unload', Event.unloadCache, false); var Position = { // set to true if needed, warning: firefox performance problems // NOT neeeded for page scrolling, only if draggable contained in // scrollable elements includeScrollOffsets: false, // must be called before calling withinIncludingScrolloffset, every time the // page is scrolled prepare: function() { this.deltaX = window.pageXOffset || document.documentElement.scrollLeft || document.body.scrollLeft || 0; this.deltaY = window.pageYOffset || document.documentElement.scrollTop || document.body.scrollTop || 0; }, realOffset: function(element) { var valueT = 0, valueL = 0; do { valueT += element.scrollTop || 0; valueL += element.scrollLeft || 0; element = element.parentNode; } while (element); return [valueL, valueT]; }, cumulativeOffset: function(element) { var valueT = 0, valueL = 0; do { valueT += element.offsetTop || 0; valueL += element.offsetLeft || 0; element = element.offsetParent; } while (element); return [valueL, valueT]; }, positionedOffset: function(element) { var valueT = 0, valueL = 0; do { valueT += element.offsetTop || 0; valueL += element.offsetLeft || 0; element = element.offsetParent; if (element) { if(element.tagName=='BODY') break; var p = Element.getStyle(element, 'position'); if (p == 'relative' || p == 'absolute') break; } } while (element); return [valueL, valueT]; }, offsetParent: function(element) { if (element.offsetParent) return element.offsetParent; if (element == document.body) return element; while ((element = element.parentNode) && element != document.body) if (Element.getStyle(element, 'position') != 'static') return element; return document.body; }, // caches x/y coordinate pair to use with overlap within: function(element, x, y) { if (this.includeScrollOffsets) return this.withinIncludingScrolloffsets(element, x, y); this.xcomp = x; this.ycomp = y; this.offset = this.cumulativeOffset(element); return (y >= this.offset[1] && y < this.offset[1] + element.offsetHeight && x >= this.offset[0] && x < this.offset[0] + element.offsetWidth); }, withinIncludingScrolloffsets: function(element, x, y) { var offsetcache = this.realOffset(element); this.xcomp = x + offsetcache[0] - this.deltaX; this.ycomp = y + offsetcache[1] - this.deltaY; this.offset = this.cumulativeOffset(element); return (this.ycomp >= this.offset[1] && this.ycomp < this.offset[1] + element.offsetHeight && this.xcomp >= this.offset[0] && this.xcomp < this.offset[0] + element.offsetWidth); }, // within must be called directly before overlap: function(mode, element) { if (!mode) return 0; if (mode == 'vertical') return ((this.offset[1] + element.offsetHeight) - this.ycomp) / element.offsetHeight; if (mode == 'horizontal') return ((this.offset[0] + element.offsetWidth) - this.xcomp) / element.offsetWidth; }, page: function(forElement) { var valueT = 0, valueL = 0; var element = forElement; do { valueT += element.offsetTop || 0; valueL += element.offsetLeft || 0; // Safari fix if (element.offsetParent == document.body) if (Element.getStyle(element,'position')=='absolute') break; } while (element = element.offsetParent); element = forElement; do { if (!window.opera || element.tagName=='BODY') { valueT -= element.scrollTop || 0; valueL -= element.scrollLeft || 0; } } while (element = element.parentNode); return [valueL, valueT]; }, clone: function(source, target) { var options = Object.extend({ setLeft: true, setTop: true, setWidth: true, setHeight: true, offsetTop: 0, offsetLeft: 0 }, arguments[2] || {}) // find page position of source source = $(source); var p = Position.page(source); // find coordinate system to use target = $(target); var delta = [0, 0]; var parent = null; // delta [0,0] will do fine with position: fixed elements, // position:absolute needs offsetParent deltas if (Element.getStyle(target,'position') == 'absolute') { parent = Position.offsetParent(target); delta = Position.page(parent); } // correct by body offsets (fixes Safari) if (parent == document.body) { delta[0] -= document.body.offsetLeft; delta[1] -= document.body.offsetTop; } // set position if(options.setLeft) target.style.left = (p[0] - delta[0] + options.offsetLeft) + 'px'; if(options.setTop) target.style.top = (p[1] - delta[1] + options.offsetTop) + 'px'; if(options.setWidth) target.style.width = source.offsetWidth + 'px'; if(options.setHeight) target.style.height = source.offsetHeight + 'px'; }, absolutize: function(element) { element = $(element); if (element.style.position == 'absolute') return; Position.prepare(); var offsets = Position.positionedOffset(element); var top = offsets[1]; var left = offsets[0]; var width = element.clientWidth; var height = element.clientHeight; element._originalLeft = left - parseFloat(element.style.left || 0); element._originalTop = top - parseFloat(element.style.top || 0); element._originalWidth = element.style.width; element._originalHeight = element.style.height; element.style.position = 'absolute'; element.style.top = top + 'px'; element.style.left = left + 'px'; element.style.width = width + 'px'; element.style.height = height + 'px'; }, relativize: function(element) { element = $(element); if (element.style.position == 'relative') return; Position.prepare(); element.style.position = 'relative'; var top = parseFloat(element.style.top || 0) - (element._originalTop || 0); var left = parseFloat(element.style.left || 0) - (element._originalLeft || 0); element.style.top = top + 'px'; element.style.left = left + 'px'; element.style.height = element._originalHeight; element.style.width = element._originalWidth; } } // Safari returns margins on body which is incorrect if the child is absolutely // positioned. For performance reasons, redefine Position.cumulativeOffset for // KHTML/WebKit only. if (Prototype.Browser.WebKit) { Position.cumulativeOffset = function(element) { var valueT = 0, valueL = 0; do { valueT += element.offsetTop || 0; valueL += element.offsetLeft || 0; if (element.offsetParent == document.body) if (Element.getStyle(element, 'position') == 'absolute') break; element = element.offsetParent; } while (element); return [valueL, valueT]; } } Element.addMethods();rapache-1.2.8/test/r-script.R0000644000175100017510000000015412706745114015327 0ustar ondrejondrejfooey <- function(file,env){ setContentType("text/plain") cat("File:",file,"contents:\n") source(file) } rapache-1.2.8/test/read.r0000644000175100017510000000114012706745114014533 0ustar ondrejondrejif (is.null(FILES)) rnorm(10) tmpfile <- NULL if(!is.null(SERVER) && ("method" %in% names(SERVER)) && (SERVER$method == "POST") ){ tmpfile <- tempfile() con <- file(tmpfile,open="w") writeLines(readLines(),con); close(con); } setContentType("text/html") cat("") cat('

Using R To Read Input

\n') if (!is.null(tmpfile)) cat('

We read to this file:',tmpfile,'

\n') cat('
\n') cat('Upload a file:
\n') cat('') cat("
") -2 rapache-1.2.8/test/recBin.r0000644000175100017510000000255712706745114015037 0ustar ondrejondrej# Output starts here setContentType("text/html") cat('

receiveBin() test for RApache

\n') cat('
\n',sep='') cat('Enter a string:
\n',sep='') cat('Enter another string:
\n',sep='') cat('Upload a file:
\n') cat('Upload another file:
\n') cat('') cat("
\n")
while(length(x <- receiveBin(30)) > 0){
    cat(' raw:', x,'\nchar:',sep=' ')
    for (i in 1:length(x)){
	if (x[i] == 0) cat(' \\0')
	else if (x[i] == 13) cat(' \\r')
	else if (x[i] == 10) cat(' \\n')
	else cat(' ',rawToChar(x[i]))
    }
    cat('\n')
}
cat("
\n")
cat("SERVER INTERNALS\n")
print(list(readStarted=SERVER$internals('readStarted'),postParsed=SERVER$internals('postParsed')))
cat("SERVER\n")
print(SERVER)
cat("
\n") rapache-1.2.8/test/relocation.R0000644000175100017510000000030112706745114015715 0ustar ondrejondrejhandler <- function(){ loc <- '/index.html' if (!is.null(GET) && !is.null(GET$loc) && GET$loc != '') loc <- GET$loc setHeader("Location",loc) return(HTTP_MOVED_TEMPORARILY) } rapache-1.2.8/test/rshell.R0000644000175100017510000000136212706745114015057 0ustar ondrejondrejsetContentType('text/html') cat('

R Shell for RApache

\n') cat('\n') cat('
') if (!is.null(POST$code)){ cat("
\n")
    print(try(eval(parse(text=POST$code))))
    cat("
\n") } rapache-1.2.8/test/sendBin.r0000644000175100017510000000030512706745114015204 0ustar ondrejondrejsetContentType("image/png") t <- tempfile() png(t,type="cairo") plot(rnorm(10)) dev.off() setHeader('Content-Length',file.info(t)$size) sendBin(readBin(t,'raw',n=file.info(t)$size)) unlink(t) DONE rapache-1.2.8/test/spinner.gif0000644000175100017510000000376512706745114015621 0ustar ondrejondrejGIF89aæÿÿÿþþþ£££ýýýéééµµµùùùúúúõõõüüü«««íííÀÀÀ±±±ÇÇÇåååôôô´´´÷÷÷ÁÁÁÏÏÏæææäääßßßÄÄÄîîîšššÂÂÂÔÔÔâââ<<<¨¨¨°°°òòò­­­²²²ÛÛÛªªªÙÙÙ×××»»»&&&ÍÍÍØØØ¹¹¹žžžËËË®®®ûûûìììRRRêêê………öööJJJÜÜÜ ÑÑѤ¤¤)))ççç]]]½½½§§§ÌÌÌ···ñññÐÐÐYYYfffÊÊʦ¦¦ðððààุ¸¿¿¿èèèóóóÈÈÈzzz¥¥¥¾¾¾NNNÃÃÃÆÆÆÅÅÅjjjÝÝÝøøøÖÖÖººº¼¼¼nnnÞÞÞ–––‚‚‚ŒŒŒ‰‰‰aaatttTTT‡‡‡“““FFFŽŽŽWWW222wwwÚÚÚ|||666qqqAAAlll”””xxx¡¡¡¢¢¢---###€€€ÒÒÒ¬¬¬!ÿ NETSCAPE2.0!ù,È€‚‚-h ƒŠ‚_W -%‹Mo>j`=Š^:Q!6 53p6Z‚“OŠ/Q…Š,ƒ);Q — G@l^ba—"-$ Rƒ:‹σ1‹?T"–â­„!Jº `Ä„%* àÄ‹läÄ4HDa+Q4\" à  €âRaV¤ˆg ‘ @!ù, o€‚‚t…ƒ‚p8_sZ7Lƒ2>ngwhP7't„bcAr.: *2rb‚"Kƒ[\Š,A?B=Ê MÓ"-ƒ aÉŠH!1Ê?!ù,d€‚‚ d…ƒŠ=befN>]‹Ic.lFœ61 ‚Zb3gA†ˆ#¢ˆˆMc_XdÀE7k_¼‡$‡1ˆ7|yŠC,FwWmZ'/zR[ #VQŠ‚!ù,b€ -%‡#‡!2;/ZY!Nqjc6#Pb,ŽO§‡ e5.Ž=P_veŽV«f*gJ&moo6dKq$‰>|Ž‚`͇)" Ž!ù, m€#=‰!2;/2Y!6  ‰O!‰§G¨§#H;¬2^^H¬+¬‰c3d;JqBfEfZ!_m*.G>Sg<(¨hSkR¨Ppž§!ù, r€B1 OD†’,’U ’’ GM™†& !R ,‘™D(’Hm™zP 2-FbnG}5Z`ch+3!DIe/χ;c’Z ˆ!ù, d€‚V‚‡,P33fA‡‡}EmE‚"-‡,$†Cd{u™?F|e=b 2(],G˜3K!j%y[_t e?Q‡F+H5"0(‡©).† !ù, r€O:!2;>W."X2Y!Ml|sN1Ÿd£Ÿ^X_p¨Ÿxk7hG¯¨% §¯HmF¯nS. CCJ]PL£6^j?#V£5' £Ÿ+)!ù,a€‚ ‚:ƒ8o‡ƒC|u(U! 3s hP'“X*hƒ^‚;edj%ƒdXXg(©‚Dƒ)ne¨PI~q='/ƒ$’‚ ª;rapache-1.2.8/test/test.R0000644000175100017510000000600512706745114014544 0ustar ondrejondrej# Canonical Test hrefify <- function(title) gsub('[\\.()]','_',title,perl=TRUE) scrub <- function(str){ if (is.null(str)) return('NULL') if (length(str) == 0) return('length 0 string') #cat("\n\n",sep='') str <- try(as.character(str),silent=TRUE) if (inherits(str,'try-error')) return('try-error') #cat("\n\n",sep='') str <- gsub('&','&',str); str <- gsub('@','_at_',str); str <- gsub('<','<',str); str <- gsub('>','>',str); if (length(str) == 0 || is.null(str) || str == '') str <- ' ' str } cl<-'e' zebary <- function(i){ cl <<- ifelse(cl=='e','o','e') cat('',scrub(i),'\n',sep='') } zeblist <- function(i,l){ cl <<- ifelse(cl=='e','o','e') cat('',names(l)[i],'') if(is.list(l[[i]])) zebra(names(l)[i],l[[i]]) else { if (length(l[[i]]) > 1) zebary(l[[i]]) else cat(scrub(l[[i]])) } cat('\n',sep='') } zebra <- function(title,l){ cat('

',title,'

\n',sep='') ifelse(is.list(l),lapply(1:length(l),zeblist,l), lapply(l,zebary)) cat('
\n

') } # Output starts here setContentType("text/html") if(is.null(GET)){ called <- 1 } else { called <- as.integer(GET$called) + 1 } setCookie('called',called,expires=Sys.time()+100) setCookie('anotherCookie','foo',expires=Sys.time()+100) cat('

Canonical Test for RApache

\n') cat('\n',sep='') cat('Enter a string:
\n',sep='') cat('Enter another string:
\n',sep='') cat('Upload a file:
\n') cat('Upload another file:
\n') cat('') cat("
\n") #RApacheOutputErrors(TRUE) #RApacheOutputErrors(TRUE,prefix='\n') #RApacheOutputErrors(FALSE) zebra('CGI GET Data',GET) zebra('CGI POST Data',POST) zebra('Cookies',COOKIES) if (!is.null(FILES)){ cat('

Files Uploaded in POST Data

\n') for (n in names(FILES)){ zebra(paste("Form Variable",n),FILES[[n]]) } } zebra("SERVER Variables",SERVER) zebra("SERVER INTERNALS",list(readStarted=SERVER$internals('readStarted'),postParsed=SERVER$internals('postParsed'))) zebra("Search Path",search()) zebra(".libPaths",.libPaths()) zebra("DLLs",capture.output(str(getLoadedDLLs()))) zebra("rapache Environment",ls('rapache')) cat("\n") OK rapache-1.2.8/test/useR2007.R0000644000175100017510000000057412706745114015021 0ustar ondrejondrejuser2007example <- function(p1=.95,p2=.7){ x11(width=10,height=10) sc <- Weibull2(c(1,3),c(p1,p2)) rcens <- function(n) 1 + (5-1) * (runif(n) ^ .5) f <- Quantile2(sc, hratio=function(x) ifelse(x <= .75, 1, .75), dropin=function(x) ifelse(x <= .5, 0, .15 * (x-.5)/(5-.5)), dropout=function(x) .3*x/5 ) par(mfrow=c(2,2)) plot(f,'all',label.curves=list(keys='lines')) } rapache-1.2.8/test/useR2007.css0000644000175100017510000000344012706745114015403 0ustar ondrejondrejbody { font: .7em verdana, arial, sans-serif; margin-top: 10px; margin-left:10px; margin-right:10px; /* border: 1px solid black; */ } /* img { border: 1px; position: absolute; } */ * {margin:0; padding:0;} div#mainwrapper { /* min-width:760px; */ /* max-width:880px; */ margin-left:auto; margin-right:auto;} /* centers layout when > max width */ div#header { width:auto; } #threecolwrap { float:left; width:100%; } #twocolwrap { float:left; width:100%; display:inline; /* stops IE doubling margin on float*/ margin-right:-170px; /* CWS - neg margin move */ } #leftcol { float:left; width:175px; display:inline; /* stops IE doubling margin on float*/ /* border: 1px solid black; */ } #content { width:600px; margin-left:175px; margin-top: 0px; /* margin-right:170px; */ /* border: 1px solid black; */ } #rightcol { position: absolute; width:175px; margin-left: 775px; /* width:170px; */ /* width: auto;*/ /* border: 1px solid black; */ } #footer { width:100%; clear:both; float:left; text-align: right; font-size: .6em; /* border: 1px solid black; */ } div#yldiv { float:left; width:250px; display: none; } select { /* float: right; */ width: 100%; font-size: .9em; border: 1px solid grey; } div#formcontent { /*border: 1px solid black; */ } div.clearfix { /* border: 1px solid #CCC; */ margin-bottom: 10px; } label { float: left; font-size: .9em; font-weight: bold; width:100% } div#content h1,h2,h3 { text-align: center } div#content p,ul { margin: 2% 20% 2% 20%; font-size: 1.2em; } div#content li { margin-bottom: 3%; } div#showpdf { margin-left: 20px; } div#copyright { color: grey; text-align: center; font-size: .8em; margin: 10% 20% 0px 20%; } div#bibliography { margin-top: 10px; font: .8em verdana, arial, sans-serif; font-weight: bold; } rapache-1.2.8/test/useR2007.js0000644000175100017510000000116212706745114015226 0ustar ondrejondrejfunction RePlot(){ var p1 = document.spower.p1.value; var p2 = document.spower.p2.value; var mo = document.spower.mo.value; new Ajax.Updater( 'plot', '/brew/useR2007plot.rhtml', { 'method': 'get', 'parameters': {'p1': p1, 'p2': p2, 'mo': mo}, } ); } function ReSimulate(){ var p1 = document.spower.p1.value; var p2 = document.spower.p2.value; var mo = document.spower.mo.value; Element.show('spinner'); new Ajax.Updater( 'spowerResult', '/brew/useR2007sim.rhtml', { 'method': 'get', 'parameters': {'p1': p1, 'p2': p2, 'mo': mo}, 'onSuccess': function(r){Element.hide('spinner')} } ); } rapache-1.2.8/test/warning.R0000644000175100017510000000012512706745114015227 0ustar ondrejondrejcat('options()$warn is',getOption('warn'),'\n') cat('warnings:\n') print(warnings()) rapache-1.2.8/tools/0000755000175100017510000000000012706745114013622 5ustar ondrejondrejrapache-1.2.8/tools/brewweb0000755000175100017510000000046212706745114015207 0ustar ondrejondrej#!/usr/bin/env Rscript library(brew) library(Rook) h <- file.path(getwd(),'website') t <- file.path(h,'templates') setwd(t) for (p in list.files(pattern='\\.html')){ inputfile <- file.path(t,p) outputfile <- file.path(h,p) cat(inputfile,'\n') brew(inputfile,outputfile,tplParser=Utils$escape_html) } rapache-1.2.8/tools/config.guess0000755000175100017510000013105412706745114016146 0ustar ondrejondrej#! /bin/sh # Attempt to guess a canonical system name. # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, # 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 # Free Software Foundation, Inc. timestamp='2009-06-10' # 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 # 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. # Originally written by Per Bothner . # Please send patches to . Submit a context # diff and a properly formatted ChangeLog entry. # # This script attempts to guess a canonical system name similar to # config.sub. If it succeeds, it prints the system name on stdout, and # exits with 0. Otherwise, it exits with 1. # # The plan is that this can be called by configure scripts if you # don't specify an explicit build system type. me=`echo "$0" | sed -e 's,.*/,,'` usage="\ Usage: $0 [OPTION] Output the configuration name of the system \`$me' is run on. Operation modes: -h, --help print this help, then exit -t, --time-stamp print date of last modification, then exit -v, --version print version number, then exit Report bugs and patches to ." version="\ GNU config.guess ($timestamp) Originally written by Per Bothner. Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 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." help=" Try \`$me --help' for more information." # Parse command line while test $# -gt 0 ; do case $1 in --time-stamp | --time* | -t ) echo "$timestamp" ; exit ;; --version | -v ) echo "$version" ; exit ;; --help | --h* | -h ) echo "$usage"; exit ;; -- ) # Stop option processing shift; break ;; - ) # Use stdin as input. break ;; -* ) echo "$me: invalid option $1$help" >&2 exit 1 ;; * ) break ;; esac done if test $# != 0; then echo "$me: too many arguments$help" >&2 exit 1 fi trap 'exit 1' 1 2 15 # CC_FOR_BUILD -- compiler used by this script. Note that the use of a # compiler to aid in system detection is discouraged as it requires # temporary files to be created and, as you can see below, it is a # headache to deal with in a portable fashion. # Historically, `CC_FOR_BUILD' used to be named `HOST_CC'. We still # use `HOST_CC' if defined, but it is deprecated. # Portable tmp directory creation inspired by the Autoconf team. set_cc_for_build=' trap "exitcode=\$?; (rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null) && exit \$exitcode" 0 ; trap "rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null; exit 1" 1 2 13 15 ; : ${TMPDIR=/tmp} ; { tmp=`(umask 077 && mktemp -d "$TMPDIR/cgXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" ; } || { test -n "$RANDOM" && tmp=$TMPDIR/cg$$-$RANDOM && (umask 077 && mkdir $tmp) ; } || { tmp=$TMPDIR/cg-$$ && (umask 077 && mkdir $tmp) && echo "Warning: creating insecure temp directory" >&2 ; } || { echo "$me: cannot create a temporary directory in $TMPDIR" >&2 ; exit 1 ; } ; dummy=$tmp/dummy ; tmpfiles="$dummy.c $dummy.o $dummy.rel $dummy" ; case $CC_FOR_BUILD,$HOST_CC,$CC in ,,) echo "int x;" > $dummy.c ; for c in cc gcc c89 c99 ; do if ($c -c -o $dummy.o $dummy.c) >/dev/null 2>&1 ; then CC_FOR_BUILD="$c"; break ; fi ; done ; if test x"$CC_FOR_BUILD" = x ; then CC_FOR_BUILD=no_compiler_found ; fi ;; ,,*) CC_FOR_BUILD=$CC ;; ,*,*) CC_FOR_BUILD=$HOST_CC ;; esac ; set_cc_for_build= ;' # This is needed to find uname on a Pyramid OSx when run in the BSD universe. # (ghazi@noc.rutgers.edu 1994-08-24) if (test -f /.attbin/uname) >/dev/null 2>&1 ; then PATH=$PATH:/.attbin ; export PATH fi UNAME_MACHINE=`(uname -m) 2>/dev/null` || UNAME_MACHINE=unknown UNAME_RELEASE=`(uname -r) 2>/dev/null` || UNAME_RELEASE=unknown UNAME_SYSTEM=`(uname -s) 2>/dev/null` || UNAME_SYSTEM=unknown UNAME_VERSION=`(uname -v) 2>/dev/null` || UNAME_VERSION=unknown # Note: order is significant - the case branches are not exclusive. case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in *:NetBSD:*:*) # NetBSD (nbsd) targets should (where applicable) match one or # more of the tupples: *-*-netbsdelf*, *-*-netbsdaout*, # *-*-netbsdecoff* and *-*-netbsd*. For targets that recently # switched to ELF, *-*-netbsd* would select the old # object file format. This provides both forward # compatibility and a consistent mechanism for selecting the # object file format. # # Note: NetBSD doesn't particularly care about the vendor # portion of the name. We always set it to "unknown". sysctl="sysctl -n hw.machine_arch" UNAME_MACHINE_ARCH=`(/sbin/$sysctl 2>/dev/null || \ /usr/sbin/$sysctl 2>/dev/null || echo unknown)` case "${UNAME_MACHINE_ARCH}" in armeb) machine=armeb-unknown ;; arm*) machine=arm-unknown ;; sh3el) machine=shl-unknown ;; sh3eb) machine=sh-unknown ;; sh5el) machine=sh5le-unknown ;; *) machine=${UNAME_MACHINE_ARCH}-unknown ;; esac # The Operating System including object format, if it has switched # to ELF recently, or will in the future. case "${UNAME_MACHINE_ARCH}" in arm*|i386|m68k|ns32k|sh3*|sparc|vax) eval $set_cc_for_build if echo __ELF__ | $CC_FOR_BUILD -E - 2>/dev/null \ | grep -q __ELF__ then # Once all utilities can be ECOFF (netbsdecoff) or a.out (netbsdaout). # Return netbsd for either. FIX? os=netbsd else os=netbsdelf fi ;; *) os=netbsd ;; esac # The OS release # Debian GNU/NetBSD machines have a different userland, and # thus, need a distinct triplet. However, they do not need # kernel version information, so it can be replaced with a # suitable tag, in the style of linux-gnu. case "${UNAME_VERSION}" in Debian*) release='-gnu' ;; *) release=`echo ${UNAME_RELEASE}|sed -e 's/[-_].*/\./'` ;; esac # Since CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM: # contains redundant information, the shorter form: # CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM is used. echo "${machine}-${os}${release}" exit ;; *:OpenBSD:*:*) UNAME_MACHINE_ARCH=`arch | sed 's/OpenBSD.//'` echo ${UNAME_MACHINE_ARCH}-unknown-openbsd${UNAME_RELEASE} exit ;; *:ekkoBSD:*:*) echo ${UNAME_MACHINE}-unknown-ekkobsd${UNAME_RELEASE} exit ;; *:SolidBSD:*:*) echo ${UNAME_MACHINE}-unknown-solidbsd${UNAME_RELEASE} exit ;; macppc:MirBSD:*:*) echo powerpc-unknown-mirbsd${UNAME_RELEASE} exit ;; *:MirBSD:*:*) echo ${UNAME_MACHINE}-unknown-mirbsd${UNAME_RELEASE} exit ;; alpha:OSF1:*:*) case $UNAME_RELEASE in *4.0) UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $3}'` ;; *5.*) UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $4}'` ;; esac # According to Compaq, /usr/sbin/psrinfo has been available on # OSF/1 and Tru64 systems produced since 1995. I hope that # covers most systems running today. This code pipes the CPU # types through head -n 1, so we only detect the type of CPU 0. ALPHA_CPU_TYPE=`/usr/sbin/psrinfo -v | sed -n -e 's/^ The alpha \(.*\) processor.*$/\1/p' | head -n 1` case "$ALPHA_CPU_TYPE" in "EV4 (21064)") UNAME_MACHINE="alpha" ;; "EV4.5 (21064)") UNAME_MACHINE="alpha" ;; "LCA4 (21066/21068)") UNAME_MACHINE="alpha" ;; "EV5 (21164)") UNAME_MACHINE="alphaev5" ;; "EV5.6 (21164A)") UNAME_MACHINE="alphaev56" ;; "EV5.6 (21164PC)") UNAME_MACHINE="alphapca56" ;; "EV5.7 (21164PC)") UNAME_MACHINE="alphapca57" ;; "EV6 (21264)") UNAME_MACHINE="alphaev6" ;; "EV6.7 (21264A)") UNAME_MACHINE="alphaev67" ;; "EV6.8CB (21264C)") UNAME_MACHINE="alphaev68" ;; "EV6.8AL (21264B)") UNAME_MACHINE="alphaev68" ;; "EV6.8CX (21264D)") UNAME_MACHINE="alphaev68" ;; "EV6.9A (21264/EV69A)") UNAME_MACHINE="alphaev69" ;; "EV7 (21364)") UNAME_MACHINE="alphaev7" ;; "EV7.9 (21364A)") UNAME_MACHINE="alphaev79" ;; esac # A Pn.n version is a patched version. # A Vn.n version is a released version. # A Tn.n version is a released field test version. # A Xn.n version is an unreleased experimental baselevel. # 1.2 uses "1.2" for uname -r. echo ${UNAME_MACHINE}-dec-osf`echo ${UNAME_RELEASE} | sed -e 's/^[PVTX]//' | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` exit ;; Alpha\ *:Windows_NT*:*) # How do we know it's Interix rather than the generic POSIX subsystem? # Should we change UNAME_MACHINE based on the output of uname instead # of the specific Alpha model? echo alpha-pc-interix exit ;; 21064:Windows_NT:50:3) echo alpha-dec-winnt3.5 exit ;; Amiga*:UNIX_System_V:4.0:*) echo m68k-unknown-sysv4 exit ;; *:[Aa]miga[Oo][Ss]:*:*) echo ${UNAME_MACHINE}-unknown-amigaos exit ;; *:[Mm]orph[Oo][Ss]:*:*) echo ${UNAME_MACHINE}-unknown-morphos exit ;; *:OS/390:*:*) echo i370-ibm-openedition exit ;; *:z/VM:*:*) echo s390-ibm-zvmoe exit ;; *:OS400:*:*) echo powerpc-ibm-os400 exit ;; arm:RISC*:1.[012]*:*|arm:riscix:1.[012]*:*) echo arm-acorn-riscix${UNAME_RELEASE} exit ;; arm:riscos:*:*|arm:RISCOS:*:*) echo arm-unknown-riscos exit ;; SR2?01:HI-UX/MPP:*:* | SR8000:HI-UX/MPP:*:*) echo hppa1.1-hitachi-hiuxmpp exit ;; Pyramid*:OSx*:*:* | MIS*:OSx*:*:* | MIS*:SMP_DC-OSx*:*:*) # akee@wpdis03.wpafb.af.mil (Earle F. Ake) contributed MIS and NILE. if test "`(/bin/universe) 2>/dev/null`" = att ; then echo pyramid-pyramid-sysv3 else echo pyramid-pyramid-bsd fi exit ;; NILE*:*:*:dcosx) echo pyramid-pyramid-svr4 exit ;; DRS?6000:unix:4.0:6*) echo sparc-icl-nx6 exit ;; DRS?6000:UNIX_SV:4.2*:7* | DRS?6000:isis:4.2*:7*) 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 ;; sun4*:SunOS:5.*:* | tadpole*:SunOS:5.*:*) 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/[^.]*//'` exit ;; sun4*:SunOS:6*:*) # According to config.sub, this is the proper way to canonicalize # SunOS6. Hard to guess exactly what SunOS6 will be like, but # it's likely to be more like Solaris than SunOS4. echo sparc-sun-solaris3`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` exit ;; sun4*:SunOS:*:*) case "`/usr/bin/arch -k`" in Series*|S4*) UNAME_RELEASE=`uname -v` ;; esac # Japanese Language versions have a version number like `4.1.3-JL'. echo sparc-sun-sunos`echo ${UNAME_RELEASE}|sed -e 's/-/_/'` exit ;; sun3*:SunOS:*:*) echo m68k-sun-sunos${UNAME_RELEASE} exit ;; sun*:*:4.2BSD:*) UNAME_RELEASE=`(sed 1q /etc/motd | awk '{print substr($5,1,3)}') 2>/dev/null` test "x${UNAME_RELEASE}" = "x" && UNAME_RELEASE=3 case "`/bin/arch`" in sun3) echo m68k-sun-sunos${UNAME_RELEASE} ;; sun4) echo sparc-sun-sunos${UNAME_RELEASE} ;; esac exit ;; aushp:SunOS:*:*) echo sparc-auspex-sunos${UNAME_RELEASE} exit ;; # The situation for MiNT is a little confusing. The machine name # can be virtually everything (everything which is not # "atarist" or "atariste" at least should have a processor # > m68000). The system name ranges from "MiNT" over "FreeMiNT" # to the lowercase version "mint" (or "freemint"). Finally # the system name "TOS" denotes a system which is actually not # MiNT. But MiNT is downward compatible to TOS, so this should # be no problem. atarist[e]:*MiNT:*:* | atarist[e]:*mint:*:* | atarist[e]:*TOS:*:*) echo m68k-atari-mint${UNAME_RELEASE} exit ;; atari*:*MiNT:*:* | atari*:*mint:*:* | atarist[e]:*TOS:*:*) echo m68k-atari-mint${UNAME_RELEASE} exit ;; *falcon*:*MiNT:*:* | *falcon*:*mint:*:* | *falcon*:*TOS:*:*) echo m68k-atari-mint${UNAME_RELEASE} exit ;; milan*:*MiNT:*:* | milan*:*mint:*:* | *milan*:*TOS:*:*) echo m68k-milan-mint${UNAME_RELEASE} exit ;; hades*:*MiNT:*:* | hades*:*mint:*:* | *hades*:*TOS:*:*) echo m68k-hades-mint${UNAME_RELEASE} exit ;; *:*MiNT:*:* | *:*mint:*:* | *:*TOS:*:*) echo m68k-unknown-mint${UNAME_RELEASE} exit ;; m68k:machten:*:*) echo m68k-apple-machten${UNAME_RELEASE} exit ;; powerpc:machten:*:*) echo powerpc-apple-machten${UNAME_RELEASE} exit ;; RISC*:Mach:*:*) echo mips-dec-mach_bsd4.3 exit ;; RISC*:ULTRIX:*:*) echo mips-dec-ultrix${UNAME_RELEASE} exit ;; VAX*:ULTRIX*:*:*) echo vax-dec-ultrix${UNAME_RELEASE} exit ;; 2020:CLIX:*:* | 2430:CLIX:*:*) echo clipper-intergraph-clix${UNAME_RELEASE} exit ;; mips:*:*:UMIPS | mips:*:*:RISCos) eval $set_cc_for_build sed 's/^ //' << EOF >$dummy.c #ifdef __cplusplus #include /* for printf() prototype */ int main (int argc, char *argv[]) { #else int main (argc, argv) int argc; char *argv[]; { #endif #if defined (host_mips) && defined (MIPSEB) #if defined (SYSTYPE_SYSV) printf ("mips-mips-riscos%ssysv\n", argv[1]); exit (0); #endif #if defined (SYSTYPE_SVR4) printf ("mips-mips-riscos%ssvr4\n", argv[1]); exit (0); #endif #if defined (SYSTYPE_BSD43) || defined(SYSTYPE_BSD) printf ("mips-mips-riscos%sbsd\n", argv[1]); exit (0); #endif #endif exit (-1); } EOF $CC_FOR_BUILD -o $dummy $dummy.c && dummyarg=`echo "${UNAME_RELEASE}" | sed -n 's/\([0-9]*\).*/\1/p'` && SYSTEM_NAME=`$dummy $dummyarg` && { echo "$SYSTEM_NAME"; exit; } echo mips-mips-riscos${UNAME_RELEASE} exit ;; Motorola:PowerMAX_OS:*:*) echo powerpc-motorola-powermax exit ;; Motorola:*:4.3:PL8-*) echo powerpc-harris-powermax exit ;; Night_Hawk:*:*:PowerMAX_OS | Synergy:PowerMAX_OS:*:*) echo powerpc-harris-powermax exit ;; Night_Hawk:Power_UNIX:*:*) echo powerpc-harris-powerunix exit ;; m88k:CX/UX:7*:*) echo m88k-harris-cxux7 exit ;; m88k:*:4*:R4*) echo m88k-motorola-sysv4 exit ;; m88k:*:3*:R3*) echo m88k-motorola-sysv3 exit ;; AViiON:dgux:*:*) # DG/UX returns AViiON for all architectures UNAME_PROCESSOR=`/usr/bin/uname -p` if [ $UNAME_PROCESSOR = mc88100 ] || [ $UNAME_PROCESSOR = mc88110 ] then if [ ${TARGET_BINARY_INTERFACE}x = m88kdguxelfx ] || \ [ ${TARGET_BINARY_INTERFACE}x = x ] then echo m88k-dg-dgux${UNAME_RELEASE} else echo m88k-dg-dguxbcs${UNAME_RELEASE} fi else echo i586-dg-dgux${UNAME_RELEASE} fi exit ;; M88*:DolphinOS:*:*) # DolphinOS (SVR3) echo m88k-dolphin-sysv3 exit ;; M88*:*:R3*:*) # Delta 88k system running SVR3 echo m88k-motorola-sysv3 exit ;; XD88*:*:*:*) # Tektronix XD88 system running UTekV (SVR3) echo m88k-tektronix-sysv3 exit ;; Tek43[0-9][0-9]:UTek:*:*) # Tektronix 4300 system running UTek (BSD) echo m68k-tektronix-bsd exit ;; *:IRIX*:*:*) echo mips-sgi-irix`echo ${UNAME_RELEASE}|sed -e 's/-/_/g'` exit ;; ????????:AIX?:[12].1:2) # AIX 2.2.1 or AIX 2.1.1 is RT/PC AIX. echo romp-ibm-aix # uname -m gives an 8 hex-code CPU id exit ;; # Note that: echo "'`uname -s`'" gives 'AIX ' i*86:AIX:*:*) echo i386-ibm-aix exit ;; ia64:AIX:*:*) if [ -x /usr/bin/oslevel ] ; then IBM_REV=`/usr/bin/oslevel` else IBM_REV=${UNAME_VERSION}.${UNAME_RELEASE} fi echo ${UNAME_MACHINE}-ibm-aix${IBM_REV} exit ;; *:AIX:2:3) if grep bos325 /usr/include/stdio.h >/dev/null 2>&1; then eval $set_cc_for_build sed 's/^ //' << EOF >$dummy.c #include main() { if (!__power_pc()) exit(1); puts("powerpc-ibm-aix3.2.5"); exit(0); } EOF if $CC_FOR_BUILD -o $dummy $dummy.c && SYSTEM_NAME=`$dummy` then echo "$SYSTEM_NAME" else echo rs6000-ibm-aix3.2.5 fi elif grep bos324 /usr/include/stdio.h >/dev/null 2>&1; then echo rs6000-ibm-aix3.2.4 else echo rs6000-ibm-aix3.2 fi exit ;; *:AIX:*:[456]) IBM_CPU_ID=`/usr/sbin/lsdev -C -c processor -S available | sed 1q | awk '{ print $1 }'` if /usr/sbin/lsattr -El ${IBM_CPU_ID} | grep ' POWER' >/dev/null 2>&1; then IBM_ARCH=rs6000 else IBM_ARCH=powerpc fi if [ -x /usr/bin/oslevel ] ; then IBM_REV=`/usr/bin/oslevel` else IBM_REV=${UNAME_VERSION}.${UNAME_RELEASE} fi echo ${IBM_ARCH}-ibm-aix${IBM_REV} exit ;; *:AIX:*:*) echo rs6000-ibm-aix exit ;; ibmrt:4.4BSD:*|romp-ibm:BSD:*) echo romp-ibm-bsd4.4 exit ;; ibmrt:*BSD:*|romp-ibm:BSD:*) # covers RT/PC BSD and echo romp-ibm-bsd${UNAME_RELEASE} # 4.3 with uname added to exit ;; # report: romp-ibm BSD 4.3 *:BOSX:*:*) echo rs6000-bull-bosx exit ;; DPX/2?00:B.O.S.:*:*) echo m68k-bull-sysv3 exit ;; 9000/[34]??:4.3bsd:1.*:*) echo m68k-hp-bsd exit ;; hp300:4.4BSD:*:* | 9000/[34]??:4.3bsd:2.*:*) echo m68k-hp-bsd4.4 exit ;; 9000/[34678]??:HP-UX:*:*) HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'` case "${UNAME_MACHINE}" in 9000/31? ) HP_ARCH=m68000 ;; 9000/[34]?? ) HP_ARCH=m68k ;; 9000/[678][0-9][0-9]) if [ -x /usr/bin/getconf ]; then sc_cpu_version=`/usr/bin/getconf SC_CPU_VERSION 2>/dev/null` sc_kernel_bits=`/usr/bin/getconf SC_KERNEL_BITS 2>/dev/null` case "${sc_cpu_version}" in 523) HP_ARCH="hppa1.0" ;; # CPU_PA_RISC1_0 528) HP_ARCH="hppa1.1" ;; # CPU_PA_RISC1_1 532) # CPU_PA_RISC2_0 case "${sc_kernel_bits}" in 32) HP_ARCH="hppa2.0n" ;; 64) HP_ARCH="hppa2.0w" ;; '') HP_ARCH="hppa2.0" ;; # HP-UX 10.20 esac ;; esac fi if [ "${HP_ARCH}" = "" ]; then eval $set_cc_for_build sed 's/^ //' << EOF >$dummy.c #define _HPUX_SOURCE #include #include int main () { #if defined(_SC_KERNEL_BITS) long bits = sysconf(_SC_KERNEL_BITS); #endif long cpu = sysconf (_SC_CPU_VERSION); switch (cpu) { case CPU_PA_RISC1_0: puts ("hppa1.0"); break; case CPU_PA_RISC1_1: puts ("hppa1.1"); break; case CPU_PA_RISC2_0: #if defined(_SC_KERNEL_BITS) switch (bits) { case 64: puts ("hppa2.0w"); break; case 32: puts ("hppa2.0n"); break; default: puts ("hppa2.0"); break; } break; #else /* !defined(_SC_KERNEL_BITS) */ puts ("hppa2.0"); break; #endif default: puts ("hppa1.0"); break; } exit (0); } EOF (CCOPTS= $CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null) && HP_ARCH=`$dummy` test -z "$HP_ARCH" && HP_ARCH=hppa fi ;; esac if [ ${HP_ARCH} = "hppa2.0w" ] then eval $set_cc_for_build # hppa2.0w-hp-hpux* has a 64-bit kernel and a compiler generating # 32-bit code. hppa64-hp-hpux* has the same kernel and a compiler # generating 64-bit code. GNU and HP use different nomenclature: # # $ CC_FOR_BUILD=cc ./config.guess # => hppa2.0w-hp-hpux11.23 # $ CC_FOR_BUILD="cc +DA2.0w" ./config.guess # => hppa64-hp-hpux11.23 if echo __LP64__ | (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | grep -q __LP64__ then HP_ARCH="hppa2.0w" else HP_ARCH="hppa64" fi fi echo ${HP_ARCH}-hp-hpux${HPUX_REV} exit ;; ia64:HP-UX:*:*) HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'` echo ia64-hp-hpux${HPUX_REV} exit ;; 3050*:HI-UX:*:*) eval $set_cc_for_build sed 's/^ //' << EOF >$dummy.c #include int main () { long cpu = sysconf (_SC_CPU_VERSION); /* The order matters, because CPU_IS_HP_MC68K erroneously returns true for CPU_PA_RISC1_0. CPU_IS_PA_RISC returns correct results, however. */ if (CPU_IS_PA_RISC (cpu)) { switch (cpu) { case CPU_PA_RISC1_0: puts ("hppa1.0-hitachi-hiuxwe2"); break; case CPU_PA_RISC1_1: puts ("hppa1.1-hitachi-hiuxwe2"); break; case CPU_PA_RISC2_0: puts ("hppa2.0-hitachi-hiuxwe2"); break; default: puts ("hppa-hitachi-hiuxwe2"); break; } } else if (CPU_IS_HP_MC68K (cpu)) puts ("m68k-hitachi-hiuxwe2"); else puts ("unknown-hitachi-hiuxwe2"); exit (0); } EOF $CC_FOR_BUILD -o $dummy $dummy.c && SYSTEM_NAME=`$dummy` && { echo "$SYSTEM_NAME"; exit; } echo unknown-hitachi-hiuxwe2 exit ;; 9000/7??:4.3bsd:*:* | 9000/8?[79]:4.3bsd:*:* ) echo hppa1.1-hp-bsd exit ;; 9000/8??:4.3bsd:*:*) echo hppa1.0-hp-bsd exit ;; *9??*:MPE/iX:*:* | *3000*:MPE/iX:*:*) echo hppa1.0-hp-mpeix exit ;; hp7??:OSF1:*:* | hp8?[79]:OSF1:*:* ) echo hppa1.1-hp-osf exit ;; hp8??:OSF1:*:*) echo hppa1.0-hp-osf exit ;; i*86:OSF1:*:*) if [ -x /usr/sbin/sysversion ] ; then echo ${UNAME_MACHINE}-unknown-osf1mk else echo ${UNAME_MACHINE}-unknown-osf1 fi exit ;; parisc*:Lites*:*:*) echo hppa1.1-hp-lites exit ;; C1*:ConvexOS:*:* | convex:ConvexOS:C1*:*) echo c1-convex-bsd exit ;; C2*:ConvexOS:*:* | convex:ConvexOS:C2*:*) if getsysinfo -f scalar_acc then echo c32-convex-bsd else echo c2-convex-bsd fi exit ;; C34*:ConvexOS:*:* | convex:ConvexOS:C34*:*) echo c34-convex-bsd exit ;; C38*:ConvexOS:*:* | convex:ConvexOS:C38*:*) echo c38-convex-bsd exit ;; C4*:ConvexOS:*:* | convex:ConvexOS:C4*:*) echo c4-convex-bsd exit ;; CRAY*Y-MP:*:*:*) echo ymp-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' exit ;; CRAY*[A-Z]90:*:*:*) echo ${UNAME_MACHINE}-cray-unicos${UNAME_RELEASE} \ | sed -e 's/CRAY.*\([A-Z]90\)/\1/' \ -e y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/ \ -e 's/\.[^.]*$/.X/' exit ;; CRAY*TS:*:*:*) echo t90-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' exit ;; CRAY*T3E:*:*:*) echo alphaev5-cray-unicosmk${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' exit ;; CRAY*SV1:*:*:*) echo sv1-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' exit ;; *:UNICOS/mp:*:*) echo craynv-cray-unicosmp${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' exit ;; F30[01]:UNIX_System_V:*:* | F700:UNIX_System_V:*:*) FUJITSU_PROC=`uname -m | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'` FUJITSU_REL=`echo ${UNAME_RELEASE} | sed -e 's/ /_/'` echo "${FUJITSU_PROC}-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" exit ;; 5000:UNIX_System_V:4.*:*) FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'` FUJITSU_REL=`echo ${UNAME_RELEASE} | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/ /_/'` echo "sparc-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" exit ;; i*86:BSD/386:*:* | i*86:BSD/OS:*:* | *:Ascend\ Embedded/OS:*:*) echo ${UNAME_MACHINE}-pc-bsdi${UNAME_RELEASE} exit ;; sparc*:BSD/OS:*:*) echo sparc-unknown-bsdi${UNAME_RELEASE} exit ;; *:BSD/OS:*:*) echo ${UNAME_MACHINE}-unknown-bsdi${UNAME_RELEASE} exit ;; *:FreeBSD:*:*) case ${UNAME_MACHINE} in pc98) echo i386-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;; amd64) echo x86_64-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;; *) echo ${UNAME_MACHINE}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;; esac exit ;; i*:CYGWIN*:*) echo ${UNAME_MACHINE}-pc-cygwin exit ;; *:MINGW*:*) echo ${UNAME_MACHINE}-pc-mingw32 exit ;; i*:windows32*:*) # uname -m includes "-pc" on this system. echo ${UNAME_MACHINE}-mingw32 exit ;; i*:PW*:*) echo ${UNAME_MACHINE}-pc-pw32 exit ;; *:Interix*:[3456]*) case ${UNAME_MACHINE} in x86) echo i586-pc-interix${UNAME_RELEASE} exit ;; EM64T | authenticamd | genuineintel) echo x86_64-unknown-interix${UNAME_RELEASE} exit ;; IA64) echo ia64-unknown-interix${UNAME_RELEASE} exit ;; esac ;; [345]86:Windows_95:* | [345]86:Windows_98:* | [345]86:Windows_NT:*) echo i${UNAME_MACHINE}-pc-mks exit ;; 8664:Windows_NT:*) echo x86_64-pc-mks exit ;; i*:Windows_NT*:* | Pentium*:Windows_NT*:*) # How do we know it's Interix rather than the generic POSIX subsystem? # It also conflicts with pre-2.0 versions of AT&T UWIN. Should we # UNAME_MACHINE based on the output of uname instead of i386? echo i586-pc-interix exit ;; i*:UWIN*:*) echo ${UNAME_MACHINE}-pc-uwin exit ;; amd64:CYGWIN*:*:* | x86_64:CYGWIN*:*:*) echo x86_64-unknown-cygwin exit ;; p*:CYGWIN*:*) echo powerpcle-unknown-cygwin exit ;; prep*:SunOS:5.*:*) echo powerpcle-unknown-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` exit ;; *:GNU:*:*) # the GNU system echo `echo ${UNAME_MACHINE}|sed -e 's,[-/].*$,,'`-unknown-gnu`echo ${UNAME_RELEASE}|sed -e 's,/.*$,,'` exit ;; *:GNU/*:*:*) # other systems with GNU libc and userland echo ${UNAME_MACHINE}-unknown-`echo ${UNAME_SYSTEM} | sed 's,^[^/]*/,,' | tr '[A-Z]' '[a-z]'``echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`-gnu exit ;; i*86:Minix:*:*) echo ${UNAME_MACHINE}-pc-minix exit ;; arm*:Linux:*:*) eval $set_cc_for_build if echo __ARM_EABI__ | $CC_FOR_BUILD -E - 2>/dev/null \ | grep -q __ARM_EABI__ then echo ${UNAME_MACHINE}-unknown-linux-gnu else echo ${UNAME_MACHINE}-unknown-linux-gnueabi fi exit ;; avr32*:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu exit ;; cris:Linux:*:*) echo cris-axis-linux-gnu exit ;; crisv32:Linux:*:*) echo crisv32-axis-linux-gnu exit ;; frv:Linux:*:*) echo frv-unknown-linux-gnu exit ;; ia64:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu exit ;; m32r*:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu exit ;; m68*:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu exit ;; mips:Linux:*:* | mips64:Linux:*:*) eval $set_cc_for_build sed 's/^ //' << EOF >$dummy.c #undef CPU #undef ${UNAME_MACHINE} #undef ${UNAME_MACHINE}el #if defined(__MIPSEL__) || defined(__MIPSEL) || defined(_MIPSEL) || defined(MIPSEL) CPU=${UNAME_MACHINE}el #else #if defined(__MIPSEB__) || defined(__MIPSEB) || defined(_MIPSEB) || defined(MIPSEB) CPU=${UNAME_MACHINE} #else CPU= #endif #endif EOF eval "`$CC_FOR_BUILD -E $dummy.c 2>/dev/null | sed -n ' /^CPU/{ s: ::g p }'`" test x"${CPU}" != x && { echo "${CPU}-unknown-linux-gnu"; exit; } ;; or32:Linux:*:*) echo or32-unknown-linux-gnu exit ;; ppc:Linux:*:*) echo powerpc-unknown-linux-gnu exit ;; ppc64:Linux:*:*) echo powerpc64-unknown-linux-gnu exit ;; alpha:Linux:*:*) case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' < /proc/cpuinfo` in EV5) UNAME_MACHINE=alphaev5 ;; EV56) UNAME_MACHINE=alphaev56 ;; PCA56) UNAME_MACHINE=alphapca56 ;; PCA57) UNAME_MACHINE=alphapca56 ;; EV6) UNAME_MACHINE=alphaev6 ;; EV67) UNAME_MACHINE=alphaev67 ;; EV68*) UNAME_MACHINE=alphaev68 ;; esac objdump --private-headers /bin/sh | grep -q ld.so.1 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 PA7*) echo hppa1.1-unknown-linux-gnu ;; PA8*) echo hppa2.0-unknown-linux-gnu ;; *) echo hppa-unknown-linux-gnu ;; esac exit ;; parisc64:Linux:*:* | hppa64:Linux:*:*) echo hppa64-unknown-linux-gnu exit ;; s390:Linux:*:* | s390x:Linux:*:*) echo ${UNAME_MACHINE}-ibm-linux exit ;; sh64*:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu exit ;; sh*:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu exit ;; sparc:Linux:*:* | sparc64:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu exit ;; vax:Linux:*:*) echo ${UNAME_MACHINE}-dec-linux-gnu exit ;; x86_64:Linux:*:*) echo x86_64-unknown-linux-gnu exit ;; xtensa*:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu exit ;; i*86:Linux:*:*) # The BFD linker knows what the default object file format is, so # first see if it will tell us. cd to the root directory to prevent # problems with other programs or directories called `ld' in the path. # Set LC_ALL=C to ensure ld outputs messages in English. ld_supported_targets=`cd /; LC_ALL=C ld --help 2>&1 \ | sed -ne '/supported targets:/!d s/[ ][ ]*/ /g s/.*supported targets: *// s/ .*// p'` case "$ld_supported_targets" in elf32-i386) TENTATIVE="${UNAME_MACHINE}-pc-linux-gnu" ;; esac # Determine whether the default compiler is a.out or elf eval $set_cc_for_build sed 's/^ //' << EOF >$dummy.c #include #ifdef __ELF__ # ifdef __GLIBC__ # if __GLIBC__ >= 2 LIBC=gnu # else LIBC=gnulibc1 # endif # else LIBC=gnulibc1 # endif #else #if defined(__INTEL_COMPILER) || defined(__PGI) || defined(__SUNPRO_C) || defined(__SUNPRO_CC) LIBC=gnu #else LIBC=gnuaout #endif #endif #ifdef __dietlibc__ LIBC=dietlibc #endif EOF eval "`$CC_FOR_BUILD -E $dummy.c 2>/dev/null | sed -n ' /^LIBC/{ s: ::g p }'`" test x"${LIBC}" != x && { echo "${UNAME_MACHINE}-pc-linux-${LIBC}" exit } test x"${TENTATIVE}" != x && { echo "${TENTATIVE}"; exit; } ;; i*86:DYNIX/ptx:4*:*) # ptx 4.0 does uname -s correctly, with DYNIX/ptx in there. # earlier versions are messed up and put the nodename in both # sysname and nodename. echo i386-sequent-sysv4 exit ;; i*86:UNIX_SV:4.2MP:2.*) # Unixware is an offshoot of SVR4, but it has its own version # number series starting with 2... # I am not positive that other SVR4 systems won't match this, # I just have to hope. -- rms. # Use sysv4.2uw... so that sysv4* matches it. echo ${UNAME_MACHINE}-pc-sysv4.2uw${UNAME_VERSION} exit ;; i*86:OS/2:*:*) # If we were able to find `uname', then EMX Unix compatibility # is probably installed. echo ${UNAME_MACHINE}-pc-os2-emx exit ;; i*86:XTS-300:*:STOP) echo ${UNAME_MACHINE}-unknown-stop exit ;; i*86:atheos:*:*) echo ${UNAME_MACHINE}-unknown-atheos exit ;; i*86:syllable:*:*) echo ${UNAME_MACHINE}-pc-syllable exit ;; i*86:LynxOS:2.*:* | i*86:LynxOS:3.[01]*:* | i*86:LynxOS:4.[02]*:*) echo i386-unknown-lynxos${UNAME_RELEASE} exit ;; i*86:*DOS:*:*) echo ${UNAME_MACHINE}-pc-msdosdjgpp exit ;; i*86:*:4.*:* | i*86:SYSTEM_V:4.*:*) UNAME_REL=`echo ${UNAME_RELEASE} | sed 's/\/MP$//'` if grep Novell /usr/include/link.h >/dev/null 2>/dev/null; then echo ${UNAME_MACHINE}-univel-sysv${UNAME_REL} else echo ${UNAME_MACHINE}-pc-sysv${UNAME_REL} fi exit ;; i*86:*:5:[678]*) # UnixWare 7.x, OpenUNIX and OpenServer 6. case `/bin/uname -X | grep "^Machine"` in *486*) UNAME_MACHINE=i486 ;; *Pentium) UNAME_MACHINE=i586 ;; *Pent*|*Celeron) UNAME_MACHINE=i686 ;; esac echo ${UNAME_MACHINE}-unknown-sysv${UNAME_RELEASE}${UNAME_SYSTEM}${UNAME_VERSION} exit ;; i*86:*:3.2:*) if test -f /usr/options/cb.name; then UNAME_REL=`sed -n 's/.*Version //p' /dev/null >/dev/null ; then UNAME_REL=`(/bin/uname -X|grep Release|sed -e 's/.*= //')` (/bin/uname -X|grep i80486 >/dev/null) && UNAME_MACHINE=i486 (/bin/uname -X|grep '^Machine.*Pentium' >/dev/null) \ && UNAME_MACHINE=i586 (/bin/uname -X|grep '^Machine.*Pent *II' >/dev/null) \ && UNAME_MACHINE=i686 (/bin/uname -X|grep '^Machine.*Pentium Pro' >/dev/null) \ && UNAME_MACHINE=i686 echo ${UNAME_MACHINE}-pc-sco$UNAME_REL else echo ${UNAME_MACHINE}-pc-sysv32 fi exit ;; 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 exit ;; Intel:Mach:3*:*) echo i386-pc-mach3 exit ;; paragon:*:*:*) echo i860-intel-osf1 exit ;; i860:*:4.*:*) # i860-SVR4 if grep Stardent /usr/include/sys/uadmin.h >/dev/null 2>&1 ; then echo i860-stardent-sysv${UNAME_RELEASE} # Stardent Vistra i860-SVR4 else # Add other i860-SVR4 vendors below as they are discovered. echo i860-unknown-sysv${UNAME_RELEASE} # Unknown i860-SVR4 fi exit ;; mini*:CTIX:SYS*5:*) # "miniframe" echo m68010-convergent-sysv exit ;; mc68k:UNIX:SYSTEM5:3.51m) echo m68k-convergent-sysv exit ;; M680?0:D-NIX:5.3:*) echo m68k-diab-dnix exit ;; M68*:*:R3V[5678]*:*) test -r /sysV68 && { echo 'm68k-motorola-sysv'; exit; } ;; 3[345]??:*:4.0:3.0 | 3[34]??A:*:4.0:3.0 | 3[34]??,*:*:4.0:3.0 | 3[34]??/*:*:4.0:3.0 | 4400:*:4.0:3.0 | 4850:*:4.0:3.0 | SKA40:*:4.0:3.0 | SDS2:*:4.0:3.0 | SHG2:*:4.0:3.0 | S7501*:*:4.0:3.0) OS_REL='' 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; } ;; 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 ;; mc68030:UNIX_System_V:4.*:*) echo m68k-atari-sysv4 exit ;; TSUNAMI:LynxOS:2.*:*) echo sparc-unknown-lynxos${UNAME_RELEASE} exit ;; rs6000:LynxOS:2.*:*) echo rs6000-unknown-lynxos${UNAME_RELEASE} exit ;; PowerPC:LynxOS:2.*:* | PowerPC:LynxOS:3.[01]*:* | PowerPC:LynxOS:4.[02]*:*) echo powerpc-unknown-lynxos${UNAME_RELEASE} exit ;; SM[BE]S:UNIX_SV:*:*) echo mips-dde-sysv${UNAME_RELEASE} exit ;; RM*:ReliantUNIX-*:*:*) echo mips-sni-sysv4 exit ;; RM*:SINIX-*:*:*) echo mips-sni-sysv4 exit ;; *:SINIX-*:*:*) if uname -p 2>/dev/null >/dev/null ; then UNAME_MACHINE=`(uname -p) 2>/dev/null` echo ${UNAME_MACHINE}-sni-sysv4 else echo ns32k-sni-sysv fi exit ;; PENTIUM:*:4.0*:*) # Unisys `ClearPath HMP IX 4000' SVR4/MP effort # says echo i586-unisys-sysv4 exit ;; *:UNIX_System_V:4*:FTX*) # From Gerald Hewes . # How about differentiating between stratus architectures? -djm echo hppa1.1-stratus-sysv4 exit ;; *:*:*:FTX*) # From seanf@swdc.stratus.com. echo i860-stratus-sysv4 exit ;; i*86:VOS:*:*) # From Paul.Green@stratus.com. echo ${UNAME_MACHINE}-stratus-vos exit ;; *:VOS:*:*) # From Paul.Green@stratus.com. echo hppa1.1-stratus-vos exit ;; mc68*:A/UX:*:*) echo m68k-apple-aux${UNAME_RELEASE} exit ;; news*:NEWS-OS:6*:*) echo mips-sony-newsos6 exit ;; R[34]000:*System_V*:*:* | R4000:UNIX_SYSV:*:* | R*000:UNIX_SV:*:*) if [ -d /usr/nec ]; then echo mips-nec-sysv${UNAME_RELEASE} else echo mips-unknown-sysv${UNAME_RELEASE} fi exit ;; BeBox:BeOS:*:*) # BeOS running on hardware made by Be, PPC only. echo powerpc-be-beos exit ;; BeMac:BeOS:*:*) # BeOS running on Mac or Mac clone, PPC only. echo powerpc-apple-beos exit ;; 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 ;; SX-5:SUPER-UX:*:*) echo sx5-nec-superux${UNAME_RELEASE} exit ;; SX-6:SUPER-UX:*:*) echo sx6-nec-superux${UNAME_RELEASE} exit ;; SX-7:SUPER-UX:*:*) echo sx7-nec-superux${UNAME_RELEASE} exit ;; SX-8:SUPER-UX:*:*) echo sx8-nec-superux${UNAME_RELEASE} exit ;; SX-8R:SUPER-UX:*:*) echo sx8r-nec-superux${UNAME_RELEASE} exit ;; Power*:Rhapsody:*:*) echo powerpc-apple-rhapsody${UNAME_RELEASE} exit ;; *:Rhapsody:*:*) echo ${UNAME_MACHINE}-apple-rhapsody${UNAME_RELEASE} exit ;; *:Darwin:*:*) UNAME_PROCESSOR=`uname -p` || UNAME_PROCESSOR=unknown case $UNAME_PROCESSOR in unknown) UNAME_PROCESSOR=powerpc ;; esac echo ${UNAME_PROCESSOR}-apple-darwin${UNAME_RELEASE} exit ;; *:procnto*:*:* | *:QNX:[0123456789]*:*) UNAME_PROCESSOR=`uname -p` if test "$UNAME_PROCESSOR" = "x86"; then UNAME_PROCESSOR=i386 UNAME_MACHINE=pc fi echo ${UNAME_PROCESSOR}-${UNAME_MACHINE}-nto-qnx${UNAME_RELEASE} exit ;; *:QNX:*:4*) echo i386-pc-qnx exit ;; NSE-?:NONSTOP_KERNEL:*:*) echo nse-tandem-nsk${UNAME_RELEASE} exit ;; NSR-?:NONSTOP_KERNEL:*:*) echo nsr-tandem-nsk${UNAME_RELEASE} exit ;; *:NonStop-UX:*:*) echo mips-compaq-nonstopux exit ;; BS2000:POSIX*:*:*) echo bs2000-siemens-sysv exit ;; DS/*:UNIX_System_V:*:*) echo ${UNAME_MACHINE}-${UNAME_SYSTEM}-${UNAME_RELEASE} exit ;; *:Plan9:*:*) # "uname -m" is not consistent, so use $cputype instead. 386 # is converted to i386 for consistency with other x86 # operating systems. if test "$cputype" = "386"; then UNAME_MACHINE=i386 else UNAME_MACHINE="$cputype" fi echo ${UNAME_MACHINE}-unknown-plan9 exit ;; *:TOPS-10:*:*) echo pdp10-unknown-tops10 exit ;; *:TENEX:*:*) echo pdp10-unknown-tenex exit ;; KS10:TOPS-20:*:* | KL10:TOPS-20:*:* | TYPE4:TOPS-20:*:*) echo pdp10-dec-tops20 exit ;; XKL-1:TOPS-20:*:* | TYPE5:TOPS-20:*:*) echo pdp10-xkl-tops20 exit ;; *:TOPS-20:*:*) echo pdp10-unknown-tops20 exit ;; *:ITS:*:*) echo pdp10-unknown-its exit ;; SEI:*:*:SEIUX) echo mips-sei-seiux${UNAME_RELEASE} exit ;; *:DragonFly:*:*) echo ${UNAME_MACHINE}-unknown-dragonfly`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` exit ;; *:*VMS:*:*) UNAME_MACHINE=`(uname -p) 2>/dev/null` case "${UNAME_MACHINE}" in A*) echo alpha-dec-vms ; exit ;; I*) echo ia64-dec-vms ; exit ;; V*) echo vax-dec-vms ; exit ;; esac ;; *:XENIX:*:SysV) echo i386-pc-xenix exit ;; i*86:skyos:*:*) echo ${UNAME_MACHINE}-pc-skyos`echo ${UNAME_RELEASE}` | sed -e 's/ .*$//' exit ;; 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 #echo "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" 1>&2 eval $set_cc_for_build cat >$dummy.c < # include #endif main () { #if defined (sony) #if defined (MIPSEB) /* BFD wants "bsd" instead of "newsos". Perhaps BFD should be changed, I don't know.... */ printf ("mips-sony-bsd\n"); exit (0); #else #include printf ("m68k-sony-newsos%s\n", #ifdef NEWSOS4 "4" #else "" #endif ); exit (0); #endif #endif #if defined (__arm) && defined (__acorn) && defined (__unix) printf ("arm-acorn-riscix\n"); exit (0); #endif #if defined (hp300) && !defined (hpux) printf ("m68k-hp-bsd\n"); exit (0); #endif #if defined (NeXT) #if !defined (__ARCHITECTURE__) #define __ARCHITECTURE__ "m68k" #endif int version; version=`(hostinfo | sed -n 's/.*NeXT Mach \([0-9]*\).*/\1/p') 2>/dev/null`; if (version < 4) printf ("%s-next-nextstep%d\n", __ARCHITECTURE__, version); else printf ("%s-next-openstep%d\n", __ARCHITECTURE__, version); exit (0); #endif #if defined (MULTIMAX) || defined (n16) #if defined (UMAXV) printf ("ns32k-encore-sysv\n"); exit (0); #else #if defined (CMU) printf ("ns32k-encore-mach\n"); exit (0); #else printf ("ns32k-encore-bsd\n"); exit (0); #endif #endif #endif #if defined (__386BSD__) printf ("i386-pc-bsd\n"); exit (0); #endif #if defined (sequent) #if defined (i386) printf ("i386-sequent-dynix\n"); exit (0); #endif #if defined (ns32000) printf ("ns32k-sequent-dynix\n"); exit (0); #endif #endif #if defined (_SEQUENT_) struct utsname un; uname(&un); if (strncmp(un.version, "V2", 2) == 0) { printf ("i386-sequent-ptx2\n"); exit (0); } if (strncmp(un.version, "V1", 2) == 0) { /* XXX is V1 correct? */ printf ("i386-sequent-ptx1\n"); exit (0); } printf ("i386-sequent-ptx\n"); exit (0); #endif #if defined (vax) # if !defined (ultrix) # include # if defined (BSD) # if BSD == 43 printf ("vax-dec-bsd4.3\n"); exit (0); # else # if BSD == 199006 printf ("vax-dec-bsd4.3reno\n"); exit (0); # else printf ("vax-dec-bsd\n"); exit (0); # endif # endif # else printf ("vax-dec-bsd\n"); exit (0); # endif # else printf ("vax-dec-ultrix\n"); exit (0); # endif #endif #if defined (alliant) && defined (i860) printf ("i860-alliant-bsd\n"); exit (0); #endif exit (1); } EOF $CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null && SYSTEM_NAME=`$dummy` && { echo "$SYSTEM_NAME"; exit; } # Apollos put the system type in the environment. test -d /usr/apollo && { echo ${ISP}-apollo-${SYSTYPE}; exit; } # Convex versions that predate uname can use getsysinfo(1) if [ -x /usr/convex/getsysinfo ] then case `getsysinfo -f cpu_type` in c1*) echo c1-convex-bsd exit ;; c2*) if getsysinfo -f scalar_acc then echo c32-convex-bsd else echo c2-convex-bsd fi exit ;; c34*) echo c34-convex-bsd exit ;; c38*) echo c38-convex-bsd exit ;; c4*) echo c4-convex-bsd exit ;; esac fi cat >&2 < in order to provide the needed information to handle your system. config.guess timestamp = $timestamp uname -m = `(uname -m) 2>/dev/null || echo unknown` uname -r = `(uname -r) 2>/dev/null || echo unknown` uname -s = `(uname -s) 2>/dev/null || echo unknown` uname -v = `(uname -v) 2>/dev/null || echo unknown` /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null` /bin/uname -X = `(/bin/uname -X) 2>/dev/null` hostinfo = `(hostinfo) 2>/dev/null` /bin/universe = `(/bin/universe) 2>/dev/null` /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null` /bin/arch = `(/bin/arch) 2>/dev/null` /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null` /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null` UNAME_MACHINE = ${UNAME_MACHINE} UNAME_RELEASE = ${UNAME_RELEASE} UNAME_SYSTEM = ${UNAME_SYSTEM} UNAME_VERSION = ${UNAME_VERSION} EOF exit 1 # Local variables: # eval: (add-hook 'write-file-hooks 'time-stamp) # time-stamp-start: "timestamp='" # time-stamp-format: "%:y-%02m-%02d" # time-stamp-end: "'" # End: rapache-1.2.8/tools/config.sub0000755000175100017510000010242512706745114015611 0ustar ondrejondrej#! /bin/sh # Configuration validation subroutine script. # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, # 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 # Free Software Foundation, Inc. timestamp='2009-06-11' # This file is (in principle) common to ALL GNU software. # The presence of a machine in this file suggests that SOME GNU software # can handle that machine. It does not imply ALL GNU software can. # # 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 # 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. # Please send patches to . Submit a context # diff and a properly formatted ChangeLog entry. # # Configuration subroutine to validate and canonicalize a configuration type. # Supply the specified configuration type as an argument. # If it is invalid, we print an error message on stderr and exit with code 1. # Otherwise, we print the canonical config type on stdout and succeed. # This file is supposed to be the same for all GNU packages # and recognize all the CPU types, system types and aliases # that are meaningful with *any* GNU software. # Each package is responsible for reporting which valid configurations # it does not support. The user should be able to distinguish # a failure to support a valid configuration from a meaningless # configuration. # The goal of this file is to map all the various variations of a given # machine specification into a single specification in the form: # CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM # or in some cases, the newer four-part form: # CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM # It is wrong to echo any other type of specification. me=`echo "$0" | sed -e 's,.*/,,'` usage="\ Usage: $0 [OPTION] CPU-MFR-OPSYS $0 [OPTION] ALIAS Canonicalize a configuration name. Operation modes: -h, --help print this help, then exit -t, --time-stamp print date of last modification, then exit -v, --version print version number, then exit Report bugs and patches to ." version="\ GNU config.sub ($timestamp) Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 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." help=" Try \`$me --help' for more information." # Parse command line while test $# -gt 0 ; do case $1 in --time-stamp | --time* | -t ) echo "$timestamp" ; exit ;; --version | -v ) echo "$version" ; exit ;; --help | --h* | -h ) echo "$usage"; exit ;; -- ) # Stop option processing shift; break ;; - ) # Use stdin as input. break ;; -* ) echo "$me: invalid option $1$help" exit 1 ;; *local*) # First pass through any local machine types. echo $1 exit ;; * ) break ;; esac done case $# in 0) echo "$me: missing argument$help" >&2 exit 1;; 1) ;; *) echo "$me: too many arguments$help" >&2 exit 1;; esac # Separate what the user gave into CPU-COMPANY and OS or KERNEL-OS (if any). # Here we must recognize all the valid KERNEL-OS combinations. 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/'` ;; *) basic_machine=`echo $1 | sed 's/-[^-]*$//'` if [ $basic_machine != $1 ] then os=`echo $1 | sed 's/.*-/-/'` else os=; fi ;; esac ### Let's recognize common machines as not being operating systems so ### that things like config.sub decstation-3100 work. We also ### recognize some manufacturers as not being operating systems, so we ### can provide default operating systems below. case $os in -sun*os*) # Prevent following clause from handling this invalid input. ;; -dec* | -mips* | -sequent* | -encore* | -pc532* | -sgi* | -sony* | \ -att* | -7300* | -3300* | -delta* | -motorola* | -sun[234]* | \ -unicom* | -ibm* | -next | -hp | -isi* | -apollo | -altos* | \ -convergent* | -ncr* | -news | -32* | -3600* | -3100* | -hitachi* |\ -c[123]* | -convex* | -sun | -crds | -omron* | -dg | -ultra | -tti* | \ -harris | -dolphin | -highlevel | -gould | -cbm | -ns | -masscomp | \ -apple | -axis | -knuth | -cray) os= basic_machine=$1 ;; -bluegene*) os=-cnk ;; -sim | -cisco | -oki | -wec | -winbond) os= basic_machine=$1 ;; -scout) ;; -wrs) os=-vxworks basic_machine=$1 ;; -chorusos*) os=-chorusos basic_machine=$1 ;; -chorusrdb) os=-chorusrdb basic_machine=$1 ;; -hiux*) os=-hiuxwe2 ;; -sco6) os=-sco5v6 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; -sco5) os=-sco3.2v5 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; -sco4) os=-sco3.2v4 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; -sco3.2.[4-9]*) os=`echo $os | sed -e 's/sco3.2./sco3.2v/'` basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; -sco3.2v[4-9]*) # Don't forget version if it is 3.2v4 or newer. basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; -sco5v6*) # Don't forget version if it is 3.2v4 or newer. basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; -sco*) os=-sco3.2v2 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; -udk*) basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; -isc) os=-isc2.2 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; -clix*) basic_machine=clipper-intergraph ;; -isc*) basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; -lynx*) os=-lynxos ;; -ptx*) basic_machine=`echo $1 | sed -e 's/86-.*/86-sequent/'` ;; -windowsnt*) os=`echo $os | sed -e 's/windowsnt/winnt/'` ;; -psos*) os=-psos ;; -mint | -mint[0-9]*) basic_machine=m68k-atari os=-mint ;; esac # Decode aliases for certain CPU-COMPANY combinations. case $basic_machine in # Recognize the basic CPU types without company name. # Some are omitted here because they have special meanings below. 1750a | 580 \ | a29k \ | alpha | alphaev[4-8] | alphaev56 | alphaev6[78] | alphapca5[67] \ | alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] | alpha64pca5[67] \ | am33_2.0 \ | arc | arm | arm[bl]e | arme[lb] | armv[2345] | armv[345][lb] | avr | avr32 \ | bfin \ | c4x | clipper \ | d10v | d30v | dlx | dsp16xx \ | fido | fr30 | frv \ | 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 \ | mips | mipsbe | mipseb | mipsel | mipsle \ | mips16 \ | mips64 | mips64el \ | mips64octeon | mips64octeonel \ | mips64orion | mips64orionel \ | mips64r5900 | mips64r5900el \ | mips64vr | mips64vrel \ | mips64vr4100 | mips64vr4100el \ | mips64vr4300 | mips64vr4300el \ | mips64vr5000 | mips64vr5000el \ | mips64vr5900 | mips64vr5900el \ | mipsisa32 | mipsisa32el \ | mipsisa32r2 | mipsisa32r2el \ | mipsisa64 | mipsisa64el \ | mipsisa64r2 | mipsisa64r2el \ | mipsisa64sb1 | mipsisa64sb1el \ | mipsisa64sr71k | mipsisa64sr71kel \ | mipstx39 | mipstx39el \ | mn10200 | mn10300 \ | moxie \ | mt \ | msp430 \ | nios | nios2 \ | ns16k | ns32k \ | or32 \ | pdp10 | pdp11 | pj | pjl \ | 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 \ | sh64 | sh64le \ | sparc | sparc64 | sparc64b | sparc64v | sparc86x | sparclet | sparclite \ | sparcv8 | sparcv9 | sparcv9b | sparcv9v \ | spu | strongarm \ | tahoe | thumb | tic4x | tic80 | tron \ | v850 | v850e \ | we32k \ | x86 | xc16x | xscale | xscalee[bl] | xstormy16 | xtensa \ | z8k | z80) basic_machine=$basic_machine-unknown ;; m6811 | m68hc11 | m6812 | m68hc12) # Motorola 68HC11/12. basic_machine=$basic_machine-unknown os=-none ;; m88110 | m680[12346]0 | m683?2 | m68360 | m5200 | v70 | w65 | z8k) ;; ms1) basic_machine=mt-unknown ;; # We use `pc' rather than `unknown' # because (1) that's what they normally are, and # (2) the word "unknown" tends to confuse beginning users. i*86 | x86_64) basic_machine=$basic_machine-pc ;; # Object if more than one company name word. *-*-*) echo Invalid configuration \`$1\': machine \`$basic_machine\' not recognized 1>&2 exit 1 ;; # Recognize the basic CPU types with company name. 580-* \ | a29k-* \ | alpha-* | alphaev[4-8]-* | alphaev56-* | alphaev6[78]-* \ | alpha64-* | alpha64ev[4-8]-* | alpha64ev56-* | alpha64ev6[78]-* \ | alphapca5[67]-* | alpha64pca5[67]-* | arc-* \ | arm-* | armbe-* | armle-* | armeb-* | armv*-* \ | avr-* | avr32-* \ | bfin-* | bs2000-* \ | c[123]* | c30-* | [cjt]90-* | c4x-* | c54x-* | c55x-* | c6x-* \ | clipper-* | craynv-* | cydra-* \ | d10v-* | d30v-* | dlx-* \ | elxsi-* \ | f30[01]-* | f700-* | fido-* | fr30-* | frv-* | fx80-* \ | h8300-* | h8500-* \ | 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-* \ | mips-* | mipsbe-* | mipseb-* | mipsel-* | mipsle-* \ | mips16-* \ | mips64-* | mips64el-* \ | mips64octeon-* | mips64octeonel-* \ | mips64orion-* | mips64orionel-* \ | mips64r5900-* | mips64r5900el-* \ | mips64vr-* | mips64vrel-* \ | mips64vr4100-* | mips64vr4100el-* \ | mips64vr4300-* | mips64vr4300el-* \ | mips64vr5000-* | mips64vr5000el-* \ | mips64vr5900-* | mips64vr5900el-* \ | mipsisa32-* | mipsisa32el-* \ | mipsisa32r2-* | mipsisa32r2el-* \ | mipsisa64-* | mipsisa64el-* \ | mipsisa64r2-* | mipsisa64r2el-* \ | mipsisa64sb1-* | mipsisa64sb1el-* \ | mipsisa64sr71k-* | mipsisa64sr71kel-* \ | mipstx39-* | mipstx39el-* \ | mmix-* \ | mt-* \ | msp430-* \ | nios-* | nios2-* \ | none-* | np1-* | ns16k-* | ns32k-* \ | orion-* \ | pdp10-* | pdp11-* | pj-* | pjl-* | pn-* | power-* \ | 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-* \ | 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-* \ | tron-* \ | v850-* | v850e-* | vax-* \ | we32k-* \ | x86-* | x86_64-* | xc16x-* | xps100-* | xscale-* | xscalee[bl]-* \ | xstormy16-* | xtensa*-* \ | ymp-* \ | z8k-* | z80-*) ;; # Recognize the basic CPU types without company name, with glob match. xtensa*) basic_machine=$basic_machine-unknown ;; # Recognize the various machine names and aliases which stand # for a CPU type and a company and sometimes even an OS. 386bsd) basic_machine=i386-unknown os=-bsd ;; 3b1 | 7300 | 7300-att | att-7300 | pc7300 | safari | unixpc) basic_machine=m68000-att ;; 3b*) basic_machine=we32k-att ;; a29khif) basic_machine=a29k-amd os=-udi ;; abacus) basic_machine=abacus-unknown ;; adobe68k) basic_machine=m68010-adobe os=-scout ;; alliant | fx80) basic_machine=fx80-alliant ;; altos | altos3068) basic_machine=m68k-altos ;; am29k) basic_machine=a29k-none os=-bsd ;; amd64) basic_machine=x86_64-pc ;; amd64-*) basic_machine=x86_64-`echo $basic_machine | sed 's/^[^-]*-//'` ;; amdahl) basic_machine=580-amdahl os=-sysv ;; amiga | amiga-*) basic_machine=m68k-unknown ;; amigaos | amigados) basic_machine=m68k-unknown os=-amigaos ;; amigaunix | amix) basic_machine=m68k-unknown os=-sysv4 ;; apollo68) basic_machine=m68k-apollo os=-sysv ;; apollo68bsd) basic_machine=m68k-apollo os=-bsd ;; aros) basic_machine=i386-pc os=-aros ;; aux) basic_machine=m68k-apple os=-aux ;; balance) basic_machine=ns32k-sequent os=-dynix ;; blackfin) basic_machine=bfin-unknown os=-linux ;; blackfin-*) basic_machine=bfin-`echo $basic_machine | sed 's/^[^-]*-//'` os=-linux ;; bluegene*) basic_machine=powerpc-ibm os=-cnk ;; c90) basic_machine=c90-cray os=-unicos ;; cegcc) basic_machine=arm-unknown os=-cegcc ;; convex-c1) basic_machine=c1-convex os=-bsd ;; convex-c2) basic_machine=c2-convex os=-bsd ;; convex-c32) basic_machine=c32-convex os=-bsd ;; convex-c34) basic_machine=c34-convex os=-bsd ;; convex-c38) basic_machine=c38-convex os=-bsd ;; cray | j90) basic_machine=j90-cray os=-unicos ;; craynv) basic_machine=craynv-cray os=-unicosmp ;; cr16) basic_machine=cr16-unknown os=-elf ;; crds | unos) basic_machine=m68k-crds ;; crisv32 | crisv32-* | etraxfs*) basic_machine=crisv32-axis ;; cris | cris-* | etrax*) basic_machine=cris-axis ;; crx) basic_machine=crx-unknown os=-elf ;; da30 | da30-*) basic_machine=m68k-da30 ;; decstation | decstation-3100 | pmax | pmax-* | pmin | dec3100 | decstatn) basic_machine=mips-dec ;; decsystem10* | dec10*) basic_machine=pdp10-dec os=-tops10 ;; decsystem20* | dec20*) basic_machine=pdp10-dec os=-tops20 ;; delta | 3300 | motorola-3300 | motorola-delta \ | 3300-motorola | delta-motorola) basic_machine=m68k-motorola ;; delta88) basic_machine=m88k-motorola os=-sysv3 ;; dicos) basic_machine=i686-pc os=-dicos ;; djgpp) basic_machine=i586-pc os=-msdosdjgpp ;; dpx20 | dpx20-*) basic_machine=rs6000-bull os=-bosx ;; dpx2* | dpx2*-bull) basic_machine=m68k-bull os=-sysv3 ;; ebmon29k) basic_machine=a29k-amd os=-ebmon ;; elxsi) basic_machine=elxsi-elxsi os=-bsd ;; encore | umax | mmax) basic_machine=ns32k-encore ;; es1800 | OSE68k | ose68k | ose | OSE) basic_machine=m68k-ericsson os=-ose ;; fx2800) basic_machine=i860-alliant ;; genix) basic_machine=ns32k-ns ;; gmicro) basic_machine=tron-gmicro os=-sysv ;; go32) basic_machine=i386-pc os=-go32 ;; h3050r* | hiux*) basic_machine=hppa1.1-hitachi os=-hiuxwe2 ;; h8300hms) basic_machine=h8300-hitachi os=-hms ;; h8300xray) basic_machine=h8300-hitachi os=-xray ;; h8500hms) basic_machine=h8500-hitachi os=-hms ;; harris) basic_machine=m88k-harris os=-sysv3 ;; hp300-*) basic_machine=m68k-hp ;; hp300bsd) basic_machine=m68k-hp os=-bsd ;; hp300hpux) basic_machine=m68k-hp os=-hpux ;; hp3k9[0-9][0-9] | hp9[0-9][0-9]) basic_machine=hppa1.0-hp ;; hp9k2[0-9][0-9] | hp9k31[0-9]) basic_machine=m68000-hp ;; hp9k3[2-9][0-9]) basic_machine=m68k-hp ;; hp9k6[0-9][0-9] | hp6[0-9][0-9]) basic_machine=hppa1.0-hp ;; hp9k7[0-79][0-9] | hp7[0-79][0-9]) basic_machine=hppa1.1-hp ;; hp9k78[0-9] | hp78[0-9]) # FIXME: really hppa2.0-hp basic_machine=hppa1.1-hp ;; hp9k8[67]1 | hp8[67]1 | hp9k80[24] | hp80[24] | hp9k8[78]9 | hp8[78]9 | hp9k893 | hp893) # FIXME: really hppa2.0-hp basic_machine=hppa1.1-hp ;; hp9k8[0-9][13679] | hp8[0-9][13679]) basic_machine=hppa1.1-hp ;; hp9k8[0-9][0-9] | hp8[0-9][0-9]) basic_machine=hppa1.0-hp ;; hppa-next) os=-nextstep3 ;; hppaosf) basic_machine=hppa1.1-hp os=-osf ;; hppro) basic_machine=hppa1.1-hp os=-proelf ;; i370-ibm* | ibm*) basic_machine=i370-ibm ;; # I'm not sure what "Sysv32" means. Should this be sysv3.2? i*86v32) basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` os=-sysv32 ;; i*86v4*) basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` os=-sysv4 ;; i*86v) basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` os=-sysv ;; i*86sol2) basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` os=-solaris2 ;; i386mach) basic_machine=i386-mach os=-mach ;; i386-vsta | vsta) basic_machine=i386-unknown os=-vsta ;; iris | iris4d) basic_machine=mips-sgi case $os in -irix*) ;; *) os=-irix4 ;; esac ;; isi68 | isi) basic_machine=m68k-isi os=-sysv ;; m68knommu) basic_machine=m68k-unknown os=-linux ;; m68knommu-*) basic_machine=m68k-`echo $basic_machine | sed 's/^[^-]*-//'` os=-linux ;; m88k-omron*) basic_machine=m88k-omron ;; magnum | m3230) basic_machine=mips-mips os=-sysv ;; merlin) basic_machine=ns32k-utek os=-sysv ;; mingw32) basic_machine=i386-pc os=-mingw32 ;; mingw32ce) basic_machine=arm-unknown os=-mingw32ce ;; miniframe) basic_machine=m68000-convergent ;; *mint | -mint[0-9]* | *MiNT | *MiNT[0-9]*) basic_machine=m68k-atari os=-mint ;; mips3*-*) basic_machine=`echo $basic_machine | sed -e 's/mips3/mips64/'` ;; mips3*) basic_machine=`echo $basic_machine | sed -e 's/mips3/mips64/'`-unknown ;; monitor) basic_machine=m68k-rom68k os=-coff ;; morphos) basic_machine=powerpc-unknown os=-morphos ;; msdos) basic_machine=i386-pc os=-msdos ;; ms1-*) basic_machine=`echo $basic_machine | sed -e 's/ms1-/mt-/'` ;; mvs) basic_machine=i370-ibm os=-mvs ;; ncr3000) basic_machine=i486-ncr os=-sysv4 ;; netbsd386) basic_machine=i386-unknown os=-netbsd ;; netwinder) basic_machine=armv4l-rebel os=-linux ;; news | news700 | news800 | news900) basic_machine=m68k-sony os=-newsos ;; news1000) basic_machine=m68030-sony os=-newsos ;; news-3600 | risc-news) basic_machine=mips-sony os=-newsos ;; necv70) basic_machine=v70-nec os=-sysv ;; next | m*-next ) basic_machine=m68k-next case $os in -nextstep* ) ;; -ns2*) os=-nextstep2 ;; *) os=-nextstep3 ;; esac ;; nh3000) basic_machine=m68k-harris os=-cxux ;; nh[45]000) basic_machine=m88k-harris os=-cxux ;; nindy960) basic_machine=i960-intel os=-nindy ;; mon960) basic_machine=i960-intel os=-mon960 ;; nonstopux) basic_machine=mips-compaq os=-nonstopux ;; np1) basic_machine=np1-gould ;; nsr-tandem) basic_machine=nsr-tandem ;; op50n-* | op60c-*) basic_machine=hppa1.1-oki os=-proelf ;; openrisc | openrisc-*) basic_machine=or32-unknown ;; os400) basic_machine=powerpc-ibm os=-os400 ;; OSE68000 | ose68000) basic_machine=m68000-ericsson os=-ose ;; os68k) basic_machine=m68k-none os=-os68k ;; pa-hitachi) basic_machine=hppa1.1-hitachi os=-hiuxwe2 ;; paragon) basic_machine=i860-intel os=-osf ;; parisc) basic_machine=hppa-unknown os=-linux ;; parisc-*) basic_machine=hppa-`echo $basic_machine | sed 's/^[^-]*-//'` os=-linux ;; pbd) basic_machine=sparc-tti ;; pbb) basic_machine=m68k-tti ;; pc532 | pc532-*) basic_machine=ns32k-pc532 ;; pc98) basic_machine=i386-pc ;; pc98-*) basic_machine=i386-`echo $basic_machine | sed 's/^[^-]*-//'` ;; pentium | p5 | k5 | k6 | nexgen | viac3) basic_machine=i586-pc ;; pentiumpro | p6 | 6x86 | athlon | athlon_*) basic_machine=i686-pc ;; pentiumii | pentium2 | pentiumiii | pentium3) basic_machine=i686-pc ;; pentium4) basic_machine=i786-pc ;; pentium-* | p5-* | k5-* | k6-* | nexgen-* | viac3-*) basic_machine=i586-`echo $basic_machine | sed 's/^[^-]*-//'` ;; pentiumpro-* | p6-* | 6x86-* | athlon-*) basic_machine=i686-`echo $basic_machine | sed 's/^[^-]*-//'` ;; pentiumii-* | pentium2-* | pentiumiii-* | pentium3-*) basic_machine=i686-`echo $basic_machine | sed 's/^[^-]*-//'` ;; pentium4-*) basic_machine=i786-`echo $basic_machine | sed 's/^[^-]*-//'` ;; pn) basic_machine=pn-gould ;; power) basic_machine=power-ibm ;; ppc) basic_machine=powerpc-unknown ;; ppc-*) basic_machine=powerpc-`echo $basic_machine | sed 's/^[^-]*-//'` ;; ppcle | powerpclittle | ppc-le | powerpc-little) basic_machine=powerpcle-unknown ;; ppcle-* | powerpclittle-*) basic_machine=powerpcle-`echo $basic_machine | sed 's/^[^-]*-//'` ;; ppc64) basic_machine=powerpc64-unknown ;; ppc64-*) basic_machine=powerpc64-`echo $basic_machine | sed 's/^[^-]*-//'` ;; ppc64le | powerpc64little | ppc64-le | powerpc64-little) basic_machine=powerpc64le-unknown ;; ppc64le-* | powerpc64little-*) basic_machine=powerpc64le-`echo $basic_machine | sed 's/^[^-]*-//'` ;; ps2) basic_machine=i386-ibm ;; pw32) basic_machine=i586-unknown os=-pw32 ;; rdos) basic_machine=i386-pc os=-rdos ;; rom68k) basic_machine=m68k-rom68k os=-coff ;; rm[46]00) basic_machine=mips-siemens ;; rtpc | rtpc-*) basic_machine=romp-ibm ;; s390 | s390-*) basic_machine=s390-ibm ;; s390x | s390x-*) basic_machine=s390x-ibm ;; sa29200) basic_machine=a29k-amd os=-udi ;; sb1) basic_machine=mipsisa64sb1-unknown ;; sb1el) basic_machine=mipsisa64sb1el-unknown ;; sde) basic_machine=mipsisa32-sde os=-elf ;; sei) basic_machine=mips-sei os=-seiux ;; sequent) basic_machine=i386-sequent ;; sh) basic_machine=sh-hitachi os=-hms ;; sh5el) basic_machine=sh5le-unknown ;; sh64) basic_machine=sh64-unknown ;; sparclite-wrs | simso-wrs) basic_machine=sparclite-wrs os=-vxworks ;; sps7) basic_machine=m68k-bull os=-sysv2 ;; spur) basic_machine=spur-unknown ;; st2000) basic_machine=m68k-tandem ;; stratus) basic_machine=i860-stratus os=-sysv4 ;; sun2) basic_machine=m68000-sun ;; sun2os3) basic_machine=m68000-sun os=-sunos3 ;; sun2os4) basic_machine=m68000-sun os=-sunos4 ;; sun3os3) basic_machine=m68k-sun os=-sunos3 ;; sun3os4) basic_machine=m68k-sun os=-sunos4 ;; sun4os3) basic_machine=sparc-sun os=-sunos3 ;; sun4os4) basic_machine=sparc-sun os=-sunos4 ;; sun4sol2) basic_machine=sparc-sun os=-solaris2 ;; sun3 | sun3-*) basic_machine=m68k-sun ;; sun4) basic_machine=sparc-sun ;; sun386 | sun386i | roadrunner) basic_machine=i386-sun ;; sv1) basic_machine=sv1-cray os=-unicos ;; symmetry) basic_machine=i386-sequent os=-dynix ;; t3e) basic_machine=alphaev5-cray os=-unicos ;; t90) basic_machine=t90-cray os=-unicos ;; tic54x | c54x*) basic_machine=tic54x-unknown os=-coff ;; tic55x | c55x*) basic_machine=tic55x-unknown os=-coff ;; tic6x | c6x*) basic_machine=tic6x-unknown os=-coff ;; tile*) basic_machine=tile-unknown os=-linux-gnu ;; tx39) basic_machine=mipstx39-unknown ;; tx39el) basic_machine=mipstx39el-unknown ;; toad1) basic_machine=pdp10-xkl os=-tops20 ;; tower | tower-32) basic_machine=m68k-ncr ;; tpf) basic_machine=s390x-ibm os=-tpf ;; udi29k) basic_machine=a29k-amd os=-udi ;; ultra3) basic_machine=a29k-nyu os=-sym1 ;; v810 | necv810) basic_machine=v810-nec os=-none ;; vaxv) basic_machine=vax-dec os=-sysv ;; vms) basic_machine=vax-dec os=-vms ;; vpp*|vx|vx-*) basic_machine=f301-fujitsu ;; vxworks960) basic_machine=i960-wrs os=-vxworks ;; vxworks68) basic_machine=m68k-wrs os=-vxworks ;; vxworks29k) basic_machine=a29k-wrs os=-vxworks ;; w65*) basic_machine=w65-wdc os=-none ;; w89k-*) basic_machine=hppa1.1-winbond os=-proelf ;; xbox) basic_machine=i686-pc os=-mingw32 ;; xps | xps100) basic_machine=xps100-honeywell ;; ymp) basic_machine=ymp-cray os=-unicos ;; z8k-*-coff) basic_machine=z8k-unknown os=-sim ;; z80-*-coff) basic_machine=z80-unknown os=-sim ;; none) basic_machine=none-none os=-none ;; # Here we handle the default manufacturer of certain CPU types. It is in # some cases the only manufacturer, in others, it is the most popular. w89k) basic_machine=hppa1.1-winbond ;; op50n) basic_machine=hppa1.1-oki ;; op60c) basic_machine=hppa1.1-oki ;; romp) basic_machine=romp-ibm ;; mmix) basic_machine=mmix-knuth ;; rs6000) basic_machine=rs6000-ibm ;; vax) basic_machine=vax-dec ;; pdp10) # there are many clones, so DEC is not a safe bet basic_machine=pdp10-unknown ;; pdp11) basic_machine=pdp11-dec ;; we32k) basic_machine=we32k-att ;; sh[1234] | sh[24]a | sh[24]aeb | sh[34]eb | sh[1234]le | sh[23]ele) basic_machine=sh-unknown ;; sparc | sparcv8 | sparcv9 | sparcv9b | sparcv9v) basic_machine=sparc-sun ;; cydra) basic_machine=cydra-cydrome ;; orion) basic_machine=orion-highlevel ;; orion105) basic_machine=clipper-highlevel ;; mac | mpw | mac-mpw) basic_machine=m68k-apple ;; pmac | pmac-mpw) basic_machine=powerpc-apple ;; *-unknown) # Make sure to match an already-canonicalized machine name. ;; *) echo Invalid configuration \`$1\': machine \`$basic_machine\' not recognized 1>&2 exit 1 ;; esac # Here we canonicalize certain aliases for manufacturers. case $basic_machine in *-digital*) basic_machine=`echo $basic_machine | sed 's/digital.*/dec/'` ;; *-commodore*) basic_machine=`echo $basic_machine | sed 's/commodore.*/cbm/'` ;; *) ;; esac # Decode manufacturer-specific aliases for certain operating systems. if [ x"$os" != x"" ] then case $os in # First match some system type aliases # that might get confused with valid system types. # -solaris* is a basic system type, with this one exception. -solaris1 | -solaris1.*) os=`echo $os | sed -e 's|solaris1|sunos4|'` ;; -solaris) os=-solaris2 ;; -svr4*) os=-sysv4 ;; -unixware*) os=-sysv4.2uw ;; -gnu/linux*) os=`echo $os | sed -e 's|gnu/linux|linux-gnu|'` ;; # First accept the basic system types. # The portable systems comes first. # Each alternative MUST END IN A *, to match a version number. # -sysv* is not here because it comes later, after sysvr4. -gnu* | -bsd* | -mach* | -minix* | -genix* | -ultrix* | -irix* \ | -*vms* | -sco* | -esix* | -isc* | -aix* | -cnk* | -sunos | -sunos[34]*\ | -hpux* | -unos* | -osf* | -luna* | -dgux* | -solaris* | -sym* \ | -kopensolaris* \ | -amigaos* | -amigados* | -msdos* | -newsos* | -unicos* | -aof* \ | -aos* | -aros* \ | -nindy* | -vxsim* | -vxworks* | -ebmon* | -hms* | -mvs* \ | -clix* | -riscos* | -uniplus* | -iris* | -rtu* | -xenix* \ | -hiux* | -386bsd* | -knetbsd* | -mirbsd* | -netbsd* \ | -openbsd* | -solidbsd* \ | -ekkobsd* | -kfreebsd* | -freebsd* | -riscix* | -lynxos* \ | -bosx* | -nextstep* | -cxux* | -aout* | -elf* | -oabi* \ | -ptx* | -coff* | -ecoff* | -winnt* | -domain* | -vsta* \ | -udi* | -eabi* | -lites* | -ieee* | -go32* | -aux* \ | -chorusos* | -chorusrdb* | -cegcc* \ | -cygwin* | -pe* | -psos* | -moss* | -proelf* | -rtems* \ | -mingw32* | -linux-gnu* | -linux-newlib* | -linux-uclibc* \ | -uxpv* | -beos* | -mpeix* | -udk* \ | -interix* | -uwin* | -mks* | -rhapsody* | -darwin* | -opened* \ | -openstep* | -oskit* | -conix* | -pw32* | -nonstopux* \ | -storm-chaos* | -tops10* | -tenex* | -tops20* | -its* \ | -os2* | -vos* | -palmos* | -uclinux* | -nucleus* \ | -morphos* | -superux* | -rtmk* | -rtmk-nova* | -windiss* \ | -powermax* | -dnix* | -nx6 | -nx7 | -sei* | -dragonfly* \ | -skyos* | -haiku* | -rdos* | -toppers* | -drops*) # Remember, each alternative MUST END IN *, to match a version number. ;; -qnx*) case $basic_machine in x86-* | i*86-*) ;; *) os=-nto$os ;; esac ;; -nto-qnx*) ;; -nto*) os=`echo $os | sed -e 's|nto|nto-qnx|'` ;; -sim | -es1800* | -hms* | -xray | -os68k* | -none* | -v88r* \ | -windows* | -osx | -abug | -netware* | -os9* | -beos* | -haiku* \ | -macos* | -mpw* | -magic* | -mmixware* | -mon960* | -lnews*) ;; -mac*) os=`echo $os | sed -e 's|mac|macos|'` ;; -linux-dietlibc) os=-linux-dietlibc ;; -linux*) os=`echo $os | sed -e 's|linux|linux-gnu|'` ;; -sunos5*) os=`echo $os | sed -e 's|sunos5|solaris2|'` ;; -sunos6*) os=`echo $os | sed -e 's|sunos6|solaris3|'` ;; -opened*) os=-openedition ;; -os400*) os=-os400 ;; -wince*) os=-wince ;; -osfrose*) os=-osfrose ;; -osf*) os=-osf ;; -utek*) os=-bsd ;; -dynix*) os=-bsd ;; -acis*) os=-aos ;; -atheos*) os=-atheos ;; -syllable*) os=-syllable ;; -386bsd) os=-bsd ;; -ctix* | -uts*) os=-sysv ;; -nova*) os=-rtmk-nova ;; -ns2 ) os=-nextstep2 ;; -nsk*) os=-nsk ;; # Preserve the version number of sinix5. -sinix5.*) os=`echo $os | sed -e 's|sinix|sysv|'` ;; -sinix*) os=-sysv4 ;; -tpf*) os=-tpf ;; -triton*) os=-sysv3 ;; -oss*) os=-sysv3 ;; -svr4) os=-sysv4 ;; -svr3) os=-sysv3 ;; -sysvr4) os=-sysv4 ;; # This must come after -sysvr4. -sysv*) ;; -ose*) os=-ose ;; -es1800*) os=-ose ;; -xenix) os=-xenix ;; -*mint | -mint[0-9]* | -*MiNT | -MiNT[0-9]*) os=-mint ;; -aros*) os=-aros ;; -kaos*) os=-kaos ;; -zvmoe) os=-zvmoe ;; -dicos*) os=-dicos ;; -none) ;; *) # Get rid of the `-' at the beginning of $os. os=`echo $os | sed 's/[^-]*-//'` echo Invalid configuration \`$1\': system \`$os\' not recognized 1>&2 exit 1 ;; esac else # Here we handle the default operating systems that come with various machines. # The value should be what the vendor currently ships out the door with their # machine or put another way, the most popular os provided with the machine. # Note that if you're going to try to match "-MANUFACTURER" here (say, # "-sun"), then you have to tell the case statement up towards the top # that MANUFACTURER isn't an operating system. Otherwise, code above # will signal an error saying that MANUFACTURER isn't an operating # system, and we'll never get to this point. case $basic_machine in score-*) os=-elf ;; spu-*) os=-elf ;; *-acorn) os=-riscix1.2 ;; arm*-rebel) os=-linux ;; arm*-semi) os=-aout ;; c4x-* | tic4x-*) os=-coff ;; # This must come before the *-dec entry. pdp10-*) os=-tops20 ;; pdp11-*) os=-none ;; *-dec | vax-*) os=-ultrix4.2 ;; m68*-apollo) os=-domain ;; i386-sun) os=-sunos4.0.2 ;; m68000-sun) os=-sunos3 # This also exists in the configure program, but was not the # default. # os=-sunos4 ;; m68*-cisco) os=-aout ;; mep-*) os=-elf ;; mips*-cisco) os=-elf ;; mips*-*) os=-elf ;; or32-*) os=-coff ;; *-tti) # must be before sparc entry or we get the wrong os. os=-sysv3 ;; sparc-* | *-sun) os=-sunos4.1.1 ;; *-be) os=-beos ;; *-haiku) os=-haiku ;; *-ibm) os=-aix ;; *-knuth) os=-mmixware ;; *-wec) os=-proelf ;; *-winbond) os=-proelf ;; *-oki) os=-proelf ;; *-hp) os=-hpux ;; *-hitachi) os=-hiux ;; i860-* | *-att | *-ncr | *-altos | *-motorola | *-convergent) os=-sysv ;; *-cbm) os=-amigaos ;; *-dg) os=-dgux ;; *-dolphin) os=-sysv3 ;; m68k-ccur) os=-rtu ;; m88k-omron*) os=-luna ;; *-next ) os=-nextstep ;; *-sequent) os=-ptx ;; *-crds) os=-unos ;; *-ns) os=-genix ;; i370-*) os=-mvs ;; *-next) os=-nextstep3 ;; *-gould) os=-sysv ;; *-highlevel) os=-bsd ;; *-encore) os=-bsd ;; *-sgi) os=-irix ;; *-siemens) os=-sysv4 ;; *-masscomp) os=-rtu ;; f30[01]-fujitsu | f700-fujitsu) os=-uxpv ;; *-rom68k) os=-coff ;; *-*bug) os=-coff ;; *-apple) os=-macos ;; *-atari*) os=-mint ;; *) os=-none ;; esac fi # Here we handle the case where we know the os, and the CPU type, but not the # manufacturer. We pick the logical manufacturer. vendor=unknown case $basic_machine in *-unknown) case $os in -riscix*) vendor=acorn ;; -sunos*) vendor=sun ;; -cnk*|-aix*) vendor=ibm ;; -beos*) vendor=be ;; -hpux*) vendor=hp ;; -mpeix*) vendor=hp ;; -hiux*) vendor=hitachi ;; -unos*) vendor=crds ;; -dgux*) vendor=dg ;; -luna*) vendor=omron ;; -genix*) vendor=ns ;; -mvs* | -opened*) vendor=ibm ;; -os400*) vendor=ibm ;; -ptx*) vendor=sequent ;; -tpf*) vendor=ibm ;; -vxsim* | -vxworks* | -windiss*) vendor=wrs ;; -aux*) vendor=apple ;; -hms*) vendor=hitachi ;; -mpw* | -macos*) vendor=apple ;; -*mint | -mint[0-9]* | -*MiNT | -MiNT[0-9]*) vendor=atari ;; -vos*) vendor=stratus ;; esac basic_machine=`echo $basic_machine | sed "s/unknown/$vendor/"` ;; esac echo $basic_machine$os exit # Local variables: # eval: (add-hook 'write-file-hooks 'time-stamp) # time-stamp-start: "timestamp='" # time-stamp-format: "%:y-%02m-%02d" # time-stamp-end: "'" # End: rapache-1.2.8/tools/config_http.R0000644000175100017510000000414012706745114016250 0ustar ondrejondrejAPXS <- commandArgs(trailingOnly=TRUE)[1] HTTPD <- commandArgs(trailingOnly=TRUE)[2] options(warn=-1) NextAvailablePort <- function(){ start <- 8181 while(TRUE){ if (start >= 65536) return(0) con <- try(socketConnection(port=start),silent=TRUE) if (inherits(con,'try-error')){ return(start) } close(con) start <- start + 1 } } # # Variables that will get replaced in httpd.conf.in # DOCROOT <- paste(getwd(),'/test',sep='') PORT <- NextAvailablePort() BREWINSTALLED <- 'brew' %in% .packages(all.available=TRUE) unlink('test/httpd.conf') con <- file('test/httpd.conf',open='w+') lines <- readLines('test/httpd.conf.in') if (BREWINSTALLED){ lines <- append(lines,c( '\n', ' SetHandler r-script\n', ' RHandler brew::brew\n', '\n') ) } lines <- gsub('@PORT@',PORT,lines) lines <- gsub('@DOCROOT@',DOCROOT,lines) writeLines(lines,con) close(con) unlink('test/confs/load_modules') # Test if dir module is compiled into httpd if (length(grep('dir',readLines(pipe(paste(HTTPD,'-l')))))==0){ # No, we need to add it. grab LIBEXECDIR con <- file('test/confs/load_modules',open='a') libexecdir <- readLines(pipe(paste(APXS,'-q LIBEXECDIR')))[1] cat('LoadModule dir_module ',libexecdir,'/mod_dir.so\n',sep='',file=con) close(con) } else { print('mod_dir built in') } # Test if log_config module is compiled into httpd if (length(grep('log_config',readLines(pipe(paste(HTTPD,'-l')))))==0){ # No, we need to add it. grab LIBEXECDIR con <- file('test/confs/load_modules',open='a') libexecdir <- readLines(pipe(paste(APXS,'-q LIBEXECDIR')))[1] cat('LoadModule log_config_module ',libexecdir,'/mod_log_config.so\n',sep='',file=con) close(con) } else { print('mod_log_config built in') } # Test if mime module is compiled into httpd if (length(grep('mime',readLines(pipe(paste(HTTPD,'-l')))))==0){ # No, we need to add it. grab LIBEXECDIR con <- file('test/confs/load_modules',open='a') libexecdir <- readLines(pipe(paste(APXS,'-q LIBEXECDIR')))[1] cat('LoadModule mime_module ',libexecdir,'/mod_mime.so\n',sep='',file=con) close(con) } else { print('mod_mime built in') } rapache-1.2.8/tools/create_tarball_release0000755000175100017510000000055012706745114020214 0ustar ondrejondrej#!/bin/bash # Call this from the top level dir like so: # ./tools/create_tarball_release # Will create the tarball in the top level dir MOD_R_VERSION=`grep "define MOD_R_VERSION" mod_R.c | awk '{print $3}' | tr -d \"` echo creating version $MOD_R_VERSION git archive --format=tar --prefix=rapache-${MOD_R_VERSION}/ HEAD | gzip >rapache-${MOD_R_VERSION}.tar.gz rapache-1.2.8/tools/install-sh0000755000175100017510000003160012706745114015626 0ustar ondrejondrej#!/bin/sh # install - install a program, script, or datafile scriptversion=2006-10-14.15 # This originates from X11R5 (mit/util/scripts/install.sh), which was # later released in X11R6 (xc/config/util/install.sh) with the # following copyright and license. # # Copyright (C) 1994 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 CONNEC- # TION 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 deal- # ings in this Software without prior written authorization from the X Consor- # tium. # # # FSF changes to this file are in the public domain. # # Calling this script install-sh is preferred over install.sh, to prevent # `make' implicit rules from creating a file called install from it # when there is no Makefile. # # This script is compatible with the BSD install script, but was written # from scratch. nl=' ' IFS=" "" $nl" # set DOITPROG to echo to test this script # Don't use :- since 4.3BSD and earlier shells don't like it. doit="${DOITPROG-}" if test -z "$doit"; then doit_exec=exec else doit_exec=$doit fi # Put in absolute file names if you don't have them in your path; # or use environment vars. mvprog="${MVPROG-mv}" cpprog="${CPPROG-cp}" chmodprog="${CHMODPROG-chmod}" chownprog="${CHOWNPROG-chown}" chgrpprog="${CHGRPPROG-chgrp}" stripprog="${STRIPPROG-strip}" rmprog="${RMPROG-rm}" mkdirprog="${MKDIRPROG-mkdir}" posix_glob= posix_mkdir= # Desired mode of installed file. mode=0755 chmodcmd=$chmodprog chowncmd= chgrpcmd= stripcmd= rmcmd="$rmprog -f" mvcmd="$mvprog" src= dst= dir_arg= dstarg= no_target_directory= usage="Usage: $0 [OPTION]... [-T] SRCFILE DSTFILE or: $0 [OPTION]... SRCFILES... DIRECTORY or: $0 [OPTION]... -t DIRECTORY SRCFILES... or: $0 [OPTION]... -d DIRECTORIES... In the 1st form, copy SRCFILE to DSTFILE. In the 2nd and 3rd, copy all SRCFILES to DIRECTORY. In the 4th, create DIRECTORIES. Options: -c (ignored) -d create directories instead of installing files. -g GROUP $chgrpprog installed files to GROUP. -m MODE $chmodprog installed files to MODE. -o USER $chownprog installed files to USER. -s $stripprog installed files. -t DIRECTORY install into DIRECTORY. -T report an error if DSTFILE is a directory. --help display this help and exit. --version display version info and exit. Environment variables override the default commands: CHGRPPROG CHMODPROG CHOWNPROG CPPROG MKDIRPROG MVPROG RMPROG STRIPPROG " while test $# -ne 0; do case $1 in -c) shift continue;; -d) dir_arg=true shift continue;; -g) chgrpcmd="$chgrpprog $2" shift shift continue;; --help) echo "$usage"; exit $?;; -m) mode=$2 shift shift case $mode in *' '* | *' '* | *' '* | *'*'* | *'?'* | *'['*) echo "$0: invalid mode: $mode" >&2 exit 1;; esac continue;; -o) chowncmd="$chownprog $2" shift shift continue;; -s) stripcmd=$stripprog shift continue;; -t) dstarg=$2 shift shift continue;; -T) no_target_directory=true shift continue;; --version) echo "$0 $scriptversion"; exit $?;; --) shift break;; -*) echo "$0: invalid option: $1" >&2 exit 1;; *) break;; esac done if test $# -ne 0 && test -z "$dir_arg$dstarg"; then # When -d is used, all remaining arguments are directories to create. # When -t is used, the destination is already specified. # Otherwise, the last argument is the destination. Remove it from $@. for arg do if test -n "$dstarg"; then # $@ is not empty: it contains at least $arg. set fnord "$@" "$dstarg" shift # fnord fi shift # arg dstarg=$arg done fi if test $# -eq 0; then if test -z "$dir_arg"; then echo "$0: no input file specified." >&2 exit 1 fi # It's OK to call `install-sh -d' without argument. # This can happen when creating conditional directories. exit 0 fi if test -z "$dir_arg"; then trap '(exit $?); exit' 1 2 13 15 # Set umask so as not to create temps with too-generous modes. # However, 'strip' requires both read and write access to temps. case $mode in # Optimize common cases. *644) cp_umask=133;; *755) cp_umask=22;; *[0-7]) if test -z "$stripcmd"; then u_plus_rw= else u_plus_rw='% 200' fi cp_umask=`expr '(' 777 - $mode % 1000 ')' $u_plus_rw`;; *) if test -z "$stripcmd"; then u_plus_rw= else u_plus_rw=,u+rw fi cp_umask=$mode$u_plus_rw;; esac fi for src do # Protect names starting with `-'. case $src in -*) src=./$src ;; esac if test -n "$dir_arg"; then dst=$src dstdir=$dst test -d "$dstdir" dstdir_status=$? else # Waiting for this to be detected by the "$cpprog $src $dsttmp" command # might cause directories to be created, which would be especially bad # if $src (and thus $dsttmp) contains '*'. if test ! -f "$src" && test ! -d "$src"; then echo "$0: $src does not exist." >&2 exit 1 fi if test -z "$dstarg"; then echo "$0: no destination specified." >&2 exit 1 fi dst=$dstarg # Protect names starting with `-'. case $dst in -*) dst=./$dst ;; esac # If destination is a directory, append the input filename; won't work # if double slashes aren't ignored. if test -d "$dst"; then if test -n "$no_target_directory"; then echo "$0: $dstarg: Is a directory" >&2 exit 1 fi dstdir=$dst dst=$dstdir/`basename "$src"` dstdir_status=0 else # Prefer dirname, but fall back on a substitute if dirname fails. dstdir=` (dirname "$dst") 2>/dev/null || expr X"$dst" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$dst" : 'X\(//\)[^/]' \| \ X"$dst" : 'X\(//\)$' \| \ X"$dst" : 'X\(/\)' \| . 2>/dev/null || echo X"$dst" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q' ` test -d "$dstdir" dstdir_status=$? fi fi obsolete_mkdir_used=false if test $dstdir_status != 0; then case $posix_mkdir in '') # Create intermediate dirs using mode 755 as modified by the umask. # This is like FreeBSD 'install' as of 1997-10-28. umask=`umask` case $stripcmd.$umask in # Optimize common cases. *[2367][2367]) mkdir_umask=$umask;; .*0[02][02] | .[02][02] | .[02]) mkdir_umask=22;; *[0-7]) mkdir_umask=`expr $umask + 22 \ - $umask % 100 % 40 + $umask % 20 \ - $umask % 10 % 4 + $umask % 2 `;; *) mkdir_umask=$umask,go-w;; esac # With -d, create the new directory with the user-specified mode. # Otherwise, rely on $mkdir_umask. if test -n "$dir_arg"; then mkdir_mode=-m$mode else mkdir_mode= fi posix_mkdir=false case $umask in *[123567][0-7][0-7]) # POSIX mkdir -p sets u+wx bits regardless of umask, which # is incompatible with FreeBSD 'install' when (umask & 300) != 0. ;; *) tmpdir=${TMPDIR-/tmp}/ins$RANDOM-$$ trap 'ret=$?; rmdir "$tmpdir/d" "$tmpdir" 2>/dev/null; exit $ret' 0 if (umask $mkdir_umask && exec $mkdirprog $mkdir_mode -p -- "$tmpdir/d") >/dev/null 2>&1 then if test -z "$dir_arg" || { # Check for POSIX incompatibilities with -m. # HP-UX 11.23 and IRIX 6.5 mkdir -m -p sets group- or # other-writeable bit of parent directory when it shouldn't. # FreeBSD 6.1 mkdir -m -p sets mode of existing directory. ls_ld_tmpdir=`ls -ld "$tmpdir"` case $ls_ld_tmpdir in d????-?r-*) different_mode=700;; d????-?--*) different_mode=755;; *) false;; esac && $mkdirprog -m$different_mode -p -- "$tmpdir" && { ls_ld_tmpdir_1=`ls -ld "$tmpdir"` test "$ls_ld_tmpdir" = "$ls_ld_tmpdir_1" } } then posix_mkdir=: fi rmdir "$tmpdir/d" "$tmpdir" else # Remove any dirs left behind by ancient mkdir implementations. rmdir ./$mkdir_mode ./-p ./-- 2>/dev/null fi trap '' 0;; esac;; esac if $posix_mkdir && ( umask $mkdir_umask && $doit_exec $mkdirprog $mkdir_mode -p -- "$dstdir" ) then : else # The umask is ridiculous, or mkdir does not conform to POSIX, # or it failed possibly due to a race condition. Create the # directory the slow way, step by step, checking for races as we go. case $dstdir in /*) prefix=/ ;; -*) prefix=./ ;; *) prefix= ;; esac case $posix_glob in '') if (set -f) 2>/dev/null; then posix_glob=true else posix_glob=false fi ;; esac oIFS=$IFS IFS=/ $posix_glob && set -f set fnord $dstdir shift $posix_glob && set +f IFS=$oIFS prefixes= for d do test -z "$d" && continue prefix=$prefix$d if test -d "$prefix"; then prefixes= else if $posix_mkdir; then (umask=$mkdir_umask && $doit_exec $mkdirprog $mkdir_mode -p -- "$dstdir") && break # Don't fail if two instances are running concurrently. test -d "$prefix" || exit 1 else case $prefix in *\'*) qprefix=`echo "$prefix" | sed "s/'/'\\\\\\\\''/g"`;; *) qprefix=$prefix;; esac prefixes="$prefixes '$qprefix'" fi fi prefix=$prefix/ done if test -n "$prefixes"; then # Don't fail if two instances are running concurrently. (umask $mkdir_umask && eval "\$doit_exec \$mkdirprog $prefixes") || test -d "$dstdir" || exit 1 obsolete_mkdir_used=true fi fi fi if test -n "$dir_arg"; then { test -z "$chowncmd" || $doit $chowncmd "$dst"; } && { test -z "$chgrpcmd" || $doit $chgrpcmd "$dst"; } && { test "$obsolete_mkdir_used$chowncmd$chgrpcmd" = false || test -z "$chmodcmd" || $doit $chmodcmd $mode "$dst"; } || exit 1 else # Make a couple of temp file names in the proper directory. dsttmp=$dstdir/_inst.$$_ rmtmp=$dstdir/_rm.$$_ # Trap to clean up those temp files at exit. trap 'ret=$?; rm -f "$dsttmp" "$rmtmp" && exit $ret' 0 # Copy the file name to the temp name. (umask $cp_umask && $doit_exec $cpprog "$src" "$dsttmp") && # and set any options; do chmod last to preserve setuid bits. # # If any of these fail, we abort the whole thing. If we want to # ignore errors from any of these, just make sure not to ignore # errors from the above "$doit $cpprog $src $dsttmp" command. # { test -z "$chowncmd" || $doit $chowncmd "$dsttmp"; } \ && { test -z "$chgrpcmd" || $doit $chgrpcmd "$dsttmp"; } \ && { test -z "$stripcmd" || $doit $stripcmd "$dsttmp"; } \ && { test -z "$chmodcmd" || $doit $chmodcmd $mode "$dsttmp"; } && # Now rename the file to the real destination. { $doit $mvcmd -f "$dsttmp" "$dst" 2>/dev/null \ || { # The rename failed, perhaps because mv can't rename something else # to itself, or perhaps because mv is so ancient that it does not # support -f. # Now remove or move aside any old file at destination location. # We try this two ways since rm can't unlink itself on some # systems and the destination file might be busy for other # reasons. In this case, the final cleanup might fail but the new # file should still install successfully. { if test -f "$dst"; then $doit $rmcmd -f "$dst" 2>/dev/null \ || { $doit $mvcmd -f "$dst" "$rmtmp" 2>/dev/null \ && { $doit $rmcmd -f "$rmtmp" 2>/dev/null; :; }; }\ || { echo "$0: cannot unlink or rename $dst" >&2 (exit 1); exit 1 } else : fi } && # Now rename the file to the real destination. $doit $mvcmd "$dsttmp" "$dst" } } || exit 1 trap '' 0 fi done # Local variables: # eval: (add-hook 'write-file-hooks 'time-stamp) # time-stamp-start: "scriptversion=" # time-stamp-format: "%:y-%02m-%02d.%02H" # time-stamp-end: "$" # End: rapache-1.2.8/tools/ltmain.sh0000755000175100017510000073341512706745114015462 0ustar ondrejondrej# Generated from ltmain.m4sh. # ltmain.sh (GNU libtool) 2.2.6b # 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 # 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. # Usage: $progname [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 # --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.6b Debian-2.2.6b-2ubuntu1 # automake: $automake_version # autoconf: $autoconf_version # # Report bugs to . PROGRAM=ltmain.sh PACKAGE=libtool VERSION="2.2.6b Debian-2.2.6b-2ubuntu1" TIMESTAMP="" package_revision=1.3017 # 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 # NLS nuisances: We save the old values to restore during execute mode. # Only set LANG and LC_ALL to C if already set. # These must not be set unconditionally because not all systems understand # e.g. LANG=C (notably SCO). lt_user_locale= lt_safe_locale= for lt_var in LANG LANGUAGE LC_ALL LC_CTYPE LC_COLLATE LC_MESSAGES do eval "if test \"\${$lt_var+set}\" = set; then save_$lt_var=\$$lt_var $lt_var=C export $lt_var lt_user_locale=\"$lt_var=\\\$save_\$lt_var; \$lt_user_locale\" lt_safe_locale=\"$lt_var=C; \$lt_safe_locale\" fi" done $lt_unset CDPATH : ${CP="cp -f"} : ${ECHO="echo"} : ${EGREP="/bin/grep -E"} : ${FGREP="/bin/grep -F"} : ${GREP="/bin/grep"} : ${LN_S="ln -s"} : ${MAKE="make"} : ${MKDIR="mkdir"} : ${MV="mv -f"} : ${RM="rm -f"} : ${SED="/bin/sed"} : ${SHELL="${CONFIG_SHELL-/bin/sh}"} : ${Xsed="$SED -e 1s/^X//"} # Global variables: EXIT_SUCCESS=0 EXIT_FAILURE=1 EXIT_MISMATCH=63 # $? = 63 is used to indicate version mismatch to missing. EXIT_SKIP=77 # $? = 77 is used to indicate a skipped test to automake. exit_status=$EXIT_SUCCESS # Make sure IFS has a sensible default lt_nl=' ' IFS=" $lt_nl" dirname="s,/[^/]*$,," basename="s,^.*/,," # 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 () { # 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_result=`$ECHO "X${1}" | $Xsed -e "$basename"` } # Generated shell functions inserted here. # 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: # In the unlikely event $progname began with a '-', it would play havoc with # func_echo (imagine progname=-n), so we prepend ./ in that case: func_dirname_and_basename "$progpath" progname=$func_basename_result case $progname in -*) progname=./$progname ;; esac # Make sure we have an absolute path for reexecution: case $progpath in [\\/]*|[A-Za-z]:\\*) ;; *[\\/]*) progdir=$func_dirname_result progdir=`cd "$progdir" && pwd` progpath="$progdir/$progname" ;; *) save_IFS="$IFS" IFS=: for progdir in $PATH; do IFS="$save_IFS" test -x "$progdir/$progname" && break done IFS="$save_IFS" test -n "$progdir" || progdir=`pwd` progpath="$progdir/$progname" ;; 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' # Re-`\' parameter expansions in output of double_quote_subst that were # `\'-ed in input to the same. If an odd number of `\' preceded a '$' # in input to double_quote_subst, that '$' was protected from expansion. # Since each input `\' is now two `\'s, look for any number of runs of # four `\'s followed by two `\'s and then a '$'. `\' that '$'. bs='\\' bs2='\\\\' bs4='\\\\\\\\' dollar='\$' sed_double_backslash="\ s/$bs4/&\\ /g s/^$bs2$dollar/$bs&/ s/\\([^$bs]\\)$bs2$dollar/\\1$bs2$bs$dollar/g s/\n//g" # Standard options: opt_dry_run=false opt_help=false opt_quiet=false opt_verbose=false opt_warning=: # func_echo arg... # Echo program name prefixed message, along with the current mode # name if it has been set yet. func_echo () { $ECHO "$progname${mode+: }$mode: $*" } # func_verbose arg... # Echo program name prefixed message in verbose mode only. func_verbose () { $opt_verbose && func_echo ${1+"$@"} # A bug in bash halts the script if the last line of a function # fails when set -e is in force, so we need another command to # work around that: : } # func_error arg... # Echo program name prefixed message to standard error. func_error () { $ECHO "$progname${mode+: }$mode: "${1+"$@"} 1>&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" # 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 } # func_mktempdir [string] # Make a temporary directory that won't clash with other running # libtool processes, and avoids race conditions if possible. If # given, STRING is the basename for that directory. func_mktempdir () { my_template="${TMPDIR-/tmp}/${1-$progname}" if test "$opt_dry_run" = ":"; then # Return a directory name, but don't create it in dry-run mode my_tmpdir="${my_template}-$$" else # If mktemp works, use that first and foremost 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}$$" 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'" fi $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 () { 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" esac } # 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 () { case $1 in *[\\\`\"]*) my_arg=`$ECHO "X$1" | $Xsed \ -e "$double_quote_subst" -e "$sed_double_backslash"` ;; *) 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" } # 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 () { 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 "$my_cmd" my_status=$? if test "$my_status" -eq 0; then :; else eval "(exit $my_status); $my_fail_exp" fi 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 () { 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 fi } # 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 } exit_cmd=: # 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 </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 } # Parse options once, thoroughly. This comes as soon as possible in # the script to make things like `libtool --version' happen quickly. { # Shorthand for --mode=foo, only valid as the first argument case $1 in clean|clea|cle|cl) shift; set dummy --mode clean ${1+"$@"}; shift ;; 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 ;; finish|finis|fini|fin|fi|f) shift; set dummy --mode finish ${1+"$@"}; shift ;; install|instal|insta|inst|ins|in|i) shift; set dummy --mode install ${1+"$@"}; shift ;; link|lin|li|l) shift; set dummy --mode link ${1+"$@"}; shift ;; uninstall|uninstal|uninsta|uninst|unins|unin|uni|un|u) shift; set dummy --mode uninstall ${1+"$@"}; shift ;; esac # 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 ;; -*) func_fatal_help "unrecognized option \`$opt'" ;; *) nonopt="$opt" break ;; esac done case $host in *cygwin* | *mingw* | *pw32* | *cegcc*) # don't eliminate duplications in $postdeps and $predeps opt_duplicate_compiler_generated_deps=: ;; *) opt_duplicate_compiler_generated_deps=$opt_duplicate_deps ;; esac # Having warned about all mis-specified options, bail out if # anything was wrong. $exit_cmd $EXIT_FAILURE } # 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 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" 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 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." } # 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 } # 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 } # 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" } # 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 <?"'"'"' &()|`$[]' \ && func_warning "libobj name \`$libobj' may not contain shell special characters." func_dirname_and_basename "$obj" "/" "" objname="$func_basename_result" xdir="$func_dirname_result" lobj=${xdir}$objdir/$objname test -z "$base_compile" && \ func_fatal_help "you must specify a compilation command" # Delete any leftover library objects. if test "$build_old_libs" = yes; then removelist="$obj $lobj $libobj ${libobj}T" else removelist="$lobj $libobj ${libobj}T" fi # On Cygwin there's no "real" PIC flag so we must build both object types case $host_os in cygwin* | mingw* | pw32* | os2* | cegcc*) pic_mode=default ;; esac if test "$pic_mode" = no && test "$deplibs_check_method" != pass_all; then # non-PIC code in shared libraries is not supported pic_mode=default fi # 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} lockfile="$output_obj.lock" else output_obj= need_locks=no lockfile= fi # 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" sleep 2 done elif test "$need_locks" = warn; then if test -f "$lockfile"; then $ECHO "\ *** ERROR, $lockfile exists and contains: `cat $lockfile 2>/dev/null` This indicates that another process is trying to use the same temporary object file, and libtool could not work around it because your compiler does not support \`-c' and \`-o' together. If you 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 exit $EXIT_FAILURE fi removelist="$removelist $output_obj" $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 # Only build a PIC object if we are building libtool libraries. if test "$build_libtool_libs" = yes; then # Without this assignment, base_compile gets emptied. fbsd_hideous_sh_bug=$base_compile if test "$pic_mode" != no; then command="$base_compile $qsrcfile $pic_flag" else # Don't build PIC code command="$base_compile $qsrcfile" fi func_mkdir_p "$xdir$objdir" if test -z "$output_obj"; then # Place PIC objects in $objdir command="$command -o $lobj" fi func_show_eval_locale "$command" \ 'test -n "$output_obj" && $RM $removelist; exit $EXIT_FAILURE' if test "$need_locks" = warn && test "X`cat $lockfile 2>/dev/null`" != "X$srcfile"; then $ECHO "\ *** ERROR, $lockfile contains: `cat $lockfile 2>/dev/null` but it should contain: $srcfile This indicates that another process is trying to use the same temporary object file, and libtool could not work around it because your compiler does not support \`-c' and \`-o' together. If you 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 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' fi # Allow error messages only from the first compilation. if test "$suppress_opt" = yes; then suppress_output=' >/dev/null 2>&1' fi fi # Only build a position-dependent object if we build old libraries. if test "$build_old_libs" = yes; then if test "$pic_mode" != yes; then # Don't build PIC code command="$base_compile $qsrcfile$pie_flag" else command="$base_compile $qsrcfile $pic_flag" fi if test "$compiler_c_o" = yes; then command="$command -o $obj" fi # Suppress compiler output if we already did a PIC compilation. command="$command$suppress_output" func_show_eval_locale "$command" \ '$opt_dry_run || $RM $removelist; exit $EXIT_FAILURE' if test "$need_locks" = warn && test "X`cat $lockfile 2>/dev/null`" != "X$srcfile"; then $ECHO "\ *** ERROR, $lockfile contains: `cat $lockfile 2>/dev/null` but it should contain: $srcfile This indicates that another process is trying to use the same temporary object file, and libtool could not work around it because your compiler does not support \`-c' and \`-o' together. If you 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 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' fi fi $opt_dry_run || { func_write_libtool_object "$libobj" "$objdir/$objname" "$objname" # Unlock the critical section if it was locked if test "$need_locks" != no; then removelist=$lockfile $RM "$lockfile" fi } exit $EXIT_SUCCESS } $opt_help || { test "$mode" = compile && func_mode_compile ${1+"$@"} } func_mode_help () { # We need to display help for each of the modes. case $mode in "") # Generic help is extracted from the usage comments # at the start of this file. func_help ;; clean) $ECHO \ "Usage: $progname [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: $progname [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 -no-suppress do not suppress compiler output for multiple passes -prefer-pic try to building PIC objects only -prefer-non-pic try to building non-PIC objects only -shared do not build a \`.o' file suitable for static linking -static only 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: $progname [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: $progname [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: $progname [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 following components of INSTALL-COMMAND are treated specially: -inst-prefix PREFIX-DIR Use PREFIX-DIR as a staging area for installation The rest of the components are interpreted as arguments to that command (only BSD-compatible install options are recognized)." ;; link) $ECHO \ "Usage: $progname [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 -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 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: $progname [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." ;; *) func_fatal_help "invalid operation mode \`$mode'" ;; esac $ECHO $ECHO "Try \`$progname --help' for more information about other modes." exit $? } # Now that we've collected a possible --mode arg, show help if necessary $opt_help && func_mode_help # 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" # Handle -dlopen flags immediately. for file in $execute_dlfiles; do test -f "$file" \ || func_fatal_help "\`$file' is not a file" 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" # Read the libtool library. dlname= library_names= func_source "$file" # 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 fi 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 ;; *.lo) # Just add the directory containing the .lo file. func_dirname "$file" "" "." dir="$func_dirname_result" ;; *) func_warning "\`-dlopen' is ignored for non-libtool libraries and objects" continue ;; esac # Get the absolute pathname. absdir=`cd "$dir" && pwd` test -n "$absdir" && dir="$absdir" # 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 # This variable tells wrapper scripts just to set shlibpath_var # rather than running their programs. libtool_execute_magic="$magic" # 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 ;; 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 $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\" $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" 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." ;; *) $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+"$@"} # 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 # 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" # 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 $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 # 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" test -n "$prev" && \ func_fatal_help "the \`$prev' option requires an argument" 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 # Strip any trailing slash from the destination. func_stripname '' '/' "$dest" dest=$func_stripname_result # 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" # 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" ;; 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" ;; *.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" library_names= old_library= relink_command= func_source "$file" # 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" ;; 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 -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@%%"` fi func_warning "relinking \`$file'" func_show_eval "$relink_command" \ 'func_fatal_error "error: relink \`$file'\'' with the above command before installing it"' fi # See the names of the shared library. set dummy $library_names; shift if test -n "$1"; then realname="$1" shift srcname="$realname" test -n "$relink_command" && srcname="$realname"T # 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 $?' 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 fi # Do each command in the postinstall commands. lib="$destdir/$realname" func_execute_cmds "$postinstall_cmds" 'exit $?' 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 $?' # Maybe install the static library, too. test -n "$old_library" && staticlibs="$staticlibs $dir/$old_library" ;; *.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 func_basename "$file" destfile="$func_basename_result" destfile="$destdir/$destfile" fi # 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'" ;; 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 ;; *) # 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 # 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 # 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= func_source "$wrapper" # Check the variables that should have been set. test -z "$generated_by_libtool_version" && \ func_fatal_error "invalid libtool wrapper script \`$wrapper'" 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' else exit $EXIT_SUCCESS 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" 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 $ECHO >> "$output_objdir/$my_dlsyms" "\ /* 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 $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 }," 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" ;; 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 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" ;; *) if test "X$my_pic_p" != Xno; then pic_flag_for_symtable=" $pic_flag" fi ;; 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'" ;; 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" } # 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 } # 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 ;; 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" } # 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 fi $ECHO "\ #! $SHELL # $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. # 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 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 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 "\ # Find the directory that this script lives in. thisdir=\`\$ECHO \"X\$file\" | \$Xsed -e 's%/[^/]*$%%'\` test \"x\$thisdir\" = \"x\$file\" && thisdir=. # 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%/[^/]*\$%%'\` # 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 file=\`\$ECHO \"X\$file\" | \$Xsed -e 's%^.*/%%'\` file=\`ls -ld \"\$thisdir/\$file\" | ${SED} -n 's/.*-> //p'\` done " } # end: func_emit_wrapper_part1 # 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 fi $ECHO "\ # 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 file=\"\$\$-\$program\" if test ! -d \"\$progdir\"; then $MKDIR \"\$progdir\" else $RM \"\$progdir/\$file\" fi" $ECHO "\ # 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 $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 $ECHO "\ if test -f \"\$progdir/\$program\"; then" # 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\" # 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/::*\$//'\` export $shlibpath_var " fi # 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 $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+\"\$@\"} " ;; *) $ECHO "\ exec \"\$progdir/\$program\" \${1+\"\$@\"} " ;; esac $ECHO "\ \$ECHO \"\$0: cannot exec \$program \$*\" 1>&2 exit 1 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 # 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 # 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}" } # 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 # 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 # 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 < #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 defined(PATH_MAX) # define LT_PATHMAX PATH_MAX #elif defined(MAXPATHLEN) # define LT_PATHMAX MAXPATHLEN #else # define LT_PATHMAX 1024 #endif #ifndef S_IXOTH # define S_IXOTH 0 #endif #ifndef S_IXGRP # define S_IXGRP 0 #endif #ifdef _MSC_VER # define S_IXUSR _S_IEXEC # define stat _stat # ifndef _INTPTR_T_DEFINED # define intptr_t int # endif #endif #ifndef DIR_SEPARATOR # define DIR_SEPARATOR '/' # define PATH_SEPARATOR ':' #endif #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 #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 */ #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 */ #ifdef __CYGWIN__ # define FOPEN_WB "wb" #endif #ifndef FOPEN_WB # define FOPEN_WB "w" #endif #ifndef _O_BINARY # define _O_BINARY 0 #endif #define XMALLOC(type, num) ((type *) xmalloc ((num) * sizeof(type))) #define XFREE(stale) do { \ if (stale) { free ((void *) stale); stale = 0; } \ } while (0) #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 const char *program_name = NULL; 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 func_emit_wrapper_part1 yes | $SED -e 's/\([\\"]\)/\\\1/g' \ -e 's/^/ "/' -e 's/$/\\n"/' echo ";" 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; } int check_executable (const char *path) { struct stat st; LTWRAPPER_DEBUGPRINTF (("(check_executable) : %s\n", path ? (*path ? path : "EMPTY!") : "NULL!")); if ((!path) || (!*path)) return 0; if ((stat (path, &st) >= 0) && (st.st_mode & (S_IXUSR | S_IXGRP | S_IXOTH))) return 1; else return 0; } int make_executable (const char *path) { int rval = 0; struct stat st; LTWRAPPER_DEBUGPRINTF (("(make_executable) : %s\n", path ? (*path ? path : "EMPTY!") : "NULL!")); if ((!path) || (!*path)) return 0; if (stat (path, &st) >= 0) { rval = chmod (path, st.st_mode | S_IXOTH | S_IXGRP | S_IXUSR); } return rval; } /* 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; LTWRAPPER_DEBUGPRINTF (("(find_executable) : %s\n", wrapper ? (*wrapper ? wrapper : "EMPTY!") : "NULL!")); if ((wrapper == NULL) || (*wrapper == '\0')) return NULL; /* 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 * 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; 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); } 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 } } 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; } int lt_split_name_value (const char *arg, char** name, char** value) { const char *p; int len; if (!arg || !*arg) return 1; p = strchr (arg, (int)'='); if (!p) return 1; *value = xstrdup (++p); len = strlen (arg) - strlen (*value); *name = XMALLOC (char, len); strncpy (*name, arg, len-1); (*name)[len - 1] = '\0'; return 0; } void lt_opt_process_env_set (const char *arg) { char *name = NULL; char *value = NULL; if (lt_split_name_value (arg, &name, &value) != 0) { XFREE (name); XFREE (value); lt_fatal ("bad argument for %s: '%s'", env_set_opt, arg); } lt_setenv (name, value); XFREE (name); XFREE (value); } void lt_opt_process_env_prepend (const char *arg) { char *name = NULL; char *value = NULL; char *new_value = NULL; if (lt_split_name_value (arg, &name, &value) != 0) { XFREE (name); XFREE (value); lt_fatal ("bad argument for %s: '%s'", env_prepend_opt, arg); } new_value = lt_extend_str (getenv (name), value, 0); lt_setenv (name, new_value); XFREE (new_value); XFREE (name); XFREE (value); } void lt_opt_process_env_append (const char *arg) { char *name = NULL; char *value = NULL; char *new_value = NULL; if (lt_split_name_value (arg, &name, &value) != 0) { XFREE (name); XFREE (value); lt_fatal ("bad argument for %s: '%s'", env_append_opt, arg); } new_value = lt_extend_str (getenv (name), value, 1); lt_setenv (name, new_value); XFREE (new_value); XFREE (name); XFREE (value); } 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 : ""))); 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); } } 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 : ""))); if (name && *name && value && *value) { char *new_value = lt_extend_str (getenv (name), value, 0); lt_setenv (name, new_value); XFREE (new_value); } } EOF } # end: func_emit_cwrapperexe_src # 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 # 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 ;; 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= 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 # 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 ;; -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 ;; esac done # See if our shared archives depend on static archives. test -n "$old_archive_from_new_cmds" && build_old_libs=yes # 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" # 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 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. # Check to see that this really is a libtool object. if func_lalib_unsafe_p "$arg"; then pic_object= non_pic_object= # Read the .lo file func_source "$arg" 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 # 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 # CHECK ME: I think I busted this. -Ossama if test "$prev" = dlprefiles; then # Preload the old-style object. dlprefiles="$dlprefiles $pic_object" prev= fi # A PIC object. func_append libobjs " $pic_object" arg="$pic_object" 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" # 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" prevarg="$arg" 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" fi continue ;; -allow-undefined) # FIXME: remove this flag sometime in the future. func_fatal_error "\`-allow-undefined' must not be used because it is the default" ;; -avoid-version) avoid_version=yes continue ;; -dlopen) prev=dlfiles continue ;; -dlpreopen) prev=dlprefiles continue ;; -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 ;; # 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 ;; -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'" else func_fatal_error "need path for \`-L' option" fi 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*'` case :$dllsearchpath: in *":$dir:"*) ;; ::) dllsearchpath=$dir;; *) dllsearchpath="$dllsearchpath:$dir";; esac case :$dllsearchpath: in *":$testbindir:"*) ;; ::) dllsearchpath=$testbindir;; *) dllsearchpath="$dllsearchpath:$testbindir";; esac ;; esac continue ;; -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 ;; 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 ;; -module) module=yes continue ;; # 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 ;; -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 ;; -multi_module) single_module="${wl}-multi_module" continue ;; -no-fast-install) fast_install=no continue ;; -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 ;; -no-undefined) allow_undefined=no continue ;; -objectlist) prev=objectlist continue ;; -o) prev=output ;; -precious-files-regex) prev=precious_regex continue ;; -release) prev=release continue ;; -rpath) prev=rpath continue ;; -R) prev=xrpath continue ;; -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 ;; -shared) # The effects of -shared are defined in a previous loop. continue ;; -shrext) prev=shrext continue ;; -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 ;; -weak) prev=weak continue ;; -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 ;; -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 ;; -Xcompiler) prev=xcompiler continue ;; -Xlinker) prev=xlinker continue ;; -XCClinker) prev=xcclinker continue ;; # -msg_* for osf cc -msg_*) func_quote_for_eval "$arg" arg="$func_quote_for_eval_result" ;; # -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 ;; # Some other compiler flag. -* | +*) func_quote_for_eval "$arg" arg="$func_quote_for_eval_result" ;; *.$objext) # A standard object. objs="$objs $arg" ;; *.lo) # A libtool-controlled object. # Check to see that this really is a libtool object. if func_lalib_unsafe_p "$arg"; then pic_object= non_pic_object= # Read the .lo file func_source "$arg" 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 # 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 # CHECK ME: I think I busted this. -Ossama if test "$prev" = dlprefiles; then # Preload the old-style object. dlprefiles="$dlprefiles $pic_object" prev= fi # A PIC object. func_append libobjs " $pic_object" arg="$pic_object" 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" # 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 ;; *.$libext) # An archive. deplibs="$deplibs $arg" old_deplibs="$old_deplibs $arg" continue ;; *.la) # A libtool-controlled library. 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" 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 # Now actually substitute the argument into the commands. if test -n "$arg"; then func_append compile_command " $arg" func_append finalize_command " $arg" fi done # argument parsing loop test -n "$prev" && \ func_fatal_help "the \`$prevarg' option requires an argument" 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 oldlibs= # calculate the name of the file, without its directory func_basename "$output" outputname="$func_basename_result" libobjs_save="$libobjs" 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= 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 fi libs="$libs $deplib" done if test "$linkmode" = lib; then libs="$predeps $libs $compiler_lib_search_path $postdeps" # 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 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 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 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" done deplibs="$tmp_deplibs" 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%" test "X$link_all_deplibs" != Xno && libs="$libs $dependency_libs" ;; esac 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 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 if test "$found" = yes || test -f "$lib"; then : else func_fatal_error "cannot find the library \`$lib' or unhandled argument \`$deplib'" fi # Check to see that this really is a libtool archive. func_lalib_unsafe_p "$lib" \ || func_fatal_error "\`$lib' is not a valid libtool archive" func_dirname "$lib" "" "." ladir="$func_dirname_result" dlname= dlopen= dlpreopen= libdir= library_names= old_library= inherited_linker_flags= # If the library was installed with an old release of libtool, # it will not redefine variables installed, or shouldnotlink installed=yes shouldnotlink=no avoidtemprpath= # 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 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" 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 elif test "$linkmode" != prog && test "$linkmode" != lib; then func_fatal_error "\`$lib' is not a convenience library" fi continue fi # $pass = conv # 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 # 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 # 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" # 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 # 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 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 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... 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 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 # Warn about portability, can't link against -module's on some # systems (darwin). Don't bleat about dlopened modules though! dlopenmodule="" for dlpremoduletest in $dlprefiles; do if test "X$dlpremoduletest" = "X$lib"; then dlopenmodule="$dlpremoduletest" break fi done if test -z "$dlopenmodule" && 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 if test -n "$old_archive_from_expsyms_cmds"; then # figure out the soname set dummy $library_names shift realname="$1" 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* | *cegcc*) func_arith $current - $age major=$func_arith_result versuffix="-$major" ;; esac eval soname=\"$soname_spec\" else soname="$realname" fi # Make a new name for the extract_expsyms_cmds to use soroot="$soname" func_basename "$soroot" soname="$func_basename_result" func_stripname 'lib' '.dll' "$soname" newlib=libimp-$func_stripname_result.a # 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 # 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" 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 if test "$lib_linked" != yes; then func_fatal_configuration "unsupported hardcode properties" fi 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 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 path= 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 ;; *) func_fatal_configuration "$modename: unknown library version type \`$version_type'" ;; 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 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 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 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 # 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" # All the library-specific variables (install_libdir is set above). library_names= old_library= dlname= # 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 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 # 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 if test -n "$soname_spec"; then eval soname=\"$soname_spec\" else soname="$realname" fi if test -z "$dlname"; then dlname=$soname fi lib="$output_objdir/$realname" linknames= for link do linknames="$linknames $link" done # 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= 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 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 # 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 -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 "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 tmp_deplibs= for test_deplib in $deplibs; do case " $convenience " in *" $test_deplib "*) ;; *) tmp_deplibs="$tmp_deplibs $test_deplib" ;; esac done deplibs="$tmp_deplibs" 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" func_extract_archives $gentop $convenience libobjs="$libobjs $func_extract_archives_result" test "X$libobjs" = "X " && libobjs= 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 # 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 # 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 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. # 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"` # Clear the reloadable object creation command queue and # initialize k to one. test_cmds= concat_cmds= objlist= last_robj= k=1 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" else output= fi 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 test -n "$save_libobjs" && func_verbose "creating a temporary reloadable object file: $output" # 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 exit $lt_exit } done IFS="$save_ifs" 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 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 -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 fi libobjs=$output # Restore the value of output. output=$save_output 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. # 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 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 IFS="$save_ifs" # 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 # 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 # 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 ;; 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" func_extract_archives $gentop $convenience reload_conv_objs="$reload_objs $func_extract_archives_result" fi fi # 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 output="$obj" func_execute_cmds "$reload_cmds" 'exit $?' # 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 exit $EXIT_SUCCESS fi if test "$build_libtool_libs" != yes; then if test -n "$gentop"; then func_show_eval '${RM}r "$gentop"' fi # 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 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 if test -n "$gentop"; then func_show_eval '${RM}r "$gentop"' fi exit $EXIT_SUCCESS ;; prog) case $host in *cygwin*) func_stripname '' '.exe' "$output" output=$func_stripname_result.exe;; esac test -n "$vinfo" && \ func_warning "\`-version-info' is ignored for programs" test -n "$release" && \ func_warning "\`-release' is ignored for programs" 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." 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 /'` ;; 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'` ;; esac # 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" compile_command="$compile_command $compile_deplibs" finalize_command="$finalize_command $finalize_deplibs" 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 # 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 *" $libdir "*) ;; *) perm_rpath="$perm_rpath $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 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 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 func_generate_dlsyms "$outputname" "@PROGRAM@" "no" # template prelinking step if test -n "$prelink_cmds"; then func_execute_cmds "$prelink_cmds" '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" # We have no uninstalled library dependencies, so finalize right now. exit_status=0 func_show_eval "$link_command" 'exit_status=$?' # Delete the generated files. if test -f "$output_objdir/${outputname}S.${objext}"; then func_show_eval '$RM "$output_objdir/${outputname}S.${objext}"' fi exit $exit_status fi 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 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 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 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" 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 else link_command="$compile_var$compile_command$compile_rpath" relink_command="$finalize_var$finalize_command$finalize_rpath" fi fi # Replace the output file specification. link_command=`$ECHO "X$link_command" | $Xsed -e 's%@OUTPUT@%'"$output_objdir/$outputname"'%g'` # Delete the old output files. $opt_dry_run || $RM $output $output_objdir/$outputname $output_objdir/lt-$outputname func_show_eval "$link_command" 'exit $?' # Now create the wrapper script. func_verbose "creating $output" # 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" else func_quote_for_eval "$var_value" relink_command="$var=$func_quote_for_eval_result; export $var; $relink_command" 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 # 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= ;; 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 } # 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 func_emit_wrapper no > $output chmod +x $output ;; esac } exit $EXIT_SUCCESS ;; esac # See if we need to build an old-fashioned archive. for oldlib in $oldlibs; do 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" fi if test -n "$addlibs"; then gentop="$output_objdir/${outputname}x" generated="$generated $gentop" func_extract_archives $gentop $addlibs oldobjs="$oldobjs $func_extract_archives_result" 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 # 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 oldobjs="$oldobjs $func_extract_archives_result" fi # 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 done 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 fi fi func_execute_cmds "$cmds" 'exit $?' done test -n "$generated" && \ func_show_eval "${RM}r$generated" # Now create the libtool archive. case $output in *.la) old_library= test "$build_old_libs" = yes && old_library="$libname.$libext" func_verbose "creating $output" # 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 # 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= 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. # The name that we can dlopen(3). dlname='$tdlname' # Names of this library. library_names='$library_names' # The name of the static archive. old_library='$old_library' # Linker flags that can not go in dependency_libs. inherited_linker_flags='$new_inherited_linker_flags' # Libraries that this one depends upon. dependency_libs='$dependency_libs' # Names of additional weak libraries provided by this library weak_library_names='$weak_libs' # Version information for $libname. current=$current age=$age revision=$revision # Is this an already installed library? installed=$installed # Should we warn about portability when linking against -modules? shouldnotlink=$module # Files to dlopen/dlpreopen dlopen='$dlfiles' dlpreopen='$dlprefiles' # 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 } # 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 } { test "$mode" = link || test "$mode" = relink; } && func_mode_link ${1+"$@"} # func_mode_uninstall arg... func_mode_uninstall () { $opt_debug RM="$nonopt" files= rmforce= exit_status=0 # This variable tells wrapper scripts just to set variables rather # than running their programs. libtool_install_magic="$magic" for arg do case $arg in -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" rmdirs= origobjdir="$objdir" for file in $files; do func_dirname "$file" "" "." dir="$func_dirname_result" if test "X$dir" = X.; then objdir="$origobjdir" else objdir="$dir/$origobjdir" fi func_basename "$file" name="$func_basename_result" test "$mode" = uninstall && objdir="$dir" # Remember objdir for removal later, being careful to avoid duplicates if test "$mode" = clean; then case " $rmdirs " in *" $objdir "*) ;; *) rmdirs="$rmdirs $objdir" ;; esac 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 : elif test -d "$file"; then exit_status=1 continue elif test "$rmforce" = yes; then continue fi rmfiles="$file" case $name in *.la) # Possibly a libtool archive, so verify it. if func_lalib_p "$file"; then func_source $dir/$name # Delete the libtool libraries and symlinks. for n in $library_names; do rmfiles="$rmfiles $objdir/$n" done test -n "$old_library" && rmfiles="$rmfiles $objdir/$old_library" case "$mode" in clean) case " $library_names " in # " " in the beginning catches empty $dlname *" $dlname "*) ;; *) rmfiles="$rmfiles $objdir/$dlname" ;; esac 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' 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' fi # FIXME: should reinstall the best remaining shared library. ;; esac fi ;; *.lo) # Possibly a libtool object, so verify it. if func_lalib_p "$file"; then # Read the .lo file func_source $dir/$name # Add PIC object to the list of files to remove. 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 rmfiles="$rmfiles $dir/$non_pic_object" fi fi ;; *) if test "$mode" = clean ; then noexename=$name case $file in *.exe) func_stripname '' '.exe' "$file" file=$func_stripname_result func_stripname '' '.exe' "$name" noexename=$func_stripname_result # $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 # note $name still contains .exe if it was in $file originally # as does the version of $file that was added into $rmfiles rmfiles="$rmfiles $objdir/$name $objdir/${name}S.${objext}" if test "$fast_install" = yes && test -n "$relink_command"; then rmfiles="$rmfiles $objdir/lt-$name" fi if test "X$noexename" != "X$name" ; then rmfiles="$rmfiles $objdir/lt-${noexename}.c" fi fi fi ;; esac func_show_eval "$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" 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" } test -z "$exec_cmd" && \ func_fatal_help "invalid operation mode \`$mode'" if test -n "$exec_cmd"; then eval exec "$exec_cmd" exit $EXIT_FAILURE fi exit $exit_status # The TAGs below are defined such that we never get into a situation # in which we disable both kinds of libraries. Given conflicting # choices, we go for a static library, that is the most portable, # since we can't tell whether shared libraries were disabled because # the user asked for that or because the platform doesn't support # them. This is particularly important on AIX, because we don't # support having both static and shared libraries enabled at the same # time on that platform, so we default to a shared-only configuration. # If a disable-shared tag is given, we'll fallback to a static-only # 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 # ### 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` # ### END LIBTOOL TAG CONFIG: disable-static # Local Variables: # mode:shell-script # sh-indentation:2 # End: # vi:sw=2 rapache-1.2.8/tools/missing0000755000175100017510000002557712706745114015241 0ustar ondrejondrej#! /bin/sh # Common stub for a few missing GNU programs while installing. scriptversion=2006-05-10.23 # Copyright (C) 1996, 1997, 1999, 2000, 2002, 2003, 2004, 2005, 2006 # Free Software Foundation, Inc. # Originally by Fran,cois Pinard , 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, 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. if test $# -eq 0; then echo 1>&2 "Try \`$0 --help' for more information" exit 1 fi run=: sed_output='s/.* --output[ =]\([^ ]*\).*/\1/p' sed_minuso='s/.* -o \([^ ]*\).*/\1/p' # In the cases where this matters, `missing' is being run in the # srcdir already. if test -f configure.ac; then configure_ac=configure.ac else configure_ac=configure.in fi msg="missing on your system" case $1 in --run) # Try to run requested program, and just exit if it succeeds. run= shift "$@" && exit 0 # Exit code 63 means version mismatch. This often happens # when the user try to use an ancient version of a tool on # a file that requires a minimum version. In this case we # we should proceed has if the program had been absent, or # if --run hadn't been passed. if test $? = 63; then run=: msg="probably too old" fi ;; -h|--h|--he|--hel|--help) echo "\ $0 [OPTION]... PROGRAM [ARGUMENT]... Handle \`PROGRAM [ARGUMENT]...' for when PROGRAM is missing, or return an error status if there is no known handling for PROGRAM. Options: -h, --help display this help and exit -v, --version output version information and exit --run try to run the given command, and emulate it if it fails Supported PROGRAM values: aclocal touch file \`aclocal.m4' autoconf touch file \`configure' autoheader touch file \`config.h.in' autom4te touch the output file, or create a stub one automake touch all \`Makefile.in' files bison create \`y.tab.[ch]', if possible, from existing .[ch] flex create \`lex.yy.c', if possible, from existing .c help2man touch the output file lex create \`lex.yy.c', if possible, from existing .c makeinfo touch the output file tar try tar, gnutar, gtar, then tar without non-portable flags yacc create \`y.tab.[ch]', if possible, from existing .[ch] Send bug reports to ." exit $? ;; -v|--v|--ve|--ver|--vers|--versi|--versio|--version) echo "missing $scriptversion (GNU Automake)" exit $? ;; -*) echo 1>&2 "$0: Unknown \`$1' option" echo 1>&2 "Try \`$0 --help' for more information" exit 1 ;; esac # Now exit if we have it, but it failed. Also exit now if we # don't have it and --version was passed (most likely to detect # the program). case $1 in lex|yacc) # Not GNU programs, they don't have --version. ;; tar) if test -n "$run"; then echo 1>&2 "ERROR: \`tar' requires --run" exit 1 elif test "x$2" = "x--version" || test "x$2" = "x--help"; then exit 1 fi ;; *) if test -z "$run" && ($1 --version) > /dev/null 2>&1; then # We have it, but it failed. exit 1 elif test "x$2" = "x--version" || test "x$2" = "x--help"; then # Could not run --version or --help. This is probably someone # running `$TOOL --version' or `$TOOL --help' to check whether # $TOOL exists and not knowing $TOOL uses missing. exit 1 fi ;; esac # If it does not exist, or fails to run (possibly an outdated version), # try to emulate it. case $1 in aclocal*) echo 1>&2 "\ WARNING: \`$1' is $msg. You should only need it if you modified \`acinclude.m4' or \`${configure_ac}'. You might want to install the \`Automake' and \`Perl' packages. Grab them from any GNU archive site." touch aclocal.m4 ;; autoconf) echo 1>&2 "\ WARNING: \`$1' is $msg. You should only need it if you modified \`${configure_ac}'. You might want to install the \`Autoconf' and \`GNU m4' packages. Grab them from any GNU archive site." touch configure ;; autoheader) echo 1>&2 "\ WARNING: \`$1' is $msg. You should only need it if you modified \`acconfig.h' or \`${configure_ac}'. You might want to install the \`Autoconf' and \`GNU m4' packages. Grab them from any GNU archive site." files=`sed -n 's/^[ ]*A[CM]_CONFIG_HEADER(\([^)]*\)).*/\1/p' ${configure_ac}` test -z "$files" && files="config.h" touch_files= for f in $files; do case $f in *:*) touch_files="$touch_files "`echo "$f" | sed -e 's/^[^:]*://' -e 's/:.*//'`;; *) touch_files="$touch_files $f.in";; esac done touch $touch_files ;; automake*) echo 1>&2 "\ WARNING: \`$1' is $msg. You should only need it if you modified \`Makefile.am', \`acinclude.m4' or \`${configure_ac}'. You might want to install the \`Automake' and \`Perl' packages. Grab them from any GNU archive site." find . -type f -name Makefile.am -print | sed 's/\.am$/.in/' | while read f; do touch "$f"; done ;; autom4te) echo 1>&2 "\ WARNING: \`$1' is needed, but is $msg. You might have modified some files without having the proper tools for further handling them. You can get \`$1' as part of \`Autoconf' from any GNU archive site." file=`echo "$*" | sed -n "$sed_output"` test -z "$file" && file=`echo "$*" | sed -n "$sed_minuso"` if test -f "$file"; then touch $file else test -z "$file" || exec >$file echo "#! /bin/sh" echo "# Created by GNU Automake missing as a replacement of" echo "# $ $@" echo "exit 0" chmod +x $file exit 1 fi ;; bison|yacc) echo 1>&2 "\ WARNING: \`$1' $msg. You should only need it if you modified a \`.y' file. You may need the \`Bison' package in order for those modifications to take effect. You can get \`Bison' from any GNU archive site." rm -f y.tab.c y.tab.h if test $# -ne 1; then eval LASTARG="\${$#}" case $LASTARG in *.y) SRCFILE=`echo "$LASTARG" | sed 's/y$/c/'` if test -f "$SRCFILE"; then cp "$SRCFILE" y.tab.c fi SRCFILE=`echo "$LASTARG" | sed 's/y$/h/'` if test -f "$SRCFILE"; then cp "$SRCFILE" y.tab.h fi ;; esac fi if test ! -f y.tab.h; then echo >y.tab.h fi if test ! -f y.tab.c; then echo 'main() { return 0; }' >y.tab.c fi ;; lex|flex) echo 1>&2 "\ WARNING: \`$1' is $msg. You should only need it if you modified a \`.l' file. You may need the \`Flex' package in order for those modifications to take effect. You can get \`Flex' from any GNU archive site." rm -f lex.yy.c if test $# -ne 1; then eval LASTARG="\${$#}" case $LASTARG in *.l) SRCFILE=`echo "$LASTARG" | sed 's/l$/c/'` if test -f "$SRCFILE"; then cp "$SRCFILE" lex.yy.c fi ;; esac fi if test ! -f lex.yy.c; then echo 'main() { return 0; }' >lex.yy.c fi ;; help2man) echo 1>&2 "\ WARNING: \`$1' is $msg. You should only need it if you modified a dependency of a manual page. You may need the \`Help2man' package in order for those modifications to take effect. You can get \`Help2man' from any GNU archive site." file=`echo "$*" | sed -n "$sed_output"` test -z "$file" && file=`echo "$*" | sed -n "$sed_minuso"` if test -f "$file"; then touch $file else test -z "$file" || exec >$file echo ".ab help2man is required to generate this page" exit 1 fi ;; makeinfo) echo 1>&2 "\ WARNING: \`$1' is $msg. You should only need it if you modified a \`.texi' or \`.texinfo' file, or any other file indirectly affecting the aspect of the manual. The spurious call might also be the consequence of using a buggy \`make' (AIX, DU, IRIX). You might want to install the \`Texinfo' package or the \`GNU make' package. Grab either from any GNU archive site." # The file to touch is that specified with -o ... file=`echo "$*" | sed -n "$sed_output"` test -z "$file" && file=`echo "$*" | sed -n "$sed_minuso"` if test -z "$file"; then # ... or it is the one specified with @setfilename ... infile=`echo "$*" | sed 's/.* \([^ ]*\) *$/\1/'` file=`sed -n ' /^@setfilename/{ s/.* \([^ ]*\) *$/\1/ p q }' $infile` # ... or it is derived from the source name (dir/f.texi becomes f.info) test -z "$file" && file=`echo "$infile" | sed 's,.*/,,;s,.[^.]*$,,'`.info fi # If the file does not exist, the user really needs makeinfo; # let's fail without touching anything. test -f $file || exit 1 touch $file ;; tar) shift # We have already tried tar in the generic part. # Look for gnutar/gtar before invocation to avoid ugly error # messages. if (gnutar --version > /dev/null 2>&1); then gnutar "$@" && exit 0 fi if (gtar --version > /dev/null 2>&1); then gtar "$@" && exit 0 fi firstarg="$1" if shift; then case $firstarg in *o*) firstarg=`echo "$firstarg" | sed s/o//` tar "$firstarg" "$@" && exit 0 ;; esac case $firstarg in *h*) firstarg=`echo "$firstarg" | sed s/h//` tar "$firstarg" "$@" && exit 0 ;; esac fi echo 1>&2 "\ WARNING: I can't seem to be able to run \`tar' with the given arguments. You may want to install GNU tar or Free paxutils, or check the command line arguments." exit 1 ;; *) echo 1>&2 "\ WARNING: \`$1' is needed, and is $msg. You might have modified some files without having the proper tools for further handling them. Check the \`README' file, it often tells you about the needed prerequisites for installing this package. You may also peek at any GNU archive site, in case some other package would contain this missing \`$1' program." exit 1 ;; esac exit 0 # Local variables: # eval: (add-hook 'write-file-hooks 'time-stamp) # time-stamp-start: "scriptversion=" # time-stamp-format: "%:y-%02m-%02d.%02H" # time-stamp-end: "$" # End: